2

I'll describe my real life problem to provide context for my question.

I'm a legal technician who happens to know how to code; I started with VBA and VB.NET years ago, and since my organization benefits from things I make (mostly because they get them for free), I had to delve deeper and deeper in new languages and tools. I've been happily deploying some PHP/Symfony solutions in our intranet, with interfaces relying mostly on jQuery and Bootstrap. They impressed some of my superiors, who also know something about technology and programming, but now they want more.

Now they decided we should implement a decoupled solution based on Django Rest framework in the backend, and Angular 8 in the frontend. I hurried to learn Django and Python and my backend project seems to work, but I'm struggling with Angular, and I'm stuck with a specific problem.

The question I ask here for you guys is this: where and how I should ask help for implementing an authentication system, because I'm afraid the good pals in SO will shun me for asking for a ready solution. That's why I came here on meta, because I believe here you will forgive me if my question is silly. I don't want another SO user to work for me, I just want to know whether I could post a question asking for guidance to implement, as quick as possible, a solution for this:

  1. I have to use Azure AD to authenticate users with Microsoft accounts.
  2. I successfuly followed MS tutorials for Azure authentication in Django and in Angular, and was able to consume MS-Graph services from both frameworks, and store the token Azure uses for authentication.
  3. Now I don't know how to connect both things, so that users can authenticate once and then, based on that authentication, I can clear them access to the REST API which will contain also data stored in our local MySQL database.
  4. If I implement the authentication in frontend (Angular), I don't know how I can make the backend validate this authentication and set a clearance flag in the session.
  5. If I implement the authentication in backend (Django), I don't know how I can make get the authentication status, so that it can selectively show or hide parts of the interface.

My question here on meta is: could I post such a question on Stack Overflow, or that would be preposterous?

Thanks for your patience.

EDIT: As my question was tagged as possibly duplicated, I followed the link for the possible answer and, as much as they belong to the same discussion (i.e. excessive broadness of a question), I guess my post had unduplicated details on why a question would be considered to be too broad, and the answer already offered here gives useful insights on how breaking down such a question in "presentable" questions on Stack Overflow. So I believe it is harmless and perhaps useful to others, to leave it here as it is.

3
  • 1
    That wouldn't work in a single question, it were too broad. You need to cut your issue into smaller problem, like you did with that list and ask specific question for each smaller piece.
    – Tom
    Commented Nov 5, 2019 at 23:37
  • No, you can't. Sorry about that.
    – TGrif
    Commented Nov 5, 2019 at 23:41
  • Thanks, I'll try to do that. But I alsoo need to know which approach (4 or 5) is more appropriate. Do you think I should ask that first?
    – VBobCat
    Commented Nov 5, 2019 at 23:41

1 Answer 1

5

I'm afraid the good pals in SO will shun me for asking for a ready solution.

You shouldn't be; this is silly. (Not saying that it doesn't happen, but when it does, it's silly, so you shouldn't be overly concerned with it.)

When people complain about questions that ask for a ready solution, they are really complaining about one of two problems:

  1. A question that is inherently too broad—e.g., How do I build Facebook?

  2. A question that does not contain enough background information to sufficiently contextualize it, thus making it too broad. (These are the type of questions where people commonly want to ask, "What have you tried?")

So those are the two problems that you need to avoid. I think you're on the right track with the background information you've provided in this question. However, I would suggest that you also provide sample code illustrating what you are trying to do, ideally in the form of a minimal, reproducible example.

Asking about both Angular and Django implementations in the same question would be a bad idea, because that's instantly too broad. If you want to ask about both, do it as two separate questions.

But, "How do I make the backend perform authentication validation and set a clearance flag in the session?", when asking along with additional supporting context, would be a valid Stack Overflow question.

However, don't ask for someone to build/implement/describe an authentication system. That is an example of problem #1: it is inherently too broad.

For architecture-style questions like "Should I implement authentication in the frontend or backend?", you might be able to ask on Software Engineering, but please read their Help Center to determine whether your question is actually on-topic there. Here is an example of the sort of frontend/backend architecture question that you might ask on Software Engineering. I would also recommend reviewing the FAQ explaining the difference between Stack Overflow and Software Engineering.

6
  • Thank you, Cody. I'll do my best to solve as much of my problem by myself and post valid, adequate questions on StackExchange forums when I need to. Sometimes I feel I just don't have a good way to express myself, which maybe comes from me not being a professional developer and English not being my native language. But I'll try my best. Your answer was very helpful.
    – VBobCat
    Commented Nov 6, 2019 at 0:30
  • 4
    @VBobCat The key thing to remember is, try and break your task up into smaller chunks, and then ask questions about those things. If you have absolutely no idea where to begin, then unfortunately Stack Exchange sites aren't really the right place for you to ask a question. But if you start down a path and get stuck, then there's nothing wrong with asking a question about that. Don't worry too much about your English skills: I had no problem understanding your question here.
    – Cody Gray Mod
    Commented Nov 6, 2019 at 0:32
  • 1
    there is a FAQ on SE meta specifically focused on these matters: What goes on Software Engineering (previously known as Programmers)? A guide for Stack Overflow. Wonder if you forgot about it or maybe intentionally omitted for some reason
    – gnat
    Commented Nov 6, 2019 at 8:54
  • There also the subject of duplicates - a (very) similar question may already have been asked on Stack Overflow (18,475,792 questions and counting). Perhaps include something to this effect? Commented Nov 6, 2019 at 15:26
  • 1
    There is no conspiracy to avoid linking to that FAQ, @gnat. Not everyone has the encyclopedic knowledge of relevant links that you do. If I'm honest, the omission was more because I was lazy and didn't feel like going to search for all relevant prior discussion. Answers on this site are collaboratively edited for a reason. If there's something that can be improved, please feel free to do so, both in my answers and elsewhere. But...as the top two editors on Meta, you and Peter both know that already.
    – Cody Gray Mod
    Commented Nov 6, 2019 at 19:00
  • 1
    @Peter See comment above. If you think there's a way to improve an answer, feel free to edit it in. I wasn't trying to create an exhaustive list of question-asking tips here, though, so I didn't consider mentioning searching for duplicates.
    – Cody Gray Mod
    Commented Nov 6, 2019 at 19:02

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