Closed chrisgrieser closed 6 days ago
Please raise a PR.
I'm not really sure what the best way for doing this would be. I have an implementation here:
https://github.com/kometenstaub/ddgr
Diff:
https://github.com/jarun/ddgr/compare/main...kometenstaub:ddgr:main
However, this approach changes the JSON format and would be a breaking change.
The answers from before are still a list, but the return format is a dict.
{
results: [],
instant_answer: "…",
}
instant_answer
will not be added to the dict if it is missing.
Not sure whether it's a bug or intentional, when using
--json
, the instant answer is left out, resulting in the need to often callddgr
twice to get json output & any instant answer