Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

loguru-notification

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

loguru-notification

Project logging printout

  • 0.0.7
  • PyPI
  • Socket score

Maintainers
1

loguru-notification

loguru-notification 是一个日志输出项目,在loguru的基础集成日志输出到控制台、输出到Slack、并结合CMRESHandler把日记记录到ElasticSearch, 更容易的对日志进行分析。

Installation

1.使用python包管理工具pip 进行安装。

pip install loguru-notification

Usage

对loguru-notification进行配置,并输出日志信息。

from configlog.setlogs import Logger

logger = Logger(
    webhook_url='Your Slack webhook URL',  # Slack webhook URL  # noqa
    es_host='172.0.0.1:9200',  # log on ElasticSearch host ip and port
)

if __name__ == '__main__':
    logger.printout('输出到控制台')
    logger.msg('输出到控制台,并写入ElasticSearch')
    logger.notice('输出到控制台和Slack,并写入ElasticSearch')

Contributing

欢迎使用,如果有好的优化方法也欢迎提交修改。

使用前请做适当的测试,以确定跟您的项目完全兼容。

License

MIT

FAQs


Did you know?

Socket

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.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc