Skip to content

Commit 6b42e2f

Browse files
committed
Merge branch 'dev-v2.10' into 2.10
2 parents a829110 + e430af5 commit 6b42e2f

33 files changed

Lines changed: 784 additions & 333 deletions

File tree

.flake8

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
[flake8]
2+
max-line-length=88
23
exclude =
34
.*
45
./contrib
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
name: Create GitHub release
2+
3+
# Create a GitHub release when a tag is pushed
4+
on:
5+
push:
6+
tags:
7+
- 'ckan-**'
8+
9+
jobs:
10+
build:
11+
name: Create GitHub release
12+
runs-on: ubuntu-latest
13+
env:
14+
GH_TOKEN: ${{ github.token }}
15+
steps:
16+
- name: Checkout
17+
uses: actions/checkout@v4
18+
19+
- name: Build Changelog URL and create release
20+
run: |
21+
TAG_NAME=${{ github.ref_name }}
22+
CKAN_VERSION=$(echo $TAG_NAME | sed -s 's/ckan-//')
23+
MAJOR=$(echo $CKAN_VERSION | cut -d'.' -f1)
24+
MINOR=$(echo $CKAN_VERSION | cut -d'.' -f2)
25+
PATCH=$(echo $CKAN_VERSION | cut -d'.' -f3)
26+
27+
DATE=$(git log -1 --format=%ad --date=format:'%Y-%m-%d' $TAG_NAME)
28+
29+
URL="https://docs.ckan.org/en/$MAJOR.$MINOR/changelog.html#v-$MAJOR-$MINOR-$PATCH-$DATE"
30+
31+
NOTES="Full changelog here: $URL"
32+
33+
gh release create "$TAG_NAME" --verify-tag --title "$TAG_NAME" --notes "$NOTES"

.github/workflows/publish-pypi.yml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: Publish to PyPI
2+
3+
# Publish to PyPI when a tag is pushed
4+
on:
5+
push:
6+
tags:
7+
- 'ckan-**'
8+
9+
jobs:
10+
build:
11+
name: Build distribution
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
- name: Set up Python
16+
uses: actions/setup-python@v5
17+
with:
18+
python-version: "3.9"
19+
- name: Install pypa/build
20+
run: >-
21+
python3 -m
22+
pip install
23+
build
24+
--user
25+
- name: Build a binary wheel and a source tarball
26+
run: python3 -m build
27+
- name: Store the distribution packages
28+
uses: actions/upload-artifact@v4
29+
with:
30+
name: python-package-distributions
31+
path: dist/
32+
33+
publish-to-pypi:
34+
name: Publish Python distribution on PyPI
35+
needs:
36+
- build
37+
runs-on: ubuntu-latest
38+
environment:
39+
name: pypi
40+
url: https://pypi.org/p/ckan
41+
permissions:
42+
id-token: write
43+
steps:
44+
- name: Download all the dists
45+
uses: actions/download-artifact@v4
46+
with:
47+
name: python-package-distributions
48+
path: dist/
49+
- name: Publish distribution to PyPI
50+
uses: pypa/gh-action-pypi-publish@release/v1
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
name: Publish to TestPyPI
2+
3+
# Publish to Test PyPI when a pull request is merged to master
4+
on:
5+
push:
6+
branches:
7+
- 'master'
8+
9+
jobs:
10+
build:
11+
name: Build distribution
12+
runs-on: ubuntu-latest
13+
steps:
14+
- uses: actions/checkout@v4
15+
- name: Set up Python
16+
uses: actions/setup-python@v5
17+
with:
18+
python-version: "3.9"
19+
- name: Add timestamp to version number
20+
run: |
21+
TIMESTAMP=$(date +"%Y%m%d%H%M")
22+
sed -E -i 's/__version__ = "(.*)"$/__version__ = "\1.post'$TIMESTAMP'"/' ckan/__init__.py
23+
- name: Install pypa/build
24+
run: >-
25+
python3 -m
26+
pip install
27+
build
28+
--user
29+
- name: Build a binary wheel and a source tarball
30+
run: python3 -m build
31+
- name: Store the distribution packages
32+
uses: actions/upload-artifact@v4
33+
with:
34+
name: python-package-distributions
35+
path: dist/
36+
37+
publish-to-testpypi:
38+
name: Publish Python distribution on TestPyPI
39+
needs:
40+
- build
41+
runs-on: ubuntu-latest
42+
environment:
43+
name: test-pypi
44+
url: https://test.pypi.org/p/ckan
45+
permissions:
46+
id-token: write
47+
steps:
48+
- name: Download all the dists
49+
uses: actions/download-artifact@v4
50+
with:
51+
name: python-package-distributions
52+
path: dist/
53+
- name: Publish distribution to TestPyPI
54+
uses: pypa/gh-action-pypi-publish@release/v1
55+
with:
56+
repository-url: https://test.pypi.org/legacy/

CHANGELOG.rst

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,41 @@ Changelog
99

1010
.. towncrier release notes start
1111
12+
v.2.10.6 2024-12-11
13+
===================
14+
15+
Minor changes
16+
-------------
17+
18+
- `datastore_info` action method now has `side_effect_free`, allowing it to be
19+
available via GET requests in the API. (`#8457
20+
<https://github.com/ckan/ckan/pull/8457>`_)
21+
- Add id attribute to AnonymousUser
22+
(`#8571 <https://github.com/ckan/ckan/pull/8571>`_)
23+
- Automate publishing CKAN package to PyPI (`#8520
24+
<https://github.com/ckan/ckan/pull/8520>`_)
25+
- Automate creation of GitHub release (`#8570
26+
<https://github.com/ckan/ckan/pull/8570>`_)
27+
28+
29+
Bugfixes
30+
--------
31+
32+
- Fixed context in `set_datastore_active_flag` to
33+
solve possible solr errors during `index_package` (`#7571
34+
<https://github.com/ckan/ckan/pull/7571>`_)
35+
- POST request to GET-only endpoint causes 500 error (`#7616
36+
<https://github.com/ckan/ckan/pull/7616>`_)
37+
- Set license model `od_conformance` and `osd_conformance` attributes' default
38+
values to `False` to prevent errors. (`#8268
39+
<https://github.com/ckan/ckan/pull/8268>`_)
40+
- Load the right i18n files for Chinese locales in DataTables View. (`#8432
41+
<https://github.com/ckan/ckan/pull/8432>`_)
42+
- Fixed server error on robots.txt when bootstrap 3 templates were used.
43+
(`#8536 <https://github.com/ckan/ckan/pull/8536>`_)
44+
- Include ``public`` folder in MANIFEST.in
45+
(`#8565 <https://github.com/ckan/ckan/pull/8565>`_)
46+
1247
v.2.10.5 2024-08-21
1348
===================
1449

MANIFEST.in

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ recursive-include ckanext *.py
1515
recursive-include ckanext/*/i18n *
1616
recursive-include ckanext/*/public *
1717
recursive-include ckanext/*/assets *
18+
recursive-include ckanext/*/migration *
1819
recursive-include ckanext/*/templates *
1920
recursive-include ckanext/*/theme/public *
2021
recursive-include ckanext/*/theme/templates *

changes/7574.feature

Lines changed: 0 additions & 6 deletions
This file was deleted.

changes/7616.bugfix

Lines changed: 0 additions & 1 deletion
This file was deleted.

changes/8138.bugfix

Lines changed: 0 additions & 1 deletion
This file was deleted.

changes/8204.bugfix

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)