Skip to content

fix: Restore to project directory after using nodewhisper#239

Open
yannagrebah wants to merge 1 commit intoChetanXpro:mainfrom
yannagrebah:main
Open

fix: Restore to project directory after using nodewhisper#239
yannagrebah wants to merge 1 commit intoChetanXpro:mainfrom
yannagrebah:main

Conversation

@yannagrebah
Copy link
Copy Markdown

This PR fixes a minor oversight. When using nodewhisper(), it changes the current working directory to ./cpp/whisper.cpp instead of the project directory. This could cause problems when using other processes that rely on the current working directory.
This just restores the current directory to the project directory after all functions are done. Funny enough, this was already handled when an error occurred with handleError().

@Sleavely
Copy link
Copy Markdown

Sleavely commented Mar 26, 2026

Could you apply the same finally-statement in src/autoDownloadModel.ts? It also only resets in the catch-block.

Edit: And in src/downloadModel.ts which doesn't seem to have any cleanup logic at all.

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.

2 participants