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

Mistake in NetBoxScanner class #29

Open
inetman opened this issue Jan 24, 2021 · 0 comments
Open

Mistake in NetBoxScanner class #29

inetman opened this issue Jan 24, 2021 · 0 comments

Comments

@inetman
Copy link

inetman commented Jan 24, 2021

Issue

When I tried to create ip-address netbox with below:

            self.netbox.ipam.ip_addresses.create(
                address=host[0],
                tags=[{"name": self.tag}],
                # dns_name=host[1],
                description=host[1]
            )

I got a error:
pynetbox.core.query.RequestError: The request failed with code 400 Bad Request: {'tags': ['All list items must be of string type.']}

How does it solve?

we have to change dict inside list to simple list without dict
#tags=[{"name": self.tag}],
with
tags=[self.tag],

Proof

изображение

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant