Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FP] MissingTemporaryFileDeletion срабатывает при асинхронном удалении #3260

Open
vkostyanetsky opened this issue Apr 6, 2024 · 0 comments
Labels
good first issue Good for newcomers type/FP False positive

Comments

@vkostyanetsky
Copy link
Contributor

vkostyanetsky commented Apr 6, 2024

Диагностика

MissingTemporaryFileDeletion

Версия

1.13.0

Описание ложного срабатывания диагностики

Диагностика срабатывает, несмотря на то, что временный файл удаляется в асинхронной процедуре.

Пример кода

Временный файл удаляется в обеих методах ниже, но для CreateCSRAsync() диагностика сработает.

&AtClient
Async Procedure CreateCSRAsync() 

	FileName = GetTempFileName(".properties");
			
	Try
		DeleteFilesAsync(FileName); 
	Except
		CommonUseClientServer.MessageToUser("Cannot delete the temporary file!");
	EndTry;
	
EndProcedure

&AtClient
Procedure CreateCSR() 

	FileName = GetTempFileName(".properties");
			
	Try
		DeleteFiles(FileName); 
	Except
		CommonUseClientServer.MessageToUser("Cannot delete the temporary file!");
	EndTry;	
	
EndProcedure

Скриншоты

001 image_2024-03-13_20-54-11

@vkostyanetsky vkostyanetsky added the type/FP False positive label Apr 6, 2024
@theshadowco theshadowco added the good first issue Good for newcomers label Jul 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers type/FP False positive
Projects
None yet
Development

No branches or pull requests

2 participants