view · edit · sidebar · attach · print · history

20130708-add-oddb2xml-zurrose-option-debug-ch-oddb-org-jobs-failures

<< 20130709-update-oddb2xml-zurrose-option | 2013 | 20130703-check-alloga-virbac-sandoz-bbmb-and-debug-invoicer-job-index-therapeutics-exporter >>


Summary

  • Update oddb2xml price from zurrose, Add VAT tag with -p option.

Commits / Patches

on zurrose-path-option brach

Index / Status


Add price from zurrose.dat and VAT code

Price

0120020209ERYTRHOCIN I.V. Trockensub Fl 1g                  001518002010300B08016000000000000000^M
0120020244FERRO-GRADUMET Depottabl 30 Stk                   000895001090300C06071007680316440115^M
0120020273KENDURAL Depottabl 30 Stk                         000492000840100C06071007680353660163^M
0130020646SELSUN Shampoo Susp 60 ml                         000911001650300D10040007680172330414^M
0120020652SELSUN Shampoo Susp 120 ml                        001576002520300D10040007680172330681^M
0130021806EAU PRECIEUSE D?pensier L?s 375 ml                001220001870300D10060000000000000000^M
  • EAN is 83,13 (EAN13
  • Price is 61,6
  • The transfer.dat of zurrose uses ISO-8859-1.

VAT code

DownloadArticle_out.xsd

              <xs:element name="VAT" nillable="false" minOccurs="0">^M
                <xs:annotation>^M
                  <xs:documentation xml:lang="EN">Code for value added tax: 1=full, 2=reduced, 3=excluded</xs:documentation>^M
                  <xs:documentation xml:lang="EN">(galdat 3.0,Table.Field: AC.VATCode)</xs:documentation>^M
                </xs:annotation>^M
                <xs:simpleType>^M
                  <xs:restriction base="xs:int">^M
                    <xs:enumeration value="1"/>^M
                    <xs:enumeration value="2"/>^M
                    <xs:enumeration value="3"/>^M
                  </xs:restriction>^M
                </xs:simpleType>^M
              </xs:element>^M

Added Price from transfer.dat in zurrose, like this:

    <ARTPRI>
      <VDAT>2013-07-08T14:46:47+0900</VDAT>
      <PTYP>ZURROSE</PTYP>
      <PRICE>8.77</PRICE>
    </ARTPRI>
commits

VAT

Updated to use this transfer.dat for VAT.

commit

PATH Option

Added PATH option as temporary debug.

% bundle exec bin/oddb2xml -a nonpharma -p zurrose ~/Downloads/transfer.dat
DE
        Pharma products: 15179
        NonPharma products: 30039
FR
        Pharma products: 15179
        NonPharma products: 30039
commit

on zurrose-path-option brach


Ruby 1.8.7

/usr/local/lib64/ruby/gems/1.8/gems/oddb2xml-1.5.4/lib/oddb2xml/extractor.rb:420:in
`round': wrong number of arguments (1 for 0) (ArgumentError)
        from /usr/local/lib64/ruby/gems/1.8/gems/net-http-persistent-2.8/lib/net/http/faster.rb:15:in
`join'
        from /usr/local/lib64/ruby/gems/1.8/gems/net-http-persistent-2.8/lib/net/http/faster.rb:15:in
`to_proc'
        from /usr/local/lib64/ruby/gems/1.8/gems/oddb2xml-1.5.4/lib/oddb2xml/cli.rb:71:in
`map'
        from /usr/local/lib64/ruby/gems/1.8/gems/oddb2xml-1.5.4/lib/oddb2xml/cli.rb:71:in
`run'
        from /usr/local/lib64/ruby/gems/1.8/gems/oddb2xml-1.5.4/bin/oddb2xml:77
        from /usr/local/bin/oddb2xml:23:in `load'
        from /usr/local/bin/oddb2xml:23

In ruby 1.8.7 cannot takes argment with round.

commit

Debug errors on production

Note

This meas that Program uses too many memory and ruby can not access terminated Object by GC.

Plugin: ODDB::SwissmedicPlugin
Error: NotImplementedError
Message: method `to_ary' called on terminated object (0x000000386fc4e8 flags=0x0 klass=0x0)
Backtrace:
/usr/local/lib/ruby/gems/1.9.1/gems/odba-1.1.0/lib/odba/stub.rb:146:in `+'
/usr/local/lib/ruby/gems/1.9.1/gems/odba-1.1.0/lib/odba/stub.rb:146:in `+'
/var/www/oddb.org/src/model/substance.rb:249:in `_search_keys'
/var/www/oddb.org/src/model/substance.rb:237:in `search_keys'
(eval):3:in `block in proc_resolve_search_term'
/usr/local/lib/ruby/gems/1.9.1/gems/odba-1.1.0/lib/odba/index.rb:146:in `call'
...
view · edit · sidebar · attach · print · history
Page last modified on June 14, 2016, at 05:07 PM