Skip to content

Commit bd3b8ed

Browse files
committed
Getting ready for release 3.1.1
1 parent a18f81b commit bd3b8ed

File tree

6 files changed

+56
-10
lines changed

6 files changed

+56
-10
lines changed

ANNOUNCE.rst

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
Announcing Python-Blosc2 3.1.0
2-
==============================
1+
Announcing Python-Blosc2 3.1.0 (and 3.1.1)
2+
==========================================
33

44
This is a minor release where we optimized the performance of the
55
internal compute engine, as well as indexing for NDArrays. We also
@@ -29,7 +29,7 @@ You can think of Python-Blosc2 3.0 as an extension of NumPy/numexpr that:
2929

3030
Install it with::
3131

32-
pip install blosc2==3.1.0 # if you prefer wheels
32+
pip install blosc2 --update # if you prefer wheels
3333
conda install -c conda-forge python-blosc2 mkl # if you prefer conda and MKL
3434

3535
For more info, you can have a look at the release notes in:

RELEASE_NOTES.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,11 @@
11
# Release notes
22

3+
## Changes from 3.1.0 to 3.1.1
4+
5+
* Quick release to fix an issue with version number in the package (was reporting 3.0.0
6+
instead of 3.1.0).
7+
8+
39
## Changes from 3.0.0 to 3.1.0
410

511
### Improvements

RELEASING.rst

Lines changed: 10 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,13 @@ Python-Blosc2 release procedure
44
Preliminaries
55
-------------
66

7-
* Set the version number in ``pyproject.toml`` to the new version number (e.g. ``X.Y.Z``).
7+
* Set the version number for the release by using::
8+
9+
python update_version.py X.Y.Z
10+
11+
and double-check the updated version number in ``pyproject.toml`` and with::
12+
13+
python -c "import blosc2; print(blosc2.__version__)"
814

915
* Make sure that the c-blosc2 repository is updated to the latest version (or a specific
1016
version that will be documented in the ``RELEASE_NOTES.md``). In ``CMakeLists.txt`` edit::
@@ -18,11 +24,10 @@ Preliminaries
1824

1925
* Make sure that the current main branch is passing the tests in continuous integration.
2026

21-
* Build the package and make sure that::
27+
* Build the package and make sure that tests are passing::
2228

23-
python -c "import blosc2; blosc2.print_versions()"
24-
25-
is printing the correct versions.
29+
pip install -e ".[test]"
30+
pytest
2631

2732
* Make sure that ``RELEASE_NOTES.md`` and ``ANNOUNCE.rst`` are up to date with the
2833
latest news in the release.

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ dependencies = [
3939
"httpx",
4040
"platformdirs",
4141
]
42-
version = "3.1.0"
42+
version = "3.1.1"
4343

4444

4545
[project.optional-dependencies]

src/blosc2/version.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = "3.0.0"
1+
__version__ = "3.1.1"

update_version.py

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
#######################################################################
2+
# Copyright (c) 2019-present, Blosc Development Team <[email protected]>
3+
# All rights reserved.
4+
#
5+
# This source code is licensed under a BSD-style license (found in the
6+
# LICENSE file in the root directory of this source tree)
7+
#######################################################################
8+
9+
import re
10+
import sys
11+
12+
13+
def update_version(new_version):
14+
# Update version in pyproject.toml
15+
with open("pyproject.toml") as file:
16+
pyproject_content = file.read()
17+
pyproject_content = re.sub(r'version = ".*"', f'version = "{new_version}"', pyproject_content)
18+
with open("pyproject.toml", "w") as file:
19+
file.write(pyproject_content)
20+
21+
# Update version in src/blosc2/version.py
22+
with open("src/blosc2/version.py") as file:
23+
version_content = file.read()
24+
version_content = re.sub(r'__version__ = ".*"', f'__version__ = "{new_version}"', version_content)
25+
with open("src/blosc2/version.py", "w") as file:
26+
file.write(version_content)
27+
28+
29+
if __name__ == "__main__":
30+
if len(sys.argv) != 2:
31+
print("Usage: python update_version.py <new_version>")
32+
sys.exit(1)
33+
new_version = sys.argv[1]
34+
update_version(new_version)
35+
print(f"Version updated to {new_version}")

0 commit comments

Comments
 (0)