Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(context): methods to get nested map from query string #4029

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

dorzepowski
Copy link

No description provided.

@appleboy appleboy added this to the v1.11 milestone Aug 15, 2024
Copy link

codecov bot commented Aug 15, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 99.06%. Comparing base (3dc1cd6) to head (256e3f8).
Report is 67 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #4029      +/-   ##
==========================================
- Coverage   99.21%   99.06%   -0.16%     
==========================================
  Files          42       44       +2     
  Lines        3182     2778     -404     
==========================================
- Hits         3157     2752     -405     
+ Misses         17       15       -2     
- Partials        8       11       +3     
Flag Coverage Δ
?
-tags "sonic avx" 99.05% <100.00%> (?)
-tags nomsgpack 99.04% <100.00%> (?)
go-1.18 ?
go-1.19 ?
go-1.20 ?
go-1.21 99.06% <100.00%> (-0.16%) ⬇️
macos-latest 99.05% <100.00%> (-0.16%) ⬇️
ubuntu-latest 99.04% <100.00%> (-0.17%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@dorzepowski dorzepowski force-pushed the feat/query-string-to-nested-map branch from 256e3f8 to 21dea20 Compare August 16, 2024 15:48
@dorzepowski
Copy link
Author

dorzepowski commented Aug 16, 2024

  1. Recently I fixed the issue that makes one test sometimes failing
  2. Also I added support for arrays at the value level of the nested map, while implicit arrays are still returning only first value

In other words:

GET /get?filter[names][]=alice&filter[names][]=bob

will produce map

map[names:[alice bob]]

while:

GET /get?filter[status]=new&filter[status]=old HTTP/1.1

will produce the map with only single value at given key

map[status:new]

This may (or may not) be a good alternative for the #2139 approach

@dorzepowski dorzepowski force-pushed the feat/query-string-to-nested-map branch 2 times, most recently from 8a09e3e to cfb5684 Compare August 27, 2024 07:49
@dorzepowski dorzepowski force-pushed the feat/query-string-to-nested-map branch from cfb5684 to 8f79761 Compare August 27, 2024 07:49
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants