Rake error during update (not fatal) (again)

AI-generated summary

The user Ed_S reported a non-fatal Rake error that occurred during both Docker and Discourse upgrades. The error message indicates that the task ‘assets:flush_sw’ is unknown and suggests running rake --tasks to see available tasks. The error also mentions the alternative task ‘assets:clean’.

Again, for information, and looking similar to an observation made previously, 5 months ago, which seemed to be explained as a transient situation:
Rake error during update (not fatal)

During docker upgrade:

Waiting for Unicorn to reload.......................
$ bundle exec rake assets:flush_sw
rake aborted!
Don't know how to build task 'assets:flush_sw' (See the list of available tasks with `rake --tasks`)
Did you mean?  assets:clean
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
/usr/local/bin/bundle:23:in `load'
/usr/local/bin/bundle:23:in `<main>'
(See full trace by running task with --trace)
WARNING: Unable to flush service worker file
Running post deploy migrations

and during discourse upgrade:

Waiting for Unicorn to reload..........................
$ bundle exec rake assets:flush_sw
rake aborted!
Don't know how to build task 'assets:flush_sw' (See the list of available tasks with `rake --tasks`)
Did you mean?  assets:clean
/var/www/discourse/vendor/bundle/ruby/2.6.0/gems/rake-13.0.1/exe/rake:27:in `<top (required)>'
/usr/local/bin/bundle:23:in `load'
/usr/local/bin/bundle:23:in `<main>'
(See full trace by running task with --trace)
WARNING: Unable to flush service worker file
Running post deploy migrations
1 Like