whiteleaf7 / narou

Narou.rb - 小説家になろうのダウンローダ&縦書き整形&管理アプリ。Kindle(などの電子書籍端末)でなろうを読む場合に超便利です!
Other
483 stars 56 forks source link

3.9.0に変えてからさらにwaitが足りてない? #429

Closed makijackson closed 2 months ago

makijackson commented 2 months ago

以前はデフォルトで間に合ってたんですけど3.9.0に変えてから下記のようなエラーが出るようになりました。掲示板の方ではwait時間が足りないなどのコメントがあったので色々変えて見ましたが相変わらずなので何かヒントを求めて書き込んでます。これは400話ぐらいのなろうのダウンロード中です。以前からのもののアップデートは(わからないでけかもしれませんが)とりあえず大丈夫そうです。

/opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/net/http.rb:1603:in initialize': Failed to open TCP connection to ncode.syosetu.com:443 (Cannot allocate memory - connect(2) for "ncode.syosetu.com" port 443) (Errno::ENOMEM) from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/net/http.rb:1603:inopen' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/net/http.rb:1603:in block in connect' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/timeout.rb:186:inblock in timeout' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/timeout.rb:193:in timeout' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/net/http.rb:1601:inconnect' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/net/http.rb:1580:in do_start' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/net/http.rb:1569:instart' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/open-uri.rb:334:in open_http' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/open-uri.rb:770:inbuffer_open' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/open-uri.rb:220:in block in open_loop' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/open-uri.rb:218:incatch' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/open-uri.rb:218:in open_loop' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/open-uri.rb:158:inopen_uri' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/open_uri_redirections-0.2.1/lib/open-uri/redirections_patch.rb:55:in open_uri' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/open-uri.rb:750:inopen' from /opt/homebrew/Cellar/ruby/3.3.0/lib/ruby/3.3.0/open-uri.rb:29:in open' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/downloader.rb:1177:indownload_raw_data' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/downloader.rb:1133:in a_section_download' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/downloader.rb:1036:inblock in sections_download_and_save' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/downloader.rb:1030:in each' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/downloader.rb:1030:ineach_with_index' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/downloader.rb:1030:in sections_download_and_save' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/downloader.rb:395:inrun_download' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/downloader.rb:337:in start_download' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/command/download.rb:142:inblock in execute' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/command/download.rb:110:in each' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/command/download.rb:110:inwith_index' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/command/download.rb:110:in execute' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/commandbase.rb:125:inexecute!' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/commandbase.rb:134:in execute!' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/commandline.rb:29:inrun' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/commandline.rb:43:in run!' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/narou.rb:50:inblock in <top (required)>' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/lib/backtracer.rb:16:in capture' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/narou.rb:49:in<top (required)>' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/bin/narou:13:in require_relative' from /opt/homebrew/lib/ruby/gems/3.3.0/gems/narou-3.9.0/bin/narou:13:in<top (required)>' from /opt/homebrew/bin/narou:25:in load' from /opt/homebrew/bin/narou:25:in

'

jam7 commented 2 months ago

掲示板の方にも出てますが、サーバー側の制限なので、待ち時間を延ばすしかありません。エラーが出るのが嫌なら、

download.interval: 2.0
download.wait-steps: 3
update.interval: 5.0

くらいにしてゆっくり待つのがお薦めです。私もそうしてますがupdateに一晩かかりますがエラーは出なくなりました。

makijackson commented 2 months ago

ありがとうございます。download.intervalは変えていましたが wait-stepsも変更したことで無事ダウンロードができるようになりました。