Skip to content
This repository has been archived by the owner on May 3, 2021. It is now read-only.

Stopped working #103

Closed
luizping opened this issue Jan 13, 2021 · 113 comments
Closed

Stopped working #103

luizping opened this issue Jan 13, 2021 · 113 comments

Comments

@luizping
Copy link

I think IG changed the policy. Now to see a user page, you have to be logged in. So when you run the script, the GET returns the IG Login Page content.

@mahotilo
Copy link
Collaborator

My IP is now banned, so I can't do a clear check. But yes, something has changed for me too. I will check later if this new IG behaviour is permanent or only for banned IPs.

@benbracedigital
Copy link

benbracedigital commented Jan 13, 2021

I'm getting the same issue too after a couple of page views Instagram isn't returning any images and in the console I get

Instagram Feed: It looks like YOUR network has been temporary banned because of too many requests. See https://github.com/jsanahuja/jquery.instagramFeed/issues/25

@web-assistant
Copy link

I'm also seeing the temporary banned message

@mahotilo
Copy link
Collaborator

@benbracedigital
Were you able to see images today before ban? What cache_time had you had?

@benbracedigital
Copy link

Yes I was and I could see the images on a different server this morning but after a couple of refreshes, I get the error message. I've set the cache_time to 120.

@mahotilo
Copy link
Collaborator

mahotilo commented Jan 13, 2021

It seems like 120min is not enough now. The new default and recommended value is 6 hours (360)

@benbracedigital
Copy link

Sure, happy to increase to 6 hours but I would expect it to be cached for 2 hours previously and still work rather than error and not show images within minutes?

@mahotilo
Copy link
Collaborator

mahotilo commented Jan 13, 2021

What version of the script do you have? I can see cached images even in the ban.
And true, with an error in the console

@benbracedigital
Copy link

version 1.3.6

@mahotilo
Copy link
Collaborator

Caching is only available since 2.0.0

@benbracedigital
Copy link

Ah, thank you. I'll download the latest version and see what results I get.

@mahotilo
Copy link
Collaborator

mahotilo commented Jan 13, 2021

But only after the end of the ban.
I mean "will see" :)

@benbracedigital
Copy link

I can at least see cached images now. I'm going to deployed to a different (non banned) server to see if that all works.

@mahotilo
Copy link
Collaborator

mahotilo commented Jan 13, 2021

Your (browser) IP is banned, not the IP of the server of your page. Personally, I am currently banned on my PC, but I can flawlessly see the script results on my phone with mobile internet.

@benbracedigital
Copy link

Looks to be working. Thanks for your help

@mahotilo
Copy link
Collaborator

@luizping

I think IG changed the policy. Now to see a user page, you have to be logged in. So when you run the script, the GET returns the IG Login Page content.

I am finally able to check your issue after my last ban ended. The redirect to IG Login Page is only related to the ban. Now, I am able to open and preview any IG page with only offer to register at the bottom.

@mahotilo
Copy link
Collaborator

mahotilo commented Jan 18, 2021

Yeah, it looks like these are tough times. IG has banned me right after the first successful page update. And ban will last 2-3 days, I expect.
Really tough.

@Federico-Iglesias
Copy link

@mahotilo how are you? Is to possible to avoid this issue by using cache_time setting? Thanks!

@mahotilo
Copy link
Collaborator

Is to possible to avoid this issue by using cache_time setting? Thanks!

The cache_time is the only cure we have, It works. But it is very easy to catch a ban if you simultaneously use the script on different sites and make experiments :)
I am thinking of increasing the cache_time up to 24 h for myself to avoid future bans.

@pabrul
Copy link

pabrul commented Jan 18, 2021

I'm kind of on an "eternal ban", because sometimes the feed appears and sometimes not, the same happens with this error, sometimes it appears on the console and sometimes it doesn't, I really don't know what to do anymore :(

@pabrul
Copy link

pabrul commented Jan 18, 2021

image

@mahotilo
Copy link
Collaborator

@pabrul

...I really don't know what to do anymore :(

First of all, you should update your script to the latest version 2.0.1
This is how your console should look like in case of a ban.

image

@no-liver
Copy link

Having the same issue, updated to ver 2.0.1 and console reads:
jquery.instagramFeed.min.js:98 Instagram Feed: Your network has been temporary banned by Instagram because of too many requests. Consider increasing your 'cache_time'. See https://github.com/jsanahuja/jquery.instagramFeed/issues/25 and https://github.com/jsanahuja/jquery.instagramFeed/issues/101 4

Increased cache_time: 360 4 days ago and no change.

Any suggestions to proceed?

@mahotilo
Copy link
Collaborator

Any suggestions to proceed?

Wait until IG unbans you. Last time, 3 days were enough for me.

@mahotilo
Copy link
Collaborator

mahotilo commented Jan 20, 2021

Well, what I have found about the ban from IG.

  1. The script and the caching approach work fine. You can update script output on 1-2 pages without being banned.
  2. But, @jsanahuja... It seems to me, the demo page that has 4 calls of script in a raw with different username + 1 call with a tag might be the point where the visitors get banned.

@jsanahuja
Copy link
Owner

  1. But, @jsanahuja... It seems to me, the demo page that has 4 calls of script in a raw with different username + 1 call with a tag might be the point where the visitors get banned.

Maybe we should change it to use the same username on all the examples. The tag call doesn't matter because it never gets banned as far as I know

@mahotilo
Copy link
Collaborator

The tag call doesn't matter because it never gets banned as far as I know

I also think so.

Maybe we should change it to use the same username on all the examples.

Or maybe the function should be called only when the corresponding tab is opened? Barcelona should be kept:)

@jsanahuja
Copy link
Owner

jsanahuja commented Jan 21, 2021

Or maybe the function should be called only when the corresponding tab is opened?

Mmm, way better

Barcelona should be kept:)

Hahaha, for sure 😄

@ReneR97
Copy link

ReneR97 commented Jan 21, 2021

Just have a question for clarification, if i get banned on one page, will i be banned on all pages that use this script, or is the ban on a per page basis? or is it on a per instagram page basis?

@mahotilo
Copy link
Collaborator

mahotilo commented Jan 21, 2021

I believe, it is a ban on your IP. Any nonlogged-in requests from your IP are banned by IG during the ban period.

@web-burn
Copy link

web-burn commented Mar 4, 2021

@mahotilo I noticed this error only for some instagram accounts. Please try the next user name:
modern_presta

Update: The error occur when instagram account doesn't have bio.

@m0nclous
Copy link
Collaborator

m0nclous commented Mar 4, 2021

@jsanahuja i noticed this error now. The instagram feed doesn't displayed. Browser firefox. I use the latest version 3.0.0.
Screenshot_1

This happens when Google responds with an error, because in this case it does not send the header "Access-Control-Allow-Origin"
To understand the reason - you need to reproduce the problem and see the answer from Google manually.

I think this solution is still crude and more logging needs to be added.

image

image

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 4, 2021

@mahotilo I noticed this error only for some instagram accounts. Please try the next user name:
modern_presta

Update: The error occur when instagram account doesn't have bio.

I have checked, there is the same error here.
But, it has happened to me before too. It is related to the first VIDEO in the row.

@m0nclous
Copy link
Collaborator

m0nclous commented Mar 4, 2021

@mahotilo I noticed this error only for some instagram accounts. Please try the next user name:
modern_presta
Update: The error occur when instagram account doesn't have bio.

I have checked, there is the same error here.
But, it has happened to me before too. It is related to the first VIDEO in the row.

This happens when parse_caption() dont finds a caption and returns false in escape_string where the string is expected.
I will fix it.

image

image

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 4, 2021

We should definitely have created a separate new issue for this :)

@m0nclous
Copy link
Collaborator

m0nclous commented Mar 4, 2021

We should definitely have created a separate new issue for this :)

Can you do it please?

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 4, 2021

Please, let us continue to discuss this error here #120

@jsanahuja
Copy link
Owner

jsanahuja commented Mar 4, 2021

@jsanahuja i noticed this error now. The instagram feed doesn't displayed. Browser firefox. I use the latest version 3.0.0.
Screenshot_1

This happens when Google responds with an error, because in this case it does not send the header "Access-Control-Allow-Origin"
To understand the reason - you need to reproduce the problem and see the answer from Google manually.

I think this solution is still crude and more logging needs to be added.

image

image

@m0nclous this is because you are running the script without a web server. The solution is setting the 'Referer' header but web browsers won't allow us to do that with Javascript for security reasons

@thomashdk
Copy link

ALso gettings this. Using 3.0.0 whit the "fix" host

image

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 4, 2021

@thomashdk, I can only quote for you

this is because you are running the script without a web server

@thomashdk
Copy link

On my site I get this ?

image

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 4, 2021

@thomashdk, can you see the script output for the demo page https://www.sowecms.com/demos/jquery.instagramFeed/index.html?

@thomashdk
Copy link

image
hmm no ? @mahotilo

@thomashdk, can you see the script output for the demo page https://www.sowecms.com/demos/jquery.instagramFeed/index.html?

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 4, 2021

@thomashdk
Hmm, it works for me here
image

@thomashdk
Copy link

@mahotilo i'm getting the images but also all the errors..

Weird..

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 4, 2021

@thomashdk

Weird..

Not exactly. Some of these errors are caused by fair try to load data directly from IG in case they will change their minds.
Other errors are related to too big amount of images in the TAG example (see #119)

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 4, 2021

@thomashdk, to get rid of such errors in the console, follow this recommendation.
image

@thomashdk
Copy link

thomashdk commented Mar 9, 2021

Hi @mahotilo

hmm have already tried with that..
Just getting this now.

image

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 9, 2021

Are you using the script with TAG?

@thomashdk
Copy link

i'm using Username

@thomashdk
Copy link

@mahotilo If I change the username to "Instragram" I get their feed.

If I changed it to my own "thomas___dk" then it dont..

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 9, 2021

Hmm.
It works here on my test site

image

            $.instagramFeed({
                'username': 'thomas___dk',
                'container': '#Instafeed',
                'display_profile': true,
                'display_biography': true,
                'display_gallery': true,
                'display_igtv': true,
                'callback': null,
                'styling': true,
                'items': 8,
                'items_per_row': 4,
                'margin': 1,
                'lazy_load': true, 
                'display_captions': true,
                'cache_time': 360,
            });

@thomashdk
Copy link

You don't have the hostname specified?

Arh you using this ?
https://cdnjs.cloudflare.com/ajax/libs/jquery.instagramFeed/3.0.0/jquery.instagramFeed.min.js

@mahotilo
Copy link
Collaborator

mahotilo commented Mar 9, 2021

You don't have the hostname specified?

Yep. But it is not a problem.

Arh you using this ?

I am using version 3.0.3.

@unlockdesgn
Copy link

Suddenly instagram feed down !
Example:
https://www.jqueryscript.net/demo/Instagram-Photos-Without-API-instagramFeed/

@tiktiddies
Copy link

Suddenly instagram feed down !
Example:
https://www.jqueryscript.net/demo/Instagram-Photos-Without-API-instagramFeed/

same error in demo and my website https://www.tiktiddies.com/ it's not a problem of IP banned but a problem of "Access to XMLHttpRequest at 'https://www.instagram.com/XXXXXXX/' from origin 'https://www.tiktiddies.com' has been blocked by CORS policy: No 'Access-Control-Allow-Origin' header is present on the requested resource."

@unlockdesgn
Copy link

What is the solution ?

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests