You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@datafusion.apache.org by "killzoner (via GitHub)" <gi...@apache.org> on 2025/10/13 12:55:56 UTC
[PR] add msrvcheck [datafusion-ballista]
killzoner opened a new pull request, #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328
# Which issue does this PR close?
<!--
We generally require a GitHub issue to be filed for all bug fixes and enhancements and this helps us generate change logs for our releases. You can link an issue to this PR using the GitHub syntax. For example `Closes #123` indicates that this PR will close issue #123.
-->
It's an automated way to track msrv with upstream `datafusion`.
Currently cargo checks for msrv when adding a new dependency on latest resolver (https://rust-lang.github.io/rfcs/3537-msrv-resolver.html), not for existing ones.
# Rationale for this change
<!--
Why are you proposing this change? If this is already explained clearly in the issue then this section is not needed.
Explaining clearly why changes are proposed helps reviewers understand your changes and offer better suggestions for fixes.
-->
This is one of the items from https://github.com/apache/datafusion-ballista/issues/1271
# What changes are included in this PR?
<!--
There is no need to duplicate the description in the issue here but it is sometimes worth providing a summary of the individual changes in this PR.
-->
Add a CI check to make sure MSRV is aligned with upstream `datafusion` projects.
# Are there any user-facing changes?
<!--
If there are user-facing changes then we may require documentation to be updated before approving the PR.
-->
No
<!--
If there are any breaking changes to public APIs, please add the `api change` label.
-->
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on code in PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#discussion_r2429908673
##########
.github/workflows/dependencies.yml:
##########
@@ -0,0 +1,58 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Dependencies
+
+concurrency:
+ group: ${{ github.repository }}-${{ github.head_ref || github.sha }}-${{ github.workflow }}
+ cancel-in-progress: true
+
+on:
+ push:
+ branches-ignore:
+ - 'gh-readonly-queue/**'
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ pull_request:
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ merge_group:
+ # manual trigger
+ # https://docs.github.com/en/actions/managing-workflow-runs/manually-running-a-workflow
+ workflow_dispatch:
+
+jobs:
+ depcheck:
+ name: msrv dependency check
+ runs-on: ubuntu-latest
+ container:
+ image: amd64/rust
+ steps:
+ - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
Review Comment:
I'm gonna make sure to rebase / fix the thing once the other PR is merged or I can do it now.
Either ways, i'm expecting some kind of git conflict, and I'm keeping this comment as unresolved to make sure it's addressed if no conflict
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on code in PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#discussion_r2429519113
##########
dev/msrvcheck/src/main.rs:
##########
@@ -0,0 +1,69 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+use cargo::CargoResult;
+use std::env;
+use std::path::Path;
+
+use cargo::util::context::GlobalContext;
+
+/// Verifies that we are tracking the right MSRV from datafusion.
+/// This is vastly inspired from <https://github.com/apache/datafusion/tree/10a437b826568c27b81d7d16a02b938a13d1a4ad/dev/depcheck>
+fn main() -> CargoResult<()> {
+ let gctx = GlobalContext::default()?;
+ // This is the path for the depcheck binary
+ let path = env::var("CARGO_MANIFEST_DIR").unwrap();
+ let root_cargo_toml = Path::new(&path)
+ // dev directory
+ .parent()
+ .expect("Can not find dev directory")
+ // project root directory
+ .parent()
+ .expect("Can not find project root directory")
+ .join("Cargo.toml");
+
+ println!(
+ "Checking for MSRV dependencies in {}",
+ root_cargo_toml.display()
+ );
+
+ let workspace = cargo::core::Workspace::new(&root_cargo_toml, &gctx)?;
+ let project_msrv = workspace.lowest_rust_version().unwrap(); // there should be a MSRV project wise
+
+ let (_, resolve) = cargo::ops::resolve_ws(&workspace, false)?;
+ let packages_with_rust_version: Vec<_> = resolve
+ .iter()
+ .filter(|id| id.name().starts_with("datafusion"))
+ .map(|e| resolve.summary(e))
+ .map(|e| (e.name(), e.rust_version()))
+ .collect();
+
+ println!("Current project MSRV: {}", project_msrv);
+
Review Comment:
done
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "milenkovicm (via GitHub)" <gi...@apache.org>.
milenkovicm commented on PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#issuecomment-3403676372
> Example of failing check with MSRV downgraded:
>
> https://github.com/killzoner/datafusion-ballista/commit/6d7022f9f196f605b0eb4e91c947ef903263ee40
>
> https://github.com/killzoner/datafusion-ballista/actions/runs/18509960270/job/52748285312#step:5:636
>
>
>
> ```bash
>
> Current project MSRV: 1.85.0
>
> thread 'main' panicked at src/main.rs:60:17:
>
> package 'datafusion' has MSRV 1.86.0 not compatible with current project MSRV 1.85.0
>
> ```
I see, should it be other way around I wonder. We need to support MSRV which datafusion supports or older
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "milenkovicm (via GitHub)" <gi...@apache.org>.
milenkovicm commented on code in PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#discussion_r2428406620
##########
dev/msrvcheck/src/main.rs:
##########
@@ -0,0 +1,69 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+use cargo::CargoResult;
+use std::env;
+use std::path::Path;
+
+use cargo::util::context::GlobalContext;
+
+/// Verifies that we are tracking the right MSRV from datafusion.
+/// This is vastly inspired from <https://github.com/apache/datafusion/tree/10a437b826568c27b81d7d16a02b938a13d1a4ad/dev/depcheck>
+fn main() -> CargoResult<()> {
+ let gctx = GlobalContext::default()?;
+ // This is the path for the depcheck binary
+ let path = env::var("CARGO_MANIFEST_DIR").unwrap();
+ let root_cargo_toml = Path::new(&path)
+ // dev directory
+ .parent()
+ .expect("Can not find dev directory")
+ // project root directory
+ .parent()
+ .expect("Can not find project root directory")
+ .join("Cargo.toml");
+
+ println!(
+ "Checking for MSRV dependencies in {}",
+ root_cargo_toml.display()
+ );
+
+ let workspace = cargo::core::Workspace::new(&root_cargo_toml, &gctx)?;
+ let project_msrv = workspace.lowest_rust_version().unwrap(); // there should be a MSRV project wise
+
+ let (_, resolve) = cargo::ops::resolve_ws(&workspace, false)?;
+ let packages_with_rust_version: Vec<_> = resolve
+ .iter()
+ .filter(|id| id.name().starts_with("datafusion"))
+ .map(|e| resolve.summary(e))
+ .map(|e| (e.name(), e.rust_version()))
+ .collect();
+
+ println!("Current project MSRV: {}", project_msrv);
+
Review Comment:
can we add print statement to print datafusion MSRV as well? it would help with tracking datafsuion version on update
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on code in PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#discussion_r2429908673
##########
.github/workflows/dependencies.yml:
##########
@@ -0,0 +1,58 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Dependencies
+
+concurrency:
+ group: ${{ github.repository }}-${{ github.head_ref || github.sha }}-${{ github.workflow }}
+ cancel-in-progress: true
+
+on:
+ push:
+ branches-ignore:
+ - 'gh-readonly-queue/**'
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ pull_request:
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ merge_group:
+ # manual trigger
+ # https://docs.github.com/en/actions/managing-workflow-runs/manually-running-a-workflow
+ workflow_dispatch:
+
+jobs:
+ depcheck:
+ name: msrv dependency check
+ runs-on: ubuntu-latest
+ container:
+ image: amd64/rust
+ steps:
+ - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
Review Comment:
I'm gonna make sure to rebase / fix the thing once the other PR is merged.
Either ways, i'm expecting some kind of git conflict, and I'm keeping this comment as unresolved to make sure it's addressed if no conflict
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "milenkovicm (via GitHub)" <gi...@apache.org>.
milenkovicm commented on PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#issuecomment-3409959674
all right, if I understand correctly, if datafusion is 1.85 we could decide to have ballista at 1.86 but not 1.84, as datafusion might not work in 1.84?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "milenkovicm (via GitHub)" <gi...@apache.org>.
milenkovicm commented on PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#issuecomment-3412512922
thanks @killzoner
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "milenkovicm (via GitHub)" <gi...@apache.org>.
milenkovicm merged PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "milenkovicm (via GitHub)" <gi...@apache.org>.
milenkovicm commented on code in PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#discussion_r2429703736
##########
.github/workflows/dependencies.yml:
##########
@@ -0,0 +1,58 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Dependencies
+
+concurrency:
+ group: ${{ github.repository }}-${{ github.head_ref || github.sha }}-${{ github.workflow }}
+ cancel-in-progress: true
+
+on:
+ push:
+ branches-ignore:
+ - 'gh-readonly-queue/**'
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ pull_request:
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ merge_group:
+ # manual trigger
+ # https://docs.github.com/en/actions/managing-workflow-runs/manually-running-a-workflow
+ workflow_dispatch:
+
+jobs:
+ depcheck:
+ name: msrv dependency check
+ runs-on: ubuntu-latest
+ container:
+ image: amd64/rust
+ steps:
+ - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
Review Comment:
are you sure this will be covered in that other PR? this is new job definition
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#issuecomment-3403589775
Example of failing check with MSRV downgraded:
https://github.com/killzoner/datafusion-ballista/commit/1955270a4200ee20ca88218cde7d97706c60f021
https://github.com/killzoner/datafusion-ballista/actions/runs/18509752501/job/52747547809#step:5:637
```bash
Current project MSRV: 1.85.0
thread 'main' panicked at src/main.rs:60:17:
package datafusion has 1.86.0 MSRV not compatible with current project MSRV 1.85.0
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#issuecomment-3411036980
> all right, if I understand correctly, if datafusion is 1.85 we could decide to have ballista at 1.86 but not 1.84, as datafusion might not work in 1.84?
That's my understanding yes
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#issuecomment-3400743119
Right now we check only datafusion, as we need to make sure that there is a proper MSRV defined in the crate toml.
That's true for datafusion, but there is currently no way to check this if the dependency didn't provide any `rust-version` info.
This should fail the CI, I can do a commit to demonstrate it by bumping artificially `ballista` MSRV and see how it behaves.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on code in PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#discussion_r2430416843
##########
.github/workflows/dependencies.yml:
##########
@@ -0,0 +1,58 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Dependencies
+
+concurrency:
+ group: ${{ github.repository }}-${{ github.head_ref || github.sha }}-${{ github.workflow }}
+ cancel-in-progress: true
+
+on:
+ push:
+ branches-ignore:
+ - 'gh-readonly-queue/**'
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ pull_request:
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ merge_group:
+ # manual trigger
+ # https://docs.github.com/en/actions/managing-workflow-runs/manually-running-a-workflow
+ workflow_dispatch:
+
+jobs:
+ depcheck:
+ name: msrv dependency check
+ runs-on: ubuntu-latest
+ container:
+ image: amd64/rust
+ steps:
+ - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
Review Comment:
Rebased and cleaned
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#issuecomment-3414058907
> thanks @killzoner
Thank you for the detailed reviews
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "milenkovicm (via GitHub)" <gi...@apache.org>.
milenkovicm commented on code in PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#discussion_r2428399045
##########
.github/workflows/dependencies.yml:
##########
@@ -0,0 +1,58 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Dependencies
+
+concurrency:
+ group: ${{ github.repository }}-${{ github.head_ref || github.sha }}-${{ github.workflow }}
+ cancel-in-progress: true
+
+on:
+ push:
+ branches-ignore:
+ - 'gh-readonly-queue/**'
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ pull_request:
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ merge_group:
+ # manual trigger
+ # https://docs.github.com/en/actions/managing-workflow-runs/manually-running-a-workflow
+ workflow_dispatch:
+
+jobs:
+ depcheck:
+ name: msrv dependency check
+ runs-on: ubuntu-latest
+ container:
+ image: amd64/rust
+ steps:
+ - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
Review Comment:
can you please replace hashes with versions here as well? thanks
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on code in PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#discussion_r2428403895
##########
.github/workflows/dependencies.yml:
##########
@@ -0,0 +1,58 @@
+# Licensed to the Apache Software Foundation (ASF) under one
+# or more contributor license agreements. See the NOTICE file
+# distributed with this work for additional information
+# regarding copyright ownership. The ASF licenses this file
+# to you under the Apache License, Version 2.0 (the
+# "License"); you may not use this file except in compliance
+# with the License. You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing,
+# software distributed under the License is distributed on an
+# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+# KIND, either express or implied. See the License for the
+# specific language governing permissions and limitations
+# under the License.
+
+name: Dependencies
+
+concurrency:
+ group: ${{ github.repository }}-${{ github.head_ref || github.sha }}-${{ github.workflow }}
+ cancel-in-progress: true
+
+on:
+ push:
+ branches-ignore:
+ - 'gh-readonly-queue/**'
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ pull_request:
+ paths:
+ - "**/Cargo.toml"
+ - "**/Cargo.lock"
+ merge_group:
+ # manual trigger
+ # https://docs.github.com/en/actions/managing-workflow-runs/manually-running-a-workflow
+ workflow_dispatch:
+
+jobs:
+ depcheck:
+ name: msrv dependency check
+ runs-on: ubuntu-latest
+ container:
+ image: amd64/rust
+ steps:
+ - uses: actions/checkout@08c6903cd8c0fde910a37f88322edcfb5dd907a8 # v5.0.0
Review Comment:
doing it in https://github.com/apache/datafusion-ballista/pull/1327 (sorry 2 concurrent PRs :smile: )
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on code in PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#discussion_r2428483535
##########
dev/msrvcheck/src/main.rs:
##########
@@ -0,0 +1,69 @@
+// Licensed to the Apache Software Foundation (ASF) under one
+// or more contributor license agreements. See the NOTICE file
+// distributed with this work for additional information
+// regarding copyright ownership. The ASF licenses this file
+// to you under the Apache License, Version 2.0 (the
+// "License"); you may not use this file except in compliance
+// with the License. You may obtain a copy of the License at
+//
+// http://www.apache.org/licenses/LICENSE-2.0
+//
+// Unless required by applicable law or agreed to in writing,
+// software distributed under the License is distributed on an
+// "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+// KIND, either express or implied. See the License for the
+// specific language governing permissions and limitations
+// under the License.
+
+use cargo::CargoResult;
+use std::env;
+use std::path::Path;
+
+use cargo::util::context::GlobalContext;
+
+/// Verifies that we are tracking the right MSRV from datafusion.
+/// This is vastly inspired from <https://github.com/apache/datafusion/tree/10a437b826568c27b81d7d16a02b938a13d1a4ad/dev/depcheck>
+fn main() -> CargoResult<()> {
+ let gctx = GlobalContext::default()?;
+ // This is the path for the depcheck binary
+ let path = env::var("CARGO_MANIFEST_DIR").unwrap();
+ let root_cargo_toml = Path::new(&path)
+ // dev directory
+ .parent()
+ .expect("Can not find dev directory")
+ // project root directory
+ .parent()
+ .expect("Can not find project root directory")
+ .join("Cargo.toml");
+
+ println!(
+ "Checking for MSRV dependencies in {}",
+ root_cargo_toml.display()
+ );
+
+ let workspace = cargo::core::Workspace::new(&root_cargo_toml, &gctx)?;
+ let project_msrv = workspace.lowest_rust_version().unwrap(); // there should be a MSRV project wise
+
+ let (_, resolve) = cargo::ops::resolve_ws(&workspace, false)?;
+ let packages_with_rust_version: Vec<_> = resolve
+ .iter()
+ .filter(|id| id.name().starts_with("datafusion"))
+ .map(|e| resolve.summary(e))
+ .map(|e| (e.name(), e.rust_version()))
+ .collect();
+
+ println!("Current project MSRV: {}", project_msrv);
+
Review Comment:
will do
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org
Re: [PR] add msrvcheck [datafusion-ballista]
Posted by "killzoner (via GitHub)" <gi...@apache.org>.
killzoner commented on PR #1328:
URL: https://github.com/apache/datafusion-ballista/pull/1328#issuecomment-3409805028
> > Example of failing check with MSRV downgraded:
> > [killzoner@6d7022f](https://github.com/killzoner/datafusion-ballista/commit/6d7022f9f196f605b0eb4e91c947ef903263ee40)
> > https://github.com/killzoner/datafusion-ballista/actions/runs/18509960270/job/52748285312#step:5:636
> > ```shell
> > Current project MSRV: 1.85.0
> >
> > thread 'main' panicked at src/main.rs:60:17:
> >
> > package 'datafusion' has MSRV 1.86.0 not compatible with current project MSRV 1.85.0
> > ```
>
> I see, should it be other way around I wonder. We need to support MSRV which datafusion supports or older
It's a bit counter intuitive yes, but apparently this is well this way
See usage in `cargo add` (https://github.com/rust-lang/cargo/blob/367fd9f213750cd40317803dd0a5a3ce3f0c676d/src/cargo/ops/cargo_add/mod.rs#L947) and other places (https://github.com/rust-lang/cargo/blob/367fd9f213750cd40317803dd0a5a3ce3f0c676d/src/cargo/ops/cargo_update.rs#L754)
Basically whenever we update a dependency (here `datafusion`), we should make sure to adjust the one in ballista reflecting the new potentiel MSRV from the dependencies
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: github-unsubscribe@datafusion.apache.org
For additional commands, e-mail: github-help@datafusion.apache.org