CircleCI-Public / path-filtering-orb

MIT License
24 stars 62 forks source link

feat(executor): allow setting executor tag #34

Closed joeybaer closed 2 years ago

joeybaer commented 2 years ago

Is there another way to set the executor version? We wanted to set it to python 3.8.2 but were not familiar with how without passing through the stack like this.

danalstadt commented 2 years ago

@joeybaer why are you looking to change the python version?

In my case, I came across this because our repo has a .python-version for 3.8.10 in the root, which causes the path-filtering/filter job to error out. It looks like this could solve my issue by allowing us to run path-filtering in the 3.8.10 container.

danalstadt commented 2 years ago

More broadly, I would say that it's a leaky abstraction if my .python-version file interferes with the functioning of this orb.

joeybaer commented 2 years ago

@joeybaer why are you looking to change the python version?

In my case, I came across this because our repo has a .python-version for 3.8.10 in the root, which causes the path-filtering/filter job to error out. It looks like this could solve my issue by allowing us to run path-filtering in the 3.8.10 container.

The same situation as you, I didn't see others experiencing this so was curious if just a user error. I have not pushed this orb to our org to verify it works but can look into doing that. I also agree with your comment that the checked-out code should not interfere with the runtime of the orb.

lazcamus commented 2 years ago

FWIW, I have a .python-version checked into my repo and am (now) running into this as well

lazcamus commented 2 years ago

I've published this change publicly at camusenergy/path-filtering@dev:pass-executor-tag (it's purported to live for 90 days?) and am using it successfully with tag: 3.10.2

tseruga commented 2 years ago

This is also interfering with my usage of the orb.

checked-out code should not interfere with the runtime of the orb.

mblayman commented 2 years ago

My company is running into this issue as well. Our CircleCI point of contact (👋 @felixshiftellecon) suggested that I comment on this too.

As others have noted, it would be preferable for this orb to function even when there is a .python-version in a code checkout, but I'd be happy enough with the ability to set a tag on this orb to pick the Python version in the interim.

BigJerBD commented 2 years ago

:+1: same problem here.

if changing the exector tags ia problem, anything that allows to not be in the folder where the .python-version is would also work for us

lazcamus commented 2 years ago

happy to see this merged, though it appears it's not usable as it's not part of a release?

@h42zhu could you provide guidance on when we should expect a release that includes this change? I've got a local hackaround that's going to expire which will continue to hang over my head until I bump to a public release.

lazcamus commented 2 years ago

I was using a dev orb to hack around this, and the expiry is hanging over my head, so I moved to an inline orb.

I'll document the recipe here, in case someone else would like to do the same:

% git clone https://github.com/CircleCI-Public/path-filtering-orb
% cd path-filtering-orb/src
% (echo 'orbs:'; echo '  path-filtering:'; circleci orb pack . | sed -e 's/^/    /g') > append-me.yaml

then merge append-me.yaml into your config.yaml in the appropriate place (I stuck it at the bottom). I had to add continuation: circleci/continuation@0.2.0 to the orbs: section of the inlined orb, since I guess it wasn't included in the pack.

It's working fine for me now, and will tide me over until there's a proper release.

h42zhu commented 2 years ago

@lazcamus Sorry for the late reply. The new orb version has just been released and in the orb registry. Please feel free to use the latest version.

jalessio commented 2 years ago

@lazcamus Sorry for the late reply. The new orb version has just been released and in the orb registry. Please feel free to use the latest version.

@h42zhu FYI - I'm not seeing the updated version in the Orb registry: https://circleci.com/developer/orbs/orb/circleci/path-filtering

CleanShot 2022-05-18 at 23 45 40@2x

h42zhu commented 2 years ago

@jalessio Sorry about that. I forgot to double check and missed a step in the orb promotion. It's there now: Link