Opened 4 years ago

Closed 6 weeks ago

Last modified 6 weeks ago

#17215 closed Bug (fixed)

runtests doesn't clean up all temp files all the time

Reported by: kmtracey Owned by: nobody
Component: Testing framework Version:
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

http://ci.djangoproject.com/job/Django/ builds started failing yesterday due to too many files in /tmp:

http://ci.djangoproject.com/job/Django/461/database=sqlite3,python=python2.5/console

There were nearly 300 /tmp/django_<random> directories that had accumulated, and looking at my own machine's tmp directory I see a bunch of other /tmp/tmp<random> directories that have accumulated in just the last day.

Change History (14)

comment:1 follow-up: Changed 4 years ago by aaugustin

  • Triage Stage changed from Unreviewed to Accepted

I cleaned /tmp on the CI server, but that bug should be fixed nonetheless.

comment:2 in reply to: ↑ 1 Changed 4 years ago by kmtracey

Replying to aaugustin:

I cleaned /tmp on the CI server, but that bug should be fixed nonetheless.

Thanks! And oh yes we should fix the tests to not require periodic /tmp cleanup.

It seems a clean test run leaves behind 47 (!) /tmp/tmp<random> directories. 47*15 configs on the ci server is 705 directories accumulating per commit. That means less than 50 commits before we again hit the 32,000 file in the directory limit....

comment:3 Changed 4 years ago by kmtracey

  • Owner changed from nobody to kmtracey

comment:4 Changed 4 years ago by kmtracey

In [17094]:

Refs #17215: Avoid generating 47 leftover tmp dirs during a clean test run.

comment:5 Changed 4 years ago by kmtracey

  • Owner changed from kmtracey to nobody

r17094 was a quick way to get rid of the leftover tmp dirs from a clean test run; if anyone has a better approach/idea please speak up.

There were also some leftover django<random> dirs -- these I think come from runs that don't complete successfully. I'm not sure how to approach cleaning them up.

comment:6 Changed 3 years ago by aaugustin

#19206 was a duplicate.

comment:7 Changed 15 months ago by Claude Paroz <claude@…>

In 1d9596025e53a33763d9dbb61e7dda015ec60b25:

Ensured cache tests do not leak temp dirs

Refs #17215.

comment:8 Changed 15 months ago by Claude Paroz <claude@…>

In 6015083e9d156e30c8cd5e200317f4c0f10f4abf:

[1.7.x] Ensured cache tests do not leak temp dirs

Refs #17215.
Backport of 1d9596025e from master.

comment:9 Changed 15 months ago by Claude Paroz <claude@…>

In 809362518d6dbb7ca989b32ed97b39f6156563b9:

Created import-time test temp dirs in known location

Refs #17215. In the same spirit as 5de31cb8cb.

comment:10 Changed 15 months ago by Claude Paroz <claude@…>

In 3619518c9bb8483ed911e987554ee5ae599f78d3:

[1.7.x] Created import-time test temp dirs in known location

Refs #17215. In the same spirit as 5de31cb8cb.
Backport of 809362518d from master.

comment:11 Changed 15 months ago by Claude Paroz <claude@…>

In c38e47bec02d67fe9497fb384fafb5f2806cff0b:

[1.6.x] Created import-time test temp dirs in known location

Refs #17215. In the same spirit as 5de31cb8cb.
Backport of 809362518d from master.

comment:12 Changed 15 months ago by claudep

We shouldn't get any more leaking temporary directories from the test suite (running without failures or soft-interrupted by Ctrl-C), but this needs to be confirmed. And of course, testing that any failure in one of the ~7000 current tests don't leak directories is quite impossible.

comment:13 Changed 6 weeks ago by timgraham

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

/tmp on the CI servers has stayed clean for some time.

comment:14 Changed 6 weeks ago by aaugustin

I should have closed this bug with 934400759de817471ff37d736686201d7ae34e82.

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