{@thread.name}
wintermeyer:
https://github.com/team-alembic/ash_authentication_phoenix says “This is beta software. Please don’t use it without talking to us!”. I did use it without talking to you and here we are. 😉
I followed the installation manual for a Phoenix application. When I try to start the server with mix phx.server
I’ll get the error message FeriendatenWeb.AuthController.init/1 is undefined (module FeriendatenWeb.AuthController is not available or is yet to be defined)`` I've never created an
AuthController` because the installation manual didn’t say so. Is there a step by step tutorial how to start with a vanilla Phoenix application?
axelb:
Hi <@1066033323467612262> , you must indeed create an AuthController. You can check out my auth example, where I mention this error and potential other problems while setting up AshAuthentication.Phoenix: https://github.com/axelbdt/ash_authentication_phoenix_example
ZachDaniel:
TBH that beta warning should be removed
ZachDaniel:
I removed it from ash authentication
ZachDaniel:
Didn’t realize there was one there.
ZachDaniel:
We definitely need to rectify this issue. Because everyone seems to get to this point. But in the guide we say to create an auth controller: https://ash-hq.org/docs/guides/ash_authentication/3.7.3/tutorials/integrating-ash-authentication-and-phoenix#ashauthentication-phoenix-controller
ZachDaniel:
So I’m not sure what’s going on 😂
wintermeyer:
Is there a reason why https://github.com/team-alembic/ash_authentication_phoenix and https://ash-hq.org/docs/guides/ash_authentication/3.7.3/tutorials/integrating-ash-authentication-and-phoenix#ashauthentication-phoenix-controller exist in parallel? I searched for the first one but didn’t even expect that there was an other one.
wintermeyer:
With the first URL I mean the README which gets automatically displayed by GitHub.
wintermeyer:
https://ash-hq.org/docs/guides/ash_authentication/3.7.3/tutorials/integrating-ash-authentication-and-phoenix#ashauthentication-phoenix-controller
says
ash_authentication_phoenix comes with a generator which creates a Phoenix.Controller by way of a use macro.
How can I use that generator? What’s its name?
wintermeyer:
I have an understanding issue language wise with the following sentences: “If you haven’t already, read Getting Started with Ash Authentication . This provides a good primer on creating the required resources to use Ash Authentication with your Phoenix app.”
Does this mean? a) You must go through that other document and repeat all steps in it before doing the steps on this page? b) It helps to understand the basics of the other document but we will show all needed steps here too?
ZachDaniel:
We should remove the getting started steps from readme and just point it at the tutorial.
ZachDaniel:
And yes you need to go through the other one first
ZachDaniel:
We can update the wording
ZachDaniel:
The generator it refers to is the “use” block at the top of the controller. Will change that wording as well
ZachDaniel:
I think perhaps this has been a source of confusion for people and I can only assume people must be going through the steps on the readme and not the steps on the tutorial, so hopefully removing that fixes the experience
wintermeyer:
I created a bug report related to this. https://github.com/ash-project/ash/issues/496