You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by GitBox <gi...@apache.org> on 2022/01/14 02:35:35 UTC

[GitHub] [arrow-datafusion] xudong963 opened a new pull request #1557: Update to rust 1.58

xudong963 opened a new pull request #1557:
URL: https://github.com/apache/arrow-datafusion/pull/1557


   # 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.
   -->
   
   
   
    # 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.  
   -->
   https://blog.rust-lang.org/2022/01/13/Rust-1.58.0.html
   
   # 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.
   -->
   
   # Are there any user-facing changes?
   <!--
   If there are user-facing changes then we may require documentation to be updated before approving the PR.
   -->
   
   <!--
   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@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] alamb commented on pull request #1557: Update to rust 1.58

Posted by GitBox <gi...@apache.org>.
alamb commented on pull request #1557:
URL: https://github.com/apache/arrow-datafusion/pull/1557#issuecomment-1013021592


   Thanks @xudong963 !


-- 
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@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] alamb merged pull request #1557: Update to rust 1.58

Posted by GitBox <gi...@apache.org>.
alamb merged pull request #1557:
URL: https://github.com/apache/arrow-datafusion/pull/1557


   


-- 
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@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] xudong963 commented on pull request #1557: Update to rust 1.58

Posted by GitBox <gi...@apache.org>.
xudong963 commented on pull request #1557:
URL: https://github.com/apache/arrow-datafusion/pull/1557#issuecomment-1013042019


   > Thanks @xudong963 !
   
   I wrote this PR without reading the email today, so I didn't notice that you have already filed a ticket. I'm sorry @alamb 


-- 
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@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] alamb commented on pull request #1557: Update to rust 1.58

Posted by GitBox <gi...@apache.org>.
alamb commented on pull request #1557:
URL: https://github.com/apache/arrow-datafusion/pull/1557#issuecomment-1013069049


   No worries at all 👍  


-- 
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@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] xudong963 commented on a change in pull request #1557: Update to rust 1.58

Posted by GitBox <gi...@apache.org>.
xudong963 commented on a change in pull request #1557:
URL: https://github.com/apache/arrow-datafusion/pull/1557#discussion_r784469111



##########
File path: datafusion/src/physical_plan/file_format/parquet.rs
##########
@@ -320,12 +320,8 @@ macro_rules! get_min_max_values {
         };
 
         let data_type = field.data_type();
-        let null_scalar: ScalarValue = if let Ok(v) = data_type.try_into() {
-            v
-        } else {
-            // DataFusion doesn't have support for ScalarValues of the column type
-            return None
-        };
+        // The result may be None, because DataFusion doesn't have support for ScalarValues of the column type
+        let null_scalar: ScalarValue = data_type.try_into().ok()?;

Review comment:
       https://rust-lang.github.io/rust-clippy/master/index.html#question_mark

##########
File path: datafusion/src/scalar.rs
##########
@@ -1739,7 +1739,7 @@ impl fmt::Display for ScalarValue {
     fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
         match self {
             ScalarValue::Decimal128(v, p, s) => {
-                write!(f, "{}", format!("{:?},{:?},{:?}", v, p, s))?;
+                write!(f, "{:?},{:?},{:?}", v, p, s)?;

Review comment:
       https://rust-lang.github.io/rust-clippy/master/index.html#format_in_format_args

##########
File path: ballista/rust/scheduler/src/planner.rs
##########
@@ -293,7 +293,7 @@ mod test {
             .plan_query_stages(&job_uuid.to_string(), plan)
             .await?;
         for stage in &stages {
-            println!("{}", displayable(stage.as_ref()).indent().to_string());
+            println!("{}", displayable(stage.as_ref()).indent());

Review comment:
       https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args

##########
File path: datafusion/src/physical_plan/expressions/rank.rs
##########
@@ -39,32 +39,32 @@ pub struct Rank {
 
 #[derive(Debug, Copy, Clone)]
 pub(crate) enum RankType {
-    Rank,
-    DenseRank,
-    PercentRank,
+    Basic,

Review comment:
       https://rust-lang.github.io/rust-clippy/master/index.html#enum_variant_names




-- 
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@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [arrow-datafusion] xudong963 commented on pull request #1557: Update to rust 1.58

Posted by GitBox <gi...@apache.org>.
xudong963 commented on pull request #1557:
URL: https://github.com/apache/arrow-datafusion/pull/1557#issuecomment-1012696005


   Let's use the latest Rust version and learn what has changed!


-- 
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@arrow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org