pumuki-ast-hooks 6.0.12 → 6.0.14
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/docs/RELEASE_NOTES.md
CHANGED
|
@@ -1,3 +1,31 @@
|
|
|
1
|
+
# Release Notes - v6.0.14
|
|
2
|
+
|
|
3
|
+
**Release Date**: January 13, 2026
|
|
4
|
+
**Type**: Patch Release
|
|
5
|
+
**Compatibility**: Fully backward compatible with 6.0.x
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## ✅ Fixes
|
|
10
|
+
|
|
11
|
+
- **iOS DIP detector**: `UseCase`/`Repository` protocol-like types are never treated as concrete.
|
|
12
|
+
|
|
13
|
+
---
|
|
14
|
+
|
|
15
|
+
# Release Notes - v6.0.13
|
|
16
|
+
|
|
17
|
+
**Release Date**: January 13, 2026
|
|
18
|
+
**Type**: Patch Release
|
|
19
|
+
**Compatibility**: Fully backward compatible with 6.0.x
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
## ✅ Fixes
|
|
24
|
+
|
|
25
|
+
- **iOS DIP detector**: protocol-like types are detected even with trailing punctuation (e.g. `LoginUseCase,`).
|
|
26
|
+
|
|
27
|
+
---
|
|
28
|
+
|
|
1
29
|
# Release Notes - v6.0.12
|
|
2
30
|
|
|
3
31
|
**Release Date**: January 13, 2026
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "pumuki-ast-hooks",
|
|
3
|
-
"version": "6.0.
|
|
3
|
+
"version": "6.0.14",
|
|
4
4
|
"description": "Enterprise-grade AST Intelligence System with multi-platform support (iOS, Android, Backend, Frontend) and Feature-First + DDD + Clean Architecture enforcement. Includes dynamic violations API for intelligent querying.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"bin": {
|
|
@@ -94,7 +94,8 @@ describe('DIValidationService', () => {
|
|
|
94
94
|
{ 'key.name': 'loginUseCase', 'key.typename': 'LoginUseCase' },
|
|
95
95
|
{ 'key.name': 'logoutUseCase', 'key.typename': 'LogoutUseCase & Sendable' },
|
|
96
96
|
{ 'key.name': 'currentUserUseCase', 'key.typename': 'Domain.UserRetrievalUseCase?' },
|
|
97
|
-
{ 'key.name': 'registerUseCase', 'key.typename': 'RegisterUseCase<Auth>' }
|
|
97
|
+
{ 'key.name': 'registerUseCase', 'key.typename': 'RegisterUseCase<Auth>' },
|
|
98
|
+
{ 'key.name': 'loginUseCase2', 'key.typename': 'LoginUseCase,' }
|
|
98
99
|
];
|
|
99
100
|
|
|
100
101
|
await diValidationService.validateDependencyInjection(
|
|
@@ -88,31 +88,39 @@ class ConcreteDependencyStrategy extends DIStrategy {
|
|
|
88
88
|
}
|
|
89
89
|
|
|
90
90
|
_isConcreteService(typename) {
|
|
91
|
+
const normalized = this._normalizeTypeName(typename);
|
|
91
92
|
const hasConcretePattern = this.config.concretePatterns.some(pattern =>
|
|
92
|
-
new RegExp(pattern).test(
|
|
93
|
+
new RegExp(pattern).test(normalized)
|
|
93
94
|
);
|
|
94
95
|
|
|
95
96
|
const hasProtocolIndicator = this.config.protocolIndicators.some(indicator =>
|
|
96
|
-
|
|
97
|
+
normalized.includes(indicator)
|
|
97
98
|
);
|
|
98
99
|
|
|
99
|
-
|
|
100
|
+
const isLikelyProtocol = /UseCase$|Repository$/.test(normalized) && !/Impl$/.test(normalized);
|
|
101
|
+
|
|
102
|
+
return hasConcretePattern && !hasProtocolIndicator && !isLikelyProtocol;
|
|
100
103
|
}
|
|
101
104
|
|
|
102
105
|
_isLikelyProtocolType(typename) {
|
|
103
|
-
const normalized = typename
|
|
106
|
+
const normalized = this._normalizeTypeName(typename);
|
|
107
|
+
|
|
108
|
+
if (/Impl$/.test(normalized)) {
|
|
109
|
+
return false;
|
|
110
|
+
}
|
|
111
|
+
return /UseCase$|Repository$/.test(normalized);
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
_normalizeTypeName(typename) {
|
|
115
|
+
return typename
|
|
104
116
|
.replace(/^(any|some)\s+/, '')
|
|
105
117
|
.replace(/[!?]/g, '')
|
|
106
118
|
.replace(/<.*>/g, '')
|
|
107
119
|
.split('&')[0]
|
|
108
120
|
.split('.')
|
|
109
121
|
.pop()
|
|
110
|
-
?.trim()
|
|
111
|
-
|
|
112
|
-
if (/Impl$/.test(normalized)) {
|
|
113
|
-
return false;
|
|
114
|
-
}
|
|
115
|
-
return /UseCase$|Repository$/.test(normalized);
|
|
122
|
+
?.trim()
|
|
123
|
+
.replace(/[^A-Za-z0-9_].*$/, '') || typename;
|
|
116
124
|
}
|
|
117
125
|
}
|
|
118
126
|
|