2014-08-19, 14:05
I am not using list item function just play in py script and it works
I tried to make an error exeption saying:
that is my log file?
so I cant make an new line in python script? I do not get that.
Quote:#import re
#import sys
#import urllib
#import urlparse
#import xbmc
import xbmcgui
import xbmcplugin
file = 'rtmp://thereisanrtmpfiletoplay.com/'
xbmc.executebuiltin("xbmc.PlayMedia("+file+")")
I tried to make an error exeption saying:
Quote:file = 'rtmp://thereisanrtmpfiletoplay.com/'
now='Could not connect!'
#state if file is true just play item
#state if file is false show notification
def check():
if file:
print "1 - Got a true expression value"
print file
xbmc.executebuiltin("xbmc.PlayMedia("+file+")")
else:
print "1 - Got a false expression value"
print file
xbmc.executebuiltin('Notification(ERROR,'+now+',3000,)')
check()
#executing function ^
that is my log file?
Quote:instantiating addon using automatically obtained id of "plugin.video.teststv1" dependent on version 2.1.0 of the xbmc.python api
12:55:03 T:2156 ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
- NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
Error Type: <type 'exceptions.IndentationError'>
Error Contents: ('expected an indented block', ('C:\\Users\\pythonprofile\\AppData\\Roaming\\XBMC\\addons\\plugin.video.teststv1\\default.py', 25, 2, 'if file:\n'))
IndentationError: ('expected an indented block', ('C:\\Users\\pythonprofile\\AppData\\Roaming\\XBMC\\addons\\plugin.video.teststv1\\default.py', 25, 2, 'if file:\n'))
-->End of Python script error report<--
12:55:03 T:2156 INFO: Python script stopped
Quote:default.py', 25, 2, 'if file:\n
so I cant make an new line in python script? I do not get that.