bixb922 / freezefs

Create self-extracting compressed or self-mounting archives for MicroPython
MIT License
26 stars 2 forks source link

issue if frozen_folder is not in root but in package.frozen_folder #2

Closed weenerplasticsgroup closed 4 months ago

weenerplasticsgroup commented 5 months ago

Great package, i encountered a small issue. If you place frozen_folder.py into package/frozen_folder.py I get a problem;

module = __import__( module_name )
 if module_name != "__main__":
  del sys.modules[ module_name ]
 vp = _VerbosePrint( module_name, "extract", silent )
 vp.print( f"extracting files to {target}." )
 _extract_all( module.direntries, target, overwrite, vp )

Module.direntries fails as frozen_folder.direntries does not exisits it should be package.frozen_folder.direntries

bixb922 commented 5 months ago

If you don't mind I would like you to test the latest version in this repository, or update using pip install --upgrade freezers to version 2.4. There is a fix now for the situation you describe. ~I haven't updated pypi yet.~ I hope this solves your issue.

Please let me know if it worked.

weenerplasticsgroup commented 4 months ago

It is fixed!! thanks