Skip to content

Commit a9483fa

Browse files
committed
Fix spec version
The SDK release 0.3.0 should produce events with spec version 0.3.0, but it was still using 0.2.0, so fixing that. PackageURL produced a new v0.1.1 release that includes the OCI type in the go SDK, so pulling that in as oci is the type we use in the spec Signed-off-by: Andrea Frittoli <[email protected]>
1 parent 1a3b71a commit a9483fa

10 files changed

+11
-11
lines changed

go.mod

+1-1
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ require (
66
github.com/cloudevents/sdk-go/v2 v2.10.1
77
github.com/google/go-cmp v0.5.8
88
github.com/google/uuid v1.1.2
9-
github.com/package-url/packageurl-go v0.1.0
9+
github.com/package-url/packageurl-go v0.1.1
1010
github.com/santhosh-tekuri/jsonschema/v5 v5.0.0
1111
golang.org/x/text v0.3.7
1212
)

go.sum

+2-2
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ github.com/modern-go/reflect2 v0.0.0-20180701023420-4b7aa43c6742/go.mod h1:bx2lN
3737
github.com/modern-go/reflect2 v1.0.2 h1:xBagoLtFs94CBntxluKeaWgTMpvLxC4ur3nMaC9Gz0M=
3838
github.com/modern-go/reflect2 v1.0.2/go.mod h1:yWuevngMOJpCy52FWWMvUC8ws7m/LJsjYzDa0/r8luk=
3939
github.com/niemeyer/pretty v0.0.0-20200227124842-a10e7caefd8e/go.mod h1:zD1mROLANZcx1PVRCS0qkT7pwLkGfwJo4zjcN/Tysno=
40-
github.com/package-url/packageurl-go v0.1.0 h1:efWBc98O/dBZRg1pw2xiDzovnlMjCa9NPnfaiBduh8I=
41-
github.com/package-url/packageurl-go v0.1.0/go.mod h1:C/ApiuWpmbpni4DIOECf6WCjFUZV7O1Fx7VAzrZHgBw=
40+
github.com/package-url/packageurl-go v0.1.1 h1:KTRE0bK3sKbFKAk3yy63DpeskU7Cvs/x/Da5l+RtzyU=
41+
github.com/package-url/packageurl-go v0.1.1/go.mod h1:uQd4a7Rh3ZsVg5j0lNyAfyxIeGde9yrlhjF78GzeW0c=
4242
github.com/pkg/diff v0.0.0-20210226163009-20ebb0f2a09e/go.mod h1:pJLUxLENpZxwdsKMEsNbx1VGcRFpLqf3715MtcvvzbA=
4343
github.com/pkg/errors v0.8.1/go.mod h1:bwawxfHBFNV+L2hUp1rHADufV3IMtnDRdf1r5NINEl0=
4444
github.com/pkg/errors v0.9.1 h1:FEBLx1zS214owpjy7qsBeixbURkuhQAwrK5UwLGTwt4=

pkg/api/tests/examples/future_event_major_version.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"context": {
3-
"version": "0.2.0",
3+
"version": "0.3.0",
44
"id": "271069a8-fc18-44f1-b38f-9d70a1695819",
55
"source": "/event/source/123",
66
"type": "dev.cdevents.foosubject.barpredicate.999.0.0",

pkg/api/tests/examples/future_event_minor_version.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"context": {
3-
"version": "0.2.0",
3+
"version": "0.3.0",
44
"id": "271069a8-fc18-44f1-b38f-9d70a1695819",
55
"source": "/event/source/123",
66
"type": "dev.cdevents.foosubject.barpredicate.1.999.0",

pkg/api/tests/examples/future_event_patch_version.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"context": {
3-
"version": "0.2.0",
3+
"version": "0.3.0",
44
"id": "271069a8-fc18-44f1-b38f-9d70a1695819",
55
"source": "/event/source/123",
66
"type": "dev.cdevents.foosubject.barpredicate.1.2.999",

pkg/api/tests/examples/implicit_json_custom_data.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"context": {
3-
"version": "0.2.0",
3+
"version": "0.3.0",
44
"id": "271069a8-fc18-44f1-b38f-9d70a1695819",
55
"source": "/event/source/123",
66
"type": "dev.cdevents.foosubject.barpredicate.1.2.3",

pkg/api/tests/examples/json_custom_data.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"context": {
3-
"version": "0.2.0",
3+
"version": "0.3.0",
44
"id": "271069a8-fc18-44f1-b38f-9d70a1695819",
55
"source": "/event/source/123",
66
"type": "dev.cdevents.foosubject.barpredicate.1.2.3",

pkg/api/tests/examples/non_json_custom_data.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"context": {
3-
"version": "0.2.0",
3+
"version": "0.3.0",
44
"id": "271069a8-fc18-44f1-b38f-9d70a1695819",
55
"source": "/event/source/123",
66
"type": "dev.cdevents.foosubject.barpredicate.1.2.3",

pkg/api/tests/examples/past_event_patch_version.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"context": {
3-
"version": "0.2.0",
3+
"version": "0.3.0",
44
"id": "271069a8-fc18-44f1-b38f-9d70a1695819",
55
"source": "/event/source/123",
66
"type": "dev.cdevents.foosubject.barpredicate.1.2.0",

pkg/api/types.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ import (
3030

3131
const (
3232
EventTypeRoot = "dev.cdevents"
33-
CDEventsSpecVersion = "0.2.0"
33+
CDEventsSpecVersion = "0.3.0"
3434
CDEventsSchemaURLTemplate = "https://cdevents.dev/%s/schema/%s-%s-event"
3535
CDEventsTypeRegex = "^dev\\.cdevents\\.(?P<subject>[a-z]+)\\.(?P<predicate>[a-z]+)\\.(?P<version>.*)$"
3636
)

0 commit comments

Comments
 (0)