pleroma issueshttps://git.pleroma.social/pleroma/pleroma/-/issues2023-02-09T21:25:18Zhttps://git.pleroma.social/pleroma/pleroma/-/issues/3022URLs ending in ..mp3 are not detected as URLs2023-02-09T21:25:18ZJeff CliffURLs ending in ..mp3 are not detected as URLs# Environment info
<!-- Everything is optional and where applicable but the more information the better. -->
* Browser, version, OS, platform: Version 107.0.5304.110 (Official Build) snap (64-bit), Ubuntu 20.04 LTS
* Instance URL: shitp...# Environment info
<!-- Everything is optional and where applicable but the more information the better. -->
* Browser, version, OS, platform: Version 107.0.5304.110 (Official Build) snap (64-bit), Ubuntu 20.04 LTS
* Instance URL: shitposter.club es.shitposter.club
* Frontend version (see settings -> about): pleroma-fe@c807254d3eadbd57de292360c5200358261cbc0f pleroma-fe@b13d8f7e6339e877a38a28008630dc8ec64abcdf
* Backend version (see settings -> about): 2.4.53-9048-g0f77643d-shitposterclub 2.4.3
* Browser extensions (ublock, rikaichamp etc): uBlock Origin
* Known instance/user customizations (i.e. pleromafe mods/forks, instance styles etc) -> whatever moon uses
# Bug description & reproduction steps
https://example.to/something.mp3 is detected as a URL
https://example.to/something..mp3 is not
# Bug seriousness
* How annoying it is: not very
* How often does it happen: every time
* How many people does it affect: probably quite a few, but very infrequently
* Is there a workaround for it: hack into the website and change the filename of the remote file
Rationale: RFC 1738 's grammar seems to allow for this ie because it's a url -> httpurl -> hpath -> uchar -> unreserved -> .tusooatusooahttps://git.pleroma.social/pleroma/pleroma/-/issues/3021500 when registering on an instance with approval required2022-12-15T23:07:50Ztusooa500 when registering on an instance with approval required```
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | 05:34:11.485 [error] #PID<0.18175.63> running Pleroma.Web.Endpoint (connection #PID<0.18288.63>, stream id 1) terminated
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | Server: lm.k...```
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | 05:34:11.485 [error] #PID<0.18175.63> running Pleroma.Web.Endpoint (connection #PID<0.18288.63>, stream id 1) terminated
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | Server: lm.kazv.moe:80 (http)
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | Request: POST /api/v1/accounts
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | ** (exit) an exception was raised:
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | ** (ArgumentError) Unexpected tuple format, {"test", nil} cannot be formatted into a Recipeint.
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko |
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | The expected format is {name :: String.t() | nil, address :: String.t()}, where address cannot be empty.
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko |
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | (swoosh 1.3.11) lib/swoosh/email/recipient.ex:101: Swoosh.Email.Recipient.Tuple.format/1
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | (elixir 1.10.4) lib/enum.ex:1396: Enum."-map/2-lists^map/1-0-"/2
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | (swoosh 1.3.11) lib/swoosh/email.ex:359: Swoosh.Email.to/2
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | (pleroma 2.4.52-0-g55e37ba80) lib/pleroma/emails/user_email.ex:199: anonymous fn/1 in Pleroma.Emails.UserEmail.approval_pending_email/1
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | (pleroma 2.4.52-0-g55e37ba80) lib/pleroma/web/gettext.ex:115: Pleroma.Web.Gettext.with_locales_func/2
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | (pleroma 2.4.52-0-g55e37ba80) lib/pleroma/user.ex:910: Pleroma.User.send_user_approval_email/1
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | (pleroma 2.4.52-0-g55e37ba80) lib/pleroma/user.ex:890: Pleroma.User.post_register_action/1
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko | (pleroma 2.4.52-0-g55e37ba80) lib/pleroma/web/twitter_api/twitter_api.ex:53: Pleroma.Web.TwitterAPI.TwitterAPI.create_user/2
staging-pleroma_pleroma.1.hbfzmogn7f69@ruiko |
```tusooatusooahttps://git.pleroma.social/pleroma/pleroma/-/issues/3020SearchController search error on certain users2022-12-14T04:04:53ZRenn AkazaSearchController search error on certain users### Environment
* Installation type (OTP or From Source): OTP
* Pleroma version (could be found in the "Version" tab of settings in Pleroma-FE): v2.4.0, v2.4.4, v2.4.5-2
* Elixir version (`elixir -v` for from source installations, N/A f...### Environment
* Installation type (OTP or From Source): OTP
* Pleroma version (could be found in the "Version" tab of settings in Pleroma-FE): v2.4.0, v2.4.4, v2.4.5-2
* Elixir version (`elixir -v` for from source installations, N/A for OTP): N/A
* Operating system: Alpine Linux
* PostgreSQL version (`psql -V`): 15.1
### Bug description
Certain users cannot be found by searching the full name in the search bar like `@username@instance.tld` (Mastodon v3.5.2). Posting with `@username@instance.tld` mentioned will result in a 500 error. The replies from another user mentioning `@username@instance.tld` WILL present in my timeline, but clicking the username will bring me to the profile page in `instance.tld`.
To filter out the cause, I've tried the followings:
* From same local instance, try searching another user at the same remote instance: working
* From blob.cat (v2.2), trying searching `@username@instance.tld`: working
* From bae.st (v2.4), trying searching `@username@instance.tld`: working
* From a brand new instance I setup in another VPS, try searching `@username@instance.tld`: not working
* Upgrade my instance from v2.4.4 to v2.4.5-2, try searching: not working
* Upgrade PostgreSQL from 14 to 15.5: not working
* Downgrade my instace from v2.4.5-2 to v2.4.0: not working
Here are the logs generated by my server when trying to interact with the user:
Searching:
```
22:41:22.355 [error] Elixir.Pleroma.Web.MastodonAPI.SearchController search error: %FunctionClauseError{args: nil, arity: 1, clauses: nil, function: :"-pin_data_from_featured_collection/1-fun-0-", kind: nil, module: Pleroma.Web.ActivityPub.ActivityPub}
```
Mentioning:
```
22:52:20.531 request_id=xxxxxxxxxxxxxxxxxxxxxx[error] Internal server error: %Cachex.ExecutionError{message: "no function clause matching in anonymous fn/1 in Pleroma.Web.ActivityPub.ActivityPub.pin_data_from_featured_collection/1"}
22:52:20.531 request_id=xxxxxxxxxxxxxxxxxxxxxx[info] Sent 500 in 1104ms
22:52:20.534 [error] #PID<0.7890.0> running Pleroma.Web.Endpoint (connection #PID<0.7889.0>, stream id 1) terminated
Server: my.server.tld:80 (http)
Request: POST /api/v1/statuses
** (exit) an exception was raised:
** (Cachex.ExecutionError) no function clause matching in anonymous fn/1 in Pleroma.Web.ActivityPub.ActivityPub.pin_data_from_featured_collection/1
(cachex 3.3.0) lib/cachex.ex:1443: Cachex.unwrap_unsafe/1
(pleroma 2.4.5-2-gd8e32646) lib/pleroma/formatter.ex:24: Pleroma.Formatter.escape_mention_handler/4
(linkify 0.5.1) lib/linkify/parser.ex:389: Linkify.Parser.link_mention/4
(linkify 0.5.1) lib/linkify/parser.ex:444: Linkify.Parser.check_and_link_reducer/4
(elixir 1.10.4) lib/enum.ex:3686: Enumerable.List.reduce/3
(elixir 1.10.4) lib/enum.ex:2161: Enum.reduce_while/3
(linkify 0.5.1) lib/linkify/parser.ex:155: Linkify.Parser.do_parse/3
(linkify 0.5.1) lib/linkify/parser.ex:72: Linkify.Parser.parse/2
```https://git.pleroma.social/pleroma/pleroma/-/issues/3018Unified streaming endpoint2023-10-15T21:35:33ZtusooaUnified streaming endpointhttps://docs.joinmastodon.org/methods/streaming/#websocket
Here, send to server subscribe events to start receiving updates for those events.https://docs.joinmastodon.org/methods/streaming/#websocket
Here, send to server subscribe events to start receiving updates for those events.https://git.pleroma.social/pleroma/pleroma/-/issues/3017Public Timeline is showing random ancient posts2022-12-25T21:05:53ZLummy ShinePublic Timeline is showing random ancient posts<!--
### Precheck
* For support use https://git.pleroma.social/pleroma/pleroma-support or [community channels](https://git.pleroma.social/pleroma/pleroma#community-channels).
* Please do a quick search to ensure no similar bug has been ...<!--
### Precheck
* For support use https://git.pleroma.social/pleroma/pleroma-support or [community channels](https://git.pleroma.social/pleroma/pleroma#community-channels).
* Please do a quick search to ensure no similar bug has been reported before. If the bug has not been addressed after 2 weeks, it's fine to bump it.
* Try to ensure that the bug is actually related to the Pleroma backend. For example, if a bug happens in Pleroma-FE but not in Mastodon-FE or mobile clients, it's likely that the bug should be filed in [Pleroma-FE](https://git.pleroma.social/pleroma/pleroma-fe/issues/new) repository.
-->
### Environment
* From Source (the MIX_ENV one)
* Pleroma 2.4.3
* ELIXIR 1.13.0
* Debian
* PostgreSQL 11.16
### Bug description
The public timeline is showing posts far older than the recent posts it should be, they dont appear as new, so I dont think the DB is finding them fresh, and they are only in the public timeline.
I had initially assumed that it was a bug that would sort itself out once it caught up but there is no order to it that I can tell, theyre just random 1mo 4mo 1yo etc posts. It puts these old posts above newer posts, after about 4hrs of posts it jumps to an ancient one.
Viewing profiles directly does not have this issue, home timeline doesnt, and neither does TWKN.
I have restarted, updated and such and still have the issue.
(husky shows the same issue, so im assuming its a BE issue)
any help would be appreciated, thankshttps://git.pleroma.social/pleroma/pleroma/-/issues/3015Form for managing blocked / muted shows only 20 accounts2022-12-15T02:25:48ZpiggoForm for managing blocked / muted shows only 20 accountsProbably related to the DOS mitigation that nerfed search, with no way to load more than 20? Now the form is kinda unusable.
Also, oddly, when looking at blocked users, there is a button labelled Block rather than Unblock (same on the m...Probably related to the DOS mitigation that nerfed search, with no way to load more than 20? Now the form is kinda unusable.
Also, oddly, when looking at blocked users, there is a button labelled Block rather than Unblock (same on the mutes page)
this is stable 2.4.4 with stock fe
![Screenshot_20221203_122218](/uploads/519ef02111c160b437f7ff68211bc225/Screenshot_20221203_122218.png)https://git.pleroma.social/pleroma/pleroma/-/issues/3010pleroma_ctl migrate failure2022-12-14T04:07:27ZITwrxpleroma_ctl migrate failure<!--
### Precheck
* For support use https://git.pleroma.social/pleroma/pleroma-support or [community channels](https://git.pleroma.social/pleroma/pleroma#community-channels).
* Please do a quick search to ensure no similar bug has been ...<!--
### Precheck
* For support use https://git.pleroma.social/pleroma/pleroma-support or [community channels](https://git.pleroma.social/pleroma/pleroma#community-channels).
* Please do a quick search to ensure no similar bug has been reported before. If the bug has not been addressed after 2 weeks, it's fine to bump it.
* Try to ensure that the bug is actually related to the Pleroma backend. For example, if a bug happens in Pleroma-FE but not in Mastodon-FE or mobile clients, it's likely that the bug should be filed in [Pleroma-FE](https://git.pleroma.social/pleroma/pleroma-fe/issues/new) repository.
-->
### Environment
* Installation type: **OTP**
* Pleroma version: **2.4.4**
* Elixir version: **N/A**
* Operating system: **Alpine Linux 3.16.3 (LXC system container)**
* CPU Architecture: **X86_64**
* PostgreSQL version: **14.5**
### Bug description
trying to upgrade from 2.4.4 to 2.4.5
ran `su pleroma -s $SHELL -lc "./bin/pleroma_ctl update"` (docs comment doesn't say it will overwrite files btw...)
when running `su pleroma -s $SHELL -lc "./bin/pleroma_ctl migrate"` i got:
```
/opt/pleroma/erts-10.7.2.18/bin/erlexec: line 1: ELF+@�@@@@@���ȔȔ8�8�8���/H�H�H��P�td@�@�@���Q�tdR�td8�8�8���/lib/ld-musl-aarch64.so.16�@6������X��1: not found
/opt/pleroma/erts-10.7.2.18/bin/erlexec: line 2: syntax error: unterminated quoted string
```
thankshttps://git.pleroma.social/pleroma/pleroma/-/issues/3009TLS issue with remote instance?2022-11-29T17:44:42ZrobinTLS issue with remote instance?My Pleroma instances cannot lookup users on the Mastodon instance at defcon.social, and an account there can lookup but not follow users on my Pleroma instances.
This appears to be a TLS version issue; the following shows up in /var/log...My Pleroma instances cannot lookup users on the Mastodon instance at defcon.social, and an account there can lookup but not follow users on my Pleroma instances.
This appears to be a TLS version issue; the following shows up in /var/log/messages on my instance when one of their users tries to follow one of mine:
`Nov 28 12:09:06 bakunin mix[505650]: 12:09:06.367 [info] POST /users/spike/inbox
Nov 28 12:09:06 bakunin mix[505650]: 12:09:06.381 request_id=FyvYg4vbjf0Vby4AASS
B [warning] Description: 'Authenticity is not established by certificate path va
lidation'
Nov 28 12:09:06 bakunin mix[505650]: Reason: 'Option {verify, verify_peer} a
nd cacertfile/cacerts is missing'
Nov 28 12:09:06 bakunin mix[505650]: 12:09:06.463 [notice] TLS :client: In state
:hello received SERVER ALERT: Fatal - Protocol Version
Nov 28 12:09:06 bakunin mix[505650]: 12:09:06.463 request_id=FyvYg4vbjf0Vby4AASS
B [error] Could not decode user at fetch https://defcon.social/users/us3r1d, {:t
ls_alert, {:protocol_version, 'TLS client: In state hello received SERVER ALERT:
Fatal - Protocol Version\n'}}
Nov 28 12:09:06 bakunin mix[505650]: 12:09:06.466 request_id=FyvYg4vbjf0Vby4AASS
B [info] Sent 400 in 98ms`
The following shows up in /var/log/messages on my instance when one of my users tries to find one of theirs:
`Nov 28 12:18:02 bakunin mix[506229]: 12:18:02.889 [warning] Description: 'Authenticity is not established by certificate path validation'
Nov 28 12:18:02 bakunin mix[506229]: Reason: 'Option {verify, verify_peer} and cacertfile/cacerts is missing'
Nov 28 12:18:02 bakunin mix[506229]: 12:18:02.968 [notice] TLS :client: In state :hello received SERVER ALERT: Fatal - Protocol Version
Nov 28 12:18:02 bakunin mix[506229]: 12:18:02.970 [warning] Description: 'Authenticity is not established by certificate path validation'
Nov 28 12:18:02 bakunin mix[506229]: Reason: 'Option {verify, verify_peer} and cacertfile/cacerts is missing'
Nov 28 12:18:03 bakunin mix[506229]: 12:18:03.042 [notice] TLS :client: In state :hello received SERVER ALERT: Fatal - Protocol Version
Nov 28 12:18:03 bakunin mix[506229]: 12:18:03.210 request_id=FyvY_0hs7zT46yAAAStR [info] Sent 200 in 5397ms`https://git.pleroma.social/pleroma/pleroma/-/issues/3007Current "develop" OTP: Exec format error2022-12-06T09:02:02ZAndreas GroschangCurrent "develop" OTP: Exec format errorI recently updated my instance to develop branch because of constant 500 timeline fetching errors in 2.4.x that appear to have been fixed in develop. I tried out 2.4.5 to see if i still get the problem in that release. It was still broke...I recently updated my instance to develop branch because of constant 500 timeline fetching errors in 2.4.x that appear to have been fixed in develop. I tried out 2.4.5 to see if i still get the problem in that release. It was still broken so i upgraded to develop again. Unfortunately with the latest develop OTP amd64 release i get the dreaded `Exec format error`. As far as i understand, that usually means some CPU architecture mixup. Could you check if all is right with the OTP pleroma.zip ?https://git.pleroma.social/pleroma/pleroma/-/issues/3006Can't access translation site2022-11-30T21:18:19ZAhmad DakhlallahCan't access translation siteHello,
Me and others that are trying to join the translation site "translate.pleroma.social" are unable to login to the site.
I do use my Pleroma username and password, and I do get to the page where it asked me to authorize access to ...Hello,
Me and others that are trying to join the translation site "translate.pleroma.social" are unable to login to the site.
I do use my Pleroma username and password, and I do get to the page where it asked me to authorize access to my account but when I click "Authorize", it just redirect me back to "translate.pleroma.social" without signing me in.
![image](/uploads/9c4e0cae9386668ac60112d7bbba7098/image.png)
Also, regarding translation, how can I implement my own translation without first asking for it to be implemented using "translate.pleroma.social"?
How can I compile the JSON file into JS file without braking it?
I'm looking into tested it directly and I can't wait for Pleroma to implement every change that I might need to do.
Thank you!https://git.pleroma.social/pleroma/pleroma/-/issues/3005Migrate from Mastodon 42022-11-25T21:50:17ZAhmad DakhlallahMigrate from Mastodon 4Hello,
I've tried to migrate from Mastodon to Pleroma but it failed.
I know it's because I'm using a newer Mastodon and Pleroma versions.
Does anyone know of a script that can do so? Or are anyone here ready to do it for me as a paid ...Hello,
I've tried to migrate from Mastodon to Pleroma but it failed.
I know it's because I'm using a newer Mastodon and Pleroma versions.
Does anyone know of a script that can do so? Or are anyone here ready to do it for me as a paid gig?
I belive now that I've made a mistake starting with Mastodon (The most famous one for some reason), but when I tried Pleroma I've knew for sure it was a mistake. Now I have +160 users who trusts my server and they're asking for the things that Pleroma offers without anyway for me to migrate without setting them back to zero.
Anyway, I need a script, or someone to do it as paid service.
Thank you for the wonderful script and thank you, the community people!https://git.pleroma.social/pleroma/pleroma/-/issues/3003Move an account from Peroma to Mastodon2022-11-24T10:25:53ZoptikfluffelMove an account from Peroma to MastodonHey there, I found #1526 and wondered wether Pleroma can also do it the other way around.Hey there, I found #1526 and wondered wether Pleroma can also do it the other way around.https://git.pleroma.social/pleroma/pleroma/-/issues/3001Categorizing followed accounts to create custom feeds2022-12-31T06:06:57ZmatlagCategorizing followed accounts to create custom feedsThis is a feature request, not an issue.
Once you follow many accounts (and I read in other issues the number can get really high), things can be difficult to follow, and quite messy.
Some other social networks I won't mention address t...This is a feature request, not an issue.
Once you follow many accounts (and I read in other issues the number can get really high), things can be difficult to follow, and quite messy.
Some other social networks I won't mention address this with an algorithm.
I would rather propose an option to categorize the accounts we follow, and have then the option to have feeds showing only these categories. In a client taking advantage of the feature, that would translate in some feeds showing only a subset of the followed accounts matching the category (or categories), or multiple columns each showing a defined category.
For example, I would create a category "News" and put in the accounts of the news organizations I follow. A category for "[politic topic] activist", a category for "artists", "friends", etc.
Of course such a feature could be completely handled client side, but the benefit of server side is to be able to switch client without losing all the sorting done on maybe hundreds of accounts.https://git.pleroma.social/pleroma/pleroma/-/issues/2999follow_operation does not properly use BooleanLike2022-11-28T00:13:36Zavefollow_operation does not properly use BooleanLike### Environment
* Installation type (OTP or From Source): OTP
* Pleroma version (could be found in the "Version" tab of settings in Pleroma-FE): v2.4.4
* Elixir version (`elixir -v` for from source installations, N/A for OTP): N/A
* Ope...### Environment
* Installation type (OTP or From Source): OTP
* Pleroma version (could be found in the "Version" tab of settings in Pleroma-FE): v2.4.4
* Elixir version (`elixir -v` for from source installations, N/A for OTP): N/A
* Operating system: Alpine
* PostgreSQL version (`psql -V`): Not relevant
### Bug description
Similar to https://git.pleroma.social/pleroma/pleroma/-/issues/1782, caused by the way `mastodon.py` operates (sends a string, results in a 400 `reblogs - Invalid boolean. Got: string.`), effectively breaking follow functionality of the library.
The line in question that causes this is https://git.pleroma.social/pleroma/pleroma/-/blob/v2.4.4/lib/pleroma/web/api_spec/operations/account_operation.ex#L226 (and on develop, the one for `notify` too, a couple lines below), and can be fixed by changing `type: :boolean,` to `type: BooleanLike,`. All other parameters in this file use `BooleanLike`.
MR: !3787https://git.pleroma.social/pleroma/pleroma/-/issues/2998host/domain webfinger cfg ignored; workaround2022-12-30T00:24:24Zrobinhost/domain webfinger cfg ignored; workaroundAs mentioned in https://git.pleroma.social/pleroma/pleroma/-/issues/2985 , the current stable version ignores the host/domain config that would let a server masquerade its users as belonging to a domain rather than being attached to a ho...As mentioned in https://git.pleroma.social/pleroma/pleroma/-/issues/2985 , the current stable version ignores the host/domain config that would let a server masquerade its users as belonging to a domain rather than being attached to a hostname (@user@domain instead of @user@server.domain). But that issue's closed and I don't know the social conventions around commenting on closed issues. :-)
I was told on https://git.pleroma.social/pleroma/pleroma/-/merge_requests/3361 that this is fixed for the upcoming 2.5 release, but that's not scheduled yet and my employer is ready to migrate and really wants this feature so I've come up with a workaround that fools remote Mastodon instances but for some reason not Pleroma instances.
i.e. if you look me up as "@robin@pch.net" Mastodon instances find me and refer to me as that, but Pleroma instances find me and refer to me as "@robin@pleroma.pch.net".
Pleroma must be constructing it's idea of what a remote user is called from something other than the acct: response?
Here's how I've implemented a workaround (beyond setting up the redirect on the web server as described in the docs)); can someone please tell me why it works on remote Mastodon instances but not Pleroma ones?
(This is running on our instance at pleroma.pch.net, if you want to see it live.)
```
see comments for updated workaround; it got more complicated :-)
```
(This is very much a stone tools and ignorance workaround, and it will absolutely not scale, but this will only ever be a small instance and I can drop the workaround when 2.5 releases.)https://git.pleroma.social/pleroma/pleroma/-/issues/2992Compilation error in file lib/prometheus/registry.ex: UndefinedFunctionError2022-11-28T03:48:12ZChris MakenzieCompilation error in file lib/prometheus/registry.ex: UndefinedFunctionError### Environment
* Installation type: from source
* Pleroma version: 2.4.4 - 2022-08-19 (according to CHANGELOG.md)
* Elixir version: Elixir 1.14.1 (compiled with Erlang/OTP 25)
* Operating system: Linux Fedora 37
* PostgreSQL version: p...### Environment
* Installation type: from source
* Pleroma version: 2.4.4 - 2022-08-19 (according to CHANGELOG.md)
* Elixir version: Elixir 1.14.1 (compiled with Erlang/OTP 25)
* Operating system: Linux Fedora 37
* PostgreSQL version: psql (PostgreSQL) 14.3
### Bug description
Following the manual at https://docs-develop.pleroma.social/backend/installation/debian_based_en/.
When running:
```
sudo -Hu pleroma MIX_ENV=prod mix pleroma.instance gen
```
I get the following compilation error::
```
warning: `config/prod.secret.exs` not found. You may want to create one by running `mix pleroma.instance gen`
==> prometheus_ex
Compiling 19 files (.ex)
== Compilation error in file lib/prometheus/registry.ex ==
** (UndefinedFunctionError) function Kernel.Utils.defdelegate/2 is undefined or private. Did you mean:
* defdelegate_all/3
* defdelegate_each/2
(elixir 1.14.1) Kernel.Utils.defdelegate({:exists, [line: 21], [{:name, [line: 21], nil}]}, [])
lib/prometheus/registry.ex:21: (module)
could not compile dependency :prometheus_ex, "mix compile" failed. Errors may have been logged above. You can recompile this dependency with "mix deps.compile prometheus_ex", update it with "mix deps.update prometheus_ex" or clean it with "mix deps.clean prometheus_ex"
```
So the error gets thrown in line 21 of `./deps/prometheus_ex/lib/prometheus/registry.ex`. Unfortunately, I don't have any knowledge in Elexir, otherwise I would try to bug-track it.https://git.pleroma.social/pleroma/pleroma/-/issues/2986Cannot report a fake Create activity (the status is shown as nil)2022-12-09T14:25:27ZtusooaCannot report a fake Create activity (the status is shown as nil)## tl;dr
Ok, after several months I finally found out the root cause of `nil` statuses in reports.
## Reproducing
0. Post something from a remote account. Ensure no local user is following that account.
1. Search for the object id of t...## tl;dr
Ok, after several months I finally found out the root cause of `nil` statuses in reports.
## Reproducing
0. Post something from a remote account. Ensure no local user is following that account.
1. Search for the object id of that post on the local server.
2. Report it from the local server:
```
Pleroma.Web.CommonAPI.report(Pleroma.User.get_by_nickname("SWwind"), %{account_id: "ABIJ0dpJ3vVdlYH8nA", status_ids: ["APYKvAICWGDa2B0Dei"], comment: "foobar", forward: false})
```
3. And we get
```
{:ok,
%Pleroma.Activity{
__meta__: #Ecto.Schema.Metadata<:loaded, "activities">,
actor: "https://kazv.moe/users/SWwind",
bookmark: #Ecto.Association.NotLoaded<association :bookmark is not loaded>,
data: %{
"actor" => "https://kazv.moe/users/SWwind",
"cc" => [],
"content" => "foobar",
"context" => "https://kazv.moe/contexts/031af056-8ba6-4cc4-9143-f3e29687ad6f",
"id" => "https://kazv.moe/activities/64e29e98-2039-49e7-b720-a91975020dca",
"object" => [
"https://lm.kazv.moe/users/testuser",
%{"deleted" => true, "id" => nil}
],
"published" => "2022-11-13T06:46:53.296688Z",
"state" => "open",
"to" => [],
"type" => "Flag"
},
id: "APYLXiH6cdREQss5lQ",
inserted_at: ~N[2022-11-13 06:46:53],
local: true,
notifications: #Ecto.Association.NotLoaded<association :notifications is not loaded>,
object: #Ecto.Association.NotLoaded<association :object is not loaded>,
pagination_id: nil,
recipients: [],
report_notes: #Ecto.Association.NotLoaded<association :report_notes is not loaded>,
thread_muted?: nil,
updated_at: ~N[2022-11-13 06:46:53],
user_actor: #Ecto.Association.NotLoaded<association :user_actor is not loaded>
}}
```
While:
```
Pleroma.Activity.get_by_id("APYKvAICWGDa2B0Dei")
06:49:55.927 [debug] QUERY OK source="activities" db=36.3ms idle=183.1ms
SELECT a0."id", a0."data", a0."local", a0."actor", a0."recipients", a0."inserted_at", a0."updated_at" FROM "activities" AS a0 WHERE (a0."id" = $1) AND (NOT (a0."actor" IN (SELECT su0."ap_id" FROM "users" AS su0 WHERE (su0."is_active" = FALSE) AND (NOT (su0."nickname" IS NULL)) AND (NOT (su0."nickname" LIKE 'internal.%'))))) [<<0, 0, 1, 132, 111, 183, 79, 161, 112, 115, 104, 104, 128, 152, 0, 0>>]
%Pleroma.Activity{
__meta__: #Ecto.Schema.Metadata<:loaded, "activities">,
actor: "https://lm.kazv.moe/users/testuser",
bookmark: #Ecto.Association.NotLoaded<association :bookmark is not loaded>,
data: %{
"actor" => "https://lm.kazv.moe/users/testuser",
"bcc" => [],
"bto" => [],
"cc" => ["https://www.w3.org/ns/activitystreams#Public"],
"context" => "https://lm.kazv.moe/contexts/34747291-0246-4710-b079-ac0b4b445fdd",
"object" => "https://lm.kazv.moe/objects/570c7cc4-5b1d-4b88-9fd0-abfcf23ef918",
"to" => ["https://lm.kazv.moe/users/testuser/followers"],
"type" => "Create"
},
id: "APYKvAICWGDa2B0Dei",
inserted_at: ~N[2022-11-13 06:39:55],
local: false,
notifications: #Ecto.Association.NotLoaded<association :notifications is not loaded>,
object: #Ecto.Association.NotLoaded<association :object is not loaded>,
pagination_id: nil,
recipients: ["https://lm.kazv.moe/users/testuser/followers",
"https://www.w3.org/ns/activitystreams#Public",
"https://lm.kazv.moe/users/testuser"],
report_notes: #Ecto.Association.NotLoaded<association :report_notes is not loaded>,
thread_muted?: nil,
updated_at: ~N[2022-11-13 06:39:55],
user_actor: #Ecto.Association.NotLoaded<association :user_actor is not loaded>
}
```
Apparently, it is because the Create does not actually have an id. And we should guard against this.
I'll fix it when I wake up.tusooatusooahttps://git.pleroma.social/pleroma/pleroma/-/issues/2985Webfinger domain config ignored2022-11-19T20:52:32ZStefan HaslingerWebfinger domain config ignoredI am currently in progress of migrating to a different domain, so I set up another Pleroma instance.
I'm installing from source, from stable branch, commit 59b8c920f62649b5b5902cf0e569749abe3d7991, so it's release/2.4.4
I configured in p...I am currently in progress of migrating to a different domain, so I set up another Pleroma instance.
I'm installing from source, from stable branch, commit 59b8c920f62649b5b5902cf0e569749abe3d7991, so it's release/2.4.4
I configured in prod.secret.exs:
```
config :pleroma, Pleroma.Web.WebFinger,
domain: "panoptikum.social"
```
according to [How to use a different domain name for Pleroma and the users it serves](https://docs-develop.pleroma.social/backend/configuration/how_to_serve_another_domain_for_webfinger/#configuring-webfinger-domain)
But now, the instance responds to the request:
<https://pleroma.panoptikum.social/.well-known/webfinger?resource={acc:informatom@pleroma.panoptikum.social}>
but to
<https://pleroma.panoptikum.social/.well-known/webfinger?resource={acc:informatom@panoptikum.social}>
it responds with `Couldn't find user`. So it seems, the Pleroma.Web.WebFinger domain is ignored.
Any ideas what I am doing wrong? Is Webfinger domain not yet supported on stable?
I am sure, I am not running from an old prod.secret.exs . :-)
I am an Elixir developer myself, so tech/Elixir speak is fine ;-)
```
$ elixir --version
Erlang/OTP 25 [erts-13.0.4] [source] [64-bit] [smp:2:2] [ds:2:2:10] [async-threads:1] [jit:ns]
Elixir 1.13.4 (compiled with Erlang/OTP 25)
```
A big thank you to the team for the hard work, I am running the instance I am migrating away from for years now without any issues!https://git.pleroma.social/pleroma/pleroma/-/issues/2984Unable to see reports that reference statuses2022-11-12T20:44:47Zlunapleromagit@l4.pmUnable to see reports that reference statuses### Environment
* Installation type (OTP or From Source): **Source (develop branch, 481f50bcfda0da222e7b912e441da786b5a4944c)**
* Elixir version (`elixir -v` for from source installations, N/A for OTP): 1.14.1
* Operating system: Fedora...### Environment
* Installation type (OTP or From Source): **Source (develop branch, 481f50bcfda0da222e7b912e441da786b5a4944c)**
* Elixir version (`elixir -v` for from source installations, N/A for OTP): 1.14.1
* Operating system: Fedora Linux 36
* PostgreSQL version (`psql -V`): 10.23
### Bug description
The `f.l4.pm` single-user instance has been operational since approximately 2019, with a data directory that is clocking at 11.9GB. I recently migrated it to a new server, and thought it would be good to validate that incoming reports work, turns out only *some* of them did, only ones that did not reference a status. As soon as an incoming report comes with a status, it is not added to the `activities` table, with the following error
```
[error]Postgrex.Protocol (#PID<0.1005.0>) disconnected: ** (DBConnection.ConnectionError) client #PID<0.1613.0> timed out because it queued and checked out the connection for longer than 15000ms
#PID<0.1613.0> was at location:
:prim_inet.recv0/3
(postgrex 0.15.9) lib/postgrex/protocol.ex:2972: Postgrex.Protocol.msg_recv/4
(postgrex 0.15.9) lib/postgrex/protocol.ex:2014: Postgrex.Protocol.recv_bind/3
(postgrex 0.15.9) lib/postgrex/protocol.ex:1869: Postgrex.Protocol.bind_execute_close/4
(db_connection 2.4.0) lib/db_connection/holder.ex:325: DBConnection.Holder.holder_apply/4
(db_connection 2.4.0) lib/db_connection.ex:1314: DBConnection.run_execute/5
(db_connection 2.4.0) lib/db_connection.ex:574: DBConnection.parsed_prepare_execute/5
(db_connection 2.4.0) lib/db_connection.ex:566: DBConnection.prepare_execute/4
[debug]QUERY ERROR source="activities" db=15001.6ms
SELECT a0."id", a0."data", a0."local", a0."actor", a0."recipients", a0."inserted_at", a0."updated_at", o1."id", o1."data", o1."inserted_at", o1."updated_at" FROM "activities" AS a0 INNER JOIN "objects" AS o1 ON (o1."data"->>'id') = associated_object_id(a0."data") WHERE (associated_object_id((a0."data")) = $1) ORDER BY a0."id" LIMIT 1 ["https://f.l4.pm/objects/1d2d9a40-7953-4c24-86c4-f29dbc9deec4"]
[debug]QUERY ERROR db=0.0ms
```
I drilled down the code path to `Pleroma.Web.ActivityPub.Utils.build_flag_object/1`, more specifically the `Activity.get_by_object_ap_id_with_object(id)` call is locking up.
```elixir
case Activity.get_by_ap_id_with_object(id) do
%Activity{} = activity ->
build_flag_object(activity)
nil ->
if activity = Activity.get_by_object_ap_id_with_object(id) do
build_flag_object(activity)
else
%{"id" => id, "deleted" => true}
end
end
```
```elixir
def get_by_object_ap_id_with_object(ap_id) when is_binary(ap_id) do
ap_id
|> Queries.by_object_id()
|> with_preloaded_object()
|> first()
|> Repo.one()
end
```
Running `EXPLAIN` on the query reveals that PostgreSQL should be using the relevant indexes for its execution, and if I run that query manually, it finishes "instantly" (probably around 100ms), but there's no data provided
```
pleroma_dev=# explain SELECT a0."id", a0."data", a0."local", a0."actor", a0."recipients", a0."inserted_at", a0."updated_at", o1."id", o1."data", o1."inserted_at", o1."updated_at" FROM "activities" AS a0 LEFT OUTER JOIN "objects" AS o1 ON (o1."data"->>'id') = associated_object_id(a0."data") WHERE ((a0."data")->>'id' = 'https://f.l4.pm/objects/1d2d9a40-7953-4c24-86c4-f29dbc9deec4');
QUERY PLAN
--------------------------------------------------------------------------------------------------------------------
Nested Loop Left Join (cost=1.36..5.80 rows=1 width=2141)
-> Index Scan using activities_unique_apid_index on activities a0 (cost=0.56..2.77 rows=1 width=946)
Index Cond: ((data ->> 'id'::text) = 'https://f.l4.pm/objects/1d2d9a40-7953-4c24-86c4-f29dbc9deec4'::text)
-> Index Scan using objects_unique_apid_index on objects o1 (cost=0.80..3.02 rows=1 width=1195)
Index Cond: ((data ->> 'id'::text) = (associated_object_id(a0.data))::text)
(5 rows)
```
```
pleroma_dev=# SELECT a0."id", a0."data", a0."local", a0."actor", a0."recipients", a0."inserted_at", a0."updated_at", o1."id", o1."data", o1."inserted_at", o1."updated_at" FROM "activities" AS a0 LEFT OUTER JOIN "objects" AS o1 ON (o1."data"->>'id') = associated_object_id(a0."data") WHERE ((a0."data")->>'id' = 'https://f.l4.pm/objects/1d2d9a40-7953-4c24-86c4-f29dbc9deec4')
[...]
(0 rows)
```
The migration between servers involved a `pg_dump` from the old server, a `psql -f dump.sql` in the new one, and a `mix ecto.migrate` to update some 200 commits that I was missing from my instance's branch. Trying to reach the URL itself redirects to the `/notice/` URL, which then displays the original post that was being reported upon. My instance has required API authentication, so the post itself can't be shown to unauthenticated users, apologies.
Could this be caused by staying on PostgreSQL 10? Or could there be a deeper issue in how the index is constructed?
The database logs show that Ecto itself stopped execution of the query, and my server's load is not high.
```
==> /var/lib/pgsql/10/data/log/postgresql-Sat.log <==
2022-11-12 04:41:30.447 UTC [76494] ERROR: canceling statement due to user request
2022-11-12 04:41:30.447 UTC [76494] CONTEXT: PL/pgSQL function associated_object_id(jsonb) line 8 at assignment
2022-11-12 04:41:30.447 UTC [76494] STATEMENT: SELECT a0."id", a0."data", a0."local", a0."actor", a0."recipients", a0."inserted_at", a0."updated_at", o1."id", o1."data", o1."inserted_at", o1."updated_at" FROM "activities" AS a0 INNER JOIN "objects" AS o1 ON (o1."data"->>'id') = associated_object_id(a0."data") WHERE (associated_object_id((a0."data")) = $1) ORDER BY a0."id" LIMIT 1
2022-11-12 04:41:30.448 UTC [76494] LOG: could not send data to client: Broken pipe
2022-11-12 04:41:30.448 UTC [76494] FATAL: connection to client lost
```https://git.pleroma.social/pleroma/pleroma/-/issues/2982Error when trying to create a new user via cli2022-11-11T23:21:25ZI RasError when trying to create a new user via cliOn both `stable` and `develop` branches, running in a fresh docker build from https://github.com/angristan/docker-pleroma I get an error when trying to create a new user via cli:
```
~ $ mix pleroma.user new
Compiling 614 files (.ex)
=...On both `stable` and `develop` branches, running in a fresh docker build from https://github.com/angristan/docker-pleroma I get an error when trying to create a new user via cli:
```
~ $ mix pleroma.user new
Compiling 614 files (.ex)
== Compilation error in file lib/phoenix-1.5.9/priv/templates/phx.gen.live/modal_component.ex ==
** (SyntaxError) lib/phoenix-1.5.9/priv/templates/phx.gen.live/modal_component.ex:1:13: syntax error before: '='
(elixir 1.11.4) lib/kernel/parallel_compiler.ex:314: anonymous fn/4 in Kernel.ParallelCompiler.spawn_workers/7
```
on a fresh image I get the following extra output (I have keycloak set as an oauth provider):
```
~ $ mix pleroma.user new
==> oauth2
Compiling 13 files (.ex)
Generated oauth2 app
==> ueberauth_keycloak_strategy
Compiling 3 files (.ex)
warning: defp config/0 is private, @doc attribute is always discarded for private functions/macros/types
lib/ueberauth/strategy/keycloak/oauth.ex:41: Ueberauth.Strategy.Keycloak.OAuth.config/0
warning: variable "api_ver" is unused (if the variable is not meant to be used, prefix it with an underscore)
lib/ueberauth/strategy/keycloak.ex:196: Ueberauth.Strategy.Keycloak.fetch_user/2
Generated ueberauth_keycloak_strategy app
==> pleroma
Compiling 614 files (.ex)
== Compilation error in file lib/phoenix-1.5.9/priv/templates/phx.gen.live/modal_component.ex ==
** (SyntaxError) lib/phoenix-1.5.9/priv/templates/phx.gen.live/modal_component.ex:1:13: syntax error before: '='
(elixir 1.11.4) lib/kernel/parallel_compiler.ex:314: anonymous fn/4 in Kernel.ParallelCompiler.spawn_workers/7
```
Any help much appreciated, I don't understand what isn't working :pray: