-
Notifications
You must be signed in to change notification settings - Fork 92
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
Data explorer shows not actual(cached?) content of file when saving different tables with the same filename. #5860
Comments
EDIT: NOPE, this was wrong. This is a different bug that I can reproduce in the very latest builds. Thank you for the report, @ivan-balashov! Here are some reproducible steps:
You can do |
If you run |
Thanks for the investigation -- I'm having a look at this. File updates with the DuckDB backend are a bit finicky |
…into duckdb (#5890) Addresses #5860. duckdb-wasm has some kind of file caching behavior that is not resilient to file changes on the underlying file system. This patch nukes this issue from orbit by always registering the file contents as a virtual file and reading from that. I think if and when we migrate to the duckdb NodeJS bindings per #5889 that we can avoid this chicanery. This does the same thing for Parquet files, too, since they would also become stale. e2e: @:data-explorer ### QA Notes Here was the reproducible failure from the issue: * Run iris |> readr::write_csv("test.csv") * Click on the file in the File Explorer to open it up; note that we correctly see the iris data * Run mtcars |> readr::write_csv("test.csv") * Again click on the file in the File Explorer to open it up; note that we incorrectly still see the iris data
…into duckdb (#5890) Addresses #5860. duckdb-wasm has some kind of file caching behavior that is not resilient to file changes on the underlying file system. This patch nukes this issue from orbit by always registering the file contents as a virtual file and reading from that. I think if and when we migrate to the duckdb NodeJS bindings per #5889 that we can avoid this chicanery. This does the same thing for Parquet files, too, since they would also become stale. e2e: @:data-explorer ### QA Notes Here was the reproducible failure from the issue: * Run iris |> readr::write_csv("test.csv") * Click on the file in the File Explorer to open it up; note that we correctly see the iris data * Run mtcars |> readr::write_csv("test.csv") * Again click on the file in the File Explorer to open it up; note that we incorrectly still see the iris data
System details:
macos 13.5.1 (22G90)
Positron and OS details:
Версия: Positron Version: 2025.01.0 (Universal) build 39
Code - OSS Version: 1.93.0
Commit: c7ef34f
Date: 2024-12-09T02:49:50.608Z
Фиксация: 30.4.0
Дата: 124.0.6367.243
Electron: 20.15.1
ElectronBuildId: 12.4.254.20-electron.0
Chromium: Darwin x64 22.6.0
Node.js: undefined
V8: undefined
ОС: undefined
Interpreter details:
Does not matter
tests with different R-4* and python 3-9.-3.12. interpreters
Describe the issue:
Data explorer shows not actual(cached?) content of file when saving different tables with the same filename.
I've saving file (e.g. 'test.tsv') from R or python (doesnt matter) and then click on it so it opens in Data Explorer.
I am closing the Data Explorer tab.
After this, I've saving another dataframe with other columns using the same filename ('test.tsv') and when I am clicking on it the Data explorer shows to me the old file content while file is changed;
If I an opening this file using 'open with..' text editor - it shows new content, sofile is really changed while Data explorer could not track it and shows not actual content(I assume it is due to cache invalidation problem);
Steps to reproduce the issue:
I've saving file (e.g. 'test.tsv') from R or python (doesnt matter) and then click on it so it opens in Data Explorer.
I am closing the Data Explorer tab.
After this, I've saving another dataframe with other columns using the same filename ('test.tsv') and when I am clicking on it the Data explorer shows to me the old file content while file is changed;
If I an opening this file using 'open with..' text editor - it shows new content, so file is really changed while Data explorer could not track it and shows not actual content(I assume it is due to cache invalidation problem);
Expected or desired behavior:
Data Explorer should show actual file content, not cached;
Were there any error messages in the UI, Output panel, or Developer Tools console?
Nothing
Video of bug
2024-12-25.15.26.28.mov
The text was updated successfully, but these errors were encountered: