Youtube-dl called from python script fails...why ? [solved]

Hi there,
since downloading youtube stuff with Browser plugins has been pretty unstable for me lately (read: mostly incomplete videos) I switched over to youtube-dl again. Unfortunately youtube-dl often stops downloading as well...
I wrote a small Python script which looks for incomplete downloads in my Youtube folder and restarts the download again. The code is quite simple:
#!/usr/bin/python
# -*- coding: utf8 -*-
# Modules used:
import sys, os
part_files = os.popen ("ls *.part")
for part_file in part_files:
target_name = part_file.strip()[:-5]
target_name = target_name.split(".")[0]
yt_id = target_name [len(target_name)-11:]
cli = 'youtube-dl -t http://www.youtube.com/watch?v=' + yt_id
print cli
os.popen (cli)
Unfortunately youtube-dl bombs out with the following stack trace and I have got no clue why...
youtube-dl -t http://www.youtube.com/watch?v=XNVaEoQMarg
Traceback (most recent call last):
File "/usr/lib/python2.7/runpy.py", line 162, in _run_module_as_main
"__main__", fname, loader, pkg_name)
File "/usr/lib/python2.7/runpy.py", line 72, in _run_code
exec code in run_globals
File "/usr/bin/youtube-dl/__main__.py", line 17, in <module>
File "/usr/bin/youtube-dl/youtube_dl/__init__.py", line 516, in main
File "/usr/bin/youtube-dl/youtube_dl/__init__.py", line 500, in _real_main
File "/usr/bin/youtube-dl/youtube_dl/FileDownloader.py", line 507, in download
File "/usr/bin/youtube-dl/youtube_dl/InfoExtractors.py", line 92, in extract
File "/usr/bin/youtube-dl/youtube_dl/InfoExtractors.py", line 87, in initialize
File "/usr/bin/youtube-dl/youtube_dl/InfoExtractors.py", line 313, in _real_initialize
File "/usr/bin/youtube-dl/youtube_dl/InfoExtractors.py", line 197, in report_lang
File "/usr/bin/youtube-dl/youtube_dl/FileDownloader.py", line 192, in to_screen
IOError: [Errno 32] Broken pipe
Does anybody have an idea why this happens ? Using youtube-dl without the "resume download" script works perfectly though...
TIA,
D$
Last edited by Darksoul71 (2013-06-06 11:00:51)

I think the problem is that you are using os.popen.
The function returns a file object to which the pipe of the new spawned process is connected. If you don't catch that file object, python might garbage collect it. (In addition, your script terminates, so the file object will be garbage collected).
Check out the subprocess module from the standard lib. I think there you can redirect the pipe of the new spawned processs to /dev/null or something.
http://docs.python.org/2/library/subprocess.html

Similar Messages

  • How to call a python script from a TestStand sequence?

    Please tell me how is it possible to call a python script from a TestStand sequence.
    Thank for your help in advance.
    Imre

    Here you can find some information about Python and LabVIEW:
    http://forums.ni.com/ni/board/message?board.id=170​&message.id=124424&query.id=149647#M124424
    If you have LabVIEW, you could use LabVIEW steps to call your Phyton Scipts.
    Another solution would be, to do, what is decriibed in the thread directly in TestStand:
    You can call a dll or .NET assemblies directly from teststand, or use the "Call Executable" TestStep.

  • Calling a python Script from an AE Script

    I'm trying to create a little automation script to inegrate my studios's pipline with our Shotgun page.
    I have the python cript working as "myScripy.py <arguments>" Where arguments are comp names to be updated.
    i was hoping i could create an array of selected comps and run the script once for each using:
    myPythonScript = "c:\\PythonScripts\\myScript.py " + selectedCompNameVariable
    system.callSystem(myPythonScript)
    It appears to attempt to call the pythong script via command line, but i get the following error:
    "After Effects warning: ERROR: %1 is not a valid Win32 application"
    Why is this? Can I not call a python script on my computer via this command?

  • Call a python script from perl file

    This is my first post and am not sure if this is the right forum to post this query. If this is not the right forum, pls redirect me to the appropriate forum.
    Query :
    I have a python script which was created through WLS console's recording feature. I have to call this python script from a perl script (dte topo block).
    Any pointers towards how this can be achieved ?
    Thanks,
    Madhusudan

    I am using inline python to execute python statements directly from the perl script. However, i get below error :
    [maddeshp@slc01auw forDTE]$ perl -c intro.pl
    Can't find string terminator "END_OF_PYTHON_CODE" anywhere before EOF at intro.pl line 2.
    Has anyone run into this problem ? Any suggestions on fixing this ?
    Thanks,
    Madhusudan

  • Subroutine call from SAP Script

    Hi,
    I need to calculate required/outstanding qty. hence am passing existing values of reservation#/item# and issued qty.
    both req/out qty are returned blank by the code. please help.
    Following is my code segment for a external routine call from SAP Script.
    /:   PERFORM P_GET_QTY IN PROGRAM ZTEST
    /:   USING &MSEG-RSNUM&                     
    /:   USING &MSEG-RSPOS&                     
    /:   CHANGING &REQ_QTY&                     
    /:   CHANGING &MSEG-MENGE&                  
    /:   CHANGING &OUT_QTY&                     
    /:   ENDPERFORM
    REPORT ztest .
    TABLES resb.
    DATA: wa_resb TYPE resb,
          req_qty TYPE resb-bdmng,
          isd_qty TYPE mseg-menge,
          out_qty TYPE resb-bdmng.
    FORM p_get_qty TABLES input  STRUCTURE itcsy
                          output STRUCTURE itcsy.
      DATA: avlbl TYPE resb-bdmng.
      READ TABLE input WITH KEY 'MSEG-RSNUM'.
      CHECK sy-subrc = 0.
      wa_resb-rsnum = input-value.
      READ TABLE input WITH KEY 'MSEG-RSPOS'.
      CHECK sy-subrc = 0.
      wa_resb-rspos = input-value.
      READ TABLE input WITH KEY 'REQ_QTY'.
      CHECK sy-subrc = 0.
      req_qty = input-value.
      READ TABLE input WITH KEY 'MSEG-MENGE'.
      CHECK sy-subrc = 0.
      isd_qty = input-value.
      SELECT SINGLE * INTO wa_resb
                      FROM resb
                      WHERE rsnum = wa_resb-rsnum
                      AND   rspos = wa_resb-rspos.
      CHECK sy-subrc = 0.
      avlbl   = wa_resb-bdmng - wa_resb-enmng.
      req_qty = avlbl - out_qty.
      out_qty = req_qty - isd_qty.
      output-name = 'REQ_QTY'.
      output-value = req_qty.
    MODIFY output TRANSPORTING name value WHERE name = 'REQ_QTY'.
      APPEND output.
      output-name = 'OUT_QTY'.
      output-value = out_qty.
    MODIFY output TRANSPORTING name value WHERE name = 'OUT_QTY'.
      APPEND output.
    ENDFORM.
    Thanks,
    Ram.

    Hi Ram,
    I think you have to use MODIFY instead of append for the OUTPUT table.
    MOdify the table with KEY. This should resolve the problem.
    Ram, you can check this code and see how the MODIFY is to be used.
    REPORT YLSD999A.
    DATA  W_LENGTH TYPE I.
    *   GENERAL PURPOSE SUBROUTINES FOR CALLING FROM SAPSCRIPTS
    FORM DISPLAY_POUND TABLES IN_TAB STRUCTURE ITCSY
                              OUT_TAB STRUCTURE ITCSY.
      DATA: COUNT TYPE P VALUE 16.
      DATA: W_VALUE(17) TYPE C.        "defined as 7 chars to remove pence
      DATA: W_CHAR TYPE C.
      DATA: W_DUMMY TYPE C.
      DATA: W_CURR(3) TYPE C.
    *    Get first  parameter in input table.
      READ TABLE IN_TAB INDEX 1.
      WRITE IN_TAB-VALUE TO W_VALUE .
    * get second parameter in input table
      READ TABLE IN_TAB INDEX 2.
      MOVE IN_TAB-VALUE TO W_CURR.
      IF W_CURR = 'GBP'.
        W_CURR = '£'.
      ENDIF.
      W_LENGTH = STRLEN( W_CURR ).
    *    look for first space starting at right.
      WHILE COUNT > -1.
        W_CHAR = W_VALUE+COUNT(1).
    *  W_CHAR = IN_TAB-VALUE+COUNT(1).
        IF W_CHAR = ' '.
          COUNT = COUNT - W_LENGTH + 1.
          W_VALUE+COUNT(W_LENGTH) = W_CURR.
          COUNT = -1.
        ELSE.
    *     W_VALUE+COUNT(1) = W_CHAR.
          COUNT = COUNT - 1.
        ENDIF.
      ENDWHILE.
    * read only parameter in output table
      READ TABLE OUT_TAB INDEX 1.
      OUT_TAB-VALUE = W_VALUE.
      MODIFY OUT_TAB INDEX SY-TABIX.
    ENDFORM.
    Cheers
    VJ

  • UCCE: Forceful Release an Agent Call from ICM Script, Can I?

    Hi, let me explain the requirement first. Customer wants to make their IVR free of cost but they want to start billing only when the call is landed to skill group/agent. So far I can think to make it possible by triggering their billing server by ODBC gateway through Application Gateway process. But also the customer wants to release that particular call when that pre-paid caller is out of charge. They might trigger one of my application or can modify any particular database field and put the calling# into there and my task would be release that call.
    I have thought an idea to develop a TCL script run into the voice gateways and release the call from there by searching the particular call with calling#, but I do not know TCL scripting or any idea how to develope TCL , can't I release that call from ICM script? Do I have any control on calls from ICM when the call is landed and connected to agent?
    Any help would be hightly appreciated.

    That's a nasty piece of work. Just imagine how jacked off you would be if you are the customer, you have enough in your bank account to get to an agent who is then starting to help you, and in the middle of your conversation you are simply cut off!
    I don't think it's possible - although CVP would be your best shot because of the switch leg.
    But not only that, I don't think it is desirable. If you check the customer's balance before going to an agent, that should be sufficient. Anything else is just terrible customer service.
    Regards,
    Geoff

  • Is there a way I can call a python script from within a Robohelp script?

    Hi,
    I want to integrate an external python script into the current extendscript I use in RoboHelp 10.  Is there a way to do that?
    Thanks,
    Lauren

    You can use the command line to call any kind of external application.
    Personally, I use the following function to create bat files to do such
    work.
    I've taken these functions from my free RH Extendscript library -
    http://www.wvanweelden.eu/product/robohelp-extendscript-library
    function ExecuteBatchFile(command, waitforbatch) {
         if(string_isEmpty(command))
             return false;
         if(!waitforbatch) {
             if(waitforbatch != false) {
                 waitforbatch = true;
         var path = Folder.appData.fsName + '/';
         var batFileName = 'ExtendScriptBatchFile';
         var batFileExtension = '.bat';
         var batFile = new File(pathbatFileNamebatFileExtension);
         if(batFile.exists) {
             var i  = 0;
             while(batFile.exists) {
                 i++;
                 batFile = new File(pathbatFileNamei+batFileExtension);
         command+= "\ndel /F /Q \"" + batFile.fsName + "\"";
         writeFile(batFile, command, false);
         if(!isFile(batFile, true))
             return false;
         batFile.execute();
         /* Wait on batch file execution if needed */
         if(waitforbatch) {
             while(batFile.exists) {
                 msg(".");
                 $.sleep(100);
         return true;
    function writeFile(file, szOutput, encoding) {
         var szFilePath = file.fsName;
         if(!encoding || encoding == true) {
            encoding = "UTF-8";
         var fileObj = new File(szFilePath);
         fileObj.encoding = encoding;
         fileObj.open("w");
         fileObj.write(szOutput);
         fileObj.close();
    Kind regards,
    Willam

  • RFC function call from VB Script

    I have an RFC enabled function that I need to call from VBScript.  I was working through this issue as a BAPI call but after research and RFC not initialized error messages over and over I am coming to think that the issue is not how I was doing it but what I was trying to do with different objects. 
    I think the issue is that I was trying to call a RFC function with BAPI methods, I didnt understand that there was I difference but now I do.  I don't know how to initialize the RFC on the host system and unsure if I even have all of the components on the host system to make these function calls.
    The goal here is to call a function that passes 3 paramters and modifies a user object in SAP.

    Hello John,
       are you using DCOM Connector? I have a VBScript working correctly, using DCOM Connector, and consuming a Z function module defined as RFC.
    What's the error message you're getting?
    Regards
    Michael

  • Query v$ views from shell script fail

    Hi everybody,
    the query below is runing well with a SQL*PLUS (database is mounted and not open)
    SQL> SELECT member FROM v$logfile;
    MEMBER
    +DATA/testgfi/onlinelog/group_1.298.773871647
    +DATA/testgfi/onlinelog/group_2.294.773871647
    +DATA/testgfi/onlinelog/group_3.295.773871647
    But Giving error if I run it from Shell script ???
    $ sqlplus -s '/ as sysdba' << EOF
    SELECT member FROM v$logfile;
    EOFSELECT member FROM v
    ERROR at line 1:
    ORA-01219: database not open: queries allowed on fixed tables/views only..
    Please help..
    Thanks..
    Aljaro

    Aljaro wrote:
    Hi everybody,
    the query below is runing well with a SQL*PLUS (database is mounted and not open)
    SQL> SELECT member FROM v$logfile;
    MEMBER
    +DATA/testgfi/onlinelog/group_1.298.773871647
    +DATA/testgfi/onlinelog/group_2.294.773871647
    +DATA/testgfi/onlinelog/group_3.295.773871647
    But Giving error if I run it from Shell script ???
    $ sqlplus -s '/ as sysdba' << EOF
    SELECT member FROM v$logfile;
    modify as below
    SELECT member FROM v\$logfile;

  • PVII Called From External Script?

    I have a site that uses Auto ShowHide by PVII for dropdown
    menus. I'm trying to clean up my code and wondering if its possible
    to call these behaviors from an external script. I am already do
    this with javascripts. The first part of the script looks like this
    below.
    <body
    onload="P7_autoHide('Chakra','Chakra2','Pendants2','Wands','amazingwands','signs');MM_pre loadImages('images/fwnavbar_r1_c14_f2.jpg','images/fwnavbar_r1_c12_f2.jpg','images/zodiacd own.gif','/images/crowndown.gif','/images/thirdeyedown.gif','/images/throatdown.gif','/ima ges/heartdown.gif','/images/solardown.gif','/images/sacarldown.gif','/images/basedown.gif' ,'images/fwnavbar_r1_c6_f2.jpg','images/fwnavbar_r1_c10_f2.jpg','images/fwnavbar_r1_c8_f2. jpg','images/fwnavbar_r1_c4_f2.jpg','images/fwnavbar_r1_c2_f2.jpg','images/wanddown.gif',' images/pendantdown.gif','images/chakradown.gif','images/runesdown.gif','images/pendantzodd own.gif','images/booksdown.gif','images/mirrorsdown.gif','images/aquariusdown2.gif','image s/ariesdown.gif','images/taurusdown.gif','images/geminidown.gif','images/leodown.gif','ima ges/capricorndown.gif','images/sagitdown2.gif','images/cancerdown.gif','images/libradown.g if','images/virgodown.gif','images/crystaldown2.gif','images/7chakradown.gif','images/mass agedown.gif','images/acupdown.gif','images/kyanite.gif','images/pendwandown.gif','images/f airydown.gif','images/hairdown.gif','images/incensedown.gif','images/crystalballsdown.gif' ,'images/customdown.gif','images/runeproddown.gif','images/legenddown2.gif','images/pisces down.gif','/images/scorpiodown2.jpg')">
    <script language="JavaScript" src="script3.js"
    type="text/javascript">
    </script>
    <div id="Wands" style="position:absolute; left:105px;
    top:453px; width:79px; z-index:1; overflow: hidden; height: 31px;"
    class="dropdown"
    onmouseover="P7_autoLayers(0,'Wands','Chakra');P7_Snap('seven','Chakra',80,99)">
    <div align="center"><a href="seven.htm"
    onmouseout="MM_swapImgRestore()"
    onmouseover="MM_swapImage('wand','','images/wanddown.gif',1)"><img
    src="images/wandup.gif" alt="Seven Chakra Wands" name="wand"
    width="80" height="15" vspace="0" border="0" id="wand"
    /></a><a href="chakrapendants.htm"
    onmouseout="MM_swapImgRestore()"
    onmouseover="MM_swapImage('chakrapendants','','images/pendantdown.gif',1)"><img
    src="images/pendantup.gif" alt="Seven Chakra Pendants"
    name="chakrapendants" width="80" height="15" border="0"
    id="chakrapendants" /></a></div>
    http://www.thechakrashop.com
    Any help would be appreciated
    Thanks,
    Trinoz

    Hi Suhas,
    Nice to know you became Moderator...
    Hmmm the solution you provided was the last option..
    Any ways the issue is resolved we changed the user to dialog user and then debugged the code.
    Thanks a Lot,
    Anmol.

  • ODBC access from HTA script fails

    I am trying to connect to Oracle via ADO from a HTA(HTML Application) script.
    I have trying both DSN and DSNLESS connections, see code below.
    I have also tried the Microsoft ODBC for Oracle, Oracle 9i ODBC and Oracle10g ODBC drivers.
    I have tried doing the connection from both vbscript and javascript.
    Everything I try gives me the "[Microsoft][ODBC Driver Manager} Driver's SQLSetConnectAttr failed" error.
    Any help will be greatly appreciated!
    *** CODE ***
    <script Language="JavaScript"><!--
    function dotheconnectionx()
    var sConnect="DSN=prod2;UID=tts;PWD=tts";
    var objConnx= new ActiveXObject( "ADODB.Connection" );
    objConnx.Open( sConnect );
    alert(objConnx.errors.count);
    alert(objConnx.errors(0).description);
    //--></script>
    <script language="vbscript">
    Dim objConn
    Dim rsetQuery
    Dim tmpSQL
    Dim tmpDSN
    tmpDSN="DSN=prod2;uid=tts;pwd=tts"
    Dim strConn
    strConn="Driver={Microsoft ODBC for Oracle}; CONNECTSTRING=prod; uid=TTS; pwd=tts;"
    sub dotheconnection
    Set objConn = CreateObject("ADODB.Connection")
    objConn.ConnectionString = tmpDSN
    objConn.Open
         If objConn.errors.count <> 0 Then
              alert(objConn.errors.count)
              alert("problem connecting to the database")
              alert(objConn.errors(0).description)
              alert(objConn.ConnectionString)
         end if
    end sub
    </script>
    <body onload="dotheconnection();">

    This is running off my laptop for development and I have several version of the Oracle client installed. Specifically 8, 9 and 10.
    I can connect via ODBC from a query tool using the specified DSN and can connect to the specified database using several Oracle tools.
    I haven't tried doing this from a VBS but I will try that to see if it works or gives any diagnostic info
    I tested as a vbscript .VBS and get the same results and the .HTA
    *** vbscript code ***
    Dim objConn
    Dim rsetQuery
    Dim tmpSQL
    Dim tmpDSN
    tmpDSN="DSN=prod2;uid=tts;pwd=tts"
    Dim strConn
    strConn="Driver={Microsoft ODBC for Oracle}; CONNECTSTRING=prod; uid=TTS; pwd=tts;"
    sub dotheconnection
    Set objConn = CreateObject("ADODB.Connection")
    objConn.ConnectionString = strConn
    objConn.Open
         If objConn.errors.count <> 0 Then
              Wscript.echo objConn.errors.count
              Wscript.echo "problem connecting to the database"
              Wscript.echo objConn.errors(0).description
              Wscript.echo objConn.ConnectionString
         end if
    end sub
    dotheconnection()
    Edited by: JL Hainsworth on Mar 10, 2009 1:32 PM

  • Calling Python Script from LabVIEW

    Hello Everyone,
    I want to call the Python script from LabVIEW.
    I tried with using at the command line but i am unable to run that script file..
    i have gone through LabPython but i am unable to call the scripts from there also..
    If someone has an example of a VI which invokes a python script, it will be very helpful...
    Thanks a lot in advance
    Regards
    Avni

    avni wrote:
    I have to invoke the Script file at command prompt.
    Can you descriobe your restriction(s) concerning "invoke the script at the command prompt"?  There may be ways around that.

  • How to execute "cd" comaand from a python script

    Hi All,
    I want to write a python script where I want to call another Python script which accepts some commandline arguments and is in some other location. I am not u derstanding that how can I execute the "cd" command in my python script to go to that particular location where the other python script exist.
    Please guide...
    Thanks in Advance.

    Moderator Action:
    This post was originally in the Oracle Linux forum.
    That is NOT for Oracle-on-Linux questions. It is a forum for questions specific to that distro of Linux.
    You have a Python question.
    The post has been relocated to the Database General forum.
    @ O.P.:
    Maybe this will help. It was the first result from Google when searching on keywords `oracle python`:
    http://www.oracle.com/technetwork/articles/dsl/python-091105.html

  • Calling a .py script inside a .VI, using anaconda's Libraries or specific python version (SystemExec.vi(?), MAC OSX)

    Hi,
    I'm new to both mac and LabView, so it may well be something obvious I'm missing.
    I'm trying to use System Exec (http://zone.ni.com/reference/en-XX/help/371361L-01/glang/system_exec/ with LabVIEW 2014 on Mac OS X Mavericks) to call a python script to do some image processing after taking some data and saving images via LabView.
    My problem is that I cannot figure out how to point it to the correct version/install of python to use, as it seems to use the pre-installed 2.7.5 apple version no matter whether that's set to be my default or not (and hence, it can't see my SciPy, PIL etc. packages that come with my Anaconda install).
    It doesn't seem to matter whether I have certain packages installed for 2.7 accessable via the terminal, the LabView System Exec command line can't seem to find them either way and throws up an error if a script is called that imports them.
    I've tried changing the working directory to the relevant anaconda/bin folder, I've also tried
    cd /Applications/anaconda/bin; python <file.py> 
    as the CL input to system exec, but it's not wanting to use anything other than the apple install. I've tried Anaconda installs with both python 2.7 and 3.4, so it doesn't seem to be down to the 3.* compatibility issues alone.
    Printing the python version to a string indicator box in LV via python script gives the following:
    2.7.5 (default, Mar 9 2014, 22:15:05)
    [GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.0.68)]
    Whereas via the terminal, the default version is the anaconda install I'd like to use, currently
    Python 3.4.1 |Anaconda 2.1.0 (x86_64)| (default, Sep 10 2014, 17:24:09)
    [GCC 4.2.1 (Apple Inc. build 5577)] on darwin
    I can do which python3.4 on the sys exec CL input to get the correct /anaconda/bin location, but if I try  python3.4 <file.py>, I just get a Seg fault.
    I've found examples for System Exec use and instructions for calling python scripts with specific versions, but neither works with Mac (frustratingly).
    I've also tried editing the Path Environment Variable, and tried getting rid of the python 2.7 install entirely, but none of these work either (the latter just causing errors all over the shop).
    So, in summary
    I'd just like to know how to specify the python version LabView uses and to have use of the corresponding python libraries.
    Either python version (2 or 3) will do, I'd just like to be able to use my libraries which came with Anaconda which I'll be writing my scripts with (which I installed as the correct packages are only compatible with a specific python version on Mac, which is not the specific version that Xcode was compatible with, argh).
    All packages work normally when using the Anaconda version with the terminal or with Spyder.
    Is there a function I can use other than System Exec? What am I missing?
    Please help.

    janedoe777 wrote:
    Accidental. Also, that's not terribly helpful.
    What exactly does that mean?
    I'm not debating whether it was accidental or intentional.  It certainly isn't helpful to post the same message twice.
    It is helpful to point out this message is a duplicate so people don't waste their time answering this one if you are already being helped in the other one.

  • Using launchctl with python script

    I have been trying to get launchctl to run a python script for me every 3 minutes. I have read many threads and such to no avail. Following describes files and such.
    PLIST file location = /Users/mike/Library/LaunchAgents
    File name = scraper.plist
    File owner:group = mike:staff
    File contents =
    <?xml version="1.0" encoding="UTF-8"?>
    <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/Prope
    <plist version="1.0">
    <dict>
    <key>Label</key>
    <string>scraper</string>
    <key>OnDemand</key>
    <true/>
    <key>Program</key>
    <string>/Users/mike/scripts/python/backgroundscript/runscraper.sh</string>
    <key>RunAtLoad</key>
    <true/>
    <key>StandardErrorPath</key>
    <string>/Users/mike/scripts/python/backgroundscript</string>
    <key>StartInterval</key>
    <integer>3</integer>
    </dict>
    </plist>
    SCRIPT INFO:
    Location = /Users/mike/scripts/python/backgroundscript/
    File name = runscraper.sh
    File Contents =
    #!/bin/sh
    say "hey mike"
    /usr/bin/python /Users/micahrye/scripts/python/backgroundscript/scraper.py
    File owner:group = mike:staff (fro scraper.py and runscraper.sh)
    File permissions = 755 (fro scraper.py and runscraper.sh)
    NOW about the script, I have the shell script runscraper.sh call the python script. All works from the cmd line, but does not work when launchctl calls it. I put the following in the runscraper script to make sure it was getting called:
    say "hey mike"
    So every time launchctl calls runscraper.sh I hear the "hey mike," so I know that launchctl is calling it, BUT it does not seem to call or launch the python!!!! AGAIN, if I run runscraper.sh from the cmd line I hear "hey mike" and the python script run with no problems.
    I have checked log files and found nothing.
    I have tried many things and nothing has worked, would enjoy someones wisdom
    thanks

    Post to the Unix forum under OS X Technologies.

Maybe you are looking for

  • Ipod not recognised by finder, updater or itunes

    whilst updating my ipod (older version 30gb with dock) with my mac last night (power mac G5) - there was a problem which meant that i had to restart the mac. now the mac doesn't recognise the ipod (not seen in finder or itunes) and i can't restore it

  • How to skip validation using serverListener

    Hi, I am using Jdev 11.1.2.3.0 My requirement was to called some action using the keyboard key. I tried with Access key first but its behaving differently in different browser. Crome: allowing action on access key press. IE : setting the focus on com

  • HT1420 I can't find the authorize this computer prompt

    I am trying to authorize my new imac so I can download the song list from my iphone.  I looked in itunes but do not see how to do it.  I have 4 products authorized so I should be able to add my imac.  I read the instructions in Itunes support but I d

  • What are the  configuration tht pi administration have to perform

    hi friends   i am new to pi can any one help me what are the  configuration tht pi administration have to perform and post installation to be done after installing pi in stand alone box? plz help thnks ravi

  • Fact table data type changed from int to nvarchar -- rebuild on cube fails

     I change one of my data types in the Fact table from INT to Nvarchar... When I look at the properties it appears correct but when I try to Process it fails still thinking it's data type INT.  How can the DSV be refreshed( I did try REFRESH  and it n