Thanks to visit codestin.com
Credit goes to github.com

Skip to content

simplifying build #1238

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

Open
stonebig opened this issue Jun 25, 2023 · 7 comments
Open

simplifying build #1238

stonebig opened this issue Jun 25, 2023 · 7 comments

Comments

@stonebig
Copy link
Contributor

stonebig commented Jun 25, 2023

make does:

  • rebuild winpython wheel
  • in make
    • create directories if needed
    • if rebuild_existing: (if remove_existing:)
      • create batch scripts
      • create launchers
      • ensure pip
      • re-install pip, setuptools winpython
      • patch standard package
      • write a changelog from collected utilitaries version and legacy package names.
  • install python via _extract_python()
  • install setuptools, wheel and winpython

zip outside of make.py

@stonebig
Copy link
Contributor Author

ideas:

  • simulation mode is useless nowodays
  • pre-building winpython wheel may be done on external step
  • doing the changelog based on the packages.ini is no more needed as pip can

@stonebig
Copy link
Contributor Author

build winpython wheel out of make.py:

  • currently in utils.rebuild_winpython() called per make.py
  • that is :
    • from winpython source directory
    • python -m flit build
    • copy result at %my_source_dirs%

@RoyiAvital
Copy link

If you move to MicroMamba all you need is the launchers and environment files + YAML file.
Wouldn't that make your life much much easier?

@firai
Copy link
Contributor

firai commented Jul 6, 2023

Just throwing ideas out there:

  • Is running ensurepip needed on Windows? Don't the common Python installations on Windows, Python installer, nuget, Chocolatey and Microsoft Store, include pip? I guess running ensurepip is required for PyPy?
  • I don't see where the two steps before "zip outside of make" are being done, but could the build directories be restructured to avoid extracting Python and re-installing setuptools, wheel and winpython again? Or maybe the zipping operation could be coded to skip some files?

EDIT:

  • Why patch pip, update pip and then patch pip again? Can't pip be updated first, and then patch pip once before installing the other packages? Even if ensurepip is run, it doesn't seem like pip needs to be patched twice.

@stonebig
Copy link
Contributor Author

stonebig commented Jul 8, 2023

Just throwing ideas out there:

  • Is running ensurepip needed on Windows? Don't the common Python installations on Windows, Python installer, nuget, Chocolatey and Microsoft Store, include pip? I guess running ensurepip is required for PyPy?

Yes, because of PyPy, ensurepip is to launch:
https://github.com/winpython/winpython/blob/master/make.py#L1971-L1973
image

  • I don't see where the two steps before "zip outside of make" are being done, but could the build directories be restructured to avoid extracting Python and re-installing setuptools, wheel and winpython again? Or maybe the zipping operation could be coded to skip some files?

EDIT:

  • Why patch pip, update pip and then patch pip again? Can't pip be updated first, and then patch pip once before installing the other packages? Even if ensurepip is run, it doesn't seem like pip needs to be patched twice.

pip is :

@firai
Copy link
Contributor

firai commented Jul 8, 2023

  • [pip is] updated to latest avoid the "there is a new version annoying message" when winPython is published

I usually get the message anyway because of the sporadic minor releases. Probably a good idea to have the latest pip when you release though.

I'm asking about the duplication in patching pip at https://github.com/winpython/winpython/blob/master/make.py#L1975 and then again at https://github.com/winpython/winpython/blob/master/make.py#L1984 after upgrading pip, which is being done before the other packages are installed/upgraded. Is patching at 1984 not enough to make the distribution movable? Can the pre-patch at 1975 be removed?

@stonebig stonebig added this to the 2025-03 PEP 751 / AI local milestone May 4, 2025
@stonebig
Copy link
Contributor Author

stonebig commented May 4, 2025

a lot of rework has been done this winter 2024-2025 already

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

No branches or pull requests

3 participants