We're updating the issue view to help you get more done. 

Download files are not always removed from /tmp directory after generation

Description

We currently have some code that is intended to remove download files from the /tmp folder after the download is generated.

However, this code does not always work, causing the /tmp folder to fill up. This has always been the case, but it is an even bigger problem than it was previously because, now that we include images in downloads, a single work with images can take up 10% of the allotted space.

Testing

Not really testable. We can confirm downloads still work, though – probably using a new work to make sure it’s not only working because it’s cached.

Notes

redsummernight [17:11]

Please note that "after" filters are executed only after a successful action, but not when an exception is raised in the request cycle.
"around" filters are responsible for running their associated actions by yielding, similar to how Rack middlewares work.

if we use around_action with begin/ensure we can force /tmp cleanup to run no matter what

redsummernight [17:12]
https://guides.rubyonrails.org/action_controller_overview.html#after-filters-and-around-filters

Environment

Status

Assignee

redsummernight

Reporter

Sarken

Roadmap

Export

Priority

High

Affects versions

0.9.237

Fix versions

Components

BackEnd

Difficulty

Medium

Milestone

Internal 0.9