anitab-org / mentorship-android

Mentorship System is an application that matches women in tech to mentor each other, on career development, through 1:1 relations during a certain period of time. This is the Android application of this project.
https://github.com/anitab-org/mentorship-android/raw/apk/app-debug.apk
GNU General Public License v3.0
167 stars 379 forks source link

Improvement in responses provided to user #1137

Closed Ankit-akumar closed 3 years ago

Ankit-akumar commented 3 years ago

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

I have just started exploring this project and was testing the apk provided in the User Interface design. I was trying to sign up for the app and started giving some random/invalid inputs. I felt that how the user is notified about the mistakes he/she did can be improved.

Describe the solution you'd like

For example in the provided screenshot, instead of just telling the user "Your username is invalid" the user should be notified of the exact reason for that like "Username should not contain whitespaces or blanks".

Additional context

ScreenshotIssueMentorshipAndroid

The change is small but would make the life of a naive user much easy :-)

epicadk commented 3 years ago

Thanks. We should add validations on the fornt end as well. Would you like to work on this?

Ankit-akumar commented 3 years ago

Yeah sure that would be great. I believe I would have to alter the validateDetails method accordingly.

Ankit-akumar commented 3 years ago

@epicadk These are the rules I have implemented -> 1) The username should consist of 6 to 30 characters inclusive. 2) The username can only contain alphanumeric characters and underscores (_) Anything else?

epicadk commented 3 years ago

You can find the server side validation here. Please try to match them.

Ankit-akumar commented 3 years ago

The max and min length of any field is not mentioned there. Could you please verify once?

epicadk commented 3 years ago

I think you can find them there https://github.com/anitab-org/mentorship-backend/tree/d9dcb53da75583b3693b2e917db1ab8c54576a46/app/api/validations

Ankit-akumar commented 3 years ago

I have made the changes as per the links you provided. And as said in the readme I ran the tests. On testing, I saw some test cases are failing. But I don't think this has anything to do with the changes I made (these tests were already failing before I made the changes). Moreover, the build also fails because of a lot of deprecation warnings. Shall I open the PR?

epicadk commented 3 years ago

Yup open the pr. We are looking into those.

Ankit-akumar commented 3 years ago

hey, @epicadk I have opened the PR for the same. Please review this