michaelgale / pcbflow

Python based Printed Circuit Board (PCB) layout and design package based on CuFlow.
BSD 3-Clause "New" or "Revised" License
133 stars 16 forks source link

Examples error on a fresh install #6

Closed ukd1 closed 10 months ago

ukd1 commented 10 months ago
$ git clone https://github.com/michaelgale/pcbflow.git
Cloning into 'pcbflow'...
remote: Enumerating objects: 645, done.
remote: Counting objects: 100% (23/23), done.
remote: Compressing objects: 100% (8/8), done.
remote: Total 645 (delta 18), reused 15 (delta 15), pack-reused 622
Receiving objects: 100% (645/645), 4.82 MiB | 4.85 MiB/s, done.
Resolving deltas: 100% (450/450), done.
$ cd pcbflow
$ python setup.py install
running install
/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
  warnings.warn(
/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/setuptools/command/easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools.
  warnings.warn(
running bdist_egg
running egg_info
creating pcbflow.egg-info
writing pcbflow.egg-info/PKG-INFO
writing dependency_links to pcbflow.egg-info/dependency_links.txt
writing requirements to pcbflow.egg-info/requires.txt
writing top-level names to pcbflow.egg-info/top_level.txt
writing manifest file 'pcbflow.egg-info/SOURCES.txt'
reading manifest file 'pcbflow.egg-info/SOURCES.txt'
adding license file 'LICENSE.md'
writing manifest file 'pcbflow.egg-info/SOURCES.txt'
installing library code to build/bdist.macosx-12.3-arm64/egg
running install_lib
running build_py
creating build
creating build/lib
creating build/lib/pcbflow
copying pcbflow/gerber.py -> build/lib/pcbflow
copying pcbflow/board.py -> build/lib/pcbflow
copying pcbflow/excellon.py -> build/lib/pcbflow
copying pcbflow/kicad.py -> build/lib/pcbflow
copying pcbflow/util.py -> build/lib/pcbflow
copying pcbflow/route.py -> build/lib/pcbflow
copying pcbflow/__init__.py -> build/lib/pcbflow
copying pcbflow/sexp_parser.py -> build/lib/pcbflow
copying pcbflow/drc.py -> build/lib/pcbflow
copying pcbflow/hershey.py -> build/lib/pcbflow
copying pcbflow/eagle.py -> build/lib/pcbflow
copying pcbflow/layer.py -> build/lib/pcbflow
copying pcbflow/svgout.py -> build/lib/pcbflow
copying pcbflow/part.py -> build/lib/pcbflow
copying pcbflow/draw.py -> build/lib/pcbflow
creating build/lib/pcbflow/footprints
copying pcbflow/footprints/sot.py -> build/lib/pcbflow/footprints
copying pcbflow/footprints/xtal.py -> build/lib/pcbflow/footprints
copying pcbflow/footprints/pin_header.py -> build/lib/pcbflow/footprints
copying pcbflow/footprints/__init__.py -> build/lib/pcbflow/footprints
copying pcbflow/footprints/tssop.py -> build/lib/pcbflow/footprints
copying pcbflow/footprints/special_conn.py -> build/lib/pcbflow/footprints
copying pcbflow/footprints/special_pcb.py -> build/lib/pcbflow/footprints
copying pcbflow/footprints/smd_discrete.py -> build/lib/pcbflow/footprints
copying pcbflow/footprints/soic.py -> build/lib/pcbflow/footprints
copying pcbflow/footprints/qfn.py -> build/lib/pcbflow/footprints
copying pcbflow/footprints/bga.py -> build/lib/pcbflow/footprints
creating build/bdist.macosx-12.3-arm64
creating build/bdist.macosx-12.3-arm64/egg
creating build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/gerber.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/board.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/excellon.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/kicad.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/util.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
creating build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/sot.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/xtal.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/pin_header.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/__init__.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/tssop.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/special_conn.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/special_pcb.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/smd_discrete.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/soic.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/qfn.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/footprints/bga.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints
copying build/lib/pcbflow/route.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/__init__.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/sexp_parser.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/drc.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/hershey.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/eagle.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/layer.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/svgout.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/part.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
copying build/lib/pcbflow/draw.py -> build/bdist.macosx-12.3-arm64/egg/pcbflow
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/gerber.py to gerber.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/board.py to board.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/excellon.py to excellon.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/kicad.py to kicad.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/util.py to util.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/sot.py to sot.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/xtal.py to xtal.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/pin_header.py to pin_header.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/__init__.py to __init__.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/tssop.py to tssop.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/special_conn.py to special_conn.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/special_pcb.py to special_pcb.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/smd_discrete.py to smd_discrete.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/soic.py to soic.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/qfn.py to qfn.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/footprints/bga.py to bga.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/route.py to route.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/__init__.py to __init__.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/sexp_parser.py to sexp_parser.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/drc.py to drc.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/hershey.py to hershey.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/eagle.py to eagle.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/layer.py to layer.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/svgout.py to svgout.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/part.py to part.cpython-310.pyc
byte-compiling build/bdist.macosx-12.3-arm64/egg/pcbflow/draw.py to draw.cpython-310.pyc
creating build/bdist.macosx-12.3-arm64/egg/EGG-INFO
installing scripts to build/bdist.macosx-12.3-arm64/egg/EGG-INFO/scripts
running install_scripts
running build_scripts
creating build/scripts-3.10
copying scripts/lbrlist.py -> build/scripts-3.10
copying scripts/kilist.py -> build/scripts-3.10
changing mode of build/scripts-3.10/lbrlist.py from 644 to 755
changing mode of build/scripts-3.10/kilist.py from 644 to 755
creating build/bdist.macosx-12.3-arm64/egg/EGG-INFO/scripts
copying build/scripts-3.10/kilist.py -> build/bdist.macosx-12.3-arm64/egg/EGG-INFO/scripts
copying build/scripts-3.10/lbrlist.py -> build/bdist.macosx-12.3-arm64/egg/EGG-INFO/scripts
changing mode of build/bdist.macosx-12.3-arm64/egg/EGG-INFO/scripts/kilist.py to 755
changing mode of build/bdist.macosx-12.3-arm64/egg/EGG-INFO/scripts/lbrlist.py to 755
copying pcbflow.egg-info/PKG-INFO -> build/bdist.macosx-12.3-arm64/egg/EGG-INFO
copying pcbflow.egg-info/SOURCES.txt -> build/bdist.macosx-12.3-arm64/egg/EGG-INFO
copying pcbflow.egg-info/dependency_links.txt -> build/bdist.macosx-12.3-arm64/egg/EGG-INFO
copying pcbflow.egg-info/requires.txt -> build/bdist.macosx-12.3-arm64/egg/EGG-INFO
copying pcbflow.egg-info/top_level.txt -> build/bdist.macosx-12.3-arm64/egg/EGG-INFO
zip_safe flag not set; analyzing archive contents...
pcbflow.__pycache__.__init__.cpython-310: module references __file__
creating dist
creating 'dist/pcbflow-0.1.0-py3.10.egg' and adding 'build/bdist.macosx-12.3-arm64/egg' to it
removing 'build/bdist.macosx-12.3-arm64/egg' (and everything under it)
Processing pcbflow-0.1.0-py3.10.egg
creating /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pcbflow-0.1.0-py3.10.egg
Extracting pcbflow-0.1.0-py3.10.egg to /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Adding pcbflow 0.1.0 to easy-install.pth file
Installing kilist.py script to /Users/russ/.asdf/installs/python/3.10.6/bin
Installing lbrlist.py script to /Users/russ/.asdf/installs/python/3.10.6/bin

Installed /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pcbflow-0.1.0-py3.10.egg
Processing dependencies for pcbflow==0.1.0
Searching for cairosvg
Reading https://pypi.org/simple/cairosvg/
/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pkg_resources/__init__.py:123: PkgResourcesDeprecationWarning:  is an invalid version and will not be supported in a future release
  warnings.warn(
/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pkg_resources/__init__.py:123: PkgResourcesDeprecationWarning: 2.0.0rc1.linux-x86-64 is an invalid version and will not be supported in a future release
  warnings.warn(
/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pkg_resources/__init__.py:123: PkgResourcesDeprecationWarning: x86-64 is an invalid version and will not be supported in a future release
  warnings.warn(
/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pkg_resources/__init__.py:123: PkgResourcesDeprecationWarning: 2.1.3.linux-x86-64 is an invalid version and will not be supported in a future release
  warnings.warn(
Downloading https://files.pythonhosted.org/packages/01/a5/1866b42151f50453f1a0d28fc4c39f5be5f412a2e914f33449c42daafdf1/CairoSVG-2.7.1-py3-none-any.whl#sha256=8a5222d4e6c3f86f1f7046b63246877a63b49923a1cd202184c3a634ef546b3b
Best match: CairoSVG 2.7.1
Processing CairoSVG-2.7.1-py3-none-any.whl
Installing CairoSVG-2.7.1-py3-none-any.whl to /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Adding CairoSVG 2.7.1 to easy-install.pth file
Installing cairosvg script to /Users/russ/.asdf/installs/python/3.10.6/bin

Installed /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/CairoSVG-2.7.1-py3.10.egg
Searching for svgwrite
Reading https://pypi.org/simple/svgwrite/
Downloading https://files.pythonhosted.org/packages/84/15/640e399579024a6875918839454025bb1d5f850bb70d96a11eabb644d11c/svgwrite-1.4.3-py3-none-any.whl#sha256=bb6b2b5450f1edbfa597d924f9ac2dd099e625562e492021d7dd614f65f8a22d
Best match: svgwrite 1.4.3
Processing svgwrite-1.4.3-py3-none-any.whl
Installing svgwrite-1.4.3-py3-none-any.whl to /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Adding svgwrite 1.4.3 to easy-install.pth file

Installed /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/svgwrite-1.4.3-py3.10.egg
Searching for pytest
Reading https://pypi.org/simple/pytest/
Downloading https://files.pythonhosted.org/packages/42/8f/609a38adb94cf52f8e4bf1aafa072dcf5d08fa3cb76c506517ea0ae042d5/pytest-8.0.0rc1-py3-none-any.whl#sha256=6c30d4c4409c5d227ef936678b72c56b6fbaed28a6ee4eafd2c93ed9a24c65af
Best match: pytest 8.0.0rc1
Processing pytest-8.0.0rc1-py3-none-any.whl
Installing pytest-8.0.0rc1-py3-none-any.whl to /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Adding pytest 8.0.0rc1 to easy-install.pth file
Installing py.test script to /Users/russ/.asdf/installs/python/3.10.6/bin
Installing pytest script to /Users/russ/.asdf/installs/python/3.10.6/bin

Installed /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pytest-8.0.0rc1-py3.10.egg
Searching for cssselect2
Reading https://pypi.org/simple/cssselect2/
Downloading https://files.pythonhosted.org/packages/9d/3a/e39436efe51894243ff145a37c4f9a030839b97779ebcc4f13b3ba21c54e/cssselect2-0.7.0-py3-none-any.whl#sha256=fd23a65bfd444595913f02fc71f6b286c29261e354c41d722ca7a261a49b5969
Best match: cssselect2 0.7.0
Processing cssselect2-0.7.0-py3-none-any.whl
Installing cssselect2-0.7.0-py3-none-any.whl to /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Adding cssselect2 0.7.0 to easy-install.pth file

Installed /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/cssselect2-0.7.0-py3.10.egg
Searching for cairocffi
Reading https://pypi.org/simple/cairocffi/
Downloading https://files.pythonhosted.org/packages/17/be/a5d2c16317c6a890502725970589ae7f06cfc66b2e6916ba0a86973403c8/cairocffi-1.6.1-py3-none-any.whl#sha256=aa78ee52b9069d7475eeac457389b6275aa92111895d78fbaa2202a52dac112e
Best match: cairocffi 1.6.1
Processing cairocffi-1.6.1-py3-none-any.whl
Installing cairocffi-1.6.1-py3-none-any.whl to /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Adding cairocffi 1.6.1 to easy-install.pth file

Installed /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/cairocffi-1.6.1-py3.10.egg
Searching for tomli>=1.0.0
Reading https://pypi.org/simple/tomli/
Downloading https://files.pythonhosted.org/packages/97/75/10a9ebee3fd790d20926a90a2547f0bf78f371b2f13aa822c759680ca7b9/tomli-2.0.1-py3-none-any.whl#sha256=939de3e7a6161af0c887ef91b7d41a53e7c5a1ca976325f429cb46ea9bc30ecc
Best match: tomli 2.0.1
Processing tomli-2.0.1-py3-none-any.whl
Installing tomli-2.0.1-py3-none-any.whl to /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Adding tomli 2.0.1 to easy-install.pth file

Installed /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/tomli-2.0.1-py3.10.egg
Searching for exceptiongroup>=1.0.0rc8
Reading https://pypi.org/simple/exceptiongroup/
Downloading https://files.pythonhosted.org/packages/b8/9a/5028fd52db10e600f1c4674441b968cf2ea4959085bfb5b99fb1250e5f68/exceptiongroup-1.2.0-py3-none-any.whl#sha256=4bfd3996ac73b41e9b9628b04e079f193850720ea5945fc96a08633c66912f14
Best match: exceptiongroup 1.2.0
Processing exceptiongroup-1.2.0-py3-none-any.whl
Installing exceptiongroup-1.2.0-py3-none-any.whl to /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Adding exceptiongroup 1.2.0 to easy-install.pth file

Installed /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/exceptiongroup-1.2.0-py3.10.egg
Searching for pluggy<2.0,>=1.3.0
Reading https://pypi.org/simple/pluggy/
Downloading https://files.pythonhosted.org/packages/05/b8/42ed91898d4784546c5f06c60506400548db3f7a4b3fb441cba4e5c17952/pluggy-1.3.0-py3-none-any.whl#sha256=d89c696a773f8bd377d18e5ecda92b7a3793cbe66c87060a6fb58c7b6e1061f7
Best match: pluggy 1.3.0
Processing pluggy-1.3.0-py3-none-any.whl
Installing pluggy-1.3.0-py3-none-any.whl to /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Adding pluggy 1.3.0 to easy-install.pth file

Installed /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pluggy-1.3.0-py3.10.egg
Searching for iniconfig
Reading https://pypi.org/simple/iniconfig/
Downloading https://files.pythonhosted.org/packages/ef/a6/62565a6e1cf69e10f5727360368e451d4b7f58beeac6173dc9db836a5b46/iniconfig-2.0.0-py3-none-any.whl#sha256=b6a85871a79d2e3b22d2d1b94ac2824226a63c6b741c88f7ae975f18b6778374
Best match: iniconfig 2.0.0
Processing iniconfig-2.0.0-py3-none-any.whl
Installing iniconfig-2.0.0-py3-none-any.whl to /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Adding iniconfig 2.0.0 to easy-install.pth file

Installed /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/iniconfig-2.0.0-py3.10.egg
Searching for Pillow==9.2.0
Best match: Pillow 9.2.0
Adding Pillow 9.2.0 to easy-install.pth file

Using /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Searching for shapely==2.0a1
Best match: shapely 2.0a1
Adding shapely 2.0a1 to easy-install.pth file

Using /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Searching for tinycss2==1.1.1
Best match: tinycss2 1.1.1
Adding tinycss2 1.1.1 to easy-install.pth file

Using /Users/russ/.local/lib/python3.10/site-packages
Searching for defusedxml==0.7.1
Best match: defusedxml 0.7.1
Adding defusedxml 0.7.1 to easy-install.pth file

Using /Users/russ/.local/lib/python3.10/site-packages
Searching for packaging==21.3
Best match: packaging 21.3
Adding packaging 21.3 to easy-install.pth file

Using /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Searching for numpy==1.23.5
Best match: numpy 1.23.5
Adding numpy 1.23.5 to easy-install.pth file
Installing f2py script to /Users/russ/.asdf/installs/python/3.10.6/bin
Installing f2py3 script to /Users/russ/.asdf/installs/python/3.10.6/bin
Installing f2py3.10 script to /Users/russ/.asdf/installs/python/3.10.6/bin

Using /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Searching for webencodings==0.5.1
Best match: webencodings 0.5.1
Adding webencodings 0.5.1 to easy-install.pth file

Using /Users/russ/.local/lib/python3.10/site-packages
Searching for cffi==1.15.1
Best match: cffi 1.15.1
Adding cffi 1.15.1 to easy-install.pth file

Using /Users/russ/.local/lib/python3.10/site-packages
Searching for pyparsing==3.0.9
Best match: pyparsing 3.0.9
Adding pyparsing 3.0.9 to easy-install.pth file

Using /Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages
Searching for pycparser==2.21
Best match: pycparser 2.21
Adding pycparser 2.21 to easy-install.pth file

Using /Users/russ/.local/lib/python3.10/site-packages
Finished processing dependencies for pcbflow==0.1.0

$ cd examples
$ python basic/blank.py
Traceback (most recent call last):
  File "/Users/russ/Sites/pcbflow/examples/basic/blank.py", line 10, in <module>
    brd.fill_layer("GTL", "GND")
  File "/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pcbflow-0.1.0-py3.10.egg/pcbflow/board.py", line 249, in fill_layer
    lyr.fill_poly = g.difference(exclusions.buffer(self.drc.clearance))
AttributeError: 'NoneType' object has no attribute 'buffer'

$ python basic/holes.py
Traceback (most recent call last):
  File "/Users/russ/Sites/pcbflow/examples/basic/holes.py", line 17, in <module>
    brd.fill_layer("GTL", "GND")
  File "/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pcbflow-0.1.0-py3.10.egg/pcbflow/board.py", line 249, in fill_layer
    lyr.fill_poly = g.difference(exclusions.buffer(self.drc.clearance))
AttributeError: 'NoneType' object has no attribute 'buffer'

$ cd sample
$ python sample.py
WARNING: fanout for R3 requires at least one net name to match against pad names
Traceback (most recent call last):
  File "/Users/russ/Sites/pcbflow/examples/sample/sample.py", line 38, in <module>
    usb_con = EaglePart(
  File "/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pcbflow-0.1.0-py3.10.egg/pcbflow/eagle.py", line 90, in __init__
    tree = ET.parse(self.libraryfile)
  File "/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/xml/etree/ElementTree.py", line 1222, in parse
    tree.parse(source, parser)
  File "/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/xml/etree/ElementTree.py", line 569, in parse
    source = open(source, "rb")
FileNotFoundError: [Errno 2] No such file or directory: 'sparkfun.lbr'
michaelgale commented 10 months ago

The file not found errors are due to a breaking change to python's __file__ dunder method. After python 3.9+, the basename is returned with the full path rather than the base filename without path. All example scripts now use os.path.basename(__file__)[:-3] to return a simple basename as expected. In realty, your scripts will use your own filename reference anyway--the use of __file__ was a convenience for the sample scripts to self name.

Lastly, the sample.py script did not work because you do not have a sparkfun.lbr Eagle PCB library in the path of the script. Unless you use Eagle PCB, it is not a relevant test.

Modifications have been made to the repo example scripts and committed. Other changes have been made to support new versions of dependancy libraries.

michaelgale commented 10 months ago

Nevermind about the comments with respect to the __file__ dunder methods! That was referring to the bugs I was received whilst trying to replicate your error!

The NoneType buffers are likely due to the version of the shapely library. PCBflow was initially released supporting v.1.8.0+. Breaking changes were made v.2.0.0+ and therefore PCBflow was just changed to support them. Pull the most recent PCBflow and try again?

ukd1 commented 10 months ago

Thanks for the quick reply! Just pulled, still getting this error:

 % python basic/blank.py
Traceback (most recent call last):
  File "/Users/russ/Sites/pcbflow/examples/basic/blank.py", line 11, in <module>
    brd.fill_layer("GTL", "GND")
  File "/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pcbflow-0.2.0-py3.10.egg/pcbflow/board.py", line 247, in fill_layer
    lyr.fill_poly = g.difference(exclusions.buffer(self.drc.clearance))
AttributeError: 'NoneType' object has no attribute 'buffer'

BTW, if it needs another version of Python, or some other requirements - I'm happy to install, just no sure where to get them (e.g. sparkfun.lbr).

Side/background: I am a total beginner at designing boards, but like programming. For CAD, I decided to learn OpenSCAD first - this seems similar! So, I have near-zero context for fixing outside of reading your README.

michaelgale commented 10 months ago

The first thing to try is to update the shapely package:

$ pip install --upgrade shapely

FYI, my platform has v.2.0.2 of shapely

michaelgale commented 10 months ago

Examining your execution dump above, I see that your installation uses shapely 2.0a1. When reviewing the changelogs from the shapely library repo, it appears that there was a very important fix made to version 2.0b1+ which would very much explain the AttributeError: 'NoneType' object has no attribute 'buffer' messages above. The object which is declared as a NoneType should in theory never be of this type. This object is the result of a call to the shapely.unary_union method which (as of 2.0b1+) should always return an object of type GeometryCollection (even if empty).

Therefore, I would strongly suggest updating your shapely library as described above to any version 2.0b1+, preferably v.2.0.2 (latest as of now).

michaelgale commented 10 months ago

I've enforced the version of the shapely package in the pcbflow installer. Therefore, you can git pull and attempt a new pip install .

ukd1 commented 10 months ago

Thanks - I just pulled, python setup.py install, and tried the basic example, but still get this error:

python examples/basic/blank.py 
Traceback (most recent call last):
  File "/Users/russ/Sites/pcbflow/examples/basic/blank.py", line 11, in <module>
    brd.fill_layer("GTL", "GND")
  File "/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pcbflow-0.2.0-py3.10.egg/pcbflow/board.py", line 247, in fill_layer
    lyr.fill_poly = g.difference(exclusions.buffer(self.drc.clearance))
AttributeError: 'NoneType' object has no attribute 'buffer'

Any idea what am I missing / doing wrong?

michaelgale commented 10 months ago

Can try pip list at your terminal and report back which version of shapely is shown?

ukd1 commented 10 months ago
pcbflow % pip list | grep shapely
shapely                      2.0a1

So, looks like the change didn't force it to update on install?

michaelgale commented 10 months ago

Try this pip install --upgrade shapely and pip list to check the version

ukd1 commented 10 months ago

I did the dumber version before seeing your comment:

pcbflow % pip uninstall shapely
...
pcbflow % python setup.py install
...
pcbflow % pip list | grep shapely
shapely                      2.0.2
pcbflow % python examples/basic/blank.py 
Rendering Gerber GTD...
Rendering Gerber GTP...
Rendering Gerber GTO...
Rendering Gerber GTS...
Rendering Gerber GTL...
Rendering Gerber GBL...
Rendering Gerber GBS...
Rendering Gerber GBO...
Rendering Gerber GBP...
Rendering Gerber GBD...
Rendering Gerber GML...
Rendering excellon drill files...
Rendering preview_top.['pdf']...
Rendering preview_top_docu.['pdf']...
Rendering preview_bot.['pdf']...
Rendering preview_bot_docu.['pdf']...
Rendering preview_all.['pdf']...

So, looks like it's working!!

I'm a rubyist, so not really sure why the change to your requirements.txt and pull + re-setup didn't force that dependency update (will this affect others?) -- but thanks so much for helping fix this with me!

michaelgale commented 10 months ago

Glad its working. I'm not a pip expert, so I'm not sure what to blame for ignoring the requirements spec! On the to do list is to make a package for PyPI to make installation that much easier.

ukd1 commented 10 months ago

One more question - where / how can I install the sparkfun.lbr stuff?

michaelgale commented 10 months ago

The sparkfun.lbr is just an Eagle parts library I use for testing. Unless you need to use parts from existing Eagle part libraries, then its not something you really require. I think there might be a copy in the scripts folder, but I'm not sure. In any case, it is simply a test file for verifying that pcbflow can read/import parts.

ukd1 commented 10 months ago

Is it this one - https://github.com/sparkfun/Old-SparkFun-Eagle-Library - the "current" one seems to not have that individual file in. I'm setting up some github actions test running, and sample running for this, and trying to find the library you use for this.

I tried using https://github.com/sparkfun/Old-SparkFun-Eagle-Library/tree/master but it doesn't like it:

python examples/sample/sample.py
WARNING: fanout for R3 requires at least one net name to match against pad names
Traceback (most recent call last):
  File "/Users/russ/Sites/pcbflow/examples/sample/sample.py", line 39, in <module>
    usb_con = EaglePart(
  File "/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/site-packages/pcbflow-0.2.0-py3.10.egg/pcbflow/eagle.py", line 90, in __init__
    tree = ET.parse(self.libraryfile)
  File "/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/xml/etree/ElementTree.py", line 1222, in parse
    tree.parse(source, parser)
  File "/Users/russ/.asdf/installs/python/3.10.6/lib/python3.10/xml/etree/ElementTree.py", line 580, in parse
    self._root = parser._parse_whole(source)
xml.etree.ElementTree.ParseError: not well-formed (invalid token): line 1, column 0

The file appears to be binary, but your code is expecting xml; I guess the one I found is 13 year old lol, so prolly wrong. Could you point me to the right github for this? Or, should I try update to the current eagle libs from them - which I think is https://github.com/sparkfun/SparkFun-Eagle-Libraries

ukd1 commented 10 months ago

USB-B-SMT I can only find in https://github.com/sparkfun/SparkFun-Eagle-Libraries/blob/main/SparkFun-Retired.lbr - but no idea if it's the same one

ukd1 commented 10 months ago

could it be replaced with USB-B-MICRO-SMD from https://github.com/sparkfun/SparkFun-Eagle-Libraries/blob/main/SparkFun-Connectors.lbr? (It runs / outputs something, but, I'm a noob - so no idea if it's actually "bad" output)

ukd1 commented 10 months ago

The sparkfun.lbr is just an Eagle parts library I use for testing. Unless you need to use parts from existing Eagle part libraries, then its not something you really require. I think there might be a copy in the scripts folder, but I'm not sure. In any case, it is simply a test file for verifying that pcbflow can read/import parts.

Just re-read this - I guess I didn't see the scripts part! thanks.

michaelgale commented 10 months ago

@ukd1 I presume I can close this issue unless there are any comments?