netbox-community / pynetbox

Python API client library for Netbox.
Apache License 2.0
580 stars 172 forks source link

object.update Not working for ip_Addresses #604

Closed jcresp21 closed 9 months ago

jcresp21 commented 9 months ago

pynetbox version

v7.3.3

NetBox version

v3.3.10

Python version

3.8

Steps to Reproduce

ip_public=nb.ipam.ip_addresses.get(address="xxxxxxx/32") I get the object and I can print all info from it with ip_public.address , .description, etc. If have tried several ways to do and update of the object of a save without success , same thing I have done in the past with other kind of objects, vm's, devices, clusters. etc.

    ipData=dict(
        description= "Updated description"
    )
    ip_public.update(ipData)

or ip_public.save() doesn't reflect any change in Netbox, and I see the timestamp of the object being "updated" in the GUI. So the request is getting there, but it simply doesn't change a thing.

Is this object not supported with get ? I have some other code where I create the ip_address or I delete it without problems. Thanks

Expected Behavior

Be able to make changes to IP addresses using the .get and .update or save methods.

Observed Behavior

No Exception ,simply changes are not reflected.

jcresp21 commented 9 months ago

I realized I was making the pynetbox.api with a http url, instead of https, the strange thing is that I could retrieve the object and list its attributes and even delete it, but I wasn't able to modify it or create new objects. It must be an incomtability with my reverse proxy. I swapped to https and everythin is working.