瀏覽代碼

Modify. Words should be in small letters

Sergienko Anton 7 年之前
父節點
當前提交
5559e8beb0
共有 2 個文件被更改,包括 6 次插入3 次删除
  1. 1 1
      src/data.json
  2. 5 2
      src/program_efremova.py

+ 1 - 1
src/data.json

@@ -71618,7 +71618,7 @@
     },
     },
     "Минологий": {
     "Минологий": {
         "definition": "м. Жития святых, расположенные в календарном порядке.",
         "definition": "м. Жития святых, расположенные в календарном порядке.",
-        "answerIsProbablyNotNoun": "404"
+        "answerIsProbablyNotNoun": "noun"
     },
     },
     "миномёт": {
     "миномёт": {
         "definition": "м. Артиллерийское орудие, предназначенное для навесной стрельбы минами (1*)."
         "definition": "м. Артиллерийское орудие, предназначенное для навесной стрельбы минами (1*)."

+ 5 - 2
src/program_efremova.py

@@ -273,7 +273,7 @@ def check_word_in_morfologija(word, html):
 
 
 def check_word_in_site(word, url, function_check_html):
 def check_word_in_site(word, url, function_check_html):
     answer = None
     answer = None
-    response = requests.get(url + word)
+    response = requests.get(url + word.lower())
     if response.status_code == 200:
     if response.status_code == 200:
         answer_from_html = function_check_html(word, response.text)
         answer_from_html = function_check_html(word, response.text)
         if answer_from_html is not None:
         if answer_from_html is not None:
@@ -353,7 +353,10 @@ def main():
 
 
 
 
 def test():
 def test():
-    check_word_in_site('мост', 'http://www.morfologija.ru/словоформа/', check_word_in_morfologija)
+    check_word_in_site('минологий', 'http://www.morfologija.ru/словоформа/', check_word_in_morfologija)
+    check_word_in_site('минологий', 'https://goldlit.ru/component/slog?words=', check_word_in_goldlit)
+    check_word_in_site('минологий', 'https://dic.academic.ru/searchall.php?SWord=', check_word_in_academic)
+    check_word_in_site('минологий', 'https://ru.wiktionary.org/wiki/', check_word_in_wiktionary)
 
 
 
 
 if __name__ == '__main__':
 if __name__ == '__main__':