Explorar o código

also use tempdir for .exo_node_id to keep the dir clean

Alex Cheema hai 10 meses
pai
achega
4923eb7e44
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      exo/helpers.py

+ 1 - 1
exo/helpers.py

@@ -170,7 +170,7 @@ def is_valid_uuid(val):
 
 
 def get_or_create_node_id():
-  NODE_ID_FILE = Path(os.path.dirname(os.path.abspath(__file__)))/".exo_node_id"
+  NODE_ID_FILE = Path(tempfile.gettempdir()) / ".exo_node_id"
   try:
     if NODE_ID_FILE.is_file():
       with open(NODE_ID_FILE, "r") as f: