I am using Tempfile to store temporary data on disk.
The documentation I’ve read (The Ruby Way, p353) states:
“The new method (Tempfile.new(“seed_str”)) takes a basename as a seed
string, and concatenates onto it the process id and a unique
however, I am testing my web app, and request after request, I end up
with the exact same filename…
I worked around this by actually adding a random number within the
rand_str = rand
however, I am sure there must be a way to get Tempfile to work
and return an actual unique name?
thanks for your help,