relaton / relaton-itu

Relaton-ITU: retrieve ITU Standards for bibliographic use using the Relaton BibliographicItem model
https://www.relaton.org
MIT License
2 stars 1 forks source link

(URGENT) Unable to fetch ITU-T REC-T.4 #67

Closed ronaldtse closed 1 year ago

ronaldtse commented 1 year ago

Document: https://www.itu.int/rec/T-REC-T.4/en

This is needed by:

$ bundle exec relaton fetch "ITU-T REC T.4"
[relaton-itu] ("ITU-T REC T.4") fetching...
[relaton-itu] WARNING: no match found online for ITU-T REC T.4. The code must be exactly like it is on the standards website.
[relaton-itu] If you wanted to cite all document parts for the reference, use "ITU-T REC T.4 (all parts)".
If the document is not a standard, use its document type abbreviation (TS, TR, PAS, Guide).
No matching bibliographic entry found
$ bundle exec relaton fetch "ITU T-REC-T.4"
[relaton-itu] ("ITU T-REC-T.4") fetching...
[relaton-itu] WARNING: no match found online for ITU T-REC-T.4. The code must be exactly like it is on the standards website.
[relaton-itu] If you wanted to cite all document parts for the reference, use "ITU T-REC-T.4 (all parts)".
If the document is not a standard, use its document type abbreviation (TS, TR, PAS, Guide).
No matching bibliographic entry found
$ bundle exec relaton fetch "ITU-T REC-T.4"
[relaton-itu] ("ITU-T REC-T.4") fetching...
[relaton-itu] WARNING: no match found online for ITU-T REC-T.4. The code must be exactly like it is on the standards website.
[relaton-itu] If you wanted to cite all document parts for the reference, use "ITU-T REC-T.4 (all parts)".
If the document is not a standard, use its document type abbreviation (TS, TR, PAS, Guide).
No matching bibliographic entry found
$ bundle exec relaton fetch "ITU REC T.4"
[relaton-itu] ("ITU REC T.4") fetching...
[relaton-itu] WARNING: no match found online for ITU REC T.4. The code must be exactly like it is on the standards website.
[relaton-itu] If you wanted to cite all document parts for the reference, use "ITU REC T.4 (all parts)".
If the document is not a standard, use its document type abbreviation (TS, TR, PAS, Guide).
No matching bibliographic entry found
andrew2net commented 1 year ago

@ronaldtse itu.int can find only ITU-T T.4 not ITU-T REC T.4. We can remove REC from references. Is it good solution?

ronaldtse commented 1 year ago

@andrew2net It actually doesn't matter what itu.int finds, but what we accept.

The point of Relaton is to use a unified interface to obtain a machine-readable reference.

The idea that our document identifiers rely on the search results is not really correct.

Notice that when a user finds this page:

They can either do:

We should support all of these, as well as the individual versions:

andrew2net commented 1 year ago

@andrew2net It actually doesn't matter what itu.int finds, but what we accept.

The point of Relaton is to use a unified interface to obtain a machine-readable reference.

The idea that our document identifiers rely on the search results is not really correct.

@ronaldtse I agree. I'm talking about transforming input references. To fix this issue we can accept "ITU-T REC T.4", remove "REC", and then use the transformed reference "ITU-T T.4" to find a document. Isn't it that we need?

andrew2net commented 1 year ago

We should support all of these, as well as the individual versions:

What does the "I" at the end of the reference mean?

  • relaton fetch "ITU T-REC-T.4-200307"
  • relaton fetch "ITU-T REC-T.4-200307"
  • relaton fetch "ITU-T REC T.4-200307"
  • relaton fetch "ITU-T T.4-200307"

For such references we need to implement references an IDs parsing. I see we don't have pubid-itu yet, so I'm going to implement a temporary solution.

ronaldtse commented 1 year ago

To fix this issue we can accept "ITU-T REC T.4", remove "REC", and then use the transformed reference "ITU-T T.4" to find a document. Isn't it that we need?

Yes it is.

What does the "I" at the end of the reference mean?

I’m not sure. The I comes from the ID in the path. For a user who is able to find the page, they should just be able to use the ID directly to find the item via Relaton.

For such references we need to implement references an IDs parsing. I see we don't have pubid-itu yet, so I'm going to implement a temporary solution.

@mico can we start a new pubid-itu? Thanks!

andrew2net commented 1 year ago

fixed in v.1.14.3

andrew2net commented 1 year ago

@mico you can use pubid parser in pubid-itu

ronaldtse commented 1 year ago
  • relaton fetch "ITU T-REC-T.4"
  • relaton fetch "ITU-T REC-T.4"
  • relaton fetch "ITU-T REC T.4"
  • relaton fetch "ITU-T T.4"

@andrew2net the first three entries cannot be found:

$ bundle exec relaton fetch "ITU T-REC-T.4"
[relaton] (ITU T-REC-T.4) not found.
No matching bibliographic entry found
andrew2net commented 1 year ago

@ronaldtse it seems they are cached. Try

$ relaton db clear
Cache DB is cleared
$ relaton fetch "ITU T-REC-T.4"
[relaton-itu] ("ITU-T REC T.4") fetching...
[relaton-itu] ("ITU-T REC T.4") found ITU-T T.4
<bibdata type="standard" schema-version="v1.2.3">
...
ronaldtse commented 1 year ago

@andrew2net confirm that they work. Thanks.