Closed Andrei1Byte closed 6 years ago
could you try an older python-version? 2.2 and 3.5 are tested.
for me it seems, xlwt has problems. You could also try to remove xlwt package.
Hello,
On Py 3.5.3 I get this for test.py:
D:\KIT-URI\PyModules\canmatrix-development\test>python test.py arxml -> ['csv', 'dbc', 'dbf', 'json', 'kcd', 'sym', 'xls', 'xlsx', 'xml', 'yaml'] dbc -> ['arxml', 'csv', 'dbf', 'json', 'kcd', 'sym', 'xls', 'xlsx', 'xml', 'yaml'] dbf -> ['arxml', 'csv', 'dbc', 'json', 'kcd', 'sym', 'xls', 'xlsx', 'xml', 'yaml'] json -> ['arxml', 'csv', 'dbc', 'dbf', 'kcd', 'sym', 'xls', 'xlsx', 'xml', 'yaml'] kcd -> ['arxml', 'csv', 'dbc', 'dbf', 'json', 'sym', 'xls', 'xlsx', 'xml', 'yaml'] sym -> ['arxml', 'csv', 'dbc', 'dbf', 'json', 'kcd', 'xls', 'xlsx', 'xml', 'yaml'] Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped Variable type 'string' found and skipped xls -> ['arxml', 'csv', 'dbc', 'dbf', 'json', 'kcd', 'sym', 'xlsx', 'xml', 'yaml'] xlsx -> ['arxml', 'csv', 'dbc', 'dbf', 'json', 'kcd', 'sym', 'xls', 'xml', 'yaml'] yaml -> ['arxml', 'csv', 'dbc', 'dbf', 'json', 'kcd', 'sym', 'xls', 'xlsx', 'xml'] Traceback (most recent call last): File "test.py", line 82, in
exit_code = subprocess.call(['diff', '-r', 'reference', 'converted']) File "C:\Python35\lib\subprocess.py", line 247, in call with Popen(*popenargs, **kwargs) as p: File "C:\Python35\lib\subprocess.py", line 676, in init restore_signals, start_new_session) File "C:\Python35\lib\subprocess.py", line 955, in _execute_child startupinfo) FileNotFoundError: [WinError 2] The system cannot find the file specified
[ebroecker] This is ok, because test.py uses diff
which is not installed in windows system.
And this for createTestMatrix.py:
D:\KIT-URI\PyModules\canmatrix-development\test>python createTestMatrix.py Traceback (most recent call last): File "createTestMatrix.py", line 7, in
import canmatrix.exportall as ex ImportError: No module named 'canmatrix.exportall'
[ebroecker] this is NOT ok. Reason: createTestMatrix.py is heavily outdated. I'll fix this later these days.
pip freeze:
D:\KIT-URI\PyModules\canmatrix-development\test>python -V Python 3.5.3 D:\KIT-URI\PyModules\canmatrix-development\test>pip freeze bitstruct==3.5.0 canmatrix==0.6.1rc0 freeze==1.0.10 future==0.16.0 lxml==4.1.1 pyaml==17.10.0 PyYAML==3.12 six==1.11.0 xlrd==1.1.0 xlsxwriter==1.0.2 xlwt==1.3.0 xlwt-future==0.8.0
simply converting should work?
canconvert test.dbc test2.dbc
or - if you want in examples:
python convert.py ..\test.dbc test2.dbc
Yes simply converting is working (no error).
I tried with python convert.py test.dbc test2.dbc
createTestMatrix.py should work again with: 21063ed640b22c9c8c9935c257aac33e1ecadd85
The following error is popping up: 'str' object has no attribute 'decode' so I deleted the "decode("utf-8")" for unit="specialCharUnit°$", and "Multi \n Line \n Signal comment with a-umlaut: ä") and now is working.
For test.py is the same behavior.
I don't want to create another issue for this question, and I don't know where to address it so I address it here.
@ebroecker : Dose this project(package) supports CAN FD ?
CAN FD is now handled in this issue: #115
can this issue be closed?
I'm getting the same error on Python 3.9.2 and the latest canmatrix commit as of Oct 20, 2022.
raise ValueError("cannot use LOCALE flag with a str pattern") ValueError: cannot use LOCALE flag with a str pattern
I'm also not able to run the test examples:
canconvert test.dbc test2.dbc
or
python convert.py ..\test.dbc test2.dbc
Both of the above return the same error.
UPDATE: The solution here worked for me.
TL;DR: Uninstall xlwt: pip uninstall xlwt
and pip uninstall xlwt-future
and then specifically reinstall xlwt v1.3.0: pip install 'xlwt==1.3.0'
Hello,
I receive this error "ValueError cannot use LOCALE flag with a str pattern", when I try to run anything related to this project. For example I tried to run test.py:
This is the output:
This is the output of : python setup.py install
This is the output of: pip install -r requirements.txt
This is the output of: pip freeze
Python version 3.6.3
Any ideas on how to fix this issue?
Thanks