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

webrpc update from head #11

Open
wants to merge 188 commits into
base: master
Choose a base branch
from
Open

webrpc update from head #11

wants to merge 188 commits into from

Conversation

kipply
Copy link

@kipply kipply commented Apr 23, 2021

No description provided.

@CLAassistant
Copy link

CLAassistant commented Oct 11, 2022

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you all sign our Contributor License Agreement before we can accept your contribution.
0 out of 5 committers have signed the CLA.

❌ VojtechVitek
❌ LukasJenicek
❌ pkieltyka
❌ klaidliadon
❌ austinmilt
You have signed the CLA already but the status is still pending? Let us recheck it.

VojtechVitek and others added 19 commits October 16, 2022 14:28
Remove binary file from the source code
* Exploring Templates functions API

* Implement "dict", "set" and "get" dictionary funcs for templates

This will help us define type mapping in templates

* Re-add some v0.6.0 functions for now

* Refactor dict function, so we can pass it down to sub-templates

* Add type helper funcmaps

* Implement isBaseType function

* Bring back some obsolete functions to keep generators v0.6.0 working

* make diff

* Fix the tests for now

* Fix go.mod after git cherry-pick

* Pass variables to templates via CLI -Flags, add error/fatal funcmaps

* Remove gofmt/goimports for now

* Implement printfStderr and exit funcs

* Move VERSION to gen/ package, expose it as {{.WebrpcGenVersion}}

* Expose {{.WebrpcTarget}} and {{.WebrpcGenCLI}}

* Remove generator specific tests

Each generator repo should be testing the schema/output on its own

* Improve and document the template variables

* Support old -client, -server and -pkg flags

* Remove bunch of golang-specific funcmaps

* Fix tests

* Remove go-specific funcmaps for method inputs/outputs/arguments

* Resolve rebase

* Print "custom" target in case of local dir

* Remove more go-specific funcmaps; rename "first" to "coalesce"

* Gen: Remove all Go-spefific funcmaps/code

* Remove last go-specific funcmaps

* README: Table of generators

* Remove "indent" and rename "stderrPrintf"

* webrpc-gen: Return early when writing to stdout

* webrpc-gen: Print fatal errors to stderr

Otherwise the errors potentially ended up in the generated output file.

* Execute "main" template as the required generator entrypoint

* Add documentation about generator templates

* Generator docs: Document schema object and add TOC

* Document template functions

* Implement minVersion function

* Markdown: Escape column character in a table row

* Document requiring webrpc-gen version from templates

* Improve error message by naming the template after its target

* Collect flags in its own function

* Implement "default" function

* Add "in" function, remove "str" function and gofmt

* Implement ternary, split, first, last functions

* Remove JavaScript-specific template functions

* Finalize template functions for webrpc schema types

* Remove last generic or TS-specific template functions

* Update template functions docs

* Update README & examples with new webrpc-gen targets

* Bring back goimport/gofmt for golang targets

* PR feedback: Use Go 1.16+

* webrpc-gen CLI: Use v0.7.0 as an example target

* Use os.WriteFile() instead of ioutil.WriteFile()

* Improve isGolangTarget() so it works with local templates too

* webrpc-gen -fmt=false: disable automatic code formatting

* Lowercase all template option CLI flags, print target -help

* Lowercase all generator options, update docs

* Regenerate examples: Apply new DO NOT EDIT comment
This allows external tools like https://github.com/golang-cz/go2webrpc to build full webrpc schema.
* Upgrade golang-basics example to chi v4

* Create Go module for golang-basic example
This proves #74 is not caused by TypeScript generator
VojtechVitek and others added 30 commits April 23, 2024 16:16
…le) (#285)

* Update to [email protected]

* Update dependencies (compatible with Go 1.19)

go get -u [email protected] ./...

* Regenerate examples

* make dep-upgrade-all: Require Go 1.19 for now

* Update to [email protected]
* Update to [email protected]

* Regenerate tests/examples
update gitfs dependencies using fork
* don't convert type to string

* enum type

* Support enum in map

* update tests

* move enum to another struct, add example
add tests for new enum methods
Bumps [ws](https://github.com/websockets/ws) from 5.2.2 to 5.2.4.
- [Release notes](https://github.com/websockets/ws/releases)
- [Commits](websockets/ws@5.2.2...5.2.4)

---
updated-dependencies:
- dependency-name: ws
  dependency-type: indirect
...

Signed-off-by: dependabot[bot] <[email protected]>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
https://goreleaser.com/deprecations/#-rm-dist

```
--rm-dist has been deprecated in favor of --clean.
```

This will fix the GoReleaser pipeline in master.
* Update to [email protected]

go get github.com/webrpc/[email protected]

* Fix hello-webrpc example
* parse annotations for service methods

* add annotations to schema

* on deprecate hook when some of the endpoints been deprecated

* regenerate examples

* use request in deprecate hook

* finish annotation parsing

* report deprecated endpoint onRequest

* handle same annotation types separated by comma

* return error OnRequest

* renerate with latest gen-golang tmpl

* sort imports

* regenerate examples

* remove unused annotations from test case

* regenerate examples with latest gen-golang

* use latest gen-golang

* regenerate using latest gen-golang

* add test for deprecated user endpoint

* add onError hook to tests

* enable parsing annotation with multiple values

* regenerate using latest gen-golang
This reverts commit 6e8be5b.
* implement service filtering and apply in golang-basics example

* filter out methods with specific annotation

* transform services to map internally

* match annotation key and value or just annotation type

* remove redundant whitespace trimming
improve annotation parser
* add template version and template target to template vars

* regenerate tests

* add code gen header to schema

* rename fields on schema tmpl
* render schema hash if schema version in ridl is empty

* version format - go dependency like
* update gen-golang to v0.16.0

* update gen-typescript to v0.15.0

* regenerate all examples using latest tmpl versions
* Update examples - add Webrpc header to CORS

* Expose Webrpc header to CORS clients
* gen-golang v0.16.0 -> v0.16.1

* examples

* tests
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.