mastodon-android
mastodon-android copied to clipboard
[BUG] App doesnt respect filters
I have my settings set to only show english as that is the only language i speak. However i know that some other languages use english characters or near enough so that isnt my main problem. The app also does not appear to be respecting user defined filters either
It should respect the word filters. Language filters are something I've never seen before?
Account settings > preferences > other
Sent from ProtonMail mobile
-------- Original Message -------- On Apr 29, 2022, 9:58 AM, Gregory K wrote:
It should respect the word filters. Language filters are something I've never seen before?
— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
I can confirm that word filters don't appear to work. I have a few hashtags filtered out with this configuration that get hidden in the web UI, but display in the app:
Exactly the same to me. I've asked and see other people are able to filter out hashtags and keywords. Added some filters that do work on the web interface but ignored by the app.
I don't see any reference to filters in the Settings screen of the app:

And going to the account settings, as mentioned above, doesn't show them either (it opens a webview with only account-rekated actions like moving to a different server, changing the password, etc.)
To get to the filters I have to, from the account settings page in the webview, click the hamburger menu and then select Filters. This is completely undiscoverable and should be readily accessible from the app settings screen.
Yes, the filters aren't shown anywhere in the UI (for now), but they are loaded and applied. If some of them don't apply the way they do in the web app, this is a bug I would need to fix.
@grishka would it be worth opening a separate issue to track adding a "Filters" entry in the app's Settings screen (even if just as a link to a webview, as is the case with the "Account settings" one?)
The app doesn't respects filters.
Example - I have a filter for #Caturday, which the website respects, but the app ignores.
Website (filtered post hidden)
App (filtered post not hidden)
https://github.com/tuskyapp/Tusky/issues/2660 Tusky fixed a similar issue recently. I wonder if it might be a similar root cause.
Hm. I think I actually tested my filter implementation on cats, too
Parse html tags out of status content before applying filters.
Yeah okay that makes sense. I'm testing filters against raw html, which is not the best idea.
Mastodon 4.0 adds filtered
property on posts so you don't need manually regex stuff client-side anymore, you just need to confirm that expiration time has not been reached yet.
Posts not being filtered in Android app. Filters work as expected on desktop web interface.
Are you using version 1.1.4?
I am using Mastodon for Android 1.1.4 (45)
Are you using version 1.1.4?
I'm using 1.1.4 and filters are still not working.
Huh, profiles? It's the first time I'm seeing this option. There was never any code in the app to apply filters to posts in profiles.
The option is there on the website. Should it be removed from the website?
The issue also occurs in home and timelines. This is just one example that was quick for me to find just now.
No, it's just that this option is new and I was never told that it was introduced, and so I never added support for it on my side.
The issue also occurs in home and timelines.
In 1.1.4?
It occurs for me in Home in 1.1.4.
On Thu, Dec 8, 2022, 11:19 PM Gregory K @.***> wrote:
No, it's just that this option is new and I was never told that it was introduced, and so I never added support for it on my side.
The issue also occurs in home and timelines.
In 1.1.4?
— Reply to this email directly, view it on GitHub https://github.com/mastodon/mastodon-android/issues/94#issuecomment-1343864819, or unsubscribe https://github.com/notifications/unsubscribe-auth/AANHUMGJIKGZE3J7ZSCICBLWMK6ONANCNFSM5UWDCDXQ . You are receiving this because you commented.Message ID: @.***>
Also for me. Example:
@MarkSte: It occurs for me in Home in 1.1.4.
Maybe that's related to the filters only getting updated once every hour, as per AccountSessionManager.java#L254? When removing this check (and thus updating on every app restart), filters do appear to work for me (on home) (but I don't know whether the implementation is the same; as in whether the same posts are being filtered as on Web).
…so probably, if the filtered
field is available, client-side filtering shouldn't be done at all:
@Gargron: Mastodon 4.0 adds
filtered
property on posts so you don't need manually regex stuff client-side anymore, you just need to confirm that expiration time has not been reached yet.
Also, the whole "Hide with a warning - Show anyway" feature is missing.
That's odd. Today, without any changes in my filters (or other settings) in 12 hours, filters are now working on both the Android app and the desktop browser version. BUT...I have the filter set to "Hide with a warning" and on Android app, filtered posts are being completely hidden. On the desktop, filtered posts are being hidden behind a warning. I'm still running Android 1.1.4 (45) and v4.0.2 on the desktop.
Yes, the app reloads the filters periodically.
BUT...I have the filter set to "Hide with a warning" and on Android app, filtered posts are being completely hidden.
This is a new feature in Mastodon 4.0. The code to implement this has not yet been written and the warning has not yet been designed.
If I understand grishka correctly, the Android app's implementation of filters fails for the setting "Hide with a warning" but works for the setting "Hide completely." I just experimented and found that offending posts are hidden completely on Android app no matter which setting is used. On the desktop filters work as I expect.
Mastodon 4.0 adds
filtered
property on posts so you don't need manually regex stuff client-side anymore, you just need to confirm that expiration time has not been reached yet.
@Gargron Wouldn't this not work for old posts that have already been downloaded by clients?