You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@calcite.apache.org by "chucheng92 (via GitHub)" <gi...@apache.org> on 2023/08/31 12:19:07 UTC
[GitHub] [calcite] chucheng92 opened a new pull request, #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
chucheng92 opened a new pull request, #3405:
URL: https://github.com/apache/calcite/pull/3405
https://issues.apache.org/jira/browse/CALCITE-5961
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] sonarcloud[bot] commented on pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "sonarcloud[bot] (via GitHub)" <gi...@apache.org>.
sonarcloud[bot] commented on PR #3405:
URL: https://github.com/apache/calcite/pull/3405#issuecomment-1700971750
Kudos, SonarCloud Quality Gate passed! [](https://sonarcloud.io/dashboard?id=apache_calcite&pullRequest=3405)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG) [0 Bugs](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY) [0 Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY)
[](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT) [](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT) [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL) [0 Code Smells](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL)
[](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_coverage&view=list) [93.3% Coverage](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_coverage&view=list)
[](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_duplicated_lines_density&view=list) [0.0% Duplication](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_duplicated_lines_density&view=list)
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] sonarcloud[bot] commented on pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "sonarcloud[bot] (via GitHub)" <gi...@apache.org>.
sonarcloud[bot] commented on PR #3405:
URL: https://github.com/apache/calcite/pull/3405#issuecomment-1708293514
Kudos, SonarCloud Quality Gate passed! [](https://sonarcloud.io/dashboard?id=apache_calcite&pullRequest=3405)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG) [0 Bugs](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY) [0 Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY)
[](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT) [](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT) [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL) [0 Code Smells](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL)
[](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_coverage&view=list) [94.1% Coverage](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_coverage&view=list)
[](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_duplicated_lines_density&view=list) [0.0% Duplication](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_duplicated_lines_density&view=list)
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] chucheng92 commented on pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "chucheng92 (via GitHub)" <gi...@apache.org>.
chucheng92 commented on PR #3405:
URL: https://github.com/apache/calcite/pull/3405#issuecomment-1710071252
hi, @NobiGo. If there are no new reviewers to give a comment. Would you help to merge this? 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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] chucheng92 commented on a diff in pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "chucheng92 (via GitHub)" <gi...@apache.org>.
chucheng92 commented on code in PR #3405:
URL: https://github.com/apache/calcite/pull/3405#discussion_r1312463704
##########
testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java:
##########
@@ -5885,7 +5885,9 @@ private static void checkIf(SqlOperatorFixture f) {
final SqlOperatorFixture f = f0.withLibrary(SqlLibrary.SPARK);
f.checkScalar("array_compact(array[null, 1, null, 2])", "[1, 2]",
- "INTEGER ARRAY NOT NULL");
+ "INTEGER NOT NULL ARRAY NOT NULL");
+ f.checkScalar("array_compact(array[1, 2])", "[1, 2]",
+ "INTEGER NOT NULL ARRAY NOT NULL");
f.checkScalar("array_compact(array[null])", "[]",
"NULL ARRAY NOT NULL");
f.checkScalar("array_compact(array(null))", "[]",
Review Comment:
@NobiGo thank for reviewing~ Yes, it was introduced by the previous commit/PR, I have removed it. PTAL.
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] sonarcloud[bot] commented on pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "sonarcloud[bot] (via GitHub)" <gi...@apache.org>.
sonarcloud[bot] commented on PR #3405:
URL: https://github.com/apache/calcite/pull/3405#issuecomment-1704732230
Kudos, SonarCloud Quality Gate passed! [](https://sonarcloud.io/dashboard?id=apache_calcite&pullRequest=3405)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG) [0 Bugs](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY) [0 Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY)
[](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT) [](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT) [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL) [0 Code Smells](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL)
[](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_coverage&view=list) [94.1% Coverage](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_coverage&view=list)
[](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_duplicated_lines_density&view=list) [0.0% Duplication](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_duplicated_lines_density&view=list)
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] NobiGo merged pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "NobiGo (via GitHub)" <gi...@apache.org>.
NobiGo merged PR #3405:
URL: https://github.com/apache/calcite/pull/3405
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] NobiGo commented on a diff in pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "NobiGo (via GitHub)" <gi...@apache.org>.
NobiGo commented on code in PR #3405:
URL: https://github.com/apache/calcite/pull/3405#discussion_r1312440471
##########
testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java:
##########
@@ -5885,7 +5885,9 @@ private static void checkIf(SqlOperatorFixture f) {
final SqlOperatorFixture f = f0.withLibrary(SqlLibrary.SPARK);
f.checkScalar("array_compact(array[null, 1, null, 2])", "[1, 2]",
- "INTEGER ARRAY NOT NULL");
+ "INTEGER NOT NULL ARRAY NOT NULL");
+ f.checkScalar("array_compact(array[1, 2])", "[1, 2]",
+ "INTEGER NOT NULL ARRAY NOT NULL");
f.checkScalar("array_compact(array[null])", "[]",
"NULL ARRAY NOT NULL");
f.checkScalar("array_compact(array(null))", "[]",
Review Comment:
Two same tests for `array_compact(array[null])`?
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] chucheng92 commented on pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "chucheng92 (via GitHub)" <gi...@apache.org>.
chucheng92 commented on PR #3405:
URL: https://github.com/apache/calcite/pull/3405#issuecomment-1704876596
@NobiGo hi. If you have time, could you help to review it again? 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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] sonarcloud[bot] commented on pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "sonarcloud[bot] (via GitHub)" <gi...@apache.org>.
sonarcloud[bot] commented on PR #3405:
URL: https://github.com/apache/calcite/pull/3405#issuecomment-1701176858
Kudos, SonarCloud Quality Gate passed! [](https://sonarcloud.io/dashboard?id=apache_calcite&pullRequest=3405)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG) [0 Bugs](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY) [0 Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY)
[](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT) [](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT) [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL) [0 Code Smells](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL)
[](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_coverage&view=list) [93.3% Coverage](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_coverage&view=list)
[](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_duplicated_lines_density&view=list) [0.0% Duplication](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_duplicated_lines_density&view=list)
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] chucheng92 commented on pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "chucheng92 (via GitHub)" <gi...@apache.org>.
chucheng92 commented on PR #3405:
URL: https://github.com/apache/calcite/pull/3405#issuecomment-1707549985
@NobiGo hi. xiong. thanks for reviewing.
It seems that the commit history has increased a lot due to a force-push by Tanner. Do I need to rebase the main and then wait to see if there are other reviews, then we can merge this?
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] chucheng92 commented on a diff in pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "chucheng92 (via GitHub)" <gi...@apache.org>.
chucheng92 commented on code in PR #3405:
URL: https://github.com/apache/calcite/pull/3405#discussion_r1312463704
##########
testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java:
##########
@@ -5885,7 +5885,9 @@ private static void checkIf(SqlOperatorFixture f) {
final SqlOperatorFixture f = f0.withLibrary(SqlLibrary.SPARK);
f.checkScalar("array_compact(array[null, 1, null, 2])", "[1, 2]",
- "INTEGER ARRAY NOT NULL");
+ "INTEGER NOT NULL ARRAY NOT NULL");
+ f.checkScalar("array_compact(array[1, 2])", "[1, 2]",
+ "INTEGER NOT NULL ARRAY NOT NULL");
f.checkScalar("array_compact(array[null])", "[]",
"NULL ARRAY NOT NULL");
f.checkScalar("array_compact(array(null))", "[]",
Review Comment:
@NobiGo thank for reviewing. Yes, it was introduced by the previous commit/PR, and I can remove it in this PR? WDYT?
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] chucheng92 commented on a diff in pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "chucheng92 (via GitHub)" <gi...@apache.org>.
chucheng92 commented on code in PR #3405:
URL: https://github.com/apache/calcite/pull/3405#discussion_r1312463704
##########
testkit/src/main/java/org/apache/calcite/test/SqlOperatorTest.java:
##########
@@ -5885,7 +5885,9 @@ private static void checkIf(SqlOperatorFixture f) {
final SqlOperatorFixture f = f0.withLibrary(SqlLibrary.SPARK);
f.checkScalar("array_compact(array[null, 1, null, 2])", "[1, 2]",
- "INTEGER ARRAY NOT NULL");
+ "INTEGER NOT NULL ARRAY NOT NULL");
+ f.checkScalar("array_compact(array[1, 2])", "[1, 2]",
+ "INTEGER NOT NULL ARRAY NOT NULL");
f.checkScalar("array_compact(array[null])", "[]",
"NULL ARRAY NOT NULL");
f.checkScalar("array_compact(array(null))", "[]",
Review Comment:
@NobiGo thank for reviewing. Yes, it was introduced by the previous commit/PR, should I can remove it in this PR?
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [calcite] sonarcloud[bot] commented on pull request #3405: [CALCITE-5961] Type inference of ARRAY_COMPACT is incorrect
Posted by "sonarcloud[bot] (via GitHub)" <gi...@apache.org>.
sonarcloud[bot] commented on PR #3405:
URL: https://github.com/apache/calcite/pull/3405#issuecomment-1702183325
Kudos, SonarCloud Quality Gate passed! [](https://sonarcloud.io/dashboard?id=apache_calcite&pullRequest=3405)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG) [0 Bugs](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=BUG)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY) [0 Vulnerabilities](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=VULNERABILITY)
[](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT) [](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT) [0 Security Hotspots](https://sonarcloud.io/project/security_hotspots?id=apache_calcite&pullRequest=3405&resolved=false&types=SECURITY_HOTSPOT)
[](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL) [](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL) [0 Code Smells](https://sonarcloud.io/project/issues?id=apache_calcite&pullRequest=3405&resolved=false&types=CODE_SMELL)
[](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_coverage&view=list) [93.3% Coverage](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_coverage&view=list)
[](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_duplicated_lines_density&view=list) [0.0% Duplication](https://sonarcloud.io/component_measures?id=apache_calcite&pullRequest=3405&metric=new_duplicated_lines_density&view=list)
--
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: commits-unsubscribe@calcite.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org