Skip to content

Commit

Permalink
Upgrade to latest pydantic
Browse files Browse the repository at this point in the history
  • Loading branch information
istride committed Oct 15, 2024
1 parent 0b58d58 commit a7ea46c
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
3 changes: 2 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,8 @@ classifiers = [
]
dependencies = [
"fastapi~=0.110.0",
"pydantic~=1.10.14",
"pydantic",
"pydantic-settings",
"rpft @ https://github.com/IDEMSInternational/rapidpro-flow-toolkit/archive/refs/heads/main.tar.gz",
]
description = "Spreadsheet-backed API for ParentText goals"
Expand Down
6 changes: 4 additions & 2 deletions src/parenttext_goals_webhooks/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,9 @@
from pathlib import Path

from fastapi import FastAPI
from pydantic import BaseModel, BaseSettings
from pydantic import BaseModel
from pydantic_settings import BaseSettings


from parenttext_goals_webhooks import api_version
from parenttext_goals_webhooks.hooks import Hooks
Expand Down Expand Up @@ -79,7 +81,7 @@ class ListQuery(BaseModel):
sort_columns: list[str] = list()

class Config:
schema_extra = {
json_schema_extra = {
"examples": [
{
"filter_expression": "'no' in relationship",
Expand Down
2 changes: 0 additions & 2 deletions tests/test_integrity.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,6 @@ def test_module_IDs(self):
self.assertTrue(hasattr(row, "topic_ID"), row)
self.assertTrue(hasattr(row, "name"), row)
self.assertIn(row.topic_ID, link_data, row)
# TODO: If we have a list of all modules in RapidPro,
# we can also check that the module ID is from that list

def test_ltp_headers(self):
data = self.db.ltp_activities()
Expand Down

0 comments on commit a7ea46c

Please sign in to comment.