Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Test more integrations on 3.13 #3578

Merged
merged 11 commits into from
Sep 27, 2024
Merged

Test more integrations on 3.13 #3578

merged 11 commits into from
Sep 27, 2024

Conversation

sentrivana
Copy link
Contributor

@sentrivana sentrivana commented Sep 27, 2024

Test integrations on Python 3.13 as long as the framework/library supports it.

Follow up: #3582

Copy link

codecov bot commented Sep 27, 2024

❌ 10 Tests Failed:

Tests completed Failed Passed Skipped
10594 10 10584 1453
View the top 3 failed tests by shortest run time
 tests.integrations.pyramid.test_pyramid
Stack Traces | 0s run time
No failure message available
tests.integrations.dramatiq.test_dramatiq test_that_expected_exceptions_are_not_captured
Stack Traces | 0.274s run time
.../integrations/dramatiq/test_dramatiq.py:217: in test_that_expected_exceptions_are_not_captured
    assert events == []
E   assert [{'level': 'error', 'exception': {'values': [{'mechanism': {'type': 'logging', 'handled': True}, 'module': None, 'type': 'TypeError', 'value': "'_thread._ThreadHandle' object is not callable", 'stacktrace': {'frames': [{'filename': 'dramatiq/middleware/time_limit.py', 'abs_path': '.../sentry-python/sentry-python/.tox/py3.13-dramatiq-latest/lib/python3.13.../dramatiq/middleware/time_limit.py', 'function': 'run', 'module': 'dramatiq.middleware.time_limit', 'lineno': 113, 'pre_context': ['            raise_thread_exception(thread_id, TimeLimitExceeded)', '', '    def run(self):', '        while True:', '            try:'], 'context_line': '                self._handle()', 'post_context': ['            except Exception:  # pragma: no cover', '                self.logger.exception("Unhandled error while running the time limit handler.")', '', '            sleep(self.interval)', ''], 'vars': {'self': '<_CtypesTimeoutManager(Thread-33, started daemon 140639912064768)>'}, 'in_app': False}]}}]}, 'logger': 'dramatiq.middleware.time_limit.TimeLimit', 'logentry': {'message': 'Unhandled error while running the time limit handler.', 'params': []}, 'extra': {'sys.argv': ['.../sentry-python/sentry-python/.tox/py3.13-dramatiq-latest/lib/python3.13....../site-packages/pytest/__main__.py', 'tests/integrations/dramatiq', '-o', 'junit_suite_name=py3.13-dramatiq-latest']}, 'event_id': '6d0cb7ea9a2c4a5c84cdac39d691ecc6', 'timestamp': '2024-09-27T11:24:09.813808Z', 'contexts': {'trace': {'trace_id': '8c08d171d550474890c01fe5e0fce48b', 'span_id': 'b7a2562b84afa6d3', 'parent_span_id': None}, 'runtime': {'name': 'CPython', 'version': '3.13.0', 'build': '3.13.0rc2 (main, Sep  9 2024, 03:11:15) [GCC 9.4.0]'}}, 'transaction_info': {}, 'breadcrumbs': {'values': []}, 'modules': {'sentry-sdk': '2.14.0', 'charset-normalizer': '3.3.2', 'pip': '24.0', 'pyyaml': '6.0.2', 'prometheus_client': '0.21.0', 'setuptools': '75.1.0', 'asttokens': '2.4.1', 'pysocks': '1.7.1', 'executing': '2.1.0', 'jsonschema-specifications': '2023.12.1', 'urllib3': '2.2.3', 'idna': '3.10', 'pytest-cov': '5.0.0', 'rpds-py': '0.20.0', 'dramatiq': '1.17.0', 'docopt': '0.6.2', 'py': '1.11.0', 'pytest': '8.3.3', 'pyrsistent': '0.20.0', 'iniconfig': '2.0.0', 'pytest-forked': '1.6.0', 'watchdog': '5.0.2', 'pluggy': '1.5.0', 'pytest-localserver': '0.9.0', 'referencing': '0.35.1', 'responses': '0.25.3', 'coverage': '7.6.1', 'markupsafe': '2.1.5', 'pytest-watch': '4.2.0', 'attrs': '24.2.0', 'requests': '2.32.3', 'werkzeug': '3.0.4', 'certifi': '2024.8.30', 'jsonschema': '4.23.0', 'six': '1.16.0', 'packaging': '24.1', 'colorama': '0.4.6'}, 'release': 'fb120dddad2bc3b4a72b451225326420e7103e67', 'environment': 'production', 'server_name': 'fv-az1116-770', 'sdk': {'name': 'sentry.python', 'version': '2.14.0', 'packages': [{'name': 'pypi:sentry-sdk', 'version': '2.14.0'}], 'integrations': ['argv', 'atexit', 'dedupe', 'dramatiq', 'excepthook', 'logging', 'modules', 'stdlib', 'threading']}, 'platform': 'python'}] == []
E     
E     Left contains one more item: {'breadcrumbs': {'values': []}, 'contexts': {'runtime': {'build': '3.13.0rc2 (main, Sep  9 2024, 03:11:15) [GCC 9.4.0]...'8c08d171d550474890c01fe5e0fce48b'}}, 'environment': 'production', 'event_id': '6d0cb7ea9a2c4a5c84cdac39d691ecc6', ...}
E     
E     Full diff:
E     - []
E     + [
E     +     {
E     +         'breadcrumbs': {
E     +             'values': [],
E     +         },
E     +         'contexts': {
E     +             'runtime': {
E     +                 'build': '3.13.0rc2 (main, Sep  9 2024, 03:11:15) [GCC 9.4.0]',
E     +                 'name': 'CPython',
E     +                 'version': '3.13.0',
E     +             },
E     +             'trace': {
E     +                 'parent_span_id': None,
E     +                 'span_id': 'b7a2562b84afa6d3',
E     +                 'trace_id': '8c08d171d550474890c01fe5e0fce48b',
E     +             },
E     +         },
E     +         'environment': 'production',
E     +         'event_id': '6d0cb7ea9a2c4a5c84cdac39d691ecc6',
E     +         'exception': {
E     +             'values': [
E     +                 {
E     +                     'mechanism': {
E     +                         'handled': True,
E     +                         'type': 'logging',
E     +                     },
E     +                     'module': None,
E     +                     'stacktrace': {
E     +                         'frames': [
E     +                             {
E     +                                 'abs_path': '.../sentry-python/sentry-python/.tox/py3.13-dramatiq-latest/lib/python3.13.../dramatiq/middleware/time_limit.py',
E     +                                 'context_line': '                self._handle()',
E     +                                 'filename': 'dramatiq/middleware/time_limit.py',
E     +                                 'function': 'run',
E     +                                 'in_app': False,
E     +                                 'lineno': 113,
E     +                                 'module': 'dramatiq.middleware.time_limit',
E     +                                 'post_context': [
E     +                                     '            except Exception:  # pragma: '
E     +                                     'no cover',
E     +                                     '                '
E     +                                     'self.logger.exception("Unhandled error '
E     +                                     'while running the time limit handler.")',
E     +                                     '',
E     +                                     '            sleep(self.interval)',
E     +                                     '',
E     +                                 ],
E     +                                 'pre_context': [
E     +                                     '            '
E     +                                     'raise_thread_exception(thread_id, '
E     +                                     'TimeLimitExceeded)',
E     +                                     '',
E     +                                     '    def run(self):',
E     +                                     '        while True:',
E     +                                     '            try:',
E     +                                 ],
E     +                                 'vars': {
E     +                                     'self': '<_CtypesTimeoutManager(Thread-33, started '
E     +                                     'daemon 140639912064768)>',
E     +                                 },
E     +                             },
E     +                         ],
E     +                     },
E     +                     'type': 'TypeError',
E     +                     'value': "'_thread._ThreadHandle' object is not callable",
E     +                 },
E     +             ],
E     +         },
E     +         'extra': {
E     +             'sys.argv': [
E     +                 '.../sentry-python/sentry-python/.tox/py3.13-dramatiq-latest/lib/python3.13....../site-packages/pytest/__main__.py',
E     +                 'tests/integrations/dramatiq',
E     +                 '-o',
E     +                 'junit_suite_name=py3.13-dramatiq-latest',
E     +             ],
E     +         },
E     +         'level': 'error',
E     +         'logentry': {
E     +             'message': 'Unhandled error while running the time limit handler.',
E     +             'params': [],
E     +         },
E     +         'logger': 'dramatiq.middleware.time_limit.TimeLimit',
E     +         'modules': {
E     +             'asttokens': '2.4.1',
E     +             'attrs': '24.2.0',
E     +             'certifi': '2024.8.30',
E     +             'charset-normalizer': '3.3.2',
E     +             'colorama': '0.4.6',
E     +             'coverage': '7.6.1',
E     +             'docopt': '0.6.2',
E     +             'dramatiq': '1.17.0',
E     +             'executing': '2.1.0',
E     +             'idna': '3.10',
E     +             'iniconfig': '2.0.0',
E     +             'jsonschema': '4.23.0',
E     +             'jsonschema-specifications': '2023.12.1',
E     +             'markupsafe': '2.1.5',
E     +             'packaging': '24.1',
E     +             'pip': '24.0',
E     +             'pluggy': '1.5.0',
E     +             'prometheus_client': '0.21.0',
E     +             'py': '1.11.0',
E     +             'pyrsistent': '0.20.0',
E     +             'pysocks': '1.7.1',
E     +             'pytest': '8.3.3',
E     +             'pytest-cov': '5.0.0',
E     +             'pytest-forked': '1.6.0',
E     +             'pytest-localserver': '0.9.0',
E     +             'pytest-watch': '4.2.0',
E     +             'pyyaml': '6.0.2',
E     +             'referencing': '0.35.1',
E     +             'requests': '2.32.3',
E     +             'responses': '0.25.3',
E     +             'rpds-py': '0.20.0',
E     +             'sentry-sdk': '2.14.0',
E     +             'setuptools': '75.1.0',
E     +             'six': '1.16.0',
E     +             'urllib3': '2.2.3',
E     +             'watchdog': '5.0.2',
E     +             'werkzeug': '3.0.4',
E     +         },
E     +         'platform': 'python',
E     +         'release': 'fb120dddad2bc3b4a72b451225326420e7103e67',
E     +         'sdk': {
E     +             'integrations': [
E     +                 'argv',
E     +                 'atexit',
E     +                 'dedupe',
E     +                 'dramatiq',
E     +                 'excepthook',
E     +                 'logging',
E     +                 'modules',
E     +                 'stdlib',
E     +                 'threading',
E     +             ],
E     +             'name': 'sentry.python',
E     +             'packages': [
E     +                 {
E     +                     'name': 'pypi:sentry-sdk',
E     +                     'version': '2.14.0',
E     +                 },
E     +             ],
E     +             'version': '2.14.0',
E     +         },
E     +         'server_name': 'fv-az1116-770',
E     +         'timestamp': '2024-09-27T11:24:09.813808Z',
E     +         'transaction_info': {},
E     +     },
E     + ]
tests.integrations.dramatiq.test_dramatiq test_that_local_variables_are_captured
Stack Traces | 0.274s run time
.../integrations/dramatiq/test_dramatiq.py:98: in test_that_local_variables_are_captured
    (event,) = events
E   ValueError: too many values to unpack (expected 1)

To view individual test run time comparison to the main branch, go to the Test Analytics Dashboard

@sentrivana sentrivana marked this pull request as ready for review September 27, 2024 12:22
@sentrivana sentrivana enabled auto-merge (squash) September 27, 2024 12:28
Copy link
Member

@szokeasaurusrex szokeasaurusrex left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💯

@sentrivana sentrivana merged commit 205591e into master Sep 27, 2024
139 checks passed
@sentrivana sentrivana deleted the ivana/add-more-3.13-tests branch September 27, 2024 12:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants