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

merge master to v2 #1903

Merged
merged 88 commits into from
Oct 19, 2024
Merged

merge master to v2 #1903

merged 88 commits into from
Oct 19, 2024

Conversation

ubogdan
Copy link
Contributor

@ubogdan ubogdan commented Oct 17, 2024

Describe the PR
Sync changes from master with v2 branch.

Relation issue
e.g. https:/swaggo/swag/pull/118/files

Additional context
Neet to resolve conflicts. (wip)

tzxdtc and others added 30 commits April 11, 2023 10:43
remove repeat net/http
* Add template action delimiter cli flag

* Add delims to generator config and template

Also adds tests using the "quote" test as a base. This has to have a
custom Instance name or it will clash with the "quotes" one and panic
since it will have registered two "swagger" instances in the package
test.

* Add testdata for custom delim flags

Based on the "quote" testdata.

* Add delims to the spec, with tests.

Make sure we don't add delims if they are empty. This shouldn't be
possible, but might as well be safe.

* Go mod tidy and sum update

* Make the CLI experience a bit cleaner

* Revert go.mod and sum

* Update readme
)

* add retract caused by accidentally pushed tags

* update version to match new tag version

---------

Co-authored-by: Tobias Theel <[email protected]>
Bumps [github.com/gin-gonic/gin](https:/gin-gonic/gin) from 1.7.7 to 1.9.1.
- [Release notes](https:/gin-gonic/gin/releases)
- [Changelog](https:/gin-gonic/gin/blob/master/CHANGELOG.md)
- [Commits](gin-gonic/gin@v1.7.7...v1.9.1)

---
updated-dependencies:
- dependency-name: github.com/gin-gonic/gin
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [github.com/gin-gonic/gin](https:/gin-gonic/gin) from 1.7.7 to 1.9.1.
- [Release notes](https:/gin-gonic/gin/releases)
- [Changelog](https:/gin-gonic/gin/blob/master/CHANGELOG.md)
- [Commits](gin-gonic/gin@v1.7.7...v1.9.1)

---
updated-dependencies:
- dependency-name: github.com/gin-gonic/gin
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…ort (#1600)

Bumps [github.com/gin-gonic/gin](https:/gin-gonic/gin) from 1.7.7 to 1.9.1.
- [Release notes](https:/gin-gonic/gin/releases)
- [Changelog](https:/gin-gonic/gin/blob/master/CHANGELOG.md)
- [Commits](gin-gonic/gin@v1.7.7...v1.9.1)

---
updated-dependencies:
- dependency-name: github.com/gin-gonic/gin
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…le params (#1621)

* fix required params parsing for routes with multiple paths and multiple params

* fix incorrect variable declaration of validParams
* parser: if all tags negate return true on no hits
* support binary const

Signed-off-by: sdghchj <[email protected]>

* add test

Signed-off-by: sdghchj <[email protected]>

---------

Signed-off-by: sdghchj <[email protected]>
* global security

* improve test
#1605)

* change cli flag to parse operations in dependency

Signed-off-by: sdghchj <[email protected]>

* change cli flag to parse operations in dependency

Signed-off-by: sdghchj <[email protected]>

* add cli flag --pdl to determine whether parse operations in dependency

Signed-off-by: sdghchj <[email protected]>

* add cli flag --pdl to determine whether parse operations in dependency

Signed-off-by: sdghchj <[email protected]>

* add cli flag --pdl to determine whether parse operations in dependency

Signed-off-by: sdghchj <[email protected]>

---------

Signed-off-by: sdghchj <[email protected]>
test: add a test case to validate permission equal
Bumps gopkg.in/yaml.v3 from 3.0.0-20200615113413-eeeca48fe776 to 3.0.0.

---
updated-dependencies:
- dependency-name: gopkg.in/yaml.v3
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [golang.org/x/net](https:/golang/net) from 0.8.0 to 0.17.0.
- [Commits](golang/net@v0.8.0...v0.17.0)

---
updated-dependencies:
- dependency-name: golang.org/x/net
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Bumps [golang.org/x/net](https:/golang/net) from 0.7.0 to 0.17.0.
- [Commits](golang/net@v0.7.0...v0.17.0)

---
updated-dependencies:
- dependency-name: golang.org/x/net
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
…value, make fixes to prevent a null pointer exception occurs (#1667)
Bumps [golang.org/x/net](https:/golang/net) from 0.10.0 to 0.17.0.
- [Commits](golang/net@v0.10.0...v0.17.0)

---
updated-dependencies:
- dependency-name: golang.org/x/net
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
)

Bumps [golang.org/x/net](https:/golang/net) from 0.10.0 to 0.17.0.
- [Commits](golang/net@v0.10.0...v0.17.0)

---
updated-dependencies:
- dependency-name: golang.org/x/net
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
@ubogdan
Copy link
Contributor Author

ubogdan commented Oct 18, 2024

@sdghchj can you please give a hand here, we have 2 unit tests failing ...

@sdghchj
Copy link
Member

sdghchj commented Oct 19, 2024

My pleasure, however what can I do for you?
I have no developing experience about v2 mechanism.
I just doubt v2 was wrongly used.
I see the v2 branch is trying to support OpenAPI specification both V2 and V3, that means it is trying to be compatible with the master branch. But v2 is usually used when the compatibility is broken.
I just tried removing the v2 from the module path and all the import package path in the branch v2-merge you created a few hours ago , then I found the test TestParseGenericsFunctionScoped passed.
So my opinion is remove v2.
@Nerzal Here needs your advice.

@ubogdan
Copy link
Contributor Author

ubogdan commented Oct 19, 2024

@sdghchj No worries about the experience with the v2 branch.

We changed the import path so v2 can be used/tested until the development is ready. The reason is obvious: many community members want OAS3, and a smaller one is open to testing and contributing.
Also, I avoided merging so many changes into the master branch and breaking the v1.x version.

The main reason we are doing this is to keep OAS 2 fixes in sync with v2, This means we can adapt the test import path to "..v2/,,,' .

Keeping both OAS2 and OAS 3 in v2 will be more like transition path, When we consider the development is done we can warn users that we accept only security patches for "OAS2' and we will drop it in v3.

@sdghchj @easonlin404 @Nerzal what is your suggestion here: Should we drop OAS 2 completely in v2?

@ubogdan ubogdan requested review from sdghchj, Nerzal and easonlin404 and removed request for sdghchj October 19, 2024 07:31
@ubogdan
Copy link
Contributor Author

ubogdan commented Oct 19, 2024

@sdghchj Thanks for the tip. Unit tests are fixed now.

@ubogdan ubogdan merged commit 7b50e07 into v2 Oct 19, 2024
9 of 10 checks passed
@ubogdan ubogdan deleted the v2-merge branch October 19, 2024 20:25
@ubogdan ubogdan restored the v2-merge branch October 19, 2024 20:25
ubogdan added a commit that referenced this pull request Oct 19, 2024
ubogdan added a commit that referenced this pull request Oct 19, 2024
@ubogdan ubogdan deleted the v2-merge branch October 19, 2024 20:30
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.