Comments (5)
I don't see this char in the source code. Help is welcome, please.
it's in spanish addendums, which are in ISO-8859-15 charset. It's ó
in Traducción
.
It seems they correctly specify the addendum charset in po4a for Spanish, but po4a tries to read it in UTF-8 anyway... so it's probably a po4a's bug.
Besides that po4a probably should print some less cryptic error message with a reference to the file at least and maybe continue with the rest of the documents instead of straight up crashing...
To reproduce:
git clone https://salsa.debian.org/debian/debhelper.git
cd debhelper
po4a man/po4a/po4a.cfg
PS: po4a-translate
works fine:
po4a-translate -f pod -m dh_auto_build -l man/es/dh_auto_build.pod -p man/po4a/po/es.po -A ISO-8859-15 -a man/po4a/add3.es
from po4a.
Ok, I think I got it. I must have forgotten to use PerlIO on the filehandle that is in charge of the addendum. I'll look at it later on.
Many many thanks @Fat-Zer for this great diagnostic. You really rock.
from po4a.
I don't see this char in the source code. Help is welcome, please.
from po4a.
Ok, I nailed this down, I guess. The main issue was the po4a.cfg file which is not nice with us.
[po4a_alias:pod] pod opt_fr:"-L ISO-8859-15 -A UTF-8"
[po4a_alias:pod] pod opt_es:"-L UTF-8 -A ISO-8859-15"
[po4a_alias:pod] pod opt_de:"-L ISO-8859-15 -A UTF-8"
[po4a_alias:pod] pod opt_pt:"-L UTF-8 -A UTF-8"
[po4a_alias:pod] pod opt_ja:"-L UTF-8 -A UTF-8"
See how it's redefining the pod alias several times. I think that this was already broken in the past (only the last definition is kept) but before the introduction of PerlIO, the -A ISO-8859-15
was useless for some reason involving Perl trying to magically guess what to do.
I fixed this in commit 300208e197ce4e8a7692ed835f093abb8c07007b, but debhelper still fails with this error:
Malformed encoding while writing char '–' to file /tmp/debhelper/man/de/debhelper.pod with charset ISO-8859-15: "\x{2013}" does not map to iso-8859-15 at
This is because of the -L iso-8859-15
in the config file, which shouldn't be there since most languages of the list use UTF-8 chars that cannot be represented in Latin1. It used to work because all those -L parameters where wrongly discarded because of the previous bug. I guess that if you move the opt_fr
line after the opt_ja
one, it will fail as it is right now, because in that case, the request to write french files in Latin1 is not ignored anymore, and it fails because the french translation contains …
, the char representing 3 dots, that cannot be represented in Latin1.
I think that my code fixes this bug, but I leave it open for further discussion in case someone has a better idea.
from po4a.
Ok, nobody spoke out, so I'm closing the bug. Feel free to reopen on need.
from po4a.
Related Issues (20)
- Mb -> MB in the po4a-gettextize docs
- Weblate: Set a repository browser URL for po4a-doc HOT 5
- How to generate Markdown without line wrap? HOT 2
- seems update to po4a to 0.70 breaks builds of apt HOT 14
- seems update to po4a to 0.70 the alternate language man pages are no longer installed. HOT 5
- Accept-Languages + Accept on website returns incorrect languages HOT 3
- docbook: Multiline entities not translated HOT 3
- Failed to run 'po4a-gettextize' for 'sgml' format (Error while running onsgmls -p) HOT 2
- Feature Request: Keep maintaining 'po4a-xxx' utilities HOT 4
- #☑️
- Malformed encoding while writing to file <output> with charset utf-8: Unknown failure HOT 3
- Error while build v0.71 on openSUSE HOT 11
- Markdown tables not parsed properly
- Lots of warnings and errors when building texinfo-docs with po4a-traslated texinfo.texi HOT 1
- Is it possible to use translated (but outdated version) of changed paragraph in translated file? HOT 2
- second argument to Locale::Po4a::TransTractor::read now mandatory HOT 2
- Problem after PerlIO overhaul in v0.70 HOT 9
- Fails to build with perl 5.40 HOT 2
- Add custom placeholders for po4a componentes in Weblate HOT 5
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from po4a.