Tusky
Tusky copied to clipboard
Add Mastodon Redirect support
Mastodon Redirect is my app that handles redirecting Mastodon links to supported apps, so the apps don't have to maintain their own list of supported instances.
This PR adds auto-detect support for Mastodon Redirect, so Tusky can be chosen for opening Mastodon links.
Addresses https://github.com/tuskyapp/Tusky/issues/3865
To test:
- Download Mastodon Redirect from https://github.com/zacharee/MastodonRedirect.
- Install Tusky from this PR's code.
- Open and log into Tusky.
- Find a random post and copy its link. Paste the link somewhere it'll be clickable, such as in Telegram's "Saved messages" channel.
- Remove Tusky from Recents.
- Open Mastodon Redirect and select Tusky in the "Discovered" section.
- Tap the pasted link. It should launch Tusky and then resolve to the post.
- Back out to the main feed in Tusky and go back to the link, without removing Tusky from Recents this time. The link should open Tusky and resolve to the post.
I fail to test that. My steps:
- use an Android Api 34 emulator
- Install Tusky from this branch
- Install Mastodon redirect 1.11.0
- make Android open links from a few domains with Mastodon redirect
- enable Tusky in Mastodon redirect
- click a link from one of the enabled domains in Chrome
- Chrome closes
Failed to deliver inset control state change to w=Window{bb5153c u0 com.android.chrome/com.google.android.apps.chrome.Main EXITING}
android.os.DeadObjectException
similar result on a real device and with Firefox
Try using the "Open Link" share target instead.
Mastodon Redirect has so many domains that it can break whatever API Chrome is using to read where to open links. I've been waiting on an update to instances.social's API for better active-status filtering.
Same result with "open link" :( Seems like Android is unable to cope with an app having so many supported domains
Try revoking any links you enabled for auto-handling. You might also need to try opening a link from something like Keep or Telegram. I want to reduce the number of handled domains in Mastodon Redirect, but I haven't been able to find a better source yet.
I've reduced the number of supported domains by about 1000 in Mastodon Redirect. It's still over 11k total, but it should be less prone to crashing.
I also added a new share target for opening links, which uses the same path Mastodon Redirect does.
Any news here? 🙈
@zacharee This PR needs to be rebased or have a merge commit from tuskyapp:develop. If you can not afford time for solving this, I can gladly take over. (no tusky maintainer, just want to help getting this done :) )
@lazalatin can you bring that forward?