Skip to content

Temporary Directories Cleanup in 'Single File Mode' #11378

@browntarik

Description

@browntarik

Issue Details:
In the 'single file mode', the functions workspace_storage_path and database_storage_path are observed to return blank strings. As a result, the get_temp_path("") function is used. When get_temp_path receives a blank string, it generates a unique GUID every single time to form a part of the resultant path. This behavior implies:

  1. Each created directory has a unique GUID, meaning they are used once and never revisited.
  2. Any data written to these uniquely generated directories remains unused in subsequent sessions.
  3. There is no existing mechanism to clear or delete these directories after their one-time use.

Potential Solutions:

  1. Integrate a mechanism to clear these directories upon application shutdown. However, this might not be fully reliable as unplanned shutdowns or crashes may prevent the cleanup.
  2. Implement a persistent tracking system (possibly on the TypeScript side) that records these unique directories. This system can then be used to clean up these directories during a subsequent session.

Metadata

Metadata

Assignees

Labels

Language ServiceinternalUsed to opt-out an issue from having GitHub actions applied to itmore votes neededIssues that have been postponed until more community members upvote it

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions