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

submitted log parser throws an exception #2

Open
perillaroc opened this issue Jun 13, 2020 · 0 comments
Open

submitted log parser throws an exception #2

perillaroc opened this issue Jun 13, 2020 · 0 comments

Comments

@perillaroc
Copy link
Member

Log records may have some errors when ecflow server crash.

For example, two records are in the same line in the following logs.

MSG:[00:23:58 15.5.2020] chd:complete /gmf_grapes_gfs_post/12/upload/ftp_togrib2/upload_togrib2_global/upload_togrib2_039
LOG:[00:23:58 15.5.2020]  complete: /gmf_grapes_gfs_post/12/upload/ftp_togrib2/upload_togrib2_global/upload_togrib2_039
MSG:[00:23:58 15.5.2020] chd:complete /gmf_grapes_gfs_post/12/upload/ftp_togrib2/upload_togrib2_global/upload_togrib2_006
LOG:[00:23:58 15.5.2020]  complete: /gmf_grapes_gfs_post/12/upload/ftp_togrib2/upload_togrib2_global/upload_togrib2_006
LOG:[00:23:58 15.5.2020]  submitted: /gmf_grapes_gfs_post/12/upload/ftp_togrib2/upload_togrib2_global/upload_togrib2_054 job_size:9824MSG:[03:58:52 15.5.2020] Ecflow version(4.11.1) boost(1.53.0) compiler(gcc 4.8.5) protocol(TEXT_ARCHIVE) Compiled on Dec 25 2018 06:53:21
MSG:[03:58:52 15.5.2020] Started at 2020-May-15 03:58:52 universal time
MSG:[03:58:52 15.5.2020] Host(login_b01)  Port(31071) using TCP/IP v4
MSG:[03:58:52 15.5.2020] ECF_HOME /g1/u/nwp_pd/ecfworks/ecflow
MSG:[03:58:52 15.5.2020] Job scheduling interval: 60
MSG:[03:58:52 15.5.2020] Server initial state is HALTED
MSG:[03:58:52 15.5.2020] Loading check point file /g1/u/nwp_pd/ecfworks/ecflow/login_b01.31071.check port = 31071
MSG:[03:58:52 15.5.2020] Loading of *DEFS* check point file SUCCEDED. Loaded 0 suites

The parser for submitted will throw an exception:

ValueError: invalid literal for int() with base 10: '9824MSG:[03:58:52 15.5.2020] Ecflow version(4.11.1) boost(1.53.0) compiler(gcc 4.8.5) protocol(TEXT_ARCHIVE) Compiled on Dec 25 2018 06:53:21\n'

The exception should be checked or use another function to parse int from string.

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

1 participant