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

Raise error when from_deepmd_npy_mixed with not-a-directory para. #432

Open
wants to merge 2 commits into
base: devel
Choose a base branch
from

Conversation

iProzd
Copy link
Collaborator

@iProzd iProzd commented Mar 12, 2023

No description provided.

@codecov
Copy link

codecov bot commented Mar 12, 2023

Codecov Report

Patch coverage: 100.00% and project coverage change: +0.02 🎉

Comparison is base (f8c5d4a) 82.51% compared to head (91deabf) 82.53%.

Additional details and impacted files
@@            Coverage Diff             @@
##            devel     #432      +/-   ##
==========================================
+ Coverage   82.51%   82.53%   +0.02%     
==========================================
  Files          68       68              
  Lines        6198     6206       +8     
==========================================
+ Hits         5114     5122       +8     
  Misses       1084     1084              
Impacted Files Coverage Δ
dpdata/bond_order_system.py 68.11% <ø> (ø)
dpdata/cli.py 0.00% <ø> (ø)
dpdata/cp2k/cell.py 82.14% <ø> (ø)
dpdata/cp2k/output.py 97.84% <ø> (ø)
dpdata/fhi_aims/output.py 90.37% <ø> (ø)
dpdata/plugins/3dmol.py 46.66% <ø> (ø)
dpdata/plugins/ase.py 78.78% <ø> (ø)
dpdata/siesta/aiMD_output.py 97.47% <ø> (ø)
dpdata/xyz/quip_gap_xyz.py 93.16% <ø> (ø)
dpdata/plugins/deepmd.py 67.74% <100.00%> (+0.26%) ⬆️
... and 1 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@@ -136,6 +136,7 @@ def mix_system(self, *system, type_map, **kwargs):

def from_multi_systems(self, directory, **kwargs):
sys_dir = []
assert os.path.isdir(directory), f"{directory} is not a directory!"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please raise FileNotFoundError. One has not chance of catching the error with assertion!
Plz also add a UT for it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants