Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] Error creating index in Semantic Search notebook #291

Open
2 tasks done
jseldess opened this issue Nov 14, 2023 · 0 comments
Open
2 tasks done

[Bug] Error creating index in Semantic Search notebook #291

jseldess opened this issue Nov 14, 2023 · 0 comments
Labels
bug Something isn't working

Comments

@jseldess
Copy link
Contributor

Is this a new bug?

  • I believe this is a new bug
  • I have searched the existing issues, and I could not find an existing issue for this bug

Current Behavior

In the Semantic Search notebook, when I try to create the index (code below), I always get an error (see log output) and am not able to proceed with the notebook. In the "Creating an index" step of the semantic search notebook, running:

import time

# only create index if it doesn't exist
if index_name not in pinecone.list_indexes():
    pinecone.create_index(
        name=index_name,
        dimension=len(dataset.documents.iloc[0]['values']),
        metric='cosine'
    )
    # wait a moment for the index to be fully initialized
    time.sleep(1)

# now connect to the index
index = pinecone.GRPCIndex(index_name)

Expected Behavior

I expect the index to be created successfully, so I can proceed with the notebook.

Steps To Reproduce

  1. Go to https://colab.research.google.com/github/pinecone-io/examples/blob/master/docs/semantic-search.ipynb.
  2. Run through the steps until you get to the create an index code.
  3. Run that and you should get the error mentioned above.

Relevant log output

WARNING:urllib3.connectionpool:Retrying (Retry(total=2, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7c49135055a0>: Failed to establish a new connection: [Errno -2] Name or service not known')': /databases
WARNING:urllib3.connectionpool:Retrying (Retry(total=1, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7c4913504070>: Failed to establish a new connection: [Errno -2] Name or service not known')': /databases
WARNING:urllib3.connectionpool:Retrying (Retry(total=0, connect=None, read=None, redirect=None, status=None)) after connection broken by 'NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7c49123b0430>: Failed to establish a new connection: [Errno -2] Name or service not known')': /databases
---------------------------------------------------------------------------
gaierror                                  Traceback (most recent call last)
[/usr/local/lib/python3.10/dist-packages/urllib3/connection.py](https://localhost:8080/#) in _new_conn(self)
    173         try:
--> 174             conn = connection.create_connection(
    175                 (self._dns_host, self.port), self.timeout, **extra_kw

24 frames
gaierror: [Errno -2] Name or service not known

During handling of the above exception, another exception occurred:

NewConnectionError                        Traceback (most recent call last)
NewConnectionError: <urllib3.connection.HTTPSConnection object at 0x7c49123b05e0>: Failed to establish a new connection: [Errno -2] Name or service not known

During handling of the above exception, another exception occurred:

MaxRetryError                             Traceback (most recent call last)
[/usr/local/lib/python3.10/dist-packages/urllib3/util/retry.py](https://localhost:8080/#) in increment(self, method, url, response, error, _pool, _stacktrace)
    590 
    591         if new_retry.is_exhausted():
--> 592             raise MaxRetryError(_pool, url, error or ResponseError(cause))
    593 
    594         log.debug("Incremented Retry for (url='%s'): %r", url, new_retry)

MaxRetryError: HTTPSConnectionPool(host='controller.pinecone_environment.pinecone.io', port=443): Max retries exceeded with url: /databases (Caused by NewConnectionError('<urllib3.connection.HTTPSConnection object at 0x7c49123b05e0>: Failed to establish a new connection: [Errno -2] Name or service not known'))


### Environment

```markdown
- **OS**: MacOS 14.1
- **Pinecone client version**: ? (in google colab)

Additional Context

No response

@jseldess jseldess added the bug Something isn't working label Nov 14, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant