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

x/tools/cmd/present: playground stopped working on Google App Engine #15981

Closed
peggyl opened this issue Jun 6, 2016 · 8 comments
Closed

x/tools/cmd/present: playground stopped working on Google App Engine #15981

peggyl opened this issue Jun 6, 2016 · 8 comments

Comments

@peggyl
Copy link

@peggyl peggyl commented Jun 6, 2016

Please answer these questions before submitting your issue. Thanks!

  1. What version of Go are you using (go version)?
    go1.6.2 darwin/amd64 (but I don't believe the issue is in the Go version)

Chrome 50.0.2661.102 and Firefox 43.0.4

  1. What operating system and processor architecture are you using (go env)?
    GOARCH="amd64"
    GOBIN=""
    GOEXE=""
    GOHOSTARCH="amd64"
    GOHOSTOS="darwin"
    GOOS="darwin"
    GOPATH="/Users/peggyli/go"
    GORACE=""
    GOROOT="/usr/local/Cellar/go/1.6.2/libexec"
    GOTOOLDIR="/usr/local/Cellar/go/1.6.2/libexec/pkg/tool/darwin_amd64"
    GO15VENDOREXPERIMENT="1"
    CC="clang"
    GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fno-common"
    CXX="clang++"
    CGO_ENABLED="1"
  2. What did you do?
  • Create a new App Engine project, and create local project directory with app.yaml and present/ directory. Existing projects seem unaffected.
  • Create a .slide file that conforms to the present format. It can be very simple - just needs to include .play something.go on one slide. "Hello world" is sufficient.
  • Deploy to GAE.
  • Open in browser, skip to the slide with the play snippet.
  1. What did you expect to see?
    Run button that executes the Go code (i.e. prints "hello world").
  2. What did you see instead?
    No Run button displayed -> unable to run code. Have not disabled -playground (or tried hacking NaCl in GAE or related).

Notes - I haven't had a lot of time to debug, but:

  • play.golang.org works fine, .play examples on talks.golang.org also work.
  • Could not easily reproduce locally with same slide after go get -u golang.org/x/tools/cmd/present
  • No obvious server-side issues, so I hijacked the play.js handler to always return a clean copy of https://talks.golang.org/play.js, which actually seems to fix the problem. Probably worth looking at the diff, but I just haven't had a chance to.
@peggyl
Copy link
Author

@peggyl peggyl commented Jun 8, 2016

As far as I can tell, I copied over tools/cmd/present and deployed before https://go-review.googlesource.com/#/c/21488/8 was merged, leading to an error in the JavaScript console play.js:507 Uncaught ReferenceError: notesEnabled is not defined.

Easily remedied by updating the package, re-copying files, and redeploying, but if this is actually the cause, this feels like a backwards-incompatible change.

@adg
Copy link
Contributor

@adg adg commented Jun 8, 2016

So you were using a present directory copied from an earlier revision of tools, but linking against a newer version of the tools repo?

@quentinmit quentinmit changed the title cmd/present: playground stopped working on Google App Engine x/tools/cmd/present: playground stopped working on Google App Engine Jun 17, 2016
@quentinmit quentinmit added this to the Unreleased milestone Jun 17, 2016
@sbinet
Copy link
Member

@sbinet sbinet commented Jul 1, 2016

AFAICT, cmd/present still works when run locally (just writing a presentation right now) but when the presentation is served from talks.godoc.org the Run button (when clicked) doesn't display what a simple program with println("hello") should (it just displays "Program exited".)
e.g.: http://talks.godoc.org/github.com/sbinet/parisgo/20150417-tuto/slides/parisgo.slide#7

(hum... actually not completely sure this is the same issue than the OP...)

@adg
Copy link
Contributor

@adg adg commented Jul 4, 2016

@peggyl ping: can you confirm my interpretation of your issue report?

@adg
Copy link
Contributor

@adg adg commented Jul 4, 2016

@sbinet that's probably an issue with talks.godoc.org, separate to this one. Care to file an issue at the golang/gddo issue tracker?

@sbinet
Copy link
Member

@sbinet sbinet commented Jul 4, 2016

indeed, that's a duplicate of golang/gddo#418

@agnivade
Copy link
Contributor

@agnivade agnivade commented Apr 24, 2018

ping @peggyl

can you confirm my interpretation of your issue report?

@gopherbot
Copy link

@gopherbot gopherbot commented May 24, 2018

Timed out in state WaitingForInfo. Closing.

(I am just a bot, though. Please speak up if this is a mistake or you have the requested information.)

@gopherbot gopherbot closed this May 24, 2018
@golang golang locked and limited conversation to collaborators May 24, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
6 participants
You can’t perform that action at this time.