gonumをインストールした時にエラーが出た話

### 何をしようとしたか
Goの数値計算パッケージgonumをローカル環境にインストールした後、テストを実行したらエラー発生

### 何をしたか
Goのバージョン変更

## 環境
Ubuntu: 18.04.4 LTS
Go: 1.10.4

## 起因
gonumをインストール後、公式gonumのイントロ*1)に従ってテストを実行します。

```
go test gonum.org/v1/...
// 以下, 出力結果
...
FAIL gonum.org/v1/gonum/floats [build failed]
FAIL gonum.org/v1/gonum/graph [build failed]
FAIL gonum.org/v1/gonum/graph/community [build failed]
? gonum.org/v1/gonum/graph/encoding [no test files]
FAIL gonum.org/v1/gonum/graph/encoding/digraph6 [build failed]
FAIL gonum.org/v1/gonum/graph/encoding/dot [build failed]
FAIL gonum.org/v1/gonum/graph/encoding/graph6 [build failed]
FAIL gonum.org/v1/gonum/graph/encoding/graphql [build failed]
FAIL gonum.org/v1/gonum/graph/flow [build failed]
...
? gonum.org/v1/gonum/graph/formats/dot/internal/token [no test files]
? gonum.org/v1/gonum/graph/formats/dot/internal/util [no test files]
ok gonum.org/v1/gonum/graph/formats/gexf12 (cached)
ok gonum.org/v1/gonum/graph/formats/sigmajs (cached)
FAIL gonum.org/v1/gonum/graph/graphs/gen [build failed]
? gonum.org/v1/gonum/graph/internal/linear [no test files]
? gonum.org/v1/gonum/graph/internal/ordered [no test files]
ok gonum.org/v1/gonum/graph/internal/set (cached)
? gonum.org/v1/gonum/graph/internal/uid [no test files]
FAIL gonum.org/v1/gonum/graph/iterator [build failed]
FAIL gonum.org/v1/gonum/graph/multi [build failed]
FAIL gonum.org/v1/gonum/graph/network [build failed]
FAIL gonum.org/v1/gonum/graph/path [build failed]
FAIL gonum.org/v1/gonum/graph/path/dynamic [build failed]
FAIL gonum.org/v1/gonum/graph/path/internal/testgraphs [build failed]
FAIL gonum.org/v1/gonum/graph/product [build failed]
FAIL gonum.org/v1/gonum/graph/simple [build failed]
FAIL gonum.org/v1/gonum/graph/spectral [build failed]
FAIL gonum.org/v1/gonum/graph/testgraph [build failed]
FAIL gonum.org/v1/gonum/graph/topo [build failed]
FAIL gonum.org/v1/gonum/graph/traverse [build failed]
FAIL gonum.org/v1/gonum/integrate [build failed]
FAIL gonum.org/v1/gonum/integrate/quad [build failed]
? gonum.org/v1/gonum/integrate/testquad [no test files]
...

```
**FAIL**が多い。公式gonumの引用から、
> 
This will take a few minutes. Packages should all have an “ok” or “?” next to them. While the tests are running, please feel free to browse the source code!

テスト結果は**OK**か**?**になるはずなので、原因調査。

## 原因
gonumのgitで以下のgoのバージョンに関する記載を発見しました。

``` travis.yml
# Do not move these lines; they are referred to by README.md. |
:--|
| # Versions of go that are explicitly supported by Gonum, plus Go tip. |
 go: |
  - 1.14.x |
  - 1.13.x |
  - master |
 ... (以下省略)
```

ローカル環境を確認。Goのバージョンが1.10.4なので、1.13以上に変更する必要がある。

```
go version go1.10.4 linux/amd64
```

## 改善
ということで、goenvを用いてGoのバージョンを1.14に変更します。

```
$ goenv versions
  system
* 1.14.2 (set by /home/'username'/.goenv/version)
```

goenvの関しては以下の記事があります。
- goenvでgoをインストール 〜初心者向け〜
https://qiita.com/yut-kt/items/9f5ac1e788df61f64290
- goenvでGoのバージョン管理
https://qiita.com/fujitahiroshi/items/fe2631bc5816b5cf5251

## 結果
再び、テストを実行します。

```
go test gonum.org/v1/...
// 以下, 出力結果
...
ok gonum.org/v1/gonum/graph/formats/cytoscapejs 0.582s
? gonum.org/v1/gonum/graph/formats/dot [no test files]
ok gonum.org/v1/gonum/graph/formats/dot/ast 0.036s
ok gonum.org/v1/gonum/graph/formats/dot/internal/astx 0.036s
? gonum.org/v1/gonum/graph/formats/dot/internal/errors [no test files]
ok gonum.org/v1/gonum/graph/formats/dot/internal/lexer 0.115s
ok gonum.org/v1/gonum/graph/formats/dot/internal/parser 0.108s
? gonum.org/v1/gonum/graph/formats/dot/internal/token [no test files]
? gonum.org/v1/gonum/graph/formats/dot/internal/util [no test files]
ok gonum.org/v1/gonum/graph/formats/gexf12 0.016s
ok gonum.org/v1/gonum/graph/formats/sigmajs 0.299s
ok gonum.org/v1/gonum/graph/graphs/gen 14.996s
? gonum.org/v1/gonum/graph/internal/linear [no test files]
? gonum.org/v1/gonum/graph/internal/ordered [no test files]
ok gonum.org/v1/gonum/graph/internal/set 0.015s
? gonum.org/v1/gonum/graph/internal/uid [no test files]
ok gonum.org/v1/gonum/graph/iterator 0.037s
ok gonum.org/v1/gonum/graph/multi 0.464s
ok gonum.org/v1/gonum/graph/network 0.012s
ok gonum.org/v1/gonum/graph/path 22.051s
ok gonum.org/v1/gonum/graph/path/dynamic 0.110s
ok gonum.org/v1/gonum/graph/path/internal/testgraphs 0.019s
ok gonum.org/v1/gonum/graph/product 7.998s
ok gonum.org/v1/gonum/graph/simple 0.304s
ok gonum.org/v1/gonum/graph/spectral 0.008s
ok gonum.org/v1/gonum/graph/testgraph 0.027s
ok gonum.org/v1/gonum/graph/topo 0.938s
ok gonum.org/v1/gonum/graph/traverse 0.537s
ok gonum.org/v1/gonum/integrate 0.131s
ok gonum.org/v1/gonum/integrate/quad 0.161s
? gonum.org/v1/gonum/integrate/testquad [no test files]
ok gonum.org/v1/gonum/internal/asm/c128 0.046s
ok gonum.org/v1/gonum/internal/asm/c64 0.054s
ok gonum.org/v1/gonum/internal/asm/f32 0.064s
ok gonum.org/v1/gonum/internal/asm/f64 0.110s
ok gonum.org/v1/gonum/internal/cmplx64 0.045s
ok gonum.org/v1/gonum/internal/math32 0.031s
ok gonum.org/v1/gonum/internal/testrand 0.004s
? gonum.org/v1/gonum/lapack [no test files]
ok gonum.org/v1/gonum/lapack/gonum 39.052s
? gonum.org/v1/gonum/lapack/lapack64 [no test files]
ok gonum.org/v1/gonum/lapack/testlapack 0.040s
ok gonum.org/v1/gonum/mat 30.443s
ok gonum.org/v1/gonum/mathext 10.512s
ok gonum.org/v1/gonum/mathext/internal/amos 19.968s
? gonum.org/v1/gonum/mathext/internal/cephes [no test files]
? gonum.org/v1/gonum/mathext/internal/gonum [no test files]
ok gonum.org/v1/gonum/mathext/prng 0.034s
...
```
公式の記載通り、**OK**か**?**だけになったので成功です。


## 参考文献
1) [公式] GONUM
https://www.gonum.org/post/introtogonum/
2) git gonum/.travis.yml
https://github.com/gonum/gonum/blob/master/.travis.yml#L6-L10
3) goenvでgoをインストール 〜初心者向け〜
https://qiita.com/yut-kt/items/9f5ac1e788df61f64290
4) goenvでGoのバージョン管理
https://qiita.com/fujitahiroshi/items/fe2631bc5816b5cf5251