Replies: 1 comment
-
I'm confused about what exactly it is you're trying to do that you're unable to. It sounds like you're able to get a You then say you aren't able to parse it because of
|
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hello, having a bit of trouble with parsing attr Model. I'm mostly using pydantic models and now I'm a little confused with attrs Models.
Having models like
which are after client generation converted into:
My main goal is to generate appilcation client with models that can be used in another applications for obvious reasons. For example when I'm about to use generated function
create_measurement.sync(client=CLIENT, json_body=data)
. But as I understoodjson_body
needs to have theCreateMeasurementBodyParams
Model. Which is fine and I understand. But what is the proper way of parsing a dictionary into this Model whenadditional_properties
are added into every Model and SubModel?I have an example:
Here I'm just creating a dictionary which is suitable for the CreateMeasurementBodyParams (or at least for pydantic model it would be). But then I'm not able to parse it bcs of the
additional_proparties
that are added to the model when generated and I'm not able to usecreate_measure.sync
GENERATED function bcs I'm not able to pass data into it. What am I doing wrong?Beta Was this translation helpful? Give feedback.
All reactions