Page MenuHomePhabricator

Initializing the new MediaWiki Submodules "removes" local repository with lost of unstaged code.
Closed, InvalidPublicBUG REPORT

Description

List of steps to reproduce (step by step, including full links if applicable):

  • checkout mediawiki 1.38.0-wmf.4

What happens?:
While checking out the new release candidate, my local Extensions and Skins have been removed from my machine, due to the introduction of "submodules" within the main MediaWiki repository. This incurred in lost of work that I did in the previous days

What should have happened instead?:

  • I would have liked my existing extension to remain intact

Software version (if not a Wikimedia wiki), browser information, screenshots, other information, etc:

  • I use GitKraken as my source control software
  • The folder seems to have been "erased" as soon as I checked out the latest branch
  • GitKraken automatically initialize the Submodule on pull
  • There may be no actual solution for the problem, but it may be worth mentioning it as a warning as some people may lose work like I did

Event Timeline

While checking out the new release candidate

mediawiki 1.38.0-wmf.4 is not a release candidate, far from it. It is a branch used for WMF deployment purposes, and is setup specifically for that purpose. They are generally not advised for use by 3rd parties.

Sorry for the miss-use of verbiage about the "release candidate". I work with one of the project (MediaSearch and Abstract Wikipedia) and I was trying to reproduce a bug raised that I could not reproduce locally.

I was having a chat with Kosta in slack and he suggested to open a phabricator task to highlight the issue as it could be quite disruptive for people (I have lost over 2 hours trying to set everything up again, and I have to re-develop my latest stories too).

I don’t know about GitKraken, but you should be able to get a lot of it back using the ‘git reflog’

I’m honestly not sure where you would document this that people would see. git by default won’t just delete things, and will stop if changes are conflicts. And would require you to explicitly delete untracked files etc. I don’t know what GitKraken actually does by default

I would imagine saving other work in a dynamic repo like MW core probably isn’t the best.

The folder seems to have been "erased" as soon as I checked out the latest branch

The folder?

Can you clarify what actual setup you were using?

Were these changes locally commited changes? Were they uncommitted local files?

Pppery subscribed.

I agree with Reedy that Wikimedia has no reason to support what you are doing. And this task is long obsolete anyway. Let's close it.