Parser error when using SCHED catalogs #13
bobeldering
started this conversation in
Known issues
Replies: 1 comment
-
A few more example of bad entries in the SCHED source catalog: The usage of
This leads to the following error message running pySCHED:
The usage of
This leads to the following (warning) message running pySCHED: |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Example sched.py output:
The error message is:
Error running pySCHED: /home/eldering/sched//catalogs/sources.gsfc line 16858: Unexpected RHS token Token(type_='misc', value="'1957+40", file_=<_io.TextIOWrapper name='/home/eldering/sched//catalogs/sources.gsfc' mode='r' encoding='UTF-8'>, line=16858)
The complete output of the pySCHED run is below:
Explanation of the error
pySCHED is designed to accept and process any valid SCHED input. However some SCHED (source) catalogs have missing quote closing characters. For example in the case above, one of the values of the SOURCE keyword is
'1957+40
(note the opening quote without the closing quote character). While SCHED does accept this (a newline implicitly ends a quoted string), the pySCHED parser does not accept this.Resolution
The pySCHED catalogs are continuously updated to track the SCHED catalogs, with the missing quote problem fixed. To use the pySCHED catalogs, remove the
$SCHED
environment variable from your shell, by running the following command:$ unset SCHED
When the
$SCHED
environment is not set, pySCHED will use the default location, where the pySCHED catalogs are downloaded to. You can also explicitly set this path:$ export SCHED=~/.pysched
Beta Was this translation helpful? Give feedback.
All reactions