yonaskolb / SwagGen

OpenAPI/Swagger 3.0 Parser and Swift code generator

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Couldn't get required object pointer

timshe opened this issue · comments

I used SwagGen to generate my Client API and I have spent two days on this error:

Printing description of self.behaviours:
expression produced error: warning: couldn't get required object pointer (substituting NULL): Couldn't load 'self' because its value couldn't be evaluated

error: Execution was interrupted, reason: EXC_BAD_ACCESS (code=1, address=0x10).
The process has been returned to the state before expression evaluation.

The error happens here:

// create composite behaviour to make it easy to call functions on array of behaviours
let requestBehaviour = RequestBehaviourGroup(request: request, behaviours: self.behaviours + behaviours)

I stepped through the code several times: the URL is well formed,I updated the APIClient.swift (attached) from a verified version (Fix a potential crash when constructing a URLRequest (#268))

Swaggen Version: 4.4.0
Xcode Version 12.4 (12D4e)
s.dependency 'Alamofire', '~> 4.9.0'
s.source = { :git => 'git@github.com:https://github.com/yonaskolb/SwagGen.git'

Any pointer to a solution would be appreciated


ezoic increase your site revenue