-
-
Notifications
You must be signed in to change notification settings - Fork 942
Closed
Milestone
Description
While investigating further problems on 9.1.7.0 related to #4767 I came accross a weird behavior of YAML::Store which does not print out correct unicode characters if the transaction is in readonly.
This is a small script that shows the problem
$ ruby --version
jruby 9.1.7.0 (2.3.1) 2017-01-11 68056ae OpenJDK 64-Bit Server VM 25.141-b16 on 1.8.0_141-b16 +jit [linux-x86_64]
$ cat pstore_test.rb
require 'yaml/store'
puts 'PStore'
store = PStore.new('test.pstore')
store.transaction{ store['test'] = 'Tütü' }
print 'Correct: '
puts store.transaction{ store['test'] }
print 'Correct: '
puts store.transaction(true){ store['test'] }
puts 'YAML'
store = YAML::Store.new('test.yaml')
store.transaction{ store['test'] = 'Tütü' }
print 'Correct: '
puts store.transaction{ store['test'] }
print 'Incorrect: '
puts store.transaction(true){ store['test'] }
$ rm test.*
$ ruby pstore_test.rb
PStore
Correct: Tütü
Correct: Tütü
YAML
Correct: Tütü
Incorrect: Tütü
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels