Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merge 0.6.x into 0.7.x #206

Merged
merged 38 commits into from
Dec 13, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
38 commits
Select commit Hold shift + click to select a range
5d2503b
Adds cleanupsyncs command parameters
akolson Jul 13, 2023
89fac4c
Changes argument underscores to hythens, uodates changelog + version …
akolson Jul 18, 2023
5ef2225
Merge pull request #186 from akolson/add-cleanupsyncs-params
bjester Jul 18, 2023
6e5e0e0
Fix latest version number
bjester Jul 18, 2023
85b9e72
corrects version number on changelogs
akolson Jul 18, 2023
682b003
Merge pull request #189 from akolson/add-cleanupsyncs-params
bjester Jul 18, 2023
6c3a5f9
Update publishing workflow
bjester Jul 18, 2023
3962121
Use python3 instead
bjester Jul 18, 2023
7ed1215
Merge pull request #190 from bjester/update-publish-0.6.x
bjester Jul 18, 2023
9e9d00e
Update github action workflows for py2.7 deprecation
bjester Sep 11, 2023
2217f6b
Fix linting issue
bjester Sep 11, 2023
6c733df
Python2.7 backports for test.support
bjester Sep 11, 2023
fed7ed9
Bump ubuntu 18.04 to 20.04, create matrixized jobs for 2.7, 3.4, 3.5
bjester Sep 11, 2023
8fac257
fix test backports for 3.4 & 3.5, remove 3.4+crypto
bjester Sep 12, 2023
7320330
Merge pull request #199 from bjester/fix-gh-actions
rtibbles Sep 12, 2023
85688a2
Add the ReadTheDocs config file
MisRob Sep 13, 2023
4f95820
Clean up theme settings
MisRob Sep 15, 2023
bfc3a58
Remove accelerated deps
bjester Sep 28, 2023
79d05e9
Add custom user agent
vkWeb Aug 30, 2023
45da82a
Bump python version down
bjester Sep 28, 2023
2fe0cde
Install morango itself, and core deps
bjester Sep 28, 2023
5dcbb40
Merge pull request #202 from MisRob/docs-config-file
bjester Sep 28, 2023
3eb9b13
Merge pull request #197 from vkWeb/customised_user_agent
bjester Sep 28, 2023
d0ec1dd
Add option to ignore process check when resuming sync session
bjester Jul 24, 2023
934db63
Update changelog
bjester Jul 25, 2023
6e9a653
Update changelog for other changes
bjester Sep 28, 2023
4e51901
Merge pull request #194 from bjester/optional-ignore-on-resume
bjester Sep 28, 2023
43e5eed
Add test for deletion and recreation across syncing.
rtibbles Oct 3, 2023
8d4a4af
Prevent DeletedModel creation during model deserialization.
rtibbles Oct 3, 2023
318f861
Don't create HardDeleted or Deleted models on deserialization.
rtibbles Oct 5, 2023
057ffde
Update changelog and version for 0.6.18
rtibbles Oct 5, 2023
ca558cc
Assert deletion in fact, rather than in record, for FKs onto hard del…
rtibbles Oct 5, 2023
c38a957
Merge pull request #203 from rtibbles/no_deleted_model_tracking_in_de…
rtibbles Oct 5, 2023
c9cbdae
Fix issue in iteration of sessions; only close sync sessions when als…
bjester Nov 14, 2023
3ddd45f
Add test for active transfer filter
bjester Nov 14, 2023
3552d4c
Bump version and update changelog
bjester Nov 14, 2023
fb1a67b
Merge pull request #205 from bjester/a-sync-story
bjester Nov 14, 2023
e7a9b76
Merge branch 'release-v0.6.x' into 'release-v0.7.x'
rtibbles Dec 12, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 4 additions & 6 deletions .github/workflows/python-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,13 @@ on:

jobs:
deploy:

runs-on: ubuntu-20.04

runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v2
uses: actions/setup-python@v3
with:
python-version: 2.7
python-version: 3.9
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
8 changes: 3 additions & 5 deletions .github/workflows/python2-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,11 @@ jobs:
name: Python 2 syntax checking
needs: pre_job
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
runs-on: ubuntu-latest
runs-on: ubuntu-20.04
container:
image: python:2.7.18-buster
steps:
- uses: actions/checkout@v2
- name: Set up Python 2.7
uses: actions/setup-python@v2
with:
python-version: 2.7
- name: Install dependencies
run: |
python -m pip install --upgrade pip
Expand Down
127 changes: 99 additions & 28 deletions .github/workflows/tox.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,67 +18,134 @@ jobs:
unit_test:
name: Python unit tests
needs: pre_job
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
runs-on: ubuntu-20.04
strategy:
max-parallel: 5
matrix:
python-version: [2.7, 3.6, 3.7, 3.8, 3.9, '3.10', '3.11']
python-version: [3.6, 3.7, 3.8, 3.9, '3.10', '3.11']

steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install tox
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: |
python -m pip install --upgrade pip
pip install tox
- name: tox env cache
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/.tox/py${{ matrix.python-version }}
key: ${{ runner.os }}-tox-py${{ matrix.python-version }}-${{ hashFiles('setup.py', 'requirements/*.txt') }}
- name: Test with tox
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: tox -e py${{ matrix.python-version }}
unit_test_deprecated:
name: Python unit tests (deprecated python versions)
needs: pre_job
runs-on: ubuntu-20.04
strategy:
max-parallel: 3
matrix:
python-version: [2.7]
container:
image: python:${{ matrix.python-version }}
steps:
- uses: actions/checkout@v2
- name: Install tox
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: |
python -m pip install --upgrade pip
pip install tox
- name: tox env cache
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/.tox/py${{ matrix.python-version }}
key: ${{ runner.os }}-tox-py${{ matrix.python-version }}-${{ hashFiles('setup.py', 'requirements/*.txt') }}
- name: Test with tox
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: tox -e py${{ matrix.python-version }}
cryptography:
name: Python unit tests + cryptography
needs: pre_job
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
runs-on: ubuntu-20.04
strategy:
max-parallel: 5
matrix:
# only crypto 3.3 seems to work
python-version: [ 2.7, 3.6, 3.7, 3.8, 3.9, '3.10', '3.11' ]
python-version: [ 3.6, 3.7, 3.8, 3.9, '3.10', '3.11' ]
crypto-version: [ 3.3 ]

steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install system dependencies
run: |
sudo apt-get -y -qq update
sudo apt-get install -y openssl libssl-dev
- name: Install tox
run: |
python -m pip install --upgrade pip
pip install tox
- name: tox env cache
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/.tox/py${{ matrix.python-version }}
key: ${{ runner.os }}-tox-py${{ matrix.python-version }}-crypto${{ matrix.crypto-version }}-${{ hashFiles('setup.py', 'requirements/*.txt') }}
- name: Test with tox
run: tox -e py${{ matrix.python-version }}-cryptography${{ matrix.crypto-version }}
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install system dependencies
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: |
sudo apt-get -y -qq update
sudo apt-get install -y openssl libssl-dev
- name: Install tox
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: |
python -m pip install --upgrade pip
pip install tox
- name: tox env cache
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/.tox/py${{ matrix.python-version }}
key: ${{ runner.os }}-tox-py${{ matrix.python-version }}-crypto${{ matrix.crypto-version }}-${{ hashFiles('setup.py', 'requirements/*.txt') }}
- name: Test with tox
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: tox -e py${{ matrix.python-version }}-cryptography${{ matrix.crypto-version }}
cryptography_deprecated:
name: Python unit tests (deprecated python versions) + cryptography
needs: pre_job
runs-on: ubuntu-20.04
strategy:
max-parallel: 3
matrix:
# Packages are no longer available for the distribution that comes with the
# python:3.4 image, so we can't install the necessary dependencies. Eventually,
# this will happen to the others as well.
# EOL: [3.4]
python-version: [2.7]
container:
image: python:${{ matrix.python-version }}
steps:
- uses: actions/checkout@v2
- name: Install system dependencies
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: |
apt-get -y -qq update
apt-get install -y openssl libssl-dev
- name: Install tox
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: |
python -m pip install --upgrade pip
pip install tox
- name: tox env cache
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/.tox/py${{ matrix.python-version }}
key: ${{ runner.os }}-tox-py${{ matrix.python-version }}-crypto3.3-${{ hashFiles('setup.py', 'requirements/*.txt') }}
- name: Test with tox
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: tox -e py${{ matrix.python-version }}-cryptography3.3
postgres:
name: Python postgres unit tests
needs: pre_job
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
runs-on: ubuntu-20.04
services:
# Label used to access the service container
Expand All @@ -102,19 +169,23 @@ jobs:
steps:
- uses: actions/checkout@v2
- name: Set up Python 3.9 for Postgres
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
uses: actions/setup-python@v2
with:
python-version: 3.9
- name: Install tox
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: |
python -m pip install --upgrade pip
pip install tox
- name: tox env cache
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
uses: actions/cache@v2
with:
path: ${{ github.workspace }}/.tox/py${{ matrix.python-version }}
key: ${{ runner.os }}-tox-py${{ matrix.python-version }}-${{ hashFiles('setup.py', 'requirements/*.txt') }}
path: ${{ github.workspace }}/.tox/py3.6
key: ${{ runner.os }}-tox-py3.6-${{ hashFiles('setup.py', 'requirements/*.txt') }}
- name: Test with tox
if: ${{ needs.pre_job.outputs.should_skip != 'true' }}
run: tox -e postgres
windows:
name: Python unit tests on Windows Server
Expand All @@ -123,7 +194,7 @@ jobs:
strategy:
max-parallel: 5
matrix:
python-version: [3.9]
python-version: [3.8]

steps:
- uses: actions/checkout@v2
Expand Down
6 changes: 4 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -77,14 +77,16 @@ target/
# celery beat schedule file
celerybeat-schedule

# dotenv
# dotenv, envrc
.env
.envrc

# virtualenv
venv/
ENV/
.venv
Pipfile
.envrc

# Spyder project settings
.spyderproject
Expand All @@ -97,4 +99,4 @@ Pipfile

*.db

.vscode
.vscode
12 changes: 12 additions & 0 deletions .readthedocs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
version: 2
formats: all
build:
os: ubuntu-22.04
tools:
python: "3.9"
sphinx:
configuration: docs/conf.py
python:
install:
- requirements: requirements/docs.txt
- path: .
14 changes: 14 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,20 @@

List of the most important changes for each release.

## 0.6.19
- The `cleanupsyncs` management command now only cleans up sync sessions if also inactive for `expiration` amount of time
- Fixes issue accessing index on queryset in `cleanupsyncs` management command

## 0.6.18
- Prevent creation of Deleted and HardDeleted models during deserialization to allow propagation of syncable objects that are recreated after a previous deletion without causing a merge conflict.

## 0.6.17
- Added `client-instance-id`, `server-instance-id`, `sync-filter`, `push` and `pull` arguments to `cleanupsyncs` management command
- Added option for resuming a sync to ignore the `SyncSession`'s existing `process_id`
- Added custom user agent to sync HTTP requests
- Fixed documentation build issues
- Makefile no longer defines shell with explicit path

## 0.6.16
- Added dedicated `client_instance_id` and `server_instance_id` fields to `SyncSession`
- Renamed `client_instance` and `server_instance` fields on `SyncSession` to `client_instance_json` and `server_instance_json` respectively
Expand Down
12 changes: 5 additions & 7 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
from django.utils.encoding import force_text
from django.utils.html import strip_tags

import sphinx_rtd_theme

# If extensions (or modules to document with autodoc) are in another
# directory, add these directories to sys.path here. If the directory is
# relative to the documentation root, use os.path.abspath to make it
Expand Down Expand Up @@ -164,14 +166,10 @@ def process_docstring(app, what, name, obj, options, lines):

# The theme to use for HTML and HTML Help pages. See the documentation for
# a list of builtin themes.
html_theme = 'default'

if not False: # only import and set the theme if we're building docs locally
import sphinx_rtd_theme

html_theme = "sphinx_rtd_theme"
html_theme_path = [".", sphinx_rtd_theme.get_html_theme_path()]
# html_theme = 'default'

html_theme = "sphinx_rtd_theme"
html_theme_path = [".", sphinx_rtd_theme.get_html_theme_path()]

# Approach 2 for custom stylesheet:
# adapted from: http://rackerlabs.github.io/docs-rackspace/tools/rtd-tables.html
Expand Down
Loading
Loading