Revert "Makefile: scripts: Add build args for proxy when using docker…

… build"
This reverts commit 51171296c9b24c1e8b8d2a5fb500456d8302fddb.
Let's configure our CI to use redsocks instead, which theoretically helps us to avoid the whole proxy madness.

$ ./run-local.sh -u
::info:: Bootstrap the local machine

PLAY [all] ***********************************************************************************************

TASK [Gathering Facts] ***********************************************************************************
ok: [localhost]

TASK [Install build packages] ****************************************************************************
ok: [localhost]

TASK [Download Go tarball] *******************************************************************************
ok: [localhost]

TASK [Extract Go tarball] ********************************************************************************
changed: [localhost]

TASK [Create link to go binary] **************************************************************************
changed: [localhost]

TASK [Check docker is installed] *************************************************************************
changed: [localhost]

TASK [Install docker dependencies] ***********************************************************************
skipping: [localhost]

TASK [Add docker repo GPG key] ***************************************************************************
skipping: [localhost]

TASK [Add docker repo] ***********************************************************************************
skipping: [localhost]

TASK [Install docker packages] ***************************************************************************
skipping: [localhost]

TASK [Create the docker group] ***************************************************************************
skipping: [localhost]

TASK [Install docker packages] ***************************************************************************
skipping: [localhost]

TASK [Create the docker group] ***************************************************************************
skipping: [localhost]

TASK [Install docker packages] ***************************************************************************
skipping: [localhost]

TASK [Create the docker group] ***************************************************************************
skipping: [localhost]

TASK [Install yum-utils] *********************************************************************************
skipping: [localhost]

TASK [Add docker yum repo] *******************************************************************************
skipping: [localhost]

TASK [Install docker packages] ***************************************************************************
skipping: [localhost]

TASK [Get FragmentPath] **********************************************************************************
skipping: [localhost]

TASK [Copy fragment file to /etc/systemd/system/docker.service.d] ****************************************
skipping: [localhost]

TASK [Check if /etc/systemd/system/docker.service has StartLimitBurst=0] *********************************
skipping: [localhost]

TASK [Replace a value of StartLimitBurst to 0] ***********************************************************
skipping: [localhost]

TASK [Otherwise, insert `StartLimitBurst=0` just after a service section] ********************************
skipping: [localhost]

TASK [Reload systemd] ************************************************************************************
skipping: [localhost]

TASK [Install yum-utils] *********************************************************************************
skipping: [localhost]

TASK [Add docker yum repo] *******************************************************************************
skipping: [localhost]

TASK [Install docker packages] ***************************************************************************
skipping: [localhost]

TASK [Start docker service] ******************************************************************************
ok: [localhost]

TASK [Check qemu-user-static is installed] ***************************************************************
skipping: [localhost]

TASK [Install qemu-user-static] **************************************************************************
skipping: [localhost]

PLAY [all] ***********************************************************************************************

TASK [Gathering Facts] ***********************************************************************************
ok: [localhost]

TASK [Install containerd from distro] ********************************************************************
ok: [localhost]

TASK [Re-create containerd config] ***********************************************************************
changed: [localhost]

TASK [Restart containerd service] ************************************************************************
changed: [localhost]

PLAY [all] ***********************************************************************************************

TASK [Gathering Facts] ***********************************************************************************
ok: [localhost]

TASK [Install kubeadm required packages] *****************************************************************
ok: [localhost]

TASK [Create CNI home directory] *************************************************************************
changed: [localhost]

TASK [Download CNI plugins] ******************************************************************************
ok: [localhost]

TASK [Install CNI plugins] *******************************************************************************
changed: [localhost]

TASK [Download crictl] ***********************************************************************************
ok: [localhost]

TASK [Install crictl] ************************************************************************************
changed: [localhost]

TASK [Install kube binaries] *****************************************************************************
changed: [localhost] => (item=kubeadm)
changed: [localhost] => (item=kubelet)
changed: [localhost] => (item=kubectl)

TASK [Remove zram-generator-defaults in Fedora] **********************************************************
skipping: [localhost]

TASK [Disable swap] **************************************************************************************
ok: [localhost]

TASK [Disable swap in fstab] *****************************************************************************
ok: [localhost]

TASK [Create kubelet service] ****************************************************************************
changed: [localhost]

TASK [Create kubelet.service.d directory] ****************************************************************
changed: [localhost]

TASK [Create kubeadm service config] *********************************************************************
changed: [localhost]

TASK [Create kubeadm configuration directory] ************************************************************
changed: [localhost]

TASK [Create kubeadm configuration file] *****************************************************************
changed: [localhost]

TASK [Reload systemd configuration] **********************************************************************
ok: [localhost]

TASK [Start kubelet service] *****************************************************************************
changed: [localhost]

TASK [Create flannel home directory] *********************************************************************
changed: [localhost]

TASK [Create flannel deployment file] ********************************************************************
changed: [localhost]

PLAY [all] ***********************************************************************************************

TASK [Gathering Facts] ***********************************************************************************
ok: [localhost]

TASK [Install python3-docker and python3-requests] *******************************************************
ok: [localhost]

TASK [Start a docker registry] ***************************************************************************
changed: [localhost]

PLAY [all] ***********************************************************************************************

TASK [Gathering Facts] ***********************************************************************************
ok: [localhost]

TASK [Install test dependencies] *************************************************************************
ok: [localhost]

TASK [shell] *********************************************************************************************
fatal: [localhost]: FAILED! => {"changed": true, "cmd": "command -v bats >/dev/null 2>&1", "delta": "0:00:00.006332", "end": "2024-06-21 00:48:55.262881", "msg": "non-zero return code", "rc": 127, "start": "2024-06-21 00:48:55.256549", "stderr": "", "stderr_lines": [], "stdout": "", "stdout_lines": []}
...ignoring

TASK [Clone bats repository] *****************************************************************************
changed: [localhost]

TASK [Install bats] **************************************************************************************
changed: [localhost]

TASK [Remove bats sources] *******************************************************************************
changed: [localhost]

TASK [Check kustomize is installed] **********************************************************************
fatal: [localhost]: FAILED! => {"changed": true, "cmd": "command -v kustomize >/dev/null 2>&1", "delta": "0:00:00.006108", "end": "2024-06-21 00:48:59.121956", "msg": "non-zero return code", "rc": 127, "start": "2024-06-21 00:48:59.115848", "stderr": "", "stderr_lines": [], "stdout": "", "stdout_lines": []}
...ignoring

TASK [Install kustomize] *********************************************************************************
changed: [localhost]

TASK [Download Go tarball] *******************************************************************************
ok: [localhost]

TASK [Extract Go tarball] ********************************************************************************
skipping: [localhost]

TASK [Create link to go binary] **************************************************************************
ok: [localhost]

PLAY RECAP ***********************************************************************************************
localhost                  : ok=43   changed=24   unreachable=0    failed=0    skipped=25   rescued=0    ignored=2

::info:: Bring up the test cluster
[init] Using Kubernetes version: v1.24.0
[preflight] Running pre-flight checks
	[WARNING SystemVerification]: missing optional cgroups: blkio
[preflight] Pulling images required for setting up a Kubernetes cluster
[preflight] This might take a minute or two, depending on the speed of your internet connection
[preflight] You can also perform this action in beforehand using 'kubeadm config images pull'
[certs] Using certificateDir folder "/etc/kubernetes/pki"
[certs] Generating "ca" certificate and key
[certs] Generating "apiserver" certificate and key
[certs] apiserver serving cert is signed for DNS names [984fee00befb.jf.intel.com kubernetes kubernetes.default kubernetes.default.svc kubernetes.default.svc.cluster.local] and IPs [<IP_ADDRESS> <IP_ADDRESS>]
[certs] Generating "apiserver-kubelet-client" certificate and key
[certs] Generating "front-proxy-ca" certificate and key
[certs] Generating "front-proxy-client" certificate and key
[certs] Generating "etcd/ca" certificate and key
[certs] Generating "etcd/server" certificate and key
[certs] etcd/server serving cert is signed for DNS names [984fee00befb.jf.intel.com localhost] and IPs [<IP_ADDRESS> <IP_ADDRESS> ::1]
[certs] Generating "etcd/peer" certificate and key
[certs] etcd/peer serving cert is signed for DNS names [984fee00befb.jf.intel.com localhost] and IPs [<IP_ADDRESS> <IP_ADDRESS> ::1]
[certs] Generating "etcd/healthcheck-client" certificate and key
[certs] Generating "apiserver-etcd-client" certificate and key
[certs] Generating "sa" key and public key
[kubeconfig] Using kubeconfig folder "/etc/kubernetes"
[kubeconfig] Writing "admin.conf" kubeconfig file
[kubeconfig] Writing "kubelet.conf" kubeconfig file
[kubeconfig] Writing "controller-manager.conf" kubeconfig file
[kubeconfig] Writing "scheduler.conf" kubeconfig file
[kubelet-start] Writing kubelet environment file with flags to file "/var/lib/kubelet/kubeadm-flags.env"
[kubelet-start] Writing kubelet configuration to file "/var/lib/kubelet/config.yaml"
[kubelet-start] Starting the kubelet
[control-plane] Using manifest folder "/etc/kubernetes/manifests"
[control-plane] Creating static Pod manifest for "kube-apiserver"
[control-plane] Creating static Pod manifest for "kube-controller-manager"
[control-plane] Creating static Pod manifest for "kube-scheduler"
[etcd] Creating static Pod manifest for local etcd in "/etc/kubernetes/manifests"
[wait-control-plane] Waiting for the kubelet to boot up the control plane as static Pods from directory "/etc/kubernetes/manifests". This can take up to 4m0s
[apiclient] All control plane components are healthy after 9.005904 seconds
[upload-config] Storing the configuration used in ConfigMap "kubeadm-config" in the "kube-system" Namespace
[kubelet] Creating a ConfigMap "kubelet-config" in namespace kube-system with the configuration for the kubelets in the cluster
[upload-certs] Skipping phase. Please see --upload-certs
[mark-control-plane] Marking the node 984fee00befb.jf.intel.com as control-plane by adding the labels: [node-role.kubernetes.io/control-plane node.kubernetes.io/exclude-from-external-load-balancers]
[mark-control-plane] Marking the node 984fee00befb.jf.intel.com as control-plane by adding the taints [node-role.kubernetes.io/master:NoSchedule node-role.kubernetes.io/control-plane:NoSchedule]
[bootstrap-token] Using token: h24ap9.30xq1ih0xfrqlq3m
[bootstrap-token] Configuring bootstrap tokens, cluster-info ConfigMap, RBAC Roles
[bootstrap-token] Configured RBAC rules to allow Node Bootstrap tokens to get nodes
[bootstrap-token] Configured RBAC rules to allow Node Bootstrap tokens to post CSRs in order for nodes to get long term certificate credentials
[bootstrap-token] Configured RBAC rules to allow the csrapprover controller automatically approve CSRs from a Node Bootstrap Token
[bootstrap-token] Configured RBAC rules to allow certificate rotation for all node client certificates in the cluster
[bootstrap-token] Creating the "cluster-info" ConfigMap in the "kube-public" namespace
[kubelet-finalize] Updating "/etc/kubernetes/kubelet.conf" to point to a rotatable kubelet client certificate and key
[addons] Applied essential addon: CoreDNS
[addons] Applied essential addon: kube-proxy

Your Kubernetes control-plane has initialized successfully!

To start using your cluster, you need to run the following as a regular user:

  mkdir -p $HOME/.kube
  sudo cp -i /etc/kubernetes/admin.conf $HOME/.kube/config
  sudo chown $(id -u):$(id -g) $HOME/.kube/config

Alternatively, if you are the root user, you can run:

  export KUBECONFIG=/etc/kubernetes/admin.conf

You should now deploy a pod network to the cluster.
Run "kubectl apply -f [podnetwork].yaml" with one of the options listed at:
  https://kubernetes.io/docs/concepts/cluster-administration/addons/

Then you can join any number of worker nodes by running the following on each as root:

kubeadm join <IP_ADDRESS>:6443 --token h24ap9.30xq1ih0xfrqlq3m \
	--discovery-token-ca-cert-hash sha256:f5e1dd934e583bc8bce3e6c966fac5bc2315cfc20e4e4644041f5ff301498ed4
namespace/kube-flannel created
clusterrole.rbac.authorization.k8s.io/flannel created
clusterrolebinding.rbac.authorization.k8s.io/flannel created
serviceaccount/flannel created
configmap/kube-flannel-cfg created
daemonset.apps/kube-flannel-ds created
node/984fee00befb.jf.intel.com untainted
node/984fee00befb.jf.intel.com untainted
node/984fee00befb.jf.intel.com labeled
::info:: Build and install the operator
::debug:: Repo /home/sdp/cc-operator already in git's safe.directory
test -s /home/sdp/cc-operator/bin/controller-gen || GOBIN=/home/sdp/cc-operator/bin go install<EMAIL_ADDRESS>/home/sdp/cc-operator/bin/controller-gen rbac:roleName=manager-role crd webhook paths="./..." output:crd:artifacts:config=config/crd/bases
/home/sdp/cc-operator/bin/controller-gen object:headerFile="hack/boilerplate.go.txt" paths="./..."
go fmt ./...
go vet ./...
test -s /home/sdp/cc-operator/bin/setup-envtest || GOBIN=/home/sdp/cc-operator/bin go install sigs.k8s.io/controller-runtime/tools/setup-envtest@latest
KUBEBUILDER_ASSETS="/home/sdp/.local/share/kubebuilder-envtest/k8s/1.24.2-linux-amd64" go test ./... -coverprofile cover.out
?   	github.com/confidential-containers/operator	[no test files]
?   	github.com/confidential-containers/operator/api/v1beta1	[no test files]
ok  	github.com/confidential-containers/operator/controllers	0.069s	coverage: 0.0% of statements
docker build -t localhost:5000/cc-operator:latest .
[+] Building 48.9s (17/17) FINISHED                                                        docker:default
 => [internal] load build definition from Dockerfile                                                 0.0s
 => => transferring dockerfile: 957B                                                                 0.0s
 => [internal] load .dockerignore                                                                    0.0s
 => => transferring context: 2B                                                                      0.0s
 => [internal] load metadata for gcr.io/distroless/static:nonroot                                    0.5s
 => [internal] load metadata for docker.io/library/golang:1.20                                       0.6s
 => CACHED [stage-1 1/3] FROM gcr.io/distroless/static:nonroot@sha256:e9ac71e2b8e279a8372741b7a0293  0.0s
 => [builder 1/9] FROM docker.io/library/golang:1.20@sha256:8f9af7094d0cb27cc783c697ac5ba25efdc4da3  0.0s
 => [internal] load build context                                                                    0.0s
 => => transferring context: 14.04kB                                                                 0.0s
 => CACHED [builder 2/9] WORKDIR /workspace                                                          0.0s
 => CACHED [builder 3/9] COPY go.mod go.mod                                                          0.0s
 => CACHED [builder 4/9] COPY go.sum go.sum                                                          0.0s
 => [builder 5/9] RUN go mod download                                                                6.5s
 => [builder 6/9] COPY main.go main.go                                                               0.0s
 => [builder 7/9] COPY api/ api/                                                                     0.1s
 => [builder 8/9] COPY controllers/ controllers/                                                     0.3s
 => [builder 9/9] RUN CGO_ENABLED=0 GOOS=linux go build -a -o manager main.go                       40.6s
 => [stage-1 2/3] COPY --from=builder /workspace/manager .                                           0.2s
 => exporting to image                                                                               0.4s
 => => exporting layers                                                                              0.4s
 => => writing image sha256:90f27bee4570c6cd8e4e801d1ec7fec5ffaf365e8bc725e3a547390267e3c676         0.0s
 => => naming to localhost:5000/cc-operator:latest                                                   0.0s
docker push localhost:5000/cc-operator:latest
The push refers to repository [localhost:5000/cc-operator]
ee6753ff7115: Pushed
b336e209998f: Pushed
f4aee9e53c42: Pushed
1a73b54f556b: Pushed
2a92d6ac9e4f: Pushed
bbb6cacb8c82: Pushed
ac805962e479: Pushed
af5aa97ebe6c: Pushed
4d049f83d9cf: Pushed
945d17be9a3e: Pushed
49626df344c9: Pushed
3d6fa0469044: Pushed
latest: digest: sha256:8dfa32006a940c543197cbe3fc52ebda40315bfb49cb19455ded658a2d69f9b7 size: 2814
::debug:: system's containerd version: 1.7.12
namespace/confidential-containers-system created
customresourcedefinition.apiextensions.k8s.io/ccruntimes.confidentialcontainers.org created
serviceaccount/cc-operator-controller-manager created
role.rbac.authorization.k8s.io/cc-operator-leader-election-role created
clusterrole.rbac.authorization.k8s.io/cc-operator-manager-role created
clusterrole.rbac.authorization.k8s.io/cc-operator-metrics-reader created
clusterrole.rbac.authorization.k8s.io/cc-operator-proxy-role created
rolebinding.rbac.authorization.k8s.io/cc-operator-leader-election-rolebinding created
clusterrolebinding.rbac.authorization.k8s.io/cc-operator-manager-rolebinding created
clusterrolebinding.rbac.authorization.k8s.io/cc-operator-proxy-rolebinding created
configmap/cc-operator-manager-config created
service/cc-operator-controller-manager-metrics-service created
deployment.apps/cc-operator-controller-manager created
coco_containerd_version=<IP_ADDRESS> \
official_containerd_version=1.7.7 \
vfio_gpu_containerd_version=<IP_ADDRESS> \
nydus_snapshotter_version=v0.13.13 \
bash -x payload.sh
+ set -o errexit
+ set -o pipefail
+ set -o nounset
+++ readlink -f payload.sh
++ dirname /home/sdp/cc-operator/install/pre-install-payload/payload.sh
+ script_dir=/home/sdp/cc-operator/install/pre-install-payload
+ coco_containerd_repo=https://github.com/confidential-containers/containerd
+ official_containerd_repo=https://github.com/containerd/containerd
+ vfio_gpu_containerd_repo=https://github.com/confidential-containers/containerd
+ nydus_snapshotter_repo=https://github.com/containerd/nydus-snapshotter
++ mktemp -d -t containerd-XXXXXXXXXX
+ containerd_dir=/tmp/containerd-1cJbbb2HkC/containerd
+ extra_docker_manifest_flags=--insecure
+ registry=localhost:5000/reqs-payload
+ supported_arches=("linux/amd64" "linux/s390x")
+ main
+ build_payload
+ pushd /home/sdp/cc-operator/install/pre-install-payload
~/cc-operator/install/pre-install-payload ~/cc-operator/install/pre-install-payload
+ local tag
++ git rev-parse HEAD
+ tag=6a496310b2648d48b3ad23a54a9630ec1ef9791c
+ manifest_args=()
+ for arch in "${supported_arches[@]}"
+ setup_env_for_arch linux/amd64
+ case "$1" in
+ kernel_arch=x86_64
+ golang_arch=amd64
+ echo 'Building containerd payload image for linux/amd64'
Building containerd payload image for linux/amd64
+ docker buildx build --build-arg ARCH=amd64 --build-arg COCO_CONTAINERD_VERSION=<IP_ADDRESS> --build-arg COCO_CONTAINERD_REPO=https://github.com/confidential-containers/containerd --build-arg OFFICIAL_CONTAINERD_VERSION=1.7.7 --build-arg OFFICIAL_CONTAINERD_REPO=https://github.com/containerd/containerd --build-arg VFIO_GPU_CONTAINERD_VERSION=<IP_ADDRESS> --build-arg VFIO_GPU_CONTAINERD_REPO=https://github.com/confidential-containers/containerd --build-arg NYDUS_SNAPSHOTTER_VERSION=v0.13.13 --build-arg NYDUS_SNAPSHOTTER_REPO=https://github.com/containerd/nydus-snapshotter -t localhost:5000/reqs-payload:x86_64-6a496310b2648d48b3ad23a54a9630ec1ef9791c --platform=linux/amd64 --load .
[+] Building 31.2s (23/23) FINISHED                                                        docker:default
 => [internal] load .dockerignore                                                                    0.0s
 => => transferring context: 2B                                                                      0.0s
 => [internal] load build definition from Dockerfile                                                 0.0s
 => => transferring dockerfile: 4.88kB                                                               0.0s
 => [internal] load metadata for docker.io/library/golang:1.19-alpine                                0.9s
 => [internal] load metadata for docker.io/library/alpine:3.18                                       1.2s
 => [nydus-binary-downloader 1/2] FROM docker.io/library/golang:1.19-alpine@sha256:0ec0646e208ea58  24.5s
 => => resolve docker.io/library/golang:1.19-alpine@sha256:0ec0646e208ea58e5d29e558e39f2e59fccf39b7  0.0s
 => => sha256:0ec0646e208ea58e5d29e558e39f2e59fccf39b7bda306cb53bbaff91919eca5 1.65kB / 1.65kB       0.0s
 => => sha256:276692412aea6f9dd6cdc5725b2f1c05bef8df7223811afbc6aa16294e2903f9 1.16kB / 1.16kB       0.0s
 => => sha256:5da886f1a5e71f657d8205d2b8aec7c3de24070327553634520503326e53ae14 5.18kB / 5.18kB       0.0s
 => => sha256:7264a8db6415046d36d16ba98b79778e18accee6ffa71850405994cffa9be7de 3.40MB / 3.40MB       0.2s
 => => sha256:c4d48a809fc2256f8aa0aeee47998488d64409855adba00a7cb3007ab9f3286e 284.69kB / 284.69kB   0.1s
 => => sha256:e2e938b6148703b9e1e60b0db2cd54d7cfd2bd17c38fdd5b379bc4d4d5ec5285 122.48MB / 122.48MB   1.5s
 => => sha256:7896c2688058484dc40121d0b4e0a6133add530a2091f409987d54e8ffbac5ec 155B / 155B           0.3s
 => => extracting sha256:7264a8db6415046d36d16ba98b79778e18accee6ffa71850405994cffa9be7de            0.3s
 => => extracting sha256:c4d48a809fc2256f8aa0aeee47998488d64409855adba00a7cb3007ab9f3286e            0.1s
 => => extracting sha256:e2e938b6148703b9e1e60b0db2cd54d7cfd2bd17c38fdd5b379bc4d4d5ec5285           21.8s
 => => extracting sha256:7896c2688058484dc40121d0b4e0a6133add530a2091f409987d54e8ffbac5ec            0.0s
 => [internal] load build context                                                                    0.0s
 => => transferring context: 11.20kB                                                                 0.0s
 => [base 1/1] FROM docker.io/library/alpine:3.18@sha256:1875c923b73448b558132e7d4a44b815d078779ed7  0.9s
 => => resolve docker.io/library/alpine:3.18@sha256:1875c923b73448b558132e7d4a44b815d078779ed7a73f7  0.0s
 => => sha256:1875c923b73448b558132e7d4a44b815d078779ed7a73f76209c6372de95ea8d 1.64kB / 1.64kB       0.0s
 => => sha256:d9a39933bee4ccb6d934b7b5632cdf8c42658f3cecc5029681338f397142af6e 528B / 528B           0.0s
 => => sha256:8fd7cac70a4aaabb31d459b03e3534b14341c31429b678b650039ac45a606cfc 1.47kB / 1.47kB       0.0s
 => => sha256:73baa7ef167e70f1c0233fe09e741780d780ea16e78b3c1b6f4216e2afbbd03e 3.41MB / 3.41MB       0.4s
 => => extracting sha256:73baa7ef167e70f1c0233fe09e741780d780ea16e78b3c1b6f4216e2afbbd03e            0.3s
 => [coco-containerd-binary-downloader 1/1] RUN  mkdir -p /opt/confidential-containers-pre-install-  7.6s
 => [kubectl-binary-downloader 1/1] RUN  apk --no-cache add curl &&  curl -fL --progress-bar -o /us  6.6s
 => [vfio-gpu-containerd-binary-downloader 1/1] RUN  mkdir -p /opt/confidential-containers-pre-inst  8.0s
 => [stage-6  1/10] RUN apk --no-cache add bash gcompat                                              5.3s
 => [official-containerd-binary-downloader 1/1] RUN  mkdir -p /opt/confidential-containers-pre-inst  8.0s
 => [stage-6  2/10] COPY --from=coco-containerd-binary-downloader /opt/confidential-containers-pre-  0.2s
 => [stage-6  3/10] COPY --from=official-containerd-binary-downloader /opt/confidential-containers-  0.2s
 => [stage-6  4/10] COPY --from=vfio-gpu-containerd-binary-downloader /opt/confidential-containers-  0.2s
 => [nydus-binary-downloader 2/2] RUN mkdir -p /opt/confidential-containers-pre-install-artifacts/o  4.0s
 => [stage-6  5/10] COPY --from=nydus-binary-downloader /opt/confidential-containers-pre-install-ar  0.2s
 => [stage-6  6/10] COPY --from=kubectl-binary-downloader /usr/bin/kubectl /usr/bin/kubectl          0.2s
 => [stage-6  7/10] COPY ./containerd/containerd-for-cc-override.conf /opt/confidential-containers-  0.0s
 => [stage-6  8/10] COPY ./remote-snapshotter/nydus-snapshotter/nydus-snapshotter.service /opt/conf  0.0s
 => [stage-6  9/10] COPY ./remote-snapshotter/nydus-snapshotter/config-coco-guest-pulling.toml /opt  0.0s
 => [stage-6 10/10] COPY ./scripts/* /opt/confidential-containers-pre-install-artifacts/scripts/     0.0s
 => exporting to image                                                                               0.4s
 => => exporting layers                                                                              0.4s
 => => writing image sha256:5a3631e3625d6aeab3e76710f3724ad13888fb2a96f5d48542eaddb6d3d339c1         0.0s
 => => naming to localhost:5000/reqs-payload:x86_64-6a496310b2648d48b3ad23a54a9630ec1ef9791c         0.0s
+ docker push localhost:5000/reqs-payload:x86_64-6a496310b2648d48b3ad23a54a9630ec1ef9791c
The push refers to repository [localhost:5000/reqs-payload]
7c4d5e0d3fb9: Pushed
2338503b35b8: Pushed
781580df0b20: Pushed
af671a8251df: Pushed
31945c10bfc9: Pushed
11b4160c84ad: Pushed
29173137a82c: Pushed
92e4f6166f12: Pushed
35c5f1ecacee: Pushed
aa85c9a7e05e: Pushed
63ec0bd56cf3: Pushed
x86_64-6a496310b2648d48b3ad23a54a9630ec1ef9791c: digest: sha256:14dd2f85ea80b3eb6cfc247d8d4fb0c763d9c1eefb10e959a6ad2ba400d6baa1 size: 2627
+ manifest_args+=(--amend "${registry}:${kernel_arch##*/}-${tag}")
+ for arch in "${supported_arches[@]}"
+ setup_env_for_arch linux/s390x
+ case "$1" in
+ kernel_arch=s390x
+ golang_arch=s390x
+ echo 'Building containerd payload image for linux/s390x'
Building containerd payload image for linux/s390x
+ docker buildx build --build-arg ARCH=s390x --build-arg COCO_CONTAINERD_VERSION=<IP_ADDRESS> --build-arg COCO_CONTAINERD_REPO=https://github.com/confidential-containers/containerd --build-arg OFFICIAL_CONTAINERD_VERSION=1.7.7 --build-arg OFFICIAL_CONTAINERD_REPO=https://github.com/containerd/containerd --build-arg VFIO_GPU_CONTAINERD_VERSION=<IP_ADDRESS> --build-arg VFIO_GPU_CONTAINERD_REPO=https://github.com/confidential-containers/containerd --build-arg NYDUS_SNAPSHOTTER_VERSION=v0.13.13 --build-arg NYDUS_SNAPSHOTTER_REPO=https://github.com/containerd/nydus-snapshotter -t localhost:5000/reqs-payload:s390x-6a496310b2648d48b3ad23a54a9630ec1ef9791c --platform=linux/s390x --load .
[+] Building 38.3s (23/23) FINISHED                                                        docker:default
 => [internal] load .dockerignore                                                                    0.0s
 => => transferring context: 2B                                                                      0.0s
 => [internal] load build definition from Dockerfile                                                 0.0s
 => => transferring dockerfile: 4.88kB                                                               0.0s
 => [internal] load metadata for docker.io/library/golang:1.19-alpine                                0.7s
 => [internal] load metadata for docker.io/library/alpine:3.18                                       0.7s
 => [internal] load build context                                                                    0.0s
 => => transferring context: 510B                                                                    0.0s
 => [base 1/1] FROM docker.io/library/alpine:3.18@sha256:1875c923b73448b558132e7d4a44b815d078779ed7  0.7s
 => => resolve docker.io/library/alpine:3.18@sha256:1875c923b73448b558132e7d4a44b815d078779ed7a73f7  0.0s
 => => sha256:606d0994dba8dcb8d96bdbc4d2fa6aab25b2558dc000b820766733dc7d4534a6 1.47kB / 1.47kB       0.0s
 => => sha256:784fb6b11ccf355c65e296bcf7ef3623ff36c33ac16292b79440c32ec3699700 3.23MB / 3.23MB       0.2s
 => => sha256:1875c923b73448b558132e7d4a44b815d078779ed7a73f76209c6372de95ea8d 1.64kB / 1.64kB       0.0s
 => => sha256:c188397a7c757726752001ff56a1c6abafa66131d7509d80b8c49bcdde8aabcc 528B / 528B           0.0s
 => => extracting sha256:784fb6b11ccf355c65e296bcf7ef3623ff36c33ac16292b79440c32ec3699700            0.3s
 => [nydus-binary-downloader 1/2] FROM docker.io/library/golang:1.19-alpine@sha256:0ec0646e208ea58  25.5s
 => => resolve docker.io/library/golang:1.19-alpine@sha256:0ec0646e208ea58e5d29e558e39f2e59fccf39b7  0.0s
 => => sha256:0ec0646e208ea58e5d29e558e39f2e59fccf39b7bda306cb53bbaff91919eca5 1.65kB / 1.65kB       0.0s
 => => sha256:7b47cff2c98995690cd81fc6d18c0f7b726bf92d375268791e8bcd42553f7862 1.16kB / 1.16kB       0.0s
 => => sha256:8ece8eb6ca448b9da6d6ac6a8ba791f0a5ad3ffb4feb9bf0ef0932da14896346 5.18kB / 5.18kB       0.0s
 => => sha256:8bed2eae372fe236061920d89ae1ce89695a12df84989113bcc7ce4bd9774456 3.21MB / 3.21MB       0.3s
 => => sha256:ec90be18226e5c99d10161aed1a143f4134093c55b4d6979bbdbbe4b0683eb11 285.09kB / 285.09kB   0.4s
 => => sha256:8a62238188658a20afe263e4174c269ab91e68e86bf02db75dac3bbdacfe253c 120.93MB / 120.93MB   2.3s
 => => extracting sha256:8bed2eae372fe236061920d89ae1ce89695a12df84989113bcc7ce4bd9774456            0.3s
 => => sha256:3ac2bd91a23c4e119cd9dc376dcfc3d3d5d128d7f9723eb0d4b575e3d810f15b 156B / 156B           0.5s
 => => extracting sha256:ec90be18226e5c99d10161aed1a143f4134093c55b4d6979bbdbbe4b0683eb11            0.1s
 => => extracting sha256:8a62238188658a20afe263e4174c269ab91e68e86bf02db75dac3bbdacfe253c           22.0s
 => => extracting sha256:3ac2bd91a23c4e119cd9dc376dcfc3d3d5d128d7f9723eb0d4b575e3d810f15b            0.0s
 => [coco-containerd-binary-downloader 1/1] RUN  mkdir -p /opt/confidential-containers-pre-install  17.7s
 => [vfio-gpu-containerd-binary-downloader 1/1] RUN  mkdir -p /opt/confidential-containers-pre-ins  17.7s
 => [stage-6  1/10] RUN apk --no-cache add bash gcompat                                              8.8s
 => [kubectl-binary-downloader 1/1] RUN  apk --no-cache add curl &&  curl -fL --progress-bar -o /u  14.7s
 => [official-containerd-binary-downloader 1/1] RUN  mkdir -p /opt/confidential-containers-pre-ins  20.0s
 => [stage-6  2/10] COPY --from=coco-containerd-binary-downloader /opt/confidential-containers-pre-  0.2s
 => [stage-6  3/10] COPY --from=official-containerd-binary-downloader /opt/confidential-containers-  0.2s
 => [stage-6  4/10] COPY --from=vfio-gpu-containerd-binary-downloader /opt/confidential-containers-  0.2s
 => [nydus-binary-downloader 2/2] RUN mkdir -p /opt/confidential-containers-pre-install-artifacts/  10.7s
 => [stage-6  5/10] COPY --from=nydus-binary-downloader /opt/confidential-containers-pre-install-ar  0.2s
 => [stage-6  6/10] COPY --from=kubectl-binary-downloader /usr/bin/kubectl /usr/bin/kubectl          0.2s
 => [stage-6  7/10] COPY ./containerd/containerd-for-cc-override.conf /opt/confidential-containers-  0.0s
 => [stage-6  8/10] COPY ./remote-snapshotter/nydus-snapshotter/nydus-snapshotter.service /opt/conf  0.0s
 => [stage-6  9/10] COPY ./remote-snapshotter/nydus-snapshotter/config-coco-guest-pulling.toml /opt  0.0s
 => [stage-6 10/10] COPY ./scripts/* /opt/confidential-containers-pre-install-artifacts/scripts/     0.0s
 => exporting to image                                                                               0.4s
 => => exporting layers                                                                              0.4s
 => => writing image sha256:ca45e42e9fb193a85c606f89c6d101597b4e974156a5170b40ef5e715e1f04fc         0.0s
 => => naming to localhost:5000/reqs-payload:s390x-6a496310b2648d48b3ad23a54a9630ec1ef9791c          0.0s
+ docker push localhost:5000/reqs-payload:s390x-6a496310b2648d48b3ad23a54a9630ec1ef9791c
The push refers to repository [localhost:5000/reqs-payload]
2e16dbd547d6: Pushed
92acfc7a741d: Pushed
30a81a02436f: Pushed
ee43530cefd4: Pushed
5694569416c3: Pushed
0a9195626364: Pushed
b6e41598f38b: Pushed
c04de0d01492: Pushed
3985b1badfd8: Pushed
2b0cb965c8b6: Pushed
f645e7050c9d: Pushed
s390x-6a496310b2648d48b3ad23a54a9630ec1ef9791c: digest: sha256:6b7ebd23c6e16878e8cc7061e038b476a66dc13d580699a81bd2d342acb66845 size: 2627
+ manifest_args+=(--amend "${registry}:${kernel_arch##*/}-${tag}")
+ purge_previous_manifests localhost:5000/reqs-payload:6a496310b2648d48b3ad23a54a9630ec1ef9791c
+ local manifest
+ local sanitised_manifest
+ manifest=localhost:5000/reqs-payload:6a496310b2648d48b3ad23a54a9630ec1ef9791c
++ echo localhost:5000/reqs-payload:6a496310b2648d48b3ad23a54a9630ec1ef9791c
++ sed 's|/|_|g'
++ sed 's|:|-|g'
+ sanitised_manifest=localhost-5000_reqs-payload-6a496310b2648d48b3ad23a54a9630ec1ef9791c
+ rm -rf /home/sdp/.docker/manifests/localhost-5000_reqs-payload-6a496310b2648d48b3ad23a54a9630ec1ef9791c
+ purge_previous_manifests localhost:5000/reqs-payload:latest
+ local manifest
+ local sanitised_manifest
+ manifest=localhost:5000/reqs-payload:latest
++ echo localhost:5000/reqs-payload:latest
++ sed 's|/|_|g'
++ sed 's|:|-|g'
+ sanitised_manifest=localhost-5000_reqs-payload-latest
+ rm -rf /home/sdp/.docker/manifests/localhost-5000_reqs-payload-latest
+ docker manifest create --insecure localhost:5000/reqs-payload:6a496310b2648d48b3ad23a54a9630ec1ef9791c --amend localhost:5000/reqs-payload:x86_64-6a496310b2648d48b3ad23a54a9630ec1ef9791c --amend localhost:5000/reqs-payload:s390x-6a496310b2648d48b3ad23a54a9630ec1ef9791c
Created manifest list localhost:5000/reqs-payload:6a496310b2648d48b3ad23a54a9630ec1ef9791c
+ docker manifest create --insecure localhost:5000/reqs-payload:latest --amend localhost:5000/reqs-payload:x86_64-6a496310b2648d48b3ad23a54a9630ec1ef9791c --amend localhost:5000/reqs-payload:s390x-6a496310b2648d48b3ad23a54a9630ec1ef9791c
Created manifest list localhost:5000/reqs-payload:latest
+ docker manifest push --insecure localhost:5000/reqs-payload:6a496310b2648d48b3ad23a54a9630ec1ef9791c
sha256:11ac8ddf52158399c098e27d2591d5d982cdf228c705d12c03e3dfdcc957dd94
+ docker manifest push --insecure localhost:5000/reqs-payload:latest
sha256:11ac8ddf52158399c098e27d2591d5d982cdf228c705d12c03e3dfdcc957dd94
+ popd
~/cc-operator/install/pre-install-payload
ccruntime.confidentialcontainers.org/ccruntime-sample created
::debug:: Pod: cc-operator-controller-manager-ccbbcfdf7-n7vxl, Container: kube-rbac-proxy, Restart count: 0
::debug:: Pod: manager, Container: 0, Restart count:
::debug:: Pod: cc-operator-daemon-install-9mjjp, Container: cc-runtime-install-pod, Restart count: 0
::debug:: Pod: cc-operator-pre-install-daemon-8rtgd, Container: cc-runtime-pre-install-pod, Restart count: 0
::info:: No new restarts in 3x21s, proceeding...
::info:: Run tests
INFO: Running operator tests for kata-qemu
operator_tests.bats
 ✓ [cc][operator] Test can uninstall the operator
 ✓ [cc][operator] Test can reinstall the operator

2 tests, 0 failures

::info:: Uninstall the operator
ccruntime.confidentialcontainers.org "ccruntime-sample" deleted
::error:: there are ccruntime pods still running
::group::Describe pods from confidential-containers-system namespace
Name:         cc-operator-controller-manager-ccbbcfdf7-vt8x6
Namespace:    confidential-containers-system
Priority:     0
Node:         984fee00befb.jf.intel.com/<IP_ADDRESS>
Start Time:   Fri, 21 Jun 2024 01:00:21 -0700
Labels:       control-plane=controller-manager
              pod-template-hash=ccbbcfdf7
Annotations:  <none>
Status:       Running
IP:           <IP_ADDRESS>
IPs:
  IP:           <IP_ADDRESS>
Controlled By:  ReplicaSet/cc-operator-controller-manager-ccbbcfdf7
Containers:
  kube-rbac-proxy:
    Container ID:  containerd://ca45fac7d77d8c16f95785de79fefa8d04bf0160ee6b5ed2a6f7fd993a98bcc8
    Image:         gcr.io/kubebuilder/kube-rbac-proxy:v0.13.1
    Image ID:      gcr.io/kubebuilder/kube-rbac-proxy@sha256:d4883d7c622683b3319b5e6b3a7edfbf2594c18060131a8bf64504805f875522
    Port:          8443/TCP
    Host Port:     0/TCP
    Args:
      --secure-listen-address=<IP_ADDRESS>:8443
      --upstream=http://<IP_ADDRESS>:8080/
      --logtostderr=true
      --v=10
    State:          Running
      Started:      Fri, 21 Jun 2024 01:00:22 -0700
    Ready:          True
    Restart Count:  0
    Environment:    <none>
    Mounts:
      /var/run/secrets/kubernetes.io/serviceaccount from kube-api-access-zvbld (ro)
  manager:
    Container ID:  containerd://6614be18fb7da7803fe6e36f1bfdf487430bae392fce7e22713b2e154f40adf4
    Image:         localhost:5000/cc-operator:latest
    Image ID:      localhost:5000/cc-operator@sha256:8dfa32006a940c543197cbe3fc52ebda40315bfb49cb19455ded658a2d69f9b7
    Port:          <none>
    Host Port:     <none>
    Command:
      /manager
    Args:
      --health-probe-bind-address=:8081
      --metrics-bind-address=<IP_ADDRESS>:8080
      --leader-elect
    State:          Running
      Started:      Fri, 21 Jun 2024 01:00:22 -0700
    Ready:          True
    Restart Count:  0
    Limits:
      cpu:     200m
      memory:  100Mi
    Requests:
      cpu:      100m
      memory:   20Mi
    Liveness:   http-get http://:8081/healthz delay=15s timeout=1s period=20s #success=1 #failure=3
    Readiness:  http-get http://:8081/readyz delay=5s timeout=1s period=10s #success=1 #failure=3
    Environment:
      CCRUNTIME_NAMESPACE:  confidential-containers-system (v1:metadata.namespace)
    Mounts:
      /var/run/secrets/kubernetes.io/serviceaccount from kube-api-access-zvbld (ro)
Conditions:
  Type              Status
  Initialized       True
  Ready             True
  ContainersReady   True
  PodScheduled      True
Volumes:
  kube-api-access-zvbld:
    Type:                    Projected (a volume that contains injected data from multiple sources)
    TokenExpirationSeconds:  3607
    ConfigMapName:           kube-root-ca.crt
    ConfigMapOptional:       <nil>
    DownwardAPI:             true
QoS Class:                   Burstable
Node-Selectors:              <none>
Tolerations:                 node.kubernetes.io/not-ready:NoExecute op=Exists for 300s
                             node.kubernetes.io/unreachable:NoExecute op=Exists for 300s
Events:
  Type     Reason     Age   From               Message
  ----     ------     ----  ----               -------
  Normal   Scheduled  12m   default-scheduler  Successfully assigned confidential-containers-system/cc-operator-controller-manager-ccbbcfdf7-vt8x6 to 984fee00befb.jf.intel.com
  Normal   Pulled     12m   kubelet            Container image "gcr.io/kubebuilder/kube-rbac-proxy:v0.13.1" already present on machine
  Normal   Created    12m   kubelet            Created container kube-rbac-proxy
  Normal   Started    12m   kubelet            Started container kube-rbac-proxy
  Normal   Pulling    12m   kubelet            Pulling image "localhost:5000/cc-operator:latest"
  Normal   Pulled     12m   kubelet            Successfully pulled image "localhost:5000/cc-operator:latest" in 33.701652ms
  Normal   Created    12m   kubelet            Created container manager
  Normal   Started    12m   kubelet            Started container manager
  Warning  Unhealthy  12m   kubelet            Liveness probe failed: Get "http://<IP_ADDRESS>:8081/healthz": context deadline exceeded (Client.Timeout exceeded while awaiting headers)
  Warning  Unhealthy  12m   kubelet            Readiness probe failed: Get "http://<IP_ADDRESS>:8081/readyz": context deadline exceeded (Client.Timeout exceeded while awaiting headers)

Name:         cc-operator-pre-install-daemon-hpjsq
Namespace:    confidential-containers-system
Priority:     0
Node:         984fee00befb.jf.intel.com/<IP_ADDRESS>
Start Time:   Fri, 21 Jun 2024 01:00:36 -0700
Labels:       controller-revision-hash=84f7757fb
              name=cc-operator-pre-install-daemon
              pod-template-generation=1
Annotations:  <none>
Status:       Running
IP:           <IP_ADDRESS>
IPs:
  IP:           <IP_ADDRESS>
Controlled By:  DaemonSet/cc-operator-pre-install-daemon
Containers:
  cc-runtime-pre-install-pod:
    Container ID:  containerd://99e6d5922134b25a7e4bdda520c631f5543ca249624d4b7a02a63f04b533fe30
    Image:         localhost:5000/reqs-payload
    Image ID:      localhost:5000/reqs-payload@sha256:11ac8ddf52158399c098e27d2591d5d982cdf228c705d12c03e3dfdcc957dd94
    Port:          <none>
    Host Port:     <none>
    Command:
      /bin/sh
      -c
      /opt/confidential-containers-pre-install-artifacts/scripts/pre-install.sh
    State:          Running
      Started:      Fri, 21 Jun 2024 01:00:37 -0700
    Ready:          True
    Restart Count:  0
    Environment:
      NODE_NAME:                     (v1:spec.nodeName)
      INSTALL_OFFICIAL_CONTAINERD:  false
    Mounts:
      /etc/containerd/ from containerd-conf (rw)
      /etc/systemd/system/ from etc-systemd-system (rw)
      /opt/confidential-containers/ from confidential-containers-artifacts (rw)
      /usr/local/bin/ from local-bin (rw)
      /var/lib/containerd-nydus/ from containerd-nydus (rw)
      /var/run/secrets/kubernetes.io/serviceaccount from kube-api-access-lszvl (ro)
Conditions:
  Type              Status
  Initialized       True
  Ready             True
  ContainersReady   True
  PodScheduled      True
Volumes:
  confidential-containers-artifacts:
    Type:          HostPath (bare host directory volume)
    Path:          /opt/confidential-containers/
    HostPathType:  DirectoryOrCreate
  etc-systemd-system:
    Type:          HostPath (bare host directory volume)
    Path:          /etc/systemd/system/
    HostPathType:
  containerd-conf:
    Type:          HostPath (bare host directory volume)
    Path:          /etc/containerd/
    HostPathType:
  local-bin:
    Type:          HostPath (bare host directory volume)
    Path:          /usr/local/bin/
    HostPathType:
  containerd-nydus:
    Type:          HostPath (bare host directory volume)
    Path:          /var/lib/containerd-nydus/
    HostPathType:
  kube-api-access-lszvl:
    Type:                    Projected (a volume that contains injected data from multiple sources)
    TokenExpirationSeconds:  3607
    ConfigMapName:           kube-root-ca.crt
    ConfigMapOptional:       <nil>
    DownwardAPI:             true
QoS Class:                   BestEffort
Node-Selectors:              node.kubernetes.io/worker=
Tolerations:                 node.kubernetes.io/disk-pressure:NoSchedule op=Exists
                             node.kubernetes.io/memory-pressure:NoSchedule op=Exists
                             node.kubernetes.io/not-ready:NoExecute op=Exists
                             node.kubernetes.io/pid-pressure:NoSchedule op=Exists
                             node.kubernetes.io/unreachable:NoExecute op=Exists
                             node.kubernetes.io/unschedulable:NoSchedule op=Exists
Events:
  Type    Reason     Age   From               Message
  ----    ------     ----  ----               -------
  Normal  Scheduled  12m   default-scheduler  Successfully assigned confidential-containers-system/cc-operator-pre-install-daemon-hpjsq to 984fee00befb.jf.intel.com
  Normal  Pulling    12m   kubelet            Pulling image "localhost:5000/reqs-payload"
  Normal  Pulled     12m   kubelet            Successfully pulled image "localhost:5000/reqs-payload" in 51.967048ms
  Normal  Created    12m   kubelet            Created container cc-runtime-pre-install-pod
  Normal  Started    12m   kubelet            Started container cc-runtime-pre-install-pod
::endgroup::
::info:: Shutdown the cluster
[reset] Reading configuration from the cluster...
[reset] FYI: You can look at this config file with 'kubectl -n kube-system get cm kubeadm-config -o yaml'
[preflight] Running pre-flight checks
[reset] Stopping the kubelet service
[reset] Unmounting mounted directories in "/var/lib/kubelet"
[reset] Deleting contents of directories: [/etc/kubernetes/manifests /etc/kubernetes/pki]
[reset] Deleting files: [/etc/kubernetes/admin.conf /etc/kubernetes/kubelet.conf /etc/kubernetes/bootstrap-kubelet.conf /etc/kubernetes/controller-manager.conf /etc/kubernetes/scheduler.conf]
[reset] Deleting contents of stateful directories: [/var/lib/etcd /var/lib/kubelet /var/lib/dockershim /var/run/kubernetes /var/lib/cni]

The reset process does not clean CNI configuration. To do so, you must remove /etc/cni/net.d

The reset process does not reset or clean up iptables rules or IPVS tables.
If you wish to reset iptables, you must do so manually by using the "iptables" command.

If your cluster was setup to utilize IPVS, run ipvsadm --clear (or similar)
to reset your system's IPVS tables.

The reset process does not clean your kubeconfig files and you must remove them manually.
Please, check the contents of the $HOME/.kube/config file.
::info:: Undo the bootstrap

PLAY [all] ***********************************************************************************************

TASK [Gathering Facts] ***********************************************************************************
ok: [localhost]

TASK [Uninstall go] **************************************************************************************
changed: [localhost] => (item=/usr/local/bin/go)
changed: [localhost] => (item=/usr/local/go)

PLAY [all] ***********************************************************************************************

TASK [Gathering Facts] ***********************************************************************************
ok: [localhost]

TASK [Check containerd is installed] *********************************************************************
changed: [localhost]

TASK [Re-create containerd config] ***********************************************************************
changed: [localhost]

TASK [Restart containerd service] ************************************************************************
changed: [localhost]

PLAY [all] ***********************************************************************************************

TASK [Gathering Facts] ***********************************************************************************
ok: [localhost]

TASK [Uninstall flannel] *********************************************************************************
changed: [localhost]

TASK [Check kubelet is installed] ************************************************************************
changed: [localhost]

TASK [Stop kubelet service] ******************************************************************************
ok: [localhost]

TASK [Delete kubelet service files] **********************************************************************
changed: [localhost] => (item=/etc/systemd/system/kubelet.service)
changed: [localhost] => (item=/etc/systemd/system/kubelet.service.d)

TASK [Delete the kubeadm configuration directory] ********************************************************
changed: [localhost]

TASK [Remove kube binaries] ******************************************************************************
changed: [localhost] => (item=crictl)
changed: [localhost] => (item=kubeadm)
changed: [localhost] => (item=kubectl)
changed: [localhost] => (item=kubelet)

TASK [Uninstall cni] *************************************************************************************
changed: [localhost]

PLAY [all] ***********************************************************************************************

TASK [Gathering Facts] ***********************************************************************************
ok: [localhost]

TASK [Remove the docker registry] ************************************************************************
changed: [localhost]

PLAY [all] ***********************************************************************************************

TASK [Gathering Facts] ***********************************************************************************
ok: [localhost]

TASK [Uninstall go] **************************************************************************************
ok: [localhost] => (item=/usr/local/bin/go)
ok: [localhost] => (item=/usr/local/go)
changed: [localhost] => (item=/usr/local/bin/bats)
changed: [localhost] => (item=/usr/local/bin/kustomize)

PLAY RECAP ***********************************************************************************************
localhost                  : ok=18   changed=12   unreachable=0    failed=0    skipped=0    rescued=0    ignored=0

::info:: Testing passed

Got a green run, now I'm re-running the tests again to make sure we've covered the leftover issues as well.

Wow!
fatal: [localhost]: FAILED! => {"attempts": 3, "changed": true, "cmd": "curl -s --retry 3 --retry-delay 10 \"[https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh\](https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh/)"  | bash\ncp -f ./kustomize /usr/local/bin\n", "delta": "0:00:00.284000", "end": "2024-06-21 02:19:13.502888", "msg": "non-zero return code", "rc": 1, "start": "2024-06-21 02:19:13.218888", "stderr": "cp: cannot stat './kustomize': No such file or directory", "stderr_lines": ["cp: cannot stat './kustomize': No such file or directory"], "stdout": "Github rate-limiter failed the request. Either authenticate or wait a couple of minutes.", "stdout_lines": ["Github rate-limiter failed the request. Either authenticate or wait a couple of minutes."]}

This is something I was not actually expecting to hit.  Regardless, this should not be unique to the TDX machine and should not be a blocker for this one to get merged.

Interesting, maybe we'll have to consider something like this: https://docs.github.com/en/rest/authentication/authenticating-to-the-rest-api?apiVersion=2022-11-28#authenticating-in-a-github-actions-workflow-using-curl

Merging after double-checking with @stevenhorsman that he's okay with this approach, at least for now.


TFLite GPU Delegates: Reshape fails to reshape input matrix with batch >1

System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow): Yes
OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Ubuntu 16.04
Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device: n/a
TensorFlow installed from (source or binary): source
TensorFlow version (use command below): master
Python version: 3.6.5
Bazel version (if compiling from source): n/a
GCC/Compiler version (if compiling from source): n/a
CUDA/cuDNN version: n/a
GPU model and memory: n/a

Describe the current behavior
The following test case fails.
TEST(ReshapeTest, Smoke) {
  TensorRefFloat32 augend, addend, output;
  augend.type = DataType::FLOAT32;
  augend.ref = 0;
  augend.shape = BHWC(1, 2, 6, 1);

  output.type = DataType::FLOAT32;
  output.ref = 2;
  output.shape = BHWC(2, 3, 2, 1);

  ReshapeAttributes attr;
  attr.new_shape = BHWC(2, 3, 2, 1);

  SingleOpModel model({ToString(OperationType::RESHAPE), std::move(attr)},
                      {augend}, {output});
  ASSERT_TRUE(model.PopulateTensor(0, {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12}));
  ASSERT_TRUE(model.Invoke(*NewReshapeNodeShader()));
  EXPECT_THAT(model.GetOutput(0),
              Pointwise(FloatNear(1e-6), {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12}));
}

Value of: model.Invoke(*NewReshapeNodeShader())
  Actual: false
Expected: true

If the input batch is 2:
TEST(ReshapeTest, Smoke) {
  TensorRefFloat32 augend, addend, output;
  augend.type = DataType::FLOAT32;
  augend.ref = 0;
  augend.shape = BHWC(2, 3, 2, 1);

  output.type = DataType::FLOAT32;
  output.ref = 2;
  output.shape = BHWC(2, 2, 3, 1);

  ReshapeAttributes attr;
  attr.new_shape = BHWC(2, 2, 3, 1);

  SingleOpModel model({ToString(OperationType::RESHAPE), std::move(attr)},
                      {augend}, {output});
  ASSERT_TRUE(model.PopulateTensor(0, {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12}));
  // ASSERT_TRUE(model.PopulateTensor(1, {2, 2, 3}));
  ASSERT_TRUE(model.Invoke(*NewReshapeNodeShader()));
  EXPECT_THAT(model.GetOutput(0),
              Pointwise(FloatNear(1e-6), {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12}));
}

Value of: model.GetOutput(0)
Expected: contains 12 values, where each value and its corresponding value in { 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12 } are an almost-equal pair
  Actual: { 1, 2, 3, 4, 5, 6, 0, 0, 0, 0, 0, 0 }, where the value pair (0, 7) at index #6 don't match, which is 7 from 0

However, the test case passes if the batch dimensions are identical.
Describe the expected behavior
The output sequence should match the input, even when the batch dimensions are greater than 1. Why do batch dimensions need to be 1?
Other info
I'm not sure if my take is correct. gid.z should take the value 1 to read the second batch in the second case, but gid.z is always 0. Perhaps it's a bug in the command queue?

@mun3
TFLite GPU treats the batch dimension specially, and currently doesn't allow operations along that dimension.  If you say batch size is n, it needs to be true for all input / output tensors.  In other words, you cannot specify a tensor shape [2, 1, 1, 1] and make it [1, 1, 1, 2] and vice versa.
Given the TFLite GPU's background of running things as efficient and as fast as possible, it didn't consider batch sizes, or rather, was assuming everything would be running on batch size 1.  We have plans to extend and allow such reshapes in the future, but it's not prioritized at the moment.

@impjdi I've noticed these lines https://github.com/tensorflow/tensorflow/blob/master/tensorflow/lite/delegates/gpu/gl/api.cc#L390-L392
if (!IsBatchMatchesForAllValues(model)) {
    return InvalidArgumentError("Only identical batch dimension is supported");
}

which seem to suggest things should work as long as batch dimensions match. However, the following fails:
TEST(ReshapeTest, MultiChan2) {
  TensorRefFloat32 augend, addend, output;

  augend.type = DataType::FLOAT32;
  augend.ref = 0;
  augend.shape = BHWC(2, 1, 4, 5);

  int b = 2;
  int h = 1;
  int w = 4;
  int c = 5;

  output.type = DataType::FLOAT32;
  output.ref = 2;
  output.shape = BHWC(b, h, w, c);

  ReshapeAttributes attr;
  attr.new_shape = BHWC(b, h, w, c);

  SingleOpModel model({ToString(OperationType::RESHAPE), std::move(attr)},
                      {augend}, {output});

  ASSERT_TRUE(model.PopulateTensor(0, {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40}));
  ASSERT_TRUE(model.Invoke(*NewReshapeNodeShader()));
  EXPECT_THAT(model.GetOutput(0),
              Pointwise(FloatNear(1e-6), {1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40}));
}

Would it be a better idea to change the IsBatchMatchesForAllValues check to something like IsBatchOne to make things more consistent?
bool IsBatchOne(const GraphFloat32& model) {
  int32_t b = model.values()[0]->tensor.shape.b;
  if (b != 1) return false;
  for (auto value : model.values()) {
    if (value->tensor.shape.b != 1) {
      return false;
    }
  }
  return true;
}

@mun3
I think the right syntax there should be:

ReshapeAttributes attr;
attr.new_shape = BHWC(1, h, w, c);

because the reshape op is not applicable to the batch dimension.  We will check the syntax and improve the error message.

@mun3 Could you please let us know if this issue still persists ? If it is resolved then please feel free to move this issue to close status ? Thanks!


flavorDimensions in android is deprecated

It looks like flavorDimensions  got deprecated and should be replaced with list of the flavors
https://stackoverflow.com/questions/75100286/android-flavordimensions-is-deprecated
So this line
https://github.com/osociety/vernet/blob/52bf1564bd4cbc2e3bc82b1b559f7f886ecb1701/android/app/build.gradle#L65
Should be replaced with
flavorDimensions ["deploy"]

Fixed


Linked span in ochttp (server) should be of parent type

Describe the bug
when IsPublicEndpoint is set to true incoming traceContext is added as link to newly created root span on the server side. The link type is set CHILD . However, according to the spec it should be PARENT.

fixed by #1055


Weird issue with the UI element

I have CreditCardForm in my xml and it shows up in the view, but when I tap it nothing happens, no soft keyboard or anything.
<com.devmarvel.creditcardentry.library.CreditCardForm
            android:layout_marginLeft="@dimen/pad4"
            android:layout_marginRight="@dimen/pad4"
            android:layout_marginTop="@dimen/pad8"
            android:layout_marginBottom="@dimen/pad8"
            android:id="@+id/cc_input"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            app:include_exp="false"
            app:include_helper="false"
            app:include_security="false"
            app:include_zip="false"/>

Any idea what might be the issue?
p.s: it's inside a recyclerview.

Is focus being stolen by another click listener?

No, there are no other listeners. I did not try it out of the recyclerview but once I added a container around it, it started working. Thank you, great library.


[🐞] service worker not found with the release 0.18.1

Which component is affected?
Qwik Runtime
Describe the bug
Just following the basics step on a fresh start. It happens also on a more complex project that i just update with version 0.18.1
Reproduction
https://github.com/pleclech/qwik-0.18.1-service-worker-issue
Steps to reproduce
Run pnpm install follow by pnpm preview and then open the site in the browser you will see in the network tab:
TypeError: Failed to register a ServiceWorker for scope ('http://localhost:4173/') with script ('http://localhost:4173/service-worker.js'): A bad HTTP response code (404) was received when fetching the script. (anonymous) @ (index):3 Promise.catch (async) (anonymous) @ (index):3 (anonymous) @ (index):3
System Info
System:
    OS: Linux 5.15 Debian GNU/Linux 11 (bullseye) 11 (bullseye)
    CPU: (8) x64 Intel(R) Core(TM) i7-7700 CPU @ 3.60GHz
    Memory: 8.69 GB / 15.62 GB
    Container: Yes
    Shell: 5.8 - /usr/bin/zsh
  Binaries:
    Node: 16.13.0 - ~/.nvm/versions/node/v16.13.0/bin/node
    Yarn: 1.22.15 - ~/.yarn/bin/yarn
    npm: 8.18.0 - ~/.nvm/versions/node/v16.13.0/bin/npm
  npmPackages:
    @builder.io/qwik: 0.18.1 => 0.18.1
    @builder.io/qwik-city: 0.2.1 => 0.2.1
    undici: 5.18.0 => 5.18.0
    vite: 4.1.1 => 4.1.1

Additional Information
No response

Experiencing the same issue, only since updating from 0.17 to 0.18+

Yes, same thing happening on my end.

Yep, the same with me

Should be fixed in 0.19.0!

Yep no more error on 0.19.0, thanks.

I'm seeing this now with 1.2.14. 🤔

https://pneuma-25h.pages.dev/tokens/

https://pneuma-25h.pages.dev/service-worker.js is 404. Looks like it never got generated? Could we have a reproduction?

@mhevery Sorry, I figured that one out. I added Qwik City to the component library starter manually, and left out the src/routes/service-worker.ts file.


IndexError: list index out of range

Describe the bug
I have added some print statement to the source code. results[len(metrics) * i + j] is causing the error because results is empty.
The error is not triggered at the beginning of the process, but later, 61% (408/672).
Ragas version: up-to date with the github repo
Python version: 3.10.13
Code to Reproduce
embedding_model_id = "BAAI/bge-large-en-v1.5"
embeddings = HuggingFaceEmbeddings(model_name=embedding_model_id)

#eval_df ['question', 'question_id', 'reference_answer', 'reference_source', 'reference_source_id', 'answer', 'source', 'source_id']
def ragas_format(example):
    example["contexts"] = [example["reference_source"]]
    example["ground_truth"] = example["reference_answer"]
    return example

project_id = ""
config = {"project_id": project_id}
creds, _ = google.auth.default(quota_project_id=project_id)

chat = ChatVertexAI(credentials=creds)
ragas_vertexai_llm = LangchainLLMWrapper(chat)

eval_ds = datasets.Dataset.from_pandas(eval_df)

metrics = [
    ragas.metrics.faithfulness,
    ragas.metrics.context_relevancy,
    ragas.metrics.context_recall
]

for m in metrics:
    m.__setattr__("llm", ragas_vertexai_llm)

    if hasattr(m, "embeddings"):
        m.__setattr__("embeddings", embeddings)

results = ragas.evaluate(
    eval_ds.map(ragas_format),
    metrics=metrics,
    llm=ragas_vertexai_llm,
    embeddings=embeddings
)

Error trace
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Invalid JSON response. Expected dictionary with key 'Attributed'
Exception in thread Thread-10:
Traceback (most recent call last):
  File "/opt/conda/lib/python3.10/threading.py", line 1016, in _bootstrap_inner
    self.run()
  File "/home/jupyter/ragas/src/ragas/executor.py", line 66, in run
    results = self.loop.run_until_complete(self._aresults())
  File "/opt/conda/lib/python3.10/site-packages/nest_asyncio.py", line 99, in run_until_complete
    return f.result()
  File "/opt/conda/lib/python3.10/asyncio/futures.py", line 201, in result
    raise self._exception.with_traceback(self._exception_tb)
  File "/opt/conda/lib/python3.10/asyncio/tasks.py", line 232, in __step
    result = coro.send(None)
  File "/home/jupyter/ragas/src/ragas/executor.py", line 54, in _aresults
    raise e
  File "/home/jupyter/ragas/src/ragas/executor.py", line 49, in _aresults
    r = await future
  File "/opt/conda/lib/python3.10/asyncio/tasks.py", line 571, in _wait_for_one
    return f.result()  # May raise f.exception().
  File "/opt/conda/lib/python3.10/asyncio/futures.py", line 201, in result
    raise self._exception.with_traceback(self._exception_tb)
  File "/opt/conda/lib/python3.10/asyncio/tasks.py", line 232, in __step
    result = coro.send(None)
  File "/home/jupyter/ragas/src/ragas/executor.py", line 82, in wrapped_callable_async
    return counter, await callable(*args, **kwargs)
  File "/home/jupyter/ragas/src/ragas/metrics/base.py", line 91, in ascore
    raise e
  File "/home/jupyter/ragas/src/ragas/metrics/base.py", line 87, in ascore
    score = await self._ascore(row=row, callbacks=group_cm, is_async=is_async)
  File "/home/jupyter/ragas/src/ragas/metrics/_context_recall.py", line 119, in _ascore
    return self._compute_score(response)
  File "/home/jupyter/ragas/src/ragas/metrics/_context_recall.py", line 94, in _compute_score
    response = [
  File "/home/jupyter/ragas/src/ragas/metrics/_context_recall.py", line 96, in <listcomp>
    if item.get("Attributed")
AttributeError: 'str' object has no attribute 'get'

len results : 0
len dataset : 224
len(metrics) * i + j : 0

---------------------------------------------------------------------------
IndexError                                Traceback (most recent call last)
Cell In[18], line 3
      1 nest_asyncio.apply()
----> 3 results = ragas.evaluate(
      4     eval_ds.map(ragas_format),
      5     metrics=metrics,
      6     llm=ragas_vertexai_llm,
      7     embeddings=embeddings
      8 )

File ~/ragas/src/ragas/evaluation.py:222, in evaluate(dataset, metrics, llm, embeddings, callbacks, is_async, max_workers, run_config, raise_exceptions, column_map)
    219     if not evaluation_group_cm.ended:
    220         evaluation_rm.on_chain_error(e)
--> 222     raise e
    223 else:
    224     result = Result(
    225         scores=Dataset.from_list(scores),
    226         dataset=dataset,
    227         binary_columns=binary_metrics,
    228     )

File ~/ragas/src/ragas/evaluation.py:210, in evaluate(dataset, metrics, llm, embeddings, callbacks, is_async, max_workers, run_config, raise_exceptions, column_map)
    208 for j, m in enumerate(metrics):
    209     print(f"len(metrics) * i + j : {len(metrics) *i +j}")
--> 210     s[m.name] = results[len(metrics) * i + j]
    211 scores.append(s)
    212 # close the row chain

IndexError: list index out of range

thanks for putting the effort to write a really good issue. much appreciated @0ENZO 🙂
there are 2 issues here as far as I can see

Vertex AI is not working as it should be. the JSON format is not being followed. tagging @shahules786 for his expertise here
the misleading error message - that I will fix right now :)

thanks for bringing this up 0ENZO!

hey @0ENZO fixed the incorrect error messsage here #561. Let me know if that one makes more sense when trying to debug
will try to look into the vertex AI issue shortly

Hey @0ENZO , I'm on it. Most likely it is due to that vertex AI is unable to generate valid json output even with the retry mechanism.


Touch outside modal

Hi,
How do i disable/remove the closing of the modal,when i click outside the modal.
Even though i click out of the modal it shouldn't close.

@Thanmai-C
backdrop={true}  backdropPressToClose={true}

@herarya But when click to inside area modal, modal also closed.
How do touch only outside modal, modal is closed, not inside modal


kontrol prove throws segmentation fault for full/large cheatcode based setup for Optimism

Problem: kontrol prove on this branch of repo https://github.com/runtimeverification/_audits_Ethereum-optimism_pausability/tree/cheatcode-deploy throws segmentation fault. However, the kore-rpc-booster server is still running after the segmentation fault.
Steps to reproduce:
clone the above branch
cd packages/contracts-bedrock
./test/kontrol/deploy/run-kontrol.sh.
After about 20 minutes (varies on different machine) the following relevant log is generated:
+ kontrol prove --max-depth 100000000 --max-iterations 10000 --smt-timeout 10000000 --bmc-depth 10 --workers 1 --bug-report SetupBugReport --no-break-on-calls --auto-abstract-gas --match-test OptimismPortalTest.test_finalize --use-booster
Bug report exists, removing: SetupBugReport.tar
[Info#proxy] Loading definition from kout-deploy/kompiled/definition.kore, main module "FOUNDRY-MAIN"
[Info#kore] : Info (LogMessage):
    Reading the input file TimeSpec {sec = 0, nsec = 58384000} []
[Info#kore] : Info (LogMessage):
    Parsing the file TimeSpec {sec = 0, nsec = 0} []
[Info#kore] : Info (LogMessage):
    Verifying the definition TimeSpec {sec = 0, nsec = 0} []
[Info#kore] : Info (LogMessage):
    Executing TimeSpec {sec = 1, nsec = 117167000} []
[Info#kore] : Info (LogMessage):
    Reading the input file TimeSpec {sec = 0, nsec = 59050000} []
[Info#kore] : Info (LogMessage):
    Parsing the file TimeSpec {sec = 0, nsec = 0} []
[Info#kore] : Info (LogMessage):
    Verifying the definition TimeSpec {sec = 0, nsec = 0} []
[Info#proxy] Starting RPC server
[Info] Process request 1 simplify
[Info#booster] Simplifying all predicates
[Info] Process request 2 simplify
[Info#booster] Simplifying a pattern
./test/kontrol/deploy/run-kontrol.sh: line 20: 90052 Segmentation fault: 11  kontrol prove --max-depth ${max_depth} --max-iterations ${max_iterations} --smt-timeout ${smt_timeout} --bmc-depth ${bmc_depth} --workers ${workers} ${reinit} ${bug_report} ${break_on_calls} ${auto_abstract} ${tests} ${use_booster}

However, the kore-rpc-booster backend process did not crash and was still running/idling
It maybe relevant to this issue https://runtimeverification.slack.com/archives/CC360GUTG/p1701873937414179, but the error logs looks different.
The following bug report is attached.
SetupBugReport.tar.zip
@tothtamas28 @JuanCoRo @palinatolmach Please help to decide whether this is a kontrol bug or something else.

Which version of kontrol does this occur on?

I am using the latest version Kontrol version: 0.1.91 on Mac M1 and I used ulimit -s unlimited to relax the resource constraint and it still has the problem. The Segmentation Fault error code is 11 for Python on Mac. So it means kontrol crashed.

With above instructions, the stack trace is the following:
Bug report exists, removing: SetupBugReport.tar
[Info#proxy] Loading definition from kout-deploy/kompiled/definition.kore, main module "FOUNDRY-MAIN"
[Info#kore] : Info (LogMessage):
    Reading the input file TimeSpec {sec = 0, nsec = 58368000} []
[Info#kore] : Info (LogMessage):
    Parsing the file TimeSpec {sec = 0, nsec = 0} []
[Info#kore] : Info (LogMessage):
    Verifying the definition TimeSpec {sec = 0, nsec = 0} []
[Info#kore] : Info (LogMessage):
    Executing TimeSpec {sec = 1, nsec = 128727000} []
[Info#kore] : Info (LogMessage):
    Reading the input file TimeSpec {sec = 0, nsec = 59222000} []
[Info#kore] : Info (LogMessage):
    Parsing the file TimeSpec {sec = 0, nsec = 1000} []
[Info#kore] : Info (LogMessage):
    Verifying the definition TimeSpec {sec = 0, nsec = 0} []
[Info#proxy] Starting RPC server
[Info] Process request 1 simplify
[Info#booster] Simplifying all predicates
[Info] Process request 2 simplify
[Info#booster] Simplifying a pattern
Fatal Python error: Segmentation fault

Current thread 0x00000001d6be9ec0 (most recent call first):
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 35 in __init__
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 236 in __init__
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 253 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 1561 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 132 in from_dict
  File "/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py", line 453 in <genexpr>
  ...

Extension modules: psutil._psutil_osx, psutil._psutil_posix (total: 2)
./test/kontrol/deploy/run-kontrol.sh: line 22: 37571 Segmentation fault: 11  kontrol prove --max-depth ${max_depth} --max-iterations ${max_iterations} --smt-timeout ${smt_timeout} --bmc-depth ${bmc_depth} --workers ${workers} ${reinit} ${bug_report} ${break_on_calls} ${auto_abstract} ${tests} ${use_booster}

Can you include line 543 of the following file?
/nix/store/00vmhg1y58hk2qmyw3q0myhx4inlzh9p-python3.10-pyk-0.1.540/lib/python3.10/site-packages/pyk/kore/syntax.py

See the screenshot

Reproduction steps.
Extract SetupBugReport.tar.zip into <pyk-repo-root>/bug-report, then
poetry run python3 test.py

where test.py is the following script:
# test.py

import json
import faulthandler
import sys
from pathlib import Path

from pyk.kore.syntax import Pattern

sys.setrecursionlimit(10**8)
faulthandler.enable()

resp_file = Path('bug-report/rpc_OptimismPortalTest.setUp():0/002_response.json')

with resp_file.open() as f:
    resp_data = json.load(f)

kore_data = resp_data['result']['state']['term']
Pattern.from_dict(kore_data)

On my machine, sys.setrecursionlimit(20975) leads to RecursionError for json.loads, and a recursion limit higher than that causes a segfault for Pattern.from_dict.

Looks like the <jumpDests> cell in the response has more than 10k elements. It is represented as
_Set_(SetItem(item0), _Set_(SetItem(item1), ...))

resulting in  deeply nested structure.

Things we will try:

Use Cython: https://cython.org/
Try emitting K code for the jumpdests containment check instead of using set containment (potential problem with maknig lots of equation rules).
Try flattening the sets using assoc productions.
Remove the recursion on the Python side, using loops instead.

3 and 4 we should probably eventually work towards anyway.

Fix (item 4 from the list above): https://github.com/runtimeverification/pyk/pull/775
@spencerhaoxiao, can you re-run the proof with the fix to see if it clears the issue?

Fix (item 4 from the list above): runtimeverification/pyk#775
@spencerhaoxiao, can you re-run the proof with the fix to see if it clears the issue?

@tothtamas28, The problem is fixed with your PR, thanks.
B


Implement Loguru for better logging

So far we're adopting basic logging - 95% of the time that's ok, but for instance the logs are not catching errors, which is annoying for bugfixes.
Loguru might offer a solution, at a very small dependency cost - especially if not on Windows (otherwise two small dependencies more to deal with their terminal).
I think it'd be neat to implement it!

Should this be closed?


Seems like content type detection changed.


feat(sdk): add nexus into wandb/wandb

Description
What does the PR do?
We've made notable enhancements to our code base, introducing a range of new capabilities that hold promise for improved performance.  The new code could have a positive impact on our overall outcomes, representing a step forward for our product.

🤖 Generated by Copilot at b6a8f05
This pull request adds several files and directories to the nexus package, which is a Python client for the wandb API. The files and directories include a GitHub workflow for pre-commit checks, a .gitignore file for ignoring irrelevant files, some IntelliJ IDEA IDE files for configuring the project, some GraphQL files for defining queries and mutations, a go:generate directive for generating the GraphQL schema and client code, a genqlient.yaml file for configuring the genqlient tool, a Makefile for building, testing, and releasing the package, and a MANIFEST.in file for specifying the source distribution. The purpose of these changes is to improve the development, testing, and deployment process of the nexus package.
Testing
How was this PR tested?
Checklist

[ ] Include reference to internal ticket "Fixes WB-NNNN" and/or GitHub issue "Fixes #NNNN" (if applicable)
[ ] Ensure PR title compliance with the conventional commits standards

🕺🪩


RuntimeError while training and validating on different devices

The Bug
Training and validation tasks could not be executed on different devices.
The current device assigning policy does not allow specifying devices per task, but if the device is overridden inside a task code (e.g. for CPU inference), an error is raised (see below).
Steps To Reproduce

Open any tutorial folder in openfl-tutorials/interactive_api. I found the bug in PyTorch_Kvasir_UNet.
Create and activate director Python environment.
Execute:pip install /path/to/openfl
cd director
bash start_director.sh

In a separate terminal create and activate envoy Python environment.
Execute:pip install /path/to/openfl
cd envoy
pip install sd_requirements.txt
bash start_envoy.sh

In a separate terminal create and activate workspace Python environment.
Execute:pip install /path/to/openfl
pip install torchvision==0.8.1 # for Kvasir workspace
jupyter notebook

Open the Jupyter UI and go to the main experiment notebook in the workspace folder.
In tasks definition, add a device overriding line so devices for different tasks differ. Since for Kvasir example CUDA_PREFERRED policy is set, all tasks get cuda:* devices in parameters. So we need to change it to cpu:@TI.register_fl_task(model='unet_model', data_loader='val_loader', device='device')
def validate(unet_model, val_loader, device):
    device='cpu'  #  HERE WE OVERRIDE THE DEVICE
    print(f'\n\n TASK VALIDATE GOT DEVICE {device}\n\n')

    unet_model.eval()
    unet_model.to(device)

    val_loader = tqdm.tqdm(val_loader, desc="validate")

    val_score = 0
    total_samples = 0

    with torch.no_grad():
        for data, target in val_loader:
            samples = target.shape[0]
            total_samples += samples
            data, target = torch.tensor(data).to(device), \
                torch.tensor(target).to(device, dtype=torch.int64)
            output = unet_model(data)
            val = soft_dice_coef(output, target)
            val_score += val.sum().cpu().numpy()

    return {'dice_coef': val_score / total_samples,}

Run all cells.
During fl_experiment.stream_metrics() an error occurs:[15:53:29] ERROR    Collaborator failed with error: Expected all tensors to be on the same device, but found at least two devices, cuda:0 and cpu!:  envoy.py:75
                Traceback (most recent call last):
                  File "/home/itrushkin/.virtualenvs/envoy/lib/python3.8/site-packages/openfl/component/envoy/envoy.py", line 73, in run
                    self._run_collaborator()
                  File "/home/itrushkin/.virtualenvs/envoy/lib/python3.8/site-packages/openfl/component/envoy/envoy.py", line 141, in
                _run_collaborator
                    col.run()
                  File "/home/itrushkin/.virtualenvs/envoy/lib/python3.8/site-packages/openfl/component/collaborator/collaborator.py", line 145,
                in run
                    self.do_task(task, round_number)
                  File "/home/itrushkin/.virtualenvs/envoy/lib/python3.8/site-packages/openfl/component/collaborator/collaborator.py", line 241,
                in do_task
                    global_output_tensor_dict, local_output_tensor_dict = func(
                  File "/home/itrushkin/.virtualenvs/envoy/lib/python3.8/site-packages/openfl/federated/task/task_runner.py", line 129, in
                collaborator_adapted_task
                    metric_dict = callable_task(**task_kwargs)
                  File
                "/home/itrushkin/.virtualenvs/openfl_research/lib/python3.8/site-packages/openfl/interface/interactive_api/experiment.py", line
                436, in wrapper_decorator
                    metric_dict = training_method(**task_keywords)
                  File "<ipython-input-13-b3468c8701fc>", line 50, in train
                  File "/home/itrushkin/.virtualenvs/envoy/lib/python3.8/site-packages/torch/autograd/grad_mode.py", line 26, in
                decorate_context
                    return func(*args, **kwargs)
                  File "/home/itrushkin/.virtualenvs/envoy/lib/python3.8/site-packages/torch/optim/adam.py", line 108, in step
                    F.adam(params_with_grad,
                  File "/home/itrushkin/.virtualenvs/envoy/lib/python3.8/site-packages/torch/optim/functional.py", line 86, in adam
                    exp_avg.mul_(beta1).add_(grad, alpha=1 - beta1)
                RuntimeError: Expected all tensors to be on the same device, but found at least two devices, cuda:0 and cpu!

Expected behavior
Training is completed without errors.
Desktop
OS: Ubuntu 18.04
Python: 3.8
CUDA: 11.2
PyTorch: 1.7.0

Reproduced this behavior on MXNet. We should add model.collect_params().reset_ctx(ctx=[device]) to the tutorial when we change devices to reset the context.
Could not reproduce this behavior for Tensorflow example. The user can switch devices for different tasks without an issue in Tensorflow.

cc @alexey-khorkin @ViktoriiaRomanova

Did you try to move the optimizer to CPU?

You should use the assigned device in your task