Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(reana_dev): add no_update_submodules flag (#816) #816

Closed

Conversation

jlemesh
Copy link
Member

@jlemesh jlemesh commented Aug 5, 2024

Add --no-update-submodules flag to reana-dev commands cluster-build and cluster-deploy.

reana-commons adage lib version have been upgraded (needed for Ubuntu upgrade to 24.04, Python to 3.12), but other components still require older version. As reana-commons is a submodule, docker image builds fail for certain components (reana-server and reana-workflow-engine-yadage):

[2024-08-05T10:34:56] reana-server: docker build -t docker.io/reanahub/reana-server:latest .
[+] Building 7.6s (14/14) FINISHED                                                                                                               docker:desktop-linux
 => [internal] load build definition from Dockerfile                                                                                                             0.0s
 => => transferring dockerfile: 3.52kB                                                                                                                           0.0s
 => [internal] load metadata for docker.io/library/ubuntu:20.04                                                                                                  0.8s
 => [auth] library/ubuntu:pull token for registry-1.docker.io                                                                                                    0.0s
 => [internal] load .dockerignore                                                                                                                                0.0s
 => => transferring context: 370B                                                                                                                                0.0s
 => [1/9] FROM docker.io/library/ubuntu:20.04@sha256:0b897358ff6624825fb50d20ffb605ab0eaea77ced0adb8c6a4b756513dec6fc                                            0.0s
 => [internal] load build context                                                                                                                                0.1s
 => => transferring context: 216.40kB                                                                                                                            0.1s
 => CACHED [2/9] COPY requirements.txt /code/                                                                                                                    0.0s
 => CACHED [3/9] RUN apt-get update -y &&     apt-get install --no-install-recommends -y       gcc       git       libffi-dev       libpcre3       libpcre3-dev  0.0s
 => CACHED [4/9] WORKDIR /code                                                                                                                                   0.0s
 => CACHED [5/9] COPY . /code                                                                                                                                    0.0s
 => [6/9] RUN if [ "0" -gt 0 ]; then pip install --no-cache-dir -e ".[debug]"; else pip install --no-cache-dir .; fi;                                            2.3s
 => [7/9] RUN if test -e modules/reana-commons; then       if [ "0" -gt 0 ]; then         pip install --no-cache-dir -e "modules/reana-commons[kubernetes,yadag  3.9s
 => [8/9] RUN sed -i 's|^username_regex = re.compile\(.*\)$|username_regex = re.compile("^\\S+$")|g' /usr/local/lib/python3.8/dist-packages/invenio_userprofile  0.1s 
 => ERROR [9/9] RUN pip check                                                                                                                                    0.4s 
------                                                                                                                                                                
 > [9/9] RUN pip check:                                                                                                                                               
0.362 reana-server 0.95.0a1 has requirement adage==0.10.1, but you have adage 0.11.0.                                                                                 
------                                                                                                                                                                
Dockerfile:75
--------------------
  73 |     # Check for any broken Python dependencies
  74 |     # hadolint ignore=DL3059
  75 | >>> RUN pip check
  76 |     
  77 |     # Set useful environment variables
--------------------
ERROR: failed to solve: process "/bin/sh -c pip check" did not complete successfully: exit code: 1
[2024-08-05T10:34:56] reana-server: Command 'docker build -t docker.io/reanahub/reana-server:latest .' returned non-zero exit status 1.

Add a flag to skip submodule update if debug mode is used. Adding this flag (instead of e. g. --update-submodule and not doing submodule update by default in debug mode) to not interfere with current development flow.

@jlemesh jlemesh force-pushed the feat_no_update_submodules_flag branch from 4b0a3e5 to 9a09005 Compare August 5, 2024 08:51
Copy link

codecov bot commented Aug 5, 2024

Codecov Report

Attention: Patch coverage is 0% with 5 lines in your changes missing coverage. Please review.

Project coverage is 18.13%. Comparing base (9698c63) to head (9a09005).
Report is 18 commits behind head on master.

Files with missing lines Patch % Lines
reana/reana_dev/cluster.py 0.00% 5 Missing ⚠️
Additional details and impacted files

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #816      +/-   ##
==========================================
- Coverage   18.15%   18.13%   -0.03%     
==========================================
  Files          26       26              
  Lines        2478     2481       +3     
==========================================
  Hits          450      450              
- Misses       2028     2031       +3     
Files with missing lines Coverage Δ
reana/reana_dev/cluster.py 0.00% <0.00%> (ø)

@jlemesh jlemesh closed this Aug 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant