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

pyright fixes for ext/io/phonon/symmetry/transformations/util/vis/dev_scripts and improve io.lobster #3757

Merged
merged 72 commits into from
Apr 15, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
Show all changes
72 commits
Select commit Hold shift + click to select a range
418f3e2
Add a CI run that only tests non-optional deps (optimistically)
ml-evs Feb 22, 2024
b0b16a6
Install dev deps at least
ml-evs Feb 22, 2024
a9cf9cd
Try out pyright config for unbound vars only
ml-evs Feb 22, 2024
93e9afe
Add pyright to CI
ml-evs Feb 22, 2024
fc09e78
Merge branch 'master' into ml-evs/ci-with-mandatory-deps
ml-evs Mar 29, 2024
f63b806
pyright fix
DanielYang59 Apr 13, 2024
20d318e
pyright fix in vis.structure_vtk
DanielYang59 Apr 13, 2024
974a8b9
fix `utils`
DanielYang59 Apr 13, 2024
081db43
fix `transformations`
DanielYang59 Apr 13, 2024
28b9380
Merge branch 'master' into pyright
DanielYang59 Apr 13, 2024
fa0e173
Merge branch 'master' into pyright
DanielYang59 Apr 13, 2024
d388c23
fix `symmetry.kpath`
DanielYang59 Apr 13, 2024
895f2c1
finish fixing `symmetry`
DanielYang59 Apr 13, 2024
2d7f701
update `pyright`
DanielYang59 Apr 13, 2024
a6a5714
suppress `pyright` reportMissingModuleSource warning
DanielYang59 Apr 13, 2024
2063f09
fix `phonon`
DanielYang59 Apr 13, 2024
4ac354f
some fixes in `io`
DanielYang59 Apr 13, 2024
a9c8c78
Merge branch 'master' into pyright
DanielYang59 Apr 13, 2024
e3d2d54
format tweaks of `io.vasp.outputs`
DanielYang59 Apr 13, 2024
afac73e
fix unit test for `symmetry.kpath`
DanielYang59 Apr 13, 2024
147cb85
fix io.vasp
DanielYang59 Apr 13, 2024
962e4ee
fix unit test for io.vasp.inputs
DanielYang59 Apr 13, 2024
2f4c6fc
fix io.qchem
DanielYang59 Apr 13, 2024
87a588b
fix io.pwscf, need input
DanielYang59 Apr 13, 2024
c3f290b
replace `match.group(i)` with `match[i]`
DanielYang59 Apr 13, 2024
8ee0655
fix missing )
DanielYang59 Apr 13, 2024
45b59b9
fix typo
DanielYang59 Apr 13, 2024
eddf08f
suppress `reportInvalidTypeForm`
DanielYang59 Apr 13, 2024
d9cfcff
fix io.nwchem and packmol
DanielYang59 Apr 13, 2024
ac96441
fix io.lobster.inputs and use snake_case
DanielYang59 Apr 13, 2024
5b031a5
fix lobsterenv
DanielYang59 Apr 13, 2024
92d8a91
fix io.icet
DanielYang59 Apr 13, 2024
0acf807
fix io.lammps
DanielYang59 Apr 13, 2024
69ea14e
revert to try/except for speed
DanielYang59 Apr 14, 2024
da84ebc
set default coords_are_cartesian for pwscf
DanielYang59 Apr 14, 2024
4d6426b
fix io.gaussian
DanielYang59 Apr 14, 2024
6778493
fix io.fiesta
DanielYang59 Apr 14, 2024
4a0a125
fix io.cif
DanielYang59 Apr 14, 2024
626ba66
fix io.babel
DanielYang59 Apr 14, 2024
a44a97d
fix io.ase
DanielYang59 Apr 14, 2024
641e9aa
fix io.cif tests
DanielYang59 Apr 14, 2024
5fed53a
fix io.feff
DanielYang59 Apr 14, 2024
5732564
fix io.exciting
DanielYang59 Apr 14, 2024
6066330
fix io.abinit
DanielYang59 Apr 14, 2024
17b8e4a
fix io.cp2k
DanielYang59 Apr 14, 2024
3b41635
fix io.lobster.outputs
DanielYang59 Apr 14, 2024
46987fd
take some (not all) code rabbit suggestion
DanielYang59 Apr 14, 2024
7335314
fix ext
DanielYang59 Apr 14, 2024
6580fb5
fix dev_scripts
DanielYang59 Apr 14, 2024
58050bb
fix logic error
DanielYang59 Apr 14, 2024
aab8e22
simplify checking
DanielYang59 Apr 14, 2024
6f9d344
remove some weird constructions in lobster io
JaGeo Apr 14, 2024
247a08c
pre-commit auto-fixes
pre-commit-ci[bot] Apr 14, 2024
b8d03f1
resolve code rabbit suggestions
JaGeo Apr 14, 2024
befe350
Merge branch 'pyright' of github.com:DanielYang59/pymatgen into pyright
DanielYang59 Apr 14, 2024
136a0e4
fix more new key issues
JaGeo Apr 14, 2024
9ec8141
fix new_key problems with code simplification
JaGeo Apr 14, 2024
b3a3180
make same logic for del
JaGeo Apr 14, 2024
0ba73d8
remove unnecessary `int` before `math.floor/ceil`
DanielYang59 Apr 14, 2024
f9db258
Fix lower vs other
JaGeo Apr 14, 2024
1b0d6fe
Merge branch 'pyright' of github.com:DanielYang59/pymatgen into pyright
JaGeo Apr 14, 2024
72981f1
tweak error type in io.lobster
DanielYang59 Apr 15, 2024
aee9bc4
fix error type in lobster test
DanielYang59 Apr 15, 2024
d1aec0f
fix nested if
DanielYang59 Apr 15, 2024
abaebb5
pre-commit auto-fixes
pre-commit-ci[bot] Apr 15, 2024
801a98f
remove DEBUG tag
DanielYang59 Apr 15, 2024
4b1c8d0
comment out pyright until all chunks finished
DanielYang59 Apr 15, 2024
6cc78ce
replace runtime error with value error
DanielYang59 Apr 15, 2024
afc4f6d
use walrus op for if match := re.match(...)
janosh Apr 15, 2024
80aa33f
remove unused pyright code until ready to enable
janosh Apr 15, 2024
1dffaff
rename single-letter m->match
janosh Apr 15, 2024
2ce0368
remove unused raw
DanielYang59 Apr 15, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Try out pyright config for unbound vars only
  • Loading branch information
ml-evs committed Feb 23, 2024
commit a9cf9cdf93a95ad8713f13561d59c6ac4c6cab88
5 changes: 5 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -62,3 +62,8 @@ repos:
hooks:
- id: nbstripout
args: [--drop-empty-cells, --keep-output]

- repo: https://github.com/RobertCraigie/pyright-python
rev: v1.1.351
hooks:
- id: pyright
7 changes: 7 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -142,3 +142,10 @@ rute,reson,titels,ges,scalr,strat,struc,hda,nin,ons,pres,kno,loos,lamda,lew,atom
"""
skip = "pymatgen/analysis/aflow_prototypes.json"
check-filenames = true

[tool.pyright]
typeCheckingMode = "off"
reportPossiblyUnboundVariable = true
reportUnboundVariable = true
reportMissingImports = false
exclude = ["**/tests"]