-
Notifications
You must be signed in to change notification settings - Fork 1.5k
test: allow external_access_plan run on windows #13531
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
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.
I suspect it is not used when not all features are activated 🤔
Thanks @zhuliquan - it would also be really nice to figure out how you are running the code/tests to see this error. Maybe there is some better way we can come up with to fix it |
we should really avoid This is used in |
84915b6
to
53b7305
Compare
53b7305
to
32acd9d
Compare
Yeah, I fix code and enable it let new_file_name = if cfg!(target_os = "windows") {
// Windows path separator is different from Unix
file_name.replace("\\", "/")
} else {
file_name.clone()
}; |
🤔 the test now seems to be failing I wonder if it has to do with how the temp files are created 🤔 |
I suspect that the specific char '%7E' (i.e. '~') appears in the directory, and the Windows system seems to be unable to handle this.
So I fix below code to avoid the specific char which begin with '%'.
|
b161625
to
b65d2a3
Compare
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.
Thanks @zhuliquan -- i have one more question. I don't think it is necessary to fix but it would be nice to get a resolution
|
||
/// Return a parquet file with 2 row groups each with 5 rows | ||
fn get_test_data() -> &'static TestData { | ||
TEST_DATA.get_or_init(|| { |
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.
The reason to use the TEST_DATA
thing was to avoid creating the same file over and over again.
Do we need to remove TEST_DATA
?
It seems like the core difference is the use of tempfile_in
rather than the change from static
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.
If we aren't going to use TEST_DATA
anymore perhaps we can remove it (rather than name it starting with _
to avoid a compiler error) 🤔
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.
The reason to use the
TEST_DATA
thing was to avoid creating the same file over and over again.Do we need to remove
TEST_DATA
?It seems like the core difference is the use of
tempfile_in
rather than the change from static
There is no chance for delete TEST_DATA. Because there is no main test function to lead minor test cases.
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.
If we aren't going to use
TEST_DATA
anymore perhaps we can remove it (rather than name it starting with_
to avoid a compiler error) 🤔
@alamb Yeah, I share same point with you, I remove it now.
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.
Looks like an improvement to me -- thanks @zhuliquan
Which issue does this PR close?
Closes #13530.
Rationale for this change
I always receive this warning when running
cargo clippy
, and I would like to get rid of it.What changes are included in this PR?
Are these changes tested?
Are there any user-facing changes?