Skip to content

Commit

Permalink
Remove FastAPI monkey-patch
Browse files Browse the repository at this point in the history
  • Loading branch information
davidbrochart committed Sep 4, 2022
1 parent 5e56c32 commit 00a03a5
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 8 deletions.
8 changes: 0 additions & 8 deletions plugins/yjs/fps_yjs/routes.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,14 +27,6 @@ class JupyterSQLiteYStore(SQLiteYStore):
router = APIRouter()


def get_path_param_names(path: str) -> Set[str]:
return {name.split(":")[0] for name in re.findall("{(.*?)}", path)}


# FIXME: remove the patch when https://github.com/tiangolo/fastapi/pull/3879 is merged
fastapi.utils.get_path_param_names.__code__ = get_path_param_names.__code__


def to_datetime(iso_date: str) -> datetime:
return datetime.fromisoformat(iso_date.rstrip("Z"))

Expand Down
1 change: 1 addition & 0 deletions setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ package_dir =
python_requires = >=3.7

install_requires =
fastapi >=0.82.0
fps >=0.0.19
fps-uvicorn >=0.0.19
fps-contents
Expand Down

0 comments on commit 00a03a5

Please sign in to comment.