Files
markitect-main/markitect/assets/constants.py
tegwick 4bcc178f43
Some checks failed
Test Suite / code-quality (push) Has been cancelled
Test Suite / unit-tests (3.11) (push) Has been cancelled
Test Suite / unit-tests (3.12) (push) Has been cancelled
Test Suite / integration-tests (push) Has been cancelled
Test Suite / e2e-tests (push) Has been cancelled
Test Suite / performance-tests (push) Has been cancelled
Test Suite / security-scan (push) Has been cancelled
Test Suite / test-summary (push) Has been cancelled
fix: move test artifacts to tmp directory and update gitignore
- Create tmp/test_artifacts/ directory for test storage
- Add tmp/ to .gitignore to exclude test artifacts from version control
- Update test files to use project tmp directory instead of system temp
- Add test-specific path constants for consistent configuration
- Prevent asset_registry.json from being overwritten by tests

🤖 Generated with [Claude Code](https://claude.ai/code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-10-19 21:39:40 +02:00

60 lines
1.5 KiB
Python

"""
Configuration constants and defaults for the markitect assets module.
This module defines default values, file extensions, and other constants
used throughout the asset management system.
"""
# Default paths and filenames
DEFAULT_ASSETS_DIR = "assets"
DEFAULT_REGISTRY_FILENAME = "asset_registry.json"
DEFAULT_MANIFEST_FILENAME = "manifest.json"
# Test-specific paths (for development/testing)
DEFAULT_TEST_ASSETS_DIR = "tmp/test_artifacts/assets"
DEFAULT_TEST_REGISTRY_FILENAME = "tmp/test_artifacts/asset_registry.json"
# Package file extension
PACKAGE_EXTENSION = ".mdpkg"
# Default configuration values
DEFAULT_CONFIG = {
"enable_deduplication": True,
"default_conflict_resolution": "backup",
"max_file_size": 100 * 1024 * 1024, # 100MB
"performance_timeout_ms": 100,
"memory_limit_mb": 50
}
# File patterns to exclude from packages by default
DEFAULT_EXCLUDE_PATTERNS = [
".DS_Store",
"Thumbs.db",
"*.tmp",
"*.temp",
"*.swp",
"*.bak",
"__pycache__",
".git",
".svn",
".hg"
]
# Supported manifest format version
MANIFEST_FORMAT_VERSION = "1.0"
# Hash algorithm used for content addressing
HASH_ALGORITHM = "sha256"
# Symlink conflict resolution options
CONFLICT_RESOLUTION_OPTIONS = ["overwrite", "backup", "skip"]
# MIME type detection fallbacks
FALLBACK_MIME_TYPES = {
".md": "text/markdown",
".txt": "text/plain",
".json": "application/json",
".yaml": "application/x-yaml",
".yml": "application/x-yaml"
}