-
Notifications
You must be signed in to change notification settings - Fork 1
Run Continuous Integration tests on Github Actions #88
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
5a9c874
to
5794fe0
Compare
1ef85a1
to
57772da
Compare
The GitHub Actions look promising. It seems the macOS agent doesn't correctly cache the |
Yeah, it's meant to consolidate all our Linux/macOS/Windows unit tests into one file using a matrix build specification (instead of having .travis.yml and .azure-pipelines.yml). Was going to put gmt-master into it somehow too at some point. It's been a lot of trial and error at this point getting it to work but should be getting there!
Good spotting, I'll try that. Not sure if it's because the Linux build runs faster than macOS and 'caches' things first. |
0fa0644
to
a2083c3
Compare
.github/workflows/ci_tests.yaml
Outdated
uses: actions/cache@v2 | ||
id: cache | ||
with: | ||
path: $(HOME)/.gmt |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
GitHub Actions may not support $(HOME)
. Try ~/.gmt
instead. See the pip cache example
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ok, won't hurt to try.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now macOS has the correct cache (~6MB), but Linux fails to extract the cache tarballs.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah. Not sure why the Windows run is saying it can't find the cache.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll try using ${{ github.workspace }}/.gmt
instead.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Still no luck. I noticed that Linux and Windows agents actually can download some files but timeout for others. For example:
Run gmt which -Gu @earth_relief_10m @earth_relief_60m @ridge.txt @Table_5_11.txt @tut_bathy.nc @tut_quakes.ngdc @tut_ship.xyz
earth_relief_10m: Download file from the GMT data server [data set size is 2.8M].
earth_relief_10m: Earth Relief at 10x10 arc minutes obtained by Gaussian Cartesian filtering (18 km fullwidth) of SRTM15+V2 [Tozer et al., 2019].
gmtwhich [ERROR]: Libcurl Error: Timeout was reached
gmtwhich [ERROR]: You can turn remote file download off by setting GMT_DATA_SERVER_LIMIT = 0.
gmtwhich [ERROR]: File earth_relief_10m.grd not found!
earth_relief_60m: Download file from the GMT data server [data set size is 106K].
earth_relief_60m: Earth Relief at 60x60 arc minutes obtained by Gaussian Cartesian filtering (111 km fullwidth) of SRTM15+V2 [Tozer et al., 2019].
C:/Users/runneradmin/.gmt/server/earth_relief_60m.grd
C:/Users/runneradmin/.gmt/cache/ridge.txt
C:/Users/runneradmin/.gmt/cache/Table_5_11.txt
C:/Users/runneradmin/.gmt/cache/tut_bathy.nc
C:/Users/runneradmin/.gmt/cache/tut_quakes.ngdc
C:/Users/runneradmin/.gmt/cache/tut_ship.xyz
I think a workaround would be running the "gmt which" command multiple times until all files are downloaded.
Signed-off-by: Wei Ji <[email protected]>
Signed-off-by: Wei Ji <[email protected]>
Signed-off-by: Wei Ji <[email protected]>
Signed-off-by: Wei Ji <[email protected]>
Signed-off-by: Wei Ji <[email protected]>
Try just caching ~/.gmt/cache and ~/.gmt/server.
Co-authored-by: Dongdong Tian <[email protected]>
DeepCode failed to analyze this pull requestSomething went wrong despite trying multiple times, sorry about that. |
|
||
jobs: | ||
test: | ||
name: ${{ matrix.os }} - Python ${{ matrix.python_version }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Another typo:
name: ${{ matrix.os }} - Python ${{ matrix.python_version }} | |
name: ${{ matrix.os }} - Python ${{ matrix.python-version }} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see you've been working on it on a branch in upstream pygmt
. Should I move this Pull Request there so we can both work on it?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, that would be better.
Closing in favour of upstream PR at GenericMappingTools#475. |
Description of proposed changes
Newer attempt of #35.
Fixes #
Reminders
make format
andmake check
to make sure the code follows the style guide.doc/api/index.rst
.