Skip to content

Commit

Permalink
fix(models:automation_blocker): fix type of samples
Browse files Browse the repository at this point in the history
  • Loading branch information
simsa-st committed Mar 25, 2024
1 parent 2e5aeff commit b36d6a8
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
2 changes: 1 addition & 1 deletion rossum_api/models/automation_blocker.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ class AutomationBlockerContent:
type: str
schema_id: Optional[str] = None
samples_truncated: Optional[bool] = False
samples: Dict[str, Any] = field(default_factory=dict)
samples: List[Dict[str, Any]] = field(default_factory=list)
details: Dict[str, Any] = field(default_factory=dict)


Expand Down
11 changes: 10 additions & 1 deletion tests/elis_api_client/test_annotations.py
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,16 @@ def dummy_annotation_with_sideloads():
"automation_blocker": {
"id": 981916,
"url": "https://elis.develop.r8.lol/api/v1/automation_blockers/981916",
"content": [{"type": "automation_disabled", "level": "annotation"}],
"content": [
{"type": "automation_disabled", "level": "annotation"},
{
"level": "datapoint",
"type": "error_message",
"samples": [
{"details": {"message_content": ["Total Amount is most likely not empty"]}}
],
},
],
"annotation": "https://elis.develop.r8.lol/api/v1/annotations/3232238",
},
"email_thread": None,
Expand Down

0 comments on commit b36d6a8

Please sign in to comment.