Closed jrgriffiniii closed 3 years ago
This is indeed an expected error, as this method is not implemented on the underlying DSpace Class:
This is also going to block all updates for Item metadata, as the following would, then, raise the same error for DSpace::CLI::MetadataArray
(please see https://github.com/pulibrary/dspace-cli/blob/main/dspace/cli/metadata_array.rb#L79).
https://github.com/pulibrary/dspace-cli/tree/issues-120-jrgriffiniii-metadatum-update advances this to the point where metadata records are being updated when tested on the staging environment.
> query = DSpace::CLI::Query.new
> query.find_by_handle('88435/dsp01cr56n3903')
> item = query.results.first
> item.metadata.elements.first.value
=> "Li, Sophia Hsin-Jung"
> item.metadata.elements.first.value = 'test author'
=> "test author"
> item.metadata.elements.first.value
=> "test author"
> item.metadata.update
=> [true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true, true]
> item.metadata.elements.first.value
=> "test author"
When attempting to update individual Metadatum objects, there are failures tracing to the following: