Я могу подтвердить использование устаревшего образа релиза в рамках другого изменения в mail-receiver .
Я открыл этот PR, который был объединён 11 августа:
main ← Ethsim12:fix-email-encoded
merged 01:09PM - 11 Aug 26 UTC
## What does this change?
Updates mail-receiver to send incoming MIME messages … using the
`email_encoded` parameter expected by Discourse's `/admin/email/handle_mail`
endpoint.
The message is encoded with `Base64.strict_encode64` before being added to
the form data.
This removes use of the deprecated raw `email` parameter.
## Why?
Discourse currently logs a deprecation notice for every incoming email sent
by mail-receiver:
> the email parameter is deprecated. all POST requests to this route should
> be sent with a base64 strict encoded email_encoded parameter instead
A freshly rebuilt `discourse/mail-receiver:release` still reproduces the
warning because the current mail-receiver code continues to send `email`.
## Tests
Adds regression coverage which verifies that:
- the deprecated `email` parameter is not sent
- `email_encoded` is sent
- the encoded value represents the original MIME message
Tested locally with Ruby 3.2.11:
- `bundle exec rake test` — 16 examples, 0 failures
- `bundle exec rubocop` — no offenses
- `bundle exec stree check ...` — all files matched expected format
This is related to #13, which proposed the same API migration in 2023.
This PR refreshes that change against current `main` and adds regression
coverage.
Он изменяет вызов в mail receiver с:
post.set_form_data(email: @mail)
на более новый параметр email_encoded, ожидаемый Discourse.
После того как PR был объединён, я пересобрал mail-receiver 17 августа, но в только что пересобранном контейнере всё ещё присутствовал код:
post.set_form_data(email: @mail)
Я добавил подробности в объединённый PR здесь:
main ← Ethsim12:fix-email-encoded
Thanks again for merging this.
I rebuilt `mail-receiver` again today (17 August… ), but the published
`discourse/mail-receiver:release` image still appears to contain the old
implementation.
The rebuild reports the `release` image as up to date, and checking the
freshly rebuilt running container gives:
```text
# docker exec mail-receiver \
grep -n -E 'base64|set_form_data' \
/usr/local/lib/site_ruby/mail_receiver/discourse_mail_receiver.rb
40: post.set_form_data(email: @mail)
```
A newly received email therefore still produces the `email parameter is
deprecated` warning in Discourse.
Since #37 is merged into `main`, does the
`discourse/mail-receiver:release` Docker image need to be rebuilt/published
separately for this change to reach normal self-hosted installations?
22 августа я пересобрал его снова, и ./launcher rebuild mail-receiver сообщил, что опубликованный образ релиза является актуальным, с дайджестом:
sha256:2a0d45bb92a783c846a821e635413764eeadb3441ef6190085545a4bf054cb1e
Входящая почта на моей установке по-прежнему работает, но каждое полученное письмо продолжает вызывать предупреждение Discourse:
the email parameter is deprecated
так как опубликованный образ не содержит изменения из объединённого PR #37 .
Таким образом, это, по-видимому, независимо подтверждает первую найденную вами проблему: изменения, объединённые в репозитории mail-receiver , не попадают в опубликованный образ discourse/mail-receiver:release.