Replies: 1 comment 1 reply
-
No, that's not right, because it won't remove any files from 3.3.10 which are not in 3.4 so you'll end up with a mixed 3.3.10 / 3.4 What you need to do is to untar into a completely separate directory (e.g. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
NetBox version
v3.3.10
Python version
3.9
Steps to Reproduce
I have Netbox 3.3.10 instance running on clear Rocky 8.7 with SELinux enabled / Python 3.9.13 / Postgresql 14.6. No additional netbox plugins installed. No issues with 3.3.10 instance observed. All "breaking changes" requirements as described in release notes for 3.4 branch are met.
I try to upgrade from 3.3.10 to 3.4.0 the next way:
When running the script i get next exception:
Applying database migrations (python3 netbox/manage.py migrate)...
Traceback (most recent call last):
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/template/utils.py", line 69, in getitem
return self._engines[alias]
KeyError: 'django'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/netbox/netbox/extras/registry.py", line 13, in getitem
return super().getitem(key)
KeyError: 'plugins'
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/netbox/netbox/manage.py", line 10, in
execute_from_command_line(sys.argv)
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/core/management/init.py", line 446, in execute_from_command_line
utility.execute()
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/core/management/init.py", line 440, in execute
self.fetch_command(subcommand).run_from_argv(self.argv)
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/core/management/base.py", line 402, in run_from_argv
self.execute(*args, **cmd_options)
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/core/management/base.py", line 448, in execute
output = self.handle(*args, **options)
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/core/management/base.py", line 96, in wrapped
res = handle_func(*args, **kwargs)
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/core/management/commands/migrate.py", line 97, in handle
self.check(databases=[database])
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/core/management/base.py", line 475, in check
all_issues = checks.run_checks(
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/core/checks/registry.py", line 88, in run_checks
new_errors = check(app_configs=app_configs, databases=databases)
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/contrib/admin/checks.py", line 78, in check_dependencies
for engine in engines.all():
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/template/utils.py", line 94, in all
return [self[alias] for alias in self]
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/template/utils.py", line 94, in
return [self[alias] for alias in self]
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/template/utils.py", line 85, in getitem
engine = engine_cls(params)
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/template/backends/django.py", line 25, in init
options["libraries"] = self.get_templatetag_libraries(libraries)
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/template/backends/django.py", line 43, in get_templatetag_libraries
libraries = get_installed_libraries()
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/template/backends/django.py", line 117, in get_installed_libraries
return {
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/template/backends/django.py", line 117, in
return {
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/template/backends/django.py", line 106, in get_template_tag_modules
for name in get_package_libraries(pkg):
File "/opt/netbox/venv/lib64/python3.9/site-packages/django/template/backends/django.py", line 129, in get_package_libraries
module = import_module(entry[1])
File "/usr/lib64/python3.9/importlib/init.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "", line 1030, in _gcd_import
File "", line 1007, in _find_and_load
File "", line 986, in _find_and_load_unlocked
File "", line 680, in _load_unlocked
File "", line 850, in exec_module
File "", line 228, in _call_with_frames_removed
File "/opt/netbox/netbox/utilities/templatetags/nav.py", line 5, in
from netbox.navigation_menu import MENUS
File "/opt/netbox/netbox/netbox/navigation_menu.py", line 408, in
if registry['plugins']['menu_items']:
File "/opt/netbox/netbox/extras/registry.py", line 15, in getitem
raise KeyError(f"Invalid store: {key}")
KeyError: 'Invalid store: plugins'
So upgrade procedure fails on this phase.
I am not familiar enough with python, so could anybody explain the reason of such exception happening and how to fix the issue?
Thank you in advance.
Expected Behavior
3.3.10 > 3.4.0 upgrade procedure succeeds.
Observed Behavior
3.3.10 > 3.4.0 fails when running database migrations (python3 netbox/manage.py migrate) with an exception thrown.
Beta Was this translation helpful? Give feedback.
All reactions