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

need to lock in version of generators #1236

Merged
merged 3 commits into from
Dec 31, 2019
Merged

need to lock in version of generators #1236

merged 3 commits into from
Dec 31, 2019

Conversation

kensipe
Copy link
Member

@kensipe kensipe commented Dec 30, 2019

Signed-off-by: Ken Sipe kensipe@gmail.com

Follow up to #1211
It is not OK to not lock in the version of the build tool chain.

Also the file gen is out of date :(

Signed-off-by: Ken Sipe <kensipe@gmail.com>
Signed-off-by: Ken Sipe <kensipe@gmail.com>
Signed-off-by: Ken Sipe <kensipe@gmail.com>
@@ -96,7 +96,7 @@ func configCrdsKudoDev_instancesYaml() (*asset, error) {
return nil, err
}

info := bindataFileInfo{name: "config/crds/kudo.dev_instances.yaml", size: 1040, mode: os.FileMode(420), modTime: time.Unix(1576836957, 0)}
info := bindataFileInfo{name: "config/crds/kudo.dev_instances.yaml", size: 0, mode: os.FileMode(0), modTime: time.Unix(0, 0)}
Copy link
Contributor

@alenkacz alenkacz Dec 31, 2019

Choose a reason for hiding this comment

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

hmm I don't understand why were these changes required, can you explain please? Especially the mode and size...

Copy link
Member Author

Choose a reason for hiding this comment

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

generated files should not change if the source does not change... the way bindata.go was originally implemented (which was recent) seems less mature than it should be in a number of ways. this pr resolves that. It isn't ok to have a dirty local repo with a make all or make generate. After a couple of weeks of wonder what was the issue... it was this.

it is the timestamp that is most offensive... it will change based on a new clone of the repo etc. There is a flag to "set" modtime however it doesn't take a 0 or it appears that 0 means generate it. we could set it to 1 but I thought that would be confusing. specifying "no metadata" zeros out modtime... and everything else. It isn't particular useful information for our context... and in most likely case, it was accidental... meaning it wasn't a decision... it was the default behavior.

Copy link
Contributor

Choose a reason for hiding this comment

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

oh I see, so the key is -nometadata. Yeah I did not get that part. Thanks for the explanation

Copy link
Contributor

Choose a reason for hiding this comment

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

thx, for the explanation, @kensipe , I was wondering the same thing as Alena

@@ -85,9 +85,9 @@ deploy-clean:
# Generate code
generate:
ifeq (, $(shell which go-bindata))
go get github.com/go-bindata/go-bindata/go-bindata
go get github.com/go-bindata/go-bindata/go-bindata@v3.1.2
Copy link
Contributor

Choose a reason for hiding this comment

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

👍

Copy link
Contributor

@alenkacz alenkacz left a comment

Choose a reason for hiding this comment

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

👍

@@ -96,7 +96,7 @@ func configCrdsKudoDev_instancesYaml() (*asset, error) {
return nil, err
}

info := bindataFileInfo{name: "config/crds/kudo.dev_instances.yaml", size: 1040, mode: os.FileMode(420), modTime: time.Unix(1576836957, 0)}
info := bindataFileInfo{name: "config/crds/kudo.dev_instances.yaml", size: 0, mode: os.FileMode(0), modTime: time.Unix(0, 0)}
Copy link
Contributor

Choose a reason for hiding this comment

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

oh I see, so the key is -nometadata. Yeah I did not get that part. Thanks for the explanation

@kensipe kensipe merged commit e7244b3 into master Dec 31, 2019
@kensipe kensipe deleted the ken/go-bindata branch December 31, 2019 14:13
ANeumann82 pushed a commit that referenced this pull request Feb 13, 2020
* Locked version go-bindata tool to specific version
* turned off metadata for generated `bindata.go` file

Signed-off-by: Ken Sipe <kensipe@gmail.com>
Signed-off-by: Andreas Neumann <aneumann@mesosphere.com>
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

3 participants