flakytest.dev anze3db fedidevs
Tests / mastodon_auth/tests.py

MastodonLoginViewTests::test_create_app_failure_without_existing_credentials_errors

First seen 4 months, 2 weeks ago in 553d048
CI github-actions:test 11 runs
Average
125 ms
median 102 ms
max 235 ms
Phases
Setup 15 ms Call 110 ms Teardown 0.62 ms
Categories
Database 34 ms Other (Mocking, pytest, Unsampled, Libraries, ...) 92 ms

7 database queries per run

Needs 8 KB of memory (max 64 KB)

Duration per run

Where the time goes

Latest run in ci:github-actions:test, 7 hours ago · open run
Show pytest frames
setup15 ms12.8%
TestCase.setUpClassdjango/test/testcases.py:1426 cls.cls_atomics = cls._enter_atomics()15 ms12.8%
TestCase._enter_atomicsdjango/test/testcases.py:139915 ms12.8%
Atomic.__enter__django/db/transaction.py:21015 ms12.8%
BaseDatabaseWrapper.get_autocommitdjango/db/backends/base/base.py:45415 ms12.8%
SimpleTestCase.ensure_connection_patch_method.<locals>.patched_ensure_connectiondjango/test/testcases.py:30415 ms12.8%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:2615 ms12.8%
BaseDatabaseWrapper.ensure_connectiondjango/db/backends/base/base.py:27915 ms12.8%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:2615 ms12.8%
BaseDatabaseWrapper.connectdjango/db/backends/base/base.py:25615 ms12.8%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:2615 ms12.8%
DatabaseWrapper.get_new_connectiondjango/db/backends/postgresql/base.py:34515 ms12.8%
Connection.connectpsycopg/connection.py:10915 ms12.8%
wait_connpsycopg/waiting.py:1419 ms7.8%
EpollSelector.select<stdlib>/selectors.py:4529 ms7.8%
wait_connpsycopg/waiting.py:1456 ms5.0%
BaseConnection._connect_genpsycopg/_connection_base.py:4396 ms5.0%
call105 ms87.0%
MastodonLoginViewTests.test_create_app_failure_without_existing_credentials_errorsmastodon_auth/tests.py:195 response = self.client.post("/mastodon_login/", {"instance": "det.social"})99 ms81.4%
Client.postdjango/test/client.py:116299 ms81.4%
RequestFactory.postdjango/test/client.py:49999 ms81.4%
RequestFactory.genericdjango/test/client.py:67199 ms81.4%
Client.requestdjango/test/client.py:109199 ms81.4%
ClientHandler.__call__django/test/client.py:17399 ms81.4%
BaseHandler.load_middlewaredjango/core/handlers/base.py:6399 ms81.4%
WhiteNoiseMiddleware.__init__whitenoise/middleware.py:10499 ms81.4%
WhiteNoise.add_fileswhitenoise/base.py:10899 ms81.4%
WhiteNoise.update_files_dictionarywhitenoise/base.py:12082 ms67.6%
WhiteNoise.add_file_to_dictionarywhitenoise/base.py:13180 ms66.3%
WhiteNoise.get_static_filewhitenoise/base.py:21755 ms45.6%
StaticFile.__init__whitenoise/responders.py:7720 ms16.6%
StaticFile.get_alternativeswhitenoise/responders.py:2018 ms6.9%
Headers.__setitem__<stdlib>/wsgiref/headers.py:625 ms4.1%
Headers.__delitem__<stdlib>/wsgiref/headers.py:713 ms2.8%
Headers._convert_string_type<stdlib>/wsgiref/headers.py:502 ms1.4%
Headers.__delitem__<stdlib>/wsgiref/headers.py:722 ms1.4%
StaticFile.get_alternativeswhitenoise/responders.py:2003 ms2.8%
__init____init__:-12 ms1.4%
Headers.__init__<stdlib>/wsgiref/headers.py:442 ms1.4%
Headers._convert_string_type<stdlib>/wsgiref/headers.py:502 ms1.4%
StaticFile.get_alternativeswhitenoise/responders.py:1983 ms2.8%
StaticFile.get_alternatives.<locals>.<lambda>whitenoise/responders.py:1982 ms1.4%
<GC>~2 ms1.4%
StaticFile.get_alternativeswhitenoise/responders.py:2032 ms1.4%
Headers.__setitem__<stdlib>/wsgiref/headers.py:622 ms1.4%
Headers.__delitem__<stdlib>/wsgiref/headers.py:712 ms1.4%
StaticFile.get_alternativeswhitenoise/responders.py:2072 ms1.4%
Headers.items<stdlib>/wsgiref/headers.py:1392 ms1.4%
StaticFile.get_alternativeswhitenoise/responders.py:2042 ms1.4%
compile<stdlib>/re/__init__.py:2912 ms1.4%
StaticFile.__init__whitenoise/responders.py:7312 ms9.7%
StaticFile.get_headerswhitenoise/responders.py:1787 ms5.5%
parsedate<stdlib>/email/_parseaddr.py:1855 ms4.1%
parsedate_tz<stdlib>/email/_parseaddr.py:505 ms4.1%
_parsedate_tz<stdlib>/email/_parseaddr.py:1012 ms1.4%
_parsedate_tz<stdlib>/email/_parseaddr.py:1052 ms1.4%
_parsedate_tz<stdlib>/email/_parseaddr.py:1412 ms1.4%
Headers.__getitem__<stdlib>/wsgiref/headers.py:832 ms1.4%
Headers.get<stdlib>/wsgiref/headers.py:1052 ms1.4%
StaticFile.get_headerswhitenoise/responders.py:1702 ms1.4%
StaticFile.get_headerswhitenoise/responders.py:1802 ms1.4%
StaticFile.get_headerswhitenoise/responders.py:1762 ms1.4%
formatdate<stdlib>/email/utils.py:2662 ms1.4%
StaticFile.__init__whitenoise/responders.py:768 ms6.9%
StaticFile.get_not_modified_responsewhitenoise/responders.py:1893 ms2.8%
Headers.__getitem__<stdlib>/wsgiref/headers.py:832 ms1.4%
Headers.get<stdlib>/wsgiref/headers.py:1062 ms1.4%
StaticFile.get_not_modified_responsewhitenoise/responders.py:1883 ms2.8%
Headers.__contains__<stdlib>/wsgiref/headers.py:872 ms1.4%
Headers.get<stdlib>/wsgiref/headers.py:1062 ms1.4%
StaticFile.get_not_modified_responsewhitenoise/responders.py:1902 ms1.4%
StaticFile.__init__whitenoise/responders.py:745 ms4.1%
Headers.__getitem__<stdlib>/wsgiref/headers.py:833 ms2.8%
Headers.get<stdlib>/wsgiref/headers.py:1062 ms1.4%
parsedate<stdlib>/email/_parseaddr.py:1852 ms1.4%
StaticFile.__init__whitenoise/responders.py:725 ms4.1%
StaticFile.get_file_statswhitenoise/responders.py:1612 ms1.4%
StaticFile.get_file_statswhitenoise/responders.py:1632 ms1.4%
StaticFile.__init__whitenoise/responders.py:752 ms1.4%
Headers.__getitem__<stdlib>/wsgiref/headers.py:832 ms1.4%
Headers.get<stdlib>/wsgiref/headers.py:1062 ms1.4%
WhiteNoise.get_static_filewhitenoise/base.py:21222 ms17.9%
WhiteNoise.add_cache_headerswhitenoise/base.py:23320 ms16.6%
WhiteNoiseMiddleware.immutable_file_testwhitenoise/middleware.py:17620 ms16.6%
WhiteNoiseMiddleware.get_static_urlwhitenoise/middleware.py:19718 ms15.2%
URLMixin.urldebug_toolbar/panels/staticfiles.py:2013 ms11.0%
HashedFilesMixin.urldjango/contrib/staticfiles/storage.py:23510 ms8.3%
HashedFilesMixin._urldjango/contrib/staticfiles/storage.py:2043 ms2.8%
LazyObject.__getattribute__django/utils/functional.py:2832 ms1.4%
HashedFilesMixin._urldjango/contrib/staticfiles/storage.py:2163 ms2.8%
FileSystemStorage.urldjango/core/files/storage/filesystem.py:2072 ms1.4%
urljoin<stdlib>/urllib/parse.py:7652 ms1.4%
HashedFilesMixin._urldjango/contrib/staticfiles/storage.py:2142 ms1.4%
ManifestFilesMixin.stored_namedjango/contrib/staticfiles/storage.py:5952 ms1.4%
HashedFilesMixin._urldjango/contrib/staticfiles/storage.py:2082 ms1.4%
LazyObject.__getattribute__django/utils/functional.py:2803 ms2.8%
WhiteNoise.add_cache_headerswhitenoise/base.py:2342 ms1.4%
Headers.__setitem__<stdlib>/wsgiref/headers.py:622 ms1.4%
Headers.__delitem__<stdlib>/wsgiref/headers.py:722 ms1.4%
WhiteNoise.get_static_filewhitenoise/base.py:2113 ms2.8%
WhiteNoise.add_mime_headerswhitenoise/base.py:2303 ms2.8%
Headers.add_header<stdlib>/wsgiref/headers.py:1922 ms1.4%
Headers._convert_string_type<stdlib>/wsgiref/headers.py:492 ms1.4%
WhiteNoise.add_file_to_dictionarywhitenoise/base.py:1232 ms1.4%
WhiteNoise.update_files_dictionarywhitenoise/base.py:11517 ms13.8%
scantreewhitenoise/base.py:27312 ms9.7%
<GC>~10 ms8.3%
scantreewhitenoise/base.py:2715 ms4.1%
scantreewhitenoise/base.py:2715 ms4.1%
scantreewhitenoise/base.py:2713 ms2.8%
scantreewhitenoise/base.py:2713 ms2.8%
scantreewhitenoise/base.py:2713 ms2.8%
scantreewhitenoise/base.py:2692 ms1.4%
scantreewhitenoise/base.py:2732 ms1.4%
scantreewhitenoise/base.py:2692 ms1.4%
TransactionTestCase._pre_setupdjango/test/testcases.py:1167 cls._fixture_setup()5 ms4.1%
TestCase._fixture_setupdjango/test/testcases.py:14815 ms4.1%
TestCase._enter_atomicsdjango/test/testcases.py:13995 ms4.1%
Atomic.__enter__django/db/transaction.py:2235 ms4.1%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:265 ms4.1%
BaseDatabaseWrapper.savepointdjango/db/backends/base/base.py:4005 ms4.1%
BaseDatabaseWrapper._savepointdjango/db/backends/base/base.py:3675 ms4.1%
CursorWrapper.executedjango/db/backends/utils.py:795 ms4.1%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:925 ms4.1%
CursorWrapper._executedjango/db/backends/utils.py:1035 ms4.1%
Cursor.executepsycopg/cursor.py:1135 ms4.1%
Connection.waitpsycopg/connection.py:4955 ms4.1%
BaseCursor._execute_genpsycopg/_cursor_base.py:2042 ms1.4%
BaseCursor._start_querypsycopg/_cursor_base.py:3872 ms1.4%
BaseConnection._start_querypsycopg/_connection_base.py:5532 ms1.4%
BaseConnection._exec_commandpsycopg/_connection_base.py:4742 ms1.4%
MastodonLoginViewTests.test_create_app_failure_without_existing_credentials_errorsmastodon_auth/tests.py:193 http_get.return_value = MagicMock(status_code=200)2 ms1.4%
MagicMixin.__init__<stdlib>/unittest/mock.py:21862 ms1.4%
MagicMixin._mock_set_magics<stdlib>/unittest/mock.py:22092 ms1.4%
Estimated from 81 samples; phase durations are exact. Frames from pytest and pluggy are hidden .

Hot lines in your code

mastodon_auth/tests.py:195
response = self.client.post("/mastodon_login/", {"instance": "det.social"})
MastodonLoginViewTests.test_create_app_failure_without_existing_credentials_errors · Mocking
99 ms
mastodon_auth/tests.py:193
http_get.return_value = MagicMock(status_code=200)
MastodonLoginViewTests.test_create_app_failure_without_existing_credentials_errors · Mocking
2 ms

Fixtures

Exact setup time
_unittest_setUpClass_fixture_MastodonLoginViewTests class 14 ms
_django_setup_unittest class 0.38 ms
_django_db_marker function 0.09 ms
_template_string_if_invalid_marker function 0.06 ms
_django_isolate_apps function 0.05 ms
_django_set_urlconf function 0.05 ms
_dj_autoclear_mailbox function 0.05 ms
_live_server_helper function 0.05 ms
_django_clear_site_cache function 0.04 ms
monkeypatch function 0.03 ms

Database

7 queries · 10 ms
No repeated queries.

Biggest pieces of work

call test body
mastodon_auth/tests.py:195
100 ms
setup setUpClass
django/test/testcases.py:1426
15 ms
call _pre_setup
django/test/testcases.py:1167
5 ms

Reliability

12 results · 0 CI failures · 0 local failures

This test hasn't failed recently.

History

Latest 12 results, oldest first in the strip
When Environment Outcome Duration Commit
7 hours ago CI github-actions:test passed 121 ms c28a326 main Profile
16 hours ago CI github-actions:test passed 67 ms 9b8826a main Profile
22 hours ago CI github-actions:test passed 99 ms 4f01055 main Profile
1 week, 5 days ago CI github-actions:test passed 95 ms 8ab642e main Profile
2 weeks, 2 days ago CI github-actions:test passed 65 ms 9b75244 main Profile
2 weeks, 2 days ago CI github-actions:test passed 127 ms 9603516 main Profile
2 weeks, 4 days ago CI github-actions:test passed 102 ms 615a272 main Profile
3 weeks ago CI github-actions:test passed 70 ms d923a46 main Profile
3 weeks ago CI github-actions:test passed 201 ms 82997f8 main Profile
3 weeks ago CI github-actions:test passed 196 ms 623aa3e main Profile
3 weeks ago CI github-actions:test passed 235 ms ab6465a main Profile
3 weeks ago CI github-actions:test passed 84 ms 0c23747 main Run