Verified Commit 216ae0d3 authored by Adrian DC's avatar Adrian DC
Browse files

chore(bundle): refactor 'CI_LOCAL_EXTENDS_INCOMPLETE' flag variable

Issue: #295
---

Signed-off-by: default avatarAdrian DC <radian.dc@gmail.com>
parent 222e1040
Loading
Loading
Loading
Loading
+1 −1
Changes for src/package/bundle.py: 1 added line, 1 removed line.
Original line number Diff line number Diff line
@@ -44,7 +44,6 @@ class Bundle:
    ENV_DEBUG_VERSION_FAKE: str = 'DEBUG_VERSION_FAKE'
    ENV_DISPLAY_XAUTH_MAGIC_ADD: str = 'CI_LOCAL_DISPLAY_XAUTH_MAGIC_ADD'
    ENV_ENGINE_NAME: str = 'CI_LOCAL_ENGINE_NAME'
    ENV_EXTENDS_INCOMPLETE: str = 'CI_LOCAL_EXTENDS_INCOMPLETE'
    ENV_FORCE_COLOR: str = 'FORCE_COLOR'
    ENV_GIT_BINARY_PATH: str = 'GIT_BINARY_PATH'
    ENV_HISTORIES_DURATION_FAKE: str = 'CI_LOCAL_HISTORIES_DURATION_FAKE'
@@ -64,5 +63,6 @@ class Bundle:

    # Flags
    FLAG_ENGINE: str = 'CI_LOCAL_ENGINE'
    FLAG_EXTENDS_INCOMPLETE: str = 'CI_LOCAL_EXTENDS_INCOMPLETE'
    FLAG_NETWORK: str = 'CI_LOCAL_NETWORK'
    FLAG_PRIVILEGED: str = 'CI_LOCAL_PRIVILEGED'
+2 −2
Changes for src/parsers/gitlab.py: 2 added lines, 2 removed lines.
Original line number Diff line number Diff line
@@ -1054,8 +1054,8 @@ class GitLab:
        if 'extends' in job_data and job_data['extends']:

            # Allowed incomplete extended job
            if Bundle.ENV_EXTENDS_INCOMPLETE in job.variables and str(
                    job.variables[Bundle.ENV_EXTENDS_INCOMPLETE]).lower() in [
            if Bundle.FLAG_EXTENDS_INCOMPLETE in job.variables and str(
                    job.variables[Bundle.FLAG_EXTENDS_INCOMPLETE]).lower() in [
                        'true',
                        '1',
                    ]: