[FIXED] [Bug#4381] OpenSCAD icon missing in 2 scenarios

Post here for help on using FreeCAD's graphical user interface (GUI).
Forum rules
and Helpful information
IMPORTANT: Please click here and read this first, before asking for help

Also, be nice to others! Read the FreeCAD code of conduct!
fc_tofu
Posts: 653
Joined: Sun Jan 05, 2020 4:56 pm

[FIXED] [Bug#4381] OpenSCAD icon missing in 2 scenarios

Post by fc_tofu »

Case 1. icon of feature "Increase Tolerance" missing in TreeView
Reproduce: OpenSCAD >Increase Tolerance Feature
fsc_2020-06-20_040413b.jpg
fsc_2020-06-20_040413b.jpg (32.37 KiB) Viewed 2048 times
Error msg in Report:

Code: Select all

Traceback (most recent call last):
  File "E:\WINAPP_B\FreeCAD_0.19\Mod\OpenSCAD\OpenSCADFeatures.py", line 85, in getIcon
    import freecad.OpenSCAD.OpenSCAD_rc
<class 'ModuleNotFoundError'>: No module named 'freecad.OpenSCAD'
In FC0.18/win10x64, icon exists,
fsc_2020-06-20_041814b.jpg
fsc_2020-06-20_041814b.jpg (15.47 KiB) Viewed 2048 times

Case 2. icon missing in global toolbar after customizer
Reproduce:
Customize >Toolbar >OpenSCAD >Mesh Booleans =>Global
Restart FC
fsc_2020-06-20_041154b.jpg
fsc_2020-06-20_041154b.jpg (57.48 KiB) Viewed 2048 times
fsc_2020-06-20_041308b.jpg
fsc_2020-06-20_041308b.jpg (38.23 KiB) Viewed 2048 times
This issue donnot happen to FC0.18.4/win10x64.
This issue donot happen to customized LOCAL toolbar.

BTW. OpenSCAD executable already installed on same computer, and setup in FC's pref >OpenSCAD. (But this seems doesn't matter here.)
fsc_2020-06-20_041734.jpg
fsc_2020-06-20_041734.jpg (36.49 KiB) Viewed 2048 times

Code: Select all

OS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.21514 (Git)
Build type: Release
Branch: master
Hash: 89ddab33f692a9bd739171689f9ab0eb58d64b35
Python version: 3.8.2
Qt version: 5.12.5
Coin version: 4.0.0
OCC version: 7.4.0
Locale: English/United States (en_US)
Tracker:
issue #4381
Last edited by fc_tofu on Mon Jun 22, 2020 4:30 am, edited 3 times in total.
fc_tofu
Posts: 653
Joined: Sun Jan 05, 2020 4:56 pm

Re: [Regression] OpenSCAD icon missing in 2 scenarios

Post by fc_tofu »

keithsloan52 wrote: Sat Feb 08, 2020 7:27 am Ping
keithsloan52
Veteran
Posts: 2756
Joined: Mon Feb 27, 2012 5:31 pm

Re: [Regression] OpenSCAD icon missing in 2 scenarios

Post by keithsloan52 »

fc_tofu wrote: Fri Jun 19, 2020 8:39 pm Case 1. icon of feature "Increase Tolerance" missing in TreeView
Reproduce: OpenSCAD >Increase Tolerance Feature

fsc_2020-06-20_040413b.jpg

Error msg in Report:

Code: Select all

Traceback (most recent call last):
  File "E:\WINAPP_B\FreeCAD_0.19\Mod\OpenSCAD\OpenSCADFeatures.py", line 85, in getIcon
    import freecad.OpenSCAD.OpenSCAD_rc
<class 'ModuleNotFoundError'>: No module named 'freecad.OpenSCAD'
In FC0.18/win10x64, icon exists,
fsc_2020-06-20_041814b.jpg


Case 2. icon missing in global toolbar after customizer
Reproduce:
Customize >Toolbar >OpenSCAD >Mesh Booleans =>Global
Restart FC

fsc_2020-06-20_041154b.jpg

fsc_2020-06-20_041308b.jpg

This issue donnot happen to FC0.18.4/win10x64.
This issue donot happen to customized LOCAL toolbar.

BTW. OpenSCAD executable already installed on same computer, and setup in FC's pref >OpenSCAD. (But this seems doesn't matter here.)

fsc_2020-06-20_041734.jpg

Code: Select all

OS: Windows 10 (10.0)
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.19.21514 (Git)
Build type: Release
Branch: master
Hash: 89ddab33f692a9bd739171689f9ab0eb58d64b35
Python version: 3.8.2
Qt version: 5.12.5
Coin version: 4.0.0
OCC version: 7.4.0
Locale: English/United States (en_US)
For some reason a dot has gone missing should be import .freecad.OpenSCAD.OpenSCAD_rc

i.e. the freecad should start with a dot for current directory.

Pull Request - made
fc_tofu
Posts: 653
Joined: Sun Jan 05, 2020 4:56 pm

Re: [Regression] OpenSCAD icon missing in 2 scenarios

Post by fc_tofu »

keithsloan52 wrote: Sat Jun 20, 2020 4:59 pm For some reason a dot has gone missing should be import .freecad.OpenSCAD.OpenSCAD_rc
Thank you. But your method doesnot work in both cases.

My attempt
File: OpenSCADFeatures.py
Line: 85

Code: Select all

        import freecad.OpenSCAD.OpenSCAD_rc
Change to

Code: Select all

        import OpenSCAD_rc
This fixes case 1, but doesnot fix case 2.

Please find a better fix.
keithsloan52
Veteran
Posts: 2756
Joined: Mon Feb 27, 2012 5:31 pm

Re: [Regression] OpenSCAD icon missing in 2 scenarios

Post by keithsloan52 »

fc_tofu wrote: Sat Jun 20, 2020 6:09 pm
keithsloan52 wrote: Sat Jun 20, 2020 4:59 pm For some reason a dot has gone missing should be import .freecad.OpenSCAD.OpenSCAD_rc
Thank you. But your method doesnot work in both cases.

My attempt
File: OpenSCADFeatures.py
Line: 85

Code: Select all

        import freecad.OpenSCAD.OpenSCAD_rc
Change to

Code: Select all

        import OpenSCAD_rc
This fixes case 1, but doesnot fix case 2.

Please find a better fix.
I am not that familiar with Qt dialogs and Windows, hopefully somebody else who does might fix.
fc_tofu
Posts: 653
Joined: Sun Jan 05, 2020 4:56 pm

Re: [Regression] OpenSCAD icon missing in 2 scenarios

Post by fc_tofu »

keithsloan52 wrote: Sat Jun 20, 2020 7:08 pm I am not that familiar with Qt dialogs and Windows, hopefully somebody else who does might fix.
Ok, thank you. Let's wait for someone give a try.
keithsloan52
Veteran
Posts: 2756
Joined: Mon Feb 27, 2012 5:31 pm

Re: [Regression] OpenSCAD icon missing in 2 scenarios

Post by keithsloan52 »

fc_tofu wrote: Sun Jun 21, 2020 12:42 pm
keithsloan52 wrote: Sat Jun 20, 2020 7:08 pm I am not that familiar with Qt dialogs and Windows, hopefully somebody else who does might fix.
Ok, thank you. Let's wait for someone give a try.
Would be best if you posted as Bug see https://wiki.freecadweb.org/Tracker

@fc_tofu
fc_tofu
Posts: 653
Joined: Sun Jan 05, 2020 4:56 pm

Re: [Regression] OpenSCAD icon missing in 2 scenarios

Post by fc_tofu »

keithsloan52 wrote: Sun Jun 21, 2020 2:49 pm
Would be best if you posted as Bug see https://wiki.freecadweb.org/Tracker
Reported now.
digitalgoose
Posts: 16
Joined: Thu Mar 02, 2017 12:36 am

Re: [Bug#4381] OpenSCAD icon missing in 2 scenarios

Post by digitalgoose »

Post Reply