Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Olive Testing] Android plugin #211

Closed
cmltaWt0 opened this issue Oct 24, 2022 · 20 comments
Closed

[Olive Testing] Android plugin #211

cmltaWt0 opened this issue Oct 24, 2022 · 20 comments
Labels
bug Report of or fix for something that isn't working as intended help wanted Ready to be picked up by anyone in the community release testing Affects the upcoming release (attention needed)
Milestone

Comments

@cmltaWt0
Copy link

cmltaWt0 commented Oct 24, 2022

Testings env

Login

State: Failed
STR:

  • Click on login link
  • Enter email and password
  • Click login

Screenshot 2022-10-24 at 19 48 04

Registration

State: Failed
Note - user is actually created. Register the same user will give and Existent user error.
STR:

  • Click on register link
  • Fill Full name, Public Name, Email, Password
  • Select Agreement checkbox
  • Submit

Screenshot 2022-10-24 at 20 31 44

Register page

TOS link makrup is broken.

Screenshot 2022-10-24 at 19 46 04

@regisb
Copy link
Contributor

regisb commented Oct 24, 2022

I can confirm that logging in is impossible. I'm getting the following logs from the server:

tutor_local-lms-1                        | 2022-10-24 19:11:17,763 INFO 7 [tracking] [user None] [ip 78.196.96.100] logger.py:41 - {"name": "/oauth2/access_token/", "context": {"user_id": null, "path": "/oauth2/access_token/", "course_id": "", "org_id": "", "enterprise_uuid": ""}, "username": "", "session": "", "ip": "78.196.96.100", "agent": "Dalvik/2.1.0 (Linux; U; Android 12; LE2115 Build/RKQ1.211119.001) Open edx olive Demo/io.overhang.demo.olive/3.1.4", "host": "olive.demo.overhang.io", "referer": "", "accept_language": "", "event": "{\"GET\": {}, \"POST\": {\"grant_type\": [\"password\"], \"client_id\": [\"android\"], \"username\": [\"admin\"], \"password\": \"********\"}}", "time": "2022-10-24T19:11:17.762963+00:00", "event_type": "/oauth2/access_token/", "event_source": "server", "page": null}
tutor_local-caddy-1                      | {"level":"error","ts":1666638677.780014,"logger":"http.log.access.log0","msg":"handled request","request":{"remote_addr":"78.196.96.100:39550","proto":"HTTP/2.0","method":"POST","host":"olive.demo.overhang.io","uri":"/oauth2/access_token/","tls":{"resumed":false,"version":772,"cipher_suite":4865,"proto":"h2","proto_mutual":true,"server_name":"olive.demo.overhang.io"}},"user_id":"","duration":0.033390752,"size":27,"status":401}
tutor_local-lms-1                        | [pid: 7|app: 0|req: 1485/4373] 172.18.0.8 () {44 vars in 918 bytes} [Mon Oct 24 19:11:17 2022] POST /oauth2/access_token/ => generated 27 bytes in 33 msecs (HTTP/1.1 401) 9 headers in 588 bytes (1 switches on core 0)

LMS is replying to POST /oauth2/access_token/ with a 401 Unauthorized error. I have no idea why.

If someone with mobile dev skills reads this, I could use a hand...

@cmltaWt0
Copy link
Author

@regisb Custom Android build using oauth client credentials from https://olive.demo.overhang.io/oauth2/access_token/ works fine (at least Login step). So I suspect incorrect oauth client_id/token being added during the apk build step. Need to review the build process.

@cmltaWt0
Copy link
Author

Tested on the latest deploy/build.
Login works!
image

To be continue...

@cmltaWt0
Copy link
Author

cmltaWt0 commented Nov 7, 2022

Additional testing for Android app

Profile editing

Steps:

  • Set Age on the Account Web page /account (13+ years)
  • On Mobile Open profile
  • Click Edit
  • Change Location
  • Change Spoken Language
  • Add About me
  • Upload Icon image
  • Check changes on Profile (https://apps.olive.demo.overhang.io/profile/u/) and Account /account page

Status: PASS

image

image

image

image

Enrolled course on main screen

Steps:

  • Enroll to a Course on the LMS Dashboard Web page
  • Open Studio, login as a staff user
  • Open the Course Advanced settings
  • Set Mobile course available to true
  • Open Mobile app
  • Login
  • Check that Enrolled Course in available on the main screen

Status: PASS

image

Open enrolled course from the main screen

Steps:

  • Enroll to a Course on the LMS Dashboard Web page
  • Open Studio, login as a staff user
  • Open the Course Advanced settings
  • Set Mobile course available to true
  • Open Mobile app
  • Login
  • Check that Enrolled Course in available on the main screen
  • Open Course by click on it
  • Check the Course Home screen

Status: FAILED
Details: Application crashed

@ghassanmas
Copy link
Member

@cmltaWt0 thanks for the detailed input!.. I was going over the logs of edx-app-android to see if there might be already a fix for the last failed test and I found this openedx-unsupported/edx-app-android/pull/1694 which I think is realted to the last test, if yes then we should add it to #205

@DeanJayMathew
Copy link

Awesome jobs! So @cmltaWt0 I presume we should add all these as new test cases. These will be the first new test cases added to the sheet since testing began. I endeavour to add them tomorrow.

@regisb
Copy link
Contributor

regisb commented Nov 14, 2022

Android app was upgraded to 3.2.2 on the Olive demo server. Can you please run the failed tests again?

@arbrandes arbrandes added this to the Olive.1 milestone Dec 6, 2022
@arbrandes arbrandes moved this from 💡 Incoming to 🏗 In Progress in Build-Test-Release Working Group Dec 6, 2022
@arbrandes
Copy link
Contributor

@cmltaWt0, have you been able to re-run the tests?

@arbrandes arbrandes added the release testing Affects the upcoming release (attention needed) label Dec 6, 2022
@cmltaWt0
Copy link
Author

cmltaWt0 commented Dec 6, 2022

@cmltaWt0, have you been able to re-run the tests?

Sure, will do today.

@arbrandes arbrandes added the bug Report of or fix for something that isn't working as intended label Dec 6, 2022
@cmltaWt0
Copy link
Author

cmltaWt0 commented Dec 6, 2022

Tested the 3.2.2 version on emulator and on real device. It's crashed on login/register step.
Crash report says the following:

java.lang.RuntimeException:
java.lang.InstantiationException: java.lang.Class<org.edx.mobile.util.Config$ApiUrlVersionConfig> has no zero argument constructor at
org.edx.mobile.util.Config.getObjectOrNewInstance(Config.java:783) at
...
...

@regisb could you check the configuration option for the build please?

@cmltaWt0
Copy link
Author

cmltaWt0 commented Dec 6, 2022

If configuration looks good I can try to backport the My Courses screen detached fragment issue for ViewModel fix to olive.master and then we can rebuild from this branch but not from a release tag.

@regisb
Copy link
Contributor

regisb commented Dec 9, 2022

Thanks for testing @cmltaWt0. I have no idea what is going on. Configuration is supposed to be ok, as I didn't change it since the last release. I also observe that the app is crashing, though I don't know why. (I don't even know how to generate a crash report on my phone...) No logs are generated on the server.

You are talking about this PR, right? openedx-unsupported/edx-app-android#1694 It should already be present in the app, as we are running 3.2.2 which was published in October: https://github.com/openedx/edx-app-android/releases/tag/release%2F3.2.2

Any other idea?

EDIT: I downgraded the generated app from 3.2.2 to 3.1.4. With 3.1.4 I am able to login... but then the app crashes on opening the demo course. I need to figure out what happened between those two versions that could cause the crash in v3.2.2.

EDIT: Version 11bb840580df92098717e875c7d68b6a994a9205 (latest commit from the master branch) is also broken. App also crashes after login.

EDIT: for the record, 3.0.2 was the last known version to work (in Nutmeg). I tried it with Olive and it works. So if we can't get 3.2.2 to work we'll have to keep 3.0.2.

@arbrandes
Copy link
Contributor

Release janitor check: what are we doing here, if anything, for Olive.1? We only have a couple of hours.

@regisb
Copy link
Contributor

regisb commented Dec 12, 2022

I downgraded the android plugin to 3.0.2. We'll work later to upgrade to 3.2.2.

@arbrandes arbrandes modified the milestones: Olive.1, Olive.2 Dec 12, 2022
@arbrandes arbrandes moved this from In progress to Backlog in Build-Test-Release Working Group Dec 12, 2022
@arbrandes arbrandes moved this from Backlog to In progress in Build-Test-Release Working Group Dec 12, 2022
@ghassanmas
Copy link
Member

Following our today BTR call, there was a bug that I encournted in different context enrollment is not possible when using the APK.

It would return 400 code, the way to resolve for that was to disable the ProGuard featuer. By commenting the following lines:

https://github.com/openedx/edx-app-android/blob/11bb840580df92098717e875c7d68b6a994a9205/OpenEdXMobile/build.gradle#L501-L508

In particualr I think this commit openedx-unsupported/edx-app-android@7090944 is probably the reason for bug.

@regisb regisb added the help wanted Ready to be picked up by anyone in the community label Jan 3, 2023
@regisb
Copy link
Contributor

regisb commented Jan 3, 2023

I'm a terrible mobile developer and I need help with this issue, so I'll unassign myself. As an acceptance criteria, I'd like someone to open a PR on the tutor-android plugin repo to upgrade the app from 3.0.2 to 3.2.2 (or later). Users should be able to login, register and enroll in courses from the app.

@regisb regisb removed their assignment Jan 3, 2023
@arbrandes arbrandes moved this from In progress to Backlog in Build-Test-Release Working Group Jan 24, 2023
@jalondonot jalondonot modified the milestones: Olive.2, Olive.3 Mar 6, 2023
@jalondonot
Copy link

@cmltaWt0, are you currently working on this? otherwise, let's mark this issue as unassigned to let people know this issue is requiring someone to work on it.

@cmltaWt0
Copy link
Author

cmltaWt0 commented Mar 6, 2023

@jalondonot actually I don't. Was just a reported and tried to help to diagnose the issue.
Let me un-assign myself for now 👍
Maybe later I can pick this up and try it again.

@cmltaWt0 cmltaWt0 removed their assignment Mar 6, 2023
@jalondonot jalondonot removed this from the Olive.3 milestone May 15, 2023
@mariajgrimaldi mariajgrimaldi added this to the Quince.3 milestone Feb 12, 2024
@mariajgrimaldi mariajgrimaldi modified the milestones: Quince.3, Redwood.1 Apr 26, 2024
@mariajgrimaldi
Copy link
Member

@regisb @cmltaWt0: do you folks know if this issue was resolved? If not, do you know someone we could contact to help us with this issue? I don't know anyone who is familiar with the Android app.

@regisb
Copy link
Contributor

regisb commented May 13, 2024

I mean, the android app is really supposed to be working in Quince, so my guess is that yes, this issue is now resolved.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Report of or fix for something that isn't working as intended help wanted Ready to be picked up by anyone in the community release testing Affects the upcoming release (attention needed)
Projects
Development

No branches or pull requests

7 participants