Dominique Leuenberger 2023-01-26 12:58:41 +00:00 committed by Git OBS Bridge
commit 6fb377a65e
4 changed files with 39 additions and 2 deletions

View File

@ -0,0 +1,29 @@
From 876aab4b0e7b73dd16f96c92706a6a464ddd23df Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Stefan=20Br=C3=BCns?= <stefan.bruens@rwth-aachen.de>
Date: Thu, 26 Jan 2023 00:55:12 +0100
Subject: [PATCH] FEM: femmesh: fix AttributeError: module 'numpy' has no
attribute 'int'
---
src/Mod/Fem/femmesh/meshtools.py | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/src/Mod/Fem/femmesh/meshtools.py b/src/Mod/Fem/femmesh/meshtools.py
index dd8671b0ea..7693249bb9 100644
--- a/src/Mod/Fem/femmesh/meshtools.py
+++ b/src/Mod/Fem/femmesh/meshtools.py
@@ -485,7 +485,10 @@ def get_femelement_sets(
# fem_objects = FreeCAD FEM document objects
# get femelements for reference shapes of each obj.References
count_femelements = 0
- referenced_femelements = np.zeros((max(femelement_table.keys())+1,),dtype=np.int)
+ referenced_femelements = np.zeros(
+ (max(femelement_table.keys()) + 1,),
+ dtype=int
+ )
has_remaining_femelements = None
for fem_object_i, fem_object in enumerate(fem_objects):
obj = fem_object["Object"]
--
2.38.1

View File

@ -1,7 +1,7 @@
#
# spec file for package FreeCAD-test
#
# Copyright (c) 2022 SUSE LLC
# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed

View File

@ -1,3 +1,9 @@
-------------------------------------------------------------------
Thu Jan 26 00:01:42 UTC 2023 - Stefan Brüns <stefan.bruens@rwth-aachen.de>
- Fix build after numpy 1.24 API changes, add
0001-FEM-femmesh-fix-AttributeError-module-numpy-has-no-a.patch
-------------------------------------------------------------------
Fri Dec 30 00:55:38 UTC 2022 - Stefan Brüns <stefan.bruens@rwth-aachen.de>

View File

@ -1,7 +1,7 @@
#
# spec file for package FreeCAD
#
# Copyright (c) 2022 SUSE LLC
# Copyright (c) 2023 SUSE LLC
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
@ -48,6 +48,8 @@ Patch4: 0001-Drawing-add-missing-include.patch
Patch5: 0001-FEM-add-missing-include.patch
# PATCH-FIX-UPSTREAM
Patch6: 0001-Revert-unused-parameter-warning-change.patch
# PATCH-FIX-UPSTREAM
Patch7: 0001-FEM-femmesh-fix-AttributeError-module-numpy-has-no-a.patch
# Test suite fails on 32bit and I don't want to debug that anymore
ExcludeArch: %ix86 %arm ppc s390 s390x