relaton / relaton-iec

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

Unable to fetch "IEC/PAS 62596" #31

Closed ronaldtse closed 9 months ago

ronaldtse commented 3 years ago

https://webstore.iec.ch/publication/20742

But:

Screen Shot 2020-12-21 at 5 07 32 PM

So we should accept the syntax of "IEC/PAS XXXX" as well.

ronaldtse commented 1 year ago

Check if this has changed with #47 .

ronaldtse commented 9 months ago

For some reason this isn't working yet.

$ bundle exec relaton fetch "IEC/PAS 62596"
[relaton-iec] (IEC/PAS 62596) Fetching from Relaton repsitory ...
[relaton-iec] (IEC/PAS 62596) Not found.
[relaton-iec] (IEC/PAS 62596) TIP: If you wish to cite all document parts for the reference, use `IEC/PAS 62596 (all parts)`.
No matching bibliographic entry found
andrew2net commented 9 months ago

@ronaldtse the Harmonized API provides the document with IEC PAS 62596 ID. So to fetch it we should use:

$ relaton fetch --no-cache "IEC PAS 62596"
[relaton-iec] (IEC PAS 62596) Fetching from Relaton repsitory ...
[relaton-iec] (IEC PAS 62596) Found: `IEC PAS 62596:2009`
<bibdata type="standard" schema-version="v1.2.5">
...

I seems slash used to divide copublishers IEC/ISO, IEC/IEEE etc.

ronaldtse commented 9 months ago

I see. So I actually tried that after the first tried failed. However it says that the cache says it’s not found? Let me try again.

andrew2net commented 9 months ago

Yes, because in the relaton cache filenames are created from references. Slashes and spaces replaced with underscores. So the requests IEC PAS 62596 and IEC/PAS 62596 are stored in same file. It needs to clear DB by relaton DB clear.

Maybe we should replace slashes with hyphens?