Comments (5)
Hi @BertAssistant !
I'm kinda confused about this one.
from youtube-search-python.
Hi @BertAssistant !
Can you please remove the following line from your code & let me know if it still shows that on terminal?
url = StreamURLFetcher().get(target, 251)
I also recommend to make global object of the StreamURLFetcher
, & address its instance, instead of every time instanciating StreamURLFetcher
.
Because that's the only thing that can go wrong, I guess.
from youtube-search-python.
Hi @BertAssistant !
Can you please remove the following line from your code & let me know if it still shows that on terminal?
url = StreamURLFetcher().get(target, 251)Because that's the only thing that can go wrong, I guess.
I think the main problem (Could not make requests) is StreamURLFetcher(). On my local console it works fine, but not with the server console
from youtube-search-python.
Hello @BertAssistant !
As you probably read my documentation of the project, the StreamURLFetcher
is derived from PyTube
& its a slow process.
Thing is that, when you message too frequently, the things get kinda bad as it uses some global variables, which do not make it thread safe.
So,
all I can say is to change this line:
url = StreamURLFetcher().get(target, 251)
to:
# Store this globally.
fetcher = StreamURLFetcher()
def yourMessageFunction(self, ...):
# Address the object.
url = fetcher.get(target, 251)
By this, the performance will also improve & possibly your bug will also get fixed.
You can see this project from someone else, how he/she has stored the object globally.
from youtube-search-python.
Hope this gets it resolved.
Thanks.
Closing. Feel free to make further query.
from youtube-search-python.
Related Issues (20)
- [Feature request] youtube music search HOT 1
- Age-restricted videos not deciphering in StreamURLFetcher HOT 2
- Retrieve channel info & search with a specific time span HOT 8
- Search for videos with multiple hashtags HOT 1
- Errors on Video.getInfo HOT 2
- Issues with fetching age-restricted videos
- Filter livestreams HOT 5
- Total views of a channel HOT 2
- about video information retrieved, miss "how many likes/dislike" properties HOT 1
- [Feature Request] get list of Playlists created by a user HOT 1
- ChannelSearch not working on "* - topic" channels
- got repeted result in playlist HOT 3
- Passing cookies to requests
- Different calls to Comments.get keeps comments from previous calls HOT 1
- Transcriptions are blank HOT 2
- error when getting videos from channel id HOT 2
- Title and desc HOT 1
- Include like count for video info HOT 2
- Questions rather than issue: how to add some values to the result? HOT 2
- An important anouncement about this library HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from youtube-search-python.