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

Ensure device symmetricNAT field is updated #1957

Closed
wants to merge 1 commit into from

Conversation

vishnoianil
Copy link
Contributor

with add/update device requests

Openapi client generates the model with json tag
omitempty, that removes the symmetricNAT flag in
the json request body if it's false.

Fixes: #1956

Copy link

netlify bot commented Mar 6, 2024

Deploy Preview for nexodus-docs canceled.

Name Link
🔨 Latest commit fc89e76
🔍 Latest deploy log https://app.netlify.com/sites/nexodus-docs/deploys/65e81a8267a8870009c77885

@vishnoianil vishnoianil force-pushed the symnat-flag branch 3 times, most recently from 3345ba5 to 16ecc0f Compare March 6, 2024 06:57
with add/update device requests

Openapi client generates the model with json tag
omitempty, that removes the symmetricNAT flag in
the json request body if it's false.

Signed-off-by: Anil Kumar Vishnoi <[email protected]>
@chirino
Copy link
Member

chirino commented Mar 6, 2024

I don't think this will fix the problem. The issue is in the generated OpenAPI client models.

When I PATCH path "/api/devices/${device_id}" with json body:
"""
{
"symmetric_nat": false
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In my testing, this was not present in the request at all

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah.. this PR changes AddDevice model, but that's not used in the PATCH operation.

@chirino
Copy link
Member

chirino commented Mar 6, 2024

fixed in #1958`

@chirino chirino closed this Mar 6, 2024
@vishnoianil vishnoianil deleted the symnat-flag branch March 6, 2024 18:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

SymmetricNAT is never set back to false for a device
3 participants