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/08/22 18:27:23 UTC

[GitHub] [arrow-datafusion] ayushdg opened a new pull request, #3226: Add more trim test cases

ayushdg opened a new pull request, #3226:
URL: https://github.com/apache/arrow-datafusion/pull/3226

   # 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.
   -->
   
   Closes #.
   
    # 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.  
   -->
   Following up on the changes made in #3181 adding more tests checking for trim with optional flag and optional trim_what expr.
   
   # 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.
   -->
   Adds additional tests for trim
   Updates the `BuiltInScalarFunction::Trim` function signature to accept two inputs.
   
   # Are there any user-facing changes?
   <!--
   If there are user-facing changes then we may require documentation to be updated before approving the PR.
   -->
   Existing trim functionality would be unchanged.
   <!--
   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] andygrove merged pull request #3226: Add more trim test cases

Posted by GitBox <gi...@apache.org>.
andygrove merged PR #3226:
URL: https://github.com/apache/arrow-datafusion/pull/3226


-- 
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] ayushdg commented on a diff in pull request #3226: Add more trim test cases

Posted by GitBox <gi...@apache.org>.
ayushdg commented on code in PR #3226:
URL: https://github.com/apache/arrow-datafusion/pull/3226#discussion_r951770978


##########
datafusion/expr/src/function.rs:
##########
@@ -296,15 +296,15 @@ pub fn signature(fun: &BuiltinScalarFunction) -> Signature {
         | BuiltinScalarFunction::SHA256
         | BuiltinScalarFunction::SHA384
         | BuiltinScalarFunction::SHA512
-        | BuiltinScalarFunction::Trim
         | BuiltinScalarFunction::Upper => Signature::uniform(
             1,
             vec![DataType::Utf8, DataType::LargeUtf8],
             fun.volatility(),
         ),
         BuiltinScalarFunction::Btrim
         | BuiltinScalarFunction::Ltrim
-        | BuiltinScalarFunction::Rtrim => Signature::one_of(

Review Comment:
   Given that trim originally supported LargeUtf8 and l/r/btrim might also support those types, does it make sense to update the function signature here to accept largeUtf8's as well?



-- 
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] codecov-commenter commented on pull request #3226: Add more trim test cases

Posted by GitBox <gi...@apache.org>.
codecov-commenter commented on PR #3226:
URL: https://github.com/apache/arrow-datafusion/pull/3226#issuecomment-1222792694

   # [Codecov](https://codecov.io/gh/apache/arrow-datafusion/pull/3226?src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) Report
   > Merging [#3226](https://codecov.io/gh/apache/arrow-datafusion/pull/3226?src=pr&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (bc7caf5) into [master](https://codecov.io/gh/apache/arrow-datafusion/commit/f974e886155e8cabdafec3da5361911a3d7262b9?el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) (f974e88) will **decrease** coverage by `0.00%`.
   > The diff coverage is `100.00%`.
   
   ```diff
   @@            Coverage Diff             @@
   ##           master    #3226      +/-   ##
   ==========================================
   - Coverage   85.84%   85.84%   -0.01%     
   ==========================================
     Files         291      291              
     Lines       52910    52916       +6     
   ==========================================
   + Hits        45421    45426       +5     
   - Misses       7489     7490       +1     
   ```
   
   
   | [Impacted Files](https://codecov.io/gh/apache/arrow-datafusion/pull/3226?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation) | Coverage Δ | |
   |---|---|---|
   | [datafusion/expr/src/function.rs](https://codecov.io/gh/apache/arrow-datafusion/pull/3226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-ZGF0YWZ1c2lvbi9leHByL3NyYy9mdW5jdGlvbi5ycw==) | `97.75% <ø> (ø)` | |
   | [datafusion/core/tests/sql/expr.rs](https://codecov.io/gh/apache/arrow-datafusion/pull/3226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-ZGF0YWZ1c2lvbi9jb3JlL3Rlc3RzL3NxbC9leHByLnJz) | `99.84% <100.00%> (+<0.01%)` | :arrow_up: |
   | [datafusion/expr/src/logical\_plan/plan.rs](https://codecov.io/gh/apache/arrow-datafusion/pull/3226/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation#diff-ZGF0YWZ1c2lvbi9leHByL3NyYy9sb2dpY2FsX3BsYW4vcGxhbi5ycw==) | `77.83% <0.00%> (-0.18%)` | :arrow_down: |
   
   :mega: We’re building smart automated test selection to slash your CI/CD build times. [Learn more](https://about.codecov.io/iterative-testing/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=The+Apache+Software+Foundation)
   


-- 
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] andygrove commented on a diff in pull request #3226: Add more trim test cases

Posted by GitBox <gi...@apache.org>.
andygrove commented on code in PR #3226:
URL: https://github.com/apache/arrow-datafusion/pull/3226#discussion_r951925527


##########
datafusion/expr/src/function.rs:
##########
@@ -296,15 +296,15 @@ pub fn signature(fun: &BuiltinScalarFunction) -> Signature {
         | BuiltinScalarFunction::SHA256
         | BuiltinScalarFunction::SHA384
         | BuiltinScalarFunction::SHA512
-        | BuiltinScalarFunction::Trim
         | BuiltinScalarFunction::Upper => Signature::uniform(
             1,
             vec![DataType::Utf8, DataType::LargeUtf8],
             fun.volatility(),
         ),
         BuiltinScalarFunction::Btrim
         | BuiltinScalarFunction::Ltrim
-        | BuiltinScalarFunction::Rtrim => Signature::one_of(

Review Comment:
   Tests are passing, which must mean that we did not have any tests for `Trim` with `LargeUtf8` so I think this change is fine as is. If we declare that `LargeUtf8` is supported then we need to add relevant tests as well.



-- 
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] ursabot commented on pull request #3226: Add more trim test cases

Posted by GitBox <gi...@apache.org>.
ursabot commented on PR #3226:
URL: https://github.com/apache/arrow-datafusion/pull/3226#issuecomment-1224161267

   Benchmark runs are scheduled for baseline = 9ecf277a396c300a2ddbd5b2b4ab46947a091a43 and contender = 74872a31969c01d976ecc36135082c8b8aeaf953. 74872a31969c01d976ecc36135082c8b8aeaf953 is a master commit associated with this PR. Results will be available as each benchmark for each run completes.
   Conbench compare runs links:
   [Skipped :warning: Benchmarking of arrow-datafusion-commits is not supported on ec2-t3-xlarge-us-east-2] [ec2-t3-xlarge-us-east-2](https://conbench.ursa.dev/compare/runs/22ff5821f1cc4ccb97efcb523c9f4d47...a127328f7b3146aca8ea519058847cd5/)
   [Skipped :warning: Benchmarking of arrow-datafusion-commits is not supported on test-mac-arm] [test-mac-arm](https://conbench.ursa.dev/compare/runs/5842658807794a75b92ebb753b6c0e84...bfb4c809f27c415285e2ed3a76a54802/)
   [Skipped :warning: Benchmarking of arrow-datafusion-commits is not supported on ursa-i9-9960x] [ursa-i9-9960x](https://conbench.ursa.dev/compare/runs/c8eba7b283c144149ffd963f7a48b0b2...2e4e7937ea554727b06046a03addc63c/)
   [Skipped :warning: Benchmarking of arrow-datafusion-commits is not supported on ursa-thinkcentre-m75q] [ursa-thinkcentre-m75q](https://conbench.ursa.dev/compare/runs/f28b96a1bd864c6e8b6e409d46908e5e...127c252419b045bc94aedd480fb616f0/)
   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
   


-- 
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