python-chess-coverage
Expose the potential energy of chess ply
This library constructs a dictionary of chess piece threat and protection statuses, keyed by "rank and file" board positions.
Usage:
import chess
import json
from chess_coverage import Coverage
board = chess.Board()
board.push_san("e4")
board.push_san("d5")
c = Coverage(board)
cover = c.cover()
print(json.dumps(cover, indent=2, sort_keys=True))
Example result fragment:
"e4": {
"color": true,
"index": 28,
"is_protected_by": [],
"is_threatened_by": ["d5"],
"moves": ["d5", "e5"],
"occupant": "white pawn",
"position": "e4",
"protects": [],
"symbol": "P",
"threatens": ["d5"],
"black_can_move_here": [],
"white_can_move_here": [],
"black_can_capture_here": [],
"white_can_capture_here": []
}
Metadata
Release files for chess-coverage 0.1.8
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| chess_coverage-0.1.8.tar.gz | 41.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| chess_coverage-0.1.8-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 69.8 kB
Release files / chess_coverage-0.1.8.tar.gz
| Download URL | chess_coverage-0.1.8.tar.gz |
|---|---|
| Size | 41.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7bf35038b75a6c8b53805804e8b48d13480cdacd960b52c6b47fa7ee9c66b106
|
|
BLAKE2b-256 checksum How to use checksums |
9a3f2698ae37e958633545c5a4e5508b39da2305fd7a30cc47ab356b4f800ee6
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.1
|
Release files / chess_coverage-0.1.8-py3-none-any.whl
| Download URL | chess_coverage-0.1.8-py3-none-any.whl |
|---|---|
| Size | 28.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
56c6d82a79c393c97337ed6b68846b4f0b8b6e21bd16fa1ddf5b4fa9fc8ed4b7
|
|
BLAKE2b-256 checksum How to use checksums |
9c4321238dc769634a74cbf1fd72ca3fc187a66bb313ec0bdccfb56a2868a83e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.1
|