Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Login A/B test detected! Trying another string... #4877

Closed
johnvfitness opened this issue Aug 15, 2019 · 45 comments
Closed

Login A/B test detected! Trying another string... #4877

johnvfitness opened this issue Aug 15, 2019 · 45 comments
Labels

Comments

@johnvfitness
Copy link

My error after update

Login A/B test detected! Trying another string...

sessions end.

@Mr-HaleYa
Copy link
Contributor

same problem

@adamlh
Copy link

adamlh commented Aug 15, 2019

Also have this exact issue - Is there a workaround for this?

@ghost
Copy link

ghost commented Aug 16, 2019

same problem.

@Flaunkerton2395
Copy link

Same problem for me too, with no logs to show for it either...

@ghost
Copy link

ghost commented Aug 16, 2019

#4873
I have the same problem:

InstaPy Version: 0.6.2
Workspace in use: "/root/InstaPy"

INFO [2019-08-16 05:38:23] [username]  Session started!

INFO [2019-08-16 05:38:23] [username]  -- Connection Checklist [1/3] (Internet Connection Status)
INFO [2019-08-16 05:38:27] [username]  - Internet Connection Status: ok
INFO [2019-08-16 05:38:27] [username]  - Current IP is "IP" and it's from "Country"
INFO [2019-08-16 05:38:27] [username]  -- Connection Checklist [2/3] (Instagram Server Status)
INFO [2019-08-16 05:38:33] [username]  - Instagram WebSite Status: Currently Up 
INFO [2019-08-16 05:38:33] [username]  - Instagram Response Time: 122.423 ms 
INFO [2019-08-16 05:38:33] [username]  - Instagram Reponse Code: 200
INFO [2019-08-16 05:38:33] [username]  - Instagram Server Status: ok
INFO [2019-08-16 05:38:33] [username]  -- Connection Checklist [3/3] (Hide Selenium Extension)
INFO [2019-08-16 05:38:33] [username]  - window.navigator.webdriver response: False
INFO [2019-08-16 05:38:33] [username]  - Hide Selenium Extension: ok
Cookie file not found, creating cookie...
Login A/B test detected! Trying another string...

CRITICAL [2019-08-16 05:38:48] [username]  Unable to login to Instagram! You will find more information in the logs above.

INFO [2019-08-16 05:38:52] [username]  Sessional Live Report:
	|> No any statistics to show


[Session lasted 34.68 seconds]
INFO [2019-08-16 05:38:52] [username]  Session ended!

@MariusLoeffler
Copy link

Same problem for me too, and also here: no logs

@seductionn
Copy link

this software is riddled with bugs... same problem

@thealexpak
Copy link

Same
Login A/B test detected! Trying another string...

@mario1105
Copy link

I've fixed it logging in manually by using 'headless_browser=False' and adding a delay right after the 'print("Cookie file not found, creating cookie...")' in the login_util.py
So you can add sleep(60)and then while sleeping you can login manually and leave the script running.

But then I have another error while trying to like by locations or hashtags...
File "/usr/local/lib/python3.6/dist-packages/instapy/instapy.py", line 1914, in like_by_tags self.logger, File "/usr/local/lib/python3.6/dist-packages/instapy/like_util.py", line 606, in check_link media = post_page[0]["media"] KeyError: 'media'

@posittron
Copy link

I was getting this, you have to turn off two factor authentication or any security that sends a text code to your phone. I turned it off and it works now. Just idk why firefox is so slow in loading users

@brnskn
Copy link
Contributor

brnskn commented Aug 16, 2019

Same problem +1

@noelDz
Copy link

noelDz commented Aug 16, 2019

Experiencing the same problem here

@GreatMalboro
Copy link

I also have this issue

@JeanLoriston
Copy link

+1 same error

@Mockapapella
Copy link

This issue was fixed in the development branch

pip install -U git+https://github.com/timgrossman/InstaPy@dev to update

@Tr1pke
Copy link

Tr1pke commented Aug 17, 2019

Not working. Everything is up to date

@posittron
Copy link

This issue was fixed in the development branch
pip install -U git+https://github.com/timgrossman/InstaPy@dev to update

Dude can you help me with this. I've updated to 0.6.2 from dev branch but the loading of likers of pictures is painfully slow. If you want to reproduce the issue ,its easy just use the follow_likers option from the documentation and you'll see that as the no. of users loaded increases it gets slower and slower. I think its a quick fix and its driving me crazy

@Tr1pke
Copy link

Tr1pke commented Aug 17, 2019

running 0.6.2 now , not much of a difference it doesn't s shouw the Login A/B etc anymore.

it just kills the session now.

` .. .. .. .. .. .. .. .. .. .. ..
No any custom workspace provided. ~using existing..
InstaPy Version: 0.6.2
.
. .. .. .. .. .. .. ._.
Workspace in use: "/home/steven/InstaPy"
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO
INFO [2019-08-17 20:22:16] [.runs] Session started!
oooooooooooooooooooooooooooooooooooooooooooooooooooooo
INFO [2019-08-17 20:22:16] [
.runs] -- Connection Checklist [1/3] (Internet Connection Status)
INFO [2019-08-17 20:22:16] [.runs] - Internet Connection Status: ok
INFO [2019-08-17 20:22:16] [
.runs] - Current IP is "77.109.96.213" and it's from "Belgium/BE"
INFO [2019-08-17 20:22:17] [.runs] -- Connection Checklist [2/3] (Instagram Server Status)
INFO [2019-08-17 20:22:23] [
.runs] - Instagram WebSite Status: Currently Up
INFO [2019-08-17 20:22:23] [.runs] - Instagram Response Time: 112.239 ms
INFO [2019-08-17 20:22:23] [
.runs] - Instagram Reponse Code: 200
INFO [2019-08-17 20:22:23] [.runs] - Instagram Server Status: ok
INFO [2019-08-17 20:22:23] [
.runs] -- Connection Checklist [3/3] (Hide Selenium Extension)
INFO [2019-08-17 20:22:23] [.runs] - window.navigator.webdriver response: False
INFO [2019-08-17 20:22:23] [
.runs] - Hide Selenium Extension: ok
Cookie file not found, creating cookie...
Instagram detected an unusual login attempt
Check Instagram App for "Suspicious Login attempt" prompt
A security code was sent to your Email: vs@s.
INFO [2019-08-17 20:23:11] [
.runs] Security Code not present in /home/steven/InstaPy/logs/.runs/state.json file
Type the security code here: 572186
.......................................................................................................................
CRITICAL [2019-08-17 20:24:45] [
.runs] Unable to login to Instagram! You will find more information in the logs above.
'''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''''

INFO [2019-08-17 20:24:46] [*.runs] Sessional Live Report:
|> No any statistics to show

[Session lasted 2.64 minutes]
OOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO
INFO [2019-08-17 20:24:46] [*.runs] Session ended!
oooooooooooooooooooooooooooooooooooooooooooooooooooooo
`

@noelDz
Copy link

noelDz commented Aug 17, 2019

This issue was fixed in the development branch

pip install -U git+https://github.com/timgrossman/InstaPy@dev to update

I got my Instapy script running as usual after updating and logging in using the two step verification process. You might need to set headless_browser = False on your script in order to enter the verification code IG sends you (adding a page delay on the settings also helps):

session = InstaPy(username="ig_user",
password="ig_password",
headless_browser=False,
page_delay=25
)
Hope that helps

@Mr-HaleYa
Copy link
Contributor

To anybody still having this issue on 6.1
Its caused by a typo in the file xpath_compile.py

Line 159 "login_elem_no_such_exception": "//a[text()='Log``` In']",

It looks like this ^^^

It needs to look like this

Line 159 "login_elem_no_such_exception": "//button[text()='Log In']",

It will still throw the statement Login A/B test detected! Trying another string... but then it should login...

It most likely will ask for a security code that will be sent to your email, just enter that and you should be all set!

@otomay
Copy link

otomay commented Aug 18, 2019

To anybody still having this issue on 6.1
Its caused by a typo in the file xpath_compile.py

Line 159 "login_elem_no_such_exception": "//a[text()='Log``` In']",

It looks like this ^^^

It needs to look like this

Line 159 "login_elem_no_such_exception": "//button[text()='Log In']",

It will still throw the statement Login A/B test detected! Trying another string... but then it should login...

It most likely will ask for a security code that will be sent to your email, just enter that and you should be all set!

it worked for me, thanks

@twilsens
Copy link

Worked for me also!!

@Flaunkerton2395
Copy link

Do you know where the file xpath_compile.py is stored? I cannot seem to find it in my installation.

@Mr-HaleYa
Copy link
Contributor

Do you know where the file xpath_compile.py is stored? I cannot seem to find it in my installation.

What OS are you using?

@Flaunkerton2395
Copy link

I'm currently on Mojave 10.14.5

@Mr-HaleYa
Copy link
Contributor

Ummm I've never tried it on Mac...
On Linux its under /usr/local/lib/python3.6/dist-packages/instapy
On Windows its under E:\Users\(yourprofile)\AppData\Local\Programs\Python\Python37-32\Lib\site-packages\instapy

Try to find python and then find site-packages and it should be under the folder called Instapy

@Flaunkerton2395
Copy link

I strangely don't even have that file on my Mac, the one mention of 'login_elem_no_such_exception' is in my login.util file:

try:
login_elem = browser.find_element_by_xpath(
read_xpath(login_user.name, "login_elem"))
except NoSuchElementException:
print("Login A/B test detected! Trying another string...")
try:
login_elem = browser.find_element_by_xpath(
read_xpath(login_user.name, "login_elem_no_such_exception")
)
except NoSuchElementException:
return False

@Mr-HaleYa
Copy link
Contributor

@Flaunkerton2395 No that's where the error is thrown from but the reason it is thrown is because of a typo in another file

@Mr-HaleYa
Copy link
Contributor

For instapy to function you have to have the file xpath_compile.py.

@Mr-HaleYa
Copy link
Contributor

#4895

@Flaunkerton2395
Copy link

#4902

@TeraJaQ
Copy link

TeraJaQ commented Aug 26, 2019

For RaspberryPi the xpath_compile.py file is stored in:

/home/pi/.local/lib/python3.7/site-packages/instapy/xpath_compile.py

@mikediachenko
Copy link

For RaspberryPi the xpath_compile.py file is stored in: ...

@Flaunkerton2395 The same is for macOS. Please, check it.

Sent with GitHawk

@giacomoalonzi
Copy link

To anybody still having this issue on 6.1
Its caused by a typo in the file xpath_compile.py

Line 159 "login_elem_no_such_exception": "//a[text()='Log``` In']",

It looks like this ^^^

It needs to look like this

Line 159 "login_elem_no_such_exception": "//button[text()='Log In']",

It will still throw the statement Login A/B test detected! Trying another string... but then it should login...

It most likely will ask for a security code that will be sent to your email, just enter that and you should be all set!

solved for me ⚡️

For RaspberryPi the xpath_compile.py file is stored in:

/home/pi/.local/lib/python3.7/site-packages/instapy/xpath_compile.py

If you use instapy-gui the path is the following:
instapy-gui/env/lib/python3.7/site-packages/instapy

@breuerfelix breuerfelix mentioned this issue Aug 30, 2019
@stale
Copy link

stale bot commented Sep 29, 2019

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

If this problem still occurs, please open a new issue

@stale stale bot added the wontfix label Sep 29, 2019
@stale stale bot closed this as completed Oct 6, 2019
@mrglenean
Copy link

Hi guys, I'm using python 3.7 latest instapy, with chromedriver on Mac, and I check xpath file and looks fine but I'm still having the same problem, cannot running instapy. Someone knows how to solve this?

@Tr1pke
Copy link

Tr1pke commented Mar 31, 2020

Hi guys, I'm using python 3.7 latest instapy, with chromedriver on Mac, and I check xpath file and looks fine but I'm still having the same problem, cannot running instapy. Someone knows how to solve this?

Welcome to 2020. Instapy is not longer supported.

@mrglenean
Copy link

problem

Seriously? Really?

@Tr1pke
Copy link

Tr1pke commented Mar 31, 2020

problem

Seriously? Really?

Where were you the last 2 years? Mars ?

@mrglenean
Copy link

problem

Seriously? Really?

Where were you the last 2 years? Mars ?

if I tell you, you cannot believe it. Thank you for the info! I didn't see it.

@anybudy
Copy link

anybudy commented May 12, 2020

Hi guys, I'm using python 3.7 latest instapy, with chromedriver on Mac, and I check xpath file and looks fine but I'm still having the same problem, cannot running instapy. Someone knows how to solve this?

Welcome to 2020. Instapy is not longer supported.

Where is it written? (writing this from 2050)

@BANDRIO
Copy link

BANDRIO commented Sep 26, 2020

Hi guys, I'm using python 3.7 latest instapy, with chromedriver on Mac, and I check xpath file and looks fine but I'm still having the same problem, cannot running instapy. Someone knows how to solve this?

Welcome to 2020. Instapy is not longer supported.

Where is it written? (writing this from 2050)

shit.
got late.

@najmehn00
Copy link

Hi guys, I'm using python 3.7 latest instapy, with chromedriver on Mac, and I check xpath file and looks fine but I'm still having the same problem, cannot running instapy. Someone knows how to solve this?

Welcome to 2020. Instapy is not longer supported.

but we have instapy version 2022 :/

@giorivoira
Copy link

To anybody still having this issue on 6.1 Its caused by a typo in the file xpath_compile.py

Line 159 "login_elem_no_such_exception": "//a[text()='Log``` In']",

It looks like this ^^^

It needs to look like this

Line 159 "login_elem_no_such_exception": "//button[text()='Log In']",

It will still throw the statement Login A/B test detected! Trying another string... but then it should login...

It most likely will ask for a security code that will be sent to your email, just enter that and you should be all set!

This is not working (anymore I think). Any suggestions?

@arctronic
Copy link

"login_elem_no_such_exception": "//button[text()='Log In']",

From 2023, not working xd

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

No branches or pull requests