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

Support describing nested messages #607

Open
yebrahim opened this issue Nov 9, 2022 · 2 comments
Open

Support describing nested messages #607

yebrahim opened this issue Nov 9, 2022 · 2 comments

Comments

@yebrahim
Copy link

yebrahim commented Nov 9, 2022

Using desc is only useful on top level messages. Also support calling it for nested objects:

myservice@localhost:50051> desc SayHelloRequest
+---------------------+----------------------------+----------------+
|        FIELD        |              TYPE          | REPEATED       |
+---------------------+----------------------------+----------------+
| person              | TYPE_MESSAGE               | false          |
|                     | (Person)                   |                |
+---------------------+----------------------------+----------------+

Should be able to do something like desc Person, or desc com.HelloService.Person.

@ktr0731
Copy link
Owner

ktr0731 commented Nov 13, 2022

Currently, there are no ways to do it, but I think the behavior should be improved.

FYI: in the command-line mode, we can describe all messages such as:

$ evans -r cli desc
api.Example:
service Example {
  rpc SayHello ( .api.SayHelloRequest ) returns ( .api.SayHelloResponse );
}

$ evans -r cli desc api.SayHelloRequest
api.SayHelloRequest:
message SayHelloRequest {
  Person person = 1;
}

$ evans -r cli desc api.Person
api.Person:
message Person {
  // something
}

@yebrahim
Copy link
Author

yeah it'd be real nice if we can do it in the repl, especialy with those long-nested message types. :)

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

No branches or pull requests

2 participants