text1
stringlengths
0
536k
text2
stringlengths
0
536k
label
int64
0
1
<h3 dir="auto">Vue.js version</h3> <p dir="auto">1.0.27</p> <h3 dir="auto">Reproduction Link</h3> <p dir="auto"><a href="https://jsfiddle.net/gckb9mkv/1/" rel="nofollow">https://jsfiddle.net/gckb9mkv/1/</a></p> <h3 dir="auto">Steps to reproduce</h3> <p dir="auto">Open the fiddle and check the console output</p> <h3 dir="auto">What is Expected?</h3> <p dir="auto">Same code but with 1.0.26 dependencies.<br> <a href="https://jsfiddle.net/qjvz0p1x/" rel="nofollow">https://jsfiddle.net/qjvz0p1x/</a></p> <p dir="auto">// p1:Array[2]<br> // p2:Array[0]<br> // p3:"toto"</p> <h3 dir="auto">What is actually happening?</h3> <p dir="auto">// p1:"a,b"<br> // p2:true<br> // p3:"toto"</p>
<h3 dir="auto">Vue.js version</h3> <p dir="auto">1.0.27</p> <h3 dir="auto">Description</h3> <p dir="auto">Parameter data type is illegal to chang</p> <h3 dir="auto">Reproduction Link</h3> <p dir="auto"><a href="https://jsfiddle.net/jawc4bpo/" rel="nofollow">jsfiddle</a></p> <h3 dir="auto">What is Expected?</h3> <p dir="auto">Here is same <a href="https://jsfiddle.net/gn4aezn2/" rel="nofollow">example</a> with version 1.0.26 where it works</p>
1
<p dir="auto">Similar to Fancy Zones be able to define locations for Windows to be positioned in response to specific scenarios - in this can switching between single and dual (or more) monitor configurations - either docking/undocking a laptop, or connecting to a remote desktop session with "use all monitors" or a single screen.</p> <p dir="auto">A specific use-case:<br> I usually work with my Windows VM via a remote desktop scenario where I have two screens. My 'host' in my Macbook with an external monitor, and Windows via Remote Desktop supports that very well, allowing me to use both screens and arrange windows where I want/need them... but, if I'm away from that desktop and connect via my iPad or my laptop without it's external screen then all the remote desktop windows get 'gathered' back into the single screen (desired behavior), but when I log back in via the dual screen configuration I have to waste time moving windows back to my preferred layout.</p> <p dir="auto">Would love to be able to set up rules so that (eg) when moving to a single screen Windows behaves as normal, but when a second screen is available automatically move (VSCode, Chrome, Powerpoint) to the second screen (ideally it would remember the positions they were in before they had been 'gathered' across to the single monitor and so revert to actual positions and sizes rather than just retain relative sizing/position to where they had been in the gathered scenario</p>
<h2 dir="auto"><g-emoji class="g-emoji" alias="information_source" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/2139.png">ℹ</g-emoji> Computer information</h2> <ul dir="auto"> <li>PowerToys version: 0.21.1</li> <li>PowerToy Utility: Run</li> <li>Running PowerToys as Admin: Yes</li> <li>Windows build number: 18363.1082 || 1909</li> </ul> <h2 dir="auto"><g-emoji class="g-emoji" alias="memo" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/1f4dd.png">📝</g-emoji> Provide detailed reproduction steps (if any)</h2> <ol dir="auto"> <li>Run PowerToys</li> <li>Run "PowerToys Run"</li> <li>Try to find any application || .exe</li> </ol> <h3 dir="auto">✔️ Expected result</h3> <p dir="auto">My favorite executable I was looking for :)</p> <h3 dir="auto"><g-emoji class="g-emoji" alias="x" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/274c.png">❌</g-emoji> Actual result</h3> <p dir="auto">I can't find no one application || .exe . In an earlier version i easy find any application || .exe</p> <h2 dir="auto">📷 Screenshots</h2> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/44039577/93025129-16244800-f604-11ea-8cf0-8920274b3c7f.png"><img src="https://user-images.githubusercontent.com/44039577/93025129-16244800-f604-11ea-8cf0-8920274b3c7f.png" alt="Screeeeen" style="max-width: 100%;"></a></p>
0
<p dir="auto">Please:</p> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> The environment is ubuntu 20.04 &amp; Jetpack v5.0.1 - build follows Jetson Zoo website</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> I have tried to both compile jax without success. pip3 install jax[cuda] works. However if I run pip3 install jaxlib I get an error code Error: No matching distribution found for jaxlib</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> when I have tried to compile, the .cache for bazel uses all my free disk space.</li> </ul> <p dir="auto">Thanks in advance for your assistance,</p> <p dir="auto">Paul</p>
<p dir="auto">Potentially related to <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="916640295" data-permission-text="Title is private" data-url="https://github.com/google/jax/issues/6932" data-hovercard-type="issue" data-hovercard-url="/google/jax/issues/6932/hovercard" href="https://github.com/google/jax/issues/6932">#6932</a> or <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="927516918" data-permission-text="Title is private" data-url="https://github.com/google/jax/issues/7052" data-hovercard-type="issue" data-hovercard-url="/google/jax/issues/7052/hovercard" href="https://github.com/google/jax/issues/7052">#7052</a>.</p> <p dir="auto">I am using a heterogeneous cluster with various different compute options. I got Jax and Flax installed fine on the CPU system. Then I tried using a GPU node (specifically dual socket Cavium ThunderX2 99xx 32-core processors with two NVIDIA Tesla V100 GPUs), but am unable to install jaxlib:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ pip install --upgrade jax jaxlib==0.1.68+cuda111 -f https://storage.googleapis.com/jax-releases/jax_releases.html Looking in links: https://storage.googleapis.com/jax-releases/jax_releases.html Requirement already satisfied: jax in /home/southworth/.conda/envs/jax_arch/lib/python3.7/site-packages (0.2.16) ERROR: Could not find a version that satisfies the requirement jaxlib==0.1.68+cuda111 (from versions: none) ERROR: No matching distribution found for jaxlib==0.1.68+cuda111"><pre class="notranslate"><code class="notranslate">$ pip install --upgrade jax jaxlib==0.1.68+cuda111 -f https://storage.googleapis.com/jax-releases/jax_releases.html Looking in links: https://storage.googleapis.com/jax-releases/jax_releases.html Requirement already satisfied: jax in /home/southworth/.conda/envs/jax_arch/lib/python3.7/site-packages (0.2.16) ERROR: Could not find a version that satisfies the requirement jaxlib==0.1.68+cuda111 (from versions: none) ERROR: No matching distribution found for jaxlib==0.1.68+cuda111 </code></pre></div> <p dir="auto">or even</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="pip install jaxlib ERROR: Could not find a version that satisfies the requirement jaxlib (from versions: none) ERROR: No matching distribution found for jaxlib"><pre class="notranslate"><code class="notranslate">pip install jaxlib ERROR: Could not find a version that satisfies the requirement jaxlib (from versions: none) ERROR: No matching distribution found for jaxlib </code></pre></div> <p dir="auto">Below is my pip version, which is up to date. Pip also installs other libraries fine (numpy, scipy, etc.)</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ pip --version pip 21.1.2 from /home/southworth/.conda/envs/jax_arch/lib/python3.7/site-packages/pip (python 3.7)"><pre class="notranslate"><code class="notranslate">$ pip --version pip 21.1.2 from /home/southworth/.conda/envs/jax_arch/lib/python3.7/site-packages/pip (python 3.7) </code></pre></div>
1
<p dir="auto">Challenge <a href="http://www.freecodecamp.com/challenges/waypoint-comment-your-javascript-code" rel="nofollow">http://www.freecodecamp.com/challenges/waypoint-comment-your-javascript-code</a> has an issue. Please describe how to reproduce it, and include links to screenshots if possible.</p> <p dir="auto">When running the test on a multiple line comment such as:</p> <p dir="auto">/*<br> comment<br> */</p> <p dir="auto">the code does not pass. /* comments <em>/ are usually used when you want to span a comment across multiple lines, this would be a great area to talk about the difference between the two. To fix the bug you could add your regex expression to check continuous lines for the /</em> */ comment</p>
<p dir="auto">Challenge <a href="http://www.freecodecamp.com/challenges/waypoint-comment-your-javascript-code" rel="nofollow">http://www.freecodecamp.com/challenges/waypoint-comment-your-javascript-code</a> has an issue. Please describe how to reproduce it, and include links to screenshots if possible.</p> <p dir="auto">Left side error checking seems wrong</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/6602253/9322092/8ff4273c-4523-11e5-8b61-72997748f789.png"><img src="https://cloud.githubusercontent.com/assets/6602253/9322092/8ff4273c-4523-11e5-8b61-72997748f789.png" alt="comment your javascript code" style="max-width: 100%;"></a></p>
1
<p dir="auto">iOS has support for changing what the return/done key on the keybaord should be labeled with...</p>
<h2 dir="auto">Steps to Reproduce</h2> <p dir="auto">After upgrading flutter to the latest version I get a lot of erroneous warnings and errors when running <code class="notranslate">flutter analyze</code>. Many of the warnings are reported multiple times (the warnings seem valid though). But most disturbingly I get errors at the very start of some files:</p> <p dir="auto"><code class="notranslate">error • Invalid constant value at lib/page_error.dart:1:1 • invalid_constant</code></p> <p dir="auto">All files has the same encoding (according to IntelliJ), and I've checked with a binary viewer <code class="notranslate">xxd</code> and there seem to be no weird invisible characters at the beginning of the affected files.</p> <p dir="auto">First lines of output from xxd:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="00000000: 696d 706f 7274 2027 6461 7274 3a69 6f27 import 'dart:io' 00000010: 3b0a 696d 706f 7274 2027 6461 7274 3a6d ;.import 'dart:m 00000020: 6174 6827 3b0a 0a69 6d70 6f72 7420 2770 ath';..import 'p 00000030: 6163 6b61 6765 3a66 6c75 7474 6572 2f6d ackage:flutter/m"><pre class="notranslate"><code class="notranslate">00000000: 696d 706f 7274 2027 6461 7274 3a69 6f27 import 'dart:io' 00000010: 3b0a 696d 706f 7274 2027 6461 7274 3a6d ;.import 'dart:m 00000020: 6174 6827 3b0a 0a69 6d70 6f72 7420 2770 ath';..import 'p 00000030: 6163 6b61 6765 3a66 6c75 7474 6572 2f6d ackage:flutter/m </code></pre></div> <h2 dir="auto">Logs</h2> <p dir="auto">Complete output from flutter analyze:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Viktors-MacBook-Pro:Newsvoice vik$ flutter analyze Analyzing /Users/vik/Projects/NewsVoice/NewsvoiceApp/Newsvoice... hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/page_error.dart:1:1 • invalid_constant error • Invalid constant value at lib/page_onboarding.dart:1:1 • invalid_constant error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/page_category.dart:1:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/page_error.dart:1:1 • invalid_constant error • Invalid constant value at lib/page_onboarding.dart:1:1 • invalid_constant error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/page_category.dart:1:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/page_category.dart:1:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/page_error.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/page_category.dart:1:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/page_onboarding.dart:1:1 • invalid_constant error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import 54 errors and 109 hints found. (Ran in 5.9s)"><pre class="notranslate"><code class="notranslate">Viktors-MacBook-Pro:Newsvoice vik$ flutter analyze Analyzing /Users/vik/Projects/NewsVoice/NewsvoiceApp/Newsvoice... hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/page_error.dart:1:1 • invalid_constant error • Invalid constant value at lib/page_onboarding.dart:1:1 • invalid_constant error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/page_category.dart:1:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/page_error.dart:1:1 • invalid_constant error • Invalid constant value at lib/page_onboarding.dart:1:1 • invalid_constant error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/page_category.dart:1:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/page_category.dart:1:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/page_error.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/page_category.dart:1:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/page_onboarding.dart:1:1 • invalid_constant error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widget_newsmix.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_material.dart:1:1 • invalid_constant error • Arguments of a constant creation must be constant expressions at lib/widgets_material.dart:1:1 • const_with_non_constant_argument error • Invalid constant value at lib/widgets_news.dart:1:1 • invalid_constant error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import hint • Unused import at lib/widgets_comments.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import error • Invalid constant value at lib/widgets_scaffold.dart:1:1 • invalid_constant hint • Unused import at lib/aspectorama_api.dart:4:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:5:8 • unused_import hint • Unused import at lib/aspectorama_api.dart:13:8 • unused_import hint • Unused import at lib/service_universal_links.dart:1:8 • unused_import 54 errors and 109 hints found. (Ran in 5.9s) </code></pre></div> <h2 dir="auto">Flutter Doctor</h2> <p dir="auto">[✓] Flutter (on Mac OS X 10.12.3 16D32, channel master)<br> • Flutter at /Users/vik/Projects/flutter<br> • Framework revision <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/flutter/flutter/commit/b52d659406104a53ecbcdd64d41ec89971a9e967/hovercard" href="https://github.com/flutter/flutter/commit/b52d659406104a53ecbcdd64d41ec89971a9e967"><tt>b52d659</tt></a> (14 hours ago), 2017-04-17 15:44:41 -0700<br> • Engine revision <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/flutter/flutter/commit/c24a0e51750570f271f860bbffbe082aab4ea72f/hovercard" href="https://github.com/flutter/flutter/commit/c24a0e51750570f271f860bbffbe082aab4ea72f"><tt>c24a0e5</tt></a><br> • Tools Dart version 1.23.0-dev.11.7</p> <p dir="auto">[✓] Host Executable Compatibility<br> • Downloaded executables execute on host</p> <p dir="auto">[✓] Android toolchain - develop for Android devices (Android SDK 25.0.2)<br> • Android SDK at /Users/vik/Library/Android/sdk<br> • Platform android-25, build-tools 25.0.2<br> • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java<br> • Java version: OpenJDK Runtime Environment (build 1.8.0_112-release-b06)</p> <p dir="auto">[✓] iOS toolchain - develop for iOS devices (Xcode 8.3)<br> • Xcode at /Applications/Xcode.app/Contents/Developer<br> • Xcode 8.3, Build version 8E162<br> • ios-deploy 1.9.1<br> • CocoaPods version 1.2.0</p> <p dir="auto">[✓] Android Studio (version 2.3)<br> • Android Studio at /Applications/Android Studio.app/Contents<br> • Gradle version 3.2<br> • Java version: OpenJDK Runtime Environment (build 1.8.0_112-release-b06)</p> <p dir="auto">[✓] IntelliJ IDEA Community Edition (version 2016.3.4)<br> • Dart plugin version 163.13137<br> • Flutter plugin version 0.1.11.1</p> <p dir="auto">[✓] Connected devices<br> • Nexus 5X • 01023965355db590 • android-arm • Android 6.0 (API 23)</p>
0
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/mui-org/material-ui/issues">issues</a> of this repository and believe that this is not a duplicate.</li> </ul> <h2 dir="auto">Expected Behavior</h2> <p dir="auto">When calling Dialog component with fullWidth=true and no other props I would expect the Dialog to take up the full width of the screen</p> <h2 dir="auto">Current Behavior</h2> <p dir="auto">What's happening is because the of the defaultProps value for maxWidth is 'sm' the true width ends up being capped at 600px like so:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/19170080/34534440-204d3588-f08c-11e7-9f1d-d0b09c9a15a1.png"><img src="https://user-images.githubusercontent.com/19170080/34534440-204d3588-f08c-11e7-9f1d-d0b09c9a15a1.png" alt="screen shot 2018-01-03 at 1 43 39 pm" style="max-width: 100%;"></a></p> <p dir="auto">I only noticed the issue when I accidentally put 'lg' a value which is not supported and noticed that it worked like I wanted it to</p> <h2 dir="auto">Steps to Reproduce (for bugs)</h2> <ol dir="auto"> <li>Open Dialog component with props fullScreen=true</li> </ol> <h2 dir="auto">Context</h2> <p dir="auto">I would like to submit a PR if approved to check if there is fullScreen applied and no maxWidth prop provided to ignore the defaultProps of 'sm'</p> <h2 dir="auto">Your Environment</h2> <table role="table"> <thead> <tr> <th>Tech</th> <th>Version</th> </tr> </thead> <tbody> <tr> <td>Material-UI</td> <td>1.0.0-beta.26</td> </tr> <tr> <td>React</td> <td>16</td> </tr> <tr> <td>browser</td> <td>Chrome 63</td> </tr> <tr> <td>etc</td> <td></td> </tr> </tbody> </table>
<p dir="auto">I am trying the following:</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="const decorate = withStyles(({ palette }) =&gt; ({ root: { } })); class MyComponent extends React.Component&lt;WithStyles&lt;'root'&gt;&gt; { // What should be the type of the props? constructor(props: WithStyles&lt;'root'&gt;) { super(props); // ... do things } render() { const cl = this.props.classes!; return &lt;div className={cl.root}&gt;hi&lt;/div&gt;; } } export default decorate&lt;{}&gt;(MyComponent); "><pre class="notranslate"><span class="pl-k">const</span> <span class="pl-s1">decorate</span> <span class="pl-c1">=</span> <span class="pl-en">withStyles</span><span class="pl-kos">(</span><span class="pl-kos">(</span><span class="pl-kos">{</span> palette <span class="pl-kos">}</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">root</span>: <span class="pl-kos">{</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">class</span> <span class="pl-smi">MyComponent</span> <span class="pl-k">extends</span> <span class="pl-smi">React</span><span class="pl-kos">.</span><span class="pl-c1">Component</span><span class="pl-kos">&lt;</span><span class="pl-smi">WithStyles</span><span class="pl-kos">&lt;</span><span class="pl-s">'root'</span><span class="pl-kos">&gt;</span><span class="pl-kos">&gt;</span> <span class="pl-kos">{</span> <span class="pl-c">// What should be the type of the props?</span> <span class="pl-en">constructor</span><span class="pl-kos">(</span><span class="pl-s1">props</span>: <span class="pl-smi">WithStyles</span><span class="pl-kos">&lt;</span><span class="pl-s">'root'</span><span class="pl-kos">&gt;</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-smi">super</span><span class="pl-kos">(</span><span class="pl-s1">props</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-c">// ... do things</span> <span class="pl-kos">}</span> <span class="pl-en">render</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">const</span> <span class="pl-s1">cl</span> <span class="pl-c1">=</span> <span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">props</span><span class="pl-kos">.</span><span class="pl-c1">classes</span><span class="pl-c1">!</span><span class="pl-kos">;</span> <span class="pl-k">return</span> <span class="pl-c1">&lt;</span><span class="pl-s1">div</span> <span class="pl-smi">className</span><span class="pl-c1">=</span><span class="pl-kos">{</span><span class="pl-c1">cl</span><span class="pl-kos">.</span><span class="pl-c1">root</span><span class="pl-kos">}</span><span class="pl-c1">&gt;</span><span class="pl-s1">hi</span><span class="pl-c1">&lt;</span><span class="pl-c1">/</span>div&gt;; <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-k">export</span> <span class="pl-k">default</span> <span class="pl-en">decorate</span><span class="pl-kos">&lt;</span><span class="pl-kos">{</span><span class="pl-kos">}</span><span class="pl-kos">&gt;</span><span class="pl-kos">(</span><span class="pl-smi">MyComponent</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <p dir="auto">However struggling to work out the right constructor props type</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Error:(67, 29) TS2345:Argument of type 'typeof MyClass' is not assignable to parameter of type 'ComponentType&lt;WithStyles&lt;&quot;root&quot;&gt;&gt;'. Type 'typeof MyClass' is not assignable to type 'StatelessComponent&lt;WithStyles&lt;&quot;root&quot;&gt;&gt;'. Type 'typeof MyClass' provides no match for the signature '(props: WithStyles&lt;&quot;root&quot;&gt; &amp; { children?: ReactNode; }, context?: any): ReactElement&lt;any&gt; | null'."><pre class="notranslate"><code class="notranslate">Error:(67, 29) TS2345:Argument of type 'typeof MyClass' is not assignable to parameter of type 'ComponentType&lt;WithStyles&lt;"root"&gt;&gt;'. Type 'typeof MyClass' is not assignable to type 'StatelessComponent&lt;WithStyles&lt;"root"&gt;&gt;'. Type 'typeof MyClass' provides no match for the signature '(props: WithStyles&lt;"root"&gt; &amp; { children?: ReactNode; }, context?: any): ReactElement&lt;any&gt; | null'. </code></pre></div> <p dir="auto">The Typescript Guide in the docs doesn't provide an example to show how to type a constructor</p> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/callemall/material-ui/issues">issues</a> of this repository and believe that this is not a duplicate.</li> </ul> <h2 dir="auto">Your Environment</h2> <table role="table"> <thead> <tr> <th>Tech</th> <th>Version</th> </tr> </thead> <tbody> <tr> <td>Material-UI</td> <td>1.0.0-beta.17</td> </tr> <tr> <td>React</td> <td>16.0.0 (using <code class="notranslate">@types/react</code> 16.0.18</td> </tr> </tbody> </table>
0
<blockquote> <p dir="auto">Warning: setState(...): Can only update a mounted or mounting component. This usually means you called setState() on an unmounted component. This is a no-op.</p> </blockquote> <p dir="auto">It would be great to get a stack trace here so I know what this warning is referring to</p>
<p dir="auto">Seeing something like:</p> <blockquote> <p dir="auto">Warning: Any use of a keyed object should be wrapped in React.addons.createFragment(object) before being passed as a child.</p> </blockquote> <p dir="auto">Is really useful but... not so much if you don't know where the offending code is. A trace call would <em>really</em> help narrow down where in an application the problematic code is.</p> <p dir="auto">This would also obliviate the need for the (pointless) try/catch below that needs to be edited to even work (it catches the error it throws).</p>
1
<p dir="auto">As was noted in <a href="https://github.com/rust-lang/rfcs/pull/141#issuecomment-47253786" data-hovercard-type="pull_request" data-hovercard-url="/rust-lang/rfcs/pull/141/hovercard">the RFC discussion</a>, covariant lifetime positions (which I was mistakenly referring to as "contravariant") should require explicit lifetime annotations.</p> <p dir="auto">cc <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="37476072" data-permission-text="Title is private" data-url="https://github.com/rust-lang/rust/issues/15552" data-hovercard-type="issue" data-hovercard-url="/rust-lang/rust/issues/15552/hovercard" href="https://github.com/rust-lang/rust/issues/15552">#15552</a></p>
<p dir="auto">Three related FIXMEs in <code class="notranslate">back::link</code> suggest adding back-end optimization levels other than <code class="notranslate">-O2</code>, exposing and using lists of specific LLVM optimizations, or at least not duplicating the LLVM optimizer's list of <code class="notranslate">-O2</code> optimizations.</p>
0
<h2 dir="auto">Bug Report</h2> <p dir="auto"><strong>Current Behavior</strong><br> <code class="notranslate">Duplicate declaration "x"</code> is thrown for the below code, this does not happen when natively run by e.g. Chrome. See <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/kzc/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/kzc">@kzc</a>'s comments below for clarification of the ECMA specification where it's also shown that the Bable behavior is incorrect.</p> <p dir="auto">This does not matter in itself, it doesn't make sense to write this code. However, e.g. Terser correctly treats them as different scopes and reuses variable names as below if it sees that the for-variable is not used (this mostly happens when using <code class="notranslate">.entries()</code> and you at some point stop referencing key or value). This makes it fragile to import some pre-minified code in projects, especially as the error does not show up until it is transpiled by Babel, the code works on its own.</p> <p dir="auto"><strong>Input Code</strong></p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="for (let x of [1]) { let x=1; }"><pre class="notranslate"><span class="pl-k">for</span> <span class="pl-kos">(</span><span class="pl-k">let</span> <span class="pl-s1">x</span> <span class="pl-k">of</span> <span class="pl-kos">[</span><span class="pl-c1">1</span><span class="pl-kos">]</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">let</span> <span class="pl-s1">x</span><span class="pl-c1">=</span><span class="pl-c1">1</span><span class="pl-kos">;</span> <span class="pl-kos">}</span></pre></div> <p dir="auto"><strong>Expected behavior/code</strong><br> <code class="notranslate">x</code> should be shadowed and the code should compile. Again, see <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/kzc/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/kzc">@kzc</a>'s comments below for exact expected behavior.</p> <p dir="auto"><strong>Environment</strong><br> Easily replicated in the Babel repl (online), 7.4.0, use es2015 or preset-env.</p> <p dir="auto"><a href="https://babeljs.io/repl/#?babili=false&amp;browsers=ie%20%3E%3D%2011&amp;build=&amp;builtIns=false&amp;spec=false&amp;loose=true&amp;code_lz=GYewTgBAFANgpgFwgDwiYEDaBGAugSggG8AoCCeJZAXmwG4SBfIA&amp;debug=false&amp;forceAllTransforms=false&amp;shippedProposals=false&amp;circleciRepo=&amp;evaluate=true&amp;fileSize=false&amp;timeTravel=false&amp;sourceType=module&amp;lineWrap=false&amp;presets=env&amp;prettier=false&amp;targets=&amp;version=7.4.5&amp;externalPlugins=" rel="nofollow">https://babeljs.io/repl/#?babili=false&amp;browsers=ie%20%3E%3D%2011&amp;build=&amp;builtIns=false&amp;spec=false&amp;loose=true&amp;code_lz=GYewTgBAFANgpgFwgDwiYEDaBGAugSggG8AoCCeJZAXmwG4SBfIA&amp;debug=false&amp;forceAllTransforms=false&amp;shippedProposals=false&amp;circleciRepo=&amp;evaluate=true&amp;fileSize=false&amp;timeTravel=false&amp;sourceType=module&amp;lineWrap=false&amp;presets=env&amp;prettier=false&amp;targets=&amp;version=7.4.5&amp;externalPlugins=</a></p> <p dir="auto"><strong>Possible Solution</strong><br> Do not throw the error, the code should compile.</p>
<h2 dir="auto">Bug Report</h2> <p dir="auto"><strong>Current Behavior</strong><br> Throws this exception:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="TypeError: undefined: Duplicate declaration &quot;i&quot; 1 | 2 | for (let i of 'foo') { &gt; 3 | let i = 'a'; | ^ 4 | console.log(i); 5 | } 6 | "><pre class="notranslate"><code class="notranslate">TypeError: undefined: Duplicate declaration "i" 1 | 2 | for (let i of 'foo') { &gt; 3 | let i = 'a'; | ^ 4 | console.log(i); 5 | } 6 | </code></pre></div> <p dir="auto"><strong>Input Code</strong></p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="for (let i of 'foo') { let i = 'a'; console.log(i); }"><pre class="notranslate"><span class="pl-k">for</span> <span class="pl-kos">(</span><span class="pl-k">let</span> <span class="pl-s1">i</span> <span class="pl-k">of</span> <span class="pl-s">'foo'</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">let</span> <span class="pl-s1">i</span> <span class="pl-c1">=</span> <span class="pl-s">'a'</span><span class="pl-kos">;</span> <span class="pl-smi">console</span><span class="pl-kos">.</span><span class="pl-en">log</span><span class="pl-kos">(</span><span class="pl-s1">i</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span></pre></div> <p dir="auto"><strong>Expected behavior/code</strong><br> Should prints <code class="notranslate">'a'</code> three times instead of throws this exception.<br> This is the behaviour in Node and Safari, for example.</p> <p dir="auto"><strong>Babel Configuration (CLI command)</strong></p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="const output = require('@babel/core').transform(` for (let i of 'foo') { let i = 'a'; console.log(i); } `, { presets: ['@babel/preset-env'] });"><pre class="notranslate"><span class="pl-k">const</span> <span class="pl-s1">output</span> <span class="pl-c1">=</span> <span class="pl-en">require</span><span class="pl-kos">(</span><span class="pl-s">'@babel/core'</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">transform</span><span class="pl-kos">(</span><span class="pl-s">`</span> <span class="pl-s">for (let i of 'foo') {</span> <span class="pl-s"> let i = 'a';</span> <span class="pl-s"> console.log(i);</span> <span class="pl-s">}</span> <span class="pl-s">`</span><span class="pl-kos">,</span> <span class="pl-kos">{</span> <span class="pl-c1">presets</span>: <span class="pl-kos">[</span><span class="pl-s">'@babel/preset-env'</span><span class="pl-kos">]</span> <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <p dir="auto"><strong>Environment</strong></p> <ul dir="auto"> <li>Babel version(s): lastest</li> <li>Node/npm version: Node 9</li> <li>OS: macOS High Sierra</li> <li>Monorepo: yes</li> <li>How you are using Babel: <code class="notranslate">cli</code></li> </ul>
1
<p dir="auto">I am currently using bootstrap as a library (not a boilerplate) for a node.js web server. The problem is that when I do this, then it takes forever to pull the entire repo and all history from github.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&quot;dependencies&quot;: { &quot;bootstrap&quot;: &quot;git+https://github.com/twbs/bootstrap.git#v3.0.0&quot; }"><pre class="notranslate"><code class="notranslate">"dependencies": { "bootstrap": "git+https://github.com/twbs/bootstrap.git#v3.0.0" } </code></pre></div> <p dir="auto">I noticed that the person that owns bootstrap on npm is not tied to this repo.<br> <a href="http://npmjs.org/package/bootstrap" rel="nofollow">http://npmjs.org/package/bootstrap</a></p> <p dir="auto">I would be thrilled if this repo was published as an npm module so that it could be included inside of a project without a git url pointing to npm.</p> <p dir="auto">Does anyone else feel this is important? If so, what are the next steps?</p>
<p dir="auto">With the launch of v3 and the new org, we should formalize the node packages that are out there and ensure they're kept up to date. No idea what this would take, but I'm making a note of it here so we tackle it soon. These two seem like the most popular, Less and Sass versions:</p> <p dir="auto"><strong>Bootstrap:</strong> <a href="https://npmjs.org/package/twitter-bootstrap" rel="nofollow">https://npmjs.org/package/twitter-bootstrap</a><br> <strong>Sass port:</strong> <a href="https://npmjs.org/package/bootstrap-sass" rel="nofollow">https://npmjs.org/package/bootstrap-sass</a></p> <p dir="auto">Let me know if folks think of any other ports, packages, add-ons, etc that could use formalizing (aside from Sass).</p>
1
<pre class="notranslate">The api.txt file does not include the values of constants. It needs to do so. Named constants must not change value over the lifetime of Go 1. If we have made any such mistakes already, we need to identify them. We need to have this fix in place for Go 1.2 to prevent future mistakes.</pre>
<pre class="notranslate">What does 'go version' print? go version devel +74a1371ffaf1 Tue Apr 22 17:13:38 2014 -0700 + linux/amd64 What steps reproduce the problem? Current lib/time/zoneinfo.zip is based on 2013g version of IANA timezone database. The most recent one is 2014b. Don't we want to update it before Go 1.3?</pre>
0
<h3 dir="auto">Playwright version</h3> <p dir="auto">1.12.0</p> <h3 dir="auto">Operating system</h3> <p dir="auto">MacOS, Linux</p> <h3 dir="auto">What browsers are you seeing the problem on?</h3> <p dir="auto">Chromium, Firefox, WebKit</p> <h3 dir="auto">Other information</h3> <p dir="auto">test-runner</p> <h3 dir="auto">What happened? / Describe the bug</h3> <p dir="auto">When running tests by the command <code class="notranslate">playwright test --reporter=junit --shard=1/2 </code>, in the junit report the skipped tests are marked "passed" with time '0'.</p> <p dir="auto">At the same time, in gitlab ci in Test, after testing in two different threads, the number of tests in the gitlab is more than it actually is.<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/37740578/125773766-824542be-fb36-4646-a812-90e7a7e8532e.png"><img src="https://user-images.githubusercontent.com/37740578/125773766-824542be-fb36-4646-a812-90e7a7e8532e.png" alt="image" style="max-width: 100%;"></a></p> <p dir="auto">I suggest not to include tests with time '0' in the JUnit report or don't include not running tests</p> <h3 dir="auto">Code snippet to reproduce your bug</h3> <p dir="auto"><em>No response</em></p> <h3 dir="auto">Relevant log output</h3> <p dir="auto"><em>No response</em></p>
<p dir="auto"><strong>Context:</strong></p> <ul dir="auto"> <li>Playwright Version: 1.3.0</li> <li>Operating System: Windows</li> <li>Node.js version: 12.18.3</li> <li>Browser: Chromium</li> </ul> <p dir="auto"><strong>Code Snippet</strong></p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="const { chromium } = require(&quot;playwright&quot;); (async () =&gt; { const browser = await chromium.launch(); const page = await browser.newPage(); await page.setContent( '&lt;input type=&quot;file&quot; name=&quot;fileToUpload&quot; id=&quot;fileToUpload&quot;&gt;' ); await page.setInputFiles(&quot;input&quot;, &quot;path/to/large/file.txt&quot;); await browser.close(); })(); "><pre class="notranslate"><span class="pl-k">const</span> <span class="pl-kos">{</span> chromium <span class="pl-kos">}</span> <span class="pl-c1">=</span> <span class="pl-en">require</span><span class="pl-kos">(</span><span class="pl-s">"playwright"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">(</span><span class="pl-k">async</span> <span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-k">const</span> <span class="pl-s1">browser</span> <span class="pl-c1">=</span> <span class="pl-k">await</span> <span class="pl-s1">chromium</span><span class="pl-kos">.</span><span class="pl-en">launch</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">const</span> <span class="pl-s1">page</span> <span class="pl-c1">=</span> <span class="pl-k">await</span> <span class="pl-s1">browser</span><span class="pl-kos">.</span><span class="pl-en">newPage</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">await</span> <span class="pl-s1">page</span><span class="pl-kos">.</span><span class="pl-en">setContent</span><span class="pl-kos">(</span> <span class="pl-s">'&lt;input type="file" name="fileToUpload" id="fileToUpload"&gt;'</span> <span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">await</span> <span class="pl-s1">page</span><span class="pl-kos">.</span><span class="pl-en">setInputFiles</span><span class="pl-kos">(</span><span class="pl-s">"input"</span><span class="pl-kos">,</span> <span class="pl-s">"path/to/large/file.txt"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">await</span> <span class="pl-s1">browser</span><span class="pl-kos">.</span><span class="pl-en">close</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <p dir="auto"><strong>Describe the bug</strong><br> When uploading large file, about 100MB, <code class="notranslate">page.setInputFiles</code> fails. With Firefox and Webkit it takes some time but it works.<br> Log:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" pw:api =&gt; page.setContent started +0ms pw:api setting frame content, waiting until &quot;load&quot; [] +1ms pw:api &lt;= page.setContent succeeded +79ms pw:api =&gt; page.setInputFiles started +2ms pw:api waiting for selector &quot;input&quot; [] +1ms pw:api selector resolved to visible &lt;input type=&quot;file&quot; id=&quot;fileToUpload&quot; name=&quot;fileToUpload&quot;/&gt; [] +26ms pw:api &lt;= page.setInputFiles failed +1s (node:19668) UnhandledPromiseRejectionWarning: page.setInputFiles: Protocol error (Runtime.callFunctionOn): Target closed. =========================== logs =========================== [api] waiting for selector &quot;input&quot; [api] selector resolved to visible &lt;input type=&quot;file&quot; id=&quot;fileToUpload&quot; name=&quot;fileToUpload&quot;/&gt; ============================================================ Note: use DEBUG=pw:api environment variable and rerun to capture Playwright logs.Error at C:\dev\playwright\node_modules\playwright\lib\chromium\crConnection.js:131:63 at new Promise (&lt;anonymous&gt;) at CRSession.send (C:\dev\playwright\node_modules\playwright\lib\chromium\crConnection.js:130:16) at CRSession.send (C:\dev\playwright\node_modules\playwright\lib\helper.js:80:31) at CRExecutionContext.evaluateWithArguments (C:\dev\playwright\node_modules\playwright\lib\chromium\crExecutionContext.js:40:79) at evaluateExpression (C:\dev\playwright\node_modules\playwright\lib\javascript.js:164:40) at async FrameManager.waitForSignalsCreatedBy (C:\dev\playwright\node_modules\playwright\lib\frames.js:90:24) at async FrameExecutionContext.evaluateInternal (C:\dev\playwright\node_modules\playwright\lib\dom.js:36:16) at async CRPage.setInputFiles (C:\dev\playwright\node_modules\playwright\lib\chromium\crPage.js:210:9) at async C:\dev\playwright\node_modules\playwright\lib\dom.js:440:13 -- ASYNC -- at CRSession.send (C:\dev\playwright\node_modules\playwright\lib\helper.js:79:23) at CRExecutionContext.evaluateWithArguments (C:\dev\playwright\node_modules\playwright\lib\chromium\crExecutionContext.js:40:79) at evaluateExpression (C:\dev\playwright\node_modules\playwright\lib\javascript.js:164:40) at async FrameManager.waitForSignalsCreatedBy (C:\dev\playwright\node_modules\playwright\lib\frames.js:90:24) at async FrameExecutionContext.evaluateInternal (C:\dev\playwright\node_modules\playwright\lib\dom.js:36:16) at async CRPage.setInputFiles (C:\dev\playwright\node_modules\playwright\lib\chromium\crPage.js:210:9) at async C:\dev\playwright\node_modules\playwright\lib\dom.js:440:13 at async FrameManager.waitForSignalsCreatedBy (C:\dev\playwright\node_modules\playwright\lib\frames.js:90:24) at async ElementHandle._setInputFiles (C:\dev\playwright\node_modules\playwright\lib\dom.js:438:9) at async C:\dev\playwright\node_modules\playwright\lib\frames.js:674:32 -- ASYNC -- at Frame.setInputFiles (C:\dev\playwright\node_modules\playwright\lib\helper.js:79:23) at C:\dev\playwright\node_modules\playwright\lib\page.js:407:61 at Page._attributeToPage (C:\dev\playwright\node_modules\playwright\lib\page.js:370:20) at Page.setInputFiles (C:\dev\playwright\node_modules\playwright\lib\page.js:407:21) at Page.setInputFiles (C:\dev\playwright\node_modules\playwright\lib\helper.js:80:31) at C:\dev\playwright\upload.js:9:14 (node:19668) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2) (node:19668) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code."><pre class="notranslate"><code class="notranslate"> pw:api =&gt; page.setContent started +0ms pw:api setting frame content, waiting until "load" [] +1ms pw:api &lt;= page.setContent succeeded +79ms pw:api =&gt; page.setInputFiles started +2ms pw:api waiting for selector "input" [] +1ms pw:api selector resolved to visible &lt;input type="file" id="fileToUpload" name="fileToUpload"/&gt; [] +26ms pw:api &lt;= page.setInputFiles failed +1s (node:19668) UnhandledPromiseRejectionWarning: page.setInputFiles: Protocol error (Runtime.callFunctionOn): Target closed. =========================== logs =========================== [api] waiting for selector "input" [api] selector resolved to visible &lt;input type="file" id="fileToUpload" name="fileToUpload"/&gt; ============================================================ Note: use DEBUG=pw:api environment variable and rerun to capture Playwright logs.Error at C:\dev\playwright\node_modules\playwright\lib\chromium\crConnection.js:131:63 at new Promise (&lt;anonymous&gt;) at CRSession.send (C:\dev\playwright\node_modules\playwright\lib\chromium\crConnection.js:130:16) at CRSession.send (C:\dev\playwright\node_modules\playwright\lib\helper.js:80:31) at CRExecutionContext.evaluateWithArguments (C:\dev\playwright\node_modules\playwright\lib\chromium\crExecutionContext.js:40:79) at evaluateExpression (C:\dev\playwright\node_modules\playwright\lib\javascript.js:164:40) at async FrameManager.waitForSignalsCreatedBy (C:\dev\playwright\node_modules\playwright\lib\frames.js:90:24) at async FrameExecutionContext.evaluateInternal (C:\dev\playwright\node_modules\playwright\lib\dom.js:36:16) at async CRPage.setInputFiles (C:\dev\playwright\node_modules\playwright\lib\chromium\crPage.js:210:9) at async C:\dev\playwright\node_modules\playwright\lib\dom.js:440:13 -- ASYNC -- at CRSession.send (C:\dev\playwright\node_modules\playwright\lib\helper.js:79:23) at CRExecutionContext.evaluateWithArguments (C:\dev\playwright\node_modules\playwright\lib\chromium\crExecutionContext.js:40:79) at evaluateExpression (C:\dev\playwright\node_modules\playwright\lib\javascript.js:164:40) at async FrameManager.waitForSignalsCreatedBy (C:\dev\playwright\node_modules\playwright\lib\frames.js:90:24) at async FrameExecutionContext.evaluateInternal (C:\dev\playwright\node_modules\playwright\lib\dom.js:36:16) at async CRPage.setInputFiles (C:\dev\playwright\node_modules\playwright\lib\chromium\crPage.js:210:9) at async C:\dev\playwright\node_modules\playwright\lib\dom.js:440:13 at async FrameManager.waitForSignalsCreatedBy (C:\dev\playwright\node_modules\playwright\lib\frames.js:90:24) at async ElementHandle._setInputFiles (C:\dev\playwright\node_modules\playwright\lib\dom.js:438:9) at async C:\dev\playwright\node_modules\playwright\lib\frames.js:674:32 -- ASYNC -- at Frame.setInputFiles (C:\dev\playwright\node_modules\playwright\lib\helper.js:79:23) at C:\dev\playwright\node_modules\playwright\lib\page.js:407:61 at Page._attributeToPage (C:\dev\playwright\node_modules\playwright\lib\page.js:370:20) at Page.setInputFiles (C:\dev\playwright\node_modules\playwright\lib\page.js:407:21) at Page.setInputFiles (C:\dev\playwright\node_modules\playwright\lib\helper.js:80:31) at C:\dev\playwright\upload.js:9:14 (node:19668) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). To terminate the node process on unhandled promise rejection, use the CLI flag `--unhandled-rejections=strict` (see https://nodejs.org/api/cli.html#cli_unhandled_rejections_mode). (rejection id: 2) (node:19668) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code. </code></pre></div>
0
<p dir="auto"><strong>Migrated issue, originally created by cieplak (<a href="https://github.com/cieplak">@cieplak</a>)</strong></p> <p dir="auto">Table reflection works in Postgres for regular views, but when reflecting materialized views, a sqlalchemy.exc.NoSuchTableError exception is raised.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="from sqlalchemy import Table from sqlalchemy.ext.compiler import compiles from sqlalchemy.sql.expression import Executable, ClauseElement class CreateView(Executable, ClauseElement): def __init__(self, name, select): self.name = name self.select = select @compiles(CreateView) def visit_create_view(element, compiler, **kw): return &quot;CREATE MATERIALIZED VIEW %s AS %s&quot; % ( element.name, compiler.process(element.select, literal_binds=True) ) from sqlalchemy import MetaData, Column, Integer from sqlalchemy.engine import create_engine uri = 'postgresql://postgres@localhost/postgres' engine = create_engine(uri) metadata = MetaData(engine) t = Table('t', metadata, Column('id', Integer, primary_key=True), Column('number', Integer)) t.create() engine.execute(t.insert().values(id=1, number=3)) engine.execute(t.insert().values(id=9, number=-3)) createview = CreateView('viewname', t.select().where(t.c.id&gt;5)) engine.execute(createview) v = Table('viewname', metadata, autoload=True) for r in engine.execute(v.select()): print r"><pre class="notranslate"><code class="notranslate">from sqlalchemy import Table from sqlalchemy.ext.compiler import compiles from sqlalchemy.sql.expression import Executable, ClauseElement class CreateView(Executable, ClauseElement): def __init__(self, name, select): self.name = name self.select = select @compiles(CreateView) def visit_create_view(element, compiler, **kw): return "CREATE MATERIALIZED VIEW %s AS %s" % ( element.name, compiler.process(element.select, literal_binds=True) ) from sqlalchemy import MetaData, Column, Integer from sqlalchemy.engine import create_engine uri = 'postgresql://postgres@localhost/postgres' engine = create_engine(uri) metadata = MetaData(engine) t = Table('t', metadata, Column('id', Integer, primary_key=True), Column('number', Integer)) t.create() engine.execute(t.insert().values(id=1, number=3)) engine.execute(t.insert().values(id=9, number=-3)) createview = CreateView('viewname', t.select().where(t.c.id&gt;5)) engine.execute(createview) v = Table('viewname', metadata, autoload=True) for r in engine.execute(v.select()): print r </code></pre></div>
<p dir="auto"><strong>Migrated issue, originally created by Erich Seifert (<a href="https://github.com/eseifert">@eseifert</a>)</strong></p> <p dir="auto">At the moment, with SQLAlchemy 0.8.4, introspecting a materialized view in a PostgreSQL 9.3.2 database fails with:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" File &quot;/tmp/test/meterializedview.py&quot;, line 16, in __init__ self.MaterializedView = Table('mytable', MetaData(), autoload=True, autoload_with=self.db) File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/schema.py&quot;, line 332, in __new__ table._init(name, metadata, *args, **kw) File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/schema.py&quot;, line 396, in _init self._autoload(metadata, autoload_with, include_columns) File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/schema.py&quot;, line 413, in _autoload self, include_columns, exclude_columns File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/engine/base.py&quot;, line 1595, in run_callable return conn.run_callable(callable_, *args, **kwargs) File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/engine/base.py&quot;, line 1118, in run_callable return callable_(self, *args, **kwargs) File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/engine/default.py&quot;, line 262, in reflecttable return insp.reflecttable(table, include_columns, exclude_columns) File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/engine/reflection.py&quot;, line 414, in reflecttable for col_d in self.get_columns(table_name, schema, **tblkw): File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/engine/reflection.py&quot;, line 254, in get_columns **kw) File &quot;&lt;string&gt;&quot;, line 1, in &lt;lambda&gt; File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/engine/reflection.py&quot;, line 49, in cache ret = fn(self, con, *args, **kw) File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/dialects/postgresql/base.py&quot;, line 1678, in get_columns info_cache=kw.get('info_cache')) File &quot;&lt;string&gt;&quot;, line 1, in &lt;lambda&gt; File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/engine/reflection.py&quot;, line 49, in cache ret = fn(self, con, *args, **kw) File &quot;/usr/lib64/python2.7/site-packages/sqlalchemy/dialects/postgresql/base.py&quot;, line 1593, in get_table_oid raise exc.NoSuchTableError(table_name) `#!sql SELECT c.oid FROM pg_catalog.pg_class c LEFT JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace WHERE (%s) AND c.relname = :table_name AND c.relkind in ('r','v')"><pre class="notranslate"><code class="notranslate"> File "/tmp/test/meterializedview.py", line 16, in __init__ self.MaterializedView = Table('mytable', MetaData(), autoload=True, autoload_with=self.db) File "/usr/lib64/python2.7/site-packages/sqlalchemy/schema.py", line 332, in __new__ table._init(name, metadata, *args, **kw) File "/usr/lib64/python2.7/site-packages/sqlalchemy/schema.py", line 396, in _init self._autoload(metadata, autoload_with, include_columns) File "/usr/lib64/python2.7/site-packages/sqlalchemy/schema.py", line 413, in _autoload self, include_columns, exclude_columns File "/usr/lib64/python2.7/site-packages/sqlalchemy/engine/base.py", line 1595, in run_callable return conn.run_callable(callable_, *args, **kwargs) File "/usr/lib64/python2.7/site-packages/sqlalchemy/engine/base.py", line 1118, in run_callable return callable_(self, *args, **kwargs) File "/usr/lib64/python2.7/site-packages/sqlalchemy/engine/default.py", line 262, in reflecttable return insp.reflecttable(table, include_columns, exclude_columns) File "/usr/lib64/python2.7/site-packages/sqlalchemy/engine/reflection.py", line 414, in reflecttable for col_d in self.get_columns(table_name, schema, **tblkw): File "/usr/lib64/python2.7/site-packages/sqlalchemy/engine/reflection.py", line 254, in get_columns **kw) File "&lt;string&gt;", line 1, in &lt;lambda&gt; File "/usr/lib64/python2.7/site-packages/sqlalchemy/engine/reflection.py", line 49, in cache ret = fn(self, con, *args, **kw) File "/usr/lib64/python2.7/site-packages/sqlalchemy/dialects/postgresql/base.py", line 1678, in get_columns info_cache=kw.get('info_cache')) File "&lt;string&gt;", line 1, in &lt;lambda&gt; File "/usr/lib64/python2.7/site-packages/sqlalchemy/engine/reflection.py", line 49, in cache ret = fn(self, con, *args, **kw) File "/usr/lib64/python2.7/site-packages/sqlalchemy/dialects/postgresql/base.py", line 1593, in get_table_oid raise exc.NoSuchTableError(table_name) `#!sql SELECT c.oid FROM pg_catalog.pg_class c LEFT JOIN pg_catalog.pg_namespace n ON n.oid = c.relnamespace WHERE (%s) AND c.relname = :table_name AND c.relkind in ('r','v') </code></pre></div> <p dir="auto">However, a new <code class="notranslate">relkind</code> value <code class="notranslate">m</code> was introduced for materialized views, which isn't handled at the moment.</p> <p dir="auto">To (partly) solve the problem for me, i just added <code class="notranslate">m</code> to the where clause:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="AND c.relname = :table_name AND c.relkind in ('r','v','m')"><pre class="notranslate"><code class="notranslate">AND c.relname = :table_name AND c.relkind in ('r','v','m') </code></pre></div> <p dir="auto">There are several other cases where <code class="notranslate">relkind</code> is used (<code class="notranslate">get_table_names</code>, <code class="notranslate">get_view_names</code>, <code class="notranslate">get_indexes</code>, etc.) where it isn't clear how to deal with materialized view because they are a hybrid of tables and views and can have their own indexes and table spaces.</p> <p dir="auto">As far as I can see, the same issue exists in SQLAlchemy 0.9 (browser:lib/sqlalchemy/dialects/postgresql/base.py, rev <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/sqlalchemy/sqlalchemy/commit/164bff07496c345c3c57a8b26439aa6a0fbce3b8/hovercard" href="https://github.com/sqlalchemy/sqlalchemy/commit/164bff07496c345c3c57a8b26439aa6a0fbce3b8"><tt>164bff0</tt></a>).</p>
1
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/apache/dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the <a href="https://github.com/apache/dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li> </ul> <h3 dir="auto">Environment</h3> <ul dir="auto"> <li>Dubbo version: 2.7.7</li> </ul> <h3 dir="auto">Steps to reproduce this issue</h3> <p dir="auto"><a href="https://github.com/apache/dubbo/tree/master/dubbo-dependencies-bom">https://github.com/apache/dubbo/tree/master/dubbo-dependencies-bom</a><br> &lt;nacos_version&gt;1.1.1&lt;/nacos_version&gt;</p> <h3 dir="auto">Expected Result</h3> <p dir="auto">&lt;nacos_version&gt;1.2.1&lt;/nacos_version&gt;<br> because we want using nacos-client 1.2.1 in our project.</p>
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/apache/dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the <a href="https://github.com/apache/dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li> </ul> <h3 dir="auto">Environment</h3> <ul dir="auto"> <li>Dubbo version: 2.7.2</li> <li>Operating System version: macOs</li> <li>Java version: JDK 1.8</li> </ul> <h3 dir="auto">Steps to reproduce this issue</h3> <ol dir="auto"> <li>Currently, my dubbo service is beyond 2.5.10, and going to upgrade 2.7.2. The build system errors me that DubboComponentScan is not exists in alibaba package, then select to auto-import apache one.</li> </ol> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import org.apache.dubbo.config.spring.context.annotation.DubboComponentScan; @SpringBootApplication @DubboComponentScan public class ServiceInitializer extends SpringBootServletInitializer { @Override protected SpringApplicationBuilder configure(SpringApplicationBuilder application) { return application.sources(ServiceInitializer.class); } }"><pre class="notranslate"><code class="notranslate">import org.apache.dubbo.config.spring.context.annotation.DubboComponentScan; @SpringBootApplication @DubboComponentScan public class ServiceInitializer extends SpringBootServletInitializer { @Override protected SpringApplicationBuilder configure(SpringApplicationBuilder application) { return application.sources(ServiceInitializer.class); } } </code></pre></div> <ol start="2" dir="auto"> <li>I have forgot to switch <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/service/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/service">@service</a> from alibaba to apache one. The IDE's alert doesn't obviously, and build system doesn't stop the build.</li> </ol> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import com.alibaba.dubbo.config.annotation.Service; @Service public class DemoServiceImpl implements DemoService { @Override public String sayHello(String name) { return &quot;welcome,&quot;+name; } }"><pre class="notranslate"><code class="notranslate">import com.alibaba.dubbo.config.annotation.Service; @Service public class DemoServiceImpl implements DemoService { @Override public String sayHello(String name) { return "welcome,"+name; } } </code></pre></div> <ol start="3" dir="auto"> <li>The application is running without error message, but service have not been started.</li> </ol> <p dir="auto">Pls. provide [GitHub address] to reproduce this issue.</p> <h3 dir="auto">Expected Result</h3> <p dir="auto">The DubboComponentScan should backward compatible with alibaba <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/service/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/service">@service</a> and <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/reference/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/reference">@reference</a>.</p> <h3 dir="auto">Actual Result</h3> <p dir="auto">It's incompatible with alibaba <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/service/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/service">@service</a> and <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/reference/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/reference">@reference</a>.</p> <p dir="auto">If there is an exception, please attach the exception trace:</p> <p dir="auto">The service have not thrown any exception, consumer will throw no provider exception as service not started.</p>
0
<p dir="auto">For instance, when I make a path on a windows system, it usually fails with a way too long error:</p> <div class="highlight highlight-source-go notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="package main import &quot;os&quot; func main() { err := os.MkdirAll(`C:\Users\AAAA\BBBB\CCCC\DDDD\EEEE\FFFF\GGGG\HHHH\IIII\JJJJ\KKKK\LLLL\MMMM\NNNN\OOOO\PPPP\QQQQ\RRRR\SSSS\TTTT\UUUU\VVVV\WWWW\XXXX\YYYY\ZZZZ\AAAA\BBBB\CCCC\DDDD\EEEE\FFFF\GGGG\HHHH\IIII\JJJJ\KKKK\LLLL\MMMM\NNNN\OOOO\PPPP\QQQQ\RRRR\SSSS\TTTT\UUUU\VVVV\WWWW\XXXX\YYYY\ZZZZ`, os.ModePerm) if err != nil { panic(err) } } ...... // result mkdir C:\Users\AAAA\BBBB\CCCC\DDDD\EEEE\FFFF\GGGG\HHHH\IIII\JJJJ\KKKK\LLLL\MMMM\NNNN\OOOO\PPPP\QQQQ\RRRR\SSSS\TTTT\UUUU\VVVV\WWWW\XXXX\YYYY\ ZZZZ\AAAA\BBBB\CCCC\DDDD\EEEE\FFFF\GGGG\HHHH\IIII\JJJJ\KKKK\LLLL\MMMM\NNNN\OOOO\PPPP\QQQQ\RRRR\SSSS\TTTT\UUUU\VVVV: The filename or extensio n is too long."><pre class="notranslate"><span class="pl-k">package</span> main <span class="pl-k">import</span> <span class="pl-s">"os"</span> <span class="pl-k">func</span> <span class="pl-en">main</span>() { <span class="pl-s1">err</span> <span class="pl-c1">:=</span> <span class="pl-s1">os</span>.<span class="pl-en">MkdirAll</span>(<span class="pl-s">`C:\Users\AAAA\BBBB\CCCC\DDDD\EEEE\FFFF\GGGG\HHHH\IIII\JJJJ\KKKK\LLLL\MMMM\NNNN\OOOO\PPPP\QQQQ\RRRR\SSSS\TTTT\UUUU\VVVV\WWWW\XXXX\YYYY\ZZZZ\AAAA\BBBB\CCCC\DDDD\EEEE\FFFF\GGGG\HHHH\IIII\JJJJ\KKKK\LLLL\MMMM\NNNN\OOOO\PPPP\QQQQ\RRRR\SSSS\TTTT\UUUU\VVVV\WWWW\XXXX\YYYY\ZZZZ`</span>, <span class="pl-s1">os</span>.<span class="pl-c1">ModePerm</span>) <span class="pl-k">if</span> <span class="pl-s1">err</span> <span class="pl-c1">!=</span> <span class="pl-c1">nil</span> { <span class="pl-en">panic</span>(<span class="pl-s1">err</span>) } } <span class="pl-c1">...</span><span class="pl-c1">...</span> <span class="pl-c">// result</span> mkdir <span class="pl-s1">C</span>:\U<span class="pl-s1">sers</span><span class="pl-cce">\A</span><span class="pl-s1">AAA</span><span class="pl-cce">\B</span><span class="pl-s1">BBB</span><span class="pl-cce">\C</span><span class="pl-s1">CCC</span><span class="pl-cce">\D</span><span class="pl-s1">DDD</span><span class="pl-cce">\E</span><span class="pl-s1">EEE</span><span class="pl-cce">\F</span><span class="pl-s1">FFF</span><span class="pl-cce">\G</span><span class="pl-s1">GGG</span><span class="pl-cce">\H</span><span class="pl-s1">HHH</span><span class="pl-cce">\I</span><span class="pl-s1">III</span><span class="pl-cce">\J</span><span class="pl-s1">JJJ</span><span class="pl-cce">\K</span><span class="pl-s1">KKK</span><span class="pl-cce">\L</span><span class="pl-s1">LLL</span><span class="pl-cce">\M</span><span class="pl-s1">MMM</span><span class="pl-cce">\N</span><span class="pl-s1">NNN</span><span class="pl-cce">\O</span><span class="pl-s1">OOO</span><span class="pl-cce">\P</span><span class="pl-s1">PPP</span><span class="pl-cce">\Q</span><span class="pl-s1">QQQ</span><span class="pl-cce">\R</span><span class="pl-s1">RRR</span><span class="pl-cce">\S</span><span class="pl-s1">SSS</span><span class="pl-cce">\T</span><span class="pl-s1">TTT</span>\U<span class="pl-s1">UUU</span><span class="pl-cce">\V</span><span class="pl-s1">VVV</span><span class="pl-cce">\W</span><span class="pl-s1">WWW</span><span class="pl-cce">\X</span><span class="pl-s1">XXX</span><span class="pl-cce">\Y</span><span class="pl-s1">YYY</span><span class="pl-cce">\</span> <span class="pl-cce"></span><span class="pl-s1">ZZZZ</span><span class="pl-cce">\A</span><span class="pl-s1">AAA</span><span class="pl-cce">\B</span><span class="pl-s1">BBB</span><span class="pl-cce">\C</span><span class="pl-s1">CCC</span><span class="pl-cce">\D</span><span class="pl-s1">DDD</span><span class="pl-cce">\E</span><span class="pl-s1">EEE</span><span class="pl-cce">\F</span><span class="pl-s1">FFF</span><span class="pl-cce">\G</span><span class="pl-s1">GGG</span><span class="pl-cce">\H</span><span class="pl-s1">HHH</span><span class="pl-cce">\I</span><span class="pl-s1">III</span><span class="pl-cce">\J</span><span class="pl-s1">JJJ</span><span class="pl-cce">\K</span><span class="pl-s1">KKK</span><span class="pl-cce">\L</span><span class="pl-s1">LLL</span><span class="pl-cce">\M</span><span class="pl-s1">MMM</span><span class="pl-cce">\N</span><span class="pl-s1">NNN</span><span class="pl-cce">\O</span><span class="pl-s1">OOO</span><span class="pl-cce">\P</span><span class="pl-s1">PPP</span><span class="pl-cce">\Q</span><span class="pl-s1">QQQ</span><span class="pl-cce">\R</span><span class="pl-s1">RRR</span><span class="pl-cce">\S</span><span class="pl-s1">SSS</span><span class="pl-cce">\T</span><span class="pl-s1">TTT</span>\U<span class="pl-s1">UUU</span><span class="pl-cce">\V</span>VVV: <span class="pl-s1">The</span> <span class="pl-s1">filename</span> <span class="pl-s1">or</span> <span class="pl-s1">extensio</span> <span class="pl-s1">n</span> <span class="pl-s1">is</span> <span class="pl-s1">too</span> <span class="pl-s1">long</span>.</pre></div> <p dir="auto">To be clear, this is usually fixed by prepending <code class="notranslate">\\?\</code> to the path.</p> <p dir="auto">What version of Go are you using (go version)? <strong>go1.5.3</strong><br> What operating system and processor architecture are you using? <strong>windows/amd64 - Windows2012R2</strong><br> What did you do? <strong>Create a very very long path, as per example</strong><br> What did you expect to see? <strong>No error creating the directory</strong><br> What did you see instead? <strong>os.PathError creating the directory</strong></p>
<pre class="notranslate">This program creates directory, but fails to create file inside (CAREFUL IF CHANGING THIS PROGRAM - YOU MIGHT END UP WITH FILES/DIRECTORIES YOU WILL NOT BE ABLE TO DELETE WITH STANDARD SHELL TOOLS): package main import ( "fmt" "log" "os" "strings" ) func main() { // root := `\\?\c:\` root := `c:\` dir := root + strings.Repeat("d", 200) file := dir + `\` + strings.Repeat("f", 200) err := os.Mkdir(dir, 0777) if err != nil { log.Fatalf("Mkdir(%s): %v", dir, err) } f, err := os.Create(file) if err != nil { log.Fatalf("Create(%s): %v", file, err) } _, err = fmt.Fprintf(f, "Hello world") if err != nil { log.Fatalf("Fprintf(%s): %v", file, err) } err = f.Close() if err != nil { log.Fatalf("Close(%s): %v", file, err) } err = os.Remove(file) if err != nil { log.Fatalf("Remove(%s): %v", file, err) } err = os.Remove(dir) if err != nil { log.Fatalf("Remove(%s): %v", dir, err) } } This can be handled properly if we use \\?\ path prefix (uncomment line in the code). But \\?\ prefixed paths needs to be "normalized": they have to be absolute, no . or .. allowed, / is not allowed, UNC paths needs to be handled properly. See <a href="http://goo.gl/th2fJ" rel="nofollow">http://goo.gl/th2fJ</a> for details, especially "Maximum Path Length Limitation" section. This issue has come up on our own builder: <a href="http://goo.gl/FbblU" rel="nofollow">http://goo.gl/FbblU</a>. Perhaps our own paths do not need to be that long. I did not look into that yet. Alex</pre>
1
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> I have searched the <a href="https://github.com/apache/incubator-dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> I have checked the <a href="https://github.com/apache/incubator-dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li> </ul> <h3 dir="auto">如题</h3> <ul dir="auto"> <li>在阿里云仓库或者maven仓库中根本找不到org.apache.dubbo下相关的依赖啊,只能找到com.alibaba下的依赖啊</li> <li>尝试对着这个官方例子练习,一直拉不下jar...</li> </ul>
<ul dir="auto"> <li>[] I have searched the <a href="https://github.com/apache/dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li> <li>[ 1] I have checked the <a href="https://github.com/apache/dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li> </ul> <h3 dir="auto">Environment</h3> <ul dir="auto"> <li>Dubbo version: 2.7.3</li> <li>Operating System version: win10</li> <li>Java version: 1.8</li> </ul> <h3 dir="auto">Steps to reproduce this issue</h3> <ol dir="auto"> <li>I didn't add any configuration about monitor in app;</li> <li>Provider and consumer Startup success;</li> <li>Call someone interface and get exception like "java.lang.NoClassDefFoundError: com/alibaba/dubbo/monitor/MonitorService".</li> </ol> <p dir="auto">How to disable dubbo's monitor related services if I don't want to use monitor.</p>
0
<p dir="auto">I'm getting a weird error when trying to <code class="notranslate">jit</code> things:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Traceback (most recent call last): File &quot;/home/ubuntu/dev/research/lottery/cifar10_convnet_run.py&quot;, line 228, in &lt;module&gt; test_make_batcher() File &quot;/home/ubuntu/dev/research/lottery/cifar10_convnet_run.py&quot;, line 87, in test_make_batcher for fn in [make_batcher(5, 2), jit(make_batcher(5, 2))]: File &quot;/home/ubuntu/dev/research/lottery/cifar10_convnet_run.py&quot;, line 79, in make_batcher splits = list(jnp.arange(1, num_examples // batch_size + 1) * batch_size) File &quot;/nix/store/ix119bzn54cgvsm98cidfdb4c8w0v1qc-python3.9-jax-0.3.0/lib/python3.9/site-packages/jax/_src/numpy/lax_numpy.py&quot;, line 6747, in deferring_binary_op return binary_op(self, other) RuntimeError: UNKNOWN: PTX JIT compiler library not found in external/org_tensorflow/tensorflow/stream_executor/cuda/cuda_asm_compiler.cc(56): 'cuLinkCreate(0, nullptr, nullptr, &amp;link_state)'"><pre class="notranslate"><code class="notranslate">Traceback (most recent call last): File "/home/ubuntu/dev/research/lottery/cifar10_convnet_run.py", line 228, in &lt;module&gt; test_make_batcher() File "/home/ubuntu/dev/research/lottery/cifar10_convnet_run.py", line 87, in test_make_batcher for fn in [make_batcher(5, 2), jit(make_batcher(5, 2))]: File "/home/ubuntu/dev/research/lottery/cifar10_convnet_run.py", line 79, in make_batcher splits = list(jnp.arange(1, num_examples // batch_size + 1) * batch_size) File "/nix/store/ix119bzn54cgvsm98cidfdb4c8w0v1qc-python3.9-jax-0.3.0/lib/python3.9/site-packages/jax/_src/numpy/lax_numpy.py", line 6747, in deferring_binary_op return binary_op(self, other) RuntimeError: UNKNOWN: PTX JIT compiler library not found in external/org_tensorflow/tensorflow/stream_executor/cuda/cuda_asm_compiler.cc(56): 'cuLinkCreate(0, nullptr, nullptr, &amp;link_state)' </code></pre></div> <p dir="auto">What does this mean? What .so am I missing? I can confirm that I have <code class="notranslate">libnvidia-ptxjitcompiler.so</code>, <code class="notranslate">libnvidia-ptxjitcompiler.so.1</code>, and <code class="notranslate">libnvidia-ptxjitcompiler.so.495.44</code> all on my system.</p> <p dir="auto">Please:</p> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> Check for duplicate issues.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> Provide a complete example of how to reproduce the bug, wrapped in triple backticks like this:</li> </ul> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="from jax import jit jit(lambda x: 2*x)"><pre class="notranslate"><span class="pl-k">from</span> <span class="pl-s1">jax</span> <span class="pl-k">import</span> <span class="pl-s1">jit</span> <span class="pl-en">jit</span>(<span class="pl-k">lambda</span> <span class="pl-s1">x</span>: <span class="pl-c1">2</span><span class="pl-c1">*</span><span class="pl-s1">x</span>)</pre></div> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> If applicable, include full error messages/tracebacks.<br> <a href="https://gist.github.com/samuela/7245561c382842d70a729caecbd11912">https://gist.github.com/samuela/7245561c382842d70a729caecbd11912</a></li> </ul>
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> Check for duplicate issues.<br> I searched <code class="notranslate">is:issue is:open pip install jaxlib metadata</code></li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> Provide a complete example of how to reproduce the bug:</li> </ul> <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="pip install --upgrade jax==0.2.0 jaxlib==0.1.55+cuda110 -f https://storage.googleapis.com/jax-releases/jax_releases.html"><pre class="notranslate">pip install --upgrade jax==0.2.0 jaxlib==0.1.55+cuda110 -f https://storage.googleapis.com/jax-releases/jax_releases.html</pre></div> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> If applicable, include full error messages/tracebacks. Returns:</li> </ul> <blockquote> <p dir="auto">Looking in links: <a href="https://storage.googleapis.com/jax-releases/jax_releases.html" rel="nofollow">https://storage.googleapis.com/jax-releases/jax_releases.html</a><br> Requirement already satisfied: jax==0.2.0 in /home/jb/anaconda3/envs/cuda111/lib/python3.8/site-packages (0.2.0)<br> Collecting jaxlib==0.1.55+cuda110<br> Using cached <a href="https://storage.googleapis.com/jax-releases/cuda110/jaxlib-0.1.55%2Bcuda110-cp38-none-manylinux2010_x86_64.whl" rel="nofollow">https://storage.googleapis.com/jax-releases/cuda110/jaxlib-0.1.55%2Bcuda110-cp38-none-manylinux2010_x86_64.whl</a> (155.2 MB)<br> WARNING: Discarding <a href="https://storage.googleapis.com/jax-releases/cuda110/jaxlib-0.1.55%2Bcuda110-cp38-none-manylinux2010_x86_64.whl" rel="nofollow">https://storage.googleapis.com/jax-releases/cuda110/jaxlib-0.1.55%2Bcuda110-cp38-none-manylinux2010_x86_64.whl</a> (from <a href="https://storage.googleapis.com/jax-releases/jax_releases.html" rel="nofollow">https://storage.googleapis.com/jax-releases/jax_releases.html</a>). Requested jaxlib==0.1.55+cuda110 from <a href="https://storage.googleapis.com/jax-releases/cuda110/jaxlib-0.1.55%2Bcuda110-cp38-none-manylinux2010_x86_64.whl" rel="nofollow">https://storage.googleapis.com/jax-releases/cuda110/jaxlib-0.1.55%2Bcuda110-cp38-none-manylinux2010_x86_64.whl</a> has inconsistent version: filename has '0.1.55+cuda110', but metadata has '0.1.55'<br> ERROR: Could not find a version that satisfies the requirement jaxlib==0.1.55+cuda110 (from versions: 0.1, 0.1.1, 0.1.32, 0.1.33, 0.1.34, 0.1.35, 0.1.36, 0.1.37, 0.1.38, 0.1.39, 0.1.40, 0.1.41, 0.1.42, 0.1.43, 0.1.44, 0.1.45, 0.1.46, 0.1.47, 0.1.48, 0.1.50, 0.1.51, 0.1.52, 0.1.52+cuda100, 0.1.52+cuda101, 0.1.52+cuda102, 0.1.52+cuda110, 0.1.55, 0.1.55+cuda100, 0.1.55+cuda101, 0.1.55+cuda102, 0.1.55+cuda110, 0.1.56, 0.1.56+cuda100, 0.1.56+cuda101, 0.1.56+cuda102, 0.1.56+cuda110, 0.1.56+cuda111, 0.1.57, 0.1.57+cuda101, 0.1.57+cuda102, 0.1.57+cuda110, 0.1.57+cuda111, 0.1.58, 0.1.58+cuda101, 0.1.58+cuda102, 0.1.58+cuda110, 0.1.58+cuda111, 0.1.59, 0.1.59+cuda101, 0.1.59+cuda102, 0.1.59+cuda110, 0.1.59+cuda111, 0.1.60, 0.1.60+cuda101, 0.1.60+cuda102, 0.1.60+cuda110, 0.1.60+cuda111, 0.1.61, 0.1.61+cuda101, 0.1.61+cuda102, 0.1.61+cuda110, 0.1.61+cuda111, 0.1.61+cuda112, 0.1.62, 0.1.62+cuda101, 0.1.62+cuda102, 0.1.62+cuda110, 0.1.62+cuda111, 0.1.62+cuda112, 0.1.63, 0.1.63+cuda101, 0.1.63+cuda102, 0.1.63+cuda110, 0.1.63+cuda111, 0.1.63+cuda112, 0.1.64, 0.1.64+cuda101, 0.1.64+cuda102, 0.1.64+cuda110, 0.1.64+cuda111, 0.1.64+cuda112, 0.1.65, 0.1.65+cuda101, 0.1.65+cuda102, 0.1.65+cuda110, 0.1.65+cuda111, 0.1.65+cuda112, 0.1.66, 0.1.66+cuda101, 0.1.66+cuda102, 0.1.66+cuda110, 0.1.66+cuda111, 0.1.67, 0.1.67+cuda101, 0.1.67+cuda102, 0.1.67+cuda110, 0.1.67+cuda111)<br> ERROR: No matching distribution found for jaxlib==0.1.55+cuda110</p> </blockquote> <p dir="auto">Conda env at time of install:<br> <a href="https://github.com/google/jax/files/6626643/tmp.txt">env.txt</a></p> <p dir="auto">Notable: my cuda toollkit version is 11.1 (to use with torch). I am pinned back on jax 0.1.55 due to DeepMind GLN implementation, if curious.</p> <p dir="auto">Edit: Using GTX 1070</p>
0
<p dir="auto">Now that <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="475389232" data-permission-text="Title is private" data-url="https://github.com/JuliaLang/julia/issues/32753" data-hovercard-type="pull_request" data-hovercard-url="/JuliaLang/julia/pull/32753/hovercard" href="https://github.com/JuliaLang/julia/pull/32753">#32753</a> has landed, for Julia 2.0+ , we should deprecate the <code class="notranslate">@evalpoly</code> macro.</p>
<p dir="auto">Consider a Julia neophyte trying to sort <code class="notranslate">Char</code>s:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; maximum('A', 'B') ERROR: MethodError: objects of type Char are not callable Stacktrace: [1] mapreduce_first(::Char, ::Function, ::Char) at ./reduce.jl:293 [2] mapfoldl_impl(::Char, ::Function, ::NamedTuple{(),Tuple{}}, ::Char) at ./reduce.jl:60 [3] #mapfoldl#186(::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::typeof(mapfoldl), ::Char, ::Function, ::Char) at ./reduce.jl:72 [4] mapfoldl(::Char, ::Function, ::Char) at ./reduce.jl:72 [5] #mapreduce#194(::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::typeof(mapreduce), ::Char, ::Function, ::Char) at ./reduce.jl:200 [6] mapreduce(::Char, ::Function, ::Char) at ./reduce.jl:200 [7] maximum(::Char, ::Char) at ./reduce.jl:524 [8] top-level scope at none:0"><pre class="notranslate"><code class="notranslate">julia&gt; maximum('A', 'B') ERROR: MethodError: objects of type Char are not callable Stacktrace: [1] mapreduce_first(::Char, ::Function, ::Char) at ./reduce.jl:293 [2] mapfoldl_impl(::Char, ::Function, ::NamedTuple{(),Tuple{}}, ::Char) at ./reduce.jl:60 [3] #mapfoldl#186(::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::typeof(mapfoldl), ::Char, ::Function, ::Char) at ./reduce.jl:72 [4] mapfoldl(::Char, ::Function, ::Char) at ./reduce.jl:72 [5] #mapreduce#194(::Base.Iterators.Pairs{Union{},Union{},Tuple{},NamedTuple{(),Tuple{}}}, ::typeof(mapreduce), ::Char, ::Function, ::Char) at ./reduce.jl:200 [6] mapreduce(::Char, ::Function, ::Char) at ./reduce.jl:200 [7] maximum(::Char, ::Char) at ./reduce.jl:524 [8] top-level scope at none:0 </code></pre></div> <p dir="auto">Of course they should have used <code class="notranslate">max</code>. But that stack trace is long and confusing, considering that already the very first call <code class="notranslate">maximum(::Char, ::Char)</code>, the types are all wrong for <code class="notranslate">maximum</code>. Normally, Julia methods have a signature that takes only appropritate abstract types, like <code class="notranslate">Number</code> and so on, precisely so that the method only apply to inputs of the correct types.</p> <p dir="auto">The problem is that there are no types for <code class="notranslate">Callable</code> or <code class="notranslate">Iterable</code>, so the signature of <code class="notranslate"> maximum</code> is totally untyped: <code class="notranslate">maximum(f, a) = mapreduce(f, max, a)</code>.</p> <p dir="auto">To solve this, I suggest implementing Holy traits <code class="notranslate">Iterable</code> and <code class="notranslate">Callable</code>:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="maximum(f, itr) = maximum(f, callable(f), itr, iterable(itr)) maximum(f, ::Callable, itr, ::Iterable)"><pre class="notranslate"><code class="notranslate">maximum(f, itr) = maximum(f, callable(f), itr, iterable(itr)) maximum(f, ::Callable, itr, ::Iterable) </code></pre></div> <p dir="auto">One argument against doing this is that it could open the door to all kinds of traits in Base for this or that property. However, in my experience, it seems like the properties "iterable" and "callable" are particularly often used, just consider the amount of confusion about what is iterable or not we often see.</p>
0
<p dir="auto">Hello,<br> I'm running Airflow 1.10.10 and using the <code class="notranslate">GCSToBigQueryOperator</code> from <code class="notranslate">airflow.providers.google.cloud.transfers.gcs_to_bigquery</code> in order to load data from google cloud storage into a big query table.<br> Although everything is working as expected, I keep seeing (a lot of) deprecation warnings in my logs:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="DeprecationWarning: The bigquery_conn_id parameter has been deprecated. You should pass the gcp_conn_id parameter. bigquery.py:103: DeprecationWarning: This method will be deprecated. Please use `BigQueryHook.get_client` method` taskinstance.py:984: DeprecationWarning: This method is deprecated. Please use airflow.providers.google.cloud.hooks.bigquery.BigQueryHook.run_load` bigquery.py:1614: DeprecationWarning: This method is deprecated. Please use `BigQueryHook.insert_job` method."><pre class="notranslate"><code class="notranslate">DeprecationWarning: The bigquery_conn_id parameter has been deprecated. You should pass the gcp_conn_id parameter. bigquery.py:103: DeprecationWarning: This method will be deprecated. Please use `BigQueryHook.get_client` method` taskinstance.py:984: DeprecationWarning: This method is deprecated. Please use airflow.providers.google.cloud.hooks.bigquery.BigQueryHook.run_load` bigquery.py:1614: DeprecationWarning: This method is deprecated. Please use `BigQueryHook.insert_job` method. </code></pre></div> <p dir="auto">Although everything is working well, I'm afraid that in the future those warnings will indeed cause problems.<br> Please update the code and find a way to use the suggested methods instead of the deprecated ones.<br> If any more information is needed from me regarding the warnings or my system I will be happy to add it.<br> Thank you!</p>
<p dir="auto">Current issue is I have pools configured on same type of task where I can have up to max 100 pool slots of that task type running in parallel BUT I want ability to say don't START running more than 5 at a time. So ideally these tasks should be scheduled in steps.<br> ie<br> at each scheduler iteration 1 (ie 9:03:30 am) 5 tasks scheduled for the pool<br> at each scheduler iteration 2 (ie 9:04:00 am) 5 more tasks scheduled for the pool (so 10 currently running in the pool)<br> at each scheduler iteration 3 (ie 9:04:30 am) 5 more tasks scheduled for the pool (so 15 currently running in the pool)<br> at 9:04:42 am 3 tasks completed for the pool<br> at each scheduler iteration 4 (ie 9:05:00 am) 5 more tasks scheduled for the pool (so 17 currently running in the pool)<br> ..etc</p>
0
<p dir="auto">If not I would like to request this feature.</p> <p dir="auto">Given the fact that npm modules have been hacked before and that I/we will use modules from the registry it would be nice if we could reduce the threat of these modules and only give permissions to each module if necessary.</p> <p dir="auto">If this is possible I would suggest a new parameter like --block-external which would deny all given permissions from cached/external modules and than each permission could be extended by a list that would come after it.</p> <p dir="auto">I don't really know if this is feasible.<br> Btw good job on Deno! Its pretty cool so far.</p>
<p dir="auto">So I love the concept of privileged vs. unprivileged. During the talk at JSConf, Ryan recognizes that a linter should not be allowed to, for example, make network requests. I think this is a powerful concept, but I also think it's not quite powerful enough.</p> <p dir="auto">JS and in particular node/npm gets a bad rep these days for security. First of all, I think this is unwarranted generally speaking, as the kinds of things people point out are equally accurate in most package managers/languages/runtimes, if not more so. However, if deno is going to consider permissions to be a language/runtime level concern, I think it should go a step further.</p> <p dir="auto">For some context, I want to point to <a href="https://hackernoon.com/im-harvesting-credit-card-numbers-and-passwords-from-your-site-here-s-how-9a8cb347c5b5" rel="nofollow">the article I've seen most on this topic</a>. The concern in this particular article is a little different than the one I'm proposing deno attempt to solve because deno is backend and the article proposes a frontend security issue, but it's certainly related and if deno is going to end up with similar usecases to node, of course we will be using it on the front end as well. The issue is that a node module N dependencies deep can do arbitrary things like read files, read environment variables, make requests to servers, etc., and the end user won't necessarily ever know about it (and the middle package maintainers very well might not either).</p> <p dir="auto">Sandboxing on an application-level is a start, but I just don't think it goes far enough for practical needs. I think an amazing module/dependency system (which I think deno is trying to create) should be able to "sandbox" individual module/dependencies, and that this should even be the default behavior.</p> <p dir="auto">Unfortunately, barring switching back to <code class="notranslate">require</code>, all of the ideas I have either rely on using some kind of manifest such as package.json, a language-level change, some kind of string-related kludge, or mandatory dependency injection. In my opinion, the first two are the most reasonable (knowing absolutely nothing about deno internals).</p> <hr> <p dir="auto">The manifest solution is, of course, quite simple. You can just add permissions to modules that would cascade down. An example given using typical package.json structure:</p> <div class="highlight highlight-source-json notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="{ &quot;dependencies&quot;: { &quot;https://unpkg.com/somepackage@0.0.1/somepackage.min.js&quot;: { &quot;permissions&quot;: { &quot;http&quot;: true, &quot;fs&quot;: true } }, &quot;https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js&quot;: { &quot;permissions&quot;: { &quot;*&quot;: true } } } }"><pre class="notranslate">{ <span class="pl-ent">"dependencies"</span>: { <span class="pl-ent">"https://unpkg.com/somepackage@0.0.1/somepackage.min.js"</span>: { <span class="pl-ent">"permissions"</span>: { <span class="pl-ent">"http"</span>: <span class="pl-c1">true</span>, <span class="pl-ent">"fs"</span>: <span class="pl-c1">true</span> } }, <span class="pl-ent">"https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js"</span>: { <span class="pl-ent">"permissions"</span>: { <span class="pl-ent">"*"</span>: <span class="pl-c1">true</span> } } } }</pre></div> <hr> <p dir="auto">A language level solution might include a tweak to <code class="notranslate">import</code> such as <code class="notranslate">import a from 'https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js' permit(http, fs)</code> or a more Rusty solution which I kind of like better:</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import a from 'https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js'; await a.initializeSafely(); // ... %permit(http, fs) { await a.doSomethingDangerous(); }"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">a</span> <span class="pl-k">from</span> <span class="pl-s">'https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js'</span><span class="pl-kos">;</span> <span class="pl-k">await</span> <span class="pl-s1">a</span><span class="pl-kos">.</span><span class="pl-en">initializeSafely</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-c">// ...</span> <span class="pl-c1">%</span><span class="pl-en">permit</span><span class="pl-kos">(</span><span class="pl-s1">http</span><span class="pl-kos">,</span> <span class="pl-s1">fs</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">await</span> <span class="pl-s1">a</span><span class="pl-kos">.</span><span class="pl-en">doSomethingDangerous</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span></pre></div> <p dir="auto">The reason I like this solution better is because it now makes it even harder for package writers to hijack permissions just because they happen to be using them elsewhere. That is to say, now <em>only</em> <code class="notranslate">doSomethingDangerous</code> can make http requests, while <code class="notranslate">initializeSafely</code> remains safe. So the package writers can't use the permissions you give them just because you import them.</p> <p dir="auto">I think this is harder to enforce at runtime in general but especially in-browser, but I'd leave that to ebwckpa or whomever.</p> <p dir="auto">Arguably, this is also similar to what Haskell might do, or just similar to how <code class="notranslate">async/await</code> works with the implicit "pre-emption" permission; you need to yield power to it for it to use that power. If arbitrary commands could allow pre-emption, that would be inherently insecure as much of our code is written with the understanding that it will be executed synchronously.</p> <hr> <p dir="auto">A string related kludge is very similar to modifying <code class="notranslate">import</code>:</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import a from 'https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js permit(http, fs)';"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">a</span> <span class="pl-k">from</span> <span class="pl-s">'https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js permit(http, fs)'</span><span class="pl-kos">;</span></pre></div> <p dir="auto">I don't love it but it would be relatively easy to implement on the surface level, I believe, as it's just a matter of resolution middleware.</p> <hr> <p dir="auto">Mandatory dependency injection would essentially disallow libraries from importing system APIs. This is kind of nice for all the reasons dependency injection is nice, and annoying for all the reasons dependency injection is annoying.</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import makeA from 'https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js'; import fs from 'fs'; import http from 'http'; const a = makeA({ fs, http }); await a.doSomethingDangerous();"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">makeA</span> <span class="pl-k">from</span> <span class="pl-s">'https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js'</span><span class="pl-kos">;</span> <span class="pl-k">import</span> <span class="pl-s1">fs</span> <span class="pl-k">from</span> <span class="pl-s">'fs'</span><span class="pl-kos">;</span> <span class="pl-k">import</span> <span class="pl-s1">http</span> <span class="pl-k">from</span> <span class="pl-s">'http'</span><span class="pl-kos">;</span> <span class="pl-k">const</span> <span class="pl-s1">a</span> <span class="pl-c1">=</span> <span class="pl-en">makeA</span><span class="pl-kos">(</span><span class="pl-kos">{</span> fs<span class="pl-kos">,</span> http <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">await</span> <span class="pl-s1">a</span><span class="pl-kos">.</span><span class="pl-en">doSomethingDangerous</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <p dir="auto">I could also see this being combined with an import modification:</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import makeA from 'https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js' with fs=fs, http=http;"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">makeA</span> <span class="pl-k">from</span> <span class="pl-s">'https://unpkg.com/highlytrustedpackage@1.2.3/ok.min.js'</span> <span class="pl-s1">with</span> <span class="pl-s1">fs</span><span class="pl-c1">=</span><span class="pl-s1">fs</span><span class="pl-kos">,</span> <span class="pl-s1">http</span><span class="pl-c1">=</span><span class="pl-s1">http</span><span class="pl-kos">;</span></pre></div> <p dir="auto">wherein the inner package would not be allowed to <code class="notranslate">import 'fs'</code> without the place where it's imported having explicitly defined this behavior. The issue here is a lack of flexibility (such as a lower ability to mock-in-place).</p> <p dir="auto">In an ideal world (and I do actually think this would be the best solution possible), deno would disallow <code class="notranslate">import</code>ing system libraries from inside modules and allow grand overrides of inner module dependencies, with additional configuration allowed at runtime. This would enable the following usecases, almost all of which are more ergonomic if it's allowed at runtime:</p> <ul dir="auto"> <li>Allowing inner modules to easily and ergonomically offer custom replacements <ul dir="auto"> <li>Bluebird instead of native promises, for example</li> </ul> </li> <li>Mocking during testing (think Jest, but available all the time as a first-class citizen)</li> <li>Initialization parameters (no need to separately call <code class="notranslate">mod.initialize({ /* ... */ })</code>)</li> </ul> <hr> <p dir="auto">Very curious to hear what everyone's thoughts are.</p>
1
<p dir="auto">Hello,</p> <p dir="auto"><code class="notranslate">interpolate</code> doesn't work with <code class="notranslate">NaT</code><br> see <a href="http://stackoverflow.com/questions/33921795/fill-timestamp-nat-with-a-linear-interpolation/33922824#33922824" rel="nofollow">http://stackoverflow.com/questions/33921795/fill-timestamp-nat-with-a-linear-interpolation/33922824#33922824</a></p> <p dir="auto">Here is a trivial example to show the situation:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="s = pd.Series(pd.date_range('2015-01-01' , '2015-01-30'), name='t') s[3], s[4], s[5] = pd.NaT, pd.NaT, pd.NaT s[13], s[14], s[15] = pd.NaT, pd.NaT, pd.NaT print(s) 0 2015-01-01 1 2015-01-02 2 2015-01-03 3 NaT 4 NaT 5 NaT 6 2015-01-07 7 2015-01-08 8 2015-01-09 9 2015-01-10 10 2015-01-11 11 2015-01-12 12 2015-01-13 13 NaT 14 NaT 15 NaT 16 2015-01-17 17 2015-01-18 18 2015-01-19 19 2015-01-20 20 2015-01-21 21 2015-01-22 22 2015-01-23 23 2015-01-24 24 2015-01-25 25 2015-01-26 26 2015-01-27 27 2015-01-28 28 2015-01-29 29 2015-01-30 Name: t, dtype: datetime64[ns] print(s.interpolate()) 0 2015-01-01 1 2015-01-02 2 2015-01-03 3 NaT 4 NaT 5 NaT 6 2015-01-07 7 2015-01-08 8 2015-01-09 9 2015-01-10 10 2015-01-11 11 2015-01-12 12 2015-01-13 13 NaT 14 NaT 15 NaT 16 2015-01-17 17 2015-01-18 18 2015-01-19 19 2015-01-20 20 2015-01-21 21 2015-01-22 22 2015-01-23 23 2015-01-24 24 2015-01-25 25 2015-01-26 26 2015-01-27 27 2015-01-28 28 2015-01-29 29 2015-01-30 Name: t, dtype: datetime64[ns] assert s.interpolate().isnull().sum() == 0 --------------------------------------------------------------------------- AssertionError Traceback (most recent call last) &lt;ipython-input-150-8a59e397a174&gt; in &lt;module&gt;() ----&gt; 1 assert s.interpolate().isnull().sum() == 0 AssertionError:"><pre class="notranslate"><code class="notranslate">s = pd.Series(pd.date_range('2015-01-01' , '2015-01-30'), name='t') s[3], s[4], s[5] = pd.NaT, pd.NaT, pd.NaT s[13], s[14], s[15] = pd.NaT, pd.NaT, pd.NaT print(s) 0 2015-01-01 1 2015-01-02 2 2015-01-03 3 NaT 4 NaT 5 NaT 6 2015-01-07 7 2015-01-08 8 2015-01-09 9 2015-01-10 10 2015-01-11 11 2015-01-12 12 2015-01-13 13 NaT 14 NaT 15 NaT 16 2015-01-17 17 2015-01-18 18 2015-01-19 19 2015-01-20 20 2015-01-21 21 2015-01-22 22 2015-01-23 23 2015-01-24 24 2015-01-25 25 2015-01-26 26 2015-01-27 27 2015-01-28 28 2015-01-29 29 2015-01-30 Name: t, dtype: datetime64[ns] print(s.interpolate()) 0 2015-01-01 1 2015-01-02 2 2015-01-03 3 NaT 4 NaT 5 NaT 6 2015-01-07 7 2015-01-08 8 2015-01-09 9 2015-01-10 10 2015-01-11 11 2015-01-12 12 2015-01-13 13 NaT 14 NaT 15 NaT 16 2015-01-17 17 2015-01-18 18 2015-01-19 19 2015-01-20 20 2015-01-21 21 2015-01-22 22 2015-01-23 23 2015-01-24 24 2015-01-25 25 2015-01-26 26 2015-01-27 27 2015-01-28 28 2015-01-29 29 2015-01-30 Name: t, dtype: datetime64[ns] assert s.interpolate().isnull().sum() == 0 --------------------------------------------------------------------------- AssertionError Traceback (most recent call last) &lt;ipython-input-150-8a59e397a174&gt; in &lt;module&gt;() ----&gt; 1 assert s.interpolate().isnull().sum() == 0 AssertionError: </code></pre></div> <p dir="auto">Kind regards</p>
<p dir="auto">I didn't directly found an open issue about it, but is there a reason we do not implement interpolation of datetime <em>values</em> (so not in the index)?</p> <p dir="auto">Example:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="In [14]: s = pd.Series(pd.date_range('2012-01-01', periods=5)) In [16]: s[2] = np.nan In [17]: s Out[17]: 0 2012-01-01 1 2012-01-02 2 NaT 3 2012-01-04 4 2012-01-05 dtype: datetime64[ns] In [18]: s.interpolate() Out[18]: 0 2012-01-01 1 2012-01-02 2 NaT 3 2012-01-04 4 2012-01-05 dtype: datetime64[ns]"><pre class="notranslate"><code class="notranslate">In [14]: s = pd.Series(pd.date_range('2012-01-01', periods=5)) In [16]: s[2] = np.nan In [17]: s Out[17]: 0 2012-01-01 1 2012-01-02 2 NaT 3 2012-01-04 4 2012-01-05 dtype: datetime64[ns] In [18]: s.interpolate() Out[18]: 0 2012-01-01 1 2012-01-02 2 NaT 3 2012-01-04 4 2012-01-05 dtype: datetime64[ns] </code></pre></div> <p dir="auto">A crude manual work around:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="In [20]: s2 = pd.Series(s.values.astype('int64')) In [21]: s2[s2&lt;0] = np.nan In [22]: s2 Out[22]: 0 1.325376e+18 1 1.325462e+18 2 NaN 3 1.325635e+18 4 1.325722e+18 dtype: float64 In [23]: pd.to_datetime(s2.interpolate(), unit='ns') Out[23]: 0 2012-01-01 1 2012-01-02 2 2012-01-03 3 2012-01-04 4 2012-01-05 dtype: datetime64[ns]"><pre class="notranslate"><code class="notranslate">In [20]: s2 = pd.Series(s.values.astype('int64')) In [21]: s2[s2&lt;0] = np.nan In [22]: s2 Out[22]: 0 1.325376e+18 1 1.325462e+18 2 NaN 3 1.325635e+18 4 1.325722e+18 dtype: float64 In [23]: pd.to_datetime(s2.interpolate(), unit='ns') Out[23]: 0 2012-01-01 1 2012-01-02 2 2012-01-03 3 2012-01-04 4 2012-01-05 dtype: datetime64[ns] </code></pre></div>
1
<p dir="auto">Not work shell with grep pipline:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="- shell: find /TEST/PATH -name requirements.txt -exec cat {} \; | grep -o '^[^#]*' - shell: &quot;find /TEST/PATH -name requirements.txt -exec cat {} \\; | grep -o '^[^#]*'&quot; - shell: find /TEST/PATH -name requirements.txt -exec cat {} \; | grep test - shell: &quot;find /TEST/PATH -name requirements.txt -exec cat {} \\; | grep test&quot; - shell: find /TEST/PATH -name requirements.txt -print0 | xargs -0 cat | grep -o '^[^#]*' - shell: &quot;find /TEST/PATH -name requirements.txt -print0 | xargs -0 cat | grep -o '^[^#]*'&quot; - shell: find /TEST/PATH -name requirements.txt -print0 | xargs -0 cat | grep test - shell: &quot;find /TEST/PATH -name requirements.txt -print0 | xargs -0 cat | grep test&quot;"><pre class="notranslate"><code class="notranslate">- shell: find /TEST/PATH -name requirements.txt -exec cat {} \; | grep -o '^[^#]*' - shell: "find /TEST/PATH -name requirements.txt -exec cat {} \\; | grep -o '^[^#]*'" - shell: find /TEST/PATH -name requirements.txt -exec cat {} \; | grep test - shell: "find /TEST/PATH -name requirements.txt -exec cat {} \\; | grep test" - shell: find /TEST/PATH -name requirements.txt -print0 | xargs -0 cat | grep -o '^[^#]*' - shell: "find /TEST/PATH -name requirements.txt -print0 | xargs -0 cat | grep -o '^[^#]*'" - shell: find /TEST/PATH -name requirements.txt -print0 | xargs -0 cat | grep test - shell: "find /TEST/PATH -name requirements.txt -print0 | xargs -0 cat | grep test" </code></pre></div> <p dir="auto">with next message:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="failed: [test-instance] =&gt; {&quot;changed&quot;: true, &quot;cmd&quot;: &quot;find /TEST/PATH -name requirements.txt -exec cat {} \\; | grep -o '^[^#]*'&quot;, &quot;delta&quot;: &quot;0:00:00.003797&quot;, &quot;end&quot;: &quot;2015-06-03 21:40:57.502797&quot;, &quot;rc&quot;: 1, &quot;start&quot;: &quot;2015-06-03 21:40:57.499000&quot;, &quot;warnings&quot;: []} FATAL: all hosts have already failed -- aborting"><pre class="notranslate"><code class="notranslate">failed: [test-instance] =&gt; {"changed": true, "cmd": "find /TEST/PATH -name requirements.txt -exec cat {} \\; | grep -o '^[^#]*'", "delta": "0:00:00.003797", "end": "2015-06-03 21:40:57.502797", "rc": 1, "start": "2015-06-03 21:40:57.499000", "warnings": []} FATAL: all hosts have already failed -- aborting </code></pre></div> <p dir="auto">When I replace <code class="notranslate">grep something</code> for example to <code class="notranslate">tail</code> all work, this commands also work fine on shell on instance for bash and sh, also this work for python <code class="notranslate">subprocess.Popen</code> with shell=True.</p>
<h5 dir="auto">ISSUE TYPE</h5> <ul dir="auto"> <li>Bug Report</li> </ul> <h5 dir="auto">COMPONENT NAME</h5> <p dir="auto">SSH connection</p> <h5 dir="auto">ANSIBLE VERSION</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ansible 2.2.0 (devel eb33ed4219) last updated 2016/09/27 11:16:30 (GMT +200) lib/ansible/modules/core: (detached HEAD c03697c81e) last updated 2016/09/27 11:17:10 (GMT +200) lib/ansible/modules/extras: (detached HEAD 119bc466be) last updated 2016/09/27 11:17:58 (GMT +200) config file = configured module search path = Default w/o overrides"><pre class="notranslate"><code class="notranslate">ansible 2.2.0 (devel eb33ed4219) last updated 2016/09/27 11:16:30 (GMT +200) lib/ansible/modules/core: (detached HEAD c03697c81e) last updated 2016/09/27 11:17:10 (GMT +200) lib/ansible/modules/extras: (detached HEAD 119bc466be) last updated 2016/09/27 11:17:58 (GMT +200) config file = configured module search path = Default w/o overrides </code></pre></div> <h5 dir="auto">CONFIGURATION</h5> <p dir="auto">N/A</p> <h5 dir="auto">OS / ENVIRONMENT</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Linux localhost 3.8.11 #1 SMP Mon Sep 12 21:56:54 PDT 2016 x86_64 x86_64 x86_64 GNU/Linux Python 2.7.11 OpenSSH_6.6.1p1 Ubuntu-2ubuntu2.6, OpenSSL 1.0.1f 6 Jan 2014"><pre class="notranslate"><code class="notranslate">Linux localhost 3.8.11 #1 SMP Mon Sep 12 21:56:54 PDT 2016 x86_64 x86_64 x86_64 GNU/Linux Python 2.7.11 OpenSSH_6.6.1p1 Ubuntu-2ubuntu2.6, OpenSSL 1.0.1f 6 Jan 2014 </code></pre></div> <p dir="auto">~/ansible$ pip list<br> ansible (2.2.0)<br> apache-libcloud (0.20.1)<br> aws (0.2.5)<br> awscli (1.10.61)<br> backports.ssl-match-hostname (3.5.0.1)<br> boto (2.40.0)<br> boto3 (1.1.3)<br> botocore (1.4.51)<br> certifi (2015.11.20.1)<br> cffi (1.7.0)<br> colorama (0.3.7)<br> Cython (0.20.1.post0)<br> docutils (0.12)<br> ecdsa (0.13)<br> enum34 (1.1.6)<br> Fabric (1.11.1)<br> futures (3.0.5)<br> google-api-python-client (1.1)<br> httplib2 (0.8)<br> idna (2.1)<br> ipaddress (1.0.16)<br> Jinja2 (2.8)<br> jmespath (0.9.0)<br> jsonpatch (1.13)<br> jsonpointer (1.10)<br> jwt (0.3.2)<br> lxml (3.3.3)<br> MarkupSafe (0.23)<br> numpy (1.8.2)<br> paramiko (1.17.0)<br> pip (8.1.2)<br> ply (3.4)<br> prettytable (0.7.2)<br> pyasn1 (0.1.9)<br> pycparser (2.14)<br> pycrypto (2.6.1)<br> pygpgme (0.3)<br> pyOpenSSL (0.13)<br> python-apt (0.9.3.5ubuntu2)<br> python-dateutil (2.5.3)<br> python-gflags (3.0.4)<br> python-nghttp2 (1.3.5.dev0)<br> PyYAML (3.11)<br> rsa (3.4.2)<br> s3transfer (0.1.3)<br> setuptools (23.0.0)<br> simplejson (3.3.1)<br> six (1.10.0)<br> tabulate (0.7.5)<br> urllib3 (1.14)<br> virtualenv (1.11.4)</p> <h5 dir="auto">SUMMARY</h5> <p dir="auto">Using a repo installed version of Ansible, 2.1.1 all works fine.</p> <p dir="auto">When I remove that version and then clone the devel branch, ansible-playbook fails to connect to hosts while running ansible -m setup consistently works and gets facts from the host.</p> <h5 dir="auto">STEPS TO REPRODUCE</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ansible mng -m setup -a 'gather_subset=!all' -vvvvvv Using /home/fvant/ansible-local/ansible.cfg as config file Loading callback plugin minimal of type stdout, v2.0 from /home/fvant/ansible/lib/ansible/plugins/callback/__init__.pyc Using module file /home/fvant/ansible/lib/ansible/modules/core/system/setup.py &lt;10.0.91.104&gt; ESTABLISH SSH CONNECTION FOR USER: root &lt;10.0.91.104&gt; SSH: ansible.cfg set ssh_args: (-C)(-o)(ControlMaster=auto)(-o)(ControlPersist=60s) &lt;10.0.91.104&gt; SSH: ANSIBLE_HOST_KEY_CHECKING/host_key_checking disabled: (-o)(StrictHostKeyChecking=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_PRIVATE_KEY_FILE/private_key_file/ansible_ssh_private_key_file set: (-o)(IdentityFile=&quot;./vars/keys/ansible_id_rsa&quot;) &lt;10.0.91.104&gt; SSH: ansible_password/ansible_ssh_pass not set: (-o)(KbdInteractiveAuthentication=no)(-o)(PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey)(-o)(PasswordAuthentication=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_REMOTE_USER/remote_user/ansible_user/user/-u set: (-o)(User=root) &lt;10.0.91.104&gt; SSH: ANSIBLE_TIMEOUT/timeout set: (-o)(ConnectTimeout=5) &lt;10.0.91.104&gt; SSH: PlayContext set ssh_common_args: () &lt;10.0.91.104&gt; SSH: PlayContext set ssh_extra_args: () &lt;10.0.91.104&gt; SSH: found only ControlPersist; added ControlPath: (-o)(ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r) &lt;10.0.91.104&gt; SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o 'IdentityFile=&quot;./vars/keys/ansible_id_rsa&quot;' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=5 -o ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r 10.0.91.104 '/bin/sh -c '&quot;'&quot;'( umask 77 &amp;&amp; mkdir -p &quot;` echo /tmp/ansible-tmp-1474979078.18-42020272005162 `&quot; &amp;&amp; echo ansible-tmp-1474979078.18-42020272005162=&quot;` echo /tmp/ansible-tmp-1474979078.18-42020272005162 `&quot; ) &amp;&amp; sleep 0'&quot;'&quot;'' &lt;10.0.91.104&gt; PUT /tmp/tmpUCSQuH TO /tmp/ansible-tmp-1474979078.18-42020272005162/setup.py &lt;10.0.91.104&gt; SSH: ansible.cfg set ssh_args: (-C)(-o)(ControlMaster=auto)(-o)(ControlPersist=60s) &lt;10.0.91.104&gt; SSH: ANSIBLE_HOST_KEY_CHECKING/host_key_checking disabled: (-o)(StrictHostKeyChecking=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_PRIVATE_KEY_FILE/private_key_file/ansible_ssh_private_key_file set: (-o)(IdentityFile=&quot;./vars/keys/ansible_id_rsa&quot;) &lt;10.0.91.104&gt; SSH: ansible_password/ansible_ssh_pass not set: (-o)(KbdInteractiveAuthentication=no)(-o)(PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey)(-o)(PasswordAuthentication=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_REMOTE_USER/remote_user/ansible_user/user/-u set: (-o)(User=root) &lt;10.0.91.104&gt; SSH: ANSIBLE_TIMEOUT/timeout set: (-o)(ConnectTimeout=5) &lt;10.0.91.104&gt; SSH: PlayContext set ssh_common_args: () &lt;10.0.91.104&gt; SSH: PlayContext set sftp_extra_args: () &lt;10.0.91.104&gt; SSH: found only ControlPersist; added ControlPath: (-o)(ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r) &lt;10.0.91.104&gt; SSH: EXEC sftp -b - -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o 'IdentityFile=&quot;./vars/keys/ansible_id_rsa&quot;' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=5 -o ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r '[10.0.91.104]' &lt;10.0.91.104&gt; ESTABLISH SSH CONNECTION FOR USER: root &lt;10.0.91.104&gt; SSH: ansible.cfg set ssh_args: (-C)(-o)(ControlMaster=auto)(-o)(ControlPersist=60s) &lt;10.0.91.104&gt; SSH: ANSIBLE_HOST_KEY_CHECKING/host_key_checking disabled: (-o)(StrictHostKeyChecking=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_PRIVATE_KEY_FILE/private_key_file/ansible_ssh_private_key_file set: (-o)(IdentityFile=&quot;./vars/keys/ansible_id_rsa&quot;) &lt;10.0.91.104&gt; SSH: ansible_password/ansible_ssh_pass not set: (-o)(KbdInteractiveAuthentication=no)(-o)(PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey)(-o)(PasswordAuthentication=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_REMOTE_USER/remote_user/ansible_user/user/-u set: (-o)(User=root) &lt;10.0.91.104&gt; SSH: ANSIBLE_TIMEOUT/timeout set: (-o)(ConnectTimeout=5) &lt;10.0.91.104&gt; SSH: PlayContext set ssh_common_args: () &lt;10.0.91.104&gt; SSH: PlayContext set ssh_extra_args: () &lt;10.0.91.104&gt; SSH: found only ControlPersist; added ControlPath: (-o)(ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r) &lt;10.0.91.104&gt; SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o 'IdentityFile=&quot;./vars/keys/ansible_id_rsa&quot;' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=5 -o ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r 10.0.91.104 '/bin/sh -c '&quot;'&quot;'chmod u+x /tmp/ansible-tmp-1474979078.18-42020272005162/ /tmp/ansible-tmp-1474979078.18-42020272005162/setup.py &amp;&amp; sleep 0'&quot;'&quot;'' &lt;10.0.91.104&gt; ESTABLISH SSH CONNECTION FOR USER: root &lt;10.0.91.104&gt; SSH: ansible.cfg set ssh_args: (-C)(-o)(ControlMaster=auto)(-o)(ControlPersist=60s) &lt;10.0.91.104&gt; SSH: ANSIBLE_HOST_KEY_CHECKING/host_key_checking disabled: (-o)(StrictHostKeyChecking=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_PRIVATE_KEY_FILE/private_key_file/ansible_ssh_private_key_file set: (-o)(IdentityFile=&quot;./vars/keys/ansible_id_rsa&quot;) &lt;10.0.91.104&gt; SSH: ansible_password/ansible_ssh_pass not set: (-o)(KbdInteractiveAuthentication=no)(-o)(PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey)(-o)(PasswordAuthentication=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_REMOTE_USER/remote_user/ansible_user/user/-u set: (-o)(User=root) &lt;10.0.91.104&gt; SSH: ANSIBLE_TIMEOUT/timeout set: (-o)(ConnectTimeout=5) &lt;10.0.91.104&gt; SSH: PlayContext set ssh_common_args: () &lt;10.0.91.104&gt; SSH: PlayContext set ssh_extra_args: () &lt;10.0.91.104&gt; SSH: found only ControlPersist; added ControlPath: (-o)(ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r) &lt;10.0.91.104&gt; SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o 'IdentityFile=&quot;./vars/keys/ansible_id_rsa&quot;' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=5 -o ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r -tt 10.0.91.104 '/bin/sh -c '&quot;'&quot;'/usr/bin/python /tmp/ansible-tmp-1474979078.18-42020272005162/setup.py; rm -rf &quot;/tmp/ansible-tmp-1474979078.18-42020272005162/&quot; &gt; /dev/null 2&gt;&amp;1 &amp;&amp; sleep 0'&quot;'&quot;'' mng-a-sandbox01 | SUCCESS =&gt; { &quot;ansible_facts&quot;: { &quot;ansible_architecture&quot;: &quot;x86_64&quot;, &quot;ansible_cmdline&quot;: { &quot;BOOT_IMAGE&quot;: &quot;/boot/vmlinuz-3.10.0-327.10.1.el7.x86_64&quot;, &quot;LANG&quot;: &quot;en_US.UTF-8&quot;, &quot;console&quot;: &quot;ttyS0,115200&quot;, &quot;crashkernel&quot;: &quot;auto&quot;, &quot;ro&quot;: true, &quot;root&quot;: &quot;UUID=ef6ba050-6cdc-416a-9380-c14304d0d206&quot; }, &lt;/snip&gt;"><pre class="notranslate"><code class="notranslate">ansible mng -m setup -a 'gather_subset=!all' -vvvvvv Using /home/fvant/ansible-local/ansible.cfg as config file Loading callback plugin minimal of type stdout, v2.0 from /home/fvant/ansible/lib/ansible/plugins/callback/__init__.pyc Using module file /home/fvant/ansible/lib/ansible/modules/core/system/setup.py &lt;10.0.91.104&gt; ESTABLISH SSH CONNECTION FOR USER: root &lt;10.0.91.104&gt; SSH: ansible.cfg set ssh_args: (-C)(-o)(ControlMaster=auto)(-o)(ControlPersist=60s) &lt;10.0.91.104&gt; SSH: ANSIBLE_HOST_KEY_CHECKING/host_key_checking disabled: (-o)(StrictHostKeyChecking=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_PRIVATE_KEY_FILE/private_key_file/ansible_ssh_private_key_file set: (-o)(IdentityFile="./vars/keys/ansible_id_rsa") &lt;10.0.91.104&gt; SSH: ansible_password/ansible_ssh_pass not set: (-o)(KbdInteractiveAuthentication=no)(-o)(PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey)(-o)(PasswordAuthentication=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_REMOTE_USER/remote_user/ansible_user/user/-u set: (-o)(User=root) &lt;10.0.91.104&gt; SSH: ANSIBLE_TIMEOUT/timeout set: (-o)(ConnectTimeout=5) &lt;10.0.91.104&gt; SSH: PlayContext set ssh_common_args: () &lt;10.0.91.104&gt; SSH: PlayContext set ssh_extra_args: () &lt;10.0.91.104&gt; SSH: found only ControlPersist; added ControlPath: (-o)(ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r) &lt;10.0.91.104&gt; SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o 'IdentityFile="./vars/keys/ansible_id_rsa"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=5 -o ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r 10.0.91.104 '/bin/sh -c '"'"'( umask 77 &amp;&amp; mkdir -p "` echo /tmp/ansible-tmp-1474979078.18-42020272005162 `" &amp;&amp; echo ansible-tmp-1474979078.18-42020272005162="` echo /tmp/ansible-tmp-1474979078.18-42020272005162 `" ) &amp;&amp; sleep 0'"'"'' &lt;10.0.91.104&gt; PUT /tmp/tmpUCSQuH TO /tmp/ansible-tmp-1474979078.18-42020272005162/setup.py &lt;10.0.91.104&gt; SSH: ansible.cfg set ssh_args: (-C)(-o)(ControlMaster=auto)(-o)(ControlPersist=60s) &lt;10.0.91.104&gt; SSH: ANSIBLE_HOST_KEY_CHECKING/host_key_checking disabled: (-o)(StrictHostKeyChecking=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_PRIVATE_KEY_FILE/private_key_file/ansible_ssh_private_key_file set: (-o)(IdentityFile="./vars/keys/ansible_id_rsa") &lt;10.0.91.104&gt; SSH: ansible_password/ansible_ssh_pass not set: (-o)(KbdInteractiveAuthentication=no)(-o)(PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey)(-o)(PasswordAuthentication=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_REMOTE_USER/remote_user/ansible_user/user/-u set: (-o)(User=root) &lt;10.0.91.104&gt; SSH: ANSIBLE_TIMEOUT/timeout set: (-o)(ConnectTimeout=5) &lt;10.0.91.104&gt; SSH: PlayContext set ssh_common_args: () &lt;10.0.91.104&gt; SSH: PlayContext set sftp_extra_args: () &lt;10.0.91.104&gt; SSH: found only ControlPersist; added ControlPath: (-o)(ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r) &lt;10.0.91.104&gt; SSH: EXEC sftp -b - -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o 'IdentityFile="./vars/keys/ansible_id_rsa"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=5 -o ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r '[10.0.91.104]' &lt;10.0.91.104&gt; ESTABLISH SSH CONNECTION FOR USER: root &lt;10.0.91.104&gt; SSH: ansible.cfg set ssh_args: (-C)(-o)(ControlMaster=auto)(-o)(ControlPersist=60s) &lt;10.0.91.104&gt; SSH: ANSIBLE_HOST_KEY_CHECKING/host_key_checking disabled: (-o)(StrictHostKeyChecking=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_PRIVATE_KEY_FILE/private_key_file/ansible_ssh_private_key_file set: (-o)(IdentityFile="./vars/keys/ansible_id_rsa") &lt;10.0.91.104&gt; SSH: ansible_password/ansible_ssh_pass not set: (-o)(KbdInteractiveAuthentication=no)(-o)(PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey)(-o)(PasswordAuthentication=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_REMOTE_USER/remote_user/ansible_user/user/-u set: (-o)(User=root) &lt;10.0.91.104&gt; SSH: ANSIBLE_TIMEOUT/timeout set: (-o)(ConnectTimeout=5) &lt;10.0.91.104&gt; SSH: PlayContext set ssh_common_args: () &lt;10.0.91.104&gt; SSH: PlayContext set ssh_extra_args: () &lt;10.0.91.104&gt; SSH: found only ControlPersist; added ControlPath: (-o)(ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r) &lt;10.0.91.104&gt; SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o 'IdentityFile="./vars/keys/ansible_id_rsa"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=5 -o ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r 10.0.91.104 '/bin/sh -c '"'"'chmod u+x /tmp/ansible-tmp-1474979078.18-42020272005162/ /tmp/ansible-tmp-1474979078.18-42020272005162/setup.py &amp;&amp; sleep 0'"'"'' &lt;10.0.91.104&gt; ESTABLISH SSH CONNECTION FOR USER: root &lt;10.0.91.104&gt; SSH: ansible.cfg set ssh_args: (-C)(-o)(ControlMaster=auto)(-o)(ControlPersist=60s) &lt;10.0.91.104&gt; SSH: ANSIBLE_HOST_KEY_CHECKING/host_key_checking disabled: (-o)(StrictHostKeyChecking=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_PRIVATE_KEY_FILE/private_key_file/ansible_ssh_private_key_file set: (-o)(IdentityFile="./vars/keys/ansible_id_rsa") &lt;10.0.91.104&gt; SSH: ansible_password/ansible_ssh_pass not set: (-o)(KbdInteractiveAuthentication=no)(-o)(PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey)(-o)(PasswordAuthentication=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_REMOTE_USER/remote_user/ansible_user/user/-u set: (-o)(User=root) &lt;10.0.91.104&gt; SSH: ANSIBLE_TIMEOUT/timeout set: (-o)(ConnectTimeout=5) &lt;10.0.91.104&gt; SSH: PlayContext set ssh_common_args: () &lt;10.0.91.104&gt; SSH: PlayContext set ssh_extra_args: () &lt;10.0.91.104&gt; SSH: found only ControlPersist; added ControlPath: (-o)(ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r) &lt;10.0.91.104&gt; SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o 'IdentityFile="./vars/keys/ansible_id_rsa"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=5 -o ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r -tt 10.0.91.104 '/bin/sh -c '"'"'/usr/bin/python /tmp/ansible-tmp-1474979078.18-42020272005162/setup.py; rm -rf "/tmp/ansible-tmp-1474979078.18-42020272005162/" &gt; /dev/null 2&gt;&amp;1 &amp;&amp; sleep 0'"'"'' mng-a-sandbox01 | SUCCESS =&gt; { "ansible_facts": { "ansible_architecture": "x86_64", "ansible_cmdline": { "BOOT_IMAGE": "/boot/vmlinuz-3.10.0-327.10.1.el7.x86_64", "LANG": "en_US.UTF-8", "console": "ttyS0,115200", "crashkernel": "auto", "ro": true, "root": "UUID=ef6ba050-6cdc-416a-9380-c14304d0d206" }, &lt;/snip&gt; </code></pre></div> <h5 dir="auto">EXPECTED RESULTS</h5> <h5 dir="auto">ACTUAL RESULTS</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ansible-playbook playbooks/main.yml -e env=mng --ask-vault-pass -e account=playground -vvvvvvvvv Loading callback plugin default of type stdout, v2.0 from /home/fvant/ansible/lib/ansible/plugins/callback/__init__.pyc Loading callback plugin profile_tasks of type aggregate, v2.0 from /home/fvant/ansible/lib/ansible/plugins/callback/__init__.pyc PLAYBOOK: main.yml ************************************************************* 11 plays in playbooks/main.yml PLAY [mng] ********************************************************************* TASK [setup] ******************************************************************* Tuesday 27 September 2016 14:19:31 +0200 (0:00:00.177) 0:00:01.441 ***** Using module file /home/fvant/ansible/lib/ansible/modules/core/system/setup.py &lt;10.0.91.104&gt; ESTABLISH SSH CONNECTION FOR USER: root &lt;10.0.91.104&gt; SSH: ansible.cfg set ssh_args: (-C)(-o)(ControlMaster=auto)(-o)(ControlPersist=60s) &lt;10.0.91.104&gt; SSH: ANSIBLE_HOST_KEY_CHECKING/host_key_checking disabled: (-o)(StrictHostKeyChecking=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_PRIVATE_KEY_FILE/private_key_file/ansible_ssh_private_key_file set: (-o)(IdentityFile=&quot;./vars/keys/ansible_id_rsa&quot;) &lt;10.0.91.104&gt; SSH: ansible_password/ansible_ssh_pass not set: (-o)(KbdInteractiveAuthentication=no)(-o)(PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey)(-o)(PasswordAuthentication=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_REMOTE_USER/remote_user/ansible_user/user/-u set: (-o)(User=root) &lt;10.0.91.104&gt; SSH: ANSIBLE_TIMEOUT/timeout set: (-o)(ConnectTimeout=5) &lt;10.0.91.104&gt; SSH: PlayContext set ssh_common_args: () &lt;10.0.91.104&gt; SSH: PlayContext set ssh_extra_args: () &lt;10.0.91.104&gt; SSH: found only ControlPersist; added ControlPath: (-o)(ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r) &lt;10.0.91.104&gt; SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o 'IdentityFile=&quot;./vars/keys/ansible_id_rsa&quot;' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=5 -o ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r 10.0.91.104 '/bin/sh -c '&quot;'&quot;'( umask 77 &amp;&amp; mkdir -p &quot;` echo /tmp/ansible-tmp-1474978771.34-100536752987114 `&quot; &amp;&amp; echo ansible-tmp-1474978771.34-100536752987114=&quot;` echo /tmp/ansible-tmp-1474978771.34-100536752987114 `&quot; ) &amp;&amp; sleep 0'&quot;'&quot;'' fatal: [mng-a-sandbox01]: UNREACHABLE! =&gt; { &quot;changed&quot;: false, &quot;msg&quot;: &quot;Failed to connect to the host via ssh.&quot;, &quot;unreachable&quot;: true }"><pre class="notranslate"><code class="notranslate">ansible-playbook playbooks/main.yml -e env=mng --ask-vault-pass -e account=playground -vvvvvvvvv Loading callback plugin default of type stdout, v2.0 from /home/fvant/ansible/lib/ansible/plugins/callback/__init__.pyc Loading callback plugin profile_tasks of type aggregate, v2.0 from /home/fvant/ansible/lib/ansible/plugins/callback/__init__.pyc PLAYBOOK: main.yml ************************************************************* 11 plays in playbooks/main.yml PLAY [mng] ********************************************************************* TASK [setup] ******************************************************************* Tuesday 27 September 2016 14:19:31 +0200 (0:00:00.177) 0:00:01.441 ***** Using module file /home/fvant/ansible/lib/ansible/modules/core/system/setup.py &lt;10.0.91.104&gt; ESTABLISH SSH CONNECTION FOR USER: root &lt;10.0.91.104&gt; SSH: ansible.cfg set ssh_args: (-C)(-o)(ControlMaster=auto)(-o)(ControlPersist=60s) &lt;10.0.91.104&gt; SSH: ANSIBLE_HOST_KEY_CHECKING/host_key_checking disabled: (-o)(StrictHostKeyChecking=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_PRIVATE_KEY_FILE/private_key_file/ansible_ssh_private_key_file set: (-o)(IdentityFile="./vars/keys/ansible_id_rsa") &lt;10.0.91.104&gt; SSH: ansible_password/ansible_ssh_pass not set: (-o)(KbdInteractiveAuthentication=no)(-o)(PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey)(-o)(PasswordAuthentication=no) &lt;10.0.91.104&gt; SSH: ANSIBLE_REMOTE_USER/remote_user/ansible_user/user/-u set: (-o)(User=root) &lt;10.0.91.104&gt; SSH: ANSIBLE_TIMEOUT/timeout set: (-o)(ConnectTimeout=5) &lt;10.0.91.104&gt; SSH: PlayContext set ssh_common_args: () &lt;10.0.91.104&gt; SSH: PlayContext set ssh_extra_args: () &lt;10.0.91.104&gt; SSH: found only ControlPersist; added ControlPath: (-o)(ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r) &lt;10.0.91.104&gt; SSH: EXEC ssh -vvv -C -o ControlMaster=auto -o ControlPersist=60s -o StrictHostKeyChecking=no -o 'IdentityFile="./vars/keys/ansible_id_rsa"' -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o User=root -o ConnectTimeout=5 -o ControlPath=/home/fvant/.ansible/cp/ansible-ssh-%h-%p-%r 10.0.91.104 '/bin/sh -c '"'"'( umask 77 &amp;&amp; mkdir -p "` echo /tmp/ansible-tmp-1474978771.34-100536752987114 `" &amp;&amp; echo ansible-tmp-1474978771.34-100536752987114="` echo /tmp/ansible-tmp-1474978771.34-100536752987114 `" ) &amp;&amp; sleep 0'"'"'' fatal: [mng-a-sandbox01]: UNREACHABLE! =&gt; { "changed": false, "msg": "Failed to connect to the host via ssh.", "unreachable": true } </code></pre></div>
0
<p dir="auto">When I try to run <code class="notranslate">python example/regressions.py</code> it throws this error</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Traceback (most recent call last): File &quot;examples/regressions.py&quot;, line 12, in &lt;module&gt; dateRange = DatetimeIndex(start, periods=N) File &quot;/Users/vyomkesh/code/pandas/pandas/util/decorators.py&quot;, line 88, in wrapper return func(*args, **kwargs) File &quot;/Users/vyomkesh/code/pandas/pandas/tseries/index.py&quot;, line 240, in __new__ data = list(data) TypeError: 'datetime.datetime' object is not iterable"><pre class="notranslate"><code class="notranslate">Traceback (most recent call last): File "examples/regressions.py", line 12, in &lt;module&gt; dateRange = DatetimeIndex(start, periods=N) File "/Users/vyomkesh/code/pandas/pandas/util/decorators.py", line 88, in wrapper return func(*args, **kwargs) File "/Users/vyomkesh/code/pandas/pandas/tseries/index.py", line 240, in __new__ data = list(data) TypeError: 'datetime.datetime' object is not iterable </code></pre></div>
<p dir="auto"><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="217953096" data-permission-text="Title is private" data-url="https://github.com/pandas-dev/pandas/issues/15838" data-hovercard-type="pull_request" data-hovercard-url="/pandas-dev/pandas/pull/15838/hovercard?comment_id=109296615&amp;comment_type=review_comment" href="https://github.com/pandas-dev/pandas/pull/15838#discussion_r109296615">#15838 (comment)</a></p> <p dir="auto">we have fairly uniform IO routines of the form</p> <p dir="auto"><code class="notranslate">.to_format(path, df, **kwargs)</code> (takes DataFrame)<br> and<br> <code class="notranslate">pd.read_format(path, **kwargs)</code> (returns DataFrame)</p> <p dir="auto">so should document various aspects of this:</p> <ul dir="auto"> <li>contract on input path strings</li> <li>file-like objects &amp; <code class="notranslate">is_file_like</code> (<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="219391145" data-permission-text="Title is private" data-url="https://github.com/pandas-dev/pandas/issues/15894" data-hovercard-type="pull_request" data-hovercard-url="/pandas-dev/pandas/pull/15894/hovercard" href="https://github.com/pandas-dev/pandas/pull/15894">#15894</a>)</li> <li>do we do any encoding / compression (only on csv/json ATM), compression</li> <li>various guarantees on what we are sending in (e.g. no Index, string columns which are non-duplicated), no non-string objects (see feather/parquet impl).</li> <li>make these more pluggable</li> <li>perhaps allow a specification for block access / chunking.</li> <li>additional args to accept/use: <code class="notranslate">mode</code> (for writing)</li> </ul>
0
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/mui-org/material-ui/issues">issues</a> of this repository and believe that this is not a duplicate.</li> </ul> <h2 dir="auto">Expected Behavior</h2> <p dir="auto">After resizing my window tooltips should be repositioned correctly to avoid unnecessary scrollbars.</p> <h2 dir="auto">Current Behavior</h2> <p dir="auto">When i resize a window to a certain point which has a tooltip at the edge then the tooltip is wrongly positioned after the resize which results in unnecessary scrollbars. After moving the mouse over the button which creates the tooltip a few times it gets into the correct position</p> <h2 dir="auto">Steps to Reproduce (for bugs)</h2> <p dir="auto"><a href="https://codesandbox.io/s/m7p9qlpjnp" rel="nofollow">https://codesandbox.io/s/m7p9qlpjnp</a></p> <ol dir="auto"> <li>Resize the whole window until unnecessary scrollbars appear</li> <li>Simply hover over the button</li> <li>After moving the mouse away and again over the button the tooltip moves</li> <li>After doing that a few times it moves into the correct position it should have been in initially</li> </ol> <h2 dir="auto">Context</h2> <p dir="auto">It currently affects me when i resize my application (see image below) -&gt; then scrollbars appear due to the tooltip position, which shouldn't be there. After moving over and away from the button serveral times the tooltip is positioned correctly.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/490061/33489837-681c7770-d6b5-11e7-8a9d-00504fea0359.png"><img src="https://user-images.githubusercontent.com/490061/33489837-681c7770-d6b5-11e7-8a9d-00504fea0359.png" alt="image" style="max-width: 100%;"></a></p> <h2 dir="auto">Your Environment</h2> <table role="table"> <thead> <tr> <th>Tech</th> <th>Version</th> </tr> </thead> <tbody> <tr> <td>Material-UI</td> <td>1.0.0-beta.22</td> </tr> <tr> <td>Browser</td> <td>Chrome</td> </tr> </tbody> </table>
<p dir="auto"><code class="notranslate">TextField</code> with a <code class="notranslate">label</code> set to something and <code class="notranslate">type</code> set to date but with no initial value displays the label and <code class="notranslate">mm/dd/yyyy</code> on top of each other in the <code class="notranslate">TextField</code>. Once you enter the field, the label moves up as superscript and the mm/dd/yyyy remains and is readable.</p> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/callemall/material-ui/issues">issues</a> of this repository and believe that this is not a duplicate.</li> </ul> <h2 dir="auto">Expected Behavior</h2> <p dir="auto">When the date picker has no value, if it is going to display the expected date format in the field, it should treat that as a value and move the label up to superscript. Alternatively, don't display the date format unless the user enters the field and there is no value.</p> <h2 dir="auto">Current Behavior</h2> <p dir="auto">Currently the label and date format overwrite each other if there is no value for the TextField.</p> <h2 dir="auto">Steps to Reproduce (for bugs)</h2> <p dir="auto">Example on codesandbox.io:<br> <a href="https://codesandbox.io/s/6ljy4wq04k" rel="nofollow">https://codesandbox.io/s/6ljy4wq04k</a></p> <h2 dir="auto">Your Environment</h2> <table role="table"> <thead> <tr> <th>Tech</th> <th>Version</th> </tr> </thead> <tbody> <tr> <td>Material-UI</td> <td>1.0.0-beta.9</td> </tr> <tr> <td>React</td> <td>15.6.1</td> </tr> <tr> <td>browser</td> <td>Chrome 60.03</td> </tr> </tbody> </table>
0
<p dir="auto">Hi!</p> <p dir="auto">I want to make a custom layer which is supposed to fuse the output of a Dense Layer with a Convolution2D Layer.</p> <p dir="auto">The Idea came from <a href="http://dl.acm.org/citation.cfm?id=2925974" rel="nofollow">this paper</a> and here's the network:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/22426131/20623098/5031fff4-b31b-11e6-8594-a54e83fce131.PNG"><img src="https://cloud.githubusercontent.com/assets/22426131/20623098/5031fff4-b31b-11e6-8594-a54e83fce131.PNG" alt="The Network" style="max-width: 100%;"></a></p> <p dir="auto">the fusion layer tries to fuse the Convolution2D tensor (<code class="notranslate">256x28x28</code>) with the Dense tensor (<code class="notranslate">256</code>). here's the equation for it:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/22426131/20623156/86186496-b31b-11e6-9cb4-bc5baa024e24.PNG"><img src="https://cloud.githubusercontent.com/assets/22426131/20623156/86186496-b31b-11e6-9cb4-bc5baa024e24.PNG" alt="The Fusion Formula" style="max-width: 100%;"></a></p> <p dir="auto"><code class="notranslate">y_global =&gt; Dense layer output with shape 256</code><br> <code class="notranslate">y_mid =&gt; Convolution2D layer output with shape 256x28x28</code></p> <p dir="auto">Here's the description of the paper about the Fusion process:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/22426131/20623587/843d158e-b31d-11e6-9fa0-49709a241052.PNG"><img src="https://cloud.githubusercontent.com/assets/22426131/20623587/843d158e-b31d-11e6-9fa0-49709a241052.PNG" alt="capture3" style="max-width: 100%;"></a></p> <p dir="auto">I ended up making a new custom layer like below:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="class FusionLayer(Layer): def __init__(self, output_dim, **kwargs): self.output_dim = output_dim super(FusionLayer, self).__init__(**kwargs) def build(self, input_shape): input_dim = input_shape[1][1] initial_weight_value = np.random.random((input_dim, self.output_dim)) self.W = K.variable(initial_weight_value) self.b = K.zeros((input_dim,)) self.trainable_weights = [self.W, self.b] def call(self, inputs, mask=None): y_global = inputs[0] y_mid = inputs[1] # the code below should be modified output = K.dot(K.concatenate([y_global, y_mid]), self.W) output += self.b return self.activation(output) def get_output_shape_for(self, input_shape): assert input_shape and len(input_shape) == 2 return (input_shape[0], self.output_dim)"><pre class="notranslate"><code class="notranslate">class FusionLayer(Layer): def __init__(self, output_dim, **kwargs): self.output_dim = output_dim super(FusionLayer, self).__init__(**kwargs) def build(self, input_shape): input_dim = input_shape[1][1] initial_weight_value = np.random.random((input_dim, self.output_dim)) self.W = K.variable(initial_weight_value) self.b = K.zeros((input_dim,)) self.trainable_weights = [self.W, self.b] def call(self, inputs, mask=None): y_global = inputs[0] y_mid = inputs[1] # the code below should be modified output = K.dot(K.concatenate([y_global, y_mid]), self.W) output += self.b return self.activation(output) def get_output_shape_for(self, input_shape): assert input_shape and len(input_shape) == 2 return (input_shape[0], self.output_dim) </code></pre></div> <p dir="auto">I think I got the <code class="notranslate">__init__</code> and <code class="notranslate">build</code> methods right but I don't know how to concatenate <code class="notranslate">y_global</code> (256 dimesnions) with <code class="notranslate">y-mid</code> (256x28x28 dimensions) in the <code class="notranslate">call</code> layer so that the output would be the same as the equation mentioned above.</p> <p dir="auto">How can I implement this equation in the <code class="notranslate">call</code> method?</p> <p dir="auto">Thanks so much...</p> <p dir="auto">UPDATE: any other way to successfully integrate the data of these 2 layers is also acceptable for me... it doesn't exactly have to be the way mentioned in the paper but it needs to at least return an acceptable output...</p>
<p dir="auto">Easy to reproduce this bug when training GANs but probably occurs in other use cases as well. When <code class="notranslate">BatchNormalization</code> is used in the <code class="notranslate">generator</code> of a GAN, <code class="notranslate">combined.train_on_batch</code> fails. It's really weird but for some reason <code class="notranslate">combined.train_on_batch</code> does not calculate the loss correctly when batch norm is used in the generator. I tested the loss by hand doing something like:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="loss = combined.train_on_batch(x, y) combined_pred = combined.predict(x) loss_check = K.eval(custom_loss(y, combined_pred)) &gt;&gt;&gt; loss != loss_check"><pre class="notranslate"><span class="pl-s1">loss</span> <span class="pl-c1">=</span> <span class="pl-s1">combined</span>.<span class="pl-en">train_on_batch</span>(<span class="pl-s1">x</span>, <span class="pl-s1">y</span>) <span class="pl-s1">combined_pred</span> <span class="pl-c1">=</span> <span class="pl-s1">combined</span>.<span class="pl-en">predict</span>(<span class="pl-s1">x</span>) <span class="pl-s1">loss_check</span> <span class="pl-c1">=</span> <span class="pl-v">K</span>.<span class="pl-en">eval</span>(<span class="pl-en">custom_loss</span>(<span class="pl-s1">y</span>, <span class="pl-s1">combined_pred</span>)) <span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-s1">loss</span> <span class="pl-c1">!=</span> <span class="pl-s1">loss_check</span></pre></div> <p dir="auto">You can reproduce this in <code class="notranslate">wGAN</code> branch here: <a href="https://github.com/wayaai/GAN-Sandbox">https://github.com/wayaai/GAN-Sandbox</a> and uncomment the BatchNorm layer in the generator.</p>
0
<h5 dir="auto">System information (version)</h5> <ul dir="auto"> <li>OpenCV =&gt; 3.2</li> <li>Operating System / Platform =&gt; osx</li> <li>Compiler =&gt; clang</li> </ul> <h5 dir="auto">Detailed description</h5> <p dir="auto">copyTo does not use the type information available when copying between two typed matrices.</p> <h5 dir="auto">Steps to reproduce</h5> <p dir="auto">cv::Mat1b a{10, 10};<br> cv::Mat2b b{10, 10};<br> b.copyTo(a) // will fail at runtime, though it should not compile</p>
<h5 dir="auto">System information (version)</h5> <ul dir="auto"> <li>OpenCV =&gt; 4.1.1</li> <li>Operating System / Platform =&gt; Webassembly</li> <li>Compiler =&gt; emscripten</li> </ul> <h5 dir="auto">Detailed description</h5> <p dir="auto">I got this error message while compiling my C++ program that uses VideoCapture object<br> I compiled OpenCV using this build_js.py</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" def get_cmake_cmd(self): cmd = [&quot;cmake&quot;, &quot;-DCMAKE_BUILD_TYPE=Release&quot;, &quot;-DCMAKE_TOOLCHAIN_FILE='%s'&quot; % self.get_toolchain_file(), &quot;-DCPU_BASELINE=''&quot;, &quot;-DCPU_DISPATCH=''&quot;, &quot;-DCV_TRACE=OFF&quot;, &quot;-DBUILD_SHARED_LIBS=OFF&quot;, &quot;-DWITH_1394=OFF&quot;, &quot;-DWITH_ADE=OFF&quot;, &quot;-DWITH_VTK=OFF&quot;, &quot;-DWITH_EIGEN=OFF&quot;, &quot;-DWITH_FFMPEG=ON&quot;, &quot;-DWITH_GSTREAMER=ON&quot;, &quot;-DWITH_GTK=ON&quot;, &quot;-DWITH_GTK_2_X=OFF&quot;, &quot;-DWITH_IPP=OFF&quot;, &quot;-DWITH_JASPER=OFF&quot;, &quot;-DWITH_JPEG=ON&quot;, &quot;-DWITH_WEBP=ON&quot;, &quot;-DWITH_OPENEXR=OFF&quot;, &quot;-DWITH_OPENGL=OFF&quot;, &quot;-DWITH_OPENVX=OFF&quot;, &quot;-DWITH_OPENNI=OFF&quot;, &quot;-DWITH_OPENNI2=OFF&quot;, &quot;-DWITH_PNG=ON&quot;, &quot;-DWITH_TBB=OFF&quot;, &quot;-DWITH_PTHREADS_PF=OFF&quot;, &quot;-DWITH_TIFF=ON&quot;, &quot;-DWITH_V4L=ON&quot;, &quot;-DWITH_OPENCL=ON&quot;, &quot;-DWITH_OPENCL_SVM=ON&quot;, &quot;-DWITH_OPENCLAMDFFT=ON&quot;, &quot;-DWITH_OPENCLAMDBLAS=ON&quot;, &quot;-DWITH_GPHOTO2=OFF&quot;, &quot;-DWITH_LAPACK=OFF&quot;, &quot;-DWITH_ITT=OFF&quot;, &quot;-DWITH_QUIRC=OFF&quot;, &quot;-DBUILD_ZLIB=ON&quot;, &quot;-DBUILD_opencv_apps=ON&quot;, &quot;-DBUILD_opencv_calib3d=ON&quot;, &quot;-DBUILD_opencv_dnn=ON&quot;, &quot;-DBUILD_opencv_features2d=ON&quot;, &quot;-DBUILD_opencv_flann=ON&quot;, # No bindings provided. This module is used as a dependency for other modules. &quot;-DBUILD_opencv_gapi=OFF&quot;, &quot;-DBUILD_opencv_ml=OFF&quot;, &quot;-DBUILD_opencv_photo=ON&quot;, &quot;-DBUILD_opencv_imgcodecs=ON&quot;, &quot;-DBUILD_opencv_shape=OFF&quot;, &quot;-DBUILD_opencv_videoio=ON&quot;, &quot;-DBUILD_opencv_videostab=ON&quot;, &quot;-DBUILD_opencv_highgui=ON&quot;, &quot;-DBUILD_opencv_superres=OFF&quot;, &quot;-DBUILD_opencv_stitching=OFF&quot;, &quot;-DBUILD_opencv_java=OFF&quot;, &quot;-DBUILD_opencv_java_bindings_generator=OFF&quot;, &quot;-DBUILD_opencv_js=ON&quot;, &quot;-DBUILD_opencv_python2=OFF&quot;, &quot;-DBUILD_opencv_python3=OFF&quot;, &quot;-DBUILD_opencv_python_bindings_generator=OFF&quot;, &quot;-DBUILD_EXAMPLES=OFF&quot;, &quot;-DBUILD_PACKAGE=OFF&quot;, &quot;-DBUILD_TESTS=OFF&quot;, &quot;-DBUILD_PERF_TESTS=OFF&quot;]"><pre class="notranslate"><span class="pl-k">def</span> <span class="pl-en">get_cmake_cmd</span>(<span class="pl-s1">self</span>): <span class="pl-s1">cmd</span> <span class="pl-c1">=</span> [<span class="pl-s">"cmake"</span>, <span class="pl-s">"-DCMAKE_BUILD_TYPE=Release"</span>, <span class="pl-s">"-DCMAKE_TOOLCHAIN_FILE='%s'"</span> <span class="pl-c1">%</span> <span class="pl-s1">self</span>.<span class="pl-en">get_toolchain_file</span>(), <span class="pl-s">"-DCPU_BASELINE=''"</span>, <span class="pl-s">"-DCPU_DISPATCH=''"</span>, <span class="pl-s">"-DCV_TRACE=OFF"</span>, <span class="pl-s">"-DBUILD_SHARED_LIBS=OFF"</span>, <span class="pl-s">"-DWITH_1394=OFF"</span>, <span class="pl-s">"-DWITH_ADE=OFF"</span>, <span class="pl-s">"-DWITH_VTK=OFF"</span>, <span class="pl-s">"-DWITH_EIGEN=OFF"</span>, <span class="pl-s">"-DWITH_FFMPEG=ON"</span>, <span class="pl-s">"-DWITH_GSTREAMER=ON"</span>, <span class="pl-s">"-DWITH_GTK=ON"</span>, <span class="pl-s">"-DWITH_GTK_2_X=OFF"</span>, <span class="pl-s">"-DWITH_IPP=OFF"</span>, <span class="pl-s">"-DWITH_JASPER=OFF"</span>, <span class="pl-s">"-DWITH_JPEG=ON"</span>, <span class="pl-s">"-DWITH_WEBP=ON"</span>, <span class="pl-s">"-DWITH_OPENEXR=OFF"</span>, <span class="pl-s">"-DWITH_OPENGL=OFF"</span>, <span class="pl-s">"-DWITH_OPENVX=OFF"</span>, <span class="pl-s">"-DWITH_OPENNI=OFF"</span>, <span class="pl-s">"-DWITH_OPENNI2=OFF"</span>, <span class="pl-s">"-DWITH_PNG=ON"</span>, <span class="pl-s">"-DWITH_TBB=OFF"</span>, <span class="pl-s">"-DWITH_PTHREADS_PF=OFF"</span>, <span class="pl-s">"-DWITH_TIFF=ON"</span>, <span class="pl-s">"-DWITH_V4L=ON"</span>, <span class="pl-s">"-DWITH_OPENCL=ON"</span>, <span class="pl-s">"-DWITH_OPENCL_SVM=ON"</span>, <span class="pl-s">"-DWITH_OPENCLAMDFFT=ON"</span>, <span class="pl-s">"-DWITH_OPENCLAMDBLAS=ON"</span>, <span class="pl-s">"-DWITH_GPHOTO2=OFF"</span>, <span class="pl-s">"-DWITH_LAPACK=OFF"</span>, <span class="pl-s">"-DWITH_ITT=OFF"</span>, <span class="pl-s">"-DWITH_QUIRC=OFF"</span>, <span class="pl-s">"-DBUILD_ZLIB=ON"</span>, <span class="pl-s">"-DBUILD_opencv_apps=ON"</span>, <span class="pl-s">"-DBUILD_opencv_calib3d=ON"</span>, <span class="pl-s">"-DBUILD_opencv_dnn=ON"</span>, <span class="pl-s">"-DBUILD_opencv_features2d=ON"</span>, <span class="pl-s">"-DBUILD_opencv_flann=ON"</span>, <span class="pl-c"># No bindings provided. This module is used as a dependency for other modules.</span> <span class="pl-s">"-DBUILD_opencv_gapi=OFF"</span>, <span class="pl-s">"-DBUILD_opencv_ml=OFF"</span>, <span class="pl-s">"-DBUILD_opencv_photo=ON"</span>, <span class="pl-s">"-DBUILD_opencv_imgcodecs=ON"</span>, <span class="pl-s">"-DBUILD_opencv_shape=OFF"</span>, <span class="pl-s">"-DBUILD_opencv_videoio=ON"</span>, <span class="pl-s">"-DBUILD_opencv_videostab=ON"</span>, <span class="pl-s">"-DBUILD_opencv_highgui=ON"</span>, <span class="pl-s">"-DBUILD_opencv_superres=OFF"</span>, <span class="pl-s">"-DBUILD_opencv_stitching=OFF"</span>, <span class="pl-s">"-DBUILD_opencv_java=OFF"</span>, <span class="pl-s">"-DBUILD_opencv_java_bindings_generator=OFF"</span>, <span class="pl-s">"-DBUILD_opencv_js=ON"</span>, <span class="pl-s">"-DBUILD_opencv_python2=OFF"</span>, <span class="pl-s">"-DBUILD_opencv_python3=OFF"</span>, <span class="pl-s">"-DBUILD_opencv_python_bindings_generator=OFF"</span>, <span class="pl-s">"-DBUILD_EXAMPLES=OFF"</span>, <span class="pl-s">"-DBUILD_PACKAGE=OFF"</span>, <span class="pl-s">"-DBUILD_TESTS=OFF"</span>, <span class="pl-s">"-DBUILD_PERF_TESTS=OFF"</span>]</pre></div>
0
<p dir="auto">Challenge <a href="http://www.freecodecamp.com/challenges/waypoint-sift-through-text-with-regular-expressions" rel="nofollow">http://www.freecodecamp.com/challenges/waypoint-sift-through-text-with-regular-expressions</a></p> <p dir="auto">Instructions for this and the next couple of lessons are some what misleading when explaining what + does in regex syntax.</p> <p dir="auto">Instructions state + is need to find 'one or more occurrences of this pattern' which is not correct. In the example given + would find the letters an followed by 1 or more d's, and not multiple and's.</p> <p dir="auto">Also, the tests expect and+ when + is not required to find an the occurrences of and in the sentence.</p>
<h4 dir="auto">Issue Description</h4> <p dir="auto">Anytime I attempt to edit text it starts on the line below where I have selected. This can be adding a space, letter, number. Any editing of any kind including backspaces happen on the next line as well.<br> It only happens once and happens on any new/reloaded page. Occurs in both night mode and day mode.</p> <h4 dir="auto">Browser Information</h4> <ul dir="auto"> <li>Browser Name, Version: Chrome Version 57.0.2987.98 (64-bit)</li> <li>Operating System: Windows 10</li> <li>Mobile, Desktop, or Tablet: Desktop</li> </ul> <h4 dir="auto">Screenshot</h4> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/12226281/24592012/7c1aaa32-17dc-11e7-8df6-c026146fce87.png"><img src="https://cloud.githubusercontent.com/assets/12226281/24592012/7c1aaa32-17dc-11e7-8df6-c026146fce87.png" alt="editingissuebefore" style="max-width: 100%;"></a></p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/12226281/24592015/85beef62-17dc-11e7-836b-ad42cb808fc5.png"><img src="https://cloud.githubusercontent.com/assets/12226281/24592015/85beef62-17dc-11e7-836b-ad42cb808fc5.png" alt="editingissueafter" style="max-width: 100%;"></a></p>
0
<p dir="auto">When i started using freecodecamp, i didn't know that each user can create a personal profile and all his solutions will be present there.<br> As a result, my profile page is filled with many redundant solutions because sometimes i comeback and relearn old problems and submit the results many times.</p> <p dir="auto">It would be nice if there is a button that allows user to delete unwanted or dated solutions.<br> Thanks.</p>
<p dir="auto">If there are multiple solutions posted to a bonfire I'd like the ability to remove older versions (though I'd also like to be <em>able</em> to keep older versions too). Perhaps the ability to edit the solution on my profile.</p>
1
<p dir="auto">There appears to be both</p> <p dir="auto"><code class="notranslate">FrameworkBundle\Tests\Debug\TraceableEventDispatcherTest</code><br> <code class="notranslate">FrameworkBundle\Tests\Debug\TraceableEventDispactherTest</code></p> <p dir="auto">One has a stopwatch and one doesn't. I'm guessing this is an error? The issue is the spelling of dispatch <code class="notranslate">tch</code> vs <code class="notranslate">cth</code></p>
<p dir="auto">Start with these two Documents:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" namespace My\XBundle\Document; use Doctrine\ODM\MongoDB\Mapping\Annotations as MongoDB; /** * @MongoDB\Document * @MongoDB\InheritanceType(&quot;COLLECTION_PER_CLASS&quot;) */ abstract class AbstractFoo { /** * @MongoDB\Id */ protected $id; /** * @MongoDB\String */ protected $displayName; }"><pre lang="php&lt;?php" class="notranslate"><code class="notranslate"> namespace My\XBundle\Document; use Doctrine\ODM\MongoDB\Mapping\Annotations as MongoDB; /** * @MongoDB\Document * @MongoDB\InheritanceType("COLLECTION_PER_CLASS") */ abstract class AbstractFoo { /** * @MongoDB\Id */ protected $id; /** * @MongoDB\String */ protected $displayName; } </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" namespace My\XBundle\Document; use Doctrine\ODM\MongoDB\Mapping\Annotations as MongoDB; /** * @MongoDB\Document */ class SubFoo extends AbstractFoo { /** * @MongoDB\String */ protected $value; }"><pre lang="php&lt;?php" class="notranslate"><code class="notranslate"> namespace My\XBundle\Document; use Doctrine\ODM\MongoDB\Mapping\Annotations as MongoDB; /** * @MongoDB\Document */ class SubFoo extends AbstractFoo { /** * @MongoDB\String */ protected $value; } </code></pre></div> <p dir="auto">Now, when you run <code class="notranslate">mongodb:generate:documents My\XBundle</code>, you will end up with this in the subclass:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" namespace My\XBundle\Document; use Doctrine\ODM\MongoDB\Mapping\Annotations as MongoDB; /** * @MongoDB\Document */ class SubFoo extends AbstractFoo { /** * @MongoDB\String */ protected $value; /** * @var $id */ protected $id; /** * @var string $displayName */ protected $displayName; /** * Set value * * @param string $value */ public function setValue($value) { $this-&gt;value = $value; } /** * Get value * * @return string $value */ public function getValue() { return $this-&gt;value; } /** * Get id * * @return id $id */ public function getId() { return $this-&gt;id; } /** * Set displayName * * @param string $displayName */ public function setDisplayName($displayName) { $this-&gt;displayName = $displayName; } /** * Get displayName * * @return string $displayName */ public function getDisplayName() { return $this-&gt;displayName; } }"><pre lang="php&lt;?php" class="notranslate"><code class="notranslate"> namespace My\XBundle\Document; use Doctrine\ODM\MongoDB\Mapping\Annotations as MongoDB; /** * @MongoDB\Document */ class SubFoo extends AbstractFoo { /** * @MongoDB\String */ protected $value; /** * @var $id */ protected $id; /** * @var string $displayName */ protected $displayName; /** * Set value * * @param string $value */ public function setValue($value) { $this-&gt;value = $value; } /** * Get value * * @return string $value */ public function getValue() { return $this-&gt;value; } /** * Get id * * @return id $id */ public function getId() { return $this-&gt;id; } /** * Set displayName * * @param string $displayName */ public function setDisplayName($displayName) { $this-&gt;displayName = $displayName; } /** * Get displayName * * @return string $displayName */ public function getDisplayName() { return $this-&gt;displayName; } } </code></pre></div>
0
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/callemall/material-ui/issues">issues</a> of this repository and believe that this is not a duplicate.</li> </ul> <h2 dir="auto">Context</h2> <p dir="auto">For now I am using the Menu component to render custom context menu on the mouse right click event. And menu should appear relatively to the cursor position. So it would be great to pass some<br> additional "x, y" props to the Popover that will shift Menu position relatively to the anchorEl. Is that a<br> good idea? Or maybe there is a better way to perform that functionality? Thanks!</p> <h2 dir="auto">Your Environment</h2> <table role="table"> <thead> <tr> <th>Tech</th> <th>Version</th> </tr> </thead> <tbody> <tr> <td>Material-UI</td> <td>v1.0.0-beta.17</td> </tr> <tr> <td>React</td> <td>v16.0.0</td> </tr> <tr> <td>browser</td> <td>Google Chrome 61.0.3163.100</td> </tr> <tr> <td>etc</td> <td></td> </tr> </tbody> </table>
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/callemall/material-ui/issues">issues</a> of this repository and believe that this is not a duplicate.</li> </ul> <h2 dir="auto">Expected Behavior</h2> <p dir="auto">I want to add some custom colors as primary for theme.</p> <h2 dir="auto">Current Behavior</h2> <p dir="auto">Updating theme with custom color not possible. New object is updated with new color but theme property not get updated.</p> <h2 dir="auto">Steps to Reproduce (for bugs)</h2> <p dir="auto">I call createMuiTheme method and pass object</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="const default_theme_obj = { fontFamily: &quot;Roboto, sans-serif&quot;, palette: { primary: &quot;#fff&quot; }, };"><pre class="notranslate"><span class="pl-k">const</span> <span class="pl-s1">default_theme_obj</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span> <span class="pl-c1">fontFamily</span>: <span class="pl-s">"Roboto, sans-serif"</span><span class="pl-kos">,</span> <span class="pl-c1">palette</span>: <span class="pl-kos">{</span> <span class="pl-c1">primary</span>: <span class="pl-s">"#fff"</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-kos">}</span><span class="pl-kos">;</span></pre></div> <p dir="auto">but when i pass it as theme={default_theme_obj} to MuiThemeProvider nothing happen, it still have default MUI theme colors. This is exacly how it was worked it v0.19.</p> <h2 dir="auto">Context</h2> <p dir="auto">I expect that theme is updated with new color set as primary.<br> My app have several different theme depend on user role. When user is on login page default should be applied with color from DEFAULT_THEME object and when user get access he also get theme from DB which is applied to MUI. It was working really well in v0.19 but when i switch MuiProvider is never updated.</p> <h2 dir="auto">Your Environment</h2> <table role="table"> <thead> <tr> <th>Tech</th> <th>Version</th> </tr> </thead> <tbody> <tr> <td>Material-UI</td> <td>1.0.0-beta.20</td> </tr> <tr> <td>React</td> <td>16.1.1</td> </tr> <tr> <td>browser</td> <td>all</td> </tr> </tbody> </table>
0
<h3 dir="auto">Version</h3> <p dir="auto">2.5.17</p> <h3 dir="auto">Reproduction link</h3> <p dir="auto"><a href="https://codesandbox.io/s/zwm20ozlym" rel="nofollow">https://codesandbox.io/s/zwm20ozlym</a></p> <h3 dir="auto">Steps to reproduce</h3> <p dir="auto">check reproduction url</p> <h3 dir="auto">What is expected?</h3> <p dir="auto">Duplicate keys detected to be warned</p> <h3 dir="auto">What is actually happening?</h3> <p dir="auto">Duplicate keys detected not warned</p> <hr> <p dir="auto">when addVnodes is called, vnodes with same key are not warned</p>
<p dir="auto">When a class is set in an dom element which is being initied with Vue and the same class is set in the component root dom element, the final result is a double class. You can see the results <a href="https://jsfiddle.net/miljan/8z2phjsx/1/" rel="nofollow">here</a>, check with the console the dom and you should see "compClass compClass" instead of just one.</p> <p dir="auto">It's not a big deal but doesn't seem the expected behaviour.</p>
0
<p dir="auto">Atom will not responding when viewing a large chunk of minified script, maybe it has to do with the syntax highlighting.</p>
<p dir="auto">May be a known issue, but files with large embedded images such as github's public/enterprise/maintenance.html will often cause Atom to freeze (MacVim actually struggles as well).</p> <p dir="auto">Seems some of them (github's public/maintenance.html for instance) work fine when in soft wrap mode, or until you move your cursor to the long line when out of soft wrap.</p>
1
<h3 dir="auto">Problem description</h3> <p dir="auto">The <code class="notranslate">&lt;Grid container&gt;</code> component receives these props</p> <div class="highlight highlight-source-css notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=".MuiGrid-spacing-xs-16-1335 { width: calc(100% + 16px); margin: -8px; }"><pre class="notranslate">.<span class="pl-c1">MuiGrid-spacing-xs-16-1335</span> { <span class="pl-c1">width</span><span class="pl-kos">:</span> <span class="pl-en">calc</span>(<span class="pl-c1">100<span class="pl-smi">%</span></span> <span class="pl-c1">+</span> <span class="pl-c1">16<span class="pl-smi">px</span></span>); <span class="pl-c1">margin</span><span class="pl-kos">:</span> <span class="pl-c1">-8<span class="pl-smi">px</span></span>; }</pre></div> <p dir="auto">causing a horizontal scrollbar. See <a href="https://stackoverflow.com/questions/45519275/grid-in-material-ui-causes-horizontal-scroll-react" rel="nofollow">this</a> question for a more accurate example and the (unelegant) fix.</p> <h3 dir="auto">Steps to reproduce</h3> <p dir="auto">Create an empty project and create one <code class="notranslate">&lt;Grid&gt;</code> with a single item inside. Your page will have a horizontal scroll bar.</p> <h3 dir="auto">Versions</h3> <ul dir="auto"> <li>Material-UI: beta 5</li> <li>React: 15.6.1</li> <li>Browser: Chrome 60</li> </ul> <h3 dir="auto">Proposed solution</h3> <p dir="auto">Only apply the spacing class and its variants on <code class="notranslate">&lt;Grid&gt;</code> children. I suppose this may be a little inconsistent in the case where you are nesting <code class="notranslate">&lt;Grid&gt;</code> containers, so an alternative could be to just have a prop like <code class="notranslate">applySpacingToContainerOnly={true}</code> (default: <code class="notranslate">false</code>) or something?</p>
<p dir="auto">The <code class="notranslate">&lt;Grid container&gt;</code> extends beyond its parent, with half of spacing size.<br> I have marked the extra width in red, also setting spacing to zero fixes the problem.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/3260363/28355346-338983fc-6c81-11e7-9f67-fb33c7758283.png"><img src="https://user-images.githubusercontent.com/3260363/28355346-338983fc-6c81-11e7-9f67-fb33c7758283.png" alt="mobile-padding" style="max-width: 100%;"></a></p> <p dir="auto">Here is a working example: <a href="https://codesandbox.io/s/Y8nzGm5W" rel="nofollow">https://codesandbox.io/s/Y8nzGm5W</a>.<br> Similar code with a zero spacing works as expected: <a href="https://codesandbox.io/s/NxvYxvQpL" rel="nofollow">https://codesandbox.io/s/NxvYxvQpL</a>.</p>
1
<p dir="auto">I recently moved to webpack from require.js and some node_module have .min files built in. When I use a file from node_module I just do <code class="notranslate">require('my-module')</code> and it loads it right away without any config. But this will load the development version or a bigger version.</p> <p dir="auto">For example react is loaded <code class="notranslate">require('react/addons')</code> but this is not the minified version.</p> <p dir="auto">My question is:</p> <ul dir="auto"> <li>Should I load modules normally and then minify everything?</li> <li>Should I use their .min files provided and then minify everything again? (in this way I save a lot of disk)</li> <li>Any better way? Would be nice to automatically loade minified files.</li> </ul> <p dir="auto">For now, I'm changing the aliases of webpack to load the minified version when building the app:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="myConfig.resolve.alias.phaserUnFixed = &quot;nodeModules/phaser/build/custom/phaser-no-physics.min.js&quot;; myConfig.resolve.alias.react = &quot;nodeModules/react/dist/react-with-addons.min.js&quot;; myConfig.resolve.alias.lodash = &quot;nodeModules/lodash/dist/lodash.compat.min.js&quot;; myConfig.resolve.alias.moment = &quot;nodeModules/moment/min/moment.min.js&quot;;"><pre class="notranslate"><code class="notranslate">myConfig.resolve.alias.phaserUnFixed = "nodeModules/phaser/build/custom/phaser-no-physics.min.js"; myConfig.resolve.alias.react = "nodeModules/react/dist/react-with-addons.min.js"; myConfig.resolve.alias.lodash = "nodeModules/lodash/dist/lodash.compat.min.js"; myConfig.resolve.alias.moment = "nodeModules/moment/min/moment.min.js"; </code></pre></div> <p dir="auto">But this is not a good approach either... Can you think of anything better?</p>
<h1 dir="auto">Bug report</h1> <p dir="auto">Hello I had in my package.json<br> <code class="notranslate">^4.17.2</code></p> <p dir="auto">It auto upgraded to <code class="notranslate">4.20.3</code> and then I get the error:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema. - configuration.module.rules[0].exclude should be one of these: RegExp | string | function | [(recursive)] | object { and?, exclude?, include?, not?, or?, test? } | [RegExp | string | function | [(recursive)] | object { and?, exclude?, include?, not?, or?, test? }] -&gt; One or multiple rule conditions Details: * configuration.module.rules[0].exclude should be an instance of RegExp * configuration.module.rules[0].exclude should be a string. * configuration.module.rules[0].exclude should be an instance of function * configuration.module.rules[0].exclude[0] should be an instance of RegExp * configuration.module.rules[0].exclude[0]: The provided value &quot;node_modules&quot; is not an absolute path! * configuration.module.rules[0].exclude[0] should be an instance of function * configuration.module.rules[0].exclude[0] should be an array: [RegExp | string | function | [(recursive)] | object { and?, exclude?, include?, not?, or?, test? }] * configuration.module.rules[0].exclude[0] should be an object. * configuration.module.rules[0].exclude should be an object. * configuration.module.rules[0].exclude[0] should be an instance of RegExp * configuration.module.rules[0].exclude[0]: The provided value &quot;node_modules&quot; is not an absolute path! * configuration.module.rules[0].exclude[0] should be an instance of function * configuration.module.rules[0].exclude[0] should be an array: [RegExp | string | function | [(recursive)] | object { and?, exclude?, include?, not?, or?, test? }] * configuration.module.rules[0].exclude[0] should be an object. npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! p2@0.0.1 dist: `cross-env PRODUCTION=true node_modules/.bin/webpack` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the p2@0.0.1 dist script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above."><pre class="notranslate"><code class="notranslate">Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema. - configuration.module.rules[0].exclude should be one of these: RegExp | string | function | [(recursive)] | object { and?, exclude?, include?, not?, or?, test? } | [RegExp | string | function | [(recursive)] | object { and?, exclude?, include?, not?, or?, test? }] -&gt; One or multiple rule conditions Details: * configuration.module.rules[0].exclude should be an instance of RegExp * configuration.module.rules[0].exclude should be a string. * configuration.module.rules[0].exclude should be an instance of function * configuration.module.rules[0].exclude[0] should be an instance of RegExp * configuration.module.rules[0].exclude[0]: The provided value "node_modules" is not an absolute path! * configuration.module.rules[0].exclude[0] should be an instance of function * configuration.module.rules[0].exclude[0] should be an array: [RegExp | string | function | [(recursive)] | object { and?, exclude?, include?, not?, or?, test? }] * configuration.module.rules[0].exclude[0] should be an object. * configuration.module.rules[0].exclude should be an object. * configuration.module.rules[0].exclude[0] should be an instance of RegExp * configuration.module.rules[0].exclude[0]: The provided value "node_modules" is not an absolute path! * configuration.module.rules[0].exclude[0] should be an instance of function * configuration.module.rules[0].exclude[0] should be an array: [RegExp | string | function | [(recursive)] | object { and?, exclude?, include?, not?, or?, test? }] * configuration.module.rules[0].exclude[0] should be an object. npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! p2@0.0.1 dist: `cross-env PRODUCTION=true node_modules/.bin/webpack` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the p2@0.0.1 dist script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. </code></pre></div> <p dir="auto"><strong>What is the current behavior?</strong></p> <p dir="auto">I downgraded to <code class="notranslate">~4.17.2</code></p> <p dir="auto">I didnt suppose you'd release a breaking change<br> and such one,</p> <p dir="auto"><code class="notranslate">webpack.config.js</code></p> <p dir="auto">relevant part</p> <p dir="auto"><code class="notranslate">exclude: ['node_modules']</code></p>
0
<p dir="auto">I ran into this when implementing Back button transition in a router. Because the transition is inside a browser <code class="notranslate">popstate</code> event, it gets batched with the low pri update, and the pending state doesn't appear.</p> <p dir="auto">I had to do <a href="https://github.com/gaearon/suspense-experimental-github-demo/blob/cb75d1a71847be85e1365d8b33f766a0d0e21463/src/createRouter.js#L68-L69">this</a> to work around it but it's unfortunate. We might want to fix this by treating pending state as special. Or maybe a warning — but then we need a first-class official API for opting into user blocking pri.</p>
<p dir="auto"><strong>Do you want to request a <em>feature</em> or report a <em>bug</em>?</strong></p> <p dir="auto">Bug</p> <p dir="auto"><strong>What is the current behavior?</strong></p> <p dir="auto"><code class="notranslate">isPending</code> is never set to true when calling <code class="notranslate">startTransition</code> within <code class="notranslate">useEffect</code>, but it <em>does</em> work properly when within a <code class="notranslate">useLayoutEffect</code>.</p> <p dir="auto"><a href="https://codesandbox.io/s/usetransition-useeffect-issues-p1j9s" rel="nofollow">https://codesandbox.io/s/usetransition-useeffect-issues-p1j9s</a></p> <p dir="auto">Here's the correct behavior (accomplished via <code class="notranslate">useLayoutEffect</code>):</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/1500684/68164575-662d7b00-ff1a-11e9-9d02-71d7a22fd5cf.gif"><img src="https://user-images.githubusercontent.com/1500684/68164575-662d7b00-ff1a-11e9-9d02-71d7a22fd5cf.gif" alt="good" data-animated-image="" style="max-width: 100%;"></a></p> <p dir="auto">Here's the incorrect behavior (via <code class="notranslate">useEffect</code>):</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/1500684/68164540-4c8c3380-ff1a-11e9-9191-d9c87ddecbed.gif"><img src="https://user-images.githubusercontent.com/1500684/68164540-4c8c3380-ff1a-11e9-9191-d9c87ddecbed.gif" alt="bad" data-animated-image="" style="max-width: 100%;"></a></p> <p dir="auto">Note the difference is that the opacity never changes to 0.4 (which is determined based on the <code class="notranslate">isPending</code> state).</p> <p dir="auto"><strong>What is the expected behavior?</strong></p> <p dir="auto">I expect them to both behave the same (at least as far as the user can observe).</p> <p dir="auto"><strong>Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?</strong></p> <ul dir="auto"> <li>react@0.0.0-experimental-f6b8d31a7</li> <li>react-dom@0.0.0-experimental-f6b8d31a7</li> </ul>
1
<p dir="auto">Reduction from <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="341180436" data-permission-text="Title is private" data-url="https://github.com/JuliaLang/julia/issues/28118" data-hovercard-type="pull_request" data-hovercard-url="/JuliaLang/julia/pull/28118/hovercard?comment_id=408327573&amp;comment_type=issue_comment" href="https://github.com/JuliaLang/julia/pull/28118#issuecomment-408327573">#28118 (comment)</a>. Note: Needs <code class="notranslate">julia -g</code> (or <code class="notranslate">julia-debug</code>) for reproduction to enable the verifier:</p> <div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="julia&gt; function foo() try finally try catch ex end end end foo (generic function with 1 method) julia&gt; code_typed(foo, Tuple{}) Block 6 successors (Array{Int64, (2,)}[9, 7]), does not match fall-through terminator ERROR: Stacktrace: [1] error() at ./error.jl:42 [2] verify_ir(::Core.Compiler.IRCode) at ./compiler/ssair/verify.jl:110"><pre class="notranslate">julia<span class="pl-k">&gt;</span> <span class="pl-k">function</span> <span class="pl-en">foo</span>() <span class="pl-k">try</span> <span class="pl-k">finally</span> <span class="pl-k">try</span> <span class="pl-k">catch</span> ex <span class="pl-k">end</span> <span class="pl-k">end</span> <span class="pl-k">end</span> foo (generic <span class="pl-k">function</span> with <span class="pl-c1">1</span> method) julia<span class="pl-k">&gt;</span> <span class="pl-c1">code_typed</span>(foo, Tuple{}) Block <span class="pl-c1">6</span> successors (Array{Int64, (<span class="pl-c1">2</span>,)}[<span class="pl-c1">9</span>, <span class="pl-c1">7</span>]), does not match fall<span class="pl-k">-</span>through terminator ERROR<span class="pl-k">:</span> Stacktrace<span class="pl-k">:</span> [<span class="pl-c1">1</span>] <span class="pl-c1">error</span>() at <span class="pl-k">./</span>error<span class="pl-k">.</span>jl<span class="pl-k">:</span><span class="pl-c1">42</span> [<span class="pl-c1">2</span>] <span class="pl-c1">verify_ir</span>(<span class="pl-k">::</span><span class="pl-c1">Core.Compiler.IRCode</span>) at <span class="pl-k">./</span>compiler<span class="pl-k">/</span>ssair<span class="pl-k">/</span>verify<span class="pl-k">.</span>jl<span class="pl-k">:</span><span class="pl-c1">110</span></pre></div> <p dir="auto">The failing test is this:<br> </p><div class="Box Box--condensed my-2"> <div class="Box-header f6"> <p class="mb-0 text-bold"> <a href="https://github.com/JuliaLang/julia/blob/4b8c697be086c2830d66413f9c16eb50e0ecc45a/base/compiler/ssair/verify.jl#L108-L109">julia/base/compiler/ssair/verify.jl</a> </p> <p class="mb-0 color-fg-muted"> Lines 108 to 109 in <a data-pjax="true" class="commit-tease-sha" href="/JuliaLang/julia/commit/4b8c697be086c2830d66413f9c16eb50e0ecc45a">4b8c697</a> </p> </div> <div itemprop="text" class="Box-body p-0 blob-wrapper blob-wrapper-embedded data"> <table class="highlight tab-size mb-0 js-file-line-container" data-tab-size="8" data-paste-markdown-skip=""> <tbody><tr class="border-0"> <td id="L108" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="108"></td> <td id="LC108" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-k">if</span> <span class="pl-c1">length</span>(block<span class="pl-k">.</span>succs) <span class="pl-k">!=</span> <span class="pl-c1">1</span> <span class="pl-k">||</span> block<span class="pl-k">.</span>succs[<span class="pl-c1">1</span>] <span class="pl-k">!=</span> idx <span class="pl-k">+</span> <span class="pl-c1">1</span> </td> </tr> <tr class="border-0"> <td id="L109" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="109"></td> <td id="LC109" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-c1">@verify_error</span> <span class="pl-s"><span class="pl-pds">"</span>Block <span class="pl-v">$idx</span> successors (<span class="pl-v">$(block<span class="pl-k">.</span>succs)</span>), does not match fall-through terminator<span class="pl-pds">"</span></span> </td> </tr> </tbody></table> </div> </div> <p></p> <p dir="auto">The IR looks like this:</p> <div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" 1 ── $(Expr(:enter, #4)) 2 ── $(Expr(:leave, 1)) 3 ── goto #6 4 ── $(Expr(:leave, 1)) 5 ── %5 = $(Expr(:the_exception))::Any 4 6 ┄─ %6 = φ (#3 =&gt; 1, #5 =&gt; 2)::Int64 │ %7 = φ (#3 =&gt; false, #5 =&gt; true)::Bool │ %8 = φ (#3 =&gt; #undef, #5 =&gt; %5)::Core.Compiler.MaybeUndef(Any) │ $(Expr(:enter, #9)) │ %10 = ϒ (%6)::Int64 └─── %11 = ϒ (%8)::Any 7 ── $(Expr(:leave, 1)) 8 ── goto #11 9 ── %14 = φᶜ (%10)::Int64 │ %15 = φᶜ (%11)::Any └─── $(Expr(:leave, 1)) 10 ─ nothing::Nothing 6 11 ┄ %18 = φ (#8 =&gt; %6, #10 =&gt; %14)::Int64 │ %19 = φ (#8 =&gt; %7, #10 =&gt; true)::Bool │ %20 = φ (#8 =&gt; %8, #10 =&gt; %15)::Core.Compiler.MaybeUndef(Any) │ %21 = (%18 === 2)::Bool └─── goto #13 if not %21 12 ─ $(Expr(:throw_undef_if_not, Symbol(&quot;#temp#&quot;), :(%19)))::Any │ $(Expr(:foreigncall, :(:jl_rethrow_other), Union{}, svec(Any), :(:ccall), 1, :(%20)))::Union{} └─── unreachable 13 ─ return nothing"><pre class="notranslate"> <span class="pl-c1">1</span> ── <span class="pl-k">$</span>(<span class="pl-c1">Expr</span>(<span class="pl-c1">:enter</span>, <span class="pl-c"><span class="pl-c">#</span>4))</span> <span class="pl-c1">2</span> ── <span class="pl-k">$</span>(<span class="pl-c1">Expr</span>(<span class="pl-c1">:leave</span>, <span class="pl-c1">1</span>)) <span class="pl-c1">3</span> ── goto <span class="pl-c"><span class="pl-c">#</span>6</span> <span class="pl-c1">4</span> ── <span class="pl-k">$</span>(<span class="pl-c1">Expr</span>(<span class="pl-c1">:leave</span>, <span class="pl-c1">1</span>)) <span class="pl-c1">5</span> ── <span class="pl-k">%</span><span class="pl-c1">5</span> <span class="pl-k">=</span> <span class="pl-k">$</span>(<span class="pl-c1">Expr</span>(<span class="pl-c1">:the_exception</span>))<span class="pl-k">::</span><span class="pl-c1">Any</span> <span class="pl-c1">4</span> <span class="pl-c1">6</span> ┄─ <span class="pl-k">%</span><span class="pl-c1">6</span> <span class="pl-k">=</span> φ (<span class="pl-c"><span class="pl-c">#</span>3 =&gt; 1, #5 =&gt; 2)::Int64</span> │ <span class="pl-k">%</span><span class="pl-c1">7</span> <span class="pl-k">=</span> φ (<span class="pl-c"><span class="pl-c">#</span>3 =&gt; false, #5 =&gt; true)::Bool</span> │ <span class="pl-k">%</span><span class="pl-c1">8</span> <span class="pl-k">=</span> φ (<span class="pl-c"><span class="pl-c">#</span>3 =&gt; #undef, #5 =&gt; %5)::Core.Compiler.MaybeUndef(Any)</span> │ <span class="pl-k">$</span>(<span class="pl-c1">Expr</span>(<span class="pl-c1">:enter</span>, <span class="pl-c"><span class="pl-c">#</span>9))</span> │ <span class="pl-k">%</span><span class="pl-c1">10</span> <span class="pl-k">=</span> ϒ (<span class="pl-k">%</span><span class="pl-c1">6</span>)<span class="pl-k">::</span><span class="pl-c1">Int64</span> └─── <span class="pl-k">%</span><span class="pl-c1">11</span> <span class="pl-k">=</span> ϒ (<span class="pl-k">%</span><span class="pl-c1">8</span>)<span class="pl-k">::</span><span class="pl-c1">Any</span> <span class="pl-c1">7</span> ── <span class="pl-k">$</span>(<span class="pl-c1">Expr</span>(<span class="pl-c1">:leave</span>, <span class="pl-c1">1</span>)) <span class="pl-c1">8</span> ── goto <span class="pl-c"><span class="pl-c">#</span>11</span> <span class="pl-c1">9</span> ── <span class="pl-k">%</span><span class="pl-c1">14</span> <span class="pl-k">=</span> φᶜ (<span class="pl-k">%</span><span class="pl-c1">10</span>)<span class="pl-k">::</span><span class="pl-c1">Int64</span> │ <span class="pl-k">%</span><span class="pl-c1">15</span> <span class="pl-k">=</span> φᶜ (<span class="pl-k">%</span><span class="pl-c1">11</span>)<span class="pl-k">::</span><span class="pl-c1">Any</span> └─── <span class="pl-k">$</span>(<span class="pl-c1">Expr</span>(<span class="pl-c1">:leave</span>, <span class="pl-c1">1</span>)) <span class="pl-c1">10</span> ─ <span class="pl-c1">nothing</span><span class="pl-k">::</span><span class="pl-c1">Nothing</span> <span class="pl-c1">6</span> <span class="pl-c1">11</span> ┄ <span class="pl-k">%</span><span class="pl-c1">18</span> <span class="pl-k">=</span> φ (<span class="pl-c"><span class="pl-c">#</span>8 =&gt; %6, #10 =&gt; %14)::Int64</span> │ <span class="pl-k">%</span><span class="pl-c1">19</span> <span class="pl-k">=</span> φ (<span class="pl-c"><span class="pl-c">#</span>8 =&gt; %7, #10 =&gt; true)::Bool</span> │ <span class="pl-k">%</span><span class="pl-c1">20</span> <span class="pl-k">=</span> φ (<span class="pl-c"><span class="pl-c">#</span>8 =&gt; %8, #10 =&gt; %15)::Core.Compiler.MaybeUndef(Any)</span> │ <span class="pl-k">%</span><span class="pl-c1">21</span> <span class="pl-k">=</span> (<span class="pl-k">%</span><span class="pl-c1">18</span> <span class="pl-k">===</span> <span class="pl-c1">2</span>)<span class="pl-k">::</span><span class="pl-c1">Bool</span> └─── goto <span class="pl-c"><span class="pl-c">#</span>13 if not %21</span> <span class="pl-c1">12</span> ─ <span class="pl-k">$</span>(<span class="pl-c1">Expr</span>(<span class="pl-c1">:throw_undef_if_not</span>, <span class="pl-c1">Symbol</span>(<span class="pl-s"><span class="pl-pds">"</span>#temp#<span class="pl-pds">"</span></span>), :(<span class="pl-k">%</span><span class="pl-c1">19</span>)))<span class="pl-k">::</span><span class="pl-c1">Any</span> │ <span class="pl-k">$</span>(<span class="pl-c1">Expr</span>(<span class="pl-c1">:foreigncall</span>, :(<span class="pl-c1">:jl_rethrow_other</span>), Union{}, <span class="pl-c1">svec</span>(Any), :(<span class="pl-c1">:ccall</span>), <span class="pl-c1">1</span>, :(<span class="pl-k">%</span><span class="pl-c1">20</span>)))<span class="pl-k">::</span><span class="pl-c1">Union{}</span> └─── unreachable <span class="pl-c1">13</span> ─ <span class="pl-k">return</span> <span class="pl-c1">nothing</span></pre></div> <p dir="auto">IIUC, the <code class="notranslate"> $(Expr(:enter, #9))</code> should terminate that block with these successors.</p>
<p dir="auto">Repro, build <code class="notranslate">julia-debug</code>. Run:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; try finally try catch end end Block 6 successors (Array{Int64, (2,)}[9, 7]), does not match fall-through terminator Internal error: encountered unexpected error in runtime: MethodError(f=typeof(Base.string)(), args=(), world=0x0000000000000e78) rec_backtrace at /Users/kristoffer/julia/src/stackwalk.c:94 record_backtrace at /Users/kristoffer/julia/src/task.c:246 jl_throw at /Users/kristoffer/julia/src/task.c:577 jl_method_error_bare at /Users/kristoffer/julia/src/gf.c:1597 jl_method_error at /Users/kristoffer/julia/src/gf.c:1615 jl_lookup_generic_ at /Users/kristoffer/julia/src/gf.c:2142 jl_apply_generic at /Users/kristoffer/julia/src/gf.c:2162 error at ./error.jl:42 jl_fptr_args at /Users/kristoffer/julia/src/gf.c:1822 jl_invoke at /Users/kristoffer/julia/src/gf.c:42 verify_ir at ./compiler/ssair/verify.jl:110 run_passes at ./compiler/ssair/driver.jl:132 optimize at ./compiler/optimize.jl:162 typeinf at ./compiler/typeinfer.jl:35 typeinf_ext at ./compiler/typeinfer.jl:611 jfptr_typeinf_ext_58 at /Users/kristoffer/julia/usr/lib/julia/sys-debug.dylib (unknown line) jl_apply_generic at /Users/kristoffer/julia/src/gf.c:2165 jl_apply at /Users/kristoffer/julia/src/./julia.h:1538 jl_apply_with_saved_exception_state at /Users/kristoffer/julia/src/rtutils.c:257 jl_type_infer at /Users/kristoffer/julia/src/gf.c:275 jl_toplevel_eval_flex at /Users/kristoffer/julia/src/toplevel.c:822 jl_toplevel_eval at /Users/kristoffer/julia/src/toplevel.c:840 jl_toplevel_eval_in at /Users/kristoffer/julia/src/builtins.c:633 eval at ./boot.jl:319 jl_fptr_args at /Users/kristoffer/julia/src/gf.c:1822 jl_apply_generic at /Users/kristoffer/julia/src/gf.c:2165 eval_user_input at /Users/kristoffer/julia/usr/share/julia/stdlib/v0.7/REPL/src/REPL.jl:87 macro expansion at /Users/kristoffer/julia/usr/share/julia/stdlib/v0.7/REPL/src/REPL.jl:119 [inlined] #28 at ./task.jl:262 jl_fptr_args at /Users/kristoffer/julia/src/gf.c:1822 jl_fptr_trampoline at /Users/kristoffer/julia/src/gf.c:1812 jl_apply_generic at /Users/kristoffer/julia/src/gf.c:2165 jl_apply at /Users/kristoffer/julia/src/./julia.h:1538 start_task at /Users/kristoffer/julia/src/task.c:268"><pre class="notranslate"><code class="notranslate">julia&gt; try finally try catch end end Block 6 successors (Array{Int64, (2,)}[9, 7]), does not match fall-through terminator Internal error: encountered unexpected error in runtime: MethodError(f=typeof(Base.string)(), args=(), world=0x0000000000000e78) rec_backtrace at /Users/kristoffer/julia/src/stackwalk.c:94 record_backtrace at /Users/kristoffer/julia/src/task.c:246 jl_throw at /Users/kristoffer/julia/src/task.c:577 jl_method_error_bare at /Users/kristoffer/julia/src/gf.c:1597 jl_method_error at /Users/kristoffer/julia/src/gf.c:1615 jl_lookup_generic_ at /Users/kristoffer/julia/src/gf.c:2142 jl_apply_generic at /Users/kristoffer/julia/src/gf.c:2162 error at ./error.jl:42 jl_fptr_args at /Users/kristoffer/julia/src/gf.c:1822 jl_invoke at /Users/kristoffer/julia/src/gf.c:42 verify_ir at ./compiler/ssair/verify.jl:110 run_passes at ./compiler/ssair/driver.jl:132 optimize at ./compiler/optimize.jl:162 typeinf at ./compiler/typeinfer.jl:35 typeinf_ext at ./compiler/typeinfer.jl:611 jfptr_typeinf_ext_58 at /Users/kristoffer/julia/usr/lib/julia/sys-debug.dylib (unknown line) jl_apply_generic at /Users/kristoffer/julia/src/gf.c:2165 jl_apply at /Users/kristoffer/julia/src/./julia.h:1538 jl_apply_with_saved_exception_state at /Users/kristoffer/julia/src/rtutils.c:257 jl_type_infer at /Users/kristoffer/julia/src/gf.c:275 jl_toplevel_eval_flex at /Users/kristoffer/julia/src/toplevel.c:822 jl_toplevel_eval at /Users/kristoffer/julia/src/toplevel.c:840 jl_toplevel_eval_in at /Users/kristoffer/julia/src/builtins.c:633 eval at ./boot.jl:319 jl_fptr_args at /Users/kristoffer/julia/src/gf.c:1822 jl_apply_generic at /Users/kristoffer/julia/src/gf.c:2165 eval_user_input at /Users/kristoffer/julia/usr/share/julia/stdlib/v0.7/REPL/src/REPL.jl:87 macro expansion at /Users/kristoffer/julia/usr/share/julia/stdlib/v0.7/REPL/src/REPL.jl:119 [inlined] #28 at ./task.jl:262 jl_fptr_args at /Users/kristoffer/julia/src/gf.c:1822 jl_fptr_trampoline at /Users/kristoffer/julia/src/gf.c:1812 jl_apply_generic at /Users/kristoffer/julia/src/gf.c:2165 jl_apply at /Users/kristoffer/julia/src/./julia.h:1538 start_task at /Users/kristoffer/julia/src/task.c:268 </code></pre></div> <p dir="auto">Changing the <code class="notranslate">finally</code> to <code class="notranslate">catch</code>makes it go away.</p>
1
<p dir="auto">Hi,</p> <p dir="auto">The new <code class="notranslate">text-left</code>, <code class="notranslate">text-center</code> and <code class="notranslate">text-right</code> classes doesn't work on the table cells. Maybe it would be nice to add an <code class="notranslate">!important</code> hack to force alignment ?</p>
<p dir="auto">Bootstrap also defined an extension functions named "tabs" which is same as the one provided by jQuery UI. So referencing to both jQuery UI and bootstrap will cause unexpected behaviors on the tabs. I think this issue is kind of related to issue <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="1591888" data-permission-text="Title is private" data-url="https://github.com/twbs/bootstrap/issues/171" data-hovercard-type="issue" data-hovercard-url="/twbs/bootstrap/issues/171/hovercard" href="https://github.com/twbs/bootstrap/issues/171">#171</a>, somehow it's more about styles, but this is about javascript namespace. Maybe limit the scope of bootstrap functions by namespace will be a good idea. Thanks.</p>
0
<div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="module M1 type T1 y end foo(x::Int) = 10 foo(x::T1) = foo(x.y) end @show code_typed(M1.foo, (M1.T1,))"><pre class="notranslate"><span class="pl-k">module</span> M1 type T1 y <span class="pl-k">end</span> <span class="pl-en">foo</span>(x<span class="pl-k">::</span><span class="pl-c1">Int</span>) <span class="pl-k">=</span> <span class="pl-c1">10</span> <span class="pl-en">foo</span>(x<span class="pl-k">::</span><span class="pl-c1">T1</span>) <span class="pl-k">=</span> <span class="pl-c1">foo</span>(x<span class="pl-k">.</span>y) <span class="pl-k">end</span> <span class="pl-c1">@show</span> <span class="pl-c1">code_typed</span>(M1<span class="pl-k">.</span>foo, (M1<span class="pl-k">.</span>T1,))</pre></div> <p dir="auto">gives</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="code_typed(M1.foo,(M1.T1,)) = Any[:($(Expr(:lambda, Any[:x], Any[Any[],Any[Any[:x,M1.T1,0]],Any[]], :(begin # /home/mlubin/test2.jl, line 8: return foo((top(getfield))(x::M1.T1,:y))::Int64 end::Int64))))]"><pre class="notranslate"><code class="notranslate">code_typed(M1.foo,(M1.T1,)) = Any[:($(Expr(:lambda, Any[:x], Any[Any[],Any[Any[:x,M1.T1,0]],Any[]], :(begin # /home/mlubin/test2.jl, line 8: return foo((top(getfield))(x::M1.T1,:y))::Int64 end::Int64))))] </code></pre></div> <p dir="auto">on Julia 0.4.</p> <p dir="auto">This is incorrect, we can't infer anything about the return type here, since <code class="notranslate">foo</code> could be extended later and <code class="notranslate">x.y</code> doesn't need to be an <code class="notranslate">Int</code>.</p>
<p dir="auto">if I define a function d2 before a function d1 which calls d2 then change d2, d1 uses the old definition for d2.<br> I assume this is because it is all precompiled, but maybe there should be a note warning of this? Or would it be possible to replace the old definition with a longjmp to the new one?<br> (Mostly important for the REPL, since I don't always do a full load)</p> <div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="julia&gt; function d2() a end julia&gt; function d() d2() end julia&gt; d() in d: a not defined julia&gt; function d2() b=2 end julia&gt; d() in d: a not defined julia&gt; d2 Methods for generic function d2 d2() at prompt:2 julia&gt; function d() d2() end julia&gt; d() 2"><pre class="notranslate">julia<span class="pl-k">&gt;</span> <span class="pl-k">function</span> <span class="pl-en">d2</span>() a <span class="pl-k">end</span> julia<span class="pl-k">&gt;</span> <span class="pl-k">function</span> <span class="pl-en">d</span>() <span class="pl-c1">d2</span>() <span class="pl-k">end</span> julia<span class="pl-k">&gt;</span> <span class="pl-c1">d</span>() in d<span class="pl-k">:</span> a not defined julia<span class="pl-k">&gt;</span> <span class="pl-k">function</span> <span class="pl-en">d2</span>() b<span class="pl-k">=</span><span class="pl-c1">2</span> <span class="pl-k">end</span> julia<span class="pl-k">&gt;</span> <span class="pl-c1">d</span>() in d<span class="pl-k">:</span> a not defined julia<span class="pl-k">&gt;</span> d2 Methods <span class="pl-k">for</span> generic <span class="pl-k">function</span> d2 <span class="pl-c1">d2</span>() at prompt<span class="pl-k">:</span><span class="pl-c1">2</span> julia<span class="pl-k">&gt;</span> <span class="pl-k">function</span> <span class="pl-en">d</span>() <span class="pl-c1">d2</span>() <span class="pl-k">end</span> julia<span class="pl-k">&gt;</span> <span class="pl-c1">d</span>() <span class="pl-c1">2</span></pre></div>
1
<p dir="auto">scipy 1.0.1, Anaconda 5, Linux 64 bit</p> <p dir="auto">When y is a N-dimensional array, I would expect interp1d to work independently on each series.<br> When invoked with <code class="notranslate">kind='quadratic'</code> or <code class="notranslate">kind='cubic'</code>, however, if <em>any</em> series contains NaNs then the interpolated values of <em>all</em> series will be NaN:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import numpy from scipy.interpolate import * x = numpy.arange(0, 8, 1) y = numpy.stack([numpy.arange(0, 80, 10), numpy.full((8, ), numpy.nan)], axis=1) print(&quot;x =&quot;, x) print(&quot;y =&quot;, y) for kind in ('nearest', 'linear', 'zero', 'slinear', 'quadratic', 'cubic'): print(kind + ' =', interp1d(x, y, axis=0, kind=kind)(4.5)) print(&quot;Akima =&quot;, Akima1DInterpolator(x, y, axis=0)(4.5)) print(&quot;PCHIP =&quot;, PchipInterpolator(x, y, axis=0)(4.5))"><pre class="notranslate"><code class="notranslate">import numpy from scipy.interpolate import * x = numpy.arange(0, 8, 1) y = numpy.stack([numpy.arange(0, 80, 10), numpy.full((8, ), numpy.nan)], axis=1) print("x =", x) print("y =", y) for kind in ('nearest', 'linear', 'zero', 'slinear', 'quadratic', 'cubic'): print(kind + ' =', interp1d(x, y, axis=0, kind=kind)(4.5)) print("Akima =", Akima1DInterpolator(x, y, axis=0)(4.5)) print("PCHIP =", PchipInterpolator(x, y, axis=0)(4.5)) </code></pre></div> <p dir="auto">Output:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="x = [0 1 2 3 4 5 6 7] y = [[ 0. nan] [10. nan] [20. nan] [30. nan] [40. nan] [50. nan] [60. nan] [70. nan]] nearest = [40. nan] linear = [45. nan] zero = [40. nan] slinear = [45. nan] quadratic = [nan nan] cubic = [nan nan] Akima = [45. nan] PCHIP = [45. nan]"><pre class="notranslate"><code class="notranslate">x = [0 1 2 3 4 5 6 7] y = [[ 0. nan] [10. nan] [20. nan] [30. nan] [40. nan] [50. nan] [60. nan] [70. nan]] nearest = [40. nan] linear = [45. nan] zero = [40. nan] slinear = [45. nan] quadratic = [nan nan] cubic = [nan nan] Akima = [45. nan] PCHIP = [45. nan] </code></pre></div>
<p dir="auto">Hi,</p> <p dir="auto">I have a request for the following case. Let's say I have a N-Dimensional vector of features for each timestamp in a time-series. So a N+1 dimensional data cube. I want to interpolate each feature, side-by-side in the direction of the time-series (1D interpolation).</p> <p dir="auto">Currently the <code class="notranslate">scipy.interpolate.interp1d</code> allows for the side-by-side interpolation of a N-dimensional array in one specific direction, which is great.<br> However, in case you have missing (NaN) data randomly distributed over the N+1-dimensional time-series, this then doesn't apply anymore but is often the case.</p> <p dir="auto">One option is to add the time-series also as a N+1-dimensional array, corresponding to the data values. Currently, this would then be like interpolation with grid data, but that is the multi-dimensional interpolation, It would be good to have this option also for 1D interpolation (single direction)</p> <p dir="auto">Another option would be by adding some sort of a mask, or boolean weights to the interp1d function, which would be the same shape as the data array, specifying which data points to actually take into account.</p> <p dir="auto">Option number 3 would be to add a value which should be ignored and not taken into account in the interpolation, this seems the easiest.</p> <p dir="auto">I would greatly appreciate this, coming as someone in the field of earth-observation, where missing data is very common.</p> <p dir="auto">Regards,<br> Matic</p>
1
<p dir="auto">First of all, sorry about the title! I can't really summarize the problem in a good way (if anyone can change it to a better one, then, please, be my guest!).</p> <p dir="auto">I was trying to optimize a toolbox I was coding and I had a very strange type warnings using <code class="notranslate">@code_warntype</code>. I posted the problem on discourse to verify if I was doing something wrong [1] with global declaration of constants.</p> <p dir="auto">It turns out that <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/tkoolen/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/tkoolen">@tkoolen</a> and <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/StefanKarpinski/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/StefanKarpinski">@StefanKarpinski</a> identified a bigger problem (that I cannot really describe in technical detail) and asked to open an issue.</p> <p dir="auto">Consider the following code:</p> <div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="VERSION &gt;= v&quot;0.4.0-dev+6521&quot; &amp;&amp; __precompile__() module TestConst export test function test(n::Number, e::Number) # Auxiliary constant to compute the functions. K1 = 3.0 # Declare the functions that must solved for 0. f1(a, i) = K1 end end"><pre class="notranslate"><span class="pl-c1">VERSION</span> <span class="pl-k">&gt;=</span> <span class="pl-s"><span class="pl-pds"><span class="pl-c1">v</span>"</span>0.4.0-dev+6521<span class="pl-pds">"</span></span> <span class="pl-k">&amp;&amp;</span> <span class="pl-c1">__precompile__</span>() <span class="pl-k">module</span> TestConst <span class="pl-k">export</span> test <span class="pl-k">function</span> <span class="pl-en">test</span>(n<span class="pl-k">::</span><span class="pl-c1">Number</span>, e<span class="pl-k">::</span><span class="pl-c1">Number</span>) <span class="pl-c"><span class="pl-c">#</span> Auxiliary constant to compute the functions.</span> K1 <span class="pl-k">=</span> <span class="pl-c1">3.0</span> <span class="pl-c"><span class="pl-c">#</span> Declare the functions that must solved for 0.</span> <span class="pl-en">f1</span>(a, i) <span class="pl-k">=</span> K1 <span class="pl-k">end</span> <span class="pl-k">end</span></pre></div> <p dir="auto">If I analyze the type using <code class="notranslate">@code_warntype test(1,1)</code>, then I get:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Variables: #self# &lt;optimized out&gt; n &lt;optimized out&gt; e &lt;optimized out&gt; K1 &lt;optimized out&gt; f1::TestConst.#f1#1{Float64} Body: begin # line 12: f1::TestConst.#f1#1{Float64} = $(Expr(:new, TestConst.#f1#1{Float64}, 3.0)) return f1::TestConst.#f1#1{Float64} end::TestConst.#f1#1{Float64}"><pre class="notranslate"><code class="notranslate">Variables: #self# &lt;optimized out&gt; n &lt;optimized out&gt; e &lt;optimized out&gt; K1 &lt;optimized out&gt; f1::TestConst.#f1#1{Float64} Body: begin # line 12: f1::TestConst.#f1#1{Float64} = $(Expr(:new, TestConst.#f1#1{Float64}, 3.0)) return f1::TestConst.#f1#1{Float64} end::TestConst.#f1#1{Float64} </code></pre></div> <p dir="auto">However, consider the following code in which a check of the variable <code class="notranslate">n</code> is added:</p> <div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="VERSION &gt;= v&quot;0.4.0-dev+6521&quot; &amp;&amp; __precompile__() module TestConst export test function test(n::Number, e::Number) if (n &lt;= 0) throw(ArgumentError(&quot;The angular velocity must be greater than 0.&quot;)) end # Auxiliary constant to compute the functions. K1 = 3.0 # Declare the functions that must solved for 0. f1(a, i) = K1 end end"><pre class="notranslate"><span class="pl-c1">VERSION</span> <span class="pl-k">&gt;=</span> <span class="pl-s"><span class="pl-pds"><span class="pl-c1">v</span>"</span>0.4.0-dev+6521<span class="pl-pds">"</span></span> <span class="pl-k">&amp;&amp;</span> <span class="pl-c1">__precompile__</span>() <span class="pl-k">module</span> TestConst <span class="pl-k">export</span> test <span class="pl-k">function</span> <span class="pl-en">test</span>(n<span class="pl-k">::</span><span class="pl-c1">Number</span>, e<span class="pl-k">::</span><span class="pl-c1">Number</span>) <span class="pl-k">if</span> (n <span class="pl-k">&lt;=</span> <span class="pl-c1">0</span>) <span class="pl-c1">throw</span>(<span class="pl-c1">ArgumentError</span>(<span class="pl-s"><span class="pl-pds">"</span>The angular velocity must be greater than 0.<span class="pl-pds">"</span></span>)) <span class="pl-k">end</span> <span class="pl-c"><span class="pl-c">#</span> Auxiliary constant to compute the functions.</span> K1 <span class="pl-k">=</span> <span class="pl-c1">3.0</span> <span class="pl-c"><span class="pl-c">#</span> Declare the functions that must solved for 0.</span> <span class="pl-en">f1</span>(a, i) <span class="pl-k">=</span> K1 <span class="pl-k">end</span> <span class="pl-k">end</span></pre></div> <p dir="auto">In this case, I see problems about the type:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Variables: #self# &lt;optimized out&gt; n::Int64 e &lt;optimized out&gt; K1::Core.Box f1::TestConst.#f1#1 Body: begin K1::Core.Box = $(Expr(:new, :(Core.Box))) NewvarNode(:(f1::TestConst.#f1#1)) unless (Base.sle_int)(n::Int64, 0)::Bool goto 6 # line 9: (TestConst.throw)($(Expr(:new, :(Base.ArgumentError), &quot;The angular velocity must be greater than 0.&quot;)))::Union{} 6: # line 13: (Core.setfield!)(K1::Core.Box, :contents, 3.0)::Float64 # line 16: f1::TestConst.#f1#1 = $(Expr(:new, :(TestConst.#f1#1), :(K1))) return f1::TestConst.#f1#1 end::TestConst.#f1#1"><pre class="notranslate"><code class="notranslate">Variables: #self# &lt;optimized out&gt; n::Int64 e &lt;optimized out&gt; K1::Core.Box f1::TestConst.#f1#1 Body: begin K1::Core.Box = $(Expr(:new, :(Core.Box))) NewvarNode(:(f1::TestConst.#f1#1)) unless (Base.sle_int)(n::Int64, 0)::Bool goto 6 # line 9: (TestConst.throw)($(Expr(:new, :(Base.ArgumentError), "The angular velocity must be greater than 0.")))::Union{} 6: # line 13: (Core.setfield!)(K1::Core.Box, :contents, 3.0)::Float64 # line 16: f1::TestConst.#f1#1 = $(Expr(:new, :(TestConst.#f1#1), :(K1))) return f1::TestConst.#f1#1 end::TestConst.#f1#1 </code></pre></div> <p dir="auto">I performed a simple benchmark on both version using:</p> <div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="@time for k=1:1000000000 test(1,1) end"><pre class="notranslate"><span class="pl-c1">@time</span> <span class="pl-k">for</span> k<span class="pl-k">=</span><span class="pl-c1">1</span><span class="pl-k">:</span><span class="pl-c1">1000000000</span> <span class="pl-c1">test</span>(<span class="pl-c1">1</span>,<span class="pl-c1">1</span>) <span class="pl-k">end</span></pre></div> <p dir="auto">The result was <code class="notranslate">0.93s</code> for the first algorithm and <code class="notranslate">18s</code> for the second one.</p> <hr> <h1 dir="auto">References</h1> <p dir="auto">[1] <a href="https://discourse.julialang.org/t/correct-way-to-declare-global-constant-in-modules/10234/6" rel="nofollow">https://discourse.julialang.org/t/correct-way-to-declare-global-constant-in-modules/10234/6</a></p>
<p dir="auto">Hi,<br> I'm getting the error below from a fresh installation of julia-1.7.0beta2 on powerpc. ChainRulesCore loads fine, the error only occurs with <code class="notranslate">using CUDA</code></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; using CUDA [ Info: Precompiling CUDA [052768ef-5323-5732-b1bb-66c8b64840ba] WARNING: Method definition (::ChainRulesCore.Thunk{F})() in module ChainRulesCore at /home/rkube/.julia/packages/ChainRulesCore/EgLlm/src/deprecated.jl:52 overwritten on the same line (check for duplicate calls to `include`). ** incremental compilation may be fatally broken for this module ** WARNING: Method definition (::ChainRulesCore.InplaceableThunk{T&lt;:(ChainRulesCore.Thunk{F} where F), F})() in module ChainRulesCore at /home/rkube/.julia/packages/ChainRulesCore/EgLlm/src/deprecated.jl:52 overwritten on the same line (check for duplicate calls to `include`). ** incremental compilation may be fatally broken for this module ** ERROR: LoadError: TypeError: in Atomic, in T, expected T&lt;:Union{Bool, Int16, Int32, Int64, Int8, UInt16, UInt32, UInt64, UInt8}, got Type{Float64} Stacktrace: [1] top-level scope @ ~/.julia/packages/CUDA/Ozu5O/src/pool.jl:450 [2] include(mod::Module, _path::String) @ Base ./Base.jl:417 [3] include(x::String) @ CUDA ~/.julia/packages/CUDA/Ozu5O/src/CUDA.jl:1 [4] top-level scope @ ~/.julia/packages/CUDA/Ozu5O/src/CUDA.jl:67 [5] include @ ./Base.jl:417 [inlined] [6] include_package_for_output(pkg::Base.PkgId, input::String, depot_path::Vector{String}, dl_load_path::Vector{String}, load_path::Vector{String}, concrete_deps::Vector{Pair{Base.PkgId, UInt64}}, source::Nothing) @ Base ./loading.jl:1318 [7] top-level scope @ none:1 [8] eval @ ./boot.jl:373 [inlined] [9] eval(x::Expr) @ Base.MainInclude ./client.jl:453 [10] top-level scope @ none:1 in expression starting at /home/rkube/.julia/packages/CUDA/Ozu5O/src/pool.jl:450 in expression starting at /home/rkube/.julia/packages/CUDA/Ozu5O/src/CUDA.jl:1 ERROR: Failed to precompile CUDA [052768ef-5323-5732-b1bb-66c8b64840ba] to /home/rkube/.julia/compiled/v1.7/CUDA/jl_TuxLx5. Stacktrace: [1] error(s::String) @ Base ./error.jl:33 [2] compilecache(pkg::Base.PkgId, path::String, internal_stderr::IO, internal_stdout::IO, ignore_loaded_modules::Bool) @ Base ./loading.jl:1466 [3] compilecache(pkg::Base.PkgId, path::String) @ Base ./loading.jl:1410 [4] _require(pkg::Base.PkgId) @ Base ./loading.jl:1120 [5] require(uuidkey::Base.PkgId) @ Base ./loading.jl:1013 [6] require(into::Module, mod::Symbol) @ Base ./loading.jl:997 "><pre class="notranslate"><code class="notranslate">julia&gt; using CUDA [ Info: Precompiling CUDA [052768ef-5323-5732-b1bb-66c8b64840ba] WARNING: Method definition (::ChainRulesCore.Thunk{F})() in module ChainRulesCore at /home/rkube/.julia/packages/ChainRulesCore/EgLlm/src/deprecated.jl:52 overwritten on the same line (check for duplicate calls to `include`). ** incremental compilation may be fatally broken for this module ** WARNING: Method definition (::ChainRulesCore.InplaceableThunk{T&lt;:(ChainRulesCore.Thunk{F} where F), F})() in module ChainRulesCore at /home/rkube/.julia/packages/ChainRulesCore/EgLlm/src/deprecated.jl:52 overwritten on the same line (check for duplicate calls to `include`). ** incremental compilation may be fatally broken for this module ** ERROR: LoadError: TypeError: in Atomic, in T, expected T&lt;:Union{Bool, Int16, Int32, Int64, Int8, UInt16, UInt32, UInt64, UInt8}, got Type{Float64} Stacktrace: [1] top-level scope @ ~/.julia/packages/CUDA/Ozu5O/src/pool.jl:450 [2] include(mod::Module, _path::String) @ Base ./Base.jl:417 [3] include(x::String) @ CUDA ~/.julia/packages/CUDA/Ozu5O/src/CUDA.jl:1 [4] top-level scope @ ~/.julia/packages/CUDA/Ozu5O/src/CUDA.jl:67 [5] include @ ./Base.jl:417 [inlined] [6] include_package_for_output(pkg::Base.PkgId, input::String, depot_path::Vector{String}, dl_load_path::Vector{String}, load_path::Vector{String}, concrete_deps::Vector{Pair{Base.PkgId, UInt64}}, source::Nothing) @ Base ./loading.jl:1318 [7] top-level scope @ none:1 [8] eval @ ./boot.jl:373 [inlined] [9] eval(x::Expr) @ Base.MainInclude ./client.jl:453 [10] top-level scope @ none:1 in expression starting at /home/rkube/.julia/packages/CUDA/Ozu5O/src/pool.jl:450 in expression starting at /home/rkube/.julia/packages/CUDA/Ozu5O/src/CUDA.jl:1 ERROR: Failed to precompile CUDA [052768ef-5323-5732-b1bb-66c8b64840ba] to /home/rkube/.julia/compiled/v1.7/CUDA/jl_TuxLx5. Stacktrace: [1] error(s::String) @ Base ./error.jl:33 [2] compilecache(pkg::Base.PkgId, path::String, internal_stderr::IO, internal_stdout::IO, ignore_loaded_modules::Bool) @ Base ./loading.jl:1466 [3] compilecache(pkg::Base.PkgId, path::String) @ Base ./loading.jl:1410 [4] _require(pkg::Base.PkgId) @ Base ./loading.jl:1120 [5] require(uuidkey::Base.PkgId) @ Base ./loading.jl:1013 [6] require(into::Module, mod::Symbol) @ Base ./loading.jl:997 </code></pre></div>
0
<p dir="auto">if you have a parent/child relationship doing a query that contains a <code class="notranslate">has_child</code> will result in error:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="curl localhost:9200/_search -d '{ &quot;highlight&quot;: {&quot;fields&quot;: {&quot;title&quot;: {}}}, &quot;query&quot;: { &quot;has_child&quot;: { &quot;query&quot;: {&quot;match&quot;: {&quot;body&quot;: &quot;drip&quot;}}, &quot;type&quot;: &quot;answer&quot; } } }'"><pre class="notranslate"><code class="notranslate">curl localhost:9200/_search -d '{ "highlight": {"fields": {"title": {}}}, "query": { "has_child": { "query": {"match": {"body": "drip"}}, "type": "answer" } } }' </code></pre></div> <p dir="auto">Error returned:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="{ &quot;type&quot;:&quot;illegal_state_exception&quot;, &quot;reason&quot;:&quot;can't load global ordinals for reader of type: class org.apache.lucene.search.highlight.WeightedSpanTermExtractor$DelegatingLeafReader must be a DirectoryReader&quot; }"><pre class="notranslate"><code class="notranslate">{ "type":"illegal_state_exception", "reason":"can't load global ordinals for reader of type: class org.apache.lucene.search.highlight.WeightedSpanTermExtractor$DelegatingLeafReader must be a DirectoryReader" } </code></pre></div> <p dir="auto">Works fine on 2.0.0, fails on 2.1.0 and later.</p>
<p dir="auto">When I was upgraded es from 2.0 to 2.1, highlight feature stop working.</p> <p dir="auto">I got this error message:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="{ &quot;shard&quot;: 0, &quot;index&quot;: &quot;4odevelop_4o&quot;, &quot;node&quot;: &quot;XiZaRocLQGuBwZPg58Naqw&quot;, &quot;reason&quot;: { &quot;type&quot;: &quot;illegal_state_exception&quot;, &quot;reason&quot;: &quot;can't load global ordinals for reader of type: class org.apache.lucene.search.highlight.WeightedSpanTermExtractor$DelegatingLeafReader must be a DirectoryReader&quot; } }"><pre class="notranslate"><code class="notranslate">{ "shard": 0, "index": "4odevelop_4o", "node": "XiZaRocLQGuBwZPg58Naqw", "reason": { "type": "illegal_state_exception", "reason": "can't load global ordinals for reader of type: class org.apache.lucene.search.highlight.WeightedSpanTermExtractor$DelegatingLeafReader must be a DirectoryReader" } } </code></pre></div>
1
<p dir="auto"><strong>Do you want to request a <em>feature</em> or report a <em>bug</em>?</strong></p> <p dir="auto">I'm not quite sure if feature/bug... I have an error boundary, and I want to test that it works correctly, but it produces a big <code class="notranslate">console.error</code> and there doesn't seem a great way to get around it.</p> <p dir="auto"><strong>What is the current behavior?</strong></p> <p dir="auto">When an error is captured by the error boundary, it still logs to console during tests, making it look like something failed but it is expected (because I am testing error boundary) in this case.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" console.error node_modules/react-dom/cjs/react-dom.development.js:9747 The above error occurred in the &lt;Child&gt; component: in Child (at ErrorBoundary.test.jsx:20) in ErrorBoundary (created by WrapperComponent) in WrapperComponent React will try to recreate this component tree from scratch using the error boundary you provided, ErrorBoundary."><pre class="notranslate"><code class="notranslate"> console.error node_modules/react-dom/cjs/react-dom.development.js:9747 The above error occurred in the &lt;Child&gt; component: in Child (at ErrorBoundary.test.jsx:20) in ErrorBoundary (created by WrapperComponent) in WrapperComponent React will try to recreate this component tree from scratch using the error boundary you provided, ErrorBoundary. </code></pre></div> <p dir="auto"><strong>If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem. Your bug will get fixed much faster if we can run your code and it doesn't have dependencies other than React. Paste the link to your JSFiddle (<a href="https://jsfiddle.net/Luktwrdm/" rel="nofollow">https://jsfiddle.net/Luktwrdm/</a>) or CodeSandbox (<a href="https://codesandbox.io/s/new" rel="nofollow">https://codesandbox.io/s/new</a>) example below:</strong></p> <p dir="auto">Error Boundary:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import React from &quot;react&quot;; import PropTypes from &quot;prop-types&quot;; export default class ErrorBoundary extends React.Component { static propTypes = { children: PropTypes.oneOfType([ PropTypes.node, PropTypes.arrayOf(PropTypes.node) ]).isRequired, render: PropTypes.func.isRequired }; state = { hasError: false, error: null, errorInfo: null }; componentDidCatch(error, errorInfo) { this.setState({ hasError: true, error, errorInfo }); // if we have Bugsnag in this environment, we can notify our error tracker if (window.Bugsnag) { window.Bugsnag.notify(error); } } render() { if (this.state.hasError) { return this.props.render(this.state.error, this.state.errorInfo); } return this.props.children; } }"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-v">React</span> <span class="pl-k">from</span> <span class="pl-s">"react"</span><span class="pl-kos">;</span> <span class="pl-k">import</span> <span class="pl-v">PropTypes</span> <span class="pl-k">from</span> <span class="pl-s">"prop-types"</span><span class="pl-kos">;</span> <span class="pl-k">export</span> <span class="pl-k">default</span> <span class="pl-k">class</span> <span class="pl-v">ErrorBoundary</span> <span class="pl-k">extends</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-c1">Component</span> <span class="pl-kos">{</span> <span class="pl-k">static</span> <span class="pl-c1">propTypes</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span> <span class="pl-c1">children</span>: <span class="pl-v">PropTypes</span><span class="pl-kos">.</span><span class="pl-en">oneOfType</span><span class="pl-kos">(</span><span class="pl-kos">[</span> <span class="pl-v">PropTypes</span><span class="pl-kos">.</span><span class="pl-c1">node</span><span class="pl-kos">,</span> <span class="pl-v">PropTypes</span><span class="pl-kos">.</span><span class="pl-en">arrayOf</span><span class="pl-kos">(</span><span class="pl-v">PropTypes</span><span class="pl-kos">.</span><span class="pl-c1">node</span><span class="pl-kos">)</span> <span class="pl-kos">]</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-c1">isRequired</span><span class="pl-kos">,</span> <span class="pl-c1">render</span>: <span class="pl-v">PropTypes</span><span class="pl-kos">.</span><span class="pl-c1">func</span><span class="pl-kos">.</span><span class="pl-c1">isRequired</span> <span class="pl-kos">}</span><span class="pl-kos">;</span> <span class="pl-c1">state</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span> <span class="pl-c1">hasError</span>: <span class="pl-c1">false</span><span class="pl-kos">,</span> <span class="pl-c1">error</span>: <span class="pl-c1">null</span><span class="pl-kos">,</span> <span class="pl-c1">errorInfo</span>: <span class="pl-c1">null</span> <span class="pl-kos">}</span><span class="pl-kos">;</span> <span class="pl-en">componentDidCatch</span><span class="pl-kos">(</span><span class="pl-s1">error</span><span class="pl-kos">,</span> <span class="pl-s1">errorInfo</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-en">setState</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">hasError</span>: <span class="pl-c1">true</span><span class="pl-kos">,</span> error<span class="pl-kos">,</span> errorInfo <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-c">// if we have Bugsnag in this environment, we can notify our error tracker</span> <span class="pl-k">if</span> <span class="pl-kos">(</span><span class="pl-smi">window</span><span class="pl-kos">.</span><span class="pl-c1">Bugsnag</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-smi">window</span><span class="pl-kos">.</span><span class="pl-c1">Bugsnag</span><span class="pl-kos">.</span><span class="pl-en">notify</span><span class="pl-kos">(</span><span class="pl-s1">error</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-en">render</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">if</span> <span class="pl-kos">(</span><span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">state</span><span class="pl-kos">.</span><span class="pl-c1">hasError</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">return</span> <span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">props</span><span class="pl-kos">.</span><span class="pl-en">render</span><span class="pl-kos">(</span><span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">state</span><span class="pl-kos">.</span><span class="pl-c1">error</span><span class="pl-kos">,</span> <span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">state</span><span class="pl-kos">.</span><span class="pl-c1">errorInfo</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-k">return</span> <span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">props</span><span class="pl-kos">.</span><span class="pl-c1">children</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span></pre></div> <p dir="auto">ErrorBoundary.test.jsx</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import ErrorBoundary from &quot;./ErrorBoundary&quot;; const Child = () =&gt; { throw &quot;error&quot;; }; it(&quot;catches error and renders message&quot;, () =&gt; { const wrapper = mount( &lt;ErrorBoundary render={() =&gt; &lt;div&gt;Error has occurred&lt;/div&gt;}&gt; &lt;Child /&gt; &lt;/ErrorBoundary&gt; ); expect(wrapper.text()).toEqual(&quot;Error has occurred&quot;); });"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-v">ErrorBoundary</span> <span class="pl-k">from</span> <span class="pl-s">"./ErrorBoundary"</span><span class="pl-kos">;</span> <span class="pl-k">const</span> <span class="pl-v">Child</span> <span class="pl-c1">=</span> <span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-k">throw</span> <span class="pl-s">"error"</span><span class="pl-kos">;</span> <span class="pl-kos">}</span><span class="pl-kos">;</span> <span class="pl-en">it</span><span class="pl-kos">(</span><span class="pl-s">"catches error and renders message"</span><span class="pl-kos">,</span> <span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-k">const</span> <span class="pl-s1">wrapper</span> <span class="pl-c1">=</span> <span class="pl-en">mount</span><span class="pl-kos">(</span> <span class="pl-c1">&lt;</span><span class="pl-ent">ErrorBoundary</span> <span class="pl-c1">render</span><span class="pl-c1">=</span><span class="pl-kos">{</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-ent">div</span><span class="pl-c1">&gt;</span>Error has occurred<span class="pl-c1">&lt;</span><span class="pl-c1">/</span><span class="pl-ent">div</span><span class="pl-c1">&gt;</span><span class="pl-kos">}</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-v">Child</span> <span class="pl-c1">/</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-c1">/</span><span class="pl-ent">ErrorBoundary</span><span class="pl-c1">&gt;</span> <span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">expect</span><span class="pl-kos">(</span><span class="pl-s1">wrapper</span><span class="pl-kos">.</span><span class="pl-en">text</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">toEqual</span><span class="pl-kos">(</span><span class="pl-s">"Error has occurred"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <p dir="auto"><strong>What is the expected behavior?</strong></p> <p dir="auto">I'm not sure exactly... here is a way I can sort of temporarily pause <code class="notranslate">console.error</code> logging during the course of the test, but it seems messy. How should error boundaries be tested?</p> <p dir="auto">Here is a <em>hacky</em> solution:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import ErrorBoundary from &quot;./ErrorBoundary&quot;; const Child = () =&gt; { throw &quot;error&quot;; }; const pauseErrorLogging = codeToRun =&gt; { const logger = console.error; console.error = () =&gt; {}; codeToRun(); console.error = logger; }; it(&quot;catches error and renders message&quot;, () =&gt; { pauseErrorLogging(() =&gt; { const wrapper = mount( &lt;ErrorBoundary render={() =&gt; &lt;div&gt;Error has occurred&lt;/div&gt;}&gt; &lt;Child /&gt; &lt;/ErrorBoundary&gt; ); expect(wrapper.text()).toEqual(&quot;Error has occurred&quot;); }); });"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-v">ErrorBoundary</span> <span class="pl-k">from</span> <span class="pl-s">"./ErrorBoundary"</span><span class="pl-kos">;</span> <span class="pl-k">const</span> <span class="pl-v">Child</span> <span class="pl-c1">=</span> <span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-k">throw</span> <span class="pl-s">"error"</span><span class="pl-kos">;</span> <span class="pl-kos">}</span><span class="pl-kos">;</span> <span class="pl-k">const</span> <span class="pl-en">pauseErrorLogging</span> <span class="pl-c1">=</span> <span class="pl-s1">codeToRun</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-k">const</span> <span class="pl-s1">logger</span> <span class="pl-c1">=</span> <span class="pl-smi">console</span><span class="pl-kos">.</span><span class="pl-c1">error</span><span class="pl-kos">;</span> <span class="pl-smi">console</span><span class="pl-kos">.</span><span class="pl-en">error</span> <span class="pl-c1">=</span> <span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span><span class="pl-kos">}</span><span class="pl-kos">;</span> <span class="pl-en">codeToRun</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-smi">console</span><span class="pl-kos">.</span><span class="pl-c1">error</span> <span class="pl-c1">=</span> <span class="pl-s1">logger</span><span class="pl-kos">;</span> <span class="pl-kos">}</span><span class="pl-kos">;</span> <span class="pl-en">it</span><span class="pl-kos">(</span><span class="pl-s">"catches error and renders message"</span><span class="pl-kos">,</span> <span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-en">pauseErrorLogging</span><span class="pl-kos">(</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-k">const</span> <span class="pl-s1">wrapper</span> <span class="pl-c1">=</span> <span class="pl-en">mount</span><span class="pl-kos">(</span> <span class="pl-c1">&lt;</span><span class="pl-ent">ErrorBoundary</span> <span class="pl-c1">render</span><span class="pl-c1">=</span><span class="pl-kos">{</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-ent">div</span><span class="pl-c1">&gt;</span>Error has occurred<span class="pl-c1">&lt;</span><span class="pl-c1">/</span><span class="pl-ent">div</span><span class="pl-c1">&gt;</span><span class="pl-kos">}</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-v">Child</span> <span class="pl-c1">/</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-c1">/</span><span class="pl-ent">ErrorBoundary</span><span class="pl-c1">&gt;</span> <span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">expect</span><span class="pl-kos">(</span><span class="pl-s1">wrapper</span><span class="pl-kos">.</span><span class="pl-en">text</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">toEqual</span><span class="pl-kos">(</span><span class="pl-s">"Error has occurred"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <p dir="auto"><strong>Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?</strong></p> <p dir="auto">16.2 (with enzyme 3.3)</p>
<hr> <p dir="auto"><strong>(This is a repost of <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="262802629" data-permission-text="Title is private" data-url="https://github.com/jestjs/jest/issues/4597" data-hovercard-type="issue" data-hovercard-url="/jestjs/jest/issues/4597/hovercard" href="https://github.com/jestjs/jest/issues/4597">jestjs/jest#4597</a> by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/erikras/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/erikras">@erikras</a>.)</strong></p> <hr> <p dir="auto"><strong>Do you want to request a <em>feature</em> or report a <em>bug</em>?</strong></p> <p dir="auto">Somewhere in between?</p> <p dir="auto"><strong>What is the current behavior?</strong></p> <p dir="auto">When I'm running tests on <a href="https://github.com/erikras/redux-form">my library</a>, there are some behaviors that I want to test <em>do</em> throw an error. These currently result in:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Consider adding an error boundary to your tree to customize error handling behavior. You can learn more about error boundaries at https://fb.me/react-error-boundaries."><pre class="notranslate"><code class="notranslate">Consider adding an error boundary to your tree to customize error handling behavior. You can learn more about error boundaries at https://fb.me/react-error-boundaries. </code></pre></div> <p dir="auto">...being output to the console. This error is great in an application, but not so great for a library test.</p> <p dir="auto"><strong>What is the expected behavior?</strong></p> <p dir="auto">It would be great if I could do something like:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="expect(() =&gt; { TestUtils.renderIntoDocument(&lt;DoSomething naughty/&gt;) }) .toThrow(/Bad developer!/) .andCatch() // &lt;---- prevents React 16 error boundary warning"><pre class="notranslate"><span class="pl-en">expect</span><span class="pl-kos">(</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-v">TestUtils</span><span class="pl-kos">.</span><span class="pl-en">renderIntoDocument</span><span class="pl-kos">(</span><span class="pl-c1">&lt;</span><span class="pl-ent">DoSomething</span> <span class="pl-c1">naughty</span><span class="pl-c1">/</span><span class="pl-c1">&gt;</span><span class="pl-kos">)</span> <span class="pl-kos">}</span><span class="pl-kos">)</span> <span class="pl-kos">.</span><span class="pl-en">toThrow</span><span class="pl-kos">(</span><span class="pl-pds"><span class="pl-c1">/</span>Bad developer!<span class="pl-c1">/</span></span><span class="pl-kos">)</span> <span class="pl-kos">.</span><span class="pl-en">andCatch</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c">// &lt;---- prevents React 16 error boundary warning</span></pre></div> <p dir="auto"><strong>Please provide your exact Jest configuration and mention your Jest, node, yarn/npm version and operating system.</strong></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="jest@21.2.1 react@16.0.0 react-dom@16.0.0"><pre class="notranslate"><code class="notranslate">jest@21.2.1 react@16.0.0 react-dom@16.0.0 </code></pre></div> <p dir="auto"><strong>See also</strong></p> <ul dir="auto"> <li><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="262782704" data-permission-text="Title is private" data-url="https://github.com/facebook/react/issues/11083" data-hovercard-type="issue" data-hovercard-url="/facebook/react/issues/11083/hovercard" href="https://github.com/facebook/react/issues/11083">#11083</a></li> <li><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="250734072" data-permission-text="Title is private" data-url="https://github.com/facebook/react/issues/10474" data-hovercard-type="issue" data-hovercard-url="/facebook/react/issues/10474/hovercard?comment_id=334164834&amp;comment_type=issue_comment" href="https://github.com/facebook/react/issues/10474#issuecomment-334164834">#10474 (comment)</a></li> </ul>
1
<p dir="auto">It appears commit <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/psf/requests/commit/329a5cfdd4500fb1ce405a3242ef95f9197d24ba/hovercard" href="https://github.com/psf/requests/commit/329a5cfdd4500fb1ce405a3242ef95f9197d24ba"><tt>329a5cf</tt></a> has broken <code class="notranslate">_basic_auth_str</code> and it now throws an exception <code class="notranslate">TypeError</code> (see below) when the supplied username and password is <code class="notranslate">None</code>.</p> <p dir="auto">Befor this commit, in requests 2.1.1, it was possible to supply None values for username and password when authentication is optional - in this particular case Home Assistant writing to InfluxDB with default configuration.</p> <p dir="auto">Exception thrown:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="TypeError: sequence item 0: expected a bytes-like object, NoneType found"><pre class="notranslate"><span class="pl-v">TypeError</span>: <span class="pl-s1">sequence</span> <span class="pl-s1">item</span> <span class="pl-c1">0</span>: <span class="pl-s1">expected</span> <span class="pl-s1">a</span> <span class="pl-s1">bytes</span><span class="pl-c1">-</span><span class="pl-s1">like</span> <span class="pl-s1">object</span>, <span class="pl-v">NoneType</span> <span class="pl-s1">found</span></pre></div>
<p dir="auto">Possibly just a previously quirkly behavior that intentionally no longer works.</p> <p dir="auto">For <code class="notranslate">requests&lt;2.12.2</code> having <code class="notranslate">None</code> for username and password still resulted in a BasicAuth authstr being created. Starting in <code class="notranslate">2.12.2</code> it will raise an exception.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" ... File &quot;/blah/lib/python2.7/site-packages/requests/auth.py&quot;, line 38, in _basic_auth_str b64encode(b':'.join((username, password))).strip() TypeError: sequence item 0: expected string, NoneType found"><pre lang="Traceback" class="notranslate"><code class="notranslate"> ... File "/blah/lib/python2.7/site-packages/requests/auth.py", line 38, in _basic_auth_str b64encode(b':'.join((username, password))).strip() TypeError: sequence item 0: expected string, NoneType found </code></pre></div> <p dir="auto">here's the change, (which certainly seems desirable), but caused our upstream (<code class="notranslate">python-gitlab</code>) to break.<br> <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/kennethreitz/requests/commit/329a5cfdd4500fb1ce405a3242ef95f9197d24ba/hovercard" href="https://github.com/kennethreitz/requests/commit/329a5cfdd4500fb1ce405a3242ef95f9197d24ba">kennethreitz@<tt>329a5cf</tt></a></p>
1
<ul dir="auto"> <li>Electron version:<br> ares: "1.10.1-DEV"<br> atom-shell: "1.3.1"<br> chrome: "52.0.2743.82"<br> electron: "1.3.1"<br> http_parser: "2.7.0"<br> modules: "49"<br> node: "6.3.0"<br> openssl: "1.0.2h"<br> uv: "1.9.1"<br> v8: "5.2.361.43"<br> zlib: "1.2.8"</li> <li>Operating system: Windows 10 Pro</li> </ul> <p dir="auto">My Electron program runs successfully when I have a network connection. However, with no network connection available it crashes immediately upon startup.</p> <p dir="auto">Here's what I see at the console:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&gt; $ npm start &gt; &gt; &gt; violetbug@1.0.0 start C:\ElectronProjects\violetbug &gt; &gt; electron . &gt; &gt; &gt; C:\ElectronProjects\violetbug\node_modules\electron-prebuilt\dist\electron.exe: c:\jenkins\workspace\electron-win-x64\vendor\node\src\cares_wrap.cc:1328: Assertion `(r) == (0)' failed. &gt; &gt; npm ERR! Windows_NT 10.0.14366 &gt; npm ERR! argv &quot;C:\\Program Files\\nodejs\\node.exe&quot; &quot;C:\\Users\\John\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js&quot; &quot;start&quot; &gt; npm ERR! node v6.3.1 &gt; npm ERR! npm v3.9.3 &gt; npm ERR! code ELIFECYCLE &gt; npm ERR! violetbug@1.0.0 start: `electron .` &gt; npm ERR! Exit status 3 &gt; npm ERR! &gt; npm ERR! Failed at the violetbug@1.0.0 start script 'electron .'. &gt; npm ERR! Make sure you have the latest version of node.js and npm installed. &gt; npm ERR! If you do, this is most likely a problem with the violetbug package, &gt; npm ERR! not with npm itself. &gt; npm ERR! Tell the author that this fails on your system: &gt; npm ERR! electron . &gt; npm ERR! You can get information on how to open an issue for this project with: &gt; npm ERR! npm bugs violetbug &gt; npm ERR! Or if that isn't available, you can get their info via: &gt; npm ERR! npm owner ls violetbug &gt; npm ERR! There is likely additional logging output above. &gt; &gt; npm ERR! Please include the following file with any support request: &gt; npm ERR! C:\ElectronProjects\violetbug\npm-debug.log &gt; "><pre class="notranslate"><code class="notranslate">&gt; $ npm start &gt; &gt; &gt; violetbug@1.0.0 start C:\ElectronProjects\violetbug &gt; &gt; electron . &gt; &gt; &gt; C:\ElectronProjects\violetbug\node_modules\electron-prebuilt\dist\electron.exe: c:\jenkins\workspace\electron-win-x64\vendor\node\src\cares_wrap.cc:1328: Assertion `(r) == (0)' failed. &gt; &gt; npm ERR! Windows_NT 10.0.14366 &gt; npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\John\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "start" &gt; npm ERR! node v6.3.1 &gt; npm ERR! npm v3.9.3 &gt; npm ERR! code ELIFECYCLE &gt; npm ERR! violetbug@1.0.0 start: `electron .` &gt; npm ERR! Exit status 3 &gt; npm ERR! &gt; npm ERR! Failed at the violetbug@1.0.0 start script 'electron .'. &gt; npm ERR! Make sure you have the latest version of node.js and npm installed. &gt; npm ERR! If you do, this is most likely a problem with the violetbug package, &gt; npm ERR! not with npm itself. &gt; npm ERR! Tell the author that this fails on your system: &gt; npm ERR! electron . &gt; npm ERR! You can get information on how to open an issue for this project with: &gt; npm ERR! npm bugs violetbug &gt; npm ERR! Or if that isn't available, you can get their info via: &gt; npm ERR! npm owner ls violetbug &gt; npm ERR! There is likely additional logging output above. &gt; &gt; npm ERR! Please include the following file with any support request: &gt; npm ERR! C:\ElectronProjects\violetbug\npm-debug.log &gt; </code></pre></div> <p dir="auto">Here is C:\ElectronProjects\violetbug\npm-debug.log:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="0 info it worked if it ends with ok 1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe', 1 verbose cli 'C:\\Users\\John\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js', 1 verbose cli 'start' ] 2 info using npm@3.9.3 3 info using node@v6.3.1 4 verbose run-script [ 'prestart', 'start', 'poststart' ] 5 info lifecycle violetbug@1.0.0~prestart: violetbug@1.0.0 6 silly lifecycle violetbug@1.0.0~prestart: no script for prestart, continuing 7 info lifecycle violetbug@1.0.0~start: violetbug@1.0.0 8 verbose lifecycle violetbug@1.0.0~start: unsafe-perm in lifecycle true 9 verbose lifecycle violetbug@1.0.0~start: PATH: C:\Users\John\AppData\Roaming\npm\node_modules\npm\bin\node-gyp-bin;C:\ElectronProjects\violetbug\node_modules\.bin;C:\Program Files\nodejs;C:\Users\John\bin;C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\local\bin;C:\Program Files\Git\usr\bin;C:\Program Files\Git\usr\bin;C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\bin;C:\Users\John\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0;C:\Program Files (x86)\Python27;C:\Users\John\.dnx\bin;C:\Program Files\Microsoft DNX\Dnvm;C:\Programs;C:\Users\John\AppData\Local\Microsoft\WindowsApps;C:\Program Files\Microsoft SQL Server\130\Tools\Binn;C:\Program Files\Git\cmd;C:\Program Files (x86)\Brackets\command;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit;C:\Program Files\Intel\WiFi\bin;C:\Program Files\Common Files\Intel\WirelessCommon;C:\Programs\ffmpeg\bin;C:\Program Files\nodejs;C:\Program Files (x86)\Google\google_appengine;C:\Users\John\AppData\Local\atom\bin;C:\Program Files (x86)\Microsoft VS Code\bin;C:\Users\John\AppData\Local\Microsoft\WindowsApps;C:\Program Files\Intel\WiFi\bin;C:\Program Files\Common Files\Intel\WirelessCommon;C:\Users\John\AppData\Roaming\npm;C:\Program Files\Git\usr\bin\vendor_perl;C:\Program Files\Git\usr\bin\core_perl 10 verbose lifecycle violetbug@1.0.0~start: CWD: C:\ElectronProjects\violetbug 11 silly lifecycle violetbug@1.0.0~start: Args: [ '/d /s /c', 'electron .' ] 12 silly lifecycle violetbug@1.0.0~start: Returned: code: 3 signal: null 13 info lifecycle violetbug@1.0.0~start: Failed to exec start script 14 verbose stack Error: violetbug@1.0.0 start: `electron .` 14 verbose stack Exit status 3 14 verbose stack at EventEmitter.&lt;anonymous&gt; (C:\Users\John\AppData\Roaming\npm\node_modules\npm\lib\utils\lifecycle.js:245:16) 14 verbose stack at emitTwo (events.js:106:13) 14 verbose stack at EventEmitter.emit (events.js:191:7) 14 verbose stack at ChildProcess.&lt;anonymous&gt; (C:\Users\John\AppData\Roaming\npm\node_modules\npm\lib\utils\spawn.js:24:14) 14 verbose stack at emitTwo (events.js:106:13) 14 verbose stack at ChildProcess.emit (events.js:191:7) 14 verbose stack at maybeClose (internal/child_process.js:852:16) 14 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:215:5) 15 verbose pkgid violetbug@1.0.0 16 verbose cwd C:\ElectronProjects\violetbug 17 error Windows_NT 10.0.14366 18 error argv &quot;C:\\Program Files\\nodejs\\node.exe&quot; &quot;C:\\Users\\John\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js&quot; &quot;start&quot; 19 error node v6.3.1 20 error npm v3.9.3 21 error code ELIFECYCLE 22 error violetbug@1.0.0 start: `electron .` 22 error Exit status 3 23 error Failed at the violetbug@1.0.0 start script 'electron .'. 23 error Make sure you have the latest version of node.js and npm installed. 23 error If you do, this is most likely a problem with the violetbug package, 23 error not with npm itself. 23 error Tell the author that this fails on your system: 23 error electron . 23 error You can get information on how to open an issue for this project with: 23 error npm bugs violetbug 23 error Or if that isn't available, you can get their info via: 23 error npm owner ls violetbug 23 error There is likely additional logging output above. 24 verbose exit [ 1, true ] "><pre class="notranslate"><code class="notranslate">0 info it worked if it ends with ok 1 verbose cli [ 'C:\\Program Files\\nodejs\\node.exe', 1 verbose cli 'C:\\Users\\John\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js', 1 verbose cli 'start' ] 2 info using npm@3.9.3 3 info using node@v6.3.1 4 verbose run-script [ 'prestart', 'start', 'poststart' ] 5 info lifecycle violetbug@1.0.0~prestart: violetbug@1.0.0 6 silly lifecycle violetbug@1.0.0~prestart: no script for prestart, continuing 7 info lifecycle violetbug@1.0.0~start: violetbug@1.0.0 8 verbose lifecycle violetbug@1.0.0~start: unsafe-perm in lifecycle true 9 verbose lifecycle violetbug@1.0.0~start: PATH: C:\Users\John\AppData\Roaming\npm\node_modules\npm\bin\node-gyp-bin;C:\ElectronProjects\violetbug\node_modules\.bin;C:\Program Files\nodejs;C:\Users\John\bin;C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\local\bin;C:\Program Files\Git\usr\bin;C:\Program Files\Git\usr\bin;C:\Program Files\Git\mingw64\bin;C:\Program Files\Git\usr\bin;C:\Users\John\bin;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0;C:\Program Files (x86)\Python27;C:\Users\John\.dnx\bin;C:\Program Files\Microsoft DNX\Dnvm;C:\Programs;C:\Users\John\AppData\Local\Microsoft\WindowsApps;C:\Program Files\Microsoft SQL Server\130\Tools\Binn;C:\Program Files\Git\cmd;C:\Program Files (x86)\Brackets\command;C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit;C:\Program Files\Intel\WiFi\bin;C:\Program Files\Common Files\Intel\WirelessCommon;C:\Programs\ffmpeg\bin;C:\Program Files\nodejs;C:\Program Files (x86)\Google\google_appengine;C:\Users\John\AppData\Local\atom\bin;C:\Program Files (x86)\Microsoft VS Code\bin;C:\Users\John\AppData\Local\Microsoft\WindowsApps;C:\Program Files\Intel\WiFi\bin;C:\Program Files\Common Files\Intel\WirelessCommon;C:\Users\John\AppData\Roaming\npm;C:\Program Files\Git\usr\bin\vendor_perl;C:\Program Files\Git\usr\bin\core_perl 10 verbose lifecycle violetbug@1.0.0~start: CWD: C:\ElectronProjects\violetbug 11 silly lifecycle violetbug@1.0.0~start: Args: [ '/d /s /c', 'electron .' ] 12 silly lifecycle violetbug@1.0.0~start: Returned: code: 3 signal: null 13 info lifecycle violetbug@1.0.0~start: Failed to exec start script 14 verbose stack Error: violetbug@1.0.0 start: `electron .` 14 verbose stack Exit status 3 14 verbose stack at EventEmitter.&lt;anonymous&gt; (C:\Users\John\AppData\Roaming\npm\node_modules\npm\lib\utils\lifecycle.js:245:16) 14 verbose stack at emitTwo (events.js:106:13) 14 verbose stack at EventEmitter.emit (events.js:191:7) 14 verbose stack at ChildProcess.&lt;anonymous&gt; (C:\Users\John\AppData\Roaming\npm\node_modules\npm\lib\utils\spawn.js:24:14) 14 verbose stack at emitTwo (events.js:106:13) 14 verbose stack at ChildProcess.emit (events.js:191:7) 14 verbose stack at maybeClose (internal/child_process.js:852:16) 14 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:215:5) 15 verbose pkgid violetbug@1.0.0 16 verbose cwd C:\ElectronProjects\violetbug 17 error Windows_NT 10.0.14366 18 error argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\John\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "start" 19 error node v6.3.1 20 error npm v3.9.3 21 error code ELIFECYCLE 22 error violetbug@1.0.0 start: `electron .` 22 error Exit status 3 23 error Failed at the violetbug@1.0.0 start script 'electron .'. 23 error Make sure you have the latest version of node.js and npm installed. 23 error If you do, this is most likely a problem with the violetbug package, 23 error not with npm itself. 23 error Tell the author that this fails on your system: 23 error electron . 23 error You can get information on how to open an issue for this project with: 23 error npm bugs violetbug 23 error Or if that isn't available, you can get their info via: 23 error npm owner ls violetbug 23 error There is likely additional logging output above. 24 verbose exit [ 1, true ] </code></pre></div>
<ul dir="auto"> <li>Electron version: <code class="notranslate">electron-v1.2.6-win32-x64</code></li> <li>Operating system: <code class="notranslate">Windows 10 Home (version 1511; build 10586.420)</code></li> </ul> <p dir="auto">As reported from <a href="https://github.com/Microsoft/vscode/issues/7570" data-hovercard-type="issue" data-hovercard-url="/microsoft/vscode/issues/7570/hovercard">here</a> - I came across the issue while trying to launch Visual Studio Code without an internet connection.</p> <p dir="auto">I also confirmed the behaviour with versions of Electron as far back as <code class="notranslate">electron-v0.37.6-win32-x64</code> (the one that VS Code currently uses)</p>
1
<p dir="auto">MainActivity has below code for load GIF first time it's working if I restart application it gets a crash for loading gif.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ImageView imageViewGIF = navigationView.findViewById(R.id.imageViewGIF); Glide.with(this).asGif().load(R.drawable.gift_3).into(imageViewGIF);"><pre class="notranslate"><code class="notranslate">ImageView imageViewGIF = navigationView.findViewById(R.id.imageViewGIF); Glide.with(this).asGif().load(R.drawable.gift_3).into(imageViewGIF); </code></pre></div> <p dir="auto">but when I restart the app it gets a crash for at loading of GIF<br> ```</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" Intent intent = new Intent(context, SplashActivity.class); intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP); startActivity(intent); finish();"><pre class="notranslate"><code class="notranslate"> Intent intent = new Intent(context, SplashActivity.class); intent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK | Intent.FLAG_ACTIVITY_CLEAR_TASK | Intent.FLAG_ACTIVITY_CLEAR_TOP); startActivity(intent); finish(); </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="application get a crash with below log. ``` FATAL EXCEPTION: main Process: com.app.package, PID: 19360 java.lang.IllegalArgumentException: You cannot start a load for a destroyed activity at android_support.qc.b(RequestManagerRetriever.java:298) at android_support.qc.a(RequestManagerRetriever.java:123) at android_support.ji.a(Glide.java:589)"><pre class="notranslate"><code class="notranslate">application get a crash with below log. ``` FATAL EXCEPTION: main Process: com.app.package, PID: 19360 java.lang.IllegalArgumentException: You cannot start a load for a destroyed activity at android_support.qc.b(RequestManagerRetriever.java:298) at android_support.qc.a(RequestManagerRetriever.java:123) at android_support.ji.a(Glide.java:589) </code></pre></div> <p dir="auto">i have used<br> <code class="notranslate"> </code>'com.github.bumptech.glide:glide:4.2.0'``<br> <code class="notranslate">'com.github.bumptech.glide:glide:4.3.1'</code></p> <p dir="auto">both versions have the same issue</p>
<p dir="auto"><strong>TLDR</strong>; Glide should just log and cancel the load instead of crashing when the activity is destoryed since there is no point in loading anything. The user of the library shouldn't have to explicitly handle this situation.</p> <hr> <p dir="auto"><strong>Glide Version/Integration library (if any)</strong>: 'com.github.bumptech.glide:glide:3.6.1'<br> <strong>Device/Android Version</strong>: Any/Android 5.0+<br> <strong>Issue details/Repro steps/Use case background</strong>:</p> <p dir="auto">This issue is related to issue <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="42845070" data-permission-text="Title is private" data-url="https://github.com/bumptech/glide/issues/138" data-hovercard-type="issue" data-hovercard-url="/bumptech/glide/issues/138/hovercard" href="https://github.com/bumptech/glide/issues/138">#138</a>. When making a call on glide if the activity has been destroyed it will throw an IllegalArgumentException. The following code in the RequestManagerRetriever.java class is responsible:</p> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="@TargetApi(Build.VERSION_CODES.JELLY_BEAN_MR1) private static void assertNotDestroyed(Activity activity) { if (Build.VERSION.SDK_INT &gt;= Build.VERSION_CODES.JELLY_BEAN_MR1 &amp;&amp; activity.isDestroyed()) { throw new IllegalArgumentException(&quot;You cannot start a load for a destroyed activity&quot;); } }"><pre class="notranslate"><span class="pl-c1">@</span><span class="pl-c1">TargetApi</span>(<span class="pl-smi">Build</span>.<span class="pl-c1">VERSION_CODES</span>.<span class="pl-c1">JELLY_BEAN_MR1</span>) <span class="pl-k">private</span> <span class="pl-k">static</span> <span class="pl-smi">void</span> <span class="pl-s1">assertNotDestroyed</span>(<span class="pl-smi">Activity</span> <span class="pl-s1">activity</span>) { <span class="pl-k">if</span> (<span class="pl-smi">Build</span>.<span class="pl-c1">VERSION</span>.<span class="pl-c1">SDK_INT</span> &gt;= <span class="pl-smi">Build</span>.<span class="pl-c1">VERSION_CODES</span>.<span class="pl-c1">JELLY_BEAN_MR1</span> &amp;&amp; <span class="pl-s1">activity</span>.<span class="pl-en">isDestroyed</span>()) { <span class="pl-k">throw</span> <span class="pl-k">new</span> <span class="pl-smi">IllegalArgumentException</span>(<span class="pl-s">"You cannot start a load for a destroyed activity"</span>); } }</pre></div> <p dir="auto">This is causing a crash in my crashlytics console for a small percentage of my users. There is likely some kind of timing issue where the user hits home as they are scrolling a big list and the activity is cleaned up which results in this crash. I could fix this issue by wrapping glide and running this code myself and simply not calling glide in this situation. However I believe this is the wrong approach, the library shouldn't be crashing in this situation and instead should log and do nothing.</p> <p dir="auto">If the activity is destroyed then the view that is being displayed which the image is being displayed is not visible and as a result no exception should be thrown. Instead glide should log and simply not show the image. Users of the library should not have to explicitly handle situations like these, it makes more sense to just handle it in the library.</p> <p dir="auto"><strong>Glide load line</strong>:</p> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="Glide.with(context).load(url).bitmapTransform(new GrayscaleTransformation(getContext())).into(imageView);"><pre class="notranslate"><span class="pl-smi">Glide</span>.<span class="pl-en">with</span>(<span class="pl-s1">context</span>).<span class="pl-en">load</span>(<span class="pl-s1">url</span>).<span class="pl-en">bitmapTransform</span>(<span class="pl-k">new</span> <span class="pl-smi">GrayscaleTransformation</span>(<span class="pl-en">getContext</span>())).<span class="pl-en">into</span>(<span class="pl-s1">imageView</span>);</pre></div> <p dir="auto"><strong>Layout XML</strong>: not relevant</p> <p dir="auto"><strong>Stack trace / LogCat</strong>:</p> <div class="highlight highlight-source-ruby notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="Fatal Exception: java.lang.IllegalArgumentException: You cannot start a load for a destroyed activity at com.bumptech.glide.manager.RequestManagerRetriever.assertNotDestroyed(RequestManagerRetriever.java:134) at com.bumptech.glide.manager.RequestManagerRetriever.get(RequestManagerRetriever.java:102) at com.bumptech.glide.manager.RequestManagerRetriever.get(RequestManagerRetriever.java:87) at com.bumptech.glide.Glide.with(Glide.java:620) at com.myapp.myapp$24.run(MyAppClass.java:977) at android.os.Handler.handleCallback(Handler.java:739) at android.os.Handler.dispatchMessage(Handler.java:95) at android.os.Looper.loop(Looper.java:135) at android.app.ActivityThread.main(ActivityThread.java:5431) at java.lang.reflect.Method.invoke(Method.java) at java.lang.reflect.Method.invoke(Method.java:372) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:914) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:707)"><pre class="notranslate"><span class="pl-en">Fatal</span> <span class="pl-pds">Exception</span>: <span class="pl-en">java</span><span class="pl-kos">.</span><span class="pl-en">lang</span><span class="pl-kos">.</span><span class="pl-v">IllegalArgumentException</span>: <span class="pl-v">You</span> <span class="pl-en">cannot</span> <span class="pl-en">start</span> <span class="pl-en">a</span> <span class="pl-en">load</span> <span class="pl-k">for</span> <span class="pl-en">a</span> <span class="pl-en">destroyed</span> <span class="pl-en">activity</span> <span class="pl-en">at</span> <span class="pl-en">com</span><span class="pl-kos">.</span><span class="pl-en">bumptech</span><span class="pl-kos">.</span><span class="pl-en">glide</span><span class="pl-kos">.</span><span class="pl-en">manager</span><span class="pl-kos">.</span><span class="pl-en">RequestManagerRetriever</span><span class="pl-kos">.</span><span class="pl-en">assertNotDestroyed</span><span class="pl-kos">(</span><span class="pl-v">RequestManagerRetriever</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:134</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">com</span><span class="pl-kos">.</span><span class="pl-en">bumptech</span><span class="pl-kos">.</span><span class="pl-en">glide</span><span class="pl-kos">.</span><span class="pl-en">manager</span><span class="pl-kos">.</span><span class="pl-en">RequestManagerRetriever</span><span class="pl-kos">.</span><span class="pl-en">get</span><span class="pl-kos">(</span><span class="pl-v">RequestManagerRetriever</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:102</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">com</span><span class="pl-kos">.</span><span class="pl-en">bumptech</span><span class="pl-kos">.</span><span class="pl-en">glide</span><span class="pl-kos">.</span><span class="pl-en">manager</span><span class="pl-kos">.</span><span class="pl-en">RequestManagerRetriever</span><span class="pl-kos">.</span><span class="pl-en">get</span><span class="pl-kos">(</span><span class="pl-v">RequestManagerRetriever</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:87</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">com</span><span class="pl-kos">.</span><span class="pl-en">bumptech</span><span class="pl-kos">.</span><span class="pl-en">glide</span><span class="pl-kos">.</span><span class="pl-en">Glide</span><span class="pl-kos">.</span><span class="pl-en">with</span><span class="pl-kos">(</span><span class="pl-v">Glide</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:620</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">com</span><span class="pl-kos">.</span><span class="pl-en">myapp</span><span class="pl-kos">.</span><span class="pl-en">myapp</span>$24<span class="pl-kos">.</span><span class="pl-en">run</span><span class="pl-kos">(</span><span class="pl-v">MyAppClass</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:977</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">android</span><span class="pl-kos">.</span><span class="pl-en">os</span><span class="pl-kos">.</span><span class="pl-en">Handler</span><span class="pl-kos">.</span><span class="pl-en">handleCallback</span><span class="pl-kos">(</span><span class="pl-v">Handler</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:739</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">android</span><span class="pl-kos">.</span><span class="pl-en">os</span><span class="pl-kos">.</span><span class="pl-en">Handler</span><span class="pl-kos">.</span><span class="pl-en">dispatchMessage</span><span class="pl-kos">(</span><span class="pl-v">Handler</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:95</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">android</span><span class="pl-kos">.</span><span class="pl-en">os</span><span class="pl-kos">.</span><span class="pl-en">Looper</span><span class="pl-kos">.</span><span class="pl-en">loop</span><span class="pl-kos">(</span><span class="pl-v">Looper</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:135</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">android</span><span class="pl-kos">.</span><span class="pl-en">app</span><span class="pl-kos">.</span><span class="pl-en">ActivityThread</span><span class="pl-kos">.</span><span class="pl-en">main</span><span class="pl-kos">(</span><span class="pl-v">ActivityThread</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:5431</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">java</span><span class="pl-kos">.</span><span class="pl-en">lang</span><span class="pl-kos">.</span><span class="pl-en">reflect</span><span class="pl-kos">.</span><span class="pl-en">Method</span><span class="pl-kos">.</span><span class="pl-en">invoke</span><span class="pl-kos">(</span><span class="pl-v">Method</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">java</span><span class="pl-kos">.</span><span class="pl-en">lang</span><span class="pl-kos">.</span><span class="pl-en">reflect</span><span class="pl-kos">.</span><span class="pl-en">Method</span><span class="pl-kos">.</span><span class="pl-en">invoke</span><span class="pl-kos">(</span><span class="pl-v">Method</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:372</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">com</span><span class="pl-kos">.</span><span class="pl-en">android</span><span class="pl-kos">.</span><span class="pl-en">internal</span><span class="pl-kos">.</span><span class="pl-en">os</span><span class="pl-kos">.</span><span class="pl-en">ZygoteInit</span>$MethodAndArgsCaller<span class="pl-kos">.</span><span class="pl-en">run</span><span class="pl-kos">(</span><span class="pl-v">ZygoteInit</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:914</span><span class="pl-kos">)</span> <span class="pl-en">at</span> <span class="pl-en">com</span><span class="pl-kos">.</span><span class="pl-en">android</span><span class="pl-kos">.</span><span class="pl-en">internal</span><span class="pl-kos">.</span><span class="pl-en">os</span><span class="pl-kos">.</span><span class="pl-en">ZygoteInit</span><span class="pl-kos">.</span><span class="pl-en">main</span><span class="pl-kos">(</span><span class="pl-v">ZygoteInit</span><span class="pl-kos">.</span><span class="pl-en">java</span><span class="pl-pds">:707</span><span class="pl-kos">)</span></pre></div>
1
<p dir="auto">I'm trying to use Plots.contour. I'm not entirely sure that my objects have the appropriate size/shape for contour.</p> <p dir="auto">x is Vector{Float64} with 513 elements<br> t is Vector{Float64} with 10001 elements<br> time_steps is 10001x513 Array{Float64,2}</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="using Plots Plots.contour(x, t, time_steps) Illegal inttoptr ​ %37 = ptrtoint double addrspace(13)* %36 to i64 Illegal inttoptr %56 = inttoptr i64 %55 to i8 addrspace(13)* signal (6): Aborted in expression starting at none:0 gsignal at /usr/bin/../lib/x86_64-linux-gnu/libc.so.6 (unknown line) abort at /usr/bin/../lib/x86_64-linux-gnu/libc.so.6 (unknown line) unknown function (ip: 0x7f9f0a769d04) _ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) _ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) _ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) unknown function (ip: 0x7f9f0a853ac1) unknown function (ip: 0x7f9f0a8562d8) unknown function (ip: 0x7f9f0a8568cd) unknown function (ip: 0x7f9f0a791b4a) unknown function (ip: 0x7f9f0a7c2ed3) unknown function (ip: 0x7f9f0a7e884b) jl_apply_generic at /usr/bin/../lib/x86_64-linux-gnu/libjulia.so.1 (unknown line) #346 at ./array.jl:0 iterate at ./generator.jl:47 [inlined] indexed_iterate at ./tuple.jl:89 [inlined] gr_add_series at /home/wesley/.julia/packages/Plots/uCh2y/src/backends/gr.jl:1491 gr_display at /home/wesley/.julia/packages/Plots/uCh2y/src/backends/gr.jl:891 unknown function (ip: 0x7f9eb12c1048) gr_display at /home/wesley/.julia/packages/Plots/uCh2y/src/backends/gr.jl:596 _show at /home/wesley/.julia/packages/Plots/uCh2y/src/backends/gr.jl:1776 _showjuno at /home/wesley/.julia/packages/Plots/uCh2y/src/output.jl:273 [inlined] showjuno at /home/wesley/.julia/packages/Plots/uCh2y/src/output.jl:257 show at /home/wesley/.julia/packages/Plots/uCh2y/src/output.jl:212 unknown function (ip: 0x7f9f0a7f3df8) #base64encode#3 at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/encode.jl:208 base64encode##kw at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/encode.jl:203 [inlined] _binstringmime at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/Base64.jl:46 [inlined] #stringmime#6 at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/Base64.jl:43 stringmime##kw at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/Base64.jl:43 #stringmime#7 at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/Base64.jl:44 stringmime##kw at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/Base64.jl:44 [inlined] displayinplotpane at /home/wesley/.julia/packages/Atom/BPtI0/src/display/showdisplay.jl:84 displayandrender at /home/wesley/.julia/packages/Atom/BPtI0/src/display/showdisplay.jl:131 #218 at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:191 unknown function (ip: 0x7f9f0a7f3df8) jl_f__apply_latest at /usr/bin/../lib/x86_64-linux-gnu/libjulia.so.1 (unknown line) #invokelatest#1 at ./essentials.jl:712 [inlined] invokelatest at ./essentials.jl:711 [inlined] #216 at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:190 withpath at /home/wesley/.julia/packages/CodeTools/VsjEq/src/utils.jl:30 withpath at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:9 #215 at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:173 [inlined] with_logstate at ./logging.jl:398 with_logger at ./logging.jl:505 [inlined] #214 at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:172 [inlined] hideprompt at /home/wesley/.julia/packages/Atom/BPtI0/src/repl.jl:127 macro expansion at /home/wesley/.julia/packages/Media/ItEPc/src/dynamic.jl:24 [inlined] evalall at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:162 unknown function (ip: 0x7f9f0a7f3df8) jl_f__apply_latest at /usr/bin/../lib/x86_64-linux-gnu/libjulia.so.1 (unknown line) #invokelatest#1 at ./essentials.jl:712 unknown function (ip: 0x7f9f0a7f3df8) invokelatest at ./essentials.jl:711 unknown function (ip: 0x7f9f0a7f3df8) macro expansion at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:41 [inlined] #184 at ./task.jl:358 unknown function (ip: 0x7f9eec0479ac) unknown function (ip: 0x7f9f0a800cbb) unknown function (ip: (nil)) Allocations: 118696019 (Pool: 118600401; Big: 95618); GC: 104"><pre class="notranslate"><code class="notranslate">using Plots Plots.contour(x, t, time_steps) Illegal inttoptr ​ %37 = ptrtoint double addrspace(13)* %36 to i64 Illegal inttoptr %56 = inttoptr i64 %55 to i8 addrspace(13)* signal (6): Aborted in expression starting at none:0 gsignal at /usr/bin/../lib/x86_64-linux-gnu/libc.so.6 (unknown line) abort at /usr/bin/../lib/x86_64-linux-gnu/libc.so.6 (unknown line) unknown function (ip: 0x7f9f0a769d04) _ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) _ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) _ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) unknown function (ip: 0x7f9f0a853ac1) unknown function (ip: 0x7f9f0a8562d8) unknown function (ip: 0x7f9f0a8568cd) unknown function (ip: 0x7f9f0a791b4a) unknown function (ip: 0x7f9f0a7c2ed3) unknown function (ip: 0x7f9f0a7e884b) jl_apply_generic at /usr/bin/../lib/x86_64-linux-gnu/libjulia.so.1 (unknown line) #346 at ./array.jl:0 iterate at ./generator.jl:47 [inlined] indexed_iterate at ./tuple.jl:89 [inlined] gr_add_series at /home/wesley/.julia/packages/Plots/uCh2y/src/backends/gr.jl:1491 gr_display at /home/wesley/.julia/packages/Plots/uCh2y/src/backends/gr.jl:891 unknown function (ip: 0x7f9eb12c1048) gr_display at /home/wesley/.julia/packages/Plots/uCh2y/src/backends/gr.jl:596 _show at /home/wesley/.julia/packages/Plots/uCh2y/src/backends/gr.jl:1776 _showjuno at /home/wesley/.julia/packages/Plots/uCh2y/src/output.jl:273 [inlined] showjuno at /home/wesley/.julia/packages/Plots/uCh2y/src/output.jl:257 show at /home/wesley/.julia/packages/Plots/uCh2y/src/output.jl:212 unknown function (ip: 0x7f9f0a7f3df8) #base64encode#3 at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/encode.jl:208 base64encode##kw at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/encode.jl:203 [inlined] _binstringmime at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/Base64.jl:46 [inlined] #stringmime#6 at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/Base64.jl:43 stringmime##kw at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/Base64.jl:43 #stringmime#7 at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/Base64.jl:44 stringmime##kw at /build/julia-98cBbp/julia-1.4.1+dfsg/usr/share/julia/stdlib/v1.4/Base64/src/Base64.jl:44 [inlined] displayinplotpane at /home/wesley/.julia/packages/Atom/BPtI0/src/display/showdisplay.jl:84 displayandrender at /home/wesley/.julia/packages/Atom/BPtI0/src/display/showdisplay.jl:131 #218 at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:191 unknown function (ip: 0x7f9f0a7f3df8) jl_f__apply_latest at /usr/bin/../lib/x86_64-linux-gnu/libjulia.so.1 (unknown line) #invokelatest#1 at ./essentials.jl:712 [inlined] invokelatest at ./essentials.jl:711 [inlined] #216 at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:190 withpath at /home/wesley/.julia/packages/CodeTools/VsjEq/src/utils.jl:30 withpath at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:9 #215 at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:173 [inlined] with_logstate at ./logging.jl:398 with_logger at ./logging.jl:505 [inlined] #214 at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:172 [inlined] hideprompt at /home/wesley/.julia/packages/Atom/BPtI0/src/repl.jl:127 macro expansion at /home/wesley/.julia/packages/Media/ItEPc/src/dynamic.jl:24 [inlined] evalall at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:162 unknown function (ip: 0x7f9f0a7f3df8) jl_f__apply_latest at /usr/bin/../lib/x86_64-linux-gnu/libjulia.so.1 (unknown line) #invokelatest#1 at ./essentials.jl:712 unknown function (ip: 0x7f9f0a7f3df8) invokelatest at ./essentials.jl:711 unknown function (ip: 0x7f9f0a7f3df8) macro expansion at /home/wesley/.julia/packages/Atom/BPtI0/src/eval.jl:41 [inlined] #184 at ./task.jl:358 unknown function (ip: 0x7f9eec0479ac) unknown function (ip: 0x7f9f0a800cbb) unknown function (ip: (nil)) Allocations: 118696019 (Pool: 118600401; Big: 95618); GC: 104 </code></pre></div>
<p dir="auto">Hello,</p> <p dir="auto">so I found a hard crash of Julia from a small piece of code</p> <div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="using Random a = reshape(shuffle(0:15), 4, 4) b = reshape(transpose(a), 1, :) circshift(b, -1))"><pre class="notranslate"><span class="pl-k">using</span> Random a <span class="pl-k">=</span> <span class="pl-c1">reshape</span>(<span class="pl-c1">shuffle</span>(<span class="pl-c1">0</span><span class="pl-k">:</span><span class="pl-c1">15</span>), <span class="pl-c1">4</span>, <span class="pl-c1">4</span>) b <span class="pl-k">=</span> <span class="pl-c1">reshape</span>(<span class="pl-c1">transpose</span>(a), <span class="pl-c1">1</span>, :) <span class="pl-c1">circshift</span>(b, <span class="pl-k">-</span><span class="pl-c1">1</span>))</pre></div> <p dir="auto">And the resulting crash "report" is:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Illegal inttoptr %uglygep88 = ptrtoint i8 addrspace(13)* %uglygep to i64 Illegal inttoptr %scevgep8990 = ptrtoint i64 addrspace(13)* %scevgep89 to i64 Illegal inttoptr %215 = inttoptr i64 %214 to i8 addrspace(13)* Illegal inttoptr %umax9192 = inttoptr i64 %umax91 to i64 addrspace(13)* signal (6): Aborted in expression starting at /home/paul/test.jl:4 gsignal at /usr/bin/../lib/x86_64-linux-gnu/libc.so.6 (unknown line) abort at /usr/bin/../lib/x86_64-linux-gnu/libc.so.6 (unknown line) unknown function (ip: 0x7f98b857fd04) _ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) _ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) _ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) unknown function (ip: 0x7f98b8669ac1) unknown function (ip: 0x7f98b866c2d8) unknown function (ip: 0x7f98b866c8cd) unknown function (ip: 0x7f98b85a7b4a) unknown function (ip: 0x7f98b85d9082) unknown function (ip: 0x7f98b85fe84b) jl_apply_generic at /usr/bin/../lib/x86_64-linux-gnu/libjulia.so.1 (unknown line) unknown function (ip: 0x7f98b861175b) unknown function (ip: 0x7f98b8611389) unknown function (ip: 0x7f98b86118f0) unknown function (ip: 0x7f98b86129c8) unknown function (ip: 0x7f98b8613616) unknown function (ip: 0x7f98b862be08) unknown function (ip: 0x7f98b8607105) jl_load at /usr/bin/../lib/x86_64-linux-gnu/libjulia.so.1 (unknown line) include at ./Base.jl:377 exec_options at ./client.jl:288 _start at ./client.jl:484 jfptr__start_2075.clone_1 at /usr/lib/x86_64-linux-gnu/julia/sys.so (unknown line) unknown function (ip: 0x5585861d29d9) unknown function (ip: 0x5585861d25a6) __libc_start_main at /usr/bin/../lib/x86_64-linux-gnu/libc.so.6 (unknown line) unknown function (ip: 0x5585861d264d) Allocations: 2505 (Pool: 2493; Big: 12); GC: 0 Aborted (core dumped)"><pre class="notranslate"><code class="notranslate">Illegal inttoptr %uglygep88 = ptrtoint i8 addrspace(13)* %uglygep to i64 Illegal inttoptr %scevgep8990 = ptrtoint i64 addrspace(13)* %scevgep89 to i64 Illegal inttoptr %215 = inttoptr i64 %214 to i8 addrspace(13)* Illegal inttoptr %umax9192 = inttoptr i64 %umax91 to i64 addrspace(13)* signal (6): Aborted in expression starting at /home/paul/test.jl:4 gsignal at /usr/bin/../lib/x86_64-linux-gnu/libc.so.6 (unknown line) abort at /usr/bin/../lib/x86_64-linux-gnu/libc.so.6 (unknown line) unknown function (ip: 0x7f98b857fd04) _ZN4llvm13FPPassManager13runOnFunctionERNS_8FunctionE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) _ZN4llvm13FPPassManager11runOnModuleERNS_6ModuleE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) _ZN4llvm6legacy15PassManagerImpl3runERNS_6ModuleE at /usr/bin/../lib/x86_64-linux-gnu/libLLVM-8.so.1 (unknown line) unknown function (ip: 0x7f98b8669ac1) unknown function (ip: 0x7f98b866c2d8) unknown function (ip: 0x7f98b866c8cd) unknown function (ip: 0x7f98b85a7b4a) unknown function (ip: 0x7f98b85d9082) unknown function (ip: 0x7f98b85fe84b) jl_apply_generic at /usr/bin/../lib/x86_64-linux-gnu/libjulia.so.1 (unknown line) unknown function (ip: 0x7f98b861175b) unknown function (ip: 0x7f98b8611389) unknown function (ip: 0x7f98b86118f0) unknown function (ip: 0x7f98b86129c8) unknown function (ip: 0x7f98b8613616) unknown function (ip: 0x7f98b862be08) unknown function (ip: 0x7f98b8607105) jl_load at /usr/bin/../lib/x86_64-linux-gnu/libjulia.so.1 (unknown line) include at ./Base.jl:377 exec_options at ./client.jl:288 _start at ./client.jl:484 jfptr__start_2075.clone_1 at /usr/lib/x86_64-linux-gnu/julia/sys.so (unknown line) unknown function (ip: 0x5585861d29d9) unknown function (ip: 0x5585861d25a6) __libc_start_main at /usr/bin/../lib/x86_64-linux-gnu/libc.so.6 (unknown line) unknown function (ip: 0x5585861d264d) Allocations: 2505 (Pool: 2493; Big: 12); GC: 0 Aborted (core dumped) </code></pre></div> <p dir="auto"><code class="notranslate">versioninfo</code> is:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Julia Version 1.4.1 Platform Info: OS: Linux (x86_64-linux-gnu) CPU: Intel(R) Core(TM) i7-8565U CPU @ 1.80GHz WORD_SIZE: 64 LIBM: libopenlibm LLVM: libLLVM-8.0.1 (ORCJIT, skylake)"><pre class="notranslate"><code class="notranslate">Julia Version 1.4.1 Platform Info: OS: Linux (x86_64-linux-gnu) CPU: Intel(R) Core(TM) i7-8565U CPU @ 1.80GHz WORD_SIZE: 64 LIBM: libopenlibm LLVM: libLLVM-8.0.1 (ORCJIT, skylake) </code></pre></div> <p dir="auto">Please let me know if I can help in any way!</p>
1
<p dir="auto">In the autograd tutorial, <a href="https://pytorch.org/tutorials/beginner/blitz/autograd_tutorial.html" rel="nofollow">https://pytorch.org/tutorials/beginner/blitz/autograd_tutorial.html</a></p> <blockquote> <p dir="auto">print(x.grad)</p> </blockquote> <p dir="auto">gives output:</p> <blockquote> <p dir="auto">tensor([[4.5000, 4.5000],<br> [4.5000, 4.5000]])</p> </blockquote> <p dir="auto">but it hangs afterwards.</p> <p dir="auto">pytorch version: 1.5.0<br> python: 3.7.7<br> OS: windows 7</p> <p dir="auto">cc <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/ezyang/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/ezyang">@ezyang</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/ssnl/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/ssnl">@ssnl</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/albanD/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/albanD">@albanD</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/zou3519/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/zou3519">@zou3519</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/gqchen/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/gqchen">@gqchen</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/peterjc123/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/peterjc123">@peterjc123</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/nbcsm/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/nbcsm">@nbcsm</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/guyang3532/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/guyang3532">@guyang3532</a></p>
<p dir="auto">Whenever backward() is called to compute gradients the python script never terminates. The backward function is not per se blocking and all lines after it are still executed however the script just does not terminate. This may be related with the operation system which is Windows 7 or with the use of conda. At least there is another <a href="https://stackoverflow.com/questions/57857690/pytorch-autograd-obstructs-script-from-terminating" rel="nofollow">(post on Stack Overflow)</a> describing the same problem in the same environment.</p> <h2 dir="auto">To Reproduce</h2> <p dir="auto">Steps to reproduce the behavior:</p> <ol dir="auto"> <li>install PyTorch on windows 7 via conda (<code class="notranslate">conda create --name grad_test pytorch -c pytorch</code>)</li> <li>run example code given below taken from the post on Stack Overflow</li> </ol> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import torch x = torch.randn(3, requires_grad=True) y = x * 2 print(y) gradients = torch.tensor([0.1, 1.0, 0.0001], dtype=torch.float) y.backward(gradients) print(x.grad) print(&quot;all done&quot;)"><pre class="notranslate"><code class="notranslate">import torch x = torch.randn(3, requires_grad=True) y = x * 2 print(y) gradients = torch.tensor([0.1, 1.0, 0.0001], dtype=torch.float) y.backward(gradients) print(x.grad) print("all done") </code></pre></div> <h2 dir="auto">Expected behavior</h2> <p dir="auto">Script runs and exits after printing "all done".</p> <h2 dir="auto">Environment</h2> <p dir="auto">PyTorch version: 1.3.0<br> Is debug build: No<br> CUDA used to build PyTorch: 10.1</p> <p dir="auto">OS: Microsoft Windows 7 Enterprise<br> CMake version: version 3.9.6</p> <p dir="auto">Python version: 3.7<br> Is CUDA available: Yes<br> CUDA runtime version: 10.1.243<br> GPU models and configuration: GPU 0: GeForce GTX 1080<br> Nvidia driver version: 441.12<br> cuDNN version: Could not collect</p> <p dir="auto">Versions of relevant libraries:<br> [pip] numpy==1.17.3<br> [pip] torch==1.3.0<br> [pip] torchvision==0.4.1<br> [conda] blas 1.0 mkl anaconda<br> [conda] libblas 3.8.0 14_mkl conda-forge<br> [conda] libcblas 3.8.0 14_mkl conda-forge<br> [conda] liblapack 3.8.0 14_mkl conda-forge<br> [conda] mkl 2019.4 245<br> [conda] mkl-service 2.3.0 py37hfa6e2cd_0 conda-forge<br> [conda] pytorch 1.3.0 py3.7_cuda101_cudnn7_0 pytorch<br> [conda] torchvision 0.4.1 py37_cu101 pytorch</p> <p dir="auto">cc <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/ezyang/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/ezyang">@ezyang</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/ssnl/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/ssnl">@ssnl</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/albanD/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/albanD">@albanD</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/zou3519/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/zou3519">@zou3519</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/gqchen/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/gqchen">@gqchen</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/peterjc123/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/peterjc123">@peterjc123</a></p>
1
<p dir="auto">My zookeeper version is 3.5.5,My druid version 0.22.0 ,How can I solve it,thank you .</p>
<p dir="auto">Submitting GroupBy queries to the JSON query API returns a 500 when given duplicate output name columns. For example:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="{ &quot;context&quot;: {&quot;queryId&quot;: &quot;010b5fa5-9a45-4614-8c0b-acaa747c2af0&quot;}, &quot;dataSource&quot;: &quot;Famous_Duets&quot;, &quot;aggregations&quot;: [{ &quot;fieldName&quot;: &quot;count&quot;, &quot;name&quot;: &quot;count&quot;, &quot;type&quot;: &quot;count&quot; }], &quot;dataSource&quot;: &quot;my_datasource&quot;, &quot;dimensions&quot;: [{ &quot;dimension&quot;: &quot;Female_Singer&quot;, &quot;outputName&quot;: &quot;Singer&quot;, &quot;type&quot;: &quot;default&quot; }, { &quot;dimension&quot;: &quot;Male_Singer&quot;, &quot;outputName&quot;: &quot;Singer&quot;, &quot;type&quot;: &quot;default&quot; }], &quot;granularity&quot;: &quot;all&quot;, &quot;intervals&quot;: [&quot;2017-06-20T14:51:00Z/2017-06-20T18:27:00Z&quot;], &quot;queryType&quot;: &quot;groupBy&quot; }"><pre class="notranslate"><code class="notranslate">{ "context": {"queryId": "010b5fa5-9a45-4614-8c0b-acaa747c2af0"}, "dataSource": "Famous_Duets", "aggregations": [{ "fieldName": "count", "name": "count", "type": "count" }], "dataSource": "my_datasource", "dimensions": [{ "dimension": "Female_Singer", "outputName": "Singer", "type": "default" }, { "dimension": "Male_Singer", "outputName": "Singer", "type": "default" }], "granularity": "all", "intervals": ["2017-06-20T14:51:00Z/2017-06-20T18:27:00Z"], "queryType": "groupBy" } </code></pre></div> <p dir="auto">Note that <code class="notranslate">Singer</code> is the outputName for more than one groupBy dimension. The query response is:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="{&quot;error&quot;:&quot;Unknown exception&quot;}"><pre class="notranslate"><code class="notranslate">{"error":"Unknown exception"} </code></pre></div> <p dir="auto">Obviously, the query is malformed, but returning the error in this response might be helpful. The way I tracked it down was in the logs:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="2017-06-20T18:49:09,604 INFO [qtp1665324560-197[groupBy_Famous_Duets_010b5fa5-9a45-4614-8c0b-acaa747c2af0]] io.druid.server.QueryResource - Unknown exception [010b5fa5-9a45-4614-8c0b-acaa747c2af0]"><pre class="notranslate"><code class="notranslate">2017-06-20T18:49:09,604 INFO [qtp1665324560-197[groupBy_Famous_Duets_010b5fa5-9a45-4614-8c0b-acaa747c2af0]] io.druid.server.QueryResource - Unknown exception [010b5fa5-9a45-4614-8c0b-acaa747c2af0] </code></pre></div> <p dir="auto">Later in the logs, a log containing:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Dimension[Singer] occurred more than once in InputRow"><pre class="notranslate"><code class="notranslate">Dimension[Singer] occurred more than once in InputRow </code></pre></div> <p dir="auto">Tipped me off to what the error was.</p>
0
<p dir="auto">Hello,</p> <p dir="auto">While setting up deno in docker I noticed the <code class="notranslate">install.sh</code> script uses <code class="notranslate">unzip</code> and the build will exit with the error <code class="notranslate">unzip is not installed</code>. I believe this is not a default program and <code class="notranslate">tar</code> can be used in place of <code class="notranslate">unzip</code>.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="RUN curl -fsSL https://deno.land/x/install/install.sh | sh"><pre lang="docker" class="notranslate"><code class="notranslate">RUN curl -fsSL https://deno.land/x/install/install.sh | sh </code></pre></div> <p dir="auto"><a href="https://github.com/denoland/deno_install/blob/master/install.sh#L39">https://github.com/denoland/deno_install/blob/master/install.sh#L39</a></p> <p dir="auto">The <code class="notranslate">RUN</code> command that worked for me was</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="RUN sudo apt-get update &amp;&amp; sudo apt-get install unzip -y &amp;&amp; \ curl -fsSL https://deno.land/x/install/install.sh | sh &amp;&amp; \ sudo mkdir &quot;/usr/local/etc/bash_completion.d&quot; &amp;&amp; \ sudo chown &quot;$USER:$USER&quot; &quot;/usr/local/etc/bash_completion.d&quot; &amp;&amp; \ sudo &quot;$HOME/.deno/bin/deno&quot; completions bash &gt; &quot;/usr/local/etc/bash_completion.d/deno.bash&quot; &amp;&amp; \ sudo apt-get clean &amp;&amp; \ sudo rm -rf /var/lib/apt/lists/* ENV DENO_INSTALL=&quot;/$HOME/.deno&quot; ENV PATH=&quot;$DENO_INSTALL/bin:$PATH&quot;"><pre class="notranslate"><code class="notranslate">RUN sudo apt-get update &amp;&amp; sudo apt-get install unzip -y &amp;&amp; \ curl -fsSL https://deno.land/x/install/install.sh | sh &amp;&amp; \ sudo mkdir "/usr/local/etc/bash_completion.d" &amp;&amp; \ sudo chown "$USER:$USER" "/usr/local/etc/bash_completion.d" &amp;&amp; \ sudo "$HOME/.deno/bin/deno" completions bash &gt; "/usr/local/etc/bash_completion.d/deno.bash" &amp;&amp; \ sudo apt-get clean &amp;&amp; \ sudo rm -rf /var/lib/apt/lists/* ENV DENO_INSTALL="/$HOME/.deno" ENV PATH="$DENO_INSTALL/bin:$PATH" </code></pre></div>
<p dir="auto">If unzip is not installed, the install.sh should install it for you</p>
1
<p dir="auto">This is on OSX 10.10.1 with Atom 0.15.0</p> <p dir="auto">I had an issue today where I ran out of disk space, and Atom seemed to wipe out a previously saved file.</p> <p dir="auto">As in, this file had already been saved, I opened it in Atom, saved, then I quit Atom. Then when I restarted Atom, the file was empty.</p> <p dir="auto">I checked with <code class="notranslate">ls</code>, the file was empty and 0 bytes.</p> <p dir="auto">I do understand that running out of disk space is certainly not a normal condition, but is there any explanation that would explain how Atom would completely wipe out the contents of the file as a result?</p>
<p dir="auto">I have a hard time replicating this issue since it will require me filling up the disk again, but in a nutshell the problem is that when I edit a file in Atom, if the disk space is not enough to save it, I find that the file content is erased.</p> <p dir="auto">This happened to me more than once (yeah I need more Gbs of disk space) so I can certify that it is Atom the one causing the issue. The issue appears whenever I edit the file, not when I just open it. The problem is not that Atom is not being able to save the file (that would make sense if there is no disk space available), the problem is that Atom <em>removes all the content</em>, and of course I'm afterwards not able to recover it.</p> <p dir="auto">I have no clue of why may this be happening</p>
1
<h1 dir="auto">Feature request</h1> <h2 dir="auto">Is your feature request related to a problem? Please describe.</h2> <p dir="auto">may be related to <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="482077873" data-permission-text="Title is private" data-url="https://github.com/vercel/next.js/issues/8422" data-hovercard-type="issue" data-hovercard-url="/vercel/next.js/issues/8422/hovercard" href="https://github.com/vercel/next.js/issues/8422">#8422</a>.</p> <p dir="auto">At the present time , when using next.js with other backend frameworks (isomorphic applications), users have few controls to the logging facility of next.js.</p> <p dir="auto">Users can only pass <code class="notranslate">{quiet: true}</code> when instantiate <code class="notranslate">next.js</code> object. But doing these only hide error messages, still can not modify some logging behaviours such as logging level or logging format.</p> <p dir="auto">I hope next.js can provide some mechanics for controlling dev logging behaviour.</p> <h2 dir="auto">Describe the solution you'd like</h2> <p dir="auto">using more advanced logging framework such as <a href="https://github.com/winstonjs/winston">winston</a> maybe a good solution.</p> <h2 dir="auto">Describe alternatives you've considered</h2> <h2 dir="auto">Additional context</h2> <p dir="auto">I found next.js do have an abstract layer to handle logging(<a href="https://github.com/zeit/next.js/blob/52dd42a6bb9f0a45af1fb5eac773729b031e8fb1/packages/next/build/output/log.ts">log.ts</a>), while some code use these abstract APIs to log( such as <a href="https://github.com/zeit/next.js/blob/18a9c7e371efc4c487f9c3599c3211ce30009d6c/packages/next/build/output/store.ts#L81"><code class="notranslate">bundled successfully</code></a> ), some do not ( such as <a href="https://github.com/zeit/next.js/blob/18a9c7e371efc4c487f9c3599c3211ce30009d6c/packages/next/build/index.ts#L322"><code class="notranslate">Compiled successfully</code></a> )</p> <p dir="auto">Maybe with controllable logging is also make next.js avilable to provide more detailed messages for debug using.</p>
<h1 dir="auto">Feature request</h1> <h2 dir="auto">Is your feature request related to a problem? Please describe.</h2> <p dir="auto">Using custom server interferes with other logging in my app.</p> <h2 dir="auto">Describe the solution you'd like</h2> <p dir="auto">A way to silence <code class="notranslate">next</code> and an interface to tap into <code class="notranslate">ready</code>, <code class="notranslate">recompile</code>, <code class="notranslate">error</code> events.</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="const app = next({ dev: true, quiet: true }) app.on('ready', myLogger.info); app.on('recompile', myLogger.trace); app.on('error', err =&gt; myLogger.error('something went wrong', { err })); const handle = app.getRequestHandler() // ..."><pre class="notranslate"><span class="pl-k">const</span> <span class="pl-s1">app</span> <span class="pl-c1">=</span> <span class="pl-en">next</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">dev</span>: <span class="pl-c1">true</span><span class="pl-kos">,</span> <span class="pl-c1">quiet</span>: <span class="pl-c1">true</span> <span class="pl-kos">}</span><span class="pl-kos">)</span> <span class="pl-s1">app</span><span class="pl-kos">.</span><span class="pl-en">on</span><span class="pl-kos">(</span><span class="pl-s">'ready'</span><span class="pl-kos">,</span> <span class="pl-s1">myLogger</span><span class="pl-kos">.</span><span class="pl-c1">info</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-s1">app</span><span class="pl-kos">.</span><span class="pl-en">on</span><span class="pl-kos">(</span><span class="pl-s">'recompile'</span><span class="pl-kos">,</span> <span class="pl-s1">myLogger</span><span class="pl-kos">.</span><span class="pl-c1">trace</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-s1">app</span><span class="pl-kos">.</span><span class="pl-en">on</span><span class="pl-kos">(</span><span class="pl-s">'error'</span><span class="pl-kos">,</span> <span class="pl-s1">err</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">myLogger</span><span class="pl-kos">.</span><span class="pl-en">error</span><span class="pl-kos">(</span><span class="pl-s">'something went wrong'</span><span class="pl-kos">,</span> <span class="pl-kos">{</span> err <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">const</span> <span class="pl-s1">handle</span> <span class="pl-c1">=</span> <span class="pl-s1">app</span><span class="pl-kos">.</span><span class="pl-en">getRequestHandler</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c">// ...</span></pre></div>
1
<h3 dir="auto">STR</h3> <div class="highlight highlight-source-rust notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="#![crate_type = &quot;lib&quot;] use std::mem; use std::ops::Deref; fn ice(sample: &amp;Sample&lt;f32&gt;) { let slice: &amp;[f32] = sample; } fn ok(sample: &amp;Sample&lt;f32&gt;) { let slice: &amp;[f32] = unsafe { mem::transmute(sample) }; } struct Sample&lt;A&gt;([A]); impl&lt;A&gt; Deref for Sample&lt;A&gt; { type Target = [A]; fn deref(&amp;self) -&gt; &amp;[A] { unsafe { mem::transmute(self) } } }"><pre class="notranslate"><span class="pl-c1">#!<span class="pl-kos">[</span>crate_type = <span class="pl-s">"lib"</span><span class="pl-kos">]</span></span> <span class="pl-k">use</span> std<span class="pl-kos">::</span>mem<span class="pl-kos">;</span> <span class="pl-k">use</span> std<span class="pl-kos">::</span>ops<span class="pl-kos">::</span><span class="pl-v">Deref</span><span class="pl-kos">;</span> <span class="pl-k">fn</span> <span class="pl-en">ice</span><span class="pl-kos">(</span><span class="pl-s1">sample</span><span class="pl-kos">:</span> <span class="pl-c1">&amp;</span><span class="pl-smi">Sample</span><span class="pl-kos">&lt;</span><span class="pl-smi">f32</span><span class="pl-kos">&gt;</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">let</span> slice<span class="pl-kos">:</span> <span class="pl-c1">&amp;</span><span class="pl-kos">[</span><span class="pl-smi">f32</span><span class="pl-kos">]</span> = sample<span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-k">fn</span> <span class="pl-en">ok</span><span class="pl-kos">(</span><span class="pl-s1">sample</span><span class="pl-kos">:</span> <span class="pl-c1">&amp;</span><span class="pl-smi">Sample</span><span class="pl-kos">&lt;</span><span class="pl-smi">f32</span><span class="pl-kos">&gt;</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">let</span> slice<span class="pl-kos">:</span> <span class="pl-c1">&amp;</span><span class="pl-kos">[</span><span class="pl-smi">f32</span><span class="pl-kos">]</span> = <span class="pl-k">unsafe</span> <span class="pl-kos">{</span> mem<span class="pl-kos">::</span><span class="pl-en">transmute</span><span class="pl-kos">(</span>sample<span class="pl-kos">)</span> <span class="pl-kos">}</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-k">struct</span> <span class="pl-smi">Sample</span><span class="pl-kos">&lt;</span><span class="pl-smi">A</span><span class="pl-kos">&gt;</span><span class="pl-kos">(</span><span class="pl-kos">[</span><span class="pl-smi">A</span><span class="pl-kos">]</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">impl</span><span class="pl-kos">&lt;</span><span class="pl-smi">A</span><span class="pl-kos">&gt;</span> <span class="pl-smi">Deref</span> <span class="pl-k">for</span> <span class="pl-smi">Sample</span><span class="pl-kos">&lt;</span><span class="pl-smi">A</span><span class="pl-kos">&gt;</span> <span class="pl-kos">{</span> <span class="pl-k">type</span> <span class="pl-smi">Target</span> = <span class="pl-kos">[</span><span class="pl-smi">A</span><span class="pl-kos">]</span><span class="pl-kos">;</span> <span class="pl-k">fn</span> <span class="pl-en">deref</span><span class="pl-kos">(</span><span class="pl-c1">&amp;</span><span class="pl-smi">self</span><span class="pl-kos">)</span> -&gt; <span class="pl-c1">&amp;</span><span class="pl-kos">[</span><span class="pl-smi">A</span><span class="pl-kos">]</span> <span class="pl-kos">{</span> <span class="pl-k">unsafe</span> <span class="pl-kos">{</span> mem<span class="pl-kos">::</span><span class="pl-en">transmute</span><span class="pl-kos">(</span><span class="pl-smi">self</span><span class="pl-kos">)</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span></pre></div> <h3 dir="auto">Backtrace</h3> <div class="highlight highlight-source-rust notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="error: internal compiler error: unexpected panic note: the compiler unexpectedly panicked. this is a bug. note: we would appreciate a bug report: http://doc.rust-lang.org/complement-bugreport.html note: run with `RUST_BACKTRACE=1` for a backtrace thread 'rustc' panicked at 'unsized_part_of_type failed even though ty is unsized', /home/rustbuild/src/rust-buildbot/slave/nightly-dist-rustc-linux/build/src/librustc_trans/trans/common.rs:166 stack backtrace: 1: 0x7fdc3bc535b0 - sys::backtrace::write::h0cbfc88baae43aa021y 2: 0x7fdc3bc779b0 - failure::on_fail::h0a7ead13585065c0rcH 3: 0x7fdc3bbd5970 - rt::unwind::begin_unwind_inner::h5389a239af7b06eeMQG 4: 0x7fdc3a8a7d50 - rt::unwind::begin_unwind::h16123941288702621176 5: 0x7fdc3a980310 - trans::common::unsized_part_of_type::ha72e8603712ad74dSRk 6: 0x7fdc3a9b12a0 - trans::type_of::type_of::type_of_unsize_info::h8f9f7a388a336e9dm8o 7: 0x7fdc3a903650 - trans::type_of::type_of::h26bd2a95f0ad4a3727o 8: 0x7fdc3a9208a0 - trans::datum::Datum&lt;'tcx, Rvalue&gt;::to_ref_datum::h75fa0e01c0664e30YQf 9: 0x7fdc3a920a00 - trans::datum::Datum&lt;'tcx, Rvalue&gt;::to_appropriate_datum::h6c5a00ca4a6144b7SRf 10: 0x7fdc3a93fe30 - trans::callee::trans_arg_datum::h5d56fde4db281665Rqh 11: 0x7fdc3a9330c0 - trans::callee::trans_args::h82e8228688fa879cShh 12: 0x7fdc3a95d7a0 - trans::expr::trans_overloaded_op::h7dcf7ba6da813cf5I6j 13: 0x7fdc3a979e60 - trans::expr::deref_once::h6284489ab9f07c9eBzk 14: 0x7fdc3a94cf50 - trans::expr::deref_multiple::h48c0e59f95e290f1Zxk 15: 0x7fdc3a8f9cb0 - trans::expr::trans::h4aa11cd527e88cd0dIh 16: 0x7fdc3a8f8b20 - trans::expr::trans_into::h792bd9b430d8f7dfJEh 17: 0x7fdc3a9fa950 - trans::_match::mk_binding_alloca::h4494187384434577009 18: 0x7fdc3a8f81c0 - trans::base::init_local::he96ac71055395945not 19: 0x7fdc3a8f9130 - trans::controlflow::trans_block::hd445a33426df7637Bde 20: 0x7fdc3a9c4530 - trans::base::trans_closure::h899ff1df83d7583b9du 21: 0x7fdc3a8e55e0 - trans::base::trans_fn::hc2298bc13eeb8cfappu 22: 0x7fdc3a8e0570 - trans::base::trans_item::h03200b520668f12feOu 23: 0x7fdc3a9cb990 - trans::base::trans_crate::ha94cd7a9cd13cad4yLv 24: 0x7fdc3c269210 - driver::phase_4_translate_to_llvm::he09ab588c39cf70ewPa 25: 0x7fdc3c242200 - driver::compile_input::h0eb7a1103ff8aba2Eba 26: 0x7fdc3c3136e0 - run_compiler::ha9d14025fcb8e9fc5bc 27: 0x7fdc3c311d40 - thunk::F.Invoke&lt;A, R&gt;::invoke::h5646167225587318028 28: 0x7fdc3c310c30 - rt::unwind::try::try_fn::h4383208440922308355 29: 0x7fdc3bce3d40 - rust_try_inner 30: 0x7fdc3bce3d30 - rust_try 31: 0x7fdc3c310ee0 - thunk::F.Invoke&lt;A, R&gt;::invoke::h10387639015308431532 32: 0x7fdc3bc63ea0 - sys::thread::thread_start::h5a97a888379df6e9FQC 33: 0x7fdc35c722b0 - start_thread 34: 0x7fdc3b861249 - __clone 35: 0x0 - &lt;unknown&gt;"><pre class="notranslate">error<span class="pl-kos">:</span> internal compiler error<span class="pl-kos">:</span> unexpected panic note<span class="pl-kos">:</span> the compiler unexpectedly panicked<span class="pl-kos">.</span> <span class="pl-c1">this</span> is a bug<span class="pl-kos">.</span> <span class="pl-c1">note</span><span class="pl-kos">:</span> we would appreciate a bug report<span class="pl-kos">:</span> http<span class="pl-kos">:</span><span class="pl-c">//doc.rust-lang.org/complement-bugreport.html</span> note<span class="pl-kos">:</span> run with `<span class="pl-v">RUST_BACKTRACE</span>=<span class="pl-c1">1</span>` <span class="pl-k">for</span> a backtrace thread <span class="pl-c1">'</span>rustc<span class="pl-c1">'</span> panicked at <span class="pl-c1">'</span>unsized_part_of_type failed even though ty is unsized<span class="pl-c1">'</span><span class="pl-kos">,</span> /home/rustbuild/src/rust-buildbot/slave/nightly-dist-rustc-linux/build/src/librustc_trans/trans/common<span class="pl-kos">.</span><span class="pl-c1">rs</span><span class="pl-kos">:</span><span class="pl-c1">166</span> stack backtrace<span class="pl-kos">:</span> <span class="pl-c1">1</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3bc535b0</span> - sys<span class="pl-kos">::</span>backtrace<span class="pl-kos">::</span>write<span class="pl-kos">::</span>h0cbfc88baae43aa021y <span class="pl-c1">2</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3bc779b0</span> - failure<span class="pl-kos">::</span>on_fail<span class="pl-kos">::</span>h0a7ead13585065c0rcH <span class="pl-c1">3</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3bbd5970</span> - rt<span class="pl-kos">::</span>unwind<span class="pl-kos">::</span>begin_unwind_inner<span class="pl-kos">::</span>h5389a239af7b06eeMQG <span class="pl-c1">4</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a8a7d50</span> - rt<span class="pl-kos">::</span>unwind<span class="pl-kos">::</span>begin_unwind<span class="pl-kos">::</span>h16123941288702621176 <span class="pl-c1">5</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a980310</span> - trans<span class="pl-kos">::</span>common<span class="pl-kos">::</span>unsized_part_of_type<span class="pl-kos">::</span>ha72e8603712ad74dSRk <span class="pl-c1">6</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a9b12a0</span> - trans<span class="pl-kos">::</span>type_of<span class="pl-kos">::</span>type_of<span class="pl-kos">::</span>type_of_unsize_info<span class="pl-kos">::</span>h8f9f7a388a336e9dm8o <span class="pl-c1">7</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a903650</span> - trans<span class="pl-kos">::</span>type_of<span class="pl-kos">::</span>type_of<span class="pl-kos">::</span>h26bd2a95f0ad4a3727o <span class="pl-c1">8</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a9208a0</span> - trans<span class="pl-kos">::</span>datum<span class="pl-kos">::</span><span class="pl-v">Datum</span>&lt;<span class="pl-c1">'</span>tcx<span class="pl-kos">,</span> <span class="pl-v">Rvalue</span>&gt;<span class="pl-kos">::</span>to_ref_datum<span class="pl-kos">::</span>h75fa0e01c0664e30YQf <span class="pl-c1">9</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a920a00</span> - trans<span class="pl-kos">::</span>datum<span class="pl-kos">::</span><span class="pl-v">Datum</span>&lt;<span class="pl-c1">'</span>tcx<span class="pl-kos">,</span> <span class="pl-v">Rvalue</span>&gt;<span class="pl-kos">::</span>to_appropriate_datum<span class="pl-kos">::</span>h6c5a00ca4a6144b7SRf <span class="pl-c1">10</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a93fe30</span> - trans<span class="pl-kos">::</span>callee<span class="pl-kos">::</span>trans_arg_datum<span class="pl-kos">::</span>h5d56fde4db281665Rqh <span class="pl-c1">11</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a9330c0</span> - trans<span class="pl-kos">::</span>callee<span class="pl-kos">::</span>trans_args<span class="pl-kos">::</span>h82e8228688fa879cShh <span class="pl-c1">12</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a95d7a0</span> - trans<span class="pl-kos">::</span>expr<span class="pl-kos">::</span>trans_overloaded_op<span class="pl-kos">::</span>h7dcf7ba6da813cf5I6j <span class="pl-c1">13</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a979e60</span> - trans<span class="pl-kos">::</span>expr<span class="pl-kos">::</span>deref_once<span class="pl-kos">::</span>h6284489ab9f07c9eBzk <span class="pl-c1">14</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a94cf50</span> - trans<span class="pl-kos">::</span>expr<span class="pl-kos">::</span>deref_multiple<span class="pl-kos">::</span>h48c0e59f95e290f1Zxk <span class="pl-c1">15</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a8f9cb0</span> - trans<span class="pl-kos">::</span>expr<span class="pl-kos">::</span>trans<span class="pl-kos">::</span>h4aa11cd527e88cd0dIh <span class="pl-c1">16</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a8f8b20</span> - trans<span class="pl-kos">::</span>expr<span class="pl-kos">::</span>trans_into<span class="pl-kos">::</span>h792bd9b430d8f7dfJEh <span class="pl-c1">17</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a9fa950</span> - trans<span class="pl-kos">::</span>_match<span class="pl-kos">::</span>mk_binding_alloca<span class="pl-kos">::</span>h4494187384434577009 <span class="pl-c1">18</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a8f81c0</span> - trans<span class="pl-kos">::</span>base<span class="pl-kos">::</span>init_local<span class="pl-kos">::</span>he96ac71055395945not <span class="pl-c1">19</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a8f9130</span> - trans<span class="pl-kos">::</span>controlflow<span class="pl-kos">::</span>trans_block<span class="pl-kos">::</span>hd445a33426df7637Bde <span class="pl-c1">20</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a9c4530</span> - trans<span class="pl-kos">::</span>base<span class="pl-kos">::</span>trans_closure<span class="pl-kos">::</span>h899ff1df83d7583b9du <span class="pl-c1">21</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a8e55e0</span> - trans<span class="pl-kos">::</span>base<span class="pl-kos">::</span>trans_fn<span class="pl-kos">::</span>hc2298bc13eeb8cfappu <span class="pl-c1">22</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a8e0570</span> - trans<span class="pl-kos">::</span>base<span class="pl-kos">::</span>trans_item<span class="pl-kos">::</span>h03200b520668f12feOu <span class="pl-c1">23</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3a9cb990</span> - trans<span class="pl-kos">::</span>base<span class="pl-kos">::</span>trans_crate<span class="pl-kos">::</span>ha94cd7a9cd13cad4yLv <span class="pl-c1">24</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3c269210</span> - driver<span class="pl-kos">::</span>phase_4_translate_to_llvm<span class="pl-kos">::</span>he09ab588c39cf70ewPa <span class="pl-c1">25</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3c242200</span> - driver<span class="pl-kos">::</span>compile_input<span class="pl-kos">::</span>h0eb7a1103ff8aba2Eba <span class="pl-c1">26</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3c3136e0</span> - run_compiler<span class="pl-kos">::</span>ha9d14025fcb8e9fc5bc <span class="pl-c1">27</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3c311d40</span> - thunk<span class="pl-kos">::</span><span class="pl-v">F</span><span class="pl-kos">.</span><span class="pl-c1">Invoke</span>&lt;<span class="pl-v">A</span><span class="pl-kos">,</span> <span class="pl-v">R</span>&gt;<span class="pl-kos">::</span>invoke<span class="pl-kos">::</span>h5646167225587318028 <span class="pl-c1">28</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3c310c30</span> - rt<span class="pl-kos">::</span>unwind<span class="pl-kos">::</span>try<span class="pl-kos">::</span>try_fn<span class="pl-kos">::</span>h4383208440922308355 <span class="pl-c1">29</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3bce3d40</span> - rust_try_inner <span class="pl-c1">30</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3bce3d30</span> - rust_try <span class="pl-c1">31</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3c310ee0</span> - thunk<span class="pl-kos">::</span><span class="pl-v">F</span><span class="pl-kos">.</span><span class="pl-c1">Invoke</span>&lt;<span class="pl-v">A</span><span class="pl-kos">,</span> <span class="pl-v">R</span>&gt;<span class="pl-kos">::</span>invoke<span class="pl-kos">::</span>h10387639015308431532 <span class="pl-c1">32</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3bc63ea0</span> - sys<span class="pl-kos">::</span>thread<span class="pl-kos">::</span>thread_start<span class="pl-kos">::</span>h5a97a888379df6e9FQC <span class="pl-c1">33</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc35c722b0</span> - start_thread <span class="pl-c1">34</span><span class="pl-kos">:</span> <span class="pl-c1">0x7fdc3b861249</span> - __clone <span class="pl-c1">35</span><span class="pl-kos">:</span> <span class="pl-c1">0x0</span> - &lt;<span class="pl-smi">unknown</span>&gt;</pre></div> <h3 dir="auto">Version</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="rustc 1.0.0-nightly (a954663db 2015-02-10 22:08:30 +0000)"><pre class="notranslate"><code class="notranslate">rustc 1.0.0-nightly (a954663db 2015-02-10 22:08:30 +0000) </code></pre></div> <p dir="auto">cc <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/nick29581/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/nick29581">@nick29581</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/eddyb/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/eddyb">@eddyb</a></p> <p dir="auto">(NB <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="41361825" data-permission-text="Title is private" data-url="https://github.com/rust-lang/rust/issues/16812" data-hovercard-type="issue" data-hovercard-url="/rust-lang/rust/issues/16812/hovercard" href="https://github.com/rust-lang/rust/issues/16812">#16812</a> has the same ICE message, but it don't think it's a duplicate because that issue is about "complex" (unsupported?) DST structs that can't be obtained/created via a <code class="notranslate">mem::transmute</code>. On the other hand, this issue is about the known-to-work <code class="notranslate">NewType(Dst)</code>/<code class="notranslate">NewType { inner: Dst }</code> pattern)</p>
<p dir="auto">As per fixme.</p>
0
<p dir="auto"><strong>Glide Version : 4.0.0</strong>:</p> <p dir="auto"><strong>Integration libraries : okhttp3-integration:4.0.0</strong>:</p> <p dir="auto"><strong>Device/Android Version : xiaomi 6.0</strong>:</p> <p dir="auto"><strong>Issue details / Repro steps / Use case background</strong>:<br> options add transform , when refresh recyclerview , the item image will flicker .</p> <p dir="auto"><strong>Glide load line / <code class="notranslate">GlideModule</code> (if any) / list Adapter code (if any)</strong>:</p> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" RequestOptions options = new RequestOptions(); options.placeholder(R.drawable.default_news_cat_pic) .error(R.drawable.default_news_cat_pic) .dontAnimate() .diskCacheStrategy(DiskCacheStrategy.AUTOMATIC) .options.transform(new TopCrop(imageView.getContext())); GlideApp.with(image.getContext()) .load(url) .apply(options) .into(image);"><pre class="notranslate"> <span class="pl-smi">RequestOptions</span> <span class="pl-s1">options</span> = <span class="pl-k">new</span> <span class="pl-smi">RequestOptions</span>(); <span class="pl-s1">options</span>.<span class="pl-en">placeholder</span>(<span class="pl-smi">R</span>.<span class="pl-s1">drawable</span>.<span class="pl-s1">default_news_cat_pic</span>) .<span class="pl-en">error</span>(<span class="pl-smi">R</span>.<span class="pl-s1">drawable</span>.<span class="pl-s1">default_news_cat_pic</span>) .<span class="pl-en">dontAnimate</span>() .<span class="pl-en">diskCacheStrategy</span>(<span class="pl-smi">DiskCacheStrategy</span>.<span class="pl-c1">AUTOMATIC</span>) .<span class="pl-s1">options</span>.<span class="pl-en">transform</span>(<span class="pl-k">new</span> <span class="pl-smi">TopCrop</span>(<span class="pl-s1">imageView</span>.<span class="pl-en">getContext</span>())); <span class="pl-smi">GlideApp</span>.<span class="pl-en">with</span>(<span class="pl-s1">image</span>.<span class="pl-en">getContext</span>()) .<span class="pl-en">load</span>(<span class="pl-s1">url</span>) .<span class="pl-en">apply</span>(<span class="pl-s1">options</span>) .<span class="pl-en">into</span>(<span class="pl-s1">image</span>);</pre></div> <p dir="auto"><strong>Layout XML</strong>:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" &lt;RelativeLayout android:id=&quot;@+id/rl_content&quot; android:layout_width=&quot;match_parent&quot; android:layout_height=&quot;wrap_content&quot; android:paddingLeft=&quot;@dimen/normal_margin&quot; android:paddingRight=&quot;@dimen/normal_margin&quot; android:paddingTop=&quot;@dimen/normal_margin&quot;&gt; &lt;TextView android:id=&quot;@+id/tv_title&quot; android:layout_width=&quot;match_parent&quot; android:layout_height=&quot;wrap_content&quot; android:layout_alignLeft=&quot;@+id/ll_head&quot; android:layout_alignStart=&quot;@+id/ll_head&quot; android:layout_below=&quot;@id/ll_head&quot; android:ellipsize=&quot;end&quot; android:lineSpacingExtra=&quot;3dp&quot; android:maxLines=&quot;2&quot; android:paddingBottom=&quot;2dp&quot; android:text=&quot;标题&quot; android:textColor=&quot;@color/text_black&quot; android:textSize=&quot;@dimen/font_size_big&quot; /&gt; &lt;ImageView android:id=&quot;@+id/iv_image&quot; android:layout_width=&quot;match_parent&quot; android:layout_height=&quot;187dp&quot; android:layout_below=&quot;@id/tv_title&quot; android:layout_marginTop=&quot;5dp&quot; android:src=&quot;@drawable/default_news_cat_pic&quot; /&gt; &lt;TextView android:id=&quot;@+id/tv_desc&quot; style=&quot;@style/noraml_text_style&quot; android:layout_below=&quot;@id/iv_image&quot; android:layout_marginTop=&quot;7dp&quot; android:ellipsize=&quot;end&quot; android:lineSpacingExtra=&quot;2dp&quot; android:maxLines=&quot;2&quot; android:text=&quot;简介&quot; android:visibility=&quot;gone&quot; /&gt; &lt;/RelativeLayout&gt; "><pre class="notranslate"><code class="notranslate"> &lt;RelativeLayout android:id="@+id/rl_content" android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingLeft="@dimen/normal_margin" android:paddingRight="@dimen/normal_margin" android:paddingTop="@dimen/normal_margin"&gt; &lt;TextView android:id="@+id/tv_title" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_alignLeft="@+id/ll_head" android:layout_alignStart="@+id/ll_head" android:layout_below="@id/ll_head" android:ellipsize="end" android:lineSpacingExtra="3dp" android:maxLines="2" android:paddingBottom="2dp" android:text="标题" android:textColor="@color/text_black" android:textSize="@dimen/font_size_big" /&gt; &lt;ImageView android:id="@+id/iv_image" android:layout_width="match_parent" android:layout_height="187dp" android:layout_below="@id/tv_title" android:layout_marginTop="5dp" android:src="@drawable/default_news_cat_pic" /&gt; &lt;TextView android:id="@+id/tv_desc" style="@style/noraml_text_style" android:layout_below="@id/iv_image" android:layout_marginTop="7dp" android:ellipsize="end" android:lineSpacingExtra="2dp" android:maxLines="2" android:text="简介" android:visibility="gone" /&gt; &lt;/RelativeLayout&gt; </code></pre></div> <p dir="auto"><strong>Stack trace / LogCat</strong>:</p> <div class="highlight highlight-source-ruby notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="paste stack trace and/or log here"><pre class="notranslate"><span class="pl-en">paste</span> <span class="pl-en">stack</span> <span class="pl-en">trace</span> <span class="pl-k">and</span>/<span class="pl-en">or</span> <span class="pl-en">log</span> <span class="pl-en">here</span></pre></div>
<p dir="auto">Hi,</p> <p dir="auto">first of all thank you for a great library. The issue started today when I updated to the newest Glide 4.0.0 from 4.0.0 RC1. Images everywhere started flickering when refreshing data (for example in the RecyclerView's notifyDatasetChanged method). Here is my helper class that I'm using for displaying images.</p> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="public class ImageManager { public static ImageManager.Builder with(Context context) { return new Builder(context); } public static class Builder { private final RequestManager requestManager; private RequestBuilder&lt;Drawable&gt; requestBuilder; public Builder(Context context) { requestManager = Glide.with(context); } public Builder load(String url) { requestBuilder = requestManager.load(url); return this; } public Builder load(Uri uri) { requestBuilder = requestManager.load(uri); return this; } public void clear(ImageView imageView) { requestManager.clear(imageView); } public void into(ImageView imageView) { RequestOptions requestOptions = new RequestOptions(); requestOptions = requestOptions.downsample(DownsampleStrategy.AT_LEAST); if (ViewCompat.getTransitionName(imageView) != null) { requestOptions = requestOptions.dontTransform(); } requestBuilder.apply(requestOptions).thumbnail(0.1f).into(imageView); } } }"><pre class="notranslate"><span class="pl-k">public</span> <span class="pl-k">class</span> <span class="pl-smi">ImageManager</span> { <span class="pl-k">public</span> <span class="pl-k">static</span> <span class="pl-smi">ImageManager</span>.<span class="pl-smi">Builder</span> <span class="pl-en">with</span>(<span class="pl-smi">Context</span> <span class="pl-s1">context</span>) { <span class="pl-k">return</span> <span class="pl-k">new</span> <span class="pl-smi">Builder</span>(<span class="pl-s1">context</span>); } <span class="pl-k">public</span> <span class="pl-k">static</span> <span class="pl-k">class</span> <span class="pl-smi">Builder</span> { <span class="pl-k">private</span> <span class="pl-k">final</span> <span class="pl-smi">RequestManager</span> <span class="pl-s1">requestManager</span>; <span class="pl-k">private</span> <span class="pl-smi">RequestBuilder</span>&lt;<span class="pl-smi">Drawable</span>&gt; <span class="pl-s1">requestBuilder</span>; <span class="pl-k">public</span> <span class="pl-smi">Builder</span>(<span class="pl-smi">Context</span> <span class="pl-s1">context</span>) { <span class="pl-s1">requestManager</span> = <span class="pl-smi">Glide</span>.<span class="pl-en">with</span>(<span class="pl-s1">context</span>); } <span class="pl-k">public</span> <span class="pl-smi">Builder</span> <span class="pl-en">load</span>(<span class="pl-smi">String</span> <span class="pl-s1">url</span>) { <span class="pl-s1">requestBuilder</span> = <span class="pl-s1">requestManager</span>.<span class="pl-en">load</span>(<span class="pl-s1">url</span>); <span class="pl-k">return</span> <span class="pl-smi">this</span>; } <span class="pl-k">public</span> <span class="pl-smi">Builder</span> <span class="pl-en">load</span>(<span class="pl-smi">Uri</span> <span class="pl-s1">uri</span>) { <span class="pl-s1">requestBuilder</span> = <span class="pl-s1">requestManager</span>.<span class="pl-en">load</span>(<span class="pl-s1">uri</span>); <span class="pl-k">return</span> <span class="pl-smi">this</span>; } <span class="pl-k">public</span> <span class="pl-smi">void</span> <span class="pl-en">clear</span>(<span class="pl-smi">ImageView</span> <span class="pl-s1">imageView</span>) { <span class="pl-s1">requestManager</span>.<span class="pl-en">clear</span>(<span class="pl-s1">imageView</span>); } <span class="pl-k">public</span> <span class="pl-smi">void</span> <span class="pl-en">into</span>(<span class="pl-smi">ImageView</span> <span class="pl-s1">imageView</span>) { <span class="pl-smi">RequestOptions</span> <span class="pl-s1">requestOptions</span> = <span class="pl-k">new</span> <span class="pl-smi">RequestOptions</span>(); <span class="pl-s1">requestOptions</span> = <span class="pl-s1">requestOptions</span>.<span class="pl-en">downsample</span>(<span class="pl-smi">DownsampleStrategy</span>.<span class="pl-c1">AT_LEAST</span>); <span class="pl-k">if</span> (<span class="pl-smi">ViewCompat</span>.<span class="pl-en">getTransitionName</span>(<span class="pl-s1">imageView</span>) != <span class="pl-c1">null</span>) { <span class="pl-s1">requestOptions</span> = <span class="pl-s1">requestOptions</span>.<span class="pl-en">dontTransform</span>(); } <span class="pl-s1">requestBuilder</span>.<span class="pl-en">apply</span>(<span class="pl-s1">requestOptions</span>).<span class="pl-en">thumbnail</span>(<span class="pl-c1">0.1f</span>).<span class="pl-en">into</span>(<span class="pl-s1">imageView</span>); } } }</pre></div> <p dir="auto">Maybe this issue is related with this other <a href="https://github.com/bumptech/glide/issues/2035" data-hovercard-type="issue" data-hovercard-url="/bumptech/glide/issues/2035/hovercard">issue</a>, but I didn't have a problem with this on that version so I created a new topic.</p>
1
<p dir="auto">API Doc update for <a href="https://www.tensorflow.org/versions/r2.0/api_docs/python/tf/audio/encode_wav" rel="nofollow">https://www.tensorflow.org/versions/r2.0/api_docs/python/tf/audio/encode_wav</a></p> <p dir="auto">Correct links? No<br> Clear Description? No<br> Usage Example?<br> Parameters Defined? Yes, not verified against current code<br> Returns defined? Yes, not verified against current code<br> Raises listed and defined? No<br> Visuals, if applicable? No</p> <p dir="auto">I will submit a PR, please assign this bug to me.</p> <p dir="auto">Part of Issue <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="438088367" data-permission-text="Title is private" data-url="https://github.com/tensorflow/tensorflow/issues/28237" data-hovercard-type="issue" data-hovercard-url="/tensorflow/tensorflow/issues/28237/hovercard" href="https://github.com/tensorflow/tensorflow/issues/28237">#28237</a> &amp; Issue <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="438087827" data-permission-text="Title is private" data-url="https://github.com/tensorflow/tensorflow/issues/28236" data-hovercard-type="issue" data-hovercard-url="/tensorflow/tensorflow/issues/28236/hovercard" href="https://github.com/tensorflow/tensorflow/issues/28236">#28236</a></p>
<p dir="auto">API doc update for <a href="https://www.tensorflow.org/versions/r2.0/api_docs/python/tf/audio/decode_wav" rel="nofollow">https://www.tensorflow.org/versions/r2.0/api_docs/python/tf/audio/decode_wav</a></p> <p dir="auto">Correct links? No<br> Clear Description? No<br> Usage Example?<br> Parameters Defined? Yes, not verified against current code<br> Returns defined? Yes, not verified against current code<br> Raises listed and defined? No<br> Visuals, if applicable? No</p> <p dir="auto">I will submit a PR, please assign this bug to me.</p>
1
<p dir="auto"><code class="notranslate">react.tsx</code>:</p> <div class="highlight highlight-source-tsx notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import React from &quot;https://esm.sh/react&quot; export default function hello(foo: string) { return &lt;p&gt; Hello {foo}&lt;/p&gt;; } console.log(hello(&quot;world&quot;))"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-smi">React</span> <span class="pl-k">from</span> <span class="pl-s">"https://esm.sh/react"</span> <span class="pl-k">export</span> <span class="pl-k">default</span> <span class="pl-k">function</span> <span class="pl-en">hello</span><span class="pl-kos">(</span><span class="pl-s1">foo</span>: <span class="pl-smi">string</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">return</span> <span class="pl-c1">&lt;</span><span class="pl-ent">p</span><span class="pl-c1">&gt;</span> Hello <span class="pl-kos">{</span><span class="pl-s1">foo</span><span class="pl-kos">}</span><span class="pl-c1">&lt;</span><span class="pl-c1">/</span><span class="pl-ent">p</span><span class="pl-c1">&gt;</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-smi">console</span><span class="pl-kos">.</span><span class="pl-en">log</span><span class="pl-kos">(</span><span class="pl-en">hello</span><span class="pl-kos">(</span><span class="pl-s">"world"</span><span class="pl-kos">)</span><span class="pl-kos">)</span></pre></div> <p dir="auto"><code class="notranslate">deno run react,tsx</code>:</p> <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="Check file:///home/luca/testStuff/deno/react.tsx { &quot;$$typeof&quot;: Symbol(react.element), type: &quot;p&quot;, key: null, ref: null, props: { children: [ &quot; Hello &quot;, &quot;world&quot; ] }, _owner: null }"><pre class="notranslate">Check file:///home/luca/testStuff/deno/react.tsx { <span class="pl-s"><span class="pl-pds">"</span><span class="pl-smi">$$</span>typeof<span class="pl-pds">"</span></span>: Symbol(react.element), type: <span class="pl-s"><span class="pl-pds">"</span>p<span class="pl-pds">"</span></span>, key: null, ref: null, props: { children: [ <span class="pl-s"><span class="pl-pds">"</span> Hello <span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>world<span class="pl-pds">"</span></span> ] }, _owner: null }</pre></div> <p dir="auto"><code class="notranslate">deno run - &lt; react.tsx</code>:</p> <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="deno run - &lt; react.tsx error: Expected ;, got { at file:///home/luca/testStuff/deno/$deno$stdin.ts:4:21"><pre class="notranslate">deno run - <span class="pl-k">&lt;</span> react.tsx error: Expected <span class="pl-k">;</span>, got { at file:///home/luca/testStuff/deno/<span class="pl-smi">$deno$stdin</span>.ts:4:21</pre></div>
<p dir="auto">I'm trying out deno for scripting (it's been a great experience so far, kudos!).</p> <p dir="auto">I'd like to be able to create script files without a <code class="notranslate">.ts</code> extension. If I do this, then the following is interpreted as JS and I get a syntax error on the type annotations:</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="#!/usr/bin/env -S deno run --allow-run --allow-read --allow-write // code: language=typescript function hello(name: string) { console.log(&quot;Hello,&quot;, name); } hello(Deno.args[0]);"><pre class="notranslate">#!/usr/bin/env -S deno run --allow-run --allow-read --allow-write <span class="pl-c">// code: language=typescript</span> <span class="pl-k">function</span> <span class="pl-en">hello</span><span class="pl-kos">(</span><span class="pl-s1">name</span>: <span class="pl-smi">string</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-smi">console</span><span class="pl-kos">.</span><span class="pl-en">log</span><span class="pl-kos">(</span><span class="pl-s">"Hello,"</span><span class="pl-kos">,</span> <span class="pl-s1">name</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-en">hello</span><span class="pl-kos">(</span><span class="pl-smi">Deno</span><span class="pl-kos">.</span><span class="pl-c1">args</span><span class="pl-kos">[</span><span class="pl-c1">0</span><span class="pl-kos">]</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ ./myscript error: Uncaught SyntaxError: Unexpected token ':' function hello(name: string) { ^ at file:///home/joe/tmp/myscript:5:20"><pre class="notranslate"><code class="notranslate">$ ./myscript error: Uncaught SyntaxError: Unexpected token ':' function hello(name: string) { ^ at file:///home/joe/tmp/myscript:5:20 </code></pre></div> <p dir="auto">I believe the simplest solution would be to add a CLI flag to force script to be interpreted as typescript.</p> <p dir="auto">Something like:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="--language=[javascript, typescript]"><pre class="notranslate"><code class="notranslate">--language=[javascript, typescript] </code></pre></div> <p dir="auto">so in the above script the shebang becomes:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="#!/usr/bin/env -S deno run --language=typescript --allow-run --allow-read --allow-write"><pre class="notranslate"><code class="notranslate">#!/usr/bin/env -S deno run --language=typescript --allow-run --allow-read --allow-write </code></pre></div>
1
<p dir="auto"><strong><a href="https://jira.spring.io/secure/ViewProfile.jspa?name=aloew" rel="nofollow">Andreas Loew</a></strong> opened <strong><a href="https://jira.spring.io/browse/SPR-5026?redirect=false" rel="nofollow">SPR-5026</a></strong> and commented</p> <p dir="auto">Summary:</p> <p dir="auto">When creating the underlying physical JMS connection, SingleConnectionFactory should call the appropriate createXXXConnection method properly reflecting the type of the target XXXConnectionFactory:</p> <ul dir="auto"> <li>for a target QueueConnectionFactory, call createQueueConnection()</li> <li>for a target TopicConnectionFactory, call createTopicConnection()</li> <li>for a target ConnectionFactory, call createTopicConnection()</li> </ul> <p dir="auto">Details:</p> <p dir="auto">The exception I get looks like the following:</p> <p dir="auto">22.07.2008 12:14:52 org.springframework.jms.connection.SingleConnectionFactory initConnection<br> INFO: Established shared JMS Connection: com.spirit.wave.jms.WaveConnection@e79839<br> Exception in thread "main" javax.jms.IllegalStateException: This SingleConnectionFactory does not hold a QueueConnection but rather: com.spirit.wave.jms.WaveConnection@e79839<br> at org.springframework.jms.connection.SingleConnectionFactory.createQueueConnection(SingleConnectionFactory.java:229)<br> at testcase.MessageRequestor.main(MessageRequestor.java:47)</p> <p dir="auto">But my targetConnectionFactory indeed is a JMS 1.1-compliant com.spirit.wave.jms.WaveQueueConnectionFactory.</p> <p dir="auto">The real root cause for seeing this issue is that, with "my" JMS provider, calling qcf.createConnection() on a WaveQueueConnectionFactory instance qcf only creates a WaveConnection (which only implements connection, but not QueueConnection), but calling qcf.createQueueConnection() creates a WaveQueueConnection (which implements both).</p> <p dir="auto">I would propose to fix this with the following if ... then ... else in SingleConnectionFactory#doCreateConnection() that ensures that the appropriate create method is being called:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="protected Connection doCreateConnection() throws JMSException { ConnectionFactory connfac = getTargetConnectionFactory(); Connection conn = null; if (connfac instanceof QueueConnectionFactory) { conn = ((QueueConnectionFactory) connfac).createQueueConnection(); } else if (connfac instanceof TopicConnectionFactory) { conn = ((TopicConnectionFactory) connfac).createTopicConnection(); } else { conn = connfac.createConnection(); } return conn; }"><pre class="notranslate"><code class="notranslate">protected Connection doCreateConnection() throws JMSException { ConnectionFactory connfac = getTargetConnectionFactory(); Connection conn = null; if (connfac instanceof QueueConnectionFactory) { conn = ((QueueConnectionFactory) connfac).createQueueConnection(); } else if (connfac instanceof TopicConnectionFactory) { conn = ((TopicConnectionFactory) connfac).createTopicConnection(); } else { conn = connfac.createConnection(); } return conn; } </code></pre></div> <p dir="auto">I do perfectly know that a SingleConnectionFactory102 exists which properly handles this, but (a) my provider is JMS 1.1 compliant and (b) I would rather like to use CachedConnectionFactory (not directly SingleConnectionFactory).</p> <p dir="auto">I admit that, if you prefer, this issue could also be resolved by adding a CachedConnectionFactory102 that extends SingleConnectionFactory102.</p> <p dir="auto">Many thanks for considering this fix for the Spring 2.5.x series! :-)</p> <p dir="auto">Best regards,</p> <p dir="auto">Andreas</p> <hr> <p dir="auto"><strong>Affects:</strong> 2.5.3, 2.5.4, 2.5.5</p>
<p dir="auto"><strong><a href="https://jira.spring.io/secure/ViewProfile.jspa?name=lisak" rel="nofollow">Josef Vychtrle</a></strong> opened <strong><a href="https://jira.spring.io/browse/SPR-8600?redirect=false" rel="nofollow">SPR-8600</a></strong> and commented</p> <p dir="auto">There are two major means of data binding initialization, but there is a drawback in the oldschool xml one.</p> <p dir="auto">In short, you can do this :</p> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="@InitBinder(&quot;order&quot;)public void initBinder(WebDataBinder binder) { binder.setAllowedFields(allowedFields.split(&quot;,&quot;)); }"><pre class="notranslate"><span class="pl-c1">@</span><span class="pl-c1">InitBinder</span>(<span class="pl-s">"order"</span>)<span class="pl-k">public</span> <span class="pl-smi">void</span> <span class="pl-s1">initBinder</span>(<span class="pl-smi">WebDataBinder</span> <span class="pl-s1">binder</span>) { <span class="pl-s1">binder</span>.<span class="pl-en">setAllowedFields</span>(<span class="pl-s1">allowedFields</span>.<span class="pl-en">split</span>(<span class="pl-s">","</span>)); }</pre></div> <p dir="auto">but it can't be done with ConfigurableWebBindingInitializer. First off, the binder instance is created in AnnotationMethodHandlerAdapter and initializer is passed the binder instance somewhere in HandlerMethodInvoker so it can't be set up... :</p> <div class="highlight highlight-text-xml notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&lt;bean id=&quot;webBindingInitializer&quot; class=&quot;org.springframework.web.bind.support.ConfigurableWebBindingInitializer&quot;&gt; &lt;property name=&quot;messageCodesResolver&quot; ref=&quot;codesResolver&quot; /&gt; &lt;!-- missing allowed / disallowed / required properties --&gt; &lt;/bean&gt;"><pre class="notranslate">&lt;<span class="pl-ent">bean</span> <span class="pl-e">id</span>=<span class="pl-s"><span class="pl-pds">"</span>webBindingInitializer<span class="pl-pds">"</span></span> <span class="pl-e">class</span>=<span class="pl-s"><span class="pl-pds">"</span>org.springframework.web.bind.support.ConfigurableWebBindingInitializer<span class="pl-pds">"</span></span>&gt; &lt;<span class="pl-ent">property</span> <span class="pl-e">name</span>=<span class="pl-s"><span class="pl-pds">"</span>messageCodesResolver<span class="pl-pds">"</span></span> <span class="pl-e">ref</span>=<span class="pl-s"><span class="pl-pds">"</span>codesResolver<span class="pl-pds">"</span></span> /&gt; <span class="pl-c"><span class="pl-c">&lt;!--</span> missing allowed / disallowed / required properties <span class="pl-c">--&gt;</span></span> &lt;/<span class="pl-ent">bean</span>&gt;</pre></div> <p dir="auto">FIX :<strong>ConfigurableWebBindingInitializer.java</strong></p> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="public void initBinder(WebDataBinder binder, WebRequest request) {if(this.allowedFields != null) { binder.setAllowedFields(allowedFields); } if(this.disallowedFields != null) { binder.setDisallowedFields(disallowedFields); } if(this.allowedFields != null) { binder.setRequiredFields(requiredFields); } if (this.directFieldAccess) { binder.initDirectFieldAccess(); }if (this.messageCodesResolver != null) { binder.setMessageCodesResolver(this.messageCodesResolver); }if (this.bindingErrorProcessor != null) { binder.setBindingErrorProcessor(this.bindingErrorProcessor); }if (this.validator != null &amp;&amp; binder.getTarget() != null &amp;&amp;this.validator.supports(binder.getTarget().getClass())) { binder.setValidator(this.validator); }if (this.conversionService != null) { binder.setConversionService(this.conversionService); }if (this.propertyEditorRegistrars != null) {for (PropertyEditorRegistrar propertyEditorRegistrar : this.propertyEditorRegistrars) { propertyEditorRegistrar.registerCustomEditors(binder); } } }"><pre class="notranslate"><span class="pl-k">public</span> <span class="pl-smi">void</span> <span class="pl-s1">initBinder</span>(<span class="pl-smi">WebDataBinder</span> <span class="pl-s1">binder</span>, <span class="pl-smi">WebRequest</span> <span class="pl-s1">request</span>) {<span class="pl-k">if</span>(<span class="pl-smi">this</span>.<span class="pl-s1">allowedFields</span> != <span class="pl-c1">null</span>) { <span class="pl-s1">binder</span>.<span class="pl-en">setAllowedFields</span>(<span class="pl-s1">allowedFields</span>); } <span class="pl-k">if</span>(<span class="pl-smi">this</span>.<span class="pl-s1">disallowedFields</span> != <span class="pl-c1">null</span>) { <span class="pl-s1">binder</span>.<span class="pl-en">setDisallowedFields</span>(<span class="pl-s1">disallowedFields</span>); } <span class="pl-k">if</span>(<span class="pl-smi">this</span>.<span class="pl-s1">allowedFields</span> != <span class="pl-c1">null</span>) { <span class="pl-s1">binder</span>.<span class="pl-en">setRequiredFields</span>(<span class="pl-s1">requiredFields</span>); } <span class="pl-k">if</span> (<span class="pl-smi">this</span>.<span class="pl-s1">directFieldAccess</span>) { <span class="pl-s1">binder</span>.<span class="pl-en">initDirectFieldAccess</span>(); }<span class="pl-k">if</span> (<span class="pl-smi">this</span>.<span class="pl-s1">messageCodesResolver</span> != <span class="pl-c1">null</span>) { <span class="pl-s1">binder</span>.<span class="pl-en">setMessageCodesResolver</span>(<span class="pl-smi">this</span>.<span class="pl-s1">messageCodesResolver</span>); }<span class="pl-k">if</span> (<span class="pl-smi">this</span>.<span class="pl-s1">bindingErrorProcessor</span> != <span class="pl-c1">null</span>) { <span class="pl-s1">binder</span>.<span class="pl-en">setBindingErrorProcessor</span>(<span class="pl-smi">this</span>.<span class="pl-s1">bindingErrorProcessor</span>); }<span class="pl-k">if</span> (<span class="pl-smi">this</span>.<span class="pl-s1">validator</span> != <span class="pl-c1">null</span> &amp;&amp; <span class="pl-s1">binder</span>.<span class="pl-en">getTarget</span>() != <span class="pl-c1">null</span> &amp;&amp;<span class="pl-smi">this</span>.<span class="pl-s1">validator</span>.<span class="pl-en">supports</span>(<span class="pl-s1">binder</span>.<span class="pl-en">getTarget</span>().<span class="pl-en">getClass</span>())) { <span class="pl-s1">binder</span>.<span class="pl-en">setValidator</span>(<span class="pl-smi">this</span>.<span class="pl-s1">validator</span>); }<span class="pl-k">if</span> (<span class="pl-smi">this</span>.<span class="pl-s1">conversionService</span> != <span class="pl-c1">null</span>) { <span class="pl-s1">binder</span>.<span class="pl-en">setConversionService</span>(<span class="pl-smi">this</span>.<span class="pl-s1">conversionService</span>); }<span class="pl-k">if</span> (<span class="pl-smi">this</span>.<span class="pl-s1">propertyEditorRegistrars</span> != <span class="pl-c1">null</span>) {<span class="pl-k">for</span> (<span class="pl-smi">PropertyEditorRegistrar</span> <span class="pl-s1">propertyEditorRegistrar</span> : <span class="pl-smi">this</span>.<span class="pl-s1">propertyEditorRegistrars</span>) { <span class="pl-s1">propertyEditorRegistrar</span>.<span class="pl-en">registerCustomEditors</span>(<span class="pl-s1">binder</span>); } } }</pre></div> <hr> <p dir="auto"><strong>Affects:</strong> 3.1 M2</p> <p dir="auto"><strong>Reference URL:</strong> <a href="http://stackoverflow.com/q/7014245/306488" rel="nofollow">http://stackoverflow.com/q/7014245/306488</a></p> <p dir="auto"><strong>Issue Links:</strong></p> <ul dir="auto"> <li><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="398113988" data-permission-text="Title is private" data-url="https://github.com/spring-projects/spring-framework/issues/13245" data-hovercard-type="issue" data-hovercard-url="/spring-projects/spring-framework/issues/13245/hovercard" href="https://github.com/spring-projects/spring-framework/issues/13245">#13245</a> ConfigurableWebBindingInitializer should have allowed / disallowed / required fields for DataBinder initialization (<em><strong>"is duplicated by"</strong></em>)</li> </ul>
0
<p dir="auto"><strong>System information</strong>.</p> <p dir="auto">TensorFlow version (you are using): 2.5.0<br> Are you willing to contribute it (Yes/No) : No</p> <p dir="auto"><strong>Describe the feature and the current behavior/state</strong>.</p> <p dir="auto">When I subclass <code class="notranslate">Layer</code> to implement a custom layer, sometimes I need to storage temporary values (e.g. hidden features) in forward propogation (<code class="notranslate">call</code> method) for later use, here is an example:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import tensorflow as tf from tensorflow.keras import layers class MyLayer(layers.Layer): def __init__(self): super().__init__() self.convs = [ layers.Conv2D(64 if i &lt; 2 else 3, (3, 3), strides=2, padding='same') for i in range(3)] def call(self, inputs): gt = inputs['gt'] pred = self.forward(inputs) loss = self.compute_loss(gt, pred) return loss def forward(self, inputs): # implement forward propogation and reserve intermediate feature map sizes self.featmap_sizes = [] feat = image = inputs['image'] for conv in self.convs: feat = tf.nn.relu(conv(feat)) self.featmap_sizes.append(tf.shape(feat)[1:3]) pred = tf.image.resize(feat, tf.shape(image)[1:3], 'bilinear') + image return pred def compute_loss(self, y_true, y_pred): # maybe a simple mse loss return tf.reduce_mean((y_true - y_pred)**2) my_layer = MyLayer() loss = my_layer({ 'image': tf.random.normal((1, 64, 64, 3)), 'gt': tf.random.normal((1, 64, 64, 3)) }) print(my_layer.featmap_sizes)"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">tensorflow</span> <span class="pl-k">as</span> <span class="pl-s1">tf</span> <span class="pl-k">from</span> <span class="pl-s1">tensorflow</span>.<span class="pl-s1">keras</span> <span class="pl-k">import</span> <span class="pl-s1">layers</span> <span class="pl-k">class</span> <span class="pl-v">MyLayer</span>(<span class="pl-s1">layers</span>.<span class="pl-v">Layer</span>): <span class="pl-k">def</span> <span class="pl-en">__init__</span>(<span class="pl-s1">self</span>): <span class="pl-en">super</span>().<span class="pl-en">__init__</span>() <span class="pl-s1">self</span>.<span class="pl-s1">convs</span> <span class="pl-c1">=</span> [ <span class="pl-s1">layers</span>.<span class="pl-v">Conv2D</span>(<span class="pl-c1">64</span> <span class="pl-k">if</span> <span class="pl-s1">i</span> <span class="pl-c1">&lt;</span> <span class="pl-c1">2</span> <span class="pl-k">else</span> <span class="pl-c1">3</span>, (<span class="pl-c1">3</span>, <span class="pl-c1">3</span>), <span class="pl-s1">strides</span><span class="pl-c1">=</span><span class="pl-c1">2</span>, <span class="pl-s1">padding</span><span class="pl-c1">=</span><span class="pl-s">'same'</span>) <span class="pl-k">for</span> <span class="pl-s1">i</span> <span class="pl-c1">in</span> <span class="pl-en">range</span>(<span class="pl-c1">3</span>)] <span class="pl-k">def</span> <span class="pl-en">call</span>(<span class="pl-s1">self</span>, <span class="pl-s1">inputs</span>): <span class="pl-s1">gt</span> <span class="pl-c1">=</span> <span class="pl-s1">inputs</span>[<span class="pl-s">'gt'</span>] <span class="pl-s1">pred</span> <span class="pl-c1">=</span> <span class="pl-s1">self</span>.<span class="pl-en">forward</span>(<span class="pl-s1">inputs</span>) <span class="pl-s1">loss</span> <span class="pl-c1">=</span> <span class="pl-s1">self</span>.<span class="pl-en">compute_loss</span>(<span class="pl-s1">gt</span>, <span class="pl-s1">pred</span>) <span class="pl-k">return</span> <span class="pl-s1">loss</span> <span class="pl-k">def</span> <span class="pl-en">forward</span>(<span class="pl-s1">self</span>, <span class="pl-s1">inputs</span>): <span class="pl-c"># implement forward propogation and reserve intermediate feature map sizes</span> <span class="pl-s1">self</span>.<span class="pl-s1">featmap_sizes</span> <span class="pl-c1">=</span> [] <span class="pl-s1">feat</span> <span class="pl-c1">=</span> <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-s1">inputs</span>[<span class="pl-s">'image'</span>] <span class="pl-k">for</span> <span class="pl-s1">conv</span> <span class="pl-c1">in</span> <span class="pl-s1">self</span>.<span class="pl-s1">convs</span>: <span class="pl-s1">feat</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">nn</span>.<span class="pl-en">relu</span>(<span class="pl-en">conv</span>(<span class="pl-s1">feat</span>)) <span class="pl-s1">self</span>.<span class="pl-s1">featmap_sizes</span>.<span class="pl-en">append</span>(<span class="pl-s1">tf</span>.<span class="pl-en">shape</span>(<span class="pl-s1">feat</span>)[<span class="pl-c1">1</span>:<span class="pl-c1">3</span>]) <span class="pl-s1">pred</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">resize</span>(<span class="pl-s1">feat</span>, <span class="pl-s1">tf</span>.<span class="pl-en">shape</span>(<span class="pl-s1">image</span>)[<span class="pl-c1">1</span>:<span class="pl-c1">3</span>], <span class="pl-s">'bilinear'</span>) <span class="pl-c1">+</span> <span class="pl-s1">image</span> <span class="pl-k">return</span> <span class="pl-s1">pred</span> <span class="pl-k">def</span> <span class="pl-en">compute_loss</span>(<span class="pl-s1">self</span>, <span class="pl-s1">y_true</span>, <span class="pl-s1">y_pred</span>): <span class="pl-c"># maybe a simple mse loss</span> <span class="pl-k">return</span> <span class="pl-s1">tf</span>.<span class="pl-en">reduce_mean</span>((<span class="pl-s1">y_true</span> <span class="pl-c1">-</span> <span class="pl-s1">y_pred</span>)<span class="pl-c1">**</span><span class="pl-c1">2</span>) <span class="pl-s1">my_layer</span> <span class="pl-c1">=</span> <span class="pl-v">MyLayer</span>() <span class="pl-s1">loss</span> <span class="pl-c1">=</span> <span class="pl-en">my_layer</span>({ <span class="pl-s">'image'</span>: <span class="pl-s1">tf</span>.<span class="pl-s1">random</span>.<span class="pl-en">normal</span>((<span class="pl-c1">1</span>, <span class="pl-c1">64</span>, <span class="pl-c1">64</span>, <span class="pl-c1">3</span>)), <span class="pl-s">'gt'</span>: <span class="pl-s1">tf</span>.<span class="pl-s1">random</span>.<span class="pl-en">normal</span>((<span class="pl-c1">1</span>, <span class="pl-c1">64</span>, <span class="pl-c1">64</span>, <span class="pl-c1">3</span>)) }) <span class="pl-en">print</span>(<span class="pl-s1">my_layer</span>.<span class="pl-s1">featmap_sizes</span>)</pre></div> <p dir="auto">It works fine when not using distribute strategy (or default strategy <code class="notranslate">tf.distribute.get_strategy()</code>), <code class="notranslate">self.featmap_sizes</code> is a list of three tensors (in this case [[32, 32], [16, 16], [8, 8]]). But when running under MirroredStrategy, I found that <code class="notranslate">self.featmap_sizes</code> may contain more than three tensors, and the order of tensors may be wrong:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="# assume we have 2 GPUs distribute_strategy = tf.distribute.MirroredStrategy() with distribute_strategy.scope(): my_layer2 = MyLayer() data = distribute_strategy.experimental_distribute_values_from_function( lambda ctx: { 'image': tf.random.normal((1, 64, 64, 3)), 'gt': tf.random.normal((1, 64, 64, 3)) }) loss = distribute_strategy.run(my_layer2, args=(data,)) print(my_layer2.featmap_sizes)"><pre class="notranslate"><span class="pl-c"># assume we have 2 GPUs</span> <span class="pl-s1">distribute_strategy</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">distribute</span>.<span class="pl-v">MirroredStrategy</span>() <span class="pl-k">with</span> <span class="pl-s1">distribute_strategy</span>.<span class="pl-en">scope</span>(): <span class="pl-s1">my_layer2</span> <span class="pl-c1">=</span> <span class="pl-v">MyLayer</span>() <span class="pl-s1">data</span> <span class="pl-c1">=</span> <span class="pl-s1">distribute_strategy</span>.<span class="pl-en">experimental_distribute_values_from_function</span>( <span class="pl-k">lambda</span> <span class="pl-s1">ctx</span>: { <span class="pl-s">'image'</span>: <span class="pl-s1">tf</span>.<span class="pl-s1">random</span>.<span class="pl-en">normal</span>((<span class="pl-c1">1</span>, <span class="pl-c1">64</span>, <span class="pl-c1">64</span>, <span class="pl-c1">3</span>)), <span class="pl-s">'gt'</span>: <span class="pl-s1">tf</span>.<span class="pl-s1">random</span>.<span class="pl-en">normal</span>((<span class="pl-c1">1</span>, <span class="pl-c1">64</span>, <span class="pl-c1">64</span>, <span class="pl-c1">3</span>)) }) <span class="pl-s1">loss</span> <span class="pl-c1">=</span> <span class="pl-s1">distribute_strategy</span>.<span class="pl-en">run</span>(<span class="pl-s1">my_layer2</span>, <span class="pl-s1">args</span><span class="pl-c1">=</span>(<span class="pl-s1">data</span>,)) <span class="pl-en">print</span>(<span class="pl-s1">my_layer2</span>.<span class="pl-s1">featmap_sizes</span>)</pre></div> <p dir="auto">As expected, <code class="notranslate">loss</code> is a <code class="notranslate">PerReplica</code> tensor but <code class="notranslate">self.featmap_sizes</code> is not, <code class="notranslate">self.featmap_sizes</code> contains normal <code class="notranslate">tf.Tensor</code> object. What's even weirder is that it sometimes contains more than 3 values (This is just a simple example, in such a simple case the exception won't always appear).</p> <p dir="auto">Now I have two questions:</p> <ul dir="auto"> <li>Whether tensor aggregation (not the reduction of <code class="notranslate">tf.Variable</code>) cross replicas is only for output tensors of function run by <code class="notranslate">distribute_strategy.run</code> ? (As in the example above, the returned loss is aggregated as <code class="notranslate">PerReplica</code>, but the property <code class="notranslate">self.featmap_sizes</code> is not). Sorry I didn't find the description of this part in the <a href="https://tensorflow.google.cn/api_docs/python/tf/distribute/Strategy?hl=en#run" rel="nofollow">tensorflow document</a>. Since I'm using keras to customize the nearul network component, I'm wondering what happens when I assign or append values to a layer's properties in a distributed situation.</li> <li>Why does the problem of abnormal property value occur? I'm guessing that since MirroredStrategy is single-process, the layer's property assignment or append operation may be duplicated or overwritten between different devices (maybe they are running in different threads? I have no idea). When I reviewed the source code of keras <code class="notranslate">Layer</code>, I found that it defines a <code class="notranslate">self._thread_local</code> attribute in the constructor, Is this related to the problem I stated? Do I need to save the temporary tensors I need in <code class="notranslate">self._thread_local</code> like <code class="notranslate">self._thread_local.featmap_sizes = []</code>? Sorry I didn't see anything about <code class="notranslate">self._thread_local</code> in the <a href="https://tensorflow.google.cn/api_docs/python/tf/keras/layers/Layer?hl=en" rel="nofollow">document of keras Layer</a>.</li> </ul> <p dir="auto">My hope is that each device (replica) should only operate on its own values in a distributed case, and should not flow between replicas without artificial aggregation. If this mechanism has been implicitly implemented, I hope that the official can supplement this description in the document or tutorials. Thank you~</p> <p dir="auto"><strong>Will this change the current api? How?</strong><br> No</p> <p dir="auto"><strong>Who will benefit from this feature?</strong><br> Anyone who want to customize complex functions in keras Layer subclassing under MirroredStrategy.</p> <p dir="auto"><strong><a href="https://github.com/keras-team/keras/blob/master/CONTRIBUTING.md">Contributing</a></strong></p> <ul dir="auto"> <li>Do you want to contribute a PR? (yes/no): no</li> <li>If yes, please read <a href="https://github.com/keras-team/keras/blob/master/CONTRIBUTING.md">this page</a> for instructions</li> <li>Briefly describe your candidate solution(if contributing):</li> </ul>
<p dir="auto">Hello,</p> <p dir="auto">Never contributed to Keras before, but I am interested in creating a PR with a new feature, but before I do so, I want to get feedback and check if it would be accepted :P</p> <p dir="auto">The function ``fit_generator'' is extremely useful, but it is difficult to use parallelized. It expects a generator, which are not thread-safe in Python. Alternatively, it can run each generator on a different process, but then it is likely that you would end with duplicated observations across processes since generators can't talk to each other.</p> <p dir="auto">The class <a href="https://keras.io/utils/" rel="nofollow"><code class="notranslate">keras.utils.Sequence</code></a> is a very useful work-around, but it's not very well documented and not easy to use (it requires an undocumented <code class="notranslate">OrderedEnqueuer</code> wrapper, etc.) I am interested in creating a <code class="notranslate">fit_sequence</code> method that takes care of this.</p> <p dir="auto">Thoughts?</p> <p dir="auto">Thanks,<br> Jose</p>
0
<p dir="auto">This is the code that I have put in. When I test the link myself, it does everything the challenge mentions. I am just unable to complete this challenge. Am I missing something?</p> <p dir="auto">Challenge <a href="http://beta.freecodecamp.com/en/challenges/applied-visual-design/adjust-the-hover-state-of-an-anchor-tag" rel="nofollow">adjust-the-hover-state-of-an-anchor-tag</a> has an issue.<br> User Agent is: <code class="notranslate">Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.87 Safari/537.36</code>.<br> Please describe how to reproduce this issue, and include links to screenshots if possible.</p> <div class="highlight highlight-text-html-basic notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" &lt;style&gt; a { color: #000; } a:hover{ color: #00F; text-decoration: none; } &lt;/style&gt; &lt;a href=&quot;https://atjonathan.github.io/catphotoapp&quot;&gt;CatPhotoApp&lt;/a&gt; "><pre class="notranslate"><span class="pl-kos">&lt;</span><span class="pl-ent">style</span><span class="pl-kos">&gt;</span> <span class="pl-ent">a</span> { <span class="pl-c1">color</span><span class="pl-kos">:</span> <span class="pl-pds"><span class="pl-kos">#</span>000</span>; } <span class="pl-ent">a</span><span class="pl-kos">:</span><span class="pl-c1">hover</span>{ <span class="pl-c1">color</span><span class="pl-kos">:</span> <span class="pl-pds"><span class="pl-kos">#</span>00F</span>; <span class="pl-c1">text-decoration</span><span class="pl-kos">:</span> none; } <span class="pl-kos">&lt;/</span><span class="pl-ent">style</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">a</span> <span class="pl-c1">href</span>="<span class="pl-s">https://atjonathan.github.io/catphotoapp</span>"<span class="pl-kos">&gt;</span>CatPhotoApp<span class="pl-kos">&lt;/</span><span class="pl-ent">a</span><span class="pl-kos">&gt;</span></pre></div>
<p dir="auto">Challenge <a href="http://beta.freecodecamp.com/en/challenges/applied-visual-design/adjust-the-hover-state-of-an-anchor-tag" rel="nofollow">adjust-the-hover-state-of-an-anchor-tag</a> has an issue.</p> <p dir="auto">I think this challenge should be changed, I'll list some reasons:</p> <ul dir="auto"> <li>Right now the challenge shows two new concepts, hover and text-decoration: none, when the overall teaching style is one concept per challenge</li> <li>Here pseudo-classes are introduced for the first time in the curriculum, I think the description is too concise and could leave a beginner with a lot of doubts.</li> <li>There is not an example showing how to use :hover with a selector.</li> </ul> <p dir="auto">My suggestion:</p> <ul dir="auto"> <li>Split the challenge in two, one for hover, one for text-transform: none.</li> <li>Enhance the description, including a practical example.</li> </ul>
1
<div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="23:07 &lt; balpert&gt; can we add &lt;Namespaced.Things /&gt; to JSX? 23:07 &lt; jwalke&gt; I like that you chose the dot! 23:07 &lt; jwalke&gt; Keep it javascript-first. 23:07 &lt; balpert&gt; yes 23:08 &lt; balpert&gt; translating colon to dot would be absurd 23:08 &lt; balpert&gt; (in my opinion) 23:08 &lt; jwalke&gt; So you could have var MyComponentsPackage = {Typeahead: R.createClass.. } 23:08 &lt; jwalke&gt; &lt;MyComponentsPackage.Typeahead /&gt; 23:08 &lt; jwalke&gt; I like it. 23:08 &lt; jwalke&gt; Make an issue!"><pre class="notranslate"><code class="notranslate">23:07 &lt; balpert&gt; can we add &lt;Namespaced.Things /&gt; to JSX? 23:07 &lt; jwalke&gt; I like that you chose the dot! 23:07 &lt; jwalke&gt; Keep it javascript-first. 23:07 &lt; balpert&gt; yes 23:08 &lt; balpert&gt; translating colon to dot would be absurd 23:08 &lt; balpert&gt; (in my opinion) 23:08 &lt; jwalke&gt; So you could have var MyComponentsPackage = {Typeahead: R.createClass.. } 23:08 &lt; jwalke&gt; &lt;MyComponentsPackage.Typeahead /&gt; 23:08 &lt; jwalke&gt; I like it. 23:08 &lt; jwalke&gt; Make an issue! </code></pre></div>
<p dir="auto">I came up with a rather crude (but I think promising) way to autogen component rendering tests. I'm throwing a big list of values at my components' propTypes validators (kind of like using a fuzzer). I use that to construct a set of supposedly-valid values for each prop, and subsequently combine those into supposedly-valid sets of props.</p> <p dir="auto">With direct calling of prop validators being deprecated, is there some other way to accomplish this that I'm missing? I think this test generator would be really useful, but given that I'm dependent on a deprecated feature, I'm not clear if it has a future.</p> <p dir="auto">fiddle demo: <a href="https://jsfiddle.net/6g3r6amb/1/" rel="nofollow">https://jsfiddle.net/6g3r6amb/1/</a></p>
0
<p dir="auto">From <a href="http://symfony.com/doc/current/reference/forms/types/repeated.html" rel="nofollow">the docs</a>:</p> <blockquote> <p dir="auto">This is a special field "group", that creates two identical fields whose values must match (or a validation error is thrown). The most common use is when you need the user to repeat their password or email to verify accuracy.</p> </blockquote> <p dir="auto">In other words, the form should not be valid if values are mismatched. But when a form is submitted with mismatched values in a repeated type <code class="notranslate">Form::isValid</code> returns true. No validation error is thrown, and the value from the repeated field is null. The null value <a href="https://github.com/symfony/symfony/blob/f8fb8a98b2f9d797483a020cee3ec6ad2e82c366/src/Symfony/Component/Form/Tests/Extension/Core/Type/RepeatedTypeTest.php#L167">seems to be expected</a>, but <strong>why is the form a valid submission?</strong></p> <p dir="auto">There is the correct error in <code class="notranslate">Form::$transformationFailure</code> but it doesn't seem to impact the form errors.</p> <p dir="auto"><a href="https://gist.github.com/chrisguitarguy/25436e46764719aa0f54">Here is a little silex app</a> with a repeated field to illustrate.</p> <p dir="auto">If this is expected behavior feel free to close. If that is the case the docs need some work to clear up expectations about what the repeated type does.</p>
<p dir="auto">I was using Silex with Symfony 2.5.7. Form validation broke when I updated to version 2.6.0.</p> <p dir="auto">Here's the <code class="notranslate">buildForm</code> method defined for my <code class="notranslate">PasswordResetType</code>:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="function buildForm(FormBuilderInterface $builder, array $options) { $builder -&gt;add('password', 'repeated', array( 'type' =&gt; 'password', 'invalid_message' =&gt; $this-&gt;app['translator']-&gt;trans('form_errors.pass_must_match'), 'required' =&gt; true, 'first_options' =&gt; array( 'constraints' =&gt; array( new Assert\NotBlank() ), ), 'second_options' =&gt; array( 'constraints' =&gt; array( new Assert\NotBlank() ) ) )) ; } }"><pre class="notranslate"><code class="notranslate">function buildForm(FormBuilderInterface $builder, array $options) { $builder -&gt;add('password', 'repeated', array( 'type' =&gt; 'password', 'invalid_message' =&gt; $this-&gt;app['translator']-&gt;trans('form_errors.pass_must_match'), 'required' =&gt; true, 'first_options' =&gt; array( 'constraints' =&gt; array( new Assert\NotBlank() ), ), 'second_options' =&gt; array( 'constraints' =&gt; array( new Assert\NotBlank() ) ) )) ; } } </code></pre></div> <p dir="auto">The Twig template associated to my form:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="{{ form_start(form) }} {{ form_widget(form._token) }} {{ form_errors(form) }} &lt;div class=&quot;form-group&quot;&gt; {{ form_label(form.password.first, 'user.new_password'|trans, {'label_attr': {'class': 'control-label'}}) }} {{ form_errors(form.password.first) }} {{ form_widget(form.password.first, {'attr': {'class': 'form-control', 'placeholder' : 'user.new_password'|trans}}) }} &lt;/div&gt; &lt;div class=&quot;form-group&quot;&gt; {{ form_label(form.password.second, 'user.new_password_confirmation'|trans, {'label_attr': {'class': 'control-label'}}) }} {{ form_errors(form.password.second) }} {{ form_widget(form.password.second, {'attr': {'class': 'form-control', 'placeholder' : 'user.new_password_confirmation'|trans}}) }} &lt;/div&gt; &lt;button type=&quot;submit&quot; class=&quot;btn btn-primary btn-block&quot;&gt;{{'user.reset_password'|trans}}&lt;/button&gt; {{ form_end(form) }}"><pre class="notranslate"><code class="notranslate">{{ form_start(form) }} {{ form_widget(form._token) }} {{ form_errors(form) }} &lt;div class="form-group"&gt; {{ form_label(form.password.first, 'user.new_password'|trans, {'label_attr': {'class': 'control-label'}}) }} {{ form_errors(form.password.first) }} {{ form_widget(form.password.first, {'attr': {'class': 'form-control', 'placeholder' : 'user.new_password'|trans}}) }} &lt;/div&gt; &lt;div class="form-group"&gt; {{ form_label(form.password.second, 'user.new_password_confirmation'|trans, {'label_attr': {'class': 'control-label'}}) }} {{ form_errors(form.password.second) }} {{ form_widget(form.password.second, {'attr': {'class': 'form-control', 'placeholder' : 'user.new_password_confirmation'|trans}}) }} &lt;/div&gt; &lt;button type="submit" class="btn btn-primary btn-block"&gt;{{'user.reset_password'|trans}}&lt;/button&gt; {{ form_end(form) }} </code></pre></div> <p dir="auto">The associated controllers:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$app-&gt;get('/{_locale}/reset_password/{token}', function(Request $request, $token) use ($app) { /* ... */ $form = $app['form.factory']-&gt;create(new PasswordResetType($app), array()); return $app['twig']-&gt;render('password_reset.twig', array( 'title' =&gt; 'Page title', 'form' =&gt; $form-&gt;createView() )); })-&gt;bind('reset_password'); $app-&gt;post('/{_locale}/reset_password/{token}', function(Request $request, $token) use ($app) { /* ... */ $form = $app['form.factory']-&gt;create(new PasswordResetType($app), array()); $form-&gt;handleRequest($request); if ($form-&gt;isValid()) { $data = $form-&gt;getData(); $password = $data['password']; // this is line 113 /* ... */ } });"><pre class="notranslate"><code class="notranslate">$app-&gt;get('/{_locale}/reset_password/{token}', function(Request $request, $token) use ($app) { /* ... */ $form = $app['form.factory']-&gt;create(new PasswordResetType($app), array()); return $app['twig']-&gt;render('password_reset.twig', array( 'title' =&gt; 'Page title', 'form' =&gt; $form-&gt;createView() )); })-&gt;bind('reset_password'); $app-&gt;post('/{_locale}/reset_password/{token}', function(Request $request, $token) use ($app) { /* ... */ $form = $app['form.factory']-&gt;create(new PasswordResetType($app), array()); $form-&gt;handleRequest($request); if ($form-&gt;isValid()) { $data = $form-&gt;getData(); $password = $data['password']; // this is line 113 /* ... */ } }); </code></pre></div> <p dir="auto">This generates the following error when passwords don't match: <code class="notranslate">Error: ContextErrorException in controllers_users.php line 113: Notice: Undefined index: password</code>. This indicates <code class="notranslate">$form-&gt;isValid()</code> returned <code class="notranslate">true</code> while it shouldn't have, since the passwords don't match.</p>
1
<h1 dir="auto">Bug report</h1> <h2 dir="auto">Describe the bug</h2> <p dir="auto">So there is a <code class="notranslate">./pages/_document.js</code> and <code class="notranslate">&lt;NextScript /&gt;</code>, even if you remove it next.js will include all the bundles. I'm curious why <code class="notranslate">&lt;NextScript /&gt;</code> seems to not matter. Nothing changes if I remove it or add it back.</p> <h2 dir="auto">To Reproduce</h2> <p dir="auto">Steps to reproduce the behavior, please provide code snippets or a repository:</p> <ol dir="auto"> <li>Go to <a href="https://with-nextscript-llzwhvgbup.now.sh" rel="nofollow">https://with-nextscript-llzwhvgbup.now.sh</a> (it is <a href="https://github.com/zeit/next.js/tree/canary/examples/with-emotion">with-emotion example</a> deployed as is)</li> <li>Check Network tab in dev tools</li> <li>Scripts are being dowloaded</li> <li>Go to <a href="https://without-nextscript-vmfhuqxgbt.now.sh" rel="nofollow">https://without-nextscript-vmfhuqxgbt.now.sh</a> (it is <a href="https://github.com/zeit/next.js/tree/canary/examples/with-emotion">with-emotion example</a> with removed <code class="notranslate">&lt;NextScript /&gt;</code> and deployed)</li> <li>Check Network tab in dev tools</li> <li>Scripts are <strong>still</strong> being dowloaded</li> </ol> <p dir="auto">build process is <code class="notranslate">next build &amp;&amp; next export</code></p> <h2 dir="auto">Expected behavior</h2> <p dir="auto">No scripts should be in place</p> <h2 dir="auto">Screenshots</h2> <p dir="auto">N/A</p> <h2 dir="auto">System information</h2> <ul dir="auto"> <li>OS: macOS 10.13.4</li> <li>Browser N/A</li> <li>Version of Next.js: latest</li> </ul> <h2 dir="auto">Additional context</h2> <p dir="auto">kinda related <a href="https://spectrum.chat/thread/3f923307-a694-4af5-b000-517a7e26c0d7" rel="nofollow">https://spectrum.chat/thread/3f923307-a694-4af5-b000-517a7e26c0d7</a><br> I tried to achieve approach described in this tweet <a href="https://twitter.com/_davideast/status/1009112973439393795" rel="nofollow">https://twitter.com/_davideast/status/1009112973439393795</a></p>
<h1 dir="auto">Feature request</h1> <h2 dir="auto">Is your feature request related to a problem? Please describe.</h2> <p dir="auto">We want some static pages to be as lightweight as possible and we're fine with full page reloads navigating out of them if we can chop off extra 200Kb.</p> <h2 dir="auto">Describe the solution you'd like</h2> <p dir="auto">Add an option to path map in next.config.js to indicate this specific page doesn't need to include react app and can operate as plain HTML page.<br> React app is only removed in case the flag is set to <code class="notranslate">true</code> explicitly.</p> <p dir="auto">Looks like it should be enough to just make <code class="notranslate">files</code> content empty there if option is set. <a href="https://github.com/zeit/next.js/blob/canary/server/render.js#L100">https://github.com/zeit/next.js/blob/canary/server/render.js#L100</a></p> <p dir="auto">For the simple example from tutorial setting up</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="// next.config.js module.exports = { exportPathMap: function(defaultPathMap) { return { '/': { page: '/', withoutReact: true }, '/about': { page: '/about' } } } }"><pre class="notranslate"><span class="pl-c">// next.config.js</span> <span class="pl-smi">module</span><span class="pl-kos">.</span><span class="pl-c1">exports</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span> <span class="pl-en">exportPathMap</span>: <span class="pl-k">function</span><span class="pl-kos">(</span><span class="pl-s1">defaultPathMap</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">return</span> <span class="pl-kos">{</span> <span class="pl-s">'/'</span>: <span class="pl-kos">{</span> <span class="pl-c1">page</span>: <span class="pl-s">'/'</span><span class="pl-kos">,</span> <span class="pl-c1">withoutReact</span>: <span class="pl-c1">true</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">'/about'</span>: <span class="pl-kos">{</span> <span class="pl-c1">page</span>: <span class="pl-s">'/about'</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span></pre></div> <p dir="auto">As a result <code class="notranslate">/out</code> would be populated with</p> <div class="highlight highlight-text-html-basic notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&lt;!--/out/index/index.html--&gt; &lt;!DOCTYPE html&gt; &lt;html&gt; &lt;head&gt; &lt;meta charSet=&quot;utf-8&quot; class=&quot;next-head&quot;/&gt; &lt;/head&gt; &lt;body&gt; &lt;a href=&quot;/about&quot;&gt;About&lt;/a&gt; &lt;/body&gt; &lt;/html&gt; &lt;!--/out/about/index.html--&gt; &lt;!DOCTYPE html&gt; &lt;html&gt; &lt;head&gt; &lt;meta charSet=&quot;utf-8&quot; class=&quot;next-head&quot;/&gt; &lt;link rel=&quot;preload&quot; href=&quot;/_next/9d298d49-6fb5-4c6f-a992-31fdb0d3e01a/page/about.js&quot; as=&quot;script&quot;/&gt; &lt;!--other scripts--&gt; &lt;/head&gt; &lt;body&gt; &lt;!--page content --&gt; &lt;script&gt; NEXT_DATA = {&quot;props&quot;: &quot;etc..&quot;} &lt;/script&gt; &lt;script id=&quot;__NEXT_PAGE__/about&quot; src=&quot;...&quot;&gt;&lt;/script&gt; &lt;/body&gt; &lt;/html&gt;"><pre class="notranslate"><span class="pl-c">&lt;!--/out/index/index.html--&gt;</span> <span class="pl-c1">&lt;!DOCTYPE html<span class="pl-kos">&gt;</span></span> <span class="pl-kos">&lt;</span><span class="pl-ent">html</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">head</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">meta</span> <span class="pl-c1">charSet</span>="<span class="pl-s">utf-8</span>" <span class="pl-c1">class</span>="<span class="pl-s">next-head</span>"/&gt; <span class="pl-kos">&lt;/</span><span class="pl-ent">head</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">body</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">a</span> <span class="pl-c1">href</span>="<span class="pl-s">/about</span>"<span class="pl-kos">&gt;</span>About<span class="pl-kos">&lt;/</span><span class="pl-ent">a</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">body</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">html</span><span class="pl-kos">&gt;</span> <span class="pl-c">&lt;!--/out/about/index.html--&gt;</span> <span class="pl-c1">&lt;!DOCTYPE html<span class="pl-kos">&gt;</span></span> <span class="pl-kos">&lt;</span><span class="pl-ent">html</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">head</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">meta</span> <span class="pl-c1">charSet</span>="<span class="pl-s">utf-8</span>" <span class="pl-c1">class</span>="<span class="pl-s">next-head</span>"/&gt; <span class="pl-kos">&lt;</span><span class="pl-ent">link</span> <span class="pl-c1">rel</span>="<span class="pl-s">preload</span>" <span class="pl-c1">href</span>="<span class="pl-s">/_next/9d298d49-6fb5-4c6f-a992-31fdb0d3e01a/page/about.js</span>" <span class="pl-c1">as</span>="<span class="pl-s">script</span>"/&gt; <span class="pl-c">&lt;!--other scripts--&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">head</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">body</span><span class="pl-kos">&gt;</span> <span class="pl-c">&lt;!--page content --&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">script</span><span class="pl-kos">&gt;</span> <span class="pl-c1">NEXT_DATA</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span><span class="pl-s">"props"</span>: <span class="pl-s">"etc.."</span><span class="pl-kos">}</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">script</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">script</span> <span class="pl-c1">id</span>="<span class="pl-s">__NEXT_PAGE__/about</span>" <span class="pl-c1">src</span>="<span class="pl-s">...</span>"<span class="pl-kos">&gt;</span><span class="pl-kos">&lt;/</span><span class="pl-ent">script</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">body</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">html</span><span class="pl-kos">&gt;</span></pre></div> <p dir="auto">This way index page is going to be very lightweight, with a tradeoff of full page reload navigating to /about. While /about would load the app, so navigation back to / would be handled on the client-side.</p> <h2 dir="auto">Describe alternatives you've considered</h2> <p dir="auto">Static site generators :) But we need way more than just static pages and next.js fits us best except for this tiny quirk.</p> <h2 dir="auto">Additional context</h2> <p dir="auto">Happy to implement that, just wanted to make sure this is not something going against the roadmap for next.js. Or if it's something already available, but hidden. I'm new to the library, only playing around for the second day.</p>
1
<p dir="auto">Tooltips on links, when placed inside the accordion, are being cut off.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/874a2256791098d71e048948512b8d997fbf8f96471a5d6ffd03ddb253889c42/68747470733a2f2f662e636c6f75642e6769746875622e636f6d2f6173736574732f3837323733302f3533353930362f31313130626566302d633134642d313165322d396432332d6565323238613534373735612e706e67"><img src="https://camo.githubusercontent.com/874a2256791098d71e048948512b8d997fbf8f96471a5d6ffd03ddb253889c42/68747470733a2f2f662e636c6f75642e6769746875622e636f6d2f6173736574732f3837323733302f3533353930362f31313130626566302d633134642d313165322d396432332d6565323238613534373735612e706e67" alt="screen shot 2013-05-20 at 14 58 18" data-canonical-src="https://f.cloud.github.com/assets/872730/535906/1110bef0-c14d-11e2-9d23-ee228a54775a.png" style="max-width: 100%;"></a></p> <p dir="auto">Setting <code class="notranslate">.collapse { position: static; }</code> (now: relative) clears the issue.</p> <p dir="auto">Example: <a href="http://jsfiddle.net/TravellerSam/R55vg/" rel="nofollow">http://jsfiddle.net/TravellerSam/R55vg/</a></p>
<p dir="auto">In the case of popovers close to the edge of an accordion, the popover was being truncated.<br> The following change fixed it for our usage</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=".accordion-body.in { overflow:visible; }"><pre class="notranslate"><code class="notranslate">.accordion-body.in { overflow:visible; } </code></pre></div>
1
<p dir="auto">by <strong>axel.schreiner</strong>:</p> <pre class="notranslate">This is using 'hg update release' on MacOS X Lion (hg update default and ./all.bash fail early on). Based on the package documentation I believe that data can be transfered to and from an interface-typed variable. This does not seem to be the case. The attached program can be run with the arguments ss is si ii to select a transfer from and to a struct or an interface. Additionally, the argument reg will register the structure with gob, but that does not change anything. What steps will reproduce the problem? 1. compile the attached file 2. run it with options ss and is -- no error message. 3. run it with options si or ii -- error message from gob. What is the expected output? No error message in case 3. What do you see instead? decoding error gob: wrong type received for local value main.Mer: Foo = struct { Bar string; Beque string; } Which compiler are you using (5g, 6g, 8g, gccgo)? 6g Which operating system are you using? MacOS X Lion Which revision are you using? (hg identify) c1702f36df03 (release-branch.r60) release/release.r60.3</pre> <p dir="auto">Attachments:</p> <ol dir="auto"> <li><a href="https://storage.googleapis.com/go-attachment/2938/0/demo.go" rel="nofollow">demo.go</a> (1446 bytes)</li> </ol>
<p dir="auto">The documentation for time.String() shows the format used to convert time into a string: <a href="http://golang.org/pkg/time/#Time.String" rel="nofollow">http://golang.org/pkg/time/#Time.String</a>.</p> <p dir="auto">This string appears to be different to the const formats already defined in the time package, so if I wanted to naively (not using time.Format) convert a time -&gt; string -&gt; time I'd need to copy the format from the docs into my code and use it in a call to time.Parse.</p> <p dir="auto">In addition this format string is used a few times in <a href="http://golang.org/src/time/format_test.go" rel="nofollow">http://golang.org/src/time/format_test.go</a> as a literal string.</p> <p dir="auto">Isn't this format string a good candidate to be placed in the consts?</p>
0
<h5 dir="auto">ISSUE TYPE</h5> <ul dir="auto"> <li>Bug Report</li> </ul> <h5 dir="auto">COMPONENT NAME</h5> <p dir="auto">core</p> <h5 dir="auto">ANSIBLE VERSION</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[root@172-20-12-5 ~]# ansible --version ansible 1.9.6 configured module search path = None [root@172-20-12-5 ~]#"><pre class="notranslate"><code class="notranslate">[root@172-20-12-5 ~]# ansible --version ansible 1.9.6 configured module search path = None [root@172-20-12-5 ~]# </code></pre></div> <h5 dir="auto">CONFIGURATION</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[root@172-20-12-5 ~]# cat /etc/ansible/ansible.cfg # config file for ansible -- http://ansible.com/ # ============================================== # nearly all parameters can be overridden in ansible-playbook # or with command line flags. ansible will read ANSIBLE_CONFIG, # ansible.cfg in the current working directory, .ansible.cfg in # the home directory or /etc/ansible/ansible.cfg, whichever it # finds first [defaults] # some basic default values... inventory = /etc/ansible/hosts #library = /usr/share/my_modules/ remote_tmp = $HOME/.ansible/tmp pattern = * forks = 5 poll_interval = 15 sudo_user = root #ask_sudo_pass = True #ask_pass = True transport = smart #remote_port = 22 module_lang = C # plays will gather facts by default, which contain information about # the remote system. # # smart - gather by default, but don't regather if already gathered # implicit - gather by default, turn off with gather_facts: False # explicit - do not gather by default, must say gather_facts: True gathering = implicit # additional paths to search for roles in, colon separated #roles_path = /etc/ansible/roles # uncomment this to disable SSH key host checking #host_key_checking = False # change this for alternative sudo implementations sudo_exe = sudo # what flags to pass to sudo #sudo_flags = -H # SSH timeout timeout = 10 # default user to use for playbooks if user is not specified # (/usr/bin/ansible will use current user as default) #remote_user = root # logging is off by default unless this path is defined # if so defined, consider logrotate #log_path = /var/log/ansible.log # default module name for /usr/bin/ansible #module_name = command # use this shell for commands executed under sudo # you may need to change this to bin/bash in rare instances # if sudo is constrained #executable = /bin/sh # if inventory variables overlap, does the higher precedence one win # or are hash values merged together? The default is 'replace' but # this can also be set to 'merge'. #hash_behaviour = replace # list any Jinja2 extensions to enable here: #jinja2_extensions = jinja2.ext.do,jinja2.ext.i18n # if set, always use this private key file for authentication, same as # if passing --private-key to ansible or ansible-playbook #private_key_file = /path/to/file # format of string {{ ansible_managed }} available within Jinja2 # templates indicates to users editing templates files will be replaced. # replacing {file}, {host} and {uid} and strftime codes with proper values. ansible_managed = Ansible managed: {file} modified on %Y-%m-%d %H:%M:%S by {uid} on {host} # by default, ansible-playbook will display &quot;Skipping [host]&quot; if it determines a task # should not be run on a host. Set this to &quot;False&quot; if you don't want to see these &quot;Skipping&quot; # messages. NOTE: the task header will still be shown regardless of whether or not the # task is skipped. #display_skipped_hosts = True # by default (as of 1.3), Ansible will raise errors when attempting to dereference # Jinja2 variables that are not set in templates or action lines. Uncomment this line # to revert the behavior to pre-1.3. #error_on_undefined_vars = False # by default (as of 1.6), Ansible may display warnings based on the configuration of the # system running ansible itself. This may include warnings about 3rd party packages or # other conditions that should be resolved if possible. # to disable these warnings, set the following value to False: #system_warnings = True # by default (as of 1.4), Ansible may display deprecation warnings for language # features that should no longer be used and will be removed in future versions. # to disable these warnings, set the following value to False: #deprecation_warnings = True # (as of 1.8), Ansible can optionally warn when usage of the shell and # command module appear to be simplified by using a default Ansible module # instead. These warnings can be silenced by adjusting the following # setting or adding warn=yes or warn=no to the end of the command line # parameter string. This will for example suggest using the git module # instead of shelling out to the git command. # command_warnings = False # set plugin path directories here, separate with colons action_plugins = /usr/share/ansible_plugins/action_plugins callback_plugins = /usr/share/ansible_plugins/callback_plugins connection_plugins = /usr/share/ansible_plugins/connection_plugins lookup_plugins = /usr/share/ansible_plugins/lookup_plugins vars_plugins = /usr/share/ansible_plugins/vars_plugins filter_plugins = /usr/share/ansible_plugins/filter_plugins # by default callbacks are not loaded for /bin/ansible, enable this if you # want, for example, a notification or logging callback to also apply to # /bin/ansible runs #bin_ansible_callbacks = False # don't like cows? that's unfortunate. # set to 1 if you don't want cowsay support or export ANSIBLE_NOCOWS=1 #nocows = 1 # don't like colors either? # set to 1 if you don't want colors, or export ANSIBLE_NOCOLOR=1 #nocolor = 1 # the CA certificate path used for validating SSL certs. This path # should exist on the controlling node, not the target nodes # common locations: # RHEL/CentOS: /etc/pki/tls/certs/ca-bundle.crt # Fedora : /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem # Ubuntu : /usr/share/ca-certificates/cacert.org/cacert.org.crt #ca_file_path = # the http user-agent string to use when fetching urls. Some web server # operators block the default urllib user agent as it is frequently used # by malicious attacks/scripts, so we set it to something unique to # avoid issues. #http_user_agent = ansible-agent # if set to a persistent type (not 'memory', for example 'redis') fact values # from previous runs in Ansible will be stored. This may be useful when # wanting to use, for example, IP information from one group of servers # without having to talk to them in the same playbook run to get their # current IP information. fact_caching = memory # retry files #retry_files_enabled = False #retry_files_save_path = ~/.ansible-retry [privilege_escalation] #become=True #become_method=sudo #become_user=root #become_ask_pass=False [paramiko_connection] # uncomment this line to cause the paramiko connection plugin to not record new host # keys encountered. Increases performance on new host additions. Setting works independently of the # host key checking setting above. #record_host_keys=False # by default, Ansible requests a pseudo-terminal for commands executed under sudo. Uncomment this # line to disable this behaviour. #pty=False [ssh_connection] # ssh arguments to use # Leaving off ControlPersist will result in poor performance, so use # paramiko on older platforms rather than removing it #ssh_args = -o ControlMaster=auto -o ControlPersist=60s # The path to use for the ControlPath sockets. This defaults to # &quot;%(directory)s/ansible-ssh-%%h-%%p-%%r&quot;, however on some systems with # very long hostnames or very long path names (caused by long user names or # deeply nested home directories) this can exceed the character limit on # file socket names (108 characters for most platforms). In that case, you # may wish to shorten the string below. # # Example: # control_path = %(directory)s/%%h-%%r #control_path = %(directory)s/ansible-ssh-%%h-%%p-%%r # Enabling pipelining reduces the number of SSH operations required to # execute a module on the remote server. This can result in a significant # performance improvement when enabled, however when using &quot;sudo:&quot; you must # first disable 'requiretty' in /etc/sudoers # # By default, this option is disabled to preserve compatibility with # sudoers configurations that have requiretty (the default on many distros). # #pipelining = False # if True, make ansible use scp if the connection type is ssh # (default is sftp) #scp_if_ssh = True [accelerate] accelerate_port = 5099 accelerate_timeout = 30 accelerate_connect_timeout = 5.0 # The daemon timeout is measured in minutes. This time is measured # from the last activity to the accelerate daemon. accelerate_daemon_timeout = 30 # If set to yes, accelerate_multi_key will allow multiple # private keys to be uploaded to it, though each user must # have access to the system via SSH to add a new key. The default # is &quot;no&quot;. #accelerate_multi_key = yes [selinux] # file systems that require special treatment when dealing with security context # the default behaviour that copies the existing context or uses the user default # needs to be changed to use the file system dependant context. #special_context_filesystems=nfs,vboxsf,fuse"><pre class="notranslate"><code class="notranslate">[root@172-20-12-5 ~]# cat /etc/ansible/ansible.cfg # config file for ansible -- http://ansible.com/ # ============================================== # nearly all parameters can be overridden in ansible-playbook # or with command line flags. ansible will read ANSIBLE_CONFIG, # ansible.cfg in the current working directory, .ansible.cfg in # the home directory or /etc/ansible/ansible.cfg, whichever it # finds first [defaults] # some basic default values... inventory = /etc/ansible/hosts #library = /usr/share/my_modules/ remote_tmp = $HOME/.ansible/tmp pattern = * forks = 5 poll_interval = 15 sudo_user = root #ask_sudo_pass = True #ask_pass = True transport = smart #remote_port = 22 module_lang = C # plays will gather facts by default, which contain information about # the remote system. # # smart - gather by default, but don't regather if already gathered # implicit - gather by default, turn off with gather_facts: False # explicit - do not gather by default, must say gather_facts: True gathering = implicit # additional paths to search for roles in, colon separated #roles_path = /etc/ansible/roles # uncomment this to disable SSH key host checking #host_key_checking = False # change this for alternative sudo implementations sudo_exe = sudo # what flags to pass to sudo #sudo_flags = -H # SSH timeout timeout = 10 # default user to use for playbooks if user is not specified # (/usr/bin/ansible will use current user as default) #remote_user = root # logging is off by default unless this path is defined # if so defined, consider logrotate #log_path = /var/log/ansible.log # default module name for /usr/bin/ansible #module_name = command # use this shell for commands executed under sudo # you may need to change this to bin/bash in rare instances # if sudo is constrained #executable = /bin/sh # if inventory variables overlap, does the higher precedence one win # or are hash values merged together? The default is 'replace' but # this can also be set to 'merge'. #hash_behaviour = replace # list any Jinja2 extensions to enable here: #jinja2_extensions = jinja2.ext.do,jinja2.ext.i18n # if set, always use this private key file for authentication, same as # if passing --private-key to ansible or ansible-playbook #private_key_file = /path/to/file # format of string {{ ansible_managed }} available within Jinja2 # templates indicates to users editing templates files will be replaced. # replacing {file}, {host} and {uid} and strftime codes with proper values. ansible_managed = Ansible managed: {file} modified on %Y-%m-%d %H:%M:%S by {uid} on {host} # by default, ansible-playbook will display "Skipping [host]" if it determines a task # should not be run on a host. Set this to "False" if you don't want to see these "Skipping" # messages. NOTE: the task header will still be shown regardless of whether or not the # task is skipped. #display_skipped_hosts = True # by default (as of 1.3), Ansible will raise errors when attempting to dereference # Jinja2 variables that are not set in templates or action lines. Uncomment this line # to revert the behavior to pre-1.3. #error_on_undefined_vars = False # by default (as of 1.6), Ansible may display warnings based on the configuration of the # system running ansible itself. This may include warnings about 3rd party packages or # other conditions that should be resolved if possible. # to disable these warnings, set the following value to False: #system_warnings = True # by default (as of 1.4), Ansible may display deprecation warnings for language # features that should no longer be used and will be removed in future versions. # to disable these warnings, set the following value to False: #deprecation_warnings = True # (as of 1.8), Ansible can optionally warn when usage of the shell and # command module appear to be simplified by using a default Ansible module # instead. These warnings can be silenced by adjusting the following # setting or adding warn=yes or warn=no to the end of the command line # parameter string. This will for example suggest using the git module # instead of shelling out to the git command. # command_warnings = False # set plugin path directories here, separate with colons action_plugins = /usr/share/ansible_plugins/action_plugins callback_plugins = /usr/share/ansible_plugins/callback_plugins connection_plugins = /usr/share/ansible_plugins/connection_plugins lookup_plugins = /usr/share/ansible_plugins/lookup_plugins vars_plugins = /usr/share/ansible_plugins/vars_plugins filter_plugins = /usr/share/ansible_plugins/filter_plugins # by default callbacks are not loaded for /bin/ansible, enable this if you # want, for example, a notification or logging callback to also apply to # /bin/ansible runs #bin_ansible_callbacks = False # don't like cows? that's unfortunate. # set to 1 if you don't want cowsay support or export ANSIBLE_NOCOWS=1 #nocows = 1 # don't like colors either? # set to 1 if you don't want colors, or export ANSIBLE_NOCOLOR=1 #nocolor = 1 # the CA certificate path used for validating SSL certs. This path # should exist on the controlling node, not the target nodes # common locations: # RHEL/CentOS: /etc/pki/tls/certs/ca-bundle.crt # Fedora : /etc/pki/ca-trust/extracted/pem/tls-ca-bundle.pem # Ubuntu : /usr/share/ca-certificates/cacert.org/cacert.org.crt #ca_file_path = # the http user-agent string to use when fetching urls. Some web server # operators block the default urllib user agent as it is frequently used # by malicious attacks/scripts, so we set it to something unique to # avoid issues. #http_user_agent = ansible-agent # if set to a persistent type (not 'memory', for example 'redis') fact values # from previous runs in Ansible will be stored. This may be useful when # wanting to use, for example, IP information from one group of servers # without having to talk to them in the same playbook run to get their # current IP information. fact_caching = memory # retry files #retry_files_enabled = False #retry_files_save_path = ~/.ansible-retry [privilege_escalation] #become=True #become_method=sudo #become_user=root #become_ask_pass=False [paramiko_connection] # uncomment this line to cause the paramiko connection plugin to not record new host # keys encountered. Increases performance on new host additions. Setting works independently of the # host key checking setting above. #record_host_keys=False # by default, Ansible requests a pseudo-terminal for commands executed under sudo. Uncomment this # line to disable this behaviour. #pty=False [ssh_connection] # ssh arguments to use # Leaving off ControlPersist will result in poor performance, so use # paramiko on older platforms rather than removing it #ssh_args = -o ControlMaster=auto -o ControlPersist=60s # The path to use for the ControlPath sockets. This defaults to # "%(directory)s/ansible-ssh-%%h-%%p-%%r", however on some systems with # very long hostnames or very long path names (caused by long user names or # deeply nested home directories) this can exceed the character limit on # file socket names (108 characters for most platforms). In that case, you # may wish to shorten the string below. # # Example: # control_path = %(directory)s/%%h-%%r #control_path = %(directory)s/ansible-ssh-%%h-%%p-%%r # Enabling pipelining reduces the number of SSH operations required to # execute a module on the remote server. This can result in a significant # performance improvement when enabled, however when using "sudo:" you must # first disable 'requiretty' in /etc/sudoers # # By default, this option is disabled to preserve compatibility with # sudoers configurations that have requiretty (the default on many distros). # #pipelining = False # if True, make ansible use scp if the connection type is ssh # (default is sftp) #scp_if_ssh = True [accelerate] accelerate_port = 5099 accelerate_timeout = 30 accelerate_connect_timeout = 5.0 # The daemon timeout is measured in minutes. This time is measured # from the last activity to the accelerate daemon. accelerate_daemon_timeout = 30 # If set to yes, accelerate_multi_key will allow multiple # private keys to be uploaded to it, though each user must # have access to the system via SSH to add a new key. The default # is "no". #accelerate_multi_key = yes [selinux] # file systems that require special treatment when dealing with security context # the default behaviour that copies the existing context or uses the user default # needs to be changed to use the file system dependant context. #special_context_filesystems=nfs,vboxsf,fuse </code></pre></div> <h5 dir="auto">OS / ENVIRONMENT</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[root@172-20-12-5 ~]# cat /etc/system-release CentOS Linux release 7.2.1511 (Core)"><pre class="notranslate"><code class="notranslate">[root@172-20-12-5 ~]# cat /etc/system-release CentOS Linux release 7.2.1511 (Core) </code></pre></div> <h5 dir="auto">SUMMARY</h5> <p dir="auto">I have a test script which will re-run a task on the host(localhost), but after a lot of times(sometimes only a few minutes) re-run the task, the task failed by report:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="TASK: [pre-install script] **************************************************** &lt;172.20.12.5&gt; ESTABLISH CONNECTION FOR USER: root &lt;172.20.12.5&gt; EXEC ssh -C -tt -vvv -o ControlMaster=auto -o ControlPersist=60s -o ControlPath=&quot;/root/.ansible/cp/ansible-ssh-%h-%p-%r&quot; -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 172.20.12.5 /bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible-tmp-1464595244.34-181895261530692 &amp;&amp; echo $HOME/.ansible/tmp/ansible-tmp-1464595244.34-181895261530692' &lt;172.20.12.5&gt; PUT /tmp/tmp_l2Pf4 TO tmp_l2Pf4 &lt;172.20.12.5&gt; EXEC ssh -C -tt -vvv -o ControlMaster=auto -o ControlPersist=60s -o ControlPath=&quot;/root/.ansible/cp/ansible-ssh-%h-%p-%r&quot; -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 172.20.12.5 /bin/sh -c 'chmod +rx tmp_l2Pf4' &lt;172.20.12.5&gt; EXEC ssh -C -tt -vvv -o ControlMaster=auto -o ControlPersist=60s -o ControlPath=&quot;/root/.ansible/cp/ansible-ssh-%h-%p-%r&quot; -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 172.20.12.5 /bin/sh -c 'LANG=C LC_CTYPE=C tmp_l2Pf4 ' failed: [172.20.12.5] =&gt; {&quot;changed&quot;: true, &quot;rc&quot;: 127} stderr: OpenSSH_6.6.1, OpenSSL 1.0.1e-fips 11 Feb 2013 debug1: Reading configuration data /etc/ssh/ssh_config debug1: /etc/ssh/ssh_config line 57: Applying options for * debug1: auto-mux: Trying existing master debug2: fd 3 setting O_NONBLOCK debug2: mux_client_hello_exchange: master version 4 debug3: mux_client_forwards: request forwardings: 0 local, 0 remote debug3: mux_client_request_session: entering debug3: mux_client_request_alive: entering debug3: mux_client_request_alive: done pid = 30030 debug3: mux_client_request_session: session request sent debug1: mux_client_request_session: master session id: 2 debug3: mux_client_read_packet: read header failed: Broken pipe debug2: Received exit status from master 127 Shared connection to 172.20.12.5 closed. stdout: /bin/sh: tmp_l2Pf4: command not found FATAL: all hosts have already failed -- aborting "><pre class="notranslate"><code class="notranslate">TASK: [pre-install script] **************************************************** &lt;172.20.12.5&gt; ESTABLISH CONNECTION FOR USER: root &lt;172.20.12.5&gt; EXEC ssh -C -tt -vvv -o ControlMaster=auto -o ControlPersist=60s -o ControlPath="/root/.ansible/cp/ansible-ssh-%h-%p-%r" -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 172.20.12.5 /bin/sh -c 'mkdir -p $HOME/.ansible/tmp/ansible-tmp-1464595244.34-181895261530692 &amp;&amp; echo $HOME/.ansible/tmp/ansible-tmp-1464595244.34-181895261530692' &lt;172.20.12.5&gt; PUT /tmp/tmp_l2Pf4 TO tmp_l2Pf4 &lt;172.20.12.5&gt; EXEC ssh -C -tt -vvv -o ControlMaster=auto -o ControlPersist=60s -o ControlPath="/root/.ansible/cp/ansible-ssh-%h-%p-%r" -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 172.20.12.5 /bin/sh -c 'chmod +rx tmp_l2Pf4' &lt;172.20.12.5&gt; EXEC ssh -C -tt -vvv -o ControlMaster=auto -o ControlPersist=60s -o ControlPath="/root/.ansible/cp/ansible-ssh-%h-%p-%r" -o KbdInteractiveAuthentication=no -o PreferredAuthentications=gssapi-with-mic,gssapi-keyex,hostbased,publickey -o PasswordAuthentication=no -o ConnectTimeout=10 172.20.12.5 /bin/sh -c 'LANG=C LC_CTYPE=C tmp_l2Pf4 ' failed: [172.20.12.5] =&gt; {"changed": true, "rc": 127} stderr: OpenSSH_6.6.1, OpenSSL 1.0.1e-fips 11 Feb 2013 debug1: Reading configuration data /etc/ssh/ssh_config debug1: /etc/ssh/ssh_config line 57: Applying options for * debug1: auto-mux: Trying existing master debug2: fd 3 setting O_NONBLOCK debug2: mux_client_hello_exchange: master version 4 debug3: mux_client_forwards: request forwardings: 0 local, 0 remote debug3: mux_client_request_session: entering debug3: mux_client_request_alive: entering debug3: mux_client_request_alive: done pid = 30030 debug3: mux_client_request_session: session request sent debug1: mux_client_request_session: master session id: 2 debug3: mux_client_read_packet: read header failed: Broken pipe debug2: Received exit status from master 127 Shared connection to 172.20.12.5 closed. stdout: /bin/sh: tmp_l2Pf4: command not found FATAL: all hosts have already failed -- aborting </code></pre></div> <h5 dir="auto">STEPS TO REPRODUCE</h5> <p dir="auto">Only need to replace your real host ip and run the test_script.py will re-produce the bug.<br> BTW, don't forget to add your host ip to /etc/ansible/hosts</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[root@172-20-12-5 ~]# cat test_script.py #!/usr/bin/env python # encoding: utf-8 import argparse import sys import os import subprocess import signal import simplejson import ConfigParser import string import tempfile import pwd, grp import traceback import uuid import yaml import jinja2 import datetime yaml = '''--- - hosts: 172.20.12.5 remote_user: root tasks: - name: pre-install script script: $pre_install_script ''' pre_install_script = ''' [ -d /etc/yum.repos.d/ ] &amp;&amp; echo -e &quot;#aliyun base\n[alibase]\nname=CentOS-\$releasever - Base - mirrors.aliyun.com\nfailovermethod=priority\nbaseurl=http://mirrors.aliyun.com/centos/\$releasever/os/\$basearch/\ngpgcheck=0\nenabled=0\n \n#released updates \n[aliupdates]\nname=CentOS-\$releasever - Updates - mirrors.aliyun.com\nfailovermethod=priority\nbaseurl=http://mirrors.aliyun.com/centos/\$releasever/updates/\$basearch/\nenabled=0\ngpgcheck=0\n \n[aliextras]\nname=CentOS-\$releasever - Extras - mirrors.aliyun.com\nfailovermethod=priority\nbaseurl=http://mirrors.aliyun.com/centos/\$releasever/extras/\$basearch/\nenabled=0\ngpgcheck=0\n \n[aliepel]\nname=Extra Packages for Enterprise Linux \$releasever - \$basearce - mirrors.aliyun.com\nbaseurl=http://mirrors.aliyun.com/epel/\$releasever/\$basearch\nfailovermethod=priority\nenabled=0\ngpgcheck=0\n&quot; &gt; /etc/yum.repos.d/zstack-aliyun-yum.repo ''' fd, pre_install_script_path = tempfile.mkstemp() os.fdopen(fd, 'w').write(pre_install_script) t = string.Template(yaml) yaml = t.substitute({ 'pre_install_script': pre_install_script_path }) cmd = ''' yaml_file=`mktemp` cat &lt;&lt;EOF &gt;&gt; $$yaml_file $yaml EOF ansible-playbook -vvvv $$yaml_file ''' t = string.Template(cmd) cmd = t.substitute({ 'yaml': yaml, }) class ShellCmd(object): def __init__(self, cmd, workdir=None, pipe=True): self.cmd = cmd if pipe: self.process = subprocess.Popen(cmd, shell=True, stdout=subprocess.PIPE, stdin=subprocess.PIPE, stderr=subprocess.PIPE, cwd=workdir) else: self.process = subprocess.Popen(cmd, shell=True, cwd=workdir) self.return_code = None self.stdout = None self.stderr = None def __call__(self, is_exception=True): print 'executing shell command[%s]:' % self.cmd (self.stdout, self.stderr) = self.process.communicate() if is_exception and self.process.returncode != 0: print self.stderr print self.stdout sys.exit(1) return self.stdout def shell_no_pipe(cmd, is_exception=True): print datetime.datetime.now().strftime(&quot;%Y-%m-%d_%H-%M-%S&quot;) return ShellCmd(cmd, pipe=False)(is_exception) while True: shell_no_pipe(cmd)"><pre class="notranslate"><code class="notranslate">[root@172-20-12-5 ~]# cat test_script.py #!/usr/bin/env python # encoding: utf-8 import argparse import sys import os import subprocess import signal import simplejson import ConfigParser import string import tempfile import pwd, grp import traceback import uuid import yaml import jinja2 import datetime yaml = '''--- - hosts: 172.20.12.5 remote_user: root tasks: - name: pre-install script script: $pre_install_script ''' pre_install_script = ''' [ -d /etc/yum.repos.d/ ] &amp;&amp; echo -e "#aliyun base\n[alibase]\nname=CentOS-\$releasever - Base - mirrors.aliyun.com\nfailovermethod=priority\nbaseurl=http://mirrors.aliyun.com/centos/\$releasever/os/\$basearch/\ngpgcheck=0\nenabled=0\n \n#released updates \n[aliupdates]\nname=CentOS-\$releasever - Updates - mirrors.aliyun.com\nfailovermethod=priority\nbaseurl=http://mirrors.aliyun.com/centos/\$releasever/updates/\$basearch/\nenabled=0\ngpgcheck=0\n \n[aliextras]\nname=CentOS-\$releasever - Extras - mirrors.aliyun.com\nfailovermethod=priority\nbaseurl=http://mirrors.aliyun.com/centos/\$releasever/extras/\$basearch/\nenabled=0\ngpgcheck=0\n \n[aliepel]\nname=Extra Packages for Enterprise Linux \$releasever - \$basearce - mirrors.aliyun.com\nbaseurl=http://mirrors.aliyun.com/epel/\$releasever/\$basearch\nfailovermethod=priority\nenabled=0\ngpgcheck=0\n" &gt; /etc/yum.repos.d/zstack-aliyun-yum.repo ''' fd, pre_install_script_path = tempfile.mkstemp() os.fdopen(fd, 'w').write(pre_install_script) t = string.Template(yaml) yaml = t.substitute({ 'pre_install_script': pre_install_script_path }) cmd = ''' yaml_file=`mktemp` cat &lt;&lt;EOF &gt;&gt; $$yaml_file $yaml EOF ansible-playbook -vvvv $$yaml_file ''' t = string.Template(cmd) cmd = t.substitute({ 'yaml': yaml, }) class ShellCmd(object): def __init__(self, cmd, workdir=None, pipe=True): self.cmd = cmd if pipe: self.process = subprocess.Popen(cmd, shell=True, stdout=subprocess.PIPE, stdin=subprocess.PIPE, stderr=subprocess.PIPE, cwd=workdir) else: self.process = subprocess.Popen(cmd, shell=True, cwd=workdir) self.return_code = None self.stdout = None self.stderr = None def __call__(self, is_exception=True): print 'executing shell command[%s]:' % self.cmd (self.stdout, self.stderr) = self.process.communicate() if is_exception and self.process.returncode != 0: print self.stderr print self.stdout sys.exit(1) return self.stdout def shell_no_pipe(cmd, is_exception=True): print datetime.datetime.now().strftime("%Y-%m-%d_%H-%M-%S") return ShellCmd(cmd, pipe=False)(is_exception) while True: shell_no_pipe(cmd) </code></pre></div> <h5 dir="auto">EXPECTED RESULTS</h5> <p dir="auto">Tasks can run normally all the time.</p> <h5 dir="auto">ACTUAL RESULTS</h5> <p dir="auto">After repeat the task, task will failed by lost the tmp dir.</p> <p dir="auto">Below is the output of test script</p> <p dir="auto"><a href="https://gist.github.com/winger007/97aca1543b19680b4a4ee960672c537e">https://gist.github.com/winger007/97aca1543b19680b4a4ee960672c537e</a></p>
<p dir="auto">After I upgrade ansible 2.0.0.1 from 1.9.4, when performing a playlook always encounter intermittent fault "failed to resolve remote temporary directory from".</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ ansible-playbook playlooks/playlook-filters.yml PLAY *************************************************************************** TASK [command] ***************************************************************** fatal: [YT_8_22]: FAILED! =&gt; {&quot;failed&quot;: true, &quot;msg&quot;: &quot;ERROR! failed to resolve remote temporary directory from ansible-tmp-1452759681.1-95441304852350: `( umask 22 &amp;&amp; mkdir -p \&quot;$( echo /tmp/.ansible/tmp/ansible-tmp-1452759681.1-95441304852350 )\&quot; &amp;&amp; echo \&quot;$( echo /tmp/.ansible/tmp/ansible-tmp-1452759681.1-95441304852350 )\&quot; )` returned empty string&quot;} ...ignoring TASK [debug] ******************************************************************* ok: [YT_8_22] =&gt; { &quot;msg&quot;: &quot;it failed&quot; } PLAY RECAP ********************************************************************* YT_8_22 : ok=2 changed=0 unreachable=0 failed=0"><pre class="notranslate"><code class="notranslate">$ ansible-playbook playlooks/playlook-filters.yml PLAY *************************************************************************** TASK [command] ***************************************************************** fatal: [YT_8_22]: FAILED! =&gt; {"failed": true, "msg": "ERROR! failed to resolve remote temporary directory from ansible-tmp-1452759681.1-95441304852350: `( umask 22 &amp;&amp; mkdir -p \"$( echo /tmp/.ansible/tmp/ansible-tmp-1452759681.1-95441304852350 )\" &amp;&amp; echo \"$( echo /tmp/.ansible/tmp/ansible-tmp-1452759681.1-95441304852350 )\" )` returned empty string"} ...ignoring TASK [debug] ******************************************************************* ok: [YT_8_22] =&gt; { "msg": "it failed" } PLAY RECAP ********************************************************************* YT_8_22 : ok=2 changed=0 unreachable=0 failed=0 </code></pre></div> <p dir="auto">This is happening for one of the tasks randomly, following are those tasks:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" --- - hosts: YT_8_22 tasks: - shell: /bin/true register: result ignore_errors: True - debug: msg=&quot;it failed&quot; when: result|failed"><pre class="notranslate"><code class="notranslate"> --- - hosts: YT_8_22 tasks: - shell: /bin/true register: result ignore_errors: True - debug: msg="it failed" when: result|failed </code></pre></div> <p dir="auto">I try on 1.9.4, have not seen the phenomenon. Can anybody tell me how to do that ?</p> <p dir="auto">I found another links to similar problems: <a href="https://groups.google.com/forum/#!searchin/ansible-project/Intermittent$20error%7Csort:relevance/ansible-project/FyK6au2O9KY/tWuf31P9AQAJ" rel="nofollow">https://groups.google.com/forum/#!searchin/ansible-project/Intermittent$20error%7Csort:relevance/ansible-project/FyK6au2O9KY/tWuf31P9AQAJ</a></p>
1
<p dir="auto">Using python 3.3 on Mac OS:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import requests requests.post(&quot;http://localhost:8080/nonexistent&quot;, headers = {'Content-Type': 'text/plain;charset=UTF-8'}, data=b'foo')"><pre class="notranslate"><code class="notranslate">import requests requests.post("http://localhost:8080/nonexistent", headers = {'Content-Type': 'text/plain;charset=UTF-8'}, data=b'foo') </code></pre></div> <p dir="auto">results in the following request (captured with tcpdump):</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="POST /nonexistent HTTP/1.1 Host: localhost:8080 Accept-Encoding: identity Accept-Encoding: gzip, deflate, compress Content-Type: application/x-www-form-urlencoded Content-Type: text/plain;charset=UTF-8 Accept: */* Content-Length: 3 User-Agent: python-requests/1.2.0 CPython/3.3.1 Darwin/12.3.0 foo"><pre class="notranslate"><code class="notranslate">POST /nonexistent HTTP/1.1 Host: localhost:8080 Accept-Encoding: identity Accept-Encoding: gzip, deflate, compress Content-Type: application/x-www-form-urlencoded Content-Type: text/plain;charset=UTF-8 Accept: */* Content-Length: 3 User-Agent: python-requests/1.2.0 CPython/3.3.1 Darwin/12.3.0 foo </code></pre></div> <p dir="auto">Note that the specified content-type header is present, but another "Content-Type: application/x-www-form-urlencoded" is added. As far as I can tell, the extra Content-Type header is added at the end of prepare_body in models.py due to <code class="notranslate">'content-type' in self.headers</code> not recognizing the existing content-type header in the <code class="notranslate">self.headers</code> dict (the key is, at that time, <code class="notranslate">b'Content-type</code>, and it seems it's this str &lt;-&gt; bytes comparison that fails).</p> <p dir="auto">It is possible to work around this by wrapping the bytes in a BytesIO object (and setting it's len property), but it still seems like a bug?</p>
<p dir="auto"><a href="https://tools.ietf.org/html/rfc6874" rel="nofollow">RFC6874 </a>updates <a href="https://tools.ietf.org/html/rfc3986" rel="nofollow">RFC3986 </a> URI Syntax to support IPv6 Zone Identifiers. Zone identifiers are required when working with link local IPv6 addresses on a machine with multiple network adapters.</p> <p dir="auto">RFC6874 updates the URI ABNF to include:</p> <blockquote> <p dir="auto">IP-literal = "[" ( IPv6address / IPv6addrz / IPvFuture ) "]"<br> ZoneID = 1*( unreserved / pct-encoded )<br> IPv6addrz = IPv6address "%25" ZoneID</p> </blockquote> <p dir="auto">Windows systems use integers for the zone identifiers (Linux systems often use interface names instead).</p> <p dir="auto">When performing a get request to a link local address with zone ID "37" formatted as per RFC6874 (e.g. http://[fe80::1234%2537]) the percent encoding seems to be interpreted incorrectly and attempts to access fe80::12347 which is an invalid IPv6 address.</p> <h2 dir="auto">Expected Result</h2> <p dir="auto">Get request to "fe80::1234%37" performed correctly</p> <h2 dir="auto">Actual Result</h2> <p dir="auto">urlllib3 LocationParseError and requests.exceptions.InvalidURL exceptions are generated.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&gt;&gt;&gt; r = requests.get(&quot;http://[fe80::1234%2537]&quot;) Traceback (most recent call last): File &quot;C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\adapters.py&quot;, line 412, in send conn = self.get_connection(request.url, proxies) File &quot;C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\adapters.py&quot;, line 315, in get_connection conn = self.poolmanager.connection_from_url(url) File &quot;C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\poolmanager.py&quot;, line 297, in connection_from_url u = parse_url(url) File &quot;C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\util\url.py&quot;, line 392, in parse_url return six.raise_from(LocationParseError(source_url), None) File &quot;&lt;string&gt;&quot;, line 3, in raise_from urllib3.exceptions.LocationParseError: Failed to parse: http://[fe80::12347]/ During handling of the above exception, another exception occurred: Traceback (most recent call last): File &quot;&lt;stdin&gt;&quot;, line 1, in &lt;module&gt; File &quot;C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\api.py&quot;, line 76, in get return request('get', url, params=params, **kwargs) File &quot;C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\api.py&quot;, line 61, in request return session.request(method=method, url=url, **kwargs) File &quot;C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\sessions.py&quot;, line 542, in request resp = self.send(prep, **send_kwargs) File &quot;C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\sessions.py&quot;, line 655, in send r = adapter.send(request, **kwargs) File &quot;C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\adapters.py&quot;, line 414, in send raise InvalidURL(e, request=request) requests.exceptions.InvalidURL: Failed to parse: http://[fe80::12347]/"><pre class="notranslate"><code class="notranslate">&gt;&gt;&gt; r = requests.get("http://[fe80::1234%2537]") Traceback (most recent call last): File "C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\adapters.py", line 412, in send conn = self.get_connection(request.url, proxies) File "C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\adapters.py", line 315, in get_connection conn = self.poolmanager.connection_from_url(url) File "C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\poolmanager.py", line 297, in connection_from_url u = parse_url(url) File "C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\urllib3\util\url.py", line 392, in parse_url return six.raise_from(LocationParseError(source_url), None) File "&lt;string&gt;", line 3, in raise_from urllib3.exceptions.LocationParseError: Failed to parse: http://[fe80::12347]/ During handling of the above exception, another exception occurred: Traceback (most recent call last): File "&lt;stdin&gt;", line 1, in &lt;module&gt; File "C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\api.py", line 76, in get return request('get', url, params=params, **kwargs) File "C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\api.py", line 61, in request return session.request(method=method, url=url, **kwargs) File "C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\sessions.py", line 542, in request resp = self.send(prep, **send_kwargs) File "C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\sessions.py", line 655, in send r = adapter.send(request, **kwargs) File "C:\Users\username_removed\AppData\Local\Programs\Python\Python39\lib\site-packages\requests\adapters.py", line 414, in send raise InvalidURL(e, request=request) requests.exceptions.InvalidURL: Failed to parse: http://[fe80::12347]/ </code></pre></div> <p dir="auto">It seems that part of the zone ID is concatenated onto the IPv6 address and the % removed altogther.</p> <h2 dir="auto">Reproduction Steps</h2> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import requests r = requests.get(&quot;http://[fe80::1234%2537]&quot;)"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">requests</span> <span class="pl-s1">r</span> <span class="pl-c1">=</span> <span class="pl-s1">requests</span>.<span class="pl-en">get</span>(<span class="pl-s">"http://[fe80::1234%2537]"</span>)</pre></div> <p dir="auto">Note that the zone identifiers vary between PCs/OSs and sometimes over reboots, it is unlikely that 37 will be a valid Zone ID on most systems. However the connection should fail with "[WinError 10049] The requested address is not valid in its context" rather than</p> <h2 dir="auto">Other Notes</h2> <p dir="auto">The correct URL can be accesses by escaping the Zone ID twice. e.g:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import requests r = requests.get(&quot;http://[fe80::1234%252537]&quot;)"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">requests</span> <span class="pl-s1">r</span> <span class="pl-c1">=</span> <span class="pl-s1">requests</span>.<span class="pl-en">get</span>(<span class="pl-s">"http://[fe80::1234%252537]"</span>)</pre></div> <p dir="auto">Will attempt to access the correct address fe80::1234%37 perhaps %encoding is being performed twice?</p> <p dir="auto">Exact behaviour depends on the specific zone ID used, for instance some zone IDs work with or without the percent encoded % character:</p> <ul dir="auto"> <li>r = requests.get("http://[fe80::1234%1]")</li> <li>r = requests.get("http://[fe80::1234%251]")</li> <li>r = requests.get("http://[fe80::1234%25251]")</li> </ul> <p dir="auto">All attempt a get request from fe80::1234%1</p> <h2 dir="auto">urllib3 behaviour</h2> <p dir="auto">urllib3 seems to perform in accordance with RFC6874:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&gt;&gt;&gt; import urllib3 &gt;&gt;&gt; urllib3.util.parse_url(&quot;http://[fe80::1234%2537]&quot;) Url(scheme='http', auth=None, host='[fe80::1234%37]', port=None, path=None, query=None, fragment=None)"><pre class="notranslate"><code class="notranslate">&gt;&gt;&gt; import urllib3 &gt;&gt;&gt; urllib3.util.parse_url("http://[fe80::1234%2537]") Url(scheme='http', auth=None, host='[fe80::1234%37]', port=None, path=None, query=None, fragment=None) </code></pre></div> <h2 dir="auto">System Information</h2> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ python -m requests.help"><pre class="notranslate"><code class="notranslate">$ python -m requests.help </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="{ &quot;chardet&quot;: { &quot;version&quot;: &quot;4.0.0&quot; }, &quot;cryptography&quot;: { &quot;version&quot;: &quot;&quot; }, &quot;idna&quot;: { &quot;version&quot;: &quot;2.10&quot; }, &quot;implementation&quot;: { &quot;name&quot;: &quot;CPython&quot;, &quot;version&quot;: &quot;3.9.2&quot; }, &quot;platform&quot;: { &quot;release&quot;: &quot;10&quot;, &quot;system&quot;: &quot;Windows&quot; }, &quot;pyOpenSSL&quot;: { &quot;openssl_version&quot;: &quot;&quot;, &quot;version&quot;: null }, &quot;requests&quot;: { &quot;version&quot;: &quot;2.25.1&quot; }, &quot;system_ssl&quot;: { &quot;version&quot;: &quot;1010109f&quot; }, &quot;urllib3&quot;: { &quot;version&quot;: &quot;1.26.3&quot; }, &quot;using_pyopenssl&quot;: false }"><pre class="notranslate"><code class="notranslate">{ "chardet": { "version": "4.0.0" }, "cryptography": { "version": "" }, "idna": { "version": "2.10" }, "implementation": { "name": "CPython", "version": "3.9.2" }, "platform": { "release": "10", "system": "Windows" }, "pyOpenSSL": { "openssl_version": "", "version": null }, "requests": { "version": "2.25.1" }, "system_ssl": { "version": "1010109f" }, "urllib3": { "version": "1.26.3" }, "using_pyopenssl": false } </code></pre></div>
0
<p dir="auto">How can i collapse/expand ExpansionTile programatically ?<br> i dont see any way to toggle ExpansionTile in its definition<br> can anyone suggest me how can i achieve that ?</p>
<h2 dir="auto">Steps to Reproduce</h2> <p dir="auto">TextFormField not visible when has focus<br> <a href="https://gist.github.com/bahrinb55/e0a96e8a29bb9dbbc96111625ec27b3e">https://gist.github.com/bahrinb55/e0a96e8a29bb9dbbc96111625ec27b3e</a></p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/45315990/48970809-15768800-f011-11e8-933e-22a6110d33f2.gif"><img src="https://user-images.githubusercontent.com/45315990/48970809-15768800-f011-11e8-933e-22a6110d33f2.gif" alt="untitled" data-animated-image="" style="max-width: 100%;"></a></p> <h2 dir="auto">Logs</h2> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" processDynamicReleaseResources: task ':app:processDynamicReleaseResources' processDynamicReleaseUnitTestJavaRes: task ':app:processDynamicReleaseUnitTestJavaRes' processOperations: org.gradle.api.internal.file.DefaultFileOperations@2b409f8d processProfileJavaRes: task ':app:processProfileJavaRes' processProfileManifest: task ':app:processProfileManifest' processProfileResources: task ':app:processProfileResources' processProfileUnitTestJavaRes: task ':app:processProfileUnitTestJavaRes' processReleaseJavaRes: task ':app:processReleaseJavaRes' processReleaseManifest: task ':app:processReleaseManifest' processReleaseResources: task ':app:processReleaseResources' processReleaseUnitTestJavaRes: task ':app:processReleaseUnitTestJavaRes' project: project ':app' projectConfigurator: org.gradle.api.internal.project.BuildOperationCrossProjectConfigurator@23b4966e projectDir: D:\mywork\Projet\AfroLinker\Flutter\afrolinker_app\android\app projectEvaluationBroadcaster: ProjectEvaluationListener broadcast projectEvaluator: org.gradle.configuration.project.LifecycleProjectEvaluator@35ac14 projectPath: :app projectRegistry: org.gradle.api.internal.project.DefaultProjectRegistry@9247bd9 properties: {...} providers: org.gradle.api.internal.provider.DefaultProviderFactory@22dc2053 reportBuildArtifactsDebug: task ':app:reportBuildArtifactsDebug' reportBuildArtifactsDynamicProfile: task ':app:reportBuildArtifactsDynamicProfile' reportBuildArtifactsDynamicRelease: task ':app:reportBuildArtifactsDynamicRelease' reportBuildArtifactsProfile: task ':app:reportBuildArtifactsProfile' reportBuildArtifactsRelease: task ':app:reportBuildArtifactsRelease' reportSourceSetTransformAndroidTest: task ':app:reportSourceSetTransformAndroidTest' reportSourceSetTransformAndroidTestDebug: task ':app:reportSourceSetTransformAndroidTestDebug' reportSourceSetTransformDebug: task ':app:reportSourceSetTransformDebug' reportSourceSetTransformDynamicProfile: task ':app:reportSourceSetTransformDynamicProfile' reportSourceSetTransformDynamicRelease: task ':app:reportSourceSetTransformDynamicRelease' reportSourceSetTransformMain: task ':app:reportSourceSetTransformMain' reportSourceSetTransformProfile: task ':app:reportSourceSetTransformProfile' reportSourceSetTransformRelease: task ':app:reportSourceSetTransformRelease' reportSourceSetTransformTest: task ':app:reportSourceSetTransformTest' reportSourceSetTransformTestDebug: task ':app:reportSourceSetTransformTestDebug' reportSourceSetTransformTestDynamicProfile: task ':app:reportSourceSetTransformTestDynamicProfile' reportSourceSetTransformTestDynamicRelease: task ':app:reportSourceSetTransformTestDynamicRelease' reportSourceSetTransformTestProfile: task ':app:reportSourceSetTransformTestProfile' reportSourceSetTransformTestRelease: task ':app:reportSourceSetTransformTestRelease' reporting: org.gradle.api.reporting.ReportingExtension_Decorated@2b4498e8 reportsDir: D:\mywork\Projet\AfroLinker\Flutter\afrolinker_app\build\app\reports repositories: repository container resolveConfigAttr: task ':app:resolveConfigAttr' resourceLoader: org.gradle.internal.resource.transfer.DefaultUriTextResourceLoader@2cc46c08 resources: org.gradle.api.internal.resources.DefaultResourceHandler@1bc3088 rootDir: D:\mywork\Projet\AfroLinker\Flutter\afrolinker_app\android rootProject: root project 'android' script: false scriptHandlerFactory: org.gradle.api.internal.initialization.DefaultScriptHandlerFactory@2b6c79d5 scriptPluginFactory: org.gradle.configuration.ScriptPluginFactorySelector@24602788 serviceRegistryFactory: org.gradle.internal.service.scopes.ProjectScopeServices$4@2bcbbb20 services: ProjectScopeServices signingReport: task ':app:signingReport' sourceCompatibility: 1.8 sourceSets: SourceSet container splitsDiscoveryTaskDebug: task ':app:splitsDiscoveryTaskDebug' splitsDiscoveryTaskDynamicProfile: task ':app:splitsDiscoveryTaskDynamicProfile' splitsDiscoveryTaskDynamicRelease: task ':app:splitsDiscoveryTaskDynamicRelease' splitsDiscoveryTaskProfile: task ':app:splitsDiscoveryTaskProfile' splitsDiscoveryTaskRelease: task ':app:splitsDiscoveryTaskRelease' standardOutputCapture: org.gradle.internal.logging.services.DefaultLoggingManager@344472f6 state: project state 'EXECUTED' status: integration subprojects: [] targetCompatibility: 1.8 tasks: task set test: task ':app:test' testDebugUnitTest: task ':app:testDebugUnitTest' testDynamicProfileUnitTest: task ':app:testDynamicProfileUnitTest' testDynamicReleaseUnitTest: task ':app:testDynamicReleaseUnitTest' testProfileUnitTest: task ':app:testProfileUnitTest' testReleaseUnitTest: task ':app:testReleaseUnitTest' testReportDir: D:\mywork\Projet\AfroLinker\Flutter\afrolinker_app\build\app\reports\tests testReportDirName: tests testResultsDir: D:\mywork\Projet\AfroLinker\Flutter\afrolinker_app\build\app\test-results testResultsDirName: test-results transformClassesWithDexBuilderForDebug: task ':app:transformClassesWithDexBuilderForDebug' transformClassesWithDexBuilderForDebugAndroidTest: task ':app:transformClassesWithDexBuilderForDebugAndroidTest' transformClassesWithDexBuilderForDynamicProfile: task ':app:transformClassesWithDexBuilderForDynamicProfile' transformClassesWithDexBuilderForDynamicRelease: task ':app:transformClassesWithDexBuilderForDynamicRelease' transformClassesWithDexBuilderForProfile: task ':app:transformClassesWithDexBuilderForProfile' transformClassesWithDexBuilderForRelease: task ':app:transformClassesWithDexBuilderForRelease' transformDexArchiveWithDexMergerForDebug: task ':app:transformDexArchiveWithDexMergerForDebug' transformDexArchiveWithDexMergerForDebugAndroidTest: task ':app:transformDexArchiveWithDexMergerForDebugAndroidTest' transformDexArchiveWithDexMergerForDynamicProfile: task ':app:transformDexArchiveWithDexMergerForDynamicProfile' transformDexArchiveWithDexMergerForDynamicRelease: task ':app:transformDexArchiveWithDexMergerForDynamicRelease' transformDexArchiveWithDexMergerForProfile: task ':app:transformDexArchiveWithDexMergerForProfile' transformDexArchiveWithDexMergerForRelease: task ':app:transformDexArchiveWithDexMergerForRelease' transformDexArchiveWithExternalLibsDexMergerForDebug: task ':app:transformDexArchiveWithExternalLibsDexMergerForDebug' transformDexArchiveWithExternalLibsDexMergerForDebugAndroidTest: task ':app:transformDexArchiveWithExternalLibsDexMergerForDebugAndroidTest' transformDexArchiveWithExternalLibsDexMergerForDynamicProfile: task ':app:transformDexArchiveWithExternalLibsDexMergerForDynamicProfile' transformDexArchiveWithExternalLibsDexMergerForDynamicRelease: task ':app:transformDexArchiveWithExternalLibsDexMergerForDynamicRelease' transformDexArchiveWithExternalLibsDexMergerForProfile: task ':app:transformDexArchiveWithExternalLibsDexMergerForProfile' transformDexArchiveWithExternalLibsDexMergerForRelease: task ':app:transformDexArchiveWithExternalLibsDexMergerForRelease' transformNativeLibsWithMergeJniLibsForDebug: task ':app:transformNativeLibsWithMergeJniLibsForDebug' transformNativeLibsWithMergeJniLibsForDebugAndroidTest: task ':app:transformNativeLibsWithMergeJniLibsForDebugAndroidTest' transformNativeLibsWithMergeJniLibsForDynamicProfile: task ':app:transformNativeLibsWithMergeJniLibsForDynamicProfile' transformNativeLibsWithMergeJniLibsForDynamicRelease: task ':app:transformNativeLibsWithMergeJniLibsForDynamicRelease' transformNativeLibsWithMergeJniLibsForProfile: task ':app:transformNativeLibsWithMergeJniLibsForProfile' transformNativeLibsWithMergeJniLibsForRelease: task ':app:transformNativeLibsWithMergeJniLibsForRelease' transformResourcesWithMergeJavaResForDebug: task ':app:transformResourcesWithMergeJavaResForDebug' transformResourcesWithMergeJavaResForDebugAndroidTest: task ':app:transformResourcesWithMergeJavaResForDebugAndroidTest' transformResourcesWithMergeJavaResForDebugUnitTest: task ':app:transformResourcesWithMergeJavaResForDebugUnitTest' transformResourcesWithMergeJavaResForDynamicProfile: task ':app:transformResourcesWithMergeJavaResForDynamicProfile' transformResourcesWithMergeJavaResForDynamicProfileUnitTest: task ':app:transformResourcesWithMergeJavaResForDynamicProfileUnitTest' transformResourcesWithMergeJavaResForDynamicRelease: task ':app:transformResourcesWithMergeJavaResForDynamicRelease' transformResourcesWithMergeJavaResForDynamicReleaseUnitTest: task ':app:transformResourcesWithMergeJavaResForDynamicReleaseUnitTest' transformResourcesWithMergeJavaResForProfile: task ':app:transformResourcesWithMergeJavaResForProfile' transformResourcesWithMergeJavaResForProfileUnitTest: task ':app:transformResourcesWithMergeJavaResForProfileUnitTest' transformResourcesWithMergeJavaResForRelease: task ':app:transformResourcesWithMergeJavaResForRelease' transformResourcesWithMergeJavaResForReleaseUnitTest: task ':app:transformResourcesWithMergeJavaResForReleaseUnitTest' uninstallAll: task ':app:uninstallAll' uninstallDebug: task ':app:uninstallDebug' uninstallDebugAndroidTest: task ':app:uninstallDebugAndroidTest' uninstallDynamicProfile: task ':app:uninstallDynamicProfile' uninstallDynamicRelease: task ':app:uninstallDynamicRelease' uninstallProfile: task ':app:uninstallProfile' uninstallRelease: task ':app:uninstallRelease' validateSigningDebug: task ':app:validateSigningDebug' validateSigningDebugAndroidTest: task ':app:validateSigningDebugAndroidTest' validateSigningDynamicProfile: task ':app:validateSigningDynamicProfile' validateSigningDynamicRelease: task ':app:validateSigningDynamicRelease' validateSigningProfile: task ':app:validateSigningProfile' validateSigningRelease: task ':app:validateSigningRelease' version: unspecified writeDebugApplicationId: task ':app:writeDebugApplicationId' writeDynamicProfileApplicationId: task ':app:writeDynamicProfileApplicationId' writeDynamicReleaseApplicationId: task ':app:writeDynamicReleaseApplicationId' writeProfileApplicationId: task ':app:writeProfileApplicationId' writeReleaseApplicationId: task ':app:writeReleaseApplicationId' 1 actionable task: 1 executed [ +20 ms] executing: [D:\mywork\Projet\\Flutter\\android\] D:\mywork\Projet\\Flutter\\android\gradlew.bat app:tasks --all [+1892 ms] &gt; Task :app:tasks ------------------------------------------------------------ All tasks runnable from project :app ------------------------------------------------------------ Android tasks ------------- androidDependencies - Displays the Android dependencies of the project. signingReport - Displays the signing info for each variant. sourceSets - Prints out all the source sets defined in this project. Build tasks ----------- assemble - Assembles all variants of all applications and secondary packages. assembleAndroidTest - Assembles all the Test applications. assembleDebug - Assembles all Debug builds. assembleDynamicProfile - Assembles all DynamicProfile builds. assembleDynamicRelease - Assembles all DynamicRelease builds. assembleProfile - Assembles all Profile builds. assembleRelease - Assembles all Release builds. build - Assembles and tests this project. buildDependents - Assembles and tests this project and all projects that depend on it. buildNeeded - Assembles and tests this project and all projects it depends on. bundleDebug - Creates all Debug bundles. bundleDynamicProfile - Creates all DynamicProfile bundles. bundleDynamicRelease - Creates all DynamicRelease bundles. bundleProfile - Creates all Profile bundles. bundleRelease - Creates all Release bundles. clean - Deletes the build directory. cleanBuildCache - Deletes the build cache directory. compileDebugAndroidTestSources compileDebugSources compileDebugUnitTestSources compileDynamicProfileSources compileDynamicProfileUnitTestSources compileDynamicReleaseSources compileDynamicReleaseUnitTestSources compileProfileSources compileProfileUnitTestSources compileReleaseSources compileReleaseUnitTestSources Cleanup tasks ------------- lintFix - Runs lint on all variants and applies any safe suggestions to the source code. Help tasks ---------- buildEnvironment - Displays all buildscript dependencies declared in project ':app'. components - Displays the components produced by project ':app'. [incubating] dependencies - Displays all dependencies declared in project ':app'. dependencyInsight - Displays the insight into a specific dependency in project ':app'. dependentComponents - Displays the dependent components of components in project ':app'. [incubating] help - Displays a help message. model - Displays the configuration model of project ':app'. [incubating] projects - Displays the sub-projects of project ':app'. properties - Displays the properties of project ':app'. tasks - Displays the tasks runnable from project ':app'. Install tasks ------------- installDebug - Installs the Debug build. installDebugAndroidTest - Installs the android (on device) tests for the Debug build. installDynamicProfile - Installs the DynamicProfile build. installDynamicRelease - Installs the DynamicRelease build. installProfile - Installs the Profile build. installRelease - Installs the Release build. uninstallAll - Uninstall all applications. uninstallDebug - Uninstalls the Debug build. uninstallDebugAndroidTest - Uninstalls the android (on device) tests for the Debug build. uninstallDynamicProfile - Uninstalls the DynamicProfile build. uninstallDynamicRelease - Uninstalls the DynamicRelease build. uninstallProfile - Uninstalls the Profile build. uninstallRelease - Uninstalls the Release build. Verification tasks ------------------ check - Runs all checks. connectedAndroidTest - Installs and runs instrumentation tests for all flavors on connected devices. connectedCheck - Runs all device checks on currently connected devices. connectedDebugAndroidTest - Installs and runs the tests for debug on connected devices. deviceAndroidTest - Installs and runs instrumentation tests using all Device Providers. deviceCheck - Runs all device checks using Device Providers and Test Servers. lint - Runs lint on all variants. lintDebug - Runs lint on the Debug build. lintDynamicProfile - Runs lint on the DynamicProfile build. lintDynamicRelease - Runs lint on the DynamicRelease build. lintProfile - Runs lint on the Profile build. lintRelease - Runs lint on the Release build. lintVitalRelease - Runs lint on just the fatal issues in the release build. test - Run unit tests for all variants. testDebugUnitTest - Run unit tests for the debug build. testDynamicProfileUnitTest - Run unit tests for the dynamicProfile build. testDynamicReleaseUnitTest - Run unit tests for the dynamicRelease build. testProfileUnitTest - Run unit tests for the profile build. testReleaseUnitTest - Run unit tests for the release build. Other tasks ----------- assembleDebugAndroidTest assembleDebugUnitTest assembleDynamicProfileUnitTest assembleDynamicReleaseUnitTest assembleProfileUnitTest assembleReleaseUnitTest buildDebugPreBundle buildDynamicProfilePreBundle buildDynamicReleasePreBundle buildProfilePreBundle buildReleasePreBundle bundle bundleDebugAndroidTestResources bundleDebugResources bundleDynamicProfileResources bundleDynamicReleaseResources bundleProfileResources bundleReleaseResources checkDebugAndroidTestClasspath checkDebugClasspath checkDebugLibraries checkDebugManifest checkDynamicProfileClasspath checkDynamicProfileLibraries checkDynamicProfileManifest checkDynamicReleaseClasspath checkDynamicReleaseLibraries checkDynamicReleaseManifest checkProfileClasspath checkProfileLibraries checkProfileManifest checkReleaseClasspath checkReleaseLibraries checkReleaseManifest compileDebugAidl compileDebugAndroidTestAidl compileDebugAndroidTestJavaWithJavac compileDebugAndroidTestNdk compileDebugAndroidTestRenderscript compileDebugAndroidTestShaders compileDebugJavaWithJavac compileDebugNdk compileDebugRenderscript compileDebugShaders compileDebugUnitTestJavaWithJavac compileDynamicProfileAidl compileDynamicProfileJavaWithJavac compileDynamicProfileNdk compileDynamicProfileRenderscript compileDynamicProfileShaders compileDynamicProfileUnitTestJavaWithJavac compileDynamicReleaseAidl compileDynamicReleaseJavaWithJavac compileDynamicReleaseNdk compileDynamicReleaseRenderscript compileDynamicReleaseShaders compileDynamicReleaseUnitTestJavaWithJavac compileLint compileProfileAidl compileProfileJavaWithJavac compileProfileNdk compileProfileRenderscript compileProfileShaders compileProfileUnitTestJavaWithJavac compileReleaseAidl compileReleaseJavaWithJavac compileReleaseNdk compileReleaseRenderscript compileReleaseShaders compileReleaseUnitTestJavaWithJavac consumeConfigAttr copyFlutterAssetsDebug copyFlutterAssetsDynamicProfile copyFlutterAssetsDynamicRelease copyFlutterAssetsProfile copyFlutterAssetsRelease createDebugCompatibleScreenManifests createDynamicProfileCompatibleScreenManifests createDynamicReleaseCompatibleScreenManifests createMockableJar createProfileCompatibleScreenManifests createReleaseCompatibleScreenManifests extractApksForDebug extractApksForDynamicProfile extractApksForDynamicRelease extractApksForProfile extractApksForRelease extractProguardFiles flutterBuildDebug flutterBuildDynamicProfile flutterBuildDynamicRelease flutterBuildProfile flutterBuildRelease flutterBuildX86Jar generateDebugAndroidTestAssets generateDebugAndroidTestBuildConfig generateDebugAndroidTestResources generateDebugAndroidTestResValues generateDebugAndroidTestSources generateDebugAssets generateDebugBuildConfig generateDebugFeatureMetadata generateDebugFeatureTransitiveDeps generateDebugResources generateDebugResValues generateDebugSources generateDebugUnitTestAssets generateDebugUnitTestResources generateDebugUnitTestSources generateDynamicProfileAssets generateDynamicProfileBuildConfig generateDynamicProfileFeatureMetadata generateDynamicProfileFeatureTransitiveDeps generateDynamicProfileResources generateDynamicProfileResValues generateDynamicProfileSources generateDynamicProfileUnitTestAssets generateDynamicProfileUnitTestResources generateDynamicProfileUnitTestSources generateDynamicReleaseAssets generateDynamicReleaseBuildConfig generateDynamicReleaseFeatureMetadata generateDynamicReleaseFeatureTransitiveDeps generateDynamicReleaseResources generateDynamicReleaseResValues generateDynamicReleaseSources generateDynamicReleaseUnitTestAssets generateDynamicReleaseUnitTestResources generateDynamicReleaseUnitTestSources generateProfileAssets generateProfileBuildConfig generateProfileFeatureMetadata generateProfileFeatureTransitiveDeps generateProfileResources generateProfileResValues generateProfileSources generateProfileUnitTestAssets generateProfileUnitTestResources generateProfileUnitTestSources generateReleaseAssets generateReleaseBuildConfig generateReleaseFeatureMetadata generateReleaseFeatureTransitiveDeps generateReleaseResources generateReleaseResValues generateReleaseSources generateReleaseUnitTestAssets generateReleaseUnitTestResources generateReleaseUnitTestSources javaPreCompileDebug javaPreCompileDebugAndroidTest javaPreCompileDebugUnitTest javaPreCompileDynamicProfile javaPreCompileDynamicProfileUnitTest javaPreCompileDynamicRelease javaPreCompileDynamicReleaseUnitTest javaPreCompileProfile javaPreCompileProfileUnitTest javaPreCompileRelease javaPreCompileReleaseUnitTest mainApkListPersistenceDebug mainApkListPersistenceDebugAndroidTest mainApkListPersistenceDynamicProfile mainApkListPersistenceDynamicRelease mainApkListPersistenceProfile mainApkListPersistenceRelease makeApkFromBundleForDebug makeApkFromBundleForDynamicProfile makeApkFromBundleForDynamicRelease makeApkFromBundleForProfile makeApkFromBundleForRelease mergeDebugAndroidTestAssets mergeDebugAndroidTestJniLibFolders mergeDebugAndroidTestResources mergeDebugAndroidTestShaders mergeDebugAssets mergeDebugJniLibFolders mergeDebugResources mergeDebugShaders mergeDynamicProfileAssets mergeDynamicProfileJniLibFolders mergeDynamicProfileResources mergeDynamicProfileShaders mergeDynamicReleaseAssets mergeDynamicReleaseJniLibFolders mergeDynamicReleaseResources mergeDynamicReleaseShaders mergeProfileAssets mergeProfileJniLibFolders mergeProfileResources mergeProfileShaders mergeReleaseAssets mergeReleaseJniLibFolders mergeReleaseResources mergeReleaseShaders packageAppClassesDebug packageAppClassesDebugAndroidTest packageAppClassesDebugUnitTest packageAppClassesDynamicProfile packageAppClassesDynamicProfileUnitTest packageAppClassesDynamicRelease packageAppClassesDynamicReleaseUnitTest packageAppClassesProfile packageAppClassesProfileUnitTest packageAppClassesRelease packageAppClassesReleaseUnitTest packageDebug packageDebugAndroidTest packageDebugBundle packageDebugUniversalApk packageDynamicProfile packageDynamicProfileBundle packageDynamicProfileUniversalApk packageDynamicRelease packageDynamicReleaseBundle packageDynamicReleaseUniversalApk packageProfile packageProfileBundle packageProfileUniversalApk packageRelease packageReleaseBundle packageReleaseUniversalApk preBuild preDebugAndroidTestBuild preDebugBuild preDebugUnitTestBuild preDynamicProfileBuild preDynamicProfileUnitTestBuild preDynamicReleaseBuild preDynamicReleaseUnitTestBuild prepareLintJar preProfileBuild preProfileUnitTestBuild preReleaseBuild preReleaseUnitTestBuild processDebugAndroidTestJavaRes processDebugAndroidTestManifest processDebugAndroidTestResources processDebugJavaRes processDebugManifest processDebugResources processDebugUnitTestJavaRes processDynamicProfileJavaRes processDynamicProfileManifest processDynamicProfileResources processDynamicProfileUnitTestJavaRes processDynamicReleaseJavaRes processDynamicReleaseManifest processDynamicReleaseResources processDynamicReleaseUnitTestJavaRes processProfileJavaRes processProfileManifest processProfileResources processProfileUnitTestJavaRes processReleaseJavaRes processReleaseManifest processReleaseResources processReleaseUnitTestJavaRes reportBuildArtifactsDebug reportBuildArtifactsDynamicProfile reportBuildArtifactsDynamicRelease reportBuildArtifactsProfile reportBuildArtifactsRelease reportSourceSetTransformAndroidTest reportSourceSetTransformAndroidTestDebug reportSourceSetTransformDebug reportSourceSetTransformDynamicProfile reportSourceSetTransformDynamicRelease reportSourceSetTransformMain reportSourceSetTransformProfile reportSourceSetTransformRelease reportSourceSetTransformTest reportSourceSetTransformTestDebug reportSourceSetTransformTestDynamicProfile reportSourceSetTransformTestDynamicRelease reportSourceSetTransformTestProfile reportSourceSetTransformTestRelease resolveConfigAttr splitsDiscoveryTaskDebug splitsDiscoveryTaskDynamicProfile splitsDiscoveryTaskDynamicRelease splitsDiscoveryTaskProfile splitsDiscoveryTaskRelease transformClassesWithDexBuilderForDebug transformClassesWithDexBuilderForDebugAndroidTest transformClassesWithDexBuilderForDynamicProfile transformClassesWithDexBuilderForDynamicRelease transformClassesWithDexBuilderForProfile transformClassesWithDexBuilderForRelease transformDexArchiveWithDexMergerForDebug transformDexArchiveWithDexMergerForDebugAndroidTest transformDexArchiveWithDexMergerForDynamicProfile transformDexArchiveWithDexMergerForDynamicRelease transformDexArchiveWithDexMergerForProfile transformDexArchiveWithDexMergerForRelease transformDexArchiveWithExternalLibsDexMergerForDebug transformDexArchiveWithExternalLibsDexMergerForDebugAndroidTest transformDexArchiveWithExternalLibsDexMergerForDynamicProfile transformDexArchiveWithExternalLibsDexMergerForDynamicRelease transformDexArchiveWithExternalLibsDexMergerForProfile transformDexArchiveWithExternalLibsDexMergerForRelease transformNativeLibsWithMergeJniLibsForDebug transformNativeLibsWithMergeJniLibsForDebugAndroidTest transformNativeLibsWithMergeJniLibsForDynamicProfile transformNativeLibsWithMergeJniLibsForDynamicRelease transformNativeLibsWithMergeJniLibsForProfile transformNativeLibsWithMergeJniLibsForRelease transformResourcesWithMergeJavaResForDebug transformResourcesWithMergeJavaResForDebugAndroidTest transformResourcesWithMergeJavaResForDebugUnitTest transformResourcesWithMergeJavaResForDynamicProfile transformResourcesWithMergeJavaResForDynamicProfileUnitTest transformResourcesWithMergeJavaResForDynamicRelease transformResourcesWithMergeJavaResForDynamicReleaseUnitTest transformResourcesWithMergeJavaResForProfile transformResourcesWithMergeJavaResForProfileUnitTest transformResourcesWithMergeJavaResForRelease transformResourcesWithMergeJavaResForReleaseUnitTest validateSigningDebug validateSigningDebugAndroidTest validateSigningDynamicProfile validateSigningDynamicRelease validateSigningProfile validateSigningRelease writeDebugApplicationId writeDynamicProfileApplicationId writeDynamicReleaseApplicationId writeProfileApplicationId writeReleaseApplicationId Rules ----- Pattern: clean&lt;TaskName&gt;: Cleans the output files of a task. Pattern: build&lt;ConfigurationName&gt;: Assembles the artifacts of a configuration. Pattern: upload&lt;ConfigurationName&gt;: Assembles and uploads the artifacts belonging to a configuration. 1 actionable task: 1 executed [ +17 ms] Resolving dependencies... (completed) [ +3 ms] executing: D:\mywork\androidsdk\sdk2\build-tools\28.0.3\aapt dump xmltree D:\mywork\Projet\\Flutter\\build\app\outputs\apk\app.apk AndroidManifest.xml [ +36 ms] Exit code 0 from: D:\mywork\androidsdk\sdk2\build-tools\28.0.3\aapt dump xmltree D:\mywork\Projet\\Flutter\\build\app\outputs\apk\app.apk AndroidManifest.xml [ ] N: android=http://schemas.android.com/apk/res/android E: manifest (line=2) A: android:versionCode(0x0101021b)=(type 0x10)0x1 A: android:versionName(0x0101021c)=&quot;1.0.0&quot; (Raw: &quot;1.0.0&quot;) A: package=&quot;com.example.&quot; (Raw: &quot;com.example.&quot;) A: platformBuildVersionCode=(type 0x10)0x1 A: platformBuildVersionName=&quot;1.0.0&quot; (Raw: &quot;1.0.0&quot;) E: uses-sdk (line=7) A: android:minSdkVersion(0x0101020c)=(type 0x10)0x10 A: android:targetSdkVersion(0x01010270)=(type 0x10)0x1b E: uses-permission (line=16) A: android:name(0x01010003)=&quot;android.permission.INTERNET&quot; (Raw: &quot;android.permission.INTERNET&quot;) E: uses-permission (line=17) A: android:name(0x01010003)=&quot;android.permission.ACCESS_NETWORK_STATE&quot; (Raw: &quot;android.permission.ACCESS_NETWORK_STATE&quot;) E: uses-permission (line=18) A: android:name(0x01010003)=&quot;android.permission.WAKE_LOCK&quot; (Raw: &quot;android.permission.WAKE_LOCK&quot;) E: uses-permission (line=19) A: android:name(0x01010003)=&quot;com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE&quot; (Raw: &quot;com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE&quot;) E: uses-permission (line=20) A: android:name(0x01010003)=&quot;com.google.android.c2dm.permission.RECEIVE&quot; (Raw: &quot;com.google.android.c2dm.permission.RECEIVE&quot;) E: application (line=28) A: android:label(0x01010001)=&quot;&quot; (Raw: &quot;&quot;) A: android:icon(0x01010002)=@0x7f090000 A: android:name(0x01010003)=&quot;io.flutter.app.FlutterApplication&quot; (Raw: &quot;io.flutter.app.FlutterApplication&quot;) A: android:debuggable(0x0101000f)=(type 0x12)0xffffffff E: activity (line=33) A: android:theme(0x01010000)=@0x7f0b0000 A: android:name(0x01010003)=&quot;com.example..MainActivity&quot; (Raw: &quot;com.example..MainActivity&quot;) A: android:launchMode(0x0101001d)=(type 0x10)0x1 A: android:configChanges(0x0101001f)=(type 0x11)0x400035b4 A: android:windowSoftInputMode(0x0101022b)=(type 0x11)0x10 A: android:hardwareAccelerated(0x010102d3)=(type 0x12)0xffffffff E: meta-data (line=47) A: android:name(0x01010003)=&quot;io.flutter.app.android.SplashScreenUntilFirstFrame&quot; (Raw: &quot;io.flutter.app.android.SplashScreenUntilFirstFrame&quot;) A: android:value(0x01010024)=(type 0x12)0xffffffff E: intent-filter (line=51) E: action (line=52) A: android:name(0x01010003)=&quot;android.intent.action.MAIN&quot; (Raw: &quot;android.intent.action.MAIN&quot;) E: category (line=54) A: android:name(0x01010003)=&quot;android.intent.category.LAUNCHER&quot; (Raw: &quot;android.intent.category.LAUNCHER&quot;) E: service (line=58) A: android:name(0x01010003)=&quot;com.google.firebase.components.ComponentDiscoveryService&quot; (Raw: &quot;com.google.firebase.components.ComponentDiscoveryService&quot;) A: android:exported(0x01010010)=(type 0x12)0x0 E: meta-data (line=61) A: android:name(0x01010003)=&quot;com.google.firebase.components:com.google.firebase.firestore.FirestoreRegistrar&quot; (Raw: &quot;com.google.firebase.components:com.google.firebase.firestore.FirestoreRegistrar&quot;) A: android:value(0x01010024)=&quot;com.google.firebase.components.ComponentRegistrar&quot; (Raw: &quot;com.google.firebase.components.ComponentRegistrar&quot;) E: meta-data (line=64) A: android:name(0x01010003)=&quot;com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar&quot; (Raw: &quot;com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar&quot;) A: android:value(0x01010024)=&quot;com.google.firebase.components.ComponentRegistrar&quot; (Raw: &quot;com.google.firebase.components.ComponentRegistrar&quot;) E: meta-data (line=67) A: android:name(0x01010003)=&quot;com.google.firebase.components:com.google.firebase.iid.Registrar&quot; (Raw: &quot;com.google.firebase.components:com.google.firebase.iid.Registrar&quot;) A: android:value(0x01010024)=&quot;com.google.firebase.components.ComponentRegistrar&quot; (Raw: &quot;com.google.firebase.components.ComponentRegistrar&quot;) E: receiver (line=72) A: android:name(0x01010003)=&quot;com.google.android.gms.measurement.AppMeasurementReceiver&quot; (Raw: &quot;com.google.android.gms.measurement.AppMeasurementReceiver&quot;) A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: receiver (line=77) A: android:name(0x01010003)=&quot;com.google.android.gms.measurement.AppMeasurementInstallReferrerReceiver&quot; (Raw: &quot;com.google.android.gms.measurement.AppMeasurementInstallReferrerReceiver&quot;) A: android:permission(0x01010006)=&quot;android.permission.INSTALL_PACKAGES&quot; (Raw: &quot;android.permission.INSTALL_PACKAGES&quot;) A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=82) E: action (line=83) A: android:name(0x01010003)=&quot;com.android.vending.INSTALL_REFERRER&quot; (Raw: &quot;com.android.vending.INSTALL_REFERRER&quot;) E: service (line=87) A: android:name(0x01010003)=&quot;com.google.android.gms.measurement.AppMeasurementService&quot; (Raw: &quot;com.google.android.gms.measurement.AppMeasurementService&quot;) A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: service (line=91) A: android:name(0x01010003)=&quot;com.google.android.gms.measurement.AppMeasurementJobService&quot; (Raw: &quot;com.google.android.gms.measurement.AppMeasurementJobService&quot;) A: android:permission(0x01010006)=&quot;android.permission.BIND_JOB_SERVICE&quot; (Raw: &quot;android.permission.BIND_JOB_SERVICE&quot;) A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: receiver (line=97) A: android:name(0x01010003)=&quot;com.google.firebase.iid.FirebaseInstanceIdReceiver&quot; (Raw: &quot;com.google.firebase.iid.FirebaseInstanceIdReceiver&quot;) A: android:permission(0x01010006)=&quot;com.google.android.c2dm.permission.SEND&quot; (Raw: &quot;com.google.android.c2dm.permission.SEND&quot;) A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=101) E: action (line=102) A: android:name(0x01010003)=&quot;com.google.android.c2dm.intent.RECEIVE&quot; (Raw: &quot;com.google.android.c2dm.intent.RECEIVE&quot;) E: service (line=109) A: android:name(0x01010003)=&quot;com.google.firebase.iid.FirebaseInstanceIdService&quot; (Raw: &quot;com.google.firebase.iid.FirebaseInstanceIdService&quot;) A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=112) A: android:priority(0x0101001c)=(type 0x10)0xfffffe0c E: action (line=113) A: android:name(0x01010003)=&quot;com.google.firebase.INSTANCE_ID_EVENT&quot; (Raw: &quot;com.google.firebase.INSTANCE_ID_EVENT&quot;) E: activity (line=117) A: android:theme(0x01010000)=@0x1030010 A: android:name(0x01010003)=&quot;com.google.android.gms.common.api.GoogleApiActivity&quot; (Raw: &quot;com.google.android.gms.common.api.GoogleApiActivity&quot;) A: android:exported(0x01010010)=(type 0x12)0x0 E: provider (line=122) A: android:name(0x01010003)=&quot;com.google.firebase.provider.FirebaseInitProvider&quot; (Raw: &quot;com.google.firebase.provider.FirebaseInitProvider&quot;) A: android:exported(0x01010010)=(type 0x12)0x0 A: android:authorities(0x01010018)=&quot;com.example..firebaseinitprovider&quot; (Raw: &quot;com.example..firebaseinitprovider&quot;) A: android:initOrder(0x0101001a)=(type 0x10)0x64 E: meta-data (line=128) A: android:name(0x01010003)=&quot;com.google.android.gms.version&quot; (Raw: &quot;com.google.android.gms.version&quot;) A: android:value(0x01010024)=@0x7f070001 E: meta-data (line=131) A: android:name(0x01010003)=&quot;android.support.VERSION&quot; (Raw: &quot;android.support.VERSION&quot;) A: android:value(0x01010024)=&quot;26.1.0&quot; (Raw: &quot;26.1.0&quot;) [ +9 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell -x logcat -v time -t 1 [ +71 ms] Exit code 0 from: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell -x logcat -v time -t 1 [ ] --------- beginning of main 11-24 16:51:41.988 W/OpenGLRenderer( 2182): Incorrectly called buildLayer on View: ShortcutAndWidgetContainer, destroying layer... [ +4 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell -x logcat -v time [ +596 ms] DependencyChecker: nothing is modified after 2018-11-24 17:50:47.000. [ +3 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb version [ +55 ms] Android Debug Bridge version 1.0.40 Version 4986621 Installed as D:\mywork\androidsdk\sdk2\platform-tools\adb.EXE [ +3 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb start-server [ +61 ms] Building APK [ +13 ms] Gradle task 'assembleDebug'... [ +2 ms] executing: [D:\mywork\Projet\\Flutter\\android\] D:\mywork\Projet\\Flutter\\android\gradlew.bat -Pverbose=true -Ptarget=D:\mywork\Projet\\Flutter\\lib/main.dart -Ptrack-widget-creation=false -Pfilesystem-scheme=org-dartlang-root assembleDebug [+2053 ms] &gt; Task :app:flutterBuildX86Jar UP-TO-DATE [ +121 ms] &gt; Task :app:checkDebugClasspath UP-TO-DATE [ +8 ms] &gt; Task :app:preBuild UP-TO-DATE [ ] &gt; Task :cloud_firestore:preBuild UP-TO-DATE [ ] &gt; Task :cloud_firestore:preDebugBuild UP-TO-DATE [ ] &gt; Task :cloud_firestore:checkDebugManifest UP-TO-DATE [ +4 ms] &gt; Task :cloud_firestore:processDebugManifest UP-TO-DATE [ ] &gt; Task :firebase_core:preBuild UP-TO-DATE [ ] &gt; Task :firebase_core:preDebugBuild UP-TO-DATE [ ] &gt; Task :firebase_core:checkDebugManifest UP-TO-DATE [ ] &gt; Task :firebase_core:processDebugManifest UP-TO-DATE [ ] &gt; Task :path_provider:preBuild UP-TO-DATE [ ] &gt; Task :path_provider:preDebugBuild UP-TO-DATE [ ] &gt; Task :path_provider:checkDebugManifest UP-TO-DATE [ ] &gt; Task :path_provider:processDebugManifest UP-TO-DATE [ ] &gt; Task :shared_preferences:preBuild UP-TO-DATE [ ] &gt; Task :shared_preferences:preDebugBuild UP-TO-DATE [ ] &gt; Task :shared_preferences:checkDebugManifest UP-TO-DATE [ ] &gt; Task :shared_preferences:processDebugManifest UP-TO-DATE [ ] &gt; Task :app:preDebugBuild UP-TO-DATE [ ] &gt; Task :cloud_firestore:compileDebugAidl NO-SOURCE [ ] &gt; Task :firebase_core:compileDebugAidl NO-SOURCE [ ] &gt; Task :path_provider:compileDebugAidl NO-SOURCE [ ] &gt; Task :shared_preferences:compileDebugAidl NO-SOURCE [ ] &gt; Task :app:compileDebugAidl NO-SOURCE [ ] &gt; Task :cloud_firestore:packageDebugRenderscript NO-SOURCE [ ] &gt; Task :firebase_core:packageDebugRenderscript NO-SOURCE [ ] &gt; Task :path_provider:packageDebugRenderscript NO-SOURCE [ ] &gt; Task :shared_preferences:packageDebugRenderscript NO-SOURCE [ ] &gt; Task :app:compileDebugRenderscript UP-TO-DATE [ ] &gt; Task :app:checkDebugManifest UP-TO-DATE [ ] &gt; Task :app:generateDebugBuildConfig UP-TO-DATE [ +3 ms] &gt; Task :app:prepareLintJar UP-TO-DATE [ +1 ms] &gt; Task :app:cleanMergeDebugAssets [ +144 ms] &gt; Task :app:flutterBuildDebug UP-TO-DATE [ +1 ms] &gt; Task :app:mergeDebugShaders UP-TO-DATE [ ] &gt; Task :app:compileDebugShaders UP-TO-DATE [ ] &gt; Task :app:generateDebugAssets UP-TO-DATE [ ] &gt; Task :cloud_firestore:mergeDebugShaders UP-TO-DATE [ ] &gt; Task :cloud_firestore:compileDebugShaders UP-TO-DATE [ ] &gt; Task :cloud_firestore:generateDebugAssets UP-TO-DATE [ ] &gt; Task :cloud_firestore:packageDebugAssets UP-TO-DATE [ ] &gt; Task :firebase_core:mergeDebugShaders UP-TO-DATE [ ] &gt; Task :firebase_core:compileDebugShaders UP-TO-DATE [ ] &gt; Task :firebase_core:generateDebugAssets UP-TO-DATE [ ] &gt; Task :firebase_core:packageDebugAssets UP-TO-DATE [ ] &gt; Task :path_provider:mergeDebugShaders UP-TO-DATE [ ] &gt; Task :path_provider:compileDebugShaders UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugAssets UP-TO-DATE [ ] &gt; Task :path_provider:packageDebugAssets UP-TO-DATE [ ] &gt; Task :shared_preferences:mergeDebugShaders UP-TO-DATE [ ] &gt; Task :shared_preferences:compileDebugShaders UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugAssets UP-TO-DATE [ ] &gt; Task :shared_preferences:packageDebugAssets UP-TO-DATE [ ] &gt; Task :app:mergeDebugAssets [ +203 ms] &gt; Task :app:copyFlutterAssetsDebug [ +46 ms] &gt; Task :app:mainApkListPersistenceDebug UP-TO-DATE [ +17 ms] &gt; Task :app:generateDebugResValues UP-TO-DATE [ +4 ms] &gt; Task :app:generateDebugResources UP-TO-DATE [ +6 ms] &gt; Task :cloud_firestore:compileDebugRenderscript UP-TO-DATE [ +28 ms] &gt; Task :cloud_firestore:generateDebugResValues UP-TO-DATE [ +11 ms] &gt; Task :cloud_firestore:generateDebugResources UP-TO-DATE [ +6 ms] &gt; Task :cloud_firestore:packageDebugResources UP-TO-DATE [ ] &gt; Task :firebase_core:compileDebugRenderscript UP-TO-DATE [ ] &gt; Task :firebase_core:generateDebugResValues UP-TO-DATE [ ] &gt; Task :firebase_core:generateDebugResources UP-TO-DATE [ ] &gt; Task :firebase_core:packageDebugResources UP-TO-DATE [ ] &gt; Task :path_provider:compileDebugRenderscript UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugResValues UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugResources UP-TO-DATE [ ] &gt; Task :path_provider:packageDebugResources UP-TO-DATE [ ] &gt; Task :shared_preferences:compileDebugRenderscript UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugResValues UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugResources UP-TO-DATE [ ] &gt; Task :shared_preferences:packageDebugResources UP-TO-DATE [ +62 ms] &gt; Task :app:mergeDebugResources UP-TO-DATE [ ] &gt; Task :app:createDebugCompatibleScreenManifests UP-TO-DATE [ ] &gt; Task :app:processDebugManifest UP-TO-DATE [ ] &gt; Task :app:splitsDiscoveryTaskDebug UP-TO-DATE [ ] &gt; Task :cloud_firestore:generateDebugRFile UP-TO-DATE [ +98 ms] &gt; Task :firebase_core:generateDebugRFile UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugRFile UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugRFile UP-TO-DATE [ ] &gt; Task :app:processDebugResources UP-TO-DATE [ ] &gt; Task :app:generateDebugSources UP-TO-DATE [ ] &gt; Task :cloud_firestore:generateDebugBuildConfig UP-TO-DATE [ ] &gt; Task :cloud_firestore:prepareLintJar UP-TO-DATE [ ] &gt; Task :cloud_firestore:generateDebugSources UP-TO-DATE [ ] &gt; Task :cloud_firestore:javaPreCompileDebug UP-TO-DATE [ ] &gt; Task :cloud_firestore:compileDebugJavaWithJavac UP-TO-DATE [ ] &gt; Task :cloud_firestore:processDebugJavaRes NO-SOURCE [ ] &gt; Task :cloud_firestore:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:generateDebugBuildConfig UP-TO-DATE [ ] &gt; Task :firebase_core:prepareLintJar UP-TO-DATE [ ] &gt; Task :firebase_core:generateDebugSources UP-TO-DATE [ ] &gt; Task :firebase_core:javaPreCompileDebug UP-TO-DATE [ +2 ms] &gt; Task :firebase_core:compileDebugJavaWithJavac UP-TO-DATE [ ] &gt; Task :firebase_core:processDebugJavaRes NO-SOURCE [ ] &gt; Task :firebase_core:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugBuildConfig UP-TO-DATE [ ] &gt; Task :path_provider:prepareLintJar UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugSources UP-TO-DATE [ ] &gt; Task :path_provider:javaPreCompileDebug UP-TO-DATE [ +86 ms] &gt; Task :path_provider:compileDebugJavaWithJavac UP-TO-DATE [ ] &gt; Task :path_provider:processDebugJavaRes NO-SOURCE [ ] &gt; Task :path_provider:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugBuildConfig UP-TO-DATE [ ] &gt; Task :shared_preferences:prepareLintJar UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugSources UP-TO-DATE [ ] &gt; Task :shared_preferences:javaPreCompileDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:compileDebugJavaWithJavac UP-TO-DATE [ ] &gt; Task :shared_preferences:processDebugJavaRes NO-SOURCE [ +2 ms] &gt; Task :shared_preferences:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug UP-TO-DATE [ ] &gt; Task :app:javaPreCompileDebug UP-TO-DATE [ ] &gt; Task :app:compileDebugJavaWithJavac UP-TO-DATE [ ] &gt; Task :app:compileDebugNdk NO-SOURCE [ ] &gt; Task :app:compileDebugSources UP-TO-DATE [ +93 ms] &gt; Task :app:transformClassesWithDexBuilderForDebug UP-TO-DATE [ ] &gt; Task :app:transformDexArchiveWithExternalLibsDexMergerForDebug UP-TO-DATE [ +2 ms] &gt; Task :app:transformDexArchiveWithDexMergerForDebug UP-TO-DATE [ ] &gt; Task :app:mergeDebugJniLibFolders UP-TO-DATE [ ] &gt; Task :cloud_firestore:compileDebugNdk NO-SOURCE [ ] &gt; Task :cloud_firestore:mergeDebugJniLibFolders UP-TO-DATE [ ] &gt; Task :cloud_firestore:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE [ ] &gt; Task :cloud_firestore:transformNativeLibsWithIntermediateJniLibsForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:compileDebugNdk NO-SOURCE [ ] &gt; Task :firebase_core:mergeDebugJniLibFolders UP-TO-DATE [ ] &gt; Task :firebase_core:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:transformNativeLibsWithIntermediateJniLibsForDebug UP-TO-DATE [ ] &gt; Task :path_provider:compileDebugNdk NO-SOURCE [ ] &gt; Task :path_provider:mergeDebugJniLibFolders UP-TO-DATE [ ] &gt; Task :path_provider:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE [ ] &gt; Task :path_provider:transformNativeLibsWithIntermediateJniLibsForDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:compileDebugNdk NO-SOURCE [ +3 ms] &gt; Task :shared_preferences:mergeDebugJniLibFolders UP-TO-DATE [ ] &gt; Task :shared_preferences:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:transformNativeLibsWithIntermediateJniLibsForDebug UP-TO-DATE [ ] &gt; Task :app:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE [ ] &gt; Task :app:checkDebugLibraries UP-TO-DATE [ ] &gt; Task :app:processDebugJavaRes NO-SOURCE [ ] &gt; Task :app:transformResourcesWithMergeJavaResForDebug UP-TO-DATE [ ] &gt; Task :app:validateSigningDebug UP-TO-DATE [ ] &gt; Task :app:packageDebug UP-TO-DATE [ ] &gt; Task :app:assembleDebug UP-TO-DATE [ +85 ms] &gt; Task :cloud_firestore:extractDebugAnnotations UP-TO-DATE [ +3 ms] &gt; Task :cloud_firestore:mergeDebugConsumerProguardFiles UP-TO-DATE [ +12 ms] &gt; Task :cloud_firestore:transformResourcesWithMergeJavaResForDebug UP-TO-DATE [ +8 ms] &gt; Task :cloud_firestore:transformClassesAndResourcesWithSyncLibJarsForDebug UP-TO-DATE [ +16 ms] &gt; Task :cloud_firestore:transformNativeLibsWithSyncJniLibsForDebug UP-TO-DATE [ +6 ms] &gt; Task :cloud_firestore:bundleDebugAar UP-TO-DATE [ +4 ms] &gt; Task :cloud_firestore:compileDebugSources UP-TO-DATE [ +5 ms] &gt; Task :cloud_firestore:assembleDebug UP-TO-DATE [ ] &gt; Task :firebase_core:extractDebugAnnotations UP-TO-DATE [ ] &gt; Task :firebase_core:mergeDebugConsumerProguardFiles UP-TO-DATE [ ] &gt; Task :firebase_core:transformResourcesWithMergeJavaResForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:transformClassesAndResourcesWithSyncLibJarsForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:transformNativeLibsWithSyncJniLibsForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:bundleDebugAar UP-TO-DATE [ ] &gt; Task :firebase_core:compileDebugSources UP-TO-DATE [ ] &gt; Task :firebase_core:assembleDebug UP-TO-DATE [ +11 ms] &gt; Task :path_provider:extractDebugAnnotations UP-TO-DATE [ ] &gt; Task :path_provider:mergeDebugConsumerProguardFiles UP-TO-DATE [ ] &gt; Task :path_provider:transformResourcesWithMergeJavaResForDebug UP-TO-DATE [ +2 ms] &gt; Task :path_provider:transformClassesAndResourcesWithSyncLibJarsForDebug UP-TO-DATE [ +1 ms] &gt; Task :path_provider:transformNativeLibsWithSyncJniLibsForDebug UP-TO-DATE [ +2 ms] &gt; Task :path_provider:bundleDebugAar UP-TO-DATE [ +1 ms] &gt; Task :path_provider:compileDebugSources UP-TO-DATE [ ] &gt; Task :path_provider:assembleDebug UP-TO-DATE [ +1 ms] &gt; Task :shared_preferences:extractDebugAnnotations UP-TO-DATE [ ] &gt; Task :shared_preferences:mergeDebugConsumerProguardFiles UP-TO-DATE [ +1 ms] &gt; Task :shared_preferences:transformResourcesWithMergeJavaResForDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:transformClassesAndResourcesWithSyncLibJarsForDebug UP-TO-DATE [ +1 ms] &gt; Task :shared_preferences:transformNativeLibsWithSyncJniLibsForDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:bundleDebugAar UP-TO-DATE [ ] &gt; Task :shared_preferences:compileDebugSources UP-TO-DATE [ +10 ms] &gt; Task :shared_preferences:assembleDebug UP-TO-DATE [ +1 ms] 123 actionable tasks: 3 executed, 120 up-to-date [ +314 ms] Gradle task 'assembleDebug'... (completed) [ +27 ms] calculateSha: LocalDirectory: 'D:\mywork\Projet\\Flutter\\build\app\outputs\apk'/app.apk [ +554 ms] Built build\app\outputs\apk\debug\app-debug.apk. [ +1 ms] executing: D:\mywork\androidsdk\sdk2\build-tools\28.0.3\aapt dump xmltree D:\mywork\Projet\\Flutter\\build\app\outputs\apk\app.apk AndroidManifest.xml [ +27 ms] Exit code 0 from: D:\mywork\androidsdk\sdk2\build-tools\28.0.3\aapt dump xmltree D:\mywork\Projet\\Flutter\\build\app\outputs\apk\app.apk AndroidManifest.xml [ ] N: android=http://schemas.android.com/apk/res/android E: manifest (line=2) A: android:versionCode(0x0101021b)=(type 0x10)0x1 A: android:versionName(0x0101021c)=&quot;1.0.0&quot; (Raw: &quot;1.0.0&quot;) A: package=&quot;com.example.&quot; (Raw: &quot;com.example.&quot;) A: platformBuildVersionCode=(type 0x10)0x1 A: platformBuildVersionName=&quot;1.0.0&quot; (Raw: &quot;1.0.0&quot;) E: uses-sdk (line=7) A: android:minSdkVersion(0x0101020c)=(type 0x10)0x10 A: android:targetSdkVersion(0x01010270)=(type 0x10)0x1b E: uses-permission (line=16) A: android:name(0x01010003)=&quot;android.permission.INTERNET&quot; (Raw: &quot;android.permission.INTERNET&quot;) E: uses-permission (line=17) A: android:name(0x01010003)=&quot;android.permission.ACCESS_NETWORK_STATE&quot; (Raw: &quot;android.permission.ACCESS_NETWORK_STATE&quot;) E: uses-permission (line=18) A: android:name(0x01010003)=&quot;android.permission.WAKE_LOCK&quot; (Raw: &quot;android.permission.WAKE_LOCK&quot;) E: uses-permission (line=19) A: android:name(0x01010003)=&quot;com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE&quot; (Raw: &quot;com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE&quot;) E: uses-permission (line=20) A: android:name(0x01010003)=&quot;com.google.android.c2dm.permission.RECEIVE&quot; (Raw: &quot;com.google.android.c2dm.permission.RECEIVE&quot;) E: application (line=28) A: android:label(0x01010001)=&quot;&quot; (Raw: &quot;&quot;) A: android:icon(0x01010002)=@0x7f090000 A: android:name(0x01010003)=&quot;io.flutter.app.FlutterApplication&quot; (Raw: &quot;io.flutter.app.FlutterApplication&quot;) A: android:debuggable(0x0101000f)=(type 0x12)0xffffffff E: activity (line=33) A: android:theme(0x01010000)=@0x7f0b0000 A: android:name(0x01010003)=&quot;com.example..MainActivity&quot; (Raw: &quot;com.example..MainActivity&quot;) A: android:launchMode(0x0101001d)=(type 0x10)0x1 A: android:configChanges(0x0101001f)=(type 0x11)0x400035b4 A: android:windowSoftInputMode(0x0101022b)=(type 0x11)0x10 A: android:hardwareAccelerated(0x010102d3)=(type 0x12)0xffffffff E: meta-data (line=47) A: android:name(0x01010003)=&quot;io.flutter.app.android.SplashScreenUntilFirstFrame&quot; (Raw: &quot;io.flutter.app.android.SplashScreenUntilFirstFrame&quot;) A: android:value(0x01010024)=(type 0x12)0xffffffff E: intent-filter (line=51) E: action (line=52) A: android:name(0x01010003)=&quot;android.intent.action.MAIN&quot; (Raw: &quot;android.intent.action.MAIN&quot;) E: category (line=54) A: android:name(0x01010003)=&quot;android.intent.category.LAUNCHER&quot; (Raw: &quot;android.intent.category.LAUNCHER&quot;) E: service (line=58) A: android:name(0x01010003)=&quot;com.google.firebase.components.ComponentDiscoveryService&quot; (Raw: &quot;com.google.firebase.components.ComponentDiscoveryService&quot;) A: android:exported(0x01010010)=(type 0x12)0x0 E: meta-data (line=61) A: android:name(0x01010003)=&quot;com.google.firebase.components:com.google.firebase.firestore.FirestoreRegistrar&quot; (Raw: &quot;com.google.firebase.components:com.google.firebase.firestore.FirestoreRegistrar&quot;) A: android:value(0x01010024)=&quot;com.google.firebase.components.ComponentRegistrar&quot; (Raw: &quot;com.google.firebase.components.ComponentRegistrar&quot;) E: meta-data (line=64) A: android:name(0x01010003)=&quot;com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar&quot; (Raw: &quot;com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar&quot;) A: android:value(0x01010024)=&quot;com.google.firebase.components.ComponentRegistrar&quot; (Raw: &quot;com.google.firebase.components.ComponentRegistrar&quot;) E: meta-data (line=67) A: android:name(0x01010003)=&quot;com.google.firebase.components:com.google.firebase.iid.Registrar&quot; (Raw: &quot;com.google.firebase.components:com.google.firebase.iid.Registrar&quot;) A: android:value(0x01010024)=&quot;com.google.firebase.components.ComponentRegistrar&quot; (Raw: &quot;com.google.firebase.components.ComponentRegistrar&quot;) E: receiver (line=72) A: android:name(0x01010003)=&quot;com.google.android.gms.measurement.AppMeasurementReceiver&quot; (Raw: &quot;com.google.android.gms.measurement.AppMeasurementReceiver&quot;) A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: receiver (line=77) A: android:name(0x01010003)=&quot;com.google.android.gms.measurement.AppMeasurementInstallReferrerReceiver&quot; (Raw: &quot;com.google.android.gms.measurement.AppMeasurementInstallReferrerReceiver&quot;) A: android:permission(0x01010006)=&quot;android.permission.INSTALL_PACKAGES&quot; (Raw: &quot;android.permission.INSTALL_PACKAGES&quot;) A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=82) E: action (line=83) A: android:name(0x01010003)=&quot;com.android.vending.INSTALL_REFERRER&quot; (Raw: &quot;com.android.vending.INSTALL_REFERRER&quot;) E: service (line=87) A: android:name(0x01010003)=&quot;com.google.android.gms.measurement.AppMeasurementService&quot; (Raw: &quot;com.google.android.gms.measurement.AppMeasurementService&quot;) A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: service (line=91) A: android:name(0x01010003)=&quot;com.google.android.gms.measurement.AppMeasurementJobService&quot; (Raw: &quot;com.google.android.gms.measurement.AppMeasurementJobService&quot;) A: android:permission(0x01010006)=&quot;android.permission.BIND_JOB_SERVICE&quot; (Raw: &quot;android.permission.BIND_JOB_SERVICE&quot;) A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: receiver (line=97) A: android:name(0x01010003)=&quot;com.google.firebase.iid.FirebaseInstanceIdReceiver&quot; (Raw: &quot;com.google.firebase.iid.FirebaseInstanceIdReceiver&quot;) A: android:permission(0x01010006)=&quot;com.google.android.c2dm.permission.SEND&quot; (Raw: &quot;com.google.android.c2dm.permission.SEND&quot;) A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=101) E: action (line=102) A: android:name(0x01010003)=&quot;com.google.android.c2dm.intent.RECEIVE&quot; (Raw: &quot;com.google.android.c2dm.intent.RECEIVE&quot;) E: service (line=109) A: android:name(0x01010003)=&quot;com.google.firebase.iid.FirebaseInstanceIdService&quot; (Raw: &quot;com.google.firebase.iid.FirebaseInstanceIdService&quot;) A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=112) A: android:priority(0x0101001c)=(type 0x10)0xfffffe0c E: action (line=113) A: android:name(0x01010003)=&quot;com.google.firebase.INSTANCE_ID_EVENT&quot; (Raw: &quot;com.google.firebase.INSTANCE_ID_EVENT&quot;) E: activity (line=117) A: android:theme(0x01010000)=@0x1030010 A: android:name(0x01010003)=&quot;com.google.android.gms.common.api.GoogleApiActivity&quot; (Raw: &quot;com.google.android.gms.common.api.GoogleApiActivity&quot;) A: android:exported(0x01010010)=(type 0x12)0x0 E: provider (line=122) A: android:name(0x01010003)=&quot;com.google.firebase.provider.FirebaseInitProvider&quot; (Raw: &quot;com.google.firebase.provider.FirebaseInitProvider&quot;) A: android:exported(0x01010010)=(type 0x12)0x0 A: android:authorities(0x01010018)=&quot;com.example..firebaseinitprovider&quot; (Raw: &quot;com.example..firebaseinitprovider&quot;) A: android:initOrder(0x0101001a)=(type 0x10)0x64 E: meta-data (line=128) A: android:name(0x01010003)=&quot;com.google.android.gms.version&quot; (Raw: &quot;com.google.android.gms.version&quot;) A: android:value(0x01010024)=@0x7f070001 E: meta-data (line=131) A: android:name(0x01010003)=&quot;android.support.VERSION&quot; (Raw: &quot;android.support.VERSION&quot;) A: android:value(0x01010024)=&quot;26.1.0&quot; (Raw: &quot;26.1.0&quot;) [ +4 ms] Stopping app 'app.apk' on Android SDK built for x86 64. [ ] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell am force-stop com.example. [ +294 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell pm list packages com.example. [ +275 ms] package:com.example. [ +2 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell cat /data/local/tmp/sky.com.example..sha1 [ +45 ms] 4a9ca306051ab02038550896b38161cef7844d8c [ +1 ms] Latest build already installed. [ ] Android SDK built for x86 64 startApp [ +1 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell am start -a android.intent.action.RUN -f 0x20000000 --ez enable-background-compilation true --ez enable-dart-profiling true --ez enable-checked-mode true com.example./com.example..MainActivity [ +292 ms] Starting: Intent { act=android.intent.action.RUN flg=0x20000000 cmp=com.example./.MainActivity (has extras) } [ ] Waiting for observatory port to be available... [ +392 ms] Observatory URL on device: http://127.0.0.1:43411/ [ +1 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 forward tcp:0 tcp:43411 [ +45 ms] 62673 [ ] Forwarded host port 62673 to device port 43411 for Observatory [ +6 ms] Connecting to service protocol: http://127.0.0.1:62673/ [ +335 ms] Successfully connected to service protocol: http://127.0.0.1:62673/ [ +4 ms] Sending to VM service: getVM({}) [ +11 ms] Result: {type: VM, name: vm, architectureBits: 64, targetCPU: x64, hostCPU: Virtual CPU, version: 2.1.0-dev.9.4.flutter-f9ebf21297 (Thu Nov 8 23:00:07 2018 +0100) on &quot;android_x64&quot;, _profilerMode: VM, _nativeZoneMemoryUsage: 0, pid: 28202, startTime: 15430... [ +8 ms] Sending to VM service: getIsolate({isolateId: isolates/189969803}) [ +5 ms] Sending to VM service: _flutter.listViews({}) [ +15 ms] Result: {type: FlutterViewList, views: [{type: FlutterView, id: _flutterView/0x709f17383f98, isolate: {type: @Isolate, fixedId: true, id: isolates/189969803, name: main.dart$main-189969803, number: 189969803}}]} [ +8 ms] DevFS: Creating new filesystem on the device (null) [ +1 ms] Sending to VM service: _createDevFS({fsName: }) [ +41 ms] Result: {type: Isolate, fixedId: true, id: isolates/189969803, name: main.dart:main(), number: 189969803, _originNumber: 189969803, startTime: 1543078322516, _heaps: {new: {type: HeapSpace, name: new, vmName: Scavenger, collections: 2, avgCollectionPeriod... [ +36 ms] Result: {type: FileSystem, name: , uri: file:///data/user/0/com.example./cache///} [ ] DevFS: Created new filesystem on device (file:///data/user/0/com.example./cache///) [ +2 ms] Updating assets [ +174 ms] Syncing files to device Android SDK built for x86 64... [ +3 ms] DevFS: Starting sync from LocalDirectory: 'D:\mywork\Projet\\Flutter\' [ ] Scanning project files [ +11 ms] Scanning package files [ +110 ms] Scanning asset files [ +1 ms] Scanning for deleted files [ +73 ms] Compiling dart to kernel with 613 updated files [ +10 ms] C:\flutter\bin\cache\dart-sdk\bin\dart C:\flutter\bin\cache\artifacts\engine\windows-x64\frontend_server.dart.snapshot --sdk-root C:\flutter\bin\cache\artifacts\engine\common\flutter_patched_sdk/ --incremental --strong --target=flutter --output-dill build\app.dill --packages D:\mywork\Projet\\Flutter\\.packages --filesystem-scheme org-dartlang-root [ +84 ms] I/Choreographer(28202): Skipped 54 frames! The application may be doing too much work on its main thread. [ +7 ms] D/EGL_emulation(28202): eglMakeCurrent: 0x709f19ca20a0: ver 2 0 (tinfo 0x709f19c0c6c0) [ +745 ms] D/ (28202): HostConnection::get() New Host Connection established 0x709f154524a0, tid 28219 [ +18 ms] D/EGL_emulation(28202): eglMakeCurrent: 0x709f211318c0: ver 2 0 (tinfo 0x709f19c0c440) [+1055 ms] Updating files [ +285 ms] DevFS: Sync finished [ ] Syncing files to device Android SDK built for x86 64... (completed) [ ] Synced 2.1MB. [ +1 ms] Sending to VM service: _flutter.listViews({}) [ +16 ms] Result: {type: FlutterViewList, views: [{type: FlutterView, id: _flutterView/0x709f17383f98, isolate: {type: @Isolate, fixedId: true, id: isolates/189969803, name: main.dart$main-189969803, number: 189969803}}]} [ +1 ms] Connected to _flutterView/0x709f17383f98."><pre class="notranslate"><code class="notranslate"> processDynamicReleaseResources: task ':app:processDynamicReleaseResources' processDynamicReleaseUnitTestJavaRes: task ':app:processDynamicReleaseUnitTestJavaRes' processOperations: org.gradle.api.internal.file.DefaultFileOperations@2b409f8d processProfileJavaRes: task ':app:processProfileJavaRes' processProfileManifest: task ':app:processProfileManifest' processProfileResources: task ':app:processProfileResources' processProfileUnitTestJavaRes: task ':app:processProfileUnitTestJavaRes' processReleaseJavaRes: task ':app:processReleaseJavaRes' processReleaseManifest: task ':app:processReleaseManifest' processReleaseResources: task ':app:processReleaseResources' processReleaseUnitTestJavaRes: task ':app:processReleaseUnitTestJavaRes' project: project ':app' projectConfigurator: org.gradle.api.internal.project.BuildOperationCrossProjectConfigurator@23b4966e projectDir: D:\mywork\Projet\AfroLinker\Flutter\afrolinker_app\android\app projectEvaluationBroadcaster: ProjectEvaluationListener broadcast projectEvaluator: org.gradle.configuration.project.LifecycleProjectEvaluator@35ac14 projectPath: :app projectRegistry: org.gradle.api.internal.project.DefaultProjectRegistry@9247bd9 properties: {...} providers: org.gradle.api.internal.provider.DefaultProviderFactory@22dc2053 reportBuildArtifactsDebug: task ':app:reportBuildArtifactsDebug' reportBuildArtifactsDynamicProfile: task ':app:reportBuildArtifactsDynamicProfile' reportBuildArtifactsDynamicRelease: task ':app:reportBuildArtifactsDynamicRelease' reportBuildArtifactsProfile: task ':app:reportBuildArtifactsProfile' reportBuildArtifactsRelease: task ':app:reportBuildArtifactsRelease' reportSourceSetTransformAndroidTest: task ':app:reportSourceSetTransformAndroidTest' reportSourceSetTransformAndroidTestDebug: task ':app:reportSourceSetTransformAndroidTestDebug' reportSourceSetTransformDebug: task ':app:reportSourceSetTransformDebug' reportSourceSetTransformDynamicProfile: task ':app:reportSourceSetTransformDynamicProfile' reportSourceSetTransformDynamicRelease: task ':app:reportSourceSetTransformDynamicRelease' reportSourceSetTransformMain: task ':app:reportSourceSetTransformMain' reportSourceSetTransformProfile: task ':app:reportSourceSetTransformProfile' reportSourceSetTransformRelease: task ':app:reportSourceSetTransformRelease' reportSourceSetTransformTest: task ':app:reportSourceSetTransformTest' reportSourceSetTransformTestDebug: task ':app:reportSourceSetTransformTestDebug' reportSourceSetTransformTestDynamicProfile: task ':app:reportSourceSetTransformTestDynamicProfile' reportSourceSetTransformTestDynamicRelease: task ':app:reportSourceSetTransformTestDynamicRelease' reportSourceSetTransformTestProfile: task ':app:reportSourceSetTransformTestProfile' reportSourceSetTransformTestRelease: task ':app:reportSourceSetTransformTestRelease' reporting: org.gradle.api.reporting.ReportingExtension_Decorated@2b4498e8 reportsDir: D:\mywork\Projet\AfroLinker\Flutter\afrolinker_app\build\app\reports repositories: repository container resolveConfigAttr: task ':app:resolveConfigAttr' resourceLoader: org.gradle.internal.resource.transfer.DefaultUriTextResourceLoader@2cc46c08 resources: org.gradle.api.internal.resources.DefaultResourceHandler@1bc3088 rootDir: D:\mywork\Projet\AfroLinker\Flutter\afrolinker_app\android rootProject: root project 'android' script: false scriptHandlerFactory: org.gradle.api.internal.initialization.DefaultScriptHandlerFactory@2b6c79d5 scriptPluginFactory: org.gradle.configuration.ScriptPluginFactorySelector@24602788 serviceRegistryFactory: org.gradle.internal.service.scopes.ProjectScopeServices$4@2bcbbb20 services: ProjectScopeServices signingReport: task ':app:signingReport' sourceCompatibility: 1.8 sourceSets: SourceSet container splitsDiscoveryTaskDebug: task ':app:splitsDiscoveryTaskDebug' splitsDiscoveryTaskDynamicProfile: task ':app:splitsDiscoveryTaskDynamicProfile' splitsDiscoveryTaskDynamicRelease: task ':app:splitsDiscoveryTaskDynamicRelease' splitsDiscoveryTaskProfile: task ':app:splitsDiscoveryTaskProfile' splitsDiscoveryTaskRelease: task ':app:splitsDiscoveryTaskRelease' standardOutputCapture: org.gradle.internal.logging.services.DefaultLoggingManager@344472f6 state: project state 'EXECUTED' status: integration subprojects: [] targetCompatibility: 1.8 tasks: task set test: task ':app:test' testDebugUnitTest: task ':app:testDebugUnitTest' testDynamicProfileUnitTest: task ':app:testDynamicProfileUnitTest' testDynamicReleaseUnitTest: task ':app:testDynamicReleaseUnitTest' testProfileUnitTest: task ':app:testProfileUnitTest' testReleaseUnitTest: task ':app:testReleaseUnitTest' testReportDir: D:\mywork\Projet\AfroLinker\Flutter\afrolinker_app\build\app\reports\tests testReportDirName: tests testResultsDir: D:\mywork\Projet\AfroLinker\Flutter\afrolinker_app\build\app\test-results testResultsDirName: test-results transformClassesWithDexBuilderForDebug: task ':app:transformClassesWithDexBuilderForDebug' transformClassesWithDexBuilderForDebugAndroidTest: task ':app:transformClassesWithDexBuilderForDebugAndroidTest' transformClassesWithDexBuilderForDynamicProfile: task ':app:transformClassesWithDexBuilderForDynamicProfile' transformClassesWithDexBuilderForDynamicRelease: task ':app:transformClassesWithDexBuilderForDynamicRelease' transformClassesWithDexBuilderForProfile: task ':app:transformClassesWithDexBuilderForProfile' transformClassesWithDexBuilderForRelease: task ':app:transformClassesWithDexBuilderForRelease' transformDexArchiveWithDexMergerForDebug: task ':app:transformDexArchiveWithDexMergerForDebug' transformDexArchiveWithDexMergerForDebugAndroidTest: task ':app:transformDexArchiveWithDexMergerForDebugAndroidTest' transformDexArchiveWithDexMergerForDynamicProfile: task ':app:transformDexArchiveWithDexMergerForDynamicProfile' transformDexArchiveWithDexMergerForDynamicRelease: task ':app:transformDexArchiveWithDexMergerForDynamicRelease' transformDexArchiveWithDexMergerForProfile: task ':app:transformDexArchiveWithDexMergerForProfile' transformDexArchiveWithDexMergerForRelease: task ':app:transformDexArchiveWithDexMergerForRelease' transformDexArchiveWithExternalLibsDexMergerForDebug: task ':app:transformDexArchiveWithExternalLibsDexMergerForDebug' transformDexArchiveWithExternalLibsDexMergerForDebugAndroidTest: task ':app:transformDexArchiveWithExternalLibsDexMergerForDebugAndroidTest' transformDexArchiveWithExternalLibsDexMergerForDynamicProfile: task ':app:transformDexArchiveWithExternalLibsDexMergerForDynamicProfile' transformDexArchiveWithExternalLibsDexMergerForDynamicRelease: task ':app:transformDexArchiveWithExternalLibsDexMergerForDynamicRelease' transformDexArchiveWithExternalLibsDexMergerForProfile: task ':app:transformDexArchiveWithExternalLibsDexMergerForProfile' transformDexArchiveWithExternalLibsDexMergerForRelease: task ':app:transformDexArchiveWithExternalLibsDexMergerForRelease' transformNativeLibsWithMergeJniLibsForDebug: task ':app:transformNativeLibsWithMergeJniLibsForDebug' transformNativeLibsWithMergeJniLibsForDebugAndroidTest: task ':app:transformNativeLibsWithMergeJniLibsForDebugAndroidTest' transformNativeLibsWithMergeJniLibsForDynamicProfile: task ':app:transformNativeLibsWithMergeJniLibsForDynamicProfile' transformNativeLibsWithMergeJniLibsForDynamicRelease: task ':app:transformNativeLibsWithMergeJniLibsForDynamicRelease' transformNativeLibsWithMergeJniLibsForProfile: task ':app:transformNativeLibsWithMergeJniLibsForProfile' transformNativeLibsWithMergeJniLibsForRelease: task ':app:transformNativeLibsWithMergeJniLibsForRelease' transformResourcesWithMergeJavaResForDebug: task ':app:transformResourcesWithMergeJavaResForDebug' transformResourcesWithMergeJavaResForDebugAndroidTest: task ':app:transformResourcesWithMergeJavaResForDebugAndroidTest' transformResourcesWithMergeJavaResForDebugUnitTest: task ':app:transformResourcesWithMergeJavaResForDebugUnitTest' transformResourcesWithMergeJavaResForDynamicProfile: task ':app:transformResourcesWithMergeJavaResForDynamicProfile' transformResourcesWithMergeJavaResForDynamicProfileUnitTest: task ':app:transformResourcesWithMergeJavaResForDynamicProfileUnitTest' transformResourcesWithMergeJavaResForDynamicRelease: task ':app:transformResourcesWithMergeJavaResForDynamicRelease' transformResourcesWithMergeJavaResForDynamicReleaseUnitTest: task ':app:transformResourcesWithMergeJavaResForDynamicReleaseUnitTest' transformResourcesWithMergeJavaResForProfile: task ':app:transformResourcesWithMergeJavaResForProfile' transformResourcesWithMergeJavaResForProfileUnitTest: task ':app:transformResourcesWithMergeJavaResForProfileUnitTest' transformResourcesWithMergeJavaResForRelease: task ':app:transformResourcesWithMergeJavaResForRelease' transformResourcesWithMergeJavaResForReleaseUnitTest: task ':app:transformResourcesWithMergeJavaResForReleaseUnitTest' uninstallAll: task ':app:uninstallAll' uninstallDebug: task ':app:uninstallDebug' uninstallDebugAndroidTest: task ':app:uninstallDebugAndroidTest' uninstallDynamicProfile: task ':app:uninstallDynamicProfile' uninstallDynamicRelease: task ':app:uninstallDynamicRelease' uninstallProfile: task ':app:uninstallProfile' uninstallRelease: task ':app:uninstallRelease' validateSigningDebug: task ':app:validateSigningDebug' validateSigningDebugAndroidTest: task ':app:validateSigningDebugAndroidTest' validateSigningDynamicProfile: task ':app:validateSigningDynamicProfile' validateSigningDynamicRelease: task ':app:validateSigningDynamicRelease' validateSigningProfile: task ':app:validateSigningProfile' validateSigningRelease: task ':app:validateSigningRelease' version: unspecified writeDebugApplicationId: task ':app:writeDebugApplicationId' writeDynamicProfileApplicationId: task ':app:writeDynamicProfileApplicationId' writeDynamicReleaseApplicationId: task ':app:writeDynamicReleaseApplicationId' writeProfileApplicationId: task ':app:writeProfileApplicationId' writeReleaseApplicationId: task ':app:writeReleaseApplicationId' 1 actionable task: 1 executed [ +20 ms] executing: [D:\mywork\Projet\\Flutter\\android\] D:\mywork\Projet\\Flutter\\android\gradlew.bat app:tasks --all [+1892 ms] &gt; Task :app:tasks ------------------------------------------------------------ All tasks runnable from project :app ------------------------------------------------------------ Android tasks ------------- androidDependencies - Displays the Android dependencies of the project. signingReport - Displays the signing info for each variant. sourceSets - Prints out all the source sets defined in this project. Build tasks ----------- assemble - Assembles all variants of all applications and secondary packages. assembleAndroidTest - Assembles all the Test applications. assembleDebug - Assembles all Debug builds. assembleDynamicProfile - Assembles all DynamicProfile builds. assembleDynamicRelease - Assembles all DynamicRelease builds. assembleProfile - Assembles all Profile builds. assembleRelease - Assembles all Release builds. build - Assembles and tests this project. buildDependents - Assembles and tests this project and all projects that depend on it. buildNeeded - Assembles and tests this project and all projects it depends on. bundleDebug - Creates all Debug bundles. bundleDynamicProfile - Creates all DynamicProfile bundles. bundleDynamicRelease - Creates all DynamicRelease bundles. bundleProfile - Creates all Profile bundles. bundleRelease - Creates all Release bundles. clean - Deletes the build directory. cleanBuildCache - Deletes the build cache directory. compileDebugAndroidTestSources compileDebugSources compileDebugUnitTestSources compileDynamicProfileSources compileDynamicProfileUnitTestSources compileDynamicReleaseSources compileDynamicReleaseUnitTestSources compileProfileSources compileProfileUnitTestSources compileReleaseSources compileReleaseUnitTestSources Cleanup tasks ------------- lintFix - Runs lint on all variants and applies any safe suggestions to the source code. Help tasks ---------- buildEnvironment - Displays all buildscript dependencies declared in project ':app'. components - Displays the components produced by project ':app'. [incubating] dependencies - Displays all dependencies declared in project ':app'. dependencyInsight - Displays the insight into a specific dependency in project ':app'. dependentComponents - Displays the dependent components of components in project ':app'. [incubating] help - Displays a help message. model - Displays the configuration model of project ':app'. [incubating] projects - Displays the sub-projects of project ':app'. properties - Displays the properties of project ':app'. tasks - Displays the tasks runnable from project ':app'. Install tasks ------------- installDebug - Installs the Debug build. installDebugAndroidTest - Installs the android (on device) tests for the Debug build. installDynamicProfile - Installs the DynamicProfile build. installDynamicRelease - Installs the DynamicRelease build. installProfile - Installs the Profile build. installRelease - Installs the Release build. uninstallAll - Uninstall all applications. uninstallDebug - Uninstalls the Debug build. uninstallDebugAndroidTest - Uninstalls the android (on device) tests for the Debug build. uninstallDynamicProfile - Uninstalls the DynamicProfile build. uninstallDynamicRelease - Uninstalls the DynamicRelease build. uninstallProfile - Uninstalls the Profile build. uninstallRelease - Uninstalls the Release build. Verification tasks ------------------ check - Runs all checks. connectedAndroidTest - Installs and runs instrumentation tests for all flavors on connected devices. connectedCheck - Runs all device checks on currently connected devices. connectedDebugAndroidTest - Installs and runs the tests for debug on connected devices. deviceAndroidTest - Installs and runs instrumentation tests using all Device Providers. deviceCheck - Runs all device checks using Device Providers and Test Servers. lint - Runs lint on all variants. lintDebug - Runs lint on the Debug build. lintDynamicProfile - Runs lint on the DynamicProfile build. lintDynamicRelease - Runs lint on the DynamicRelease build. lintProfile - Runs lint on the Profile build. lintRelease - Runs lint on the Release build. lintVitalRelease - Runs lint on just the fatal issues in the release build. test - Run unit tests for all variants. testDebugUnitTest - Run unit tests for the debug build. testDynamicProfileUnitTest - Run unit tests for the dynamicProfile build. testDynamicReleaseUnitTest - Run unit tests for the dynamicRelease build. testProfileUnitTest - Run unit tests for the profile build. testReleaseUnitTest - Run unit tests for the release build. Other tasks ----------- assembleDebugAndroidTest assembleDebugUnitTest assembleDynamicProfileUnitTest assembleDynamicReleaseUnitTest assembleProfileUnitTest assembleReleaseUnitTest buildDebugPreBundle buildDynamicProfilePreBundle buildDynamicReleasePreBundle buildProfilePreBundle buildReleasePreBundle bundle bundleDebugAndroidTestResources bundleDebugResources bundleDynamicProfileResources bundleDynamicReleaseResources bundleProfileResources bundleReleaseResources checkDebugAndroidTestClasspath checkDebugClasspath checkDebugLibraries checkDebugManifest checkDynamicProfileClasspath checkDynamicProfileLibraries checkDynamicProfileManifest checkDynamicReleaseClasspath checkDynamicReleaseLibraries checkDynamicReleaseManifest checkProfileClasspath checkProfileLibraries checkProfileManifest checkReleaseClasspath checkReleaseLibraries checkReleaseManifest compileDebugAidl compileDebugAndroidTestAidl compileDebugAndroidTestJavaWithJavac compileDebugAndroidTestNdk compileDebugAndroidTestRenderscript compileDebugAndroidTestShaders compileDebugJavaWithJavac compileDebugNdk compileDebugRenderscript compileDebugShaders compileDebugUnitTestJavaWithJavac compileDynamicProfileAidl compileDynamicProfileJavaWithJavac compileDynamicProfileNdk compileDynamicProfileRenderscript compileDynamicProfileShaders compileDynamicProfileUnitTestJavaWithJavac compileDynamicReleaseAidl compileDynamicReleaseJavaWithJavac compileDynamicReleaseNdk compileDynamicReleaseRenderscript compileDynamicReleaseShaders compileDynamicReleaseUnitTestJavaWithJavac compileLint compileProfileAidl compileProfileJavaWithJavac compileProfileNdk compileProfileRenderscript compileProfileShaders compileProfileUnitTestJavaWithJavac compileReleaseAidl compileReleaseJavaWithJavac compileReleaseNdk compileReleaseRenderscript compileReleaseShaders compileReleaseUnitTestJavaWithJavac consumeConfigAttr copyFlutterAssetsDebug copyFlutterAssetsDynamicProfile copyFlutterAssetsDynamicRelease copyFlutterAssetsProfile copyFlutterAssetsRelease createDebugCompatibleScreenManifests createDynamicProfileCompatibleScreenManifests createDynamicReleaseCompatibleScreenManifests createMockableJar createProfileCompatibleScreenManifests createReleaseCompatibleScreenManifests extractApksForDebug extractApksForDynamicProfile extractApksForDynamicRelease extractApksForProfile extractApksForRelease extractProguardFiles flutterBuildDebug flutterBuildDynamicProfile flutterBuildDynamicRelease flutterBuildProfile flutterBuildRelease flutterBuildX86Jar generateDebugAndroidTestAssets generateDebugAndroidTestBuildConfig generateDebugAndroidTestResources generateDebugAndroidTestResValues generateDebugAndroidTestSources generateDebugAssets generateDebugBuildConfig generateDebugFeatureMetadata generateDebugFeatureTransitiveDeps generateDebugResources generateDebugResValues generateDebugSources generateDebugUnitTestAssets generateDebugUnitTestResources generateDebugUnitTestSources generateDynamicProfileAssets generateDynamicProfileBuildConfig generateDynamicProfileFeatureMetadata generateDynamicProfileFeatureTransitiveDeps generateDynamicProfileResources generateDynamicProfileResValues generateDynamicProfileSources generateDynamicProfileUnitTestAssets generateDynamicProfileUnitTestResources generateDynamicProfileUnitTestSources generateDynamicReleaseAssets generateDynamicReleaseBuildConfig generateDynamicReleaseFeatureMetadata generateDynamicReleaseFeatureTransitiveDeps generateDynamicReleaseResources generateDynamicReleaseResValues generateDynamicReleaseSources generateDynamicReleaseUnitTestAssets generateDynamicReleaseUnitTestResources generateDynamicReleaseUnitTestSources generateProfileAssets generateProfileBuildConfig generateProfileFeatureMetadata generateProfileFeatureTransitiveDeps generateProfileResources generateProfileResValues generateProfileSources generateProfileUnitTestAssets generateProfileUnitTestResources generateProfileUnitTestSources generateReleaseAssets generateReleaseBuildConfig generateReleaseFeatureMetadata generateReleaseFeatureTransitiveDeps generateReleaseResources generateReleaseResValues generateReleaseSources generateReleaseUnitTestAssets generateReleaseUnitTestResources generateReleaseUnitTestSources javaPreCompileDebug javaPreCompileDebugAndroidTest javaPreCompileDebugUnitTest javaPreCompileDynamicProfile javaPreCompileDynamicProfileUnitTest javaPreCompileDynamicRelease javaPreCompileDynamicReleaseUnitTest javaPreCompileProfile javaPreCompileProfileUnitTest javaPreCompileRelease javaPreCompileReleaseUnitTest mainApkListPersistenceDebug mainApkListPersistenceDebugAndroidTest mainApkListPersistenceDynamicProfile mainApkListPersistenceDynamicRelease mainApkListPersistenceProfile mainApkListPersistenceRelease makeApkFromBundleForDebug makeApkFromBundleForDynamicProfile makeApkFromBundleForDynamicRelease makeApkFromBundleForProfile makeApkFromBundleForRelease mergeDebugAndroidTestAssets mergeDebugAndroidTestJniLibFolders mergeDebugAndroidTestResources mergeDebugAndroidTestShaders mergeDebugAssets mergeDebugJniLibFolders mergeDebugResources mergeDebugShaders mergeDynamicProfileAssets mergeDynamicProfileJniLibFolders mergeDynamicProfileResources mergeDynamicProfileShaders mergeDynamicReleaseAssets mergeDynamicReleaseJniLibFolders mergeDynamicReleaseResources mergeDynamicReleaseShaders mergeProfileAssets mergeProfileJniLibFolders mergeProfileResources mergeProfileShaders mergeReleaseAssets mergeReleaseJniLibFolders mergeReleaseResources mergeReleaseShaders packageAppClassesDebug packageAppClassesDebugAndroidTest packageAppClassesDebugUnitTest packageAppClassesDynamicProfile packageAppClassesDynamicProfileUnitTest packageAppClassesDynamicRelease packageAppClassesDynamicReleaseUnitTest packageAppClassesProfile packageAppClassesProfileUnitTest packageAppClassesRelease packageAppClassesReleaseUnitTest packageDebug packageDebugAndroidTest packageDebugBundle packageDebugUniversalApk packageDynamicProfile packageDynamicProfileBundle packageDynamicProfileUniversalApk packageDynamicRelease packageDynamicReleaseBundle packageDynamicReleaseUniversalApk packageProfile packageProfileBundle packageProfileUniversalApk packageRelease packageReleaseBundle packageReleaseUniversalApk preBuild preDebugAndroidTestBuild preDebugBuild preDebugUnitTestBuild preDynamicProfileBuild preDynamicProfileUnitTestBuild preDynamicReleaseBuild preDynamicReleaseUnitTestBuild prepareLintJar preProfileBuild preProfileUnitTestBuild preReleaseBuild preReleaseUnitTestBuild processDebugAndroidTestJavaRes processDebugAndroidTestManifest processDebugAndroidTestResources processDebugJavaRes processDebugManifest processDebugResources processDebugUnitTestJavaRes processDynamicProfileJavaRes processDynamicProfileManifest processDynamicProfileResources processDynamicProfileUnitTestJavaRes processDynamicReleaseJavaRes processDynamicReleaseManifest processDynamicReleaseResources processDynamicReleaseUnitTestJavaRes processProfileJavaRes processProfileManifest processProfileResources processProfileUnitTestJavaRes processReleaseJavaRes processReleaseManifest processReleaseResources processReleaseUnitTestJavaRes reportBuildArtifactsDebug reportBuildArtifactsDynamicProfile reportBuildArtifactsDynamicRelease reportBuildArtifactsProfile reportBuildArtifactsRelease reportSourceSetTransformAndroidTest reportSourceSetTransformAndroidTestDebug reportSourceSetTransformDebug reportSourceSetTransformDynamicProfile reportSourceSetTransformDynamicRelease reportSourceSetTransformMain reportSourceSetTransformProfile reportSourceSetTransformRelease reportSourceSetTransformTest reportSourceSetTransformTestDebug reportSourceSetTransformTestDynamicProfile reportSourceSetTransformTestDynamicRelease reportSourceSetTransformTestProfile reportSourceSetTransformTestRelease resolveConfigAttr splitsDiscoveryTaskDebug splitsDiscoveryTaskDynamicProfile splitsDiscoveryTaskDynamicRelease splitsDiscoveryTaskProfile splitsDiscoveryTaskRelease transformClassesWithDexBuilderForDebug transformClassesWithDexBuilderForDebugAndroidTest transformClassesWithDexBuilderForDynamicProfile transformClassesWithDexBuilderForDynamicRelease transformClassesWithDexBuilderForProfile transformClassesWithDexBuilderForRelease transformDexArchiveWithDexMergerForDebug transformDexArchiveWithDexMergerForDebugAndroidTest transformDexArchiveWithDexMergerForDynamicProfile transformDexArchiveWithDexMergerForDynamicRelease transformDexArchiveWithDexMergerForProfile transformDexArchiveWithDexMergerForRelease transformDexArchiveWithExternalLibsDexMergerForDebug transformDexArchiveWithExternalLibsDexMergerForDebugAndroidTest transformDexArchiveWithExternalLibsDexMergerForDynamicProfile transformDexArchiveWithExternalLibsDexMergerForDynamicRelease transformDexArchiveWithExternalLibsDexMergerForProfile transformDexArchiveWithExternalLibsDexMergerForRelease transformNativeLibsWithMergeJniLibsForDebug transformNativeLibsWithMergeJniLibsForDebugAndroidTest transformNativeLibsWithMergeJniLibsForDynamicProfile transformNativeLibsWithMergeJniLibsForDynamicRelease transformNativeLibsWithMergeJniLibsForProfile transformNativeLibsWithMergeJniLibsForRelease transformResourcesWithMergeJavaResForDebug transformResourcesWithMergeJavaResForDebugAndroidTest transformResourcesWithMergeJavaResForDebugUnitTest transformResourcesWithMergeJavaResForDynamicProfile transformResourcesWithMergeJavaResForDynamicProfileUnitTest transformResourcesWithMergeJavaResForDynamicRelease transformResourcesWithMergeJavaResForDynamicReleaseUnitTest transformResourcesWithMergeJavaResForProfile transformResourcesWithMergeJavaResForProfileUnitTest transformResourcesWithMergeJavaResForRelease transformResourcesWithMergeJavaResForReleaseUnitTest validateSigningDebug validateSigningDebugAndroidTest validateSigningDynamicProfile validateSigningDynamicRelease validateSigningProfile validateSigningRelease writeDebugApplicationId writeDynamicProfileApplicationId writeDynamicReleaseApplicationId writeProfileApplicationId writeReleaseApplicationId Rules ----- Pattern: clean&lt;TaskName&gt;: Cleans the output files of a task. Pattern: build&lt;ConfigurationName&gt;: Assembles the artifacts of a configuration. Pattern: upload&lt;ConfigurationName&gt;: Assembles and uploads the artifacts belonging to a configuration. 1 actionable task: 1 executed [ +17 ms] Resolving dependencies... (completed) [ +3 ms] executing: D:\mywork\androidsdk\sdk2\build-tools\28.0.3\aapt dump xmltree D:\mywork\Projet\\Flutter\\build\app\outputs\apk\app.apk AndroidManifest.xml [ +36 ms] Exit code 0 from: D:\mywork\androidsdk\sdk2\build-tools\28.0.3\aapt dump xmltree D:\mywork\Projet\\Flutter\\build\app\outputs\apk\app.apk AndroidManifest.xml [ ] N: android=http://schemas.android.com/apk/res/android E: manifest (line=2) A: android:versionCode(0x0101021b)=(type 0x10)0x1 A: android:versionName(0x0101021c)="1.0.0" (Raw: "1.0.0") A: package="com.example." (Raw: "com.example.") A: platformBuildVersionCode=(type 0x10)0x1 A: platformBuildVersionName="1.0.0" (Raw: "1.0.0") E: uses-sdk (line=7) A: android:minSdkVersion(0x0101020c)=(type 0x10)0x10 A: android:targetSdkVersion(0x01010270)=(type 0x10)0x1b E: uses-permission (line=16) A: android:name(0x01010003)="android.permission.INTERNET" (Raw: "android.permission.INTERNET") E: uses-permission (line=17) A: android:name(0x01010003)="android.permission.ACCESS_NETWORK_STATE" (Raw: "android.permission.ACCESS_NETWORK_STATE") E: uses-permission (line=18) A: android:name(0x01010003)="android.permission.WAKE_LOCK" (Raw: "android.permission.WAKE_LOCK") E: uses-permission (line=19) A: android:name(0x01010003)="com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE" (Raw: "com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE") E: uses-permission (line=20) A: android:name(0x01010003)="com.google.android.c2dm.permission.RECEIVE" (Raw: "com.google.android.c2dm.permission.RECEIVE") E: application (line=28) A: android:label(0x01010001)="" (Raw: "") A: android:icon(0x01010002)=@0x7f090000 A: android:name(0x01010003)="io.flutter.app.FlutterApplication" (Raw: "io.flutter.app.FlutterApplication") A: android:debuggable(0x0101000f)=(type 0x12)0xffffffff E: activity (line=33) A: android:theme(0x01010000)=@0x7f0b0000 A: android:name(0x01010003)="com.example..MainActivity" (Raw: "com.example..MainActivity") A: android:launchMode(0x0101001d)=(type 0x10)0x1 A: android:configChanges(0x0101001f)=(type 0x11)0x400035b4 A: android:windowSoftInputMode(0x0101022b)=(type 0x11)0x10 A: android:hardwareAccelerated(0x010102d3)=(type 0x12)0xffffffff E: meta-data (line=47) A: android:name(0x01010003)="io.flutter.app.android.SplashScreenUntilFirstFrame" (Raw: "io.flutter.app.android.SplashScreenUntilFirstFrame") A: android:value(0x01010024)=(type 0x12)0xffffffff E: intent-filter (line=51) E: action (line=52) A: android:name(0x01010003)="android.intent.action.MAIN" (Raw: "android.intent.action.MAIN") E: category (line=54) A: android:name(0x01010003)="android.intent.category.LAUNCHER" (Raw: "android.intent.category.LAUNCHER") E: service (line=58) A: android:name(0x01010003)="com.google.firebase.components.ComponentDiscoveryService" (Raw: "com.google.firebase.components.ComponentDiscoveryService") A: android:exported(0x01010010)=(type 0x12)0x0 E: meta-data (line=61) A: android:name(0x01010003)="com.google.firebase.components:com.google.firebase.firestore.FirestoreRegistrar" (Raw: "com.google.firebase.components:com.google.firebase.firestore.FirestoreRegistrar") A: android:value(0x01010024)="com.google.firebase.components.ComponentRegistrar" (Raw: "com.google.firebase.components.ComponentRegistrar") E: meta-data (line=64) A: android:name(0x01010003)="com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar" (Raw: "com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar") A: android:value(0x01010024)="com.google.firebase.components.ComponentRegistrar" (Raw: "com.google.firebase.components.ComponentRegistrar") E: meta-data (line=67) A: android:name(0x01010003)="com.google.firebase.components:com.google.firebase.iid.Registrar" (Raw: "com.google.firebase.components:com.google.firebase.iid.Registrar") A: android:value(0x01010024)="com.google.firebase.components.ComponentRegistrar" (Raw: "com.google.firebase.components.ComponentRegistrar") E: receiver (line=72) A: android:name(0x01010003)="com.google.android.gms.measurement.AppMeasurementReceiver" (Raw: "com.google.android.gms.measurement.AppMeasurementReceiver") A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: receiver (line=77) A: android:name(0x01010003)="com.google.android.gms.measurement.AppMeasurementInstallReferrerReceiver" (Raw: "com.google.android.gms.measurement.AppMeasurementInstallReferrerReceiver") A: android:permission(0x01010006)="android.permission.INSTALL_PACKAGES" (Raw: "android.permission.INSTALL_PACKAGES") A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=82) E: action (line=83) A: android:name(0x01010003)="com.android.vending.INSTALL_REFERRER" (Raw: "com.android.vending.INSTALL_REFERRER") E: service (line=87) A: android:name(0x01010003)="com.google.android.gms.measurement.AppMeasurementService" (Raw: "com.google.android.gms.measurement.AppMeasurementService") A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: service (line=91) A: android:name(0x01010003)="com.google.android.gms.measurement.AppMeasurementJobService" (Raw: "com.google.android.gms.measurement.AppMeasurementJobService") A: android:permission(0x01010006)="android.permission.BIND_JOB_SERVICE" (Raw: "android.permission.BIND_JOB_SERVICE") A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: receiver (line=97) A: android:name(0x01010003)="com.google.firebase.iid.FirebaseInstanceIdReceiver" (Raw: "com.google.firebase.iid.FirebaseInstanceIdReceiver") A: android:permission(0x01010006)="com.google.android.c2dm.permission.SEND" (Raw: "com.google.android.c2dm.permission.SEND") A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=101) E: action (line=102) A: android:name(0x01010003)="com.google.android.c2dm.intent.RECEIVE" (Raw: "com.google.android.c2dm.intent.RECEIVE") E: service (line=109) A: android:name(0x01010003)="com.google.firebase.iid.FirebaseInstanceIdService" (Raw: "com.google.firebase.iid.FirebaseInstanceIdService") A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=112) A: android:priority(0x0101001c)=(type 0x10)0xfffffe0c E: action (line=113) A: android:name(0x01010003)="com.google.firebase.INSTANCE_ID_EVENT" (Raw: "com.google.firebase.INSTANCE_ID_EVENT") E: activity (line=117) A: android:theme(0x01010000)=@0x1030010 A: android:name(0x01010003)="com.google.android.gms.common.api.GoogleApiActivity" (Raw: "com.google.android.gms.common.api.GoogleApiActivity") A: android:exported(0x01010010)=(type 0x12)0x0 E: provider (line=122) A: android:name(0x01010003)="com.google.firebase.provider.FirebaseInitProvider" (Raw: "com.google.firebase.provider.FirebaseInitProvider") A: android:exported(0x01010010)=(type 0x12)0x0 A: android:authorities(0x01010018)="com.example..firebaseinitprovider" (Raw: "com.example..firebaseinitprovider") A: android:initOrder(0x0101001a)=(type 0x10)0x64 E: meta-data (line=128) A: android:name(0x01010003)="com.google.android.gms.version" (Raw: "com.google.android.gms.version") A: android:value(0x01010024)=@0x7f070001 E: meta-data (line=131) A: android:name(0x01010003)="android.support.VERSION" (Raw: "android.support.VERSION") A: android:value(0x01010024)="26.1.0" (Raw: "26.1.0") [ +9 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell -x logcat -v time -t 1 [ +71 ms] Exit code 0 from: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell -x logcat -v time -t 1 [ ] --------- beginning of main 11-24 16:51:41.988 W/OpenGLRenderer( 2182): Incorrectly called buildLayer on View: ShortcutAndWidgetContainer, destroying layer... [ +4 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell -x logcat -v time [ +596 ms] DependencyChecker: nothing is modified after 2018-11-24 17:50:47.000. [ +3 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb version [ +55 ms] Android Debug Bridge version 1.0.40 Version 4986621 Installed as D:\mywork\androidsdk\sdk2\platform-tools\adb.EXE [ +3 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb start-server [ +61 ms] Building APK [ +13 ms] Gradle task 'assembleDebug'... [ +2 ms] executing: [D:\mywork\Projet\\Flutter\\android\] D:\mywork\Projet\\Flutter\\android\gradlew.bat -Pverbose=true -Ptarget=D:\mywork\Projet\\Flutter\\lib/main.dart -Ptrack-widget-creation=false -Pfilesystem-scheme=org-dartlang-root assembleDebug [+2053 ms] &gt; Task :app:flutterBuildX86Jar UP-TO-DATE [ +121 ms] &gt; Task :app:checkDebugClasspath UP-TO-DATE [ +8 ms] &gt; Task :app:preBuild UP-TO-DATE [ ] &gt; Task :cloud_firestore:preBuild UP-TO-DATE [ ] &gt; Task :cloud_firestore:preDebugBuild UP-TO-DATE [ ] &gt; Task :cloud_firestore:checkDebugManifest UP-TO-DATE [ +4 ms] &gt; Task :cloud_firestore:processDebugManifest UP-TO-DATE [ ] &gt; Task :firebase_core:preBuild UP-TO-DATE [ ] &gt; Task :firebase_core:preDebugBuild UP-TO-DATE [ ] &gt; Task :firebase_core:checkDebugManifest UP-TO-DATE [ ] &gt; Task :firebase_core:processDebugManifest UP-TO-DATE [ ] &gt; Task :path_provider:preBuild UP-TO-DATE [ ] &gt; Task :path_provider:preDebugBuild UP-TO-DATE [ ] &gt; Task :path_provider:checkDebugManifest UP-TO-DATE [ ] &gt; Task :path_provider:processDebugManifest UP-TO-DATE [ ] &gt; Task :shared_preferences:preBuild UP-TO-DATE [ ] &gt; Task :shared_preferences:preDebugBuild UP-TO-DATE [ ] &gt; Task :shared_preferences:checkDebugManifest UP-TO-DATE [ ] &gt; Task :shared_preferences:processDebugManifest UP-TO-DATE [ ] &gt; Task :app:preDebugBuild UP-TO-DATE [ ] &gt; Task :cloud_firestore:compileDebugAidl NO-SOURCE [ ] &gt; Task :firebase_core:compileDebugAidl NO-SOURCE [ ] &gt; Task :path_provider:compileDebugAidl NO-SOURCE [ ] &gt; Task :shared_preferences:compileDebugAidl NO-SOURCE [ ] &gt; Task :app:compileDebugAidl NO-SOURCE [ ] &gt; Task :cloud_firestore:packageDebugRenderscript NO-SOURCE [ ] &gt; Task :firebase_core:packageDebugRenderscript NO-SOURCE [ ] &gt; Task :path_provider:packageDebugRenderscript NO-SOURCE [ ] &gt; Task :shared_preferences:packageDebugRenderscript NO-SOURCE [ ] &gt; Task :app:compileDebugRenderscript UP-TO-DATE [ ] &gt; Task :app:checkDebugManifest UP-TO-DATE [ ] &gt; Task :app:generateDebugBuildConfig UP-TO-DATE [ +3 ms] &gt; Task :app:prepareLintJar UP-TO-DATE [ +1 ms] &gt; Task :app:cleanMergeDebugAssets [ +144 ms] &gt; Task :app:flutterBuildDebug UP-TO-DATE [ +1 ms] &gt; Task :app:mergeDebugShaders UP-TO-DATE [ ] &gt; Task :app:compileDebugShaders UP-TO-DATE [ ] &gt; Task :app:generateDebugAssets UP-TO-DATE [ ] &gt; Task :cloud_firestore:mergeDebugShaders UP-TO-DATE [ ] &gt; Task :cloud_firestore:compileDebugShaders UP-TO-DATE [ ] &gt; Task :cloud_firestore:generateDebugAssets UP-TO-DATE [ ] &gt; Task :cloud_firestore:packageDebugAssets UP-TO-DATE [ ] &gt; Task :firebase_core:mergeDebugShaders UP-TO-DATE [ ] &gt; Task :firebase_core:compileDebugShaders UP-TO-DATE [ ] &gt; Task :firebase_core:generateDebugAssets UP-TO-DATE [ ] &gt; Task :firebase_core:packageDebugAssets UP-TO-DATE [ ] &gt; Task :path_provider:mergeDebugShaders UP-TO-DATE [ ] &gt; Task :path_provider:compileDebugShaders UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugAssets UP-TO-DATE [ ] &gt; Task :path_provider:packageDebugAssets UP-TO-DATE [ ] &gt; Task :shared_preferences:mergeDebugShaders UP-TO-DATE [ ] &gt; Task :shared_preferences:compileDebugShaders UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugAssets UP-TO-DATE [ ] &gt; Task :shared_preferences:packageDebugAssets UP-TO-DATE [ ] &gt; Task :app:mergeDebugAssets [ +203 ms] &gt; Task :app:copyFlutterAssetsDebug [ +46 ms] &gt; Task :app:mainApkListPersistenceDebug UP-TO-DATE [ +17 ms] &gt; Task :app:generateDebugResValues UP-TO-DATE [ +4 ms] &gt; Task :app:generateDebugResources UP-TO-DATE [ +6 ms] &gt; Task :cloud_firestore:compileDebugRenderscript UP-TO-DATE [ +28 ms] &gt; Task :cloud_firestore:generateDebugResValues UP-TO-DATE [ +11 ms] &gt; Task :cloud_firestore:generateDebugResources UP-TO-DATE [ +6 ms] &gt; Task :cloud_firestore:packageDebugResources UP-TO-DATE [ ] &gt; Task :firebase_core:compileDebugRenderscript UP-TO-DATE [ ] &gt; Task :firebase_core:generateDebugResValues UP-TO-DATE [ ] &gt; Task :firebase_core:generateDebugResources UP-TO-DATE [ ] &gt; Task :firebase_core:packageDebugResources UP-TO-DATE [ ] &gt; Task :path_provider:compileDebugRenderscript UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugResValues UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugResources UP-TO-DATE [ ] &gt; Task :path_provider:packageDebugResources UP-TO-DATE [ ] &gt; Task :shared_preferences:compileDebugRenderscript UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugResValues UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugResources UP-TO-DATE [ ] &gt; Task :shared_preferences:packageDebugResources UP-TO-DATE [ +62 ms] &gt; Task :app:mergeDebugResources UP-TO-DATE [ ] &gt; Task :app:createDebugCompatibleScreenManifests UP-TO-DATE [ ] &gt; Task :app:processDebugManifest UP-TO-DATE [ ] &gt; Task :app:splitsDiscoveryTaskDebug UP-TO-DATE [ ] &gt; Task :cloud_firestore:generateDebugRFile UP-TO-DATE [ +98 ms] &gt; Task :firebase_core:generateDebugRFile UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugRFile UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugRFile UP-TO-DATE [ ] &gt; Task :app:processDebugResources UP-TO-DATE [ ] &gt; Task :app:generateDebugSources UP-TO-DATE [ ] &gt; Task :cloud_firestore:generateDebugBuildConfig UP-TO-DATE [ ] &gt; Task :cloud_firestore:prepareLintJar UP-TO-DATE [ ] &gt; Task :cloud_firestore:generateDebugSources UP-TO-DATE [ ] &gt; Task :cloud_firestore:javaPreCompileDebug UP-TO-DATE [ ] &gt; Task :cloud_firestore:compileDebugJavaWithJavac UP-TO-DATE [ ] &gt; Task :cloud_firestore:processDebugJavaRes NO-SOURCE [ ] &gt; Task :cloud_firestore:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:generateDebugBuildConfig UP-TO-DATE [ ] &gt; Task :firebase_core:prepareLintJar UP-TO-DATE [ ] &gt; Task :firebase_core:generateDebugSources UP-TO-DATE [ ] &gt; Task :firebase_core:javaPreCompileDebug UP-TO-DATE [ +2 ms] &gt; Task :firebase_core:compileDebugJavaWithJavac UP-TO-DATE [ ] &gt; Task :firebase_core:processDebugJavaRes NO-SOURCE [ ] &gt; Task :firebase_core:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugBuildConfig UP-TO-DATE [ ] &gt; Task :path_provider:prepareLintJar UP-TO-DATE [ ] &gt; Task :path_provider:generateDebugSources UP-TO-DATE [ ] &gt; Task :path_provider:javaPreCompileDebug UP-TO-DATE [ +86 ms] &gt; Task :path_provider:compileDebugJavaWithJavac UP-TO-DATE [ ] &gt; Task :path_provider:processDebugJavaRes NO-SOURCE [ ] &gt; Task :path_provider:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugBuildConfig UP-TO-DATE [ ] &gt; Task :shared_preferences:prepareLintJar UP-TO-DATE [ ] &gt; Task :shared_preferences:generateDebugSources UP-TO-DATE [ ] &gt; Task :shared_preferences:javaPreCompileDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:compileDebugJavaWithJavac UP-TO-DATE [ ] &gt; Task :shared_preferences:processDebugJavaRes NO-SOURCE [ +2 ms] &gt; Task :shared_preferences:transformClassesAndResourcesWithPrepareIntermediateJarsForDebug UP-TO-DATE [ ] &gt; Task :app:javaPreCompileDebug UP-TO-DATE [ ] &gt; Task :app:compileDebugJavaWithJavac UP-TO-DATE [ ] &gt; Task :app:compileDebugNdk NO-SOURCE [ ] &gt; Task :app:compileDebugSources UP-TO-DATE [ +93 ms] &gt; Task :app:transformClassesWithDexBuilderForDebug UP-TO-DATE [ ] &gt; Task :app:transformDexArchiveWithExternalLibsDexMergerForDebug UP-TO-DATE [ +2 ms] &gt; Task :app:transformDexArchiveWithDexMergerForDebug UP-TO-DATE [ ] &gt; Task :app:mergeDebugJniLibFolders UP-TO-DATE [ ] &gt; Task :cloud_firestore:compileDebugNdk NO-SOURCE [ ] &gt; Task :cloud_firestore:mergeDebugJniLibFolders UP-TO-DATE [ ] &gt; Task :cloud_firestore:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE [ ] &gt; Task :cloud_firestore:transformNativeLibsWithIntermediateJniLibsForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:compileDebugNdk NO-SOURCE [ ] &gt; Task :firebase_core:mergeDebugJniLibFolders UP-TO-DATE [ ] &gt; Task :firebase_core:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:transformNativeLibsWithIntermediateJniLibsForDebug UP-TO-DATE [ ] &gt; Task :path_provider:compileDebugNdk NO-SOURCE [ ] &gt; Task :path_provider:mergeDebugJniLibFolders UP-TO-DATE [ ] &gt; Task :path_provider:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE [ ] &gt; Task :path_provider:transformNativeLibsWithIntermediateJniLibsForDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:compileDebugNdk NO-SOURCE [ +3 ms] &gt; Task :shared_preferences:mergeDebugJniLibFolders UP-TO-DATE [ ] &gt; Task :shared_preferences:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:transformNativeLibsWithIntermediateJniLibsForDebug UP-TO-DATE [ ] &gt; Task :app:transformNativeLibsWithMergeJniLibsForDebug UP-TO-DATE [ ] &gt; Task :app:checkDebugLibraries UP-TO-DATE [ ] &gt; Task :app:processDebugJavaRes NO-SOURCE [ ] &gt; Task :app:transformResourcesWithMergeJavaResForDebug UP-TO-DATE [ ] &gt; Task :app:validateSigningDebug UP-TO-DATE [ ] &gt; Task :app:packageDebug UP-TO-DATE [ ] &gt; Task :app:assembleDebug UP-TO-DATE [ +85 ms] &gt; Task :cloud_firestore:extractDebugAnnotations UP-TO-DATE [ +3 ms] &gt; Task :cloud_firestore:mergeDebugConsumerProguardFiles UP-TO-DATE [ +12 ms] &gt; Task :cloud_firestore:transformResourcesWithMergeJavaResForDebug UP-TO-DATE [ +8 ms] &gt; Task :cloud_firestore:transformClassesAndResourcesWithSyncLibJarsForDebug UP-TO-DATE [ +16 ms] &gt; Task :cloud_firestore:transformNativeLibsWithSyncJniLibsForDebug UP-TO-DATE [ +6 ms] &gt; Task :cloud_firestore:bundleDebugAar UP-TO-DATE [ +4 ms] &gt; Task :cloud_firestore:compileDebugSources UP-TO-DATE [ +5 ms] &gt; Task :cloud_firestore:assembleDebug UP-TO-DATE [ ] &gt; Task :firebase_core:extractDebugAnnotations UP-TO-DATE [ ] &gt; Task :firebase_core:mergeDebugConsumerProguardFiles UP-TO-DATE [ ] &gt; Task :firebase_core:transformResourcesWithMergeJavaResForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:transformClassesAndResourcesWithSyncLibJarsForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:transformNativeLibsWithSyncJniLibsForDebug UP-TO-DATE [ ] &gt; Task :firebase_core:bundleDebugAar UP-TO-DATE [ ] &gt; Task :firebase_core:compileDebugSources UP-TO-DATE [ ] &gt; Task :firebase_core:assembleDebug UP-TO-DATE [ +11 ms] &gt; Task :path_provider:extractDebugAnnotations UP-TO-DATE [ ] &gt; Task :path_provider:mergeDebugConsumerProguardFiles UP-TO-DATE [ ] &gt; Task :path_provider:transformResourcesWithMergeJavaResForDebug UP-TO-DATE [ +2 ms] &gt; Task :path_provider:transformClassesAndResourcesWithSyncLibJarsForDebug UP-TO-DATE [ +1 ms] &gt; Task :path_provider:transformNativeLibsWithSyncJniLibsForDebug UP-TO-DATE [ +2 ms] &gt; Task :path_provider:bundleDebugAar UP-TO-DATE [ +1 ms] &gt; Task :path_provider:compileDebugSources UP-TO-DATE [ ] &gt; Task :path_provider:assembleDebug UP-TO-DATE [ +1 ms] &gt; Task :shared_preferences:extractDebugAnnotations UP-TO-DATE [ ] &gt; Task :shared_preferences:mergeDebugConsumerProguardFiles UP-TO-DATE [ +1 ms] &gt; Task :shared_preferences:transformResourcesWithMergeJavaResForDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:transformClassesAndResourcesWithSyncLibJarsForDebug UP-TO-DATE [ +1 ms] &gt; Task :shared_preferences:transformNativeLibsWithSyncJniLibsForDebug UP-TO-DATE [ ] &gt; Task :shared_preferences:bundleDebugAar UP-TO-DATE [ ] &gt; Task :shared_preferences:compileDebugSources UP-TO-DATE [ +10 ms] &gt; Task :shared_preferences:assembleDebug UP-TO-DATE [ +1 ms] 123 actionable tasks: 3 executed, 120 up-to-date [ +314 ms] Gradle task 'assembleDebug'... (completed) [ +27 ms] calculateSha: LocalDirectory: 'D:\mywork\Projet\\Flutter\\build\app\outputs\apk'/app.apk [ +554 ms] Built build\app\outputs\apk\debug\app-debug.apk. [ +1 ms] executing: D:\mywork\androidsdk\sdk2\build-tools\28.0.3\aapt dump xmltree D:\mywork\Projet\\Flutter\\build\app\outputs\apk\app.apk AndroidManifest.xml [ +27 ms] Exit code 0 from: D:\mywork\androidsdk\sdk2\build-tools\28.0.3\aapt dump xmltree D:\mywork\Projet\\Flutter\\build\app\outputs\apk\app.apk AndroidManifest.xml [ ] N: android=http://schemas.android.com/apk/res/android E: manifest (line=2) A: android:versionCode(0x0101021b)=(type 0x10)0x1 A: android:versionName(0x0101021c)="1.0.0" (Raw: "1.0.0") A: package="com.example." (Raw: "com.example.") A: platformBuildVersionCode=(type 0x10)0x1 A: platformBuildVersionName="1.0.0" (Raw: "1.0.0") E: uses-sdk (line=7) A: android:minSdkVersion(0x0101020c)=(type 0x10)0x10 A: android:targetSdkVersion(0x01010270)=(type 0x10)0x1b E: uses-permission (line=16) A: android:name(0x01010003)="android.permission.INTERNET" (Raw: "android.permission.INTERNET") E: uses-permission (line=17) A: android:name(0x01010003)="android.permission.ACCESS_NETWORK_STATE" (Raw: "android.permission.ACCESS_NETWORK_STATE") E: uses-permission (line=18) A: android:name(0x01010003)="android.permission.WAKE_LOCK" (Raw: "android.permission.WAKE_LOCK") E: uses-permission (line=19) A: android:name(0x01010003)="com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE" (Raw: "com.google.android.finsky.permission.BIND_GET_INSTALL_REFERRER_SERVICE") E: uses-permission (line=20) A: android:name(0x01010003)="com.google.android.c2dm.permission.RECEIVE" (Raw: "com.google.android.c2dm.permission.RECEIVE") E: application (line=28) A: android:label(0x01010001)="" (Raw: "") A: android:icon(0x01010002)=@0x7f090000 A: android:name(0x01010003)="io.flutter.app.FlutterApplication" (Raw: "io.flutter.app.FlutterApplication") A: android:debuggable(0x0101000f)=(type 0x12)0xffffffff E: activity (line=33) A: android:theme(0x01010000)=@0x7f0b0000 A: android:name(0x01010003)="com.example..MainActivity" (Raw: "com.example..MainActivity") A: android:launchMode(0x0101001d)=(type 0x10)0x1 A: android:configChanges(0x0101001f)=(type 0x11)0x400035b4 A: android:windowSoftInputMode(0x0101022b)=(type 0x11)0x10 A: android:hardwareAccelerated(0x010102d3)=(type 0x12)0xffffffff E: meta-data (line=47) A: android:name(0x01010003)="io.flutter.app.android.SplashScreenUntilFirstFrame" (Raw: "io.flutter.app.android.SplashScreenUntilFirstFrame") A: android:value(0x01010024)=(type 0x12)0xffffffff E: intent-filter (line=51) E: action (line=52) A: android:name(0x01010003)="android.intent.action.MAIN" (Raw: "android.intent.action.MAIN") E: category (line=54) A: android:name(0x01010003)="android.intent.category.LAUNCHER" (Raw: "android.intent.category.LAUNCHER") E: service (line=58) A: android:name(0x01010003)="com.google.firebase.components.ComponentDiscoveryService" (Raw: "com.google.firebase.components.ComponentDiscoveryService") A: android:exported(0x01010010)=(type 0x12)0x0 E: meta-data (line=61) A: android:name(0x01010003)="com.google.firebase.components:com.google.firebase.firestore.FirestoreRegistrar" (Raw: "com.google.firebase.components:com.google.firebase.firestore.FirestoreRegistrar") A: android:value(0x01010024)="com.google.firebase.components.ComponentRegistrar" (Raw: "com.google.firebase.components.ComponentRegistrar") E: meta-data (line=64) A: android:name(0x01010003)="com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar" (Raw: "com.google.firebase.components:com.google.firebase.analytics.connector.internal.AnalyticsConnectorRegistrar") A: android:value(0x01010024)="com.google.firebase.components.ComponentRegistrar" (Raw: "com.google.firebase.components.ComponentRegistrar") E: meta-data (line=67) A: android:name(0x01010003)="com.google.firebase.components:com.google.firebase.iid.Registrar" (Raw: "com.google.firebase.components:com.google.firebase.iid.Registrar") A: android:value(0x01010024)="com.google.firebase.components.ComponentRegistrar" (Raw: "com.google.firebase.components.ComponentRegistrar") E: receiver (line=72) A: android:name(0x01010003)="com.google.android.gms.measurement.AppMeasurementReceiver" (Raw: "com.google.android.gms.measurement.AppMeasurementReceiver") A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: receiver (line=77) A: android:name(0x01010003)="com.google.android.gms.measurement.AppMeasurementInstallReferrerReceiver" (Raw: "com.google.android.gms.measurement.AppMeasurementInstallReferrerReceiver") A: android:permission(0x01010006)="android.permission.INSTALL_PACKAGES" (Raw: "android.permission.INSTALL_PACKAGES") A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=82) E: action (line=83) A: android:name(0x01010003)="com.android.vending.INSTALL_REFERRER" (Raw: "com.android.vending.INSTALL_REFERRER") E: service (line=87) A: android:name(0x01010003)="com.google.android.gms.measurement.AppMeasurementService" (Raw: "com.google.android.gms.measurement.AppMeasurementService") A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: service (line=91) A: android:name(0x01010003)="com.google.android.gms.measurement.AppMeasurementJobService" (Raw: "com.google.android.gms.measurement.AppMeasurementJobService") A: android:permission(0x01010006)="android.permission.BIND_JOB_SERVICE" (Raw: "android.permission.BIND_JOB_SERVICE") A: android:enabled(0x0101000e)=(type 0x12)0xffffffff A: android:exported(0x01010010)=(type 0x12)0x0 E: receiver (line=97) A: android:name(0x01010003)="com.google.firebase.iid.FirebaseInstanceIdReceiver" (Raw: "com.google.firebase.iid.FirebaseInstanceIdReceiver") A: android:permission(0x01010006)="com.google.android.c2dm.permission.SEND" (Raw: "com.google.android.c2dm.permission.SEND") A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=101) E: action (line=102) A: android:name(0x01010003)="com.google.android.c2dm.intent.RECEIVE" (Raw: "com.google.android.c2dm.intent.RECEIVE") E: service (line=109) A: android:name(0x01010003)="com.google.firebase.iid.FirebaseInstanceIdService" (Raw: "com.google.firebase.iid.FirebaseInstanceIdService") A: android:exported(0x01010010)=(type 0x12)0xffffffff E: intent-filter (line=112) A: android:priority(0x0101001c)=(type 0x10)0xfffffe0c E: action (line=113) A: android:name(0x01010003)="com.google.firebase.INSTANCE_ID_EVENT" (Raw: "com.google.firebase.INSTANCE_ID_EVENT") E: activity (line=117) A: android:theme(0x01010000)=@0x1030010 A: android:name(0x01010003)="com.google.android.gms.common.api.GoogleApiActivity" (Raw: "com.google.android.gms.common.api.GoogleApiActivity") A: android:exported(0x01010010)=(type 0x12)0x0 E: provider (line=122) A: android:name(0x01010003)="com.google.firebase.provider.FirebaseInitProvider" (Raw: "com.google.firebase.provider.FirebaseInitProvider") A: android:exported(0x01010010)=(type 0x12)0x0 A: android:authorities(0x01010018)="com.example..firebaseinitprovider" (Raw: "com.example..firebaseinitprovider") A: android:initOrder(0x0101001a)=(type 0x10)0x64 E: meta-data (line=128) A: android:name(0x01010003)="com.google.android.gms.version" (Raw: "com.google.android.gms.version") A: android:value(0x01010024)=@0x7f070001 E: meta-data (line=131) A: android:name(0x01010003)="android.support.VERSION" (Raw: "android.support.VERSION") A: android:value(0x01010024)="26.1.0" (Raw: "26.1.0") [ +4 ms] Stopping app 'app.apk' on Android SDK built for x86 64. [ ] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell am force-stop com.example. [ +294 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell pm list packages com.example. [ +275 ms] package:com.example. [ +2 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell cat /data/local/tmp/sky.com.example..sha1 [ +45 ms] 4a9ca306051ab02038550896b38161cef7844d8c [ +1 ms] Latest build already installed. [ ] Android SDK built for x86 64 startApp [ +1 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 shell am start -a android.intent.action.RUN -f 0x20000000 --ez enable-background-compilation true --ez enable-dart-profiling true --ez enable-checked-mode true com.example./com.example..MainActivity [ +292 ms] Starting: Intent { act=android.intent.action.RUN flg=0x20000000 cmp=com.example./.MainActivity (has extras) } [ ] Waiting for observatory port to be available... [ +392 ms] Observatory URL on device: http://127.0.0.1:43411/ [ +1 ms] executing: D:\mywork\androidsdk\sdk2\platform-tools\adb -s emulator-5554 forward tcp:0 tcp:43411 [ +45 ms] 62673 [ ] Forwarded host port 62673 to device port 43411 for Observatory [ +6 ms] Connecting to service protocol: http://127.0.0.1:62673/ [ +335 ms] Successfully connected to service protocol: http://127.0.0.1:62673/ [ +4 ms] Sending to VM service: getVM({}) [ +11 ms] Result: {type: VM, name: vm, architectureBits: 64, targetCPU: x64, hostCPU: Virtual CPU, version: 2.1.0-dev.9.4.flutter-f9ebf21297 (Thu Nov 8 23:00:07 2018 +0100) on "android_x64", _profilerMode: VM, _nativeZoneMemoryUsage: 0, pid: 28202, startTime: 15430... [ +8 ms] Sending to VM service: getIsolate({isolateId: isolates/189969803}) [ +5 ms] Sending to VM service: _flutter.listViews({}) [ +15 ms] Result: {type: FlutterViewList, views: [{type: FlutterView, id: _flutterView/0x709f17383f98, isolate: {type: @Isolate, fixedId: true, id: isolates/189969803, name: main.dart$main-189969803, number: 189969803}}]} [ +8 ms] DevFS: Creating new filesystem on the device (null) [ +1 ms] Sending to VM service: _createDevFS({fsName: }) [ +41 ms] Result: {type: Isolate, fixedId: true, id: isolates/189969803, name: main.dart:main(), number: 189969803, _originNumber: 189969803, startTime: 1543078322516, _heaps: {new: {type: HeapSpace, name: new, vmName: Scavenger, collections: 2, avgCollectionPeriod... [ +36 ms] Result: {type: FileSystem, name: , uri: file:///data/user/0/com.example./cache///} [ ] DevFS: Created new filesystem on device (file:///data/user/0/com.example./cache///) [ +2 ms] Updating assets [ +174 ms] Syncing files to device Android SDK built for x86 64... [ +3 ms] DevFS: Starting sync from LocalDirectory: 'D:\mywork\Projet\\Flutter\' [ ] Scanning project files [ +11 ms] Scanning package files [ +110 ms] Scanning asset files [ +1 ms] Scanning for deleted files [ +73 ms] Compiling dart to kernel with 613 updated files [ +10 ms] C:\flutter\bin\cache\dart-sdk\bin\dart C:\flutter\bin\cache\artifacts\engine\windows-x64\frontend_server.dart.snapshot --sdk-root C:\flutter\bin\cache\artifacts\engine\common\flutter_patched_sdk/ --incremental --strong --target=flutter --output-dill build\app.dill --packages D:\mywork\Projet\\Flutter\\.packages --filesystem-scheme org-dartlang-root [ +84 ms] I/Choreographer(28202): Skipped 54 frames! The application may be doing too much work on its main thread. [ +7 ms] D/EGL_emulation(28202): eglMakeCurrent: 0x709f19ca20a0: ver 2 0 (tinfo 0x709f19c0c6c0) [ +745 ms] D/ (28202): HostConnection::get() New Host Connection established 0x709f154524a0, tid 28219 [ +18 ms] D/EGL_emulation(28202): eglMakeCurrent: 0x709f211318c0: ver 2 0 (tinfo 0x709f19c0c440) [+1055 ms] Updating files [ +285 ms] DevFS: Sync finished [ ] Syncing files to device Android SDK built for x86 64... (completed) [ ] Synced 2.1MB. [ +1 ms] Sending to VM service: _flutter.listViews({}) [ +16 ms] Result: {type: FlutterViewList, views: [{type: FlutterView, id: _flutterView/0x709f17383f98, isolate: {type: @Isolate, fixedId: true, id: isolates/189969803, name: main.dart$main-189969803, number: 189969803}}]} [ +1 ms] Connected to _flutterView/0x709f17383f98. </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" info - 'child' is deprecated and shouldn't be used - lib\Screens\Login\index.dart:51:11 - deprecated_member_use info - Unused import: 'package:font_awesome_flutter/font_awesome_flutter.dart' - lib\Screens\PageEditProfil\index.dart:4:8 - unused_import info - The value of the field '_focusNodeFirstName' isn't used - lib\Screens\PageEditProfil\infosProfil.dart:33:15 - unused_field info - The value of the field '_focusNodeLastName' isn't used - lib\Screens\PageEditProfil\infosProfil.dart:34:15 - unused_field info - The value of the field '_focusNodeDescription' isn't used - lib\Screens\PageEditProfil\infosProfil.dart:35:15 - unused_field info - Name types using UpperCamelCase - lib\Screens\PageGeoUsers\card.dart:4:7 - camel_case_types info - This class inherits from a class marked as @immutable, and therefore should be immutable (all instance fields must be final) - lib\Screens\PageGeoUsers\card.dart:4:7 - must_be_immutable info - Duplicate import - lib\Screens\PageMessages\index.dart:2:8 - duplicate_import info - Unused import: 'package:collection/collection.dart' - lib\Screens\PageMessages\index.dart:3:8 - unused_import info - The top level variable '_kGalleryAssetsPackage' isn't used - lib\Screens\PageMessages\index.dart:4:14 - unused_element info - The top level variable '_kAsset0' isn't used - lib\Screens\PageMessages\index.dart:5:14 - unused_element info - The top level variable '_kAsset1' isn't used - lib\Screens\PageMessages\index.dart:6:14 - unused_element info - The top level variable '_kAsset2' isn't used - lib\Screens\PageMessages\index.dart:7:14 - unused_element info - Unused import: '/Models/NotificationsApp.dart' - lib\Screens\PageNotifications\index.dart:2:8 - unused_import info - The value of the field '_currentSexes' isn't used - lib\Screens\PageSettings\index.dart:17:10 - unused_field info - Unused import: '/Screens/UserProfil/user_detail_body.dart' - lib\Screens\UserProfil\footer\infos.dart:2:8 - unused_import info - This class inherits from a class marked as @immutable, and therefore should be immutable (all instance fields must be final) - lib\Screens\UserProfil\footer\infos.dart:5:7 - must_be_immutable info - Field doesn't override an inherited getter or setter - lib\Screens\UserProfil\footer\infos.dart:8:15 - override_on_non_overriding_field info - The method '_buildActionButtons' isn't used - lib\Screens\UserProfil\header\user_detail_header.dart:58:10 - unused_element info - The value of the local variable 'textTheme' isn't used - lib\Screens\UserProfil\header\user_detail_header.dart:107:9 - unused_local_variable info - Unused import: '/Screens/UserProfil/user_detail_body.dart' - lib\Screens\UserProfil\user_details_page.dart:3:8 - unused_import info - Unused import: '/Screens/UserProfil/header/user_detail_header.dart' - lib\Screens\UserProfil\user_details_page.dart:4:8 - unused_import info - Unused import: 'package:meta/meta.dart' - lib\Screens\UserProfil\user_details_page.dart:6:8 - unused_import info - Unused import: '/Screens/UserProfil/footer/photos.dart' - lib\Screens\UserProfil\user_details_page.dart:8:8 - unused_import info - The method '_buildFabLike' isn't used - lib\Screens\UserProfil\user_details_page.dart:140:10 - unused_element info - The value of the local variable 'textTheme' isn't used - lib\Screens\UserProfil\user_details_page.dart:183:9 - unused_local_variable"><pre class="notranslate"><code class="notranslate"> info - 'child' is deprecated and shouldn't be used - lib\Screens\Login\index.dart:51:11 - deprecated_member_use info - Unused import: 'package:font_awesome_flutter/font_awesome_flutter.dart' - lib\Screens\PageEditProfil\index.dart:4:8 - unused_import info - The value of the field '_focusNodeFirstName' isn't used - lib\Screens\PageEditProfil\infosProfil.dart:33:15 - unused_field info - The value of the field '_focusNodeLastName' isn't used - lib\Screens\PageEditProfil\infosProfil.dart:34:15 - unused_field info - The value of the field '_focusNodeDescription' isn't used - lib\Screens\PageEditProfil\infosProfil.dart:35:15 - unused_field info - Name types using UpperCamelCase - lib\Screens\PageGeoUsers\card.dart:4:7 - camel_case_types info - This class inherits from a class marked as @immutable, and therefore should be immutable (all instance fields must be final) - lib\Screens\PageGeoUsers\card.dart:4:7 - must_be_immutable info - Duplicate import - lib\Screens\PageMessages\index.dart:2:8 - duplicate_import info - Unused import: 'package:collection/collection.dart' - lib\Screens\PageMessages\index.dart:3:8 - unused_import info - The top level variable '_kGalleryAssetsPackage' isn't used - lib\Screens\PageMessages\index.dart:4:14 - unused_element info - The top level variable '_kAsset0' isn't used - lib\Screens\PageMessages\index.dart:5:14 - unused_element info - The top level variable '_kAsset1' isn't used - lib\Screens\PageMessages\index.dart:6:14 - unused_element info - The top level variable '_kAsset2' isn't used - lib\Screens\PageMessages\index.dart:7:14 - unused_element info - Unused import: '/Models/NotificationsApp.dart' - lib\Screens\PageNotifications\index.dart:2:8 - unused_import info - The value of the field '_currentSexes' isn't used - lib\Screens\PageSettings\index.dart:17:10 - unused_field info - Unused import: '/Screens/UserProfil/user_detail_body.dart' - lib\Screens\UserProfil\footer\infos.dart:2:8 - unused_import info - This class inherits from a class marked as @immutable, and therefore should be immutable (all instance fields must be final) - lib\Screens\UserProfil\footer\infos.dart:5:7 - must_be_immutable info - Field doesn't override an inherited getter or setter - lib\Screens\UserProfil\footer\infos.dart:8:15 - override_on_non_overriding_field info - The method '_buildActionButtons' isn't used - lib\Screens\UserProfil\header\user_detail_header.dart:58:10 - unused_element info - The value of the local variable 'textTheme' isn't used - lib\Screens\UserProfil\header\user_detail_header.dart:107:9 - unused_local_variable info - Unused import: '/Screens/UserProfil/user_detail_body.dart' - lib\Screens\UserProfil\user_details_page.dart:3:8 - unused_import info - Unused import: '/Screens/UserProfil/header/user_detail_header.dart' - lib\Screens\UserProfil\user_details_page.dart:4:8 - unused_import info - Unused import: 'package:meta/meta.dart' - lib\Screens\UserProfil\user_details_page.dart:6:8 - unused_import info - Unused import: '/Screens/UserProfil/footer/photos.dart' - lib\Screens\UserProfil\user_details_page.dart:8:8 - unused_import info - The method '_buildFabLike' isn't used - lib\Screens\UserProfil\user_details_page.dart:140:10 - unused_element info - The value of the local variable 'textTheme' isn't used - lib\Screens\UserProfil\user_details_page.dart:183:9 - unused_local_variable </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[√] Flutter (Channel beta, v0.11.9, on Microsoft Windows [version 10.0.17134.407], locale fr-FR) • Flutter version 0.11.9 at C:\flutter • Framework revision d48e6e433c (4 days ago), 2018-11-20 22:05:23 -0500 • Engine revision 5c8147450d • Dart version 2.1.0 (build 2.1.0-dev.9.4 f9ebf21297) [√] Android toolchain - develop for Android devices (Android SDK 28.0.3) • Android SDK at D:\mywork\androidsdk\sdk2 • Android NDK location not configured (optional; useful for native profiling support) • Platform android-28, build-tools 28.0.3 • ANDROID_HOME = D:\mywork\androidsdk\sdk2 • Java binary at: C:\Program Files\Android\Android Studio1\jre\bin\java • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1136-b06) • All Android licenses accepted. [!] Android Studio (version 3.0) • Android Studio at C:\Program Files\Android\Android Studio X Flutter plugin not installed; this adds Flutter specific functionality. X Dart plugin not installed; this adds Dart specific functionality. X Unable to find bundled Java version. • Try updating or re-installing Android Studio. [√] Android Studio (version 3.2) • Android Studio at C:\Program Files\Android\Android Studio1 • Flutter plugin version 29.1.1 • Dart plugin version 181.5656 • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1136-b06) [√] VS Code, 64-bit edition (version 1.29.1) • VS Code at C:\Program Files\Microsoft VS Code • Flutter extension version 2.20.0 [√] Connected device (1 available) • Android SDK built for x86 64 • emulator-5554 • android-x64 • Android 7.0 (API 24) (emulator)"><pre class="notranslate"><code class="notranslate">[√] Flutter (Channel beta, v0.11.9, on Microsoft Windows [version 10.0.17134.407], locale fr-FR) • Flutter version 0.11.9 at C:\flutter • Framework revision d48e6e433c (4 days ago), 2018-11-20 22:05:23 -0500 • Engine revision 5c8147450d • Dart version 2.1.0 (build 2.1.0-dev.9.4 f9ebf21297) [√] Android toolchain - develop for Android devices (Android SDK 28.0.3) • Android SDK at D:\mywork\androidsdk\sdk2 • Android NDK location not configured (optional; useful for native profiling support) • Platform android-28, build-tools 28.0.3 • ANDROID_HOME = D:\mywork\androidsdk\sdk2 • Java binary at: C:\Program Files\Android\Android Studio1\jre\bin\java • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1136-b06) • All Android licenses accepted. [!] Android Studio (version 3.0) • Android Studio at C:\Program Files\Android\Android Studio X Flutter plugin not installed; this adds Flutter specific functionality. X Dart plugin not installed; this adds Dart specific functionality. X Unable to find bundled Java version. • Try updating or re-installing Android Studio. [√] Android Studio (version 3.2) • Android Studio at C:\Program Files\Android\Android Studio1 • Flutter plugin version 29.1.1 • Dart plugin version 181.5656 • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1136-b06) [√] VS Code, 64-bit edition (version 1.29.1) • VS Code at C:\Program Files\Microsoft VS Code • Flutter extension version 2.20.0 [√] Connected device (1 available) • Android SDK built for x86 64 • emulator-5554 • android-x64 • Android 7.0 (API 24) (emulator) </code></pre></div>
0
<h3 dir="auto">Bug report</h3> <p dir="auto"><strong>Bug summary</strong></p> <p dir="auto">Using 'auto' to compute the number of bins with 2D data only uses the first column to compute the range. This causes all other columns to be incorrectly displayed.</p> <p dir="auto">Calculating histograms using bins='auto' with numpy gives the correct behavior.<br> <strong>Code for reproduction</strong></p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="from pylab import * # four values to examine x = randn(1000, 4)*0.1 + arange(4)/7 figure() ax1 = subplot(211) plt.hist(x, histtype='step') legend(['1', '2', '3', '4']) ax2 = subplot(212) plt.hist(x, bins='auto', histtype='step') legend(['1', '2', '3', '4']) # Match axes so it's clear where the problem is ax2.set_xlim(ax1.get_xlim()) plt.show() # Check that numpy doesn't have this bug _, bins_default = np.histogram(x) _, bins_auto = np.histogram(x, bins='auto') assert(np.min(bins_default) == np.min(bins_auto)) assert(np.max(bins_default) == np.max(bins_auto)) "><pre class="notranslate"><span class="pl-k">from</span> <span class="pl-s1">pylab</span> <span class="pl-k">import</span> <span class="pl-c1">*</span> <span class="pl-c"># four values to examine</span> <span class="pl-s1">x</span> <span class="pl-c1">=</span> <span class="pl-en">randn</span>(<span class="pl-c1">1000</span>, <span class="pl-c1">4</span>)<span class="pl-c1">*</span><span class="pl-c1">0.1</span> <span class="pl-c1">+</span> <span class="pl-en">arange</span>(<span class="pl-c1">4</span>)<span class="pl-c1">/</span><span class="pl-c1">7</span> <span class="pl-en">figure</span>() <span class="pl-s1">ax1</span> <span class="pl-c1">=</span> <span class="pl-en">subplot</span>(<span class="pl-c1">211</span>) <span class="pl-s1">plt</span>.<span class="pl-en">hist</span>(<span class="pl-s1">x</span>, <span class="pl-s1">histtype</span><span class="pl-c1">=</span><span class="pl-s">'step'</span>) <span class="pl-en">legend</span>([<span class="pl-s">'1'</span>, <span class="pl-s">'2'</span>, <span class="pl-s">'3'</span>, <span class="pl-s">'4'</span>]) <span class="pl-s1">ax2</span> <span class="pl-c1">=</span> <span class="pl-en">subplot</span>(<span class="pl-c1">212</span>) <span class="pl-s1">plt</span>.<span class="pl-en">hist</span>(<span class="pl-s1">x</span>, <span class="pl-s1">bins</span><span class="pl-c1">=</span><span class="pl-s">'auto'</span>, <span class="pl-s1">histtype</span><span class="pl-c1">=</span><span class="pl-s">'step'</span>) <span class="pl-en">legend</span>([<span class="pl-s">'1'</span>, <span class="pl-s">'2'</span>, <span class="pl-s">'3'</span>, <span class="pl-s">'4'</span>]) <span class="pl-c"># Match axes so it's clear where the problem is</span> <span class="pl-s1">ax2</span>.<span class="pl-en">set_xlim</span>(<span class="pl-s1">ax1</span>.<span class="pl-en">get_xlim</span>()) <span class="pl-s1">plt</span>.<span class="pl-en">show</span>() <span class="pl-c"># Check that numpy doesn't have this bug</span> <span class="pl-s1">_</span>, <span class="pl-s1">bins_default</span> <span class="pl-c1">=</span> <span class="pl-s1">np</span>.<span class="pl-en">histogram</span>(<span class="pl-s1">x</span>) <span class="pl-s1">_</span>, <span class="pl-s1">bins_auto</span> <span class="pl-c1">=</span> <span class="pl-s1">np</span>.<span class="pl-en">histogram</span>(<span class="pl-s1">x</span>, <span class="pl-s1">bins</span><span class="pl-c1">=</span><span class="pl-s">'auto'</span>) <span class="pl-k">assert</span>(<span class="pl-s1">np</span>.<span class="pl-en">min</span>(<span class="pl-s1">bins_default</span>) <span class="pl-c1">==</span> <span class="pl-s1">np</span>.<span class="pl-en">min</span>(<span class="pl-s1">bins_auto</span>)) <span class="pl-k">assert</span>(<span class="pl-s1">np</span>.<span class="pl-en">max</span>(<span class="pl-s1">bins_default</span>) <span class="pl-c1">==</span> <span class="pl-s1">np</span>.<span class="pl-en">max</span>(<span class="pl-s1">bins_auto</span>))</pre></div> <p dir="auto"><strong>Actual outcome</strong><br> The range of the histogram corresponds to the range of the last column of data for all columns, see second subplot.</p> <p dir="auto"><strong>Expected outcome</strong><br> The range of the histogram should correspond to the min/max of all data, as it is in the first subplot of the example code.</p> <p dir="auto"><strong>Matplotlib version</strong></p> <ul dir="auto"> <li>Operating System: Ubuntu</li> <li>Matplotlib Version: 2.0.0</li> <li>Python Version: 3.5.2</li> </ul>
<h3 dir="auto">plt.hist range bug</h3> <p dir="auto">When using plt.hist with multiple input data sets, not supplying a range, and using a string-based binning option ('auto', for example), the range determined will cut off the later datasets and only fully include the first.</p> <p dir="auto"><strong>Code for reproduction</strong></p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import numpy as np import matplotlib.pyplot as plt data = np.random.normal(0, 1, size=1000) data2 = np.random.normal(3, 1, size=1000) data3 = np.random.normal(6, 1, size=1000) plt.hist([data, data2, data3], bins='auto', histtype='stepfilled', stacked=False) "><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">numpy</span> <span class="pl-k">as</span> <span class="pl-s1">np</span> <span class="pl-k">import</span> <span class="pl-s1">matplotlib</span>.<span class="pl-s1">pyplot</span> <span class="pl-k">as</span> <span class="pl-s1">plt</span> <span class="pl-s1">data</span> <span class="pl-c1">=</span> <span class="pl-s1">np</span>.<span class="pl-s1">random</span>.<span class="pl-en">normal</span>(<span class="pl-c1">0</span>, <span class="pl-c1">1</span>, <span class="pl-s1">size</span><span class="pl-c1">=</span><span class="pl-c1">1000</span>) <span class="pl-s1">data2</span> <span class="pl-c1">=</span> <span class="pl-s1">np</span>.<span class="pl-s1">random</span>.<span class="pl-en">normal</span>(<span class="pl-c1">3</span>, <span class="pl-c1">1</span>, <span class="pl-s1">size</span><span class="pl-c1">=</span><span class="pl-c1">1000</span>) <span class="pl-s1">data3</span> <span class="pl-c1">=</span> <span class="pl-s1">np</span>.<span class="pl-s1">random</span>.<span class="pl-en">normal</span>(<span class="pl-c1">6</span>, <span class="pl-c1">1</span>, <span class="pl-s1">size</span><span class="pl-c1">=</span><span class="pl-c1">1000</span>) <span class="pl-s1">plt</span>.<span class="pl-en">hist</span>([<span class="pl-s1">data</span>, <span class="pl-s1">data2</span>, <span class="pl-s1">data3</span>], <span class="pl-s1">bins</span><span class="pl-c1">=</span><span class="pl-s">'auto'</span>, <span class="pl-s1">histtype</span><span class="pl-c1">=</span><span class="pl-s">'stepfilled'</span>, <span class="pl-s1">stacked</span><span class="pl-c1">=</span><span class="pl-c1">False</span>)</pre></div> <p dir="auto"><strong>Actual outcome</strong><br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/5065341/26168360/6b32991e-3aff-11e7-95ea-bb6b95c98c82.png"><img src="https://cloud.githubusercontent.com/assets/5065341/26168360/6b32991e-3aff-11e7-95ea-bb6b95c98c82.png" alt="bad_hist" style="max-width: 100%;"></a></p> <p dir="auto"><strong>Expected outcome</strong><br> This is the plot using the bin-edges as determined by np.histogram using the following code:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="_, be = np.histogram([data, data2, data3], bins='auto') plt.hist([data, data2, data3], bins=be, histtype='stepfilled', stacked=False)"><pre class="notranslate"><span class="pl-s1">_</span>, <span class="pl-s1">be</span> <span class="pl-c1">=</span> <span class="pl-s1">np</span>.<span class="pl-en">histogram</span>([<span class="pl-s1">data</span>, <span class="pl-s1">data2</span>, <span class="pl-s1">data3</span>], <span class="pl-s1">bins</span><span class="pl-c1">=</span><span class="pl-s">'auto'</span>) <span class="pl-s1">plt</span>.<span class="pl-en">hist</span>([<span class="pl-s1">data</span>, <span class="pl-s1">data2</span>, <span class="pl-s1">data3</span>], <span class="pl-s1">bins</span><span class="pl-c1">=</span><span class="pl-s1">be</span>, <span class="pl-s1">histtype</span><span class="pl-c1">=</span><span class="pl-s">'stepfilled'</span>, <span class="pl-s1">stacked</span><span class="pl-c1">=</span><span class="pl-c1">False</span>)</pre></div> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/5065341/26168446/b42be1e8-3aff-11e7-9b72-5a78a051055a.png"><img src="https://cloud.githubusercontent.com/assets/5065341/26168446/b42be1e8-3aff-11e7-9b72-5a78a051055a.png" alt="good_hist" style="max-width: 100%;"></a></p> <p dir="auto"><strong>Matplotlib version</strong></p> <ul dir="auto"> <li>Operating System: OSX 10.10.5</li> <li>Matplotlib Version: 2.0.1</li> <li>Python Version: 2.7.13</li> <li>Jupyter Version (if applicable): 4.0.6</li> <li>Other Libraries:</li> </ul> <p dir="auto">Python installed via Homebrew, all python packages installed via pip.</p>
1
<p dir="auto">I made a test code for this issue. I made a custom class because I want server to return jsonified list if view function returns list. It works on flask 1.0.2 but it doesn't work on the new flask version (1.1.1)</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="from flask import Flask, Response, jsonify class CustomResponse(Response): @classmethod def force_type(cls, response, environ=None): if isinstance(response, list): return jsonify(response) return super(CustomResponse, cls).force_type(response, environ) app = Flask(__name__) app.response_class = CustomResponse @app.route('/', methods=['GET']) def response_list(): return ['it', 'is', 'test'] if __name__ == '__main__': app.run(host='127.0.0.1') "><pre class="notranslate"><span class="pl-k">from</span> <span class="pl-s1">flask</span> <span class="pl-k">import</span> <span class="pl-v">Flask</span>, <span class="pl-v">Response</span>, <span class="pl-s1">jsonify</span> <span class="pl-k">class</span> <span class="pl-v">CustomResponse</span>(<span class="pl-v">Response</span>): <span class="pl-en">@<span class="pl-s1">classmethod</span></span> <span class="pl-k">def</span> <span class="pl-en">force_type</span>(<span class="pl-s1">cls</span>, <span class="pl-s1">response</span>, <span class="pl-s1">environ</span><span class="pl-c1">=</span><span class="pl-c1">None</span>): <span class="pl-k">if</span> <span class="pl-en">isinstance</span>(<span class="pl-s1">response</span>, <span class="pl-s1">list</span>): <span class="pl-k">return</span> <span class="pl-en">jsonify</span>(<span class="pl-s1">response</span>) <span class="pl-k">return</span> <span class="pl-en">super</span>(<span class="pl-v">CustomResponse</span>, <span class="pl-s1">cls</span>).<span class="pl-en">force_type</span>(<span class="pl-s1">response</span>, <span class="pl-s1">environ</span>) <span class="pl-s1">app</span> <span class="pl-c1">=</span> <span class="pl-v">Flask</span>(<span class="pl-s1">__name__</span>) <span class="pl-s1">app</span>.<span class="pl-s1">response_class</span> <span class="pl-c1">=</span> <span class="pl-v">CustomResponse</span> <span class="pl-en">@<span class="pl-s1">app</span>.<span class="pl-en">route</span>(<span class="pl-s">'/'</span>, <span class="pl-s1">methods</span><span class="pl-c1">=</span>[<span class="pl-s">'GET'</span>])</span> <span class="pl-k">def</span> <span class="pl-en">response_list</span>(): <span class="pl-k">return</span> [<span class="pl-s">'it'</span>, <span class="pl-s">'is'</span>, <span class="pl-s">'test'</span>] <span class="pl-k">if</span> <span class="pl-s1">__name__</span> <span class="pl-c1">==</span> <span class="pl-s">'__main__'</span>: <span class="pl-s1">app</span>.<span class="pl-en">run</span>(<span class="pl-s1">host</span><span class="pl-c1">=</span><span class="pl-s">'127.0.0.1'</span>)</pre></div> <p dir="auto">On 1.0.2 version,</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="# evaluate a WSGI callable, or coerce a different response # class to the correct type try: rv = self.response_class.force_type(rv, request.environ) except TypeError as e: new_error = TypeError( '{e}\nThe view function did not return a valid' ' response. The return type must be a string, tuple,' ' Response instance, or WSGI callable, but it was a' ' {rv.__class__.__name__}.'.format(e=e, rv=rv) )"><pre class="notranslate"><span class="pl-c"># evaluate a WSGI callable, or coerce a different response</span> <span class="pl-c"># class to the correct type</span> <span class="pl-k">try</span>: <span class="pl-s1">rv</span> <span class="pl-c1">=</span> <span class="pl-s1">self</span>.<span class="pl-s1">response_class</span>.<span class="pl-en">force_type</span>(<span class="pl-s1">rv</span>, <span class="pl-s1">request</span>.<span class="pl-s1">environ</span>) <span class="pl-k">except</span> <span class="pl-v">TypeError</span> <span class="pl-k">as</span> <span class="pl-s1">e</span>: <span class="pl-s1">new_error</span> <span class="pl-c1">=</span> <span class="pl-v">TypeError</span>( <span class="pl-s">'{e}<span class="pl-cce">\n</span>The view function did not return a valid'</span> <span class="pl-s">' response. The return type must be a string, tuple,'</span> <span class="pl-s">' Response instance, or WSGI callable, but it was a'</span> <span class="pl-s">' {rv.__class__.__name__}.'</span>.<span class="pl-en">format</span>(<span class="pl-s1">e</span><span class="pl-c1">=</span><span class="pl-s1">e</span>, <span class="pl-s1">rv</span><span class="pl-c1">=</span><span class="pl-s1">rv</span>) )</pre></div> <p dir="auto">flask changes type forcely by calling force_type of <code class="notranslate">response_class</code>, but newest version doesn't change. (code below)</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" if isinstance(rv, (text_type, bytes, bytearray)): # let the response class set the status and headers instead of # waiting to do it manually, so that the class can handle any # special logic rv = self.response_class(rv, status=status, headers=headers) status = headers = None elif isinstance(rv, dict): rv = jsonify(rv) elif isinstance(rv, BaseResponse) or callable(rv): # evaluate a WSGI callable, or coerce a different response # class to the correct type try: rv = self.response_class.force_type(rv, request.environ) except TypeError as e: new_error = TypeError( &quot;{e}\nThe view function did not return a valid&quot; &quot; response. The return type must be a string, dict, tuple,&quot; &quot; Response instance, or WSGI callable, but it was a&quot; &quot; {rv.__class__.__name__}.&quot;.format(e=e, rv=rv) ) reraise(TypeError, new_error, sys.exc_info()[2]) else: raise TypeError( &quot;The view function did not return a valid&quot; &quot; response. The return type must be a string, dict, tuple,&quot; &quot; Response instance, or WSGI callable, but it was a&quot; &quot; {rv.__class__.__name__}.&quot;.format(rv=rv) )"><pre class="notranslate"> <span class="pl-k">if</span> <span class="pl-en">isinstance</span>(<span class="pl-s1">rv</span>, (<span class="pl-s1">text_type</span>, <span class="pl-s1">bytes</span>, <span class="pl-s1">bytearray</span>)): <span class="pl-c"># let the response class set the status and headers instead of</span> <span class="pl-c"># waiting to do it manually, so that the class can handle any</span> <span class="pl-c"># special logic</span> <span class="pl-s1">rv</span> <span class="pl-c1">=</span> <span class="pl-s1">self</span>.<span class="pl-en">response_class</span>(<span class="pl-s1">rv</span>, <span class="pl-s1">status</span><span class="pl-c1">=</span><span class="pl-s1">status</span>, <span class="pl-s1">headers</span><span class="pl-c1">=</span><span class="pl-s1">headers</span>) <span class="pl-s1">status</span> <span class="pl-c1">=</span> <span class="pl-s1">headers</span> <span class="pl-c1">=</span> <span class="pl-c1">None</span> <span class="pl-k">elif</span> <span class="pl-en">isinstance</span>(<span class="pl-s1">rv</span>, <span class="pl-s1">dict</span>): <span class="pl-s1">rv</span> <span class="pl-c1">=</span> <span class="pl-en">jsonify</span>(<span class="pl-s1">rv</span>) <span class="pl-k">elif</span> <span class="pl-en">isinstance</span>(<span class="pl-s1">rv</span>, <span class="pl-v">BaseResponse</span>) <span class="pl-c1">or</span> <span class="pl-en">callable</span>(<span class="pl-s1">rv</span>): <span class="pl-c"># evaluate a WSGI callable, or coerce a different response</span> <span class="pl-c"># class to the correct type</span> <span class="pl-k">try</span>: <span class="pl-s1">rv</span> <span class="pl-c1">=</span> <span class="pl-s1">self</span>.<span class="pl-s1">response_class</span>.<span class="pl-en">force_type</span>(<span class="pl-s1">rv</span>, <span class="pl-s1">request</span>.<span class="pl-s1">environ</span>) <span class="pl-k">except</span> <span class="pl-v">TypeError</span> <span class="pl-k">as</span> <span class="pl-s1">e</span>: <span class="pl-s1">new_error</span> <span class="pl-c1">=</span> <span class="pl-v">TypeError</span>( <span class="pl-s">"{e}<span class="pl-cce">\n</span>The view function did not return a valid"</span> <span class="pl-s">" response. The return type must be a string, dict, tuple,"</span> <span class="pl-s">" Response instance, or WSGI callable, but it was a"</span> <span class="pl-s">" {rv.__class__.__name__}."</span>.<span class="pl-en">format</span>(<span class="pl-s1">e</span><span class="pl-c1">=</span><span class="pl-s1">e</span>, <span class="pl-s1">rv</span><span class="pl-c1">=</span><span class="pl-s1">rv</span>) ) <span class="pl-en">reraise</span>(<span class="pl-v">TypeError</span>, <span class="pl-s1">new_error</span>, <span class="pl-s1">sys</span>.<span class="pl-en">exc_info</span>()[<span class="pl-c1">2</span>]) <span class="pl-k">else</span>: <span class="pl-k">raise</span> <span class="pl-v">TypeError</span>( <span class="pl-s">"The view function did not return a valid"</span> <span class="pl-s">" response. The return type must be a string, dict, tuple,"</span> <span class="pl-s">" Response instance, or WSGI callable, but it was a"</span> <span class="pl-s">" {rv.__class__.__name__}."</span>.<span class="pl-en">format</span>(<span class="pl-s1">rv</span><span class="pl-c1">=</span><span class="pl-s1">rv</span>) )</pre></div> <p dir="auto">Is it intended or just a bug?</p> <h3 dir="auto">Expected</h3> <p dir="auto">When I call <code class="notranslate">127.0.0.1:5000</code>,</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="['it', 'is', 'test']"><pre class="notranslate"><code class="notranslate">['it', 'is', 'test'] </code></pre></div> <h3 dir="auto">Actual</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[2019-07-10 16:36:33,554] ERROR in app: Exception on / [GET] Traceback (most recent call last): File &quot;C:\Users\Mapia\Desktop\develop\study\flask.py\venv\lib\site-packages\flask\app.py&quot;, line 2446, in wsgi_app response = self.full_dispatch_request() File &quot;C:\Users\Mapia\Desktop\develop\study\flask.py\venv\lib\site-packages\flask\app.py&quot;, line 1952, in full_dispatch_request return self.finalize_request(rv) File &quot;C:\Users\Mapia\Desktop\develop\study\flask.py\venv\lib\site-packages\flask\app.py&quot;, line 1967, in finalize_request response = self.make_response(rv) File &quot;C:\Users\Mapia\Desktop\develop\study\flask.py\venv\lib\site-packages\flask\app.py&quot;, line 2130, in make_response &quot; {rv.__class__.__name__}.&quot;.format(rv=rv) TypeError: The view function did not return a valid response. The return type must be a string, dict, tuple, Response instance, or WSGI callable, but it was a list. 127.0.0.1 - - [10/Jul/2019 16:36:33] &quot;GET / HTTP/1.1&quot; 500 -"><pre class="notranslate"><code class="notranslate">[2019-07-10 16:36:33,554] ERROR in app: Exception on / [GET] Traceback (most recent call last): File "C:\Users\Mapia\Desktop\develop\study\flask.py\venv\lib\site-packages\flask\app.py", line 2446, in wsgi_app response = self.full_dispatch_request() File "C:\Users\Mapia\Desktop\develop\study\flask.py\venv\lib\site-packages\flask\app.py", line 1952, in full_dispatch_request return self.finalize_request(rv) File "C:\Users\Mapia\Desktop\develop\study\flask.py\venv\lib\site-packages\flask\app.py", line 1967, in finalize_request response = self.make_response(rv) File "C:\Users\Mapia\Desktop\develop\study\flask.py\venv\lib\site-packages\flask\app.py", line 2130, in make_response " {rv.__class__.__name__}.".format(rv=rv) TypeError: The view function did not return a valid response. The return type must be a string, dict, tuple, Response instance, or WSGI callable, but it was a list. 127.0.0.1 - - [10/Jul/2019 16:36:33] "GET / HTTP/1.1" 500 - </code></pre></div> <h3 dir="auto">Environment</h3> <ul dir="auto"> <li>Python version: 3.7.3</li> <li>Flask version: 1.1.1</li> <li>Werkzeug version: 0.15.4</li> </ul>
<h3 dir="auto">Expected Behavior</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="from flask import Flask app = Flask(__name__) @app.route('/') def issue(): return {'test': 'test'}, {'Content-Type': 'test'}"><pre class="notranslate"><code class="notranslate">from flask import Flask app = Flask(__name__) @app.route('/') def issue(): return {'test': 'test'}, {'Content-Type': 'test'} </code></pre></div> <p dir="auto">Using <code class="notranslate">curl -v http://127.0.0.1:5000/</code> to query the view I expect only one <code class="notranslate">Content-Type</code> header &gt; <code class="notranslate">Content-Type: test</code></p> <h3 dir="auto">Actual Behavior</h3> <p dir="auto">Duplicate headers are returned</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&lt; Content-Type: application/json &lt; Content-Type: test"><pre class="notranslate"><code class="notranslate">&lt; Content-Type: application/json &lt; Content-Type: test </code></pre></div> <h3 dir="auto">Environment</h3> <ul dir="auto"> <li>Python version: 3.8.2</li> <li>Flask version: 1.1.2</li> <li>Werkzeug version: 1.0.1</li> </ul> <h3 dir="auto">Context</h3> <p dir="auto">This issue also effects responses created with make_response when using a dict or jsonify body + the headers argument with a 'Content-Type':</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="from flask import Flask, make_response app = Flask(__name__) @app.route('/') def issue(): return make_response({'test': 'test'}, {'Content-Type': 'test'})"><pre class="notranslate"><code class="notranslate">from flask import Flask, make_response app = Flask(__name__) @app.route('/') def issue(): return make_response({'test': 'test'}, {'Content-Type': 'test'}) </code></pre></div> <p dir="auto">This issue is caused by jsonify adding a 'Content-Type' header then make_response uses <code class="notranslate">extent</code> to add the additional headers, thus leading to the duplicate.</p> <p dir="auto">Returning a str/bytes body does not have this problem as no 'Content-Type' is added by flask, if one is missing it is added by werkzeug.</p> <p dir="auto">The reason I came across this issue is we have older code which does <code class="notranslate">return json.dumps(data), 200, {'Content-Type': 'application/json+somecustomtype'}</code> and I assumed based on the flask docs that just returning the data and letting flask do the jsonify would be better.</p>
0
<ul dir="auto"> <li>Electron version: 1.4.4</li> <li>Operating system: Windows 10 Pro (x64)</li> </ul> <p dir="auto">I created a new BrowserWindow and set set <strong>fullscreen</strong> to <em>true</em> and <strong>show</strong> to <em>false</em>, then I used<br> <code class="notranslate">win.once('ready-to-show', () =&gt; { win.show(); });</code><br> to show the window and window showed as expected<br> however when I tried to set <strong>fullscreen</strong> to <em>false</em> the window turned black and completly unresponsive and I had to end process using task manager.</p> <p dir="auto">setting set <strong>fullscreen</strong> to <em>false</em> and adding <code class="notranslate">win.setFullScreen(true)</code> after <code class="notranslate">win.show();</code> solves the issue.<br> but I would like to avoid the full screen flashing at the start of my application.</p> <h1 dir="auto">main.js</h1> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="const {app, BrowserWindow} = require('electron'); let win function createWindow () { win = new BrowserWindow({fullscreen: true, fullscreenable: true, show: false, width: 1024, height: 768, title: &quot;My Window&quot;, minWidth: 1024, minHeight: 768}) global.mainWin = win; win.setMenuBarVisibility(false); win.once('ready-to-show', () =&gt; { win.show(); }); win.loadURL(`file://${__dirname}/index.html`) win.on('closed', () =&gt; { win = null }) } app.on('ready', createWindow) app.on('window-all-closed', () =&gt; { if (process.platform !== 'darwin') { app.quit() } }) app.on('activate', () =&gt; { if (win === null) { createWindow() } })"><pre class="notranslate"><code class="notranslate">const {app, BrowserWindow} = require('electron'); let win function createWindow () { win = new BrowserWindow({fullscreen: true, fullscreenable: true, show: false, width: 1024, height: 768, title: "My Window", minWidth: 1024, minHeight: 768}) global.mainWin = win; win.setMenuBarVisibility(false); win.once('ready-to-show', () =&gt; { win.show(); }); win.loadURL(`file://${__dirname}/index.html`) win.on('closed', () =&gt; { win = null }) } app.on('ready', createWindow) app.on('window-all-closed', () =&gt; { if (process.platform !== 'darwin') { app.quit() } }) app.on('activate', () =&gt; { if (win === null) { createWindow() } }) </code></pre></div> <h1 dir="auto">index.html</h1> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&lt;html&gt; &lt;head&gt; &lt;meta charset=&quot;UTF-8&quot;&gt; &lt;script src=&quot;main_script.js&quot; charset=&quot;UTF-8&quot;&gt; &lt;/script&gt; &lt;link rel=&quot;stylesheet&quot; href=&quot;main_style.css&quot;&gt; &lt;/head&gt; &lt;body&gt; &lt;div class=&quot;container&quot;&gt; &lt;input type=&quot;button&quot; class=&quot;mainmenu&quot; value=&quot;Toggle Fullscreen&quot; onClick=&quot;FSToggle();&quot;/&gt; &lt;/div&gt; &lt;/body&gt; &lt;/html&gt;"><pre class="notranslate"><code class="notranslate">&lt;html&gt; &lt;head&gt; &lt;meta charset="UTF-8"&gt; &lt;script src="main_script.js" charset="UTF-8"&gt; &lt;/script&gt; &lt;link rel="stylesheet" href="main_style.css"&gt; &lt;/head&gt; &lt;body&gt; &lt;div class="container"&gt; &lt;input type="button" class="mainmenu" value="Toggle Fullscreen" onClick="FSToggle();"/&gt; &lt;/div&gt; &lt;/body&gt; &lt;/html&gt; </code></pre></div> <h1 dir="auto">main_script.js</h1> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="const remote = require('electron').remote; const win = remote.getGlobal('mainWin'); function FSToggle(){ win.setFullScreen(!win.isFullScreen()); }"><pre class="notranslate"><code class="notranslate">const remote = require('electron').remote; const win = remote.getGlobal('mainWin'); function FSToggle(){ win.setFullScreen(!win.isFullScreen()); } </code></pre></div>
<ul dir="auto"> <li>Electron version: 1.2.0, 1.2.1, 1.2.2</li> <li>Operating system: Windows</li> </ul> <p dir="auto">If you start an browser window in fullscreen and then attempt to toggle to windowed mode, the window will just black out and become unresponsive. Attempting to toggle back again still results in a black screen.</p> <p dir="auto">However, if you start the window in windowed mode and then toggle to fullscreen, it works as expected.</p> <p dir="auto">This maybe related to the fixes made to the fullscreen API in 1.2.x. It only occurs on Windows. It does not happen on 1.1.3.</p> <p dir="auto">You can reproduce easily with the <code class="notranslate">electron-api-demos</code> application and 1.2.2.<br> <a href="https://github.com/electron/electron-api-demos">https://github.com/electron/electron-api-demos</a></p> <p dir="auto">Update <code class="notranslate">window-options</code> to set <code class="notranslate">fullscreen: true</code><br> <a href="https://github.com/electron/electron-api-demos/blob/master/main.js#L22">https://github.com/electron/electron-api-demos/blob/master/main.js#L22</a></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="var windowOptions = { width: 1080, minWidth: 680, height: 840, title: app.getName(), fullscreen: true }"><pre class="notranslate"><code class="notranslate">var windowOptions = { width: 1080, minWidth: 680, height: 840, title: app.getName(), fullscreen: true } </code></pre></div> <p dir="auto">Start the application and hit F11 to switch to windowed mode and you'll get a black screen.</p>
1
<p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/18854/5889758/9862095e-a3eb-11e4-8ce3-9dae4e61bc69.gif"><img src="https://cloud.githubusercontent.com/assets/18854/5889758/9862095e-a3eb-11e4-8ce3-9dae4e61bc69.gif" alt="graphical issue" data-animated-image="" style="max-width: 100%;"></a><br> So as you can see, there are some double printing artifacts here. I didn't see them happen, but noticed them after switching to another application. I'm running a recent OSX (10.10.1) and just installed Atom today from binary (Version 0.175.0 (0.175.0)).</p> <p dir="auto">Pretty cool editor; I look forward to using it.</p>
<p dir="auto">Most noticeable in the tree view, resizing it, scrolling, etc. makes it redraw and go away.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/671378/5666877/fe272bc4-9717-11e4-9d81-c6f737e03def.png"><img src="https://cloud.githubusercontent.com/assets/671378/5666877/fe272bc4-9717-11e4-9d81-c6f737e03def.png" alt="screen shot 2015-01-07 at 2 47 31 pm" style="max-width: 100%;"></a></p> <p dir="auto">/cc <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/zcbenz/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/zcbenz">@zcbenz</a> Any ideas on this one?</p>
1
<p dir="auto">Describe what you were doing when the bug occurred:<br> 1.<br> 2.<br> 3.</p> <hr> <h2 dir="auto">Please do not remove the text below this line</h2> <p dir="auto">DevTools version: 4.10.1-f160547f47</p> <p dir="auto">Call stack: at store_Store.getElementAtIndex (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:21226:35)<br> at store_Store.getElementIDAtIndex (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:21242:26)<br> at chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:28678:63<br> at List.render (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:22934:18)<br> at vi (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:13515:76)<br> at ui (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:13506:10)<br> at mk (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:16077:86)<br> at lk (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:15459:11)<br> at kk (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:15451:23)<br> at ck (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:15435:5)</p> <p dir="auto">Component stack: at List (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:22629:30)<br> at div<br> at AutoSizer (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:3003:5)<br> at div<br> at div<br> at Tree_Tree (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:28429:47)<br> at div<br> at div<br> at InspectedElementContextController (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:28921:3)<br> at OwnersListContextController (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:27558:3)<br> at SettingsModalContextController (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:28206:3)<br> at Components_Components (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:33383:52)<br> at ErrorBoundary_ErrorBoundary (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:29219:5)<br> at PortaledContent (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:29336:32)<br> at div<br> at div<br> at ProfilerContextController (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:32934:3)<br> at TreeContextController (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:24322:3)<br> at SettingsContextController (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:24811:3)<br> at ModalDialogContextController (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:29404:3)<br> at DevTools_DevTools (chrome-extension://fmkadmapgofadopljbjfkapdkoienihi/build/main.js:36207:3)</p>
<p dir="auto">I would also like to propose that following potentially improvements for speed and simplicity now that useState is there.</p> <p dir="auto">I would like to propose the following variants, which introduce a modstamp and a setItem for state that contains list of items.<br> Instead of having to destructor arrays and objects and things to cause reference changes, which is havey,<br> setItem would implicit tick the mostamp for an item in an array and the modstamp if required at array container level.<br> There would be alot less overhead in my mind to this approach that to setItem([...this.array]), causing new references to be created in the back ground, such that there is a reference change detected, such that item re-renders.<br> if one wants to do a bulk update with more than a single item then setContent(this.array), which implicit, tick the mostamp.</p> <p dir="auto">This would simplify things, because everything is basically reduce to a primative comparison or modstamp and no doesn't need to write deep ShouldComponentUpdate comparison anymore, as been take into account by useState.</p> <p dir="auto">I think it is quite straint forward, obviously there would be all the logic in the background wrapping useState or using symbol and inject directly into an object. One just needs a GetContent the with out a modstamp for hitting API's.</p> <p dir="auto">Typically this is just a concept, the function names and useState variants don't have to follow everything word for word names and that are menings less, its basically behavior, simplification that one is looking for, weather is with effects or which every.</p> <p dir="auto">Typically UseState approach is much nicer, when having to setup, things, where on is linking into to nested structures of this.state, because updating them requires destructing of parent properties, such that they not lost.</p> <p dir="auto"><strong>Continuous Scroll</strong><br> In addition to this one also is there required the ability to not tick the timestamp when setContent is used, because when you working with controls where the is a data provide for like FlatList or things like that, where only UI items for screens space, while all data is not converted into controls, only the section for display. Typiclaly the documentation with regards to react-native is not correctly in how to use js for continuous scroll, as par last docs I read, cause full re-renders instead appends, for data off screen. Depends on weather you have a full screen of items or less basically. Basically flatList could also detect not just reference change, but array exceeding being below the minimum number of row Items that would cover the screen. if is an append, well change is ignored. If update, then mostamps would have change for the person.</p> <p dir="auto"><strong>CRUD system of changes</strong><br> Basically you could also implement Create/Update/Delete item delta caching in the back ground for aggregation, which what I ultimate wanted to do in missive cad system, to reduce UI re-draw. I this case just before render, deltas are then merge before GetDerivedStateFromProps and render would be called.</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" const modStamp = Symbol('modstamp'); enum UseStateType { Primative, ArrayObject, Object } // Different function names could be used as well. useState(type: UseStateType, initialcontent: TLookUpValueType, setMethod?: (value: TLookUpValueType) =&gt; void)) : any useState(UseStateType.Primative, initialcontent: TLookUpValueType, setMethod?: (value: TLookUpValueType) =&gt; void)) : [ setContent, getContent] useState(UseStateType.ArrayObject, initialcontent: TLookUpValueType, setMethod? :(value: TLookUpValueType) =&gt; void)) : [ setContent, setItem, ,getContent, getModStamp, tickModStamp] useState(UseStateType.Object, initialcontent: TLookUpValueType, setMethod? :(value: TLookUpValueType) =&gt; void)) : [ setContent, setItem, ,getContent, getModStamp, tickModStamp] { const setItem = (pos, item) =&gt; { item[modStamp] = (this.state.array[pos][modStamp] || 0)++; this.state.array[pos] = item; } return [.., setItem, .. , ..]; } render () { return &lt;React.Fragment&gt; this.state.map(it =&gt; &lt;Item key={it.key} modStamp={it.modStamp} value={it}&gt; &lt;/React.Fragment&gt; } "><pre class="notranslate"><span class="pl-k">const</span> <span class="pl-s1">modStamp</span> <span class="pl-c1">=</span> <span class="pl-smi">Symbol</span><span class="pl-kos">(</span><span class="pl-s">'modstamp'</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">enum</span> <span class="pl-smi">UseStateType</span> <span class="pl-kos">{</span> <span class="pl-c1">Primative</span><span class="pl-kos">,</span> <span class="pl-c1">ArrayObject</span><span class="pl-kos">,</span> <span class="pl-c1">Object</span> <span class="pl-kos">}</span> <span class="pl-c">// Different function names could be used as well.</span> <span class="pl-en">useState</span><span class="pl-kos">(</span><span class="pl-s1">type</span>: <span class="pl-smi">UseStateType</span><span class="pl-kos">,</span> <span class="pl-s1">initialcontent</span>: <span class="pl-smi">TLookUpValueType</span><span class="pl-kos">,</span> <span class="pl-en">setMethod</span>?: <span class="pl-kos">(</span><span class="pl-s1">value</span>: <span class="pl-smi">TLookUpValueType</span><span class="pl-kos">)</span> <span class="pl-c1">=</span><span class="pl-c1">&gt;</span> <span class="pl-k">void</span><span class="pl-kos">)</span><span class="pl-kos">)</span> : <span class="pl-s1">any</span> <span class="pl-en">useState</span><span class="pl-kos">(</span><span class="pl-smi">UseStateType</span><span class="pl-kos">.</span><span class="pl-c1">Primative</span><span class="pl-kos">,</span> <span class="pl-s1">initialcontent</span>: <span class="pl-smi">TLookUpValueType</span><span class="pl-kos">,</span> <span class="pl-en">setMethod</span>?: <span class="pl-kos">(</span><span class="pl-s1">value</span>: <span class="pl-smi">TLookUpValueType</span><span class="pl-kos">)</span> <span class="pl-c1">=</span><span class="pl-c1">&gt;</span> <span class="pl-k">void</span><span class="pl-kos">)</span><span class="pl-kos">)</span> : <span class="pl-kos">[</span> <span class="pl-s1">setContent</span><span class="pl-kos">,</span> <span class="pl-s1">getContent</span><span class="pl-kos">]</span> <span class="pl-en">useState</span><span class="pl-kos">(</span><span class="pl-smi">UseStateType</span><span class="pl-kos">.</span><span class="pl-c1">ArrayObject</span><span class="pl-kos">,</span> <span class="pl-s1">initialcontent</span>: <span class="pl-smi">TLookUpValueType</span><span class="pl-kos">,</span> <span class="pl-en">setMethod</span>? :<span class="pl-kos">(</span><span class="pl-s1">value</span>: <span class="pl-smi">TLookUpValueType</span><span class="pl-kos">)</span> <span class="pl-c1">=</span><span class="pl-c1">&gt;</span> <span class="pl-k">void</span><span class="pl-kos">)</span><span class="pl-kos">)</span> : <span class="pl-kos">[</span> <span class="pl-s1">setContent</span><span class="pl-kos">,</span> <span class="pl-s1">setItem</span><span class="pl-kos">,</span> <span class="pl-kos">,</span><span class="pl-s1">getContent</span><span class="pl-kos">,</span> <span class="pl-s1">getModStamp</span><span class="pl-kos">,</span> <span class="pl-s1">tickModStamp</span><span class="pl-kos">]</span> <span class="pl-en">useState</span><span class="pl-kos">(</span><span class="pl-smi">UseStateType</span><span class="pl-kos">.</span><span class="pl-c1">Object</span><span class="pl-kos">,</span> <span class="pl-s1">initialcontent</span>: <span class="pl-smi">TLookUpValueType</span><span class="pl-kos">,</span> <span class="pl-en">setMethod</span>? :<span class="pl-kos">(</span><span class="pl-s1">value</span>: <span class="pl-smi">TLookUpValueType</span><span class="pl-kos">)</span> <span class="pl-c1">=</span><span class="pl-c1">&gt;</span> <span class="pl-k">void</span><span class="pl-kos">)</span><span class="pl-kos">)</span> : <span class="pl-kos">[</span> <span class="pl-s1">setContent</span><span class="pl-kos">,</span> <span class="pl-s1">setItem</span><span class="pl-kos">,</span> <span class="pl-kos">,</span><span class="pl-s1">getContent</span><span class="pl-kos">,</span> <span class="pl-s1">getModStamp</span><span class="pl-kos">,</span> <span class="pl-s1">tickModStamp</span><span class="pl-kos">]</span><span class="pl-kos"></span> <span class="pl-kos">{</span> <span class="pl-k">const</span> <span class="pl-en">setItem</span> <span class="pl-c1">=</span> <span class="pl-kos">(</span><span class="pl-s1">pos</span><span class="pl-kos">,</span> <span class="pl-s1">item</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-s1">item</span><span class="pl-kos">[</span><span class="pl-s1">modStamp</span><span class="pl-kos">]</span> <span class="pl-c1">=</span> <span class="pl-kos">(</span><span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">state</span><span class="pl-kos">.</span><span class="pl-c1">array</span><span class="pl-kos">[</span><span class="pl-s1">pos</span><span class="pl-kos">]</span><span class="pl-kos">[</span><span class="pl-s1">modStamp</span><span class="pl-kos">]</span> <span class="pl-c1">||</span> <span class="pl-c1">0</span><span class="pl-kos">)</span><span class="pl-c1">++</span><span class="pl-kos">;</span> <span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">state</span><span class="pl-kos">.</span><span class="pl-c1">array</span><span class="pl-kos">[</span><span class="pl-s1">pos</span><span class="pl-kos">]</span> <span class="pl-c1">=</span> <span class="pl-s1">item</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-k">return</span> <span class="pl-kos">[</span><span class="pl-kos">.</span><span class="pl-kos">.</span><span class="pl-kos">,</span> <span class="pl-s1">setItem</span><span class="pl-kos">,</span> <span class="pl-kos">.</span><span class="pl-kos">.</span> <span class="pl-kos">,</span> <span class="pl-kos">.</span><span class="pl-kos">.</span><span class="pl-kos">]</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-en">render</span> <span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos"></span> <span class="pl-kos">{</span> <span class="pl-k">return</span> <span class="pl-kos">&lt;</span><span class="pl-smi">React</span><span class="pl-kos">.</span><span class="pl-smi">Fragment</span><span class="pl-kos">&gt;</span> <span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">state</span><span class="pl-kos">.</span><span class="pl-c1">map</span><span class="pl-kos">(</span><span class="pl-s1">it</span> <span class="pl-c1">=&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-smi">Item</span> <span class="pl-s1">key</span><span class="pl-c1">=</span><span class="pl-kos">{</span><span class="pl-c1">it</span><span class="pl-kos">.</span><span class="pl-c1">key</span><span class="pl-kos">}</span> <span class="pl-s1">modStamp</span><span class="pl-c1">=</span><span class="pl-kos">{</span><span class="pl-s1">it</span><span class="pl-kos">.</span><span class="pl-smi">modStamp</span><span class="pl-kos">}</span> <span class="pl-smi">value</span><span class="pl-c1">=</span><span class="pl-kos">{</span><span class="pl-c1">it</span><span class="pl-kos">}</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-c1">/</span><span class="pl-smi">React</span><span class="pl-kos">.</span><span class="pl-c1">Fragment</span><span class="pl-c1">&gt;</span> <span class="pl-kos">}</span></pre></div>
0
<ul dir="auto"> <li>[*] I have searched the <a href="https://github.com/apache/dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li> <li>[*] I have checked the <a href="https://github.com/apache/dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li> </ul> <h3 dir="auto">Environment</h3> <ul dir="auto"> <li>Dubbo version: 2.7.5-SNAPSHOT</li> <li>Dubbo branch: master</li> <li>Operating System version: macOS Catalina</li> <li>Java version: jdk-11.0.5.jdk</li> </ul> <h3 dir="auto">Steps to reproduce this issue</h3> <ol dir="auto"> <li>start zookeeper localhost</li> <li>write code consumer-side, like this</li> </ol> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" public class ConsumerApplication { private static String zookeeperHost = System.getProperty(&quot;zookeeper.address&quot;, &quot;127.0.0.1&quot;); public static void main(String[] args) { ReferenceConfig&lt;DemoService&gt; reference = new ReferenceConfig&lt;&gt;(); reference.setApplication(new ApplicationConfig(&quot;first-dubbo-consumer&quot;)); reference.setRegistry(new RegistryConfig(&quot;zookeeper://&quot; + zookeeperHost + &quot;:2181&quot;)); reference.setInterface(DemoService.class); DemoService service = reference.get(); String message = service.sayHello(&quot;dubbo&quot;); System.out.println(message); } } "><pre class="notranslate"> <span class="pl-k">public</span> <span class="pl-k">class</span> <span class="pl-smi">ConsumerApplication</span> { <span class="pl-k">private</span> <span class="pl-k">static</span> <span class="pl-smi">String</span> <span class="pl-s1">zookeeperHost</span> = <span class="pl-smi">System</span>.<span class="pl-en">getProperty</span>(<span class="pl-s">"zookeeper.address"</span>, <span class="pl-s">"127.0.0.1"</span>); <span class="pl-k">public</span> <span class="pl-k">static</span> <span class="pl-smi">void</span> <span class="pl-en">main</span>(<span class="pl-smi">String</span>[] <span class="pl-s1">args</span>) { <span class="pl-smi">ReferenceConfig</span>&lt;<span class="pl-smi">DemoService</span>&gt; <span class="pl-s1">reference</span> = <span class="pl-k">new</span> <span class="pl-smi">ReferenceConfig</span>&lt;&gt;(); <span class="pl-s1">reference</span>.<span class="pl-en">setApplication</span>(<span class="pl-k">new</span> <span class="pl-smi">ApplicationConfig</span>(<span class="pl-s">"first-dubbo-consumer"</span>)); <span class="pl-s1">reference</span>.<span class="pl-en">setRegistry</span>(<span class="pl-k">new</span> <span class="pl-smi">RegistryConfig</span>(<span class="pl-s">"zookeeper://"</span> + <span class="pl-s1">zookeeperHost</span> + <span class="pl-s">":2181"</span>)); <span class="pl-s1">reference</span>.<span class="pl-en">setInterface</span>(<span class="pl-smi">DemoService</span>.<span class="pl-k">class</span>); <span class="pl-smi">DemoService</span> <span class="pl-s1">service</span> = <span class="pl-s1">reference</span>.<span class="pl-en">get</span>(); <span class="pl-smi">String</span> <span class="pl-s1">message</span> = <span class="pl-s1">service</span>.<span class="pl-en">sayHello</span>(<span class="pl-s">"dubbo"</span>); <span class="pl-smi">System</span>.<span class="pl-s1">out</span>.<span class="pl-en">println</span>(<span class="pl-s1">message</span>); } }</pre></div> <ol start="3" dir="auto"> <li>write code provider-side like this</li> </ol> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="public class Application { private static String zookeeperHost = System.getProperty(&quot;zookeeper.address&quot;, &quot;127.0.0.1&quot;); public static void main(String[] args) throws Exception { ServiceConfig&lt;DemoService&gt; service = new ServiceConfig&lt;DemoService&gt;(); service.setApplication(new ApplicationConfig(&quot;first-dubbo-provider&quot;)); service.setRegistry(new RegistryConfig(&quot;zookeeper://&quot; + zookeeperHost + &quot;:2181&quot;)); service.setInterface(DemoService.class); service.setRef(new DemoServiceImpl()); service.setParameters(new HashMap&lt;&gt;()); service.export(); System.out.println(&quot;dubbo service started&quot;); new CountDownLatch(1).await(); } }"><pre class="notranslate"><span class="pl-k">public</span> <span class="pl-k">class</span> <span class="pl-smi">Application</span> { <span class="pl-k">private</span> <span class="pl-k">static</span> <span class="pl-smi">String</span> <span class="pl-s1">zookeeperHost</span> = <span class="pl-smi">System</span>.<span class="pl-en">getProperty</span>(<span class="pl-s">"zookeeper.address"</span>, <span class="pl-s">"127.0.0.1"</span>); <span class="pl-k">public</span> <span class="pl-k">static</span> <span class="pl-smi">void</span> <span class="pl-en">main</span>(<span class="pl-smi">String</span>[] <span class="pl-s1">args</span>) <span class="pl-k">throws</span> <span class="pl-smi">Exception</span> { <span class="pl-smi">ServiceConfig</span>&lt;<span class="pl-smi">DemoService</span>&gt; <span class="pl-s1">service</span> = <span class="pl-k">new</span> <span class="pl-smi">ServiceConfig</span>&lt;<span class="pl-smi">DemoService</span>&gt;(); <span class="pl-s1">service</span>.<span class="pl-en">setApplication</span>(<span class="pl-k">new</span> <span class="pl-smi">ApplicationConfig</span>(<span class="pl-s">"first-dubbo-provider"</span>)); <span class="pl-s1">service</span>.<span class="pl-en">setRegistry</span>(<span class="pl-k">new</span> <span class="pl-smi">RegistryConfig</span>(<span class="pl-s">"zookeeper://"</span> + <span class="pl-s1">zookeeperHost</span> + <span class="pl-s">":2181"</span>)); <span class="pl-s1">service</span>.<span class="pl-en">setInterface</span>(<span class="pl-smi">DemoService</span>.<span class="pl-k">class</span>); <span class="pl-s1">service</span>.<span class="pl-en">setRef</span>(<span class="pl-k">new</span> <span class="pl-smi">DemoServiceImpl</span>()); <span class="pl-s1">service</span>.<span class="pl-en">setParameters</span>(<span class="pl-k">new</span> <span class="pl-smi">HashMap</span>&lt;&gt;()); <span class="pl-s1">service</span>.<span class="pl-en">export</span>(); <span class="pl-smi">System</span>.<span class="pl-s1">out</span>.<span class="pl-en">println</span>(<span class="pl-s">"dubbo service started"</span>); <span class="pl-k">new</span> <span class="pl-smi">CountDownLatch</span>(<span class="pl-c1">1</span>).<span class="pl-en">await</span>(); } }</pre></div> <ol start="4" dir="auto"> <li>serviceImpl code like this</li> </ol> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="@Service(version = &quot;1.0.0&quot;,timeout = 9000) public class DemoServiceImpl implements DemoService { @Override public String sayHello(String name) { try{ Thread.sleep(7000); }catch (Exception ex){ } return &quot;Hello, &quot; + name + &quot;, &quot; + new Date(); } }"><pre class="notranslate"><code class="notranslate">@Service(version = "1.0.0",timeout = 9000) public class DemoServiceImpl implements DemoService { @Override public String sayHello(String name) { try{ Thread.sleep(7000); }catch (Exception ex){ } return "Hello, " + name + ", " + new Date(); } } </code></pre></div> <p dir="auto">You can find that the TIMEOUT is 9000, but I got an Exception and it tells me the TIMEOUT is 1000.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Exception in thread &quot;main&quot; org.apache.dubbo.rpc.RpcException: Failed to invoke the method sayHello in the service com.example.studydubboApi.DemoService. Tried 3 times of the providers [192.168.1.5:20880] (1/1) from the registry 127.0.0.1:2181 on the consumer 192.168.1.5 using the dubbo version 2.7.5-SNAPSHOT. Last error is: Invoke remote method timeout. method: sayHello, provider: dubbo://192.168.1.5:20880/com.example.studydubboApi.DemoService?anyhost=true&amp;application=first-dubbo-consumer&amp;check=false&amp;deprecated=false&amp;dubbo=2.0.2&amp;dynamic=true&amp;generic=false&amp;interface=com.example.studydubboApi.DemoService&amp;lazy=false&amp;methods=sayHello&amp;pid=20243&amp;register.ip=192.168.1.5&amp;release=2.7.5-SNAPSHOT&amp;remote.application=first-dubbo-provider&amp;side=consumer&amp;sticky=false&amp;timestamp=1571837759756, cause: org.apache.dubbo.remoting.TimeoutException: Waiting server-side response timeout by scan timer. start time: 2019-10-23 21:39:46.800, end time: 2019-10-23 21:39:47.825, client elapsed: 5 ms, server elapsed: 1018 ms, timeout: 1000 ms, request: Request [id=2, version=2.0.2, twoway=true, event=false, broken=false, data=RpcInvocation [methodName=sayHello, parameterTypes=[class java.lang.String], arguments=[dubbo], attachments={path=com.example.studydubboApi.DemoService, remote.application=first-dubbo-consumer, interface=com.example.studydubboApi.DemoService, version=0.0.0}]], channel: /192.168.1.5:56619 -&gt; /192.168.1.5:20880 at org.apache.dubbo.rpc.cluster.support.FailoverClusterInvoker.doInvoke(FailoverClusterInvoker.java:113) at org.apache.dubbo.rpc.cluster.support.AbstractClusterInvoker.invoke(AbstractClusterInvoker.java:248) at org.apache.dubbo.rpc.cluster.support.wrapper.MockClusterInvoker.invoke(MockClusterInvoker.java:78) at org.apache.dubbo.rpc.proxy.InvokerInvocationHandler.invoke(InvokerInvocationHandler.java:55) at org.apache.dubbo.common.bytecode.proxy0.sayHello(proxy0.java) at com.example.studydubboconsumer.ConsumerApplication.main(ConsumerApplication.java:20) Caused by: java.util.concurrent.ExecutionException: org.apache.dubbo.remoting.TimeoutException: Waiting server-side response timeout by scan timer. start time: 2019-10-23 21:39:46.800, end time: 2019-10-23 21:39:47.825, client elapsed: 5 ms, server elapsed: 1018 ms, timeout: 1000 ms, request: Request [id=2, version=2.0.2, twoway=true, event=false, broken=false, data=RpcInvocation [methodName=sayHello, parameterTypes=[class java.lang.String], arguments=[dubbo], attachments={path=com.example.studydubboApi.DemoService, remote.application=first-dubbo-consumer, interface=com.example.studydubboApi.DemoService, version=0.0.0}]], channel: /192.168.1.5:56619 -&gt; /192.168.1.5:20880 at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:395) at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2022) at org.apache.dubbo.rpc.protocol.AsyncToSyncInvoker.invoke(AsyncToSyncInvoker.java:56) at org.apache.dubbo.rpc.listener.ListenerInvokerWrapper.invoke(ListenerInvokerWrapper.java:78) at org.apache.dubbo.monitor.support.MonitorFilter.invoke(MonitorFilter.java:92) at org.apache.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:82) at org.apache.dubbo.rpc.protocol.dubbo.filter.FutureFilter.invoke(FutureFilter.java:54) at org.apache.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:82) at org.apache.dubbo.rpc.filter.ConsumerContextFilter.invoke(ConsumerContextFilter.java:60) at org.apache.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:82) at org.apache.dubbo.rpc.protocol.ProtocolFilterWrapper$CallbackRegistrationInvoker.invoke(ProtocolFilterWrapper.java:157) at org.apache.dubbo.rpc.protocol.InvokerWrapper.invoke(InvokerWrapper.java:56) at org.apache.dubbo.rpc.cluster.support.FailoverClusterInvoker.doInvoke(FailoverClusterInvoker.java:82) ... 5 more Caused by: org.apache.dubbo.remoting.TimeoutException: Waiting server-side response timeout by scan timer. start time: 2019-10-23 21:39:46.800, end time: 2019-10-23 21:39:47.825, client elapsed: 5 ms, server elapsed: 1018 ms, timeout: 1000 ms, request: Request [id=2, version=2.0.2, twoway=true, event=false, broken=false, data=RpcInvocation [methodName=sayHello, parameterTypes=[class java.lang.String], arguments=[dubbo], attachments={path=com.example.studydubboApi.DemoService, remote.application=first-dubbo-consumer, interface=com.example.studydubboApi.DemoService, version=0.0.0}]], channel: /192.168.1.5:56619 -&gt; /192.168.1.5:20880 at org.apache.dubbo.remoting.exchange.support.DefaultFuture.doReceived(DefaultFuture.java:189) at org.apache.dubbo.remoting.exchange.support.DefaultFuture.received(DefaultFuture.java:153) at org.apache.dubbo.remoting.exchange.support.DefaultFuture$TimeoutCheckTask.run(DefaultFuture.java:258) at org.apache.dubbo.common.timer.HashedWheelTimer$HashedWheelTimeout.expire(HashedWheelTimer.java:648) at org.apache.dubbo.common.timer.HashedWheelTimer$HashedWheelBucket.expireTimeouts(HashedWheelTimer.java:727) at org.apache.dubbo.common.timer.HashedWheelTimer$Worker.run(HashedWheelTimer.java:449) at java.base/java.lang.Thread.run(Thread.java:834)"><pre class="notranslate"><code class="notranslate">Exception in thread "main" org.apache.dubbo.rpc.RpcException: Failed to invoke the method sayHello in the service com.example.studydubboApi.DemoService. Tried 3 times of the providers [192.168.1.5:20880] (1/1) from the registry 127.0.0.1:2181 on the consumer 192.168.1.5 using the dubbo version 2.7.5-SNAPSHOT. Last error is: Invoke remote method timeout. method: sayHello, provider: dubbo://192.168.1.5:20880/com.example.studydubboApi.DemoService?anyhost=true&amp;application=first-dubbo-consumer&amp;check=false&amp;deprecated=false&amp;dubbo=2.0.2&amp;dynamic=true&amp;generic=false&amp;interface=com.example.studydubboApi.DemoService&amp;lazy=false&amp;methods=sayHello&amp;pid=20243&amp;register.ip=192.168.1.5&amp;release=2.7.5-SNAPSHOT&amp;remote.application=first-dubbo-provider&amp;side=consumer&amp;sticky=false&amp;timestamp=1571837759756, cause: org.apache.dubbo.remoting.TimeoutException: Waiting server-side response timeout by scan timer. start time: 2019-10-23 21:39:46.800, end time: 2019-10-23 21:39:47.825, client elapsed: 5 ms, server elapsed: 1018 ms, timeout: 1000 ms, request: Request [id=2, version=2.0.2, twoway=true, event=false, broken=false, data=RpcInvocation [methodName=sayHello, parameterTypes=[class java.lang.String], arguments=[dubbo], attachments={path=com.example.studydubboApi.DemoService, remote.application=first-dubbo-consumer, interface=com.example.studydubboApi.DemoService, version=0.0.0}]], channel: /192.168.1.5:56619 -&gt; /192.168.1.5:20880 at org.apache.dubbo.rpc.cluster.support.FailoverClusterInvoker.doInvoke(FailoverClusterInvoker.java:113) at org.apache.dubbo.rpc.cluster.support.AbstractClusterInvoker.invoke(AbstractClusterInvoker.java:248) at org.apache.dubbo.rpc.cluster.support.wrapper.MockClusterInvoker.invoke(MockClusterInvoker.java:78) at org.apache.dubbo.rpc.proxy.InvokerInvocationHandler.invoke(InvokerInvocationHandler.java:55) at org.apache.dubbo.common.bytecode.proxy0.sayHello(proxy0.java) at com.example.studydubboconsumer.ConsumerApplication.main(ConsumerApplication.java:20) Caused by: java.util.concurrent.ExecutionException: org.apache.dubbo.remoting.TimeoutException: Waiting server-side response timeout by scan timer. start time: 2019-10-23 21:39:46.800, end time: 2019-10-23 21:39:47.825, client elapsed: 5 ms, server elapsed: 1018 ms, timeout: 1000 ms, request: Request [id=2, version=2.0.2, twoway=true, event=false, broken=false, data=RpcInvocation [methodName=sayHello, parameterTypes=[class java.lang.String], arguments=[dubbo], attachments={path=com.example.studydubboApi.DemoService, remote.application=first-dubbo-consumer, interface=com.example.studydubboApi.DemoService, version=0.0.0}]], channel: /192.168.1.5:56619 -&gt; /192.168.1.5:20880 at java.base/java.util.concurrent.CompletableFuture.reportGet(CompletableFuture.java:395) at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2022) at org.apache.dubbo.rpc.protocol.AsyncToSyncInvoker.invoke(AsyncToSyncInvoker.java:56) at org.apache.dubbo.rpc.listener.ListenerInvokerWrapper.invoke(ListenerInvokerWrapper.java:78) at org.apache.dubbo.monitor.support.MonitorFilter.invoke(MonitorFilter.java:92) at org.apache.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:82) at org.apache.dubbo.rpc.protocol.dubbo.filter.FutureFilter.invoke(FutureFilter.java:54) at org.apache.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:82) at org.apache.dubbo.rpc.filter.ConsumerContextFilter.invoke(ConsumerContextFilter.java:60) at org.apache.dubbo.rpc.protocol.ProtocolFilterWrapper$1.invoke(ProtocolFilterWrapper.java:82) at org.apache.dubbo.rpc.protocol.ProtocolFilterWrapper$CallbackRegistrationInvoker.invoke(ProtocolFilterWrapper.java:157) at org.apache.dubbo.rpc.protocol.InvokerWrapper.invoke(InvokerWrapper.java:56) at org.apache.dubbo.rpc.cluster.support.FailoverClusterInvoker.doInvoke(FailoverClusterInvoker.java:82) ... 5 more Caused by: org.apache.dubbo.remoting.TimeoutException: Waiting server-side response timeout by scan timer. start time: 2019-10-23 21:39:46.800, end time: 2019-10-23 21:39:47.825, client elapsed: 5 ms, server elapsed: 1018 ms, timeout: 1000 ms, request: Request [id=2, version=2.0.2, twoway=true, event=false, broken=false, data=RpcInvocation [methodName=sayHello, parameterTypes=[class java.lang.String], arguments=[dubbo], attachments={path=com.example.studydubboApi.DemoService, remote.application=first-dubbo-consumer, interface=com.example.studydubboApi.DemoService, version=0.0.0}]], channel: /192.168.1.5:56619 -&gt; /192.168.1.5:20880 at org.apache.dubbo.remoting.exchange.support.DefaultFuture.doReceived(DefaultFuture.java:189) at org.apache.dubbo.remoting.exchange.support.DefaultFuture.received(DefaultFuture.java:153) at org.apache.dubbo.remoting.exchange.support.DefaultFuture$TimeoutCheckTask.run(DefaultFuture.java:258) at org.apache.dubbo.common.timer.HashedWheelTimer$HashedWheelTimeout.expire(HashedWheelTimer.java:648) at org.apache.dubbo.common.timer.HashedWheelTimer$HashedWheelBucket.expireTimeouts(HashedWheelTimer.java:727) at org.apache.dubbo.common.timer.HashedWheelTimer$Worker.run(HashedWheelTimer.java:449) at java.base/java.lang.Thread.run(Thread.java:834) </code></pre></div> <p dir="auto">Is it an issue?</p>
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/apache/dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the <a href="https://github.com/apache/dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li> </ul> <h3 dir="auto">Environment</h3> <ul dir="auto"> <li>Dubbo version: master</li> <li>Operating System version: mac os 10.14.3</li> <li>Java version: 1.8.0_201</li> </ul> <h3 dir="auto">Steps to reproduce this issue</h3> <ol dir="auto"> <li>use StringUtils.isNotEmpty(id) instead of id != null &amp;&amp; id.length() in DubboBeanDefinitionParser.JAVA at line 97</li> </ol> <p dir="auto">What do you expected from the above steps?<br> make code clear and unity as other StringUtils method used in this class</p>
0
<h5 dir="auto">ISSUE TYPE</h5> <p dir="auto">Bug Report</p> <h5 dir="auto">COMPONENT NAME</h5> <p dir="auto">core</p> <h5 dir="auto">ANSIBLE VERSION</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ansible 2.0.0.2 (stable-2.0.0.1 3b5d7400de) last updated 2016/04/14 085854 (GMT -500) lib/ansible/modules/core (detached HEAD ce6619bf5d) last updated 2016/04/14 090423 (GMT -500) lib/ansible/modules/extras (detached HEAD 29af26884e) last updated 2016/04/14 090506 (GMT -500) config file = /root/ansible/ansible.cfg configured module search path = Default w/o overrides"><pre class="notranslate"><code class="notranslate">ansible 2.0.0.2 (stable-2.0.0.1 3b5d7400de) last updated 2016/04/14 085854 (GMT -500) lib/ansible/modules/core (detached HEAD ce6619bf5d) last updated 2016/04/14 090423 (GMT -500) lib/ansible/modules/extras (detached HEAD 29af26884e) last updated 2016/04/14 090506 (GMT -500) config file = /root/ansible/ansible.cfg configured module search path = Default w/o overrides </code></pre></div> <h5 dir="auto">CONFIGURATION</h5> <h5 dir="auto">OS / ENVIRONMENT</h5> <p dir="auto">N/A</p> <h5 dir="auto">SUMMARY</h5> <p dir="auto">Getting error shown below when trying to change user permissions using win_acl<br> TASK [role1 : set permissions for IIS_IUSRS] *************************<br> fatal: [hostMachine]: FAILED! =&gt; {"changed": false, "failed": true, "msg": "an exception occured when adding the specified rule"}</p> <h5 dir="auto">STEPS TO REPRODUCE</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="roles/role1/tasks/main.yml --- - name: set permissions for IIS-IUSRS win_acl: path=&quot;C:\\Users\\James\\Desktop\temp&quot; user='IIS_IUSRS' rights='Read' type=allow state=present"><pre class="notranslate"><code class="notranslate">roles/role1/tasks/main.yml --- - name: set permissions for IIS-IUSRS win_acl: path="C:\\Users\\James\\Desktop\temp" user='IIS_IUSRS' rights='Read' type=allow state=present </code></pre></div> <h5 dir="auto">EXPECTED RESULTS</h5> <p dir="auto">Permissions changed</p> <h5 dir="auto">ACTUAL RESULTS</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="TASK [role1: set permissions for IIS_IUSRS] ************************* task path: /root/ansible/roles/role1/tasks/main.yml:9 fatal: [myMachine]: FAILED! =&gt; {&quot;changed&quot;: false, &quot;failed&quot;: true, &quot;invocation&quot;: {&quot;module_name&quot;: &quot;win_acl&quot;}, &quot;msg&quot;: &quot;an exception occured when adding the specified rule&quot;} PLAY RECAP ********************************************************************* myMachine : ok=1 changed=0 unreachable=0 failed=1 "><pre class="notranslate"><code class="notranslate">TASK [role1: set permissions for IIS_IUSRS] ************************* task path: /root/ansible/roles/role1/tasks/main.yml:9 fatal: [myMachine]: FAILED! =&gt; {"changed": false, "failed": true, "invocation": {"module_name": "win_acl"}, "msg": "an exception occured when adding the specified rule"} PLAY RECAP ********************************************************************* myMachine : ok=1 changed=0 unreachable=0 failed=1 </code></pre></div>
<p dir="auto"><strong>Issue Type:</strong></p> <p dir="auto">Bug Report</p> <p dir="auto"><strong>Ansible Version:</strong></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ansible 1.9.2 (detached HEAD 982bad7886) last updated 2015/06/19 17:29:23 (GMT -200) lib/ansible/modules/core: (detached HEAD 016ad8a1cb) last updated 2015/06/19 17:29:29 (GMT -200) lib/ansible/modules/extras: (detached HEAD 86d9bbae52) last updated 2015/06/19 17:29:34 (GMT -200) v2/ansible/modules/core: (detached HEAD 34784b7a61) last updated 2015/06/19 17:29:40 (GMT -200) v2/ansible/modules/extras: (detached HEAD 46e316a20a) last updated 2015/06/19 17:29:47 (GMT -200) configured module search path = None"><pre class="notranslate"><code class="notranslate">ansible 1.9.2 (detached HEAD 982bad7886) last updated 2015/06/19 17:29:23 (GMT -200) lib/ansible/modules/core: (detached HEAD 016ad8a1cb) last updated 2015/06/19 17:29:29 (GMT -200) lib/ansible/modules/extras: (detached HEAD 86d9bbae52) last updated 2015/06/19 17:29:34 (GMT -200) v2/ansible/modules/core: (detached HEAD 34784b7a61) last updated 2015/06/19 17:29:40 (GMT -200) v2/ansible/modules/extras: (detached HEAD 46e316a20a) last updated 2015/06/19 17:29:47 (GMT -200) configured module search path = None </code></pre></div> <p dir="auto"><strong>Ansible Configuration:</strong></p> <p dir="auto">I haven't changed or added any configuration settings to Ansible.</p> <p dir="auto"><strong>Environment:</strong></p> <p dir="auto">OSX 10.10.3<br> Python 2.7.10</p> <p dir="auto"><strong>Summary:</strong></p> <p dir="auto">A handler that is firstly not notified due to a skipped and depended upon task, but later notified through the same task (directly invoked), does not run at the of the play.</p> <p dir="auto"><strong>Steps to Reproduce:</strong></p> <p dir="auto">I set up an example repository to illustrate this bug: <a href="https://github.com/arturhoo/ansible-bug">https://github.com/arturhoo/ansible-bug</a></p> <p dir="auto"><strong>Expected Results:</strong></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ ansible-playbook -i 'localhost,' --connection=local playbook.yml PLAY [all] ******************************************************************** GATHERING FACTS *************************************************************** ok: [localhost] TASK: [one | create bar file] ************************************************* skipping: [localhost] TASK: [one | echo foo to bar file] ******************************************** skipping: [localhost] TASK: [two | create xpto file] ************************************************ changed: [localhost] TASK: [one | create bar file] ************************************************* changed: [localhost] TASK: [one | echo foo to bar file] ******************************************** changed: [localhost] NOTIFIED: [one | handle this] ************************************************* changed: [localhost] PLAY RECAP ******************************************************************** localhost : ok=4 changed=4 unreachable=0 failed=0"><pre class="notranslate"><code class="notranslate">$ ansible-playbook -i 'localhost,' --connection=local playbook.yml PLAY [all] ******************************************************************** GATHERING FACTS *************************************************************** ok: [localhost] TASK: [one | create bar file] ************************************************* skipping: [localhost] TASK: [one | echo foo to bar file] ******************************************** skipping: [localhost] TASK: [two | create xpto file] ************************************************ changed: [localhost] TASK: [one | create bar file] ************************************************* changed: [localhost] TASK: [one | echo foo to bar file] ******************************************** changed: [localhost] NOTIFIED: [one | handle this] ************************************************* changed: [localhost] PLAY RECAP ******************************************************************** localhost : ok=4 changed=4 unreachable=0 failed=0 </code></pre></div> <p dir="auto"><strong>Actual Results:</strong></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ ansible-playbook -i 'localhost,' --connection=local playbook.yml PLAY [all] ******************************************************************** GATHERING FACTS *************************************************************** ok: [localhost] TASK: [one | create bar file] ************************************************* skipping: [localhost] TASK: [one | echo foo to bar file] ******************************************** skipping: [localhost] TASK: [two | create xpto file] ************************************************ changed: [localhost] TASK: [one | create bar file] ************************************************* changed: [localhost] TASK: [one | echo foo to bar file] ******************************************** changed: [localhost] NOTIFIED: [one | handle this] ************************************************* skipping: [localhost] PLAY RECAP ******************************************************************** localhost : ok=4 changed=3 unreachable=0 failed=0"><pre class="notranslate"><code class="notranslate">$ ansible-playbook -i 'localhost,' --connection=local playbook.yml PLAY [all] ******************************************************************** GATHERING FACTS *************************************************************** ok: [localhost] TASK: [one | create bar file] ************************************************* skipping: [localhost] TASK: [one | echo foo to bar file] ******************************************** skipping: [localhost] TASK: [two | create xpto file] ************************************************ changed: [localhost] TASK: [one | create bar file] ************************************************* changed: [localhost] TASK: [one | echo foo to bar file] ******************************************** changed: [localhost] NOTIFIED: [one | handle this] ************************************************* skipping: [localhost] PLAY RECAP ******************************************************************** localhost : ok=4 changed=3 unreachable=0 failed=0 </code></pre></div>
0
<h3 dir="auto">First Check</h3> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I added a very descriptive title to this issue.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I used the GitHub search to find a similar issue and didn't find it.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I searched the FastAPI documentation, with the integrated search.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I already searched in Google "How to X in FastAPI" and didn't find any information.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I already read and followed all the tutorial in the docs and didn't find an answer.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I already checked if it is not related to FastAPI but to <a href="https://github.com/samuelcolvin/pydantic">Pydantic</a>.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I already checked if it is not related to FastAPI but to <a href="https://github.com/swagger-api/swagger-ui">Swagger UI</a>.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I already checked if it is not related to FastAPI but to <a href="https://github.com/Redocly/redoc">ReDoc</a>.</li> </ul> <h3 dir="auto">Commit to Help</h3> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I commit to help with one of those options <g-emoji class="g-emoji" alias="point_up_2" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/1f446.png">👆</g-emoji></li> </ul> <h3 dir="auto">Example Code</h3> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="val = 1 async def functionOne(self) -&gt; JSONResponse: try: await addOne(); // adds one to value. return JSONResponse(status_code=200, content={&quot;message&quot;: &quot;example&quot;}) except ValueError as e: return JSONResponse(status_code=400, content={&quot;message&quot;: e.args[0]}) router.get('/example')(self.functionOne)"><pre class="notranslate"><span class="pl-s1">val</span> <span class="pl-c1">=</span> <span class="pl-c1">1</span> <span class="pl-k">async</span> <span class="pl-k">def</span> <span class="pl-en">functionOne</span>(<span class="pl-s1">self</span>) <span class="pl-c1">-&gt;</span> <span class="pl-v">JSONResponse</span>: <span class="pl-k">try</span>: <span class="pl-k">await</span> <span class="pl-en">addOne</span>(); <span class="pl-c1">//</span> <span class="pl-s1">adds</span> <span class="pl-s1">one</span> <span class="pl-s1">to</span> <span class="pl-s1">value</span>. <span class="pl-s1">return</span> <span class="pl-v">JSONResponse</span>(<span class="pl-s1">status_code</span><span class="pl-c1">=</span><span class="pl-c1">200</span>, <span class="pl-s1">content</span><span class="pl-c1">=</span>{<span class="pl-s">"message"</span>: <span class="pl-s">"example"</span>}) <span class="pl-k">except</span> <span class="pl-v">ValueError</span> <span class="pl-k">as</span> <span class="pl-s1">e</span>: <span class="pl-k">return</span> <span class="pl-v">JSONResponse</span>(<span class="pl-s1">status_code</span><span class="pl-c1">=</span><span class="pl-c1">400</span>, <span class="pl-s1">content</span><span class="pl-c1">=</span>{<span class="pl-s">"message"</span>: <span class="pl-s1">e</span>.<span class="pl-s1">args</span>[<span class="pl-c1">0</span>]}) <span class="pl-s1">router</span>.<span class="pl-en">get</span>(<span class="pl-s">'/example'</span>)(<span class="pl-s1">self</span>.<span class="pl-s1">functionOne</span>)</pre></div> <h3 dir="auto">Description</h3> <p dir="auto">the value of the val should be 2 but getting 3 because I am getting duplicate requests in a single hit.</p> <h3 dir="auto">Operating System</h3> <p dir="auto">Linux</p> <h3 dir="auto">Operating System Details</h3> <p dir="auto">Linux</p> <h3 dir="auto">FastAPI Version</h3> <p dir="auto">0.70.1</p> <h3 dir="auto">Python Version</h3> <p dir="auto">3.8</p> <h3 dir="auto">Additional Context</h3> <p dir="auto"><em>No response</em></p>
<h3 dir="auto">First check</h3> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I added a very descriptive title to this issue.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I used the GitHub search to find a similar issue and didn't find it.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I searched the FastAPI documentation, with the integrated search.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I already searched in Google "How to X in FastAPI" and didn't find any information.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I already read and followed all the tutorial in the docs and didn't find an answer.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I already checked if it is not related to FastAPI but to <a href="https://github.com/samuelcolvin/pydantic">Pydantic</a>.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I already checked if it is not related to FastAPI but to <a href="https://github.com/swagger-api/swagger-ui">Swagger UI</a>.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I already checked if it is not related to FastAPI but to <a href="https://github.com/Redocly/redoc">ReDoc</a>.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> After submitting this, I commit to one of: <ul dir="auto"> <li>Read open issues with questions until I find 2 issues where I can help someone and add a comment to help there.</li> <li>I already hit the "watch" button in this repository to receive notifications and I commit to help at least 2 people that ask questions in the future.</li> <li>Implement a Pull Request for a confirmed bug.</li> </ul> </li> </ul> <h3 dir="auto">Example</h3> <p dir="auto">Here's a self-contained, <a href="https://stackoverflow.com/help/minimal-reproducible-example" rel="nofollow">minimal, reproducible, example</a> with my use case:</p> <h4 dir="auto"><code class="notranslate">main.py</code></h4> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="from fastapi import FastAPI import router1 import router2 app = FastAPI() app.include_router(router1.router, prefix=&quot;/r1&quot;) app.include_router(router2.router, prefix=&quot;/r2&quot;)"><pre class="notranslate"><span class="pl-k">from</span> <span class="pl-s1">fastapi</span> <span class="pl-k">import</span> <span class="pl-v">FastAPI</span> <span class="pl-k">import</span> <span class="pl-s1">router1</span> <span class="pl-k">import</span> <span class="pl-s1">router2</span> <span class="pl-s1">app</span> <span class="pl-c1">=</span> <span class="pl-v">FastAPI</span>() <span class="pl-s1">app</span>.<span class="pl-en">include_router</span>(<span class="pl-s1">router1</span>.<span class="pl-s1">router</span>, <span class="pl-s1">prefix</span><span class="pl-c1">=</span><span class="pl-s">"/r1"</span>) <span class="pl-s1">app</span>.<span class="pl-en">include_router</span>(<span class="pl-s1">router2</span>.<span class="pl-s1">router</span>, <span class="pl-s1">prefix</span><span class="pl-c1">=</span><span class="pl-s">"/r2"</span>)</pre></div> <h4 dir="auto"><code class="notranslate">router1.py</code></h4> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="from enum import Enum from fastapi import APIRouter class DuplicatedEnum(str, Enum): value1 = &quot;value1&quot; router = APIRouter() @router.get(&quot;/&quot;) async def _(type: DuplicatedEnum = DuplicatedEnum.value1): pass"><pre class="notranslate"><span class="pl-k">from</span> <span class="pl-s1">enum</span> <span class="pl-k">import</span> <span class="pl-v">Enum</span> <span class="pl-k">from</span> <span class="pl-s1">fastapi</span> <span class="pl-k">import</span> <span class="pl-v">APIRouter</span> <span class="pl-k">class</span> <span class="pl-v">DuplicatedEnum</span>(<span class="pl-s1">str</span>, <span class="pl-v">Enum</span>): <span class="pl-s1">value1</span> <span class="pl-c1">=</span> <span class="pl-s">"value1"</span> <span class="pl-s1">router</span> <span class="pl-c1">=</span> <span class="pl-v">APIRouter</span>() <span class="pl-en">@<span class="pl-s1">router</span>.<span class="pl-en">get</span>(<span class="pl-s">"/"</span>)</span> <span class="pl-k">async</span> <span class="pl-k">def</span> <span class="pl-en">_</span>(<span class="pl-s1">type</span>: <span class="pl-v">DuplicatedEnum</span> <span class="pl-c1">=</span> <span class="pl-v">DuplicatedEnum</span>.<span class="pl-s1">value1</span>): <span class="pl-k">pass</span></pre></div> <h4 dir="auto"><code class="notranslate">router2.py</code></h4> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="from enum import Enum from fastapi import APIRouter class DuplicatedEnum(str, Enum): value2 = &quot;value2&quot; router = APIRouter() @router.get(&quot;/&quot;) async def _(type: DuplicatedEnum = DuplicatedEnum.value2): pass"><pre class="notranslate"><span class="pl-k">from</span> <span class="pl-s1">enum</span> <span class="pl-k">import</span> <span class="pl-v">Enum</span> <span class="pl-k">from</span> <span class="pl-s1">fastapi</span> <span class="pl-k">import</span> <span class="pl-v">APIRouter</span> <span class="pl-k">class</span> <span class="pl-v">DuplicatedEnum</span>(<span class="pl-s1">str</span>, <span class="pl-v">Enum</span>): <span class="pl-s1">value2</span> <span class="pl-c1">=</span> <span class="pl-s">"value2"</span> <span class="pl-s1">router</span> <span class="pl-c1">=</span> <span class="pl-v">APIRouter</span>() <span class="pl-en">@<span class="pl-s1">router</span>.<span class="pl-en">get</span>(<span class="pl-s">"/"</span>)</span> <span class="pl-k">async</span> <span class="pl-k">def</span> <span class="pl-en">_</span>(<span class="pl-s1">type</span>: <span class="pl-v">DuplicatedEnum</span> <span class="pl-c1">=</span> <span class="pl-v">DuplicatedEnum</span>.<span class="pl-s1">value2</span>): <span class="pl-k">pass</span></pre></div> <h3 dir="auto">Description</h3> <ul dir="auto"> <li>Open the browser and call the document <code class="notranslate">/redoc</code>.</li> <li>It raised error <code class="notranslate">Error resolving $ref pointer "http://127.0.0.1:8000/openapi.json#/components/schemas/DuplicatedEnum". Token "DuplicatedEnum" does not exist.</code></li> <li>After I checked <code class="notranslate">openapi.json</code>, it gives wrong parameter schema:</li> </ul> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="{ &quot;openapi&quot;: &quot;3.0.2&quot;, &quot;info&quot;: { &quot;title&quot;: &quot;FastAPI&quot;, &quot;version&quot;: &quot;0.1.0&quot; }, &quot;paths&quot;: { &quot;/r1/&quot;: { &quot;get&quot;: { &quot;summary&quot;: &quot; &quot;, &quot;operationId&quot;: &quot;__r1__get&quot;, &quot;parameters&quot;: [{ &quot;required&quot;: false, &quot;schema&quot;: { &quot;allOf&quot;: [{ &quot;$ref&quot;: &quot;#/components/schemas/DuplicatedEnum&quot; //should be `router1__DuplicatedEnum` }], &quot;default&quot;: &quot;value1&quot; }, &quot;name&quot;: &quot;type&quot;, &quot;in&quot;: &quot;query&quot; }], &quot;responses&quot;: { &quot;200&quot;: { &quot;description&quot;: &quot;Successful Response&quot;, &quot;content&quot;: { &quot;application/json&quot;: { &quot;schema&quot;: {} } } }, &quot;422&quot;: { &quot;description&quot;: &quot;Validation Error&quot;, &quot;content&quot;: { &quot;application/json&quot;: { &quot;schema&quot;: { &quot;$ref&quot;: &quot;#/components/schemas/HTTPValidationError&quot; } } } } } } }, &quot;/r2/&quot;: { &quot;get&quot;: { &quot;summary&quot;: &quot; &quot;, &quot;operationId&quot;: &quot;__r2__get&quot;, &quot;parameters&quot;: [{ &quot;required&quot;: false, &quot;schema&quot;: { &quot;allOf&quot;: [{ &quot;$ref&quot;: &quot;#/components/schemas/DuplicatedEnum&quot; }], &quot;default&quot;: &quot;value2&quot; }, &quot;name&quot;: &quot;type&quot;, &quot;in&quot;: &quot;query&quot; }], &quot;responses&quot;: { &quot;200&quot;: { &quot;description&quot;: &quot;Successful Response&quot;, &quot;content&quot;: { &quot;application/json&quot;: { &quot;schema&quot;: {} } } }, &quot;422&quot;: { &quot;description&quot;: &quot;Validation Error&quot;, &quot;content&quot;: { &quot;application/json&quot;: { &quot;schema&quot;: { &quot;$ref&quot;: &quot;#/components/schemas/HTTPValidationError&quot; } } } } } } } }, &quot;components&quot;: { &quot;schemas&quot;: { &quot;HTTPValidationError&quot;: { &quot;title&quot;: &quot;HTTPValidationError&quot;, &quot;type&quot;: &quot;object&quot;, &quot;properties&quot;: { &quot;detail&quot;: { &quot;title&quot;: &quot;Detail&quot;, &quot;type&quot;: &quot;array&quot;, &quot;items&quot;: { &quot;$ref&quot;: &quot;#/components/schemas/ValidationError&quot; } } } }, &quot;ValidationError&quot;: { &quot;title&quot;: &quot;ValidationError&quot;, &quot;required&quot;: [&quot;loc&quot;, &quot;msg&quot;, &quot;type&quot;], &quot;type&quot;: &quot;object&quot;, &quot;properties&quot;: { &quot;loc&quot;: { &quot;title&quot;: &quot;Location&quot;, &quot;type&quot;: &quot;array&quot;, &quot;items&quot;: { &quot;type&quot;: &quot;string&quot; } }, &quot;msg&quot;: { &quot;title&quot;: &quot;Message&quot;, &quot;type&quot;: &quot;string&quot; }, &quot;type&quot;: { &quot;title&quot;: &quot;Error Type&quot;, &quot;type&quot;: &quot;string&quot; } } }, &quot;router1__DuplicatedEnum&quot;: { &quot;title&quot;: &quot;DuplicatedEnum&quot;, &quot;enum&quot;: [&quot;value1&quot;], &quot;type&quot;: &quot;string&quot;, &quot;description&quot;: &quot;An enumeration.&quot; }, &quot;router2__DuplicatedEnum&quot;: { &quot;title&quot;: &quot;DuplicatedEnum&quot;, &quot;enum&quot;: [&quot;value2&quot;], &quot;type&quot;: &quot;string&quot;, &quot;description&quot;: &quot;An enumeration.&quot; } } } }"><pre class="notranslate"><span class="pl-kos">{</span> <span class="pl-s">"openapi"</span>: <span class="pl-s">"3.0.2"</span><span class="pl-kos">,</span> <span class="pl-s">"info"</span>: <span class="pl-kos">{</span> <span class="pl-s">"title"</span>: <span class="pl-s">"FastAPI"</span><span class="pl-kos">,</span> <span class="pl-s">"version"</span>: <span class="pl-s">"0.1.0"</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"paths"</span>: <span class="pl-kos">{</span> <span class="pl-s">"/r1/"</span>: <span class="pl-kos">{</span> <span class="pl-s">"get"</span>: <span class="pl-kos">{</span> <span class="pl-s">"summary"</span>: <span class="pl-s">" "</span><span class="pl-kos">,</span> <span class="pl-s">"operationId"</span>: <span class="pl-s">"__r1__get"</span><span class="pl-kos">,</span> <span class="pl-s">"parameters"</span>: <span class="pl-kos">[</span><span class="pl-kos">{</span> <span class="pl-s">"required"</span>: <span class="pl-c1">false</span><span class="pl-kos">,</span> <span class="pl-s">"schema"</span>: <span class="pl-kos">{</span> <span class="pl-s">"allOf"</span>: <span class="pl-kos">[</span><span class="pl-kos">{</span> <span class="pl-s">"$ref"</span>: <span class="pl-s">"#/components/schemas/DuplicatedEnum"</span> <span class="pl-c">//should be `router1__DuplicatedEnum`</span> <span class="pl-kos">}</span><span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-s">"default"</span>: <span class="pl-s">"value1"</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"name"</span>: <span class="pl-s">"type"</span><span class="pl-kos">,</span> <span class="pl-s">"in"</span>: <span class="pl-s">"query"</span> <span class="pl-kos">}</span><span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-s">"responses"</span>: <span class="pl-kos">{</span> <span class="pl-s">"200"</span>: <span class="pl-kos">{</span> <span class="pl-s">"description"</span>: <span class="pl-s">"Successful Response"</span><span class="pl-kos">,</span> <span class="pl-s">"content"</span>: <span class="pl-kos">{</span> <span class="pl-s">"application/json"</span>: <span class="pl-kos">{</span> <span class="pl-s">"schema"</span>: <span class="pl-kos">{</span><span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"422"</span>: <span class="pl-kos">{</span> <span class="pl-s">"description"</span>: <span class="pl-s">"Validation Error"</span><span class="pl-kos">,</span> <span class="pl-s">"content"</span>: <span class="pl-kos">{</span> <span class="pl-s">"application/json"</span>: <span class="pl-kos">{</span> <span class="pl-s">"schema"</span>: <span class="pl-kos">{</span> <span class="pl-s">"$ref"</span>: <span class="pl-s">"#/components/schemas/HTTPValidationError"</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"/r2/"</span>: <span class="pl-kos">{</span> <span class="pl-s">"get"</span>: <span class="pl-kos">{</span> <span class="pl-s">"summary"</span>: <span class="pl-s">" "</span><span class="pl-kos">,</span> <span class="pl-s">"operationId"</span>: <span class="pl-s">"__r2__get"</span><span class="pl-kos">,</span> <span class="pl-s">"parameters"</span>: <span class="pl-kos">[</span><span class="pl-kos">{</span> <span class="pl-s">"required"</span>: <span class="pl-c1">false</span><span class="pl-kos">,</span> <span class="pl-s">"schema"</span>: <span class="pl-kos">{</span> <span class="pl-s">"allOf"</span>: <span class="pl-kos">[</span><span class="pl-kos">{</span> <span class="pl-s">"$ref"</span>: <span class="pl-s">"#/components/schemas/DuplicatedEnum"</span> <span class="pl-kos">}</span><span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-s">"default"</span>: <span class="pl-s">"value2"</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"name"</span>: <span class="pl-s">"type"</span><span class="pl-kos">,</span> <span class="pl-s">"in"</span>: <span class="pl-s">"query"</span> <span class="pl-kos">}</span><span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-s">"responses"</span>: <span class="pl-kos">{</span> <span class="pl-s">"200"</span>: <span class="pl-kos">{</span> <span class="pl-s">"description"</span>: <span class="pl-s">"Successful Response"</span><span class="pl-kos">,</span> <span class="pl-s">"content"</span>: <span class="pl-kos">{</span> <span class="pl-s">"application/json"</span>: <span class="pl-kos">{</span> <span class="pl-s">"schema"</span>: <span class="pl-kos">{</span><span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"422"</span>: <span class="pl-kos">{</span> <span class="pl-s">"description"</span>: <span class="pl-s">"Validation Error"</span><span class="pl-kos">,</span> <span class="pl-s">"content"</span>: <span class="pl-kos">{</span> <span class="pl-s">"application/json"</span>: <span class="pl-kos">{</span> <span class="pl-s">"schema"</span>: <span class="pl-kos">{</span> <span class="pl-s">"$ref"</span>: <span class="pl-s">"#/components/schemas/HTTPValidationError"</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"components"</span>: <span class="pl-kos">{</span> <span class="pl-s">"schemas"</span>: <span class="pl-kos">{</span> <span class="pl-s">"HTTPValidationError"</span>: <span class="pl-kos">{</span> <span class="pl-s">"title"</span>: <span class="pl-s">"HTTPValidationError"</span><span class="pl-kos">,</span> <span class="pl-s">"type"</span>: <span class="pl-s">"object"</span><span class="pl-kos">,</span> <span class="pl-s">"properties"</span>: <span class="pl-kos">{</span> <span class="pl-s">"detail"</span>: <span class="pl-kos">{</span> <span class="pl-s">"title"</span>: <span class="pl-s">"Detail"</span><span class="pl-kos">,</span> <span class="pl-s">"type"</span>: <span class="pl-s">"array"</span><span class="pl-kos">,</span> <span class="pl-s">"items"</span>: <span class="pl-kos">{</span> <span class="pl-s">"$ref"</span>: <span class="pl-s">"#/components/schemas/ValidationError"</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"ValidationError"</span>: <span class="pl-kos">{</span> <span class="pl-s">"title"</span>: <span class="pl-s">"ValidationError"</span><span class="pl-kos">,</span> <span class="pl-s">"required"</span>: <span class="pl-kos">[</span><span class="pl-s">"loc"</span><span class="pl-kos">,</span> <span class="pl-s">"msg"</span><span class="pl-kos">,</span> <span class="pl-s">"type"</span><span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-s">"type"</span>: <span class="pl-s">"object"</span><span class="pl-kos">,</span> <span class="pl-s">"properties"</span>: <span class="pl-kos">{</span> <span class="pl-s">"loc"</span>: <span class="pl-kos">{</span> <span class="pl-s">"title"</span>: <span class="pl-s">"Location"</span><span class="pl-kos">,</span> <span class="pl-s">"type"</span>: <span class="pl-s">"array"</span><span class="pl-kos">,</span> <span class="pl-s">"items"</span>: <span class="pl-kos">{</span> <span class="pl-s">"type"</span>: <span class="pl-s">"string"</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"msg"</span>: <span class="pl-kos">{</span> <span class="pl-s">"title"</span>: <span class="pl-s">"Message"</span><span class="pl-kos">,</span> <span class="pl-s">"type"</span>: <span class="pl-s">"string"</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"type"</span>: <span class="pl-kos">{</span> <span class="pl-s">"title"</span>: <span class="pl-s">"Error Type"</span><span class="pl-kos">,</span> <span class="pl-s">"type"</span>: <span class="pl-s">"string"</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"router1__DuplicatedEnum"</span>: <span class="pl-kos">{</span> <span class="pl-s">"title"</span>: <span class="pl-s">"DuplicatedEnum"</span><span class="pl-kos">,</span> <span class="pl-s">"enum"</span>: <span class="pl-kos">[</span><span class="pl-s">"value1"</span><span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-s">"type"</span>: <span class="pl-s">"string"</span><span class="pl-kos">,</span> <span class="pl-s">"description"</span>: <span class="pl-s">"An enumeration."</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"router2__DuplicatedEnum"</span>: <span class="pl-kos">{</span> <span class="pl-s">"title"</span>: <span class="pl-s">"DuplicatedEnum"</span><span class="pl-kos">,</span> <span class="pl-s">"enum"</span>: <span class="pl-kos">[</span><span class="pl-s">"value2"</span><span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-s">"type"</span>: <span class="pl-s">"string"</span><span class="pl-kos">,</span> <span class="pl-s">"description"</span>: <span class="pl-s">"An enumeration."</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span></pre></div> <h3 dir="auto">Environment</h3> <ul dir="auto"> <li>OS: [e.g. Linux / Windows / macOS]: Linux</li> <li>FastAPI Version [e.g. 0.3.0]: 0.63.0</li> <li>Python version: 3.9.1</li> </ul>
0
<h3 dir="auto">Preflight Checklist</h3> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have read the <a href="https://github.com/electron/electron/blob/master/CONTRIBUTING.md">Contributing Guidelines</a> for this project.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I agree to follow the <a href="https://github.com/electron/electron/blob/master/CODE_OF_CONDUCT.md">Code of Conduct</a> that this project adheres to.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the issue tracker for an issue that matches the one I want to file, without success.</li> </ul> <h3 dir="auto">Issue Details</h3> <ul dir="auto"> <li><strong>Electron Version:</strong> <ul dir="auto"> <li>9.0.0</li> </ul> </li> <li><strong>Operating System:</strong> <ul dir="auto"> <li>10.15.5</li> </ul> </li> <li><strong>Last Known Working Electron version:</strong> <ul dir="auto"> <li>no</li> </ul> </li> </ul> <h3 dir="auto">Expected Behavior</h3> <p dir="auto">show the download file dialog</p> <h3 dir="auto">Actual Behavior</h3> <p dir="auto">nothing happened</p> <h3 dir="auto">To Reproduce</h3> <p dir="auto">use the follow config to load remote <code class="notranslate">pdf</code></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" frame: true, fullscreenable: true, width: 500, height: 600, resizable: true, backgroundColor: '#ffffff', webPreferences: { plugins: true, nodeIntegration: true, contextIsolation: false, javascript: true, webSecurity: true, allowRunningInsecureContent: true, }, show: false"><pre class="notranslate"><code class="notranslate"> frame: true, fullscreenable: true, width: 500, height: 600, resizable: true, backgroundColor: '#ffffff', webPreferences: { plugins: true, nodeIntegration: true, contextIsolation: false, javascript: true, webSecurity: true, allowRunningInsecureContent: true, }, show: false </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" pdfWindow.webContents.loadURL(url); "><pre class="notranslate"><code class="notranslate"> pdfWindow.webContents.loadURL(url); </code></pre></div> <p dir="auto"><a href="https://gist.github.com/c09409811c4264df06535f24cfd7194d">https://gist.github.com/c09409811c4264df06535f24cfd7194d</a></p> <h3 dir="auto">Screenshots</h3> <h3 dir="auto">Additional Information</h3>
<p dir="auto">When viewing a PDF, clicking the "download" button has no effect. It should trigger a download (including the <code class="notranslate">"will-download"</code> event and associated machinery).</p>
1
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/apache/incubator-dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have checked the <a href="https://github.com/apache/incubator-dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li> </ul> <h3 dir="auto">Details</h3> <p dir="auto">For now on, Dubbo does not support to resolve all placeholders from property value from any <code class="notranslate">PropertySource</code>, thus it will impact Dubbo Spring Boot's externalization configuration, like this issue :</p> <ul dir="auto"> <li><a href="https://github.com/apache/incubator-dubbo-spring-boot-project/issues/249" data-hovercard-type="issue" data-hovercard-url="/apache/dubbo-spring-boot-project/issues/249/hovercard">Can provider boot features external config placeholders in properties?</a></li> </ul> <p dir="auto">What's more, Dubbo's <code class="notranslate">PropertySourcesUtils</code> will be removed and replaced by <a href="https://github.com/alibaba/spring-context-support">Alibaba's spring-context-support</a>'s <a href="https://github.com/alibaba/spring-context-support/blob/1.0.1/src/main/java/com/alibaba/spring/util/PropertySourcesUtils.java"><code class="notranslate">PropertySourcesUtils</code></a></p>
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> I have searched the <a href="https://github.com/apache/incubator-dubbo/issues">issues</a> of this repository and believe that this is not a duplicate.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> I have checked the <a href="https://github.com/apache/incubator-dubbo/blob/master/FAQ.md">FAQ</a> of this repository and believe that this is not a duplicate.</li> </ul> <h3 dir="auto">Environment</h3> <ul dir="auto"> <li>Dubbo version: 2.5.10</li> <li>Operating System version: win10</li> <li>Java version: 1.8</li> </ul> <h3 dir="auto">Step to reproduce this issue</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" `public class Entity implements Serializable { private static final long serialVersionUID = 187648346954430294L; private List&lt;Integer&gt; list1 = new CopyOnWriteArrayList&lt;&gt;(); private List&lt;Integer&gt; list2 = new CopyOnWriteArrayList&lt;&gt;(); public List&lt;Integer&gt; getList1() { return list1; } public List&lt;Integer&gt; getList2() { return list2; } }` `public static void main(String[] args) throws IOException { Entity entity = new Entity(); // 此时两个 CopyOnWriteArrayList 不同 System.out.println(entity.getList1() == entity.getList2()); // 序列化 OutputStream outputStream = new FileOutputStream(&quot;dubboSerializer&quot;); GenericObjectOutput objectOutput = new GenericObjectOutput(outputStream); objectOutput.writeObject(entity); objectOutput.flushBuffer(); // 反序列化 GenericObjectInput input = new GenericObjectInput(new FileInputStream(&quot;dubboSerializer&quot;)); Entity obj1 = (Entity) input.readObject(); // 此时两个 CopyOnWriteArrayList 相同???????????????????????? System.out.println(obj1.getList1() == obj1.getList2()); }`"><pre class="notranslate"><code class="notranslate"> `public class Entity implements Serializable { private static final long serialVersionUID = 187648346954430294L; private List&lt;Integer&gt; list1 = new CopyOnWriteArrayList&lt;&gt;(); private List&lt;Integer&gt; list2 = new CopyOnWriteArrayList&lt;&gt;(); public List&lt;Integer&gt; getList1() { return list1; } public List&lt;Integer&gt; getList2() { return list2; } }` `public static void main(String[] args) throws IOException { Entity entity = new Entity(); // 此时两个 CopyOnWriteArrayList 不同 System.out.println(entity.getList1() == entity.getList2()); // 序列化 OutputStream outputStream = new FileOutputStream("dubboSerializer"); GenericObjectOutput objectOutput = new GenericObjectOutput(outputStream); objectOutput.writeObject(entity); objectOutput.flushBuffer(); // 反序列化 GenericObjectInput input = new GenericObjectInput(new FileInputStream("dubboSerializer")); Entity obj1 = (Entity) input.readObject(); // 此时两个 CopyOnWriteArrayList 相同???????????????????????? System.out.println(obj1.getList1() == obj1.getList2()); }` </code></pre></div> <p dir="auto">说明: 将 CopyOnWriteArrayList 换成 ArrayList 时 没有此问题.</p>
0
<p dir="auto">Current if entering a new line inside ad JsDoc comment, nothing is inserted in the new line.<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/1171301/10116153/9c4bb62a-63dd-11e5-876a-609c87897ab4.gif"><img src="https://cloud.githubusercontent.com/assets/1171301/10116153/9c4bb62a-63dd-11e5-876a-609c87897ab4.gif" alt="gif" data-animated-image="" style="max-width: 100%;"></a></p>
<p dir="auto">I have many scenarios where I would do this:</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import myExternalModule = require(&quot;./myExternalModule&quot;); // not using myExternalModule here"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">myExternalModule</span> <span class="pl-c1">=</span> require<span class="pl-kos">(</span><span class="pl-s">"./myExternalModule"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-c">// not using myExternalModule here</span></pre></div> <p dir="auto">I dont use <code class="notranslate">myExternalModule</code> in my code but still I want it to be included using requirejs. I just need it to be there.<br> If there could be a <code class="notranslate">forceimport</code> keyword that would be very cool!</p>
0
<h1 dir="auto">Environment</h1> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Windows build number: Microsoft Windows [Version 10.0.18362.449] Windows Terminal version (if applicable): 0.6.2951.0"><pre lang="none" class="notranslate"><code class="notranslate">Windows build number: Microsoft Windows [Version 10.0.18362.449] Windows Terminal version (if applicable): 0.6.2951.0 </code></pre></div> <p dir="auto">Link to Feedback: <a href="https://aka.ms/AA6f0m9" rel="nofollow">https://aka.ms/AA6f0m9</a></p> <h1 dir="auto">Prerequisites</h1> <ol dir="auto"> <li>3 monitors, 1st and 2nd -with Full HD resolution and 100% scaling, 3rd - 2550x1440 and 150% scaling</li> <li>Installed Ubuntu 18.04 WSL</li> </ol> <h1 dir="auto">Steps to reproduce</h1> <ol dir="auto"> <li>Open WSL Ubuntu 18.04 in Windows Terminal, keep it in screen 1 or 2 (with 100% scaling)</li> <li>connect to via ssh to any server (tried to connect to Amazon Linux)</li> <li>Move Windows Terminal to 3rd screen (with 150% scaling)</li> <li>Wait 3 seconds</li> <li>Move Windows Terminal to 2nd screen (with 100% scaling)</li> </ol> <h1 dir="auto">Expected behavior</h1> <p dir="auto">Loading indicator is shown, in few seconds terminal is closed</p> <h1 dir="auto">Actual behavior</h1> <p dir="auto">Terminal should continue working without any issues</p> <p dir="auto">Note: on "Ubuntu 18.04 LTS" app this issue isn't reproducing</p>
<h1 dir="auto">Environment</h1> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Windows build number: Version 10.0.18922.1000 Windows Terminal version (if applicable): 0.2.1715.0"><pre lang="none" class="notranslate"><code class="notranslate">Windows build number: Version 10.0.18922.1000 Windows Terminal version (if applicable): 0.2.1715.0 </code></pre></div> <h1 dir="auto">Steps to reproduce</h1> <ol dir="auto"> <li>Open <code class="notranslate">profiles.json</code></li> <li>In the "cmd" profile, change the value of <code class="notranslate">colorScheme</code> from "Campbell" to "Solarized Dark" (ensure this scheme exists in the built-in <code class="notranslate">schemes</code> list)</li> <li>Close and reopen Terminal</li> <li>Open the "cmd" profile</li> </ol> <p dir="auto">Also reproducible with WSL profiles (e.g. "Ubuntu").</p> <h1 dir="auto">Expected behavior</h1> <p dir="auto">According to <a href="https://github.com/microsoft/terminal/blob/03e3d8a685b7c2b74e6e56e34199e823353defb1/doc/cascadia/SettingsSchema.md">doc/cascadia/SettingsSchema.md</a>, <code class="notranslate">colorScheme</code> selects the color scheme to use for the profile, so I would expect to see Solarized colors in my terminal.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/builtin_solarized_dark.png"><img src="https://raw.githubusercontent.com/mbadolato/iTerm2-Color-Schemes/master/screenshots/builtin_solarized_dark.png" alt="solarized dark" style="max-width: 100%;"></a></p> <h1 dir="auto">Actual behavior</h1> <p dir="auto">cmd profile:<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/3299086/59968372-1c2e9480-9539-11e9-909d-c0024ca2dba2.png"><img src="https://user-images.githubusercontent.com/3299086/59968372-1c2e9480-9539-11e9-909d-c0024ca2dba2.png" alt="no-solarized" style="max-width: 100%;"></a></p> <p dir="auto">ubuntu profile (output of <a href="https://github.com/fikovnik/bin-scripts/blob/master/color-test.sh">color-test.sh</a>):<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/3299086/59968428-21d8aa00-953a-11e9-87a2-8e239dcdbcfb.png"><img src="https://user-images.githubusercontent.com/3299086/59968428-21d8aa00-953a-11e9-87a2-8e239dcdbcfb.png" alt="no-solarized_wsl" style="max-width: 100%;"></a></p>
0
<h3 dir="auto">System information</h3> <ul dir="auto"> <li><strong>Have I written custom code (as opposed to using a stock example script provided in TensorFlow)</strong>:</li> <li><strong>OS Platform and Distribution (e.g., Linux Ubuntu 16.04)</strong>:</li> <li><strong>TensorFlow installed from (source or binary)</strong>: python wheel</li> <li><strong>TensorFlow version (use command below)</strong>: 1.4 and 1.3</li> <li><strong>Python version</strong>: 3.6.1</li> <li><strong>Bazel version (if compiling from source)</strong>:</li> <li><strong>GCC/Compiler version (if compiling from source)</strong>:</li> <li><strong>CUDA/cuDNN version</strong>: None</li> <li><strong>GPU model and memory</strong>: None</li> <li><strong>Exact command to reproduce</strong>:</li> </ul> <p dir="auto">when I run tensorflow1.4 script using estimator, the script is 8 times slower than tensorflow 1.3</p> <h3 dir="auto">Source code / logs</h3> <p dir="auto"><code class="notranslate">main</code> script</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="#!/usr/bin/env python __author__ = 'zj' import argparse import os import sys import numpy as np import time try: import better_exceptions except ImportError: pass import tensorflow as tf from src.model_ori import crnn_fn from src.data_handler import data_loader from src.config import Params, Alphabet from src.input_utils import input_fn def main(unused_argv): models_path = FLAGS.input_model_dir if not os.path.exists(models_path): assert FileNotFoundError models_list = [os.path.join(models_path, x[:-5]) for x in os.listdir(models_path) if x.endswith('.meta')] if not os.path.exists(FLAGS.output_model_dir): os.makedirs(FLAGS.output_model_dir) parameters = Params(eval_batch_size=128, input_shape=(32, 304), digits_only=False, alphabet=Alphabet.CHINESECHAR_LETTERS_DIGITS_EXTENDED, alphabet_decoding='same', image_channels=1, csv_delimiter=' ', csv_files_eval=FLAGS.csv_files_eval, output_model_dir=FLAGS.output_model_dir, gpu=FLAGS.gpu ) model_params = { 'Params': parameters, } os.environ['CUDA_VISIBLE_DEVICES'] = parameters.gpu config_sess = tf.ConfigProto() config_sess.gpu_options.per_process_gpu_memory_fraction = 0.6 # Config estimator est_config = tf.estimator.RunConfig() est_config = est_config.replace(session_config=config_sess, save_summary_steps=100, model_dir=parameters.output_model_dir) estimator = tf.estimator.Estimator(model_fn=crnn_fn, params=model_params, config=est_config, model_dir=parameters.output_model_dir, ) try: with open(FLAGS.output_file, encoding='utf-8', mode='w') as save_file: for model in models_list: start = time.time() eval_results = estimator.evaluate(input_fn=data_loader(csv_filename=parameters.csv_files_eval, params=parameters, batch_size=parameters.eval_batch_size, num_epochs=1), steps=3, checkpoint_path=model) print('time:',time.time() - start) print('model: %s Evaluation results: %s' % (model, str(eval_results))) save_file.write(model + ' ' + str(eval_results) + '\n') except KeyboardInterrupt: print('Interrupted') if __name__ == '__main__': parser = argparse.ArgumentParser() parser.add_argument('-fe', '--csv_files_eval', required=False, type=str, help='CSV filename for evaluation', nargs='*', default=['E:/val1.csv']) parser.add_argument('-o', '--output_model_dir', required=False, type=str, help='Directory for output', default='models_vgg_100K_no_eval') parser.add_argument('-m', '--input_model_dir', required=False, type=str, help='Directory for output', default='model_test') parser.add_argument('-g', '--gpu', type=str, help=&quot;GPU 0,1 or '' &quot;, default='0') parser.add_argument('-of', '--output_file', required=False, type=str, default='123.txt', help=&quot;the log output file&quot;) tf.logging.set_verbosity(tf.logging.DEBUG) FLAGS, unparsed = parser.parse_known_args() tf.app.run(main=main, argv=[sys.argv[0]] + unparsed) "><pre class="notranslate"><span class="pl-c">#!/usr/bin/env python</span> <span class="pl-s1">__author__</span> <span class="pl-c1">=</span> <span class="pl-s">'zj'</span> <span class="pl-k">import</span> <span class="pl-s1">argparse</span> <span class="pl-k">import</span> <span class="pl-s1">os</span> <span class="pl-k">import</span> <span class="pl-s1">sys</span> <span class="pl-k">import</span> <span class="pl-s1">numpy</span> <span class="pl-k">as</span> <span class="pl-s1">np</span> <span class="pl-k">import</span> <span class="pl-s1">time</span> <span class="pl-k">try</span>: <span class="pl-k">import</span> <span class="pl-s1">better_exceptions</span> <span class="pl-k">except</span> <span class="pl-v">ImportError</span>: <span class="pl-k">pass</span> <span class="pl-k">import</span> <span class="pl-s1">tensorflow</span> <span class="pl-k">as</span> <span class="pl-s1">tf</span> <span class="pl-k">from</span> <span class="pl-s1">src</span>.<span class="pl-s1">model_ori</span> <span class="pl-k">import</span> <span class="pl-s1">crnn_fn</span> <span class="pl-k">from</span> <span class="pl-s1">src</span>.<span class="pl-s1">data_handler</span> <span class="pl-k">import</span> <span class="pl-s1">data_loader</span> <span class="pl-k">from</span> <span class="pl-s1">src</span>.<span class="pl-s1">config</span> <span class="pl-k">import</span> <span class="pl-v">Params</span>, <span class="pl-v">Alphabet</span> <span class="pl-k">from</span> <span class="pl-s1">src</span>.<span class="pl-s1">input_utils</span> <span class="pl-k">import</span> <span class="pl-s1">input_fn</span> <span class="pl-k">def</span> <span class="pl-en">main</span>(<span class="pl-s1">unused_argv</span>): <span class="pl-s1">models_path</span> <span class="pl-c1">=</span> <span class="pl-v">FLAGS</span>.<span class="pl-s1">input_model_dir</span> <span class="pl-k">if</span> <span class="pl-c1">not</span> <span class="pl-s1">os</span>.<span class="pl-s1">path</span>.<span class="pl-en">exists</span>(<span class="pl-s1">models_path</span>): <span class="pl-k">assert</span> <span class="pl-v">FileNotFoundError</span> <span class="pl-s1">models_list</span> <span class="pl-c1">=</span> [<span class="pl-s1">os</span>.<span class="pl-s1">path</span>.<span class="pl-en">join</span>(<span class="pl-s1">models_path</span>, <span class="pl-s1">x</span>[:<span class="pl-c1">-</span><span class="pl-c1">5</span>]) <span class="pl-k">for</span> <span class="pl-s1">x</span> <span class="pl-c1">in</span> <span class="pl-s1">os</span>.<span class="pl-en">listdir</span>(<span class="pl-s1">models_path</span>) <span class="pl-k">if</span> <span class="pl-s1">x</span>.<span class="pl-en">endswith</span>(<span class="pl-s">'.meta'</span>)] <span class="pl-k">if</span> <span class="pl-c1">not</span> <span class="pl-s1">os</span>.<span class="pl-s1">path</span>.<span class="pl-en">exists</span>(<span class="pl-v">FLAGS</span>.<span class="pl-s1">output_model_dir</span>): <span class="pl-s1">os</span>.<span class="pl-en">makedirs</span>(<span class="pl-v">FLAGS</span>.<span class="pl-s1">output_model_dir</span>) <span class="pl-s1">parameters</span> <span class="pl-c1">=</span> <span class="pl-v">Params</span>(<span class="pl-s1">eval_batch_size</span><span class="pl-c1">=</span><span class="pl-c1">128</span>, <span class="pl-s1">input_shape</span><span class="pl-c1">=</span>(<span class="pl-c1">32</span>, <span class="pl-c1">304</span>), <span class="pl-s1">digits_only</span><span class="pl-c1">=</span><span class="pl-c1">False</span>, <span class="pl-s1">alphabet</span><span class="pl-c1">=</span><span class="pl-v">Alphabet</span>.<span class="pl-v">CHINESECHAR_LETTERS_DIGITS_EXTENDED</span>, <span class="pl-s1">alphabet_decoding</span><span class="pl-c1">=</span><span class="pl-s">'same'</span>, <span class="pl-s1">image_channels</span><span class="pl-c1">=</span><span class="pl-c1">1</span>, <span class="pl-s1">csv_delimiter</span><span class="pl-c1">=</span><span class="pl-s">' '</span>, <span class="pl-s1">csv_files_eval</span><span class="pl-c1">=</span><span class="pl-v">FLAGS</span>.<span class="pl-s1">csv_files_eval</span>, <span class="pl-s1">output_model_dir</span><span class="pl-c1">=</span><span class="pl-v">FLAGS</span>.<span class="pl-s1">output_model_dir</span>, <span class="pl-s1">gpu</span><span class="pl-c1">=</span><span class="pl-v">FLAGS</span>.<span class="pl-s1">gpu</span> ) <span class="pl-s1">model_params</span> <span class="pl-c1">=</span> { <span class="pl-s">'Params'</span>: <span class="pl-s1">parameters</span>, } <span class="pl-s1">os</span>.<span class="pl-s1">environ</span>[<span class="pl-s">'CUDA_VISIBLE_DEVICES'</span>] <span class="pl-c1">=</span> <span class="pl-s1">parameters</span>.<span class="pl-s1">gpu</span> <span class="pl-s1">config_sess</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-v">ConfigProto</span>() <span class="pl-s1">config_sess</span>.<span class="pl-s1">gpu_options</span>.<span class="pl-s1">per_process_gpu_memory_fraction</span> <span class="pl-c1">=</span> <span class="pl-c1">0.6</span> <span class="pl-c"># Config estimator</span> <span class="pl-s1">est_config</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">estimator</span>.<span class="pl-v">RunConfig</span>() <span class="pl-s1">est_config</span> <span class="pl-c1">=</span> <span class="pl-s1">est_config</span>.<span class="pl-en">replace</span>(<span class="pl-s1">session_config</span><span class="pl-c1">=</span><span class="pl-s1">config_sess</span>, <span class="pl-s1">save_summary_steps</span><span class="pl-c1">=</span><span class="pl-c1">100</span>, <span class="pl-s1">model_dir</span><span class="pl-c1">=</span><span class="pl-s1">parameters</span>.<span class="pl-s1">output_model_dir</span>) <span class="pl-s1">estimator</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">estimator</span>.<span class="pl-v">Estimator</span>(<span class="pl-s1">model_fn</span><span class="pl-c1">=</span><span class="pl-s1">crnn_fn</span>, <span class="pl-s1">params</span><span class="pl-c1">=</span><span class="pl-s1">model_params</span>, <span class="pl-s1">config</span><span class="pl-c1">=</span><span class="pl-s1">est_config</span>, <span class="pl-s1">model_dir</span><span class="pl-c1">=</span><span class="pl-s1">parameters</span>.<span class="pl-s1">output_model_dir</span>, ) <span class="pl-k">try</span>: <span class="pl-k">with</span> <span class="pl-en">open</span>(<span class="pl-v">FLAGS</span>.<span class="pl-s1">output_file</span>, <span class="pl-s1">encoding</span><span class="pl-c1">=</span><span class="pl-s">'utf-8'</span>, <span class="pl-s1">mode</span><span class="pl-c1">=</span><span class="pl-s">'w'</span>) <span class="pl-k">as</span> <span class="pl-s1">save_file</span>: <span class="pl-k">for</span> <span class="pl-s1">model</span> <span class="pl-c1">in</span> <span class="pl-s1">models_list</span>: <span class="pl-s1">start</span> <span class="pl-c1">=</span> <span class="pl-s1">time</span>.<span class="pl-en">time</span>() <span class="pl-s1">eval_results</span> <span class="pl-c1">=</span> <span class="pl-s1">estimator</span>.<span class="pl-en">evaluate</span>(<span class="pl-s1">input_fn</span><span class="pl-c1">=</span><span class="pl-en">data_loader</span>(<span class="pl-s1">csv_filename</span><span class="pl-c1">=</span><span class="pl-s1">parameters</span>.<span class="pl-s1">csv_files_eval</span>, <span class="pl-s1">params</span><span class="pl-c1">=</span><span class="pl-s1">parameters</span>, <span class="pl-s1">batch_size</span><span class="pl-c1">=</span><span class="pl-s1">parameters</span>.<span class="pl-s1">eval_batch_size</span>, <span class="pl-s1">num_epochs</span><span class="pl-c1">=</span><span class="pl-c1">1</span>), <span class="pl-s1">steps</span><span class="pl-c1">=</span><span class="pl-c1">3</span>, <span class="pl-s1">checkpoint_path</span><span class="pl-c1">=</span><span class="pl-s1">model</span>) <span class="pl-en">print</span>(<span class="pl-s">'time:'</span>,<span class="pl-s1">time</span>.<span class="pl-en">time</span>() <span class="pl-c1">-</span> <span class="pl-s1">start</span>) <span class="pl-en">print</span>(<span class="pl-s">'model: %s Evaluation results: %s'</span> <span class="pl-c1">%</span> (<span class="pl-s1">model</span>, <span class="pl-en">str</span>(<span class="pl-s1">eval_results</span>))) <span class="pl-s1">save_file</span>.<span class="pl-en">write</span>(<span class="pl-s1">model</span> <span class="pl-c1">+</span> <span class="pl-s">' '</span> <span class="pl-c1">+</span> <span class="pl-en">str</span>(<span class="pl-s1">eval_results</span>) <span class="pl-c1">+</span> <span class="pl-s">'<span class="pl-cce">\n</span>'</span>) <span class="pl-k">except</span> <span class="pl-v">KeyboardInterrupt</span>: <span class="pl-en">print</span>(<span class="pl-s">'Interrupted'</span>) <span class="pl-k">if</span> <span class="pl-s1">__name__</span> <span class="pl-c1">==</span> <span class="pl-s">'__main__'</span>: <span class="pl-s1">parser</span> <span class="pl-c1">=</span> <span class="pl-s1">argparse</span>.<span class="pl-v">ArgumentParser</span>() <span class="pl-s1">parser</span>.<span class="pl-en">add_argument</span>(<span class="pl-s">'-fe'</span>, <span class="pl-s">'--csv_files_eval'</span>, <span class="pl-s1">required</span><span class="pl-c1">=</span><span class="pl-c1">False</span>, <span class="pl-s1">type</span><span class="pl-c1">=</span><span class="pl-s1">str</span>, <span class="pl-s1">help</span><span class="pl-c1">=</span><span class="pl-s">'CSV filename for evaluation'</span>, <span class="pl-s1">nargs</span><span class="pl-c1">=</span><span class="pl-s">'*'</span>, <span class="pl-s1">default</span><span class="pl-c1">=</span>[<span class="pl-s">'E:/val1.csv'</span>]) <span class="pl-s1">parser</span>.<span class="pl-en">add_argument</span>(<span class="pl-s">'-o'</span>, <span class="pl-s">'--output_model_dir'</span>, <span class="pl-s1">required</span><span class="pl-c1">=</span><span class="pl-c1">False</span>, <span class="pl-s1">type</span><span class="pl-c1">=</span><span class="pl-s1">str</span>, <span class="pl-s1">help</span><span class="pl-c1">=</span><span class="pl-s">'Directory for output'</span>, <span class="pl-s1">default</span><span class="pl-c1">=</span><span class="pl-s">'models_vgg_100K_no_eval'</span>) <span class="pl-s1">parser</span>.<span class="pl-en">add_argument</span>(<span class="pl-s">'-m'</span>, <span class="pl-s">'--input_model_dir'</span>, <span class="pl-s1">required</span><span class="pl-c1">=</span><span class="pl-c1">False</span>, <span class="pl-s1">type</span><span class="pl-c1">=</span><span class="pl-s1">str</span>, <span class="pl-s1">help</span><span class="pl-c1">=</span><span class="pl-s">'Directory for output'</span>, <span class="pl-s1">default</span><span class="pl-c1">=</span><span class="pl-s">'model_test'</span>) <span class="pl-s1">parser</span>.<span class="pl-en">add_argument</span>(<span class="pl-s">'-g'</span>, <span class="pl-s">'--gpu'</span>, <span class="pl-s1">type</span><span class="pl-c1">=</span><span class="pl-s1">str</span>, <span class="pl-s1">help</span><span class="pl-c1">=</span><span class="pl-s">"GPU 0,1 or '' "</span>, <span class="pl-s1">default</span><span class="pl-c1">=</span><span class="pl-s">'0'</span>) <span class="pl-s1">parser</span>.<span class="pl-en">add_argument</span>(<span class="pl-s">'-of'</span>, <span class="pl-s">'--output_file'</span>, <span class="pl-s1">required</span><span class="pl-c1">=</span><span class="pl-c1">False</span>, <span class="pl-s1">type</span><span class="pl-c1">=</span><span class="pl-s1">str</span>, <span class="pl-s1">default</span><span class="pl-c1">=</span><span class="pl-s">'123.txt'</span>, <span class="pl-s1">help</span><span class="pl-c1">=</span><span class="pl-s">"the log output file"</span>) <span class="pl-s1">tf</span>.<span class="pl-s1">logging</span>.<span class="pl-en">set_verbosity</span>(<span class="pl-s1">tf</span>.<span class="pl-s1">logging</span>.<span class="pl-v">DEBUG</span>) <span class="pl-v">FLAGS</span>, <span class="pl-s1">unparsed</span> <span class="pl-c1">=</span> <span class="pl-s1">parser</span>.<span class="pl-en">parse_known_args</span>() <span class="pl-s1">tf</span>.<span class="pl-s1">app</span>.<span class="pl-en">run</span>(<span class="pl-s1">main</span><span class="pl-c1">=</span><span class="pl-s1">main</span>, <span class="pl-s1">argv</span><span class="pl-c1">=</span>[<span class="pl-s1">sys</span>.<span class="pl-s1">argv</span>[<span class="pl-c1">0</span>]] <span class="pl-c1">+</span> <span class="pl-s1">unparsed</span>)</pre></div> <p dir="auto"><code class="notranslate">data_loader</code> script</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="#!/usr/bin/env python import tensorflow as tf import numpy as np from .config import Params, CONST from typing import Tuple def data_loader(csv_filename: str, params: Params, batch_size: int = 128, data_augmentation: bool = False, num_epochs: int = None, image_summaries: bool = False): def input_fn(): # Choose case one csv file or list of csv files if not isinstance(csv_filename, list): filename_queue = tf.train.string_input_producer([csv_filename], num_epochs=num_epochs, name='filename_queue') elif isinstance(csv_filename, list): filename_queue = tf.train.string_input_producer(csv_filename, num_epochs=num_epochs, name='filename_queue') # Skip lines that have already been processed reader = tf.TextLineReader(name='CSV_Reader', skip_header_lines=0) key, value = reader.read(filename_queue, name='file_reading_op') default_line = [['None'], ['None']] path, label = tf.decode_csv(value, record_defaults=default_line, field_delim=params.csv_delimiter, name='csv_reading_op') image, img_width = image_reading(path, resized_size=params.input_shape, params=params, data_augmentation=data_augmentation, padding=True) to_batch = {'images': image, 'images_widths': img_width, 'filenames': path, 'labels': label} prepared_batch = tf.train.shuffle_batch(to_batch, batch_size=batch_size, min_after_dequeue=500, num_threads=15, capacity=4000, allow_smaller_final_batch=False, name='prepared_batch_queue') if image_summaries: tf.summary.image('input/image', prepared_batch.get('images'), max_outputs=1) tf.summary.text('input/labels', prepared_batch.get('labels')[:10]) tf.summary.text('input/widths', tf.as_string(prepared_batch.get('images_widths'))) return prepared_batch, prepared_batch.get('labels') return input_fn def image_reading(path: str, params: Params, resized_size: Tuple[int, int] = None, data_augmentation: bool = False, padding: bool = False) -&gt; Tuple[tf.Tensor, tf.Tensor]: # Read image image_content = tf.read_file(path, name='image_reader') image = tf.cond(tf.equal(tf.string_split([path], '.').values[1], tf.constant('jpg', dtype=tf.string)), true_fn=lambda: tf.image.decode_jpeg(image_content, channels=params.image_channels, try_recover_truncated=True), # TODO channels = 3 ? false_fn=lambda: tf.image.decode_png(image_content, channels=params.image_channels), name='image_decoding') # Data augmentation if data_augmentation: image = augment_data(image) # Padding if padding: with tf.name_scope('padding'): image, img_width = padding_inputs_width(image, resized_size, increment=CONST.DIMENSION_REDUCTION_W_POOLING) # Resize else: image = tf.image.resize_images(image, size=resized_size) img_width = tf.shape(image)[1] with tf.control_dependencies([tf.assert_equal(image.shape[:2], resized_size)]): return image, img_width def random_rotation(img: tf.Tensor, max_rotation: float = 0.1, crop: bool = True) -&gt; tf.Tensor: # from SeguinBe with tf.name_scope('RandomRotation'): rotation = tf.random_uniform([], -max_rotation, max_rotation) rotated_image = tf.contrib.image.rotate(img, rotation, interpolation='BILINEAR') if crop: rotation = tf.abs(rotation) original_shape = tf.shape(rotated_image)[:2] h, w = original_shape[0], original_shape[1] # see https://stackoverflow.com/questions/16702966/rotate-image-and-crop-out-black-borders for formulae old_l, old_s = tf.cond(h &gt; w, lambda: [h, w], lambda: [w, h]) old_l, old_s = tf.cast(old_l, tf.float32), tf.cast(old_s, tf.float32) new_l = (old_l * tf.cos(rotation) - old_s * tf.sin(rotation)) / tf.cos(2 * rotation) new_s = (old_s - tf.sin(rotation) * new_l) / tf.cos(rotation) new_h, new_w = tf.cond(h &gt; w, lambda: [new_l, new_s], lambda: [new_s, new_l]) new_h, new_w = tf.cast(new_h, tf.int32), tf.cast(new_w, tf.int32) bb_begin = tf.cast(tf.ceil((h - new_h) / 2), tf.int32), tf.cast(tf.ceil((w - new_w) / 2), tf.int32) rotated_image_crop = rotated_image[bb_begin[0]:h - bb_begin[0], bb_begin[1]:w - bb_begin[1], :] # If crop removes the entire image, keep the original image rotated_image = tf.cond(tf.equal(tf.size(rotated_image_crop), 0), true_fn=lambda: img, false_fn=lambda: rotated_image_crop) return rotated_image def random_padding(image: tf.Tensor, max_pad_w: int = 5, max_pad_h: int = 10) -&gt; tf.Tensor: w_pad = list(np.random.randint(0, max_pad_w, size=[2])) h_pad = list(np.random.randint(0, max_pad_h, size=[2])) paddings = [h_pad, w_pad, [0, 0]] return tf.pad(image, paddings, mode='REFLECT', name='random_padding') def augment_data(image: tf.Tensor) -&gt; tf.Tensor: with tf.name_scope('DataAugmentation'): # Random padding image = random_padding(image) image = tf.image.random_brightness(image, max_delta=0.1) image = tf.image.random_contrast(image, 0.5, 1.5) image = random_rotation(image, 0.05, crop=True) if image.shape[-1] &gt;= 3: image = tf.image.random_hue(image, 0.2) image = tf.image.random_saturation(image, 0.5, 1.5) return image def padding_inputs_width(image: tf.Tensor, target_shape: Tuple[int, int], increment: int) -&gt; Tuple[ tf.Tensor, tf.Tensor]: target_ratio = target_shape[1] / target_shape[0] # Compute ratio to keep the same ratio in new image and get the size of padding # necessary to have the final desired shape shape = tf.shape(image) # 计算宽高比 ratio = tf.divide(shape[1], shape[0], name='ratio') new_h = target_shape[0] new_w = tf.cast(tf.round((ratio * new_h) / increment) * increment, tf.int32) f1 = lambda: (new_w, ratio) f2 = lambda: (new_h, tf.constant(1.0, dtype=tf.float64)) new_w, ratio = tf.case({tf.greater(new_w, 0): f1, tf.less_equal(new_w, 0): f2}, default=f1, exclusive=True) target_w = target_shape[1] # Definitions for cases def pad_fn(): with tf.name_scope('mirror_padding'): pad = tf.subtract(target_w, new_w) img_resized = tf.image.resize_images(image, [new_h, new_w]) # Padding to have the desired width paddings = [[0, 0], [0, pad], [0, 0]] pad_image = tf.pad(img_resized, paddings, mode='SYMMETRIC', name=None) # Set manually the shape pad_image.set_shape([target_shape[0], target_shape[1], img_resized.get_shape()[2]]) return pad_image, (new_h, new_w) def replicate_fn(): with tf.name_scope('replication_padding'): img_resized = tf.image.resize_images(image, [new_h, new_w]) # If one symmetry is not enough to have a full width # Count number of replications needed n_replication = tf.cast(tf.ceil(target_shape[1] / new_w), tf.int32) img_replicated = tf.tile(img_resized, tf.stack([1, n_replication, 1])) pad_image = tf.image.crop_to_bounding_box(image=img_replicated, offset_height=0, offset_width=0, target_height=target_shape[0], target_width=target_shape[1]) # Set manually the shape pad_image.set_shape([target_shape[0], target_shape[1], img_resized.get_shape()[2]]) return pad_image, (new_h, new_w) def simple_resize(): with tf.name_scope('simple_resize'): img_resized = tf.image.resize_images(image, target_shape) img_resized.set_shape([target_shape[0], target_shape[1], img_resized.get_shape()[2]]) return img_resized, target_shape # 3 cases pad_image, (new_h, new_w) = tf.case( { # case 1 : new_w &gt;= target_w tf.logical_and(tf.greater_equal(ratio, target_ratio), tf.greater_equal(new_w, target_w)): simple_resize, # case 2 : new_w &gt;= target_w/2 &amp; new_w &lt; target_w &amp; ratio &lt; target_ratio tf.logical_and(tf.less(ratio, target_ratio), tf.logical_and(tf.greater_equal(new_w, tf.cast(tf.divide(target_w, 2), tf.int32)), tf.less(new_w, target_w))): pad_fn, # case 3 : new_w &lt; target_w/2 &amp; new_w &lt; target_w &amp; ratio &lt; target_ratio tf.logical_and(tf.less(ratio, target_ratio), tf.logical_and(tf.less(new_w, target_w), tf.less(new_w, tf.cast(tf.divide(target_w, 2), tf.int32)))): replicate_fn }, default=simple_resize, exclusive=True) return pad_image, new_w # new_w = image width used for computing sequence lengths def preprocess_image_for_prediction(fixed_height: int = 32, min_width: int = 8): &quot;&quot;&quot; Input function to use when exporting the model for making predictions (see estimator.export_savedmodel) :param fixed_height: height of the input image after resizing :param min_width: minimum width of image after resizing :return: &quot;&quot;&quot; def serving_input_fn(): # define placeholder for input image image = tf.placeholder(dtype=tf.float32, shape=[None, None, 1]) shape = tf.shape(image) # Assert shape is h x w x c with c = 1 ratio = tf.divide(shape[1], shape[0]) increment = CONST.DIMENSION_REDUCTION_W_POOLING new_width = tf.cast(tf.round((ratio * fixed_height) / increment) * increment, tf.int32) resized_image = tf.cond(new_width &lt; tf.constant(min_width, dtype=tf.int32), true_fn=lambda: tf.image.resize_images(image, size=(fixed_height, min_width)), false_fn=lambda: tf.image.resize_images(image, size=(fixed_height, new_width)) ) # Features to serve features = {'images': resized_image[None], # cast to 1 x h x w x c 'images_widths': new_width[None] # cast to tensor } # Inputs received receiver_inputs = {'images': image} return tf.estimator.export.ServingInputReceiver(features, receiver_inputs) return serving_input_fn"><pre class="notranslate"><span class="pl-c">#!/usr/bin/env python</span> <span class="pl-k">import</span> <span class="pl-s1">tensorflow</span> <span class="pl-k">as</span> <span class="pl-s1">tf</span> <span class="pl-k">import</span> <span class="pl-s1">numpy</span> <span class="pl-k">as</span> <span class="pl-s1">np</span> <span class="pl-k">from</span> .<span class="pl-s1">config</span> <span class="pl-k">import</span> <span class="pl-v">Params</span>, <span class="pl-v">CONST</span> <span class="pl-k">from</span> <span class="pl-s1">typing</span> <span class="pl-k">import</span> <span class="pl-v">Tuple</span> <span class="pl-k">def</span> <span class="pl-en">data_loader</span>(<span class="pl-s1">csv_filename</span>: <span class="pl-s1">str</span>, <span class="pl-s1">params</span>: <span class="pl-v">Params</span>, <span class="pl-s1">batch_size</span>: <span class="pl-s1">int</span> <span class="pl-c1">=</span> <span class="pl-c1">128</span>, <span class="pl-s1">data_augmentation</span>: <span class="pl-s1">bool</span> <span class="pl-c1">=</span> <span class="pl-c1">False</span>, <span class="pl-s1">num_epochs</span>: <span class="pl-s1">int</span> <span class="pl-c1">=</span> <span class="pl-c1">None</span>, <span class="pl-s1">image_summaries</span>: <span class="pl-s1">bool</span> <span class="pl-c1">=</span> <span class="pl-c1">False</span>): <span class="pl-k">def</span> <span class="pl-en">input_fn</span>(): <span class="pl-c"># Choose case one csv file or list of csv files</span> <span class="pl-k">if</span> <span class="pl-c1">not</span> <span class="pl-en">isinstance</span>(<span class="pl-s1">csv_filename</span>, <span class="pl-s1">list</span>): <span class="pl-s1">filename_queue</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">train</span>.<span class="pl-en">string_input_producer</span>([<span class="pl-s1">csv_filename</span>], <span class="pl-s1">num_epochs</span><span class="pl-c1">=</span><span class="pl-s1">num_epochs</span>, <span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-s">'filename_queue'</span>) <span class="pl-k">elif</span> <span class="pl-en">isinstance</span>(<span class="pl-s1">csv_filename</span>, <span class="pl-s1">list</span>): <span class="pl-s1">filename_queue</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">train</span>.<span class="pl-en">string_input_producer</span>(<span class="pl-s1">csv_filename</span>, <span class="pl-s1">num_epochs</span><span class="pl-c1">=</span><span class="pl-s1">num_epochs</span>, <span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-s">'filename_queue'</span>) <span class="pl-c"># Skip lines that have already been processed</span> <span class="pl-s1">reader</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-v">TextLineReader</span>(<span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-s">'CSV_Reader'</span>, <span class="pl-s1">skip_header_lines</span><span class="pl-c1">=</span><span class="pl-c1">0</span>) <span class="pl-s1">key</span>, <span class="pl-s1">value</span> <span class="pl-c1">=</span> <span class="pl-s1">reader</span>.<span class="pl-en">read</span>(<span class="pl-s1">filename_queue</span>, <span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-s">'file_reading_op'</span>) <span class="pl-s1">default_line</span> <span class="pl-c1">=</span> [[<span class="pl-s">'None'</span>], [<span class="pl-s">'None'</span>]] <span class="pl-s1">path</span>, <span class="pl-s1">label</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">decode_csv</span>(<span class="pl-s1">value</span>, <span class="pl-s1">record_defaults</span><span class="pl-c1">=</span><span class="pl-s1">default_line</span>, <span class="pl-s1">field_delim</span><span class="pl-c1">=</span><span class="pl-s1">params</span>.<span class="pl-s1">csv_delimiter</span>, <span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-s">'csv_reading_op'</span>) <span class="pl-s1">image</span>, <span class="pl-s1">img_width</span> <span class="pl-c1">=</span> <span class="pl-en">image_reading</span>(<span class="pl-s1">path</span>, <span class="pl-s1">resized_size</span><span class="pl-c1">=</span><span class="pl-s1">params</span>.<span class="pl-s1">input_shape</span>, <span class="pl-s1">params</span><span class="pl-c1">=</span><span class="pl-s1">params</span>, <span class="pl-s1">data_augmentation</span><span class="pl-c1">=</span><span class="pl-s1">data_augmentation</span>, <span class="pl-s1">padding</span><span class="pl-c1">=</span><span class="pl-c1">True</span>) <span class="pl-s1">to_batch</span> <span class="pl-c1">=</span> {<span class="pl-s">'images'</span>: <span class="pl-s1">image</span>, <span class="pl-s">'images_widths'</span>: <span class="pl-s1">img_width</span>, <span class="pl-s">'filenames'</span>: <span class="pl-s1">path</span>, <span class="pl-s">'labels'</span>: <span class="pl-s1">label</span>} <span class="pl-s1">prepared_batch</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">train</span>.<span class="pl-en">shuffle_batch</span>(<span class="pl-s1">to_batch</span>, <span class="pl-s1">batch_size</span><span class="pl-c1">=</span><span class="pl-s1">batch_size</span>, <span class="pl-s1">min_after_dequeue</span><span class="pl-c1">=</span><span class="pl-c1">500</span>, <span class="pl-s1">num_threads</span><span class="pl-c1">=</span><span class="pl-c1">15</span>, <span class="pl-s1">capacity</span><span class="pl-c1">=</span><span class="pl-c1">4000</span>, <span class="pl-s1">allow_smaller_final_batch</span><span class="pl-c1">=</span><span class="pl-c1">False</span>, <span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-s">'prepared_batch_queue'</span>) <span class="pl-k">if</span> <span class="pl-s1">image_summaries</span>: <span class="pl-s1">tf</span>.<span class="pl-s1">summary</span>.<span class="pl-en">image</span>(<span class="pl-s">'input/image'</span>, <span class="pl-s1">prepared_batch</span>.<span class="pl-en">get</span>(<span class="pl-s">'images'</span>), <span class="pl-s1">max_outputs</span><span class="pl-c1">=</span><span class="pl-c1">1</span>) <span class="pl-s1">tf</span>.<span class="pl-s1">summary</span>.<span class="pl-en">text</span>(<span class="pl-s">'input/labels'</span>, <span class="pl-s1">prepared_batch</span>.<span class="pl-en">get</span>(<span class="pl-s">'labels'</span>)[:<span class="pl-c1">10</span>]) <span class="pl-s1">tf</span>.<span class="pl-s1">summary</span>.<span class="pl-en">text</span>(<span class="pl-s">'input/widths'</span>, <span class="pl-s1">tf</span>.<span class="pl-en">as_string</span>(<span class="pl-s1">prepared_batch</span>.<span class="pl-en">get</span>(<span class="pl-s">'images_widths'</span>))) <span class="pl-k">return</span> <span class="pl-s1">prepared_batch</span>, <span class="pl-s1">prepared_batch</span>.<span class="pl-en">get</span>(<span class="pl-s">'labels'</span>) <span class="pl-k">return</span> <span class="pl-s1">input_fn</span> <span class="pl-k">def</span> <span class="pl-en">image_reading</span>(<span class="pl-s1">path</span>: <span class="pl-s1">str</span>, <span class="pl-s1">params</span>: <span class="pl-v">Params</span>, <span class="pl-s1">resized_size</span>: <span class="pl-v">Tuple</span>[<span class="pl-s1">int</span>, <span class="pl-s1">int</span>] <span class="pl-c1">=</span> <span class="pl-c1">None</span>, <span class="pl-s1">data_augmentation</span>: <span class="pl-s1">bool</span> <span class="pl-c1">=</span> <span class="pl-c1">False</span>, <span class="pl-s1">padding</span>: <span class="pl-s1">bool</span> <span class="pl-c1">=</span> <span class="pl-c1">False</span>) <span class="pl-c1">-&gt;</span> <span class="pl-v">Tuple</span>[<span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>, <span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>]: <span class="pl-c"># Read image</span> <span class="pl-s1">image_content</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">read_file</span>(<span class="pl-s1">path</span>, <span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-s">'image_reader'</span>) <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cond</span>(<span class="pl-s1">tf</span>.<span class="pl-en">equal</span>(<span class="pl-s1">tf</span>.<span class="pl-en">string_split</span>([<span class="pl-s1">path</span>], <span class="pl-s">'.'</span>).<span class="pl-s1">values</span>[<span class="pl-c1">1</span>], <span class="pl-s1">tf</span>.<span class="pl-en">constant</span>(<span class="pl-s">'jpg'</span>, <span class="pl-s1">dtype</span><span class="pl-c1">=</span><span class="pl-s1">tf</span>.<span class="pl-s1">string</span>)), <span class="pl-s1">true_fn</span><span class="pl-c1">=</span><span class="pl-k">lambda</span>: <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">decode_jpeg</span>(<span class="pl-s1">image_content</span>, <span class="pl-s1">channels</span><span class="pl-c1">=</span><span class="pl-s1">params</span>.<span class="pl-s1">image_channels</span>, <span class="pl-s1">try_recover_truncated</span><span class="pl-c1">=</span><span class="pl-c1">True</span>), <span class="pl-c"># TODO channels = 3 ?</span> <span class="pl-s1">false_fn</span><span class="pl-c1">=</span><span class="pl-k">lambda</span>: <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">decode_png</span>(<span class="pl-s1">image_content</span>, <span class="pl-s1">channels</span><span class="pl-c1">=</span><span class="pl-s1">params</span>.<span class="pl-s1">image_channels</span>), <span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-s">'image_decoding'</span>) <span class="pl-c"># Data augmentation</span> <span class="pl-k">if</span> <span class="pl-s1">data_augmentation</span>: <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-en">augment_data</span>(<span class="pl-s1">image</span>) <span class="pl-c"># Padding</span> <span class="pl-k">if</span> <span class="pl-s1">padding</span>: <span class="pl-k">with</span> <span class="pl-s1">tf</span>.<span class="pl-en">name_scope</span>(<span class="pl-s">'padding'</span>): <span class="pl-s1">image</span>, <span class="pl-s1">img_width</span> <span class="pl-c1">=</span> <span class="pl-en">padding_inputs_width</span>(<span class="pl-s1">image</span>, <span class="pl-s1">resized_size</span>, <span class="pl-s1">increment</span><span class="pl-c1">=</span><span class="pl-v">CONST</span>.<span class="pl-v">DIMENSION_REDUCTION_W_POOLING</span>) <span class="pl-c"># Resize</span> <span class="pl-k">else</span>: <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">resize_images</span>(<span class="pl-s1">image</span>, <span class="pl-s1">size</span><span class="pl-c1">=</span><span class="pl-s1">resized_size</span>) <span class="pl-s1">img_width</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">shape</span>(<span class="pl-s1">image</span>)[<span class="pl-c1">1</span>] <span class="pl-k">with</span> <span class="pl-s1">tf</span>.<span class="pl-en">control_dependencies</span>([<span class="pl-s1">tf</span>.<span class="pl-en">assert_equal</span>(<span class="pl-s1">image</span>.<span class="pl-s1">shape</span>[:<span class="pl-c1">2</span>], <span class="pl-s1">resized_size</span>)]): <span class="pl-k">return</span> <span class="pl-s1">image</span>, <span class="pl-s1">img_width</span> <span class="pl-k">def</span> <span class="pl-en">random_rotation</span>(<span class="pl-s1">img</span>: <span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>, <span class="pl-s1">max_rotation</span>: <span class="pl-s1">float</span> <span class="pl-c1">=</span> <span class="pl-c1">0.1</span>, <span class="pl-s1">crop</span>: <span class="pl-s1">bool</span> <span class="pl-c1">=</span> <span class="pl-c1">True</span>) <span class="pl-c1">-&gt;</span> <span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>: <span class="pl-c"># from SeguinBe</span> <span class="pl-k">with</span> <span class="pl-s1">tf</span>.<span class="pl-en">name_scope</span>(<span class="pl-s">'RandomRotation'</span>): <span class="pl-s1">rotation</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">random_uniform</span>([], <span class="pl-c1">-</span><span class="pl-s1">max_rotation</span>, <span class="pl-s1">max_rotation</span>) <span class="pl-s1">rotated_image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">contrib</span>.<span class="pl-s1">image</span>.<span class="pl-en">rotate</span>(<span class="pl-s1">img</span>, <span class="pl-s1">rotation</span>, <span class="pl-s1">interpolation</span><span class="pl-c1">=</span><span class="pl-s">'BILINEAR'</span>) <span class="pl-k">if</span> <span class="pl-s1">crop</span>: <span class="pl-s1">rotation</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">abs</span>(<span class="pl-s1">rotation</span>) <span class="pl-s1">original_shape</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">shape</span>(<span class="pl-s1">rotated_image</span>)[:<span class="pl-c1">2</span>] <span class="pl-s1">h</span>, <span class="pl-s1">w</span> <span class="pl-c1">=</span> <span class="pl-s1">original_shape</span>[<span class="pl-c1">0</span>], <span class="pl-s1">original_shape</span>[<span class="pl-c1">1</span>] <span class="pl-c"># see https://stackoverflow.com/questions/16702966/rotate-image-and-crop-out-black-borders for formulae</span> <span class="pl-s1">old_l</span>, <span class="pl-s1">old_s</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cond</span>(<span class="pl-s1">h</span> <span class="pl-c1">&gt;</span> <span class="pl-s1">w</span>, <span class="pl-k">lambda</span>: [<span class="pl-s1">h</span>, <span class="pl-s1">w</span>], <span class="pl-k">lambda</span>: [<span class="pl-s1">w</span>, <span class="pl-s1">h</span>]) <span class="pl-s1">old_l</span>, <span class="pl-s1">old_s</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">old_l</span>, <span class="pl-s1">tf</span>.<span class="pl-s1">float32</span>), <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">old_s</span>, <span class="pl-s1">tf</span>.<span class="pl-s1">float32</span>) <span class="pl-s1">new_l</span> <span class="pl-c1">=</span> (<span class="pl-s1">old_l</span> <span class="pl-c1">*</span> <span class="pl-s1">tf</span>.<span class="pl-en">cos</span>(<span class="pl-s1">rotation</span>) <span class="pl-c1">-</span> <span class="pl-s1">old_s</span> <span class="pl-c1">*</span> <span class="pl-s1">tf</span>.<span class="pl-en">sin</span>(<span class="pl-s1">rotation</span>)) <span class="pl-c1">/</span> <span class="pl-s1">tf</span>.<span class="pl-en">cos</span>(<span class="pl-c1">2</span> <span class="pl-c1">*</span> <span class="pl-s1">rotation</span>) <span class="pl-s1">new_s</span> <span class="pl-c1">=</span> (<span class="pl-s1">old_s</span> <span class="pl-c1">-</span> <span class="pl-s1">tf</span>.<span class="pl-en">sin</span>(<span class="pl-s1">rotation</span>) <span class="pl-c1">*</span> <span class="pl-s1">new_l</span>) <span class="pl-c1">/</span> <span class="pl-s1">tf</span>.<span class="pl-en">cos</span>(<span class="pl-s1">rotation</span>) <span class="pl-s1">new_h</span>, <span class="pl-s1">new_w</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cond</span>(<span class="pl-s1">h</span> <span class="pl-c1">&gt;</span> <span class="pl-s1">w</span>, <span class="pl-k">lambda</span>: [<span class="pl-s1">new_l</span>, <span class="pl-s1">new_s</span>], <span class="pl-k">lambda</span>: [<span class="pl-s1">new_s</span>, <span class="pl-s1">new_l</span>]) <span class="pl-s1">new_h</span>, <span class="pl-s1">new_w</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">new_h</span>, <span class="pl-s1">tf</span>.<span class="pl-s1">int32</span>), <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">new_w</span>, <span class="pl-s1">tf</span>.<span class="pl-s1">int32</span>) <span class="pl-s1">bb_begin</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">tf</span>.<span class="pl-en">ceil</span>((<span class="pl-s1">h</span> <span class="pl-c1">-</span> <span class="pl-s1">new_h</span>) <span class="pl-c1">/</span> <span class="pl-c1">2</span>), <span class="pl-s1">tf</span>.<span class="pl-s1">int32</span>), <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">tf</span>.<span class="pl-en">ceil</span>((<span class="pl-s1">w</span> <span class="pl-c1">-</span> <span class="pl-s1">new_w</span>) <span class="pl-c1">/</span> <span class="pl-c1">2</span>), <span class="pl-s1">tf</span>.<span class="pl-s1">int32</span>) <span class="pl-s1">rotated_image_crop</span> <span class="pl-c1">=</span> <span class="pl-s1">rotated_image</span>[<span class="pl-s1">bb_begin</span>[<span class="pl-c1">0</span>]:<span class="pl-s1">h</span> <span class="pl-c1">-</span> <span class="pl-s1">bb_begin</span>[<span class="pl-c1">0</span>], <span class="pl-s1">bb_begin</span>[<span class="pl-c1">1</span>]:<span class="pl-s1">w</span> <span class="pl-c1">-</span> <span class="pl-s1">bb_begin</span>[<span class="pl-c1">1</span>], :] <span class="pl-c"># If crop removes the entire image, keep the original image</span> <span class="pl-s1">rotated_image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cond</span>(<span class="pl-s1">tf</span>.<span class="pl-en">equal</span>(<span class="pl-s1">tf</span>.<span class="pl-en">size</span>(<span class="pl-s1">rotated_image_crop</span>), <span class="pl-c1">0</span>), <span class="pl-s1">true_fn</span><span class="pl-c1">=</span><span class="pl-k">lambda</span>: <span class="pl-s1">img</span>, <span class="pl-s1">false_fn</span><span class="pl-c1">=</span><span class="pl-k">lambda</span>: <span class="pl-s1">rotated_image_crop</span>) <span class="pl-k">return</span> <span class="pl-s1">rotated_image</span> <span class="pl-k">def</span> <span class="pl-en">random_padding</span>(<span class="pl-s1">image</span>: <span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>, <span class="pl-s1">max_pad_w</span>: <span class="pl-s1">int</span> <span class="pl-c1">=</span> <span class="pl-c1">5</span>, <span class="pl-s1">max_pad_h</span>: <span class="pl-s1">int</span> <span class="pl-c1">=</span> <span class="pl-c1">10</span>) <span class="pl-c1">-&gt;</span> <span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>: <span class="pl-s1">w_pad</span> <span class="pl-c1">=</span> <span class="pl-en">list</span>(<span class="pl-s1">np</span>.<span class="pl-s1">random</span>.<span class="pl-en">randint</span>(<span class="pl-c1">0</span>, <span class="pl-s1">max_pad_w</span>, <span class="pl-s1">size</span><span class="pl-c1">=</span>[<span class="pl-c1">2</span>])) <span class="pl-s1">h_pad</span> <span class="pl-c1">=</span> <span class="pl-en">list</span>(<span class="pl-s1">np</span>.<span class="pl-s1">random</span>.<span class="pl-en">randint</span>(<span class="pl-c1">0</span>, <span class="pl-s1">max_pad_h</span>, <span class="pl-s1">size</span><span class="pl-c1">=</span>[<span class="pl-c1">2</span>])) <span class="pl-s1">paddings</span> <span class="pl-c1">=</span> [<span class="pl-s1">h_pad</span>, <span class="pl-s1">w_pad</span>, [<span class="pl-c1">0</span>, <span class="pl-c1">0</span>]] <span class="pl-k">return</span> <span class="pl-s1">tf</span>.<span class="pl-en">pad</span>(<span class="pl-s1">image</span>, <span class="pl-s1">paddings</span>, <span class="pl-s1">mode</span><span class="pl-c1">=</span><span class="pl-s">'REFLECT'</span>, <span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-s">'random_padding'</span>) <span class="pl-k">def</span> <span class="pl-en">augment_data</span>(<span class="pl-s1">image</span>: <span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>) <span class="pl-c1">-&gt;</span> <span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>: <span class="pl-k">with</span> <span class="pl-s1">tf</span>.<span class="pl-en">name_scope</span>(<span class="pl-s">'DataAugmentation'</span>): <span class="pl-c"># Random padding</span> <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-en">random_padding</span>(<span class="pl-s1">image</span>) <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">random_brightness</span>(<span class="pl-s1">image</span>, <span class="pl-s1">max_delta</span><span class="pl-c1">=</span><span class="pl-c1">0.1</span>) <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">random_contrast</span>(<span class="pl-s1">image</span>, <span class="pl-c1">0.5</span>, <span class="pl-c1">1.5</span>) <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-en">random_rotation</span>(<span class="pl-s1">image</span>, <span class="pl-c1">0.05</span>, <span class="pl-s1">crop</span><span class="pl-c1">=</span><span class="pl-c1">True</span>) <span class="pl-k">if</span> <span class="pl-s1">image</span>.<span class="pl-s1">shape</span>[<span class="pl-c1">-</span><span class="pl-c1">1</span>] <span class="pl-c1">&gt;=</span> <span class="pl-c1">3</span>: <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">random_hue</span>(<span class="pl-s1">image</span>, <span class="pl-c1">0.2</span>) <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">random_saturation</span>(<span class="pl-s1">image</span>, <span class="pl-c1">0.5</span>, <span class="pl-c1">1.5</span>) <span class="pl-k">return</span> <span class="pl-s1">image</span> <span class="pl-k">def</span> <span class="pl-en">padding_inputs_width</span>(<span class="pl-s1">image</span>: <span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>, <span class="pl-s1">target_shape</span>: <span class="pl-v">Tuple</span>[<span class="pl-s1">int</span>, <span class="pl-s1">int</span>], <span class="pl-s1">increment</span>: <span class="pl-s1">int</span>) <span class="pl-c1">-&gt;</span> <span class="pl-v">Tuple</span>[ <span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>, <span class="pl-s1">tf</span>.<span class="pl-v">Tensor</span>]: <span class="pl-s1">target_ratio</span> <span class="pl-c1">=</span> <span class="pl-s1">target_shape</span>[<span class="pl-c1">1</span>] <span class="pl-c1">/</span> <span class="pl-s1">target_shape</span>[<span class="pl-c1">0</span>] <span class="pl-c"># Compute ratio to keep the same ratio in new image and get the size of padding</span> <span class="pl-c"># necessary to have the final desired shape</span> <span class="pl-s1">shape</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">shape</span>(<span class="pl-s1">image</span>) <span class="pl-c"># 计算宽高比</span> <span class="pl-s1">ratio</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">divide</span>(<span class="pl-s1">shape</span>[<span class="pl-c1">1</span>], <span class="pl-s1">shape</span>[<span class="pl-c1">0</span>], <span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-s">'ratio'</span>) <span class="pl-s1">new_h</span> <span class="pl-c1">=</span> <span class="pl-s1">target_shape</span>[<span class="pl-c1">0</span>] <span class="pl-s1">new_w</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">tf</span>.<span class="pl-en">round</span>((<span class="pl-s1">ratio</span> <span class="pl-c1">*</span> <span class="pl-s1">new_h</span>) <span class="pl-c1">/</span> <span class="pl-s1">increment</span>) <span class="pl-c1">*</span> <span class="pl-s1">increment</span>, <span class="pl-s1">tf</span>.<span class="pl-s1">int32</span>) <span class="pl-s1">f1</span> <span class="pl-c1">=</span> <span class="pl-k">lambda</span>: (<span class="pl-s1">new_w</span>, <span class="pl-s1">ratio</span>) <span class="pl-s1">f2</span> <span class="pl-c1">=</span> <span class="pl-k">lambda</span>: (<span class="pl-s1">new_h</span>, <span class="pl-s1">tf</span>.<span class="pl-en">constant</span>(<span class="pl-c1">1.0</span>, <span class="pl-s1">dtype</span><span class="pl-c1">=</span><span class="pl-s1">tf</span>.<span class="pl-s1">float64</span>)) <span class="pl-s1">new_w</span>, <span class="pl-s1">ratio</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">case</span>({<span class="pl-s1">tf</span>.<span class="pl-en">greater</span>(<span class="pl-s1">new_w</span>, <span class="pl-c1">0</span>): <span class="pl-s1">f1</span>, <span class="pl-s1">tf</span>.<span class="pl-en">less_equal</span>(<span class="pl-s1">new_w</span>, <span class="pl-c1">0</span>): <span class="pl-s1">f2</span>}, <span class="pl-s1">default</span><span class="pl-c1">=</span><span class="pl-s1">f1</span>, <span class="pl-s1">exclusive</span><span class="pl-c1">=</span><span class="pl-c1">True</span>) <span class="pl-s1">target_w</span> <span class="pl-c1">=</span> <span class="pl-s1">target_shape</span>[<span class="pl-c1">1</span>] <span class="pl-c"># Definitions for cases</span> <span class="pl-k">def</span> <span class="pl-en">pad_fn</span>(): <span class="pl-k">with</span> <span class="pl-s1">tf</span>.<span class="pl-en">name_scope</span>(<span class="pl-s">'mirror_padding'</span>): <span class="pl-s1">pad</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">subtract</span>(<span class="pl-s1">target_w</span>, <span class="pl-s1">new_w</span>) <span class="pl-s1">img_resized</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">resize_images</span>(<span class="pl-s1">image</span>, [<span class="pl-s1">new_h</span>, <span class="pl-s1">new_w</span>]) <span class="pl-c"># Padding to have the desired width</span> <span class="pl-s1">paddings</span> <span class="pl-c1">=</span> [[<span class="pl-c1">0</span>, <span class="pl-c1">0</span>], [<span class="pl-c1">0</span>, <span class="pl-s1">pad</span>], [<span class="pl-c1">0</span>, <span class="pl-c1">0</span>]] <span class="pl-s1">pad_image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">pad</span>(<span class="pl-s1">img_resized</span>, <span class="pl-s1">paddings</span>, <span class="pl-s1">mode</span><span class="pl-c1">=</span><span class="pl-s">'SYMMETRIC'</span>, <span class="pl-s1">name</span><span class="pl-c1">=</span><span class="pl-c1">None</span>) <span class="pl-c"># Set manually the shape</span> <span class="pl-s1">pad_image</span>.<span class="pl-en">set_shape</span>([<span class="pl-s1">target_shape</span>[<span class="pl-c1">0</span>], <span class="pl-s1">target_shape</span>[<span class="pl-c1">1</span>], <span class="pl-s1">img_resized</span>.<span class="pl-en">get_shape</span>()[<span class="pl-c1">2</span>]]) <span class="pl-k">return</span> <span class="pl-s1">pad_image</span>, (<span class="pl-s1">new_h</span>, <span class="pl-s1">new_w</span>) <span class="pl-k">def</span> <span class="pl-en">replicate_fn</span>(): <span class="pl-k">with</span> <span class="pl-s1">tf</span>.<span class="pl-en">name_scope</span>(<span class="pl-s">'replication_padding'</span>): <span class="pl-s1">img_resized</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">resize_images</span>(<span class="pl-s1">image</span>, [<span class="pl-s1">new_h</span>, <span class="pl-s1">new_w</span>]) <span class="pl-c"># If one symmetry is not enough to have a full width</span> <span class="pl-c"># Count number of replications needed</span> <span class="pl-s1">n_replication</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">tf</span>.<span class="pl-en">ceil</span>(<span class="pl-s1">target_shape</span>[<span class="pl-c1">1</span>] <span class="pl-c1">/</span> <span class="pl-s1">new_w</span>), <span class="pl-s1">tf</span>.<span class="pl-s1">int32</span>) <span class="pl-s1">img_replicated</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">tile</span>(<span class="pl-s1">img_resized</span>, <span class="pl-s1">tf</span>.<span class="pl-en">stack</span>([<span class="pl-c1">1</span>, <span class="pl-s1">n_replication</span>, <span class="pl-c1">1</span>])) <span class="pl-s1">pad_image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">crop_to_bounding_box</span>(<span class="pl-s1">image</span><span class="pl-c1">=</span><span class="pl-s1">img_replicated</span>, <span class="pl-s1">offset_height</span><span class="pl-c1">=</span><span class="pl-c1">0</span>, <span class="pl-s1">offset_width</span><span class="pl-c1">=</span><span class="pl-c1">0</span>, <span class="pl-s1">target_height</span><span class="pl-c1">=</span><span class="pl-s1">target_shape</span>[<span class="pl-c1">0</span>], <span class="pl-s1">target_width</span><span class="pl-c1">=</span><span class="pl-s1">target_shape</span>[<span class="pl-c1">1</span>]) <span class="pl-c"># Set manually the shape</span> <span class="pl-s1">pad_image</span>.<span class="pl-en">set_shape</span>([<span class="pl-s1">target_shape</span>[<span class="pl-c1">0</span>], <span class="pl-s1">target_shape</span>[<span class="pl-c1">1</span>], <span class="pl-s1">img_resized</span>.<span class="pl-en">get_shape</span>()[<span class="pl-c1">2</span>]]) <span class="pl-k">return</span> <span class="pl-s1">pad_image</span>, (<span class="pl-s1">new_h</span>, <span class="pl-s1">new_w</span>) <span class="pl-k">def</span> <span class="pl-en">simple_resize</span>(): <span class="pl-k">with</span> <span class="pl-s1">tf</span>.<span class="pl-en">name_scope</span>(<span class="pl-s">'simple_resize'</span>): <span class="pl-s1">img_resized</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">resize_images</span>(<span class="pl-s1">image</span>, <span class="pl-s1">target_shape</span>) <span class="pl-s1">img_resized</span>.<span class="pl-en">set_shape</span>([<span class="pl-s1">target_shape</span>[<span class="pl-c1">0</span>], <span class="pl-s1">target_shape</span>[<span class="pl-c1">1</span>], <span class="pl-s1">img_resized</span>.<span class="pl-en">get_shape</span>()[<span class="pl-c1">2</span>]]) <span class="pl-k">return</span> <span class="pl-s1">img_resized</span>, <span class="pl-s1">target_shape</span> <span class="pl-c"># 3 cases</span> <span class="pl-s1">pad_image</span>, (<span class="pl-s1">new_h</span>, <span class="pl-s1">new_w</span>) <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">case</span>( { <span class="pl-c"># case 1 : new_w &gt;= target_w</span> <span class="pl-s1">tf</span>.<span class="pl-en">logical_and</span>(<span class="pl-s1">tf</span>.<span class="pl-en">greater_equal</span>(<span class="pl-s1">ratio</span>, <span class="pl-s1">target_ratio</span>), <span class="pl-s1">tf</span>.<span class="pl-en">greater_equal</span>(<span class="pl-s1">new_w</span>, <span class="pl-s1">target_w</span>)): <span class="pl-s1">simple_resize</span>, <span class="pl-c"># case 2 : new_w &gt;= target_w/2 &amp; new_w &lt; target_w &amp; ratio &lt; target_ratio</span> <span class="pl-s1">tf</span>.<span class="pl-en">logical_and</span>(<span class="pl-s1">tf</span>.<span class="pl-en">less</span>(<span class="pl-s1">ratio</span>, <span class="pl-s1">target_ratio</span>), <span class="pl-s1">tf</span>.<span class="pl-en">logical_and</span>(<span class="pl-s1">tf</span>.<span class="pl-en">greater_equal</span>(<span class="pl-s1">new_w</span>, <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">tf</span>.<span class="pl-en">divide</span>(<span class="pl-s1">target_w</span>, <span class="pl-c1">2</span>), <span class="pl-s1">tf</span>.<span class="pl-s1">int32</span>)), <span class="pl-s1">tf</span>.<span class="pl-en">less</span>(<span class="pl-s1">new_w</span>, <span class="pl-s1">target_w</span>))): <span class="pl-s1">pad_fn</span>, <span class="pl-c"># case 3 : new_w &lt; target_w/2 &amp; new_w &lt; target_w &amp; ratio &lt; target_ratio</span> <span class="pl-s1">tf</span>.<span class="pl-en">logical_and</span>(<span class="pl-s1">tf</span>.<span class="pl-en">less</span>(<span class="pl-s1">ratio</span>, <span class="pl-s1">target_ratio</span>), <span class="pl-s1">tf</span>.<span class="pl-en">logical_and</span>(<span class="pl-s1">tf</span>.<span class="pl-en">less</span>(<span class="pl-s1">new_w</span>, <span class="pl-s1">target_w</span>), <span class="pl-s1">tf</span>.<span class="pl-en">less</span>(<span class="pl-s1">new_w</span>, <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">tf</span>.<span class="pl-en">divide</span>(<span class="pl-s1">target_w</span>, <span class="pl-c1">2</span>), <span class="pl-s1">tf</span>.<span class="pl-s1">int32</span>)))): <span class="pl-s1">replicate_fn</span> }, <span class="pl-s1">default</span><span class="pl-c1">=</span><span class="pl-s1">simple_resize</span>, <span class="pl-s1">exclusive</span><span class="pl-c1">=</span><span class="pl-c1">True</span>) <span class="pl-k">return</span> <span class="pl-s1">pad_image</span>, <span class="pl-s1">new_w</span> <span class="pl-c"># new_w = image width used for computing sequence lengths</span> <span class="pl-k">def</span> <span class="pl-en">preprocess_image_for_prediction</span>(<span class="pl-s1">fixed_height</span>: <span class="pl-s1">int</span> <span class="pl-c1">=</span> <span class="pl-c1">32</span>, <span class="pl-s1">min_width</span>: <span class="pl-s1">int</span> <span class="pl-c1">=</span> <span class="pl-c1">8</span>): <span class="pl-s">"""</span> <span class="pl-s"> Input function to use when exporting the model for making predictions (see estimator.export_savedmodel)</span> <span class="pl-s"> :param fixed_height: height of the input image after resizing</span> <span class="pl-s"> :param min_width: minimum width of image after resizing</span> <span class="pl-s"> :return:</span> <span class="pl-s"> """</span> <span class="pl-k">def</span> <span class="pl-en">serving_input_fn</span>(): <span class="pl-c"># define placeholder for input image</span> <span class="pl-s1">image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">placeholder</span>(<span class="pl-s1">dtype</span><span class="pl-c1">=</span><span class="pl-s1">tf</span>.<span class="pl-s1">float32</span>, <span class="pl-s1">shape</span><span class="pl-c1">=</span>[<span class="pl-c1">None</span>, <span class="pl-c1">None</span>, <span class="pl-c1">1</span>]) <span class="pl-s1">shape</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">shape</span>(<span class="pl-s1">image</span>) <span class="pl-c"># Assert shape is h x w x c with c = 1</span> <span class="pl-s1">ratio</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">divide</span>(<span class="pl-s1">shape</span>[<span class="pl-c1">1</span>], <span class="pl-s1">shape</span>[<span class="pl-c1">0</span>]) <span class="pl-s1">increment</span> <span class="pl-c1">=</span> <span class="pl-v">CONST</span>.<span class="pl-v">DIMENSION_REDUCTION_W_POOLING</span> <span class="pl-s1">new_width</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cast</span>(<span class="pl-s1">tf</span>.<span class="pl-en">round</span>((<span class="pl-s1">ratio</span> <span class="pl-c1">*</span> <span class="pl-s1">fixed_height</span>) <span class="pl-c1">/</span> <span class="pl-s1">increment</span>) <span class="pl-c1">*</span> <span class="pl-s1">increment</span>, <span class="pl-s1">tf</span>.<span class="pl-s1">int32</span>) <span class="pl-s1">resized_image</span> <span class="pl-c1">=</span> <span class="pl-s1">tf</span>.<span class="pl-en">cond</span>(<span class="pl-s1">new_width</span> <span class="pl-c1">&lt;</span> <span class="pl-s1">tf</span>.<span class="pl-en">constant</span>(<span class="pl-s1">min_width</span>, <span class="pl-s1">dtype</span><span class="pl-c1">=</span><span class="pl-s1">tf</span>.<span class="pl-s1">int32</span>), <span class="pl-s1">true_fn</span><span class="pl-c1">=</span><span class="pl-k">lambda</span>: <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">resize_images</span>(<span class="pl-s1">image</span>, <span class="pl-s1">size</span><span class="pl-c1">=</span>(<span class="pl-s1">fixed_height</span>, <span class="pl-s1">min_width</span>)), <span class="pl-s1">false_fn</span><span class="pl-c1">=</span><span class="pl-k">lambda</span>: <span class="pl-s1">tf</span>.<span class="pl-s1">image</span>.<span class="pl-en">resize_images</span>(<span class="pl-s1">image</span>, <span class="pl-s1">size</span><span class="pl-c1">=</span>(<span class="pl-s1">fixed_height</span>, <span class="pl-s1">new_width</span>)) ) <span class="pl-c"># Features to serve</span> <span class="pl-s1">features</span> <span class="pl-c1">=</span> {<span class="pl-s">'images'</span>: <span class="pl-s1">resized_image</span>[<span class="pl-c1">None</span>], <span class="pl-c"># cast to 1 x h x w x c</span> <span class="pl-s">'images_widths'</span>: <span class="pl-s1">new_width</span>[<span class="pl-c1">None</span>] <span class="pl-c"># cast to tensor</span> } <span class="pl-c"># Inputs received</span> <span class="pl-s1">receiver_inputs</span> <span class="pl-c1">=</span> {<span class="pl-s">'images'</span>: <span class="pl-s1">image</span>} <span class="pl-k">return</span> <span class="pl-s1">tf</span>.<span class="pl-s1">estimator</span>.<span class="pl-s1">export</span>.<span class="pl-v">ServingInputReceiver</span>(<span class="pl-s1">features</span>, <span class="pl-s1">receiver_inputs</span>) <span class="pl-k">return</span> <span class="pl-s1">serving_input_fn</span></pre></div> <p dir="auto">log<br> tensorflow1.4</p> <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="INFO:tensorflow:Using config: {'_model_dir': 'models_vgg_100K_no_eval', '_tf_random_seed': None, '_save_summary_steps': 100, '_save_checkpoints_steps': None, '_save_checkpoints_secs': 600, '_session_config': gpu_options { per_process_gpu_memory_fraction: 0.6 } , '_keep_checkpoint_max': 5, '_keep_checkpoint_every_n_hours': 10000, '_log_step_count_steps': 100, '_service': None, '_cluster_spec': &lt;tensorflow.python.training.server_lib.ClusterSpec object at 0x000002BAAA7A6780&gt;, '_task_type': 'worker', '_task_id': 0, '_master': '', '_is_chief': True, '_num_ps_replicas': 0, '_num_worker_replicas': 1} INFO:tensorflow:Starting evaluation at 2017-11-28-12:21:42 INFO:tensorflow:Restoring parameters from model_test\model.ckpt-54692 2017-11-28 20:22:04.720980: I C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\kernels\logging_ops.cc:79] * Loss : [0.236689657] INFO:tensorflow:Evaluation [1/3] 2017-11-28 20:28:32.360331: I C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\kernels\logging_ops.cc:79] * Loss : [0.238805175] INFO:tensorflow:Evaluation [2/3] 2017-11-28 20:35:41.020994: I C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\kernels\logging_ops.cc:79] * Loss : [0.237995088] INFO:tensorflow:Evaluation [3/3] INFO:tensorflow:Finished evaluation at 2017-11-28-12:43:21 INFO:tensorflow:Saving dict for global step 54692: eval/CER = 0.0108218, eval/accuracy = 0.929688, global_step = 54692, loss = 0.23783 time:1306.1133954524994 model: model_test\model.ckpt-54692 Evaluation results: {'eval/CER': 0.01082176, 'eval/accuracy': 0.9296875, 'loss': 0.23782997, 'global_step': 54692}"><pre class="notranslate">INFO:tensorflow:Using config: {<span class="pl-s"><span class="pl-pds">'</span>_model_dir<span class="pl-pds">'</span></span>: <span class="pl-s"><span class="pl-pds">'</span>models_vgg_100K_no_eval<span class="pl-pds">'</span></span>, <span class="pl-s"><span class="pl-pds">'</span>_tf_random_seed<span class="pl-pds">'</span></span>: None, <span class="pl-s"><span class="pl-pds">'</span>_save_summary_steps<span class="pl-pds">'</span></span>: 100, <span class="pl-s"><span class="pl-pds">'</span>_save_checkpoints_steps<span class="pl-pds">'</span></span>: None, <span class="pl-s"><span class="pl-pds">'</span>_save_checkpoints_secs<span class="pl-pds">'</span></span>: 600, <span class="pl-s"><span class="pl-pds">'</span>_session_config<span class="pl-pds">'</span></span>: gpu_options { per_process_gpu_memory_fraction: 0.6 } , <span class="pl-s"><span class="pl-pds">'</span>_keep_checkpoint_max<span class="pl-pds">'</span></span>: 5, <span class="pl-s"><span class="pl-pds">'</span>_keep_checkpoint_every_n_hours<span class="pl-pds">'</span></span>: 10000, <span class="pl-s"><span class="pl-pds">'</span>_log_step_count_steps<span class="pl-pds">'</span></span>: 100, <span class="pl-s"><span class="pl-pds">'</span>_service<span class="pl-pds">'</span></span>: None, <span class="pl-s"><span class="pl-pds">'</span>_cluster_spec<span class="pl-pds">'</span></span>: <span class="pl-k">&lt;</span>tensorflow.python.training.server_lib.ClusterSpec object at 0x000002BAAA7A<span class="pl-k">6780&gt;</span>, <span class="pl-s"><span class="pl-pds">'</span>_task_type<span class="pl-pds">'</span></span>: <span class="pl-s"><span class="pl-pds">'</span>worker<span class="pl-pds">'</span></span>, <span class="pl-s"><span class="pl-pds">'</span>_task_id<span class="pl-pds">'</span></span>: 0, <span class="pl-s"><span class="pl-pds">'</span>_master<span class="pl-pds">'</span></span>: <span class="pl-s"><span class="pl-pds">'</span><span class="pl-pds">'</span></span>, <span class="pl-s"><span class="pl-pds">'</span>_is_chief<span class="pl-pds">'</span></span>: True, <span class="pl-s"><span class="pl-pds">'</span>_num_ps_replicas<span class="pl-pds">'</span></span>: 0, <span class="pl-s"><span class="pl-pds">'</span>_num_worker_replicas<span class="pl-pds">'</span></span>: 1} INFO:tensorflow:Starting evaluation at 2017-11-28-12:21:42 INFO:tensorflow:Restoring parameters from model_test<span class="pl-cce">\m</span>odel.ckpt-54692 2017-11-28 20:22:04.720980: I C:<span class="pl-cce">\t</span>f_jenkins<span class="pl-cce">\h</span>ome<span class="pl-cce">\w</span>orkspace<span class="pl-cce">\r</span>el-win<span class="pl-cce">\M\w</span>indows<span class="pl-cce">\P</span>Y<span class="pl-cce">\3</span>6<span class="pl-cce">\t</span>ensorflow<span class="pl-cce">\c</span>ore<span class="pl-cce">\k</span>ernels<span class="pl-cce">\l</span>ogging_ops.cc:79] <span class="pl-k">*</span> Loss <span class="pl-c1">:</span> [0.236689657] INFO:tensorflow:Evaluation [1/3] 2017-11-28 20:28:32.360331: I C:<span class="pl-cce">\t</span>f_jenkins<span class="pl-cce">\h</span>ome<span class="pl-cce">\w</span>orkspace<span class="pl-cce">\r</span>el-win<span class="pl-cce">\M\w</span>indows<span class="pl-cce">\P</span>Y<span class="pl-cce">\3</span>6<span class="pl-cce">\t</span>ensorflow<span class="pl-cce">\c</span>ore<span class="pl-cce">\k</span>ernels<span class="pl-cce">\l</span>ogging_ops.cc:79] <span class="pl-k">*</span> Loss <span class="pl-c1">:</span> [0.238805175] INFO:tensorflow:Evaluation [2/3] 2017-11-28 20:35:41.020994: I C:<span class="pl-cce">\t</span>f_jenkins<span class="pl-cce">\h</span>ome<span class="pl-cce">\w</span>orkspace<span class="pl-cce">\r</span>el-win<span class="pl-cce">\M\w</span>indows<span class="pl-cce">\P</span>Y<span class="pl-cce">\3</span>6<span class="pl-cce">\t</span>ensorflow<span class="pl-cce">\c</span>ore<span class="pl-cce">\k</span>ernels<span class="pl-cce">\l</span>ogging_ops.cc:79] <span class="pl-k">*</span> Loss <span class="pl-c1">:</span> [0.237995088] INFO:tensorflow:Evaluation [3/3] INFO:tensorflow:Finished evaluation at 2017-11-28-12:43:21 INFO:tensorflow:Saving dict <span class="pl-k">for</span> global step 54692: eval/CER = 0.0108218, eval/accuracy = 0.929688, global_step = 54692, loss = 0.23783 time:1306.1133954524994 model: model_test<span class="pl-cce">\m</span>odel.ckpt-54692 Evaluation results: {<span class="pl-s"><span class="pl-pds">'</span>eval/CER<span class="pl-pds">'</span></span>: 0.01082176, <span class="pl-s"><span class="pl-pds">'</span>eval/accuracy<span class="pl-pds">'</span></span>: 0.9296875, <span class="pl-s"><span class="pl-pds">'</span>loss<span class="pl-pds">'</span></span>: 0.23782997, <span class="pl-s"><span class="pl-pds">'</span>global_step<span class="pl-pds">'</span></span>: 54692}</pre></div> <p dir="auto">tensorflow 1.3</p> <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="INFO:tensorflow:Using config: {'_model_dir': 'models_vgg_100K_no_eval', '_tf_random_seed': 1, '_save_summary_steps': 100, '_save_checkpoints_secs': 600, '_save_checkpoints_steps': None, '_session_config': gpu_options { per_process_gpu_memory_fraction: 0.6 } , '_keep_checkpoint_max': 5, '_keep_checkpoint_every_n_hours': 10000, '_log_step_count_steps': 100} INFO:tensorflow:Starting evaluation at 2017-11-28-12:49:50 INFO:tensorflow:Restoring parameters from model_test\model.ckpt-54692 2017-11-28 20:50:12.841210: I C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\kernels\logging_ops.cc:79] * Loss : [0.17519826] INFO:tensorflow:Evaluation [1/3] 2017-11-28 20:51:03.366275: I C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\kernels\logging_ops.cc:79] * Loss : [0.2987892] INFO:tensorflow:Evaluation [2/3] 2017-11-28 20:51:49.843030: I C:\tf_jenkins\home\workspace\rel-win\M\windows\PY\36\tensorflow\core\kernels\logging_ops.cc:79] * Loss : [0.20660429] INFO:tensorflow:Evaluation [3/3] INFO:tensorflow:Finished evaluation at 2017-11-28-12:52:19 INFO:tensorflow:Saving dict for global step 54692: eval/CER = 0.01188, eval/accuracy = 0.924479, global_step = 54692, loss = 0.226864 time:157.26274514198303 model: model_test\model.ckpt-54692 Evaluation results: {'eval/CER': 0.011879961, 'eval/accuracy': 0.92447919, 'loss': 0.22686392, 'global_step': 54692}"><pre class="notranslate">INFO:tensorflow:Using config: {<span class="pl-s"><span class="pl-pds">'</span>_model_dir<span class="pl-pds">'</span></span>: <span class="pl-s"><span class="pl-pds">'</span>models_vgg_100K_no_eval<span class="pl-pds">'</span></span>, <span class="pl-s"><span class="pl-pds">'</span>_tf_random_seed<span class="pl-pds">'</span></span>: 1, <span class="pl-s"><span class="pl-pds">'</span>_save_summary_steps<span class="pl-pds">'</span></span>: 100, <span class="pl-s"><span class="pl-pds">'</span>_save_checkpoints_secs<span class="pl-pds">'</span></span>: 600, <span class="pl-s"><span class="pl-pds">'</span>_save_checkpoints_steps<span class="pl-pds">'</span></span>: None, <span class="pl-s"><span class="pl-pds">'</span>_session_config<span class="pl-pds">'</span></span>: gpu_options { per_process_gpu_memory_fraction: 0.6 } , <span class="pl-s"><span class="pl-pds">'</span>_keep_checkpoint_max<span class="pl-pds">'</span></span>: 5, <span class="pl-s"><span class="pl-pds">'</span>_keep_checkpoint_every_n_hours<span class="pl-pds">'</span></span>: 10000, <span class="pl-s"><span class="pl-pds">'</span>_log_step_count_steps<span class="pl-pds">'</span></span>: 100} INFO:tensorflow:Starting evaluation at 2017-11-28-12:49:50 INFO:tensorflow:Restoring parameters from model_test<span class="pl-cce">\m</span>odel.ckpt-54692 2017-11-28 20:50:12.841210: I C:<span class="pl-cce">\t</span>f_jenkins<span class="pl-cce">\h</span>ome<span class="pl-cce">\w</span>orkspace<span class="pl-cce">\r</span>el-win<span class="pl-cce">\M\w</span>indows<span class="pl-cce">\P</span>Y<span class="pl-cce">\3</span>6<span class="pl-cce">\t</span>ensorflow<span class="pl-cce">\c</span>ore<span class="pl-cce">\k</span>ernels<span class="pl-cce">\l</span>ogging_ops.cc:79] <span class="pl-k">*</span> Loss <span class="pl-c1">:</span> [0.17519826] INFO:tensorflow:Evaluation [1/3] 2017-11-28 20:51:03.366275: I C:<span class="pl-cce">\t</span>f_jenkins<span class="pl-cce">\h</span>ome<span class="pl-cce">\w</span>orkspace<span class="pl-cce">\r</span>el-win<span class="pl-cce">\M\w</span>indows<span class="pl-cce">\P</span>Y<span class="pl-cce">\3</span>6<span class="pl-cce">\t</span>ensorflow<span class="pl-cce">\c</span>ore<span class="pl-cce">\k</span>ernels<span class="pl-cce">\l</span>ogging_ops.cc:79] <span class="pl-k">*</span> Loss <span class="pl-c1">:</span> [0.2987892] INFO:tensorflow:Evaluation [2/3] 2017-11-28 20:51:49.843030: I C:<span class="pl-cce">\t</span>f_jenkins<span class="pl-cce">\h</span>ome<span class="pl-cce">\w</span>orkspace<span class="pl-cce">\r</span>el-win<span class="pl-cce">\M\w</span>indows<span class="pl-cce">\P</span>Y<span class="pl-cce">\3</span>6<span class="pl-cce">\t</span>ensorflow<span class="pl-cce">\c</span>ore<span class="pl-cce">\k</span>ernels<span class="pl-cce">\l</span>ogging_ops.cc:79] <span class="pl-k">*</span> Loss <span class="pl-c1">:</span> [0.20660429] INFO:tensorflow:Evaluation [3/3] INFO:tensorflow:Finished evaluation at 2017-11-28-12:52:19 INFO:tensorflow:Saving dict <span class="pl-k">for</span> global step 54692: eval/CER = 0.01188, eval/accuracy = 0.924479, global_step = 54692, loss = 0.226864 time:157.26274514198303 model: model_test<span class="pl-cce">\m</span>odel.ckpt-54692 Evaluation results: {<span class="pl-s"><span class="pl-pds">'</span>eval/CER<span class="pl-pds">'</span></span>: 0.011879961, <span class="pl-s"><span class="pl-pds">'</span>eval/accuracy<span class="pl-pds">'</span></span>: 0.92447919, <span class="pl-s"><span class="pl-pds">'</span>loss<span class="pl-pds">'</span></span>: 0.22686392, <span class="pl-s"><span class="pl-pds">'</span>global_step<span class="pl-pds">'</span></span>: 54692}</pre></div>
<p dir="auto"><em>Please make sure that this is a bug. As per our <a href="https://github.com/tensorflow/tensorflow/blob/master/ISSUES.md">GitHub Policy</a>, we only address code/doc bugs, performance issues, feature requests and build/installation issues on GitHub. tag:bug_template</em></p> <p dir="auto"><strong>System information</strong></p> <ul dir="auto"> <li> <p dir="auto">Have I written custom code (as opposed to using a stock example script provided in TensorFlow):</p> </li> <li> <p dir="auto">OS Platform and Distribution (e.g., Linux Ubuntu 16.04):</p> </li> </ul> <p dir="auto">Linux Ubuntu 16.04.3</p> <ul dir="auto"> <li>Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device:</li> <li>TensorFlow installed from (source or binary):</li> </ul> <p dir="auto">source</p> <ul dir="auto"> <li>TensorFlow version (use command below):</li> </ul> <p dir="auto">ToT</p> <ul dir="auto"> <li>Python version:</li> </ul> <p dir="auto">3.6</p> <ul dir="auto"> <li>Bazel version (if compiling from source):</li> </ul> <p dir="auto">19.04</p> <ul dir="auto"> <li>GCC/Compiler version (if compiling from source):</li> </ul> <p dir="auto">5.4.0</p> <ul dir="auto"> <li>CUDA/cuDNN version:</li> </ul> <p dir="auto">10.0/7.4</p> <ul dir="auto"> <li>GPU model and memory:</li> </ul> <p dir="auto">You can collect some of this information using our environment capture<br> <a href="https://github.com/tensorflow/tensorflow/tree/master/tools/tf_env_collect.sh">script</a><br> You can also obtain the TensorFlow version with: 1. TF 1.0: <code class="notranslate">python -c "import tensorflow as tf; print(tf.GIT_VERSION, tf.VERSION)"</code> 2. TF 2.0: <code class="notranslate">python -c "import tensorflow as tf; print(tf.version.GIT_VERSION, tf.version.VERSION)"</code></p> <p dir="auto"><strong>Describe the current behavior</strong></p> <p dir="auto">When XLA is off, the BERT compiles fine.</p> <p dir="auto"><strong>Describe the expected behavior</strong></p> <p dir="auto"><strong>Code to reproduce the issue</strong><br> Provide a reproducible test case that is the bare minimum necessary to generate the problem.</p> <p dir="auto">The following code pattern in the TF graph will expose the problem,</p> <p dir="auto">op0: Node "VarHandleOp"<br> op1: Node "Switch" op0, pred<br> op2: Node "ReadVariableOp" op0<br> op3: Node "ReadVariableOp" op1</p> <p dir="auto">Whem op2 and op3 are clustered together in XLA, the inputs op0 and op1 are<br> considered resource arguments, and they happen to map the the same resource<br> op0, and lead to the error "Duplicate variable passed to XLA cluster" reported at<br> line 135, xla_launch_util.cc.</p> <p dir="auto">I am worarounding the problem by placing constraint on clustable nodes in<br> mark_for_compilation_pass.cc, so that nodes with resource input from a "Switch"<br> node be rejected for clustering. Some people suggest that it may be better to fix<br> the problem where the problem is reported.</p> <p dir="auto"><strong>Other info / logs</strong><br> Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached.</p>
0
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> I have searched the <a href="https://github.com/zeit/next.js/issues?q=is%3Aissue">issues</a> of this repository and believe that this is not a duplicate.</li> </ul> <h2 dir="auto">Expected Behavior</h2> <p dir="auto">require relative path</p> <h2 dir="auto">Current Behavior</h2> <p dir="auto">require real path</p> <h2 dir="auto">Steps to Reproduce (for bugs)</h2> <ol dir="auto"> <li>import dynamic from 'next/dynamic';</li> <li>const DynamicToast = dynamic(import('../Toast/Model'))</li> <li>render </li> <li>next build</li> <li>I find this code in the build file</li> </ol> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="require(&quot;/Users/cui/code/bgt-next/.next/dist/&quot;+({0:&quot;chunks/components_Head_CommonDataGet_862fa71fb71bf2f9a1510bd6db4c2d86&quot;,1:&quot;chunks/components_Toast_Model_85c00f4ecc802eef46047a5e1de0328e&quot;}[t]||t)+&quot;-&quot;+{0:&quot;f0f24e5569d7ef5be482&quot;,1:&quot;4889637e50f9c8f8c305&quot;}[t]+&quot;.js&quot;),"><pre class="notranslate"><code class="notranslate">require("/Users/cui/code/bgt-next/.next/dist/"+({0:"chunks/components_Head_CommonDataGet_862fa71fb71bf2f9a1510bd6db4c2d86",1:"chunks/components_Toast_Model_85c00f4ecc802eef46047a5e1de0328e"}[t]||t)+"-"+{0:"f0f24e5569d7ef5be482",1:"4889637e50f9c8f8c305"}[t]+".js"), </code></pre></div> <h2 dir="auto">Context</h2> <h2 dir="auto">Your Environment</h2> <table role="table"> <thead> <tr> <th>Tech</th> <th>Version</th> </tr> </thead> <tbody> <tr> <td>next</td> <td>latest</td> </tr> <tr> <td>node</td> <td>8.10.1</td> </tr> <tr> <td>OS</td> <td>mac os 10.13.3</td> </tr> <tr> <td>browser</td> <td></td> </tr> <tr> <td>etc</td> <td></td> </tr> </tbody> </table>
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I have searched the <a href="https://github.com/zeit/next.js/issues">issues</a> of this repository and believe that this is not a duplicate.</li> </ul> <h2 dir="auto">Expected Behavior</h2> <p dir="auto">When I change javascript files inside node_modules folder, the related bundles should get recompiled.</p> <h2 dir="auto">Current Behavior</h2> <p dir="auto">I have to restart next server to get the javascript file inside node_modules recompiled.</p> <h2 dir="auto">Context</h2> <p dir="auto">I'm sure that webpack watch mode and webpack-dev-middleware have support for recompile bundle whenever any related javascript file changes, but it looks like next disables that and use watcher of itself instead.</p> <p dir="auto">This behaviour makes debug by tweak code in node_modules very painful.</p> <h2 dir="auto">Your Environment</h2> <table role="table"> <thead> <tr> <th>Tech</th> <th>Version</th> </tr> </thead> <tbody> <tr> <td>next</td> <td>4.1.3</td> </tr> <tr> <td>node</td> <td>8.5</td> </tr> <tr> <td>OS</td> <td>MacOS</td> </tr> <tr> <td>browser</td> <td>any</td> </tr> <tr> <td>etc</td> <td></td> </tr> </tbody> </table>
0
<p dir="auto"><strong>How to get the current entry point's name from within a loader?</strong></p> <p dir="auto">It is needed for a customized <code class="notranslate">file-loader</code> that uses <code class="notranslate">loaderUtils.interpolateName</code> by default which obviously interpolates the <code class="notranslate">[name]</code> to the currently required file name.</p> <p dir="auto">In <code class="notranslate">extract-text-webpack-plugin</code> the <code class="notranslate">[name]</code> is interpolated to the <strong>entry point name</strong> and that's what I'm for in the customized <code class="notranslate">file-loader</code> <em>(the purpose of which is to aid in toggling source-maps for <code class="notranslate">.less</code> files depending on current environment)</em></p> <p dir="auto">Hence the question. Thanks.</p>
<p dir="auto">If I have a entry <code class="notranslate">hello.js</code> like this:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="require('./images/test.png');"><pre class="notranslate"><code class="notranslate">require('./images/test.png'); </code></pre></div> <p dir="auto">and I use <code class="notranslate">file-loader</code> to handle this, then I want the built image named as "hello.test.png",how can I make it?</p> <p dir="auto">The following example can not fill my need:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="{ test: /\.(jpe?g|png|gif|svg)$/i, loaders: ['file?hash=sha512&amp;digest=hex&amp;name=[path][hash].[ext]'] }"><pre class="notranslate"><code class="notranslate">{ test: /\.(jpe?g|png|gif|svg)$/i, loaders: ['file?hash=sha512&amp;digest=hex&amp;name=[path][hash].[ext]'] } </code></pre></div>
1
<h5 dir="auto">ISSUE TYPE</h5> <ul dir="auto"> <li>Bug Report</li> </ul> <h5 dir="auto">COMPONENT NAME</h5> <p dir="auto">ec2_instance_facts</p> <h5 dir="auto">ANSIBLE VERSION</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ansible 2.4.0.0 config file = /etc/ansible/ansible.cfg configured module search path = [u'/home/jjabs/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules'] ansible python module location = /usr/lib/python2.7/site-packages/ansible executable location = /usr/bin/ansible python version = 2.7.13 (default, Jul 21 2017, 03:24:34) [GCC 7.1.1 20170630]"><pre class="notranslate"><code class="notranslate">ansible 2.4.0.0 config file = /etc/ansible/ansible.cfg configured module search path = [u'/home/jjabs/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules'] ansible python module location = /usr/lib/python2.7/site-packages/ansible executable location = /usr/bin/ansible python version = 2.7.13 (default, Jul 21 2017, 03:24:34) [GCC 7.1.1 20170630] </code></pre></div> <h5 dir="auto">CONFIGURATION</h5> <p dir="auto">DEFAULT_CALLBACK_WHITELIST(/etc/ansible/ansible.cfg) = ['profile_tasks']<br> DEFAULT_LOG_PATH(/etc/ansible/ansible.cfg) = /var/log/ansible.log<br> HOST_KEY_CHECKING(/etc/ansible/ansible.cfg) = False</p> <h5 dir="auto">OS / ENVIRONMENT</h5> <p dir="auto">Manjaro 17</p> <h5 dir="auto">SUMMARY</h5> <p dir="auto">ec2_remote_facts deliver the instance tags as expected.<br> The new module which should replace it (ec2_instance_facts) do not show instance tags.<br> Easy to reproduce since you can easily switch the module name and use the same params.</p> <h5 dir="auto">STEPS TO REPRODUCE</h5> <p dir="auto">get_ec2_facts.yml</p> <div class="highlight highlight-source-yaml notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="--- - ec2_instance_facts: region: &quot;your-region&quot; aws_access_key: &quot;your-key&quot; aws_secret_key: &quot;your-secret-key&quot; filters: instance-state-name: running &quot;tag:Name&quot;: &quot;your-instance-name&quot; register: ec2_facts"><pre class="notranslate">--- - <span class="pl-ent">ec2_instance_facts</span>: <span class="pl-ent">region</span>: <span class="pl-s"><span class="pl-pds">"</span>your-region<span class="pl-pds">"</span></span> <span class="pl-ent">aws_access_key</span>: <span class="pl-s"><span class="pl-pds">"</span>your-key<span class="pl-pds">"</span></span> <span class="pl-ent">aws_secret_key</span>: <span class="pl-s"><span class="pl-pds">"</span>your-secret-key<span class="pl-pds">"</span></span> <span class="pl-ent">filters</span>: <span class="pl-ent">instance-state-name</span>: <span class="pl-s">running</span> <span class="pl-s"><span class="pl-pds">"</span><span class="pl-ent">tag:Name</span><span class="pl-pds">"</span></span>: <span class="pl-s"><span class="pl-pds">"</span>your-instance-name<span class="pl-pds">"</span></span> <span class="pl-ent">register</span>: <span class="pl-s">ec2_facts</span></pre></div> <h5 dir="auto">EXPECTED RESULTS</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ok: [localhost] =&gt; { &quot;ec2_facts&quot;: { .... bla bla bla }, &quot;tags&quot;: { &quot;key&quot;: &quot;value&quot;, &quot;foo&quot;: &quot;bar&quot; }, } ] } "><pre class="notranslate"><code class="notranslate">ok: [localhost] =&gt; { "ec2_facts": { .... bla bla bla }, "tags": { "key": "value", "foo": "bar" }, } ] } </code></pre></div> <h5 dir="auto">ACTUAL RESULTS</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ok: [localhost] =&gt; { &quot;ec2_facts&quot;: { .... bla bla bla }, &quot;tags&quot;: {}, } ] } "><pre class="notranslate"><code class="notranslate">ok: [localhost] =&gt; { "ec2_facts": { .... bla bla bla }, "tags": {}, } ] } </code></pre></div>
<p dir="auto">Synchronize module adds unwanted path fragment to rsync destination when multiple items used (with_items)</p> <p dir="auto">Part of task with synchronize action and with_items directive:</p> <div class="highlight highlight-source-yaml notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="- name: 'SOLR | Deploy cores configuration files for instances' synchronize: src=projects/{{project_name}}/core-conf/ dest=/opt/solr/home/cores/{{item.name}}/conf/ archive=yes delete=yes rsync_path=&quot;sudo rsync&quot; register: solrxml when: item.solr is defined and item.solr == 'present' with_items: instances tags: - solr - solr-conf - search"><pre class="notranslate">- <span class="pl-ent">name</span>: <span class="pl-s"><span class="pl-pds">'</span>SOLR | Deploy cores configuration files for instances<span class="pl-pds">'</span></span> <span class="pl-ent">synchronize</span>: <span class="pl-s">src=projects/{{project_name}}/core-conf/ dest=/opt/solr/home/cores/{{item.name}}/conf/ archive=yes delete=yes rsync_path="sudo rsync"</span> <span class="pl-ent">register</span>: <span class="pl-s">solrxml</span> <span class="pl-ent">when</span>: <span class="pl-s">item.solr is defined and item.solr == 'present'</span> <span class="pl-ent">with_items</span>: <span class="pl-s">instances</span> <span class="pl-ent">tags</span>: - <span class="pl-s">solr</span> - <span class="pl-s">solr-conf</span> - <span class="pl-s">search</span></pre></div> <p dir="auto">Got output:</p> <blockquote> <p dir="auto">TASK: [solr | SOLR | Deploy cores configuration files for instances] **********<br> &lt;127.0.0.1&gt; EXEC ['/bin/sh', '-c', 'mkdir -p $HOME/.ansible/tmp/ansible-1383930775.88-164589547782291 &amp;&amp; chmod a+rx $HOME/.ansible/tmp/ansible-1383930775.88-164589547782291 &amp;&amp; echo $HOME/.ansible/tmp/ansible-1383930775.88-164589547782291']<br> &lt;127.0.0.1&gt; PUT /tmp/tmp6nU_52 TO /home/xt/.ansible/tmp/ansible-1383930775.88-164589547782291/synchronize<br> &lt;127.0.0.1&gt; EXEC ['/bin/sh', '-c', '/usr/bin/env python /home/xt/.ansible/tmp/ansible-1383930775.88-164589547782291/synchronize; rm -rf /home/xt/.ansible/tmp/ansible-1383930775.88-164589547782291/ &gt;/dev/null 2&gt;&amp;1']<br> changed: [10.1.250.10] =&gt; (item={'autopull': 'present', 'cron': 'present', 'solr': 'present', 'name': 'dev', 'vhost': 'application', 'domains': 'dev.test.local', 'docroot': u'/var/www/dev', 'db': 'present', 'auth': 'present'}) =&gt; {"changed": true, "cmd": "rsync --delay-updates --compress --timeout=10 --delete-after --archive --rsh 'ssh -o StrictHostKeyChecking=no' --rsync-path 'sudo rsync' --out-format='&lt;&gt;%i %n%L' projects/test/core-conf/ vagrant@10.1.250.10:/opt/solr/home/cores/dev/conf/", "item": {"auth": "present", "autopull": "present", "cron": "present", "db": "present", "docroot": "/var/www/dev", "domains": "dev.test.local", "name": "dev", "solr": "present", "vhost": "application"}, "msg": ".d....og... ./\n.f....og... admin-extra.html\n.f....og... currency.xml\n.f....og... elevate.xml\n.f....og... mapping-FoldToASCII.txt\n.f....og... mapping-ISOLatin1Accent.txt\n.f....og... protwords.txt\n.f....og... schema.xml\n.f....og... schema_extra_fields.xml\n.f....og... schema_extra_types.xml\n.f....og... scripts.conf\n.f....og... solrconfig.xml\n.f....og... solrconfig_extra.xml\n.f....og... solrcore.properties\n.f....og... spellings.txt\n.f....og... stopwords.txt\n.f....og... synonyms.txt\n.d....og... lang/\n.f....og... lang/contractions_ca.txt\n.f....og... lang/contractions_fr.txt\n.f....og... lang/contractions_ga.txt\n.f....og... lang/contractions_it.txt\n.f....og... lang/hyphenations_ga.txt\n.f....og... lang/stemdict_nl.txt\n.f....og... lang/stoptags_ja.txt\n.f....og... lang/stopwords_ar.txt\n.f....og... lang/stopwords_bg.txt\n.f....og... lang/stopwords_ca.txt\n.f....og... lang/stopwords_cz.txt\n.f....og... lang/stopwords_da.txt\n.f....og... lang/stopwords_de.txt\n.f....og... lang/stopwords_el.txt\n.f....og... lang/stopwords_en.txt\n.f....og... lang/stopwords_es.txt\n.f....og... lang/stopwords_eu.txt\n.f....og... lang/stopwords_fa.txt\n.f....og... lang/stopwords_fi.txt\n.f....og... lang/stopwords_fr.txt\n.f....og... lang/stopwords_ga.txt\n.f....og... lang/stopwords_gl.txt\n.f....og... lang/stopwords_hi.txt\n.f....og... lang/stopwords_hu.txt\n.f....og... lang/stopwords_hy.txt\n.f....og... lang/stopwords_id.txt\n.f....og... lang/stopwords_it.txt\n.f....og... lang/stopwords_ja.txt\n.f....og... lang/stopwords_lv.txt\n.f....og... lang/stopwords_nl.txt\n.f....og... lang/stopwords_no.txt\n.f....og... lang/stopwords_pt.txt\n.f....og... lang/stopwords_ro.txt\n.f....og... lang/stopwords_ru.txt\n.f....og... lang/stopwords_sv.txt\n.f....og... lang/stopwords_th.txt\n.f....og... lang/stopwords_tr.txt\n.f....og... lang/userdict_ja.txt\n.d....og... velocity/\n.f....og... velocity/VM_global_library.vm\n.f....og... velocity/browse.vm\n.f....og... velocity/cluster.vm\n.f....og... velocity/clusterResults.vm\n.f....og... velocity/doc.vm\n.f....og... velocity/facet_fields.vm\n.f....og... velocity/facet_queries.vm\n.f....og... velocity/facet_ranges.vm\n.f....og... velocity/facets.vm\n.f....og... velocity/footer.vm\n.f....og... velocity/head.vm\n.f....og... velocity/header.vm\n.f....og... velocity/hit.vm\n.f....og... velocity/hitGrouped.vm\n.f....og... velocity/jquery.autocomplete.css\n.f....og... velocity/jquery.autocomplete.js\n.f....og... velocity/layout.vm\n.f....og... velocity/main.css\n.f....og... velocity/query.vm\n.f....og... velocity/querySpatial.vm\n.f....og... velocity/suggest.vm\n.f....og... velocity/tabs.vm\n.d....og... xslt/\n.f....og... xslt/example.xsl\n.f....og... xslt/example_atom.xsl\n.f....og... xslt/example_rss.xsl\n.f....og... xslt/luke.xsl\n.f....og... xslt/updateXml.xsl\n", "rc": 0}<br> &lt;127.0.0.1&gt; EXEC ['/bin/sh', '-c', 'mkdir -p $HOME/.ansible/tmp/ansible-1383930776.06-136953182056861 &amp;&amp; chmod a+rx $HOME/.ansible/tmp/ansible-1383930776.06-136953182056861 &amp;&amp; echo $HOME/.ansible/tmp/ansible-1383930776.06-136953182056861']<br> &lt;127.0.0.1&gt; PUT /tmp/tmpKJBXPa TO /home/xt/.ansible/tmp/ansible-1383930776.06-136953182056861/synchronize<br> &lt;127.0.0.1&gt; EXEC ['/bin/sh', '-c', '/usr/bin/env python /home/xt/.ansible/tmp/ansible-1383930776.06-136953182056861/synchronize; rm -rf /home/xt/.ansible/tmp/ansible-1383930776.06-136953182056861/ &gt;/dev/null 2&gt;&amp;1']<br> failed: [10.1.250.10] =&gt; (item={'autopull': 'absent', 'cron': 'absent', 'solr': 'present', 'name': 'stage', 'vhost': 'static', 'domains': 'stage.test.local stg.test.local', 'docroot': u'/var/www/stage/current', 'db': 'present', 'auth': 'present'}) =&gt; {"cmd": "rsync --delay-updates --compress --timeout=10 --delete-after --archive --rsh 'ssh -o StrictHostKeyChecking=no' --rsync-path 'sudo rsync' --out-format='&lt;&gt;%i %n%L' projects/test/core-conf/ vagrant@10.1.250.10:vagrant@10.1.250.10:/opt/solr/home/cores/dev/conf/", "failed": true, "item": {"auth": "present", "autopull": "absent", "cron": "absent", "db": "present", "docroot": "/var/www/stage/current", "domains": "stage.test.local stg.test.local", "name": "stage", "solr": "present", "vhost": "static"}, "rc": 12}<br> msg: rsync: mkdir "/home/vagrant/vagrant@10.1.250.10:/opt/solr/home/cores/dev/conf" failed: No such file or directory (2)<br> rsync error: error in file IO (code 11) at main.c(605) [Receiver=3.0.9]<br> rsync: connection unexpectedly closed (197 bytes received so far) [sender]<br> rsync error: error in rsync protocol data stream (code 12) at io.c(226) [sender=3.1.0]</p> </blockquote> <p dir="auto">Some of options got duplicated for second item</p> <p dir="auto">Ansible: v1.4 (devel)<br> Python: 2.7</p>
0
<p dir="auto">Hi<br> First I would like to point out that the documentation for WebXRManager has missing functions that are there in the source but not mentioned in the documentation. Not sure how you want to tackle this as in the source there is no comments about what these extra functions do. The webxr section could benefit of some more docu.</p> <p dir="auto">I was in the need of getting the fov of the AR camera when in immersive-ar mode in WebXR and stumbled upon WebXRManager.getCamera(). Some tutorial say that this is the AR/VR camera that is used.<br> On my phone it reports a fov of 50 always (once you enter AR mode). Which is not right. So what is this function supposed to do?</p> <p dir="auto">I ended up calculating the fov like so once a XRFrame was available.<br> Do you propose a different solution? You could add a function to WebXRManager that has the below code.<br> I dont know what the getCamera function does in VR mode, maybe it works but in AR mode i dont think it works as expected.</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" let ref= this.renderer.xr.getReferenceSpace(); let pose= frame.getViewerPose(ref); if (pose) { let fovi = pose.views[0].projectionMatrix[5]; const fov = Math.atan2(1, fovi) * 2 * 180 / Math.PI; console.log(fov); }"><pre class="notranslate"> <span class="pl-k">let</span> <span class="pl-s1">ref</span><span class="pl-c1">=</span> <span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">renderer</span><span class="pl-kos">.</span><span class="pl-c1">xr</span><span class="pl-kos">.</span><span class="pl-en">getReferenceSpace</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">let</span> <span class="pl-s1">pose</span><span class="pl-c1">=</span> <span class="pl-s1">frame</span><span class="pl-kos">.</span><span class="pl-en">getViewerPose</span><span class="pl-kos">(</span><span class="pl-s1">ref</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">if</span> <span class="pl-kos">(</span><span class="pl-s1">pose</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">let</span> <span class="pl-s1">fovi</span> <span class="pl-c1">=</span> <span class="pl-s1">pose</span><span class="pl-kos">.</span><span class="pl-c1">views</span><span class="pl-kos">[</span><span class="pl-c1">0</span><span class="pl-kos">]</span><span class="pl-kos">.</span><span class="pl-c1">projectionMatrix</span><span class="pl-kos">[</span><span class="pl-c1">5</span><span class="pl-kos">]</span><span class="pl-kos">;</span> <span class="pl-k">const</span> <span class="pl-s1">fov</span> <span class="pl-c1">=</span> <span class="pl-v">Math</span><span class="pl-kos">.</span><span class="pl-en">atan2</span><span class="pl-kos">(</span><span class="pl-c1">1</span><span class="pl-kos">,</span> <span class="pl-s1">fovi</span><span class="pl-kos">)</span> <span class="pl-c1">*</span> <span class="pl-c1">2</span> <span class="pl-c1">*</span> <span class="pl-c1">180</span> <span class="pl-c1">/</span> <span class="pl-v">Math</span><span class="pl-kos">.</span><span class="pl-c1">PI</span><span class="pl-kos">;</span> <span class="pl-smi">console</span><span class="pl-kos">.</span><span class="pl-en">log</span><span class="pl-kos">(</span><span class="pl-s1">fov</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span></pre></div> <p dir="auto">Thanks<br> Dimi</p>
<h5 dir="auto">Description of the problem</h5> <p dir="auto">The VR camera always returns a FOV of 50 degrees, which is not necessarily the actual FOV. Using Cardboard, for example, the field of view is a lot higher.</p> <p dir="auto">It can be tested in <a href="https://threejs.org/examples/webvr_cubes.html" rel="nofollow">this example</a> using the code:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="renderer.vr.getCamera(camera).fov"><pre class="notranslate"><span class="pl-s1">renderer</span><span class="pl-kos">.</span><span class="pl-c1">vr</span><span class="pl-kos">.</span><span class="pl-en">getCamera</span><span class="pl-kos">(</span><span class="pl-s1">camera</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-c1">fov</span></pre></div> <p dir="auto">If this value is not meant to be used (because the view is distorted rather differently from a regular perspective camera), maybe that property should return -1 to indicate this.</p> <h5 dir="auto">Three.js version</h5> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Dev</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> r88</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> ...</li> </ul> <h5 dir="auto">Browser</h5> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> All of them</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> Chrome</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Firefox</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Internet Explorer</li> </ul> <h5 dir="auto">OS</h5> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> All of them</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Windows</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> macOS</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> Linux</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Android</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> iOS</li> </ul> <h5 dir="auto">Hardware Requirements (graphics card, VR Device, ...)</h5> <p dir="auto">Used Cardboard. but the VR emulation extension for Chrome behaves the same way.</p>
1
<p dir="auto">**I pass variable "activeObject$" through input() option in component</p> <p dir="auto"><strong>Current behavior</strong><br> vendor.bundle.js:42872 EXCEPTION: Uncaught (in promise): Error: Error in ./BaseObjectReleasesPageComponent class BaseObjectReleasesPageComponent - inline template:170:43 caused by: Failed to execute 'setAttribute' on 'Element': 'ng-reflect-active-object$' is not a valid attribute name.<br> Error: Failed to execute 'setAttribute' on 'Element': 'ng-reflect-active-object$' is not a valid attribute name.<br> at DomRenderer.setElementAttribute (<a href="http://beta.prwire:4201/vendor.bundle.js:32057:31" rel="nofollow">http://beta.prwire:4201/vendor.bundle.js:32057:31</a>)<br> at DomRenderer.setBindingDebugInfo (<a href="http://beta.prwire:4201/vendor.bundle.js:32078:18" rel="nofollow">http://beta.prwire:4201/vendor.bundle.js:32078:18</a>)<br> at DebugDomRenderer.setBindingDebugInfo (<a href="http://beta.prwire:4201/vendor.bundle.js:59773:24" rel="nofollow">http://beta.prwire:4201/vendor.bundle.js:59773:24</a>)<br> at setBindingDebugInfo (<a href="http://beta.prwire:4201/vendor.bundle.js:19771:18" rel="nofollow">http://beta.prwire:4201/vendor.bundle.js:19771:18</a>)<br> at <a href="http://beta.prwire:4201/vendor.bundle.js:19763:9" rel="nofollow">http://beta.prwire:4201/vendor.bundle.js:19763:9</a><br> at Array.forEach (native)<br> at setBindingDebugInfoForChanges (<a href="http://beta.prwire:4201/vendor.bundle.js:19762:26" rel="nofollow">http://beta.prwire:4201/vendor.bundle.js:19762:26</a>)<br> at Wrapper_EmailSubscriptionsBlockComponent.ngDoCheck (/AppModule/EmailSubscriptionsBlockComponent/wrapper.ngfactory.js:29:7)<br> at CompiledTemplate.proxyViewClass.View_BaseObjectReleasesPageComponent0.detectChangesInternal (/AppModule/BaseObjectReleasesPageComponent/component.ngfactory.js:264:47)<br> at CompiledTemplate.proxyViewClass.AppView.detectChanges (<a href="http://beta.prwire:4201/vendor.bundle.js:61297:14" rel="nofollow">http://beta.prwire:4201/vendor.bundle.js:61297:14</a>)</p> <p dir="auto">** OS:<br> Linux user-desktop 3.13.0-37-generic <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="45048591" data-permission-text="Title is private" data-url="https://github.com/angular/angular/issues/64" data-hovercard-type="pull_request" data-hovercard-url="/angular/angular/pull/64/hovercard" href="https://github.com/angular/angular/pull/64">#64</a>-Ubuntu SMP Mon Sep 22 21:28:38 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux</p> <p dir="auto">ng version<br> angular-cli: 1.0.0-beta.21<br> node: 7.1.0<br> os: linux x64</p> <ul dir="auto"> <li> <p dir="auto"><strong>Angular version:</strong><br> "dependencies": {<br> "@angular/common": "2.2.3",<br> "@angular/compiler": "2.2.3",<br> "@angular/core": "2.2.3",<br> "@angular/forms": "2.2.3",<br> "@angular/http": "2.2.3",<br> "@angular/platform-browser": "2.2.3",<br> "@angular/platform-browser-dynamic": "2.2.3",<br> "@angular/router": "3.2.3",<br> "angular2-cookie": "^1.2.5",<br> "angular2-toaster": "^1.0.2",<br> "core-js": "^2.4.1",<br> "ng2-pagination": "^0.5.1",<br> "rxjs": "5.0.0-rc.1",<br> "systemjs": "0.19.41",<br> "ts-helpers": "^1.1.1",<br> "zone.js": "^0.6.23"<br> },<br> "devDependencies": {<br> "@angular/compiler-cli": "2.2.3",<br> "@types/jasmine": "2.5.38",<br> "@types/node": "^6.0.42",<br> "angular-cli": "1.0.0-beta.22",<br> ...</p> </li> <li> <p dir="auto"><strong>Browser:</strong> Chrome</p> </li> </ul>
<p dir="auto"><strong>I'm submitting a ...</strong> (check one with "x")</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[ ] bug report =&gt; search github for a similar issue or PR before submitting [x ] feature request [ ] support request =&gt; Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question"><pre class="notranslate"><code class="notranslate">[ ] bug report =&gt; search github for a similar issue or PR before submitting [x ] feature request [ ] support request =&gt; Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question </code></pre></div> <p dir="auto"><strong>Current behavior</strong></p> <p dir="auto">I have the the following active paths</p> <p dir="auto">'./path1' the link path1 should be active.<br> './path1?param1=70000&amp;param2=test2' the link path1 should be active.<br> './path1/path2' the link path2 should be active.</p> <p dir="auto">I am using [routerLinkActiveOptions]="{ exact: true }" to distinguise between './path1' and './path1/path2' but this doesn't work with queryParams. Which is why I should probably use the queryParams variable. But since I want to allow any parameter it's strange that I have to specify all of them.</p> <p dir="auto"><strong>Expected behavior</strong></p> <p dir="auto">path1 should be active even with parameters without needing to specify all of them.</p> <p dir="auto"><strong>What is the motivation / use case for changing the behavior?</strong><br> In use cases where there are many parameters and you want to make the link active for any of them it's strange that you need to specify all of them.</p> <p dir="auto"><strong>Please tell us about your environment:</strong></p> <p dir="auto">Angular2 latest, chrome</p> <ul dir="auto"> <li><strong>Angular version:</strong> 2.0.X</li> </ul> <ul dir="auto"> <li> <p dir="auto"><strong>Browser:</strong> [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Chrome</p> </li> <li> <p dir="auto"><strong>Language:</strong> [all | TypeScript X.X | ES6/7 | ES5]<br> Typescript</p> </li> </ul>
0
<p dir="auto">All responsive classes (both by device size and print) don't like inline elements like <span> to be hidden and shown correctly without breaking it.</span></p> <p dir="auto">Example:</p> <div class="highlight highlight-text-html-basic notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&lt;a class=&quot;btn&quot;&gt;&lt;i class=&quot;glyphicon glyphicon-envelope&quot;&gt;&lt;/i&gt; &lt;span class=&quot;hidden-sm&quot;&gt;Email&lt;/span&gt;&lt;/a&gt;"><pre class="notranslate"><span class="pl-kos">&lt;</span><span class="pl-ent">a</span> <span class="pl-c1">class</span>="<span class="pl-s">btn</span>"<span class="pl-kos">&gt;</span><span class="pl-kos">&lt;</span><span class="pl-ent">i</span> <span class="pl-c1">class</span>="<span class="pl-s">glyphicon glyphicon-envelope</span>"<span class="pl-kos">&gt;</span><span class="pl-kos">&lt;/</span><span class="pl-ent">i</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">span</span> <span class="pl-c1">class</span>="<span class="pl-s">hidden-sm</span>"<span class="pl-kos">&gt;</span>Email<span class="pl-kos">&lt;/</span><span class="pl-ent">span</span><span class="pl-kos">&gt;</span><span class="pl-kos">&lt;/</span><span class="pl-ent">a</span><span class="pl-kos">&gt;</span></pre></div> <p dir="auto">It does hide the span correctly when the screensize is below 768px, however when visible it's placed below the icon since it recieves a display:block.</p> <p dir="auto">Possible solution:<br> Add display:inline-block for elements like a, span, i, em, strong, etc when used in combination with responsive classes.</p>
<p dir="auto">related to issues <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="16856611" data-permission-text="Title is private" data-url="https://github.com/twbs/bootstrap/issues/8500" data-hovercard-type="pull_request" data-hovercard-url="/twbs/bootstrap/pull/8500/hovercard" href="https://github.com/twbs/bootstrap/pull/8500">#8500</a> , <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="14075731" data-permission-text="Title is private" data-url="https://github.com/twbs/bootstrap/issues/7808" data-hovercard-type="issue" data-hovercard-url="/twbs/bootstrap/issues/7808/hovercard" href="https://github.com/twbs/bootstrap/issues/7808">#7808</a> , <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="6609454" data-permission-text="Title is private" data-url="https://github.com/twbs/bootstrap/issues/4929" data-hovercard-type="issue" data-hovercard-url="/twbs/bootstrap/issues/4929/hovercard" href="https://github.com/twbs/bootstrap/issues/4929">#4929</a> ; using <code class="notranslate">.hidden-sm</code> to hide span within <code class="notranslate">.nav &gt; li &gt; a</code> . Because class is <code class="notranslate">display: block</code> above -sm then text wraps to new line. Would you consider <code class="notranslate">.hidden-*</code> classes to be <code class="notranslate">display: inline-block</code> instead ?</p> <p dir="auto">Here's a jsfiddle of the two cases - but the repercussions could be greater outside of this situation so probably needs more consideration... <a href="http://jsfiddle.net/jholl/P86yf/" rel="nofollow">http://jsfiddle.net/jholl/P86yf/</a></p>
1
<p dir="auto">rustc --version<br> rustc 0.6 (9143688 2013-02-14 14:44:12 -0800)<br> host: x86_64-unknown-linux-gnu</p> <p dir="auto">Found ICE when compiling this snippet:</p> <p dir="auto">fn main() {<br> match 0 {<br> y if y &lt; 0 =&gt; ()<br> }<br> }</p> <p dir="auto">Here is the backtrace:<br> rust: task failed at 'Assertion (!pats.is_empty()) failed', .../src/librustc/middle/check_match.rs:135<br> /usr/bin/../lib/librustrt.so(_ZN9rust_task13begin_failureEPKcS1_m+0x4b)[0x7f7c0fd2aeeb]<br> /usr/bin/../lib/librustrt.so(+0x2ac29)[0x7f7c0fd3bc29]<br> /usr/bin/../lib/librustrt.so(upcall_fail+0x180)[0x7f7c0fd2ccf0]<br> /usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0xf858b)[0x7f7c1187358b]<br> /usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0x402de)[0x7f7c117bb2de]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6middle11check_match16check_exhaustive16_c41dd2a15ed85183_06E+0xa7f)[0x7f7c1058032f]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6middle11check_match10check_expr17_91da63eec117a1fb3_06E+0x865)[0x7f7c1057c365]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x3febae)[0x7f7c1036bbae]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6middle11check_match8check_fn17_307b4ac256cbd1fb3_06E+0x153)[0x7f7c1057cd53]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x60fbf7)[0x7f7c1057cbf7]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x3fd1e0)[0x7f7c1036a1e0]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x3fc9c4)[0x7f7c103699c4]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6middle11check_match11check_crate17_4eb7bea3f5c7f29d3_06E+0x439)[0x7f7c1057b3f9]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x8c17f6)[0x7f7c1082e7f6]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x908254)[0x7f7c10875254]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6driver6driver12compile_upto17_8d63b5f164a5111b3_06E+0x1d13)[0x7f7c1082a8d3]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x908254)[0x7f7c10875254]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN6driver6driver13compile_input15_ec93634a1749fa3_06E+0xb9)[0x7f7c1082ee19]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN12run_compiler16_effc976f5954f613_06E+0x2218)[0x7f7c10860f98]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x905241)[0x7f7c10872241]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x90385e)[0x7f7c1087085e]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x908254)[0x7f7c10875254]<br> /usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0xc3d74)[0x7f7c1183ed74]<br> /usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0x129dc0)[0x7f7c118a4dc0]<br> /usr/bin/../lib/librustrt.so(_Z18task_start_wrapperP10spawn_args+0x24)[0x7f7c0fd2b754]<br> error: internal compiler error: unexpected failure<br> note: the compiler hit an unexpected failure path. this is a bug<br> note: try running with RUST_LOG=rustc=1,::rt::backtrace to get further details and report the results to github.com/mozilla/rust/issues<br> rust: task failed at 'explicit failure', .../src/librustc/rustc.rc:371<br> /usr/bin/../lib/librustrt.so(_ZN9rust_task13begin_failureEPKcS1_m+0x4b)[0x7f7c0fd2aeeb]<br> /usr/bin/../lib/librustrt.so(+0x2ac29)[0x7f7c0fd3bc29]<br> /usr/bin/../lib/librustrt.so(upcall_fail+0x180)[0x7f7c0fd2ccf0]<br> /usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0xf858b)[0x7f7c1187358b]<br> /usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0xf8532)[0x7f7c11873532]<br> /usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(_ZN3sys12begin_unwind17_7cd364c41f10422f3_06E+0x71)[0x7f7c117bb771]<br> /usr/bin/../lib/libcore-c3ca5d77d81b46c1-0.6.so(+0x129dc0)[0x7f7c118a4dc0]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN7monitor17_43bc971c43c819df3_06E+0x5fb5)[0x7f7c10867e25]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(+0x908254)[0x7f7c10875254]<br> /usr/bin/../lib/librustc-c84825241471686d-0.6.so(_ZN4main16_706f4ee7413ae583_06E+0x7e)[0x7f7c10874e6e]<br> /usr/bin/../lib/librustrt.so(_Z18task_start_wrapperP10spawn_args+0x24)[0x7f7c0fd2b754]<br> rust: domain main @0x19dc3b0 root task failed</p>
<p dir="auto">The following test:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="enum side { mayo, catsup, vinegar } enum order { hamburger, fries(side), shake } enum meal { to_go(order), for_here(order) } fn foo(m: @meal, cond: bool) { match *m { to_go(_) =&gt; { } for_here(_) if cond =&gt; {} for_here(hamburger) =&gt; {} for_here(fries(s)) =&gt; {} for_here(shake) =&gt; {} } } fn main() { foo(@for_here(hamburger), true) }"><pre class="notranslate"><code class="notranslate">enum side { mayo, catsup, vinegar } enum order { hamburger, fries(side), shake } enum meal { to_go(order), for_here(order) } fn foo(m: @meal, cond: bool) { match *m { to_go(_) =&gt; { } for_here(_) if cond =&gt; {} for_here(hamburger) =&gt; {} for_here(fries(s)) =&gt; {} for_here(shake) =&gt; {} } } fn main() { foo(@for_here(hamburger), true) } </code></pre></div> <p dir="auto">results in an assertion failure in trans:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=";RUST_LOG=rustc=0 rustc ~/tmp/pat-bug-in-trans.rs rust: task failed at 'Assertion m.len() &gt; 0u || is_some(chk) failed', /Users/nmatsakis/versioned/rust-gold/src/rustc/middle/trans/alt.rs:431 error: internal compiler error: unexpected failure note: the compiler hit an unexpected failure path. this is a bug note: try running with RUST_LOG=rustc=0,::rt::backtrace to get further details and report the results to github.com/mozilla/rust/issues rust: task failed at 'explicit failure', /Users/nmatsakis/versioned/rust-gold/src/rustc/driver/rustc.rs:264 rust: domain main @0x7f8d99800010 root task failed rust: task failed at 'killed', /Users/nmatsakis/versioned/rust-gold/src/libcore/task.rs:520"><pre class="notranslate"><code class="notranslate">;RUST_LOG=rustc=0 rustc ~/tmp/pat-bug-in-trans.rs rust: task failed at 'Assertion m.len() &gt; 0u || is_some(chk) failed', /Users/nmatsakis/versioned/rust-gold/src/rustc/middle/trans/alt.rs:431 error: internal compiler error: unexpected failure note: the compiler hit an unexpected failure path. this is a bug note: try running with RUST_LOG=rustc=0,::rt::backtrace to get further details and report the results to github.com/mozilla/rust/issues rust: task failed at 'explicit failure', /Users/nmatsakis/versioned/rust-gold/src/rustc/driver/rustc.rs:264 rust: domain main @0x7f8d99800010 root task failed rust: task failed at 'killed', /Users/nmatsakis/versioned/rust-gold/src/libcore/task.rs:520 </code></pre></div> <p dir="auto">The problem has to do with the <code class="notranslate">if</code>, something in the logic there gets a bit confused.</p>
1
<p dir="auto">version<br> 5.0.0-alpha</p> <p dir="auto">my config<br> spring.shardingsphere.props.query-with-cipher-column=true<br> spring.shardingsphere.rules.encrypt.tables.user_info.columns.name.cipherColumn=name_enc<br> spring.shardingsphere.rules.encrypt.tables.user_info.columns.name.encryptorName=name_encryptor<br> spring.shardingsphere.rules.encrypt.tables.user_info.columns.mobile.cipherColumn=mobile_enc<br> spring.shardingsphere.rules.encrypt.tables.user_info.columns.mobile.encryptorName=mobile_encryptor<br> spring.shardingsphere.rules.encrypt.tables.user_info.columns.ident.cipherColumn=ident_enc<br> spring.shardingsphere.rules.encrypt.tables.user_info.columns.ident.encryptorName=idcard_encryptor<br> spring.shardingsphere.rules.encrypt.tables.user_info.columns.value.cipherColumn=value_enc<br> spring.shardingsphere.rules.encrypt.tables.user_info.columns.value.encryptorName=addr_encryptor<br> spring.shardingsphere.rules.encrypt.tables.test_name.columns.name.cipherColumn=name_enc<br> spring.shardingsphere.rules.encrypt.tables.test_name.columns.name.encryptorName=name_encryptor<br> spring.shardingsphere.rules.encrypt.tables.users.columns.name.cipherColumn=name_enc<br> spring.shardingsphere.rules.encrypt.tables.users.columns.name.encryptorName=name_encryptor</p> <p dir="auto">2021-02-02 17:24:11.161 INFO 1832 --- [ main] ShardingSphere-SQL : Logic SQL: select ui.*,u.name,tn.name from user_info ui left join users u on u.id = ui.id left join test_name tn on tn.name = u.name where ui.id &gt; 0<br> 2021-02-02 17:24:11.163 INFO 1832 --- [ main] ShardingSphere-SQL : Actual SQL: ds0 ::: select <code class="notranslate">ui</code>.<code class="notranslate">id</code>, <code class="notranslate">ui</code>.<code class="notranslate">cust_id</code>, <code class="notranslate">ui</code>.<code class="notranslate">unique_id</code>, <code class="notranslate">ui</code>.<code class="notranslate">name_enc</code> AS name, <code class="notranslate">ui</code>.<code class="notranslate">name_assisted</code>, <code class="notranslate">ui</code>.<code class="notranslate">ident_enc</code> AS ident, <code class="notranslate">ui</code>.<code class="notranslate">mobile_enc</code> AS mobile, <code class="notranslate">ui</code>.<code class="notranslate">password</code>, <code class="notranslate">ui</code>.<code class="notranslate">reg_time</code>, <code class="notranslate">ui</code>.<code class="notranslate">modify_time</code>, <code class="notranslate">ui</code>.<code class="notranslate">reg_source</code>, <code class="notranslate">ui</code>.<code class="notranslate">reg_app_channel</code>, <code class="notranslate">ui</code>.<code class="notranslate">reg_device_info</code>, <code class="notranslate">ui</code>.<code class="notranslate">status</code>, <code class="notranslate">ui</code>.<code class="notranslate">is_mobile_authed</code>, <code class="notranslate">ui</code>.<code class="notranslate">complate_cust_info</code>, <code class="notranslate">ui</code>.<code class="notranslate">time_inst</code>, <code class="notranslate">ui</code>.<code class="notranslate">time_upd</code>, <code class="notranslate">ui</code>.<code class="notranslate">has_checked</code>, <code class="notranslate">ui</code>.<code class="notranslate">value_enc</code> AS value, <code class="notranslate">ui</code>.<code class="notranslate">system</code>,u.name_enc AS name,tn.name_enc AS name from user_info ui left join users u on u.id = ui.id left join test_name tn on <strong>tn.name = u.name</strong> where ui.id &gt; 0</p> <p dir="auto">left join .... on tn.name = u.name ,there will be rewrite to tn.name_enc = u.name_enc</p>
<p dir="auto">I query the field infromation of the table with the "select COLUMN_NAME FROM information_schema.COLUMNS WHERE TABLE_NAME='goods'" statement,but result is null.<br> the "goods" is the source table of subtable.</p> <p dir="auto">I found through debug that the reason is that the information stored in the mysql database is<br> the subtable information ,so it cannot be obtained.</p> <p dir="auto">if I want query the column information of the table by source table names,what to do .</p>
0
<p dir="auto">We have <code class="notranslate">in</code> with <code class="notranslate">∈</code>, but not an non-ascii alias for ∉. I suggest <code class="notranslate">!in</code> or <code class="notranslate">notin</code>.</p> <p dir="auto">The problem is I don't want to use <code class="notranslate">∉</code> when I wouldn't use <code class="notranslate">∈</code>. In other words, if my code is using <code class="notranslate">in</code>, it then kinda forces you to change these to <code class="notranslate">∈</code> so they match with <code class="notranslate">∉</code>.</p>
<p dir="auto">I encountered a possible MKL threading bug in Julia 1.7.0 on macOS but don't know if it is the same as the OpenBLAS threading issue (e.g. <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="1069687332" data-permission-text="Title is private" data-url="https://github.com/JuliaLang/julia/issues/43301" data-hovercard-type="issue" data-hovercard-url="/JuliaLang/julia/issues/43301/hovercard" href="https://github.com/JuliaLang/julia/issues/43301">#43301</a> ), so please close if this is a duplicate.</p> <p dir="auto">The following code is a simplified version of code that generates impulse response functions from a state-space model. It works with 1 BLAS thread but the matrix based iteration x2 explodes with any higher thread number, even though the relevant row of the matrix only has one non-zero entry of 0.9 and should give the same path as x1, which is essentially an AR1. On Linux, the code runs for any number of threads and x1 and x2 follow the same impulse response.</p> <div class="highlight highlight-source-julia notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="using Plots, MKL, LinearAlgebra BLAS.set_num_threads(2) var_index = 150 # index of variable of interest LOMstate = randn(300, 300) # law of motion LOMstate[var_index, :] .= 0.0 # set the law of motion for the variable of interest to an AR with coefficient 0.9 LOMstate[var_index, var_index] = 0.9 x0 = zeros(size(LOMstate, 1), 1) x0[var_index] = 1.0 # shock to the variable of interest irf_horizon = 40 x1 = x0 * ones(1, irf_horizon + 1) x2 = x0 * ones(1, irf_horizon + 1) for t = 1:irf_horizon x1[var_index, t+1] = LOMstate[var_index, var_index] * x1[var_index, t] # just iterate over AR1 x2[:, t+1] = LOMstate * x2[:, t] # iterate full system but variable of interest should be unaffected by rest of system end plt1 = plot(x1[var_index, :], label = &quot;IRF AR1 based&quot;) plt1 = plot!(x2[var_index, :], label = &quot;IRF matrix based&quot;)"><pre class="notranslate"><span class="pl-k">using</span> Plots, MKL, LinearAlgebra BLAS<span class="pl-k">.</span><span class="pl-c1">set_num_threads</span>(<span class="pl-c1">2</span>) var_index <span class="pl-k">=</span> <span class="pl-c1">150</span> <span class="pl-c"><span class="pl-c">#</span> index of variable of interest</span> LOMstate <span class="pl-k">=</span> <span class="pl-c1">randn</span>(<span class="pl-c1">300</span>, <span class="pl-c1">300</span>) <span class="pl-c"><span class="pl-c">#</span> law of motion</span> LOMstate[var_index, :] <span class="pl-k">.=</span> <span class="pl-c1">0.0</span> <span class="pl-c"><span class="pl-c">#</span> set the law of motion for the variable of interest to an AR with coefficient 0.9</span> LOMstate[var_index, var_index] <span class="pl-k">=</span> <span class="pl-c1">0.9</span> x0 <span class="pl-k">=</span> <span class="pl-c1">zeros</span>(<span class="pl-c1">size</span>(LOMstate, <span class="pl-c1">1</span>), <span class="pl-c1">1</span>) x0[var_index] <span class="pl-k">=</span> <span class="pl-c1">1.0</span> <span class="pl-c"><span class="pl-c">#</span> shock to the variable of interest</span> irf_horizon <span class="pl-k">=</span> <span class="pl-c1">40</span> x1 <span class="pl-k">=</span> x0 <span class="pl-k">*</span> <span class="pl-c1">ones</span>(<span class="pl-c1">1</span>, irf_horizon <span class="pl-k">+</span> <span class="pl-c1">1</span>) x2 <span class="pl-k">=</span> x0 <span class="pl-k">*</span> <span class="pl-c1">ones</span>(<span class="pl-c1">1</span>, irf_horizon <span class="pl-k">+</span> <span class="pl-c1">1</span>) <span class="pl-k">for</span> t <span class="pl-k">=</span> <span class="pl-c1">1</span><span class="pl-k">:</span>irf_horizon x1[var_index, t<span class="pl-k">+</span><span class="pl-c1">1</span>] <span class="pl-k">=</span> LOMstate[var_index, var_index] <span class="pl-k">*</span> x1[var_index, t] <span class="pl-c"><span class="pl-c">#</span> just iterate over AR1</span> x2[:, t<span class="pl-k">+</span><span class="pl-c1">1</span>] <span class="pl-k">=</span> LOMstate <span class="pl-k">*</span> x2[:, t] <span class="pl-c"><span class="pl-c">#</span> iterate full system but variable of interest should be unaffected by rest of system</span> <span class="pl-k">end</span> plt1 <span class="pl-k">=</span> <span class="pl-c1">plot</span>(x1[var_index, :], label <span class="pl-k">=</span> <span class="pl-s"><span class="pl-pds">"</span>IRF AR1 based<span class="pl-pds">"</span></span>) plt1 <span class="pl-k">=</span> <span class="pl-c1">plot!</span>(x2[var_index, :], label <span class="pl-k">=</span> <span class="pl-s"><span class="pl-pds">"</span>IRF matrix based<span class="pl-pds">"</span></span>)</pre></div> <p dir="auto">With 1 thread<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/12073629/146387732-518a7e85-935c-4bbb-8586-a8e243a1b30c.png"><img width="487" alt="image" src="https://user-images.githubusercontent.com/12073629/146387732-518a7e85-935c-4bbb-8586-a8e243a1b30c.png" style="max-width: 100%;"></a></p> <p dir="auto">With 2 or more threads (might look different due to random<code class="notranslate">LOMstate</code> matrix)<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/12073629/146387872-b9b34506-4a83-431b-a07a-6b8ba4ba604b.png"><img width="495" alt="image" src="https://user-images.githubusercontent.com/12073629/146387872-b9b34506-4a83-431b-a07a-6b8ba4ba604b.png" style="max-width: 100%;"></a></p> <p dir="auto">My system:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Julia Version 1.7.0 Commit 3bf9d17731 (2021-11-30 12:12 UTC) Platform Info: OS: macOS (x86_64-apple-darwin19.5.0) CPU: Intel(R) Xeon(R) W-2191B CPU @ 2.30GHz WORD_SIZE: 64 LIBM: libopenlibm LLVM: libLLVM-12.0.1 (ORCJIT, skylake-avx512) Environment: JULIA_EDITOR = code JULIA_NUM_THREADS = 1 "><pre class="notranslate"><code class="notranslate">Julia Version 1.7.0 Commit 3bf9d17731 (2021-11-30 12:12 UTC) Platform Info: OS: macOS (x86_64-apple-darwin19.5.0) CPU: Intel(R) Xeon(R) W-2191B CPU @ 2.30GHz WORD_SIZE: 64 LIBM: libopenlibm LLVM: libLLVM-12.0.1 (ORCJIT, skylake-avx512) Environment: JULIA_EDITOR = code JULIA_NUM_THREADS = 1 </code></pre></div> <p dir="auto">I'm happy to provide more information.</p>
0
<p dir="auto">There is an error in the docstring for the query function in</p> <p dir="auto"><code class="notranslate">pandas/core/frame.py</code>.</p> <p dir="auto">The PR here fixes this: <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="338360768" data-permission-text="Title is private" data-url="https://github.com/pandas-dev/pandas/issues/21731" data-hovercard-type="pull_request" data-hovercard-url="/pandas-dev/pandas/pull/21731/hovercard" href="https://github.com/pandas-dev/pandas/pull/21731">#21731</a></p> <h4 dir="auto">Code Sample, a copy-pastable example if possible</h4> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="# Your code here "><pre class="notranslate"><span class="pl-c"># Your code here</span></pre></div> <h4 dir="auto">Problem description</h4> <p dir="auto">[this should explain <strong>why</strong> the current behaviour is a problem and why the expected output is a better solution.]</p> <p dir="auto"><strong>Note</strong>: We receive a lot of issues on our GitHub tracker, so it is very possible that your issue has been posted before. Please check first before submitting so that we do not have to handle and close duplicates!</p> <p dir="auto"><strong>Note</strong>: Many problems can be resolved by simply upgrading <code class="notranslate">pandas</code> to the latest version. Before submitting, please check if that solution works for you. If possible, you may want to check if <code class="notranslate">master</code> addresses this issue, but that is not necessary.</p> <p dir="auto">For documentation-related issues, you can check the latest versions of the docs on <code class="notranslate">master</code> here:</p> <p dir="auto"><a href="https://pandas-docs.github.io/pandas-docs-travis/" rel="nofollow">https://pandas-docs.github.io/pandas-docs-travis/</a></p> <p dir="auto">If the issue has not been resolved there, go ahead and file it in the issue tracker.</p> <h4 dir="auto">Expected Output</h4> <h4 dir="auto">Output of <code class="notranslate">pd.show_versions()</code></h4> <details> <p dir="auto">[paste the output of <code class="notranslate">pd.show_versions()</code> here below this line]</p> </details>
<p dir="auto">Hey everyone,</p> <p dir="auto">I was working on a project that involves working with data acquired via the world bank pandas api (i.e. <code class="notranslate">pandas.io.wb</code>). This library has a function called <code class="notranslate">pandas.io.wb.search(str)</code> which is very useful. In data transformation terms, it's basically does this- given a string 's', filter the dataframe by retaining only the tuples where a string match occurs with the given string 's'.</p> <p dir="auto">This operation occurs in my workflow on a regular basis, and I was wondering if anyone else feels the need to have this function natively in pandas. Would be a huge time saver in my opinion!</p> <p dir="auto">Was thinking of a function that looks like this:<br> <code class="notranslate">DataFrame.search(search_str, is_ignore_case=True, is_match_full_word=False, **kwargs)</code></p> <p dir="auto">Would love to hear from the community! :)</p>
0
<p dir="auto">Here <a href="http://getbootstrap.com/css/#grid-offsetting" rel="nofollow">http://getbootstrap.com/css/#grid-offsetting</a> we see col-lg-offset-* but there's no col-lg-offset-<em>. There's col-offset-</em>. Need to fix.</p>
<p dir="auto">So as per the documentation, I tried using two different offsets for desktop and phone. But I could not find the col-lg-offset on the CDN hosted css file.</p> <p dir="auto"><a href="http://netdna.bootstrapcdn.com/bootstrap/3.0.0-rc1/css/bootstrap.min.css" rel="nofollow">http://netdna.bootstrapcdn.com/bootstrap/3.0.0-rc1/css/bootstrap.min.css</a></p> <p dir="auto">Am not sure if this is an issue or am I going wrong somewhere?</p>
1
<p dir="auto">I am trying to concatenating two Panels with duplicate <code class="notranslate">Items</code> (but different <code class="notranslate">major_axes</code>) together, without actually having to duplicate items... Did some searching but couldn't find much on SO.</p> <p dir="auto">Unfortunately I cannot upload pics to github at the moment.. <strong>But screens are attached <a href="http://stackoverflow.com/questions/34652835/pandas-how-to-concatenate-two-panels-without-duplicating-items-axis-i-e-colum" rel="nofollow">here</a>.</strong></p> <p dir="auto">To illustrate what I mean:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="# create data import pandas as pd df1 = pd.DataFrame({'A' : [1, 2, 3], 'B' : [2, 5, 6]}, index={0, 1, 2}) df2 = pd.DataFrame({'A' : [1, 2, 3], 'B' : [2, 5, 6]}, index={3, 4, 5}) df3 = pd.DataFrame({'A' : [5, 2, 3], 'B' : [2, 5, 6]}, index={6, 7, 8}) df4 = pd.DataFrame({'A' : [6, 2, 3], 'B' : [2, 5, 6]}, index={9, 10, 11}) pan1 = pd.Panel({'X' : df1, 'Y': df2}) pan2 = pd.Panel({'X' : df3, 'Y': df4}) # concat these two panels above pan3 = pd.concat([pan1, pan2]) pan3 Output: &lt;class 'pandas.core.panel.Panel'&gt; Dimensions: 4 (items) x 12 (major_axis) x 2 (minor_axis) Items axis: X to Y Major_axis axis: 0 to 11 Minor_axis axis: A to B"><pre class="notranslate"><code class="notranslate"># create data import pandas as pd df1 = pd.DataFrame({'A' : [1, 2, 3], 'B' : [2, 5, 6]}, index={0, 1, 2}) df2 = pd.DataFrame({'A' : [1, 2, 3], 'B' : [2, 5, 6]}, index={3, 4, 5}) df3 = pd.DataFrame({'A' : [5, 2, 3], 'B' : [2, 5, 6]}, index={6, 7, 8}) df4 = pd.DataFrame({'A' : [6, 2, 3], 'B' : [2, 5, 6]}, index={9, 10, 11}) pan1 = pd.Panel({'X' : df1, 'Y': df2}) pan2 = pd.Panel({'X' : df3, 'Y': df4}) # concat these two panels above pan3 = pd.concat([pan1, pan2]) pan3 Output: &lt;class 'pandas.core.panel.Panel'&gt; Dimensions: 4 (items) x 12 (major_axis) x 2 (minor_axis) Items axis: X to Y Major_axis axis: 0 to 11 Minor_axis axis: A to B </code></pre></div> <p dir="auto"><strong>Note that the <code class="notranslate">Items</code> axis for <code class="notranslate">pan3</code> is of length 4, while <code class="notranslate">pan1</code> and <code class="notranslate">pan2</code> both have <code class="notranslate">Items</code> axis of length 2.</strong></p> <p dir="auto">Looking at <code class="notranslate">pan3</code>'s <code class="notranslate">minor_axis</code>, I get duplicated columns in the frame below. <strong>This is my problem.</strong>:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="pan3.loc[:, :, 'B']"><pre class="notranslate"><code class="notranslate">pan3.loc[:, :, 'B'] </code></pre></div> <p dir="auto">Screenshot: See this <a href="http://stackoverflow.com/questions/34652835/pandas-how-to-concatenate-two-panels-without-duplicating-items-axis-i-e-colum" rel="nofollow">link on SO</a></p> <p dir="auto"><strong>What I actually want to see</strong> can be replicated as follows in a more complicated way... (Not more duplicated columns in the screenshot):</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="df5 = pd.concat([df1, df3]) df6 = pd.concat([df2, df4]) pan4 = pd.Panel({'X':df5, 'Y':df6}) pan4.loc[:, :, 'B']"><pre class="notranslate"><code class="notranslate">df5 = pd.concat([df1, df3]) df6 = pd.concat([df2, df4]) pan4 = pd.Panel({'X':df5, 'Y':df6}) pan4.loc[:, :, 'B'] </code></pre></div> <p dir="auto">Screenshot: See this <a href="http://stackoverflow.com/questions/34652835/pandas-how-to-concatenate-two-panels-without-duplicating-items-axis-i-e-colum" rel="nofollow">link on SO</a></p> <p dir="auto"><strong>Is this something that can be done with <code class="notranslate">pd.concat</code>?</strong> Thanks guys.</p>
<p dir="auto">I get a NameError exception when I try to filter DataFrame by selected index values (inside IPython session). You can see that <a href="http://www.datafilehost.com/d/a5c78493" rel="nofollow"><code class="notranslate">valid</code></a> is <code class="notranslate">numpy.array</code> while <a href="http://www.datafilehost.com/d/cf3704a0" rel="nofollow"><code class="notranslate">lab</code></a> is a <code class="notranslate">pandas.DataFrame</code> object. Both of them are initialized and accessible. However I cannot put them together. Here is the error:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="In [51]: valid Out[51]: array([38661, 44593, 38705, 38918, 38727, 38757, 38751, 38777, 38787, ..., 45328, 45337, 43645, 43694, 43701]) In [52]: lab Out[52]: 0 39333 -1 39173 -1 42756 -1 39633 -1 38661 -1 44801 81 ... ... 39379 -1 39742 -1 44765 108 44279 -1 40584 -1 41047 -1 41833 98 [3299 rows x 1 columns] In [53]: lab[lab.index.map(lambda x: x in valid)] --------------------------------------------------------------------------- NameError Traceback (most recent call last) /home/vitaly/progs/vnii_gochs/venv/lib/python2.7/site-packages/django/core/management/commands/shell.pyc in &lt;module&gt;() ----&gt; 1 lab[lab.index.map(lambda x: x in valid)] /home/vitaly/progs/vnii_gochs/venv/lib/python2.7/site-packages/pandas/core/index.pyc in map(self, mapper) 1558 1559 def map(self, mapper): -&gt; 1560 return self._arrmap(self.values, mapper) 1561 1562 def isin(self, values, level=None): /home/vitaly/progs/vnii_gochs/venv/lib/python2.7/site-packages/pandas/algos.so in pandas.algos.arrmap_int64 (pandas/algos.c:78469)() /home/vitaly/progs/vnii_gochs/venv/lib/python2.7/site-packages/django/core/management/commands/shell.pyc in &lt;lambda&gt;(x) ----&gt; 1 lab[lab.index.map(lambda x: x in valid)] NameError: global name 'valid' is not defined"><pre class="notranslate"><span class="pl-v">In</span> [<span class="pl-c1">51</span>]: <span class="pl-s1">valid</span> <span class="pl-v">Out</span>[<span class="pl-c1">51</span>]: <span class="pl-en">array</span>([<span class="pl-c1">38661</span>, <span class="pl-c1">44593</span>, <span class="pl-c1">38705</span>, <span class="pl-c1">38918</span>, <span class="pl-c1">38727</span>, <span class="pl-c1">38757</span>, <span class="pl-c1">38751</span>, <span class="pl-c1">38777</span>, <span class="pl-c1">38787</span>, ..., <span class="pl-c1">45328</span>, <span class="pl-c1">45337</span>, <span class="pl-c1">43645</span>, <span class="pl-c1">43694</span>, <span class="pl-c1">43701</span>]) <span class="pl-v">In</span> [<span class="pl-c1">52</span>]: <span class="pl-s1">lab</span> <span class="pl-v">Out</span>[<span class="pl-c1">52</span>]: <span class="pl-c1">0</span> <span class="pl-c1">39333</span> <span class="pl-c1">-</span><span class="pl-c1">1</span> <span class="pl-c1">39173</span> <span class="pl-c1">-</span><span class="pl-c1">1</span> <span class="pl-c1">42756</span> <span class="pl-c1">-</span><span class="pl-c1">1</span> <span class="pl-c1">39633</span> <span class="pl-c1">-</span><span class="pl-c1">1</span> <span class="pl-c1">38661</span> <span class="pl-c1">-</span><span class="pl-c1">1</span> <span class="pl-c1">44801</span> <span class="pl-c1">81</span> ... ... <span class="pl-c1">39379</span> <span class="pl-c1">-</span><span class="pl-c1">1</span> <span class="pl-c1">39742</span> <span class="pl-c1">-</span><span class="pl-c1">1</span> <span class="pl-c1">44765</span> <span class="pl-c1">108</span> <span class="pl-c1">44279</span> <span class="pl-c1">-</span><span class="pl-c1">1</span> <span class="pl-c1">40584</span> <span class="pl-c1">-</span><span class="pl-c1">1</span> <span class="pl-c1">41047</span> <span class="pl-c1">-</span><span class="pl-c1">1</span> <span class="pl-c1">41833</span> <span class="pl-c1">98</span> [<span class="pl-c1">3299</span> <span class="pl-s1">rows</span> <span class="pl-s1">x</span> <span class="pl-c1">1</span> <span class="pl-s1">columns</span>] <span class="pl-v">In</span> [<span class="pl-c1">53</span>]: <span class="pl-s1">lab</span>[<span class="pl-s1">lab</span>.<span class="pl-s1">index</span>.<span class="pl-en">map</span>(<span class="pl-k">lambda</span> <span class="pl-s1">x</span>: <span class="pl-s1">x</span> <span class="pl-c1">in</span> <span class="pl-s1">valid</span>)] <span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span> <span class="pl-v">NameError</span> <span class="pl-v">Traceback</span> (<span class="pl-s1">most</span> <span class="pl-s1">recent</span> <span class="pl-s1">call</span> <span class="pl-s1">last</span>) <span class="pl-c1">/</span><span class="pl-s1">home</span><span class="pl-c1">/</span><span class="pl-s1">vitaly</span><span class="pl-c1">/</span><span class="pl-s1">progs</span><span class="pl-c1">/</span><span class="pl-s1">vnii_gochs</span><span class="pl-c1">/</span><span class="pl-s1">venv</span><span class="pl-c1">/</span><span class="pl-s1">lib</span><span class="pl-c1">/</span><span class="pl-s1">python2</span>.<span class="pl-c1">7</span><span class="pl-c1">/</span><span class="pl-s1">site</span><span class="pl-c1">-</span><span class="pl-s1">packages</span><span class="pl-c1">/</span><span class="pl-s1">django</span><span class="pl-c1">/</span><span class="pl-s1">core</span><span class="pl-c1">/</span><span class="pl-s1">management</span><span class="pl-c1">/</span><span class="pl-s1">commands</span><span class="pl-c1">/</span><span class="pl-s1">shell</span>.<span class="pl-s1">pyc</span> <span class="pl-c1">in</span> <span class="pl-c1">&lt;</span><span class="pl-s1">module</span><span class="pl-c1">&gt;</span>() <span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">&gt;</span> <span class="pl-c1">1</span> <span class="pl-s1">lab</span>[<span class="pl-s1">lab</span>.<span class="pl-s1">index</span>.<span class="pl-en">map</span>(<span class="pl-k">lambda</span> <span class="pl-s1">x</span>: <span class="pl-s1">x</span> <span class="pl-c1">in</span> <span class="pl-s1">valid</span>)] <span class="pl-c1">/</span><span class="pl-s1">home</span><span class="pl-c1">/</span><span class="pl-s1">vitaly</span><span class="pl-c1">/</span><span class="pl-s1">progs</span><span class="pl-c1">/</span><span class="pl-s1">vnii_gochs</span><span class="pl-c1">/</span><span class="pl-s1">venv</span><span class="pl-c1">/</span><span class="pl-s1">lib</span><span class="pl-c1">/</span><span class="pl-s1">python2</span>.<span class="pl-c1">7</span><span class="pl-c1">/</span><span class="pl-s1">site</span><span class="pl-c1">-</span><span class="pl-s1">packages</span><span class="pl-c1">/</span><span class="pl-s1">pandas</span><span class="pl-c1">/</span><span class="pl-s1">core</span><span class="pl-c1">/</span><span class="pl-s1">index</span>.<span class="pl-s1">pyc</span> <span class="pl-c1">in</span> <span class="pl-en">map</span>(<span class="pl-s1">self</span>, <span class="pl-s1">mapper</span>) <span class="pl-c1">1558</span> <span class="pl-c1">1559</span> <span class="pl-k">def</span> <span class="pl-en">map</span>(<span class="pl-s1">self</span>, <span class="pl-s1">mapper</span>): <span class="pl-c1">-</span><span class="pl-c1">&gt;</span> <span class="pl-c1">1560</span> <span class="pl-s1">return</span> <span class="pl-s1">self</span>.<span class="pl-en">_arrmap</span>(<span class="pl-s1">self</span>.<span class="pl-s1">values</span>, <span class="pl-s1">mapper</span>) <span class="pl-c1">1561</span> <span class="pl-c1">1562</span> <span class="pl-k">def</span> <span class="pl-en">isin</span>(<span class="pl-s1">self</span>, <span class="pl-s1">values</span>, <span class="pl-s1">level</span><span class="pl-c1">=</span><span class="pl-c1">None</span>): <span class="pl-c1">/</span><span class="pl-s1">home</span><span class="pl-c1">/</span><span class="pl-s1">vitaly</span><span class="pl-c1">/</span><span class="pl-s1">progs</span><span class="pl-c1">/</span><span class="pl-s1">vnii_gochs</span><span class="pl-c1">/</span><span class="pl-s1">venv</span><span class="pl-c1">/</span><span class="pl-s1">lib</span><span class="pl-c1">/</span><span class="pl-s1">python2</span>.<span class="pl-c1">7</span><span class="pl-c1">/</span><span class="pl-s1">site</span><span class="pl-c1">-</span><span class="pl-s1">packages</span><span class="pl-c1">/</span><span class="pl-s1">pandas</span><span class="pl-c1">/</span><span class="pl-s1">algos</span>.<span class="pl-s1">so</span> <span class="pl-c1">in</span> <span class="pl-s1">pandas</span>.<span class="pl-s1">algos</span>.<span class="pl-en">arrmap_int64</span> (<span class="pl-s1">pandas</span><span class="pl-c1">/</span><span class="pl-s1">algos</span>.<span class="pl-s1">c</span>:<span class="pl-c1">78469</span>)() <span class="pl-c1">/</span><span class="pl-s1">home</span><span class="pl-c1">/</span><span class="pl-s1">vitaly</span><span class="pl-c1">/</span><span class="pl-s1">progs</span><span class="pl-c1">/</span><span class="pl-s1">vnii_gochs</span><span class="pl-c1">/</span><span class="pl-s1">venv</span><span class="pl-c1">/</span><span class="pl-s1">lib</span><span class="pl-c1">/</span><span class="pl-s1">python2</span>.<span class="pl-c1">7</span><span class="pl-c1">/</span><span class="pl-s1">site</span><span class="pl-c1">-</span><span class="pl-s1">packages</span><span class="pl-c1">/</span><span class="pl-s1">django</span><span class="pl-c1">/</span><span class="pl-s1">core</span><span class="pl-c1">/</span><span class="pl-s1">management</span><span class="pl-c1">/</span><span class="pl-s1">commands</span><span class="pl-c1">/</span><span class="pl-s1">shell</span>.<span class="pl-s1">pyc</span> <span class="pl-c1">in</span> <span class="pl-c1">&lt;</span><span class="pl-s1">lambda</span><span class="pl-c1">&gt;</span>(<span class="pl-s1">x</span>) <span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">-</span><span class="pl-c1">&gt;</span> <span class="pl-c1">1</span> <span class="pl-s1">lab</span>[<span class="pl-s1">lab</span>.<span class="pl-s1">index</span>.<span class="pl-en">map</span>(<span class="pl-k">lambda</span> <span class="pl-s1">x</span>: <span class="pl-s1">x</span> <span class="pl-c1">in</span> <span class="pl-s1">valid</span>)] <span class="pl-v">NameError</span>: <span class="pl-s1">global</span> <span class="pl-s1">name</span> <span class="pl-s">'valid'</span> <span class="pl-c1">is</span> <span class="pl-c1">not</span> <span class="pl-s1">defined</span></pre></div> <p dir="auto">What's wrong with this code? I use pandas 0.15.1.<br> (This issue is a duplicate of SO's question <a href="http://stackoverflow.com/questions/27637825/variable-visibility-issue-with-pandas-and-ipython/27643446#27643446" rel="nofollow">http://stackoverflow.com/questions/27637825/variable-visibility-issue-with-pandas-and-ipython/27643446#27643446</a>)</p>
0
<p dir="auto">by <strong>roberto.catini</strong>:</p> <pre class="notranslate">The comment for the P521 function partially reference another function: At line 373 of the source code: <a href="http://golang.org/src/pkg/crypto/elliptic/elliptic.go?s=11710:11727#L364" rel="nofollow">http://golang.org/src/pkg/crypto/elliptic/elliptic.go?s=11710:11727#L364</a> the comment should read: // P521 returns a Curve which implements P-521 (see FIPS 186-3, section D.2.5)</pre>
<p dir="auto">by <strong><a href="mailto:ilarkin@crystalnix.com">ilarkin@crystalnix.com</a></strong>:</p> <pre class="notranslate">What does 'go version' print? go version go1.2 linux/amd64 What steps reproduce the problem? Code: <a href="http://play.golang.org/p/TasQabnlRu" rel="nofollow">http://play.golang.org/p/TasQabnlRu</a> 1. Create a new *net.TCPConn (using net.Accept) 2. Call File() 3. Close new file 4. Set Read Deadline to 5 seconds 5. Start reading What happened? The reading is never finishes. As the result i see the following output: &gt; New Connection: 127.0.0.1:33079 &gt; Fd: 7 &gt; What should have happened instead? &gt; New Connection: 127.0.0.1:33079 &gt; Fd: 7 &gt; Error: read tcp 127.0.0.1:33079: i/o timeout Please provide any additional information below. I'm trying to understand why this code sample doesn't work. As i understand, File() creates a copy of the underlying fd. And the new fd has no effect to the original. One more thing... If i use only the SetReadDeadline function - timeout doesn't work. But if i use it in couple with the syscall.SetsockoptTimeval function - it works.</pre>
0
<p dir="auto"><strong>Migrated issue, originally created by Michael Bayer (<a href="https://github.com/zzzeek">@zzzeek</a>)</strong></p> <p dir="auto">very simple and the slightest bit not backwards compatible....very unfortunate I wasn't able to see this four years ago, unless I'm missing something.</p> <p dir="auto">Might have to push this to 0.8.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="diff -r 35cba3c84ab9c36663e57049e56e59cace5aa2f7 lib/sqlalchemy/orm/properties.py --- a/lib/sqlalchemy/orm/properties.py Thu Feb 16 19:29:00 2012 -0500 +++ b/lib/sqlalchemy/orm/properties.py Sat Feb 18 08:39:33 2012 -0500 @@ -1030,7 +1030,8 @@ # general mapped table, which in the case of inheritance is # a join. return join_condition(mapper.mapped_table, table, - a_subset=mapper.local_table) + a_subset=mapper.local_table, + consider_as_foreign_keys=self._user_defined_foreign_keys) try: if self.secondary is not None: diff -r 35cba3c84ab9c36663e57049e56e59cace5aa2f7 lib/sqlalchemy/sql/util.py --- a/lib/sqlalchemy/sql/util.py Thu Feb 16 19:29:00 2012 -0500 +++ b/lib/sqlalchemy/sql/util.py Sat Feb 18 08:39:33 2012 -0500 @@ -225,7 +225,10 @@ return visitors.cloned_traverse(crit, {}, {'binary':visit_binary}) -def join_condition(a, b, ignore_nonexistent_tables=False, a_subset=None): +def join_condition(a, b, + ignore_nonexistent_tables=False, + a_subset=None, + consider_as_foreign_keys=None): &quot;&quot;&quot;create a join condition between two tables or selectables. e.g.:: @@ -269,6 +272,9 @@ else: continue + if consider_as_foreign_keys and \ + fk.parent not in consider_as_foreign_keys: + continue if col is not None: crit.append(col == fk.parent) constraints.add(fk.constraint) @@ -286,6 +292,9 @@ # coverage to mark it. continue + if consider_as_foreign_keys and \ + fk.parent not in consider_as_foreign_keys: + continue if col is not None: crit.append(col == fk.parent) constraints.add(fk.constraint) diff -r 35cba3c84ab9c36663e57049e56e59cace5aa2f7 test/orm/test_relationships.py --- a/test/orm/test_relationships.py Thu Feb 16 19:29:00 2012 -0500 +++ b/test/orm/test_relationships.py Sat Feb 18 08:39:33 2012 -0500 @@ -202,7 +202,7 @@ 'company':relationship(Company, backref='employees'), 'reports_to':relationship(Employee, remote_side=[employee_t.c.company_id](employee_t.c.emp_id,), - foreign_keys=[employee_t.c.reports_to_id](employee_t.c.reports_to_id), + foreign_keys=[employee_t.c.company_id](employee_t.c.reports_to_id,), backref=backref('employees', foreign_keys=None) ) }) @@ -240,7 +240,7 @@ (employee_t.c.reports_to_id, employee_t.c.emp_id), (employee_t.c.company_id, employee_t.c.company_id) ], - foreign_keys=[employee_t.c.reports_to_id](employee_t.c.reports_to_id), + foreign_keys=[employee_t.c.company_id](employee_t.c.reports_to_id,), backref=backref('employees', foreign_keys=None) ) })"><pre class="notranslate"><code class="notranslate">diff -r 35cba3c84ab9c36663e57049e56e59cace5aa2f7 lib/sqlalchemy/orm/properties.py --- a/lib/sqlalchemy/orm/properties.py Thu Feb 16 19:29:00 2012 -0500 +++ b/lib/sqlalchemy/orm/properties.py Sat Feb 18 08:39:33 2012 -0500 @@ -1030,7 +1030,8 @@ # general mapped table, which in the case of inheritance is # a join. return join_condition(mapper.mapped_table, table, - a_subset=mapper.local_table) + a_subset=mapper.local_table, + consider_as_foreign_keys=self._user_defined_foreign_keys) try: if self.secondary is not None: diff -r 35cba3c84ab9c36663e57049e56e59cace5aa2f7 lib/sqlalchemy/sql/util.py --- a/lib/sqlalchemy/sql/util.py Thu Feb 16 19:29:00 2012 -0500 +++ b/lib/sqlalchemy/sql/util.py Sat Feb 18 08:39:33 2012 -0500 @@ -225,7 +225,10 @@ return visitors.cloned_traverse(crit, {}, {'binary':visit_binary}) -def join_condition(a, b, ignore_nonexistent_tables=False, a_subset=None): +def join_condition(a, b, + ignore_nonexistent_tables=False, + a_subset=None, + consider_as_foreign_keys=None): """create a join condition between two tables or selectables. e.g.:: @@ -269,6 +272,9 @@ else: continue + if consider_as_foreign_keys and \ + fk.parent not in consider_as_foreign_keys: + continue if col is not None: crit.append(col == fk.parent) constraints.add(fk.constraint) @@ -286,6 +292,9 @@ # coverage to mark it. continue + if consider_as_foreign_keys and \ + fk.parent not in consider_as_foreign_keys: + continue if col is not None: crit.append(col == fk.parent) constraints.add(fk.constraint) diff -r 35cba3c84ab9c36663e57049e56e59cace5aa2f7 test/orm/test_relationships.py --- a/test/orm/test_relationships.py Thu Feb 16 19:29:00 2012 -0500 +++ b/test/orm/test_relationships.py Sat Feb 18 08:39:33 2012 -0500 @@ -202,7 +202,7 @@ 'company':relationship(Company, backref='employees'), 'reports_to':relationship(Employee, remote_side=[employee_t.c.company_id](employee_t.c.emp_id,), - foreign_keys=[employee_t.c.reports_to_id](employee_t.c.reports_to_id), + foreign_keys=[employee_t.c.company_id](employee_t.c.reports_to_id,), backref=backref('employees', foreign_keys=None) ) }) @@ -240,7 +240,7 @@ (employee_t.c.reports_to_id, employee_t.c.emp_id), (employee_t.c.company_id, employee_t.c.company_id) ], - foreign_keys=[employee_t.c.reports_to_id](employee_t.c.reports_to_id), + foreign_keys=[employee_t.c.company_id](employee_t.c.reports_to_id,), backref=backref('employees', foreign_keys=None) ) }) </code></pre></div> <p dir="auto">works great for the usual case of multiple foreign keys:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="from sqlalchemy import * from sqlalchemy.orm import * from sqlalchemy.ext.declarative import declarative_base Base= declarative_base() class Project(Base): __tablename__ = 'project' id = Column(String(100), primary_key=True) client_id = Column(String(80), ForeignKey('user.username')) creator_id = Column(String(80), ForeignKey('user.username')) workers = relationship(&quot;User&quot;, backref=&quot;assigned_project&quot;, foreign_keys=&quot;User.project_id&quot;, ) client = relationship(&quot;User&quot;, backref=&quot;owned_projects&quot;, foreign_keys=client_id, post_update=True) creator = relationship(&quot;User&quot;, backref=&quot;created_projects&quot;, foreign_keys=creator_id, post_update=True) class User(Base): __tablename__ = 'user' username = Column(String(80), primary_key=True) project_id = Column(String(100), ForeignKey(&quot;project.id&quot;, use_alter=True, name=&quot;fk_user_project_id&quot;)) e = create_engine(&quot;sqlite://&quot;, echo=True) Base.metadata.create_all(e) s = Session(e) p1 = Project(id=&quot;someproject&quot;) u1 = User(username=&quot;someuser&quot;) p1.client = p1.creator = u1 u1.assigned_project = p1 s.add(u1) s.commit()"><pre class="notranslate"><code class="notranslate">from sqlalchemy import * from sqlalchemy.orm import * from sqlalchemy.ext.declarative import declarative_base Base= declarative_base() class Project(Base): __tablename__ = 'project' id = Column(String(100), primary_key=True) client_id = Column(String(80), ForeignKey('user.username')) creator_id = Column(String(80), ForeignKey('user.username')) workers = relationship("User", backref="assigned_project", foreign_keys="User.project_id", ) client = relationship("User", backref="owned_projects", foreign_keys=client_id, post_update=True) creator = relationship("User", backref="created_projects", foreign_keys=creator_id, post_update=True) class User(Base): __tablename__ = 'user' username = Column(String(80), primary_key=True) project_id = Column(String(100), ForeignKey("project.id", use_alter=True, name="fk_user_project_id")) e = create_engine("sqlite://", echo=True) Base.metadata.create_all(e) s = Session(e) p1 = Project(id="someproject") u1 = User(username="someuser") p1.client = p1.creator = u1 u1.assigned_project = p1 s.add(u1) s.commit() </code></pre></div>
<p dir="auto"><strong>Describe the bug</strong><br> I've created a custom column type, which converts "Y" and "N" from within the database to <code class="notranslate">True</code> and <code class="notranslate">False</code> in the python context and vice versa. I choose to implement it as an enum type.</p> <p dir="auto">This all works well. Now I've started to use naming convention for constraints and my oracle database suddenly complains about a duplicate constraint names.</p> <p dir="auto">For debugging and finding a minimal example I used sqlite as the database engine and don't used naming convention (because it seem sqlite just overwrite the first appearance of a constraint name). The code below indeed creates two check constraints with the same content. Why?</p> <p dir="auto"><strong>Expected behavior</strong></p> <p dir="auto">Only one check constraint should be created.</p> <p dir="auto"><strong>To Reproduce</strong></p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import enum from pathlib import Path from typing import Any, Type from sqlalchemy import Column, Integer, String, create_engine, text, types from sqlalchemy.ext.declarative import declarative_base Base = declarative_base() class BoolYN(types.TypeDecorator): impl = types.Enum def __init__(self, *args: Any, **kwargs: Any): super().__init__(&quot;Y&quot;, &quot;N&quot;, *args, **kwargs) def process_literal_param(self, value: bool, dialect: Any) -&gt; str: &quot;&quot;&quot; Converts bool value passed to literal value on inserting to database. aka python --&gt; column &quot;&quot;&quot; if value is True: return &quot;Y&quot; elif value is False: return &quot;N&quot; else: raise TypeError(f&quot;{value} is not of type bool&quot;) process_bind_param = process_literal_param def process_result_value(self, value: str, dialect: Any) -&gt; bool: &quot;&quot;&quot; Convert combined enum value to associated single enum type. aka column --&gt; python &quot;&quot;&quot; if value == &quot;Y&quot;: return True elif value == &quot;N&quot;: return False else: raise ValueError(f&quot;{value} cannot be converted to a bool&quot;) class User(Base): __tablename__ = &quot;users&quot; id = Column(Integer, primary_key=True) name = Column(String) active = Column( BoolYN(length=1, native_enum=False, create_constraint=True), nullable=False, server_default=text(&quot;'N'&quot;), ) def main(): if Path(&quot;custom_type_db.db&quot;).exists(): Path(&quot;custom_type_db.db&quot;).unlink() engine = create_engine(&quot;sqlite:///custom_type_db.db&quot;, echo=&quot;debug&quot;) Base.metadata.create_all(engine) if __name__ == &quot;__main__&quot;: main()"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">enum</span> <span class="pl-k">from</span> <span class="pl-s1">pathlib</span> <span class="pl-k">import</span> <span class="pl-v">Path</span> <span class="pl-k">from</span> <span class="pl-s1">typing</span> <span class="pl-k">import</span> <span class="pl-v">Any</span>, <span class="pl-v">Type</span> <span class="pl-k">from</span> <span class="pl-s1">sqlalchemy</span> <span class="pl-k">import</span> <span class="pl-v">Column</span>, <span class="pl-v">Integer</span>, <span class="pl-v">String</span>, <span class="pl-s1">create_engine</span>, <span class="pl-s1">text</span>, <span class="pl-s1">types</span> <span class="pl-k">from</span> <span class="pl-s1">sqlalchemy</span>.<span class="pl-s1">ext</span>.<span class="pl-s1">declarative</span> <span class="pl-k">import</span> <span class="pl-s1">declarative_base</span> <span class="pl-v">Base</span> <span class="pl-c1">=</span> <span class="pl-en">declarative_base</span>() <span class="pl-k">class</span> <span class="pl-v">BoolYN</span>(<span class="pl-s1">types</span>.<span class="pl-v">TypeDecorator</span>): <span class="pl-s1">impl</span> <span class="pl-c1">=</span> <span class="pl-s1">types</span>.<span class="pl-v">Enum</span> <span class="pl-k">def</span> <span class="pl-en">__init__</span>(<span class="pl-s1">self</span>, <span class="pl-c1">*</span><span class="pl-s1">args</span>: <span class="pl-v">Any</span>, <span class="pl-c1">**</span><span class="pl-s1">kwargs</span>: <span class="pl-v">Any</span>): <span class="pl-en">super</span>().<span class="pl-en">__init__</span>(<span class="pl-s">"Y"</span>, <span class="pl-s">"N"</span>, <span class="pl-c1">*</span><span class="pl-s1">args</span>, <span class="pl-c1">**</span><span class="pl-s1">kwargs</span>) <span class="pl-k">def</span> <span class="pl-en">process_literal_param</span>(<span class="pl-s1">self</span>, <span class="pl-s1">value</span>: <span class="pl-s1">bool</span>, <span class="pl-s1">dialect</span>: <span class="pl-v">Any</span>) <span class="pl-c1">-&gt;</span> <span class="pl-s1">str</span>: <span class="pl-s">"""</span> <span class="pl-s"> Converts bool value passed to literal value on inserting to database.</span> <span class="pl-s"></span> <span class="pl-s"> aka python --&gt; column</span> <span class="pl-s"> """</span> <span class="pl-k">if</span> <span class="pl-s1">value</span> <span class="pl-c1">is</span> <span class="pl-c1">True</span>: <span class="pl-k">return</span> <span class="pl-s">"Y"</span> <span class="pl-k">elif</span> <span class="pl-s1">value</span> <span class="pl-c1">is</span> <span class="pl-c1">False</span>: <span class="pl-k">return</span> <span class="pl-s">"N"</span> <span class="pl-k">else</span>: <span class="pl-k">raise</span> <span class="pl-v">TypeError</span>(<span class="pl-s">f"<span class="pl-s1"><span class="pl-kos">{</span><span class="pl-s1">value</span><span class="pl-kos">}</span></span> is not of type bool"</span>) <span class="pl-s1">process_bind_param</span> <span class="pl-c1">=</span> <span class="pl-s1">process_literal_param</span> <span class="pl-k">def</span> <span class="pl-en">process_result_value</span>(<span class="pl-s1">self</span>, <span class="pl-s1">value</span>: <span class="pl-s1">str</span>, <span class="pl-s1">dialect</span>: <span class="pl-v">Any</span>) <span class="pl-c1">-&gt;</span> <span class="pl-s1">bool</span>: <span class="pl-s">"""</span> <span class="pl-s"> Convert combined enum value to associated single enum type.</span> <span class="pl-s"></span> <span class="pl-s"> aka column --&gt; python</span> <span class="pl-s"> """</span> <span class="pl-k">if</span> <span class="pl-s1">value</span> <span class="pl-c1">==</span> <span class="pl-s">"Y"</span>: <span class="pl-k">return</span> <span class="pl-c1">True</span> <span class="pl-k">elif</span> <span class="pl-s1">value</span> <span class="pl-c1">==</span> <span class="pl-s">"N"</span>: <span class="pl-k">return</span> <span class="pl-c1">False</span> <span class="pl-k">else</span>: <span class="pl-k">raise</span> <span class="pl-v">ValueError</span>(<span class="pl-s">f"<span class="pl-s1"><span class="pl-kos">{</span><span class="pl-s1">value</span><span class="pl-kos">}</span></span> cannot be converted to a bool"</span>) <span class="pl-k">class</span> <span class="pl-v">User</span>(<span class="pl-v">Base</span>): <span class="pl-s1">__tablename__</span> <span class="pl-c1">=</span> <span class="pl-s">"users"</span> <span class="pl-s1">id</span> <span class="pl-c1">=</span> <span class="pl-v">Column</span>(<span class="pl-v">Integer</span>, <span class="pl-s1">primary_key</span><span class="pl-c1">=</span><span class="pl-c1">True</span>) <span class="pl-s1">name</span> <span class="pl-c1">=</span> <span class="pl-v">Column</span>(<span class="pl-v">String</span>) <span class="pl-s1">active</span> <span class="pl-c1">=</span> <span class="pl-v">Column</span>( <span class="pl-v">BoolYN</span>(<span class="pl-s1">length</span><span class="pl-c1">=</span><span class="pl-c1">1</span>, <span class="pl-s1">native_enum</span><span class="pl-c1">=</span><span class="pl-c1">False</span>, <span class="pl-s1">create_constraint</span><span class="pl-c1">=</span><span class="pl-c1">True</span>), <span class="pl-s1">nullable</span><span class="pl-c1">=</span><span class="pl-c1">False</span>, <span class="pl-s1">server_default</span><span class="pl-c1">=</span><span class="pl-en">text</span>(<span class="pl-s">"'N'"</span>), ) <span class="pl-k">def</span> <span class="pl-en">main</span>(): <span class="pl-k">if</span> <span class="pl-v">Path</span>(<span class="pl-s">"custom_type_db.db"</span>).<span class="pl-en">exists</span>(): <span class="pl-v">Path</span>(<span class="pl-s">"custom_type_db.db"</span>).<span class="pl-en">unlink</span>() <span class="pl-s1">engine</span> <span class="pl-c1">=</span> <span class="pl-en">create_engine</span>(<span class="pl-s">"sqlite:///custom_type_db.db"</span>, <span class="pl-s1">echo</span><span class="pl-c1">=</span><span class="pl-s">"debug"</span>) <span class="pl-v">Base</span>.<span class="pl-s1">metadata</span>.<span class="pl-en">create_all</span>(<span class="pl-s1">engine</span>) <span class="pl-k">if</span> <span class="pl-s1">__name__</span> <span class="pl-c1">==</span> <span class="pl-s">"__main__"</span>: <span class="pl-en">main</span>()</pre></div> <p dir="auto"><strong>Error</strong></p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/2164565/112795622-126c8600-9069-11eb-8b85-68edc80ef31b.png"><img src="https://user-images.githubusercontent.com/2164565/112795622-126c8600-9069-11eb-8b85-68edc80ef31b.png" alt="duplicate_constraint" style="max-width: 100%;"></a></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="2021-03-29 08:43:31,474 INFO sqlalchemy.engine.base.Engine SELECT CAST('test plain returns' AS VARCHAR(60)) AS anon_1 2021-03-29 08:43:31,474 INFO sqlalchemy.engine.base.Engine () 2021-03-29 08:43:31,474 INFO sqlalchemy.engine.base.Engine SELECT CAST('test unicode returns' AS VARCHAR(60)) AS anon_1 2021-03-29 08:43:31,474 INFO sqlalchemy.engine.base.Engine () 2021-03-29 08:43:31,475 INFO sqlalchemy.engine.base.Engine PRAGMA main.table_info(&quot;users&quot;) 2021-03-29 08:43:31,475 INFO sqlalchemy.engine.base.Engine () 2021-03-29 08:43:31,475 DEBUG sqlalchemy.engine.base.Engine Col ('cid', 'name', 'type', 'notnull', 'dflt_value', 'pk') 2021-03-29 08:43:31,475 INFO sqlalchemy.engine.base.Engine PRAGMA temp.table_info(&quot;users&quot;) 2021-03-29 08:43:31,475 INFO sqlalchemy.engine.base.Engine () 2021-03-29 08:43:31,475 DEBUG sqlalchemy.engine.base.Engine Col ('cid', 'name', 'type', 'notnull', 'dflt_value', 'pk') 2021-03-29 08:43:31,476 INFO sqlalchemy.engine.base.Engine CREATE TABLE users ( id INTEGER NOT NULL, name VARCHAR, active VARCHAR(1) DEFAULT 'N' NOT NULL, PRIMARY KEY (id), CHECK (active IN ('Y', 'N')), CHECK (active IN ('Y', 'N')) ) 2021-03-29 08:43:31,476 INFO sqlalchemy.engine.base.Engine () 2021-03-29 08:43:31,478 INFO sqlalchemy.engine.base.Engine COMMIT"><pre class="notranslate"><code class="notranslate">2021-03-29 08:43:31,474 INFO sqlalchemy.engine.base.Engine SELECT CAST('test plain returns' AS VARCHAR(60)) AS anon_1 2021-03-29 08:43:31,474 INFO sqlalchemy.engine.base.Engine () 2021-03-29 08:43:31,474 INFO sqlalchemy.engine.base.Engine SELECT CAST('test unicode returns' AS VARCHAR(60)) AS anon_1 2021-03-29 08:43:31,474 INFO sqlalchemy.engine.base.Engine () 2021-03-29 08:43:31,475 INFO sqlalchemy.engine.base.Engine PRAGMA main.table_info("users") 2021-03-29 08:43:31,475 INFO sqlalchemy.engine.base.Engine () 2021-03-29 08:43:31,475 DEBUG sqlalchemy.engine.base.Engine Col ('cid', 'name', 'type', 'notnull', 'dflt_value', 'pk') 2021-03-29 08:43:31,475 INFO sqlalchemy.engine.base.Engine PRAGMA temp.table_info("users") 2021-03-29 08:43:31,475 INFO sqlalchemy.engine.base.Engine () 2021-03-29 08:43:31,475 DEBUG sqlalchemy.engine.base.Engine Col ('cid', 'name', 'type', 'notnull', 'dflt_value', 'pk') 2021-03-29 08:43:31,476 INFO sqlalchemy.engine.base.Engine CREATE TABLE users ( id INTEGER NOT NULL, name VARCHAR, active VARCHAR(1) DEFAULT 'N' NOT NULL, PRIMARY KEY (id), CHECK (active IN ('Y', 'N')), CHECK (active IN ('Y', 'N')) ) 2021-03-29 08:43:31,476 INFO sqlalchemy.engine.base.Engine () 2021-03-29 08:43:31,478 INFO sqlalchemy.engine.base.Engine COMMIT </code></pre></div> <p dir="auto"><strong>Versions.</strong></p> <ul dir="auto"> <li>OS: Ubunto 18.04</li> <li>Python: 3.9</li> <li>SQLAlchemy: 1.3.23 / 1.4.2</li> <li>Database: sqlite</li> <li>DBAPI: sqlite3</li> </ul>
0
<p dir="auto">Hi,</p> <p dir="auto"><strong>VS</strong>: 2015 CTP 5<br> <strong>TS</strong>: 1.4</p> <p dir="auto">In the snapshot below, we are at the point of assigning an inline function to property <code class="notranslate">foo</code>:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/1106823/6485181/beccf034-c279-11e4-80df-688211205fe9.png"><img src="https://cloud.githubusercontent.com/assets/1106823/6485181/beccf034-c279-11e4-80df-688211205fe9.png" alt="image" style="max-width: 100%;"></a></p> <p dir="auto">The intention is to write something like</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="x.foo = bar =&gt; bar.toString();"><pre class="notranslate"><span class="pl-s1">x</span><span class="pl-kos">.</span><span class="pl-en">foo</span> <span class="pl-c1">=</span> <span class="pl-s1">bar</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">bar</span><span class="pl-kos">.</span><span class="pl-en">toString</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <p dir="auto">Clearly, the provided completion list is not very helpful here.</p> <p dir="auto">Furthermore, when the letter <code class="notranslate">b</code> is typed intellisense shows an already <strong>_selected</strong>_ item in the list of completions. By this I mean the item <code class="notranslate">blur</code> is highlighted with a background colour. This provides a misleading impression that an exact match has been identified by the intellisense engine, providing a (false) incentive for the user to hit tab in order to complete the term.</p> <p dir="auto">I believe the more correct behaviour here is to</p> <ul dir="auto"> <li> <p dir="auto">not show intellisense at all unless a type compatible with <code class="notranslate">x.foo</code> exists, or</p> </li> <li> <p dir="auto">only show an outline, similar to the one below:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/1106823/6485490/02464282-c27c-11e4-9055-3237516743df.png"><img src="https://cloud.githubusercontent.com/assets/1106823/6485490/02464282-c27c-11e4-9055-3237516743df.png" alt="image" style="max-width: 100%;"></a></p> </li> </ul>
<p dir="auto">VS now commits completion lists on more than tab and enter, including space and a variety of punctuation characters (semicolon, parens, brackets, etc). There are places where we offer completion lists that we shouldn't, or poor completion lists, which were previously visual distractions but now are significant annoyances in the actual typing experience, requiring constantly dismissing completion lists via Esc to type what you intended.</p> <p dir="auto"><strong>Fat arrow functions</strong><br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/7121557/5688657/d16729f2-980e-11e4-941e-656b974b3a66.gif"><img src="https://cloud.githubusercontent.com/assets/7121557/5688657/d16729f2-980e-11e4-941e-656b974b3a66.gif" alt="writealambda" data-animated-image="" style="max-width: 100%;"></a><br> Typing a space after the fat arrow argument commits a suggestion that is never correct, and then happens frequently in the body as well.</p> <p dir="auto"><strong>Type argument declarations</strong><br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/7121557/5689110/4b9db39e-9814-11e4-8b4d-1e69299feeed.gif"><img src="https://cloud.githubusercontent.com/assets/7121557/5689110/4b9db39e-9814-11e4-8b4d-1e69299feeed.gif" alt="typeargumentcompletion" data-animated-image="" style="max-width: 100%;"></a><br> Tracked here <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="51510680" data-permission-text="Title is private" data-url="https://github.com/microsoft/TypeScript/issues/1428" data-hovercard-type="issue" data-hovercard-url="/microsoft/TypeScript/issues/1428/hovercard" href="https://github.com/microsoft/TypeScript/issues/1428">#1428</a></p> <p dir="auto"><strong>Destrucuring Assignments</strong><br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/7121557/5689074/ee4c0a92-9813-11e4-8a37-8a0710464913.gif"><img src="https://cloud.githubusercontent.com/assets/7121557/5689074/ee4c0a92-9813-11e4-8a37-8a0710464913.gif" alt="destructuringcompletions" data-animated-image="" style="max-width: 100%;"></a><br> Not supported in the editor yet but will need to work like var declaration completion lists.</p> <p dir="auto">There are likely other cases as well but these ones stand out immediately. This also ties into <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="39123893" data-permission-text="Title is private" data-url="https://github.com/microsoft/TypeScript/issues/315" data-hovercard-type="issue" data-hovercard-url="/microsoft/TypeScript/issues/315/hovercard" href="https://github.com/microsoft/TypeScript/issues/315">#315</a> which is asking for a toggle on this behavior. Depending on the fix we use for this behavior we may also have some significant test costs associated with these fixes.</p>
1
<p dir="auto"><strong>Is this a request for help?</strong> (If yes, you should use our troubleshooting guide and community support channels, see <a href="http://kubernetes.io/docs/troubleshooting/" rel="nofollow">http://kubernetes.io/docs/troubleshooting/</a>.):</p> <p dir="auto"><strong>What keywords did you search in Kubernetes issues before filing this one?</strong> (If you have found any duplicates, you should instead reply there.):</p> <hr> <p dir="auto"><strong>Is this a BUG REPORT or FEATURE REQUEST?</strong> (choose one):</p> <p dir="auto"><strong>Kubernetes version</strong> (use <code class="notranslate">kubectl version</code>):<br> v1.3.7</p> <p dir="auto"><strong>Environment</strong>:</p> <ul dir="auto"> <li><strong>Cloud provider or hardware configuration</strong>:</li> <li><strong>OS</strong> (e.g. from /etc/os-release): centOS 7</li> <li><strong>Kernel</strong> (e.g. <code class="notranslate">uname -a</code>):Linux zhouzong-1-e426f249-e94c-439d-a300-ae836e93dada 3.10.0-327.el7.x86_64 <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="35192559" data-permission-text="Title is private" data-url="https://github.com/kubernetes/kubernetes/issues/1" data-hovercard-type="issue" data-hovercard-url="/kubernetes/kubernetes/issues/1/hovercard" href="https://github.com/kubernetes/kubernetes/issues/1">#1</a> SMP Thu Nov 19 22:10:57 UTC 2015 x86_64 x86_64 x86_64 GNU/Linux</li> <li><strong>Install tools</strong>:</li> <li><strong>Others</strong>:</li> </ul> <p dir="auto"><strong>What happened</strong>:<br> 1.After running : /home/cmcc/k8s_1.3.7/cluster/images/hyperkube/make build VERSION=v1.3.7,the error below happened.</p> <p dir="auto">cp ../../../_output/dockerized/bin/linux/amd64/hyperkube /tmp/tmp.HzRR8SYT3E<br> cp: cannot stat ‘../../../_output/dockerized/bin/linux/amd64/hyperkube’: No such file or directory<br> make: *** [build] Error 1</p> <p dir="auto">2.According to README, "# First, build the binaries:$ build/run.sh hack/build-cross.sh", after running" build/run.sh: No such file or directory" " hack/build-cross.sh: No such file or directory"</p> <p dir="auto"><strong>What you expected to happen</strong>:</p> <p dir="auto">the necessary files for building images should be tarred together. we suggest you do it first.</p> <p dir="auto"><strong>How to reproduce it</strong> (as minimally and precisely as possible):<br> always happen when you build the hypercube image.</p> <p dir="auto"><strong>Anything else do we need to know</strong>:</p>
<p dir="auto">Ran into a flaky test</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="--- FAIL: TestSyncPodsDoesNothing (0.00 seconds) kubelet_test.go:57: expected []string{&quot;list&quot;}, got []string{&quot;list&quot;, &quot;list&quot;, &quot;inspect_container&quot;, &quot;inspect_container&quot;} I1028 22:40:10.479932 00811 docker.go:304] Docker Container: foo is not managed by kubelet. E1028 22:40:10.480297 00811 kubelet.go:641] Unable to get pod with name bar.new.test and uuid info, health checks may be invalid E1028 22:40:10.480548 00811 kubelet.go:641] Unable to get pod with name foo.new.test and uuid info, health checks may be invalid E1028 22:40:10.480865 00811 kubelet.go:641] Unable to get pod with name foo.new.test and uuid info, health checks may be invalid W1028 22:40:10.481460 00811 kubelet.go:337] Unknown protocol '': defaulting to TCP W1028 22:40:10.481494 00811 kubelet.go:337] Unknown protocol 'foobar': defaulting to TCP W1028 22:40:10.481721 00811 kubelet.go:901] Pod ..: HostPort is already allocated, ignoring: [[0].port: duplicate value '81'] E1028 22:40:10.483264 00811 kubelet.go:415] Invalid handler: &amp;{&lt;nil&gt; &lt;nil&gt;} E1028 22:40:10.483415 00811 kubelet.go:641] Unable to get pod with name foo.new.test and uuid info, health checks may be invalid E1028 22:40:10.483619 00811 kubelet.go:747] Error running pod foo.new.test container bar: failed to call event handler: test error I1028 22:40:10.484245 00811 runonce.go:62] waiting for 1 pods I1028 22:40:10.484334 00811 runonce.go:138] container &quot;bar&quot; not found I1028 22:40:10.484365 00811 runonce.go:112] pod &quot;foo&quot; containers not running: syncing E1028 22:40:10.484561 00811 kubelet.go:641] Unable to get pod with name foo.new.test and uuid info, health checks may be invalid I1028 22:40:10.484726 00811 runonce.go:124] pod &quot;foo&quot; containers synced, waiting for 1s I1028 22:40:11.485208 00811 runonce.go:108] pod &quot;foo&quot; containers running I1028 22:40:11.485265 00811 runonce.go:75] started pod &quot;foo&quot; I1028 22:40:11.485303 00811 runonce.go:84] 1 pods started 2014/10/28 22:40:11 http: WriteHeader called with both Transfer-Encoding of &quot;chunked&quot; and a Content-Length of 0 2014/10/28 22:40:11 http: WriteHeader called with both Transfer-Encoding of &quot;chunked&quot; and a Content-Length of 0 2014/10/28 22:40:11 http: WriteHeader called with both Transfer-Encoding of &quot;chunked&quot; and a Content-Length of 0 FAIL coverage: 68.7% of statements FAIL github.com/GoogleCloudPlatform/kubernetes/pkg/kubelet 1.542s"><pre class="notranslate"><code class="notranslate">--- FAIL: TestSyncPodsDoesNothing (0.00 seconds) kubelet_test.go:57: expected []string{"list"}, got []string{"list", "list", "inspect_container", "inspect_container"} I1028 22:40:10.479932 00811 docker.go:304] Docker Container: foo is not managed by kubelet. E1028 22:40:10.480297 00811 kubelet.go:641] Unable to get pod with name bar.new.test and uuid info, health checks may be invalid E1028 22:40:10.480548 00811 kubelet.go:641] Unable to get pod with name foo.new.test and uuid info, health checks may be invalid E1028 22:40:10.480865 00811 kubelet.go:641] Unable to get pod with name foo.new.test and uuid info, health checks may be invalid W1028 22:40:10.481460 00811 kubelet.go:337] Unknown protocol '': defaulting to TCP W1028 22:40:10.481494 00811 kubelet.go:337] Unknown protocol 'foobar': defaulting to TCP W1028 22:40:10.481721 00811 kubelet.go:901] Pod ..: HostPort is already allocated, ignoring: [[0].port: duplicate value '81'] E1028 22:40:10.483264 00811 kubelet.go:415] Invalid handler: &amp;{&lt;nil&gt; &lt;nil&gt;} E1028 22:40:10.483415 00811 kubelet.go:641] Unable to get pod with name foo.new.test and uuid info, health checks may be invalid E1028 22:40:10.483619 00811 kubelet.go:747] Error running pod foo.new.test container bar: failed to call event handler: test error I1028 22:40:10.484245 00811 runonce.go:62] waiting for 1 pods I1028 22:40:10.484334 00811 runonce.go:138] container "bar" not found I1028 22:40:10.484365 00811 runonce.go:112] pod "foo" containers not running: syncing E1028 22:40:10.484561 00811 kubelet.go:641] Unable to get pod with name foo.new.test and uuid info, health checks may be invalid I1028 22:40:10.484726 00811 runonce.go:124] pod "foo" containers synced, waiting for 1s I1028 22:40:11.485208 00811 runonce.go:108] pod "foo" containers running I1028 22:40:11.485265 00811 runonce.go:75] started pod "foo" I1028 22:40:11.485303 00811 runonce.go:84] 1 pods started 2014/10/28 22:40:11 http: WriteHeader called with both Transfer-Encoding of "chunked" and a Content-Length of 0 2014/10/28 22:40:11 http: WriteHeader called with both Transfer-Encoding of "chunked" and a Content-Length of 0 2014/10/28 22:40:11 http: WriteHeader called with both Transfer-Encoding of "chunked" and a Content-Length of 0 FAIL coverage: 68.7% of statements FAIL github.com/GoogleCloudPlatform/kubernetes/pkg/kubelet 1.542s </code></pre></div>
0
<p dir="auto"><strong>Migrated issue, originally created by Anonymous</strong></p> <p dir="auto">Versions of Firebird prior to 2.0 were subject to the following bug <a href="http://tracker.firebirdsql.org/browse/CORE-356" rel="nofollow">http://tracker.firebirdsql.org/browse/CORE-356</a></p> <p dir="auto">The gist of CORE-356 is that values in the RDB$DEFAULT_SOURCE column of the RDB$RELATION_FIELDS table can have leading whitespace.</p> <p dir="auto">Trying to use meta.reflect on one of these tables results in errors like this:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="File &quot;.../site-packages/sqlalchemy/databases/firebird.py&quot;, line 501, in reflecttable assert row['fdefault']('fdefault').upper().startswith('DEFAULT '), row AssertionError: (u'ARCHIVED ', None, u'TEXT', 0, 1, None, 0, &quot; DEFAULT 'N'&quot;)"><pre class="notranslate"><code class="notranslate">File ".../site-packages/sqlalchemy/databases/firebird.py", line 501, in reflecttable assert row['fdefault']('fdefault').upper().startswith('DEFAULT '), row AssertionError: (u'ARCHIVED ', None, u'TEXT', 0, 1, None, 0, " DEFAULT 'N'") </code></pre></div> <p dir="auto">A simple fix for this is to add a TRIM to the tblqry around the COALESCE or since the fdefault value is being modified with .upper anyway line 501 might be a better spot to "fix" this</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="assert row['fdefault']('fdefault').upper().lstrip().startswith('DEFAULT '), row"><pre class="notranslate"><code class="notranslate">assert row['fdefault']('fdefault').upper().lstrip().startswith('DEFAULT '), row </code></pre></div>
<p dir="auto"><strong>Migrated issue, originally created by Anonymous</strong></p> <p dir="auto">During schema reflection SQLAlchemy fails with AssertionError</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Traceback (most recent call last): File &quot;/tmp/sqla2.py&quot;, line 190, in &lt;module&gt; concentrate=False # Don't try to join the relation lines together File &quot;/tmp/sqla2.py&quot;, line 132, in create_schema_graph metadata.reflect() File &quot;/home/filip/tefnet/teferp/workspace/tefobjects/lib/python2.5/site-packages/SQLAlchemy-0.5.5-py2.5.egg/sqlalchemy/schema.py&quot;, line 1733, in reflect Table(name, self, **reflect_opts) File &quot;/home/filip/tefnet/teferp/workspace/tefobjects/lib/python2.5/site-packages/SQLAlchemy-0.5.5-py2.5.egg/sqlalchemy/schema.py&quot;, line 108, in __call__ return type.__call__(self, name, metadata, *args, **kwargs) File &quot;/home/filip/tefnet/teferp/workspace/tefobjects/lib/python2.5/site-packages/SQLAlchemy-0.5.5-py2.5.egg/sqlalchemy/schema.py&quot;, line 236, in __init__ _bind_or_error(metadata).reflecttable(self, include_columns=include_columns) File &quot;/home/filip/tefnet/teferp/workspace/tefobjects/lib/python2.5/site-packages/SQLAlchemy-0.5.5-py2.5.egg/sqlalchemy/engine/base.py&quot;, line 1265, in reflecttable self.dialect.reflecttable(conn, table, include_columns) File &quot;/mnt/tmp/tefnet/teferp/workspace/tefobjects/lib/python2.5/site-packages/SQLAlchemy-0.5.5-py2.5.egg/sqlalchemy/databases/firebird.py&quot;, line 502, in reflecttable assert row['fdefault']('fdefault').upper().startswith('DEFAULT '), row AssertionError: (u'DATAREJ ', 1, u'DATE ', None, 4, None, 0, ' DEFAULT CURRENT_DATE')"><pre class="notranslate"><code class="notranslate">Traceback (most recent call last): File "/tmp/sqla2.py", line 190, in &lt;module&gt; concentrate=False # Don't try to join the relation lines together File "/tmp/sqla2.py", line 132, in create_schema_graph metadata.reflect() File "/home/filip/tefnet/teferp/workspace/tefobjects/lib/python2.5/site-packages/SQLAlchemy-0.5.5-py2.5.egg/sqlalchemy/schema.py", line 1733, in reflect Table(name, self, **reflect_opts) File "/home/filip/tefnet/teferp/workspace/tefobjects/lib/python2.5/site-packages/SQLAlchemy-0.5.5-py2.5.egg/sqlalchemy/schema.py", line 108, in __call__ return type.__call__(self, name, metadata, *args, **kwargs) File "/home/filip/tefnet/teferp/workspace/tefobjects/lib/python2.5/site-packages/SQLAlchemy-0.5.5-py2.5.egg/sqlalchemy/schema.py", line 236, in __init__ _bind_or_error(metadata).reflecttable(self, include_columns=include_columns) File "/home/filip/tefnet/teferp/workspace/tefobjects/lib/python2.5/site-packages/SQLAlchemy-0.5.5-py2.5.egg/sqlalchemy/engine/base.py", line 1265, in reflecttable self.dialect.reflecttable(conn, table, include_columns) File "/mnt/tmp/tefnet/teferp/workspace/tefobjects/lib/python2.5/site-packages/SQLAlchemy-0.5.5-py2.5.egg/sqlalchemy/databases/firebird.py", line 502, in reflecttable assert row['fdefault']('fdefault').upper().startswith('DEFAULT '), row AssertionError: (u'DATAREJ ', 1, u'DATE ', None, 4, None, 0, ' DEFAULT CURRENT_DATE') </code></pre></div> <p dir="auto">The problem is because 'DEFAULT' sometimes has whitespaces at the begining</p> <hr> <p dir="auto">Attachments: <a href="../wiki/imported_issue_attachments/1582/tef_firebird_default_reflection.patch">tef_firebird_default_reflection.patch</a></p>
1
<p dir="auto">I recently ran into an issue whereby curve_fit was failing to fit a function, even though the guesses were reasonable. The warning reported by Scipy was "/usr/local/depot/Python-3.5.1/lib/python3.5/site-packages/scipy/optimize/minpack.py:690: OptimizeWarning: Covariance of the parameters could not be estimated".</p> <p dir="auto">After hours of searching, I discovered that the problem was that I was using np.float32 arrays for the x and y data. Simply using x.astype(np.float64) resolved the issue. Though the warning provided no help or hints as to the source of the problem.</p> <p dir="auto">This is similar to what was reported in this (rather old) email thread: <a href="http://scipy-user.scipy.narkive.com/wSafjCiz/curve-fit-with-float32-values" rel="nofollow">http://scipy-user.scipy.narkive.com/wSafjCiz/curve-fit-with-float32-values</a>, which proved to be very difficult to find. It would be useful to warn in the curve_fit documentation (and other minimisation functions) about using float32 inputs, particularly as the problem only manifests itself with certain data sets.</p>
<p dir="auto">Hello, I have some data where inadvertently the x and y data were of different types, eventually after much troubleshooting I discovered that one was <code class="notranslate">np.float32</code> and the other was <code class="notranslate">np.float64</code>. When trying to use least-squares minimization to fit to the data, either <code class="notranslate">scipy.optimize.curve_fit</code> or <code class="notranslate">scipy.optimize.leastsq</code> failed in a weird quasi-silent way. The failure mode is that the parameters are barely changed from the initial guess and the optimization returns even though the result is clearly not good. Below is a minimum example demonstrating the bug (from a jupyter notebook):</p> <h3 dir="auto">Reproducing code example:</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="%pylab inline import numpy as np from scipy.optimize import curve_fit def gauss(x, A, mu, sigma): return A/(sigma*np.sqrt(2*np.pi))*np.exp(-(np.power(x-mu,2)/(2*np.power(sigma,2)))) xdata = np.linspace(-1, 1, 20) p_act = [1.4, 0.2, 0.2] ydata = gauss(xdata, *p_act) + np.random.normal(loc=0, scale=0.05, size=len(xdata)) p0 = [1, 0, 0.1] xdata = xdata.astype(dtype=np.float32) ydata = ydata.astype(dtype=np.float64) fit1, pcov1 = curve_fit(gauss, xdata, ydata, p0=p0) xdata = xdata.astype(dtype=np.float32) ydata = ydata.astype(dtype=np.float32) fit2, pcov2 = curve_fit(gauss, xdata, ydata, p0=p0) print(fit1) print(fit2) plot(xdata, ydata, 'bo') x2 = np.linspace(xdata[0], xdata[-1], 100) plot(x2, gauss(x2, *fit1), 'r--') plot(x2, gauss(x2, *fit2), 'm--')"><pre class="notranslate"><code class="notranslate">%pylab inline import numpy as np from scipy.optimize import curve_fit def gauss(x, A, mu, sigma): return A/(sigma*np.sqrt(2*np.pi))*np.exp(-(np.power(x-mu,2)/(2*np.power(sigma,2)))) xdata = np.linspace(-1, 1, 20) p_act = [1.4, 0.2, 0.2] ydata = gauss(xdata, *p_act) + np.random.normal(loc=0, scale=0.05, size=len(xdata)) p0 = [1, 0, 0.1] xdata = xdata.astype(dtype=np.float32) ydata = ydata.astype(dtype=np.float64) fit1, pcov1 = curve_fit(gauss, xdata, ydata, p0=p0) xdata = xdata.astype(dtype=np.float32) ydata = ydata.astype(dtype=np.float32) fit2, pcov2 = curve_fit(gauss, xdata, ydata, p0=p0) print(fit1) print(fit2) plot(xdata, ydata, 'bo') x2 = np.linspace(xdata[0], xdata[-1], 100) plot(x2, gauss(x2, *fit1), 'r--') plot(x2, gauss(x2, *fit2), 'm--') </code></pre></div> <p dir="auto">The output of the print statements are:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[1. 0.05021768 0.10987875] [1.37911003 0.19699727 0.19586094]"><pre class="notranslate"><code class="notranslate">[1. 0.05021768 0.10987875] [1.37911003 0.19699727 0.19586094] </code></pre></div> <h3 dir="auto">Error message:</h3> <p dir="auto">The only signature is that there is a covariance warning when fitting with the different data types:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="/usr/local/lib/python3.7/site-packages/scipy/optimize/minpack.py:794: OptimizeWarning: Covariance of the parameters could not be estimated category=OptimizeWarning)"><pre class="notranslate"><code class="notranslate">/usr/local/lib/python3.7/site-packages/scipy/optimize/minpack.py:794: OptimizeWarning: Covariance of the parameters could not be estimated category=OptimizeWarning) </code></pre></div> <h3 dir="auto">Scipy/Numpy/Python version information:</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="1.1.0 1.15.1 sys.version_info(major=3, minor=7, micro=1, releaselevel='final', serial=0)"><pre class="notranslate"><code class="notranslate">1.1.0 1.15.1 sys.version_info(major=3, minor=7, micro=1, releaselevel='final', serial=0) </code></pre></div>
1
<p dir="auto">I've been using <a href="https://github.com/jasonmayes/Twitter-Post-Fetcher">twitter-fetcher</a> to circumvent Twitter's latest API without much issues until recently when I started getting the following errors, after posting a duplicate tweet:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[Vue warn]: Duplicate value found in v-for=&quot;tweet in tweets&quot;: &quot;&lt;p class=\&quot;tweet\&quot;&gt;tweet parsed from json file!&lt;/p&gt;&quot;. Use track-by=&quot;$index&quot; if you are expecting duplicate values. vue.js:1174 Uncaught TypeError: Cannot read property 'parentNode' of null. "><pre class="notranslate"><code class="notranslate">[Vue warn]: Duplicate value found in v-for="tweet in tweets": "&lt;p class=\"tweet\"&gt;tweet parsed from json file!&lt;/p&gt;". Use track-by="$index" if you are expecting duplicate values. vue.js:1174 Uncaught TypeError: Cannot read property 'parentNode' of null. </code></pre></div> <p dir="auto">Why would <code class="notranslate">v-for</code> throw an error when there's a duplicate value? I've reproduced the warning <a href="https://ide.c9.io/pierrebonbon/twitter-fetcher" rel="nofollow">here</a></p>
<h3 dir="auto">What problem does this feature solve?</h3> <p dir="auto">make template html more <strong>DRY</strong> by reducing simple component (self-evident?) definitions.</p> <p dir="auto">Many times I find that I declare event methods using the same name as the underlying event, such as</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&lt;a @click=click @mouseover=mouseover :title=title&gt;hello&lt;/a&gt;"><pre class="notranslate"><code class="notranslate">&lt;a @click=click @mouseover=mouseover :title=title&gt;hello&lt;/a&gt; </code></pre></div> <p dir="auto">(where <code class="notranslate">click</code> and <code class="notranslate">mouseover</code> are of course defined as methods for the component, and <code class="notranslate">title</code> is declared within the data() object).</p> <p dir="auto">A cleaner way to do this (imho, and in keeping with javascript's shorthand object notation: e.g. const x = { a, b, c }), a cleaner way may look like this:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&lt;a @click @mouseover :title&gt;hello&lt;/a&gt;"><pre class="notranslate"><code class="notranslate">&lt;a @click @mouseover :title&gt;hello&lt;/a&gt; </code></pre></div> <p dir="auto">This concept could also be extended to binding of variables &amp; props (e.g. :title=title becomes :title).</p> <h3 dir="auto">What does the proposed API look like?</h3> <p dir="auto">the API would not (should not need to) be changed as this would affect only the initial parsing of a template's html.</p> <p dir="auto">I suspect the parts of the code to be modified would be <a href="https://github.com/vuejs/vue/blob/dev/src/compiler/parser/html-parser.js">here</a> and <a href="https://github.com/vuejs/vue/blob/dev/src/compiler/directives/model.js">here</a> but those were too involved for me to attempt.</p>
0
<p dir="auto">Steps to reproduce:</p> <ol dir="auto"> <li>highlight a word</li> </ol> <p dir="auto"><strong>Atom Version</strong>: 0.183.0<br> <strong>System</strong>: Mac OS X 10.10.2<br> <strong>Thrown From</strong>: Atom Core</p> <h3 dir="auto">Stack Trace</h3> <p dir="auto">Uncaught InvalidCharacterError: Failed to execute 'add' on 'DOMTokenList': The token provided ('highlight-selected light-theme background') contains HTML space characters, which are not valid in tokens.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="At /Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:63 Error: Failed to execute 'add' on 'DOMTokenList': The token provided ('highlight-selected light-theme background') contains HTML space characters, which are not valid in tokens. at Error (native) at HighlightsComponent.module.exports.HighlightsComponent.updateHighlightNode (/Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:63:33) at HighlightsComponent.module.exports.HighlightsComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:47:28) at LinesComponent.module.exports.LinesComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/lines-component.js:118:32) at TextEditorComponent.module.exports.TextEditorComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:213:27) at /Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:283:28 at ViewRegistry.module.exports.ViewRegistry.performDocumentUpdate (/Applications/Atom.app/Contents/Resources/app/src/view-registry.js:159:9) at /Applications/Atom.app/Contents/Resources/app/src/view-registry.js:3:61 "><pre class="notranslate"><code class="notranslate">At /Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:63 Error: Failed to execute 'add' on 'DOMTokenList': The token provided ('highlight-selected light-theme background') contains HTML space characters, which are not valid in tokens. at Error (native) at HighlightsComponent.module.exports.HighlightsComponent.updateHighlightNode (/Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:63:33) at HighlightsComponent.module.exports.HighlightsComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:47:28) at LinesComponent.module.exports.LinesComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/lines-component.js:118:32) at TextEditorComponent.module.exports.TextEditorComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:213:27) at /Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:283:28 at ViewRegistry.module.exports.ViewRegistry.performDocumentUpdate (/Applications/Atom.app/Contents/Resources/app/src/view-registry.js:159:9) at /Applications/Atom.app/Contents/Resources/app/src/view-registry.js:3:61 </code></pre></div> <h3 dir="auto">Commands</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" 3x -1:54.3 editor:move-to-end-of-word (atom-text-editor.editor.is-focused) -1:53.3 core:move-right (atom-text-editor.editor.is-focused) -1:53.0 editor:select-to-end-of-word (atom-text-editor.editor.is-focused) 2x -1:49.7 core:save (atom-text-editor.editor.is-focused) -1:29.5 core:backspace (atom-text-editor.editor.is-focused) 2x -1:24.0 core:save (atom-text-editor.editor.is-focused) -1:15.1 editor:select-to-end-of-word (atom-text-editor.editor.is-focused) 2x -1:11.7 core:save (atom-text-editor.editor.is-focused) -0:56.6 core:move-right (atom-text-editor.editor.is-focused) 2x -0:56.0 core:save (atom-text-editor.editor.is-focused) 3x -0:32.8 find-and-replace:select-next (atom-text-editor.editor.is-focused) -0:27.8 core:move-left (atom-text-editor.editor.is-focused) -0:26.0 core:save (atom-text-editor.editor.is-focused) -0:25.0 core:move-to-top (atom-text-editor.editor.is-focused) -0:21.2 core:backspace (atom-text-editor.editor.is-focused) 2x -0:20.2 core:save (atom-text-editor.editor.is-focused)"><pre class="notranslate"><code class="notranslate"> 3x -1:54.3 editor:move-to-end-of-word (atom-text-editor.editor.is-focused) -1:53.3 core:move-right (atom-text-editor.editor.is-focused) -1:53.0 editor:select-to-end-of-word (atom-text-editor.editor.is-focused) 2x -1:49.7 core:save (atom-text-editor.editor.is-focused) -1:29.5 core:backspace (atom-text-editor.editor.is-focused) 2x -1:24.0 core:save (atom-text-editor.editor.is-focused) -1:15.1 editor:select-to-end-of-word (atom-text-editor.editor.is-focused) 2x -1:11.7 core:save (atom-text-editor.editor.is-focused) -0:56.6 core:move-right (atom-text-editor.editor.is-focused) 2x -0:56.0 core:save (atom-text-editor.editor.is-focused) 3x -0:32.8 find-and-replace:select-next (atom-text-editor.editor.is-focused) -0:27.8 core:move-left (atom-text-editor.editor.is-focused) -0:26.0 core:save (atom-text-editor.editor.is-focused) -0:25.0 core:move-to-top (atom-text-editor.editor.is-focused) -0:21.2 core:backspace (atom-text-editor.editor.is-focused) 2x -0:20.2 core:save (atom-text-editor.editor.is-focused) </code></pre></div> <h3 dir="auto">Config</h3> <div class="highlight highlight-source-json notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="{ &quot;core&quot;: { &quot;ignoredNames&quot;: [ &quot;.git&quot;, &quot;.svn&quot;, &quot;.DS_Store&quot; ], &quot;disabledPackages&quot;: [ &quot;language-perl&quot;, &quot;language-php&quot;, &quot;language-python&quot;, &quot;language-ruby-on-rails&quot;, &quot;language-ruby&quot;, &quot;todo-show&quot;, &quot;glist&quot;, &quot;omnisharp-atom&quot;, &quot;minimap&quot;, &quot;minimap-color-highlight&quot;, &quot;minimap-find-and-replace&quot;, &quot;minimap-git-diff&quot;, &quot;minimap-highlight-selected&quot;, &quot;minimap-selection&quot;, &quot;live-archive&quot;, &quot;styleguide&quot;, &quot;autocomplete&quot;, &quot;language-diff&quot; ], &quot;themes&quot;: [ &quot;one-light-ui&quot;, &quot;monokai-light&quot; ], &quot;projectHome&quot;: &quot;/Users/daniel/dev/ds&quot; }, &quot;editor&quot;: { &quot;fontFamily&quot;: &quot;Source Code Pro for Powerline&quot;, &quot;showIndentGuide&quot;: true, &quot;scrollPastEnd&quot;: true, &quot;invisibles&quot;: {}, &quot;fontSize&quot;: 15 } }"><pre class="notranslate">{ <span class="pl-ent">"core"</span>: { <span class="pl-ent">"ignoredNames"</span>: [ <span class="pl-s"><span class="pl-pds">"</span>.git<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>.svn<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>.DS_Store<span class="pl-pds">"</span></span> ], <span class="pl-ent">"disabledPackages"</span>: [ <span class="pl-s"><span class="pl-pds">"</span>language-perl<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>language-php<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>language-python<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>language-ruby-on-rails<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>language-ruby<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>todo-show<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>glist<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>omnisharp-atom<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>minimap<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>minimap-color-highlight<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>minimap-find-and-replace<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>minimap-git-diff<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>minimap-highlight-selected<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>minimap-selection<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>live-archive<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>styleguide<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>autocomplete<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>language-diff<span class="pl-pds">"</span></span> ], <span class="pl-ent">"themes"</span>: [ <span class="pl-s"><span class="pl-pds">"</span>one-light-ui<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>monokai-light<span class="pl-pds">"</span></span> ], <span class="pl-ent">"projectHome"</span>: <span class="pl-s"><span class="pl-pds">"</span>/Users/daniel/dev/ds<span class="pl-pds">"</span></span> }, <span class="pl-ent">"editor"</span>: { <span class="pl-ent">"fontFamily"</span>: <span class="pl-s"><span class="pl-pds">"</span>Source Code Pro for Powerline<span class="pl-pds">"</span></span>, <span class="pl-ent">"showIndentGuide"</span>: <span class="pl-c1">true</span>, <span class="pl-ent">"scrollPastEnd"</span>: <span class="pl-c1">true</span>, <span class="pl-ent">"invisibles"</span>: {}, <span class="pl-ent">"fontSize"</span>: <span class="pl-c1">15</span> } }</pre></div> <h3 dir="auto">Installed Packages</h3> <div class="highlight highlight-source-coffee notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="# User atom-alignment, v0.11.0 atom-beautify, v0.21.3 atom-color-highlight, v3.0.8 autocomplete-paths, v1.0.2 autocomplete-plus, v2.2.0 change-case, v0.5.1 coffee-compile, v0.10.0 color-picker, v1.4.4 file-icons, v1.4.11 filesize, v0.1.1 git-tab-status, v1.5.3 highlight-selected, v0.9.0 language-batch, v0.3.2 language-csharp, v0.5.0 language-fsharp, v0.8.4 last-cursor-position, v0.7.0 linter-less, v0.3.1 monokai-light, v0.3.6 script-runner, v1.7.0 set-syntax, v0.2.1 trailing-spaces, v0.2.4 # Dev No dev packages"><pre class="notranslate"><span class="pl-c"><span class="pl-c">#</span> User</span> atom<span class="pl-k">-</span>alignment, v0.<span class="pl-ii">11</span>.<span class="pl-ii">0</span> atom<span class="pl-k">-</span>beautify, v0.<span class="pl-ii">21</span>.<span class="pl-ii">3</span> atom<span class="pl-k">-</span>color<span class="pl-k">-</span>highlight, v3.<span class="pl-ii">0</span>.<span class="pl-ii">8</span> autocomplete<span class="pl-k">-</span>paths, v1.<span class="pl-ii">0</span>.<span class="pl-ii">2</span> autocomplete<span class="pl-k">-</span>plus, v2.<span class="pl-ii">2</span>.<span class="pl-ii">0</span> change<span class="pl-k">-</span><span class="pl-k">case</span>, v0.<span class="pl-ii">5</span>.<span class="pl-ii">1</span> coffee<span class="pl-k">-</span>compile, v0.<span class="pl-ii">10</span>.<span class="pl-ii">0</span> color<span class="pl-k">-</span>picker, v1.<span class="pl-ii">4</span>.<span class="pl-ii">4</span> file<span class="pl-k">-</span>icons, v1.<span class="pl-ii">4</span>.<span class="pl-ii">11</span> filesize, v0.<span class="pl-ii">1</span>.<span class="pl-ii">1</span> git<span class="pl-k">-</span>tab<span class="pl-k">-</span>status, v1.<span class="pl-ii">5</span>.<span class="pl-ii">3</span> highlight<span class="pl-k">-</span>selected, v0.<span class="pl-ii">9</span>.<span class="pl-ii">0</span> language<span class="pl-k">-</span>batch, v0.<span class="pl-ii">3</span>.<span class="pl-ii">2</span> language<span class="pl-k">-</span>csharp, v0.<span class="pl-ii">5</span>.<span class="pl-ii">0</span> language<span class="pl-k">-</span>fsharp, v0.<span class="pl-ii">8</span>.<span class="pl-ii">4</span> last<span class="pl-k">-</span>cursor<span class="pl-k">-</span>position, v0.<span class="pl-ii">7</span>.<span class="pl-ii">0</span> linter<span class="pl-k">-</span>less, v0.<span class="pl-ii">3</span>.<span class="pl-ii">1</span> monokai<span class="pl-k">-</span>light, v0.<span class="pl-ii">3</span>.<span class="pl-ii">6</span> script<span class="pl-k">-</span>runner, v1.<span class="pl-ii">7</span>.<span class="pl-ii">0</span> set<span class="pl-k">-</span>syntax, v0.<span class="pl-ii">2</span>.<span class="pl-ii">1</span> trailing<span class="pl-k">-</span>spaces, v0.<span class="pl-ii">2</span>.<span class="pl-ii">4</span> <span class="pl-c"><span class="pl-c">#</span> Dev</span> <span class="pl-en">No</span> <span class="pl-en">dev</span> packages</pre></div>
<p dir="auto">[Enter steps to reproduce below:]</p> <ol dir="auto"> <li>...</li> <li>...</li> </ol> <p dir="auto"><strong>Atom Version</strong>: 0.183.0<br> <strong>System</strong>: Mac OS X 10.10.2<br> <strong>Thrown From</strong>: Atom Core</p> <h3 dir="auto">Stack Trace</h3> <p dir="auto">Uncaught InvalidCharacterError: Failed to execute 'add' on 'DOMTokenList': The token provided ('highlight-selected background') contains HTML space characters, which are not valid in tokens.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="At /Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:63 Error: Failed to execute 'add' on 'DOMTokenList': The token provided ('highlight-selected background') contains HTML space characters, which are not valid in tokens. at Error (native) at HighlightsComponent.module.exports.HighlightsComponent.updateHighlightNode (/Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:63:33) at HighlightsComponent.module.exports.HighlightsComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:47:28) at LinesComponent.module.exports.LinesComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/lines-component.js:118:32) at TextEditorComponent.module.exports.TextEditorComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:213:27) at /Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:283:28 at ViewRegistry.module.exports.ViewRegistry.performDocumentUpdate (/Applications/Atom.app/Contents/Resources/app/src/view-registry.js:159:9) at /Applications/Atom.app/Contents/Resources/app/src/view-registry.js:3:61 "><pre class="notranslate"><code class="notranslate">At /Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:63 Error: Failed to execute 'add' on 'DOMTokenList': The token provided ('highlight-selected background') contains HTML space characters, which are not valid in tokens. at Error (native) at HighlightsComponent.module.exports.HighlightsComponent.updateHighlightNode (/Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:63:33) at HighlightsComponent.module.exports.HighlightsComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/highlights-component.js:47:28) at LinesComponent.module.exports.LinesComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/lines-component.js:118:32) at TextEditorComponent.module.exports.TextEditorComponent.updateSync (/Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:213:27) at /Applications/Atom.app/Contents/Resources/app/src/text-editor-component.js:283:28 at ViewRegistry.module.exports.ViewRegistry.performDocumentUpdate (/Applications/Atom.app/Contents/Resources/app/src/view-registry.js:159:9) at /Applications/Atom.app/Contents/Resources/app/src/view-registry.js:3:61 </code></pre></div> <h3 dir="auto">Commands</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" -3:03.6 pane:show-previous-item (atom-text-editor.editor.is-focused) -3:03.0 pane:show-next-item (atom-text-editor.editor) -3:01.9 pane:show-previous-item (atom-text-editor.editor.is-focused) 3x -3:01.3 pane:show-next-item (atom-text-editor.editor) -2:59.1 pane:show-previous-item (atom-text-editor.editor)"><pre class="notranslate"><code class="notranslate"> -3:03.6 pane:show-previous-item (atom-text-editor.editor.is-focused) -3:03.0 pane:show-next-item (atom-text-editor.editor) -3:01.9 pane:show-previous-item (atom-text-editor.editor.is-focused) 3x -3:01.3 pane:show-next-item (atom-text-editor.editor) -2:59.1 pane:show-previous-item (atom-text-editor.editor) </code></pre></div> <h3 dir="auto">Config</h3> <div class="highlight highlight-source-json notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="{ &quot;core&quot;: { &quot;ignoredNames&quot;: [ &quot;tags&quot; ], &quot;disabledPackages&quot;: [ &quot;rails-transporter&quot;, &quot;term2&quot;, &quot;term2&quot;, &quot;term2&quot;, &quot;vim-mode&quot;, &quot;atom-ctags&quot; ], &quot;themes&quot;: [ &quot;atom-dark-ui&quot;, &quot;monokai&quot; ] }, &quot;editor&quot;: { &quot;fontSize&quot;: 13, &quot;showIndentGuide&quot;: true, &quot;autoIndent&quot;: false, &quot;preferredLineLength&quot;: 120, &quot;invisibles&quot;: {}, &quot;softWrap&quot;: true } }"><pre class="notranslate">{ <span class="pl-ent">"core"</span>: { <span class="pl-ent">"ignoredNames"</span>: [ <span class="pl-s"><span class="pl-pds">"</span>tags<span class="pl-pds">"</span></span> ], <span class="pl-ent">"disabledPackages"</span>: [ <span class="pl-s"><span class="pl-pds">"</span>rails-transporter<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>term2<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>term2<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>term2<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>vim-mode<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>atom-ctags<span class="pl-pds">"</span></span> ], <span class="pl-ent">"themes"</span>: [ <span class="pl-s"><span class="pl-pds">"</span>atom-dark-ui<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>monokai<span class="pl-pds">"</span></span> ] }, <span class="pl-ent">"editor"</span>: { <span class="pl-ent">"fontSize"</span>: <span class="pl-c1">13</span>, <span class="pl-ent">"showIndentGuide"</span>: <span class="pl-c1">true</span>, <span class="pl-ent">"autoIndent"</span>: <span class="pl-c1">false</span>, <span class="pl-ent">"preferredLineLength"</span>: <span class="pl-c1">120</span>, <span class="pl-ent">"invisibles"</span>: {}, <span class="pl-ent">"softWrap"</span>: <span class="pl-c1">true</span> } }</pre></div> <h3 dir="auto">Installed Packages</h3> <div class="highlight highlight-source-coffee notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="# User atom-color-highlight, v3.0.8 autocomplete-paths, v1.0.2 autocomplete-plus, v2.2.0 color-picker, v1.4.4 command-logger, v0.22.0 file-icons, v1.4.11 git-tab-status, v1.5.3 highlight-selected, v0.9.0 language-emblem, v0.1.0 language-haml, v0.15.0 linter, v0.11.1 linter-clang, v2.25.1 linter-coffeelint, v0.1.7 linter-csslint, v0.0.11 linter-erb, v0.1.0 linter-javac, v0.1.3 linter-jshint, v0.1.0 linter-ruby, v0.1.4 linter-scss-lint, v0.0.14 monokai, v0.12.0 # Dev No dev packages"><pre class="notranslate"><span class="pl-c"><span class="pl-c">#</span> User</span> atom<span class="pl-k">-</span>color<span class="pl-k">-</span>highlight, v3.<span class="pl-ii">0</span>.<span class="pl-ii">8</span> autocomplete<span class="pl-k">-</span>paths, v1.<span class="pl-ii">0</span>.<span class="pl-ii">2</span> autocomplete<span class="pl-k">-</span>plus, v2.<span class="pl-ii">2</span>.<span class="pl-ii">0</span> color<span class="pl-k">-</span>picker, v1.<span class="pl-ii">4</span>.<span class="pl-ii">4</span> command<span class="pl-k">-</span>logger, v0.<span class="pl-ii">22</span>.<span class="pl-ii">0</span> file<span class="pl-k">-</span>icons, v1.<span class="pl-ii">4</span>.<span class="pl-ii">11</span> git<span class="pl-k">-</span>tab<span class="pl-k">-</span>status, v1.<span class="pl-ii">5</span>.<span class="pl-ii">3</span> highlight<span class="pl-k">-</span>selected, v0.<span class="pl-ii">9</span>.<span class="pl-ii">0</span> language<span class="pl-k">-</span>emblem, v0.<span class="pl-ii">1</span>.<span class="pl-ii">0</span> language<span class="pl-k">-</span>haml, v0.<span class="pl-ii">15</span>.<span class="pl-ii">0</span> linter, v0.<span class="pl-ii">11</span>.<span class="pl-ii">1</span> linter<span class="pl-k">-</span>clang, v2.<span class="pl-ii">25</span>.<span class="pl-ii">1</span> linter<span class="pl-k">-</span>coffeelint, v0.<span class="pl-ii">1</span>.<span class="pl-ii">7</span> linter<span class="pl-k">-</span>csslint, v0.<span class="pl-ii">0</span>.<span class="pl-ii">11</span> linter<span class="pl-k">-</span>erb, v0.<span class="pl-ii">1</span>.<span class="pl-ii">0</span> linter<span class="pl-k">-</span>javac, v0.<span class="pl-ii">1</span>.<span class="pl-ii">3</span> linter<span class="pl-k">-</span>jshint, v0.<span class="pl-ii">1</span>.<span class="pl-ii">0</span> linter<span class="pl-k">-</span>ruby, v0.<span class="pl-ii">1</span>.<span class="pl-ii">4</span> linter<span class="pl-k">-</span>scss<span class="pl-k">-</span>lint, v0.<span class="pl-ii">0</span>.<span class="pl-ii">14</span> monokai, v0.<span class="pl-ii">12</span>.<span class="pl-ii">0</span> <span class="pl-c"><span class="pl-c">#</span> Dev</span> <span class="pl-en">No</span> <span class="pl-en">dev</span> packages</pre></div>
1
<p dir="auto">Sorry, it was glitch on my side after ObjLoader update. After my code fixing everything works fine.<br> ...</p> <h5 dir="auto">Three.js version</h5> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Dev</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> r74</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> r75</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> ...</li> </ul> <h5 dir="auto">Browser</h5> <ul class="contains-task-list"> <li>[] All of them</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> Chrome</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Firefox</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Internet Explorer</li> </ul> <h5 dir="auto">OS</h5> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> All of them</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Windows</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> Linux</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Android</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> IOS</li> </ul>
<p dir="auto">I was wondering if the extrude part of <a href="https://github.com/mrdoob/three.js/blob/master/src/extras/geometries/TextGeometry.js">TextGeometry</a> could be somehow separated into it's on <code class="notranslate">ExtrudeGeometry</code> class.</p> <p dir="auto">Right now we have have <a href="https://github.com/mrdoob/three.js/blob/master/src/extras/geometries/LatheGeometry.js">LatheGeometry</a> which gets a set of points and creates a revoluted mesh with it, and would be great to have something like that for extrusions.</p> <p dir="auto"><a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/zz85/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/zz85">@zz85</a>, <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/alteredq/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/alteredq">@alteredq</a>, thoughts?</p>
0