Commit graph

938 commits

Author SHA1 Message Date
Haelwenn
4115701f71 Merge branch 'recipients-experiments' into 'develop'
ActivityPub: Don't show announces of your own objects in timeline.

See merge request pleroma/pleroma!2637
2020-06-12 16:57:13 +00:00
lain
e557265a03 Merge branch 'global-status-expiration' into 'develop'
Global status expiration

See merge request pleroma/pleroma!2208
2020-06-12 14:14:09 +00:00
lain
5d87405b51 ActivityPubTest: Update test for atomized parameters. 2020-06-10 16:55:30 +02:00
Thibaut Girka
570123ae21 Add test 2020-06-10 16:53:24 +02:00
lain
600e2ea073 ActivityPubTest: Make test easier to understand. 2020-06-10 12:15:56 +02:00
lain
9e411372d0 ActivityPub: Don't show announces of your own objects in timeline. 2020-06-10 12:10:09 +02:00
Egor Kislitsyn
d44843e677
Restrict ActivityExpirationPolicy to Notes only 2020-06-08 17:56:34 +04:00
Egor Kislitsyn
da22119c2f
Merge branch 'develop' into global-status-expiration 2020-06-08 17:21:47 +04:00
lain
3b5282bef2 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-06-08 11:19:18 +02:00
lain
7d66dd180a Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-06-08 10:18:10 +02:00
lain
2cdaac4330 SideEffects: Move streaming of chats to after the transaction. 2020-06-07 14:52:56 +02:00
lain
ca0e6e702b ChatMessageReference -> Chat.MessageReference 2020-06-06 11:51:10 +02:00
Egor Kislitsyn
b02df1803e
Merge remote-tracking branch 'origin/develop' into activity-pub-use-atoms-as-keys 2020-06-05 23:15:10 +04:00
lain
115d08a754 Pipeline: Add a side effects step after the transaction finishes
This is to run things like streaming notifications out, which will
sometimes need data that is created by the transaction, but is
streamed out asynchronously.
2020-06-05 16:47:02 +02:00
lain
0efa8aa0b9 Transmogrifier: For follows, create notifications last.
As the notification type changes depending on the follow state,
the notification should not be created and streamed out before the
state settles. For this reason, the notification creation has been
delayed until it's clear if the user has been followed or not.

This is a bit hacky but it will be properly rewritten using the
pipeline soon.
2020-06-05 12:26:07 +02:00
Egor Kislitsyn
317e2b8d61
Use atoms as keys in ActivityPub.fetch_* functions options 2020-06-04 21:36:26 +04:00
lain
74edd4f391 Merge branch 'remake-remodel-dms' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-06-04 19:24:07 +02:00
lain
56dfa0e0fb Transmogrifier: Update notification after accepting. 2020-06-04 19:22:49 +02:00
lain
41503b1673 Apply suggestion to test/web/activity_pub/transmogrifier/chat_message_test.exs 2020-06-04 15:16:10 +00:00
lain
00748e9650 ChatMessageReferences: Change seen -> unread 2020-06-04 17:14:42 +02:00
lain
5d7dda883e SideEffectsTest: More tests. 2020-06-04 14:46:41 +02:00
lain
fb4ae9c720 Streamer, SideEffects: Stream out ChatMessageReferences
Saves us a few calles to fetch things from the DB that we already
have.
2020-06-03 16:45:04 +02:00
lain
7f5c5b11a5 Chats: Remove unread from the db, calculate from unseen messages. 2020-06-03 14:26:50 +02:00
lain
aa22fce8f4 ChatMessageReference: Introduce and switch in chat controller. 2020-06-03 12:30:12 +02:00
Egor Kislitsyn
a7627bdc7a
Merge remote-tracking branch 'origin/develop' into global-status-expiration 2020-06-01 15:48:51 +04:00
lain
6ff079ca9f Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-30 12:31:12 +02:00
lain
2c9465cc51 SafeText: Let through basic html. 2020-05-30 12:17:18 +02:00
Haelwenn (lanodan) Monnier
a43b435c0a
AP C2S: allow limit & order on outbox & read_inbox 2020-05-29 16:14:45 +02:00
Haelwenn (lanodan) Monnier
b3b367b894
Bugfix: Reuse Controller.Helper pagination for APC2S 2020-05-29 16:14:45 +02:00
lain
863c02b25d SideEffects: Stream out chat messages. 2020-05-29 15:44:03 +02:00
lain
9848978109 Merge branch 'fix-relay-repeat-notification' into 'develop'
Fix relay repeat notification

See merge request pleroma/pleroma!2590
2020-05-29 10:42:49 +00:00
lain
af6d01ec93 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-29 12:36:17 +02:00
kPherox
48fd9be65a
Exclude post actor from to of relay announce 2020-05-27 23:51:15 +09:00
rinpatch
d35be02e70 Merge branch 'refactor-add-mention-step-one' into 'develop'
Fix ObjectView calling into strange functions

Closes #1807

See merge request pleroma/pleroma!2580
2020-05-27 14:17:12 +00:00
lain
2c25087d20 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-25 16:52:03 +02:00
lain
6bd7070b00 Transmogrifier: Use a simpler way to get mentions. 2020-05-25 15:08:43 +02:00
lain
f20dff451e Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into 1808-pleroma-sucks 2020-05-25 14:01:16 +02:00
lain
5d5db7e5b7 StealEmojiPolicyTest: Clean up. 2020-05-25 14:00:18 +02:00
lain
2dff376041 StealEmojiPolicyTest: Fix flaky test. 2020-05-25 13:58:14 +02:00
lain
ee35bb5ac2 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-25 13:57:27 +02:00
lain
aeb0875025 StealEmojiPolicyTest: Fix flaky test. 2020-05-25 13:48:47 +02:00
lain
d0c26956da User: Don't error out if we want to refresh a user but can't 2020-05-25 12:46:14 +02:00
lain
355aa3bdc7 ActivityPubController: Add Mastodon activity compat route. 2020-05-22 17:06:12 +02:00
lain
ca755f9a73 ActivityPubController: Add Mastodon compatibility route. 2020-05-22 16:15:29 +02:00
Haelwenn
7b02bfca51 Merge branch 'announce-validator' into 'develop'
Announce validator

See merge request pleroma/pleroma!2567
2020-05-22 05:47:53 +00:00
lain
578ed3a37f Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-21 15:35:13 +02:00
lain
a42a0716ec Merge branch 'features/emoji_stealer' into 'develop'
MRF.StealEmojiPolicy: New Policy

See merge request pleroma/pleroma!2385
2020-05-21 13:31:49 +00:00
lain
cc0d462e91 Attachments: Have the mediaType on the root, too. 2020-05-21 15:08:56 +02:00
lain
814c3e5171 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-21 15:00:05 +02:00
lain
bf1b221f94 Credo fixes for the credo god. 2020-05-21 14:12:32 +02:00
lain
cdc6ba8d7b AnnounceValidator: Check for announcability 2020-05-21 13:58:18 +02:00
lain
c76267afb9 Credo fixes. 2020-05-21 13:31:52 +02:00
lain
23e248694d Announcements: Fix all tests. 2020-05-21 13:16:21 +02:00
lain
d9d425708e SideEffects: Builed out Announce effects. 2020-05-21 12:43:09 +02:00
lain
39031f4860 Pipeline: Don't federate if federation is disabled. 2020-05-20 16:36:55 +02:00
lain
e42bc5f557 Announcements: Handle through common pipeline. 2020-05-20 15:44:37 +02:00
lain
c7cdc553ff Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into announce-validator 2020-05-20 14:02:40 +02:00
lain
423ea497bb Merge branch 'feature/1734-user-deletion' into 'develop'
User deletion

Closes #1734

See merge request pleroma/pleroma!2493
2020-05-20 11:43:49 +00:00
lain
d19c716770 AttachmentValidator: Handle empty mediatypes 2020-05-18 20:17:28 +02:00
lain
be4db41d71 ChatMessageValidator: Allow one message in an array, too. 2020-05-18 18:45:33 +02:00
lain
0d5bce018d AnnounceValidator: Validate for existing announce 2020-05-18 16:54:10 +02:00
lain
17a8342c1e ObjectValidators: Add basic Announce validator. 2020-05-18 16:45:11 +02:00
lain
63ab2743ce TransmogrifierTest: Fix tests. 2020-05-18 15:47:26 +02:00
lain
7d381b16b7 Transmogrifier Test: Extract Announce handling. 2020-05-18 14:48:37 +02:00
lain
baf051a59e SideEffects: Don't update unread count for actor in chatmessages. 2020-05-17 12:22:26 +02:00
lain
f012c3a202 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-15 13:33:04 +02:00
Haelwenn (lanodan) Monnier
e688d4ee69
MRF.StealEmojiPolicy: New Policy
Inspired by https://git.pleroma.social/moonman/emoji-stealer-mrf/-/blob/master/steal_emoji_policy.ex
2020-05-14 09:59:56 +02:00
Egor Kislitsyn
6802dc28ba
Add OpenAPI spec for PleromaAPI.AccountController 2020-05-13 19:06:46 +04:00
lain
0f0acc740d Chat: Allow posting without content if an attachment is present. 2020-05-13 15:31:28 +02:00
lain
3cff4e24cd Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-13 12:44:16 +02:00
Egor Kislitsyn
7803a85d2c
Add OpenAPI spec for StatusController 2020-05-13 00:25:21 +04:00
rinpatch
24c8c13640 Merge branch '1757-blocks-breaking-on-disabled-outgoing-blocks' into 'develop'
ActivityPub: Fix non-federating blocks.

Closes #1757

See merge request pleroma/pleroma!2514
2020-05-12 16:45:46 +00:00
rinpatch
4cc71aad65 Merge branch '1748-remote-following-follower-count' into 'develop'
Transmogrifier: On incoming follow accept, update follow counts.

Closes #1748

See merge request pleroma/pleroma!2515
2020-05-12 16:44:58 +00:00
lain
dfb90a1fd6 Transmogrifier: Add tests for certain announces 2020-05-12 12:50:48 +02:00
lain
ca31af473c Transmogrifier: On incoming follow accept, update follow counts. 2020-05-12 12:29:37 +02:00
lain
d0ba1844b0 ActivityPub: Fix non-federating blocks. 2020-05-12 10:52:46 +02:00
lain
f28ed36b4d Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-11 17:14:58 +02:00
lain
679afb2de4 SideEffects test: Add test for favorite deletion. 2020-05-11 15:38:19 +02:00
lain
5367a00257 Deletion: Handle the case of pruned objects. 2020-05-11 15:06:23 +02:00
Alexander Strizhakov
287f781808
user deletion 2020-05-08 17:11:17 +03:00
lain
7637ef4203 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-08 13:13:37 +02:00
lain
fbcc53760e Merge branch 'feature/emojireactvalidator' into 'develop'
Move EmojiReacts to the Pipeline.

See merge request pleroma/pleroma!2473
2020-05-08 10:41:41 +00:00
lain
7e9aaa0d02 Transmogrifier tests: Remove more double tests. 2020-05-08 11:43:07 +02:00
lain
f1274c3326 Transmogrifier tests: Remove double tests. 2020-05-08 11:41:13 +02:00
Haelwenn
769d95644d Merge branch 'feature/restrict-c2s' into 'develop'
AP C2S: Restrict creation to `Note`s for now.

See merge request pleroma/pleroma!2472
2020-05-07 22:29:16 +00:00
lain
ef55d24054 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into feature/emojireactvalidator 2020-05-07 18:53:34 +02:00
lain
7ac0cffb34 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into feature/emojireactvalidator 2020-05-07 15:03:12 +02:00
lain
788b7e7bbd Merge fixes. 2020-05-07 14:52:37 +02:00
lain
f0c22df226 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into feature/undo-validator-reduced 2020-05-07 14:45:20 +02:00
lain
1748e26948 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-06 17:36:08 +02:00
rinpatch
473b0d9f3d Merge branch 'feature/delete-validator' into 'develop'
Move deletions to the common pipeline

Closes #1497

See merge request pleroma/pleroma!2441
2020-05-06 14:32:58 +00:00
lain
fc9d0b6eec Credo fixes. 2020-05-06 16:31:21 +02:00
lain
20baa2eaf0 ChatMessages: Add attachments. 2020-05-06 16:12:36 +02:00
lain
205313e541 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-06 11:44:30 +02:00
lain
df846eda71 Merge branch 'bugfix/sensitive_object' into 'develop'
Transmogrifier.set_sensitive/1: Keep sensitive set to true

Closes #954

See merge request pleroma/pleroma!2470
2020-05-06 09:04:13 +00:00
lain
92caae5923 Undoing: Move undoing blocks to the pipeline everywhere. 2020-05-05 18:02:24 +02:00
lain
a3bb2e5474 Undoing: Move undoing announcements to the pipeline everywhere. 2020-05-05 16:42:34 +02:00
lain
b34debe615 Undoing: Move undoing reactions to the pipeline everywhere. 2020-05-05 16:17:09 +02:00
lain
a3071f0231 Undoing: Move undoing likes to the pipeline everywhere. 2020-05-05 15:08:41 +02:00
lain
f1da8882f9 UndoValidator: Add UndoValidator. 2020-05-05 14:17:47 +02:00
lain
8b2457bdbf Transmogrifier tests: Extract Undo handling 2020-05-05 13:25:34 +02:00
Egor Kislitsyn
decaa64f75
Merge branch 'develop' into global-status-expiration 2020-05-05 14:28:54 +04:00
lain
db55dc9445 ActivityPub: Remove react_with_emoji. 2020-05-05 12:28:28 +02:00
lain
ad771546d8 Transmogrifier: Move emoji reactions to common pipeline. 2020-05-05 12:11:46 +02:00
lain
142bf0957c Transmogrifier: Extract EmojiReact tests. 2020-05-05 11:20:53 +02:00
lain
c297667f16 Merge branch 'fix/issue-1729' into 'develop'
Only update follower/following stats for actor types of users and bots.

Closes #1565 and #1729

See merge request pleroma/pleroma!2464
2020-05-05 08:21:39 +00:00
lain
2cb3f8a8cf Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into feature/delete-validator 2020-05-05 10:19:01 +02:00
lain
6400998820 AP C2S: Restrict creation to Notes for now. 2020-05-05 10:12:37 +02:00
Haelwenn (lanodan) Monnier
bf0e41f0da
Transmogrifier.set_sensitive/1: Keep sensitive set to true 2020-05-04 23:36:00 +02:00
lain
c23cb8d37a Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-04 19:24:04 +02:00
lain
0f9bed022f LikeValidator: Fix up context. 2020-05-04 17:18:17 +02:00
lain
e03c301ebe LikeValidator: Fix up missing recipients. 2020-05-04 17:08:31 +02:00
lain
335aabc39c Transmogrifier tests: Extract like tests. 2020-05-04 14:45:28 +02:00
lain
ec24c70db8 ActivityPub: Don't fetch Application follower counts. 2020-05-04 14:22:54 +02:00
lain
c40afe5ba0 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-05-04 10:43:20 +02:00
lain
6c337489f4 Various testing fixes in relation to user deletion. 2020-05-03 13:01:19 +02:00
lain
6fb96f64c1 Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into feature/delete-validator 2020-05-03 12:55:29 +02:00
lain
4dfc617cdf Transmogrifier: Don't fetch actor that's guaranteed to be there. 2020-05-03 12:51:28 +02:00
rinpatch
e55876409b Deactivate local users on deletion instead of deleting the record
Prevents the possibility of re-registration, which allowed to read
DMs of the deleted account.

Also includes a migration that tries to find any already deleted
accounts and insert skeletons for them.

Closes pleroma/pleroma#1687
2020-05-02 19:05:13 +03:00
Ivan Tashkinov
2d07ed7747 [#1732] Made AP C2S :followers and :following endpoints serve on no auth
(as for related :api pipeline endpoints).
2020-05-02 18:28:04 +03:00
lain
44fbd09709 Merge branch 'issue/1577' into 'develop'
[#1577] fix mediaType of object

See merge request pleroma/pleroma!2372
2020-05-01 12:38:46 +00:00
lain
5f42e6629d DeleteValidator: Only allow deletion of certain types. 2020-05-01 13:34:47 +02:00
lain
32b8386ede DeleteValidator: Don't federate local deletions of remote objects.
Closes #1497
2020-04-30 21:23:18 +02:00
lain
999d639873 ActivityPub: Remove delete function.
This is handled by the common pipeline now.
2020-04-30 20:13:47 +02:00
lain
500f5ec14e SideEffects: On deletion, reduce the reply count cache 2020-04-30 19:47:13 +02:00
Haelwenn (lanodan) Monnier
f1523f9acd
Increase tests on AP C2S
Related: https://git.pleroma.social/pleroma/pleroma/-/issues/954
2020-04-30 18:56:57 +02:00
lain
ab60ee1776 SideEffects: On deletion, reduce the User note count. 2020-04-30 18:19:39 +02:00
lain
3d0dc58e2e SideEffectsTest: Test streaming. 2020-04-30 18:10:36 +02:00
lain
315b773dd9 ObjectValidator: Refactor. 2020-04-30 17:58:31 +02:00
lain
4500fdc04c DeleteValidator: Add internal helper field after validation. 2020-04-30 17:53:02 +02:00
lain
c9bfa51ea9 Credo fixes. 2020-04-30 15:58:37 +02:00
lain
417eed4a2b SideEffects: Handle deletions. 2020-04-30 15:57:27 +02:00
lain
1fb383f368 DeleteValidator: Deleting a user is valid. 2020-04-30 15:42:30 +02:00
lain
4dc5302f45 Transmogrifier: Handle incoming deletes for non-user objects. 2020-04-30 15:26:23 +02:00
lain
db184a8eb4 DeleteValidator: Mastodon sends unaddressed deletes. 2020-04-30 14:37:14 +02:00
lain
bd219ba7e8 Transmogrifier Tests: Extract deletion tests. 2020-04-30 14:14:00 +02:00
lain
503de4b8df ObjectValidator: Add validation for Deletes. 2020-04-29 19:09:51 +02:00
lain
b8056e69e0 Object Validator Types: Add Recipients. 2020-04-29 19:08:08 +02:00
lain
20587aa931 Chat message creation: Check actor. 2020-04-29 14:53:53 +02:00
lain
a88734a0a2 Transmogrifier: Fetch missing actors for chatmessages. 2020-04-29 14:25:33 +02:00
lain
e055b8d203 Pipeline: Always run common_pipeline in a transaction for now. 2020-04-29 13:45:50 +02:00
lain
0c491b904d Merge branch 'develop' of git.pleroma.social:pleroma/pleroma into remake-remodel-dms 2020-04-29 13:19:04 +02:00
Maksim Pechnikov
7bd187bc5e added test 2020-04-29 08:13:10 +03:00
Ivan Tashkinov
908cf22a6c Merge remote-tracking branch 'remotes/origin/develop' into automatic-authentication-and-instance-publicity-checks
# Conflicts:
#	lib/pleroma/web/mastodon_api/controllers/account_controller.ex
2020-04-28 19:56:20 +03:00
lain
dedffd100c Pipeline: Unify, refactor, DRY. 2020-04-28 17:29:54 +02:00
lain
abd0928229 CreateChatMessageValidator: Validate object existence 2020-04-28 16:45:28 +02:00
lain
6aa116eca7 Create activity handling: Flip it and reverse it
Both objects and create activities will now go through the common
pipeline and will be validated. Objects are now created as a side
effect of the Create activity, rolling back a transaction if it's
not possible to insert the object.
2020-04-28 16:26:19 +02:00
lain
906cf53ab9 Recipient Type: Cast all elements as ObjectIDs. 2020-04-28 13:38:02 +02:00
Egor Kislitsyn
764b4f95a8
Merge branch 'develop' into global-status-expiration 2020-04-28 14:13:53 +04:00
Maksim Pechnikov
ea5142b94b convert markdown content to html 2020-04-28 09:32:43 +03:00