Skip to content
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

Language Filter #29

Open
Made1908 opened this issue Aug 3, 2024 · 14 comments
Open

Language Filter #29

Made1908 opened this issue Aug 3, 2024 · 14 comments
Labels
feature New feature

Comments

@Made1908
Copy link

Made1908 commented Aug 3, 2024

It would be nice to have a language Filter, so that only specified languages are shown.

@sleeyax
Copy link
Owner

sleeyax commented Aug 3, 2024

Not sure if that's possible, I don't think Easynews includes language info in search results but I'll have to double check. Maybe it can be extracted from the title (similar to how quality/resolution is currently extracted) but it definitely won't be a perfect solution as many titles don't have a language code in them.

@sleeyax sleeyax added the feature New feature label Aug 3, 2024
@Made1908
Copy link
Author

Made1908 commented Aug 3, 2024

Atleast in my language (german) the title always contains either .GERMAN. or .German. I would assume that that is the usual way how stremio addons parse the language.

@Screamio
Copy link

Language filters would be really helpful indeed.

Probably in form of a Regex search filter as an optional filter which could be set?
Could be a new sorting option, which the user could configure and it would allow to list matching file names at the beginning of the list.

@mikmc55
Copy link

mikmc55 commented Sep 13, 2024

the code is here open source to test with any regex filtering you want, its not possible from the easynews console itself so not straightforward to implement

@linsetlogan
Copy link

If you are not english, it's a nighmare without lang filter.

@kibabyte
Copy link

Would it be possible to add a field in the configuration that simply appends something to the search? Appending spanish, french, german or whatever will probably already yield quite usable results. Please excuse my ignorance if this is not how it would work.

@sleeyax
Copy link
Owner

sleeyax commented Oct 25, 2024

Would it be possible to add a field in the configuration that simply appends something to the search? Appending spanish, french, german or whatever will probably already yield quite usable results. Please excuse my ignorance if this is not how it would work.

Yes, that could work as a work-around if no other more robust solution is found.

@kibabyte
Copy link

Was a better solution found here? I will try to implement what I am wanting to do when there is some nice deal on easynews for black friday, although a slightly less janky solution would surely be appreciated.

@newspeer
Copy link

That would be great!

@kingunlim
Copy link

maybe something in the pipes? 😎

@kingunlim
Copy link

maybe someone else knows a working solution to the language filter problem?

@kibabyte
Copy link

maybe someone else knows a working solution to the language filter problem?

Only way I can think of is self hosting the add on with a modified search prompt. Might aswell make it adjustable to instead of hardcoding it in. I will look into it in the next few weeks maybe.

@Marvins13
Copy link

A simple fix I made for myself was to add a filter with "german" to the For loop of the defineStreamHandler and the defineMetaHandler in the addon.ts.
And now I have it running myself with a cloudflare worker.

if (!title.toUpperCase().includes("GERMAN")) { continue; }

@newspeer
Copy link

newspeer commented Jan 14, 2025

Thanks, unfortunately doesn't work for me. Easynews doesn't return anything for me. Tested with many current German releases.

` if (isBadVideo(file) || !matchesTitle(title, search, false)) {
continue;
}
if (!title.toUpperCase().includes("GERMAN")) { continue; }

    videos.push({
      id: ${prefix}${file.sig},`

and

if (isBadVideo(file)) { continue; } if (!title.toUpperCase().includes("GERMAN")) { continue; } // For series there are multiple possible queries that could match the title. // We check if at least one of them matches. if (type === 'series') { const queries = [

Did I place the filter wrong?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature
Projects
None yet
Development

No branches or pull requests

9 participants