Skip to content

Conversation

jiridanek
Copy link
Member

@jiridanek jiridanek commented Aug 28, 2025

https://issues.redhat.com/browse/RHAIENG-785

Description

find . -name Pipfile -delete
find . -name Pipfile.lock -delete
find . -name requirements.txt -delete

How Has This Been Tested?

Merge criteria:

  • The commits are squashed in a cohesive manner and have meaningful messages.
  • Testing instructions have been added in the PR body (for PRs involving changes that are not immediately obvious).
  • The developer has manually tested the changes and verified that the changes work

Summary by CodeRabbit

  • New Features
    • No user-facing features added.
  • Bug Fixes
    • None.
  • Chores
    • Removed numerous environment and dependency manifest files across runtimes and images, deleting pinned dependency lists and related metadata.
    • Repository now contains fewer pinned Python dependency manifests; this may affect reproducible environment setup or builds that relied on those files.
  • Refactor
    • None.

Copy link
Contributor

coderabbitai bot commented Aug 28, 2025

Walkthrough

Removed content from multiple Pipfile and requirements.txt manifests across runtimes, jupyter, rstudio, and codeserver directories; affected files are now empty or deleted, removing all previously declared package sources, package pins, and python_version constraints.

Changes

Cohort / File(s) Summary
Requirements files cleared
codeserver/ubi9-python-3.12/requirements.txt, rstudio/c9s-python-3.11/requirements.txt, rstudio/rhel9-python-3.11/requirements.txt
All lines removed; files now empty (removed headers, index-url, pinned packages and hashes).
Pipfiles removed — Jupyter variants
jupyter/.../ubi9-python-3.12/Pipfile (includes datascience, minimal, pytorch+llmcompressor, pytorch, rocm/pytorch, rocm/tensorflow, tensorflow, trustyai)
Entire Pipfile content deleted for each listed jupyter runtime path — removed sources, [dev-packages], [packages], and [requires] blocks.
Pipfiles removed — Runtimes
runtimes/.../ubi9-python-3.12/Pipfile (includes datascience, minimal, pytorch+llmcompressor, pytorch, rocm-pytorch, rocm-tensorflow, tensorflow)
Entire Pipfile content deleted for each listed runtime path — removed sources, package lists, and python_version constraints.
Pipfiles removed — RStudio / CodeServer
rstudio/c9s-python-3.11/Pipfile, rstudio/rhel9-python-3.11/Pipfile, codeserver/ubi9-python-3.12/Pipfile
Full Pipfile removals — deleted package declarations and [requires] python_version entries.

Estimated code review effort

🎯 4 (Complex) | ⏱️ ~40 minutes

Possibly related PRs

Suggested reviewers

  • atheo89

Tip

🔌 Remote MCP (Model Context Protocol) integration is now available!

Pro plan users can now connect to remote MCP servers from the Integrations page. Connect with popular remote MCPs such as Notion and Linear to add more context to your reviews and chats.


📜 Recent review details

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

💡 Knowledge Base configuration:

  • MCP integration is disabled by default for public repositories
  • Jira integration is disabled by default for public repositories
  • Linear integration is disabled by default for public repositories

You can enable these sources in your CodeRabbit configuration.

📥 Commits

Reviewing files that changed from the base of the PR and between 646aeb5 and dec6614.

⛔ Files ignored due to path filters (18)
  • codeserver/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • jupyter/datascience/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • jupyter/minimal/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • jupyter/pytorch+llmcompressor/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • jupyter/pytorch/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • jupyter/rocm/pytorch/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • jupyter/rocm/tensorflow/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • jupyter/tensorflow/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • jupyter/trustyai/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • rstudio/c9s-python-3.11/Pipfile.lock is excluded by !**/*.lock
  • rstudio/rhel9-python-3.11/Pipfile.lock is excluded by !**/*.lock
  • runtimes/datascience/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • runtimes/minimal/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • runtimes/pytorch+llmcompressor/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • runtimes/pytorch/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • runtimes/rocm-pytorch/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • runtimes/rocm-tensorflow/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
  • runtimes/tensorflow/ubi9-python-3.12/Pipfile.lock is excluded by !**/*.lock
📒 Files selected for processing (21)
  • codeserver/ubi9-python-3.12/Pipfile (0 hunks)
  • codeserver/ubi9-python-3.12/requirements.txt (0 hunks)
  • jupyter/datascience/ubi9-python-3.12/Pipfile (0 hunks)
  • jupyter/minimal/ubi9-python-3.12/Pipfile (0 hunks)
  • jupyter/pytorch+llmcompressor/ubi9-python-3.12/Pipfile (0 hunks)
  • jupyter/pytorch/ubi9-python-3.12/Pipfile (0 hunks)
  • jupyter/rocm/pytorch/ubi9-python-3.12/Pipfile (0 hunks)
  • jupyter/rocm/tensorflow/ubi9-python-3.12/Pipfile (0 hunks)
  • jupyter/tensorflow/ubi9-python-3.12/Pipfile (0 hunks)
  • jupyter/trustyai/ubi9-python-3.12/Pipfile (0 hunks)
  • rstudio/c9s-python-3.11/Pipfile (0 hunks)
  • rstudio/c9s-python-3.11/requirements.txt (0 hunks)
  • rstudio/rhel9-python-3.11/Pipfile (0 hunks)
  • rstudio/rhel9-python-3.11/requirements.txt (0 hunks)
  • runtimes/datascience/ubi9-python-3.12/Pipfile (0 hunks)
  • runtimes/minimal/ubi9-python-3.12/Pipfile (0 hunks)
  • runtimes/pytorch+llmcompressor/ubi9-python-3.12/Pipfile (0 hunks)
  • runtimes/pytorch/ubi9-python-3.12/Pipfile (0 hunks)
  • runtimes/rocm-pytorch/ubi9-python-3.12/Pipfile (0 hunks)
  • runtimes/rocm-tensorflow/ubi9-python-3.12/Pipfile (0 hunks)
  • runtimes/tensorflow/ubi9-python-3.12/Pipfile (0 hunks)
💤 Files with no reviewable changes (21)
  • jupyter/trustyai/ubi9-python-3.12/Pipfile
  • rstudio/c9s-python-3.11/requirements.txt
  • jupyter/minimal/ubi9-python-3.12/Pipfile
  • rstudio/rhel9-python-3.11/requirements.txt
  • runtimes/minimal/ubi9-python-3.12/Pipfile
  • runtimes/pytorch/ubi9-python-3.12/Pipfile
  • codeserver/ubi9-python-3.12/Pipfile
  • rstudio/rhel9-python-3.11/Pipfile
  • runtimes/pytorch+llmcompressor/ubi9-python-3.12/Pipfile
  • jupyter/rocm/pytorch/ubi9-python-3.12/Pipfile
  • codeserver/ubi9-python-3.12/requirements.txt
  • runtimes/datascience/ubi9-python-3.12/Pipfile
  • jupyter/pytorch/ubi9-python-3.12/Pipfile
  • jupyter/tensorflow/ubi9-python-3.12/Pipfile
  • jupyter/pytorch+llmcompressor/ubi9-python-3.12/Pipfile
  • runtimes/tensorflow/ubi9-python-3.12/Pipfile
  • runtimes/rocm-pytorch/ubi9-python-3.12/Pipfile
  • rstudio/c9s-python-3.11/Pipfile
  • jupyter/rocm/tensorflow/ubi9-python-3.12/Pipfile
  • runtimes/rocm-tensorflow/ubi9-python-3.12/Pipfile
  • jupyter/datascience/ubi9-python-3.12/Pipfile
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (35)
  • GitHub Check: build (rstudio-rhel9-python-3.11, 3.11, linux/amd64, true) / build
  • GitHub Check: Red Hat Konflux / odh-workbench-jupyter-pytorch-llmcompressor-cuda-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-jupyter-tensorflow-rocm-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-pipeline-runtime-tensorflow-cuda-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-pipeline-runtime-pytorch-cuda-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-pipeline-runtime-tensorflow-rocm-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-jupyter-pytorch-cuda-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-codeserver-datascience-cpu-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-pipeline-runtime-pytorch-llmcompressor-cuda-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-rstudio-minimal-cpu-py311-c9s-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-jupyter-tensorflow-cuda-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-pipeline-runtime-pytorch-rocm-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-jupyter-pytorch-rocm-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-pipeline-runtime-datascience-cpu-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-pipeline-runtime-minimal-cpu-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-jupyter-minimal-cuda-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-rstudio-minimal-cuda-py311-c9s-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-jupyter-minimal-rocm-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-jupyter-datascience-cpu-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-jupyter-minimal-cpu-py312-ubi9-on-pull-request
  • GitHub Check: Red Hat Konflux / odh-workbench-jupyter-trustyai-cpu-py312-ubi9-on-pull-request
  • GitHub Check: build (jupyter-trustyai-ubi9-python-3.12, 3.12, linux/amd64, false) / build
  • GitHub Check: build (rstudio-c9s-python-3.11, 3.11, linux/amd64, false) / build
  • GitHub Check: build (cuda-rstudio-c9s-python-3.11, 3.11, linux/amd64, false) / build
  • GitHub Check: build (runtime-minimal-ubi9-python-3.12, 3.12, linux/amd64, false) / build
  • GitHub Check: build (codeserver-ubi9-python-3.12, 3.12, linux/amd64, false) / build
  • GitHub Check: build (jupyter-minimal-ubi9-python-3.12, 3.12, linux/amd64, false) / build
  • GitHub Check: build (rocm-jupyter-tensorflow-ubi9-python-3.12, 3.12, linux/amd64, false) / build
  • GitHub Check: build (rocm-runtime-pytorch-ubi9-python-3.12, 3.12, linux/amd64, false) / build
  • GitHub Check: build (rocm-runtime-tensorflow-ubi9-python-3.12, 3.12, linux/amd64, false) / build
  • GitHub Check: build (runtime-cuda-pytorch-llmcompressor-ubi9-python-3.12, 3.12, linux/amd64, false) / build
  • GitHub Check: build (rocm-jupyter-minimal-ubi9-python-3.12, 3.12, linux/amd64, false) / build
  • GitHub Check: build (cuda-jupyter-pytorch-llmcompressor-ubi9-python-3.12, 3.12, linux/amd64, false) / build
  • GitHub Check: build (codeserver-ubi9-python-3.12, 3.12, linux/arm64, false) / build
  • GitHub Check: build (jupyter-minimal-ubi9-python-3.12, 3.12, linux/s390x, false) / build
✨ Finishing Touches
🧪 Generate unit tests
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbit in a new review comment at the desired location with your query.
  • PR comments: Tag @coderabbit in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbit gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbit read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.

Support

Need help? Create a ticket on our support page for assistance with any issues or questions.

CodeRabbit Commands (Invoked using PR/Issue comments)

Type @coderabbit help to get the list of available commands.

Other keywords and placeholders

  • Add @coderabbit ignore or @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbit summary or @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbit or @coderabbitai anywhere in the PR title to generate the title automatically.

Status, Documentation and Community

  • Visit our Status Page to check the current availability of CodeRabbit.
  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

@github-actions github-actions bot added the review-requested GitHub Bot creates notification on #pr-review-ai-ide-team slack channel label Aug 28, 2025
@openshift-ci openshift-ci bot requested review from atheo89 and dibryant August 28, 2025 20:42
Copy link
Contributor

openshift-ci bot commented Aug 28, 2025

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign jesuino for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added size/xxl and removed size/xxl labels Aug 28, 2025
Copy link
Contributor

openshift-ci bot commented Aug 28, 2025

@jiridanek: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/images 646aeb5 link true /test images
ci/prow/rocm-notebooks-py312-e2e-tests 646aeb5 link true /test rocm-notebooks-py312-e2e-tests
ci/prow/rstudio-notebook-e2e-tests 646aeb5 link true /test rstudio-notebook-e2e-tests
ci/prow/notebooks-py312-ubi9-e2e-tests 646aeb5 link true /test notebooks-py312-ubi9-e2e-tests

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here.

@jiridanek
Copy link
Member Author

Tried

  uv pip compile pyproject.toml --output-file requirements.txt --format requirements.txt --generate-hashes --emit-index-url --python-version="${PWD##*-}" --python-platform linux --no-annotate -q' \;

and then compared what changed using

#!/usr/bin/env python3
import pathlib
import subprocess
import re
from packaging.version import parse as parse_version

def get_staged_requirements_files():
    """Returns a list of staged files ending with requirements.txt."""
    try:
        # cmd = ["git", "diff", "--name-only", "--cached"]
        cmd = ["git", "diff", "--name-only"]
        result = subprocess.run(cmd, capture_output=True, text=True, check=True)
        return [
            line for line in result.stdout.strip().split("\n")
            if 'requirements.txt' in line and line.strip()
        ]
    except subprocess.CalledProcessError:
        return []

def get_file_content(revision_and_path):
    """Gets file content from a specific git revision (e.g., 'HEAD:path/file' or ':path/file')."""
    try:
        cmd = ["git", "show", revision_and_path]
        result = subprocess.run(cmd, capture_output=True, text=True, check=True)
        return result.stdout
    except subprocess.CalledProcessError:
        return ""  # File might be new, so it won't exist in HEAD

def parse_requirements(content: str) -> dict:
    """Parses requirements content into a dict of {package_name: version_string}."""
    packages = {}
    # This regex captures 'package-name==version' and ignores markers/hashes
    regex = re.compile(r"^\s*([a-zA-Z0-9_.-]+)==([^;\s]+)")
    for line in content.strip().split("\n"):
        match = regex.match(line)
        if match:
            package_name = match.group(1).lower()
            version_str = match.group(2)
            packages[package_name] = version_str
    return packages

def main():
    """Main function to find and compare staged requirements files."""
    staged_files = get_staged_requirements_files()
    if not staged_files:
        print("No staged requirements.txt files found.")
        return

    for filepath in staged_files:
        print(f"--- Comparing: {filepath} ---")

        # Fetch content for 'before' (from HEAD) and 'after' (from index/staging)
        before_content = get_file_content(f"HEAD:{filepath}")
        # after_content = get_file_content(f":{filepath}")
        after_content = pathlib.Path(filepath).read_text()

        before_packages = parse_requirements(before_content)
        after_packages = parse_requirements(after_content)

        # Get a set of all unique package names from both files
        all_package_names = sorted(set(before_packages.keys()) | set(after_packages.keys()))

        has_changes = False
        for name in all_package_names:
            before_ver = before_packages.get(name)
            after_ver = after_packages.get(name)

            if before_ver == after_ver:
                continue

            has_changes = True
            if before_ver and after_ver:
                if parse_version(before_ver) < parse_version(after_ver):
                    print(f"  [UPGRADED] {name}: {before_ver} -> {after_ver}")
                elif parse_version(before_ver) > parse_version(after_ver):
                    print(f"  [DOWNGRADED] {name}: {before_ver} -> {after_ver}")
                else:
                    # This case handles non-version changes, like in the hash or marker
                    print(f"  [MODIFIED] {name}: Line changed but version is the same.")
            elif after_ver:
                print(f"  [ADDED]    {name}: {after_ver}")
            elif before_ver:
                print(f"  [REMOVED]  {name}: {before_ver}")

        if not has_changes:
            print("  No version changes detected.")
        print()

if __name__ == "__main__":
    try:
        main()
    except ImportError:
        print("Error: The 'packaging' library is required.")
        print("Please install it: python3 -m pip install packaging")
    except FileNotFoundError:
        print("Error: The 'git' command was not found.")
        print("Please make sure you are in a git repository and git is in your PATH.")

@jiridanek jiridanek force-pushed the jd_rm_Pipfile_lockfiles branch from 646aeb5 to dec6614 Compare August 29, 2025 07:37
@openshift-ci openshift-ci bot added size/xxl and removed size/xxl labels Aug 29, 2025
@jiridanek jiridanek merged commit ed2d978 into opendatahub-io:main Aug 29, 2025
40 of 78 checks passed
@jiridanek jiridanek deleted the jd_rm_Pipfile_lockfiles branch August 29, 2025 08:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
review-requested GitHub Bot creates notification on #pr-review-ai-ide-team slack channel size/xxl
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant