Discourse Yearly Review

I’m not able to reproduce this. I assume by “trigger creation in sidekiq” you are clicking this button?

The logic to check if the topic already exists is just based on a custom field per FIX: Check for existing review topic by custom field (#65) · discourse/discourse-yearly-review@98012d8 · GitHub fix, so changing the category shouldn’t make a difference (though of course deleting the topic will):

def review_topic_exists?(review_year)
  TopicCustomField
    .find_by(name: ::YearlyReview::POST_CUSTOM_FIELD, value: review_year.to_s)
    &.topic
    .present?
end

Unless there is something clearing these custom fields or some other issue I am not aware of?

1 Like

And yet is happening. Mine is creating new one, and

  • the plugin used category forum at the Jan 1st
  • I changed setting to category community
  • I moved created review from forum to community editing topic itself, not using timer and republishing
  • the plugin created new one next day (I’ve allowed duplicate headers)

Or

  • the plugin is configured to use category staff
  • I moved created topic from staff to community editing topic itself
  • next day the plugin created new one to staff

The last one may been an issue because of

  • I moved created review without staff members and moved the review to community
  • I included staff and triggered creation and it did new review and this time staff included as asked
  • I edited name of that topic and moved to community
  • I changed setting back to staff excluded
  • and the plugin created new review next day

It should create a review, if

  • date is after Jan 1., AND
  • there is not a topic of right name

Well, AFAIK it should follow that logic. I can be very wrong too. But without any knowledge of coding what so ever I would make a bold claim: it doesn’t recoqnize name of topic now because category is different what settings say it should be.

2 Likes

Correct.

I am able to replicate this again today using the exact same steps, on my personal site. I now have three of these topics in three different categories.

Happy to invite you to show you.

2 Likes

We recently changed this to check for the presence of a custom field on the yearly review topic for that year, the topic title should have no bearing:

Just confirming, but do you and @tobiaseigen have the latest version with this commit FIX: Check for existing review topic by custom field (#65) · discourse/discourse-yearly-review@98012d8 · GitHub installed?

I am not saying it is not happening – there is clearly some difference in configuration or some other difference between my local setup and yours/Tobias’ sites, so just trying to narrow things down here so we can push a fix.

@tobiaseigen yes please!

2 Likes

I don’t know, you tell me :smirk:

3.2.0.beta4-dev (9ac3961f23)

Anyway, I’m not big believer on once a year upgrading, so I’ll do rebuilding today too.

2 Likes

I thought I updated this topic last week but I didn’t :facepalm: I found the issue, and the fix is here:

TL;DR: That previous commit I made introduced a bug, where if the first year topic for the year is deleted, subsequent sidekiq runs will keep making more and more topics. Once you have that commit the issue should stop.

5 Likes

One question because the virtual world has changed: Are AI personas excluded somehow? I mean, those chatty ones that can be mentioned.

Because if those non-humans show up in the review, I will be in big trouble.

My first attempt was to add AIs to the staff group, but that wasn’t possible.

3 Likes

Good question! Can you test it on your site and let us know?

Presumably since bots don’t participate in public discussions, they will not be featured.

2 Likes

Well, my bots participate, a lot. That’s why those are mentionable.

I could do a test drive triggering the review manually. Didn’t think that option at all :joy:

edit: it didn’t do anything at all, no review what so ever :thinking:

2 Likes

I think it only works in January.

I’ve only had a quick look on my phone but I’ve seen some checks that the UserID is greater than 0. The AI users created by the Discourse AI plugin have negative IDs.

4 Likes

That’s true unless you run it manually - see the instructions in the first post.

3 Likes

My understanding is that only the top 5 public categories will be used to pull data from, IF nothing is placed in that first setting option. May I assume that if I specify 20 or 30 (or more) categories there, that they will all be used for source data? I have a large number of categories, and 5 just doesn’t represent my user base very well.

Happy New Year

1 Like

Yeah, it doesn’t include bots. Nice.

Happy New Year!

On my three sites the plugin did not run - at least no new topic was created. It’s 11am local time here. Do I need to run it manually? And doesn’t it run twice maybe?

I tried to create a shadow review including the staff. Just nice reminder to users how big part they are content wise. But it refuses generate it — I guess because it knows it has been alredy done.

Is the only solution delete original one, regenerate new and restore the the first one?

It follows the time you installed the plugin. So manually triggering will do the job, and next year it will follow that time.

1 Like

You can definitely do it, last year I made one with both. I don’t remember how I did it but I definitely didn’t delete anything. I think I just clicked the option and the force ran it

1 Like

But it doesn’t do it now. I have a feeling it has something to do earlier bug’ish where the plugin created new review if the old one was moved to new category.

There is a small bug. Pipe symbol | should be removed from topic title before including in the Markdown table.

1 Like

I did and got my review topics for all three instances. Unfortunately all three in English, not German (the language of the instances).

Last year the review topics were created (automaticly or manually triggered, don’t know anymore) at 3:15am. So something is not working here as you said.

Maybe the language and also automatic triggering things can be looked in for next year?