relaton / relaton-iec

IecBib: retrieve IEC/CIE Standards for bibliographic use using the BibliographicItem model
MIT License
1 stars 0 forks source link

(URGENT) Failure in fetching IEC SRC documents due to document type typo #49

Closed ronaldtse closed 1 year ago

ronaldtse commented 1 year ago
$ relaton fetch "IEC SRD 63188:2022"
[relaton-iso-bib] WARNING: invalid doctype: system-reference-delivrabble
[relaton-iso-bib] Allowed doctypes are: international-standard, technical-specification, technical-report, publicly-available-specification, international-workshop-agreement, guide, amendment, technical-corrigendum, directive
<bibdata type="standard" schema-version="v1.2.1">
  <fetched>2022-12-22</fetched>
  <title type="title-main" format="text/plain" language="en" script="Latn">Smart Cities Reference Architecture Methodology</title>
  <title type="main" format="text/plain" language="en" script="Latn">Smart Cities Reference Architecture Methodology</title>
  <uri type="src">https://webstore.iec.ch/publication/62092</uri>
  <uri type="obp">/preview/info_iecsrd63188%7Bed1.0%7Den.pdf</uri>
  <docidentifier type="IEC" primary="true">IEC SRD 63188:2022</docidentifier>
  <docidentifier type="URN">urn:iec:std:iec:63188:2022:srd::en</docidentifier>
  <date type="published">
    <on>2022-09-06</on>
  </date>
  <contributor>
    <role type="publisher"/>
    <organization>
      <name>International Electrotechnical Commission</name>
      <abbreviation>IEC</abbreviation>
      <uri>www.iec.ch</uri>
    </organization>
  </contributor>
  <edition>1.0</edition>
  <language>en</language>
  <script>Latn</script>
  <abstract format="text/plain" language="en" script="Latn">The Smart Cities Reference Architecture Methodology (SCRAM) proposes a common methodology for developing the Smart Cities Reference Architecture (SCRA), which is a tailorable template for architectures of, practically, any city system. SCRAM reviews and defines the desired characteristics of Smart Cities, diverse SCRA viewpoints and corresponding SCRA model types in order to promote consistency and uniformity across architectures for various smart cities.</abstract>
  <status>
    <stage>60</stage>
    <substage>60</substage>
  </status>
  <copyright>
    <from>2022</from>
    <owner>
      <organization>
        <name>International Electrotechnical Commission</name>
        <abbreviation>IEC</abbreviation>
        <uri>www.iec.ch</uri>
      </organization>
    </owner>
  </copyright>
  <place>Geneva</place>
  <ext schema-version="v1.0.0">
    <doctype>system-reference-delivrabble</doctype>
    <editorialgroup>
      <technical-committee type="technicalCommittee">SyC Smart Cities - Electrotechnical aspects of Smart Cities</technical-committee>
    </editorialgroup>
    <ics>
      <code>13.020.20</code>
      <text>Environmental economics. Sustainability</text>
    </ics>
    <ics>
      <code>03.100.70</code>
      <text>Management systems</text>
    </ics>
    <structuredidentifier type="IEC">
      <project-number>63188</project-number>
    </structuredidentifier>
  </ext>
</bibdata>

Notice system-reference-delivrabble contains a typo.

This is affecting https://github.com/metanorma/SWF-Corpus_and_IEEEP2874-D2 "main" branch.

ronaldtse commented 1 year ago

We need to add a test case for IEC SRDs.

andrew2net commented 1 year ago

@ronaldtse it's fixed in v 1.14.1

ronaldtse commented 1 year ago

Thank you!

ronaldtse commented 1 year ago

@andrew2net I'm still seeing the error with relaton-iec 1.14.1. Is the problem with relaton-data-iec that needs to be refreshed?

andrew2net commented 1 year ago

@ronaldtse please try to clean relaton cache relaton db clean

ronaldtse commented 1 year ago

@andrew2net is the command relaton db clear?

$ relaton db clean

Could not find command "clean".
Did you mean?  "clear"
Deprecation warning: Thor exit with status 0 on errors. To keep this behavior, you must define `exit_on_failure?` in `Relaton::Cli::Command`
You can silence deprecations warning by setting the environment variable THOR_SILENCE_DEPRECATION.
ronaldtse commented 1 year ago

I used relaton db clear and it worked.

$ relaton fetch "IEC SRD 63188:2022"
[relaton-iec] ("IEC SRD 63188") fetching...
[relaton-iec] ("IEC SRD 63188") found IEC SRD 63188:2022
<bibdata type="standard" schema-version="v1.2.1">
  <fetched>2023-01-18</fetched>

Thanks!