Skip to content

Commit

Permalink
remove debug prints
Browse files Browse the repository at this point in the history
  • Loading branch information
PythonFZ committed Dec 6, 2024
1 parent 23509ef commit 5fb1c40
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 8 deletions.
1 change: 0 additions & 1 deletion znh5md/interface/io.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,6 @@ def __getitem__(
# separately from the OSError h5py raises
raise
except OSError as err:
print(err)
raise IndexError("Index out of range")

def extend(self, frames: list[ase.Atoms]) -> None:
Expand Down
7 changes: 0 additions & 7 deletions znh5md/interface/read.py
Original file line number Diff line number Diff line change
Expand Up @@ -182,10 +182,6 @@ def getitem(
observables = f[f"/observables/{self.particles_group}"]
process_observables(self, frames, observables, index)

print(len(frames))
print(particles)
print(is_single_item)

return list(frames) if not is_single_item else frames[0]


Expand Down Expand Up @@ -346,15 +342,12 @@ def process_observables(self, frames: Frames, observables, index) -> None:
frames, grp_name, grp["value"][index], origin, self.use_ase_calc
)
except (OSError, IndexError) as err:
print(err)
# ??? why is this not triggering?
pass # Handle backfilling for invalid values
except KeyError as err:
print(err)
raise KeyError(
f"Key '{grp_name}' does not seem to be a valid H5MD group"
" - missing 'value' dataset."
)
except Exception as err:
print(err)
raise ValueError(f"Error processing group '{grp_name}'") from err

0 comments on commit 5fb1c40

Please sign in to comment.