quipucords / camayoc

Test automation framework that facilitates functional testing of quipucords.
https://camayoc.readthedocs.io/
GNU General Public License v3.0
5 stars 4 forks source link

Refresh poetry.lock #434

Closed mirekdlugosz closed 1 year ago

mirekdlugosz commented 1 year ago

This is done mainly for Playwright (UI tests).

Since today, Jenkins agent downloads Playwright browsers during image build. This speeds up pipeline execution a little (as we don't have to download large files).

Playwright browser versions are tied to Playwright version. As I have used newer Playwright when building Jenkins agent image, now pipeline still wants to download browsers - because our pinned Playwright is older, and requires older browsers. After this PR, it won't be necessary.

If we update Playwright version in the future, it's best to also update Jenkins agent image.

codecov[bot] commented 1 year ago

Codecov Report

Merging #434 (69a34f9) into main (2bffdac) will not change coverage. Report is 1 commits behind head on main. The diff coverage is n/a.

@@           Coverage Diff           @@
##             main     #434   +/-   ##
=======================================
  Coverage   79.11%   79.11%           
=======================================
  Files           5        5           
  Lines         249      249           
=======================================
  Hits          197      197           
  Misses         52       52           

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more

bruno-fs commented 1 year ago

since we will only want to update playwright alongside jenkins, shouldn't we lock playwright on pyproject.toml as well to avoid future updates for other dependencies inadvertently also upgrading playwright?

mirekdlugosz commented 1 year ago

I'm on the fence. I see your point, but:

  1. We install using poetry install with poetry.lock committed, which means that poetry will use exact versions we have in lockfile, even if newer versions are available in PyPI. If we version Playwright in pyproject, that means we can't only run poetry lock, we have to also bump version in pyproject. Version in pyproject will also benefit any other package manager that understands pyproject format, but we don't care about these.
  2. There's nothing among our dependencies that could bump playwright without us knowing. Playwright is very much our direct dependency we fully control.
  3. Jenkins agent image builder process doesn't use pyproject. If we version Playwright, we need to keep version reference in sync in two separate places. (Right now we still need to keep versions in sync, we just hope that Playwright don't make a release between us updating a Camayoc lockfile and generating new jenkins image.)

All in all, I'm willing to take a risk and not version this explicitly. If this becomes a problem down the line, then we can fix it properly.

bruno-fs commented 1 year ago

Good points! Leaving my 👍🏽 , then