Tests / starter_packs/tests.py
TestShareStarterPack::test_api_plain_json
Regression caught
First seen 1 year, 2 months ago in 1e2abb0
CI
github-actions:test
4 runs
Average
220 ms
median 232 ms
max 362 ms
1 failed
max 362 ms
1 failed
Phases
Setup 69 ms
Call 150 ms
Teardown 0.35 ms
Categories
Database 83 ms
Factories 18 ms
App code 1 ms
Test code 1 ms
Other (Libraries, Deep copies, pytest, Imports, ...) 117 ms
26 database queries per run
Needs 1 MB of memory (max 3 MB)
Duration per run
Where the time goes
Latest run in ci:github-actions:test, 7 hours ago ·
open run
setup0.72 ms1.3%
CallInfo.from_call_pytest/runner.py:3610.72 ms1.3%
call_and_report.<locals>.<lambda>_pytest/runner.py:2500.72 ms1.3%
HookCaller.__call__pluggy/_hooks.py:5120.72 ms1.3%
PluginManager._hookexecpluggy/_manager.py:1200.72 ms1.3%
_multicallpluggy/_callers.py:1210.72 ms1.3%
pytest_runtest_setup_pytest/runner.py:1700.72 ms1.3%
SetupState.setup_pytest/runner.py:5360.72 ms1.3%
call52 ms98.1%
CallInfo.from_call_pytest/runner.py:36152 ms98.1%
call_and_report.<locals>.<lambda>_pytest/runner.py:25052 ms98.1%
HookCaller.__call__pluggy/_hooks.py:51252 ms98.1%
PluginManager._hookexecpluggy/_manager.py:12052 ms98.1%
_multicallpluggy/_callers.py:12152 ms98.1%
pytest_runtest_call_pytest/runner.py:18452 ms98.1%
_django_setup_unittest.<locals>.non_debugging_runtestpytest_django/plugin.py:61452 ms98.1%
SimpleTestCase.__call__django/test/testcases.py:31452 ms98.1%
SimpleTestCase._setup_and_calldjango/test/testcases.py:36947 ms88.8%
TestCase.__call__<stdlib>/unittest/case.py:74747 ms88.8%
TestCase.run<stdlib>/unittest/case.py:69147 ms88.8%
TestCase._callTestMethod<stdlib>/unittest/case.py:63747 ms88.8%
TestShareStarterPack.test_api_plain_jsonstarter_packs/tests.py:851 response = self.client.get(40 ms74.8%
Client.getdjango/test/client.py:113340 ms74.8%
RequestFactory.getdjango/test/client.py:47540 ms74.8%
RequestFactory.genericdjango/test/client.py:67140 ms74.8%
Client.requestdjango/test/client.py:109140 ms74.8%
ClientHandler.__call__django/test/client.py:17335 ms65.4%
BaseHandler.load_middlewaredjango/core/handlers/base.py:6335 ms65.4%
WhiteNoiseMiddleware.__init__whitenoise/middleware.py:10435 ms65.4%
WhiteNoise.add_fileswhitenoise/base.py:10835 ms65.4%
WhiteNoise.update_files_dictionarywhitenoise/base.py:12017 ms32.7%
WhiteNoise.add_file_to_dictionarywhitenoise/base.py:13117 ms32.7%
WhiteNoise.get_static_filewhitenoise/base.py:21712 ms23.4%
StaticFile.__init__whitenoise/responders.py:735 ms9.3%
StaticFile.get_headerswhitenoise/responders.py:1672 ms4.7%
StaticFile.get_headerswhitenoise/responders.py:1802 ms4.7%
StaticFile.__init__whitenoise/responders.py:772 ms4.7%
StaticFile.get_alternativeswhitenoise/responders.py:2012 ms4.7%
WhiteNoise.get_static_filewhitenoise/base.py:2122 ms4.7%
WhiteNoise.add_cache_headerswhitenoise/base.py:2332 ms4.7%
WhiteNoiseMiddleware.immutable_file_testwhitenoise/middleware.py:1762 ms4.7%
WhiteNoiseMiddleware.get_static_urlwhitenoise/middleware.py:1972 ms4.7%
URLMixin.urldebug_toolbar/panels/staticfiles.py:202 ms4.7%
HashedFilesMixin.urldjango/contrib/staticfiles/storage.py:2352 ms4.7%
HashedFilesMixin._urldjango/contrib/staticfiles/storage.py:2162 ms4.7%
FileSystemStorage.urldjango/core/files/storage/filesystem.py:2072 ms4.7%
WhiteNoise.update_files_dictionarywhitenoise/base.py:11512 ms23.4%
scantreewhitenoise/base.py:27110 ms18.7%
scantreewhitenoise/base.py:27110 ms18.7%
scantreewhitenoise/base.py:2737 ms14.0%
scantreewhitenoise/base.py:2712 ms4.7%
scantreewhitenoise/base.py:2712 ms4.7%
scantreewhitenoise/base.py:2712 ms4.7%
scantreewhitenoise/base.py:2732 ms4.7%
scantreewhitenoise/base.py:2692 ms4.7%
ClientHandler.__call__django/test/client.py:1865 ms9.3%
BaseHandler.get_responsedjango/core/handlers/base.py:1425 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
MiddlewareMixin.__call__django/utils/deprecation.py:3805 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
MiddlewareMixin.__call__django/utils/deprecation.py:3805 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
MiddlewareMixin.__call__django/utils/deprecation.py:3805 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
WhiteNoiseMiddleware.__call__whitenoise/middleware.py:1235 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
DebugToolbarMiddleware.__call__debug_toolbar/middleware.py:1455 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
MiddlewareMixin.__call__django/utils/deprecation.py:3805 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
MiddlewareMixin.__call__django/utils/deprecation.py:3805 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
MiddlewareMixin.__call__django/utils/deprecation.py:3805 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
MiddlewareMixin.__call__django/utils/deprecation.py:3805 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
MiddlewareMixin.__call__django/utils/deprecation.py:3805 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
MiddlewareMixin.__call__django/utils/deprecation.py:3805 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
MiddlewareMixin.__call__django/utils/deprecation.py:3805 ms9.3%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:565 ms9.3%
BaseHandler._get_responsedjango/core/handlers/base.py:1995 ms9.3%
share_starter_packstarter_packs/views.py:729 starter_pack = get_object_or_404(StarterPack, slug=starter_pack_slug, deleted_at__isnull=True)2 ms4.7%
get_object_or_404django/shortcuts.py:1002 ms4.7%
QuerySet.getdjango/db/models/query.py:7022 ms4.7%
QuerySet.__len__django/db/models/query.py:4212 ms4.7%
QuerySet._fetch_alldjango/db/models/query.py:22622 ms4.7%
ModelIterable.__iter__django/db/models/query.py:1032 ms4.7%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms4.7%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.7%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.7%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.7%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms4.7%
Cursor.executepsycopg/cursor.py:1132 ms4.7%
Connection.waitpsycopg/connection.py:4952 ms4.7%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms4.7%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms4.7%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms4.7%
share_starter_packstarter_packs/views.py:781 for account in accounts2 ms4.7%
QuerySet.__iter__django/db/models/query.py:4392 ms4.7%
QuerySet._fetch_alldjango/db/models/query.py:22622 ms4.7%
ModelIterable.__iter__django/db/models/query.py:1032 ms4.7%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16122 ms4.7%
SQLCompiler.as_sqldjango/db/models/sql/compiler.py:7682 ms4.7%
SQLCompiler.pre_sql_setupdjango/db/models/sql/compiler.py:892 ms4.7%
SQLCompiler.setup_querydjango/db/models/sql/compiler.py:782 ms4.7%
SQLCompiler.get_selectdjango/db/models/sql/compiler.py:3192 ms4.7%
SQLCompiler.compiledjango/db/models/sql/compiler.py:5792 ms4.7%
Exists.as_sqldjango/db/models/expressions.py:19062 ms4.7%
Subquery.as_sqldjango/db/models/expressions.py:18762 ms4.7%
Query.as_sqldjango/db/models/sql/query.py:13182 ms4.7%
SQLCompiler.as_sqldjango/db/models/sql/compiler.py:7962 ms4.7%
SQLCompiler.compiledjango/db/models/sql/compiler.py:5792 ms4.7%
WhereNode.as_sqldjango/db/models/sql/where.py:1512 ms4.7%
SQLCompiler.compiledjango/db/models/sql/compiler.py:5792 ms4.7%
RelatedLookupMixin.as_sqldjango/db/models/fields/related_lookups.py:1282 ms4.7%
Exact.as_sqldjango/db/models/lookups.py:4072 ms4.7%
BuiltinLookup.as_sqldjango/db/models/lookups.py:2432 ms4.7%
BuiltinLookup.process_lhsdjango/db/models/lookups.py:2352 ms4.7%
Lookup.process_lhsdjango/db/models/lookups.py:1092 ms4.7%
TestShareStarterPack.test_api_plain_jsonstarter_packs/tests.py:897 for account in accounts7 ms14.0%
QuerySet.__iter__django/db/models/query.py:4397 ms14.0%
QuerySet._fetch_alldjango/db/models/query.py:22627 ms14.0%
ModelIterable.__iter__django/db/models/query.py:1037 ms14.0%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16255 ms9.3%
CursorWrapper.executedjango/db/backends/utils.py:795 ms9.3%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:925 ms9.3%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1005 ms9.3%
CursorWrapper._executedjango/db/backends/utils.py:1055 ms9.3%
Cursor.executepsycopg/cursor.py:1135 ms9.3%
Connection.waitpsycopg/connection.py:4955 ms9.3%
BaseCursor._execute_genpsycopg/_cursor_base.py:2065 ms9.3%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2865 ms9.3%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:785 ms9.3%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16122 ms4.7%
SQLCompiler.as_sqldjango/db/models/sql/compiler.py:7682 ms4.7%
SQLCompiler.pre_sql_setupdjango/db/models/sql/compiler.py:892 ms4.7%
SQLCompiler.setup_querydjango/db/models/sql/compiler.py:782 ms4.7%
SQLCompiler.get_selectdjango/db/models/sql/compiler.py:2652 ms4.7%
SQLCompiler.get_default_columnsdjango/db/models/sql/compiler.py:10102 ms4.7%
SimpleTestCase._setup_and_calldjango/test/testcases.py:3602 ms4.7%
TransactionTestCase._pre_setupdjango/test/testcases.py:1167 cls._fixture_setup()2 ms4.7%
TestCase._fixture_setupdjango/test/testcases.py:14812 ms4.7%
TestCase._enter_atomicsdjango/test/testcases.py:13992 ms4.7%
Atomic.__enter__django/db/transaction.py:2232 ms4.7%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:262 ms4.7%
BaseDatabaseWrapper.savepointdjango/db/backends/base/base.py:4002 ms4.7%
BaseDatabaseWrapper._savepointdjango/db/backends/base/base.py:3672 ms4.7%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.7%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.7%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.7%
CursorWrapper._executedjango/db/backends/utils.py:1032 ms4.7%
Cursor.executepsycopg/cursor.py:1132 ms4.7%
Connection.waitpsycopg/connection.py:4952 ms4.7%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms4.7%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms4.7%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms4.7%
SimpleTestCase._setup_and_calldjango/test/testcases.py:3722 ms4.7%
TransactionTestCase._post_teardowndjango/test/testcases.py:1243 self._fixture_teardown()2 ms4.7%
TestCase._fixture_teardowndjango/test/testcases.py:14982 ms4.7%
DatabaseWrapper.check_constraintsdjango/db/backends/postgresql/base.py:4952 ms4.7%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.7%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.7%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.7%
CursorWrapper._executedjango/db/backends/utils.py:1032 ms4.7%
Cursor.executepsycopg/cursor.py:1132 ms4.7%
Connection.waitpsycopg/connection.py:4952 ms4.7%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms4.7%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms4.7%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms4.7%
Estimated from 22 samples; phase durations are exact. Frames from pytest and pluggy are
shown
.
Hot lines in your code
|
starter_packs/tests.py:851
response = self.client.get(
TestShareStarterPack.test_api_plain_json
· Libraries
|
35 ms |
|
starter_packs/tests.py:897
for account in accounts
TestShareStarterPack.test_api_plain_json
· Database
|
7 ms |
|
starter_packs/views.py:729
starter_pack = get_object_or_404(StarterPack, slug=starter_pack_slug, deleted_at__isnull=True)
share_starter_pack
· Database
|
2 ms |
|
starter_packs/views.py:781
for account in accounts
share_starter_pack
· Database
|
2 ms |
Fixtures
Exact setup time| _template_string_if_invalid_marker function | 0.05 ms |
| _dj_autoclear_mailbox function | 0.05 ms |
| _django_db_marker function | 0.03 ms |
| _django_isolate_apps function | 0.02 ms |
| _live_server_helper function | 0.02 ms |
| _django_set_urlconf function | 0.02 ms |
| _django_clear_site_cache function | 0.02 ms |
| monkeypatch function | 0.02 ms |
Database
9 queries · 6 msNo repeated queries.
Biggest pieces of work
|
call test body
starter_packs/tests.py:851
|
47 ms |
|
call _pre_setup
django/test/testcases.py:1167
|
2 ms |
|
call _post_teardown
django/test/testcases.py:1243
|
2 ms |
| setup pytest internals | 0.72 ms |
Reliability
5 results · 1 CI failure · 0 local failuresRegression caught Fixed by a change that didn't touch the test: the test caught a real bug.
| Failure streak | Verdict | Failures |
|---|---|---|
| Oct 18, 15:53 → Oct 18, 16:01 | Regression caught | 1 |
History
Latest 50 results, oldest first in the strip| When | Environment | Outcome | Duration | |
|---|---|---|---|---|
| 7 hours ago | CI github-actions:test | passed | 53 ms | Profile |
| 7 hours ago | CI github-actions:test | passed | 218 ms | Profile |
| 7 hours ago | CI github-actions:test | failed | 362 ms | Profile |
| 12 hours ago | CI github-actions:test | passed | 246 ms | Profile |
| 12 hours ago | CI github-actions:test | passed | 85 ms | Run |
| 3 months, 3 weeks ago | CI github-actions | passed | 54 ms | Run |
| 3 months, 3 weeks ago | CI github-actions | passed | 77 ms | Run |
| 3 months, 3 weeks ago | CI github-actions | passed | 82 ms | Run |
| 3 months, 3 weeks ago | CI github-actions | passed | 95 ms | Run |
| 3 months, 3 weeks ago | CI github-actions | passed | 79 ms | Run |
| 3 months, 3 weeks ago | CI github-actions | passed | 94 ms | Run |
| 3 months, 3 weeks ago | CI github-actions | passed | 78 ms | Run |
| 3 months, 3 weeks ago | CI github-actions | passed | 89 ms | Run |
| 3 months, 3 weeks ago | CI github-actions | passed | 96 ms | Run |
| 3 months, 4 weeks ago | CI github-actions | passed | 91 ms | Run |
| 3 months, 4 weeks ago | CI github-actions | passed | 87 ms | Run |
| 3 months, 4 weeks ago | CI github-actions | passed | 89 ms | Run |
| 3 months, 4 weeks ago | CI github-actions | passed | 83 ms | Run |
| 3 months, 4 weeks ago | CI github-actions | passed | 95 ms | Run |
| 3 months, 4 weeks ago | CI github-actions | passed | 90 ms | Run |