TypeError: cannot concatenate 'str' and 'function' objects python files -


I have to download an Rtmp video and I have an error

  error: 'str' And 'Function' objects  

I need help I have not seen this error at all, how do I solve the problem

  cmd = 'rtmpdump - R - t "sdjsds8" -r "'+ player +'" a "vod" -f "13,0,0,182 wins" w "http://website.fr/components/com_vodvideo/mediaplayer/player-licensed.swf "-P" http://website.fr "-y" mp4: '+ code +' "-o" MaVideo.flv ' 

Code:

  Import ConfigParser Import Requests, Again, OA Xrez import quality_SD Fonction_smil () xrez import from quality to xrez imported quality_HD from quality_FHD to sys: global resolution config = ConfigParser.ConfigParser () config.read ('config.ini') quality = config .Get ('setting', ' VIDEO_QUALITY ') Quality ==' 1080p ': resolution = (quality_FHD (' qualityFHD ')) elif quality ==' 720p ': resolution = (quality_HD (' qualityHD ')) elif quality = "480p": preface code As in = (quality_SD ('qualitySD')) url = resolution print "download with request" r = requests.get (url) with open ("video.smil", "west bengal"): code .write (r.content) for text in mykey Mayke = open ( "/ home / slurry / ADEN / Veedioksmil", "r"): matches = Reksrc ( "base =" (. *?) '', Text if match: vod_links = str (match.group (1)) Print print vod_links 'Téléchargement de la video ...' cmd = 'rtmpdump -v -t "fbfhfhfh" -r "' + Url + '"a" vod "-f" win 13,0,0,182 "w" http://website.com/components/com_vodvideo/mediaplayer/player-licensed.swf "-p" http://website.com "-y" mp4: '+ code +' o 'MaVidio.mp4' 'OS System (CMD)  

Edit

On my primary script, Error is on files and smil.py error ????

Call final): File "start.py", line 35, & lt; Module & gt; Fonction_smil file "files / smil.py" from Smile Import, line 30, & lt; Module & gt; If match: NameError: name 'match' is not defined

your url is not a string in the variable, but there is a function. You might want to "..." + url () + "..." .

There is a file in your code variable, there is no string, therefore, you can not do + with string . This will be the next problem :)


Comments

Popular posts from this blog

python - Overriding the save method in Django ModelForm -

html - CSS autoheight, but fit content to height of div -

qt - How to prevent QAudioInput from automatically boosting the master volume to 100%? -