Skip to content

Commit

Permalink
Suppress unnecessary warnings in Windows bundle
Browse files Browse the repository at this point in the history
  • Loading branch information
jhc13 committed Apr 27, 2024
1 parent a0f15c9 commit 43190e8
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions taggui/run_gui.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import sys
import traceback

import transformers
from PySide6.QtGui import QImageReader
from PySide6.QtWidgets import QApplication, QMessageBox

Expand All @@ -23,6 +24,10 @@ def run_gui():


if __name__ == '__main__':
# Suppress warnings when running inside a bundled version of the
# application.
if sys.stdout is None:
transformers.logging.set_verbosity_error()
try:
run_gui()
except Exception as exception:
Expand Down

0 comments on commit 43190e8

Please sign in to comment.