Skip to content

Commit c80f94d

Browse files
authored
v3.8.0 (#224)
1 parent c4e55b3 commit c80f94d

File tree

12 files changed

+77
-70
lines changed

12 files changed

+77
-70
lines changed

.github/workflows/codeql.yml

+52-53
Original file line numberDiff line numberDiff line change
@@ -12,67 +12,66 @@
1212
name: "CodeQL"
1313

1414
on:
15-
push:
16-
branches: [ "main" ]
17-
pull_request:
18-
# The branches below must be a subset of the branches above
19-
branches: [ "main" ]
20-
schedule:
21-
# Runs at 22:21 on Monday.
22-
- cron: '21 22 * * 1'
15+
push:
16+
branches: ["main"]
17+
pull_request:
18+
# The branches below must be a subset of the branches above
19+
branches: ["main"]
20+
schedule:
21+
# Runs at 22:21 on Monday.
22+
- cron: "21 22 * * 1"
2323

2424
jobs:
25-
analyze:
26-
name: Analyze
27-
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
28-
timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
29-
permissions:
30-
actions: read
31-
contents: read
32-
security-events: write
25+
analyze:
26+
name: Analyze
27+
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
28+
timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
29+
permissions:
30+
actions: read
31+
contents: read
32+
security-events: write
3333

34-
strategy:
35-
fail-fast: false
36-
matrix:
37-
language: [ 'javascript', 'python' ]
38-
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby', 'swift' ]
39-
# Use only 'java' to analyze code written in Java, Kotlin or both
40-
# Use only 'javascript' to analyze code written in JavaScript, TypeScript or both
41-
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
34+
strategy:
35+
fail-fast: false
36+
matrix:
37+
language: ["javascript", "python"]
38+
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby', 'swift' ]
39+
# Use only 'java' to analyze code written in Java, Kotlin or both
40+
# Use only 'javascript' to analyze code written in JavaScript, TypeScript or both
41+
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
4242

43-
steps:
44-
- name: Checkout repository
45-
uses: actions/checkout@v3
43+
steps:
44+
- name: Checkout repository
45+
uses: actions/checkout@v4
4646

47-
# Initializes the CodeQL tools for scanning.
48-
- name: Initialize CodeQL
49-
uses: github/codeql-action/init@v2
50-
with:
51-
languages: ${{ matrix.language }}
52-
# If you wish to specify custom queries, you can do so here or in a config file.
53-
# By default, queries listed here will override any specified in a config file.
54-
# Prefix the list here with "+" to use these queries and those in the config file.
47+
# Initializes the CodeQL tools for scanning.
48+
- name: Initialize CodeQL
49+
uses: github/codeql-action/init@v2
50+
with:
51+
languages: ${{ matrix.language }}
52+
# If you wish to specify custom queries, you can do so here or in a config file.
53+
# By default, queries listed here will override any specified in a config file.
54+
# Prefix the list here with "+" to use these queries and those in the config file.
5555

56-
# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
57-
# queries: security-extended,security-and-quality
56+
# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
57+
# queries: security-extended,security-and-quality
5858

59+
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift).
60+
# If this step fails, then you should remove it and run the build manually (see below)
61+
- name: Autobuild
62+
uses: github/codeql-action/autobuild@v2
5963

60-
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift).
61-
# If this step fails, then you should remove it and run the build manually (see below)
62-
- name: Autobuild
63-
uses: github/codeql-action/autobuild@v2
64+
# ℹ️ Command-line programs to run using the OS shell.
65+
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
6466

65-
# ℹ️ Command-line programs to run using the OS shell.
66-
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
67+
# If the Autobuild fails above, remove it and uncomment the following three lines.
68+
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
6769

68-
# If the Autobuild fails above, remove it and uncomment the following three lines.
69-
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
70+
# - run: |
71+
# echo "Run, Build Application using script"
72+
# ./location_of_script_within_repo/buildscript.sh
7073

71-
# - run: |
72-
# echo "Run, Build Application using script"
73-
# ./location_of_script_within_repo/buildscript.sh
74-
75-
- name: Perform CodeQL Analysis
76-
uses: github/codeql-action/analyze@v2
77-
with:
78-
category: "/language:${{matrix.language}}"
74+
- name: Perform CodeQL Analysis
75+
uses: github/codeql-action/analyze@v2
76+
with:
77+
category: "/language:${{matrix.language}}"

.github/workflows/publish-develop-docs.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ jobs:
88
deploy:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/checkout@v3
11+
- uses: actions/checkout@v4
1212
with:
1313
fetch-depth: 0
14-
- uses: actions/setup-python@v4
14+
- uses: actions/setup-python@v5
1515
with:
1616
python-version: 3.x
1717
- run: pip install -r requirements/build-docs.txt

.github/workflows/publish-py.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,9 @@ jobs:
1111
release-package:
1212
runs-on: ubuntu-latest
1313
steps:
14-
- uses: actions/checkout@v3
14+
- uses: actions/checkout@v4
1515
- name: Set up Python
16-
uses: actions/setup-python@v4
16+
uses: actions/setup-python@v5
1717
with:
1818
python-version: "3.x"
1919
- name: Install dependencies

.github/workflows/publish-release-docs.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -8,10 +8,10 @@ jobs:
88
deploy:
99
runs-on: ubuntu-latest
1010
steps:
11-
- uses: actions/checkout@v3
11+
- uses: actions/checkout@v4
1212
with:
1313
fetch-depth: 0
14-
- uses: actions/setup-python@v4
14+
- uses: actions/setup-python@v5
1515
with:
1616
python-version: 3.x
1717
- run: pip install -r requirements/build-docs.txt

.github/workflows/test-docs.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -14,10 +14,10 @@ jobs:
1414
docs:
1515
runs-on: ubuntu-latest
1616
steps:
17-
- uses: actions/checkout@v3
17+
- uses: actions/checkout@v4
1818
with:
1919
fetch-depth: 0
20-
- uses: actions/setup-python@v4
20+
- uses: actions/setup-python@v5
2121
with:
2222
python-version: 3.x
2323
- name: Check docs build

.github/workflows/test-src.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,9 @@ jobs:
1717
matrix:
1818
python-version: ["3.9", "3.10", "3.11"]
1919
steps:
20-
- uses: actions/checkout@v3
20+
- uses: actions/checkout@v4
2121
- name: Use Python ${{ matrix.python-version }}
22-
uses: actions/setup-python@v4
22+
uses: actions/setup-python@v5
2323
with:
2424
python-version: ${{ matrix.python-version }}
2525
- name: Install Python Dependencies

CHANGELOG.md

+8-3
Original file line numberDiff line numberDiff line change
@@ -34,14 +34,18 @@ Using the following categories, list your changes in this order:
3434

3535
## [Unreleased]
3636

37+
- Nothing (yet)!
38+
39+
## [3.8.0] - 2024-02-20
40+
3741
### Added
3842

3943
- Built-in cross-process communication mechanism via the `reactpy_django.hooks.use_channel_layer` hook.
4044
- Access to the root component's `id` via the `reactpy_django.hooks.use_root_id` hook.
4145
- More robust control over ReactPy clean up tasks!
4246
- `settings.py:REACTPY_CLEAN_INTERVAL` to control how often ReactPy automatically performs cleaning tasks.
43-
- `settings.py:REACTPY_CLEAN_SESSIONS` to control whether ReactPy automatically cleans up expired sessions.
44-
- `settings.py:REACTPY_CLEAN_USER_DATA` to control whether ReactPy automatically cleans up orphaned user data.
47+
- `settings.py:REACTPY_CLEAN_SESSIONS` to control whether ReactPy should clean up expired sessions during automatic cleanups.
48+
- `settings.py:REACTPY_CLEAN_USER_DATA` to control whether ReactPy should clean up orphaned user data during automatic cleanups.
4549
- `python manage.py clean_reactpy` command to manually perform ReactPy clean up tasks.
4650

4751
### Changed
@@ -461,7 +465,8 @@ Using the following categories, list your changes in this order:
461465

462466
- Support for IDOM within the Django
463467

464-
[Unreleased]: https://github.com/reactive-python/reactpy-django/compare/3.7.0...HEAD
468+
[Unreleased]: https://github.com/reactive-python/reactpy-django/compare/3.8.0...HEAD
469+
[3.8.0]: https://github.com/reactive-python/reactpy-django/compare/3.7.0...3.8.0
465470
[3.7.0]: https://github.com/reactive-python/reactpy-django/compare/3.6.0...3.7.0
466471
[3.6.0]: https://github.com/reactive-python/reactpy-django/compare/3.5.1...3.6.0
467472
[3.5.1]: https://github.com/reactive-python/reactpy-django/compare/3.5.0...3.5.1

README.md

+1
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@
2727
- [Customizable reconnection behavior](https://reactive-python.github.io/reactpy-django/latest/reference/settings/#stability-settings)
2828
- [Customizable disconnection behavior](https://reactive-python.github.io/reactpy-django/latest/reference/template-tag)
2929
- [Multiple root components](https://reactive-python.github.io/reactpy-django/latest/reference/template-tag/)
30+
- [Cross-process communication/signaling (Channel Layers)](https://reactive-python.github.io/reactpy-django/latest/reference/hooks/#use-channel-layer)
3031
- [Django view to ReactPy component conversion](https://reactive-python.github.io/reactpy-django/latest/reference/components/#view-to-component)
3132
- [Django static file access](https://reactive-python.github.io/reactpy-django/latest/reference/components/#django-css)
3233
- [Django database access](https://reactive-python.github.io/reactpy-django/latest/reference/hooks/#use-query)

docs/src/reference/hooks.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -369,7 +369,7 @@ This is often used to create chat systems, synchronize data between components,
369369
pip install channels-redis
370370
```
371371

372-
3. Configure your `settings.py` to use `RedisChannelLayer` as your layer backend.
372+
3. Configure your `settings.py` to use `#!python RedisChannelLayer` as your layer backend.
373373

374374
```python linenums="0"
375375
CHANNEL_LAYERS = {

docs/src/reference/settings.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,7 @@ Use `#!python 0` to not store any session data.
232232

233233
Minimum seconds between ReactPy automatic clean up operations.
234234

235-
The server will check if the interval has passed after every component disconnection, and will perform a clean if needed.
235+
After a component disconnection, the server will perform a clean up if this amount of time has passed since the last clean up.
236236

237237
Set this value to `#!python None` to disable automatic clean up operations.
238238

docs/src/reference/template-tag.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ Django template tags can be used within your HTML templates to provide ReactPy f
1212

1313
This template tag can be used to insert any number of ReactPy components onto your page.
1414

15+
Each component loaded via this template tag will receive a dedicated WebSocket connection to the server.
16+
1517
=== "my-template.html"
1618

1719
{% include-markdown "../../../README.md" start="<!--html-code-start-->" end="<!--html-code-end-->" %}
@@ -27,7 +29,7 @@ This template tag can be used to insert any number of ReactPy components onto yo
2729
| `#!python class` | `#!python str | None` | The HTML class to apply to the top-level component div. | `#!python None` |
2830
| `#!python key` | `#!python Any` | Force the component's root node to use a [specific key value](https://reactpy.dev/docs/guides/creating-interfaces/rendering-data/index.html#organizing-items-with-keys). Using `#!python key` within a template tag is effectively useless. | `#!python None` |
2931
| `#!python host` | `#!python str | None` | The host to use for the ReactPy connections. If unset, the host will be automatically configured.<br/>Example values include: `localhost:8000`, `example.com`, `example.com/subdir` | `#!python None` |
30-
| `#!python prerender` | `#!python str` | If `#!python "true"`, the component will pre-rendered, which enables SEO compatibility and reduces perceived latency. | `#!python "false"` |
32+
| `#!python prerender` | `#!python str` | If `#!python "true"` the component will pre-rendered, which enables SEO compatibility and reduces perceived latency. | `#!python "false"` |
3133
| `#!python offline` | `#!python str` | The dotted path to a component that will be displayed if your root component loses connection to the server. Keep in mind, this `offline` component will be non-interactive (hooks won't operate). | `#!python ""` |
3234
| `#!python **kwargs` | `#!python Any` | The keyword arguments to provide to the component. | N/A |
3335

src/reactpy_django/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
REACTPY_WEBSOCKET_ROUTE,
99
)
1010

11-
__version__ = "3.7.0"
11+
__version__ = "3.8.0"
1212
__all__ = [
1313
"REACTPY_WEBSOCKET_PATH",
1414
"REACTPY_WEBSOCKET_ROUTE",

0 commit comments

Comments
 (0)