Cards Validator cannot find metatags with Shopify’s HTTP headers


#1

Cards previously worked until about a week ago. Today I copied the HTML from a page on Shopify and hosted it on a different server, where Twitter’s Card Validator worked as expected. This leaves me thinking the problem is the HTTP headers being sent by Shopify are causing Twitter’s Card Validator to break and give up processing the web page?

CARD VALIDATOR OUTPUT:

Unable to render Card preview
INFO: Page fetched successfully
WARN: No metatags found

HEADERS SENT BY SHOPIFY:

HTTP/1.1 200 OK
Server: nginx
Date: Wed, 25 May 2016 20:09:48 GMT
Content-Type: text/html; charset=utf-8
Transfer-Encoding: chunked
Connection: close
Vary: Accept-Encoding
Vary: Accept-Encoding
Status: 200 OK
X-ShopId: 2200910
X-ShardId: 4
Content-Language: en
Content-Security-Policy-Report-Only: default-src ‘self’ *; connect-src ‘self’ *; font-src ‘self’ * data:; frame-src ‘self’ *; img-src ‘self’ * data:; media-src ‘self’ *; object-src ‘self’ *; script-src ‘self’ * ‘unsafe-inline’ ‘unsafe-eval’; style-src ‘self’ * ‘unsafe-inline’; frame-ancestors indosole.com; report-uri /csp-report/d7c4ff22-a437-4829-a011-6092b5237df8?source%5Baction%5D=index&source%5Bcontroller%5D=shop&source%5Bsection%5D=storefront;
X-XSS-Protection: 1; mode=block; report=/xss-report/d7c4ff22-a437-4829-a011-6092b5237df8?source%5Baction%5D=index&source%5Bcontroller%5D=shop&source%5Bsection%5D=storefront
ETag: cacheable:bffa592ecdeb7f3778a54bc937766aa9
X-Alternate-Cache-Key: cacheable:17185c5c137057af56e86924b381aeff
X-Cache: hit, server
Set-Cookie: _session_id=c7fb7b1d49a2688b88c096509122b658; path=/; HttpOnly
Set-Cookie: _orig_referrer=; path=/
Set-Cookie: _landing_page=%2F; path=/
Set-Cookie: cart_sig=; path=/; expires=Wed, 08 Jun 2016 20:09:48 -0000; HttpOnly
Set-Cookie: customer_sig=; path=/; expires=Sun, 25 May 2036 20:09:48 -0000; HttpOnly
X-Request-Id: d7c4ff22-a437-4829-a011-6092b5237df8
P3P: CP="NOI DSP COR NID ADMa OPTa OUR NOR"
X-Dc: chi2
X-Content-Type-Options: nosniff

EXAMPLE URLS:



#2

According to this post Have metatag and robots.txt - so why does fetching fail? it could be the x-content-type-options header.


#3

It looks like the problem is not HTTP Headers, but Shopify is sending 404s to Twitterbot for some reason.

curl -A “” http://obeyclothing.com/products/cliffside-short-sleeve-shirt --> Works
curl -A “Twitterbot/1.0” http://obeyclothing.com/products/cliffside-short-sleeve-shirt --> 404 Not Found

I’ve submitted a ticket with Shopify as it looks like the problem is on their end.