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’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: send alert image with telegram message, if requested #279

Open
wants to merge 14 commits into
base: main
Choose a base branch
from

Conversation

blenzi
Copy link
Contributor

@blenzi blenzi commented Aug 11, 2023

This PR adds the possibility to send the alert image together with a telegram message, if requested

  • add boolean field send_image to recipient table
  • add int field media_id to notification table
  • add and use python-telegram-bot dependency (negligible increase in docker image size)

Bruno Lenzi added 3 commits August 11, 2023 18:42
- Dockerfile-dev: image FROM pyronear/pyro-api:python3.8-alpine3.10
- add boolean field send_message to recipient table
- add int field media_id to notification table
@ghost
Copy link

ghost commented Aug 11, 2023

Nice of you to open a PR 🙏
When you're ready and want to get it reviewed, post a comment in this Pull Request with this message: /quack review

@codecov
Copy link

codecov bot commented Aug 11, 2023

Codecov Report

Attention: Patch coverage is 92.59259% with 2 lines in your changes are missing coverage. Please review.

Project coverage is 94.31%. Comparing base (767be30) to head (ecb101a).

Files Patch % Lines
src/app/api/endpoints/media.py 33.33% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #279      +/-   ##
==========================================
- Coverage   94.54%   94.31%   -0.23%     
==========================================
  Files          63       66       +3     
  Lines        1594     1690      +96     
==========================================
+ Hits         1507     1594      +87     
- Misses         87       96       +9     
Flag Coverage Δ
client 90.58% <ø> (?)
unittests 94.51% <92.59%> (-0.03%) ⬇️

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

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@blenzi blenzi requested a review from a team August 12, 2023 09:01
@@ -1,4 +1,4 @@
FROM pyroapi:python3.8-alpine3.10
FROM pyronear/pyro-api:python3.8-alpine3.10
Copy link
Member

Choose a reason for hiding this comment

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

@blenzi your are changing this in severals PR it should be done once in a PR I guess

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Thanks @MateoLostanlen. Now that #281 was merged, this will be part of main

Bruno Lenzi added 3 commits December 5, 2023 16:24
# Conflicts:
#	poetry.lock
#	pyproject.toml
#	src/Dockerfile-dev
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants