-
Notifications
You must be signed in to change notification settings - Fork 1
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
Setup script changes and misc bug fixes #64
Conversation
hl7 waveform when running validation. Some refactoring to make testing better.
PR checklistDefault guide for a PR (if multiple PRs for the work, only keep one version of it and link to it on the other PRs)
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
not looked at the Java but the Python changes LGTM 🚀
emap-setup/emap_runner/runner.py
Outdated
use_hoover = ("hoover" in self.global_config["repositories"]) and (not self.args.use_only_hl7_reader) | ||
use_hoover = ("hoover" in self.global_config["repositories"]) and self.args.use_hoover |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
perhaps this should be
if self.args.use_hoover and "hoover" not in self.global_config["repositories"]:
raise ValueError("hoover missing from repositories in global config")
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ah yes, that avoids failing silently if the user asked for hoover
"""Time elapsed since the runner started""" | ||
return timedelta(seconds=time() - self.start_time) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🙃
Probably best to change the type of start_time
to datetime.datetime
then
"""Time elapsed since the runner started""" | |
return timedelta(seconds=time() - self.start_time) | |
"""Time elapsed since the runner started""" | |
assert self.start_time is not None | |
return datetime.now() - self.start_time |
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since start_time
isn't needed outside that method I've turned it into a local. And it should be a monotonic clock to ignore system time jumps.
Setup script changes for validation (including fixing #25 )
Design doc update.
Miscellaneous fixes that were needed to process the HL7 dump file during validation. Mostly parsing error handling.