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

feat: Add more informative errors when evaluation of --default-resources fails #1192

Merged

Conversation

DonFreed
Copy link
Contributor

@DonFreed DonFreed commented Sep 28, 2021

Description

--default-resources values are evaluated with eval() and some default resources strings can fail if not properly quoted (e.g. see #1093). This PR adds a more informative error message for --default-resources arguments that raise an exception.

QC

  • The PR contains a test case for the changes or the changes are already covered by an existing test case.
  • The documentation (docs/) is updated to reflect the changes or this is not necessary (e.g. if the change does neither modify the language nor the behavior or functionalities of Snakemake).

@DonFreed DonFreed requested a review from johanneskoester as a code owner Sep 28, 2021
@DonFreed DonFreed changed the title Add more informative errors when evaluation of --default-resources fails feat: Add more informative errors when evaluation of --default-resources fails Sep 28, 2021
@DonFreed
Copy link
Contributor Author

DonFreed commented Sep 29, 2021

I'm not sure why the tests took so long here?

snakemake/resources.py Outdated Show resolved Hide resolved
@DonFreed
Copy link
Contributor Author

DonFreed commented Oct 1, 2021

It looks like there may have been some DNS issues at Quay during testing, https://status.quay.io/incidents/bt8yqm82069z

@sonarcloud
Copy link

sonarcloud bot commented Oct 1, 2021

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 1 Code Smell

No Coverage information No Coverage information
0.0% 0.0% Duplication

@johanneskoester johanneskoester merged commit b3c4e68 into snakemake:main Oct 11, 2021
6 checks passed
@DonFreed DonFreed deleted the informative_default-resources_errors branch Oct 26, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants