burr icon indicating copy to clipboard operation
burr copied to clipboard

Adds endpoints to debug what has been persisted

Open skrawcz opened this issue 1 year ago • 0 comments

This I think will be useful for production debugging; what's in my state?

This assumes:

  1. You have the right dependencies with the server to load the right persister.
  2. Not all persisters load via the constructor, so you can use a classmethod to be called to instantiate it.
  3. Haven't exposed writing to state, but it's something we could do.

We'd probably want to couple this with a UI view.

Changes

  • server run.py with two endpoints
  • adds pydantic models returned

How I tested this

  • not extensively, but it seems to work.

Notes

Checklist

  • [ ] PR has an informative and human-readable title (this will be pulled into the release notes)
  • [ ] Changes are limited to a single goal (no scope creep)
  • [ ] Code passed the pre-commit check & code is left cleaner/nicer than when first encountered.
  • [ ] Any change in functionality is tested
  • [ ] New functions are documented (with a description, list of inputs, and expected output)
  • [ ] Placeholder code is flagged / future TODOs are captured in comments
  • [ ] Project documentation has been updated if adding/changing functionality.

skrawcz avatar Jul 30 '24 06:07 skrawcz