Skip to content

Releases: pdm-project/pdm

v2.11.0

14 Dec 00:44
90f095e
Compare
Choose a tag to compare

Features & Improvements

  • Officially drop the support for Python 3.7.
  • Allow exporting current project as editable dependency with pdm export. #1910
  • Improve the lockfile compatibility checking by using 3-digit version numbers. This can distinguish forward-compatibility and backward-compatibility. #2164
  • Add --skip-existing to pdm publish to ignore the uploading error if the package already exists. #2362
  • Use ==major.minor.* as default requires python for application projects. #2382
  • We now use the package-type field in the tool.pdm table to differentiate between library and application projects. #2394
  • Add support for {pdm} placeholder in script definitions to call the same PDM entrypoint #2408
  • When exporting requirements, record the environment markers from all parents for each requirement. This allows the exported requirements to work on different platforms and Python versions. #2418
  • pdm lock now supports --update-reuse option to keep the pinned versions in the lockfile if possible. #2419
  • Introduce a new lock strategy inherit_metadata to inherit and merge markers from parent requirements. This is enabled by default when creating a new lockfile. #2421
  • New cache methods: symlink_individual for creating a symlink for each individual package file and hardlink for creating hardlinks. #2425
  • Add "pdm sync" pre-commit hook #2474
  • New update strategy: reuse-installed. When this strategy is enabled, PDM will try to reuse the versions already installed in the environment, even if the package names are given in the command line following add or update. This strategy is supported by add, update and lock commands. #2479
  • Show subcommand's help info when passing unrecognized arguments. #2480
  • add PDM_CACHE_DIR environment variable to configure cache directory location. #2485

Bug Fixes

  • Use the same order of Python interpreters as interactive mode in pdm init -n. #2436
  • pdm init now implies --lib if --backend is passed. #2437
  • Fix a bug that link collection ignores package-index-binding. #2442
  • Fix the wrong installation candidates for different architectures on Windows. #2464
  • Fix installing PEP 561 stub-only packages with install.cache_method = "symlink". #2466
  • Fix a KeyError raised by pdm update --unconstrained when the project itself is listed as a dependency. #2483

v2.10.4

24 Nov 01:43
015411d
Compare
Choose a tag to compare

Bug Fixes

  • Do not detect as requirements.txt if the file is a python script. #2416
  • Provide information of the original line when parsing requirement fails. #2417
  • Resolve -r requirements paths relative to the requirement file they are specified in #2422
  • Updating package now overwrites the old files instead of removing before installing. #2423

v2.10.3

16 Nov 12:14
d498f8e
Compare
Choose a tag to compare

Bug Fixes

  • Create virtualenv for conda base Python. #2409

v2.10.2

16 Nov 07:22
2742bdb
Compare
Choose a tag to compare

Features & Improvements

  • Log the response text when pdm publish fails with HTTP error. #2400

Bug Fixes

  • Improve the error message when a specific package can't be found in the lockfile. #2358
  • prevent wrong project name (including space and illegal characters) #2360
  • Fix a bug that PDM cannot detect namespace packages correctly when creating symlinks. The package's __init__.py contains an unusual line. #2378
  • Fix template files created by pdm init being read-only when copied from a read-only PDM installation. #2379
  • Don't reset the build backend when asking for import. #2388
  • Never wrap the output of the export command. #2390
  • Forbid global project in conda base environment, since it may remove conda-managed packages. #2409

v2.10.1

07 Nov 00:52
90aadf0
Compare
Choose a tag to compare

Bug Fixes

  • Fix a bug preventing ctrl-c from interrupting program execution on 2nd invocation when using "pdm run" (Windows only). #2292
  • Fix list index out of range when build error message is empty. #2337
  • Fix find_link sources being exported as --extra--index-url #2342
  • Fix an installation failure when install.cache = true. #2355
  • Fix a resolution issue that extra dependencies are not resolved when the bare dependency has more specific version constraint. #2369

Documentation

  • Set up a chatbot powered by LLM on the doc page. #2365

v2.10.0

26 Oct 02:22
2458ae3
Compare
Choose a tag to compare

Note
This is the last minor release that supports installing on Python 3.7.
Please upgrade your Python to 3.8 or higher.

Features & Improvements

  • Allow binding packages to specific sources with include_packages and exclude_packages config under tool.pdm.source table. #1645
  • Show warnings when a package is rejected by the resolve because of uncovered requires-python range. And provide a way to ignore them per-package. #2304
  • Add -q/--quiet option to suppress some warnings printed to the console. This option is mutually exclusive with -v/--verbose. #2304
  • Introduce a new --strategy/-S option for lock command, to specify one or more strategy flags for resolving dependencies. --static-urls and --no-cross-platform are deprecated at the same time. #2310
  • Add lock option to resolve direct dependencies to the minimal versions available. #2310
  • Report the progress of download and unpacking when installing packages. #2328
  • Refactor find_project_root() and find_pypackage() to look for the project root recursively, and remove the project_max_depth configuration variable and the corresponding PDM_PROJECT_MAX_DEPTH environment variable. #2286

Bug Fixes

  • Change the venv backend clean function pdm.cli.commands.venv.backend.Backend._ensure_clean to empty the .venv folder instead of deleting it. #2282
  • Fix a bug that dependency groups from Poetry 1.2+ do not migrate properly to PDM. #2285
  • Fix a bug that build requirements are installed into wrong location when using --venv option. #2314
  • Fix a bug that global repository setting results in TypeError . #2330
  • Fix a credentials error when working with two indices on the same host #2333

Miscellany

  • Officially supports python3.12 now. #2301

v2.9.3

25 Sep 09:24
5861d12
Compare
Choose a tag to compare

Bug Fixes

  • Revert the changes to the behavior of installing self, introduced in #2162.
    Self package won't be installed when --no-default is requested. #2230
  • Reject the candidate if it contains invalid metadata, to avoid a crash in the process of resolution. #2261

Documentation

  • Clarify what --no-isolated does. #2071

v2.9.2

12 Sep 09:46
a771ffc
Compare
Choose a tag to compare

Features & Improvements

  • Fix an issue that --no-lock option doesn't work as expected. Also support --no-lock option for add, remove and update commands. #2245

Bug Fixes

  • Use findpython to find pythons with the spec given by the user. #2225
  • Use UTF-8 to read pyvenv.cfg. #2227
  • On Windows, try looking for the virtualenv python.exe binary under bin/
    as well as Scripts/ and the virtualenv/conda root. #2236
  • Write relocatable dependency URLs with ${PROJECT_ROOT} variable in the lockfile. #2240

v2.9.1

03 Sep 07:05
a50604c
Compare
Choose a tag to compare

Features & Improvements

  • Support convert setup.cfg without existing setup.py. #2222

Bug Fixes

  • pdm run should only find local file if the command starts with ./. #2221

v2.9.0

31 Aug 07:48
7a740a6
Compare
Choose a tag to compare

Features & Improvements

  • Add an --overwrite option to pdm init to overwrite existing files(default False). #2163
  • Support passing filter patterns as positional arguments to pdm list command.
    Add --tree as an alias and preferred name of --graph option. #2165
  • Switch to truststore by default. #2195
  • Consider packages as installed if the venv includes them from the system-site-packages. #2216
  • Allow pdm run to run a script with the relative or absolute path. #2217

Bug Fixes

  • Fix a bug that removing dev dependency uninstalls the project as well. #2150
  • Fix a bug that @ file:// dependencies can not be updated. #2169
  • Fix a bug that dependencies requested out of the range of requires-python cause PDM to crash. #2175
  • Fix the compatibility issue with copier 8.0+. #2177
  • Makes comarable_version("1.2.3+local1") == Version("1.2.3"). #2182
  • Default behavior for pdm venv activate when shell detection fails. #2187
  • Handle parsing errors when converting from poetry-style metadata. #2203
  • Don't copy .pyc files from the template directory. #2213

Removals and Deprecations

  • Remove the legacy build backend pdm-pep517. #2167