Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix documentation of descriptor classes that have a custom metaclass #1843

Closed
wants to merge 1 commit into from

Conversation

embray
Copy link
Contributor

@embray embray commented Apr 9, 2015

(i.e. a subclass of type). This avoids using string comparisons to do
type checks, except in the case of the fix for #1155, since in Python 3
there really seems to be no way to export the instancemethod type, short
of using ctypes.

The attached test demonstrates the issue that this fixes--previously such classes were identified as data attributes.

(i.e. a subclass of type).  This avoids using string comparisons to do
type checks, except in the case of the fix for sphinx-doc#1155, since in Python 3
there really seems to be no way to export the instancemethod type, short
of using ctypes.
embray added a commit to embray/astropy_helpers that referenced this pull request Apr 9, 2015
embray added a commit to astropy/astropy-helpers that referenced this pull request Apr 10, 2015
embray added a commit to astropy/astropy-helpers that referenced this pull request Apr 10, 2015
@NYKevin
Copy link

NYKevin commented May 26, 2015

See #1526 for some related discussion imported from Bitbucket.

@embray
Copy link
Contributor Author

embray commented May 27, 2015

Thanks, somehow I didn't see the existing issue (figured this was pretty obscure). This should fix #1526.

@bsipocz
Copy link
Contributor

bsipocz commented Apr 14, 2016

@shimizukawa @embray - I wonder what's the status of this?

We have this workaround locally in astropy-helpers (https://github.com/astropy/astropy-helpers/blob/master/astropy_helpers/sphinx/ext/autodoc_enhancements.py#L75), but it causes the new 1.4 Sphinx to raise a warning (#2451) that I can't get rid of. Would be nice to see it making its way upstream, and solve the issue.

WARNING: while setting up extension astropy_helpers.sphinx.ext.autodoc_enhancements: directive 'autoattribute' is already registered, it will be overridden

@embray
Copy link
Contributor Author

embray commented Apr 15, 2016

I dunno. Looks to me like the status is I made a PR and it works, but hasn't bee merged yet shrug.

@shimizukawa
Copy link
Member

Sorry for my late reply.
This patch looks good to me.
Thanks for your contribution. I'll merge this soon!

@embray
Copy link
Contributor Author

embray commented Nov 24, 2016

I can rebase the PR if it will help.

@shimizukawa
Copy link
Member

@embray Thanks!
IMO this "bug fix" should be merged into "stable" branch.
Can you do that?

shimizukawa added a commit that referenced this pull request Nov 24, 2016
@shimizukawa
Copy link
Member

OK, I can merge this PR into stable by hand. For CI testing, I pushed it as branch named '1843'.

@shimizukawa
Copy link
Member

Now CI passed.

@shimizukawa
Copy link
Member

Finally this PR is merged into stable branch by hand as: 3284e89.
Thanks!

@bsipocz
Copy link
Contributor

bsipocz commented Nov 24, 2016

@shimizukawa - Thanks for merging this. Could you tell which version it will be released? I'm asking, so we know when to remove the workarounds on our side.

@shimizukawa
Copy link
Member

It will come next 1.5 beta release (and 1.4.10 if exists)

@embray
Copy link
Contributor Author

embray commented Nov 26, 2016

Thanks sorry I wasn't able to get to it, I've been on a (brief) vacation. LGTM as merged!

astrofrog pushed a commit to astropy/sphinx-automodapi that referenced this pull request Jan 27, 2018
astrofrog pushed a commit to astropy/sphinx-automodapi that referenced this pull request Jan 27, 2018
astrofrog pushed a commit to astropy/sphinx-automodapi that referenced this pull request Jan 27, 2018
astrofrog pushed a commit to astropy/sphinx-automodapi that referenced this pull request Jan 27, 2018
@github-actions github-actions bot locked as resolved and limited conversation to collaborators Sep 17, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants