Skip to content
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

wiki: keeping a check on wiki page creation/edits #27313

Closed
mfrw opened this issue Aug 28, 2018 · 14 comments
Closed

wiki: keeping a check on wiki page creation/edits #27313

mfrw opened this issue Aug 28, 2018 · 14 comments
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone

Comments

@mfrw
Copy link
Contributor

mfrw commented Aug 28, 2018

All must have noticed in the past few days attempts by people to create a random page on the wiki.
I was wondering if there was a way we could check this.
Although this is not an issue related to the language, I thought of raising it here as all of us can not religiously follow the mailing list.

@ianlancetaylor ianlancetaylor changed the title Keeping a check on wiki page creation. website: keeping a check on wiki page creation Aug 28, 2018
@ianlancetaylor
Copy link
Contributor

Does GitHub provide any way to subscribe to changes in the wiki?

@ianlancetaylor ianlancetaylor added this to the Unreleased milestone Aug 28, 2018
@ianlancetaylor ianlancetaylor added the NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one. label Aug 28, 2018
@ALTree
Copy link
Member

ALTree commented Aug 30, 2018

Does GitHub provide any way to subscribe to changes in the wiki?

AFAIK you can subscribe to the whole repo and you'll get everything that happens (PR, issues and changes on the wiki), but you can't just subscribe to the wiki.

@ianlancetaylor
Copy link
Contributor

I "watch" the repo. Is that how you subscribe? I get e-mail for every pull request and every issue, but I don't get anything about changes to the wiki.

@ALTree
Copy link
Member

ALTree commented Aug 30, 2018

Yes I was talking about "watch repo". Mmh. Maybe I'm wrong about the wiki emails. I thought you could get emails about everything you see in https://github.com/orgs/golang/dashboard and I see wiki changes there (under "All activity") but if you don't receive emails then maybe that's not true.

@FiloSottile
Copy link
Contributor

The wiki is a git repo, so we can run a cron fetching and diffing.

@crvv
Copy link
Contributor

crvv commented Jan 18, 2019

The wiki is a git repo, but it doesn't have other features of a normal GitHub repo.
There is a workaround.
https://www.growingwiththeweb.com/2016/07/enabling-pull-requests-on-github-wikis.html

Create a new repo, like github.com/golang/go-wiki and use pull request to edit.
In github.com/golang/go, enable Restrict editing to collaborators only in the wiki settings.
And set up a CI(travis-ci in the link) to sync the new repo and github.com/golang/go.wiki.

I think this is a good solution.
This can prevent #29738.

@dmitshur dmitshur changed the title website: keeping a check on wiki page creation wiki: keeping a check on wiki page creation/edits Jan 18, 2019
@dmitshur
Copy link
Contributor

dmitshur commented Jan 18, 2019

I think we should take a first step of making it possible to subscribe/watch for wiki page creation/edits, before considering adding barriers (and review workload) to wiki page edits.

We currently have a golang-codereviews mailing list where all new CLs and CL comments are copied to. People can use it to subscribe to notifications for CLs.

We can create a similar golang-wikichanges mailing list where new wiki pages and existing page edits are copied. I discussed this idea with @ianlancetaylor and it sounded okay to him. /cc @bradfitz @andybons

In addition to the wiki being a git repo, GitHub API v3 has an endpoint to list all events for a repository:

https://developer.github.com/v3/activity/events/#list-repository-events

One of the events is a wiki page creation/edit event:

https://developer.github.com/v3/activity/events/types/#gollumevent

If there are no objections or improvement suggestions, I can look into setting up a service (or add to an existing one) that watches for wiki events and mails a new golang-wikichanges mailing list.

@dmitshur dmitshur self-assigned this Jan 18, 2019
@bradfitz
Copy link
Contributor

The wiki is also in git, so we could have our maintnerd config start mirroring the metadata for:

https://github.com/golang/go.wiki.git

Not sure if that helps here, but we should probably do it for the future anyway, as it's cheap, and it's nice to have all the contributions in one place for querying.

@andybons
Copy link
Member

I have no objections. Am I correct that this would manifest itself as (to start):

Every wiki page change is emailed to golang-wikichanges@ as a diff ?

@dmitshur dmitshur removed their assignment Jan 18, 2019
@dmitshur
Copy link
Contributor

dmitshur commented Jan 18, 2019

That's my understanding.

I think it'll be nice if all updates for the same page are grouped in email threads. That means using the same email title. Using the page title both for "page created" and "page edited" events should achieve that.

@andybons
Copy link
Member

I have something up and running sending emails to golang-wikichanges@googlegroups.com. Example email: https://groups.google.com/forum/#!topic/golang-wikichanges/c25X5t0-8b0

@gopherbot
Copy link

Change https://golang.org/cl/158642 mentions this issue: x/build/cloudfns: send email updates when the wiki changes

gopherbot pushed a commit to golang/build that referenced this issue Jan 29, 2019
This change introduces two cloud functions: wikiwebhook and
sendwikidiff. The former handles GitHub Wiki change events
sent over HTTP and enqueues them on a pubsub topic for the
latter to pick up. sendwikidiff then checks out the wiki
repo and sends an email with the diff of the change to
golang-wikichanges@.

The reason it is split into two functions is due to GitHub’s
timeout limit on webhook handlers (ten seconds). In testing,
a cold boot of a function that does everything described
above would sometimes hit that limit.

Updates golang/go#27313

Change-Id: I1974e1434c7003482df724d6ea3b537e22231c36
Reviewed-on: https://go-review.googlesource.com/c/158642
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
@agnivade
Copy link
Contributor

@andybons - Looks like the mailing list is up and running. Is there anything pending here ?

@andybons
Copy link
Member

I don't believe so. Closing.

@golang golang locked and limited conversation to collaborators Aug 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
FrozenDueToAge NeedsInvestigation Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Projects
None yet
Development

No branches or pull requests

10 participants