Skip to content

Conversation

@Oaphi
Copy link
Member

@Oaphi Oaphi commented Feb 3, 2026

closes #1968 (the label is now configurable via locale strings):

Screenshot from 2026-02-03 17-39-50

closes #1971:

Screenshot from 2026-02-03 18-17-51 Screenshot from 2026-02-03 18-18-02 Screenshot from 2026-02-03 18-18-15

closes #1975 - comment threads now use the priority_order common scope regardless of whether they are initially loaded or expanded via the "show more" button (note that we still order by updated_at and not last_activity_at - we should switch to the latter when we can).

closes #1970:

image

closes #1965 (see below);
closes #1966 (see below);
closes #1884 (we now simply use Moment.js to format timestamps - note the new format and preserved relative time):

2026-02-05_14-24

closes #1977 (also exposes MaxUploadSize to client-side code as QPixel.MAX_UPLOAD_SIZE):
Screenshot from 2026-02-05 16-19-05

closes #1969 (with existing threads and no threads respectively):

image image

closes #1671 (new site setting: MaxRequestBodySize):
image

@codecov
Copy link

codecov bot commented Feb 3, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 80.98%. Comparing base (fb4d5da) to head (b002f8b).

Additional details and impacted files
Components Coverage Δ
controllers 75.60% <ø> (+0.03%) ⬆️
helpers 85.08% <100.00%> (+0.02%) ⬆️
jobs 81.48% <ø> (ø)
models 93.03% <100.00%> (-0.01%) ⬇️
tasks 61.11% <ø> (ø)

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@Oaphi Oaphi requested review from a team, cellio and trichoplax February 3, 2026 15:59
@cellio
Copy link
Member

cellio commented Feb 3, 2026

Tested:

  • comment label (1968)
  • search width (1971)
  • thread order (1975)
  • profile stats alignment (1970)
  • notification times (1965, 1884)
  • inbox date format (1966)
  • large avatar images (1977)
  • new comment wording (1969)
  • silent error for too-large image (1671)

What user testing, if any, applies for #1884 and #1671?

Oaphi added 20 commits February 3, 2026 20:09
@Oaphi Oaphi marked this pull request as ready for review February 7, 2026 18:28
Comment on lines 219 to 236
def cleanup_site_settings
to_remove = []

$site_settings_map.each do |community_id, names|
stale_settings = SiteSetting.unscoped
.where(community_id: community_id)
.where.not(name: names)
to_remove.push(*stale_settings)
end

return unless to_remove.any?

ActiveRecord::Base.transaction do
to_remove.each(&:destroy!)
end

puts "#{SiteSetting.model_name}: removed #{to_remove.size}"
end
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

After this PR is merged, we'll start automatically removing SiteSettings that are no longer present in seeds. My hope is that it'll evolve into a proper cleanup step in the future and then into a full solution for dynamically changing seeds.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Question: if a setting is no longer in seeds but is in the DB, then code that still checks for that setting would continue to work in existing deployments and fail in new ones. How do we make sure that there's no referring code before removing, and especially auto-removing, a setting? I love having cleanup but do want to make sure we only clean up truly unused stuff.

Copy link
Member Author

@Oaphi Oaphi Feb 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can't - well, we technically can, but that would be an unreasonable thing to automate. For the cleanup to trigger, one has to manually remove the setting from the seed file - at which point it's entirely on them to ensure there's nothing referencing the setting in code, we can't do anything about that. And if we remove a setting (as is the case with MaxUploadSize here), the onus is on us to update the codebase to not use it anymore.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, ok. I assume grepping the code for the name of the setting you're removing is sufficient to catch any remaining references?

Copy link
Member Author

@Oaphi Oaphi Feb 8, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup, there should be no code referencing the old setting (I thoroughly purged it before dropping, of course) but double-checking won't hurt

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My question wasn't about this change, but future ones. :-) Is there a comment in the YAML file to the effect that removing an entry will purge it (not just stop seeding it)? Belt and suspenders isn't bad when it comes to comments for future editors.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have hard time imagining someone removing a baked in site setting without checking how it's used and expecting it to not break anything, but I suppose a mention in the docs won't hurt. We might want the cleanup to be locked behind an environment variable similar to UPDATE_POSTS just to be on the safe side (it's not like having a dangling site setting is the end of the world). @ArtOfCode-, what do you think about adding one?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm probably being needlessly paranoid -- that PR would get reviewed, after all, and we'd have a conversation like this if it didn't mention calling code or the lack thereof. I think we can leave it as-is. (Feel free to resolve this conversation.)

@Oaphi
Copy link
Member Author

Oaphi commented Feb 8, 2026

What user testing, if any, applies for #1884 and #1671?

For #1884, none is needed as long as the new timestamp format works. For #1671 one could tweak the new site setting (MaxRequestBodySize), then attempt to upload a file of a size bigger than the new limit. When pasting the file directly to the new post body field, there should be a notification mentioning the limit. When uploading via the form, it should be mentioned in the caption + correctly error out. NGINX can be tested once the change is on the dev server

Copy link
Member

@cellio cellio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tested everything listed (and checked off) in a previous comment and it all looks good. I have a (paranoid?) question about deleted posts, and someone more qualified should review new JS and the JSON & config changes in the db directory. (I looked at all the other code changes and they look fine to me.)

Copy link
Contributor

@trichoplax trichoplax left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have a couple of requests and a question.

@Oaphi Oaphi requested a review from trichoplax February 12, 2026 01:39
Copy link
Contributor

@trichoplax trichoplax left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All looks good.

@Oaphi Oaphi requested a review from ArtOfCode- February 12, 2026 02:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment