<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Running a python script on a raspberry pi]]></title><description><![CDATA[<p dir="auto">Hello. I am having trouble running a python script using TriggerCMD on a Raspberry Pi. I have the agent installed as root and running in the background. I am able to do various things such as shutdown, reboot, and open applications. The agent runs the commands perfectly for that but when I try to run a python script nothing happens.</p>
<p dir="auto">For the script I tried a number of things:<br />
command:"python /home/pi/script.py" (also tried with root and with the escapes for the backslashes<br />
command:"sudo su user -c python /home/pi/script.py"<br />
then I tried to point to actual location of the python installation but nothing.  I just wanted to run a script that was all. Thank you in advance.</p>
]]></description><link>https://www.triggercmd.com/forum/topic/1681/running-a-python-script-on-a-raspberry-pi</link><generator>RSS for Node</generator><lastBuildDate>Thu, 21 May 2026 07:16:39 GMT</lastBuildDate><atom:link href="https://www.triggercmd.com/forum/topic/1681.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 01 Oct 2021 00:45:55 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Sat, 24 Jun 2023 04:25:07 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/1">@Russ</a><br />
Thank you Russ for looking into it.</p>
<p dir="auto">With the startup, I was referring to the RPI starting / booting up from being turned off. I noticed that the issue only happens from the RPI starting up and on the first instance a command is run. The next time a command is run, the command executes without issue. The main problem is the xdotool command not being executed on this first instance. However, the page is loaded.</p>
<p dir="auto">Also, I do have TriggerCMD installed as a background agent using that command and I do have xhost+ addeed to the end of the /etc/profile</p>
]]></description><link>https://www.triggercmd.com/forum/post/7141</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/7141</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Sat, 24 Jun 2023 04:25:07 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Tue, 20 Jun 2023 22:25:27 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a>,</p>
<p dir="auto">I tested it on my Raspberry Pi, except I used DISPLAY=:0 instead of DISPLAY=0.0.</p>
<pre><code>"su - pi -c 'export DISPLAY=:0; /usr/bin/chromium-browser https://www.yt.com/subscriptions/; sleep 5; xdotool mousemove 300 400; xdotool click 1;'"
</code></pre>
<p dir="auto">It worked every time after I ran <strong>triggercmdagent</strong> as root on my Raspberry Pi.</p>
<p dir="auto">You wrote, "The first its run after startup, ..." What's startup?  Do you mean startup of the triggercmd agent, or startup of the Raspberry Pi?</p>
<p dir="auto">Edit: I just realized you're probably having your RPi login automatically as pi, and you've installed the background agent.  I'll try that next.</p>
<p dir="auto">I tried it and it works every time for me.  I installed the background agent with this command:</p>
<pre><code>/usr/share/triggercmdagent/app/src/installdaemon.sh
</code></pre>
<p dir="auto">I switched the "ground" field to "background" of course, so my entry looks like this:</p>
<pre><code>    {
      "trigger": "Test",
      "command": "su - pi -c 'export DISPLAY=:0; /usr/bin/chromium-browser https://www.yt.com/subscriptions/; sleep 5; xdotool mousemove 300 400; xdotool click 1'",
      "ground": "background",
      "voice": "test",
      "allowParams": "false"
    }
</code></pre>
<p dir="auto">I also added <strong>xhost +</strong> to the end of my /etc/profile so it's enabled during boot.</p>
]]></description><link>https://www.triggercmd.com/forum/post/7131</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/7131</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Tue, 20 Jun 2023 22:25:27 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Mon, 19 Jun 2023 13:46:46 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/1">@Russ</a><br />
Hello again Russ. I have the command simply running from the commands.json. The command is just the one you had helped me with previously. The command opens a website, waits for a few seconds, and then its a xdotool command.</p>
<p dir="auto">The command I am trying to run is:<br />
"su - pi -c 'export DISPLAY=0.0; /usr/bin/chromium-browser <a href="https://www.yt.com/subscriptions/" rel="nofollow ugc">https://www.yt.com/subscriptions/</a>; sleep 5; xdotool mousemove 300 400; xdotool click 1;'"</p>
<p dir="auto">The first its run after startup, nothing happens. If I run the same command again, it executes without issue. I tried to tinker with it this weekend to save some time on diagnostics, but the same issue continues to persist.</p>
]]></description><link>https://www.triggercmd.com/forum/post/7130</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/7130</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Mon, 19 Jun 2023 13:46:46 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Fri, 16 Jun 2023 19:51:15 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a>, can you share your scripts and commands.json entry?  I'll see if I can reproduce the problem and solve it this weekend.</p>
]]></description><link>https://www.triggercmd.com/forum/post/7125</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/7125</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Fri, 16 Jun 2023 19:51:15 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Fri, 16 Jun 2023 04:01:14 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/1">@Russ</a><br />
Thank you again Russ. Unfortunately, that did not work either. The script only executes after run it again.</p>
]]></description><link>https://www.triggercmd.com/forum/post/7124</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/7124</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Fri, 16 Jun 2023 04:01:14 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Wed, 14 Jun 2023 12:36:36 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a>, I'm not sure why that didn't work.  I thought what's in /etc/profile runs for every user, so when your pi user logs in it should run.  Have you tried adding it to pi's ~/.bashrc file?  That's another thing you could try.</p>
<p dir="auto">If it still doesn't work, let me know.  I'll setup one of my Pi's with XWindows and see if I can figure it out.</p>
]]></description><link>https://www.triggercmd.com/forum/post/7118</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/7118</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Wed, 14 Jun 2023 12:36:36 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Wed, 14 Jun 2023 05:12:13 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/1">@Russ</a><br />
Thank you Russell. I had xhost + in that location (ie. etc/profile and at the end of the file) and I believe I had it there based on your previous instructions. I tinkered around further this evening and I found that problem only occurs after an initial startup. If the command is started again after occurring a start-up (ie. run again after startup) then it works without issue. I tried to circumvent the issue with a delay  and that did not work. I found a workaround of commanding the script to run again, but I wanted to get the script working as it previously was and if it was possible. I was wondering if you happen to know why this might be the case. Thank you in advance</p>
]]></description><link>https://www.triggercmd.com/forum/post/7116</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/7116</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Wed, 14 Jun 2023 05:12:13 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Mon, 12 Jun 2023 23:26:19 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a>, please try this:</p>
<p dir="auto">Add this line to your <strong>/etc/profile</strong> file:</p>
<pre><code>xhost +
</code></pre>
<p dir="auto">I think that will make it persist.</p>
]]></description><link>https://www.triggercmd.com/forum/post/7109</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/7109</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Mon, 12 Jun 2023 23:26:19 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Mon, 12 Jun 2023 03:06:27 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/1">@Russ</a></p>
<p dir="auto">Hello Russ,</p>
<p dir="auto">I hope you are doing well! I had an issue arise with "xhost +". Previously, my scripts would run using xdotool without issue. I would simply say the particular command (through assistant or wherever) and the xdotool command would be executed. Now, I can only get the xdotool commands executed after I type "xhost +" in the linux command terminal, but not after the initial startup of the Raspberry Pi.</p>
<p dir="auto">I am curently running a Raspberry Pi 4 with debian (i can't recall which version but can provide the specifics if necessary). I recently updated through apt-get etc and that is when the issue arose. Thank you in advance and any help would be much appreciated.</p>
]]></description><link>https://www.triggercmd.com/forum/post/7103</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/7103</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Mon, 12 Jun 2023 03:06:27 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Wed, 06 Oct 2021 21:20:35 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a> , no problem. Thanks for sharing your TRIGGERcmd use cases.</p>
]]></description><link>https://www.triggercmd.com/forum/post/4678</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4678</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Wed, 06 Oct 2021 21:20:35 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Wed, 06 Oct 2021 15:55:34 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/1">@Russ</a> Thank you kindly Russ. Everything is running properly and I have been able to program in what I wanted. Thank you and I apologize for the trouble. I don't know how many times you have dealt with these issues specifically</p>
]]></description><link>https://www.triggercmd.com/forum/post/4676</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4676</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Wed, 06 Oct 2021 15:55:34 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Wed, 06 Oct 2021 00:45:54 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a>, this worked for me:</p>
<pre><code>su - pi -c 'export DISPLAY=:0.0; /usr/bin/chromium https://google.com'
</code></pre>
]]></description><link>https://www.triggercmd.com/forum/post/4671</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4671</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Wed, 06 Oct 2021 00:45:54 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Tue, 05 Oct 2021 16:37:43 GMT]]></title><description><![CDATA[<p dir="auto">Thank you Russ. It works as expected and I was able to write in the commands. They are all working. I just needed to add export to the command. However, I am having one problem with chromium-browser though. When it is launched, it's launched in root I believe because all the bookmarks and everything are not there. I had the same issue with a media player but I was able to launch it with this command no problem:</p>
<pre><code>"command":"echo pi | sudo -S su pi-c '/usr/bin/&lt;app-location&gt;'"
</code></pre>
<p dir="auto">I tried the same command with chromium (and with --no-sandbox) and nothing happens (also tried with the export DISPLAY command). Is there a way to do this at all? I just wanted to launch a website from user and still have access to what I saved on the user chromium? I tried --user-data-dir and --add-user commands as well.</p>
]]></description><link>https://www.triggercmd.com/forum/post/4665</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4665</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Tue, 05 Oct 2021 16:37:43 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Tue, 05 Oct 2021 12:33:44 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a>, good question.  I think this should work:</p>
<pre><code>DISPLAY=:0.0; xdotool mousemove 500 500
</code></pre>
]]></description><link>https://www.triggercmd.com/forum/post/4662</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4662</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Tue, 05 Oct 2021 12:33:44 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Tue, 05 Oct 2021 03:52:38 GMT]]></title><description><![CDATA[<p dir="auto">Thank you kindly Russ. It is working perfectly now and this is all pretty neat so far. For the bash script issue, I was putting the "export DISPLAY" line in the wrong place.</p>
<p dir="auto">I just had one question. Is it possible to chain these commands in one line in the TriggerCMD command line? so for example "command":"export DISPLAY=:0.0 | xdotool mousemove 500 500" or something along those lines. I was just wondering for the sake of minimizing the number of scripts for certain things.</p>
]]></description><link>https://www.triggercmd.com/forum/post/4658</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4658</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Tue, 05 Oct 2021 03:52:38 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Mon, 04 Oct 2021 23:30:03 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a>, I think I found the problem.</p>
<p dir="auto">Here's how to fix it:</p>
<ul>
<li>In your bash script, add this command before it runs your Python script:<br />
export DISPLAY=:0.0</li>
<li>In one of your bash shells running as the pi user, run:<br />
xhost +</li>
</ul>
<p dir="auto">By default, root doesn't have a DISPLAY variable set, so xdotool doesn't know what X windows to talk to.</p>
<p dir="auto">X windows also doesn't allow other users to interact with the X windows desktop by default.  That <strong>xhost +</strong> command allows it.</p>
<p dir="auto"><img src="/forum/assets/uploads/files/1633389659952-92d4be45-3a44-46ab-8e6b-9874345e2dc7-image.png" alt="92d4be45-3a44-46ab-8e6b-9874345e2dc7-image.png" class=" img-fluid img-markdown" /></p>
<p dir="auto">One thing to keep in mind - if you're running a command in the background service, it will run as root, so will have root's environment variables.  The pi user has a DISPLAY variable set, but root doesn't have it by default.</p>
]]></description><link>https://www.triggercmd.com/forum/post/4656</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4656</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Mon, 04 Oct 2021 23:30:03 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Sun, 03 Oct 2021 02:48:23 GMT]]></title><description><![CDATA[<p dir="auto">Of course. The python script was simply this to begin with:</p>
<pre><code>import subprocess
subprocess.call(["xdotool", "mousemove", "945", "132"])
</code></pre>
<p dir="auto">I basically took it from here on stackoverflow - <a href="https://stackoverflow.com/questions/9681959/how-can-i-use-xdotool-from-within-a-python-module-script/44608709" rel="nofollow ugc">https://stackoverflow.com/questions/9681959/how-can-i-use-xdotool-from-within-a-python-module-script/44608709</a>. This was just something basic for now to make sure it was working okay with TriggerCMD. The script executes and the cursor moves when called from console or through an editor. With TriggerCMD, it doesn't get launched for some reason, but the append to txt file still happens.</p>
]]></description><link>https://www.triggercmd.com/forum/post/4650</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4650</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Sun, 03 Oct 2021 02:48:23 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Sun, 03 Oct 2021 01:34:06 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a>, that's good news.</p>
<p dir="auto">If you want to share your python script I might be able to figure out what's happening with xdotools.</p>
]]></description><link>https://www.triggercmd.com/forum/post/4649</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4649</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Sun, 03 Oct 2021 01:34:06 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Sat, 02 Oct 2021 17:43:04 GMT]]></title><description><![CDATA[<p dir="auto">Thank you again Russ. I have some good news to report. I forgot to make the bash script executable. Now, the <a href="http://test.py" rel="nofollow ugc">test.py</a> works and the .txt file is appended in the tmp folder. However, there is now a problem with a particular line of code not executing.</p>
<p dir="auto">So after the <a href="http://test.py" rel="nofollow ugc">test.py</a> worked, I tried to change the script to just having an xdotools command. I tried it and that particular line of code is not being executed. I then tried the original <a href="http://test.py" rel="nofollow ugc">test.py</a> with the line added at the bottom. The script appended into the tmp folder again but did not execute the line of code with xdotools in it.</p>
<p dir="auto">Thank you for the help so far though. I am glad that at least the appending to file is working now</p>
]]></description><link>https://www.triggercmd.com/forum/post/4648</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4648</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Sat, 02 Oct 2021 17:43:04 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Sat, 02 Oct 2021 16:37:32 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a>, you wrote, "I even tried bash scripts and still nothing."  Do you mean you had the TRIGGERcmd agent run a bash script, and the bash script should have ran the python script, and it didn't?  I'm glad you tried that because I was going to suggest it.</p>
<p dir="auto">My suggestion at this point is to repeat that experiment, but keep the bash and python script super simple, and output to a file in /tmp from both so you can see if either one ran.  So you could make this your bash script:</p>
<pre><code>#!/bin/bash
echo "Hello from bash" &gt;&gt; /tmp/bash.log
/usr/bin/env python3 /root/test.py
</code></pre>
<p dir="auto">You could use the <a href="http://test.py" rel="nofollow ugc">test.py</a> example above.  It's simple and writes a log file.</p>
<p dir="auto">Don't forget to make the bash script executable with chmod +x <a href="http://test.sh" rel="nofollow ugc">test.sh</a></p>
<p dir="auto">If we can get a super simple python script to run, that would narrow down the problem.</p>
]]></description><link>https://www.triggercmd.com/forum/post/4647</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4647</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Sat, 02 Oct 2021 16:37:32 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Sat, 02 Oct 2021 05:29:29 GMT]]></title><description><![CDATA[<p dir="auto">Thank you Russ. I can't either command to work (both the python3 or python command). I saw these commans from your posts using that command from the LED strips and I tried it based on that awhile ago. I tried it again, just to be sure. The python script runs when I test it in the console and I know the command is being triggered, but still nothing happens on the PI. I did all the commands on background as well.</p>
<p dir="auto">The script I had running is simply to perform a button click (actually just to pause a video). I even tried a script that outputs appends to a file but still nothing. I even tried EXPORT.DISPLAY=0.0 to no avail.</p>
<p dir="auto">I assumed the issue was down to the agent being in root and the applications being under the user (based on previous posts). I previously had an issue of launching applications but I found the following command did the trick</p>
<pre><code>"command":"echo user | sudo -S su user -c '&lt;app-location&gt;'"
</code></pre>
<p dir="auto">For some reason though, this doesn't work for python scripts. So &lt;'python <a href="http://script.py" rel="nofollow ugc">script.py</a>'&gt; or even &lt;'python' <a href="http://script.py" rel="nofollow ugc">script.py</a>&gt; or with the python location obtained from "which python". It is the same with python3. I even tried bash scripts and still nothing.</p>
]]></description><link>https://www.triggercmd.com/forum/post/4646</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4646</guid><dc:creator><![CDATA[daproduct]]></dc:creator><pubDate>Sat, 02 Oct 2021 05:29:29 GMT</pubDate></item><item><title><![CDATA[Reply to Running a python script on a raspberry pi on Sat, 02 Oct 2021 01:40:48 GMT]]></title><description><![CDATA[<p dir="auto"><a class="mention plugin-mentions-user plugin-mentions-a" href="https://www.triggercmd.com/forum/uid/5521">@daproduct</a>, this worked for me on my Raspberry Pi:</p>
<pre><code>{"trigger":"python test","command":"python3 /root/test.py","ground":"background","voice":""},
</code></pre>
<p dir="auto">I also tried it with python 2.7 with this commands.json entry:</p>
<pre><code>{"trigger":"python test","command":"python /root/test.py","ground":"background","voice":""},
</code></pre>
<p dir="auto">This is my test python script:</p>
<pre><code>f = open("/tmp/test.txt", "a")
f.write("Now the file has more content!")
f.close()
</code></pre>
<p dir="auto">Maybe you're setting the ground to foreground?  Usually on a Raspberry Pi it needs to be background because it's running in the background service.</p>
]]></description><link>https://www.triggercmd.com/forum/post/4644</link><guid isPermaLink="true">https://www.triggercmd.com/forum/post/4644</guid><dc:creator><![CDATA[Russ]]></dc:creator><pubDate>Sat, 02 Oct 2021 01:40:48 GMT</pubDate></item></channel></rss>