Report Augur versions on error without --use-conda
#611
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description of proposed changes
If the workflow errors out and the user isn't using the
--use-conda
Snakemake flag, let the user know what Augur version they have installed and which version is expected in the Conda environment. Let users know about the--use-conda
flag in this case as a possible solution to the workflow errors.Previously, we've attempted to assert minimum Augur versions in the Snakefile, but this is difficult to assert under all valid conditions (e.g., when the user uses
--use-conda
, we don't know what Augur version they have). This PR attempts to handle the case when users do not use the workflow's predefined Conda environment and at least a) report their current Augur version and the required version based on the Conda environment file and b) let them know about the--use-conda
flag. This approach opts for providing a more helpful error message to users when the workflow fails instead of asserting a requirement that is difficult to verify prior to running the workflow.Related issue(s)
Related to nextstrain/cli#119
Testing
Tested by installing an older version of Augur in an external Conda environment that did not support the
--output-strains
argument foraugur filter
(11.1.2 or before) and confirming that the new error message about--use-conda
got printed when the filter rule failed.Release checklist
If this pull request introduces new features, complete the following steps:
docs/change_log.md
in this pull request to document these changes by the date they were added.