From bee8bed43e6c766ecd856c6e10e17ad7718fc4d4 Mon Sep 17 00:00:00 2001 From: "K. Shankari" Date: Sat, 21 Dec 2024 12:45:24 -0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=91=B7=20Upload=20exact=20versions=20of?= =?UTF-8?q?=20the=20packages=20used?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit We use `^` versions for our dependencies, which means that any compatible minor version could be pulled. However, we recently ran into an issue (https://github.com/e-mission/e-mission-phone/pull/1193#issuecomment-2558223871) in which a change to a minor version broke our tests. Sifting through all our dependencies to find the ones that were bumped, and which dependencies they bumped in turn is time consuming. For example in the issue above, the dependency that caused the break was `react-native`, which we don't include directly in our project. One option to identify changes would be to check the `package-lock.json`, but unless we are constantly reinstalling npm, we won't necessarily know what changed around the time that the tests broke. Uploading the `package-lock.json` from runs allows us to see the versions from before and after the break and narrow down the potential changes. --- .github/workflows/code-coverage.yml | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/.github/workflows/code-coverage.yml b/.github/workflows/code-coverage.yml index a97fb3925..a6100b0bf 100644 --- a/.github/workflows/code-coverage.yml +++ b/.github/workflows/code-coverage.yml @@ -26,6 +26,14 @@ jobs: source setup/activate_serve.sh npm run test + - name: Upload exact version(s) of packages used + uses: actions/upload-artifact@v4 + with: + name: versions-results + path: | + package-lock.json + ./coverage/coverage-final.json + - name: Upload coverage reports to Codecov uses: codecov/codecov-action@v4 with: