Skip to content

Adding support for jsoniter scala#531

Open
jkozlovvski wants to merge 16 commits intomasterfrom
Adding-support-for-jsoniter-scala
Open

Adding support for jsoniter scala#531
jkozlovvski wants to merge 16 commits intomasterfrom
Adding-support-for-jsoniter-scala

Conversation

@jkozlovvski
Copy link
Copy Markdown

No description provided.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR introduces a new kebs-jsoniter module intended to provide automatic jsoniter-scala codec generation for Kebs types across Scala 2.13 and Scala 3, and wires the module into the multi-project build.

Changes:

  • Adds a new jsoniter crossProject, including jsoniter-scala dependencies and aggregation into the root build.
  • Implements jsoniter codec derivation for Kebs types (value classes / instance converters), with Scala 2 & Scala 3 source sets.
  • Adds a jsoniter test suite + version-specific test models; also adds Metals-generated metals.sbt plugin files.

Reviewed changes

Copilot reviewed 17 out of 18 changed files in this pull request and generated 13 comments.

Show a summary per file
File Description
build.sbt Adds jsoniter-scala deps/settings and a new jsoniterSupport crossProject; changes default Scala version and aggregates jsoniter modules.
project/metals.sbt Adds sbt-bloop plugin via Metals-generated file.
project/project/metals.sbt Adds sbt-bloop plugin via Metals-generated file (nested meta-build).
project/project/project/metals.sbt Adds sbt-bloop plugin via Metals-generated file (deeply nested meta-build).
jsoniter/src/main/scala-2/pl/iterators/kebs/jsoniter/KebsJsoniter.scala Scala 2 macro-based codec derivation for Kebs types and fallback derivation.
jsoniter/src/main/scala-3/pl/iterators/kebs/jsoniter/KebsJsoniter.scala Scala 3 inline-based codec derivation, plus snakified/capitalized variants.
jsoniter/src/main/scala/pl/iterators/kebs/jsoniter/package.scala Attempts to expose a package object-based entrypoint for jsoniter support.
jsoniter/src/main/scala/pl/iterators/kebs/jsoniter/enums/package.scala Placeholder (commented) enums package object.
jsoniter/src/main/scala/pl/iterators/kebs/jsoniter/enums/KebsJsoniterEnums.scala Placeholder (commented) enums/value-enums codec implementation.
jsoniter/src/test/scala/pl/iterators/kebs/jsoniter/formats/JsoniterFormatTests.scala Base jsoniter codec tests (flat, DTO, recursive, >22 fields).
jsoniter/src/test/scala/pl/iterators/kebs/jsoniter/formats/JsoniterFormatSnakifiedVariantTests.scala Tests for snake_case variant codec behavior.
jsoniter/src/test/scala/pl/iterators/kebs/jsoniter/formats/JsoniterFormatCapitalizeVariantTests.scala Tests for PascalCase/capitalized variant codec behavior.
jsoniter/src/test/scala-2/pl/iterators/kebs/jsoniter/model/model.scala Scala 2 test model definitions.
jsoniter/src/test/scala-2/pl/iterators/kebs/jsoniter/KebsEnumForTests.scala Scala 2 test helper trait for enumeratum enums.
jsoniter/src/test/scala-2/pl/iterators/kebs/jsoniter/KebsValueEnumForTests.scala Scala 2 test helper trait for enumeratum value enums.
jsoniter/src/test/scala-3/pl/iterators/kebs/jsoniter/model/model.scala Scala 3 test model definitions (Scala 3 enums/value enums).
jsoniter/src/test/scala-3/pl/iterators/kebs/jsoniter/KebsEnumForTests.scala Scala 3 test helper trait for Kebs enums.
jsoniter/src/test/scala-3/pl/iterators/kebs/jsoniter/KebsValueEnumForTests.scala Scala 3 test helper trait for Kebs value enums.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread jsoniter/src/main/scala/pl/iterators/kebs/jsoniter/package.scala Outdated
Comment thread jsoniter/src/main/scala-2/pl/iterators/kebs/jsoniter/KebsJsoniter.scala Outdated
Comment thread jsoniter/src/main/scala/pl/iterators/kebs/jsoniter/enums/KebsJsoniterEnums.scala Outdated
Comment thread project/project/project/metals.sbt
Comment thread project/project/metals.sbt
Comment thread project/metals.sbt Outdated
@jkozlovvski jkozlovvski marked this pull request as ready for review April 13, 2026 07:36
@jkozlovvski jkozlovvski requested a review from Copilot April 13, 2026 07:36
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 21 out of 22 changed files in this pull request and generated 4 comments.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread jsoniter/src/main/scala/pl/iterators/kebs/jsoniter/package.scala Outdated
Comment thread project/metals.sbt Outdated
Comment thread jsoniter/src/main/scala/pl/iterators/kebs/jsoniter/enums/KebsJsoniterEnums.scala Outdated
@@ -0,0 +1,8 @@
// format: off
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not needed

@@ -0,0 +1,8 @@
// format: off
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

not needed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants