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

Error when location changes in NOTAMC #3

Open
data-al opened this issue May 27, 2021 · 2 comments
Open

Error when location changes in NOTAMC #3

data-al opened this issue May 27, 2021 · 2 comments
Assignees

Comments

@data-al
Copy link

data-al commented May 27, 2021

I saw there is an issue with the parser in the case when there is a NOTAMC with a change in the location, like for ex.:

import notam

issue_notam = '(H3501/20 NOTAMC H2368/20\nQ) CZXX/QAACN/IV/BO/E/035/050/5050N05947W155\nA) CZUL CZQX B) 2012312350\nE) L657: NUDOV TO SUSUB: INFO PUBLISHED)'

notam.Notam.from_str(issue_notam)

I get this error:

ParseError: Rule 'b_clause' didn't match at 'CZQX B) 2012312350 E' (line 3, column 9).

If i remove the second airport (like below) it works, so i guess the code doesn't handle these cases ? :

issue_notam = '(H3501/20 NOTAMC H2368/20\nQ) CZXX/QAACN/IV/BO/E/035/050/5050N05947W155\nA) CZUL B) 2012312350\nE) L657: NUDOV TO SUSUB: INFO PUBLISHED)'

@slavak slavak self-assigned this Jul 10, 2021
@slavak
Copy link
Owner

slavak commented Jul 10, 2021

Hi @data-al. Sorry it took me so long to see this.

The parser currently supports multiple locations in the A clause when they are separated by a slash ("/"). Re-checking the ICAO specification, it appears this is indeed incorrect and should be a whitespace.

I'll fix this momentarily.

@slavak
Copy link
Owner

slavak commented Jul 10, 2021

Fixed in PR #4. Let me know if this resolved your issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants