TeamNewPipe / NewPipe

A libre lightweight streaming front-end for Android.
https://newpipe.net
GNU General Public License v3.0
31.1k stars 3.02k forks source link

please add filters to search functionality #110

Closed doodhout closed 2 years ago

doodhout commented 8 years ago

Sometimes when I want to look for the latest (new) videos of a ongoing vlog series (e.g. Equals Three) I want the search results ordered by date.

I know that this problem will be solved when you implement the possibility to view and search in channel playlists, but I'd like the power to adjust the search results nonetheless.

Currently the results that are displayed use the default filter values, one of which is by order of relevance.

I suppose this isn't really hard to make; mostly adding extra arguments in the search() function in the file YoutubeSearchEngine.java, and a nice UI-component to let the user choose which filters he'd like to use, but I reckon it's not the smallest job ever to be done, especially if you take the time to work out a nice UI solution for this - which isn't easy.

Since I have a rough vision on how to do this, maybe I will be able to find the time during the christmas holidays to do it myself and submit a pull request.

gregarkhipov commented 8 years ago

We could add filter button right next to the search bar which will pop out dropdown menu with options just like on YouTube site. But considering device size, we can make this menu scrollable and use spinners instead of listing all options where it's possible (for instance, upload date and type).

theScrabi commented 8 years ago

Hm consider a NavigationDrawer. It's cleaner, and its also just a mater of time until this is finally coming.

doodhout commented 8 years ago

The search function is still annoying to use if you search for the latest video in an existing series, since I (at least think that I) still cannot have the search results in chronological order.

Is there any view on whether this is a feature that is being considered?

theScrabi commented 8 years ago

You'd have to aplay filters on the result, which wouldn't be that complicated, but id like to focus on rather more importand features first. So unless someone else implements this it's not going to come soon.

doodhout commented 8 years ago

Why wouldn't this be important? (I understand that this is subjective, of course) If I use the search feature in NewPipe, it will give me results in whatever order of importance YouTube deems fit, but that is far from always the best order.

Especially for youtube series (like Equals Three or any poster that regularly posts new videos in the same series or playlist), you get search results where the videos aren't ranked chronologically, so it's almost impossible to know if there is any new video you haven't watched yet. It's stupid that I have to use another client (or the website) first to actually know what to look for, because the search feature in NewPipe cannot find it for me.

Anyway, I might be able to take this up. I'll bother you with a pull request sooner or later. ;-)

bagelcake commented 7 years ago

Any ETA on this @doodhout?

I too believe this is a very necessary feature. I usually search YouTube for the latest uploads and having the ability to sort by upload date (or however else including perhaps duration length) is crucial. Until then, I can't really use what would otherwise be a perfect replacement.

I can't offer help with this but if you need Photoshopping, let me know. Thanks.

doodhout commented 6 years ago

You caught me with my pants down - I haven't picked this up yet. It's been a busy year, but I'm not here to make excuses.

I'll try and actually get things done. If and when I start, I suppose the ETA is... soon.

Tbc...

doodhout commented 6 years ago

@theScrabi @mauriciocolli

I've cloned the repos locally and started some investigation.

Turns out the relevant bits to this problem are located in YoutubeSearchEngine in the project NewPipeExtractor:

        String url = "https://www.youtube.com/results"
                + "?q=" + URLEncoder.encode(query, CHARSET_UTF_8)
                + "&page=" + Integer.toString(page + 1);

        switch (filter) {
            case STREAM:
                url += "&sp=EgIQAVAU";
                break;
            case CHANNEL:
                url += "&sp=EgIQAlAU"; //EgIQA( lowercase L )AU
                break;
            case PLAYLIST:
                url += "&sp=EgIQA1AU"; //EgIQA( one )AU
                break;
            case ANY:
                // Don't append any parameter to search for everything
            default:
                break;
        }

The problem with the current situation is that Youtube sort of "combines" those filters into a single and seemingly random variable value, behind which I cannot see the logic.

For example:

This massive collection of all possible combinations without knowing how to generate such a value ourselves is causing this to be cumbersome and boilerplate. It can be done, of course, but it's not pretty.

Can anyone pitch in with a bright idea to tackle this?

P.S. I searched around a bit and found that the old parameter called "search_sort" still works (for now) AND works in conjunction with the new type filter parameters, so only implementing sort order using this old parameter promises to be much, much simpler.

P.P.S. Should I move this comment to a(n upcoming) Pull Request to keep it all together in one thread?

theScrabi commented 6 years ago

Do you really want to combine those? Have you ever done that? I mean I barely use those, and wen I do I use only one at a time. What do you think.

bagelcake commented 6 years ago

@doodhout Thanks for all your work, I really appreciate this especially when it gets implemented. For now I've been using search commands as a workaround. For example, to sort by upload date, I do "movie trailers, new" and so far it's been an okay workaround. Sometimes I lose the position by scrolling too far down and have to redo the search again.

stale[bot] commented 5 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

doodhout commented 5 years ago

I realise I have been leaving this hanging for quite a while.

Since I now work around this problem by using (other people's) playlists (because that's more or less what I tried achieving using the search function), I don't think I really need this that hard.

Are there any takers or will this be left to die? Anything is fine for me.

Bluesir9 commented 5 years ago

@doodhout I have implemented this functionality in NewPipeExtractor here. So rest assured it will be out soon :)

doodhout commented 5 years ago

Excellent work, @Bluesir9!

Suncatcher commented 4 years ago

So, five years passed and still we have no sorting in search, it's kind of shame, ya?

but I'm not here to make excuses. If and when I start I suppose the ETA is... soon.

Soon is not a meaningful ETA, can you share something more precise? We can support this functionality by donation, as it is in high demand of many.

And what does response in this issue mean? Core support of what was added? What sort?

richard-broadhurst commented 4 years ago

I love NewPipe, but the way I use Youtube is always to search for a topic "bbc micro" and order by date uploaded (most recent first). I can't find a way to do this and if this is the right feature, I would love it to be incorporated. I never use subscriptions as my topics often only have one or to videos from any given individual, so it must be on the main search results.

doodhout commented 4 years ago

I haven't picked this up and I'm not planning to in the near future, so if anyone wants to do this in my stead, please don't hold back. :)

MD77MD commented 4 years ago

@B0pol I hope you guys can do something about this feature

360fun commented 3 years ago

I love NewPipe, but I always felt missing the ability to order/filter search results: this is a very needed function! 🙏

FreeTube has also implemented it: image

ghost commented 3 years ago

@Stypox this feature request is open since 5 years, another 5 and we'll can celebrating its birthday ahahaha.

Seriously...isn't better close these kind of requests, instead leaving them open to rot into oblivion?

I also notice a series of other similar requests opened and stacked up here, meanwhile other less important features are integrated almost immediately.

🤷‍♂️🤷‍♂️🤷‍♂️🤷‍♂️🤷‍♂️

tastytea commented 3 years ago

@Oizaro Why? The series of similar requests prove that a lot of people want that feature. Maybe tomorrow someone is bored, notices this issue and implements it.

ghost commented 3 years ago

@Oizaro Why? The series of similar requests prove that a lot of people want that feature. Maybe tomorrow someone is bored, notices this issue and implements it.

So we get new features, just because "someone is bored"? 🤣🤣🤣

tastytea commented 3 years ago

So we get new features, just because "someone is bored"?

We get features because someone who can code and has the time wants to implement them (for a variety of reasons, being bored is just an example). I'm sure you can also pay someone to implement a specific feature.

ghost commented 3 years ago

So we get new features, just because "someone is bored"?

...I'm sure you can also pay someone to implement a specific feature.

The choice in this sense is wide and includes even easier solutions (without giving examples, I think it is already clear).

I just find very unusual that a creator always prefer to leave the task of implementing new features to others, rather to follow a own roadmap (when there's time to do it).

At this point it would be better if the app were paid rather than open source.

MD77MD commented 3 years ago

@Stypox this feature request is open since 5 years, another 5 and we'll can celebrating its birthday ahahaha.

Seriously...isn't better close these kind of requests, instead leaving them open to rot into oblivion?

I also notice a series of other similar requests opened and stacked up here, meanwhile other less important features are integrated almost immediately.

🤷‍♂️🤷‍♂️🤷‍♂️🤷‍♂️🤷‍♂️

exactly!! I've raised this issue before with them but nothing.

its sad to see newPipe turn into thier learning guinea pig...

this also tells me that they are probably using the YouTube app (like many of us are forced to do) otherwise how could you search for anything among the other necessary but neglected features.

that's why paid apps will always when.

just sad 🙁

christianfl commented 3 years ago

Just pay someone to develop this feature then.

fairking commented 3 years ago

Just really disappointing having to go to the actual youtube to search and filter by last month/year. Please make this feature. Everything else is very good job guys. 👍

MichiFr commented 3 years ago

Me too was searching for this useful YT feature in NewPipe, since I've found this app on internet. However, the lack of sorting or filtering keeps me away from this app because I don't want to have 5 yrs old vids in my search result which are absolutely not relevant anymore.

Of course, if there are no volunteers to implement those lines of code this into the app, we won't see it anytime soo. But as far as I've understood , someone has already done the work for us, see Bluesir9's message from 4 th Dec 2018! Or am I wrong?

sebma commented 3 years ago

@MichiFr No, you're not wrong. And for convenience, here's the link to Bluesir9's message from 4 th Dec 2018.

MichiFr commented 3 years ago

So, this leaves the question: why can't I see this option in current release? Wasn't it merged into the main branch so far? Any reasons for this?

christianfl commented 3 years ago

Because you seem to confound the Newpipe extractor with the app itself. As there is support in the extractor, there is "just" the frontend support missing for adding some basic filters.

MichiFr commented 3 years ago

Ah, thanks for clarification!

As I understand now, basically the main part is done in the extractor itself, the UI is missing the options to use the filters...

opusforlife2 commented 3 years ago

Nope. That PR was not merged. It was closed without merging. So there is nothing yet in either Newpipe or the Extractor.

litetex commented 2 years ago

Duplicate of #2251

litetex commented 2 years ago

Closing as duplicate.

Please use #2251 as it's more up-to-date. Also maybe give it a up-vote if you want 😉

sebma commented 2 years ago

@litetex How come an older issue (#110) be marked as a duplicate of a newer issue (#2251), shouldn't it be the opposite ?

litetex commented 2 years ago

Please use #2251 as it's more up-to-date.