Conversation
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.
Summary
Expose W&B run identity through typed logging configuration and fix cached run
ownership when applications initialize, finish, or replace the active SDK run.
logging.wandb_run_id,wandb_run_name, andwandb_resume; preservetimestamp-based defaults, existing project/group fields, and vision config behavior.
finished/replaced; require explicit initialization to adopt a replacement.
This replaces the need for an application to intercept
wandb.initto supplylauncher-derived identity. No launcher-specific environment parsing, report
filtering, or application-specific naming policy is added.
Validation
28 tests pass (
test_wandb_identity.pyandtest_logging_level.py), coveringdefault/explicit identity, resume modes, invalid settings, repeated/external
initialization, failed initialization, finished/replaced runs, missing SDK,
and unchanged vision-generation identity. Tests use a fake SDK and make no
remote W&B calls. Ruff and
git diff --checkpass.Independent of pending #747: based directly on upstream main, with none of that
PR's watchdog/launcher/unregister commits included.
Initialization policy
Initialization remains best-effort, including
wandb_resume="must": SDK initialization errors are logged and training continues without W&B logging.wandb_resume=Nonedefers to SDK settings, including environment configuration; it does not guarantee that resuming is disabled. An application-owned active run retains its existing identity and policy.