Closed (fixed)
Project:
Flag
Version:
8.x-4.x-dev
Component:
Flag core
Priority:
Normal
Category:
Task
Assigned:
Unassigned
Reporter:
Created:
29 Dec 2014 at 14:36 UTC
Updated:
1 Feb 2015 at 22:04 UTC
Jump to comment: Most recent
Flag 8.x currently resides on Github. This was originally done to avoid a flood of issues and commits while the module was being rewritten. Today, 8.x is fairly stable and all major functionality is in place. Keeping Flag 8.x on Github means a loss of visibility for the module, and is confusing for site builders who are already using the 8.x module on projects.
Migrate the Flag 8.x repository to D.O. This can either be done as a clean commit, or a migration importing all of the Github commit history.
A new version tag will be available in the issue queue. The Flag project page will need to be updated.
N/A.
Comments
Comment #1
klausi+1
I would keep the git history since it potentially contains valuable information why a change was made. And please use the 8.x-Y.x git branch name pattern (not master).
Comment #2
socketwench commentedMaster was only used on github since it's the standard there. ^_^ We'd definitely use a versioned branch on D.O.
Comment #3
socketwench commentedA potential roadblock is that the Travis CI tests are currently failing. They work locally and via the CLI as long as "localhost" is not used as the hostname. I've tried to modify the travis configuration to use an alternate hostname, but it's still failing.
I'm not sure if we'd have the same problems on D.O. I seem to remember Travis is used to power Testbot, but the configuration may be controlled by D.O and not modifiable by contrib projects.
Comment #4
pfrenssen+1 for keeping the git history, I wonder why throwing away the history is even considered as an option.
Comment #5
socketwench commentedThe idea behind not including git history during the early rewrite process isn't as valuable as it is during the "production" phase this repo move would represent. The history also would reference github issue numbers and not D.O issues. It may be a moot point, however, since git logs may only be rarely looked at and the cleanliness gained isn't worth the information loss.
Comment #6
socketwench commentedAdmittedly, I'd love to keep the commit history from github myself. Having only one commit shown for a year's worth of work just seems...unfair.
Mostly, I want input from the other Flag maintainers before I start pushing a branch to D.O.
Comment #7
joachim commented> The idea behind not including git history during the early rewrite process isn't as valuable as it is during the "production" phase this repo move would represent. The history also would reference github issue numbers and not D.O issues. It may be a moot point, however, since git logs may only be rarely looked at and the cleanliness gained isn't worth the information loss.
Hmmmm we maybe should have moved back sooner, but for ages the code on github wasn't up to coding or documentation standards.
Which brings me to my first question: is the D8 branch conforming to coding and documentation standards? That's a requirement for getting code onto d.org. I don't really mind if tests don't pass or things are broken, but the code needs to be ready to be worked on by the community.
It would indeed be a bad thing to lose commit history. But I really would rather avoid the horrible tangle of merges that the github branch has -- that's really not useful to anyone who's going to need to work through the history to, say, understand why a change was made, or when something broke.
So I'm not sure how we proceed -- some judicious cherry-picking and squash merges, but that would require some time poring over the github branch.
Comment #8
socketwench commentedFor the most part. There are some minor issues being flagged by phpcs, and some missing docblocks have slipped through lately due to the hellish month I've been having (lost an Aunt, lost a car, got acquired). I can start poking at that tonight. Also the tests are broken on Travis CI, but not locally. That problem may only exist on Github rather than on D.O's test infrastructure.
There are 800 commits on Github... Somehow I doubt anyone will want to spend the time to clean that up or cherry-pick. The longer we leave the project on Github, the messier that will get too. It might be easier to just accept the mess in the past, but move quickly so future commits will be cleaner.
Comment #9
joachim commented> There are 800 commits on Github... Somehow I doubt anyone will want to spend the time to clean that up or cherry-pick
Yeah... I've just had a quick go with the most recent merge tree... it blew up at the first commit it tried to apply...
How on earth did you manage to make a merge commit with two branches that were BOTH yours???
Please can you make sure once we're back on d.org to always pull before you make commits, and make sure not to create merge commits?
It is a real pain that it's this messy, and it's true that the commit messages aren't that useful as they refer to github pull requests. But people should be credited, so we should keep the history.
While on the subject of credit though, I see @socketwench has at least 3 different versions of author credit. Could you have a go at using http://schacon.github.io/git/git-filter-branch.html / https://help.github.com/articles/changing-author-info/ to tidy that up? That at least will either work quickly or not at all.
Comment #10
joachim commentedHmm, that works, but I'm not sure what to change your credit to: the credit form on this issue says socketwench is --author="rashfeather " which is somewhat confusing.
Comment #11
socketwench commentedYeah. I changed my username a long time ago, but the original one persists in git. I'm not sure if it's worth raising that with the infrastructure team or not.
Comment #12
joachim commented> I'm not sure if it's worth raising that with the infrastructure team or not.
It definitely needs sorting out, as any of your patches that are committed by someone else but marked as authored by you will be wrong.
Comment #13
socketwench commentedIt doesn't according to this issue... https://www.drupal.org/node/1490262#comment-6120108
Comment #14
joachim commentedIn which case, it's not your git username that needs fixing, but the UI on d.org that creates the '--author' part of the suggested git commit command: it should use your d.org username, not your git username.
Comment #15
socketwench commentedYou're actually in the repo in two different ways. Some of these differences are actually from the original D.O repo since I imported history from there.
Hmmm. The 8.x branch starts at commit 369 in the repo. Can we squash the previous commits?
Comment #16
socketwench commentedAlright. I've cleaned up some of the duplicate authors and pushed the changes.
Comment #17
pfrenssenEverything before this is the original history of the module I presume? That comprises years of very valuable history, don't throw it away please!
In my daily work I very much rely on things like
git log -Sto find historical changes to particular strings. The context you can glean from looking at these commits is invaluable.Comment #18
joachim commented> In my daily work I very much rely on things like git log -S to find historical changes to particular strings. The context you can glean from looking at these commits is invaluable.
I agree completely!
> The 8.x branch starts at commit 369 in the repo. Can we squash the previous commits?
I'm not actually sure what's meant by this.
Presumably we're going to end up on d.org with an 8.x-3.x branch which forks off from 7.x-3.x at some point.
There's one bit of git history hacking I'd like to do before pushing 8.x-3.x to d.org, which is remove a merge commit from github's initial commit, which adds a LICENSE.txt file which should never be here.
(I wish we could do more history hacking, but I realize it's a doomed endeavour: whatever we do, a long section of our 8.x-3.x branch is going to have code that's not compliant with coding and docs standards, and whose commit messages refer to github issue numbers -- and hence are lacking in context. I don't remember if it was my suggestion to develop 8.x on github, but for the record, I don't think it was a good idea.)
Comment #19
socketwench commentedYeah, that occurred to me after I replied. It wouldn't really make much of a difference anyways.
I was actually thinking 8.x-4.x given that the module was rewritten, and there are some significant new features (Field Entry link type). It would just be easier to start with a new major version number.
I can see about removing that commit. If nothing else, I can remove the file itself from the repo.
IIRC, I did start the code on D.O but you raised concerns about people using the 8.x branch prematurely and mucking up the issue queue. That was a valid point, but we rarely got any issues posted to the module on Github. We only recently broke 100, and most of them are task reminders to myself. The lack of visibility and commit consistency was the result.
If anything, we should have considered moving the module back to D.O much, much sooner. Perhaps the trigger point should have been when we were finally able to flag entities. That would have been feature-complete-enough to prove that the rewrite wasn't a dead end. That would have lessened the impact of the divergent git logs and leveraged the community rather than requiring a minor PR campaign on my part to raise awareness.
Comment #20
socketwench commentedLicense file removed.
We also have two READMEs. I'd like to do some rewriting and bring it closer to what I did for Flag Friend: http://cgit.drupalcode.org/flag_friend/commit/?id=8c97956ea1149c27ebfef3...
Once that's done, I'll delete the duplicate README from history. According to Berdir, README.md looks like the format going forward. I'll rewrite the content in the existing README.txt, then migrate it over to the *.md file.
Comment #21
socketwench commentedTurns out, you can't change your git username on D.O: https://www.drupal.org/node/2401715#comment-9483767
Comment #22
joachim commentedOk that's our new 8.x-4.x branch pushed to d.org! Hurrah!
Now this is back on d.org, please could we avoid making merge commits, and have commit messages that follow the standard form: https://www.drupal.org/node/52287?
Comment #23
joachim commentedComment #24
joachim commentedIssues still open on github should be moved over to this queue, I think.
Comment #25
socketwench commentedYep. I'll start working on that and converting in-flight PRs to patch issues.
Comment #26
joachim commentedCool!
Could you take take of updating the project page too please? I've just noticed that links through to github.
Comment #27
socketwench commentedOn it.
Comment #28
socketwench commentedDone.
I also made the development snapshots visible on the main page.