-
Notifications
You must be signed in to change notification settings - Fork 178
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
feat(robot-server): show run time parameters in pending analysis #15229
Conversation
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.
Thank you! I know this is all a work in progress, but some suggestions so far:
protocol_resource=protocol_resource, | ||
run_time_param_values=parsed_rtp, | ||
) | ||
except BaseException as error: |
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.
I think we want to catch Exception
instead of BaseException
. As a heuristic: if something raises KeyboardInterrupt
or asyncio.CancelledError
, we do not want to swallow it.
I see that the ProtocolAnalyzer
internals are also currently catching BaseException
. I think those should be catching Exception
, too.
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.
Changes look good and make sense to me, and will make adding the "new file needed" analysis result much easier
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.
yay ty
) -> None: | ||
"""Initialize the analyzer and its dependencies.""" | ||
self._analysis_store = analysis_store | ||
self._protocol_resource = protocol_resource | ||
|
||
async def load_runner( |
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.
from discussion w/ @SyntaxColoring: making runner loading as a part of the analyzer initialization will help prevent misuse of load_runner()
, for example, calling load_runner()
multiple times.
I like this suggestion. Will take it into account when making the upcoming changes to the analysis arch.
Closes AUTH-282
Overview
Follow-up to #15217
This PR changes a pending analysis'
AnalysisSummary
to include the run time parameters (with overrides).In order to do this, we will now be parsing the RTPs before analysis response is created. This is a very quick process and shouldn't cause any perceptible delays in the response of neither
POST /protocols
norPOST /runs/.../analyses
endpoints, as long as recommended python protocol guidelines are followed.Test Plan
POST
request on/protocols/{protocolId}/analyses
endpoint with different RTP values, or by specifying theforceReanalysis
flag, and verify that the newly pending analysis also contains (updated) RTPsGET
endpoints also contain RTPsChangelog
AnalysesManager
. The analyses manager is responsible for creating a protocol analyzer per analysis, extracting the run time parameters from the runner and starting the analysis.ProtocolAnalyzer
has been divided into two functions- one that loads the runner and other that runs the runner.AnalysesManager
for starting analyses instead of directly interacting withProtocolAnalyzer
.Review requests
AnalysesManager
& updatedProtocolAnalyzer
makes sense.Would like to get others' opinions on this.
Risk assessment