Tests / confs/tests.py
TestCreateConference::test_mastodon_url_is_kept
First seen 12 hours ago in 0c23747
CI
github-actions:test
4 runs
Average
1.26 s
median 1.41 s
max 1.63 s
max 1.63 s
Phases
Setup 3 ms
Call 1.26 s
Teardown 0.30 ms
Categories
Password hashing 770 ms
Database 34 ms
Other (Libraries, Unsampled, Deep copies) 460 ms
27 database queries per run
Needs 25 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
call600 ms99.8%
TestCreateConference.setUpconfs/tests.py:1044 self.user = User.objects.create_user("alice", password="pw")337 ms56.1%
UserManager.create_userdjango/contrib/auth/models.py:180337 ms56.1%
UserManager._create_userdjango/contrib/auth/models.py:167336 ms55.9%
UserManager._create_user_objectdjango/contrib/auth/models.py:160336 ms55.9%
make_passworddjango/contrib/auth/hashers.py:118335 ms55.7%
PBKDF2PasswordHasher.encodedjango/contrib/auth/hashers.py:333335 ms55.7%
pbkdf2django/utils/crypto.py:93335 ms55.7%
1 smaller frames hidden
1 smaller frames hidden
TestCreateConference.test_mastodon_url_is_keptconfs/tests.py:1132 self.client.post(reverse("create_conference"), data)253 ms42.1%
Client.postdjango/test/client.py:1162253 ms42.1%
RequestFactory.postdjango/test/client.py:499253 ms42.1%
RequestFactory.genericdjango/test/client.py:671253 ms42.1%
Client.requestdjango/test/client.py:1091253 ms42.1%
ClientHandler.__call__django/test/client.py:173243 ms40.4%
BaseHandler.load_middlewaredjango/core/handlers/base.py:63243 ms40.4%
WhiteNoiseMiddleware.__init__whitenoise/middleware.py:104241 ms40.0%
WhiteNoise.add_fileswhitenoise/base.py:108241 ms40.0%
WhiteNoise.update_files_dictionarywhitenoise/base.py:120234 ms38.8%
WhiteNoise.add_file_to_dictionarywhitenoise/base.py:131234 ms38.8%
WhiteNoise.get_static_filewhitenoise/base.py:212208 ms34.6%
WhiteNoise.add_cache_headerswhitenoise/base.py:233207 ms34.4%
WhiteNoiseMiddleware.immutable_file_testwhitenoise/middleware.py:176207 ms34.4%
WhiteNoiseMiddleware.get_static_urlwhitenoise/middleware.py:197207 ms34.4%
URLMixin.urldebug_toolbar/panels/staticfiles.py:21202 ms33.6%
<GC>~202 ms33.6%
URLMixin.urldebug_toolbar/panels/staticfiles.py:204 ms0.7%
HashedFilesMixin.urldjango/contrib/staticfiles/storage.py:2353 ms0.5%
1 smaller frames hidden
1 smaller frames hidden
WhiteNoise.get_static_filewhitenoise/base.py:21720 ms3.4%
StaticFile.__init__whitenoise/responders.py:7312 ms2.0%
StaticFile.get_headerswhitenoise/responders.py:1764 ms0.7%
5 smaller frames hidden
StaticFile.__init__whitenoise/responders.py:764 ms0.7%
3 smaller frames hidden
WhiteNoise.get_static_filewhitenoise/base.py:2103 ms0.5%
1 smaller frames hidden
WhiteNoise.update_files_dictionarywhitenoise/base.py:1157 ms1.2%
scantreewhitenoise/base.py:2717 ms1.2%
scantreewhitenoise/base.py:2716 ms1.0%
scantreewhitenoise/base.py:2735 ms0.9%
1 smaller frames hidden
1 smaller frames hidden
ClientHandler.__call__django/test/client.py:18610 ms1.7%
BaseHandler.get_responsedjango/core/handlers/base.py:14210 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
MiddlewareMixin.__call__django/utils/deprecation.py:38010 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
MiddlewareMixin.__call__django/utils/deprecation.py:38010 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
MiddlewareMixin.__call__django/utils/deprecation.py:38010 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
WhiteNoiseMiddleware.__call__whitenoise/middleware.py:12310 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
DebugToolbarMiddleware.__call__debug_toolbar/middleware.py:14510 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
MiddlewareMixin.__call__django/utils/deprecation.py:38010 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
MiddlewareMixin.__call__django/utils/deprecation.py:38010 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
MiddlewareMixin.__call__django/utils/deprecation.py:38010 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
MiddlewareMixin.__call__django/utils/deprecation.py:38010 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
MiddlewareMixin.__call__django/utils/deprecation.py:38010 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
MiddlewareMixin.__call__django/utils/deprecation.py:38010 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
MiddlewareMixin.__call__django/utils/deprecation.py:38010 ms1.7%
convert_exception_to_response.<locals>.innerdjango/core/handlers/exception.py:5610 ms1.7%
BaseHandler._get_responsedjango/core/handlers/base.py:19910 ms1.7%
user_passes_test.<locals>.decorator.<locals>._view_wrapperdjango/contrib/auth/decorators.py:627 ms1.2%
create_conferenceconfs/views.py:4874 ms0.7%
unique_conference_slugconfs/views.py:475 while Conference.objects.filter(slug=slug).exists():4 ms0.7%
BaseManager._get_queryset_methods.<locals>.create_method.<locals>.manager_methoddjango/db/models/manager.py:874 ms0.7%
BaseManager.get_querysetdjango/db/models/manager.py:1554 ms0.7%
2 smaller frames hidden
user_passes_test.<locals>.decorator.<locals>._view_wrapperdjango/contrib/auth/decorators.py:593 ms0.5%
login_required.<locals>.<lambda>django/contrib/auth/decorators.py:823 ms0.5%
new_method_proxy.<locals>.innerdjango/utils/functional.py:2513 ms0.5%
SimpleLazyObject._setupdjango/utils/functional.py:4043 ms0.5%
AuthenticationMiddleware.process_request.<locals>.<lambda>django/contrib/auth/middleware.py:393 ms0.5%
get_userdjango/contrib/auth/middleware.py:193 ms0.5%
TestCreateConference.test_mastodon_url_is_keptconfs/tests.py:1126 self.client.force_login(self.user)6 ms1.0%
ClientMixin.force_logindjango/test/client.py:8586 ms1.0%
ClientMixin._logindjango/test/client.py:8893 ms0.5%
2 smaller frames hidden
3 smaller frames hidden
Estimated from 586 samples; phase durations are exact. Frames from pytest and pluggy are
hidden
.
Hot lines in your code
|
confs/tests.py:1044
self.user = User.objects.create_user("alice", password="pw")
TestCreateConference.setUp
· Password hashing
|
337 ms |
|
confs/tests.py:1132
self.client.post(reverse("create_conference"), data)
TestCreateConference.test_mastodon_url_is_kept
· Libraries
|
246 ms |
|
confs/tests.py:1126
self.client.force_login(self.user)
TestCreateConference.test_mastodon_url_is_kept
· Database
|
6 ms |
|
confs/views.py:475
while Conference.objects.filter(slug=slug).exists():
unique_conference_slug
· Database
|
4 ms |
|
confs/views.py:498
form.save_m2m() # persist the selected conference_tags (icons)
create_conference
· Database
|
2 ms |
|
confs/tests.py:1133
conference = Conference.objects.get(name="PyCon Test")
TestCreateConference.test_mastodon_url_is_kept
· Database
|
2 ms |
|
confs/views.py:497
conference.save()
create_conference
· Database
|
1 ms |
|
confs/views.py:593
conference_url = request.build_absolute_uri(reverse("conference", kwargs={"conference_slug": conference.slug}))
send_approval_notification
· Libraries
|
1 ms |
Fixtures
Exact setup time| _dj_autoclear_mailbox function | 0.05 ms |
| _template_string_if_invalid_marker function | 0.03 ms |
| _django_db_marker function | 0.03 ms |
| _django_clear_site_cache function | 0.03 ms |
| _django_isolate_apps function | 0.03 ms |
| _django_set_urlconf function | 0.02 ms |
| _live_server_helper function | 0.02 ms |
| monkeypatch function | 0.02 ms |
Database
27 queries · 9 msNo repeated queries.
Biggest pieces of work
|
call setUp
confs/tests.py:1044
|
337 ms |
|
call test body
confs/tests.py:1132
|
262 ms |
|
call _post_teardown
django/test/testcases.py:1243
|
1 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 | 601 ms | Profile |
| 7 hours ago | CI github-actions:test | passed | 1.20 s | Profile |
| 7 hours ago | CI github-actions:test | passed | 1.63 s | Profile |
| 12 hours ago | CI github-actions:test | passed | 1.63 s | Profile |
| 12 hours ago | CI github-actions:test | passed | 680 ms | Run |