MACRO:Work Feature 2014_12
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Be nice to others! Respect the FreeCAD code of conduct!
Re: MACRO:Work Feature 2014_12
Hello Rentlau_64,
i think same problem on my installation (win 10) too
OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.9459 (Git)
Build type: Release
Branch: master
Hash: f22f5c819e510c27debea285e6a7ee20363c30d9
Python version: 2.7.8
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.0.0
i think same problem on my installation (win 10) too
OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.9459 (Git)
Build type: Release
Branch: master
Hash: f22f5c819e510c27debea285e6a7ee20363c30d9
Python version: 2.7.8
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.0.0
-
- Posts: 181
- Joined: Tue Oct 21, 2014 9:47 am
- Location: Pau (France)
Re: MACRO:Work Feature 2014_12
@ nemesis,
You have this error :
When you change :
To try to fix the bug :
In the file WF_ObjParCurveEdit_2016.py under your directory WorkFeature/WorkFeature/ParCurve/:
try to replace line 9
by
In file WF_ObjParCurve_2016.py under WorkFeature/WorkFeature/ParCurve/:
try to replace line 11
by
and let me know if it works i will commit the bug fix?
Rentlau_64
You have this error :
Which file did you change first?ERROR:cannot load FreeCAD module...modify line 6 and 7 of this script !!
<unknown exception traceback><unknown exception type>: <unknown exception data>
When you change :
toif not sys.path.__contains__("/usr/lib/freecad/lib"):
sys.path.append("/usr/lib/freecad/lib")
if not sys.path.__contains__("/Applications/FreeCAD.app/Contents/lib"):
sys.path.append("/Applications/FreeCAD.app/Contents/lib")
To try to fix the bug :
Please check first that you have the following files:Traceback (most recent call last):
File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Macro/start_WF.FCMacro", line 34, in <module>
import WorkFeature.WF_2015 as WF
File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/WorkFeature/WorkFeature/WF_2015.py", line 65, in <module>
from ParCurve.WF_ObjParCurve_2016 import *
File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/WorkFeature/WorkFeature/ParCurve/WF_ObjParCurve_2016.py", line 16, in <module>
import WF_ObjParCurveEdit_2016 as ParCurveEdit
File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/WorkFeature/WorkFeature/ParCurve/WF_ObjParCurveEdit_2016.py", line 11, in <module>
import Ui.WF_ObjParCurve2DEditGui_2016 as EDIT_2D
<type 'exceptions.ImportError'>: No module named WF_ObjParCurve2DEditGui_2016
under your directory WorkFeature/WorkFeature/ParCurve/Ui__init__.py
WF_ObjParCurve2DEditGui_2016.py
WF_ObjParCurve3DEditGui_2016.py
WF_ObjSurfaceEditGui_2016.py
WF_ParCurveGui_2016.py
In the file WF_ObjParCurveEdit_2016.py under your directory WorkFeature/WorkFeature/ParCurve/:
try to replace line 9
Code: Select all
sys.path.append(os.path.dirname(__file__))
Code: Select all
# Get the path of the current python script
m_current_path = os.path.realpath(__file__)
# Update your paths
if not sys.path.__contains__(m_current_path):
sys.path.append(m_current_path)
try to replace line 11
Code: Select all
m_current_path = "/home/laurent/Develop/Workspaces/Python/WF_test/WorkFeature/ParCurve/"
Code: Select all
# Get the path of the current python script
m_current_path = os.path.realpath(__file__)
Rentlau_64
Re: MACRO:Work Feature 2014_12
I changed it in "start_WF.py"rentlau_64 wrote: Which file did you change first?
check! (that's a clone from github)rentlau_64 wrote: Please check first that you have the following files:
I did all the changes and:
Code: Select all
Traceback (most recent call last):
File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Macro/start_WF.FCMacro", line 34, in <module>
import WorkFeature.WF_2015 as WF
File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/WorkFeature/WorkFeature/WF_2015.py", line 65, in <module>
from ParCurve.WF_ObjParCurve_2016 import *
File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/WorkFeature/WorkFeature/ParCurve/WF_ObjParCurve_2016.py", line 18, in <module>
import WF_ObjParCurveEdit_2016 as ParCurveEdit
File "/Volumes/doc/Thierry/Library/Preferences/FreeCAD/Mod/WorkFeature/WorkFeature/ParCurve/WF_ObjParCurveEdit_2016.py", line 16, in <module>
import Ui.WF_ObjParCurve2DEditGui_2016 as EDIT_2D
<type 'exceptions.ImportError'>: No module named WF_ObjParCurve2DEditGui_2016
Re: MACRO:Work Feature 2014_12
Hello rentlau_64, thanks for the update!
What is the expected path?
It seems that the directory structure is more complicated in this version.
Can you post a screenshot of your directory structure starting with the .FreeCAD folder?
What is the expected path?
It seems that the directory structure is more complicated in this version.
Can you post a screenshot of your directory structure starting with the .FreeCAD folder?
"fight the good fight"
-
- Posts: 181
- Joined: Tue Oct 21, 2014 9:47 am
- Location: Pau (France)
Re: MACRO:Work Feature 2014_12
Yes the directory structure is a bit more complex.
I did that to try to handle more sub function of the big big macro.
The directory tree is :
you can test if starting from file WF_ObjParCurve_2016.py directly into FreeCad works or not?
On my Linux system it is working OK.
Let me try to fix that issue
Rentlau_64
I did that to try to handle more sub function of the big big macro.
The directory tree is :
I added the ParCurve directory and its structure.
├── README.md
├── start_WF.FCMacro
├── start_WF.py
└── WorkFeature
├── Beam
│ ├── beam.py
│ └── __init__.py
├── COPYING
├── COPYING.LESSER
├── Doc
│ ├── WF_documentation.pdf
│ └── WF_releasesDocumentation.pdf
├── Icons
│ ├── License
│ └── WF_centerObjectsPlanes.png
├── __init__.py
├── __init__.pyc
├── ParCurve
│ ├── __init__.py
│ ├── __init__.pyc
│ ├── Ressources
│ │ ├── 2DPoints.txt
│ │ ├── __init__.py
│ │ ├── Parametric2D.dat
│ │ ├── Parametric3D.dat
│ │ └── ParametricSurf.dat
│ ├── Ui
│ │ ├── __init__.py
│ │ ├── __init__.pyc
│ │ ├── sh_ui2pySide
│ │ ├── WF_ObjParCurve2DEditGui_2016.py
│ │ ├── WF_ObjParCurve2DEditGui_2016.pyc
│ │ ├── WF_ObjParCurve2DEditGui_2016.ui
│ │ ├── WF_ObjParCurve3DEditGui_2016.py
│ │ ├── WF_ObjParCurve3DEditGui_2016.pyc
│ │ ├── WF_ObjParCurve3DEditGui_2016.ui
│ │ ├── WF_ObjSurfaceEditGui_2016.py
│ │ ├── WF_ObjSurfaceEditGui_2016.pyc
│ │ ├── WF_ObjSurfaceEditGui_2016.ui
│ │ ├── WF_ParCurveGui_2016.py
│ │ ├── WF_ParCurveGui_2016.pyc
│ │ └── WF_ParCurveGui_2016.ui
│ ├── Utils
│ │ ├── Coordonnees.py
│ │ ├── Gui.py
│ │ ├── Gui.pyc
│ │ ├── __init__.py
│ │ ├── __init__.pyc
│ │ ├── Text.py
│ │ └── Text.pyc
│ ├── WF_ObjParCurve_2016.py
│ ├── WF_ObjParCurve_2016.pyc
│ ├── WF_ObjParCurveEdit_2016.py
│ └── WF_ObjParCurveEdit_2016.pyc
├── Ressources
│ ├── Parametric2D.dat
│ └── Parametric3D.dat
├── Sweep
│ └── sweep.py
├── Ui
│ ├── __init__.py
│ ├── sh_ui2pySide
│ ├── WFGui_2015.py
│ ├── WFGui_2015.ui
│ ├── WF_ObjParCurve2DEditGui_2016.py
│ ├── WF_ObjParCurve2DEditGui_2016.ui
│ ├── WF_ObjParCurve3DEditGui_2016.py
│ ├── WF_ObjParCurve3DEditGui_2016.ui
│ ├── WF_ObjSurfaceEditGui_2016.py
│ └── WF_ObjSurfaceEditGui_2016.ui
├── Utils
│ ├── __init__.py
│ ├── __init__.pyc
│ ├── WF_curve.py
│ ├── WF_line.py
│ ├── WF_plane.py
│ ├── WF_points_set.py
│ ├── WF_points_set.pyc
│ └── WF_Utils.py
├── WF_2015.py
├── WF_2015.pyc
├── WFGui_2015.py
├── WFGui_2015.pyc
├── WF_ObjParCurve_2015.py
├── WF_ObjParCurve2DEditGui_2016.py
├── WF_ObjParCurve3DEditGui_2016.py
├── WF_ObjParCurveEdit_2015.py
├── WF_ObjRot_2015.py
├── WF_ObjRot_2015.pyc
├── WF_ObjSurfaceEditGui_2016.py
├── WF_Utils_2015.py
├── WF_Utils_2015.pyc
└── WF_wf.png
you can test if starting from file WF_ObjParCurve_2016.py directly into FreeCad works or not?
On my Linux system it is working OK.
Let me try to fix that issue
Rentlau_64
Re: MACRO:Work Feature 2014_12
Thanks, this helps.rentlau_64 wrote:The directory tree is :
There are missing files on github.
The Workfeature/ParCurve/Ui sub directory is missing the .py files (only the .ui files are there) I found 3 of the 4 .py files in Workfeature/Ui directory, copied them over and got past nemesis's error. I couldn't find WF_ParCurveGui_2016.py. Also the Workfeature/ParCurve/Utils sub directory is totally missing.
"fight the good fight"
-
- Posts: 181
- Joined: Tue Oct 21, 2014 9:47 am
- Location: Pau (France)
Re: MACRO:Work Feature 2014_12
Sgrogan,
thank you for your help,
l will commit all the missing files in a few minutes.
meanwhile you can generate py files into Ui directory with:
thank you for your help,
l will commit all the missing files in a few minutes.
meanwhile you can generate py files into Ui directory with:
Rentlau_64sh sh_ui2pySide anyfile.ui
Re: MACRO:Work Feature 2014_12
Hello Rentlau_64,
that was it!
Starting fine now.
Thank you.
UR_
that was it!
Starting fine now.
Thank you.
UR_
-
- Posts: 181
- Joined: Tue Oct 21, 2014 9:47 am
- Location: Pau (France)
Re: MACRO:Work Feature 2014_12
cool!
have fun
have fun
Re: MACRO:Work Feature 2014_12
Thanks rentlau_64, everything loads now.
If I select the "Wire" tab and then then the "Curves and Surfaces" tab, when launching the Curves and Surfaces menu I get
The "Parametric Curve" tab is created though.
The "Close" button doesn't close. If I hit the x in the upper right corner the tab closes. If I then re-launch the "Curves and Surfaces" tab it opens as a new panel pinned to the right side of my screen.
OS: Windows 7
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.16.6706 (Git)
Build type: Release
Branch: releases/FreeCAD-0-16
Hash: f86a4e411ff7848dea98d7242f43b7774bee8fa0
Python version: 2.7.8
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 6.8.0.oce-0.17
If I select the "Wire" tab and then then the "Curves and Surfaces" tab, when launching the Curves and Surfaces menu I get
Code: Select all
Traceback (most recent call last):
File "C:/Users/Chris/AppData/Roaming/FreeCAD/Macro\WorkFeature\WF_2015.py", line 13441, in launch_curvesAndSurfaces
self.reg_events2D = RegressionCurve2DEvents(myObject.gui)
File "C:/Users/Chris/AppData/Roaming/FreeCAD/Macro\WorkFeature\ParCurve\WF_ObjParCurve_2016.py", line 1968, in __init__
self.regcurv2D = RegressionCurve2D(self.ui)
File "C:/Users/Chris/AppData/Roaming/FreeCAD/Macro\WorkFeature\ParCurve\WF_ObjParCurve_2016.py", line 503, in __init__
Parametric.__init__(self, gui)
File "C:/Users/Chris/AppData/Roaming/FreeCAD/Macro\WorkFeature\ParCurve\WF_ObjParCurve_2016.py", line 244, in __init__
self.setGuiStuff()
File "C:/Users/Chris/AppData/Roaming/FreeCAD/Macro\WorkFeature\ParCurve\WF_ObjParCurve_2016.py", line 255, in setGuiStuff
self.pbar = self.gui.progressBar
AttributeError: 'module' object has no attribute 'progressBar'
The "Close" button doesn't close. If I hit the x in the upper right corner the tab closes. If I then re-launch the "Curves and Surfaces" tab it opens as a new panel pinned to the right side of my screen.
OS: Windows 7
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.16.6706 (Git)
Build type: Release
Branch: releases/FreeCAD-0-16
Hash: f86a4e411ff7848dea98d7242f43b7774bee8fa0
Python version: 2.7.8
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 6.8.0.oce-0.17
"fight the good fight"