#34452 closed Bug (duplicate)

Report the correct port when using port 0 with runserver

Reported by: Gergely Kalmár Owned by: nobody
Component: Core (Management commands) Version: 4.1
Severity: Normal Keywords:
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

When starting runserver on port 0 the operating system assigns an available random-ish port number, however, this port number is not shown in the information section:

$ ./manage runserver 0
Performing system checks...

System check identified no issues (0 silenced).
March 31, 2023 - 20:10:05
Django version 4.1.7, using settings '...'
Starting development server at http://127.0.0.1:0/
Quit the server with CONTROL-C.

Note that the shown development server URL is invalid – the actual port used is not going to be zero.

Change History (1)

comment:1 by Mariusz Felisiak, 18 months ago

Component: UncategorizedCore (Management commands)
Resolution: duplicate
Status: newclosed

Duplicate of #32813.

Note: See TracTickets for help on using tickets.
Back to Top