How do I handle the 'Failed to query for notebook' error?

If you encounter the error message "Failed to query for notebook name, you can set it manually with the WANDB_NOTEBOOK_NAME environment variable," resolve it by setting the environment variable. Multiple methods accomplish this:

%env "WANDB_NOTEBOOK_NAME" "notebook name here"
import os

os.environ["WANDB_NOTEBOOK_NAME"] = "notebook name here"

Last modified February 4, 2025: b42d7fe