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

TestSyncAnnouncements::test_skips_past_and_archived_conferences

First seen 3 weeks ago in 0c23747
CI github-actions:test 11 runs
Average
21 ms
median 19 ms
max 35 ms
Phases
Setup 3 ms Call 17 ms Teardown 0.35 ms
Categories
Database 14 ms Factories 0.73 ms Other (pytest, Libraries, Unsampled, Mocking, ...) 6 ms

9 database queries per run

Needs 13 KB of memory (max 32 KB)

Duration per run

Where the time goes

Latest run in ci:github-actions:test, 7 hours ago · open run
Show pytest frames
setup1 ms10.3%
call9 ms87.5%
TestSyncAnnouncements.test_skips_past_and_archived_conferencesconfs/tests.py:9974 ms35.0%
TestSyncAnnouncements._syncconfs/tests.py:936 with mock.patch("confs.management.commands.syncannouncements.timezone.now", return_value=self.NOW):2 ms17.5%
_patch.__enter__<stdlib>/unittest/mock.py:15102 ms17.5%
_patch.get_original<stdlib>/unittest/mock.py:14632 ms17.5%
resolve_name<stdlib>/pkgutil.py:4812 ms17.5%
TestSyncAnnouncements._syncconfs/tests.py:937 call_command("syncannouncements")2 ms17.5%
call_commanddjango/core/management/__init__.py:1952 ms17.5%
RichCommand.executedjango_rich/management/__init__.py:342 ms17.5%
BaseCommand.executedjango/core/management/base.py:4662 ms17.5%
Command.handleconfs/management/commands/syncannouncements.py:132 ms17.5%
sync_upcomingconfs/conference_announcements.py:107 for conference in upcoming:2 ms17.5%
QuerySet.__iter__django/db/models/query.py:4392 ms17.5%
QuerySet._fetch_alldjango/db/models/query.py:22622 ms17.5%
ModelIterable.__iter__django/db/models/query.py:1032 ms17.5%
SQLCompiler.execute_sqldjango/db/models/sql/compiler.py:16252 ms17.5%
CursorWrapper.executedjango/db/backends/utils.py:792 ms17.5%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms17.5%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms17.5%
Cursor.executepsycopg/cursor.py:1132 ms17.5%
Connection.waitpsycopg/connection.py:4952 ms17.5%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms17.5%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms17.5%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms17.5%
TransactionTestCase._post_teardowndjango/test/testcases.py:1243 self._fixture_teardown()4 ms35.0%
TestCase._fixture_teardowndjango/test/testcases.py:14972 ms17.5%
TestCase._should_check_constraintsdjango/test/testcases.py:15062 ms17.5%
DatabaseWrapper.is_usabledjango/db/backends/postgresql/base.py:5042 ms17.5%
Cursor.executepsycopg/cursor.py:1132 ms17.5%
Connection.waitpsycopg/connection.py:4952 ms17.5%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms17.5%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms17.5%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms17.5%
TestCase._fixture_teardowndjango/test/testcases.py:15002 ms17.5%
TestCase._rollback_atomicsdjango/test/testcases.py:14082 ms17.5%
Atomic.__exit__django/db/transaction.py:2952 ms17.5%
async_unsafe.<locals>.decorator.<locals>.innerdjango/utils/asyncio.py:262 ms17.5%
BaseDatabaseWrapper.savepoint_rollbackdjango/db/backends/base/base.py:4132 ms17.5%
BaseDatabaseWrapper._savepoint_rollbackdjango/db/backends/base/base.py:3712 ms17.5%
CursorWrapper.executedjango/db/backends/utils.py:792 ms17.5%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms17.5%
CursorWrapper._executedjango/db/backends/utils.py:1032 ms17.5%
Cursor.executepsycopg/cursor.py:1132 ms17.5%
Connection.waitpsycopg/connection.py:4952 ms17.5%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms17.5%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms17.5%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms17.5%
TestSyncAnnouncements.test_skips_past_and_archived_conferencesconfs/tests.py:994 self._conference(slug="past", start_date=dt.date(2020, 1, 1), end_date=dt.date(2020, 1, 3))2 ms17.5%
TestSyncAnnouncements._conferenceconfs/tests.py:933 return baker.make(Conference, **defaults)2 ms17.5%
makemodel_bakery/baker.py:1752 ms17.5%
Baker.makemodel_bakery/baker.py:4542 ms17.5%
Baker._makemodel_bakery/baker.py:5422 ms17.5%
Baker.instancemodel_bakery/baker.py:6592 ms17.5%
Model.savedjango/db/models/base.py:9042 ms17.5%
Model.save_basedjango/db/models/base.py:9962 ms17.5%
Model._save_tabledjango/db/models/base.py:11992 ms17.5%
Model._do_insertdjango/db/models/base.py:12512 ms17.5%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:872 ms17.5%
QuerySet._insertdjango/db/models/query.py:21412 ms17.5%
SQLInsertCompiler.execute_sqldjango/db/models/sql/compiler.py:19362 ms17.5%
CursorWrapper.executedjango/db/backends/utils.py:792 ms17.5%
CursorWrapper._execute_with_wrappersdjango/db/backends/utils.py:922 ms17.5%
CursorWrapper._executedjango/db/backends/utils.py:1052 ms17.5%
Cursor.executepsycopg/cursor.py:1132 ms17.5%
Connection.waitpsycopg/connection.py:4952 ms17.5%
BaseCursor._execute_genpsycopg/_cursor_base.py:2062 ms17.5%
BaseCursor._maybe_prepare_genpsycopg/_cursor_base.py:2862 ms17.5%
ClientCursorMixin._execute_sendpsycopg/client_cursor.py:782 ms17.5%
Estimated from 6 samples; phase durations are exact. Frames from pytest and pluggy are hidden .

Hot lines in your code

confs/tests.py:933
return baker.make(Conference, **defaults)
TestSyncAnnouncements._conference · Database
2 ms
confs/tests.py:936
with mock.patch("confs.management.commands.syncannouncements.timezone.now", return_value=self.NOW):
TestSyncAnnouncements._sync · Mocking
2 ms
confs/conference_announcements.py:107
for conference in upcoming:
sync_upcoming · Database
2 ms

Fixtures

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

Database

9 queries · 4 ms
No repeated queries.

Biggest pieces of work

call test body
confs/tests.py:994
6 ms
call _post_teardown
django/test/testcases.py:1243
4 ms
setup pytest internals 1 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
7 hours ago CI github-actions:test passed 11 ms c28a326 main Profile
16 hours ago CI github-actions:test passed 13 ms 9b8826a main Profile
22 hours ago CI github-actions:test passed 11 ms 4f01055 main Profile
1 week, 5 days ago CI github-actions:test passed 21 ms 8ab642e main Profile
2 weeks, 2 days ago CI github-actions:test passed 19 ms 9b75244 main Profile
2 weeks, 2 days ago CI github-actions:test passed 16 ms 9603516 main Profile
2 weeks, 4 days ago CI github-actions:test passed 32 ms 615a272 main Profile
3 weeks ago CI github-actions:test passed 14 ms d923a46 main Profile
3 weeks ago CI github-actions:test passed 22 ms 82997f8 main Profile
3 weeks ago CI github-actions:test passed 35 ms 623aa3e main Profile
3 weeks ago CI github-actions:test passed 31 ms ab6465a main Profile
3 weeks ago CI github-actions:test passed 9 ms 0c23747 main Run