Executive summary
sayeed1999/home scores 36 out of 100, but it is rated At risk while a critical security finding is open; the score itself is unchanged.
The weakest lens counts most in the score, and here that is Production Readiness, which scores 15 and is rated Critical. Its Dependency Hygiene dimension scores 0 out of 10, and until that reaches 4, Production Readiness can't be rated higher than Adequate. The first actions are to resolve the 3 Deprecated finding(s) in Dependency Hygiene and to resolve the 6 Orphaned file finding(s) in Knowledge Freshness, and if Production Readiness rose to 70, the score would rise from 36 to about 52.
43 findings are critical: 32 in Dependency Vulnerabilities, five in Dependency Hygiene, three in Web-Security Posture, two in IaC & Container Security and one in Circular Imports.
Watchdog couldn't measure 9 dimensions in this code, among them Code Coverage, Test Reliability and Internal API Consistency, so they are left out of the score. The product code is 2,951 lines, which would take an estimated 0.1 person-years, around €2,700, to rebuild.
If Production Readiness rose from 15 to 70, the lowest score rated Strong, the score would rise from 36 to about 52.
New since the last survey: 31 findings
- Dependency Hygiene · Deprecated: @types/http-proxy-middleware api-gateway/package.json
- Dependency Hygiene · Deprecated: @types/mongoose chat-service/package.json
- Dependency Hygiene · Deprecated: @types/socket.io chat-service/package.json
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Static Analysis (SAST) · REDACTED
- Web-Security Posture · Cryptographic key material is a compile-time constant REDACTED
- Web-Security Posture · Cryptographic key material is a compile-time constant REDACTED
Fixed since the last survey: 51 findings
- Test Coverage · No test reaches this file REDACTED
- Test Coverage · No test reaches this file home-service/src/modules/post-log/controllers/rest.ts
- Test Coverage · No test reaches this file api-gateway/src/index.ts
- Test Coverage · No test reaches this file auth-service/src/message-queue/chat-queue.ts
- Test Coverage · No test reaches this file auth-service/src/message-queue/home-queue.ts
- Test Coverage · No test reaches this file chat-service/src/models/provider.ts
- Test Coverage · No test reaches this file REDACTED
- Test Coverage · No test reaches this file chat-service/src/loaders/db-connection.ts
- Test Coverage · No test reaches this file home-service/src/api/middlewares/post.middleware.ts
- Test Coverage · No test reaches this file REDACTED
- Test Coverage · No test reaches this file REDACTED
- Test Coverage · No test reaches this file chat-service/src/models/message.model.ts
- Test Coverage · No test reaches this file ecom-service/src/api/routes/index.ts
- Test Coverage · No test reaches this file ecom-service/src/modules/product/repository/index.ts
- Test Coverage · No test reaches this file REDACTED
- Test Coverage · No test reaches this file REDACTED
- Test Coverage · No test reaches this file ecom-service/src/index.ts
- Test Coverage · No test reaches this file ecom-service/src/modules/product/services/index.ts
- Test Coverage · No test reaches this file home-service/src/api/routes/index.ts
- Test Coverage · No test reaches this file home-service/src/loaders/db-connection.ts
- Test Coverage · No test reaches this file auth-service/src/loaders/set-subscriber-for-services.ts
- Test Coverage · No test reaches this file auth-service/src/utils/enums/index.ts
- Test Coverage · No test reaches this file auth-service/src/utils/errors/custom-error.ts
- Test Coverage · No test reaches this file chat-service/src/utils/errors/custom-error.ts
- Test Coverage · No test reaches this file ecom-service/src/utils/errors/custom-error.ts
- Test Coverage · No test reaches this file ecom-service/src/modules/product/controllers/rest.ts
- Test Coverage · No test reaches this file chat-service/src/api/routes/index.ts
- Test Coverage · No test reaches this file REDACTED
- Test Coverage · No test reaches this file ecom-service/src/message-queue/index.ts
- Test Coverage · No test reaches this file ecom-service/src/utils/enums/index.ts
- Test Coverage · No test reaches this file chat-service/src/utils/enums/index.ts
- Test Coverage · No test reaches this file auth-service/src/utils/helpers/email.ts
- Test Coverage · No test reaches this file chat-service/src/modules/group-conversation/controllers/rest.ts
- Test Coverage · No test reaches this file api-gateway/src/api/routes/index.ts
- Test Coverage · No test reaches this file api-gateway/src/config/index.ts
- Test Coverage · No test reaches this file api-gateway/src/loaders/index.ts
- Test Coverage · No test reaches this file api-gateway/src/utils/constants/index.ts
- Test Coverage · No test reaches this file api-gateway/src/utils/helpers/index.ts
- Test Coverage · No test reaches this file auth-service/src/jobs/index.ts
- Test Coverage · No test reaches this file auth-service/src/modules/auth/controllers/grpc.ts
- Test Coverage · No test reaches this file auth-service/src/subscribers/index.ts
- Test Coverage · No test reaches this file auth-service/src/utils/helpers/index.ts
- Test Coverage · No test reaches this file ecom-service/src/modules/cart/controllers/rest.ts
- Test Coverage · No test reaches this file ecom-service/src/modules/cart/repository/index.ts
- Test Coverage · No test reaches this file ecom-service/src/modules/cart/services/index.ts
- Test Coverage · No test reaches this file ecom-service/src/modules/user/controllers/rest.ts
- Test Coverage · No test reaches this file ecom-service/src/modules/user/repository/index.ts
- Test Coverage · No test reaches this file ecom-service/src/modules/user/services/index.ts
- Test Coverage · No test reaches this file ecom-service/src/utils/helpers/index.ts
- Test Coverage · No test reaches this file home-service/src/modules/base/controllers/rest.ts
- Test Coverage · No test reaches this file home-service/src/utils/helpers/index.ts
Rebuild cost: about €2,700 · Estimate
| Cost to rebuild | €900 to €4,500, for 15 to 48 hours of work, about 0.1 person-years for one engineer |
|---|---|
| Difficulty of the problem | Standard, judged from the kind of software and how it is built. Code that solves a harder problem, such as payments or medical bookings, costs more per line to write. |
| Quality factor | ×0.7 at a score of 36. Better code takes more work to write, so the factor is ×1.0 at a score of 70, lower below it and higher above it. |
| Size | Small: 2,951 lines of product code |
Top priorities
Diagnosis: what the measurements show together
Architecture: which parts of the code depend on which
| uses → | 1 api-gateway | 2 auth-service | 3 auth-service.src | 4 auth-service.src.api | 5 auth-service.src.loaders | 6 auth-service.src.message-queue | 7 auth-service.src.models | 8 auth-service.src.models.provider | 9 auth-service.src.models.role_model | 10 auth-service.src.models.user-role_model | 11 auth-service.src.models.user_model | 12 auth-service.src.modules.auth | 13 auth-service.src.modules.auth.controllers | 14 auth-service.src.utils.enums | 15 auth-service.src.utils.errors.custom-error | 16 auth-service.src.utils.helpers | 17 chat-service | 18 chat-service.src.api | 19 chat-service.src.loaders | 20 chat-service.src.models.conversation_model | 21 chat-service.src.models.user_model | 22 chat-service.src.modules.dual-conversation.controllers | 23 chat-service.src.modules.dual-conversation.services | 24 home-service.src.models.comment_model | 25 home-service.src.models.post-log_model | 26 home-service.src.models.post_model | 27 home-service.src.modules.base.repository | 28 chat-service.src.models.provider | 29 chat-service.src.modules.group-conversation.services | 30 ecom-service.src.models.provider | 31 home-service.src.models.provider | 32 home-service.src.modules.base.services | 33 home-service.src.modules.comment.repository | 34 home-service.src.modules.post-log.repository | 35 home-service.src.modules.post.repository | 36 home-service.src.modules.user.repository | 37 home-service.src.modules.comment.services | 38 home-service.src.modules.post-log.services | 39 home-service.src.modules.post.services | 40 home-service.src.modules.user.services |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 1 api-gateway | ||||||||||||||||||||||||||||||||||||||||
| 2 auth-service | ||||||||||||||||||||||||||||||||||||||||
| 3 auth-service.src | ||||||||||||||||||||||||||||||||||||||||
| 4 auth-service.src.api | ||||||||||||||||||||||||||||||||||||||||
| 5 auth-service.src.loaders | ||||||||||||||||||||||||||||||||||||||||
| 6 auth-service.src.message-queue | ||||||||||||||||||||||||||||||||||||||||
| 7 auth-service.src.models | ||||||||||||||||||||||||||||||||||||||||
| 8 auth-service.src.models.provider | ||||||||||||||||||||||||||||||||||||||||
| 9 auth-service.src.models.role_model | ||||||||||||||||||||||||||||||||||||||||
| 10 auth-service.src.models.user-role_model | ||||||||||||||||||||||||||||||||||||||||
| 11 auth-service.src.models.user_model | ||||||||||||||||||||||||||||||||||||||||
| 12 auth-service.src.modules.auth | ||||||||||||||||||||||||||||||||||||||||
| 13 auth-service.src.modules.auth.controllers | ||||||||||||||||||||||||||||||||||||||||
| 14 auth-service.src.utils.enums | ||||||||||||||||||||||||||||||||||||||||
| 15 auth-service.src.utils.errors.custom-error | ||||||||||||||||||||||||||||||||||||||||
| 16 auth-service.src.utils.helpers | ||||||||||||||||||||||||||||||||||||||||
| 17 chat-service | ||||||||||||||||||||||||||||||||||||||||
| 18 chat-service.src.api | ||||||||||||||||||||||||||||||||||||||||
| 19 chat-service.src.loaders | ||||||||||||||||||||||||||||||||||||||||
| 20 chat-service.src.models.conversation_model | ||||||||||||||||||||||||||||||||||||||||
| 21 chat-service.src.models.user_model | ||||||||||||||||||||||||||||||||||||||||
| 22 chat-service.src.modules.dual-conversation.controllers | ||||||||||||||||||||||||||||||||||||||||
| 23 chat-service.src.modules.dual-conversation.services | ||||||||||||||||||||||||||||||||||||||||
| 24 home-service.src.models.comment_model | ||||||||||||||||||||||||||||||||||||||||
| 25 home-service.src.models.post-log_model | ||||||||||||||||||||||||||||||||||||||||
| 26 home-service.src.models.post_model | ||||||||||||||||||||||||||||||||||||||||
| 27 home-service.src.modules.base.repository | ||||||||||||||||||||||||||||||||||||||||
| 28 chat-service.src.models.provider | 1 | 1 | 1 | |||||||||||||||||||||||||||||||||||||
| 29 chat-service.src.modules.group-conversation.services | 1 | |||||||||||||||||||||||||||||||||||||||
| 30 ecom-service.src.models.provider | 1 | |||||||||||||||||||||||||||||||||||||||
| 31 home-service.src.models.provider | 1 | 1 | 1 | 1 | 1 | |||||||||||||||||||||||||||||||||||
| 32 home-service.src.modules.base.services | 1 | 1 | ||||||||||||||||||||||||||||||||||||||
| 33 home-service.src.modules.comment.repository | 1 | |||||||||||||||||||||||||||||||||||||||
| 34 home-service.src.modules.post-log.repository | 1 | |||||||||||||||||||||||||||||||||||||||
| 35 home-service.src.modules.post.repository | 1 | 1 | ||||||||||||||||||||||||||||||||||||||
| 36 home-service.src.modules.user.repository | 1 | |||||||||||||||||||||||||||||||||||||||
| 37 home-service.src.modules.comment.services | 2 | 2 | 1 | |||||||||||||||||||||||||||||||||||||
| 38 home-service.src.modules.post-log.services | 1 | 1 | ||||||||||||||||||||||||||||||||||||||
| 39 home-service.src.modules.post.services | 2 | 1 | 1 | |||||||||||||||||||||||||||||||||||||
| 40 home-service.src.modules.user.services | 1 |
28→8 chat-service.src.models.provider uses auth-service.src.models.provider✕
- Connections
- 1 pair of types, where a type in chat-service.src.models.provider uses a type in auth-service.src.models.provider.
- The types involved
chat-service.src.models.provider.Provider→auth-service.src.models.provider.Provider
- Direction
- chat-service.src.models.provider uses auth-service.src.models.provider, so a change to auth-service.src.models.provider can break chat-service.src.models.provider, while a change to chat-service.src.models.provider can't break auth-service.src.models.provider.
- Position
- Below the diagonal: chat-service.src.models.provider uses a module listed above it, which is the healthy direction.
28→11 chat-service.src.models.provider uses auth-service.src.models.user_model✕
- Connections
- 1 pair of types, where a type in chat-service.src.models.provider uses a type in auth-service.src.models.user_model.
- The types involved
chat-service.src.models.provider.Provider→auth-service.src.models.user_model.IUser
- Direction
- chat-service.src.models.provider uses auth-service.src.models.user_model, so a change to auth-service.src.models.user_model can break chat-service.src.models.provider, while a change to chat-service.src.models.provider can't break auth-service.src.models.user_model.
- Position
- Below the diagonal: chat-service.src.models.provider uses a module listed above it, which is the healthy direction.
28→20 chat-service.src.models.provider uses chat-service.src.models.conversation_model✕
- Connections
- 1 pair of types, where a type in chat-service.src.models.provider uses a type in chat-service.src.models.conversation_model.
- The types involved
chat-service.src.models.provider.Provider→chat-service.src.models.conversation_model.IConversation
- Direction
- chat-service.src.models.provider uses chat-service.src.models.conversation_model, so a change to chat-service.src.models.conversation_model can break chat-service.src.models.provider, while a change to chat-service.src.models.provider can't break chat-service.src.models.conversation_model.
- Position
- Below the diagonal: chat-service.src.models.provider uses a module listed above it, which is the healthy direction.
29→23 chat-service.src.modules.group-conversation.services uses chat-service.src.modules.dual-conversation.services✕
- Connections
- 1 pair of types, where a type in chat-service.src.modules.group-conversation.services uses a type in chat-service.src.modules.dual-conversation.services.
- The types involved
chat-service.src.modules.group-conversation.services.GroupConversationService→chat-service.src.modules.dual-conversation.services.DualConversationService
- Direction
- chat-service.src.modules.group-conversation.services uses chat-service.src.modules.dual-conversation.services, so a change to chat-service.src.modules.dual-conversation.services can break chat-service.src.modules.group-conversation.services, while a change to chat-service.src.modules.group-conversation.services can't break chat-service.src.modules.dual-conversation.services.
- Position
- Below the diagonal: chat-service.src.modules.group-conversation.services uses a module listed above it, which is the healthy direction.
30→8 ecom-service.src.models.provider uses auth-service.src.models.provider✕
- Connections
- 1 pair of types, where a type in ecom-service.src.models.provider uses a type in auth-service.src.models.provider.
- The types involved
ecom-service.src.models.provider.Provider→auth-service.src.models.provider.Provider
- Direction
- ecom-service.src.models.provider uses auth-service.src.models.provider, so a change to auth-service.src.models.provider can break ecom-service.src.models.provider, while a change to ecom-service.src.models.provider can't break auth-service.src.models.provider.
- Position
- Below the diagonal: ecom-service.src.models.provider uses a module listed above it, which is the healthy direction.
31→8 home-service.src.models.provider uses auth-service.src.models.provider✕
- Connections
- 1 pair of types, where a type in home-service.src.models.provider uses a type in auth-service.src.models.provider.
- The types involved
home-service.src.models.provider.Provider→auth-service.src.models.provider.Provider
- Direction
- home-service.src.models.provider uses auth-service.src.models.provider, so a change to auth-service.src.models.provider can break home-service.src.models.provider, while a change to home-service.src.models.provider can't break auth-service.src.models.provider.
- Position
- Below the diagonal: home-service.src.models.provider uses a module listed above it, which is the healthy direction.
31→11 home-service.src.models.provider uses auth-service.src.models.user_model✕
- Connections
- 1 pair of types, where a type in home-service.src.models.provider uses a type in auth-service.src.models.user_model.
- The types involved
home-service.src.models.provider.Provider→auth-service.src.models.user_model.IUser
- Direction
- home-service.src.models.provider uses auth-service.src.models.user_model, so a change to auth-service.src.models.user_model can break home-service.src.models.provider, while a change to home-service.src.models.provider can't break auth-service.src.models.user_model.
- Position
- Below the diagonal: home-service.src.models.provider uses a module listed above it, which is the healthy direction.
31→24 home-service.src.models.provider uses home-service.src.models.comment_model✕
- Connections
- 1 pair of types, where a type in home-service.src.models.provider uses a type in home-service.src.models.comment_model.
- The types involved
home-service.src.models.provider.Provider→home-service.src.models.comment_model.IComment
- Direction
- home-service.src.models.provider uses home-service.src.models.comment_model, so a change to home-service.src.models.comment_model can break home-service.src.models.provider, while a change to home-service.src.models.provider can't break home-service.src.models.comment_model.
- Position
- Below the diagonal: home-service.src.models.provider uses a module listed above it, which is the healthy direction.
31→25 home-service.src.models.provider uses home-service.src.models.post-log_model✕
- Connections
- 1 pair of types, where a type in home-service.src.models.provider uses a type in home-service.src.models.post-log_model.
- The types involved
home-service.src.models.provider.Provider→home-service.src.models.post-log_model.IPostLog
- Direction
- home-service.src.models.provider uses home-service.src.models.post-log_model, so a change to home-service.src.models.post-log_model can break home-service.src.models.provider, while a change to home-service.src.models.provider can't break home-service.src.models.post-log_model.
- Position
- Below the diagonal: home-service.src.models.provider uses a module listed above it, which is the healthy direction.
31→26 home-service.src.models.provider uses home-service.src.models.post_model✕
- Connections
- 1 pair of types, where a type in home-service.src.models.provider uses a type in home-service.src.models.post_model.
- The types involved
home-service.src.models.provider.Provider→home-service.src.models.post_model.IPost
- Direction
- home-service.src.models.provider uses home-service.src.models.post_model, so a change to home-service.src.models.post_model can break home-service.src.models.provider, while a change to home-service.src.models.provider can't break home-service.src.models.post_model.
- Position
- Below the diagonal: home-service.src.models.provider uses a module listed above it, which is the healthy direction.
32→11 home-service.src.modules.base.services uses auth-service.src.models.user_model✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.base.services uses a type in auth-service.src.models.user_model.
- The types involved
home-service.src.modules.base.services.IBaseService→auth-service.src.models.user_model.IUser
- Direction
- home-service.src.modules.base.services uses auth-service.src.models.user_model, so a change to auth-service.src.models.user_model can break home-service.src.modules.base.services, while a change to home-service.src.modules.base.services can't break auth-service.src.models.user_model.
- Position
- Below the diagonal: home-service.src.modules.base.services uses a module listed above it, which is the healthy direction.
32→27 home-service.src.modules.base.services uses home-service.src.modules.base.repository✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.base.services uses a type in home-service.src.modules.base.repository.
- The types involved
home-service.src.modules.base.services.BaseService→home-service.src.modules.base.repository.IBaseRepository
- Direction
- home-service.src.modules.base.services uses home-service.src.modules.base.repository, so a change to home-service.src.modules.base.repository can break home-service.src.modules.base.services, while a change to home-service.src.modules.base.services can't break home-service.src.modules.base.repository.
- Position
- Below the diagonal: home-service.src.modules.base.services uses a module listed above it, which is the healthy direction.
33→27 home-service.src.modules.comment.repository uses home-service.src.modules.base.repository✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.comment.repository uses a type in home-service.src.modules.base.repository.
- The types involved
home-service.src.modules.comment.repository.CommentRepository→home-service.src.modules.base.repository.BaseRepository
- Direction
- home-service.src.modules.comment.repository uses home-service.src.modules.base.repository, so a change to home-service.src.modules.base.repository can break home-service.src.modules.comment.repository, while a change to home-service.src.modules.comment.repository can't break home-service.src.modules.base.repository.
- Position
- Below the diagonal: home-service.src.modules.comment.repository uses a module listed above it, which is the healthy direction.
34→27 home-service.src.modules.post-log.repository uses home-service.src.modules.base.repository✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.post-log.repository uses a type in home-service.src.modules.base.repository.
- The types involved
home-service.src.modules.post-log.repository.PostLogRepository→home-service.src.modules.base.repository.BaseRepository
- Direction
- home-service.src.modules.post-log.repository uses home-service.src.modules.base.repository, so a change to home-service.src.modules.base.repository can break home-service.src.modules.post-log.repository, while a change to home-service.src.modules.post-log.repository can't break home-service.src.modules.base.repository.
- Position
- Below the diagonal: home-service.src.modules.post-log.repository uses a module listed above it, which is the healthy direction.
35→26 home-service.src.modules.post.repository uses home-service.src.models.post_model✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.post.repository uses a type in home-service.src.models.post_model.
- The types involved
home-service.src.modules.post.repository.IPostRepository→home-service.src.models.post_model.IPost
- Direction
- home-service.src.modules.post.repository uses home-service.src.models.post_model, so a change to home-service.src.models.post_model can break home-service.src.modules.post.repository, while a change to home-service.src.modules.post.repository can't break home-service.src.models.post_model.
- Position
- Below the diagonal: home-service.src.modules.post.repository uses a module listed above it, which is the healthy direction.
35→27 home-service.src.modules.post.repository uses home-service.src.modules.base.repository✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.post.repository uses a type in home-service.src.modules.base.repository.
- The types involved
home-service.src.modules.post.repository.PostRepository→home-service.src.modules.base.repository.BaseRepository
- Direction
- home-service.src.modules.post.repository uses home-service.src.modules.base.repository, so a change to home-service.src.modules.base.repository can break home-service.src.modules.post.repository, while a change to home-service.src.modules.post.repository can't break home-service.src.modules.base.repository.
- Position
- Below the diagonal: home-service.src.modules.post.repository uses a module listed above it, which is the healthy direction.
36→27 home-service.src.modules.user.repository uses home-service.src.modules.base.repository✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.user.repository uses a type in home-service.src.modules.base.repository.
- The types involved
home-service.src.modules.user.repository.UserRepository→home-service.src.modules.base.repository.BaseRepository
- Direction
- home-service.src.modules.user.repository uses home-service.src.modules.base.repository, so a change to home-service.src.modules.base.repository can break home-service.src.modules.user.repository, while a change to home-service.src.modules.user.repository can't break home-service.src.modules.base.repository.
- Position
- Below the diagonal: home-service.src.modules.user.repository uses a module listed above it, which is the healthy direction.
37→11 home-service.src.modules.comment.services uses auth-service.src.models.user_model✕
- Connections
- 2 pairs of types, where a type in home-service.src.modules.comment.services uses a type in auth-service.src.models.user_model.
- The types involved
home-service.src.modules.comment.services.CommentService→auth-service.src.models.user_model.IUserhome-service.src.modules.comment.services.ICommentService→auth-service.src.models.user_model.IUser
- Direction
- home-service.src.modules.comment.services uses auth-service.src.models.user_model, so a change to auth-service.src.models.user_model can break home-service.src.modules.comment.services, while a change to home-service.src.modules.comment.services can't break auth-service.src.models.user_model.
- Position
- Below the diagonal: home-service.src.modules.comment.services uses a module listed above it, which is the healthy direction.
37→24 home-service.src.modules.comment.services uses home-service.src.models.comment_model✕
- Connections
- 2 pairs of types, where a type in home-service.src.modules.comment.services uses a type in home-service.src.models.comment_model.
- The types involved
home-service.src.modules.comment.services.CommentService→home-service.src.models.comment_model.ICommenthome-service.src.modules.comment.services.ICommentService→home-service.src.models.comment_model.IComment
- Direction
- home-service.src.modules.comment.services uses home-service.src.models.comment_model, so a change to home-service.src.models.comment_model can break home-service.src.modules.comment.services, while a change to home-service.src.modules.comment.services can't break home-service.src.models.comment_model.
- Position
- Below the diagonal: home-service.src.modules.comment.services uses a module listed above it, which is the healthy direction.
37→32 home-service.src.modules.comment.services uses home-service.src.modules.base.services✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.comment.services uses a type in home-service.src.modules.base.services.
- The types involved
home-service.src.modules.comment.services.CommentService→home-service.src.modules.base.services.BaseService
- Direction
- home-service.src.modules.comment.services uses home-service.src.modules.base.services, so a change to home-service.src.modules.base.services can break home-service.src.modules.comment.services, while a change to home-service.src.modules.comment.services can't break home-service.src.modules.base.services.
- Position
- Below the diagonal: home-service.src.modules.comment.services uses a module listed above it, which is the healthy direction.
38→25 home-service.src.modules.post-log.services uses home-service.src.models.post-log_model✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.post-log.services uses a type in home-service.src.models.post-log_model.
- The types involved
home-service.src.modules.post-log.services.PostLogService→home-service.src.models.post-log_model.IPostLog
- Direction
- home-service.src.modules.post-log.services uses home-service.src.models.post-log_model, so a change to home-service.src.models.post-log_model can break home-service.src.modules.post-log.services, while a change to home-service.src.modules.post-log.services can't break home-service.src.models.post-log_model.
- Position
- Below the diagonal: home-service.src.modules.post-log.services uses a module listed above it, which is the healthy direction.
38→32 home-service.src.modules.post-log.services uses home-service.src.modules.base.services✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.post-log.services uses a type in home-service.src.modules.base.services.
- The types involved
home-service.src.modules.post-log.services.PostLogService→home-service.src.modules.base.services.BaseService
- Direction
- home-service.src.modules.post-log.services uses home-service.src.modules.base.services, so a change to home-service.src.modules.base.services can break home-service.src.modules.post-log.services, while a change to home-service.src.modules.post-log.services can't break home-service.src.modules.base.services.
- Position
- Below the diagonal: home-service.src.modules.post-log.services uses a module listed above it, which is the healthy direction.
39→11 home-service.src.modules.post.services uses auth-service.src.models.user_model✕
- Connections
- 2 pairs of types, where a type in home-service.src.modules.post.services uses a type in auth-service.src.models.user_model.
- The types involved
home-service.src.modules.post.services.IPostService→auth-service.src.models.user_model.IUserhome-service.src.modules.post.services.PostService→auth-service.src.models.user_model.IUser
- Direction
- home-service.src.modules.post.services uses auth-service.src.models.user_model, so a change to auth-service.src.models.user_model can break home-service.src.modules.post.services, while a change to home-service.src.modules.post.services can't break auth-service.src.models.user_model.
- Position
- Below the diagonal: home-service.src.modules.post.services uses a module listed above it, which is the healthy direction.
39→26 home-service.src.modules.post.services uses home-service.src.models.post_model✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.post.services uses a type in home-service.src.models.post_model.
- The types involved
home-service.src.modules.post.services.PostService→home-service.src.models.post_model.IPost
- Direction
- home-service.src.modules.post.services uses home-service.src.models.post_model, so a change to home-service.src.models.post_model can break home-service.src.modules.post.services, while a change to home-service.src.modules.post.services can't break home-service.src.models.post_model.
- Position
- Below the diagonal: home-service.src.modules.post.services uses a module listed above it, which is the healthy direction.
39→32 home-service.src.modules.post.services uses home-service.src.modules.base.services✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.post.services uses a type in home-service.src.modules.base.services.
- The types involved
home-service.src.modules.post.services.PostService→home-service.src.modules.base.services.BaseService
- Direction
- home-service.src.modules.post.services uses home-service.src.modules.base.services, so a change to home-service.src.modules.base.services can break home-service.src.modules.post.services, while a change to home-service.src.modules.post.services can't break home-service.src.modules.base.services.
- Position
- Below the diagonal: home-service.src.modules.post.services uses a module listed above it, which is the healthy direction.
40→32 home-service.src.modules.user.services uses home-service.src.modules.base.services✕
- Connections
- 1 pair of types, where a type in home-service.src.modules.user.services uses a type in home-service.src.modules.base.services.
- The types involved
home-service.src.modules.user.services.UserService→home-service.src.modules.base.services.BaseService
- Direction
- home-service.src.modules.user.services uses home-service.src.modules.base.services, so a change to home-service.src.modules.base.services can break home-service.src.modules.user.services, while a change to home-service.src.modules.user.services can't break home-service.src.modules.base.services.
- Position
- Below the diagonal: home-service.src.modules.user.services uses a module listed above it, which is the healthy direction.
At a glance — Code Health
At a glance — Architecture
At a glance — Maturity
At a glance — Readiness
At a glance — Security
At a glance — Domain Modelling
At a glance — Performance
Security & Compliance — OWASP Top-10 mapping
| OWASP category | Findings | Severity |
|---|---|---|
| A03:2025 — Software Supply Chain Failures | 50 | High / Critical |
| A05:2025 — Injection | 30 | Medium |
| A02:2025 — Security Misconfiguration | 6 | High / Critical |
Roadmap
Begin by cleaning up dependencies, specifically addressing deprecated packages in package.json followed by updating outdated npm libraries. Next, improve codebase knowledge by removing orphaned files, prioritizing REDACTED and user.model.ts, and establish architectural decision records to document key technical choices. Finally, strengthen data protection by implementing a secure key vault and encrypting sensitive database columns to eliminate coverage gaps.
| Do this | Helps | Effort | Dimension |
|---|---|---|---|
| Resolve the 3 Deprecated finding(s) in Dependency Hygiene — start with package.json (3). | +6.0 pts | Low | Dependency Hygiene |
| Resolve the 6 Orphaned file finding(s) in Knowledge Freshness — start with REDACTED (5), user.model.ts. | +5.3 pts | Low | Knowledge Freshness |
| Resolve the 1 No ADRs found finding(s) in ADR Quality. | +4.7 pts | Low | ADR Quality |
| Resolve the 2 Outdated (npm) finding(s) in Dependency Hygiene — start with package.json (2). | +4.0 pts | Low | Dependency Hygiene |
| Strengthen data-at-rest protection: vault your keys (AWS KMS / Secrets Manager, Azure Key Vault, GCP KMS / Secret Manager, HashiCorp Vault) and encrypt the most sensitive columns (typeorm-encrypted, prisma-field-encryption, mongoose-field-encryption or MongoDB CSFLE) — partial coverage still leaves gaps. | +4.3 pts | Medium | Data Protection |
| Record your significant design decisions. Write one short document per decision, giving its date, the situation, the decision and its consequences, and keep them together with your other design documents. A docs/adr folder with each file named by number and title is the easiest place to find them. | +3.7 pts | Medium | Architecture documentation |
| Resolve the 26 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (8), REDACTED (6), REDACTED (6). | +2.9 pts | Medium | Static Analysis (SAST) |
| Add a CI workflow that builds and runs the test suite on every push/PR. | +2.9 pts | Medium | CI/CD gates |
File quality
| File | Score | Band | Worst signal |
|---|---|---|---|
| REDACTED | 0.0 | Slop | Dependency Vulnerabilities: Critical CVE: REDACTED |
| REDACTED | 0.0 | Slop | Dependency Vulnerabilities: Critical CVE: REDACTED |
| REDACTED | 0.1 | Slop | Dependency Vulnerabilities: Critical CVE: REDACTED |
| REDACTED | 3.2 | Slop | Dependency Vulnerabilities: Critical CVE: REDACTED |
| REDACTED | 4.1 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| REDACTED | 4.4 | Mixed | IaC & Container Security: High IaC: REDACTED |
| REDACTED | 4.4 | Mixed | IaC & Container Security: High IaC: REDACTED |
| REDACTED | 5.9 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| REDACTED | 6.3 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| REDACTED | 6.3 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| REDACTED | 6.3 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| REDACTED | 6.3 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| REDACTED | 6.9 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| chat-service/package.json | 7.3 | Mixed | Dependency Hygiene: Deprecated: @types/mongoose |
| REDACTED | 7.9 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| REDACTED | 7.9 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| REDACTED | 7.9 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| REDACTED | 7.9 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| REDACTED | 7.9 | Mixed | Static Analysis (SAST): Medium: REDACTED |
| chat-service/src/modules/user/repository/index.ts | 8.2 | Near-clean | Explicit Debt: TodoComment |
How the grades work
A definite problem that already costs you something and drags the score down: a missing authorisation check, a dependency with a known exploit, a build that does not reproduce. Failure here tends to cause failures elsewhere.
Likely wrong, but not failing yet. It degrades the codebase over a longer horizon and can cause failures elsewhere — not urgent this week, not something to carry for two years either.
Recorded, with no effect on how the codebase functions. Present so the survey is complete, not because it needs doing.
Something this survey could not settle from the outside, and which could be critical or serious. Either a control was required and no positive evidence of it exists in the repository — a backup job that nothing shows was ever restored from proves nothing about restores — or our own analysis could not run over that part of the tree. This is not a clean result. These are excluded from the score rather than awarded a pass, so the number on the cover neither rewards nor penalises them: if you act on this survey without resolving them, you carry that risk yourself. Each one is named under Limitations.
Methodology & how to trust this report
Watchdog is a deep, periodic assessment — run each sprint, monthly, or quarterly, taking the time to go wider and deeper than a quick check and surfacing in one coherent report what you'd otherwise piece together from a dozen separate tools. It scores deterministically: the same commit yields the same score, every run. 69 of 72 evaluated dimensions are computed purely by tools and static analysis (confidence 1.0); 3 documentation/naming judgement(s) are LLM-assisted and labelled advisory. Overall confidence is 0.9 — the weighted average across measured dimensions; it falls as more of the score leans on LLM-assisted judgement and rises when it's fully tool-backed.
What we checked — 72 dimensions across the health lenses
- Can you open the finding? Real findings cite a repo-relative file and line you can open at the cited line — never an absolute scratch path. Here, 216 of 237 do; the remainder are repo-wide signals — a dimension-level measurement, not a single line.
- Is there a tool behind the number? Every score below names the method that produced it — Roslyn, git, a scanner, or (for a handful of documentation/naming dimensions) an LLM labelled sampled · advisory — not a narrative.
- Does re-running give the same result? Run it again on the same commit and the score — and this report, byte for byte — is identical. A report whose numbers move between runs is describing the run, not the code.
Tools & methods
| Method | Backs | Version | Evaluator |
|---|---|---|---|
| Roslyn static analysis | Complexity, cohesion, coupling, dead code, API surface, layering | 5.3.0 | ✓ deterministic |
| Native secret scanner | Hardcoded secrets / credentials | 1.0.0 | ✓ deterministic |
| Watchdog duplication detector (in-process) | Code duplication | 1.0.0 | ✓ deterministic |
| Coverage (coverlet / dotnet-coverage) | Line & branch coverage | 10.0.400 | ✓ deterministic |
| NuGet / dotnet | Outdated, vulnerable & deprecated dependencies | 10.0.400 | ✓ deterministic |
| git / LibGit2Sharp | Churn hotspots, knowledge concentration, history | 2.43.0 · 0.31.0 | ✓ deterministic |
| gitleaks · semgrep · trivy · checkov | Secrets in history, SAST, CVEs, IaC & container, PII / GDPR | 1.86.0 · 0.69.3 · 3.2.533 | ✓ deterministic |
| LLM (sampled · advisory) | Documentation quality, ADR conformance, naming — sampled over a bounded sample; advisory, never a deterministic measurement | Local LLM | ◐ LLM · sampled · advisory |
Run transparency — what happened this run
- D8 Code Coverage — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Coverage NOT MEASURED: test source is present (.ts) and the coverage collector does support this ecosystem — it drives jest, vitest and mocha — but no test command in this repository names a runner the analyzer recognises, so it could not tell what to instrument. Read from the manifests: `home-service` has a `scripts.test` of `ts-mocha -p tsconfig.json --timeout 30000 test/**/*.test.ts`. Not scored — this is a gap in the analyzer's reading of test commands, not a missing .ts runner and not a defect in this repository. To have real coverage read, produce a coverage report in a standard format (lcov — `vitest --coverage`, `jest --coverage`, `bun test --coverage --coverage-reporter=lcov`, or `nyc`) and commit it — a hosted scan measures a clone of the repository, so a report that exists only in a working tree, a CI runner's or your own, never reaches it; the artefact is commonly gitignored, so `git add -f` that one file (or un-ignore its path) and commit it alongside the code it measures. You can widen what we reach: optional: produce a coverage report in a standard format (lcov — `vitest --coverage`, `jest --coverage`, `bun test --coverage --coverage-reporter=lcov`, or `nyc`) and commit it — a hosted scan measures a clone of the repository, so a report that exists only in a working tree, a CI runner's or your own, never reaches it; the artefact is commonly gitignored, so `git add -f` that one file (or un-ignore its path) and commit it alongside the code it measures — a committed report is read whatever runner produced it.
- D11 Test Reliability — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Test source is present (.ts) and the reliability runner does support this ecosystem — it drives jest, vitest, mocha and egg-bin — but no test command in this repository names a runner the analyzer recognises, so it could not tell what to re-run. Read from the manifests: `home-service` has a `scripts.test` of `ts-mocha -p tsconfig.json --timeout 30000 test/**/*.test.ts`. So flakiness couldn't be assessed. Not scored — this is a gap in the analyzer's reading of test commands, not a missing .ts runner and not a finding about this repository.
- D16 Bus Factor — not measured this run — This is a true statement about the repository that carries nothing for its owner to act on, so it is reported here rather than as a defect in their code. Single-maintainer repository — bus factor is not applicable (4 contributor(s) across 144 commit(s) sampled, automation and bot accounts excluded). One of them holds 92% of the history; the other 3 hold 2.7% each on average, below the 5% at which there is somebody to hand the work to. That is a single maintainer with drive-by contributors, not a team whose knowledge has concentrated — so the bus factor is not applicable and there is nothing here for the owner to act on.
- D22 Internal API Consistency — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. D22 identifies the intentionally-exposed surface from `IsPackable` and `.Contracts` project names, MSBuild conventions read off the loaded project set. This target exposed no such projects, so the probe never ran; this says nothing about whether the repository has a public API. This repository commits no C#/VB source at all, so there was never an MSBuild project set to read these conventions off. That is OUR side and it is an ADMISSION gap, not an environment fault: it declares a published package (api-gateway/package.json), but no published-package marker D22 reads admitted any project here. D22 DOES collect the public API of every language in this tree, and admits a project only when its manifest makes that ecosystem's publication act in a form the marker recognises — so what is missing is not a collector but an admission rule for the publication act this repository makes, if it makes one. The remedy is a better discriminator for that marker — not a collector, and no change to the scan image can close it. The marker's rules are measured to refuse applications, so one refused repository is the rule working as calibrated; several are the evidence that it is too strict. For npm the surface is what a published package.json's entry points (exports, main, module, types) export, followed through the source; an entry that names build output the tree does not commit (dist/, build/) is not followed back to source, because only a tsconfig outDir/rootDir pair states that mapping and a bundler's input lives in executable configuration this engine does not evaluate.
- D27 Navigability — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Navigability is taken over call sites whose callee resolved. For C# that population includes calls into referenced assemblies; for this language only calls declared inside the repository count, so the abstention threshold reads the repository's use of its standard library as a resolution failure. That is a limit of this analyzer, not a build problem in this repository.
- D44 Platform End-of-Life — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This dimension reads a project's own statement about the platform it runs on: a TargetFramework in a .NET project file, a .nvmrc or .python-version, a capped requires-python, a Rust toolchain file or Cargo.toml rust-version, a .go-version, .java-version, .ruby-version, .tool-versions or .sdkmanrc, a go.mod go directive, a Maven or Gradle Java level or toolchain, a Gemfile's ruby directive, a mix.exs elixir requirement, a rebar.config minimum_otp_vsn, a pubspec.yaml SDK constraint, a build.sbt scalaVersion, or a framework major pinned by a dependency constraint. This repository carries none of them, so nothing about its platform was established. That is a gap in this analyzer's coverage, NOT a finding that the platform is supported — a language whose runtime is declared elsewhere (Package.swift, a REDACTED) is simply not read here yet.
- AXR1 Runtime accessibility — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. Render strategy: boot via DockerCompose (docker-compose.yml). compose up failed (exit 17 — an image could not be built) — failed to solve: node:alpine: failed to resolve source metadata for docker.io/library/node:alpine: failed to do request: Head "https://registry-1.docker.io/v2/library/node/manifests/alpine": Forbidden; runtime evidence skipped.
- DM9 Scattered domain decisions — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. Arm two tells a construction that PRODUCES a measurement from one that merely passes it along, and this repository's frontend does not compute that fact. A measurement built independently in two places would not appear above.
- P8 Schema migrations — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. The schema may be created by a runner, a deploy script or a config file outside what this check reads, so an absence here is our blind spot rather than a missing migration strategy. The card abstains instead of scoring. You can widen what we reach: if the schema is created and evolved by a tool this check does not name, naming it lets us teach the detector to read it.
- R4 Test Coverage — measured, with a gap in what it reached — Watchdog measured this, but not all of it. What it did not reach is a gap on our side — a collector, parser or image we have not built yet — so the numbers on that dimension cover less than the repository, and the part left out is not evidence that it would have passed. 51 further occurrence(s) are not listed individually; the score already reflects all 91.
- X2 Cancellation propagation — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Go, PHP, Dart, Kotlin, Ruby, Scala, Java, Python and Rust source only, and no C# was loaded, and no named async function in this repository's JavaScript/TypeScript, nor any Go, PHP or Dart function or Kotlin suspend function, makes a request that can be cancelled (fetch, axios, ky, ofetch; net/http, net.Dial; amphp; Dio; Ktor, OkHttp), so there is nothing to judge, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
- X4 Structured logging — not measured this run — Watchdog could not measure this here. That is a gap on our side — a collector, parser or image we have not built yet — and it is neither a defect in this repository nor evidence that the check would have passed. This check reads C# syntax, and JavaScript/TypeScript, Java, Kotlin, Python, PHP, Dart, Ruby, Scala and Rust source only, and no C# was loaded, and this repository's JavaScript/TypeScript, Python and PHP make no call through a named logger, so it had nothing of this repository's product to read. That is a gap in this analyzer's language reach — not a finding that the repository is free of what this check looks for.
Limitations & what we did not check
Watchdog assesses the repository exactly as committed, and only the repository. By design it does not reach outside the source tree: the live cloud account, the running CI/CD pipeline, the host's branch-protection and approval rules, the production configuration, or a restore actually exercised against a backup are all out of scope. That boundary is a feature, not a gap — a repo-relative, deterministic scan re-runs identically on any commit and every finding opens at a real file and line, where a live audit can neither be reproduced nor traced. The visible consequence is that controls which leave no in-repo evidence are reported as "not evidenced" and excluded from the score rather than awarded a number a static scan cannot justify.
Per-dimension blind spots
- D1 Cyclomatic Complexity: Cyclomatic complexity counts branches statically — it cannot tell an essential decision tree from accidental tangle, nor see complexity that lives in data or configuration (large switch-case token tables, DSL lexers/parsers, data-as-code rule tables) rather than control flow: a tokenizer's many single-character cases read as high complexity though each branch is trivial.
- D2 Cognitive Complexity: Cognitive-complexity heuristics approximate how hard code is to follow; genuine domain difficulty and well-named intent that eases reading are not captured.
- D3 God Classes: "God class" is sized by members and responsibilities visible in the type — a deliberately broad facade over a coherent subsystem can read the same as an accidental grab-bag. For front-end JS the file-length check is cohesion-aware (a single-responsibility module — one class/IIFE — earns a 3× threshold), but cohesion is approximated from top-level declarations, not true dependency structure.
- D5 Coupling: Coupling is measured between projects/assemblies — runtime coupling through DI, reflection, messaging or shared databases is invisible to a static reference graph.
- D6 Cohesion (LCOM4): LCOM4 cohesion is syntactic — it infers connectivity from which methods touch which fields/methods by name, not from real runtime behaviour or intent.
- D9 Test Distribution: The test-pyramid shape is inferred from project/folder naming and references, with a single test host bucketed per-file by its path tier and content signals — a suite that names tiers unconventionally and gives no per-file signal can still be mis-bucketed.
- D10 Test Quality: Assertion density is structural — it cannot tell a meaningful behavioural assertion from a trivial one, only that an assertion is present.
- D12 Dependency Hygiene: Dependency health reads manifests and lockfiles — a vulnerability in a vendored/copied dependency, or risk from how a dependency is actually used, is outside this view.
- D13 Secret Scanning: Secret detection is signature- and entropy-based on the current tree — a secret that does not match a known pattern, or one already rotated, will not be flagged (a clean scan is "nothing matched", not "no secrets exist").
- D14 License Compliance: License compatibility is checked against declared package metadata and a policy — mislabelled or missing license metadata, and obligations that depend on how you distribute, are not resolved here.
- D15 Churn × Complexity Hotspots: Churn hotspots come from git history — a freshly imported or squashed repository has no churn signal, and recent rewrites can mask a historically risky file.
- D17 Explicit Debt: Acknowledged-debt signals (TODO/FIXME, suppressions, dead code) are textual — undocumented debt that nobody marked, and debt that lives in design rather than annotations, is invisible. Committed machine-written code (scaffolded migrations, designer/codegen output, generated stubs) is excluded — it is never the team's dead code to delete.
- D19 Documentation Quality: Documentation quality is judged by an LLM over a bounded sample of docs — it reads what is written, not whether the docs match the running system, and it is advisory, not a measurement. Its critique rows are drawn from a closed category vocabulary and each row means the same thing in every run, so two scans can be compared row by row; the SET that fires is still a sample, and does not repeat exactly. Measured on one frozen input, six scans at one engine SHA: 2-5 critique rows per scan, 8 distinct rows across the six, 3 of those 8 seen in only one scan. So a D19 row is evidence about the documentation, but a COUNT of D19 rows is not a quantity — never read a change in it as an improvement or a regression.
- D20 ADR Quality: ADR quality is an LLM read of the decision records present — it cannot know about decisions made and never recorded, and its verdict is sampled and advisory.
- D21 Naming Consistency: Naming quality is an LLM judgement over a bounded sample — it assesses clarity/consistency of the names it sees, not domain-correctness, and is advisory.
- D26 Project Cohesion: Project focus is sized from members/namespaces per project — a project that is broad by deliberate design reads the same as one that has sprawled.
- D28 Secrets (history): Secret-history scanning sweeps the git log for known patterns — a secret that predates the available history, or never matched a signature, is not found (clean means "nothing matched in the history we can see").
- D29 Static Analysis (SAST): SAST findings are pattern-based (semgrep) — it finds classes of bug it has rules for; logic flaws, auth/authorization gaps and issues needing runtime context are out of reach (and clean means "no rule matched").
- D30 Dependency Vulnerabilities: CVE matching depends on accurate package/version metadata and on the advisory databases — a vulnerability with no published advisory, or in code not declared as a dependency, is not seen. Coverage needs a RESOLVED graph: an unpinned requirements.txt, or a pom without a resolved build, yields partial coverage rather than a clean verdict. An ecosystem the analyzer cannot scan is reported as unmeasured, never as clean.
- D31 IaC & Container Security: IaC scanning checks Dockerfiles/Terraform/Kubernetes against best-practice rules — it cannot see the live cloud account, runtime configuration, or drift between the committed config and what is actually deployed.
- D34 Knowledge Freshness: Freshness is decayed commit RECENCY, not comprehension — code read often but rarely committed reads as orphaned, and stable code that genuinely needs no changes is penalised the same as forgotten code; bot/squash commits distort it like the bus factor.
- D35 Change Coupling: Change coupling is co-change in COMMITS — files split across separate commits, or coupled only through a shared config/build step, read as uncoupled, and a sweeping commit (rename/format) is excluded so it doesn't couple everything. It shows that files change together, not WHY: a high coupling can be a healthy cohesive pair as readily as a hidden leak.
- D43 Malicious Dependencies: Only packages some vulnerability database has already NAMED as malicious are seen — a compromise published in the last hours, or never reported at all, is invisible here, and this dimension reading 10 is not evidence that a dependency is trustworthy. There is no typosquat or dependency-confusion analysis: a package nobody has reported is simply absent from the feeds. Coverage is the dependency scan's: an ecosystem that could not be scanned is disclosed as unmeasured, never as clean.
- AX10 Code composition: Role is inferred from namespace/folder convention, not semantics — a domain concept living in a folder named "Services" reads as application, and the split is lines-of-code, not business value. The business-logic-share score is a SOFT, FLOORED signal: it contributes to the Architecture lens but is floored at the Critical gate, so an infrastructure-heavy design (a gateway, an ETL, a driver) is legitimately low without being nuked to zero.
- M4 Documentation accuracy: Onboarding quality is an LLM read of the docs/setup present — it cannot run the onboarding or measure how long a real new joiner takes; the verdict is sampled and advisory.
- P4 Deployment & Rollback: Approval/branch-protection rules live in repository settings the scan cannot see — only their in-repo evidence (config files, workflows) is checked, so a control enforced purely in the host's settings reads as "not evidenced".
The LLM boundary
Dimensions
D1 · Cyclomatic Complexity
0 method(s) exceeded the cyclomatic complexity threshold of 15.
D2 · Cognitive Complexity
0 method(s) exceeded the cognitive complexity threshold of 15.
D3 · God Classes
0 god class(es) detected.
D5 · Coupling
5 production modules (npm), 0 dependency cycle(s), 0 unstable depended-on module(s). Read from the build's own module declarations; 0 module(s) off the main sequence.
D6 · Cohesion (LCOM4)
0 of 4 classes have LCOM4 above 3.
D9 · Test Distribution
17 test methods: 17 unit, 0 integration, 0 BDD, 0 e2e. The JavaScript/TypeScript suite contributes 17 `it`/`test` case(s) across 1 test file(s) declaring at least one; its tier split is read from package names and paths only.
D10 · Test Quality
0 skipped, 0 zero-assertion, no mocking-framework packages referenced (hand-written doubles or no mocking) across 17 tests.
D12 · Dependency Hygiene
13 outdated direct production npm dependency(ies) of 16 graded, 0 pinning defect(s), across 5 package.json (5 of them the product) and 5 committed lockfile(s). Development dependencies are deliberately not graded for currency: that grade is about what SHIPS. 3 direct dependency(ies) — production, development or optional — are marked DEPRECATED by their publisher (the registry's per-version mark, or the lockfile's copy of it when the registry could not be asked); deprecated transitive packages are listed but not charged. Whether any is UNMAINTAINED is not graded — the registry publishes no maintenance status, and release age does not stand in for one. Whether any is UNUSED is not graded either: that is a source question, and the frontend dependency lens (R8) answers it in this same run. Known CVEs in this dependency graph are D30's question, read from the manifest there.
What to do
- Resolve the 3 Deprecated finding(s) in Dependency Hygiene — start with package.json (3). — One of this dimension's main actionable groups (3 warning-level).
- Resolve the 2 Outdated (npm) finding(s) in Dependency Hygiene — start with package.json (2). — One of this dimension's main actionable groups (2 recommendation-level).
- Stand up a CI pipeline, then gate Dependency Hygiene in it to reach Verified (currently Documented). — This repository has no CI pipeline, so there is nothing to add a gate to yet — the pipeline comes first. Hardens enforcement from Documented toward Verified — provenance only; does not change the score.
D13 · Secret Scanning
Secret scan ran and found no leaked secrets.
D14 · License Compliance
0 of 16 shipped npm package(s) use a banned license. Licences were resolved from registry.npmjs.org over the 16 production dependency(ies) this repository's committed lockfile resolves, across 5 product package.json manifest(s). Its 37 `devDependencies` declaration(s) are excluded: a consumer installs none of them. ★ DEPTH: this is the DIRECT production set the lockfile resolves, NOT the transitive closure — only one of the four lock dialects this pass reads states a full graph, so a banned licence pulled in only by a dependency's OWN dependencies is outside this verdict, exactly as the JVM arm's declaration-site verdict is. ★ Each licence is the one the registry publishes for the package's CURRENT release rather than for the pinned version, which is the same caveat the Hex and RubyGems arms carry. This repository publishes itself under ISC, which is its own choice and is not judged here.
D15 · Churn × Complexity Hotspots
No churn × complexity hotspots in the window.
D17 · Explicit Debt
2 deducted task-comment markers across 2951 LoC (0.0/KLoC) → score 9.9. Task comments only: this repository's language is read without a compiler, so D17's suppression, dead-code and commented-out-code arms did not run and this score counts fewer marker kinds than a .NET repository's would.
What to do
- Resolve the 2 TodoComment finding(s) in Explicit Debt — start with REDACTED (2). — One of this dimension's main actionable groups (2 warning-level).
- Stand up a CI pipeline, then gate Explicit Debt in it to reach Verified (currently Documented). — This repository has no CI pipeline, so there is nothing to add a gate to yet — the pipeline comes first. Hardens enforcement from Documented toward Prevented — provenance only; does not change the score.
D19 · Documentation Quality
The repository's root README is an excellent overview of what the monorepo project 'Home' contains (unit microservices like api-gateway, chat-service, auth-service) and its design patterns (Observer, Provider, Singleton, Generic Repository), plus a detailed OVERALL STRUCTURE diagram showing each service's location, ports, and databases. It also begins with an outline of every section present in the document, so any missing section would be flagged against the outline rather than the visible text. The README is well written but does not yet provide installation/build or usage examples for the services it describes.
What to do
- Improve Documentation Quality — currently 7.0/10. — The repository's root README is an excellent overview of what the monorepo project 'Home' contains (unit microservices like api-gateway, chat-service, auth-service) and its design patterns (Observer, Provider, Singleton, Generic Repository), plus a detailed OVERALL STRUCTURE diagram showing each service's location, ports, and databases. It also begins with an outline of every section present in the document, so any missing section would be flagged against the outline rather than the visible text. The README is well written but does not yet provide installation/build or usage examples for the services it describes.
D20 · ADR Quality
No architecture decision records were found.
What to do
- Resolve the 1 No ADRs found finding(s) in ADR Quality. — One of this dimension's main actionable groups (1 recommendation-level).
D21 · Naming Consistency
0 naming inconsistencies across 0 sampled symbols.
D26 · Project Cohesion
0 of 5 build units (npm) flagged as possibly oversized/incoherent.
D28 · Secrets (history)
gitleaks scanned the full history AND the current working tree and found no secrets.
D29 · Static Analysis (SAST)
30 finding(s): 0 critical, 0 high, 30 medium, 0 low.
What to do
- Resolve the 26 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (8), REDACTED (6), REDACTED (6). — One of this dimension's main actionable groups (26 warning-level).
- Resolve the 4 REDACTED finding(s) in Static Analysis (SAST) — start with REDACTED (4). — One of this dimension's main actionable groups (4 warning-level).
D30 · Dependency Vulnerabilities
50 finding(s): 6 critical, 26 high, 10 medium, 8 low.
What to do
- Resolve the 25 High CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (25). — One of this dimension's main actionable groups (25 issue-level).
- Resolve the 6 Critical CVE finding(s) in Dependency Vulnerabilities — start with REDACTED (6). — One of this dimension's main actionable groups (6 issue-level).
- Resolve the 1 High vulnerability finding(s) in Dependency Vulnerabilities — start with REDACTED. — One of this dimension's main actionable groups (1 issue-level).
D31 · IaC & Container Security
6 finding(s): 0 critical, 2 high, 2 medium, 2 low.
What to do
- Resolve the 2 High IaC finding(s) in IaC & Container Security — start with REDACTED (2). — One of this dimension's main actionable groups (2 issue-level).
- Resolve the 2 Medium IaC finding(s) in IaC & Container Security — start with REDACTED (2). — One of this dimension's main actionable groups (2 warning-level).
- Resolve the 2 Low IaC finding(s) in IaC & Container Security — start with REDACTED (2). — One of this dimension's main actionable groups (2 recommendation-level).
D34 · Knowledge Freshness
6 of 6 significant source file(s) are orphaned — their living knowledge has decayed to nothing, so no one currently understands them. The largest is chat-service/src/modules/group-conversation/services/index.ts. Counted over 6 of the 117 production source files in this repository: the rest are under the ~2,400-byte size floor this dimension measures over.
What to do
- Resolve the 6 Orphaned file finding(s) in Knowledge Freshness — start with REDACTED (5), user.model.ts. — One of this dimension's main actionable groups (6 recommendation-level).
- Resolve the 1 Orphaned files with no living knowledge finding(s) in Knowledge Freshness. — One of this dimension's main actionable groups (1 recommendation-level).
D35 · Change Coupling
No strong hidden change-coupling between production files.
D43 · Malicious Dependencies
No dependency in any ecosystem this repository declares is published as malicious.
Frontend & cross-cutting dimensions
AX10 · Code composition
What to do
- The domain core is a small share of production code, but most of the rest matched no layer vocabulary at all — so this is not yet an anemic-domain finding. The namespace/path convention could not place that code, which makes the composition above a statement about the naming, not about the design. Name the layers (or check that the repository's conventions differ from the ones this check knows) before reading a thin domain into it.
AX3 · Project dependency cycles
AX4 · Dependency direction
AX6 · Interface segregation
C1 · Data Protection
What to do
- Strengthen data-at-rest protection: vault your keys (AWS KMS / Secrets Manager, Azure Key Vault, GCP KMS / Secret Manager, HashiCorp Vault) and encrypt the most sensitive columns (typeorm-encrypted, prisma-field-encryption, mongoose-field-encryption or MongoDB CSFLE) — partial coverage still leaves gaps.
- Enforce HTTPS (serve through https.createServer / NestJS httpsOptions, or redirect plain HTTP with express-sslify behind your TLS terminator) so data in transit is always encrypted.
C2 · Access Controls
- Authorization IS enforced here (by route guards, auth middleware or checks that refuse a caller) — this is NOT a claim that endpoints are unprotected. What's missing is a NAMED rule set: who may do what is encoded inline where it is checked, so the rules can't be listed, reviewed or tested apart from the code that applies them. Recommendation, not a defect.
What to do
- Name the access rules — roles/permissions declared once (a @Roles/@Permissions decorator with its guard, a CASL ability, a casbin model, or Supabase CREATE POLICY) and consulted where access is checked, so the rule set is reviewable and testable on its own.
DM9 · Scattered domain decisions
GD1 · Unfinished & placeholder code
IC1 · Incompleteness & stubs
- `fanout_user_creation` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — auth-service/src/message-queue/index.ts:11
- `fanout_user_update` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — auth-service/src/message-queue/index.ts:17
- `fanout_user_deletion` is declared `async` but never awaits anything, so it runs synchronously while pretending to be asynchronous. Drop `async` or do the real async work. — auth-service/src/message-queue/index.ts:23
What to do
- Remove the dead code that still moves this score: delete dead if(false) branches and either do the real async work or drop the async keyword from fake-async functions.
M1 · Documentation (README)
What to do
- Explain in the README how to run the tests. Add a section called Testing to the README in the repository's top folder, saying how to run the test suite.
- Add a README to the 5 of 5 project(s) that lack one — worth up to 2 pts.
M2 · Architecture documentation
- No Architecture Decision Records found — no conventional ADR directory, no numbered `NNNN-title` documents in any markup this check reads, and nothing ADR-shaped by content. Design rationale recorded elsewhere (a design-notes tree, a mailing list, pull-request discussion) is not visible to this check and is not re-findable per decision, so a future maintainer cannot ask why one choice was made and get an answer.
- No C4/Structurizr/PlantUML/Mermaid/Graphviz/D2 diagram, no drawn diagram named for the architecture, no file named `architecture` or `design` in any markup this check reads, and nothing in the README, docs or contributor guides that announces the shape — no `## Architecture` heading, no "architecture overview"/"high-level design" phrasing, no "the architecture is …" introduction, no guided code tour. A shape laid out in prose that never names itself as the architecture is not visible to this check, and neither is one kept outside the repository, so this row reports the absence of a re-findable shape document — not evidence that nobody wrote the shape down.
What to do
- Record your significant design decisions. Write one short document per decision, giving its date, the situation, the decision and its consequences, and keep them together with your other design documents. A docs/adr folder with each file named by number and title is the easiest place to find them.
- Add a C4 context/container diagram (Structurizr, PlantUML or Mermaid) or an architecture.md overview.
M3 · Folder & project structure
M4 · Documentation accuracy
- README advertises a microservices architecture, but the repo is a single project with no service manifests — searched for: `microservice`, `service-mesh`, `istio`. Each was matched case- and separator-insensitively against file and directory NAMES anywhere in the tree, and against the CONTENTS of manifest and configuration files (package.json and other *.json, *.csproj, *.props, *.sln/*.slnx, *.yml, *.toml, *.config, tool configs such as eslint.config.js, REDACTED); the README's own prose never counts, so a claim is never refuted by merely being made. Nothing outside that search was read — a footprint living only in a submodule, in a file type not listed here, or under a name none of those terms matches is not seen, and this row is then wrong. — README.md:3
What to do
- Reconcile the README with reality: README advertises a microservices architecture, but the repo is a single project with no service manifests.
P1 · CI/CD gates
- No CI workflow found (.github/workflows, azure-pipelines.yml, .gitlab-ci.yml, …) — changes aren't gated by an automated build/test.
What to do
- Add a CI workflow that builds and runs the test suite on every push/PR.
P10 · Library API & versioning
P2 · Observability
- No logging call was found in the 117 JavaScript/TypeScript production file(s) this check read across 5 module(s). Each was searched for its ecosystem's logging libraries (JavaScript/TypeScript: pino, winston, bunyan, log4js, loglevel, consola, the NestJS Logger) and for a call on a receiver named `log`/`logger` (or ending in `Logger`/`_logger`) with a level verb. It cannot see logging through a repo-local wrapper named otherwise, or in source it did not read — this is 'no logging found by this walk', not a verdict that nothing here logs. If it is right, production issues will be hard to diagnose.
What to do
- Adopt pino (or winston) and log at meaningful points in the services you run.
- Consider OpenTelemetry tracing/metrics (@opentelemetry/sdk-node) and a health-check endpoint (@godaddy/terminus or a /health route) for operability.
P3 · Security & performance tooling
- No static application security testing detected. For this repository's stack, add CodeQL's javascript-typescript pack, `semgrep --config=p/typescript`, or eslint-plugin-security — this repository has no CI pipeline yet, so run it locally to clear the existing findings, then make it a step of the first workflow you add so a regression fails the build. What was searched, so you can tell an absence from a miss: the 0 CI workflow file(s) in this repository, and the scanner and linter configuration checked in beside them. A scan that runs outside CI, one configured in your forge's web UI rather than in a committed file, or a tool whose name is none of those this check carries, is not seen — if that is your case the row is wrong, and saying so is more useful than adding a second scanner.
What to do
- Run what this repository's stack ships: CodeQL's javascript-typescript pack, `semgrep --config=p/typescript`, or eslint-plugin-security — locally for now, since there is no CI pipeline here yet, and as a step of the first workflow you add so a security regression fails the build instead of landing.
- Enable Dependabot/Renovate or a dependency-review gate.
- Add gitleaks/trufflehog in CI to block PRs that introduce committed secrets.
P4 · Deployment & Rollback
- Deployment is orchestrated by compose, but no service declares a `healthcheck:` and nothing pins a previous image to fall back to — the runtime can tell that the container is up, not that it is serving, so a bad release is harder to detect and reverse.
What to do
- Add a `healthcheck:` to the served compose service — probing the endpoint it already answers on where it has one — with `depends_on: condition: service_healthy` on whatever waits for it, and keep the deployed image tag immutable and recorded so rolling back is re-pointing at the previous tag rather than rebuilding.
- Add an approval/environment gate (required reviewers / protection rules) before production promotion.
PF3 · Async & latency hygiene
R1 · Type Safety
R10 · Code Duplication
- 13 duplicated blocks under the repository root have copies in at least two of the sibling directories auth-service, chat-service, ecom-service, home-service — 9 of them are reported below, and 4 are counted here but not reported individually: those copies match on shape but no longer clear R10's bar for an individually reported row — either they kept neither their own names nor their values, or what was copied is too small to stand on its own (it reports near-exact duplication only, and only of substantial extent). What this row states is the concentration, which the detector measured over all 13 and which does not depend on how exactly each block's copies still match. That concentration is one structural fact, not 13 local ones: the siblings replicate behaviour none of them owns, which is the shape of a missing shared module — a common library every sibling imports — rather than 13 separate extractions. Check first whether the siblings are deliberately standalone deliverables (scaffold templates, demo apps that must stay copy-pasteable); where they are, the duplication is the design and the per-block rows are the ones to act on. — chat-service/src/api/middlewares/index.ts:5
- chat-service/src/api/middlewares/index.ts:5 · home-service/src/api/middlewares/index.ts:5 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — chat-service/src/api/middlewares/index.ts:5
- home-service/src/modules/base/repository/index.ts:15 · home-service/src/modules/base/services/index.ts:12 — the two spans are one implementation copied and then locally edited — 280 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — home-service/src/modules/base/repository/index.ts:15
- chat-service/src/message-queue/index.ts:5 · home-service/src/message-queue/index.ts:5 — the two spans are one implementation copied and then locally edited — 212 tokens are still identical, in the same order in both files, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — chat-service/src/message-queue/index.ts:5
- REDACTED:10 · REDACTED:10 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — REDACTED:10
- REDACTED:12 · REDACTED:14 · REDACTED:14 — the 3 copies are spread across 3 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. There is one copy in each of 3 separate files rather than several in one place, so check first whether these are sibling modules that each declare their own version of one shape — one per entity, per provider, per language. Where they are, no single extracted module collapses them: each module still has to be written, and what recurs is the TEMPLATE. The moves that do collapse a template are to generate these modules from the set they enumerate, or to replace the repeated construction with one factory each site calls with its own values — and where the set is the point, each module pinning one distinct thing, the repetition IS the enumeration and there is nothing to delete. — REDACTED:12
- auth-service/src/api/middlewares/index.ts:18 · ecom-service/src/api/middlewares/index.ts:8 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — auth-service/src/api/middlewares/index.ts:18
- auth-service/src/models/provider.ts:7 · ecom-service/src/models/provider.ts:9 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — auth-service/src/models/provider.ts:7
- auth-service/src/api/middlewares/index.ts:52 · home-service/src/api/middlewares/index.ts:60 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — auth-service/src/api/middlewares/index.ts:52
- chat-service/src/modules/dual-conversation/services/index.ts:32 · chat-service/src/modules/group-conversation/services/index.ts:93 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — chat-service/src/modules/dual-conversation/services/index.ts:32
- chat-service/src/modules/dual-conversation/services/index.ts:56 · chat-service/src/modules/group-conversation/services/index.ts:118 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — chat-service/src/modules/dual-conversation/services/index.ts:56
- home-service/src/modules/post-log/controllers/rest.ts:4 · home-service/src/modules/user/controllers/rest.ts:4 — the 2 copies are spread across 2 files, and the CITED SPAN is a run of MODULE-LEVEL DECLARATIONS — bindings the module declares and exports — rather than statements with a call site. Do not read this as an extract-a-helper row: a call expression cannot stand where a declaration was, and putting one there would delete the names themselves, which are what the rest of the codebase imports. What actually repeats here is the INITIALISER — the same expression shape written once per binding. So give that expression one name (a small helper the initialisers call, or a shared base value they are each derived from) and keep every binding under the name it already has. Where the run is an enumeration — one binding per distinct thing, differing precisely in the thing each one names — the repetition IS the enumeration and collapsing it would delete entries; consider instead whether the set belongs in one exported table the individual names are read out of. Reported because the copies drift apart the first time only one of them is edited. — home-service/src/modules/post-log/controllers/rest.ts:4
- chat-service/src/modules/dual-conversation/services/index.ts:9 · chat-service/src/modules/group-conversation/services/index.ts:71 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — chat-service/src/modules/dual-conversation/services/index.ts:9
- auth-service/src/message-queue/chat-queue.ts:4 · auth-service/src/message-queue/home-queue.ts:4 — the 2 copies are spread across 2 files, and the SHAPE of this repetition could not be determined. It is not a run of declarations, a listing, a declaration header, a type body or a slice through a construct — and it was not measured as a run of executable statements either, so this row cannot tell you whether a function can stand where these lines are. Read the two spans before acting, because the move is opposite in the two cases. Where they are statements, the ordinary answer holds: give the shared part one home and call it from each site. Where they turn out to be declarations, a literal's entries, or the cases of an enumeration, there is no call site to call anything from, and collapsing them would delete what each copy pins — a shared base type, a generated set, or one exported constant each site refers to is the move instead, and sometimes the honest answer is that there is nothing to extract at all. Reported because the copies drift apart the first time only one of them is edited, which is true whichever of those they are. — auth-service/src/message-queue/chat-queue.ts:4
- home-service/src/models/post.model.ts:53 · home-service/src/models/user.model.ts:42 — the 2 copies are spread across 2 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — home-service/src/models/post.model.ts:53
- home-service/src/modules/comment/controllers/rest.ts:12 · home-service/src/modules/user/controllers/rest.ts:16 — the 2 copies are spread across 2 files, and the CITED SPAN is a run of MODULE-LEVEL DECLARATIONS — bindings the module declares and exports — rather than statements with a call site. Do not read this as an extract-a-helper row: a call expression cannot stand where a declaration was, and putting one there would delete the names themselves, which are what the rest of the codebase imports. What actually repeats here is the INITIALISER — the same expression shape written once per binding. So give that expression one name (a small helper the initialisers call, or a shared base value they are each derived from) and keep every binding under the name it already has. Where the run is an enumeration — one binding per distinct thing, differing precisely in the thing each one names — the repetition IS the enumeration and collapsing it would delete entries; consider instead whether the set belongs in one exported table the individual names are read out of. Reported because the copies drift apart the first time only one of them is edited. — home-service/src/modules/comment/controllers/rest.ts:12
- chat-service/src/loaders/db-connection.ts:5 · home-service/src/loaders/db-connection.ts:5 — the 2 copies are spread across 2 directories, so the shared home is a decision rather than an obvious spot: check first whether one of them already owns this behaviour, and otherwise put the extracted module somewhere all of the sites already reach rather than making one of them depend on another. — chat-service/src/loaders/db-connection.ts:5
- chat-service/src/modules/user/controllers/rest.ts:24 · chat-service/src/modules/user/controllers/rest.ts:41 — all 2 copies are in the same file, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — chat-service/src/modules/user/controllers/rest.ts:24
- auth-service/src/modules/auth/controllers/rest.ts:21 · home-service/src/modules/comment/controllers/rest.ts:15 · home-service/src/modules/post/controllers/rest.ts:58 · home-service/src/modules/user/controllers/rest.ts:19 — the 4 copies are spread across 4 files, and the CITED SPAN is not a self-contained block — it runs from inside one construct into the next (the tail of a branch plus the head of the following one, a run of switch arms, the end of a declaration plus the list that follows it) rather than covering a whole unit. So do not lift these lines literally: no call can be substituted for a half-open construct. Extract the enclosing repeated UNIT instead — the whole function, component or branch these lines sit in — and where the repetition IS the construct (a run of switch arms, a stack of near-identical declarations) replace it with one table or registry looked up by key rather than a helper each arm calls. The copies still drift apart the first time only one of them is edited, which is why this is reported. — auth-service/src/modules/auth/controllers/rest.ts:21
- home-service/src/modules/post/services/index.ts:79 · home-service/src/modules/post/services/index.ts:101 — the two spans are one implementation copied and then locally edited — 62 tokens are still identical, in the same order in both spans, with only local edits between them. The copies have already begun to drift, which is this row's finding: an edit made to one and not the other changes behaviour silently. Diff the two spans first to learn what genuinely differs, then extract the shared core into one module both sites use, passing the differences in as parameters — or, if one copy exists only because the other could not be imported from its context, make one of them the single source the other is generated or re-exported from. If one copy is no longer reachable, delete it rather than letting it shadow the live one. — home-service/src/modules/post/services/index.ts:79
What to do
- Act on each finding's own remediation rather than one rule: the move depends on what recurs. Where the copies are executable blocks, give the shared part one home and call it from each site; where they are declarations, a listing, a specialisation already delegating to its base, or one shape repeated per entity, there is no call site and the move is a shared type, a generated set or a factory — sometimes there is nothing to extract.
R2 · Cyclomatic Complexity
- secureUpdateOrDelete has cyclomatic complexity 12 and cognitive complexity 9; this row is raised above a cyclomatic bar of 10. The two numbers answer different questions and the gap between them is what decides whether to act: cyclomatic counts the independent arms through the body, cognitive counts what it costs to hold them in your head, so nesting and mixed boolean chains raise it while a flat run of independent arms does not. Cognitive sits below cyclomatic here, so much of the count is breadth — arms side by side rather than stacked — and splitting per arm would leave a function per arm; group the work between the checks into named steps instead. Measured by this repository's own parse of the file, so a body assembled at runtime, or generated, is counted as written rather than as it executes. (×2) — auth-service/src/api/middlewares/index.ts:52, home-service/src/api/middlewares/index.ts:60
R3 · Large Files
R4 · Test Coverage
- No test imports this module directly or transitively. Import reachability cannot see a test that executes a file by path instead of importing it, nor one that drives it through a running browser by navigating to a URL — if neither does, no test reaches this one. (×40) — chat-service/src/modules/group-conversation/services/index.ts:1, auth-service/src/modules/auth/services/index.ts:1, auth-service/src/models/user.model.ts:1, …
What to do
- Add tests that import the unreached modules (directly or through their public entry).
R5 · Dependency Freshness
What to do
- Bump outdated dependencies to current versions to limit upgrade debt.
R6 · Tooling
- test ✓ · lint ✗ · typecheck ✗ — read from this repository's package.json scripts and corroborated against its CI workflows. A script counts when its name or command matches the step: `test` for the suite, `lint` or `prettier` for linting, `typecheck`/`type-check`/`tsc` for type checking. ✗ therefore means no script or CI step under those names was found, NOT that the step is absent from your pipeline — a task invoked by a runner this check does not read, or named something else entirely, is not seen and is worth confirming before acting on a cross. A ✓ means the wiring is DECLARED — a script or CI step under those names exists. It is not a statement that the step passes, or that it runs at all: nothing here installs a dependency or executes a suite.
What to do
- Add eslint and `tsc --noEmit` as package.json scripts and run them in CI.
R7 · Dead Code
- Unreachable from the 5 application, 0 tooling and 2 test entry point(s) detected in this repo. Nothing this repository declares compiles or type-checks these files, so a wrong deletion here would raise no compile error — gate removals on `npm test`, which loads the modules, and note that it only covers what it exercises. An undetected custom entry would make these reachable.
- no import path from any entry point (5 application, 0 tooling, 2 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (chat-service/src/modules/group-conversation/controllers/rest.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — chat-service/src/modules/group-conversation/services/index.ts
- no import path from any entry point (5 application, 0 tooling, 2 test roots considered), and no other file in the scanned tree imports it — nothing in-repo names this module at all, which is the strongest form of this claim the import graph can make (×24) — ecom-service/src/models/discount.model.ts, ecom-service/src/models/inventory.model.ts, home-service/src/modules/post-log/controllers/rest.ts, …
- no import path from any entry point (5 application, 0 tooling, 2 test roots considered), but 1 in-repo import(s) from 1 other file(s) do name it (ecom-service/src/message-queue/index.ts) — every one of those referrers is itself unreachable, so this file is dead only as a member of that cluster: if any referrer is in fact alive, this row falls with it — ecom-service/src/utils/constants/index.ts
- Nothing imports this binding — it is safe to review for removal. (×6) — auth-service/src/utils/enums/index.ts:7, chat-service/src/loaders/db-connection.ts:20, chat-service/src/loaders/socket-io.ts:30, …
What to do
- Delete the dead files and unused exports — every line is maintenance cost and rebuild-estimate inflation with zero runtime value.
R8 · Dependency Hygiene
- Imported but not declared in any reachable package.json — installs work only by hoisting accident. (×5) — api-gateway/src/index.ts:2, REDACTED:2, REDACTED:2, …
- Only test files import it (first: home-service/test/workflow.test.ts:2) — move it to devDependencies. — home-service/package.json:15
What to do
- Remove unused dependencies, declare unlisted imports explicitly, and demote type-/test-only packages to devDependencies.
R9 · Circular Imports
- home-service/src/models/post-log.model.ts → home-service/src/models/post.model.ts → home-service/src/models/post-log.model.ts — home-service/src/models/post-log.model.ts:2
What to do
- Break each cycle by extracting the shared piece into a module both sides can import.
S1 · Web-Security Posture
- `secret` is the token-signing key and is a compile-time constant, so the secret this operation depends on is published with the source. A key that ships with the source is not secret: every contributor, fork, mirror and released binary carries it, so anyone holding the repository can decrypt what any installation encrypted, and there is no way to invalidate what was already protected because every deployment built from this source shares the value. Where the constant is a password salt the consequence differs but is no smaller — one global salt means precomputation amortises across every installation, which is the property salting exists to destroy. Read the value from configuration, an environment variable or a secrets manager at startup and FAIL FAST when it is absent, so a missing key stops the process instead of silently falling back to a shared default; treat the committed value as disclosed and rotate it rather than only deleting the line. For a salt, generate a fresh random one per password and store it alongside the hash. (×3) — REDACTED:3, REDACTED:3, REDACTED:3
- `app.listen(…)` serves plain HTTP on a network address, and nothing in its package enforces HTTPS: no TLS served (`https.createServer`, Fastify `https`, Nest `httpsOptions`), no redirect of plain requests to `https://`, no `Strict-Transport-Security` (helmet sends it by default), and no TLS-terminating proxy configuration committed beside it — so a browser may talk to it in clear text. (−2.0 on this card.) (×5) — api-gateway/src/index.ts:20, REDACTED:28, REDACTED:31, …
What to do
- Load cryptographic key and salt material from configuration, an environment variable or a secrets manager rather than fixing it in the source, and fail fast at startup when it is absent — a default that silently works is the one that reaches production. Rotate anything already committed: it must be treated as disclosed. Salts should be generated per password and stored with the hash, never shared across installations. This repository constructs key or salt material fixed at compile time at 3 sites, not one: `REDACTED:3` (token-signing key, `secret`), `REDACTED:3` (token-signing key, `secret`), `REDACTED:3` (token-signing key, `secret`). Each is a separate decision — fixing only the line this row cites leaves the others in place.
- Enforce HTTPS on each listed server: serve TLS itself, or redirect plain requests to `https://` and send `Strict-Transport-Security` (`helmet()` does by default) behind the TLS-terminating proxy — and commit that proxy's configuration beside the service. A server only this machine reaches should bind `127.0.0.1`.
X1 · Async correctness
X12 · Unreachable branch
X13 · Undrained process stream
X14 · Bypassable address classification
X15 · Unvalidated length from an untrusted reader
X16 · Unfloored truncation loop
X17 · Uncapped recursion over a caller-supplied document
X18 · Disposal-pattern correctness
X19 · Unrestored process-global state
X21 · Side-effecting pattern guard
X22 · Contradicted release guard
X23 · Unguarded diagnostic materialisation
X24 · Document value interpolated into markup unescaped
X25 · Inert configuration knob
X28 · Index access outside its own emptiness guard
X29 · Per-element action decided by a fixed element
X3 · Exception handling
X30 · Support guard that admits what it rejects
X5 · Nullable reference types
Reference — by lens
| Lens | Score | Rating | Impact |
|---|---|---|---|
| Code Health | 82% | Strong | Solid. |
| Architecture | 84% | Strong | Solid. |
| Maturity | 47% | Weak — gated by D34, M2 | Capped at Fair by a Critical contributor — resolve it before relying on this lens. |
| Readiness | 15% | Critical — gated by R4, R6, R8, P1, P2, P3 | Capped at Fair by a Critical contributor — resolve it before relying on this lens. |
| Security | 38% | Weak — gated by D29, D30, C1 | Capped at Fair by a Critical contributor — resolve it before relying on this lens. |
| Performance | 100% | Exemplary | Strongest area. |
Unscored — 1 check(s) recorded observations but carry no score
- X10 Duplicated predicate — 4 observation(s) recorded · Advisory — this card reports evidence and never carries a score.
Not evidenced — 5 control(s) we could not find positive evidence for
- C3 Audit Trail — Repo shows no audit-logging mechanism (an audit-log table or model, an ORM write hook that records changes — a TypeORM/MikroORM subscriber, a Sequelize or Mongoose hook, Prisma middleware — or a change-history plugin such as mongoose-history or sequelize-paper-trail) for sensitive changes — absence of evidence is not evidence of a working control. Record an audit trail in code (or document where it lives) so this dimension can be scored.
- C4 Data Retention — Repo shows no data-retention / TTL / cleanup mechanism for personal data — absence of evidence is not evidence of a working control. Define retention periods and a purge/cleanup job (or TTL) in code, or document where retention is enforced, so this dimension can be scored.
- C5 Data-Subject Rights — Repo shows no corroborated data-subject-rights mechanism (erasure / export-portability / consent) tied to a subject id or GDPR vocabulary — absence of evidence is not evidence of a working control. Implement erasure, data export/portability and consent tracking over the subject's records.
- P5 DR & Backup — not evidenced — repo shows no backup/RTO/RPO controls; absence of evidence is not evidence of a working control
- P6 Release Hygiene — not evidenced — no changelog, version stamp or semver release tag in the repo
Not included — 62 check(s) not relevant to this codebase
- AC1 Text alternatives — No web markup found — accessibility is not applicable to this repository.
- AC2 Forms & labels — No web markup found — accessibility is not applicable to this repository.
- AC3 Page structure — No web markup found — accessibility is not applicable to this repository.
- AC4 Keyboard semantics — No web markup found — accessibility is not applicable to this repository.
- AC5 ARIA correctness — No web markup found — accessibility is not applicable to this repository.
- AC6 Visual & motion safety — No web markup found — accessibility is not applicable to this repository.
- AC7 A11y enforcement — No web markup found — accessibility is not applicable to this repository.
- AX1 Captive dependencies — Not applicable: this repository's TypeScript imports no dependency-injection container and defines no container of its own — nothing that both registers and resolves bindings, and nothing that names two lifetimes — so nothing holds one lifetime's instance while handing out another's.
- AX2 Stateful singletons — Not applicable: TypeScript/JavaScript runs each process's requests on one event loop, so no two requests write a shared object at the same instant (interleaving across an await is a different defect).
- AX5 Architecture & structure — not assessed — architecture style/structure is computed from a project graph (projects, types, module namespaces) that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- AX7 Slice cohesion — not applicable — not a vertical-slice architecture
- AX8 Test isolation — no test/production split to check
- AX9 CQS / query purity — no CQRS query handlers detected — query purity is not applicable to this codebase
- AXB2 Runtime readiness — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
- AXR1 Runtime accessibility — compose up failed (exit 17 — an image could not be built) — failed to solve: node:alpine: failed to resolve source metadata for docker.io/library/node:alpine: failed to do request: Head "https://registry-1.docker.io/v2/library/node/manifests/alpine": Forbidden; runtime evidence skipped This is a statement about this run, not a statement about your application: nothing here says the surface is inaccessible, only that it was never rendered.
- D11 Test Reliability — Test reliability not included — the test command names no runner the analyzer recognises
- D16 Bus Factor — single-maintainer repository — bus factor is not applicable
- D18 Solution Shape — D18 scores the shape of a .NET solution; this repository has no .NET solution or project files, so the dimension does not apply.
- D22 Internal API Consistency — The exposed public-API surface could not be collected — no C#/VB projects loaded.
- D23 Boundary Type-Coupling — No bounded-context organisation was detected either — neither a context-shaped layout, nor 2+ sibling source directories each declaring an aggregate root, nor 2+ projects each declaring an entity of their own. Declaring this codebase's bounded contexts (≥2) would let cross-boundary type coupling be assessed. Declare them in `.codehealth/config.yaml` at the repository root (create it if absent), mapping each context name to the module-path or namespace prefixes that belong to it — e.g. `architecture:` → `contexts:` → `Billing: ["src/billing", "Acme.Billing"]`, `Catalog: ["src/catalog", "Acme.Catalog"]`.
- D24 Comment Value — No inline comments to assess — comment value is not applicable here.
- D25 ADR Conformance — no ADRs to check
- D27 Navigability — D27 counts a call into the standard library or a dependency as unresolved for this repository's language (.ts), so too few call sites counted as resolved to assess navigability. Not scored: this is a gap in the analyzer, not a verdict about this repository.
- D32 Data Compliance (PII/GDPR) — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that.
- D36 Supply-chain Provenance & Signing — No CI/build pipeline found (.github/.forgejo/.gitea workflows, .circleci, .buildkite, .woodpecker, .teamcity, .gitlab-ci.yml, .travis.yml, bitbucket-pipelines.yml, .drone.yml, .cirrus.yml, .woodpecker.yml, appveyor.yml, azure-pipelines*.yml, .pipelines/, .vsts-ci/, .azuredevops/, Jenkinsfile); there is no build to attest provenance for.
- D37 Vulnerability-disclosure Policy — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed.
- D39 IL Efficiency — D39 measures the IL emitted by a .NET build; this repository has no .NET solution or project files, so the dimension does not apply.
- D4 Code Duplication — This repository's production source (.ts) is not read by D4's token comparison, which compares .NET source: duplication in it is measured by R10 Code Duplication, the frontend lens's card running the same clone algorithm over the JS/TS token stream. Not scored here — read the R10 card for this repository's duplication.
- D40 Network Egress Confinement — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here.
- D41 Kernel & Syscall Confinement — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here.
- D42 Runtime Threat Enforcement — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here.
- D44 Platform End-of-Life — Platform end-of-life not assessed — this repository declares no platform this pass reads
- D7 Architectural Integrity — no checkable ADRs, and no project-reference graph for the cycle pass to read — so this dimension makes no claim about dependency cycles in either direction (where this repository's language has an import-cycle lens, cycles are reported there). Architectural integrity not assessed
- D8 Code Coverage — Coverage not measured — the test command names no runner the analyzer recognises
- DM1 Aggregate boundaries — not applicable: no DDD domain layer was detected (no aggregate, entity or value-object structure), so there is no domain model for this card to grade
- DM10 One transaction, one aggregate — not applicable: no DDD domain layer was detected (no aggregate, entity or value-object structure), so there is no domain model for this card to grade
- DM2 Strongly-typed ids — not applicable: no DDD domain layer was detected (no aggregate, entity or value-object structure), so there is no domain model for this card to grade
- DM3 Integration-event coupling — not applicable: no DDD domain layer was detected (no aggregate, entity or value-object structure), so there is no domain model for this card to grade
- DM4 Rich vs anemic model — not applicable: no DDD domain layer was detected (no aggregate, entity or value-object structure), so there is no domain model for this card to grade
- DM5 Encapsulated state — not applicable: no DDD domain layer was detected (no aggregate, entity or value-object structure), so there is no domain model for this card to grade
- DM6 Domain ↔ infrastructure boundary — this TypeScript/JavaScript repository maps no type to a persistence framework (TypeORM/Prisma/MikroORM/Sequelize/Mongoose), so DM6's domain↔infrastructure fusion read has no population to be taken over
- DM7 Repository granularity — not applicable: no DDD domain layer was detected (no aggregate, entity or value-object structure), so there is no domain model for this card to grade
- ED1 Event-Driven — not scored — this repository shows none of the 3 signals this lens looks for
- ED5 Idempotency — no mutating command handlers or message consumers detected — idempotency check not applicable
- ES1 Event Sourcing — not scored — this repository shows none of the 3 signals this lens looks for
- P12 CI test-gate honesty — no CI workflow found
- P7 Outbound HTTP resilience — no outbound HTTP usage detected — no HTTP client call or construction in the JavaScript/TypeScript source (service entry point: api-gateway/src/index.ts:10 (express()))
- P8 Schema migrations — Sequelize is declared, but the schema-migration mechanism could not be identified. Our limit, not a verdict on this repository.
- P9 Domain vs controller coverage — no coverage report found on disk — produce a coverage report in a standard format (lcov — `vitest --coverage`, `jest --coverage`, `bun test --coverage --coverage-reporter=lcov`, or `nyc`) and commit it — a hosted scan measures a clone of the repository, so a report that exists only in a working tree, a CI runner's or your own, never reaches it; the artefact is commonly gitignored, so `git add -f` that one file (or un-ignore its path) and commit it alongside the code it measures, or wire coverage collection into CI, to enable this cross-layer check
- PF1 Benchmark discipline — Not applicable: no benchmark suite was found. This check searched for tinybench, mitata, benchmark.js, benny or vitest `bench(...)` calls in files that import them (or `*.bench.*` files), or one of those in a package.json, and for a `*benchmark*` script that this repository's CI runs. Benchmarks are credited as a bonus, so their absence is neither scored nor deducted.
- PF2 Allocation hygiene — Not applicable: TypeScript/JavaScript runs on a garbage-collected runtime that gives a program no allocation-control idiom to choose on a hot path — no pools, stack allocation or value types — so allocation awareness is not something this code can be rated on.
- R11 Import Boundaries — No recognizable feature-sliced/layered src layout — boundary rules not applicable.
- SC1 Supply-chain hygiene — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
- X2 Cancellation propagation — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X20 Mistyped argument guard — This check asks whether an argument guard reports an EMPTY value as a NULL one, which needs a language that throws a null-specific argument exception — .NET's ArgumentNullException, the JVM's NullPointerException, Dart's ArgumentError.notNull. This repository contains none of those languages: the ones it is written in have a single exception for a bad argument, so there is no pair of exceptions to confuse and nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
- X26 Unsynchronised callback handoff — Not applicable: this check looks for a collection written by a callback on one thread while the body waiting on it touches it on another, and in this repository's languages no collection is reachable from two threads at once. TypeScript/JavaScript runs every callback on the one thread that owns its objects: a callback runs only when the body waiting on it has yielded, never alongside it, and a worker thread receives a COPY of what it is sent. A SharedArrayBuffer carries raw bytes, never an Array, Map or Set, so no collection is reachable from two threads at once. Not a gap in the analyzer and not a finding about your code.
- X27 Collection changed while being enumerated — Not applicable: this check looks for a loop whose body adds to or removes from the very collection the loop is walking, invalidating the enumerator it holds, and in this repository's languages that cannot happen. JavaScript and TypeScript have no iterator that a change can invalidate: an `Array` is walked by index against its live length, and a `Map` or `Set` by the ECMAScript specification's live entry list, so a body that adds to, removes from or empties what it walks raises nothing — every loop form (`for…of`, `for…in`, `forEach`, `map`, `filter`, `reduce`, `entries()`) on every built-in collection (`Array`, `Map`, `Set`, plain objects, `URLSearchParams`, `Headers`, `FormData`) runs to completion. Such a loop can still skip an element or never end, which is a different defect and not the one this check asks about. Not a gap in the analyzer and not a finding about your code.
- X32 Type resolved by simple name across every loaded assembly — This check is about how a .NET program searches the assemblies loaded into its process for a type, and this repository contains no .NET source, so there is nothing here for it to assess. Not a gap in the analyzer and not a finding about your code.
- X4 Structured logging — not analysed — these correctness checks read a source model that was not loaded for this repository, because the repository is written in a language this check does not yet model, or because its projects failed to load. This is a gap in the analyzer, not a finding about this repository
- X6 Hand-rolled structured-format parsing — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
- X7 Silent fallback defaults — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
- X9 Subsumed condition operand — Advisory — this card reports evidence and never carries a score, so there is nothing missing here.
Appendix A — Findings (grouped)
Critical — 43 finding(s)
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- Unlisted import 'body-parser' api-gateway/src/index.ts:2
- Unlisted import 'body-parser' REDACTED:2
- Unlisted import 'body-parser' REDACTED:2
- Unlisted import 'body-parser' ecom-service/src/index.ts:2
- Unlisted import 'body-parser' REDACTED:2
- Cryptographic key material is a compile-time constant REDACTED:3
- Cryptographic key material is a compile-time constant REDACTED:3
- Cryptographic key material is a compile-time constant REDACTED:3
- REDACTED
- REDACTED
- REDACTED
- Import cycle (2 files) home-service/src/models/post-log.model.ts:2
Serious — 141 finding(s)
- No test reaches this file chat-service/src/modules/group-conversation/services/index.ts:1
- No test reaches this file auth-service/src/modules/auth/services/index.ts:1
- No test reaches this file auth-service/src/models/user.model.ts:1
- No test reaches this file chat-service/src/modules/dual-conversation/services/index.ts:1
- No test reaches this file ecom-service/src/models/product.model.ts:1
- No test reaches this file auth-service/src/api/middlewares/index.ts:1
- No test reaches this file home-service/src/modules/post/controllers/rest.ts:1
- No test reaches this file chat-service/src/modules/user/repository/index.ts:1
- No test reaches this file home-service/src/message-queue/index.ts:1
- No test reaches this file chat-service/src/api/middlewares/index.ts:1
- No test reaches this file chat-service/src/modules/user/controllers/rest.ts:1
- No test reaches this file ecom-service/src/models/discount.model.ts:1
- No test reaches this file REDACTED:1
- No test reaches this file auth-service/src/message-queue/index.ts:1
- No test reaches this file REDACTED:1
- No test reaches this file REDACTED:1
- No test reaches this file auth-service/src/models/user-role.model.ts:1
- No test reaches this file chat-service/src/modules/user/services/index.ts:1
- No test reaches this file chat-service/src/message-queue/index.ts:1
- No test reaches this file ecom-service/src/models/cart.model.ts:1
- No test reaches this file chat-service/src/models/conversation.model.ts:1
- No test reaches this file ecom-service/src/models/provider.ts:1
- No test reaches this file ecom-service/src/api/middlewares/index.ts:1
- No test reaches this file ecom-service/src/models/category.model.ts:1
- No test reaches this file ecom-service/src/modules/category/repository/index.ts:1
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- Dead file (~0 LoC) api-gateway/src/api/routes/index.ts
- Dead file (~0 LoC) api-gateway/src/config/index.ts
- Dead file (~0 LoC) api-gateway/src/loaders/index.ts
- Dead file (~0 LoC) api-gateway/src/utils/constants/index.ts
- Dead file (~0 LoC) api-gateway/src/utils/helpers/index.ts
- Dead file (~0 LoC) auth-service/src/jobs/index.ts
- Dead file (~0 LoC) auth-service/src/modules/auth/controllers/grpc.ts
- Dead file (~0 LoC) auth-service/src/subscribers/index.ts
- Dead file (~0 LoC) auth-service/src/utils/helpers/index.ts
- Dead file (~0 LoC) ecom-service/src/modules/cart/controllers/rest.ts
- Dead file (~0 LoC) ecom-service/src/modules/cart/repository/index.ts
- Dead file (~0 LoC) ecom-service/src/modules/cart/services/index.ts
- Dead file (~0 LoC) ecom-service/src/modules/user/controllers/rest.ts
- Dead file (~0 LoC) ecom-service/src/modules/user/repository/index.ts
- Dead file (~0 LoC) ecom-service/src/modules/user/services/index.ts
- Dead file (~0 LoC) ecom-service/src/utils/helpers/index.ts
- Dead file (~0 LoC) home-service/src/modules/base/controllers/rest.ts
- Dead file (~0 LoC) home-service/src/utils/helpers/index.ts
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- Deprecated: @types/http-proxy-middleware api-gateway/package.json:19
- Deprecated: @types/mongoose chat-service/package.json:25
- Deprecated: @types/socket.io chat-service/package.json:28
- Fake-async — async method never awaits auth-service/src/message-queue/index.ts:11
- Fake-async — async method never awaits auth-service/src/message-queue/index.ts:17
- Fake-async — async method never awaits auth-service/src/message-queue/index.ts:23
- Duplicated block (15 lines × 2 locations) auth-service/src/message-queue/chat-queue.ts:4
- Duplicated block (15 lines × 2 locations) home-service/src/models/post.model.ts:53
- Duplicated block (15 lines × 2 locations) home-service/src/modules/comment/controllers/rest.ts:12
- TodoComment REDACTED:23
- TodoComment chat-service/src/modules/user/repository/index.ts:12
- REDACTED
- REDACTED
- Duplicated block (24 lines × 2 locations) auth-service/src/api/middlewares/index.ts:18
- Duplicated block (24 lines × 2 locations) auth-service/src/models/provider.ts:7
- Duplicated block (8 lines × 2 locations) chat-service/src/loaders/db-connection.ts:5
- Duplicated block (8 lines × 2 locations) chat-service/src/modules/user/controllers/rest.ts:24
- Complex function secureUpdateOrDelete (cyclomatic 12, cognitive 9) auth-service/src/api/middlewares/index.ts:52
- Complex function secureUpdateOrDelete (cyclomatic 12, cognitive 9) home-service/src/api/middlewares/index.ts:60
- Dead file (~6 LoC) ecom-service/src/message-queue/index.ts
- Dead file (~6 LoC) ecom-service/src/utils/enums/index.ts
- No CI pipeline
- No structured logging
- Duplication concentrated across 4 sibling directories (13 clone groups) chat-service/src/api/middlewares/index.ts:5
- Duplicated block (38 lines × 2 locations) chat-service/src/api/middlewares/index.ts:5
- Duplicated block with local edits (34 matched lines × 2 locations) home-service/src/modules/base/repository/index.ts:15
- Duplicated block with local edits (27 matched lines × 2 locations) chat-service/src/message-queue/index.ts:5
- Duplicated block (26 lines × 2 locations) REDACTED:10
- Duplicated block (25 lines × 3 locations) REDACTED:12
- Duplicated block (22 lines × 2 locations) auth-service/src/api/middlewares/index.ts:52
- Duplicated block (21 lines × 2 locations) chat-service/src/modules/dual-conversation/services/index.ts:32
- Duplicated block (19 lines × 2 locations) chat-service/src/modules/dual-conversation/services/index.ts:56
- Duplicated block (17 lines × 2 locations) home-service/src/modules/post-log/controllers/rest.ts:4
- Duplicated block (16 lines × 2 locations) chat-service/src/modules/dual-conversation/services/index.ts:9
- Duplicated block (7 lines × 4 locations) auth-service/src/modules/auth/controllers/rest.ts:21
- Duplicated block with local edits (7 matched lines × 2 locations) home-service/src/modules/post/services/index.ts:79
- No lint or typecheck script
- Dead file (~144 LoC) chat-service/src/modules/group-conversation/services/index.ts
- Dead file (~48 LoC) ecom-service/src/models/discount.model.ts
- Dead file (~34 LoC) ecom-service/src/models/inventory.model.ts
- Dead file (~26 LoC) home-service/src/modules/post-log/controllers/rest.ts
- Dead file (~8 LoC) ecom-service/src/utils/constants/index.ts
- Dead file (~3 LoC) chat-service/src/modules/group-conversation/controllers/rest.ts
Minor — 42 finding(s)
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- REDACTED
- Orphaned file chat-service/src/modules/group-conversation/services/index.ts:1
- Orphaned file home-service/src/modules/post/services/index.ts:1
- Orphaned file auth-service/src/modules/auth/services/index.ts:1
- Orphaned file auth-service/src/models/user.model.ts:1
- Orphaned file home-service/src/api/middlewares/index.ts:1
- Orphaned file chat-service/src/modules/dual-conversation/services/index.ts:1
- No app-layer HTTPS enforcement detected api-gateway/src/index.ts:20
- No app-layer HTTPS enforcement detected REDACTED:28
- No app-layer HTTPS enforcement detected REDACTED:31
- No app-layer HTTPS enforcement detected ecom-service/src/index.ts:14
- No app-layer HTTPS enforcement detected REDACTED:29
- Duplicated predicate auth-service/src/api/middlewares/index.ts:60
- Duplicated predicate auth-service/src/api/middlewares/index.ts:64
- Duplicated predicate chat-service/src/message-queue/index.ts:31
- Duplicated predicate chat-service/src/message-queue/index.ts:23
- Outdated (npm): bullmq auth-service/package.json:14
- Outdated (npm): mongoose chat-service/package.json:18
- REDACTED
- REDACTED
- Unused export 'default' chat-service/src/loaders/db-connection.ts:20
- Unused export 'default' chat-service/src/loaders/socket-io.ts:30
- No named authorization policies
- No ADRs found
- Orphaned files with no living knowledge
- No ADRs
- No architecture diagram/doc
- README/code drift README.md:3
- No SAST
- No rollback/health safety
- Unused export 'Gender' auth-service/src/utils/enums/index.ts:7
- Unused export 'routeNotFoundHandler' ecom-service/src/api/middlewares/index.ts:4
- Unused export 'authenticate' ecom-service/src/api/middlewares/index.ts:22
- Unused export 'secureUpdateOrDelete' home-service/src/api/middlewares/index.ts:60
- Test-only dependency 'chai' in production deps home-service/package.json:15
Minor — 11 finding(s)
- Outdated (npm): bcrypt
- Outdated (npm): chai
- Outdated (npm): cors
- Outdated (npm): dotenv
- Outdated (npm): express
- Outdated (npm): http-proxy-middleware
- Outdated (npm): jsonwebtoken
- Outdated (npm): morgan
- Outdated (npm): mysql2
- Outdated (npm): sequelize
- Outdated (npm): socket.io
Appendix B — Reproduction & audit trail
| Dimension | Tool | Version | Command | Findings | Raw output |
|---|---|---|---|---|---|
| D28 · Secrets (history) | gitleaks | — | gitleaks detect --no-banner --config /opt/gitleaks-rules/watchdog-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-bc61ba57c80c49eb88199970c70bf75b/history.json --exit-code 0 --source . | 0 | artifacts/raw/gitleaks-history.json |
| D28 · Secrets (history) | gitleaks | — | gitleaks detect --no-git --no-banner --config /opt/gitleaks-rules/watchdog-gitleaks.toml --report-format json --report-path /tmp/watchdog-gitleaks-bc61ba57c80c49eb88199970c70bf75b/tree.json --exit-code 0 --source . | 0 | artifacts/raw/gitleaks-tree.json |
| D29 · Static Analysis (SAST) | semgrep | — | semgrep --config /opt/semgrep-rules/security-audit.yml --config /opt/semgrep-rules/owasp-top-ten.yml --config /opt/semgrep-rules/watchdog-sast.yml --json --quiet --timeout 10 --timeout-threshold 3 --metrics off . | 30 | artifacts/raw/semgrep.json |
| D30 · Dependency Vulnerabilities | trivy | — | trivy fs --scanners vuln --format json --quiet --severity CRITICAL,HIGH,MEDIUM,LOW --skip-dirs **/bin/** --skip-dirs **/obj/** . --skip-db-update | 50 | artifacts/raw/trivy-fs.json |
| D31 · IaC & Container Security | trivy | — | trivy config --format json --quiet . | 6 | artifacts/raw/trivy-config.json |
| D32 · Data Compliance (PII/GDPR) | semgrep | — | semgrep: not applicable — No personal data was found crossing a boundary the PII/GDPR ruleset checks — nothing written to a log or console sink, placed in a URL or query string, or persisted to browser storage. That is a clean result for the LEAK surface only: this ruleset detects personal data escaping, it does not inventory the personal data a repository holds, so it is not evidence that this repository has no personal-data surface. The personal-data map (Appendix C) and the C1-C5 compliance cards are what speak to that. | 0 | — |
| D36 · Supply-chain Provenance & Signing | provenance | — | provenance: not applicable — No CI/build pipeline found (.github/.forgejo/.gitea workflows, .circleci, .buildkite, .woodpecker, .teamcity, .gitlab-ci.yml, .travis.yml, bitbucket-pipelines.yml, .drone.yml, .cirrus.yml, .woodpecker.yml, appveyor.yml, azure-pipelines*.yml, .pipelines/, .vsts-ci/, .azuredevops/, Jenkinsfile); there is no build to attest provenance for. | 0 | — |
| D37 · Vulnerability-disclosure Policy | disclosure | — | disclosure: not applicable — No vulnerability-disclosure policy file found (SECURITY.md/.markdown/.rst/.txt at root or under .github/.forgejo/.gitea/docs, .well-known/security.txt). A coordinated-disclosure policy may live off-repo, so this is not evidenced rather than failed. | 0 | — |
| D40 · Network Egress Confinement | runtime-hardening | — | runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; network egress policy is a cluster-native control that may live at the platform/firewall layer, so there is nothing to assess here. | 0 | — |
| D41 · Kernel & Syscall Confinement | runtime-hardening | — | runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; seccomp/AppArmor/SELinux confinement is a workload-level control, so there is nothing to assess here. | 0 | — |
| D42 · Runtime Threat Enforcement | runtime-hardening | — | runtime-hardening: not applicable — No Kubernetes/orchestration workloads found in the repository manifests; runtime threat-detection and admission-control policy are cluster-level controls, so there is nothing to assess here. | 0 | — |
| D43 · Malicious Dependencies | trivy | — | trivy fs --scanners vuln --format json --quiet --severity CRITICAL,HIGH,MEDIUM,LOW --skip-dirs **/bin/** --skip-dirs **/obj/** . --skip-db-update | 0 | artifacts/raw/trivy-fs.json |