Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

wikipedia search issue #329

Open
shainmathew77 opened this issue Sep 24, 2023 · 0 comments
Open

wikipedia search issue #329

shainmathew77 opened this issue Sep 24, 2023 · 0 comments

Comments

@shainmathew77
Copy link

PS C:\Program Files\Python310\virtual assistant> pip install --upgrade wikipedia
Requirement already satisfied: wikipedia in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (1.4.0)
.12.2)
Requirement already satisfied: requests<3.0.0,>=2.0.0 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from wikipedia) (2.31.0)
Requirement already satisfied: charset-normalizer<4,>=2 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from requests<3.0.0,>=2.0.0->wikipedia) (3.2.0)
Requirement already satisfied: idna<4,>=2.5 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from requests<3.0.0,>=2.0.0->wikipedia) (3.4)
Requirement already satisfied: urllib3<3,>=1.21.1 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from requests<3.0.0,>=2.0.0->wikipedia) (2.0.4)
Requirement already satisfied: certifi>=2017.4.17 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from requests<3.0.0,>=2.0.0->wikipedia) (2023.7.22)
Requirement already satisfied: soupsieve>1.2 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from beautifulsoup4->wikipedia) (2.4.1)
PS C:\Program Files\Python310\virtual assistant> pip install wikipedia
Requirement already satisfied: wikipedia in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (1.4.0)
Requirement already satisfied: beautifulsoup4 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from wikipedia) (4Requirement already satisfied: requests<3.0.0,>=2.0.0 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from wikipedia) (2.31.0)
Requirement already satisfied: charset-normalizer<4,>=2 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from requests<3.0.0,>=2.0.0->wikipedia) (3.2.0)
Requirement already satisfied: idna<4,>=2.5 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from requests<3.0.0,>=2.0.0->wikipedia) (3.4)
Requirement already satisfied: urllib3<3,>=1.21.1 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from requests<3.0.0,>=2.0.0->wikipedia) (2.0.4)
Requirement already satisfied: certifi>=2017.4.17 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from requests<3.0.0,>=2.0.0->wikipedia) (2023.7.22)
Requirement already satisfied: soupsieve>1.2 in c:\users\shain mathew\appdata\local\programs\python\python311\lib\site-packages (from beautifulsoup4->wikipedia) (2.4.1)
PS C:\Program Files\Python310\virtual assistant> & "C:/Users/SHAIN MATHEW/AppData/Local/Programs/Python/Python311/python.exe" "c:/Program Files/Python310/virtual assistant/main2.py"
pygame 2.5.1 (SDL 2.28.2, Python 3.11.4)
Hello from the pygame community. https://www.pygame.org/contribute.html
Listening.....
Recognizing.....
User said: Wikipedia

Traceback (most recent call last):
File "c:\Program Files\Python310\virtual assistant\main2.py", line 271, in
run_virtual_assistant()
File "c:\Program Files\Python310\virtual assistant\main2.py", line 171, in run_virtual_assistant
results = wikipedia_search(query)
^^^^^^^^^^^^^^^^^^^^^^^
File "c:\Program Files\Python310\virtual assistant\main2.py", line 101, in wikipedia_search
results = wikipedia.summary(query, sentences=2)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python311\Lib\site-packages\wikipedia\util.py", line 28, in call
ret = self._cache[key] = self.fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python311\Lib\site-packages\wikipedia\wikipedia.py", line 231, in summary
page_info = page(title, auto_suggest=auto_suggest, redirect=redirect)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python311\Lib\site-packages\wikipedia\wikipedia.py", line 270, in page
results, suggestion = search(title, results=1, suggestion=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python311\Lib\site-packages\wikipedia\util.py", line 28, in call
ret = self._cache[key] = self.fn(*args, **kwargs)
^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\user\AppData\Local\Programs\Python\Python311\Lib\site-packages\wikipedia\wikipedia.py", line 109, in search
raise WikipediaException(raw_results['error']['info'])
wikipedia.exceptions.WikipediaException: An unknown error occured: "The "srsearch" parameter must be set.". Please report it on GitHub!

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

No branches or pull requests

1 participant