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

AnalyticsTest::test_ci_vs_local_needs_both

First seen 3 weeks ago in 78a4357
CI github-actions:test 12 runs
Average
7 ms
median 7 ms
max 8 ms
Phases
Setup 0.62 ms Call 6 ms Teardown 0.15 ms
Categories
Database 4 ms Factories 0.20 ms Other (Unsampled, pytest, Libraries) 2 ms

9 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, 16 hours ago · open run
Show pytest frames
call6 ms89.3%
AnalyticsTest.test_ci_vs_local_needs_bothapps/projects/tests.py:797 self.assertIsNone(ci_vs_local(baker.make(Project)))4 ms59.5%
ci_vs_localapps/projects/analytics.py:734 ci = list(Environment.objects.filter(project=project, kind=Environment.Kind.CI))2 ms29.8%
QuerySet.__iter__django/db/models/query.py:3902 ms29.8%
QuerySet._fetch_alldjango/db/models/query.py:20002 ms29.8%
ModelIterable.__iter__django/db/models/query.py:952 ms29.8%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16242 ms29.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms29.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms29.8%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms29.8%
Cursor.executepsycopg/cursor.py:1132 ms29.8%
Connection.waitpsycopg/connection.py:4952 ms29.8%
ci_vs_localapps/projects/analytics.py:735 local = list(Environment.objects.filter(project=project, kind=Environment.Kind.LOCAL))2 ms29.8%
QuerySet.__iter__django/db/models/query.py:3902 ms29.8%
QuerySet._fetch_alldjango/db/models/query.py:20002 ms29.8%
ModelIterable.__iter__django/db/models/query.py:1272 ms29.8%
TransactionTestCase._post_teardowndjango/test/testcases.py:1240 self._fixture_teardown()2 ms29.8%
TestCase._fixture_teardowndjango/test/testcases.py:14952 ms29.8%
DatabaseWrapper.check_constraintsdjango/db/backends/postgresql/base.py:4832 ms29.8%
CursorWrapper.executedjango/db/backends/utils.py:792 ms29.8%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms29.8%
CursorWrapper._executedjango/db/backends/utils.py:1032 ms29.8%
Cursor.executepsycopg/cursor.py:1132 ms29.8%
Connection.waitpsycopg/connection.py:4952 ms29.8%
Estimated from 3 samples; phase durations are exact. Frames from pytest and pluggy are hidden .

Hot lines in your code

apps/projects/analytics.py:734
ci = list(Environment.objects.filter(project=project, kind=Environment.Kind.CI))
ci_vs_local · Database
2 ms
apps/projects/analytics.py:735
local = list(Environment.objects.filter(project=project, kind=Environment.Kind.LOCAL))
ci_vs_local · Database
2 ms

Fixtures

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

Database

9 queries · 3 ms
No repeated queries.

Biggest pieces of work

call test body
apps/projects/tests.py:797
4 ms
call _post_teardown
django/test/testcases.py:1240
2 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
16 hours ago CI github-actions:test passed 7 ms e141198 main Profile
1 week, 5 days ago CI github-actions:test passed 4 ms 46ec2aa main Profile
2 weeks, 1 day ago CI github-actions:test passed 7 ms afde85b main Profile
2 weeks, 1 day ago CI github-actions:test passed 7 ms fe29f9d main Profile
2 weeks, 1 day ago CI github-actions:test passed 8 ms 044719a main Profile
2 weeks, 2 days ago CI github-actions:test passed 4 ms b3fedae main Profile
2 weeks, 4 days ago CI github-actions:test passed 8 ms 43c4eda main Profile
2 weeks, 6 days ago CI github-actions:test passed 7 ms 9caa567 main Profile
2 weeks, 6 days ago CI github-actions:test passed 8 ms ec75501 main Profile
3 weeks ago CI github-actions:test passed 8 ms d2c12e5 main Profile
3 weeks ago CI github-actions:test passed 4 ms 0b902f6 main Profile
3 weeks ago CI github-actions:test passed 7 ms 78a4357 main Profile