whitfin / stash

A small and user-friendly ETS wrapper for caching in Elixir
MIT License
52 stars 9 forks source link

When persistence is used getting an erlang error #1

Open bfcns opened 7 years ago

bfcns commented 7 years ago

When persistence is used getting an erlang error

dets: file <<"/tmp/my_persistence_file">> not properly closed, repairing ...

ben-pr-p commented 7 years ago

Also getting this - I traced it down to

iex(21) > :dets.from_ets("./my_cache.dets", :my_cache)
{
  :EXIT,
  {
    :function_clause,
    [
      {
        :lists,
        :thing_to_list,
        ["/Users/benpacker/bnc/cosmic/fs_nonode@nohost_97376_520."],
        [file: 'lists.erl', line: 603]
      },
      {:lists, :flatmap, 2, [file: 'lists.erl', line: 1250]},
      {:file_sorter, :next_temp, 1, [file: 'file_sorter.erl', line: 1412]},
      {:file_sorter, :write_run, 2, [file: 'file_sorter.erl', line: 595]},
      {:file_sorter, :fun_run, 5, [file: 'file_sorter.erl', line: 589]},
      {:file_sorter, :do_sort, 5, [file: 'file_sorter.erl', line: 372]},
      {:dets, :do_sort, 5, [file: 'dets.erl', line: 2833]},
      {:dets, :do_finit, 4, [file: 'dets.erl', line: 2208]}
    ]
  }
}

I don't have the ets or erlang knowledge to really understand this error message though