sul-dlss / dlme

Digital Library of the Middle East web application, based on Spotlight
https://dlmenetwork.org/
Other
20 stars 2 forks source link

Investigate undefined method to_global_id error in DeleteResourceJob #566

Closed aaron-collier closed 5 years ago

aaron-collier commented 5 years ago

"undefined method `to_global_id' for nil:NilClass"

Found in this log: https://us-west-2.console.aws.amazon.com/cloudwatch/home?region=us-west-2#logEventViewer:group=dlme-worker;stream=sidekiq/sidekiq/c33235eb-4d23-496b-b0c4-ece09290ad35;start=2019-09-17T01:35:02Z

jcoyne commented 5 years ago

Full trace:

E, [2019-09-17T07:30:44.376085 #1] ERROR -- : [ActiveJob] [DeleteResourcesJob] [2cdc9052-4d8c-45d3-b54e-dda89a188187] Error performing DeleteResourcesJob (Job ID: 2cdc9052-4d8c-45d3-b54e-dda89a188187) from Sidekiq(dlme_production_default) in 141.25ms: NoMethodError (undefined method `to_global_id' for nil:NilClass):
07:30:44
/opt/app/jobs/delete_resources_job.rb:26:in `remove_resource'

07:30:44
/opt/app/jobs/delete_resources_job.rb:12:in `block in perform'
07:30:44
/opt/app/jobs/delete_resources_job.rb:11:in `each'
07:30:44
/opt/app/jobs/delete_resources_job.rb:11:in `each_with_index'
07:30:44
/opt/app/jobs/delete_resources_job.rb:11:in `perform'
/opt/app/jobs/delete_resources_job.rb:11:in `perform'