Skip to content

Drop old python versiosn, upgrade requirements, test for python 3.12. #69

Drop old python versiosn, upgrade requirements, test for python 3.12.

Drop old python versiosn, upgrade requirements, test for python 3.12. #69

GitHub Actions / JUnit Test Report failed Jul 25, 2024 in 0s

30 tests run, 0 skipped, 2 failed.

Annotations

Check failure on line 1 in .mypy_cache/3.11/chartreuse/tests/e2e_tests/test_blackbox.data.json

See this annotation in the file changed.

@github-actions github-actions / JUnit Test Report

test_blackbox.test_chartreuse_blackbox_post_upgrade

failed on setup with "subprocess.CalledProcessError: Command 'docker build . -f example/Dockerfile-dev --tag dummy-e2e-chartreuse-image:latest' returned non-zero exit status 1."
Raw output
@pytest.fixture(scope="module")
    def prepare_container_image_and_helm_chart() -> None:
        # We build a dummy docker image and deploy chartreuse subchart
>       run_command(
            "docker build . -f example/Dockerfile-dev --tag dummy-e2e-chartreuse-image:latest",
            cwd=ROOT_PATH,
        )

src/chartreuse/tests/e2e_tests/conftest.py:73: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

command = 'docker build . -f example/Dockerfile-dev --tag dummy-e2e-chartreuse-image:latest'
return_result = False
line_callback = <bound method Logger.info of <Logger wiremind_kubernetes.utils (DEBUG)>>
kw_args = {'cwd': '/home/runner/work/chartreuse/chartreuse/src/chartreuse/../..'}
interpreted_command = ['docker', 'build', '.', '-f', 'example/Dockerfile-dev', '--tag', ...]
process = <Popen: returncode: 1 args: ['docker', 'build', '.', '-f', 'example/Dockerfi...>
line = 'ERROR: failed to solve: process "/bin/sh -c pip install -e ." did not complete successfully: exit code: 1\n'

    def run_command(
        command: Union[List, str], return_result: bool = False, line_callback: Union[Callable, None] = None, **kw_args: Any
    ) -> Tuple[str, str, int]:
        """
        Run command, print stdout/stderr, check that command exited correctly, return stdout/err
        """
        logger.debug(f"Running {command}")
        if line_callback and return_result:
            raise ValueError("line_callback and return_result parameters are mutually incompatible.")
    
        if not line_callback:
            line_callback = logger.info
    
        interpreted_command: List[str]
        if isinstance(command, str):
            interpreted_command = shlex.split(command)
        else:
            interpreted_command = command
    
        process = subprocess.Popen(
            interpreted_command, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, universal_newlines=True, **kw_args
        )
    
        if return_result:
            out, err = process.communicate()
            return (out, err, process.returncode)
    
        if process.stdout:
            for line in iter(process.stdout.readline, ""):
                line_callback(line.strip())
        process.wait()
    
        if process.returncode:
>           raise subprocess.CalledProcessError(process.returncode, command)
E           subprocess.CalledProcessError: Command 'docker build . -f example/Dockerfile-dev --tag dummy-e2e-chartreuse-image:latest' returned non-zero exit status 1.

/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/wiremind_kubernetes/utils.py:48: CalledProcessError

Check failure on line 1 in .mypy_cache/3.11/chartreuse/tests/e2e_tests/test_blackbox.data.json

See this annotation in the file changed.

@github-actions github-actions / JUnit Test Report

test_blackbox.test_chartreuse_blackbox_pre_upgrade

failed on setup with "subprocess.CalledProcessError: Command 'docker build . -f example/Dockerfile-dev --tag dummy-e2e-chartreuse-image:latest' returned non-zero exit status 1."
Raw output
@pytest.fixture(scope="module")
    def prepare_container_image_and_helm_chart() -> None:
        # We build a dummy docker image and deploy chartreuse subchart
>       run_command(
            "docker build . -f example/Dockerfile-dev --tag dummy-e2e-chartreuse-image:latest",
            cwd=ROOT_PATH,
        )

src/chartreuse/tests/e2e_tests/conftest.py:73: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

command = 'docker build . -f example/Dockerfile-dev --tag dummy-e2e-chartreuse-image:latest'
return_result = False
line_callback = <bound method Logger.info of <Logger wiremind_kubernetes.utils (DEBUG)>>
kw_args = {'cwd': '/home/runner/work/chartreuse/chartreuse/src/chartreuse/../..'}
interpreted_command = ['docker', 'build', '.', '-f', 'example/Dockerfile-dev', '--tag', ...]
process = <Popen: returncode: 1 args: ['docker', 'build', '.', '-f', 'example/Dockerfi...>
line = 'ERROR: failed to solve: process "/bin/sh -c pip install -e ." did not complete successfully: exit code: 1\n'

    def run_command(
        command: Union[List, str], return_result: bool = False, line_callback: Union[Callable, None] = None, **kw_args: Any
    ) -> Tuple[str, str, int]:
        """
        Run command, print stdout/stderr, check that command exited correctly, return stdout/err
        """
        logger.debug(f"Running {command}")
        if line_callback and return_result:
            raise ValueError("line_callback and return_result parameters are mutually incompatible.")
    
        if not line_callback:
            line_callback = logger.info
    
        interpreted_command: List[str]
        if isinstance(command, str):
            interpreted_command = shlex.split(command)
        else:
            interpreted_command = command
    
        process = subprocess.Popen(
            interpreted_command, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, universal_newlines=True, **kw_args
        )
    
        if return_result:
            out, err = process.communicate()
            return (out, err, process.returncode)
    
        if process.stdout:
            for line in iter(process.stdout.readline, ""):
                line_callback(line.strip())
        process.wait()
    
        if process.returncode:
>           raise subprocess.CalledProcessError(process.returncode, command)
E           subprocess.CalledProcessError: Command 'docker build . -f example/Dockerfile-dev --tag dummy-e2e-chartreuse-image:latest' returned non-zero exit status 1.

/opt/hostedtoolcache/Python/3.11.9/x64/lib/python3.11/site-packages/wiremind_kubernetes/utils.py:48: CalledProcessError