Merge branch 'develop' of github.com:matrix-org/synapse into matrix-org-hotfixes
commit
a794ad17c2
|
@ -0,0 +1,4 @@
|
||||||
|
---
|
||||||
|
title: CI run against latest deps is failing
|
||||||
|
---
|
||||||
|
See https://github.com/{{env.GITHUB_REPOSITORY}}/actions/runs/{{env.GITHUB_RUN_ID}}
|
|
@ -1,8 +0,0 @@
|
||||||
#!/bin/sh
|
|
||||||
|
|
||||||
# replaces the dependency on Twisted in `python_dependencies` with trunk.
|
|
||||||
|
|
||||||
set -e
|
|
||||||
cd "$(dirname "$0")"/..
|
|
||||||
|
|
||||||
sed -i -e 's#"Twisted.*"#"Twisted @ git+https://github.com/twisted/twisted"#' synapse/python_dependencies.py
|
|
|
@ -8,8 +8,4 @@
|
||||||
!pyproject.toml
|
!pyproject.toml
|
||||||
!poetry.lock
|
!poetry.lock
|
||||||
|
|
||||||
# TODO: remove these once we have moved over to using poetry-core in pyproject.toml
|
|
||||||
!MANIFEST.in
|
|
||||||
!setup.py
|
|
||||||
|
|
||||||
**/__pycache__
|
**/__pycache__
|
||||||
|
|
|
@ -0,0 +1,156 @@
|
||||||
|
# People who are freshly `pip install`ing from PyPI will pull in the latest versions of
|
||||||
|
# dependencies which match the broad requirements. Since most CI runs are against
|
||||||
|
# the locked poetry environment, run specifically against the latest dependencies to
|
||||||
|
# know if there's an upcoming breaking change.
|
||||||
|
#
|
||||||
|
# As an overview this workflow:
|
||||||
|
# - checks out develop,
|
||||||
|
# - installs from source, pulling in the dependencies like a fresh `pip install` would, and
|
||||||
|
# - runs mypy and test suites in that checkout.
|
||||||
|
#
|
||||||
|
# Based on the twisted trunk CI job.
|
||||||
|
|
||||||
|
name: Latest dependencies
|
||||||
|
|
||||||
|
on:
|
||||||
|
schedule:
|
||||||
|
- cron: 0 7 * * *
|
||||||
|
workflow_dispatch:
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
mypy:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
# The dev dependencies aren't exposed in the wheel metadata (at least with current
|
||||||
|
# poetry-core versions), so we install with poetry.
|
||||||
|
- uses: matrix-org/setup-python-poetry@v1
|
||||||
|
with:
|
||||||
|
python-version: "3.x"
|
||||||
|
poetry-version: "1.2.0b1"
|
||||||
|
# Dump installed versions for debugging.
|
||||||
|
- run: poetry run pip list > before.txt
|
||||||
|
# Upgrade all runtime dependencies only. This is intended to mimic a fresh
|
||||||
|
# `pip install matrix-synapse[all]` as closely as possible.
|
||||||
|
- run: poetry update --no-dev
|
||||||
|
- run: poetry run pip list > after.txt && (diff -u before.txt after.txt || true)
|
||||||
|
- run: poetry run mypy
|
||||||
|
trial:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- database: "sqlite"
|
||||||
|
- database: "postgres"
|
||||||
|
postgres-version: "14"
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- run: sudo apt-get -qq install xmlsec1
|
||||||
|
- name: Set up PostgreSQL ${{ matrix.postgres-version }}
|
||||||
|
if: ${{ matrix.postgres-version }}
|
||||||
|
run: |
|
||||||
|
docker run -d -p 5432:5432 \
|
||||||
|
-e POSTGRES_PASSWORD=postgres \
|
||||||
|
-e POSTGRES_INITDB_ARGS="--lc-collate C --lc-ctype C --encoding UTF8" \
|
||||||
|
postgres:${{ matrix.postgres-version }}
|
||||||
|
- uses: actions/setup-python@v2
|
||||||
|
with:
|
||||||
|
python-version: "3.x"
|
||||||
|
- run: pip install .[all,test]
|
||||||
|
- name: Await PostgreSQL
|
||||||
|
if: ${{ matrix.postgres-version }}
|
||||||
|
timeout-minutes: 2
|
||||||
|
run: until pg_isready -h localhost; do sleep 1; done
|
||||||
|
- run: python -m twisted.trial --jobs=2 tests
|
||||||
|
env:
|
||||||
|
SYNAPSE_POSTGRES: ${{ matrix.database == 'postgres' || '' }}
|
||||||
|
SYNAPSE_POSTGRES_HOST: localhost
|
||||||
|
SYNAPSE_POSTGRES_USER: postgres
|
||||||
|
SYNAPSE_POSTGRES_PASSWORD: postgres
|
||||||
|
- name: Dump logs
|
||||||
|
# Logs are most useful when the command fails, always include them.
|
||||||
|
if: ${{ always() }}
|
||||||
|
# Note: Dumps to workflow logs instead of using actions/upload-artifact
|
||||||
|
# This keeps logs colocated with failing jobs
|
||||||
|
# It also ignores find's exit code; this is a best effort affair
|
||||||
|
run: >-
|
||||||
|
find _trial_temp -name '*.log'
|
||||||
|
-exec echo "::group::{}" \;
|
||||||
|
-exec cat {} \;
|
||||||
|
-exec echo "::endgroup::" \;
|
||||||
|
|| true
|
||||||
|
|
||||||
|
|
||||||
|
sytest:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
container:
|
||||||
|
image: matrixdotorg/sytest-synapse:testing
|
||||||
|
volumes:
|
||||||
|
- ${{ github.workspace }}:/src
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
include:
|
||||||
|
- sytest-tag: focal
|
||||||
|
|
||||||
|
- sytest-tag: focal
|
||||||
|
postgres: postgres
|
||||||
|
workers: workers
|
||||||
|
redis: redis
|
||||||
|
env:
|
||||||
|
POSTGRES: ${{ matrix.postgres && 1}}
|
||||||
|
WORKERS: ${{ matrix.workers && 1 }}
|
||||||
|
REDIS: ${{ matrix.redis && 1 }}
|
||||||
|
BLACKLIST: ${{ matrix.workers && 'synapse-blacklist-with-workers' }}
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- name: Ensure sytest runs `pip install`
|
||||||
|
# Delete the lockfile so sytest will `pip install` rather than `poetry install`
|
||||||
|
run: rm /src/poetry.lock
|
||||||
|
working-directory: /src
|
||||||
|
- name: Prepare test blacklist
|
||||||
|
run: cat sytest-blacklist .ci/worker-blacklist > synapse-blacklist-with-workers
|
||||||
|
- name: Run SyTest
|
||||||
|
run: /bootstrap.sh synapse
|
||||||
|
working-directory: /src
|
||||||
|
- name: Summarise results.tap
|
||||||
|
if: ${{ always() }}
|
||||||
|
run: /sytest/scripts/tap_to_gha.pl /logs/results.tap
|
||||||
|
- name: Upload SyTest logs
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
if: ${{ always() }}
|
||||||
|
with:
|
||||||
|
name: Sytest Logs - ${{ job.status }} - (${{ join(matrix.*, ', ') }})
|
||||||
|
path: |
|
||||||
|
/logs/results.tap
|
||||||
|
/logs/**/*.log*
|
||||||
|
|
||||||
|
|
||||||
|
# TODO: run complement (as with twisted trunk, see #12473).
|
||||||
|
|
||||||
|
# open an issue if the build fails, so we know about it.
|
||||||
|
open-issue:
|
||||||
|
if: failure()
|
||||||
|
needs:
|
||||||
|
# TODO: should mypy be included here? It feels more brittle than the other two.
|
||||||
|
- mypy
|
||||||
|
- trial
|
||||||
|
- sytest
|
||||||
|
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
- uses: JasonEtco/create-an-issue@5d9504915f79f9cc6d791934b8ef34f2353dd74d # v2.5.0, 2020-12-06
|
||||||
|
env:
|
||||||
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
with:
|
||||||
|
update_existing: true
|
||||||
|
filename: .ci/latest_deps_build_failed_issue_template.md
|
||||||
|
|
|
@ -15,24 +15,18 @@ jobs:
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- uses: actions/setup-python@v2
|
- uses: actions/setup-python@v2
|
||||||
- run: pip install -e .
|
- run: pip install .
|
||||||
- run: scripts-dev/generate_sample_config.sh --check
|
- run: scripts-dev/generate_sample_config.sh --check
|
||||||
- run: scripts-dev/config-lint.sh
|
- run: scripts-dev/config-lint.sh
|
||||||
|
|
||||||
lint:
|
lint:
|
||||||
runs-on: ubuntu-latest
|
# This does a vanilla `poetry install` - no extras. I'm slightly anxious
|
||||||
strategy:
|
# that we might skip some typechecks on code that uses extras. However,
|
||||||
matrix:
|
# I think the right way to fix this is to mark any extras needed for
|
||||||
toxenv:
|
# typechecking as development dependencies. To detect this, we ought to
|
||||||
- "check_codestyle"
|
# turn up mypy's strictness: disallow unknown imports and be accept fewer
|
||||||
- "check_isort"
|
# uses of `Any`.
|
||||||
- "mypy"
|
uses: "matrix-org/backend-meta/.github/workflows/python-poetry-ci.yml@v1"
|
||||||
|
|
||||||
steps:
|
|
||||||
- uses: actions/checkout@v2
|
|
||||||
- uses: actions/setup-python@v2
|
|
||||||
- run: pip install tox
|
|
||||||
- run: tox -e ${{ matrix.toxenv }}
|
|
||||||
|
|
||||||
lint-crlf:
|
lint-crlf:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
@ -71,23 +65,23 @@ jobs:
|
||||||
matrix:
|
matrix:
|
||||||
python-version: ["3.7", "3.8", "3.9", "3.10"]
|
python-version: ["3.7", "3.8", "3.9", "3.10"]
|
||||||
database: ["sqlite"]
|
database: ["sqlite"]
|
||||||
toxenv: ["py"]
|
extras: ["all"]
|
||||||
include:
|
include:
|
||||||
# Newest Python without optional deps
|
# Newest Python without optional deps
|
||||||
- python-version: "3.10"
|
- python-version: "3.10"
|
||||||
toxenv: "py-noextras"
|
extras: ""
|
||||||
|
|
||||||
# Oldest Python with PostgreSQL
|
# Oldest Python with PostgreSQL
|
||||||
- python-version: "3.7"
|
- python-version: "3.7"
|
||||||
database: "postgres"
|
database: "postgres"
|
||||||
postgres-version: "10"
|
postgres-version: "10"
|
||||||
toxenv: "py"
|
extras: "all"
|
||||||
|
|
||||||
# Newest Python with newest PostgreSQL
|
# Newest Python with newest PostgreSQL
|
||||||
- python-version: "3.10"
|
- python-version: "3.10"
|
||||||
database: "postgres"
|
database: "postgres"
|
||||||
postgres-version: "14"
|
postgres-version: "14"
|
||||||
toxenv: "py"
|
extras: "all"
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
@ -99,17 +93,16 @@ jobs:
|
||||||
-e POSTGRES_PASSWORD=postgres \
|
-e POSTGRES_PASSWORD=postgres \
|
||||||
-e POSTGRES_INITDB_ARGS="--lc-collate C --lc-ctype C --encoding UTF8" \
|
-e POSTGRES_INITDB_ARGS="--lc-collate C --lc-ctype C --encoding UTF8" \
|
||||||
postgres:${{ matrix.postgres-version }}
|
postgres:${{ matrix.postgres-version }}
|
||||||
- uses: actions/setup-python@v2
|
- uses: matrix-org/setup-python-poetry@v1
|
||||||
with:
|
with:
|
||||||
python-version: ${{ matrix.python-version }}
|
python-version: ${{ matrix.python-version }}
|
||||||
- run: pip install tox
|
extras: ${{ matrix.extras }}
|
||||||
- name: Await PostgreSQL
|
- name: Await PostgreSQL
|
||||||
if: ${{ matrix.postgres-version }}
|
if: ${{ matrix.postgres-version }}
|
||||||
timeout-minutes: 2
|
timeout-minutes: 2
|
||||||
run: until pg_isready -h localhost; do sleep 1; done
|
run: until pg_isready -h localhost; do sleep 1; done
|
||||||
- run: tox -e ${{ matrix.toxenv }}
|
- run: poetry run trial --jobs=2 tests
|
||||||
env:
|
env:
|
||||||
TRIAL_FLAGS: "--jobs=2"
|
|
||||||
SYNAPSE_POSTGRES: ${{ matrix.database == 'postgres' || '' }}
|
SYNAPSE_POSTGRES: ${{ matrix.database == 'postgres' || '' }}
|
||||||
SYNAPSE_POSTGRES_HOST: localhost
|
SYNAPSE_POSTGRES_HOST: localhost
|
||||||
SYNAPSE_POSTGRES_USER: postgres
|
SYNAPSE_POSTGRES_USER: postgres
|
||||||
|
@ -156,23 +149,24 @@ jobs:
|
||||||
|
|
||||||
trial-pypy:
|
trial-pypy:
|
||||||
# Very slow; only run if the branch name includes 'pypy'
|
# Very slow; only run if the branch name includes 'pypy'
|
||||||
|
# Note: sqlite only; no postgres. Completely untested since poetry move.
|
||||||
if: ${{ contains(github.ref, 'pypy') && !failure() && !cancelled() }}
|
if: ${{ contains(github.ref, 'pypy') && !failure() && !cancelled() }}
|
||||||
needs: linting-done
|
needs: linting-done
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
python-version: ["pypy-3.7"]
|
python-version: ["pypy-3.7"]
|
||||||
|
extras: ["all"]
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
|
# Install libs necessary for PyPy to build binary wheels for dependencies
|
||||||
- run: sudo apt-get -qq install xmlsec1 libxml2-dev libxslt-dev
|
- run: sudo apt-get -qq install xmlsec1 libxml2-dev libxslt-dev
|
||||||
- uses: actions/setup-python@v2
|
- uses: matrix-org/setup-python-poetry@v1
|
||||||
with:
|
with:
|
||||||
python-version: ${{ matrix.python-version }}
|
python-version: ${{ matrix.python-version }}
|
||||||
- run: pip install tox
|
extras: ${{ matrix.extras }}
|
||||||
- run: tox -e py
|
- run: poetry run trial --jobs=2 tests
|
||||||
env:
|
|
||||||
TRIAL_FLAGS: "--jobs=2"
|
|
||||||
- name: Dump logs
|
- name: Dump logs
|
||||||
# Logs are most useful when the command fails, always include them.
|
# Logs are most useful when the command fails, always include them.
|
||||||
if: ${{ always() }}
|
if: ${{ always() }}
|
||||||
|
|
|
@ -6,16 +6,25 @@ on:
|
||||||
|
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
|
|
||||||
|
concurrency:
|
||||||
|
group: ${{ github.workflow }}-${{ github.ref }}
|
||||||
|
cancel-in-progress: true
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
mypy:
|
mypy:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- uses: actions/setup-python@v2
|
- uses: matrix-org/setup-python-poetry@v1
|
||||||
- run: .ci/patch_for_twisted_trunk.sh
|
with:
|
||||||
- run: pip install tox
|
python-version: "3.x"
|
||||||
- run: tox -e mypy
|
extras: "all"
|
||||||
|
- run: |
|
||||||
|
poetry remove twisted
|
||||||
|
poetry add --extras tls git+https://github.com/twisted/twisted.git#trunk
|
||||||
|
poetry install --no-interaction --extras "all test"
|
||||||
|
- run: poetry run mypy
|
||||||
|
|
||||||
trial:
|
trial:
|
||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
|
@ -23,14 +32,15 @@ jobs:
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- run: sudo apt-get -qq install xmlsec1
|
- run: sudo apt-get -qq install xmlsec1
|
||||||
- uses: actions/setup-python@v2
|
- uses: matrix-org/setup-python-poetry@v1
|
||||||
with:
|
with:
|
||||||
python-version: 3.7
|
python-version: "3.x"
|
||||||
- run: .ci/patch_for_twisted_trunk.sh
|
extras: "all test"
|
||||||
- run: pip install tox
|
- run: |
|
||||||
- run: tox -e py
|
poetry remove twisted
|
||||||
env:
|
poetry add --extras tls git+https://github.com/twisted/twisted.git#trunk
|
||||||
TRIAL_FLAGS: "--jobs=2"
|
poetry install --no-interaction --extras "all test"
|
||||||
|
- run: poetry run trial --jobs 2 tests
|
||||||
|
|
||||||
- name: Dump logs
|
- name: Dump logs
|
||||||
# Logs are most useful when the command fails, always include them.
|
# Logs are most useful when the command fails, always include them.
|
||||||
|
@ -55,11 +65,23 @@ jobs:
|
||||||
steps:
|
steps:
|
||||||
- uses: actions/checkout@v2
|
- uses: actions/checkout@v2
|
||||||
- name: Patch dependencies
|
- name: Patch dependencies
|
||||||
run: .ci/patch_for_twisted_trunk.sh
|
# Note: The poetry commands want to create a virtualenv in /src/.venv/,
|
||||||
|
# but the sytest-synapse container expects it to be in /venv/.
|
||||||
|
# We symlink it before running poetry so that poetry actually
|
||||||
|
# ends up installing to `/venv`.
|
||||||
|
run: |
|
||||||
|
ln -s -T /venv /src/.venv
|
||||||
|
poetry remove twisted
|
||||||
|
poetry add --extras tls git+https://github.com/twisted/twisted.git#trunk
|
||||||
|
poetry install --no-interaction --extras "all test"
|
||||||
working-directory: /src
|
working-directory: /src
|
||||||
- name: Run SyTest
|
- name: Run SyTest
|
||||||
run: /bootstrap.sh synapse
|
run: /bootstrap.sh synapse
|
||||||
working-directory: /src
|
working-directory: /src
|
||||||
|
env:
|
||||||
|
# Use offline mode to avoid reinstalling the pinned version of
|
||||||
|
# twisted.
|
||||||
|
OFFLINE: 1
|
||||||
- name: Summarise results.tap
|
- name: Summarise results.tap
|
||||||
if: ${{ always() }}
|
if: ${{ always() }}
|
||||||
run: /sytest/scripts/tap_to_gha.pl /logs/results.tap
|
run: /sytest/scripts/tap_to_gha.pl /logs/results.tap
|
||||||
|
|
|
@ -15,8 +15,7 @@ _trial_temp*/
|
||||||
.DS_Store
|
.DS_Store
|
||||||
__pycache__/
|
__pycache__/
|
||||||
|
|
||||||
# We do want the poetry lockfile. TODO: is there a good reason for ignoring
|
# We do want the poetry lockfile.
|
||||||
# '*.lock' above? If not, let's nuke it.
|
|
||||||
!poetry.lock
|
!poetry.lock
|
||||||
|
|
||||||
# stuff that is likely to exist when you run a server locally
|
# stuff that is likely to exist when you run a server locally
|
||||||
|
|
5882
CHANGES.md
5882
CHANGES.md
File diff suppressed because it is too large
Load Diff
54
MANIFEST.in
54
MANIFEST.in
|
@ -1,54 +0,0 @@
|
||||||
include LICENSE
|
|
||||||
include VERSION
|
|
||||||
include *.rst
|
|
||||||
include *.md
|
|
||||||
include demo/README
|
|
||||||
include demo/demo.tls.dh
|
|
||||||
include demo/*.py
|
|
||||||
include demo/*.sh
|
|
||||||
|
|
||||||
include synapse/py.typed
|
|
||||||
recursive-include synapse/storage *.sql
|
|
||||||
recursive-include synapse/storage *.sql.postgres
|
|
||||||
recursive-include synapse/storage *.sql.sqlite
|
|
||||||
recursive-include synapse/storage *.py
|
|
||||||
recursive-include synapse/storage *.txt
|
|
||||||
recursive-include synapse/storage *.md
|
|
||||||
|
|
||||||
recursive-include docs *
|
|
||||||
recursive-include scripts-dev *
|
|
||||||
recursive-include synapse *.pyi
|
|
||||||
recursive-include tests *.py
|
|
||||||
recursive-include tests *.pem
|
|
||||||
recursive-include tests *.p8
|
|
||||||
recursive-include tests *.crt
|
|
||||||
recursive-include tests *.key
|
|
||||||
|
|
||||||
recursive-include synapse/res *
|
|
||||||
recursive-include synapse/static *.css
|
|
||||||
recursive-include synapse/static *.gif
|
|
||||||
recursive-include synapse/static *.html
|
|
||||||
recursive-include synapse/static *.js
|
|
||||||
|
|
||||||
exclude .codecov.yml
|
|
||||||
exclude .coveragerc
|
|
||||||
exclude .dockerignore
|
|
||||||
exclude .editorconfig
|
|
||||||
exclude Dockerfile
|
|
||||||
exclude mypy.ini
|
|
||||||
exclude sytest-blacklist
|
|
||||||
exclude test_postgresql.sh
|
|
||||||
|
|
||||||
include book.toml
|
|
||||||
include pyproject.toml
|
|
||||||
recursive-include changelog.d *
|
|
||||||
|
|
||||||
include .flake8
|
|
||||||
prune .circleci
|
|
||||||
prune .github
|
|
||||||
prune .ci
|
|
||||||
prune contrib
|
|
||||||
prune debian
|
|
||||||
prune demo/etc
|
|
||||||
prune docker
|
|
||||||
prune stubs
|
|
33
README.rst
33
README.rst
|
@ -293,39 +293,42 @@ directory of your choice::
|
||||||
git clone https://github.com/matrix-org/synapse.git
|
git clone https://github.com/matrix-org/synapse.git
|
||||||
cd synapse
|
cd synapse
|
||||||
|
|
||||||
Synapse has a number of external dependencies, that are easiest
|
Synapse has a number of external dependencies. We maintain a fixed development
|
||||||
to install using pip and a virtualenv::
|
environment using [poetry](https://python-poetry.org/). First, install poetry. We recommend
|
||||||
|
|
||||||
python3 -m venv ./env
|
pip install --user pipx
|
||||||
source ./env/bin/activate
|
pipx install poetry
|
||||||
pip install -e ".[all,dev]"
|
|
||||||
|
as described `here <https://python-poetry.org/docs/#installing-with-pipx>`_.
|
||||||
|
(See `poetry's installation docs <https://python-poetry.org/docs/#installation>`
|
||||||
|
for other installation methods.) Then ask poetry to create a virtual environment
|
||||||
|
from the project and install Synapse's dependencies::
|
||||||
|
|
||||||
|
poetry install --extras "all test"
|
||||||
|
|
||||||
This will run a process of downloading and installing all the needed
|
This will run a process of downloading and installing all the needed
|
||||||
dependencies into a virtual env. If any dependencies fail to install,
|
dependencies into a virtual env.
|
||||||
try installing the failing modules individually::
|
|
||||||
|
|
||||||
pip install -e "module-name"
|
|
||||||
|
|
||||||
We recommend using the demo which starts 3 federated instances running on ports `8080` - `8082`
|
We recommend using the demo which starts 3 federated instances running on ports `8080` - `8082`
|
||||||
|
|
||||||
./demo/start.sh
|
poetry run ./demo/start.sh
|
||||||
|
|
||||||
(to stop, you can use `./demo/stop.sh`)
|
(to stop, you can use `poetry run ./demo/stop.sh`)
|
||||||
|
|
||||||
See the [demo documentation](https://matrix-org.github.io/synapse/develop/development/demo.html)
|
See the `demo documentation <https://matrix-org.github.io/synapse/develop/development/demo.html>`_
|
||||||
for more information.
|
for more information.
|
||||||
|
|
||||||
If you just want to start a single instance of the app and run it directly::
|
If you just want to start a single instance of the app and run it directly::
|
||||||
|
|
||||||
# Create the homeserver.yaml config once
|
# Create the homeserver.yaml config once
|
||||||
python -m synapse.app.homeserver \
|
poetry run synapse_homeserver \
|
||||||
--server-name my.domain.name \
|
--server-name my.domain.name \
|
||||||
--config-path homeserver.yaml \
|
--config-path homeserver.yaml \
|
||||||
--generate-config \
|
--generate-config \
|
||||||
--report-stats=[yes|no]
|
--report-stats=[yes|no]
|
||||||
|
|
||||||
# Start the app
|
# Start the app
|
||||||
python -m synapse.app.homeserver --config-path homeserver.yaml
|
poetry run synapse_homeserver --config-path homeserver.yaml
|
||||||
|
|
||||||
|
|
||||||
Running the unit tests
|
Running the unit tests
|
||||||
|
@ -334,7 +337,7 @@ Running the unit tests
|
||||||
After getting up and running, you may wish to run Synapse's unit tests to
|
After getting up and running, you may wish to run Synapse's unit tests to
|
||||||
check that everything is installed correctly::
|
check that everything is installed correctly::
|
||||||
|
|
||||||
trial tests
|
poetry run trial tests
|
||||||
|
|
||||||
This should end with a 'PASSED' result (note that exact numbers will
|
This should end with a 'PASSED' result (note that exact numbers will
|
||||||
differ)::
|
differ)::
|
||||||
|
|
|
@ -0,0 +1 @@
|
||||||
|
Implement [MSC3383](https://github.com/matrix-org/matrix-spec-proposals/pull/3383) for including the destination in server-to-server authentication headers. Contributed by @Bubu and @jcgruenhage for Famedly GmbH.
|
|
@ -1 +0,0 @@
|
||||||
Send device list changes to application services as specified by [MSC3202](https://github.com/matrix-org/matrix-spec-proposals/pull/3202), using unstable prefixes. The `msc3202_transaction_extensions` experimental homeserver config option must be enabled and `org.matrix.msc3202: true` must be present in the application service registration file for device list changes to be sent. The "left" field is currently always empty.
|
|
|
@ -1 +0,0 @@
|
||||||
Optimise fetching large quantities of missing room state over federation.
|
|
|
@ -1 +0,0 @@
|
||||||
Fix a long-standing bug that updating the server notices user profile (display name/avatar URL) in the configuration would not be applied to pre-existing rooms. Contributed by Jorge Florian.
|
|
|
@ -1 +0,0 @@
|
||||||
Remove lingering unstable references to MSC2403 (knocking).
|
|
|
@ -1 +0,0 @@
|
||||||
Avoid trying to calculate the state at outlier events.
|
|
|
@ -1 +0,0 @@
|
||||||
Omit sending "offline" presence updates to application services after they are initially configured.
|
|
|
@ -1 +0,0 @@
|
||||||
Switch to using a sequence to generate AS transaction IDs. Contributed by Nick Beeper. If running synapse with a dedicated appservice worker, this MUST be stopped before upgrading the main process and database.
|
|
|
@ -0,0 +1 @@
|
||||||
|
Prevent a sync request from removing a user's busy presence status.
|
|
@ -1 +0,0 @@
|
||||||
Fix a long-standing bug where events from ignored users were still considered for bundled aggregations.
|
|
|
@ -1 +0,0 @@
|
||||||
Offload the `update_client_ip` background job from the main process to the background worker, when using Redis-based replication.
|
|
|
@ -1 +0,0 @@
|
||||||
Move `update_client_ip` background job from the main process to the background worker.
|
|
|
@ -1 +0,0 @@
|
||||||
Add missing type hints for storage.
|
|
|
@ -1 +0,0 @@
|
||||||
Clarify documentation for running SyTest against Synapse, including use of Postgres and worker mode.
|
|
|
@ -1 +0,0 @@
|
||||||
Add missing type definitions for scripts in docker folder. Contributed by Jorge Florian.
|
|
|
@ -1 +0,0 @@
|
||||||
Remove the unused and unstable `/aggregations` endpoint which was removed from [MSC2675](https://github.com/matrix-org/matrix-doc/pull/2675).
|
|
|
@ -1 +0,0 @@
|
||||||
Move [MSC2654](https://github.com/matrix-org/matrix-doc/pull/2654) support behind an experimental configuration flag.
|
|
|
@ -1 +0,0 @@
|
||||||
Add a module callback to react to new 3PID (email address, phone number) associations.
|
|
|
@ -1 +0,0 @@
|
||||||
Add a configuration option to remove a specific set of rooms from sync responses.
|
|
|
@ -1 +0,0 @@
|
||||||
Document the behaviour of `LoggingTransaction.call_after` and `LoggingTransaction.call_on_exception` methods when transactions are retried.
|
|
|
@ -1 +0,0 @@
|
||||||
Avoid trying to calculate the state at outlier events.
|
|
|
@ -1 +0,0 @@
|
||||||
Update docstrings to explain how to decipher live and historic pagination tokens.
|
|
|
@ -0,0 +1 @@
|
||||||
|
Fix bug with incremental sync missing events when rejoining/backfilling. Contributed by Nick @ Beeper.
|
|
@ -1 +0,0 @@
|
||||||
Add ground work for speeding up device list updates for users in large numbers of rooms.
|
|
|
@ -1 +0,0 @@
|
||||||
Fix typechecker problems exposed by signedjson 1.1.2.
|
|
|
@ -1 +0,0 @@
|
||||||
Add a module callback to react to account data changes.
|
|
|
@ -1 +0,0 @@
|
||||||
Fix non-member state events not resolving for historical events when used in [MSC2716](https://github.com/matrix-org/matrix-spec-proposals/pull/2716) `/batch_send` `state_events_at_start`.
|
|
|
@ -1 +0,0 @@
|
||||||
Avoid trying to calculate the state at outlier events.
|
|
|
@ -1 +0,0 @@
|
||||||
Update dead links in `check-newsfragment.sh` to point to the correct documentation URL.
|
|
|
@ -1 +0,0 @@
|
||||||
Avoid trying to calculate the state at outlier events.
|
|
|
@ -1 +0,0 @@
|
||||||
Fix a long-standing bug affecting URL previews that would generate a 500 response instead of a 403 if the previewed URL includes a port that isn't allowed by the relevant blacklist.
|
|
|
@ -1 +0,0 @@
|
||||||
Remove the `tox` packaging job: it will be redundant once #11537 lands.
|
|
|
@ -1 +0,0 @@
|
||||||
Ignore `.envrc` for `direnv` users.
|
|
|
@ -1 +0,0 @@
|
||||||
Remove the (broadly unused, dev-only) dockerfile for pg tests.
|
|
|
@ -0,0 +1 @@
|
||||||
|
Use poetry to manage Synapse's dependencies.
|
|
@ -1 +0,0 @@
|
||||||
Fix a long-standing bug where events from ignored users were still considered for bundled aggregations.
|
|
|
@ -1 +0,0 @@
|
||||||
Upgrade the version of `mdbook` in CI to 0.4.17.
|
|
|
@ -0,0 +1 @@
|
||||||
|
Fix rendering of the documentation site when using the 'print' feature.
|
|
@ -1 +0,0 @@
|
||||||
Allow setting user admin status using the module API. Contributed by Famedly.
|
|
|
@ -0,0 +1 @@
|
||||||
|
The groups/communities feature in Synapse has been disabled by default.
|
|
@ -1 +0,0 @@
|
||||||
Updates to the Room DAG concepts development document to clarify that we mark events as outliers because we don't have any state for them.
|
|
|
@ -1 +0,0 @@
|
||||||
Remove redundant `get_success` calls in test code.
|
|
|
@ -1 +0,0 @@
|
||||||
Add type annotations for `tests/unittest.py`.
|
|
|
@ -1 +0,0 @@
|
||||||
Move single-use methods out of `TestCase`.
|
|
|
@ -1 +0,0 @@
|
||||||
Remove broken and unused development scripts.
|
|
|
@ -1 +0,0 @@
|
||||||
Default to `private` room visibility rather than `public` when a client does not specify one, according to spec.
|
|
|
@ -1 +0,0 @@
|
||||||
Remove broken and unused development scripts.
|
|
|
@ -1 +0,0 @@
|
||||||
Convert `Linearizer` tests from `inlineCallbacks` to async.
|
|
|
@ -1 +0,0 @@
|
||||||
Update docstrings for `ReadWriteLock` tests.
|
|
|
@ -1 +0,0 @@
|
||||||
Remove broken and unused development scripts.
|
|
|
@ -1 +0,0 @@
|
||||||
Refactor `Linearizer`, convert methods to async and use an async context manager.
|
|
|
@ -1 +0,0 @@
|
||||||
Fix a long-standing bug where `Linearizer`s could get stuck if a cancellation were to happen at the wrong time.
|
|
|
@ -1 +0,0 @@
|
||||||
Fix a spec compliance issue where requests to the `/publicRooms` federation API would specify `limit` as a string.
|
|
|
@ -0,0 +1 @@
|
||||||
|
Enable processing of device list updates asynchronously.
|
|
@ -1 +0,0 @@
|
||||||
Make `StreamToken.from_string` and `RoomStreamToken.parse` propagate cancellations instead of replacing them with `SynapseError`s.
|
|
|
@ -1 +0,0 @@
|
||||||
Reduce overhead of restarting synchrotrons.
|
|
|
@ -0,0 +1 @@
|
||||||
|
Add a manual documenting config file options.
|
|
@ -1 +0,0 @@
|
||||||
Update the link to Redis pub/sub documentation in the workers documentation..
|
|
|
@ -1 +0,0 @@
|
||||||
Update `/messages` to use historic pagination tokens if no `from` query parameter is given.
|
|
|
@ -1 +0,0 @@
|
||||||
Add type hints to tests files.
|
|
|
@ -1 +0,0 @@
|
||||||
Reduce overhead of restarting synchrotrons.
|
|
|
@ -1 +0,0 @@
|
||||||
Allow specifying the Postgres database's port when running unit tests with Postgres.
|
|
|
@ -1 +0,0 @@
|
||||||
Remove temporary pin of signedjson<=1.1.1 that was added in Synapse 1.56.0.
|
|
|
@ -1 +0,0 @@
|
||||||
Add opentracing spans to calls to external cache.
|
|
|
@ -1 +0,0 @@
|
||||||
Lay groundwork for using `poetry` to manage Synapse's dependencies.
|
|
|
@ -0,0 +1 @@
|
||||||
|
Remove unstable identifiers from [MSC3440](https://github.com/matrix-org/matrix-doc/pull/3440).
|
|
@ -1 +0,0 @@
|
||||||
Make missing `importlib_metadata` dependency explicit.
|
|
|
@ -1 +0,0 @@
|
||||||
Bundle locked versions of dependencies into the Docker image.
|
|
|
@ -1 +0,0 @@
|
||||||
Update type annotations for compatiblity with prometheus_client 0.14.
|
|
|
@ -1 +0,0 @@
|
||||||
Fix a bug introduced in Synapse 1.49.0 which caused the `synapse_event_persisted_position` metric to have invalid values.
|
|
|
@ -1 +0,0 @@
|
||||||
Add a module API for reading and writing global account data.
|
|
|
@ -1 +0,0 @@
|
||||||
Remove documentation for converting a legacy structured logging configuration to the new format.
|
|
|
@ -0,0 +1 @@
|
||||||
|
Preparation for faster-room-join work: start a background process to resynchronise the room state after a room join.
|
|
@ -0,0 +1 @@
|
||||||
|
Remove an unstable identifier from [MSC3083](https://github.com/matrix-org/matrix-doc/pull/3083).
|
|
@ -1 +0,0 @@
|
||||||
Remove support for the unstable identifiers specified in [MSC3288](https://github.com/matrix-org/matrix-doc/pull/3288).
|
|
|
@ -0,0 +1 @@
|
||||||
|
Preparation for faster-room-join work: Implement a tracking mechanism to allow functions to wait for full room state to arrive.
|
|
@ -1 +0,0 @@
|
||||||
Make missing `importlib_metadata` dependency explicit.
|
|
|
@ -1 +0,0 @@
|
||||||
Add missing type hints to configuration classes.
|
|
|
@ -1 +0,0 @@
|
||||||
Support the stable `v1` endpoint for `/relations`, per [MSC2675](https://github.com/matrix-org/matrix-doc/pull/2675).
|
|
|
@ -1 +0,0 @@
|
||||||
Add files used to build the Docker image used for complement testing into the Synapse repository.
|
|
|
@ -1 +0,0 @@
|
||||||
Fix up healthcheck generation for workers docker image.
|
|
|
@ -1 +0,0 @@
|
||||||
Run the olddeps CI job using Poetry.
|
|
|
@ -1 +0,0 @@
|
||||||
Do not include groups in the sync response when disabled.
|
|
|
@ -1 +0,0 @@
|
||||||
Avoid trying to calculate the state at outlier events.
|
|
|
@ -1 +0,0 @@
|
||||||
Fix a spec compliance issue where requests to the `/publicRooms` federation API would specify `limit` as a string.
|
|
|
@ -1 +0,0 @@
|
||||||
Run the CI portdb script in the locked poetry environment.
|
|
|
@ -1 +0,0 @@
|
||||||
Improve type hints related to HTTP query parameters.
|
|
|
@ -1 +0,0 @@
|
||||||
Run the CI export-data script in the locked poetry environment.
|
|
|
@ -1 +0,0 @@
|
||||||
Stop maintaining a list of lint targets.
|
|
|
@ -1 +0,0 @@
|
||||||
Make `synapse._scripts` pass type checks.
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue