Skip to content
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

Replace From trait with TryFrom trait for datafusion-proto crate #3401 #3429

Merged
merged 1 commit into from
Sep 10, 2022

Conversation

comphead
Copy link
Contributor

Which issue does this PR close?

Closes #3401 .

Rationale for this change

Replacing From with TryFrom will help with error handling

What changes are included in this PR?

Replace From trait with TryFrom trait for datafusion-proto crate #3401

Are there any user-facing changes?

No

@comphead
Copy link
Contributor Author

@andygrove this is related to your comment #3365 (comment)

Please review

@codecov-commenter
Copy link

Codecov Report

Merging #3429 (c1692a2) into master (3987117) will increase coverage by 0.10%.
The diff coverage is 53.65%.

@@            Coverage Diff             @@
##           master    #3429      +/-   ##
==========================================
+ Coverage   85.51%   85.61%   +0.10%     
==========================================
  Files         296      296              
  Lines       54303    54482     +179     
==========================================
+ Hits        46436    46645     +209     
+ Misses       7867     7837      -30     
Impacted Files Coverage Δ
datafusion/proto/src/logical_plan.rs 17.46% <25.00%> (ø)
datafusion/proto/src/to_proto.rs 52.00% <55.55%> (+3.74%) ⬆️
datafusion/proto/src/lib.rs 93.85% <100.00%> (+0.33%) ⬆️
datafusion/physical-expr/src/planner.rs 92.68% <0.00%> (-1.52%) ⬇️
datafusion/expr/src/logical_plan/plan.rs 76.85% <0.00%> (-0.67%) ⬇️
datafusion/sql/src/planner.rs 81.06% <0.00%> (-0.62%) ⬇️
datafusion/optimizer/src/reduce_outer_join.rs 98.19% <0.00%> (-0.61%) ⬇️
datafusion/core/src/physical_plan/planner.rs 76.87% <0.00%> (-0.58%) ⬇️
datafusion/core/src/physical_plan/metrics/value.rs 86.93% <0.00%> (-0.51%) ⬇️
datafusion/optimizer/src/simplify_expressions.rs 82.83% <0.00%> (-0.24%) ⬇️
... and 11 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Contributor

@alamb alamb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks great to me -- thanks @comphead

@@ -719,7 +719,7 @@ impl AsLogicalPlan for LogicalPlanNode {
})
}
};
let schema: protobuf::Schema = schema.as_ref().into();
let schema: protobuf::Schema = schema.as_ref().try_into()?;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Copy link
Member

@andygrove andygrove left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @comphead!

@andygrove andygrove merged commit 24f2770 into apache:master Sep 10, 2022
@ursabot
Copy link

ursabot commented Sep 10, 2022

Benchmark runs are scheduled for baseline = b247204 and contender = 24f2770. 24f2770 is a master commit associated with this PR. Results will be available as each benchmark for each run completes.
Conbench compare runs links:
[Skipped ⚠️ Benchmarking of arrow-datafusion-commits is not supported on ec2-t3-xlarge-us-east-2] ec2-t3-xlarge-us-east-2
[Skipped ⚠️ Benchmarking of arrow-datafusion-commits is not supported on test-mac-arm] test-mac-arm
[Skipped ⚠️ Benchmarking of arrow-datafusion-commits is not supported on ursa-i9-9960x] ursa-i9-9960x
[Skipped ⚠️ Benchmarking of arrow-datafusion-commits is not supported on ursa-thinkcentre-m75q] ursa-thinkcentre-m75q
Buildkite builds:
Supported benchmarks:
ec2-t3-xlarge-us-east-2: Supported benchmark langs: Python, R. Runs only benchmarks with cloud = True
test-mac-arm: Supported benchmark langs: C++, Python, R
ursa-i9-9960x: Supported benchmark langs: Python, R, JavaScript
ursa-thinkcentre-m75q: Supported benchmark langs: C++, Java

@comphead comphead deleted the replace_from_to_try_from branch September 16, 2022 22:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Replace From trait with TryFrom trait for datafusion-proto crate
5 participants