Skip to content
This repository has been archived by the owner on Aug 13, 2021. It is now read-only.

Add www() for searching on the web #185

Closed
aroberge opened this issue Feb 11, 2021 · 4 comments
Closed

Add www() for searching on the web #185

aroberge opened this issue Feb 11, 2021 · 4 comments

Comments

@aroberge
Copy link
Owner

aroberge commented Feb 11, 2021

As suggested in https://pythonbytes.fm/episodes/show/220/what-why-and-where-of-friendly-errors-in-python, perhaps I should add a www() function that would search for a corresponding error (type and message) on the web. This could be done using Python's webbrowser module and searching on duckduckgo (for privacy).

Also perhaps add a special function to search Python docs; perhaps py_doc() which, by default, would search on the error name on the python site but could have a special field linking to a specific place. Since the python docs are also available in French, it should link to the appropriate version.

Before I can create the py_doc() function, I need to restructure the "back end" and change the return argument of probably close to 100 functions (which is something I was planning to do, but is getting a higher priority).

@aroberge
Copy link
Owner Author

www searches for the error message. If no exception has been raised, it simply searches for Friendly-traceback ! 😄

@aroberge
Copy link
Owner Author

Closing this issue. Much work needed for custom links, but both www() and py_doc() work with the existing information.

@aroberge aroberge reopened this Feb 12, 2021
@aroberge
Copy link
Owner Author

Removing py_doc() and adding a python keyword to www() instead. Also added another argument to search for a specific term.

@aroberge
Copy link
Owner Author

image

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant