square / square/wire

Pretty print classes

Open
#1,138 0 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Kotlin
Stars
4.4k
Forks
627
Avg merge
3d 15m
Merged PRs (30d)
20

Description

I just switched over from the java protobuf libraries to wire with the kotlin generation and so far everything is really great. The one thing that would be nice to have is if the toString method coul "pretty print" the proto class similar to how the java library does it, i.e. with newlines and indentation. Right now it makes it really difficult to see the contents of a proto if I just quickly want to debug it.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Locate the Kotlin-generated proto class toString entry point and compare its output with the Java protobuf library's pretty-print behavior. Done means a proto's string representation uses readable newlines and indentation for quick debugging.

Written by the indexing model from the issue text.

Assessment

Tech stack
kotlin
Domain
backend-api-design
Issue type
Feature
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.