1

In graalpython https://www.graalvm.org/python/ what is difference between ginstall and pip? Which one to use?

Paul Verest
  • 60,022
  • 51
  • 208
  • 332
  • 1
    According to [their docs](https://www.graalvm.org/reference-manual/python/Packages/) it looks like ``ginstall`` is for packages made explicitly compatible with GraalVM (i.e. extension modules like ``numpy``) whereas ``pip`` allows you to pull in regular modules, which may-or-may-not work (i.e. its a gamble for extension modules). Haven't tried it myself, though. – MisterMiyagi Jul 16 '21 at 06:55

1 Answers1

3

Unlike pip, ginstall installs package versions that are known to be (mostly) compatible with GraalPython and always runs setup.py to install the package from sources.

Both pip and ginstall apply GraalPython specific patches for some packages. This application of the patches is in pip achieved by monkey patching its internals, so it may not work with never versions of pip.

TL;DR: I would use ginstall first. If it does not support the package you want, I'd use pip. Also, avoid upgrading the bundled pip if possible.

Historically, another reason for the existence of ginstall was that GraalPython did not support SSL, which pip needs unless you use custom mirror. This not the case anymore.

Steves
  • 2,798
  • 21
  • 21