taobig
taobig
``` var tokenManager TokenManager = TokenManager{cache: cache} // github.com/larksuite/oapi-sdk-go/[email protected]/core/tokenmanager.go ``` 有时候本程序作为一个服务,需要暴露access token给外部其他程序临时调用,希望能够修改tokenManager为可导出变量,同时将它的 **getAppAccessToken()** 和 **getTenantAccessToken()** 两个方法也设置为可导出。另外希望同时也支持导出access token的ttl。
api file: ``` type Example { Data any `json:"data"` } ``` run `goctl` command Error message: can not found declaration 'any' in context
Now we can only call `zrpc.SetClientSlowThreshold(threshold time.Duration)` to set zrpc's "client slow threshold value". But it works on all RPC clients. I hope each zrpc client can set zrpc ClientSlowThreshold...
现有代码: ``` public static String packageToPath(String pkg) { return pkg.replaceAll("\\.", File.separator); } ``` 在windows下会导致如下异常: java.lang.ExceptionInInitializerError at... Caused by:java.lang.IllegalArgumentException: character to be escaped is missing
fix processTransactionWithAddressLookups usage
现在参数解析的httpx.Parse()返回的错误不会区分是参数错误还是其他错误,希望区分开来。(因为参数错误可以显示给请求方,其他错误需要自定义处理隐藏) 而现在httpx.Parse()触发的错误都是没有导出的error变量(errTypeMismatch,errValueNotSettable,errValueNotStruct),没办法用errors.Is()来判断其类型。 希望提供一种机制,可以让用户侧的程序可以区分httpx.Parse()的返回error是参数错误还是其他错误。 我的想法: 1. 在Go>=1.20版本,可以新建一个可导出的ErrParamsError(标准error),使用multi error组合original error+ErrParamsError,这样用户侧可以用errors.Is(err, ErrParamsError)来判断。 2. 在Go
There is a decimal field in mysql table. ``` sql ... `amount` decimal(20, 2) NOT NULL ... ``` generate model by gii ```php ... * @property float $amount ... ```...
基于关联issue: #3128 , 现在最新版的go-zero要求最低go版本是1.20,所以可以不用兼容1.20以下版本了。 ### 背景 现在参数解析的httpx.Parse()返回的错误不会区分是参数错误还是其他错误,希望区分开来。(因为参数错误可以显示给请求方,其他错误需要隐藏并自定义返回信息) 而现在httpx.Parse()触发的错误都是没有导出的error变量(errTypeMismatch,errValueNotSettable,errValueNotStruct),没办法用errors.Is()来判断其类型,所以用户层没法区分是参数错误还是logic返回的业务错误。 但是如果仅仅将上述errTypeMismatch,errValueNotSettable,errValueNotStruct等几个err修改为可导出,用户要一个个去匹配判断,太麻烦了,所以我的想法是: - 新建一个可导出的ErrParamsError(标准error),使用multi error组合(`errors.Join(ErrParamError, originalErr)`),这样用户侧可以用errors.Is(err, ErrParamsError)来判断。
- https://github.com/binance/binance-connector-go/blob/fc4f37238f0e42e40d90e54f35413eaaf18f486b/account.go#L184 - https://developers.binance.com/docs/binance-spot-api-docs/rest-api/trading-endpoints#new-order-trade
Testcase: - token **(mainnet)**: EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v (USDC) - token 2022 **(devnet)**: 64vX5aZLdRrHD5HwEqFW9fvtxYeYx7xqmqYWFQ1KNS5h