diff --git a/AGENTS.md b/AGENTS.md index 8acc6fa9f..465eb9797 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -21,7 +21,7 @@ Toolchain versions (Ruby, Node, Postgres, pnpm) are pinned in `.tool-versions`; - **Interactive console:** `rake console` (or `bin/rails console`). - **Asset build (one-off):** `pnpm build` (JS via esbuild) and `pnpm build:css` (CSS via esbuild). -Feed operations are exposed as rake tasks: `rake fetch_feeds`, `rake fetch_feed[ID]`, `rake lazy_fetch`, `rake cleanup_old_stories[DAYS]` (default 30 days; removes read, unstarred stories). +Feed operations are exposed as rake tasks: `rake fetch_feeds`, `rake fetch_feed[ID]`, `rake cleanup_old_stories[DAYS]` (default 30 days; removes read, unstarred stories). ## Architecture @@ -64,6 +64,10 @@ Gotchas: ESLint, Stylelint, and RuboCop each use a generated "todo" baseline file (`.eslint_todo.ts`, `.stylelint_todo.yml`, `.rubocop_todo.yml`) that suppresses pre-existing offenses. The intent is to ratchet these down over time — fix offenses and remove their entries rather than adding new suppressions. Regenerate via `bundle exec exe/eslint_autogen` / `bundle exec exe/stylelint_autogen` (CI checks that the committed baseline matches). A custom RuboCop cop lives in `linters/rubocop/cop/`. +## Changelog + +Stringer doesn't cut releases; people run whatever is on `main`. When a change matters to people running Stringer (a breaking change, a new or removed setting or rake task, a notable feature), add an entry to `CHANGELOG.md` under a heading for the date it lands on `main` (`## YYYY-MM-DD`, newest first). Reuse that day's heading if it already exists, and group entries under `### Breaking changes` etc. as needed. Skip internal changes like refactors, tests, and dependency bumps. + ## CI CircleCI (`.circleci/config.yml`) runs, in order: `tscheck`, eslint (incl. unused-rule check and autogen drift check), vitest, brakeman, stylelint (+ autogen drift), rubocop, then rspec (with `xvfb-run` for system specs). Match this locally before pushing. diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 000000000..baf0a9add --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,14 @@ +# Changelog + +Changes that matter to people running Stringer, newest first. Each heading is +the date the change landed on `main`. + +## 2026-11-28 + +### Breaking changes + +- **Heroku: `rake lazy_fetch` removed.** If your Heroku Scheduler runs + `rake lazy_fetch`, change it to `rake fetch_feeds`. The old task only queued + jobs, so feeds didn't update while the web dyno was asleep + ([#647](https://github.com/stringer-rss/stringer/issues/647)). You can also + remove the `APP_URL` setting. diff --git a/Rakefile b/Rakefile index 5fc8d463b..5af931830 100644 --- a/Rakefile +++ b/Rakefile @@ -9,20 +9,6 @@ task fetch_feeds: :environment do Feed::FetchAll.call end -desc "Lazily fetch all feeds." -task lazy_fetch: :environment do - if ENV["APP_URL"] - uri = URI(ENV["APP_URL"]) - - # warm up server by fetching the root path - Net::HTTP.get_response(uri) - end - - FeedRepository.list.each do |feed| - CallableJob.perform_later(Feed::FetchOne, feed) - end -end - desc "Fetch single feed" task :fetch_feed, [:id] => :environment do |_t, args| Feed::FetchOne.call(Feed.find(args[:id])) diff --git a/app.json b/app.json index 342a65f59..dc86ac557 100644 --- a/app.json +++ b/app.json @@ -35,14 +35,6 @@ "ENFORCE_SSL": { "description": "Force all clients to connect over SSL", "value": "true" - }, - "WORKER_EMBEDDED": { - "description": "Force worker threads to be spawned by main process", - "value": "true" - }, - "WORKER_RETRY": { - "description": "Number of times to respawn the worker thread if it fails", - "value": "3" } }, "addons": [ diff --git a/app/views/debug/heroku.rb b/app/views/debug/heroku.rb index 2c396d967..fd289e88b 100644 --- a/app/views/debug/heroku.rb +++ b/app/views/debug/heroku.rb @@ -2,7 +2,7 @@ class Views::Debug::Heroku < Views::Base SCHEDULER_TASK = <<~TEXT - Task: rake lazy_fetch + Task: rake fetch_feeds Dyno Size: 1X Frequency: Hourly TEXT diff --git a/docs/Heroku.md b/docs/Heroku.md index a63923f81..01d4620df 100644 --- a/docs/Heroku.md +++ b/docs/Heroku.md @@ -10,8 +10,6 @@ heroku config:set ENCRYPTION_KEY_DERIVATION_SALT=`openssl rand -hex 64` git push heroku main -heroku config:set APP_URL=`heroku apps:info --shell | grep web_url | cut -d= -f2` - heroku run rake db:migrate heroku restart @@ -19,7 +17,7 @@ heroku addons:create scheduler heroku addons:open scheduler ``` -Add an hourly task that runs `rake lazy_fetch` (if you are not on Heroku you may want `rake fetch_feeds` instead). +Add an hourly task that runs `rake fetch_feeds`. Load the app and follow the instructions to import your feeds and start using the app. diff --git a/spec/system/heroku_spec.rb b/spec/system/heroku_spec.rb index 04e71c583..3e142ba59 100644 --- a/spec/system/heroku_spec.rb +++ b/spec/system/heroku_spec.rb @@ -10,7 +10,7 @@ it "displays the scheduler task instructions" do visit("/heroku") - expect(page).to have_text("rake lazy_fetch") + expect(page).to have_text("rake fetch_feeds") end it "links to the home page" do