New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[feature] Filters v1 #2594
[feature] Filters v1 #2594
Conversation
There are two cache-related TODOs: one is for the multi-invalidate cache method that doesn't exist yet, and one is for cache memory ratios, which I don't understand. The Swagger tool GtS uses seems to have a lot of bugs and omissions, so I'm not 100% on the Swagger parts. |
Using the CI for |
Being upstreamed at superseriousbusiness#2594
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
This comment was marked as off-topic.
Oops, that close was entirely accidental. |
I take back my "this should work fine on 0.14"; there are some DB changes I need to rebase on top of first. |
6a7ad18
to
b044de9
Compare
The unused code warnings are a false positive, possibly due to dominikh/go-tools#1440, and I've fixed the issue with GoLand custom folding region comments in go-critic/go-critic#1408. For now, I've added very specific exclusions to our linter config. I have no idea why the docs build failed, but I haven't changed anything in the docs. |
This comment was marked as off-topic.
This comment was marked as off-topic.
I'll check it out :) |
Not sure why the docs build failed, but I'll kick it :) |
As a point of order, can we please keep the "how does this work and does it work with my favourite client" discussion to a minimum going forwards? It causes a bunch of notifications and it's not relevant to the change itself. There's a Matrix room for this kind of discussion. |
This is looking almost ready to go 👀 Just a few discussions left to resolve. Thanks for your continued hard work @VyrCossont ! |
This is an operation that the Mastodon v2 filter API doesn't actually have, because filter statuses, unlike keywords, don't have options: the only info they contain is the status ID to be filtered.
case float64: | ||
form.ExpiresIn = util.Ptr(int(e)) | ||
|
||
case string: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
should we be expecting this as a string? this feels wrong. or is this mastodon normalized behaviour we're stuck with :p
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the same set of types accepted by the poll expiration time mechanism, so I assume we've seen that happen at least once 😞
Our existing linters should catch these, or they don't matter very much
Description
This pull request implements a client-side filter API compatible with the Mastodon filter v1 API.
It does not implement the Mastodon filter v2 API, although it does add the DB and cache plumbing to trivially implement that API later. It also doesn't implement the server-side filtering part of the v1 API: the
irreversible
filter option will return an error message if set totrue
.Fixes #1472
Checklist
go fmt ./...
andgolangci-lint run
.