home / github

Menu
  • GraphQL API
  • Search all tables

issue_comments

Table actions
  • GraphQL API for issue_comments

16 rows where issue = 655382009 sorted by updated_at descending

✎ View and edit SQL

This data as json, CSV (advanced)

Suggested facets: reactions, created_at (date), updated_at (date)

user 5

  • fujiisoup 6
  • keewis 4
  • max-sixty 3
  • shoyer 2
  • stale[bot] 1

author_association 2

  • MEMBER 15
  • NONE 1

issue 1

  • what is the best way to reset an unintentional direct push to the master · 16 ✖
id html_url issue_url node_id user created_at updated_at ▲ author_association body reactions performed_via_github_app issue
1100945568 https://github.com/pydata/xarray/issues/4218#issuecomment-1100945568 https://api.github.com/repos/pydata/xarray/issues/4218 IC_kwDOAMm_X85Bnxig max-sixty 5635139 2022-04-17T20:34:32Z 2022-04-17T20:34:32Z MEMBER

As long as you don't force push (which is disabled), I think the preferred option for dealing with accidentally pushed changes is to push a "revert" commit generated from git revert

I think that's the right approach, so closing. Feel free to reopen though

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
1100938839 https://github.com/pydata/xarray/issues/4218#issuecomment-1100938839 https://api.github.com/repos/pydata/xarray/issues/4218 IC_kwDOAMm_X85Bnv5X stale[bot] 26384082 2022-04-17T19:43:45Z 2022-04-17T19:43:45Z NONE

In order to maintain a list of currently relevant issues, we mark issues as stale after a period of inactivity

If this issue remains relevant, please comment here or remove the stale label; otherwise it will be marked as closed automatically

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657275143 https://github.com/pydata/xarray/issues/4218#issuecomment-657275143 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzI3NTE0Mw== keewis 14808389 2020-07-12T21:06:38Z 2020-07-12T21:07:33Z MEMBER

this was actually not that dangerous since everyone who synced the git history (i.e. at least @max-sixty) before that accident had a full "backup" of the commit history.

Would it make sense to add a section for "people with commit access" to contributing.rst? I imagine this could be useful as a reference and for new maintainers...

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657273886 https://github.com/pydata/xarray/issues/4218#issuecomment-657273886 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzI3Mzg4Ng== fujiisoup 6815844 2020-07-12T20:55:53Z 2020-07-12T20:55:53Z MEMBER

I think the preferred option for dealing with accidentally pushed changes is to push a "revert" commit generated from git revert

OK, understood.

but as long as we keep the master branch protected, it's always possible always possible to move forward by reverting changes -- there is no way to lose work.

Then, probably the most dangarous part was when I unprotected the master branch. I was afraid of messing up the commit history, but it is much better than losing entire commit history...

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657261588 https://github.com/pydata/xarray/issues/4218#issuecomment-657261588 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzI2MTU4OA== shoyer 1217238 2020-07-12T18:59:08Z 2020-07-12T18:59:08Z MEMBER

But anyways, this is not a big deal at all! Git makes it very easy to mess things up, but as long as we keep the master branch protected, it's always possible always possible to move forward by reverting changes -- there is no way to lose work.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657261331 https://github.com/pydata/xarray/issues/4218#issuecomment-657261331 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzI2MTMzMQ== shoyer 1217238 2020-07-12T18:56:53Z 2020-07-12T18:56:53Z MEMBER

As long as you don't force push (which is disabled), I think the preferred option for dealing with accidentally pushed changes is to push a "revert" commit generated from git revert

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657258662 https://github.com/pydata/xarray/issues/4218#issuecomment-657258662 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzI1ODY2Mg== max-sixty 5635139 2020-07-12T18:30:40Z 2020-07-12T18:30:40Z MEMBER

It looks like @keewis isn't in https://github.com/orgs/pydata/teams/xarray/members so he couldn't change the permissions, can we change that? I think only @shoyer can add people to that team.

Me and @jhamman seem to be in both that team and added to https://github.com/pydata/xarray/settings/access, which seems redundant (though not causing any bad outcomes either)

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657258596 https://github.com/pydata/xarray/issues/4218#issuecomment-657258596 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzI1ODU5Ng== max-sixty 5635139 2020-07-12T18:30:07Z 2020-07-12T18:30:07Z MEMBER

No stress @fujiisoup ! Glad this worked out.

We could disable push access and then people can manually re-enable when necessary. But no strong view.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657210253 https://github.com/pydata/xarray/issues/4218#issuecomment-657210253 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzIxMDI1Mw== keewis 14808389 2020-07-12T11:39:58Z 2020-07-12T13:23:34Z MEMBER

you could try to undo that by: getting the hash of the latest commit (7bf9df9d75c40bcbf2dd28c47204529a76561a3f right now), then calling sh git reset <hash> git push -f

Since I've been afraid of that mistake as well, I added a git hook that makes git refuse to push to master and stable on the main repository (use --no-verify to override it): ```bash $ cat .git/hooks/pre-push

!/usr/bin/env bash

protected_remotes="origin" protected_branches="master stable"

isin() { local list="$1" local substring="$2"

for element in $list
do
    [[ "$element" == "$substring" ]] && return 0;
done

return -1;

}

readonly() { remote="$1" branch="$2"

if isin "$protected_remotes" "$remote" && isin "$protected_branches" "$branch"
then
    return 0;
else
    return -1;
fi

}

remote="$1"

IFS=" " while read local_ref local_sha remote_ref remote_sha do branch="$(echo $remote_ref | sed 's#^refs/heads/##g')" if readonly "$remote" "$branch" then echo "cannot push to $remote/$branch: protected branch. Use --no-verify to override this." exit -1 fi done ```

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657215217 https://github.com/pydata/xarray/issues/4218#issuecomment-657215217 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzIxNTIxNw== fujiisoup 6815844 2020-07-12T12:26:41Z 2020-07-12T12:26:41Z MEMBER

OK, thanks.

So I think either a pre-push hook or git config branch.master.pushRemote no_push (but then you also can't push to your own master anymore) are the best way forward

Agreed. I'll use your pre-push hook. Thanks @keewis .

{
    "total_count": 1,
    "+1": 1,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657213126 https://github.com/pydata/xarray/issues/4218#issuecomment-657213126 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzIxMzEyNg== keewis 14808389 2020-07-12T12:07:49Z 2020-07-12T12:10:35Z MEMBER

see this SO question. However, I don't think we should try that since there are a few cases where you still need to push without a PR (releasing, mainly). So I think either a pre-push hook or git config branch.master.pushRemote no_push (but then you also can't push to your own master anymore) are the best way forward

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657212192 https://github.com/pydata/xarray/issues/4218#issuecomment-657212192 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzIxMjE5Mg== fujiisoup 6815844 2020-07-12T11:59:11Z 2020-07-12T11:59:11Z MEMBER

BTW, is it possible to disallow direct push to master on github? Maybe we only need to merge PRs and but not push.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657211959 https://github.com/pydata/xarray/issues/4218#issuecomment-657211959 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzIxMTk1OQ== fujiisoup 6815844 2020-07-12T11:56:34Z 2020-07-12T11:56:34Z MEMBER

OK. Done. Thanks. I'll use your script. Thanks.

And sorry again for my mistake.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657211714 https://github.com/pydata/xarray/issues/4218#issuecomment-657211714 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzIxMTcxNA== keewis 14808389 2020-07-12T11:54:41Z 2020-07-12T11:54:41Z MEMBER

oh, yeah. Then someone with the appropriate permissions (you? or maybe @shoyer?) has to temporarily remove the branch protection (settings on github), force push, and then add back the branch protection.

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657211712 https://github.com/pydata/xarray/issues/4218#issuecomment-657211712 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzIxMTcxMg== fujiisoup 6815844 2020-07-12T11:54:40Z 2020-07-12T11:54:40Z MEMBER

Maybe I can unprotect the master, but I'm hesitating this action...

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009
657211365 https://github.com/pydata/xarray/issues/4218#issuecomment-657211365 https://api.github.com/repos/pydata/xarray/issues/4218 MDEyOklzc3VlQ29tbWVudDY1NzIxMTM2NQ== fujiisoup 6815844 2020-07-12T11:51:31Z 2020-07-12T11:51:31Z MEMBER

Thanks. but it looks the master is protected and I cannot force push. Total 0 (delta 0), reused 0 (delta 0) remote: error: GH006: Protected branch update failed for refs/heads/master. remote: error: Cannot force-push to this protected branch To https://github.com/pydata/xarray.git ! [remote rejected] master -> master (protected branch hook declined) error: failed to push some refs to 'https://github.com/pydata/xarray.git'

{
    "total_count": 0,
    "+1": 0,
    "-1": 0,
    "laugh": 0,
    "hooray": 0,
    "confused": 0,
    "heart": 0,
    "rocket": 0,
    "eyes": 0
}
  what is the best way to reset an unintentional direct push to the master 655382009

Advanced export

JSON shape: default, array, newline-delimited, object

CSV options:

CREATE TABLE [issue_comments] (
   [html_url] TEXT,
   [issue_url] TEXT,
   [id] INTEGER PRIMARY KEY,
   [node_id] TEXT,
   [user] INTEGER REFERENCES [users]([id]),
   [created_at] TEXT,
   [updated_at] TEXT,
   [author_association] TEXT,
   [body] TEXT,
   [reactions] TEXT,
   [performed_via_github_app] TEXT,
   [issue] INTEGER REFERENCES [issues]([id])
);
CREATE INDEX [idx_issue_comments_issue]
    ON [issue_comments] ([issue]);
CREATE INDEX [idx_issue_comments_user]
    ON [issue_comments] ([user]);
Powered by Datasette · Queries took 14.368ms · About: xarray-datasette