google / physical-web

The Physical Web: walk up and use anything
http://physical-web.org
Apache License 2.0
5.99k stars 665 forks source link

short url pointing to branch.io deep link url not working #723

Closed joreilly closed 8 years ago

joreilly commented 8 years ago

I'm getting expected notification on iOS and Android if I configure beacon with something like https://google.com but doesn't work when I use https://goo.gl/c6Bf32 (fwiw this redirects to branch.io deep link url). I can open that link in browser (on desktop and mobile) and redirects correctly.

joreilly commented 8 years ago

I tried a different url shortening service (https://tiny.cc/w3txcy) ....that works on iOS but not on Android.

scottjenson commented 8 years ago

The fact it shows up on iOS (which doesn't do much checking) and it doesn't show up on Android means that your URL is getting filtered. We're working on getting a utility that will let you know why. The check list we follow is:

99% of the time, if a URL is rejected, it is due to the first 2 items on this list.

joreilly commented 8 years ago

yes, final URL is definitely HTTPS....had ran in to that issue when I started looking at this. Also, as mentioned, the goo.gl shortened version doesn't show up on either iOS or Android for some reason.

scottjenson commented 8 years ago

It appears your beacon URL is nothing more than a prompt to install an app, is that true? If so, all you're going to do is frustrate the user.

joreilly commented 8 years ago

@scottjenson it's a branch.io deep link url that will bring you to app/play store if you don't have app installed....otherwise it will open up app and go to particular screen.

scottjenson commented 8 years ago

Understood. We're perfectly happy to have you use DeepLink URLs but if it fails, our recommendation is that it goes to a web page that offers some type of information or value and not just an install banner. I appreciate this is more work and it may not even make sense for what your app does but at least offering SOMETHING is more likely to put the user in a good mood and be encouraged to install your app.

OK, editorial over. I just put your URL through a redirect tester and got this trace back: Results:

https://tiny.cc/w3txcy

HTTP/1.1 303 See Other Server: nginx Date: Thu, 14 Jul 2016 21:16:10 GMT Content-Type: text/html Transfer-Encoding: chunked Connection: keep-alive X-Powered-By: PHP/5.3.28 Set-Cookie: main_session=a%3A4%3A%7Bs%3A10%3A%22session_id%22%3Bs%3A32%3A%22ddde6f5a274404d263e7106dcfaf026c%22%3Bs%3A10%3A%22ip_address%22%3Bs%3A13%3A%22207.192.73.86%22%3Bs%3A10%3A%22user_agent%22%3Bb%3A0%3Bs%3A13%3A%22last_activity%22%3Bi%3A1468530970%3B%7Db092ec6e1e43bb36f539a4cdf033c054; expires=Fri, 15-Jul-2016 21:16:10 GMT; path=/; domain=.tiny.cc X-Robots-Tag: nofollow, noindex Location: https://bnc.lt/a/key_test_minWiDWlzWfRZSghVAlFQjjkvvmB8JId?artworkUUID=OakIslandDuneslores

It appears your destination has a robots.txt that is setting nofollow, noindex. As we use the Google crawler we can't follow links that don't ask not to be followed.

joreilly commented 8 years ago

Thanks @scottjenson ....will investigate why that's happening.

jeffprestes commented 8 years ago

Hey @scottjenson,

where do I find the redirect tester you've mentioned?

Thanks,

-Jeff

On Sat, Jul 16, 2016 at 9:12 AM, joreilly notifications@github.com wrote:

Thanks @scottjenson https://github.com/scottjenson ....will investigate why that's happening.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/google/physical-web/issues/723#issuecomment-233127559, or mute the thread https://github.com/notifications/unsubscribe-auth/AAgjWcNiWLKiw54Y6yKVki9RC8iVa08mks5qWMq7gaJpZM4JL3m_ .

scottjenson commented 8 years ago

There are many. I used http://redirectcheck.com/ but I'm looking for a better one. If anyone can recommend one, please shout out.

joreilly commented 8 years ago

@scottjenson I'm still not clear on why original goog.gl link I mentioned above (https://goo.gl/c6Bf32) didn't work. I ran that through http://redirectcheck.com/ and don't see "nofollow" being specfiied.

scottjenson commented 8 years ago

That doesn't appear to be related to your original question (which was about google.com working but not branch.io) Is there a new issue regarding goo.gl links? Keep in mind that if you are having an issue it is almost certainly with the final URL not the shortener. If you are using goo.gl or tiny.cc to a branch.io link, they both should have a problem. Please correct me if I'm wrong.

In general, any fancy/schmancy redirection (that's a technical term ;-) can confuse anyone that's following redirection. Another thing to test is use tiny.cc to point to ANY static page on https://branch.io/... link. If that work, then it's likely your redirection is causing problems.

We tend to encourage people to point to static pages for just this reason.

beaufortfrancois commented 8 years ago

@scottjenson We may want to add in https://google.github.io/physical-web/faq the fact that we use robots.txt-compliant Google crawler.

joreilly commented 8 years ago

@scottjenson my original question was " works.....if I configure beacon with something like https://google.com but doesn't work when I use https://goo.gl/c6Bf32". So using "google.com" directly works as expected but using that goog.gl one doesn't. When that url had failed I had tried the tiny.cc one then. From your analysis that one (tiny.cc) had the nofollow redirect issue you mentioned but when I put my original goog.gl short url in to that redirect link, it looks ok.

scottjenson commented 8 years ago

OK, sorry for the confusion, I clearly misunderstood. What I meant was:

  1. Set goo.gl to point to a static branch.io page
  2. See if that works (it should)
  3. Set goo.gl to point to your redirecting branch.io page
  4. If that fails, it's likely how you're redirecting the page (which is hard to get right)
ferencbrachmann commented 8 years ago

We have a simular issue. The redirector URL gets filtered out (works on Chrome for iOS and does not work in Nearby). we get the following from redirect check. Do you guys have any ideas on why this gets filtered out?

beeem.co/em000004

HTTP/1.1 301 Moved Permanently Date: Thu, 21 Jul 2016 08:04:15 GMT Content-Type: text/html; charset=iso-8859-1 Transfer-Encoding: chunked Connection: keep-alive Set-Cookie: __cfduid=d869d30222a03c0e5eedf532cf84ae4e51469088255; expires=Fri, 21-Jul-17 08:04:15 GMT; path=/; domain=.beeem.co; HttpOnly X-Frame-Options: SAMEORIGIN Location: https://beeem.co/em000004 Server: cloudflare-nginx CF-RAY: 2c5d241b759421bc-EWR

https://beeem.co/em000004

HTTP/1.1 302 Found Date: Thu, 21 Jul 2016 08:04:16 GMT Content-Type: text/html; charset=iso-8859-1 Transfer-Encoding: chunked Connection: keep-alive Set-Cookie: __cfduid=d45df2dd5d6e16290dfe69c9ca4f0cf991469088255; expires=Fri, 21-Jul-17 08:04:15 GMT; path=/; domain=.beeem.co; HttpOnly X-Frame-Options: SAMEORIGIN Location: https://beeem.co/p/GB/Bushey/WatfordBathroomandKitchens/watfordbath Server: cloudflare-nginx CF-RAY: 2c5d241fe5d4183a-EWR

https://beeem.co/p/GB/Bushey/WatfordBathroomandKitchens/watfordbath

HTTP/1.1 200 OK Date: Thu, 21 Jul 2016 08:04:16 GMT Content-Type: text/html; charset=UTF-8 Transfer-Encoding: chunked Connection: keep-alive Set-Cookie: __cfduid=d7f6387d140e28747334bccf7b4ae96b91469088256; expires=Fri, 21-Jul-17 08:04:16 GMT; path=/; domain=.beeem.co; HttpOnly X-Frame-Options: SAMEORIGIN X-Powered-By: PHP/5.5.29 Vary: Accept-Encoding X-Mod-Pagespeed: 1.9.32.3-4523 Pragma: no-cache Cache-Control: max-age=0, no-cache Server: cloudflare-nginx CF-RAY: 2c5d242265c521bc-EWR

ferencbrachmann commented 8 years ago

Furthermore, we can report that the URL (https://beeem.co/p/GB/Bushey/WatfordBathroomandKitchens/watfordbath) gets resolved by Chrome (see attached screenshot) and not on Nearby. 2016-07-21 08 27 55

2016-07-21 08 28 24

scottjenson commented 8 years ago

@mmocny could you have a look at this?

x2c commented 8 years ago

@scottjenson I can confirm I'm experiencing the same problems regarding redirects. I have tailed my server logs and it looks like the Google Proxy is not even attempting to hit the redirector URL but it will happily resolve the end URL directly

mmocny commented 8 years ago

@joreilly It looks like https://goo.gl/c6Bf32 redirects to a page which does not have a TITLE which is required by Nearby. (Nearby actually currently also requires a description, but this is a bug and is being fixed as we speak).

@ferencbrachmann It looks like beeem.co/em000004 does have both title and description, but from your screenshot above, it looks like descripton may have not been there at the time of your report? If you added one recently, can you confirm that Nearby works now? As I said, that was a bug and is being fixed.

Please let me know if that resolves the issue, cheers!

mmocny commented 8 years ago

@x2c I don't think redirectors had anything to do with either of the above cases. If you think there is an issue, can you file a new bug and provide a URL for me to check?

ferencbrachmann commented 8 years ago

@mmocny We just actually published a workaround (meta description tag) a few hours ago. And it works now!

chetstriker commented 7 years ago

I seem to be having a similar issue. I'm also using branch.io for deep linking. the URL is https://p9o0.app.link/jay if I open it directly on my phone with the app installed then it opens the app at URI viewboost:// like it should. If i open the link and it's not installed then it also works great and directs me to the install page. My problem is that when I add https://p9o0.app.link/jay to my beacon's eddystone url, it just takes me directly to http://bellemachine.com/viewboost to install the app whether the app is installed or not. So I no that the link by itself works fine, only when trying to add it as the eddystone url does it fail. I assume it's trying to reverse lookup the final destination directly from the beacon and broadcasts the URL of the final destination because the beacon doesn't have the app installed and so just gives the end point to the phone clicking on the link instead of the entered address (https://p9o0.app.link/jay) directly. Is there some sort of workaround for this? or are dynamic deep linking addresses from sites like branch.io not possible to use with beacons?