auto flake and corrections

This commit is contained in:
2025-11-08 23:46:15 +01:00
parent 1ea870eef5
commit 781a9b6c08
81 changed files with 4646 additions and 3718 deletions
+11 -11
View File
@@ -10,18 +10,18 @@ import json
def main():
"""Main function to fix coverage gutters configuration."""
print("=== Coverage Gutters Fix ===")
print(f"Current working directory: {os.getcwd()}")
# 1. Check if coverage.xml exists
if os.path.exists('coverage.xml'):
print("✓ coverage.xml exists")
# Check file size and basic content
size = os.path.getsize('coverage.xml')
print(f"✓ coverage.xml size: {size} bytes")
# Read first few lines to verify it's valid XML
try:
with open('coverage.xml', 'r') as f:
@@ -37,12 +37,12 @@ def main():
print("Running coverage to generate coverage.xml...")
os.system("python -m coverage run --source=pyWebLayout -m unittest tests.test_abstract_inline")
os.system("python -m coverage xml")
# 2. Check VSCode settings
vscode_settings_path = '.vscode/settings.json'
if os.path.exists(vscode_settings_path):
print("✓ VSCode settings.json exists")
with open(vscode_settings_path, 'r') as f:
try:
settings = json.load(f)
@@ -57,18 +57,18 @@ def main():
print(f"✗ Error parsing VSCode settings: {e}")
else:
print("✗ VSCode settings.json not found")
# 3. Check if inline.py file exists
inline_file = 'pyWebLayout/abstract/inline.py'
if os.path.exists(inline_file):
print(f"{inline_file} exists")
# Check file size
size = os.path.getsize(inline_file)
print(f"{inline_file} size: {size} bytes")
else:
print(f"{inline_file} does not exist")
# 4. Run a fresh coverage collection specifically for the inline module
print("\n=== Running Fresh Coverage ===")
try:
@@ -80,7 +80,7 @@ def main():
print("✓ Fresh coverage data generated")
except Exception as e:
print(f"✗ Error generating coverage: {e}")
# 5. Instructions for manual verification
print("\n=== Manual Verification Steps ===")
print("1. In VSCode, open the Command Palette (Ctrl+Shift+P)")
@@ -90,7 +90,7 @@ def main():
print(" - 'Coverage Gutters: Display Coverage' again")
print("4. Check that coverage.xml contains data for pyWebLayout/abstract/inline.py")
print("5. The file should show 100% coverage (all lines covered)")
print("\n=== Troubleshooting ===")
print("If coverage still doesn't show:")
print("1. Restart VSCode")