Replace console usage with centralized logger across all packages excluding extension base 4930#4931
Open
ruhil6789 wants to merge 3 commits into
Conversation
- Replaced all console.* statements with logger calls across extension-base - Added logger instances to all service files, API files, and utilities - Fixed TypeScript errors related to missing logger declarations - Test files (.spec.ts) intentionally left unchanged
- Break circular dependency between extension-base and extension-dapp by creating local logger in extension-dapp - Add missing logger imports in extension-koni-ui components - Fix TypeScript project references to resolve build errors - Update tsconfig files to maintain rootDir while breaking circular dependencies - Fix type errors in DebuggerAPI component
…ger-across-all-packages-excluding-extension-base-4930
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR resolves critical TypeScript compilation errors caused by circular dependencies between
extension-baseandextension-dapppackages, and fixes missing logger imports across the codebase.Problem
extension-base↔extension-dappFixes: [4930]
Solution
1. Break Circular Dependency
extension-dappto eliminate circular dependency withextension-basepackages/extension-dapp/src/logger.tswithSimpleLoggerclassextension-dapp/src/bundle.tsto use local logger instead of importing fromextension-base2. Fix TypeScript Configuration
tsconfig.build.jsonandtsconfig.jsonforextension-baseandextension-dapprootDirconstraintsextension-base→extension-dapp3. Fix Missing Logger Imports
defaultLoggerimport inNotification.tsxcreateLoggerimport and logger instance inTransactionSubmission.tsxSettings/index.tsxDebuggerAPI.tsx(undefined check forformValues?.api)Changes
packages/extension-dapp/src/logger.tsImpact
Resolves TypeScript build errors (TS6059, TS6307, TS6202)
Maintains all
rootDirconfigurations as requiredNo breaking changes to functionality
All logger functionality preserved
Testing
Related Issues
Fixes TypeScript circular dependency and compilation errors