You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@calcite.apache.org by "Stamatis Zampetakis (Jira)" <ji...@apache.org> on 2021/09/27 13:28:00 UTC
[jira] [Comment Edited] (CALCITE-4798) Gradle build fails due to
deprecated metadata APIs
[ https://issues.apache.org/jira/browse/CALCITE-4798?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17420741#comment-17420741 ]
Stamatis Zampetakis edited comment on CALCITE-4798 at 9/27/21, 1:27 PM:
------------------------------------------------------------------------
I think the {{-Werror}} flag is not standard thus not supported by all JDK providers. I can reproduce the problem with various Oracle JDKs but failed to do so with OpenJDK for instance.
||JDK||./gradlew build||
|/opt/jdks/jdk1.8.0_261|KO|
|/opt/jdks/jdk8u302-b08|KO|
was (Author: zabetak):
I think the {{-Werror}} flag is not standard thus not supported by all JDK providers. I can reproduce the problem with various Oracle JDKs but failed to do so with OpenJDK for instance.
||JDK||./gradlew build||
|/opt/jdks/jdk1.8.0_261|KO|
|/opt/jdks/jdk8u302-b08|KO|
> Gradle build fails due to deprecated metadata APIs
> --------------------------------------------------
>
> Key: CALCITE-4798
> URL: https://issues.apache.org/jira/browse/CALCITE-4798
> Project: Calcite
> Issue Type: Bug
> Components: build
> Reporter: Stamatis Zampetakis
> Assignee: James Starr
> Priority: Major
> Labels: pull-request-available
> Fix For: 1.28.0
>
> Time Spent: 10m
> Remaining Estimate: 0h
>
> Running {{./gradlew build}} locally fails since {{CachingRelMetadataProvider}} was deprecated in [b51a2e14343df089ee0b6c3e8a20c00c51186421|https://github.com/apache/calcite/commit/b51a2e14343df089ee0b6c3e8a20c00c51186421] but is still used in {{PlannerImpl}}.
> {noformat}
> $ ./gradlew build
> > Configure project :
> Building Apache Calcite 1.28.0-SNAPSHOT
> > Task :core:compileJava
> Ignoring profile 'okta' on line 26 because it did not start with 'profile ' and it was not 'default'.
> /Projects/Apache/calcite/core/src/main/java/org/apache/calcite/prepare/PlannerImpl.java:39: warning: [deprecation] CachingRelMetadataProvider in org.apache.calcite.rel.metadata has been deprecated
> import org.apache.calcite.rel.metadata.CachingRelMetadataProvider;
> ^
> error: warnings found and -Werror specified
> Note: Some input files use unchecked or unsafe operations.
> Note: Recompile with -Xlint:unchecked for details.
> 1 error
> 1 warning
> > Task :core:compileJava FAILED
> FAILURE: Build failed with an exception.
> * What went wrong:
> Execution failed for task ':core:compileJava'.
> > Compilation failed; see the compiler error output for details.
> * Try:
> Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
> * Get more help at https://help.gradle.org
> Deprecated Gradle features were used in this build, making it incompatible with Gradle 7.0.
> Use '--warning-mode all' to show the individual deprecation warnings.
> See https://docs.gradle.org/6.8.3/userguide/command_line_interface.html#sec:command_line_warnings
> BUILD FAILED in 4s
> 193 actionable tasks: 4 executed, 189 up-to-date
> S3 cache 423ms wasted on misses, reads: 1, elapsed: 423ms
> {noformat}
> Although locally the build fails it seems that in CI we are not using the {{-Werror}} flag so the error is hidden.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)