[Bugfix:InstructorUI] Fix DockerUI instability#12216
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #12216 +/- ##
=========================================
Coverage 21.71% 21.71%
Complexity 9612 9612
=========================================
Files 268 268
Lines 36070 36070
Branches 475 475
=========================================
Hits 7832 7832
Misses 27767 27767
Partials 471 471
Flags with carried forward coverage won't be shown. Click here to find out more. 🚀 New features to boost your workflow:
|
Chriun
approved these changes
Nov 24, 2025
Contributor
Chriun
left a comment
There was a problem hiding this comment.
Didn't test, but the debugging done here definitely seems correct. I agree that since it wouldn't be likely that this would occur in production we can just add an explicit wait, but it would be good to keep in mind if something does happen in the future.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why is this Change Important & Necessary?
Docker UI has been failing. The reason is that the tests run too fast. Look at the following snippet to see reason:
Modify: 2025-11-23 22:22:11.781514464 -0500
Modify: 2025-11-23 22:22:11.029512364 -0500
With nanosecond precision, we can see this error clearly. However, PHP's
filemtimestops at the seconds level, as shown by the code belowContainers mtime: 1763954531
Last update mtime: 1763954531
What is the New Behavior?
The most simple fix would be to change the docker test to introduce a one second delay. However, this would only fix the test and not the production grade issue that it can cause. However, since PHP does not have a built in function to get file time by the nanoseconds (if the operating system has nanoseconds in the first place), this would be pretty hard to implement. Furthermore, this should rarely pop up as instructors are usually not updating docker / remove docker / adding docker images in the same nanosecond. Would be open to feedback, but as of now, I will add a one second wait to the docker test to fix this issue.
What steps should a reviewer take to reproduce or test the bug or new feature?
Look above
Automated Testing & Documentation
Other information