Conversation
- 「タグ」「状態」「リンク」カラムに orderable: false を追加 - これらのカラムは「DL」「保存先」と同様にソート不要のため - ヘッダークリック時にソート順が変わらないように修正
- Command.require_all を commandline.rb で実行し、CLI/WebUI両方で全コマンドをロード - これにより個別のコマンドファイルでの require_command が不要に - lib/downloader.rb に NovelSetting の require を追加 - PushServer の quit メソッドを改善: - @server_thread を保存し、終了時に確実に kill - Ctrl+C 終了時の 19199 ポート(WebSocket)プロセス残存問題を解決 参考: ponponusa/draft/r2.0 の c2c5313 (Command.require_all の実装)
Feature/upstream cherry pick
- narou-mod向けの実行ファイルとバッチスクリプトを追加 - gemspecリネームとビルド設定を調整 - 旧narouコマンドの互換起動を維持
- CIとRuboCop設定をnarou-mod用に更新 - Gemfileコメントを最新化
- Windows側ブラウザへのフォールバックでnarou-mod web起動時の警告を解消
- narou-mod web の更新処理をGitHub配布gemベースに刷新 - WUI の更新テストを含むRSpecを追加
- downloaderのtoc等読み込みを安全化しエラー時は警告扱いへ - 不正なYAML検知用のRSpecを追加
- downloader取得処理の安全性をRSpecで検証
Feature/change gem name
- Helper.erb_copy 用に erb を読み込む - Downloader 未定義でもバックアップ判定できるよう調整
Windows 向け init 実行時の NameError を解消
- プロダクト名を統一 - その他、いくつかのテキストを修正
feature/update-various-texts
- ダウンローダーとWeb APIをタグ情報連携に対応 - Web UIの表示とスタイルを調整しプロモタグを可視化 - 新規スペックとバージョン情報を追加更新
- タッチ判定の誤検知を防ぎ click イベントを確実に発火 - バージョン確認ダイアログの null セーフティを追加
- プロモタグ除去の既定値を無効化し、明示設定時のみ除去が働くよう変更 - Web API/テーブル描画からのプロモタグ正規化を外し、レスポンス生成時にタイトルを書き換えないよう変更 - 更新コマンドで更新差分がなくてもタイトル/プロモタグが追随するよう改善 - 最新取得タイトルを保持する項目を導入し、プロモタグ除去は常に生データから派生させる管理へ再構成 - rspecの更新
Feature/web UI table arrange
- notepad/drag_and_drop/download 各テンプレートの CSS/JS 参照を CDN に切り替え - テンプレート内のインデントを整えて Haml の 500 エラーを解消 - narou-mod.gemspec のインストールメッセージを微調整
Fix/old jquery loadding pages
- fix Narou::COMMIT
|
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| def http_download(uri, destination, limit = 5) | ||
| raise Error, "ダウンロードがリダイレクト回数上限を超えました" if limit <= 0 | ||
|
|
||
| perform_download_request(uri) do |response| | ||
| response.value | ||
| File.open(destination, "wb") do |file| | ||
| response.read_body do |chunk| | ||
| file.write(chunk) | ||
| end | ||
| end | ||
| end | ||
| rescue Net::HTTPRedirection => e | ||
| new_uri = URI(e.response["location"]) | ||
| http_download(new_uri, destination, limit - 1) | ||
| rescue Net::HTTPRetriableError => e | ||
| raise Error, "HTTP #{e.response.code} #{e.response.message}" |
There was a problem hiding this comment.
Follow GitHub release redirects when downloading gem assets
The new updater’s http_download method never follows redirects. It first calls response.value, which raises Net::HTTPRetriableError for any 3xx response and jumps to the later rescue that re-raises an error, so the Net::HTTPRedirection handler that should follow the Location header is unreachable. GitHub browser_download_url links respond with 302/307 redirects to the actual S3 asset, meaning auto-updates will reliably fail with “HTTP 302 Found” instead of downloading the gem. Inspect the response class before invoking value or intercept the retriable error and manually retry with the redirect location so that gem downloads succeed.
Useful? React with 👍 / 👎.
-(デフォルトで無効 = 以前と同様にタイトルと著者名を扱う)