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

Protocol Engine: return protocol metadata on protocol file upload #8003

Closed
2 tasks
mcous opened this issue Jun 24, 2021 · 0 comments · Fixed by #8274
Closed
2 tasks

Protocol Engine: return protocol metadata on protocol file upload #8003

mcous opened this issue Jun 24, 2021 · 0 comments · Fixed by #8274
Assignees
Labels
protocol-engine Ticket related to the Protocol Engine project and associated HTTP APIs robot-svcs Falls under the purview of the Robot Services squad (formerly CPX, Core Platform Experience).
Milestone

Comments

@mcous
Copy link
Contributor

mcous commented Jun 24, 2021

Overview

As a user of the new ProtocolEngine-based upload-and-run system, I'd like to know metadata about my protocol when I upload it to my OT-2, so that I can better understand what I'm about to run.

In this case, "metadata" includes any of the following, if available:

  • Filename(s) of the protocol
  • Name (as in "title") of the protocol
  • Author
  • Description
  • Last modification date
  • Python Protocol API version
  • JSON Protocol Schema version
  • Protocol Designer version

Acceptance criteria

  • Protocol engine POST & GET /protocols response models include metadata listed above
  • (Internal) protocol resource model includes API version / schema version for correct simulation/run mechanics

Implementation details

  • The metadata items listed are based on the information that the Opentrons App currently displays for RPC-uploaded protocols
  • For JSON protocols, this is a straightforward parsing of the JSON
  • For Python protocols, we should probably maintain our current strategy of inspecting the syntax tree for the metadata module variable
    • We could choose to from protocol_file import metadata or something similar
    • However, due to the likelihood of import side-effects, static analysis is safer
  • Last modification date is only really meaningful for JSON protocols, where this is encoded in data
    • Only the client would know when a Python file was last touched, so don't worry about it in the HTTP API
@mcous mcous added robot-svcs Falls under the purview of the Robot Services squad (formerly CPX, Core Platform Experience). protocol-engine Ticket related to the Protocol Engine project and associated HTTP APIs labels Jun 24, 2021
@mcous mcous added this to the CPX Sprint 38 milestone Jul 27, 2021
@SyntaxColoring SyntaxColoring self-assigned this Aug 19, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
protocol-engine Ticket related to the Protocol Engine project and associated HTTP APIs robot-svcs Falls under the purview of the Robot Services squad (formerly CPX, Core Platform Experience).
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants