Giter VIP home page Giter VIP logo

starred_search's Issues

facing `UnhandledPromiseRejectionWarning: Error: Request failed with status code 403` on making API requests.

λ starred_search --user 'link-' --find 'es6' -d
(node:12837) UnhandledPromiseRejectionWarning: Error: Request failed with status code 403
    at createError (/home/greyhound/.nvm/versions/node/v14.15.0/lib/node_modules/starred_search/bin/starred_search:1212:15)
    at settle (/home/greyhound/.nvm/versions/node/v14.15.0/lib/node_modules/starred_search/bin/starred_search:1471:12)
    at IncomingMessage.handleStreamEnd (/home/greyhound/.nvm/versions/node/v14.15.0/lib/node_modules/starred_search/bin/starred_search:598:11)
    at IncomingMessage.emit (events.js:327:22)
    at endReadableNT (_stream_readable.js:1327:12)
    at processTicksAndRejections (internal/process/task_queues.js:80:21)
(Use `node --trace-warnings ...` to show where the warning was created)
(node:12837) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2)
(node:12837) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

λ starred_search --version
0.1.10

λ node --version 
v14.15.0

I installed using npm install starred_search -g
The operating system is Ubuntu 20.04 LTS in WSL1.

I'm not a nodejs person, but these warnings/errors are not fetching any results, yields 403. README didn't say anything about adding keys.
Is there anything i'm doing wrong?

Add parameter for github access token

Unauthenticated requests without github access tokens are rate limited to 60 requests per hour, and the application may send many requests in one run. A parameter should be added to allow users to add their access token to the requests.

-t, --token <github access token> (optional)
  A github access token to be used in sending requests. generate one from here (https://github.com/settings/tokens?type=beta)

# usage example
$ starred_search -u 'link-' -f 'es6' -t github_pat_*****

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.