Commit Graph

1230 Commits

Author SHA1 Message Date
Tusooa Zhu bd0eb1c675
Make activity search properly use GIN indexes
The original approach to search in GIN indexes is to use
`to_tsvector(text)` in the WHERE clause of the query. According to
postgres docs [pdoc], this method does not make use of the index,
while `to_tsvector(config, text)` does. This commit changed the
query to use the two-argument `to_tsvector()`.

[pdoc]: https://www.postgresql.org/docs/12/textsearch-tables.html

To obtain the search config in use, we make a query to the db first.
The `::regconfig::oid` hack is needed because Postgrex does not support
regconfig type directly [postgrexbug]. I use the conversion from and to
`oid` instead of `text` because I tested in the actual DB and querying
using the conversion via `text` is slow just as the one-argument
`to_tsvector()` variant.

[postgrexbug]: https://github.com/elixir-ecto/postgrex/issues/502

Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3519

Closes: https://git.pleroma.social/pleroma/pleroma/-/issues/2758
2021-08-28 18:26:04 +02:00
Ilja 53b0dd4ecc
List available frontends also when no static/frontends folder is present yet
* To see what front ends are installed, it ls static/frontends. When this folder doesn't exists yet, it will return an empty array.
* Installing still works since the folder is created during installation already

Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3510
2021-08-28 18:23:49 +02:00
Sam Therapy 09c42ce13e
Add Admin-FE menu for StealEmojiPolicy
Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3512
2021-08-28 18:21:59 +02:00
Tusooa Zhu a80cb58ac1
Add changelog for !3519 2021-08-27 22:31:22 -04:00
Alex Gleason 01175ef498
Streamer: fix crash in MastodonAPI.StatusView
Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3508
2021-08-13 17:58:03 +02:00
Haelwenn (lanodan) Monnier 27e1e4c742
Activity.Search: fallback on status resolution on DB Timeout
Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3507
2021-08-13 17:57:50 +02:00
Alex Gleason e117551169
AdminAPI: hotfix for nil report objects
Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3504
2021-08-13 17:57:39 +02:00
Haelwenn (lanodan) Monnier bb2d5879cc
maybe_notify_subscribers: Don't create notifications from ingested replies
Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3505
2021-08-13 17:57:19 +02:00
Haelwenn (lanodan) Monnier 0e2aebd036
TwitterAPI: Make change_email require body params instead of query
Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3503
2021-08-13 17:57:11 +02:00
Haelwenn (lanodan) Monnier 3961422f85
TwitterAPI: Make change_password require body params instead of query
Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3503
2021-08-13 17:56:59 +02:00
Haelwenn (lanodan) Monnier 8baaa36a16
ObjectAgePolicy: Fix pattern matching on published
Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3500
2021-08-13 17:56:46 +02:00
kPherox 34606d609d
fix: stream out Create Activity
Backport of: https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3499
2021-08-13 17:54:51 +02:00
rinpatch 7afabe1cc6 Merge branch 'bugfix/status-search-fallback' into 'develop'
Activity.Search: resolve status on DB Timeout

Closes #2566

See merge request pleroma/pleroma!3507
2021-08-13 12:09:39 +00:00
Haelwenn (lanodan) Monnier 6455b967ec
Activity.Search: fallback on status resolution on DB Timeout 2021-08-12 10:35:32 +02:00
Haelwenn 3ca39ccf69 Merge branch 'bugfix/subscriptions-replies' into 'develop'
maybe_notify_subscribers: Normalize Object to check inReplyTo presence

Closes #2732

See merge request pleroma/pleroma!3505
2021-08-11 18:50:39 +00:00
Haelwenn (lanodan) Monnier 436fac3bac
maybe_notify_subscribers: Don't create notifications from ingested messages 2021-08-11 20:49:38 +02:00
Haelwenn 901204df22 Merge branch 'poll-notification' into 'develop'
MastodonAPI: Support poll notification

See merge request pleroma/pleroma!3484
2021-08-09 10:02:37 +00:00
Haelwenn 6384d78035 Merge branch 'simple_policy_reasons_for_instance_specific_policies' into 'develop'
Simple policy reasons for instance specific policies

See merge request pleroma/pleroma!3314
2021-08-09 09:37:59 +00:00
Sean King 1841bd8383 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remove/mastofe 2021-08-06 08:08:20 -06:00
matildepark 469405b7b2
CHANGELOG.md: Fix instances of 2020 being actually 2021 2021-08-06 08:42:27 +02:00
Ilja cd706c0335
improve changelog entry 2021-08-06 07:59:54 +02:00
Ilja 9418424048
Add transparency_exclusions also to the breaking changes 2021-08-06 07:59:53 +02:00
Ilja 506bf16363
Change docs
* ./configuration/mrf.md
  * Change example
* ./configuration/cheatsheet.md
  * Change descriptions to include that a reason is given
* CHANGELOG.md
  * Add as breaking change
2021-08-06 07:59:53 +02:00
Alex Gleason e311c60923
CHANGELOG: moderator abilities 2021-08-05 11:11:27 -05:00
Haelwenn (lanodan) Monnier 79e993cae5
Release 2.4.0 2021-08-01 08:26:39 +02:00
Alex Gleason 3d8ce61fe5
CHANGELOG: fixed JSON error rendering 2021-07-27 08:30:38 -05:00
Alex Gleason 85d71d4f1d
CHANGELOG: Support `poll` notification type 2021-07-18 11:49:25 -05:00
Alex Gleason c4efe0d2d6
CHANGELOG: instance deletion 2021-07-17 15:05:20 -05:00
feld 3f58213646 Merge branch 'admin-api-users-sort' into 'develop'
AdminAPI: sort new users at the top

Closes #2709

See merge request pleroma/pleroma!3481
2021-07-14 14:39:14 +00:00
Alex Gleason 117b3edf54
CHANGELOG: AdminAPI return date with users 2021-07-14 09:03:44 -05:00
Alex Gleason 5681a007d7
CHANGELOG: AdminAPI users sort 2021-07-13 22:48:32 -05:00
Alex Gleason 65514484cc
CHANGELOG: fixed user deletion database timeout 2021-07-12 16:59:54 -05:00
Haelwenn (lanodan) Monnier 6dc78f5f6f
AP C2S: Remove restrictions and make it go through pipeline 2021-07-12 06:49:41 +02:00
Sean King 5d279a22b1 Merge develop branch upstream 2021-07-10 11:04:16 -06:00
Mark Felder 64d009693e Update Linkify to fix crash on posts with a URL we failed to parse correctly 2021-07-08 12:33:17 -05:00
Alex Gleason 310ef6b70d
Deletions: change User.purge/1 to defp, add CHANGELOG entry 2021-06-30 12:25:20 -05:00
Mark Felder d12e62c0b6 Add new Twittercard/OGP changes 2021-06-09 11:56:54 -05:00
Mark Felder 8443f82247 Update scope of AnalyzeMetadata features 2021-06-08 12:56:03 -05:00
feld 9a357d63f0 Update CHANGELOG.md 2021-06-07 20:07:59 +00:00
feld 10abbf13ba Update CHANGELOG.md 2021-06-07 20:07:27 +00:00
feld 84f42b92f0 Merge branch 'develop' into 'fix/prune-hashtags'
# Conflicts:
#   CHANGELOG.md
2021-06-07 20:06:36 +00:00
feld 4ca380490f Update CHANGELOG.md 2021-06-07 20:05:18 +00:00
feld c31338abe6 Update CHANGELOG.md 2021-06-07 20:04:27 +00:00
Mark Felder eb150e7d88 Document OTP 24 support so we remember to add it to the official release notes / announcement 2021-06-04 15:50:10 -05:00
Sean King dc4814f0cd
Fix merge conflicts with upstream 2021-06-04 14:42:44 -06:00
Haelwenn 0c56f9de0d Merge branch 'tests/openapi-everywhere' into 'develop'
Put OpenAPI ~everywhere in tests

See merge request pleroma/pleroma!3324
2021-06-04 18:53:09 +00:00
Mark Felder d6432a65da Move shout configuration from :instance, update docs and changelog 2021-06-01 11:49:46 -05:00
Mark Felder ff00b354fa Rename the non-federating Chat feature to Shout 2021-06-01 11:49:14 -05:00
feld 359ded086c Merge branch 'simplepolicy-announce-leak' into 'develop'
SimplePolicy: filter nested objects, fixes #2582

Closes #2582

See merge request pleroma/pleroma!3376
2021-05-28 19:05:13 +00:00
Mark Felder cd4352a86f Missing entry for pinned posts federation from MR !3312 2021-05-27 12:20:21 -05:00
Mark Felder 05d678c070 Expose user email address to user/owner; not publicly. 2021-05-20 12:50:43 -05:00
Mark Felder 2d7f6ce6fb Clarify AttachmentMetadata changes 2021-05-18 16:46:51 -05:00
Mark Felder c64cbee26c Fixed checking for Upload Filter required commands 2021-05-18 16:28:21 -05:00
Mark Felder 9b6b5ac196 Rename upload filter to AnalyzeMetadata 2021-05-18 15:33:33 -05:00
Alex Gleason 5a57b025c7
Changelog: attachment meta 2021-05-12 20:15:33 -05:00
Alex Gleason cea44b6b3e
Merge remote-tracking branch 'upstream/develop' into simplepolicy-announce-leak 2021-05-07 12:40:45 -05:00
Alex Gleason b15c4629ff
CHANGELOG: notice routes 2021-05-05 14:51:29 -05:00
feld 745375bdcf Merge branch 'dont-crash-email-settings' into 'develop'
Don't crash so hard when email settings are invalid

Closes #2606

See merge request pleroma/pleroma!3400
2021-05-04 13:30:00 +00:00
Alex Gleason 90770e0841
CHANGELOG: don't crash so hard when email settings are invalid 2021-05-03 14:43:34 -05:00
Alex Gleason dca87c5e7b
CHANGELOG: markdown 2021-05-01 11:28:06 -05:00
Alex Gleason 20878c7f99
CHANGELOG: SimplePolicy embedded objects are now checked 2021-04-30 14:22:02 -05:00
Alex Gleason 8c1d6e8839
CHANGELOG: Return OAuth token `id` 2021-04-29 12:20:46 -05:00
Alex Gleason 762be6ce10
Merge remote-tracking branch 'upstream/develop' into block-behavior 2021-04-29 11:14:32 -05:00
Mark Felder d7a71a275a Fixed pleroma.user delete_activities mix task. 2021-04-22 10:15:50 -05:00
Sean King 2780cdd4e7
Add CHANGELOG entry 2021-04-19 16:06:19 -06:00
Sean King a787fed8f7
Move changelog around 2021-04-16 15:50:17 -06:00
Sean King bf9c4f5289
Add note about Mastodon FE being removed from Pleroma in changelog 2021-04-15 23:39:33 -06:00
feld 0a7c2a32ba Merge branch 'develop' into 'fix/notifsettings-breaking-login'
# Conflicts:
#   CHANGELOG.md
2021-04-15 14:59:26 +00:00
Mark Felder 861f192852 Document fixed ability to save ConcurrentLimiter settings in ConfigDB 2021-04-13 14:39:44 -05:00
Mark Felder 9fbcdc15b1 Validate custom instance thumbnail set via AdminAPI produces correct URL 2021-04-13 10:52:53 -05:00
Mark Felder 31ce8a3730 Fix CHANGELOG entry meant for next release 2021-04-01 10:15:01 -05:00
Mark Felder 765f0907df Document user login failure fix for NULL notification_settings 2021-04-01 10:07:57 -05:00
Mark Felder 7eab98d5c8 Document new FollowBot MRF 2021-03-30 11:10:44 -05:00
Alexander Strizhakov ad907254fb changelog entry 2021-03-23 12:40:49 -05:00
rinpatch f930e83fa2 Merge branch 'fix/remove_auto_nsfw' into 'develop'
Remove sensitive setting #nsfw

See merge request pleroma/pleroma!3223
2021-03-19 08:48:22 +00:00
Haelwenn (lanodan) Monnier a22c53810b
Remove deprecated /api/qvitter/statuses/notifications/read 2021-03-15 06:47:07 +01:00
Ivan Tashkinov 946e0aab49 Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework 2021-03-10 07:48:50 +03:00
Haelwenn 7f413139fb Merge branch 'openapi/admin/user' into 'develop'
Add OpenAPI spec for AdminAPI.UserController

See merge request pleroma/pleroma!3355
2021-03-10 03:24:40 +00:00
Ivan Tashkinov 92526e0230 Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework 2021-03-07 11:34:39 +03:00
lain 10f402af6d Changelog: Re-add application support 2021-03-03 15:35:25 +01:00
lain c5352e90be Changelog, mix: merge in stable 2021-03-03 13:56:40 +01:00
Egor Kislitsyn 3aae5231b2
Add OpenAPI spec for AdminAPI.UserController 2021-03-02 20:49:17 +04:00
lain 7d790bb27b Changelog: Remove application support line. 2021-03-02 14:42:11 +01:00
Ivan Tashkinov 882dd46843 Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework 2021-03-02 08:26:30 +03:00
lain 9f71b63c2d Update changelog 2021-03-01 21:12:26 +01:00
Mark Felder 808e15b264 Document user agent leak fix 2021-03-01 21:05:58 +01:00
feld 8a563efdd8 Update CHANGELOG.md 2021-02-28 18:46:03 +00:00
lain 6a71aa535b Merge branch 'admin-api-versioning' into 'develop'
Pleroma APIs versioning

Closes #2509

See merge request pleroma/pleroma!3335
2021-02-28 16:22:22 +00:00
lain e6a14e1cd1 Merge branch 'feat/client_app_details' into 'develop'
Support application field

See merge request pleroma/pleroma!3311
2021-02-28 16:17:34 +00:00
Haelwenn (lanodan) Monnier 3bc7d12271
Remove sensitive-property setting #nsfw, create HashtagPolicy 2021-02-27 21:26:17 +01:00
Ivan Tashkinov 8f88a90ca3 Merge remote-tracking branch 'remotes/origin/develop' into feature/object-hashtags-rework
# Conflicts:
#	lib/pleroma/application.ex
#	lib/pleroma/config.ex
2021-02-23 13:58:35 +03:00
eugenijm c1d63bbd9a Reroute /api/pleroma to /api/v1/pleroma 2021-02-21 13:26:23 +03:00
Mark Felder e31274f51d Revert changelog entry that leaked from another branch. 2021-02-20 17:07:12 -06:00
Mark Felder 1cb417bce6 Document HeifToJpeg and its requirement of libheif's heic-convert tool 2021-02-20 14:32:14 -06:00
Alexander Strizhakov 1e6c27181e
expires_in in scheduled status params 2021-02-18 14:59:22 +03:00
rinpatch 6d66fadea7 Remove `:auth, :enforce_oauth_admin_scope_usage`
`admin` scope has been required by default for more than a year now
and all apps that use the API seems to request a proper scope by now.
2021-02-17 20:47:38 +03:00
Haelwenn e7b1f0f5f4 Merge branch 'feat/chat-list-pagination' into 'develop'
Chats: Introduce /api/v2/pleroma/chats which implements pagination

Closes #2140

See merge request pleroma/pleroma!3325
2021-02-17 15:36:59 +00:00
rinpatch 158f9f18ee Merge branch 'remove-conversation-api' into 'develop'
Add API endpoint to remove a conversation

Closes #2488

See merge request pleroma/pleroma!3321
2021-02-17 15:14:27 +00:00
rinpatch d7ad288c84 Chats: Introduce /api/v2/pleroma/chats which implements pagination
Also removes incorrect claim that /api/v1/pleroma/chats supports
pagination and deprecates it.

Closes #2140
2021-02-17 16:03:24 +03:00
Egor Kislitsyn cf6d3db58f
Add API endpoint to remove a conversation 2021-02-15 21:48:13 +04:00