From 451bdf2c756ed47a51b1612c4a2a1115224d6b01 Mon Sep 17 00:00:00 2001 From: David Young Date: Wed, 29 Apr 2026 14:02:25 -0600 Subject: [PATCH] fixing ports --- internal/auth/auth.go | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/internal/auth/auth.go b/internal/auth/auth.go index 721b69a..8e3ca81 100644 --- a/internal/auth/auth.go +++ b/internal/auth/auth.go @@ -27,12 +27,11 @@ type Result struct { } func listenOnFreePort() (net.Listener, string, error) { - ln, err := net.Listen("tcp", "127.0.0.1:0") + ln, err := net.Listen("tcp", "127.0.0.1:8080") if err != nil { - return nil, "", fmt.Errorf("finding free port: %w", err) + return nil, "", fmt.Errorf("listening on port 8080: %w", err) } - port := ln.Addr().(*net.TCPAddr).Port - return ln, fmt.Sprintf("http://localhost:%d/callback", port), nil + return ln, "http://localhost:8080/callback", nil } // TwitterOAuth2 runs the OAuth 2.0 PKCE flow for Twitter/X. It opens the