-
-
Notifications
You must be signed in to change notification settings - Fork 487
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
Add a bit of typing to manifold code #29775
Comments
comment:1
In case people are interested in a general discussion of typing in the Sage library: #29756 Meta-ticket: Review of Python 3 features that sagelib should use systematically |
comment:3
The addition of |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:5
Replying to @egourgoulhon:
I think this is a very important point, and one that needs discussion in a broader context.
|
comment:6
Replying to @egourgoulhon:
If we don't duplicate the code, then the output type of |
This comment has been minimized.
This comment has been minimized.
comment:8
It's true that I noticed while working on typing support, but the addition is actually rather independent of this. As Eric says, If it were just for typing, one could also annotate the original |
comment:9
Replying to @tobiasdiez:
No, one can take the differential because the returned object in this case is actually a
No need for improvement, this is already the case:
|
comment:11
Thanks for the clarification. I actually tested it before, but apparently made some mistakes as I've thus removed the Anything else that needs improvement? From my side this is good to go. I would add more typing in follow-up issues to keep the size of the changes small and reviewable. |
comment:12
There are some doctest errors, as well as coverage, pyflakes and pycodeystyle errors; check the patchbot reports (click on the "9.2.beta0 button" in the top right of the ticket description). |
comment:13
Another thing: the typing information does not show up in the html documentation produced by Sphinx. |
comment:14
The file |
comment:15
I had a quick look at the errors and most of them are a result of that the tools (pyflakes and pycodestyle) have problems with the typing syntax. After a bit of googling, it appears that these issues are fixed in the most recent versions (e.g. PyCQA/pyflakes#247 and vim-syntastic/syntastic#1667). Where do I find the version used? Moreover, one common problems seems to be that these tools need to be installed under python 3, since otherwise they check the files using python 2 syntax (e.g. vim-syntastic/syntastic#1667 (comment)). How can I make sure that it's the case indeed? Finally, the |
comment:17
Replying to @tobiasdiez:
Could you create a separate ticket for this please and link to it from #28936 |
comment:18
Replying to @tobiasdiez:
Best to open an issue on https://github.com/sagemath/sage-patchbot |
comment:19
branch is red and needs to be rebased on the latest beta |
Branch pushed to git repo; I updated commit sha1. New commits:
|
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:124
There's also one file that still manually string-quotes types instead of relying on |
Branch pushed to git repo; I updated commit sha1. New commits:
|
comment:126
Ready now, I think. The patch is still bigger than really necessary as a result of Tobias's tool alphabetically sorting the imports. Also the formatting of the typed argument lists uses a mix of styles across the file. |
comment:127
Tests still OK with Python 3.7 |
comment:128
As all remarks seem to be addressed, Matthias is fine with my changes and I'm with his, I'll set it back to positively reviewed. |
Changed reviewer from Matthias Koeppe, ... to Matthias Koeppe, Tobias Diez |
comment:129
There is a merge failure with Sage 9.6.beta6 |
Branch pushed to git repo; I updated commit sha1. This was a forced push. New commits:
|
comment:131
rebased |
comment:132
The patchbot reveals some coverage issue, but this seems to be triggered by the use of |
comment:133
Thanks! |
Changed reviewer from Matthias Koeppe, Tobias Diez to Matthias Koeppe, Tobias Diez, Eric Gourgoulhon |
comment:135
Replying to @egourgoulhon:
Might be worth opening a ticket at |
comment:136
Replying to @slel:
Thanks for the suggestion; this is now |
Changed branch from public/manifolds/typing to |
This PR adds a bit of typing information to some of the methods in the manifolds module.
CC: @tscrim @nthiery @mjungmath @fchapoton
Component: manifolds
Keywords: typing
Author: Tobias Diez
Branch/Commit:
7c18c7f
Reviewer: Matthias Koeppe, Tobias Diez, Eric Gourgoulhon
Issue created by migration from https://trac.sagemath.org/ticket/29775
The text was updated successfully, but these errors were encountered: