LibraryOfCongress / bagit-python

Work with BagIt packages from Python.
http://libraryofcongress.github.io/bagit-python
218 stars 85 forks source link

--validate fails if algorithm name is not lowercase #83

Closed ruebot closed 7 years ago

ruebot commented 7 years ago

Scenario:

  1. $ bagit.py --validate plant 2016-12-14 10:38:36,662 - INFO - plant is invalid: Missing manifest file
  2. $ cd plant && mv manifest-SHA1.txt manifest-sha1.txt && cd ..
  3. $ bagit.py --validate plant 2016-12-14 11:05:31,219 - INFO - plant is valid

This is happening if a bag is created with the bagit-java library and validated with this library.

Might be somewhat related to #81:

Implementations SHOULD issue a warning when multiple manifests are present which differ only in case or normalization form.

acdha commented 7 years ago

What version of bagit-java are you using? I noticed that this problem doesn't reproduce with bagit-java 4.x which makes me wonder whether we need to fix the 5.x branch to be in line with other implementations.

ruebot commented 7 years ago

@acdha 5.0.0-BETA - https://github.com/fcrepo4-labs/fcrepo-import-export/blob/master/pom.xml#L23

acdha commented 7 years ago

Hmmm, if this is only failing in the 5.x beta versions I might reverse my earlier comment and suggest that we just change the Java library to lower-case it.

ruebot commented 7 years ago

@acdha heh. Want me to open up an issue over there too?

acdha commented 7 years ago

Let me blow the cobwebs off of my Java and make a patch

ruebot commented 7 years ago

Thank you! Very much appreciated :smile:

acdha commented 7 years ago

@ruebot At first glance, it seems @johnscancella already fixed this in https://github.com/LibraryOfCongress/bagit-java/commit/af513013c7ca7398b290450f55afcf8f8708b5a7. That's in 5.0.0-BETA but not any of the newer tags — seems like it'd be easiest to switch to https://github.com/LibraryOfCongress/bagit-java/releases/tag/v5.0.0-RC10

ruebot commented 7 years ago

@acdha oh, that's great! That's for looking into it,a nd @johnscancella thanks for address it!

ruebot commented 7 years ago

@acdha @johnscancella sorry to bug y'all again, do you publish SNAPSHOT artifacts anywhere for bagit-java?

ruebot commented 7 years ago

...we tried to use jitpack, but the build isn't signed, and that doesn't work -- https://jitpack.io/com/github/LibraryOfCongress/bagit-java/v5.0.0-RC10/build.log -- and only 5.0.0-BETA is in maven central http://search.maven.org/#search%7Cgav%7C1%7Cg%3A%22gov.loc%22%20AND%20a%3A%22bagit%22

ruebot commented 7 years ago

nvm, @acoburn just found https://oss.sonatype.org/content/repositories/snapshots/gov/loc/bagit/5.0.0-RC10-SNAPSHOT/ :smile:

johnscancella commented 7 years ago

yeah, I wish I could remove that 5.0.0-BETA from maven central, but they have a strict policy about not removing dependencies. That should have really just been published to the snapshot repo.

acdha commented 7 years ago

@johnscancella I've generally found that if you publish newer versions people will use those. Maybe it'd be enough to start publishing RC builds?

johnscancella commented 7 years ago

I pushed the RC12 release to https://oss.sonatype.org/content/repositories/snapshots/gov/loc/bagit/5.0.0-RC12-SNAPSHOT/