From fd15157d1f1a72199b48891fdc309551eef88a8c Mon Sep 17 00:00:00 2001 From: "Jens W. Klein" Date: Wed, 28 Feb 2024 14:47:20 +0100 Subject: [PATCH 1/7] Remove --pre on generated sources --- CHANGES.md | 11 ++++++++++- src/mxdev/processing.py | 2 +- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 0867a30..a256f0c 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -1,8 +1,17 @@ ## Changes +### 4.0.0 (2024-02-28) + +- Breaking: Remove `--pre` on sources from generated `requirements-mxdev.txt`. + Usually it is not needed any longer. + This is a breaking change if you rely on the `--pre` option being present in the generated file. + Now the `--pre` option should be added to `pip install` when the generated file is used. + This change enables the use of the generated file with the alternative pip replacement `uv`. + [jensens] + ### 3.1.0 (2023-12-10) -- Provide `directory` default setting [rnix] +- Feature: Provide `directory` default setting [rnix] - Feature: Include other INI config files [jensens] ### 3.0.0 (2023-05-08) diff --git a/src/mxdev/processing.py b/src/mxdev/processing.py index a8db81d..134bc30 100644 --- a/src/mxdev/processing.py +++ b/src/mxdev/processing.py @@ -205,7 +205,7 @@ def write_dev_sources(fio, packages: typing.Dict[str, typing.Dict[str, typing.An continue extras = f"[{package['extras']}]" if package["extras"] else "" subdir = f"/{package['subdirectory']}" if package["subdirectory"] else "" - install_options = " --pre" + install_options = "" editable = ( f"""-e ./{package['target']}/{name}{subdir}{extras}{install_options}\n""" ) From cd47fd94627f06ecaba103a18430f2b9c03965d7 Mon Sep 17 00:00:00 2001 From: "Jens W. Klein" Date: Wed, 28 Feb 2024 15:02:08 +0100 Subject: [PATCH 2/7] fixes #38: add docs for vcs setting --- CHANGES.md | 3 +++ README.md | 16 ++++++++++++++++ 2 files changed, 19 insertions(+) diff --git a/CHANGES.md b/CHANGES.md index a256f0c..883ac7a 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -9,6 +9,9 @@ This change enables the use of the generated file with the alternative pip replacement `uv`. [jensens] +- Document sections `vcs` setting. + [jensens] + ### 3.1.0 (2023-12-10) - Feature: Provide `directory` default setting [rnix] diff --git a/README.md b/README.md index 0918893..4f18da0 100644 --- a/README.md +++ b/README.md @@ -191,6 +191,22 @@ Optional a writable URL for pushes can be specified. If the `pushurl` is set after initial checkout it is not applied. To apply it remove the repository and checkout again. +#### `vcs = VCS` + +The version control system to use. + +Supported are: +- `git` (stable, tested) +- `fs` (stable, tested) - in fact no vcs, but points to a local directory. + This can be achieved without mxdev by using `-e PATH` in the requirements input file. +- `svn` (unstable, test needs rewrite) +- `gitsvn` (unstable, test needs rewrite) +- `hg` (unstable, test needs rewrite) +- `bzr` (unstable, test needs rewrite) +- `darcs` (unstable, test needs rewrite) + +Defaults to `git`. + #### `branch = BRANCHNAME_OR_TAG` The branch name or tag to checkout. From b3478786231938a76be9c8ec7e96f8356ffa711d Mon Sep 17 00:00:00 2001 From: "Jens W. Klein" Date: Wed, 28 Feb 2024 15:03:43 +0100 Subject: [PATCH 3/7] remove empty install options --- src/mxdev/processing.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/mxdev/processing.py b/src/mxdev/processing.py index 134bc30..905846e 100644 --- a/src/mxdev/processing.py +++ b/src/mxdev/processing.py @@ -205,9 +205,8 @@ def write_dev_sources(fio, packages: typing.Dict[str, typing.Dict[str, typing.An continue extras = f"[{package['extras']}]" if package["extras"] else "" subdir = f"/{package['subdirectory']}" if package["subdirectory"] else "" - install_options = "" editable = ( - f"""-e ./{package['target']}/{name}{subdir}{extras}{install_options}\n""" + f"""-e ./{package['target']}/{name}{subdir}{extras}\n""" ) logger.debug(f"-> {editable.strip()}") fio.write(editable) From 72975cca478097afc01917413d32d8122e815c89 Mon Sep 17 00:00:00 2001 From: "Jens W. Klein" Date: Wed, 28 Feb 2024 15:09:15 +0100 Subject: [PATCH 4/7] adjust minimum version of pip needed --- CHANGES.md | 2 +- README.md | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 883ac7a..da51745 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -3,7 +3,7 @@ ### 4.0.0 (2024-02-28) - Breaking: Remove `--pre` on sources from generated `requirements-mxdev.txt`. - Usually it is not needed any longer. + Usually it is not needed any longer, at least withy pip 23.x. This is a breaking change if you rely on the `--pre` option being present in the generated file. Now the `--pre` option should be added to `pip install` when the generated file is used. This change enables the use of the generated file with the alternative pip replacement `uv`. diff --git a/README.md b/README.md index 4f18da0..fe91f59 100644 --- a/README.md +++ b/README.md @@ -277,7 +277,7 @@ Mxdev will Now, use the generated requirements and constraints files with i.e. `pip install -r requirements-mxdev.txt`. -**mxdev >=2.0 needs pip version 22 at minimum to work properly** +**mxdev >=4.0 needs pip version 23 at minimum to work properly** ## Example Configuration From d88f5c519739b5c018dfd66afe224f6b553cd947 Mon Sep 17 00:00:00 2001 From: "Jens W. Klein" Date: Wed, 28 Feb 2024 15:16:35 +0100 Subject: [PATCH 5/7] Drop Python 3.7 support (EOL) --- .github/workflows/release.yaml | 2 +- .github/workflows/tests.yaml | 5 ++--- CHANGES.md | 3 +++ pyproject.toml | 7 +++---- 4 files changed, 9 insertions(+), 8 deletions(-) diff --git a/.github/workflows/release.yaml b/.github/workflows/release.yaml index 509f6e7..a2aecf4 100644 --- a/.github/workflows/release.yaml +++ b/.github/workflows/release.yaml @@ -17,7 +17,7 @@ jobs: steps: - uses: actions/checkout@v4 - name: Set up Python - uses: actions/setup-python@v4 + uses: actions/setup-python@v5 with: python-version: "3.12" - name: Install pypa/build diff --git a/.github/workflows/tests.yaml b/.github/workflows/tests.yaml index 5e539bc..e611ecd 100644 --- a/.github/workflows/tests.yaml +++ b/.github/workflows/tests.yaml @@ -11,14 +11,13 @@ jobs: lint: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@v4 + - uses: actions/setup-python@v5 - uses: pre-commit/action@v3.0.0 build: strategy: matrix: python-version: - - "3.7" - "3.8" - "3.9" - "3.10" diff --git a/CHANGES.md b/CHANGES.md index da51745..3624261 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -9,6 +9,9 @@ This change enables the use of the generated file with the alternative pip replacement `uv`. [jensens] +- Breaking: Drop support for Python 3.7 (it is end of life). + [jensens] + - Document sections `vcs` setting. [jensens] diff --git a/pyproject.toml b/pyproject.toml index 115046f..6ddf5b0 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,21 +1,20 @@ [project] name = "mxdev" description = "Enable to work with Python projects containing lots of packages, of which you only want to develop some." -version = "3.1.0" +version = "4.0.0" keywords = ["pip", "vcs", "git", "development"] authors = [ {name = "MX Stack Developers", email = "dev@bluedynamics.com" } ] -requires-python = ">=3.7" +requires-python = ">=3.8" license = { text = "BSD 2-Clause License" } classifiers = [ - "Development Status :: 4 - Beta", + "Development Status :: 5 - Production/Stable", "Intended Audience :: Developers", "Topic :: Software Development :: Build Tools", "License :: OSI Approved :: BSD License", "Operating System :: OS Independent", "Programming Language :: Python", - "Programming Language :: Python :: 3.7", "Programming Language :: Python :: 3.8", "Programming Language :: Python :: 3.9", "Programming Language :: Python :: 3.10", From be2c6946f3756ea86e3e437462c376b63eab937b Mon Sep 17 00:00:00 2001 From: "Jens W. Klein" Date: Wed, 28 Feb 2024 15:17:44 +0100 Subject: [PATCH 6/7] make format --- src/mxdev/processing.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/mxdev/processing.py b/src/mxdev/processing.py index 905846e..13be0a3 100644 --- a/src/mxdev/processing.py +++ b/src/mxdev/processing.py @@ -205,9 +205,7 @@ def write_dev_sources(fio, packages: typing.Dict[str, typing.Dict[str, typing.An continue extras = f"[{package['extras']}]" if package["extras"] else "" subdir = f"/{package['subdirectory']}" if package["subdirectory"] else "" - editable = ( - f"""-e ./{package['target']}/{name}{subdir}{extras}\n""" - ) + editable = f"""-e ./{package['target']}/{name}{subdir}{extras}\n""" logger.debug(f"-> {editable.strip()}") fio.write(editable) fio.write("\n\n") From 93fbe63a4e579dea5a82d55fab478397fe06a9d2 Mon Sep 17 00:00:00 2001 From: "Jens W. Klein" Date: Wed, 28 Feb 2024 15:46:02 +0100 Subject: [PATCH 7/7] say (official) --- CHANGES.md | 4 ++-- README.md | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CHANGES.md b/CHANGES.md index 3624261..b728e15 100644 --- a/CHANGES.md +++ b/CHANGES.md @@ -9,10 +9,10 @@ This change enables the use of the generated file with the alternative pip replacement `uv`. [jensens] -- Breaking: Drop support for Python 3.7 (it is end of life). +- Breaking: Drop official support for Python 3.7 (it is end of life). [jensens] -- Document sections `vcs` setting. +- Document `mx.ini` sections `vcs` setting. [jensens] ### 3.1.0 (2023-12-10) diff --git a/README.md b/README.md index fe91f59..25c8249 100644 --- a/README.md +++ b/README.md @@ -224,6 +224,7 @@ For specifying the path to the Python package, when it is not in the root of the Default empty. #### `target` + The target directory for source from this section. Default to default target directory configured in the main section `[settings]` `default-target =` value.