OpenFn / OpenFn/kit

Unit tests in circleCI take 3 minutes just to set up the container env

Open
#1,163 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

DevX
Dominant language
TypeScript
Stars
21
Forks
23
Avg merge
1d 22h
Merged PRs (30d)
17

Description

Something strange is going on in our circle CI

Check this workflow

  • All steps use the same docker image and resource
  • Build took just 7s to spin up environment
  • Unit test took 3m 22 to spin up environment

This seems to be repeated across a few runs

In the slow spinup, we get this warning about metadata

  Did not get image metadata for cimg/node:22.20: Get "http://%2Fvar%2Frun%2Fdocker.sock/v1.41/images/docker.io/cimg/node:22.20/json": context deadline exceeded
WARNING: docker image cimg/node:22.20 does not specify an architecture

The when pulling the image it says it takes 27s to create the container:

cimg/node:22.20:
  pull stats: download 19.02MiB in 3.724s (5.107MiB/s)
  time to create container: 27.02s

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the linked CircleCI workflow and compare the build and unit-test environment setup logs across the reported runs. Investigate the cimg/node:22.20 metadata warning and container creation timing; done means identifying and documenting the cause of the repeated slow startup and verifying that unit-test setup returns to the expected duration.

Written by the indexing model from the issue text.

Assessment

Tech stack
docker, node.js
Domain
ci-cd, devops
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.