LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Software
User Name
Password
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.

Notices


Reply
  Search this Thread
Old 02-23-2018, 12:37 PM   #4996
tonycpsu
Member
 
Registered: Apr 2014
Posts: 71

Rep: Reputation: Disabled

OK, so I added an MLB plugin to streamlink that can successfully (with my hard-coded access token at the moment) decrypt and play an MLB.tv stream. So it definitely looks like an ideal replacement for mlbhls.
 
Old 02-23-2018, 12:44 PM   #4997
brianV_
LQ Newbie
 
Registered: Feb 2018
Posts: 3

Rep: Reputation: Disabled
Quote:
Originally Posted by tonycpsu View Post
OK, so I added an MLB plugin to streamlink that can successfully (with my hard-coded access token at the moment) decrypt and play an MLB.tv stream. So it definitely looks like an ideal replacement for mlbhls.
Better to reuse an existing library than depending on our own code if possible.
 
Old 02-23-2018, 12:54 PM   #4998
tonycpsu
Member
 
Registered: Apr 2014
Posts: 71

Rep: Reputation: Disabled
Quote:
Originally Posted by brianV_ View Post
Better to reuse an existing library than depending on our own code if possible.
I'm not sure what you mean? streamlink is an existing project. It doesn't have a plugin for MLB.tv.
 
Old 02-23-2018, 12:55 PM   #4999
tonycpsu
Member
 
Registered: Apr 2014
Posts: 71

Rep: Reputation: Disabled
But now that you mention it, it does have support for passing http headers through to the built-in HLS plugin, and it appears that's all that's needed in this case... So, yeah, no plugin necessary.
 
Old 02-23-2018, 12:55 PM   #5000
brianV_
LQ Newbie
 
Registered: Feb 2018
Posts: 3

Rep: Reputation: Disabled
Quote:
Originally Posted by tonycpsu View Post
I'm not sure what you mean? livestreamer is an existing project. It doesn't have a plugin for MLB.tv.
Sorry, I should have been more clear. What I meant was:

'It's better to use livestreamer than to continue to maintain mlbhls'.

Basically just agreeing with your suggestion!
 
1 members found this post helpful.
Old 02-23-2018, 01:58 PM   #5001
daftcat
mlbviewer Maintainer
 
Registered: Apr 2008
Posts: 1,883

Rep: Reputation: 86
Quote:
Originally Posted by tonycpsu View Post
OK, so I added an MLB plugin to streamlink that can successfully (with my hard-coded access token at the moment) decrypt and play an MLB.tv stream. So it definitely looks like an ideal replacement for mlbhls.
My email is in the README. Or I also emailed you earlier today. Send me what you have and I'll merge it with what I've got. We can possibly get some game support via an mlbplay replacement this weekend or next week.
 
Old 02-24-2018, 11:10 AM   #5002
freddysmith
LQ Newbie
 
Registered: Feb 2018
Posts: 5

Rep: Reputation: Disabled
Ive been trying streamlink with hardly much luck, Will try again for todays game, If anyone has any help would be great missing watching it on my linux already

Last edited by freddysmith; 02-24-2018 at 11:16 AM.
 
Old 02-25-2018, 10:31 AM   #5003
kweisen
Member
 
Registered: May 2006
Location: Englewood, Fl
Distribution: MInt 17
Posts: 57

Rep: Reputation: 0
Also, it appears that the GameDay Audio is not working as before. I get the schedule listing but all the games are indicating 'No Media'. Hopefully, any fixes you're able to come up with will also take care of this. Thanks.
 
Old 02-26-2018, 10:24 AM   #5004
bunglebungle
LQ Newbie
 
Registered: Nov 2007
Posts: 15

Rep: Reputation: 0
Quote:
Originally Posted by tonycpsu View Post
Supporting all of this would seem to require a major rewrite of mlbhls, and while I'm a decent C programmer, I think a lot of other tools have come along that could make this easier, including streamlink, which has the advantages of (a) being written in Python, (b) already supporting HLS, and (c) having a decent "plugin" system for dealing with stream providers. There isn't one for MLB, but looking at some of the others, I feel like the plugin mechanism should be flexible enough for what we need.
The plugin for Kodi is having the same issues. It's Python - I don't know how much overlap there is but perhaps whatever is learned can be shared (knowledge or code).
 
Old 02-27-2018, 09:36 AM   #5005
freddysmith
LQ Newbie
 
Registered: Feb 2018
Posts: 5

Rep: Reputation: Disabled
Quote:
Originally Posted by tonycpsu View Post
But now that you mention it, it does have support for passing http headers through to the built-in HLS plugin, and it appears that's all that's needed in this case... So, yeah, no plugin necessary.
Have sent you a email but havnt got a response yet, are you still working on something
 
Old 03-01-2018, 04:49 PM   #5006
tonycpsu
Member
 
Registered: Apr 2014
Posts: 71

Rep: Reputation: Disabled
Sorry for the delayed response, folks. Here's where I'm at with this.

After speaking with daftcat and showing him what I've got so far, we've decided to move forward with a new project, which I'm calling mlbstreamer. I will welcome any and all contributions from daftcat and anyone else who's interested in helping out, but I wanted to take my initial idea for the project from "works for me" status to the point where I thought it was robust enough to release.

Unfortunately, I lost my MLB.tv access today -- not because of anything to do with this app, but because I've had my subscription through T-Mobile's free MLB.tv promotion, and that promotion ended yesterday. Apparently T-Mobile is going to do that promo again, but not until the end of the month, which means I won't have MLB.tv access during Spring Training. This means it's going to be hard for me to support folks if they run into any problems.

Still, I want people to be able to watch games, so I'm going to release what I have so far. Right now I'd say the intended audience is people can install Python packages and troubleshoot a bit if things go sideways. If that isn't you, well, you're more than welcome to try it out, but I'll be limited in how much I can help without an active MLB.tv account.

What I can say is that this was working for me as of yesterday to watch games, and that I plan to keep improving things over time once I have a working subscription again.

The project is located here:

It consists of two programs: mlbplay and mlbstreamer. mlbplay is a bit like the program of the same name in mlbviewer -- it's a command-line program to play a single game. mlbstreamer is more like mlbviewer itself, in that it's a console user interface that allows you to browse the schedule and play games from there.

The mlbstreamer program is definitely a work in progress, so right now it's an optional install. Well, it will be installed by default, but its dependencies won't, so it won't run.

If you want to install without those dependencies just to use the mlbplay command-line program, run:

Code:
pip install "git+https://github.com/tonycpsu/mlbstreamer" --process-dependency-links
If you want the whole thing, including the mlbstreamer console UI dependencies, run:

Code:
pip install "git+https://github.com/tonycpsu/mlbstreamer/#egg=mlbstreamer[gui]" --process-dependency-links
The first thing you'll need to do is configure your username, password, etc. To do that, run:

Code:
mlbplay --init-config
The program should ask you for your username and password, then try to find your media player (it just looks for mpv or vlc right now.). If it doesn't find it, you can enter the full path to whatever you're using. If your player worked with mlbviewer, it should work with mlbstreamer. It'll also ask you for your time zone so that game times are displayed properly.

Once that's done, you should be able to play a team's games by running:

Code:
mlbplay [TEAM]
where TEAM is the team code for the team's game you want to watch. If you want to watch a game for a different date, run with the -d option, e.g:

Code:
mlbplay -d 2018-02-24 phi
The mlbstreamer console UI may or may not work for everyone right now. If it does, it'll show you a schedule view. Press "w" to watch a game, left/right arrows to browse days, "t" to go to today's games. The log window at the bottom should tell you if there are any errors, like if the game doesn't have a stream.

Like I said, I can't really test a lot of the error conditions now because I don't have an active account. But hopefully this thing works for y'all, and if not, well, I can start fixing it once I get my account back.

I should also make it clear clear that this program is intended for streaming MLB.tv for legitimate subscribers only, for the purposes of watching games you're legally allowed to access, and that I will not be held responsible for any problems you may run into as a result of using this software.

I think that's it for now. Hopefully this works for at least one other person!

Last edited by tonycpsu; 03-01-2018 at 05:19 PM.
 
1 members found this post helpful.
Old 03-01-2018, 04:53 PM   #5007
freddysmith
LQ Newbie
 
Registered: Feb 2018
Posts: 5

Rep: Reputation: Disabled
Quote:
Originally Posted by tonycpsu View Post
Sorry for the delayed response, folks. Here's where I'm at with this.

After speaking with daftcat and showing him what I've got so far, we've decided to move forward with a new project, which I'm calling mlbstreamer. I will welcome any and all contributions from daftcat and anyone else who's interested in helping out, but I wanted to take my initial idea for the project from "works for me" status to the point where I thought it was robust enough to release.

thank you for what you'd done so far, Are you able to share how you got streamlink to work? as i use it for other legal streaming sports ive come acustom to it

if its something your able to do . can you email me at sam410879@gmail.com

thank you
 
Old 03-01-2018, 05:02 PM   #5008
tonycpsu
Member
 
Registered: Apr 2014
Posts: 71

Rep: Reputation: Disabled
Quote:
Originally Posted by freddysmith View Post
thank you for what you'd done so far, Are you able to share how you got streamlink to work? as i use it for other legal streaming sports ive come acustom to it
It's not so much a question of getting streamlink itself to work, as it already supports HLS streams. What's needed is the authorization header, which you can only get via the MLB login process. The code for doing this is in session.py in the mlbstreamer source code.

If you have other subscriptions that provide HLS streams, you'd just need to do the same for them. I know the NHL uses MLB Advanced Media for their streaming platform, so it's possible this could work for NHL.tv with some tweaks, but I don't have an NHL.tv account.
 
Old 03-01-2018, 05:03 PM   #5009
fang2415
Member
 
Registered: Jan 2007
Posts: 195

Rep: Reputation: 15
Wow, great work tony, daftcat et al.! It looks like it'll take some tinkering to get it set up but I'm looking forward to it. Thanks so much for sharing your path to wherever the new MLBAM takes us this year!

tony, might it be worth setting up a donation site somewhere to see if people can at least pitch in enough to (self-interestedly) get you an MLB.tv subscription? As a starving grad student I'm no good for more than a few bucks, but I'd be happy to do that if it allows you to maintain the software I use.
 
Old 03-02-2018, 02:04 AM   #5010
jowski
Member
 
Registered: Aug 2007
Posts: 117

Rep: Reputation: 9
I gave the installation a shot and it requires root to do it. <Sarc> Some nonsense about permissions.</Sarc>

After installing, I tried "mlbplay --init-config" as a normal user and got the following:

Traceback (most recent call last):
File "/usr/bin/mlbplay", line 9, in <module>
load_entry_point('mlbstreamer==0.0.1', 'console_scripts', 'mlbplay')()
File "/usr/lib64/python2.7/site-packages/pkg_resources/__init__.py", line 542, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/lib64/python2.7/site-packages/pkg_resources/__init__.py", line 2569, in load_entry_point
return ep.load()
File "/usr/lib64/python2.7/site-packages/pkg_resources/__init__.py", line 2229, in load
return self.resolve()
File "/usr/lib64/python2.7/site-packages/pkg_resources/__init__.py", line 2235, in resolve
module = __import__(self.module_name, fromlist=['__name__'], level=0)
File "/usr/lib64/python2.7/site-packages/mlbstreamer/play.py", line 14, in <module>
from . import config
File "/usr/lib64/python2.7/site-packages/mlbstreamer/config.py", line 4, in <module>
from collections.abc import MutableMapping
ImportError: No module named abc

Not sure why but...

If you need more info or have something else that I can try; let me know.


Jim
 
  


Reply

Tags
help, install, installation, instructions, seek, vlc, windows



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
mlb.com gameday audio stream statmobile Linux - Newbie 6 05-06-2008 10:16 PM
link dies intermittently-seemingly at random- between win<->linux not linux<->linux?? takahaya Linux - Networking 10 03-09-2007 10:37 PM
triple boot linux/linux/linux No Windows involved toastermaker Linux - Newbie 12 03-02-2006 10:40 PM
Redhat (rhel v2.1) bootup problem with linux (linux vs linux-up) namgor Linux - Software 2 06-24-2004 02:49 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Software

All times are GMT -5. The time now is 07:10 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration