https://github.com/newt239/ship-notify-public
To notify the update of SHIP
https://github.com/newt239/ship-notify-public
discord-py firebase python3 selenium
Last synced: about 2 months ago
JSON representation
To notify the update of SHIP
- Host: GitHub
- URL: https://github.com/newt239/ship-notify-public
- Owner: newt239
- License: mit
- Created: 2021-01-19T11:45:03.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2022-07-16T08:50:10.000Z (almost 4 years ago)
- Last Synced: 2025-07-04T02:39:27.655Z (12 months ago)
- Topics: discord-py, firebase, python3, selenium
- Language: Python
- Homepage:
- Size: 24.5 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# SHIP-notify
## 概要
[SHIP](https://ship.sakae-higashi.jp/)に新しいファイルが投稿された際に通知するシステム。
PaaSとしてHerokuを使用。Discord.pyの@tasks.loopで600秒毎に現在時間を確認し、予め設定していた時間であればSHIPやその他このシステムで更新を取得しているプラットフォームへAPIリクエストやスクレイピングを行い、データベースと差があれば更新し各媒体での通知を行う。
SHIPのスクレイピングにはseleniumを使用。中高それぞれの「連絡事項」「学習教材」「学校通信」のページを1日2~5回程度取得している。データベースに保存されていないものが見つかればそのリンクをクリックし、説明文やファイルのダウンロード&SHIP-notify側のデータベースへのアップロードを行う。
データベースはFirebaseのFirestoreとStrageを使用。ファイルの保存に関しては無料枠の容量で抑えるため中学のページのものは保存を行っていない。
## その他備考
### webDriver バージョン設定
環境変数 CHROMEDRIVER_VERSION に[ここ](https://chromedriver.chromium.org/downloads)に記載されているバージョンをセットする。
現在のバージョンは99.0.4844.51