-
Notifications
You must be signed in to change notification settings - Fork 52
fix: event backend and frontend creation #329
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
fix: event backend and frontend creation #329
Conversation
Codecov Report
@@ Coverage Diff @@
## develop #329 +/- ##
===========================================
- Coverage 98.05% 98.02% -0.04%
===========================================
Files 73 73
Lines 3194 3195 +1
===========================================
Hits 3132 3132
- Misses 62 63 +1
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! :)
app/internal/event.py
Outdated
logging.exception( | ||
f"{invited_email} is not a valid email address", | ||
) | ||
continue |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Probably shouldn't use continue or break.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not my code.
I added the if not invited from form as this was producing an error for empty "invitees" field
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
(so I am not sure what the effect will be, need to see who wrote this originally)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
changed this a bit. to guard clause as Yam asked + instead of continue used - try, except, else
<textarea id="say" name="description" placeholder="Description"></textarea> | ||
<div class="form_row"> | ||
<label for="vc_link">VC link: </label> | ||
<input type="text" id="vc_link" name="vc_link" placeholder="VC URL"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use dashes in HTML ids: vc-link instead of vc_link.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is really problematic.
I've looked this through and though you are right this is a problem it exists all over the project in different tags and affects many many files and not related to the purpose of this PR (fixing create event).
Maybe it's necessary to open a new PR to fix this throughout the project . @yammesicka What do you think?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great work! Please just use guard instead of the long if/else in get_invited_emails
app/internal/event.py
Outdated
continue | ||
invited_emails.append(invited_email) | ||
if not invited_from_form: | ||
invited_emails.append("") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return [""]
instead, and unindent the else
clause
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done :) (I used try, except else inside the for loop)
fix overrided merges-
location and vc separation
invited email
fix invited emails error when empty
fix vc_link references
fix models.py - make vc link nullable