<turbo-stream action="append" target="posts_list"><template>    <div class="postbit" id="91976" data-post-id="91976">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="OvermindDL1" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/OvermindDL1/120/2677_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  OvermindDL1
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote group-livebook_core_team" data-username="josevalim" data-post="1" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/48/1787_2.png" class="avatar"> josevalim:</div>
<blockquote>
<p><strong>We promise to keep all warnings relevant and worth of your time, but, as a trade-off, we don’t allow you to disable them</strong> .</p>
</blockquote>
</aside>
<p>Just as a note, I love this!  Never let warnings be disableable!  <img src="https://forum.elixirforum.com/images/emoji/apple/slight_smile.png?v=15" title=":slight_smile:" class="emoji" alt=":slight_smile:" loading="lazy" width="20" height="20"></p>
<p><em>/me wonders if there is a way to pass the warnings_as_errors flag in mix.exs…</em></p>
<p>Overall though, I like the verbose warnings.  It is both telling you what is wrong and often how to fix it, but also is a big thing of “You Need To Stop Doing This Warning Thing”.</p>
<p>But a help catalog could be quite, just as long as the big warnings by default don’t stop.  <img src="https://forum.elixirforum.com/images/emoji/apple/slight_smile.png?v=15" title=":slight_smile:" class="emoji" alt=":slight_smile:" loading="lazy" width="20" height="20"></p>
<aside class="quote group-livebook_core_team" data-username="josevalim" data-post="22" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/48/1787_2.png" class="avatar"> josevalim:</div>
<blockquote>
<p>Would you advocate for long warnings if every unused variable warning comes with one or two extra pagraphs?</p>
</blockquote>
</aside>
<p>Honestly… Yes by default, it makes it far less ignorable!  <img src="https://forum.elixirforum.com/images/emoji/apple/slight_smile.png?v=15" title=":slight_smile:" class="emoji" alt=":slight_smile:" loading="lazy" width="20" height="20"></p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="91976" data-batch-url="/posts/batch_likers">
                        1
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/proposal-introduce-help-catalogs/15718/25">Post #24</a>
	                </div>
	            </div>
              <div id="likers-container-91976" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="91976"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #24"></div>
  </section>
</div>
    <div class="postbit" id="91977" data-post-id="91977">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="minhajuddin" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/minhajuddin/120/1533_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  minhajuddin
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<blockquote>
<p>Q1</p>
</blockquote>
<p>A help catalog with a more detailed information about the warning would be a great addition.</p>
<blockquote>
<p>Q2</p>
</blockquote>
<p>Making help and warning info accessible via the elixir command would be another great addition.</p>
<blockquote>
<p>Q3</p>
</blockquote>
<p>This would be the natural progression of <em>2</em>, so I vote for this too.</p>
<p>One suggestion I have is to not restrict the help catalog to just warnings. It would be great if we could expose other kinds of useful information which is usually shoved into a <code>README</code> or <code>Getting Started</code> guide via the help catalog. Take distillery for example, it would be great if we could list all the topics in a help catalog for distillery by something like <code>elixir -h 'distillery:*'</code> and then get detailed info on <code>elixir -h distillery:getting_started</code> or <code>elixir -h distillery:phoenix</code>.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="91977" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/proposal-introduce-help-catalogs/15718/26">Post #25</a>
	                </div>
	            </div>
              <div id="likers-container-91977" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="91977"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #25"></div>
  </section>
</div>
    <div class="postbit" id="91983" data-post-id="91983">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="josevalim" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/120/1787_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  josevalim
                    <span class="op-star" title="Thread Starter">
                      <img alt="OP" class="op-star-icon" src="/assets/thread-icons/thread-icon-thread-starter-df91e872.png" />
                    </span>
                  </h3>
		          </div>
						
			          <div class="user-title">
									<span>Creator of Elixir</span>
			          </div>
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote no-group" data-username="minhajuddin" data-post="26" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/minhajuddin/48/1533_2.png" class="avatar"> minhajuddin:</div>
<blockquote>
<p>Take distillery for example, it would be great if we could list all the topics in a help catalog for distillery by something like <code>elixir -h 'distillery:*'</code> and then get detailed info on <code>elixir -h distillery:getting_started</code> or <code>elixir -h distillery:phoenix</code> .</p>
</blockquote>
</aside>
<p>This is a potential source of confusion but I don’t believe the catalog would work as a general pages or guides. I don’t believe the command line is a rich enough environment for such material.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="91983" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/proposal-introduce-help-catalogs/15718/27">Post #26</a>
	                </div>
	            </div>
              <div id="likers-container-91983" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="91983"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #26"></div>
  </section>
</div>
    <div class="postbit" id="91995" data-post-id="91995">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="georgeguimaraes" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/georgeguimaraes/120/19267_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  georgeguimaraes
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote group-livebook_core_team" data-username="josevalim" data-post="19" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/48/1787_2.png" class="avatar"> josevalim:</div>
<blockquote>
<p><strong>what can we do to make sure that a newcomer will understand what</strong> <code>elixir -h elixir:foobar</code> <strong>in a warning/error means</strong> and make sure that they will be able to access the detailed information?</p>
</blockquote>
</aside>
<p>We may use URLs and point them to an online version hosted at <a href="http://elixir-lang.org" rel="nofollow">elixir-lang.org</a>. Sure, this may add some burden when releasing Elixir and making sure there’s a new help catalog online, but nothing beats URLs at being easy to access.</p>
<p>Still not sure with lib’s catalog though. <img src="https://forum.elixirforum.com/images/emoji/apple/thinking.png?v=15" title=":thinking:" class="emoji" alt=":thinking:" loading="lazy" width="20" height="20"></p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="91995" data-batch-url="/posts/batch_likers">
                        1
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/proposal-introduce-help-catalogs/15718/28">Post #27</a>
	                </div>
	            </div>
              <div id="likers-container-91995" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="91995"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #27"></div>
  </section>
</div>
    <div class="postbit" id="91997" data-post-id="91997">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="josevalim" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/120/1787_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  josevalim
                    <span class="op-star" title="Thread Starter">
                      <img alt="OP" class="op-star-icon" src="/assets/thread-icons/thread-icon-thread-starter-df91e872.png" />
                    </span>
                  </h3>
		          </div>
						
			          <div class="user-title">
									<span>Creator of Elixir</span>
			          </div>
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote no-group" data-username="georgeguimaraes" data-post="28" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/georgeguimaraes/48/19267_2.png" class="avatar"> georgeguimaraes:</div>
<blockquote>
<p>We may use URLs and point them to an online version hosted at <a href="http://elixir-lang.org" rel="nofollow">elixir-lang.org</a>. Sure, this may add some burden when releasing Elixir and making sure there’s a new help catalog online, but nothing beats URLs at being easy to access.</p>
</blockquote>
</aside>
<p>I think we should be able to integrate the catalog with ExDoc, which means both Elixir and libraries should have online versions of those. But I’d personally prefer a flow that works on the command line (or from my editor) and does not require a browser. Thoughts?</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="91997" data-batch-url="/posts/batch_likers">
                        4
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/proposal-introduce-help-catalogs/15718/29">Post #28</a>
	                </div>
	            </div>
              <div id="likers-container-91997" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="91997"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #28"></div>
  </section>
</div>
    <div class="postbit" id="92004" data-post-id="92004">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="lackac" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/lackac/120/6584_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  lackac
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote group-livebook_core_team" data-username="josevalim" data-post="20" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/48/1787_2.png" class="avatar"> josevalim:</div>
<blockquote>
<p>I would like the catalog information to be possibly dynamic. For example, Phoenix could look into the user configuration and say “you can change this behaviour by setting X, it is currently set to false”. In Elixir, for example, I would like for <code>elixir:guards</code> to show all guards.</p>
</blockquote>
</aside>
<p>I think this is a good enough reason to go with the functions based approach that you’re proposing.</p>
<aside class="quote group-livebook_core_team" data-username="josevalim" data-post="27" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/48/1787_2.png" class="avatar"> josevalim:</div>
<blockquote>
<p>This is a potential source of confusion but I don’t believe the catalog would work as a general pages or guides. I don’t believe the command line is a rich enough environment for such material.</p>
</blockquote>
</aside>
<p>This got me thinking. Isn’t accessing the catalog with <code>help</code> placing it in the same frame of reference from the perspective of the user as documentation and guides? We’re even calling it help catalog, but the purpose seems to be limited to explaining warnings and errors in more detail. I don’t think it should work as a general pages or guides collection either, but in that case we should probably go with a different name that clearly defines the purpose. I think we should also reconsider <code>--explain</code>.</p>
<p>Regarding naming, I don’t like the sound of “error catalog” or “warning catalog”, so I did a quick thesaurus lookup on “warning” and these jumped out at me: notice, advice, advisory, hint. I like the sound of “advice” or “hint” and think that they communicate the purpose better. <code>elixir --hint elixir:nested_var</code>? I think this also helps newcomers understand what this command means in a warning message.</p>
<p>The only issue I have with the above is that it moves this farther from documentation as the storage and retrieval mechanism. On one hand we can use this information to compile a list of hints (just trying to see how it sounds) in ExDoc. That makes it useful to Elixir core and libraries. We could then solidify the convention, and popularise it in other Erlang VM languages to let them benefit as well. Or we could rely on the docs chunk which is already making its way into those languages. It seems though that the docs chunk approach would prevent dynamic content. Isn’t there a way to have the best of both worlds? I have a half baked solution in mind, but will sleep on it before I write it up.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="92004" data-batch-url="/posts/batch_likers">
                        1
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/proposal-introduce-help-catalogs/15718/30">Post #29</a>
	                </div>
	            </div>
              <div id="likers-container-92004" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="92004"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #29"></div>
  </section>
</div>
    <div class="postbit" id="92013" data-post-id="92013">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="kelvinst" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/kelvinst/120/10173_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  kelvinst
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote group-livebook_core_team" data-username="josevalim" data-post="1" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/48/1787_2.png" class="avatar"> josevalim:</div>
<blockquote>
<p><strong>Question 1:</strong> what do think about the idea of supporting help catalog in general? (regardless of the command structure, syntax, etc)</p>
</blockquote>
</aside>
<p>I’m totally pro having shorter warnings for stuff like <code>unused variable x</code>, but having an easy way for newcomers to get more info about it. But like <a class="mention" href="/u/lackac" rel="nofollow">@lackac</a>, I’m not so sure about the naming after reading all the discussion. So not so sure, if I like the overall idea of a separated feature for it.</p>
<aside class="quote group-livebook_core_team" data-username="josevalim" data-post="1" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/48/1787_2.png" class="avatar"> josevalim:</div>
<blockquote>
<p><strong>Question 2:</strong> what do you think about the suggested syntax for catalogs and its implementation?</p>
</blockquote>
</aside>
<p>Good enough. But:</p>
<ol>
<li>Please export it to the docs either under a centralized page, or in sections inside the modules, or even both.</li>
<li>Using functions to define this is quite strange. I mean, I know it makes it a lot more powerful, since one can use runtime stuff, but I don’t really think we need this, since as you mentioned: contextual information should remain as part of the warning, and if it’s runtime stuff, it’s somehow contextual.</li>
</ol>
<aside class="quote group-livebook_core_team" data-username="josevalim" data-post="1" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/48/1787_2.png" class="avatar"> josevalim:</div>
<blockquote>
<p><strong>Question 3:</strong> should we close the gap and allow help and open generally available in the <code>elixir</code> and <code>mix run</code> commands?</p>
</blockquote>
</aside>
<p>Yes, sure.</p>
<hr>
<p>Now, with my considerations for each question in mind, what about doing something like:</p>
<pre data-code-wrap="elixir"><code class="lang-elixir">defmodule Foo do
  @moduledoc "Foo doc"

  @doc """
  Foo.bar doc

  # Warnings

  ## Put some warning title here

  And its description.

  ## Put another warning title here

  And more description.
  """
  def bar do
    ...
  end 
end
</code></pre>
<p>And of course, <code>elixir -h app:Foo.bar</code> would totally do the job, you should only link to them on the documentation.</p>
<p>If one would like to separate warnings, like you want to do to core, it’s always an option to create a warning function like:</p>
<pre data-code-wrap="elixir"><code class="lang-elixir">defmodule Foo do
  @moduledoc "Foo doc"

  @doc """
  Foo.bar doc. 

  Please notice this function can throw `warning1` and `warning2`.
  """
  def bar do
    ...
  end 

  @doc """
  # Warning title here

  And its description.
  """
  def warning1, do: warn("this")

  @doc """
  # Another warning title here

  And more description.
  """
  def warning2, do: warn("that")
end
</code></pre>
<p>PS.: for warnings thrown by erlang code, you could create a <code>CompilationWarnings</code> module with the functions and docs for each of them and raise an exception if they are called directly.</p>
<p>This would use the stuff we already have, so no complexity added to the core, and it is a very plausible solution for the problem you have IMO. And with this solution in mind, my final answers to the questions would change to:</p>
<ol>
<li><strong>Q</strong>: What do think about the idea of supporting help catalog in general?<br>
<strong>A</strong>: The idea of reducing noise on warning is really good, but we can solve it without a new catalog feature</li>
<li><strong>Q</strong>: What do you think about the suggested syntax for catalogs and its implementation?<br>
<strong>A</strong>: Well, right now IMO we should not implement it at all</li>
<li><strong>Q</strong>: Should we close the gap and allow help and open generally available in the <code>elixir</code> and <code>mix run</code> commands?<br>
<strong>A</strong>: That’s now a really big YES, we should focus all the big efforts on these stuff.</li>
</ol>
<p>So what do you think?</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="92013" data-batch-url="/posts/batch_likers">
                        1
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/proposal-introduce-help-catalogs/15718/31">Post #30</a>
	                </div>
	            </div>
              <div id="likers-container-92013" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="92013"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #30"></div>
  </section>
</div>
    <div class="postbit" id="92017" data-post-id="92017">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="Ryzey" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/Ryzey/120/17302_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  Ryzey
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>Being able to access documentation directly from IEx is useful to me. It allows me to not get stuck on a problem while coding when I have no internet access (and also access from the terminal is just quicker and more convenient IMO). I would not like to see an error message, which I don’t fully understand, and then have to rely on internet access to view the detailed description.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="92017" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/proposal-introduce-help-catalogs/15718/32">Post #31</a>
	                </div>
	            </div>
              <div id="likers-container-92017" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="92017"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #31"></div>
  </section>
</div>
    <div class="postbit" id="92027" data-post-id="92027">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="josevalim" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/120/1787_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  josevalim
                    <span class="op-star" title="Thread Starter">
                      <img alt="OP" class="op-star-icon" src="/assets/thread-icons/thread-icon-thread-starter-df91e872.png" />
                    </span>
                  </h3>
		          </div>
						
			          <div class="user-title">
									<span>Creator of Elixir</span>
			          </div>
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote no-group" data-username="lackac" data-post="30" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/lackac/48/6584_2.png" class="avatar"> lackac:</div>
<blockquote>
<p>This got me thinking. Isn’t accessing the catalog with <code>help</code> placing it in the same frame of reference from the perspective of the user as documentation and guides? We’re even calling it help catalog, but the purpose seems to be limited to explaining warnings and errors in more detail. I don’t think it should work as a general pages or guides collection either, but in that case we should probably go with a different name that clearly defines the purpose. I think we should also reconsider <code>--explain</code> .</p>
</blockquote>
</aside>
<p>We need to balance the confusion of also using <code>help</code> for catalog with the confusion of introducing a third option. Today we already have two commands: <code>help</code> and <code>info</code>. I don’t know the correct answer, but I have a <em>feeling</em> introducing a third command will just be too confusing.</p>
<p>To be very fair, there is nothing stopping someone from adding “distillery:phoenix”. Elixir will have a “elixir:guards” and we do have a page named “Guards”. Implementation wise you could just <code>File.read!(...)</code> the page contents. I just wouldn’t expect packages to necessarily do this because pages just look superior on ExDoc thanks to navigation, accessibility tools, hopefully search, etc.</p>
<aside class="quote no-group" data-username="kelvinst" data-post="31" data-topic="15718">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/kelvinst/48/10173_2.png" class="avatar"> kelvinst:</div>
<blockquote>
<p>And of course, <code>elixir -h app:Foo.bar</code> would totally do the job, you should only link to them on the documentation.</p>
</blockquote>
</aside>
<p>I have mentioned on other replies why I don’t think moving this to the documentation is a good idea, so please check them and follow back. But in a nutshell, there is more dynamic information than just the context of the warning.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="92027" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/proposal-introduce-help-catalogs/15718/33">Post #32</a>
	                </div>
	            </div>
              <div id="likers-container-92027" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="92027"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #32"></div>
  </section>
</div>
    <div class="postbit" id="92037" data-post-id="92037">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="stefanchrobot" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/stefanchrobot/120/7657_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  stefanchrobot
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>“Yes” to all the questions.</p>
<p>I really like how <a href="https://github.com/rrrene/credo#basic-usage" rel="noopener nofollow ugc">Credo</a> does this: shows you one-liners with an option to print a very detailed information about each one. My only gripe is that one needs to copy-paste the whole location (filename + line number) into the command line to get the details. It would be better to just number the warning so that it’s easier to type in the command that prints the explanation for a specific occurrence. I’d also rather have the hint about <code>--explain</code> appear only once. Summing up, something along the lines of:</p>
<pre data-code-wrap="elixir"><code class="lang-elixir">Compiling 1 file (.ex)
warning #1: variable "thing" is unused
  lib/file.ex:8

warning #2: function MyModule.next/1 is undefined or private. Did you mean one of:

      * next/2

  lib/other.ex:98

Compilation finished with warnings. Use "mix explain" to get a detailed explanation or "mix explain #2" to explain a specific warning.
</code></pre>
<p>As for the short/medium/long thing, I would like something like the following rule: by default print the “what”, “where” and contextual hints for fixing; put the “why” and general hints/explanation in the catalog. In the example above, I’d rather have the notice about prefixing the variable with <code>_</code> in the catalog since an unused variable might be because of a typo or incomplete refactoring. On the other hand, I’d like to keep the suggestions for the second error since this is useful for fixing the problem.</p>
<aside class="quote group-livebook_core_team" data-username="josevalim" data-post="1" data-topic="15718" data-full="true">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/josevalim/48/1787_2.png" class="avatar"> josevalim:</div>
<blockquote>
<p>One reason to say yes is completeness. However, I personally open IEx multiple times only to retrieve the documentation or to open a module, so I would definitely use this feature too.</p>
</blockquote>
</aside>
<p>I find myself doing the same. My only concern is: how/will this work for deps? It would make sense to put it in the context of Mix, so something like <code>mix explain app:entry</code>.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="92037" data-batch-url="/posts/batch_likers">
                        0
                      </span>
                      <!-- <span class="thread-count js-solved-indicator" title="Marked as solution"></span> -->
	                </div>
	                <div class="go-to-post">
	                  <a title="Go to post" alt="Go to post" href="https://forum.elixirforum.com/t/proposal-introduce-help-catalogs/15718/34">Post #33</a>
	                </div>
	            </div>
              <div id="likers-container-92037" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="92037"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-standard-post cat-standard-post" title="Post #33"></div>
  </section>
</div>
</template></turbo-stream><turbo-stream action="replace" target="load-more-container"><template><div id="load-more-container" class="load-more-container">
    <a class="load-more-button" data-turbo-stream="true" href="/topics/15718/load_more?page=4">Load more posts (17 remaining)</a>
</div></template></turbo-stream>