Skip to content

Replace Travis-CI with GitHub Actions #448

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

Merged
merged 34 commits into from
Jan 31, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
5dedf61
Attempt setup of GitHub Actions to run tests with `tox`
althonos Jan 27, 2021
8c0b771
Install `tox-gh-actions` in GitHub Actions test workflow
althonos Jan 27, 2021
a2ebaae
Make sure to use a recent version of `pip` in GitHub Actions
althonos Jan 27, 2021
1c71b8e
Make CI jobs upload coverage statistics to Coveralls
althonos Jan 28, 2021
9e726ce
Make minimal `requirements.txt` files for the docs and the tests
althonos Jan 28, 2021
c824bdb
Refactor `tox.ini` to pack its own dependencies
althonos Jan 28, 2021
ad127ff
Rewrite tests to use `unittest.skipIf` instead of `pytest.mark.skipif…
althonos Jan 28, 2021
2c19154
Rewrite `tests.test_appfs` as a proper unittest module
althonos Jan 28, 2021
b2f40ec
Make `tests.test_ftpfs` use `pytest.mark.slow` only if available
althonos Jan 28, 2021
188d0a8
Rewrite `tests.test_opener` without using `pytest` fixtures
althonos Jan 28, 2021
1914a6e
Fix missing `mock` test requirement for Python 2.7
althonos Jan 28, 2021
aede860
Fix `tox` not correctly collecting coverage with `pytest-cov`
althonos Jan 28, 2021
07f4bc6
Require minimum `coverage` version of `5.0` to use the `relative_file…
althonos Jan 28, 2021
c239574
Add a linting stage to the GitHub Actions test workflow
althonos Jan 28, 2021
8783091
Add PyPy environments to `tox.ini` configuration
althonos Jan 28, 2021
eaae371
Reformat Python code with latest version of `black`
althonos Jan 28, 2021
5a27e2e
Fix type-related issues in `ftpfs.FTPFile` and add support for `array…
althonos Jan 28, 2021
221b9e5
Rewrite buffering in `FTPFile.writelines` to work with more argument …
althonos Jan 28, 2021
ec8300b
Fix typing of some methods in `fs.iotools` and `fs.memoryfs` file APIs
althonos Jan 28, 2021
70ee97a
Relax Python version but pin dependencies in `tox` linter environments
althonos Jan 28, 2021
a433d9e
Fix `flake8` warnings in `fs` and `tests` modules
althonos Jan 28, 2021
afdcf8c
Fix documentation-related errors found by `pydocstyle`
althonos Jan 28, 2021
91a57da
Refactor `fs.appfs` to avoid copying `__init__` documentation
althonos Jan 28, 2021
63a4cd1
Move `OSFS` initialization parameters to the `OSFS.__init__` docstring
althonos Jan 28, 2021
b19862b
Fix rendering of examples in `MemoryFS` docstring
althonos Jan 28, 2021
66d49a8
Rename linter environments in `tox.ini` to be tool-agnostic
althonos Jan 28, 2021
5d8009c
Fix remaining linter issues in `fs` modules
althonos Jan 28, 2021
79fe038
Mark BZ2 and XZ tests as slow in `tests.test_tarfs`
althonos Jan 28, 2021
9ab0bd5
Make upload /download tests in `FSTestCases` faster by only building …
althonos Jan 28, 2021
2b1cab4
Run PyPy tests in Actions CI but skip some `tests.test_ftpfs` test cases
althonos Jan 28, 2021
996d202
Update all badges on `README.md` to use `shields.io` [ci skip]
althonos Jan 28, 2021
2673eed
Move `tox` configuration into `setup.cfg` to reduce project repo clut…
althonos Jan 28, 2021
e957139
Remove Travis-CI configuration files
althonos Jan 28, 2021
3624d47
Update `CHANGELOG.md` with GitHub Actions PR and update older entries
althonos Jan 28, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 72 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,72 @@
name: Test

on:
- push
- pull_request

jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
python-version:
- 2.7
- 3.5
- 3.6
- 3.7
- 3.8
- 3.9
- pypy-2.7
- pypy-3.6
- pypy-3.7
steps:
- name: Checkout code
uses: actions/checkout@v1
- name: Setup Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Update pip
run: python -m pip install -U pip wheel setuptools
- name: Install tox
run: python -m pip install tox tox-gh-actions
- name: Test with tox
run: python -m tox
- name: Collect coverage results
uses: AndreMiras/coveralls-python-action@develop
with:
parallel: true
flag-name: test (${{ matrix.python-version}})

coveralls:
needs: test
runs-on: ubuntu-latest
steps:
- name: Upload coverage statistics to Coveralls
uses: AndreMiras/coveralls-python-action@develop
with:
parallel-finished: true

lint:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
linter:
- typecheck
- codestyle
- docstyle
- codeformat
steps:
- name: Checkout code
uses: actions/checkout@v1
- name: Setup Python 3.9
uses: actions/setup-python@v2
with:
python-version: 3.9
- name: Update pip
run: python -m pip install -U pip wheel setuptools
- name: Install tox
run: python -m pip install tox tox-gh-actions
- name: Run ${{ matrix.linter }} linter
run: python -m tox -e ${{ matrix.linter }}
57 changes: 0 additions & 57 deletions .travis.yml

This file was deleted.

42 changes: 31 additions & 11 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,22 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
## Unreleased

### Changed
- Make `FS.upload` explicit about the expected error when the parent directory of the destination does not exist
[#445](https://github.com/PyFilesystem/pyfilesystem2/pull/445).

- Make `FS.upload` explicit about the expected error when the parent directory of the destination does not exist.
Closes [#445](https://github.com/PyFilesystem/pyfilesystem2/pull/445).
- Migrate continuous integration from Travis-CI to GitHub Actions and introduce several linters
again in the build steps ([#448](https://github.com/PyFilesystem/pyfilesystem2/pull/448)).
Closes [#446](https://github.com/PyFilesystem/pyfilesystem2/pull/446).
- Stop requiring `pytest` to run tests, allowing any test runner supporting `unittest`-style
test suites.
- `FSTestCases` now builds the large data required for `upload` and `download` tests only
once in order to reduce the total testing time.

### Fixed

- Make `FTPFile`, `MemoryFile` and `RawWrapper` accept [`array.array`](https://docs.python.org/3/library/array.html)
arguments for the `write` and `writelines` methods, as expected by their base class [`io.RawIOBase`](https://docs.python.org/3/library/io.html#io.RawIOBase).
- Various documentation issues, including `MemoryFS` docstring not rendering properly.


## [2.4.12] - 2021-01-14
Expand All @@ -22,6 +36,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
[#380](https://github.com/PyFilesystem/pyfilesystem2/issues/380).
- Added compatibility if a Windows FTP server returns file information to the
`LIST` command with 24-hour times. Closes [#438](https://github.com/PyFilesystem/pyfilesystem2/issues/438).
- Added Python 3.9 support. Closes [#443](https://github.com/PyFilesystem/pyfilesystem2/issues/443).

### Changed

Expand All @@ -30,25 +45,30 @@ and this project adheres to [Semantic Versioning](http://semver.org/).
be able to see if we break something aside from known issues with FTP tests.
- Include docs in source distributions as well as the whole tests folder,
ensuring `conftest.py` is present, fixes [#364](https://github.com/PyFilesystem/pyfilesystem2/issues/364).
- Stop patching copy with Python 3.8+ because it already uses `sendfile`.
- Stop patching copy with Python 3.8+ because it already uses `sendfile`
([#424](https://github.com/PyFilesystem/pyfilesystem2/pull/424)).
Closes [#421](https://github.com/PyFilesystem/pyfilesystem2/issues/421).

### Fixed

- Fixed crash when CPython's -OO flag is used
- Fixed error when parsing timestamps from a FTP directory served from a WindowsNT FTP Server, fixes [#395](https://github.com/PyFilesystem/pyfilesystem2/issues/395).
- Fixed error when parsing timestamps from a FTP directory served from a WindowsNT FTP Server.
Closes [#395](https://github.com/PyFilesystem/pyfilesystem2/issues/395).
- Fixed documentation of `Mode.to_platform_bin`. Closes [#382](https://github.com/PyFilesystem/pyfilesystem2/issues/382).
- Fixed the code example in the "Testing Filesystems" section of the
"Implementing Filesystems" guide. Closes [#407](https://github.com/PyFilesystem/pyfilesystem2/issues/407).
- Fixed `FTPFS.openbin` not implicitly opening files in binary mode like expected
from `openbin`. Closes [#406](https://github.com/PyFilesystem/pyfilesystem2/issues/406).


## [2.4.11] - 2019-09-07

### Added

- Added geturl for TarFS and ZipFS for 'fs' purpose. NoURL for 'download' purpose.
- Added helpful root path in CreateFailed exception [#340](https://github.com/PyFilesystem/pyfilesystem2/issues/340)
- Added Python 3.8 support
- Added helpful root path in CreateFailed exception.
Closes [#340](https://github.com/PyFilesystem/pyfilesystem2/issues/340).
- Added Python 3.8 support.

### Fixed

Expand Down Expand Up @@ -76,7 +96,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/).

### Fixed

- Fixed broken WrapFS.movedir [#322](https://github.com/PyFilesystem/pyfilesystem2/issues/322)
- Fixed broken WrapFS.movedir [#322](https://github.com/PyFilesystem/pyfilesystem2/issues/322).

## [2.4.9] - 2019-07-28

Expand Down Expand Up @@ -458,7 +478,7 @@ No changes, pushed wrong branch to PyPi.

### Added

- New `copy_if_newer' functionality in`copy` module.
- New `copy_if_newer` functionality in `copy` module.

### Fixed

Expand All @@ -469,17 +489,17 @@ No changes, pushed wrong branch to PyPi.
### Changed

- Improved FTP support for non-compliant servers
- Fix for ZipFS implied directories
- Fix for `ZipFS` implied directories

## [2.0.1] - 2017-03-11

### Added

- TarFS contributed by Martin Larralde
- `TarFS` contributed by Martin Larralde.

### Fixed

- FTPFS bugs.
- `FTPFS` bugs.

## [2.0.0] - 2016-12-07

Expand Down
15 changes: 7 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,14 @@

Python's Filesystem abstraction layer.

[![PyPI version](https://badge.fury.io/py/fs.svg)](https://badge.fury.io/py/fs)
[![PyPI version](https://img.shields.io/pypi/v/fs)](https://pypi.org/project/fs/)
[![PyPI](https://img.shields.io/pypi/pyversions/fs.svg)](https://pypi.org/project/fs/)
[![Downloads](https://pepy.tech/badge/fs/month)](https://pepy.tech/project/fs/month)


[![Build Status](https://travis-ci.org/PyFilesystem/pyfilesystem2.svg?branch=master)](https://travis-ci.org/PyFilesystem/pyfilesystem2)
[![Windows Build Status](https://ci.appveyor.com/api/projects/status/github/pyfilesystem/pyfilesystem2?branch=master&svg=true)](https://ci.appveyor.com/project/willmcgugan/pyfilesystem2)
[![Coverage Status](https://coveralls.io/repos/github/PyFilesystem/pyfilesystem2/badge.svg)](https://coveralls.io/github/PyFilesystem/pyfilesystem2)
[![Codacy Badge](https://api.codacy.com/project/badge/Grade/30ad6445427349218425d93886ade9ee)](https://www.codacy.com/app/will-mcgugan/pyfilesystem2?utm_source=github.com&utm_medium=referral&utm_content=PyFilesystem/pyfilesystem2&utm_campaign=Badge_Grade)
[![Downloads](https://pepy.tech/badge/fs/month)](https://pepy.tech/project/fs/)
[![Build Status](https://img.shields.io/github/workflow/status/PyFilesystem/pyfilesystem2/Test/master?logo=github&cacheSeconds=600)](https://github.com/PyFilesystem/pyfilesystem2/actions?query=branch%3Amaster)
[![Windows Build Status](https://img.shields.io/appveyor/build/willmcgugan/pyfilesystem2/master?logo=appveyor&cacheSeconds=600)](https://ci.appveyor.com/project/willmcgugan/pyfilesystem2)
[![Coverage Status](https://img.shields.io/coveralls/github/PyFilesystem/pyfilesystem2/master?cacheSeconds=600)](https://coveralls.io/github/PyFilesystem/pyfilesystem2)
[![Codacy Badge](https://img.shields.io/codacy/grade/30ad6445427349218425d93886ade9ee/master?logo=codacy)](https://www.codacy.com/app/will-mcgugan/pyfilesystem2?utm_source=github.com&utm_medium=referral&utm_content=PyFilesystem/pyfilesystem2&utm_campaign=Badge_Grade)
[![Docs](https://img.shields.io/readthedocs/pyfilesystem2?maxAge=3600)](http://pyfilesystem2.readthedocs.io/en/stable/?badge=stable)

## Documentation

Expand Down
3 changes: 3 additions & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
# the bare requirements for building docs
Sphinx ~=3.0
sphinx-rtd-theme ~=0.5.1
11 changes: 11 additions & 0 deletions docs/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -304,3 +304,14 @@
#texinfo_no_detailmenu = False

napoleon_include_special_with_doc = True


# -- Options for autodoc -----------------------------------------------------

# Configure autodoc so that it doesn't skip building the documentation for
# __init__ methods, since the arguments to instantiate classes should be in
# the __init__ docstring and not at the class-level.

autodoc_default_options = {
'special-members': '__init__',
}
Loading