sourcegraph / appdash

Application tracing system for Go, based on Google's Dapper.
https://sourcegraph.com
Other
1.72k stars 137 forks source link

Do not load template data from disk by default. #59

Closed slimsag closed 9 years ago

slimsag commented 9 years ago

Reported on Slack by @rhastamasta who had trouble running Appdash.

Currently we load the template data from disk by default, but it doesn't seem to work in all cases, as he was getting:

template [root.html layout.html]: Asset root.html can't read by error: Error reading asset root.html at ../go/src/sourcegraph.com/sourcegraph/appdash/traceapp/tmpl/root.html: open ../go/src/sourcegraph.com/sourcegraph/appdash/traceapp/tmpl/root.html: no such file or directory
MacBook-Pro:src adu$ pwd
/Users/adu/Workspace/go/src
MacBook-Pro:src adu$ l
total 0
0 drwxr-xr-x   6 adu  1955793164   204B Apr  3 10:47 .
0 drwxr-xr-x   5 adu  1955793164   170B Mar 11 14:20 ..
0 drwxr-xr-x   3 adu  1955793164   102B Mar 11 14:20 bitbucket.org
0 drwxr-xr-x   3 adu  1955793164   102B Mar 11 14:20 code.google.com
0 drwxr-xr-x  21 adu  1955793164   714B Apr  6 10:09 github.com
0 drwxr-xr-x   3 adu  1955793164   102B Apr  3 10:47 sourcegraph.com

The solution in this case is to determine why Appdash doesn't load assets relative to the proper $GOPATH variable (/Users/adu/Workspace/go above) or simply require go generate to be ran during development / modification of template files.