Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
2 changes: 1 addition & 1 deletion .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
contents: read
strategy:
matrix:
python-version: ["3.9", "3.10", "3.11"]
python-version: ["3.11", "3.12", "3.13"]
steps:
- uses: actions/checkout@v4

Expand Down
18 changes: 18 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,24 @@

All notable changes to this project will be documented in this file.

## [0.13.0] - 2026-03-26

### Features

- feat: trigger CI actions (that are triggered on PRs) in merge queue (#76) (FrenchGithubUser)

### Miscellaneous Tasks

- chore: bump python version (FrenchGithubUser)
- chore: the synapse team is now the maintainer of this project, update CODEOWNERS and remove obsolete file (FrenchGithubUser)
- chore: twisted dependency doesn't need to be pinned anymore (FrenchGithubUser)
- ci: remove unnecessary branches filter (#77) (FrenchGithubUser)
- fix: update tests to work with breaking changes in recent synapse versions (FrenchGithubUser)

### Refactoring

- refactor: Add more logs (Matheus Zaniolo)

## [0.12.0] - 2025-07-31

### Features
Expand Down
5 changes: 2 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,8 @@ authors = [
classifiers = [
"Development Status :: 4 - Beta",
"Programming Language :: Python",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: Implementation :: CPython",
"Programming Language :: Python :: Implementation :: PyPy",
]
Expand All @@ -28,7 +27,7 @@ dependencies = [
"twisted",
"Twisted",
]
version = "0.12.0"
version = "0.13.0"

[project.urls]
Documentation = "https://github.com/famedly/synapse-token-authenticator"
Expand Down
16 changes: 8 additions & 8 deletions synapse_token_authenticator/token_authenticator.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,30 +22,30 @@

import synapse
from jwcrypto import jwk, jwt
from jwcrypto.jwk import JWKSet
from jwcrypto.common import JWException, json_decode
from jwcrypto.jwk import JWKSet
from synapse.api.errors import HttpResponseException
from synapse.module_api import ModuleApi
from synapse.types import UserID
from twisted.web import resource
from twisted.internet import defer
from twisted.web import resource

from synapse_token_authenticator.config import TokenAuthenticatorConfig
from synapse_token_authenticator.utils import (
get_oidp_metadata,
basic_auth,
validate_scopes,
MetadataResource,
all_list_elems_are_equal_return_the_elem,
basic_auth,
get_oidp_metadata,
get_path_in_dict,
if_not_none,
MetadataResource,
validate_scopes,
)

logger = logging.getLogger(__name__)


class TokenAuthenticator:
__version__ = "0.0.0"
__version__ = "0.13.0"

def __init__(self, config: dict, account_handler: ModuleApi):
self.api = account_handler
Expand Down Expand Up @@ -580,7 +580,7 @@ def get_from_set(set_):

user_id = await self.api.register_user(localpart, admin=bool(admin))
logger.debug(
f"User '{localpart}' created as '{ 'Admin' if bool(admin) else 'User'}'"
f"User '{localpart}' created as '{'Admin' if bool(admin) else 'User'}'"
)

if email:
Expand Down
Loading