Commit Graph

261 Commits

Author SHA1 Message Date
Frost Ming 8a215dd198 remove typing imports 2020-08-27 21:30:14 +08:00
Frost Ming 45d9332cc0 Update dependency tomlkit 2020-08-27 20:35:25 +08:00
frostming f58a97329e update vendors 2020-08-12 15:24:07 +08:00
frostming 034bd6a4fe Update requirementslib to 1.5.12 2020-07-10 16:06:14 +08:00
frostming 564ed68718 Update pythonfinder from 1.2.2 to 1.2.4 2020-06-01 21:47:06 +08:00
frostming c5d2129e2b Update requirementslib 2020-06-01 19:21:16 +08:00
Dan Ryan ed30845837 Update gitignore and release task
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-28 00:03:57 -04:00
Dan Ryan 45675144bd Merge branch 'master' into import-vendored-attrs 2020-05-27 19:57:37 -04:00
Dan Ryan df664f2784 Add patch to update attrs import paths and add news entry.
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-27 19:57:02 -04:00
Dan Ryan 3acad96afd Fix piptools patch typo
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-27 19:49:56 -04:00
Dan Ryan 8cc00622cc Update makefile to build docs
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-20 15:58:49 -04:00
Dan Ryan 12e46a0bfb Fix release file
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-20 15:24:13 -04:00
Dan Ryan 3549d28702 Update release script
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-20 15:12:12 -04:00
Dan Ryan ed780c4061 Tweak crayons patch with vendored imports
- Remove now-unused `allow_global` argument to pip install
  argument builder
- Update vistir version number and code to fix vendoring issue

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-20 01:47:48 -04:00
Dan Ryan 4c10c35b57 Update vistir patch
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-19 19:48:37 -04:00
Dan Ryan 47aa2acc90 Set build_isolation and use_pep517 correctly
- Fix how `use_pep517` and `build_isolation` are read from the
  environment -- introduce a new environment helper to detect
  `<PREFIX>_<SETTING>` and `<PREFIX>_NO_<SETTING>`, check for booleans
  and return appropriately boolean, str, or None types
- Check for `False` values when adding `--no-use-pep517` and
  `--no-build-isolation` during resolution rather than falsey values
- Change environment variable name from `PIP_PYTHON_VERSION` to
  `PIPENV_REQUESTED_PYTHON_VERSION` to avoid causing `pip` to fail due
  to accidentally percieving the `python_version` flag as being set --
  this is an artifact from attempting to resolve outside of the
  virtualenv
- Add `pipenv` to the path of patched `notpip.__main__` to accommodate
  updated import fully qualified module names
- Update `pip` and `piptools` patches
- Add test packages for each of two known failure modes: outdated
  `setuptools` with a missing `build-backend` (which `pip` forces to
  `build_meta:__legacy__` & which doesn't exist before `40.8`), and
  `import Cython` statements in `setup.py` in packages with properly
  defined `pyproject.toml` `build-backend` lines.
- Fixes #4231
- Replaces, includes, and closes #4242

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>

Add integration tests for #4231

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-08 21:43:32 -04:00
Dan Ryan 7059a26fbd Float wheels to the top of the candidate sort order
- `ignore_compatibility` is meant to resolve hashes into the lockfile
  after resolution happens
- We still want compatible items to be the ones we actually tell pip to
  install
- Fixes #4231

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-08 09:59:09 -04:00
Dan Ryan c30155ff45 Fix recursive PEP 508 VCS resolution
- Recursively resolve PEP 508 URLs in subdependencies
  - Fix `piptools` cache storage of VCS dependencies as results
- Avoid saving VCS dependency versions to `Pipfile.lock`
- Fixes #3396
- Fixes #4217

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-05-05 23:44:34 -04:00
Dan Ryan 881d0e9923 Update release task
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-29 00:02:06 -04:00
Dan Ryan 76576761c6 Allow incompatible links during hash lookup
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-28 11:47:00 -04:00
Dan Ryan 580056f8ee Update license download script to accurately name licenses
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-27 17:04:15 -04:00
Dan Ryan ca1da4b295 Fix broken pip patch
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-27 16:59:53 -04:00
Dan Ryan d8f0100c08 Update patches for pip and piptools
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-27 15:28:30 -04:00
Dan Ryan d8be535006 Update patch for pep425tags to include os import
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-26 15:55:20 -04:00
Dan Ryan 483161fea1 Only build with one python version
Signed-off-by: Dan Ryan <dan@danryan.co>
2020-04-24 18:13:02 -04:00
Dan Ryan 60818d7b31 Automate release workflow
- Automatically release when tags are pushed to master
- Release automation will build wheel and sdist + upload to pypi
- Added test pypi as initial target
- Updated version update scripts to help with automatic version
  management

Signed-off-by: Dan Ryan <dan@danryan.co>
2020-04-24 18:01:13 -04:00
Dan Ryan cf8fa39b88 Update build script in tasks
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-23 22:13:47 -04:00
Dan Ryan 79bcbbab53 Fix safety zipfile generation
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-22 13:59:20 -04:00
Dan Ryan 1bc1bd75ac Add pipenv vendor dirs to safety runtime paths
- Fix configparser import and add patch in dparse
- Update patch on safety to add paths

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-20 18:26:31 -04:00
Dan Ryan 8e0d01998c Vendor safety outside of zipfile
- Vendor `pyyaml == 5.3.1`
- Vendor `dparse == 0.5.0`
- Vendor `safety == 1.8.7`
- Remove built `pyyaml` extensions and move `lib` directory to
  `vendor/yaml2` and `lib3` to `vendor/yaml3`
- Patch `safety` to use modified `pyyaml` paths
- Update outdated dependencies:
  - `urllib3 1.25.8 => 1.25.9`
  - `certifi 2019.11.28 => 2020.4.5.1`
  - `pyparsing 2.4.6 => 2.4.7`
  - `resolvelib 0.2.2 => 0.3.0`

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-20 17:23:57 -04:00
Dan Ryan e19129e5df Fix safety script and re-vendor safety
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-17 19:57:46 -04:00
Dan Ryan b93c49a54a Don't set default CA cert bundle
- Requests doesn't unpack zipped certs when they are set directly
- Zipped bundles are unpacked when they are discovered
- So we can just include certifi and put it on `sys.path`

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-17 01:47:50 -04:00
Dan Ryan b4b5691577 Fix failing pyup API key
- Update vendored safety package
- Swap to blank pyup API key by default (but allow custom key)
- Slightly improve safety revendoring
- Fixes #4188

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-16 21:23:37 -04:00
Dan Ryan 4bbcefb675 Update marker resolution
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:15:59 -04:00
Dan Ryan e03878d7c7 Add news entry and fix lockfile
- Drop pytest-tap
- Update azure pipelines config
- Borrow ramdisk configuration from pip
- Fix pyinstaller ref for python 2
- Add 0-minute timeout and add github workflow
- Add skip for pywin32
- Scale down to `-n auto` to reduce race conditions on windows
- Skip pywin32 on python 3.8 as the relevant dependencies aren't
  compatible
- Use default pip exists action = ignore to work around VCS race
  condition
- Create local temp directory to avoid crossing drive letter boundary on
  azure during CI runs
- Monkeypatch click windows console detection to return False in CI

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:06 -04:00
Dan Ryan ed8ae212c7 Fix tomlkit functools32 import
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:05 -04:00
Dan Ryan 7923151d2b Update vendoring script
- Pull licenses from .DIST-INFO files if available before cleaining up
  wheel metadata

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:04 -04:00
Dan Ryan bff39c5720 Update piptools patches
- Fix hash retrieval and reverse dependency traversal for wheel urls

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:03 -04:00
Dan Ryan 01157a21d7 Fix tomlkit patch and update library
Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:03 -04:00
Dan Ryan 662e7c77c9 Update tomlkit patch
- Update tomlkit patch
- Update test artifacts

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:02 -04:00
Dan Ryan e7fc6e9425 Re-vendor dependencies
- Update tomlkit => 0.5.11

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:02 -04:00
Dan Ryan 14566756a0 Fix outline table conversion for new tomlkit release
- Fix conversion of outline tables with new tomlkit release
- Fix pip and pip-shims patches

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:01 -04:00
Dan Ryan e629c0ce02 Update vendor.txt and ecosystem libraries
- Update `pip_shims`, `pythonfinder`, `requirementslib`, `vistir`
- Add patches to update or fix import paths where necessary
- Hardcode funcsigs license

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:01 -04:00
Dan Ryan b5892c1d03 Add missing dependencies, fix patched pip path
- Add missing dependencies:
  - `zipp==0.6.0`
  - `more-itertools==5.0.0`
  - `importlib-metadata==1.3.0`
  - `funcsigs==1.0.2`
  - `contextlib2==0.6.0.post1`
- Fix patched pip import paths for CLI and resolver
- Update patches

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:00 -04:00
Dan Ryan d9cddcb890 Updated and re-patched vendored dependencies
- **click-completion**: ``0.5.1 => 0.5.2``
- **python-dotenv**: ``0.10.2 => 0.10.3``
- **jinja2**: ``2.10. => 2.10.3``
- **parse**: ``1.12.0 => 1.13.0``
- **pathlib2**: ``2.3.3 => 2.3.5``
- **pipreqs**: ``0.4.9 => 0.4.10``
- **urllib3**: ``1.25.2 => 1.25.7``
- **certifi**: ``2019.3.9 => 2019.11.28``
- **requirementslib**: ``1.5.1 => 1.5.4``
- **attrs**: ``19.1.0 => 19.3.0``
- **distlib**: ``0.2.9 => 0.3.0``
- **packaging**: ``19.0 => 19.2``
- **pyparsing**: ``2.3.1 => 2.4.5``
- **tomlkit**: ``0.5.3 => 0.5.8``
- **six**: ``1.12.0 => 1.13.0``
- **semver**: ``2.8.1 => 2.9.0``
- **vistir**: ``0.4.2 => 0.4.3``
- **pip-shims**: ``0.3.2 => 0.4.0``
- **yaspin**: ``0.14.3 => 0.15.0``
- **cerberus**: ``1.3.1 => 1.3.2``
- **pep517**: ``0.5.0 => 0.8.1``
- **orderedmultidict**: ``1.0 => 1.0.1``
- **pip**: ``19.0.3 => 19.3.1``
- **pip-tools**: ``3.5.0 => 4.3.0``

Signed-off-by: Dan Ryan <dan.ryan@canonical.com>
2020-04-10 12:14:00 -04:00
frostming 7d36f3fbda Reformat codes 2019-09-06 18:06:05 +08:00
frostming 089bb57d7e Update vendor packages 2019-07-17 12:21:11 +08:00
Frost Ming 5e69bca451 Use autogenerated contributing.md 2019-07-14 16:45:19 +08:00
Frost Ming 2f619df5f9 Merge branch master 2019-07-14 15:36:41 +08:00
Dan Ryan 83868c8f1a Cut over to devpi for tests and improve logging
- Verbose logs will now write gracefully to the terminal even while the
  spinner is running (i.e. during locking)
- This PR also cuts over to Devpi for a backing cache rather than a
  hacked httpbin instance
- Inclues a refactor of `pip_install` to deduplicate logic
- Attempts to switch back to relying on native editable installs in pip
  as the current implementation is broken on master (i.e. nothing is
  installed in the virtualenv)
- Fixes #3809

Signed-off-by: Dan Ryan <dan@danryan.co>
2019-06-25 01:26:49 -04:00