Skip to content

Commit

Permalink
[pre-commit.ci] auto fixes from pre-commit.com hooks
Browse files Browse the repository at this point in the history
for more information, see https://pre-commit.ci
  • Loading branch information
pre-commit-ci[bot] committed Apr 7, 2024
1 parent 8e48a29 commit b7237b8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
4 changes: 3 additions & 1 deletion mesa/time.py
Original file line number Diff line number Diff line change
Expand Up @@ -403,4 +403,6 @@ def __init__(self, model: Model, time_step: TimeT = 1) -> None:
"""
super().__init__(model)
raise Exception("DiscreteEventScheduler is deprecated in favor of the functionality provided by experimental.devs")
raise Exception(
"DiscreteEventScheduler is deprecated in favor of the functionality provided by experimental.devs"
)
1 change: 1 addition & 0 deletions tests/test_devs.py
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ def test_simulation_event():
# check if we pass over deletion of callable silently because of weakrefs
def some_test_function(x, y):
return x + y

event = SimulationEvent(time, some_test_function, priority=Priority.DEFAULT)
del some_test_function
event.execute()
Expand Down

0 comments on commit b7237b8

Please sign in to comment.