Python support on Windows

Guys, pretty-please, bring python to the windows images so there is less hustle setting this up with choco/conda and build time is considerably faster :pray: :pray: :pray:

4 Likes

Here is the script I use to install conda on Travis windows builds: conda4travis.

It’s similar to @kangwonlee’s script.

We also need Python for AMICI.
https://github.com/ICB-DCM/AMICI[https://github.com/ICB-DCM/AMICI]

Thank you for bringing Windows support, I recently came across.
Here is the following way to install required Python on Windows using pyenv-win (pyenv for Windows).
Note:- Choose the python version based on your need, no restrictions.
https://github.com/network-tools/shconfparser/blob/master/.travis.yml
Build passing Windows Travis CI: https://travis-ci.org/network-tools/shconfparser/builds/615217203

language: python
sudo: false

matrix:
  include:
    - os: windows
      language: sh
      before_install:
        - git clone https://github.com/pyenv-win/pyenv-win.git $HOME/.pyenv
        - export PATH="$HOME/.pyenv/pyenv-win/bin:$HOME/.pyenv/pyenv-win/shims:$PATH"
        - pyenv install -q 3.7.1
        - pyenv rehash
        - pyenv local 3.7.1
        - python --version
        - pip install -r requirements_dev.txt
    - os: linux
      python: 2.7
      before_install:
        - pip install -r requirements_dev27.txt
    - os: linux
      python: 3.7
      before_install:
        - pip install -r requirements_dev.txt

script:
  - "PYTHONPATH=. python -m pytest -v -s --cov=shconfparser tests"

after_success:
  - coveralls

Hope this helps :slight_smile:

4 Likes

My .travis.yml config file doesn’t work anymore. I used to have settings for windows

  • name: “Python 3.8.0 on Windows”
    os: windows # Windows 10.0.17134 N/A Build 17134
    language: shell # ‘language: python’ is an error on Travis CI Windows
    before_install:
    - choco install python --version 3.8.0
    - python --version
    - python -m pip install --upgrade pip
    - pip3 install --upgrade pytest
    env: PATH=/c/Python38:/c/Python38/Scripts:$PATH

and the error on travis-ci

Enjoy using Chocolatey? Explore more amazing features to take your

67experience to the next level at

68 https://chocolatey.org/compare

69The command “choco install python --version 3.8.0” failed and exited with 1 during .

70

71Your build has been stopped.

This used to work. I am not sure what happened.

Edited later: it looks like https://chocolatey.org/packages/python is down. It says “The service is unavailable.”

A post was split to a new topic: Job fails even though the exit code is 0

Any update on whether and when there will be built-in support for Python 3 in the Windows environment on Travis?

1 Like

It’s a shame this doesn’t get addressed.

Imprint