text1
stringlengths
0
536k
text2
stringlengths
0
536k
label
int64
0
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">Environment</h3> <ul dir="auto"> <li>Dubbo version: 2.7.1</li> <li>Operating System version: mac sierra 10.12</li> <li>Java version: 1.8</li> </ul> <h3 dir="auto">Steps to reproduce this issue</h3> <p dir="auto">For PR: <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="444367090" data-permission-text="Title is private" data-url="https://github.com/apache/dubbo/issues/4067" data-hovercard-type="pull_request" data-hovercard-url="/apache/dubbo/pull/4067/hovercard" href="https://github.com/apache/dubbo/pull/4067">#4067</a></p> <ol dir="auto"> <li>Run consumer without provider as below, it throws No provider exception.</li> </ol> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ReferenceConfigCache cache = ReferenceConfigCache.getCache(); DemoService demoService = (DemoService) cache.get(reference); demoService.sayHello(&quot;hi&quot;);"><pre class="notranslate"><code class="notranslate">ReferenceConfigCache cache = ReferenceConfigCache.getCache(); DemoService demoService = (DemoService) cache.get(reference); demoService.sayHello("hi"); </code></pre></div> <ol start="2" dir="auto"> <li>Start provider and then run consumer again, get null from the demoService.</li> </ol> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ReferenceConfigCache cache = ReferenceConfigCache.getCache(); DemoService demoService = (DemoService) cache.get(reference);"><pre class="notranslate"><code class="notranslate">ReferenceConfigCache cache = ReferenceConfigCache.getCache(); DemoService demoService = (DemoService) cache.get(reference); </code></pre></div> <p dir="auto">Pls. provide [GitHub address] to reproduce this issue.</p> <h3 dir="auto">Expected Result</h3> <p dir="auto">DemoService should be initialized.</p> <h3 dir="auto">Actual Result</h3> <p dir="auto">DemoService returns null even with provider started.</p> <p dir="auto">For the first time, the ReferenceConfig init throws exception from refprotocol.refer(interfaceClass, urls.get(0)), have not changed the initialized to false. For the second time, the ReferenceConfig cannot init it again as initialized is true.</p> <p dir="auto">We should set initialized after init finished.</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/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/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: mac</li> <li>Java version: jdk 8</li> </ul> <h3 dir="auto">Steps to reproduce this issue</h3> <p dir="auto">注册了两个配置中心,一个用的是dubbo默认配置</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="dubbo.registry.address=zookeeper://127.0.0.1:2181"><pre class="notranslate"><code class="notranslate">dubbo.registry.address=zookeeper://127.0.0.1:2181 </code></pre></div> <p dir="auto">然后自定一个注册中心:</p> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" @Bean public RegistryConfig ecareConsumerConfig() { RegistryConfig registryConfig = new RegistryConfig(); registryConfig.setAddress(&quot;zookeeper://127.0.0.1:2182&quot;); registryConfig.setGroup(&quot;dubbo&quot;); return registryConfig; }"><pre class="notranslate"> <span class="pl-c1">@</span><span class="pl-c1">Bean</span> <span class="pl-k">public</span> <span class="pl-smi">RegistryConfig</span> <span class="pl-s1">ecareConsumerConfig</span>() { <span class="pl-smi">RegistryConfig</span> <span class="pl-s1">registryConfig</span> = <span class="pl-k">new</span> <span class="pl-smi">RegistryConfig</span>(); <span class="pl-s1">registryConfig</span>.<span class="pl-en">setAddress</span>(<span class="pl-s">"zookeeper://127.0.0.1:2182"</span>); <span class="pl-s1">registryConfig</span>.<span class="pl-en">setGroup</span>(<span class="pl-s">"dubbo"</span>); <span class="pl-k">return</span> <span class="pl-s1">registryConfig</span>; }</pre></div> <p dir="auto">引用时,指定了注册中心<code class="notranslate">ecareConsumerConfig</code></p> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" @Reference(registry = &quot;ecareConsumerConfig&quot;) private UserInfoApiService userInfoApiService;"><pre class="notranslate"> <span class="pl-c1">@</span><span class="pl-c1">Reference</span>(<span class="pl-s1">registry</span> = <span class="pl-s">"ecareConsumerConfig"</span>) <span class="pl-k">private</span> <span class="pl-smi">UserInfoApiService</span> <span class="pl-s1">userInfoApiService</span>;</pre></div> <p dir="auto">然后程序启动解析时,源码走到<code class="notranslate">org.apache.dubbo.config.ReferenceConfig.init()</code>里面注册信息都是<code class="notranslate">127.0.0.1:2182</code>,继续走,当走到<code class="notranslate">startConfigCenter</code>里面调用了<code class="notranslate">ConfigManager.getInstance().refreshAll();</code>里面的<code class="notranslate">AbstractConfig.refresh()</code>不管你是否拥有值,都将里面的值覆盖掉,变成<code class="notranslate">zookeeper://127.0.0.1:2181</code>。导致注册中心找错</p> <p dir="auto">Pls. provide [GitHub address] to reproduce this issue.</p> <h3 dir="auto">Expected Result</h3> <p dir="auto">What do you expected from the above steps?</p> <h3 dir="auto">Actual Result</h3> <p dir="auto">What actually happens?</p> <p dir="auto">If there is an exception, please attach the exception trace:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Just put your stack trace here!"><pre class="notranslate"><code class="notranslate">Just put your stack trace here! </code></pre></div>
0
<p dir="auto">Open attached file and zoom in a lot<br> Might be reproducible only on Windows</p> <p dir="auto">Input from <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/alexandrudima/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/alexandrudima">@alexandrudima</a> :</p> <ul dir="auto"> <li>check why are you getting a new gpu layer</li> <li>we already had this issue in other trees and Joao discovered it was happening due to scroll bars</li> <li>another reason for this might be the positioning (non integer coordinates) of the repl or the background. Though this one is unlikely</li> </ul> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/1926584/11272842/1cddf344-8ed0-11e5-9d52-e3ac90d25c2a.png"><img src="https://cloud.githubusercontent.com/assets/1926584/11272842/1cddf344-8ed0-11e5-9d52-e3ac90d25c2a.png" alt="image" style="max-width: 100%;"></a></p>
<p dir="auto"><em>From UX Meeting: <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="158969676" data-permission-text="Title is private" data-url="https://github.com/microsoft/vscode/issues/7338" data-hovercard-type="issue" data-hovercard-url="/microsoft/vscode/issues/7338/hovercard" href="https://github.com/microsoft/vscode/issues/7338">#7338</a>, topic "Update on separating editor and group actions"</em></p> <h2 dir="auto">No Tabs: Group Level Commands</h2> <p dir="auto">As a part of the work to support tabs, we made some assumptions about the need for managing stacks of editors when tabs are <strong>not</strong> enabled. We believed that users would want the following:</p> <ul dir="auto"> <li>A group level affordance that indicates when there are multiple editors open in a group (when clicked it shows these open editors).</li> <li>A group level overflow button with the following items: <ul dir="auto"> <li>“Close All” open editors in a group at once, thus closing the group when empty editors are not enabled.</li> <li>“Move Left” / “Move Right” the group (same result as dragging a group).</li> </ul> </li> </ul> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/1487073/15947974/2eef5dca-2e53-11e6-819a-de3fb1b57d28.png"><img src="https://cloud.githubusercontent.com/assets/1487073/15947974/2eef5dca-2e53-11e6-819a-de3fb1b57d28.png" alt="image" style="max-width: 100%;"></a></p> <p dir="auto">After dogfooding with the <a href="https://code.visualstudio.com/insiders" rel="nofollow">Insiders Release</a> we think it’s possible these UI elements are actually not needed:</p> <ul dir="auto"> <li>The Open Editors area in the explorer already indicates when multiple editors are open in a group and what they are.</li> <li>Closing all editors is possible from Open Editors</li> <li>Moving groups left and right is already possible through dragging the editor or in Open Editors, although this needs to be accessible</li> </ul> <p dir="auto">Furthermore, it is visually "noisy" to have these group-level commands when tabs are not enabled. The extra buttons increase the complexity, and the lighter gray background that separates the group-level commands from the editor commands is heavy and attention-grabbing.</p> <p dir="auto">Finally, corner cases exist where you could have two overflow menus, one for local commands and one for group-level commands. This is confusing and undesirable.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/1487073/15948080/b0eda91c-2e53-11e6-84d6-4f174b80a86f.jpeg"><img src="https://cloud.githubusercontent.com/assets/1487073/15948080/b0eda91c-2e53-11e6-84d6-4f174b80a86f.jpeg" alt="doubleoverflow" style="max-width: 100%;"></a></p> <h3 dir="auto">Conclusion</h3> <p dir="auto">We decided that it would be best to revert these changes and remove the group-level commands to eliminate duplicate functionality and keep the current ("no tabs") model intact for the "tabs disabled" scenario.</p>
0
<p dir="auto"><strong>Apache Airflow version</strong>: 1.10.11</p> <p dir="auto"><strong>Kubernetes version (if you are using kubernetes)</strong> (use <code class="notranslate">kubectl version</code>):</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):</li> <li><strong>Kernel</strong> (e.g. <code class="notranslate">uname -a</code>):</li> <li><strong>Install tools</strong>:</li> <li><strong>Others</strong>:</li> </ul> <p dir="auto"><strong>What happened</strong>:</p> <p dir="auto"><strong>What you expected to happen</strong>:</p> <p dir="auto"><strong>How to reproduce it</strong>:</p> <p dir="auto">Set MSSQL as the sql connection backend and examine the airflow scheduler logs</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[2020-07-22 08:27:16,334] {settings.py:306} DEBUG - Disposing DB connection pool (PID 7714) Process DagFileProcessor1036-Process: Traceback (most recent call last): File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py&quot;, line 1278, in _execute_context cursor, statement, parameters, context File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/default.py&quot;, line 593, in do_execute cursor.execute(statement, parameters) pyodbc.ProgrammingError: ('42000', &quot;[42000] [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]Incorrect syntax near '1'. (102) (SQLExecDirectW)&quot;) The above exception was the direct cause of the following exception: Traceback (most recent call last): File &quot;/usr/local/lib/python3.7/multiprocessing/process.py&quot;, line 297, in _bootstrap self.run() File &quot;/usr/local/lib/python3.7/multiprocessing/process.py&quot;, line 99, in run self._target(*self._args, **self._kwargs) File &quot;/home/airflow/.local/lib/python3.7/site-packages/airflow/jobs/scheduler_job.py&quot;, line 159, in _run_file_processor pickle_dags) File &quot;/home/airflow/.local/lib/python3.7/site-packages/airflow/utils/db.py&quot;, line 74, in wrapper return func(*args, **kwargs) File &quot;/home/airflow/.local/lib/python3.7/site-packages/airflow/jobs/scheduler_job.py&quot;, line 1593, in process_file paused_dag_ids = models.DagModel.get_paused_dag_ids(dag_ids=dagbag.dag_ids) File &quot;/home/airflow/.local/lib/python3.7/site-packages/airflow/utils/db.py&quot;, line 74, in wrapper return func(*args, **kwargs) File &quot;/home/airflow/.local/lib/python3.7/site-packages/airflow/models/dag.py&quot;, line 1808, in get_paused_dag_ids .filter(DagModel.dag_id.in_(dag_ids)) File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/orm/query.py&quot;, line 3341, in all return list(self) File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/orm/query.py&quot;, line 3503, in __iter__ return self._execute_and_instances(context) File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/orm/query.py&quot;, line 3528, in _execute_and_instances result = conn.execute(querycontext.statement, self._params) File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py&quot;, line 1014, in execute return meth(self, multiparams, params) File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/sql/elements.py&quot;, line 298, in _execute_on_connection return connection._execute_clauseelement(self, multiparams, params) File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py&quot;, line 1133, in _execute_clauseelement distilled_params, File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py&quot;, line 1318, in _execute_context e, statement, parameters, cursor, context File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py&quot;, line 1512, in _handle_dbapi_exception sqlalchemy_exception, with_traceback=exc_info[2], from_=e File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/util/compat.py&quot;, line 178, in raise_ raise exception File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py&quot;, line 1278, in _execute_context cursor, statement, parameters, context File &quot;/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/default.py&quot;, line 593, in do_execute cursor.execute(statement, parameters) sqlalchemy.exc.ProgrammingError: (pyodbc.ProgrammingError) ('42000', &quot;[42000] [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]Incorrect syntax near '1'. (102) (SQLExecDirectW)&quot;) [SQL: SELECT dag.dag_id AS dag_dag_id FROM dag WHERE dag.is_paused IS 1 AND dag.dag_id IN (?)] [parameters: ('test-dag',)] (Background on this error at: http://sqlalche.me/e/13/f405) "><pre class="notranslate"><code class="notranslate">[2020-07-22 08:27:16,334] {settings.py:306} DEBUG - Disposing DB connection pool (PID 7714) Process DagFileProcessor1036-Process: Traceback (most recent call last): File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1278, in _execute_context cursor, statement, parameters, context File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/default.py", line 593, in do_execute cursor.execute(statement, parameters) pyodbc.ProgrammingError: ('42000', "[42000] [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]Incorrect syntax near '1'. (102) (SQLExecDirectW)") The above exception was the direct cause of the following exception: Traceback (most recent call last): File "/usr/local/lib/python3.7/multiprocessing/process.py", line 297, in _bootstrap self.run() File "/usr/local/lib/python3.7/multiprocessing/process.py", line 99, in run self._target(*self._args, **self._kwargs) File "/home/airflow/.local/lib/python3.7/site-packages/airflow/jobs/scheduler_job.py", line 159, in _run_file_processor pickle_dags) File "/home/airflow/.local/lib/python3.7/site-packages/airflow/utils/db.py", line 74, in wrapper return func(*args, **kwargs) File "/home/airflow/.local/lib/python3.7/site-packages/airflow/jobs/scheduler_job.py", line 1593, in process_file paused_dag_ids = models.DagModel.get_paused_dag_ids(dag_ids=dagbag.dag_ids) File "/home/airflow/.local/lib/python3.7/site-packages/airflow/utils/db.py", line 74, in wrapper return func(*args, **kwargs) File "/home/airflow/.local/lib/python3.7/site-packages/airflow/models/dag.py", line 1808, in get_paused_dag_ids .filter(DagModel.dag_id.in_(dag_ids)) File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/orm/query.py", line 3341, in all return list(self) File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/orm/query.py", line 3503, in __iter__ return self._execute_and_instances(context) File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/orm/query.py", line 3528, in _execute_and_instances result = conn.execute(querycontext.statement, self._params) File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1014, in execute return meth(self, multiparams, params) File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/sql/elements.py", line 298, in _execute_on_connection return connection._execute_clauseelement(self, multiparams, params) File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1133, in _execute_clauseelement distilled_params, File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1318, in _execute_context e, statement, parameters, cursor, context File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1512, in _handle_dbapi_exception sqlalchemy_exception, with_traceback=exc_info[2], from_=e File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/util/compat.py", line 178, in raise_ raise exception File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/base.py", line 1278, in _execute_context cursor, statement, parameters, context File "/home/airflow/.local/lib/python3.7/site-packages/sqlalchemy/engine/default.py", line 593, in do_execute cursor.execute(statement, parameters) sqlalchemy.exc.ProgrammingError: (pyodbc.ProgrammingError) ('42000', "[42000] [Microsoft][ODBC Driver 17 for SQL Server][SQL Server]Incorrect syntax near '1'. (102) (SQLExecDirectW)") [SQL: SELECT dag.dag_id AS dag_dag_id FROM dag WHERE dag.is_paused IS 1 AND dag.dag_id IN (?)] [parameters: ('test-dag',)] (Background on this error at: http://sqlalche.me/e/13/f405) </code></pre></div> <p dir="auto"><strong>Anything else we need to know</strong>:</p>
<h3 dir="auto">Apache Airflow version</h3> <p dir="auto">2.5.2</p> <h3 dir="auto">What happened</h3> <p dir="auto">When using dynamic task groups mapping I cannot access logs of the mapped task instances</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/31843161/231144317-5d29e07d-9e50-4540-b482-d080e80793f2.png"><img src="https://user-images.githubusercontent.com/31843161/231144317-5d29e07d-9e50-4540-b482-d080e80793f2.png" alt="obrazek" style="max-width: 100%;"></a></p> <h3 dir="auto">What you think should happen instead</h3> <p dir="auto">I want to be able to click through logs of mapped task instances in the Grid View in Airflow UI</p> <h3 dir="auto">How to reproduce</h3> <p dir="auto">Follow tutorial <a href="https://docs.astronomer.io/learn/dynamic-tasks#mapping-over-task-groups" rel="nofollow">https://docs.astronomer.io/learn/dynamic-tasks#mapping-over-task-groups</a></p> <h3 dir="auto">Operating System</h3> <p dir="auto">debian</p> <h3 dir="auto">Versions of Apache Airflow Providers</h3> <p dir="auto"><em>No response</em></p> <h3 dir="auto">Deployment</h3> <p dir="auto">Other Docker-based deployment</p> <h3 dir="auto">Deployment details</h3> <p dir="auto"><em>No response</em></p> <h3 dir="auto">Anything else</h3> <p dir="auto"><em>No response</em></p> <h3 dir="auto">Are you willing to submit PR?</h3> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Yes I am willing to submit a PR!</li> </ul> <h3 dir="auto">Code of Conduct</h3> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I agree to follow this project's <a href="https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md">Code of Conduct</a></li> </ul>
0
<p dir="auto">I am trying to do a barplot where the positive values are a certain color and the negative values are another color. I have scripts that I've used in previous versions where this was working but the current version isn't working. I am basing it off of a code snippet from: <a href="https://stackoverflow.com/questions/22311139/matplotlib-bar-chart-choose-color-if-value-is-positive-vs-value-is-negative" rel="nofollow">https://stackoverflow.com/questions/22311139/matplotlib-bar-chart-choose-color-if-value-is-positive-vs-value-is-negative</a></p> <p dir="auto"><strong>Is there something in the backend of the plotting wrapper that is stoping multiple color values from working?</strong></p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="# Versions print(&quot;Python Version:&quot;, sys.version) print() print(&quot;Pandas Version:&quot;, pd.__version__) # Input Data data = {'M00001': 0.099999999999999978, 'M00003': 0.125, 'M00004': -0.14200000000000007, 'M00005': -1.0, 'M00007': -0.25, 'M00017': 0.14300000000000002, 'M00021': -1.0, 'M00023': -0.25, 'M00034': 0.097000000000000003, 'M00035': -0.25, 'M00048': -0.122, 'M00050': -0.25, 'M00053': -0.125, 'M00060': 0.11099999999999999, 'M00063': -0.25, 'M00115': 0.59999999999999998, 'M00116': -0.11099999999999999, 'M00126': -0.14300000000000002, 'M00127': -0.39999999999999997, 'M00144': -0.15400000000000003, 'M00149': 0.25, 'M00157': -0.125, 'M00173': -0.090000000000000024, 'M00178': -0.17300000000000004, 'M00179': -0.10399999999999998, 'M00188': 0.33300000000000002, 'M00240': -0.33299999999999996, 'M00242': -0.33299999999999996, 'M00256': 0.5, 'M00335': -0.125, 'M00359': -0.050000000000000044, 'M00360': -0.05600000000000005, 'M00377': 0.14299999999999996, 'M00459': 0.5, 'M00481': 0.5, 'M00504': 0.5, 'M00527': 0.1429999999999999, 'M00530': -0.5, 'M00532': 0.10000000000000001, 'M00549': 0.66700000000000004, 'M00609': 0.16699999999999998, 'M00614': -0.083000000000000018, 'M00618': 0.11200000000000004, 'M00628': -0.25, 'M00695': -0.33300000000000002, 'M00723': -0.25, 'M00728': 0.33300000000000002, 'M00754': 0.33300000000000002, 'M00793': -0.25, 'M90000': -0.11400000000000005, 'M91000': -0.070000000000000007} Se_data = pd.Series(data) # Pandas Plotting with plt.style.context(&quot;seaborn-white&quot;): fig, ax = plt.subplots(figsize=(5,10)) Se_data.plot(kind=&quot;barh&quot;, ax=ax, color=Se_data.map(lambda x: {True:&quot;blue&quot;, False:&quot;red&quot;}[x &gt; 0]))"><pre class="notranslate"><span class="pl-c"># Versions</span> <span class="pl-en">print</span>(<span class="pl-s">"Python Version:"</span>, <span class="pl-s1">sys</span>.<span class="pl-s1">version</span>) <span class="pl-en">print</span>() <span class="pl-en">print</span>(<span class="pl-s">"Pandas Version:"</span>, <span class="pl-s1">pd</span>.<span class="pl-s1">__version__</span>) <span class="pl-c"># Input Data</span> <span class="pl-s1">data</span> <span class="pl-c1">=</span> {<span class="pl-s">'M00001'</span>: <span class="pl-c1">0.099999999999999978</span>, <span class="pl-s">'M00003'</span>: <span class="pl-c1">0.125</span>, <span class="pl-s">'M00004'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.14200000000000007</span>, <span class="pl-s">'M00005'</span>: <span class="pl-c1">-</span><span class="pl-c1">1.0</span>, <span class="pl-s">'M00007'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.25</span>, <span class="pl-s">'M00017'</span>: <span class="pl-c1">0.14300000000000002</span>, <span class="pl-s">'M00021'</span>: <span class="pl-c1">-</span><span class="pl-c1">1.0</span>, <span class="pl-s">'M00023'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.25</span>, <span class="pl-s">'M00034'</span>: <span class="pl-c1">0.097000000000000003</span>, <span class="pl-s">'M00035'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.25</span>, <span class="pl-s">'M00048'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.122</span>, <span class="pl-s">'M00050'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.25</span>, <span class="pl-s">'M00053'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.125</span>, <span class="pl-s">'M00060'</span>: <span class="pl-c1">0.11099999999999999</span>, <span class="pl-s">'M00063'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.25</span>, <span class="pl-s">'M00115'</span>: <span class="pl-c1">0.59999999999999998</span>, <span class="pl-s">'M00116'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.11099999999999999</span>, <span class="pl-s">'M00126'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.14300000000000002</span>, <span class="pl-s">'M00127'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.39999999999999997</span>, <span class="pl-s">'M00144'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.15400000000000003</span>, <span class="pl-s">'M00149'</span>: <span class="pl-c1">0.25</span>, <span class="pl-s">'M00157'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.125</span>, <span class="pl-s">'M00173'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.090000000000000024</span>, <span class="pl-s">'M00178'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.17300000000000004</span>, <span class="pl-s">'M00179'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.10399999999999998</span>, <span class="pl-s">'M00188'</span>: <span class="pl-c1">0.33300000000000002</span>, <span class="pl-s">'M00240'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.33299999999999996</span>, <span class="pl-s">'M00242'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.33299999999999996</span>, <span class="pl-s">'M00256'</span>: <span class="pl-c1">0.5</span>, <span class="pl-s">'M00335'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.125</span>, <span class="pl-s">'M00359'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.050000000000000044</span>, <span class="pl-s">'M00360'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.05600000000000005</span>, <span class="pl-s">'M00377'</span>: <span class="pl-c1">0.14299999999999996</span>, <span class="pl-s">'M00459'</span>: <span class="pl-c1">0.5</span>, <span class="pl-s">'M00481'</span>: <span class="pl-c1">0.5</span>, <span class="pl-s">'M00504'</span>: <span class="pl-c1">0.5</span>, <span class="pl-s">'M00527'</span>: <span class="pl-c1">0.1429999999999999</span>, <span class="pl-s">'M00530'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.5</span>, <span class="pl-s">'M00532'</span>: <span class="pl-c1">0.10000000000000001</span>, <span class="pl-s">'M00549'</span>: <span class="pl-c1">0.66700000000000004</span>, <span class="pl-s">'M00609'</span>: <span class="pl-c1">0.16699999999999998</span>, <span class="pl-s">'M00614'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.083000000000000018</span>, <span class="pl-s">'M00618'</span>: <span class="pl-c1">0.11200000000000004</span>, <span class="pl-s">'M00628'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.25</span>, <span class="pl-s">'M00695'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.33300000000000002</span>, <span class="pl-s">'M00723'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.25</span>, <span class="pl-s">'M00728'</span>: <span class="pl-c1">0.33300000000000002</span>, <span class="pl-s">'M00754'</span>: <span class="pl-c1">0.33300000000000002</span>, <span class="pl-s">'M00793'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.25</span>, <span class="pl-s">'M90000'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.11400000000000005</span>, <span class="pl-s">'M91000'</span>: <span class="pl-c1">-</span><span class="pl-c1">0.070000000000000007</span>} <span class="pl-v">Se_data</span> <span class="pl-c1">=</span> <span class="pl-s1">pd</span>.<span class="pl-v">Series</span>(<span class="pl-s1">data</span>) <span class="pl-c"># Pandas Plotting</span> <span class="pl-k">with</span> <span class="pl-s1">plt</span>.<span class="pl-s1">style</span>.<span class="pl-en">context</span>(<span class="pl-s">"seaborn-white"</span>): <span class="pl-s1">fig</span>, <span class="pl-s1">ax</span> <span class="pl-c1">=</span> <span class="pl-s1">plt</span>.<span class="pl-en">subplots</span>(<span class="pl-s1">figsize</span><span class="pl-c1">=</span>(<span class="pl-c1">5</span>,<span class="pl-c1">10</span>)) <span class="pl-v">Se_data</span>.<span class="pl-en">plot</span>(<span class="pl-s1">kind</span><span class="pl-c1">=</span><span class="pl-s">"barh"</span>, <span class="pl-s1">ax</span><span class="pl-c1">=</span><span class="pl-s1">ax</span>, <span class="pl-s1">color</span><span class="pl-c1">=</span><span class="pl-v">Se_data</span>.<span class="pl-en">map</span>(<span class="pl-k">lambda</span> <span class="pl-s1">x</span>: {<span class="pl-c1">True</span>:<span class="pl-s">"blue"</span>, <span class="pl-c1">False</span>:<span class="pl-s">"red"</span>}[<span class="pl-s1">x</span> <span class="pl-c1">&gt;</span> <span class="pl-c1">0</span>]))</pre></div> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/9061708/30394716-c3c381d4-9878-11e7-829a-be3b8c2fea06.png"><img src="https://user-images.githubusercontent.com/9061708/30394716-c3c381d4-9878-11e7-829a-be3b8c2fea06.png" alt="image" style="max-width: 100%;"></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="&gt;&gt;&gt; df = pd.DataFrame({&quot;A&quot;: range(4), &quot;color&quot;: ['red', 'blue', 'blue', 'red']}) &gt;&gt;&gt; ax = df.plot.bar(y='A', color=df['color']) &gt;&gt;&gt; [p.get_facecolor() for p in ax.patches] [(1.0, 0.0, 0.0, 1.0), (1.0, 0.0, 0.0, 1.0), (1.0, 0.0, 0.0, 1.0), (1.0, 0.0, 0.0, 1.0)]"><pre class="notranslate"><span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-s1">df</span> <span class="pl-c1">=</span> <span class="pl-s1">pd</span>.<span class="pl-v">DataFrame</span>({<span class="pl-s">"A"</span>: <span class="pl-en">range</span>(<span class="pl-c1">4</span>), <span class="pl-s">"color"</span>: [<span class="pl-s">'red'</span>, <span class="pl-s">'blue'</span>, <span class="pl-s">'blue'</span>, <span class="pl-s">'red'</span>]}) <span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-s1">ax</span> <span class="pl-c1">=</span> <span class="pl-s1">df</span>.<span class="pl-s1">plot</span>.<span class="pl-en">bar</span>(<span class="pl-s1">y</span><span class="pl-c1">=</span><span class="pl-s">'A'</span>, <span class="pl-s1">color</span><span class="pl-c1">=</span><span class="pl-s1">df</span>[<span class="pl-s">'color'</span>]) <span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> [<span class="pl-s1">p</span>.<span class="pl-en">get_facecolor</span>() <span class="pl-k">for</span> <span class="pl-s1">p</span> <span class="pl-c1">in</span> <span class="pl-s1">ax</span>.<span class="pl-s1">patches</span>] [(<span class="pl-c1">1.0</span>, <span class="pl-c1">0.0</span>, <span class="pl-c1">0.0</span>, <span class="pl-c1">1.0</span>), (<span class="pl-c1">1.0</span>, <span class="pl-c1">0.0</span>, <span class="pl-c1">0.0</span>, <span class="pl-c1">1.0</span>), (<span class="pl-c1">1.0</span>, <span class="pl-c1">0.0</span>, <span class="pl-c1">0.0</span>, <span class="pl-c1">1.0</span>), (<span class="pl-c1">1.0</span>, <span class="pl-c1">0.0</span>, <span class="pl-c1">0.0</span>, <span class="pl-c1">1.0</span>)]</pre></div> <h4 dir="auto">Problem description</h4> <p dir="auto">It plots correctly but it does not pick the right color per bar. it only pick the color of the first value in the list.<br> it was working perfectly in pandas 0.19.2</p> <h4 dir="auto">Expected Output</h4> <p dir="auto">the plot should contain a different color as the list is being passed. Similar to matplotlib behavior and the old pandas version</p> <h4 dir="auto">Output of <code class="notranslate">pd.show_versions()</code></h4> <details> <p dir="auto">pandas: 0.20.2<br> pytest: None<br> pip: 9.0.1<br> setuptools: 36.0.1<br> Cython: None<br> numpy: 1.12.1<br> scipy: 0.19.1<br> xarray: None<br> IPython: 5.4.1<br> sphinx: None<br> patsy: None<br> dateutil: 2.6.0<br> pytz: 2017.2<br> blosc: None<br> bottleneck: None<br> tables: None<br> numexpr: None<br> feather: None<br> matplotlib: 2.0.2<br> openpyxl: None<br> xlrd: 1.0.0<br> xlwt: None<br> xlsxwriter: None<br> lxml: None<br> bs4: None<br> html5lib: 0.9999999<br> sqlalchemy: None<br> pymysql: None<br> psycopg2: 2.7.1 (dt dec pq3 ext lo64)<br> jinja2: 2.9.6<br> s3fs: None<br> pandas_gbq: None<br> pandas_datareader: None</p> </details>
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/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">Caret should position on active input field.</p> <h2 dir="auto">Current Behavior</h2> <p dir="auto">Caret is often appearing as if input is on the next input<br> Tested on actual mobile device and recorded video using simulator on iOS</p> <p dir="auto">SEE VIDEO HERE:<br> <a href="https://drive.google.com/file/d/1TfyzHa8TZDiiDMN04_O68MTNVAgAZSbv/view?usp=sharing" rel="nofollow">https://drive.google.com/file/d/1TfyzHa8TZDiiDMN04_O68MTNVAgAZSbv/view?usp=sharing</a></p> <h2 dir="auto">Steps to Reproduce (for bugs)</h2> <ol dir="auto"> <li></li> <li></li> <li></li> <li></li> </ol> <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>Material-UI</td> <td>beta32</td> </tr> <tr> <td>React</td> <td>16.2.0</td> </tr> <tr> <td>browser</td> <td>iOS Safari</td> </tr> <tr> <td>etc</td> <td></td> </tr> </tbody> </table>
<p dir="auto">I let a fullscreen dialog appear in my web application and have a TextField being automatically focused. The field is kind of focused, but the blinking | is not displayed.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/8998518/32510535-3b190b7a-c3f1-11e7-84f3-4f9d3821f721.jpg"><img src="https://user-images.githubusercontent.com/8998518/32510535-3b190b7a-c3f1-11e7-84f3-4f9d3821f721.jpg" alt="img_1229" style="max-width: 100%;"></a></p> <p dir="auto">If you tab on the <strong>same</strong> TextField again, it'll blink one line under the text field.<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/8998518/32510556-4f07944e-c3f1-11e7-8943-662426d4f2a8.jpg"><img src="https://user-images.githubusercontent.com/8998518/32510556-4f07944e-c3f1-11e7-8943-662426d4f2a8.jpg" alt="img_1230" style="max-width: 100%;"></a></p> <p dir="auto">Again on the same: TextField is unfocused.<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/8998518/32510565-52d1d4cc-c3f1-11e7-99bc-94d2b1aaad38.jpg"><img src="https://user-images.githubusercontent.com/8998518/32510565-52d1d4cc-c3f1-11e7-99bc-94d2b1aaad38.jpg" alt="img_1231" style="max-width: 100%;"></a></p> <p dir="auto">Again on the same, the correct TextField is finally focused with |.<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/8998518/32510575-56be533a-c3f1-11e7-8cf8-b8558fd630ab.jpg"><img src="https://user-images.githubusercontent.com/8998518/32510575-56be533a-c3f1-11e7-8cf8-b8558fd630ab.jpg" alt="img_1233" style="max-width: 100%;"></a></p> <ul dir="auto"> <li>[ x] 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> <p dir="auto">This is my dialog content:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&lt;DialogContent style={{ textAlign: 'center' }}&gt; &lt;DialogTitle&gt; Enter your lorem link &lt;/DialogTitle&gt; &lt;DialogContentText&gt; Lorem ipsum. &lt;/DialogContentText&gt; &lt;TextField required autoFocus inputRef={el =&gt; this.TitleInput = el} margin=&quot;normal&quot; label=&quot;Enter your course title&quot; type=&quot;text&quot; style={{ width: '60%', minWidth: '250px' }} inputProps={{ maxLength: 10 }} /&gt; &lt;TextField required inputRef={el =&gt; this.LinkInput = el} margin=&quot;normal&quot; label=&quot;Enter your link&quot; type=&quot;text&quot; style={{ width: '60%', minWidth: '250px' }} /&gt; &lt;/DialogContent&gt;"><pre class="notranslate"><code class="notranslate">&lt;DialogContent style={{ textAlign: 'center' }}&gt; &lt;DialogTitle&gt; Enter your lorem link &lt;/DialogTitle&gt; &lt;DialogContentText&gt; Lorem ipsum. &lt;/DialogContentText&gt; &lt;TextField required autoFocus inputRef={el =&gt; this.TitleInput = el} margin="normal" label="Enter your course title" type="text" style={{ width: '60%', minWidth: '250px' }} inputProps={{ maxLength: 10 }} /&gt; &lt;TextField required inputRef={el =&gt; this.LinkInput = el} margin="normal" label="Enter your link" type="text" style={{ width: '60%', minWidth: '250px' }} /&gt; &lt;/DialogContent&gt; </code></pre></div> <h2 dir="auto">Environment</h2> <p dir="auto">This bug only happens on iOS devices.</p> <table role="table"> <thead> <tr> <th>Tech</th> <th>Version</th> </tr> </thead> <tbody> <tr> <td>Material-UI</td> <td>1.0.0-beta.19</td> </tr> <tr> <td>React</td> <td>16.0.0</td> </tr> <tr> <td>browser</td> <td>iOS Safari</td> </tr> <tr> <td>etc</td> <td>iPhone 7, iPad Pro 9"</td> </tr> </tbody> </table>
1
<p dir="auto">Hi, I recently upgraded to <code class="notranslate">atom-0.184.0</code> and the required <code class="notranslate">atom-shell-0.22.3</code>. All works remarkably well, considering how severe the one thing that does <em>not</em> is:</p> <p dir="auto">Almost always (though strangely enough not really always) atom crashes whenever I try to copy something into its window. Not only that, but even if I have saved a file in a ~5s time window before the crash, it will undo whatever save that was :-/ This is not as far as I can tell contingent on what it is that I copy or where it is copied from.</p> <p dir="auto">This is seriously annoying! And sadly I can't seem to debug it , atom automatically detaches itself from the terminal so that I do not see any output...</p>
<p dir="auto">I'm using Atom ver. 0.189.0 on Ubuntu 14.04.2 LTS. When I copy a piece of text in atom and I try to paste it the right-click menu either won't show up or will show up without giving me option to paste. The paste shortcut doesn't work either and it creates issues even if I try to copy and paste text from other programs (after I have coping something from atom). I have disable all the extra plugins, so it isn't a plugin issue. I didn't had this issue with the previous version (I am using webupd8 ppa). If I do a right click on a place where there isn't a text entry (meaning a place where it doesn't support paste anyway) the right click menu appears fine.</p>
1
<p dir="auto">E. g. remove ColumnSelectorFactory.makeFloat/Double/Long/ObjectColumnSelector, and leave only one method "makeColumnValueSelector". Users which need different specializations could call corresponding methods on <code class="notranslate">ColumnValueSelector</code> itself: getFloat()/getDouble/getLong().</p> <p dir="auto">This change will allow to reduce code duplication in <code class="notranslate">IndexedDoubles</code>, <code class="notranslate">IndexedLongs</code> and <code class="notranslate">IndexedFloats</code>.</p>
<h3 dir="auto">Affected Version</h3> <p dir="auto">Current master</p> <h3 dir="auto">Description</h3> <p dir="auto">Here is the error.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="2019-12-09T15:38:33,215 ERROR [task-runner-0-priority-0] org.apache.druid.indexing.common.task.HadoopIndexTask - Got invocation target exception in run(), cause: java.lang.ExceptionInInitializerError: null at org.apache.druid.indexing.common.task.HadoopIndexTask$HadoopDetermineConfigInnerProcessingRunner.runTask(HadoopIndexTask.java:639) ~[druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_181] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_181] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_181] at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_181] at org.apache.druid.indexing.common.task.HadoopIndexTask.runInternal(HadoopIndexTask.java:347) ~[druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at org.apache.druid.indexing.common.task.HadoopIndexTask.runTask(HadoopIndexTask.java:281) [druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at org.apache.druid.indexing.common.task.AbstractBatchIndexTask.run(AbstractBatchIndexTask.java:138) [druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at org.apache.druid.indexing.overlord.SingleTaskBackgroundRunner$SingleTaskBackgroundRunnerCallable.call(SingleTaskBackgroundRunner.java:419) [druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at org.apache.druid.indexing.overlord.SingleTaskBackgroundRunner$SingleTaskBackgroundRunnerCallable.call(SingleTaskBackgroundRunner.java:391) [druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_181] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_181] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_181] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_181] Caused by: com.google.inject.CreationException: Unable to create injector, see the following errors: 1) A binding to org.apache.hadoop.conf.Configuration was already configured at org.apache.druid.storage.hdfs.HdfsStorageDruidModule.configure(HdfsStorageDruidModule.java:111) (via modules: com.google.inject.util.Modules$OverrideModule -&gt; org.apache.druid.storage.hdfs.HdfsStorageDruidModule). at org.apache.druid.data.input.parquet.ParquetExtensionsModule.configure(ParquetExtensionsModule.java:101) (via modules: com.google.inject.util.Modules$OverrideModule -&gt; org.apache.druid.data.input.parquet.ParquetExtensionsModule) 1 error at com.google.inject.internal.Errors.throwCreationExceptionIfErrorsExist(Errors.java:470) ~[guice-4.1.0.jar:?] at com.google.inject.internal.InternalInjectorCreator.initializeStatically(InternalInjectorCreator.java:155) ~[guice-4.1.0.jar:?] at com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:107) ~[guice-4.1.0.jar:?] at com.google.inject.Guice.createInjector(Guice.java:99) ~[guice-4.1.0.jar:?] at com.google.inject.Guice.createInjector(Guice.java:73) ~[guice-4.1.0.jar:?] at com.google.inject.Guice.createInjector(Guice.java:62) ~[guice-4.1.0.jar:?] at org.apache.druid.initialization.Initialization.makeInjectorWithModules(Initialization.java:431) ~[druid-server-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at org.apache.druid.indexer.HadoopDruidIndexerConfig.&lt;clinit&gt;(HadoopDruidIndexerConfig.java:101) ~[druid-indexing-hadoop-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] ... 14 more"><pre class="notranslate"><code class="notranslate">2019-12-09T15:38:33,215 ERROR [task-runner-0-priority-0] org.apache.druid.indexing.common.task.HadoopIndexTask - Got invocation target exception in run(), cause: java.lang.ExceptionInInitializerError: null at org.apache.druid.indexing.common.task.HadoopIndexTask$HadoopDetermineConfigInnerProcessingRunner.runTask(HadoopIndexTask.java:639) ~[druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[?:1.8.0_181] at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) ~[?:1.8.0_181] at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[?:1.8.0_181] at java.lang.reflect.Method.invoke(Method.java:498) ~[?:1.8.0_181] at org.apache.druid.indexing.common.task.HadoopIndexTask.runInternal(HadoopIndexTask.java:347) ~[druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at org.apache.druid.indexing.common.task.HadoopIndexTask.runTask(HadoopIndexTask.java:281) [druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at org.apache.druid.indexing.common.task.AbstractBatchIndexTask.run(AbstractBatchIndexTask.java:138) [druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at org.apache.druid.indexing.overlord.SingleTaskBackgroundRunner$SingleTaskBackgroundRunnerCallable.call(SingleTaskBackgroundRunner.java:419) [druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at org.apache.druid.indexing.overlord.SingleTaskBackgroundRunner$SingleTaskBackgroundRunnerCallable.call(SingleTaskBackgroundRunner.java:391) [druid-indexing-service-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_181] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_181] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_181] at java.lang.Thread.run(Thread.java:748) [?:1.8.0_181] Caused by: com.google.inject.CreationException: Unable to create injector, see the following errors: 1) A binding to org.apache.hadoop.conf.Configuration was already configured at org.apache.druid.storage.hdfs.HdfsStorageDruidModule.configure(HdfsStorageDruidModule.java:111) (via modules: com.google.inject.util.Modules$OverrideModule -&gt; org.apache.druid.storage.hdfs.HdfsStorageDruidModule). at org.apache.druid.data.input.parquet.ParquetExtensionsModule.configure(ParquetExtensionsModule.java:101) (via modules: com.google.inject.util.Modules$OverrideModule -&gt; org.apache.druid.data.input.parquet.ParquetExtensionsModule) 1 error at com.google.inject.internal.Errors.throwCreationExceptionIfErrorsExist(Errors.java:470) ~[guice-4.1.0.jar:?] at com.google.inject.internal.InternalInjectorCreator.initializeStatically(InternalInjectorCreator.java:155) ~[guice-4.1.0.jar:?] at com.google.inject.internal.InternalInjectorCreator.build(InternalInjectorCreator.java:107) ~[guice-4.1.0.jar:?] at com.google.inject.Guice.createInjector(Guice.java:99) ~[guice-4.1.0.jar:?] at com.google.inject.Guice.createInjector(Guice.java:73) ~[guice-4.1.0.jar:?] at com.google.inject.Guice.createInjector(Guice.java:62) ~[guice-4.1.0.jar:?] at org.apache.druid.initialization.Initialization.makeInjectorWithModules(Initialization.java:431) ~[druid-server-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] at org.apache.druid.indexer.HadoopDruidIndexerConfig.&lt;clinit&gt;(HadoopDruidIndexerConfig.java:101) ~[druid-indexing-hadoop-0.17.0-incubating-iap-preview1.jar:0.17.0-incubating-iap-preview1] ... 14 more </code></pre></div>
0
<p dir="auto">Occurs in Fiber with multiple instances of the React package (which can't share current owner).</p>
<p dir="auto">So I'm loading a precompiled react file into my server.js and using that to rendertostring.<br> (there is a very good reason why I'm doing it like this, don't ask about it, that's no part of the issue here)</p> <p dir="auto">This actually works but the moment you introduce hooks... it all goes to hell. I've tried setting react/react-dom as externals and such. Nothing works. It keeps throwing the same issue.</p> <ol dir="auto"> <li>There are no mismatching versions</li> <li>There are no duplicate react versions I can see</li> <li>The rules of hooks are not broken as far as I know.</li> </ol> <p dir="auto">React version: 16.12.0</p> <h2 dir="auto">Steps To Reproduce</h2> <ol dir="auto"> <li><a href="https://github.com/Pixelatex/hooks-ssr-issue">https://github.com/Pixelatex/hooks-ssr-issue</a></li> <li>Yarn build</li> <li>Yarn serve</li> <li>Go to localhost:3000 and see it crash, removing the hooks from app.js shows it working.</li> </ol> <p dir="auto">Link to code example:</p> <p dir="auto"><a href="https://github.com/Pixelatex/hooks-ssr-issue">https://github.com/Pixelatex/hooks-ssr-issue</a></p> <h2 dir="auto">The current behavior</h2> <p dir="auto">It should render a string with the resulting html.</p> <h2 dir="auto">The expected behavior</h2> <p dir="auto">Hooks should just work.</p>
0
<p dir="auto">These can be seen by inspecting the <code class="notranslate">__call__</code> attribute, but they are referenced from the particular plotting methods, but not easily learned about in IPython/Jupyter.</p> <p dir="auto"><a href="https://github.com/pandas-dev/pandas/blob/master/pandas/tools/plotting.py#L3781">https://github.com/pandas-dev/pandas/blob/master/pandas/tools/plotting.py#L3781</a></p>
<p dir="auto">I'm running into a problem with using <code class="notranslate">dropna</code> with a list of columns specified by <code class="notranslate">subset</code>. I wish to remove rows with missing values:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/a2925527d468f0050b1cb35e254876beef367322970b06ece2aa2a00aa94da0c/687474703a2f2f642e70722f692f357767522b"><img src="https://camo.githubusercontent.com/a2925527d468f0050b1cb35e254876beef367322970b06ece2aa2a00aa94da0c/687474703a2f2f642e70722f692f357767522b" alt="missing" data-canonical-src="http://d.pr/i/5wgR+" style="max-width: 100%;"></a></p> <p dir="auto">The dataset looks like this:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://camo.githubusercontent.com/b97fbb7c01e51f97f5e0d38ecc218bd879d79066969def568bbe086ae08cc966/687474703a2f2f642e70722f692f775259452b"><img src="https://camo.githubusercontent.com/b97fbb7c01e51f97f5e0d38ecc218bd879d79066969def568bbe086ae08cc966/687474703a2f2f642e70722f692f775259452b" alt="dataset" data-canonical-src="http://d.pr/i/wRYE+" style="max-width: 100%;"></a></p> <p dir="auto">However, when I try to call <code class="notranslate">dropna</code> using these columns, it complains about a duplicate axis:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="variables.dropna(subset=['cigarette_smokers', 'birth_wt_child', 'oxygen', 'length_of_stay', 'hospitalized_vitamin_d', 'breastfed']) --------------------------------------------------------------------------- ValueError Traceback (most recent call last) &lt;ipython-input-168-96be0b0b00e8&gt; in &lt;module&gt;() 1 variables.dropna(subset=['cigarette_smokers', 'birth_wt_child', ----&gt; 2 'oxygen', 'length_of_stay', 'hospitalized_vitamin_d', 'breastfed']) /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/frame.pyc in dropna(self, axis, how, thresh, subset, inplace) 2407 if subset is not None: 2408 agg_axis_name = self._get_axis_name(agg_axis) -&gt; 2409 agg_obj = self.reindex(**{agg_axis_name: subset}) 2410 2411 count = agg_obj.count(axis=agg_axis) /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/frame.pyc in reindex(self, index, columns, **kwargs) 2160 def reindex(self, index=None, columns=None, **kwargs): 2161 return super(DataFrame, self).reindex(index=index, columns=columns, -&gt; 2162 **kwargs) 2163 2164 @Appender(_shared_docs['reindex_axis'] % _shared_doc_kwargs) /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/generic.pyc in reindex(self, *args, **kwargs) 1561 return self._reindex_axes(axes, level, limit, 1562 method, fill_value, copy, -&gt; 1563 takeable=takeable).__finalize__(self) 1564 1565 def _reindex_axes(self, axes, level, limit, method, fill_value, copy, /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/frame.pyc in _reindex_axes(self, axes, level, limit, method, fill_value, copy, takeable) 2110 if columns is not None: 2111 frame = frame._reindex_columns(columns, copy, level, fill_value, -&gt; 2112 limit, takeable=takeable) 2113 2114 index = axes['index'] /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/frame.pyc in _reindex_columns(self, new_columns, copy, level, fill_value, limit, takeable) 2137 return self._reindex_with_indexers({1: [new_columns, indexer]}, 2138 copy=copy, fill_value=fill_value, -&gt; 2139 allow_dups=takeable) 2140 2141 def _reindex_multi(self, axes, copy, fill_value): /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/generic.pyc in _reindex_with_indexers(self, reindexers, method, fill_value, limit, copy, allow_dups) 1687 new_data = new_data.reindex_indexer(index, indexer, axis=baxis, 1688 fill_value=fill_value, -&gt; 1689 allow_dups=allow_dups) 1690 1691 elif (baxis == 0 and index is not None and /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/internals.pyc in reindex_indexer(self, new_axis, indexer, axis, fill_value, allow_dups) 3227 # trying to reindex on an axis with duplicates 3228 if not allow_dups and not self.axes[axis].is_unique: -&gt; 3229 raise ValueError(&quot;cannot reindex from a duplicate axis&quot;) 3230 3231 if not self.is_consolidated(): ValueError: cannot reindex from a duplicate axis"><pre class="notranslate"><code class="notranslate">variables.dropna(subset=['cigarette_smokers', 'birth_wt_child', 'oxygen', 'length_of_stay', 'hospitalized_vitamin_d', 'breastfed']) --------------------------------------------------------------------------- ValueError Traceback (most recent call last) &lt;ipython-input-168-96be0b0b00e8&gt; in &lt;module&gt;() 1 variables.dropna(subset=['cigarette_smokers', 'birth_wt_child', ----&gt; 2 'oxygen', 'length_of_stay', 'hospitalized_vitamin_d', 'breastfed']) /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/frame.pyc in dropna(self, axis, how, thresh, subset, inplace) 2407 if subset is not None: 2408 agg_axis_name = self._get_axis_name(agg_axis) -&gt; 2409 agg_obj = self.reindex(**{agg_axis_name: subset}) 2410 2411 count = agg_obj.count(axis=agg_axis) /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/frame.pyc in reindex(self, index, columns, **kwargs) 2160 def reindex(self, index=None, columns=None, **kwargs): 2161 return super(DataFrame, self).reindex(index=index, columns=columns, -&gt; 2162 **kwargs) 2163 2164 @Appender(_shared_docs['reindex_axis'] % _shared_doc_kwargs) /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/generic.pyc in reindex(self, *args, **kwargs) 1561 return self._reindex_axes(axes, level, limit, 1562 method, fill_value, copy, -&gt; 1563 takeable=takeable).__finalize__(self) 1564 1565 def _reindex_axes(self, axes, level, limit, method, fill_value, copy, /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/frame.pyc in _reindex_axes(self, axes, level, limit, method, fill_value, copy, takeable) 2110 if columns is not None: 2111 frame = frame._reindex_columns(columns, copy, level, fill_value, -&gt; 2112 limit, takeable=takeable) 2113 2114 index = axes['index'] /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/frame.pyc in _reindex_columns(self, new_columns, copy, level, fill_value, limit, takeable) 2137 return self._reindex_with_indexers({1: [new_columns, indexer]}, 2138 copy=copy, fill_value=fill_value, -&gt; 2139 allow_dups=takeable) 2140 2141 def _reindex_multi(self, axes, copy, fill_value): /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/generic.pyc in _reindex_with_indexers(self, reindexers, method, fill_value, limit, copy, allow_dups) 1687 new_data = new_data.reindex_indexer(index, indexer, axis=baxis, 1688 fill_value=fill_value, -&gt; 1689 allow_dups=allow_dups) 1690 1691 elif (baxis == 0 and index is not None and /Library/Python/2.7/site-packages/pandas-0.13.0_395_gef55e60-py2.7-macosx-10.9-intel.egg/pandas/core/internals.pyc in reindex_indexer(self, new_axis, indexer, axis, fill_value, allow_dups) 3227 # trying to reindex on an axis with duplicates 3228 if not allow_dups and not self.axes[axis].is_unique: -&gt; 3229 raise ValueError("cannot reindex from a duplicate axis") 3230 3231 if not self.is_consolidated(): ValueError: cannot reindex from a duplicate axis </code></pre></div> <p dir="auto">Running a current build from master in Python 2.7.5 on OS X 10.9.1.</p>
0
<p dir="auto"><strong>Steps to reproduce:</strong> Run the following code</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import numpy as np n = 25 tmp1 = np.identity(n) tmp2 = np.linalg.inv(tmp1) print(&quot;Done&quot;)"><pre class="notranslate"><code class="notranslate">import numpy as np n = 25 tmp1 = np.identity(n) tmp2 = np.linalg.inv(tmp1) print("Done") </code></pre></div> <p dir="auto"><strong>Expected behaviour:</strong> Should finish running and print "Done"<br> <strong>Observed behaviour:</strong> About 8 times out of 10 the above code will hang on the <code class="notranslate">np.linalg.inv</code> line and python starts consuming ~100% CPU on one core. Python doesn't respond to Ctrl+C, and I have to kill the process through the task manager. If I change <code class="notranslate">n &lt;= 24</code>, the code runs fine every time.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/967771/39592452-67d10bac-4ecc-11e8-8166-1b5fae4a0bde.png"><img src="https://user-images.githubusercontent.com/967771/39592452-67d10bac-4ecc-11e8-8166-1b5fae4a0bde.png" alt="Deadlock screenshot" style="max-width: 100%;"></a></p> <p dir="auto">I've managed to reproduce this on Python 3.6.1 and 3.5.5 (see the below conda environment listings). In my Python 2.7 environment, I can't reproduce it.</p> <p dir="auto">Python 3.6 environment:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="E:\Development&gt;python Python 3.6.1 |Continuum Analytics, Inc.| (default, May 11 2017, 13:25:24) [MSC v.1900 64 bit (AMD64)] on win32 Type &quot;help&quot;, &quot;copyright&quot;, &quot;credits&quot; or &quot;license&quot; for more information. &gt;&gt;&gt; exit() E:\Development&gt;conda list # packages in environment at C:\Users\uqasnosw\AppData\Local\Continuum\Miniconda3: # # Name Version Build Channel alabaster 0.7.10 py36_0 asn1crypto 0.22.0 py36_0 babel 2.4.0 py36_0 blas 1.1 openblas conda-forge bzip2 1.0.6 vc14_1 [vc14] conda-forge ca-certificates 2017.11.5 0 conda-forge cffi 1.10.0 py36_0 clangdev 5.0.0 flang_3 [vc14 flang] conda-forge colorama 0.3.9 py36_0 conda 4.5.2 py36_0 conda-forge conda-env 2.6.0 0 conda-forge console_shortcut 0.1.1 py36_1 cryptography 1.8.1 py36_0 cvxopt 1.2.0 py36_blas_openblas_200 [blas_openblas] conda-forge cvxopt 1.1.9 &lt;pip&gt; cycler 0.10.0 py36_0 dask-core 0.16.1 py_0 conda-forge decorator 4.0.11 py36_0 decorator 4.2.1 &lt;pip&gt; docutils 0.13.1 py36_0 freetype 2.8.1 vc14_0 [vc14] conda-forge future 0.16.0 &lt;pip&gt; glpk 4.65 vc14_0 [vc14] conda-forge graphviz 2.38.0 4 gym 0.9.6 &lt;pip&gt; icc_rt 2017.0.4 h97af966_0 icu 58.2 vc14_0 [vc14] conda-forge idna 2.5 py36_0 imageio 2.2.0 py36_0 conda-forge imagesize 0.7.1 py36_0 intel-openmp 2018.0.0 8 ipython 6.1.0 py36_0 ipython_genutils 0.2.0 py36_0 isort 4.2.15 &lt;pip&gt; jedi 0.10.2 py36_2 jinja2 2.9.6 py36_0 jpeg 9b vc14_2 [vc14] conda-forge kiwisolver 1.0.1 py36_1 conda-forge lazy-object-proxy 1.3.1 &lt;pip&gt; libflang 5.0.0 vc14_20180208 [vc14] conda-forge libgpuarray 0.7.5 vc14_0 [vc14] conda-forge libiconv 1.14 vc14_4 [vc14] conda-forge libpng 1.6.34 vc14_0 [vc14] conda-forge libpython 2.0 py36_0 libtiff 4.0.9 vc14_0 [vc14] conda-forge libxml2 2.9.5 vc14_1 [vc14] conda-forge llvm-meta 5.0.0 0 conda-forge llvmdev 5.0.0 default_1 [vc14] conda-forge m2w64-binutils 2.25.1 5 m2w64-bzip2 1.0.6 6 m2w64-crt-git 5.0.0.4636.2595836 2 m2w64-gcc 5.3.0 6 m2w64-gcc-ada 5.3.0 6 m2w64-gcc-fortran 5.3.0 6 m2w64-gcc-libgfortran 5.3.0 6 m2w64-gcc-libs 5.3.0 7 m2w64-gcc-libs-core 5.3.0 7 m2w64-gcc-objc 5.3.0 6 m2w64-gmp 6.1.0 2 m2w64-headers-git 5.0.0.4636.c0ad18a 2 m2w64-isl 0.16.1 2 m2w64-libiconv 1.14 6 m2w64-libmangle-git 5.0.0.4509.2e5a9a2 2 m2w64-libwinpthread-git 5.0.0.4634.697f757 2 m2w64-make 4.1.2351.a80a8b8 2 m2w64-mpc 1.0.3 3 m2w64-mpfr 3.1.4 4 m2w64-pkg-config 0.29.1 2 m2w64-toolchain 5.3.0 7 m2w64-tools-git 5.0.0.4592.90b8472 2 m2w64-windows-default-manifest 6.4 3 m2w64-winpthreads-git 5.0.0.4634.697f757 2 m2w64-zlib 1.2.8 10 mako 1.0.6 py36_0 markupsafe 0.23 py36_2 matplotlib 2.2.2 py36_1 conda-forge matplotlib 2.1.2 &lt;pip&gt; mccabe 0.6.1 &lt;pip&gt; menuinst 1.4.7 py36_0 metis 5.1.0 vc14_3 [vc14] conda-forge mingw 4.7 1 mkl 2018.0.2 1 mkl-service 1.1.2 py36_3 mkl_fft 1.0.1 py36_1 conda-forge mkl_random 1.0.1 py36_0 conda-forge msys2-conda-epoch 20160418 1 networkx 2.1 &lt;pip&gt; networkx 2.0 py36_1 conda-forge nose 1.3.7 py36_1 nose-parameterized 0.5.0 py36_0 numpy 1.14.0 &lt;pip&gt; numpy 1.14.3 py36_blas_openblas_200 [blas_openblas] conda-forge olefile 0.44 py36_0 conda-forge openblas 0.2.20 vc14_7 [vc14] conda-forge opencv-python 3.4.0 &lt;pip&gt; openmp 5.0.0 vc14_1 [vc14] conda-forge openssl 1.0.2n vc14_0 [vc14] conda-forge packaging 16.8 py36_0 pandas 0.22.0 py36_1 conda-forge path.py 10.3.1 py36_0 pickleshare 0.7.4 py36_0 Pillow 5.0.0 &lt;pip&gt; pillow 5.0.0 py36_0 conda-forge pip 9.0.3 py36_0 conda-forge prompt_toolkit 1.0.14 py36_0 pyasn1 0.2.3 py36_0 pycosat 0.6.2 py36_0 pycparser 2.17 py36_0 pydot 1.0.29 &lt;pip&gt; pyglet 1.3.1 &lt;pip&gt; pygments 2.2.0 py36_0 pygpu 0.7.5 py36_0 conda-forge pyopenssl 17.0.0 py36_0 pyparsing 2.2.0 &lt;pip&gt; pyparsing 2.1.4 py36_0 pyqt 5.6.0 py36_2 python 3.6.1 2 python-dateutil 2.6.0 py36_0 python-dateutil 2.6.1 &lt;pip&gt; pytz 2018.3 &lt;pip&gt; pytz 2017.2 py36_0 PyWavelets 0.5.2 &lt;pip&gt; pywavelets 0.5.2 py36_1 conda-forge pywin32 220 py36_2 qt 5.6.2 vc14_1 [vc14] conda-forge requests 2.14.2 py36_0 ruamel_yaml 0.11.14 py36_1 scikit-image 0.13.1 py36_0 conda-forge scikit-learn 0.19.1 &lt;pip&gt; scipy 1.0.0 py36h1260518_0 setuptools 27.2.0 py36_1 simplegeneric 0.8.1 py36_1 sip 4.18 py36_0 six 1.10.0 py36_0 six 1.11.0 &lt;pip&gt; sklearn 0.0 &lt;pip&gt; snowballstemmer 1.2.1 py36_0 sphinx 1.6.2 py36_0 sphinxcontrib 1.0 py36_0 sphinxcontrib-websupport 1.0.1 py36_0 sqlite 3.22.0 vc14_0 [vc14] conda-forge suitesparse 5.1.2 blas_openblas_vc14_202 [blas_openblas vc14] conda-forge tbb 2018_20171205 vc14_0 [vc14] conda-forge theano 0.9.0 py36_0 tk 8.5.19 vc14_1 [vc14] conda-forge toolz 0.8.2 py_2 conda-forge tornado 5.0.2 py36_0 conda-forge traitlets 4.3.2 py36_0 vc 14 0 conda-forge vs2015_runtime 14.0.25123 0 wcwidth 0.1.7 py36_0 wheel 0.29.0 py36_0 XlsxWriter 1.0.2 &lt;pip&gt; yaml 0.1.7 vc14_0 [vc14] conda-forge zlib 1.2.11 vc14_0 [vc14] conda-forge"><pre class="notranslate"><code class="notranslate">E:\Development&gt;python Python 3.6.1 |Continuum Analytics, Inc.| (default, May 11 2017, 13:25:24) [MSC v.1900 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license" for more information. &gt;&gt;&gt; exit() E:\Development&gt;conda list # packages in environment at C:\Users\uqasnosw\AppData\Local\Continuum\Miniconda3: # # Name Version Build Channel alabaster 0.7.10 py36_0 asn1crypto 0.22.0 py36_0 babel 2.4.0 py36_0 blas 1.1 openblas conda-forge bzip2 1.0.6 vc14_1 [vc14] conda-forge ca-certificates 2017.11.5 0 conda-forge cffi 1.10.0 py36_0 clangdev 5.0.0 flang_3 [vc14 flang] conda-forge colorama 0.3.9 py36_0 conda 4.5.2 py36_0 conda-forge conda-env 2.6.0 0 conda-forge console_shortcut 0.1.1 py36_1 cryptography 1.8.1 py36_0 cvxopt 1.2.0 py36_blas_openblas_200 [blas_openblas] conda-forge cvxopt 1.1.9 &lt;pip&gt; cycler 0.10.0 py36_0 dask-core 0.16.1 py_0 conda-forge decorator 4.0.11 py36_0 decorator 4.2.1 &lt;pip&gt; docutils 0.13.1 py36_0 freetype 2.8.1 vc14_0 [vc14] conda-forge future 0.16.0 &lt;pip&gt; glpk 4.65 vc14_0 [vc14] conda-forge graphviz 2.38.0 4 gym 0.9.6 &lt;pip&gt; icc_rt 2017.0.4 h97af966_0 icu 58.2 vc14_0 [vc14] conda-forge idna 2.5 py36_0 imageio 2.2.0 py36_0 conda-forge imagesize 0.7.1 py36_0 intel-openmp 2018.0.0 8 ipython 6.1.0 py36_0 ipython_genutils 0.2.0 py36_0 isort 4.2.15 &lt;pip&gt; jedi 0.10.2 py36_2 jinja2 2.9.6 py36_0 jpeg 9b vc14_2 [vc14] conda-forge kiwisolver 1.0.1 py36_1 conda-forge lazy-object-proxy 1.3.1 &lt;pip&gt; libflang 5.0.0 vc14_20180208 [vc14] conda-forge libgpuarray 0.7.5 vc14_0 [vc14] conda-forge libiconv 1.14 vc14_4 [vc14] conda-forge libpng 1.6.34 vc14_0 [vc14] conda-forge libpython 2.0 py36_0 libtiff 4.0.9 vc14_0 [vc14] conda-forge libxml2 2.9.5 vc14_1 [vc14] conda-forge llvm-meta 5.0.0 0 conda-forge llvmdev 5.0.0 default_1 [vc14] conda-forge m2w64-binutils 2.25.1 5 m2w64-bzip2 1.0.6 6 m2w64-crt-git 5.0.0.4636.2595836 2 m2w64-gcc 5.3.0 6 m2w64-gcc-ada 5.3.0 6 m2w64-gcc-fortran 5.3.0 6 m2w64-gcc-libgfortran 5.3.0 6 m2w64-gcc-libs 5.3.0 7 m2w64-gcc-libs-core 5.3.0 7 m2w64-gcc-objc 5.3.0 6 m2w64-gmp 6.1.0 2 m2w64-headers-git 5.0.0.4636.c0ad18a 2 m2w64-isl 0.16.1 2 m2w64-libiconv 1.14 6 m2w64-libmangle-git 5.0.0.4509.2e5a9a2 2 m2w64-libwinpthread-git 5.0.0.4634.697f757 2 m2w64-make 4.1.2351.a80a8b8 2 m2w64-mpc 1.0.3 3 m2w64-mpfr 3.1.4 4 m2w64-pkg-config 0.29.1 2 m2w64-toolchain 5.3.0 7 m2w64-tools-git 5.0.0.4592.90b8472 2 m2w64-windows-default-manifest 6.4 3 m2w64-winpthreads-git 5.0.0.4634.697f757 2 m2w64-zlib 1.2.8 10 mako 1.0.6 py36_0 markupsafe 0.23 py36_2 matplotlib 2.2.2 py36_1 conda-forge matplotlib 2.1.2 &lt;pip&gt; mccabe 0.6.1 &lt;pip&gt; menuinst 1.4.7 py36_0 metis 5.1.0 vc14_3 [vc14] conda-forge mingw 4.7 1 mkl 2018.0.2 1 mkl-service 1.1.2 py36_3 mkl_fft 1.0.1 py36_1 conda-forge mkl_random 1.0.1 py36_0 conda-forge msys2-conda-epoch 20160418 1 networkx 2.1 &lt;pip&gt; networkx 2.0 py36_1 conda-forge nose 1.3.7 py36_1 nose-parameterized 0.5.0 py36_0 numpy 1.14.0 &lt;pip&gt; numpy 1.14.3 py36_blas_openblas_200 [blas_openblas] conda-forge olefile 0.44 py36_0 conda-forge openblas 0.2.20 vc14_7 [vc14] conda-forge opencv-python 3.4.0 &lt;pip&gt; openmp 5.0.0 vc14_1 [vc14] conda-forge openssl 1.0.2n vc14_0 [vc14] conda-forge packaging 16.8 py36_0 pandas 0.22.0 py36_1 conda-forge path.py 10.3.1 py36_0 pickleshare 0.7.4 py36_0 Pillow 5.0.0 &lt;pip&gt; pillow 5.0.0 py36_0 conda-forge pip 9.0.3 py36_0 conda-forge prompt_toolkit 1.0.14 py36_0 pyasn1 0.2.3 py36_0 pycosat 0.6.2 py36_0 pycparser 2.17 py36_0 pydot 1.0.29 &lt;pip&gt; pyglet 1.3.1 &lt;pip&gt; pygments 2.2.0 py36_0 pygpu 0.7.5 py36_0 conda-forge pyopenssl 17.0.0 py36_0 pyparsing 2.2.0 &lt;pip&gt; pyparsing 2.1.4 py36_0 pyqt 5.6.0 py36_2 python 3.6.1 2 python-dateutil 2.6.0 py36_0 python-dateutil 2.6.1 &lt;pip&gt; pytz 2018.3 &lt;pip&gt; pytz 2017.2 py36_0 PyWavelets 0.5.2 &lt;pip&gt; pywavelets 0.5.2 py36_1 conda-forge pywin32 220 py36_2 qt 5.6.2 vc14_1 [vc14] conda-forge requests 2.14.2 py36_0 ruamel_yaml 0.11.14 py36_1 scikit-image 0.13.1 py36_0 conda-forge scikit-learn 0.19.1 &lt;pip&gt; scipy 1.0.0 py36h1260518_0 setuptools 27.2.0 py36_1 simplegeneric 0.8.1 py36_1 sip 4.18 py36_0 six 1.10.0 py36_0 six 1.11.0 &lt;pip&gt; sklearn 0.0 &lt;pip&gt; snowballstemmer 1.2.1 py36_0 sphinx 1.6.2 py36_0 sphinxcontrib 1.0 py36_0 sphinxcontrib-websupport 1.0.1 py36_0 sqlite 3.22.0 vc14_0 [vc14] conda-forge suitesparse 5.1.2 blas_openblas_vc14_202 [blas_openblas vc14] conda-forge tbb 2018_20171205 vc14_0 [vc14] conda-forge theano 0.9.0 py36_0 tk 8.5.19 vc14_1 [vc14] conda-forge toolz 0.8.2 py_2 conda-forge tornado 5.0.2 py36_0 conda-forge traitlets 4.3.2 py36_0 vc 14 0 conda-forge vs2015_runtime 14.0.25123 0 wcwidth 0.1.7 py36_0 wheel 0.29.0 py36_0 XlsxWriter 1.0.2 &lt;pip&gt; yaml 0.1.7 vc14_0 [vc14] conda-forge zlib 1.2.11 vc14_0 [vc14] conda-forge </code></pre></div> <p dir="auto">Python 3.5 environment:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="E:\Development&gt;activate python35 (python35) E:\Development&gt;python Python 3.5.5 | packaged by conda-forge | (default, Feb 13 2018, 06:15:35) [MSC v.1900 64 bit (AMD64)] on win32 Type &quot;help&quot;, &quot;copyright&quot;, &quot;credits&quot; or &quot;license&quot; for more information. &gt;&gt;&gt; exit() (python35) E:\Development&gt;conda list # packages in environment at C:\Users\uqasnosw\AppData\Local\Continuum\Miniconda3\envs\python35: # # Name Version Build Channel absl-py 0.2.0 &lt;pip&gt; astor 0.6.2 &lt;pip&gt; atari-py 0.1.1 &lt;pip&gt; backcall 0.1.0 py_0 conda-forge baselines 0.1.5 &lt;pip&gt; blas 1.1 openblas conda-forge bleach 2.1.3 py_0 conda-forge bleach 1.5.0 &lt;pip&gt; Box2D 2.3.2 &lt;pip&gt; ca-certificates 2018.1.18 0 conda-forge certifi 2018.1.18 py35_0 conda-forge cffi 1.11.5 py35_0 conda-forge chardet 3.0.4 &lt;pip&gt; click 6.7 &lt;pip&gt; cloudpickle 0.5.2 &lt;pip&gt; colorama 0.3.9 py35_0 conda-forge cvxopt 1.2.0 py35_blas_openblas_200 [blas_openblas] conda-forge cycler 0.10.0 py35_0 conda-forge Cython 0.28.1 &lt;pip&gt; decorator 4.3.0 py_0 conda-forge dill 0.2.7.1 &lt;pip&gt; entrypoints 0.2.3 py35_1 conda-forge freetype 2.8.1 vc14_0 [vc14] conda-forge future 0.16.0 &lt;pip&gt; gast 0.2.0 &lt;pip&gt; glfw 1.6.0 &lt;pip&gt; glpk 4.65 vc14_0 [vc14] conda-forge grpcio 1.11.0 &lt;pip&gt; gym 0.9.6 &lt;pip&gt; html5lib 0.9999999 &lt;pip&gt; html5lib 1.0.1 py_0 conda-forge icc_rt 2017.0.4 h97af966_0 icu 58.2 vc14_0 [vc14] conda-forge idna 2.6 &lt;pip&gt; imageio 2.3.0 &lt;pip&gt; intel-openmp 2018.0.0 8 ipykernel 4.8.2 py35_0 conda-forge ipython 6.3.1 py35_0 conda-forge ipython_genutils 0.2.0 py35_0 conda-forge ipywidgets 7.2.1 py35_1 conda-forge jedi 0.12.0 py35_0 conda-forge jinja2 2.10 py35_0 conda-forge joblib 0.11 &lt;pip&gt; jpeg 9b vc14_2 [vc14] conda-forge jsonschema 2.6.0 py35_1 conda-forge jupyter 1.0.0 py_1 conda-forge jupyter_client 5.2.3 py35_0 conda-forge jupyter_console 5.2.0 py35_0 conda-forge jupyter_core 4.4.0 py_0 conda-forge kiwisolver 1.0.1 py35_1 conda-forge libflang 5.0.0 vc14_20180208 [vc14] conda-forge libpng 1.6.34 vc14_0 [vc14] conda-forge libsodium 1.0.16 vc14_0 [vc14] conda-forge llvm-meta 5.0.0 0 conda-forge m2w64-dsdp 5.8 1 m2w64-fftw 3.3.4 6 m2w64-gcc-libgfortran 5.3.0 6 m2w64-gcc-libs 5.3.0 7 m2w64-gcc-libs-core 5.3.0 7 m2w64-glpk 4.61 1 m2w64-gmp 6.1.0 2 m2w64-gsl 2.1 2 m2w64-libwinpthread-git 5.0.0.4634.697f757 2 m2w64-openblas 0.2.19 1 Markdown 2.6.11 &lt;pip&gt; markupsafe 1.0 py35_0 conda-forge matplotlib 2.2.2 py35_1 conda-forge metis 5.1.0 vc14_3 [vc14] conda-forge mistune 0.8.3 py35_1 conda-forge mkl 2018.0.2 1 mkl_fft 1.0.1 py35_1 conda-forge mkl_random 1.0.1 py35_0 conda-forge mpi4py 3.0.0 &lt;pip&gt; msys2-conda-epoch 20160418 1 mujoco-py 1.50.1.53 &lt;pip&gt; nbconvert 5.3.1 py_1 conda-forge nbformat 4.4.0 py35_0 conda-forge notebook 5.4.1 py35_0 conda-forge numpy 1.14.2 py35_blas_openblas_200 [blas_openblas] conda-forge openblas 0.2.20 vc14_7 [vc14] conda-forge openmp 5.0.0 vc14_1 [vc14] conda-forge openssl 1.0.2n vc14_0 [vc14] conda-forge pandoc 2.1.3 0 conda-forge pandocfilters 1.4.2 py35_0 conda-forge parso 0.2.0 py_0 conda-forge pickleshare 0.7.4 py35_0 conda-forge Pillow 5.1.0 &lt;pip&gt; pip 10.0.1 &lt;pip&gt; pip 9.0.3 py35_0 conda-forge progressbar2 3.37.1 &lt;pip&gt; prompt_toolkit 1.0.15 py35_0 conda-forge protobuf 3.5.2.post1 &lt;pip&gt; pycparser 2.18 &lt;pip&gt; pycparser 2.18 py35_0 conda-forge pyglet 1.3.1 &lt;pip&gt; pygments 2.2.0 py35_0 conda-forge PyOpenGL 3.1.0 &lt;pip&gt; pyparsing 2.2.0 py35_0 conda-forge pyqt 5.6.0 py35_4 conda-forge pyreadline 2.1 &lt;pip&gt; python 3.5.5 0 conda-forge python-dateutil 2.7.2 py_0 conda-forge python-utils 2.3.0 &lt;pip&gt; pytorch-cpu 0.4.0 py35_cpuhe774522_1 pytorch pytz 2018.3 py_0 conda-forge pywinpty 0.5 py35_2 conda-forge pyzmq 17.0.0 &lt;pip&gt; pyzmq 17.0.0 py35_4 conda-forge qt 5.6.2 vc14_1 [vc14] conda-forge qtconsole 4.3.1 py35_0 conda-forge requests 2.18.4 &lt;pip&gt; scikit-learn 0.19.1 py35h2037775_0 scipy 1.0.1 py35hce232c7_0 send2trash 1.5.0 py_0 conda-forge setuptools 39.0.1 py35_0 conda-forge simplegeneric 0.8.1 py35_0 conda-forge sip 4.18 py35_1 conda-forge six 1.11.0 py35_1 conda-forge suitesparse 5.1.2 blas_openblas_vc14_202 [blas_openblas vc14] conda-forge tbb 2018_20171205 vc14_0 [vc14] conda-forge tensorboard 1.7.0 &lt;pip&gt; tensorflow 1.7.0 &lt;pip&gt; termcolor 1.1.0 &lt;pip&gt; terminado 0.8.1 py35_0 conda-forge testpath 0.3.1 py35_0 conda-forge torchvision 0.2.1 &lt;pip&gt; tornado 5.0.2 py35_0 conda-forge tqdm 4.23.0 &lt;pip&gt; traitlets 4.3.2 py35_0 conda-forge urllib3 1.22 &lt;pip&gt; vc 14 0 conda-forge vs2015_runtime 14.0.25420 0 conda-forge wcwidth 0.1.7 py35_0 conda-forge webencodings 0.5.1 py35_0 conda-forge Werkzeug 0.14.1 &lt;pip&gt; wheel 0.31.0 py35_0 conda-forge widgetsnbextension 3.2.1 py35_0 conda-forge win_unicode_console 0.5 py35_0 conda-forge wincertstore 0.2 py35_0 conda-forge winpty 0.4.3 vc14_2 [vc14] conda-forge xlsxwriter 1.0.2 py_0 conda-forge zeromq 4.2.5 vc14_1 [vc14] conda-forge zlib 1.2.11 vc14_0 [vc14] conda-forge zmq 0.0.0 &lt;pip&gt;"><pre class="notranslate"><code class="notranslate">E:\Development&gt;activate python35 (python35) E:\Development&gt;python Python 3.5.5 | packaged by conda-forge | (default, Feb 13 2018, 06:15:35) [MSC v.1900 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license" for more information. &gt;&gt;&gt; exit() (python35) E:\Development&gt;conda list # packages in environment at C:\Users\uqasnosw\AppData\Local\Continuum\Miniconda3\envs\python35: # # Name Version Build Channel absl-py 0.2.0 &lt;pip&gt; astor 0.6.2 &lt;pip&gt; atari-py 0.1.1 &lt;pip&gt; backcall 0.1.0 py_0 conda-forge baselines 0.1.5 &lt;pip&gt; blas 1.1 openblas conda-forge bleach 2.1.3 py_0 conda-forge bleach 1.5.0 &lt;pip&gt; Box2D 2.3.2 &lt;pip&gt; ca-certificates 2018.1.18 0 conda-forge certifi 2018.1.18 py35_0 conda-forge cffi 1.11.5 py35_0 conda-forge chardet 3.0.4 &lt;pip&gt; click 6.7 &lt;pip&gt; cloudpickle 0.5.2 &lt;pip&gt; colorama 0.3.9 py35_0 conda-forge cvxopt 1.2.0 py35_blas_openblas_200 [blas_openblas] conda-forge cycler 0.10.0 py35_0 conda-forge Cython 0.28.1 &lt;pip&gt; decorator 4.3.0 py_0 conda-forge dill 0.2.7.1 &lt;pip&gt; entrypoints 0.2.3 py35_1 conda-forge freetype 2.8.1 vc14_0 [vc14] conda-forge future 0.16.0 &lt;pip&gt; gast 0.2.0 &lt;pip&gt; glfw 1.6.0 &lt;pip&gt; glpk 4.65 vc14_0 [vc14] conda-forge grpcio 1.11.0 &lt;pip&gt; gym 0.9.6 &lt;pip&gt; html5lib 0.9999999 &lt;pip&gt; html5lib 1.0.1 py_0 conda-forge icc_rt 2017.0.4 h97af966_0 icu 58.2 vc14_0 [vc14] conda-forge idna 2.6 &lt;pip&gt; imageio 2.3.0 &lt;pip&gt; intel-openmp 2018.0.0 8 ipykernel 4.8.2 py35_0 conda-forge ipython 6.3.1 py35_0 conda-forge ipython_genutils 0.2.0 py35_0 conda-forge ipywidgets 7.2.1 py35_1 conda-forge jedi 0.12.0 py35_0 conda-forge jinja2 2.10 py35_0 conda-forge joblib 0.11 &lt;pip&gt; jpeg 9b vc14_2 [vc14] conda-forge jsonschema 2.6.0 py35_1 conda-forge jupyter 1.0.0 py_1 conda-forge jupyter_client 5.2.3 py35_0 conda-forge jupyter_console 5.2.0 py35_0 conda-forge jupyter_core 4.4.0 py_0 conda-forge kiwisolver 1.0.1 py35_1 conda-forge libflang 5.0.0 vc14_20180208 [vc14] conda-forge libpng 1.6.34 vc14_0 [vc14] conda-forge libsodium 1.0.16 vc14_0 [vc14] conda-forge llvm-meta 5.0.0 0 conda-forge m2w64-dsdp 5.8 1 m2w64-fftw 3.3.4 6 m2w64-gcc-libgfortran 5.3.0 6 m2w64-gcc-libs 5.3.0 7 m2w64-gcc-libs-core 5.3.0 7 m2w64-glpk 4.61 1 m2w64-gmp 6.1.0 2 m2w64-gsl 2.1 2 m2w64-libwinpthread-git 5.0.0.4634.697f757 2 m2w64-openblas 0.2.19 1 Markdown 2.6.11 &lt;pip&gt; markupsafe 1.0 py35_0 conda-forge matplotlib 2.2.2 py35_1 conda-forge metis 5.1.0 vc14_3 [vc14] conda-forge mistune 0.8.3 py35_1 conda-forge mkl 2018.0.2 1 mkl_fft 1.0.1 py35_1 conda-forge mkl_random 1.0.1 py35_0 conda-forge mpi4py 3.0.0 &lt;pip&gt; msys2-conda-epoch 20160418 1 mujoco-py 1.50.1.53 &lt;pip&gt; nbconvert 5.3.1 py_1 conda-forge nbformat 4.4.0 py35_0 conda-forge notebook 5.4.1 py35_0 conda-forge numpy 1.14.2 py35_blas_openblas_200 [blas_openblas] conda-forge openblas 0.2.20 vc14_7 [vc14] conda-forge openmp 5.0.0 vc14_1 [vc14] conda-forge openssl 1.0.2n vc14_0 [vc14] conda-forge pandoc 2.1.3 0 conda-forge pandocfilters 1.4.2 py35_0 conda-forge parso 0.2.0 py_0 conda-forge pickleshare 0.7.4 py35_0 conda-forge Pillow 5.1.0 &lt;pip&gt; pip 10.0.1 &lt;pip&gt; pip 9.0.3 py35_0 conda-forge progressbar2 3.37.1 &lt;pip&gt; prompt_toolkit 1.0.15 py35_0 conda-forge protobuf 3.5.2.post1 &lt;pip&gt; pycparser 2.18 &lt;pip&gt; pycparser 2.18 py35_0 conda-forge pyglet 1.3.1 &lt;pip&gt; pygments 2.2.0 py35_0 conda-forge PyOpenGL 3.1.0 &lt;pip&gt; pyparsing 2.2.0 py35_0 conda-forge pyqt 5.6.0 py35_4 conda-forge pyreadline 2.1 &lt;pip&gt; python 3.5.5 0 conda-forge python-dateutil 2.7.2 py_0 conda-forge python-utils 2.3.0 &lt;pip&gt; pytorch-cpu 0.4.0 py35_cpuhe774522_1 pytorch pytz 2018.3 py_0 conda-forge pywinpty 0.5 py35_2 conda-forge pyzmq 17.0.0 &lt;pip&gt; pyzmq 17.0.0 py35_4 conda-forge qt 5.6.2 vc14_1 [vc14] conda-forge qtconsole 4.3.1 py35_0 conda-forge requests 2.18.4 &lt;pip&gt; scikit-learn 0.19.1 py35h2037775_0 scipy 1.0.1 py35hce232c7_0 send2trash 1.5.0 py_0 conda-forge setuptools 39.0.1 py35_0 conda-forge simplegeneric 0.8.1 py35_0 conda-forge sip 4.18 py35_1 conda-forge six 1.11.0 py35_1 conda-forge suitesparse 5.1.2 blas_openblas_vc14_202 [blas_openblas vc14] conda-forge tbb 2018_20171205 vc14_0 [vc14] conda-forge tensorboard 1.7.0 &lt;pip&gt; tensorflow 1.7.0 &lt;pip&gt; termcolor 1.1.0 &lt;pip&gt; terminado 0.8.1 py35_0 conda-forge testpath 0.3.1 py35_0 conda-forge torchvision 0.2.1 &lt;pip&gt; tornado 5.0.2 py35_0 conda-forge tqdm 4.23.0 &lt;pip&gt; traitlets 4.3.2 py35_0 conda-forge urllib3 1.22 &lt;pip&gt; vc 14 0 conda-forge vs2015_runtime 14.0.25420 0 conda-forge wcwidth 0.1.7 py35_0 conda-forge webencodings 0.5.1 py35_0 conda-forge Werkzeug 0.14.1 &lt;pip&gt; wheel 0.31.0 py35_0 conda-forge widgetsnbextension 3.2.1 py35_0 conda-forge win_unicode_console 0.5 py35_0 conda-forge wincertstore 0.2 py35_0 conda-forge winpty 0.4.3 vc14_2 [vc14] conda-forge xlsxwriter 1.0.2 py_0 conda-forge zeromq 4.2.5 vc14_1 [vc14] conda-forge zlib 1.2.11 vc14_0 [vc14] conda-forge zmq 0.0.0 &lt;pip&gt; </code></pre></div> <p dir="auto">Python 2.7 environment (can't reproduce here):</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="E:\Development&gt;activate python27 (python27) E:\Development&gt;python Python 2.7.13 |Anaconda 4.4.0 (64-bit)| (default, May 11 2017, 13:17:26) [MSC v.1500 64 bit (AMD64)] on win32 Type &quot;help&quot;, &quot;copyright&quot;, &quot;credits&quot; or &quot;license&quot; for more information. Anaconda is brought to you by Continuum Analytics. Please check out: http://continuum.io/thanks and https://anaconda.org &gt;&gt;&gt; exit() (python27) E:\Development&gt;conda list # packages in environment at C:\Users\uqasnosw\AppData\Local\Continuum\Miniconda3\envs\python27: # # Name Version Build Channel _license 1.1 py27_1 alabaster 0.7.10 py27_0 anaconda 4.4.0 np112py27_0 anaconda-client 1.6.3 py27_0 anaconda-navigator 1.6.2 py27_0 anaconda-project 0.6.0 py27_0 asn1crypto 0.22.0 py27_0 astroid 1.4.9 py27_0 astropy 1.3.2 np112py27_0 babel 2.4.0 py27_0 backports 1.0 py27_0 backports_abc 0.5 py27_0 beautifulsoup4 4.6.0 py27_0 bitarray 0.8.1 py27_1 blaze 0.10.1 py27_0 bleach 1.5.0 py27_0 bokeh 0.12.5 py27_1 boto 2.46.1 py27_0 bottleneck 1.2.1 np112py27_0 bzip2 1.0.6 vc9_3 [vc9] cdecimal 2.3 py27_2 cffi 1.10.0 py27_0 chardet 3.0.3 py27_0 click 6.7 py27_0 cloudpickle 0.2.2 py27_0 clyent 1.2.2 py27_0 colorama 0.3.9 py27_0 comtypes 1.1.2 py27_0 configparser 3.5.0 py27_0 console_shortcut 0.1.1 py27_1 contextlib2 0.5.5 py27_0 cryptography 1.8.1 py27_0 curl 7.52.1 vc9_0 [vc9] cvxopt 1.1.9 &lt;pip&gt; cycler 0.10.0 py27_0 cython 0.25.2 py27_0 cytoolz 0.8.2 py27_0 dask 0.14.3 py27_1 datashape 0.5.4 py27_0 decorator 4.0.11 py27_0 distributed 1.16.3 py27_0 docutils 0.13.1 py27_0 entrypoints 0.2.2 py27_1 enum34 1.1.6 py27_0 et_xmlfile 1.0.1 py27_0 fastcache 1.0.2 py27_1 flask 0.12.2 py27_0 flask-cors 3.0.2 py27_0 freetype 2.5.5 vc9_2 [vc9] funcsigs 1.0.2 py27_0 functools32 3.2.3.2 py27_0 futures 3.1.1 py27_0 get_terminal_size 1.0.0 py27_0 gevent 1.2.1 py27_0 greenlet 0.4.12 py27_0 grin 1.2.1 py27_3 h5py 2.7.0 np112py27_0 hdf5 1.8.15.1 vc9_4 [vc9] heapdict 1.0.0 py27_1 html5lib 0.999 py27_0 icu 57.1 vc9_0 [vc9] idna 2.5 py27_0 imagesize 0.7.1 py27_0 ipaddress 1.0.18 py27_0 ipykernel 4.6.1 py27_0 ipython 5.3.0 py27_0 ipython_genutils 0.2.0 py27_0 ipywidgets 6.0.0 py27_0 isort 4.2.5 py27_0 itsdangerous 0.24 py27_0 jdcal 1.3 py27_0 jedi 0.10.2 py27_2 jinja2 2.9.6 py27_0 jpeg 9b vc9_0 [vc9] jsonschema 2.6.0 py27_0 jupyter 1.0.0 py27_3 jupyter_client 5.0.1 py27_0 jupyter_console 5.1.0 py27_0 jupyter_core 4.3.0 py27_0 lazy-object-proxy 1.2.2 py27_0 libpng 1.6.27 vc9_0 [vc9] libtiff 4.0.6 vc9_3 [vc9] llvmlite 0.18.0 py27_0 locket 0.2.0 py27_1 lxml 3.7.3 py27_0 markupsafe 0.23 py27_2 matplotlib 2.0.2 np112py27_0 menuinst 1.4.7 py27_0 mistune 0.7.4 py27_0 mkl 2017.0.1 0 mkl-service 1.1.2 py27_3 mpmath 0.19 py27_1 msgpack-python 0.4.8 py27_0 multipledispatch 0.4.9 py27_0 navigator-updater 0.1.0 py27_0 nbconvert 5.1.1 py27_0 nbformat 4.3.0 py27_0 networkx 1.11 py27_0 nltk 3.2.3 py27_0 nose 1.3.7 py27_1 notebook 5.0.0 py27_0 numba 0.33.0 np112py27_0 numexpr 2.6.2 np112py27_0 numpy 1.12.1 py27_0 numpydoc 0.6.0 py27_0 odo 0.5.0 py27_1 olefile 0.44 py27_0 openpyxl 2.4.7 py27_0 openssl 1.0.2l vc9_0 [vc9] packaging 16.8 py27_0 pandas 0.20.1 np112py27_0 pandocfilters 1.4.1 py27_0 partd 0.3.8 py27_0 path.py 10.3.1 py27_0 pathlib2 2.2.1 py27_0 patsy 0.4.1 py27_0 pep8 1.7.0 py27_0 pickleshare 0.7.4 py27_0 pillow 4.1.1 py27_0 pip 9.0.1 py27_1 ply 3.10 py27_0 prompt_toolkit 1.0.14 py27_0 psutil 5.2.2 py27_0 py 1.4.33 py27_0 pycosat 0.6.2 py27_0 pycparser 2.17 py27_0 pycrypto 2.6.1 py27_6 pycurl 7.43.0 py27_2 pyflakes 1.5.0 py27_0 pygments 2.2.0 py27_0 pylint 1.6.4 py27_1 pyodbc 4.0.16 py27_0 pyopenssl 17.0.0 py27_0 pyparsing 2.1.4 py27_0 pyqt 5.6.0 py27_2 pytables 3.2.2 np112py27_4 pytest 3.0.7 py27_0 python 2.7.13 1 python-dateutil 2.6.0 py27_0 pytz 2017.2 py27_0 pywavelets 0.5.2 np112py27_0 pywin32 220 py27_2 pyyaml 3.12 py27_0 pyzmq 16.0.2 py27_0 qt 5.6.2 vc9_4 [vc9] qtawesome 0.4.4 py27_0 qtconsole 4.3.0 py27_0 qtpy 1.2.1 py27_0 requests 2.14.2 py27_0 rope 0.9.4 py27_1 ruamel_yaml 0.11.14 py27_1 scandir 1.5 py27_0 scikit-image 0.13.0 np112py27_0 scikit-learn 0.18.1 np112py27_1 scipy 0.19.0 np112py27_0 seaborn 0.7.1 py27_0 setuptools 27.2.0 py27_1 simplegeneric 0.8.1 py27_1 singledispatch 3.4.0.3 py27_0 sip 4.18 py27_0 six 1.10.0 py27_0 snowballstemmer 1.2.1 py27_0 sortedcollections 0.5.3 py27_0 sortedcontainers 1.5.7 py27_0 sphinx 1.5.6 py27_0 spyder 3.1.4 py27_0 sqlalchemy 1.1.9 py27_0 ssl_match_hostname 3.4.0.2 py27_1 statsmodels 0.8.0 np112py27_0 subprocess32 3.2.7 py27_0 sympy 1.0 py27_0 tblib 1.3.2 py27_0 testpath 0.3 py27_0 tk 8.5.18 vc9_0 [vc9] toolz 0.8.2 py27_0 tornado 4.5.1 py27_0 traitlets 4.3.2 py27_0 unicodecsv 0.14.1 py27_0 vs2008_runtime 9.00.30729.5054 0 vs2015_runtime 14.0.25123 0 wcwidth 0.1.7 py27_0 werkzeug 0.12.2 py27_0 wheel 0.29.0 py27_0 widgetsnbextension 2.0.0 py27_0 win_unicode_console 0.5 py27_0 wrapt 1.10.10 py27_0 xlrd 1.0.0 py27_0 xlsxwriter 0.9.6 py27_0 xlwings 0.10.4 py27_0 xlwt 1.2.0 py27_0 zict 0.1.2 py27_0 zlib 1.2.8 vc9_3 [vc9]"><pre class="notranslate"><code class="notranslate">E:\Development&gt;activate python27 (python27) E:\Development&gt;python Python 2.7.13 |Anaconda 4.4.0 (64-bit)| (default, May 11 2017, 13:17:26) [MSC v.1500 64 bit (AMD64)] on win32 Type "help", "copyright", "credits" or "license" for more information. Anaconda is brought to you by Continuum Analytics. Please check out: http://continuum.io/thanks and https://anaconda.org &gt;&gt;&gt; exit() (python27) E:\Development&gt;conda list # packages in environment at C:\Users\uqasnosw\AppData\Local\Continuum\Miniconda3\envs\python27: # # Name Version Build Channel _license 1.1 py27_1 alabaster 0.7.10 py27_0 anaconda 4.4.0 np112py27_0 anaconda-client 1.6.3 py27_0 anaconda-navigator 1.6.2 py27_0 anaconda-project 0.6.0 py27_0 asn1crypto 0.22.0 py27_0 astroid 1.4.9 py27_0 astropy 1.3.2 np112py27_0 babel 2.4.0 py27_0 backports 1.0 py27_0 backports_abc 0.5 py27_0 beautifulsoup4 4.6.0 py27_0 bitarray 0.8.1 py27_1 blaze 0.10.1 py27_0 bleach 1.5.0 py27_0 bokeh 0.12.5 py27_1 boto 2.46.1 py27_0 bottleneck 1.2.1 np112py27_0 bzip2 1.0.6 vc9_3 [vc9] cdecimal 2.3 py27_2 cffi 1.10.0 py27_0 chardet 3.0.3 py27_0 click 6.7 py27_0 cloudpickle 0.2.2 py27_0 clyent 1.2.2 py27_0 colorama 0.3.9 py27_0 comtypes 1.1.2 py27_0 configparser 3.5.0 py27_0 console_shortcut 0.1.1 py27_1 contextlib2 0.5.5 py27_0 cryptography 1.8.1 py27_0 curl 7.52.1 vc9_0 [vc9] cvxopt 1.1.9 &lt;pip&gt; cycler 0.10.0 py27_0 cython 0.25.2 py27_0 cytoolz 0.8.2 py27_0 dask 0.14.3 py27_1 datashape 0.5.4 py27_0 decorator 4.0.11 py27_0 distributed 1.16.3 py27_0 docutils 0.13.1 py27_0 entrypoints 0.2.2 py27_1 enum34 1.1.6 py27_0 et_xmlfile 1.0.1 py27_0 fastcache 1.0.2 py27_1 flask 0.12.2 py27_0 flask-cors 3.0.2 py27_0 freetype 2.5.5 vc9_2 [vc9] funcsigs 1.0.2 py27_0 functools32 3.2.3.2 py27_0 futures 3.1.1 py27_0 get_terminal_size 1.0.0 py27_0 gevent 1.2.1 py27_0 greenlet 0.4.12 py27_0 grin 1.2.1 py27_3 h5py 2.7.0 np112py27_0 hdf5 1.8.15.1 vc9_4 [vc9] heapdict 1.0.0 py27_1 html5lib 0.999 py27_0 icu 57.1 vc9_0 [vc9] idna 2.5 py27_0 imagesize 0.7.1 py27_0 ipaddress 1.0.18 py27_0 ipykernel 4.6.1 py27_0 ipython 5.3.0 py27_0 ipython_genutils 0.2.0 py27_0 ipywidgets 6.0.0 py27_0 isort 4.2.5 py27_0 itsdangerous 0.24 py27_0 jdcal 1.3 py27_0 jedi 0.10.2 py27_2 jinja2 2.9.6 py27_0 jpeg 9b vc9_0 [vc9] jsonschema 2.6.0 py27_0 jupyter 1.0.0 py27_3 jupyter_client 5.0.1 py27_0 jupyter_console 5.1.0 py27_0 jupyter_core 4.3.0 py27_0 lazy-object-proxy 1.2.2 py27_0 libpng 1.6.27 vc9_0 [vc9] libtiff 4.0.6 vc9_3 [vc9] llvmlite 0.18.0 py27_0 locket 0.2.0 py27_1 lxml 3.7.3 py27_0 markupsafe 0.23 py27_2 matplotlib 2.0.2 np112py27_0 menuinst 1.4.7 py27_0 mistune 0.7.4 py27_0 mkl 2017.0.1 0 mkl-service 1.1.2 py27_3 mpmath 0.19 py27_1 msgpack-python 0.4.8 py27_0 multipledispatch 0.4.9 py27_0 navigator-updater 0.1.0 py27_0 nbconvert 5.1.1 py27_0 nbformat 4.3.0 py27_0 networkx 1.11 py27_0 nltk 3.2.3 py27_0 nose 1.3.7 py27_1 notebook 5.0.0 py27_0 numba 0.33.0 np112py27_0 numexpr 2.6.2 np112py27_0 numpy 1.12.1 py27_0 numpydoc 0.6.0 py27_0 odo 0.5.0 py27_1 olefile 0.44 py27_0 openpyxl 2.4.7 py27_0 openssl 1.0.2l vc9_0 [vc9] packaging 16.8 py27_0 pandas 0.20.1 np112py27_0 pandocfilters 1.4.1 py27_0 partd 0.3.8 py27_0 path.py 10.3.1 py27_0 pathlib2 2.2.1 py27_0 patsy 0.4.1 py27_0 pep8 1.7.0 py27_0 pickleshare 0.7.4 py27_0 pillow 4.1.1 py27_0 pip 9.0.1 py27_1 ply 3.10 py27_0 prompt_toolkit 1.0.14 py27_0 psutil 5.2.2 py27_0 py 1.4.33 py27_0 pycosat 0.6.2 py27_0 pycparser 2.17 py27_0 pycrypto 2.6.1 py27_6 pycurl 7.43.0 py27_2 pyflakes 1.5.0 py27_0 pygments 2.2.0 py27_0 pylint 1.6.4 py27_1 pyodbc 4.0.16 py27_0 pyopenssl 17.0.0 py27_0 pyparsing 2.1.4 py27_0 pyqt 5.6.0 py27_2 pytables 3.2.2 np112py27_4 pytest 3.0.7 py27_0 python 2.7.13 1 python-dateutil 2.6.0 py27_0 pytz 2017.2 py27_0 pywavelets 0.5.2 np112py27_0 pywin32 220 py27_2 pyyaml 3.12 py27_0 pyzmq 16.0.2 py27_0 qt 5.6.2 vc9_4 [vc9] qtawesome 0.4.4 py27_0 qtconsole 4.3.0 py27_0 qtpy 1.2.1 py27_0 requests 2.14.2 py27_0 rope 0.9.4 py27_1 ruamel_yaml 0.11.14 py27_1 scandir 1.5 py27_0 scikit-image 0.13.0 np112py27_0 scikit-learn 0.18.1 np112py27_1 scipy 0.19.0 np112py27_0 seaborn 0.7.1 py27_0 setuptools 27.2.0 py27_1 simplegeneric 0.8.1 py27_1 singledispatch 3.4.0.3 py27_0 sip 4.18 py27_0 six 1.10.0 py27_0 snowballstemmer 1.2.1 py27_0 sortedcollections 0.5.3 py27_0 sortedcontainers 1.5.7 py27_0 sphinx 1.5.6 py27_0 spyder 3.1.4 py27_0 sqlalchemy 1.1.9 py27_0 ssl_match_hostname 3.4.0.2 py27_1 statsmodels 0.8.0 np112py27_0 subprocess32 3.2.7 py27_0 sympy 1.0 py27_0 tblib 1.3.2 py27_0 testpath 0.3 py27_0 tk 8.5.18 vc9_0 [vc9] toolz 0.8.2 py27_0 tornado 4.5.1 py27_0 traitlets 4.3.2 py27_0 unicodecsv 0.14.1 py27_0 vs2008_runtime 9.00.30729.5054 0 vs2015_runtime 14.0.25123 0 wcwidth 0.1.7 py27_0 werkzeug 0.12.2 py27_0 wheel 0.29.0 py27_0 widgetsnbextension 2.0.0 py27_0 win_unicode_console 0.5 py27_0 wrapt 1.10.10 py27_0 xlrd 1.0.0 py27_0 xlsxwriter 0.9.6 py27_0 xlwings 0.10.4 py27_0 xlwt 1.2.0 py27_0 zict 0.1.2 py27_0 zlib 1.2.8 vc9_3 [vc9] </code></pre></div> <p dir="auto">My system configuration (from DxDiag) is <a href="https://github.com/numpy/numpy/files/1971989/DxDiag.txt">here</a>.</p> <p dir="auto">NB: This seems to be a re-incarnation of <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="36001590" data-permission-text="Title is private" data-url="https://github.com/numpy/numpy/issues/4813" data-hovercard-type="issue" data-hovercard-url="/numpy/numpy/issues/4813/hovercard" href="https://github.com/numpy/numpy/issues/4813">#4813</a>.</p> <p dir="auto">Thank you in advance for any help resolving this.</p>
<p dir="auto">Hi,</p> <p dir="auto">I've noticed that numpy's testsuite hangs when numpy is built against MKL 2018.2 - but runs to completion when built against MKL 2017.1.</p> <p dir="auto">This is the case for numpy v1.14.2, 1.14.x HEAD and master branches.</p> <p dir="auto">I'm on CentOS 7.4 x86_64 on a Broadwell processor, python 2.7.5 (but also affects other pythons), Cython 0.28.2, nose 1.3.7.</p> <p dir="auto">By executing this: python -c "import numpy; numpy.test(verbose=2)"</p> <p dir="auto">I can see that the hang occurs while running this test: numpy.distutils.tests.test_exec_command.TestExecCommand.test_basic</p> <p dir="auto">At this point, the python interpreter is consuming an entire CPU core and, if I strace it, I see a stream of identical lines, all showing:</p> <p dir="auto">sched_yield() = 0</p> <p dir="auto">Any ideas, please?</p> <p dir="auto">Thanks!</p>
1
<p dir="auto">#</p><details><summary>Click to expand!</summary><p dir="auto"></p> <h3 dir="auto">Issue Type</h3> <p dir="auto">Bug</p> <h4 dir="auto">Source</h4> <p dir="auto">binary</p> <h4 dir="auto">Tensorflow Version</h4> <p dir="auto">2.8.2</p> <h4 dir="auto">Custom Code</h4> <p dir="auto">Yes</p> <h4 dir="auto">OS Platform and Distribution</h4> <p dir="auto">Linux Ubuntu 18.04.5</p> <h4 dir="auto">Python version</h4> <p dir="auto">Python 3.7.13</p> <h4 dir="auto">Current Behavior</h4> <p dir="auto">I am following the steps here for customizing what happens in <code class="notranslate">train_step</code> when you customize a model:</p> <p dir="auto"><a href="https://www.tensorflow.org/guide/keras/customizing_what_happens_in_fit" rel="nofollow">https://www.tensorflow.org/guide/keras/customizing_what_happens_in_fit</a></p> <p dir="auto">The issue is, I am getting very different results for the loss when I am using the exact same <code class="notranslate">tensorflow.keras.losses.mean_squared_error</code> function in different locations.</p> <p dir="auto">When I use <code class="notranslate">mean_squared_error</code> "manually" during <code class="notranslate">train_step</code> (I am calling this the non-compiled mse), the loss is significantly worse than if I pass it into the compile method, e.g. <code class="notranslate">model.compile(optimizer="adam", loss=mean_squared_error)</code> (I am calling this the compiled mse).</p> <p dir="auto"><code class="notranslate">tensorflow.keras.metrics.MeanSquaredError</code> yields roughly the same result as the compiled version of mse, but it is still not exactly the same.</p> <h4 dir="auto">Expected Behavior</h4> <p dir="auto">My expectation is that the loss should be the same whether it is passed into <code class="notranslate">.compile</code>, defined during <code class="notranslate">train_step</code>, or used as a metric. But it is significantly worse if I do not pass it into <code class="notranslate">.compile</code> and I don't know why. I am following the documentation, and as far as I can tell am not doing anything incorrectly.</p> <p dir="auto">Why is the loss so different when it is and is not passed into <code class="notranslate">.compile</code>?</p> <h4 dir="auto">Colab Notebook</h4> <p dir="auto">I have reproduced this behavior in this google colab notebook, link below. The plot shows that non-compiled mse is systematically worse than compiled mse.</p> <p dir="auto"><a href="https://colab.research.google.com/drive/1c1L8KJYQbAldphKvFvmw5cHi9EyBQP0X?usp=sharing" rel="nofollow">https://colab.research.google.com/drive/1c1L8KJYQbAldphKvFvmw5cHi9EyBQP0X?usp=sharing</a></p> <p dir="auto">Originally I opened a ticket at tensorflow/tensorflow <a href="https://github.com/tensorflow/tensorflow/issues/56866" data-hovercard-type="issue" data-hovercard-url="/tensorflow/tensorflow/issues/56866/hovercard">here</a>, and they were able to reproduce the issue. This is the gist:</p> <p dir="auto"><a href="https://colab.research.google.com/gist/sushreebarsa/f1144243be9eed060c39c60611811811/56866.ipynb" rel="nofollow">https://colab.research.google.com/gist/sushreebarsa/f1144243be9eed060c39c60611811811/56866.ipynb</a></p> <h4 dir="auto">Standalone code to reproduce behavior</h4> <p dir="auto">This is the same as what is in the Colab notebooks.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import tensorflow as tf from tensorflow.keras.metrics import Mean, MeanSquaredError from tensorflow.keras.models import Model from tensorflow.keras.layers import Dense, Dropout, Input from tensorflow.keras.optimizers import Adam from tensorflow.keras.losses import mean_squared_error import matplotlib.pyplot as plt seed = 113 epochs = 30 batch_size = 10 n = 5 history_dict = {} # load dataset (x_train, y_train), (x_test, y_test) = tf.keras.datasets.boston_housing.load_data( path=&quot;boston_housing.npz&quot;, test_split=0.2, seed=seed, ) n_validate = int(0.1 * len(x_train)) train_dataset = tf.data.Dataset.from_tensor_slices( (x_train[:-n_validate], y_train[:-n_validate]) ).batch(batch_size) valid_dataset = tf.data.Dataset.from_tensor_slices( (x_train[-n_validate:], y_train[-n_validate:]) ).batch(batch_size) test_dataset = tf.data.Dataset.from_tensor_slices( (x_test, y_test) ).batch(batch_size) for i in range(n): tf.keras.backend.clear_session() mse_tracker = Mean(name=&quot;non_compiled_mse&quot;) mse_tracker_metric = MeanSquaredError(name=&quot;mse_metric&quot;) class CustomModel(Model): @tf.function def train_step(self, data): x, y_true = data with tf.GradientTape() as tape: y_pred = self(x, training=True) compiled_mse = self.compiled_loss(y_true, y_pred) non_compiled_mse = mean_squared_error(y_true, y_pred) mse_tracker.update_state(non_compiled_mse) mse_tracker_metric.update_state(y_true, y_pred) gradients = tape.gradient(compiled_mse, self.trainable_variables) self.optimizer.apply_gradients(zip(gradients, self.trainable_variables)) return {m.name: m.result() for m in self.metrics} @tf.function() def test_step(self, data): x, y_true = data y_pred = self(x, training=False) compiled_mse = self.compiled_loss(y_true, y_pred) non_compiled_mse = mean_squared_error(y_true, y_pred) mse_tracker.update_state(non_compiled_mse) mse_tracker_metric.update_state(y_true, y_pred) return {m.name: m.result() for m in self.metrics} @property def metrics(self): return super().metrics + [mse_tracker, mse_tracker_metric] input_layer = Input(shape=x_train.shape[1:]) x = Dense(8, activation='linear')(input_layer) x = Dense(8, activation='linear')(x) output_layer = Dense(units=1, activation='linear')(x) model = CustomModel(input_layer, output_layer) model.compile(optimizer=Adam(learning_rate=1e-3), loss=mean_squared_error) history = model.fit( train_dataset, validation_data=valid_dataset, epochs=epochs, verbose=0, ) history_dict[f&quot;compiled_mse_{i}&quot;] = history.history[&quot;loss&quot;] history_dict[f&quot;non_compiled_mse_{i}&quot;] = history.history[&quot;non_compiled_mse&quot;] history_dict[f&quot;mse_metric_{i}&quot;] = history.history[&quot;mse_metric&quot;] plot_start_epoch = 5 plt.figure(figsize=(12, 6)) for i in range(n): plt.plot( range(epochs)[plot_start_epoch:], history_dict[f&quot;compiled_mse_{i}&quot;][plot_start_epoch:], label=f&quot;compiled_mse&quot; if i == 0 else None, color=&quot;black&quot;, ) plt.plot( range(epochs)[plot_start_epoch:], history_dict[f&quot;non_compiled_mse_{i}&quot;][plot_start_epoch:], label=f&quot;non_compiled_mse&quot; if i == 0 else None, color=&quot;orange&quot;, ) plt.plot( range(epochs)[plot_start_epoch:], history_dict[f&quot;mse_metric_{i}&quot;][plot_start_epoch:], label=f&quot;mse_metric&quot; if i == 0 else None, color=&quot;red&quot;, linestyle=&quot;dashed&quot;, ) plt.ylabel(&quot;loss&quot;) plt.xlabel(&quot;epoch&quot;) plt.title(&quot;compiled vs non-compiled mse vs mse metric&quot;) plt.legend() plt.show()"><pre class="notranslate"><code class="notranslate">import tensorflow as tf from tensorflow.keras.metrics import Mean, MeanSquaredError from tensorflow.keras.models import Model from tensorflow.keras.layers import Dense, Dropout, Input from tensorflow.keras.optimizers import Adam from tensorflow.keras.losses import mean_squared_error import matplotlib.pyplot as plt seed = 113 epochs = 30 batch_size = 10 n = 5 history_dict = {} # load dataset (x_train, y_train), (x_test, y_test) = tf.keras.datasets.boston_housing.load_data( path="boston_housing.npz", test_split=0.2, seed=seed, ) n_validate = int(0.1 * len(x_train)) train_dataset = tf.data.Dataset.from_tensor_slices( (x_train[:-n_validate], y_train[:-n_validate]) ).batch(batch_size) valid_dataset = tf.data.Dataset.from_tensor_slices( (x_train[-n_validate:], y_train[-n_validate:]) ).batch(batch_size) test_dataset = tf.data.Dataset.from_tensor_slices( (x_test, y_test) ).batch(batch_size) for i in range(n): tf.keras.backend.clear_session() mse_tracker = Mean(name="non_compiled_mse") mse_tracker_metric = MeanSquaredError(name="mse_metric") class CustomModel(Model): @tf.function def train_step(self, data): x, y_true = data with tf.GradientTape() as tape: y_pred = self(x, training=True) compiled_mse = self.compiled_loss(y_true, y_pred) non_compiled_mse = mean_squared_error(y_true, y_pred) mse_tracker.update_state(non_compiled_mse) mse_tracker_metric.update_state(y_true, y_pred) gradients = tape.gradient(compiled_mse, self.trainable_variables) self.optimizer.apply_gradients(zip(gradients, self.trainable_variables)) return {m.name: m.result() for m in self.metrics} @tf.function() def test_step(self, data): x, y_true = data y_pred = self(x, training=False) compiled_mse = self.compiled_loss(y_true, y_pred) non_compiled_mse = mean_squared_error(y_true, y_pred) mse_tracker.update_state(non_compiled_mse) mse_tracker_metric.update_state(y_true, y_pred) return {m.name: m.result() for m in self.metrics} @property def metrics(self): return super().metrics + [mse_tracker, mse_tracker_metric] input_layer = Input(shape=x_train.shape[1:]) x = Dense(8, activation='linear')(input_layer) x = Dense(8, activation='linear')(x) output_layer = Dense(units=1, activation='linear')(x) model = CustomModel(input_layer, output_layer) model.compile(optimizer=Adam(learning_rate=1e-3), loss=mean_squared_error) history = model.fit( train_dataset, validation_data=valid_dataset, epochs=epochs, verbose=0, ) history_dict[f"compiled_mse_{i}"] = history.history["loss"] history_dict[f"non_compiled_mse_{i}"] = history.history["non_compiled_mse"] history_dict[f"mse_metric_{i}"] = history.history["mse_metric"] plot_start_epoch = 5 plt.figure(figsize=(12, 6)) for i in range(n): plt.plot( range(epochs)[plot_start_epoch:], history_dict[f"compiled_mse_{i}"][plot_start_epoch:], label=f"compiled_mse" if i == 0 else None, color="black", ) plt.plot( range(epochs)[plot_start_epoch:], history_dict[f"non_compiled_mse_{i}"][plot_start_epoch:], label=f"non_compiled_mse" if i == 0 else None, color="orange", ) plt.plot( range(epochs)[plot_start_epoch:], history_dict[f"mse_metric_{i}"][plot_start_epoch:], label=f"mse_metric" if i == 0 else None, color="red", linestyle="dashed", ) plt.ylabel("loss") plt.xlabel("epoch") plt.title("compiled vs non-compiled mse vs mse metric") plt.legend() plt.show() </code></pre></div> <h4 dir="auto">Related Issues</h4> <p dir="auto">I could not find an issue that was the same as this one, but <a href="https://github.com/keras-team/keras/issues/16834" data-hovercard-type="issue" data-hovercard-url="/keras-team/keras/issues/16834/hovercard">16834</a> might be related, as it also notes a difference between compiled mean squared error and manually calculated mean squared error:</p> <blockquote> <p dir="auto">When using keras for regression problems, loss uses mean squared error. The loss displayed by the network fit in the last epoch during training is inconsistent with the loss calculated from the input data after the model is saved.</p> </blockquote> <p dir="auto">I have not tested whether or not this behavior is reproduced when using a loss other than mean squared error.</p></details><p dir="auto"></p>
<p dir="auto">I want to test the loss function, mse in keras by myself. However, the calculated answers are different. The definition of mse is below: <a href="https://en.wikipedia.org/wiki/Mean_squared_error" rel="nofollow">https://en.wikipedia.org/wiki/Mean_squared_error</a></p> <p dir="auto">The test code is below:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="from keras.datasets import boston_housing import numpy as np (train_data, train_targets), (test_data, test_targets) = boston_housing.load_data() x_train = train_data.astype(np.float32) from keras import models from keras import layers model = models.Sequential() model.add(layers.Dense(64, activation='relu', input_shape=(13,))) model.add(layers.Dense(64, activation='relu')) model.add(layers.Dense(1)) model.compile(optimizer='rmsprop',loss='mse', metrics=['mae']) y_train = train_targets.astype(np.float32) # y_test = test_targets.astype(np.float32) model.fit(x_train,y_train,epochs=1,batch_size=404) print(np.mean((y_train - model.predict(x_train).ravel()) ** 2))"><pre class="notranslate"><span class="pl-k">from</span> <span class="pl-s1">keras</span>.<span class="pl-s1">datasets</span> <span class="pl-k">import</span> <span class="pl-s1">boston_housing</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-s1">train_data</span>, <span class="pl-s1">train_targets</span>), (<span class="pl-s1">test_data</span>, <span class="pl-s1">test_targets</span>) <span class="pl-c1">=</span> <span class="pl-s1">boston_housing</span>.<span class="pl-en">load_data</span>() <span class="pl-s1">x_train</span> <span class="pl-c1">=</span> <span class="pl-s1">train_data</span>.<span class="pl-en">astype</span>(<span class="pl-s1">np</span>.<span class="pl-s1">float32</span>) <span class="pl-k">from</span> <span class="pl-s1">keras</span> <span class="pl-k">import</span> <span class="pl-s1">models</span> <span class="pl-k">from</span> <span class="pl-s1">keras</span> <span class="pl-k">import</span> <span class="pl-s1">layers</span> <span class="pl-s1">model</span> <span class="pl-c1">=</span> <span class="pl-s1">models</span>.<span class="pl-v">Sequential</span>() <span class="pl-s1">model</span>.<span class="pl-en">add</span>(<span class="pl-s1">layers</span>.<span class="pl-v">Dense</span>(<span class="pl-c1">64</span>, <span class="pl-s1">activation</span><span class="pl-c1">=</span><span class="pl-s">'relu'</span>, <span class="pl-s1">input_shape</span><span class="pl-c1">=</span>(<span class="pl-c1">13</span>,))) <span class="pl-s1">model</span>.<span class="pl-en">add</span>(<span class="pl-s1">layers</span>.<span class="pl-v">Dense</span>(<span class="pl-c1">64</span>, <span class="pl-s1">activation</span><span class="pl-c1">=</span><span class="pl-s">'relu'</span>)) <span class="pl-s1">model</span>.<span class="pl-en">add</span>(<span class="pl-s1">layers</span>.<span class="pl-v">Dense</span>(<span class="pl-c1">1</span>)) <span class="pl-s1">model</span>.<span class="pl-en">compile</span>(<span class="pl-s1">optimizer</span><span class="pl-c1">=</span><span class="pl-s">'rmsprop'</span>,<span class="pl-s1">loss</span><span class="pl-c1">=</span><span class="pl-s">'mse'</span>, <span class="pl-s1">metrics</span><span class="pl-c1">=</span>[<span class="pl-s">'mae'</span>]) <span class="pl-s1">y_train</span> <span class="pl-c1">=</span> <span class="pl-s1">train_targets</span>.<span class="pl-en">astype</span>(<span class="pl-s1">np</span>.<span class="pl-s1">float32</span>) <span class="pl-c"># y_test = test_targets.astype(np.float32)</span> <span class="pl-s1">model</span>.<span class="pl-en">fit</span>(<span class="pl-s1">x_train</span>,<span class="pl-s1">y_train</span>,<span class="pl-s1">epochs</span><span class="pl-c1">=</span><span class="pl-c1">1</span>,<span class="pl-s1">batch_size</span><span class="pl-c1">=</span><span class="pl-c1">404</span>) <span class="pl-en">print</span>(<span class="pl-s1">np</span>.<span class="pl-en">mean</span>((<span class="pl-s1">y_train</span> <span class="pl-c1">-</span> <span class="pl-s1">model</span>.<span class="pl-en">predict</span>(<span class="pl-s1">x_train</span>).<span class="pl-en">ravel</span>()) <span class="pl-c1">**</span> <span class="pl-c1">2</span>))</pre></div> <p dir="auto">It shows that the loss function is around 816 in keras. However, from the definition of mse, the results is around 704. Why are the results different here?</p>
1
<p dir="auto"><strong>Do you want to request a <em>feature</em> or report a <em>bug</em>?</strong><br> bug</p> <p dir="auto"><strong>What is the current behavior?</strong><br> Webpack is a dependency on <a href="https://github.com/AngularClass/angular2-webpack-starter">this Angular project</a>, and when I attempt to run the project on Windows 7 (this is important as it seems to be a problem on Windows 7 only!), I get the following error message. As it turns out, it is an error in Webpack:</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.context: The provided value &quot;c:\\web-my\\insurance&quot; is not an absolute path! - configuration.output.path: The provided value &quot;c:\\web-my\\insurance\\dist&quot; is not an absolute path!"><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.context: The provided value "c:\\web-my\\insurance" is not an absolute path! - configuration.output.path: The provided value "c:\\web-my\\insurance\\dist" is not an absolute path! </code></pre></div> <p dir="auto">I fixed it quickly by modifying line 20 in schemas\ajv.absolutePath.js from:<br> <code class="notranslate">const passes = expected === /^(?:[A-Z]:\\|\/)/.test(data);</code><br> to:<br> <code class="notranslate">const passes = expected === /^(?:[A-Za-z]:\\|\/)/.test(data);</code><br> I am not sure if this is the best solution, though.</p> <p dir="auto"><strong>If the current behavior is a bug, please provide the steps to reproduce.</strong><br> Checkout the angular project at <a href="https://github.com/AngularClass/angular2-webpack-starter">https://github.com/AngularClass/angular2-webpack-starter</a> and attempt to run in on Windows 7. Then see your console.</p> <p dir="auto"><strong>What is the expected behavior?</strong><br> No errors. The paths should work, even on Windows 7.</p> <p dir="auto"><strong>If this is a feature request, what is motivation or use case for changing the behavior?</strong><br> N/A<br> <strong>Please mention other relevant information such as the browser version, Node.js version, webpack version and Operating System.</strong><br> The error occurs on Windows 7 (this is probably the key information), node v6.9.2, npm v4.0.5, webpack 2.3.1.</p>
<p dir="auto"><strong>Do you want to request a <em>feature</em> or report a <em>bug</em>?</strong><br> Bug</p> <p dir="auto"><strong>What is the current behavior?</strong><br> Webpack fails with error on any path, e.g.:<br> configuration.context: The provided value “d:\projects\project\src” is not an absolute path!</p> <p dir="auto"><strong>If the current behavior is a bug, please provide the steps to reproduce.</strong><br> Windows 10<br> Git Bash<br> Node v6.9.1<br> npm v4.0.0</p> <p dir="auto">Create a webpack project and specify a context path, e.g. <code class="notranslate">context: path.resolve(__dirname, 'src')</code></p> <p dir="auto">run webpack with the specified config.</p> <p dir="auto"><strong>What is the expected behavior?</strong><br> Webpack uses the path as specified.</p> <p dir="auto"><strong>If this is a feature request, what is motivation or use case for changing the behavior?</strong></p> <p dir="auto"><strong>Please mention other relevant information such as the browser version, Node.js version, webpack version and Operating System.</strong><br> Windows 10<br> Git Bash<br> Node v6.9.1<br> npm v4.0.0</p>
1
<p dir="auto">Currently <code class="notranslate">page.route(url, handler, options)</code>/<code class="notranslate">browserContext.route(url, handler, options)</code> intercept routes based on url alone. It would be great if we have the ability to intercept based on any request properties like <code class="notranslate">method</code>, <code class="notranslate">header</code>, etc.</p> <h2 dir="auto">Use case</h2> <p dir="auto">A use case would be the common REST scenario where we want to intercept both <code class="notranslate">GET /items</code> and <code class="notranslate">POST /items</code>.</p> <p dir="auto">Very simplified example:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="test('items', async ({ page }) =&gt; { // Intercept GET /api/items await page.route('/api/items', route =&gt; route.fulfill({ body: JSON.stringify([{ id: 1, name: 'Item 1' }]) })) // Intercept POST /api/items await page.route('/api/items', route =&gt; route.fulfill({ body: JSON.stringify({ id: 2, name: 'Item 2' }) })) await page.goto('/items') // expect &quot;Item 1&quot; to be in the list await page.click('role=button[name=&quot;New item&quot;]') // expect &quot;Item 2&quot; to be created in the list })"><pre class="notranslate"><span class="pl-en">test</span><span class="pl-kos">(</span><span class="pl-s">'items'</span><span class="pl-kos">,</span> <span class="pl-k">async</span> <span class="pl-kos">(</span><span class="pl-kos">{</span> page <span class="pl-kos">}</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-c">// Intercept GET /api/items</span> <span class="pl-k">await</span> <span class="pl-s1">page</span><span class="pl-kos">.</span><span class="pl-en">route</span><span class="pl-kos">(</span><span class="pl-s">'/api/items'</span><span class="pl-kos">,</span> <span class="pl-s1">route</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">route</span><span class="pl-kos">.</span><span class="pl-en">fulfill</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">body</span>: <span class="pl-c1">JSON</span><span class="pl-kos">.</span><span class="pl-en">stringify</span><span class="pl-kos">(</span><span class="pl-kos">[</span><span class="pl-kos">{</span> <span class="pl-c1">id</span>: <span class="pl-c1">1</span><span class="pl-kos">,</span> <span class="pl-c1">name</span>: <span class="pl-s">'Item 1'</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-c">// Intercept POST /api/items</span> <span class="pl-k">await</span> <span class="pl-s1">page</span><span class="pl-kos">.</span><span class="pl-en">route</span><span class="pl-kos">(</span><span class="pl-s">'/api/items'</span><span class="pl-kos">,</span> <span class="pl-s1">route</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">route</span><span class="pl-kos">.</span><span class="pl-en">fulfill</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">body</span>: <span class="pl-c1">JSON</span><span class="pl-kos">.</span><span class="pl-en">stringify</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">id</span>: <span class="pl-c1">2</span><span class="pl-kos">,</span> <span class="pl-c1">name</span>: <span class="pl-s">'Item 2'</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">await</span> <span class="pl-s1">page</span><span class="pl-kos">.</span><span class="pl-en">goto</span><span class="pl-kos">(</span><span class="pl-s">'/items'</span><span class="pl-kos">)</span> <span class="pl-c">// expect "Item 1" to be in the list</span> <span class="pl-k">await</span> <span class="pl-s1">page</span><span class="pl-kos">.</span><span class="pl-en">click</span><span class="pl-kos">(</span><span class="pl-s">'role=button[name="New item"]'</span><span class="pl-kos">)</span> <span class="pl-c">// expect "Item 2" to be created in the list</span> <span class="pl-kos">}</span><span class="pl-kos">)</span></pre></div> <p dir="auto">The "matcher"(<code class="notranslate">url&lt;string|RegExp|function(URL):boolean&gt;</code>) doesn't allow for any matching on the request itself - only the request url.<br> The "response"(<code class="notranslate">handler&lt;function(Route, Request)&gt;</code>) doesn't allow us to "skip" to the next interceptor - as the comment says in the source code <code class="notranslate">// There is no chaining, first handler wins.</code>.</p> <h2 dir="auto">Existing workarounds</h2> <ol dir="auto"> <li>Add single interceptor with conditional handler:</li> </ol> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="await page.route('/api/items', (route, request) =&gt; { if (request.method() === 'GET') { return route.fulfill({ body: JSON.stringify([{ id: 1, name: 'Item 1' }]) }) } if (request.method() === 'POST') { return route.fulfill({ body: JSON.stringify({ id: 2, name: 'Item 2' }) } return route.continue() })"><pre class="notranslate"><span class="pl-k">await</span> <span class="pl-s1">page</span><span class="pl-kos">.</span><span class="pl-c1">route</span><span class="pl-kos">(</span><span class="pl-s">'/api/items'</span><span class="pl-kos">,</span> <span class="pl-kos">(</span><span class="pl-s1">route</span><span class="pl-kos">,</span> <span class="pl-s1">request</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-k">if</span> <span class="pl-kos">(</span><span class="pl-s1">request</span><span class="pl-kos">.</span><span class="pl-en">method</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">===</span> <span class="pl-s">'GET'</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">return</span> <span class="pl-s1">route</span><span class="pl-kos">.</span><span class="pl-en">fulfill</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">body</span>: <span class="pl-c1">JSON</span><span class="pl-kos">.</span><span class="pl-en">stringify</span><span class="pl-kos">(</span><span class="pl-kos">[</span><span class="pl-kos">{</span> <span class="pl-c1">id</span>: <span class="pl-c1">1</span><span class="pl-kos">,</span> <span class="pl-c1">name</span>: <span class="pl-s">'Item 1'</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">if</span> <span class="pl-kos">(</span><span class="pl-s1">request</span><span class="pl-kos">.</span><span class="pl-en">method</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">===</span> <span class="pl-s">'POST'</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">return</span> <span class="pl-s1">route</span><span class="pl-kos">.</span><span class="pl-en">fulfill</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">body</span>: <span class="pl-c1">JSON</span><span class="pl-kos">.</span><span class="pl-en">stringify</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">id</span>: <span class="pl-c1">2</span><span class="pl-kos">,</span> <span class="pl-c1">name</span>: <span class="pl-s">'Item 2'</span> <span class="pl-kos">}</span><span class="pl-kos">)</span> <span class="pl-kos">}</span> <span class="pl-s1">return</span> <span class="pl-s1">route</span><span class="pl-kos">.</span><span class="pl-en">continue</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">While this is enough in some cases, it's not very atomic and reusable. My idea is to make these a bit more generic and use them in fixtures - making sure that i can easily target just the request i need. Also, the idea of having the matching logic in the handler instead of the matcher just seems wrong.</p> <ol start="2" dir="auto"> <li>Use <code class="notranslate">options.times</code> and order the interceptors based on their runtime execution. This seems very fragile and really not ideal.</li> </ol> <h2 dir="auto">Proposal</h2> <p dir="auto">Even though the contribution guide says "Expose as little information as needed. When in doubt, don’t expose new information.", i feel like we should have an escape hatch in the "matcher" function. Two options:</p> <ul dir="auto"> <li>Non-breaking change: adding the request as a second parameter to the url function:<br> <code class="notranslate">url&lt;string|RegExp|function(URL, request):boolean&gt;</code><br> Not the best API but that's the price of non-breaking i guess.</li> <li>Breaking change: replacing the URL param with the request param in the url function:<br> <code class="notranslate">url&lt;string|RegExp|function(request):boolean&gt;</code><br> This seems like a very robust and flexible way of route matching but it does break BC.</li> </ul> <p dir="auto">It's a bit unfortunate that we can't reuse the standard glob/regex url matching when we use the function.<br> This is how i imagine it could look like:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="await page.route( (url, request) =&gt; request.method() === 'GET' &amp;&amp; minimatch('/api/items', url.toSting()), route =&gt; route.fulfill({ body: JSON.stringify([{ id: 1, name: 'Item 1' }]) }) ) await page.route( (url, request) =&gt; request.method() === 'POST' &amp;&amp; minimatch('/api/items', url.toSting()), route =&gt; route.fulfill({ body: JSON.stringify({ id: 2, name: 'Item 2' }) )"><pre class="notranslate"><span class="pl-k">await</span> <span class="pl-s1">page</span><span class="pl-kos">.</span><span class="pl-en">route</span><span class="pl-kos">(</span> <span class="pl-kos">(</span><span class="pl-s1">url</span><span class="pl-kos">,</span> <span class="pl-s1">request</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">request</span><span class="pl-kos">.</span><span class="pl-en">method</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">===</span> <span class="pl-s">'GET'</span> <span class="pl-c1">&amp;&amp;</span> <span class="pl-en">minimatch</span><span class="pl-kos">(</span><span class="pl-s">'/api/items'</span><span class="pl-kos">,</span> <span class="pl-s1">url</span><span class="pl-kos">.</span><span class="pl-en">toSting</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">route</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">route</span><span class="pl-kos">.</span><span class="pl-en">fulfill</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">body</span>: <span class="pl-c1">JSON</span><span class="pl-kos">.</span><span class="pl-en">stringify</span><span class="pl-kos">(</span><span class="pl-kos">[</span><span class="pl-kos">{</span> <span class="pl-c1">id</span>: <span class="pl-c1">1</span><span class="pl-kos">,</span> <span class="pl-c1">name</span>: <span class="pl-s">'Item 1'</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">await</span> <span class="pl-s1">page</span><span class="pl-kos">.</span><span class="pl-c1">route</span><span class="pl-kos">(</span> <span class="pl-kos">(</span><span class="pl-s1">url</span><span class="pl-kos">,</span> <span class="pl-s1">request</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">request</span><span class="pl-kos">.</span><span class="pl-en">method</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">===</span> <span class="pl-s">'POST'</span> <span class="pl-c1">&amp;&amp;</span> <span class="pl-en">minimatch</span><span class="pl-kos">(</span><span class="pl-s">'/api/items'</span><span class="pl-kos">,</span> <span class="pl-s1">url</span><span class="pl-kos">.</span><span class="pl-en">toSting</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">route</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">route</span><span class="pl-kos">.</span><span class="pl-c1">fulfill</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">body</span>: <span class="pl-c1">JSON</span><span class="pl-kos">.</span><span class="pl-en">stringify</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">id</span>: <span class="pl-c1">2</span><span class="pl-kos">,</span> <span class="pl-c1">name</span>: <span class="pl-s">'Item 2'</span> <span class="pl-kos">}</span><span class="pl-kos">)</span> <span class="pl-kos">)</span></pre></div> <p dir="auto">I think that having a convenient way to match by method(in addition to url) would be helpful in a lot of situations.<br> What do you guys think? Do you have other APIs in mind to achieve this or do you think the current workaround methods are good enough?</p>
<p dir="auto">I'm seeing weird, intermittent behaviors happen while running tests in the Webkit browser only, and only when it runs inside of the official Docker container... not on my Mac. It appears that some headers (like "Date" and "Expires") get broken into 2 pieces somehow, and then there's the occasional cancelling of requests. Please see the screenshots below.</p> <p dir="auto">Something to note: The <code class="notranslate">invalid HTTP headers</code> message in red shows next to a request that looks fine... It's the one above the message that looks janky, as you can see from the headers.</p> <p dir="auto">While I suspect a bug, I'm certainly open to the idea that I could be doing something the wrong way if these request/response "interruptions" can be clearly explained. I've definitely not found much online from a simple Google search.</p> <h3 dir="auto">System info</h3> <ul dir="auto"> <li>Playwright Version: v1.34.3</li> <li>Operating Systems: <ul dir="auto"> <li>Locally: MacOS Ventura (M1)</li> <li>In CI or local Docker: mcr.microsoft.com/playwright:v1.34.3-focal</li> </ul> </li> <li>Browser: Webkit</li> <li>Other info:</li> </ul> <h3 dir="auto">Source code</h3> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> I provided exact source code that allows reproducing the issue locally.</li> </ul> <p dir="auto"><strong>Link to the GitHub repository with the repro</strong><br> <em>Prioprietary</em></p> <p dir="auto">or</p> <p dir="auto"><strong>Config file</strong><br> <em>Proprietary</em></p> <p dir="auto"><strong>Test file (self-contained)</strong></p> <p dir="auto">I can't share the test, because it's proprietary, but I've seen the issue from my screenshot in <code class="notranslate">waitForRequest</code> and <code class="notranslate">waitForUrl</code>, when the parameter is a callback function. That may not have anything to do with it, but I don't know.</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" await test.step(`assert that a service request is made with a token`, async () =&gt; { const tokenedRequest = await page.waitForRequest( (request) =&gt; { const url = new URL(request.url()); const headers = request.headers(); return url.pathname.includes('/content/') &amp;&amp; /Bearer \S{16}/.test(headers?.authorization); }, { timeout: 30000, }, ); expect(tokenedRequest).toBeTruthy(); });"><pre class="notranslate"> <span class="pl-k">await</span> <span class="pl-s1">test</span><span class="pl-kos">.</span><span class="pl-en">step</span><span class="pl-kos">(</span><span class="pl-s">`assert that a service request is made with a token`</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">tokenedRequest</span> <span class="pl-c1">=</span> <span class="pl-k">await</span> <span class="pl-s1">page</span><span class="pl-kos">.</span><span class="pl-en">waitForRequest</span><span class="pl-kos">(</span> <span class="pl-kos">(</span><span class="pl-s1">request</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">url</span> <span class="pl-c1">=</span> <span class="pl-k">new</span> <span class="pl-c1">URL</span><span class="pl-kos">(</span><span class="pl-s1">request</span><span class="pl-kos">.</span><span class="pl-en">url</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">const</span> <span class="pl-s1">headers</span> <span class="pl-c1">=</span> <span class="pl-s1">request</span><span class="pl-kos">.</span><span class="pl-en">headers</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-s1">url</span><span class="pl-kos">.</span><span class="pl-c1">pathname</span><span class="pl-kos">.</span><span class="pl-en">includes</span><span class="pl-kos">(</span><span class="pl-s">'/content/'</span><span class="pl-kos">)</span> <span class="pl-c1">&amp;&amp;</span> <span class="pl-pds"><span class="pl-c1">/</span>Bearer <span class="pl-cce">\S</span><span class="pl-kos">{</span>16<span class="pl-kos">}</span><span class="pl-c1">/</span></span><span class="pl-kos">.</span><span class="pl-en">test</span><span class="pl-kos">(</span><span class="pl-s1">headers</span><span class="pl-kos">?.</span><span class="pl-c1">authorization</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-c1">timeout</span>: <span class="pl-c1">30000</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">expect</span><span class="pl-kos">(</span><span class="pl-s1">tokenedRequest</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">toBeTruthy</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>Steps</strong><br> <em>Proprietary</em></p> <p dir="auto"><strong>Expected</strong><br> I can't give too many details, as it's proprietary, but this is testing Azure/B2C OAuth.</p> <p dir="auto"><strong>Actual</strong></p> <p dir="auto">Sometimes does weird stuff to HTTP headers:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer" href="https://user-images.githubusercontent.com/77355440/244570452-c74c4aa5-8a93-4599-892b-b4032529439a.png"><img src="https://user-images.githubusercontent.com/77355440/244570452-c74c4aa5-8a93-4599-892b-b4032529439a.png" alt="image" style="max-width: 100%;"></a></p> <p dir="auto">Sometimes cancels requests:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer" href="https://user-images.githubusercontent.com/77355440/244570775-f9c5c3ad-f9eb-4f5a-b3c2-3baa31bbdaaf.png"><img src="https://user-images.githubusercontent.com/77355440/244570775-f9c5c3ad-f9eb-4f5a-b3c2-3baa31bbdaaf.png" alt="image" style="max-width: 100%;"></a></p>
0
<table role="table"> <thead> <tr> <th>Q</th> <th>A</th> </tr> </thead> <tbody> <tr> <td>Bug report?</td> <td>yes</td> </tr> <tr> <td>Feature request?</td> <td>no</td> </tr> <tr> <td>BC Break report?</td> <td>yes</td> </tr> <tr> <td>RFC?</td> <td>yes/no</td> </tr> <tr> <td>Symfony version</td> <td>2.8</td> </tr> </tbody> </table> <p dir="auto">There was recently a change to the UniqueEntity Validator: <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/symfony/doctrine-bridge/commit/40941a3/hovercard" href="https://github.com/symfony/doctrine-bridge/commit/40941a3">symfony/doctrine-bridge@<tt>40941a3</tt></a></p> <p dir="auto">This has changed it's behaviour. It used to "return" if any value was null. Now, it continues if a value is null.</p> <p dir="auto">This means that if you have 1 null value and 1 non null value, it only matches the criteria to the single value.</p> <p dir="auto">I think this is quite a big BC break. Would love to get some feedback on this change.</p> <p dir="auto">We now have validation that is failing when we use 2 fields (one has a value and the other is null). We need it to only validate if both are not null.</p>
<table role="table"> <thead> <tr> <th>Q</th> <th>A</th> </tr> </thead> <tbody> <tr> <td>Bug report?</td> <td>yes</td> </tr> <tr> <td>Feature request?</td> <td>no</td> </tr> <tr> <td>BC Break report?</td> <td>no</td> </tr> <tr> <td>RFC?</td> <td>no</td> </tr> <tr> <td>Symfony version</td> <td>2.8.17</td> </tr> </tbody> </table> <p dir="auto">Scenario: I'm validating an entity like this</p> <div class="highlight highlight-text-html-php notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="$validator-&gt;validate($device, [ new UniqueEntity([ 'fields' =&gt; ['accountId', 'tenantUuid'], 'em' =&gt; $provisioningEm ]) ]);"><pre class="notranslate"><span class="pl-s1"><span class="pl-c1">$</span>validator</span>-&gt;<span class="pl-en">validate</span>(<span class="pl-s1"><span class="pl-c1">$</span>device</span>, [ <span class="pl-k">new</span> <span class="pl-v">UniqueEntity</span>([ <span class="pl-s">'fields'</span> =&gt; [<span class="pl-s">'accountId'</span>, <span class="pl-s">'tenantUuid'</span>], <span class="pl-s">'em'</span> =&gt; <span class="pl-s1"><span class="pl-c1">$</span>provisioningEm</span> ]) ]);</pre></div> <p dir="auto">If <code class="notranslate">accountId</code> happens to be null, <a href="https://github.com/symfony/symfony/blob/2.8/src/Symfony/Bridge/Doctrine/Validator/Constraints/UniqueEntityValidator.php#L90-L94">UniqueEntityValidator</a> will now exclude it from the constraint list (since commit <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/symfony/symfony/commit/1e3421d6f03325ef805f5d11c714982b70d6c06f/hovercard" href="https://github.com/symfony/symfony/commit/1e3421d6f03325ef805f5d11c714982b70d6c06f"><tt>1e3421d</tt></a> ), failing <a href="https://github.com/symfony/symfony/blob/2.8/src/Symfony/Bridge/Doctrine/Validator/Constraints/UniqueEntityValidator.php#L136-L137">later on</a> because <code class="notranslate">$criteria[$fields[0]]</code> is an invalid array access: <code class="notranslate">fields[0]</code> is the string "accountId", which is not in <code class="notranslate">$criteria</code>.<br> Reverting lines 88-94 to the version before the commit linked above fixes the issue.</p>
1
<h1 dir="auto">Bug report</h1> <p dir="auto"><strong>What is the current behavior?</strong><br> Im using <a href="https://npmjs.com/package/wallpaper" rel="nofollow">Wallpaper</a><br> and I Get a node: urls error</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" App • ERROR • Renderer in node:util UnhandledSchemeError: Reading from &quot;node:util&quot; is not handled by plugins (Unhandled scheme) . Webpack supports &quot;data:&quot; and &quot;file:&quot; URIs by default. You may need an additional plugin to handle &quot;node:&quot; URIs."><pre class="notranslate"><code class="notranslate"> App • ERROR • Renderer in node:util UnhandledSchemeError: Reading from "node:util" is not handled by plugins (Unhandled scheme) . Webpack supports "data:" and "file:" URIs by default. You may need an additional plugin to handle "node:" URIs. </code></pre></div> <p dir="auto">This might be a duplicate, but i dont understand the other issues because they were'nt providing a clear solution<br> <strong>If the current behavior is a bug, please provide the steps to reproduce.</strong></p> <p dir="auto"><strong>What is the expected behavior?</strong></p> <p dir="auto"><strong>Other relevant information:</strong><br> webpack version: 5<br> Node.js version: 16.x.x<br> Operating System: MacOS<br> Additional tools: Quasar, VueJs</p>
<h2 dir="auto">Feature request</h2> <p dir="auto"><strong>What is the expected behavior?</strong><br> Ability to force bundling of a module</p> <p dir="auto"><strong>What is motivation or use case for adding/changing the behavior?</strong><br> It is impossible to dynamically import a module using import(moduleName) with moduleName being a variable</p> <p dir="auto"><strong>How should this be implemented in your opinion?</strong><br> In settings, there should be an array of bundled modules, the modules within it will be bundled even if they're not required in the project itself</p> <p dir="auto"><strong>Are you willing to work on this yourself?</strong><br> no</p>
0
<p dir="auto">See </p><div class="Box Box--condensed my-2"> <div class="Box-header f6"> <p class="mb-0 text-bold"> <a href="https://github.com/flutter/flutter/blob/befe01989610e4e231ca1c9095fcdb7a027ede84/packages/flutter_tools/lib/src/commands/analyze_once.dart#L93">flutter/packages/flutter_tools/lib/src/commands/analyze_once.dart</a> </p> <p class="mb-0 color-fg-muted"> Line 93 in <a data-pjax="true" class="commit-tease-sha" href="/flutter/flutter/commit/befe01989610e4e231ca1c9095fcdb7a027ede84">befe019</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="L93" class="blob-num border-0 px-3 py-0 color-bg-default" data-line-number="93"></td> <td id="LC93" class="blob-code border-0 px-3 py-0 color-bg-default blob-code-inner js-file-line"> <span class="pl-c">// De-duplicate the dartanalyzer command output (https://github.com/dart-lang/sdk/issues/25697).</span> </td> </tr> </tbody></table> </div> </div> <p></p> <p dir="auto"><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="131529473" data-permission-text="Title is private" data-url="https://github.com/dart-lang/sdk/issues/25697" data-hovercard-type="issue" data-hovercard-url="/dart-lang/sdk/issues/25697/hovercard" href="https://github.com/dart-lang/sdk/issues/25697">dart-lang/sdk#25697</a> was fixed at <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/dart-lang/sdk/commit/eae2bf27470ff5c52c52647b27db224feb4f68d5/hovercard" href="https://github.com/dart-lang/sdk/commit/eae2bf27470ff5c52c52647b27db224feb4f68d5">dart-lang/sdk@<tt>eae2bf2</tt></a></p> <p dir="auto">Now you can replace <code class="notranslate">issues</code> with an <code class="notranslate">int</code>. Nice!</p>
<h2 dir="auto">Steps to Reproduce</h2> <p dir="auto"><code class="notranslate">Flutter create</code> a new project. Set the <code class="notranslate">Team</code> in Xcode and run the project from Xcode on a connected device. This results in : <code class="notranslate">Thread 1: signal SIGPIPE</code> . It is possible to make the app run by pressing the <code class="notranslate">Continue program execution</code> button in the debug area about 3 times.</p>
0
<h4 dir="auto">Code Sample, a copy-pastable example if possible</h4> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="from io import StringIO df = pd.read_csv(StringIO('''Date,A\n8/23/2017,a\n8/22/2017,b\n8/24/2017,c'''), parse_dates=['Date']) print(df) print(type(pd.datetime(2017, 8, 22).date())) print(type(df['Date'][1])) df_sub = df[df['Date'] == pd.datetime(2017, 8, 22).date()] "><pre class="notranslate"><code class="notranslate">from io import StringIO df = pd.read_csv(StringIO('''Date,A\n8/23/2017,a\n8/22/2017,b\n8/24/2017,c'''), parse_dates=['Date']) print(df) print(type(pd.datetime(2017, 8, 22).date())) print(type(df['Date'][1])) df_sub = df[df['Date'] == pd.datetime(2017, 8, 22).date()] </code></pre></div> <h4 dir="auto">Error returned</h4> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Traceback (most recent call last): File &quot;&lt;pyshell#72&gt;&quot;, line 1, in &lt;module&gt; df_sub = df[df['Date'] == pd.datetime(2017, 8, 22).date()] File &quot;C:\Python35\lib\site-packages\pandas\core\ops.py&quot;, line 877, in wrapper res = na_op(values, other) File &quot;C:\Python35\lib\site-packages\pandas\core\ops.py&quot;, line 806, in na_op y = libindex.convert_scalar(x, _values_from_object(y)) File &quot;pandas\_libs\index.pyx&quot;, line 494, in pandas._libs.index.convert_scalar File &quot;pandas\_libs\index.pyx&quot;, line 509, in pandas._libs.index.convert_scalar ValueError: cannot set a Timestamp with a non-timestamp"><pre class="notranslate"><code class="notranslate">Traceback (most recent call last): File "&lt;pyshell#72&gt;", line 1, in &lt;module&gt; df_sub = df[df['Date'] == pd.datetime(2017, 8, 22).date()] File "C:\Python35\lib\site-packages\pandas\core\ops.py", line 877, in wrapper res = na_op(values, other) File "C:\Python35\lib\site-packages\pandas\core\ops.py", line 806, in na_op y = libindex.convert_scalar(x, _values_from_object(y)) File "pandas\_libs\index.pyx", line 494, in pandas._libs.index.convert_scalar File "pandas\_libs\index.pyx", line 509, in pandas._libs.index.convert_scalar ValueError: cannot set a Timestamp with a non-timestamp </code></pre></div> <h4 dir="auto">Problem description</h4> <p dir="auto">I just upgraded to pandas version '0.21.0rc1'. The <code class="notranslate">df_sub</code> line above used to work in a prior version. Should a <code class="notranslate">Timestamp</code> and a <code class="notranslate">datetime.date</code> be comparable like it used to in a previous version? Not a huge issue for me but my intent is to just report it in-case it requires attention.</p> <h4 dir="auto">Expected Output</h4> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" Date A 1 2017-08-22 b"><pre class="notranslate"><code class="notranslate"> Date A 1 2017-08-22 b </code></pre></div> <h4 dir="auto">Helpful Links</h4> <p dir="auto">May be a similar or related issue: <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="268127467" data-permission-text="Title is private" data-url="https://github.com/pandas-dev/pandas/issues/17965" data-hovercard-type="issue" data-hovercard-url="/pandas-dev/pandas/issues/17965/hovercard" href="https://github.com/pandas-dev/pandas/issues/17965">#17965</a><br> <code class="notranslate">convert_scalar</code> location: <a href="https://github.com/pandas-dev/pandas/blob/master/pandas/_libs/index.pyx#L494">https://github.com/pandas-dev/pandas/blob/master/pandas/_libs/index.pyx#L494</a></p> <h4 dir="auto">Output of <code class="notranslate">pd.show_versions()</code></h4> <details> <h2 dir="auto">[paste the output of <code class="notranslate">pd.show_versions()</code> here below this line]<br> INSTALLED VERSIONS</h2> <p dir="auto">commit: None<br> python: 3.5.2.final.0<br> python-bits: 64<br> OS: Windows<br> OS-release: 7<br> machine: AMD64<br> processor: Intel64 Family 6 Model 42 Stepping 7, GenuineIntel<br> byteorder: little<br> LC_ALL: None<br> LANG: None<br> LOCALE: English_United States.1252</p> <p dir="auto">pandas: 0.21.0rc1<br> pytest: None<br> pip: 9.0.1<br> setuptools: 20.10.1<br> Cython: 0.25.2<br> numpy: 1.13.3<br> scipy: 0.19.1<br> pyarrow: None<br> xarray: None<br> IPython: 5.2.2<br> sphinx: None<br> patsy: 0.4.1<br> dateutil: 2.6.1<br> pytz: 2017.2<br> blosc: None<br> bottleneck: None<br> tables: 3.3.0<br> numexpr: 2.6.2<br> feather: None<br> matplotlib: 2.0.0rc2<br> openpyxl: None<br> xlrd: 1.0.0<br> xlwt: None<br> xlsxwriter: 0.9.6<br> lxml: None<br> bs4: 4.5.3<br> html5lib: 0.9999999<br> sqlalchemy: 1.1.11<br> pymysql: None<br> psycopg2: None<br> jinja2: 2.9.5<br> s3fs: None<br> fastparquet: None<br> pandas_gbq: None<br> pandas_datareader: None</p> </details>
<p dir="auto">This should probably work</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="In [16]: df = pd.DataFrame({'A':[pd.Timestamp('20130101'), np.nan]}) In [17]: df Out[17]: A 0 2013-01-01 1 NaT In [18]: pd.Timestamp('20130101').to_pydatetime()&gt;=df.A Out[18]: 0 True 1 False Name: A, dtype: bool In [20]: pd.Timestamp('20130101').to_pydatetime().date()&gt;=df.A ValueError: cannot set a Timestamp with a non-timestamp"><pre class="notranslate"><code class="notranslate">In [16]: df = pd.DataFrame({'A':[pd.Timestamp('20130101'), np.nan]}) In [17]: df Out[17]: A 0 2013-01-01 1 NaT In [18]: pd.Timestamp('20130101').to_pydatetime()&gt;=df.A Out[18]: 0 True 1 False Name: A, dtype: bool In [20]: pd.Timestamp('20130101').to_pydatetime().date()&gt;=df.A ValueError: cannot set a Timestamp with a non-timestamp </code></pre></div>
1
<p dir="auto">I found the 2 semi colons on the screen during the on going html &amp; css and bootstrap series in the front end course.</p> <p dir="auto">I have randomly selected the below 2 waypoint links and the screenshots for the reference:-</p> <p dir="auto">1 - <a href="http://www.freecodecamp.com/challenges/waypoint-house-our-page-within-a-bootstrap-container-fluid-div" rel="nofollow">http://www.freecodecamp.com/challenges/waypoint-house-our-page-within-a-bootstrap-container-fluid-div</a></p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/9387490/12221369/3b477406-b7be-11e5-8f36-a369d53e88d8.jpg"><img src="https://cloud.githubusercontent.com/assets/9387490/12221369/3b477406-b7be-11e5-8f36-a369d53e88d8.jpg" alt="q1" style="max-width: 100%;"></a></p> <p dir="auto">2- <a href="http://www.freecodecamp.com/challenges/waypoint-add-borders-around-your-elements" rel="nofollow">http://www.freecodecamp.com/challenges/waypoint-add-borders-around-your-elements</a></p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/9387490/12221370/4a6129b4-b7be-11e5-80d9-d2b4753d3d8b.jpg"><img src="https://cloud.githubusercontent.com/assets/9387490/12221370/4a6129b4-b7be-11e5-80d9-d2b4753d3d8b.jpg" alt="q2" style="max-width: 100%;"></a></p> <p dir="auto">Wondering about these semi colons. Of course, they aren't any obstacles during the course. Thought it might a confusion for a newbie.</p>
<p dir="auto">Two semicolons at the top and bottom of the phone screen.<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/15240972/12204095/26bfea82-b600-11e5-85f9-82bcf5848499.png"><img src="https://cloud.githubusercontent.com/assets/15240972/12204095/26bfea82-b600-11e5-85f9-82bcf5848499.png" alt="screen shot 2016-01-08 at 12 05 11 pm" style="max-width: 100%;"></a></p>
1
<h2 dir="auto">Bug Report</h2> <p dir="auto"><strong>Current Behavior</strong><br> Unhandled promise rejection TypeError:traget is not iterable!</p> <p dir="auto"><strong>Input Code</strong></p> <p dir="auto"><strong>Expected behavior/code</strong></p> <p dir="auto"><strong>Environment</strong></p> <ul dir="auto"> <li>Babel version(s): 7.4.5</li> </ul> <p dir="auto"><strong>Possible Solution</strong></p> <p dir="auto"><strong>Additional context/Screenshots</strong></p> <p dir="auto"><strong>other</strong><br> I have seen the same problem <a href="https://github.com/babel/babel/issues/7395" data-hovercard-type="issue" data-hovercard-url="/babel/babel/issues/7395/hovercard">7395</a><br> and the pr <a href="https://github.com/babel/babel/pull/7400" data-hovercard-type="pull_request" data-hovercard-url="/babel/babel/pull/7400/hovercard">7400</a></p> <p dir="auto">but it didn't solve the problem.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/25626094/60332069-95f6d000-99c8-11e9-9779-9819f81d7ef9.png"><img src="https://user-images.githubusercontent.com/25626094/60332069-95f6d000-99c8-11e9-9779-9819f81d7ef9.png" alt="image" style="max-width: 100%;"></a><br> I build my project with webpack ,i fix it as the picture show</p> <p dir="auto"><a href="https://github.com/babel/babel/issues/9872#thread-subscription-status" data-hovercard-type="issue" data-hovercard-url="/babel/babel/issues/9872/hovercard">9872</a></p>
<h2 dir="auto">Bug Report</h2> <p dir="auto"><strong>Current Behavior</strong><br> Dynamic imports are not working in IE10. The following error is shown in the console: "Unhandled promise rejectionTypeError: Target is not iterable". @babel/preset-env is used with core-js@3. <code class="notranslate">.browserslistrc</code> contains <code class="notranslate">ie &lt;= 10</code>.</p> <p dir="auto"><strong>Input Code</strong><br> <a href="https://github.com/jorenvanhee/dynamic-imports-with-preset-env-test">https://github.com/jorenvanhee/dynamic-imports-with-preset-env-test</a></p> <p dir="auto">Run <code class="notranslate">npm i &amp;&amp; npm run build</code> and visit <code class="notranslate">/index.html</code> in IE10.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import('./answer').then((module) =&gt; { console.log(module.default); });"><pre class="notranslate"><code class="notranslate">import('./answer').then((module) =&gt; { console.log(module.default); }); </code></pre></div> <p dir="auto"><strong>Expected behavior/code</strong><br> <code class="notranslate">42</code> should be logged in the console.</p> <p dir="auto"><strong>Babel Configuration (.babelrc, package.json, cli command)</strong></p> <p dir="auto"><a href="https://github.com/jorenvanhee/dynamic-imports-with-preset-env-test">https://github.com/jorenvanhee/dynamic-imports-with-preset-env-test</a></p> <p dir="auto"><strong>Environment</strong></p> <ul dir="auto"> <li>Babel version(s): 7.4.3</li> <li>Node/npm version: Node 10.15.1/npm 6.5</li> <li>How you are using Babel: loader</li> </ul> <p dir="auto"><strong>Additional context/Screenshots</strong></p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/231202/56349093-24c8be80-61c8-11e9-9559-598d452cdcc7.png"><img src="https://user-images.githubusercontent.com/231202/56349093-24c8be80-61c8-11e9-9559-598d452cdcc7.png" alt="Screenshot 2019-04-16 at 17 08 48" style="max-width: 100%;"></a></p>
1
<p dir="auto"><a href="http://doc.rust-lang.org/nightly/std/primitive.f32.html" rel="nofollow"><code class="notranslate">std::f32</code></a> doc page has <code class="notranslate">impl Float for f32</code> at the top and at the bottom.</p> <ul dir="auto"> <li>The bottom one seems to have more elements though it's not clear why.</li> <li>Their styling is the same so it's not obvious if they should mean 2 different things.</li> </ul> <p dir="auto">Something should change so either they don't look like misshapen clones or it's clear what they mean.</p>
<p dir="auto">Here's an example I just got:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="src/anthill/execution/kind.rs:124:32: 125:29 error: cannot infer an appropriate lifetime due to conflicting requirements src/anthill/execution/kind.rs:124 dictionary.name_to_kind.find(&amp;name) src/anthill/execution/kind.rs:125 }; src/anthill/execution/kind.rs:124:32: 124:55 note: first, the lifetime cannot outlive the expression at 124:32... src/anthill/execution/kind.rs:124 dictionary.name_to_kind.find(&amp;name) ^~~~~~~~~~~~~~~~~~~~~~~ src/anthill/execution/kind.rs:124:32: 124:55 note: ...due to the following expression src/anthill/execution/kind.rs:124 dictionary.name_to_kind.find(&amp;name) ^~~~~~~~~~~~~~~~~~~~~~~ src/anthill/execution/kind.rs:124:32: 125:29 note: but, the lifetime must be valid for the method call at 124:32... src/anthill/execution/kind.rs:124 dictionary.name_to_kind.find(&amp;name) src/anthill/execution/kind.rs:125 }; src/anthill/execution/kind.rs:124:32: 124:55 note: ...due to the following expression src/anthill/execution/kind.rs:124 dictionary.name_to_kind.find(&amp;name) ^~~~~~~~~~~~~~~~~~~~~~~"><pre class="notranslate"><code class="notranslate">src/anthill/execution/kind.rs:124:32: 125:29 error: cannot infer an appropriate lifetime due to conflicting requirements src/anthill/execution/kind.rs:124 dictionary.name_to_kind.find(&amp;name) src/anthill/execution/kind.rs:125 }; src/anthill/execution/kind.rs:124:32: 124:55 note: first, the lifetime cannot outlive the expression at 124:32... src/anthill/execution/kind.rs:124 dictionary.name_to_kind.find(&amp;name) ^~~~~~~~~~~~~~~~~~~~~~~ src/anthill/execution/kind.rs:124:32: 124:55 note: ...due to the following expression src/anthill/execution/kind.rs:124 dictionary.name_to_kind.find(&amp;name) ^~~~~~~~~~~~~~~~~~~~~~~ src/anthill/execution/kind.rs:124:32: 125:29 note: but, the lifetime must be valid for the method call at 124:32... src/anthill/execution/kind.rs:124 dictionary.name_to_kind.find(&amp;name) src/anthill/execution/kind.rs:125 }; src/anthill/execution/kind.rs:124:32: 124:55 note: ...due to the following expression src/anthill/execution/kind.rs:124 dictionary.name_to_kind.find(&amp;name) ^~~~~~~~~~~~~~~~~~~~~~~ </code></pre></div> <p dir="auto">Now, I'm developing some experience with lifetimes so I have some intuition about what I did wrong. And I appreciate the effort that went into this error message! But still, saying "the lifetime can't outlive the expression X in location Y because it must be valid at the function call at exactly the same expression X in the same location Y" - that's not exactly explaining things in a way that is understandable to a newcomer (which I still am).</p> <p dir="auto">Perhaps there's a better way to phrase the problem, and possibly eliminate the duplications?</p>
0
<p dir="auto">Add Font Awesome Icons to all of our Buttons</p> <p dir="auto"><a href="https://www.freecodecamp.com/challenges/add-font-awesome-icons-to-all-of-our-buttons" rel="nofollow">https://www.freecodecamp.com/challenges/add-font-awesome-icons-to-all-of-our-buttons</a></p> <h4 dir="auto">Issue Description</h4> <p dir="auto">In this challenge as you know the buttons for Like, Info and Delete you add cool icons to the end of the text in each button. I am wondering why for the trashcan on the delete button it goes off the previewer page and thus you cannot see it. Makes it look not clean is this a bug or could there be something I am missing about how the .col-xs-4 work?</p> <h4 dir="auto">Browser Information</h4> <ul dir="auto"> <li>Browser Name, Version: Chrome</li> <li>Operating System: Windows 10</li> <li>Mobile, Desktop, or Tablet: Desktop</li> </ul> <h4 dir="auto">Your Code</h4> <div class="highlight highlight-text-html-basic notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&lt;div class=&quot;row&quot;&gt; &lt;div class=&quot;col-xs-4&quot;&gt; &lt;button class=&quot;btn btn-block btn-primary&quot;&gt;&lt;i class=&quot;fa fa-thumbs-up&quot;&gt;&lt;/i&gt; Like&lt;/button&gt; &lt;/div&gt; &lt;div class=&quot;col-xs-4&quot;&gt; &lt;button class=&quot;btn btn-block btn-info&quot;&gt;Info&lt;i class=&quot;fa fa-info-circle&quot;&gt;&lt;/i&gt;&lt;/button&gt; &lt;/div&gt; &lt;div class=&quot;col-xs-4&quot;&gt; &lt;button class=&quot;btn btn-block btn-danger&quot;&gt;Delete&lt;i class=&quot;fa fa-trash&quot;&gt;&lt;/i&gt;&lt;/button&gt; &lt;/div&gt; &lt;/div&gt; "><pre class="notranslate"><span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">row</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">col-xs-4</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-block btn-primary</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">fa fa-thumbs-up</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> Like<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">col-xs-4</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-block btn-info</span>"<span class="pl-kos">&gt;</span>Info<span class="pl-kos">&lt;</span><span class="pl-ent">i</span> <span class="pl-c1">class</span>="<span class="pl-s">fa fa-info-circle</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">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">col-xs-4</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-block btn-danger</span>"<span class="pl-kos">&gt;</span>Delete<span class="pl-kos">&lt;</span><span class="pl-ent">i</span> <span class="pl-c1">class</span>="<span class="pl-s">fa fa-trash</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">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span></pre></div> <h4 dir="auto">Screenshot</h4> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/20713384/18476038/8e32a1e6-7996-11e6-906f-687945604f78.png"><img src="https://cloud.githubusercontent.com/assets/20713384/18476038/8e32a1e6-7996-11e6-906f-687945604f78.png" alt="image" style="max-width: 100%;"></a></p>
<p dir="auto">Forewarning, this <em>may</em> be bike-shedding worthy....</p> <h3 dir="auto">Workspace</h3> <p dir="auto">User Agent is: <code class="notranslate">Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/49.0.2623.110 Safari/537.36</code>. (Chrome on Windows 7)</p> <h3 dir="auto">Setting</h3> <p dir="auto">The CatPhoto is where you make an web page and one component is adding three buttons like below.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/2754821/14199337/7156ec7e-f798-11e5-864c-49dd8c334c40.png"><img src="https://cloud.githubusercontent.com/assets/2754821/14199337/7156ec7e-f798-11e5-864c-49dd8c334c40.png" alt="image" style="max-width: 100%;"></a></p> <h3 dir="auto">Problem</h3> <p dir="auto">But then you will eventually make it into something like this below.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/2754821/14199333/641738c0-f798-11e5-9464-43c6de465704.png"><img src="https://cloud.githubusercontent.com/assets/2754821/14199333/641738c0-f798-11e5-9464-43c6de465704.png" alt="image" style="max-width: 100%;"></a></p> <p dir="auto">Notice that the red Delete button is squished and on the side (this is mostly a desktop problem; mobile user won't have the same issue -- see below)</p> <h4 dir="auto">Mobile Version</h4> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/2754821/14199436/364c3a70-f799-11e5-98af-7dbe7da0fbb1.png"><img src="https://cloud.githubusercontent.com/assets/2754821/14199436/364c3a70-f799-11e5-98af-7dbe7da0fbb1.png" alt="image" style="max-width: 100%;"></a></p> <h3 dir="auto">Solution</h3> <p dir="auto">So I propose two things:</p> <ul dir="auto"> <li>Change the "Delete" button into a "Edit" button so it'll fit on the button better. <ul dir="auto"> <li>This is fairly easy. You'll just need to change this in the challenge seeds starting with the challenge <a href="https://www.freecodecamp.com/challenges/warn-your-users-of-a-dangerous-action" rel="nofollow">Warn your Users of a Dangerous Action</a> where the button is added.</li> <li>Then change the challenges up until the last one on <a href="https://www.freecodecamp.com/challenges/line-up-form-elements-responsively-with-bootstrap" rel="nofollow">Line up Form Elements Responsively with Bootstrap</a>.</li> <li>You could also change the icon if appropriate.</li> </ul> </li> <li>Add new challenge to add in making all three of those buttons also have the class <code class="notranslate">btn-sm</code> to make the text inside the button not seem all smushed. <ul dir="auto"> <li>This one will require a little more effort in making an entirely new challenge, which may be unnecessary.</li> </ul> </li> </ul> <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;button class=&quot;btn btn-block btn-info btn-sm&quot;&gt;&lt;i class=&quot;fa fa-info-circle&quot;&gt;&lt;/i&gt; Info&lt;/button&gt;"><pre class="notranslate"><span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-block btn-info btn-sm</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">fa fa-info-circle</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> Info<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span></pre></div> <p dir="auto">If the proposed changes were made, the finished app will look like this:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/2754821/14199509/e3e483d6-f799-11e5-8983-b02a50d68da7.png"><img src="https://cloud.githubusercontent.com/assets/2754821/14199509/e3e483d6-f799-11e5-8983-b02a50d68da7.png" alt="image" style="max-width: 100%;"></a></p>
1
<p dir="auto">by <strong>limit.usus</strong>:</p> <pre class="notranslate">What steps will reproduce the problem? 1.run make.bash 2.run run.bash 3. What is the expected output? What do you see instead? I expected all tests will be passed but caught error. Error occurs while running test program: % ./run.bash -snip- make[1]: Entering directory `/home/limit/hg/go/src/pkg/net' gotest make[2]: Entering directory `/home/limit/hg/go/src/pkg/net' rm -f _test/net.a _gotest_.6 make[2]: Leaving directory `/home/limit/hg/go/src/pkg/net' make[2]: Entering directory `/home/limit/hg/go/src/pkg/net' 6g -o _gotest_.6 dnsclient.go dnsconfig.go dnsmsg.go fd.go fd_linux.go ip.go ipsock.go net.go parse.go port.go sock.go tcpsock.go udpsock.go unixsock.go dialgoogle_test.go ip_test.go net_test.go parse_test.go port_test.go server_test.go timeout_test.go rm -f _test/net.a gopack grc _test/net.a _gotest_.6 make[2]: Leaving directory `/home/limit/hg/go/src/pkg/net' throw: index out of range panic PC=0x2ba316c10d38 throw+0x3e /home/limit/hg/go/src/pkg/runtime/runtime.c:74 throw(0x47f060, 0x0) runtime·throwindex+0x1c /home/limit/hg/go/src/pkg/runtime/runtime.c:47 runtime·throwindex() net·hostPortToIP+0x19a /home/limit/hg/go/src/pkg/net/ipsock.go:199 net·hostPortToIP(0x446170, 0x0, 0x3, 0x0, 0x464280, ...) net·ResolveTCPAddr+0x34 /home/limit/hg/go/src/pkg/net/tcpsock.go:61 net·ResolveTCPAddr(0x464280, 0x0, 0xf, 0x0, 0x4462f0, ...) net·Dial+0x2a3 /home/limit/hg/go/src/pkg/net/net.go:133 net·Dial(0x446170, 0x0, 0x3, 0x0, 0x4462f0, ...) net·TestDialError+0xbc /home/limit/hg/go/src/pkg/net/net_test.go:56 net·TestDialError(0x16c5dd20, 0x2ba3) testing·tRunner+0x22 /home/limit/hg/go/src/pkg/testing/testing.go:105 testing·tRunner(0x16c5dd20, 0x2ba3, 0x494a28, 0x0) goexit /home/limit/hg/go/src/pkg/runtime/proc.c:134 goexit() 0x2ba316c5dd20 unknown pc goroutine 3: runtime·entersyscall+0x50 /home/limit/hg/go/src/pkg/runtime/proc.c:539 runtime·entersyscall() syscall·Syscall6+0x5 /home/limit/hg/go/src/pkg/syscall/asm_linux_amd64.s:41 syscall·Syscall6() syscall·EpollWait+0x84 /home/limit/hg/go/src/pkg/syscall/zsyscall_linux_amd64.go:132 syscall·EpollWait(0x6, 0x2ba3, 0x16c2f120, 0x2ba3, 0x1, ...) net·*pollster·WaitFD+0xb5 /home/limit/hg/go/src/pkg/net/fd_linux.go:116 net·*pollster·WaitFD(0x16c09cb0, 0x2ba3, 0x399ca458, 0x0, 0x72, ...) net·*pollServer·Run+0x9e /home/limit/hg/go/src/pkg/net/fd.go:237 net·*pollServer·Run(0x16bcb5c0, 0x2ba3) goexit /home/limit/hg/go/src/pkg/runtime/proc.c:134 goexit() 0x2ba316bcb5c0 unknown pc goroutine 1: gosched+0x34 /home/limit/hg/go/src/pkg/runtime/proc.c:515 gosched() chanrecv+0x318 /home/limit/hg/go/src/pkg/runtime/chan.c:319 chanrecv(0x16c61c80, 0x2ba3, 0x16c0ff68, 0x2ba3, 0x0, ...) runtime·chanrecv1+0x50 /home/limit/hg/go/src/pkg/runtime/chan.c:415 runtime·chanrecv1(0x16c61c80, 0x2ba3) testing·Main+0x263 /home/limit/hg/go/src/pkg/testing/testing.go:132 testing·Main(0x4949f8, 0x0) main·main+0x23 /home/limit/hg/go/src/pkg/net/_testmain.go:21 main·main() mainstart+0xf /home/limit/hg/go/src/pkg/runtime/amd64/asm.s:55 mainstart() goexit /home/limit/hg/go/src/pkg/runtime/proc.c:134 goexit() make[1]: *** [test] Error 2 make[1]: Leaving directory `/home/limit/hg/go/src/pkg/net' make: *** [net.test] Error 2 What is your $GOOS? $GOARCH? % echo $GOARCH amd64 % echo $GOOS linux Which revision are you sync'ed to? (hg log -l 1) % hg log -l 1 changeset: 3952:64e703cb307d tag: tip user: Russ Cox &lt;[email protected]&gt; date: Tue Nov 10 14:09:01 2009 -0800 summary: update video links Please provide any additional information below.</pre>
<p dir="auto">by <strong>yangchunxu</strong>:</p> <pre class="notranslate">Hi, as package doc say: the time.Now() shall return local current time,but actually,the first call return GMT time, 2nd call return local time, t := time.Now() t.Hour() //will return GMT time t.Hour() //will return local time tested under window XP, go1 Before filing a bug, please check whether it has been fixed since the latest release. Search the issue tracker and check that you're running the latest version of Go: Run "go version" and compare against <a href="http://golang.org/doc/devel/release.html" rel="nofollow">http://golang.org/doc/devel/release.html</a> If a newer version of Go exists, install it and retry what you did to reproduce the problem. Thanks. What steps will reproduce the problem? If possible, include a link to a program on play.golang.org. 1. 2. 3. What is the expected output? What do you see instead? Which compiler are you using (5g, 6g, 8g, gccgo)? Which operating system are you using? Which version are you using? (run 'go version') Please provide any additional information below.</pre>
0
<ul dir="auto"> <li>VSCode Version: 1.1.1</li> <li>OS Version: Windows 10</li> </ul> <p dir="auto">Steps to Reproduce:</p> <ol dir="auto"> <li>launch a command line with admin privileges</li> <li>from this command line, type "code .". Observe VS Code open</li> <li>Launch a command line without admin privileges</li> <li>from this command line, type "code .".<br> Expected:<br> VS Code opens in a new window</li> </ol> <p dir="auto">Actual:<br> Nothing, no error message, no indication of anything.</p>
<ul dir="auto"> <li>VSCode Version: 1.1.1</li> <li>OS Version: Windows 10 1511 (10586.318)</li> </ul> <p dir="auto">Steps to Reproduce:</p> <ol dir="auto"> <li>Close all Code instances, then run Code as administrator (a new blank Code instance with administrator right)</li> <li>In File Explorer, right click a text file and Open with Code, nothing will happen.</li> </ol> <p dir="auto">Note: there are multiple other ways to trigger this issue, the above repro is just an example.<br> Note 2: If you already have a code instance running without administrator running, the above issue will not get triggered. That's why the very first step is to close all Code instances.</p>
1
<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="from dataclasses import dataclass, field from typing import List, Optional from fastapi import FastAPI @dataclass class Item: name: str price: float tags: List[str] = field(default_factory=list) description: Optional[str] = None tax: Optional[float] = None app = FastAPI() @app.post(&quot;/items/next&quot;, response_model=Item) async def read_next_item(item: Item): return {}"><pre class="notranslate"><span class="pl-k">from</span> <span class="pl-s1">dataclasses</span> <span class="pl-k">import</span> <span class="pl-s1">dataclass</span>, <span class="pl-s1">field</span> <span class="pl-k">from</span> <span class="pl-s1">typing</span> <span class="pl-k">import</span> <span class="pl-v">List</span>, <span class="pl-v">Optional</span> <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-en">@<span class="pl-s1">dataclass</span></span> <span class="pl-k">class</span> <span class="pl-v">Item</span>: <span class="pl-s1">name</span>: <span class="pl-s1">str</span> <span class="pl-s1">price</span>: <span class="pl-s1">float</span> <span class="pl-s1">tags</span>: <span class="pl-v">List</span>[<span class="pl-s1">str</span>] <span class="pl-c1">=</span> <span class="pl-en">field</span>(<span class="pl-s1">default_factory</span><span class="pl-c1">=</span><span class="pl-s1">list</span>) <span class="pl-s1">description</span>: <span class="pl-v">Optional</span>[<span class="pl-s1">str</span>] <span class="pl-c1">=</span> <span class="pl-c1">None</span> <span class="pl-s1">tax</span>: <span class="pl-v">Optional</span>[<span class="pl-s1">float</span>] <span class="pl-c1">=</span> <span class="pl-c1">None</span> <span class="pl-s1">app</span> <span class="pl-c1">=</span> <span class="pl-v">FastAPI</span>() <span class="pl-en">@<span class="pl-s1">app</span>.<span class="pl-en">post</span>(<span class="pl-s">"/items/next"</span>, <span class="pl-s1">response_model</span><span class="pl-c1">=</span><span class="pl-v">Item</span>)</span> <span class="pl-k">async</span> <span class="pl-k">def</span> <span class="pl-en">read_next_item</span>(<span class="pl-s1">item</span>: <span class="pl-v">Item</span>): <span class="pl-k">return</span> {}</pre></div> <h3 dir="auto">Description</h3> <ul dir="auto"> <li>Visit swagger docs <code class="notranslate">/docs</code></li> <li>Get error <code class="notranslate">Failed to load API definition.</code></li> </ul> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Traceback (most recent call last): File &quot;/.../.venv/lib/python3.9/site-packages/uvicorn/protocols/http/httptools_impl.py&quot;, line 398, in run_asgi result = await app(self.scope, self.receive, self.send) File &quot;/.../.venv/lib/python3.9/site-packages/uvicorn/middleware/proxy_headers.py&quot;, line 45, in __call__ return await self.app(scope, receive, send) File &quot;/.../.venv/lib/python3.9/site-packages/fastapi/applications.py&quot;, line 199, in __call__ await super().__call__(scope, receive, send) File &quot;/.../.venv/lib/python3.9/site-packages/starlette/applications.py&quot;, line 112, in __call__ await self.middleware_stack(scope, receive, send) File &quot;/.../.venv/lib/python3.9/site-packages/starlette/middleware/errors.py&quot;, line 181, in __call__ raise exc from None File &quot;/.../.venv/lib/python3.9/site-packages/starlette/middleware/errors.py&quot;, line 159, in __call__ await self.app(scope, receive, _send) File &quot;/.../.venv/lib/python3.9/site-packages/starlette/exceptions.py&quot;, line 82, in __call__ raise exc from None File &quot;/.../.venv/lib/python3.9/site-packages/starlette/exceptions.py&quot;, line 71, in __call__ await self.app(scope, receive, sender) File &quot;/.../.venv/lib/python3.9/site-packages/starlette/routing.py&quot;, line 580, in __call__ await route.handle(scope, receive, send) File &quot;/.../.venv/lib/python3.9/site-packages/starlette/routing.py&quot;, line 241, in handle await self.app(scope, receive, send) File &quot;/.../.venv/lib/python3.9/site-packages/starlette/routing.py&quot;, line 52, in app response = await func(request) File &quot;/.../.venv/lib/python3.9/site-packages/fastapi/applications.py&quot;, line 152, in openapi return JSONResponse(self.openapi()) File &quot;/.../.venv/lib/python3.9/site-packages/fastapi/applications.py&quot;, line 130, in openapi self.openapi_schema = get_openapi( File &quot;/.../.venv/lib/python3.9/site-packages/fastapi/openapi/utils.py&quot;, line 376, in get_openapi definitions = get_model_definitions( File &quot;/.../.venv/lib/python3.9/site-packages/fastapi/utils.py&quot;, line 28, in get_model_definitions model_name = model_name_map[model] KeyError: &lt;class 'pydantic.dataclasses.Item'&gt;"><pre class="notranslate"><code class="notranslate">Traceback (most recent call last): File "/.../.venv/lib/python3.9/site-packages/uvicorn/protocols/http/httptools_impl.py", line 398, in run_asgi result = await app(self.scope, self.receive, self.send) File "/.../.venv/lib/python3.9/site-packages/uvicorn/middleware/proxy_headers.py", line 45, in __call__ return await self.app(scope, receive, send) File "/.../.venv/lib/python3.9/site-packages/fastapi/applications.py", line 199, in __call__ await super().__call__(scope, receive, send) File "/.../.venv/lib/python3.9/site-packages/starlette/applications.py", line 112, in __call__ await self.middleware_stack(scope, receive, send) File "/.../.venv/lib/python3.9/site-packages/starlette/middleware/errors.py", line 181, in __call__ raise exc from None File "/.../.venv/lib/python3.9/site-packages/starlette/middleware/errors.py", line 159, in __call__ await self.app(scope, receive, _send) File "/.../.venv/lib/python3.9/site-packages/starlette/exceptions.py", line 82, in __call__ raise exc from None File "/.../.venv/lib/python3.9/site-packages/starlette/exceptions.py", line 71, in __call__ await self.app(scope, receive, sender) File "/.../.venv/lib/python3.9/site-packages/starlette/routing.py", line 580, in __call__ await route.handle(scope, receive, send) File "/.../.venv/lib/python3.9/site-packages/starlette/routing.py", line 241, in handle await self.app(scope, receive, send) File "/.../.venv/lib/python3.9/site-packages/starlette/routing.py", line 52, in app response = await func(request) File "/.../.venv/lib/python3.9/site-packages/fastapi/applications.py", line 152, in openapi return JSONResponse(self.openapi()) File "/.../.venv/lib/python3.9/site-packages/fastapi/applications.py", line 130, in openapi self.openapi_schema = get_openapi( File "/.../.venv/lib/python3.9/site-packages/fastapi/openapi/utils.py", line 376, in get_openapi definitions = get_model_definitions( File "/.../.venv/lib/python3.9/site-packages/fastapi/utils.py", line 28, in get_model_definitions model_name = model_name_map[model] KeyError: &lt;class 'pydantic.dataclasses.Item'&gt; </code></pre></div> <h3 dir="auto">Operating System</h3> <p dir="auto">macOS</p> <h3 dir="auto">Operating System Details</h3> <p dir="auto"><em>No response</em></p> <h3 dir="auto">FastAPI Version</h3> <p dir="auto">0.67.0</p> <h3 dir="auto">Python Version</h3> <p dir="auto">3.9.5</p> <h3 dir="auto">Additional Context</h3> <p dir="auto"><em>No response</em></p>
<p dir="auto"><strong>Describe the bug</strong><br> When input data is defined as <code class="notranslate">Union</code> type and both models have the same field (or inherit the same base class) response contains duplicated validation errors for the same field.</p> <p dir="auto"><strong>To Reproduce</strong></p> <p dir="auto">Let's create models and route:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="class Base(BaseModel): name: str class ModelA(Base): foo: Optional[str] = None class ModelB(Base): bar: Optional[str] = None Input = Union[ModelA, ModelB] @api.post(&quot;/foo&quot;) async def foo_post(data: Input = Body(...)): pass"><pre class="notranslate"><span class="pl-k">class</span> <span class="pl-v">Base</span>(<span class="pl-v">BaseModel</span>): <span class="pl-s1">name</span>: <span class="pl-s1">str</span> <span class="pl-k">class</span> <span class="pl-v">ModelA</span>(<span class="pl-v">Base</span>): <span class="pl-s1">foo</span>: <span class="pl-v">Optional</span>[<span class="pl-s1">str</span>] <span class="pl-c1">=</span> <span class="pl-c1">None</span> <span class="pl-k">class</span> <span class="pl-v">ModelB</span>(<span class="pl-v">Base</span>): <span class="pl-s1">bar</span>: <span class="pl-v">Optional</span>[<span class="pl-s1">str</span>] <span class="pl-c1">=</span> <span class="pl-c1">None</span> <span class="pl-v">Input</span> <span class="pl-c1">=</span> <span class="pl-v">Union</span>[<span class="pl-v">ModelA</span>, <span class="pl-v">ModelB</span>] <span class="pl-en">@<span class="pl-s1">api</span>.<span class="pl-en">post</span>(<span class="pl-s">"/foo"</span>)</span> <span class="pl-k">async</span> <span class="pl-k">def</span> <span class="pl-en">foo_post</span>(<span class="pl-s1">data</span>: <span class="pl-v">Input</span> <span class="pl-c1">=</span> <span class="pl-v">Body</span>(...)): <span class="pl-k">pass</span></pre></div> <p dir="auto">When request is made with empty json payload <code class="notranslate">{}</code>, response contains two errors for field <code class="notranslate">name</code> (mesage is <code class="notranslate">field required</code>).</p> <p dir="auto"><strong>Expected behavior</strong><br> In such case only one error of the same type should be returned without duplicates.</p> <p dir="auto"><strong>Environment:</strong></p> <ul dir="auto"> <li>OS: macOS</li> <li>FastAPI: 0.35</li> <li>Python: 3.7.4</li> </ul>
0
<p dir="auto"><code class="notranslate">"@types/react": "16.7.13"</code> works.<br> <code class="notranslate">"@types/react": "16.7.14"</code> and <code class="notranslate">"@types/react": "16.7.18"</code> (latest) throws this error.</p> <p dir="auto">Using <code class="notranslate">"typescript": "3.2.2"</code>.</p>
<ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> I tried using the latest <code class="notranslate">react-router/index.d.ts</code> file in this repo and had problems.</li> <li>[ x] I tried using the latest stable version of tsc. <a href="https://www.npmjs.com/package/typescript" rel="nofollow">https://www.npmjs.com/package/typescript</a></li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> I have a question that is inappropriate for <a href="https://stackoverflow.com/" rel="nofollow">StackOverflow</a>. (Please ask any appropriate questions there).</li> <li>[ x] I want to talk about <code class="notranslate">react-router/index.d.ts</code> and <code class="notranslate">history.d.ts</code>. <ul dir="auto"> <li>The authors of that type definition are cc/ <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/ngbrown/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/ngbrown">@ngbrown</a><br> Sergey Buturlakin <a href="https://github.com/sergey-buturlakin">https://github.com/sergey-buturlakin</a>, Yuichi Murata <a href="https://github.com/mrk21">https://github.com/mrk21</a>, Václav Ostrožlík <a href="https://github.com/vasek17">https://github.com/vasek17</a>, Nathan Brown <a href="https://github.com/ngbrown">https://github.com/ngbrown</a></li> </ul> </li> </ul> <p dir="auto">When I install react-router I get the following errors</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ERROR in /Projects/REACT/rangle/typescript-react-redux-starter/typings/browser/ambient/react-router/index.d.ts (32,22): error TS2305: Module 'HistoryModule' has no exported member 'LocationDescriptor'. ERROR in /Projects/REACT/rangle/typescript-react-redux-starter/typings/browser/ambient/react-router/index.d.ts (111,30): error TS2305: Module 'HistoryModule' has no exported member 'LocationDescriptor'. ERROR in /Projects/REACT/rangle/typescript-react-redux-starter/typings/browser/ambient/react-router/index.d.ts (211,31): error TS2305: Module 'HistoryModule' has no exported member 'LocationDescriptor'."><pre class="notranslate"><code class="notranslate">ERROR in /Projects/REACT/rangle/typescript-react-redux-starter/typings/browser/ambient/react-router/index.d.ts (32,22): error TS2305: Module 'HistoryModule' has no exported member 'LocationDescriptor'. ERROR in /Projects/REACT/rangle/typescript-react-redux-starter/typings/browser/ambient/react-router/index.d.ts (111,30): error TS2305: Module 'HistoryModule' has no exported member 'LocationDescriptor'. ERROR in /Projects/REACT/rangle/typescript-react-redux-starter/typings/browser/ambient/react-router/index.d.ts (211,31): error TS2305: Module 'HistoryModule' has no exported member 'LocationDescriptor'. </code></pre></div> <p dir="auto">Steps to reproduce</p> <p dir="auto">Clone <a href="https://github.com/rangle/typescript-react-redux-starter">https://github.com/rangle/typescript-react-redux-starter</a> and get it running, i.e. npm install; npm run dev<br> run node_modules/typings/dest/bin.js install react-router --ambient --save<br> run npm run dev</p> <p dir="auto">Expected Behavior<br> Typings throw no errors</p> <p dir="auto">Actual Behavior<br> Typings compilation throws three errors</p> <p dir="auto">I can see from the code that history.d.ts doesn't export the LocationDescriptor type, but it's used in the react-router type definition.</p>
0
<p dir="auto">Python <strong>requests</strong> library changes URL in some situations.<br> it removes some parameters<br> for example<br> <code class="notranslate">url = "https://www.example.com/test?"</code><br> it removes <code class="notranslate">?</code> in the request when I see it in Burp proxy<br> it changes to<br> <code class="notranslate">https://www.example.com/test</code><br> because I'm pentesting web applications I need to send for example quotation mark too and other things which will be removed by library automatically.<br> I need following path:<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/61124903/182108804-e9811743-2ba4-41d3-8266-9e6d97998e4a.png"><img src="https://user-images.githubusercontent.com/61124903/182108804-e9811743-2ba4-41d3-8266-9e6d97998e4a.png" alt="image" style="max-width: 100%;"></a><br> after ? must be empty</p>
<p dir="auto">As spending about 10 minutes figuring out how to log raw request/responses in requests, I eventually came across the following <a href="http://stackoverflow.com/questions/10588644/how-can-i-see-the-entire-http-request-thats-being-sent-by-my-python-application" rel="nofollow">SO article</a>, which references an obscure part of the <a href="http://docs.python-requests.org/en/master/api/?highlight=debuglevel" rel="nofollow">documentation</a>.</p> <p dir="auto">It would be nice if there was a clear section in the docs which explains how to do this, as it's not very clear and took quite a bit of searching. A quick copy/paste (or a complete move) would suffice. Thoughts?</p>
0
<p dir="auto">Win10 Pro OS:</p> <p dir="auto">Ok I'm no rocket scientist but I installed the new "PowerToys.msi" file and when I opened the program from the taskbar icon using "Settings" the box opens up to a blank screen. I have only 3 options to choose from the taskbar icon..."Settings, About and Exit".</p> <p dir="auto">Rebooted thinking that would help...NOT<br> Removed and re-installed...NOT</p> <p dir="auto">Stumped on why it does not work...<br> I know it's a beta but I was hoping for a bit more...</p>
<h1 dir="auto">Environment</h1> <p dir="auto">W10 Pro V1903 Build 18362.295<br> PowerToys: 0.11.0<br> Settings Screen</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Windows build number: [run &quot;ver&quot; at a command prompt] PowerToys version: PowerToy module for which you are reporting the bug (if applicable):"><pre class="notranslate"><code class="notranslate">Windows build number: [run "ver" at a command prompt] PowerToys version: PowerToy module for which you are reporting the bug (if applicable): </code></pre></div> <h1 dir="auto">Steps to reproduce</h1> <p dir="auto">Just installed and attempted to open settings. Screen is totally blank/empty.<br> I 'repaired - same issue.<br> Uninstalled, reboot and reinstall - same issue.</p> <h1 dir="auto">Expected behavior</h1> <p dir="auto">Expect to see config options</p> <h1 dir="auto">Actual behavior</h1> <p dir="auto">Blank window.</p> <h1 dir="auto">Screenshots</h1> <p dir="auto"><a href="https://i.imgur.com/a7oWKgp.png" rel="nofollow">https://i.imgur.com/a7oWKgp.png</a></p>
1
<pre class="notranslate">Tested with latest tip. ENODATA is not supported on e.g. FreeBSD but ENOATTR is supported more widely. In Linux it is a synonym for ENODATA. The attached patch makes ENOATTR work on Linux.</pre> <p dir="auto">Attachments:</p> <ol dir="auto"> <li><a href="https://storage.googleapis.com/go-attachment/753/0/err.diff" rel="nofollow">err.diff</a> (1448 bytes)</li> </ol>
<p dir="auto">by <strong><a href="mailto:[email protected]">[email protected]</a></strong>:</p> <pre class="notranslate">What steps will reproduce the problem? If possible, include a link to a program on play.golang.org. 1. in a method, create an array using literal syntax 2. take that array's slice using [:] syntax 3. return the slice 4. try to access the slice from caller Simplest reproducing program, courtesy of dominikh (Dominik Honnef) who helped me look at this: <a href="http://play.golang.org/p/Yl6EXET0fc" rel="nofollow">http://play.golang.org/p/Yl6EXET0fc</a> My original program, reproducing roughly the steps that triggered this in a real project (much more elaborate): <a href="http://play.golang.org/p/s1WGRen-te" rel="nofollow">http://play.golang.org/p/s1WGRen-te</a> What is the expected output? 0 3 foo 1 3 bar 0 3 foo 1 3 bar What do you see instead? 0 3 foo 1 3 bar 0 3 foo 1 4457167 [string too long] Which compiler are you using (5g, 6g, 8g, gccgo)? 6g Which operating system are you using? Linux 3.5.0-23-generic #35~precise1-Ubuntu SMP Fri Jan 25 17:13:26 UTC 2013 x86_64 x86_64 x86_64 GNU/Linux Which version are you using? (run 'go version') 1.1 (dominikh confirms this happens on tip as well) Please provide any additional information below. This is a strange and elusive bug; essentially, when using a slice that is produced using the [:] notation on an array as a return value, the caller gets a bogus pointer. When I initially came across this bug, I was getting "invalid memory address or nil pointer dereference" panics in the json Marshal function when trying to serialize the return value (I was testing an HTTP framework, so I just had a method return the slice of [2]string{foo, bar}). When I tried to printf the value it was trying to pass to Marshal, it printed a bunch of binary data with strings that I recognized from other parts of the program, obviously causing serious concern. Below are 2 programs that will reproduce this in various forms. dominikh from #go-nuts helped me look at this and actually narrowed it down a bit further than my initial repro, which just reproduced the sequence of events that happened in my program. His notes below: "These are all the details I could find: - It breaks when using method values; it doesn't break when using function values. - It breaks when allowing inlining; it doesn't break when not allowing inlining - It breaks both with Go 1.1 and Go tip, so that makes bisecting it somewhat easier." Additional "fun" info: - if you call printf("%p", foo[:]) in the "broken" method in the second program, it "fixes" the issue; I'm guessing this tips off the compiler somehow. I discovered this while trying to see if I could demonstrate the pointer having the wrong address</pre>
0
<p dir="auto">Hi ,<br> I have the same issue as <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="211924785" data-permission-text="Title is private" data-url="https://github.com/keras-team/keras/issues/5601" data-hovercard-type="issue" data-hovercard-url="/keras-team/keras/issues/5601/hovercard" href="https://github.com/keras-team/keras/issues/5601">#5601</a> (I am unable to force Keras + Theano to use more than 1 thread using OpenBLAS.) I have applied all suggestion mentioned on issue <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="211924785" data-permission-text="Title is private" data-url="https://github.com/keras-team/keras/issues/5601" data-hovercard-type="issue" data-hovercard-url="/keras-team/keras/issues/5601/hovercard" href="https://github.com/keras-team/keras/issues/5601">#5601</a>, It works on:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="inputs = Input(shape=(1024000,)) x = Dense(256, activation='relu')(inputs) x = Dense(256, activation='relu')(x) predictions = Dense(10000, activation='softmax')(x) model = Model(input=inputs, output=predictions) model.compile(optimizer='rmsprop', loss='categorical_crossentropy', metrics=['accuracy']) data = np.random.rand(100, 1024000) for i in range(100000): print (i) model.predict(data)"><pre class="notranslate"><code class="notranslate">inputs = Input(shape=(1024000,)) x = Dense(256, activation='relu')(inputs) x = Dense(256, activation='relu')(x) predictions = Dense(10000, activation='softmax')(x) model = Model(input=inputs, output=predictions) model.compile(optimizer='rmsprop', loss='categorical_crossentropy', metrics=['accuracy']) data = np.random.rand(100, 1024000) for i in range(100000): print (i) model.predict(data) </code></pre></div> <p dir="auto">but it doesn't work on :</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="THEANO_FLAGS='device=cpu,openmp=True,blas.ldflags=-lopenblas' OMP_NUM_THREADS=8 KERAS_BACKEND=theano import pandas as pd import numpy as np from tqdm import tqdm from keras.models import Sequential from keras.layers.core import Dense, Activation, Dropout from keras.layers.embeddings import Embedding from keras.layers.recurrent import LSTM, GRU from keras.layers.normalization import BatchNormalization from keras.utils import np_utils import keras.engine.topology from keras.layers import TimeDistributed, Lambda from keras.layers import Convolution1D, GlobalMaxPooling1D from keras.callbacks import ModelCheckpoint from keras import backend as K from keras.layers.advanced_activations import PReLU from keras.preprocessing import sequence, text data = pd.read_csv('data/quora_duplicate_questions.tsv', sep='\t') y = data.is_duplicate.values tk = text.Tokenizer(nb_words=200000) max_len = 40 tk.fit_on_texts(list(data.question1.values) + list(data.question2.values.astype(str))) x1 = tk.texts_to_sequences(data.question1.values) x1 = sequence.pad_sequences(x1, maxlen=max_len) x2 = tk.texts_to_sequences(data.question2.values.astype(str)) x2 = sequence.pad_sequences(x2, maxlen=max_len) word_index = tk.word_index ytrain_enc = np_utils.to_categorical(y) embeddings_index = {} f = open('data/glove.840B.300d.txt') values_conv = [] for line in tqdm(f): values = line.split() for item in values: try: values_conv.append(float(item)) except: pass word = values_conv[0] coefs = np.asarray(values_conv[1:], dtype='float32') embeddings_index[word] = coefs f.close() print('Found %s word vectors.' % len(embeddings_index)) embedding_matrix = np.zeros((len(word_index) + 1, 300)) for word, i in tqdm(word_index.items()): embedding_vector = embeddings_index.get(word) if embedding_vector is not None: embedding_matrix[i] = embedding_vector"><pre class="notranslate"><code class="notranslate">THEANO_FLAGS='device=cpu,openmp=True,blas.ldflags=-lopenblas' OMP_NUM_THREADS=8 KERAS_BACKEND=theano import pandas as pd import numpy as np from tqdm import tqdm from keras.models import Sequential from keras.layers.core import Dense, Activation, Dropout from keras.layers.embeddings import Embedding from keras.layers.recurrent import LSTM, GRU from keras.layers.normalization import BatchNormalization from keras.utils import np_utils import keras.engine.topology from keras.layers import TimeDistributed, Lambda from keras.layers import Convolution1D, GlobalMaxPooling1D from keras.callbacks import ModelCheckpoint from keras import backend as K from keras.layers.advanced_activations import PReLU from keras.preprocessing import sequence, text data = pd.read_csv('data/quora_duplicate_questions.tsv', sep='\t') y = data.is_duplicate.values tk = text.Tokenizer(nb_words=200000) max_len = 40 tk.fit_on_texts(list(data.question1.values) + list(data.question2.values.astype(str))) x1 = tk.texts_to_sequences(data.question1.values) x1 = sequence.pad_sequences(x1, maxlen=max_len) x2 = tk.texts_to_sequences(data.question2.values.astype(str)) x2 = sequence.pad_sequences(x2, maxlen=max_len) word_index = tk.word_index ytrain_enc = np_utils.to_categorical(y) embeddings_index = {} f = open('data/glove.840B.300d.txt') values_conv = [] for line in tqdm(f): values = line.split() for item in values: try: values_conv.append(float(item)) except: pass word = values_conv[0] coefs = np.asarray(values_conv[1:], dtype='float32') embeddings_index[word] = coefs f.close() print('Found %s word vectors.' % len(embeddings_index)) embedding_matrix = np.zeros((len(word_index) + 1, 300)) for word, i in tqdm(word_index.items()): embedding_vector = embeddings_index.get(word) if embedding_vector is not None: embedding_matrix[i] = embedding_vector </code></pre></div> <p dir="auto">I don't really know what the problem is. I would really appreciate any help. Thanks</p>
<p dir="auto">Environment:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&gt;&gt;&gt; import sys &gt;&gt;&gt; print(sys.version) 3.5.3 (v3.5.3:1880cb95a742, Jan 16 2017, 16:02:32) [MSC v.1900 64 bit (AMD64)] &gt;&gt;&gt; import tensorflow &gt;&gt;&gt; tensorflow.__version__ '1.4.0' &gt;&gt;&gt; import keras Using TensorFlow backend. &gt;&gt;&gt; keras.__version__ '2.0.9'"><pre class="notranslate"><code class="notranslate">&gt;&gt;&gt; import sys &gt;&gt;&gt; print(sys.version) 3.5.3 (v3.5.3:1880cb95a742, Jan 16 2017, 16:02:32) [MSC v.1900 64 bit (AMD64)] &gt;&gt;&gt; import tensorflow &gt;&gt;&gt; tensorflow.__version__ '1.4.0' &gt;&gt;&gt; import keras Using TensorFlow backend. &gt;&gt;&gt; keras.__version__ '2.0.9' </code></pre></div> <p dir="auto">I can run this code:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="from tensorflow import Graph from keras.models import model_from_json print('loading first model...') graph1 = Graph() with graph1.as_default(): with open('model1_arch.json') as arch_file: model1 = model_from_json(arch_file.read()) print('loading second model...') graph2 = Graph() with graph2.as_default(): with open('model2_arch.json') as arch_file: model2 = model_from_json(arch_file.read())"><pre class="notranslate"><code class="notranslate">from tensorflow import Graph from keras.models import model_from_json print('loading first model...') graph1 = Graph() with graph1.as_default(): with open('model1_arch.json') as arch_file: model1 = model_from_json(arch_file.read()) print('loading second model...') graph2 = Graph() with graph2.as_default(): with open('model2_arch.json') as arch_file: model2 = model_from_json(arch_file.read()) </code></pre></div> <p dir="auto">It prints:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Using TensorFlow backend. loading first model... loading second model..."><pre class="notranslate"><code class="notranslate">Using TensorFlow backend. loading first model... loading second model... </code></pre></div> <p dir="auto">looks fine.<br> And this code:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="from tensorflow import Graph from keras.models import model_from_json print('loading first model...') graph1 = Graph() with graph1.as_default(): with open('model1_arch.json') as arch_file: model1 = model_from_json(arch_file.read()) model1.load_weights('model1_weights.h5') # &lt;--- add this line print('loading second model...') graph2 = Graph() with graph2.as_default(): with open('model2_arch.json') as arch_file: model2 = model_from_json(arch_file.read())"><pre class="notranslate"><code class="notranslate">from tensorflow import Graph from keras.models import model_from_json print('loading first model...') graph1 = Graph() with graph1.as_default(): with open('model1_arch.json') as arch_file: model1 = model_from_json(arch_file.read()) model1.load_weights('model1_weights.h5') # &lt;--- add this line print('loading second model...') graph2 = Graph() with graph2.as_default(): with open('model2_arch.json') as arch_file: model2 = model_from_json(arch_file.read()) </code></pre></div> <p dir="auto">It prints:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Using TensorFlow backend. loading first model... 2017-11-19 17:00:05.742339: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\platform\cpu_feature_guard.cc:137] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX AVX2 2017-11-19 17:00:06.276240: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\common_runtime\gpu\gpu_device.cc:1030] Found device 0 with properties: name: GeForce GTX 950M major: 5 minor: 0 memoryClockRate(GHz): 0.928 pciBusID: 0000:01:00.0 totalMemory: 4.00GiB freeMemory: 3.35GiB 2017-11-19 17:00:06.276809: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\common_runtime\gpu\gpu_device.cc:1120] Creating TensorFlow device (/device:GPU:0) -&gt; (device: 0, name: GeForce GTX 950M, pci bus id: 0000:01:00.0, compute capability: 5.0) loading second model..."><pre class="notranslate"><code class="notranslate">Using TensorFlow backend. loading first model... 2017-11-19 17:00:05.742339: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\platform\cpu_feature_guard.cc:137] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX AVX2 2017-11-19 17:00:06.276240: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\common_runtime\gpu\gpu_device.cc:1030] Found device 0 with properties: name: GeForce GTX 950M major: 5 minor: 0 memoryClockRate(GHz): 0.928 pciBusID: 0000:01:00.0 totalMemory: 4.00GiB freeMemory: 3.35GiB 2017-11-19 17:00:06.276809: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\common_runtime\gpu\gpu_device.cc:1120] Creating TensorFlow device (/device:GPU:0) -&gt; (device: 0, name: GeForce GTX 950M, pci bus id: 0000:01:00.0, compute capability: 5.0) loading second model... </code></pre></div> <p dir="auto">So far so good.</p> <p dir="auto">However, I run this code:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="from tensorflow import Graph from keras.models import model_from_json print('loading first model...') graph1 = Graph() with graph1.as_default(): with open('model1_arch.json') as arch_file: model1 = model_from_json(arch_file.read()) model1.load_weights('model1_weights.h5') print('loading second model...') graph2 = Graph() with graph2.as_default(): with open('model2_arch.json') as arch_file: model2 = model_from_json(arch_file.read()) model2.load_weights('model2_weights.h5') # &lt;--- add this line"><pre class="notranslate"><code class="notranslate">from tensorflow import Graph from keras.models import model_from_json print('loading first model...') graph1 = Graph() with graph1.as_default(): with open('model1_arch.json') as arch_file: model1 = model_from_json(arch_file.read()) model1.load_weights('model1_weights.h5') print('loading second model...') graph2 = Graph() with graph2.as_default(): with open('model2_arch.json') as arch_file: model2 = model_from_json(arch_file.read()) model2.load_weights('model2_weights.h5') # &lt;--- add this line </code></pre></div> <p dir="auto">It doesn't work.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Using TensorFlow backend. loading first model... 2017-11-19 17:05:23.982670: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\platform\cpu_feature_guard.cc:137] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX AVX2 2017-11-19 17:05:24.522351: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\common_runtime\gpu\gpu_device.cc:1030] Found device 0 with properties: name: GeForce GTX 950M major: 5 minor: 0 memoryClockRate(GHz): 0.928 pciBusID: 0000:01:00.0 totalMemory: 4.00GiB freeMemory: 3.35GiB 2017-11-19 17:05:24.522861: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\common_runtime\gpu\gpu_device.cc:1120] Creating TensorFlow device (/device:GPU:0) -&gt; (device: 0, name: GeForce GTX 950M, pci bus id: 0000:01:00.0, compute capability: 5.0) loading second model... Traceback (most recent call last): File &quot;C:\Program Files\Python35\lib\site-packages\tensorflow\python\client\session.py&quot;, line 1064, in _run allow_operation=False) File &quot;C:\Program Files\Python35\lib\site-packages\tensorflow\python\framework\ops.py&quot;, line 3035, in as_graph_element return self._as_graph_element_locked(obj, allow_tensor, allow_operation) File &quot;C:\Program Files\Python35\lib\site-packages\tensorflow\python\framework\ops.py&quot;, line 3114, in _as_graph_element_locked raise ValueError(&quot;Tensor %s is not an element of this graph.&quot; % obj) ValueError: Tensor Tensor(&quot;Placeholder:0&quot;, shape=(40980, 50), dtype=float32) is not an element of this graph. During handling of the above exception, another exception occurred: Traceback (most recent call last): File &quot;D:/university/django-and-bootstrap-template/mysite/rate/models/test/test.py&quot;, line 15, in &lt;module&gt; model2.load_weights('model2_weights.h5') File &quot;C:\Program Files\Python35\lib\site-packages\keras\models.py&quot;, line 733, in load_weights topology.load_weights_from_hdf5_group(f, layers) File &quot;C:\Program Files\Python35\lib\site-packages\keras\engine\topology.py&quot;, line 3142, in load_weights_from_hdf5_group K.batch_set_value(weight_value_tuples) File &quot;C:\Program Files\Python35\lib\site-packages\keras\backend\tensorflow_backend.py&quot;, line 2247, in batch_set_value get_session().run(assign_ops, feed_dict=feed_dict) File &quot;C:\Program Files\Python35\lib\site-packages\tensorflow\python\client\session.py&quot;, line 889, in run run_metadata_ptr) File &quot;C:\Program Files\Python35\lib\site-packages\tensorflow\python\client\session.py&quot;, line 1067, in _run + e.args[0]) TypeError: Cannot interpret feed_dict key as Tensor: Tensor Tensor(&quot;Placeholder:0&quot;, shape=(40980, 50), dtype=float32) is not an element of this graph."><pre class="notranslate"><code class="notranslate">Using TensorFlow backend. loading first model... 2017-11-19 17:05:23.982670: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\platform\cpu_feature_guard.cc:137] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX AVX2 2017-11-19 17:05:24.522351: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\common_runtime\gpu\gpu_device.cc:1030] Found device 0 with properties: name: GeForce GTX 950M major: 5 minor: 0 memoryClockRate(GHz): 0.928 pciBusID: 0000:01:00.0 totalMemory: 4.00GiB freeMemory: 3.35GiB 2017-11-19 17:05:24.522861: I C:\tf_jenkins\home\workspace\rel-win\M\windows-gpu\PY\35\tensorflow\core\common_runtime\gpu\gpu_device.cc:1120] Creating TensorFlow device (/device:GPU:0) -&gt; (device: 0, name: GeForce GTX 950M, pci bus id: 0000:01:00.0, compute capability: 5.0) loading second model... Traceback (most recent call last): File "C:\Program Files\Python35\lib\site-packages\tensorflow\python\client\session.py", line 1064, in _run allow_operation=False) File "C:\Program Files\Python35\lib\site-packages\tensorflow\python\framework\ops.py", line 3035, in as_graph_element return self._as_graph_element_locked(obj, allow_tensor, allow_operation) File "C:\Program Files\Python35\lib\site-packages\tensorflow\python\framework\ops.py", line 3114, in _as_graph_element_locked raise ValueError("Tensor %s is not an element of this graph." % obj) ValueError: Tensor Tensor("Placeholder:0", shape=(40980, 50), dtype=float32) is not an element of this graph. During handling of the above exception, another exception occurred: Traceback (most recent call last): File "D:/university/django-and-bootstrap-template/mysite/rate/models/test/test.py", line 15, in &lt;module&gt; model2.load_weights('model2_weights.h5') File "C:\Program Files\Python35\lib\site-packages\keras\models.py", line 733, in load_weights topology.load_weights_from_hdf5_group(f, layers) File "C:\Program Files\Python35\lib\site-packages\keras\engine\topology.py", line 3142, in load_weights_from_hdf5_group K.batch_set_value(weight_value_tuples) File "C:\Program Files\Python35\lib\site-packages\keras\backend\tensorflow_backend.py", line 2247, in batch_set_value get_session().run(assign_ops, feed_dict=feed_dict) File "C:\Program Files\Python35\lib\site-packages\tensorflow\python\client\session.py", line 889, in run run_metadata_ptr) File "C:\Program Files\Python35\lib\site-packages\tensorflow\python\client\session.py", line 1067, in _run + e.args[0]) TypeError: Cannot interpret feed_dict key as Tensor: Tensor Tensor("Placeholder:0", shape=(40980, 50), dtype=float32) is not an element of this graph. </code></pre></div> <p dir="auto">I'm trying to duplicate the solution found <a href="https://stackoverflow.com/a/41991989/5161420" rel="nofollow">here</a>.<br> These two models are good if and only if they're not in each other's way.</p>
0
<ul dir="auto"> <li>Electron version: 1.6.12 (electron-prebuilt-compile)</li> <li>Operating system: Windows 10</li> </ul> <h3 dir="auto">Expected behavior</h3> <p dir="auto">I am writing application in react. I want to create eventListener, which will send by ipcRenderer url of first webview, to another. Also some links should be blocked. I tried a lot of evens, but finally ended with <code class="notranslate">'will-navigate'</code> and <code class="notranslate">event.preventDefault()</code>.</p> <h3 dir="auto">Actual behavior</h3> <p dir="auto">Will-navigate doesn't work at all. It doesn't display even console logs. I checked other events. F.g <code class="notranslate">did-navigate</code> or <code class="notranslate">did-navigate-in-page</code> and from these events I received respones.</p> <h3 dir="auto">How to reproduce</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ReactDOM.findDOMNode(this).addEventListener('did-navigate-in-page',(event) =&gt;{ console.log(&quot;did-navigate-in-page&quot;)}); ReactDOM.findDOMNode(this).addEventListener('did-navigate',(event, url) =&gt;{ console.log(&quot;did-navigate&quot;)}); ReactDOM.findDOMNode(this).addEventListener('will-navigate',(event, url) =&gt;{ console.log(&quot;will-navigate&quot;)})"><pre class="notranslate"><code class="notranslate">ReactDOM.findDOMNode(this).addEventListener('did-navigate-in-page',(event) =&gt;{ console.log("did-navigate-in-page")}); ReactDOM.findDOMNode(this).addEventListener('did-navigate',(event, url) =&gt;{ console.log("did-navigate")}); ReactDOM.findDOMNode(this).addEventListener('will-navigate',(event, url) =&gt;{ console.log("will-navigate")}) </code></pre></div> <p dir="auto">And responses are:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="did-navigate-in-page did-navigate"><pre class="notranslate"><code class="notranslate">did-navigate-in-page did-navigate </code></pre></div>
<p dir="auto">for some reason, the will-navigate event handler does not fire from the renderer process, i have only tested for the will-navigate event listener, am not sure if this is the behaviour of other webContents event listeners</p> <h3 dir="auto">Expected behavior</h3> <p dir="auto">the webContents will-navigate event handler should fire and prevent the window from navigating</p> <h3 dir="auto">Actual behavior</h3> <p dir="auto">the webContents will-navigate event does not fire, instead the window navigates</p> <h3 dir="auto">How to reproduce</h3> <p dir="auto">main.js</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="const { BrowserWindow, app } = require(&quot;electron&quot;); app.on(&quot;ready&quot;, () =&gt; { let win = new BrowserWindow({}); win.on(&quot;close&quot;, () =&gt; { win = null; app.quit(); }); win.webContents.openDevTools({ mode: &quot;detached&quot; }); win.loadURL(`file://${__dirname}/index.html`); });"><pre class="notranslate"><span class="pl-k">const</span> <span class="pl-kos">{</span> BrowserWindow<span class="pl-kos">,</span> app <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">"electron"</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-kos">(</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-k">let</span> <span class="pl-s1">win</span> <span class="pl-c1">=</span> <span class="pl-k">new</span> <span class="pl-v">BrowserWindow</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-s1">win</span><span class="pl-kos">.</span><span class="pl-en">on</span><span class="pl-kos">(</span><span class="pl-s">"close"</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-s1">win</span> <span class="pl-c1">=</span> <span class="pl-c1">null</span><span class="pl-kos">;</span> <span class="pl-s1">app</span><span class="pl-kos">.</span><span class="pl-en">quit</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-s1">win</span><span class="pl-kos">.</span><span class="pl-c1">webContents</span><span class="pl-kos">.</span><span class="pl-en">openDevTools</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">mode</span>: <span class="pl-s">"detached"</span> <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-s1">win</span><span class="pl-kos">.</span><span class="pl-en">loadURL</span><span class="pl-kos">(</span><span class="pl-s">`file://<span class="pl-s1"><span class="pl-kos">${</span><span class="pl-s1">__dirname</span><span class="pl-kos">}</span></span>/index.html`</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">index.html</p> <div class="highlight highlight-text-html-basic notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&lt;!doctype html&gt; &lt;html&gt; &lt;head&gt; &lt;title&gt; Webcontents from renderer proces &lt;/title&gt; &lt;/head&gt; &lt;body&gt; &lt;p&gt; Drag and Drop Something Here&lt;/p&gt; &lt;script&gt; const { remote: { getCurrentWindow } } = require(&quot;electron&quot;); const webContents = getCurrentWindow().webContents; console.log(webContents); webContents.on(&quot;will-navigate&quot;, (evt,filePath) =&gt; { evt.preventDefault(); console.log(filePath); }); &lt;/script&gt; &lt;/body&gt; &lt;/html&gt; "><pre class="notranslate"><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">title</span><span class="pl-kos">&gt;</span> Webcontents from renderer proces <span class="pl-kos">&lt;/</span><span class="pl-ent">title</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">body</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">p</span><span class="pl-kos">&gt;</span> Drag and Drop Something Here<span class="pl-kos">&lt;/</span><span class="pl-ent">p</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-k">const</span> <span class="pl-kos">{</span> <span class="pl-c1">remote</span>: <span class="pl-kos">{</span> getCurrentWindow <span class="pl-kos">}</span> <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">"electron"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">const</span> <span class="pl-s1">webContents</span> <span class="pl-c1">=</span> <span class="pl-en">getCurrentWindow</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-c1">webContents</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">webContents</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-s1">webContents</span><span class="pl-kos">.</span><span class="pl-en">on</span><span class="pl-kos">(</span><span class="pl-s">"will-navigate"</span><span class="pl-kos">,</span> <span class="pl-kos">(</span><span class="pl-s1">evt</span><span class="pl-kos">,</span><span class="pl-s1">filePath</span><span class="pl-kos">)</span> <span class="pl-c1">=&gt;</span> <span class="pl-kos">{</span> <span class="pl-s1">evt</span><span class="pl-kos">.</span><span class="pl-en">preventDefault</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-en">log</span><span class="pl-kos">(</span><span class="pl-s1">filePath</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">&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> <ul dir="auto"> <li>Electron version: 1.7.11</li> <li>Operating system: Gnu/Linux</li> </ul>
1
<p dir="auto">[Enter steps to reproduce below:]</p> <ol dir="auto"> <li>ctrl + alt + o to open AtomSharp</li> <li>get exception</li> </ol> <p dir="auto"><strong>Atom Version</strong>: 0.166.0<br> <strong>System</strong>: Mac OS X 10.10.1<br> <strong>Thrown From</strong>: Atom Core</p> <h3 dir="auto">Stack Trace</h3> <p dir="auto">Uncaught Error: spawn mono ENOENT</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="At events.js:85 Error: spawn mono ENOENT at exports._errnoException (util.js:742:11) at Process.ChildProcess._handle.onexit (child_process.js:1051:32) at child_process.js:1142:20 at process._tickCallback (node.js:378:11) "><pre class="notranslate"><code class="notranslate">At events.js:85 Error: spawn mono ENOENT at exports._errnoException (util.js:742:11) at Process.ChildProcess._handle.onexit (child_process.js:1051:32) at child_process.js:1142:20 at process._tickCallback (node.js:378:11) </code></pre></div> <h3 dir="auto">Commands</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" -1:07.9 project-manager:toggle (atom-text-editor.editor.is-focused) -1:06.6 core:confirm (atom-text-editor.editor.mini) 18x -0:36.7 core:backspace (atom-text-editor.editor.mini) -0:00.0 omnisharp-atom:toggle (atom-text-editor.editor.is-focused)"><pre class="notranslate"><code class="notranslate"> -1:07.9 project-manager:toggle (atom-text-editor.editor.is-focused) -1:06.6 core:confirm (atom-text-editor.editor.mini) 18x -0:36.7 core:backspace (atom-text-editor.editor.mini) -0:00.0 omnisharp-atom:toggle (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;editor&quot;: { &quot;fontSize&quot;: 13, &quot;invisibles&quot;: {} } }"><pre class="notranslate">{ <span class="pl-ent">"core"</span>: {}, <span class="pl-ent">"editor"</span>: { <span class="pl-ent">"fontSize"</span>: <span class="pl-c1">13</span>, <span class="pl-ent">"invisibles"</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 color-picker, v1.2.6 jshint, v1.1.3 language-cshtml, v0.1.0 linter, v0.9.1 omnisharp-atom, v0.1.6 project-manager, v1.14.1 # Dev No dev packages"><pre class="notranslate"><span class="pl-c"><span class="pl-c">#</span> User</span> color<span class="pl-k">-</span>picker, v1.<span class="pl-ii">2</span>.<span class="pl-ii">6</span> jshint, v1.<span class="pl-ii">1</span>.<span class="pl-ii">3</span> language<span class="pl-k">-</span>cshtml, v0.<span class="pl-ii">1</span>.<span class="pl-ii">0</span> linter, v0.<span class="pl-ii">9</span>.<span class="pl-ii">1</span> omnisharp<span class="pl-k">-</span>atom, v0.<span class="pl-ii">1</span>.<span class="pl-ii">6</span> project<span class="pl-k">-</span>manager, v1.<span class="pl-ii">14</span>.<span class="pl-ii">1</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">I've installed all the pieces successfully, yet when I open up a .cs file and start omnisharp, I get this error:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/55049/5336031/4f23c51c-7e83-11e4-831e-6e880852426d.png"><img src="https://cloud.githubusercontent.com/assets/55049/5336031/4f23c51c-7e83-11e4-831e-6e880852426d.png" alt="screen shot 2014-12-08 at 2 38 16 am" style="max-width: 100%;"></a></p> <p dir="auto">Running KRE 1.0.0-beta1</p>
1
<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="import pandas as pd df = pd.DataFrame([[None, 1], [None, 1]], columns=['a', 'b']) grouped = df.groupby('a') print(len(grouped.groups)) print(grouped.groups) df = pd.DataFrame([[None, 1], [1, 1]], columns=['a', 'b']) grouped = df.groupby('a') print(grouped.groups)"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">pandas</span> <span class="pl-k">as</span> <span class="pl-s1">pd</span> <span class="pl-s1">df</span> <span class="pl-c1">=</span> <span class="pl-s1">pd</span>.<span class="pl-v">DataFrame</span>([[<span class="pl-c1">None</span>, <span class="pl-c1">1</span>], [<span class="pl-c1">None</span>, <span class="pl-c1">1</span>]], <span class="pl-s1">columns</span><span class="pl-c1">=</span>[<span class="pl-s">'a'</span>, <span class="pl-s">'b'</span>]) <span class="pl-s1">grouped</span> <span class="pl-c1">=</span> <span class="pl-s1">df</span>.<span class="pl-en">groupby</span>(<span class="pl-s">'a'</span>) <span class="pl-en">print</span>(<span class="pl-en">len</span>(<span class="pl-s1">grouped</span>.<span class="pl-s1">groups</span>)) <span class="pl-en">print</span>(<span class="pl-s1">grouped</span>.<span class="pl-s1">groups</span>) <span class="pl-s1">df</span> <span class="pl-c1">=</span> <span class="pl-s1">pd</span>.<span class="pl-v">DataFrame</span>([[<span class="pl-c1">None</span>, <span class="pl-c1">1</span>], [<span class="pl-c1">1</span>, <span class="pl-c1">1</span>]], <span class="pl-s1">columns</span><span class="pl-c1">=</span>[<span class="pl-s">'a'</span>, <span class="pl-s">'b'</span>]) <span class="pl-s1">grouped</span> <span class="pl-c1">=</span> <span class="pl-s1">df</span>.<span class="pl-en">groupby</span>(<span class="pl-s">'a'</span>) <span class="pl-en">print</span>(<span class="pl-s1">grouped</span>.<span class="pl-s1">groups</span>)</pre></div> <h4 dir="auto">Problem description</h4> <p dir="auto">Not sure if this is design intent or a bug. When None appears in column grouped by, None is not counted as a group. If it is a design intent, is there any we to turn off this feature?</p> <h4 dir="auto">Expected Output</h4> <p dir="auto">None is counted as a group.</p> <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> <h2 dir="auto">INSTALLED VERSIONS</h2> <p dir="auto">commit: None<br> python: 3.6.2.final.0<br> python-bits: 64<br> OS: Linux<br> OS-release: 4.4.0-119-generic<br> machine: x86_64<br> processor: x86_64<br> byteorder: little<br> LC_ALL: None<br> LANG: en_HK.UTF-8<br> LOCALE: en_HK.UTF-8</p> <p dir="auto">pandas: 0.23.0<br> pytest: 3.2.1<br> pip: 9.0.1<br> setuptools: 36.4.0<br> Cython: None<br> numpy: 1.14.3<br> scipy: None<br> pyarrow: None<br> xarray: None<br> IPython: None<br> sphinx: None<br> patsy: None<br> dateutil: 2.7.3<br> pytz: 2018.4<br> blosc: None<br> bottleneck: None<br> tables: None<br> numexpr: 2.6.5<br> feather: None<br> matplotlib: None<br> openpyxl: 2.4.9<br> xlrd: None<br> xlwt: None<br> xlsxwriter: None<br> lxml: None<br> bs4: None<br> html5lib: 0.999999999<br> sqlalchemy: 1.1.15<br> pymysql: None<br> psycopg2: 2.7.3.1 (dt dec pq3 ext lo64)<br> jinja2: 2.9.6<br> s3fs: None<br> fastparquet: None<br> pandas_gbq: None<br> pandas_datareader: None</p> </details>
<p dir="auto">ENH: maybe for now just provide a warning if dropping the nan rows when pivotting...</p> <p dir="auto">rom ml</p> <p dir="auto"><a href="http://stackoverflow.com/questions/16860172/python-pandas-pivot-table-silently-drops-indices-with-nans" rel="nofollow">http://stackoverflow.com/questions/16860172/python-pandas-pivot-table-silently-drops-indices-with-nans</a></p> <p dir="auto">This is effectivly trying to groupby on a NaN, currently not allowed</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="In [13]: a = [['a', 'b', 12, 12, 12], ['a', nan, 12.3, 233., 12], ['b', 'a', 123.23, 123, 1], ['a', 'b', 1, 1, 1.]] In [14]: df = DataFrame(a, columns=['a', 'b', 'c', 'd', 'e']) In [15]: df.groupby(['a','b']).sum() Out[15]: c d e a b a b 13.00 13 13 b a 123.23 123 1"><pre class="notranslate"><code class="notranslate">In [13]: a = [['a', 'b', 12, 12, 12], ['a', nan, 12.3, 233., 12], ['b', 'a', 123.23, 123, 1], ['a', 'b', 1, 1, 1.]] In [14]: df = DataFrame(a, columns=['a', 'b', 'c', 'd', 'e']) In [15]: df.groupby(['a','b']).sum() Out[15]: c d e a b a b 13.00 13 13 b a 123.23 123 1 </code></pre></div> <p dir="auto">Workaround to fill the index with a dummy, pivot, and replace</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" In [31]: df2 = df.copy() In [32]: df2['dummy'] = np.nan In [33]: df2['b'] = df2['b'].fillna('dummy') In [34]: df2 Out[34]: a b c d e dummy 0 a b 12.00 12 12 NaN 1 a dummy 12.30 233 12 NaN 2 b a 123.23 123 1 NaN 3 a b 1.00 1 1 NaN In [35]: df2.pivot_table(rows=['a', 'b'], values=['c', 'd', 'e'], aggfunc=sum) Out[35]: a b c d e 0 a b 13.00 13 13 1 a dummy 12.30 233 12 2 b a 123.23 123 1 In [36]: df2.pivot_table(rows=['a', 'b'], values=['c', 'd', 'e'], aggfunc=sum).replace('dummy',np.nan) Out[36]: a b c d e 0 a b 13.00 13 13 1 a NaN 12.30 233 12 2 b a 123.23 123 1 "><pre class="notranslate"><code class="notranslate"> In [31]: df2 = df.copy() In [32]: df2['dummy'] = np.nan In [33]: df2['b'] = df2['b'].fillna('dummy') In [34]: df2 Out[34]: a b c d e dummy 0 a b 12.00 12 12 NaN 1 a dummy 12.30 233 12 NaN 2 b a 123.23 123 1 NaN 3 a b 1.00 1 1 NaN In [35]: df2.pivot_table(rows=['a', 'b'], values=['c', 'd', 'e'], aggfunc=sum) Out[35]: a b c d e 0 a b 13.00 13 13 1 a dummy 12.30 233 12 2 b a 123.23 123 1 In [36]: df2.pivot_table(rows=['a', 'b'], values=['c', 'd', 'e'], aggfunc=sum).replace('dummy',np.nan) Out[36]: a b c d e 0 a b 13.00 13 13 1 a NaN 12.30 233 12 2 b a 123.23 123 1 </code></pre></div>
1
<p dir="auto">From <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="367497815" data-permission-text="Title is private" data-url="https://github.com/denoland/deno/issues/929" data-hovercard-type="issue" data-hovercard-url="/denoland/deno/issues/929/hovercard" href="https://github.com/denoland/deno/issues/929">#929</a> and <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="384853190" data-permission-text="Title is private" data-url="https://github.com/denoland/deno/issues/1226" data-hovercard-type="issue" data-hovercard-url="/denoland/deno/issues/1226/hovercard" href="https://github.com/denoland/deno/issues/1226">#1226</a>, I believe that the intended behaviour is that extension-less shebang scripts are seen as TypeScript files, but that does not seems to be the case?</p> <p dir="auto">Minimal example:</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-all // filename: hi interface Foo { bar: string; } console.log(&quot;Hi&quot;);"><pre class="notranslate">#!/usr/bin/env -S deno run --allow-all <span class="pl-c">// filename: hi</span> <span class="pl-k">interface</span> <span class="pl-smi">Foo</span> <span class="pl-kos">{</span> <span class="pl-c1">bar</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">"Hi"</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <p dir="auto">Running <code class="notranslate">./hi</code> or <code class="notranslate">deno run hi</code> yields <code class="notranslate">error: Unexpected token `interface`.</code></p>
<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>Apache Airflow version</strong>: 1.10.14</p> <p dir="auto"><strong>Environment</strong>: docker -&gt; FROM python:3.6.8</p> <p dir="auto"><strong>What happened</strong>:</p> <p dir="auto">the webserver at launch crash but do not stop the process. So the container stay up , until I restart</p> <p dir="auto"><strong>What you expected to happen</strong>:</p> <p dir="auto">The process should fail and stop</p> <p dir="auto"><strong>How to reproduce it</strong>:</p> <p dir="auto">When I run <strong>docker-compose up -d</strong> it launch</p> <p dir="auto">1 container for the backend database ( postgre 13.1)<br> 1 container for the webserver<br> 1 container for the scheduler<br> 1 container for the init_db ( only running <strong>airflow db init</strong> )<br> 1 container for the create user ( only running <strong>airflow create_user -r Admin -f admin -l admin -e None -u admin -p admin</strong> )</p> <p dir="auto">If I kill the webserver container and relaunch it , it work well. (So it's apparently a case of when the database is not yet fully setup )</p> <p dir="auto">logs of the webserver</p> <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" [SQL: INSERT INTO ab_permission_view (id, permission_id, view_menu_id) VALUES (nextval('ab_permission_view_id_seq'), %(permission_id)s, %(view_menu_id)s) RETURNING ab_permission_view.id] [parameters: {'permission_id': 84, 'view_menu_id': 96}] (Background on this error at: http://sqlalche.me/e/13/gkpj) [2021-04-09 11:12:38,582] {security.py:210} INFO - Initializing permissions for role:Viewer in the database. Traceback (most recent call last): File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py&quot;, line 1257, in _execute_context cursor, statement, parameters, context File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/dialects/postgresql/psycopg2.py&quot;, line 898, in do_executemany cursor.executemany(statement, parameters) psycopg2.errors.UniqueViolation: duplicate key value violates unique constraint &quot;ab_permission_view_role_permission_view_id_role_id_key&quot; DETAIL: Key (permission_view_id, role_id)=(47, 3) already exists. The above exception was the direct cause of the following exception: Traceback (most recent call last): File &quot;/opt/venv/bin/myflow&quot;, line 8, in &lt;module&gt; sys.exit(main()) File &quot;/opt/venv/lib/python3.6/site-packages/myflow/myflow_cli.py&quot;, line 75, in main args.func(args) File &quot;/opt/venv/lib/python3.6/site-packages/airflow/utils/cli.py&quot;, line 81, in wrapper return f(*args, **kwargs) File &quot;/opt/venv/lib/python3.6/site-packages/airflow/bin/cli.py&quot;, line 1179, in webserver app = cached_app_rbac(None) if settings.RBAC else cached_app(None) File &quot;/opt/venv/lib/python3.6/site-packages/airflow/www_rbac/app.py&quot;, line 297, in cached_app app, _ = create_app(config, session, testing) File &quot;/opt/venv/lib/python3.6/site-packages/airflow/www_rbac/app.py&quot;, line 213, in create_app security_manager.sync_roles() File &quot;/opt/venv/lib/python3.6/site-packages/airflow/www_rbac/security.py&quot;, line 487, in sync_roles self.init_role(role, vms, perms) File &quot;/opt/venv/lib/python3.6/site-packages/airflow/www_rbac/security.py&quot;, line 216, in init_role self.get_session.merge(role) File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/scoping.py&quot;, line 163, in do return getattr(self.registry(), name)(*args, **kwargs) File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py&quot;, line 2160, in merge self._autoflush() File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py&quot;, line 1633, in _autoflush util.raise_(e, with_traceback=sys.exc_info()[2]) File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/util/compat.py&quot;, line 182, in raise_ raise exception File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py&quot;, line 1622, in _autoflush self.flush() File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py&quot;, line 2540, in flush self._flush(objects) File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py&quot;, line 2682, in _flush transaction.rollback(_capture_exception=True) File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/util/langhelpers.py&quot;, line 70, in __exit__ with_traceback=exc_tb, File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/util/compat.py&quot;, line 182, in raise_ raise exception File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py&quot;, line 2642, in _flush flush_context.execute() File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/unitofwork.py&quot;, line 422, in execute rec.execute(self) File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/unitofwork.py&quot;, line 540, in execute self.dependency_processor.process_saves(uow, states) File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/dependency.py&quot;, line 1177, in process_saves uowcommit, secondary_insert, secondary_update, secondary_delete File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/dependency.py&quot;, line 1239, in _run_crud connection.execute(statement, secondary_insert) File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py&quot;, line 1011, in execute return meth(self, multiparams, params) File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/sql/elements.py&quot;, line 298, in _execute_on_connection return connection._execute_clauseelement(self, multiparams, params) File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py&quot;, line 1130, in _execute_clauseelement distilled_params, File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py&quot;, line 1317, in _execute_context e, statement, parameters, cursor, context File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py&quot;, line 1511, in _handle_dbapi_exception sqlalchemy_exception, with_traceback=exc_info[2], from_=e File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/util/compat.py&quot;, line 182, in raise_ raise exception File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py&quot;, line 1257, in _execute_context cursor, statement, parameters, context File &quot;/opt/venv/lib/python3.6/site-packages/sqlalchemy/dialects/postgresql/psycopg2.py&quot;, line 898, in do_executemany cursor.executemany(statement, parameters) sqlalchemy.exc.IntegrityError: (raised as a result of Query-invoked autoflush; consider using a session.no_autoflush block if this flush is occurring prematurely) (psycopg2.errors.UniqueViolation) duplicate key value violates unique constraint &quot;ab_permission_view_role_permission_view_id_role_id_key&quot; DETAIL: Key (permission_view_id, role_id)=(47, 3) already exists. [SQL: INSERT INTO ab_permission_view_role (id, permission_view_id, role_id) VALUES (nextval('ab_permission_view_role_id_seq'), %(permission_view_id)s, %(role_id)s)] [parameters: ({'permission_view_id': 47, 'role_id': 3}, {'permission_view_id': 101, 'role_id': 3}, {'permission_view_id': 57, 'role_id': 3}, {'permission_view_id': 70, 'role_id': 3}, {'permission_view_id': 207, 'role_id': 3}, {'permission_view_id': 167, 'role_id': 3}, {'permission_view_id': 96, 'role_id': 3}, {'permission_view_id': 68, 'role_id': 3} ... displaying 10 of 41 total bound parameter sets ... {'permission_view_id': 161, 'role_id': 3}, {'permission_view_id': 85, 'role_id': 3})] (Background on this error at: http://sqlalche.me/e/13/gkpj) "><pre class="notranslate">[SQL: INSERT INTO ab_permission_view (id, permission_id, view_menu_id) VALUES (nextval(<span class="pl-s"><span class="pl-pds">'</span>ab_permission_view_id_seq<span class="pl-pds">'</span></span>), %(permission_id)s, %(view_menu_id)s) RETURNING ab_permission_view.id] [parameters: {<span class="pl-s"><span class="pl-pds">'</span>permission_id<span class="pl-pds">'</span></span>: 84, <span class="pl-s"><span class="pl-pds">'</span>view_menu_id<span class="pl-pds">'</span></span>: 96}] (Background on this error at: http://sqlalche.me/e/13/gkpj) [2021-04-09 11:12:38,582] {security.py:210} INFO - Initializing permissions <span class="pl-k">for</span> <span class="pl-smi">role:Viewer</span> <span class="pl-k">in</span> the database. Traceback (most recent call last): File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py<span class="pl-pds">"</span></span>, line 1257, <span class="pl-k">in</span> _execute_context cursor, statement, parameters, context File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/dialects/postgresql/psycopg2.py<span class="pl-pds">"</span></span>, line 898, <span class="pl-k">in</span> do_executemany cursor.executemany(statement, parameters) psycopg2.errors.UniqueViolation: duplicate key value violates unique constraint <span class="pl-s"><span class="pl-pds">"</span>ab_permission_view_role_permission_view_id_role_id_key<span class="pl-pds">"</span></span> DETAIL: Key (permission_view_id, role_id)=(47, 3) already exists. The above exception was the direct cause of the following exception: Traceback (most recent call last): File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/bin/myflow<span class="pl-pds">"</span></span>, line 8, <span class="pl-k">in</span> <span class="pl-k">&lt;</span>module<span class="pl-k">&gt;</span> <span class="pl-en">sys.exit(main</span>()) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/myflow/myflow_cli.py<span class="pl-pds">"</span></span>, line 75, <span class="pl-k">in</span> main args.func(args) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/airflow/utils/cli.py<span class="pl-pds">"</span></span>, line 81, <span class="pl-k">in</span> wrapper <span class="pl-k">return</span> f(<span class="pl-k">*</span>args, <span class="pl-k">**</span>kwargs) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/airflow/bin/cli.py<span class="pl-pds">"</span></span>, line 1179, <span class="pl-k">in</span> webserver app = cached_app_rbac(None) <span class="pl-k">if</span> settings.RBAC <span class="pl-k">else</span> cached_app(None) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/airflow/www_rbac/app.py<span class="pl-pds">"</span></span>, line 297, <span class="pl-k">in</span> cached_app app, _ = create_app(config, session, testing) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/airflow/www_rbac/app.py<span class="pl-pds">"</span></span>, line 213, <span class="pl-k">in</span> create_app <span class="pl-en">security_manager.sync_roles</span>() File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/airflow/www_rbac/security.py<span class="pl-pds">"</span></span>, line 487, <span class="pl-k">in</span> sync_roles self.init_role(role, vms, perms) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/airflow/www_rbac/security.py<span class="pl-pds">"</span></span>, line 216, <span class="pl-k">in</span> init_role self.get_session.merge(role) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/scoping.py<span class="pl-pds">"</span></span>, line 163, <span class="pl-k">in</span> <span class="pl-k">do</span> <span class="pl-k">return</span> <span class="pl-en">getattr(self.registry</span>(), name)(<span class="pl-k">*</span>args, <span class="pl-k">**</span>kwargs) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py<span class="pl-pds">"</span></span>, line 2160, <span class="pl-k">in</span> merge <span class="pl-en">self._autoflush</span>() File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py<span class="pl-pds">"</span></span>, line 1633, <span class="pl-k">in</span> _autoflush util.raise_(e, with_traceback=sys.exc_info()[2]) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/util/compat.py<span class="pl-pds">"</span></span>, line 182, <span class="pl-k">in</span> raise_ raise exception File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py<span class="pl-pds">"</span></span>, line 1622, <span class="pl-k">in</span> _autoflush <span class="pl-en">self.flush</span>() File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py<span class="pl-pds">"</span></span>, line 2540, <span class="pl-k">in</span> flush self._flush(objects) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py<span class="pl-pds">"</span></span>, line 2682, <span class="pl-k">in</span> _flush transaction.rollback(_capture_exception=True) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/util/langhelpers.py<span class="pl-pds">"</span></span>, line 70, <span class="pl-k">in</span> __exit__ with_traceback=exc_tb, File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/util/compat.py<span class="pl-pds">"</span></span>, line 182, <span class="pl-k">in</span> raise_ raise exception File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/session.py<span class="pl-pds">"</span></span>, line 2642, <span class="pl-k">in</span> _flush <span class="pl-en">flush_context.execute</span>() File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/unitofwork.py<span class="pl-pds">"</span></span>, line 422, <span class="pl-k">in</span> execute rec.execute(self) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/unitofwork.py<span class="pl-pds">"</span></span>, line 540, <span class="pl-k">in</span> execute self.dependency_processor.process_saves(uow, states) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/dependency.py<span class="pl-pds">"</span></span>, line 1177, <span class="pl-k">in</span> process_saves uowcommit, secondary_insert, secondary_update, secondary_delete File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/orm/dependency.py<span class="pl-pds">"</span></span>, line 1239, <span class="pl-k">in</span> _run_crud connection.execute(statement, secondary_insert) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py<span class="pl-pds">"</span></span>, line 1011, <span class="pl-k">in</span> execute <span class="pl-k">return</span> meth(self, multiparams, params) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/sql/elements.py<span class="pl-pds">"</span></span>, line 298, <span class="pl-k">in</span> _execute_on_connection <span class="pl-k">return</span> connection._execute_clauseelement(self, multiparams, params) File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py<span class="pl-pds">"</span></span>, line 1130, <span class="pl-k">in</span> _execute_clauseelement distilled_params, File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py<span class="pl-pds">"</span></span>, line 1317, <span class="pl-k">in</span> _execute_context e, statement, parameters, cursor, context File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py<span class="pl-pds">"</span></span>, line 1511, <span class="pl-k">in</span> _handle_dbapi_exception sqlalchemy_exception, with_traceback=exc_info[2], from_=e File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/util/compat.py<span class="pl-pds">"</span></span>, line 182, <span class="pl-k">in</span> raise_ raise exception File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/engine/base.py<span class="pl-pds">"</span></span>, line 1257, <span class="pl-k">in</span> _execute_context cursor, statement, parameters, context File <span class="pl-s"><span class="pl-pds">"</span>/opt/venv/lib/python3.6/site-packages/sqlalchemy/dialects/postgresql/psycopg2.py<span class="pl-pds">"</span></span>, line 898, <span class="pl-k">in</span> do_executemany cursor.executemany(statement, parameters) sqlalchemy.exc.IntegrityError: (raised as a result of Query-invoked autoflush<span class="pl-k">;</span> consider using a session.no_autoflush block <span class="pl-k">if</span> this flush is occurring prematurely) (psycopg2.errors.UniqueViolation) duplicate key value violates unique constraint <span class="pl-s"><span class="pl-pds">"</span>ab_permission_view_role_permission_view_id_role_id_key<span class="pl-pds">"</span></span> DETAIL: Key (permission_view_id, role_id)=(47, 3) already exists. [SQL: INSERT INTO ab_permission_view_role (id, permission_view_id, role_id) VALUES (nextval(<span class="pl-s"><span class="pl-pds">'</span>ab_permission_view_role_id_seq<span class="pl-pds">'</span></span>), %(permission_view_id)s, %(role_id)s)] [parameters: ({<span class="pl-s"><span class="pl-pds">'</span>permission_view_id<span class="pl-pds">'</span></span>: 47, <span class="pl-s"><span class="pl-pds">'</span>role_id<span class="pl-pds">'</span></span>: 3}, {<span class="pl-s"><span class="pl-pds">'</span>permission_view_id<span class="pl-pds">'</span></span>: 101, <span class="pl-s"><span class="pl-pds">'</span>role_id<span class="pl-pds">'</span></span>: 3}, {<span class="pl-s"><span class="pl-pds">'</span>permission_view_id<span class="pl-pds">'</span></span>: 57, <span class="pl-s"><span class="pl-pds">'</span>role_id<span class="pl-pds">'</span></span>: 3}, {<span class="pl-s"><span class="pl-pds">'</span>permission_view_id<span class="pl-pds">'</span></span>: 70, <span class="pl-s"><span class="pl-pds">'</span>role_id<span class="pl-pds">'</span></span>: 3}, {<span class="pl-s"><span class="pl-pds">'</span>permission_view_id<span class="pl-pds">'</span></span>: 207, <span class="pl-s"><span class="pl-pds">'</span>role_id<span class="pl-pds">'</span></span>: 3}, {<span class="pl-s"><span class="pl-pds">'</span>permission_view_id<span class="pl-pds">'</span></span>: 167, <span class="pl-s"><span class="pl-pds">'</span>role_id<span class="pl-pds">'</span></span>: 3}, {<span class="pl-s"><span class="pl-pds">'</span>permission_view_id<span class="pl-pds">'</span></span>: 96, <span class="pl-s"><span class="pl-pds">'</span>role_id<span class="pl-pds">'</span></span>: 3}, {<span class="pl-s"><span class="pl-pds">'</span>permission_view_id<span class="pl-pds">'</span></span>: 68, <span class="pl-s"><span class="pl-pds">'</span>role_id<span class="pl-pds">'</span></span>: 3} ... displaying 10 of 41 total bound parameter sets ... {<span class="pl-s"><span class="pl-pds">'</span>permission_view_id<span class="pl-pds">'</span></span>: 161, <span class="pl-s"><span class="pl-pds">'</span>role_id<span class="pl-pds">'</span></span>: 3}, {<span class="pl-s"><span class="pl-pds">'</span>permission_view_id<span class="pl-pds">'</span></span>: 85, <span class="pl-s"><span class="pl-pds">'</span>role_id<span class="pl-pds">'</span></span>: 3})] (Background on this error at: http://sqlalche.me/e/13/gkpj) </pre></div> <p dir="auto">maybe this is a problem already fix with airflow 2.0.0 , in that case I'm sorry for opening this issue :)</p>
<h3 dir="auto">Apache Airflow version</h3> <p dir="auto">2.2.4 (latest released)</p> <h3 dir="auto">What happened</h3> <p dir="auto">I executed the following command <code class="notranslate">pip install apache-airflow -U</code>, to upgrade to the latest version of Airflow.</p> <p dir="auto">This was successful, I can execute <code class="notranslate">airflow info</code> and <code class="notranslate">airflow check</code> returning 2.2.4 and INFO - Connection successful respectively.</p> <p dir="auto">When I run <code class="notranslate">airflow webserver</code>, I receive the following error in the browser:<br> <code class="notranslate">sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) no such table: session [SQL: SELECT session.id AS session_id_1, session.session_id AS session_session_id, session.data AS session_data, session.expiry AS session_expiry FROM session WHERE session.session_id = ? LIMIT ? OFFSET ?] [parameters: ('228b8648-db66-4795-9379-040adb92c08e', 1, 0)] (Background on this error at: http://sqlalche.me/e/13/e3q8)</code></p> <p dir="auto">I have tried</p> <ul dir="auto"> <li>airflow db upgrade</li> <li>airflow db reset</li> </ul> <p dir="auto">Neither correct the error, I am really lost to resolve the error and getting nervous as I need my local working for my job.</p> <p dir="auto">Any help would be most appreciated.</p> <h3 dir="auto">What you expected to happen</h3> <p dir="auto">Airflow to successfully run after installation</p> <h3 dir="auto">How to reproduce</h3> <p dir="auto"><em>No response</em></p> <h3 dir="auto">Operating System</h3> <p dir="auto">macOS</p> <h3 dir="auto">Versions of Apache Airflow Providers</h3> <p dir="auto">apache-airflow-providers-amazon==2.5.0<br> apache-airflow-providers-ftp==2.0.0<br> apache-airflow-providers-http==2.0.0<br> apache-airflow-providers-imap==2.0.0<br> apache-airflow-providers-mysql==2.1.1<br> apache-airflow-providers-sqlite==2.0.0</p> <h3 dir="auto">Deployment</h3> <p dir="auto">Virtualenv installation</p> <h3 dir="auto">Deployment details</h3> <p dir="auto"><em>No response</em></p> <h3 dir="auto">Anything else</h3> <p dir="auto">When running <code class="notranslate">airflow db init</code></p> <p dir="auto">I see the following error<br> <code class="notranslate">sqlalchemy.exc.OperationalError: (sqlite3.OperationalError) duplicate column name: last_scheduling_decision [SQL: ALTER TABLE dag_run ADD COLUMN last_scheduling_decision TIMESTAMP]</code></p> <p dir="auto">When running <code class="notranslate">airflow db reset</code></p> <p dir="auto">I receive the following error:</p> <p dir="auto"><code class="notranslate">sqlite3.OperationalError: table _alembic_tmp_dag already exists</code></p> <h3 dir="auto">Are you willing to submit PR?</h3> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox"> Yes I am willing to submit a PR!</li> </ul> <h3 dir="auto">Code of Conduct</h3> <ul class="contains-task-list"> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> I agree to follow this project's <a href="https://github.com/apache/airflow/blob/main/CODE_OF_CONDUCT.md">Code of Conduct</a></li> </ul>
0
<p dir="auto">such as:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="const str = `bar/*`"><pre class="notranslate"><span class="pl-k">const</span> <span class="pl-s1">str</span> <span class="pl-c1">=</span> <span class="pl-s">`bar/*`</span></pre></div>
<p dir="auto">Right now, those keywords like <code class="notranslate">import</code> <code class="notranslate">class</code> <code class="notranslate">from</code> are all plain white.</p>
1
<p dir="auto">Hi,<br> sorry if this is the wrong place to ask for this.</p> <p dir="auto">It is really awesome that VS Code is now open-source. Some time ago I created a issue in the TypeScript repo (<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="112100558" data-permission-text="Title is private" data-url="https://github.com/microsoft/TypeScript/issues/5324" data-hovercard-type="issue" data-hovercard-url="/microsoft/TypeScript/issues/5324/hovercard" href="https://github.com/microsoft/TypeScript/issues/5324">microsoft/TypeScript#5324</a>) asking if it'd be possible to embed the Monaco Editor (as used in the <a href="http://www.typescriptlang.org/Playground" rel="nofollow">TypeScript Playground</a>) into your own HTML pages.</p> <p dir="auto">I'd like to:</p> <ul dir="auto"> <li>Show the Monaco editor in the HTML page using the Typescript Language Service.</li> <li>Specify the initial TypeScript editor contents and my own .d.ts definition files to be used by the TS Language Service.</li> <li>Get the displayed TypeScript and the transpiled Javascript when e.g. a button is clicked.</li> <li>Be able to dispose of the editor when e.g. another button is clicked.</li> </ul> <p dir="auto">So I'd like to use the editor similar to the Typescript Playground, with the difference that I would specify my own .d.ts files and to not have a JavaScript editor at the right-hand side.<br> However I don't know how to do this correctly.</p> <p dir="auto">I checked out the vscode repository and invoked tsc in the <a href="https://github.com/Microsoft/vscode/tree/master/src">src folder</a>. Then I created a HTML page in that folder using the TS playground as a template:</p> <div class="highlight highlight-text-html-basic notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&lt;!DOCTYPE html&gt; &lt;html&gt; &lt;head&gt; &lt;meta charset=&quot;UTF-8&quot; /&gt; &lt;script type=&quot;text/javascript&quot; src=&quot;https://code.jquery.com/jquery-2.1.4.min.js&quot;&gt;&lt;/script&gt; &lt;/head&gt; &lt;body&gt; &lt;h1&gt;Test Monaco&lt;/h1&gt; &lt;div id=&quot;typescriptEditor&quot;&gt;&lt;/div&gt; &lt;script type=&quot;text/javascript&quot;&gt; var require = { baseUrl: &quot;/&quot; }; &lt;/script&gt; &lt;script type=&quot;text/javascript&quot; src=&quot;vs/loader.js&quot;&gt;&lt;/script&gt; &lt;script type=&quot;text/javascript&quot; src=&quot;vs/editor/editor.main.js&quot;&gt;&lt;/script&gt; &lt;script type=&quot;text/javascript&quot;&gt; if (!window.console.info) { window.console.info = function(){} } (function () { 'use strict'; var domnode = document.getElementById('typescriptEditor') var typescriptMode = null; require(['vs/editor/editor.main'], function () { Monaco.Editor.getOrCreateMode('text/typescript').then(function (mode) { typescriptMode = mode; var editor = Monaco.Editor.create(domnode, { value: '', mode: 'text/plain', fontIsMonospace: true, suggestOnTriggerCharacters: true, showTypeScriptWarnings: false }); }); }); })(); &lt;/script&gt; &lt;/body&gt; &lt;/html&gt;"><pre class="notranslate"><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>" /&gt; <span class="pl-kos">&lt;</span><span class="pl-ent">script</span> <span class="pl-c1">type</span>="<span class="pl-s">text/javascript</span>" <span class="pl-c1">src</span>="<span class="pl-s">https://code.jquery.com/jquery-2.1.4.min.js</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">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">h1</span><span class="pl-kos">&gt;</span>Test Monaco<span class="pl-kos">&lt;/</span><span class="pl-ent">h1</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">id</span>="<span class="pl-s">typescriptEditor</span>"<span class="pl-kos">&gt;</span><span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">script</span> <span class="pl-c1">type</span>="<span class="pl-s">text/javascript</span>"<span class="pl-kos">&gt;</span> <span class="pl-k">var</span> <span class="pl-s1">require</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span> <span class="pl-c1">baseUrl</span>: <span class="pl-s">"/"</span> <span class="pl-kos">}</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">type</span>="<span class="pl-s">text/javascript</span>" <span class="pl-c1">src</span>="<span class="pl-s">vs/loader.js</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">script</span> <span class="pl-c1">type</span>="<span class="pl-s">text/javascript</span>" <span class="pl-c1">src</span>="<span class="pl-s">vs/editor/editor.main.js</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">script</span> <span class="pl-c1">type</span>="<span class="pl-s">text/javascript</span>"<span class="pl-kos">&gt;</span> <span class="pl-k">if</span> <span class="pl-kos">(</span><span class="pl-c1">!</span><span class="pl-smi">window</span><span class="pl-kos">.</span><span class="pl-c1">console</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-smi">window</span><span class="pl-kos">.</span><span class="pl-c1">console</span><span class="pl-kos">.</span><span class="pl-en">info</span> <span class="pl-c1">=</span> <span class="pl-k">function</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">function</span> <span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-s">'use strict'</span><span class="pl-kos">;</span> <span class="pl-k">var</span> <span class="pl-s1">domnode</span> <span class="pl-c1">=</span> <span class="pl-smi">document</span><span class="pl-kos">.</span><span class="pl-en">getElementById</span><span class="pl-kos">(</span><span class="pl-s">'typescriptEditor'</span><span class="pl-kos">)</span> <span class="pl-k">var</span> <span class="pl-s1">typescriptMode</span> <span class="pl-c1">=</span> <span class="pl-c1">null</span><span class="pl-kos">;</span> <span class="pl-en">require</span><span class="pl-kos">(</span><span class="pl-kos">[</span><span class="pl-s">'vs/editor/editor.main'</span><span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-k">function</span> <span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-v">Monaco</span><span class="pl-kos">.</span><span class="pl-c1">Editor</span><span class="pl-kos">.</span><span class="pl-en">getOrCreateMode</span><span class="pl-kos">(</span><span class="pl-s">'text/typescript'</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">then</span><span class="pl-kos">(</span><span class="pl-k">function</span> <span class="pl-kos">(</span><span class="pl-s1">mode</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-s1">typescriptMode</span> <span class="pl-c1">=</span> <span class="pl-s1">mode</span><span class="pl-kos">;</span> <span class="pl-k">var</span> <span class="pl-s1">editor</span> <span class="pl-c1">=</span> <span class="pl-v">Monaco</span><span class="pl-kos">.</span><span class="pl-c1">Editor</span><span class="pl-kos">.</span><span class="pl-en">create</span><span class="pl-kos">(</span><span class="pl-s1">domnode</span><span class="pl-kos">,</span> <span class="pl-kos">{</span> <span class="pl-c1">value</span>: <span class="pl-s">''</span><span class="pl-kos">,</span> <span class="pl-c1">mode</span>: <span class="pl-s">'text/plain'</span><span class="pl-kos">,</span> <span class="pl-c1">fontIsMonospace</span>: <span class="pl-c1">true</span><span class="pl-kos">,</span> <span class="pl-c1">suggestOnTriggerCharacters</span>: <span class="pl-c1">true</span><span class="pl-kos">,</span> <span class="pl-c1">showTypeScriptWarnings</span>: <span class="pl-c1">false</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-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">&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">However, when hosting the directory in IIS Express and opening the HTML file in a browser, I'm getting errors such as</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="GET http://localhost:8080/vs/editor/contrib/comment/common/color.css [HTTP/1.1 404 Not Found 16ms] GET http://localhost:8080/vs/editor/contrib/inPlaceReplace/common/gotoError.css [HTTP/1.1 404 Not Found 13ms] GET http://localhost:8080/vs/editor/contrib/referenceSearch/browser/rename.css [HTTP/1.1 404 Not Found 125ms] TypeError: Browser.isInWebWorker is not a function browserService.js:25:17 TypeError: nls.localize is not a function pluginsRegistry.js:330:30 TypeError: EditorCommon.LineTokensBinaryEncoding is undefined tokenIterator.js:7:9"><pre class="notranslate"><code class="notranslate">GET http://localhost:8080/vs/editor/contrib/comment/common/color.css [HTTP/1.1 404 Not Found 16ms] GET http://localhost:8080/vs/editor/contrib/inPlaceReplace/common/gotoError.css [HTTP/1.1 404 Not Found 13ms] GET http://localhost:8080/vs/editor/contrib/referenceSearch/browser/rename.css [HTTP/1.1 404 Not Found 125ms] TypeError: Browser.isInWebWorker is not a function browserService.js:25:17 TypeError: nls.localize is not a function pluginsRegistry.js:330:30 TypeError: EditorCommon.LineTokensBinaryEncoding is undefined tokenIterator.js:7:9 </code></pre></div> <p dir="auto">Can anybody give me some pointers how to embed the editor correctly using the TS service?</p> <p dir="auto">Thank you!</p>
<p dir="auto">Now that VS Code is open source, it also means that the <a href="https://github.com/Microsoft/vscode/tree/master/src/vs/editor">Monaco Editor is open source</a> <em>(at-least to some extent)</em>.</p> <p dir="auto">I would really like to use this editor in my own web application for editing TypeScript files. The only problem is I can't find any documentation about how to do this. I know its possible because the editor is on <a href="http://www.typescriptlang.org/Playground" rel="nofollow">TypeScript Playground</a> and <a href="http://www.hanselman.com/blog/ARichNewJavaScriptCodeEditorSpreadingToSeveralMicrosoftWebSites.aspx" rel="nofollow">a few other places</a>.</p> <p dir="auto">As far as I can tell, the open sourcing of VS Code is the first time the source code of the Monaco editor has been made public. Also, I think that the VS Code repository is the primary source of the Monaco editor <em>(someone from Microsoft please confirm?)</em>.</p> <p dir="auto">So far, there have been many questions about using the Monaco Editor on Stack Overflow and other forums, but I have yet to see an official reply from Microsoft.</p> <p dir="auto"><strong>Can someone please provide some documentation on using the Monaco Editor in a web site, or perhaps release the source code of TypeScript Playground</strong> <em>(There is nothing to hide now that we have the Monaco source in the VS Code repository)</em>.</p> <p dir="auto">Currently, the only thing keeping me from using TypeScript as a JavaScript replacement is the fact that I can't easily use the Monaco Editor inside of my web application. I'm currently using the ACE Editor with a <a href="http://sevin7676.github.io/Ace.Tern/demo.html#javascript" rel="nofollow">Tern plugin I created</a>. I don't want to go through all of the work of creating full Intellisense support for TypeScript inside of ACE because its a significant undertaking- Instead I'd rather contribute to the Monaco editor and use it as a replacement for ACE (and replace JavaScript with TypeScript).</p>
1
<h3 dir="auto">Expected Behavior</h3> <p dir="auto">auto_pop of the request context should be executed regardless of whether an exception happened after pushing the context(for example, when opening a session).</p> <p dir="auto">We're using Redis sessions from flask_session:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="def _setup_session(app): from util.cache.region import cache_region from dogpile.cache.backends.null import NullBackend from flask_session import RedisSessionInterface if not isinstance(cache_region.backend, NullBackend): redis = cache_region.backend.client session_interface = RedisSessionInterface(redis, 'test.session.', use_signer=False, permanent=False) app.session_interface = session_interface"><pre class="notranslate"><span class="pl-k">def</span> <span class="pl-en">_setup_session</span>(<span class="pl-s1">app</span>): <span class="pl-k">from</span> <span class="pl-s1">util</span>.<span class="pl-s1">cache</span>.<span class="pl-s1">region</span> <span class="pl-k">import</span> <span class="pl-s1">cache_region</span> <span class="pl-k">from</span> <span class="pl-s1">dogpile</span>.<span class="pl-s1">cache</span>.<span class="pl-s1">backends</span>.<span class="pl-s1">null</span> <span class="pl-k">import</span> <span class="pl-v">NullBackend</span> <span class="pl-k">from</span> <span class="pl-s1">flask_session</span> <span class="pl-k">import</span> <span class="pl-v">RedisSessionInterface</span> <span class="pl-k">if</span> <span class="pl-c1">not</span> <span class="pl-en">isinstance</span>(<span class="pl-s1">cache_region</span>.<span class="pl-s1">backend</span>, <span class="pl-v">NullBackend</span>): <span class="pl-s1">redis</span> <span class="pl-c1">=</span> <span class="pl-s1">cache_region</span>.<span class="pl-s1">backend</span>.<span class="pl-s1">client</span> <span class="pl-s1">session_interface</span> <span class="pl-c1">=</span> <span class="pl-v">RedisSessionInterface</span>(<span class="pl-s1">redis</span>, <span class="pl-s">'test.session.'</span>, <span class="pl-s1">use_signer</span><span class="pl-c1">=</span><span class="pl-c1">False</span>, <span class="pl-s1">permanent</span><span class="pl-c1">=</span><span class="pl-c1">False</span>) <span class="pl-s1">app</span>.<span class="pl-s1">session_interface</span> <span class="pl-c1">=</span> <span class="pl-s1">session_interface</span></pre></div> <h3 dir="auto">Actual Behavior</h3> <p dir="auto">The request context is not popped whenever there is a timeout getting the session from Redis.<br> We can see in following requests the 'g' object still holds information from the failing request.</p> <p dir="auto">In ctx.py the context is first pushed and then the session is opened:</p> <div class="highlight highlight-text-python-traceback notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" _request_ctx_stack.push(self) # Open the session at the moment that the request context is # available. This allows a custom open_session method to use the # request context (e.g. code that access database information # stored on `g` instead of the appcontext). self.session = self.app.open_session(self.request)"><pre class="notranslate"> _request_ctx_stack.push(<span class="pl-c1">self</span>) <span class="pl-c"><span class="pl-c">#</span> Open the session at the moment that the request context is</span> <span class="pl-c"><span class="pl-c">#</span> available. This allows a custom open_session method to use the</span> <span class="pl-c"><span class="pl-c">#</span> request context (e.g. code that access database information</span> <span class="pl-c"><span class="pl-c">#</span> stored on `g` instead of the appcontext).</span> <span class="pl-c1">self</span>.session <span class="pl-k">=</span> <span class="pl-c1">self</span>.app.open_session(<span class="pl-c1">self</span>.request)</pre></div> <p dir="auto">But if open_session() fails, then ctx.auto_pop() is not executed. Perhaps ctx.push() should also be under the try...finally block in app.py?</p> <p dir="auto">This is the exception that triggers the context not to be popped:</p> <div class="highlight highlight-text-python-traceback notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="redis.exceptions:TimeoutError: Timeout reading from socket Traceback (most recent call last): File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/newrelic-2.74.0.54/newrelic/api/web_transaction.py&quot;, line 738, in __iter__ File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/newrelic-2.74.0.54/newrelic/api/web_transaction.py&quot;, line 1114, in __call__ File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/werkzeug/contrib/fixers.py&quot;, line 152, in __call__ File &quot;/var/www/censored_production/www/censored/util/logging.py&quot;, line 136, in __call__ File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/flask/app.py&quot;, line 1813, in wsgi_app File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/flask/ctx.py&quot;, line 321, in push File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/flask/app.py&quot;, line 825, in open_session File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/flask_session/sessions.py&quot;, line 132, in open_session File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/newrelic-2.74.0.54/newrelic/hooks/datastore_redis.py&quot;, line 67, in _nr_wrapper_Redis_method_ File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/redis/client.py&quot;, line 880, in get File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/redis/client.py&quot;, line 573, in execute_command File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/redis/client.py&quot;, line 585, in parse_response File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/redis/connection.py&quot;, line 577, in read_response File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/redis/connection.py&quot;, line 238, in read_response File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/redis/connection.py&quot;, line 168, in readline File &quot;/var/www/censored_production/env/lib/python2.7/site-packages/redis/connection.py&quot;, line 139, in _read_from_socket"><pre class="notranslate">redis.exceptions:TimeoutError: Timeout reading from socket Traceback (most recent call last): File "/var/www/censored_production/env/lib/python2.7/site-packages/newrelic-2.74.0.54/newrelic/api/web_transaction.py", line 738, in __iter__ File "/var/www/censored_production/env/lib/python2.7/site-packages/newrelic-2.74.0.54/newrelic/api/web_transaction.py", line 1114, in __call__ File "/var/www/censored_production/env/lib/python2.7/site-packages/werkzeug/contrib/fixers.py", line 152, in __call__ File "/var/www/censored_production/www/censored/util/logging.py", line 136, in __call__ File "/var/www/censored_production/env/lib/python2.7/site-packages/flask/app.py", line 1813, in wsgi_app File "/var/www/censored_production/env/lib/python2.7/site-packages/flask/ctx.py", line 321, in push File "/var/www/censored_production/env/lib/python2.7/site-packages/flask/app.py", line 825, in open_session File "/var/www/censored_production/env/lib/python2.7/site-packages/flask_session/sessions.py", line 132, in open_session File "/var/www/censored_production/env/lib/python2.7/site-packages/newrelic-2.74.0.54/newrelic/hooks/datastore_redis.py", line 67, in _nr_wrapper_Redis_method_ File "/var/www/censored_production/env/lib/python2.7/site-packages/redis/client.py", line 880, in get File "/var/www/censored_production/env/lib/python2.7/site-packages/redis/client.py", line 573, in execute_command File "/var/www/censored_production/env/lib/python2.7/site-packages/redis/client.py", line 585, in parse_response File "/var/www/censored_production/env/lib/python2.7/site-packages/redis/connection.py", line 577, in read_response File "/var/www/censored_production/env/lib/python2.7/site-packages/redis/connection.py", line 238, in read_response File "/var/www/censored_production/env/lib/python2.7/site-packages/redis/connection.py", line 168, in readline File "/var/www/censored_production/env/lib/python2.7/site-packages/redis/connection.py", line 139, in _read_from_socket</pre></div> <h3 dir="auto">Environment</h3> <ul dir="auto"> <li>Python version: 2.7.6</li> <li>Flask version: 0.10.1</li> <li>Werkzeug version: 0.11.11</li> </ul>
<p dir="auto">RequestContext push is called in <a href="https://github.com/mitsuhiko/flask/blob/master/flask/app.py#L1952">wsgi_app method</a>, outside try..finally block. In <a href="https://github.com/mitsuhiko/flask/blob/master/flask/ctx.py#L332">push() method</a> application's open_session call takes place, which can possibly lead to exception. But, since original call is not in try..finally block, removal of stack top never takes place. This leads to following problems:</p> <h3 dir="auto">1. Application context stack never updates again</h3> <p dir="auto">RequestContext.push() only <a href="https://github.com/mitsuhiko/flask/blob/master/flask/ctx.py#L316">checks</a> that application context exists or belongs to current application, but same rules apply to previous context.</p> <h3 dir="auto">2. Request context stack grows</h3> <p dir="auto">Again, request context stack is pushed, but never removed. Actually just a memory leak :)</p> <h3 dir="auto">3. Misleading code comment about open_session usage</h3> <p dir="auto">Inspired by <a href="https://github.com/mitsuhiko/flask/blob/master/flask/ctx.py#L328">this comment</a>, i started to develop multi-tenant application, and found nothing but disappointment. <strong>You can't actually access request_context before open_session interface call.</strong> This means, you can't configure which database to use before opening a session.</p> <h2 dir="auto">My proposition.</h2> <p dir="auto">Move open_session call to full_dispatch_request, and add interfaces and methods, similar to before_request - before_open_session, or call before_request before opening session (may break code that depends on session interface)</p>
1
<p dir="auto">i am trying to render a header into the existing header by creating a div into the table</p> <p dir="auto">HTML Code</p> <div class="highlight highlight-text-html-basic notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&lt;table &lt;div id=&quot;container&quot;&gt;&lt;/div&gt; &lt;tr&gt;&lt;th/&gt;&lt;th/&gt;....&lt;th/&gt;&lt;/tr&gt;------&gt; deleting this row when my header is getting rendered &lt;tr&gt;&lt;td/&gt;&lt;td/&gt;....&lt;td/&gt;&lt;/td&gt; &lt;/table&gt;"><pre class="notranslate"><span class="pl-kos">&lt;</span><span class="pl-ent">table</span><span class="pl-kos"></span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">id</span>="<span class="pl-s">container</span>"<span class="pl-kos">&gt;</span><span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">tr</span><span class="pl-kos">&gt;</span><span class="pl-kos">&lt;</span><span class="pl-ent">th</span>/&gt;<span class="pl-kos">&lt;</span><span class="pl-ent">th</span>/&gt;....<span class="pl-kos">&lt;</span><span class="pl-ent">th</span>/&gt;<span class="pl-kos">&lt;/</span><span class="pl-ent">tr</span><span class="pl-kos">&gt;</span>------<span class="pl-kos">&gt;</span> deleting this row when my header is getting rendered <span class="pl-kos">&lt;</span><span class="pl-ent">tr</span><span class="pl-kos">&gt;</span><span class="pl-kos">&lt;</span><span class="pl-ent">td</span>/&gt;<span class="pl-kos">&lt;</span><span class="pl-ent">td</span>/&gt;....<span class="pl-kos">&lt;</span><span class="pl-ent">td</span>/&gt;<span class="pl-kos">&lt;/</span><span class="pl-ent">td</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">table</span><span class="pl-kos">&gt;</span></pre></div> <p dir="auto">Script</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="var StickyDiv = React.createClass({ mixins: [SimplePageScrollMixin, SimpleResizeMixin], displayName:&quot;StickyDiv&quot;, propTypes:{ offsetTop: React.PropTypes.number, zIndex: React.PropTypes.number, className: React.PropTypes.string }, getInitialState : function(){ return { fix: false, width: null }; }, getDefaultProps: function() { return { offsetTop: 38, className: '', zIndex: 9999 }; }, handleResize : function(){ this.checkWidth(); this.checkPositions(); }, handleScroll: function () { this.checkWidth(); this.checkPositions(); }, checkPositions: function(){ var pos; if('findDOMNode' in React){ pos = util.findPosRelativeToViewport(React.findDOMNode(this)); } else { pos = util.findPosRelativeToViewport(this.getDOMNode()); } if (pos[1] &lt;=this.props.offsetTop){ this.setState({fix: true}); } else { this.setState({fix: false}); } }, checkWidth: function () { var width = null; if (this.refs.duplicate) { if('findDOMNode' in React){ width = React.findDOMNode(this.refs.duplicate).getBoundingClientRect().width; } else { width = this.refs.duplicate.getDOMNode().getBoundingClientRect().width; } } else { if('findDOMNode' in React){ width = React.findDOMNode(this.refs.original).getBoundingClientRect().width; } else { width = this.refs.original.getDOMNode().getBoundingClientRect().width; } } if (this.state.width !== width) { this.setState({ width: width }); } }, componentDidMount: function () { this.checkWidth(); }, render: function () { var divStyle; if (this.state.fix) { divStyle = { display: 'block', position: 'fixed', width: this.state.width ? (this.state.width + 'px') : null, top: this.props.offsetTop, content: &quot;text/html&quot; }; return ( React.createElement(&quot;div&quot;, {style: {zIndex : this.props.zIndex, position:'relative', width:'100%'}}, React.createElement(&quot;div&quot;, {ref: &quot;duplicate&quot;, key: &quot;duplicate&quot;, style: {visibility:'hidden'}}, this.props.children ), React.createElement(&quot;div&quot;, {ref: &quot;original&quot;, key: &quot;original&quot;, style: divStyle}, this.props.children ) )); } else { divStyle = { display: 'block', position: 'relative', width:'100%' }; return ( React.createElement(&quot;div&quot;, {style: {zIndex : this.props.zIndex, position:'relative', width:'100%'}}, React.createElement(&quot;div&quot;, {ref: &quot;original&quot;, key: &quot;original&quot;, style: divStyle}, this.props.children ) )); } } }); MyComponent = React.createClass({displayName: &quot;MyComponent&quot;, getInitialState: function() { return { isSelected: false }; }, render: function() { var myVar = &quot;&lt;%= request.getAttribute(&quot;xxxx&quot;) %&gt;&quot; return ( React.createElement(StickyDiv, null, React.createElement(&quot;table&quot;,{className: &quot;&quot;, cellSpacing: &quot;0&quot;, cellPadding: &quot;0&quot;, border: &quot;0&quot;, width: &quot;100%&quot;}, React.createElement(&quot;tr&quot;, null, React.createElement(&quot;th&quot;, {valign:'middle', align:'left', width:'3%'},React.createElement(&quot;img&quot;, {src: &quot;&lt;%=appRoot%&gt;/common/images/icon_confirm.gif&quot;, className: &quot;recentlyProcessedIcon&quot;})), React.createElement(&quot;th&quot;, {width:'23%'},React.createElement(&quot;span&quot;, null,&quot;second coloumn&quot;)), React.createElement(&quot;th&quot;, {width:'9%'},React.createElement(&quot;span&quot;, {nowrap:true},&quot;third coloumn &quot;)), React.createElement(&quot;th&quot;, {width:'12%'},React.createElement(&quot;span&quot;, null,&quot;fourth coloumn&quot;)), React.createElement(&quot;th&quot;, {width:'11.5%'},React.createElement(&quot;span&quot;, null,&quot;fifith&quot;)), React.createElement(&quot;th&quot;, {width:'10.5%'},React.createElement(&quot;span&quot;,null,&quot;sixth&quot;)), React.createElement(&quot;th&quot;, {width:'3%',valign:'middle'},React.createElement(&quot;span&quot;, null,&quot;seventh&quot;)) ) ))); }}); React.render(React.createElement(MyComponent, null), document.getElementById('container') );"><pre class="notranslate"><span class="pl-k">var</span> <span class="pl-v">StickyDiv</span> <span class="pl-c1">=</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createClass</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">mixins</span>: <span class="pl-kos">[</span><span class="pl-v">SimplePageScrollMixin</span><span class="pl-kos">,</span> <span class="pl-v">SimpleResizeMixin</span><span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-c1">displayName</span>:<span class="pl-s">"StickyDiv"</span><span class="pl-kos">,</span> <span class="pl-c1">propTypes</span>:<span class="pl-kos">{</span> <span class="pl-c1">offsetTop</span>: <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-c1">PropTypes</span><span class="pl-kos">.</span><span class="pl-c1">number</span><span class="pl-kos">,</span> <span class="pl-c1">zIndex</span>: <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-c1">PropTypes</span><span class="pl-kos">.</span><span class="pl-c1">number</span><span class="pl-kos">,</span> <span class="pl-c1">className</span>: <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-c1">PropTypes</span><span class="pl-kos">.</span><span class="pl-c1">string</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-en">getInitialState</span> : <span class="pl-k">function</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">{</span> <span class="pl-c1">fix</span>: <span class="pl-c1">false</span><span class="pl-kos">,</span> <span class="pl-c1">width</span>: <span class="pl-c1">null</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">getDefaultProps</span>: <span class="pl-k">function</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">{</span> <span class="pl-c1">offsetTop</span>: <span class="pl-c1">38</span><span class="pl-kos">,</span> <span class="pl-c1">className</span>: <span class="pl-s">''</span><span class="pl-kos">,</span> <span class="pl-c1">zIndex</span>: <span class="pl-c1">9999</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">handleResize</span> : <span class="pl-k">function</span><span class="pl-kos">(</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">checkWidth</span><span class="pl-kos">(</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">checkPositions</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">handleScroll</span>: <span class="pl-k">function</span> <span class="pl-kos">(</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">checkWidth</span><span class="pl-kos">(</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">checkPositions</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">checkPositions</span>: <span class="pl-k">function</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">{</span> <span class="pl-k">var</span> <span class="pl-s1">pos</span><span class="pl-kos">;</span> <span class="pl-k">if</span><span class="pl-kos">(</span><span class="pl-s">'findDOMNode'</span> <span class="pl-k">in</span> <span class="pl-v">React</span><span class="pl-kos">)</span><span class="pl-kos">{</span> <span class="pl-s1">pos</span> <span class="pl-c1">=</span> <span class="pl-s1">util</span><span class="pl-kos">.</span><span class="pl-en">findPosRelativeToViewport</span><span class="pl-kos">(</span><span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">findDOMNode</span><span class="pl-kos">(</span><span class="pl-smi">this</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">else</span> <span class="pl-kos">{</span> <span class="pl-s1">pos</span> <span class="pl-c1">=</span> <span class="pl-s1">util</span><span class="pl-kos">.</span><span class="pl-en">findPosRelativeToViewport</span><span class="pl-kos">(</span><span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-en">getDOMNode</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">if</span> <span class="pl-kos">(</span><span class="pl-s1">pos</span><span class="pl-kos">[</span><span class="pl-c1">1</span><span class="pl-kos">]</span> <span class="pl-c1">&lt;=</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">offsetTop</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">fix</span>: <span class="pl-c1">true</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">else</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">fix</span>: <span class="pl-c1">false</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">checkWidth</span>: <span class="pl-k">function</span> <span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">var</span> <span class="pl-s1">width</span> <span class="pl-c1">=</span> <span class="pl-c1">null</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">refs</span><span class="pl-kos">.</span><span class="pl-c1">duplicate</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-s">'findDOMNode'</span> <span class="pl-k">in</span> <span class="pl-v">React</span><span class="pl-kos">)</span><span class="pl-kos">{</span> <span class="pl-s1">width</span> <span class="pl-c1">=</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">findDOMNode</span><span class="pl-kos">(</span><span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">refs</span><span class="pl-kos">.</span><span class="pl-c1">duplicate</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">getBoundingClientRect</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-c1">width</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-k">else</span> <span class="pl-kos">{</span> <span class="pl-s1">width</span> <span class="pl-c1">=</span> <span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">refs</span><span class="pl-kos">.</span><span class="pl-c1">duplicate</span><span class="pl-kos">.</span><span class="pl-en">getDOMNode</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">getBoundingClientRect</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-c1">width</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-k">else</span> <span class="pl-kos">{</span> <span class="pl-k">if</span><span class="pl-kos">(</span><span class="pl-s">'findDOMNode'</span> <span class="pl-k">in</span> <span class="pl-v">React</span><span class="pl-kos">)</span><span class="pl-kos">{</span> <span class="pl-s1">width</span> <span class="pl-c1">=</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">findDOMNode</span><span class="pl-kos">(</span><span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">refs</span><span class="pl-kos">.</span><span class="pl-c1">original</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">getBoundingClientRect</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-c1">width</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-k">else</span> <span class="pl-kos">{</span> <span class="pl-s1">width</span> <span class="pl-c1">=</span> <span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">refs</span><span class="pl-kos">.</span><span class="pl-c1">original</span><span class="pl-kos">.</span><span class="pl-en">getDOMNode</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">getBoundingClientRect</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-c1">width</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">width</span> <span class="pl-c1">!==</span> <span class="pl-s1">width</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">width</span>: <span class="pl-s1">width</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">componentDidMount</span>: <span class="pl-k">function</span> <span class="pl-kos">(</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">checkWidth</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-k">function</span> <span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">var</span> <span class="pl-s1">divStyle</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">fix</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-s1">divStyle</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span> <span class="pl-c1">display</span>: <span class="pl-s">'block'</span><span class="pl-kos">,</span> <span class="pl-c1">position</span>: <span class="pl-s">'fixed'</span><span class="pl-kos">,</span> <span class="pl-c1">width</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">width</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">width</span> <span class="pl-c1">+</span> <span class="pl-s">'px'</span><span class="pl-kos">)</span> : <span class="pl-c1">null</span><span class="pl-kos">,</span> <span class="pl-c1">top</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">offsetTop</span><span class="pl-kos">,</span> <span class="pl-c1">content</span>: <span class="pl-s">"text/html"</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-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"div"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">style</span>: <span class="pl-kos">{</span><span class="pl-c1">zIndex</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">zIndex</span><span class="pl-kos">,</span> <span class="pl-c1">position</span>:<span class="pl-s">'relative'</span><span class="pl-kos">,</span> <span class="pl-c1">width</span>:<span class="pl-s">'100%'</span><span class="pl-kos">}</span><span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"div"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">ref</span>: <span class="pl-s">"duplicate"</span><span class="pl-kos">,</span> <span class="pl-c1">key</span>: <span class="pl-s">"duplicate"</span><span class="pl-kos">,</span> <span class="pl-c1">style</span>: <span class="pl-kos">{</span><span class="pl-c1">visibility</span>:<span class="pl-s">'hidden'</span><span class="pl-kos">}</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-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-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"div"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">ref</span>: <span class="pl-s">"original"</span><span class="pl-kos">,</span> <span class="pl-c1">key</span>: <span class="pl-s">"original"</span><span class="pl-kos">,</span> <span class="pl-c1">style</span>: <span class="pl-s1">divStyle</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-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><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-k">else</span> <span class="pl-kos">{</span> <span class="pl-s1">divStyle</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span> <span class="pl-c1">display</span>: <span class="pl-s">'block'</span><span class="pl-kos">,</span> <span class="pl-c1">position</span>: <span class="pl-s">'relative'</span><span class="pl-kos">,</span> <span class="pl-c1">width</span>:<span class="pl-s">'100%'</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-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"div"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">style</span>: <span class="pl-kos">{</span><span class="pl-c1">zIndex</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">zIndex</span><span class="pl-kos">,</span> <span class="pl-c1">position</span>:<span class="pl-s">'relative'</span><span class="pl-kos">,</span> <span class="pl-c1">width</span>:<span class="pl-s">'100%'</span><span class="pl-kos">}</span><span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"div"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">ref</span>: <span class="pl-s">"original"</span><span class="pl-kos">,</span> <span class="pl-c1">key</span>: <span class="pl-s">"original"</span><span class="pl-kos">,</span> <span class="pl-c1">style</span>: <span class="pl-s1">divStyle</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-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><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-v">MyComponent</span> <span class="pl-c1">=</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createClass</span><span class="pl-kos">(</span><span class="pl-kos">{</span><span class="pl-c1">displayName</span>: <span class="pl-s">"MyComponent"</span><span class="pl-kos">,</span> <span class="pl-en">getInitialState</span>: <span class="pl-k">function</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">{</span> <span class="pl-c1">isSelected</span>: <span class="pl-c1">false</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-k">function</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">var</span> <span class="pl-s1">myVar</span> <span class="pl-c1">=</span> <span class="pl-s">"&lt;%= request.getAttribute("</span><span class="pl-s1">xxxx</span><span class="pl-s">") %&gt;"</span> <span class="pl-k">return</span> <span class="pl-kos">(</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-v">StickyDiv</span><span class="pl-kos">,</span> <span class="pl-c1">null</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"table"</span><span class="pl-kos">,</span><span class="pl-kos">{</span><span class="pl-c1">className</span>: <span class="pl-s">""</span><span class="pl-kos">,</span> <span class="pl-c1">cellSpacing</span>: <span class="pl-s">"0"</span><span class="pl-kos">,</span> <span class="pl-c1">cellPadding</span>: <span class="pl-s">"0"</span><span class="pl-kos">,</span> <span class="pl-c1">border</span>: <span class="pl-s">"0"</span><span class="pl-kos">,</span> <span class="pl-c1">width</span>: <span class="pl-s">"100%"</span><span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"tr"</span><span class="pl-kos">,</span> <span class="pl-c1">null</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"th"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">valign</span>:<span class="pl-s">'middle'</span><span class="pl-kos">,</span> <span class="pl-c1">align</span>:<span class="pl-s">'left'</span><span class="pl-kos">,</span> <span class="pl-c1">width</span>:<span class="pl-s">'3%'</span><span class="pl-kos">}</span><span class="pl-kos">,</span><span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"img"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">src</span>: <span class="pl-s">"&lt;%=appRoot%&gt;/common/images/icon_confirm.gif"</span><span class="pl-kos">,</span> <span class="pl-c1">className</span>: <span class="pl-s">"recentlyProcessedIcon"</span><span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">)</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"th"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">width</span>:<span class="pl-s">'23%'</span><span class="pl-kos">}</span><span class="pl-kos">,</span><span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"span"</span><span class="pl-kos">,</span> <span class="pl-c1">null</span><span class="pl-kos">,</span><span class="pl-s">"second coloumn"</span><span class="pl-kos">)</span><span class="pl-kos">)</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"th"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">width</span>:<span class="pl-s">'9%'</span><span class="pl-kos">}</span><span class="pl-kos">,</span><span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"span"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">nowrap</span>:<span class="pl-c1">true</span><span class="pl-kos">}</span><span class="pl-kos">,</span><span class="pl-s">"third coloumn "</span><span class="pl-kos">)</span><span class="pl-kos">)</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"th"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">width</span>:<span class="pl-s">'12%'</span><span class="pl-kos">}</span><span class="pl-kos">,</span><span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"span"</span><span class="pl-kos">,</span> <span class="pl-c1">null</span><span class="pl-kos">,</span><span class="pl-s">"fourth coloumn"</span><span class="pl-kos">)</span><span class="pl-kos">)</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"th"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">width</span>:<span class="pl-s">'11.5%'</span><span class="pl-kos">}</span><span class="pl-kos">,</span><span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"span"</span><span class="pl-kos">,</span> <span class="pl-c1">null</span><span class="pl-kos">,</span><span class="pl-s">"fifith"</span><span class="pl-kos">)</span><span class="pl-kos">)</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"th"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">width</span>:<span class="pl-s">'10.5%'</span><span class="pl-kos">}</span><span class="pl-kos">,</span><span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"span"</span><span class="pl-kos">,</span><span class="pl-c1">null</span><span class="pl-kos">,</span><span class="pl-s">"sixth"</span><span class="pl-kos">)</span><span class="pl-kos">)</span><span class="pl-kos">,</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"th"</span><span class="pl-kos">,</span> <span class="pl-kos">{</span><span class="pl-c1">width</span>:<span class="pl-s">'3%'</span><span class="pl-kos">,</span><span class="pl-c1">valign</span>:<span class="pl-s">'middle'</span><span class="pl-kos">}</span><span class="pl-kos">,</span><span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-s">"span"</span><span class="pl-kos">,</span> <span class="pl-c1">null</span><span class="pl-kos">,</span><span class="pl-s">"seventh"</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-kos">)</span><span class="pl-kos">;</span> <span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">render</span><span class="pl-kos">(</span><span class="pl-v">React</span><span class="pl-kos">.</span><span class="pl-en">createElement</span><span class="pl-kos">(</span><span class="pl-v">MyComponent</span><span class="pl-kos">,</span> <span class="pl-c1">null</span><span class="pl-kos">)</span><span class="pl-kos">,</span> <span class="pl-smi">document</span><span class="pl-kos">.</span><span class="pl-en">getElementById</span><span class="pl-kos">(</span><span class="pl-s">'container'</span><span class="pl-kos">)</span> <span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <p dir="auto">it is being rendered but it is not rendered in place of exisitng row but instead as a seperate row.</p> <p dir="auto">Is there any way i could render this new element as a row to the existing table..?????/</p> <p dir="auto">with this code sticky is working with this header but the all the coloumns are misaligned since i guess there is no cordination between the two tables i guess</p> <p dir="auto">Thanks</p>
<p dir="auto"><strong>Do you want to request a <em>feature</em> or report a <em>bug</em>?</strong><br> Bug</p> <p dir="auto"><strong>What is the current behavior?</strong><br> When developing an external library locally and using <code class="notranslate">yarn link</code> to link the library to a local react app the "hooks can only be called inside the body of a function component" error comes up. However, after publishing to npm and using the published version in the local react app everything works as expected.</p> <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> <ol dir="auto"> <li>Create a library that's built with hooks (my-hooks-lib)</li> <li>Create a local app that uses the library (my-react-app) using CRA</li> <li><code class="notranslate">yarn link</code> in my-hooks-lib and in my-react-app run <code class="notranslate">yarn link my-hooks-lib</code></li> </ol> <p dir="auto"><strong>What is the expected behavior?</strong><br> <code class="notranslate">yarn start</code> in the react app should use hooks and render normally</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><br> react and react-dom <code class="notranslate">16.7.0-alpha.2</code><br> OSX</p>
0
<p dir="auto">Challenge <a href="https://www.freecodecamp.com/challenges/target-a-specific-child-of-an-element-using-jquery" rel="nofollow">Target a Specific Child of an Element Using jQuery</a> has an issue.<br> User Agent is: <code class="notranslate">Mozilla/5.0 (Windows NT 6.1; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.133 Safari/537.36</code>.</p> <p dir="auto"><strong>In the result section of the page two #target5 buttons are displayed in the left-well before I refresh the code. Sometimes second #target5 reappears in mid coding.</strong></p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/18306824/25130302/c0682eb2-2452-11e7-93fc-54a8b8527a0b.PNG"><img src="https://cloud.githubusercontent.com/assets/18306824/25130302/c0682eb2-2452-11e7-93fc-54a8b8527a0b.PNG" alt="capture" style="max-width: 100%;"></a></p> <p dir="auto">My code:</p> <div class="highlight highlight-text-html-basic notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" &lt;script&gt; $(document).ready(function() { $(&quot;#target1&quot;).css(&quot;color&quot;, &quot;red&quot;); $(&quot;#target1&quot;).prop(&quot;disabled&quot;, true); $(&quot;#target4&quot;).remove(); $(&quot;#target2&quot;).appendTo(&quot;#right-well&quot;); **$(&quot;#target5&quot;).clone().appendTo(&quot;#left-well&quot;);** $(&quot;#target1&quot;).parent().css(&quot;background-color&quot;, &quot;red&quot;); $(&quot;#right-well&quot;).children().css(&quot;color&quot;, &quot;orange&quot;); }); &lt;/script&gt; &lt;!-- Only change code above this line. --&gt; &lt;div class=&quot;container-fluid&quot;&gt; &lt;h3 class=&quot;text-primary text-center&quot;&gt;jQuery Playground&lt;/h3&gt; &lt;div class=&quot;row&quot;&gt; &lt;div class=&quot;col-xs-6&quot;&gt; &lt;h4&gt;#left-well&lt;/h4&gt; &lt;div class=&quot;well&quot; id=&quot;left-well&quot;&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target1&quot;&gt;#target1&lt;/button&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target2&quot;&gt;#target2&lt;/button&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target3&quot;&gt;#target3&lt;/button&gt; &lt;/div&gt; &lt;/div&gt; &lt;div class=&quot;col-xs-6&quot;&gt; &lt;h4&gt;#right-well&lt;/h4&gt; &lt;div class=&quot;well&quot; id=&quot;right-well&quot;&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target4&quot;&gt;#target4&lt;/button&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target5&quot;&gt;#target5&lt;/button&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target6&quot;&gt;#target6&lt;/button&gt; &lt;/div&gt; &lt;/div&gt; &lt;/div&gt; &lt;/div&gt; "><pre class="notranslate"><span class="pl-kos">&lt;</span><span class="pl-ent">script</span><span class="pl-kos">&gt;</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-smi">document</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">ready</span><span class="pl-kos">(</span><span class="pl-k">function</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target1"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">css</span><span class="pl-kos">(</span><span class="pl-s">"color"</span><span class="pl-kos">,</span> <span class="pl-s">"red"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target1"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">prop</span><span class="pl-kos">(</span><span class="pl-s">"disabled"</span><span class="pl-kos">,</span> <span class="pl-c1">true</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target4"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">remove</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target2"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">appendTo</span><span class="pl-kos">(</span><span class="pl-s">"#right-well"</span><span class="pl-kos">)</span><span class="pl-kos">;</span><span class="pl-s1"></span> <span class="pl-c1">**</span><span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target5"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">clone</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">appendTo</span><span class="pl-kos">(</span><span class="pl-s">"#left-well"</span><span class="pl-kos">)</span><span class="pl-kos">;</span><span class="pl-s1"></span><span class="pl-c1">**</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target1"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">parent</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">css</span><span class="pl-kos">(</span><span class="pl-s">"background-color"</span><span class="pl-kos">,</span> <span class="pl-s">"red"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#right-well"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">children</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">css</span><span class="pl-kos">(</span><span class="pl-s">"color"</span><span class="pl-kos">,</span> <span class="pl-s">"orange"</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">&lt;/</span><span class="pl-ent">script</span><span class="pl-kos">&gt;</span> <span class="pl-c">&lt;!-- Only change code above this line. --&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">container-fluid</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h3</span> <span class="pl-c1">class</span>="<span class="pl-s">text-primary text-center</span>"<span class="pl-kos">&gt;</span>jQuery Playground<span class="pl-kos">&lt;/</span><span class="pl-ent">h3</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">row</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">col-xs-6</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h4</span><span class="pl-kos">&gt;</span>#left-well<span class="pl-kos">&lt;/</span><span class="pl-ent">h4</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">well</span>" <span class="pl-c1">id</span>="<span class="pl-s">left-well</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target1</span>"<span class="pl-kos">&gt;</span>#target1<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target2</span>"<span class="pl-kos">&gt;</span>#target2<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target3</span>"<span class="pl-kos">&gt;</span>#target3<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">col-xs-6</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h4</span><span class="pl-kos">&gt;</span>#right-well<span class="pl-kos">&lt;/</span><span class="pl-ent">h4</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">well</span>" <span class="pl-c1">id</span>="<span class="pl-s">right-well</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target4</span>"<span class="pl-kos">&gt;</span>#target4<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target5</span>"<span class="pl-kos">&gt;</span>#target5<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target6</span>"<span class="pl-kos">&gt;</span>#target6<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span></pre></div>
<p dir="auto">Challenge <a href="https://www.freecodecamp.com/challenges/target-the-parent-of-an-element-using-jquery#?solution=%0Afccss%0A%20%20%24(document).ready(function()%20%7B%0A%20%20%20%20%24(%22%23target1%22).css(%22color%22%2C%20%22red%22)%3B%0A%20%20%20%20%24(%22%23target1%22).prop(%22disabled%22%2C%20true)%3B%0A%20%20%20%20%24(%22%23target4%22).remove()%3B%0A%20%20%20%20%24(%22%23target2%22).appendTo(%22%23right-well%22)%3B%0A%20%20%20%20%24(%22%23target5%22).clone().appendTo(%22%23left-well%22)%3B%0A%0A%20%20%7D)%3B%0Afcces%0A%0A%3C!--%20Only%20change%20code%20above%20this%20line.%20--%3E%0A%0A%3Cbody%3E%0A%20%20%3Cdiv%20class%3D%22container-fluid%22%3E%0A%20%20%20%20%3Ch3%20class%3D%22text-primary%20text-center%22%3EjQuery%20Playground%3C%2Fh3%3E%0A%20%20%20%20%3Cdiv%20class%3D%22row%22%3E%0A%20%20%20%20%20%20%3Cdiv%20class%3D%22col-xs-6%22%3E%0A%20%20%20%20%20%20%20%20%3Ch4%3E%23left-well%3C%2Fh4%3E%0A%20%20%20%20%20%20%20%20%3Cdiv%20class%3D%22well%22%20id%3D%22left-well%22%3E%0A%20%20%20%20%20%20%20%20%20%20%3Cbutton%20class%3D%22btn%20btn-default%20target%22%20id%3D%22target1%22%3E%23target1%3C%2Fbutton%3E%0A%20%20%20%20%20%20%20%20%20%20%3Cbutton%20class%3D%22btn%20btn-default%20target%22%20id%3D%22target2%22%3E%23target2%3C%2Fbutton%3E%0A%20%20%20%20%20%20%20%20%20%20%3Cbutton%20class%3D%22btn%20btn-default%20target%22%20id%3D%22target3%22%3E%23target3%3C%2Fbutton%3E%0A%20%20%20%20%20%20%20%20%3C%2Fdiv%3E%0A%20%20%20%20%20%20%3C%2Fdiv%3E%0A%20%20%20%20%20%20%3Cdiv%20class%3D%22col-xs-6%22%3E%0A%20%20%20%20%20%20%20%20%3Ch4%3E%23right-well%3C%2Fh4%3E%0A%20%20%20%20%20%20%20%20%3Cdiv%20class%3D%22well%22%20id%3D%22right-well%22%3E%0A%20%20%20%20%20%20%20%20%20%20%3Cbutton%20class%3D%22btn%20btn-default%20target%22%20id%3D%22target4%22%3E%23target4%3C%2Fbutton%3E%0A%20%20%20%20%20%20%20%20%20%20%3Cbutton%20class%3D%22btn%20btn-default%20target%22%20id%3D%22target5%22%3E%23target5%3C%2Fbutton%3E%0A%20%20%20%20%20%20%20%20%20%20%3Cbutton%20class%3D%22btn%20btn-default%20target%22%20id%3D%22target6%22%3E%23target6%3C%2Fbutton%3E%0A%20%20%20%20%20%20%20%20%3C%2Fdiv%3E%0A%20%20%20%20%20%20%3C%2Fdiv%3E%0A%20%20%20%20%3C%2Fdiv%3E%0A%20%20%3C%2Fdiv%3E%0A%3C%2Fbody%3E%0A" rel="nofollow">Target the Parent of an Element Using jQuery</a> has an issue.<br> User Agent is: <code class="notranslate">Mozilla/5.0 (Windows NT 10.0; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/57.0.2987.133 Safari/537.36</code>.<br> Please describe how to reproduce this issue, and include links to screenshots if possible.</p> <p dir="auto">My code:</p> <div class="highlight highlight-text-html-basic notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" &lt;script&gt; $(document).ready(function() { $(&quot;#target1&quot;).css(&quot;color&quot;, &quot;red&quot;); $(&quot;#target1&quot;).prop(&quot;disabled&quot;, true); $(&quot;#target4&quot;).remove(); $(&quot;#target2&quot;).appendTo(&quot;#right-well&quot;); $(&quot;#target5&quot;).clone().appendTo(&quot;#left-well&quot;); }); &lt;/script&gt; &lt;!-- Only change code above this line. --&gt; &lt;body&gt; &lt;div class=&quot;container-fluid&quot;&gt; &lt;h3 class=&quot;text-primary text-center&quot;&gt;jQuery Playground&lt;/h3&gt; &lt;div class=&quot;row&quot;&gt; &lt;div class=&quot;col-xs-6&quot;&gt; &lt;h4&gt;#left-well&lt;/h4&gt; &lt;div class=&quot;well&quot; id=&quot;left-well&quot;&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target1&quot;&gt;#target1&lt;/button&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target2&quot;&gt;#target2&lt;/button&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target3&quot;&gt;#target3&lt;/button&gt; &lt;/div&gt; &lt;/div&gt; &lt;div class=&quot;col-xs-6&quot;&gt; &lt;h4&gt;#right-well&lt;/h4&gt; &lt;div class=&quot;well&quot; id=&quot;right-well&quot;&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target4&quot;&gt;#target4&lt;/button&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target5&quot;&gt;#target5&lt;/button&gt; &lt;button class=&quot;btn btn-default target&quot; id=&quot;target6&quot;&gt;#target6&lt;/button&gt; &lt;/div&gt; &lt;/div&gt; &lt;/div&gt; &lt;/div&gt; &lt;/body&gt; "><pre class="notranslate"><span class="pl-kos">&lt;</span><span class="pl-ent">script</span><span class="pl-kos">&gt;</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-smi">document</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">ready</span><span class="pl-kos">(</span><span class="pl-k">function</span><span class="pl-kos">(</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target1"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">css</span><span class="pl-kos">(</span><span class="pl-s">"color"</span><span class="pl-kos">,</span> <span class="pl-s">"red"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target1"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">prop</span><span class="pl-kos">(</span><span class="pl-s">"disabled"</span><span class="pl-kos">,</span> <span class="pl-c1">true</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target4"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">remove</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target2"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">appendTo</span><span class="pl-kos">(</span><span class="pl-s">"#right-well"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">$</span><span class="pl-kos">(</span><span class="pl-s">"#target5"</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">clone</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">.</span><span class="pl-en">appendTo</span><span class="pl-kos">(</span><span class="pl-s">"#left-well"</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">&lt;/</span><span class="pl-ent">script</span><span class="pl-kos">&gt;</span> <span class="pl-c">&lt;!-- Only change code above this line. --&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">div</span> <span class="pl-c1">class</span>="<span class="pl-s">container-fluid</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h3</span> <span class="pl-c1">class</span>="<span class="pl-s">text-primary text-center</span>"<span class="pl-kos">&gt;</span>jQuery Playground<span class="pl-kos">&lt;/</span><span class="pl-ent">h3</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">row</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">col-xs-6</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h4</span><span class="pl-kos">&gt;</span>#left-well<span class="pl-kos">&lt;/</span><span class="pl-ent">h4</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">well</span>" <span class="pl-c1">id</span>="<span class="pl-s">left-well</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target1</span>"<span class="pl-kos">&gt;</span>#target1<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target2</span>"<span class="pl-kos">&gt;</span>#target2<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target3</span>"<span class="pl-kos">&gt;</span>#target3<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">col-xs-6</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h4</span><span class="pl-kos">&gt;</span>#right-well<span class="pl-kos">&lt;/</span><span class="pl-ent">h4</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">class</span>="<span class="pl-s">well</span>" <span class="pl-c1">id</span>="<span class="pl-s">right-well</span>"<span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target4</span>"<span class="pl-kos">&gt;</span>#target4<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target5</span>"<span class="pl-kos">&gt;</span>#target5<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">button</span> <span class="pl-c1">class</span>="<span class="pl-s">btn btn-default target</span>" <span class="pl-c1">id</span>="<span class="pl-s">target6</span>"<span class="pl-kos">&gt;</span>#target6<span class="pl-kos">&lt;/</span><span class="pl-ent">button</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;/</span><span class="pl-ent">div</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></pre></div> <p dir="auto">The target5 button is cloned to the left-well but 2 times. This surely is a bug.</p>
1
<p dir="auto">Hi,<br> here is a bug in this example here:<br> <a href="https://github.com/keras-team/keras/blob/master/examples/cifar10_resnet.py#L423">https://github.com/keras-team/keras/blob/master/examples/cifar10_resnet.py#L423</a></p> <p dir="auto">The Exception is:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ValueError: `steps_per_epoch=None` is only valid for a generator based on the `keras.utils.Sequence` class. Please specify `steps_per_epoch` or use the `keras.utils.Sequence` class."><pre class="notranslate"><code class="notranslate">ValueError: `steps_per_epoch=None` is only valid for a generator based on the `keras.utils.Sequence` class. Please specify `steps_per_epoch` or use the `keras.utils.Sequence` class. </code></pre></div> <p dir="auto"><code class="notranslate">model.fit_generator</code> whould specify <code class="notranslate">steps_per_epoch</code>.</p> <p dir="auto">By example:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" model.fit_generator(datagen.flow(x_train, y_train, batch_size=batch_size), steps_per_epoch=int(50000/batch_size), validation_data=(x_test, y_test), epochs=epochs, verbose=1, workers=4, callbacks=callbacks)"><pre class="notranslate"><code class="notranslate"> model.fit_generator(datagen.flow(x_train, y_train, batch_size=batch_size), steps_per_epoch=int(50000/batch_size), validation_data=(x_test, y_test), epochs=epochs, verbose=1, workers=4, callbacks=callbacks) </code></pre></div>
<p dir="auto">Tensorflow 1.11.0<br> Keras 2.2.4<br> Keras-Preprocessing 1.0.5<br> Ubuntu 16.04<br> Python 2.7.12</p> <p dir="auto">Example code:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="from keras import models, layers from keras_preprocessing.image import ImageDataGenerator from keras_applications.imagenet_utils import preprocess_input train_dir = '/tmp/workspace/Pet_Dataset/train/' height, width, channels = (128, 128, 3) batch_size=32 train_datagen = ImageDataGenerator(rescale=1.0/255) train_generator = train_datagen.flow_from_directory( train_dir, target_size=(height, width), batch_size=batch_size, class_mode='categorical') network = models.Sequential() network.add(layers.Conv2D(32, (3, 3), activation='relu', input_shape=(height, width, channels))) network.add(layers.MaxPooling2D((2, 2))) network.add(layers.Conv2D(64, (3, 3), activation='relu')) network.add(layers.MaxPooling2D((2, 2))) network.add(layers.Conv2D(128, (3, 3), activation='relu')) network.add(layers.MaxPooling2D((2, 2))) network.add(layers.Conv2D(256, (3, 3), activation='relu')) network.add(layers.GlobalAveragePooling2D()) network.add(layers.Dense(train_generator.num_classes, activation='softmax')) network.compile(optimizer='RMSProp', loss='categorical_crossentropy', metrics=['accuracy']) network.summary() history = network.fit_generator(train_generator, epochs=10) "><pre class="notranslate"><code class="notranslate">from keras import models, layers from keras_preprocessing.image import ImageDataGenerator from keras_applications.imagenet_utils import preprocess_input train_dir = '/tmp/workspace/Pet_Dataset/train/' height, width, channels = (128, 128, 3) batch_size=32 train_datagen = ImageDataGenerator(rescale=1.0/255) train_generator = train_datagen.flow_from_directory( train_dir, target_size=(height, width), batch_size=batch_size, class_mode='categorical') network = models.Sequential() network.add(layers.Conv2D(32, (3, 3), activation='relu', input_shape=(height, width, channels))) network.add(layers.MaxPooling2D((2, 2))) network.add(layers.Conv2D(64, (3, 3), activation='relu')) network.add(layers.MaxPooling2D((2, 2))) network.add(layers.Conv2D(128, (3, 3), activation='relu')) network.add(layers.MaxPooling2D((2, 2))) network.add(layers.Conv2D(256, (3, 3), activation='relu')) network.add(layers.GlobalAveragePooling2D()) network.add(layers.Dense(train_generator.num_classes, activation='softmax')) network.compile(optimizer='RMSProp', loss='categorical_crossentropy', metrics=['accuracy']) network.summary() history = network.fit_generator(train_generator, epochs=10) </code></pre></div> <p dir="auto">breaks with Tensorflow 1.11.0 with <code class="notranslate">ValueError: steps_per_epoch=None is only valid for a generator based on the keras.utils.Sequence class. Please specify steps_per_epoch or use the keras.utils.Sequence class.</code>.</p> <p dir="auto">Tensorflow 1.10.0 and below works.</p> <p dir="auto">Furthermore, providing steps_per_epoch and applying multiprocessing with workers &gt; 1:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="history = network.fit_generator(train_generator, epochs=10, steps_per_epoch=train_generator.n/batch_size, use_multiprocessing=True, workers=2)"><pre class="notranslate"><code class="notranslate">history = network.fit_generator(train_generator, epochs=10, steps_per_epoch=train_generator.n/batch_size, use_multiprocessing=True, workers=2) </code></pre></div> <p dir="auto">causes a UserWarning about multiple workers duplicate data.</p> <p dir="auto">I think this is caused by wrong inheritance of ImageDataGenerator.</p> <p dir="auto">When printing the exact class that is used in <code class="notranslate">keras_preprocessing/image.py</code>, I get <code class="notranslate">&lt;class 'tensorflow.python.keras.utils.data_utils.Sequence'&gt;</code>.</p> <p dir="auto">But <code class="notranslate">fit_generator()</code> checks if the generator is a subclass of <code class="notranslate">&lt;class 'keras.utils.data_utils.Sequence'&gt;</code>, so it seems to assume that the ImageDataGenerator instance is not of type Sequence, causing above problems.</p>
1
<h2 dir="auto">Preflight Checklist</h2> <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> <p dir="auto">I am looking at developing an XR app now Chromium updated to version 80 - however in order to make it work with Windows and SteamVR in chrome, I need to disable the XR sandbox via chrome://flags. I would normally use <a href="https://peter.sh/experiments/chromium-command-line-switches/" rel="nofollow">a command line switch for this except one does not exist</a>.</p> <p dir="auto">Instead I am thinking of prompting the user to open the chrome://flags page and disable the XR<br> sandbox, however when I try to open it, it redirects me to "chrome-error://chromewebdata/"</p> <ul dir="auto"> <li><strong>Electron Version:</strong> <ul dir="auto"> <li>8.0.0</li> </ul> </li> <li><strong>Operating System:</strong> <ul dir="auto"> <li>Windows 10 x64 Build 18362</li> </ul> </li> </ul> <h3 dir="auto">Expected Behavior</h3> <p dir="auto">I can open "chrome://flags" using mainWindow.loadURL</p> <h3 dir="auto">Actual Behavior</h3> <p dir="auto">It redirects me to "chrome-error://chromewebdata/"</p> <h3 dir="auto">To Reproduce</h3> <p dir="auto">Please see the following electron fiddle: <a href="https://gist.github.com/459df8fd3c113acb2daadd0e7287afb3">https://gist.github.com/459df8fd3c113acb2daadd0e7287afb3</a></p>
<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>8.0.0</li> </ul> </li> <li><strong>Operating System:</strong> <ul dir="auto"> <li>Ubuntu 18.04 x64</li> </ul> </li> <li><strong>Last Known Working Electron version:</strong> <ul dir="auto"> <li>7.1.11</li> </ul> </li> </ul> <h3 dir="auto">Expected Behavior</h3> <p dir="auto">Loading chrome://media-internals should load the chrome media internals page</p> <h3 dir="auto">Actual Behavior</h3> <p dir="auto">Blank page. In chrome 80 there's also the option to show it in the devtools. If I set the correct flags I can see the 'Media' tab option, but it also gives me a blank page. So neither way works.</p> <h3 dir="auto">To Reproduce</h3> <p dir="auto">Load <code class="notranslate">chrome://media-internals</code></p>
1
<p dir="auto">Trying with 1.0.1</p> <p dir="auto">curl '<a href="http://localhost:9200/foobar*/_stats?pretty&amp;clear=1" rel="nofollow">http://localhost:9200/foobar*/_stats?pretty&amp;clear=1</a>'</p> <p dir="auto">The indices section has all my indices. :(</p> <p dir="auto">Trying with 0.90.12</p> <p dir="auto">{<br> "error" : "IndexMissingException[[foobar-*] missing]",<br> "status" : 404<br> }</p> <p dir="auto">Either the 0.90 solution or an empty indices section would be better then returning all.<br> This may happen with other APIs, haven't tried</p>
<p dir="auto">Hi,<br> I expect to get empty response for scenario;</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="#create an index curl -XPOST http://localhost:9200/test-1 # execute _stats for indices starting with xyz (ensure this regex has no matches) curl -XPOST http://locahost:9200/xyz*/_stats"><pre lang="ssh" class="notranslate"><code class="notranslate">#create an index curl -XPOST http://localhost:9200/test-1 # execute _stats for indices starting with xyz (ensure this regex has no matches) curl -XPOST http://locahost:9200/xyz*/_stats </code></pre></div> <p dir="auto">returns stats of all indices. I think this should return empty response.</p> <p dir="auto">Tried with 1.0.1 and 1.1.0</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/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">There will be no warnings in console.<br> There will be a line with <code class="notranslate">timeout</code>, not with <code class="notranslate">transitionDuration</code> here<br> <a href="https://github.com/mui-org/material-ui/blob/v1-beta/src/Stepper/StepContent.d.ts#L18">https://github.com/mui-org/material-ui/blob/v1-beta/src/Stepper/StepContent.d.ts#L18</a></p> <h2 dir="auto">Current Behavior</h2> <p dir="auto">This warning in console</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Warning: Unknown prop `transitionDuration` on &lt;div&gt; tag. Remove this prop from the element. in div (created by Transition) in Transition (created by Collapse) in Collapse (created by withStyles(Collapse)) in withStyles(Collapse) (created by StepContent) ..."><pre class="notranslate"><code class="notranslate">Warning: Unknown prop `transitionDuration` on &lt;div&gt; tag. Remove this prop from the element. in div (created by Transition) in Transition (created by Collapse) in Collapse (created by withStyles(Collapse)) in withStyles(Collapse) (created by StepContent) ... </code></pre></div> <h2 dir="auto">Steps to Reproduce (for bugs)</h2> <p dir="auto">There is no such warning in codesandbox example. But I can see it in my project. Also there is a <code class="notranslate">transitionDuration</code> mention -- see link above.<br> If it's not enough - I'll try to create an example with the warning later.</p> <h2 dir="auto">My 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.24</td> </tr> <tr> <td>React</td> <td>15.6.2</td> </tr> <tr> <td>browser</td> <td>Chrome 63.0.3239.84</td> </tr> </tbody> </table>
<p dir="auto"><code class="notranslate">&lt;option disabled /&gt;</code> is a native behavior of <code class="notranslate">&lt;select /&gt;</code><br> Please allow <code class="notranslate">&lt;MenuItem&gt;</code> to have a <code class="notranslate">disabled</code> props, which will not close SelectBox on <code class="notranslate">SelectInput &gt; handleItemClick</code>.</p> <ul dir="auto"> <li>[x ] 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">A disabled MenuItem should not be clickable and close the Select Menu</p> <h2 dir="auto">Current Behavior</h2> <p dir="auto">A click on every children will close the Select Menu</p> <p dir="auto">I currently had to trick with a <code class="notranslate">pointer-event :none</code> on my "disabled" MenuItem, with a nested div with <code class="notranslate">pointer-event: all</code> and an <code class="notranslate">onClick={e =&gt; e.stopPropagation()}</code> to reproduce the expected behavior</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.18</td> </tr> <tr> <td>React</td> <td>16.0.0</td> </tr> <tr> <td>browser</td> <td>all</td> </tr> </tbody> </table>
0
<p dir="auto">Hello,</p> <p dir="auto">I've been trying to find all documents that contains a field with an empty string value (<code class="notranslate">_textContent</code>) inside my index using the <code class="notranslate">missing</code> filter. But I think that this filter doesn't treat empty strings as a null value.</p> <p dir="auto">Is this a bug, or the intended behavior for this filter? If it is like this by design, may I suggest adding an <code class="notranslate">empty</code> filter, if that's even possible?</p> <p dir="auto">As a plus, I'll post the mapping that I'm currently using, the document that contains the empty string field and the query that I'm trying to run:</p> <p dir="auto">Mapping:</p> <div class="highlight highlight-source-json notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="{ &quot;documents&quot;: { &quot;mappings&quot;: { &quot;document&quot;: { &quot;properties&quot;: { &quot;_contratante&quot;: { &quot;type&quot;: &quot;string&quot; }, &quot;_dateFields&quot;: { &quot;type&quot;: &quot;nested&quot;, &quot;properties&quot;: { &quot;id&quot;: { &quot;type&quot;: &quot;string&quot;, &quot;index&quot;: &quot;not_analyzed&quot; }, &quot;value&quot;: { &quot;type&quot;: &quot;date&quot;, &quot;format&quot;: &quot;dateOptionalTime&quot; } } }, &quot;_indexadoPor&quot;: { &quot;type&quot;: &quot;string&quot; }, &quot;_textContent&quot;: { &quot;type&quot;: &quot;string&quot; }, &quot;_textFields&quot;: { &quot;type&quot;: &quot;nested&quot;, &quot;properties&quot;: { &quot;id&quot;: { &quot;type&quot;: &quot;string&quot;, &quot;index&quot;: &quot;not_analyzed&quot; }, &quot;value&quot;: { &quot;type&quot;: &quot;string&quot; } } }, &quot;_tipoDocumento&quot;: { &quot;type&quot;: &quot;string&quot; } } } } } }"><pre class="notranslate">{ <span class="pl-ent">"documents"</span>: { <span class="pl-ent">"mappings"</span>: { <span class="pl-ent">"document"</span>: { <span class="pl-ent">"properties"</span>: { <span class="pl-ent">"_contratante"</span>: { <span class="pl-ent">"type"</span>: <span class="pl-s"><span class="pl-pds">"</span>string<span class="pl-pds">"</span></span> }, <span class="pl-ent">"_dateFields"</span>: { <span class="pl-ent">"type"</span>: <span class="pl-s"><span class="pl-pds">"</span>nested<span class="pl-pds">"</span></span>, <span class="pl-ent">"properties"</span>: { <span class="pl-ent">"id"</span>: { <span class="pl-ent">"type"</span>: <span class="pl-s"><span class="pl-pds">"</span>string<span class="pl-pds">"</span></span>, <span class="pl-ent">"index"</span>: <span class="pl-s"><span class="pl-pds">"</span>not_analyzed<span class="pl-pds">"</span></span> }, <span class="pl-ent">"value"</span>: { <span class="pl-ent">"type"</span>: <span class="pl-s"><span class="pl-pds">"</span>date<span class="pl-pds">"</span></span>, <span class="pl-ent">"format"</span>: <span class="pl-s"><span class="pl-pds">"</span>dateOptionalTime<span class="pl-pds">"</span></span> } } }, <span class="pl-ent">"_indexadoPor"</span>: { <span class="pl-ent">"type"</span>: <span class="pl-s"><span class="pl-pds">"</span>string<span class="pl-pds">"</span></span> }, <span class="pl-ent">"_textContent"</span>: { <span class="pl-ent">"type"</span>: <span class="pl-s"><span class="pl-pds">"</span>string<span class="pl-pds">"</span></span> }, <span class="pl-ent">"_textFields"</span>: { <span class="pl-ent">"type"</span>: <span class="pl-s"><span class="pl-pds">"</span>nested<span class="pl-pds">"</span></span>, <span class="pl-ent">"properties"</span>: { <span class="pl-ent">"id"</span>: { <span class="pl-ent">"type"</span>: <span class="pl-s"><span class="pl-pds">"</span>string<span class="pl-pds">"</span></span>, <span class="pl-ent">"index"</span>: <span class="pl-s"><span class="pl-pds">"</span>not_analyzed<span class="pl-pds">"</span></span> }, <span class="pl-ent">"value"</span>: { <span class="pl-ent">"type"</span>: <span class="pl-s"><span class="pl-pds">"</span>string<span class="pl-pds">"</span></span> } } }, <span class="pl-ent">"_tipoDocumento"</span>: { <span class="pl-ent">"type"</span>: <span class="pl-s"><span class="pl-pds">"</span>string<span class="pl-pds">"</span></span> } } } } } }</pre></div> <p dir="auto">Document:</p> <div class="highlight highlight-source-json notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="{ &quot;_index&quot;: &quot;documents&quot;, &quot;_type&quot;: &quot;document&quot;, &quot;_id&quot;: &quot;xxx&quot;, &quot;_version&quot;: 1, &quot;found&quot;: true, &quot;_source&quot;: { &quot;_id&quot;: &quot;xxx&quot;, &quot;_contratante&quot;: &quot;xxx&quot;, &quot;_tipoDocumento&quot;: &quot;xxx&quot;, &quot;_indexadoPor&quot;: &quot;xxx&quot;, &quot;_dateFields&quot;: [ { &quot;id&quot;: &quot;538730ece4b0d13600208d7a:2&quot;, &quot;value&quot;: 1404183600000 } ], &quot;_textFields&quot;: [ { &quot;id&quot;: &quot;538730ece4b0d13600208d7a:0&quot;, &quot;value&quot;: &quot;xxx&quot; }, { &quot;id&quot;: &quot;538730ece4b0d13600208d7a:1&quot;, &quot;value&quot;: &quot;xxx&quot; }, { &quot;id&quot;: &quot;538730ece4b0d13600208d7a:3&quot;, &quot;value&quot;: &quot;&quot; }, { &quot;id&quot;: &quot;538730ece4b0d13600208d7a:4&quot;, &quot;value&quot;: &quot;xxxx&quot; } ], &quot;_textContent&quot;: &quot;&quot; } }"><pre class="notranslate">{ <span class="pl-ent">"_index"</span>: <span class="pl-s"><span class="pl-pds">"</span>documents<span class="pl-pds">"</span></span>, <span class="pl-ent">"_type"</span>: <span class="pl-s"><span class="pl-pds">"</span>document<span class="pl-pds">"</span></span>, <span class="pl-ent">"_id"</span>: <span class="pl-s"><span class="pl-pds">"</span>xxx<span class="pl-pds">"</span></span>, <span class="pl-ent">"_version"</span>: <span class="pl-c1">1</span>, <span class="pl-ent">"found"</span>: <span class="pl-c1">true</span>, <span class="pl-ent">"_source"</span>: { <span class="pl-ent">"_id"</span>: <span class="pl-s"><span class="pl-pds">"</span>xxx<span class="pl-pds">"</span></span>, <span class="pl-ent">"_contratante"</span>: <span class="pl-s"><span class="pl-pds">"</span>xxx<span class="pl-pds">"</span></span>, <span class="pl-ent">"_tipoDocumento"</span>: <span class="pl-s"><span class="pl-pds">"</span>xxx<span class="pl-pds">"</span></span>, <span class="pl-ent">"_indexadoPor"</span>: <span class="pl-s"><span class="pl-pds">"</span>xxx<span class="pl-pds">"</span></span>, <span class="pl-ent">"_dateFields"</span>: [ { <span class="pl-ent">"id"</span>: <span class="pl-s"><span class="pl-pds">"</span>538730ece4b0d13600208d7a:2<span class="pl-pds">"</span></span>, <span class="pl-ent">"value"</span>: <span class="pl-c1">1404183600000</span> } ], <span class="pl-ent">"_textFields"</span>: [ { <span class="pl-ent">"id"</span>: <span class="pl-s"><span class="pl-pds">"</span>538730ece4b0d13600208d7a:0<span class="pl-pds">"</span></span>, <span class="pl-ent">"value"</span>: <span class="pl-s"><span class="pl-pds">"</span>xxx<span class="pl-pds">"</span></span> }, { <span class="pl-ent">"id"</span>: <span class="pl-s"><span class="pl-pds">"</span>538730ece4b0d13600208d7a:1<span class="pl-pds">"</span></span>, <span class="pl-ent">"value"</span>: <span class="pl-s"><span class="pl-pds">"</span>xxx<span class="pl-pds">"</span></span> }, { <span class="pl-ent">"id"</span>: <span class="pl-s"><span class="pl-pds">"</span>538730ece4b0d13600208d7a:3<span class="pl-pds">"</span></span>, <span class="pl-ent">"value"</span>: <span class="pl-s"><span class="pl-pds">"</span><span class="pl-pds">"</span></span> }, { <span class="pl-ent">"id"</span>: <span class="pl-s"><span class="pl-pds">"</span>538730ece4b0d13600208d7a:4<span class="pl-pds">"</span></span>, <span class="pl-ent">"value"</span>: <span class="pl-s"><span class="pl-pds">"</span>xxxx<span class="pl-pds">"</span></span> } ], <span class="pl-ent">"_textContent"</span>: <span class="pl-s"><span class="pl-pds">"</span><span class="pl-pds">"</span></span> } }</pre></div> <p dir="auto">Query:</p> <div class="highlight highlight-source-json notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="{ &quot;query&quot;: { &quot;filtered&quot;: { &quot;filter&quot;: { &quot;missing&quot;: { &quot;field&quot;: &quot;_textContent&quot; } } } } }"><pre class="notranslate">{ <span class="pl-ent">"query"</span>: { <span class="pl-ent">"filtered"</span>: { <span class="pl-ent">"filter"</span>: { <span class="pl-ent">"missing"</span>: { <span class="pl-ent">"field"</span>: <span class="pl-s"><span class="pl-pds">"</span>_textContent<span class="pl-pds">"</span></span> } } } } }</pre></div> <p dir="auto">Thanks a lot for the amazing tool developed here!</p>
<p dir="auto">Heya,</p> <p dir="auto">in ES 1.2.4 i do something like this:</p> <div class="highlight highlight-source-shell notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="curl -XPUT 'http://localhost:9200/twitter/user/kimchy' -d '{ &quot;name_test&quot; : &quot;Shay Banon&quot; }' curl -XPUT 'http://localhost:9200/twitter/user/foo' -d '{ &quot;name_test&quot; : &quot;&quot; }' curl -XPOST 'http://localhost:9200/_search' -d '{&quot;query&quot;:{&quot;filtered&quot;:{&quot;filter&quot;:{&quot;and&quot;:{&quot;filters&quot;:[{&quot;missing&quot;:{&quot;field&quot;: &quot;name_test&quot;}}]}}}}}'"><pre class="notranslate">curl -XPUT <span class="pl-s"><span class="pl-pds">'</span>http://localhost:9200/twitter/user/kimchy<span class="pl-pds">'</span></span> -d <span class="pl-s"><span class="pl-pds">'</span>{ "name_test" : "Shay Banon" }<span class="pl-pds">'</span></span> curl -XPUT <span class="pl-s"><span class="pl-pds">'</span>http://localhost:9200/twitter/user/foo<span class="pl-pds">'</span></span> -d <span class="pl-s"><span class="pl-pds">'</span>{ "name_test" : "" }<span class="pl-pds">'</span></span> curl -XPOST <span class="pl-s"><span class="pl-pds">'</span>http://localhost:9200/_search<span class="pl-pds">'</span></span> -d <span class="pl-s"><span class="pl-pds">'</span>{"query":{"filtered":{"filter":{"and":{"filters":[{"missing":{"field": "name_test"}}]}}}}}<span class="pl-pds">'</span></span></pre></div> <p dir="auto">Filter in "nice view"</p> <div class="highlight highlight-source-json notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="{ &quot;query&quot;: { &quot;filtered&quot;: { &quot;filter&quot;: { &quot;and&quot;: { &quot;filters&quot;: [ { &quot;missing&quot;: { &quot;field&quot;: &quot;name_test&quot; } } ] } } } } }"><pre class="notranslate">{ <span class="pl-ent">"query"</span>: { <span class="pl-ent">"filtered"</span>: { <span class="pl-ent">"filter"</span>: { <span class="pl-ent">"and"</span>: { <span class="pl-ent">"filters"</span>: [ { <span class="pl-ent">"missing"</span>: { <span class="pl-ent">"field"</span>: <span class="pl-s"><span class="pl-pds">"</span>name_test<span class="pl-pds">"</span></span> } } ] } } } } }</pre></div> <p dir="auto">This one gives 1 hit.</p> <p dir="auto">In Version 1.3.2 i do the same stuff, but got 0 hits.</p> <p dir="auto">Am I missing something? (I read the changelog, but didnt find something that could possible do this...)</p> <p dir="auto">That happens, as i may suggest, when the field name got an underscore.<br> Tested it with "name" then it will also give one hit.</p> <p dir="auto">Thanks for watchin.</p> <p dir="auto">Dominik</p>
1
<h5 dir="auto">Issue Type: Bug Report</h5> <h5 dir="auto">Ansible Version: ansible-playbook 1.5</h5> <h5 dir="auto">Environment: OSX, Debian Squeeze</h5> <h5 dir="auto">Summary:</h5> <p dir="auto">Imagine a playbook, with a play that has a hosts: line of localhost</p> <p dir="auto">Imagine running this playbook, with a --limit derp, which does not include localhost.</p> <p dir="auto">You'd expect this to skip the play with no matching hosts, but instead the play will get executed, and then the playbook will immediately fail with FATAL: all hosts have already failed.</p> <h5 dir="auto">Steps To Reproduce:</h5> <p dir="auto">test.yaml</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" --- - name: Test play 1 hosts: localhost gather_facts: no tasks: - name: derp debug: msg=&quot;herp&quot;"><pre class="notranslate"><code class="notranslate"> --- - name: Test play 1 hosts: localhost gather_facts: no tasks: - name: derp debug: msg="herp" </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ ansible-playbook -i derp, test.yaml -vv --limit derp"><pre class="notranslate"><code class="notranslate">$ ansible-playbook -i derp, test.yaml -vv --limit derp </code></pre></div> <h5 dir="auto">Expected Results:</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="PLAY [Test play 1] ************************************************************ skipping: no hosts matched"><pre class="notranslate"><code class="notranslate">PLAY [Test play 1] ************************************************************ skipping: no hosts matched </code></pre></div> <p dir="auto">or</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="TASK: [derp] ****************************************************************** ok: [localhost] =&gt; { &quot;msg&quot;: &quot;herp&quot; }"><pre class="notranslate"><code class="notranslate">TASK: [derp] ****************************************************************** ok: [localhost] =&gt; { "msg": "herp" } </code></pre></div> <h5 dir="auto">Actual Results:</h5> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="TASK: [derp] ****************************************************************** ok: [localhost] =&gt; { &quot;msg&quot;: &quot;herp&quot; } FATAL: all hosts have already failed -- aborting"><pre class="notranslate"><code class="notranslate">TASK: [derp] ****************************************************************** ok: [localhost] =&gt; { "msg": "herp" } FATAL: all hosts have already failed -- aborting </code></pre></div> <p dir="auto">Through some bisecting, I think the offending commit is<br> <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/ansible/ansible/commit/ae9843fccdac1bc5da95f2c9d274e927f4a43962/hovercard" href="https://github.com/ansible/ansible/commit/ae9843fccdac1bc5da95f2c9d274e927f4a43962"><tt>ae9843f</tt></a><br> but I'm not positive. I believe it's a combination of this commit, along with the introduction of the implicit localhost inventory entry. More testing to continue, but I wanted to get this filed for tracking.</p>
<p dir="auto">Including "disablerepo=*" appears to disable all repos, including those explicitly enabled with enablerepo.</p> <p dir="auto">From within the vm, the following installs the package as expected:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="sudo yum install yum-plugin-downloadonly --disablerepo=* --enablerepo=mylocalrepo"><pre class="notranslate"><code class="notranslate">sudo yum install yum-plugin-downloadonly --disablerepo=* --enablerepo=mylocalrepo </code></pre></div> <p dir="auto">However, with the following playbook entry, the package cannot be found:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="- name: installing yum-plugin-downloadonly action: yum name=yum-plugin-downloadonly disablerepo=* enablerepo=mylocalrepo state=present tags: yum-config sudo: yes TASK: [common | installing yum-plugin-downloadonly] *************************** failed: [10.10.10.100] =&gt; {&quot;changed&quot;: false, &quot;failed&quot;: true, &quot;item&quot;: &quot;&quot;, &quot;rc&quot;: 0, &quot;results&quot;: []} msg: No Package matching 'yum-plugin-downloadonly' found available, installed or updated FATAL: all hosts have already failed -- aborting"><pre class="notranslate"><code class="notranslate">- name: installing yum-plugin-downloadonly action: yum name=yum-plugin-downloadonly disablerepo=* enablerepo=mylocalrepo state=present tags: yum-config sudo: yes TASK: [common | installing yum-plugin-downloadonly] *************************** failed: [10.10.10.100] =&gt; {"changed": false, "failed": true, "item": "", "rc": 0, "results": []} msg: No Package matching 'yum-plugin-downloadonly' found available, installed or updated FATAL: all hosts have already failed -- aborting </code></pre></div>
0
<p dir="auto">i find my program can not clear cookies ,if i used 0.36.1 both mac and win.</p> <p dir="auto">then i do a test.</p> <p dir="auto">code is here:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&quot;use strict&quot; const app = require('electron').app const BrowserWindow = require('electron').BrowserWindow app.on('window-all-closed', () =&gt; { app.quit() }) app.on('ready', () =&gt; { let mainWindow = new BrowserWindow({ &quot;width&quot;: 800, &quot;height&quot;: 800, &quot;center&quot;: true }) let mainWindowContents = mainWindow.webContents let session = mainWindowContents.session mainWindowContents.loadURL(&quot;https://www.google.com.hk&quot;) mainWindowContents.on('did-stop-loading', () =&gt; { // get all cookies and remove them session.cookies.get({}, (error, cookies) =&gt; { let len = cookies.length console.log(len) cookies.forEach((cookie) =&gt; { let name = cookie.name session.cookies.remove({ name: name }, function(error) { console.log(name) }) }) }) }) }) "><pre class="notranslate"><code class="notranslate">"use strict" const app = require('electron').app const BrowserWindow = require('electron').BrowserWindow app.on('window-all-closed', () =&gt; { app.quit() }) app.on('ready', () =&gt; { let mainWindow = new BrowserWindow({ "width": 800, "height": 800, "center": true }) let mainWindowContents = mainWindow.webContents let session = mainWindowContents.session mainWindowContents.loadURL("https://www.google.com.hk") mainWindowContents.on('did-stop-loading', () =&gt; { // get all cookies and remove them session.cookies.get({}, (error, cookies) =&gt; { let len = cookies.length console.log(len) cookies.forEach((cookie) =&gt; { let name = cookie.name session.cookies.remove({ name: name }, function(error) { console.log(name) }) }) }) }) }) </code></pre></div> <p dir="auto">in 0.36.1,it not working, and catch a error:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="TypeError: Error processing argument -1. at TypeError (native) at /Users/linchao/Documents/code/electron-test/main.js:31:23 at Array.forEach (native) at Function.&lt;anonymous&gt; (/Users/linchao/Documents/code/electron-test/main.js:28:13)"><pre class="notranslate"><code class="notranslate">TypeError: Error processing argument -1. at TypeError (native) at /Users/linchao/Documents/code/electron-test/main.js:31:23 at Array.forEach (native) at Function.&lt;anonymous&gt; (/Users/linchao/Documents/code/electron-test/main.js:28:13) </code></pre></div> <p dir="auto">but the test code working fine before 0.36.1,will console cookies num and display all removed cookies names.</p> <p dir="auto">thanks.</p>
<p dir="auto">Hello,</p> <p dir="auto">While executing our test codes. clearing cookies test case was failing in 0.36.1, Attached the sample stack trace.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Error: Could not call remote function `remove`. Check that the function signature is correct. Underlying error: Error processing argument -1. Error: Could not call remote function `remove`. Check that the function signature is correct. Underlying error: Error processing argument -1. at callFunction (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/lib/rpc-server.js:186:13) at EventEmitter.&lt;anonymous&gt; (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/lib/rpc-server.js:281:14) at emitMany (events.js:108:13) at EventEmitter.emit (events.js:182:7) at EventEmitter.&lt;anonymous&gt; (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/api/lib/web-contents.js:101:27) at emitTwo (events.js:87:13) at EventEmitter.emit (events.js:172:7) at callFunction (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/lib/rpc-server.js:186:13) at EventEmitter.&lt;anonymous&gt; (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/lib/rpc-server.js:281:14) at emitMany (events.js:108:13) at EventEmitter.emit (events.js:182:7) at EventEmitter.&lt;anonymous&gt; (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/api/lib/web-contents.js:101:27) at emitTwo (events.js:87:13) at EventEmitter.emit (events.js:172:7) at metaToValue (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/renderer/api/lib/remote.js:108:15) at RemoteMemberFunction [as remove] (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/renderer/api/lib/remote.js:142:26) at Object.util.cookies._delete (&lt;anonymous&gt;:6:45) "><pre class="notranslate"><code class="notranslate">Error: Could not call remote function `remove`. Check that the function signature is correct. Underlying error: Error processing argument -1. Error: Could not call remote function `remove`. Check that the function signature is correct. Underlying error: Error processing argument -1. at callFunction (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/lib/rpc-server.js:186:13) at EventEmitter.&lt;anonymous&gt; (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/lib/rpc-server.js:281:14) at emitMany (events.js:108:13) at EventEmitter.emit (events.js:182:7) at EventEmitter.&lt;anonymous&gt; (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/api/lib/web-contents.js:101:27) at emitTwo (events.js:87:13) at EventEmitter.emit (events.js:172:7) at callFunction (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/lib/rpc-server.js:186:13) at EventEmitter.&lt;anonymous&gt; (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/lib/rpc-server.js:281:14) at emitMany (events.js:108:13) at EventEmitter.emit (events.js:182:7) at EventEmitter.&lt;anonymous&gt; (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/browser/api/lib/web-contents.js:101:27) at emitTwo (events.js:87:13) at EventEmitter.emit (events.js:172:7) at metaToValue (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/renderer/api/lib/remote.js:108:15) at RemoteMemberFunction [as remove] (/Applications/electron-v0.36.1-darwin-x64/Electron.app/Contents/Resources/atom.asar/renderer/api/lib/remote.js:142:26) at Object.util.cookies._delete (&lt;anonymous&gt;:6:45) </code></pre></div> <p dir="auto">Env :</p> <p dir="auto">Electron : 0.36.1<br> Mac : OS x El captain</p> <p dir="auto">Works fine in : 0.36.0</p>
1
<p dir="auto">Challenge <a href="http://freecodecamp.com/challenges/waypoint-create-a-set-of-checkboxes" rel="nofollow">http://freecodecamp.com/challenges/waypoint-create-a-set-of-checkboxes</a> has an issue.</p> <p dir="auto">To reproduce: try the challenge and when you are going to name the checkboxes the challenge will be correct if you only type one name.</p> <p dir="auto">Expected: The challenge will only mark as complete if all three checkboxes have the same name.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/9614642/9503734/26254bb8-4c0f-11e5-9ab4-6babeae95cb8.jpg"><img src="https://cloud.githubusercontent.com/assets/9614642/9503734/26254bb8-4c0f-11e5-9ab4-6babeae95cb8.jpg" alt="issue-challenge-checkboxes" style="max-width: 100%;"></a></p>
<p dir="auto">Challenge <a href="https://www.freecodecamp.com/challenges/smallest-common-multiple" rel="nofollow">Smallest Common Multiple</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.76 Safari/537.36</code>.<br> Please describe how to reproduce this issue, and include links to screenshots if possible.</p> <p dir="auto">Hi, my code for the smallest common multiple challenge works but if I input numbers larger than 5, it gives me the infinite loop notification and the //noprotect takes too long. If it isn't a bug, could it have something to do with the efficiency of my algorithm and how I am pushing and scanning an increasingly larger array? I tried using more efficient methods like modulus or poping old values but I have only been able to max at an input of 7, as opposed to the 13 and beyond per the test cases.</p> <p dir="auto">My code:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="//In progress: It works but has problem with efficiency function smallestCommons(arr) { //Variable declarations var arr1 = []; //Values inside boundaries of arr var arr2 = []; //Multipliers of arr1 var countDuplicates = 0; //Used to find match in arr2 var result = 0; //Result dump //Sort and collect input values and dump to arr1 arr.sort(function(a,b){return a - b;}); for (i = arr[0]; i &lt;= arr[1]; i++) { arr1.push(i); } //Increment multiplier and dump into arr2 var j = 1; while(true)// { //Multiply the values of arr1 and dump to arr2 for (var k = 0; k &lt; arr1.length; k++) { arr2.push(arr1[k] * j); } //Check for internal duplicates for (var l = 0; l &lt; arr2.length; l++) { for (var m = 0; m &lt; arr2.length; m++) { if (arr2[l] == arr2[m]) { countDuplicates++; } } //Collect the result if there is a match equal to arr1.length if (countDuplicates &gt;= arr1.length) { return arr2[l]; } countDuplicates = 0; } j++; } } smallestCommons([1, 3]); "><pre class="notranslate"><span class="pl-c">//In progress: It works but has problem with efficiency</span> <span class="pl-k">function</span> <span class="pl-en">smallestCommons</span><span class="pl-kos">(</span><span class="pl-s1">arr</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-c">//Variable declarations</span> <span class="pl-k">var</span> <span class="pl-s1">arr1</span> <span class="pl-c1">=</span> <span class="pl-kos">[</span><span class="pl-kos">]</span><span class="pl-kos">;</span> <span class="pl-c">//Values inside boundaries of arr</span> <span class="pl-k">var</span> <span class="pl-s1">arr2</span> <span class="pl-c1">=</span> <span class="pl-kos">[</span><span class="pl-kos">]</span><span class="pl-kos">;</span> <span class="pl-c">//Multipliers of arr1</span> <span class="pl-k">var</span> <span class="pl-s1">countDuplicates</span> <span class="pl-c1">=</span> <span class="pl-c1">0</span><span class="pl-kos">;</span> <span class="pl-c">//Used to find match in arr2</span> <span class="pl-k">var</span> <span class="pl-s1">result</span> <span class="pl-c1">=</span> <span class="pl-c1">0</span><span class="pl-kos">;</span> <span class="pl-c">//Result dump</span> <span class="pl-c">//Sort and collect input values and dump to arr1</span> <span class="pl-s1">arr</span><span class="pl-kos">.</span><span class="pl-en">sort</span><span class="pl-kos">(</span><span class="pl-k">function</span><span class="pl-kos">(</span><span class="pl-s1">a</span><span class="pl-kos">,</span><span class="pl-s1">b</span><span class="pl-kos">)</span><span class="pl-kos">{</span><span class="pl-k">return</span> <span class="pl-s1">a</span> <span class="pl-c1">-</span> <span class="pl-s1">b</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">for</span> <span class="pl-kos">(</span><span class="pl-s1">i</span> <span class="pl-c1">=</span> <span class="pl-s1">arr</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-s1">i</span> <span class="pl-c1">&lt;=</span> <span class="pl-s1">arr</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-s1">i</span><span class="pl-c1">++</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-s1">arr1</span><span class="pl-kos">.</span><span class="pl-en">push</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> <span class="pl-c">//Increment multiplier and dump into arr2</span> <span class="pl-k">var</span> <span class="pl-s1">j</span> <span class="pl-c1">=</span> <span class="pl-c1">1</span><span class="pl-kos">;</span> <span class="pl-k">while</span><span class="pl-kos">(</span><span class="pl-c1">true</span><span class="pl-kos">)</span><span class="pl-c">//</span> <span class="pl-kos">{</span> <span class="pl-c">//Multiply the values of arr1 and dump to arr2</span> <span class="pl-k">for</span> <span class="pl-kos">(</span><span class="pl-k">var</span> <span class="pl-s1">k</span> <span class="pl-c1">=</span> <span class="pl-c1">0</span><span class="pl-kos">;</span> <span class="pl-s1">k</span> <span class="pl-c1">&lt;</span> <span class="pl-s1">arr1</span><span class="pl-kos">.</span><span class="pl-c1">length</span><span class="pl-kos">;</span> <span class="pl-s1">k</span><span class="pl-c1">++</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-s1">arr2</span><span class="pl-kos">.</span><span class="pl-en">push</span><span class="pl-kos">(</span><span class="pl-s1">arr1</span><span class="pl-kos">[</span><span class="pl-s1">k</span><span class="pl-kos">]</span> <span class="pl-c1">*</span> <span class="pl-s1">j</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-c">//Check for internal duplicates</span> <span class="pl-k">for</span> <span class="pl-kos">(</span><span class="pl-k">var</span> <span class="pl-s1">l</span> <span class="pl-c1">=</span> <span class="pl-c1">0</span><span class="pl-kos">;</span> <span class="pl-s1">l</span> <span class="pl-c1">&lt;</span> <span class="pl-s1">arr2</span><span class="pl-kos">.</span><span class="pl-c1">length</span><span class="pl-kos">;</span> <span class="pl-s1">l</span><span class="pl-c1">++</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">for</span> <span class="pl-kos">(</span><span class="pl-k">var</span> <span class="pl-s1">m</span> <span class="pl-c1">=</span> <span class="pl-c1">0</span><span class="pl-kos">;</span> <span class="pl-s1">m</span> <span class="pl-c1">&lt;</span> <span class="pl-s1">arr2</span><span class="pl-kos">.</span><span class="pl-c1">length</span><span class="pl-kos">;</span> <span class="pl-s1">m</span><span class="pl-c1">++</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">arr2</span><span class="pl-kos">[</span><span class="pl-s1">l</span><span class="pl-kos">]</span> <span class="pl-c1">==</span> <span class="pl-s1">arr2</span><span class="pl-kos">[</span><span class="pl-s1">m</span><span class="pl-kos">]</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-s1">countDuplicates</span><span class="pl-c1">++</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-c">//Collect the result if there is a match equal to arr1.length</span> <span class="pl-k">if</span> <span class="pl-kos">(</span><span class="pl-s1">countDuplicates</span> <span class="pl-c1">&gt;=</span> <span class="pl-s1">arr1</span><span class="pl-kos">.</span><span class="pl-c1">length</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">return</span> <span class="pl-s1">arr2</span><span class="pl-kos">[</span><span class="pl-s1">l</span><span class="pl-kos">]</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-s1">countDuplicates</span> <span class="pl-c1">=</span> <span class="pl-c1">0</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-s1">j</span><span class="pl-c1">++</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-kos">}</span> <span class="pl-en">smallestCommons</span><span class="pl-kos">(</span><span class="pl-kos">[</span><span class="pl-c1">1</span><span class="pl-kos">,</span> <span class="pl-c1">3</span><span class="pl-kos">]</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div>
0
<p dir="auto">支 持 中 文<br> It a beautiful day outside<br> The birds are singing<br> The flowers are booming<br> On the days like this<br> The toys like this<br> SHOULD SUPPORT CHINESE<br> 什么时候支持中文啊?</p>
<h1 dir="auto">Summary of the new feature/enhancement</h1> <p dir="auto">The windows key shortcut guide UI strings need to be localized.</p> <p dir="auto">The application will be localized in the following langauges:</p> <table role="table"> <thead> <tr> <th>Language</th> <th>Culture Code</th> </tr> </thead> <tbody> <tr> <td>English</td> <td>en</td> </tr> <tr> <td>German</td> <td>de</td> </tr> <tr> <td>Spanish</td> <td>es</td> </tr> <tr> <td>French</td> <td>fr</td> </tr> <tr> <td>Italian</td> <td>it</td> </tr> <tr> <td>Japanese</td> <td>ja</td> </tr> <tr> <td>Korean</td> <td>ko</td> </tr> <tr> <td>Portuguese (Brazil)</td> <td>pt-BR</td> </tr> <tr> <td>Russian</td> <td>ru</td> </tr> <tr> <td>Chinese (Simplified)</td> <td>zh-Hans</td> </tr> <tr> <td>Chinese (Traditional)</td> <td>zh-Hant</td> </tr> <tr> <td>Czech</td> <td>cs</td> </tr> <tr> <td>Dutch</td> <td>nl</td> </tr> <tr> <td>Hungarian</td> <td>hu</td> </tr> <tr> <td>Portuguese (Portugal)</td> <td>pt-PT</td> </tr> <tr> <td>Polish</td> <td>pl</td> </tr> <tr> <td>Swedish</td> <td>sv</td> </tr> <tr> <td>Turkish</td> <td>tr</td> </tr> </tbody> </table>
1
<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> </ul> <h3 dir="auto">Issue Details</h3> <ul dir="auto"> <li><strong>Electron Version:</strong> 10.0.0</li> </ul> <h3 dir="auto">Rejection Email</h3> <p dir="auto">Your app links against the following non-public framework(s):</p> <p dir="auto">• Contents/Frameworks/Electron Framework.framework/Versions/A/Electron Framework/_CGFontRenderingGetFontSmoothingDisabled</p> <h3 dir="auto">Additional Information: N/A</h3>
<ul dir="auto"> <li>Electron version: 1.6.2</li> <li>Operating system: Windows 10 64-bit</li> </ul> <h3 dir="auto">Expected behavior</h3> <p dir="auto">Electron usually runs /resources/app.asar if it is present however you can also run a certain app by doing <code class="notranslate">Electron your_app_path.asar</code>.<br> I expected Electron to run app.asar when started without any arguments (this does happen) but to run the provided alternative app when the argument is provided.</p> <h3 dir="auto">Actual behavior</h3> <p dir="auto">However, Electron will still run /resources/app.asar even when the alternative app archive is provided as an argument.</p> <h3 dir="auto">How to reproduce</h3> <p dir="auto">To reproduce, simply have an app.asar in /resources/ and another alternative.asar also in the resources folder. Then run <code class="notranslate">Electron resources/alternative.asar</code>. It will run the app.asar app. Then rename app.asar to app_old.asar and do the same command and it should run the alternative.asar app.</p>
0
<p dir="auto"><a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/TWiStErRob/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/TWiStErRob">@TWiStErRob</a></p> <p dir="auto">Me again. I also have a UI demand like <a href="https://github.com/bumptech/glide/issues/1124" data-hovercard-type="issue" data-hovercard-url="/bumptech/glide/issues/1124/hovercard">#1124</a>?</p> <p dir="auto">Can you give me some suggestion? Thanks.</p> <p dir="auto">Maybe like below, but attention to <strong>glide internal drawable animation</strong>: <strong>.crossFade()</strong></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Glide.with(mCOn) .load(model.url) .placeholder(R.drawable.inventory_placeholder) .diskCacheStrategy(DiskCacheStrategy.RESULT) .crossFade() .tint(Color.RED) // &lt;------------------ I am here! .into(holder.res_pic);"><pre class="notranslate"><code class="notranslate">Glide.with(mCOn) .load(model.url) .placeholder(R.drawable.inventory_placeholder) .diskCacheStrategy(DiskCacheStrategy.RESULT) .crossFade() .tint(Color.RED) // &lt;------------------ I am here! .into(holder.res_pic); </code></pre></div>
<p dir="auto">i am using Glide 3.6.1</p> <p dir="auto">i am showing the images with GridLayoutManager and using Glide to load images.<br> meanwhile i load the images i am showing the placeholder drawable.</p> <p dir="auto">i am providing the user option of selection and for that purpose if item is selected i am adding the color filter to the particular imageview. but that works perfectly fine if the image is loaded into the memory.<br> but when placeholder is displayed and user clicks on particular image then color filter is not getting applied to imageview. so user has to wait until glide finishes the image loading.</p> <p dir="auto"><strong>in the screenshot consider the requirement as i want to show Guitar Tuner selected when user taps on it.</strong></p> <div class="highlight highlight-source-java notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" Glide.with(mCOn) .load(model.url) .placeholder(R.drawable.inventory_placeholder) .diskCacheStrategy(DiskCacheStrategy.RESULT) .crossFade() .into(holder.res_pic); if (model.status) { // selected tint holder.res_pic.setColorFilter(ContextCompat.getColor(mCOn, R.color.orange_tint), PorterDuff.Mode.MULTIPLY); } else { holder.res_pic.clearColorFilter(); }"><pre class="notranslate"> <span class="pl-smi">Glide</span>.<span class="pl-en">with</span>(<span class="pl-s1">mCOn</span>) .<span class="pl-en">load</span>(<span class="pl-s1">model</span>.<span class="pl-s1">url</span>) .<span class="pl-en">placeholder</span>(<span class="pl-smi">R</span>.<span class="pl-s1">drawable</span>.<span class="pl-s1">inventory_placeholder</span>) .<span class="pl-en">diskCacheStrategy</span>(<span class="pl-smi">DiskCacheStrategy</span>.<span class="pl-c1">RESULT</span>) .<span class="pl-en">crossFade</span>() .<span class="pl-en">into</span>(<span class="pl-s1">holder</span>.<span class="pl-s1">res_pic</span>); <span class="pl-k">if</span> (<span class="pl-s1">model</span>.<span class="pl-s1">status</span>) { <span class="pl-c">// selected tint</span> <span class="pl-s1">holder</span>.<span class="pl-s1">res_pic</span>.<span class="pl-en">setColorFilter</span>(<span class="pl-smi">ContextCompat</span>.<span class="pl-en">getColor</span>(<span class="pl-s1">mCOn</span>, <span class="pl-smi">R</span>.<span class="pl-s1">color</span>.<span class="pl-s1">orange_tint</span>), <span class="pl-smi">PorterDuff</span>.<span class="pl-s1">Mode</span>.<span class="pl-c1">MULTIPLY</span>); } <span class="pl-k">else</span> { <span class="pl-s1">holder</span>.<span class="pl-s1">res_pic</span>.<span class="pl-en">clearColorFilter</span>(); }</pre></div> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/16112654/14418533/eb0e4b9c-ffdc-11e5-99a5-d5c9088f706d.png"><img src="https://cloud.githubusercontent.com/assets/16112654/14418533/eb0e4b9c-ffdc-11e5-99a5-d5c9088f706d.png" alt="screenshot_2016-04-11-11-50-01" style="max-width: 100%;"></a></p>
1
<p dir="auto">Are you planning on implementing async rendering anytime soon?<br> maybe for v8.0 release( I hope )?</p>
<p dir="auto">The <a href="https://github.com/zeit/next.js#custom-app">"Custom App"</a> readme section has one 404 and one irrelevant link under the "Examples" expanding menu.</p>
0
<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 a description of the new feature</h2> <p dir="auto"><em>What is the expected behavior of the proposed feature? What is the scenario this would be used?</em></p> <p dir="auto">I'd like to define a shortcut to each of my 4 FancyZones to directly move a window to the right position on screen (instead of hitting WIN+RIGHT 4 times to move a window to the lower right corner)</p> <hr> <p dir="auto">If you'd like to see this feature implemented, add a <g-emoji class="g-emoji" alias="+1" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/1f44d.png">👍</g-emoji> reaction to this post.</p>
<p dir="auto">I want to hit a user definable shortcut and the focused window should resize to the zone which is mapped to this shortcut .</p> <p dir="auto">I would map some keys e.g. on the numpad to my e.g. 4 zones. Now I can just press one of these keys and my windows is resized to the chosen zone.</p> <p dir="auto">Cycling with WIN + arrow is nice, but just hitting a key is a lot faster!</p>
1
<h3 dir="auto">What problem does this feature solve?</h3> <p dir="auto">Allows you to create a scoped block of HTML without having to create a component (similar to petite-vue).</p> <p dir="auto">This has already been mentioned <a href="https://github.com/vuejs/vue/issues/12212" data-hovercard-type="issue" data-hovercard-url="/vuejs/vue/issues/12212/hovercard">here</a>. However after searching for the issue/PR for hours I still cannot find it.</p> <p dir="auto">Please could you either keep this issue, re-open the original issue or add a comment which atleast links to the issue/pr.</p> <h3 dir="auto">What does the proposed API look like?</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&lt;div v-scope=&quot;{ count: 0 }&quot;&gt; {{ count }} &lt;button @click=&quot;count++&quot;&gt;inc&lt;/button&gt; &lt;/div&gt;"><pre class="notranslate"><code class="notranslate">&lt;div v-scope="{ count: 0 }"&gt; {{ count }} &lt;button @click="count++"&gt;inc&lt;/button&gt; &lt;/div&gt; </code></pre></div>
<div class="highlight highlight-text-html-basic notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&lt;!-- somewhere in a component named 'tl-login' --&gt; &lt;div v-text=&quot;str(me)&quot;&gt;"><pre class="notranslate"><span class="pl-c">&lt;!-- somewhere in a component named 'tl-login' --&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">div</span> <span class="pl-c1">v-text</span>="<span class="pl-s">str(me)</span>"<span class="pl-kos">&gt;</span></pre></div> <div class="highlight highlight-source-coffee notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="Vue = require 'vue' Vue.component 'login', template: '#tl-login' data: {} methods: str: (x) -&gt; JSON.stringify x"><pre class="notranslate"><span class="pl-v">Vue</span> <span class="pl-k">=</span> <span class="pl-c1">require</span> <span class="pl-s"><span class="pl-pds">'</span>vue<span class="pl-pds">'</span></span> <span class="pl-smi">Vue</span>.<span class="pl-en">component</span> <span class="pl-s"><span class="pl-pds">'</span>login<span class="pl-pds">'</span></span>, <span class="pl-v">template</span><span class="pl-k">:</span> <span class="pl-s"><span class="pl-pds">'</span>#tl-login<span class="pl-pds">'</span></span> <span class="pl-v">data</span><span class="pl-k">:</span> {} <span class="pl-v">methods</span><span class="pl-k">:</span> <span class="pl-en">str</span><span class="pl-k">:</span> (<span class="pl-smi">x</span>) <span class="pl-k">-&gt;</span> <span class="pl-c1">JSON</span>.<span class="pl-en">stringify</span> x</pre></div> <p dir="auto">But as it began to run, <code class="notranslate">this.str</code> is <code class="notranslate">undefined</code>:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="(function() { this.str;this.$parent.me;return this.str(this.$parent.me) })"><pre class="notranslate"><span class="pl-kos">(</span><span class="pl-k">function</span><span class="pl-kos">(</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-c1">str</span><span class="pl-kos">;</span><span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">$parent</span><span class="pl-kos">.</span><span class="pl-c1">me</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-en">str</span><span class="pl-kos">(</span><span class="pl-smi">this</span><span class="pl-kos">.</span><span class="pl-c1">$parent</span><span class="pl-kos">.</span><span class="pl-c1">me</span><span class="pl-kos">)</span> <span class="pl-kos">}</span><span class="pl-kos">)</span></pre></div> <p dir="auto">Code(before compilation) can be found at <a href="https://github.com/jiyinyiyong/meal-ordering">https://github.com/jiyinyiyong/meal-ordering</a><br> The code running online: <a href="http://repo.tiye.me/meal-ordering/" rel="nofollow">http://repo.tiye.me/meal-ordering/</a></p> <p dir="auto">This usage is not in the docs but talked at: <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="34151930" data-permission-text="Title is private" data-url="https://github.com/vuejs/Discussion/issues/29" data-hovercard-type="issue" data-hovercard-url="/vuejs/Discussion/issues/29/hovercard" href="https://github.com/vuejs/Discussion/issues/29">vuejs/Discussion#29</a></p>
0
<p dir="auto">Challenge <a href="http://www.freecodecamp.com/challenges/waypoint-bring-your-javascript-slot-machine-to-life" rel="nofollow">http://www.freecodecamp.com/challenges/waypoint-bring-your-javascript-slot-machine-to-life</a> has an issue. Please describe how to reproduce it, and include links to screenshots if possible.</p> <p dir="auto">Okay typing $($( into the code editor crashes it. The tab hangs; I can't click any of the buttons in the left sidebar like reset, and I can't type any more into the code editor.</p> <p dir="auto">There were three other people in the chat with the same problem, so it's not just me. I'm using the latest Opera on Mac OSX; one of them said she was using Chrome and the other said he was using Firefox. So it's everyone and every browser!</p> <p dir="auto">The fix that worked for all of us was to clear the browser cache and reload the page, and then copy and paste the</p> <p dir="auto">And we are all afraid to try typing it in any of the other lessons and are just copy/pasting it from here on out. So in my screenshot it's there because I copied and pasted it over three times, but actually when I typed the very first $($( at the top it froze.</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/13206606/9458730/2306da6e-4ac0-11e5-82e0-cf2c3dd648da.png"><img src="https://cloud.githubusercontent.com/assets/13206606/9458730/2306da6e-4ac0-11e5-82e0-cf2c3dd648da.png" alt="screen shot 2015-08-25 at 12 22 45 am" style="max-width: 100%;"></a></p>
<p dir="auto">Challenge <a href="http://www.freecodecamp.com/challenges/waypoint-learn-how-script-tags-and-document-ready-work" rel="nofollow">http://www.freecodecamp.com/challenges/waypoint-learn-how-script-tags-and-document-ready-work</a> has an issue. Please describe how to reproduce it, and include links to screenshots if possible.</p> <p dir="auto">I can get all tests to pass but last - it will not accept my closing tags no matter what!<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/11319764/9368776/ea353bd8-468a-11e5-9ae5-9cc5ca42d571.png"><img src="https://cloud.githubusercontent.com/assets/11319764/9368776/ea353bd8-468a-11e5-9ae5-9cc5ca42d571.png" alt="scriptclose" style="max-width: 100%;"></a></p> <p dir="auto">FIX - i can only get it to work with odd spacings<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/11319764/9368841/5c5e4f2e-468b-11e5-8265-21899fae8d98.png"><img src="https://cloud.githubusercontent.com/assets/11319764/9368841/5c5e4f2e-468b-11e5-8265-21899fae8d98.png" alt="fix" style="max-width: 100%;"></a></p>
0
<p dir="auto">Challenge <a href="http://freecodecamp.com/challenges/waypoint-iterate-with-javascript-while-loops" rel="nofollow">http://freecodecamp.com/challenges/waypoint-iterate-with-javascript-while-loops</a> has an issue. Please describe how to reproduce it, and include links to screenshots if possible.</p> <p dir="auto">This isn't a bug but a problem with the wording in the instructions. The exercise is for a while loop, but at the bottom of the instructions it says "Let's try getting a FOR loop to work..."</p> <p dir="auto">Nothing major but I figure you would like to correct it for clarity.</p> <p dir="auto">Thanks!<br> Enrique</p>
<p dir="auto">Challenge <a href="http://freecodecamp.com/challenges/waypoint-iterate-with-javascript-while-loops" rel="nofollow">http://freecodecamp.com/challenges/waypoint-iterate-with-javascript-while-loops</a> has an issue.</p> <p dir="auto">Text reads, "Let's try getting a for loop to work by pushing values to an array." It should instead read, "Let's try getting a while loop to work by pushing values to an array."</p>
1
<p dir="auto"><a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/NHDaly/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/NHDaly">@NHDaly</a> and I found this the day before juliacon, but forgot to open an issue.<br> I think <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/Keno/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/Keno">@Keno</a>'s theory was that the <code class="notranslate">literal_pow</code> stuff broke this.</p> <p dir="auto">Basically constant folding stops for exponents greater than 4.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; @code_typed (()-&gt;10^4)() CodeInfo( 1 ─ nothing::Nothing 2 ┄ %2 = φ (#1 =&gt; 10, #3 =&gt; %7)::Int64 │ %3 = φ (#1 =&gt; 3, #3 =&gt; %4)::Int64 │ %4 = Base.sub_int(%3, 1)::Int64 │ %5 = Base.slt_int(0, %4)::Bool └── goto #4 if not %5 3 ─ %7 = Base.mul_int(%2, %2)::Int64 └── goto #2 4 ─ goto #5 5 ─ goto #6 6 ─ goto #7 7 ─ return %2 ) =&gt; Int64 julia&gt; @code_typed (()-&gt;10^3)() CodeInfo( 1 ─ return 1000 ) =&gt; Int64 julia&gt; @code_typed (()-&gt;10^2)() CodeInfo( 1 ─ return 100 ) =&gt; Int64 julia&gt; @code_typed (()-&gt;10^1)() CodeInfo( 1 ─ return 10 ) =&gt; Int64 julia&gt; @code_typed (()-&gt;10^0)() CodeInfo( 1 ─ return 1 ) =&gt; Int64 julia&gt; @code_typed (()-&gt;10^-1)() CodeInfo( 1 ─ return 0.1 ) =&gt; Float64 julia&gt; @code_typed (()-&gt;10^-2)() CodeInfo( 1 ─ return 0.010000000000000002 ) =&gt; Float64 julia&gt; @code_typed (()-&gt;10^-3)() CodeInfo( 1 ─ return 0.0010000000000000002 ) =&gt; Float64 julia&gt; @code_typed (()-&gt;10^-4)() CodeInfo( 1 ─ %1 = $(Expr(:foreigncall, &quot;llvm.pow.f64&quot;, Float64, svec(Float64, Float64), 0, :(:llvmcall), 0.1, 4.0, 4.0, 0.1))::Float64 └── return %1 ) =&gt; Float64"><pre class="notranslate"><code class="notranslate">julia&gt; @code_typed (()-&gt;10^4)() CodeInfo( 1 ─ nothing::Nothing 2 ┄ %2 = φ (#1 =&gt; 10, #3 =&gt; %7)::Int64 │ %3 = φ (#1 =&gt; 3, #3 =&gt; %4)::Int64 │ %4 = Base.sub_int(%3, 1)::Int64 │ %5 = Base.slt_int(0, %4)::Bool └── goto #4 if not %5 3 ─ %7 = Base.mul_int(%2, %2)::Int64 └── goto #2 4 ─ goto #5 5 ─ goto #6 6 ─ goto #7 7 ─ return %2 ) =&gt; Int64 julia&gt; @code_typed (()-&gt;10^3)() CodeInfo( 1 ─ return 1000 ) =&gt; Int64 julia&gt; @code_typed (()-&gt;10^2)() CodeInfo( 1 ─ return 100 ) =&gt; Int64 julia&gt; @code_typed (()-&gt;10^1)() CodeInfo( 1 ─ return 10 ) =&gt; Int64 julia&gt; @code_typed (()-&gt;10^0)() CodeInfo( 1 ─ return 1 ) =&gt; Int64 julia&gt; @code_typed (()-&gt;10^-1)() CodeInfo( 1 ─ return 0.1 ) =&gt; Float64 julia&gt; @code_typed (()-&gt;10^-2)() CodeInfo( 1 ─ return 0.010000000000000002 ) =&gt; Float64 julia&gt; @code_typed (()-&gt;10^-3)() CodeInfo( 1 ─ return 0.0010000000000000002 ) =&gt; Float64 julia&gt; @code_typed (()-&gt;10^-4)() CodeInfo( 1 ─ %1 = $(Expr(:foreigncall, "llvm.pow.f64", Float64, svec(Float64, Float64), 0, :(:llvmcall), 0.1, 4.0, 4.0, 0.1))::Float64 └── return %1 ) =&gt; Float64 </code></pre></div> <p dir="auto">LLVM actually has our back here though.<br> It will constant fold for all negative integer powers I think.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; @code_llvm (()-&gt;10^-4)() ; @ REPL[15]:1 within `#35' define double @&quot;julia_#35_16849&quot;() { top: ret double 0x3F1A36E2EB1C432E } julia&gt; @code_llvm (()-&gt;10^-100)() ; @ REPL[19]:1 within `#43' define double @&quot;julia_#43_16854&quot;() { top: ret double 0x2B2BFF2EE48E055C }"><pre class="notranslate"><code class="notranslate">julia&gt; @code_llvm (()-&gt;10^-4)() ; @ REPL[15]:1 within `#35' define double @"julia_#35_16849"() { top: ret double 0x3F1A36E2EB1C432E } julia&gt; @code_llvm (()-&gt;10^-100)() ; @ REPL[19]:1 within `#43' define double @"julia_#43_16854"() { top: ret double 0x2B2BFF2EE48E055C } </code></pre></div> <p dir="auto">But for positive powers it only does 1 extra: 10^4</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; @code_llvm (()-&gt;10^4)() ; @ REPL[16]:1 within `#37' define i64 @&quot;julia_#37_16850&quot;() { top: ret i64 10000 } julia&gt; @code_llvm (()-&gt;10^5)() ; @ REPL[17]:1 within `#39' define i64 @&quot;julia_#39_16851&quot;() { L21.lr.ph: ; ┌ @ none within `literal_pow' ; │┌ @ none within `macro expansion' ; ││┌ @ intfuncs.jl:221 within `^' ; │││┌ @ intfuncs.jl:208 within `power_by_squaring' br label %L21 L21: ; preds = %L21.lr.ph, %L21 %0 = phi i64 [ 1, %L21.lr.ph ], [ %2, %L21 ] %value_phi35 = phi i64 [ 10, %L21.lr.ph ], [ %1, %L21 ] ; ││││ @ intfuncs.jl:209 within `power_by_squaring' ; ││││┌ @ int.jl:54 within `*' %1 = mul i64 %value_phi35, %value_phi35 ; ││││└ ; ││││ @ intfuncs.jl:208 within `power_by_squaring' ; ││││┌ @ int.jl:52 within `-' %2 = add nsw i64 %0, -1 ; ││││└ ; ││││┌ @ operators.jl:341 within `&gt;=' ; │││││┌ @ int.jl:410 within `&lt;=' %3 = icmp slt i64 %0, 1 ; ││││└└ br i1 %3, label %L23, label %L21 L23: ; preds = %L21 %phitmp = mul i64 %1, 10 ; └└└└ ret i64 %phitmp }"><pre class="notranslate"><code class="notranslate">julia&gt; @code_llvm (()-&gt;10^4)() ; @ REPL[16]:1 within `#37' define i64 @"julia_#37_16850"() { top: ret i64 10000 } julia&gt; @code_llvm (()-&gt;10^5)() ; @ REPL[17]:1 within `#39' define i64 @"julia_#39_16851"() { L21.lr.ph: ; ┌ @ none within `literal_pow' ; │┌ @ none within `macro expansion' ; ││┌ @ intfuncs.jl:221 within `^' ; │││┌ @ intfuncs.jl:208 within `power_by_squaring' br label %L21 L21: ; preds = %L21.lr.ph, %L21 %0 = phi i64 [ 1, %L21.lr.ph ], [ %2, %L21 ] %value_phi35 = phi i64 [ 10, %L21.lr.ph ], [ %1, %L21 ] ; ││││ @ intfuncs.jl:209 within `power_by_squaring' ; ││││┌ @ int.jl:54 within `*' %1 = mul i64 %value_phi35, %value_phi35 ; ││││└ ; ││││ @ intfuncs.jl:208 within `power_by_squaring' ; ││││┌ @ int.jl:52 within `-' %2 = add nsw i64 %0, -1 ; ││││└ ; ││││┌ @ operators.jl:341 within `&gt;=' ; │││││┌ @ int.jl:410 within `&lt;=' %3 = icmp slt i64 %0, 1 ; ││││└└ br i1 %3, label %L23, label %L21 L23: ; preds = %L21 %phitmp = mul i64 %1, 10 ; └└└└ ret i64 %phitmp } </code></pre></div> <p dir="auto">Was reminded when this came up in <a href="https://discourse.julialang.org/t/no-constant-expression-elimination-for-e-g-2-24-1/30964/8" rel="nofollow">https://discourse.julialang.org/t/no-constant-expression-elimination-for-e-g-2-24-1/30964/8</a></p>
<p dir="auto">Have a look at:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; f() = 2^5; @code_native f() .text ; Function f { ; Location: none:1 ; Function literal_pow; { ; Location: none ; Function macro expansion; { ; Location: none ; Function ^; { ; Location: none:1 pushq %rax movabsq $power_by_squaring, %rax movl $2, %edi movl $5, %esi callq *%rax ;}}} popq %rcx retq nopl (%rax) ;}"><pre class="notranslate"><code class="notranslate">julia&gt; f() = 2^5; @code_native f() .text ; Function f { ; Location: none:1 ; Function literal_pow; { ; Location: none ; Function macro expansion; { ; Location: none ; Function ^; { ; Location: none:1 pushq %rax movabsq $power_by_squaring, %rax movl $2, %edi movl $5, %esi callq *%rax ;}}} popq %rcx retq nopl (%rax) ;} </code></pre></div> <p dir="auto">This behaviour is weird. Since the result is completely fixed, shouldn't it compile all the way down to "return this predefined number" instead of requiring a new function call?<br> To make things weirder, the following functions <em>do</em> compile down to "return this number":<br> <code class="notranslate">m() = 2^8; n() = 3^4; g() = 2.0^5; h() = 2^5.0, k() = 1&lt;&lt;5</code><br> In practice, this means that running <code class="notranslate">k()</code> is unnecessarily ~3x faster than <code class="notranslate">f()</code>. Is this a bug that should be fixed?</p> <h3 dir="auto">Environment:</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="julia&gt; versioninfo() Julia Version 1.0.0 Commit 5d4eaca0c9 (2018-08-08 20:58 UTC) Platform Info: OS: Linux (x86_64-pc-linux-gnu) CPU: Intel(R) Core(TM) i5-4210H CPU @ 2.90GHz WORD_SIZE: 64 LIBM: libopenlibm LLVM: libLLVM-6.0.0 (ORCJIT, haswell) Environment: JULIA_EDITOR = atom -a JULIA_NUM_THREADS = 2"><pre class="notranslate"><code class="notranslate">julia&gt; versioninfo() Julia Version 1.0.0 Commit 5d4eaca0c9 (2018-08-08 20:58 UTC) Platform Info: OS: Linux (x86_64-pc-linux-gnu) CPU: Intel(R) Core(TM) i5-4210H CPU @ 2.90GHz WORD_SIZE: 64 LIBM: libopenlibm LLVM: libLLVM-6.0.0 (ORCJIT, haswell) Environment: JULIA_EDITOR = atom -a JULIA_NUM_THREADS = 2 </code></pre></div>
1
<p dir="auto">I'm submitting a feature request</p> <p dir="auto"><strong>Current behavior</strong><br> The HostListener decorator is a very useful feature. We use it a lot. Very often the events we subscribe to come from the document.<br> Very often, when the HostListener fires for document level events, we need to perform additional checks before performing any change to the application. Most times the handler is invoked, nothing happens to the app. Since HostListener marks the component tree as dirty, it leads to heavy re-evaluation of many components, and hurts performance (the tree is on Push but some paths are very long with HostListener near the leafs).</p> <p dir="auto"><strong>Expected behavior</strong><br> I would appreciate a way to use the HostListener without triggering a change detection for the sub tree.</p> <p dir="auto"><strong>What is the motivation / use case for changing the behavior?</strong><br> An example use-case is in directives checking for clicks outside a component. They are very common and have few implementations such as <a href="url">https://github.com/chliebel/angular2-click-outside/blob/master/clickOutside.directive.ts</a> and <a href="url">https://christianliebel.com/2016/05/angular-2-a-simple-click-outside-directive/</a>.<br> Using these directives leads to heavy evaluation of many components.</p> <p dir="auto"><strong>Angular version:</strong> 4.0.2</p>
<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><br> Currently if one binds lots of event listeners on <code class="notranslate">document</code> or <code class="notranslate">window</code>, i.e. components/directives used via ngFor, application can crawl to a slow</p> <p dir="auto"><strong>Expected behavior</strong><br> Binding event listeners should be simple without having to architect around performance concerns</p> <p dir="auto"><strong>Minimal reproduction of the problem with instructions</strong><br> Warning: If running the preview, run when not afraid of browser crashing (even on the desktop)<br> <a href="http://plnkr.co/edit/oMMi6tFR3YZMKtMqvSys?p=info" rel="nofollow">http://plnkr.co/edit/oMMi6tFR3YZMKtMqvSys?p=info</a></p> <p dir="auto"><strong>What is the motivation / use case for changing the behavior?</strong><br> I believe a good opportunity lies here to have Angular optimize handling the event delegation through binding single event listeners on <code class="notranslate">document</code> and <code class="notranslate">window</code> for global events and iterating through event listeners in order to allow for simpler application design around management of global events.</p> <p dir="auto"><strong>Please tell us about your environment:</strong><br> macOS Sierra 10.12.3</p> <ul dir="auto"> <li> <p dir="auto"><strong>Angular version:</strong> 4.0.1</p> </li> <li> <p dir="auto"><strong>Browser:</strong> all</p> </li> <li> <p dir="auto"><strong>Language:</strong> all</p> </li> <li> <p dir="auto"><strong>Node (for AoT issues):</strong> <code class="notranslate">node --version</code> = N/A</p> </li> </ul>
1
<h1 dir="auto">Feature request</h1> <h2 dir="auto">Is your feature request related to a problem? Please describe.</h2> <p dir="auto">My use case is that we have a 1MB json file that is needed to render the page. No problem on the server, but we don't want to send this data to client from getInitialProps as it'll make the pagesize huge.</p> <p dir="auto">So, we want to SSR initially, then load the JSON file via ajax on the client and only then trigger the initial client-side hydration/render once the file has loaded.</p> <h2 dir="auto">Describe the solution you'd like</h2> <p dir="auto">A way to supply a promise to next/client that can awaited before the client-side hydration takes place.</p> <h2 dir="auto">Describe alternatives you've considered</h2> <p dir="auto">If we cannot wait to delay the render, the initial SSR completes, then we have to replace it with a loading spinner on the client side while the file finishes loading. That's obviously not ideal, as it means that:</p> <ul dir="auto"> <li>The content renders server-side.</li> <li>Then it disappears on the client initial render, replaced by a spinner.</li> <li>And then returns as before, on a client later render after the file has loaded.</li> </ul> <p dir="auto">You can imagine how that gives a pretty confusing experience for the user.</p> <p dir="auto">I've got it working by either:</p> <ul dir="auto"> <li>Directly adding another await call inside the next/client/index render method in node_modules</li> <li>Using a hacky innerHTML workaround (see comment below),</li> </ul> <p dir="auto">Both these ways have problems, and so I'd prefer a real solution.</p> <h2 dir="auto">Additional context</h2> <p dir="auto">I'm happy to do a PR if you can suggest me on the right approach to take.</p>
<p dir="auto">I just wanted to see if there was a reason why the nextjs scripts like page/ and app.js load in as High priority assets. It seems to me that as high priority, they block DOMContentLoaded, and we could get quicker page rendering if we made them low priority assets.</p> <p dir="auto">It also seems like there was <a href="https://github.com/zeit/next.js/issues/1436" data-hovercard-type="issue" data-hovercard-url="/vercel/next.js/issues/1436/hovercard">some intention to have them as low priority assets in #1436</a>: the scripts all have <code class="notranslate">async=""</code> on them in production, which should make them low priority, but the presence of <a href="https://github.com/zeit/next.js/blob/master/server/document.js#L43">these preload links</a> makes them high priority. For instance this is <a class="issue-link js-issue-link notranslate" rel="noopener noreferrer nofollow" href="https://linear.app/vercel/issue/NEXT-news">next-news</a>.now.sh:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/300439/28184328-d82883c2-67c7-11e7-817b-f9d2f04be364.png"><img src="https://user-images.githubusercontent.com/300439/28184328-d82883c2-67c7-11e7-817b-f9d2f04be364.png" alt="screen shot 2017-07-13 at 12 34 45 pm" style="max-width: 100%;"></a></p> <p dir="auto">More on priorities in chrome: <a href="https://medium.com/reloading/preload-prefetch-and-priorities-in-chrome-776165961bbf" rel="nofollow">https://medium.com/reloading/preload-prefetch-and-priorities-in-chrome-776165961bbf</a></p> <hr> <p dir="auto">I did an experiment with throttling on my project, with throttling to simulate a 3G connection (Regular 3G preset in Chrome).</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" var rendered = await nextApp.renderToHTML(req, res, '/', ''); rendered = rendered.replace(/&lt;link rel=&quot;preload&quot; href=&quot;\/_next\/[a-zA-Z0-9\-]+\/.+?&quot; as=&quot;script&quot;\/&gt;/g, ''); res.send(rendered);"><pre class="notranslate"><code class="notranslate"> var rendered = await nextApp.renderToHTML(req, res, '/', ''); rendered = rendered.replace(/&lt;link rel="preload" href="\/_next\/[a-zA-Z0-9\-]+\/.+?" as="script"\/&gt;/g, ''); res.send(rendered); </code></pre></div> <ul dir="auto"> <li>Standard next.js (high priority): DOMContentLoaded in 10.26 seconds</li> <li>Removing rel=preload links (this makes them medium priority): DOMContentLoaded in 7.87 seconds</li> </ul> <p dir="auto">This seems to make a big difference for mobile users.</p> <ul dir="auto"> <li>[x ] 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>
0
<ul dir="auto"> <li>[ x ] 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>[ x ] 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> <li>Operating System version: Mac Catalina 10.15.7 (19H2)</li> <li>Java version: 1.8.0_231</li> <li>SpringBoot: 1.5.9.RELEASE</li> </ul> <h3 dir="auto">Steps to reproduce this issue</h3> <ol dir="auto"> <li>基于spring boot 1.5.x搭建demo项目并编写测试controller</li> <li>访问该测试controller,默认返回json格式的response</li> <li>引用以下包:</li> </ol> <div class="highlight highlight-text-xml notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" &lt;dependency&gt; &lt;groupId&gt;org.apache.dubbo&lt;/groupId&gt; &lt;artifactId&gt;dubbo-spring-boot-starter&lt;/artifactId&gt; &lt;version&gt;2.7.7&lt;/version&gt; &lt;/dependency&gt; &lt;dependency&gt; &lt;groupId&gt;io.springfox&lt;/groupId&gt; &lt;artifactId&gt;springfox-swagger2&lt;/artifactId&gt; &lt;version&gt;2.9.2&lt;/version&gt; &lt;/dependency&gt; &lt;dependency&gt; &lt;groupId&gt;io.springfox&lt;/groupId&gt; &lt;artifactId&gt;springfox-swagger-ui&lt;/artifactId&gt; &lt;version&gt;2.9.2&lt;/version&gt; &lt;/dependency&gt; &lt;dependency&gt; &lt;groupId&gt;io.swagger&lt;/groupId&gt; &lt;artifactId&gt;swagger-jersey2-jaxrs&lt;/artifactId&gt; &lt;version&gt;1.5.9&lt;/version&gt; &lt;/dependency&gt;"><pre class="notranslate"> &lt;<span class="pl-ent">dependency</span>&gt; &lt;<span class="pl-ent">groupId</span>&gt;org.apache.dubbo&lt;/<span class="pl-ent">groupId</span>&gt; &lt;<span class="pl-ent">artifactId</span>&gt;dubbo-spring-boot-starter&lt;/<span class="pl-ent">artifactId</span>&gt; &lt;<span class="pl-ent">version</span>&gt;2.7.7&lt;/<span class="pl-ent">version</span>&gt; &lt;/<span class="pl-ent">dependency</span>&gt; &lt;<span class="pl-ent">dependency</span>&gt; &lt;<span class="pl-ent">groupId</span>&gt;io.springfox&lt;/<span class="pl-ent">groupId</span>&gt; &lt;<span class="pl-ent">artifactId</span>&gt;springfox-swagger2&lt;/<span class="pl-ent">artifactId</span>&gt; &lt;<span class="pl-ent">version</span>&gt;2.9.2&lt;/<span class="pl-ent">version</span>&gt; &lt;/<span class="pl-ent">dependency</span>&gt; &lt;<span class="pl-ent">dependency</span>&gt; &lt;<span class="pl-ent">groupId</span>&gt;io.springfox&lt;/<span class="pl-ent">groupId</span>&gt; &lt;<span class="pl-ent">artifactId</span>&gt;springfox-swagger-ui&lt;/<span class="pl-ent">artifactId</span>&gt; &lt;<span class="pl-ent">version</span>&gt;2.9.2&lt;/<span class="pl-ent">version</span>&gt; &lt;/<span class="pl-ent">dependency</span>&gt; &lt;<span class="pl-ent">dependency</span>&gt; &lt;<span class="pl-ent">groupId</span>&gt;io.swagger&lt;/<span class="pl-ent">groupId</span>&gt; &lt;<span class="pl-ent">artifactId</span>&gt;swagger-jersey2-jaxrs&lt;/<span class="pl-ent">artifactId</span>&gt; &lt;<span class="pl-ent">version</span>&gt;1.5.9&lt;/<span class="pl-ent">version</span>&gt; &lt;/<span class="pl-ent">dependency</span>&gt;</pre></div> <ol start="4" dir="auto"> <li>重启demo项目并再次访问测试controller,这时会返回xml格式的response</li> </ol> <h3 dir="auto">Expected Result</h3> <p dir="auto">引用swagger不改变spring boot的默认http message converter组织方式,不影响各接口的response格式。</p> <h3 dir="auto">Actual Result</h3> <p dir="auto">引用swagger后改变了spring boot的默认http message converter组织方式,进而改变了各接口的response格式。</p> <h3 dir="auto">Trouble Shooting</h3> <ol dir="auto"> <li>dubbo rest集成了swagger,用到了相关的类,比如:<code class="notranslate">io.swagger.jaxrs.listing.BaseApiListingResource</code>。</li> <li>因此必须引用 <code class="notranslate">swagger-jersey2-jaxrs</code> 包。</li> <li><code class="notranslate">swagger-jersey2-jaxrs</code> 包引用了 <code class="notranslate">jackson-dataformat-xml</code>包。</li> <li><code class="notranslate">jackson-dataformat-xml</code>内部的 <code class="notranslate">XmlMapper</code>类会改变SpringBoot的HttpMessageConverter组装过程,从而改变默认response格式。</li> </ol>
<ul dir="auto"> <li>[ Y] 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>[ Y] 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: windows 10 &amp; centos 7.5</li> <li>Java version: 1.8</li> </ul> <h3 dir="auto">Steps to reproduce this issue</h3> <ol dir="auto"> <li>start app<br> 该问题有时候出现 有时候又不出现,暂时还没定位到问题。<br> 看现有的issue和我有些不一样 如果每次都出现,那就很好处理了,50%的概率启动出现,url not found的报错,我看下来是,url没有注册进去,经常只有v1可用,s1不可用。</li> </ol> <p dir="auto">bootstrap:<br> protocols:<br> dubbo:<br> name: dubbo<br> port: 30881<br> http:<br> name: rest<br> port: 30991<br> server: netty<br> contextpath: biz<br> keepalive: false<br> extension: com.XXX.EirExceptionMapper</p> <p dir="auto"><a class="user-mention notranslate" data-hovercard-type="organization" data-hovercard-url="/orgs/path/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/path">@path</a>("s1")<br> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/consumes/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/consumes">@consumes</a>({MediaType.APPLICATION_JSON, MediaType.TEXT_XML})<br> <a class="user-mention notranslate" data-hovercard-type="organization" data-hovercard-url="/orgs/produces/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/produces">@produces</a>({MediaType.APPLICATION_JSON, MediaType.TEXT_XML})<br> public interface Facade1 {<br> }</p> <p dir="auto"><a class="user-mention notranslate" data-hovercard-type="organization" data-hovercard-url="/orgs/path/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/path">@path</a>("v1")<br> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/consumes/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/consumes">@consumes</a>({MediaType.APPLICATION_JSON, MediaType.TEXT_XML})<br> <a class="user-mention notranslate" data-hovercard-type="organization" data-hovercard-url="/orgs/produces/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/produces">@produces</a>({MediaType.APPLICATION_JSON, MediaType.TEXT_XML})<br> public interface Facade1 {<br> }</p> <p dir="auto">javax.ws.rs.NotFoundException: RESTEASY003210: Could not find resource for full path: <a href="http://localhost:30991/biz/s1/eirinfo?no=2020050784981002" rel="nofollow">http://localhost:30991/biz/s1/eirinfo?no=2020050784981002</a><br> at org.jboss.resteasy.core.registry.ClassNode.match(ClassNode.java:61)<br> at org.jboss.resteasy.core.registry.RootClassNode.match(RootClassNode.java:47)<br> at org.jboss.resteasy.core.ResourceMethodRegistry.getResourceInvoker(ResourceMethodRegistry.java:442)<br> at org.jboss.resteasy.core.SynchronousDispatcher.getInvoker(SynchronousDispatcher.java:300)<br> at org.jboss.resteasy.core.SynchronousDispatcher.lambda$invoke$4(SynchronousDispatcher.java:221)<br> at org.jboss.resteasy.core.SynchronousDispatcher.lambda$preprocess$0(SynchronousDispatcher.java:135)<br> at org.jboss.resteasy.core.interception.PreMatchContainerRequestContext.filter(PreMatchContainerRequestContext.java:355)<br> at org.jboss.resteasy.core.SynchronousDispatcher.preprocess(SynchronousDispatcher.java:138)<br> at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:215)<br> at org.jboss.resteasy.plugins.server.netty.RequestDispatcher.service(RequestDispatcher.java:83)<br> at org.jboss.resteasy.plugins.server.netty.RequestHandler.channelRead0(RequestHandler.java:51)<br> at io.netty.channel.SimpleChannelInboundHandler.channelRead(SimpleChannelInboundHandler.java:105)<br> at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:362)<br> at io.netty.channel.AbstractChannelHandlerContext.access$600(AbstractChannelHandlerContext.java:38)<br> at io.netty.channel.AbstractChannelHandlerContext$7.run(AbstractChannelHandlerContext.java:353)<br> at io.netty.util.concurrent.AbstractEventExecutor.safeExecute$$$capture(AbstractEventExecutor.java:163)<br> at io.netty.util.concurrent.AbstractEventExecutor.safeExecute(AbstractEventExecutor.java)<br> at io.netty.util.concurrent.SingleThreadEventExecutor.runAllTasks(SingleThreadEventExecutor.java:404)<br> at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:466)<br> at io.netty.util.concurrent.SingleThreadEventExecutor$5.run(SingleThreadEventExecutor.java:897)<br> at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)<br> at java.lang.Thread.run(Thread.java:748)</p>
0
<p dir="auto">We currently use scientific notation (E-notation) to print large integer tensors. We shouldn't do this because it hides meaningful digits and because E-notation corresponds to floating point data types in Python.</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&gt;&gt;&gt; x = torch.ones(525076, dtype=torch.int) &gt;&gt;&gt; x.sum() tensor(5.2508e+05) &gt;&gt;&gt; x.sum().item() 525076"><pre class="notranslate"><span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-s1">x</span> <span class="pl-c1">=</span> <span class="pl-s1">torch</span>.<span class="pl-en">ones</span>(<span class="pl-c1">525076</span>, <span class="pl-s1">dtype</span><span class="pl-c1">=</span><span class="pl-s1">torch</span>.<span class="pl-s1">int</span>) <span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-s1">x</span>.<span class="pl-en">sum</span>() <span class="pl-en">tensor</span>(<span class="pl-c1">5.2508e+05</span>) <span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-s1">x</span>.<span class="pl-en">sum</span>().<span class="pl-en">item</span>() <span class="pl-c1">525076</span></pre></div>
<h2 dir="auto"><g-emoji class="g-emoji" alias="rocket" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/1f680.png">🚀</g-emoji> Feature</h2> <p dir="auto">It'd be great for developer productivity if file lists were shared among build systems.</p> <h2 dir="auto">Motivation</h2> <p dir="auto">We're maintaining 3 different build systems right now (CMake, two FB-internal flavors of Buck) and Bazel support is on the way - <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="587251362" data-permission-text="Title is private" data-url="https://github.com/pytorch/pytorch/issues/35316" data-hovercard-type="issue" data-hovercard-url="/pytorch/pytorch/issues/35316/hovercard" href="https://github.com/pytorch/pytorch/issues/35316">#35316</a> . Parts of buck build are exposed as <a href="https://github.com/pytorch/pytorch/blob/master/tools/build_variables.bzl">https://github.com/pytorch/pytorch/blob/master/tools/build_variables.bzl</a> . Today they duplicate lists of files manually (including upcoming <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="586429451" data-permission-text="Title is private" data-url="https://github.com/pytorch/pytorch/issues/35220" data-hovercard-type="pull_request" data-hovercard-url="/pytorch/pytorch/pull/35220/hovercard" href="https://github.com/pytorch/pytorch/pull/35220">#35220</a>). It's bad for developer productivity as it's easy to forget to add new file.</p> <h2 dir="auto">Pitch</h2> <p dir="auto">We could put the lists of files in a very simple format - just a text file with file names would do, or a very simple python program. All major build systems support importing external file lists. For buck/bazel it can be done by writing .bzl function and importing results.</p> <p dir="auto">For CMake simple proof of concept is <a href="https://gist.github.com/dzhulgakov/8f6cc0a7fd710b8f29689ba5e5858f7d">https://gist.github.com/dzhulgakov/8f6cc0a7fd710b8f29689ba5e5858f7d</a></p> <h2 dir="auto">Alternatives</h2> <p dir="auto">Alternative is to use globs aggressively. It's not a full solution as we currently mix different targets in the same directory (e.g. python and no-python sources). And globs can be tricky with triggering incremental rebuilds correctly.</p> <p dir="auto">cc <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/kostmo/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/kostmo">@kostmo</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/malfet/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/malfet">@malfet</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>:</li> <li><strong>TensorFlow version (use command below)</strong>:</li> <li><strong>Python version</strong>: 2.7.11</li> <li><strong>Bazel version (if compiling from source)</strong>: 0.10.0</li> <li><strong>GCC/Compiler version (if compiling from source)</strong>: 4.8.5</li> <li><strong>CUDA/cuDNN version</strong>: CUDA 8.0/ cuDNN 7</li> <li><strong>GPU model and memory</strong>: N/A</li> <li><strong>Exact command to reproduce</strong>: see below</li> </ul> <h3 dir="auto">Describe the problem</h3> <p dir="auto">When reusing a variable in current variable scope, we should always reuse its regularization loss computation. But it will declare regularization loss multiple times when reusing PartitionedVariables in tf.layers. I have found that there is no special treatment for reusing regularization loss of PartitionedVariables in tf.layers .</p> <h3 dir="auto">Source code / logs</h3> <p dir="auto">Here is the small script can reproduce the result.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import tensorflow as tf partitioner = tf.fixed_size_partitioner(3) l2_regularizer = tf.contrib.layers.l2_regularizer(0.001) for i in xrange(2): with tf.variable_scope(tf.get_variable_scope(), partitioner=partitioner, reuse=False if i == 0 else True): inputs_tensor = tf.constant(1.0, shape=[100, 100]) logits = tf.layers.dense(inputs_tensor, 256, use_bias=False, name=&quot;fc&quot;, kernel_regularizer=l2_regularizer) print (tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES))"><pre class="notranslate"><code class="notranslate">import tensorflow as tf partitioner = tf.fixed_size_partitioner(3) l2_regularizer = tf.contrib.layers.l2_regularizer(0.001) for i in xrange(2): with tf.variable_scope(tf.get_variable_scope(), partitioner=partitioner, reuse=False if i == 0 else True): inputs_tensor = tf.constant(1.0, shape=[100, 100]) logits = tf.layers.dense(inputs_tensor, 256, use_bias=False, name="fc", kernel_regularizer=l2_regularizer) print (tf.get_collection(tf.GraphKeys.REGULARIZATION_LOSSES)) </code></pre></div> <p dir="auto">This short program should get result 3 because the PartitionedVariable has 3 shards. However, it got 6.</p> <p dir="auto">A pull request has been submitted here to fix this bug: <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="319867141" data-permission-text="Title is private" data-url="https://github.com/tensorflow/tensorflow/issues/19053" data-hovercard-type="pull_request" data-hovercard-url="/tensorflow/tensorflow/pull/19053/hovercard" href="https://github.com/tensorflow/tensorflow/pull/19053">#19053</a></p>
<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">I am using a stock example script provided in TensorFlow):<br> <a href="https://www.tensorflow.org/beta/tutorials/estimators/boosted_trees_model_understanding" rel="nofollow">https://www.tensorflow.org/beta/tutorials/estimators/boosted_trees_model_understanding</a></p> </li> <li> <p dir="auto">OS Platform and Distribution (e.g., Linux Ubuntu 16.04):<br> debian linux intel x86_64</p> </li> <li> <p dir="auto">Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device:<br> NA</p> </li> <li> <p dir="auto">TensorFlow installed from (source or binary):<br> binary via<br> pip install of tf2.0.0.rc1</p> </li> <li> <p dir="auto">TensorFlow version (use command below):<br> tf2.0.0.rc1</p> </li> <li> <p dir="auto">Python version:<br> 3.7.4</p> </li> <li> <p dir="auto">CUDA/cuDNN version:<br> How to determine?</p> </li> <li> <p dir="auto">GPU model and memory:<br> GeForce RTX 2070 8GB</p> </li> </ul> <p dir="auto">v2.0.0-rc0-101-gd2d2566 2.0.0-rc1</p> <blockquote> <p dir="auto">== check python ===================================================<br> python version: 3.7.4<br> python branch:<br> python build version: ('default', 'Aug 13 2019 20:35:49')<br> python compiler version: GCC 7.3.0<br> python implementation: CPython</p> <p dir="auto">== check os platform ===============================================<br> os: Linux<br> os kernel version: <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="115886302" data-permission-text="Title is private" data-url="https://github.com/tensorflow/tensorflow/issues/1" data-hovercard-type="issue" data-hovercard-url="/tensorflow/tensorflow/issues/1/hovercard" href="https://github.com/tensorflow/tensorflow/issues/1">#1</a> SMP Debian 4.19.37-5+deb10u2 (2019-08-08)<br> os release version: 4.19.0-5-amd64<br> os platform: Linux-4.19.0-5-amd64-x86_64-with-debian-10.1<br> linux distribution: ('debian', '10.1', '')<br> linux os distribution: ('debian', '10.1', '')<br> mac version: ('', ('', '', ''), '')<br> uname: uname_result(system='Linux', node='gsd', release='4.19.0-5-amd64', version='<a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="115886302" data-permission-text="Title is private" data-url="https://github.com/tensorflow/tensorflow/issues/1" data-hovercard-type="issue" data-hovercard-url="/tensorflow/tensorflow/issues/1/hovercard" href="https://github.com/tensorflow/tensorflow/issues/1">#1</a> SMP Debian 4.19.37-5+deb10u2 (2019-08-08)', machine='x86_64', processor='')<br> architecture: ('64bit', '')<br> machine: x86_64</p> <p dir="auto">== are we in docker =============================================<br> No</p> <p dir="auto">== compiler =====================================================<br> c++ (Debian 8.3.0-6) 8.3.0<br> Copyright (C) 2018 Free Software Foundation, Inc.<br> This is free software; see the source for copying conditions. There is NO<br> warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.</p> <p dir="auto">== check pips ===================================================<br> numpy 1.17.2<br> protobuf 3.9.1<br> tensorflow 2.0.0rc1</p> <p dir="auto">== check for virtualenv =========================================<br> False</p> <p dir="auto">== tensorflow import ============================================<br> tf.version.VERSION = 2.0.0-rc1<br> tf.version.GIT_VERSION = v2.0.0-rc0-101-gd2d2566<br> tf.version.COMPILER_VERSION = 7.3.1 20180303<br> 22191: find library=libpthread.so.0 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/bin/../lib/tls/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/bin/../lib/tls/haswell:/home/davis/anaconda3/envs/py3tf2/bin/../lib/tls/x86_64:/home/davis/anaconda3/envs/py3tf2/bin/../lib/tls:/home/davis/anaconda3/envs/py3tf2/bin/../lib/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/bin/../lib/haswell:/home/davis/anaconda3/envs/py3tf2/bin/../lib/x86_64:/home/davis/anaconda3/envs/py3tf2/bin/../lib (RPATH from file /home/davis/anaconda3/envs/py3tf2/bin/python)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/tls/haswell/x86_64/libpthread.so.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/tls/haswell/libpthread.so.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/tls/x86_64/libpthread.so.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/tls/libpthread.so.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/haswell/x86_64/libpthread.so.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/haswell/libpthread.so.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/x86_64/libpthread.so.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/libpthread.so.0<br> 22191: search cache=/etc/ld.so.cache<br> 22191: trying file=/lib/x86_64-linux-gnu/libpthread.so.0<br> 22191:<br> 22191: find library=libc.so.6 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/bin/../lib (RPATH from file /home/davis/anaconda3/envs/py3tf2/bin/python)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/libc.so.6<br> 22191: search cache=/etc/ld.so.cache<br> 22191: trying file=/lib/x86_64-linux-gnu/libc.so.6<br> 22191:<br> 22191: find library=libdl.so.2 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/bin/../lib (RPATH from file /home/davis/anaconda3/envs/py3tf2/bin/python)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/libdl.so.2<br> 22191: search cache=/etc/ld.so.cache<br> 22191: trying file=/lib/x86_64-linux-gnu/libdl.so.2<br> 22191:<br> 22191: find library=libutil.so.1 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/bin/../lib (RPATH from file /home/davis/anaconda3/envs/py3tf2/bin/python)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/libutil.so.1<br> 22191: search cache=/etc/ld.so.cache<br> 22191: trying file=/lib/x86_64-linux-gnu/libutil.so.1<br> 22191:<br> 22191: find library=librt.so.1 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/bin/../lib (RPATH from file /home/davis/anaconda3/envs/py3tf2/bin/python)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/librt.so.1<br> 22191: search cache=/etc/ld.so.cache<br> 22191: trying file=/lib/x86_64-linux-gnu/librt.so.1<br> 22191:<br> 22191: find library=libm.so.6 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/bin/../lib (RPATH from file /home/davis/anaconda3/envs/py3tf2/bin/python)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/libm.so.6<br> 22191: search cache=/etc/ld.so.cache<br> 22191: trying file=/lib/x86_64-linux-gnu/libm.so.6<br> 22191:<br> 22191:<br> 22191: calling init: /lib/x86_64-linux-gnu/libpthread.so.0<br> 22191:<br> 22191:<br> 22191: calling init: /lib/x86_64-linux-gnu/libc.so.6<br> 22191:<br> 22191:<br> 22191: calling init: /lib/x86_64-linux-gnu/libm.so.6<br> 22191:<br> 22191:<br> 22191: calling init: /lib/x86_64-linux-gnu/librt.so.1<br> 22191:<br> 22191:<br> 22191: calling init: /lib/x86_64-linux-gnu/libutil.so.1<br> 22191:<br> 22191:<br> 22191: calling init: /lib/x86_64-linux-gnu/libdl.so.2<br> 22191:<br> 22191:<br> 22191: initialize program: /home/davis/anaconda3/envs/py3tf2/bin/python<br> 22191:<br> 22191:<br> 22191: transferring control: /home/davis/anaconda3/envs/py3tf2/bin/python<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_heapq.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_opcode.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191: find library=libffi.so.6 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../tls/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../tls/haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../tls/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../tls:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_ctypes.cpython-37m-x86_64-linux-gnu.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../tls/haswell/x86_64/libffi.so.6<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../tls/haswell/libffi.so.6<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../tls/x86_64/libffi.so.6<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../tls/libffi.so.6<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../haswell/x86_64/libffi.so.6<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../haswell/libffi.so.6<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../x86_64/libffi.so.6<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libffi.so.6<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libffi.so.6<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_ctypes.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_struct.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191: find library=libmkl_rt.so [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../tls/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../tls/haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../tls/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../tls:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/_mklinit.cpython-37m-x86_64-linux-gnu.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../tls/haswell/x86_64/libmkl_rt.so<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../tls/haswell/libmkl_rt.so<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../tls/x86_64/libmkl_rt.so<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../tls/libmkl_rt.so<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../haswell/x86_64/libmkl_rt.so<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../haswell/libmkl_rt.so<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../x86_64/libmkl_rt.so<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_rt.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_rt.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/_mklinit.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/_mklinit.cpython-37m-x86_64-linux-gnu.so: error: symbol lookup error: undefined symbol: omp_get_num_threads (fatal)<br> 22191: find library=libiomp5.so [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/_mklinit.cpython-37m-x86_64-linux-gnu.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libiomp5.so<br> 22191:<br> 22191: find library=libgcc_s.so.1 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/bin/../lib (RPATH from file /home/davis/anaconda3/envs/py3tf2/bin/python)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/libgcc_s.so.1<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/bin/../lib/libgcc_s.so.1<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libiomp5.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/core/_multiarray_umath.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/math.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_datetime.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_pickle.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/core/_multiarray_tests.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/linalg/lapack_lite.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/linalg/_umath_linalg.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191: find library=libz.so.1 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_ctypes.cpython-37m-x86_64-linux-gnu.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libz.so.1<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libz.so.1<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/zlib.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_bz2.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191: find library=liblzma.so.5 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_ctypes.cpython-37m-x86_64-linux-gnu.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../liblzma.so.5<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../liblzma.so.5<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_lzma.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/grp.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_decimal.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/fft/fftpack_lite.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/mkl_fft/_pydfti.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/random/mtrand.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191: find library=libcrypto.so.1.1 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_ctypes.cpython-37m-x86_64-linux-gnu.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libcrypto.so.1.1<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libcrypto.so.1.1<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_hashlib.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_blake2.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_sha3.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_bisect.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_random.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_core.so<br> 22191:<br> 22191: find library=libittnotify.so [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/bin/../lib (RPATH from file /home/davis/anaconda3/envs/py3tf2/bin/python)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/libittnotify.so<br> 22191: search cache=/etc/ld.so.cache<br> 22191: search path=/lib/x86_64-linux-gnu/tls/haswell/x86_64:/lib/x86_64-linux-gnu/tls/haswell:/lib/x86_64-linux-gnu/tls/x86_64:/lib/x86_64-linux-gnu/tls:/lib/x86_64-linux-gnu/haswell/x86_64:/lib/x86_64-linux-gnu/haswell:/lib/x86_64-linux-gnu/x86_64:/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnu/tls/haswell/x86_64:/usr/lib/x86_64-linux-gnu/tls/haswell:/usr/lib/x86_64-linux-gnu/tls/x86_64:/usr/lib/x86_64-linux-gnu/tls:/usr/lib/x86_64-linux-gnu/haswell/x86_64:/usr/lib/x86_64-linux-gnu/haswell:/usr/lib/x86_64-linux-gnu/x86_64:/usr/lib/x86_64-linux-gnu:/lib/tls/haswell/x86_64:/lib/tls/haswell:/lib/tls/x86_64:/lib/tls:/lib/haswell/x86_64:/lib/haswell:/lib/x86_64:/lib:/usr/lib/tls/haswell/x86_64:/usr/lib/tls/haswell:/usr/lib/tls/x86_64:/usr/lib/tls:/usr/lib/haswell/x86_64:/usr/lib/haswell:/usr/lib/x86_64:/usr/lib (system search path)<br> 22191: trying file=/lib/x86_64-linux-gnu/tls/haswell/x86_64/libittnotify.so<br> 22191: trying file=/lib/x86_64-linux-gnu/tls/haswell/libittnotify.so<br> 22191: trying file=/lib/x86_64-linux-gnu/tls/x86_64/libittnotify.so<br> 22191: trying file=/lib/x86_64-linux-gnu/tls/libittnotify.so<br> 22191: trying file=/lib/x86_64-linux-gnu/haswell/x86_64/libittnotify.so<br> 22191: trying file=/lib/x86_64-linux-gnu/haswell/libittnotify.so<br> 22191: trying file=/lib/x86_64-linux-gnu/x86_64/libittnotify.so<br> 22191: trying file=/lib/x86_64-linux-gnu/libittnotify.so<br> 22191: trying file=/usr/lib/x86_64-linux-gnu/tls/haswell/x86_64/libittnotify.so<br> 22191: trying file=/usr/lib/x86_64-linux-gnu/tls/haswell/libittnotify.so<br> 22191: trying file=/usr/lib/x86_64-linux-gnu/tls/x86_64/libittnotify.so<br> 22191: trying file=/usr/lib/x86_64-linux-gnu/tls/libittnotify.so<br> 22191: trying file=/usr/lib/x86_64-linux-gnu/haswell/x86_64/libittnotify.so<br> 22191: trying file=/usr/lib/x86_64-linux-gnu/haswell/libittnotify.so<br> 22191: trying file=/usr/lib/x86_64-linux-gnu/x86_64/libittnotify.so<br> 22191: trying file=/usr/lib/x86_64-linux-gnu/libittnotify.so<br> 22191: trying file=/lib/tls/haswell/x86_64/libittnotify.so<br> 22191: trying file=/lib/tls/haswell/libittnotify.so<br> 22191: trying file=/lib/tls/x86_64/libittnotify.so<br> 22191: trying file=/lib/tls/libittnotify.so<br> 22191: trying file=/lib/haswell/x86_64/libittnotify.so<br> 22191: trying file=/lib/haswell/libittnotify.so<br> 22191: trying file=/lib/x86_64/libittnotify.so<br> 22191: trying file=/lib/libittnotify.so<br> 22191: trying file=/usr/lib/tls/haswell/x86_64/libittnotify.so<br> 22191: trying file=/usr/lib/tls/haswell/libittnotify.so<br> 22191: trying file=/usr/lib/tls/x86_64/libittnotify.so<br> 22191: trying file=/usr/lib/tls/libittnotify.so<br> 22191: trying file=/usr/lib/haswell/x86_64/libittnotify.so<br> 22191: trying file=/usr/lib/haswell/libittnotify.so<br> 22191: trying file=/usr/lib/x86_64/libittnotify.so<br> 22191: trying file=/usr/lib/libittnotify.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_intel_thread.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_intel_lp64.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_avx2.so<br> 22191:<br> 22191: find library=libtensorflow_framework.so.2 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/tls/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/tls/haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/tls/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/tls:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/tls/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/tls/haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/tls/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/tls:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../tls/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../tls/haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../tls/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../tls:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/_pywrap_tensorflow_internal.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/tls/haswell/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/tls/haswell/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/tls/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/tls/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/haswell/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/haswell/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../../_solib_local/_U_S_Stensorflow_Spython_C_Upywrap_Utensorflow_Uinternal.so___Utensorflow/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/tls/haswell/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/tls/haswell/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/tls/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/tls/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/haswell/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/haswell/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../tls/haswell/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../tls/haswell/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../tls/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../tls/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../haswell/x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../haswell/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../x86_64/libtensorflow_framework.so.2<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../libtensorflow_framework.so.2<br> 22191:<br> 22191: find library=libstdc++.so.6 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/_pywrap_tensorflow_internal.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/libstdc++.so.6<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../libstdc++.so.6<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/bin/../lib (RPATH from file /home/davis/anaconda3/envs/py3tf2/bin/python)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/libstdc++.so.6<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/bin/../lib/libstdc++.so.6<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../libtensorflow_framework.so.2<br> 22191:<br> 22191: find library=libhdfs.so [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/_pywrap_tensorflow_internal.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../libhdfs.so<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/_pywrap_tensorflow_internal.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/libhdfs.so<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../libhdfs.so<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/bin/../lib (RPATH from file /home/davis/anaconda3/envs/py3tf2/bin/python)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/bin/../lib/libhdfs.so<br> 22191: search cache=/etc/ld.so.cache<br> 22191: search path=/lib/x86_64-linux-gnu:/usr/lib/x86_64-linux-gnu:/lib:/usr/lib (system search path)<br> 22191: trying file=/lib/x86_64-linux-gnu/libhdfs.so<br> 22191: trying file=/usr/lib/x86_64-linux-gnu/libhdfs.so<br> 22191: trying file=/lib/libhdfs.so<br> 22191: trying file=/usr/lib/libhdfs.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/_pywrap_tensorflow_internal.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/binascii.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_posixsubprocess.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/select.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/pyexpat.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_socket.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191:<br> 22191:<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_csv.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/fcntl.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/termios.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/framework/fast_tensor_util.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_queue.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/wrapt/_wrappers.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_json.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191: find library=libssl.so.1.1 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../.. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_ctypes.cpython-37m-x86_64-linux-gnu.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libssl.so.1.1<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libssl.so.1.1<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_ssl.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/array.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191: find library=libhdf5-978d01a9.so.103.0.0 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/tls/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/tls/haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/tls/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/tls:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/_errors.cpython-37m-x86_64-linux-gnu.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/tls/haswell/x86_64/libhdf5-978d01a9.so.103.0.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/tls/haswell/libhdf5-978d01a9.so.103.0.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/tls/x86_64/libhdf5-978d01a9.so.103.0.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/tls/libhdf5-978d01a9.so.103.0.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/haswell/x86_64/libhdf5-978d01a9.so.103.0.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/haswell/libhdf5-978d01a9.so.103.0.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/x86_64/libhdf5-978d01a9.so.103.0.0<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/libhdf5-978d01a9.so.103.0.0<br> 22191:<br> 22191: find library=libhdf5_hl-db841637.so.100.1.1 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/_errors.cpython-37m-x86_64-linux-gnu.so)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/libhdf5_hl-db841637.so.100.1.1<br> 22191:<br> 22191: find library=libsz-1c7dd0cf.so.2.0.1 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./tls/haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./tls/haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./tls/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./tls:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./haswell/x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./haswell:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./x86_64:/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/libhdf5-978d01a9.so.103.0.0)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./tls/haswell/x86_64/libsz-1c7dd0cf.so.2.0.1<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./tls/haswell/libsz-1c7dd0cf.so.2.0.1<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./tls/x86_64/libsz-1c7dd0cf.so.2.0.1<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./tls/libsz-1c7dd0cf.so.2.0.1<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./haswell/x86_64/libsz-1c7dd0cf.so.2.0.1<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./haswell/libsz-1c7dd0cf.so.2.0.1<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./x86_64/libsz-1c7dd0cf.so.2.0.1<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./libsz-1c7dd0cf.so.2.0.1<br> 22191:<br> 22191: find library=libaec-2147abcd.so.0.0.4 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/libhdf5-978d01a9.so.103.0.0)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./libaec-2147abcd.so.0.0.4<br> 22191:<br> 22191: find library=libz-a147dcb0.so.1.2.3 [0]; searching<br> 22191: search path=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/. (RPATH from file /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/libhdf5-978d01a9.so.103.0.0)<br> 22191: trying file=/home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./libz-a147dcb0.so.1.2.3<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./libz-a147dcb0.so.1.2.3<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./libaec-2147abcd.so.0.0.4<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./libsz-1c7dd0cf.so.2.0.1<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/libhdf5-978d01a9.so.103.0.0<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/libhdf5_hl-db841637.so.100.1.1<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/_errors.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/defs.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/_objects.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/_conv.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5r.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5t.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/utils.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22192: find library=libc.so.6 [0]; searching<br> 22192: search cache=/etc/ld.so.cache<br> 22192: trying file=/lib/x86_64-linux-gnu/libc.so.6<br> 22192:<br> 22192:<br> 22192: calling init: /lib/x86_64-linux-gnu/libc.so.6<br> 22192:<br> 22192:<br> 22192: initialize program: /bin/sh<br> 22192:<br> 22192:<br> 22192: transferring control: /bin/sh<br> 22192:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5z.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5a.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5s.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5p.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5ac.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/_proxy.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5d.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5ds.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5f.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5g.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5i.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5fd.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5pl.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5o.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5l.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/lite/experimental/microfrontend/python/ops/_audio_microfrontend_op.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/conversion.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/c_timestamp.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/nattype.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/np_datetime.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/timezones.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/tzconversion.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/timedeltas.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/offsets.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/ccalendar.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/strptime.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/fields.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/parsing.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/period.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/frequencies.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/timestamps.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/resolution.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/hashtable.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/missing.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/lib.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslib.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/algos.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/interval.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/properties.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/hashing.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/ops.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/index.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/join.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/sparse.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/indexing.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/internals.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/unicodedata.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/mmap.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/reshape.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/window.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/skiplist.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/groupby.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/reduction.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/parsers.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/json.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/writers.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/util/_move.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/io/msgpack/_packer.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/io/msgpack/_unpacker.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling init: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/testing.cpython-37m-x86_64-linux-gnu.so<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/bin/python [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /lib/x86_64-linux-gnu/libutil.so.1 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_heapq.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_opcode.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_ctypes.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libffi.so.6 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_struct.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/_mklinit.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libiomp5.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/core/_multiarray_umath.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/math.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_datetime.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_pickle.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/core/_multiarray_tests.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/linalg/lapack_lite.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/linalg/_umath_linalg.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/zlib.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_bz2.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_lzma.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../liblzma.so.5 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/grp.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_decimal.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/fft/fftpack_lite.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/mkl_fft/_pydfti.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/random/mtrand.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_hashlib.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_blake2.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_sha3.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_bisect.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_random.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_intel_lp64.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_avx2.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_intel_thread.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_core.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/numpy/../../../libmkl_rt.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/_pywrap_tensorflow_internal.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/binascii.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libz.so.1 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_posixsubprocess.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/select.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/pyexpat.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_socket.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191:<br> 22191:<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_csv.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/fcntl.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/termios.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/framework/fast_tensor_util.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_queue.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/wrapt/_wrappers.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_json.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/_ssl.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libssl.so.1.1 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/../../libcrypto.so.1.1 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/array.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/_errors.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/defs.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/_objects.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/_conv.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5r.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5t.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/utils.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5z.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5a.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5s.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5p.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5ac.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/_proxy.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5d.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5ds.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5f.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5g.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5i.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5fd.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5pl.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5o.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/h5l.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/libhdf5_hl-db841637.so.100.1.1 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/libhdf5-978d01a9.so.103.0.0 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./libz-a147dcb0.so.1.2.3 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./libsz-1c7dd0cf.so.2.0.1 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/h5py/.libs/./libaec-2147abcd.so.0.0.4 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/lite/experimental/microfrontend/python/ops/_audio_microfrontend_op.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/../libtensorflow_framework.so.2 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /lib/x86_64-linux-gnu/librt.so.1 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /lib/x86_64-linux-gnu/libdl.so.2 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/conversion.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/c_timestamp.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/nattype.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/np_datetime.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/timezones.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/tzconversion.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/timedeltas.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/offsets.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/ccalendar.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/strptime.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/fields.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/parsing.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/period.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/frequencies.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/timestamps.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslibs/resolution.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/hashtable.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/missing.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/lib.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/tslib.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/algos.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/interval.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/properties.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/hashing.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/ops.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/index.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/join.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/sparse.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/indexing.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/internals.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/unicodedata.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/lib-dynload/mmap.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/reshape.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/window.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/bin/../lib/libstdc++.so.6 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/bin/../lib/libgcc_s.so.1 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /lib/x86_64-linux-gnu/libm.so.6 [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/skiplist.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/groupby.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/reduction.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/parsers.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/json.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/writers.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/util/_move.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/io/msgpack/_packer.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/io/msgpack/_unpacker.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/pandas/_libs/testing.cpython-37m-x86_64-linux-gnu.so [0]<br> 22191:<br> 22191:<br> 22191: calling fini: /lib/x86_64-linux-gnu/libpthread.so.0 [0]<br> 22191:</p> <p dir="auto">== env ==========================================================<br> LD_LIBRARY_PATH is unset<br> DYLD_LIBRARY_PATH is unset</p> <p dir="auto">== nvidia-smi ===================================================<br> Mon Sep 16 13:02:01 2019<br> +-----------------------------------------------------------------------------+<br> | NVIDIA-SMI 418.74 Driver Version: 418.74 CUDA Version: 10.1 |<br> |-------------------------------+----------------------+----------------------+<br> | GPU Name Persistence-M| Bus-Id Disp.A | Volatile Uncorr. ECC |<br> | Fan Temp Perf Pwr:Usage/Cap| Memory-Usage | GPU-Util Compute M. |<br> |===============================+======================+======================|<br> | 0 GeForce RTX 2070 On | 00000000:01:00.0 On | N/A |<br> | 38% 30C P8 14W / 175W | 1249MiB / 7949MiB | 6% Default |<br> +-------------------------------+----------------------+----------------------+</p> <p dir="auto">+-----------------------------------------------------------------------------+<br> | Processes: GPU Memory |<br> | GPU PID Type Process name Usage |<br> |=============================================================================|<br> | 0 814 G /usr/lib/xorg/Xorg 34MiB |<br> | 0 948 G /usr/bin/gnome-shell 24MiB |<br> | 0 1171 G /usr/lib/xorg/Xorg 217MiB |<br> | 0 1250 G /usr/bin/gnome-shell 176MiB |<br> | 0 1551 G ...uest-channel-token=12821291265308298198 8MiB |<br> | 0 2551 G ...equest-channel-token=447657113308850378 786MiB |<br> +-----------------------------------------------------------------------------+</p> <p dir="auto">== cuda libs ===================================================</p> <p dir="auto">== tensorflow installed from info ==================<br> Name: tensorflow<br> Version: 2.0.0rc1<br> Summary: TensorFlow is an open source machine learning framework for everyone.<br> Home-page: <a href="https://www.tensorflow.org/" rel="nofollow">https://www.tensorflow.org/</a><br> Author-email: <a href="mailto:[email protected]">[email protected]</a><br> License: Apache 2.0<br> Location: /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages<br> Required-by:</p> <p dir="auto">== python version ==============================================<br> (major, minor, micro, releaselevel, serial)<br> (3, 7, 4, 'final', 0)</p> <p dir="auto">== bazel version ===============================================</p> </blockquote> <p dir="auto"><strong>Describe the current behavior</strong></p> <p dir="auto">During the train of the xgboosted tree, the kernel will abort and halt.</p> <p dir="auto"><strong>Describe the expected behavior</strong></p> <p dir="auto">That the python kernel operate normally.</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> <blockquote> <p dir="auto">import numpy as np<br> import pandas as pd<br> import tensorflow as tf<br> import ssl<br> dftrain = pd.read_csv('<a href="https://storage.googleapis.com/tf-datasets/titanic/train.csv" rel="nofollow">https://storage.googleapis.com/tf-datasets/titanic/train.csv</a>')<br> dfeval = pd.read_csv('<a href="https://storage.googleapis.com/tf-datasets/titanic/eval.csv" rel="nofollow">https://storage.googleapis.com/tf-datasets/titanic/eval.csv</a>')<br> y_train = dftrain.pop('survived')<br> y_eval = dfeval.pop('survived')<br> try:<br> %tensorflow_version 2.x<br> except Exception:<br> pass<br> import tensorflow as tf<br> tf.random.set_seed(123)<br> print( "tensorflow version = {}".format(tf.version))<br> import platform<br> print(platform.python_version())<br> vocabulary = dftrain['sex'].unique()<br> fc = tf.feature_column<br> CATEGORICAL_COLUMNS = ['sex', 'n_siblings_spouses', 'parch', 'class', 'deck', 'embark_town', 'alone']<br> NUMERIC_COLUMNS = ['age', 'fare']</p> <p dir="auto">def one_hot_cat_column(feature_name, vocab):<br> return tf.feature_column.indicator_column(<br> tf.feature_column.categorical_column_with_vocabulary_list(feature_name,<br> vocab))<br> feature_columns = []<br> for feature_name in CATEGORICAL_COLUMNS:<br> # Need to one-hot encode categorical features.<br> # He finds the unique values in each column and uses that<br> # array as a vocabulary<br> vocabulary = dftrain[feature_name].unique()<br> feature_columns.append(one_hot_cat_column(feature_name, vocabulary))</p> <p dir="auto">for feature_name in NUMERIC_COLUMNS:<br> feature_columns.append(tf.feature_column.numeric_column(feature_name,dtype=tf.float32))</p> <p dir="auto">example = dict(dftrain.head(1))<br> class_fc = tf.feature_column.indicator_column(<br> tf.feature_column.categorical_column_with_vocabulary_list('class', ('First', 'Second', 'Third')))<br> print('Feature value: "{}"'.format(example['class'].iloc[0]))<br> print('One-hot encoded: ', tf.keras.layers.DenseFeatures([class_fc])(example).numpy())</p> <h1 dir="auto">Use entire batch since this is such a small dataset.</h1> <p dir="auto">NUM_EXAMPLES = len(y_train)</p> <p dir="auto">def make_input_fn(X, y, n_epochs=None, shuffle=True):<br> def input_fn():<br> dataset = tf.data.Dataset.from_tensor_slices((dict(X), y))<br> if shuffle:<br> dataset = dataset.shuffle(NUM_EXAMPLES)<br> # For training, cycle thru dataset as many times as need (n_epochs=None).<br> dataset = dataset.repeat(n_epochs)<br> # In memory training doesn't use batching.<br> dataset = dataset.batch(NUM_EXAMPLES)<br> return dataset<br> return input_fn</p> <h1 dir="auto">Training and evaluation input functions.</h1> <p dir="auto">train_input_fn = make_input_fn(dftrain, y_train)<br> eval_input_fn = make_input_fn(dfeval, y_eval, shuffle=False, n_epochs=1)<br> linear_est = tf.estimator.LinearClassifier(feature_columns)</p> <h1 dir="auto">Train model.</h1> <p dir="auto">linear_est.train(train_input_fn, max_steps=100)</p> <h1 dir="auto">Evaluation.</h1> <p dir="auto">result = linear_est.evaluate(eval_input_fn)</p> <h1 dir="auto">Since data fits into memory, use entire dataset per layer. It will be faster.</h1> <h1 dir="auto">Above one batch is defined as the entire dataset.</h1> <p dir="auto">n_batches = 1<br> est = tf.estimator.BoostedTreesClassifier(feature_columns,<br> n_batches_per_layer=n_batches)</p> <h1 dir="auto">The model will stop training once the specified number of trees is built, not</h1> <h1 dir="auto">based on the number of steps.</h1> <p dir="auto">est.train(train_input_fn, max_steps=100) ##### &lt;&lt;&lt;&lt;&lt;---- this kills notebook kernel</p> </blockquote> <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> <p dir="auto">Output of the est.train call at end of sample script. This output is generated and then the jupyter notebook will pop up a dialog which says kernel has stopped.</p> <blockquote> <p dir="auto">INFO:tensorflow:Calling model_fn.<br> WARNING:tensorflow:From /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/feature_column/feature_column.py:2158: NumericColumn._transform_feature (from tensorflow.python.feature_column.feature_column_v2) is deprecated and will be removed in a future version.<br> Instructions for updating:<br> The old _FeatureColumn APIs are being deprecated. Please use the new FeatureColumn APIs instead.<br> WARNING:tensorflow:From /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/feature_column/feature_column.py:2158: IndicatorColumn._transform_feature (from tensorflow.python.feature_column.feature_column_v2) is deprecated and will be removed in a future version.<br> Instructions for updating:<br> The old _FeatureColumn APIs are being deprecated. Please use the new FeatureColumn APIs instead.<br> WARNING:tensorflow:From /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/feature_column/feature_column_v2.py:4302: VocabularyListCategoricalColumn._get_sparse_tensors (from tensorflow.python.feature_column.feature_column_v2) is deprecated and will be removed in a future version.<br> Instructions for updating:<br> The old _FeatureColumn APIs are being deprecated. Please use the new FeatureColumn APIs instead.<br> WARNING:tensorflow:From /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_core/python/feature_column/feature_column.py:2158: VocabularyListCategoricalColumn._transform_feature (from tensorflow.python.feature_column.feature_column_v2) is deprecated and will be removed in a future version.<br> Instructions for updating:<br> The old _FeatureColumn APIs are being deprecated. Please use the new FeatureColumn APIs instead.<br> WARNING:tensorflow:From /home/davis/anaconda3/envs/py3tf2/lib/python3.7/site-packages/tensorflow_estimator/python/estimator/canned/boosted_trees.py:161: to_int32 (from tensorflow.python.ops.math_ops) is deprecated and will be removed in a future version.<br> Instructions for updating:<br> Use <code class="notranslate">tf.cast</code> instead.<br> INFO:tensorflow:Done calling model_fn.<br> INFO:tensorflow:Create CheckpointSaverHook.<br> WARNING:tensorflow:Issue encountered when serializing resources.<br> Type is unsupported, or the types of the items don't match field type in CollectionDef. Note this is a warning and probably safe to ignore.<br> '_Resource' object has no attribute 'name'<br> INFO:tensorflow:Graph was finalized.<br> INFO:tensorflow:Running local_init_op.<br> INFO:tensorflow:Done running local_init_op.<br> WARNING:tensorflow:Issue encountered when serializing resources.<br> Type is unsupported, or the types of the items don't match field type in CollectionDef. Note this is a warning and probably safe to ignore.<br> '_Resource' object has no attribute 'name'<br> INFO:tensorflow:Saving checkpoints for 0 into /tmp/tmpr2q3edmx/model.ckpt.<br> WARNING:tensorflow:Issue encountered when serializing resources.<br> Type is unsupported, or the types of the items don't match field type in CollectionDef. Note this is a warning and probably safe to ignore.<br> '_Resource' object has no attribute 'name'<br> INFO:tensorflow:loss = 0.6931468, step = 0<br> WARNING:tensorflow:It seems that global step (tf.train.get_global_step) has not been increased. Current value (could be stable): 0 vs previous value: 0. You could increase the global step by passing tf.train.get_global_step() to Optimizer.apply_gradients or Optimizer.minimize.<br> ​</p> </blockquote>
0
<p dir="auto">I am calling a service like this:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import requests resp = requests.get('http://example.com/some/url', params={'id': 1})"><pre class="notranslate"><code class="notranslate">import requests resp = requests.get('http://example.com/some/url', params={'id': 1}) </code></pre></div> <p dir="auto">The service responds with a series of 302 redirects.<br> I am seeing this exchange.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="client&gt; GET /some/url?id=1 HTTP/1.1 client&gt; Host: example.com server&lt; HTTP/1.1 302 Moved Temporarily server&lt; Location: http://example.com/some/url?id=1&amp;extra_data=2 ## this is the bad request right here. Note the [('id', 1)] stuck on the end client&gt; GET /some/url?id=1&amp;extra_data=2&amp;[('id', 1)] HTTP/1.1. client&gt; Host: example.com # the server of course doesn't like it server&lt; HTTP/1.0 400 Bad request."><pre class="notranslate"><code class="notranslate">client&gt; GET /some/url?id=1 HTTP/1.1 client&gt; Host: example.com server&lt; HTTP/1.1 302 Moved Temporarily server&lt; Location: http://example.com/some/url?id=1&amp;extra_data=2 ## this is the bad request right here. Note the [('id', 1)] stuck on the end client&gt; GET /some/url?id=1&amp;extra_data=2&amp;[('id', 1)] HTTP/1.1. client&gt; Host: example.com # the server of course doesn't like it server&lt; HTTP/1.0 400 Bad request. </code></pre></div> <p dir="auto">Any ideas why this may be happening?</p>
<p dir="auto">Hello,</p> <p dir="auto">I have just attempted to install requests into a virtualenv environment and am getting the error:<br> NameError: name 'CERT_NONE' is not defined</p> <p dir="auto">The full stacktrace is below. I tried to install requests with the command pip install -U requests in my virtual environment. An admittedly quick Google search didn't turn up anything, but I am assuming its user error. Am I doing it wrong somehow?</p> <p dir="auto">This is on Red Hat Enterprise Linux 5 with Python 2.7.3. I have tried virtualenv with and without site packages, same error either way. If there is any more information I can provide, feel free to let me know.</p> <p dir="auto">Thanks,</p> <p dir="auto">Brian</p> <p dir="auto">Full Stack trace from error:</p> <p dir="auto">249 File "requests/packages/<strong>init</strong>.py", line 3, in <br> 250<br> 251 from . import urllib3<br> 252<br> 253 File "requests/packages/urllib3/<strong>init</strong>.py", line 16, in <br> 254<br> 255 from .connectionpool import (<br> 256<br> 257 File "requests/packages/urllib3/connectionpool.py", line 45, in <br> 258<br> 259 from .util import get_host, is_connection_dropped, ssl_wrap_socket<br> 260<br> 261 File "requests/packages/urllib3/util.py", line 293, in <br> 262<br> 263 def ssl_wrap_socket(sock, keyfile=None, certfile=None, cert_reqs=CERT_NONE,<br> 264<br> 265 NameError: name 'CERT_NONE' is not defined<br> 266<br> 267 ----------------------------------------<br> 268<br> 269 Command python setup.py egg_info failed with error code 1 in /home/bneal/pyv/build/requests<br> 270<br> 271 Exception information:<br> 272 Traceback (most recent call last):<br> 273 File "/home/bneal/pyv/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/basecommand.py", line 107, in main<br> 274 status = self.run(options, args)<br> 275 File "/home/bneal/pyv/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/commands/install.py", line 256, in run<br> 276 requirement_set.prepare_files(finder, force_root_egg_info=self.bundle, bundle=self.bundle)<br> 277 File "/home/bneal/pyv/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py", line 1042, in prepare_files<br> 278 req_to_install.run_egg_info()<br> 279 File "/home/bneal/pyv/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/req.py", line 236, in run_egg_info<br> 280 command_desc='python setup.py egg_info')<br> 281 File "/home/bneal/pyv/lib/python2.7/site-packages/pip-1.2.1-py2.7.egg/pip/util.py", line 612, in call_subprocess<br> 282 % (command_desc, proc.returncode, cwd))<br> 283 InstallationError: Command python setup.py egg_info failed with error code 1 in /home/bneal/pyv/build/requests</p>
0
<p dir="auto">It seems that there is an issue with the displayed text in the editor loading a duplicate line that also forces the cursors initial location to be above where it actually is applying the keystrokes. This only happens the first time I select something then both the duplicate code and the cursor function normally.</p> <h4 dir="auto">Screenshot</h4> <p dir="auto">On load the 3rd row is duplicated, it disappears when it refreshes the preview<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/26915540/24724552/5e2a1654-1a00-11e7-853b-26d1dfc21b24.png"><img src="https://cloud.githubusercontent.com/assets/26915540/24724552/5e2a1654-1a00-11e7-853b-26d1dfc21b24.png" alt="image" style="max-width: 100%;"></a><br> cursor positioned after line 9 @ "red");<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/26915540/24724571/70c9e9ec-1a00-11e7-85d6-8bdc000d7352.png"><img src="https://cloud.githubusercontent.com/assets/26915540/24724571/70c9e9ec-1a00-11e7-85d6-8bdc000d7352.png" alt="image" style="max-width: 100%;"></a><br> hitting enter creates a space below cursor<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/26915540/24724588/7a27ce14-1a00-11e7-87da-f385f484468e.png"><img src="https://cloud.githubusercontent.com/assets/26915540/24724588/7a27ce14-1a00-11e7-87da-f385f484468e.png" alt="image" style="max-width: 100%;"></a></p>
<p dir="auto">Challenge <a href="http://www.freecodecamp.com/challenges/bonfire-steamroller" rel="nofollow">http://www.freecodecamp.com/challenges/bonfire-steamroller</a> has an issue. Please describe how to reproduce it, and include links to screen shots if possible.</p> <p dir="auto">My code is returning the correct value in the console as well as in an external editor, but when I look at the test cases they compare the expected result to a different value than my code output in the console. I have ran it with several of the test cases and it seems to either duplicate the values in the final array or attach the values from the previously ran test to the current array. Please fix.</p> <p dir="auto">My code:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="var newArr = []; function steamroller(arr) { for (var i = 0; i &lt; arr.length; i++){ console.log(Array.isArray(arr[i])); if (Array.isArray(arr[i])){ steamroller(arr[i]); }else{ newArr.push(arr[i]); } } console.log(newArr); return newArr; } steamroller([[['a']], [['b']]]);"><pre class="notranslate"><code class="notranslate">var newArr = []; function steamroller(arr) { for (var i = 0; i &lt; arr.length; i++){ console.log(Array.isArray(arr[i])); if (Array.isArray(arr[i])){ steamroller(arr[i]); }else{ newArr.push(arr[i]); } } console.log(newArr); return newArr; } steamroller([[['a']], [['b']]]); </code></pre></div> <p dir="auto">console output: ['a','b']<br> frecodecamp test result: expected [ 'a', 'b', 'a', 'b' ] to deeply equal [ 'a', 'b' ]</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/12631698/8243846/be785ad4-15cf-11e5-96fb-156d57a33dec.JPG"><img src="https://cloud.githubusercontent.com/assets/12631698/8243846/be785ad4-15cf-11e5-96fb-156d57a33dec.JPG" alt="steamroller" style="max-width: 100%;"></a></p>
0
<h3 dir="auto">What problem does this feature solve?</h3> <p dir="auto">Both I and a colleague have spent hours debugging issues caused by having two refs with the same name. Two cases where this can happen:</p> <ol dir="auto"> <li>Simple stupidity:</li> </ol> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&lt;comp1 ref='comp'/&gt; &lt;comp2 ref='comp/&gt;"><pre class="notranslate"><code class="notranslate">&lt;comp1 ref='comp'/&gt; &lt;comp2 ref='comp/&gt; </code></pre></div> <ol start="2" dir="auto"> <li>Not realizing that refs don't seem to work in a v-for:</li> </ol> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&lt;tabs v-for='title of titles'&gt; &lt;fubar v-if='title===&quot;FUBAR&quot;' ref='fubar'/&gt; &lt;/tabs&gt;"><pre class="notranslate"><code class="notranslate">&lt;tabs v-for='title of titles'&gt; &lt;fubar v-if='title==="FUBAR"' ref='fubar'/&gt; &lt;/tabs&gt; </code></pre></div> <p dir="auto">In this case, it is reasonable to assume the ref would work correctly because there will only be one "fubar" component instantiated assuming 'titles' has no duplicates. But the ref does not work right, either because ref ignores "v-if" or because ref doesn't work right in v-for.</p> <h3 dir="auto">What does the proposed API look like?</h3> <p dir="auto">Simply issue a Vue warning when multiple refs with the same name are encountered.</p>
<h3 dir="auto">Version</h3> <p dir="auto">2.4.2</p> <h3 dir="auto">Reproduction link</h3> <p dir="auto"><a href="https://github.com/vuejs-templates/pwa">https://github.com/vuejs-templates/pwa</a></p> <h3 dir="auto">Steps to reproduce</h3> <ol dir="auto"> <li>Clone official vue-pwa template</li> <li>Add one more entry point in line <a href="https://github.com/vuejs-templates/pwa/blob/master/template/build/webpack.base.conf.js#L12">#L12</a> which includes vue</li> </ol> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="entry: { app: './src/main.js', vendor: ['vue'] }"><pre class="notranslate"><code class="notranslate">entry: { app: './src/main.js', vendor: ['vue'] } </code></pre></div> <ol start="3" dir="auto"> <li>Run <code class="notranslate">npm run dev</code> and check console. You can see that although <code class="notranslate">productionTip</code> option is disabled in <code class="notranslate">main.js</code>, the warning still appears in the console.</li> </ol> <h3 dir="auto">What is expected?</h3> <p dir="auto"><code class="notranslate">config.productionTip</code> to working properly</p> <h3 dir="auto">What is actually happening?</h3> <p dir="auto">When vue is imported in multiple entry points, it's impossible to disable productionTip.</p>
0
<div class="highlight highlight-source-fortran notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="integer function breaksf2py(arg) integer, intent(in) :: arg breaksf2py = 2 * arg end"><pre class="notranslate"><span class="pl-k">integer</span> <span class="pl-k">function</span> <span class="pl-en">breaksf2py</span>(<span class="pl-v">arg</span>) <span class="pl-k">integer</span>, <span class="pl-k">intent</span>(<span class="pl-k">in</span>) <span class="pl-k">::</span> arg breaksf2py <span class="pl-k">=</span> <span class="pl-c1">2</span> <span class="pl-k">*</span> arg <span class="pl-k">end</span></pre></div> <p dir="auto">Compiling with <code class="notranslate">f2py -m foo breaksf2py.f90</code> works fine, but <code class="notranslate">f2py -m foo -h foo.pyf breaksf2py.f90</code> gives the following error for python3 f2py (tested with 3.2 and 3.3)</p> <blockquote> <p dir="auto">Reading fortran codes...<br> Reading file 'breaksf2py.f90' (format:free)<br> Post-processing...<br> Block: foo<br> Block: breaksf2py<br> Post-processing (stage 2)...<br> Saving signatures to file "./foo.pyf"<br> Traceback (most recent call last):<br> File "/usr/bin/f2py-3.2", line 24, in <br> main()<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/f2py2e.py", line 590, in main<br> run_main(sys.argv[1:])<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/f2py2e.py", line 361, in run_main<br> postlist=callcrackfortran(files,options)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/f2py2e.py", line 286, in callcrackfortran<br> pyf=crackfortran.crack2fortran(postlist)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2749, in crack2fortran<br> pyf=crack2fortrangen(block)+'\n'<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2517, in crack2fortrangen<br> ret=ret+crack2fortrangen(g,tab,as_interface=as_interface)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2561, in crack2fortrangen<br> vars=vars2fortran(block,block['vars'],argsl,tab+tabchar, as_interface=as_interface)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2711, in vars2fortran<br> lst = true_intent_list(vars[a])<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2612, in true_intent_list<br> if c:<br> UnboundLocalError: local variable 'c' referenced before assignment</p> </blockquote> <p dir="auto">Python2 f2py can run <code class="notranslate">f2py-2.7 -m foo -h foo.pyf breaksf2py.f90</code> fine, and python3 f2py can compile the resulting pyf file with <code class="notranslate">f2py-3.3 -m foo -c foo.pyf breaksf2py.f90</code>.</p>
<p dir="auto"><em>Original ticket <a href="http://projects.scipy.org/numpy/ticket/1932" rel="nofollow">http://projects.scipy.org/numpy/ticket/1932</a> on 2011-08-12 by trac user josdekloe, assigned to <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/pearu/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/pearu">@pearu</a>.</em></p> <p dir="auto">I have been trying to use the f2py routinely to build an interface around the ECMWF BUFR library. See <a href="http://code.google.com/p/pybufr-ecmwf/" rel="nofollow">http://code.google.com/p/pybufr-ecmwf/</a> for details. This works fine for the python 2.x versions.</p> <p dir="auto">However, I also tried to add the possibility to use python3 and here I encountered some trouble. My python code converts properly to python3 using to 2to3 tool, but when I try to use the python3 version of f2py I encounter this error somewhere deep inside the f2py internals:</p> <p dir="auto">Post-processing (stage 2)...<br> Saving signatures to file "f2py_build/signatures.pyf"<br> Traceback (most recent call last):<br> File "./run_f2py_tool.py", line 11, in <br> main()<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/f2py2e.py", line 563, in main<br> run_main(sys.argv[1:])<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/f2py2e.py", line 342, in run_main<br> postlist=callcrackfortran(files,options)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/f2py2e.py", line 279, in callcrackfortran<br> pyf=crackfortran.crack2fortran(postlist)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2693, in crack2fortran<br> pyf=crack2fortrangen(block)+'\n'<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2465, in crack2fortrangen<br> ret=ret+crack2fortrangen(g,tab)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2505, in crack2fortrangen<br> body=crack2fortrangen(block['body'],tab+tabchar)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2465, in crack2fortrangen<br> ret=ret+crack2fortrangen(g,tab)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2505, in crack2fortrangen<br> body=crack2fortrangen(block['body'],tab+tabchar)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2465, in crack2fortrangen<br> ret=ret+crack2fortrangen(g,tab)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2506, in crack2fortrangen<br> vars=vars2fortran(block,block['vars'],al,tab+tabchar)<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2655, in vars2fortran<br> lst = true_intent_list(vars[a])<br> File "/usr/lib64/python3.2/site-packages/numpy/f2py/crackfortran.py", line 2557, in true_intent_list<br> if c:<br> UnboundLocalError: local variable 'c' referenced before assignment<br> ERROR: build of python wrapper failed<br> the signatures file could not be found<br> Traceback (most recent call last):<br> File "./build_interface.py", line 1803, in <br> BI.build()<br> File "./build_interface.py", line 543, in build<br> self.generate_python_wrapper(source_dir)<br> File "./build_interface.py", line 1667, in generate_python_wrapper<br> raise InterfaceBuildError<br> <strong>main</strong>.InterfaceBuildError</p> <p dir="auto">I any additional information is needed I would be happy to provide it.</p>
1
<p dir="auto">The language service doesn't give any suggestions here:</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="const wrapper = document.querySelector('.wrapper') as H"><pre class="notranslate"><span class="pl-k">const</span> <span class="pl-s1">wrapper</span> <span class="pl-c1">=</span> <span class="pl-smi">document</span><span class="pl-kos">.</span><span class="pl-en">querySelector</span><span class="pl-kos">(</span><span class="pl-s">'.wrapper'</span><span class="pl-kos">)</span> <span class="pl-k">as</span> <span class="pl-smi">H</span></pre></div> <p dir="auto">At <code class="notranslate">H</code> I expected to see HTMLElement. The suggestion is shown if I type <code class="notranslate">;</code> and then <code class="notranslate">H</code>.</p>
<div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="type T = number; var x; var y = x as /**/"><pre class="notranslate"><span class="pl-k">type</span> <span class="pl-smi">T</span> <span class="pl-c1">=</span> <span class="pl-smi">number</span><span class="pl-kos">;</span> <span class="pl-k">var</span> <span class="pl-s1">x</span><span class="pl-kos">;</span> <span class="pl-k">var</span> <span class="pl-s1">y</span> <span class="pl-c1">=</span> <span class="pl-s1">x</span> <span class="pl-k">as</span> <span class="pl-c">/**/</span></pre></div> <p dir="auto">Request completion at <code class="notranslate">/**/</code>.</p> <p dir="auto">Expected: Get completion list, <code class="notranslate">T</code> is present.<br> Actual: No completion list.</p>
1
<p dir="auto"><a href="https://github.com/numpy/numpy/files/3860457/SarimaForecasting.zip">SarimaForecasting.zip</a><br> Python 3.7 installed from Anaconda<br> Error was received when running from Anaconda prompt. Have received the same error when running programs from Spyder. The problem was resolved when I reset Spyder. This program won't run the function in parallel unless it is run from the Anaconda prompt.<br> Jeff Roles, PhD<br> <a href="mailto:[email protected]">[email protected]</a></p>
<h3 dir="auto">Reproducing code example:</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import matplotlib.pyplot as plt;"><pre class="notranslate"><code class="notranslate">import matplotlib.pyplot as plt; </code></pre></div> <p dir="auto">Before this happened I was running a different python script, which used 89 processes. Unfortunately I cannot share that script publicly. Since then numpy crashes after import immediately.</p> <h3 dir="auto">Error message:</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="OpenBLAS blas_thread_init: pthread_create failed for thread 52 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 53 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 54 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 55 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 56 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 57 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 58 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 59 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 60 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 61 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 62 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 63 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max Traceback (most recent call last): File &quot;/usr/local/lib64/python3.6/site-packages/numpy/core/__init__.py&quot;, line 17, in &lt;module&gt; from . import multiarray File &quot;/usr/local/lib64/python3.6/site-packages/numpy/core/multiarray.py&quot;, line 14, in &lt;module&gt; from . import overrides File &quot;/usr/local/lib64/python3.6/site-packages/numpy/core/overrides.py&quot;, line 7, in &lt;module&gt; from numpy.core._multiarray_umath import ( ImportError: PyCapsule_Import could not import module &quot;datetime&quot; During handling of the above exception, another exception occurred: Traceback (most recent call last): File &quot;temp.py&quot;, line 1, in &lt;module&gt; import matplotlib.pyplot as plt; File &quot;/usr/local/lib64/python3.6/site-packages/matplotlib/__init__.py&quot;, line 138, in &lt;module&gt; from . import cbook, rcsetup File &quot;/usr/local/lib64/python3.6/site-packages/matplotlib/cbook/__init__.py&quot;, line 31, in &lt;module&gt; import numpy as np File &quot;/usr/local/lib64/python3.6/site-packages/numpy/__init__.py&quot;, line 142, in &lt;module&gt; from . import core File &quot;/usr/local/lib64/python3.6/site-packages/numpy/core/__init__.py&quot;, line 47, in &lt;module&gt; raise ImportError(msg) ImportError: IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE! Importing the numpy c-extensions failed. - Try uninstalling and reinstalling numpy. - If you have already done that, then: 1. Check that you expected to use Python3.6 from &quot;/usr/bin/python3&quot;, and that you have no directories in your PATH or PYTHONPATH that can interfere with the Python and numpy version &quot;1.17.2&quot; you're trying to use. 2. If (1) looks fine, you can open a new issue at https://github.com/numpy/numpy/issues. Please include details on: - how you installed Python - how you installed numpy - your operating system - whether or not you have multiple versions of Python installed - if you built from source, your compiler versions and ideally a build log - If you're working with a numpy git repository, try `git clean -xdf` (removes all files not under version control) and rebuild numpy. Note: this error has many possible causes, so please don't comment on an existing issue about this - open a new one instead. Original error was: PyCapsule_Import could not import module &quot;datetime&quot; zsh: segmentation fault python3 temp.py"><pre class="notranslate"><code class="notranslate">OpenBLAS blas_thread_init: pthread_create failed for thread 52 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 53 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 54 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 55 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 56 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 57 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 58 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 59 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 60 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 61 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 62 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max OpenBLAS blas_thread_init: pthread_create failed for thread 63 of 64: Resource temporarily unavailable OpenBLAS blas_thread_init: RLIMIT_NPROC 4096 current, 1028736 max Traceback (most recent call last): File "/usr/local/lib64/python3.6/site-packages/numpy/core/__init__.py", line 17, in &lt;module&gt; from . import multiarray File "/usr/local/lib64/python3.6/site-packages/numpy/core/multiarray.py", line 14, in &lt;module&gt; from . import overrides File "/usr/local/lib64/python3.6/site-packages/numpy/core/overrides.py", line 7, in &lt;module&gt; from numpy.core._multiarray_umath import ( ImportError: PyCapsule_Import could not import module "datetime" During handling of the above exception, another exception occurred: Traceback (most recent call last): File "temp.py", line 1, in &lt;module&gt; import matplotlib.pyplot as plt; File "/usr/local/lib64/python3.6/site-packages/matplotlib/__init__.py", line 138, in &lt;module&gt; from . import cbook, rcsetup File "/usr/local/lib64/python3.6/site-packages/matplotlib/cbook/__init__.py", line 31, in &lt;module&gt; import numpy as np File "/usr/local/lib64/python3.6/site-packages/numpy/__init__.py", line 142, in &lt;module&gt; from . import core File "/usr/local/lib64/python3.6/site-packages/numpy/core/__init__.py", line 47, in &lt;module&gt; raise ImportError(msg) ImportError: IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE! Importing the numpy c-extensions failed. - Try uninstalling and reinstalling numpy. - If you have already done that, then: 1. Check that you expected to use Python3.6 from "/usr/bin/python3", and that you have no directories in your PATH or PYTHONPATH that can interfere with the Python and numpy version "1.17.2" you're trying to use. 2. If (1) looks fine, you can open a new issue at https://github.com/numpy/numpy/issues. Please include details on: - how you installed Python - how you installed numpy - your operating system - whether or not you have multiple versions of Python installed - if you built from source, your compiler versions and ideally a build log - If you're working with a numpy git repository, try `git clean -xdf` (removes all files not under version control) and rebuild numpy. Note: this error has many possible causes, so please don't comment on an existing issue about this - open a new one instead. Original error was: PyCapsule_Import could not import module "datetime" zsh: segmentation fault python3 temp.py </code></pre></div> <h3 dir="auto">Numpy/Python version information:</h3> <p dir="auto">numpy-1.7.1-13.el7.x86_64</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/mui-org/material-ui/issues">issues</a> of this repository and believe that this is not a duplicate.</li> </ul> <p dir="auto">This is my Switch component</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="`&lt;Switch checked={isSubscriptionStatusActive} onChange={onHandleChangeSubscriptionStatus} disabled={subscriptionStatus === 'deactive'} aria-label=&quot;subscribption-status&quot; classes={{ root: classes.root, bar: classes.bar, }} &gt;`"><pre class="notranslate"><code class="notranslate">`&lt;Switch checked={isSubscriptionStatusActive} onChange={onHandleChangeSubscriptionStatus} disabled={subscriptionStatus === 'deactive'} aria-label="subscribption-status" classes={{ root: classes.root, bar: classes.bar, }} &gt;` </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" root: { display: 'inline-flex', width: 0, position: 'relative', flexShrink: 0, }, bar: { borderRadius: 7, display: 'block', position: 'absolute', width: 34, height: 14, top: '50%', marginTop: -7, left: '50%', marginLeft: 0, }, };``` ## Steps to Reproduce (for bugs) https://codesandbox.io/s/x2wom4pm9z https://codesandbox.io/embed/x2wom4pm9z ## Context I want to have a Switch component without extra height, width, padding, margin ## Environment | Tech | Version | |--------------|---------| | Material-UI | beta 24 | | React | 16.2 |"><pre lang="const" class="notranslate"><code class="notranslate"> root: { display: 'inline-flex', width: 0, position: 'relative', flexShrink: 0, }, bar: { borderRadius: 7, display: 'block', position: 'absolute', width: 34, height: 14, top: '50%', marginTop: -7, left: '50%', marginLeft: 0, }, };``` ## Steps to Reproduce (for bugs) https://codesandbox.io/s/x2wom4pm9z https://codesandbox.io/embed/x2wom4pm9z ## Context I want to have a Switch component without extra height, width, padding, margin ## Environment | Tech | Version | |--------------|---------| | Material-UI | beta 24 | | React | 16.2 | </code></pre></div>
<h3 dir="auto">Problem description</h3> <p dir="auto">Ripple effect freeze in Button(when focus)</p> <h3 dir="auto">Versions</h3> <p dir="auto">0.18.7</p> <p dir="auto"><a href="http://www.material-ui.com/#/components/flat-button" rel="nofollow">http://www.material-ui.com/#/components/flat-button</a></p>
0
<p dir="auto">I'm running k8s on AWS. <code class="notranslate">kube-up.sh</code> works, and I can run a simple Rails app (controller and service). Everything is great, but when I go back the next day to access the app or load a new version the nodes have degraded and are all <code class="notranslate">NotReady</code></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ kubectl get nodes NAME LABELS STATUS ip-172-20-0-196.us-west-2.compute.internal kubernetes.io/hostname=ip-172-20-0-196.us-west-2.compute.internal NotReady ip-172-20-0-197.us-west-2.compute.internal kubernetes.io/hostname=ip-172-20-0-197.us-west-2.compute.internal NotReady ip-172-20-0-198.us-west-2.compute.internal kubernetes.io/hostname=ip-172-20-0-198.us-west-2.compute.internal NotReady ip-172-20-0-199.us-west-2.compute.internal kubernetes.io/hostname=ip-172-20-0-199.us-west-2.compute.internal NotReady"><pre class="notranslate"><code class="notranslate">$ kubectl get nodes NAME LABELS STATUS ip-172-20-0-196.us-west-2.compute.internal kubernetes.io/hostname=ip-172-20-0-196.us-west-2.compute.internal NotReady ip-172-20-0-197.us-west-2.compute.internal kubernetes.io/hostname=ip-172-20-0-197.us-west-2.compute.internal NotReady ip-172-20-0-198.us-west-2.compute.internal kubernetes.io/hostname=ip-172-20-0-198.us-west-2.compute.internal NotReady ip-172-20-0-199.us-west-2.compute.internal kubernetes.io/hostname=ip-172-20-0-199.us-west-2.compute.internal NotReady </code></pre></div> <p dir="auto">The pods are <code class="notranslate">Pending</code></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ kubectl get pods NAME READY STATUS RESTARTS AGE chronic-controller-16uic 0/1 Pending 0 6h chronic-controller-6x025 0/1 Pending 0 1h chronic-controller-x7owf 0/1 Pending 0 6h private-registry-pbvdi 0/1 Pending 0 6h tripplanner-controller-3q6km 0/1 Pending 0 6h tripplanner-controller-bhwwy 0/1 Pending 0 1h tripplanner-controller-fdep8 0/1 Pending 0 6h"><pre class="notranslate"><code class="notranslate">$ kubectl get pods NAME READY STATUS RESTARTS AGE chronic-controller-16uic 0/1 Pending 0 6h chronic-controller-6x025 0/1 Pending 0 1h chronic-controller-x7owf 0/1 Pending 0 6h private-registry-pbvdi 0/1 Pending 0 6h tripplanner-controller-3q6km 0/1 Pending 0 6h tripplanner-controller-bhwwy 0/1 Pending 0 1h tripplanner-controller-fdep8 0/1 Pending 0 6h </code></pre></div> <p dir="auto">Here are the recent events:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ kubectl get events FIRSTSEEN LASTSEEN COUNT NAME KIND SUBOBJECT REASON SOURCE MESSAGE Sat, 12 Sep 2015 22:44:10 -0500 Tue, 15 Sep 2015 15:04:08 -0500 44 ip-172-20-0-199.us-west-2.compute.internal Node NodeNotReady {kubelet ip-172-20-0-199.us-west-2.compute.internal} Node ip-172-20-0-199.us-west-2.compute.internal status is now: NodeNotReady Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:41 -0500 7531 chronic-controller-ljzn6 Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:41 -0500 7757 private-registry-ysjfj Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:42 -0500 7284 tripplanner-controller-7b0yr Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:42 -0500 7413 tripplanner-controller-s86wz Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:42 -0500 7374 chronic-controller-f2nrx Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:42 -0500 7447 chronic-controller-j4538 Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 01:42:38 -0500 Tue, 15 Sep 2015 15:22:42 -0500 9303 tripplanner-controller-04ztj Pod failedScheduling {scheduler } no nodes available to schedule pods"><pre class="notranslate"><code class="notranslate">$ kubectl get events FIRSTSEEN LASTSEEN COUNT NAME KIND SUBOBJECT REASON SOURCE MESSAGE Sat, 12 Sep 2015 22:44:10 -0500 Tue, 15 Sep 2015 15:04:08 -0500 44 ip-172-20-0-199.us-west-2.compute.internal Node NodeNotReady {kubelet ip-172-20-0-199.us-west-2.compute.internal} Node ip-172-20-0-199.us-west-2.compute.internal status is now: NodeNotReady Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:41 -0500 7531 chronic-controller-ljzn6 Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:41 -0500 7757 private-registry-ysjfj Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:42 -0500 7284 tripplanner-controller-7b0yr Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:42 -0500 7413 tripplanner-controller-s86wz Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:42 -0500 7374 chronic-controller-f2nrx Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 09:24:35 -0500 Tue, 15 Sep 2015 15:22:42 -0500 7447 chronic-controller-j4538 Pod failedScheduling {scheduler } no nodes available to schedule pods Mon, 14 Sep 2015 01:42:38 -0500 Tue, 15 Sep 2015 15:22:42 -0500 9303 tripplanner-controller-04ztj Pod failedScheduling {scheduler } no nodes available to schedule pods </code></pre></div> <p dir="auto">I logged into the master and one of the minions to look at <code class="notranslate">/var/log/kubelet.log</code> but that file doesn't exist on those hosts. Trying to ssh into one of the AWS instances is also spotty for me, but the EC2 instances all claim to be up and healthy.</p> <p dir="auto">I have killed everything with <code class="notranslate">kube-down.sh</code> and built it all again. Everything worked for the afternoon and then was down again the next morning. I don't know what else to look at or do. I'm happy to look at things. I'm <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/barrettclark/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/barrettclark">@barrettclark</a> in the slack channel.</p>
<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): BUG REPORT</p> <p dir="auto"><strong>Kubernetes version</strong> (use <code class="notranslate">kubectl version</code>): 1.4.6</p> <p dir="auto"><strong>Environment</strong>:</p> <ul dir="auto"> <li><strong>Cloud provider or hardware configuration</strong>: GCE</li> <li><strong>OS</strong> (e.g. from /etc/os-release): Google, Container-Optimized OS, beta 55-8872.47.0, Kernel: ChromiumOS-4.4.4 Kubernetes: 1.4.5 Docker: 1.11.2</li> <li><strong>Kernel</strong> (e.g. <code class="notranslate">uname -a</code>): Linux gke-warpdrive-default-pool-eae1f3b0-spgr 4.4.21+ <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 10 21:43:53 PST 2016 x86_64 Intel(R) Xeon(R) CPU @ 2.30GHz GenuineIntel GNU/Linux</li> <li><strong>Install tools</strong>:</li> <li><strong>Others</strong>:</li> </ul> <p dir="auto"><strong>What happened</strong>:<br> A a persistent disk was created via:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="gcloud compute disks create warpdrive-jenkins-home --type pd-standard"><pre class="notranslate"><code class="notranslate">gcloud compute disks create warpdrive-jenkins-home --type pd-standard </code></pre></div> <p dir="auto">This persistent disk is referenced in a K8s Deployment (yaml). The Pod failed on startup, due to FailedMount followed by FailedSync.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ kubectl describe pods --namespace=jenkins | tail Events: FirstSeen LastSeen Count From SubobjectPath Type Reason Message --------- -------- ----- ---- ------------- -------- ------ ------- 5m 5m 1 {default-scheduler } Normal Scheduled Successfully assigned jenkins-master-3888267560-x2rpc to gke-warpdrive-default-pool-af4bf63e-qjrx 3m 1m 2 {kubelet gke-warpdrive-default-pool-af4bf63e-qjrx} Warning FailedMount Unable to mount volumes for pod &quot;jenkins-master-3888267560-x2rpc_jenkins(5f752595-b01a-11e6-972b-42010a8e0029)&quot;: timeout expired waiting for volumes to attach/mount for pod &quot;jenkins-master-3888267560-x2rpc&quot;/&quot;jenkins&quot;. list of unattached/unmounted volumes=[jenkins-home] 3m 1m 2 {kubelet gke-warpdrive-default-pool-af4bf63e-qjrx} Warning FailedSync Error syncing pod, skipping: timeout expired waiting for volumes to attach/mount for pod &quot;jenkins-master-3888267560-x2rpc&quot;/&quot;jenkins&quot;. list of unattached/unmounted volumes=[jenkins-home]"><pre class="notranslate"><code class="notranslate">$ kubectl describe pods --namespace=jenkins | tail Events: FirstSeen LastSeen Count From SubobjectPath Type Reason Message --------- -------- ----- ---- ------------- -------- ------ ------- 5m 5m 1 {default-scheduler } Normal Scheduled Successfully assigned jenkins-master-3888267560-x2rpc to gke-warpdrive-default-pool-af4bf63e-qjrx 3m 1m 2 {kubelet gke-warpdrive-default-pool-af4bf63e-qjrx} Warning FailedMount Unable to mount volumes for pod "jenkins-master-3888267560-x2rpc_jenkins(5f752595-b01a-11e6-972b-42010a8e0029)": timeout expired waiting for volumes to attach/mount for pod "jenkins-master-3888267560-x2rpc"/"jenkins". list of unattached/unmounted volumes=[jenkins-home] 3m 1m 2 {kubelet gke-warpdrive-default-pool-af4bf63e-qjrx} Warning FailedSync Error syncing pod, skipping: timeout expired waiting for volumes to attach/mount for pod "jenkins-master-3888267560-x2rpc"/"jenkins". list of unattached/unmounted volumes=[jenkins-home] </code></pre></div> <p dir="auto">Interestingly, the persistent disk was actually attached:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="$ gcloud compute disks describe warpdrive-jenkins-home | tail lastAttachTimestamp: '2016-11-21T10:43:21.433-08:00' lastDetachTimestamp: '2016-11-21T10:37:20.688-08:00' name: warpdrive-jenkins-home selfLink: https://www.googleapis.com/compute/v1/projects/symphony-gce-dev/zones/us-east1-b/disks/warpdrive-jenkins-home sizeGb: '1000' status: READY type: https://www.googleapis.com/compute/v1/projects/symphony-gce-dev/zones/us-east1-b/diskTypes/pd-standard users: - https://www.googleapis.com/compute/v1/projects/symphony-gce-dev/zones/us-east1-b/instances/gke-warpdrive-default-pool-af4bf63e-qjrx zone: https://www.googleapis.com/compute/v1/projects/symphony-gce-dev/zones/us-east1-b"><pre class="notranslate"><code class="notranslate">$ gcloud compute disks describe warpdrive-jenkins-home | tail lastAttachTimestamp: '2016-11-21T10:43:21.433-08:00' lastDetachTimestamp: '2016-11-21T10:37:20.688-08:00' name: warpdrive-jenkins-home selfLink: https://www.googleapis.com/compute/v1/projects/symphony-gce-dev/zones/us-east1-b/disks/warpdrive-jenkins-home sizeGb: '1000' status: READY type: https://www.googleapis.com/compute/v1/projects/symphony-gce-dev/zones/us-east1-b/diskTypes/pd-standard users: - https://www.googleapis.com/compute/v1/projects/symphony-gce-dev/zones/us-east1-b/instances/gke-warpdrive-default-pool-af4bf63e-qjrx zone: https://www.googleapis.com/compute/v1/projects/symphony-gce-dev/zones/us-east1-b </code></pre></div> <p dir="auto">I attempted to recreate , but the issue persisted across all attempts.</p> <p dir="auto">Worth noting is that the issue is avoided if the persistent disk is defined by:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="gcloud compute images create jenkins-home-image --source-uri https://storage.googleapis.com/solutions-public-assets/jenkins-cd/jenkins-home-v2.tar.gz gcloud compute disks create jenkins-home --image jenkins-home-image"><pre class="notranslate"><code class="notranslate">gcloud compute images create jenkins-home-image --source-uri https://storage.googleapis.com/solutions-public-assets/jenkins-cd/jenkins-home-v2.tar.gz gcloud compute disks create jenkins-home --image jenkins-home-image </code></pre></div> <p dir="auto">Also worth noting is that I was able to ssh into a node and manually mount, write some files, unmount, then have K8s auto detach/attach via deletion/creation of Deployments, and then manually mount and verify that written files were there.</p> <p dir="auto"><strong>What you expected to happen</strong>:<br> I expected the persistent disk to attach and mount with no issue.</p> <p dir="auto"><strong>How to reproduce it</strong> (as minimally and precisely as possible):</p> <ul dir="auto"> <li>gcloud container clusters create warpdrive --machine-type n1-standard-4 --num-nodes 4 --subnetwork sym-infra-dev-guse1 --enable-autoscaling --min-nodes 4 --max-nodes 20 --scopes "<a href="https://www.googleapis.com/auth/projecthosting,storage-rw" rel="nofollow">https://www.googleapis.com/auth/projecthosting,storage-rw</a>"</li> <li>gcloud compute disks create warpdrive-jenkins-home --type pd-standard</li> <li>kubectl create ns jenkins</li> <li>create Deployment with:</li> </ul> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" volumeMounts: - mountPath: /var/jenkins_home name: jenkins-home volumes: - name: jenkins-home gcePersistentDisk: pdName: warpdrive-jenkins-home fsType: ext4 partition: 1"><pre class="notranslate"><code class="notranslate"> volumeMounts: - mountPath: /var/jenkins_home name: jenkins-home volumes: - name: jenkins-home gcePersistentDisk: pdName: warpdrive-jenkins-home fsType: ext4 partition: 1 </code></pre></div> <ul dir="auto"> <li>watch in horror as the pod fails</li> </ul> <p dir="auto"><strong>Anything else do we need to know</strong>:<br> We're desperate</p>
0
<p dir="auto"><em>Original ticket <a href="http://projects.scipy.org/scipy/ticket/988" rel="nofollow">http://projects.scipy.org/scipy/ticket/988</a> on 2009-08-17 by trac user chtito, assigned to unknown.</em></p> <p dir="auto">Using a german locale and the gtk backend induces and error in mmwrite. This bug was already reported in <code class="notranslate">gh-1329</code> and the responsability of gtk was alluded to in <a href="http://projects.scipy.org/numpy/ticket/902#comment:1" rel="nofollow">http://projects.scipy.org/numpy/ticket/902#comment:1</a>.</p> <p dir="auto">This bug has however never been fixed. It might be a bug of gtk only, but I submit it anyway here because it has devastating consequences when using the scipy.io package.</p> <p dir="auto">Here is a test case:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="#!python import os os.environ['LANG'] = 'de_DE.UTF-8' import gtk._gtk def test_locale(): from numpy import array a = array([[1.,2.],[0.,4.5]]) from scipy.sparse import coo_matrix asparse = coo_matrix(a) # figure out a temporary file name: from tempfile import NamedTemporaryFile as tempfile f = tempfile() name = f.name f.close() # mmwrite on that tmp file from scipy.io import mmread, mmwrite mmwrite(f.name, asparse) # read read = mmread(f.name) # compare print a print read.todense() from numpy.testing import assert_array_almost_equal assert_array_almost_equal(read.todense(), a) test_locale()"><pre class="notranslate"><code class="notranslate">#!python import os os.environ['LANG'] = 'de_DE.UTF-8' import gtk._gtk def test_locale(): from numpy import array a = array([[1.,2.],[0.,4.5]]) from scipy.sparse import coo_matrix asparse = coo_matrix(a) # figure out a temporary file name: from tempfile import NamedTemporaryFile as tempfile f = tempfile() name = f.name f.close() # mmwrite on that tmp file from scipy.io import mmread, mmwrite mmwrite(f.name, asparse) # read read = mmread(f.name) # compare print a print read.todense() from numpy.testing import assert_array_almost_equal assert_array_almost_equal(read.todense(), a) test_locale() </code></pre></div>
<p dir="auto"><em>Original ticket <a href="http://projects.scipy.org/scipy/ticket/828" rel="nofollow">http://projects.scipy.org/scipy/ticket/828</a> on 2008-12-28 by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/nilswagner01/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/nilswagner01">@nilswagner01</a>, assigned to unknown.</em></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&gt;&gt;&gt; scipy.__version__ '0.7.0.dev5294' &gt;&gt;&gt; numpy.__version__ '1.3.0.dev6221' ====================================================================== ERROR: test_complex_write_read (test_mmio.TestMMIOCoordinate) ---------------------------------------------------------------------- Traceback (most recent call last): File &quot;/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/tests/test_mmio.py&quot;, line 290, in test_complex_write_read b = mmread(fn).todense() File &quot;/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py&quot;, line 52, in mmread return MMFile().read(source) File &quot;/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py&quot;, line 273, in read return self._parse_body(stream) File &quot;/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py&quot;, line 407, in _parse_body flat_data = flat_data.reshape(-1,4) ValueError: total size of new array must be unchanged ====================================================================== ERROR: read a hermitian matrix ---------------------------------------------------------------------- Traceback (most recent call last): File &quot;/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/tests/test_mmio.py&quot;, line 213, in test_read_hermitian b = mmread(fn).todense() File &quot;/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py&quot;, line 52, in mmread return MMFile().read(source) File &quot;/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py&quot;, line 273, in read return self._parse_body(stream) File &quot;/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py&quot;, line 407, in _parse_body flat_data = flat_data.reshape(-1,4) ValueError: total size of new array must be unchanged "><pre class="notranslate"><code class="notranslate">&gt;&gt;&gt; scipy.__version__ '0.7.0.dev5294' &gt;&gt;&gt; numpy.__version__ '1.3.0.dev6221' ====================================================================== ERROR: test_complex_write_read (test_mmio.TestMMIOCoordinate) ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/tests/test_mmio.py", line 290, in test_complex_write_read b = mmread(fn).todense() File "/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py", line 52, in mmread return MMFile().read(source) File "/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py", line 273, in read return self._parse_body(stream) File "/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py", line 407, in _parse_body flat_data = flat_data.reshape(-1,4) ValueError: total size of new array must be unchanged ====================================================================== ERROR: read a hermitian matrix ---------------------------------------------------------------------- Traceback (most recent call last): File "/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/tests/test_mmio.py", line 213, in test_read_hermitian b = mmread(fn).todense() File "/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py", line 52, in mmread return MMFile().read(source) File "/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py", line 273, in read return self._parse_body(stream) File "/home/nwagner/local/lib64/python2.6/site-packages/scipy/io/mmio.py", line 407, in _parse_body flat_data = flat_data.reshape(-1,4) ValueError: total size of new array must be unchanged </code></pre></div>
1
<h1 dir="auto">version</h1> <p dir="auto">System ==&gt; windows x86_64.<br> opencv:==&gt;download from OpenCV website.<br> First use cmake to download, and then use GCC to compile in CMD.</p> <h1 dir="auto">Error reporting:</h1> <p dir="auto">gcc: error: long: No such file or directory<br> D:\MinGW_x86_64\bin\windres.exe: preprocessing failed.<br> mingw32-make[2]: *** [modules\world\CMakeFiles\opencv_world.dir\build.make:6680: modules/world/CMakeFiles/opencv_world.dir/vs_version.rc.obj] Error 1.<br> mingw32-make[1]: *** [CMakeFiles\Makefile2:3415: modules/world/CMakeFiles/opencv_world.dir/all] Error 2.<br> mingw32-make: *** [Makefile:181: all] Error 2.</p> <h2 dir="auto">After setting the environment variables and configuration files, we are stuck in this step.</h2> <h1 dir="auto">:(</h1>
<h5 dir="auto">System information (version)</h5> <ul dir="auto"> <li>OpenCV =&gt; 4.2.0</li> <li>Operating System / Platform =&gt; :macOS</li> <li>Compiler =&gt; cmake inside Clion</li> </ul> <h5 dir="auto">Detailed description</h5> <h5 dir="auto">Steps to reproduce</h5> <p dir="auto">I use a macOS and Xcode along with Clion, I firstly installed using home brew, however that was not a success, something went wrong with a library inside the clang(that time I used Xcode ).<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/24605645/74667799-ea142600-51de-11ea-8684-6972ab69bed2.png"><img width="1217" alt="image" src="https://user-images.githubusercontent.com/24605645/74667799-ea142600-51de-11ea-8684-6972ab69bed2.png" style="max-width: 100%;"></a><br> so ,this time I tried by downloading the source code and compiled with make, nevertheless it still didn't work.<br> after the installation, the entire set of dylib are missing, I managed to copy the old ones from the version of home brew and tried to wrong, I have tried evertthing I could ,and all I get is still an error</p>
0
<h2 dir="auto"><g-emoji class="g-emoji" alias="bug" fallback-src="https://github.githubassets.com/images/icons/emoji/unicode/1f41b.png">🐛</g-emoji> Bug</h2> <h2 dir="auto">To Reproduce</h2> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import torch MY_STR_CONST = &quot;Hi, I am a string, please realize I am a constant&quot; @torch.jit.script def fn(): return MY_STR_CONST print(fn())"><pre class="notranslate"><code class="notranslate">import torch MY_STR_CONST = "Hi, I am a string, please realize I am a constant" @torch.jit.script def fn(): return MY_STR_CONST print(fn()) </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="Traceback (most recent call last): File &quot;closed_over_string.py&quot;, line 8, in &lt;module&gt; def fn(): File &quot;/private/home/ycao/miniconda3/envs/pytorch/lib/python3.8/site-packages/torch/jit/_script.py&quot;, line 929, in script fn = torch._C._jit_script_compile( RuntimeError: python value of type 'str' cannot be used as a value: File &quot;closed_over_string.py&quot;, line 9 @torch.jit.script def fn(): return MY_STR_CONST ~~~~~~~~~~~~ &lt;--- HERE"><pre class="notranslate"><code class="notranslate">Traceback (most recent call last): File "closed_over_string.py", line 8, in &lt;module&gt; def fn(): File "/private/home/ycao/miniconda3/envs/pytorch/lib/python3.8/site-packages/torch/jit/_script.py", line 929, in script fn = torch._C._jit_script_compile( RuntimeError: python value of type 'str' cannot be used as a value: File "closed_over_string.py", line 9 @torch.jit.script def fn(): return MY_STR_CONST ~~~~~~~~~~~~ &lt;--- HERE </code></pre></div> <h2 dir="auto">Expected behavior</h2> <p dir="auto">fn() should return constant string</p> <p dir="auto">cc <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/suo/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/suo">@suo</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/gmagogsfm/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/gmagogsfm">@gmagogsfm</a></p>
<p dir="auto">From common errors in ParityBench</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="compile,58,RuntimeError: python value of type 'str' cannot be used as a value:,&quot;RuntimeError: python value of type 'str' cannot be used as a value: File &quot;&quot;/tmp/paritybenchydc_9oju/pbg51yh9q6.py&quot;&quot;, line 51 def forward(self, x): x = functional.batch_norm(x, self.running_mean, self.running_var, self.weight, self.bias, self.training, self.momentum, self.eps) if self.activation == ACT_RELU: ~~~~~~~~ &lt;--- HERE return functional.relu(x, inplace=True) elif self.activation == ACT_LEAKY_RELU:"><pre class="notranslate"><code class="notranslate">compile,58,RuntimeError: python value of type 'str' cannot be used as a value:,"RuntimeError: python value of type 'str' cannot be used as a value: File ""/tmp/paritybenchydc_9oju/pbg51yh9q6.py"", line 51 def forward(self, x): x = functional.batch_norm(x, self.running_mean, self.running_var, self.weight, self.bias, self.training, self.momentum, self.eps) if self.activation == ACT_RELU: ~~~~~~~~ &lt;--- HERE return functional.relu(x, inplace=True) elif self.activation == ACT_LEAKY_RELU: </code></pre></div> <p dir="auto">Code example is <a href="https://github.com/jansel/pytorch-jit-paritybench/blob/6c23f5bcbed5ad85ac21573024748b335b8019eb/generated/test_zllrunning_face_parsing_PyTorch.py#L533">here</a></p> <p dir="auto">cc <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/suo/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/suo">@suo</a> <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/gmagogsfm/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/gmagogsfm">@gmagogsfm</a></p>
1
<p dir="auto">Right now, the content of <code class="notranslate">classes_</code> and the shape of the output of <code class="notranslate">predict_proba</code> and <code class="notranslate">decision_function</code> are inconsistent between estimators.<br> If an <a href="http://scikit-learn.org/dev/modules/multiclass.html#multiclass-and-multilabel-algorithms" rel="nofollow">estimator supports</a> multioutput multiclass, <code class="notranslate">classes_</code> will be <code class="notranslate">[[0, 1]] * n_outputs</code> and <code class="notranslate">predict_proba</code> will return an object array of length <code class="notranslate">n_outputs</code> where each is <code class="notranslate">(n_samples, 2)</code>.<br> If the estimator supports multi-label classification, but not multioutput multiclass, <code class="notranslate">classes_</code> will be <code class="notranslate">np.arange(n_outputs)</code> and <code class="notranslate">predict_proba</code> will be <code class="notranslate">(n_samples, n_outputs)</code>.</p> <p dir="auto">That leads to issues such as <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="223399887" data-permission-text="Title is private" data-url="https://github.com/scikit-learn/scikit-learn/issues/8773" data-hovercard-type="pull_request" data-hovercard-url="/scikit-learn/scikit-learn/pull/8773/hovercard" href="https://github.com/scikit-learn/scikit-learn/pull/8773">#8773</a>, but also runs counter to the sklearn promise of a consistent API.<br> Given that even basic API like the <code class="notranslate">score</code> method is broken on multioutput multiclass (see <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="244101623" data-permission-text="Title is private" data-url="https://github.com/scikit-learn/scikit-learn/issues/9414" data-hovercard-type="issue" data-hovercard-url="/scikit-learn/scikit-learn/issues/9414/hovercard" href="https://github.com/scikit-learn/scikit-learn/issues/9414">#9414</a>), I'm not sure it's worth keeping this maintenance burden.</p> <p dir="auto">Alternatively we could detect in the multioutput multiclass classifiers that a problem is actually multilabel and use the appropriate shapes for that.</p> <p dir="auto">Either way, it's an incompatible change that's tricky to do with a deprecation cycle :-/</p>
<p dir="auto">In <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="855155631" data-permission-text="Title is private" data-url="https://github.com/scikit-learn/scikit-learn/issues/19859" data-hovercard-type="pull_request" data-hovercard-url="/scikit-learn/scikit-learn/pull/19859/hovercard" href="https://github.com/scikit-learn/scikit-learn/pull/19859">#19859</a>, I am heading toward addressing some issue already reported long time ago there: <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="19617817" data-permission-text="Title is private" data-url="https://github.com/scikit-learn/scikit-learn/issues/2451" data-hovercard-type="issue" data-hovercard-url="/scikit-learn/scikit-learn/issues/2451/hovercard" href="https://github.com/scikit-learn/scikit-learn/issues/2451">#2451</a></p> <p dir="auto">We have a range of classifier supporting multilabel classification. To give a bit of feedback, I recall what a multilabel indicator matrix look like:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="In [1]: from sklearn.datasets import make_multilabel_classification In [2]: X, y = make_multilabel_classification(n_samples=10) In [3]: y Out[3]: array([[0, 0, 0, 0, 0], [0, 0, 0, 0, 1], [0, 1, 0, 0, 1], [0, 1, 0, 0, 1], [1, 1, 0, 0, 0], [0, 1, 1, 0, 0], [0, 1, 0, 0, 0], [0, 0, 1, 0, 0], [0, 1, 0, 0, 0], [0, 1, 1, 1, 1]])"><pre class="notranslate"><span class="pl-v">In</span> [<span class="pl-c1">1</span>]: <span class="pl-s1">from</span> <span class="pl-s1">sklearn</span>.<span class="pl-s1">datasets</span> <span class="pl-s1">import</span> <span class="pl-s1">make_multilabel_classification</span> <span class="pl-v">In</span> [<span class="pl-c1">2</span>]: <span class="pl-v">X</span>, <span class="pl-s1">y</span> <span class="pl-c1">=</span> <span class="pl-en">make_multilabel_classification</span>(<span class="pl-s1">n_samples</span><span class="pl-c1">=</span><span class="pl-c1">10</span>) <span class="pl-v">In</span> [<span class="pl-c1">3</span>]: <span class="pl-s1">y</span> <span class="pl-v">Out</span>[<span class="pl-c1">3</span>]: <span class="pl-en">array</span>([[<span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>], [<span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">1</span>], [<span class="pl-c1">0</span>, <span class="pl-c1">1</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">1</span>], [<span class="pl-c1">0</span>, <span class="pl-c1">1</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">1</span>], [<span class="pl-c1">1</span>, <span class="pl-c1">1</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>], [<span class="pl-c1">0</span>, <span class="pl-c1">1</span>, <span class="pl-c1">1</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>], [<span class="pl-c1">0</span>, <span class="pl-c1">1</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>], [<span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">1</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>], [<span class="pl-c1">0</span>, <span class="pl-c1">1</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>, <span class="pl-c1">0</span>], [<span class="pl-c1">0</span>, <span class="pl-c1">1</span>, <span class="pl-c1">1</span>, <span class="pl-c1">1</span>, <span class="pl-c1">1</span>]])</pre></div> <p dir="auto">Each column contain 0/1 entries and you can have several 1 for each row. This type of classification is a special case of <code class="notranslate">multiclass-multioutput</code> where each column will not be limited to 0/1 entries but to multiclass labels.</p> <p dir="auto">We have some issue with consistency in scikit-learn when calling the method <code class="notranslate">predict_proba</code> with classifiers handling these type of data.</p> <h2 dir="auto">Current situation in scikit-learn</h2> <p dir="auto">We have a couple of classifiers that handle multilabel targets: tree-based models, neighbors, MLP, and ridge. In addition, the tree-based models and neighbors classifiers handle <code class="notranslate">multiclass-multioutput</code>.</p> <p dir="auto">In a <code class="notranslate">multiclass-multioutput</code> problem, <code class="notranslate">classifier.predict_proba</code> return a list of n_outputs containing arrays of shape (n_samples, n_classes). Since multilabel classification is a specific case of <code class="notranslate">multiclass-multioutput</code>, <code class="notranslate">classifier.predict_proba</code> will return a list of n_outputs containing arrays of shape (n_samples, 2). This should be an historical choice.</p> <p dir="auto">MLP and ridge (currently broken - see <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="856383991" data-permission-text="Title is private" data-url="https://github.com/scikit-learn/scikit-learn/issues/19869" data-hovercard-type="pull_request" data-hovercard-url="/scikit-learn/scikit-learn/pull/19869/hovercard" href="https://github.com/scikit-learn/scikit-learn/pull/19869">#19869</a>) do not support <code class="notranslate">multiclass-multioutput</code>. There internal design make that it is easy to output an array of shape (n_samples, n_outputs) containing the probability of the positive class only when calling <code class="notranslate">classifier.predict_proba</code>.</p> <p dir="auto">Therefore we have two prediction format for the classifier. This RFC intends at taking a decision regarding this discrepancy.</p> <h2 dir="auto">Potential solutions</h2> <h3 dir="auto">1. Keep the outputs as is</h3> <p dir="auto">We can decide to keep the output as we currently do. One can argue that by supporting <code class="notranslate">multiclass-multioutput</code> it is natural to keep the extensive format list of arrays while being efficient with arrays only for classifiers supporting <code class="notranslate">multilabel-indicator</code> targets.<br> It would require to make the documentation to be explicit.</p> <h3 dir="auto">2. Make output consistent</h3> <h4 dir="auto">2.1 By adding an estimator parameter</h4> <p dir="auto">We could add an estimator parameter allowing to switch from one representation to another.</p> <h3 dir="auto">2.2 By adding a parameter to the <code class="notranslate">predict_proba</code> method</h3> <p dir="auto">We could add a parameter to the <code class="notranslate">predict_proba</code> method to switch the output of the representation. It might still imply a classifier to store which type of target where fitted to distinguish between <code class="notranslate">multiclass-multioutput</code> and <code class="notranslate">multilabel-indicator</code> at predict.</p> <h3 dir="auto">2.3 By forcing all estimators to a specific format</h3> <p dir="auto">In addition, we could enforce a specific format such that by default all classifiers return the same output format. In this case, it requires some deprecation cycles.</p>
1
<p dir="auto">hi guys,<br> i have a component by which count character, word a <code class="notranslate">div</code>.<br> now, when component will be render i got a lot duplicate warning in chrome console tool =&gt; <code class="notranslate">Warning: setState(...): Cannot update during an existing state transition</code><br> what can i do for fix this problem?<br> finally, i want return states.<br> thanks</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="import React from 'react'; import ReactDOM from 'react-dom'; import Countable from 'countable'; class Statics extends React.Component { constructor(props) { super(props); this.state = { paragraphs: 0, sentences: 0, words: 0, characters: 0, all: 0 }; this.Counter_Callback = this.Counter_Callback.bind(this); } Counter_Callback(counter) { this.setState({ paragraphs: counter.paragraph, sentences: counter.sentences, words: counter.words, characters: counter.characters, all: counter.all }); } render() { var area = document.getElementById('editor'); Countable.live(area, this.Counter_Callback); return ( &lt;div&gt; &lt;div id=&quot;Word_Counter&quot;&gt; {this.state.words} Words &lt;/div&gt; &lt;/div&gt; ); } } ReactDOM.render(&lt;Statics/&gt;, document.getElementById('footer-statics'));"><pre class="notranslate"><code class="notranslate">import React from 'react'; import ReactDOM from 'react-dom'; import Countable from 'countable'; class Statics extends React.Component { constructor(props) { super(props); this.state = { paragraphs: 0, sentences: 0, words: 0, characters: 0, all: 0 }; this.Counter_Callback = this.Counter_Callback.bind(this); } Counter_Callback(counter) { this.setState({ paragraphs: counter.paragraph, sentences: counter.sentences, words: counter.words, characters: counter.characters, all: counter.all }); } render() { var area = document.getElementById('editor'); Countable.live(area, this.Counter_Callback); return ( &lt;div&gt; &lt;div id="Word_Counter"&gt; {this.state.words} Words &lt;/div&gt; &lt;/div&gt; ); } } ReactDOM.render(&lt;Statics/&gt;, document.getElementById('footer-statics')); </code></pre></div>
<p dir="auto"><strong>Do you want to request a <em>feature</em> or report a <em>bug</em>?</strong><br> No</p> <p dir="auto">I'm trying to build a custom renderer for react using <code class="notranslate">react-reconciler</code>. Most of the documentation and examples I've been able to find support rendering to a target once, but not re-rendering. But this is what I've been able to discover and am looking for more info on.</p> <p dir="auto"><code class="notranslate">prepareUpdate</code> allows you to generate a diff of the old props and new props. The examples I've found say this should return an array but I'm not sure what the items in this array should look like. So for now I'm just returning true from this method.</p> <p dir="auto"><code class="notranslate">commitUpdate</code> is run after <code class="notranslate">prepareUpdate</code> with old and new props, after which I can call the instance to tell it to update itself based on those props. But most examples I've found do not rely on the <code class="notranslate">children</code> from props and rather rely on <code class="notranslate">children</code> to come through methods such as <code class="notranslate">appendChild</code>/<code class="notranslate">removeChild</code>. It appears that when <code class="notranslate">commitUpdate</code> is run, none of the various <code class="notranslate">*Child</code> methods are called leading the <code class="notranslate">newProps</code> in <code class="notranslate">commitUpdate</code> to not reflect the children that are being tracked inside of the class. In this case I'm curious if perhaps I'm missing a <code class="notranslate">*Child</code> method in my implementation that is necessary but I don't know exists.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="appendChild(child) { this.children.push(child) } commitUpdate (oldProps, newProps) { // this.children != newProps.children }"><pre class="notranslate"><code class="notranslate">appendChild(child) { this.children.push(child) } commitUpdate (oldProps, newProps) { // this.children != newProps.children } </code></pre></div> <p dir="auto">I've also noticed that in order for <code class="notranslate">commitUpdate</code> to be called you must also pass in <code class="notranslate">supportsMutation</code>. Is this the correct property to get this working?</p> <p dir="auto">In some examples I see that projects also have a <code class="notranslate">mutation</code> object in their host config that includes essentially copies of the <code class="notranslate">*Child</code> and <code class="notranslate">commitUpdate</code> methods from the host config but when I try to do this in my renderer, those methods never seem to be called.</p> <p dir="auto">I'm also curious what the correct paradigm for attaching the underlying instances to one another. Currently, each of my elements has a render method that will call the render method of all of it's children and then add those children as sub views to the instance. But in cases where children might change, if I called render again I would end up with duplicate children in the parent. I've seen some examples where the elements attach themselves to their parents, rather than rendering all children and attaching the children to itself, which seems like it would resolve this issue, but this brings up another question.</p> <p dir="auto">For a custom element, when is the correct time to add/remove children from the underlying instance? Most examples I've seen use <code class="notranslate">*Child</code> methods to keep track of the children internally and then have a method that renders all children and adds them as sub views. But there is a question in my mind as to whether or not the <code class="notranslate">*Child</code> methods are where I should be adding the children as subviews to the instance. For example, when an instance's <code class="notranslate">appendChild</code> method is called, that's when I should add the subview as a child to the element. When <code class="notranslate">removeChild</code> is called, that is when I should remove that subview from the instance. Rather than simply using these methods to keep track of children to then render them at some other time.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="appendChild(child) { this.view.addSubview(child) } removeChild(child) { this.view.removeSubview(child) }"><pre class="notranslate"><code class="notranslate">appendChild(child) { this.view.addSubview(child) } removeChild(child) { this.view.removeSubview(child) } </code></pre></div> <p dir="auto">Rather than</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="children = new Set() appendChild(child) { this.children.add(child) } removeChild(child) { this.children.delete(child) } render() { this.children.forEach(child =&gt; { this.view.addSubview(this.child.render()) }) return this.view }"><pre class="notranslate"><code class="notranslate">children = new Set() appendChild(child) { this.children.add(child) } removeChild(child) { this.children.delete(child) } render() { this.children.forEach(child =&gt; { this.view.addSubview(this.child.render()) }) return this.view } </code></pre></div>
0
<h2 dir="auto">Bug Report</h2> <p dir="auto"><strong>Current Behavior</strong><br> const aren't being transpiled in the following situation:</p> <ul dir="auto"> <li>they are defined on a dependency file, in node_modules</li> <li>they have a function assigned <code class="notranslate">const a = param =&gt; 'whatever'</code></li> <li>that function is used by another function that is consumed by the entry point</li> </ul> <p dir="auto"><strong>Input Code</strong></p> <ul dir="auto"> <li>Filename: <code class="notranslate">entry.js</code></li> </ul> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import { foo } from 'package_in_node_modules'; export default class Whatever { constructor(param) { console.log(foo(param)); } }"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-kos">{</span> <span class="pl-s1">foo</span> <span class="pl-kos">}</span> <span class="pl-k">from</span> <span class="pl-s">'package_in_node_modules'</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">Whatever</span> <span class="pl-kos">{</span> <span class="pl-en">constructor</span><span class="pl-kos">(</span><span class="pl-s1">param</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">foo</span><span class="pl-kos">(</span><span class="pl-s1">param</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> <ul dir="auto"> <li>Filename: <code class="notranslate">package_in_node_modules/index.js</code></li> </ul> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="const helper = param =&gt; param.length; export function foo(param) { return helper(param) }"><pre class="notranslate"><span class="pl-k">const</span> <span class="pl-en">helper</span> <span class="pl-c1">=</span> <span class="pl-s1">param</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">param</span><span class="pl-kos">.</span><span class="pl-c1">length</span><span class="pl-kos">;</span> <span class="pl-k">export</span> <span class="pl-k">function</span> <span class="pl-en">foo</span><span class="pl-kos">(</span><span class="pl-s1">param</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">return</span> <span class="pl-en">helper</span><span class="pl-kos">(</span><span class="pl-s1">param</span><span class="pl-kos">)</span> <span class="pl-kos">}</span></pre></div> <p dir="auto"><em><strong>build ouptut</strong></em></p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(&quot;Cannot call a class as a function&quot;); } } const helper = param =&gt; param.length; function foo(param) { return helper(param); } var Whatever = function Whatever(param) { _classCallCheck(this, Whatever); console.log(foo(param)); }; export default Whatever;"><pre class="notranslate"><span class="pl-k">function</span> <span class="pl-en">_classCallCheck</span><span class="pl-kos">(</span><span class="pl-s1">instance</span><span class="pl-kos">,</span> <span class="pl-v">Constructor</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-c1">!</span><span class="pl-kos">(</span><span class="pl-s1">instance</span> <span class="pl-k">instanceof</span> <span class="pl-v">Constructor</span><span class="pl-kos">)</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">throw</span> <span class="pl-k">new</span> <span class="pl-v">TypeError</span><span class="pl-kos">(</span><span class="pl-s">"Cannot call a class as a function"</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">const</span> <span class="pl-en">helper</span> <span class="pl-c1">=</span> <span class="pl-s1">param</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">param</span><span class="pl-kos">.</span><span class="pl-c1">length</span><span class="pl-kos">;</span> <span class="pl-k">function</span> <span class="pl-en">foo</span><span class="pl-kos">(</span><span class="pl-s1">param</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">return</span> <span class="pl-en">helper</span><span class="pl-kos">(</span><span class="pl-s1">param</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-k">var</span> <span class="pl-v">Whatever</span> <span class="pl-c1">=</span> <span class="pl-k">function</span> <span class="pl-v">Whatever</span><span class="pl-kos">(</span><span class="pl-s1">param</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-en">_classCallCheck</span><span class="pl-kos">(</span><span class="pl-smi">this</span><span class="pl-kos">,</span> <span class="pl-v">Whatever</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">foo</span><span class="pl-kos">(</span><span class="pl-s1">param</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">export</span> <span class="pl-k">default</span> <span class="pl-v">Whatever</span><span class="pl-kos">;</span></pre></div> <p dir="auto"><strong>Expected behavior/code</strong><br> <code class="notranslate">const helper</code> being replaced by <code class="notranslate">var helper</code></p> <p dir="auto"><em><strong>expected ouptut</strong></em></p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError(&quot;Cannot call a class as a function&quot;); } } var helper = param =&gt; param.length; function foo(param) { return helper(param); } var Whatever = function Whatever(param) { _classCallCheck(this, Whatever); console.log(foo(param)); }; export default Whatever;"><pre class="notranslate"><span class="pl-k">function</span> <span class="pl-en">_classCallCheck</span><span class="pl-kos">(</span><span class="pl-s1">instance</span><span class="pl-kos">,</span> <span class="pl-v">Constructor</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-c1">!</span><span class="pl-kos">(</span><span class="pl-s1">instance</span> <span class="pl-k">instanceof</span> <span class="pl-v">Constructor</span><span class="pl-kos">)</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">throw</span> <span class="pl-k">new</span> <span class="pl-v">TypeError</span><span class="pl-kos">(</span><span class="pl-s">"Cannot call a class as a function"</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">var</span> <span class="pl-en">helper</span> <span class="pl-c1">=</span> <span class="pl-s1">param</span> <span class="pl-c1">=&gt;</span> <span class="pl-s1">param</span><span class="pl-kos">.</span><span class="pl-c1">length</span><span class="pl-kos">;</span> <span class="pl-k">function</span> <span class="pl-en">foo</span><span class="pl-kos">(</span><span class="pl-s1">param</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">return</span> <span class="pl-en">helper</span><span class="pl-kos">(</span><span class="pl-s1">param</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-kos">}</span> <span class="pl-k">var</span> <span class="pl-v">Whatever</span> <span class="pl-c1">=</span> <span class="pl-k">function</span> <span class="pl-v">Whatever</span><span class="pl-kos">(</span><span class="pl-s1">param</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-en">_classCallCheck</span><span class="pl-kos">(</span><span class="pl-smi">this</span><span class="pl-kos">,</span> <span class="pl-v">Whatever</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">foo</span><span class="pl-kos">(</span><span class="pl-s1">param</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">export</span> <span class="pl-k">default</span> <span class="pl-v">Whatever</span><span class="pl-kos">;</span></pre></div> <p dir="auto"><strong>Babel Configuration (babel.config.js, .babelrc, package.json#babel, cli command, .eslintrc)</strong></p> <ul dir="auto"> <li>Filename: <code class="notranslate">.babelrc</code></li> </ul> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="{ &quot;env&quot;: { &quot;es5&quot;: { &quot;presets&quot;: [ [&quot;@babel/preset-env&quot;, { &quot;useBuiltIns&quot;: &quot;usage&quot;, &quot;corejs&quot;: 3, &quot;modules&quot;: false, &quot;targets&quot;: &quot;&gt;= 0.01%&quot; }] ] } } }"><pre class="notranslate"><span class="pl-kos">{</span> <span class="pl-s">"env"</span>: <span class="pl-kos">{</span> <span class="pl-s">"es5"</span>: <span class="pl-kos">{</span> <span class="pl-s">"presets"</span>: <span class="pl-kos">[</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-s">"useBuiltIns"</span>: <span class="pl-s">"usage"</span><span class="pl-kos">,</span> <span class="pl-s">"corejs"</span>: <span class="pl-c1">3</span><span class="pl-kos">,</span> <span class="pl-s">"modules"</span>: <span class="pl-c1">false</span><span class="pl-kos">,</span> <span class="pl-s">"targets"</span>: <span class="pl-s">"&gt;= 0.01%"</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> <ul dir="auto"> <li>Filename: <code class="notranslate">rollup.config.js</code></li> </ul> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="import babel from 'rollup-plugin-babel'; import resolve from 'rollup-plugin-node-resolve'; import commonjs from 'rollup-plugin-commonjs'; export default { input: ['./entry.js'], output: [ { file: `./dist/index.es5.js`, format: 'esm' } ], plugins: [ resolve(), commonjs(), babel({ envName: 'es5' }) ] };"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">babel</span> <span class="pl-k">from</span> <span class="pl-s">'rollup-plugin-babel'</span><span class="pl-kos">;</span> <span class="pl-k">import</span> <span class="pl-s1">resolve</span> <span class="pl-k">from</span> <span class="pl-s">'rollup-plugin-node-resolve'</span><span class="pl-kos">;</span> <span class="pl-k">import</span> <span class="pl-s1">commonjs</span> <span class="pl-k">from</span> <span class="pl-s">'rollup-plugin-commonjs'</span><span class="pl-kos">;</span> <span class="pl-k">export</span> <span class="pl-k">default</span> <span class="pl-kos">{</span> <span class="pl-c1">input</span>: <span class="pl-kos">[</span><span class="pl-s">'./entry.js'</span><span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-c1">output</span>: <span class="pl-kos">[</span> <span class="pl-kos">{</span> <span class="pl-c1">file</span>: <span class="pl-s">`./dist/index.es5.js`</span><span class="pl-kos">,</span> <span class="pl-c1">format</span>: <span class="pl-s">'esm'</span> <span class="pl-kos">}</span> <span class="pl-kos">]</span><span class="pl-kos">,</span> <span class="pl-c1">plugins</span>: <span class="pl-kos">[</span> <span class="pl-en">resolve</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">,</span> <span class="pl-en">commonjs</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">,</span> <span class="pl-en">babel</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">envName</span>: <span class="pl-s">'es5'</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>Environment</strong></p> <ul dir="auto"> <li>Babel version(s): 7.7.4</li> <li>Node/npm version: node 8.16.2 / npm: 6.4.1</li> <li>OS: macOS 10.15.1</li> <li>Monorepo: Lerna</li> <li>How you are using Babel: loader</li> </ul>
<h3 dir="auto">Input Code</h3> <p dir="auto">In a new folder run <code class="notranslate">npm install babel-core babylon</code>, then put the following code in <code class="notranslate">traverse-error.js</code></p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="var code = ` import foo from './foo' const foo = undefined ` var babelCore = require('babel-core') var babylon = require('babylon') var ast = { type: 'File', start: 0, end: code.length, program: babylon.parse(code, { sourceType: 'module' }) } babelCore.traverse(ast, {})"><pre class="notranslate"><span class="pl-k">var</span> <span class="pl-s1">code</span> <span class="pl-c1">=</span> <span class="pl-s">`</span> <span class="pl-s">import foo from './foo'</span> <span class="pl-s">const foo = undefined</span> <span class="pl-s">`</span> <span class="pl-k">var</span> <span class="pl-s1">babelCore</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-k">var</span> <span class="pl-s1">babylon</span> <span class="pl-c1">=</span> <span class="pl-en">require</span><span class="pl-kos">(</span><span class="pl-s">'babylon'</span><span class="pl-kos">)</span> <span class="pl-k">var</span> <span class="pl-s1">ast</span> <span class="pl-c1">=</span> <span class="pl-kos">{</span> <span class="pl-c1">type</span>: <span class="pl-s">'File'</span><span class="pl-kos">,</span> <span class="pl-c1">start</span>: <span class="pl-c1">0</span><span class="pl-kos">,</span> <span class="pl-c1">end</span>: <span class="pl-s1">code</span><span class="pl-kos">.</span><span class="pl-c1">length</span><span class="pl-kos">,</span> <span class="pl-c1">program</span>: <span class="pl-s1">babylon</span><span class="pl-kos">.</span><span class="pl-en">parse</span><span class="pl-kos">(</span><span class="pl-s1">code</span><span class="pl-kos">,</span> <span class="pl-kos">{</span> <span class="pl-c1">sourceType</span>: <span class="pl-s">'module'</span> <span class="pl-kos">}</span><span class="pl-kos">)</span> <span class="pl-kos">}</span> <span class="pl-s1">babelCore</span><span class="pl-kos">.</span><span class="pl-en">traverse</span><span class="pl-kos">(</span><span class="pl-s1">ast</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">Expected Behavior</h3> <p dir="auto"><code class="notranslate">node traverse-error.js</code> should run with no output. If you simply rename the <code class="notranslate">import foo</code> or <code class="notranslate">const foo</code> to avoid the collision, it will run as expected.</p> <h3 dir="auto">Current Behavior</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="asa@asa:/tmp/babel-issue$ node traverse-error.js /tmp/babel-issue/node_modules/babel-traverse/lib/scope/index.js:397 throw this.hub.file.buildCodeFrameError(id, messages.get(&quot;scopeDuplicateDeclaration&quot;, name), TypeError); ^ TypeError: Cannot read property 'file' of undefined at Scope.checkBlockScopedCollisions (/tmp/babel-issue/node_modules/babel-traverse/lib/scope/index.js:397:21) at Scope.registerBinding (/tmp/babel-issue/node_modules/babel-traverse/lib/scope/index.js:579:16) at Scope.registerDeclaration (/tmp/babel-issue/node_modules/babel-traverse/lib/scope/index.js:483:14) at Object.BlockScoped (/tmp/babel-issue/node_modules/babel-traverse/lib/scope/index.js:185:28) at Object.newFn (/tmp/babel-issue/node_modules/babel-traverse/lib/visitors.js:318:17) at NodePath._call (/tmp/babel-issue/node_modules/babel-traverse/lib/path/context.js:76:18) at NodePath.call (/tmp/babel-issue/node_modules/babel-traverse/lib/path/context.js:44:14) at NodePath.visit (/tmp/babel-issue/node_modules/babel-traverse/lib/path/context.js:105:12) at TraversalContext.visitQueue (/tmp/babel-issue/node_modules/babel-traverse/lib/context.js:150:16) at TraversalContext.visitMultiple (/tmp/babel-issue/node_modules/babel-traverse/lib/context.js:103:17)"><pre class="notranslate"><code class="notranslate">asa@asa:/tmp/babel-issue$ node traverse-error.js /tmp/babel-issue/node_modules/babel-traverse/lib/scope/index.js:397 throw this.hub.file.buildCodeFrameError(id, messages.get("scopeDuplicateDeclaration", name), TypeError); ^ TypeError: Cannot read property 'file' of undefined at Scope.checkBlockScopedCollisions (/tmp/babel-issue/node_modules/babel-traverse/lib/scope/index.js:397:21) at Scope.registerBinding (/tmp/babel-issue/node_modules/babel-traverse/lib/scope/index.js:579:16) at Scope.registerDeclaration (/tmp/babel-issue/node_modules/babel-traverse/lib/scope/index.js:483:14) at Object.BlockScoped (/tmp/babel-issue/node_modules/babel-traverse/lib/scope/index.js:185:28) at Object.newFn (/tmp/babel-issue/node_modules/babel-traverse/lib/visitors.js:318:17) at NodePath._call (/tmp/babel-issue/node_modules/babel-traverse/lib/path/context.js:76:18) at NodePath.call (/tmp/babel-issue/node_modules/babel-traverse/lib/path/context.js:44:14) at NodePath.visit (/tmp/babel-issue/node_modules/babel-traverse/lib/path/context.js:105:12) at TraversalContext.visitQueue (/tmp/babel-issue/node_modules/babel-traverse/lib/context.js:150:16) at TraversalContext.visitMultiple (/tmp/babel-issue/node_modules/babel-traverse/lib/context.js:103:17) </code></pre></div> <h3 dir="auto">Context</h3> <p dir="auto">I have an Atom plugin called <a href="https://atom.io/packages/js-hyperclick" rel="nofollow">js-hyperclick</a>. It parses your JS files and allows you to ctrl+click filenames or variables to jump to their definitions. Today I've been working on getting <code class="notranslate">js-hyperclick</code> to inform the user when it can't function. If you have a syntax error that causes <code class="notranslate">babylon.parse</code> to throw I can help the user:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/324999/19017137/c1863948-87e4-11e6-8fca-4cccdbecc5f1.png"><img src="https://cloud.githubusercontent.com/assets/324999/19017137/c1863948-87e4-11e6-8fca-4cccdbecc5f1.png" alt="selection_019" style="max-width: 100%;"></a></p> <p dir="auto">Because this error happens when traversing and the error points to <code class="notranslate">babel-traverse</code> code, showing the user doesn't help them:</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://cloud.githubusercontent.com/assets/324999/19017179/8ae985ba-87e5-11e6-9cd4-6d852dc01d2f.png"><img src="https://cloud.githubusercontent.com/assets/324999/19017179/8ae985ba-87e5-11e6-9cd4-6d852dc01d2f.png" alt="selection_020" style="max-width: 100%;"></a></p> <p dir="auto">I tend to run into this when I'm trying to extract <code class="notranslate">foo</code> into its own file. I'll add <code class="notranslate">import foo from './new-file'</code>, then if this were able to parse I could ctrl+click the <code class="notranslate">./new-file</code> or <code class="notranslate">foo</code> to open a new editor at that path and cut/paste whatever <code class="notranslate">foo</code> needs.</p> <h3 dir="auto">Your Environment</h3> <table role="table"> <thead> <tr> <th>software</th> <th>version</th> </tr> </thead> <tbody> <tr> <td>Babel</td> <td>5.8.25 and 6.17.0</td> </tr> <tr> <td>node</td> <td>4 and 6</td> </tr> </tbody> </table> <p dir="auto">I wouldn't expect it to get fixed back in Babel5, but the code above also demonstrates the error with <code class="notranslate">npm install babel-core@5</code> and replace <code class="notranslate">babylon.parse</code> with <code class="notranslate">babelCore.parse</code></p>
0
<p dir="auto">I have a simple class that extends another where ViewChild is defined in the parent class and the component defined in the html template of each of the subclass. I Updated from beta 6 to beta 11 and didn't notice this in the breaking changes. Perhaps it was never suppose to work in the first place? I could change the code around to make it work again, which might actually turn out better structured, but wanted to know if it suppose to work or just a bug. What's happening now is that the variable is undefined in beta 11.</p>
<ul dir="auto"> <li><strong>What is the expected behavior?</strong><br> 1、node_modules/rxjs/Observable.d.ts(201,66): error TS2304: Cannot find name 'Promise'.<br> 2、node_modules/rxjs/observable/FromObservable.d.ts(7,51): error TS2304: Cannot find name 'Iterator'.</li> <li><strong>Please tell us about your environment:</strong></li> <li>Angular version: 2.0.0-beta.9</li> <li>Browser: [Chrome 48.8</li> <li>Language: [TypeScript 1.8.7]</li> </ul>
0
<p dir="auto">I'm</p> <ol dir="auto"> <li>... Trying to install packages</li> <li>... Search and press Install</li> <li>... Error appears</li> </ol> <p dir="auto"><strong>Atom Version</strong>: 0.170.0<br> <strong>System</strong>: linux 3.13.0-24-generic<br> <strong>Thrown From</strong>: Atom Core</p> <h3 dir="auto">Stack Trace</h3> <p dir="auto">Uncaught Error: getaddrinfo ENOTFOUND avatars2.githubusercontent.com</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="At stream.js:94 Error: getaddrinfo ENOTFOUND avatars2.githubusercontent.com at errnoException (dns.js:41:10) at Object.onlookup [as oncomplete] (dns.js:91:26) "><pre class="notranslate"><code class="notranslate">At stream.js:94 Error: getaddrinfo ENOTFOUND avatars2.githubusercontent.com at errnoException (dns.js:41:10) at Object.onlookup [as oncomplete] (dns.js:91:26) </code></pre></div> <h3 dir="auto">Commands</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" -4:59.5 core:backspace (atom-text-editor.editor.mini) -4:58.0 core:confirm (atom-text-editor.editor.mini) -0:02.8 core:paste (atom-text-editor.editor.mini) -0:00.0 core:confirm (atom-text-editor.editor.mini)"><pre class="notranslate"><code class="notranslate"> -4:59.5 core:backspace (atom-text-editor.editor.mini) -4:58.0 core:confirm (atom-text-editor.editor.mini) -0:02.8 core:paste (atom-text-editor.editor.mini) -0:00.0 core:confirm (atom-text-editor.editor.mini) </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;disabledPackages&quot;: [ &quot;language-objective-c&quot; ], &quot;themes&quot;: [ &quot;seti-ui&quot;, &quot;seti-syntax&quot; ] }, &quot;editor&quot;: { &quot;fontFamily&quot;: &quot;Source Code Pro&quot;, &quot;lineHeight&quot;: 1.5, &quot;invisibles&quot;: {} } }"><pre class="notranslate">{ <span class="pl-ent">"core"</span>: { <span class="pl-ent">"disabledPackages"</span>: [ <span class="pl-s"><span class="pl-pds">"</span>language-objective-c<span class="pl-pds">"</span></span> ], <span class="pl-ent">"themes"</span>: [ <span class="pl-s"><span class="pl-pds">"</span>seti-ui<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>seti-syntax<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<span class="pl-pds">"</span></span>, <span class="pl-ent">"lineHeight"</span>: <span class="pl-c1">1.5</span>, <span class="pl-ent">"invisibles"</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 seti-syntax, v0.2.1 seti-ui, v0.6.1 vim-mode, v0.34.0 # Dev No dev packages"><pre class="notranslate"><span class="pl-c"><span class="pl-c">#</span> User</span> seti<span class="pl-k">-</span>syntax, v0.<span class="pl-ii">2</span>.<span class="pl-ii">1</span> seti<span class="pl-k">-</span>ui, v0.<span class="pl-ii">6</span>.<span class="pl-ii">1</span> vim<span class="pl-k">-</span>mode, v0.<span class="pl-ii">34</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>
<p dir="auto">[Enter steps to reproduce below:]</p> <ol dir="auto"> <li>Atom was open - then Clicked the update and restart option.</li> <li>It did it's thing, then restarted.<br> 3.Clicked on preferences<br> 4.Clicked on packages.</li> </ol> <p dir="auto">That was it.</p> <p dir="auto"><strong>Atom Version</strong>: 0.169.0<br> <strong>System</strong>: Mac OS X 10.10.1<br> <strong>Thrown From</strong>: Atom Core</p> <h3 dir="auto">Stack Trace</h3> <p dir="auto">Uncaught Error: getaddrinfo ENOTFOUND avatars2.githubusercontent.com</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="At stream.js:94 Error: getaddrinfo ENOTFOUND avatars2.githubusercontent.com at errnoException (dns.js:41:10) at Object.onlookup [as oncomplete] (dns.js:91:26) "><pre class="notranslate"><code class="notranslate">At stream.js:94 Error: getaddrinfo ENOTFOUND avatars2.githubusercontent.com at errnoException (dns.js:41:10) at Object.onlookup [as oncomplete] (dns.js:91:26) </code></pre></div> <h3 dir="auto">Commands</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=""><pre class="notranslate"><code class="notranslate"></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;themes&quot;: [ &quot;seti-ui&quot;, &quot;seti-syntax&quot; ] }, &quot;editor&quot;: { &quot;fontSize&quot;: 14, &quot;invisibles&quot;: {} } }"><pre class="notranslate">{ <span class="pl-ent">"core"</span>: { <span class="pl-ent">"themes"</span>: [ <span class="pl-s"><span class="pl-pds">"</span>seti-ui<span class="pl-pds">"</span></span>, <span class="pl-s"><span class="pl-pds">"</span>seti-syntax<span class="pl-pds">"</span></span> ] }, <span class="pl-ent">"editor"</span>: { <span class="pl-ent">"fontSize"</span>: <span class="pl-c1">14</span>, <span class="pl-ent">"invisibles"</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 autoclose-html, v0.12.0 autocomplete-plus, v0.21.0 color-picker, v1.2.4 inline-autocomplete, v0.3.2 language-jade, v0.3.0 linter, v0.7.3 open-last-project, v0.1.1 project-manager, v1.10.0 seti-syntax, v0.1.7 seti-ui, v0.3.6 slash-closer, v0.7.0 # Dev No dev packages"><pre class="notranslate"><span class="pl-c"><span class="pl-c">#</span> User</span> autoclose<span class="pl-k">-</span>html, v0.<span class="pl-ii">12</span>.<span class="pl-ii">0</span> autocomplete<span class="pl-k">-</span>plus, v0.<span class="pl-ii">21</span>.<span class="pl-ii">0</span> color<span class="pl-k">-</span>picker, v1.<span class="pl-ii">2</span>.<span class="pl-ii">4</span> inline<span class="pl-k">-</span>autocomplete, v0.<span class="pl-ii">3</span>.<span class="pl-ii">2</span> language<span class="pl-k">-</span>jade, v0.<span class="pl-ii">3</span>.<span class="pl-ii">0</span> linter, v0.<span class="pl-ii">7</span>.<span class="pl-ii">3</span> open<span class="pl-k">-</span>last<span class="pl-k">-</span>project, v0.<span class="pl-ii">1</span>.<span class="pl-ii">1</span> project<span class="pl-k">-</span>manager, v1.<span class="pl-ii">10</span>.<span class="pl-ii">0</span> seti<span class="pl-k">-</span>syntax, v0.<span class="pl-ii">1</span>.<span class="pl-ii">7</span> seti<span class="pl-k">-</span>ui, v0.<span class="pl-ii">3</span>.<span class="pl-ii">6</span> slash<span class="pl-k">-</span>closer, v0.<span class="pl-ii">7</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">Please go to Stack Overflow for help and support:</p> <p dir="auto"><a href="https://stackoverflow.com/questions/tagged/tensorflow" rel="nofollow">https://stackoverflow.com/questions/tagged/tensorflow</a></p> <p dir="auto">If you open a GitHub issue, here is our policy:</p> <ol dir="auto"> <li>It must be a bug, a feature request, or a significant problem with documentation (for small docs fixes please send a PR instead).</li> <li>The form below must be filled out.</li> <li>It shouldn't be a TensorBoard issue. Those go <a href="https://github.com/tensorflow/tensorboard/issues">here</a>.</li> </ol> <p dir="auto"><strong>Here's why we have that policy</strong>: TensorFlow developers respond to issues. We want to focus on work that benefits the whole community, e.g., fixing bugs and adding features. Support only helps individuals. GitHub also notifies thousands of people when issues are filed. We want them to see you communicating an interesting problem, rather than being redirected to Stack Overflow.</p> <hr> <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>:</li> <li><strong>TensorFlow version (use command below)</strong>:</li> <li><strong>Python version</strong>:</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>:</li> <li><strong>GPU model and memory</strong>:</li> <li><strong>Exact command to reproduce</strong>:</li> </ul> <p dir="auto">You can collect some of this information using our environment capture script:</p> <p dir="auto"><a href="https://github.com/tensorflow/tensorflow/tree/master/tools/tf_env_collect.sh">https://github.com/tensorflow/tensorflow/tree/master/tools/tf_env_collect.sh</a></p> <p dir="auto">You can obtain the TensorFlow version with</p> <p dir="auto">python -c "import tensorflow as tf; print(tf.GIT_VERSION, tf.VERSION)"</p> <h3 dir="auto">Describe the problem</h3> <p dir="auto">I could not install Tensorflow on my Win 7 32-bit machine through Anaconda or Pycharm, but I did<br> on my Win 7 64-bit machine.</p> <h3 dir="auto">Source code / logs</h3> <p dir="auto">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. Try to provide a reproducible test case that is the bare minimum necessary to generate the problem.</p>
<p dir="auto">Unable to train with anything but sgd using xla, due to a missing operation.</p> <p dir="auto">line 76 in <a href="https://github.com/tensorflow/tensorflow/blob/677a14872f028e9be51bd469ec2d5cc43ea9155e/tensorflow/python/training/optimizer.py">https://github.com/tensorflow/tensorflow/blob/677a14872f028e9be51bd469ec2d5cc43ea9155e/tensorflow/python/training/optimizer.py</a></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="def _deduplicate_indexed_slices(values, indices): &quot;&quot;&quot;Sums `values` associated with any non-unique `indices`. Args: values: A `Tensor` with rank &gt;= 1. indices: A one-dimensional integer `Tensor`, indexing into the first dimension of `values` (as in an IndexedSlices object). Returns: A tuple of (`summed_values`, `unique_indices`) where `unique_indices` is a de-duplicated version of `indices` and `summed_values` contains the sum of `values` slices associated with each unique index. &quot;&quot;&quot; unique_indices, new_index_positions = array_ops.unique(indices) &lt;------- MISSING summed_values = math_ops.unsorted_segment_sum( values, new_index_positions, array_ops.shape(unique_indices)[0]) return (summed_values, unique_indices)"><pre class="notranslate"><code class="notranslate">def _deduplicate_indexed_slices(values, indices): """Sums `values` associated with any non-unique `indices`. Args: values: A `Tensor` with rank &gt;= 1. indices: A one-dimensional integer `Tensor`, indexing into the first dimension of `values` (as in an IndexedSlices object). Returns: A tuple of (`summed_values`, `unique_indices`) where `unique_indices` is a de-duplicated version of `indices` and `summed_values` contains the sum of `values` slices associated with each unique index. """ unique_indices, new_index_positions = array_ops.unique(indices) &lt;------- MISSING summed_values = math_ops.unsorted_segment_sum( values, new_index_positions, array_ops.shape(unique_indices)[0]) return (summed_values, unique_indices) </code></pre></div>
0
<ul dir="auto"> <li>VSCode Version: all</li> <li>OS Version:all</li> </ul> <p dir="auto">When I use Code on a touch-enabled device with a stylus rather than a mouse, it is very difficult to use the folding gutter, as it is hidden unless the pointer is hovering over it. While having that gutter hidden when I am not using it nicely reduces visual noise, there are times that I need it to always be there.</p> <p dir="auto">Why not provide a configuration item that allows the user to switch between having it be always visible or only visible on hover?</p>
<p dir="auto">I think there should be a triple state value instead of a boolean in the settings.json. So one can choose between don't show folding, show folding on hover and alwasy show folding.</p>
1
<p dir="auto"><strong>Describe the bug</strong><br> I am trying to post some data with content type application/x-www-form-urlencoded but the content type is changed to multipart/form-data; when I do a post of formdata</p> <p dir="auto"><strong>To Reproduce</strong><br> The situation is reproducable here: <a href="https://codepen.io/ferrykranenburg/pen/abdZrGG" rel="nofollow">https://codepen.io/ferrykranenburg/pen/abdZrGG</a></p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="var bodyFormData = new FormData(); bodyFormData.set(&quot;dbpath&quot;, &quot;somedata&quot;); bodyFormData.set(&quot;username&quot;, &quot;somedata&quot;); bodyFormData.set(&quot;password&quot;, &quot;somedata&quot;); bodyFormData.set(&quot;token&quot;, &quot;somedata&quot;); axios({ method: &quot;post&quot;, url: &quot;https://dev07.changetocomm.net/ac/api/credentials/&quot;, data: bodyFormData, headers: { &quot;content-type&quot;: &quot;application/x-www-form-urlencoded&quot; } });"><pre class="notranslate"><span class="pl-k">var</span> <span class="pl-s1">bodyFormData</span> <span class="pl-c1">=</span> <span class="pl-k">new</span> <span class="pl-v">FormData</span><span class="pl-kos">(</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-s1">bodyFormData</span><span class="pl-kos">.</span><span class="pl-en">set</span><span class="pl-kos">(</span><span class="pl-s">"dbpath"</span><span class="pl-kos">,</span> <span class="pl-s">"somedata"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-s1">bodyFormData</span><span class="pl-kos">.</span><span class="pl-en">set</span><span class="pl-kos">(</span><span class="pl-s">"username"</span><span class="pl-kos">,</span> <span class="pl-s">"somedata"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-s1">bodyFormData</span><span class="pl-kos">.</span><span class="pl-en">set</span><span class="pl-kos">(</span><span class="pl-s">"password"</span><span class="pl-kos">,</span> <span class="pl-s">"somedata"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-s1">bodyFormData</span><span class="pl-kos">.</span><span class="pl-en">set</span><span class="pl-kos">(</span><span class="pl-s">"token"</span><span class="pl-kos">,</span> <span class="pl-s">"somedata"</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-en">axios</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">method</span>: <span class="pl-s">"post"</span><span class="pl-kos">,</span> <span class="pl-c1">url</span>: <span class="pl-s">"https://dev07.changetocomm.net/ac/api/credentials/"</span><span class="pl-kos">,</span> <span class="pl-c1">data</span>: <span class="pl-s1">bodyFormData</span><span class="pl-kos">,</span> <span class="pl-c1">headers</span>: <span class="pl-kos">{</span> <span class="pl-s">"content-type"</span>: <span class="pl-s">"application/x-www-form-urlencoded"</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>Expected behavior</strong><br> The post should be done with 'application/x-www-form-urlencoded' like I'm adding to the headers.</p> <p dir="auto"><strong>Environment:</strong></p> <ul dir="auto"> <li>Axios Version [e.g. 0.19.2]</li> <li>OS: Windows 10</li> <li>Browser: Chrome</li> <li>Browser Version: latest</li> </ul> <p dir="auto"><strong>Additional context/Screenshots</strong><br> See screenshot, the post is done with multipart/form-data header.<br> <a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/5680394/84625491-a8249380-aee3-11ea-85fc-dc39d67b6f9b.png"><img src="https://user-images.githubusercontent.com/5680394/84625491-a8249380-aee3-11ea-85fc-dc39d67b6f9b.png" alt="image" style="max-width: 100%;"></a></p>
<div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="axios({ method: &quot;PUT&quot;, url: url, transformRequest: [function (data, headers) { // Do whatever you want to transform the data return formData; }], headers: { 'Content-Type': file.type }, &quot;withCredentials&quot;: false });"><pre class="notranslate"><span class="pl-en">axios</span><span class="pl-kos">(</span><span class="pl-kos">{</span> <span class="pl-c1">method</span>: <span class="pl-s">"PUT"</span><span class="pl-kos">,</span> <span class="pl-c1">url</span>: <span class="pl-s1">url</span><span class="pl-kos">,</span> <span class="pl-c1">transformRequest</span>: <span class="pl-kos">[</span><span class="pl-k">function</span> <span class="pl-kos">(</span><span class="pl-s1">data</span><span class="pl-kos">,</span> <span class="pl-s1">headers</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-c">// Do whatever you want to transform the data</span> <span class="pl-k">return</span> <span class="pl-s1">formData</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">headers</span>: <span class="pl-kos">{</span> <span class="pl-s">'Content-Type'</span>: <span class="pl-s1">file</span><span class="pl-kos">.</span><span class="pl-c1">type</span> <span class="pl-kos">}</span><span class="pl-kos">,</span> <span class="pl-s">"withCredentials"</span>: <span class="pl-c1">false</span> <span class="pl-kos">}</span><span class="pl-kos">)</span><span class="pl-kos">;</span></pre></div> <p dir="auto">Launched request with Content-Type:<br> Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryPz13ZA77aLqgPlwB</p>
1
<p dir="auto">Summary:<br> the modal is underneath the shades, it should be on top of the shade.</p> <p dir="auto">System:<br> android 4.0.1,<br> chrome beta</p> <p dir="auto">To reproduce:</p> <ol dir="auto"> <li>open <a href="http://twitter.github.com/bootstrap/javascript.html#modals">http://twitter.github.com/bootstrap/javascript.html#modals</a> with chrome</li> <li>click "Launch demo modal"</li> <li>whole screen turns black and the modal is underneath the shade</li> </ol>
<p dir="auto">Summary:<br> the modal is underneath the shades, it should be on top of the shade.</p> <p dir="auto">System:<br> android 4.0.1,<br> chrome beta</p> <p dir="auto">To reproduce:</p> <ol dir="auto"> <li>open <a href="http://twitter.github.com/bootstrap/javascript.html#modals">http://twitter.github.com/bootstrap/javascript.html#modals</a> with chrome</li> <li>click "Launch demo modal"</li> <li>whole screen turns black and the modal is underneath the shade</li> </ol>
1
<p dir="auto">Either make the two modes look the same or be deliberate about places where they should look different.</p>
<p dir="auto">When running on a desktop platform, Flutter should be able to get trackpad gesture information from the host to enable scrolling.</p>
0
<p dir="auto"><strong><a href="https://jira.spring.io/secure/ViewProfile.jspa?name=sbtourist" rel="nofollow">Sergio Bossa</a></strong> opened <strong><a href="https://jira.spring.io/browse/SPR-4435?redirect=false" rel="nofollow">SPR-4435</a></strong> and commented</p> <p dir="auto">The protected ServletRequestAttributes#getSession(boolean ) method returns a null session on child threads.<br> This is wrong because it doesn't get into account what happens in the constructor:</p> <p dir="auto">[code]<br> public ServletRequestAttributes(HttpServletRequest request) {<br> Assert.notNull(request, "Request must not be null");<br> this.request = request;<br> // Fetch existing session reference early, to have it available even<br> // after request completion (for example, in a custom child thread).<br> this.session = request.getSession(false);<br> }<br> [/code]</p> <p dir="auto">I think that the following code into the getSession method:</p> <p dir="auto">[code]<br> this.session = this.request.getSession(allowCreate);<br> return this.session;<br> [/code]</p> <p dir="auto">Should be as follows:</p> <p dir="auto">[code]<br> HttpSession newSession = this.request.getSession(allowCreate);<br> if (newSession != null) {<br> this.session = newSession;<br> }<br> return this.session;<br> [/code]</p> <hr> <p dir="auto"><strong>Affects:</strong> 2.0.7, 2.0.8</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="398085356" data-permission-text="Title is private" data-url="https://github.com/spring-projects/spring-framework/issues/9112" data-hovercard-type="issue" data-hovercard-url="/spring-projects/spring-framework/issues/9112/hovercard" href="https://github.com/spring-projects/spring-framework/issues/9112">#9112</a> ServletRequestAttributes wrongly returns a null http session on child threads. (<em><strong>"duplicates"</strong></em>)</li> </ul>
<p dir="auto"><strong><a href="https://jira.spring.io/secure/ViewProfile.jspa?name=sandrews" rel="nofollow">Scott Andrews</a></strong> opened <strong><a href="https://jira.spring.io/browse/SPR-6351?redirect=false" rel="nofollow">SPR-6351</a></strong> and commented</p> <p dir="auto">Between RC1 and RC2, classpath*: file paths stopped working. In a web app context, I am importing a set of spring contexts that form a plugin system. None of the files that match this pattern are detected<br> &lt;import resource="classpath*:META-INF/insight/insight-plugin-*.xml" /&gt;</p> <p dir="auto">Removing the wild card and hard coding the path also does not pickup the files.<br> &lt;import resource="classpath*:META-INF/insight/insight-plugin-springmvc.xml" /&gt;</p> <p dir="auto">Replacing the classpath*: with classpath: it is able to find the file.<br> &lt;import resource="classpath:META-INF/insight/insight-plugin-springmvc.xml" /&gt;</p> <p dir="auto">Using classpath: with a wild card only imports a single resource. (appears to be the first match alphabetically)<br> &lt;import resource="classpath:META-INF/insight/insight-plugin-*.xml" /&gt;</p> <hr> <p dir="auto"><strong>Affects:</strong> 3.0 RC2</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="398099258" data-permission-text="Title is private" data-url="https://github.com/spring-projects/spring-framework/issues/11032" data-hovercard-type="issue" data-hovercard-url="/spring-projects/spring-framework/issues/11032/hovercard" href="https://github.com/spring-projects/spring-framework/issues/11032">#11032</a> Cannot import bean definitions using classpath*: resource location (<em><strong>"duplicates"</strong></em>)</li> </ul> <p dir="auto">1 votes, 0 watchers</p>
0
<p dir="auto">When a LeftNav is closed, it is not hidden but simply <code class="notranslate">translateX</code> to somewhere out of the screen. However, the focus state of the button in the LeftNav is still active, this will cause some confused behavior for end users.</p> <p dir="auto">A simple test case is as following</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="class TestExample extends React.Component { constructor() { super(); this.state = { open: false }; } closeNav() { this.setState({ open: false }); console.log('click triggered'); } render() { return ( &lt;Paper&gt; &lt;RaisedButton label=&quot;New form&quot; onClick={() =&gt; this.setState({ open: true })}/&gt; &lt;LeftNav open={this.state.open}&gt; &lt;RaisedButton label=&quot;Submit form&quot; onClick={() =&gt; this.closeNav}/&gt; &lt;/LeftNav&gt; &lt;/Paper&gt; ); } }"><pre class="notranslate"><code class="notranslate">class TestExample extends React.Component { constructor() { super(); this.state = { open: false }; } closeNav() { this.setState({ open: false }); console.log('click triggered'); } render() { return ( &lt;Paper&gt; &lt;RaisedButton label="New form" onClick={() =&gt; this.setState({ open: true })}/&gt; &lt;LeftNav open={this.state.open}&gt; &lt;RaisedButton label="Submit form" onClick={() =&gt; this.closeNav}/&gt; &lt;/LeftNav&gt; &lt;/Paper&gt; ); } } </code></pre></div> <p dir="auto">Suppose the users click the "New form" button, which opens the LeftNav, and they click "Submit form" after some operation, if exists. The leftNav will be hidden obviously, however, after it is closed, if the user unexpectedly press key <code class="notranslate">ENTER</code> or <code class="notranslate">SPACE</code>, they will find the form is submitted again as the button is still focused. (in our case there will be duplicated "click triggered" in the console log)</p> <p dir="auto">This behavior is expected with the specs but not the users.</p> <p dir="auto">Currently the workaround is to manipulate the <code class="notranslate">disableKeyboardFocus</code> property of EnhancedButton when the form is closed after <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="127841730" data-permission-text="Title is private" data-url="https://github.com/mui/material-ui/issues/3000" data-hovercard-type="pull_request" data-hovercard-url="/mui/material-ui/pull/3000/hovercard" href="https://github.com/mui/material-ui/pull/3000">#3000</a> is merged.</p>
<p dir="auto">When composing a textfield with <code class="notranslate">FormControl</code>, <code class="notranslate">InputLabel</code> and <code class="notranslate">Input</code>. The placeholder is hidden even when <code class="notranslate">shrink</code> is set to <code class="notranslate">true</code> on <code class="notranslate">InputLabel</code>. <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="251187858" data-permission-text="Title is private" data-url="https://github.com/mui/material-ui/issues/7821" data-hovercard-type="issue" data-hovercard-url="/mui/material-ui/issues/7821/hovercard" href="https://github.com/mui/material-ui/issues/7821">#7821</a></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">Composing an input like this:</p> <div class="highlight highlight-source-js notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="&lt;FormControl &gt; &lt;InputLabel htmlFor=&quot;my-input&quot; shrink&gt; The label &lt;/InputLabel&gt; &lt;Input id=&quot;my-input&quot; placeholder=&quot;Placeholder&quot; /&gt; &lt;/FormControl&gt;"><pre class="notranslate"><span class="pl-c1">&lt;</span><span class="pl-ent">FormControl</span> <span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-ent">InputLabel</span> <span class="pl-c1">htmlFor</span><span class="pl-c1">=</span><span class="pl-s">"my-input"</span> <span class="pl-c1">shrink</span><span class="pl-c1">&gt;</span> The label <span class="pl-c1">&lt;</span><span class="pl-c1">/</span><span class="pl-ent">InputLabel</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-ent">Input</span> <span class="pl-c1">id</span><span class="pl-c1">=</span><span class="pl-s">"my-input"</span> <span class="pl-c1">placeholder</span><span class="pl-c1">=</span><span class="pl-s">"Placeholder"</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">FormControl</span><span class="pl-c1">&gt;</span></pre></div> <p dir="auto">Should display a placeholder at all times, like a regular input (except with content in it).</p> <h2 dir="auto">Current Behavior</h2> <p dir="auto">The placeholder is only shown on focus.</p> <h2 dir="auto">Context</h2> <p dir="auto">I am personally not a fan of material-ui's label animation, it confuses our users, and it's not clear to them that this is an input where they can type something.</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>next</td> </tr> </tbody> </table> <p dir="auto">An attempt at a solution could use the suggestion by <a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/robert-figshare/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/robert-figshare">@robert-figshare</a>. Adding this sort of css to the <code class="notranslate">Input</code> component (not sure how to apply the JSS <code class="notranslate">shrink</code> class):</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="input: { 'label.shrink + $formControl &amp;': { placeholder: { opacity: 0.5 } }, },"><pre class="notranslate"><code class="notranslate">input: { 'label.shrink + $formControl &amp;': { placeholder: { opacity: 0.5 } }, }, </code></pre></div>
0
<p dir="auto">React Devtools doesn't connect to the instance running in the iOS Simulator.</p> <p dir="auto">React DevTools Screenshot</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/542948/158083928-0be956e7-6357-4308-8990-55cd3d0a8565.png"><img src="https://user-images.githubusercontent.com/542948/158083928-0be956e7-6357-4308-8990-55cd3d0a8565.png" alt="image" style="max-width: 100%;"></a></p> <p dir="auto">iOS Simulator Screenshot</p> <p dir="auto"><a target="_blank" rel="noopener noreferrer nofollow" href="https://user-images.githubusercontent.com/542948/158083953-c61f5079-78a9-4424-bae9-c7dfbd633404.png"><img src="https://user-images.githubusercontent.com/542948/158083953-c61f5079-78a9-4424-bae9-c7dfbd633404.png" alt="image" style="max-width: 100%;"></a></p> <p dir="auto">React Native appears to have some interactivity as you can see "DevTools initialized" and the inspector on the iOS Simulator is running in the condensed mode.</p> <p dir="auto">OS: macOS Monterey (12.2.1)<br> Chip: Apple M1 Pro</p>
<h3 dir="auto">Website or app</h3> <p dir="auto">local app development</p> <h3 dir="auto">Repro steps</h3> <p dir="auto">just install react devtools and downgrade to 4.11.0</p> <h3 dir="auto">How often does this bug happen?</h3> <p dir="auto">Every time</p> <h3 dir="auto">DevTools package (automated)</h3> <p dir="auto">react-devtools-core</p> <h3 dir="auto">DevTools version (automated)</h3> <p dir="auto">4.23.0-e28a0db22</p> <h3 dir="auto">Error message (automated)</h3> <p dir="auto">Unsupported Bridge operation "0"</p> <h3 dir="auto">Error call stack (automated)</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="at /Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:53:333837 at c.emit (/Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:53:277732) at /Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:53:279273 at /Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:53:659742 at Array.forEach (&lt;anonymous&gt;) at A.e.onmessage (/Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:53:659726) at A.t (/Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:44:3009) at A.emit (events.js:315:20) at e.exports.L (/Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:8:13567) at e.exports.emit (events.js:315:20)"><pre lang="text" class="notranslate"><code class="notranslate">at /Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:53:333837 at c.emit (/Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:53:277732) at /Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:53:279273 at /Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:53:659742 at Array.forEach (&lt;anonymous&gt;) at A.e.onmessage (/Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:53:659726) at A.t (/Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:44:3009) at A.emit (events.js:315:20) at e.exports.L (/Users/softwaremac/Desktop/Users/JigneshJani/RNProjects/WifiSwitch/WifiSwitchV2_29_5/node_modules/react-devtools/node_modules/react-devtools-core/dist/standalone.js:8:13567) at e.exports.emit (events.js:315:20) </code></pre></div> <h3 dir="auto">Error component stack (automated)</h3> <p dir="auto"><em>No response</em></p> <h3 dir="auto">GitHub query string (automated)</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="https://api.github.com/search/issues?q=Unsupported Bridge operation in:title is:issue is:open is:public label:&quot;Component: Developer Tools&quot; repo:facebook/react"><pre lang="text" class="notranslate"><code class="notranslate">https://api.github.com/search/issues?q=Unsupported Bridge operation in:title is:issue is:open is:public label:"Component: Developer Tools" repo:facebook/react </code></pre></div>
1
<h2 dir="auto">Bug Report</h2> <p dir="auto"><strong>For English only</strong>, other languages will not accept.</p> <p dir="auto">Before report a bug, make sure you have:</p> <ul dir="auto"> <li>Searched open and closed <a href="https://github.com/apache/shardingsphere/issues">GitHub issues</a>.</li> <li>Read documentation: <a href="https://shardingsphere.apache.org/document/current/en/overview" rel="nofollow">ShardingSphere Doc</a>.</li> </ul> <p dir="auto">Please pay attention on issues you submitted, because we maybe need more details.<br> If no response anymore and we cannot reproduce it on current information, we will <strong>close it</strong>.</p> <p dir="auto">Please answer these questions before submitting your issue. Thanks!</p> <h3 dir="auto">Which version of ShardingSphere did you use?</h3> <p dir="auto">5.0.1-SNAPSHOT<br> master<br> commit <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/apache/shardingsphere/commit/654c876aff05c8d51261e9ffb8d46f884fb685c7/hovercard" href="https://github.com/apache/shardingsphere/commit/654c876aff05c8d51261e9ffb8d46f884fb685c7"><tt>654c876</tt></a></p> <h3 dir="auto">Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?</h3> <p dir="auto">ShardingSphere-Proxy</p> <h3 dir="auto">Expected behavior</h3> <p dir="auto">without error</p> <h3 dir="auto">Actual behavior</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[ERROR] 2021-11-25 21:46:41.736 [epollEventLoopGroup-3-5] o.a.s.p.f.n.FrontendChannelInboundHandler - Exception occur: java.lang.IndexOutOfBoundsException: readerIndex(1) + length(4) exceeds writerIndex(4): PooledSlicedByteBuf(ridx: 1, widx: 4, cap: 4/4, unwrapped: PooledUnsafeDirectByteBuf(ridx: 7, widx: 19, cap: 2048)) at io.netty.buffer.AbstractByteBuf.checkReadableBytes0(AbstractByteBuf.java:1442) at io.netty.buffer.AbstractByteBuf.readIntLE(AbstractByteBuf.java:817) at org.apache.shardingsphere.db.protocol.mysql.payload.MySQLPacketPayload.readInt4(MySQLPacketPayload.java:115) at org.apache.shardingsphere.db.protocol.mysql.packet.handshake.MySQLHandshakeResponse41Packet.&lt;init&gt;(MySQLHandshakeResponse41Packet.java:56) at org.apache.shardingsphere.proxy.frontend.mysql.authentication.MySQLAuthenticationEngine.authPhaseFastPath(MySQLAuthenticationEngine.java:88) at org.apache.shardingsphere.proxy.frontend.mysql.authentication.MySQLAuthenticationEngine.authenticate(MySQLAuthenticationEngine.java:75) at org.apache.shardingsphere.proxy.frontend.netty.FrontendChannelInboundHandler.authenticate(FrontendChannelInboundHandler.java:80) at org.apache.shardingsphere.proxy.frontend.netty.FrontendChannelInboundHandler.channelRead(FrontendChannelInboundHandler.java:72) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:324) at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:311) at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:432) at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:276) at io.netty.handler.codec.ByteToMessageCodec.channelRead(ByteToMessageCodec.java:103) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) at io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:795) at io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:480) at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:378) at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:986) at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.lang.Thread.run(Thread.java:748) [ERROR] 2021-11-25 21:46:41.745 [epollEventLoopGroup-3-5] o.a.s.p.f.n.FrontendChannelInboundHandler - Exception occur: java.lang.IndexOutOfBoundsException: readerIndex(1) + length(4) exceeds writerIndex(1): PooledSlicedByteBuf(ridx: 1, widx: 1, cap: 1/1, unwrapped: PooledUnsafeDirectByteBuf(ridx: 11, widx: 19, cap: 2048)) at io.netty.buffer.AbstractByteBuf.checkReadableBytes0(AbstractByteBuf.java:1442) at io.netty.buffer.AbstractByteBuf.readIntLE(AbstractByteBuf.java:817) at org.apache.shardingsphere.db.protocol.mysql.payload.MySQLPacketPayload.readInt4(MySQLPacketPayload.java:115) at org.apache.shardingsphere.db.protocol.mysql.packet.handshake.MySQLHandshakeResponse41Packet.&lt;init&gt;(MySQLHandshakeResponse41Packet.java:56) at org.apache.shardingsphere.proxy.frontend.mysql.authentication.MySQLAuthenticationEngine.authPhaseFastPath(MySQLAuthenticationEngine.java:88) at org.apache.shardingsphere.proxy.frontend.mysql.authentication.MySQLAuthenticationEngine.authenticate(MySQLAuthenticationEngine.java:75) at org.apache.shardingsphere.proxy.frontend.netty.FrontendChannelInboundHandler.authenticate(FrontendChannelInboundHandler.java:80) at org.apache.shardingsphere.proxy.frontend.netty.FrontendChannelInboundHandler.channelRead(FrontendChannelInboundHandler.java:72) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:324) at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:311) at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:432) at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:276) at io.netty.handler.codec.ByteToMessageCodec.channelRead(ByteToMessageCodec.java:103) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) at io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:795) at io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:480) at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:378) at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:986) at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.lang.Thread.run(Thread.java:748)"><pre class="notranslate"><code class="notranslate">[ERROR] 2021-11-25 21:46:41.736 [epollEventLoopGroup-3-5] o.a.s.p.f.n.FrontendChannelInboundHandler - Exception occur: java.lang.IndexOutOfBoundsException: readerIndex(1) + length(4) exceeds writerIndex(4): PooledSlicedByteBuf(ridx: 1, widx: 4, cap: 4/4, unwrapped: PooledUnsafeDirectByteBuf(ridx: 7, widx: 19, cap: 2048)) at io.netty.buffer.AbstractByteBuf.checkReadableBytes0(AbstractByteBuf.java:1442) at io.netty.buffer.AbstractByteBuf.readIntLE(AbstractByteBuf.java:817) at org.apache.shardingsphere.db.protocol.mysql.payload.MySQLPacketPayload.readInt4(MySQLPacketPayload.java:115) at org.apache.shardingsphere.db.protocol.mysql.packet.handshake.MySQLHandshakeResponse41Packet.&lt;init&gt;(MySQLHandshakeResponse41Packet.java:56) at org.apache.shardingsphere.proxy.frontend.mysql.authentication.MySQLAuthenticationEngine.authPhaseFastPath(MySQLAuthenticationEngine.java:88) at org.apache.shardingsphere.proxy.frontend.mysql.authentication.MySQLAuthenticationEngine.authenticate(MySQLAuthenticationEngine.java:75) at org.apache.shardingsphere.proxy.frontend.netty.FrontendChannelInboundHandler.authenticate(FrontendChannelInboundHandler.java:80) at org.apache.shardingsphere.proxy.frontend.netty.FrontendChannelInboundHandler.channelRead(FrontendChannelInboundHandler.java:72) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:324) at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:311) at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:432) at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:276) at io.netty.handler.codec.ByteToMessageCodec.channelRead(ByteToMessageCodec.java:103) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) at io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:795) at io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:480) at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:378) at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:986) at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.lang.Thread.run(Thread.java:748) [ERROR] 2021-11-25 21:46:41.745 [epollEventLoopGroup-3-5] o.a.s.p.f.n.FrontendChannelInboundHandler - Exception occur: java.lang.IndexOutOfBoundsException: readerIndex(1) + length(4) exceeds writerIndex(1): PooledSlicedByteBuf(ridx: 1, widx: 1, cap: 1/1, unwrapped: PooledUnsafeDirectByteBuf(ridx: 11, widx: 19, cap: 2048)) at io.netty.buffer.AbstractByteBuf.checkReadableBytes0(AbstractByteBuf.java:1442) at io.netty.buffer.AbstractByteBuf.readIntLE(AbstractByteBuf.java:817) at org.apache.shardingsphere.db.protocol.mysql.payload.MySQLPacketPayload.readInt4(MySQLPacketPayload.java:115) at org.apache.shardingsphere.db.protocol.mysql.packet.handshake.MySQLHandshakeResponse41Packet.&lt;init&gt;(MySQLHandshakeResponse41Packet.java:56) at org.apache.shardingsphere.proxy.frontend.mysql.authentication.MySQLAuthenticationEngine.authPhaseFastPath(MySQLAuthenticationEngine.java:88) at org.apache.shardingsphere.proxy.frontend.mysql.authentication.MySQLAuthenticationEngine.authenticate(MySQLAuthenticationEngine.java:75) at org.apache.shardingsphere.proxy.frontend.netty.FrontendChannelInboundHandler.authenticate(FrontendChannelInboundHandler.java:80) at org.apache.shardingsphere.proxy.frontend.netty.FrontendChannelInboundHandler.channelRead(FrontendChannelInboundHandler.java:72) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:324) at io.netty.handler.codec.ByteToMessageDecoder.fireChannelRead(ByteToMessageDecoder.java:311) at io.netty.handler.codec.ByteToMessageDecoder.callDecode(ByteToMessageDecoder.java:432) at io.netty.handler.codec.ByteToMessageDecoder.channelRead(ByteToMessageDecoder.java:276) at io.netty.handler.codec.ByteToMessageCodec.channelRead(ByteToMessageCodec.java:103) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.AbstractChannelHandlerContext.fireChannelRead(AbstractChannelHandlerContext.java:357) at io.netty.channel.DefaultChannelPipeline$HeadContext.channelRead(DefaultChannelPipeline.java:1410) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:379) at io.netty.channel.AbstractChannelHandlerContext.invokeChannelRead(AbstractChannelHandlerContext.java:365) at io.netty.channel.DefaultChannelPipeline.fireChannelRead(DefaultChannelPipeline.java:919) at io.netty.channel.epoll.AbstractEpollStreamChannel$EpollStreamUnsafe.epollInReady(AbstractEpollStreamChannel.java:795) at io.netty.channel.epoll.EpollEventLoop.processReady(EpollEventLoop.java:480) at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:378) at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:986) at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.lang.Thread.run(Thread.java:748) </code></pre></div> <h3 dir="auto">Reason analyze (If you can)</h3> <h3 dir="auto">Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.</h3> <ul dir="auto"> <li><a href="https://hub.fastgit.org/pingcap/benchmarksql.git" rel="nofollow">https://hub.fastgit.org/pingcap/benchmarksql.git</a></li> <li>5.0-mysql-support-opt-2.1</li> </ul> <h3 dir="auto">Example codes for reproduce this issue (such as a github link).</h3> <h1 dir="auto">BenchmarkSQL with ShardingSphere-Proxy</h1> <h2 dir="auto">BenchmarkSQL</h2> <p dir="auto"><a href="https://hub.fastgit.org/pingcap/benchmarksql.git" rel="nofollow">https://hub.fastgit.org/pingcap/benchmarksql.git</a><br> 5.0-mysql-support-opt-2.1</p> <h2 dir="auto">MySQL</h2> <p dir="auto">Version:5.7.26 Port:3306</p> <h2 dir="auto">ShardingSphere-Proxy</h2> <p dir="auto"><a href="https://github.com.cnpmjs.org/apache/shardingsphere.git" rel="nofollow">https://github.com.cnpmjs.org/apache/shardingsphere.git</a><br> master<br> commit <a class="commit-link" data-hovercard-type="commit" data-hovercard-url="https://github.com/apache/shardingsphere/commit/654c876aff05c8d51261e9ffb8d46f884fb685c7/hovercard" href="https://github.com/apache/shardingsphere/commit/654c876aff05c8d51261e9ffb8d46f884fb685c7"><tt>654c876</tt></a></p> <h2 dir="auto">About ShardingSphere-Proxy</h2> <h3 dir="auto">server.yaml</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="rules: - !AUTHORITY users: - root@%:root - sharding@:sharding provider: type: NATIVE props: #max-connections-size-per-query: 1 #executor-size: 16 # Infinite by default. #proxy-frontend-flush-threshold: 128 # The default value is 128. #proxy-opentracing-enabled: false #proxy-hint-enabled: false #sql-show: false #check-table-metadata-enabled: false #lock-wait-timeout-milliseconds: 50000 # The maximum time to wait for a lock # Proxy backend query fetch size. A larger value may increase the memory usage of ShardingSphere Proxy. # The default value is -1, which means set the minimum value for different JDBC drivers. #proxy-backend-query-fetch-size: 200 #check-duplicate-table-enabled: false proxy-frontend-executor-size: 200 # Proxy frontend executor size. The default value is 0, which means let Netty decide. # Available options of proxy backend executor suitable: OLAP(default), OLTP. The OLTP option may reduce time cost of writing packets to client, but it may increase the latency of SQL xecution # if client connections are more than proxy-frontend-netty-executor-size, especially executing slow SQL. proxy-backend-executor-suitable: OLTP"><pre class="notranslate"><code class="notranslate">rules: - !AUTHORITY users: - root@%:root - sharding@:sharding provider: type: NATIVE props: #max-connections-size-per-query: 1 #executor-size: 16 # Infinite by default. #proxy-frontend-flush-threshold: 128 # The default value is 128. #proxy-opentracing-enabled: false #proxy-hint-enabled: false #sql-show: false #check-table-metadata-enabled: false #lock-wait-timeout-milliseconds: 50000 # The maximum time to wait for a lock # Proxy backend query fetch size. A larger value may increase the memory usage of ShardingSphere Proxy. # The default value is -1, which means set the minimum value for different JDBC drivers. #proxy-backend-query-fetch-size: 200 #check-duplicate-table-enabled: false proxy-frontend-executor-size: 200 # Proxy frontend executor size. The default value is 0, which means let Netty decide. # Available options of proxy backend executor suitable: OLAP(default), OLTP. The OLTP option may reduce time cost of writing packets to client, but it may increase the latency of SQL xecution # if client connections are more than proxy-frontend-netty-executor-size, especially executing slow SQL. proxy-backend-executor-suitable: OLTP </code></pre></div> <h3 dir="auto">config-sharding.yaml</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="schemaName: proxy_tpcc dataSources: ds_0: url: jdbc:mysql://IP.10.21:3306/tpcc0 username: root password: Passwd connectionTimeoutMilliseconds: 3000 idleTimeoutMilliseconds: 60000 maxLifetimeMilliseconds: 1800000 maxPoolSize: 200 minPoolSize: 0 ds_1: url: jdbc:mysql://IP.10.21:3306/tpcc1 username: root password: Passwd connectionTimeoutMilliseconds: 3000 idleTimeoutMilliseconds: 60000 maxLifetimeMilliseconds: 1800000 maxPoolSize: 200 minPoolSize: 0 ds_2: url: jdbc:mysql://IP.10.21:3306/tpcc2 username: root password: Passwd connectionTimeoutMilliseconds: 3000 idleTimeoutMilliseconds: 60000 maxLifetimeMilliseconds: 1800000 maxPoolSize: 200 minPoolSize: 0 ds_3: url: jdbc:mysql://IP.10.21:3306/tpcc3 username: root password: Passwd connectionTimeoutMilliseconds: 3000 idleTimeoutMilliseconds: 60000 maxLifetimeMilliseconds: 1800000 maxPoolSize: 200 minPoolSize: 0 ds_4: url: jdbc:mysql://IP.10.21:3306/tpcc4 username: root password: Passwd connectionTimeoutMilliseconds: 3000 idleTimeoutMilliseconds: 60000 maxLifetimeMilliseconds: 1800000 maxPoolSize: 200 minPoolSize: 0 rules: - !SHARDING bindingTables: # - bmsql_warehouse, bmsql_customer # - bmsql_stock, bmsql_district, bmsql_order_line - bmsql_district, bmsql_order_line defaultDatabaseStrategy: none: null defaultTableStrategy: none: null keyGenerators: snowflake: props: worker-id: 123 type: SNOWFLAKE shardingAlgorithms: ds_bmsql_customer_inline: props: algorithm-expression: ds_${c_id % 5} type: INLINE ds_bmsql_district_inline: props: algorithm-expression: ds_${d_w_id % 5} type: INLINE ds_bmsql_history_inline: props: algorithm-expression: ds_${h_w_id % 5} type: INLINE ds_bmsql_item_inline: props: algorithm-expression: ds_${i_id % 5} type: INLINE ds_bmsql_new_order_inline: props: algorithm-expression: ds_${no_w_id % 5} type: INLINE ds_bmsql_oorder_inline: props: algorithm-expression: ds_${o_w_id % 5} type: INLINE ds_bmsql_order_line_inline: props: algorithm-expression: ds_${ol_w_id % 5} type: INLINE ds_bmsql_stock_inline: props: algorithm-expression: ds_${s_w_id % 5} type: INLINE ds_bmsql_warehouse_inline: props: algorithm-expression: ds_${w_id % 5} type: INLINE t_bmsql_item: type: INLINE props: algorithm-expression: bmsql_item_${i_im_id % 2} t_bmsql_order_line: type: INLINE props: algorithm-expression: bmsql_order_line_${ol_number % 6} tables: bmsql_config: actualDataNodes: ds_0.bmsql_config bmsql_customer: actualDataNodes: ds_${0..4}.bmsql_customer # tableStrategy: # standard: # shardingColumn: c_id # shardingAlgorithmName: t_bmsql_customer databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_customer_inline shardingColumn: c_id bmsql_district: actualDataNodes: ds_${0..4}.bmsql_district databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_district_inline shardingColumn: d_w_id bmsql_history: actualDataNodes: ds_${0..4}.bmsql_history databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_history_inline shardingColumn: h_w_id bmsql_item: actualDataNodes: ds_${0..4}.bmsql_item_${0..1} tableStrategy: standard: shardingColumn: i_im_id shardingAlgorithmName: t_bmsql_item databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_item_inline shardingColumn: i_id bmsql_new_order: actualDataNodes: ds_${0..4}.bmsql_new_order databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_new_order_inline shardingColumn: no_w_id bmsql_oorder: actualDataNodes: ds_${0..4}.bmsql_oorder databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_oorder_inline shardingColumn: o_w_id bmsql_order_line: actualDataNodes: ds_${0..4}.bmsql_order_line_${0..5} tableStrategy: standard: shardingColumn: ol_number shardingAlgorithmName: t_bmsql_order_line databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_order_line_inline shardingColumn: ol_w_id bmsql_stock: actualDataNodes: ds_${0..4}.bmsql_stock databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_stock_inline shardingColumn: s_w_id bmsql_warehouse: actualDataNodes: ds_${0..4}.bmsql_warehouse databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_warehouse_inline shardingColumn: w_id"><pre class="notranslate"><code class="notranslate">schemaName: proxy_tpcc dataSources: ds_0: url: jdbc:mysql://IP.10.21:3306/tpcc0 username: root password: Passwd connectionTimeoutMilliseconds: 3000 idleTimeoutMilliseconds: 60000 maxLifetimeMilliseconds: 1800000 maxPoolSize: 200 minPoolSize: 0 ds_1: url: jdbc:mysql://IP.10.21:3306/tpcc1 username: root password: Passwd connectionTimeoutMilliseconds: 3000 idleTimeoutMilliseconds: 60000 maxLifetimeMilliseconds: 1800000 maxPoolSize: 200 minPoolSize: 0 ds_2: url: jdbc:mysql://IP.10.21:3306/tpcc2 username: root password: Passwd connectionTimeoutMilliseconds: 3000 idleTimeoutMilliseconds: 60000 maxLifetimeMilliseconds: 1800000 maxPoolSize: 200 minPoolSize: 0 ds_3: url: jdbc:mysql://IP.10.21:3306/tpcc3 username: root password: Passwd connectionTimeoutMilliseconds: 3000 idleTimeoutMilliseconds: 60000 maxLifetimeMilliseconds: 1800000 maxPoolSize: 200 minPoolSize: 0 ds_4: url: jdbc:mysql://IP.10.21:3306/tpcc4 username: root password: Passwd connectionTimeoutMilliseconds: 3000 idleTimeoutMilliseconds: 60000 maxLifetimeMilliseconds: 1800000 maxPoolSize: 200 minPoolSize: 0 rules: - !SHARDING bindingTables: # - bmsql_warehouse, bmsql_customer # - bmsql_stock, bmsql_district, bmsql_order_line - bmsql_district, bmsql_order_line defaultDatabaseStrategy: none: null defaultTableStrategy: none: null keyGenerators: snowflake: props: worker-id: 123 type: SNOWFLAKE shardingAlgorithms: ds_bmsql_customer_inline: props: algorithm-expression: ds_${c_id % 5} type: INLINE ds_bmsql_district_inline: props: algorithm-expression: ds_${d_w_id % 5} type: INLINE ds_bmsql_history_inline: props: algorithm-expression: ds_${h_w_id % 5} type: INLINE ds_bmsql_item_inline: props: algorithm-expression: ds_${i_id % 5} type: INLINE ds_bmsql_new_order_inline: props: algorithm-expression: ds_${no_w_id % 5} type: INLINE ds_bmsql_oorder_inline: props: algorithm-expression: ds_${o_w_id % 5} type: INLINE ds_bmsql_order_line_inline: props: algorithm-expression: ds_${ol_w_id % 5} type: INLINE ds_bmsql_stock_inline: props: algorithm-expression: ds_${s_w_id % 5} type: INLINE ds_bmsql_warehouse_inline: props: algorithm-expression: ds_${w_id % 5} type: INLINE t_bmsql_item: type: INLINE props: algorithm-expression: bmsql_item_${i_im_id % 2} t_bmsql_order_line: type: INLINE props: algorithm-expression: bmsql_order_line_${ol_number % 6} tables: bmsql_config: actualDataNodes: ds_0.bmsql_config bmsql_customer: actualDataNodes: ds_${0..4}.bmsql_customer # tableStrategy: # standard: # shardingColumn: c_id # shardingAlgorithmName: t_bmsql_customer databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_customer_inline shardingColumn: c_id bmsql_district: actualDataNodes: ds_${0..4}.bmsql_district databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_district_inline shardingColumn: d_w_id bmsql_history: actualDataNodes: ds_${0..4}.bmsql_history databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_history_inline shardingColumn: h_w_id bmsql_item: actualDataNodes: ds_${0..4}.bmsql_item_${0..1} tableStrategy: standard: shardingColumn: i_im_id shardingAlgorithmName: t_bmsql_item databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_item_inline shardingColumn: i_id bmsql_new_order: actualDataNodes: ds_${0..4}.bmsql_new_order databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_new_order_inline shardingColumn: no_w_id bmsql_oorder: actualDataNodes: ds_${0..4}.bmsql_oorder databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_oorder_inline shardingColumn: o_w_id bmsql_order_line: actualDataNodes: ds_${0..4}.bmsql_order_line_${0..5} tableStrategy: standard: shardingColumn: ol_number shardingAlgorithmName: t_bmsql_order_line databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_order_line_inline shardingColumn: ol_w_id bmsql_stock: actualDataNodes: ds_${0..4}.bmsql_stock databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_stock_inline shardingColumn: s_w_id bmsql_warehouse: actualDataNodes: ds_${0..4}.bmsql_warehouse databaseStrategy: standard: shardingAlgorithmName: ds_bmsql_warehouse_inline shardingColumn: w_id </code></pre></div> <h3 dir="auto">bin/start.sh</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="SERVER_NAME=ShardingSphere-Proxy cd `dirname $0` cd .. DEPLOY_DIR=`pwd` LOGS_DIR=${DEPLOY_DIR}/logs if [ ! -d ${LOGS_DIR} ]; then mkdir ${LOGS_DIR} fi STDOUT_FILE=${LOGS_DIR}/stdout.log EXT_LIB=${DEPLOY_DIR}/ext-lib CLASS_PATH=.:${DEPLOY_DIR}/lib/*:${EXT_LIB}/* JAVA_OPTS=&quot; -Djava.awt.headless=true -Djava.net.preferIPv4Stack=true &quot; JAVA_MEM_OPTS=&quot; -server -Xmx16g -Xms16g -Xmn8g -Xss1m -XX:+DisableExplicitGC -XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled -XX:LargePageSizeInBytes=128m -XX:+UseFastAccessorMethods -XX:+UseCMSInitiatingOccupancyOnly -XX:CMSInitiatingOccupancyFraction=70 &quot; MAIN_CLASS=org.apache.shardingsphere.proxy.Bootstrap print_usage() { echo &quot;usage: start.sh [port] [config_dir]&quot; echo &quot; port: proxy listen port, default is 3307&quot; echo &quot; config_dir: proxy config directory, default is conf&quot; exit 0 } if [ &quot;$1&quot; == &quot;-h&quot; ] || [ &quot;$1&quot; == &quot;--help&quot; ] ; then print_usage fi echo &quot;Starting the $SERVER_NAME ...&quot; if [ $# == 0 ]; then CLASS_PATH=${DEPLOY_DIR}/conf:${CLASS_PATH} fi if [ $# == 1 ]; then MAIN_CLASS=${MAIN_CLASS}&quot; &quot;$1 echo &quot;The port is $1&quot; CLASS_PATH=${DEPLOY_DIR}/conf:${CLASS_PATH} fi if [ $# == 2 ]; then MAIN_CLASS=${MAIN_CLASS}&quot; &quot;$1&quot; &quot;$2 echo &quot;The port is $1&quot; echo &quot;The configuration path is $DEPLOY_DIR/$2&quot; CLASS_PATH=${DEPLOY_DIR}/$2:${CLASS_PATH} fi echo &quot;The classpath is ${CLASS_PATH}&quot; nohup java ${JAVA_OPTS} ${JAVA_MEM_OPTS} -classpath ${CLASS_PATH} ${MAIN_CLASS} &gt;&gt; ${STDOUT_FILE} 2&gt;&amp;1 &amp; sleep 1 echo &quot;Please check the STDOUT file: $STDOUT_FILE&quot;"><pre class="notranslate"><code class="notranslate">SERVER_NAME=ShardingSphere-Proxy cd `dirname $0` cd .. DEPLOY_DIR=`pwd` LOGS_DIR=${DEPLOY_DIR}/logs if [ ! -d ${LOGS_DIR} ]; then mkdir ${LOGS_DIR} fi STDOUT_FILE=${LOGS_DIR}/stdout.log EXT_LIB=${DEPLOY_DIR}/ext-lib CLASS_PATH=.:${DEPLOY_DIR}/lib/*:${EXT_LIB}/* JAVA_OPTS=" -Djava.awt.headless=true -Djava.net.preferIPv4Stack=true " JAVA_MEM_OPTS=" -server -Xmx16g -Xms16g -Xmn8g -Xss1m -XX:+DisableExplicitGC -XX:+UseConcMarkSweepGC -XX:+CMSParallelRemarkEnabled -XX:LargePageSizeInBytes=128m -XX:+UseFastAccessorMethods -XX:+UseCMSInitiatingOccupancyOnly -XX:CMSInitiatingOccupancyFraction=70 " MAIN_CLASS=org.apache.shardingsphere.proxy.Bootstrap print_usage() { echo "usage: start.sh [port] [config_dir]" echo " port: proxy listen port, default is 3307" echo " config_dir: proxy config directory, default is conf" exit 0 } if [ "$1" == "-h" ] || [ "$1" == "--help" ] ; then print_usage fi echo "Starting the $SERVER_NAME ..." if [ $# == 0 ]; then CLASS_PATH=${DEPLOY_DIR}/conf:${CLASS_PATH} fi if [ $# == 1 ]; then MAIN_CLASS=${MAIN_CLASS}" "$1 echo "The port is $1" CLASS_PATH=${DEPLOY_DIR}/conf:${CLASS_PATH} fi if [ $# == 2 ]; then MAIN_CLASS=${MAIN_CLASS}" "$1" "$2 echo "The port is $1" echo "The configuration path is $DEPLOY_DIR/$2" CLASS_PATH=${DEPLOY_DIR}/$2:${CLASS_PATH} fi echo "The classpath is ${CLASS_PATH}" nohup java ${JAVA_OPTS} ${JAVA_MEM_OPTS} -classpath ${CLASS_PATH} ${MAIN_CLASS} &gt;&gt; ${STDOUT_FILE} 2&gt;&amp;1 &amp; sleep 1 echo "Please check the STDOUT file: $STDOUT_FILE" </code></pre></div> <h2 dir="auto">About BenchmarkSQL</h2> <h3 dir="auto">runDatabaseBuild.sh</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="#!/bin/sh echo $(date &quot;+%Y-%m-%d %H:%M:%S&quot;) if [ $# -lt 1 ] ; then echo &quot;usage: $(basename $0) PROPS [OPT VAL [...]]&quot; &gt;&amp;2 exit 2 fi PROPS=&quot;$1&quot; shift if [ ! -f &quot;${PROPS}&quot; ] ; then echo &quot;${PROPS}: no such file or directory&quot; &gt;&amp;2 exit 1 fi DB=&quot;$(grep '^db=' $PROPS | sed -e 's/^db=//')&quot; BEFORE_LOAD=&quot;tableCreates&quot; #AFTER_LOAD=&quot;indexCreates foreignKeys extraHistID buildFinish&quot; AFTER_LOAD=&quot;indexCreates buildFinish&quot; for step in ${BEFORE_LOAD} ; do ./runSQL.sh &quot;${PROPS}&quot; $step done ./runLoader.sh &quot;${PROPS}&quot; $* for step in ${AFTER_LOAD} ; do ./runSQL.sh &quot;${PROPS}&quot; $step done echo $(date &quot;+%Y-%m-%d %H:%M:%S&quot;) ### props.proxy_mysql db=mysql driver=com.mysql.jdbc.Driver conn=jdbc:mysql://IP.10.25:3307/proxy_tpcc?serverTimezone=UTC&amp;useSSL=false&amp;cachePrepStmts=true&amp;prepStmtCacheSize=8000 user=root password=root warehouses=200 loadWorkers=200 terminals=200 //To run specified transactions per terminal- runMins must equal zero runTxnsPerTerminal=0 //To run for specified minutes- runTxnsPerTerminal must equal zero runMins=10 //Number of total transactions per minute limitTxnsPerMin=0 //Set to true to run in 4.x compatible mode. Set to false to use the //entire configured database evenly. terminalWarehouseFixed=true //The following five values must add up to 100 //The default percentages of 45, 43, 4, 4 &amp; 4 match the TPC-C spec newOrderWeight=45 paymentWeight=43 orderStatusWeight=4 deliveryWeight=4 stockLevelWeight=4 // Directory name to create for collecting detailed result data. // Comment this out to suppress. resultDirectory=my_result_%tY-%tm-%td_%tH%tM%tS osCollectorScript=./misc/os_collector_linux.py osCollectorInterval=1 //osCollectorSSHAddr=user@dbhost osCollectorDevices=net_eth0 blk_sda"><pre class="notranslate"><code class="notranslate">#!/bin/sh echo $(date "+%Y-%m-%d %H:%M:%S") if [ $# -lt 1 ] ; then echo "usage: $(basename $0) PROPS [OPT VAL [...]]" &gt;&amp;2 exit 2 fi PROPS="$1" shift if [ ! -f "${PROPS}" ] ; then echo "${PROPS}: no such file or directory" &gt;&amp;2 exit 1 fi DB="$(grep '^db=' $PROPS | sed -e 's/^db=//')" BEFORE_LOAD="tableCreates" #AFTER_LOAD="indexCreates foreignKeys extraHistID buildFinish" AFTER_LOAD="indexCreates buildFinish" for step in ${BEFORE_LOAD} ; do ./runSQL.sh "${PROPS}" $step done ./runLoader.sh "${PROPS}" $* for step in ${AFTER_LOAD} ; do ./runSQL.sh "${PROPS}" $step done echo $(date "+%Y-%m-%d %H:%M:%S") ### props.proxy_mysql db=mysql driver=com.mysql.jdbc.Driver conn=jdbc:mysql://IP.10.25:3307/proxy_tpcc?serverTimezone=UTC&amp;useSSL=false&amp;cachePrepStmts=true&amp;prepStmtCacheSize=8000 user=root password=root warehouses=200 loadWorkers=200 terminals=200 //To run specified transactions per terminal- runMins must equal zero runTxnsPerTerminal=0 //To run for specified minutes- runTxnsPerTerminal must equal zero runMins=10 //Number of total transactions per minute limitTxnsPerMin=0 //Set to true to run in 4.x compatible mode. Set to false to use the //entire configured database evenly. terminalWarehouseFixed=true //The following five values must add up to 100 //The default percentages of 45, 43, 4, 4 &amp; 4 match the TPC-C spec newOrderWeight=45 paymentWeight=43 orderStatusWeight=4 deliveryWeight=4 stockLevelWeight=4 // Directory name to create for collecting detailed result data. // Comment this out to suppress. resultDirectory=my_result_%tY-%tm-%td_%tH%tM%tS osCollectorScript=./misc/os_collector_linux.py osCollectorInterval=1 //osCollectorSSHAddr=user@dbhost osCollectorDevices=net_eth0 blk_sda </code></pre></div> <h2 dir="auto">About MySQL</h2> <h3 dir="auto">my.cnf</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[mysqld] server_id=13306 port =3306 basedir=/usr/local/mysql5.7 datadir=/data/mysql/mysql3306/data log-error=/data/mysql/mysql3306/data/mysql.err log_bin=/data/mysql/mysql3306/data/mysql-bin gtid-mode=on enforce-gtid-consistency=true log-slave-updates=1 character_set_server = utf8mb4 pid-file=/data/mysql/mysql3306/data/mysql.pid socket=/tmp/mysql3306.sock max_connections=50000 expire_logs_days=1 innodb_buffer_pool_size=8000000000 ### innodb-log-file-size=2000000000 innodb-log-files-in-group=3 innodb-flush-log-at-trx-commit=0 innodb-change-buffer-max-size=40 back_log=900 #innodb_io_capacity #innodb_io_capacity_max innodb_max_dirty_pages_pct=75 innodb_open_files=20480 innodb_buffer_pool_instances=8 innodb_page_cleaners=8 innodb_purge_threads=2 innodb_read_io_threads=8 innodb_write_io_threads=8 table_open_cache=102400 #binlog_expire_logs_seconds=43200 binlog_format=mixed log_timestamps=system thread_cache_size=16384"><pre class="notranslate"><code class="notranslate">[mysqld] server_id=13306 port =3306 basedir=/usr/local/mysql5.7 datadir=/data/mysql/mysql3306/data log-error=/data/mysql/mysql3306/data/mysql.err log_bin=/data/mysql/mysql3306/data/mysql-bin gtid-mode=on enforce-gtid-consistency=true log-slave-updates=1 character_set_server = utf8mb4 pid-file=/data/mysql/mysql3306/data/mysql.pid socket=/tmp/mysql3306.sock max_connections=50000 expire_logs_days=1 innodb_buffer_pool_size=8000000000 ### innodb-log-file-size=2000000000 innodb-log-files-in-group=3 innodb-flush-log-at-trx-commit=0 innodb-change-buffer-max-size=40 back_log=900 #innodb_io_capacity #innodb_io_capacity_max innodb_max_dirty_pages_pct=75 innodb_open_files=20480 innodb_buffer_pool_instances=8 innodb_page_cleaners=8 innodb_purge_threads=2 innodb_read_io_threads=8 innodb_write_io_threads=8 table_open_cache=102400 #binlog_expire_logs_seconds=43200 binlog_format=mixed log_timestamps=system thread_cache_size=16384 </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="### ds 准备 create database tpcc0 ; create database tpcc1 ; create database tpcc2 ; create database tpcc3 ; create database tpcc4 ;"><pre class="notranslate"><code class="notranslate">### ds 准备 create database tpcc0 ; create database tpcc1 ; create database tpcc2 ; create database tpcc3 ; create database tpcc4 ; </code></pre></div> <h2 dir="auto">BenchmarkSQL do</h2> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="./runDatabaseDestroy.sh props.proxy_mysql time ./runDatabaseBuild.sh props.proxy_mysql &gt; 200test &amp;"><pre class="notranslate"><code class="notranslate">./runDatabaseDestroy.sh props.proxy_mysql time ./runDatabaseBuild.sh props.proxy_mysql &gt; 200test &amp; </code></pre></div>
<p dir="auto">Please answer these questions before submitting your issue. Thanks!</p> <h3 dir="auto">Which version of Sharding-Jdbc do you using?</h3> <p dir="auto">1.4.2</p> <h3 dir="auto">Expected behavior</h3> <p dir="auto">分页查询,select * from t_order limit 2,2 路由多个分片,只有一个分片有数据,查询4条记录</p> <h3 dir="auto">Actual behavior</h3> <p dir="auto">应该只返回2条记录</p> <h3 dir="auto">Steps to reproduce the behavior</h3> <p dir="auto">sharding-jdbc-example-mybatis这个demo工程中,增加测试类<br> `<br> package com.dangdang.ddframe.rdb.sharding.example.jdbc;<br> import com.dangdang.ddframe.rdb.sharding.example.jdbc.entity.Order;<br> import com.dangdang.ddframe.rdb.sharding.example.jdbc.repository.OrderRepository;<br> import org.springframework.context.ApplicationContext;<br> import org.springframework.context.support.ClassPathXmlApplicationContext;<br> import java.util.List;</p> <p dir="auto">public class Test {<br> public static void main(final String[] args) {<br> ApplicationContext applicationContext = new ClassPathXmlApplicationContext("META-INF/mybatisContext.xml");<br> OrderRepository orderRepository = applicationContext.getBean(OrderRepository.class);<br> List ls = orderRepository.selectAll();<br> System.out.println(ls);<br> }<br> }</p> <p dir="auto">`</p> <p dir="auto">修改OrderMapper.xml最后一个查询,增加limit<br> `</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="&lt;select id=&quot;selectAll&quot; resultMap=&quot;baseResultMap&quot;&gt; SELECT &lt;include refid=&quot;baseColumnList&quot;/&gt; FROM `t_order` limit 2,2 &lt;/select&gt;"><pre class="notranslate"><code class="notranslate">&lt;select id="selectAll" resultMap="baseResultMap"&gt; SELECT &lt;include refid="baseColumnList"/&gt; FROM `t_order` limit 2,2 &lt;/select&gt; </code></pre></div> <p dir="auto"><code class="notranslate">修改数据库数据:</code><br> delete from ds_0.t_order_0;<br> delete from ds_0.t_order_1;<br> delete from ds_1.t_order_0;<br> delete from ds_1.t_order_1;</p> <p dir="auto">INSERT INTO <code class="notranslate">ds_0</code>.<code class="notranslate">t_order_0</code> VALUES (1000, 10, 'INIT');<br> INSERT INTO <code class="notranslate">ds_0</code>.<code class="notranslate">t_order_0</code> VALUES (1002, 10, 'INIT');<br> INSERT INTO <code class="notranslate">ds_0</code>.<code class="notranslate">t_order_0</code> VALUES (1004, 10, 'INIT');<br> INSERT INTO <code class="notranslate">ds_0</code>.<code class="notranslate">t_order_0</code> VALUES (1006, 10, 'INIT');<br> INSERT INTO <code class="notranslate">ds_0</code>.<code class="notranslate">t_order_0</code> VALUES (1008, 10, 'INIT');<br> `</p> <p dir="auto">执行打印结果有4条记录:<br> [order_id: 1000, user_id: 10, status: INIT, order_id: 1002, user_id: 10, status: INIT, order_id: 1004, user_id: 10, status: INIT, order_id: 1006, user_id: 10, status: INIT]</p> <p dir="auto">调试代码发现,shardingJDBC在包装结果集时,根据mergeContext判断是不是要聚合,ResultSetFactory.getResultSet方法中<br> ShardingResultSets shardingResultSets = new ShardingResultSets(resultSets);<br> 传入的resultSets有4个rs,获取到的shardingResultSets 只有一个,因为只有一个rs有数据,<br> ShardingResultSets.filterResultSets方法会过滤掉没有记录的rs<br> `</p> <p dir="auto">private List filterResultSets(final List resultSets) throws SQLException {<br> List result = new ArrayList&lt;&gt;(resultSets.size());<br> for (ResultSet each : resultSets) {<br> if (each.next()) {<br> result.add(new WrapperResultSet(each));<br> }<br> }<br> return result;<br> }<br> `</p> <p dir="auto">这样的话在shardingResultSets.getType()返回的是SINGLE<br> `</p> <p dir="auto">switch (shardingResultSets.getType()) {<br> case EMPTY:<br> return buildEmpty(resultSets);<br> case SINGLE:<br> return buildSingle(shardingResultSets);<br> case MULTIPLE:<br> return buildMultiple(shardingResultSets, mergeContext);<br> default:<br> throw new UnsupportedOperationException(shardingResultSets.getType().toString());<br> }<br> `<br> 这样就不会去做合并结果集操作了</p> <h3 dir="auto">Please provide the reproduce example codes (such as github link) if possible.</h3>
0
<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="import pandas as pd import numpy as np def gen_one_df(start=0): np.random.seed(0) return pd.DataFrame({'key1' : ['a', 'a', 'b', 'b', 'a'], 'key2' : ['one', 'two', 'one', 'two', 'one'], 'data1' : np.random.randn(5), 'data2' : np.random.randn(5)})[start:] df = gen_one_df() print(df) grouped = df.groupby([str(x) for x in df.dtypes], axis=1) for x, y in grouped: print(x) print(y) def return_new_data(x): # return pd.Series(range(5), index=range(count, count+5)) # return df.reindex(range(count, 5)) return gen_one_df(0) # this works, probably due to index of the return value not being the same or whatever. # return gen_one_df(1) print(grouped.apply(return_new_data))"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">pandas</span> <span class="pl-k">as</span> <span class="pl-s1">pd</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">def</span> <span class="pl-en">gen_one_df</span>(<span class="pl-s1">start</span><span class="pl-c1">=</span><span class="pl-c1">0</span>): <span class="pl-s1">np</span>.<span class="pl-s1">random</span>.<span class="pl-en">seed</span>(<span class="pl-c1">0</span>) <span class="pl-k">return</span> <span class="pl-s1">pd</span>.<span class="pl-v">DataFrame</span>({<span class="pl-s">'key1'</span> : [<span class="pl-s">'a'</span>, <span class="pl-s">'a'</span>, <span class="pl-s">'b'</span>, <span class="pl-s">'b'</span>, <span class="pl-s">'a'</span>], <span class="pl-s">'key2'</span> : [<span class="pl-s">'one'</span>, <span class="pl-s">'two'</span>, <span class="pl-s">'one'</span>, <span class="pl-s">'two'</span>, <span class="pl-s">'one'</span>], <span class="pl-s">'data1'</span> : <span class="pl-s1">np</span>.<span class="pl-s1">random</span>.<span class="pl-en">randn</span>(<span class="pl-c1">5</span>), <span class="pl-s">'data2'</span> : <span class="pl-s1">np</span>.<span class="pl-s1">random</span>.<span class="pl-en">randn</span>(<span class="pl-c1">5</span>)})[<span class="pl-s1">start</span>:] <span class="pl-s1">df</span> <span class="pl-c1">=</span> <span class="pl-en">gen_one_df</span>() <span class="pl-en">print</span>(<span class="pl-s1">df</span>) <span class="pl-s1">grouped</span> <span class="pl-c1">=</span> <span class="pl-s1">df</span>.<span class="pl-en">groupby</span>([<span class="pl-en">str</span>(<span class="pl-s1">x</span>) <span class="pl-k">for</span> <span class="pl-s1">x</span> <span class="pl-c1">in</span> <span class="pl-s1">df</span>.<span class="pl-s1">dtypes</span>], <span class="pl-s1">axis</span><span class="pl-c1">=</span><span class="pl-c1">1</span>) <span class="pl-k">for</span> <span class="pl-s1">x</span>, <span class="pl-s1">y</span> <span class="pl-c1">in</span> <span class="pl-s1">grouped</span>: <span class="pl-en">print</span>(<span class="pl-s1">x</span>) <span class="pl-en">print</span>(<span class="pl-s1">y</span>) <span class="pl-k">def</span> <span class="pl-en">return_new_data</span>(<span class="pl-s1">x</span>): <span class="pl-c"># return pd.Series(range(5), index=range(count, count+5))</span> <span class="pl-c"># return df.reindex(range(count, 5))</span> <span class="pl-k">return</span> <span class="pl-en">gen_one_df</span>(<span class="pl-c1">0</span>) <span class="pl-c"># this works, probably due to index of the return value not being the same or whatever.</span> <span class="pl-c"># return gen_one_df(1)</span> <span class="pl-en">print</span>(<span class="pl-s1">grouped</span>.<span class="pl-en">apply</span>(<span class="pl-s1">return_new_data</span>))</pre></div> <h4 dir="auto">Problem description</h4> <p dir="auto">Here, just as a trivial test of the functionality of group apply for DataFrames. I first group the frame by columns based datatypes. Then when <code class="notranslate">apply</code>ing, I simply return two identical dataframes (see <code class="notranslate">return_new_data</code>) that I assume to be concatenated together along columns (with group names as part of multiindex). However, this fails when the returned dataframes have the same index as the one on which <code class="notranslate">GroupBy</code> object is based on.</p> <p dir="auto">I think this issue is probably caused by the large amount of "well-educated guessing" in the code, and I think this should be added to <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="152567645" data-permission-text="Title is private" data-url="https://github.com/pandas-dev/pandas/issues/13056" data-hovercard-type="issue" data-hovercard-url="/pandas-dev/pandas/issues/13056/hovercard" href="https://github.com/pandas-dev/pandas/issues/13056">#13056</a>.</p> <h4 dir="auto">Expected Output</h4> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" # original dataframe. data1 data2 key1 key2 0 1.764052 -0.977278 a one 1 0.400157 0.950088 a two 2 0.978738 -0.151357 b one 3 2.240893 -0.103219 b two 4 1.867558 0.410599 a one # each group. float64 data1 data2 0 1.764052 -0.977278 1 0.400157 0.950088 2 0.978738 -0.151357 3 2.240893 -0.103219 4 1.867558 0.410599 object key1 key2 0 a one 1 a two 2 b one 3 b two 4 a one # expected output. float64 object data1 data2 key1 key2 data1 data2 key1 key2 0 1.764052 -0.977278 a one 1.764052 -0.977278 a one 1 0.400157 0.950088 a two 0.400157 0.950088 a two 2 0.978738 -0.151357 b one 0.978738 -0.151357 b one 3 2.240893 -0.103219 b two 2.240893 -0.103219 b two 4 1.867558 0.410599 a one 1.867558 0.410599 a one "><pre class="notranslate"><code class="notranslate"> # original dataframe. data1 data2 key1 key2 0 1.764052 -0.977278 a one 1 0.400157 0.950088 a two 2 0.978738 -0.151357 b one 3 2.240893 -0.103219 b two 4 1.867558 0.410599 a one # each group. float64 data1 data2 0 1.764052 -0.977278 1 0.400157 0.950088 2 0.978738 -0.151357 3 2.240893 -0.103219 4 1.867558 0.410599 object key1 key2 0 a one 1 a two 2 b one 3 b two 4 a one # expected output. float64 object data1 data2 key1 key2 data1 data2 key1 key2 0 1.764052 -0.977278 a one 1.764052 -0.977278 a one 1 0.400157 0.950088 a two 0.400157 0.950088 a two 2 0.978738 -0.151357 b one 0.978738 -0.151357 b one 3 2.240893 -0.103219 b two 2.240893 -0.103219 b two 4 1.867558 0.410599 a one 1.867558 0.410599 a one </code></pre></div> <p dir="auto">actual output:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="ValueError Traceback (most recent call last) &lt;ipython-input-1-d64daf6b7b92&gt; in &lt;module&gt;() 26 # return gen_one_df(1) 27 ---&gt; 28 print(grouped.apply(return_new_data)) ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/groupby.py in apply(self, func, *args, **kwargs) 803 # ignore SettingWithCopy here in case the user mutates 804 with option_context('mode.chained_assignment', None): --&gt; 805 return self._python_apply_general(f) 806 807 def _python_apply_general(self, f): ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/groupby.py in _python_apply_general(self, f) 812 keys, 813 values, --&gt; 814 not_indexed_same=mutated or self.mutated) 815 816 def _iterate_slices(self): ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/groupby.py in _wrap_applied_output(self, keys, values, not_indexed_same) 3854 elif isinstance(v, DataFrame): 3855 return self._concat_objects(keys, values, -&gt; 3856 not_indexed_same=not_indexed_same) 3857 elif self.grouper.groupings is not None: 3858 if len(self.grouper.groupings) &gt; 1: ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/groupby.py in _concat_objects(self, keys, values, not_indexed_same) 991 result = result.take(indexer, axis=self.axis) 992 else: --&gt; 993 result = result.reindex(ax, axis=self.axis) 994 995 elif self.group_keys: ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/util/_decorators.py in wrapper(*args, **kwargs) 125 @wraps(func) 126 def wrapper(*args, **kwargs): --&gt; 127 return func(*args, **kwargs) 128 129 if not PY2: [16/388] ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/frame.py in reindex(self, *args, **kwargs) 2933 kwargs.pop('axis', None) 2934 kwargs.pop('labels', None) -&gt; 2935 return super(DataFrame, self).reindex(**kwargs) 2936 2937 @Appender(_shared_docs['reindex_axis'] % _shared_doc_kwargs) ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/generic.py in reindex(self, *args, **kwargs) 3021 # perform the reindex on the axes 3022 return self._reindex_axes(axes, level, limit, tolerance, method, -&gt; 3023 fill_value, copy).__finalize__(self) 3024 3025 def _reindex_axes(self, axes, level, limit, tolerance, method, fill_value, ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/frame.py in _reindex_axes(self, axes, level, limit, tolerance, method, fill_value, copy) 2863 if columns is not None: 2864 frame = frame._reindex_columns(columns, method, copy, level, -&gt; 2865 fill_value, limit, tolerance) 2866 2867 index = axes['index'] ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/frame.py in _reindex_columns(self, new_columns, method, copy, level, fill_value, limit, tolerance) 2888 return self._reindex_with_indexers({1: [new_columns, indexer]}, 2889 copy=copy, fill_value=fill_value, -&gt; 2890 allow_dups=False) 2891 2892 def _reindex_multi(self, axes, copy, fill_value): ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/generic.py in _reindex_with_indexers(self, reindexers, fill_value, copy, allow_dups) 3143 fill_value=fill_value, 3144 allow_dups=allow_dups, -&gt; 3145 copy=copy) 3146 3147 if copy and new_data is self._data: ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/internals.py in reindex_indexer(self, new_axis, indexer, axis, fill_value, allow_dups, copy) 4137 # some axes don't allow reindexing with dups 4138 if not allow_dups: -&gt; 4139 self.axes[axis]._can_reindex(indexer) 4140 4141 if axis &gt;= self.ndim: ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/indexes/base.py in _can_reindex(self, indexer) 2942 # trying to reindex on an axis with duplicates 2943 if not self.is_unique and len(indexer): -&gt; 2944 raise ValueError(&quot;cannot reindex from a duplicate axis&quot;) 2945 2946 def reindex(self, target, method=None, level=None, limit=None, ValueError: cannot reindex from a duplicate axis"><pre class="notranslate"><code class="notranslate">ValueError Traceback (most recent call last) &lt;ipython-input-1-d64daf6b7b92&gt; in &lt;module&gt;() 26 # return gen_one_df(1) 27 ---&gt; 28 print(grouped.apply(return_new_data)) ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/groupby.py in apply(self, func, *args, **kwargs) 803 # ignore SettingWithCopy here in case the user mutates 804 with option_context('mode.chained_assignment', None): --&gt; 805 return self._python_apply_general(f) 806 807 def _python_apply_general(self, f): ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/groupby.py in _python_apply_general(self, f) 812 keys, 813 values, --&gt; 814 not_indexed_same=mutated or self.mutated) 815 816 def _iterate_slices(self): ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/groupby.py in _wrap_applied_output(self, keys, values, not_indexed_same) 3854 elif isinstance(v, DataFrame): 3855 return self._concat_objects(keys, values, -&gt; 3856 not_indexed_same=not_indexed_same) 3857 elif self.grouper.groupings is not None: 3858 if len(self.grouper.groupings) &gt; 1: ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/groupby.py in _concat_objects(self, keys, values, not_indexed_same) 991 result = result.take(indexer, axis=self.axis) 992 else: --&gt; 993 result = result.reindex(ax, axis=self.axis) 994 995 elif self.group_keys: ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/util/_decorators.py in wrapper(*args, **kwargs) 125 @wraps(func) 126 def wrapper(*args, **kwargs): --&gt; 127 return func(*args, **kwargs) 128 129 if not PY2: [16/388] ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/frame.py in reindex(self, *args, **kwargs) 2933 kwargs.pop('axis', None) 2934 kwargs.pop('labels', None) -&gt; 2935 return super(DataFrame, self).reindex(**kwargs) 2936 2937 @Appender(_shared_docs['reindex_axis'] % _shared_doc_kwargs) ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/generic.py in reindex(self, *args, **kwargs) 3021 # perform the reindex on the axes 3022 return self._reindex_axes(axes, level, limit, tolerance, method, -&gt; 3023 fill_value, copy).__finalize__(self) 3024 3025 def _reindex_axes(self, axes, level, limit, tolerance, method, fill_value, ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/frame.py in _reindex_axes(self, axes, level, limit, tolerance, method, fill_value, copy) 2863 if columns is not None: 2864 frame = frame._reindex_columns(columns, method, copy, level, -&gt; 2865 fill_value, limit, tolerance) 2866 2867 index = axes['index'] ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/frame.py in _reindex_columns(self, new_columns, method, copy, level, fill_value, limit, tolerance) 2888 return self._reindex_with_indexers({1: [new_columns, indexer]}, 2889 copy=copy, fill_value=fill_value, -&gt; 2890 allow_dups=False) 2891 2892 def _reindex_multi(self, axes, copy, fill_value): ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/generic.py in _reindex_with_indexers(self, reindexers, fill_value, copy, allow_dups) 3143 fill_value=fill_value, 3144 allow_dups=allow_dups, -&gt; 3145 copy=copy) 3146 3147 if copy and new_data is self._data: ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/internals.py in reindex_indexer(self, new_axis, indexer, axis, fill_value, allow_dups, copy) 4137 # some axes don't allow reindexing with dups 4138 if not allow_dups: -&gt; 4139 self.axes[axis]._can_reindex(indexer) 4140 4141 if axis &gt;= self.ndim: ~/miniconda2/envs/tf15/lib/python3.6/site-packages/pandas/core/indexes/base.py in _can_reindex(self, indexer) 2942 # trying to reindex on an axis with duplicates 2943 if not self.is_unique and len(indexer): -&gt; 2944 raise ValueError("cannot reindex from a duplicate axis") 2945 2946 def reindex(self, target, method=None, level=None, limit=None, ValueError: cannot reindex from a duplicate axis </code></pre></div> <h4 dir="auto">Output of <code class="notranslate">pd.show_versions()</code></h4> <details> <h2 dir="auto">INSTALLED VERSIONS</h2> <p dir="auto">commit: None<br> python: 3.6.4.final.0<br> python-bits: 64<br> OS: Linux<br> OS-release: 2.6.32-573.3.1.el6.x86_64<br> machine: x86_64<br> processor: x86_64<br> byteorder: little<br> LC_ALL: None<br> LANG: en_US.iso885915<br> LOCALE: en_US.ISO8859-15</p> <p dir="auto">pandas: 0.22.0<br> pytest: 3.4.0<br> pip: 9.0.1<br> setuptools: 38.4.0<br> Cython: None<br> numpy: 1.13.3<br> scipy: 1.0.0<br> pyarrow: None<br> xarray: None<br> IPython: 6.2.1<br> sphinx: None<br> patsy: 0.5.0<br> dateutil: 2.6.1<br> pytz: 2017.3<br> blosc: None<br> bottleneck: None<br> tables: None<br> numexpr: None<br> feather: None<br> matplotlib: 2.1.2<br> openpyxl: None<br> xlrd: None<br> xlwt: None<br> xlsxwriter: None<br> lxml: None<br> bs4: None<br> html5lib: 0.9999999<br> sqlalchemy: None<br> pymysql: None<br> psycopg2: None<br> jinja2: 2.10<br> s3fs: None<br> fastparquet: None<br> pandas_gbq: None<br> pandas_datareader: None</p> </details>
<div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="In [22]: df Out[22]: 0 1 2 A 1 2 0.659855 0.340490 0.351028 2 0.695581 0.264714 0.389929 B 2 0.105016 0.070774 0.114629 In [23]: df.to_csv('foo.csv') --------------------------------------------------------------------------- TypeError Traceback (most recent call last) TypeError: only integer arrays with one element can be converted to an index In [24]: df1 Out[24]: 0 1 2 a 0.313015 0.631747 0.091818 a 0.505238 0.260553 0.793378 b 0.441791 0.029851 0.139490 In [25]: df1.to_csv('foo.csv') --------------------------------------------------------------------------- ValueError Traceback (most recent call last) ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()"><pre class="notranslate"><span class="pl-v">In</span> [<span class="pl-c1">22</span>]: <span class="pl-s1">df</span> <span class="pl-v">Out</span>[<span class="pl-c1">22</span>]: <span class="pl-c1">0</span> <span class="pl-c1">1</span> <span class="pl-c1">2</span> <span class="pl-v">A</span> <span class="pl-c1">1</span> <span class="pl-c1">2</span> <span class="pl-c1">0.659855</span> <span class="pl-c1">0.340490</span> <span class="pl-c1">0.351028</span> <span class="pl-c1">2</span> <span class="pl-c1">0.695581</span> <span class="pl-c1">0.264714</span> <span class="pl-c1">0.389929</span> <span class="pl-v">B</span> <span class="pl-c1">2</span> <span class="pl-c1">0.105016</span> <span class="pl-c1">0.070774</span> <span class="pl-c1">0.114629</span> <span class="pl-v">In</span> [<span class="pl-c1">23</span>]: <span class="pl-s1">df</span>.<span class="pl-en">to_csv</span>(<span class="pl-s">'foo.csv'</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">TypeError</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-v">TypeError</span>: <span class="pl-s1">only</span> <span class="pl-s1">integer</span> <span class="pl-s1">arrays</span> <span class="pl-s1">with</span> <span class="pl-s1">one</span> <span class="pl-s1">element</span> <span class="pl-s1">can</span> <span class="pl-s1">be</span> <span class="pl-s1">converted</span> <span class="pl-s1">to</span> <span class="pl-s1">an</span> <span class="pl-s1">index</span> <span class="pl-v">In</span> [<span class="pl-c1">24</span>]: <span class="pl-s1">df1</span> <span class="pl-v">Out</span>[<span class="pl-c1">24</span>]: <span class="pl-c1">0</span> <span class="pl-c1">1</span> <span class="pl-c1">2</span> <span class="pl-s1">a</span> <span class="pl-c1">0.313015</span> <span class="pl-c1">0.631747</span> <span class="pl-c1">0.091818</span> <span class="pl-s1">a</span> <span class="pl-c1">0.505238</span> <span class="pl-c1">0.260553</span> <span class="pl-c1">0.793378</span> <span class="pl-s1">b</span> <span class="pl-c1">0.441791</span> <span class="pl-c1">0.029851</span> <span class="pl-c1">0.139490</span> <span class="pl-v">In</span> [<span class="pl-c1">25</span>]: <span class="pl-s1">df1</span>.<span class="pl-en">to_csv</span>(<span class="pl-s">'foo.csv'</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">ValueError</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-v">ValueError</span>: <span class="pl-v">The</span> <span class="pl-s1">truth</span> <span class="pl-s1">value</span> <span class="pl-s1">of</span> <span class="pl-s1">an</span> <span class="pl-s1">array</span> <span class="pl-k">with</span> <span class="pl-s1">more</span> <span class="pl-s1">than</span> <span class="pl-s1">one</span> <span class="pl-s1">element</span> <span class="pl-c1">is</span> <span class="pl-s1">ambiguous</span>. <span class="pl-v">Use</span> <span class="pl-s1">a</span>.<span class="pl-en">any</span>() <span class="pl-c1">or</span> <span class="pl-s1">a</span>.<span class="pl-en">all</span>()</pre></div>
0
<p dir="auto">The function "pcolormesh(X,Y,C)" will raise no ValueError, if the shapes of C and X,Y are not compatible. Instead a wrong plot will be produced. I suggest to raise a ValueError, if C has a shape of (n,m) and the shapes of X and Y or neither (n,m) nor (n+1,m+1).</p>
<p dir="auto">Both pcolor and pcolormesh use _pcolorargs to process the x, y, z arguments. This handles the cases where x, y are not present, and the cases where one or both of x, y are 1-D rather than 2-D, but it does not check that they are consistent with z.shape. Pcolor will raise an exception if they are not, but pcolormesh will simply make an incorrect plot.</p>
1
<h4 dir="auto">Code Sample, a copy-pastable example if possible</h4> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="d=pd.DataFrame( [ [1,2,3], [1,2,4], [2,3,5], [1,None,5], ], columns=['i','j','k'] ) print d.dtypes d = d.set_index(['i','j'])['k'] #d = d.sort_index(level=[0,1]) d = d.sort_index() print d.loc[(2,3)] # PerformanceWarning even though sorted"><pre class="notranslate"><code class="notranslate">d=pd.DataFrame( [ [1,2,3], [1,2,4], [2,3,5], [1,None,5], ], columns=['i','j','k'] ) print d.dtypes d = d.set_index(['i','j'])['k'] #d = d.sort_index(level=[0,1]) d = d.sort_index() print d.loc[(2,3)] # PerformanceWarning even though sorted </code></pre></div> <h4 dir="auto">Problem description</h4> <p dir="auto">This behavior his is very confusing. The <a href="https://pandas.pydata.org/pandas-docs/stable/advanced.html" rel="nofollow">docs ask me to sort multiindexes</a> to avoid the performance warning,</p> <p dir="auto">If I do it, I still get the PerformanceWarning. If I print the dataframe, I see that data was indeed sorted.</p> <p dir="auto">This is resolved by explicitly specifying the levels to sort: <code class="notranslate">d.sort_index(level=[0,1])</code>.</p> <p dir="auto">As a user, I'm confused. Wasn't <code class="notranslate">d.sort_index()</code> the same thing as <code class="notranslate">d.sort_index(level=...all levels...)</code>? Inspecting my dataframe, it appeared to be the, case (the index was sorted, and nested into a hierarchy).</p> <p dir="auto">Shouldn't <code class="notranslate">d.sort_index()</code> simply be the same as <code class="notranslate">d.sort_index(level=...all levels...)</code></p> <p dir="auto">I'm surprised there's any behavioral difference to be?</p> <p dir="auto">It seems due to:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="d = d.sort_index() print d.index.is_lexsorted() # False d = d.sort_index(level=[0,1]) print d.index.is_lexsorted() # True"><pre class="notranslate"><code class="notranslate">d = d.sort_index() print d.index.is_lexsorted() # False d = d.sort_index(level=[0,1]) print d.index.is_lexsorted() # True </code></pre></div> <p dir="auto">and then, they are only different if the index contains nulls.</p> <p dir="auto">Why there's a difference doesn't seem to be documented.</p> <h4 dir="auto">Expected Output</h4> <p dir="auto">Either: it should be that <code class="notranslate">d.sort_index()</code> === <code class="notranslate">d.sort_index(level=...all levels...)</code><br> or, <a href="https://pandas.pydata.org/pandas-docs/stable/generated/pandas.DataFrame.sort_index.html" rel="nofollow"> dataframe.sort_index documentation</a> could stand improvement and explain when the fully specified level parameter is different to not specifying level.</p> <p dir="auto">I'd prefer: <code class="notranslate">d.sort_index() === d.sort_index(level=d.index.names)</code>, because:</p> <ul dir="auto"> <li>this would allow functions function working on dataframes with vanilla indexes and calling sort_index(), also work optimally when provided dataframes with multindexes.</li> <li>its cumbersome and error-prone to need to remember to specify the level names, since this is only needed in the multi-index case, and then also only in the case where the index contains NULLs.</li> </ul> <h4 dir="auto">Output of <code class="notranslate">pd.show_versions()</code></h4> <details> INSTALLED VERSIONS ------------------ commit: None python: 2.7.6.final.0 python-bits: 64 OS: Linux OS-release: 3.13.0-24-generic machine: x86_64 processor: x86_64 byteorder: little LC_ALL: None LANG: en_US.UTF-8 LOCALE: None.None <p dir="auto">pandas: 0.22.0<br> pytest: None<br> pip: 9.0.1<br> setuptools: 36.0.1<br> Cython: 0.27.3<br> numpy: 1.14.0<br> scipy: 1.0.0<br> pyarrow: None<br> xarray: None<br> IPython: 5.3.0<br> sphinx: None<br> patsy: 0.2.1<br> dateutil: 2.6.1<br> pytz: 2017.2<br> blosc: None<br> bottleneck: None<br> tables: 3.1.1<br> numexpr: 2.6.2<br> feather: None<br> matplotlib: 2.0.2<br> openpyxl: 1.7.0<br> xlrd: 0.9.2<br> xlwt: 0.7.5<br> xlsxwriter: None<br> lxml: None<br> bs4: None<br> html5lib: 0.999999999<br> sqlalchemy: 1.0.15<br> pymysql: None<br> psycopg2: 2.7.3.2 (dt dec pq3 ext lo64)<br> jinja2: 2.9.6<br> s3fs: None<br> fastparquet: None<br> pandas_gbq: None<br> pandas_datareader: None</p> </details>
<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="In [1]: import pandas as pd In [2]: import numpy as np In [3]: dates_range = pd.date_range('2016/10/1', periods=3).repeat(4) In [4]: statuses = np.tile(['A', 'B', None, 'C'], 3) In [5]: values = np.random.randn(12) In [6]: df = pd.DataFrame({'date': dates_range, 'status': statuses, 'value': values}) In [7]: df Out[7]: date status value 0 2016-10-01 A -1.946876 1 2016-10-01 B 1.080243 2 2016-10-01 None 0.165715 3 2016-10-01 C -0.615913 4 2016-10-02 A 0.662645 5 2016-10-02 B 1.448593 6 2016-10-02 None -1.392233 7 2016-10-02 C 1.534083 8 2016-10-03 A 0.801988 9 2016-10-03 B -0.689987 10 2016-10-03 None -0.150036 11 2016-10-03 C -0.197410 In [8]: df.set_index(['date', 'status']).sort_index() Out[8]: value date status 2016-10-01 A -1.946876 B 1.080243 C -0.615913 NaN 0.165715 2016-10-02 A 0.662645 B 1.448593 C 1.534083 NaN -1.392233 2016-10-03 A 0.801988 B -0.689987 C -0.197410 NaN -0.150036 In [9]: df.set_index(['date', 'status']).sort_index().index.is_lexsorted() Out[9]: False In [10]: df.set_index(['date', 'status']).sort_index(level=['date', 'status']).index.is_lexsorted() Out[10]: True"><pre class="notranslate"><span class="pl-v">In</span> [<span class="pl-c1">1</span>]: <span class="pl-s1">import</span> <span class="pl-s1">pandas</span> <span class="pl-k">as</span> <span class="pl-s1">pd</span> <span class="pl-v">In</span> [<span class="pl-c1">2</span>]: <span class="pl-s1">import</span> <span class="pl-s1">numpy</span> <span class="pl-k">as</span> <span class="pl-s1">np</span> <span class="pl-v">In</span> [<span class="pl-c1">3</span>]: <span class="pl-s1">dates_range</span> <span class="pl-c1">=</span> <span class="pl-s1">pd</span>.<span class="pl-en">date_range</span>(<span class="pl-s">'2016/10/1'</span>, <span class="pl-s1">periods</span><span class="pl-c1">=</span><span class="pl-c1">3</span>).<span class="pl-en">repeat</span>(<span class="pl-c1">4</span>) <span class="pl-v">In</span> [<span class="pl-c1">4</span>]: <span class="pl-s1">statuses</span> <span class="pl-c1">=</span> <span class="pl-s1">np</span>.<span class="pl-en">tile</span>([<span class="pl-s">'A'</span>, <span class="pl-s">'B'</span>, <span class="pl-c1">None</span>, <span class="pl-s">'C'</span>], <span class="pl-c1">3</span>) <span class="pl-v">In</span> [<span class="pl-c1">5</span>]: <span class="pl-s1">values</span> <span class="pl-c1">=</span> <span class="pl-s1">np</span>.<span class="pl-s1">random</span>.<span class="pl-en">randn</span>(<span class="pl-c1">12</span>) <span class="pl-v">In</span> [<span class="pl-c1">6</span>]: <span class="pl-s1">df</span> <span class="pl-c1">=</span> <span class="pl-s1">pd</span>.<span class="pl-v">DataFrame</span>({<span class="pl-s">'date'</span>: <span class="pl-s1">dates_range</span>, <span class="pl-s">'status'</span>: <span class="pl-s1">statuses</span>, <span class="pl-s">'value'</span>: <span class="pl-s1">values</span>}) <span class="pl-v">In</span> [<span class="pl-c1">7</span>]: <span class="pl-s1">df</span> <span class="pl-v">Out</span>[<span class="pl-c1">7</span>]: <span class="pl-s1">date</span> <span class="pl-s1">status</span> <span class="pl-s1">value</span> <span class="pl-c1">0</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">01</span> <span class="pl-v">A</span> <span class="pl-c1">-</span><span class="pl-c1">1.946876</span> <span class="pl-c1">1</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">01</span> <span class="pl-v">B</span> <span class="pl-c1">1.080243</span> <span class="pl-c1">2</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">01</span> <span class="pl-v">None</span> <span class="pl-c1">0.165715</span> <span class="pl-c1">3</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">01</span> <span class="pl-v">C</span> <span class="pl-c1">-</span><span class="pl-c1">0.615913</span> <span class="pl-c1">4</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">02</span> <span class="pl-v">A</span> <span class="pl-c1">0.662645</span> <span class="pl-c1">5</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">02</span> <span class="pl-v">B</span> <span class="pl-c1">1.448593</span> <span class="pl-c1">6</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">02</span> <span class="pl-c1">None</span> <span class="pl-c1">-</span><span class="pl-c1">1.392233</span> <span class="pl-c1">7</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">02</span> <span class="pl-v">C</span> <span class="pl-c1">1.534083</span> <span class="pl-c1">8</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">03</span> <span class="pl-v">A</span> <span class="pl-c1">0.801988</span> <span class="pl-c1">9</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">03</span> <span class="pl-v">B</span> <span class="pl-c1">-</span><span class="pl-c1">0.689987</span> <span class="pl-c1">10</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">03</span> <span class="pl-c1">None</span> <span class="pl-c1">-</span><span class="pl-c1">0.150036</span> <span class="pl-c1">11</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">03</span> <span class="pl-v">C</span> <span class="pl-c1">-</span><span class="pl-c1">0.197410</span> <span class="pl-v">In</span> [<span class="pl-c1">8</span>]: <span class="pl-s1">df</span>.<span class="pl-en">set_index</span>([<span class="pl-s">'date'</span>, <span class="pl-s">'status'</span>]).<span class="pl-en">sort_index</span>() <span class="pl-v">Out</span>[<span class="pl-c1">8</span>]: <span class="pl-s1">value</span> <span class="pl-s1">date</span> <span class="pl-s1">status</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">01</span> <span class="pl-v">A</span> <span class="pl-c1">-</span><span class="pl-c1">1.946876</span> <span class="pl-v">B</span> <span class="pl-c1">1.080243</span> <span class="pl-v">C</span> <span class="pl-c1">-</span><span class="pl-c1">0.615913</span> <span class="pl-v">NaN</span> <span class="pl-c1">0.165715</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">02</span> <span class="pl-v">A</span> <span class="pl-c1">0.662645</span> <span class="pl-v">B</span> <span class="pl-c1">1.448593</span> <span class="pl-v">C</span> <span class="pl-c1">1.534083</span> <span class="pl-v">NaN</span> <span class="pl-c1">-</span><span class="pl-c1">1.392233</span> <span class="pl-c1">2016</span><span class="pl-c1">-</span><span class="pl-c1">10</span><span class="pl-c1">-</span><span class="pl-c1">03</span> <span class="pl-v">A</span> <span class="pl-c1">0.801988</span> <span class="pl-v">B</span> <span class="pl-c1">-</span><span class="pl-c1">0.689987</span> <span class="pl-v">C</span> <span class="pl-c1">-</span><span class="pl-c1">0.197410</span> <span class="pl-v">NaN</span> <span class="pl-c1">-</span><span class="pl-c1">0.150036</span> <span class="pl-v">In</span> [<span class="pl-c1">9</span>]: <span class="pl-s1">df</span>.<span class="pl-en">set_index</span>([<span class="pl-s">'date'</span>, <span class="pl-s">'status'</span>]).<span class="pl-en">sort_index</span>().<span class="pl-s1">index</span>.<span class="pl-en">is_lexsorted</span>() <span class="pl-v">Out</span>[<span class="pl-c1">9</span>]: <span class="pl-c1">False</span> <span class="pl-v">In</span> [<span class="pl-c1">10</span>]: <span class="pl-s1">df</span>.<span class="pl-en">set_index</span>([<span class="pl-s">'date'</span>, <span class="pl-s">'status'</span>]).<span class="pl-en">sort_index</span>(<span class="pl-s1">level</span><span class="pl-c1">=</span>[<span class="pl-s">'date'</span>, <span class="pl-s">'status'</span>]).<span class="pl-s1">index</span>.<span class="pl-en">is_lexsorted</span>() <span class="pl-v">Out</span>[<span class="pl-c1">10</span>]: <span class="pl-c1">True</span></pre></div> <h4 dir="auto">Problem description</h4> <p dir="auto">By giving <code class="notranslate">sort_index()</code> no <code class="notranslate">level</code> argument I expect to have the dataframe sorted on all the levels, as indeed it happens. However the <code class="notranslate">is_lexsorted()</code> method afterwards reports that it is not. The problem is fixed if I explicitly pass the <code class="notranslate">level</code> argument.</p> <p dir="auto">The behavior is particularly problematic when the <code class="notranslate">MultiIndex</code> has many levels, say <code class="notranslate">n</code>, and the <code class="notranslate">NaN</code>s appear at level <code class="notranslate">m</code> &lt; <code class="notranslate">n</code>. Then slicing the <code class="notranslate">MultiIndex</code> for levels up to <code class="notranslate">m</code> will work, while for levels from <code class="notranslate">m</code> and above it will crash.</p> <p dir="auto">Note that this was not so in previous versions. Unfortunately not sure which ones; it worked OK in spring 2017, I came upon the issue by re-running code from that time.</p> <h4 dir="auto">Expected Output</h4> <p dir="auto">The expected behavior is the one that I would get with passing the <code class="notranslate">level</code> argument with all index levels, as in the transcript above.</p> <h4 dir="auto">Output of <code class="notranslate">pd.show_versions()</code></h4> <details> <h2 dir="auto">INSTALLED VERSIONS</h2> <p dir="auto">commit: None<br> python: 3.6.3.final.0<br> python-bits: 64<br> OS: Darwin<br> OS-release: 17.0.0<br> machine: x86_64<br> processor: i386<br> byteorder: little<br> LC_ALL: en_US.UTF-8<br> LANG: en_US.UTF-8<br> LOCALE: en_US.UTF-8</p> <p dir="auto">pandas: 0.20.3<br> pytest: None<br> pip: 9.0.1<br> setuptools: 36.5.0<br> Cython: None<br> numpy: 1.13.3<br> scipy: 0.19.1<br> xarray: None<br> IPython: 6.2.0<br> sphinx: None<br> patsy: 0.4.1<br> dateutil: 2.6.1<br> pytz: 2017.2<br> blosc: None<br> bottleneck: None<br> tables: None<br> numexpr: None<br> feather: None<br> matplotlib: 2.0.2<br> openpyxl: None<br> xlrd: 1.0.0<br> xlwt: None<br> xlsxwriter: None<br> lxml: None<br> bs4: 4.6.0<br> html5lib: 0.999999999<br> sqlalchemy: 1.1.14<br> pymysql: 0.7.11.None<br> psycopg2: None<br> jinja2: 2.9.6<br> s3fs: None<br> pandas_gbq: None<br> pandas_datareader: None</p> </details>
1
<p dir="auto">Give your h1 element with the text I am dodger blue! the color dodger blue.<br> keep failure, I suspect that the unit test could have bug.</p> <p dir="auto">Challenge <a href="https://www.freecodecamp.com/en/challenges/html5-and-css/use-hex-code-to-mix-colors" rel="nofollow">use-hex-code-to-mix-colors</a> has an issue.<br> User Agent is: <code class="notranslate">Mozilla/5.0 (Macintosh; Intel Mac OS X 10_11_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/53.0.2785.89 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; .red-text { color: #FF0000; } .green-text { color: #00FF00; } .dodger-blue-text { color: #1E90FF; } .orange-text { color: #FFA500; } &lt;/style&gt; &lt;h1 class=&quot;red-text&quot;&gt;I am red!&lt;/h1&gt; &lt;h1 class=&quot;green-text&quot;&gt;I am green!&lt;/h1&gt; &lt;h1 class=&quot;dodger-blue-text&quot;&gt;I am dodger blue!&lt;/h1&gt; &lt;h1 class=&quot;orange-text&quot;&gt;I am orange!&lt;/h1&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-c1">red-text</span> { <span class="pl-c1">color</span><span class="pl-kos">:</span> <span class="pl-pds"><span class="pl-kos">#</span>FF0000</span>; } .<span class="pl-c1">green-text</span> { <span class="pl-c1">color</span><span class="pl-kos">:</span> <span class="pl-pds"><span class="pl-kos">#</span>00FF00</span>; } .<span class="pl-c1">dodger-blue-text</span> { <span class="pl-c1">color</span><span class="pl-kos">:</span> <span class="pl-pds"><span class="pl-kos">#</span>1E90FF</span>; } .<span class="pl-c1">orange-text</span> { <span class="pl-c1">color</span><span class="pl-kos">:</span> <span class="pl-pds"><span class="pl-kos">#</span>FFA500</span>; } <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">h1</span> <span class="pl-c1">class</span>="<span class="pl-s">red-text</span>"<span class="pl-kos">&gt;</span>I am red!<span class="pl-kos">&lt;/</span><span class="pl-ent">h1</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h1</span> <span class="pl-c1">class</span>="<span class="pl-s">green-text</span>"<span class="pl-kos">&gt;</span>I am green!<span class="pl-kos">&lt;/</span><span class="pl-ent">h1</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h1</span> <span class="pl-c1">class</span>="<span class="pl-s">dodger-blue-text</span>"<span class="pl-kos">&gt;</span>I am dodger blue!<span class="pl-kos">&lt;/</span><span class="pl-ent">h1</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h1</span> <span class="pl-c1">class</span>="<span class="pl-s">orange-text</span>"<span class="pl-kos">&gt;</span>I am orange!<span class="pl-kos">&lt;/</span><span class="pl-ent">h1</span><span class="pl-kos">&gt;</span> ```</pre></div>
<p dir="auto">Challenge <a href="https://www.freecodecamp.com/en/challenges/html5-and-css/use-hex-code-to-mix-colors" rel="nofollow">use-hex-code-to-mix-colors</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/52.0.2743.116 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; .red-text { color: #ff0000; } .green-text { color: #00ff00; } .dodger-blue-text { color: #1e90ff; } .orange-text { color: #ffa500; } &lt;/style&gt; &lt;h1 class=&quot;red-text&quot;&gt;I am red!&lt;/h1&gt; &lt;h1 class=&quot;green-text&quot;&gt;I am green!&lt;/h1&gt; &lt;h1 class=&quot;dodger-blue-text&quot;&gt;I am dodger blue!&lt;/h1&gt; &lt;h1 class=&quot;orange-text&quot;&gt;I am orange!&lt;/h1&gt; ``` Screenshot: ![image](https://cloud.githubusercontent.com/assets/3306170/18378269/47f34348-766c-11e6-8fb7-6e2da365ced7.png)"><pre class="notranslate"><span class="pl-kos">&lt;</span><span class="pl-ent">style</span><span class="pl-kos">&gt;</span> .<span class="pl-c1">red-text</span> { <span class="pl-c1">color</span><span class="pl-kos">:</span> <span class="pl-pds"><span class="pl-kos">#</span>ff0000</span>; } .<span class="pl-c1">green-text</span> { <span class="pl-c1">color</span><span class="pl-kos">:</span> <span class="pl-pds"><span class="pl-kos">#</span>00ff00</span>; } .<span class="pl-c1">dodger-blue-text</span> { <span class="pl-c1">color</span><span class="pl-kos">:</span> <span class="pl-pds"><span class="pl-kos">#</span>1e90ff</span>; } .<span class="pl-c1">orange-text</span> { <span class="pl-c1">color</span><span class="pl-kos">:</span> <span class="pl-pds"><span class="pl-kos">#</span>ffa500</span>; } <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">h1</span> <span class="pl-c1">class</span>="<span class="pl-s">red-text</span>"<span class="pl-kos">&gt;</span>I am red!<span class="pl-kos">&lt;/</span><span class="pl-ent">h1</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h1</span> <span class="pl-c1">class</span>="<span class="pl-s">green-text</span>"<span class="pl-kos">&gt;</span>I am green!<span class="pl-kos">&lt;/</span><span class="pl-ent">h1</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h1</span> <span class="pl-c1">class</span>="<span class="pl-s">dodger-blue-text</span>"<span class="pl-kos">&gt;</span>I am dodger blue!<span class="pl-kos">&lt;/</span><span class="pl-ent">h1</span><span class="pl-kos">&gt;</span> <span class="pl-kos">&lt;</span><span class="pl-ent">h1</span> <span class="pl-c1">class</span>="<span class="pl-s">orange-text</span>"<span class="pl-kos">&gt;</span>I am orange!<span class="pl-kos">&lt;/</span><span class="pl-ent">h1</span><span class="pl-kos">&gt;</span> ``` Screenshot: ![image](https://cloud.githubusercontent.com/assets/3306170/18378269/47f34348-766c-11e6-8fb7-6e2da365ced7.png)</pre></div>
1
<p dir="auto">It just popped up when I was closing a tab.</p> <p dir="auto">[Enter steps to reproduce below:]</p> <ol dir="auto"> <li>...</li> <li>...</li> </ol> <p dir="auto"><strong>Atom Version</strong>: 1.0.0<br> <strong>System</strong>: Microsoft Windows 7 Ultimate<br> <strong>Thrown From</strong>: Atom Core</p> <h3 dir="auto">Stack Trace</h3> <p dir="auto">Uncaught Error: Cannot find module './context-menu'<br> Error: Cannot find module './context-menu'<br> at Function.Module._resolveFilename (module.js:328:15)<br> at Function.Module._load (module.js:270:25)<br> at Module.require (module.js:357:17)<br> at require (module.js:376:17)<br> at BrowserWindow. (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\src\browser\atom-window.js:149:27)<br> at emitOne (events.js:77:13)<br> at BrowserWindow.emit (events.js:166:7)<br> at callFunction (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\browser\lib\rpc-server.js:116:18)<br> at EventEmitter. (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\browser\lib\rpc-server.js:208:14)<br> at emitMany (events.js:108:13)</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="At C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\renderer\api\lib\remote.js:77 Error: Cannot find module './context-menu' Error: Cannot find module './context-menu' at Function.Module._resolveFilename (module.js:328:15) at Function.Module._load (module.js:270:25) at Module.require (module.js:357:17) at require (module.js:376:17) at BrowserWindow.&lt;anonymous&gt; (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\src\browser\atom-window.js:149:27) at emitOne (events.js:77:13) at BrowserWindow.emit (events.js:166:7) at callFunction (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\browser\lib\rpc-server.js:116:18) at EventEmitter.&lt;anonymous&gt; (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\browser\lib\rpc-server.js:208:14) at emitMany (events.js:108:13) at metaToValue (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\renderer\api\lib\remote.js:77:15) at BrowserWindow.RemoteMemberFunction [as emit] (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\renderer\api\lib\remote.js:111:26) at ContextMenuManager.module.exports.ContextMenuManager.showForEvent (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\src\context-menu-manager.js:170:31) at HTMLDocument.&lt;anonymous&gt; (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\src\window-event-handler.js:150:33) at HTMLDocument.handler (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\src\space-pen-extensions.js:112:34) at HTMLDocument.jQuery.event.dispatch (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\node_modules\space-pen\vendor\jquery.js:4681:9) at HTMLDocument.elemData.handle (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\node_modules\space-pen\vendor\jquery.js:4359:46)"><pre class="notranslate"><code class="notranslate">At C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\renderer\api\lib\remote.js:77 Error: Cannot find module './context-menu' Error: Cannot find module './context-menu' at Function.Module._resolveFilename (module.js:328:15) at Function.Module._load (module.js:270:25) at Module.require (module.js:357:17) at require (module.js:376:17) at BrowserWindow.&lt;anonymous&gt; (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\src\browser\atom-window.js:149:27) at emitOne (events.js:77:13) at BrowserWindow.emit (events.js:166:7) at callFunction (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\browser\lib\rpc-server.js:116:18) at EventEmitter.&lt;anonymous&gt; (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\browser\lib\rpc-server.js:208:14) at emitMany (events.js:108:13) at metaToValue (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\renderer\api\lib\remote.js:77:15) at BrowserWindow.RemoteMemberFunction [as emit] (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\atom.asar\renderer\api\lib\remote.js:111:26) at ContextMenuManager.module.exports.ContextMenuManager.showForEvent (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\src\context-menu-manager.js:170:31) at HTMLDocument.&lt;anonymous&gt; (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\src\window-event-handler.js:150:33) at HTMLDocument.handler (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\src\space-pen-extensions.js:112:34) at HTMLDocument.jQuery.event.dispatch (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\node_modules\space-pen\vendor\jquery.js:4681:9) at HTMLDocument.elemData.handle (C:\Users\a\AppData\Local\atom\app-1.0.0\resources\app.asar\node_modules\space-pen\vendor\jquery.js:4359:46) </code></pre></div> <h3 dir="auto">Commands</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" 2x -1:02.8.0 application:new-file (ul.list-inline.tab-bar.inset-panel)"><pre class="notranslate"><code class="notranslate"> 2x -1:02.8.0 application:new-file (ul.list-inline.tab-bar.inset-panel) </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="{}"><pre class="notranslate">{}</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 No installed packages # Dev No dev packages"><pre class="notranslate"><span class="pl-c"><span class="pl-c">#</span> User</span> <span class="pl-en">No</span> <span class="pl-en">installed</span> packages <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">I right-clicked on a folder in the tree view</p> <p dir="auto"><strong>Atom Version</strong>: 0.194.0<br> <strong>System</strong>: Windows 7 Entreprise<br> <strong>Thrown From</strong>: Atom Core</p> <h3 dir="auto">Stack Trace</h3> <p dir="auto">Uncaught Error: Cannot find module './context-menu'<br> Error: Cannot find module './context-menu'<br> at Function.Module._resolveFilename (module.js:328:15)<br> at Function.Module._load (module.js:270:25)<br> at Module.require (module.js:357:17)<br> at require (module.js:376:17)<br> at BrowserWindow. (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\src\browser\atom-window.js:152:27)<br> at emitOne (events.js:77:13)<br> at BrowserWindow.emit (events.js:166:7)<br> at callFunction (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\browser\lib\rpc-server.js:116:18)<br> at EventEmitter. (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\browser\lib\rpc-server.js:208:14)<br> at emitMany (events.js:108:13)</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="At C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\renderer\api\lib\remote.js:77 Error: Cannot find module './context-menu' Error: Cannot find module './context-menu' at Function.Module._resolveFilename (module.js:328:15) at Function.Module._load (module.js:270:25) at Module.require (module.js:357:17) at require (module.js:376:17) at BrowserWindow.&lt;anonymous&gt; (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\src\browser\atom-window.js:152:27) at emitOne (events.js:77:13) at BrowserWindow.emit (events.js:166:7) at callFunction (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\browser\lib\rpc-server.js:116:18) at EventEmitter.&lt;anonymous&gt; (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\browser\lib\rpc-server.js:208:14) at emitMany (events.js:108:13) at metaToValue (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\renderer\api\lib\remote.js:77:15) at BrowserWindow.RemoteMemberFunction [as emit] (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\renderer\api\lib\remote.js:111:26) at ContextMenuManager.module.exports.ContextMenuManager.showForEvent (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\src\context-menu-manager.js:170:31) at HTMLDocument.&lt;anonymous&gt; (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\src\window-event-handler.js:149:33) at HTMLDocument.handler (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\src\space-pen-extensions.js:112:34) at HTMLDocument.jQuery.event.dispatch (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\node_modules\space-pen\vendor\jquery.js:4681:9) at HTMLDocument.elemData.handle (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\node_modules\space-pen\vendor\jquery.js:4359:46) "><pre class="notranslate"><code class="notranslate">At C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\renderer\api\lib\remote.js:77 Error: Cannot find module './context-menu' Error: Cannot find module './context-menu' at Function.Module._resolveFilename (module.js:328:15) at Function.Module._load (module.js:270:25) at Module.require (module.js:357:17) at require (module.js:376:17) at BrowserWindow.&lt;anonymous&gt; (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\src\browser\atom-window.js:152:27) at emitOne (events.js:77:13) at BrowserWindow.emit (events.js:166:7) at callFunction (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\browser\lib\rpc-server.js:116:18) at EventEmitter.&lt;anonymous&gt; (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\browser\lib\rpc-server.js:208:14) at emitMany (events.js:108:13) at metaToValue (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\renderer\api\lib\remote.js:77:15) at BrowserWindow.RemoteMemberFunction [as emit] (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\atom.asar\renderer\api\lib\remote.js:111:26) at ContextMenuManager.module.exports.ContextMenuManager.showForEvent (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\src\context-menu-manager.js:170:31) at HTMLDocument.&lt;anonymous&gt; (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\src\window-event-handler.js:149:33) at HTMLDocument.handler (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\src\space-pen-extensions.js:112:34) at HTMLDocument.jQuery.event.dispatch (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\node_modules\space-pen\vendor\jquery.js:4681:9) at HTMLDocument.elemData.handle (C:\Users\jbrichardet\AppData\Local\atom\app-0.194.0\resources\app.asar\node_modules\space-pen\vendor\jquery.js:4359:46) </code></pre></div> <h3 dir="auto">Commands</h3> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" -4:55.5.0 editor:checkout-head-revision (atom-text-editor.editor.is-focused) 2x -3:41.6.0 window:focus-pane-on-right (atom-text-editor.editor) -3:17.5.0 application:add-project-folder (ol.tree-view.full-menu.list-tree.has-collapsable-children.focusable-panel) -2:47.4.0 editor:newline (atom-text-editor.editor.is-focused) -2:38.2.0 core:cut (atom-text-editor.editor) -2:36.5.0 core:paste (atom-text-editor.editor.is-focused) -2:26.6.0 core:save (atom-text-editor.editor.is-focused) -2:20.6.0 core:move-down (atom-text-editor.editor) -2:20.4.0 autocomplete-plus:confirm (atom-text-editor.editor) -2:15.8.0 core:save (atom-text-editor.editor) -2:08.7.0 core:copy (atom-text-editor.editor.is-focused) -2:01.2.0 core:paste (atom-text-editor.editor.is-focused) -1:59.7.0 core:save (atom-text-editor.editor.is-focused) -1:52.2.0 core:paste (atom-text-editor.editor.is-focused) -1:51.6.0 core:save (atom-text-editor.editor.is-focused) -1:30.6.0 core:backspace (atom-text-editor.editor)"><pre class="notranslate"><code class="notranslate"> -4:55.5.0 editor:checkout-head-revision (atom-text-editor.editor.is-focused) 2x -3:41.6.0 window:focus-pane-on-right (atom-text-editor.editor) -3:17.5.0 application:add-project-folder (ol.tree-view.full-menu.list-tree.has-collapsable-children.focusable-panel) -2:47.4.0 editor:newline (atom-text-editor.editor.is-focused) -2:38.2.0 core:cut (atom-text-editor.editor) -2:36.5.0 core:paste (atom-text-editor.editor.is-focused) -2:26.6.0 core:save (atom-text-editor.editor.is-focused) -2:20.6.0 core:move-down (atom-text-editor.editor) -2:20.4.0 autocomplete-plus:confirm (atom-text-editor.editor) -2:15.8.0 core:save (atom-text-editor.editor) -2:08.7.0 core:copy (atom-text-editor.editor.is-focused) -2:01.2.0 core:paste (atom-text-editor.editor.is-focused) -1:59.7.0 core:save (atom-text-editor.editor.is-focused) -1:52.2.0 core:paste (atom-text-editor.editor.is-focused) -1:51.6.0 core:save (atom-text-editor.editor.is-focused) -1:30.6.0 core:backspace (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;node_modules&quot; ], &quot;themes&quot;: [ &quot;atom-dark-ui&quot;, &quot;seti-syntax&quot; ], &quot;disabledPackages&quot;: [ &quot;Tern&quot; ], &quot;projectHome&quot;: &quot;Y:\\app-tfoumax&quot; }, &quot;editor&quot;: { &quot;invisibles&quot;: {}, &quot;softWrap&quot;: true, &quot;showIndentGuide&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>node_modules<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>seti-syntax<span class="pl-pds">"</span></span> ], <span class="pl-ent">"disabledPackages"</span>: [ <span class="pl-s"><span class="pl-pds">"</span>Tern<span class="pl-pds">"</span></span> ], <span class="pl-ent">"projectHome"</span>: <span class="pl-s"><span class="pl-pds">"</span>Y:<span class="pl-cce">\\</span>app-tfoumax<span class="pl-pds">"</span></span> }, <span class="pl-ent">"editor"</span>: { <span class="pl-ent">"invisibles"</span>: {}, <span class="pl-ent">"softWrap"</span>: <span class="pl-c1">true</span>, <span class="pl-ent">"showIndentGuide"</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 autocomplete-plus, v2.12.0 autocomplete-snippets, v1.2.0 javascript-snippets, v1.0.0 jshint, v1.3.5 language-ejs, v0.1.0 linter, v0.12.1 pretty-json, v0.3.3 save-session, v0.14.0 Search, v0.4.0 seti-syntax, v0.4.0 # Dev No dev packages"><pre class="notranslate"><span class="pl-c"><span class="pl-c">#</span> User</span> autocomplete<span class="pl-k">-</span>plus, v2.<span class="pl-ii">12</span>.<span class="pl-ii">0</span> autocomplete<span class="pl-k">-</span>snippets, v1.<span class="pl-ii">2</span>.<span class="pl-ii">0</span> javascript<span class="pl-k">-</span>snippets, v1.<span class="pl-ii">0</span>.<span class="pl-ii">0</span> jshint, v1.<span class="pl-ii">3</span>.<span class="pl-ii">5</span> language<span class="pl-k">-</span>ejs, v0.<span class="pl-ii">1</span>.<span class="pl-ii">0</span> linter, v0.<span class="pl-ii">12</span>.<span class="pl-ii">1</span> pretty<span class="pl-k">-</span>json, v0.<span class="pl-ii">3</span>.<span class="pl-ii">3</span> save<span class="pl-k">-</span>session, v0.<span class="pl-ii">14</span>.<span class="pl-ii">0</span> Search, v0.<span class="pl-ii">4</span>.<span class="pl-ii">0</span> seti<span class="pl-k">-</span>syntax, v0.<span class="pl-ii">4</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"><strong><a href="https://jira.spring.io/secure/ViewProfile.jspa?name=costin" rel="nofollow">Costin Leau</a></strong> opened <strong><a href="https://jira.spring.io/browse/SPR-5401?redirect=false" rel="nofollow">SPR-5401</a></strong> and commented</p> <p dir="auto">Reported at:<br> <a href="http://forum.springframework.org/showthread.php?t=59567" rel="nofollow">http://forum.springframework.org/showthread.php?t=59567</a><br> <a href="http://forum.springframework.org/showthread.php?t=65205" rel="nofollow">http://forum.springframework.org/showthread.php?t=65205</a></p> <p dir="auto">"The aspect "org.springframework.beans.factory.aspectj.Annotat ionBeanConfigurerAspect" is instantiated only once as singleton. Spring calls the setter for the Beanfactory property of the Aspect for each ApplicationContext with context:spring-configured entry. The last one who gets initialized wins. The Beans from the others Contexts can't get initialized."</p> <hr> <p dir="auto"><strong>Affects:</strong> 2.5.5</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="398090953" data-permission-text="Title is private" data-url="https://github.com/spring-projects/spring-framework/issues/9829" data-hovercard-type="issue" data-hovercard-url="/spring-projects/spring-framework/issues/9829/hovercard" href="https://github.com/spring-projects/spring-framework/issues/9829">#9829</a> Support use of <code class="notranslate">@Configurable</code> mechanism across multiple OSGi bundles (<em><strong>"duplicates"</strong></em>)</li> <li><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="398090953" data-permission-text="Title is private" data-url="https://github.com/spring-projects/spring-framework/issues/9829" data-hovercard-type="issue" data-hovercard-url="/spring-projects/spring-framework/issues/9829/hovercard" href="https://github.com/spring-projects/spring-framework/issues/9829">#9829</a> Support use of <code class="notranslate">@Configurable</code> mechanism across multiple OSGi bundles (<em><strong>"is duplicated by"</strong></em>)</li> </ul> <p dir="auto">5 votes, 7 watchers</p>
<p dir="auto"><strong><a href="https://jira.spring.io/secure/ViewProfile.jspa?name=avatah" rel="nofollow">Wojciech Durczyński</a></strong> opened <strong><a href="https://jira.spring.io/browse/SPR-5156?redirect=false" rel="nofollow">SPR-5156</a></strong> and commented</p> <p dir="auto">In OSGI <code class="notranslate">@Configurable</code> mechanism works well only when used in one bundle.<br> If there is &lt;context:spring-configured /&gt; in application contexts of more then one bundle, the AnnotationBeanConfigurerAspect (single instance) is injected with two different BeanConfigurerSupport objects in non deterministic order.<br> Bundle whose BeanFactory is injected to aspect most recently works well - others don't work at all.</p> <p dir="auto">Is there any work around for this problem?</p> <hr> <p dir="auto"><strong>Affects:</strong> 2.5.5</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="398092675" data-permission-text="Title is private" data-url="https://github.com/spring-projects/spring-framework/issues/10074" data-hovercard-type="issue" data-hovercard-url="/spring-projects/spring-framework/issues/10074/hovercard" href="https://github.com/spring-projects/spring-framework/issues/10074">#10074</a> AnnotationBeanConfigurerAspect is created as a singleton and cannot be shared across multiple contexts (<em><strong>"duplicates"</strong></em>)</li> <li><a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="398092675" data-permission-text="Title is private" data-url="https://github.com/spring-projects/spring-framework/issues/10074" data-hovercard-type="issue" data-hovercard-url="/spring-projects/spring-framework/issues/10074/hovercard" href="https://github.com/spring-projects/spring-framework/issues/10074">#10074</a> AnnotationBeanConfigurerAspect is created as a singleton and cannot be shared across multiple contexts (<em><strong>"is duplicated by"</strong></em>)</li> </ul> <p dir="auto">15 votes, 20 watchers</p>
1
<p dir="auto"><strong>I'm submitting a ...</strong></p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="[x] bug report [ ] feature request [ ] support request"><pre class="notranslate"><code class="notranslate">[x] bug report [ ] feature request [ ] support request </code></pre></div> <p dir="auto"><strong>Current behavior</strong><br> In rc4, you could use the safe navigation/Elvis operator (?.) to guard against nulls in property paths when using the async pipe - don't seem to be able to in rc5.</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="// Inside a template in rc5 - Assuming Observable var data which (will have) an id property: {{(data | async)?.id}} // throws error : TypeError: Cannot read property 'id' of null"><pre class="notranslate"><code class="notranslate">// Inside a template in rc5 - Assuming Observable var data which (will have) an id property: {{(data | async)?.id}} // throws error : TypeError: Cannot read property 'id' of null </code></pre></div> <p dir="auto"><strong>Expected/desired behavior</strong><br> As per rc4:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" {{(data | async)?.id}} // works as expected - id displays when data loaded"><pre class="notranslate"><code class="notranslate"> {{(data | async)?.id}} // works as expected - id displays when data loaded </code></pre></div> <p dir="auto"><strong>Reproduction of the problem</strong><br> rc4 - working as expected:<br> <a href="http://plnkr.co/edit/m9UJEwB4ZSNhIb77A2aI?p=preview" rel="nofollow">http://plnkr.co/edit/m9UJEwB4ZSNhIb77A2aI?p=preview</a></p> <p dir="auto">rc5 - not working/throwing error:<br> <a href="http://plnkr.co/edit/QQlg8nKJqVR8DqB2SiTw?p=preview" rel="nofollow">http://plnkr.co/edit/QQlg8nKJqVR8DqB2SiTw?p=preview</a></p> <p dir="auto"><strong>What is the expected behavior?</strong><br> Accessing properties of (currently) null values not to throw an error - the Elvis operator would ideally guard against the error...</p> <p dir="auto"><strong>Please tell us about your environment:</strong></p> <ul dir="auto"> <li><strong>Angular version:</strong> 2.0.0-rc.5</li> <li><strong>Browser:</strong> [all]</li> <li><strong>Language:</strong> [all]</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"><pre class="notranslate"><code class="notranslate">[ ] bug report =&gt; search github for a similar issue or PR before submitting [x] feature request </code></pre></div> <p dir="auto"><strong>Current behavior</strong><br> Cannot apply a pipe to the display value of an input field.</p> <p dir="auto"><strong>Desired behavior</strong><br> I'd like to be able to apply a pipe to the display value of an input. Suppose I have a pipe which converts a whole number of cents into dollars and adds a dollar sign, e.g., "110" =&gt; "$1.10". As a user is typing, I'd like to apply the pipe to the displayed value while the value of the input field remains 110, i.e., only apply the pipe to the display of the field's value.</p> <p dir="auto">Here's a Plnkr which shows the input field and the value of the input run through the pipe. I'd like the actual displayed value in the input field to look like content below the input field.</p> <p dir="auto"><a href="http://plnkr.co/edit/NgNoxQ2GTUYKmEYjnYAh?p=preview" rel="nofollow">http://plnkr.co/edit/NgNoxQ2GTUYKmEYjnYAh?p=preview</a></p> <p dir="auto">And here's my SO question about this feature, demonstrated in Angular Material:</p> <p dir="auto"><a href="http://stackoverflow.com/questions/40855106/transform-md-input-value-via-pipe" rel="nofollow">http://stackoverflow.com/questions/40855106/transform-md-input-value-via-pipe</a></p> <p dir="auto"><strong>What is the motivation / use case for changing the behavior?</strong><br> This specific scenario is a common use-case in finance-related applications but the scenario is general, date formats, etc.</p> <p dir="auto"><strong>Please tell us about your environment:</strong></p> <p dir="auto">OpenSUSE 13.2 Linux, Emacs, ... N/A</p> <ul dir="auto"> <li> <p dir="auto"><strong>Angular version:</strong> 2.0.X<br> 2.x</p> </li> <li> <p dir="auto"><strong>Browser:</strong> [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]<br> All</p> </li> <li> <p dir="auto"><strong>Language:</strong> [all | TypeScript X.X | ES6/7 | ES5]<br> All</p> </li> <li> <p dir="auto"><strong>Node (for AoT issues):</strong> <code class="notranslate">node --version</code> =</p> </li> </ul>
0
<p dir="auto">Just saw a Flutter demo which showed off the Performance Overlay in the Android Emulator. While it works, it's not showing representative data. :)</p> <p dir="auto">We should make it very obvious in the tool that the data there isn't useful.</p> <p dir="auto"><a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/chinmaygarde/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/chinmaygarde">@chinmaygarde</a></p>
<p dir="auto">Add the following to a <code class="notranslate">flutter create</code> template app:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content=" print(&quot;counter: ${_counter}&quot;); print(&quot;foo&quot;);"><pre class="notranslate"><code class="notranslate"> print("counter: ${_counter}"); print("foo"); </code></pre></div> <p dir="auto">In the setState call where the counter in incremented.</p> <p dir="auto">You'll notice sometimes the logs come out twice:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="counter: 15 counter: 15 foo counter: 16 foo counter: 17 foo counter: 18 foo counter: 19 foo counter: 20 foo counter: 21 foo counter: 21 foo"><pre class="notranslate"><code class="notranslate">counter: 15 counter: 15 foo counter: 16 foo counter: 17 foo counter: 18 foo counter: 19 foo counter: 20 foo counter: 21 foo counter: 21 foo </code></pre></div> <p dir="auto"><a class="user-mention notranslate" data-hovercard-type="user" data-hovercard-url="/users/lukef/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/lukef">@lukef</a> was seeing this as well</p>
0
<p dir="auto">by <strong>awreece</strong>:</p> <pre class="notranslate">If a thread is blocked on udpConn.ReadFrom, udpConn.Close() does not wake it up. Consider the following: func TestCloseUdp(t *testing.T) { iroutines := runtime.Goroutines() conn, _ := net.ListenPacket("udp", ":6666") go func() { var buf [100]byte conn.ReadFrom(buf[:]) }() conn.Close() // 16 minutes seems like long enough time for every other thread to block or die. time.Sleep(1e12) if nroutines := runtime.Goroutines(); iroutines != nroutines { msg := fmt.Sprint("Leaked threads: was ", nroutines, " but expected ", iroutines) panic(msg) } } Which produces the unexpected output: panic: Leaked threads: was 4 but expected 2 goroutine 41 [running]: main.TestCloseUdp() ~/net_test.go:199 +0x291 testing.tRunner(0x187175d0, 0x82797cc, 0x0) $GOROOT/src/pkg/testing/testing.go:156 +0x39 created by testing.RunTests $GOROOT/src/pkg/testing/testing.go:200 +0x511 goroutine 1 [chan receive]: testing.RunTests(0x8048c00, 0x82796e8, 0x26) $GOROOT/src/pkg/testing/testing.go:201 +0x53f testing.Main(0x8048c00, 0x82796e8, 0x26, 0x26, 0x8282f30, ...) $GOROOT/src/pkg/testing/testing.go:168 +0x49 main.main() ~/_test/_testmain.go:32 +0x43 goroutine 43 [chan receive]: net.(*pollServer).WaitRead(0x1874ef30, 0x1870e680, 0x64) $GOROOT/src/pkg/net/fd.go:257 +0x5c net.(*netFD).ReadFrom(0x1870e680, 0x187e4070, 0x64, 0x64, 0xffffffff, ...) $GOROOT/src/pkg/net/fd.go:417 +0x299 net.(*UDPConn).ReadFromUDP(0x187780e0, 0x187e4070, 0x64, 0x64, 0x0, ...) $GOROOT/src/pkg/net/udpsock_posix.go:156 +0xb9 net.(*UDPConn).ReadFrom(0x187780e0, 0x187e4070, 0x64, 0x64, 0x0, ...) $GOROOT/src/pkg/net/udpsock_posix.go:171 +0x84 main._func_015(0x187780a0, 0x187789e8) ~/net_test.go:191 +0xbd created by main.TestCloseUdp ~/net_test.go:192 +0x91 goroutine 42 [syscall]: syscall.Syscall6() $GOROOT/src/pkg/syscall/asm_linux_386.s:46 +0x27 syscall.EpollWait(0x6, 0x18792148, 0xa, 0xa, 0xffffffff, ...) $GOROOT/src/pkg/syscall/zsyscall_linux_386.go:200 +0x9d net.(*pollster).WaitFD(0x18792140, 0x1874ef30, 0x0, 0x0, 0x0, ...) $GOROOT/src/pkg/net/fd_linux.go:141 +0x1b6 net.(*pollServer).Run(0x1874ef30, 0x18700dc0) $GOROOT/src/pkg/net/fd.go:228 +0x146 created by net.newPollServer $GOROOT/src/pkg/net/newpollserver.go:36 +0x464 gb error: [_test/_testmain]: exit status 2 Which compiler are you using (5g, 6g, 8g, gccgo)? 8g Which operating system are you using? Linux Which revision are you using? (hg identify) 253f02222ab0 tip</pre>
<p dir="auto">by <strong><a href="mailto:[email protected]">[email protected]</a></strong>:</p> <pre class="notranslate">It is supposed that every function in package os is platform-independentand and work in every system, but os.Symlink has not been implemented in Windows. Symbolic Links <a href="http://msdn.microsoft.com/en-us/library/windows/desktop/aa365680.aspx" rel="nofollow">http://msdn.microsoft.com/en-us/library/windows/desktop/aa365680.aspx</a> Related to: <a href="https://groups.google.com/forum/#" rel="nofollow">https://groups.google.com/forum/#</a>!topic/golang-nuts/fSjM8aga_6Y</pre>
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" 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="&gt;&gt;&gt; import jax.numpy as jnp &gt;&gt;&gt; a = jnp.zeros((10, 100)) &gt;&gt;&gt; type(a) jaxlib.xla_extension.DeviceArray"><pre class="notranslate"><span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-k">import</span> <span class="pl-s1">jax</span>.<span class="pl-s1">numpy</span> <span class="pl-k">as</span> <span class="pl-s1">jnp</span> <span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-s1">a</span> <span class="pl-c1">=</span> <span class="pl-s1">jnp</span>.<span class="pl-en">zeros</span>((<span class="pl-c1">10</span>, <span class="pl-c1">100</span>)) <span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-en">type</span>(<span class="pl-s1">a</span>) <span class="pl-s1">jaxlib</span>.<span class="pl-s1">xla_extension</span>.<span class="pl-v">DeviceArray</span></pre></div> <p dir="auto">The indexing of the DeviceArray is right:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" &gt;&gt;&gt; print(type(a[0])) jaxlib.xla_extension.DeviceArray "><pre class="notranslate"><span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-en">print</span>(<span class="pl-en">type</span>(<span class="pl-s1">a</span>[<span class="pl-c1">0</span>])) <span class="pl-s1">jaxlib</span>.<span class="pl-s1">xla_extension</span>.<span class="pl-v">DeviceArray</span></pre></div> <p dir="auto">However, <code class="notranslate">iter</code> this DeviceArray get <code class="notranslate">numpy.ndarray</code>:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content=" &gt;&gt;&gt; for b in a: print(type(b)) &lt;class 'numpy.ndarray'&gt; &lt;class 'numpy.ndarray'&gt; &lt;class 'numpy.ndarray'&gt; &lt;class 'numpy.ndarray'&gt; &lt;class 'numpy.ndarray'&gt; &lt;class 'numpy.ndarray'&gt; &lt;class 'numpy.ndarray'&gt; &lt;class 'numpy.ndarray'&gt; &lt;class 'numpy.ndarray'&gt; &lt;class 'numpy.ndarray'&gt;"><pre class="notranslate"><span class="pl-c1">&gt;&gt;</span><span class="pl-c1">&gt;</span> <span class="pl-k">for</span> <span class="pl-s1">b</span> <span class="pl-c1">in</span> <span class="pl-s1">a</span>: <span class="pl-en">print</span>(<span class="pl-en">type</span>(<span class="pl-s1">b</span>)) <span class="pl-c1">&lt;</span><span class="pl-k">class</span> <span class="pl-s">'numpy.ndarray'</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-k">class</span> <span class="pl-s">'numpy.ndarray'</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-k">class</span> <span class="pl-s">'numpy.ndarray'</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-k">class</span> <span class="pl-s">'numpy.ndarray'</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-k">class</span> <span class="pl-s">'numpy.ndarray'</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-k">class</span> <span class="pl-s">'numpy.ndarray'</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-k">class</span> <span class="pl-s">'numpy.ndarray'</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-k">class</span> <span class="pl-s">'numpy.ndarray'</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-k">class</span> <span class="pl-s">'numpy.ndarray'</span><span class="pl-c1">&gt;</span> <span class="pl-c1">&lt;</span><span class="pl-k">class</span> <span class="pl-s">'numpy.ndarray'</span><span class="pl-c1">&gt;</span></pre></div>
<p dir="auto">I noticed that when I re-ordered the matrix multiplication order, the numerical stabilities can vary wildly (4 orders of magnitude). Further, even with the same seed, whether an operation is numerically stable can vary (significantly) between runs.</p> <p dir="auto">The following were observed when running on an A6000 GPU. However, this appears fine when running on CPU, V100, or Google Colab (K80).</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="import jax # jax.config.update(&quot;jax_platform_name&quot;, &quot;cpu&quot;) import numpy as np import jax.numpy as jnp d = 97 for r in range(20, 40): key = jax.random.PRNGKey(r) key, subkey = jax.random.split(key) a = jax.random.normal(key) key, subkey = jax.random.split(key) D = jax.random.normal(key, shape=[d, r]) key, subkey = jax.random.split(key) v = jax.random.normal(key, shape=[d]) diff = (D @ (D.T @ v) - D @ D.T @ v) print( f&quot;Rank={r}: &quot; f&quot;a: {a:.3f}, \t&quot; f&quot;D(norm) {jnp.linalg.norm(D):.3f}, \t&quot; f&quot;v(norm) {jnp.linalg.norm(v):.2f}, \t&quot; f&quot;Error: {jnp.linalg.norm(diff):.3e}&quot;)"><pre class="notranslate"><span class="pl-k">import</span> <span class="pl-s1">jax</span> <span class="pl-c"># jax.config.update("jax_platform_name", "cpu")</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">jax</span>.<span class="pl-s1">numpy</span> <span class="pl-k">as</span> <span class="pl-s1">jnp</span> <span class="pl-s1">d</span> <span class="pl-c1">=</span> <span class="pl-c1">97</span> <span class="pl-k">for</span> <span class="pl-s1">r</span> <span class="pl-c1">in</span> <span class="pl-en">range</span>(<span class="pl-c1">20</span>, <span class="pl-c1">40</span>): <span class="pl-s1">key</span> <span class="pl-c1">=</span> <span class="pl-s1">jax</span>.<span class="pl-s1">random</span>.<span class="pl-v">PRNGKey</span>(<span class="pl-s1">r</span>) <span class="pl-s1">key</span>, <span class="pl-s1">subkey</span> <span class="pl-c1">=</span> <span class="pl-s1">jax</span>.<span class="pl-s1">random</span>.<span class="pl-en">split</span>(<span class="pl-s1">key</span>) <span class="pl-s1">a</span> <span class="pl-c1">=</span> <span class="pl-s1">jax</span>.<span class="pl-s1">random</span>.<span class="pl-en">normal</span>(<span class="pl-s1">key</span>) <span class="pl-s1">key</span>, <span class="pl-s1">subkey</span> <span class="pl-c1">=</span> <span class="pl-s1">jax</span>.<span class="pl-s1">random</span>.<span class="pl-en">split</span>(<span class="pl-s1">key</span>) <span class="pl-v">D</span> <span class="pl-c1">=</span> <span class="pl-s1">jax</span>.<span class="pl-s1">random</span>.<span class="pl-en">normal</span>(<span class="pl-s1">key</span>, <span class="pl-s1">shape</span><span class="pl-c1">=</span>[<span class="pl-s1">d</span>, <span class="pl-s1">r</span>]) <span class="pl-s1">key</span>, <span class="pl-s1">subkey</span> <span class="pl-c1">=</span> <span class="pl-s1">jax</span>.<span class="pl-s1">random</span>.<span class="pl-en">split</span>(<span class="pl-s1">key</span>) <span class="pl-s1">v</span> <span class="pl-c1">=</span> <span class="pl-s1">jax</span>.<span class="pl-s1">random</span>.<span class="pl-en">normal</span>(<span class="pl-s1">key</span>, <span class="pl-s1">shape</span><span class="pl-c1">=</span>[<span class="pl-s1">d</span>]) <span class="pl-s1">diff</span> <span class="pl-c1">=</span> (<span class="pl-v">D</span> @ (<span class="pl-v">D</span>.<span class="pl-v">T</span> @ <span class="pl-s1">v</span>) <span class="pl-c1">-</span> <span class="pl-v">D</span> @ <span class="pl-v">D</span>.<span class="pl-v">T</span> @ <span class="pl-s1">v</span>) <span class="pl-en">print</span>( <span class="pl-s">f"Rank=<span class="pl-s1"><span class="pl-kos">{</span><span class="pl-s1">r</span><span class="pl-kos">}</span></span>: "</span> <span class="pl-s">f"a: <span class="pl-s1"><span class="pl-kos">{</span><span class="pl-s1">a</span>:.3f<span class="pl-kos">}</span></span>, <span class="pl-cce">\t</span>"</span> <span class="pl-s">f"D(norm) <span class="pl-s1"><span class="pl-kos">{</span><span class="pl-s1">jnp</span>.<span class="pl-s1">linalg</span>.<span class="pl-en">norm</span>(<span class="pl-v">D</span>):.3f<span class="pl-kos">}</span></span>, <span class="pl-cce">\t</span>"</span> <span class="pl-s">f"v(norm) <span class="pl-s1"><span class="pl-kos">{</span><span class="pl-s1">jnp</span>.<span class="pl-s1">linalg</span>.<span class="pl-en">norm</span>(<span class="pl-s1">v</span>):.2f<span class="pl-kos">}</span></span>, <span class="pl-cce">\t</span>"</span> <span class="pl-s">f"Error: <span class="pl-s1"><span class="pl-kos">{</span><span class="pl-s1">jnp</span>.<span class="pl-s1">linalg</span>.<span class="pl-en">norm</span>(<span class="pl-s1">diff</span>):.3e<span class="pl-kos">}</span></span>"</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.</li> </ul> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="# Output from Run 1 Rank=20: a: 0.753, D(norm) 43.465, v(norm) 10.75, Error: 1.057e-01 &lt;--- Rank=21: a: 0.963, D(norm) 44.669, v(norm) 9.45, Error: 6.323e-05 Rank=22: a: 0.269, D(norm) 46.610, v(norm) 10.44, Error: 8.321e-05 Rank=23: a: -0.232, D(norm) 47.038, v(norm) 10.07, Error: 7.781e-05 Rank=24: a: -1.412, D(norm) 48.142, v(norm) 10.59, Error: 8.764e-05 Rank=25: a: 0.038, D(norm) 48.904, v(norm) 8.98, Error: 7.407e-05 Rank=26: a: -0.816, D(norm) 49.992, v(norm) 10.28, Error: 9.853e-05 Rank=27: a: 1.559, D(norm) 51.330, v(norm) 10.49, Error: 6.900e-05 Rank=28: a: 0.204, D(norm) 52.076, v(norm) 9.70, Error: 8.498e-05 Rank=29: a: -0.143, D(norm) 52.809, v(norm) 10.20, Error: 9.320e-05 Rank=30: a: 0.024, D(norm) 53.732, v(norm) 9.13, Error: 8.484e-05 Rank=31: a: 0.889, D(norm) 55.202, v(norm) 10.40, Error: 9.107e-05 Rank=32: a: 0.427, D(norm) 56.583, v(norm) 10.34, Error: 8.759e-05 Rank=33: a: 0.398, D(norm) 57.486, v(norm) 10.12, Error: 8.744e-05 Rank=34: a: -1.186, D(norm) 56.714, v(norm) 9.43, Error: 8.845e-05 Rank=35: a: -0.012, D(norm) 58.444, v(norm) 9.27, Error: 1.707e-01 &lt;--- Rank=36: a: 0.712, D(norm) 58.687, v(norm) 9.36, Error: 7.037e-05 Rank=37: a: -0.177, D(norm) 60.725, v(norm) 9.32, Error: 8.887e-05 Rank=38: a: 0.247, D(norm) 61.139, v(norm) 10.34, Error: 8.436e-05 Rank=39: a: -1.059, D(norm) 62.312, v(norm) 9.58, Error: 9.310e-05"><pre class="notranslate"><code class="notranslate"># Output from Run 1 Rank=20: a: 0.753, D(norm) 43.465, v(norm) 10.75, Error: 1.057e-01 &lt;--- Rank=21: a: 0.963, D(norm) 44.669, v(norm) 9.45, Error: 6.323e-05 Rank=22: a: 0.269, D(norm) 46.610, v(norm) 10.44, Error: 8.321e-05 Rank=23: a: -0.232, D(norm) 47.038, v(norm) 10.07, Error: 7.781e-05 Rank=24: a: -1.412, D(norm) 48.142, v(norm) 10.59, Error: 8.764e-05 Rank=25: a: 0.038, D(norm) 48.904, v(norm) 8.98, Error: 7.407e-05 Rank=26: a: -0.816, D(norm) 49.992, v(norm) 10.28, Error: 9.853e-05 Rank=27: a: 1.559, D(norm) 51.330, v(norm) 10.49, Error: 6.900e-05 Rank=28: a: 0.204, D(norm) 52.076, v(norm) 9.70, Error: 8.498e-05 Rank=29: a: -0.143, D(norm) 52.809, v(norm) 10.20, Error: 9.320e-05 Rank=30: a: 0.024, D(norm) 53.732, v(norm) 9.13, Error: 8.484e-05 Rank=31: a: 0.889, D(norm) 55.202, v(norm) 10.40, Error: 9.107e-05 Rank=32: a: 0.427, D(norm) 56.583, v(norm) 10.34, Error: 8.759e-05 Rank=33: a: 0.398, D(norm) 57.486, v(norm) 10.12, Error: 8.744e-05 Rank=34: a: -1.186, D(norm) 56.714, v(norm) 9.43, Error: 8.845e-05 Rank=35: a: -0.012, D(norm) 58.444, v(norm) 9.27, Error: 1.707e-01 &lt;--- Rank=36: a: 0.712, D(norm) 58.687, v(norm) 9.36, Error: 7.037e-05 Rank=37: a: -0.177, D(norm) 60.725, v(norm) 9.32, Error: 8.887e-05 Rank=38: a: 0.247, D(norm) 61.139, v(norm) 10.34, Error: 8.436e-05 Rank=39: a: -1.059, D(norm) 62.312, v(norm) 9.58, Error: 9.310e-05 </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="# Output from another Run Rank=20: a: 0.753, D(norm) 43.465, v(norm) 10.75, Error: 1.057e-01 &lt;--- Rank=21: a: 0.963, D(norm) 44.669, v(norm) 9.45, Error: 6.323e-05 Rank=22: a: 0.269, D(norm) 46.610, v(norm) 10.44, Error: 8.321e-05 Rank=23: a: -0.232, D(norm) 47.038, v(norm) 10.07, Error: 7.781e-05 Rank=24: a: -1.412, D(norm) 48.142, v(norm) 10.59, Error: 8.764e-05 Rank=25: a: 0.038, D(norm) 48.904, v(norm) 8.98, Error: 7.407e-05 Rank=26: a: -0.816, D(norm) 49.992, v(norm) 10.28, Error: 9.853e-05 Rank=27: a: 1.559, D(norm) 51.330, v(norm) 10.49, Error: 6.900e-05 Rank=28: a: 0.204, D(norm) 52.076, v(norm) 9.70, Error: 1.292e-01 &lt;--- Rank=29: a: -0.143, D(norm) 52.809, v(norm) 10.20, Error: 9.320e-05 Rank=30: a: 0.024, D(norm) 53.732, v(norm) 9.13, Error: 8.484e-05 Rank=31: a: 0.889, D(norm) 55.202, v(norm) 10.40, Error: 9.107e-05 Rank=32: a: 0.427, D(norm) 56.583, v(norm) 10.34, Error: 8.759e-05 Rank=33: a: 0.398, D(norm) 57.486, v(norm) 10.12, Error: 1.684e-01 &lt;--- Rank=34: a: -1.186, D(norm) 56.714, v(norm) 9.43, Error: 8.845e-05 Rank=35: a: -0.012, D(norm) 58.444, v(norm) 9.27, Error: 7.667e-05 Rank=36: a: 0.712, D(norm) 58.687, v(norm) 9.36, Error: 7.037e-05 Rank=37: a: -0.177, D(norm) 60.725, v(norm) 9.32, Error: 8.887e-05 Rank=38: a: 0.247, D(norm) 61.139, v(norm) 10.34, Error: 8.436e-05 Rank=39: a: -1.059, D(norm) 62.312, v(norm) 9.58, Error: 9.310e-05"><pre class="notranslate"><code class="notranslate"># Output from another Run Rank=20: a: 0.753, D(norm) 43.465, v(norm) 10.75, Error: 1.057e-01 &lt;--- Rank=21: a: 0.963, D(norm) 44.669, v(norm) 9.45, Error: 6.323e-05 Rank=22: a: 0.269, D(norm) 46.610, v(norm) 10.44, Error: 8.321e-05 Rank=23: a: -0.232, D(norm) 47.038, v(norm) 10.07, Error: 7.781e-05 Rank=24: a: -1.412, D(norm) 48.142, v(norm) 10.59, Error: 8.764e-05 Rank=25: a: 0.038, D(norm) 48.904, v(norm) 8.98, Error: 7.407e-05 Rank=26: a: -0.816, D(norm) 49.992, v(norm) 10.28, Error: 9.853e-05 Rank=27: a: 1.559, D(norm) 51.330, v(norm) 10.49, Error: 6.900e-05 Rank=28: a: 0.204, D(norm) 52.076, v(norm) 9.70, Error: 1.292e-01 &lt;--- Rank=29: a: -0.143, D(norm) 52.809, v(norm) 10.20, Error: 9.320e-05 Rank=30: a: 0.024, D(norm) 53.732, v(norm) 9.13, Error: 8.484e-05 Rank=31: a: 0.889, D(norm) 55.202, v(norm) 10.40, Error: 9.107e-05 Rank=32: a: 0.427, D(norm) 56.583, v(norm) 10.34, Error: 8.759e-05 Rank=33: a: 0.398, D(norm) 57.486, v(norm) 10.12, Error: 1.684e-01 &lt;--- Rank=34: a: -1.186, D(norm) 56.714, v(norm) 9.43, Error: 8.845e-05 Rank=35: a: -0.012, D(norm) 58.444, v(norm) 9.27, Error: 7.667e-05 Rank=36: a: 0.712, D(norm) 58.687, v(norm) 9.36, Error: 7.037e-05 Rank=37: a: -0.177, D(norm) 60.725, v(norm) 9.32, Error: 8.887e-05 Rank=38: a: 0.247, D(norm) 61.139, v(norm) 10.34, Error: 8.436e-05 Rank=39: a: -1.059, D(norm) 62.312, v(norm) 9.58, Error: 9.310e-05 </code></pre></div> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="# Output from another Run Rank=20: a: 0.753, D(norm) 43.465, v(norm) 10.75, Error: 1.057e-01 &lt;--- Rank=21: a: 0.963, D(norm) 44.669, v(norm) 9.45, Error: 6.323e-05 Rank=22: a: 0.269, D(norm) 46.610, v(norm) 10.44, Error: 8.321e-05 Rank=23: a: -0.232, D(norm) 47.038, v(norm) 10.07, Error: 7.781e-05 Rank=24: a: -1.412, D(norm) 48.142, v(norm) 10.59, Error: 1.489e-01 &lt;--- Rank=25: a: 0.038, D(norm) 48.904, v(norm) 8.98, Error: 7.407e-05 Rank=26: a: -0.816, D(norm) 49.992, v(norm) 10.28, Error: 9.853e-05 Rank=27: a: 1.559, D(norm) 51.330, v(norm) 10.49, Error: 6.900e-05 Rank=28: a: 0.204, D(norm) 52.076, v(norm) 9.70, Error: 8.498e-05 Rank=29: a: -0.143, D(norm) 52.809, v(norm) 10.20, Error: 9.320e-05 Rank=30: a: 0.024, D(norm) 53.732, v(norm) 9.13, Error: 8.484e-05 Rank=31: a: 0.889, D(norm) 55.202, v(norm) 10.40, Error: 9.107e-05 Rank=32: a: 0.427, D(norm) 56.583, v(norm) 10.34, Error: 8.759e-05 Rank=33: a: 0.398, D(norm) 57.486, v(norm) 10.12, Error: 8.744e-05 Rank=34: a: -1.186, D(norm) 56.714, v(norm) 9.43, Error: 8.845e-05 Rank=35: a: -0.012, D(norm) 58.444, v(norm) 9.27, Error: 7.667e-05 Rank=36: a: 0.712, D(norm) 58.687, v(norm) 9.36, Error: 7.037e-05 Rank=37: a: -0.177, D(norm) 60.725, v(norm) 9.32, Error: 8.887e-05 Rank=38: a: 0.247, D(norm) 61.139, v(norm) 10.34, Error: 8.436e-05 Rank=39: a: -1.059, D(norm) 62.312, v(norm) 9.58, Error: 9.310e-05"><pre class="notranslate"><code class="notranslate"># Output from another Run Rank=20: a: 0.753, D(norm) 43.465, v(norm) 10.75, Error: 1.057e-01 &lt;--- Rank=21: a: 0.963, D(norm) 44.669, v(norm) 9.45, Error: 6.323e-05 Rank=22: a: 0.269, D(norm) 46.610, v(norm) 10.44, Error: 8.321e-05 Rank=23: a: -0.232, D(norm) 47.038, v(norm) 10.07, Error: 7.781e-05 Rank=24: a: -1.412, D(norm) 48.142, v(norm) 10.59, Error: 1.489e-01 &lt;--- Rank=25: a: 0.038, D(norm) 48.904, v(norm) 8.98, Error: 7.407e-05 Rank=26: a: -0.816, D(norm) 49.992, v(norm) 10.28, Error: 9.853e-05 Rank=27: a: 1.559, D(norm) 51.330, v(norm) 10.49, Error: 6.900e-05 Rank=28: a: 0.204, D(norm) 52.076, v(norm) 9.70, Error: 8.498e-05 Rank=29: a: -0.143, D(norm) 52.809, v(norm) 10.20, Error: 9.320e-05 Rank=30: a: 0.024, D(norm) 53.732, v(norm) 9.13, Error: 8.484e-05 Rank=31: a: 0.889, D(norm) 55.202, v(norm) 10.40, Error: 9.107e-05 Rank=32: a: 0.427, D(norm) 56.583, v(norm) 10.34, Error: 8.759e-05 Rank=33: a: 0.398, D(norm) 57.486, v(norm) 10.12, Error: 8.744e-05 Rank=34: a: -1.186, D(norm) 56.714, v(norm) 9.43, Error: 8.845e-05 Rank=35: a: -0.012, D(norm) 58.444, v(norm) 9.27, Error: 7.667e-05 Rank=36: a: 0.712, D(norm) 58.687, v(norm) 9.36, Error: 7.037e-05 Rank=37: a: -0.177, D(norm) 60.725, v(norm) 9.32, Error: 8.887e-05 Rank=38: a: 0.247, D(norm) 61.139, v(norm) 10.34, Error: 8.436e-05 Rank=39: a: -1.059, D(norm) 62.312, v(norm) 9.58, Error: 9.310e-05 </code></pre></div>
0
<p dir="auto">I spent a little too much time trying to get the new <code class="notranslate">block</code> syntax in Go 1.6 implemented in <code class="notranslate">Hugo</code>, with no success.</p> <p dir="auto">Which is telling me that you should try to supply a "more real" example in the documentation.</p> <p dir="auto">Hugo uses the built-in associative transitive map to store its templates, so adding a new template is something like:</p> <div class="highlight highlight-source-go notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="hugoTemplates.New(&quot;homePage&quot;).Parse(someTemplate)"><pre class="notranslate"><span class="pl-s1">hugoTemplates</span>.<span class="pl-en">New</span>(<span class="pl-s">"homePage"</span>).<span class="pl-en">Parse</span>(<span class="pl-s1">someTemplate</span>)</pre></div> <p dir="auto">As I understand the new <code class="notranslate">block</code> implementation, one needs to first parse it with the master file (with the <code class="notranslate">block</code> keywords), then do a "overlay" (a modification, a re-parsing) of the same template with the template with the definitions.</p> <p dir="auto">How to do that with the above I cannot figure out (other than the simple standalone clone example in the doc -- I could clone it, but how do I replace the template in the map?).</p> <p dir="auto">My naive approach would be:</p> <div class="highlight highlight-source-go notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="m, _ := hugoTemplates.New(&quot;home&quot;).Parse(master) m.Parse(overlay)"><pre class="notranslate"><span class="pl-s1">m</span>, <span class="pl-s1">_</span> <span class="pl-c1">:=</span> <span class="pl-s1">hugoTemplates</span>.<span class="pl-en">New</span>(<span class="pl-s">"home"</span>).<span class="pl-en">Parse</span>(<span class="pl-s1">master</span>) <span class="pl-s1">m</span>.<span class="pl-en">Parse</span>(<span class="pl-s1">overlay</span>)</pre></div> <p dir="auto">And this works ... for the first template. Adding a second breaks in confusing ways.</p> <p dir="auto">Ref. <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="132423483" data-permission-text="Title is private" data-url="https://github.com/gohugoio/hugo/issues/1832" data-hovercard-type="issue" data-hovercard-url="/gohugoio/hugo/issues/1832/hovercard" href="https://github.com/gohugoio/hugo/issues/1832">gohugoio/hugo#1832</a></p> <p dir="auto">Also see <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="51281194" data-permission-text="Title is private" data-url="https://github.com/golang/go/issues/3812" data-hovercard-type="issue" data-hovercard-url="/golang/go/issues/3812/hovercard" href="https://github.com/golang/go/issues/3812">#3812</a></p>
<p dir="auto">x509.Certificate.CheckSignature does not support MD5 signatures. Is this intentional? If so, a comment should be added in the source and/or docs. If not, then please add support for MD5 signatures.</p> <p dir="auto">Code pointer: <a href="https://github.com/golang/go/blob/master/src/crypto/x509/x509.go#L621">https://github.com/golang/go/blob/master/src/crypto/x509/x509.go#L621</a></p>
0
<p dir="auto">I wanted to have two <code class="notranslate">pmap()</code>-ed function, piping one's output into another. For example, in the following way:</p> <div class="highlight highlight-source-python notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="for i, epoch in enumerate(tqdm(range(1, num_train_epochs + 1), desc=f&quot;Epoch ...&quot;, position=0, leave=True)): rng, input_rng = jax.random.split(rng) # train for batch in glue_train_data_loader(input_rng, train_dataset, total_batch_size): state, train_metrics, dropout_rngs = parallel_train_step(state, batch, dropout_rngs) # evaluate for batch in glue_eval_data_loader(eval_dataset, total_batch_size): predictions = parallel_eval_step(state, batch) metric.add_batch(predictions=chain(*predictions), references=chain(*labels)) eval_metric = metric.compute()"><pre class="notranslate"><span class="pl-k">for</span> <span class="pl-s1">i</span>, <span class="pl-s1">epoch</span> <span class="pl-c1">in</span> <span class="pl-en">enumerate</span>(<span class="pl-en">tqdm</span>(<span class="pl-en">range</span>(<span class="pl-c1">1</span>, <span class="pl-s1">num_train_epochs</span> <span class="pl-c1">+</span> <span class="pl-c1">1</span>), <span class="pl-s1">desc</span><span class="pl-c1">=</span><span class="pl-s">f"Epoch ..."</span>, <span class="pl-s1">position</span><span class="pl-c1">=</span><span class="pl-c1">0</span>, <span class="pl-s1">leave</span><span class="pl-c1">=</span><span class="pl-c1">True</span>)): <span class="pl-s1">rng</span>, <span class="pl-s1">input_rng</span> <span class="pl-c1">=</span> <span class="pl-s1">jax</span>.<span class="pl-s1">random</span>.<span class="pl-en">split</span>(<span class="pl-s1">rng</span>) <span class="pl-c"># train</span> <span class="pl-k">for</span> <span class="pl-s1">batch</span> <span class="pl-c1">in</span> <span class="pl-en">glue_train_data_loader</span>(<span class="pl-s1">input_rng</span>, <span class="pl-s1">train_dataset</span>, <span class="pl-s1">total_batch_size</span>): <span class="pl-s1">state</span>, <span class="pl-s1">train_metrics</span>, <span class="pl-s1">dropout_rngs</span> <span class="pl-c1">=</span> <span class="pl-en">parallel_train_step</span>(<span class="pl-s1">state</span>, <span class="pl-s1">batch</span>, <span class="pl-s1">dropout_rngs</span>) <span class="pl-c"># evaluate</span> <span class="pl-k">for</span> <span class="pl-s1">batch</span> <span class="pl-c1">in</span> <span class="pl-en">glue_eval_data_loader</span>(<span class="pl-s1">eval_dataset</span>, <span class="pl-s1">total_batch_size</span>): <span class="pl-s1">predictions</span> <span class="pl-c1">=</span> <span class="pl-en">parallel_eval_step</span>(<span class="pl-s1">state</span>, <span class="pl-s1">batch</span>) <span class="pl-s1">metric</span>.<span class="pl-en">add_batch</span>(<span class="pl-s1">predictions</span><span class="pl-c1">=</span><span class="pl-en">chain</span>(<span class="pl-c1">*</span><span class="pl-s1">predictions</span>), <span class="pl-s1">references</span><span class="pl-c1">=</span><span class="pl-en">chain</span>(<span class="pl-c1">*</span><span class="pl-s1">labels</span>)) <span class="pl-s1">eval_metric</span> <span class="pl-c1">=</span> <span class="pl-s1">metric</span>.<span class="pl-en">compute</span>()</pre></div> <p dir="auto"><code class="notranslate">parallel_train_step()</code> and <code class="notranslate">parallel_eval_step()</code> are the two <code class="notranslate">pmap()</code>-ed functions and <code class="notranslate">state</code> is the object being passed from one into another. The above code is adapted from <a href="https://colab.research.google.com/github/huggingface/notebooks/blob/master/examples/text_classification_flax.ipynb#scrollTo=FBARxJ8soOrs" rel="nofollow">this</a> HuggingFace Notebook.</p> <p dir="auto">Now, in case of small models, the <code class="notranslate">state</code> is small in size and the output of <code class="notranslate">parallel_train_step</code> or <code class="notranslate">parallel_eval_step</code> gets stored in a buffer distinct from the input buffer. But in case of large models, the output <code class="notranslate">state</code> may get stored in the input buffer itself. But the input buffer is marked as donated, so when the output <code class="notranslate">state</code> is passed into the second function(<code class="notranslate">parallel_eval_step()</code>), it raises <code class="notranslate">RuntimeError: Invalid argument: Buffer has been deleted or donated</code> .</p> <p dir="auto">I notice that we can <code class="notranslate">print()</code> the returned <code class="notranslate">state</code>, we can also <code class="notranslate">serialize()</code> it, but can't pass the buffers to the second <code class="notranslate">pmap()</code>-ed function.</p> <p dir="auto">Manually, I tried solving the above error by using <code class="notranslate">state = jax.tree_util.tree_map(lambda x: jnp.array(x.tolist()), state)</code> before passing it to the second function. Also, tried using <code class="notranslate">lambda x: jnp.array(x,copy=True)</code>. Both of which didn't work. Is there some other way to solve the problem?</p> <p dir="auto">Possible solution can be to un-mark the buffer as <code class="notranslate">donated</code> when the input buffer is used to store the output. But how to do it?</p> <p dir="auto"><strong>Related:</strong> <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="526635040" data-permission-text="Title is private" data-url="https://github.com/google/jax/issues/1733" data-hovercard-type="issue" data-hovercard-url="/google/jax/issues/1733/hovercard" href="https://github.com/google/jax/issues/1733">#1733</a></p> <hr> <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 requests.</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="933465160" data-permission-text="Title is private" data-url="https://github.com/google/jax/issues/7145" data-hovercard-type="issue" data-hovercard-url="/google/jax/issues/7145/hovercard" href="https://github.com/google/jax/issues/7145">#7145</a></li> </ul>
<p dir="auto">Running <code class="notranslate">import jax</code> with jaxlib 0.1.52 and jax 0.1.75 on mac osx 13.16 crashes and gives this error:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="python Python 3.8.2 | packaged by conda-forge | (default, Mar 23 2020, 17:55:48) [Clang 9.0.1 ] on darwin Type &quot;help&quot;, &quot;copyright&quot;, &quot;credits&quot; or &quot;license&quot; for more information. &gt;&gt;&gt; import jax Traceback (most recent call last): File &quot;&lt;stdin&gt;&quot;, line 1, in &lt;module&gt; File &quot;/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jax/__init__.py&quot;, line 22, in &lt;module&gt; from .api import ( File &quot;/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jax/api.py&quot;, line 38, in &lt;module&gt; from . import core File &quot;/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jax/core.py&quot;, line 31, in &lt;module&gt; from . import dtypes File &quot;/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jax/dtypes.py&quot;, line 31, in &lt;module&gt; from .lib import xla_client File &quot;/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jax/lib/__init__.py&quot;, line 52, in &lt;module&gt; from jaxlib import xla_client File &quot;/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jaxlib/xla_client.py&quot;, line 39, in &lt;module&gt; from . import xla_extension as _xla ImportError: dlopen(/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jaxlib/xla_extension.so, 2): Symbol not found: ____chkstk_darwin Referenced from: /Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jaxlib/xla_extension.so (which was built for Mac OS X 10.15) Expected in: /usr/lib/libSystem.B.dylib in /Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jaxlib/xla_extension.so &gt;&gt;&gt;"><pre class="notranslate"><code class="notranslate">python Python 3.8.2 | packaged by conda-forge | (default, Mar 23 2020, 17:55:48) [Clang 9.0.1 ] on darwin Type "help", "copyright", "credits" or "license" for more information. &gt;&gt;&gt; import jax Traceback (most recent call last): File "&lt;stdin&gt;", line 1, in &lt;module&gt; File "/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jax/__init__.py", line 22, in &lt;module&gt; from .api import ( File "/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jax/api.py", line 38, in &lt;module&gt; from . import core File "/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jax/core.py", line 31, in &lt;module&gt; from . import dtypes File "/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jax/dtypes.py", line 31, in &lt;module&gt; from .lib import xla_client File "/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jax/lib/__init__.py", line 52, in &lt;module&gt; from jaxlib import xla_client File "/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jaxlib/xla_client.py", line 39, in &lt;module&gt; from . import xla_extension as _xla ImportError: dlopen(/Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jaxlib/xla_extension.so, 2): Symbol not found: ____chkstk_darwin Referenced from: /Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jaxlib/xla_extension.so (which was built for Mac OS X 10.15) Expected in: /usr/lib/libSystem.B.dylib in /Users/Chris/miniconda3/envs/python3/lib/python3.8/site-packages/jaxlib/xla_extension.so &gt;&gt;&gt; </code></pre></div> <p dir="auto">Jax 0.1.75 and jaxlib 0.1.51 together work fine, so this bug seems like it's been introduced in jaxlib 0.1.51.</p>
0
<p dir="auto">I am using a Three.js file that has not Revision version. It says on top:</p> <ul dir="auto"> <li><a class="user-mention notranslate" data-hovercard-type="organization" data-hovercard-url="/orgs/author/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/author">@author</a> mrdoob / <a href="http://mrdoob.com/" rel="nofollow">http://mrdoob.com/</a></li> <li><a class="user-mention notranslate" data-hovercard-type="organization" data-hovercard-url="/orgs/author/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/author">@author</a> Larry Battle / <a href="http://bateru.com/news" rel="nofollow">http://bateru.com/news</a></li> <li><a class="user-mention notranslate" data-hovercard-type="organization" data-hovercard-url="/orgs/author/hovercard" data-octo-click="hovercard-link-click" data-octo-dimensions="link_type:self" href="https://github.com/author">@author</a> bhouston / <a href="http://exocortex.com" rel="nofollow">http://exocortex.com</a></li> </ul> <p dir="auto">// based on <a href="https://github.com/documentcloud/underscore/blob/bf657be243a075b5e72acc8a83e6f12a564d8f55/underscore.js#L767">https://github.com/documentcloud/underscore/blob/bf657be243a075b5e72acc8a83e6f12a564d8f55/underscore.js#L767</a></p> <ul dir="auto"> <li>As I understand there are many authors of this file and they are mentioned inside the file in many places *</li> </ul> <p dir="auto">@ Browser: Chrome Version 34.0.1847.137 m</p> <p dir="auto">I load some obj. and .mtl files and I create and add some object in the scene. I put them in an array, so I can detect when they 're clicked succesfully. ( (intersectObjects(objs,true) )</p> <p dir="auto">Although, when I create simple circle meshes and put them in an array so I can detect them, detection does not fully work. Very difficultly intersectObjects() detects my clicks on the circles (needs 4-5 clicks on average).</p> <p dir="auto">The strange thing is that when I press F12 and I open the Developer Tools (and then I close it or not,does not matter), everything works perfectly and the circles are easily detected. Very strange. I think something is wrong with intersectObjects(). It seems to me that it does not handle well the meshes.</p> <p dir="auto">Piece of code (because project is big and complicated):<br> <a href="https://dl.dropboxusercontent.com/u/100222836/code.js" rel="nofollow">https://dl.dropboxusercontent.com/u/100222836/code.js</a></p> <p dir="auto">Note: I think couple of days ago console put out an "error" message relate to the .getDescendants function of the Three.js file in the IntersectObjects function.</p>
<h5 dir="auto">Description of the problem</h5> <p dir="auto">Loading textures with a texture loader and loadManager, if the loading image is power of two, memory will be released, if NOT power of two, memory NOT released.</p> <p dir="auto">Here's the code:</p> <div class="snippet-clipboard-content notranslate position-relative overflow-auto" data-snippet-clipboard-copy-content="var mesh0; function testme(){ var manager = new THREE.LoadingManager(function(){ mesh0 = new THREE.Mesh( new THREE.PlaneBufferGeometry( 3, 3 ), new THREE.MeshBasicMaterial( { map: map0 } ) ); scene.add( mesh0 ); }); var texloader = new THREE.TextureLoader(manager); var map0 = texloader.load(&quot;textures/1.png&quot;); } function delme(){ scene.remove(mesh0); mesh0.geometry.dispose(); mesh0.material.map.dispose(); mesh0.material.dispose(); mesh0 = null; }"><pre class="notranslate"><code class="notranslate">var mesh0; function testme(){ var manager = new THREE.LoadingManager(function(){ mesh0 = new THREE.Mesh( new THREE.PlaneBufferGeometry( 3, 3 ), new THREE.MeshBasicMaterial( { map: map0 } ) ); scene.add( mesh0 ); }); var texloader = new THREE.TextureLoader(manager); var map0 = texloader.load("textures/1.png"); } function delme(){ scene.remove(mesh0); mesh0.geometry.dispose(); mesh0.material.map.dispose(); mesh0.material.dispose(); mesh0 = null; } </code></pre></div> <p dir="auto">1.png (900x598), memory not released;<br> 2.png (1024x256), memory released</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" checked=""> Dev</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> r87</li> <li class="task-list-item"><input type="checkbox" id="" disabled="" class="task-list-item-checkbox" checked=""> r86</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" checked=""> 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"> 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>
0
<p dir="auto">Hi,</p> <p dir="auto">We have been adding compile time safety to the magic string problem through the excellent string literal type introduced in 1.8.</p> <p dir="auto">One case that we are finding slipping through the safety net is the following:</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="type Foo = 'a' | 'b'; const foo: Foo = 'a'; if (foo === 'bar') { }"><pre class="notranslate"><span class="pl-k">type</span> <span class="pl-smi">Foo</span> <span class="pl-c1">=</span> <span class="pl-s">'a'</span> <span class="pl-c1">|</span> <span class="pl-s">'b'</span><span class="pl-kos">;</span> <span class="pl-k">const</span> <span class="pl-s1">foo</span>: <span class="pl-smi">Foo</span> <span class="pl-c1">=</span> <span class="pl-s">'a'</span><span class="pl-kos">;</span> <span class="pl-k">if</span> <span class="pl-kos">(</span><span class="pl-s1">foo</span> <span class="pl-c1">===</span> <span class="pl-s">'bar'</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-kos">}</span></pre></div> <p dir="auto">Here the <code class="notranslate">Foo</code> type is being compared to an incompatible value 'bar'.</p> <p dir="auto">It would be nice to get an error here similar to an enum comparison error:</p> <div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="enum Foo { a, b } enum Bar { a, b } let foo: Foo; if (foo === Bar.a) { // Operator '===' cannot be applied to types 'Foo' and 'Bar' } "><pre class="notranslate"><span class="pl-k">enum</span> <span class="pl-smi">Foo</span> <span class="pl-kos">{</span> <span class="pl-c1">a</span><span class="pl-kos">,</span> <span class="pl-c1">b</span> <span class="pl-kos">}</span> <span class="pl-k">enum</span> <span class="pl-smi">Bar</span> <span class="pl-kos">{</span> <span class="pl-c1">a</span><span class="pl-kos">,</span> <span class="pl-c1">b</span> <span class="pl-kos">}</span> <span class="pl-k">let</span> <span class="pl-s1">foo</span>: <span class="pl-smi">Foo</span><span class="pl-kos">;</span> <span class="pl-k">if</span> <span class="pl-kos">(</span><span class="pl-s1">foo</span> <span class="pl-c1">===</span> <span class="pl-smi">Bar</span><span class="pl-kos">.</span><span class="pl-c1">a</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-c">// Operator '===' cannot be applied to types 'Foo' and 'Bar'</span> <span class="pl-kos">}</span></pre></div> <p dir="auto">This is especially useful for obtaining a compile time error when the original strings <code class="notranslate">('a' | 'b')</code> are refactored during the course of development.</p> <p dir="auto">I'm aware that there are workarounds involving pseudo string enums, but this is a suggestion for this primitive case.</p> <p dir="auto">Thanks.</p>
<div class="highlight highlight-source-ts notranslate position-relative overflow-auto" dir="auto" data-snippet-clipboard-copy-content="type foo = 'hey' | 'nay'; switch (&lt;foo&gt;undefined) { case 'boom': console.log('never the case'); break; // expected unreachable code, actual no problem }"><pre class="notranslate"><span class="pl-k">type</span> <span class="pl-smi">foo</span> <span class="pl-c1">=</span> <span class="pl-s">'hey'</span> <span class="pl-c1">|</span> <span class="pl-s">'nay'</span><span class="pl-kos">;</span> <span class="pl-k">switch</span> <span class="pl-kos">(</span><span class="pl-kos">&lt;</span><span class="pl-smi">foo</span><span class="pl-kos">&gt;</span><span class="pl-c1">undefined</span><span class="pl-kos">)</span> <span class="pl-kos">{</span> <span class="pl-k">case</span> <span class="pl-s">'boom'</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">'never the case'</span><span class="pl-kos">)</span><span class="pl-kos">;</span> <span class="pl-k">break</span><span class="pl-kos">;</span> <span class="pl-c">// expected unreachable code, actual no problem</span> <span class="pl-kos">}</span></pre></div>
1