view · edit · sidebar · attach · print · history

20130306-debug-news-updater-swissmedicinfo-updater

<< | Index | >>


Summary

  • Debug news updater, fiparsed
  • Update Parser for FI/PI from swissmedicinfo.

Commit

Index


Debug-news-updater

This bug comes from change for swissmedicinfo updater.

Plugin: ODDB::TextInfoPlugin
Error: NoMethodError
Message: undefined method `upcase' for nil:NilClass
Backtrace:
(druby://localhost:10002) /var/www/oddb.org/ext/fiparse/src/textinfo_hpricot.rb:244:in `handle_image'
(druby://localhost:10002) /var/www/oddb.org/ext/fiparse/src/textinfo_hpricot.rb:256:in `insert_image'
(druby://localhost:10002) /var/www/oddb.org/ext/fiparse/src/textinfo_hpricot.rb:218:in `_handle_element'
commit

Debug iksnr extraction

TextInfoPlugin#extract_iksnrs

      languages.each_value do |doc|
        src = doc.iksnrs.to_s.gsub(/[’'´\s]/, "")
        if(match = src.match(/[0-9]{3,5}(?:\s*,\s*[0-9]{3,5})*/u))
          iksnrs.concat match.to_s.split(/\s*,\s*/u)
        end
      end 
[8] 1.9.3-p194(#<ODDB::TextInfoPlugin>)> languages.values[0].iksnrs.to_s
=> "Zulassungsnummer\n57    ‘    969    (Swissmedic).\n "
[9] 1.9.3-p194(#<ODDB::TextInfoPlugin>)> languages.values[1].iksnrs.to_s
=> "Numéro d'autorisation\n57`969 (Swissmedic)\n "

omitt without Number.
(change as whitelist from blacklist)

commit
view · edit · sidebar · attach · print · history
Page last modified on March 06, 2013, at 02:04 PM