bixb922 / freezefs

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

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

Closed weenerplasticsgroup closed 6 months ago

weenerplasticsgroup commented 6 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 6 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 6 months ago

It is fixed!! thanks