yashsingh1/xdaforums huggingface dataset:
[Xposed Framework Modules] JayShortway:
Known Issues

0.4.7.2

Support for Services is still experimental, and is completely disabled by default.

The following issues are fixed in the current version.

0.4.7.1

Support for Services is still experimental, and is completely disabled by default.

0.4.7

Support for Services is still experimental, and is completely disabled by default.

0.4.6 - Yet another minor one.

Support for Services is still experimental, and is completely disabled by default.

0.4.5 - Another minor update.

Support for Services is still experimental, and is completely disabled by default.

0.4.4 - Minor update.

Support for Services is still experimental, and is completely disabled by default.

0.4.3 - Moar bugfixes.

Support for Services is still experimental, and is completely disabled by default.

0.4.2 - Another bugfix release.

Support for Services is still experimental, but should work much better.

0.4.1 - Bugfix release.

Support for Services is still experimental.

0.4 - Service support is here!

Support for Services is still experimental.

Some apps do not show up in the 'Pick apps' screen.

AppContext sometimes force-closes.

0.3.2 - Another bugfix release.

None yet.

0.3.1 - Bugfix release.

None yet.

0.3 - Initial release.

Currently doesn't detect systemless Xposed via Magisk.

Pressing back when selecting apps to act on causes a crash. Instead, please tap either 'SAVE' (upper right) or 'X' (upper left).

A typo in the Tasker blurb.
[Xposed Framework Modules] Bladehawkz:
Oneplus one, running CM13 (sultan's) with my own custom kernel.

Seems to be working fine!
[Xposed Framework Modules] lover:
Oneplus3t with magisk and systemless xposed, The App does not detect xposed is installed and module has been activated!
[Xposed Framework Modules] JayShortway:
Thanks for the feedback, good to hear :)

Thank you for letting me know! I've put it on the Known Issues list, and I'm working on it!
[Xposed Framework Modules] Zoltair Wright:
FYI you can still use disk encryption password with accessibility services. when you enable the service it disables the 'require passcode on boot' but you can just re-enable from the security settings and it works

great module by the way! thanks
[Xposed Framework Modules] JayShortway:
That's interesting! Very unclear communication from Android though. I'll add your info to the first post, thanks for letting me know!

(And glad you like the module. :))
[Xposed Framework Modules] pjohn23:
Don't know if i posted this right but the message shown in "not running" state is the same as the running one in tasker. Shouldnt it say when "this app is not running" or something like that?

A great module and very reliable

Xperia Z running RR 5.7.4 with xposed v87 for MM
[Xposed Framework Modules] JayShortway:
Yes you're right! Thanks for the info and the screenshot. It's supposed to say "is in the foreground" or "is not in the foreground", but I see that "is" and "is not" have disappeared. Will be fixed in the next update.

Good to hear the module is reliable!
[Xposed Framework Modules] Stupifier:
Interesting Module. I always thought Tasker's app detection was a bit unreliable. Never thought it could be improved though. Thanks!

Wonder if Tasker Dev (Pent) will/can implement this as a "fix"
[Xposed Framework Modules] JayShortway:
Hi everyone,

The first update (0.3.1) is live! It is now available on Google Play, XDA Labs and the Xposed Module Repository.

It is just a quick bugfix update. It should fix the typo in the Tasker blurb, the crash when pressing 'back' in the 'Pick apps' screen and also enable Magisk systemless Xposed compatibility.

For those of you with Magisk: AppContext will probably complain it can't find the Xposed Framework, but if you enable the module and reboot, it should work (and AppContext stops complaining). I would be glad if someone could report back.

I will probably make a more elegant solution in a 0.4 update.

Please report any bugs in this thread, or by using the in-app Feedback button or sending an email to shortwaystudio@gmail.com. Thanks!

Enjoy!
[Xposed Framework Modules] JayShortway:
I'm glad you like it!

I don't think Tasker can implement this though, as AppContext hooks directly into Android-classes, which is only possible with Xposed.
[Xposed Framework Modules] richardkemp:
Very nice! You should post it in http://www.reddit.com/r/Tasker too.

If I set an app context using your plugin, then navigate to the app and toggle the screen off and on, the profile deactivates and activates again. Is this deliberate? I'm actually not sure what the in-built app context's behaviour is. I found it confusing since in that case I haven't switched app, per se.
[Xposed Framework Modules] JayShortway:
Good point. It is sort-of intended behavior, as AppContext simply checks whether the app's (or Activity's, actually) 'onStop' method is called. This method gets called when you turn the screen off. I might change this behavior in the future, or make it configurable. Until then, you could use the following workaround:

Profile: Event --> Plugin --> AppContext --> Start --> pick the apps you want to act on

Variables --> Variable Set

Name: %appsRunning

To: 1

Either: Clone the previous Profile, then go into Configuration --> Menu (3-dots) --> Configure context --> Stop

Or: Profile: Event --> Plugin --> AppContext --> Stop --> pick the same apps

Task --> Wait

MS: 500 (You can play with this number: smaller for a quicker response, bigger for more reliability detecting screen state.)

Task --> If

Condition: %SCREEN equals on

Variables --> Variable Set

Name: %appsRunning

To: 0

Task --> End If

Profile: State --> Variables --> Variable Value --> %appsRunning equals 1

Perform your Actions here.

I hope this works for you (and others)!

And thanks a lot for the heads-up on the subReddit, that's actually a very good suggestion!
[Xposed Framework Modules] palmuse:
Nice! Checking this out. Thx!
[Xposed Framework Modules] Bladehawkz:
Suggestion: currently on lollipop+(I think), location toggle is unable to be used, even with root. The workaround is to use another plugin app with root/adb privs, but I was wondering whether this could be changed using xposed (changing the location hook?), as it should be visible to tasker that's been granted root).
[Xposed Framework Modules] JayShortway:
Do you mean something like a Tasker-compatible Xposed module that toggles location modes?
[Xposed Framework Modules] Bladehawkz:
More like editing tasker so that the location toggles work when it's granted root, instead of actually requiring you to download another app/plugin and granting that root.

Any location/GPS usage gets the message "For Android 2.3+ Google have made changes such that it is no longer possible for a normal app to change GPS without user-interaction. If you wish to continue.. blah blah blah.. consider rooting and installing the secure settings plugin".

Considering that Tasker is able to have root privileges granted, clearly it should be possible for it to toggle location.
[Xposed Framework Modules] JayShortway:
Got it! It's a good point you make. However it would require either an Xposed module, or an actual adjustment/update to the Tasker app (by Pent). In case of the Xposed module, it would be interesting to see if and how this can be done.
[Xposed Framework Modules] palmuse:
Would it be possible to add a configuration to capture the native launch event (ie. prevent launch) after detecting the on Start apps? I want to implement a custom launch event (floating), but currently the app launches then I relaunch it as floating. Preventing the original launch would smooth out the process.

Thanks for considering.

Edit: Perhaps a better way to put this is to add a prelaunch event. App icon was clicked or launch called but the main activity has not displayed yet (and won't).
[Xposed Framework Modules] aadi50:
It works well. Nice module. :good:

It does exactly does what it says. But i have observed that if app is resumed from recents or anywhere else it doesnt detects ... as it now detects onStart and onStop.

Can u please add few more context for ... when app comes to focus and when app loses focus?? It will become more handy.
[Xposed Framework Modules] evilbluechickens:
is there any way this can be made compatible with xposed v86? im still running suhide with topjohnwu' s v86.2 of xposed so i can bypass safetynet checks but this would be super helpful
[Xposed Framework Modules] JayShortway:
I think I see what you mean. Am I correct in saying you want some apps to be always launched floating? And you'd like to accomplish this by creating an AppContext Event Profile that triggers when the app is (attempted to be) launched, and then prevents that? And then you'd have your own Task that launches that app floating?

It's an interesting idea, and I'll see if I can come up with something. I can't promise anything though, as I am not certain it is possible. Maybe there's something in the ActivityManager that I can hook into.
[Xposed Framework Modules] JayShortway:
Thanks for the feedback. It should, however, detect if an app is resumed from Recents if you're using Event Profiles. If it doesn't, than that would be a bug.

By 'losing focus', do you mean something like sliding down the notifications panel?
[Xposed Framework Modules] JayShortway:
I think that shouldn't be a problem. To be honest, I wasn't aware of a reason not to be on the latest Xposed Framework, but this is a pretty good one :)
[Xposed Framework Modules] palmuse:
You got it exactly. :D I appreciate your looking into it.

If there isn't anything you can hook into, perhaps adding the option to block the launch intent on start while still capturing the event might work. (Oh! capturing the Launch Intent or Main Activity in a variable would be a huge plus too! $$)

Another use of this is, as an example, is redirecting.

I have a profile that launches 2 apps in specified order whenever my phone is idle on the home screen while charging with the screen on.

I first launch an app called Current Wallpaper (displays the wallpaper, live or not, in fullscreen). I then launch an app called Huge Clock with a transparent background. I end up with a nice clean desktop clock whenever my phone is idle. :cool: I have this up all night as my bedside clock.

Right now I have a profile set so that whenever I launch Current Wallpaper, Huge Clock launches automatically right after. Works well enough, but I cannot use the Current Wallpaper app in any other context.

If I could capture, but prevent, launch of Huge Clock, I could set up a App Context profile for Huge Clock itself to run a task launching the apps normally in order. Thus I get the end result by monitoring the target app while freeing up Current Wallpaper.

A bit of a Rube Goldberg scenario, but I like the simplicity of this combination. Have not found another app that accomplishes this minimalist look.

Anywho... I appreciate your investigation. Let me know if I can test anything for you.

BTW: combining the power of Xposed and Tasker is PURE GENIUS! My mind is swimming at the possibilities. If you have the time, I think you could make some money with a fleet of integration apps. :)
[Xposed Framework Modules] aadi50:
Yeah sliding notification is surely another example of lost focus. But i actually meant... If i press home button to make the app run in Background... Then i think it is more like 'lostFocus'... Not stopped.

And I created a task to flash the %acpackage variable on all apps. And in result the alert appears only when app is started first time. And if i resume the same app the toast doesn't flash. So i think it doesnt detect on resuming apps.
[Xposed Framework Modules] JayShortway:
Interesting setup you have :) I'll look into what I can do, and if I need anything tested I'll let you know. Thanks for that!

And thanks for the compliment haha. There are indeed lots of possibilities.
[Xposed Framework Modules] JayShortway:
If you press the Home-button, the app's Activity is stopped, so it should fire the Stop Event.

Are you using Event Profiles for your %acpackage flash Task? If so, it should flash %acpackage each time you open the app, as long as you have switched to another app in between. If it doesn't, I'm afraid it's a bug :(
[Xposed Framework Modules] JayShortway:
AppContext 0.3.2

Hi everyone,

I have just released AppContext 0.3.2! It is now available on Google Play, XDA Labs and the Xposed Module Repository.

It is another bugfix update. It downgrades the minimum required version of the Xposed Framework to 86 (as requested by [MENTION=2898501]evilbluechickens[/MENTION]), fixes the search bar being unresponsive sometimes, and handles the Xposed Framework installed (systemlessly) via Magisk more elegantly. It also fixes some other minor bugs.

I have made some progress on adding support for Services, which will most probably be the first new feature to be implemented. Not yet in this release though.

Please report any bugs in this thread, or by using the in-app Feedback button or sending an email to shortwaystudio@gmail.com. Thanks!

Enjoy!
[Xposed Framework Modules] evilbluechickens:
awesome, testing it out now!
[Xposed Framework Modules] palmuse:
I may have had issues with the 0.3.2 version. I experienced a boot loop after install. Anyone else have this experience? It might have been another system issue on my device.

Edit: boot loop was NOT related to this app. All loaded up and working fine.
[Xposed Framework Modules] JayShortway:
I am glad to hear that! Thanks for reporting back!
[Xposed Framework Modules] palmuse:
Is this still under development?
[Xposed Framework Modules] JayShortway:
Yes it definitely is! I am currently working on support for Services, but have hit some roadblocks. Also, my main phone has been out for repair (bootloop) for the last couple of weeks, so I haven't been able to be as on top of things as I would like. Nevertheless, you can expect an update soon!
[Xposed Framework Modules] JayShortway:
AppContext 0.4

Hi everyone,

Service support is here! (It is still experimental though.) I have just released AppContext 0.4! It is now available on Google Play, XDA Labs and the Xposed Module Repository.

You can enable Service support under 'Experimental features'. It is currently only for Event Contexts. When you create a Context in Tasker with any app's Services, you'll have to reboot for it to take effect. You can check (and change) which apps have their Services hooked under 'Hooked Services'. Please let me know how it works for you.

Other changes in this release include a complete rewrite of the 'Pick apps' screen, making the Search bar a Search button, clearing up the Tasker blurbs and properly recognizing the website-version of Tasker. The RECEIVE_BOOT_COMPLETED permission is needed to update the list of hooked Services on pre-Marshmallow devices after a reboot.

Please report any bugs in this thread, or by using the in-app Feedback button or sending an email to shortwaystudio@gmail.com. Thanks!

Enjoy!
[Xposed Framework Modules] JayShortway:
Should work on any version of Tasker. Are you having difficulties?

(Not asked before I believe :p)
[Xposed Framework Modules] Crsmsg:
App is working good on Nougat and unofficial xposed but sometimes i have some crashes
[Xposed Framework Modules] JayShortway:
Thanks for your feedback! By crashes, do you mean AppContext force closing? I expect to have that fixed in the next update.

I am also investigating reports of some apps not showing up in the 'Pick apps' screen.
[Xposed Framework Modules] Crsmsg:
I've got a popup window that "AppContext have stopped"
[Xposed Framework Modules] JayShortway:
Thanks for getting back to me. That is probably the type of crash I am currently investigating. Hopefully fixed in the next update.
[Xposed Framework Modules] Infy_AsiX:
I can't seem to get Root Browser to show up in the app list. I'm using and old last version before the dev sold his apps to a company that's changed everything and included full screen ads in one apparently.
[Xposed Framework Modules] JayShortway:
Thanks for your report. I have sent you a test version via DM. Could you check if Root Browser shows up in that version? Thanks in advance.
[Xposed Framework Modules] Infy_AsiX:
That test version works for me :good:.

On a different note. So this works by a start and end event context? So you need to create both to for example revert a change like how an exit task would work? Whereas Tasker normally has it's app detection as more like a 'state' of active or inactive?

---------- Post added at 03:31 AM ---------- Previous post was at 02:44 AM ----------

Getting 'AppContext have stopped' when event occurs sometimes here too on that test version
[Xposed Framework Modules] JayShortway:
Great! I now have multiple reports of that fix working, so I'll include it in the next update.

Well, you have both options actually.

You could indeed create a 'start' and/or 'stop' Event Context and perform your actions. You could also set a variable to 1, for example, in the 'start' Event, and set it to 0, in the 'stop' Event, and then create a State Context for that variable being equal to 1.

Alternatively you can create a State Context directly using AppContext. In Tasker, just go to State --> Plugin --> AppContext. However, due to how Tasker works, if you select multiple apps in a State Context and switch from one app to the other, AppContext can't update any of its variables. (This is because the State does not get 're-triggered'.)

I hope this clears things up. If you have any questions, please let me know.

Yes, the version I sent you doesn't include a fix for that. However, if it happens, could you report it to Google Play? I should get more info (line numbers) from your test version, although I don't know if it shows up in my Developer Console as your test version is not on Google Play.
[Xposed Framework Modules] Infy_AsiX:
Ah I see. Somehow I missed that 'state' plugin existed. In my case the multiple state apps don't require retriggering upon swapping. I can just directly use the state context then :). I suppose that's how Tasker originally works but I never even knew.

If I can get the bug consistently I'll try to report or logcat it. I also did have a little issue trying to change a cloned event context from start to stop. After saving back to Tasker it was stuck to start, ended up trying multiple times on the clone and original with no luck.
[Xposed Framework Modules] JayShortway:
That would be great, thanks!

Hmm, that is odd. I'll see if I can reproduce the issue and investigate.
[Xposed Framework Modules] JayShortway:
Unfortunately, I am unable to replicate this behavior (on Android 4.4.2 and 6.0.1). Just to be clear, in the cloned Event Context, did you press the menu (3 dots) button and then 'Configure context'?
[Xposed Framework Modules] JayShortway:
AppContext 0.4.1

Hi everyone,

I have just released AppContext 0.4.1! It is now available on Google Play, XDA Labs and the Xposed Module Repository.

This is purely a bugfix release. Some users reported that not all apps were shown in the 'Pick apps' screen. This should be solved now. Also, some Xposed-related error are solved. (The list of hooked Services is now read via XSharedPreferences again, instead of via a ContentProvider.) Lastly, I have made an attempt at fixing the random crashes. However, if they still occur, please keep reporting them to Google Play. I should get more info (line numbers) in crash reports from this version on.

Please report any bugs in this thread, or by using the in-app Feedback button or sending an email to shortwaystudio@gmail.com. Thanks!

Enjoy!
[Xposed Framework Modules] JayShortway:
Disappearing Play Store reviews

Hi everyone,

I'd like to thank the people that have written (positive) reviews in the Play Store. Unfortunately, a lot of them disappeared because, for example, the reviewer went back to a previous version of AppContext (as written in one of the reviews). This results in Google removing the review, because it thinks it is fake. (The reviewer only had the latest version of AppContext installed for a few minutes.)

So, to anyone reviewing AppContext: please keep the latest version of AppContext installed. It should get more stable with every version :).

If anyone who wrote a review that has now disappeared reads this: it would be awesome if you could write your review again!

Thanks again to all (past and future) reviewers! They are very helpful!
[Xposed Framework Modules] Crsmsg:
v0. 4.1 app keeps stopping/crashing on the unofficial xposed Nougat.I think it doesn't hook correctly on it

I'll wait for the official xposed then i test your app again
[Xposed Framework Modules] JayShortway:
Thanks for your report. I have tested the upcoming version (0.4.2) on the unofficial Xposed for Nougat installed through Magisk, and found no problems so far. So you could try the new version when it comes out. I plan to release 0.4.2 this week.
[Xposed Framework Modules] JayShortway:
AppContext 0.4.2

Hi everyone,

I have just released AppContext 0.4.2! It is now available on Google Play, XDA Labs and the Xposed Module Repository.

In this version, I completely changed the way Services are hooked. This removes the need to select which Services should be hooked, and thus also removes the need to reboot. Moreover, it should work much better! (It is, however, still an experimental feature.) I have also made another attempt at fixing the random crashes. If they still occur, please keep reporting them. (Thanks!) I did some code restructuring and fixed some other minor bugs. Lastly, this is the first version I have tested on the unofficial Xposed for Nougat. I found no apparent problems, but please be aware that it is an unofficial Xposed.

Please report any bugs in this thread, or by using the in-app Feedback button or sending an email to shortwaystudio@gmail.com. Thanks!

Enjoy!
[Xposed Framework Modules] ninestarkoko:
Hello, very interesting app in the xposed panorama! Great idea imho.

I'm using Automagic because I find it easier to use than tasker. It has plugin support too so I'll try.

As far as I understand to use the app I need to use the Plugin event in my automation app.

I still Don T understand one thing though: does the app always run in background like a service that receives calls from the hooked code or is it called when needed, communicates to automation apl, and then quits?

One other question: can you implement App Activity started recognition? To detect when specific activities are called
[Xposed Framework Modules] Crsmsg:
v0.4.2 no more crashing but i'm having random crashes on other apps facebook, messenger,ampere,chrome and others.

Turned off module again
[Xposed Framework Modules] JayShortway:
Thanks! Yes, in your automation app you'll need to use the Plugin event, or if it supports condition/state contexts, you can use those too.

AppContext does not run in the background like a Service. It is a BroadcastReceiver, which is indeed called when needed and communicates to the automation API. After that it is either killed or cached, that's up to the Android system.

Regarding your suggestion: I'm actually investigating if I can implement that.
[Xposed Framework Modules] JayShortway:
Thanks for your report. Are you on Nougat? Could you logcat such a crash? If they happen too sporadically to 'predict', you could try opening a logcat app straight after a crash does occur, and save the logcat. Chances are you can still 'catch' the crash that way. Thanks in advance!
[Xposed Framework Modules] ninestarkoko:
Thanks for the explanation!

I use mostly triggers regarding app Activities so it would be very useful if you could add this kind of discrimination.

I give you some info about Automagic behaviour on this. Automagic uses two types of detection you can choose for activity recognition: "classic" which uses the accessibility service and "usage statistics" which is more experimental and works on Lollipop+ (the description says that).
[Xposed Framework Modules] JayShortway:
Thanks for the info, I'll be sure to check it out!