Code

Opened 7 months ago

Closed 5 months ago

Last modified 5 months ago

#21172 closed Bug (fixed)

have LiveServerThread follow the semantics of threading.Thread.join()

Reported by: ldd Owned by: unaizalakain
Component: Testing framework Version: master
Severity: Normal Keywords: live server, test server, live wsgi
Cc: unai@… Triage Stage: Ready for checkin
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

File: django/test/testcases.py

The semantics of threading.Thread.join() are "wait for this thread to end" and nothing more.

However, LiveServerThread redefines these semantics to first cause this thread to end and then wait for this thread to end.

This harms reusability, because someone calling join() on this object would expect the regular semantics and not the Django-specific redefinition. I've encountered this bug in 1.5 but visual inspection of master shows that at the time of writing this ticket it is present there too.

Attachments (0)

Change History (10)

comment:1 Changed 7 months ago by unaizalakain

  • Cc unai@… added
  • Needs documentation unset
  • Needs tests unset
  • Owner changed from nobody to unaizalakain
  • Patch needs improvement unset
  • Status changed from new to assigned
  • Triage Stage changed from Unreviewed to Accepted

comment:2 Changed 7 months ago by unaizalakain

  • Keywords live server, test server, live wsgi added

comment:4 Changed 6 months ago by timo

  • Easy pickings unset

comment:6 Changed 6 months ago by unaizalakain

  • Triage Stage changed from Accepted to Ready for checkin

comment:7 Changed 6 months ago by unaizalakain

  • Triage Stage changed from Ready for checkin to Accepted

comment:8 Changed 5 months ago by loic84

  • Triage Stage changed from Accepted to Ready for checkin

Other than the comment I left which can be addressed at commit time, LGTM.

comment:9 Changed 5 months ago by Anssi Kääriäinen <akaariai@…>

  • Resolution set to fixed
  • Status changed from assigned to closed

In 1830f50493cae042dac11957af986b0fd84f889f:

Merge pull request #1743 from unaizalakain/ticket_21172

Fixed #21172 -- have LiveServerThread follow the semantics of threading.Thread.join()

comment:10 Changed 5 months ago by Anssi Kääriäinen <akaariai@…>

In 3c10d1e64faeb67b41e7aa501b21252e357a4564:

Removed useless comment. Refs #21172

Add Comment

Modify Ticket

Change Properties
<Author field>
Action
as closed
as The resolution will be set. Next status will be 'closed'
The resolution will be deleted. Next status will be 'new'
Author


E-mail address and user name can be saved in the Preferences.

 
Note: See TracTickets for help on using tickets.