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

Maven build broken at main #16170

Closed
sgammon opened this issue Mar 14, 2024 · 0 comments
Closed

Maven build broken at main #16170

sgammon opened this issue Mar 14, 2024 · 0 comments
Labels
untriaged auto added to all issues by default when created.

Comments

@sgammon
Copy link
Contributor

sgammon commented Mar 14, 2024

What version of protobuf and what language are you using?
Version: main
Language: Java

What operating system (Linux, Windows, ...) and version? N/A

What runtime / compiler are you using (e.g., python version or gcc version)

openjdk version "21.0.2" 2024-01-16
OpenJDK Runtime Environment GraalVM CE 21.0.2+13.1 (build 21.0.2+13-jvmci-23.1-b30)
OpenJDK 64-Bit Server VM GraalVM CE 21.0.2+13.1 (build 21.0.2+13-jvmci-23.1-b30, mixed mode, sharing)

What did you do?
Steps to reproduce the behavior:

  1. git clone git@github.com:protocolbuffers/protobuf.git && cd protobuf
  2. echo 6.3.2 > .bazelversion (due to Bazel build broken at main / 7.x #16169)
  3. bazel build //java:release (passes)
  4. bazel test //java/... (passes)
  5. ln -s which protoc $(pwd)/protoc
  6. cd java && mvn clean package -DskipTests -Dmaven.javadoc.skip=true -Dgpg.skip=true (fails)
➜  protobuf git:(main) ./protoc --version
libprotoc 26.0

What did you expect to see
Successful build

What did you see instead?

[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR : 
[INFO] -------------------------------------------------------------
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[26,31] cannot find symbol
  symbol:   method getDescriptor()
Expand for full failure log
[INFO] --- compiler:3.6.1:testCompile (default-testCompile) @ protobuf-javalite ---
[INFO] Changes detected - recompiling the module!
[INFO] Compiling 131 source files to /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/test-classes
[INFO] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LiteralByteStringTest.java: Some input files use or override a deprecated API.
[INFO] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LiteralByteStringTest.java: Recompile with -Xlint:deprecation for details.
[INFO] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/src/test/java/com/google/protobuf/LiteTest.java: /Volumes/VAULTROOM/proto/protobuf-main/java/lite/src/test/java/com/google/protobuf/LiteTest.java uses unchecked or unsafe operations.
[INFO] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/src/test/java/com/google/protobuf/LiteTest.java: Recompile with -Xlint:unchecked for details.
[INFO] -------------------------------------------------------------
[ERROR] COMPILATION ERROR : 
[INFO] -------------------------------------------------------------
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[26,31] cannot find symbol
  symbol:   method getDescriptor()
  location: class protobuf_unittest.UnittestMset.TestMessageSetExtension1
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[28,31] cannot find symbol
  symbol:   method getDescriptor()
  location: class protobuf_unittest.UnittestMset.TestMessageSetExtension2
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[30,31] cannot find symbol
  symbol:   method getDescriptor()
  location: class protobuf_unittest.UnittestMset.TestMessageSetExtension3
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[41,5] cannot find symbol
  symbol:   class ExtensionRegistry
  location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[41,43] cannot find symbol
  symbol:   variable ExtensionRegistry
  location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[96,45] cannot find symbol
  symbol:   variable ExtensionRegistry
  location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[128,5] cannot find symbol
  symbol:   class ExtensionRegistry
  location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[128,43] cannot find symbol
  symbol:   variable ExtensionRegistry
  location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[152,45] cannot find symbol
  symbol:   variable ExtensionRegistry
  location: class com.google.protobuf.LazilyParsedMessageSetTest
[INFO] 9 errors 
[INFO] -------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[INFO] Reactor Summary for Protocol Buffers [Parent] 4.27.0:
[INFO] 
[INFO] Protocol Buffers [BOM] ............................. SUCCESS [  0.046 s]
[INFO] Protocol Buffers [Parent] .......................... SUCCESS [  0.222 s]
[INFO] Protocol Buffers [Lite] ............................ FAILURE [ 10.713 s]
[INFO] Protocol Buffers [Core] ............................ SKIPPED
[INFO] Protocol Buffers [Util] ............................ SKIPPED
[INFO] Protocol Buffers [Kotlin-Core] ..................... SKIPPED
[INFO] Protocol Buffers [Kotlin-Lite] ..................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  11.690 s
[INFO] Finished at: 2024-03-14T12:56:16-07:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.6.1:testCompile (default-testCompile) on project protobuf-javalite: Compilation failure: Compilation failure: 
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[26,31] cannot find symbol
[ERROR]   symbol:   method getDescriptor()
[ERROR]   location: class protobuf_unittest.UnittestMset.TestMessageSetExtension1
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[28,31] cannot find symbol
[ERROR]   symbol:   method getDescriptor()
[ERROR]   location: class protobuf_unittest.UnittestMset.TestMessageSetExtension2
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[30,31] cannot find symbol
[ERROR]   symbol:   method getDescriptor()
[ERROR]   location: class protobuf_unittest.UnittestMset.TestMessageSetExtension3
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[41,5] cannot find symbol
[ERROR]   symbol:   class ExtensionRegistry
[ERROR]   location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[41,43] cannot find symbol
[ERROR]   symbol:   variable ExtensionRegistry
[ERROR]   location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[96,45] cannot find symbol
[ERROR]   symbol:   variable ExtensionRegistry
[ERROR]   location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[128,5] cannot find symbol
[ERROR]   symbol:   class ExtensionRegistry
[ERROR]   location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[128,43] cannot find symbol
[ERROR]   symbol:   variable ExtensionRegistry
[ERROR]   location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] /Volumes/VAULTROOM/proto/protobuf-main/java/lite/target/generated-test-sources/com/google/protobuf/LazilyParsedMessageSetTest.java:[152,45] cannot find symbol
[ERROR]   symbol:   variable ExtensionRegistry
[ERROR]   location: class com.google.protobuf.LazilyParsedMessageSetTest
[ERROR] -> [Help 1]
[ERROR] 
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR] 
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException
[ERROR] 
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn  -rf :protobuf-javalite

Make sure you include information that can help us debug (full error message, exception listing, stack trace, logs).

Anything else we should know about your project / environment

@sgammon sgammon added the untriaged auto added to all issues by default when created. label Mar 14, 2024
sgammon added a commit to sgammon/protobuf that referenced this issue Mar 14, 2024
Fixes and closes protocolbuffers#16170 by adding missing
test-gen mappings and exclusions.

- fix: missing test-gen mappings
- fix: missing test exclusions

Signed-off-by: Sam Gammon <sam@elide.ventures>
sgammon added a commit to sgammon/protobuf that referenced this issue Mar 14, 2024
Fixes and closes protocolbuffers#16170 by adding missing
test-gen mappings and exclusions.

- fix: missing test-gen mappings
- fix: missing test exclusions

Signed-off-by: Sam Gammon <sam@elide.ventures>
sgammon added a commit to sgammon/protobuf that referenced this issue Apr 15, 2024
Fixes and closes protocolbuffers#16170 by adding missing
test-gen mappings and exclusions.

- fix: missing test-gen mappings
- fix: missing test exclusions

Signed-off-by: Sam Gammon <sam@elide.ventures>
deannagarcia pushed a commit to deannagarcia/protobuf that referenced this issue Jun 20, 2024
## Summary

Fixes and closes protocolbuffers#16170 by adding missing test-gen mappings and exclusions. Recent [changes](protocolbuffers#15362) to Protocol Buffers, along with the addition of the _Editions_ feature, have evolved ahead of Maven; running the build on `main` shows build errors related to the testsuite.

## Changelog

- fix: missing test-gen mappings
- fix: missing test exclusions

Closes protocolbuffers#16176

COPYBARA_INTEGRATE_REVIEW=protocolbuffers#16176 from sgammon:fix/issue-16170 2be118c
PiperOrigin-RevId: 616310039
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
untriaged auto added to all issues by default when created.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant