# Can't find project using the python API

**URL:** <https://community.wandb.ai/t/cant-find-project-using-the-python-api/5728>\
**Category:** W&B Help\
**Created:** [January 16, 2024, 8:53am UTC](https://community.wandb.ai/t/cant-find-project-using-the-python-api/5728 "2024-01-16T08:53:18Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![sholk](https://avatars.discourse-cdn.com/v4/letter/s/258eb7/32.png) [@sholk](https://community.wandb.ai/u/sholk)\
**Post date:** [January 16, 2024, 8:53am UTC](https://community.wandb.ai/t/cant-find-project-using-the-python-api/5728/1 "2024-01-16T08:53:18Z")

</div>

Hello,

I have a problem where wandb doesn’t seem to find my project or any of my runs when using Python.  
This is the code I am trying to run:

```auto
import wandb
api = wandb.Api()

run = api.run("<entity>/<project>/<run_id>")
run.config["key"] = updated_value
run.update()

```

It returns this message:

```auto
wandb.errors.CommError: Could not find run <Run <entity>/<project>/<run_id> (not found)>

```

I also tried to run this code:

```auto
runs = wandb.Api().runs("<entity>/<project>", filters={<one of my filter values>}) 
print(f"matching runs: {len(runs)}")

```

But again this returns the error:

```auto
ValueError: Could not find project <project>

```

I use version 0.15.11 of wandb and version 3.6.13 of Python, but I have also tried newer Python versions with wandb 0.15.12.

The strange thing is that I have code like this that ran perfectly before. I have made no changes and all of a sudden it stops finding my project, breaking all of my existing code. I’ve tried different ways to login, to access the project, and tried different computers but nothing works. Can you help with this?

---

<div class="post-metadata">

**Author:** ![joana-marie](https://avatars.discourse-cdn.com/v4/letter/j/f6c823/32.png) [@joana-marie](https://community.wandb.ai/u/joana-marie)\
**Post date:** [January 17, 2024, 5:22am UTC](https://community.wandb.ai/t/cant-find-project-using-the-python-api/5728/2 "2024-01-17T05:22:00Z")

</div>

Hello @sholk ,happy to help and apologies for running into this. To further assist could I ask for the following:

1. Link to the run where you are trying to query via api
2. Could you update to latest version of wandb `pip install -U wandb`
3. Try refreshing login: from command line: `rm ~/.netrc` followed by `wandb login --relogin --cloud`

Thanks~!

---

<div class="post-metadata">

**Author:** ![sholk](https://avatars.discourse-cdn.com/v4/letter/s/258eb7/32.png) [@sholk](https://community.wandb.ai/u/sholk)\
**Post date:** [January 17, 2024, 9:56am UTC](https://community.wandb.ai/t/cant-find-project-using-the-python-api/5728/3 "2024-01-17T09:56:29Z")

</div>

Thank you for the help!

Step 3 was the key. Have tried re-login before, but I think removing the `~/.netrc` file was what made the difference.

---

<div class="post-metadata">

**Author:** ![joana-marie](https://avatars.discourse-cdn.com/v4/letter/j/f6c823/32.png) [@joana-marie](https://community.wandb.ai/u/joana-marie)\
**Post date:** [January 18, 2024, 4:44am UTC](https://community.wandb.ai/t/cant-find-project-using-the-python-api/5728/4 "2024-01-18T04:44:24Z")

</div>

Hello @sholk Thank you for the confirmation, we’ll mark this as resolved, and feel free to write for any other concern if ever.
