From 65f2163c0a0b693a12654bcadae64546ddcc3b4f Mon Sep 17 00:00:00 2001 From: Neil Macneale IV <46170177+macneale4@users.noreply.github.com> Date: Thu, 6 Jul 2023 09:51:36 -0700 Subject: [PATCH] Remove temporary workaround for loopback bug in GMS (#6283) Related Prereq: https://github.com/dolthub/go-mysql-server/pull/1856 --- go/cmd/dolt/commands/sqlserver/server.go | 12 +----------- integration-tests/bats/helper/common.bash | 2 -- 2 files changed, 1 insertion(+), 13 deletions(-) diff --git a/go/cmd/dolt/commands/sqlserver/server.go b/go/cmd/dolt/commands/sqlserver/server.go index 2c7acdc10d0..98ae550f9ef 100644 --- a/go/cmd/dolt/commands/sqlserver/server.go +++ b/go/cmd/dolt/commands/sqlserver/server.go @@ -21,7 +21,6 @@ import ( "fmt" "net" "net/http" - "os" "runtime" "strconv" "time" @@ -224,11 +223,7 @@ func Serve( lck := env.NewDBLock(serverConfig.Port()) sqlserver.SetRunningServer(mySQLServer, &lck) - localConnectionHost := "localhost" - if isDoltTestEnvSet() { - localConnectionHost = "%" - } - sqlEngine.GetUnderlyingEngine().Analyzer.Catalog.MySQLDb.AddSuperUser(LocalConnectionUser, localConnectionHost, lck.Secret) + sqlEngine.GetUnderlyingEngine().Analyzer.Catalog.MySQLDb.AddSuperUser(LocalConnectionUser, "localhost", lck.Secret) var metSrv *http.Server if serverConfig.MetricsHost() != "" && serverConfig.MetricsPort() > 0 { @@ -519,8 +514,3 @@ func checkForUnixSocket(config ServerConfig) (string, bool, error) { return "", false, nil } - -// isDoltTestEnvSet Temporary function to enable __dolt_local_user__ to be used until https://github.com/dolthub/dolt/issues/6239 is resolved -func isDoltTestEnvSet() bool { - return os.Getenv("DOLT_ENABLE_LOCAL_USER_FOR_ALL_HOSTS") != "" -} diff --git a/integration-tests/bats/helper/common.bash b/integration-tests/bats/helper/common.bash index af4e850f17e..c9036d3ebf8 100644 --- a/integration-tests/bats/helper/common.bash +++ b/integration-tests/bats/helper/common.bash @@ -70,8 +70,6 @@ setup_no_dolt_init() { # during the cli -> sql migration. export DOLT_CLI_PASSWORD="" export DOLT_SILENCE_USER_REQ_FOR_TESTING="Y" - # Temporary Flag: https://github.com/dolthub/dolt/issues/6239 - export DOLT_ENABLE_LOCAL_USER_FOR_ALL_HOSTS="Y" } assert_feature_version() {