pcdshub / nabs

Not a Beamline Scientist
https://pcdshub.github.io/nabs
Other
3 stars 7 forks source link

ENH: Add ELog posting callback #53

Closed tangkong closed 2 years ago

tangkong commented 2 years ago

Description

Adds a callback that posts bluesky run information to the ELog automatically. Currently posts last ipython input at run start, and a copy of the run table as html at run stop

Motivation and Context

JIRA ticket

How Has This Been Tested?

Interactively, with new test added to test suite Test posts to devlgbk pcds-5.2.0, pcds-5.2.1

Screen Shot 2022-02-16 at 2 08 29 PM

Where Has This Been Documented?

Some docstrings, including example usage.

Pre-merge checklist

tangkong commented 2 years ago

Some significant changes here, with much inspiration taken from bluesky's LiveTable callback with regards to formatting. Failures shouldn't halt operation, but I think testing with real beamline devices and a real experiment elog would be nice.

tangkong commented 2 years ago

I would mark this as "Approve" but you have a good number of TODOs in there. Are you going to tackle them now or in a follow-up PR?

My intent was to address those in a follow up PR, if we determined that kind of functionality was wanted/needed. A lot of the to-do items are inspired from flexiblity the LiveTable callback has, but may not be necessary for this callback. (I thought)