Implement minimum length for passwords in account creation#4353
Implement minimum length for passwords in account creation#4353akolson merged 12 commits intolearningequality:unstablefrom
Conversation
There was a problem hiding this comment.
Hi @cerdo03! Generally the code looks good and works as expected, thanks. However it appears that one of the scenarios specified on the issue will fail
.....In development mode, the password
ashould still work.
@bjester will clarify on this.
Also, noting that there are a few failing tests that will need fixing before a merge.
contentcuration/contentcuration/frontend/accounts/pages/Create.vue
Outdated
Show resolved
Hide resolved
contentcuration/contentcuration/frontend/accounts/pages/Create.vue
Outdated
Show resolved
Hide resolved
….vue Co-authored-by: Blaine Jester <blainesworld@gmail.com>
bjester
left a comment
There was a problem hiding this comment.
I see some print statements and a lot of commented code.
|
Hello @cerdo03, are you still planning to follow-up here or would it be better to close the pull request? |
|
@cerdo03 Thank you for taking this on. You got it most of the way there, and I wrapped it up. Some of the backend code was quite confusing in how it worked. |
| }, | ||
| usageRules() { | ||
| return [() => (this.form.uses.length ? true : this.$tr('fieldRequiredMessage'))]; | ||
| /* eslint-disable-next-line kolibri/vue-no-undefined-string-uses */ |
There was a problem hiding this comment.
I think this is nolonger necessary as fieldRequired exists. There's a few other places to clean this up too.
There was a problem hiding this comment.
Unfortunately, this is required. The linting rule does not properly understand this is an external translator
|
Hi @cerdo03! Are you still interested in contributing to this pr, or we should reassign it? |
My comment there was a bit ambiguous. I meant that it should still work for login. That should still be the case |
akolson
left a comment
There was a problem hiding this comment.
@AlexVelezLl adding a little blocker so that the issue here can be address too!
@akolson I just tested this and the |
There was a problem hiding this comment.
Approving this after a chat with Blaine. The context of this was based on how historical data should be handled, and the pr addresses this. Thanks again @AlexVelezLl for finishing this off!
Summary
Description of the change(s) you made
Fixes #4142
I have implemented password length validation on password1 field. Password should be at least 8 characters long otherwise it would throw an error that "Password should be atleast 8 characters long".
Manual verification steps performed
Comments
Does the validation need to implemented on backend as well?
Contributor's Checklist
PR process:
CHANGELOGlabel been added to this PR. Note: items with this label will be added to the CHANGELOG at a later timedocslabel has been added if this introduces a change that needs to be updated in the user docs?requirements.txtfiles also included in this PRStudio-specifc:
notranslateclass been added to elements that shouldn't be translated by Google Chrome's automatic translation feature (e.g. icons, user-generated text)pages,components, andlayoutsdirectories as described in the docsTesting:
Reviewer's Checklist
This section is for reviewers to fill out.
yarnandpip)