Excited-state parsers: errors="replace" and Perl byte passthrough differ for a stray byte inside a captured label (#868)
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Accessibilité débutants
- 15/100
Piste de recherche
Start with the Gaussian 16 excited-state parser: the Excited State n: label is captured with (.*?) and written to EXCISYM, and the committed fixture is tests/parsers/fixtures/gaussian-16/h2co_tddft_stray_in_state.log. Compare the Python output against the Perl original on origin/main for that fixture. The work is blocked on a maintainer decision between keeping U+FFFD and reproducing raw bytes with surrogateescape, so do not register the case until that is settled.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
The Python ports of the excited-state parsers (#868) decode job output with errors="replace"; the Perl originals read bytes. A stray invalid byte on a line no pattern matches is harmless in both. It matters only inside a matched line.
Tested with fixtures derived from h2co_tddft (tests/parsers/fixtures/{gaussian-16/h2co_tddft_stray_in_state.log,orca/h2co_tddft_stray_in_state.out}), original Perl from origin/main against the Python on the branch:
- ORCA (
orca.excited): bytes placed in the\S+fields of aSTATE n:line, a transition line and a spectrum row. No capture group can hold a byte, so output is byte-identical to Perl and to the clean fixture. Registered asorca-h2co-tddft-stray-in-state; the golden is byte-identical to the one the Perl produces. - Gaussian 16 (
gaussian-16.excited): bytes placed in theExcited State n:label, which is captured with(.*?)and written toEXCISYM. They differ: Perl writes the raw byte (0xFF, 0xFE); Python writes U+FFFD (EF BF BD per byte). Everything else in the output is identical.
Open decision: keep U+FFFD (valid UTF-8 downstream, loses the original byte) or reproduce Perl's raw bytes (needs errors="surrogateescape" on stdin and stdout, and puts invalid UTF-8 into a property value). The G16 fixture is committed but not registered as a case until this is decided.
Related: a valid UTF-8 non-breaking space (C2 A0) matches \s in Python text mode but not in Perl's byte regexes. Not covered by these fixtures.
Branch: cx/868-excited.
- Langage dominant
- C
- Étoiles
- 10
- Forks
- 8
- Merge moyen
- 6 h 32 min
- PR mergées (30 j)
- 1
Préparer son environnement
Ce projet ne fournit ni conteneur de développement, ni Dockerfile, ni guide de contribution : l'installation est à votre charge. Commencez par son README, et consultez notre guide de la première contribution pour les étapes générales.
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de FriendsofECCE/ECCE
-
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
FriendsofECCE/ECCE#1358 ·
-
bug
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
FriendsofECCE/ECCE#1353 ·
-
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
FriendsofECCE/ECCE#1348 ·
-
Difficulté 2/5 1-3 heures Accessibilité débutants 76/100
FriendsofECCE/ECCE#1347 ·
-
bug
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
FriendsofECCE/ECCE#1345 ·
Toutes les issues de FriendsofECCE/ECCE
Issues similaires
-
documentation
Difficulté 2/5 1-3 heures Accessibilité débutants 84/100
Life-Framework/Life-Framework#5378 ·
Les mainteneurs répondent en général sous 1 jour
-
Bug Status: Needs Triage
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
Les mainteneurs répondent en général sous 1 jour
-
bug status: planned ui
Difficulté 2/5 1-3 heures Accessibilité débutants 70/100
ChupathingyCE/chupathingyce#2126 ·
Les mainteneurs répondent en général sous 1 jour
-
good first issue simulation
Difficulté 1/5 1-3 heures Accessibilité débutants 92/100
MarcosAsh/Lattice_Fluid_Dynamics#270 ·
Les mainteneurs répondent en général sous 1 jour
-
needs-kind
Difficulté 1/5 Moins d'une heure Accessibilité débutants 82/100
falcosecurity/libs#3173 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour