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

Receive an error when running script #1

Open
angieconde opened this issue Oct 8, 2018 · 1 comment
Open

Receive an error when running script #1

angieconde opened this issue Oct 8, 2018 · 1 comment

Comments

@angieconde
Copy link

Hi there,

When I run this, I receive the following response, any idea why?

C:\Python27\Scripts\Okta>get_all_active_users.py
Traceback (most recent call last):
File "C:\Python27\Scripts\Okta\get_all_active_users.py", line 104, in
DownloadSFUsers()
File "C:\Python27\Scripts\Okta\get_all_active_users.py", line 99, in DownloadSFUsers
writer.writerow([firstName,lastName,email,login])
UnicodeEncodeError: 'ascii' codec can't encode characters in position 0-1: ordinal not in range(128)

@angieconde
Copy link
Author

angieconde commented Oct 8, 2018

Nevermind - solved it by adding this:

import sys
reload(sys)
sys.setdefaultencoding('utf8')

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

1 participant