Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SKiDL BUG] generate_svg failure #123

Open
shanzez opened this issue Jul 12, 2021 · 1 comment
Open

[SKiDL BUG] generate_svg failure #123

shanzez opened this issue Jul 12, 2021 · 1 comment
Labels

Comments

@shanzez
Copy link
Contributor

shanzez commented Jul 12, 2021

Describe the bug
When running with generate_svg, I get a failure: KeyError: 'n"

To Reproduce
Steps to reproduce the behavior:

$ npm install -g https://github.com/nturley/netlistsvg

added 37 packages, and audited 38 packages in 5s

3 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities
$ python3 main.py 
Traceback (most recent call last):
  File "/Users/shanzez/temp/board/main.py", line 108, in <module>
    skidl.generate_svg()
  File "/opt/homebrew/lib/python3.9/site-packages/skidl/circuit.py", line 869, in generate_svg
    part_pin_dirs = {
  File "/opt/homebrew/lib/python3.9/site-packages/skidl/circuit.py", line 870, in <dictcomp>
    pin.num: io_dict[
KeyError: 'n'

Expected behavior
Generates the svg

Desktop (please complete the following information):

  • OS macOS 12 Beta - mac Mini M1 16GB mem (reproduced on Debian Linux x64 with same below versions)
  • Python version 3.9
  • SKiDL version 1.0.0

Additional context
generate_netlist and dot are fine.

@shanzez shanzez added the bug label Jul 12, 2021
@Berry1997
Copy link

Berry1997 commented Dec 19, 2021

I encountered this bug recently, and I found out that it is generated when a part contains a No-Connect Pin.
I think one may first remove the no-connect pins then assign I/O to each part pin, since slicing the string with the first character cannot deal with "nc".

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants