Replies: 4 comments 9 replies
-
I have test it on my api server working good only issue was from iOS client |
Beta Was this translation helpful? Give feedback.
-
I am getting this decoding issue lots of time I am not sure its have issue or dont get proper error message becz case let .imageUploadResponse(.success(imageURLString)):
guard let user: UserOutput = KeychainService.loadCodable(for: .user) else {
return .none
}
let attachment = AttachmentInOutPut(type: .image, userId: user.id, imageUrlString: imageURLString)
return .task {
do {
let attacment = try await environment.attachmentClient.updateUserImageURL(attachment)
return ProfileAction.attacmentResponse(.success(attacment))
} catch {
return ProfileAction.attacmentResponse(
.failure(
HTTPRequest.HRError.custom("cant upload attachment", error)
)
)
}
} from clicnt I am trying to send like this I am 100% sure i dont have decoding issue at all here my client https://github.com/AddaMeSPB/AddaMeIOS/blob/siteRouter/AddameSPM/Sources/AttachmentClient/AttachmentClient.swift and form this https://github.com/AddaMeSPB/AddaMeIOS/blob/siteRouter/AddameSPM/Sources/AttachmentClientLive/Live.swift#L84 HRError
- description : "Failed to load the request: Optional(HTTPClientError.deadlineExceeded)"
▿ reason : Optional<Error>
▿ some : HTTPClientError.deadlineExceeded
- code : AsyncHTTPClient.HTTPClientError.(unknown context at $104271798).Code.deadlineExceeded testing from server side no issue |
Beta Was this translation helpful? Give feedback.
-
@saroar It looks like the server is sending back a "deadline exceeded" error, which is why decoding is failing. You can see the definition here: I'm not familiar with this error or how to work around it, but I don't think it's a bug with our library. Can you ask someone in a community more familiar with the Since this doesn't appear to be a bug in our library, I'm going to close it. But if you do believe there's a bug in our library, please file a new issue with a reproduction for us to work with and instructions on how to reproduce. Without steps to reproduce, we really don't have much of an ability to try to fix. |
Beta Was this translation helpful? Give feedback.
-
My playground code which dont have any issue
playground code here https://gist.github.com/saroar/a1bab728f4292c54cb76085a633c6a3c
my client iOS app dont send any request to server becz its not decoding my query
https://github.com/AddaMeSPB/AddaMeIOS/blob/siteRouter/AddameSPM/Sources/EventView/EventsReducer.swift#L112
error coming from decoding from this
https://github.com/pointfreeco/swift-url-routing/blob/main/Sources/URLRouting/Client/Client.swift#L53
Beta Was this translation helpful? Give feedback.
All reactions