Hey folks! I run Mint 18.3 and I have both Pyhon3.5 and Python3.6 since many devs got crazy with fstring syntactic sugar.
How to deal with Pip module management? The 3.5 version (which is python3) is fine and can import everything as usual, but the 3.6 version (which is python3.6) cannot.
Suggestions?

EDIT: thanks all ^^
I ended up using:
$> python3.6 -m pip install {module I need}

  • Arden
    link
    64 years ago

    I’ve always used python3 -m venv so perhaps you can use

    python3.6 -m venv newenvironemt
    . ./newenvironment/bin/activate
    pip3.6 install package
    

    To install a virtualenv tied to a specific python version?

  • @Giffen
    link
    5
    edit-2
    2 years ago

    deleted by creator

  • @DelishVeg
    link
    24 years ago

    have you tried an environment management tool like pew or pipenv?

  • @wraptile
    link
    14 years ago

    Wait, mint is still stuck on py3.5? Maybe it’s time to consider a distro switch…

    • @dioramaOP
      link
      14 years ago

      Idk, I have an older version.

      • @wraptile
        link
        14 years ago

        Generally every python3 app these days requires py3.6.1+ because this version has some major changes. You should really upgrade.

        • @dioramaOP
          link
          1
          edit-2
          4 years ago

          I’ll do so at some point. I am conservative in system updates.
          What was the driving force pushing forward from 3.5.x to 3.6.1+? Is it just syntactic sugar?

          • @wraptile
            link
            14 years ago

            There are major syntax updates for asynchronous programming, f-strings and few other minor but useful things like pathlib.Path objects which are often used in desktop apps and CLIs.

            • @dioramaOP
              link
              14 years ago

              Thanks to clarify!
              I am too noob to assess how many programs could critically benefit from these advancements. The programs I have encounter until now - a niche of a niche of the scientific community - break the backwards compatibility just for fstrings. Also, I am not confident with interfaces and more on the back-end side. That is why my experience is biased against syntactic sugar.
              I am glad people find useful these brand-new features and open to learn them. :hugging face:

              • @wraptile
                link
                24 years ago

                Cheers, 3.6 was a really good release! Releases like this are somewhat rare in programming languages so confusion is understandable :)

        • @zorkmids_for_nothing
          link
          14 years ago

          You should probably never upgrade your system version of python, as the OS might be dependant on it. If I need a newer python version than my OS supports out of the box, I’ll first check the official repos to see if a newer version is available, and otherwise I’ll compile from source, which really isn’t that difficult.

  • @dioramaOP
    link
    14 years ago

    Do you find OK I re-installed the modules I have already had via pip again?

  • @ksynwa
    link
    14 years ago

    Try this: https://stackoverflow.com/a/4910393

    On Void Linux, pip packages are installed to ~/.local/lib/python3.8/site-packages and /usr/lib/python3.8/site-packages. On Mint I suppose it should be the same or at least similar so that’s how pip packages are separted by version number.