Giter Club home page Giter Club logo

Comments (14)

mitsuhiko avatar mitsuhiko commented on May 31, 2024 5

I would not say so. Nothing is ever quite as black and white, it's a matter of priorities. The experience I care most about is the one where a developer downloads a tool (let's call it rye) which they can use to get a functioning Python installation going on their system that gives them the same experience as on any other system (eg: the rustup + cargo) experience. This might very well involve having to fall back to system installations of Python, I don't quite know the answer to it.

However what I do know is that priority wise right now is making sure that on systems where the self installed downloaded versions should work, they do work, before looking at system Python installations. System python installations are a huge source of frustration right now because of how many customizations they have.

Here some motivational reasons on this:

from rye.

WhyNotHugo avatar WhyNotHugo commented on May 31, 2024 2

Oh, I though that the error had been because rye had tried to execute a python which I had not downloaded/fetched first (e.g. Python interpreter not found).

To be honest, I'm pretty discomforted by the fact that rye silently downloaded some Python binaries from some random third party source and executed them without any confirmation or indication. rye should definitely prompt before doing such things.

In any case, this general approach is a recipe for disaster, you can't just pull binaries from one distribution channel and run them elsewhere and expect them to work. You should never pull binaries from different sources unless they're explicitly built for the target host. Maybe that would work if they're statically linked, but it still sounds like a bad idea with tiny gotchas all over.

This approach of "my distribution is broken and doesn't ship a working Python, I'll pretend that distributions don't exist and reinvent things from scratch" is rather childish IMHO, and you're basically making a solution designed for broken distributions and ignoring the non-broken ones. But hey, you build for the future you want to see, so if you want to see a future where these distributions (which don't even ship a working Python) flourish, then this is definitely the way to go.

In any case, this is covered by #30, there's nothing actionable on this ticket.

Keep in mind that the Rye project is prioritizing the user experience of having a working Python installation downloaded from the internet.

Yup, it'd been pointed out to me. Regrettably, I'm not looking to switch my Python distribution nor package manager, both the ones I have work for me. I landed here expecting to be able to use rye as a dependency/virtualenv manager, but it's seems this is an all or nothing, so I'll just stick to pip-tools and mkvirtualenv until somebody tries to build something better on top of what already exists.

from rye.

mitsuhiko avatar mitsuhiko commented on May 31, 2024 1

@WhyNotHugo I absolutely understand that desire, but in some sense my goal is to get an experience going first that involves ensuring a working cpython installation from the internet, before going into solving distribution provided python installations. These have been a historic challenge to providing a reliable packaging experience.

from rye.

alissonlauffer avatar alissonlauffer commented on May 31, 2024 1

It doesn't work because Alpine Linux uses musl, and the installed python build is built against glibc. The "no such file or directory" error does not mean that the executable was not found, but rather that the required interpreter to execute it (/lib64/ld-linux-x86-64.so.2) was not found because the host uses musl.

from rye.

mitsuhiko avatar mitsuhiko commented on May 31, 2024

@WhyNotHugo What CPU architecture and operating system are you on?

from rye.

WhyNotHugo avatar WhyNotHugo commented on May 31, 2024

Alpine Edge, amd64.

Not sure if related, but I've no idea where where the 3.10 one came from:

from rye.

mitsuhiko avatar mitsuhiko commented on May 31, 2024

Alright, so here is what's happening. At the moment rye always uses [email protected] from the indygreg builds. I am assuming that for whatever reason that build is not working for you. Might be worth trying to run this and see what it outputs:

$ ~/.rye/py/[email protected]/install/bin/python3 --version

from rye.

WhyNotHugo avatar WhyNotHugo commented on May 31, 2024

I'd rather opt out of downloading python binaries entirely. My distro has working Python packages and I'd rather rely on those than pulling binaries from elsewhere.

from rye.

WhyNotHugo avatar WhyNotHugo commented on May 31, 2024
> ~/.rye/py/[email protected]/install/bin/python3 --version

zsh: no such file or directory: /home/hugo/.rye/py/[email protected]/install/bin/python3

from rye.

mitsuhiko avatar mitsuhiko commented on May 31, 2024

@WhyNotHugo this is puzzling

  1. does the error still happen if you rm -rf ~/.rye/py/[email protected]?
  2. what is the contents of ~/.rye/py/[email protected] and ~/rye/py/[email protected]/install/bin?

from rye.

WhyNotHugo avatar WhyNotHugo commented on May 31, 2024

my goal is to get an experience going first that involves ensuring a working cpython installation from the internet

But this is exactly the problem that a software distribution solves. E.g.: Alpine has python3, py3-pip, etc. Fedora, Arch, OpenBSD, and many others all have equivalent packages.

Your distribution no existing mechanism to have a working Python at all?

from rye.

WhyNotHugo avatar WhyNotHugo commented on May 31, 2024

I think this comes down to #30

from rye.

hemangjoshi37a avatar hemangjoshi37a commented on May 31, 2024

To resolve this issue, please follow these steps:

  1. Remove the existing [email protected] directory by executing the following command: rm -rf ~/.rye/py/[email protected].
  2. Check the contents of the ~/.rye/py/[email protected] and ~/rye/py/[email protected]/install/bin directories.
  3. Verify the Python version on your system by running python3 --version.
  4. If you have a working Python installation on your system, use it instead of the one provided by Rye.
  5. Share the output of the above commands with the repository maintainers for further assistance.

Keep in mind that the Rye project is prioritizing the user experience of having a working Python installation downloaded from the internet. This may change in the future to accommodate system installations of Python, but for now, the focus is on ensuring the downloaded versions work properly.

from rye.

mitsuhiko avatar mitsuhiko commented on May 31, 2024

Closing this as resolved for now. The error message is better now. For actually supporting MUSL I do not have a plan yet.

from rye.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.