Add missing wandb Hydra config group to minimal-hydra-example#635
Open
johndmulhausen wants to merge 1 commit into
Open
Add missing wandb Hydra config group to minimal-hydra-example#635johndmulhausen wants to merge 1 commit into
johndmulhausen wants to merge 1 commit into
Conversation
configs/defaults.yaml lists the `wandb: default` Hydra config group,
but configs/wandb/ was never committed: the repo-root .gitignore's
bare `wandb` pattern (meant for run-output directories) also matched
it. Composition failed with:
In 'defaults': Could not find 'wandb/default'
Add configs/wandb/default.yaml with the `setup:` mapping that main.py
unpacks into wandb.init(**cfg.wandb.setup), plus a .gitignore negation
so the config group cannot be silently re-lost.
Fixes #482
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Contributor
There was a problem hiding this comment.
Pull request overview
Fixes the minimal Hydra example failing during config composition by adding the missing wandb config group and preventing it from being ignored by git.
Changes:
- Add
examples/minimal-hydra-example/configs/wandb/default.yamlso- wandb: defaultcomposes successfully. - Update repo-root
.gitignoreto explicitly allow committing theexamples/minimal-hydra-example/configs/wandb/directory despite the globalwandbignore rule.
Reviewed changes
Copilot reviewed 1 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| examples/minimal-hydra-example/configs/wandb/default.yaml | Adds the missing Hydra config group providing setup kwargs consumed by wandb.init(**cfg.wandb.setup). |
| .gitignore | Prevents the configs/wandb/ group from being ignored by the global wandb pattern. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
johndmulhausen
marked this pull request as ready for review
July 21, 2026 21:33
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Problem
Running the minimal Hydra example fails immediately at config composition:
examples/minimal-hydra-example/configs/defaults.yamllists- wandb: defaultin its Hydra defaults, but theconfigs/wandb/directory does not exist in the repo.Root cause
The repo-root
.gitignorecontains a barewandbpattern (line 3, intended for wandb run-output directories), which also matchesconfigs/wandb/—git check-ignore -vconfirms it. The config group was silently swallowed and never committed.Fix
examples/minimal-hydra-example/configs/wandb/default.yaml(new): defines the config group with a top-levelsetup:mapping, matching how it is consumed and documented:main.pyuses exactly one thing from this group:wandb.init(**cfg.wandb.setup), so the group must be a mapping of validwandb.initkwargs undersetup:.example-hydraand documents overriding entity withwandb.setup.entity=<entity_name>(same override path used forwandb_sweep.yaml). Declaringentity: nullis load-bearing: Hydra struct mode rejects overrides of keys that do not exist, so without it the documented override would fail.entity=Noneiswandb.init's default (use your default entity).---document marker, no# @packagedirective, same asconfigs/model/default.yamlandconfigs/optimizer/*.yaml)..gitignore: adds!examples/minimal-hydra-example/configs/wandb/immediately after thewandbpattern so the config group cannot be silently re-lost (for example, a futureconfigs/wandb/offline.yamlwould otherwise be skipped bygit addwith no warning).Verification
Compose test (hydra-core 1.3.4 / omegaconf 2.3.1):
MissingConfigException: In 'defaults': Could not find 'wandb/default'(the exact error from [Bug]: minimal-hydra-example is missing wandb config #482).{'setup': {'project': 'example-hydra', 'entity': None}}.wandb.init(project="example-hydra", entity=None, mode="offline")runs and finishes cleanly (wandb 0.26.1).Fixes #482
🤖 Generated with Claude Code