diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 0000000000..5ddad421e0 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1 @@ +# Changelog \ No newline at end of file diff --git a/CHANGELOG_PENDING.md b/CHANGELOG_PENDING.md new file mode 100644 index 0000000000..e20dcff3d8 --- /dev/null +++ b/CHANGELOG_PENDING.md @@ -0,0 +1,52 @@ +# Unreleased Changes + +## vX.X + +### Upcoming Changes + +- The following flags are pending deprecation and will be removed in the next release: + - `-gasPrice` + - `-s3bucket` + - `-s3creds` + - `-gsbucket` + - `-gskey` + +### Features ⚒ + +#### General + +- \#1759 Log non-nil error when webserver stops (@AlexMapley) +- \#1773 Fix Windows build by downloading pre-configured nasm (@iameli) +- \#1779 Fix "Build from Source" link in the README (@chrishobcroft) +- \#1778 Add live mode to `livepeer_bench` and expose additional metrics (@jailuthra) +- \#1785 Update the Windows build to be fully static and to use go1.15 (@iameli) +- \#1727 Add a `-maxGasPrice` flag to set the maximum gas price to use for transactions (@kyriediculous) +- \#1790 Add changelog process +- \#1791 Switch to Github actions for Linux build and test + +#### Broadcaster + +- \#1754 Count bytes of video data received/sent per stream and expose via the /status endpoint (@darkdragon) +- \#1764 Mark all input errors in LPMS as non-retryable during transcoding (@jailuthra) + +#### Orchestrator + +- \#1731 Add support for webhook to authenticate and set prices for broadcasters at the start of a session (@kyriediculous) +- \#1761 Add a `livepeer_router` binary that can route broadcasters to different orchestrators (@yondonfu) + +### Bug Fixes 🐞 + +#### General + +- \#1729 Make sure the block watcher service can process multiple blocks in a single polling interval (@kyriediculous) +- \#1795 Fix Darwin build by changing optimization flag used for gnutls dependency (@iameli) + +#### Broadcaster + +- \#1766 Flush JSON playlist during recording after it is modified (@jailuthra) +- \#1770 Fix parallel reading from object storage (@darkdragon) + +#### Transcoder + +- \#1775 Fix transcoder load balancer race condition around session cleanup (@jailuthra) +- \#1784 Use auth token sessionID to index into sessions map in transcoder load balancer (@jailuthra) \ No newline at end of file diff --git a/PULL_REQUEST_TEMPLATE.md b/PULL_REQUEST_TEMPLATE.md index a90217e2cd..18cf719244 100644 --- a/PULL_REQUEST_TEMPLATE.md +++ b/PULL_REQUEST_TEMPLATE.md @@ -18,6 +18,8 @@ **Checklist:** -- [ ] README and other documentation updated -- [ ] Node runs in OSX and devenv +- [ ] Read the [contribution guide](./doc/contributing.md) +- [ ] `make` runs successfully - [ ] All tests in `./test.sh` pass +- [ ] README and other documentation updated +- [ ] [Pending changelog](./CHANGELOG_PENDING.md) updated diff --git a/cmd/scripts/linkify_changelog.go b/cmd/scripts/linkify_changelog.go new file mode 100644 index 0000000000..d1cb2d68cd --- /dev/null +++ b/cmd/scripts/linkify_changelog.go @@ -0,0 +1,52 @@ +package main + +import ( + "bufio" + "io/ioutil" + "log" + "os" + "regexp" + "strings" +) + +// Based on https://github.com/tendermint/tendermint/blob/master/scripts/linkify_changelog.py +// This script goes through the provided file, and replaces any " \#", +// with the valid markdown formatted link to it. e.g. +// " [\#number](https://github.com/livepeer/go-livepeer/pull/)" +// Note that if the number is for a an issue, github will auto-redirect you when you click the link. +// It is safe to run the script multiple times in succession. +// +// Example usage $ go run cmd/scripts/linkify_changelog.go CHANGELOG_PENDING.md +func main() { + if len(os.Args) < 2 { + log.Fatal("Expected filename") + } + + fname := os.Args[1] + + f, err := os.Open(fname) + if err != nil { + log.Fatal(err) + } + defer f.Close() + + re, err := regexp.Compile(`\\#([0-9]*)`) + if err != nil { + log.Fatal(err) + } + + var lines []string + scanner := bufio.NewScanner(f) + for scanner.Scan() { + line := re.ReplaceAllString(scanner.Text(), `[#$1](https://github.com/livepeer/go-livepeer/pull/$1)`) + lines = append(lines, line) + } + + if err := scanner.Err(); err != nil { + log.Fatal(err) + } + + if err := ioutil.WriteFile(fname, []byte(strings.Join(lines, "\n")), 0644); err != nil { + log.Fatal(err) + } +} diff --git a/doc/contributing.md b/doc/contributing.md new file mode 100644 index 0000000000..d692498c1e --- /dev/null +++ b/doc/contributing.md @@ -0,0 +1,17 @@ +# Contributing + +## Changelog + +Every change (feature, bug fix, etc.) should be made in a PR that includes an update to the `CHANGELOG_PENDING.md` file which tracks the set of changes that will be included in the next release. + +Changelog entries should be formatted as follows: + +``` +- \#xxx Description of the change (@contributor) +``` + +`xxx` is the PR number (if for whatever reason a PR number cannot be used the issue number is acceptable) and `contributor` is the author of the change. The full link to the PR is not necessary because it will automatically be added when a release is created, but make sure to include the backslash and pound i.e. `\#2313`. + +Changelog entries should be classified based on the `livepeer` mode of operation that they pertain to i.e. General, Broadcaster, Orchestrator, Transcoder. + +Breaking changes should be documented in the "Breaking changes" section. Any changes that involve pending deprecations (i.e. a flag will be removed in the next release) should be documented in the "Upcoming changes" section. \ No newline at end of file diff --git a/doc/releases.md b/doc/releases.md index 287324787f..2c95ca8b77 100644 --- a/doc/releases.md +++ b/doc/releases.md @@ -62,14 +62,25 @@ Once we complete this stage, we prepare a mainnet release. ### Cutting a mainnet release of go-livepeer -First, make the release commit on a branch: +Create the release commit on a branch: -```bash -git checkout -b release-0.5.2 -echo -n '0.5.2' > VERSION -git commit -am 'release v0.5.2' -git push -u origin release-0.5.2 -``` +1. Checkout a release branch + + ```bash + git checkout -b release-0.5.2 + ``` + +2. `echo -n '0.5.2' > VERSION` + +3. Update the changelog + + - Copy all entries from `CHANGELOG_PENDING.md` to the top of `CHANGELOG.md` and update `vX.X` to the new version number + - Run `go run cmd/scripts/linkify_changelog.go CHANGELOG.md` to add links for all PRs + - Reset `CHANGELOG_PENDING.md` + +4. `git commit -am 'release v0.5.2'` + +5. `git push -u origin release-0.5.2` Merge the release commit into `master` via PR. Then, push the release tag up.