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

Fixed unknown configs being silently ignored #2666

Merged
merged 5 commits into from
Dec 4, 2024
Merged

Conversation

kosack
Copy link
Contributor

@kosack kosack commented Dec 4, 2024

Fixes bug where if a configuration file with unknown file extension is passed to a tool, e.g. --config myconf.conf instead of --config myconf.yaml, it was silently ignored. Config files must now have one of the following extensions to be recognized: yml, yaml, toml, json, py, and if not a ToolConfigurationError is raised.

@maxnoe maxnoe added this to the v0.23.1 milestone Dec 4, 2024
@kosack kosack requested a review from Tobychev December 4, 2024 12:55
maxnoe
maxnoe previously approved these changes Dec 4, 2024
src/ctapipe/core/tool.py Outdated Show resolved Hide resolved
@maxnoe
Copy link
Member

maxnoe commented Dec 4, 2024

FAILED src/ctapipe/io/tests/test_simteleventsource.py::test_prod6_issues - FileNotFoundError: Couldn't find resource: 'prod6_issues.simtel.zst', You might want to install ctapipe_resources
FAILED src/ctapipe/tools/tests/test_process.py::test_prod6_issues - FileNotFoundError: Couldn't find resource: 'prod6_issues.simtel.zst', You might want to install ctapipe_resources

Damn... this is a cross issue with the switch to minio, we uploaded a new file after Gareth moved the data

@maxnoe
Copy link
Member

maxnoe commented Dec 4, 2024

Gareth uploaded the file, CI is passing now

Copy link

Passed

Analysis Details

0 Issues

  • Bug 0 Bugs
  • Vulnerability 0 Vulnerabilities
  • Code Smell 0 Code Smells

Coverage and Duplications

  • Coverage 100.00% Coverage (94.10% Estimated after merge)
  • Duplications 0.00% Duplicated Code (0.70% Estimated after merge)

Project ID: cta-observatory_ctapipe_AY52EYhuvuGcMFidNyUs

View in SonarQube

@kosack kosack merged commit df2f90d into main Dec 4, 2024
13 checks passed
@kosack kosack deleted the fix/unknown_config_type branch December 4, 2024 14:59
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.

3 participants