diff options
author | Heiner Lohaus <heiner@lohaus.eu> | 2023-10-22 15:15:43 +0200 |
---|---|---|
committer | Heiner Lohaus <heiner@lohaus.eu> | 2023-10-22 15:15:43 +0200 |
commit | 78f93bb737bc72c7a47dabe71adbc5b0349c8072 (patch) | |
tree | 7de64b02f0e32861c00555db27316cea95ebafc9 /g4f/Provider/NoowAi.py | |
parent | Improve readme (diff) | |
download | gpt4free-78f93bb737bc72c7a47dabe71adbc5b0349c8072.tar gpt4free-78f93bb737bc72c7a47dabe71adbc5b0349c8072.tar.gz gpt4free-78f93bb737bc72c7a47dabe71adbc5b0349c8072.tar.bz2 gpt4free-78f93bb737bc72c7a47dabe71adbc5b0349c8072.tar.lz gpt4free-78f93bb737bc72c7a47dabe71adbc5b0349c8072.tar.xz gpt4free-78f93bb737bc72c7a47dabe71adbc5b0349c8072.tar.zst gpt4free-78f93bb737bc72c7a47dabe71adbc5b0349c8072.zip |
Diffstat (limited to 'g4f/Provider/NoowAi.py')
-rw-r--r-- | g4f/Provider/NoowAi.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/g4f/Provider/NoowAi.py b/g4f/Provider/NoowAi.py index 93748258..9dc26d35 100644 --- a/g4f/Provider/NoowAi.py +++ b/g4f/Provider/NoowAi.py @@ -61,6 +61,8 @@ class NoowAi(AsyncGeneratorProvider): yield line["data"] elif line["type"] == "end": break + elif line["type"] == "error": + raise RuntimeError(line["data"]) def random_string(length: int = 10): return ''.join(random.choice(string.ascii_lowercase + string.digits) for _ in range(length))
\ No newline at end of file |