Skip to content

Commit d4ae606

Browse files
authored
Merge branch 'master' into dependabot/pip/django-taggit-approx-eq-6.1.0
2 parents 9e62223 + fa0a8ff commit d4ae606

File tree

304 files changed

+13085
-11526
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

304 files changed

+13085
-11526
lines changed

.github/FUNDING.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# These are supported funding model platforms
2-
github: # Replace with up to 4 GitHub Sponsors-enabled usernames e.g., [user1, user2]
2+
github: [openwisp]
33
patreon: # Replace with a single Patreon username
44
open_collective: # Replace with a single Open Collective username
55
ko_fi: # Replace with a single Ko-fi username

.github/ISSUE_TEMPLATE/bug_report.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@ name: Bug report
33
about: Open a bug report
44
title: "[bug] "
55
labels: bug
6-
assignees: ''
7-
6+
assignees: ""
87
---
98

109
**Describe the bug**
1110
A clear and concise description of the bug or unexpected behavior.
1211

1312
**Steps To Reproduce**
1413
Steps to reproduce the behavior:
14+
1515
1. Go to '...'
1616
2. Click on '....'
1717
3. Scroll down to '....'
@@ -24,7 +24,8 @@ A clear and concise description of what you expected to happen.
2424
If applicable, add screenshots to help explain your problem.
2525

2626
**System Informatioon:**
27-
- OS: [e.g. Ubuntu 24.04 LTS]
28-
- Python Version: [e.g. Python 3.11.2]
29-
- Django Version: [e.g. Django 4.2.5]
30-
- Browser and Browser Version (if applicable): [e.g. Chromium v126.0.6478.126]
27+
28+
- OS: [e.g. Ubuntu 24.04 LTS]
29+
- Python Version: [e.g. Python 3.11.2]
30+
- Django Version: [e.g. Django 4.2.5]
31+
- Browser and Browser Version (if applicable): [e.g. Chromium v126.0.6478.126]

.github/ISSUE_TEMPLATE/feature_request.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@ name: Feature request
33
about: Suggest an idea for this project
44
title: "[feature] "
55
labels: enhancement
6-
assignees: ''
7-
6+
assignees: ""
87
---
98

109
**Is your feature request related to a problem? Please describe.**

.github/ISSUE_TEMPLATE/question.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,7 @@ name: Question
33
about: Please use the Discussion Forum to ask questions
44
title: "[question] "
55
labels: question
6-
assignees: ''
7-
6+
assignees: ""
87
---
98

109
Please use the [Discussion Forum](https://github.com/orgs/openwisp/discussions) to ask questions.

.github/workflows/ci.yml

Lines changed: 64 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
---
2-
32
name: OpenWISP Controller CI Build
43

54
on:
@@ -9,6 +8,9 @@ on:
98
pull_request:
109
branches:
1110
- master
11+
- "1.1"
12+
- gsoc25-map
13+
- gsoc25-whois
1214

1315
jobs:
1416
build:
@@ -39,76 +41,76 @@ jobs:
3941
django-version: django~=4.2.0
4042

4143
steps:
42-
- uses: actions/checkout@v4
43-
with:
44-
ref: ${{ github.event.pull_request.head.sha }}
44+
- uses: actions/checkout@v4
45+
with:
46+
ref: ${{ github.event.pull_request.head.sha }}
4547

46-
- name: Cache APT packages
47-
uses: actions/cache@v4
48-
with:
49-
path: /var/cache/apt/archives
50-
key: apt-${{ runner.os }}-${{ hashFiles('.github/workflows/ci.yml') }}
51-
restore-keys: |
52-
apt-${{ runner.os }}-
48+
- name: Cache APT packages
49+
uses: actions/cache@v4
50+
with:
51+
path: /var/cache/apt/archives
52+
key: apt-${{ runner.os }}-${{ hashFiles('.github/workflows/ci.yml') }}
53+
restore-keys: |
54+
apt-${{ runner.os }}-
5355
54-
- name: Disable man page auto-update
55-
run: |
56-
echo 'set man-db/auto-update false' | sudo debconf-communicate >/dev/null
57-
sudo dpkg-reconfigure man-db
56+
- name: Disable man page auto-update
57+
run: |
58+
echo 'set man-db/auto-update false' | sudo debconf-communicate >/dev/null
59+
sudo dpkg-reconfigure man-db
5860
59-
- name: Set up Python ${{ matrix.python-version }}
60-
uses: actions/setup-python@v5
61-
with:
62-
python-version: ${{ matrix.python-version }}
63-
cache: 'pip'
64-
cache-dependency-path: |
65-
**/requirements*.txt
61+
- name: Set up Python ${{ matrix.python-version }}
62+
uses: actions/setup-python@v5
63+
with:
64+
python-version: ${{ matrix.python-version }}
65+
cache: "pip"
66+
cache-dependency-path: |
67+
**/requirements*.txt
6668
67-
- name: Install Dependencies
68-
id: deps
69-
run: |
70-
sudo apt update
71-
sudo apt -qq -y install sqlite3 gdal-bin libproj-dev \
72-
libgeos-dev libspatialite-dev spatialite-bin \
73-
libsqlite3-mod-spatialite
74-
sudo npm install -g prettier
75-
pip install -U pip wheel setuptools
76-
pip install -U -r requirements-test.txt
77-
pip install -U -e .
78-
pip install ${{ matrix.django-version }}
69+
- name: Install Dependencies
70+
id: deps
71+
run: |
72+
sudo apt update
73+
sudo apt -qq -y install sqlite3 gdal-bin libproj-dev \
74+
libgeos-dev libspatialite-dev spatialite-bin \
75+
libsqlite3-mod-spatialite
76+
sudo npm install -g prettier
77+
pip install -U pip wheel setuptools
78+
pip install -U -r requirements-test.txt
79+
pip install -U -e .
80+
pip install ${{ matrix.django-version }}
7981
80-
- name: Start postgres and redis
81-
if: ${{ !cancelled() && steps.deps.conclusion == 'success' }}
82-
run: docker compose up -d postgres redis
82+
- name: Start postgres and redis
83+
if: ${{ !cancelled() && steps.deps.conclusion == 'success' }}
84+
run: docker compose up -d postgres redis
8385

84-
- name: QA checks
85-
run: ./run-qa-checks
86+
- name: QA checks
87+
run: ./run-qa-checks
8688

87-
- name: Tests
88-
if: ${{ !cancelled() && steps.deps.conclusion == 'success' }}
89-
run: |
90-
coverage run runtests.py --parallel || coverage run ./runtests.py
91-
# tests the extension capability
92-
SAMPLE_APP=1 coverage run ./runtests.py --parallel --keepdb --exclude-tag=selenium_tests \
93-
|| SAMPLE_APP=1 coverage run ./runtests.py --keepdb --exclude-tag=selenium_tests
94-
coverage combine
95-
coverage xml
96-
env:
97-
SELENIUM_HEADLESS: 1
98-
GECKO_LOG: 1
89+
- name: Tests
90+
if: ${{ !cancelled() && steps.deps.conclusion == 'success' }}
91+
run: |
92+
coverage run runtests.py --parallel || coverage run ./runtests.py
93+
# tests the extension capability
94+
SAMPLE_APP=1 coverage run ./runtests.py --parallel --keepdb --exclude-tag=selenium_tests \
95+
|| SAMPLE_APP=1 coverage run ./runtests.py --keepdb --exclude-tag=selenium_tests
96+
coverage combine
97+
coverage xml
98+
env:
99+
SELENIUM_HEADLESS: 1
100+
GECKO_LOG: 1
99101

100-
- name: Show gecko web driver log on failures
101-
if: ${{ failure() }}
102-
run: cat geckodriver.log
102+
- name: Show gecko web driver log on failures
103+
if: ${{ failure() }}
104+
run: cat geckodriver.log
103105

104-
- name: Upload Coverage
105-
if: ${{ success() }}
106-
uses: coverallsapp/github-action@v2
107-
with:
108-
parallel: true
109-
format: cobertura
110-
flag-name: python-${{ matrix.env.env }}
111-
github-token: ${{ secrets.GITHUB_TOKEN }}
106+
- name: Upload Coverage
107+
if: ${{ success() }}
108+
uses: coverallsapp/github-action@v2
109+
with:
110+
parallel: true
111+
format: cobertura
112+
flag-name: python-${{ matrix.env.env }}
113+
github-token: ${{ secrets.GITHUB_TOKEN }}
112114

113115
coveralls:
114116
needs: build
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
name: publiccode.yml validation
2+
3+
on: [pull_request, push]
4+
5+
jobs:
6+
publiccode_yml_validation:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v4
10+
- uses: italia/publiccode-parser-action@v1
11+
with:
12+
publiccode: "publiccode.yml"

.github/workflows/pypi.yml

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -17,16 +17,16 @@ jobs:
1717
permissions:
1818
id-token: write
1919
steps:
20-
- uses: actions/checkout@v4
21-
- name: Set up Python
22-
uses: actions/setup-python@v5
23-
with:
24-
python-version: '3.10'
25-
- name: Install dependencies
26-
run: |
27-
pip install -U pip
28-
pip install build
29-
- name: Build package
30-
run: python -m build
31-
- name: Publish package distributions to PyPI
32-
uses: pypa/gh-action-pypi-publish@v1.12.4
20+
- uses: actions/checkout@v4
21+
- name: Set up Python
22+
uses: actions/setup-python@v5
23+
with:
24+
python-version: "3.10"
25+
- name: Install dependencies
26+
run: |
27+
pip install -U pip
28+
pip install build
29+
- name: Build package
30+
run: python -m build
31+
- name: Publish package distributions to PyPI
32+
uses: pypa/gh-action-pypi-publish@v1.13.0

CHANGES.rst

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,41 @@ Version 1.2.0 [Unreleased]
66

77
Work in progress.
88

9+
Version 1.1.2 [2025-08-01]
10+
--------------------------
11+
12+
Bugfixes
13+
~~~~~~~~
14+
15+
- Fixed `compatibility of OpenWrt.update_config with openwisp-config >=
16+
1.1.0 <https://github.com/openwisp/openwisp-controller/issues/964>`__.
17+
- Fixed `VPN-client template switch issue when switching between VPN
18+
servers with the same address
19+
<https://github.com/openwisp/openwisp-controller/issues/973>`__.
20+
- Fixed `missing config_changed signal when reverting a template
21+
<https://github.com/openwisp/openwisp-controller/issues/836>`__.
22+
- Fixed `Zerotier network name being set to "ow_zt" instead of "global"
23+
<https://github.com/openwisp/openwisp-controller/issues/982>`__.
24+
- Fixed error in preview when device has no name set.
25+
- Fixed live updates for "Send commands" when multiple websocket
26+
connections are open for the same device.
27+
- Limited command results in the device admin to 30 entries to avoid
28+
loading issues.
29+
- Fixed uncaught exception in ``leaflet.draw.i18n.js``.
30+
- Fixed `handling of devices without a DeviceConnection when creating
31+
commands
32+
<https://github.com/openwisp/openwisp-controller/issues/1016>`__.
33+
- Prevented `adding multiple VPN client templates pointing to the same VPN
34+
server <https://github.com/openwisp/openwisp-controller/issues/832>`__.
35+
- Fixed timeout issues in VPN checksum and download configuration views
36+
for large VPN setups (e.g., 2000+ WireGuard peers) by caching the
37+
checksum and generated configuration.
38+
- Fixed an issue where enforcing required templates was accidentally
39+
deleting `VpnClient` objects, causing them to be recreated whenever
40+
device templates were modified in the Django admin.
41+
- Fixed ``HTTP 500 Server Error`` when geographic REST API endpoints
42+
receive a malformed resource ID.
43+
944
Version 1.1.1 [2025-01-31]
1045
--------------------------
1146

docs/developer/extending.rst

Lines changed: 5 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -342,9 +342,7 @@ Once you have created the models, add the following to your
342342
CONFIG_TEMPLATE_MODEL = "sample_config.Template"
343343
CONFIG_VPN_MODEL = "sample_config.Vpn"
344344
CONFIG_VPNCLIENT_MODEL = "sample_config.VpnClient"
345-
CONFIG_ORGANIZATIONCONFIGSETTINGS_MODEL = (
346-
"sample_config.OrganizationConfigSettings"
347-
)
345+
CONFIG_ORGANIZATIONCONFIGSETTINGS_MODEL = "sample_config.OrganizationConfigSettings"
348346
CONFIG_ORGANIZATIONLIMITS_MODEL = "sample_config.OrganizationLimits"
349347
DJANGO_X509_CA_MODEL = "sample_pki.Ca"
350348
DJANGO_X509_CERT_MODEL = "sample_pki.Cert"
@@ -354,12 +352,8 @@ Once you have created the models, add the following to your
354352
CONNECTION_CREDENTIALS_MODEL = "sample_connection.Credentials"
355353
CONNECTION_DEVICECONNECTION_MODEL = "sample_connection.DeviceConnection"
356354
CONNECTION_COMMAND_MODEL = "sample_connection.Command"
357-
SUBNET_DIVISION_SUBNETDIVISIONRULE_MODEL = (
358-
"sample_subnet_division.SubnetDivisionRule"
359-
)
360-
SUBNET_DIVISION_SUBNETDIVISIONINDEX_MODEL = (
361-
"sample_subnet_division.SubnetDivisionIndex"
362-
)
355+
SUBNET_DIVISION_SUBNETDIVISIONRULE_MODEL = "sample_subnet_division.SubnetDivisionRule"
356+
SUBNET_DIVISION_SUBNETDIVISIONINDEX_MODEL = "sample_subnet_division.SubnetDivisionIndex"
363357
364358
Substitute ``sample_config``, ``sample_pki``, ``sample_connection``,
365359
``sample_geo`` & ``sample_subnet_division`` with the name you chose in
@@ -483,9 +477,7 @@ For example:
483477
SubnetDivisionRuleInlineAdmin,
484478
)
485479
486-
SubnetDivisionRuleInlineAdmin.fields += [
487-
"example"
488-
] # <-- monkey patching example
480+
SubnetDivisionRuleInlineAdmin.fields += ["example"] # <-- monkey patching example
489481
490482
14.2. Inheriting admin classes
491483
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -843,9 +835,7 @@ them upon deletion for that device.
843835
# performs no operation for existing objects.
844836
@classmethod
845837
def provision_for_existing_objects(cls, rule_obj):
846-
for device in Device.objects.filter(
847-
organization=rule_obj.organization
848-
):
838+
for device in Device.objects.filter(organization=rule_obj.organization):
849839
cls.provision_receiver(device, created=True)
850840
851841
After creating a class for your custom rule type, you will need to set

0 commit comments

Comments
 (0)