avast / wanna-ml

Complete MLOps framework for Vertex-AI
MIT License
17 stars 3 forks source link

[Bug]: WANNA_GCP_DISABLE_REMOTE_VALIDATION has inverted logic #97

Closed racinmat closed 10 months ago

racinmat commented 11 months ago

Contact Details

No response

What happened?

https://github.com/avast/wanna-ml/blob/897aaad27a88b70e9bb5a6e77f4b14343671d579/src/wanna/core/utils/env.py#L41-L57 shows that the logic is the complete oposite of what the name suggests

(wanna-notebook-demo) PS C:\Projects\wanna-notebook-demo> $ENV:WANNA_GCP_DISABLE_REMOTE_VALIDATION="false"
(wanna-notebook-demo) PS C:\Projects\wanna-notebook-demo> wanna version                                   
ℹ WANNA GCP access allowed
ℹ WANNA cloud build access is enabled
ℹ WANNA remote validation is disabled
✅ Your wanna cli is up to date with 0.2.35
(wanna-notebook-demo) PS C:\Projects\wanna-notebook-demo> $ENV:WANNA_GCP_DISABLE_REMOTE_VALIDATION="true" 
(wanna-notebook-demo) PS C:\Projects\wanna-notebook-demo> wanna version                                  
ℹ WANNA GCP access allowed
ℹ WANNA cloud build access is enabled
ℹ WANNA remote validation is enabled
✅ Your wanna cli is up to date with 0.2.35

wanna.yaml file

none

wanna-ml CLI command

wanna version

Relevant log output

No response

racinmat commented 11 months ago

The tests in https://github.com/avast/wanna-ml/blob/v0.2.35/tests/utils/test_env.py#L30-L34 show also that the logic is inverse of the name of the variable.