at_widgets icon indicating copy to clipboard operation
at_widgets copied to clipboard

Add staging & testing rootDomain support for all validating functions in at_onboarding_flutter package

Open yahu1031 opened this issue 3 years ago • 5 comments

Is your feature request related to a problem? Please describe.

I'm trying to create a custom login screen. And trying to authenticate with

OnboardingService.getInstance().authenticate('@bob🛠', jsonData: atKeysFileData);

I'm running om the local server(vip.ve.atsign.zone). The authentication was failing with ResponseStatus.serverNotReached response cause _checkAtSignServerStatus('@bob🛠') returns ServerStatus.unavailable. This is because, The implementation of the function has AppConstants.rootDomain which is root.atsign.org. This won't let me check my local server atsigns.

Describe the solution you'd like

In the RootEnvironment extension for domain, assign values before returning them. And in case, If users want to have a custom login screen, they don't use any RootEnvironment. In such a case, the functions that use the rootDomain must be passed as an optional parameter.

NOTE:

If this wasn't modified as mentioned, then testing on local servers won't be possible for custom login screens.

yahu1031 avatar Apr 03 '22 07:04 yahu1031

@yahu1031 For now, you can change the rootDomain in AppConstants from at_onboarding_flutter.

AppConstants.rootDomain = "vip.ve.atsign.zone"

Because we will have a new at_onboarding package (which refactors the UI and flow). So I think no need update the current at_onboarding_flutter package for this issue. Please let me know your thoughts. Thank you!

sonle-geekyants avatar Apr 05 '22 09:04 sonle-geekyants

Yes, cool. So this can go under enhancement for that new code then.

yahu1031 avatar Apr 05 '22 10:04 yahu1031

Moving this to "upstream dependency" till the new refactored at_onboarding_flutter package is released.

sarika01 avatar Apr 19 '22 12:04 sarika01

@yahu1031 Please check the latest version of at_onboarding in trunk branch We can pass rootDomain into AtOnboardingConfig when call the function AtOnboarding.onboard...

sonle-geekyants avatar Aug 05 '22 09:08 sonle-geekyants

@sonle-geekyants Lemme check and update this

yahu1031 avatar Aug 07 '22 07:08 yahu1031

Closing as completed

gkc avatar Feb 20 '23 12:02 gkc