Giter Site home page Giter Site logo

Comments (18)

unresolvedsymbol avatar unresolvedsymbol commented on July 24, 2024

The command works perfectly fine from termux as it should

from termux-tasker.

agnostic-apollo avatar agnostic-apollo commented on July 24, 2024

Are you sure you have granted tasker com.termux.permission.RUN_COMMAND permission?

And does the action not throw any error? Make sure timeout value is greater than 0. And try with Execute in terminal session toggle disabled and flash %stdout and %stderr.

Edit: Actually, permission would have been granted, otherwise a warning would have been shown in the screenshot.

from termux-tasker.

unresolvedsymbol avatar unresolvedsymbol commented on July 24, 2024

Screenshot_20210331-171324_Permission_controller

from termux-tasker.

unresolvedsymbol avatar unresolvedsymbol commented on July 24, 2024

I will try your timeout suggestion but I'm pretty sure I tried tweaking that around

from termux-tasker.

unresolvedsymbol avatar unresolvedsymbol commented on July 24, 2024

Screenshot_20210331-171530_Tasker
No dice

from termux-tasker.

agnostic-apollo avatar agnostic-apollo commented on July 24, 2024

Disable the Execute in terminal session toggle, set timeout to 10s and flash %stdout, %stderr and %result with a Flash action. Does the action even run successfully, green or red dot?

If that doesn't tell you anything, then we can check the logcat.

from termux-tasker.

unresolvedsymbol avatar unresolvedsymbol commented on July 24, 2024

Yes the task stays green, I've tried both with and without "exec in terminal session" unfortunately I'm not too familiar with variables in tasker so I couldn't seem to get it to flash the stdout but here's an extract from logcat along with some device info: https://a.pomf.cat/ogfott.zip

from termux-tasker.

agnostic-apollo avatar agnostic-apollo commented on July 24, 2024

Just add a new action from Alert -> Flash and set value to

%stdout
%stderr
%result

And for getting more useful log entries of Termux:Tasker, set it to debug level from plugin configuration screen options (3 dots on top right), then run command.

https://github.com/termux/termux-tasker#debugging

from termux-tasker.

 avatar commented on July 24, 2024

It may not work under tasker if yeecli shebang is standard (like #!/usr/bin/env python or similar). All its parts should be fixed with utility termux-fix-shebang.

Reason why it works under Termux session is that termux-exec (https://wiki.termux.com/wiki/Termux-exec) is being used for interactive shell.

from termux-tasker.

agnostic-apollo avatar agnostic-apollo commented on July 24, 2024

Yeah, that might actually be it and that would show as bad interpreter errors in %stderr with a successful action.

It's also mentioned in the README.

https://github.com/termux/termux-tasker#termux-environment

Another reason why stderr should always be checked when running shell commands. There are template tasks available as well that test everything for you, specially if you are not skilled in tasker.

https://github.com/termux/termux-tasker#templates

from termux-tasker.

unresolvedsymbol avatar unresolvedsymbol commented on July 24, 2024

Screenshot_20210331-203122_Tasker
This is what happens unfortunately.
Yes I've added a script to ~/.termux/tasked with

#!/data/data/com.termux/files/usr/bin/env bash
yee --ip 192.168.1.178 toggle

from termux-tasker.

unresolvedsymbol avatar unresolvedsymbol commented on July 24, 2024

(Screenshot shows wrong binary but I switched it to the script with the same result)

from termux-tasker.

agnostic-apollo avatar agnostic-apollo commented on July 24, 2024

It wouldn't matter what your initial script shebang is since termux will handle it (unless interpreter doesn't exist at both paths, then plugin action will be stuck forever, will be fixed in next Termux version). However, the shebangs of all scripts like yee called inside your script matter. But apparently it's not showing an error, was the toggle disabled when you did the flash? Did logs show anything?

from termux-tasker.

unresolvedsymbol avatar unresolvedsymbol commented on July 24, 2024

Check the logcat zip attached earlier, lmk if it has anything useful

from termux-tasker.

agnostic-apollo avatar agnostic-apollo commented on July 24, 2024

It didn't cause you are supposed to set log level to debug and then run the action like I said. Without it Termux:Tasker won't log parameters and results. And run it with the Execute in terminal session toggle disabled like I already mentioned, otherwise %stdout and %stderr are never set/returned.

And how did you even grab that logcat?

from termux-tasker.

unresolvedsymbol avatar unresolvedsymbol commented on July 24, 2024

Screenshot_20210331-220349_Termux_Tasker
Screenshot_20210331-220405_Tasker
I've had these set if this is what you're referring to. Also MatLog (modernized catlog)

from termux-tasker.

agnostic-apollo avatar agnostic-apollo commented on July 24, 2024

I was referring to the first picture, it's fine. But did you create the zip after setting it to verbose or before? If before, then it should have had entries with termux-tasker tag by Termux:Tasker app and termux-task by Termux app (with toggle disabled). Try capturing again.

from termux-tasker.

agnostic-apollo avatar agnostic-apollo commented on July 24, 2024

Closing since currently inactive. Can be opened again if more info is provided.

from termux-tasker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.