Sorry Python but it is what it is.

you are viewing a single comment's thread
view the rest of the comments
[–] 8 points 2 years ago (2 children)

Bruh idk why the difference... Educate me?

  • source
  • hideshow 4 child comments
  • [–] 5 points 2 years ago (2 children)

    Pip stores everything inside of some random txt file that doesn't differentiate between packages and dependencies.

  • source
  • parent
  • hideshow 4 child comments
  • [–] 12 points 2 years ago (1 child)

    Pip stores nothing in a text file

  • source
  • parent
  • hideshow 2 child comments
  • [–] 1 point 2 years ago (2 children)

    If you want to export your local environment, isn't usually a requirements.txt used?

  • source
  • parent
  • hideshow 4 child comments
  • [–] 5 points 2 years ago (1 child)

    Yes, but this file is created by you and not pip. It's not like package.json from npm. You don't even need to create this file.

  • source
  • parent
  • hideshow 2 child comments
  • [–] 2 points 2 years ago (2 children)

    Well if the file would be created by hand, that's very cumbersome.

    But what is sometimes done to create it automatically is using

    pip freeze > requirements. txt

    inside your virtual environment.

    You said I don't need to create this file? How else will I distribute my environment so that it can be easily used? There are a lot of other standard, like setup.py etc, so it's only one possibility. But the fact that there are multiple competing standard shows that how pip handles this is kinds bad.

  • source
  • parent
  • hideshow 4 child comments
  • [–] 2 points 2 years ago

    If you try to keep your depencies low, it's not very cumbersome. I usually do that.

    A setup.py/pyproject.toml can replace requirements. txt, but it is for creating packages and does way more than just installing dependencies, so they are not really competing.

    For scripts which have just 1 or 2 packges as depencies it's also usuall to just tell people to run pip install .

  • source
  • parent
  • [–] [S] 0 points 2 years ago (1 child)

    cargo just works, it's great and everyone loves it.

    npm has a lot of issues but in general does the job. When docs say do 'npm install X' you do it and it works.

    pip is a mess. In my experience doing 'pip install X' will maybe install something but it will not work because some dependencies will be screwed up. Using it to distribute software is pointless.

  • source
  • parent
  • hideshow 2 child comments
  • [–] 21 points 2 years ago (3 children)

    I use pip extensively and have zero issues.

    npm pulls in a million dependencies for even the simplest functionality.

  • source
  • parent
  • hideshow 6 child comments
  • [–] 11 points 2 years ago (2 children)

    Is that really the fault of the package manager or is it of the libraries you decide to use?

  • source
  • parent
  • hideshow 4 child comments
  • [–] 4 points 2 years ago (1 child)

    You’ve never had broken dependencies?

  • source
  • parent
  • hideshow 2 child comments
  • [–] [S] -1 points 2 years ago (1 child)

    It probably works for your own local project. After using it for couple of days to install some 3rd party tool my conclusion is that it has no idea about dependencies. It just downloads some dependencies in some random versions and than it never works. Completely useless.

  • source
  • parent
  • hideshow 2 child comments