Re: [VOTE] Release Apache Calcite 1.37.0 (release candidate 4)

2024-04-29 Thread Sergey Nuyanzin
Hi Guilluame,

I played a bit more and I realised that if from commit above I just remove
one line with assert (assert map != null)
then ArrayIndexOutOfBoundsException disappears

same for current main branch, if I remove all lines from SqlFunctions with
assert (now there are 3 such lines) then
ArrayIndexOutOfBoundsException disappears

Thus,  it does not look like a Calcite issue, more like a problem on ASM
side
please correct me if I'm wrong

On Mon, Apr 29, 2024 at 10:33 PM Sergey Nuyanzin 
wrote:

> i follow the procedure described here
> https://calcite.apache.org/docs/howto.html#making-a-release-candidate
> started
> btw I played a bit with git bisect and it shows that the issue
>
> java.lang.ArrayIndexOutOfBoundsException: Index 65536 out of bounds for 
> length 297at 
> org.objectweb.asm.ClassReader.readLabel(ClassReader.java:2695)at 
> org.objectweb.asm.ClassReader.createLabel(ClassReader.java:2711)
>
> started appearing after this commit
>
> https://github.com/apache/calcite/commit/bcf6bd8577b25c563b1c597c70704594a18ca1a3
>
> On Mon, Apr 29, 2024 at 10:01 PM Guillaume Masse
>  wrote:
>
>> Hi Sergey,
>>
>> thanks for trying that update
>>
>> I confirm I have the same issue with your release at
>>
>> https://repository.apache.org/content/repositories/orgapachecalcite-1231/org/apache/calcite/
>>
>>
>> https://github.com/MasseGuillaume/asm-remapper-bug/commit/852e4cd246d278db8acf5e997a54619bc4f85fc7
>>
>> This rules out one of my hypothesis on the java build version.
>>
>> Can you point me to the release procedure you are using? I saw
>> https://calcite.apache.org/develop/#contributing is there more precise
>> steps?
>>
>>
>>
>> On Mon, Apr 29, 2024 at 3:27 PM Sergey Nuyanzin 
>> wrote:
>>
>> > I repeated same procedure with jdk1.8u412
>> > here you can find the jars
>> >
>> >
>> https://repository.apache.org/content/repositories/orgapachecalcite-1231/org/apache/calcite/
>> > it looks like asm-remapper gives the same result...
>> >
>> > On Mon, Apr 29, 2024 at 8:41 PM Guillaume Masse
>> >  wrote:
>> >
>> > > If you take a look at
>> > >
>> > >
>> > >
>> >
>> https://www.openlogic.com/openjdk-downloads?field_java_parent_version_target_id=416_operating_system_target_id=426_architecture_target_id=391_java_package_target_id=All
>> > >
>> > > The most recent release is 8u412-b08
>> > >
>> > > If it follows more or less the openjdk schedule:
>> > >
>> > > https://wiki.openjdk.org/display/jdk8u/Main
>> > >
>> > > *Most recent and past release details:*
>> > >
>> > >- 8u412-b08 (GA), April 16th 2024 [Release <
>> > https://bit.ly/openjdk8u412
>> > > >]
>> > >[Tag ]
>> [
>> > >Binaries
>> > ><
>> > >
>> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u412-b08>
>> > >]
>> > >- 8u402-b06 (GA), January 16th 2024 [Release
>> > >] [Tag
>> > >]
>> > [Binaries
>> > ><
>> > >
>> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u402-b06>
>> > >]
>> > >- 8u392-b08 (GA), October 17th 2023 [Release
>> > >] [Tag
>> > >]
>> > [Binaries
>> > ><
>> > >
>> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u392-b08>
>> > >]
>> > >- 8u382-b05 (GA), July 18th 2023 [Release <
>> > https://bit.ly/openjdk8u382
>> > > >]
>> > >[Tag ]
>> [
>> > >Binaries
>> > ><
>> > >
>> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u382-b05>
>> > >]
>> > >- 8u372-b07 (GA), April 18th 2023 [Release <
>> > https://bit.ly/openjdk8u372
>> > > >]
>> > >[Tag ]
>> [
>> > >Binaries
>> > ><
>> > >
>> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u372-b07>
>> > >]
>> > >
>> > >
>> > > This means your java version is from April 2023. Can you try to update
>> > your
>> > > system to the latest build 8u412-b08 and publish the jarfile
>> somewhere I
>> > > can test ?
>> > >
>> > >
>> > > On Mon, Apr 29, 2024 at 2:25 PM Sergey Nuyanzin 
>> > > wrote:
>> > >
>> > > > Thanks for testing Guillaume
>> > > >
>> > > > >Sergey can you give me all the details about your build environment
>> > so I
>> > > > >can reproduce that bytecode?
>> > > > >OS / java --version
>> > > > yep, sure
>> > > > Ubuntu 22.04.4 LTS,
>> > > > 1.8.0_372-372 (OpenLogic-OpenJDK 25.372-b07)
>> > > >
>> > > > I will also try to look at it with my set up and the info  you've
>> > > provided
>> > > >
>> > > > On Mon, Apr 29, 2024 at 8:03 PM Guillaume Masse
>> > > >  wrote:
>> > > >
>> > > > > -1 (not binding)
>> > > > >
>> > > > > The bytecode of classfile
>> > org/apache/calcite/runtime/SqlFunctions.class
>> > > > is
>> > > > > invalid (and only this 

[jira] [Created] (CALCITE-6392) Support all PostgreSQL 14 date/time patterns for to_date/to_timestamp

2024-04-29 Thread Norman Jordan (Jira)
Norman Jordan created CALCITE-6392:
--

 Summary: Support all PostgreSQL 14 date/time patterns for 
to_date/to_timestamp
 Key: CALCITE-6392
 URL: https://issues.apache.org/jira/browse/CALCITE-6392
 Project: Calcite
  Issue Type: Sub-task
Reporter: Norman Jordan
Assignee: Norman Jordan


Many of the date/time format patterns supported by PostgreSQL 14 are not 
supported in Calcite.
 * HH
 * US
 * 
 * S
 * AM
 * A.M.
 * am
 * a.m.
 * PM
 * P.M.
 * pm
 * p.m.
 * Y,YYY
 * YYY
 * Y
 * IYYY
 * IYY
 * IY
 * I
 * BC
 * B.C.
 * bc
 * b.c.
 * AD
 * A.D.
 * ad
 * a.d.
 * MONTH
 * month
 * MON
 * mon
 * DAY
 * day
 * Dy
 * dy
 * IDDD
 * ID
 * TZH
 * TZM
 * OF

There are also template pattern modifiers that need to be supported.
 * FM (prefix)
 * TH (suffix)
 * th (suffix)
 * FX (prefix)
 * TM (prefix)

Some format patterns in Calcite behave differently from PostgreSQL 14.
 * FF1
 * FF2
 * FF4
 * FF5
 * FF6

Also verify that the other existing format strings produce results that match 
PostgreSQL 14.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


Re: [VOTE] Release Apache Calcite 1.37.0 (release candidate 4)

2024-04-29 Thread Sergey Nuyanzin
i follow the procedure described here
https://calcite.apache.org/docs/howto.html#making-a-release-candidate
started
btw I played a bit with git bisect and it shows that the issue

java.lang.ArrayIndexOutOfBoundsException: Index 65536 out of
bounds for length 297at
org.objectweb.asm.ClassReader.readLabel(ClassReader.java:2695)
at org.objectweb.asm.ClassReader.createLabel(ClassReader.java:2711)

started appearing after this commit
https://github.com/apache/calcite/commit/bcf6bd8577b25c563b1c597c70704594a18ca1a3

On Mon, Apr 29, 2024 at 10:01 PM Guillaume Masse
 wrote:

> Hi Sergey,
>
> thanks for trying that update
>
> I confirm I have the same issue with your release at
>
> https://repository.apache.org/content/repositories/orgapachecalcite-1231/org/apache/calcite/
>
>
> https://github.com/MasseGuillaume/asm-remapper-bug/commit/852e4cd246d278db8acf5e997a54619bc4f85fc7
>
> This rules out one of my hypothesis on the java build version.
>
> Can you point me to the release procedure you are using? I saw
> https://calcite.apache.org/develop/#contributing is there more precise
> steps?
>
>
>
> On Mon, Apr 29, 2024 at 3:27 PM Sergey Nuyanzin 
> wrote:
>
> > I repeated same procedure with jdk1.8u412
> > here you can find the jars
> >
> >
> https://repository.apache.org/content/repositories/orgapachecalcite-1231/org/apache/calcite/
> > it looks like asm-remapper gives the same result...
> >
> > On Mon, Apr 29, 2024 at 8:41 PM Guillaume Masse
> >  wrote:
> >
> > > If you take a look at
> > >
> > >
> > >
> >
> https://www.openlogic.com/openjdk-downloads?field_java_parent_version_target_id=416_operating_system_target_id=426_architecture_target_id=391_java_package_target_id=All
> > >
> > > The most recent release is 8u412-b08
> > >
> > > If it follows more or less the openjdk schedule:
> > >
> > > https://wiki.openjdk.org/display/jdk8u/Main
> > >
> > > *Most recent and past release details:*
> > >
> > >- 8u412-b08 (GA), April 16th 2024 [Release <
> > https://bit.ly/openjdk8u412
> > > >]
> > >[Tag ] [
> > >Binaries
> > ><
> > >
> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u412-b08>
> > >]
> > >- 8u402-b06 (GA), January 16th 2024 [Release
> > >] [Tag
> > >]
> > [Binaries
> > ><
> > >
> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u402-b06>
> > >]
> > >- 8u392-b08 (GA), October 17th 2023 [Release
> > >] [Tag
> > >]
> > [Binaries
> > ><
> > >
> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u392-b08>
> > >]
> > >- 8u382-b05 (GA), July 18th 2023 [Release <
> > https://bit.ly/openjdk8u382
> > > >]
> > >[Tag ] [
> > >Binaries
> > ><
> > >
> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u382-b05>
> > >]
> > >- 8u372-b07 (GA), April 18th 2023 [Release <
> > https://bit.ly/openjdk8u372
> > > >]
> > >[Tag ] [
> > >Binaries
> > ><
> > >
> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u372-b07>
> > >]
> > >
> > >
> > > This means your java version is from April 2023. Can you try to update
> > your
> > > system to the latest build 8u412-b08 and publish the jarfile somewhere
> I
> > > can test ?
> > >
> > >
> > > On Mon, Apr 29, 2024 at 2:25 PM Sergey Nuyanzin 
> > > wrote:
> > >
> > > > Thanks for testing Guillaume
> > > >
> > > > >Sergey can you give me all the details about your build environment
> > so I
> > > > >can reproduce that bytecode?
> > > > >OS / java --version
> > > > yep, sure
> > > > Ubuntu 22.04.4 LTS,
> > > > 1.8.0_372-372 (OpenLogic-OpenJDK 25.372-b07)
> > > >
> > > > I will also try to look at it with my set up and the info  you've
> > > provided
> > > >
> > > > On Mon, Apr 29, 2024 at 8:03 PM Guillaume Masse
> > > >  wrote:
> > > >
> > > > > -1 (not binding)
> > > > >
> > > > > The bytecode of classfile
> > org/apache/calcite/runtime/SqlFunctions.class
> > > > is
> > > > > invalid (and only this classfile)
> > > > >
> > > > > I tested all class files from the following artifacts:
> > > > > calcite-core-1.37.0.jar
> > > > > calcite-linq4j-1.37.0.jar
> > > > > avatica-core-1.25.0.jar
> > > > > avatica-metrics-1.25.0.jar
> > > > >
> > > > > This will prevent bytecode tools like asm (https://asm.ow2.io/)
> from
> > > > > transforming calcite bytecode (for example shading a dependency).
> > > > >
> > > > > See
> > > > > https://gitlab.ow2.org/asm/asm/-/issues/318008
> > > > > https://lists.apache.org/thread/nrt4ysoc14p20sq23z744jyfqh1bznyh
> > > > >
> > > > > To reproduce
> > > > > https://github.com/MasseGuillaume/asm-remapper-bug
> > > > >
> > > > > Sergey can you give me 

Re: [VOTE] Release Apache Calcite 1.37.0 (release candidate 4)

2024-04-29 Thread Guillaume Masse
Hi Sergey,

thanks for trying that update

I confirm I have the same issue with your release at
https://repository.apache.org/content/repositories/orgapachecalcite-1231/org/apache/calcite/

https://github.com/MasseGuillaume/asm-remapper-bug/commit/852e4cd246d278db8acf5e997a54619bc4f85fc7

This rules out one of my hypothesis on the java build version.

Can you point me to the release procedure you are using? I saw
https://calcite.apache.org/develop/#contributing is there more precise
steps?



On Mon, Apr 29, 2024 at 3:27 PM Sergey Nuyanzin  wrote:

> I repeated same procedure with jdk1.8u412
> here you can find the jars
>
> https://repository.apache.org/content/repositories/orgapachecalcite-1231/org/apache/calcite/
> it looks like asm-remapper gives the same result...
>
> On Mon, Apr 29, 2024 at 8:41 PM Guillaume Masse
>  wrote:
>
> > If you take a look at
> >
> >
> >
> https://www.openlogic.com/openjdk-downloads?field_java_parent_version_target_id=416_operating_system_target_id=426_architecture_target_id=391_java_package_target_id=All
> >
> > The most recent release is 8u412-b08
> >
> > If it follows more or less the openjdk schedule:
> >
> > https://wiki.openjdk.org/display/jdk8u/Main
> >
> > *Most recent and past release details:*
> >
> >- 8u412-b08 (GA), April 16th 2024 [Release <
> https://bit.ly/openjdk8u412
> > >]
> >[Tag ] [
> >Binaries
> ><
> > https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u412-b08>
> >]
> >- 8u402-b06 (GA), January 16th 2024 [Release
> >] [Tag
> >]
> [Binaries
> ><
> > https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u402-b06>
> >]
> >- 8u392-b08 (GA), October 17th 2023 [Release
> >] [Tag
> >]
> [Binaries
> ><
> > https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u392-b08>
> >]
> >- 8u382-b05 (GA), July 18th 2023 [Release <
> https://bit.ly/openjdk8u382
> > >]
> >[Tag ] [
> >Binaries
> ><
> > https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u382-b05>
> >]
> >- 8u372-b07 (GA), April 18th 2023 [Release <
> https://bit.ly/openjdk8u372
> > >]
> >[Tag ] [
> >Binaries
> ><
> > https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u372-b07>
> >]
> >
> >
> > This means your java version is from April 2023. Can you try to update
> your
> > system to the latest build 8u412-b08 and publish the jarfile somewhere I
> > can test ?
> >
> >
> > On Mon, Apr 29, 2024 at 2:25 PM Sergey Nuyanzin 
> > wrote:
> >
> > > Thanks for testing Guillaume
> > >
> > > >Sergey can you give me all the details about your build environment
> so I
> > > >can reproduce that bytecode?
> > > >OS / java --version
> > > yep, sure
> > > Ubuntu 22.04.4 LTS,
> > > 1.8.0_372-372 (OpenLogic-OpenJDK 25.372-b07)
> > >
> > > I will also try to look at it with my set up and the info  you've
> > provided
> > >
> > > On Mon, Apr 29, 2024 at 8:03 PM Guillaume Masse
> > >  wrote:
> > >
> > > > -1 (not binding)
> > > >
> > > > The bytecode of classfile
> org/apache/calcite/runtime/SqlFunctions.class
> > > is
> > > > invalid (and only this classfile)
> > > >
> > > > I tested all class files from the following artifacts:
> > > > calcite-core-1.37.0.jar
> > > > calcite-linq4j-1.37.0.jar
> > > > avatica-core-1.25.0.jar
> > > > avatica-metrics-1.25.0.jar
> > > >
> > > > This will prevent bytecode tools like asm (https://asm.ow2.io/) from
> > > > transforming calcite bytecode (for example shading a dependency).
> > > >
> > > > See
> > > > https://gitlab.ow2.org/asm/asm/-/issues/318008
> > > > https://lists.apache.org/thread/nrt4ysoc14p20sq23z744jyfqh1bznyh
> > > >
> > > > To reproduce
> > > > https://github.com/MasseGuillaume/asm-remapper-bug
> > > >
> > > > Sergey can you give me all the details about your build environment
> so
> > I
> > > > can reproduce that bytecode?
> > > > OS / java --version
> > > >
> > > > I do not have the root cause of the issue.
> > > > I suspect it's related to import
> > > > org.checkerframework.checker.nullness.qual.Nullable
> > > >
> > > >
> > > >
> > > >
> > > >
> > > > On Mon, Apr 29, 2024 at 10:56 AM Sergey Nuyanzin <
> snuyan...@gmail.com>
> > > > wrote:
> > > >
> > > > > Hi all,
> > > > >
> > > > > The issue CALCITE-6390 with failing of Arrow Adapter tests on
> Windows
> > > > while
> > > > > building from source is fixed.
> > > > > Thanks  a lot to Caican Can for highlighting the issue
> > > > > Stamatis for quick PR
> > > > > and Ruben and Alessandro for the review!
> > > > >
> > > > > I have created a build for Apache Calcite 1.37.0, release
> > > > > candidate 4.
> > > > >
> > > > > 

Re: [VOTE] Release Apache Calcite 1.37.0 (release candidate 4)

2024-04-29 Thread Sergey Nuyanzin
I repeated same procedure with jdk1.8u412
here you can find the jars
https://repository.apache.org/content/repositories/orgapachecalcite-1231/org/apache/calcite/
it looks like asm-remapper gives the same result...

On Mon, Apr 29, 2024 at 8:41 PM Guillaume Masse
 wrote:

> If you take a look at
>
>
> https://www.openlogic.com/openjdk-downloads?field_java_parent_version_target_id=416_operating_system_target_id=426_architecture_target_id=391_java_package_target_id=All
>
> The most recent release is 8u412-b08
>
> If it follows more or less the openjdk schedule:
>
> https://wiki.openjdk.org/display/jdk8u/Main
>
> *Most recent and past release details:*
>
>- 8u412-b08 (GA), April 16th 2024 [Release  >]
>[Tag ] [
>Binaries
><
> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u412-b08>
>]
>- 8u402-b06 (GA), January 16th 2024 [Release
>] [Tag
>] [Binaries
><
> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u402-b06>
>]
>- 8u392-b08 (GA), October 17th 2023 [Release
>] [Tag
>] [Binaries
><
> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u392-b08>
>]
>- 8u382-b05 (GA), July 18th 2023 [Release  >]
>[Tag ] [
>Binaries
><
> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u382-b05>
>]
>- 8u372-b07 (GA), April 18th 2023 [Release  >]
>[Tag ] [
>Binaries
><
> https://github.com/adoptium/temurin8-binaries/releases/tag/jdk8u372-b07>
>]
>
>
> This means your java version is from April 2023. Can you try to update your
> system to the latest build 8u412-b08 and publish the jarfile somewhere I
> can test ?
>
>
> On Mon, Apr 29, 2024 at 2:25 PM Sergey Nuyanzin 
> wrote:
>
> > Thanks for testing Guillaume
> >
> > >Sergey can you give me all the details about your build environment so I
> > >can reproduce that bytecode?
> > >OS / java --version
> > yep, sure
> > Ubuntu 22.04.4 LTS,
> > 1.8.0_372-372 (OpenLogic-OpenJDK 25.372-b07)
> >
> > I will also try to look at it with my set up and the info  you've
> provided
> >
> > On Mon, Apr 29, 2024 at 8:03 PM Guillaume Masse
> >  wrote:
> >
> > > -1 (not binding)
> > >
> > > The bytecode of classfile org/apache/calcite/runtime/SqlFunctions.class
> > is
> > > invalid (and only this classfile)
> > >
> > > I tested all class files from the following artifacts:
> > > calcite-core-1.37.0.jar
> > > calcite-linq4j-1.37.0.jar
> > > avatica-core-1.25.0.jar
> > > avatica-metrics-1.25.0.jar
> > >
> > > This will prevent bytecode tools like asm (https://asm.ow2.io/) from
> > > transforming calcite bytecode (for example shading a dependency).
> > >
> > > See
> > > https://gitlab.ow2.org/asm/asm/-/issues/318008
> > > https://lists.apache.org/thread/nrt4ysoc14p20sq23z744jyfqh1bznyh
> > >
> > > To reproduce
> > > https://github.com/MasseGuillaume/asm-remapper-bug
> > >
> > > Sergey can you give me all the details about your build environment so
> I
> > > can reproduce that bytecode?
> > > OS / java --version
> > >
> > > I do not have the root cause of the issue.
> > > I suspect it's related to import
> > > org.checkerframework.checker.nullness.qual.Nullable
> > >
> > >
> > >
> > >
> > >
> > > On Mon, Apr 29, 2024 at 10:56 AM Sergey Nuyanzin 
> > > wrote:
> > >
> > > > Hi all,
> > > >
> > > > The issue CALCITE-6390 with failing of Arrow Adapter tests on Windows
> > > while
> > > > building from source is fixed.
> > > > Thanks  a lot to Caican Can for highlighting the issue
> > > > Stamatis for quick PR
> > > > and Ruben and Alessandro for the review!
> > > >
> > > > I have created a build for Apache Calcite 1.37.0, release
> > > > candidate 4.
> > > >
> > > > Thanks to everyone who has contributed to this release.
> > > >
> > > > You can read the release notes here:
> > > >
> > > >
> > >
> >
> https://github.com/apache/calcite/blob/calcite-1.37.0-rc4/site/_docs/history.md
> > > >
> > > > The commit to be voted upon:
> > > >
> > > >
> > >
> >
> https://gitbox.apache.org/repos/asf?p=calcite.git;a=commit;h=044db3d72ee53c1a82ce68b0c2a9b4f0bed81f18
> > > >
> > > > Its hash is 044db3d72ee53c1a82ce68b0c2a9b4f0bed81f18
> > > >
> > > > Tag:
> > > > https://github.com/apache/calcite/tree/calcite-1.37.0-rc4
> > > >
> > > > The artifacts to be voted on are located here:
> > > >
> > https://dist.apache.org/repos/dist/dev/calcite/apache-calcite-1.37.0-rc4
> > > > (revision 68857)
> > > >
> > > > The hashes of the artifacts are as follows:
> > > >
> > > >
> > >
> >
> 

Re: [VOTE] Release Apache Calcite 1.37.0 (release candidate 4)

2024-04-29 Thread Guillaume Masse
If you take a look at

https://www.openlogic.com/openjdk-downloads?field_java_parent_version_target_id=416_operating_system_target_id=426_architecture_target_id=391_java_package_target_id=All

The most recent release is 8u412-b08

If it follows more or less the openjdk schedule:

https://wiki.openjdk.org/display/jdk8u/Main

*Most recent and past release details:*

   - 8u412-b08 (GA), April 16th 2024 [Release ]
   [Tag ] [
   Binaries
   
   ]
   - 8u402-b06 (GA), January 16th 2024 [Release
   ] [Tag
   ] [Binaries
   
   ]
   - 8u392-b08 (GA), October 17th 2023 [Release
   ] [Tag
   ] [Binaries
   
   ]
   - 8u382-b05 (GA), July 18th 2023 [Release ]
   [Tag ] [
   Binaries
   
   ]
   - 8u372-b07 (GA), April 18th 2023 [Release ]
   [Tag ] [
   Binaries
   
   ]


This means your java version is from April 2023. Can you try to update your
system to the latest build 8u412-b08 and publish the jarfile somewhere I
can test ?


On Mon, Apr 29, 2024 at 2:25 PM Sergey Nuyanzin  wrote:

> Thanks for testing Guillaume
>
> >Sergey can you give me all the details about your build environment so I
> >can reproduce that bytecode?
> >OS / java --version
> yep, sure
> Ubuntu 22.04.4 LTS,
> 1.8.0_372-372 (OpenLogic-OpenJDK 25.372-b07)
>
> I will also try to look at it with my set up and the info  you've provided
>
> On Mon, Apr 29, 2024 at 8:03 PM Guillaume Masse
>  wrote:
>
> > -1 (not binding)
> >
> > The bytecode of classfile org/apache/calcite/runtime/SqlFunctions.class
> is
> > invalid (and only this classfile)
> >
> > I tested all class files from the following artifacts:
> > calcite-core-1.37.0.jar
> > calcite-linq4j-1.37.0.jar
> > avatica-core-1.25.0.jar
> > avatica-metrics-1.25.0.jar
> >
> > This will prevent bytecode tools like asm (https://asm.ow2.io/) from
> > transforming calcite bytecode (for example shading a dependency).
> >
> > See
> > https://gitlab.ow2.org/asm/asm/-/issues/318008
> > https://lists.apache.org/thread/nrt4ysoc14p20sq23z744jyfqh1bznyh
> >
> > To reproduce
> > https://github.com/MasseGuillaume/asm-remapper-bug
> >
> > Sergey can you give me all the details about your build environment so I
> > can reproduce that bytecode?
> > OS / java --version
> >
> > I do not have the root cause of the issue.
> > I suspect it's related to import
> > org.checkerframework.checker.nullness.qual.Nullable
> >
> >
> >
> >
> >
> > On Mon, Apr 29, 2024 at 10:56 AM Sergey Nuyanzin 
> > wrote:
> >
> > > Hi all,
> > >
> > > The issue CALCITE-6390 with failing of Arrow Adapter tests on Windows
> > while
> > > building from source is fixed.
> > > Thanks  a lot to Caican Can for highlighting the issue
> > > Stamatis for quick PR
> > > and Ruben and Alessandro for the review!
> > >
> > > I have created a build for Apache Calcite 1.37.0, release
> > > candidate 4.
> > >
> > > Thanks to everyone who has contributed to this release.
> > >
> > > You can read the release notes here:
> > >
> > >
> >
> https://github.com/apache/calcite/blob/calcite-1.37.0-rc4/site/_docs/history.md
> > >
> > > The commit to be voted upon:
> > >
> > >
> >
> https://gitbox.apache.org/repos/asf?p=calcite.git;a=commit;h=044db3d72ee53c1a82ce68b0c2a9b4f0bed81f18
> > >
> > > Its hash is 044db3d72ee53c1a82ce68b0c2a9b4f0bed81f18
> > >
> > > Tag:
> > > https://github.com/apache/calcite/tree/calcite-1.37.0-rc4
> > >
> > > The artifacts to be voted on are located here:
> > >
> https://dist.apache.org/repos/dist/dev/calcite/apache-calcite-1.37.0-rc4
> > > (revision 68857)
> > >
> > > The hashes of the artifacts are as follows:
> > >
> > >
> >
> a6ae7ea1ebbab3e5b723122c9517412d74b6bccba9fb41d360f7c2262ed7f26e5a4cc861a711d4813d27d72a0ffd086ae3a9175abc3c874b079137c84d13f83a
> > > *apache-calcite-1.37.0-src.tar.gz
> > >
> > > A staged Maven repository is available for review at:
> > >
> > >
> >
> https://repository.apache.org/content/repositories/orgapachecalcite-1230/org/apache/calcite/
> > >
> > > Release artifacts are signed with the following key:
> > > https://people.apache.org/keys/committer/snuyanzin.asc
> > > https://www.apache.org/dist/calcite/KEYS
> > >
> > > To create the jars and test Apache Calcite: "gradle build"
> > > (requires an appropriate Gradle/JDK 

[jira] [Created] (CALCITE-6391) Apply mapping to RelCompositeTrait does not apply it to wrapped traits

2024-04-29 Thread James Duong (Jira)
James Duong created CALCITE-6391:


 Summary: Apply mapping to RelCompositeTrait does not apply it to 
wrapped traits
 Key: CALCITE-6391
 URL: https://issues.apache.org/jira/browse/CALCITE-6391
 Project: Calcite
  Issue Type: Bug
Reporter: James Duong


RelCompositeTrait wraps multiple traits. However it does not override 
RelTrait#apply(Mapping.TargetMapping). It uses the default implementation which 
makes the mapping have no effect.

The correct behavior would be to propagate the apply() call to wrapped traits.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)


Re: [VOTE] Release Apache Calcite 1.37.0 (release candidate 4)

2024-04-29 Thread Sergey Nuyanzin
Thanks for testing Guillaume

>Sergey can you give me all the details about your build environment so I
>can reproduce that bytecode?
>OS / java --version
yep, sure
Ubuntu 22.04.4 LTS,
1.8.0_372-372 (OpenLogic-OpenJDK 25.372-b07)

I will also try to look at it with my set up and the info  you've provided

On Mon, Apr 29, 2024 at 8:03 PM Guillaume Masse
 wrote:

> -1 (not binding)
>
> The bytecode of classfile org/apache/calcite/runtime/SqlFunctions.class is
> invalid (and only this classfile)
>
> I tested all class files from the following artifacts:
> calcite-core-1.37.0.jar
> calcite-linq4j-1.37.0.jar
> avatica-core-1.25.0.jar
> avatica-metrics-1.25.0.jar
>
> This will prevent bytecode tools like asm (https://asm.ow2.io/) from
> transforming calcite bytecode (for example shading a dependency).
>
> See
> https://gitlab.ow2.org/asm/asm/-/issues/318008
> https://lists.apache.org/thread/nrt4ysoc14p20sq23z744jyfqh1bznyh
>
> To reproduce
> https://github.com/MasseGuillaume/asm-remapper-bug
>
> Sergey can you give me all the details about your build environment so I
> can reproduce that bytecode?
> OS / java --version
>
> I do not have the root cause of the issue.
> I suspect it's related to import
> org.checkerframework.checker.nullness.qual.Nullable
>
>
>
>
>
> On Mon, Apr 29, 2024 at 10:56 AM Sergey Nuyanzin 
> wrote:
>
> > Hi all,
> >
> > The issue CALCITE-6390 with failing of Arrow Adapter tests on Windows
> while
> > building from source is fixed.
> > Thanks  a lot to Caican Can for highlighting the issue
> > Stamatis for quick PR
> > and Ruben and Alessandro for the review!
> >
> > I have created a build for Apache Calcite 1.37.0, release
> > candidate 4.
> >
> > Thanks to everyone who has contributed to this release.
> >
> > You can read the release notes here:
> >
> >
> https://github.com/apache/calcite/blob/calcite-1.37.0-rc4/site/_docs/history.md
> >
> > The commit to be voted upon:
> >
> >
> https://gitbox.apache.org/repos/asf?p=calcite.git;a=commit;h=044db3d72ee53c1a82ce68b0c2a9b4f0bed81f18
> >
> > Its hash is 044db3d72ee53c1a82ce68b0c2a9b4f0bed81f18
> >
> > Tag:
> > https://github.com/apache/calcite/tree/calcite-1.37.0-rc4
> >
> > The artifacts to be voted on are located here:
> > https://dist.apache.org/repos/dist/dev/calcite/apache-calcite-1.37.0-rc4
> > (revision 68857)
> >
> > The hashes of the artifacts are as follows:
> >
> >
> a6ae7ea1ebbab3e5b723122c9517412d74b6bccba9fb41d360f7c2262ed7f26e5a4cc861a711d4813d27d72a0ffd086ae3a9175abc3c874b079137c84d13f83a
> > *apache-calcite-1.37.0-src.tar.gz
> >
> > A staged Maven repository is available for review at:
> >
> >
> https://repository.apache.org/content/repositories/orgapachecalcite-1230/org/apache/calcite/
> >
> > Release artifacts are signed with the following key:
> > https://people.apache.org/keys/committer/snuyanzin.asc
> > https://www.apache.org/dist/calcite/KEYS
> >
> > To create the jars and test Apache Calcite: "gradle build"
> > (requires an appropriate Gradle/JDK installation)
> >
> > Please vote on releasing this package as Apache Calcite 1.37.0.
> >
> > The vote is open for the next 72 hours and passes if a majority of at
> > least three +1 PMC votes are cast.
> >
> > [ ] +1 Release this package as Apache Calcite 1.37.0
> > [ ]  0 I don't feel strongly about it, but I'm okay with the release
> > [ ] -1 Do not release this package because...
> >
> > Here is my vote:
> >
> > +1 (binding)
> >
> >
> > --
> > Best regards,
> > Sergey
> >
>


-- 
Best regards,
Sergey


Re: [VOTE] Release Apache Calcite 1.37.0 (release candidate 4)

2024-04-29 Thread Guillaume Masse
-1 (not binding)

The bytecode of classfile org/apache/calcite/runtime/SqlFunctions.class is
invalid (and only this classfile)

I tested all class files from the following artifacts:
calcite-core-1.37.0.jar
calcite-linq4j-1.37.0.jar
avatica-core-1.25.0.jar
avatica-metrics-1.25.0.jar

This will prevent bytecode tools like asm (https://asm.ow2.io/) from
transforming calcite bytecode (for example shading a dependency).

See
https://gitlab.ow2.org/asm/asm/-/issues/318008
https://lists.apache.org/thread/nrt4ysoc14p20sq23z744jyfqh1bznyh

To reproduce
https://github.com/MasseGuillaume/asm-remapper-bug

Sergey can you give me all the details about your build environment so I
can reproduce that bytecode?
OS / java --version

I do not have the root cause of the issue.
I suspect it's related to import
org.checkerframework.checker.nullness.qual.Nullable





On Mon, Apr 29, 2024 at 10:56 AM Sergey Nuyanzin 
wrote:

> Hi all,
>
> The issue CALCITE-6390 with failing of Arrow Adapter tests on Windows while
> building from source is fixed.
> Thanks  a lot to Caican Can for highlighting the issue
> Stamatis for quick PR
> and Ruben and Alessandro for the review!
>
> I have created a build for Apache Calcite 1.37.0, release
> candidate 4.
>
> Thanks to everyone who has contributed to this release.
>
> You can read the release notes here:
>
> https://github.com/apache/calcite/blob/calcite-1.37.0-rc4/site/_docs/history.md
>
> The commit to be voted upon:
>
> https://gitbox.apache.org/repos/asf?p=calcite.git;a=commit;h=044db3d72ee53c1a82ce68b0c2a9b4f0bed81f18
>
> Its hash is 044db3d72ee53c1a82ce68b0c2a9b4f0bed81f18
>
> Tag:
> https://github.com/apache/calcite/tree/calcite-1.37.0-rc4
>
> The artifacts to be voted on are located here:
> https://dist.apache.org/repos/dist/dev/calcite/apache-calcite-1.37.0-rc4
> (revision 68857)
>
> The hashes of the artifacts are as follows:
>
> a6ae7ea1ebbab3e5b723122c9517412d74b6bccba9fb41d360f7c2262ed7f26e5a4cc861a711d4813d27d72a0ffd086ae3a9175abc3c874b079137c84d13f83a
> *apache-calcite-1.37.0-src.tar.gz
>
> A staged Maven repository is available for review at:
>
> https://repository.apache.org/content/repositories/orgapachecalcite-1230/org/apache/calcite/
>
> Release artifacts are signed with the following key:
> https://people.apache.org/keys/committer/snuyanzin.asc
> https://www.apache.org/dist/calcite/KEYS
>
> To create the jars and test Apache Calcite: "gradle build"
> (requires an appropriate Gradle/JDK installation)
>
> Please vote on releasing this package as Apache Calcite 1.37.0.
>
> The vote is open for the next 72 hours and passes if a majority of at
> least three +1 PMC votes are cast.
>
> [ ] +1 Release this package as Apache Calcite 1.37.0
> [ ]  0 I don't feel strongly about it, but I'm okay with the release
> [ ] -1 Do not release this package because...
>
> Here is my vote:
>
> +1 (binding)
>
>
> --
> Best regards,
> Sergey
>


[VOTE] Release Apache Calcite 1.37.0 (release candidate 4)

2024-04-29 Thread Sergey Nuyanzin
Hi all,

The issue CALCITE-6390 with failing of Arrow Adapter tests on Windows while
building from source is fixed.
Thanks  a lot to Caican Can for highlighting the issue
Stamatis for quick PR
and Ruben and Alessandro for the review!

I have created a build for Apache Calcite 1.37.0, release
candidate 4.

Thanks to everyone who has contributed to this release.

You can read the release notes here:
https://github.com/apache/calcite/blob/calcite-1.37.0-rc4/site/_docs/history.md

The commit to be voted upon:
https://gitbox.apache.org/repos/asf?p=calcite.git;a=commit;h=044db3d72ee53c1a82ce68b0c2a9b4f0bed81f18

Its hash is 044db3d72ee53c1a82ce68b0c2a9b4f0bed81f18

Tag:
https://github.com/apache/calcite/tree/calcite-1.37.0-rc4

The artifacts to be voted on are located here:
https://dist.apache.org/repos/dist/dev/calcite/apache-calcite-1.37.0-rc4
(revision 68857)

The hashes of the artifacts are as follows:
a6ae7ea1ebbab3e5b723122c9517412d74b6bccba9fb41d360f7c2262ed7f26e5a4cc861a711d4813d27d72a0ffd086ae3a9175abc3c874b079137c84d13f83a
*apache-calcite-1.37.0-src.tar.gz

A staged Maven repository is available for review at:
https://repository.apache.org/content/repositories/orgapachecalcite-1230/org/apache/calcite/

Release artifacts are signed with the following key:
https://people.apache.org/keys/committer/snuyanzin.asc
https://www.apache.org/dist/calcite/KEYS

To create the jars and test Apache Calcite: "gradle build"
(requires an appropriate Gradle/JDK installation)

Please vote on releasing this package as Apache Calcite 1.37.0.

The vote is open for the next 72 hours and passes if a majority of at
least three +1 PMC votes are cast.

[ ] +1 Release this package as Apache Calcite 1.37.0
[ ]  0 I don't feel strongly about it, but I'm okay with the release
[ ] -1 Do not release this package because...

Here is my vote:

+1 (binding)


-- 
Best regards,
Sergey


[CANCEL][VOTE] Release Apache Calcite 1.37.0, release candidate 3)

2024-04-29 Thread Sergey Nuyanzin
Cancel this thread, due to CALCITE-6390[1] issue in the build.

Will start another vote once the issue will be fixed and merged.

[1] https://issues.apache.org/jira/browse/CALCITE-6390

-- 
Best regards,
Sergey


Re: [VOTE] Release Apache Calcite 1.37.0 (release candidate 3)

2024-04-29 Thread Sergey Nuyanzin
I'm going to cancel the vote
because of CALCITE-6390[1]

[1] https://issues.apache.org/jira/browse/CALCITE-6390

On Sun, Apr 28, 2024 at 6:24 PM Sergey Nuyanzin  wrote:

> one finding I forgot to mention
> I noticed that Arrow adapter[1] was merged with skipping of build on
> Windows
> and it definitely has issues while testing on Windows, I raised a jira
> issue for that[2]
>
> so in case of Windows currently should follow same way like it is in GHA
> settings
> gradle build --exclude-task :arrow:build
> I also added this info in how to section about build from source
>
> [1] https://issues.apache.org/jira/browse/CALCITE-2040
> [2] https://issues.apache.org/jira/browse/CALCITE-6390
>
>
> On Sun, Apr 28, 2024 at 6:18 PM Sergey Nuyanzin 
> wrote:
>
>> Hi all,
>>
>> I have created a build for Apache Calcite 1.37.0, release
>> candidate 3.
>>
>> Thanks to everyone who has contributed to this release.
>>
>> You can read the release notes here:
>>
>> https://github.com/apache/calcite/blob/calcite-1.37.0-rc3/site/_docs/history.md
>>
>> The commit to be voted upon:
>>
>> https://gitbox.apache.org/repos/asf?p=calcite.git;a=commit;h=27c206d93d0bcd5692a76fd53feafa68a48afcbf
>>
>> Its hash is 27c206d93d0bcd5692a76fd53feafa68a48afcbf
>>
>> Tag:
>> https://github.com/apache/calcite/tree/calcite-1.37.0-rc3
>>
>> The artifacts to be voted on are located here:
>> https://dist.apache.org/repos/dist/dev/calcite/apache-calcite-1.37.0-rc3
>> (revision 68834)
>>
>> The hashes of the artifacts are as follows:
>>
>> 0c0c629559dfe50613d77e6f5114a09abc691de3b6488ee37bd60b518e4c37e7eb68643031b97ca4641323f6a34bcfc861ed6d56c428dadc355c638ce67662fd
>> *apache-calcite-1.37.0-src.tar.gz
>>
>> A staged Maven repository is available for review at:
>>
>> https://repository.apache.org/content/repositories/orgapachecalcite-1229/org/apache/calcite/
>>
>> Release artifacts are signed with the following key:
>> https://people.apache.org/keys/committer/snuyanzin.asc
>> https://www.apache.org/dist/calcite/KEYS
>>
>> To create the jars and test Apache Calcite: "gradle build"
>> (requires an appropriate Gradle/JDK installation)
>>
>> Please vote on releasing this package as Apache Calcite 1.37.0.
>>
>> The vote is open for the next 72 hours and passes if a majority of at
>> least three +1 PMC votes are cast.
>>
>> [ ] +1 Release this package as Apache Calcite 1.37.0
>> [ ]  0 I don't feel strongly about it, but I'm okay with the release
>> [ ] -1 Do not release this package because...
>>
>> Here is my vote:
>>
>> +1 (binding)
>>
>>
>> --
>> Best regards,
>> Sergey
>>
>
>
> --
> Best regards,
> Sergey
>


-- 
Best regards,
Sergey


Re: [DISCUSS] Towards Calcite 1.37.0

2024-04-29 Thread Sergey Nuyanzin
Hi everyone,

I created RC 3
however as I mentioned in the RC3 thread there is an issue with Arrow
adapter
that it is not supported on Windows, as a result it is not able to pass
tests on Windows.

I noticed that there are some links to Arrow docs telling that there is no
official support for Windows [1],
at least it is stated that it is regularly tested on Linux and Mac.

>From Calcite's point of view it means that building and testing from
sources like `./gradlew clean build`
will not work anymore on Windows. Now on Windows we should have something
like `./gradlew clean build --exclude-task :arrow:build`

I'm not sure we can do much about it, I created a jira issue and placed
some observations there [2].
However it looks like the only thing we can do about it is mentioning this
in breaking changes and howtos for instance hot to build from sources.

Please correct me if I'm wrong


[1] https://arrow.apache.org/docs/java/install.html#system-compatibility
[2] https://issues.apache.org/jira/browse/CALCITE-6390

On Mon, Apr 22, 2024 at 9:20 PM Sergey Nuyanzin  wrote:

> Hi devs,
>
> As it was mentioned earlier in order to an RC I'll start the
> release process now. Therefore main branch is in code freeze until
> further notice.
>
> On Sun, Apr 21, 2024 at 2:22 AM Benchao Li  wrote:
>
>> +1 to produce one RC on the next Monday!
>>
>> Stamatis Zampetakis  于2024年4月19日周五 21:55写道:
>> >
>> > I agree with others that we shouldn't wait too long for cutting a
>> > release. I am pretty sure there are many good PRs that can be merged
>> > but nobody prevents us from making another release once this is done.
>> > Having an RC on Monday would be great.
>> >
>> > For people who may be completely familiar with all our
>> > processes/tools, I outline below two points that are somewhat relevant
>> > to the discussion so far.
>> >
>> > In general we don't have a strict review-then-commit (RTC) policy for
>> > merging changes in Calcite. In various cases committers of the project
>> > can merge changes without getting an explicit approval. This shouldn't
>> > happen for risky or debatable patches but it is fine to do that for
>> > addressing small bugs, minor improvements, etc. It's up to the
>> > discretion of the committer to decide when to merge a change.
>> >
>> > All JIRA activities (conversations, updates, etc.) can be tracked by
>> > subscribing to the issues@calcite list. People who are subscribed to
>> > issues@ receive notifications for every JIRA ticket even if they are
>> > not following a particular ticket.
>> >
>> > Best,
>> > Stamatis
>> >
>> >
>> > On Thu, Apr 18, 2024 at 9:29 PM Sergey Nuyanzin 
>> wrote:
>> > >
>> > > Thanks Benchao and Francis for pushing
>> > > you are right we need to finally make an RC
>> > >
>> > > Thanks Mihai for driving this work
>> > > Starting tomorrow I will have more time which I can use to help with
>> > > review.
>> > > I would suggest to set a deadline like end of Saturday/begin of Sunday
>> > > in order to have an RC on Monday (IIRC anyway because of holidays
>> voting
>> > > period was usually extended)
>> > >
>> > > WDYT?
>> > >
>> > >
>> > >
>> > >
>> > > On Thu, Apr 18, 2024 at 6:55 PM Mihai Budiu  wrote:
>> > >
>> > > > I have a few PR that I would like to land in 1.37 which have
>> received no
>> > > > reviews.
>> > > > Three of them resolve bugs which I consider quite important.
>> > > > Let me describe them briefly, maybe this will help convince someone
>> to
>> > > > contribute the effort of reviewing.
>> > > > Normally this kind of discussion is made inside of JIRA, but I
>> noticed
>> > > > that if one is not following a particular JIRA ticket, they will
>> never see
>> > > > the conversation.
>> > > >
>> > > > [CALCITE-6322] Casts to DECIMAL types are ignored<
>> > > > https://github.com/apache/calcite/pull/3733>
>> > > >
>> > > > Code like (CAST x AS DECIMAL(5, 2)) is treated by Calcite like a
>> NOOP. I
>> > > > consider this as a major bug, which has been open for a very long
>> time.
>> > > > This PR handles the cases where X is a numeric type.
>> > > >
>> > > > [CALCITE-2067] RexLiteral cannot represent accurately floating point
>> > > > values, including NaN, Infinity<
>> > > > https://github.com/apache/calcite/pull/3663>
>> > > >
>> > > > Calcite uses BigDecimal values to represent floating point
>> literals. This
>> > > > has two problems:
>> > > >
>> > > >   *
>> > > > some FP constants cannot be represented exactly, leading to subtle
>> > > > rounding errors in computations that are performed at
>> compilation-time
>> > > >   *
>> > > > FP literals cannot represent special FP values, like NaN
>> > > >
>> > > > This PR switches the representation of FP literals to use Java
>> > > > Double/Float values. This is a breaking change, because it changes
>> the
>> > > > semantics of some programs. However, I claim that these programs
>> were
>> > > > initially incorrect.
>> > > >
>> > > > [CALCITE-3522] Sql validator limits decimal literals to 64 bits and
>> > >