Melacast Week 5/6 | 6/25–7/7
It was a busy couple of weeks outside of the project, so I decided to merge these past two week’s progress into one.
At the start of last week, I decided to begin working on the login/registration and profile creation flow of pages since these pages consisted mainly of forms that were really similar to the last flow I finished which allowed listings to be created. Here, I realized that I hadn’t worked with these pages since last summer and needed a refresher. After scanning through the code, I gave the registration flow a test run, and I ran into my first wall after I submitted my info.
The first issue was:
SMTPAuthenticationError at /accounts/signup/
(534, '5.7.14 <https://accounts.google.com/ContinueSignIn?sarp=1&scc=1&plt=AKgnsbvNq\n5.7.14 S3l1pFXENupDa_SdPphNHrnzeLPUOyf6O0l1s31w7h_UARx11P89AxPeeZ6xBi2KeQRjsw\n5.7.14 nvpxZhPVv771W9ljEDyeWnqpqv3_nakuPo36BEl3IlYj9qVujNB5cm0TYFf9LQAxRjFdda\n5.7.14 xh-y5spA9zIQONDsvRRgN3e0DXoIkgxTO3Mu75IaACi-XlvFtFfPBiQ81gUrBZ_PhZsBmh\n5.7.14 ajsSf-flNEmoSydyOTNdmwdB0__8> Please log in via your web browser and\n5.7.14 then try again.\n5.7.14 Learn more at\n5.7.14 https://support.google.com/mail/bin/answer.py?answer=78754 40sm12125121qgi.47 - gsmtp')
Strange, I thought I had the whole email process (delicately) patched together last time.
An initial search revealed that this issue was related to a Google account allowing access from less-secure apps. The “fix” didn’t work, so that set off a chain of spending a couple days trying to understand the Django’s email process better, thinking something was wrong with Gmail and trying to send email with Anymail instead, and then finally looping back to the start.
Turns out, the account I used to send emails from had 2FA enabled, which complicated the whole allowing access feature. So I switched to the actual Melacast account, enabled access there, and then had to visit some obscure link for a captcha. The catch was that both of those last two processes took some time to come into effect which is why the solution didn’t work at first. The whole issue turned into one of those situations that sort of just resolves itself quietly.
Next up, I became convinced of the usefulness of implementing unit and snapshot tests. I was randomly just testing the Dashboard page:
The recommended section up top was supposed to be empty (since no listings were created with Animator roles yet), but instead it was being populated by all existing listings instead. I had no idea what the issue was, so I went to the last resort and added a console.log(“Call #”) to figure out which Axios request was going wrong (Definitely should’ve done this at the start). Turns out, I had messed up the brackets to a conditional, and the resulting GET request was running by default since it didn’t have a conditional to meet.
This process opened my eyes to being more meticulous in adding console logs where they should go, and the importance of having tests to detect this. Since then, I’ve been slowly making progress in implementing Jest going forward.
Other than that, the UI hasn’t presented too much trouble, and I finished with the registration and authentication pages. Currently halfway through the create a profile form also.