Skip to content

fix EDS Signal NameError#902

Merged
ebroecker merged 1 commit intoebroecker:developmentfrom
StaflSystems:bugfix/eds-nameerror
Mar 3, 2026
Merged

fix EDS Signal NameError#902
ebroecker merged 1 commit intoebroecker:developmentfrom
StaflSystems:bugfix/eds-nameerror

Conversation

@willson556
Copy link
Copy Markdown
Contributor

Fix the following crash:

Traceback (most recent call last):
  File "/usr/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/usr/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/home/.../python3.10/site-packages/canmatrix/cli/convert.py", line 163, in <module>
    sys.exit(cli_convert())
  File "/home/.../python3.10/site-packages/click/core.py", line 1485, in __call__
    return self.main(*args, **kwargs)
  File "/home/.../python3.10/site-packages/click/core.py", line 1406, in main
    rv = self.invoke(ctx)
  File "/home/.../python3.10/site-packages/click/core.py", line 1269, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/.../python3.10/site-packages/click/core.py", line 824, in invoke
    return callback(*args, **kwargs)
  File "/home/.../python3.10/site-packages/canmatrix/cli/convert.py", line 158, in cli_convert
    canmatrix.convert.convert(infile, outfile, **options)
  File "/home/.../python3.10/site-packages/canmatrix/convert.py", line 69, in convert
    dbs = canmatrix.formats.loadp(infile, **options)
  File "/home/.../python3.10/site-packages/canmatrix/formats/__init__.py", line 71, in loadp
    return load(fileObject, import_type, key, **options)
  File "/home/.../python3.10/site-packages/canmatrix/formats/__init__.py", line 94, in load
    dbs[key] = module_instance.load(file_object, **options)  # type: ignore
  File "/home/.../python3.10/site-packages/canmatrix/formats/eds.py", line 245, in load
    new_sig = canmatrix.Signal(signal_name, size=bit_length, start_bit=current_bit_start)
NameError: name 'canmatrix' is not defined. Did you mean: 'CanMatrix'?

Also, fix the type hint on load().

@ebroecker ebroecker merged commit 4411d9e into ebroecker:development Mar 3, 2026
3 of 16 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants