Bad characters in generated HTML policy list. |
||
Issue descriptionAs mentioned in emaxx' comment in https://chromium-review.googlesource.com/c/chromium/src/+/632058 , the generated policy list contains invalid charcters when viewed in a web browser (chrome). As the file is valid UTF-8 now, I suspect that this is a wrong encoding setting or due to bad handling when processing the files (replacing placeholders, generating html..)
,
Oct 9 2017
Generated the Policy Templates doc with the CL above applied. Old output: https://sites.google.com/a/chromium.org/dev/system/app/pages/admin/compare?wuid=wuid:gx:7eda57d8c86914e&rev1=126 e.g.: Microsoft® Active Directory® New output: https://sites.google.com/a/chromium.org/dev/administrators/policy-list-3 e.g. Microsoft® Active Directory® domain
,
Oct 20 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/ed86c1e677e86176eb9e6eb1a420ea7460976261 commit ed86c1e677e86176eb9e6eb1a420ea7460976261 Author: Pavol Marko <pmarko@chromium.org> Date: Fri Oct 20 09:00:09 2017 Mark nontranslateable string in policy_templates.json One instance of "Microsoft(R) Active Directory(R)" was not marked as nontranslateable with <ph> tags. This CL fixes that. BUG= 758836 Change-Id: Id676deb914798354068069a2d3a105af8492e496 Reviewed-on: https://chromium-review.googlesource.com/729862 Reviewed-by: Julian Pastarmov <pastarmovj@chromium.org> Commit-Queue: Pavol Marko <pmarko@chromium.org> Cr-Commit-Position: refs/heads/master@{#510382} [modify] https://crrev.com/ed86c1e677e86176eb9e6eb1a420ea7460976261/components/policy/resources/policy_templates.json
,
Nov 2 2017
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/0c61a1ebc26599b4a980d794e8c050f226d578b4 commit 0c61a1ebc26599b4a980d794e8c050f226d578b4 Author: Pavol Marko <pmarko@chromium.org> Date: Thu Nov 02 16:29:51 2017 Treat policy_templates.json as utf-8 encoded when translating Set the encoding of the policy_templates.json input file to utf-8. Until now, its encoding was not specified in the translation definition (grd file), which resulted in a default cp1252 encoding, leading to bad characters in the output (and transitively in all generated artifacts, including HTML policy docs, ADM/ADMX/ADML files, plist files, ..). Note that we're not touching the encoding of grit's output files, so the processing chain will now be: policy_templates.json (utf-8) --(expect utf-8)--> grit --(write utf-16)--> policy_templates_<lang>.json (utf-16) --(expect utf-16)--> template_formatter.py --(write encoding(X))--> X=doc/admx/plist/.. The mismatch was that while policy_templates.json was encoded in utf-8, grit expected utf-16 input encoding. BUG= 758836 TEST=Generated policy documentation (gn target policy_templates) and verified that special characters are treated properly. Change-Id: I266a15b2ce78490ce9676905c105f20dfafbdfca Reviewed-on: https://chromium-review.googlesource.com/707101 Commit-Queue: Pavol Marko <pmarko@chromium.org> Reviewed-by: Maksim Ivanov <emaxx@chromium.org> Cr-Commit-Position: refs/heads/master@{#513512} [modify] https://crrev.com/0c61a1ebc26599b4a980d794e8c050f226d578b4/components/policy/resources/policy_templates.grd
,
Nov 2 2017
|
||
►
Sign in to add a comment |
||
Comment 1 by pmarko@chromium.org
, Oct 9 2017