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

No credentials stored [Errno 2] No such file or directory: 'data/my@mail' #113

Closed
dejurin opened this issue Jan 1, 2021 · 20 comments
Closed

Comments

@dejurin
Copy link

dejurin commented Jan 1, 2021

from py3pin.Pinterest import Pinterest

pinterest = Pinterest(email='my@mail',
                      password='pass',
                      username='username')


@imgVOID
Copy link
Contributor

imgVOID commented Jan 4, 2021

Me too

@bstoilov
Copy link
Owner

bstoilov commented Jan 5, 2021

you are not passing the cred_root parameter

Pinterest(email='your email goes here', password='password goes here', username='look in pinterest url', cred_root='cred root dir')

try providing it and see if that helps

@dejurin
Copy link
Author

dejurin commented Jan 5, 2021

you are not passing the cred_root parameter

Pinterest(email='your email goes here', password='password goes here', username='look in pinterest url', cred_root='cred root dir')

try providing it and see if that helps

I was try

from py3pin.Pinterest import Pinterest

pinterest = Pinterest(email='mail@gmail.com',
                      password='pass',
                      username='https://www.pinterest.com/myURL/')
No credentials stored [Errno 2] No such file or directory: 'data/mail@gmail.com'

VERSION: Python 3.9.1

@bstoilov
Copy link
Owner

bstoilov commented Jan 5, 2021

Did you call login? 'data' is the default location of the credentials, there is a logic to make sure the directory exists etc.

@imgVOID
Copy link
Contributor

imgVOID commented Jan 6, 2021

Previously, the program itself created a directory, if that does not exist, now it gives an error. Maybe it's a my Windows admin rules problem.
But today, in my case, directory has been created, and the program show the error too. I think it can be an error with the Windows' and UNIX difference in the path slashes, but I'm not shure about it.

@dejurin
Copy link
Author

dejurin commented Jan 6, 2021

Did you call login? 'data' is the default location of the credentials, there is a logic to make sure the directory exists etc.

sure, 'data' created but nothing else.

OS: OSX 11.0.1
VERSION: Python 3.9.1

@bstoilov
Copy link
Owner

bstoilov commented Jan 6, 2021

Works on my machine, I have to test it on a different one and windows apparently.

Shouldn't be a os specific path problem since I am using this

os.path.join(self.root, self.username)

@imgVOID
Copy link
Contributor

imgVOID commented Jan 6, 2021

Works on my machine, I have to test it on a different one and windows apparently.

Shouldn't be a os specific path problem since I am using this

os.path.join(self.root, self.username)

U're right, so we need to do some fixes with the os pathes
my Windows say that there isnt any " \ \data" (double slash) folder.

@dejurin
Copy link
Author

dejurin commented Jan 6, 2021

I was add fullpath, but not work.

    def _get_cred_file_path(self):
        return os.path.join('/Users/admin/pin' + self.root, self.username)
No credentials stored [Errno 2] No such file or directory: 

Script not create file.

@imgVOID
Copy link
Contributor

imgVOID commented Jan 6, 2021

I was add fullpath, but not work.

    def _get_cred_file_path(self):
        return os.path.join('/Users/admin/pin' + self.root, self.username)
No credentials stored [Errno 2] No such file or directory: 

Script not create file.

Check your Windows admin permissions and write access.
And go to fix this file

@dejurin
Copy link
Author

dejurin commented Jan 6, 2021

I was add fullpath, but not work.

    def _get_cred_file_path(self):
        return os.path.join('/Users/admin/pin' + self.root, self.username)
No credentials stored [Errno 2] No such file or directory: 

Script not create file.

Check your Windows admin permissions and write access.
And go to fix this file

I'm use MAC, I was try run with root permissions, but doest work.
PS: you run this script successful on windows?

@imgVOID
Copy link
Contributor

imgVOID commented Jan 6, 2021

PS: you run this script successful on windows?

After the captcha update no, but before - yes many times

@imgVOID
Copy link
Contributor

imgVOID commented Jan 6, 2021

You know that only the one way to release your problem is to fix this file

try:
    with open(self._get_cred_file_path()) as f:
        content = f.read()
        self.cookies = json.loads(content)
except Exception as e:
    print("No credentials stored", e)

@bstoilov
Copy link
Owner

I was not able to reproduce the issue in any way on my linux machine. Probably it is an os specific thing. I will try on mac and windows and let you know

@bstoilov
Copy link
Owner

Works on all win and mac

@animemoeus
Copy link

same problem, Ubuntu 20.04

No credentials stored [Errno 2] No such file or directory: 'data/my@email.com'

@bstoilov
Copy link
Owner

@animemoeus Is the login sucessful?

@animemoeus
Copy link

@animemoeus Is the login sucessful?

Yes, but I need to log in every time

No credentials stored [Errno 2] No such file or directory: 'data/my.@email.com'
 
[WDM] - Current google-chrome version is 87.0.4280
[WDM] - Get LATEST driver version for 87.0.4280
[WDM] - Driver [/home/user/.wdm/drivers/chromedriver/linux64/87.0.4280.88/chromedriver] found in cache
Failed to login Message: 

Successfully logged in with account my@email.com

@imgVOID
Copy link
Contributor

imgVOID commented Jan 18, 2021

@animemoeus Is the login sucessful?

Yes, but I need to log in every time

No credentials stored [Errno 2] No such file or directory: 'data/my.@email.com'
 
[WDM] - Current google-chrome version is 87.0.4280
[WDM] - Get LATEST driver version for 87.0.4280
[WDM] - Driver [/home/user/.wdm/drivers/chromedriver/linux64/87.0.4280.88/chromedriver] found in cache
Failed to login Message: 

Successfully logged in with account my@email.com

I had this problem yesterday. In my case, it was because Windows Defender was clearing my ADMIN ROOT PRIVILEGES !!!

@imgVOID
Copy link
Contributor

imgVOID commented Jan 18, 2021

Thus, the probability that you have problems with the OS write permissions or antivirus settings is 99%.

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

No branches or pull requests

4 participants