-
Notifications
You must be signed in to change notification settings - Fork 7k
[core] fix authentication token related tests in windows #58444
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Signed-off-by: sampan <sampan@anyscale.com>
…auth tests This commit modifies the handling of the `RAY_AUTH_TOKEN` and `RAY_AUTH_TOKEN_PATH` environment variables in the gRPC authentication token tests to ensure compatibility with Windows. It uses `_putenv_s` for setting environment variables on Windows and maintains the existing behavior for other platforms. Signed-off-by: sampan <sampan@anyscale.com>
Signed-off-by: sampan <sampan@anyscale.com>
Signed-off-by: sampan <sampan@anyscale.com>
|
sorry, probably should have let core team reviewed and approved first. let me know if this needs more changes or even a revert. |
| void set_env_var(const char *name, const char *value) { ray::SetEnv(name, value); } | ||
|
|
||
| void unset_env_var(const char *name) { | ||
| #ifdef _WIN32 | ||
| _putenv_s(name, "") | ||
| #else | ||
| unsetenv(name); | ||
| #endif | ||
| } | ||
| void unset_env_var(const char *name) { ray::UnsetEnv(name); } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should remove these util wrappers
np, lgtm |
…#58444) fix a typo (missing semicolon) in authentication_token_loader_test and use cross env compatible `ray::UnsetEnv()` and `ray::setEnv()` in tests --------- Signed-off-by: sampan <sampan@anyscale.com> Co-authored-by: sampan <sampan@anyscale.com>
…#58444) fix a typo (missing semicolon) in authentication_token_loader_test and use cross env compatible `ray::UnsetEnv()` and `ray::setEnv()` in tests --------- Signed-off-by: sampan <sampan@anyscale.com> Co-authored-by: sampan <sampan@anyscale.com>
…#58444) fix a typo (missing semicolon) in authentication_token_loader_test and use cross env compatible `ray::UnsetEnv()` and `ray::setEnv()` in tests --------- Signed-off-by: sampan <sampan@anyscale.com> Co-authored-by: sampan <sampan@anyscale.com> Signed-off-by: Aydin Abiar <aydin@anyscale.com>
…#58444) fix a typo (missing semicolon) in authentication_token_loader_test and use cross env compatible `ray::UnsetEnv()` and `ray::setEnv()` in tests --------- Signed-off-by: sampan <sampan@anyscale.com> Co-authored-by: sampan <sampan@anyscale.com> Signed-off-by: YK <1811651+ykdojo@users.noreply.github.com>
…#58444) fix a typo (missing semicolon) in authentication_token_loader_test and use cross env compatible `ray::UnsetEnv()` and `ray::setEnv()` in tests --------- Signed-off-by: sampan <sampan@anyscale.com> Co-authored-by: sampan <sampan@anyscale.com>
…#58444) fix a typo (missing semicolon) in authentication_token_loader_test and use cross env compatible `ray::UnsetEnv()` and `ray::setEnv()` in tests --------- Signed-off-by: sampan <sampan@anyscale.com> Co-authored-by: sampan <sampan@anyscale.com> Signed-off-by: Future-Outlier <eric901201@gmail.com>
fix a typo (missing semicolon) in authentication_token_loader_test and use cross env compatible
ray::UnsetEnv()andray::setEnv()in tests