[SOLVED][bug?] AddOn manager fails to initialise, 0.21 daily build on ubuntu ppa

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!
Post Reply
Videonauth
Posts: 4
Joined: Thu Jun 23, 2022 8:46 am

[SOLVED][bug?] AddOn manager fails to initialise, 0.21 daily build on ubuntu ppa

Post by Videonauth »

Since about two days after updating the freecad-daily package from the Ubuntu ppa the addon manager fails to initialize, see log below.

Code: Select all

10:51:21  Init:      Initializing /usr/share/freecad-daily/Mod/AddonManager... failed
10:51:21  ----------------------------------------------------------------------------------------------------
10:51:21  Traceback (most recent call last):
  File "<string>", line 140, in RunInitGuiPy
  File "<string>", line 6, in <module>
  File "/usr/share/freecad-daily/Mod/AddonManager/AddonManager.py", line 38, in <module>
    from addonmanager_workers import *
  File "/usr/share/freecad-daily/Mod/AddonManager/addonmanager_workers.py", line 84, in <module>
    import markdown
  File "/home/michael/.local/share/FreeCAD/AdditionalPythonPackages/markdown/__init__.py", line 29, in <module>
    from .core import Markdown, markdown, markdownFromFile  # noqa: E402
  File "/home/michael/.local/share/FreeCAD/AdditionalPythonPackages/markdown/core.py", line 26, in <module>
    from . import util
  File "/home/michael/.local/share/FreeCAD/AdditionalPythonPackages/markdown/util.py", line 88, in <module>
    INSTALLED_EXTENSIONS = metadata.entry_points(group='markdown.extensions')
TypeError: entry_points() got an unexpected keyword argument 'group'
10:51:21  ----------------------------------------------------------------------------------------------------
10:51:21  During initialization the error "entry_points() got an unexpected keyword argument 'group'" occurred in /usr/share/freecad-daily/Mod/AddonManager/InitGui.py
10:51:21  Please look into the log file for further information
Not sure what is wrong there and how to fix it, so i ask here before posting to github issue tracker.

Code: Select all

OS: Ubuntu 20.04.4 LTS (ubuntu:GNOME/ubuntu)
Word size of FreeCAD: 64-bit
Version: 0.21.
Build type: Release
Branch: unknown
Hash: a527daa4b3341688073ed7a8dee107e80109276d
Python 3.8.10, Qt 5.12.8, Coin 4.0.0, Vtk 7.1.1, OCC 7.5.2
Locale: English/United States (en_US)
Installed mods: 
  * A2plus 0.4.56a
  * Render 2022.2.0
  * FeedsAndSpeeds 0.4.0
  * BOLTSFC
  * Assembly4 0.12.0
  * 3D_Printing_Tools
  * fasteners 0.3.45
  * parts_library
  * Curves 0.4.4
  * Help 1.0.3
  * Behave-Dark-Colors 0.0.1
  * fcgear 1.0.0
Also not sure if this now really belong in this catergory of the forums, so please be patient with me.
Last edited by Videonauth on Thu Jun 23, 2022 11:17 am, edited 1 time in total.
Syres
Veteran
Posts: 2893
Joined: Thu Aug 09, 2018 11:14 am

Re: [maybe bug?] AddOn manager fails to initialise, 0.21 daily build on ubuntu ppa

Post by Syres »

Videonauth wrote: Thu Jun 23, 2022 8:56 am Since about two days after updating the freecad-daily package from the Ubuntu ppa the addon manager fails to initialize, see log below.
It's a bug but not in FreeCAD in that the change made works perfectly fine with markdown version 3.3.7 and I'm guessing any version other than 3.3.5 https://github.com/Python-Markdown/markdown/issues/1203

To prove which version you are using enter the following in the FreeCAD Python Console:

Code: Select all

import markdown
markdown.__version__
If you can upgrade to 3.3.7 then I cannot see a reason at present not to.
Videonauth
Posts: 4
Joined: Thu Jun 23, 2022 8:46 am

Re: [maybe bug?] AddOn manager fails to initialise, 0.21 daily build on ubuntu ppa

Post by Videonauth »

This as well results in an error on trying to import it, probably means this dependency did not get installed?

Code: Select all

import markdown
Traceback (most recent call last):
  File "<input>", line 1, in <module>
  File "/home/michael/.local/share/FreeCAD/AdditionalPythonPackages/markdown/__init__.py", line 29, in <module>
    from .core import Markdown, markdown, markdownFromFile  # noqa: E402
  File "/home/michael/.local/share/FreeCAD/AdditionalPythonPackages/markdown/core.py", line 26, in <module>
    from . import util
  File "/home/michael/.local/share/FreeCAD/AdditionalPythonPackages/markdown/util.py", line 88, in <module>
    INSTALLED_EXTENSIONS = metadata.entry_points(group='markdown.extensions')
TypeError: entry_points() got an unexpected keyword argument 'group'
Syres
Veteran
Posts: 2893
Joined: Thu Aug 09, 2018 11:14 am

Re: [maybe bug?] AddOn manager fails to initialise, 0.21 daily build on ubuntu ppa

Post by Syres »

Videonauth wrote: Thu Jun 23, 2022 10:38 am This as well results in an error on trying to import it, probably means this dependency did not get installed?
Sorry I wasn't thinking, it is definitely installed as the you would receive a completely different error message IMHO. So best to just upgrade, in my case I used pip on my Windows box and it went straight to 3.3.7.
Videonauth
Posts: 4
Joined: Thu Jun 23, 2022 8:46 am

Re: [maybe bug?] AddOn manager fails to initialise, 0.21 daily build on ubuntu ppa

Post by Videonauth »

Installing 3.3.7 systemwide did solve the error message for me, but that would mean i have to add to the bug report i just did a moment ago on github, means the markdown file getting used for building the daily is somehow outdated it seems.

LIsting with pip it did not show markdown in any way, however now it does, and FreeCAD is back to working and having an addon manager as well.
Syres
Veteran
Posts: 2893
Joined: Thu Aug 09, 2018 11:14 am

Re: [maybe bug?] AddOn manager fails to initialise, 0.21 daily build on ubuntu ppa

Post by Syres »

What needs adding to FC's code IMHO is a version check against existing markdown installation, my Linux partition had 2.6.9 which worked fine also, it's just that specific 3.3.5 that's faulty.
Videonauth
Posts: 4
Joined: Thu Jun 23, 2022 8:46 am

Re: [maybe bug?] AddOn manager fails to initialise, 0.21 daily build on ubuntu ppa

Post by Videonauth »

Thank you very much for helping out here and putting me on the right track to solve it. Should I mark this topic as solved? and yes must be something very weird as i had system wide no markdown installed so it only existed within the FreeCAD user folder which gets filled on install of the python modules for FreeCAD. The problem appeared about two days ago, the version before which was 0.20 was working fine with them. so maybe something has been changed which now needs the newer version of markdown.
Post Reply