-
-
Notifications
You must be signed in to change notification settings - Fork 178
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 errors and add mypy to CI #2190
Merged
Merged
Changes from all commits
Commits
Show all changes
68 commits
Select commit
Hold shift + click to select a range
9fbe4ed
Remove adjoint, unused and untested.
jhale 17f5d63
Remove this, cannot work with missing RTLD_NOW in modern ctypes.
jhale f7f9d33
Work in progress for mypy pass (MetaClass stuff is tricky).
jhale 0a849cd
Add mypy to ubuntu image
jhale bd8a508
Again
jhale d695e3e
Merge branch 'main' into jhale/mypy-fixes-and-ci
jhale c417f26
Move later
jhale 2aa08c1
Merge branch 'jhale/mypy-fixes-and-ci' of github.com:FEniCS/dolfinx i…
jhale 3494584
Bit more typing, remove adjoint import
jhale 068c3e8
Fix but more typing errors back
jhale 764faae
Adding if makes type check pass
jhale 5d2c439
35 errors left in python/dolfinx
jhale 129fda7
Remaining issues are due to use of single dispatch
jhale edff60b
Add py.typed files so that users actually see type annotations
jhale a3b5a86
Generalised arguments types for mesh constructors
jhale 1d50a2e
Fix singledispatch definition to raise NotImplementedError if no meth…
jhale 31d55be
Fixes all typing issues in assemble.
jhale 6a20000
9 left in demos, 22 in main library (mainly in petsc.py)
jhale 5a02e4b
flake8 fixes
jhale cdebd1a
Merge branch 'main' into jhale/mypy-fixes-and-ci
jhale 2b1e356
Demos pass, petsc.py and two strange ones to go
jhale ff21edf
Liberal mypy passes, all tests pass
jhale 5f49d1a
Fix fallback vector
jhale 04dd71e
Fixes
jhale 1d9c836
mypy settings in cfg file
jhale ea5165a
Small tweak
jhale 23d7f69
Bound numpy while 1.22 breaks numba
jhale 7876b16
pep8
jhale a4ccbbf
Remove numpy version
jhale 89e89cc
Move back to old use
jhale af65b6b
fix
jhale e3c049d
flake8
jhale 07b8f05
Test fixes
jhale 98e2140
move mypy up
jhale 2edac28
fix mypy install
jhale c70f63b
Fixes
jhale e6e5fb2
isort
jhale d7a7e1f
Free numpy version
jhale aa04fd6
Merge branch 'main' into jhale/mypy-fixes-and-ci
jhale 675e85e
Might need to re-run tests once Docker images update
jhale 1179dc7
Add mypy to image
jhale 5b62896
Type pybind11 .
jhale 8bcf985
Remove mypy install from CI
jhale 917e3cf
Also wrap cell_perm_gmsh
jhale 239d93d
Make dim optional, grab tdim?
jhale d078159
Reallow value to be passed
jhale 99bc314
Allow lists to eval
jhale 73f4d96
Remove comment
jhale ade54ba
Better API?
jhale 7962032
Prefer this design.
jhale 89c891b
Better singledispatch la
jhale 16ec231
Bug fixes
jhale e0e30ec
Fix
jhale 458bf41
Merge branch 'main' into jhale/mypy-fixes-and-ci
jhale 947051b
Ignore return error
jhale 9296b15
flake8
jhale d4244c6
Remove explicit casts
jhale b352006
Remove cryptic typings, ignore errors
jhale 83cb9eb
Revert some files to main
jhale 5477334
Remove explicit dim
jhale 4dadcba
Small tweaks.
jhale e431eb0
Revert
jhale 6bd4d06
flake8
jhale cca3b9f
Merge branch 'main' of github.com:FEniCS/dolfinx into jhale/mypy-fixe…
jhale 8ebad9d
Merge branch 'main' into jhale/mypy-fixes-and-ci
jhale ecc87b3
Fix, should discuss this again
jhale a2d49c5
Merge remote-tracking branch 'origin/main' into jhale/mypy-fixes-and-ci
jhale 2163afb
Merge branch 'jhale/mypy-fixes-and-ci' of github.com:FEniCS/dolfinx i…
jhale File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This need to be checked. My recollection os that the removed code was required when MKL is used.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
As it stands it won't work because
ctypes.RTLD_NOW
no longer exists, at least in any of my installs. There isctypes.RTLD_GLOBAL
andctypes.RTLD_LOCAL
.The static checker picked this up as an error which was quite nice.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@chrisrichardson do you know the purpose/necessity of this code path?