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

Earthquake notification system #87

Open
renatgalimov opened this issue May 10, 2023 · 0 comments
Open

Earthquake notification system #87

renatgalimov opened this issue May 10, 2023 · 0 comments

Comments

@renatgalimov
Copy link
Contributor

renatgalimov commented May 10, 2023

Task: Implement Earthquake Notification System

Project Overview

Implement an earthquake notification system into the existing app. The system should scan for earthquake notifications, extract relevant data (magnitude and coordinates), and update screen content accordingly.

Task Description

  • Develop a service to scan for earthquake notifications from a specified source (website parsing or atom feed subscription).
  • Extract the magnitude and coordinates (latitude and longitude) of each earthquake notification.
  • Utilize the app's API (GET /screens/) to retrieve information about all screens.
  • Filter screens based on proximity to the earthquake's location:
    • Magnitude 2.0+: Within 100 km
    • Magnitude 3.0+: Within 200 km
    • Magnitude 4.0+: Within 300 km
    • Magnitude 5.0+: Within 400 km
    • Magnitude 6.0+: Within 500 km
    • Magnitude 7.0+: Within 600 km
    • Magnitude 8.0+: Within 1000 km
    • Magnitude 9.0+: Within 1500 km
  • Create a playlist for each screen within the defined proximity:
    • Set playlist priority to 1.
    • Add a predicate to play content for a specific duration based on the earthquake's magnitude:
      • Magnitude 2.0+: 2 minutes
      • Magnitude 3.0+: 3 minutes
      • Magnitude 4.0+: 5 minutes
      • Magnitude 5.0+: 10 minutes
    • Include metadata in the playlist indicating the time of expiration.
  • After 10 minutes, retrieve all playlists and delete those that have expired.

Please note that this is a draft task description, and additional details may be required for a complete implementation.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant