Skip to content
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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

馃悰 Fix email sending issue missing "From" field #2926

Merged
merged 9 commits into from
Mar 30, 2022

Conversation

GitHK
Copy link
Contributor

@GitHK GitHK commented Mar 29, 2022

What do these changes do?

The "From" field was not found during the sending of the email. Turns out the wrong parameter to parse the pedantic model was used.
This fixes the issue and allows for emails to get sent once again.

Extra:

  • Fixes warnings with a test case in director-v2

Related issue/s

How to test

Checklist

@GitHK GitHK self-assigned this Mar 29, 2022
@GitHK GitHK requested a review from mrnicegyu11 March 29, 2022 14:20
@codecov
Copy link

codecov bot commented Mar 29, 2022

Codecov Report

Merging #2926 (6fab6cd) into master (be2df27) will increase coverage by 1.2%.
The diff coverage is 83.3%.

Impacted file tree graph

@@           Coverage Diff            @@
##           master   #2926     +/-   ##
========================================
+ Coverage    78.4%   79.6%   +1.2%     
========================================
  Files         677     677             
  Lines       28230   28231      +1     
  Branches     3282    3282             
========================================
+ Hits        22136   22479    +343     
+ Misses       5346    4992    -354     
- Partials      748     760     +12     
Flag Coverage 螖
integrationtests 65.7% <83.3%> (+4.0%) 猬嗭笍
unittests 75.1% <83.3%> (+<0.1%) 猬嗭笍

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage 螖
...erver/src/simcore_service_webserver/login/utils.py 51.6% <0.0%> (-0.6%) 猬囷笍
...rver/src/simcore_service_webserver/login/plugin.py 85.7% <100.0%> (酶)
...er/src/simcore_service_webserver/login/settings.py 100.0% <100.0%> (酶)
...simcore_service_webserver/projects/project_lock.py 94.7% <0.0%> (-5.3%) 猬囷笍
...imcore_service_webserver/garbage_collector_core.py 70.5% <0.0%> (-1.0%) 猬囷笍
...ore_service_director_v2/utils/dask_client_utils.py 78.2% <0.0%> (-0.9%) 猬囷笍
.../director/src/simcore_service_director/producer.py 62.7% <0.0%> (+0.6%) 猬嗭笍
...e_service_director_v2/modules/dask_clients_pool.py 93.9% <0.0%> (+1.5%) 猬嗭笍
...rector_v2/modules/comp_scheduler/base_scheduler.py 88.6% <0.0%> (+1.8%) 猬嗭笍
...service_director_v2/api/routes/dynamic_services.py 88.2% <0.0%> (+2.1%) 猬嗭笍
... and 18 more

@GitHK GitHK requested a review from pcrespov March 29, 2022 16:11
Copy link
Member

@sanderegg sanderegg left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

marvelous

@@ -26,7 +26,7 @@ class MockedCalls(BaseModel):
attach: List[Any]


class TestCase(BaseModel):
class Example(BaseModel):
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Example?? really? is there no better name? 馃ぃ

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

true ..

Comment on lines +49 to +50
SMTP_USERNAME: Optional[str] = Field(...)
SMTP_PASSWORD: Optional[SecretStr] = Field(...)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

is the Field(...) really needed?

Copy link
Member

@pcrespov pcrespov Mar 29, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sanderegg yes, this way the field is required, which is what will solve the bug we had.

Check

as a reminder

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, it means that the fields need to be provided even if the provided value is None

@GitHK GitHK merged commit 7fcb113 into ITISFoundation:master Mar 30, 2022
@GitHK GitHK deleted the fix-email-sending-2 branch March 30, 2022 05:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Can't send email
3 participants