-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
chore: add more logging #92
Conversation
WalkthroughThe pull request introduces modifications to two TypeScript files: Changes
Sequence DiagramsequenceDiagram
participant Resolver as ToolsResolver
participant JobUtils as ProductJobUtils
participant Logger as Console Logger
Resolver->>JobUtils: scheduleTriggerJob()
JobUtils->>Logger: Log info/warn/error
JobUtils-->>Resolver: Job scheduling result
The sequence diagram illustrates the interaction between Tip CodeRabbit's docstrings feature is now available as part of our Early Access Program! Simply use the command 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 0
🧹 Nitpick comments (3)
src/modules/data-ingestion/product.job.utils.ts (1)
44-49
: Consider utilising the logger instead ofconsole.log
.
Whilst this block is functionally correct, usingconsole.log
for production logging can clutter outputs and make logs harder to manage. You might want to rely on the providedLogsInterface
or a unified logging mechanism for consistency and enhanced maintainability.src/modules/tools/tools.resolver.ts (2)
90-94
: Abstract repeated inline logging.
Defining these arrow functions directly here is acceptable; however, they appear again below, essentially duplicating the same logic. You could consider creating a helper function or reusing an existing logger interface to reduce duplication and improve maintainability.
96-100
: Revisit duplicated logging code.
Similarly to the previous lines, you are repeating the same arrow functions forinfo
,warn
, anderror
. If you plan to incorporate further logging enhancements, centralising or abstracting this logger configuration could simplify future changes.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
src/modules/data-ingestion/product.job.utils.ts
(1 hunks)src/modules/tools/tools.resolver.ts
(1 hunks)
No description provided.