No such file or directory: 'C:\\Users\\admin\\AppData\\Roaming\\FreeCAD\\Templates\\Asm4_infoPartConf.json'

Discussion about the development of the Assembly workbench.
Forum rules
Be nice to others! Respect the FreeCAD code of conduct!
Post Reply
IemandAnders
Posts: 14
Joined: Wed Apr 20, 2022 8:22 am

No such file or directory: 'C:\\Users\\admin\\AppData\\Roaming\\FreeCAD\\Templates\\Asm4_infoPartConf.json'

Post by IemandAnders »

Fresh install Version: 0.21.0.32198 (Git)

Code: Select all

[Errno 2] No such file or directory: 'C:\\Users\\admin\\AppData\\Roaming\\FreeCAD\\Templates\\Asm4_infoPartConf.json'Running the Python command 'Asm4_makeBOM' failed:
Traceback (most recent call last):
  File "C:\Users\admin\AppData\Roaming\FreeCAD\Mod\Assembly4\.\makeBomCmd.py", line 91, in Activated
    file = open(ConfUserFilejson, 'r')

[Errno 2] No such file or directory: 'C:\\Users\\admin\\AppData\\Roaming\\FreeCAD\\Templates\\Asm4_infoPartConf.json'

Code: Select all

[code]
OS: Windows 10 Version 2009
Word size of FreeCAD: 64-bit
Version: 0.21.0.32198 (Git)
Build type: Release
Branch: master
Hash: f51b2156f35399cab38eef1e957a59ad5a11de66
Python 3.8.16, Qt 5.15.6, Coin 4.0.0, Vtk 9.1.0, OCC 7.6.3
Locale: Dutch/Netherlands (nl_NL)
Installed mods: 
  * Assembly4 0.12.6
[/code]
Syres
Veteran
Posts: 2893
Joined: Thu Aug 09, 2018 11:14 am

Re: No such file or directory: 'C:\\Users\\admin\\AppData\\Roaming\\FreeCAD\\Templates\\Asm4_infoPartConf.json'

Post by Syres »

It looks to me that new users don't have the json file created (unless I'm missing a step) so I just removed the

Code: Select all

'''
from lines 23 and 41 from InfoPartCmd.py in my local ASM4 install and saved the changed file. See https://github.com/Zolko-123/FreeCAD_As ... Cmd.py#L23

Restart FreeCAD to activate the section of code and select any Body in the document and click Assembly menu > Edit Part Information, click the Configure fields button and click OK, this will create the Templates folder if it doesn't exist and write the missing json file. You can now go back to creating the Bill of Materials.
Syres
Veteran
Posts: 2893
Joined: Thu Aug 09, 2018 11:14 am

Re: No such file or directory: 'C:\\Users\\admin\\AppData\\Roaming\\FreeCAD\\Templates\\Asm4_infoPartConf.json'

Post by Syres »

I've submitted a fix with a little more polish https://github.com/Zolko-123/FreeCAD_Assembly4/pull/417
Syres
Veteran
Posts: 2893
Joined: Thu Aug 09, 2018 11:14 am

Re: No such file or directory: 'C:\\Users\\admin\\AppData\\Roaming\\FreeCAD\\Templates\\Asm4_infoPartConf.json'

Post by Syres »

Closed due to zero response from the maintainer.
User avatar
Zolko
Veteran
Posts: 2213
Joined: Mon Dec 17, 2018 10:02 am

Re: No such file or directory: 'C:\\Users\\admin\\AppData\\Roaming\\FreeCAD\\Templates\\Asm4_infoPartConf.json'

Post by Zolko »

Syres wrote: Mon Apr 10, 2023 10:33 am Closed due to zero response from the maintainer.
Image
try the Assembly4 workbench for FreCAD — tutorials here and here
Post Reply