bagit-profiles / bagit-profiles-validator

A simple Python module for validating BagIt Profiles.
The Unlicense
12 stars 6 forks source link

fix python2-isms and pylint warnings #5

Closed kba closed 5 years ago

kba commented 5 years ago

This makes bagit-profiles-validator py3-compatible and fixes a few warnings, reduces the number of unreachable code etc. No functional changes.

Is this still maintained? Is there an exchange between this and https://github.com/fair-research/bdbag/blob/master/bdbag/bdbagit_profile.py?

ruebot commented 5 years ago

Hi @kba, thanks!

This is still maintained for the most part. @mjordan and I are around, but there isn't much active development happening.

Can't say there is any exchange between that project and ours. First I've honestly heard about it.

ruebot commented 5 years ago
[nruest@wombat:bagit-profiles-validator] (git)-[2to3]-$ python3 setup.py test                              
running test
running egg_info
writing bagit_profile.egg-info/PKG-INFO
writing dependency_links to bagit_profile.egg-info/dependency_links.txt
writing requirements to bagit_profile.egg-info/requires.txt
writing top-level names to bagit_profile.egg-info/top_level.txt
reading manifest file 'bagit_profile.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'bagit_profile.egg-info/SOURCES.txt'
running build_ext
test_validate (test.Test_bag_profile) ... /usr/local/lib/python3.6/dist-packages/bagit-1.7.0-py3.6.egg/bagit.py:320: DeprecationWarning: Use the Bag.version_info tuple instead of Bag.version
  DeprecationWarning,
ok
test_validate_accept_bagit_version (test.Test_bag_profile) ... ok
test_validate_allow_fetch (test.Test_bag_profile) ... ok
test_validate_bag_info (test.Test_bag_profile) ... ok
test_validate_bagit_profile_info (test.Test_bag_profile) ... ok
test_validate_manifests_required (test.Test_bag_profile) ... ok
test_validate_serialization (test.Test_bag_profile) ... ok

----------------------------------------------------------------------
Ran 7 tests in 2.123s

OK

Looks good to me. Let me know if you're good with this @mjordan, and I can merge.

I suppose we should setup TravisCI or CircleCI on this.

kba commented 5 years ago

Cool, thanks, appreciate the quick response!

I suppose we should setup TravisCI or CircleCI on this.

Just now preparing a .circleci/config.yml :) PR in a few minutes.

ruebot commented 5 years ago

Thanks! I've authorized CircleCI for this GitHub org, so we should be good to go there once we get the other PR in and merged.

ruebot commented 5 years ago

@kba want to update this branch, and hopefully it should trigger the build?

kba commented 5 years ago

Fixed the urlopen/python3-bytes-are-not-str problems, tests pass now.

ruebot commented 5 years ago

@mjordan you ok if I merge this one, and start moving on to the other PRs?