-6

I asked this question on Stack Overflow and it was closed for being "opinion-based":

gRPC endpoint that sends initial data and afterwards stream of data

I formulated the question like this:

  1. State a clear goal of what I want to achieve.
  2. Present two workarounds that do not really do what I want.
  3. Ask if there is a solution to the goal.

What could I have done differently in formulating the question to avoid closing? Why is this an opinion based question?

4
  • 8
    The definition of "clean" is already hugely opinionated. But probably what made people go "bang, bang bang bang!" is that you have two very visible options listed in the question. Which one to pick? -> opinion.
    – Gimby
    Feb 3 at 10:33
  • 4
    Can't speak for any voter, but this may have been caused by the subjectivity of what makes a solution "clean". The presence of two options could have lured some into thinking that you were specifically asking "which one is better", but this is pure speculation. The way I see it, the question amounts to asking for assistance in making software design decisions, which have shaky grounds for SO. meta.stackoverflow.com/questions/252139/… meta.stackoverflow.com/questions/281184/…
    – E_net4
    Feb 3 at 10:37
  • I just provided the two options, such that people can see that I already thought that far and do not need to propose them themselves, because they are both bad. Feb 3 at 11:00
  • 4
    @TadeoHepperle I have to make clear that there is a big difference between what you intend and what you present. Even if you have the best intentions and have no intention at all to ask for opinions, if you write a question in a way that reads opinionated, you make your life difficult. So an example such as this is very telling, because you put two options exceptionally visible for everyone to see by applying headings even to draw eyes to it. That is probably worse than putting them in a bullet list. If it requires people to have to reason why something is not opinionated, you need to rewrite.
    – Gimby
    Feb 3 at 14:10

1 Answer 1

20

I have two options, which one to pick and/or does an even better option exist?

is an opinion based question, specially if you don't provide any objective criteria the options (or any option) could be evaluated against. I'm thinking Quality attributes here.

Even with proper criteria the question as asked is still off-topic. I don't see an actual programming problem that needs solving. I do see a software design challenge. You need a white board, not a programmer.

Software Design questions might be on-topic on Software Engineering but check any previous questions already asked and familiarize yourself with the type of questions that are well received there before you cross-post to our sister site. They get very upset when we dump our off-topic stuff on their site.

You argue it is a syntax problem. That is not clear at all from the question.

You state in your question:

service LobbyService {
 rpc OpenLobbyAndListenToPlayerJoins(Empty) returns (LobbyData, >stream PlayerJoin);
}

Unfortunately this is not possible

but then don't expand on why that is not possible. Does a linter/compiler spit out errors? Does an implementation blow up? Something else?

Karl Knechtel adds: I think the question would be better off if it clearly highlights the intended interface and behavior. "Unfortunately this is not possible" - if it were possible, exactly what do you suppose it would do? How does that differ from what the workarounds do?

Instead you offer two Options and then asks us for other solutions. Which reads to me as Options.

Maybe the question is salvageable if you add any syntax errors and/or undesired effects from your preferred solution and then explain that you tried alternatives that do not solve the actual functional requirement. Your question can then ask to solve the syntax problem you face in your preferred way going forward.

Answers to your question either solve your problem or will generate options when your goal can't be reached the way you envisioned.

5
  • "I have two options, which one to pick?" this is not at all what I asked! I said: here are two options that both do NOT do what I want, is there another solution. Feb 3 at 10:59
  • 6
    Still a design problem, which is off-topic
    – rene
    Feb 3 at 11:01
  • 2
    No it's not a design problem. It's a syntax problem. I wanted to know if there is a syntax in gRPC that allows for returning both, a stream and a single response as a tuple. Feb 3 at 11:04
  • 2
    @TadeoHepperle fair enough, I gave my answer another edit with an alternative option.
    – rene
    Feb 3 at 11:19
  • 7
    I think the question would be better off if it clearly highlights the intended interface and behaviour. "Unfortunately this is not possible" - if it were possible, exactly what do you suppose it would do? How does that differ from what the workarounds do? Feb 3 at 13:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .