mirror of
https://github.com/httprunner/httprunner.git
synced 2026-05-20 23:59:49 +08:00
fix #819: maximum recursion error in locusts, caused by sentry sdk
This commit is contained in:
@@ -7,15 +7,28 @@ import itertools
|
||||
import json
|
||||
import os.path
|
||||
import re
|
||||
import uuid
|
||||
from datetime import datetime
|
||||
|
||||
from httprunner import exceptions, logger
|
||||
import sentry_sdk
|
||||
|
||||
from httprunner import exceptions, logger, __version__
|
||||
from httprunner.compat import basestring, bytes, is_py2
|
||||
from httprunner.exceptions import ParamsError
|
||||
|
||||
absolute_http_url_regexp = re.compile(r"^https?://", re.I)
|
||||
|
||||
|
||||
def init_sentry_sdk():
|
||||
sentry_sdk.init(
|
||||
dsn="https://cc6dd86fbe9f4e7fbd95248cfcff114d@sentry.io/1862849",
|
||||
release="httprunner@{}".format(__version__)
|
||||
)
|
||||
|
||||
with sentry_sdk.configure_scope() as scope:
|
||||
scope.set_user({"id": uuid.getnode()})
|
||||
|
||||
|
||||
def set_os_environ(variables_mapping):
|
||||
""" set variables mapping to os.environ
|
||||
"""
|
||||
|
||||
Reference in New Issue
Block a user