Spaces:
Sleeping
Sleeping
apple muncy
commited on
Commit
Β·
fb6d0f1
1
Parent(s):
969592a
added stag.log
Browse filesSigned-off-by: apple muncy <[email protected]>
- mcp_server.py +2 -2
mcp_server.py
CHANGED
@@ -13,7 +13,7 @@ from dotenv import load_dotenv
|
|
13 |
#adding logger"π Starting HF Tagging Bot...
|
14 |
import logging
|
15 |
loggerS = logging.getLogger(__name__)
|
16 |
-
logging.basicConfig(filename='/home/user/
|
17 |
#for testing logger
|
18 |
loggerS.debug('MCP-server, This message should go to the log file')
|
19 |
|
@@ -69,7 +69,7 @@ def get_current_tags(repo_id: str) -> str:
|
|
69 |
def add_new_tag(repo_id: str, new_tag: str) -> str:
|
70 |
"""Add a new tag to a HuggingFace model repository via PR"""
|
71 |
print(f"π§ add_new_tag called with repo_id: {repo_id}, new_tag: {new_tag}")
|
72 |
-
|
73 |
if not hf_api:
|
74 |
error_result = {"error": "HF token not configured"}
|
75 |
json_str = json.dumps(error_result)
|
|
|
13 |
#adding logger"π Starting HF Tagging Bot...
|
14 |
import logging
|
15 |
loggerS = logging.getLogger(__name__)
|
16 |
+
logging.basicConfig(filename='/home/user/Stag.log', encoding='utf-8', level=logging.DEBUG)
|
17 |
#for testing logger
|
18 |
loggerS.debug('MCP-server, This message should go to the log file')
|
19 |
|
|
|
69 |
def add_new_tag(repo_id: str, new_tag: str) -> str:
|
70 |
"""Add a new tag to a HuggingFace model repository via PR"""
|
71 |
print(f"π§ add_new_tag called with repo_id: {repo_id}, new_tag: {new_tag}")
|
72 |
+
loggerS.info('Server-Add a new tag')
|
73 |
if not hf_api:
|
74 |
error_result = {"error": "HF token not configured"}
|
75 |
json_str = json.dumps(error_result)
|