Skip to content

Commit

Permalink
Cached filesystems need to be synced on re-run
Browse files Browse the repository at this point in the history
  • Loading branch information
m90 committed Jan 18, 2025
1 parent 80bcb27 commit 9cd2645
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions src/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,8 @@ createApp({
throw new Error('read access to directory not granted')
}
this.inputFs = await this.pyodide.mountNativeFS(this.filesInputLocation, dirHandle)
} else {
await this.inputFs.syncfs()
}

if (this.isUsingFilesystemOutput && !this.outputFs) {
Expand All @@ -88,6 +90,8 @@ createApp({
throw new Error('read/write access to directory not granted')
}
this.outputFs = await this.pyodide.mountNativeFS(this.filesOutputLocation, dirHandle)
} else {
await this.outputFs.syncfs()
}

if (this.isUsingTextInput) {
Expand Down

0 comments on commit 9cd2645

Please sign in to comment.