Code Monkey home page Code Monkey logo

Comments (8)

kingfetty avatar kingfetty commented on July 29, 2024

After the correction of using a string to using self.device_type the code now fails at load_interfaces() because there is a block attempting to read the variable device_specs before it is assigned. This is due to the fact that the variable is created inside an if block that checks if a yaml file exists and the reference to the variable is outside this if block.

from nautobot-app-ssot.

kingfetty avatar kingfetty commented on July 29, 2024

Also appears Sync Job is using default soft timeout limit of 5 minutes which is way too short for a sync job. This should be updated in the jobs.py meta to be at least several hours.

from nautobot-app-ssot.

ShivaniMauryaIntel avatar ShivaniMauryaIntel commented on July 29, 2024

I had the same issue. If the issue is fixed, do we need to reinstall the ssot plugin ?

from nautobot-app-ssot.

ShivaniMauryaIntel avatar ShivaniMauryaIntel commented on July 29, 2024

@jdrew82 I have reinstalled the ssot plugin & ran the aci sync job again. The job is still failing & a new error is coming now -
"exc_message": [
"ltd"]
where "ltd" is the identifier used in my env variable. If I replace ltd with abc or any other name, that name will be the error.
Below are the env vars used -
NAUTOBOT_APIC_BASE_URI_LTD
NAUTOBOT_APIC_USERNAME_LTD
NAUTOBOT_APIC_PASSWORD_LTD
NAUTOBOT_APIC_VERIFY_LTD
NAUTOBOT_APIC_SITE_LTD
NAUTOBOT_APIC_TENANT_PREFIX_LTD

from nautobot-app-ssot.

jdrew82 avatar jdrew82 commented on July 29, 2024

@ShivaniMauryaIntel can you provide the full traceback? Without knowing where this is happening it's tough to track down the cause.

from nautobot-app-ssot.

jdrew82 avatar jdrew82 commented on July 29, 2024

Also appears Sync Job is using default soft timeout limit of 5 minutes which is way too short for a sync job. This should be updated in the jobs.py meta to be at least several hours.

The global timeout is defined with the NAUTOBOT_CELERY_TASK_SOFT_TIME_LIMIT and NAUTOBOT_CELERY_TASK_TIME_LIMIT environment variables as hard limits. You can go into the Job settings and set a lower timeout if desired. Although we can set one in the Job itself it's difficult to know an appropriate timeout as it will vary quite a bit depending upon your deployment size and size of dataset being imported.

from nautobot-app-ssot.

ShivaniMauryaIntel avatar ShivaniMauryaIntel commented on July 29, 2024

@jdrew82 Based on your suggestion on slack, I have defined my env vars in a .env file & called the file in nautobot service - https://josh-v.com/nautobot-environment-file/
Below are the env vars used -
NAUTOBOT_APIC_BASE_URI_LTD
NAUTOBOT_APIC_USERNAME_LTD
NAUTOBOT_APIC_PASSWORD_LTD
NAUTOBOT_APIC_VERIFY_LTD
NAUTOBOT_APIC_SITE_LTD
NAUTOBOT_APIC_TENANT_PREFIX_LTD

Now, I am running the ACI sync job from Nautobot UI & I am getting the error at "ltd" which is the identifier used in my env variable. If I replace ltd with abc or any other name, that name is showing in the error message -
Return Data -
{
"exc_message": [
"ltd"
],
"exc_module": "builtins",
"exc_type": "KeyError"
}

7
Traceback (most recent call last):
File "/opt/nautobot/lib64/python3.9/site-packages/celery/app/trace.py", line 477, in trace_task
R = retval = fun(*args, **kwargs)
File "/opt/nautobot/lib64/python3.9/site-packages/celery/app/trace.py", line 760, in protected_call
return self.run(*args, **kwargs)
File "/opt/nautobot/lib64/python3.9/site-packages/nautobot/extras/jobs.py", line 1136, in run_job
result = job(*args, **kwargs)
File "/opt/nautobot/lib64/python3.9/site-packages/nautobot/extras/jobs.py", line 149, in call
return self.run(*args, **deserialized_kwargs)
File "/opt/nautobot/lib64/python3.9/site-packages/nautobot_ssot/integrations/aci/jobs.py", line 90, in run
super().run(dryrun=self.dryrun, memory_profiling=self.memory_profiling, *args, **kwargs)
File "/opt/nautobot/lib64/python3.9/site-packages/nautobot_ssot/jobs/base.py", line 317, in run
self.sync_data(memory_profiling)
File "/opt/nautobot/lib64/python3.9/site-packages/nautobot_ssot/jobs/base.py", line 136, in sync_data
self.load_source_adapter()
File "/opt/nautobot/lib64/python3.9/site-packages/nautobot_ssot/integrations/aci/jobs.py", line 74, in load_source_adapter
self.source_adapter = AciAdapter(job=self, sync=self.sync, client=aci_creds[self.apic])
KeyError: 'ltd'

from nautobot-app-ssot.

ShivaniMauryaIntel avatar ShivaniMauryaIntel commented on July 29, 2024

@jdrew82 Is this issue raised as another bug with ACI Sync Job? I am a bit concerned here as there was a bug fixed in the ACI Sync job 2 weeks ago & now there is another bug.

from nautobot-app-ssot.

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.