# Julia is now available on Travis Windows builds

**URL:** https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187
**Category:** Announcements
**Tags:** ci
**Created:** [August 5, 2019, 7:57pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187 "2019-08-05T19:57:03Z")
**Posts on this page:** 20
**Page:** 1

<div class="post-metadata">

### Author: ![ararslan](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ararslan/32/3825_2.png) [@ararslan](https://discourse.julialang.org/u/ararslan)
#### Post date: [August 5, 2019, 7:57pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/1 "2019-08-05T19:57:03Z")

</div>

Exciting news for people who love cross-platform CI! As you may know, [Travis added Windows builds last year](https://blog.travis-ci.com/2018-10-11-windows-early-release). I’m pleased to announce that after some testing and working out the kinks, Julia is now available out of the box on Travis Windows builds!

To illustrate how it’s used, I’ve set up my package called [Jackknife](https://github.com/ararslan/Jackknife.jl) to use Travis builds for Linux, macOS, and Windows simultaneously. You can see the configuration file [here](https://github.com/ararslan/Jackknife.jl/blob/master/.travis.yml). It’s as easy as adding `windows` to the `os` list!

A common practice with Julia Windows builds on AppVeyor is to include testing on 32-bit Windows. That is also possible for Travis! See [this build](https://travis-ci.org/ararslan/Jackknife.jl/builds/568049240) for an example, and click “view config” to see how it’s set up. (Note that it’s not as simple as making `arch` a list like `os` or `julia` that gets expanded in the build matrix, and note that for `language: julia`, the `arch` specification is only recognized for Windows builds for now.)

A special thanks to @simonbyrne for getting 95% of the way there, @Gnimuc for valuable insight that worked out a blocking issue, and Hiro Asari (BanzaiMan) from Travis for working with us to push it over the finish line.

Enjoy your build!

---

<div class="post-metadata">

### Author: ![chakravala](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chakravala/32/6832_2.png) [@chakravala](https://discourse.julialang.org/u/chakravala)
#### Post date: [August 5, 2019, 8:47pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/2 "2019-08-05T20:47:55Z")

</div>

Is it recommended to deprecate `appveyor` builds?

---

<div class="post-metadata">

### Author: ![ararslan](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ararslan/32/3825_2.png) [@ararslan](https://discourse.julialang.org/u/ararslan)
#### Post date: [August 5, 2019, 9:18pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/3 "2019-08-05T21:18:25Z")

</div>

Nah. Use whichever build service you like. 🙂

---

<div class="post-metadata">

### Author: ![davidanthoff](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/davidanthoff/32/223493_2.png) [@davidanthoff](https://discourse.julialang.org/u/davidanthoff)
#### Post date: [August 5, 2019, 9:43pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/4 "2019-08-05T21:43:39Z")

</div>

That is so awesome, thank you!

Could one add another `os` like `windows-32bit` that would still allow us to just use the nice `os` list but still test on 32 bit?

I think testing on 32 bit is really, really valuable, I tend to catch a lot of bugs that way.

---

<div class="post-metadata">

### Author: ![ararslan](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ararslan/32/3825_2.png) [@ararslan](https://discourse.julialang.org/u/ararslan)
#### Post date: [August 5, 2019, 9:56pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/5 "2019-08-05T21:56:38Z")

</div>

> [@davidanthoff](#):
>
> Could one add another `os` like `windows-32bit` that would still allow us to just use the nice `os` list but still test on 32 bit?

AFAIK no. If I’m not mistaken, the values in `os` must match to those provided by Travis itself. Also note that saying `os: windows-32bit` would be a misnomer, as the build itself is still 64-bit Windows, it just downloads and uses the 32-bit Julia binary, same as running 32-bit on AppVeyor.

> [@davidanthoff](#):
>
> I think testing on 32 bit is really, really valuable

Yeah for sure. And it is possible, it’s just not super convenient at the moment. Ideally I’d like `arch` to accept a list so that the build matrix would be `os` \* `arch` \* `julia`, but it doesn’t do that at the moment.

---

<div class="post-metadata">

### Author: ![SaschaMann](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/saschamann/32/2852_2.png) [@SaschaMann](https://discourse.julialang.org/u/SaschaMann)
#### Post date: [August 5, 2019, 10:15pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/6 "2019-08-05T22:15:04Z")

</div>

This is great! Already caught a bug thanks to 32 bit testing. 😃

One question: Right now you can’t tell apart the architectures in the build overview. Is there a nice way to change the display name of the operating system? Setting an unused environment variable works, but it feels a bit hacky.

---

<div class="post-metadata">

### Author: ![ararslan](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ararslan/32/3825_2.png) [@ararslan](https://discourse.julialang.org/u/ararslan)
#### Post date: [August 5, 2019, 10:16pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/7 "2019-08-05T22:16:22Z")

</div>

> [@SaschaMann](#):
>
> Is there a nice way to change the display name of the operating system?

Unfortunately not as far as I can tell.

---

<div class="post-metadata">

### Author: ![giordano](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/giordano/32/2166_2.png) [@giordano](https://discourse.julialang.org/u/giordano)
#### Post date: [August 5, 2019, 10:17pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/8 "2019-08-05T22:17:55Z")

</div>

If you use the matrix you can set the name of each job, it’s the `name` field: [Customizing the Build - Travis CI](https://docs.travis-ci.com/user/customizing-the-build/#naming-jobs-within-matrices)

---

<div class="post-metadata">

### Author: ![Nosferican](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nosferican/32/9275_2.png) [@Nosferican](https://discourse.julialang.org/u/Nosferican)
#### Post date: [August 6, 2019, 12:31am UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/9 "2019-08-06T00:31:11Z")

</div>

Could you share the config for including 32 bit testing?

---

<div class="post-metadata">

### Author: ![ararslan](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/ararslan/32/3825_2.png) [@ararslan](https://discourse.julialang.org/u/ararslan)
#### Post date: [August 6, 2019, 3:18am UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/10 "2019-08-06T03:18:20Z")

</div>

I assume @SaschaMann is referring to the standard setup for testing 32-bit Windows on AppVeyor, e.g. with [Appveyor.jl](https://github.com/JuliaCI/Appveyor.jl). You can also see how it’s set up with Travis in the link my the top post.

---

<div class="post-metadata">

### Author: ![chakravala](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/chakravala/32/6832_2.png) [@chakravala](https://discourse.julialang.org/u/chakravala)
#### Post date: [August 6, 2019, 1:34pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/11 "2019-08-06T13:34:36Z")

</div>

Does appveyor use 32 bit binaries on 64 bit also? Or does it launch an actual 32 bit distro?

---

<div class="post-metadata">

### Author: ![SaschaMann](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/saschamann/32/2852_2.png) [@SaschaMann](https://discourse.julialang.org/u/SaschaMann)
#### Post date: [August 6, 2019, 3:00pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/12 "2019-08-06T15:00:36Z")

</div>

I was referring to the Travis setup in the OP.

@Nosferican This is the full build matrix I’m using now, incl. 32bit Julia. Note that you may want to remove `arch: x86` from `allow_failures`, I have it in there because I’ll have to fix bugs I found through the 32bit testing first.

> **Travis Script**
>
> ```yaml
> os:
> - osx
> - linux
> 
> julia:
> - 1.0
> - 1.1
> - nightly
> 
> matrix:
> # fast_finish marks the build as passing even if allow_failures builds are still running
> fast_finish: true
> include:
> - os: windows
> arch: x64
> julia: 1.0
> - os: windows
> arch: x86
> julia: 1.0
> name: "Julia 1 (32bit)"
> - os: windows
> arch: x64
> julia: 1.1
> - os: windows
> arch: x86
> julia: 1.1
> name: "Julia 1.1 (32bit)"
> allow_failures:
> - julia: nightly
> - arch: x86
> 
> ```

---

<div class="post-metadata">

### Author: ![oschulz](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/oschulz/32/2998_2.png) [@oschulz](https://discourse.julialang.org/u/oschulz)
#### Post date: [August 6, 2019, 3:56pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/13 "2019-08-06T15:56:38Z")

</div>

> I think testing on 32 bit is really, really valuable, I tend to catch a lot of bugs that way.

Couldn’t agree more!

---

<div class="post-metadata">

### Author: ![Nosferican](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nosferican/32/9275_2.png) [@Nosferican](https://discourse.julialang.org/u/Nosferican)
#### Post date: [August 7, 2019, 3:02pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/14 "2019-08-07T15:02:11Z")

</div>

I had some issues with the script. I need to run the following matrix for the testing stage. However, for some reason the collection of jobs get interpreted as a single linux job. See config and log example [here](https://travis-ci.org/Nosferican/Econometrics.jl/builds/568484609/config).

---

<div class="post-metadata">

### Author: ![SaschaMann](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/saschamann/32/2852_2.png) [@SaschaMann](https://discourse.julialang.org/u/SaschaMann)
#### Post date: [August 7, 2019, 6:59pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/15 "2019-08-07T18:59:01Z")

</div>

Not sure what’s going on there, never used stages, sorry 🤷‍♂️

---

<div class="post-metadata">

### Author: ![Nosferican](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nosferican/32/9275_2.png) [@Nosferican](https://discourse.julialang.org/u/Nosferican)
#### Post date: [August 7, 2019, 8:31pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/16 "2019-08-07T20:31:22Z")

</div>

I tried without stages too and it gave me the same thing, [Travis CI - Test and Deploy Your Code with Confidence](https://travis-ci.org/Nosferican/Econometrics.jl/jobs/568478242/config)

---

<div class="post-metadata">

### Author: ![Nosferican](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/nosferican/32/9275_2.png) [@Nosferican](https://discourse.julialang.org/u/Nosferican)
#### Post date: [August 9, 2019, 8:38am UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/17 "2019-08-09T08:38:31Z")

</div>

@ararslan [Here](https://github.com/Nosferican/test-ci/pull/1/checks?check_run_id=188936109) is an example trying to include the Windows jobs, but only spawning the Linux one.

---

<div class="post-metadata">

### Author: ![mortenpi](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mortenpi/32/158_2.png) [@mortenpi](https://discourse.julialang.org/u/mortenpi)
#### Post date: [August 11, 2019, 1:51am UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/18 "2019-08-11T01:51:39Z")

</div>

Apparently, `matrix` and `jobs` [are simply aliases of each other](https://travis-ci.community/t/multi-os-build-matrix-not-working/4424/2?u=mortenpi). So to make the `matrix / include` thing work with additional build stages, you need to do something like:

```yaml
language: julia

os:
  - osx
  - linux

julia:
  - 1.0
  - 1.1
  - nightly

jobs:
  include:
    # additional Windows 32/64-bit jobs
    - os: windows
      arch: x64
      julia: 1.0
    - os: windows
      arch: x86
      julia: 1.0
      name: "Julia 1 (32bit)"
    - os: windows
      arch: x64
      julia: 1.1
    - os: windows
      arch: x86
      julia: 1.1
      name: "Julia 1.1 (32bit)"
    # documentation build stage
    - stage: "Documentation"
      os: linux
      julia: 1.3
      script:
        - julia --project=docs/ -e 'using Pkg; Pkg.develop(PackageSpec(path=pwd()));
                                               Pkg.instantiate()'
        - julia --project=docs/ docs/make.jl
      after_success: skip

```

You can see a successful expansion [here](https://travis-ci.com/mortenpi/test-ci/builds/122700806/config).

---

<div class="post-metadata">

### Author: ![juliohm](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/juliohm/32/215266_2.png) [@juliohm](https://discourse.julialang.org/u/juliohm)
#### Post date: [August 11, 2019, 1:04pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/19 "2019-08-11T13:04:16Z")

</div>

Anyone having similar issues with visual regression tests on Windows? [https://github.com/JuliaIO/ImageMagick.jl/issues/163](https://github.com/JuliaIO/ImageMagick.jl/issues/163)

Visual regression tests depend on ImageMagick.jl and the package doesn’t seem to build successfully on Windows. Appreciate any help.

---

<div class="post-metadata">

### Author: ![davidanthoff](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/davidanthoff/32/223493_2.png) [@davidanthoff](https://discourse.julialang.org/u/davidanthoff)
#### Post date: [August 12, 2019, 10:42pm UTC](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187/20 "2019-08-12T22:42:26Z")

</div>

Ah, nice! Another way to do this that seems a bit shorter it so use the standard `os` selection to add the 64 bit Windows build, and then just add additional jobs for 32 bit, like I’ve done [here](https://github.com/anthofflab/RobustAdaptiveMetropolisSampler.jl/blob/master/.travis.yml).

[Next page](https://discourse.julialang.org/t/julia-is-now-available-on-travis-windows-builds/27187.md?page=2)
