flakytest.dev anze3db flakytest
Tests / apps/mcp/tests.py

McpTest::test_get_test_not_found

First seen 9 hours ago in 78a4357
CI github-actions:test 5 runs
Average
40 ms
median 44 ms
max 49 ms
Phases
Setup 0.64 ms Call 39 ms Teardown 0.17 ms
Categories
Database 13 ms Other (Libraries, Unsampled, pytest) 27 ms

13 database queries per run

Needs 0 KB of memory (max 0 KB)

Duration per run

Where the time goes

Latest run in ci:github-actions:test, 2 hours ago · open run
Hide pytest frames
call43 ms98.0%
CallInfo.from_call_pytest/runner.py:35343 ms98.0%
call_and_report.<locals>.<lambda>_pytest/runner.py:24543 ms98.0%
HookCaller.__call__pluggy/_hooks.py:51243 ms98.0%
PluginManager._hookexecpluggy/_manager.py:12043 ms98.0%
_multicallpluggy/_callers.py:12143 ms98.0%
pytest_runtest_call_pytest/runner.py:17943 ms98.0%
_django_setup_unittest.<locals>.non_debugging_runtestpytest_django/plugin.py:57343 ms98.0%
SimpleTestCase.__call__django/test/testcases.py:31343 ms98.0%
SimpleTestCase._setup_and_calldjango/test/testcases.py:36838 ms88.2%
TestCase.__call__<stdlib>/unittest/case.py:74738 ms88.2%
TestCase.run<stdlib>/unittest/case.py:69138 ms88.2%
TestCase._callTestMethod<stdlib>/unittest/case.py:63738 ms88.2%
McpTest.test_get_test_not_foundapps/mcp/tests.py:237 body = self.rpc("tools/call", {"name": "get_test", "arguments": {"nodeid": "test_other"}})32 ms73.5%
McpTest.rpcapps/mcp/tests.py:7432 ms73.5%
McpTest.postapps/mcp/tests.py:66 return self.client.post(32 ms73.5%
Client.postdjango/test/client.py:115332 ms73.5%
RequestFactory.postdjango/test/client.py:49932 ms73.5%
RequestFactory.genericdjango/test/client.py:67132 ms73.5%
Client.requestdjango/test/client.py:108232 ms73.5%
ClientHandler.__call__django/test/client.py:17323 ms53.9%
BaseHandler.load_middlewaredjango/core/handlers/base.py:6223 ms53.9%
WhiteNoiseMiddleware.__init__whitenoise/middleware.py:10423 ms53.9%
WhiteNoise.add_fileswhitenoise/base.py:10823 ms53.9%
WhiteNoise.update_files_dictionarywhitenoise/base.py:12017 ms39.2%
WhiteNoise.add_file_to_dictionarywhitenoise/base.py:13117 ms39.2%
WhiteNoise.get_static_filewhitenoise/base.py:20815 ms34.3%
StaticFile.__init__whitenoise/responders.py:739 ms19.6%
StaticFile.get_headerswhitenoise/responders.py:1764 ms9.8%
formatdate<stdlib>/email/utils.py:2664 ms9.8%
StaticFile.get_headerswhitenoise/responders.py:1782 ms4.9%
parsedate<stdlib>/email/_parseaddr.py:1852 ms4.9%
StaticFile.__init__whitenoise/responders.py:772 ms4.9%
StaticFile.get_alternativeswhitenoise/responders.py:2012 ms4.9%
StaticFile.__init__whitenoise/responders.py:722 ms4.9%
StaticFile.get_file_statswhitenoise/responders.py:1612 ms4.9%
WhiteNoise.get_static_filewhitenoise/base.py:2032 ms4.9%
WhiteNoise.add_cache_headerswhitenoise/base.py:2242 ms4.9%
WhiteNoiseMiddleware.immutable_file_testwhitenoise/middleware.py:1762 ms4.9%
WhiteNoiseMiddleware.get_static_urlwhitenoise/middleware.py:1972 ms4.9%
URLMixin.urldebug_toolbar/panels/staticfiles.py:202 ms4.9%
WhiteNoise.update_files_dictionarywhitenoise/base.py:1156 ms14.7%
scantreewhitenoise/base.py:2626 ms14.7%
scantreewhitenoise/base.py:2626 ms14.7%
scantreewhitenoise/base.py:2642 ms4.9%
scantreewhitenoise/base.py:2622 ms4.9%
scantreewhitenoise/base.py:2622 ms4.9%
scantreewhitenoise/base.py:2622 ms4.9%
scantreewhitenoise/base.py:2642 ms4.9%
scantreewhitenoise/base.py:2602 ms4.9%
ClientHandler.__call__django/test/client.py:1869 ms19.6%
BaseHandler.get_responsedjango/core/handlers/base.py:1419 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
DebugToolbarMiddleware.__call__debug_toolbar/middleware.py:1309 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
MiddlewareMixin.__call__django/utils/deprecation.py:3099 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
WhiteNoiseMiddleware.__call__whitenoise/middleware.py:1239 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
MiddlewareMixin.__call__django/utils/deprecation.py:3099 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
MiddlewareMixin.__call__django/utils/deprecation.py:3099 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
MiddlewareMixin.__call__django/utils/deprecation.py:3099 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
MiddlewareMixin.__call__django/utils/deprecation.py:3099 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
MiddlewareMixin.__call__django/utils/deprecation.py:3099 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
MiddlewareMixin.__call__django/utils/deprecation.py:3099 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
AccountMiddleware.<locals>.middlewareallauth/account/middleware.py:349 ms19.6%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:559 ms19.6%
BaseHandler._get_responsedjango/core/handlers/base.py:1989 ms19.6%
csrf_exempt.<locals>._view_wrapperdjango/views/decorators/csrf.py:659 ms19.6%
mcpapps/mcp/urls.py:1254 ms9.8%
authenticateapps/mcp/urls.py:55 project = Project.objects.filter(secrettokens__token=token).first()2 ms4.9%
QuerySet.firstdjango/db/models/query.py:11452 ms4.9%
QuerySet.__iter__django/db/models/query.py:3902 ms4.9%
QuerySet._fetch_alldjango/db/models/query.py:20002 ms4.9%
ModelIterable.__iter__django/db/models/query.py:952 ms4.9%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16242 ms4.9%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.9%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.9%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.9%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms4.9%
Cursor.executepsycopg/cursor.py:1132 ms4.9%
Connection.waitpsycopg/connection.py:4952 ms4.9%
authenticateapps/mcp/urls.py:57 SecretTokens.objects.filter(token=token).update(date_last_used=timezone.now())2 ms4.9%
QuerySet.updatedjango/db/models/query.py:13002 ms4.9%
SQLUpdateCompiler.execute_sqldjango/db/models/sql/compiler.py:21112 ms4.9%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16242 ms4.9%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.9%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.9%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.9%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms4.9%
Cursor.executepsycopg/cursor.py:1132 ms4.9%
Connection.waitpsycopg/connection.py:4952 ms4.9%
mcpapps/mcp/urls.py:1474 ms9.8%
handleapps/mcp/urls.py:1154 ms9.8%
call_toolapps/mcp/urls.py:754 ms9.8%
Tools.callapps/mcp/tools.py:1814 ms9.8%
Tools.get_testapps/mcp/tools.py:2954 ms9.8%
Tools.find_testapps/mcp/tools.py:281 test = tests.filter(name=nodeid).first()2 ms4.9%
QuerySet.firstdjango/db/models/query.py:11452 ms4.9%
QuerySet.__iter__django/db/models/query.py:3902 ms4.9%
QuerySet._fetch_alldjango/db/models/query.py:20002 ms4.9%
ModelIterable.__iter__django/db/models/query.py:952 ms4.9%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16242 ms4.9%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.9%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.9%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.9%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms4.9%
Cursor.executepsycopg/cursor.py:1132 ms4.9%
Connection.waitpsycopg/connection.py:4952 ms4.9%
Tools.find_testapps/mcp/tools.py:284 matches = list(tests.filter(name__contains=nodeid).order_by("name")[:11])2 ms4.9%
QuerySet.__iter__django/db/models/query.py:3902 ms4.9%
QuerySet._fetch_alldjango/db/models/query.py:20002 ms4.9%
ModelIterable.__iter__django/db/models/query.py:952 ms4.9%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16242 ms4.9%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.9%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.9%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.9%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms4.9%
Cursor.executepsycopg/cursor.py:1132 ms4.9%
Connection.waitpsycopg/connection.py:4952 ms4.9%
McpTest.test_get_test_not_foundapps/mcp/tests.py:2396 ms14.7%
McpTest.rpcapps/mcp/tests.py:746 ms14.7%
McpTest.postapps/mcp/tests.py:66 return self.client.post(6 ms14.7%
Client.postdjango/test/client.py:11536 ms14.7%
RequestFactory.postdjango/test/client.py:4996 ms14.7%
RequestFactory.genericdjango/test/client.py:6716 ms14.7%
Client.requestdjango/test/client.py:10826 ms14.7%
ClientHandler.__call__django/test/client.py:1866 ms14.7%
BaseHandler.get_responsedjango/core/handlers/base.py:1416 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
DebugToolbarMiddleware.__call__debug_toolbar/middleware.py:1306 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
MiddlewareMixin.__call__django/utils/deprecation.py:3096 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
WhiteNoiseMiddleware.__call__whitenoise/middleware.py:1236 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
MiddlewareMixin.__call__django/utils/deprecation.py:3096 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
MiddlewareMixin.__call__django/utils/deprecation.py:3096 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
MiddlewareMixin.__call__django/utils/deprecation.py:3096 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
MiddlewareMixin.__call__django/utils/deprecation.py:3096 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
MiddlewareMixin.__call__django/utils/deprecation.py:3096 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
MiddlewareMixin.__call__django/utils/deprecation.py:3096 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
AccountMiddleware.<locals>.middlewareallauth/account/middleware.py:346 ms14.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:556 ms14.7%
BaseHandler._get_responsedjango/core/handlers/base.py:1986 ms14.7%
csrf_exempt.<locals>._view_wrapperdjango/views/decorators/csrf.py:656 ms14.7%
mcpapps/mcp/urls.py:1474 ms9.8%
handleapps/mcp/urls.py:1154 ms9.8%
call_toolapps/mcp/urls.py:754 ms9.8%
Tools.callapps/mcp/tools.py:1814 ms9.8%
Tools.get_testapps/mcp/tools.py:2954 ms9.8%
Tools.find_testapps/mcp/tools.py:281 test = tests.filter(name=nodeid).first()2 ms4.9%
QuerySet.firstdjango/db/models/query.py:11452 ms4.9%
QuerySet.__iter__django/db/models/query.py:3902 ms4.9%
QuerySet._fetch_alldjango/db/models/query.py:20002 ms4.9%
ModelIterable.__iter__django/db/models/query.py:952 ms4.9%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16242 ms4.9%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.9%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.9%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.9%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms4.9%
Cursor.executepsycopg/cursor.py:1132 ms4.9%
Connection.waitpsycopg/connection.py:4952 ms4.9%
Tools.find_testapps/mcp/tools.py:284 matches = list(tests.filter(name__contains=nodeid).order_by("name")[:11])2 ms4.9%
QuerySet.__iter__django/db/models/query.py:3902 ms4.9%
QuerySet._fetch_alldjango/db/models/query.py:20002 ms4.9%
ModelIterable.__iter__django/db/models/query.py:952 ms4.9%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16242 ms4.9%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.9%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.9%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.9%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms4.9%
Cursor.executepsycopg/cursor.py:1132 ms4.9%
Connection.waitpsycopg/connection.py:4952 ms4.9%
mcpapps/mcp/urls.py:1252 ms4.9%
authenticateapps/mcp/urls.py:55 project = Project.objects.filter(secrettokens__token=token).first()2 ms4.9%
QuerySet.firstdjango/db/models/query.py:11452 ms4.9%
QuerySet.__iter__django/db/models/query.py:3902 ms4.9%
QuerySet._fetch_alldjango/db/models/query.py:20002 ms4.9%
ModelIterable.__iter__django/db/models/query.py:952 ms4.9%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16112 ms4.9%
SQLCompiler.as_sqldjango/db/models/sql/compiler.py:7922 ms4.9%
SQLCompiler.get_from_clausedjango/db/models/sql/compiler.py:11592 ms4.9%
SQLCompiler.compiledjango/db/models/sql/compiler.py:5782 ms4.9%
SimpleTestCase._setup_and_calldjango/test/testcases.py:3714 ms9.8%
TransactionTestCase._post_teardowndjango/test/testcases.py:1240 self._fixture_teardown()4 ms9.8%
TestCase._fixture_teardowndjango/test/testcases.py:14954 ms9.8%
DatabaseWrapper.check_constraintsdjango/db/backends/postgresql/base.py:4832 ms4.9%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.9%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.9%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.9%
CursorWrapper._executedjango/db/backends/utils.py:1032 ms4.9%
Cursor.executepsycopg/cursor.py:1132 ms4.9%
Connection.waitpsycopg/connection.py:4952 ms4.9%
DatabaseWrapper.check_constraintsdjango/db/backends/postgresql/base.py:4842 ms4.9%
CursorWrapper.executedjango/db/backends/utils.py:792 ms4.9%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms4.9%
QueryTracker._django_wrapperflakytest/profiling/dbtrack.py:1002 ms4.9%
CursorWrapper._executedjango/db/backends/utils.py:1032 ms4.9%
Cursor.executepsycopg/cursor.py:1132 ms4.9%
Connection.waitpsycopg/connection.py:4952 ms4.9%
Estimated from 20 samples; phase durations are exact. Frames from pytest and pluggy are shown .

Hot lines in your code

apps/mcp/tests.py:66
return self.client.post(
McpTest.post · Libraries
23 ms
apps/mcp/urls.py:55
project = Project.objects.filter(secrettokens__token=token).first()
authenticate · Database
4 ms
apps/mcp/tools.py:281
test = tests.filter(name=nodeid).first()
Tools.find_test · Database
4 ms
apps/mcp/tools.py:284
matches = list(tests.filter(name__contains=nodeid).order_by("name")[:11])
Tools.find_test · Database
4 ms
apps/mcp/urls.py:57
SecretTokens.objects.filter(token=token).update(date_last_used=timezone.now())
authenticate · Database
2 ms

Fixtures

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

Database

13 queries · 5 ms

Repeated queries are usually N+1 lookups: fetch them once with select_related / prefetch_related (or selectinload).

4×
SELECT "projects_test"."id", "projects_test"."name", "projects_test"."project_id", "projects_test"."slug", "projects_test"."date_last_run", "projects_test"."date_first_seen", "projects_test"."first_commit_id", "projects_test"."muted" FROM "projects_test" WHERE ("projects_test"."project_id" = %s AND…

Biggest pieces of work

call test body
apps/mcp/tests.py:237
38 ms
call _post_teardown
django/test/testcases.py:1240
4 ms

Reliability

5 results · 0 CI failures · 0 local failures

This test hasn't failed recently.

History

Latest 5 results, oldest first in the strip
When Environment Outcome Duration Commit
2 hours ago CI github-actions:test passed 43 ms 9caa567 main Profile
2 hours ago CI github-actions:test passed 44 ms ec75501 main Profile
9 hours ago CI github-actions:test passed 49 ms d2c12e5 main Profile
9 hours ago CI github-actions:test passed 20 ms 0b902f6 main Profile
9 hours ago CI github-actions:test passed 44 ms 78a4357 main Profile