WalletConnect / WalletConnectSwiftV2

WalletConnect Swift SDK v2
https://docs.walletconnect.com
Apache License 2.0
301 stars 159 forks source link

Failed to build project for debug: `Cannot find type 'JSONRPC' in scope` #1390

Open Andoran90 opened 1 month ago

Andoran90 commented 1 month ago

Describe the bug When upgrading to 1.19.0 and higher failed to build project in debug, because of Cannot find type 'JSONRPC' in scope.

func getSessionRequest(id: JSONRPC.RPCID) -> (request: Request, context: VerifyContext?)? {
    fatalError("Unimplemented")
}

Remove JSONRPC. so the project can be build in debug

SDK Version

To Reproduce Steps to reproduce the behavior:

  1. Add pod 'WalletConnectSwiftV2', :git => 'https://github.com/WalletConnect/WalletConnectSwiftV2', :tag => '1.19.0'
  2. Click on Build button
  3. See error Cannot find type 'JSONRPC' in scope

Expected behavior Build successful

Screenshots

image
llbartekll commented 1 month ago

hey, I would guess it's some xcode issue, have you been able to resolve?

Andoran90 commented 1 month ago

there is preprocessor #if Debug, so this code compiling for Debug builds. To resolve this I need to navigate to this file and remove JSONRPC., because this doesn't exist. Swift doesn't support namespaces and there are no entity JSONRPC, so this is definitely should be removed.

Andoran90 commented 1 month ago

@llbartekll hello. Is there any updates on this?