curationexperts / alexandria-legacy

Alexandria Digital Research Library - http://alexandria.ucsb.edu
Other
6 stars 1 forks source link

Error ingesting cylinders on sandbox #630

Closed jcoyne closed 8 years ago

jcoyne commented 8 years ago
$ RAILS_ENV=production bin/ingest-cylinders /data/metadata-cylinders/cylinders_samples_only_marc.xml /data/objects-cylinders/
Loading environment...
Starting import...
2016-03-01T03:49:16+00:00  INFO traject (2.3.0) executing with: `-c lib/traject/audio_config.rb -s files_directory=/data/objects-cylinders/ /data/metadata-cylinders/cylinders_samples_only_marc.xml`
2016-03-01T03:49:16+00:00  INFO Reading from /data/metadata-cylinders/cylinders_samples_only_marc.xml
2016-03-01T03:49:16+00:00  INFO    Indexer with 0 processing threads, reader: Traject::MarcReader and writer: ObjectFactoryWriter
    WARNING: Unable to determine contributor role.  Expected to find subfield 'e' or '4', but subfield wasn't found.  MARC field: 100
  Updated Audio recording f31v5cjb (002556253)
    WARNING: Unable to determine contributor role.  Expected to find subfield 'e' or '4', but subfield wasn't found.  MARC field: 100
2016-03-01T03:49:20+00:00 FATAL Traject::CommandLine: Unexpected exception, terminating execution: #<Ldp::BadRequest: Encountered " "<" "< "" at line 27, column 40.
Was expecting one of:
    <IRIref> ...
    <PNAME_NS> ...
    <PNAME_LN> ...
    <BLANK_NODE_LABEL> ...
    <VAR1> ...
    <VAR2> ...
    "true" ...
    "false" ...
    <INTEGER> ...
    <DECIMAL> ...
    <DOUBLE> ...
    <INTEGER_POSITIVE> ...
    <DECIMAL_POSITIVE> ...
    <DOUBLE_POSITIVE> ...
    <INTEGER_NEGATIVE> ...
    <DECIMAL_NEGATIVE> ...
    <DOUBLE_NEGATIVE> ...
    <STRING_LITERAL1> ...
    <STRING_LITERAL2> ...
    <STRING_LITERAL_LONG1> ...
    <STRING_LITERAL_LONG2> ...
    "(" ...
    <NIL> ...
    "[" ...
    <ANON> ...
    >
/opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/ldp-0.4.1/lib/ldp/client/methods.rb:121:in `block in check_for_errors': Encountered " "<" "< "" at line 27, column 40. (Ldp::BadRequest)
Was expecting one of:
    <IRIref> ...
    <PNAME_NS> ...
    <PNAME_LN> ...
    <BLANK_NODE_LABEL> ...
    <VAR1> ...
    <VAR2> ...
    "true" ...
    "false" ...
    <INTEGER> ...
    <DECIMAL> ...
    <DOUBLE> ...
    <INTEGER_POSITIVE> ...
    <DECIMAL_POSITIVE> ...
    <DOUBLE_POSITIVE> ...
    <INTEGER_NEGATIVE> ...
    <DECIMAL_NEGATIVE> ...
    <DOUBLE_NEGATIVE> ...
    <STRING_LITERAL1> ...
    <STRING_LITERAL2> ...
    <STRING_LITERAL_LONG1> ...
    <STRING_LITERAL_LONG2> ...
    "(" ...
    <NIL> ...
    "[" ...
    <ANON> ...

    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/ldp-0.4.1/lib/ldp/client/methods.rb:119:in `tap'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/ldp-0.4.1/lib/ldp/client/methods.rb:119:in `check_for_errors'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/ldp-0.4.1/lib/ldp/client/methods.rb:112:in `block in patch'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:166:in `instrument'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/ldp-0.4.1/lib/ldp/client/methods.rb:104:in `patch'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/caching_connection.rb:29:in `patch'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/sparql_insert.rb:11:in `execute'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/ldp_resource_service.rb:18:in `update'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/persistence.rb:170:in `execute_sparql_update'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/persistence.rb:157:in `update_record'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/indexing.rb:60:in `update_record'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/callbacks.rb:243:in `block (2 levels) in update_record'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:117:in `call'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:555:in `block (2 levels) in compile'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in `call'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:92:in `__run_callbacks__'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:778:in `_run_save_callbacks'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:81:in `run_callbacks'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/callbacks.rb:243:in `block in update_record'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:117:in `call'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:555:in `block (2 levels) in compile'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:505:in `call'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:92:in `__run_callbacks__'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:778:in `_run_update_callbacks'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/callbacks.rb:81:in `run_callbacks'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/callbacks.rb:242:in `update_record'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/persistence.rb:141:in `create_or_update'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/persistence.rb:31:in `save!'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/active-fedora-9.9.0/lib/active_fedora/validations.rb:56:in `save!'
    from /opt/alexandria-v2/releases/20160301011446/lib/importer/factory/object_factory.rb:31:in `update'
    from /opt/alexandria-v2/releases/20160301011446/lib/importer/factory/object_factory.rb:15:in `block in run'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:164:in `block in instrument'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/notifications/instrumenter.rb:20:in `instrument'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/activesupport-4.2.5.1/lib/active_support/notifications.rb:164:in `instrument'
    from /opt/alexandria-v2/releases/20160301011446/lib/importer/factory/object_factory.rb:13:in `run'
    from /opt/alexandria-v2/releases/20160301011446/lib/object_factory_writer.rb:77:in `build_object'
    from /opt/alexandria-v2/releases/20160301011446/lib/object_factory_writer.rb:57:in `put'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/traject-2.3.0/lib/traject/indexer.rb:479:in `block (2 levels) in process'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/traject-2.3.0/lib/traject/thread_pool.rb:114:in `maybe_in_thread_pool'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/traject-2.3.0/lib/traject/indexer.rb:474:in `block in process'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/marc-1.0.0/lib/marc/xml_parsers.rb:37:in `yield_record'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/marc-1.0.0/lib/marc/xml_parsers.rb:72:in `end_element_namespace'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/nokogiri-1.6.7.2/lib/nokogiri/xml/sax/parser.rb:95:in `parse_with'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/nokogiri-1.6.7.2/lib/nokogiri/xml/sax/parser.rb:95:in `parse_io'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/nokogiri-1.6.7.2/lib/nokogiri/xml/sax/parser.rb:82:in `parse'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/marc-1.0.0/lib/marc/xml_parsers.rb:112:in `each'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/traject-2.3.0/lib/traject/marc_reader.rb:86:in `each'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/traject-2.3.0/lib/traject/indexer.rb:444:in `process'
    from /opt/alexandria-v2/shared/bundle/ruby/2.3.0/gems/traject-2.3.0/lib/traject/command_line.rb:67:in `execute'
    from bin/ingest-cylinders:33:in `<main>'
jcoyne commented 8 years ago

The SPARQL being issued was:

QUERY IS DELETE { <> <http://purl.org/dc/terms/created> ?change . }
  WHERE { <> <http://purl.org/dc/terms/created> ?change . } ;
DELETE { <http://127.0.0.1:8080/fedora/rest/prod/f3/hd/7t/96/f3hd7t96#timespan_g74089820> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> ?change . }
  WHERE { <http://127.0.0.1:8080/fedora/rest/prod/f3/hd/7t/96/f3hd7t96#timespan_g74089820> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> ?change . } ;
DELETE { <> <http://purl.org/dc/terms/issued> ?change . }
  WHERE { <> <http://purl.org/dc/terms/issued> ?change . } ;
DELETE { <#timespan_g63802480> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> ?change . }
  WHERE { <#timespan_g63802480> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> ?change . } ;
DELETE { <#timespan_g63802480> <http://www.europeana.eu/schemas/edm/begin> ?change . }
  WHERE { <#timespan_g63802480> <http://www.europeana.eu/schemas/edm/begin> ?change . } ;
DELETE { <> <http://purl.org/dc/terms/language> ?change . }
  WHERE { <> <http://purl.org/dc/terms/language> ?change . } ;
DELETE { <> <http://purl.org/dc/terms/type> ?change . }
  WHERE { <> <http://purl.org/dc/terms/type> ?change . } ;
DELETE { <> <http://id.loc.gov/vocabulary/identifiers/issue-number> ?change . }
  WHERE { <> <http://id.loc.gov/vocabulary/identifiers/issue-number> ?change . } ;
DELETE { <> <http://id.loc.gov/vocabulary/identifiers/matrix-number> ?change . }
  WHERE { <> <http://id.loc.gov/vocabulary/identifiers/matrix-number> ?change . } ;
DELETE { <> <http://id.loc.gov/vocabulary/relators/prf> ?change . }
  WHERE { <> <http://id.loc.gov/vocabulary/relators/prf> ?change . } ;
INSERT {
<http://127.0.0.1:8080/fedora/rest/prod/f3/hd/7t/96/f3hd7t96#timespan_g74089820> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.europeana.eu/schemas/edm/TimeSpan> .
<> <http://purl.org/dc/terms/created> <http://127.0.0.1:8080/fedora/rest/prod/f3/hd/7t/96/f3hd7t96#timespan_g74089820> .
<#timespan_g63802480> <http://www.w3.org/1999/02/22-rdf-syntax-ns#type> <http://www.europeana.eu/schemas/edm/TimeSpan> .
<#timespan_g63802480> <http://www.europeana.eu/schemas/edm/begin> "1905"^^<http://www.w3.org/2001/XMLSchema#integer> .
<> <http://purl.org/dc/terms/issued> <#timespan_g63802480> .
<> <http://purl.org/dc/terms/language> <http://id.loc.gov/vocabulary/iso639-2/   > .
<> <http://purl.org/dc/terms/type> <http://id.loc.gov/vocabulary/resourceTypes/aum> .
<> <http://id.loc.gov/vocabulary/identifiers/issue-number> "Edison Gold Moulded Record : 8946" .
<> <http://id.loc.gov/vocabulary/identifiers/matrix-number> " : " .
<> <http://id.loc.gov/vocabulary/relators/prf> <http://ucsb.curationexperts.com/authorities/people/58a568dd-e8dc-4cb6-b04e-892b7eae5f46> .
<> <http://id.loc.gov/vocabulary/relators/prf> <http://ucsb.curationexperts.com/authorities/organizations/c59437b4-b718-4873-94fb-71eb6cd05c90> .
}
 WHERE { }
jcoyne commented 8 years ago

This appears to be an invalid language triple: <> <http://purl.org/dc/terms/language> <http://id.loc.gov/vocabulary/iso639-2/ > .