About replacing all non word characters by underscores: it would be great if we could allow more characters, because Graphite allows more characters than that.

I tried to dig in Graphite's code to find the exact list of allowed characters, but to no avail. In fact Carbon can use a lot of characters on Unix, only / and null are forbidden, but currently graphite-web can't handle parenthesis, UTF-8, etc.

I think that until we have a clear view on what's allowed on Graphite's side, we have to stick to the current behavior.

You'll find some info in this issue: graphite-project/graphite-web#242