genuinetools / audit Goto Github PK
View Code? Open in Web Editor NEWFor auditing what collaborators, hooks, and deploy keys you have added on all your GitHub repositories.
License: MIT License
For auditing what collaborators, hooks, and deploy keys you have added on all your GitHub repositories.
License: MIT License
It is unclear whether the -orgs flag is mandatory. Without it, with a Personal Access Token, audit does not return any results for me. With -orgs it behaves as expected (output similar to README)
Should a query occur for the orgs accessible (/user/orgs) in the case of empty orgs? Or should the docs mention it (or, should it be a mandatory flag)? Thanks!
If I try to run audit for the owncloud
GitHub org it results in an seg fault because of an invalid memory address or nil pointer dereference issue. That's what I get from audit:
# audit -d --orgs owncloud
DEBU[0000] Getting current user...
DEBU[0000] current user is tboerger
DEBU[0000] Setting affiliations to OWNER,COLLABORATOR,ORGANIZATION_MEMBER
DEBU[0000] Getting repositories for org owncloud...
DEBU[0000] Executing GraphQL query to fetch repos under org owncloud
panic: runtime error: invalid memory address or nil pointer dereference
[signal SIGSEGV: segmentation violation code=0x1 addr=0x10 pc=0x126ac1d]
goroutine 1 [running]:
main.(*GQLClient).Execute(0xc0000dfdb0, 0xc000458800, 0x71c, 0xc0004bcbd0, 0x1295a00, 0xc00041a7d0, 0x12922c0, 0xc000473920, 0x0, 0x0)
/Users/thomas/Golang/src/github.com/genuinetools/audit/graphql.go:83 +0x43d
main.getRepositories(0x137a280, 0xc0000b6040, 0xc000128000, 0xc0000dfdb0, 0xc0004bcba0, 0x3, 0x3, 0x0, 0x0, 0x7ffeefbfe988, ...)
/Users/thomas/Golang/src/github.com/genuinetools/audit/main.go:179 +0x32e
main.main.func2(0x137a280, 0xc0000b6040, 0xc0000120f0, 0x0, 0x0, 0x0, 0x0)
/Users/thomas/Golang/src/github.com/genuinetools/audit/main.go:135 +0x826
github.com/genuinetools/audit/vendor/github.com/genuinetools/pkg/cli.(*Program).run(0xc000112000, 0x137a340, 0xc0000beb70, 0xc0000120c0, 0x4, 0x4, 0x10ad9fd, 0x13134b4)
/Users/thomas/Golang/src/github.com/genuinetools/audit/vendor/github.com/genuinetools/pkg/cli/cli.go:179 +0x253
github.com/genuinetools/audit/vendor/github.com/genuinetools/pkg/cli.(*Program).Run(0xc000112000)
/Users/thomas/Golang/src/github.com/genuinetools/audit/vendor/github.com/genuinetools/pkg/cli/cli.go:89 +0x61
main.main()
/Users/thomas/Golang/src/github.com/genuinetools/audit/main.go:153 +0x3f2
After that I tried to find more information, I moved the errors parsing above the data parsing, and found this error message via Printf:
Something went wrong while executing your query. This may be the result of a timeout, or it could be a GitHub bug. Please include `E7C0:116E:271B82:432CFE:5D78ACF1` when reporting this issue.
So far for my debugging, but I have no idea how this issue could be resolved. Maybe somebody of you got an idea?
GitHub has added "maintain" and "triage"
to prevent using so many api requests this should be changed to use the GitHub GraphQL api.
guide here: https://developer.github.com/v4/guides/forming-calls/
explorer here: https://developer.github.com/v4/explorer/
reply dibs here to make this yours :)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.