Addon Manager hangs Freecad

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!
nobrick321
Posts: 5
Joined: Sun Dec 04, 2022 5:15 am

Re: Addon Manager hangs Freecad

Post by nobrick321 »

Hey a similar thing is happening with me. With me it is Geodesic dome. It gets permanently stuck at Getting metadata from geodesic dome. Kindly help.
Attachments
hangs.png
hangs.png (50.42 KiB) Viewed 1029 times
User avatar
chennes
Veteran
Posts: 3876
Joined: Fri Dec 23, 2016 3:38 pm
Location: Norman, OK, USA
Contact:

Re: Addon Manager hangs Freecad

Post by chennes »

It's not necessarily that specific macro that is hanging: everything in the Addon Manager is asynchronous, and there are typically six simultaneous processes downloading data. I didn't ever look to see which macro had the bad data, but I have fixed the bug in the latest nightlies/weeklies. If you can update to one of those, that will fix it for you. Otherwise, you can actually just remove the string "rawcodeurl" from line 261 of addonmanager_macro.py and that will eliminate the crash (though not the bad macro data).
Chris Hennes
Pioneer Library System
GitHub profile, LinkedIn profile, chrishennes.com
nobrick321
Posts: 5
Joined: Sun Dec 04, 2022 5:15 am

Re: Addon Manager hangs Freecad

Post by nobrick321 »

Thanks for the amazingly quick reply Chris. Honestly I'm just a regular user doing CAD and fortunately I have some experience with coding on python and I'm doing it on Windows currently. So forums like this are new to me. The speed of resolution baffles me.
Now straight to the point, I couldn't find the string "rawcodeurl" on line 261 while working on pycharm, but there was one on 264 and I removed it, but that didn't solve it. It still does the same thing. Attaching a pic of the code.
Again I hope you bear with my noobness and help me get sorted with an addon need to get my project move ahead, which is stuck at this point for the last three days.
Attachments
hangs.png
hangs.png (95.13 KiB) Viewed 950 times
User avatar
chennes
Veteran
Posts: 3876
Joined: Fri Dec 23, 2016 3:38 pm
Location: Norman, OK, USA
Contact:

Re: Addon Manager hangs Freecad

Post by chennes »

The instance of "rawcodeurl" on line 264 was probably the one you were looking for, but it looks like you also removed the curly braces that were around it (which actually needed to stay, as just an empty "{}" pair). Give that a try, and if it doesn't work I'll upload a whole new Python file you can just drop in.
Chris Hennes
Pioneer Library System
GitHub profile, LinkedIn profile, chrishennes.com
User avatar
hammax
Veteran
Posts: 1985
Joined: Thu Jan 19, 2017 5:03 pm
Location: Ammersee DE

Re: Addon Manager hangs Freecad

Post by hammax »

... installed FC.20.2 on Win10 and cannot activate AddonManager:
https://forum.freecadweb.org/viewtopic. ... 45#p646005
Attachments
AddonManager.PNG
AddonManager.PNG (9.28 KiB) Viewed 894 times
Last edited by hammax on Wed Dec 07, 2022 5:41 am, edited 1 time in total.
User avatar
chennes
Veteran
Posts: 3876
Joined: Fri Dec 23, 2016 3:38 pm
Location: Norman, OK, USA
Contact:

Re: Addon Manager hangs Freecad

Post by chennes »

That's not related to this bug -- did you check your settings in the Addon Manager preferences? There were instances in the past of Proxy getting set to something invalid.
Chris Hennes
Pioneer Library System
GitHub profile, LinkedIn profile, chrishennes.com
nobrick321
Posts: 5
Joined: Sun Dec 04, 2022 5:15 am

Re: Addon Manager hangs Freecad

Post by nobrick321 »

Hey Chris,
Unfortunately for me, it still behaves the same after the "{}" addition. But I can see there is a change in the error log.
08:39:38 During initialization the error "inconsistent use of tabs and spaces in indentation (<string>, line 48)" occurred in C:\Users\Rits\AppData\Roaming\FreeCAD\Mod\GDT\InitGui.py
08:39:38 Please look into the log file for further information
08:39:52 Previous cache process was interrupted, restarting...
08:40:35 Addon Manager: Unexpected 0 response from server
08:40:35 Failed to connect to GitHub. Check your connection and proxy settings.
08:40:51 Unable to retrieve a description from the wiki for macro documentation
08:41:02 Timeout while fetching metadata for macro Animated Constrain
08:41:02 Unable to open macro code URL https://raw.githubusercontent.com/psico ... in.FCMacro
08:41:02 Timeout while fetching metadata for macro View Rotation
08:41:02 Unable to open macro code URL https://raw.githubusercontent.com/FreeC ... on.FCMacro
08:41:10 Unable to fetch the code of this macro.
08:41:14 Timeout while fetching metadata for macro GMSH
08:41:14 Unable to open macro code URL https://raw.githubusercontent.com/psico ... sh.FCMacro
08:41:19 Timeout while fetching metadata for macro PartsLibrary
08:41:19 Unable to open macro code URL https://raw.githubusercontent.com/FreeC ... ry.FCMacro
08:41:19 Timeout while fetching metadata for macro screw maker1 2
08:41:19 Unable to open macro code URL https://raw.githubusercontent.com/FreeC ... er.FCMacro
08:41:32 Timeout while fetching metadata for macro Geodesic Dome
08:41:32 Unable to open macro code URL https://raw.githubusercontent.com/FreeC ... ic_dome.py
08:41:36 Addon Manager: Unexpected 0 response from server
08:41:36 Addon Manager: Unexpected 0 response from server
08:41:36 Addon Manager: Unexpected 0 response from server
08:41:36 Addon Manager: Unexpected 0 response from server
08:41:36 Addon Manager: Unexpected 0 response from server
08:41:36 Addon Manager: Unexpected 0 response from server
Does this mean any different?
Attachments
hangs.png
hangs.png (68.08 KiB) Viewed 807 times
User avatar
chennes
Veteran
Posts: 3876
Joined: Fri Dec 23, 2016 3:38 pm
Location: Norman, OK, USA
Contact:

Re: Addon Manager hangs Freecad

Post by chennes »

It looks like GitHub is blocking you, probably for too many requests in too short a timespan. It may be that they have tightened up their restrictions, or are geofencing you for some reason or other. Obviously even then it shouldn't just hang, but it's not a case I've been able to test easily. I'll try to give it another look later this week. It will be eliminated as an error in a couple of months in some new caching code I am working on, but until then I would be good to have a fix.
Chris Hennes
Pioneer Library System
GitHub profile, LinkedIn profile, chrishennes.com
nobrick321
Posts: 5
Joined: Sun Dec 04, 2022 5:15 am

Re: Addon Manager hangs Freecad

Post by nobrick321 »

Well thanks for looking into it and doing doing Gods work by giving your time to improve Freecad. I am at a stage in my project that I need to make drawings with GD&T, for which I needed the addon. Is there an easy way I can fix myself such a specific addition? If not then I will wait for your fix. If you need any data from my side for the bug I'm having, I'll be checking this forum every few days.
User avatar
chennes
Veteran
Posts: 3876
Joined: Fri Dec 23, 2016 3:38 pm
Location: Norman, OK, USA
Contact:

Re: Addon Manager hangs Freecad

Post by chennes »

Is this the GD&T addon you are looking for? https://github.com/juanvanyo/FreeCAD-GDT

If so, you can either use git to clone it directly into your Mod directory, or download the ZIP archive, decompress it, and move the "master" folder from it into the Mod directory, renamig it to "FreeCAD-GDT".

Your Mod directory will be something like ~/.local/share/FreeCAD/Mod on Linux, or HOME/AppData/Roaming/FreeCAD/Mod on Windows.
Chris Hennes
Pioneer Library System
GitHub profile, LinkedIn profile, chrishennes.com
Post Reply