From 33064d22a3220135272d4a54164b72921c3cdfc4 Mon Sep 17 00:00:00 2001 From: Ilia Denisov Date: Tue, 23 Jun 2026 22:22:22 +0200 Subject: [PATCH] tmp: debug-log telegram language_code on contour (REVERT before merge) Temporary: traces the language_code Telegram sends + the seeded variant_preferences, to settle why a new account lands in Russian despite an English interface. Test contour only; force-pushed away before merge so it never reaches master. --- backend/internal/server/handlers_auth.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/backend/internal/server/handlers_auth.go b/backend/internal/server/handlers_auth.go index 4d23524..09c62b3 100644 --- a/backend/internal/server/handlers_auth.go +++ b/backend/internal/server/handlers_auth.go @@ -46,6 +46,15 @@ func (s *Server) handleTelegramAuth(c *gin.Context) { s.abortErr(c, err) return } + // TEMP DEBUG (revert before merge): trace the language_code Telegram actually sent and + // what we seeded, to settle the "ru interface" question on the test contour. + s.log.Info("telegram auth debug", + zap.String("external_id", req.ExternalID), + zap.String("language_code", req.LanguageCode), + zap.String("username", req.Username), + zap.String("start_param", req.StartParam), + zap.Bool("created", created), + zap.Strings("variant_preferences", acc.VariantPreferences)) if created { // First registration: re-evaluate moderated-chat write access, so a user who // joined the chat before registering is granted on the spot (no chat_member