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

Extend .parse_item_description #138

Open
khaeru opened this issue Aug 4, 2023 · 0 comments
Open

Extend .parse_item_description #138

khaeru opened this issue Aug 4, 2023 · 0 comments
Labels
enh Enhancements & new features help welcome Issues that depend on contributions from new developers

Comments

@khaeru
Copy link
Owner

khaeru commented Aug 4, 2023

After the initial version added in #137 (per #133), looking at the Codelist=IMF:CL_AREA(1.15) specimen reveals some nuanced uses.

For each of these either improve the parser (if not too complex) or add an explicit statement in the docs (+ test) that such usage is not supported.

Also check:

  • SDMX guidelines to see if these usages are mentioned.
  • Item schemes from other data providers, to see if usage is similar or different.

Maybe support:

  1. Multiple lines.
    Search for matching lines among all those in the description, last-to-first; assert there is only one parseable line.
  2. Parenthetical comments:
    A1 - CA - CL (from 2010) - CO (from 2020) - MX - US
    
    These could be separated and returned as a third item in each tuple, e.g. (sub, "CL", "from 2010")
  3. Expressions following a more narrative description and a ";" on the same line:
    W12=sum of (ISO 3166-1 alpha-2) partner countries; W12=W1-1A-W19
    

Probably too complex:

  1. Parentheses:
    D5A = D5 - (BR + CA + CN + IN + JP + RU + CH +US)
    
  2. Ellipses:
    5AA+5B+…+5Z+7A+…7M
    
  3. Expressions in parentheses following text:
    Reference / counterpart area (W2.W0+W1.W2)
    
@khaeru khaeru added enh Enhancements & new features help welcome Issues that depend on contributions from new developers labels Aug 4, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enh Enhancements & new features help welcome Issues that depend on contributions from new developers
Projects
None yet
Development

No branches or pull requests

1 participant