Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
44 commits
Select commit Hold shift + click to select a range
e2da247
Add prometheus histograms for room shutdown/delete/purge
Fizzadar May 12, 2025
31945fe
Update Beeper base rules
Fizzadar Mar 8, 2024
71ef069
Add JWT UI auth flow
Fizzadar Mar 8, 2024
d66aaa0
Update email copy for Beeper
Fizzadar Mar 8, 2024
57741f2
Add Beeper log formatter
Fizzadar Mar 8, 2024
68bdf2c
Add Beeper previews
Fizzadar Mar 24, 2025
5167031
Add Beeper inbox endpoints
Fizzadar Mar 8, 2024
a5d90ad
Remove any bridge bot users from ignored user account data
Fizzadar Mar 8, 2024
b72e3a4
Add Beeper notification counts
Fizzadar Mar 24, 2025
3cfb8a0
Include stream ordering in the unsigned event dict
Fizzadar Mar 8, 2024
b280815
Allow clients to add extra content to receipts
Fizzadar Mar 8, 2024
e63a3ae
Include empty identity server in well known
Fizzadar Oct 25, 2024
7b690db
Allow checking username availability when registration disabled
Fizzadar Mar 8, 2024
6388182
Change default DM room redaction power level to 100
Fizzadar Mar 8, 2024
c22bcc3
Disable transaction timeout when purging rooms
Fizzadar Mar 8, 2024
b4e8ff6
Send all notifications as high priority
Fizzadar Mar 24, 2025
7ff8991
Add Beeper specific test cases
Fizzadar Mar 8, 2024
ad6a3e9
Add CI
Fizzadar Mar 8, 2024
7dad6e5
Remove dependabot config
Fizzadar Mar 8, 2024
d83cfc1
Add Beeper readme
Fizzadar Mar 8, 2024
bbc29d4
Add Beeper release flow scripts
Fizzadar Mar 25, 2024
079d704
Add env var to disable writing to the `user_ips` table
Fizzadar Mar 28, 2024
7522b4a
Increase last seen granularity to 1h
Fizzadar Mar 28, 2024
deb2da0
Add at_order property to inbox_state endpoint
bradtgmurray Aug 13, 2024
d1f669d
Look for done.at_order in the correct place in inbox_state endpoint
bradtgmurray Aug 13, 2024
2de4591
Add note to readme about real fork
Fizzadar Sep 9, 2024
1703ce8
Bump CI action
Fizzadar Oct 4, 2024
4b5900e
Register the admin user servelet in generic worker
Fizzadar Oct 4, 2024
4f4f2b3
Replace isort and black with ruff in Beeper CI
bradtgmurray Dec 3, 2024
cc18fbc
Don't track IPs for API admin
Fizzadar Jan 9, 2025
bff1098
reset email: change branding to Beeper logo
sumnerevans Jul 3, 2024
bc389c0
Install synapse-http-antispam module
tulir Mar 21, 2025
2951bd8
Update CI/fix types for recent synapse changes
Fizzadar Mar 24, 2025
447e79e
Ignore f-strings in logging statements
tulir Jul 15, 2025
3307600
Add OpenIdStore to GenericWorkerStore
tulir Aug 28, 2025
e6596ed
Add server name label to custom metrics
tulir Oct 7, 2025
4f4aee9
Run delete stale devices background task on start
Fizzadar Nov 11, 2025
6875a3c
Use consistent Python version in CI
Fizzadar Nov 11, 2025
413c8bb
Temporarily reduce scheduled task load
Fizzadar Nov 11, 2025
2cde763
Remove hack to stop tracking admin-api device IPs and last seen
Fizzadar Nov 18, 2025
9c08132
Disable bundled aggregations
Fizzadar Mar 17, 2026
d340eac
Support MSC4446: Move fully read markers backwards (#59)
SpiritCroc Apr 9, 2026
cfff824
Explain branching strategy in readme
radon-at-beeper Apr 10, 2026
b026e54
Bump sytest/complement commits and other actions
tulir Jun 10, 2026
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
93 changes: 0 additions & 93 deletions .github/dependabot.yml

This file was deleted.

141 changes: 141 additions & 0 deletions .github/workflows/beeper-ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,141 @@
name: Beep

on:
push:
branches: ["beeper", "beeper-*"]
pull_request:


jobs:
lint-style:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: "3.13"
- run: pip install poetry
- run: poetry install
- run: poetry run ruff check --output-format=github .

lint-types:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: "3.13"
- run: pip install poetry
- run: poetry install --extras all
- run: poetry run mypy

# Tests

test-trial:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/setup-python@v6
with:
python-version: "3.13"
- run: pip install poetry
- run: poetry install --extras all
- run: poetry run trial -j4 tests

test-sytest:
runs-on: ubuntu-latest
container:
image: matrixdotorg/sytest-synapse:bookworm
volumes:
- ${{ github.workspace }}:/src
env:
SYTEST_BRANCH: e9982eeedd352daaad1e24a067477070b6b5b0b7
TOP: ${{ github.workspace }}
POSTGRES: 1
MULTI_POSTGRES: 1
WOKRERS: 1
steps:
- uses: actions/checkout@v6
- 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@v7
if: ${{ always() }}
with:
name: Sytest Logs - ${{ job.status }} - (${{ join(matrix.*, ', ') }})
path: |
/logs/results.tap
/logs/**/*.log*

test-complement:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v6
- uses: actions/checkout@v6
with:
repository: matrix-org/complement
path: complement
ref: bc2b638b11f5b0a068e39ae51f7ac2782070d14f
- name: Install complement dependencies
run: |-
sudo apt-get -qq update
sudo apt-get install -qqy libolm3 libolm-dev
go install -v github.com/gotesttools/gotestfmt/v2/cmd/gotestfmt@latest
pip install poetry
poetry install
- name: Run Complement
run: ./scripts-dev/complement.sh
env:
COMPLEMENT_DIR: complement

# Builds

build-python:
runs-on: ubuntu-latest
env:
DOCKER_BUILDKIT: 1
steps:
- uses: actions/checkout@v6
- uses: docker/setup-qemu-action@v4
- uses: docker/setup-buildx-action@v4
- uses: docker/login-action@v4
with:
registry: ${{ secrets.CI_REGISTRY }}
username: ${{ secrets.CI_REGISTRY_USER }}
password: ${{ secrets.CI_REGISTRY_PASSWORD }}
- run: |-
if [ "${{ github.ref_name }}" = "beeper" ]; then
tag=$(cat pyproject.toml | grep -E "^version =" | sed -E 's/^version = "(.+)"$/\1/')
else
tag="${{ github.head_ref || github.ref_name }}"
fi

docker buildx build \
--push \
--platform linux/amd64 \
--tag ${{ secrets.CI_REGISTRY }}/synapse:$tag-${{ github.sha }} \
-f docker/Dockerfile \
.

if [ "${{ github.ref_name }}" = "beeper" ]; then
docker pull ${{ secrets.CI_REGISTRY }}/synapse:$tag-${{ github.sha }}
docker tag \
${{ secrets.CI_REGISTRY }}/synapse:$tag-${{ github.sha }} \
${{ secrets.CI_REGISTRY }}/synapse:latest
docker push ${{ secrets.CI_REGISTRY }}/synapse:latest
fi

# Ensure the image works properly
docker run \
--entrypoint '' \
${{ secrets.CI_REGISTRY }}/synapse:$tag-${{ github.sha }} \
python -m synapse.app.homeserver --help

echo "Pushed image: synapse:$tag-${{ github.sha }}"
if [ "${{ github.ref_name }}" = "beeper" ]; then
echo "Pushed image: synapse:latest"
fi
67 changes: 67 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,67 @@
# Synapse: Beeper Edition

This is Beeper's custom version of synapse, we rebase roughly 25 commits on top of each upstream release with a few Beeper specific modifications. We also have an actual Synapse fork here: [**beeper/synapse-fork**](https://github.com/beeper/synapse-fork) which is where we make changes we expect to merge into upstream.

## Branching strategy

We have a bunch of branches. The main development branch for Beeper is
the `beeper` branch. Push commits here and they get built for our
Docker registry. The GitHub Actions logs include the specific image
tag, which is based on the original upstream version as well as the
commit hash.

We also have versioned `beeper-x.y.z` branches. These are used to
archive the history of the `beeper` branch as it is rebased onto newer
upstream Synapse versions. When rebasing, we copy the current `beeper`
branch back onto the old `beeper-x.y.z` branch for historical
reference, then create a new `beeper-x.y.z` branch based on the new
upstream version and rebase the `beeper` branch onto it, then
force-push that resulting commit into the original `beeper` branch,
which will become the new development target.

We also have `upstream-x.y.z` branches that just track the upstream
tags that we use as bases for Beeper changes, see the rebase flow
below.

## CI setup

Note that we have a separate `beeper-ci.yml` GitHub Actions workflow.
It runs exclusively on the `beeper*` branches, in place of the other
CI workflows that upstream uses and that we have not removed from our
fork. Don't get confused between the two.

## Rebase flow

### Create PR

Here we're upgrading to `v1.96.1`:

```
# Make a new branch from the upstream release, we do this so we can create a PR
# of Beeper -> upstream to run tests/confirm we're happy.
git checkout -f v1.96.1
git checkout -b upstream-1.96.1
git push -u beeper upstream-1.96.1

# Check out the base branch, pull any changes
git checkout beeper
git pull

# Now create a new branch to rebase
git checkout -b beeper-1.96.1
# And do the rebase
git rebase v1.96.1
# fix any conflicts...

# Push and make a PR from this branch to the upstream one created above
git push -u beeper beeper-1.96.1
```

### Make release

Once it's ready we just overwrite the `beeper` branch with the new one:

```
git checkout beeper-1.96.1
git push --force beeper beeper
```
31 changes: 31 additions & 0 deletions beeper/complete_release.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
#!/usr/bin/env bash

set -euo pipefail
source $(realpath $(dirname $0))/utils.sh

BEEPER_REMOTE=$(get_beeper_remote)

VERSION=${1:-}

if [ -z "$VERSION" ]; then
echo >&2 "Must specify version!"
exit 1
fi

echo "Completing Synapse: Beeper Edition version $VERSION"
echo "WARNING: this script will DELETE the branch called: beeper"
read -p "Press enter to continue"

UPSTREAM_BRANCH=upstream-$VERSION
BEEPER_BRANCH=beeper-$VERSION

git checkout $BEEPER_BRANCH
git branch -D beeper
git checkout -b beeper
git push --force $BEEPER_REMOTE beeper

# Cleanup
git branch -D $BEEPER_BRANCH
git push $BEEPER_REMOTE --delete $BEEPER_BRANCH
git branch -D $UPSTREAM_BRANCH
git push $BEEPER_REMOTE --delete $UPSTREAM_BRANCH
43 changes: 43 additions & 0 deletions beeper/prepare_release.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
#!/usr/bin/env bash

set -euo pipefail
source $(realpath $(dirname $0))/utils.sh

BEEPER_REMOTE=$(get_beeper_remote)

VERSION=${1:-}

if [ -z "$VERSION" ]; then
echo >&2 "Must specify version!"
exit 1
fi

STARTING_BRANCH=$(git branch --show-current)

echo "Preparing Synapse: Beeper Edition version $VERSION"
echo "WARNING: this script will rebase on top of the CURRENT BRANCH: $STARTING_BRANCH"
read -p "Press enter to continue"

TAG=v$VERSION
UPSTREAM_BRANCH=upstream-$VERSION
BEEPER_BRANCH=beeper-$VERSION

# Checkout the tag, create upstream branch, push it
echo "Setup branch $UPSTREAM_BRANCH"
git checkout -f $TAG
git checkout -b $UPSTREAM_BRANCH
git push -u $BEEPER_REMOTE $UPSTREAM_BRANCH

# Switch back to our starting branch, create new version branch from it
echo "Setup branch $BEEPER_BRANCH"
git checkout $STARTING_BRANCH
git checkout -b $BEEPER_BRANCH

# And rebase against upstream, applying only our Beeper commits
echo "Initiate rebase..."
git rebase $UPSTREAM_BRANCH || read -p "Rebase was a mess, press enter once you fix it"

git push -u $BEEPER_REMOTE $BEEPER_BRANCH

echo "OK we done!"
echo "Go HERE and make the PR: https://github.com/beeper/synapse/compare/upstream-$VERSION...beeper-$VERSION?expand=1"
Loading
Loading