Commit Graph

56161 Commits

Author SHA1 Message Date
dependabot[bot]
61f2786614
Build(deps): Bump rack from 2.2.9 to 2.2.10 (#29198)
Bumps [rack](https://github.com/rack/rack) from 2.2.9 to 2.2.10.
- [Release notes](https://github.com/rack/rack/releases)
- [Changelog](https://github.com/rack/rack/blob/main/CHANGELOG.md)
- [Commits](https://github.com/rack/rack/compare/v2.2.9...v2.2.10)

---
updated-dependencies:
- dependency-name: rack
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-15 05:59:37 +08:00
Jarek Radosz
f230d50c6c
DEV: Ignore an upcoming eslint rule (#29194) 2024-10-14 19:09:25 +02:00
David Taylor
182689b6bb
DEV: Improve error messages for legacy theme helpers in gjs (#29191)
theme-setting and theme-i18n are not needed in `.gjs` files. This commit adds more helpful error messages to direct developers to the modern alternatives.
2024-10-14 16:00:56 +01:00
David Battersby
492cf52bab
FIX: trashed channel thread view bug (#29192)
When chat channels are deleted, some users may be able to click the thread before it gets removed from the UI. This leads to a 500 error causing log noise. We can use the safe navigational operator to prevent calling chatable when the channel is not found (due to deleted_at constraint in query).
2024-10-14 17:45:50 +04:00
dependabot[bot]
9a922e5128
Build(deps-dev): Bump @swc/core from 1.7.26 to 1.7.35 (#29166)
Bumps [@swc/core](https://github.com/swc-project/swc) from 1.7.26 to 1.7.35.
- [Release notes](https://github.com/swc-project/swc/releases)
- [Changelog](https://github.com/swc-project/swc/blob/main/CHANGELOG.md)
- [Commits](https://github.com/swc-project/swc/compare/v1.7.26...v1.7.35)

---
updated-dependencies:
- dependency-name: "@swc/core"
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-14 09:56:11 +02:00
Jarek Radosz
a3ea2886dc
DEV: Set priorities on user tips (#29176)
Currently the topic timeline tip appears before the suggested topics one only due to a small implementation detail in the latter.

This ensures that tips appear in the expected order when more than one of these components is rendered at the same time.
2024-10-14 09:54:01 +02:00
dependabot[bot]
bf773e70bd
Build(deps): Bump css_parser from 1.19.0 to 1.19.1 (#29179)
Bumps [css_parser](https://github.com/premailer/css_parser) from 1.19.0 to 1.19.1.
- [Changelog](https://github.com/premailer/css_parser/blob/master/CHANGELOG.md)
- [Commits](https://github.com/premailer/css_parser/compare/v1.19.0...v1.19.1)

---
updated-dependencies:
- dependency-name: css_parser
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-14 09:50:49 +02:00
chapoi
1695971523
UX: change thread button in chat nav to use btn-transparent (#29186) 2024-10-14 09:25:27 +02:00
Alan Guo Xiang Tan
c949d95951
DEV: Fix not flushing Redis properly for system test. (#29188)
In  ed6c9d1545, we started flushing
Redis's database at the end of each test. However, we had something like
this:

```
config.after(:each, type: :system) { teardown system test stuff }
config.after(:each) { # flush redis }
```

When stuff was defined in this order, flushing redis was called before
the teardown of system test. Instead we have to switch the order around
which is what this commit does.
2024-10-14 15:24:29 +08:00
dependabot[bot]
bb5a58a686
Build(deps-dev): Bump trilogy from 2.8.1 to 2.9.0 (#29183)
Bumps [trilogy](https://github.com/trilogy-libraries/trilogy) from 2.8.1 to 2.9.0.
- [Release notes](https://github.com/trilogy-libraries/trilogy/releases)
- [Changelog](https://github.com/trilogy-libraries/trilogy/blob/main/CHANGELOG.md)
- [Commits](https://github.com/trilogy-libraries/trilogy/compare/v2.8.1...v2.9.0)

---
updated-dependencies:
- dependency-name: trilogy
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-14 14:40:20 +08:00
dependabot[bot]
cab79f1ef4
Build(deps): Bump net-imap from 0.4.16 to 0.4.17 (#29182)
Bumps [net-imap](https://github.com/ruby/net-imap) from 0.4.16 to 0.4.17.
- [Release notes](https://github.com/ruby/net-imap/releases)
- [Commits](https://github.com/ruby/net-imap/compare/v0.4.16...v0.4.17)

---
updated-dependencies:
- dependency-name: net-imap
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-14 14:18:58 +08:00
dependabot[bot]
5e8cabc1de
Build(deps-dev): Bump zeitwerk from 2.6.18 to 2.7.0 (#29181)
Bumps [zeitwerk](https://github.com/fxn/zeitwerk) from 2.6.18 to 2.7.0.
- [Changelog](https://github.com/fxn/zeitwerk/blob/main/CHANGELOG.md)
- [Commits](https://github.com/fxn/zeitwerk/compare/v2.6.18...v2.7.0)

---
updated-dependencies:
- dependency-name: zeitwerk
  dependency-type: direct:development
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-14 14:18:04 +08:00
Ted Johansson
45c9316d7d
DEV: Fix problem check tracker unique index not respecting NULLs (#29169)
By default, when checking uniqueness on a tuple for the purposes of enforcing a unique index, PostgreSQL considers NULLs to be distinct values. Because of this we could incorrectly have multiple entries with { identifier: "rails_env", target: nil } created due to race conditions. This would then cause errors at runtime.
2024-10-14 13:55:35 +08:00
dependabot[bot]
ca06518140
Build(deps-dev): Bump puppeteer-core from 23.5.2 to 23.5.3 (#29184)
Bumps [puppeteer-core](https://github.com/puppeteer/puppeteer) from 23.5.2 to 23.5.3.
- [Release notes](https://github.com/puppeteer/puppeteer/releases)
- [Changelog](https://github.com/puppeteer/puppeteer/blob/main/release-please-config.json)
- [Commits](https://github.com/puppeteer/puppeteer/compare/puppeteer-core-v23.5.2...puppeteer-core-v23.5.3)

---
updated-dependencies:
- dependency-name: puppeteer-core
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-14 13:49:40 +08:00
Ted Johansson
408de686bb
DEV: Convert admin user fields to FormKit (#29070)
This change replaces the admin form for adding and editing custom user fields with a new FormKit implementation.
2024-10-14 13:19:53 +08:00
Natalie Tay
ede06ffd43
FIX: Allow user to log in another account using the same device (client_id) (#29121)
Allow user to log in another account using the same device (client_id)
2024-10-14 12:39:20 +08:00
Juan David Martínez Cubillos
d3f09f8f61
DEV: Add discourse-hcaptcha plugin to the metadata list of official plugins (#29177) 2024-10-11 15:35:12 -05:00
Tobias Eigen
ae2b871037
Add link to meta to forwarded emails behaviour desc (#29174)
Added a link to https://meta.discourse.org/t/configuring-incoming-email-to-create-new-topics-or-group-messages/62977 to the `forwarded emails behaviour` setting description, to help admins learn how email forwarding works.
2024-10-11 11:07:35 -07:00
Jarek Radosz
7ab4df9a04
DEV: Fix linting in notify_category_change_spec (#29175) 2024-10-11 19:55:33 +02:00
Yuvaraj J
65a1e149ad
FIX: Notify mailing list subscribers on category change (#28811)
cf. https://meta.discourse.org/t/email-notifications-dont-get-sent-on-category-change-for-mailing-list-mode-users/308096
2024-10-11 14:47:39 +02:00
David Battersby
79d2eb5beb
FEATURE: enable threading in chat DM channels (#29170)
Support threads in DMs and group chats so members can keep their conversations organized.

This change adds a new toggle switch for threads within the Chat Channel Settings screen. For new direct message channels threading is enabled by default.

We have made a decision to exclude direct message threads from the My Threads screen for now.
2024-10-11 13:05:07 +04:00
Alan Guo Xiang Tan
d90203f27f
DEV: Break up PG query in MakePasswordColumnsFromUsersReadOnly (#29167)
We are getting a lock timeout but I can't tell which statement so break
it up.
2024-10-11 11:25:55 +08:00
Martin Brennan
2193667e1f
FIX: Plugin JS failing to load would break admin interface (#29139)
If a plugin's JS fails to load for some reason, most commonly
ad blockers, the entire admin interface would break. This is because
we are adding links to the admin routes for plugins that define
them in the sidebar.

We have a fix for this already in the plugin list which shows a warning
to the admin. This fix just prevents the broken link from rendering
in the sidebar if the route is not valid.
2024-10-11 09:26:10 +10:00
dependabot[bot]
75a7b8f8fd
Build(deps): Bump the babel group with 2 updates (#29165)
Bumps the babel group with 2 updates: [@babel/core](https://github.com/babel/babel/tree/HEAD/packages/babel-core) and [@babel/standalone](https://github.com/babel/babel/tree/HEAD/packages/babel-standalone).


Updates `@babel/core` from 7.25.7 to 7.25.8
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.25.8/packages/babel-core)

Updates `@babel/standalone` from 7.25.7 to 7.25.8
- [Release notes](https://github.com/babel/babel/releases)
- [Changelog](https://github.com/babel/babel/blob/main/CHANGELOG.md)
- [Commits](https://github.com/babel/babel/commits/v7.25.8/packages/babel-standalone)

---
updated-dependencies:
- dependency-name: "@babel/core"
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: babel
- dependency-name: "@babel/standalone"
  dependency-type: direct:production
  update-type: version-update:semver-patch
  dependency-group: babel
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-11 00:29:53 +02:00
Bianca Nenciu
33a4ab13b5
DEV: Set bigint sequences to start at MAX_INT (#28961)
This helps uncover issues with bigint columns that are joined with int
columns. It also introduces a temporary API for plugins to migrate int
columns to bigint in test environment to make tests pass.
2024-10-10 19:28:45 +03:00
Selase Krakani
dd34f1927b
FIX: Imports of upload-only chat messages (#29162)
The current implementation adds a "note" for chat messages with empty
messages, however chat messages with only uploads  are allowed. This change
allows such messages to be imported.
2024-10-10 15:18:10 +00:00
Mark VanLandingham
882c2da29e
DEV: Add modifier to SuggestedTopicsBuilder#add_results (#29164) 2024-10-10 10:03:26 -05:00
Jarek Radosz
8105b545c3
DEV: Fix random typos (#29161) 2024-10-10 16:11:55 +02:00
Mark VanLandingham
909264ee75
DEV: Publish DiscourseEvent after top topic period is calculated (#29142) 2024-10-10 08:10:39 -05:00
Jarek Radosz
374238b910
DEV: Remove duplicated key in a topic fixture (#29159) 2024-10-10 15:05:15 +02:00
Jarek Radosz
578542ca98
DEV: Remove long-deprecated test helpers (#29160)
nothing in all-the* is using them anymore
2024-10-10 15:05:05 +02:00
Amanda Alves Branquinho
5b69329656
DEV: Add helpers to customize poster title (#29156)
* DEV: Add helpers to customize poster title

* fix formatting issues

* Update app/assets/javascripts/discourse/app/templates/badges/show.hbs

Co-authored-by: Jarek Radosz <jradosz@gmail.com>

---------

Co-authored-by: Jarek Radosz <jradosz@gmail.com>
2024-10-10 21:44:35 +09:00
chapoi
3c03d9b1e5
UX: chat index flex issues (#29157) 2024-10-10 12:55:08 +02:00
Alan Guo Xiang Tan
47f383d1ac
DEV: Attempt to fix a flaky spec (#29155)
We some times get the following failure on Github CI:

```
expected StandardError with message matching /some.host/, got #<Socket::ResolutionError: getaddrinfo: Temporary failure in name resolution> with backtrace:
```
2024-10-10 17:19:53 +08:00
Joffrey JAFFEUX
9124d6ba5a
DEV: uses hasNoErrors for field as used on form (#29154)
This commit simply ensures the API is similar for fields and form.
2024-10-10 17:57:06 +09:00
dependabot[bot]
eb7fcf5d78
Build(deps-dev): Bump the embroider group with 4 updates (#29151)
Bumps the embroider group with 4 updates: [@embroider/compat](https://github.com/embroider-build/embroider/tree/HEAD/packages/compat), [@embroider/core](https://github.com/embroider-build/embroider/tree/HEAD/packages/core), [@embroider/macros](https://github.com/embroider-build/embroider/tree/HEAD/packages/macros) and [@embroider/webpack](https://github.com/embroider-build/embroider/tree/HEAD/packages/webpack).


Updates `@embroider/compat` from 3.6.4 to 3.6.5
- [Release notes](https://github.com/embroider-build/embroider/releases)
- [Changelog](https://github.com/embroider-build/embroider/blob/main/CHANGELOG.md)
- [Commits](https://github.com/embroider-build/embroider/commits/HEAD/packages/compat)

Updates `@embroider/core` from 3.4.18 to 3.4.19
- [Release notes](https://github.com/embroider-build/embroider/releases)
- [Changelog](https://github.com/embroider-build/embroider/blob/main/CHANGELOG.md)
- [Commits](https://github.com/embroider-build/embroider/commits/HEAD/packages/core)

Updates `@embroider/macros` from 1.16.8 to 1.16.9
- [Release notes](https://github.com/embroider-build/embroider/releases)
- [Changelog](https://github.com/embroider-build/embroider/blob/main/CHANGELOG.md)
- [Commits](https://github.com/embroider-build/embroider/commits/HEAD/packages/macros)

Updates `@embroider/webpack` from 4.0.7 to 4.0.8
- [Release notes](https://github.com/embroider-build/embroider/releases)
- [Changelog](https://github.com/embroider-build/embroider/blob/main/CHANGELOG.md)
- [Commits](https://github.com/embroider-build/embroider/commits/HEAD/packages/webpack)

---
updated-dependencies:
- dependency-name: "@embroider/compat"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: embroider
- dependency-name: "@embroider/core"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: embroider
- dependency-name: "@embroider/macros"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: embroider
- dependency-name: "@embroider/webpack"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: embroider
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-10 10:23:01 +02:00
dependabot[bot]
9d88722287
Build(deps-dev): Bump puppeteer-core from 23.5.1 to 23.5.2 (#29152)
Bumps [puppeteer-core](https://github.com/puppeteer/puppeteer) from 23.5.1 to 23.5.2.
- [Release notes](https://github.com/puppeteer/puppeteer/releases)
- [Changelog](https://github.com/puppeteer/puppeteer/blob/main/release-please-config.json)
- [Commits](https://github.com/puppeteer/puppeteer/compare/puppeteer-core-v23.5.1...puppeteer-core-v23.5.2)

---
updated-dependencies:
- dependency-name: puppeteer-core
  dependency-type: direct:development
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-10 10:05:10 +02:00
Jarek Radosz
8e41af5ca7
DEV: Update decorator-transform to 2.2.2 (#29153) 2024-10-10 10:02:16 +02:00
chapoi
d58a2b853f
UX: fix missing text overflow ellipsis in chat index pages (#29150) 2024-10-10 09:57:32 +02:00
Martin Brennan
d56bb72819
UX: Change AdminPageSubheader to H2 (#29149)
Since the AdminPageHeader is H1, it is more semantically
correct to progress to H2 after it rather than skipping
a level to H3

Also amend style of H2 to make it the same size as H3
2024-10-10 17:18:26 +10:00
Ella E.
663ce73e26
UX: Set consistent width for primary content in admin UI config area (#29147)
* UX: Adjust the config area primary content width

* UX: Tweak spacing on the new feature cards

* apply prettier
2024-10-09 19:40:05 -06:00
Kelv
32e261ef73
DEV: Migrate user passwords data to UserPassword table (#28746)
* Add migrations to ensure password hash is synced across users & user_passwords

* Persist password-related data in user_passwords instead of users

* Merge User#expire_old_email_tokens with User#expire_tokens_if_password_changed

* Add post deploy migration to mark password-related columns from users table as read-only

* Refactored UserPassword#confirm_password? and changes required to accommodate hashing the password after validations
2024-10-10 09:23:06 +08:00
Alan Guo Xiang Tan
c1f25cdf5b
FIX: Unicorn master and Sidekiq reopening logs at the same time (#29137)
In our production environment, we have been seeing Sidekiq processes
getting stuck randomly when a USR1 signal is sent to the Unicorn master
process. We have not been able to identify the root cause of why the
Sidekiq process gets stuck. We however noticed that when the Unicorn
master process receives a USR1 signal, it will reopen the logs for the
Unicorn master process first before sending a USR1 signal for the
Unicorn worker processes to reopen the logs. We figured that we should
do the same for the Sidekiq process as well when a USR1 signal.

In this commit, we introduce an arbitrary delay of 1 second before we
the Sidekiq process reopens its log files so as to allow enough time for the Unicorn
master to finish reopening it logs first.

We also do not send reopen logs for the Sidekiq process if the `DISCOURSE_LOG_SIDEKIQ`
env is not present because there is no need to reopen any logs.
2024-10-10 08:01:40 +08:00
Sérgio Saquetim
08d5cf01cd
FIX: Don't override other sidebar panels when opening/closing the chat drawer (#29144)
This commit fixes an issue where the following happens:

1. The user opens a page where an alternative sidebar panel is displayed like /admin or other page where a plugin is displaying an alternative sidebar like the `docs-categories` plugin
2. Clicking the chat icon in the header and opening the drawer, or if you just minimize chat into drawer after it opens full-screen
3. The alternative sidebar panel is lost and reverted to the main panel.
2024-10-09 20:29:19 -03:00
dependabot[bot]
85fa4b4cb1
Build(deps): Bump ember-template-imports from 4.1.2 to 4.1.3 (#29146)
Bumps [ember-template-imports](https://github.com/ember-template-imports/ember-template-imports) from 4.1.2 to 4.1.3.
- [Release notes](https://github.com/ember-template-imports/ember-template-imports/releases)
- [Changelog](https://github.com/ember-cli/ember-template-imports/blob/master/CHANGELOG.md)
- [Commits](https://github.com/ember-template-imports/ember-template-imports/commits)

---
updated-dependencies:
- dependency-name: ember-template-imports
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-09 23:41:00 +02:00
dependabot[bot]
335ad55e1e
Build(deps-dev): Bump the embroider group with 4 updates (#29145)
Bumps the embroider group with 4 updates: [@embroider/compat](https://github.com/embroider-build/embroider/tree/HEAD/packages/compat), [@embroider/core](https://github.com/embroider-build/embroider/tree/HEAD/packages/core), [@embroider/macros](https://github.com/embroider-build/embroider/tree/HEAD/packages/macros) and [@embroider/webpack](https://github.com/embroider-build/embroider/tree/HEAD/packages/webpack).


Updates `@embroider/compat` from 3.6.3 to 3.6.4
- [Release notes](https://github.com/embroider-build/embroider/releases)
- [Changelog](https://github.com/embroider-build/embroider/blob/main/CHANGELOG.md)
- [Commits](https://github.com/embroider-build/embroider/commits/HEAD/packages/compat)

Updates `@embroider/core` from 3.4.17 to 3.4.18
- [Release notes](https://github.com/embroider-build/embroider/releases)
- [Changelog](https://github.com/embroider-build/embroider/blob/main/CHANGELOG.md)
- [Commits](https://github.com/embroider-build/embroider/commits/HEAD/packages/core)

Updates `@embroider/macros` from 1.16.7 to 1.16.8
- [Release notes](https://github.com/embroider-build/embroider/releases)
- [Changelog](https://github.com/embroider-build/embroider/blob/main/CHANGELOG.md)
- [Commits](https://github.com/embroider-build/embroider/commits/HEAD/packages/macros)

Updates `@embroider/webpack` from 4.0.6 to 4.0.7
- [Release notes](https://github.com/embroider-build/embroider/releases)
- [Changelog](https://github.com/embroider-build/embroider/blob/main/CHANGELOG.md)
- [Commits](https://github.com/embroider-build/embroider/commits/HEAD/packages/webpack)

---
updated-dependencies:
- dependency-name: "@embroider/compat"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: embroider
- dependency-name: "@embroider/core"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: embroider
- dependency-name: "@embroider/macros"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: embroider
- dependency-name: "@embroider/webpack"
  dependency-type: direct:development
  update-type: version-update:semver-patch
  dependency-group: embroider
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-09 23:40:10 +02:00
Gabriel Grubba
53f9c81790
FEATURE: add trigger_with_pms option to topic tags changed automation trigger (#29122) 2024-10-09 09:51:40 -03:00
Ella E.
19fb8b8d57
FIX: Adjustments to the admin sidebar following recent core sidebar styling changes (#29138) 2024-10-08 22:11:07 -06:00
Alan Guo Xiang Tan
27c34915ae
DEV: Fix flaky request tracker system spec (#29136)
`Date.today` relies on the system's timezone instead of
`Rails.configuration.time_zone`. This can cause tests to fail when we
assert against the date of a record. Just use `Time.zone.today` instead
so that we always follow `Rails.configuration.time_zone`.
2024-10-09 07:53:08 +08:00
Alan Guo Xiang Tan
ed6c9d1545
DEV: Call Discourse.redis.flushdb after the end of each test (#29117)
There have been too many flaky tests as a result of leaking state in
Redis so it is easier to resolve them by ensuring we flush Redis'
database.

Locally on my machine, calling `Discourse.redis.flushdb` takes around
0.1ms which means this change will have very little impact on test
runtimes.
2024-10-09 07:19:31 +08:00