Can't Delete Draft Change

1,641 views
Skip to first unread message

Troy Perales

unread,
Nov 1, 2012, 11:03:23 AM11/1/12
to repo-d...@googlegroups.com
I can't delete a draft change for which I am the owner of. These are the general steps:
  1. Uploaded draft change
  2. Uploaded Patch Set 2 to draft change
  3. Rebased draft change though "Rebase Change" UI button, producing Patch Set 3
  4. Deleted draft change through "Delete Draft Change" UI button.
  5. Gerrit throws "Application Error: The page you requested was not found, or you do not have permission to view this page."
  6. Now the draft change only shows Patch Set 3 and throws the same error when I try to delete it through the UI.
I have been able to successfully delete other draft changes through the UI. Any suggestions on getting rid of this change? Am I missing a permission since this was rebased and the committer is Gerrit? I'd like to delete it through the UI, if possible.

Running Gerrit 2.4.2

Edwin Kempin

unread,
Nov 1, 2012, 11:22:52 AM11/1/12
to Troy Perales, repo-d...@googlegroups.com


2012/11/1 Troy Perales <tper...@esi-estech.com>

I can't delete a draft change for which I am the owner of. These are the general steps:
  1. Uploaded draft change
  2. Uploaded Patch Set 2 to draft change
  3. Rebased draft change though "Rebase Change" UI button, producing Patch Set 3
In Gerrit 2.4 rebasing a draft patch-set wrongly creates a non-draft patch set [1]. Afterwards the change is not a draft change anymore and can't be deleted. This bug was fixed in Gerrit 2.5.

[1] http://code.google.com/p/gerrit/issues/detail?id=1558
 
  1. Deleted draft change through "Delete Draft Change" UI button.
  2. Gerrit throws "Application Error: The page you requested was not found, or you do not have permission to view this page."
  3. Now the draft change only shows Patch Set 3 and throws the same error when I try to delete it through the UI.
I have been able to successfully delete other draft changes through the UI. Any suggestions on getting rid of this change? Am I missing a permission since this was rebased and the committer is Gerrit? I'd like to delete it through the UI, if possible.

Running Gerrit 2.4.2

Troy Perales

unread,
Nov 1, 2012, 11:35:11 AM11/1/12
to repo-d...@googlegroups.com, Troy Perales


On Thursday, November 1, 2012 10:22:56 AM UTC-5, Edwin Kempin wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>
I can't delete a draft change for which I am the owner of. These are the general steps:
  1. Uploaded draft change
  2. Uploaded Patch Set 2 to draft change
  3. Rebased draft change though "Rebase Change" UI button, producing Patch Set 3
In Gerrit 2.4 rebasing a draft patch-set wrongly creates a non-draft patch set [1]. Afterwards the change is not a draft change anymore and can't be deleted. This bug was fixed in Gerrit 2.5.

[1] http://code.google.com/p/gerrit/issues/detail?id=1558
 
Thanks for the clarification. I didn't think it applied to me since the commit still says "DRAFT", as well as the status.

After updating to 2.5, will I be able to delete this specific change? 

Edwin Kempin

unread,
Nov 1, 2012, 11:38:03 AM11/1/12
to Troy Perales, repo-d...@googlegroups.com


2012/11/1 Troy Perales <tper...@esi-estech.com>



On Thursday, November 1, 2012 10:22:56 AM UTC-5, Edwin Kempin wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>
I can't delete a draft change for which I am the owner of. These are the general steps:
  1. Uploaded draft change
  2. Uploaded Patch Set 2 to draft change
  3. Rebased draft change though "Rebase Change" UI button, producing Patch Set 3
In Gerrit 2.4 rebasing a draft patch-set wrongly creates a non-draft patch set [1]. Afterwards the change is not a draft change anymore and can't be deleted. This bug was fixed in Gerrit 2.5.

[1] http://code.google.com/p/gerrit/issues/detail?id=1558
 
Thanks for the clarification. I didn't think it applied to me since the commit still says "DRAFT", as well as the status.

After updating to 2.5, will I be able to delete this specific change? 
No, I don't think so. What I meant is that with 2.5 rebasing a draft patch set from the UI will create a draft patch set.

Edwin Kempin

unread,
Nov 1, 2012, 12:04:16 PM11/1/12
to Troy Perales, repo-d...@googlegroups.com


2012/11/1 Troy Perales <tper...@esi-estech.com>
On Thu, Nov 1, 2012 at 10:38 AM, Edwin Kempin <edwin....@gmail.com> wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>


On Thursday, November 1, 2012 10:22:56 AM UTC-5, Edwin Kempin wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>
I can't delete a draft change for which I am the owner of. These are the general steps:
  1. Uploaded draft change
  2. Uploaded Patch Set 2 to draft change
  3. Rebased draft change though "Rebase Change" UI button, producing Patch Set 3
In Gerrit 2.4 rebasing a draft patch-set wrongly creates a non-draft patch set [1]. Afterwards the change is not a draft change anymore and can't be deleted. This bug was fixed in Gerrit 2.5.

[1] http://code.google.com/p/gerrit/issues/detail?id=1558
 
Thanks for the clarification. I didn't think it applied to me since the commit still says "DRAFT", as well as the status.

After updating to 2.5, will I be able to delete this specific change? 
No, I don't think so. What I meant is that with 2.5 rebasing a draft patch set from the UI will create a draft patch set.

Is there any way to delete these orphan draft changes with admin access to the server or any permission?
Why do you not simply abandon this change? As admin you can of course always delete the change data from the database tables and from the git ropistory.
 

Troy Perales

unread,
Nov 1, 2012, 12:23:09 PM11/1/12
to Edwin Kempin, repo-d...@googlegroups.com
On Thu, Nov 1, 2012 at 11:04 AM, Edwin Kempin <edwin....@gmail.com> wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>
On Thu, Nov 1, 2012 at 10:38 AM, Edwin Kempin <edwin....@gmail.com> wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>


On Thursday, November 1, 2012 10:22:56 AM UTC-5, Edwin Kempin wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>
I can't delete a draft change for which I am the owner of. These are the general steps:
  1. Uploaded draft change
  2. Uploaded Patch Set 2 to draft change
  3. Rebased draft change though "Rebase Change" UI button, producing Patch Set 3
In Gerrit 2.4 rebasing a draft patch-set wrongly creates a non-draft patch set [1]. Afterwards the change is not a draft change anymore and can't be deleted. This bug was fixed in Gerrit 2.5.

[1] http://code.google.com/p/gerrit/issues/detail?id=1558
 
Thanks for the clarification. I didn't think it applied to me since the commit still says "DRAFT", as well as the status.

After updating to 2.5, will I be able to delete this specific change? 
No, I don't think so. What I meant is that with 2.5 rebasing a draft patch set from the UI will create a draft patch set.

Is there any way to delete these orphan draft changes with admin access to the server or any permission?
Why do you not simply abandon this change? As admin you can of course always delete the change data from the database tables and from the git ropistory.

That was my problem. I kept using the "--delete" flag instead of "--abandon". Thanks again for your help.

Troy Perales

unread,
Nov 1, 2012, 11:43:52 AM11/1/12
to Edwin Kempin, repo-d...@googlegroups.com
On Thu, Nov 1, 2012 at 10:38 AM, Edwin Kempin <edwin....@gmail.com> wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>


On Thursday, November 1, 2012 10:22:56 AM UTC-5, Edwin Kempin wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>
I can't delete a draft change for which I am the owner of. These are the general steps:
  1. Uploaded draft change
  2. Uploaded Patch Set 2 to draft change
  3. Rebased draft change though "Rebase Change" UI button, producing Patch Set 3
In Gerrit 2.4 rebasing a draft patch-set wrongly creates a non-draft patch set [1]. Afterwards the change is not a draft change anymore and can't be deleted. This bug was fixed in Gerrit 2.5.

[1] http://code.google.com/p/gerrit/issues/detail?id=1558
 
Thanks for the clarification. I didn't think it applied to me since the commit still says "DRAFT", as well as the status.

After updating to 2.5, will I be able to delete this specific change? 
No, I don't think so. What I meant is that with 2.5 rebasing a draft patch set from the UI will create a draft patch set.

Is there any way to delete these orphan draft changes with admin access to the server or any permission?
  1. Deleted draft change through "Delete Draft Change" UI button.
  1. Gerrit throws "Application Error: The page you requested was not found, or you do not have permission to view this page."
  2. Now the draft change only shows Patch Set 3 and throws the same error when I try to delete it through the UI.
I have been able to successfully delete other draft changes through the UI. Any suggestions on getting rid of this change? Am I missing a permission since this was rebased and the committer is Gerrit? I'd like to delete it through the UI, if possible.

Running Gerrit 2.4.2

--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

sebastia...@tieto.com

unread,
Jun 25, 2013, 5:58:44 AM6/25/13
to repo-d...@googlegroups.com, Troy Perales


On Thursday, 1 November 2012 17:04:19 UTC+1, Edwin Kempin wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>
On Thu, Nov 1, 2012 at 10:38 AM, Edwin Kempin <edwin....@gmail.com> wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>


On Thursday, November 1, 2012 10:22:56 AM UTC-5, Edwin Kempin wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>
I can't delete a draft change for which I am the owner of. These are the general steps:
  1. Uploaded draft change
  2. Uploaded Patch Set 2 to draft change
  3. Rebased draft change though "Rebase Change" UI button, producing Patch Set 3
In Gerrit 2.4 rebasing a draft patch-set wrongly creates a non-draft patch set [1]. Afterwards the change is not a draft change anymore and can't be deleted. This bug was fixed in Gerrit 2.5.

[1] http://code.google.com/p/gerrit/issues/detail?id=1558
 
Thanks for the clarification. I didn't think it applied to me since the commit still says "DRAFT", as well as the status.

After updating to 2.5, will I be able to delete this specific change? 
No, I don't think so. What I meant is that with 2.5 rebasing a draft patch set from the UI will create a draft patch set.

Is there any way to delete these orphan draft changes with admin access to the server or any permission?
Why do you not simply abandon this change? As admin you can of course always delete the change data from the database tables and from the git ropistory.

What if someone pushed for review some code which should not be disclosed and therefore leaving it even in the abandoned patch-set is not intended.
Can you state the procedure for gerrit admin to completely prune such abandoned patch sets?
 

Saša Živkov

unread,
Jun 25, 2013, 11:28:59 AM6/25/13
to sebastia...@tieto.com, repo-d...@googlegroups.com, Troy Perales
On Tue, Jun 25, 2013 at 11:58 AM, <sebastia...@tieto.com> wrote:


On Thursday, 1 November 2012 17:04:19 UTC+1, Edwin Kempin wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>

On Thu, Nov 1, 2012 at 10:38 AM, Edwin Kempin <edwin....@gmail.com> wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>


On Thursday, November 1, 2012 10:22:56 AM UTC-5, Edwin Kempin wrote:


2012/11/1 Troy Perales <tper...@esi-estech.com>
I can't delete a draft change for which I am the owner of. These are the general steps:
  1. Uploaded draft change
  2. Uploaded Patch Set 2 to draft change
  3. Rebased draft change though "Rebase Change" UI button, producing Patch Set 3
In Gerrit 2.4 rebasing a draft patch-set wrongly creates a non-draft patch set [1]. Afterwards the change is not a draft change anymore and can't be deleted. This bug was fixed in Gerrit 2.5.

[1] http://code.google.com/p/gerrit/issues/detail?id=1558
 
Thanks for the clarification. I didn't think it applied to me since the commit still says "DRAFT", as well as the status.

After updating to 2.5, will I be able to delete this specific change? 
No, I don't think so. What I meant is that with 2.5 rebasing a draft patch set from the UI will create a draft patch set.

Is there any way to delete these orphan draft changes with admin access to the server or any permission?
Why do you not simply abandon this change? As admin you can of course always delete the change data from the database tables and from the git ropistory.

What if someone pushed for review some code which should not be disclosed and therefore leaving it even in the abandoned patch-set is not intended.
Can you state the procedure for gerrit admin to completely prune such abandoned patch sets?

In the Git repository remove the references to these patch-sets:
$ git update-ref -d refs/changes/...
the ref-name is visible from the web UI of that change.

In the database check the changes and patch_sets tables.
The structure should be quite obvious and you will find easily what you have to delete.

 
 

  1. Deleted draft change through "Delete Draft Change" UI button.
  2. Gerrit throws "Application Error: The page you requested was not found, or you do not have permission to view this page."
  3. Now the draft change only shows Patch Set 3 and throws the same error when I try to delete it through the UI.
I have been able to successfully delete other draft changes through the UI. Any suggestions on getting rid of this change? Am I missing a permission since this was rebased and the committer is Gerrit? I'd like to delete it through the UI, if possible.

Running Gerrit 2.4.2

--
To unsubscribe, email repo-discuss...@googlegroups.com
More info at http://groups.google.com/group/repo-discuss?hl=en

--
To unsubscribe, email repo-discuss...@googlegroups.com



--
---
You received this message because you are subscribed to the Google Groups "Repo and Gerrit Discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to repo-discuss...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
 
 

Reply all
Reply to author
Forward
0 new messages