-
Notifications
You must be signed in to change notification settings - Fork 26
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
Metadata less #93
Metadata less #93
Conversation
…uanian: Aš galiu valgyti stiklą ir jis manęs nežeidžia Russian: Я могу есть стекло, оно мне не вредит. Korean: 나는 유리를 먹을 수 있어요. 그래도 아프지 않아요 Hebrew: אני יכול לאכול זכוכית וזה לא מזיק לי. Latin: Vitrum edere possum; mihi non nocet.
this looks very nice, I just had a look at the repo itself and it makes working with filetree and normal git tools much more fluent. BTW, this was the reason I never used filetree for the pharo-core export since there was simply too much noise to recognize any crucial information. nice work |
I'm now thinking that, with this code, I could remove the methodProperties.json file as well, since the Author and timestamp are recorded by the git commit. Thierry |
I haven't had a chance to review your code yet, but the methodProp erties.json file is only there to preserve Monticello meta data ... Dale ----- Original Message ----- | From: "Thierry Goubier" [email protected] | I'm now thinking that, with this code, I could remove the |
Oh. I believed it was used to record the timestamp and creator as recorded in the changes file ? Because there is also the properties.json file as well... But I don't think I should try to get rid of this one. |
The methodProperties.json file records meta data that is part of the Monticello definitions ... Git records the commiter and commit data for each method (file) change, so it should be possible to reconstruct the method meta data from Git and elminate the methodProperties.json file. The properties.json files manage FileTree information and should not/cannot be eliminated... Dale | From: "Thierry Goubier" [email protected] | Oh. I believed it was used to record the timestamp and creator as |
Ok, the next two commits are without the method properties metadata. Now, the timestamp is exclusively the data stored by git upon the commit (i.e. not the real time the method is written, but when it's committed to the git repository). The code is a bit rough, in that it still reads the methodProperties metadata if it is present, but it doesn't do anything with it. If you think it is Ok, I'll clean the code. |
Yeah, we need the timestamp from the definition itself, since it appears to failing the first assertion for timestamp tests ... Ugly, but necessary when it only fails on travis:( |
Well, no chances it can work. I don't have the same issue33 repo as on Travis. On travis, the git sha1 is 4058b81, and I have only one version in the history (Author: DaleHenrichs Time: 28 June 2012, 3:07:37 pm) On my branch, as merged from the pharo 2.0 branch, I have: I think that if I create an issue33.2 repo and update the timestamps, then it should work through the merge. Now, let's look at the next test case. Or does that point to a problem in the way the test repos are copied to travis ? |
Okay ... when travis does a run it does a merge of your branch and the pharo3.0 branch and does a commit .... I think the lesson here is that depending upon a SHA is not quite the same as a UUID ... if you were to checkout a specific commit of the test directory, you might have more luck, but presumably a change to a readme will cause the directory's SHA to be changed? Dale | From: "Thierry Goubier" [email protected] | Same here. | * ver01 should be 65e9904 , on travis it is 4058b81 . | I can add code in the tests to force an alternative checkup on the |
Ok, if it merges against pharo3.0 instead of 2.0 I may be in trouble. CommitID is specific to the package, not to anything in the surroundings. If the Readme is changed, its counted as a new version of the package. I've added the nonsense git sha1 from Travis as special timestamps and commits to try to get the tests to go green. I'm done for tonight. |
Perhaps a different testing strategy is called for? Presumably you don't really care about the UUID of the packages and basing the UUID on the SHA of the commit should be enough. The UUIDs should be equal if a package is loaded from two different repositories checking out the same commit ... so that is what is important ... so perhaps we shouldn't care about the UUID so much (other than to validate that two different checkouts of the same commit give the same UUID ... for the method time stamps the (unfortunate) right answer is to use the timestamp of the last commit of that package .... then at least you will have stable timestamps ... which I think are important and more correct ... Fresh start in morning:) |
Dale, I don't test against the package UUID, just against the git data (commitID, author and date). All that you describe as should be done is the way gitfiletree is doing it (package uuid is sha1 hash of git commit id + package name, timestamp is git commit timestamp, author is git commit author). I strongly believe travis makes a mess of the merge with the test data, and that I am unable to get anything reasonable out of my git queries. |
I know the culprit: Travis L4, git clone -depth=50. This cuts short the git history and removes the commits I was checking for: f8daa1b, 65e9904, 8d225c9. I leave it to you to change the travis CI script and revert this request to 523c789, or keep as it is now since it has additional tests to detect a future git copy mistake, all tracing code has been removed in 62c14ae (but I would suggest changing the ci script, otherwise those tests will start failing in a year or so...). |
Added builderCI issue for the |
Thanks! It's a relief to have been able to solve it. |
Yeah, that was a great bit of sleuthing! |
(Issue #11, #92, #93, #101) Conflicts: repository/MonticelloFileTree-Core.package/MCFileTreeStCypressReader.class/instance/loadVersionInfo.st repository/MonticelloFileTree-Core.package/MCFileTreeStCypressReader.class/methodProperties.json repository/MonticelloFileTree-Core.package/MCFileTreeStCypressWriter.class/instance/writeDefinitions..st repository/MonticelloFileTree-Core.package/MCFileTreeStCypressWriter.class/methodProperties.json repository/MonticelloFileTree-Core.package/MCFileTreeStSnapshotWriter.class/instance/writeDefinitions..st repository/MonticelloFileTree-Core.package/MCFileTreeStSnapshotWriter.class/instance/writeMethodHolderDefinitions.extension.to.do..st repository/MonticelloFileTree-Core.package/MCFileTreeStSnapshotWriter.class/methodProperties.json repository/MonticelloFileTree-Core.package/monticello.meta/version repository/MonticelloFileTree-Tests.package/monticello.meta/version
(Issue #11, #92, #93, #101) Conflicts: README.md repository/MonticelloFileTree-Core.package/MCFileTreeStCypressWriter.class/instance/writeDefinitions..st repository/MonticelloFileTree-Core.package/MCFileTreeStCypressWriter.class/methodProperties.json repository/MonticelloFileTree-Core.package/MCFileTreeStSnapshotWriter.class/instance/writeDefinitions..st repository/MonticelloFileTree-Core.package/MCFileTreeStSnapshotWriter.class/instance/writeMethodHolderDefinitions.extension.to.do..st repository/MonticelloFileTree-Core.package/MCFileTreeStSnapshotWriter.class/methodProperties.json repository/MonticelloFileTree-Core.package/monticello.meta/version repository/MonticelloFileTree-Tests.package/monticello.meta/version
(Issue #11, #92, #93, #101) Conflicts: README.md repository/MonticelloFileTree-Core.package/MCFileTreeStCypressReader.class/instance/loadVersionInfo.st repository/MonticelloFileTree-Core.package/MCFileTreeStCypressWriter.class/instance/writeDefinitions..st repository/MonticelloFileTree-Core.package/MCFileTreeStCypressWriter.class/methodProperties.json repository/MonticelloFileTree-Core.package/MCFileTreeStSnapshotWriter.class/instance/writeDefinitions..st repository/MonticelloFileTree-Core.package/MCFileTreeStSnapshotWriter.class/instance/writeMethodHolderDefinitions.extension.to.do..st repository/MonticelloFileTree-Core.package/MCFileTreeStSnapshotWriter.class/methodProperties.json repository/MonticelloFileTree-Core.package/monticello.meta/version repository/MonticelloFileTree-Tests.package/monticello.meta/version
Dale,
here is the metadata-less version of gitfiletree.
To summarize the features:
It does change the way the repository contents look like (particularly history, version numbers and author), so if you can validate the way it looks (or if others may have a look as well), I'd be happy to have your return.