Skip to content

Conversation

anik120
Copy link
Contributor

@anik120 anik120 commented Aug 21, 2025

The script used realpath --relative-to which works on Linux (GNU coreutils) but fails on macOS (BSD realpath). This caused realpath: illegal option -- - errors when running on macOS.

This PR replaces GNU-specific realpath --relative-to with Python's os.path.relpath()

Note: This introduces Python3 requirements for both CI environments and dev machines.

Also fixed sed tool selection for script: Use gsed (GNU sed) for macOS, sed for linux.

Problem:

The script used `realpath --relative-to` which works on Linux (GNU coreutils) but fails on macOS (BSD realpath). This caused `realpath: illegal option -- -` errors when running on macOS.

Solution:

Replaced GNU-specific realpath --relative-to with Python's os.path.relpath()

Note: This introduces Python3 requirements for both CI environments and local development machines

Also fixed SED tool selection for script: Use gsed for macOS, sed for linux.
@grokspawn
Copy link
Contributor

grokspawn commented Aug 21, 2025

Instead of doing this, can we enforce that the environment matches https://operator-framework.github.io/operator-controller/contribute/developer/#special-setup-for-macos?

IMHO, python3 is a bigger requirement than bash, gnu-tar, gsed, and coreutils.

We had this documented /somewhere/ for v0, but I've lost the reference. 😞
Found it: https://github.com/openshift/operator-framework-olm/blob/main/docs/downstream-ci.md#downstream-sync

@perdasilva
Copy link
Contributor

/retest

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Aug 25, 2025
Copy link
Contributor

openshift-ci bot commented Aug 25, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: anik120, perdasilva

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

The pull request process is described 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 the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Aug 25, 2025
@tmshort
Copy link
Contributor

tmshort commented Aug 26, 2025

/retest

1 similar comment
@dtfranz
Copy link
Contributor

dtfranz commented Aug 27, 2025

/retest

Copy link
Contributor

openshift-ci bot commented Aug 27, 2025

@anik120: The following test 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/e2e-gcp-olm 9820863 link true /test e2e-gcp-olm

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.

@grokspawn
Copy link
Contributor

I still favor adopting the same dev tooling restrictions here as in olmv1 (gsed, bash) and ditching the disproportionately heavy python3 dependency.
/hold
for resolution, since I'm not seeing a dialogue here and I think I need to force one.

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Aug 27, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants