# Deprication Warning

**URL:** <https://forum.weaviate.io/t/deprication-warning/1383>\
**Category:** Support\
**Created:** [February 6, 2024, 11:21am UTC](https://forum.weaviate.io/t/deprication-warning/1383 "2024-02-06T11:21:15Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![hebkon](https://avatars.discourse-cdn.com/v4/letter/h/57b2e6/32.png) [@hebkon](https://forum.weaviate.io/u/hebkon)\
**Post date:** [February 6, 2024, 11:21am UTC](https://forum.weaviate.io/t/deprication-warning/1383/1 "2024-02-06T11:21:15Z")

</div>

I connected to weaviate using Docker, which seems to work fine.

The only issue is that I get a Deprecation Warning for using v3 when I think I am using v4.

Inside a jupyter notebook I am connecting to my weaviate Docker:

```auto
import weaviate
import os
import json

client = weaviate.Client(
    url = "http://localhost:8080", # Replace with your endpoint
    additional_headers = {
        "X-OpenAI-Api-Key": os.getenv("OPENAI_API_KEY") # Replace with your inference API key
    }
)

```

And I get the warning message  
`[/Users/kon/miniconda3/envs/factcheck-gpt/lib/python3.11/site-packages/weaviate/warnings.py:158](https://file+.vscode-resource.vscode-cdn.net/Users/kon/miniconda3/envs/factcheck-gpt/lib/python3.11/site-packages/weaviate/warnings.py:158): DeprecationWarning: Dep016: You are using the Weaviate v3 client, which is deprecated. Consider upgrading to the new and improved v4 client instead! See here for usage: https://weaviate.io/developers/weaviate/client-libraries/python warnings.warn(`

although I have installed v4 in this environment I am using:  
!pip list | grep weaviate  
weaviate-client 4.4.2

for now it works, I can run all the code from the quickstart\_end\_to\_end notebook, but I am still wondering where this warning is coming from.

---

<div class="post-metadata">

**Author:** ![mnkasikci](https://avatars.discourse-cdn.com/v4/letter/m/b19c9b/32.png) [@mnkasikci](https://forum.weaviate.io/u/mnkasikci)\
**Post date:** [February 6, 2024, 2:06pm UTC](https://forum.weaviate.io/t/deprication-warning/1383/2 "2024-02-06T14:06:29Z")

</div>

If you are not utilizing v3 at all, can you consider removing weaviate client v3 globally, if it still exist? I am not an expert on python, but i had similar issues where I had to remove a package globally.

---

<div class="post-metadata">

**Author:** ![hebkon](https://avatars.discourse-cdn.com/v4/letter/h/57b2e6/32.png) [@hebkon](https://forum.weaviate.io/u/hebkon)\
**Post date:** [February 6, 2024, 3:15pm UTC](https://forum.weaviate.io/t/deprication-warning/1383/3 "2024-02-06T15:15:45Z")

</div>

Thanks for that hint, but I could not solve it like that.

It seems that I never installed v3. Neither in my conda pkgs folder nor in my site-packages folder seems to be a v3, but only version 4.4.2

Or what would be your way of finding out if I ever installed it? With pip inside a conda env.

---

<div class="post-metadata">

**Author:** ![DaveCuthbert](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/davecuthbert/32/438_2.png) [@DaveCuthbert](https://forum.weaviate.io/u/DaveCuthbert)\
**Post date:** [February 6, 2024, 5:29pm UTC](https://forum.weaviate.io/t/deprication-warning/1383/4 "2024-02-06T17:29:12Z")

</div>

Hi @hebkon you are using the v4 client, but you are connecting using a v3 style method. The older style is there for compatibility as people transition to the new style.

A local v4 connection looks like this:

import weaviate  
client = weaviate.connect\_to\_local()

There is more info about connection methods on this page:

> **[Python (Client v4) | Weaviate - Vector Database](https://weaviate.io/developers/weaviate/client-libraries/python#python-client-v4-helper-functions)**
>
> Overview

---

<div class="post-metadata">

**Author:** ![hebkon](https://avatars.discourse-cdn.com/v4/letter/h/57b2e6/32.png) [@hebkon](https://forum.weaviate.io/u/hebkon)\
**Post date:** [February 8, 2024, 10:51am UTC](https://forum.weaviate.io/t/deprication-warning/1383/5 "2024-02-08T10:51:33Z")

</div>

Thanks, that makes sense.

---

<div class="post-metadata">

**Author:** ![Gene\_Mc](https://yyz1.discourse-cdn.com/flex027/user_avatar/forum.weaviate.io/gene_mc/32/1095_2.png) [@Gene\_Mc](https://forum.weaviate.io/u/Gene_Mc)\
**Post date:** [March 14, 2024, 11:44am UTC](https://forum.weaviate.io/t/deprication-warning/1383/6 "2024-03-14T11:44:41Z")

</div>

I feel the error message should be better. The code should be able to check which version of the client is installed. If a v4 client is installed, but a v3 method is being used, the error message should say so!

“You appear to be using a v3 method with a v4 client, consider migrating your code to use v4 methods as v3 methods are deprecated.”
