Debian Bug report logs - #1051353
freecad: Can't create window in arch workbench

version graph

Package: freecad; Maintainer for freecad is Debian Science Maintainers <[email protected]>; Source for freecad is src:freecad (PTS, buildd, popcon).

Reported by: philippe <[email protected]>

Date: Wed, 6 Sep 2023 19:03:02 UTC

Severity: grave

Tags: patch

Found in version freecad/0.20.2+dfsg1-4

Fixed in version 0.20.2+dfsg1-6

Done: Petter Reinholdtsen <[email protected]>

Reply or subscribe to this bug.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to [email protected], Debian Science Maintainers <[email protected]>:
Bug#1051353; Package freecad. (Wed, 06 Sep 2023 19:03:04 GMT) (full text, mbox, link).


Acknowledgement sent to philippe <[email protected]>:
New Bug report received and forwarded. Copy sent to Debian Science Maintainers <[email protected]>. (Wed, 06 Sep 2023 19:03:04 GMT) (full text, mbox, link).


Message #5 received at [email protected] (full text, mbox, reply):

From: philippe <[email protected]>
To: Debian Bug Tracking System <[email protected]>
Subject: freecad: Can't create window in arch workbench
Date: Wed, 06 Sep 2023 21:01:43 +0200
Package: freecad
Version: 0.20.2+dfsg1-4
Severity: grave
Justification: renders package unusable

Dear Maintainer,

*** Reporter, please consider answering these questions, where appropriate ***

   * What led up to the situation?

   * What exactly did you do (or not do) that was effective (or
     ineffective)?
I try to create an house with the arch workbench.
When I want to add a window, this is not created

   * What was the outcome of this action?
I get this error :
20:54:51  <class 'AttributeError'>
20:54:51  Traceback (most recent call last):
20:54:51    File "/usr/share/freecad/Mod/Draft/draftguitools/gui_snapper.py",
line 1417, in click
20:54:51      accept()
20:54:51    File "/usr/share/freecad/Mod/Draft/draftguitools/gui_snapper.py",
line 1429, in accept
20:54:51      if len(inspect.getargspec(callback).args) > 1:
20:54:51             ^^^^^^^^^^^^^^^^^^
20:54:51  AttributeError: module 'inspect' has no attribute 'getargspec'. Did
you mean: 'getargs'?

It seems to be a conflict with phyton version (getargspec seems to be
depracted)

   * What outcome did you expect instead?

*** End of the template - remove these template lines ***


-- System Information:
Debian Release: 12.1
  APT prefers stable-security
  APT policy: (960, 'stable-security'), (950, 'stable-updates'), (910, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 6.1.0-11-amd64 (SMP w/8 CPU threads; PREEMPT)
Locale: LANG=fr_FR.UTF-8, LC_CTYPE=fr_FR.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages freecad depends on:
ii  freecad-python3  0.20.2+dfsg1-4

Versions of packages freecad recommends:
ii  calculix-ccx  2.20-1
ii  graphviz      2.42.2-7+b3

Versions of packages freecad suggests:
ii  povray  1:3.7.0.10-2+b2

-- no debconf information



Information forwarded to [email protected], Debian Science Maintainers <[email protected]>:
Bug#1051353; Package freecad. (Wed, 06 Sep 2023 22:51:03 GMT) (full text, mbox, link).


Acknowledgement sent to Petter Reinholdtsen <[email protected]>:
Extra info received and forwarded to list. Copy sent to Debian Science Maintainers <[email protected]>. (Wed, 06 Sep 2023 22:51:03 GMT) (full text, mbox, link).


Message #10 received at [email protected] (full text, mbox, reply):

From: Petter Reinholdtsen <[email protected]>
To: philippe <[email protected]>, [email protected]
Subject: Re: freecad: Can't create window in arch workbench
Date: Thu, 7 Sep 2023 00:49:20 +0200
[philippe]
> It seems to be a conflict with phyton version (getargspec seems to be
> depracted)

Thank you for discovering this problem. :)

While I doubt 'grave' is the correct severity for this, as it do not
render FreeCAD completely useless that one of the workbenches do not
work, and I personally is using the Part Design and Part
workbenches with success, I can reproduce the issue and the problem seem
to be due to python version incompatibility.

The method is present in Python 3.8[1], but not in 3.11[2] used in Debian
at the moment.  Only the recommended replacement getfullargspec() is
present in 3.11.  This issue need to be fixed upstream, as it is also
present in version 0.21.

[1] <URL: https://docs.python.org/3.8/library/inspect.html#inspect.getargspec >
[2] <URL: https://docs.python.org/3.11/library/inspect.html#inspect.getfullargspec >
-- 
Happy hacking
Petter Reinholdtsen



Information forwarded to [email protected], Debian Science Maintainers <[email protected]>:
Bug#1051353; Package freecad. (Thu, 07 Sep 2023 05:51:04 GMT) (full text, mbox, link).


Acknowledgement sent to Petter Reinholdtsen <[email protected]>:
Extra info received and forwarded to list. Copy sent to Debian Science Maintainers <[email protected]>. (Thu, 07 Sep 2023 05:51:04 GMT) (full text, mbox, link).


Message #15 received at [email protected] (full text, mbox, reply):

From: Petter Reinholdtsen <[email protected]>
To: philippe <[email protected]>, [email protected]
Subject: Re: freecad: Can't create window in arch workbench
Date: Thu, 07 Sep 2023 07:46:26 +0200
Control: tags -1 + patch

For the record, I was mistaken about the problem also being present in
FreeCAD 0.21.  I was comparing against the wrong file locally to come to
this incorrect conclusion.  The follow change to the problematic
getargspec() calls are lifted from upstream.  Can you test to see if it
solve your problem?  There are other changes in 0.21 to this file, and I
am unsure if any of them are needed.  It might be a better idea to
upgrade FreeCAD in Debian to 0.21 instead of backporting this fix.

--- a/src/Mod/Draft/draftguitools/gui_snapper.py
+++ b/src/Mod/Draft/draftguitools/gui_snapper.py
@@ -1426,7 +1426,7 @@ class Snapper:
             Gui.Snapper.off()
             self.ui.offUi()
             if callback:
-                if len(inspect.getargspec(callback).args) > 1:
+                if len(inspect.getfullargspec(callback).args) > 1:
                     obj = None
                     if self.snapInfo and ("Object" in self.snapInfo) and self.snapInfo["Object"]:
                         obj = App.ActiveDocument.getObject(self.snapInfo["Object"])
@@ -1445,7 +1445,7 @@ class Snapper:
             Gui.Snapper.off()
             self.ui.offUi()
             if callback:
-                if len(inspect.getargspec(callback).args) > 1:
+                if len(inspect.getfullargspec(callback).args) > 1:
                     callback(None, None)
                 else:
                     callback(None)


-- 
Happy hacking
Petter Reinholdtsen



Added tag(s) patch. Request was from Petter Reinholdtsen <[email protected]> to [email protected]. (Thu, 07 Sep 2023 05:51:04 GMT) (full text, mbox, link).


Information forwarded to [email protected], Debian Science Maintainers <[email protected]>:
Bug#1051353; Package freecad. (Thu, 07 Sep 2023 06:00:05 GMT) (full text, mbox, link).


Acknowledgement sent to Petter Reinholdtsen <[email protected]>:
Extra info received and forwarded to list. Copy sent to Debian Science Maintainers <[email protected]>. (Thu, 07 Sep 2023 06:00:05 GMT) (full text, mbox, link).


Message #22 received at [email protected] (full text, mbox, reply):

From: Petter Reinholdtsen <[email protected]>
To: philippe <[email protected]>, [email protected]
Subject: Re: freecad: Can't create window in arch workbench
Date: Thu, 07 Sep 2023 07:56:47 +0200
Control: notfound -1 0.20.2+dfsg1-6

I further discovered that this patch is already in freecad
0.20.2+dfsg1-6 as 0010-arch-tutorial.patch, included to fix
<URL: https://bugs.debian.org/1031566 >.  I guess the fix for stable
might be to backport this patch to 0.20.2+dfsg1-4.

<URL: https://sources.debian.org/src/freecad/0.20.2+dfsg1-10/debian/patches/0010-arch-tutorial.patch/ >

-- 
Happy hacking
Petter Reinholdtsen



Reply sent to Petter Reinholdtsen <[email protected]>:
You have taken responsibility. (Sat, 09 Sep 2023 06:12:16 GMT) (full text, mbox, link).


Notification sent to philippe <[email protected]>:
Bug acknowledged by developer. (Sat, 09 Sep 2023 06:12:17 GMT) (full text, mbox, link).


Message #27 received at [email protected] (full text, mbox, reply):

From: Petter Reinholdtsen <[email protected]>
To: [email protected]
Subject: Re: freecad: Can't create window in arch workbench
Date: Sat, 09 Sep 2023 08:08:57 +0200
Version: 0.20.2+dfsg1-6

Trying again to set the correct version metadata for this bug.  It was
fixed a while back and should perhaps be merged with #1031566.  Leaving
the severity as is in case a backport of the fix to stable is considered.

-- 
Happy hacking
Petter Reinholdtsen



Send a report that this bug log contains spam.


Debian bug tracking system administrator <[email protected]>. Last modified: Thu May 15 15:50:16 2025; Machine Name: buxtehude

Debian Bug tracking system

Debbugs is free software and licensed under the terms of the GNU General Public License version 2. The current version can be obtained from https://bugs.debian.org/debbugs-source/.

Copyright © 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson, 2005-2017 Don Armstrong, and many other contributors.