Compare commits
8 commits
9fba335937
...
3213835e33
Author | SHA1 | Date | |
---|---|---|---|
3213835e33 | |||
|
443871d913 | ||
|
a9756884ab | ||
|
bba17bc467 | ||
|
962587bfc8 | ||
|
bd78330a24 | ||
|
b0ef64243d | ||
|
9a41c65582 |
8 changed files with 45 additions and 13 deletions
3
.github/workflows/test-ruby.yml
vendored
3
.github/workflows/test-ruby.yml
vendored
|
@ -120,6 +120,7 @@ jobs:
|
|||
ruby-version:
|
||||
- '3.1'
|
||||
- '.ruby-version'
|
||||
- '3.3'
|
||||
ci_job:
|
||||
- 1
|
||||
- 2
|
||||
|
@ -198,6 +199,7 @@ jobs:
|
|||
ruby-version:
|
||||
- '3.1'
|
||||
- '.ruby-version'
|
||||
- '3.3'
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
@ -310,6 +312,7 @@ jobs:
|
|||
ruby-version:
|
||||
- '3.1'
|
||||
- '.ruby-version'
|
||||
- '3.3'
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v4
|
||||
|
|
11
CHANGELOG.md
11
CHANGELOG.md
|
@ -2,6 +2,17 @@
|
|||
|
||||
All notable changes to this project will be documented in this file.
|
||||
|
||||
## [4.2.18] - 2025-03-10
|
||||
|
||||
### Changed
|
||||
|
||||
- Change hashtag suggestion to prefer personal history capitalization (#34070 by @ClearlyClaire)
|
||||
|
||||
### Fixed
|
||||
|
||||
- Fix processing errors for some HEIF images from iOS 18 (#34086 by @renchap)
|
||||
- Fix streaming server not filtering unknown-language posts from public timelines (#33774 by @ClearlyClaire)
|
||||
|
||||
## [4.2.17] - 2025-02-27
|
||||
|
||||
### Security
|
||||
|
|
|
@ -57,6 +57,9 @@ SHELL ["/bin/bash", "-o", "pipefail", "-c"]
|
|||
ENV DEBIAN_FRONTEND="noninteractive" \
|
||||
PATH="${PATH}:/opt/ruby/bin:/opt/mastodon/bin"
|
||||
|
||||
# Add backport repository for some specific packages where we need the latest version
|
||||
RUN echo 'deb http://deb.debian.org/debian bookworm-backports main' >> /etc/apt/sources.list
|
||||
|
||||
# Ignoring these here since we don't want to pin any versions and the Debian image removes apt-get content after use
|
||||
# hadolint ignore=DL3008,DL3009
|
||||
RUN apt-get update && \
|
||||
|
@ -74,6 +77,7 @@ RUN apt-get update && \
|
|||
libicu72 \
|
||||
libidn12 \
|
||||
libyaml-0-2 \
|
||||
libheif1/bookworm-backports \
|
||||
file \
|
||||
ca-certificates \
|
||||
tzdata \
|
||||
|
|
|
@ -254,12 +254,26 @@ const expiresInFromExpiresAt = expires_at => {
|
|||
|
||||
const mergeLocalHashtagResults = (suggestions, prefix, tagHistory) => {
|
||||
prefix = prefix.toLowerCase();
|
||||
|
||||
if (suggestions.length < 4) {
|
||||
const localTags = tagHistory.filter(tag => tag.toLowerCase().startsWith(prefix) && !suggestions.some(suggestion => suggestion.type === 'hashtag' && suggestion.name.toLowerCase() === tag.toLowerCase()));
|
||||
return suggestions.concat(localTags.slice(0, 4 - suggestions.length).toJS().map(tag => ({ type: 'hashtag', name: tag })));
|
||||
} else {
|
||||
return suggestions;
|
||||
suggestions = suggestions.concat(localTags.slice(0, 4 - suggestions.length).toJS().map(tag => ({ type: 'hashtag', name: tag })));
|
||||
}
|
||||
|
||||
// Prefer capitalization from personal history, unless personal history is all lower-case
|
||||
const fixSuggestionCapitalization = (suggestion) => {
|
||||
if (suggestion.type !== 'hashtag')
|
||||
return suggestion;
|
||||
|
||||
const tagFromHistory = tagHistory.find((tag) => tag.localeCompare(suggestion.name, undefined, { sensitivity: 'accent' }) === 0);
|
||||
|
||||
if (!tagFromHistory || tagFromHistory.toLowerCase() === tagFromHistory)
|
||||
return suggestion;
|
||||
|
||||
return { ...suggestion, name: tagFromHistory };
|
||||
};
|
||||
|
||||
return suggestions.map(fixSuggestionCapitalization);
|
||||
};
|
||||
|
||||
const normalizeSuggestions = (state, { accounts, emojis, tags, token }) => {
|
||||
|
|
|
@ -56,7 +56,7 @@ services:
|
|||
|
||||
web:
|
||||
build: .
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.17
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.18
|
||||
restart: always
|
||||
env_file: .env.production
|
||||
command: bash -c "rm -f /mastodon/tmp/pids/server.pid; bundle exec rails s -p 3000"
|
||||
|
@ -77,7 +77,7 @@ services:
|
|||
|
||||
streaming:
|
||||
build: .
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.17
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.18
|
||||
restart: always
|
||||
env_file: .env.production
|
||||
command: node ./streaming
|
||||
|
@ -95,7 +95,7 @@ services:
|
|||
|
||||
sidekiq:
|
||||
build: .
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.17
|
||||
image: ghcr.io/mastodon/mastodon:v4.2.18
|
||||
restart: always
|
||||
env_file: .env.production
|
||||
command: bundle exec sidekiq
|
||||
|
|
|
@ -13,7 +13,7 @@ module Mastodon
|
|||
end
|
||||
|
||||
def patch
|
||||
17
|
||||
18
|
||||
end
|
||||
|
||||
def default_prerelease
|
||||
|
|
|
@ -33,12 +33,12 @@ describe RequestPool do
|
|||
|
||||
subject
|
||||
|
||||
threads = Array.new(20) do |_i|
|
||||
threads = Array.new(5) do
|
||||
Thread.new do
|
||||
20.times do
|
||||
subject.with('http://example.com') do |http_client|
|
||||
http_client.get('/').flush
|
||||
end
|
||||
subject.with('http://example.com') do |http_client|
|
||||
http_client.get('/').flush
|
||||
# Nudge scheduler to yield and exercise the full pool
|
||||
sleep(0.01)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
@ -789,7 +789,7 @@ const startServer = async () => {
|
|||
// filtering of statuses:
|
||||
|
||||
// Filter based on language:
|
||||
if (Array.isArray(req.chosenLanguages) && payload.language !== null && req.chosenLanguages.indexOf(payload.language) === -1) {
|
||||
if (Array.isArray(req.chosenLanguages) && req.chosenLanguages.indexOf(payload.language) === -1) {
|
||||
log.silly(req.requestId, `Message ${payload.id} filtered by language (${payload.language})`);
|
||||
return;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue