7ffdff37e4
chore: upgrade golangci-lint configuration and optimize codebase ( #4236 )
...
This PR includes the following changes:
- **Upgrade `.golangci.yml`**: Updated the configuration file to align
with the latest golangci-lint version, ensuring compatibility and
leveraging new features.
- **Refactor GitHub Action workflow**: Modified `golangci-lint.yml` in
the GitHub Actions workflow to reflect the updated configuration and
improve CI performance.
- **Codebase optimization**: Refactored code to address issues and
warnings raised by the updated golangci-lint rules, including:
- Improved function length and complexity.
- Enhanced error handling and variable naming conventions.
- Fixed minor issues such as unused imports and formatting
inconsistencies.
These changes aim to maintain code quality, ensure compatibility with
the latest tools, and improve overall maintainability.
2025-08-22 13:29:09 +08:00
7180d895ea
Update util/gconv/gconv_z_unit_scan_test.go
...
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com >
2025-06-20 18:17:40 +08:00
b73e2047db
fix(gconv): fix scanning functionality for deep slice types
2025-05-06 13:37:45 +08:00
bc1e1019c5
refract(util/gconv): change Converter interface definition for more convenient usage ( #4202 )
2025-03-14 18:23:07 +08:00
dfe088f5cd
refactor(util/gconv): add Converter feature for more flexable and extensible type converting ( #4107 )
2025-03-06 23:04:26 +08:00
f4074cd815
fix(net/gclient): remove default discovery for gclient when Discovery feature enabled ( #4174 )
2025-03-03 16:43:21 +08:00
63cb3285f8
fix(net/ghttp): update response message handling in MiddlewareHandlerResponse ( #4162 )
2025-02-27 11:59:26 +08:00
a5c8b966e2
feat(util/gconv): add basic types conversion support for function Scan ( #3991 )
2024-12-18 10:41:09 +08:00
ffa6081471
fix(util/gconv): fix missing minus in string to int64 conversion ( #3920 )
2024-11-13 23:25:24 +08:00
d1872f17f7
fix(util/gconv): assigned the same value to struct field and its same name field in embedded struct failed ( #3905 )
2024-11-06 21:12:01 +08:00
b1d875a31f
fix(util/gconv): incorrect fuzzy converting logic ( #3874 )
2024-10-21 09:16:50 +08:00
5288b70567
fix(util/gconv): one parameter to same tag in multiple struct attributes mapping failed ( #3822 )
2024-10-14 21:34:39 +08:00
5aa321dbde
fix(util/gconv): unstable converting when there is an external attribute with the same name as the internal structure ( #3799 )
2024-09-25 19:22:15 +08:00
9af8393758
fix(net/goai): change default value of RequestBody.Required from true to false, add required tag support for RequestBody ( #3796 )
2024-09-24 11:51:53 +08:00
8a1c97f518
fix(util/gconv): cached field indexes append issue caused incorrect field converting ( #3790 )
2024-09-23 19:05:32 +08:00
d8e3e9d713
fix(utils/utils_str): recognize '+' as a valid numeric sign ( #3778 )
2024-09-23 16:45:55 +08:00
777c2e7117
ci: fix mssql docker service failed in ci ( #3792 )
2024-09-23 11:50:48 +08:00
0e471eab38
fix(util/gconv): #3764 fix bool converting issue ( #3765 )
2024-09-12 21:59:38 +08:00
1b4ebc0812
perf(util/gconv): add cache logic to enhance performance ( #3673 )
2024-09-09 16:17:01 +08:00
448df14860
fix(util/gconv): #3731 map type name mismatch in switch case statement ( #3732 )
2024-09-09 14:54:40 +08:00
737da954a0
util/gconv: remove unnecessary logic for function doScanList ( #3588 )
2024-05-20 19:42:51 +08:00
a9a0785252
util/gconv: refactor code unit testing ( #3591 )
2024-05-20 19:40:30 +08:00
1013df1627
enhance: improve performance of struct converting for package gconv ( #3412 )
2024-04-23 21:30:06 +08:00
d7a0482146
fix : #3465 If the value of a string is null, the value of string is nil after the string is converted to []string ( #3468 )
2024-04-10 20:18:03 +08:00
83ba887df7
fix : #3449 accept slice parameter as json.RawMessage for http request ( #3452 )
2024-04-07 14:09:52 +08:00
911f1cb1de
enhance: use map iter to iterate the map instead of map keys and values ( #3457 )
2024-04-07 10:00:04 +08:00
e0a2645f4a
fix : #3390 name&shor tag mapping failed to command input object for package gcmd ( #3429 )
2024-04-01 19:07:08 +08:00
607f079b23
fix: cache value assertion panic if the cache adapter is not in-memory for soft time feature of package gdb; improve converting performance for gconv.Scan ( #3351 )
2024-03-07 11:36:42 +08:00
51326f3d02
fix #3245 ( #3298 )
2024-02-06 11:47:25 +08:00
c4a51f4c2f
bugfix:fix gconv map deep option not effective ( #3287 )
2024-01-29 19:52:04 +08:00
ba39323d30
improve converter feature for package gconv ( #3211 )
2024-01-22 21:52:54 +08:00
951f8921cd
fix #3237 ( #3267 )
2024-01-17 15:35:48 +08:00
42e3c5f39a
fix #3253 ( #3255 )
2024-01-11 22:14:22 +08:00
645c5ff5b5
fix issue #3218 #3204 ( #3220 )
2023-12-19 21:58:12 +08:00
9aa872e705
improve map converting feature using MapOption for package gconv ( #3170 )
2023-11-23 18:59:04 +08:00
ea5d52cb2f
fix issue #3147 ( #3161 )
2023-11-22 21:05:39 +08:00
0b407c5e6d
fix "gf gen pb" api and ctrl not working well. ( #3076 )
2023-11-08 21:26:51 +08:00
a17849bc39
improve struct converting in parameter name case sensitive scenario for package gconv ( #3122 )
2023-11-08 21:17:55 +08:00
0b71bc43a8
fix issue #3099 ( #3107 )
2023-10-31 20:02:20 +08:00
972f8c3aff
improve comments for package gconv ( #3057 )
2023-10-17 21:09:46 +08:00
65192a7f92
fix issue gconv struct slice/map of json.RawMessage ( #3006 ) ( #3008 )
2023-10-11 21:35:27 +08:00
10b67fc7b0
fix issues #2980 ( #2994 )
2023-10-11 21:28:53 +08:00
e684eae878
Make GTime support multiple formats ( #2933 )
2023-09-13 19:29:25 +08:00
5219c5c37e
add ut cases for command gen dao ( #2958 )
2023-09-12 22:00:35 +08:00
d49dccb147
test: add unit tests regarding issue 2901 ( #2930 )
2023-09-05 19:30:54 +08:00
eb11061bd2
fix: gjson encode to string expect inconformity(issue 2520) ( #2928 )
2023-09-04 21:19:22 +08:00
097b26f318
fix: multiple interfaces cause the original type to be inaccessible ( #2915 )
2023-09-04 20:11:14 +08:00
24ee5341ec
Fix empty map or struct convert to another map will return error. ( #2863 )
2023-08-17 20:59:16 +08:00
ed4d1554ab
improve converter feature for package gconv ( #2869 )
2023-08-17 20:33:12 +08:00
ea6a773d60
fix: marked gcode.CodeInternalPanic for panic ( #2860 )
2023-08-14 09:53:13 +08:00