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

Failed to load data #333

Open
guimasuko opened this issue Nov 6, 2024 · 3 comments
Open

Failed to load data #333

guimasuko opened this issue Nov 6, 2024 · 3 comments

Comments

@guimasuko
Copy link

Behaviour

Expected vs. Actual

In a debugging session, I am getting this error message "Failed to load data" when trying to "View value in Data Viewer" by using Data Wrangler extension on VSCode.
This doesn't happen every time. For some dataframes I am still being able to "View value in Data Viewer".

I also got this message (I hope it can be useful)
Error details
Received malformed content: {"name": "KeyError", "message": "'5b46cde0-7b78-42a7-80e6-34deafb9fe85'", "stack": "Traceback \u001b[1;36m(most recent call last)\u001b[0m:\n\u001b[1;36m File \u001b[1;32m:56\u001b[1;36m in \u001b[1;35m__DW_DEBUG_WRAPPER__\u001b[1;36m\n\u001b[1;31mKeyError\u001b[0m\u001b[1;31m:\u001b[0m '5b46cde0-7b78-42a7-80e6-34deafb9fe85'\n"}

Steps to reproduce:

  1. Since it is sensitive data, I can't share with you. But it is a dataframe with shape (155, 1078).
  2. I am able to print the dataframe in the debug console.
  3. I am able to save this dataframe to csv.

Diagnostic data

  • Jupyter extension version: 2024.10.0
  • Python extension version: 2024.18.0
  • .NET Install Tool for Extension Authors extension version: Not installed
  • Python package dependencies:
{
  "installed": {
    "pandas": "2.2.2",
    "pyarrow": "16.1.0"
  },
  "required": {
    "pandas": "1.2.0"
  },
  "unsatisfied": []
}
  • Entrypoint: JupyterDataViewer
  • Active mode: dataViewer
@pwang347
Copy link
Member

pwang347 commented Nov 6, 2024

Hi @guimasuko, thank you for opening this issue and we're sorry that you're encountering this.

Could you please confirm the following:

  • The error depends on the dataset only (for example, the dataset you are viewing is at top-level scope and is not inside a function or something else)
  • 100% of the times you open the dataset, you get the same error above
  • 100% of the times you open a different dataset, e.g. li = [1,2,3] it launches successfully
  • The data type you are trying to view is a Pandas DataFrame

Does the following dataset load for you? If so, is it possible for you to make a few tweaks to try to see if you can reproduce the issue:

import pandas as pd
n_rows = 155
data = {
    f"col{n}": ["Lorem ipsum dolor sit amet"] * n_rows for n in range(1078)
}
df = pd.DataFrame(data)
df

Thanks!

@pwang347
Copy link
Member

pwang347 commented Nov 6, 2024

Could you also please check if this thread applies to you as well? #274 (comment)

@guimasuko
Copy link
Author

Hi @pwang347.

Thank you for getting back to me.

I noticed that the Anaconda version had changed on my PC to 2024.10-1. Since I reverted to the previous version (2023.07-2), which I had been working with before, I am now able to view the same objects I was having trouble with when using Anaconda version 2024.10-1.

I hope this information is useful for others.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants