Hi,
i don’t find any useful information about my issue and i hope someone
can help me out.
please correct me if i’m wrong…
i18n::backend::cache uses the cache_key method to create a key for
caching, right?!
on line 70 of lib/i18n/backend/cache.rb i find:
hash = RUBY_VERSION >= “1.8.7” ? args.hash : args.inspect
therefore it (only) uses args.hash to generate the key for caching if
i’m using ruby >= 1.8.7.
Well i’am using: ruby 1.8.7 (2008-08-11 patchlevel 72) [x86_64-linux]
on a debian machine.
My app has many translations for 3 different locales.
Actually, the i18n’s cache implementation produces many collisions for
my app and therefore i have many german translations on the english
version of my app.
Well, i think: if cache_key only uses args.hash to push the
translation into the cache … and 2 keys share the same hash… of
course there is a collision.
Am i missing a point?
To help me out i’m currently using a modified version of
i18n::backend:cache that only differs to the default cache
implementation by:
hash = args.inspect
and therefore acts like with ruby < 1.8.7 … any help ? do i have to
open an issue on github - or am i wrong ?