-
Notifications
You must be signed in to change notification settings - Fork 0
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
Eiger exts logic #54
Eiger exts logic #54
Conversation
93f8a2d
to
6e70a9e
Compare
6e70a9e
to
e24721c
Compare
|
||
def __getitem__(self, key: str) -> Any: # noqa: D105 | ||
f = {} | ||
for field_ in fields(self): | ||
f[field_.name] = vars(self)[field_.name] | ||
f[field_.name] = { |
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.
Can we cache this value?
Or else calculate it without the intermediate object?
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.
device: EigerStream | ||
|
||
@HTTPEndpoint.get(f"/{STREAM_API}" + "/status/{param}") | ||
async def get_stream_status(self, request: web.Request) -> web.Response: |
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.
Are we no longer exposing this endpoint?
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.
It was moved into eiger_adapters.py
. I replaced multiple inheritance with one big class.
from apischema import serialized | ||
from apischema.fields import with_fields_set | ||
from apischema.metadata import skip | ||
from apischema.serialization import serialize |
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.
apischema? I'll look into whether this can be pulled out easily
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.
Have pulled it out
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.
As discussed, pulling this out proved to be more complicated than expected and caused upstream issues with the IOC. It will require a proper look to debug and test those differences. For now I have reset and left this internal use of apischema in. WIP on pulling out here: #66
b43bde6
to
32d06b4
Compare
Fixes #53
Changes: