exonware-xwlazy 0.1.0.19__tar.gz → 0.1.0.21__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (90) hide show
  1. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/PKG-INFO +4 -2
  2. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/README.md +3 -1
  3. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/__init__.py +6 -2
  4. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/__init__.py +0 -1
  5. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/__init__.py +1 -1
  6. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/base.py +1 -3
  7. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/cache.py +1 -3
  8. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/logger.py +1 -12
  9. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/services/dependency_mapper.py +0 -2
  10. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/services/install_async_utils.py +1 -5
  11. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/services/install_cache_utils.py +1 -13
  12. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/services/keyword_detection.py +0 -9
  13. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/services/spec_cache.py +1 -9
  14. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/services/state_manager.py +0 -2
  15. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/strategies/__init__.py +1 -1
  16. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/strategies/caching_dict.py +1 -2
  17. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/strategies/caching_installation.py +1 -2
  18. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/strategies/caching_lfu.py +1 -2
  19. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/strategies/caching_lru.py +1 -2
  20. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/strategies/caching_multitier.py +1 -2
  21. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/strategies/caching_ttl.py +1 -2
  22. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/config.py +1 -3
  23. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/contracts.py +1 -15
  24. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/defs.py +0 -19
  25. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/errors.py +1 -9
  26. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/facade.py +1 -59
  27. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/module/base.py +1 -5
  28. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/module/data.py +1 -1
  29. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/module/facade.py +0 -1
  30. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/module/importer_engine.py +1 -45
  31. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/module/strategies/__init__.py +1 -1
  32. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/module/strategies/module_helper_lazy.py +1 -2
  33. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/module/strategies/module_helper_simple.py +1 -2
  34. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/module/strategies/module_manager_advanced.py +1 -2
  35. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/module/strategies/module_manager_simple.py +1 -2
  36. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/base.py +1 -10
  37. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/conf.py +1 -8
  38. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/data.py +1 -1
  39. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/facade.py +0 -1
  40. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/async_install_handle.py +1 -3
  41. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/config_manager.py +0 -1
  42. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/discovery.py +1 -5
  43. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/host_packages.py +0 -4
  44. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/install_async.py +1 -2
  45. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/install_cache.py +1 -2
  46. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/install_interactive.py +1 -2
  47. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/install_policy.py +1 -3
  48. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/install_registry.py +1 -3
  49. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/install_result.py +1 -1
  50. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/install_sbom.py +1 -2
  51. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/install_utils.py +1 -5
  52. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/installer_engine.py +1 -3
  53. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/lazy_installer.py +1 -3
  54. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/manifest.py +0 -10
  55. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/strategy_registry.py +1 -3
  56. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_discovery_file.py +1 -2
  57. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_discovery_hybrid.py +1 -2
  58. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_discovery_manifest.py +1 -2
  59. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_execution_async.py +1 -2
  60. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_execution_cached.py +1 -2
  61. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_execution_pip.py +1 -2
  62. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_execution_wheel.py +1 -2
  63. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_mapping_discovery_first.py +1 -2
  64. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_mapping_hybrid.py +1 -2
  65. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_mapping_manifest_first.py +1 -2
  66. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_policy_allow_list.py +1 -2
  67. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_policy_deny_list.py +1 -2
  68. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_policy_permissive.py +1 -2
  69. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_timing_clean.py +1 -2
  70. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_timing_full.py +1 -2
  71. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_timing_smart.py +1 -2
  72. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/package_timing_temporary.py +1 -2
  73. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/runtime/adaptive_learner.py +1 -3
  74. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/runtime/base.py +1 -3
  75. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/runtime/facade.py +0 -1
  76. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/runtime/intelligent_selector.py +1 -4
  77. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/runtime/metrics.py +0 -4
  78. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/runtime/performance.py +0 -2
  79. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/version.py +2 -2
  80. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/xwlazy.py +0 -1
  81. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/xwlazy_wrapper.py +0 -1
  82. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/.gitignore +0 -0
  83. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/LICENSE +0 -0
  84. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/pyproject.toml +0 -0
  85. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/common/services/__init__.py +0 -0
  86. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/module/__init__.py +0 -0
  87. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/__init__.py +0 -0
  88. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/services/__init__.py +0 -0
  89. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/package/strategies/__init__.py +0 -0
  90. {exonware_xwlazy-0.1.0.19 → exonware_xwlazy-0.1.0.21}/src/exonware/xwlazy/runtime/__init__.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: exonware-xwlazy
3
- Version: 0.1.0.19
3
+ Version: 0.1.0.21
4
4
  Summary: Marker package that enables lazy install features across the eXonware suite.
5
5
  Project-URL: Homepage, https://exonware.com
6
6
  Project-URL: Repository, https://github.com/exonware/xwlazy
@@ -452,5 +452,7 @@ xwlazy is built with inspiration from the Python lazy import ecosystem, particul
452
452
 
453
453
  **Part of the eXonware ecosystem** - Enterprise-grade Python libraries for modern software development.
454
454
 
455
- *Version: 0.1.0.12 | Last Updated: 17-Nov-2025*
455
+ *Last Updated: 17-Nov-2025*
456
+
457
+ > **Note:** For the current version, use `from exonware.xwlazy import __version__` or `import exonware.xwlazy; print(exonware.xwlazy.__version__)`
456
458
 
@@ -425,5 +425,7 @@ xwlazy is built with inspiration from the Python lazy import ecosystem, particul
425
425
 
426
426
  **Part of the eXonware ecosystem** - Enterprise-grade Python libraries for modern software development.
427
427
 
428
- *Version: 0.1.0.12 | Last Updated: 17-Nov-2025*
428
+ *Last Updated: 17-Nov-2025*
429
+
430
+ > **Note:** For the current version, use `from exonware.xwlazy import __version__` or `import exonware.xwlazy; print(exonware.xwlazy.__version__)`
429
431
 
@@ -4,7 +4,6 @@ exonware package - Enterprise-grade Python framework ecosystem
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
8
7
  Generation Date: 2025-01-03
9
8
 
10
9
  This is a namespace package allowing multiple exonware subpackages
@@ -15,7 +14,12 @@ to coexist (xwsystem, xwnode, xwdata, xwlazy, etc.)
15
14
  # This allows both exonware.xwsystem and exonware.xwlazy to coexist
16
15
  __path__ = __import__('pkgutil').extend_path(__path__, __name__)
17
16
 
18
- __version__ = '0.0.1'
17
+ # Import version from xwlazy if available, otherwise use default
18
+ try:
19
+ from exonware.xwlazy.version import __version__
20
+ except ImportError:
21
+ __version__ = '0.0.1' # Fallback for namespace package when xwlazy not installed
22
+
19
23
  __author__ = 'Eng. Muhammad AlShehri'
20
24
  __email__ = 'connect@exonware.com'
21
25
  __company__ = 'eXonware.com'
@@ -10,7 +10,6 @@ installed only when needed.
10
10
  Company: eXonware.com
11
11
  Author: Eng. Muhammad AlShehri
12
12
  Email: connect@exonware.com
13
- Version: 0.1.0.19
14
13
  Generation Date: 10-Oct-2025
15
14
 
16
15
  Main Features:
@@ -6,7 +6,7 @@ Common utilities shared across package, module, and runtime.
6
6
  Company: eXonware.com
7
7
  Author: Eng. Muhammad AlShehri
8
8
  Email: connect@exonware.com
9
- Version: 0.1.0.19
9
+
10
10
  Generation Date: 15-Nov-2025
11
11
  """
12
12
 
@@ -4,7 +4,7 @@ Common Abstract Base Classes
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 15-Nov-2025
9
9
 
10
10
  Abstract base classes for shared/common strategies.
@@ -14,7 +14,6 @@ from abc import ABC, abstractmethod
14
14
  from typing import Optional, Any
15
15
  from ..contracts import ICachingStrategy
16
16
 
17
-
18
17
  # =============================================================================
19
18
  # ABSTRACT CACHING STRATEGY
20
19
  # =============================================================================
@@ -47,7 +46,6 @@ class ACachingStrategy(ICachingStrategy, ABC):
47
46
  """Clear all cached values."""
48
47
  ...
49
48
 
50
-
51
49
  # =============================================================================
52
50
  # EXPORT ALL
53
51
  # =============================================================================
@@ -6,7 +6,7 @@ Cache utilities for xwlazy - shared across package, module, and runtime.
6
6
  Company: eXonware.com
7
7
  Author: Eng. Muhammad AlShehri
8
8
  Email: connect@exonware.com
9
- Version: 0.1.0.19
9
+
10
10
  Generation Date: 15-Nov-2025
11
11
 
12
12
  This module provides unified caching functionality for all xwlazy components.
@@ -226,7 +226,6 @@ class MultiTierCache:
226
226
  except Exception as e:
227
227
  logger.debug(f"Failed to clear L2 cache: {e}")
228
228
 
229
-
230
229
  # =============================================================================
231
230
  # BYTECODE CACHE
232
231
  # =============================================================================
@@ -342,7 +341,6 @@ class BytecodeCache:
342
341
  except Exception as e:
343
342
  logger.debug(f"Failed to clear bytecode cache: {e}")
344
343
 
345
-
346
344
  # =============================================================================
347
345
  # INSTALLATION CACHE
348
346
  # =============================================================================
@@ -6,7 +6,7 @@ Logging utilities for xwlazy - shared across package, module, and runtime.
6
6
  Company: eXonware.com
7
7
  Author: Eng. Muhammad AlShehri
8
8
  Email: connect@exonware.com
9
- Version: 0.1.0.19
9
+
10
10
  Generation Date: 15-Nov-2025
11
11
 
12
12
  This module provides unified logging functionality for all xwlazy components.
@@ -62,7 +62,6 @@ def _normalize_category(name: str) -> str:
62
62
  """Normalize category name to lowercase."""
63
63
  return name.strip().lower()
64
64
 
65
-
66
65
  def _load_env_overrides() -> None:
67
66
  """Load log category overrides from environment variables."""
68
67
  for category in _CATEGORY_DEFAULTS:
@@ -73,7 +72,6 @@ def _load_env_overrides() -> None:
73
72
  enabled = env_val.strip().lower() not in {"0", "false", "off", "no"}
74
73
  _category_overrides[_normalize_category(category)] = enabled
75
74
 
76
-
77
75
  # =============================================================================
78
76
  # FORMATTER
79
77
  # =============================================================================
@@ -97,7 +95,6 @@ class XWLazyFormatter(logging.Formatter):
97
95
  message = record.getMessage()
98
96
  return f"{emoji} exonware.xwlazy [{time_str}]: [{flag}] {message}"
99
97
 
100
-
101
98
  # =============================================================================
102
99
  # CONFIGURATION
103
100
  # =============================================================================
@@ -146,7 +143,6 @@ def _ensure_basic_config() -> None:
146
143
 
147
144
  _configured = True
148
145
 
149
-
150
146
  # =============================================================================
151
147
  # PUBLIC API
152
148
  # =============================================================================
@@ -164,7 +160,6 @@ def get_logger(name: Optional[str] = None) -> logging.Logger:
164
160
  _ensure_basic_config()
165
161
  return logging.getLogger(name or "xwlazy.lazy")
166
162
 
167
-
168
163
  def is_log_category_enabled(category: str) -> bool:
169
164
  """
170
165
  Return True if the provided log category is enabled.
@@ -181,7 +176,6 @@ def is_log_category_enabled(category: str) -> bool:
181
176
  return _category_overrides[normalized]
182
177
  return _CATEGORY_DEFAULTS.get(normalized, True)
183
178
 
184
-
185
179
  def set_log_category(category: str, enabled: bool) -> None:
186
180
  """
187
181
  Enable/disable an individual log category at runtime.
@@ -192,7 +186,6 @@ def set_log_category(category: str, enabled: bool) -> None:
192
186
  """
193
187
  _category_overrides[_normalize_category(category)] = bool(enabled)
194
188
 
195
-
196
189
  def set_log_categories(overrides: Dict[str, bool]) -> None:
197
190
  """
198
191
  Bulk update multiple log categories.
@@ -203,7 +196,6 @@ def set_log_categories(overrides: Dict[str, bool]) -> None:
203
196
  for category, enabled in overrides.items():
204
197
  set_log_category(category, enabled)
205
198
 
206
-
207
199
  def get_log_categories() -> Dict[str, bool]:
208
200
  """
209
201
  Return the effective state for each built-in log category.
@@ -218,7 +210,6 @@ def get_log_categories() -> Dict[str, bool]:
218
210
  result[category] = _category_overrides.get(normalized, default_enabled)
219
211
  return result
220
212
 
221
-
222
213
  def log_event(category: str, level_fn, msg: str, *args, **kwargs) -> None:
223
214
  """
224
215
  Emit a log for the given category if it is enabled.
@@ -233,7 +224,6 @@ def log_event(category: str, level_fn, msg: str, *args, **kwargs) -> None:
233
224
  if is_log_category_enabled(category):
234
225
  level_fn(msg, *args, **kwargs)
235
226
 
236
-
237
227
  def format_message(flag: str, message: str) -> str:
238
228
  """
239
229
  Format a message with exonware.xwlazy [HH:MM:SS]: [FLAG] format.
@@ -249,7 +239,6 @@ def format_message(flag: str, message: str) -> str:
249
239
  time_str = datetime.now().strftime("%H:%M:%S")
250
240
  return f"{emoji} exonware.xwlazy [{time_str}]: [{flag}] {message}"
251
241
 
252
-
253
242
  def print_formatted(flag: str, message: str, same_line: bool = False) -> None:
254
243
  """
255
244
  Print a formatted message with optional same-line support.
@@ -37,7 +37,6 @@ def get_lazy_discovery():
37
37
  from ...package.services.discovery import get_lazy_discovery as _get_lazy_discovery
38
38
  return _get_lazy_discovery()
39
39
 
40
-
41
40
  class DependencyMapper:
42
41
  """
43
42
  Maps import names to package names using dynamic discovery.
@@ -229,6 +228,5 @@ class DependencyMapper:
229
228
  self._ensure_mappings_cached()
230
229
  return self._import_package_mapping.copy()
231
230
 
232
-
233
231
  __all__ = ['DependencyMapper']
234
232
 
@@ -4,7 +4,7 @@ Installation Async Utilities
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 15-Nov-2025
9
9
 
10
10
  Shared utilities for async installation operations.
@@ -32,7 +32,6 @@ def _ensure_logging_initialized():
32
32
  if logger is None:
33
33
  logger = _get_logger()
34
34
 
35
-
36
35
  async def get_package_size_mb(package_name: str) -> Optional[float]:
37
36
  """
38
37
  Get package size in MB by checking pip show or download size.
@@ -84,7 +83,6 @@ async def get_package_size_mb(package_name: str) -> Optional[float]:
84
83
 
85
84
  return None
86
85
 
87
-
88
86
  async def async_install_package(
89
87
  package_name: str,
90
88
  policy_args: Optional[list] = None
@@ -124,7 +122,6 @@ async def async_install_package(
124
122
  logger.error(f"Error in async install of {package_name}: {e}")
125
123
  return False, str(e)
126
124
 
127
-
128
125
  async def async_uninstall_package(
129
126
  package_name: str,
130
127
  quiet: bool = True
@@ -160,7 +157,6 @@ async def async_uninstall_package(
160
157
  logger.debug(f"Failed to uninstall {package_name}: {e}")
161
158
  return False
162
159
 
163
-
164
160
  __all__ = [
165
161
  'get_package_size_mb',
166
162
  'async_install_package',
@@ -4,7 +4,7 @@ Installation Cache Utilities
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 15-Nov-2025
9
9
 
10
10
  Shared utilities for cache management (wheels, install trees).
@@ -44,12 +44,10 @@ def _ensure_logging_initialized():
44
44
  if logger is None:
45
45
  logger = _get_logger()
46
46
 
47
-
48
47
  def get_default_cache_dir() -> Path:
49
48
  """Get the default cache directory."""
50
49
  return _DEFAULT_ASYNC_CACHE_DIR
51
50
 
52
-
53
51
  def get_cache_dir(cache_dir: Optional[Path] = None) -> Path:
54
52
  """Get cache directory, creating it if necessary."""
55
53
  if cache_dir is None:
@@ -58,21 +56,18 @@ def get_cache_dir(cache_dir: Optional[Path] = None) -> Path:
58
56
  path.mkdir(parents=True, exist_ok=True)
59
57
  return path
60
58
 
61
-
62
59
  def get_wheel_path(package_name: str, cache_dir: Optional[Path] = None) -> Path:
63
60
  """Get the cached wheel file path for a package."""
64
61
  cache = get_cache_dir(cache_dir)
65
62
  safe = package_name.replace("/", "_").replace("\\", "_").replace(":", "_")
66
63
  return cache / f"{safe}.whl"
67
64
 
68
-
69
65
  def get_install_tree_dir(package_name: str, cache_dir: Optional[Path] = None) -> Path:
70
66
  """Get the cached install directory for a package."""
71
67
  cache = get_cache_dir(cache_dir)
72
68
  safe = package_name.replace("/", "_").replace("\\", "_").replace(":", "_")
73
69
  return cache / "installs" / safe
74
70
 
75
-
76
71
  def get_site_packages_dir() -> Path:
77
72
  """Get the site-packages directory."""
78
73
  purelib = sysconfig.get_paths().get("purelib")
@@ -82,7 +77,6 @@ def get_site_packages_dir() -> Path:
82
77
  path.mkdir(parents=True, exist_ok=True)
83
78
  return path
84
79
 
85
-
86
80
  def pip_install_from_path(wheel_path: Path, policy_args: Optional[List[str]] = None) -> bool:
87
81
  """Install a wheel file using pip."""
88
82
  try:
@@ -108,7 +102,6 @@ def pip_install_from_path(wheel_path: Path, policy_args: Optional[List[str]] = N
108
102
  except subprocess.CalledProcessError:
109
103
  return False
110
104
 
111
-
112
105
  def ensure_cached_wheel(
113
106
  package_name: str,
114
107
  policy_args: Optional[List[str]] = None,
@@ -155,7 +148,6 @@ def ensure_cached_wheel(
155
148
  except subprocess.CalledProcessError:
156
149
  return None
157
150
 
158
-
159
151
  def install_from_cached_tree(
160
152
  package_name: str,
161
153
  cache_dir: Optional[Path] = None
@@ -185,7 +177,6 @@ def install_from_cached_tree(
185
177
  logger.debug("Cached tree install failed for %s: %s", package_name, exc)
186
178
  return False
187
179
 
188
-
189
180
  def materialize_cached_tree(
190
181
  package_name: str,
191
182
  wheel_path: Path,
@@ -219,7 +210,6 @@ def materialize_cached_tree(
219
210
  if temp_dir.exists():
220
211
  shutil.rmtree(temp_dir, ignore_errors=True)
221
212
 
222
-
223
213
  def has_cached_install_tree(
224
214
  package_name: str,
225
215
  cache_dir: Optional[Path] = None
@@ -228,7 +218,6 @@ def has_cached_install_tree(
228
218
  target = get_install_tree_dir(package_name, cache_dir)
229
219
  return target.exists() and any(target.iterdir())
230
220
 
231
-
232
221
  def install_from_cached_wheel(
233
222
  package_name: str,
234
223
  policy_args: Optional[List[str]] = None,
@@ -240,7 +229,6 @@ def install_from_cached_wheel(
240
229
  return False
241
230
  return pip_install_from_path(wheel_path, policy_args)
242
231
 
243
-
244
232
  __all__ = [
245
233
  'get_default_cache_dir',
246
234
  'get_cache_dir',
@@ -23,7 +23,6 @@ _keyword_config_lock = threading.RLock()
23
23
  _lazy_detection_cache: dict[str, bool] = {}
24
24
  _lazy_detection_lock = threading.RLock()
25
25
 
26
-
27
26
  def _check_package_keywords(package_name: Optional[str] = None, keyword: Optional[str] = None) -> bool:
28
27
  """
29
28
  Check if any installed package has the specified keyword in its metadata.
@@ -102,7 +101,6 @@ def _check_package_keywords(package_name: Optional[str] = None, keyword: Optiona
102
101
 
103
102
  return False
104
103
 
105
-
106
104
  def _lazy_marker_installed() -> bool:
107
105
  """Check if the exonware-xwlazy marker package is installed."""
108
106
  if sys.version_info < (3, 8):
@@ -122,7 +120,6 @@ def _lazy_marker_installed() -> bool:
122
120
  logger.debug("❌ exonware-xwlazy marker package not installed")
123
121
  return False
124
122
 
125
-
126
123
  def _lazy_env_override(package_name: str) -> Optional[bool]:
127
124
  """Check environment variable override for lazy installation."""
128
125
  env_var = f"{package_name.upper()}_LAZY_INSTALL"
@@ -137,7 +134,6 @@ def _lazy_env_override(package_name: str) -> Optional[bool]:
137
134
  return False
138
135
  return None
139
136
 
140
-
141
137
  def _detect_meta_info_mode(package_name: str) -> Optional[str]:
142
138
  """
143
139
  Detect lazy mode from package metadata keywords.
@@ -178,7 +174,6 @@ def _detect_meta_info_mode(package_name: str) -> Optional[str]:
178
174
  pass
179
175
  return None
180
176
 
181
-
182
177
  def enable_keyword_detection(enabled: bool = True, keyword: Optional[str] = None) -> None:
183
178
  """
184
179
  Enable/disable keyword-based auto-detection of lazy loading.
@@ -203,19 +198,16 @@ def enable_keyword_detection(enabled: bool = True, keyword: Optional[str] = None
203
198
  with _lazy_detection_lock:
204
199
  _lazy_detection_cache.clear()
205
200
 
206
-
207
201
  def is_keyword_detection_enabled() -> bool:
208
202
  """Return whether keyword-based detection is enabled."""
209
203
  with _keyword_config_lock:
210
204
  return _KEYWORD_DETECTION_ENABLED
211
205
 
212
-
213
206
  def get_keyword_detection_keyword() -> str:
214
207
  """Get the keyword currently being checked for auto-detection."""
215
208
  with _keyword_config_lock:
216
209
  return _KEYWORD_TO_CHECK
217
210
 
218
-
219
211
  def check_package_keywords(package_name: Optional[str] = None, keyword: Optional[str] = None) -> bool:
220
212
  """
221
213
  Check if a package (or any package) has the specified keyword in its metadata.
@@ -231,7 +223,6 @@ def check_package_keywords(package_name: Optional[str] = None, keyword: Optional
231
223
  """
232
224
  return _check_package_keywords(package_name, keyword)
233
225
 
234
-
235
226
  def _detect_lazy_installation(package_name: str) -> bool:
236
227
  """
237
228
  Detect if lazy installation should be enabled for a package.
@@ -6,7 +6,7 @@ Spec cache utilities for module specification caching.
6
6
  Company: eXonware.com
7
7
  Author: Eng. Muhammad AlShehri
8
8
  Email: connect@exonware.com
9
- Version: 0.1.0.19
9
+
10
10
  Generation Date: 10-Oct-2025
11
11
 
12
12
  This module provides multi-level caching (L1: memory, L2: disk) for module specs
@@ -49,7 +49,6 @@ except AttributeError:
49
49
  _STDLIB_MODULE_SET = set()
50
50
  _STDLIB_MODULE_SET.update(sys.builtin_module_names)
51
51
 
52
-
53
52
  @lru_cache(maxsize=1024)
54
53
  def _cached_stdlib_check(module_name: str) -> bool:
55
54
  """Check if module is part of stdlib or built-in modules."""
@@ -68,7 +67,6 @@ def _cached_stdlib_check(module_name: str) -> bool:
68
67
  except Exception:
69
68
  return False
70
69
 
71
-
72
70
  def _spec_cache_prune_locked(now: Optional[float] = None) -> None:
73
71
  """Prune expired entries from spec cache (must be called with lock held)."""
74
72
  if not _spec_cache:
@@ -80,7 +78,6 @@ def _spec_cache_prune_locked(now: Optional[float] = None) -> None:
80
78
  break
81
79
  _spec_cache.popitem(last=False)
82
80
 
83
-
84
81
  def _spec_cache_get(fullname: str) -> Optional[importlib.machinery.ModuleSpec]:
85
82
  """Get spec from multi-level cache (L1: memory, L2: disk)."""
86
83
  with _spec_cache_lock:
@@ -113,7 +110,6 @@ def _spec_cache_get(fullname: str) -> Optional[importlib.machinery.ModuleSpec]:
113
110
 
114
111
  return None
115
112
 
116
-
117
113
  def _spec_cache_put(fullname: str, spec: Optional[importlib.machinery.ModuleSpec]) -> None:
118
114
  """Put spec in multi-level cache (L1: memory, L2: disk)."""
119
115
  if spec is None:
@@ -134,7 +130,6 @@ def _spec_cache_put(fullname: str, spec: Optional[importlib.machinery.ModuleSpec
134
130
  except Exception:
135
131
  pass # Fail silently for disk cache
136
132
 
137
-
138
133
  def _spec_cache_clear(fullname: Optional[str] = None) -> None:
139
134
  """Clear spec cache entries."""
140
135
  with _spec_cache_lock:
@@ -143,7 +138,6 @@ def _spec_cache_clear(fullname: Optional[str] = None) -> None:
143
138
  else:
144
139
  _spec_cache.pop(fullname, None)
145
140
 
146
-
147
141
  def _cache_spec_if_missing(fullname: str) -> None:
148
142
  """Ensure a ModuleSpec is cached for a known-good module."""
149
143
  if _spec_cache_get(fullname):
@@ -155,12 +149,10 @@ def _cache_spec_if_missing(fullname: str) -> None:
155
149
  if spec is not None:
156
150
  _spec_cache_put(fullname, spec)
157
151
 
158
-
159
152
  def get_stdlib_module_set() -> set[str]:
160
153
  """Get the set of stdlib module names."""
161
154
  return _STDLIB_MODULE_SET.copy()
162
155
 
163
-
164
156
  __all__ = [
165
157
  '_cached_stdlib_check',
166
158
  '_spec_cache_get',
@@ -5,7 +5,6 @@ import os
5
5
  from pathlib import Path
6
6
  from typing import Dict, Optional
7
7
 
8
-
9
8
  def _get_base_config_dir() -> Path:
10
9
  """Determine a cross-platform directory for storing lazy configuration."""
11
10
  if os.name == "nt":
@@ -20,7 +19,6 @@ def _get_base_config_dir() -> Path:
20
19
  return Path(xdg_config) / "exonware" / "lazy"
21
20
  return Path.home() / ".config" / "exonware" / "lazy"
22
21
 
23
-
24
22
  class LazyStateManager:
25
23
  """Persist and retrieve lazy installation state."""
26
24
 
@@ -4,7 +4,7 @@ Common Caching Strategies - Shared by modules and packages.
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 15-Nov-2025
9
9
 
10
10
  Generic caching strategies that work with ANY data type.
@@ -4,7 +4,7 @@ Dict Cache Strategy - Simple dictionary-based caching.
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 15-Nov-2025
9
9
 
10
10
  Simple dict-based cache implementation.
@@ -14,7 +14,6 @@ Works with ANY data type (modules, packages, etc.).
14
14
  from typing import Dict, Optional, Any
15
15
  from ...common.base import ACachingStrategy
16
16
 
17
-
18
17
  class DictCache(ACachingStrategy):
19
18
  """
20
19
  Simple dictionary-based cache.
@@ -4,7 +4,7 @@ Installation Cache Strategy - Wrapper for existing InstallationCache.
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 15-Nov-2025
9
9
 
10
10
  Wraps existing InstallationCache to implement ICachingStrategy interface.
@@ -16,7 +16,6 @@ from ..cache import InstallationCache
16
16
  from ..base import ACachingStrategy
17
17
  from ...package.data import PackageData
18
18
 
19
-
20
19
  class InstallationCacheWrapper(ACachingStrategy):
21
20
  """
22
21
  Installation cache strategy wrapper.
@@ -4,7 +4,7 @@ LFU Cache Strategy - Least Frequently Used eviction.
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 15-Nov-2025
9
9
 
10
10
  LFU cache implementation with size limit.
@@ -15,7 +15,6 @@ from typing import Dict, Optional, Any
15
15
  from collections import Counter
16
16
  from ...common.base import ACachingStrategy
17
17
 
18
-
19
18
  class LFUCache(ACachingStrategy):
20
19
  """
21
20
  LFU (Least Frequently Used) cache with size limit.
@@ -4,7 +4,7 @@ LRU Cache Strategy - Least Recently Used eviction.
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 15-Nov-2025
9
9
 
10
10
  LRU cache implementation with size limit.
@@ -15,7 +15,6 @@ from typing import Optional, Any
15
15
  from collections import OrderedDict
16
16
  from ...common.base import ACachingStrategy
17
17
 
18
-
19
18
  class LRUCache(ACachingStrategy):
20
19
  """
21
20
  LRU (Least Recently Used) cache with size limit.
@@ -4,7 +4,7 @@ Multi-Tier Cache Strategy - Wrapper for existing MultiTierCache.
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 15-Nov-2025
9
9
 
10
10
  Wraps existing MultiTierCache to implement ICaching interface.
@@ -16,7 +16,6 @@ from pathlib import Path
16
16
  from ...common.cache import MultiTierCache
17
17
  from ...common.base import ACachingStrategy
18
18
 
19
-
20
19
  class MultiTierCacheStrategy(ACachingStrategy):
21
20
  """
22
21
  Multi-tier cache strategy (L1 memory + L2 disk + L3 predictive).
@@ -4,7 +4,7 @@ TTL Cache Strategy - Time-To-Live expiration.
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 15-Nov-2025
9
9
 
10
10
  TTL cache implementation with expiration.
@@ -15,7 +15,6 @@ import time
15
15
  from typing import Dict, Optional, Any, Tuple
16
16
  from ...common.base import ACachingStrategy
17
17
 
18
-
19
18
  class TTLCache(ACachingStrategy):
20
19
  """
21
20
  TTL (Time-To-Live) cache with expiration.
@@ -4,7 +4,7 @@
4
4
  Company: eXonware.com
5
5
  Author: Eng. Muhammad AlShehri
6
6
  Email: connect@exonware.com
7
- Version: 0.1.0.19
7
+
8
8
  Generation Date: 10-Oct-2025
9
9
 
10
10
  Configuration for Lazy Loading System
@@ -20,7 +20,6 @@ from typing import Optional, Any, Dict
20
20
  # Import LazyConfig dataclass from defs.py
21
21
  from .defs import LazyConfig as _LazyConfigBase
22
22
 
23
-
24
23
  # Extend LazyConfig with methods (dataclass is in defs.py)
25
24
  class LazyConfig(_LazyConfigBase):
26
25
  """Bridge configuration settings with the lazy package implementation."""
@@ -190,6 +189,5 @@ class LazyConfig(_LazyConfigBase):
190
189
  # Fail silently - hook installation failure shouldn't break package
191
190
  pass
192
191
 
193
-
194
192
  DEFAULT_LAZY_CONFIG = LazyConfig()
195
193