intellij-elixir
intellij-elixir copied to clipboard
Error when opening an Elixir file.
System
Plugin Version: 13.2.0 Application: IntelliJ IDEA Ultimate Edition (2022.2) Operating System: Linux (5.15.0-43-generic)
What I was doing
Opening an Elixir file. This error and the request to submit it came up immediately after opening. It wasn't the first Elixir file that I opened, but it did have comparatively much more inline documentation than the couple of other files I had opened. No other actions were readily associated with the error.
I had just installed the Elixir plugin for the first time and was opening a couple files to see what they looked like in Intellij; no editing, or other manipulation had occurred yet. This was also a fresh install of Intellij IDEA; I had imported settings via Setting Repository (I use DataGrip as well), but that was the only change I've made to Intellij IDEA prior to the error.
Event
Message
Element
File
From: /home/scb/source/outreach/toml-elixir/lib/toml.ex:1
Context
defmodule Toml do
@moduledoc File.read!(Path.join([__DIR__, "..", "README.md"]))
@type key :: binary | atom | term
@type opt ::
{:keys, :atoms | :atoms! | :string | (key -> term)}
| {:filename, String.t()}
From: /home/scb/source/outreach/toml-elixir/lib/toml.ex:0-6
Element Class Name
org.elixir_lang.psi.impl.ElixirAccessExpressionImpl
Exception
Stacktrace
java.lang.Throwable: Do not know whether to inject Markdown in documentation
java.lang.Throwable: Do not know whether to inject Markdown in documentation
at org.elixir_lang.errorreport.Logger.error(Logger.kt:45)
at org.elixir_lang.errorreport.Logger.error(Logger.kt:25)
at org.elixir_lang.injection.markdown.Injector.getLanguagesToInjectInQuote(Injector.kt:47)
at org.elixir_lang.injection.markdown.Injector.getLanguagesToInject(Injector.kt:22)
Yeah, I never saw a File.read!
as the value of @moduledoc
, so this is telling me it appears in the ecosystem and that I should consider handling it.
In this specific case you’re including a file that is already Markdown and the language injector framework supplied by JetBrains will already being doing the right thing in the README.md as long as your code blocks are tagged with elixir
:
```elixir
I’ll mark this as a bug to ignore File.read!
as a value here.