No module named 'napalm_base' - panos #5214

Closed
opened 2025-12-29 19:25:30 +01:00 by adam · 4 comments
Owner

Originally created by @bile0026 on GitHub (Aug 20, 2021).

NetBox version

v2.11.11

Python version

3.6

Steps to Reproduce

napalm-panos==0.5.2

2 Scenarios:

Scenario 1 - Existing Device:

  1. Set platform to paloalto_panos on device.
  2. Click status tab
  3. Error, No module named 'napalm_base'

Scenario 2 - Onboarding plugin:

  1. Use onboarding plugin to onboard new PANOS device
  2. Error importing device, No module named 'napalm_base'

Expected Behavior

Show active status of device.

Onboard device.

Observed Behavior

Receive an error of "No module named napalm_base". Other platforms work such as ios,nxos,ros.

netbox error

Originally created by @bile0026 on GitHub (Aug 20, 2021). ### NetBox version v2.11.11 ### Python version 3.6 ### Steps to Reproduce `napalm-panos==0.5.2` 2 Scenarios: Scenario 1 - Existing Device: 1. Set platform to paloalto_panos on device. 2. Click status tab 3. Error, `No module named 'napalm_base'` Scenario 2 - Onboarding plugin: 1. Use onboarding plugin to onboard new PANOS device 2. Error importing device, `No module named 'napalm_base'` ### Expected Behavior Show active status of device. Onboard device. ### Observed Behavior Receive an error of "No module named napalm_base". Other platforms work such as ios,nxos,ros. ![netbox error](https://user-images.githubusercontent.com/5022496/130263941-dd8a5ea8-c3bc-40da-8c1e-6ce7824049f7.png)
adam closed this issue 2025-12-29 19:25:30 +01:00
Author
Owner

@sdktr commented on GitHub (Aug 20, 2021):

What does the platform panos page show?

@sdktr commented on GitHub (Aug 20, 2021): What does the platform panos page show?
Author
Owner

@bile0026 commented on GitHub (Aug 20, 2021):

What does the platform panos page show?

Uploading panos_platform.png…

@bile0026 commented on GitHub (Aug 20, 2021): > What does the platform panos page show? ![Uploading panos_platform.png…]()
Author
Owner

@jeremystretch commented on GitHub (Aug 20, 2021):

This looks like an issue with the NAPALM driver itself, or possibly with your local environment. If you enable debugging and reproduce the underlying API request, you should see the full stack trace indicating exactly where the issue lies.

@jeremystretch commented on GitHub (Aug 20, 2021): This looks like an issue with the NAPALM driver itself, or possibly with your local environment. If you enable debugging and reproduce the underlying API request, you should see the full stack trace indicating exactly where the issue lies.
Author
Owner

@jeremystretch commented on GitHub (Aug 20, 2021):

Yep, I've confirmed that this is a bug in the PanOS NAPALM driver:

  File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
    <source code not available>
  File "/opt/netbox/venv/lib/python3.7/site-packages/napalm_panos/__init__.py", line 21, in <module>
    from napalm_panos.panos import PANOSDriver
  File "/opt/netbox/venv/lib/python3.7/site-packages/napalm_panos/panos.py", line 38, in <module>
    from napalm_base.utils.string_parsers import convert_uptime_string_seconds

Exception Type: ModuleNotFoundError at /api/dcim/devices/1/napalm/
Exception Value: No module named 'napalm_base'

This isn't something we can address in NetBox. You might consider raising a bug report against the NAPALM driver.

@jeremystretch commented on GitHub (Aug 20, 2021): Yep, I've confirmed that this is a bug in the PanOS NAPALM driver: ``` File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed <source code not available> File "/opt/netbox/venv/lib/python3.7/site-packages/napalm_panos/__init__.py", line 21, in <module> from napalm_panos.panos import PANOSDriver File "/opt/netbox/venv/lib/python3.7/site-packages/napalm_panos/panos.py", line 38, in <module> from napalm_base.utils.string_parsers import convert_uptime_string_seconds Exception Type: ModuleNotFoundError at /api/dcim/devices/1/napalm/ Exception Value: No module named 'napalm_base' ``` This isn't something we can address in NetBox. You might consider raising a bug report against the NAPALM driver.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/netbox#5214