Skip to content

Commit

Permalink
added try for freecad import (#48)
Browse files Browse the repository at this point in the history
  • Loading branch information
shimwell authored Apr 16, 2024
1 parent 59731d8 commit 377156b
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
8 changes: 8 additions & 0 deletions src/GEOReverse/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
# this try except attempts to import freecad (lowercase) which is the conda
# package name for FreeCAD (mixed case) upon import the conda package appends
# the sys path for Conda installed FreeCAD, consequently FreeCAD can then be
# found by subsequent import statements through out the code base
try:
import freecad
except:
pass
8 changes: 8 additions & 0 deletions src/GEOUNED/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,14 @@

# We load the STEP and the materials
import sys
# this try except attempts to import freecad (lowercase) which is the conda
# package name for FreeCAD (mixed case) upon import the conda package appends
# the sys path for Conda installed FreeCAD, consequently FreeCAD can then be
# found by subsequent import statements through out the code base
try:
import freecad
except:
pass
import FreeCAD,Part
import configparser

Expand Down

0 comments on commit 377156b

Please sign in to comment.