This project is archived and is in readonly mode.
ActiveSupport::Cache::FileStore: undefined method `ord' for nil:NilClass
-
Aditya Sanghi
- Importance changed from to Low
Can you please submit a failing test and a patch as per the contributor's guide?
It wasn't very clear what the scenario in which error happens or steps to reproduce the error.
-
Santiago Pastorino
- State changed from new to open
- Milestone set to 3.0.2
- Assigned user set to Santiago Pastorino
Igor can you provide a patch following http://rails.lighthouseapp.com/projects/8994/sending-patches or at least a failing test case?.
Thanks. -
Denis Odorcic
Attached is a patch and failing test.
The issue was that with FileStore, the key is the filename, which was being escaped properly, but not unescaped. This only presents itself when the cache is FileStore, the key contains characters that get escaped, and expire_fragment is called with a Regular expression.
The fix that Igor provided above does fix the issue, however the escaping and unescaping is essentially the same method used by CGI, so my patch uses that instead.
If you think it should go back to how it was and just use Igor's fix, that's fine. -
Denis Odorcic
- Tag changed from activesupport, caching, file_store, rails3.0.0, rails3.0.1 to activesupport, caching, file_store, patch, rails3.0.0, rails3.0.1
-
Santiago Pastorino
Please use Rack::Utils.escape and unscape instead of CGI one.
-
Denis Odorcic
I've attached an updated patch using Rack::Utils. Thanks!
-
Santiago Pastorino
- State changed from open to verified
-
Repository
- State changed from verified to committed
(from [c452d734f202fef3560173cd10701be8ff1a057b]) Fix FileStore cache incorrectly regenerating its key from a pathname when a regexp is used in expire_fragment
[#5850 ActiveSupport::Cache::FileStore: undefined method `ord' for nil:NilClass state:committed]
Signed-off-by: Santiago Pastorino santiago@wyeworks.com
https://github.com/rails/rails/commit/c452d734f202fef3560173cd10701... -
Repository
(from [ad2c0bdb9b94c79553e76f6b2db6fb23ccff6a97]) Fix FileStore cache incorrectly regenerating its key from a pathname when a regexp is used in expire_fragment
[#5850 ActiveSupport::Cache::FileStore: undefined method `ord' for nil:NilClass state:committed]
Signed-off-by: Santiago Pastorino santiago@wyeworks.com
https://github.com/rails/rails/commit/ad2c0bdb9b94c79553e76f6b2db6f...
