summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* _frontend/cli.py: Reinstate support for guessing targetsjuerg/source-guess-targetJürg Billeter2019-01-041-0/+10
| | | | | | Moving fetch and track to the source command group accidentally dropped the support for guessing targets for these commands when invoked from a workspace directory. This brings it back.
* Merge branch 'coldtom/collections' into 'master'Tristan Van Berkom2019-01-032-14/+14
|\ | | | | | | | | | | | | Use collections.abc for Mapping, Iterable Closes #831 See merge request BuildStream/buildstream!1020
| * Use collections.abc for Mapping, IterableThomas Coldrick2019-01-032-14/+14
|/ | | | | | | In _yaml.py and _frontend/complete.py we were getting pylint warnings for using collections.Mapping and collections.Iterable, which are abstract classes now provided from collections.abc. This patch just uses the classes from the right place.
* Merge branch 'tristan/toxic-linting' into 'master'Tristan Van Berkom2019-01-038-21/+43
|\ | | | | | | | | Run the linter separately from the tests See merge request BuildStream/buildstream!1033
| * tools/dev-requirements.{in,txt}: Removed requirements on pylint/codestyle ↵Tristan Van Berkom2019-01-032-6/+2
| | | | | | | | | | | | | | pytest plugins We no longer run the linters through pytest, so we don't need these plugins anymore.
| * tools/requirements.{in,txt}: Fix warning about duplicate jinjaTristan Van Berkom2019-01-032-2/+2
| | | | | | | | | | Apparently you need to spell Jinja2 with a capital J, otherwise we find it listed twice in the resulting requirements.txt files.
| * CONTRIBUTING.rst: Adding instructions to run the linter separatelytristan/toxic-lintingTristan Van Berkom2019-01-031-9/+12
| |
| * .gitlab-ci.yml: Update the CI to run the linter separately through toxTristan Van Berkom2019-01-031-0/+12
| | | | | | | | | | This should save us some cycles in CI, and also allow the developer to more conveniently lint separately from testing.
| * tox.ini: Added new 'lint' environment to lint separatelyTristan Van Berkom2019-01-031-0/+9
| |
| * setup.cfg: Don't lint by default through setup.py test invocationsTristan Van Berkom2019-01-031-1/+1
| |
| * setup.cfg: Specify the pycodestyle configurations separately from pytest ↵Tristan Van Berkom2019-01-031-3/+5
|/ | | | configuration
* Merge branch 'chandan/fix-bad-filename-mini-disaster' into 'master'Chandan Singh2019-01-033-5/+24
|\ | | | | | | | | | | | | tests/frontend/buildcheckout.py: Fix bad filename issue for Windows Closes #842 See merge request BuildStream/buildstream!1032
| * tests/frontend/buildcheckout.py: Fix bad filename issue for WindowsChandan Singh2019-01-033-5/+24
|/ | | | | | | | | | | | | | | | | | | | | In BuildStream/buildstream!1028, we added a test specifically to test that BuildStream correctly raises an warning when the name of an element contains characters that are invalid on Windows. Unfortunately, we didn't see it coming that it would make it impossible to checkout this branch on Windows. Fix it by generating this file, only if we are not running on Windows. * tests/testutils/site.py: Add `IS_WINDOWS` check * tests/frontend/buildcheckout.py: Generate file with invalid filename on the fly * Remove tests/frontend/project/elements/invalid-chars. Fixes #842. Note that this may still cause issues on WSL when running tests on a shared filesystem, but that seems to be a generic issue on WSL with `os.rename`.
* Merge branch 'chandan/toxify' into 'master'Tristan Van Berkom2019-01-0312-77/+211
|\ | | | | | | | | Use tox as a frontend for running tests See merge request BuildStream/buildstream!1027
| * CONTRIBUTING.rst: Add instructions to recreate tox environmentchandan/toxifyChandan Singh2019-01-031-0/+6
| | | | | | | | | | | | | | When we update our dependencies, developers will eventually need to recreate their `tox` environments to get correct results. This happens because `tox` isn't particularly good at recognizing changes in the requirements files.
| * Move sphinx build functionality to toxChandan Singh2019-01-033-31/+33
| | | | | | | | | | | | | | | | | | Currently the CI and the docs both have to duplicate the same inforation about how to gather dependencies etc, and have to use hacky ways to run them. Add a new `docs` environment to our tox setup so that building docs is as simple as running `tox -e docs`.
| * Move all requirements files into "tools" directoryChandan Singh2019-01-039-11/+11
| | | | | | | | | | | | These new `.in` and `.txt` are making the repository look very cluttered. Move them to a separate `tools` directory to make it look a bit cleaner.
| * CONTRIBUTING.rst: Add steps for installing non-python build dependenciesChandan Singh2019-01-031-5/+32
| | | | | | | | | | | | | | | | | | | | | | Since we don't allow use of site packages by default in our `tox` configuration, people will need to install non-python build dependencies of some of our dependencies that do not provide pre-built wheels. We have two such packages at the moment: * psuitl: requires python C headers, compiler * pygobject: requires python C headers, pkg-config, compiler, cairo headers, and gobject libraries
| * CONTRIBUTING.rst: Updated to reflect running tests using tox.Tristan Van Berkom2019-01-031-12/+40
| |
| * .gitlab-ci.yml: Run tests using toxChandan Singh2019-01-031-13/+10
| | | | | | | | | | Instead of invoking tests throung `setup.py`, use `tox` as a frontend in the CI pipelines.
| * Add tox.ini to enable running tests using toxChandan Singh2019-01-023-0/+15
| | | | | | | | | | | | | | | | Add `tox.ini` file that will enable us to use [tox](https://tox.readthedocs.io/) as a frontend for running tests. Since we share the config via `setup.cfg` and requirements via requirements files, commands like `python3 setup.py test` will continue to work.
| * Add requirements files for install, test and plugin dependenciesChandan Singh2019-01-028-29/+88
|/ | | | | | | | | | | | | | Add `.in` and `.txt` requirements files for BuildStream's pure python dependencies. For each pair, the `.in` file is supposed to capture the loose version requirements, and the corresponding `.txt` file is supposed to have frozen requirements. We have 3 such sets: * `requirements`: BuildStream's runtime dependencies * `dev-requirements`: Dependencies for running tests * `plugin-requirements`: Dependencies for core plugins Note that the frozen requirements files will only be used for testing purposes, and `setup.py` will continue to read loose requirements.
* Merge branch 'jjardon/pycodestyle' into 'master'Tristan Maat2019-01-027-27/+17
|\ | | | | | | | | Use pycodestyle instead pep8 python module See merge request BuildStream/buildstream!638
| * Use pycodestyle instead of pep8Javier Jardón2019-01-026-19/+9
| | | | | | | | | | | | | | | | pep8 package was renamed to pycodestyle to reduce confusion. Disabled warnings: W504 - Line break after binary operator (seems people like this) W605 - Invalid escape sequence (some of our regexes use these)
| * .gitlab-ci.yml: Use new testsuite images with pycodestyle 1.4.0Tristan Maat2019-01-021-8/+8
|/ | | | | | We need to bump the testsuite image versions to use the new pycodestyle update that allows excluding file paths, so that we can exclude generated python code.
* Merge branch 'chandan/update-doc-makefile-note' into 'master'Chandan Singh2019-01-021-4/+4
|\ | | | | | | | | doc/Makefile: Update comment about sphinx entrypoint See merge request BuildStream/buildstream!1026
| * doc/Makefile: Update comment about sphinx entrypointchandan/update-doc-makefile-noteChandan Singh2019-01-021-4/+4
|/ | | | | | https://github.com/sphinx-doc/sphinx/issues/4375 has been closed as `wontfix`. Update the comment in doc/Makefile that mentions it, based on the discussion on the issue.
* Merge branch 'chandan/element-filename-requirements' into 'master'Tristan Van Berkom2018-12-317-18/+127
|\ | | | | | | | | Add warnings about invalid characters in filename See merge request BuildStream/buildstream!1028
| * doc: Add note about valid element namesChandan Singh2018-12-311-0/+24
| |
| * tests/buildcheckout.py: Add tests for invalid chars in filenameChandan Singh2018-12-314-0/+27
| |
| * _loader/loader.py: Add warnings about invalid characters in filenameChandan Singh2018-12-312-0/+43
| | | | | | | | | | See https://mail.gnome.org/archives/buildstream-list/2018-December/msg00061.html for some related discussion.
| * _loader/loader.py: Refactor warnings about element names in one methodChandan Singh2018-12-311-18/+33
|/ | | | | | | Currently we some duplication in the way we check for invalid filenames. To make it more robust and allow room for adding more warnings, refactor it into a separate method `_warn_invalid_elements()` that handles just this.
* Merge branch 'tristan/junction-tests' into 'master'Tristan Van Berkom2018-12-312-40/+47
|\ | | | | | | | | Junction test addition See merge request BuildStream/buildstream!1029
| * tests/loader/junctions.py: Test the error we expect when a cross junction ↵Tristan Van Berkom2018-12-312-1/+23
| | | | | | | | element is not found
| * tests/loader/junctions.py: Use Result checking APIs instead of manuallyTristan Van Berkom2018-12-311-39/+24
|/ | | | Better to use the same API everywhere for thecking CLI results.
* Merge branch 'tristan/fix-netrc-crasher' into 'master'Tristan Van Berkom2018-12-263-3/+28
|\ | | | | | | | | Fix netrc crasher See merge request BuildStream/buildstream!1025
| * tests/sources/tar.py: Test that we don't crash when HOME is unsetTristan Van Berkom2018-12-261-0/+16
| | | | | | | | | | This happens when the netrc module is searching for a ~/.netrc file and it doesnt find any HOME set.
| * tests/testutils/runcli.py: Fixed broken environment handlingTristan Van Berkom2018-12-261-2/+5
| | | | | | | | | | Treat None values in the passed dictionary as keys to be removed from the environment, this was already happening at restoration time.
| * _downloadablefilesource.py: Avoid crashes when HOME is unsetTristan Van Berkom2018-12-261-1/+7
|/ | | | | | The python netrc module will raise OSError in the case that HOME is not set, this was discovered while running tests under tox.
* Merge branch 'tristan/test-fixes' into 'master'Tristan Van Berkom2018-12-2610-21/+11
|\ | | | | | | | | | | | | Misc fixes to the tests and newer linter errors Closes #636 See merge request BuildStream/buildstream!1011
| * dev-requirements.txt: Remove the restriction on pylint.tristan/test-fixesTristan Van Berkom2018-12-261-1/+1
| | | | | | | | | | | | After having fixed the more recent linting errors, the tests should pass with recent versions of pylint. Tested with pylint 2.2.2.
| * dev-requirements.txt: Require new version of pytest-datafilesTristan Van Berkom2018-12-261-1/+1
| | | | | | | | | | | | | | | | Since Thomas Nixon fixed the datafiles plugin to be compatible with pytest >= 3.8.0, we can now depend on it and avoid the warnings and errors which the older datafiles plugin causes. This fixes issue #636
| * buildstream/storage/_casbaseddirectory.py: Fixing new (unnecessary-pass) ↵Tristan Van Berkom2018-12-261-5/+0
| | | | | | | | linter errors
| * plugins/elements/import.py: Fixing new ↵Tristan Van Berkom2018-12-261-1/+1
| | | | | | | | (duplicate-string-formatting-argument) linter error
| * _frontend/widget.py: Fixing new (wrong-import-order) linter errorTristan Van Berkom2018-12-261-1/+1
| |
| * _frontend/complete.py: Fixing new (simplifiable-if-expression) linter errorTristan Van Berkom2018-12-261-1/+1
| |
| * _frontend/cli.py: Fixing new (unnecessary-pass) linter errorsTristan Van Berkom2018-12-261-3/+0
| |
| * _artifactcache/casserver.py: Fixed new (wrong-import-order) linter errorTristan Van Berkom2018-12-261-1/+1
| |
| * source.py: Fixing new (unnecessary-pass) linter errorTristan Van Berkom2018-12-261-1/+0
| |
| * element.py: Fixing new (unnecessary-pass) and (simplifiable-if-expression) ↵Tristan Van Berkom2018-12-261-3/+2
| | | | | | | | linter errors