-
Notifications
You must be signed in to change notification settings - Fork 5
Closed
Description
Summary or User Story
A bunch of PDFs failed to preserve because of we're not sure why, but it seems constrained to that couple day timeline and these resources. We should re-generate their derivatives
Acceptance Criteria
- The affected PDFs are regenerated.
First step
Get the IDs of all the PDFs.
#7023 has a script for finding the bad PDFs:
csp = ChangeSetPersister.default
qs = csp.query_service
pos = qs.custom_queries.find_by_property(property: :preserved_object_id, value: [], model: PreservationObject, created_at: 2.months.ago..Time.now); nil
bad_pos = pos.select do |po|
resource = Wayfinder.for(po).preserved_resource
(resource.try(:preservation_targets) || []).any? do |file_metadata|
node = po.binary_node_for(file_metadata)
node && node.checksum[0].md5 != file_metadata.checksum[0].md5
end
end; nil#7025 is a blocker for this ticket.
Resulting in PreserveResourceJob failing
Backtrace
line 84 of [PROJECT_ROOT]/app/services/preserver.rb: Preserver#preserve_binary_node
line 42 of [PROJECT_ROOT]/app/services/preserver.rb: block in Preserver#preserve_binary_content
line 40 of [PROJECT_ROOT]/app/services/preserver.rb: Array#each
Reactions are currently unavailable