Skip to content

[Help wanted] The request connection took longer than 0:00:20.000000. It was aborted. #31

@leobuzhi

Description

@leobuzhi

While running the example, I encountered the following error 1. If I set the proxy for HttpSetup, I encounter error 2.

Error 1:
(base) ➜ example git:(main) ✗ flutter run
Launching lib/main.dart on iPhone 13 in debug mode...
Running Xcode build...
└─Compiling, linking and signing... 2,703ms
Xcode build done. 7.3s
Syncing files to device iPhone 13... 123ms

Flutter run key commands.
r Hot reload. 🔥🔥🔥
R Hot restart.
h List all available interactive commands.
d Detach (terminate "flutter run" but leave application running).
c Clear the screen
q Quit (terminate the application on the device).

💪 Running with sound null safety 💪

An Observatory debugger and profiler on iPhone 13 is available at: http://127.0.0.1:65388/S7AYxR2iYWY=/
The Flutter DevTools debugger and profiler on iPhone 13 is available at: http://127.0.0.1:9101?uri=http://127.0.0.1:65388/S7AYxR2iYWY=/

Performing hot restart...
Restarted application in 354ms.
flutter:
[VERBOSE-2:dart_vm_initializer.cc(41)] Unhandled Exception:
status code :null message :The request connection took longer than 0:00:20.000000. It was aborted.
data:null

Error 2:
void initState() {
openAI = OpenAI.instance.build(
token: token,
baseOption: HttpSetup(
proxy: "localhost:1087",
receiveTimeout: const Duration(seconds: 20),
connectTimeout: const Duration(seconds: 20)),
isLog: true);
super.initState();
}

(base) ➜ example git:(main) ✗ flutter run
Launching lib/main.dart on iPhone 13 in debug mode...
Running Xcode build...
└─Compiling, linking and signing... 2,496ms
Xcode build done. 8.8s
Syncing files to device iPhone 13... 108ms

Flutter run key commands.
r Hot reload. 🔥🔥🔥
R Hot restart.
h List all available interactive commands.
d Detach (terminate "flutter run" but leave application running).
c Clear the screen
q Quit (terminate the application on the device).

💪 Running with sound null safety 💪

An Observatory debugger and profiler on iPhone 13 is available at: http://127.0.0.1:49416/nGCSjrR8sk8=/
The Flutter DevTools debugger and profiler on iPhone 13 is available at: http://127.0.0.1:9101?uri=http://127.0.0.1:49416/nGCSjrR8sk8=/
flutter:
[VERBOSE-2:dart_vm_initializer.cc(41)] Unhandled Exception:
status code :null message :null
data:null

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions