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

TestOwnerManagement::test_removing_self_redirects_home

First seen 1 month, 1 week ago in 0c23747
CI github-actions:test 13 runs
Average
123 ms
median 118 ms
max 188 ms
Phases
Setup 2 ms Call 120 ms Teardown 1 ms
Categories
Database 33 ms Test code 0.08 ms Other (Libraries, Unsampled, pytest, Deep copies, ...) 90 ms

27 database queries per run

Needs 229 KB of memory (max 1 MB)

Duration per run

Where the time goes

Latest run in ci:github-actions:test, 2 weeks ago · open run
Show pytest frames
setup4 ms5.5%
__init____init__:-14 ms5.5%
signature<stdlib>/inspect.py:33434 ms5.5%
Signature.from_callable<stdlib>/inspect.py:30584 ms5.5%
_signature_from_callable<stdlib>/inspect.py:25284 ms5.5%
_signature_from_function<stdlib>/inspect.py:24154 ms5.5%
Signature.__init__<stdlib>/inspect.py:30514 ms5.5%
call72 ms94.2%
TestOwnerManagement.test_removing_self_redirects_homestarter_packs/tests.py:648 response = self.client.post(reverse("remove_owner", args=[self.pack.slug, self.owner.id]))30 ms39.8%
Client.postdjango/test/client.py:116230 ms39.8%
RequestFactory.postdjango/test/client.py:49930 ms39.8%
RequestFactory.genericdjango/test/client.py:67130 ms39.8%
Client.requestdjango/test/client.py:109130 ms39.8%
ClientHandler.__call__django/test/client.py:17330 ms39.8%
BaseHandler.load_middlewaredjango/core/handlers/base.py:6330 ms39.8%
__init____init__:-130 ms39.8%
WhiteNoiseMiddleware.__init__whitenoise/middleware.py:10430 ms39.8%
WhiteNoise.add_fileswhitenoise/base.py:10828 ms36.2%
WhiteNoise.update_files_dictionarywhitenoise/base.py:11517 ms21.7%
scantreewhitenoise/base.py:27114 ms18.1%
scantreewhitenoise/base.py:2718 ms10.9%
scantreewhitenoise/base.py:2736 ms7.2%
scantreewhitenoise/base.py:2713 ms3.6%
scantreewhitenoise/base.py:2713 ms3.6%
scantreewhitenoise/base.py:2713 ms3.6%
scantreewhitenoise/base.py:2733 ms3.6%
scantreewhitenoise/base.py:2693 ms3.6%
scantreewhitenoise/base.py:2733 ms3.6%
scantreewhitenoise/base.py:2693 ms3.6%
WhiteNoise.update_files_dictionarywhitenoise/base.py:12011 ms14.5%
WhiteNoise.add_file_to_dictionarywhitenoise/base.py:13111 ms14.5%
WhiteNoise.get_static_filewhitenoise/base.py:2178 ms10.9%
StaticFile.__init__whitenoise/responders.py:736 ms7.2%
StaticFile.get_headerswhitenoise/responders.py:1673 ms3.6%
StaticFile.get_headerswhitenoise/responders.py:1763 ms3.6%
StaticFile.__init__whitenoise/responders.py:773 ms3.6%
StaticFile.get_alternativeswhitenoise/responders.py:2003 ms3.6%
WhiteNoise.get_static_filewhitenoise/base.py:2123 ms3.6%
WhiteNoise.add_cache_headerswhitenoise/base.py:2333 ms3.6%
WhiteNoise.add_fileswhitenoise/base.py:1073 ms3.6%
isdir<frozen genericpath>:523 ms3.6%
TestOwnerManagement.test_removing_self_redirects_homestarter_packs/tests.py:647 self.client.force_login(self.owner)19 ms25.3%
ClientMixin.force_logindjango/test/client.py:85819 ms25.3%
ClientMixin._logindjango/test/client.py:88911 ms14.5%
logindjango/contrib/auth/__init__.py:1898 ms10.9%
SessionBase.cycle_keydjango/contrib/sessions/backends/base.py:4376 ms7.2%
SessionStore.createdjango/contrib/sessions/backends/db.py:746 ms7.2%
SessionStore.savedjango/contrib/sessions/backends/db.py:1263 ms3.6%
Atomic.__enter__django/db/transaction.py:2233 ms3.6%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:263 ms3.6%
BaseDatabaseWrapper.savepointdjango/db/backends/base/base.py:4003 ms3.6%
BaseDatabaseWrapper._savepointdjango/db/backends/base/base.py:3673 ms3.6%
CursorWrapper.executedjango/db/backends/utils.py:793 ms3.6%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:923 ms3.6%
CursorWrapper._executedjango/db/backends/utils.py:1033 ms3.6%
Cursor.executepsycopg/cursor.py:1133 ms3.6%
Connection.waitpsycopg/connection.py:4953 ms3.6%
BaseCursor._execute_genpsycopg/_cursor_base.py:2063 ms3.6%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2863 ms3.6%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:783 ms3.6%
SessionStore.savedjango/contrib/sessions/backends/db.py:1273 ms3.6%
Model.savedjango/db/models/base.py:9043 ms3.6%
Model.save_basedjango/db/models/base.py:9963 ms3.6%
Model._save_tabledjango/db/models/base.py:11993 ms3.6%
Model._do_insertdjango/db/models/base.py:12513 ms3.6%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:873 ms3.6%
QuerySet._insertdjango/db/models/query.py:21413 ms3.6%
SQLInsertCompiler.execute_sqldjango/db/models/sql/compiler.py:19363 ms3.6%
CursorWrapper.executedjango/db/backends/utils.py:793 ms3.6%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:923 ms3.6%
CursorWrapper._executedjango/db/backends/utils.py:1053 ms3.6%
Cursor.executepsycopg/cursor.py:1133 ms3.6%
Connection.waitpsycopg/connection.py:4953 ms3.6%
SessionBase.cycle_keydjango/contrib/sessions/backends/base.py:4403 ms3.6%
SessionStore.deletedjango/contrib/sessions/backends/db.py:1753 ms3.6%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:873 ms3.6%
QuerySet.getdjango/db/models/query.py:7023 ms3.6%
QuerySet.__len__django/db/models/query.py:4213 ms3.6%
QuerySet._fetch_alldjango/db/models/query.py:22623 ms3.6%
ModelIterable.__iter__django/db/models/query.py:1033 ms3.6%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16253 ms3.6%
CursorWrapper.executedjango/db/backends/utils.py:793 ms3.6%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:923 ms3.6%
CursorWrapper._executedjango/db/backends/utils.py:1053 ms3.6%
Cursor.executepsycopg/cursor.py:1133 ms3.6%
Connection.waitpsycopg/connection.py:4953 ms3.6%
BaseCursor._execute_genpsycopg/_cursor_base.py:2063 ms3.6%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:3123 ms3.6%
logindjango/contrib/auth/__init__.py:1773 ms3.6%
SessionBase.__contains__django/contrib/sessions/backends/base.py:523 ms3.6%
SessionBase._get_sessiondjango/contrib/sessions/backends/base.py:2543 ms3.6%
SessionStore.loaddjango/contrib/sessions/backends/db.py:553 ms3.6%
SessionStore._get_session_from_dbdjango/contrib/sessions/backends/db.py:343 ms3.6%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:873 ms3.6%
QuerySet.getdjango/db/models/query.py:7023 ms3.6%
QuerySet.__len__django/db/models/query.py:4213 ms3.6%
QuerySet._fetch_alldjango/db/models/query.py:22623 ms3.6%
ModelIterable.__iter__django/db/models/query.py:1033 ms3.6%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16253 ms3.6%
CursorWrapper.executedjango/db/backends/utils.py:793 ms3.6%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:923 ms3.6%
CursorWrapper._executedjango/db/backends/utils.py:1053 ms3.6%
Cursor.executepsycopg/cursor.py:1133 ms3.6%
Connection.waitpsycopg/connection.py:4953 ms3.6%
BaseCursor._execute_genpsycopg/_cursor_base.py:2063 ms3.6%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2863 ms3.6%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:783 ms3.6%
ClientMixin._logindjango/test/client.py:8846 ms7.2%
ClientMixin.sessiondjango/test/client.py:8156 ms7.2%
SessionStore.savedjango/contrib/sessions/backends/db.py:1216 ms7.2%
SessionStore.createdjango/contrib/sessions/backends/db.py:703 ms3.6%
SessionBase._get_new_session_keydjango/contrib/sessions/backends/base.py:2013 ms3.6%
SessionStore.existsdjango/contrib/sessions/backends/db.py:633 ms3.6%
QuerySet.existsdjango/db/models/query.py:14583 ms3.6%
Query.has_resultsdjango/db/models/sql/query.py:6873 ms3.6%
SQLCompiler.has_resultsdjango/db/models/sql/compiler.py:15933 ms3.6%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16253 ms3.6%
CursorWrapper.executedjango/db/backends/utils.py:793 ms3.6%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:923 ms3.6%
CursorWrapper._executedjango/db/backends/utils.py:1053 ms3.6%
Cursor.executepsycopg/cursor.py:1133 ms3.6%
Connection.waitpsycopg/connection.py:4953 ms3.6%
SessionStore.createdjango/contrib/sessions/backends/db.py:743 ms3.6%
SessionStore.savedjango/contrib/sessions/backends/db.py:1273 ms3.6%
Model.savedjango/db/models/base.py:9043 ms3.6%
Model.save_basedjango/db/models/base.py:9963 ms3.6%
Model._save_tabledjango/db/models/base.py:11993 ms3.6%
Model._do_insertdjango/db/models/base.py:12513 ms3.6%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:873 ms3.6%
QuerySet._insertdjango/db/models/query.py:21413 ms3.6%
SQLInsertCompiler.execute_sqldjango/db/models/sql/compiler.py:19363 ms3.6%
CursorWrapper.executedjango/db/backends/utils.py:793 ms3.6%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:923 ms3.6%
CursorWrapper._executedjango/db/backends/utils.py:1053 ms3.6%
Cursor.executepsycopg/cursor.py:1133 ms3.6%
Connection.waitpsycopg/connection.py:4953 ms3.6%
BaseCursor._execute_genpsycopg/_cursor_base.py:2063 ms3.6%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2863 ms3.6%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:783 ms3.6%
ClientMixin._logindjango/test/client.py:8913 ms3.6%
SessionStore.savedjango/contrib/sessions/backends/db.py:1233 ms3.6%
SessionStore.create_model_instancedjango/contrib/sessions/backends/db.py:1023 ms3.6%
SessionBase.encodedjango/contrib/sessions/backends/base.py:1293 ms3.6%
dumpsdjango/core/signing.py:1913 ms3.6%
Signer.sign_objectdjango/core/signing.py:2793 ms3.6%
TimestampSigner.signdjango/core/signing.py:3013 ms3.6%
Signer.signdjango/core/signing.py:2453 ms3.6%
Signer.signaturedjango/core/signing.py:2423 ms3.6%
base64_hmacdjango/core/signing.py:1143 ms3.6%
salted_hmacdjango/utils/crypto.py:613 ms3.6%
new<stdlib>/hmac.py:2373 ms3.6%
__init____init__:-13 ms3.6%
HMAC.__init__<stdlib>/hmac.py:1083 ms3.6%
HMAC.__init<stdlib>/hmac.py:1133 ms3.6%
HMAC._init_openssl_hmac<stdlib>/hmac.py:1263 ms3.6%
TestOwnerManagement.test_removing_self_redirects_homestarter_packs/tests.py:646 self.pack.owners.add(self.friend) # not the last owner, so removal is allowed19 ms25.3%
create_forward_many_to_many_manager.<locals>.ManyRelatedManager.adddjango/db/models/fields/related_descriptors.py:132419 ms25.3%
create_forward_many_to_many_manager.<locals>.ManyRelatedManager._add_basedjango/db/models/fields/related_descriptors.py:130119 ms25.3%
create_forward_many_to_many_manager.<locals>.ManyRelatedManager._add_itemsdjango/db/models/fields/related_descriptors.py:160319 ms25.3%
QuerySet.bulk_createdjango/db/models/query.py:90019 ms25.3%
QuerySet._batched_insertdjango/db/models/query.py:217919 ms25.3%
QuerySet._insertdjango/db/models/query.py:214119 ms25.3%
SQLInsertCompiler.execute_sqldjango/db/models/sql/compiler.py:193619 ms25.3%
CursorWrapper.executedjango/db/backends/utils.py:7919 ms25.3%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:9219 ms25.3%
CursorWrapper._executedjango/db/backends/utils.py:10519 ms25.3%
Cursor.executepsycopg/cursor.py:11319 ms25.3%
Connection.waitpsycopg/connection.py:49519 ms25.3%
TransactionTestCase._pre_setupdjango/test/testcases.py:1167 cls._fixture_setup()3 ms3.6%
TestCase._fixture_setupdjango/test/testcases.py:14813 ms3.6%
TestCase._enter_atomicsdjango/test/testcases.py:13993 ms3.6%
Atomic.__enter__django/db/transaction.py:2233 ms3.6%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:263 ms3.6%
BaseDatabaseWrapper.savepointdjango/db/backends/base/base.py:4003 ms3.6%
BaseDatabaseWrapper._savepointdjango/db/backends/base/base.py:3673 ms3.6%
CursorWrapper.executedjango/db/backends/utils.py:793 ms3.6%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:923 ms3.6%
CursorWrapper._executedjango/db/backends/utils.py:1033 ms3.6%
Cursor.executepsycopg/cursor.py:1133 ms3.6%
Connection.waitpsycopg/connection.py:4953 ms3.6%
Estimated from 32 samples; phase durations are exact. Frames from pytest and pluggy are hidden .

Hot lines in your code

starter_packs/tests.py:648
response = self.client.post(reverse("remove_owner", args=[self.pack.slug, self.owner.id]))
TestOwnerManagement.test_removing_self_redirects_home · Libraries
30 ms
starter_packs/tests.py:646
self.pack.owners.add(self.friend) # not the last owner, so removal is allowed
TestOwnerManagement.test_removing_self_redirects_home · Database
19 ms
starter_packs/tests.py:647
self.client.force_login(self.owner)
TestOwnerManagement.test_removing_self_redirects_home · Database
19 ms

Fixtures

Exact setup time
_django_db_marker function 0.06 ms
_dj_autoclear_mailbox function 0.05 ms
_template_string_if_invalid_marker function 0.04 ms
_django_isolate_apps function 0.04 ms
_live_server_helper function 0.03 ms
_django_set_urlconf function 0.03 ms
_django_clear_site_cache function 0.03 ms
monkeypatch function 0.02 ms

Database

27 queries · 16 ms
No repeated queries.

Biggest pieces of work

call test body
starter_packs/tests.py:646
69 ms
setup __init__
__init__:-1
4 ms
call _pre_setup
django/test/testcases.py:1167
3 ms

Reliability

14 results · 0 CI failures · 0 local failures

This test hasn't failed recently.

History

Latest 14 results, oldest first in the strip
When Environment Outcome Duration Commit
2 weeks ago CI github-actions:test passed 76 ms 28600ed main Profile
2 weeks, 5 days ago CI github-actions:test passed 122 ms 600b717 main Profile
2 weeks, 6 days ago CI github-actions:test passed 169 ms c28a326 main Profile
3 weeks ago CI github-actions:test passed 68 ms 9b8826a main Profile
3 weeks ago CI github-actions:test passed 91 ms 4f01055 main Profile
1 month ago CI github-actions:test passed 106 ms 8ab642e main Profile
1 month ago CI github-actions:test passed 115 ms 9b75244 main Profile
1 month ago CI github-actions:test passed 124 ms 9603516 main Profile
1 month, 1 week ago CI github-actions:test passed 118 ms 615a272 main Profile
1 month, 1 week ago CI github-actions:test passed 102 ms d923a46 main Profile
1 month, 1 week ago CI github-actions:test passed 188 ms 82997f8 main Profile
1 month, 1 week ago CI github-actions:test passed 178 ms 623aa3e main Profile
1 month, 1 week ago CI github-actions:test passed 140 ms ab6465a main Profile
1 month, 1 week ago CI github-actions:test passed 79 ms 0c23747 main Run