Commit Graph

38688 Commits

Author SHA1 Message Date
2193d02433 PERF: Use PG headlines for blurb generation and highlighting for search. 2020-08-06 14:56:29 +08:00
ba482c251c FIX: stop sync of tracking state when list is filtered
This stops sync of tracking state when list is filtered, in the past this
would cause the tracking state to go off wack.

Additionally this introduces an alias for "filter=tracking", called "f=tracking"

This was done cause the term "filter" is used internally in 2 different ways
the main way is for /unread /new filtering.

Trying to also call a query param "filter" causes enormous amounts of
internal pain, this circumvents the issue.
2020-08-06 16:34:02 +10:00
255b0e9f14 PERF: Replace video and audio links in search blurb while indexing.
In the near future, we will be swtiching to PG headlines to generate the
search blurb. As such, we need to replace audio and video links in the
raw data used for headline generation. This also means that we avoid
replacing links each time we need to generate the blurb.
2020-08-06 12:25:03 +08:00
06ef87da51 DEV: Make rubocop happy. 2020-08-06 10:11:07 +08:00
ee5d8fba0c PERF: Optimize ActionView::Helpers::TextHelper#excerpt. 2020-08-06 09:59:20 +08:00
801a078105 Build(deps): Bump rubocop from 0.88.0 to 0.89.0
Bumps [rubocop](https://github.com/rubocop-hq/rubocop) from 0.88.0 to 0.89.0.
- [Release notes](https://github.com/rubocop-hq/rubocop/releases)
- [Changelog](https://github.com/rubocop-hq/rubocop/blob/master/CHANGELOG.md)
- [Commits](https://github.com/rubocop-hq/rubocop/compare/v0.88.0...v0.89.0)

Signed-off-by: dependabot-preview[bot] <support@dependabot.com>
2020-08-06 09:36:41 +08:00
ceb858c70a PERF: Release post_upload records when downloaded image is removed (#10379)
Previously we would unconditionally keep all images downloaded via pull_hotlinked_images, even if they are later removed from the post. This commit removes that logic, and relies on the existing link_post_uploads process to pick up the downloaded images in `cooked`. Specs are added to ensure this is working correctly for regular hotlinked images, and for oneboxes.
2020-08-06 10:06:34 +10:00
09254410ea FIX: Only raise proper "error" messages
Also support "1" for `QUNIT_FAIL_FAST` to make it consistent with other
arguments.
2020-08-05 16:27:06 -04:00
f1b6b1bd0e FIX: Pretender errors were being swallowed
Lots of test were broken and needed fixes.
2020-08-05 15:48:57 -04:00
b0564205d9 FIX: Raise errors for broken pretender responses in test mode 2020-08-05 15:48:56 -04:00
aa017f276f FIX: replace fullPath while rewriting the /my/ URLs.
And added the tests. Follow-up to cdca5a2ee44d39a89ebfca5cfbebb765cecdc882
2020-08-05 23:22:15 +05:30
0c8365a1a2 Improve output for QUnit tests in CI:
* Uses fewer lines of output
* Always outputs error at the end even if timeout
* Support for QUNIT_FAIL_FAST ENV var to quit at first failure
2020-08-05 13:43:14 -04:00
18e3339580 Quit tests early, output seed to easily reproduce failure 2020-08-05 12:21:16 -04:00
67e8bc5342 FEATURE - allow category group moderators to split/merge topics (#10351) 2020-08-05 10:33:25 -04:00
a68533b394 Update translations 2020-08-05 13:55:12 +00:00
b6e475a8f3 FIX: ensures shadow has last_posted_at before comparing to site setting (#10374) 2020-08-05 13:20:51 +02:00
cb12a721c4 REFACTOR: Refactor pull_hotlinked_images job
This commit should cause no functional change
- Split into functions to avoid deep nesting
- Register custom field type, and remove manual json parse/serialize
- Recover from deleted upload records

Also adds a test to ensure pull_hotlinked_images redownloads secure images only once
2020-08-05 12:14:59 +01:00
aee3c2c34d FIX: attempt to output a useful error message
currently AWS problems will just dump a stack trace
2020-08-05 17:49:42 +08:00
f4502d7739 DEV: Fix test 2020-08-05 12:11:57 +03:00
42f62a9e63 FIX: Shows all_results if current settings category has no results (#10358)
Searching for a specific setting only showed results from the current selected category. Before fixing fd02856, it automatically redirected the user to all_results. This was a problem because the redirect always happened and there was no way to share a link to a specific category.

The fix to this bug is to simply redirect the user to all_results if there are no results to be displayed.
2020-08-05 09:39:54 +02:00
850d5696f2 FIX: Disable concurrent migration for multisite:migrate.
Rails migration is not thread safe.
2020-08-05 15:12:56 +08:00
1d281353b6 FIX: Don't run seeds if multisite migration fails. 2020-08-05 15:12:56 +08:00
e8328968bb DEV: allow qunit:test to run concurrently
Previously we were fighting on pid file which makes it hard to run multiple
2020-08-05 16:57:12 +10:00
ee10002e20 FIX: excerpts larger than 999 are not supported
underlying column can only fit 1000 chars.
2020-08-05 16:20:36 +10:00
13feb300a8 FIX: Topic map was incorrectly counting assign actions (#10360)
The assign plugin is one of two situations where a post can be both a whisper and a small-action. Check the action_code field to filter out small-actions.
2020-08-05 11:51:28 +10:00
f78792c779 FEATURE: Add category_id to TopicViewWordpressSerializer (#10372) 2020-08-05 11:50:15 +10:00
8850f51fd0 FIX: Show "group members forbidden" message on mobile (#10370)
This commit fixes an oversight in commit 88359b0f167a16b9eb59a9315ceefa84e4c7ec7c.
2020-08-04 16:16:52 -07:00
eb619c8e98 prevent long email addresses from breaking admin table layout 2020-08-04 16:47:50 -04:00
0cda5b9d55 FEATURE: New plugin outlet for category-heading (#10363) 2020-08-04 12:52:43 -07:00
cdca5a2ee4 FIX: rewrite of /my/URL should work on sub directory site too. 2020-08-05 00:59:10 +05:30
4593bb60c5 FIX: allows to change a user group notification level (#10369)
The current code has an ambiguous name of "user" which is actually not a user model, the real user model is accessible on the model key of user.
2020-08-04 21:23:55 +02:00
fb91320cba UX: Refactor pikaday month prev/next button styling
And topic-list last poster halo effect
2020-08-04 14:39:25 -04:00
d0953dcda9 DEV: Fix watching plugin stylesheet changes locally
I broke this in e6dbb4fcf52fa74853ed45616dd7cbf620c7deca
2020-08-04 14:10:25 -04:00
a1ec711373 FIX: Previous fix comitted the wrong thing and was broken :( 2020-08-04 13:46:26 -04:00
6da7a97eee FIX: Exclude shared drafts from digests 2020-08-04 13:35:48 -04:00
1bef008a1e FIX: current value of flair icon missing in group manage UI 2020-08-04 12:41:14 -04:00
266c0c50d7 FIX: Load base color scheme when default theme is not set
Followup to c937afc
2020-08-04 12:15:07 -04:00
92b26ecbfb REFACTOR: Move Page title / focus / counts logic to service
We had a handful of methods attached to the root `Discourse` object
related to focus and notification counts.

This patch pulls them out into a service called `document-title` for
updating the title, and a component called `d-document` to attach
and listen for browser events related to focus.

It also removes some computed properties and observers in favor of plain
old Javascript objects.
2020-08-04 12:02:25 -04:00
14eec43889 DEV: Use CSS custom properties for colors in core plugins 2020-08-04 11:14:33 -04:00
b76731d722 FEATURE: Invite emails to groups from add member modal (#10308) 2020-08-04 10:02:01 -05:00
413fa49032 UX: Refactor lightbox hover drop shadow
For parity with auto dark mode switching, this includes a subtle effect in dark themes too.
2020-08-04 10:43:18 -04:00
25505978d0 FIX: Check if selectable avatar with SHA1 2020-08-04 16:20:16 +03:00
ef92b72ff6 DEV: ensure 'posts:reorder_posts' rake task work on single topic
when the topic_id argument is provided.
2020-08-04 14:57:49 +02:00
8a0478b97d DEV: adds plugin api to add custom recipients of a post revision (#10367)
* DEV: adds plugin api to add custom recipients of a post revision

Usage:

```
add_post_revision_notifier_recipients do |post_revision|
  [78]
end
```
2020-08-04 11:57:33 +02:00
712ab33ff8 DEV: fix 'posts:reorder' rake task
Running the reorder rake task was triggering the following error:

PG::UniqueViolation: ERROR:  duplicate key value violates unique constraint "post_timings_unique"

I re-worked the queries and refactored to use the same couple of queries for all similar tables/columns.
2020-08-04 11:07:07 +02:00
4c03a944f6 PERF: Move URI regexp in GroupSearchResults.blurb_for into constant
No need to generate the huge regexp over and over again.
2020-08-04 14:38:43 +08:00
1f7b44de67 DEV: Remove flaky secure optimized image spec 2020-08-04 16:29:41 +10:00
3b08b15855 PERF: Remove one extra call to Redis when searching. 2020-08-04 14:02:02 +08:00
5a3494b1e1 FIX: IMAP archive fix and group list mailbox code unification (#10355)
* Fixed an issue I introduced in the last PR where I am just archiving everything regardless of whether it is actually archived in Discourse man_facepalming
* Refactor group list_mailboxes IMAP code to use providers, add specs, and add provider code to get the correct prodivder
2020-08-04 14:19:57 +10:00
c937afc75e FEATURE: automatic dark mode (#10341)
A first step to adding automatic dark mode color scheme switching. Adds a new SCSS file at `color_definitions.scss` that serves to output all SCSS color variables as CSS custom properties. And replaces all SCSS color variables with the new CSS custom properties throughout the stylesheets. 

This is an alpha feature at this point, can only be enabled via console using the `default_dark_mode_color_scheme_id` site setting.
2020-08-03 22:57:10 -04:00