Skip to content

Commit

Permalink
Add typing and docs reference
Browse files Browse the repository at this point in the history
  • Loading branch information
mejroslav committed Aug 22, 2023
1 parent b8508e3 commit 0b12f26
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
3 changes: 2 additions & 1 deletion asab/sentry/service.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
import re
import logging
import json
import typing

L = logging.getLogger(__name__)

Expand Down Expand Up @@ -172,7 +173,7 @@ def capture_message(self, message, level=None, scope=None, **scope_args):
"""
return sentry_sdk.capture_message(message=message, level=level, scope=scope, **scope_args)

def set_tag(self, key: str, value) -> None:
def set_tag(self, key: str, value: typing.Union[str, int]) -> None:
"""
Add custom tag to the current scope.
Expand Down
5 changes: 5 additions & 0 deletions docs/reference/sentry/reference.md
Original file line number Diff line number Diff line change
Expand Up @@ -107,3 +107,8 @@ with sentry_svc.transaction("speed test", "multiple tasks"):
task2()
finalize()
```


## Reference

::: asab.sentry.SentryService

0 comments on commit 0b12f26

Please sign in to comment.