Skip to content

Fix/gsd numpy int64 indexing issue 5224#5260

Open
kunjsinha wants to merge 7 commits intoMDAnalysis:developfrom
kunjsinha:fix/gsd-numpy-int64-indexing-issue-5224
Open

Fix/gsd numpy int64 indexing issue 5224#5260
kunjsinha wants to merge 7 commits intoMDAnalysis:developfrom
kunjsinha:fix/gsd-numpy-int64-indexing-issue-5224

Conversation

@kunjsinha
Copy link

@kunjsinha kunjsinha commented Feb 27, 2026

Fixes #5224

Changes made in this Pull Request:

  • Fixed TypeError when indexing GSDReader trajectory with np.int64
  • Added minimal cast frame = int(frame) in GSDReader._read_frame
  • Added test test_gsd_indexing_with_numpy_int in test_gsd.py

LLM / AI generated code disclosure

LLMs or other AI-powered tools (beyond simple IDE use cases) were used in this contribution: no

PR Checklist

  • Issue raised/referenced?
  • Tests updated/added?
  • Documentation updated/added?
  • package/CHANGELOG file updated?
  • Is your name in package/AUTHORS? (If it is not, add it!)
  • LLM/AI disclosure was updated.

Developers Certificate of Origin

I certify that I can submit this code contribution as described in the Developer Certificate of Origin, under the MDAnalysis LICENSE.


📚 Documentation preview 📚: https://mdanalysis--5260.org.readthedocs.build/en/5260/

Copy link

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

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

Hello there first time contributor! Welcome to the MDAnalysis community! We ask that all contributors abide by our Code of Conduct and that first time contributors introduce themselves on GitHub Discussions so we can get to know you. You can learn more about participating here. Please also add yourself to package/AUTHORS as part of this PR.

@codecov
Copy link

codecov bot commented Feb 27, 2026

Codecov Report

❌ Patch coverage is 0% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 93.82%. Comparing base (900d20b) to head (b84323f).

Files with missing lines Patch % Lines
package/MDAnalysis/coordinates/GSD.py 0.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #5260      +/-   ##
===========================================
- Coverage    93.83%   93.82%   -0.02%     
===========================================
  Files          180      180              
  Lines        22473    22474       +1     
  Branches      3189     3189              
===========================================
- Hits         21088    21086       -2     
- Misses         923      925       +2     
- Partials       462      463       +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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.

Analysis classes fail with HOOMD GSD files with a TypeError

1 participant