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

Problem: didn't disable the url query parameter in swagger ui #704

Merged
merged 1 commit into from
Feb 16, 2022

Conversation

yihuang
Copy link
Collaborator

@yihuang yihuang commented Feb 15, 2022

Solution:

  • update to recent swagger ui version
  • add option queryConfigEnabled: false

👮🏻👮🏻👮🏻 !!!! REFERENCE THE PROBLEM YOUR ARE SOLVING IN THE PR TITLE AND DESCRIBE YOUR SOLUTION HERE !!!! DO NOT FORGET !!!! 👮🏻👮🏻👮🏻

PR Checklist:

  • Have you read the CONTRIBUTING.md?
  • Does your PR follow the C4 patch requirements?
  • Have you rebased your work on top of the latest master?
  • Have you checked your code compiles? (make)
  • Have you included tests for any non-trivial functionality?
  • Have you checked your code passes the unit tests? (make test)
  • Have you checked your code formatting is correct? (go fmt)
  • Have you checked your basic code style is fine? (golangci-lint run)
  • If you added any dependencies, have you checked they do not contain any known vulnerabilities? (go list -json -m all | nancy sleuth)
  • If your changes affect the client infrastructure, have you run the integration test?
  • If your changes affect public APIs, does your PR follow the C4 evolution of public contracts?
  • If your code changes public APIs, have you incremented the crate version numbers and documented your changes in the CHANGELOG.md?
  • If you are contributing for the first time, please read the agreement in CONTRIBUTING.md now and add a comment to this pull request stating that your PR is in accordance with the Developer's Certificate of Origin.

Thank you for your code, it's appreciated! :)

Solution:

- update to recent swagger ui version
- add option `queryConfigEnabled: false`
@codecov
Copy link

codecov bot commented Feb 15, 2022

Codecov Report

Merging #704 (256c17b) into master (3158a19) will increase coverage by 3.27%.
The diff coverage is 0.00%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #704      +/-   ##
==========================================
+ Coverage   19.35%   22.63%   +3.27%     
==========================================
  Files          71       70       -1     
  Lines        7953     8073     +120     
==========================================
+ Hits         1539     1827     +288     
+ Misses       5903     5696     -207     
- Partials      511      550      +39     
Flag Coverage Δ
integration_tests 19.34% <ø> (-0.02%) ⬇️
unit_tests 9.61% <0.00%> (?)

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

Impacted Files Coverage Δ
app/app.go 21.71% <0.00%> (-66.87%) ⬇️
app/docs/statik/statik.go
x/nft/keeper/invariants.go 3.92% <0.00%> (+3.92%) ⬆️
x/nft/types/validation.go 50.00% <0.00%> (+14.28%) ⬆️
x/nft/keeper/keeper.go 83.33% <0.00%> (+21.21%) ⬆️
x/nft/client/cli/tx.go 76.04% <0.00%> (+32.29%) ⬆️
x/nft/keeper/denom.go 84.61% <0.00%> (+33.33%) ⬆️
x/nft/client/cli/query.go 68.71% <0.00%> (+35.19%) ⬆️
x/nft/types/msgs.go 38.88% <0.00%> (+38.88%) ⬆️
... and 4 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 3158a19...256c17b. Read the comment docs.

@@ -629,7 +629,7 @@ func (app *ChainApp) RegisterTendermintService(clientCtx client.Context) {

// RegisterSwaggerAPI registers swagger route with API Server
func RegisterSwaggerAPI(ctx client.Context, rtr *mux.Router) {
statikFS, err := fs.New()
statikFS, err := fs.NewWithNamespace("chainmain")
Copy link
Collaborator Author

@yihuang yihuang Feb 15, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

used a different namespace to prevent potential conflict with the one used by cosmos-sdk's simd.

@tomtau tomtau merged commit cefbc86 into crypto-org-chain:master Feb 16, 2022
@yihuang yihuang deleted the update-swagger-ui branch February 16, 2022 01:20
tomtau pushed a commit that referenced this pull request Mar 1, 2022
Solution:

- update to recent swagger ui version
- add option `queryConfigEnabled: false`
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants