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


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="kip" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/kip/120/1440_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  kip
                  </h3>
		          </div>
						
			          <div class="user-title">
									<span>ex_cldr Core Team</span>
			          </div>
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>Really appreciate all the suggestions. Really.  <code>locale_error/1</code> I’m pretty sure isn’t the issue.  It’s just:</p>
<pre data-code-wrap="elixir"><code class="lang-elixir">  @spec locale_error(locale_name() | LanguageTag.t()) :: {Cldr.UnknownLocaleError, String.t()}
  def locale_error(%LanguageTag{requested_locale_name: requested_locale_name}) do
    locale_error(requested_locale_name)
  end

  def locale_error(locale_name) do
    {Cldr.UnknownLocaleError, "The locale #{inspect(locale_name)} is not known."}
  end
</code></pre>
<p>And I think thats the end of the rabbit hole.  I’m out of ideas.  But I’ll try to create a minimal failing case and see what that tells me.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="119786" data-batch-url="/posts/batch_likers">
                        2
                      </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/help-with-dialyzer-output-function-exunit-assertions-flunk-1-does-not-exist/15202/22">Post #21</a>
	                </div>
	            </div>
              <div id="likers-container-119786" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="119786"
                     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 #21"></div>
  </section>
</div>
    <div class="postbit" id="169836" data-post-id="169836">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="kip" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/kip/120/1440_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  kip
                  </h3>
		          </div>
						
			          <div class="user-title">
									<span>ex_cldr Core Team</span>
			          </div>
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>Kind of fun to re-read this old thread - especially since somewhere in the last year I solved the issue (and I don’t really know when). I thought my dialyzer-fu was quite reasonable now but then this issue cropped up today (after a couple of weeks work so I can’t trace when it appeared).</p>
<p>Help very much appreciated!</p>
<h3><a name="p-169836-dialyzer-error-1" class="anchor" href="#p-169836-dialyzer-error-1" aria-label="Heading link" rel="nofollow"></a>Dialyzer Error:</h3>
<pre data-code-wrap="elixir"><code class="lang-elixir">lib/cldr/backend/cldr.ex:52:call
The function call will not succeed.

Cldr.Locale.put_gettext_locale_name(
  %Cldr.LanguageTag{
    :canonical_locale_name =&gt; &lt;&lt;101, 110, 45, 76, 97, 116, 110, 45, 85, 83&gt;&gt;,
    :cldr_locale_name =&gt; &lt;&lt;101, 110&gt;&gt;,
    :extensions =&gt; %{},
    :gettext_locale_name =&gt; nil,
    :language =&gt; &lt;&lt;101, 110&gt;&gt;,
    :language_subtags =&gt; [],
    :language_variant =&gt; nil,
    :locale =&gt; %{},
    :private_use =&gt; [],
    :rbnf_locale_name =&gt; &lt;&lt;101, 110&gt;&gt;,
    :requested_locale_name =&gt; &lt;&lt;101, 110&gt;&gt;,
    :script =&gt; &lt;&lt;76, 97, 116, 110&gt;&gt;,
    :territory =&gt; :US,
    :transform =&gt; %{}
  },
  MyApp.Cldr
)

will never return since it differs in arguments with
positions 1st from the success typing arguments:

(
  %Cldr.LanguageTag{
    :canonical_locale_name =&gt; binary(),
    :cldr_locale_name =&gt; nil | binary(),
    :extensions =&gt; map(),
    :gettext_locale_name =&gt; nil | binary(),
    :language =&gt; binary(),
    :language_subtags =&gt; [binary()],
    :language_variant =&gt; nil | binary(),
    :locale =&gt; map(),
    :private_use =&gt; [binary()],
    :rbnf_locale_name =&gt; nil | binary(),
    :requested_locale_name =&gt; binary(),
    :script =&gt; nil | binary(),
    :territory =&gt; nil,
    :transform =&gt; map()
  },
  atom()
)
</code></pre>
<h3><a name="p-169836-observations-2" class="anchor" href="#p-169836-observations-2" aria-label="Heading link" rel="nofollow"></a>Observations</h3>
<p>The only difference between the <a href="https://github.com/elixir-cldr/cldr/blob/master/lib/cldr/backend/cldr.ex#L46-L53" rel="nofollow">function call</a> and the success typing is:</p>
<pre data-code-wrap="elixir"><code class="lang-elixir"># Call
    :script =&gt; &lt;&lt;76, 97, 116, 110&gt;&gt;,
    :territory =&gt; :US,
    :transform =&gt; %{}

# Success type
    :script =&gt; nil | binary(),
    :territory =&gt; nil,
    :transform =&gt; map()
</code></pre>
<p>In which the types for <code>:territory</code> would seem to mismatch.  However if I look into my <a href="https://github.com/elixir-cldr/cldr/blob/master/lib/cldr/language_tag.ex#L174-L189" rel="nofollow">types</a>:</p>
<pre data-code-wrap="elixir"><code class="lang-elixir">  # This is the type for Cldr.LanguageTag
  @type territory :: atom()
  @type t :: %__MODULE__{
          language: String.t(),
          language_subtags: [String.t()] | [],
          script: String.t() | nil,
          territory: Cldr.territory(),
          language_variant: String.t() | nil,
          locale: Cldr.LanguageTag.U.t(),
          transform: map(),
          extensions: map(),
          private_use: [String.t()] | [],
          requested_locale_name: String.t(),
          canonical_locale_name: String.t(),
          cldr_locale_name: String.t() | nil,
          rbnf_locale_name: String.t() | nil,
          gettext_locale_name: String.t() | nil
        }
</code></pre>
<p>So I’m perplexed why the success type for <code>:territory</code> is <code>nil</code> not <code>atom()</code>.  The <a href="https://github.com/elixir-cldr/cldr/blob/master/lib/cldr/locale.ex#L475-L479" rel="nofollow">called site</a> is:</p>
<pre data-code-wrap="elixir"><code class="lang-elixir">  @spec put_gettext_locale_name(Cldr.LanguageTag.t(), Cldr.backend()) :: Cldr.LanguageTag.t()
  def put_gettext_locale_name(%LanguageTag{} = language_tag, backend) do
    gettext_locale_name = gettext_locale_name(language_tag, backend)
    %{language_tag | gettext_locale_name: gettext_locale_name}
  end
</code></pre>
<p>Which doesn’t obviously disturb the success type I would have thought?</p>
<p>Any and all suggestions welcome!</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="169836" 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/help-with-dialyzer-output-function-exunit-assertions-flunk-1-does-not-exist/15202/23">Post #22</a>
	                </div>
	            </div>
              <div id="likers-container-169836" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="169836"
                     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 #22"></div>
  </section>
</div>
    <div class="postbit" id="169851" data-post-id="169851">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="michallepicki" src="/assets/icons/user-9f439610.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  michallepicki
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>you have functions in the called site file where territory is fetched from the struct and passed to other functions where <code>territory()</code> type from this file is referenced, which is a <code>String.t() | nil</code>. The only <code>atom()</code> for which this makes sense is <code>nil</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="169851" 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/help-with-dialyzer-output-function-exunit-assertions-flunk-1-does-not-exist/15202/24">Post #23</a>
	                </div>
	            </div>
              <div id="likers-container-169851" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="169851"
                     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 #23"></div>
  </section>
</div>
    <div class="postbit" id="169853" data-post-id="169853">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="michallepicki" src="/assets/icons/user-9f439610.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  michallepicki
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<aside class="quote no-group quote-modified" data-username="kip" data-post="23" data-topic="15202">
<div class="title">
<div class="quote-controls"></div>
<img alt="" width="24" height="24" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/kip/48/1440_2.png" class="avatar"> kip:</div>
<blockquote>
<p>private_use: [String.t()] | <span class="chcklst-box fa fa-square-o"></span>,</p>
</blockquote>
</aside>
<p>BTW this can be simply <code>private_use: [String.t()],</code> and the same for <code>language_subtags</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="169853" 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/help-with-dialyzer-output-function-exunit-assertions-flunk-1-does-not-exist/15202/25">Post #24</a>
	                </div>
	            </div>
              <div id="likers-container-169853" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="169853"
                     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="169854" data-post-id="169854">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="kip" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/kip/120/1440_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  kip
                  </h3>
		          </div>
						
			          <div class="user-title">
									<span>ex_cldr Core Team</span>
			          </div>
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>Thanks very much, greatly appreciated!  I’ll go diving some more. I had already adjusted the <code>:private_use</code> and <code>:language_subtags</code> types.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="169854" 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/help-with-dialyzer-output-function-exunit-assertions-flunk-1-does-not-exist/15202/26">Post #25</a>
	                </div>
	            </div>
              <div id="likers-container-169854" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="169854"
                     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="189847" data-post-id="189847">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="detiolso" src="/assets/icons/user-9f439610.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  detiolso
                  </h3>
		          </div>
						
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>Yea I am running this on CI which is using the MIX_ENV=test, is it preferable to be running this on a different environment?</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="189847" 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/help-with-dialyzer-output-function-exunit-assertions-flunk-1-does-not-exist/15202/27">Post #26</a>
	                </div>
	            </div>
              <div id="likers-container-189847" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="189847"
                     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="189881" data-post-id="189881">
  <section>
    <div class="post-wrap">


					<div class="post-header">
		        <div class="user-avatar">
		          <img alt="kip" src="https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/kip/120/1440_2.png" width="120" height="120" />
		        </div>
					
						<div class="user-details">
		          <div class="user-name">
		            <h3>
                  kip
                  </h3>
		          </div>
						
			          <div class="user-title">
									<span>ex_cldr Core Team</span>
			          </div>
						</div>
					
					</div>

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>Um, running what?  And with what error?  Tricky to help without this information.  Typically shouldn’t matter what environment you are running dialyzer in.</p> 
	            </div>

	            <div class="base-line">
	                <div class="thread-counters">
	                    <span class="thread-count count-likes js-likers-trigger" title="Likes" data-post-id="189881" 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/help-with-dialyzer-output-function-exunit-assertions-flunk-1-does-not-exist/15202/28">Post #27</a>
	                </div>
	            </div>
              <div id="likers-container-189881" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="189881"
                     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="317984" data-post-id="317984">
  <section>
    <div class="post-wrap">


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

	        <div class="thread-main">
	            <div class="post-body" data-turbo="false">
								<p>Hey just found this thread very helpful still today, solved the exactly same problem I was having. For future people coming here just keep in mind setting the MIX_ENV to <code>dev</code> will cause the hole project to be compiled again, which maybe is not desired.</p>
<p>To me including <code>:ex_unit</code> in <code>plt_add_apps</code> seems better if the project is only/already compiled with MIX_ENV set to <code>test</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="317984" 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/help-with-dialyzer-output-function-exunit-assertions-flunk-1-does-not-exist/15202/29">Post #28</a>
	                </div>
	            </div>
              <div id="likers-container-317984" 
                   class="likers-container"
                   data-first-post="false"
                   data-batch-url="/posts/batch_likers">
                   <div class="likers-placeholder" 
                     data-likers-post-id="317984"
                     data-batch-url="/posts/batch_likers">
                  <div class="post-likers"></div>
                </div>
              </div>
	        </div>
			

    </div>

    <div class="triangle-top-right type-last-post cat-last-post" title="Last post!"></div>
  </section>
</div>
</template></turbo-stream><turbo-stream action="replace" target="load-more-container"><template><div id="load-more-container" class="load-more-container">
    <span class="all-loaded">— All posts loaded —</span>
</div></template></turbo-stream>