Code Monkey home page Code Monkey logo

Comments (13)

jdrew82 avatar jdrew82 commented on June 23, 2024

Can you please provide the traceback? I need to know where in the code it's throwing the IndexError.

from nautobot-plugin-ssot-arista-cloudvision.

ksoufan avatar ksoufan commented on June 23, 2024

Below is the traceback, not sure if it's related to issue #116

Traceback (most recent call last):
File "/opt/nautobot/lib/python3.10/site-packages/nautobot_ssot/jobs/base.py", line 332, in run
self.sync_data()
File "/opt/nautobot/lib/python3.10/site-packages/nautobot_ssot/jobs/base.py", line 167, in sync_data
self.execute_sync()
File "/opt/nautobot/lib/python3.10/site-packages/nautobot_ssot/jobs/base.py", line 95, in execute_sync
self.source_adapter.sync_to(self.target_adapter, flags=self.diffsync_flags)
File "/opt/nautobot/lib/python3.10/site-packages/diffsync/init.py", line 546, in sync_to
target.sync_from(self, diff_class=diff_class, flags=flags, callback=callback, diff=diff)
File "/opt/nautobot/lib/python3.10/site-packages/diffsync/init.py", line 524, in sync_from
result = syncer.perform_sync()
File "/opt/nautobot/lib/python3.10/site-packages/diffsync/helpers.py", line 326, in perform_sync
changed |= self.sync_diff_element(element)
File "/opt/nautobot/lib/python3.10/site-packages/diffsync/helpers.py", line 366, in sync_diff_element
changed, modified_model = self.sync_model(src_model=src_model, dst_model=dst_model, ids=ids, attrs=attrs)
File "/opt/nautobot/lib/python3.10/site-packages/diffsync/helpers.py", line 415, in sync_model
dst_model = self.model_class.create(diffsync=self.dst_diffsync, ids=ids, attrs=attrs)
File "/opt/nautobot/lib/python3.10/site-packages/nautobot_ssot_aristacv/diffsync/models/nautobot.py", line 43, in create
site_code, role_code = nautobot.parse_hostname(ids["name"].lower())
File "/opt/nautobot/lib/python3.10/site-packages/nautobot_ssot_aristacv/utils/nautobot.py", line 127, in parse_hostname
if match.group("site"):
IndexError: no such group

from nautobot-plugin-ssot-arista-cloudvision.

ksoufan avatar ksoufan commented on June 23, 2024

@jdrew82 Were you able to find the issue in the nautobot model?

from nautobot-plugin-ssot-arista-cloudvision.

jdrew82 avatar jdrew82 commented on June 23, 2024

@ksoufan I've not had a chance to look into this one yet. I'll try to take a look today or tomorrow. It's a bit of an odd error. What do you have in your hostname_patterns setting? I'm going to guess that you don't have a capture group that has the site key.

from nautobot-plugin-ssot-arista-cloudvision.

ksoufan avatar ksoufan commented on June 23, 2024

Yep, the Nautobot instance is a fresh installed and trying to pull all from cloudvision.

from nautobot-plugin-ssot-arista-cloudvision.

jdrew82 avatar jdrew82 commented on June 23, 2024

@ksoufan Can you please share your settings for the plugin from nautobot_config.py?

from nautobot-plugin-ssot-arista-cloudvision.

jdrew82 avatar jdrew82 commented on June 23, 2024

Actually, nevermind. I've recreated this in my unit tests. It's definitely because there's no capture group in your hostname_patterns setting using the site key.

from nautobot-plugin-ssot-arista-cloudvision.

jdrew82 avatar jdrew82 commented on June 23, 2024

@ksoufan can you confirm if this is still an issue or not?

from nautobot-plugin-ssot-arista-cloudvision.

ksoufan avatar ksoufan commented on June 23, 2024

@jdrew82 I tried upgrading the plugin but I got the same version, how do I install this fix?

from nautobot-plugin-ssot-arista-cloudvision.

jdrew82 avatar jdrew82 commented on June 23, 2024

@ksoufan This would most likely be because a new release hasn't been cut yet. I'm working on having that done. Until that's done, you'll need to pull from the develop branch of this repo. There are steps on how you can do that detailed in my recent blog post: https://blog.networktocode.com/post/manage_nautobot_poetry/.

from nautobot-plugin-ssot-arista-cloudvision.

jdrew82 avatar jdrew82 commented on June 23, 2024

@ksoufan We've got a new release cut and pushed to PyPI so you should be able to install from there. That should address your issue and we can close this out.

from nautobot-plugin-ssot-arista-cloudvision.

qduk avatar qduk commented on June 23, 2024

@ksoufan did updating resolve your issue?

from nautobot-plugin-ssot-arista-cloudvision.

qduk avatar qduk commented on June 23, 2024

@ksoufan I'm closing this as there hasn't been a response in awhile. If there is still an issue, please open an issue on the aggregate nautobot-ssot app.

from nautobot-plugin-ssot-arista-cloudvision.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.