-
Notifications
You must be signed in to change notification settings - Fork 34
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
Use different directories for cluster marker tests #1628
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just checking, is it intentional to "leak" those temporary files after every test?
No, it is not. Now with |
Sorry for missing the point of |
The PR now seems to pass and should not leave temporary files around. Merging it. |
Multiple NamedTempFiles are created in the same directory. Therefore, it happens that the cluster marker test can interfere with each other. This commit separates the cluster marker tests by creating a temporary directory in which the cluster marker file gets created. This fixes restatedev#1626.
561c128
to
123ad9c
Compare
We can try that. I'm still not sure I understand how does it fix the actual root cause though. |
The problem was that we only created a temporary file for the cluster marker and not a temporary directory. The temporary files were all located in the same directory. When writing the new cluster marker, the process is that we first create the temporary cluster marker in the parent directory and then rename it. Since the temporary cluster marker has a fixed name, the different tests can interfere with each other since they share the same parent directory. |
Multiple NamedTempFiles are created in the same directory. Therefore,
it happens that the cluster marker test can interfere with each other.
This commit separates the cluster marker tests by creating a temporary
directory in which the cluster marker file gets created.
This fixes #1626.