scrapy-colorlog
Color log output support for Scrapy.
Installation
pip install scrapy-colorlog
Configuration
Add the following to your Scrapy project settings module:
import scrapy_colorlog
scrapy_colorlog.install()
Settings
COLORLOG_FORMAT
Default:
(
"%(light_black)s%(asctime)s%(reset)s "
"%(light_black)s[%(name)s]%(reset)s "
"%(log_color)s%(levelname)s%(reset)s%(light_black)s:%(reset)s "
"%(message)s"
)
String for formatting log messages. Refer to the colorlog package documentation for available escape codes and parameters to the format string.
See also: LOG_FORMAT.
COLORLOG_DATEFORMAT
Default: "%Y-%m-%d %H:%M:%S"
String for formatting date/time, expansion of the %(asctime)s placeholder in
COLORLOG_FORMAT.
See also: LOG_DATEFORMAT.
COLORLOG_COLORS
Default:
{
"DEBUG": "blue",
"INFO": "cyan",
"WARNING": "yellow",
"ERROR": "red",
"CRITICAL": "purple",
}
A mapping of record level names to color names. Refer to the colorlog package documentation for details.
COLORLOG_SECONDARY_COLORS
Default: None
A mapping of names to log_colors style mappings, defining additional colors that can be used in format strings. Refer to the colorlog package documentation for details.
COLORLOG_RESET
Default: True
Implicitly adds a color reset code to the message output, unless the output already ends with one.
COLORLOG_NO_COLOR
Default: False
Disable color output.
See also: NO_COLOR environment variable.
COLORLOG_FORCE_COLOR
Default: False
Enable color output. Takes precedence over COLORLOG_NO_COLOR.
See also: FORCE_COLOR environment variable.
Environment variables
NO_COLOR
Disable color output. See NO_COLOR for details.
FORCE_COLOR
Enable color output. Takes precedence over NO_COLOR.
Metadata
Release files for scrapy-colorlog 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| scrapy_colorlog-0.1.1.tar.gz | 2.8 kB | Without provenance | Details for scrapy_colorlog-0.1.1.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| scrapy_colorlog-0.1.1-py3-none-any.whl | Python 3 | none | any | Details for scrapy_colorlog-0.1.1-py3-none-any.whl |
Total release size: 6.3 kB
Release files / scrapy_colorlog-0.1.1.tar.gz
| Download URL | scrapy_colorlog-0.1.1.tar.gz |
|---|---|
| Size | 2.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
147d6dfe2c5dcb0dfe9b71af1c47fec15551adc1843941dba233d65f9f410846
|
|
BLAKE2b-256 checksum How to use checksums |
4d22c44c15477dd0b7b655298c6581b8e1cdc5f6a4237ba438bec79b0a85e836
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
pdm/2.13.3 CPython/3.12.0 Windows/11
|
Release files / scrapy_colorlog-0.1.1-py3-none-any.whl
| Download URL | scrapy_colorlog-0.1.1-py3-none-any.whl |
|---|---|
| Size | 3.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e8ca2896449b5cadf1c1b8332d8ffcf3f3ecd27f0d97d1c1a6762e72bb229e27
|
|
BLAKE2b-256 checksum How to use checksums |
b7f34fe0222bc1ab9520fd44bb2023adf3f46ebc5e1dd182d4c5535a3710738d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
pdm/2.13.3 CPython/3.12.0 Windows/11
|
Security for scrapy-colorlog 0.1.1
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.