Skip to content

Commit

Permalink
Made a small change
Browse files Browse the repository at this point in the history
  • Loading branch information
Sharpz7 committed Mar 4, 2024
1 parent 7b2b0c3 commit 15efd86
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
8 changes: 5 additions & 3 deletions afterthought/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,14 @@
import debugpy


def debug(error, port=5678):
def debug(error=None, port=5678):
print(f"Waiting for debugger to attach on {port}\n")
debugpy.listen(5678)
debugpy.wait_for_client()
traceback.print_exc()
raise error

if error is not None:
traceback.print_exc()
raise error


def debug_on_exception(*exceptions):
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "afterthought"
version = "0.4.0"
version = "0.5.0"
description = ""
authors = ["Sharpz7 <[email protected]>"]
readme = "README.md"
Expand Down

0 comments on commit 15efd86

Please sign in to comment.