Closed (fixed)
Project:
Instagram Without API (IWA)
Version:
3.0.x-dev
Component:
User interface
Priority:
Normal
Category:
Bug report
Assigned:
Reporter:
Created:
26 Aug 2019 at 06:59 UTC
Updated:
5 May 2026 at 16:15 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
ckuert commentedHi there, I just stumbled upon the same issue - is there any workaround in the meantime?
Comment #3
killian jeusselin commentedHello, same issue here, clearing all caches doesn't work anymore. I tried on a fresh install, with a different instagram account, no feed either. I haven't found any workaround for now.
Comment #4
chiefme commentedConfirmation. The same issue.
Comment #5
aporieSame issue here.
For me, it's simply because the response returns to the redirect page (and not to the user page https://www.instagram.com/username/ --> https://www.instagram.com/accounts/login/) so there is nothing to display.
As it's probably due to a restriction from Instagram when the rate limit is exceeded scrapping their content I would recommend turning to an API oriented solution.
If you log yourself on Instagram on the machine using this module it should probably work back for a time. Using a proxy will also work.
But none of these solutions are long terms solutions.
Comment #6
jurgenhaasThe API limit should not be an issue if caching is enabled, because then the API is only called if the cache for cleared and you can control that with settings for the block.
However, we saw a related error end of last week, where the requests replied with a http code 500 which then brought down our whole Drupal site. The attached patch is preventing that from happening.
Comment #7
jurgenhaasRerolled the patch so that it also work even though the module is not compliant with coding standards, e.g. white space in the original code.
Comment #8
aporieI agree with your caching analysis. The issue is when your IP got blacklisted from instagram (because I think that's what happening here), then there is no way back (at least I don't know for how long they blacklist you)...
Also if you have a VPS it makes it easier to be blacklisted.
Comment #9
jurgenhaasRe-rolled the patch again because the return type needs to be array and not bool, see also #3105915: InstagramWithoutApi::build() needs to return array
Comment #10
malcomio commentedOne option might be to add some JavaScript that would fetch the data client-side in this scenario.
Comment #11
gaijinu commented#9 applied fine, but nothing shows up in the block :-(
Comment #12
malcomio commentedI'd suggest the following addition to the code:
I observed this on a site hosted on GoDaddy, so the IP address is probably on a blacklist.
Because it's being done client-side, it's unlikely that the browser would be on the blacklist.
If I get time, I'll work on a patch for this, but if anyone else can work on it, that would be great.
Comment #13
fernly commentedSame issue here. Local environment works fine. Production environment suddenly stopped displaying the IG feed. I can think of nothing else then IG blocking scrapers after a while.
The provided patches are not related to this topic, but still thank you. You might want to open another issue for the exception catching.
Comment #14
malcomio commentedHere's a patch for the Drupal 7 version that adds the client-side behaviour suggested in #12
Comment #15
ipwa commentedThis issue is resolved in the 3.x rewrite as part of #3250550: Placed Block does not render any HTML
The original crash was caused by the strpos/string-slicing approach used to extract window._sharedData from Instagram's HTML. When Instagram returned a redirect or login page instead of profile data, the parsing produced undefined or garbage output and the block broke entirely.
The 3.x branch addresses this in several ways:
The one scenario that remains outside the module's control is Instagram temporarily blocking a server IP due to rate limiting. In that case the block will display a "Could not retrieve Instagram posts" message until the restriction is lifted — a clean degradation rather than a fatal error.
If you are on the 3.x branch and still seeing this behaviour please open a new issue with details.