Skip to content

Commit

Permalink
Generate: Reduce some logging
Browse files Browse the repository at this point in the history
  • Loading branch information
Croydon committed May 9, 2024
1 parent 24ca5c3 commit 8467bb0
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/generate.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ jobs:
name: "Generate"
runs-on: ubuntu-22.04
env:
CONAN_LOGGING_LEVEL: 10
CONAN_LOGGING_LEVEL: 20
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
Expand Down
6 changes: 3 additions & 3 deletions generate.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,11 +59,11 @@ async def get_external_site(request: Request, url_path: str):

cache_url_path = os.path.join("r", remote_config, url_path.replace("/", os.sep))

logger.info(f"Remote Type: {remote_type}, Remote HTTP URL: {remote_http_url}, Remote Name: {remote_config}")
# logger.info(f"Remote Type: {remote_type}, Remote HTTP URL: {remote_http_url}, Remote Name: {remote_config}")
# logger.info(f"url_path: {url_path}, cache_url_path: {cache_url_path}")

if url_path == "v1/ping" and len(cached_headers) != 0:
logger.info(f"Cached headers: {cached_headers}")
# logger.info(f"Cached headers: {cached_headers}")
return Response(headers=cached_headers)

# User Agent Manipulation
Expand Down Expand Up @@ -122,7 +122,7 @@ async def get_external_site(request: Request, url_path: str):
def _shell(command: str, check: bool=True) -> str:
logger.info(f"Run: {command}")
process = subprocess.run(command, shell=True, check=check, stdout=subprocess.PIPE, universal_newlines=True)
logger.info(f"Shell: {process.stdout}")
logger.info(f"Out: {process.stdout}")
return process.stdout

def _shell_background(command: str) -> None:
Expand Down

0 comments on commit 8467bb0

Please sign in to comment.