[Bug 429115] [NEW] xmlsimple loads twice when active_support required
Joshua Swink
joshua.swink at gmail.com
Mon Sep 14 00:07:34 UTC 2009
Public bug reported:
Binary package hint: rails
When you require 'active_support', xmlsimple is loaded twice. This
results in about a page full of warnings.
The cause:
- activesupport/lib/active_support/vendor.rb requires 'lib/xmlsimple.rb'
- activesupport/lib/active_support/core_ext/hash/conversions.rb requires 'xmlsimple.rb'
In package libxml-simple-ruby, these files both exist. lib/xmlsimple.rb
is a short file that simply loads xmlsimple.rb. Since Ruby sees them as
distinct files, it loads each one when requested by the above
activesupport files.
It appears that lib/xmlsimple.rb is the orphan here and should not be
loaded. Changing vendor.rb to require 'xmlsimple.rb' might be a good
solution.
The warnings that are printed (this is a result of using active-ldap)
/usr/lib/ruby/1.8/xmlsimple.rb:20: warning: method redefined; discarding old initialize
/usr/lib/ruby/1.8/xmlsimple.rb:31: warning: method redefined; discarding old save_storable
/usr/lib/ruby/1.8/xmlsimple.rb:41: warning: method redefined; discarding old restore_storable
/usr/lib/ruby/1.8/xmlsimple.rb:56: warning: method redefined; discarding old save_mem_share
/usr/lib/ruby/1.8/xmlsimple.rb:67: warning: method redefined; discarding old restore_mem_share
/usr/lib/ruby/1.8/xmlsimple.rb:77: warning: method redefined; discarding old save_mem_copy
/usr/lib/ruby/1.8/xmlsimple.rb:87: warning: method redefined; discarding old restore_mem_copy
/usr/lib/ruby/1.8/xmlsimple.rb:102: warning: method redefined; discarding old get_cache_filename
/usr/lib/ruby/1.8/xmlsimple.rb:114: warning: method redefined; discarding old get_from_memory_cache
/usr/lib/ruby/1.8/xmlsimple.rb:128: warning: method redefined; discarding old initialize
/usr/lib/ruby/1.8/xmlsimple.rb:149: warning: method redefined; discarding old xml_in
/usr/lib/ruby/1.8/xmlsimple.rb:201: warning: redefine xml_in
/usr/lib/ruby/1.8/xmlsimple.rb:212: warning: method redefined; discarding old xml_out
/usr/lib/ruby/1.8/xmlsimple.rb:257: warning: redefine xml_out
/usr/lib/ruby/1.8/xmlsimple.rb:275: warning: already initialized constant KNOWN_OPTIONS
/usr/lib/ruby/1.8/xmlsimple.rb:280: warning: already initialized constant DEF_KEY_ATTRIBUTES
/usr/lib/ruby/1.8/xmlsimple.rb:281: warning: already initialized constant DEF_ROOT_NAME
/usr/lib/ruby/1.8/xmlsimple.rb:282: warning: already initialized constant DEF_CONTENT_KEY
/usr/lib/ruby/1.8/xmlsimple.rb:283: warning: already initialized constant DEF_XML_DECLARATION
/usr/lib/ruby/1.8/xmlsimple.rb:284: warning: already initialized constant DEF_ANONYMOUS_TAG
/usr/lib/ruby/1.8/xmlsimple.rb:285: warning: already initialized constant DEF_FORCE_ARRAY
/usr/lib/ruby/1.8/xmlsimple.rb:286: warning: already initialized constant DEF_INDENTATION
/usr/lib/ruby/1.8/xmlsimple.rb:287: warning: already initialized constant DEF_KEY_TO_SYMBOL
/usr/lib/ruby/1.8/xmlsimple.rb:298: warning: method redefined; discarding old normalize_option_names
/usr/lib/ruby/1.8/xmlsimple.rb:319: warning: method redefined; discarding old handle_options
/usr/lib/ruby/1.8/xmlsimple.rb:461: warning: method redefined; discarding old collapse
/usr/lib/ruby/1.8/xmlsimple.rb:523: warning: method redefined; discarding old collapse_text_node
/usr/lib/ruby/1.8/xmlsimple.rb:544: warning: method redefined; discarding old fold_arrays
/usr/lib/ruby/1.8/xmlsimple.rb:568: warning: method redefined; discarding old fold_array
/usr/lib/ruby/1.8/xmlsimple.rb:598: warning: method redefined; discarding old fold_array_by_name
/usr/lib/ruby/1.8/xmlsimple.rb:624: warning: method redefined; discarding old collapse_content
/usr/lib/ruby/1.8/xmlsimple.rb:644: warning: method redefined; discarding old merge
/usr/lib/ruby/1.8/xmlsimple.rb:689: warning: method redefined; discarding old force_array?
/usr/lib/ruby/1.8/xmlsimple.rb:706: warning: method redefined; discarding old get_attributes
/usr/lib/ruby/1.8/xmlsimple.rb:716: warning: method redefined; discarding old has_mixed_content?
/usr/lib/ruby/1.8/xmlsimple.rb:727: warning: method redefined; discarding old set_var
/usr/lib/ruby/1.8/xmlsimple.rb:733: warning: method redefined; discarding old get_var
/usr/lib/ruby/1.8/xmlsimple.rb:750: warning: method redefined; discarding old value_to_xml
/usr/lib/ruby/1.8/xmlsimple.rb:861: warning: method redefined; discarding old scalar
/usr/lib/ruby/1.8/xmlsimple.rb:874: warning: method redefined; discarding old hash_to_array
/usr/lib/ruby/1.8/xmlsimple.rb:893: warning: method redefined; discarding old escape_value
/usr/lib/ruby/1.8/xmlsimple.rb:902: warning: method redefined; discarding old normalise_space
/usr/lib/ruby/1.8/xmlsimple.rb:911: warning: method redefined; discarding old empty
/usr/lib/ruby/1.8/xmlsimple.rb:930: warning: method redefined; discarding old node_to_text
/usr/lib/ruby/1.8/xmlsimple.rb:951: warning: method redefined; discarding old parse
/usr/lib/ruby/1.8/xmlsimple.rb:963: warning: method redefined; discarding old find_xml_file
/usr/lib/ruby/1.8/xmlsimple.rb:993: warning: method redefined; discarding old load_xml_file
/usr/lib/ruby/1.8/xmlsimple.rb:1003: warning: method redefined; discarding old put_into_cache
** Affects: rails (Ubuntu)
Importance: Undecided
Status: New
--
xmlsimple loads twice when active_support required
https://bugs.launchpad.net/bugs/429115
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
--
ubuntu-bugs mailing list
ubuntu-bugs at lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs
More information about the universe-bugs
mailing list