Skip to content

Commit

Permalink
fix(error): convert fabric error context to str,str (#7)
Browse files Browse the repository at this point in the history
  • Loading branch information
portellaa authored Oct 18, 2022
1 parent ad6b1f4 commit 11a5fc2
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/core/ydata/core/error/fabric_error.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
from __future__ import annotations
import json
from typing import Optional

Expand All @@ -8,13 +9,17 @@ def _camelcased(value: str) -> str:


class FabricError(Exception):
context: Optional[dict]
context: Optional[dict[str, str]]
description: str
http_code: Optional[int]
name: Optional[str]
return_value: int

def __init__(self, context: Optional[dict] = None, http_code: Optional[int] = None, name: Optional[str] = None):
def __init__(
self,
context: Optional[dict[str, str]] = None,
http_code: Optional[int] = None,
name: Optional[str] = None):
self.context = context
self.http_code = http_code
self.name = name
Expand Down

0 comments on commit 11a5fc2

Please sign in to comment.