[logging] Add logging to project initialization#8322
Conversation
| } | ||
| } | ||
|
|
||
| protected fun log(): Logger { |
There was a problem hiding this comment.
Out of curiosity: why did you decide to use a function rather than just accessing the field directly?
There was a problem hiding this comment.
Ah, hmmm. Just read your note above:
The log variable from protected val log is internal, and I'm not sure why (despite asking Gemini multiple questions about it). That's why I'm accessing the log from a function instead.
Seems odd. (Will investigate.)
There was a problem hiding this comment.
I tried, but for some reason it's "internal"? I couldn't figure out why. Gemini suggested this is because the logger class is declared internal at some point, but I couldn't find anything related to that in the source code. 🤷 ???
There was a problem hiding this comment.
Are you overriding a log variable in ProjectActivity?
There was a problem hiding this comment.
ProjectActivity is an interface that doesn't seem to have a log variable exposed, and FlutterProjectActivity doesn't label the log var as overridden
| } | ||
|
|
||
| public static Logger createLogger(@NotNull Class<?> logClass) { | ||
| public static @NotNull Logger createLogger(@NotNull Class<?> logClass) { |
This logs any issues from project setup in
FlutterInitializerto our dedicated log file.The log variable from
protected val logis internal, and I'm not sure why (despite asking Gemini multiple questions about it). That's why I'm accessing the log from a function instead.