question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Unable to retrieve query results from Greynoise CLI

See original GitHub issue

Hello, I recently installed pygreynoise but I’m unable to retrieve query results. Instead, i’m getting the following error

root@debian:~# greynoise query -v 23.129.64.215
Traceback (most recent call last):
  File "/usr/local/bin/greynoise", line 10, in <module>
    sys.exit(main())
  File "/usr/local/lib/python3.7/dist-packages/click/core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "/usr/local/lib/python3.7/dist-packages/click/core.py", line 782, in main
    rv = self.invoke(ctx)
  File "/usr/local/lib/python3.7/dist-packages/click/core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/local/lib/python3.7/dist-packages/click/core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/local/lib/python3.7/dist-packages/click/core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "/usr/local/lib/python3.7/dist-packages/greynoise/cli/decorator.py", line 124, in wrapper
    return function(api_client, *args, **kwargs)
  File "/usr/local/lib/python3.7/dist-packages/click/decorators.py", line 21, in new_func
    return f(get_current_context(), *args, **kwargs)
  File "/usr/local/lib/python3.7/dist-packages/greynoise/cli/decorator.py", line 44, in wrapper
    output, file=params.get("output_file", click.open_file("-", mode="w"))
  File "/usr/local/lib/python3.7/dist-packages/click/utils.py", line 272, in echo
    file.write(message)
UnicodeEncodeError: 'latin-1' codec can't encode characters in position 0-28: ordinal not in range(256)
I'm using Debian 10(64 bit) Buster, installed via pip3 18.1

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:9

github_iconTop GitHub Comments

1reaction
bradchiappettacommented, Apr 12, 2021

Hello @tlynx538 . Sorry that you’ve run into an issue with pygreynoise. I’m trying to reproduce this issue, but I’m not getting the same result. Can you try a few things for me and follow up with the output of each?

  • greynoise version
  • pip3 list
  • greynoise ip 23.129.64.215
  • greynoise ip 23.129.64.215 -f json
  • greynoise query 23.129.64.215 -f json
0reactions
bradchiappettacommented, Sep 3, 2021

Wasn’t able to reproduce. Closing issue, can file new issue if issue continues.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Python SDK Information - GreyNoise
The GreyNoise Python SDK is an abstract python library built on top of the GreyNoise API. It is the preferred library for interactions...
Read more >
GreyNoise Python Scripting with Brad Chiappetta
It also provides a CLI to call GreyNoise API directly from the command line. ... try restarting your device. Your browser can't play...
Read more >
Using the GreyNoise Enterprise API
The GreyNoise GNQL API endpoint allows search through the GreyNoise NOISE dataset. The endpoint will take in any query in the GNQL format...
Read more >
greynoise - PyPI
Abstraction to interact with GreyNoise API. ... CLI: Add missing HASSH values to output for IP and QUERY commands. Remove unused PCAP command....
Read more >
GreyNoise Intelligence - GitHub
pygreynoise Public. Python3 library and command line for GreyNoise ... Sends Greynoise query results to a Discord channel on a scheduled basis.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found