mirror of
https://github.com/element-hq/synapse.git
synced 2026-06-06 17:42:10 +00:00
Fix database migrations failing on platforms where SQLite is configured with SQLITE_DBCONFIG_DEFENSIVE by default, such as macOS. (#19690)
Fixes: #19616 This caused 2+ people trouble now, so worth batting away with a low-effort change if we can. Only seen on macOS so far, but nothing stops SQLite being configured in defensive mode by default on other platforms, so it is not necessarily entirely specific to macOS. We *could* also do this for Python < 3.12 but it'd be more effort and I don't know if it's worth it. (For context @kegsay says the interpreter with this problem was installed through `pyenv install`.) --------- Signed-off-by: Olivier 'reivilibre <oliverw@matrix.org>
This commit is contained in:
committed by
GitHub
parent
52c05c5ca4
commit
943da0ace8
@@ -309,21 +309,6 @@ works without further arguments).
|
||||
Your Postgres account needs to be able to create databases; see the postgres
|
||||
docs for [`ALTER ROLE`](https://www.postgresql.org/docs/current/sql-alterrole.html).
|
||||
|
||||
### Running the tests on MacOS
|
||||
|
||||
To run the unit tests with SQLite on MacOS you will need to swap out the default MacOS
|
||||
python interpreter with the homebrew version. This is due to the default using a
|
||||
locked down version of Python and sqlite3. After installing python from homebrew:
|
||||
|
||||
```
|
||||
poetry env remove --all
|
||||
poetry env use /opt/homebrew/bin/python3.13
|
||||
poetry install
|
||||
poetry run trial tests
|
||||
```
|
||||
|
||||
This example uses python 3.13, but choose whichever version you want.
|
||||
|
||||
## Run the integration tests ([Sytest](https://github.com/matrix-org/sytest)).
|
||||
|
||||
The integration tests are a more comprehensive suite of tests. They
|
||||
|
||||
Reference in New Issue
Block a user