Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

load_audit("Nope") fails with a bare FileNotFoundError that does not say an audit folder was expected

Closed Beginner friendly
#1,112 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

A pull request for this has already been merged.

  • #1123 by @dxnnystyles — merged

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
84/100
Issue type
Bug
Clarity
Clearly specified
Activity status
Active
Tech stack
python, yaml
Domain
cli

Research direction

Start with load_audit in faircode/benchmark.py and the existing cases in tests/test_load_audit.py; check how it handles folder paths, manifest paths, and discover_manifests. Add tests for a missing folder, an existing folder without audit.yaml, and a close misspelling. Done means each error names the attempted path and explains what audit folders or manifest paths are available.

Written by the indexing model from the issue text.

Description

enhancement good first issue

Where: faircode/benchmark.py (load_audit), tests/test_load_audit.py.

Current gap: load_audit accepts a folder or a manifest path. For a name that is neither it raises FileNotFoundError: [Errno 2] No such file or directory: 'Nope', which does not say that it looked for Nope/audit.yaml, and a typo such as "Benefits denial" (the folder is Benefits Denial) gives no hint. A name that is a real folder without an audit.yaml reports the missing file only as a path from yaml loading. The strategy error is already clear (unknown strategy: 'bogus').

Repro:

$ python3 -c "from faircode.benchmark import load_audit; load_audit('Nope')"
FileNotFoundError: [Errno 2] No such file or directory: 'Nope'

Suggested approach: raise a FileNotFoundError that names the path it tried (Nope/audit.yaml), says that folder must be an audit folder or a manifest path, and, if the folder does not exist, lists the audit folders found next to it (use discover_manifests). Add tests for a missing folder, a folder without a manifest and a close misspelling.

Done when: each of those cases produces a message that names what was tried and what exists.

Dominant language
HTML
Stars
47
Forks
45
Avg merge
3h 4m
Merged PRs (30d)
83

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from yakew7/Fair-Code

All issues in yakew7/Fair-Code

Similar issues

More CLI issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.