cc-archive / list

The List powered by Creative Commons allows people to contribute to the public commons by taking photographs of the world around them and sharing these images with the world.
GNU General Public License v3.0
48 stars 29 forks source link

"I Already Have An Account" Button Press Crashes #305

Closed rheaplex closed 9 years ago

rheaplex commented 9 years ago

List: 4.0 debug

Android: 5.1.1, Nexus 6

Steps to reproduce: Open app, on first screen select "I already have an account".

Expected result: User should be taken to CCID login.

Actual result: "Oops! The List has crashed" toast, then "Unfortunately The List has stopped" system alert.

rheaplex commented 9 years ago

Having entered The List via "I'm new" and logging in via the sidebar menu "Log In" option, this now works.

perpetuatingcuriosity commented 9 years ago

Hi Rob, looks like I the last API I exported still included a versionName 3.0.1. Can you confirm this is the new apk sent out this morning? If yes, can we call this 4.0 debug for now?

Also: are you getting these errors on the staging server with the Users table imported from the live server?

rheaplex commented 9 years ago

This is the apk from this morning, I've updated the issues to reflect this.

rheaplex commented 9 years ago

We didn't have the Users moved over, I've now copied them to staging.

This doesn't seem to have affected the issues. Forgive my ignorance but does the debug apk point to staging or do I need to do something to set that up? Thanks.

perpetuatingcuriosity commented 9 years ago

The newest apk from yesterday morning points to the staging server. Taking a look now. Meanwhile can you confirm whether the new anonymous user code is working for you on the backend if you curl?

There are three main scenarios it covers:

  1. creating an anonymous user using the login endpoint --> logging in and converting an anonymous user to a new full user (not a user previously existing in the db)
  2. creating an anonymous user using the login endpoint --> logging in as a previously existing user (already in the db)**
  3. logging in as a previous user

When I was testing, during each scenario and added list items and categories to the user before and after logging in.

**Particularly important in scenario 2 to make sure anonymous user items are being converted to the previously existing user once logged in.

rheaplex commented 9 years ago

app-debug_15_07_22.apk logs in correctly with "I already have an account".

rheaplex commented 9 years ago

Staging is running feat-anonusers .

rheaplex commented 9 years ago
curl --include --data 'username=&password=' https://staging-thelist.creativecommons.org/api/users/login

gives HTTP 200 and:

{"skey":"a5c52ddb71d71bc4f51b2aacfba6f2b0","userid":"340","email":"785FCE8D-730D-46B3-8F5B-03393EDA925A"}
rheaplex commented 9 years ago
curl --include --data 'username=785FCE8D-730D-46B3-8F5B-03393EDA925A&password=' https://staging-thelist.creativecommons.org/api/users/login

gives HTTP 200 and:

{"skey":"a5c52ddb71d71bc4f51b2aacfba6f2b0","userid":"340","email":"785FCE8D-730D-46B3-8F5B-03393EDA925A"}
rheaplex commented 9 years ago

We need a better whitelisting system for x.php on login.cc.org .

rheaplex commented 9 years ago

OK that seems to be working.