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

zipapps with nuitka #11

Closed
ClericPy opened this issue Jan 12, 2022 · 4 comments
Closed

zipapps with nuitka #11

ClericPy opened this issue Jan 12, 2022 · 4 comments
Labels
enhancement New feature or request

Comments

@ClericPy
Copy link
Owner

build with nuitka, and the requirements from Zipapps

@ClericPy ClericPy added the enhancement New feature or request label Jan 12, 2022
@ClericPy
Copy link
Owner Author

This is not very stable.

  1. prepare a python file for entrypoint named start.py
import sys
import zipimport

path = 'app.pyz'
sys.path.insert(0, path)
zipimport.zipimporter(path).load_module('__main__')
  1. python -m nuitka --standalone --nofollow-imports --mingw64 --output-dir=out start.py
  2. prepare the zipapps entrypoint file entry_point.py
import requests

print(requests.get('http://httpbin.org/get').text)
  1. python -m zipapps -m entry_point -a entry_point.py -u AUTO requests
  2. move the app.pyz file to ./out/start.dist folder
  3. run start.exe

@ClericPy ClericPy changed the title Zipapps for nuitka Zipapps with nuitka Jan 16, 2022
@ClericPy ClericPy changed the title Zipapps with nuitka zipapps with nuitka Jan 16, 2022
@ClericPy
Copy link
Owner Author

If using -d lazy install mode, need to pip install pip -t out/start.dist

@ClericPy
Copy link
Owner Author

Windows demo, to init the folders

python -m nuitka --standalone --nofollow-imports --mingw64 --plugin-enable=tk-inter --windows-icon-from-ico=1-play.ico --output-dir out start.py&&pip install pip -t out/start.dist
python -m nuitka --standalone --nofollow-imports --mingw64 --plugin-enable=tk-inter --windows-icon-from-ico=1-play.ico --windows-disable-console --output-dir outw start.py&&pip install pip -t outw/start.dist

@ClericPy
Copy link
Owner Author

failed for using nuitka with zipapps

use nuitka with simple gui

https://github.com/ClericPy/nuitka_simple_gui

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

No branches or pull requests

1 participant