API connection with wandb failing

Hi,

While attempting to complete the 1st code example in the course “Evaluating and Debugging Generative AI”, I am facing two errors.

  1. It does not allow me to login anonymously into wandb using option 1
  2. When trying option 2, I added my API key, but I am getting error that API key should be only 40 characters even though the generated API key is much longer.

Please look into this.

This is a problem with the updated wandb library. You should remove the login code, and set your API key as an environment variable before calling wandb.init()
os.environ[“WANDB_API_KEY”] = “your_key_here”