Commit Graph

2043 Commits

Author SHA1 Message Date
dependabot[bot] 500ec501a7
Bump error_prone_annotations from 2.19.1 to 2.20.0 (#2421)
Bumps [error_prone_annotations](https://github.com/google/error-prone) from 2.19.1 to 2.20.0.
- [Release notes](https://github.com/google/error-prone/releases)
- [Commits](https://github.com/google/error-prone/compare/v2.19.1...v2.20.0)

---
updated-dependencies:
- dependency-name: com.google.errorprone:error_prone_annotations
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Éamonn McManus <emcmanus@google.com>
2023-06-19 09:16:18 -07:00
dependabot[bot] 5fa61b25b4
Bump maven-shade-plugin from 3.4.1 to 3.5.0 (#2423)
Bumps [maven-shade-plugin](https://github.com/apache/maven-shade-plugin) from 3.4.1 to 3.5.0.
- [Release notes](https://github.com/apache/maven-shade-plugin/releases)
- [Commits](https://github.com/apache/maven-shade-plugin/compare/maven-shade-plugin-3.4.1...maven-shade-plugin-3.5.0)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-shade-plugin
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Éamonn McManus <emcmanus@google.com>
2023-06-19 08:44:18 -07:00
dependabot[bot] fd8c8ac082
Bump truth from 1.1.4 to 1.1.5 (#2424)
Bumps [truth](https://github.com/google/truth) from 1.1.4 to 1.1.5.
- [Release notes](https://github.com/google/truth/releases)
- [Commits](https://github.com/google/truth/compare/v1.1.4...v1.1.5)

---
updated-dependencies:
- dependency-name: com.google.truth:truth
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-19 08:40:32 -07:00
dependabot[bot] 8c523b8d2c
Bump guava from 32.0.0-jre to 32.0.1-jre (#2415)
Bumps [guava](https://github.com/google/guava) from 32.0.0-jre to 32.0.1-jre.
- [Release notes](https://github.com/google/guava/releases)
- [Commits](https://github.com/google/guava/commits)

---
updated-dependencies:
- dependency-name: com.google.guava:guava
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-14 14:03:38 -07:00
dependabot[bot] 621a6a2d9a
Bump guava-testlib from 32.0.0-jre to 32.0.1-jre (#2416)
Bumps [guava-testlib](https://github.com/google/guava) from 32.0.0-jre to 32.0.1-jre.
- [Release notes](https://github.com/google/guava/releases)
- [Commits](https://github.com/google/guava/commits)

---
updated-dependencies:
- dependency-name: com.google.guava:guava-testlib
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-14 14:03:15 -07:00
Marcono1234 44217b9100
Rename branch references in GitHub workflow to 'main' (#2418)
* Rename branch references in GitHub workflow to 'main'

* Revert accidental branch reference renaming
2023-06-12 08:46:38 -07:00
Éamonn McManus a80bc24e04
Rename `master` to `main` everywhere. (#2410) 2023-06-07 11:02:13 -07:00
dependabot[bot] e7f85dff8a
Bump maven-surefire-plugin from 3.1.0 to 3.1.2 (#2411)
Bumps [maven-surefire-plugin](https://github.com/apache/maven-surefire) from 3.1.0 to 3.1.2.
- [Release notes](https://github.com/apache/maven-surefire/releases)
- [Commits](https://github.com/apache/maven-surefire/compare/surefire-3.1.0...surefire-3.1.2)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-surefire-plugin
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-07 08:17:46 -07:00
dependabot[bot] 144626ddd9
Bump maven-failsafe-plugin from 3.1.0 to 3.1.2 (#2412)
Bumps [maven-failsafe-plugin](https://github.com/apache/maven-surefire) from 3.1.0 to 3.1.2.
- [Release notes](https://github.com/apache/maven-surefire/releases)
- [Commits](https://github.com/apache/maven-surefire/compare/surefire-3.1.0...surefire-3.1.2)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-failsafe-plugin
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-07 08:16:59 -07:00
dependabot[bot] cf50a5aaf1
Bump maven-release-plugin from 3.0.0 to 3.0.1 (#2409)
Bumps [maven-release-plugin](https://github.com/apache/maven-release) from 3.0.0 to 3.0.1.
- [Release notes](https://github.com/apache/maven-release/releases)
- [Commits](https://github.com/apache/maven-release/compare/maven-release-3.0.0...maven-release-3.0.1)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-release-plugin
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-06-05 12:55:48 -07:00
dependabot[bot] 2d7cc2e9f4
Bump jackson-databind from 2.15.1 to 2.15.2 (#2403)
Bumps [jackson-databind](https://github.com/FasterXML/jackson) from 2.15.1 to 2.15.2.
- [Commits](https://github.com/FasterXML/jackson/commits)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.core:jackson-databind
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-31 09:45:36 -07:00
dependabot[bot] 6292eafcdf
Bump truth from 1.1.3 to 1.1.4 (#2404)
Bumps [truth](https://github.com/google/truth) from 1.1.3 to 1.1.4.
- [Release notes](https://github.com/google/truth/releases)
- [Commits](https://github.com/google/truth/commits/v1.1.4)

---
updated-dependencies:
- dependency-name: com.google.truth:truth
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-31 09:45:08 -07:00
Marcono1234 481ac9b82c
Use non-`null` `FormattingStyle`; configure space after separator (#2345)
* Use non-`null` `FormattingStyle`; configure space after separator

* Improve Javadoc and tests

* Rename to plural separator*s*

* Add explicit tests for default formatting styles

---------

Co-authored-by: Éamonn McManus <emcmanus@google.com>
2023-05-30 16:32:22 -07:00
dependabot[bot] d3e17587fe
Bump guava from 31.1-jre to 32.0.0-jre (#2399)
Bumps [guava](https://github.com/google/guava) from 31.1-jre to 32.0.0-jre.
- [Release notes](https://github.com/google/guava/releases)
- [Commits](https://github.com/google/guava/commits)

---
updated-dependencies:
- dependency-name: com.google.guava:guava
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-30 15:42:32 -07:00
dependabot[bot] a8a928ee51
Bump guava-testlib from 31.1-jre to 32.0.0-jre (#2400)
Bumps [guava-testlib](https://github.com/google/guava) from 31.1-jre to 32.0.0-jre.
- [Release notes](https://github.com/google/guava/releases)
- [Commits](https://github.com/google/guava/commits)

---
updated-dependencies:
- dependency-name: com.google.guava:guava-testlib
  dependency-type: direct:development
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-30 15:42:06 -07:00
Marcono1234 43396e45fd
Add ProGuard / R8 integration tests & add default ProGuard rules (#2397)
* Add code shrinking tools integration test

* Keep no-args constructor of classes usable with JsonAdapter

* Add library ProGuard rules for Gson

They are automatically applied for all users of Gson, see
https://developer.android.com/build/shrink-code#configuration-files

* Skip japicmp-maven-plugin for shrinker-test

* Add more tests for JsonAdapter, add tests for generic classes

* Extend default constructor test

* Add Troubleshooting Guide entry for TypeToken
2023-05-28 12:24:05 -07:00
Marcono1234 4c65a82871
Remove accidental invisible characters from Troubleshooting Guide (#2395)
Accidentally contained U+200C (Zero Width Non-Joiner) followed by U+200B (Zero Width Space)
2023-05-24 14:41:26 -07:00
dependabot[bot] ed8ca46aa8
Bump maven-source-plugin from 3.2.1 to 3.3.0 (#2392)
Bumps [maven-source-plugin](https://github.com/apache/maven-source-plugin) from 3.2.1 to 3.3.0.
- [Commits](https://github.com/apache/maven-source-plugin/compare/maven-source-plugin-3.2.1...maven-source-plugin-3.3.0)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-source-plugin
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-22 07:44:37 -07:00
dependabot[bot] 6e39d1f1d3
Bump jackson-databind from 2.15.0 to 2.15.1 (#2391)
Bumps [jackson-databind](https://github.com/FasterXML/jackson) from 2.15.0 to 2.15.1.
- [Commits](https://github.com/FasterXML/jackson/commits)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.core:jackson-databind
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-17 07:01:17 -07:00
Marcono1234 a9bd30b577
Enable Error Prone HidingField bug pattern again (#2390)
Bug which required disabling this bug pattern was fixed in 2.19.1 and
Error Prone dependency was updated to that version in commit
3c4b072100
2023-05-11 13:18:09 -07:00
dependabot[bot] 3c4b072100
Bump error_prone_core from 2.19.0 to 2.19.1 (#2388)
Bumps [error_prone_core](https://github.com/google/error-prone) from 2.19.0 to 2.19.1.
- [Release notes](https://github.com/google/error-prone/releases)
- [Commits](https://github.com/google/error-prone/compare/v2.19.0...v2.19.1)

---
updated-dependencies:
- dependency-name: com.google.errorprone:error_prone_core
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-11 09:43:50 -07:00
dependabot[bot] eae63f92fb
Bump error_prone_annotations from 2.19.0 to 2.19.1 (#2389)
Bumps [error_prone_annotations](https://github.com/google/error-prone) from 2.19.0 to 2.19.1.
- [Release notes](https://github.com/google/error-prone/releases)
- [Commits](https://github.com/google/error-prone/compare/v2.19.0...v2.19.1)

---
updated-dependencies:
- dependency-name: com.google.errorprone:error_prone_annotations
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-11 09:43:22 -07:00
Éamonn McManus 49dbc6f072
Update Error Prone, bypass a bug in it, fix some problems it flags (#2387) 2023-05-09 10:28:39 -07:00
dependabot[bot] b330ad9790
Bump error_prone_annotations from 2.18.0 to 2.19.0 (#2386)
Bumps [error_prone_annotations](https://github.com/google/error-prone) from 2.18.0 to 2.19.0.
- [Release notes](https://github.com/google/error-prone/releases)
- [Commits](https://github.com/google/error-prone/compare/v2.18.0...v2.19.0)

---
updated-dependencies:
- dependency-name: com.google.errorprone:error_prone_annotations
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-09 06:44:34 -07:00
dependabot[bot] 1339b50629
Bump maven-surefire-plugin from 3.0.0 to 3.1.0 (#2383)
Bumps [maven-surefire-plugin](https://github.com/apache/maven-surefire) from 3.0.0 to 3.1.0.
- [Release notes](https://github.com/apache/maven-surefire/releases)
- [Commits](https://github.com/apache/maven-surefire/compare/surefire-3.0.0...surefire-3.1.0)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-surefire-plugin
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Éamonn McManus <emcmanus@google.com>
2023-05-08 12:17:29 -07:00
dependabot[bot] 5fffd5aca1
Bump maven-gpg-plugin from 3.0.1 to 3.1.0 (#2384)
Bumps [maven-gpg-plugin](https://github.com/apache/maven-gpg-plugin) from 3.0.1 to 3.1.0.
- [Commits](https://github.com/apache/maven-gpg-plugin/compare/maven-gpg-plugin-3.0.1...maven-gpg-plugin-3.1.0)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-gpg-plugin
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-08 12:11:43 -07:00
dependabot[bot] 8333ccac62
Bump moditect-maven-plugin from 1.0.0.RC3 to 1.0.0.Final (#2381)
Bumps [moditect-maven-plugin](https://github.com/moditect/moditect) from 1.0.0.RC3 to 1.0.0.Final.
- [Release notes](https://github.com/moditect/moditect/releases)
- [Commits](https://github.com/moditect/moditect/compare/1.0.0.RC3...1.0.0.Final)

---
updated-dependencies:
- dependency-name: org.moditect:moditect-maven-plugin
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-05-04 06:23:28 -07:00
dependabot[bot] 55cf9fa941
Bump jackson-databind from 2.14.2 to 2.15.0 (#2377)
Bumps [jackson-databind](https://github.com/FasterXML/jackson) from 2.14.2 to 2.15.0.
- [Release notes](https://github.com/FasterXML/jackson/releases)
- [Commits](https://github.com/FasterXML/jackson/commits)

---
updated-dependencies:
- dependency-name: com.fasterxml.jackson.core:jackson-databind
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-24 07:27:14 -07:00
Marcono1234 cbad1aa79f
Link to troubleshooting guide from exception messages (#2357)
* Link to troubleshooting guide from exception messages

* Add examples to troubleshooting guide

* Use proper anchor names for troubleshooting guide
2023-04-15 13:36:26 -07:00
Avi Mathur 1717fd62cf
Remove the comment strings " json is " from the UserGuide.md (#2374)
* removed ' json is ' from the UserGuide.md

* few more changes in UserGuide.md
2023-04-15 11:18:21 -07:00
Éamonn McManus 37ed0fcbd7
Address review comments from @Marcono1234. (#2372) 2023-04-10 13:33:47 -07:00
Éamonn McManus c1da2d7070
Add `@CanIgnoreReturnValue` as appropriate to Gson methods. (#2369)
This annotation indicates that return value of the annotated method does
not need to be used. If it is _not_ present on a non-void method, and if
Error Prone's `CheckReturnValue` is active, then calling the method
without using the result is an error. However, we are not enabling
`CheckReturnValue` by default here.

Also update some code that does ignore return values, so that the
returned value is used, if only by assigning it to an unused variable.
2023-04-10 10:50:25 -07:00
dependabot[bot] b43ccee889
Bump maven-surefire-plugin from 3.0.0-M9 to 3.0.0 (#2342)
Bumps [maven-surefire-plugin](https://github.com/apache/maven-surefire) from 3.0.0-M9 to 3.0.0.
- [Release notes](https://github.com/apache/maven-surefire/releases)
- [Commits](https://github.com/apache/maven-surefire/compare/surefire-3.0.0-M9...surefire-3.0.0)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-surefire-plugin
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-08 10:05:20 -07:00
dependabot[bot] f1b4a71de5
Bump maven-enforcer-plugin from 3.2.1 to 3.3.0 (#2366)
Bumps [maven-enforcer-plugin](https://github.com/apache/maven-enforcer) from 3.2.1 to 3.3.0.
- [Release notes](https://github.com/apache/maven-enforcer/releases)
- [Commits](https://github.com/apache/maven-enforcer/compare/enforcer-3.2.1...enforcer-3.3.0)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-enforcer-plugin
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-04-05 09:06:16 -07:00
Maicol 051cb43fd9
Fixes outdated URL (`ISO8601Utils.java`) (#2363)
* Fixes comments

Fixes the javadoc and the link to Jackson databind ISO8601Utils.java

* Updates outdated URL in UtcDateTypeAdapter
2023-04-01 13:59:51 -07:00
TuZhiQiang 3adead6ab4
Fix incorrect sample code in User Guide (#2362) 2023-03-30 10:32:09 -07:00
dependabot[bot] 1d9d9774be
Bump maven-resources-plugin from 3.3.0 to 3.3.1 (#2360)
Bumps [maven-resources-plugin](https://github.com/apache/maven-resources-plugin) from 3.3.0 to 3.3.1.
- [Release notes](https://github.com/apache/maven-resources-plugin/releases)
- [Commits](https://github.com/apache/maven-resources-plugin/compare/maven-resources-plugin-3.3.0...maven-resources-plugin-3.3.1)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-resources-plugin
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-28 08:28:24 -07:00
Marcono1234 c34b9ff79a
Fix incorrect inherited URLs in `pom.xml` (#2351)
Previously Maven appended the artifact ID of the modules which lead for
example for the `gson` module to the incorrect URL https://github.com/google/gson/gson

This can be checked with `mvn help:effective-pom`
2023-03-23 13:36:57 -07:00
Marcono1234 7f303b5db4
Mention creation of GitHub release in `ReleaseProcess.md` (#2349)
* Mention creation of GitHub release in `ReleaseProcess.md`

* Link to GitHub releases from README
2023-03-21 15:26:57 -07:00
dependabot[bot] 75bf3b4157
Bump maven-release-plugin from 3.0.0-M7 to 3.0.0 (#2347)
Bumps [maven-release-plugin](https://github.com/apache/maven-release) from 3.0.0-M7 to 3.0.0.
- [Release notes](https://github.com/apache/maven-release/releases)
- [Commits](https://github.com/apache/maven-release/compare/maven-release-3.0.0-M7...maven-release-3.0.0)

---
updated-dependencies:
- dependency-name: org.apache.maven.plugins:maven-release-plugin
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-21 07:57:58 -07:00
Marcono1234 26229d33d8
FormattingStyle follow-up (#2327)
* FormattingStyle follow-up

* Add links to FormattingStyle

* Use Truth for FormattingStyleTest

* Reduce pull request scope to Javadoc and minor code changes
2023-03-19 09:15:35 -07:00
Marcono1234 6eddbf3031
Make dependency on Error Prone Annotations non-optional (#2346) 2023-03-19 08:54:31 -07:00
dependabot[bot] 1da826dc6c
Bump moditect-maven-plugin from 1.0.0.RC2 to 1.0.0.RC3 (#2340)
Bumps [moditect-maven-plugin](https://github.com/moditect/moditect) from 1.0.0.RC2 to 1.0.0.RC3.
- [Release notes](https://github.com/moditect/moditect/releases)
- [Commits](https://github.com/moditect/moditect/compare/1.0.0.CR2...1.0.0.RC3)

---
updated-dependencies:
- dependency-name: org.moditect:moditect-maven-plugin
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-08 06:45:07 -08:00
Marcono1234 2f7be29a30
Specify Error Prone JVM args with `.mvn/jvm.config` (#2339)
* Specify Error Prone JVM args with `.mvn/jvm.config`

This allows avoiding fork mode for compilation, which:
- might slightly reduce compilation time
- guarantees that all compiler diagnostics are properly reported

* Combine enforcer executions
2023-03-07 13:39:05 -08:00
Marcono1234 f467ec20c3
Fix incorrect comment in `pom.xml` (#2338)
Accidentally referred to wrong JDK bug report
2023-03-06 12:29:09 -08:00
Maicol 85ebaf7c35
Fix #2334 (#2337)
* Fix #2334

This commit replaces the `NumberFormatException` with `MalformedJsonException` in the `JsonReader#readEscapeCharacter()` and also fixes the tests.

* Removes white-space
2023-03-06 08:24:09 -08:00
Marcono1234 0adcdc80d5
Fail Maven build on warnings (#2335)
* Fail Maven build on warnings

* Fix configuration parameter name

For the Javadoc plugin it is "warnings" (plural) instead of "warning"
2023-03-06 07:33:50 -08:00
Marcono1234 ef35a34a60
Enforce build using JDK >= 11 (#2333)
Building already requires JDK >= 11, but previously using a lower JDK
version such as JDK 8 would lead to cryptic build errors because some
compiler flags are unsupported.
Using the Maven Enforcer Plugin makes sure that the build fails early
with a somewhat better to understand error message.
2023-03-04 15:40:49 -08:00
dependabot[bot] 19983737ae
Bump japicmp-maven-plugin from 0.17.1 to 0.17.2 (#2331)
Bumps [japicmp-maven-plugin](https://github.com/siom79/japicmp) from 0.17.1 to 0.17.2.
- [Release notes](https://github.com/siom79/japicmp/releases)
- [Changelog](https://github.com/siom79/japicmp/blob/master/release.py)
- [Commits](https://github.com/siom79/japicmp/compare/japicmp-base-0.17.1...japicmp-base-0.17.2)

---
updated-dependencies:
- dependency-name: com.github.siom79.japicmp:japicmp-maven-plugin
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2023-03-02 10:15:13 -08:00
Maicol dc20b7561a
Fix error prone warns (#2320)
* Adds `@SuppressWarnings("NarrowingCompoundAssignment")`

* Adds `@SuppressWarnings("TypeParameterUnusedInFormals")`

* Adds `@SuppressWarnings("JavaUtilDate")`

* Adds a limit to `String.split()`

* Add `error_prone_annotations` to the `pom.xml`

* Adds `@InlineMe(...)` to deprecated methods

* Adds `@SuppressWarnings("ImmutableEnumChecker")`

* Adds `@SuppressWarnings("ModifiedButNotUsed")`

* Adds `@SuppressWarnings("MixedMutabilityReturnType")`

* Removes an unused import

* Adds `requires` to `module-info.java`

* Adds ErrorProne `link` into `pom.xml`

* Remove unused imports

Removed from:
- ParseBenchmark

* Adds `@SuppressWarnings("EqualsGetClass")`

* Excludes from `proto` just the generated code.

Replaces `.*proto.*` with `.*/generated-test-sources/protobuf/.*` in such way will be excluded just the generated code and not the whole `proto` directory

* Removes an unused variable

Removes the `descriptor` variable because is unused.

* Fixes the `BadImport` warn into `ProtosWithAnnotationsTest`

* Fixes the `BadImport` warns into `ProtosWithAnnotationsTest`

* Enables ErrorProne in `gson/src/test.*`

Removes the `gson/src/test.*` path from the `-XepExcludedPaths` parameter of the ErrorProne plugin

* Fixes `UnusedVariable` warns

This commit fix all `UnusedVariable` warns given by ErrorProne in the `gson/src/test.*` path.

Some field is annotated with `@Keep` that means is used by reflection.
In some other case the record is annotated with `@SuppressWarnings("unused")`

* Fixes `JavaUtilDate` warns

This commit fix all `JavaUtilDate` warns given by ErrorProne in the `gson/src/test.*` path.

Classes/Methods are annotated with `@SuppressWarnings("JavaUtilDate")` because it's not possible use differente Date API.

* Fixes `EqualsGetClass` warns

This commit fix all `EqualsGetClass` warns given by ErrorProne in the `gson/src/test.*` path.

I have rewrite the `equals()` methods to use `instanceof`

* Replaces pattern matching for instanceof with casts

* Fixes `JdkObsolete` warns

This commit fix all `JdkObsolete` warns given by ErrorProne in the `gson/src/test.*` path.

In some cases I have replaced the obsolete JDK classes with the newest alternatives.  In other cases, I have added the `@SuppressWarnings("JdkObsolete")`

* Fixes `ClassCanBeStatic` warns

This commit fix all `ClassCanBeStatic` warns given by ErrorProne in the `gson/src/test.*` path.

I have added the `static` keyword, or I have added `@SuppressWarnings("ClassCanBeStatic")`

* Fixes `UndefinedEquals` warns

This commit fix all `UndefinedEquals` warns given by ErrorProne in the `gson/src/test.*` path.

I have added `@SuppressWarnings("UndefinedEquals")` or fixed the asserts

Note: In this commit I have also renamed a test from `testRawCollectionDeserializationNotAlllowed` to `testRawCollectionDeserializationNotAllowed`

* Fixes `GetClassOnEnum` warns

This commit fix all `GetClassOnEnum` warns given by ErrorProne in the `gson/src/test.*` path.

I have replaced the `.getClass()` with `.getDeclaringClass()`

* Fixes `ImmutableEnumChecker` warns

This commit fix all `ImmutableEnumChecker` warns given by ErrorProne in the `gson/src/test.*` path.

I have added the `final` keyword, or I have added the `@SuppressWarnings("ImmutableEnumChecker")` annotation

* Fixes `StaticAssignmentOfThrowable` warns

This commit fix all `StaticAssignmentOfThrowable` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `AssertionFailureIgnored` warns

This commit fix all `AssertionFailureIgnored` warns given by ErrorProne in the `gson/src/test.*` path.

I have added the `@SuppressWarnings("AssertionFailureIgnored")` annotation

* Fixes `ModifiedButNotUsed` warns

This commit fix all `ModifiedButNotUsed` warns given by ErrorProne in the `gson/src/test.*` path.

I have added the `@SuppressWarnings("ModifiedButNotUsed")` annotation

* Fixes `MissingSummary` warns

This commit fix all `MissingSummary` warns given by ErrorProne in the `gson/src/test.*` path.

I have remove the Javadoc `@author`

* Fixes `FloatingPointLiteralPrecision` warns

This commit fix all `FloatingPointLiteralPrecision` warns given by ErrorProne in the `gson/src/test.*` path.

I have added the `@SuppressWarnings("FloatingPointLiteralPrecision")` annotation

* Fixes `StringSplitter` warns

This commit fix all `StringSplitter` warns given by ErrorProne in the `gson/src/test.*` path.

I have replaced the `String.split(...)` with `Splitter`

* Fixes `EmptyCatch` warns

This commit fix all `EmptyCatch` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `UnicodeEscape` warns

This commit fix all `UnicodeEscape` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `EmptyBlockTag` warns

This commit fix all `EmptyBlockTag` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `LongFloatConversion` warns

This commit fix all `LongFloatConversion` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `LongDoubleConversion` warns

This commit fix all `LongDoubleConversion` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `TruthAssertExpected` warns

This commit fix all `TruthAssertExpected` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `UnusedMethod` warns

This commit fix all `UnusedMethod` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `UnusedTypeParameter` warns

This commit fix all `UnusedTypeParameter` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `CatchFail` warns

This commit fix all `CatchFail` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `MathAbsoluteNegative` warns

This commit fix all `MathAbsoluteNegative` warns given by ErrorProne in the `gson/src/test.*` path.

* Fixes `LoopOverCharArray` warns

This commit fix all `LoopOverCharArray` warns given by ErrorProne in the `gson/src/test.*` path.

`toCharArray` allocates a new array, using `charAt` is more efficient

* Fixes `HidingField` warns

This commit fix all `HidingField` warns given by ErrorProne in the `gson/src/test.*` path.

* Implements code review feedback

* Implements code review feedback

This commit implements some other code review feedback

* Enable ErrorProne in `extra`

Thi commit removes the `.*extras/src/test.*` path from the `-XepExcludedPaths` parameter of ErrorProne.

* Fix the `JavaUtilDate` warns

This commit fix all `JavaUtilDate` warns given by ErrorProne in the `extras/src/test.*` path.

* Implements code review feedback

* Removes redundant new-line

* Implements code review feedback

* Adds `JDK11` to run test with `--release 11`

* Revert "Adds `JDK11` to run test with `--release 11`"

This reverts commit a7cca386098ae847a10a31c09c3ab9b11eee5920.
2023-03-01 14:23:27 -08:00