Skip to content

[Fusion 360 Import] Importing current F3D files fails #105

@Anuril

Description

@Anuril

I've been toying around with migrating from Fusion 360 to FreeCAD and using the InventorLoader to import my F3D Files to FreeCAD.

That fails in Freecad 1.0.2 and it fails in the weekly build 2025.11.20.

I managed to get it to work, but it's not only this code in PR #101 that needs to be patched, it's also an upstream issue in FreeCAD which isn't going to fix itself at the moment. Here's my discoveries.

  1. Trying to open an exported file from Fusion360 (Fusion Version 2605.1.18 x86_64) does not work with this error:
  File "C:\Program Files\FreeCAD 1.0\bin\Lib\site-packages\freecad\module_io.py", line 16, in OpenInsertObject
    getattr(importerModule, importMethod)(objectPath, *importArgs, **importKwargs)
  File "E:\PROFILES\<user>\AppData\Roaming\FreeCAD\Mod\InventorLoader\.\importerIL.py", line 148, in open
    _open(abs_file_name, skip, only, root)
  File "E:\PROFILES\ta\AppData\Roaming\FreeCAD\Mod\InventorLoader\.\importerIL.py", line 127, in _open
    reader = read(filename)
             ^^^^^^^^^^^^^^
  File "E:\PROFILES\<user>\AppData\Roaming\FreeCAD\Mod\InventorLoader\.\importerIL.py", line 70, in read
    if (importerF3D.read(filename)):
        ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "E:\PROFILES\<user>\AppData\Roaming\FreeCAD\Mod\InventorLoader\.\importerF3D.py", line 174, in read
    folder = read_manifest(f3d, 'Manifest.dat')
             ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "E:\PROFILES\<user>\AppData\Roaming\FreeCAD\Mod\InventorLoader\.\importerF3D.py", line 107, in read_manifest
    with f3d.open(path) as manifest:
         ^^^^^^^^^^^^^^
  File "C:\Program Files\FreeCAD 1.0\bin\Lib\zipfile.py", line 1627, in open
    return ZipExtFile(zef_file, mode, zinfo, pwd, True)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Program Files\FreeCAD 1.0\bin\Lib\zipfile.py", line 841, in __init__
    self._decompressor = _get_decompressor(self._compress_type)
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "C:\Program Files\FreeCAD 1.0\bin\Lib\zipfile.py", line 740, in _get_decompressor
    _check_compression(compress_type)
  File "C:\Program Files\FreeCAD 1.0\bin\Lib\zipfile.py", line 720, in _check_compression
    raise NotImplementedError("That compression method is not supported")
<class 'NotImplementedError'>: That compression method is not supported

The issue is that the zipfile.py provided by Upstream Freecad can't unpack the f3d zipped file from Fusion. I've tried with 7-Zip and got the same error. I've noticed that my 7-Zip version was a bit out of date, so after updating, it could uncompress the f3d file just fine. I suspect the issue is that Autodesk updated their ZIP library which supports a newer compression type.

Workaround: Just uncompress the f3d file to a folder and re-zip it using Compression = Store (sometimes called 0)

  1. After doing that, the import can then proceed, but then it says it can't interpret the manifest as because the code in Fix reading manifest in F3D importer #101 needs to be merged so that works again.

I've also managed to get the importer to crash when trying to import one of my files, but i didn't get a good log from Freecad on why it crashed, it just stops, but that should probably be in a separate issue but I don't have detailed information regarding why the crash happens. The Freecad Log says:

Msg: Reading: G:\3DDesign\convert\f\convert.f3d
Msg:     ... parsing 'FusionAssetName[Active]/Breps.BlobParts/BREP.07083386-ef75-41b6-8ffd-e4b38afb530e.smb'
Msg:     ... parsing 'FusionAssetName[Active]/Breps.BlobParts/BREP.280068e7-add6-45ff-ad20-8881441e647e.smbh'
Msg:     ... parsing 'FusionAssetName[Active]/Breps.BlobParts/BREP.5e53ad70-55cf-4e11-baff-7f0a4ec19835.smbh'
Msg:     ... parsing 'FusionAssetName[Active]/Breps.BlobParts/BREP.7381bb28-ce97-44d3-a0e3-5ee487813eff.smb'
Msg:     ... parsing 'FusionAssetName[Active]/Breps.BlobParts/BREP.c028670c-368f-46ea-acbf-2754ced582c1.smb'
Msg:     ... parsing 'FusionAssetName[Active]/Breps.BlobParts/BREP.d4c50b6a-5bc5-4079-9a02-7c96119c207f.smb'
Msg:     ... parsing 'FusionAssetName[Active]/Breps.BlobParts/BREP.f6de451d-2f72-4861-b11e-9fdd847060b9.smbh'

And the windows event log just says "Application Error" and no significant information:

 freecad.exe 
   1.0.2.0 
   6892a788 
   VCRUNTIME140.dll 
   14.44.35208.0 
   6b478ebd 
   c0000005 
   000000000000556c 
   6d28 
   01dc5c83bebaf18c 
   C:\Program Files\FreeCAD 1.0\bin\freecad.exe 
   C:\Program Files\FreeCAD 1.0\bin\VCRUNTIME140.dll 
   3b058385-c014-4c87-9808-b189ba7633b2 

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions