My app is failing the Static Analysis test with the following error:
All authenticated channels must use the Request for Information (getUserData) API call to obtain a user’s email address during the sign-up or sign-in flow.
Originally I was trying to use:
GetPartialUserData("email", {context: "signin"})
Which works great (it’s actually even more relevant for my case), except that it’s failing the Static Analysis. I tried swapping it out for getUserData() but still no luck. Same error.
The flow when you open the app is:
- main.brs creates and shows the HomeScene.
- HomeScene.xml/.brs starts a task to check if the user is signed in, and if not, presents the:
- EmailSignInScreen.xml/.brs which runs the task that includes the getUserData() command.
So if you’re not signed in, it’s a direct path from launch to getUserData() without user interaction, yet I’m still failing the Static Analysis test.
I’ve already read over the pertinent information in the following pages:
- https://developer.roku.com/docs/developer-program/roku-pay/implementation/overview.md
- https://developer.roku.com/docs/developer-program/roku-pay/signin-best-practices.md (specifically states that the RFI screen does not have to be the first screen)
- https://developer.roku.com/docs/references/brightscript/interfaces/ifchannelstore.md
But I still have no clue why it’s failing.
How can I implement this correctly to pass the test?
