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

Issue: "Couldn't upload dataset. TypeError: NetworkError when attempting to fetch resource" when trying to upload a csv dataset #529

Open
c0pper opened this issue Mar 18, 2024 · 1 comment
Labels
bug Something isn't working

Comments

@c0pper
Copy link

c0pper commented Mar 18, 2024

Description:
When attempting to upload a CSV dataset to the langsmith web ui using the provided functionality, the process fails with the error message "Couldn't upload dataset. TypeError: NetworkError when attempting to fetch resource". This error prevents the successful submission of the dataset, hindering progress on data analysis or processing tasks.

Steps Taken:

Ensured that the CSV file is correctly formatted and contains valid data.
Checked the network connectivity to ensure there are no issues with internet access.
Attempted to upload the dataset multiple times, but consistently encountered the same error.
Reviewed relevant documentation or support resources provided by the service, but did not find a solution to the issue.

Expected Outcome:
The dataset should be successfully uploaded to the server without encountering any errors, allowing for further data analysis or processing tasks to proceed.

Additional Information:

Tried in Python following this guide as well https://docs.smith.langchain.com/evaluation/faq/datasets-client#create-dataset-from-csv with the following error trace:

urllib3.exceptions.SSLError: EOF occurred in violation of protocol (_ssl.c:2384)

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
File "c:\Users\smarotta\PycharmProjects\edm_categorization\venv\lib\site-packages\requests\adapters.py", line 486, in send
resp = conn.urlopen(
File "c:\Users\smarotta\PycharmProjects\edm_categorization\venv\lib\site-packages\urllib3\connectionpool.py", line 877, in urlopen
return self.urlopen(
File "c:\Users\smarotta\PycharmProjects\edm_categorization\venv\lib\site-packages\urllib3\connectionpool.py", line 877, in urlopen
return self.urlopen(
File "c:\Users\smarotta\PycharmProjects\edm_categorization\venv\lib\site-packages\urllib3\connectionpool.py", line 877, in urlopen
return self.urlopen(
File "c:\Users\smarotta\PycharmProjects\edm_categorization\venv\lib\site-packages\urllib3\connectionpool.py", line 847, in urlopen
retries = retries.increment(
File "c:\Users\smarotta\PycharmProjects\edm_categorization\venv\lib\site-packages\urllib3\util\retry.py", line 515, in increment
raise MaxRetryError(_pool, url, reason) from reason # type: ignore[arg-type]
urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='api.smith.langchain.com', port=443): Max retries exceeded with url: /datasets/upload (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:2384)')))

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "c:\Users\user\PycharmProjects\edm_categorization\main.py", line 32, in
dataset = client.upload_csv(
File "c:\Users\user\PycharmProjects\edm_categorization\venv\lib\site-packages\langsmith\client.py", line 881, in upload_csv
response = self.session.post(
File "c:\Users\user\PycharmProjects\edm_categorization\venv\lib\site-packages\requests\sessions.py", line 637, in post
return self.request("POST", url, data=data, json=json, **kwargs)
File "c:\Users\user\PycharmProjects\edm_categorization\venv\lib\site-packages\requests\sessions.py", line 589, in request
resp = self.send(prep, **send_kwargs)
File "c:\Users\user\PycharmProjects\edm_categorization\venv\lib\site-packages\requests\sessions.py", line 703, in send
r = adapter.send(request, **kwargs)
File "c:\Users\user\PycharmProjects\edm_categorization\venv\lib\site-packages\requests\adapters.py", line 517, in send
raise SSLError(e, request=request)
requests.exceptions.SSLError: HTTPSConnectionPool(host='api.smith.langchain.com', port=443): Max retries exceeded with url: /datasets/upload (Caused by SSLError(SSLEOFError(8, 'EOF occurred in violation of protocol (_ssl.c:2384)')))

Suggestion:

No response

@hinthornw
Copy link
Collaborator

Thanks for raising - we'll investigate.

@hinthornw hinthornw added the bug Something isn't working label Apr 10, 2024
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

2 participants