Skip to content

Temporary files created by CLI are not deleted in some cases #5239

Closed
@rosen-vladimirov

Description

@rosen-vladimirov

Environment
Provide version numbers for the following components (information can be retrieved by running tns info in your project folder or by inspecting the package.json of the project):

  • CLI: 6.3.3
  • Cross-platform modules: Not applicable
  • Android Runtime: Not applicable
  • iOS Runtime: Not applicable
  • Plugin(s): Not applicable

Describe the bug
During some of the CLI operations, temporary files are created. In case CLI's process is killed (via Ctrl+C or some other way), the temporary files remain in the temp directories.

To Reproduce

tns create myApp --js
cd myApp
tns prepare android --log trace
Ctrl + C once the webpack build starts

Now check the logs for message in format:

Calling pacoteService.extractPackage for packageName: 'tns-android@6.3.1', destinationDir: 'C:\Users\VLADIM~1\AppData\Local\Temp\runtimeDir12014-5172-11uveur.rfos' and options: undefined

Check the mentioned location and you'll see it still exist, even when you've killed the CLI process.

Expected behavior
All temp files must be deleted.

Sample project

Additional context

Metadata

Metadata

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions