You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to build SONiC on Ubuntu 24.04, but the j2 tool fails to render the necessary templates. j2cli has been unmaintained for long, and the usage of removed feature is not likely to be fixed by the original author. A migration to alternatives may be necessary.
Execute make init on a machine with Python 3.12 as the default Python installation.
Describe the results you received:
The environment normally initializes.
Describe the results you expected:
The build fails with the following output:
Traceback (most recent call last):
File "/home/charlie/vsonic/venv/bin/j2", line 5, in <module>
from j2cli import main
File "/home/charlie/vsonic/venv/lib/python3.12/site-packages/j2cli/__init__.py", line 10, in <module>
from j2cli.cli import main
File "/home/charlie/vsonic/venv/lib/python3.12/site-packages/j2cli/cli.py", line 8, in <module>
import imp, inspect
ModuleNotFoundError: No module named 'imp'
The builtin module imp was deprecated in Python 3.4 and removed in Python 3.12. However, the j2cli has been unmaintained since January (see kolypto/j2cli#80), so the issue is not likely to be fixed.
Workaround
Create the Python venv using version <= 3.11.
The text was updated successfully, but these errors were encountered:
Description
I'm trying to build SONiC on Ubuntu 24.04, but the j2 tool fails to render the necessary templates. j2cli has been unmaintained for long, and the usage of removed feature is not likely to be fixed by the original author. A migration to alternatives may be necessary.
Possible candidate: https://github.com/kpfleming/jinjanator which is a fork of j2cli.
Steps to reproduce the issue:
Execute
make init
on a machine with Python 3.12 as the default Python installation.Describe the results you received:
The environment normally initializes.
Describe the results you expected:
The build fails with the following output:
The builtin module
imp
was deprecated in Python 3.4 and removed in Python 3.12. However, the j2cli has been unmaintained since January (see kolypto/j2cli#80), so the issue is not likely to be fixed.Workaround
Create the Python venv using version <= 3.11.
The text was updated successfully, but these errors were encountered: