carolinacon commited on
Commit
d1c3651
·
1 Parent(s): 4ad81fd

corrected issue when setting up chess engine variable

Browse files
Files changed (1) hide show
  1. utils/dependencies_checker.py +3 -2
utils/dependencies_checker.py CHANGED
@@ -25,7 +25,8 @@ def find_stockfish_path():
25
 
26
 
27
  def check_dependencies():
28
- if os.getenv("CHESS_ENGINE_PATH") is None:
 
29
  stockfish_path = find_stockfish_path()
30
  if stockfish_path:
31
  print(f"Found Stockfish at: {stockfish_path}")
@@ -33,4 +34,4 @@ def check_dependencies():
33
  else:
34
  print("Stockfish not found!")
35
  else:
36
- print(f"Stockfish already set to {os.getenv("CHESS_ENGINE_PATH")}")
 
25
 
26
 
27
  def check_dependencies():
28
+ chess_engine_path =os.getenv("CHESS_ENGINE_PATH", "")
29
+ if chess_engine_path is None:
30
  stockfish_path = find_stockfish_path()
31
  if stockfish_path:
32
  print(f"Found Stockfish at: {stockfish_path}")
 
34
  else:
35
  print("Stockfish not found!")
36
  else:
37
+ print(f"Stockfish already set to {chess_engine_path}")