Comments (4)
Idea: I think that perhaps this was due to a situation where the gexe
was starting some processes but not necessarily blocking to wait for them. As a result things like the creation/deletes wouldn't complete and there would be orphaned containers.
One way to mitigate this is just to do something in make test
which will run a clean
routine first. That way we can clear up any existing clusters.
from e2e-framework.
@johnSchnake isn't it being created here? https://github.com/kubernetes-sigs/e2e-framework/blob/main/klient/k8s/resources/main_test.go#L96
from e2e-framework.
So the issue isn't that I dont know where it got made in code, the point is that it exists on the host before it ever should, presumably from a previous run.
For instance, https://prow.k8s.io/view/gs/kubernetes-jenkins/pr-logs/pull/kubernetes-sigs_e2e-framework/63/pull-e2e-framework-test/1448519284388007936#1:build-log.txt%3A46 is the first time in those tests that it is making a cluster but there are already 5 that show up as having been created (just a few lines below that linked spot)
As I am pasting all the "supporting confusion" I do see something that partially explains it though. Despite the logs being written the way they are, the timestamps show that all the Creating kind cluster ...
code is getting executed near the same time.
So I thought that all of this was happening in series (I even saw a PR about wanting tests in parallel eventually), and the logs look like those creation events are in series separated by lots of time, they are actually all happening around the same moment.
This also helps explain why when I added more things like
- why does kind get installed multiple times? Because all the checks happen before kind finishes getting installed the first time
- why do we get the
file is busy
error even though we thought the tests we going in series? There seems to be more contention around the use of that file than I thought since the tests (or the setup at least) happens in parallel.
I think the issue is that the way it is invoked go test ... $(go list ./...)
; I'm guessing that the go tool runs each of those packages in parallel, but each package in series? Something like that.
from e2e-framework.
https://medium.com/@xcoulon/how-to-avoid-parallel-execution-of-tests-in-golang-763d32d88eec describes exactly the same issue; tests werent in parallel but go was running packages in parallel causing racy behavior.
This also explains why I can't repro locally (different GOMAXPROCS set I'm assuming)
Should get a fix for this soon if all I have to do is change -p 1
from e2e-framework.
Related Issues (20)
- Failed to create cluster with kind podman HOT 2
- Calling `Config`'s `Client()` in tests running parallel yields a data race HOT 6
- Create Kind Cluster without test Function HOT 6
- Allow adding custom labels and annotations when creating namespace HOT 3
- How to use BeforeEachTest HOT 13
- Ambiguous call to `cfg.Client()` in `CreateClusterWithConfig` HOT 4
- ,
- Do not share config across tests HOT 3
- Why does `-parallel` and `-fail-fast` can't be used together? HOT 8
- Running `t.FailNow()` in Assess does not fail the following assess HOT 4
- decoder.ApplyWithManifestDir fails to decode yaml with comments in it HOT 5
- Importing "sigs.k8s.io/e2e-framework/klient/conf" causes: ` k8s.io/api/flowcontrol/v1alpha1: module k8s.io/api@latest found (v0.29.3), but does not contain package k8s.io/api/flowcontrol/v1alpha1` HOT 7
- Better error output from Kwok provider HOT 2
- Embedded Local Registry HOT 4
- Test suite is executed even if the setup failed HOT 2
- CLI flags for "running only given features" will skip whole test if a feature in the env doesn't match the criteria. HOT 2
- Instructions in README are outdated and use deprecated functions HOT 5
- `Flux` Integration test with `kyverno` is flaking HOT 1
- imdario/mergo module rename is creating issues with go mod tidy HOT 2
- Handling of interrupt signal during long running tests HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from e2e-framework.