Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue #326: Add new regex to catch MUMmer v4 version information #335

Merged
merged 10 commits into from
Dec 17, 2021

Conversation

baileythegreen
Copy link
Contributor

@baileythegreen baileythegreen commented Sep 7, 2021

Adds new code to catch version information for new version of MUMmer.

Feedback may be needed on the specific error types used.

Note: this will likely require some new tests (to-be-written).

Closes #326.

Type of change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality not to work as expected)
  • This change requires a documentation update
  • This is a documentation update

Action Checklist

  • Work on a single issue/concept (if there are multiple separate issues to address, please use a separate pull request for each)
  • Fork the pyani repository under your own account (please allow write access for repository maintainers)
  • Set up an appropriate development environment (please see CONTRIBUTING.md)
  • Create a new branch with a short, descriptive name
  • Work on this branch
    • style guidelines have been followed
    • new code is commented, especially in hard-to-understand areas
    • corresponding changes to documentation have been made
    • tests for the change have been added that demonstrate the fix or feature works
  • Test locally with pytest -v non-passing code will not be merged
  • Rebase against origin/master
  • Check changes with flake8 and black before submission
  • Commit branch
  • Submit pull request, describing the content and intent of the pull request
  • Request a code review
  • Continue the discussion at Pull requests section in the pyani repository

@baileythegreen baileythegreen added the bug something isn't working how it should label Sep 7, 2021
@codecov
Copy link

codecov bot commented Sep 7, 2021

Codecov Report

Merging #335 (62967a0) into master (c0fdf6d) will increase coverage by 0.15%.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##           master     #335      +/-   ##
==========================================
+ Coverage   76.32%   76.47%   +0.15%     
==========================================
  Files          52       52              
  Lines        3404     3414      +10     
==========================================
+ Hits         2598     2611      +13     
+ Misses        806      803       -3     

@baileythegreen baileythegreen changed the title Add new regex to catch MUMmer v4 version information Issue #326: Add new regex to catch MUMmer v4 version information Sep 7, 2021
Copy link
Owner

@widdowquinn widdowquinn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One small note at l.140. (also make Exception catching specific for PermissionError and FileNotFoundError when can't find exacutable - do we need to do this for the other tools, also?)

baileythegreen added a commit that referenced this pull request Sep 7, 2021
Keep this PR in-sync with PR #335
@baileythegreen
Copy link
Contributor Author

baileythegreen commented Sep 9, 2021

Re: the PermissionError check we discussed adding, I think this may actually be superfluous: if not os.access(nucmer_path, os.X_OK) checks whether the file is executable; from looking into it, I don't think this command would return True, unless the individual had execute permissions on the file.

The other options for os.access()'s second argument check whether the user has read or write permissions for the file.

@baileythegreen baileythegreen merged commit 14a96f3 into master Dec 17, 2021
@baileythegreen baileythegreen deleted the issue_326 branch May 24, 2022 04:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug something isn't working how it should
Projects
None yet
Development

Successfully merging this pull request may close these issues.

MUMmer 4 reports version differently to MUMmer 3
2 participants