Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Defensive treatment of i18n of edition numbers #549

Closed
opoudjis opened this issue Nov 29, 2023 · 5 comments
Closed

Defensive treatment of i18n of edition numbers #549

opoudjis opened this issue Nov 29, 2023 · 5 comments
Assignees
Labels
bug Something isn't working

Comments

@opoudjis
Copy link
Contributor

German document with an edition in metadata is crashing, because there is no German i18n of the edition number.

@opoudjis opoudjis added the bug Something isn't working label Nov 29, 2023
@opoudjis opoudjis self-assigned this Nov 29, 2023
@github-project-automation github-project-automation bot moved this to 🆕 New in Metanorma Nov 29, 2023
@opoudjis
Copy link
Contributor Author

There is an added bug: the ISO-specific YAML file is defaulting to English (no German ISO-specific YAML file is supplied), but an English file must not be merged into the parent non-English isodoc file.

@opoudjis
Copy link
Contributor Author

I'm going to address that by having a universal list of supported languages, and using that in all child flavours i18n.

opoudjis added a commit that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-iso that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-iso that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-iso that referenced this issue Nov 29, 2023
@opoudjis
Copy link
Contributor Author

In downstream flavours, if they don't have an i18n file for the given language, merge parent i18n into the local English file. That means that any locally needed i18n fields still exist (so compilation doesn't scratch), and it prevents parent German from being overridden with local English.

That said, the only proper outcome is to provide a local German i18n file.

opoudjis added a commit to metanorma/metanorma-iso that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-iec that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-ieee that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-ieee that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-ietf that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-itu that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-jis that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-ogc that referenced this issue Nov 29, 2023
opoudjis added a commit to metanorma/metanorma-un that referenced this issue Nov 29, 2023
@github-project-automation github-project-automation bot moved this from 🆕 New to ✅ Done in Metanorma Nov 29, 2023
@opoudjis opoudjis reopened this Nov 30, 2023
@github-project-automation github-project-automation bot moved this from ✅ Done to 🏗 In progress in Metanorma Nov 30, 2023
@opoudjis
Copy link
Contributor Author

Need to restrict load_yaml method to current class, else inheriting flavours will never see it. So super in metanorma-bsi needs to trigger ISO load_yaml, not BSI load_yaml.

opoudjis added a commit to metanorma/metanorma-iso that referenced this issue Nov 30, 2023
opoudjis added a commit to metanorma/metanorma-iso that referenced this issue Nov 30, 2023
@opoudjis
Copy link
Contributor Author

To avoid that behaviour, creating iso_load_file which is specific to ISO i18n, and is not to be overridden by child flavours; any flavour inherited by another flavour will need to do the same. alias_method would also have worked, but would have prevented a child of a child flavour from correct override behaviour.

@github-project-automation github-project-automation bot moved this from 🏗 In progress to ✅ Done in Metanorma Nov 30, 2023
opoudjis added a commit to metanorma/metanorma-ieee that referenced this issue Dec 4, 2023
opoudjis added a commit to metanorma/metanorma-ieee that referenced this issue Dec 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Archived in project
Development

No branches or pull requests

1 participant