Skip to content

StaticFetcher() Implementation + from_pdb() refactor#5436

Open
jauy123 wants to merge 63 commits into
MDAnalysis:developfrom
jauy123:Fetcher_Class
Open

StaticFetcher() Implementation + from_pdb() refactor#5436
jauy123 wants to merge 63 commits into
MDAnalysis:developfrom
jauy123:Fetcher_Class

Conversation

@jauy123

@jauy123 jauy123 commented Jul 14, 2026

Copy link
Copy Markdown
Contributor

Fixes #5429 and #5431

Changes made in this Pull Request:

  • Implements fetch.fetchers.StaticFetcher()
  • Refactors fetch.pdb.from_pdb() to use StaticFetchers()

LLM / AI generated code disclosure

LLMs or other AI-powered tools (beyond simple IDE use cases) were used in this contribution: yes / no
From comment: #5436 (comment)

Per AI policy, I'm declaring that I used in AI in primary two ways: IDE autocomplete and help with reviewing the docstring used for the documentation to make it look more professional.

The one notable exception is that I used AI to help me draft test_multiple_downloads_existing_database and test_existing_database in testsuite/MDAnalysisTests/fetch/test_static_fetcher.py

I prompt is "Is there a unique way to determine the hash in order if two files are exactly the same including modification time in python using the standard library"

It gave code that used os.stat(), so I googled it and found pathlib.Path.stat().st_mtime in the official [docs](https://docs.python.org/3/library/pathlib.html#pathlib.Path.stat) which I then used manually for test_existing_database and test_multiple_downloads_existing_database with no AI.

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.

@jauy123

jauy123 commented Jul 14, 2026

Copy link
Copy Markdown
Contributor Author

Need a bit of polishing, but the overall logic behavior with documentation is there

@jauy123 jauy123 changed the title Fetcher class StaticFetcher() with from_pdb() refactor Jul 14, 2026
@jauy123 jauy123 changed the title StaticFetcher() with from_pdb() refactor StaticFetcher() Implementation + from_pdb() refactor Jul 14, 2026
@orbeckst orbeckst added GSoC GSoC project fetcher labels Jul 15, 2026
@jauy123

jauy123 commented Jul 15, 2026

Copy link
Copy Markdown
Contributor Author

Per AI policy, I'm declaring that I used in AI in primary two ways: IDE autocomplete and help with reviewing the docstring used for the documentation to make it look more professional.

The one notable exception is that I used AI to help me draft test_multiple_downloads_existing_database and test_existing_database in testsuite/MDAnalysisTests/fetch/test_static_fetcher.py

I prompt is "Is there a unique way to determine the hash in order if two files are exactly the same including modification time in python using the standard library"

It gave code that used os.stat(), so I googled it and found pathlib.Path.stat().st_mtime in the official docs which I then used manually for test_existing_database and test_multiple_downloads_existing_database with no AI.

@jauy123

jauy123 commented Jul 15, 2026

Copy link
Copy Markdown
Contributor Author

By the way, I don't know why tests are failing for this? The tests that are failing aren't from my code. It is stuff like MDAnalysisTests/coordinates/test_lammps.py::TestLAMMPSDATAWriter_molecule_tag which are failing which I didn't touch at all from my end.

I been running my tests (not the whole test suite) locally with pytest-cov on my end, and they aren't failing there.

@orbeckst

Copy link
Copy Markdown
Member

The failing tests are, as far as I can tell, #5382

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

fetcher GSoC GSoC project

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[GSoC 2026] Implementation of Static Fetcher

2 participants