{"action":"closed","issue":{"url":"https://api.github.com/repos/curationexperts/laevigata/issues/1776","repository_url":"https://api.github.com/repos/curationexperts/laevigata","labels_url":"https://api.github.com/repos/curationexperts/laevigata/issues/1776/labels{/name}","comments_url":"https://api.github.com/repos/curationexperts/laevigata/issues/1776/comments","events_url":"https://api.github.com/repos/curationexperts/laevigata/issues/1776/events","html_url":"https://github.com/curationexperts/laevigata/issues/1776","id":354867079,"node_id":"MDU6SXNzdWUzNTQ4NjcwNzk=","number":1776,"title":"Some ETDs won't re-index: control characters","user":{"login":"bess","id":65608,"node_id":"MDQ6VXNlcjY1NjA4","avatar_url":"https://avatars3.githubusercontent.com/u/65608?v=4","gravatar_id":"","url":"https://api.github.com/users/bess","html_url":"https://github.com/bess","followers_url":"https://api.github.com/users/bess/followers","following_url":"https://api.github.com/users/bess/following{/other_user}","gists_url":"https://api.github.com/users/bess/gists{/gist_id}","starred_url":"https://api.github.com/users/bess/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bess/subscriptions","organizations_url":"https://api.github.com/users/bess/orgs","repos_url":"https://api.github.com/users/bess/repos","events_url":"https://api.github.com/users/bess/events{/privacy}","received_events_url":"https://api.github.com/users/bess/received_events","type":"User","site_admin":false},"labels":[{"id":572508644,"node_id":"MDU6TGFiZWw1NzI1MDg2NDQ=","url":"https://api.github.com/repos/curationexperts/laevigata/labels/bug","name":"bug","color":"d63426","default":true},{"id":901001481,"node_id":"MDU6TGFiZWw5MDEwMDE0ODE=","url":"https://api.github.com/repos/curationexperts/laevigata/labels/review","name":"review","color":"e6e6e6","default":false}],"state":"closed","locked":false,"assignee":{"login":"bess","id":65608,"node_id":"MDQ6VXNlcjY1NjA4","avatar_url":"https://avatars3.githubusercontent.com/u/65608?v=4","gravatar_id":"","url":"https://api.github.com/users/bess","html_url":"https://github.com/bess","followers_url":"https://api.github.com/users/bess/followers","following_url":"https://api.github.com/users/bess/following{/other_user}","gists_url":"https://api.github.com/users/bess/gists{/gist_id}","starred_url":"https://api.github.com/users/bess/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bess/subscriptions","organizations_url":"https://api.github.com/users/bess/orgs","repos_url":"https://api.github.com/users/bess/repos","events_url":"https://api.github.com/users/bess/events{/privacy}","received_events_url":"https://api.github.com/users/bess/received_events","type":"User","site_admin":false},"assignees":[{"login":"bess","id":65608,"node_id":"MDQ6VXNlcjY1NjA4","avatar_url":"https://avatars3.githubusercontent.com/u/65608?v=4","gravatar_id":"","url":"https://api.github.com/users/bess","html_url":"https://github.com/bess","followers_url":"https://api.github.com/users/bess/followers","following_url":"https://api.github.com/users/bess/following{/other_user}","gists_url":"https://api.github.com/users/bess/gists{/gist_id}","starred_url":"https://api.github.com/users/bess/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bess/subscriptions","organizations_url":"https://api.github.com/users/bess/orgs","repos_url":"https://api.github.com/users/bess/repos","events_url":"https://api.github.com/users/bess/events{/privacy}","received_events_url":"https://api.github.com/users/bess/received_events","type":"User","site_admin":false}],"milestone":{"url":"https://api.github.com/repos/curationexperts/laevigata/milestones/19","html_url":"https://github.com/curationexperts/laevigata/milestone/19","labels_url":"https://api.github.com/repos/curationexperts/laevigata/milestones/19/labels","id":3581484,"node_id":"MDk6TWlsZXN0b25lMzU4MTQ4NA==","number":19,"title":"Release 2.0.1","description":"Show-stopper issues from v2.0.0","creator":{"login":"mark-dce","id":3064318,"node_id":"MDQ6VXNlcjMwNjQzMTg=","avatar_url":"https://avatars3.githubusercontent.com/u/3064318?v=4","gravatar_id":"","url":"https://api.github.com/users/mark-dce","html_url":"https://github.com/mark-dce","followers_url":"https://api.github.com/users/mark-dce/followers","following_url":"https://api.github.com/users/mark-dce/following{/other_user}","gists_url":"https://api.github.com/users/mark-dce/gists{/gist_id}","starred_url":"https://api.github.com/users/mark-dce/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mark-dce/subscriptions","organizations_url":"https://api.github.com/users/mark-dce/orgs","repos_url":"https://api.github.com/users/mark-dce/repos","events_url":"https://api.github.com/users/mark-dce/events{/privacy}","received_events_url":"https://api.github.com/users/mark-dce/received_events","type":"User","site_admin":false},"open_issues":8,"closed_issues":7,"state":"open","created_at":"2018-08-19T19:34:05Z","updated_at":"2018-08-30T20:59:22Z","due_on":"2018-08-30T07:00:00Z","closed_at":null},"comments":1,"created_at":"2018-08-28T19:17:27Z","updated_at":"2018-08-30T20:59:22Z","closed_at":"2018-08-30T20:59:22Z","author_association":"CONTRIBUTOR","body":"Some ETDs will not re-index because they contain control characters:\n```\nid: \"vm40xr56k\", embargo_id: nil, lease_id: nil>\nirb(main):005:0> etd.update_index\nRSolr::Error::Http: RSolr::Error::Http - 400 Bad Request\nError: 'Illegal character ((CTRL-CHAR, code 14))\n\nURI: http://127.0.0.1:8983/solr/laevigata/update?wt=ruby&softCommit=true\nRequest Headers: {\"Content-Type\"=>\"text/xml\"}\n```\n\nThe problem disappears if we clean up the control characters:\n```\n\nirb(main):006:0> etd.title\n=> [\"E\\u000Efficient Solvers for Nonlinear Problems in Imaging\"]\nirb(main):007:0> etd.title.first.gsub(\"[\\\\x00-\\\\x09\\\\x11\\\\x12\\\\x14-\\\\x1F\\\\x7F]\", \"\")\n=> \"E\\u000Efficient Solvers for Nonlinear Problems in Imaging\"\nirb(main):008:0> etd.title.first.gsub!(/\\p{Cc}/, \"\") \nRuntimeError: can't modify frozen String\n        from (irb):8:in `gsub!'\n        from (irb):8\nirb(main):009:0> etd.title.first.gsub(/\\p{Cc}/, \"\") \n=> \"Efficient Solvers for Nonlinear Problems in Imaging\"\nirb(main):010:0> etd.title.first = etd.title.first.gsub(/\\p{Cc}/, \"\") \nNoMethodError: undefined method `first=' for [\"E\\u000Efficient Solvers for Nonlinear Problems in Imaging\"]:ActiveTriples::Relation\n        from (irb):10\nirb(main):011:0> etd.title = [etd.title.first.gsub(/\\p{Cc}/, \"\")]\n=> [\"Efficient Solvers for Nonlinear Problems in Imaging\"]\nirb(main):012:0> etd.save\nStarting nested indexing of ID=\"qr46r082r\"\nStarting indexing ID=\"qr46r082r\"\nEnding indexing ID=\"qr46r082r\"\nEnding nested indexing of ID=\"qr46r082r\"\n=> true\nirb(main):013:0> etd.update_index\nStarting nested indexing of ID=\"qr46r082r\"\nStarting indexing ID=\"qr46r082r\"\nEnding indexing ID=\"qr46r082r\"\nEnding nested indexing of ID=\"qr46r082r\"\n=> {\"responseHeader\"=>{\"status\"=>0, \"QTime\"=>5}}\n\n```\n\n- [x] Add removal of control characters to sanitize code"}}
{"actor":{"display_login":"bess"}}