
Security News
Opengrep Adds Apex Support and New Rule Controls in Latest Updates
The latest Opengrep releases add Apex scanning, precision rule tuning, and performance gains for open source static code analysis.
A simple logger library that outputs logs to both standard output and a file by specifying the log level
MetalMental Loggerは、ログレベルを指定するだけで、標準出力およびファイルにログを出力するシンプルなロガーライブラリです
https://pypi.org/project/metalmental-logger/
pip install metalmental-logger
vi sample.py
import logging
from metalmental_logger.logger import metalmental_logger
# ロガーのインスタンスを作成
logger = metalmental_logger(log_level=logging.DEBUG)
def sample_function():
# ログメッセージを出力
logger.debug("これはデバッグメッセージです")
logger.info("これは情報メッセージです")
logger.warning("これは警告メッセージです")
logger.error("これはエラーメッセージです")
logger.critical("これは重大なエラーメッセージです")
sample_function()
python sample.py
[prompt]$ python sample.py
[2024-09-11 19:48:53.889 JST] [DEBUG] [9行目] [関数名: sample_function] これはデバッグメッセージです
[2024-09-11 19:48:53.889 JST] [INFO] [10行目] [関数名: sample_function] これは情報メッセージです
[2024-09-11 19:48:53.889 JST] [WARNING] [11行目] [関数名: sample_function] これは警告メッセージです
[2024-09-11 19:48:53.889 JST] [ERROR] [12行目] [関数名: sample_function] これはエラーメッセージです
[2024-09-11 19:48:53.889 JST] [CRITICAL] [13行目] [関数名: sample_function] これは重大なエラーメッセージです
[prompt]$
[prompt]$
[prompt]$ cat logs/2024-09-11.log
[2024-09-11 19:48:53.889 JST] [DEBUG] [9行目] [関数名: sample_function] これはデバッグメッセージです
[2024-09-11 19:48:53.889 JST] [INFO] [10行目] [関数名: sample_function] これは情報メッセージです
[2024-09-11 19:48:53.889 JST] [WARNING] [11行目] [関数名: sample_function] これは警告メッセージです
[2024-09-11 19:48:53.889 JST] [ERROR] [12行目] [関数名: sample_function] これはエラーメッセージです
[2024-09-11 19:48:53.889 JST] [CRITICAL] [13行目] [関数名: sample_function] これは重大なエラーメッセージです
[prompt]$
MITライセンスで提供されています
詳細はLICENSEファイルを参照してください
MetalMental - flupino@metalmental.net
FAQs
A simple logger library that outputs logs to both standard output and a file by specifying the log level
We found that metalmental-logger demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
The latest Opengrep releases add Apex scanning, precision rule tuning, and performance gains for open source static code analysis.
Security News
npm now supports Trusted Publishing with OIDC, enabling secure package publishing directly from CI/CD workflows without relying on long-lived tokens.
Research
/Security News
A RubyGems malware campaign used 60 malicious packages posing as automation tools to steal credentials from social media and marketing tool users.