Skip to content

Commit 1221cc1

Browse files
github-actions[bot]michaelosthege
authored andcommitted
Run pre-commit
1 parent f0926e2 commit 1221cc1

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

pymc3/model.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ def get_context(cls, error_if_none=True) -> Optional[T]:
184184
# Calling code expects to get a TypeError if the entity
185185
# is unfound, and there's too much to fix.
186186
if error_if_none:
187-
raise TypeError(f"No {str(cls)} on context stack")
187+
raise TypeError(f"No {cls} on context stack")
188188
return None
189189
return candidate
190190

@@ -200,9 +200,9 @@ def get_contexts(cls) -> List[T]:
200200
# no race-condition here, contexts is a thread-local object
201201
# be sure not to override contexts in a subclass however!
202202
context_class = cls.context_class
203-
assert isinstance(context_class, type), (
204-
f"Name of context class, {context_class} was not resolvable to a class"
205-
)
203+
assert isinstance(
204+
context_class, type
205+
), f"Name of context class, {context_class} was not resolvable to a class"
206206
if not hasattr(context_class, "contexts"):
207207
context_class.contexts = threading.local()
208208

@@ -1589,7 +1589,7 @@ def check_start_vals(self, start):
15891589
raise SamplingError(
15901590
"Initial evaluation of model at starting point failed!\n"
15911591
f"Starting values:\n{elem}\n\n"
1592-
f"Initial evaluation results:\n{str(initial_eval)}"
1592+
f"Initial evaluation results:\n{initial_eval}"
15931593
)
15941594

15951595
def check_test_point(self, *args, **kwargs):

0 commit comments

Comments
 (0)