Addon Manager Redesign 2021

Info about new community or project announcements, implemented features, classes, modules or APIs. Might get technical!
PLEASE DO NOT POST HELP REQUESTS OR OTHER DISCUSSIONS HERE!
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
TheMarkster
Veteran
Posts: 5505
Joined: Thu Apr 05, 2018 1:53 am

Re: Addon Manager Redesign 2021

Post by TheMarkster »

kisolre wrote: Sat Jan 01, 2022 5:18 pm
chennes wrote: Sat Jan 01, 2022 3:56 pm Can you elaborate?
There should be some default place for those macros. Now there is a Macros toolbar with just 4 buttons (adding one more would not take much space) and Macros menu item. Under the menu there is a "Recent macros" submenu. So another menu item there with "selected/shortcut/quick access..." macros that is easily populated would be nice. Same list under a button in Macros toolbar - something like Fasteners "drop down buttons" grouping style with the macros icons.
A button under the macro in addon manager that creates those shortcuts and one under the edit macro dialog.
And since there would be a menu items for those macros one could easily add those to any other toolbar if desired.
Already you can add Recent Macros as a dropdown menu to a custom toolbar.
Attachments
Snip macro screenshot-b36d8a.png
Snip macro screenshot-b36d8a.png (40 KiB) Viewed 3473 times
bleber
Posts: 259
Joined: Thu Jun 30, 2016 5:12 pm

Re: Addon Manager Redesign 2021

Post by bleber »

A macro related to draft need to go to draft, macro related to sketch need to go to sketch workbench, a general macro .....
I tri to say that if that metadata of a macro not say we're to put, a possible solution is to select the destination workbench/icon when te macro is installed.
david69
Veteran
Posts: 1773
Joined: Wed Jan 01, 2014 7:48 pm

Re: Addon Manager Redesign 2021

Post by david69 »

when I want to translate the GUI of this new interface on Crowdin, I can not find the wording, like Preference Packs. Are they missing or am I not well searching?

Edit: forget, the error is between the computer and the chair = me.
User avatar
chennes
Veteran
Posts: 3879
Joined: Fri Dec 23, 2016 3:38 pm
Location: Norman, OK, USA
Contact:

Re: Addon Manager Redesign 2021

Post by chennes »

There is a problem with the translation extraction script, though, so the dialogs aren't being translated correctly right now. I've got a PR in, I want Yorik to review before I commit.
Chris Hennes
Pioneer Library System
GitHub profile, LinkedIn profile, chrishennes.com
User avatar
chennes
Veteran
Posts: 3879
Joined: Fri Dec 23, 2016 3:38 pm
Location: Norman, OK, USA
Contact:

Re: Addon Manager Redesign 2021

Post by chennes »

I've just pushed a new PR that adds initial dependency resolution to the Addon Manager. At present it does not actually offer to do the required installations for you (that is the subject of some discussion right now), but it will clearly state a resolved list of package dependencies if Addon authors have specified them in either the old-style "metadata.txt" file, or the new "package.xml" file. It does walk the dependency graph, so the presented list should be complete (that is, if the addon depends on another addon, which depends on another addon, and so forth, the list will show all of them). It cannot do this for Python modules, which are just a flat list of required and optional modules. When using your package manager to install them, their dependencies will be resolved.

This PR also cleans up some of the output in response to various comments above. Your testing is welcome, I probably won't merge it for a few days yet, I need to test it on more platforms.

https://github.com/FreeCAD/FreeCAD/pull/5339
Chris Hennes
Pioneer Library System
GitHub profile, LinkedIn profile, chrishennes.com
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: Addon Manager Redesign 2021

Post by uwestoehr »

In the German forum (https://forum.freecadweb.org/viewtopic. ... 26#p559026) a user reported a problem with the addon manager:

- on installing the parts_library workbench it fails with

Code: Select all

21:34:19  Traceback (most recent call last):
21:34:19    File "D:\FreeCAD-build\Mod\AddonManager\addonmanager_workers.py", line 1128, in run
21:34:19      self.run_git(target_dir)
21:34:19    File "D:\FreeCAD-build\Mod\AddonManager\addonmanager_workers.py", line 1149, in run_git
21:34:19      self.run_git_clone(clonedir)
21:34:19    File "D:\FreeCAD-build\Mod\AddonManager\addonmanager_workers.py", line 1252, in run_git_clone
21:34:19      utils.symlink(
21:34:19    File "D:\FreeCAD-build\Mod\AddonManager\addonmanager_utilities.py", line 82, in symlink
21:34:19      os_symlink(source, link_name)
21:34:19  OSError: [WinError 1314] The client has no necessary permission: 'C:\\Users\\stoehr\\AppData\\Roaming\\FreeCAD\\\\Mod\\parts_library\\PartsLibrary.FCMacro' -> 'C:/Users/stoehr/AppData/Roaming/FreeCAD/Macro\\PartsLibrary.FCMacro'
I see here 2 issues:
1. the paths from/to the file should be copied are inconsistent
2. both paths only need user permissions since these are user-specific folders. So it is unclear why it is tried to gain admin privileges just to copy a fil

I am not sure the bug is in parts_library or the addon manager, though.
User avatar
chennes
Veteran
Posts: 3879
Joined: Fri Dec 23, 2016 3:38 pm
Location: Norman, OK, USA
Contact:

Re: Addon Manager Redesign 2021

Post by chennes »

The parts library is strange for a number of reasons, but in this case it looks like the embedded macro isn't symlinking correctly. I've sort of shied away from look at the PL because of the real issue (that it can't be an Addon, it's just too big). But I'll try to look into this and see if I can figure out why the symlink is failing. I assume it used to work for this person?
Chris Hennes
Pioneer Library System
GitHub profile, LinkedIn profile, chrishennes.com
mario52
Veteran
Posts: 4673
Joined: Wed May 16, 2012 2:13 pm

Re: Addon Manager Redesign 2021

Post by mario52 »

Hi

why not see the macro wiki page (as the workbench addon display the Github page) ?

mario
Maybe you need a special feature, go into Macros_recipes and Code_snippets, Topological_data_scripting.
My macros on Gist.github here complete macros Wiki and forum.
mario52
Veteran
Posts: 4673
Joined: Wed May 16, 2012 2:13 pm

Re: Addon Manager Redesign 2021

Post by mario52 »

Hi
uwestoehr wrote: Thu Jan 06, 2022 3:42 am In the German forum (https://forum.freecadweb.org/viewtopic. ... 26#p559026) a user reported a problem with the addon manager:

- on installing the parts_library workbench it fails with
no problem

addonFreeCADLibrary00.png
addonFreeCADLibrary00.png (5.56 KiB) Viewed 2933 times
addonFreeCADLibrary01.png
addonFreeCADLibrary01.png (30.21 KiB) Viewed 2930 times

OS: Windows 10 (10.0)
Word size of FreeCAD: 64-bit
Version: 0.20.26761 (Git)
Build type: Release
Python version: 3.8.12
Qt version: 5.12.9
Coin version: 4.0.0
OCC version: 7.5.3
Locale: French/Mars (fr_MA)

mario
Maybe you need a special feature, go into Macros_recipes and Code_snippets, Topological_data_scripting.
My macros on Gist.github here complete macros Wiki and forum.
User avatar
uwestoehr
Veteran
Posts: 4961
Joined: Sun Jan 27, 2019 3:21 am
Location: Germany
Contact:

Re: Addon Manager Redesign 2021

Post by uwestoehr »

chennes wrote: Thu Jan 06, 2022 4:36 am I assume it used to work for this person?
For him and also for me it worked after manually copying the macro file to the folder.

mario52 wrote: Thu Jan 06, 2022 12:01 pm no problem
Only when you have admin privileges. The issue is that it tries to gain unnecessarily admin permissions to copy a file.
Post Reply