deepmodeling / deepmodeling/dpti

[Code scan] LAMMPS dump box parser crashes on orthogonal boxes

Open Beginner friendly
#141 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
42
Forks
27
PR merge metrics
No merged PRs in 30d

Description

Source: Codex global repository scan of deepmodeling/dpti at commit b719828e7eeb571bd26411430197cd74ea78e38c.
Project: https://github.com/orgs/deepmodeling/projects/27

Problem
`dump.get_dumpbox()` always reads a third value from each BOX BOUNDS line as a tilt factor. Standard orthogonal LAMMPS dump boxes use only `lo hi` per axis, so this parser raises `IndexError` for valid dump files.

Code references
https://github.com/deepmodeling/dpti/blob/b719828e7eeb571bd26411430197cd74ea78e38c/dpti/lib/dump.py#L67
https://github.com/deepmodeling/dpti/blob/b719828e7eeb571bd26411430197cd74ea78e38c/dpti/lib/dump.py#L72
https://github.com/deepmodeling/dpti/blob/b719828e7eeb571bd26411430197cd74ea78e38c/dpti/lib/dump.py#L75

Reproduction
Parse a dump block with:

```text
ITEM: BOX BOUNDS pp pp pp
0 10
0 10
0 10
```

Expected result
Orthogonal boxes should parse with zero tilt factors instead of crashing.

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at dpti/lib/dump.py around lines 67, 72, and 75, then reproduce the failure with the orthogonal BOX BOUNDS block from the issue. Verify that standard two-value bounds are accepted and represented with zero tilt factors, without changing handling of tilt values.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Clearly specified
Newbie friendliness
78/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.