Excited-state parsers: errors="replace" and Perl byte passthrough differ for a stray byte inside a captured label (#868)
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Facilidade para iniciantes
- 15/100
Direção de pesquisa
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.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
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.
- Linguagem predominante
- C
- Estrelas
- 10
- Forks
- 8
- Merge médio
- 6h 32min
- PRs com merge (30d)
- 1
Preparar o ambiente
Este projeto não oferece contêiner de desenvolvimento, Dockerfile nem guia de contribuição, então a configuração fica por sua conta: comece pelo README e veja nosso guia da primeira contribuição para os passos gerais.
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de FriendsofECCE/ECCE
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
FriendsofECCE/ECCE#1358 ·
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
FriendsofECCE/ECCE#1353 ·
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
FriendsofECCE/ECCE#1348 ·
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 76/100
FriendsofECCE/ECCE#1347 ·
-
bug
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 72/100
FriendsofECCE/ECCE#1345 ·
Todas as issues de FriendsofECCE/ECCE
Issues semelhantes
-
documentation
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 84/100
Life-Framework/Life-Framework#5378 ·
Mantenedores costumam responder em até 1 dia
-
Bug Status: Needs Triage
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
Mantenedores costumam responder em até 1 dia
-
bug status: planned ui
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 70/100
ChupathingyCE/chupathingyce#2126 ·
Mantenedores costumam responder em até 1 dia
-
good first issue simulation
Dificuldade 1/5 1-3 horas Facilidade para iniciantes 92/100
MarcosAsh/Lattice_Fluid_Dynamics#270 ·
Mantenedores costumam responder em até 1 dia
-
needs-kind
Dificuldade 1/5 Menos de uma hora Facilidade para iniciantes 82/100
falcosecurity/libs#3173 · 1 comentário ·
Mantenedores costumam responder em até 1 dia