Timed topic's date posted keeps moving

AI-generated summary

User Vocino reported a bug where a timed topic posted to a private category was continuously resurfacing in a public category instead of staying hidden, with its timestamp repeatedly resetting. After tgxworld requested error logs, Vocino pasted a Jobs::CloseTopic exception, which tgxworld identified as a separate, already-fixed issue. The actual problem was traced to a PublishTopicToCategory job remaining in the scheduled queue. tgxworld fixed the root cause in a new commit and advised users to manually cancel the lingering job via the Sidekiq scheduled queue as a temporary workaround. Vocino confirmed the job was present and thanked tgxworld for the assistance.

Continuing the discussion from How to create a Timed Topic:

I’m noticing a strange bug where a topic I posted in a private category on Friday, to be timed for posting to a public category on Saturday, is now being continuously moved to the top of the latest topics.

The timestamp on it reads “13m” right now and will reset routinely. I’m not sure how often yet as I just noticed this. I’m assuming it’s being triggered possibly every time the clock reaches the hour it was set to or something along those lines.

4 إعجابات

Are there any errors in your logs?

Thinking this might be related?

Recent
Message (2 copies reported)

Job exception: uninitialized constant Jobs::CloseTopic
Backtrace

/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.7.1/lib/active_support/inflector/methods.rb:263:in `const_get'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.7.1/lib/active_support/inflector/methods.rb:263:in `block in constantize'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.7.1/lib/active_support/inflector/methods.rb:259:in `each'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.7.1/lib/active_support/inflector/methods.rb:259:in `inject'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.7.1/lib/active_support/inflector/methods.rb:259:in `constantize'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/activesupport-4.2.7.1/lib/active_support/core_ext/string/inflections.rb:66:in `constantize'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/sidekiq-4.2.4/lib/sidekiq/processor.rb:126:in `block in process'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/sidekiq-4.2.4/lib/sidekiq.rb:35:in `block in <module:Sidekiq>'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/sidekiq-4.2.4/lib/sidekiq/processor.rb:124:in `process'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/sidekiq-4.2.4/lib/sidekiq/processor.rb:81:in `process_one'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/sidekiq-4.2.4/lib/sidekiq/processor.rb:69:in `run'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/sidekiq-4.2.4/lib/sidekiq/util.rb:17:in `watchdog'
/var/www/discourse/vendor/bundle/ruby/2.3.0/gems/sidekiq-4.2.4/lib/sidekiq/util.rb:25:in `block in safe_thread'
4 إعجابات

That particular error has been fixed in

https://github.com/discourse/discourse/commit/e8eaffbd724e8618bfb58b6f0fba88bae4c8ee1b

and it isn’t related to the current behavior that you’re seeing.

Can you see if there is a PublishToCategory job in https://<your hostname>/sidekiq/scheduled?

3 إعجابات

Yes, there is.

in 3 days	default	Jobs::PublishTopicToCategory	
{"topic_status_update_id"=>868, "current_site_id"=>"default"}

Thanks @Vocino! I found the bug and fixed it in

https://github.com/discourse/discourse/commit/aadf4805a539425021dff8352cc4aa404c4159f0

In the meantime, you can cancel the job manually in https://<your hostname>/sidekiq/scheduled.

7 إعجابات

Cool, thanks for the help!

إعجاب واحد (1)