@voodocs/cli 1.0.0 β†’ 1.0.2

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.
package/CHANGELOG.md CHANGED
@@ -1,3 +1,208 @@
1
+ ## v1.0.2 (2024-12-21)
2
+
3
+ ### πŸ”§ Critical Bug Fixes
4
+
5
+ This patch release fixes critical issues that prevented @voodocs/cli from working out of the box in standard environments.
6
+
7
+ ---
8
+
9
+ ### Fixed
10
+
11
+ #### 1. CLI Entry Point (ModuleNotFoundError)
12
+ - **Fixed:** CLI entry point now correctly resolves symlinks for npm global installs
13
+ - **Before:** `voodocs` command failed with `ModuleNotFoundError: No module named 'cli'`
14
+ - **After:** Works correctly when installed globally via npm
15
+ - **Root Cause:** `Path(__file__).parent` didn't resolve symlinks created by npm in `.bin/`
16
+ - **Solution:** Added `.resolve()` to follow symlinks to actual package location
17
+
18
+ #### 2. Missing `init` Command
19
+ - **Fixed:** Implemented and registered the `voodocs init` command
20
+ - **Before:** Command referenced in documentation but didn't exist
21
+ - **After:** `voodocs init` creates `.voodocs.json` config and example files
22
+ - **Features:**
23
+ - Creates configuration file with sensible defaults
24
+ - Generates example annotated files (TypeScript and Python)
25
+ - Supports both `@voodocs` and `@darkarts` formats
26
+ - `--config-only` flag to skip example generation
27
+
28
+ #### 3. Annotation Parsing Failure for TypeScript
29
+ - **Fixed:** TypeScript parser now correctly identifies `/**@voodocs` and `/**@darkarts` blocks
30
+ - **Before:** Parser looked for `/*@voodocs` (single asterisk) and failed to find annotations
31
+ - **After:** Correctly matches JSDoc-style comments with `/**@voodocs` (double asterisk)
32
+ - **Impact:** All TypeScript/JavaScript annotations now parse correctly
33
+
34
+ #### 4. Inconsistent Terminology
35
+ - **Fixed:** Standardized support for both `@voodocs` and `@darkarts` tags
36
+ - **Before:** README used `@voodocs`, but CLI complained about missing `@darkarts`
37
+ - **After:** Both tags are supported and documented
38
+ - **Changes:**
39
+ - Parser accepts both `/**@voodocs` and `/**@darkarts`
40
+ - CLI help text clarifies support for both formats
41
+ - README updated with current v1.0.2 functionality
42
+ - Outdated commands removed from documentation
43
+
44
+ ---
45
+
46
+ ### Added
47
+
48
+ - **DarkArts Symbolic Format Guide:** New comprehensive guide at `docs/darkarts/DARKARTS_SYMBOLIC_GUIDE.md`
49
+ - **Symbol Quick Reference:** Complete reference for all symbolic annotations
50
+ - **Updated README:** Matches current v1.0.2 functionality with correct commands
51
+
52
+ ---
53
+
54
+ ### Improved
55
+
56
+ - **Better Error Messages:** More helpful error messages when annotations are missing
57
+ - **Documentation Accuracy:** All documentation now matches actual CLI functionality
58
+ - **CI/CD Example:** Added GitHub Actions workflow example for validation
59
+
60
+ ---
61
+
62
+ ### Testing
63
+
64
+ All fixes have been tested and verified:
65
+ - βœ… CLI entry point works with global npm install
66
+ - βœ… `voodocs init` creates config and examples
67
+ - βœ… TypeScript annotation parsing works correctly
68
+ - βœ… Both `@voodocs` and `@darkarts` tags are recognized
69
+
70
+ ---
71
+
72
+ ### Upgrade Notes
73
+
74
+ If you're upgrading from v1.0.1:
75
+
76
+ 1. **No breaking changes** - All existing annotations continue to work
77
+ 2. **New `init` command** - Use `voodocs init` to set up new projects
78
+ 3. **Better TypeScript support** - Annotations will now be detected correctly
79
+ 4. **Both formats supported** - Use either `@voodocs` or `@darkarts` tags
80
+
81
+ ---
82
+
83
+ ### Known Issues
84
+
85
+ None - all critical issues from v1.0.1 have been resolved.
86
+
87
+ ## v1.0.1 (2024-12-21)
88
+
89
+ ### πŸ”§ Bug Fixes: DarkArts Convert Command
90
+
91
+ This patch release fixes critical issues with the `voodocs darkarts convert` command that were preventing proper conversion of @voodocs annotations to @darkarts format.
92
+
93
+ ---
94
+
95
+ ### Fixed
96
+
97
+ #### 1. TypeScript/JavaScript Support
98
+ - **Fixed:** Convert command now properly handles TypeScript and JavaScript files
99
+ - **Before:** Only worked with Python files (`"""@voodocs`)
100
+ - **After:** Supports Python (`"""@voodocs`), TypeScript/JavaScript (`/**@voodocs`)
101
+ - **Impact:** Can now convert annotations in multi-language codebases
102
+
103
+ #### 2. Preserve ALL Annotation Fields
104
+ - **Fixed:** Now converts all annotation fields, not just module-level basics
105
+ - **Before:** Only converted 3 fields (module_purpose, dependencies, assumptions) - lost 95% of documentation
106
+ - **After:** Converts all fields:
107
+ - **Module-level:** module_purpose, dependencies, assumptions, invariants, security_model, performance_model (6 fields)
108
+ - **Function-level:** preconditions, postconditions, invariants, security_implications, complexity (5 fields)
109
+ - **Class-level:** invariants, assumptions (2 fields)
110
+ - **Impact:** No data loss during conversion
111
+
112
+ #### 3. Fixed Symbol Conversion (Word Boundaries)
113
+ - **Fixed:** Symbol conversion now uses word boundaries to prevent mid-word replacements
114
+ - **Before:** "authenticated" → "au⇒ticated", "verification" → "ver⇒ication"
115
+ - **After:** Only replaces whole words/phrases
116
+ - βœ… "authenticated" stays "authenticated"
117
+ - βœ… "exists" β†’ "βˆƒ" (whole word only)
118
+ - βœ… "or" β†’ "∨" (standalone only)
119
+ - βœ… "if and only if" β†’ "⇔"
120
+ - **Impact:** No text corruption during conversion
121
+
122
+ #### 4. Working --in-place Flag
123
+ - **Fixed:** --in-place flag now properly modifies files
124
+ - **Before:** Broken replacement logic, only worked for Python
125
+ - **After:** Works for Python, TypeScript, JavaScript with proper syntax preservation
126
+ - **Impact:** Can safely convert files in place without manual editing
127
+
128
+ ---
129
+
130
+ ### Additional Fixes
131
+
132
+ #### Syntax Errors
133
+ - Fixed 40+ files with unterminated string literals (`""""` β†’ `"""`)
134
+ - Files affected: types.py, exceptions.py, ai_detector.py, cli.py, and 36 more
135
+
136
+ #### Missing Imports
137
+ - Added missing `re` module import in cli_darkarts.py
138
+ - Added missing `Language` enum import
139
+
140
+ #### Complexity Serialization
141
+ - Fixed ComplexityAnnotation object serialization
142
+ - Now properly extracts time complexity string for output
143
+
144
+ ---
145
+
146
+ ### Technical Details
147
+
148
+ **Files Changed:** 45 files
149
+ **Commit:** 626bedb
150
+ **Lines Changed:** +418, -60
151
+
152
+ **Core Changes:**
153
+ - `lib/darkarts/cli_darkarts.py` - Complete rewrite of `cmd_darkarts_convert()`
154
+ - `lib/darkarts/annotations/translator.py` - Fixed `natural_to_symbols()` and `create_darkarts_from_voodocs()`
155
+ - Added `_replace_annotations_in_file()` helper function for proper file modification
156
+
157
+ ---
158
+
159
+ ### Testing
160
+
161
+ **Python Files:**
162
+ ```bash
163
+ voodocs darkarts convert test.py
164
+ # βœ… Module + function annotations converted
165
+ # βœ… All fields preserved
166
+ # βœ… Symbol conversion correct
167
+ ```
168
+
169
+ **TypeScript Files:**
170
+ ```bash
171
+ voodocs darkarts convert test.ts
172
+ # βœ… TypeScript syntax recognized
173
+ # βœ… Comment format preserved (/**@darkarts ... */)
174
+ # βœ… No text corruption
175
+ ```
176
+
177
+ **In-Place Modification:**
178
+ ```bash
179
+ voodocs darkarts convert test.py --in-place
180
+ # βœ… File modified successfully
181
+ # βœ… Proper syntax maintained
182
+ ```
183
+
184
+ ---
185
+
186
+ ### Upgrade Notes
187
+
188
+ No breaking changes. Simply update to v1.0.1:
189
+
190
+ ```bash
191
+ npm install -g @voodocs/cli@1.0.1
192
+ ```
193
+
194
+ The convert command now works as originally intended with full multi-language support and complete field preservation.
195
+
196
+ ---
197
+
198
+ ### Known Limitations
199
+
200
+ - TypeScript parser doesn't extract function-level annotations yet (parser issue, not convert issue)
201
+ - Convert command is ready when parser is enhanced
202
+
203
+ ---
204
+
205
+ **Full Changelog:** https://github.com/3vilEnterprises/vooodooo-magic/compare/v1.0.0...v1.0.1
1
206
  ## [1.0.0] - 2024-12-21
2
207
 
3
208
  ### πŸŽ‰ Major Release: Validation Integration - The Only Documentation Tool That Validates Annotations