From c34fce6d16054bd7dcc448de7957d38a1f18e042 Mon Sep 17 00:00:00 2001 From: Alexander Trakhimenok <533159+trakhimenok@users.noreply.github.com> Date: Sat, 29 Jun 2024 08:51:56 +0100 Subject: [PATCH] fix(deps): removes dep on strongo/log --- go.mod | 3 --- go.sum | 38 +++++--------------------------------- logger.go | 50 -------------------------------------------------- 3 files changed, 5 insertions(+), 86 deletions(-) delete mode 100644 logger.go diff --git a/go.mod b/go.mod index fe73731..368bb6a 100644 --- a/go.mod +++ b/go.mod @@ -11,7 +11,6 @@ toolchain go1.22.4 require ( github.com/bots-go-framework/bots-fw v0.25.2 github.com/dal-go/dalgo v0.12.1 - github.com/strongo/log v0.3.0 google.golang.org/appengine/v2 v2.0.6 ) @@ -21,11 +20,9 @@ require ( github.com/golang/protobuf v1.5.3 // indirect github.com/google/go-cmp v0.6.0 // indirect github.com/pquerna/ffjson v0.0.0-20190930134022-aa0246cd15f7 // indirect - github.com/strongo/app v0.5.7 // indirect github.com/strongo/gamp v0.0.1 // indirect github.com/strongo/i18n v0.0.4 // indirect github.com/strongo/random v0.0.1 // indirect - github.com/strongo/strongoapp v0.10.0 // indirect github.com/strongo/validation v0.0.6 // indirect google.golang.org/protobuf v1.31.0 // indirect ) diff --git a/go.sum b/go.sum index 96a60d2..8bbe481 100644 --- a/go.sum +++ b/go.sum @@ -1,32 +1,13 @@ -github.com/bots-go-framework/bots-fw v0.21.5 h1:wgJDKfq/IDPk+4tq8UQGedXtEaj4w18efsDdLS6HjP0= -github.com/bots-go-framework/bots-fw v0.21.5/go.mod h1:U+CT3TicUjjNDX5IjjFqZYGCULgwU6d2THOh6zpxjfo= -github.com/bots-go-framework/bots-fw v0.21.7 h1:WWQCDIJDjFz5cVELeRjvAOE2EN2DLtfCumNT9lZNFWg= -github.com/bots-go-framework/bots-fw v0.21.7/go.mod h1:mSjtca5Eirg096HsmRWvuIDqP++l+NhU/GtDOnPIlwM= -github.com/bots-go-framework/bots-fw v0.22.0 h1:Fm1q+znGIIO9lHHp14RpojkSdRehjcd0GpybwTL3+Ms= -github.com/bots-go-framework/bots-fw v0.22.0/go.mod h1:mSjtca5Eirg096HsmRWvuIDqP++l+NhU/GtDOnPIlwM= -github.com/bots-go-framework/bots-fw v0.23.3 h1:lFgv1BmbGuBW8/9BCfw/P+EIA8aZbSRW09SNZ3pOOic= -github.com/bots-go-framework/bots-fw v0.23.3/go.mod h1:b7nmnKYjWSbV6zxsx5RS10heRy4BFJ5iWGvncMsqheI= -github.com/bots-go-framework/bots-fw v0.23.4 h1:0tYtWvKRwbrV8I6eKtfux+dsrEPBA6sz86bmS7ogvxE= -github.com/bots-go-framework/bots-fw v0.23.4/go.mod h1:HP4bmWvt/Jz1ZCiU9SitFQi6H6gXBOybS9c/SRdr+p8= -github.com/bots-go-framework/bots-fw v0.25.0 h1:xV66vbbnTHLUthfQQJnbNtwMUvQM76A7p15bog6yqIM= -github.com/bots-go-framework/bots-fw v0.25.0/go.mod h1:YkLM40RM50ouGjG4q9MCyIUY7X6fENMeVN4b3YG2KyE= github.com/bots-go-framework/bots-fw v0.25.2 h1:OBE68k5tHYWCUNyE9vVo4aYYIe5DZxziZ9sQ9q+F3RM= github.com/bots-go-framework/bots-fw v0.25.2/go.mod h1:jGOV8Ifn0khQIAS41tYp5dnUIU2xWL7isSxgWYSh6DI= -github.com/bots-go-framework/bots-fw-store v0.1.0 h1:Ob2r28xC2Qui8a5vAskBI0YpiMncYnyhXoKnpBn5BdU= -github.com/bots-go-framework/bots-fw-store v0.1.0/go.mod h1:XkLKnHugQ98Wr5VIlw2YuRYJNMcqqYDDw/j47plxmBY= -github.com/bots-go-framework/bots-fw-store v0.1.2 h1:ROWvP/IuB27urjl/6tHThEGEBmVZ5Kh5FyPDpWslD3k= -github.com/bots-go-framework/bots-fw-store v0.1.2/go.mod h1:T2yX1QodQ9A1nep/aIAL/czt9adqMyIBVTGOAdNVPAI= github.com/bots-go-framework/bots-fw-store v0.4.0 h1:5gQNsMNJ2rni3uGvXt7TeG+V7LFJ6lNIDkAC9g9J/us= github.com/bots-go-framework/bots-fw-store v0.4.0/go.mod h1:T2yX1QodQ9A1nep/aIAL/czt9adqMyIBVTGOAdNVPAI= -github.com/bots-go-framework/bots-go-core v0.0.1 h1:Br7j+Ir3R6U8x1mnFZFq1G1K0bupJhLvdF8TIqI/7i8= -github.com/bots-go-framework/bots-go-core v0.0.1/go.mod h1:txRZn1MlcJEiCUra3bQtpkt9IM2EFGaeUvqS1VLyl30= github.com/bots-go-framework/bots-go-core v0.0.2 h1:3F/czNOLZCO5rco1Zr9rATLvJrze5PZpa2dMRv4ON+M= github.com/bots-go-framework/bots-go-core v0.0.2/go.mod h1:u4r0W8t+n/07ulLlPZT3rdCt+mb5WHXP72z4oeTJVN0= -github.com/dal-go/dalgo v0.12.0 h1:giibzqo6mIkU06b0r4uKb3ZEa2agtj1qnL8RNa6sOBM= -github.com/dal-go/dalgo v0.12.0/go.mod h1:741DXTLpQfmvkazyEiivX8OBFylpzS1QErdh/6WquqI= github.com/dal-go/dalgo v0.12.1 h1:3W95xOSC7CLgH3OQppNOWoIaMkon8GlQmgYxxO5qnvs= github.com/dal-go/dalgo v0.12.1/go.mod h1:gzBMQn5sfUcHcx+7FNpO+FQz7guT/AAYgzXM4300rAY= github.com/davecgh/go-spew v1.1.1 h1:vj9j/u1bqnvCEfJOwUhtlOARqs3+rkHYY13jYWTU97c= +github.com/davecgh/go-spew v1.1.1/go.mod h1:J7Y8YcW2NihsgmVo/mv3lAwl/skON4iLHjSsI+c5H38= github.com/golang/protobuf v1.5.0/go.mod h1:FsONVRAS9T7sI+LIUmWTfcYkHO4aIWwzhcaSAoJOfIk= github.com/golang/protobuf v1.5.3 h1:KhyjKVUg7Usr/dYsdSqoFveMYd5ko72D+zANwlG1mmg= github.com/golang/protobuf v1.5.3/go.mod h1:XVQd3VNwM+JqD3oG2Ue2ip4fOMUkwXdXDdiuN0vRsmY= @@ -34,25 +15,17 @@ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/ github.com/google/go-cmp v0.6.0 h1:ofyhxvXcZhMsU5ulbFiLKl/XBFqE1GSq7atu8tAmTRI= github.com/google/go-cmp v0.6.0/go.mod h1:17dUlkBOakJ0+DkrSSNjCkIjxS6bF9zb3elmeNGIjoY= github.com/pmezard/go-difflib v1.0.0 h1:4DBwDE0NGyQoBHbLQYPwSUPoCMWR5BEzIk/f1lZbAQM= +github.com/pmezard/go-difflib v1.0.0/go.mod h1:iKH77koFhYxTK1pcRnkKkqfTogsbg7gZNVY4sRDYZ/4= github.com/pquerna/ffjson v0.0.0-20190930134022-aa0246cd15f7 h1:xoIK0ctDddBMnc74udxJYBqlo9Ylnsp1waqjLsnef20= github.com/pquerna/ffjson v0.0.0-20190930134022-aa0246cd15f7/go.mod h1:YARuvh7BUWHNhzDq2OM5tzR2RiCcN2D7sapiKyCel/M= -github.com/stretchr/testify v1.8.4 h1:CcVxjf3Q8PM0mHUKJCdn+eZZtm5yQwehR5yeSVQQcUk= -github.com/strongo/app v0.5.7 h1:Qm4YNBmCti0ewDeSqp/8hhXrD7UOHLsk5Lp0yjgOQGI= -github.com/strongo/app v0.5.7/go.mod h1:3sv0TgKPA03wHoJX5d4zn7gqwxaxGAKthvyvVZd+Q0Y= +github.com/stretchr/testify v1.9.0 h1:HtqpIVDClZ4nwg75+f6Lvsy/wHu+3BoSGCbBAcpTsTg= +github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY= github.com/strongo/gamp v0.0.1 h1:b6vzHUzNvbPOhzPtIja1NqKf8GQqrJWjs2gninQPZac= github.com/strongo/gamp v0.0.1/go.mod h1:ZcVVIzSQFygVehdtGh6KYmcp1eOacuEKb9th81WcUOw= github.com/strongo/i18n v0.0.4 h1:48DQrrlqTlZBi7uFbyruOVsSfr+X24RmO59FaOXLWGQ= github.com/strongo/i18n v0.0.4/go.mod h1:4jBQ4PJ3Uiri2Y+LHJ5/o1nB1H2ToddRW/yZXSOTUjE= -github.com/strongo/log v0.3.0 h1:89rh62SdO9TNTd8/pzhMSdGCmZwFDXHWm5ZtJvp0Wcg= -github.com/strongo/log v0.3.0/go.mod h1:C0OyprbH7WjyhcZXdveDiu5n0vxB8qZ1rQXxtUqx8y4= github.com/strongo/random v0.0.1 h1:OZHJBb/3uEa7OX8L2Dv2pLnSeewRmXMyTACoeto6O8I= github.com/strongo/random v0.0.1/go.mod h1:/pSI+SjBNLBkjljNtVdYr6ERddA+LqSa87o0/s+9iuU= -github.com/strongo/strongoapp v0.9.1 h1:M3JqRZtqftTHGqnekW3ncNYYqLv2B1weye7yhPIG9ms= -github.com/strongo/strongoapp v0.9.1/go.mod h1:UWRe4rYG7val1PRumvd+V1TbCHmckfHr3DQ+OzvYnqo= -github.com/strongo/strongoapp v0.10.0 h1:HWB3UgaagtIr1UJxZ0oKGSdVPVw8Qfhq+/u50Rknqfw= -github.com/strongo/strongoapp v0.10.0/go.mod h1:UWRe4rYG7val1PRumvd+V1TbCHmckfHr3DQ+OzvYnqo= -github.com/strongo/validation v0.0.5 h1:O+eJM06v+rR+ZUua7kBi1JCK4a7JXMlkS7pmXkhxFJc= -github.com/strongo/validation v0.0.5/go.mod h1:euQ9ywYwBASSnCLSYOx8JW0u4/71yfbeZhBQJv93dZg= github.com/strongo/validation v0.0.6 h1:RskXD45ILagVW3jmuKUiq7WshE4kmoQEiUbgfigqHzw= github.com/strongo/validation v0.0.6/go.mod h1:V4Nu8b8CPsLNwYLKmMHN2ghkoabOpiOW8NNcUczuCWE= github.com/yuin/goldmark v1.4.13/go.mod h1:6yULJ656Px+3vBD8DxQVa3kxgyrAnzto9xy5taEt/CY= @@ -80,8 +53,6 @@ golang.org/x/tools v0.0.0-20191119224855-298f0cb1881e/go.mod h1:b+2E5dAYhXwXZwtn golang.org/x/tools v0.1.12/go.mod h1:hNGJHUnrk76NpqgfD5Aqm5Crs+Hm0VOH/i9J2+nxYbc= golang.org/x/xerrors v0.0.0-20190717185122-a985d3407aa7/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= golang.org/x/xerrors v0.0.0-20191204190536-9bdfabe68543/go.mod h1:I/5z698sn9Ka8TeJc9MKroUUfqBBauWjQqLJ2OPfmY0= -google.golang.org/appengine/v2 v2.0.5 h1:4C+F3Cd3L2nWEfSmFEZDPjQvDwL8T0YCeZBysZifP3k= -google.golang.org/appengine/v2 v2.0.5/go.mod h1:WoEXGoXNfa0mLvaH5sV3ZSGXwVmy8yf7Z1JKf3J3wLI= google.golang.org/appengine/v2 v2.0.6 h1:LvPZLGuchSBslPBp+LAhihBeGSiRh1myRoYK4NtuBIw= google.golang.org/appengine/v2 v2.0.6/go.mod h1:WoEXGoXNfa0mLvaH5sV3ZSGXwVmy8yf7Z1JKf3J3wLI= google.golang.org/protobuf v1.26.0-rc.1/go.mod h1:jlhhOSvTdKEhbULTjvd4ARK9grFBp09yW+WbY/TyQbw= @@ -90,3 +61,4 @@ google.golang.org/protobuf v1.30.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqw google.golang.org/protobuf v1.31.0 h1:g0LDEJHgrBl9N9r17Ru3sqWhkIx2NB67okBHPwC7hs8= google.golang.org/protobuf v1.31.0/go.mod h1:HV8QOd/L58Z+nl8r43ehVNZIU/HEI6OcFqwMG9pJV4I= gopkg.in/yaml.v3 v3.0.1 h1:fxVm/GzAzEWqLHuvctI91KS9hhNmmWOoWu0XTYJS7CA= +gopkg.in/yaml.v3 v3.0.1/go.mod h1:K4uyk7z7BCEPqu6E+C64Yfv1cQ7kz7rIZviUmN+EgEM= diff --git a/logger.go b/logger.go deleted file mode 100644 index 69191e5..0000000 --- a/logger.go +++ /dev/null @@ -1,50 +0,0 @@ -package gae - -import ( - "context" - "github.com/strongo/log" - logGae "google.golang.org/appengine/v2/log" -) - -type logger struct{} - -func (l logger) Name() string { - return "GaeLogger" -} -func (l logger) Debugf(c context.Context, format string, args ...interface{}) { - if c == nil { - panic("Required parameter 'c context.Context' is nill") - } - logGae.Debugf(c, format, args...) -} - -func (l logger) Infof(c context.Context, format string, args ...interface{}) { - if c == nil { - panic("Required parameter 'c context.Context' is nill") - } - logGae.Infof(c, format, args...) -} - -func (l logger) Warningf(c context.Context, format string, args ...interface{}) { - if c == nil { - panic("Required parameter 'c context.Context' is nill") - } - logGae.Warningf(c, format, args...) -} - -func (l logger) Errorf(c context.Context, format string, args ...interface{}) { - if c == nil { - panic("Required parameter 'c context.Context' is nill") - } - logGae.Errorf(c, format, args...) -} - -func (l logger) Criticalf(c context.Context, format string, args ...interface{}) { - if c == nil { - panic("Required parameter 'c context.Context' is nill") - } - logGae.Criticalf(c, format, args...) -} - -// GaeLogger is a logger for GAE environment -var GaeLogger = (log.Logger)(logger{}) // TODO: move outside of bots framework