Tests / starter_packs/tests.py
TestPinAccountInStarterPack::test_readding_account_swaps_pin_button_to_enabled_unpinned
First seen 13 hours ago in 0c23747
CI
github-actions:test
4 runs
Average
222 ms
median 228 ms
max 336 ms
max 336 ms
Phases
Setup 1 ms
Call 221 ms
Teardown 0.34 ms
Categories
Database 79 ms
Other (Libraries, Unsampled, Templates, pytest) 143 ms
50 database queries per run
Needs 109 KB of memory (max 360 KB)
Duration per run
Where the time goes
Latest run in ci:github-actions:test, 7 hours ago ·
open run
call95 ms98.9%
TestPinAccountInStarterPack.test_readding_account_swaps_pin_button_to_enabled_unpinnedstarter_packs/tests.py:1116 self.client.post(toggle_url) # remove: drops the pin along with the membership row55 ms56.7%
Client.postdjango/test/client.py:116255 ms56.7%
RequestFactory.postdjango/test/client.py:49955 ms56.7%
RequestFactory.genericdjango/test/client.py:67155 ms56.7%
Client.requestdjango/test/client.py:109155 ms56.7%
ClientHandler.__call__django/test/client.py:17335 ms36.6%
BaseHandler.load_middlewaredjango/core/handlers/base.py:6335 ms36.6%
WhiteNoiseMiddleware.__init__whitenoise/middleware.py:10435 ms36.6%
WhiteNoise.add_fileswhitenoise/base.py:10835 ms36.6%
WhiteNoise.update_files_dictionarywhitenoise/base.py:12025 ms25.6%
WhiteNoise.add_file_to_dictionarywhitenoise/base.py:13125 ms25.6%
WhiteNoise.get_static_filewhitenoise/base.py:21721 ms22.0%
StaticFile.__init__whitenoise/responders.py:7711 ms11.0%
StaticFile.get_alternativeswhitenoise/responders.py:2009 ms9.2%
__init____init__:-19 ms9.2%
Headers.__init__<stdlib>/wsgiref/headers.py:369 ms9.2%
<GC>~9 ms9.2%
StaticFile.get_alternativeswhitenoise/responders.py:2012 ms1.8%
StaticFile.__init__whitenoise/responders.py:724 ms3.7%
StaticFile.get_file_statswhitenoise/responders.py:1612 ms1.8%
StaticFile.__init__whitenoise/responders.py:732 ms1.8%
StaticFile.get_headerswhitenoise/responders.py:1762 ms1.8%
StaticFile.__init__whitenoise/responders.py:752 ms1.8%
Headers.__getitem__<stdlib>/wsgiref/headers.py:832 ms1.8%
StaticFile.__init__whitenoise/responders.py:762 ms1.8%
WhiteNoise.get_static_filewhitenoise/base.py:2124 ms3.7%
WhiteNoise.add_cache_headerswhitenoise/base.py:2332 ms1.8%
WhiteNoiseMiddleware.immutable_file_testwhitenoise/middleware.py:1762 ms1.8%
WhiteNoiseMiddleware.get_static_urlwhitenoise/middleware.py:1972 ms1.8%
URLMixin.urldebug_toolbar/panels/staticfiles.py:202 ms1.8%
WhiteNoise.update_files_dictionarywhitenoise/base.py:1159 ms9.2%
scantreewhitenoise/base.py:2719 ms9.2%
scantreewhitenoise/base.py:2719 ms9.2%
scantreewhitenoise/base.py:2735 ms5.5%
scantreewhitenoise/base.py:2714 ms3.7%
scantreewhitenoise/base.py:2714 ms3.7%
scantreewhitenoise/base.py:2714 ms3.7%
scantreewhitenoise/base.py:2692 ms1.8%
scantreewhitenoise/base.py:2732 ms1.8%
<GC>~2 ms1.8%
ClientHandler.__call__django/test/client.py:18619 ms20.1%
BaseHandler.get_responsedjango/core/handlers/base.py:14219 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
MiddlewareMixin.__call__django/utils/deprecation.py:38019 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
MiddlewareMixin.__call__django/utils/deprecation.py:38019 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
MiddlewareMixin.__call__django/utils/deprecation.py:38019 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
WhiteNoiseMiddleware.__call__whitenoise/middleware.py:12319 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
DebugToolbarMiddleware.__call__debug_toolbar/middleware.py:14519 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
MiddlewareMixin.__call__django/utils/deprecation.py:38019 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
MiddlewareMixin.__call__django/utils/deprecation.py:38019 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
MiddlewareMixin.__call__django/utils/deprecation.py:38019 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
MiddlewareMixin.__call__django/utils/deprecation.py:38019 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
MiddlewareMixin.__call__django/utils/deprecation.py:38019 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
MiddlewareMixin.__call__django/utils/deprecation.py:38019 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
MiddlewareMixin.__call__django/utils/deprecation.py:38019 ms20.1%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5619 ms20.1%
BaseHandler._get_responsedjango/core/handlers/base.py:19919 ms20.1%
user_passes_test.<locals>.decorator.<locals>._view_wrapperdjango/contrib/auth/decorators.py:6214 ms14.6%
toggle_account_to_starter_packstarter_packs/views.py:6607 ms7.3%
get_splash_image_signaturestarter_packs/splash_images.py:887 ms7.3%
get_splash_image_accountsstarter_packs/splash_images.py:77 return list(accounts)7 ms7.3%
QuerySet.__iter__django/db/models/query.py:4397 ms7.3%
QuerySet._fetch_alldjango/db/models/query.py:22627 ms7.3%
ModelIterable.__iter__django/db/models/query.py:1035 ms5.5%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16124 ms3.7%
SQLCompiler.as_sqldjango/db/models/sql/compiler.py:7684 ms3.7%
SQLCompiler.pre_sql_setupdjango/db/models/sql/compiler.py:892 ms1.8%
SQLCompiler.setup_querydjango/db/models/sql/compiler.py:782 ms1.8%
SQLCompiler.get_selectdjango/db/models/sql/compiler.py:3102 ms1.8%
SQLCompiler.get_related_selectionsdjango/db/models/sql/compiler.py:13232 ms1.8%
SQLCompiler.pre_sql_setupdjango/db/models/sql/compiler.py:902 ms1.8%
SQLCompiler.get_order_bydjango/db/models/sql/compiler.py:4912 ms1.8%
SQLCompiler._order_by_pairsdjango/db/models/sql/compiler.py:3612 ms1.8%
Expression.__hash__django/db/models/expressions.py:5622 ms1.8%
cached_property.__get__django/utils/functional.py:472 ms1.8%
Expression.identitydjango/db/models/expressions.py:5522 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
ModelIterable.__iter__django/db/models/query.py:1352 ms1.8%
SQLCompiler.results_iterdjango/db/models/sql/compiler.py:15782 ms1.8%
SQLCompiler.get_convertersdjango/db/models/sql/compiler.py:15272 ms1.8%
Col.get_db_convertersdjango/db/models/expressions.py:13832 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:620 account = get_object_or_404(Account, id=account_id)2 ms1.8%
get_object_or_404django/shortcuts.py:1002 ms1.8%
QuerySet.getdjango/db/models/query.py:7022 ms1.8%
QuerySet.__len__django/db/models/query.py:4212 ms1.8%
QuerySet._fetch_alldjango/db/models/query.py:22622 ms1.8%
ModelIterable.__iter__django/db/models/query.py:1032 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16122 ms1.8%
SQLCompiler.as_sqldjango/db/models/sql/compiler.py:7682 ms1.8%
SQLCompiler.pre_sql_setupdjango/db/models/sql/compiler.py:892 ms1.8%
SQLCompiler.setup_querydjango/db/models/sql/compiler.py:782 ms1.8%
SQLCompiler.get_selectdjango/db/models/sql/compiler.py:3322 ms1.8%
BaseExpression.select_formatdjango/db/models/expressions.py:4992 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:623 StarterPackAccount.objects.filter(2 ms1.8%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:872 ms1.8%
QuerySet.filterdjango/db/models/query.py:16762 ms1.8%
QuerySet._filter_or_excludedjango/db/models/query.py:16942 ms1.8%
QuerySet._filter_or_exclude_inplacedjango/db/models/query.py:17042 ms1.8%
Query.add_qdjango/db/models/sql/query.py:16812 ms1.8%
Query._add_qdjango/db/models/sql/query.py:17132 ms1.8%
Query.build_filterdjango/db/models/sql/query.py:15772 ms1.8%
Query.setup_joinsdjango/db/models/sql/query.py:20022 ms1.8%
Query.joindjango/db/models/sql/query.py:11502 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:657 ).count()2 ms1.8%
QuerySet.countdjango/db/models/query.py:6772 ms1.8%
Query.get_countdjango/db/models/sql/query.py:6572 ms1.8%
Query.get_aggregationdjango/db/models/sql/query.py:6392 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:674 "num_accounts": StarterPackAccount.objects.filter(starter_pack=starter_pack).count(),2 ms1.8%
QuerySet.countdjango/db/models/query.py:6772 ms1.8%
Query.get_countdjango/db/models/sql/query.py:6572 ms1.8%
Query.get_aggregationdjango/db/models/sql/query.py:6392 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
user_passes_test.<locals>.decorator.<locals>._view_wrapperdjango/contrib/auth/decorators.py:594 ms3.7%
login_required.<locals>.<lambda>django/contrib/auth/decorators.py:824 ms3.7%
new_method_proxy.<locals>.innerdjango/utils/functional.py:2514 ms3.7%
SimpleLazyObject._setupdjango/utils/functional.py:4044 ms3.7%
AuthenticationMiddleware.process_request.<locals>.<lambda>django/contrib/auth/middleware.py:394 ms3.7%
get_userdjango/contrib/auth/middleware.py:194 ms3.7%
get_userdjango/contrib/auth/__init__.py:2872 ms1.8%
_get_user_session_keydjango/contrib/auth/__init__.py:1112 ms1.8%
SessionBase.__getitem__django/contrib/sessions/backends/base.py:552 ms1.8%
SessionBase._get_sessiondjango/contrib/sessions/backends/base.py:2542 ms1.8%
SessionStore.loaddjango/contrib/sessions/backends/db.py:552 ms1.8%
SessionStore._get_session_from_dbdjango/contrib/sessions/backends/db.py:342 ms1.8%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:872 ms1.8%
QuerySet.getdjango/db/models/query.py:7022 ms1.8%
QuerySet.__len__django/db/models/query.py:4212 ms1.8%
QuerySet._fetch_alldjango/db/models/query.py:22622 ms1.8%
ModelIterable.__iter__django/db/models/query.py:1032 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
get_userdjango/contrib/auth/__init__.py:2942 ms1.8%
ModelBackend.get_userdjango/contrib/auth/backends.py:2372 ms1.8%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:872 ms1.8%
QuerySet.getdjango/db/models/query.py:7022 ms1.8%
QuerySet.__len__django/db/models/query.py:4212 ms1.8%
QuerySet._fetch_alldjango/db/models/query.py:22622 ms1.8%
ModelIterable.__iter__django/db/models/query.py:1032 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
Atomic.__enter__django/db/transaction.py:2232 ms1.8%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:262 ms1.8%
BaseDatabaseWrapper.savepointdjango/db/backends/base/base.py:4002 ms1.8%
BaseDatabaseWrapper._savepointdjango/db/backends/base/base.py:3662 ms1.8%
TestPinAccountInStarterPack.test_readding_account_swaps_pin_button_to_enabled_unpinnedstarter_packs/tests.py:1117 response = self.client.post(toggle_url) # re-add21 ms22.0%
Client.postdjango/test/client.py:116221 ms22.0%
RequestFactory.postdjango/test/client.py:49921 ms22.0%
RequestFactory.genericdjango/test/client.py:67121 ms22.0%
Client.requestdjango/test/client.py:109121 ms22.0%
ClientHandler.__call__django/test/client.py:18621 ms22.0%
BaseHandler.get_responsedjango/core/handlers/base.py:14221 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
MiddlewareMixin.__call__django/utils/deprecation.py:38021 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
MiddlewareMixin.__call__django/utils/deprecation.py:38021 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
MiddlewareMixin.__call__django/utils/deprecation.py:38021 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
WhiteNoiseMiddleware.__call__whitenoise/middleware.py:12321 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
DebugToolbarMiddleware.__call__debug_toolbar/middleware.py:14521 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
MiddlewareMixin.__call__django/utils/deprecation.py:38021 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
MiddlewareMixin.__call__django/utils/deprecation.py:38021 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
MiddlewareMixin.__call__django/utils/deprecation.py:38021 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
MiddlewareMixin.__call__django/utils/deprecation.py:38021 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
MiddlewareMixin.__call__django/utils/deprecation.py:38021 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
MiddlewareMixin.__call__django/utils/deprecation.py:38021 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
MiddlewareMixin.__call__django/utils/deprecation.py:38021 ms22.0%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5621 ms22.0%
BaseHandler._get_responsedjango/core/handlers/base.py:19921 ms22.0%
user_passes_test.<locals>.decorator.<locals>._view_wrapperdjango/contrib/auth/decorators.py:6219 ms20.1%
toggle_account_to_starter_packstarter_packs/views.py:6607 ms7.3%
get_splash_image_signaturestarter_packs/splash_images.py:887 ms7.3%
get_splash_image_accountsstarter_packs/splash_images.py:77 return list(accounts)7 ms7.3%
QuerySet.__iter__django/db/models/query.py:4397 ms7.3%
QuerySet._fetch_alldjango/db/models/query.py:22627 ms7.3%
ModelIterable.__iter__django/db/models/query.py:1037 ms7.3%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16255 ms5.5%
CursorWrapper.executedjango/db/backends/utils.py:795 ms5.5%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:925 ms5.5%
CursorWrapper._executedjango/db/backends/utils.py:1055 ms5.5%
Cursor.executepsycopg/cursor.py:1135 ms5.5%
Connection.waitpsycopg/connection.py:4955 ms5.5%
BaseCursor._execute_genpsycopg/_cursor_base.py:2065 ms5.5%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2865 ms5.5%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:785 ms5.5%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16122 ms1.8%
SQLCompiler.as_sqldjango/db/models/sql/compiler.py:7682 ms1.8%
SQLCompiler.pre_sql_setupdjango/db/models/sql/compiler.py:892 ms1.8%
SQLCompiler.setup_querydjango/db/models/sql/compiler.py:782 ms1.8%
SQLCompiler.get_selectdjango/db/models/sql/compiler.py:3102 ms1.8%
SQLCompiler.get_related_selectionsdjango/db/models/sql/compiler.py:13122 ms1.8%
SQLCompiler.get_default_columnsdjango/db/models/sql/compiler.py:10312 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:6182 ms1.8%
get_editable_packstarter_packs/views.py:60 return get_object_or_404(StarterPack, slug=slug, owners=request.user, **extra)2 ms1.8%
get_object_or_404django/shortcuts.py:1002 ms1.8%
QuerySet.getdjango/db/models/query.py:7022 ms1.8%
QuerySet.__len__django/db/models/query.py:4212 ms1.8%
QuerySet._fetch_alldjango/db/models/query.py:22622 ms1.8%
ModelIterable.__iter__django/db/models/query.py:1032 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:619 starter_pack = get_object_or_404(StarterPack.objects.select_for_update(), pk=editable.pk)2 ms1.8%
get_object_or_404django/shortcuts.py:1002 ms1.8%
QuerySet.getdjango/db/models/query.py:7022 ms1.8%
QuerySet.__len__django/db/models/query.py:4212 ms1.8%
QuerySet._fetch_alldjango/db/models/query.py:22622 ms1.8%
ModelIterable.__iter__django/db/models/query.py:1032 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:621 if StarterPackAccount.objects.filter(starter_pack=starter_pack, account_id=account_id).exists():2 ms1.8%
QuerySet.existsdjango/db/models/query.py:14582 ms1.8%
Query.has_resultsdjango/db/models/sql/query.py:6872 ms1.8%
SQLCompiler.has_resultsdjango/db/models/sql/compiler.py:15932 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:6392 ms1.8%
Account.can_add_to_starter_packaccounts/models.py:259 if self.instance_model and self.instance_model.private:2 ms1.8%
ForwardManyToOneDescriptor.__get__django/db/models/fields/related_descriptors.py:2662 ms1.8%
FetchOne.fetchdjango/db/models/fetch_modes.py:172 ms1.8%
ForwardManyToOneDescriptor.fetch_onedjango/db/models/fields/related_descriptors.py:2792 ms1.8%
ForwardManyToOneDescriptor.get_objectdjango/db/models/fields/related_descriptors.py:2312 ms1.8%
QuerySet.getdjango/db/models/query.py:7022 ms1.8%
QuerySet.__len__django/db/models/query.py:4212 ms1.8%
QuerySet._fetch_alldjango/db/models/query.py:22622 ms1.8%
ModelIterable.__iter__django/db/models/query.py:1032 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16122 ms1.8%
SQLCompiler.as_sqldjango/db/models/sql/compiler.py:7682 ms1.8%
SQLCompiler.pre_sql_setupdjango/db/models/sql/compiler.py:892 ms1.8%
SQLCompiler.setup_querydjango/db/models/sql/compiler.py:782 ms1.8%
SQLCompiler.get_selectdjango/db/models/sql/compiler.py:2732 ms1.8%
SQLCompiler.get_select.<locals>.<genexpr>django/db/models/sql/compiler.py:2782 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:649 StarterPackAccount.objects.create(2 ms1.8%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:872 ms1.8%
QuerySet.createdjango/db/models/query.py:7362 ms1.8%
Model.savedjango/db/models/base.py:9042 ms1.8%
Model.save_basedjango/db/models/base.py:9962 ms1.8%
Model._save_tabledjango/db/models/base.py:11992 ms1.8%
Model._do_insertdjango/db/models/base.py:12512 ms1.8%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:872 ms1.8%
QuerySet._insertdjango/db/models/query.py:21412 ms1.8%
SQLInsertCompiler.execute_sqldjango/db/models/sql/compiler.py:19362 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:657 ).count()2 ms1.8%
QuerySet.countdjango/db/models/query.py:6772 ms1.8%
Query.get_countdjango/db/models/sql/query.py:6572 ms1.8%
Query.get_aggregationdjango/db/models/sql/query.py:6392 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
toggle_account_to_starter_packstarter_packs/views.py:674 "num_accounts": StarterPackAccount.objects.filter(starter_pack=starter_pack).count(),2 ms1.8%
QuerySet.countdjango/db/models/query.py:6772 ms1.8%
Query.get_countdjango/db/models/sql/query.py:6572 ms1.8%
Query.get_aggregationdjango/db/models/sql/query.py:4912 ms1.8%
Expression.__hash__django/db/models/expressions.py:5622 ms1.8%
cached_property.__get__django/utils/functional.py:472 ms1.8%
user_passes_test.<locals>.decorator.<locals>._view_wrapperdjango/contrib/auth/decorators.py:592 ms1.8%
login_required.<locals>.<lambda>django/contrib/auth/decorators.py:822 ms1.8%
new_method_proxy.<locals>.innerdjango/utils/functional.py:2512 ms1.8%
SimpleLazyObject._setupdjango/utils/functional.py:4042 ms1.8%
AuthenticationMiddleware.process_request.<locals>.<lambda>django/contrib/auth/middleware.py:392 ms1.8%
get_userdjango/contrib/auth/middleware.py:192 ms1.8%
get_userdjango/contrib/auth/__init__.py:2942 ms1.8%
ModelBackend.get_userdjango/contrib/auth/backends.py:2372 ms1.8%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:872 ms1.8%
QuerySet.getdjango/db/models/query.py:7022 ms1.8%
QuerySet.__len__django/db/models/query.py:4212 ms1.8%
QuerySet._fetch_alldjango/db/models/query.py:22622 ms1.8%
ModelIterable.__iter__django/db/models/query.py:1032 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
TestPinAccountInStarterPack.test_readding_account_swaps_pin_button_to_enabled_unpinnedstarter_packs/tests.py:1112 self.client.force_login(self.owner)12 ms12.8%
ClientMixin.force_logindjango/test/client.py:85812 ms12.8%
ClientMixin._logindjango/test/client.py:8847 ms7.3%
ClientMixin.sessiondjango/test/client.py:8157 ms7.3%
SessionStore.savedjango/contrib/sessions/backends/db.py:1217 ms7.3%
SessionStore.createdjango/contrib/sessions/backends/db.py:705 ms5.5%
SessionBase._get_new_session_keydjango/contrib/sessions/backends/base.py:2015 ms5.5%
SessionStore.existsdjango/contrib/sessions/backends/db.py:635 ms5.5%
QuerySet.existsdjango/db/models/query.py:14585 ms5.5%
Query.has_resultsdjango/db/models/sql/query.py:6875 ms5.5%
SQLCompiler.has_resultsdjango/db/models/sql/compiler.py:15935 ms5.5%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16254 ms3.7%
CursorWrapper.executedjango/db/backends/utils.py:794 ms3.7%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:924 ms3.7%
CursorWrapper._executedjango/db/backends/utils.py:1054 ms3.7%
Cursor.executepsycopg/cursor.py:1134 ms3.7%
Connection.waitpsycopg/connection.py:4954 ms3.7%
BaseCursor._execute_genpsycopg/_cursor_base.py:2052 ms1.8%
BaseCursor._convert_querypsycopg/_cursor_base.py:4652 ms1.8%
PostgresClientQuery.convertpsycopg/_queries.py:2892 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16122 ms1.8%
SQLCompiler.as_sqldjango/db/models/sql/compiler.py:7682 ms1.8%
SQLCompiler.pre_sql_setupdjango/db/models/sql/compiler.py:892 ms1.8%
SQLCompiler.setup_querydjango/db/models/sql/compiler.py:782 ms1.8%
SQLCompiler.get_selectdjango/db/models/sql/compiler.py:2842 ms1.8%
Query.extra_selectdjango/db/models/sql/query.py:26882 ms1.8%
SessionStore.createdjango/contrib/sessions/backends/db.py:742 ms1.8%
SessionStore.savedjango/contrib/sessions/backends/db.py:1262 ms1.8%
Atomic.__enter__django/db/transaction.py:2232 ms1.8%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:262 ms1.8%
BaseDatabaseWrapper.savepointdjango/db/backends/base/base.py:4002 ms1.8%
BaseDatabaseWrapper._savepointdjango/db/backends/base/base.py:3672 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1032 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
ClientMixin._logindjango/test/client.py:8894 ms3.7%
logindjango/contrib/auth/__init__.py:1892 ms1.8%
SessionBase.cycle_keydjango/contrib/sessions/backends/base.py:4372 ms1.8%
SessionStore.createdjango/contrib/sessions/backends/db.py:742 ms1.8%
SessionStore.savedjango/contrib/sessions/backends/db.py:1272 ms1.8%
Model.savedjango/db/models/base.py:9042 ms1.8%
Model.save_basedjango/db/models/base.py:9962 ms1.8%
Model._save_tabledjango/db/models/base.py:11992 ms1.8%
Model._do_insertdjango/db/models/base.py:12512 ms1.8%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:872 ms1.8%
QuerySet._insertdjango/db/models/query.py:21412 ms1.8%
SQLInsertCompiler.execute_sqldjango/db/models/sql/compiler.py:19362 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
logindjango/contrib/auth/__init__.py:1982 ms1.8%
Signal.senddjango/dispatch/dispatcher.py:2492 ms1.8%
update_last_logindjango/contrib/auth/models.py:242 ms1.8%
AbstractBaseUser.savedjango/contrib/auth/base_user.py:622 ms1.8%
Model.savedjango/db/models/base.py:9042 ms1.8%
Model.save_basedjango/db/models/base.py:9962 ms1.8%
Model._save_tabledjango/db/models/base.py:11402 ms1.8%
Model._do_updatedjango/db/models/base.py:12442 ms1.8%
QuerySet._updatedjango/db/models/query.py:14482 ms1.8%
SQLUpdateCompiler.execute_returning_sqldjango/db/models/sql/compiler.py:21502 ms1.8%
SQLUpdateCompiler.execute_sqldjango/db/models/sql/compiler.py:21212 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
ClientMixin._logindjango/test/client.py:8912 ms1.8%
SessionStore.savedjango/contrib/sessions/backends/db.py:1272 ms1.8%
Model.savedjango/db/models/base.py:9042 ms1.8%
Model.save_basedjango/db/models/base.py:9962 ms1.8%
Model._save_tabledjango/db/models/base.py:11402 ms1.8%
Model._do_updatedjango/db/models/base.py:12442 ms1.8%
QuerySet._updatedjango/db/models/query.py:14482 ms1.8%
SQLUpdateCompiler.execute_returning_sqldjango/db/models/sql/compiler.py:21502 ms1.8%
SQLUpdateCompiler.execute_sqldjango/db/models/sql/compiler.py:21212 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
TestPinAccountInStarterPack.test_readding_account_swaps_pin_button_to_enabled_unpinnedstarter_packs/tests.py:1122 self.assertFalse(StarterPackAccount.objects.get(starter_pack=self.starter_pack, account=self.niche).pinned)4 ms3.7%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:874 ms3.7%
QuerySet.getdjango/db/models/query.py:7024 ms3.7%
QuerySet.__len__django/db/models/query.py:4214 ms3.7%
QuerySet._fetch_alldjango/db/models/query.py:22624 ms3.7%
ModelIterable.__iter__django/db/models/query.py:1032 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16232 ms1.8%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:262 ms1.8%
BaseDatabaseWrapper.cursordjango/db/backends/base/base.py:3202 ms1.8%
BaseDatabaseWrapper._cursordjango/db/backends/base/base.py:2982 ms1.8%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:262 ms1.8%
DatabaseWrapper.create_cursordjango/db/backends/postgresql/base.py:4422 ms1.8%
Connection.cursorpsycopg/connection.py:2592 ms1.8%
ModelIterable.__iter__django/db/models/query.py:1352 ms1.8%
TestPinAccountInStarterPack.test_readding_account_swaps_pin_button_to_enabled_unpinnedstarter_packs/tests.py:1113 StarterPackAccount.objects.filter(starter_pack=self.starter_pack, account=self.niche).update(pinned=True)2 ms1.8%
QuerySet.updatedjango/db/models/query.py:14212 ms1.8%
SQLUpdateCompiler.execute_sqldjango/db/models/sql/compiler.py:21212 ms1.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
TransactionTestCase._post_teardowndjango/test/testcases.py:1243 self._fixture_teardown()2 ms1.8%
TestCase._fixture_teardowndjango/test/testcases.py:14982 ms1.8%
DatabaseWrapper.check_constraintsdjango/db/backends/postgresql/base.py:4952 ms1.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms1.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms1.8%
CursorWrapper._executedjango/db/backends/utils.py:1032 ms1.8%
Cursor.executepsycopg/cursor.py:1132 ms1.8%
Connection.waitpsycopg/connection.py:4952 ms1.8%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms1.8%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms1.8%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms1.8%
Estimated from 54 samples; phase durations are exact. Frames from pytest and pluggy are
hidden
.
Hot lines in your code
|
starter_packs/tests.py:1116
self.client.post(toggle_url) # remove: drops the pin along with the membership row
TestPinAccountInStarterPack.test_readding_account_swaps_pin_button_to_enabled_unpinned
· Libraries
|
41 ms |
|
starter_packs/splash_images.py:77
return list(accounts)
get_splash_image_accounts
· Database
|
14 ms |
|
starter_packs/tests.py:1112
self.client.force_login(self.owner)
TestPinAccountInStarterPack.test_readding_account_swaps_pin_button_to_enabled_unpinned
· Database
|
12 ms |
|
starter_packs/views.py:657
).count()
toggle_account_to_starter_pack
· Database
|
4 ms |
|
starter_packs/views.py:674
"num_accounts": StarterPackAccount.objects.filter(starter_pack=starter_pack).count(),
toggle_account_to_starter_pack
· Database
|
4 ms |
|
starter_packs/tests.py:1122
self.assertFalse(StarterPackAccount.objects.get(starter_pack=self.starter_pack, account=self.niche).pinned)
TestPinAccountInStarterPack.test_readding_account_swaps_pin_button_to_enabled_unpinned
· Database
|
4 ms |
|
starter_packs/tests.py:1113
StarterPackAccount.objects.filter(starter_pack=self.starter_pack, account=self.niche).update(pinned=True)
TestPinAccountInStarterPack.test_readding_account_swaps_pin_button_to_enabled_unpinned
· Database
|
2 ms |
|
starter_packs/views.py:620
account = get_object_or_404(Account, id=account_id)
toggle_account_to_starter_pack
· Database
|
2 ms |
|
starter_packs/views.py:623
StarterPackAccount.objects.filter(
toggle_account_to_starter_pack
· Database
|
2 ms |
|
starter_packs/tests.py:1117
response = self.client.post(toggle_url) # re-add
TestPinAccountInStarterPack.test_readding_account_swaps_pin_button_to_enabled_unpinned
· Database
|
2 ms |
Fixtures
Exact setup time| _dj_autoclear_mailbox function | 0.05 ms |
| _template_string_if_invalid_marker function | 0.04 ms |
| _django_db_marker function | 0.04 ms |
| monkeypatch function | 0.04 ms |
| _django_isolate_apps function | 0.03 ms |
| _live_server_helper function | 0.03 ms |
| _django_set_urlconf function | 0.03 ms |
| _django_clear_site_cache function | 0.03 ms |
Database
50 queries · 20 ms
Repeated queries are usually N+1 lookups: fetch them once with select_related / prefetch_related (or selectinload).
4×
SELECT "starter_packs_starterpack"."id", "starter_packs_starterpack"."title", "starter_packs_starterpack"."slug", "starter_packs_starterpack"."description", "starter_packs_starterpack"."languages", "starter_packs_starterpack"."created_by_id", "starter_packs_starterpack"."created_at", "starter_packs…
4×
SELECT "accounts_account"."id", "accounts_account"."account_id", "accounts_account"."instance", "accounts_account"."instance_model_id", "accounts_account"."username_at_instance", "accounts_account"."search", "accounts_account"."username", "accounts_account"."acct", "accounts_account"."display_name"…
3×
SELECT "django_session"."session_key", "django_session"."session_data", "django_session"."expire_date" FROM "django_session" WHERE ("django_session"."expire_date" > %s AND "django_session"."session_key" = %s) LIMIT ?
3×
SELECT COUNT(*) AS "__count" FROM "starter_packs_starterpackaccount" WHERE "starter_packs_starterpackaccount"."starter_pack_id" = %s
Biggest pieces of work
|
call test body
starter_packs/tests.py:1116
|
93 ms |
|
call _post_teardown
django/test/testcases.py:1243
|
2 ms |
Reliability
5 results · 0 CI failures · 0 local failuresThis test hasn't failed recently.
History
Latest 5 results, oldest first in the strip| When | Environment | Outcome | Duration | |
|---|---|---|---|---|
| 7 hours ago | CI github-actions:test | passed | 96 ms | Profile |
| 8 hours ago | CI github-actions:test | passed | 280 ms | Profile |
| 8 hours ago | CI github-actions:test | passed | 176 ms | Profile |
| 13 hours ago | CI github-actions:test | passed | 336 ms | Profile |
| 13 hours ago | CI github-actions:test | passed | 103 ms | Run |