Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Editing part information #492

Open
electromuis opened this issue May 15, 2024 · 2 comments
Open

Editing part information #492

electromuis opened this issue May 15, 2024 · 2 comments

Comments

@electromuis
Copy link

When trying to edit the part information fields I get the following error:

12:58:23 Traceback (most recent call last): File "C:\Users\Electromuis\AppData\Roaming\FreeCAD\Mod\Assembly4\.\infoPartCmd.py", line 594, in accept for prop in infoPartCmd.partInfo: <class 'AttributeError'>: type object 'infoPartCmd' has no attribute 'partInfo'

Assembly 4 version: 0.50.12
FreeCAD version: 0.21.2

@Zolko-123
Copy link
Owner

yeah I know, PartInfo and BOM are broken. I hoped that someone would come up with a good solution, but they all bring some personal solution. I'll bring back my old limited code.

What fields do you think should a PartInfo have ? My suggestion currently is:

  • PartName
  • PartRef
  • PartType
  • Author
  • Description
  • Material (or density)

These should be filled by the designer. Additionally, I thought about adding following fields that are filled by the software :

  • volume
  • weight
  • CoG
  • Ixx
  • CutLength

These are easy for Bodies (links-to bodies) but more difficult for Parts (and therefore sub-assemblies)

@Buckelpiste
Copy link

Got a similar problem. Actually, I get a truncated BOM with the BOM workbench, it lacks any field apart from Number, Qty, Label, Description and File information. To be fair, I haven't typed in any PartInfo whatsoever. I worked with bodies, sketches and padding and created an assembly out of it. IMO a BOM should just take the measurements of the bodies/parts and sum it up (if that only was so easy...). Also most PartInfo can be autofilled if not specified: Name = Name of body, of file etc. Author = name of user. Material = no autofill (not necessary for simple woodworking).

That said, using the generic BOM function of Assembly4 doesn't work at all here.

Latest versions on linux.

09:51:11  ASM4> BOM following sub-assemblies
09:51:11  TypeID = App::Part Level = 0  Parent = None  Obj.Fullname =AZi_EBS_v2#Assembly
09:51:11  ------------
09:51:11  Level = 0  Parent = None  BomKeyAF=AZi_EBS_v2#Assembly
09:51:11  47
09:51:11  We have an assembly
09:51:11  Customization failed or is not setup : Function not implemented yet  Attempting to insert default values
09:51:11  Running the Python command 'Asm4_makeBOM' failed:
Traceback (most recent call last):
  File "/home/XXX/.local/share/FreeCAD/Mod/Assembly4/./makeBomCmd.py", line 125, in Activated
    self.RecursivelyAutoFillPartInfoInBom(self.model)
  File "/home/XXX/.local/share/FreeCAD/Mod/Assembly4/./makeBomCmd.py", line 173, in RecursivelyAutoFillPartInfoInBom
    infoPartCmd.infoPartUI.infoDefault(obj)
  File "/home/XXX/.local/share/FreeCAD/Mod/Assembly4/./infoPartCmd.py", line 394, in infoDefault
    infoDefault(part)
  File "/home/XXX/.local/share/FreeCAD/Mod/Assembly4/./infoPartCmd.py", line 122, in infoDefault
    AssignValuesForAutofile(part, doc,None)
  File "/home/XXX/.local/share/FreeCAD/Mod/Assembly4/./infoPartCmd.py", line 225, in AssignValuesForAutofile
    raise e
  File "/home/XXX/.local/share/FreeCAD/Mod/Assembly4/./infoPartCmd.py", line 217, in AssignValuesForAutofile
    raise Exception(f"{part.FullName} in {doc.FileName} is missing Part information fields. It needs to be reset in Edit Part Information- Configure fields .")

AZi_EBS_v2#Assembly in /home/XXX/DIR/AZi_EBS_v2.FCStd is missing Part information fields. It needs to be reset in Edit Part Information- Configure fields .307.85 Selection.cpp(1472): Object not found

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants