Skip to content

Clear Neurosift storage when rendering Neurosift#975

Merged
rly merged 7 commits intomainfrom
clear-storage-data
Mar 25, 2025
Merged

Clear Neurosift storage when rendering Neurosift#975
rly merged 7 commits intomainfrom
clear-storage-data

Conversation

@rly
Copy link
Copy Markdown
Collaborator

@rly rly commented Mar 7, 2025

Fix #974

I tested this locally. The neurosift storage data is cleared within the same session and across sessions whenever a new file is rendered.

@rly rly requested a review from pauladkisson March 7, 2025 23:58
Copy link
Copy Markdown
Collaborator

@pauladkisson pauladkisson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a way to add a test for this bug?

@rly
Copy link
Copy Markdown
Collaborator Author

rly commented Mar 12, 2025

Good idea. With help from Claude Sonnet, I added a unit/component test that tests whether the deleteDatabase method is called when the neurosift component is updated with a URL set.

I also converted Neurosift.js to a typescript file to resolve a linter warning about importing a js file into a ts file in the Neurosift component test

@rly rly mentioned this pull request Mar 25, 2025
Copy link
Copy Markdown
Collaborator

@pauladkisson pauladkisson left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good!

@rly rly merged commit 375908b into main Mar 25, 2025
27 checks passed
@rly rly deleted the clear-storage-data branch March 25, 2025 17:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Clear cache when serving NWB files to Neurosift and other services

2 participants