Go goes further and encourages code gen, so that will probably be the way you start seeing terrible frameworks being built.
In any case, "configuration as code" doesn't seem like a good definition of "magic" to me.
Also, if load-time aspect-weaving and classpath-scanning-based autodiscovery don't count as magic to you, then not much will. Code generation at least has the huge, huge, humongous advantage that you have code on disk that you can read and debug.
I also admire Racket's macro system for coming with IDE support for introspecting and debugging the code generated by macros. Macros are a much better design because they generally run at compile time and they generally only make local code transformations that are much easier to reason about, as opposed to the sweeping global changes a weaver will make.
If the Java community allowed itself to write simple golang-like code the majority of the time, there'd be much less defection to golang in my opinion.