cultivarium / MicrobeMod

A toolkit for exploring prokaryotic methylation and base modifications in nanopore sequencing
MIT License
34 stars 1 forks source link

Version v1.0.1 merge review #1

Closed alexcritschristoph closed 8 months ago

alexcritschristoph commented 8 months ago

Hi James, Tyler: This pull request is for the version I am preparing for our initial release. Please let me know if you have any recommendations or suggestions for fixes before we release.

Note you can run the unit tests with: pytest -rP

But you'll want the dependencies to pass all of the tests: let me know if you want to try and run into issues installing them. We could use that experience to also include some detailed directions for setting them up on macOS.

We don't have unit tests for every function, but I tried to get them for the main ones.

There is one thing missing element that I'm not quite sure of - how can I set it up to accurately show the version number when you run MicrobeMod --version? Currently that command doesn't work.

knightjdr commented 8 months ago

I can't install on a mac, so I'm limited with what I can do.

For the version issue, you need to handle the --version argument yourself in your main:

import argparse
import sys

from ._version import __version__ as version

def main():
   parser = argparse.ArgumentParser(description='My script description')
   parser.add_argument('--version', action='store_true', help='Show the version number and exit')
   args = parser.parse_args()
   if args.version:
        print(version)
        sys.exit()
alexcritschristoph commented 8 months ago

Hi @knightjdr, @tylerbarnum, this pull request has been updated with a considerable number of changes in the latest commit, including:

  1. Ran asp on the repository
  2. Updated the docs
  3. Switched from print() to logging
  4. Added --version
  5. Made a number of the changes suggested by Tyler - at least a majority of them.

This passes all of the unit tests and seems to be working well. I think we can merge.