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

ListValue is not iterable #636

Open
powellnorma opened this issue Oct 26, 2024 · 0 comments
Open

ListValue is not iterable #636

powellnorma opened this issue Oct 26, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@powellnorma
Copy link

Summary

ListValue is not iterable

What is the feature request for?

The core library

The Problem

With official protobuf_pb2, you can do:

args = ListValue()
args.extend([1,2,3])
some_function(*args)

But with betterproto this doesn't work currently

class ListValue(betterproto.Message):

The Ideal Solution

Add some wrapper methods (extend, iter, ..)

The Current Solution

Always use .value

@powellnorma powellnorma added the enhancement New feature or request label Oct 26, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants
@powellnorma and others