Fixes needed before merging the ported Gaussian basis-set exporters (#868)
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 25/100
Direzione di ricerca
Start by reviewing the two port branches and the listed files: the Gaussian exporter scripts, rdStandardGBS.py, tests/basislegacy/run_tests.py, CMakeLists.txt, .github/workflows/test.yml, and TGBSConfig.C. Check the existing modern test entry point and the Perl behavior described for each finding. Done means resolving the merge conflicts, addressing the listed fixes and stale paths, adding the missing fixture and test wiring, and running the basis and verify tests.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Review findings for cx/868-gbs-gaussian-modern and cx/868-gbs-gaussian-legacy. The ports themselves are faithful: every pinned reference was regenerated from the parent commit's Perl and reproduces (244 cases modern, 42 legacy), and 138 further differential runs -- shipped fixtures plus constructed inputs, across three locales -- agree byte-for-byte on stdout, stderr and exit status. Neither branch mentions python3; both use the <ecceHome>/python/python.exe pattern with a fallback. No deleted .pm has a remaining Perl caller.
Items to fix before merging:
-
Unguarded index, modern branch.
scripts/parsers/wrGaussian16GBS.py:148and the same line inwrGaussian09GBS.pyandwrGaussian03GBS.py:shells[index - 1] + '-' + first. An ECP with 9 or more components raises IndexError, so the exporter dies with a traceback after a partial basis block; the Perl printed an empty shell name and completed. The legacy branch already guards this (wrGaussian94GBS.py:57). The status check atTGBSConfig.C:2380catches it, so the user gets a warning rather than silent corruption, but the deck is lost. Unrealistic data, one-line fix. -
Non-UTF-8 input now fails, both branches.
rdStandardGBS.py:readStandardBSreadssys.stdinas text, so a single byte that is not valid UTF-8 anywhere in the .gbs -- including inside a comment -- raises UnicodeDecodeError, surfaces as exit 255 with empty output, and the user sees "Cannot execute script". The Perl passed bytes through and produced a correct deck. Reproduced on a UTF-8 desktop; works under LC_ALL=C. Read stdin as bytes, or decode with errors='replace'. -
A test that never runs, legacy branch.
tests/basislegacy/run_tests.pyhas noadd_testin CMakeLists.txt, no entry in.github/workflows/test.yml, and no other reference in the tree. Its 42 pinned cases are dead weight. The modern branch's equivalent is reached viatests/basis/run_tests.py:567. -
The G03 element ordering is deliberately changed and entirely unpinned, modern branch. Perl's G03 writer iterated unsorted
keys %gbs, so its element-block order was nondeterministic (up to 6 distinct outputs for one input over 40 runs); the Python sorts. That is an improvement, but none of the 64 pinned G03 cases has more than one element block and there is no G03 or G09 golden elsewhere, so a regression in that ordering would go unnoticed. Add one multi-element G03 fixture. -
Long-help banner, modern branch.
rdStandardGBS.py:translator_mainbuilds the usage line from the code alias, sostd2Gaussian-16 --helpprintsUsage: std2gaus16 ...where Perl used the script's own name. The legacy branch already fixes this. Cosmetic and unpinned; no caller passes --help. -
The two branches conflict in
src/dsm/chemistry/TGBSConfig.Cand use different filesystem APIs. The modern branch includesutil/Filesystem.Hwithnamespace fs = ecce::fs;inside#ifdef _WIN32, matching the rest of the tree; the legacy branch adds a bare unconditional#include <filesystem>. Both edit the same ~10 lines ofdump(). Whichever lands second needs a hand merge, and the resulting interpreter test must list all six scripts. The modern branch's form is the one to keep. -
Stale paths.
scripts/parsers/README:92still listswrGaussian94GBS.pm, deleted by the legacy branch.docs/claude/codereg/a-gaussian-basis-keyword-needs-a-library-entry.md:6still namesscripts/parsers/wrGaussian16GBS.pmin itspaths:frontmatter -- that one defeats thegrep -rllookup CLAUDE.md requires before touching a file. -
Unverified. The verify vocabularies lose 130 and 127 lines (
Gaussian-16.words,Gaussian-09.words). What left is a dead element-name table and words harvested from long Perl comments, all legitimately gone, andbuild_vocabulary.py --checkpasses. But barepotentialbecomespotential\natGaussian-16.words:651while ECP decks emits potential, andtests/verifywas not run. An unknown token is documented to degrade to UNSURE rather than BAD, so the worst case is amber on ECP decks.
Separate question, worth settling before spending more on it: the legacy branch ports exporters for codes whose EDML lives in data/client/cap/disabled/. If the aim is that the client ships no Perl, a retired code's exporter could be deleted rather than ported.
- Lingua principale
- C
- Stelle
- 10
- Fork
- 8
- Merge medio
- 6h 32m
- PR unite (30g)
- 1
Preparare l'ambiente
Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di FriendsofECCE/ECCE
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
FriendsofECCE/ECCE#1358 ·
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
FriendsofECCE/ECCE#1353 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
FriendsofECCE/ECCE#1348 ·
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 76/100
FriendsofECCE/ECCE#1347 ·
-
bug
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
FriendsofECCE/ECCE#1345 ·
Tutte le issue di FriendsofECCE/ECCE
Issue simili
-
documentation
Difficoltà 2/5 1-3 ore Idoneità per principianti 84/100
Life-Framework/Life-Framework#5378 ·
I maintainer di solito rispondono entro 1 giorno
-
Bug Status: Needs Triage
Difficoltà 2/5 1-3 ore Idoneità per principianti 78/100
I maintainer di solito rispondono entro 1 giorno
-
bug status: planned ui
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
ChupathingyCE/chupathingyce#2126 ·
I maintainer di solito rispondono entro 1 giorno
-
good first issue simulation
Difficoltà 1/5 1-3 ore Idoneità per principianti 92/100
MarcosAsh/Lattice_Fluid_Dynamics#270 ·
I maintainer di solito rispondono entro 1 giorno
-
needs-kind
Difficoltà 1/5 Meno di un'ora Idoneità per principianti 82/100
falcosecurity/libs#3173 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno