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

Update docidentifier #154

Closed
1 of 2 tasks
Intelligent2013 opened this issue Oct 27, 2022 · 19 comments
Closed
1 of 2 tasks

Update docidentifier #154

Intelligent2013 opened this issue Oct 27, 2022 · 19 comments
Assignees
Labels
bug Something isn't working enhancement New feature or request

Comments

@Intelligent2013
Copy link
Contributor

Intelligent2013 commented Oct 27, 2022

Source issue: #153 (comment)

  • no need to put ED x in the docidentifier.

Original PDF:
image

Resulted PDF:
image

Metanorma presentation XML:

<docidentifier type="ISO">ISO/IEC/TR 30167 ED 1</docidentifier>

Example adoc:

= Internet of things
:docnumber: 30167
:publisher: ISO;IEC
:copyright-holder: ISO;IEC
:tc-docnumber: 17301
:edition: 1
:revdate: 2021-06-01
:copyright-year: 2021
:language: en
:title-intro-en: Internet of things (IoT)
:title-main-en: Underwater communication technologies for IoT
:doctype: technical-report
:docstage: 60
:docsubstage: 92
...
  • add docidentifier with year into XML (rendering on page header)

Original PDF:
image

document.adoc example:

= Smart manufacturing standards map
:docnumber: 63306
:partnumber: 1
:publisher: ISO;IEC
:copyright-holder: ISO;IEC
:tc-docnumber: 17301
:edition: 1
:revdate: 2020-12-01
:copyright-year: 2020
:language: en
:title-intro-en: Smart manufacturing standards map (SM2)
:title-part-en: Framework
:doctype: technical-report
:docstage: 60
:docsubstage: 92
...
@Intelligent2013
Copy link
Contributor Author

Intelligent2013 commented Oct 27, 2022

  • add docidentifier with year and month into XML (rendering on cover page, left side)

Original PDF:
image

Currently, IEC XSLT reads the data from bibdata/docidentifier[@type = 'iso-with-lang'].

@Intelligent2013
Copy link
Contributor Author

UPDATE: if document is multi-language, then lang codes delimit by -.
image

@ronaldtse
Copy link
Contributor

UPDATE: if document is multi-language, then lang codes delimit by -.
image

This looks relevant to pubid-iec! Let me file this issue there too.

@opoudjis
Copy link
Contributor

opoudjis commented Oct 29, 2022

This is all relevant to pubid-iec. There is contradictory advice from IEC on identifiers (I put ED in on IEC advice at the time), and I'm not going to change my code to deal with it: there needs to be a single source of truth about identifiers, and that is pubid-iec.

@opoudjis
Copy link
Contributor

Issue put on hold, pending implementation of it in pubid-iec

@ronaldtse
Copy link
Contributor

This is all relevant to pubid-iec. There is contradictory advice from IEC on identifiers (I put ED in on IEC advice at the time), and I'm not going to change my code to deal with it: there needs to be a single source of truth about identifiers, and that is pubid-iec.

While two of these are bugs in pubid-iec, the problem in Metanorma is that:

  1. There are multiple pubid manifestations of a document (with edition, with year no edition), these are used in various places in the rendering
  2. PDF needs to select the proper pubid manifestation provided in the XML

If Metanorma XML does not provide the pubid manifestations, we cannot choose the correct identifiers in the PDF rendering process.

@opoudjis
Copy link
Contributor

The variants still need to come from a single source of truth, and that source of truth is pubid-iec. If that gem exists, any modifications in metanorma-iec not using pubid-iec are a temporary kludge

@ronaldtse
Copy link
Contributor

The variants still need to come from a single source of truth, and that source of truth is pubid-iec. If that gem exists, any modifications in metanorma-iec not using pubid-iec are a temporary kludge

Yes, we need to have issues resolved in pubid-iec. I don't know if metanorma-iec/relaton-iec currently utilize pubid-iec.

@opoudjis
Copy link
Contributor

metanorma-iec currently does not. I'm saying, I shouldn't invest the effort, if pubid-iec is coming (at a reasonable timeframe).

@opoudjis
Copy link
Contributor

pubid-iec is still under active development...

@opoudjis
Copy link
Contributor

opoudjis commented Jun 7, 2023

Seems to have settled.

opoudjis added a commit to metanorma/metanorma-iso that referenced this issue Jun 22, 2023
opoudjis added a commit that referenced this issue Jun 22, 2023
@opoudjis
Copy link
Contributor

Have adopted pubid-iec

@opoudjis
Copy link
Contributor

opoudjis commented Jun 25, 2023

  • no need to put ED x in the docidentifier.

If you specify

:edition: 1

You will get:

<docidentifier type="ISO">ISO/IEC TR 30167:2021 ED1</docidentifier>

If you do not specify an edition at all, you will get:

<docidentifier type="ISO">ISO/IEC TR 30167:2021</docidentifier>

Strongly suggest, @Intelligent2013, this is correct behaviour: I have removed the default setting of editions to 1.

If ED1 is wrong, please raise an issue with pubid-iec

If you want two identifiers, one with the edition and one without, let me know.

@opoudjis
Copy link
Contributor

  • add docidentifier with year into XML (rendering on page header)
<docidentifier type="ISO">ISO/IEC TR 63306-1:2020</docidentifier>
<docidentifier type="iso-undated">ISO/IEC TR 63306-1</docidentifier>

@opoudjis
Copy link
Contributor

add docidentifier with year and month into XML (rendering on cover page, left side)

This is a brand new requirement. Following your sample header, I will only provide it if revdate is populated, as type iso-revdate.

<docidentifier type="iso-revdate">ISO/IEC TR 63306-1:2020-12(en)</docidentifier>

I am ignoring days, per your example; let me know if I should not.

@opoudjis
Copy link
Contributor

Intelligent2013 added a commit to metanorma/mn-native-pdf that referenced this issue Jun 25, 2023
Intelligent2013 added a commit to metanorma/mn-native-pdf that referenced this issue Jun 25, 2023
@Intelligent2013
Copy link
Contributor Author

IEC XSLT updated for <docidentifier type="iso-revdate"> and docidentifier type="iso-undated".

@opoudjis
Copy link
Contributor

Now pending metanorma/pubid-iec#127

@opoudjis
Copy link
Contributor

Now pending metanorma/pubid-cen#19

opoudjis added a commit that referenced this issue Feb 5, 2024
@opoudjis opoudjis closed this as completed Feb 5, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working enhancement New feature or request
Projects
Status: Done
Development

No branches or pull requests

3 participants