I assume that you are using spree_active_shipping, as this is similar to the cache id for the quote sent by UPS. This will happen when someone creates an order in which there are many line items. With enough positions, this of course will create a very large file name for the cache, which will give you an error.
One option is to use memcache or redis for your Rails.cache instead of using the file system cache. Another would be to change the algorithm that the cache_key generates in the / models / active _shipping.rb application in the spree_active_shipping gem.
The last option would probably be the best, and you could just create the generated cache key via a hash, like MD5 or SHA1. This way you get the predicted cache key length.
Indeed, this should be fixed in spree_active_shipping, although it should not generate unpredictably long cache keys, even if you use the keystore, this lost memory.
source share