Skip to content

Commit 946f2f3

Browse files
committed
dogfood: Add more dogfooding
1 parent 4f79790 commit 946f2f3

File tree

47 files changed

+1438
-79
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

47 files changed

+1438
-79
lines changed

dogfood_output/SUMMARY.md

Lines changed: 18 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,22 +1,30 @@
11
# Dogfooding Summary Report
22

3-
**Generated:** 2026-01-18T13:02:26.538240
3+
**Generated:** 2026-01-18T13:19:39.235112
44

55
## Overall Statistics
66

77
- **Total Iterations:** 10
8-
- **Successful:** 8 (80.0%)
9-
- **Failed:** 0 (0.0%)
10-
- **Skipped:** 2 (20.0%)
8+
- **Successful:** 2 (20.0%)
9+
- **Failed:** 7 (70.0%)
10+
- **Skipped:** 1 (10.0%)
1111

1212
## Issues by Type
1313

14-
- **skipped:** 2
14+
- **execution_failed:** 3
15+
- **output_mismatch:** 4
16+
- **skipped:** 1
17+
18+
## Recent Failures
19+
20+
- [execution_failed](/Users/anton/Documents/github/sharpy/dogfood_output/issues/20260118_131731_execution_failed_0000) - class_inheritance/medium - 12.9s
21+
- [output_mismatch](/Users/anton/Documents/github/sharpy/dogfood_output/issues/20260118_131748_output_mismatch_0001) - virtual_override/medium - 17.1s
22+
- [output_mismatch](/Users/anton/Documents/github/sharpy/dogfood_output/issues/20260118_131843_output_mismatch_0002) - function_calling_function/complex - 21.0s
23+
- [output_mismatch](/Users/anton/Documents/github/sharpy/dogfood_output/issues/20260118_131859_output_mismatch_0003) - simple_function/simple - 16.1s
24+
- [execution_failed](/Users/anton/Documents/github/sharpy/dogfood_output/issues/20260118_131912_execution_failed_0004) - virtual_override/medium - 13.1s
25+
- [execution_failed](/Users/anton/Documents/github/sharpy/dogfood_output/issues/20260118_131923_execution_failed_0005) - enum_usage/simple - 10.6s
26+
- [output_mismatch](/Users/anton/Documents/github/sharpy/dogfood_output/issues/20260118_131939_output_mismatch_0006) - simple_function/simple - 15.7s
1527

1628
## Recent Skips
1729

18-
- break_continue/medium - Invalid expected output (Python says: 13
19-
999
20-
24
21-
16)
22-
- nested_if_in_loop/complex - Generated code invalid per spec
30+
- module_imports/complex - Unsupported feature in geometry.spy: Line 22: with statement (deferred) - 'return base + " with dimensions " + str(int(self.w...'
Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
# Issue Report: execution_failed
2+
3+
**Timestamp:** 2026-01-18T13:17:18.300150
4+
**Type:** execution_failed
5+
**Feature Focus:** class_inheritance
6+
**Complexity:** medium
7+
**Backend:** claude
8+
9+
## Generated Sharpy Code
10+
11+
```python
12+
# Test class inheritance with multiple levels and method overriding
13+
14+
@abstract
15+
class Shape:
16+
name: str
17+
18+
def __init__(self, name: str):
19+
self.name = name
20+
21+
@abstract
22+
def area(self) -> float:
23+
...
24+
25+
@virtual
26+
def describe(self) -> None:
27+
print(self.name)
28+
29+
class Rectangle(Shape):
30+
width: float
31+
height: float
32+
33+
def __init__(self, name: str, width: float, height: float):
34+
super().__init__(name)
35+
self.width = width
36+
self.height = height
37+
38+
@override
39+
def area(self) -> float:
40+
return self.width * self.height
41+
42+
class Square(Rectangle):
43+
def __init__(self, name: str, side: float):
44+
super().__init__(name, side, side)
45+
46+
@override
47+
def describe(self) -> None:
48+
super().describe()
49+
print(self.width)
50+
51+
rect = Rectangle("MyRectangle", 5.0, 3.0)
52+
rect.describe()
53+
print(rect.area())
54+
55+
square = Square("MySquare", 4.0)
56+
square.describe()
57+
print(square.area())
58+
59+
# EXPECTED OUTPUT:
60+
# MyRectangle
61+
# 15
62+
# MySquare
63+
# 4
64+
# 16
65+
```
66+
67+
## Error
68+
69+
```
70+
Compilation failed:
71+
Semantic error at line 37, column 9: Parent class 'Rectangle' has no method 'describe'
72+
73+
```
74+
75+
## Timing
76+
77+
- Generation: 4.68s
78+
- Execution: 1.16s
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Compilation failed:
2+
Semantic error at line 37, column 9: Parent class 'Rectangle' has no method 'describe'
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
MyRectangle
2+
15
3+
MySquare
4+
4
5+
16
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"issue_type": "execution_failed",
3+
"timestamp": "2026-01-18T13:17:18.300150",
4+
"generated_code": "# Test class inheritance with multiple levels and method overriding\n\n@abstract\nclass Shape:\n name: str\n\n def __init__(self, name: str):\n self.name = name\n\n @abstract\n def area(self) -> float:\n ...\n\n @virtual\n def describe(self) -> None:\n print(self.name)\n\nclass Rectangle(Shape):\n width: float\n height: float\n\n def __init__(self, name: str, width: float, height: float):\n super().__init__(name)\n self.width = width\n self.height = height\n\n @override\n def area(self) -> float:\n return self.width * self.height\n\nclass Square(Rectangle):\n def __init__(self, name: str, side: float):\n super().__init__(name, side, side)\n\n @override\n def describe(self) -> None:\n super().describe()\n print(self.width)\n\nrect = Rectangle(\"MyRectangle\", 5.0, 3.0)\nrect.describe()\nprint(rect.area())\n\nsquare = Square(\"MySquare\", 4.0)\nsquare.describe()\nprint(square.area())\n\n# EXPECTED OUTPUT:\n# MyRectangle\n# 15\n# MySquare\n# 4\n# 16",
5+
"expected_output": "MyRectangle\n15\nMySquare\n4\n16\n",
6+
"actual_output": null,
7+
"error_message": "Compilation failed:\n Semantic error at line 37, column 9: Parent class 'Rectangle' has no method 'describe'\n",
8+
"compiler_output": "",
9+
"generated_cs": null,
10+
"validation_result": "```\nVALID\nThe code uses only features from phases 0.1.0-0.1.10.\n```\n\n**Breakdown of features used:**\n\n\u2705 **Classes (0.1.6)**: `class Shape:`, `class Rectangle(Shape):`, `class Square(Rectangle):`\n\u2705 **Inheritance (0.1.7)**: Single inheritance chain `Shape \u2192 Rectangle \u2192 Square`\n\u2705 **Abstract classes/methods (0.1.7)**: `@abstract` decorator on class and `area()` method\n\u2705 **Virtual methods (0.1.7)**: `@virtual` on `describe()`\n\u2705 **Override methods (0.1.7)**: `@override` on `area()` and `describe()`\n\u2705 **Constructor (0.1.6)**: `def __init__(self, ...):` in all classes\n\u2705 **Super calls (0.1.7)**: `super().__init__(...)` and `super().describe()`\n\u2705 **Field declarations (0.1.6)**: `name: str`, `width: float`, `height: float`\n\u2705 **Field access (0.1.6)**: `self.name`, `self.width`, `self.height`\n\u2705 **Type annotations (0.1.3)**: `str`, `float`, `-> float`, `-> None`\n\u2705 **Return statement (0.1.5)**: `return self.width * self.height`\n\u2705 **Built-in print (single argument)**: `print(self.name)`, `print(self.width)`, `print(rect.area())`, `print(square.area())`\n\u2705 **Operators (0.1.3)**: `*` for multiplication\n\u2705 **Variable declaration (0.1.3)**: `rect = ...`, `square = ...`\n\u2705 **Literals (0.1.3)**: String literals `\"MyRectangle\"`, float literals `5.0`, `3.0`, `4.0`\n\nAll features are compliant with phases 0.1.0-0.1.10.\n",
11+
"feature_focus": "class_inheritance",
12+
"complexity": "medium",
13+
"backend_used": "claude",
14+
"generation_duration": 4.678782939910889,
15+
"compilation_duration": null,
16+
"execution_duration": 1.1586449146270752,
17+
"source_files": null
18+
}
Lines changed: 53 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,53 @@
1+
# Test class inheritance with multiple levels and method overriding
2+
3+
@abstract
4+
class Shape:
5+
name: str
6+
7+
def __init__(self, name: str):
8+
self.name = name
9+
10+
@abstract
11+
def area(self) -> float:
12+
...
13+
14+
@virtual
15+
def describe(self) -> None:
16+
print(self.name)
17+
18+
class Rectangle(Shape):
19+
width: float
20+
height: float
21+
22+
def __init__(self, name: str, width: float, height: float):
23+
super().__init__(name)
24+
self.width = width
25+
self.height = height
26+
27+
@override
28+
def area(self) -> float:
29+
return self.width * self.height
30+
31+
class Square(Rectangle):
32+
def __init__(self, name: str, side: float):
33+
super().__init__(name, side, side)
34+
35+
@override
36+
def describe(self) -> None:
37+
super().describe()
38+
print(self.width)
39+
40+
rect = Rectangle("MyRectangle", 5.0, 3.0)
41+
rect.describe()
42+
print(rect.area())
43+
44+
square = Square("MySquare", 4.0)
45+
square.describe()
46+
print(square.area())
47+
48+
# EXPECTED OUTPUT:
49+
# MyRectangle
50+
# 15
51+
# MySquare
52+
# 4
53+
# 16
Lines changed: 111 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,111 @@
1+
# Issue Report: output_mismatch
2+
3+
**Timestamp:** 2026-01-18T13:17:31.225175
4+
**Type:** output_mismatch
5+
**Feature Focus:** virtual_override
6+
**Complexity:** medium
7+
**Backend:** claude
8+
9+
## Generated Sharpy Code
10+
11+
```python
12+
# Test virtual and override methods with a simple shape hierarchy
13+
14+
@abstract
15+
class Shape:
16+
name: str
17+
18+
def __init__(self, name: str):
19+
self.name = name
20+
21+
@virtual
22+
def area(self) -> float:
23+
return 0.0
24+
25+
@virtual
26+
def perimeter(self) -> float:
27+
return 0.0
28+
29+
def describe(self) -> None:
30+
print(self.name)
31+
print(self.area())
32+
print(self.perimeter())
33+
34+
class Rectangle(Shape):
35+
width: float
36+
height: float
37+
38+
def __init__(self, width: float, height: float):
39+
super().__init__("Rectangle")
40+
self.width = width
41+
self.height = height
42+
43+
@override
44+
def area(self) -> float:
45+
return self.width * self.height
46+
47+
@override
48+
def perimeter(self) -> float:
49+
return 2.0 * (self.width + self.height)
50+
51+
class Circle(Shape):
52+
radius: float
53+
54+
def __init__(self, radius: float):
55+
super().__init__("Circle")
56+
self.radius = radius
57+
58+
@override
59+
def area(self) -> float:
60+
return 3.14 * self.radius * self.radius
61+
62+
@override
63+
def perimeter(self) -> float:
64+
return 2.0 * 3.14 * self.radius
65+
66+
rect: Rectangle = Rectangle(5.0, 3.0)
67+
rect.describe()
68+
69+
circ: Circle = Circle(4.0)
70+
circ.describe()
71+
72+
# EXPECTED OUTPUT:
73+
# Rectangle
74+
# 15.0
75+
# 16.0
76+
# Circle
77+
# 50.24
78+
# 25.12
79+
```
80+
81+
## Output Comparison
82+
83+
### Expected
84+
```
85+
Rectangle
86+
15.0
87+
16.0
88+
Circle
89+
50.24
90+
25.12
91+
92+
```
93+
94+
### Actual
95+
```
96+
Successfully compiled to: /var/folders/6r/tsfytt4x6s1cl4_t14c961040000gn/T/dogfood_test_23f0dbc765dd4156bf5a05a80d70d30d.exe
97+
98+
=== Running Program ===
99+
100+
Rectangle
101+
15
102+
16
103+
Circle
104+
50.24
105+
25.12
106+
```
107+
108+
## Timing
109+
110+
- Generation: 5.07s
111+
- Execution: 1.30s
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
Successfully compiled to: /var/folders/6r/tsfytt4x6s1cl4_t14c961040000gn/T/dogfood_test_23f0dbc765dd4156bf5a05a80d70d30d.exe
2+
3+
=== Running Program ===
4+
5+
Rectangle
6+
15
7+
16
8+
Circle
9+
50.24
10+
25.12
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
Rectangle
2+
15.0
3+
16.0
4+
Circle
5+
50.24
6+
25.12
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
{
2+
"issue_type": "output_mismatch",
3+
"timestamp": "2026-01-18T13:17:31.225175",
4+
"generated_code": "# Test virtual and override methods with a simple shape hierarchy\n\n@abstract\nclass Shape:\n name: str\n\n def __init__(self, name: str):\n self.name = name\n\n @virtual\n def area(self) -> float:\n return 0.0\n\n @virtual\n def perimeter(self) -> float:\n return 0.0\n\n def describe(self) -> None:\n print(self.name)\n print(self.area())\n print(self.perimeter())\n\nclass Rectangle(Shape):\n width: float\n height: float\n\n def __init__(self, width: float, height: float):\n super().__init__(\"Rectangle\")\n self.width = width\n self.height = height\n\n @override\n def area(self) -> float:\n return self.width * self.height\n\n @override\n def perimeter(self) -> float:\n return 2.0 * (self.width + self.height)\n\nclass Circle(Shape):\n radius: float\n\n def __init__(self, radius: float):\n super().__init__(\"Circle\")\n self.radius = radius\n\n @override\n def area(self) -> float:\n return 3.14 * self.radius * self.radius\n\n @override\n def perimeter(self) -> float:\n return 2.0 * 3.14 * self.radius\n\nrect: Rectangle = Rectangle(5.0, 3.0)\nrect.describe()\n\ncirc: Circle = Circle(4.0)\ncirc.describe()\n\n# EXPECTED OUTPUT:\n# Rectangle\n# 15.0\n# 16.0\n# Circle\n# 50.24\n# 25.12",
5+
"expected_output": "Rectangle\n15.0\n16.0\nCircle\n50.24\n25.12\n",
6+
"actual_output": "Successfully compiled to: /var/folders/6r/tsfytt4x6s1cl4_t14c961040000gn/T/dogfood_test_23f0dbc765dd4156bf5a05a80d70d30d.exe\n\n=== Running Program ===\n\nRectangle\n15\n16\nCircle\n50.24\n25.12",
7+
"error_message": null,
8+
"compiler_output": null,
9+
"generated_cs": null,
10+
"validation_result": "```\nVALID\nThe code uses only features from phases 0.1.0-0.1.10.\n```\n\n**Feature breakdown:**\n\n- **Classes (0.1.6)**: `Shape`, `Rectangle`, `Circle` with fields and methods\n- **Inheritance (0.1.7)**: `Rectangle(Shape)`, `Circle(Shape)`\n- **Abstract classes (0.1.7)**: `@abstract` decorator on `Shape`\n- **Virtual methods (0.1.7)**: `@virtual` on `area()` and `perimeter()`\n- **Override methods (0.1.7)**: `@override` on child class methods\n- **Constructor (0.1.6)**: `__init__` methods\n- **Super calls (0.1.7)**: `super().__init__(\"Rectangle\")`, `super().__init__(\"Circle\")`\n- **Instance methods (0.1.6)**: `describe()`, `area()`, `perimeter()`\n- **Fields (0.1.6)**: `name`, `width`, `height`, `radius`\n- **Primitive types (0.1.3)**: `str`, `float`, `None` (void return)\n- **Variables (0.1.3)**: `rect: Rectangle = Rectangle(5.0, 3.0)`\n- **Built-ins**: `print()` with single arguments\n- **Literals**: String literals (`\"Rectangle\"`, `\"Circle\"`), float literals (`5.0`, `3.0`, `3.14`, etc.)\n- **Operators (0.1.3)**: `*`, `+`, arithmetic operations\n- **Return statements (0.1.5)**: `return` with values\n\nAll features are within the allowed phases 0.1.0-0.1.10.\n",
11+
"feature_focus": "virtual_override",
12+
"complexity": "medium",
13+
"backend_used": "claude",
14+
"generation_duration": 5.067548036575317,
15+
"compilation_duration": null,
16+
"execution_duration": 1.3034591674804688,
17+
"source_files": null
18+
}

0 commit comments

Comments
 (0)