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

Errors while executing collector.py #3

Open
ghost opened this issue Oct 15, 2021 · 2 comments
Open

Errors while executing collector.py #3

ghost opened this issue Oct 15, 2021 · 2 comments

Comments

@ghost
Copy link

ghost commented Oct 15, 2021

Hello SIr ,

i ran the collector.py python script it is showing below errors , but in our gcp i want to fetch all the projects running under one folder gcp setup is it possible to do ?

@ghost
Copy link
Author

ghost commented Oct 15, 2021

PS C:\Gcp_Python_Script\gcp-iam-collector-master> python collector.py
2021-10-15 09:08:58,842 INFO init.py file_cache is only supported with oauth2client<4.0.0
2021-10-15 09:08:58,855 INFO init.py file_cache is only supported with oauth2client<4.0.0
2021-10-15 09:08:58,887 INFO init.py file_cache is only supported with oauth2client<4.0.0
2021-10-15 09:08:58,895 INFO init.py file_cache is only supported with oauth2client<4.0.0
2021-10-15 09:08:58,911 DEBUG discovery.py URL being requested: GET https://cloudresourcemanager.googleapis.com/v1/projects?pageSize=400&alt=json
2021-10-15 09:08:58,919 INFO transport.py Attempting refresh to obtain initial access_token
2021-10-15 09:08:58,919 INFO client.py Refreshing access_token
2021-10-15 09:09:01,937 INFO collector.py parsing project [0] projectId: pj-becfr-eagle-dm-bi-prod
Traceback (most recent call last):
File "C:\Gcp_Python_Script\gcp-iam-collector-master\collector.py", line 113, in
dump_projects(iam_iterator)
File "C:\Gcp_Python_Script\gcp-iam-collector-master\collector.py", line 19, in dump_projects
writer.writerow([project_id, project['projectNumber'],
TypeError: a bytes-like object is required, not 'str'

@darbyhopkins
Copy link

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