Commit History
-
feat: アプリ上からバグ報告・機能要望を送信しGitHub Issueに自動起票する機能を追加
Ryo_Shimano +1: Claude Sonnet 5「フィードバック」画面(種別・タイトル・内容・任意の報告者名)から送信すると utils/github_issues.create_issue() がGITHUB_TOKENを使ってGitHub Issueを作成する。 内容欄は最低20文字を必須にし、種別ごとの記入例(再現手順/期待動作、または 利用場面/改善案)を表示することで具体的な報告を促す。既知の不具合セクション からも導線を追加。GITHUB_TOKEN未設定時はエラーメッセージを表示して入力内容を 保持する。 Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>57d9b6b
-
テスト: 自動テストスイートを追加、Flask-Sessionの非推奨警告を修正
Ryo_Shimano +1: Claude Sonnet 4.6- tests/ ディレクトリに pytest ベースの単体・結合テスト137件を追加 - test_shift_patterns.py: ShiftPattern のカバー判定・境界値テスト - test_period_fmt.py: 期間ラベルフォーマットテスト - test_constants.py: Enum クラスのランク・ラベルテスト - test_employee.py: Employee モデルのスキル判定テスト - test_schedule_models.py: ShiftRequest/SchedulePeriod テスト - test_auth_routes.py: 認証ルート・セキュリティヘッダーテスト - test_employee_routes.py: 従業員ルートの結合テスト - web_app.py: SESSION_TYPE="filesystem" を非推奨の SESSION_TYPE="cachelib" + SESSION_CACHELIB=FileSystemCache(...) に変更し DeprecationWarning を解消 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>bff9db3 -
⑤ 削除:管理者向け Web Push 通知機能を取り消し
Ryo_Shimano +1: Claude Sonnet 4.6- routes/push.py を削除 - db/database.py: push_subscriptions テーブルの DDL を削除 - db/repositories.py: Push サブスクリプション関連関数を削除 - requirements.txt: pywebpush を削除 - web_app.py: push Blueprint の登録と認証免除を削除 - templates/pwa/sw.js: push / notificationclick イベントハンドラを削除 - templates/settings/index.html: Web Push 設定セクションと JS を削除 - routes/schedule.py: confirm() からの Push 呼び出しを削除 - routes/shifts.py: save() からの Push 呼び出しを削除 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>cd50ca4 -
⑤ ベータ機能:管理者向け Web Push 通知
Ryo_Shimano +1: Claude Sonnet 4.6依存: pywebpush>=2.0.0 を requirements.txt に追加 DB: - db/database.py: push_subscriptions テーブルを追加 - db/repositories.py: get/save/delete_push_subscription 関数を追加 新規 Blueprint: - routes/push.py: VAPID 鍵管理・購読登録・解除・テスト送信エンドポイント GET /push/vapid-public-key — ブラウザが Push 購読に使う公開鍵を返す POST /push/subscribe — 購読情報を DB に保存 POST /push/unsubscribe — 購読を解除 POST /push/send-test — テスト通知を全購読者に送信 内部: _send_push_notification() — 他ルートから呼び出せる共通関数 Push トリガー: - routes/schedule.py: confirm() でシフト確定時に Push 通知を送信 - routes/shifts.py: save() で個人保存時に希望提出通知を送信 フロントエンド: - templates/pwa/sw.js: push / notificationclick イベントハンドラを追加 - templates/settings/index.html: 「管理者向け Web Push 通知(β)」セクションを追加 VAPID 鍵取得 → 通知許可リクエスト → 購読 → 解除 / テスト送信の UI - web_app.py: push Blueprint を登録、push.* エンドポイントを認証免除リストに追加 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>8dcb560
-
PWAをiOS/Android向けに完全対応(Service Worker全体スコープ化、スプラッシュ画面、インストール導線)
- Service Workerを/sw.jsとしてルートスコープで配信し、オフライン時はキャッシュ またはオフラインページにフォールバックするよう強化 - manifest.jsonにid/scope/lang/shortcuts/maskableアイコンを追加 - iOS向けスプラッシュスクリーン(apple-touch-startup-image)と mobile-web-app-capableメタタグを追加 - ホーム画面追加を案内するインストールバナーを追加 (Android: beforeinstallprompt, iOS: 共有メニュー案内) - アイコン/スプラッシュ生成スクリプト(scripts/generate_pwa_assets.py)を追加404ee14 -
CSRF対策(Flask-WTF CSRFProtect)を追加
全POSTフォームにcsrf_tokenを付与し、fetchによるPOST/PUT/PATCH/DELETEには base.htmlでwindow.fetchをパッチして自動でX-CSRFTokenヘッダーを付与する。 CSRFエラー時はJSONリクエストには400、それ以外はflashメッセージ付きで リダイレクトする。長時間開いた画面からの送信もエラーにならないよう WTF_CSRF_TIME_LIMITは無効化。0032c7c
-
OAuth連携やCookieのセキュリティ強化のため、セッション管理とセキュリティヘッダーを設定
48ca7cd -
Web版のバージョン表示にgitコミットハッシュを使用
_version.py未生成(Web版)の場合は.git/HEADから直接コミット ハッシュ短縮形を取得して表示する。デスクトップ版のbuild-N表示は 変更なし。2d155ff -
開発者情報をヘルプページから設定ページへ移動・簡略化
ヘルプページの開発者情報セクション(開発の経緯・アプリのポイント・ 技術スタックなど)を削除し、設定ページ下部に開発者名・バージョン・ 連絡先・バグ報告案内のみのコンパクトなカードとして再構成。 バージョン表示は utils/version.py の APP_VERSION を context processor経由でテンプレートに渡すようにした。34c1f5a
-
バグ修正: #22 #37 #38 #39 #40 #41 #42 #43
- #22: パターン変更時にcustom_start/custom_endが残留する不整合を修正し、既存データもクリーンアップ - #37: SimpleCacheのプロセスローカル性によるキャッシュ無効化漏れを防ぐため、 本番起動をworkers=1+gthreadのマルチスレッド構成に統一(render.yaml/Procfile/CLAUDE.md) - #38: シフト生成の二重起動防止をDBレベルでアトミックに行うtry_start_generation()を追加 - #39: 「希望未提出」判定ロジックをutils/submission.pyに共通化し、 ダッシュボード・生成画面・希望入力画面で一致させる - #40: バックアップ/リストア対象テーブルに不足分(assignment_log等)を追加 - #41: ソルバーP5のFT全面禁止ハード制約にmin_leader要件チェックを追加し、 PTリーダー不足時にPhase1が恒常的にINFEASIBLEになる問題を解消 - #42: ログイン処理をhmac.compare_digestによる定時間比較に変更し、 パスワード長・一致結果のログ出力を削除。SECRET_KEY未設定時の警告を追加 - #43: CSV/Google同期の上書き取込で既存レコードを削除してから保存するよう修正、 確定せず離脱したプレビュー一時ファイルの掃除処理を追加、 reservation設定読み込みのtry/exceptをsafe_int()による安全な変換に統一、 ソルバー警告判定を予約客数による実効最低人数基準に修正 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>e772992 -
fix: リバースプロキシ環境での OAuth2 insecure_transport エラーを回避するため ProxyFix の適用と HTTPS スキームの強制処理を追加
a70779e
-
feat: ホームダッシュボード新設・ナビ再編・ブランドロゴをホームリンク化
- / にダッシュボード新設(今日の出勤状況・期間サマリー・クイックアクション) - スタッフ管理をボトムナビからドロワーに移動(利用頻度が低いため) - ホームをボトムナビとサイドバーの先頭に追加 - デスクトップサイドバーのブランドロゴ・モバイルページヘッダーのアイコンを / へのリンクに変更 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>706e560
-
fix: use flask-session 0.8.0 with correct config (Flask 3.x compatible)
flask-session 0.5.0 is incompatible with Flask 3.x (API changes). Restore 0.8.0 and remove deprecated config keys: - SESSION_PERMANENT (removed in 0.8.0; use session.permanent=True at login) - SESSION_USE_SIGNER (removed in 0.8.0; always signs internally now) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>78566c3
-
fix: repair output_position on startup in web_app.py
Also run the output_position=primary_position sync at startup (same fix as initialize_db, but runs immediately at gunicorn worker start so existing live deployments fix their data without waiting for a full DB reinit). Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>0279903
-
feat: add help page with usage guide and developer info
- /help route with accordion sections for each feature - Covers: スタッフ管理, 希望シフト, 自動生成, シフト表, 客数管理, 設定 - Developer card with email and GitHub link - Anchor links in TOC chips auto-expand the relevant section - Added ヘルプ to desktop sidebar, hamburger drawer, and _in_drawer detection Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>29c5e2e -
fix: logout button hidden due to wrong CSS class on drawer link
The logout <a> had class="drawer a" which applied the .drawer container styles (transform: translateY(100%)) to the link itself, pushing it off-screen. Removed the incorrect class and added onclick=closeDrawer(). Also hide logout links when APP_PASSWORD is not set via context_processor. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>fb89637 -
fix: switch to server-side filesystem sessions (Flask-Session)
Client-side cookie sessions fail silently in multi-worker gunicorn environments behind HuggingFace's reverse proxy. Flask-Session stores session data in /tmp/flask_sessions files; the cookie only holds a signed session ID, which works reliably across workers and proxies. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>32e41b1 -
fix: auth password trim + session version to invalidate stale sessions
- Strip whitespace from APP_PASSWORD and submitted password to prevent comparison failure caused by trailing newline in HuggingFace secrets - Add SESSION_VERSION check so old sessions (set before password was configured) are automatically invalidated on next request Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>88bdacf -
Add shared password authentication
- auth.py: APP_PASSWORD env var + login_required decorator - /login, /logout routes with Flask session - before_request guard on all routes (bypasses login + static) - session.permanent = True, 30-day lifetime - Login page: dark themed, password field, error flash - Logout link in desktop sidebar and hamburger drawer - No password set = open access (dev mode) Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>93c7d2b
-
Fix infinite generation loop and improve progress visibility
- web_app.py: reset stuck 'generating' status on startup (survives hot-reload/crash) - db/database.py: set SQLite timeout=30s and enable WAL mode to prevent write-lock failures - optimizer/solver.py: fix _solve_best_effort ignoring always_available flags; add phase/score tracking to progress callback; notify phase-2 start when falling back to best-effort - routes/generate.py: pass period_id to solve(); expose phase/obj fields in status endpoint - waiting.html: rAF-driven smooth bar (moves from page load, not first callback); phase labels (step 1/2 vs 2/2); objective score display with delta; 90s client-side timeout Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>ee2b6ed
-
Performance: in-memory cache, DB indexes, 2 gunicorn workers
- flask-caching SimpleCache: employees/periods/settings cached 180-300s - Cache invalidation on writes - 6 DB indexes on high-frequency foreign key columns - gunicorn workers 1→2 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>3f4c264 -
Performance: fix N+1 queries, share DB conn per request, add gzip compression
- get_all_employees: 77 queries → 3 (batch load patterns/unavail) - Flask g: reuse one DB connection per request instead of per-call - flask-compress: gzip HTML/JSON responses Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>ded0d16
-
feat: Flask Webアプリ化・PostgreSQL対応・Render デプロイ設定を追加
iPhoneからアクセスできるWebアプリとして動作するよう変換。 既存のソルバー・DBロジック・エクスポート機能はそのまま流用。 - db/database.py: SQLite/PostgreSQL 両対応のDBアダプター実装 - db/repositories.py: PostgreSQL互換SQL構文に修正 - web_app.py: Flask アプリケーションファクトリ - routes/: 従業員・シフト入力・自動生成・スケジュール・客数・設定・エクスポート - templates/: Bootstrap5 モバイルファーストレスポンシブ UI(ボトムナビ付き) - static/manifest.json + sw.js: PWA対応(ホーム画面追加可能) - Procfile + render.yaml: Render 無料枠へのデプロイ設定 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>5aad2f7