question_id int64 37.6M 73.2M | input_text stringlengths 88 52.4k | output_text stringlengths 37 35.6k | title stringlengths 15 150 | tags stringlengths 1 107 | q_score int64 -19 397 | view_count int64 3 879k | answer_count int64 1 21 | accepted_answer_id int64 37.6M 73.8M | answer_id int64 37.6M 73.8M | a_score int64 -5 1.29k | is_accepted bool 1
class | creation_date stringlengths 20 24 | input_text_instruct stringlengths 251 52.6k |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
71,846,118 | How do I specify which php file to open in command prompt?<p>I'm creating a website project using php through xampp. I've followed through a tutorial online and have opened up my website through localhost:8000. My question is, when I open a php file through command prompt, how do I specify which file I want to be opene... | <p>To open a PHP file through the command prompt you type:</p>
<pre><code>php nameOfFile.php
</code></pre>
<p>That isn't what you are doing. You're running the PHP <a href="https://www.php.net/manual/en/features.commandline.webserver.php" rel="nofollow noreferrer">built in web server</a>. It doesn't open <em>index.php<... | How do I specify which php file to open in command prompt? | php|xampp | 0 | 29 | 1 | 71,846,165 | 71,846,165 | 0 | true | 2022-04-12T16:21:57.170Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do I specify which php file to open in command prompt?<p>I'm creating a website project using php through xampp. I've followed through a tutorial online ... |
71,847,214 | How to get in which store did the specific product get the most benefit?<p>So, here are my tables:</p>
<p><strong>Sales</strong></p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>id</th>
<th>product_code</th>
<th>store_id</th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>4536</td>
<td>1</td>
</... | <p>You can find the store in question by grouping by <code>store_id</code> and ordering by the benefit.</p>
<pre><code>select top(1)
sales.store_id, sum(price-real_price)*count(sales.product_code) as benefit
from products
join sales on sales.product_code = products.product_code
where products.product_name like '%re... | How to get in which store did the specific product get the most benefit? | sql|sql-server | 0 | 26 | 2 | 71,847,406 | 71,847,406 | 0 | true | 2022-04-12T17:57:16.293Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to get in which store did the specific product get the most benefit?<p>So, here are my tables:</p>
<p><strong>Sales</strong></p>
<div class="s-table-cont... |
71,832,489 | A terminal open everytime when I open Chrome or visual studio code<p><a href="https://i.stack.imgur.com/SQR1y.jpg" rel="nofollow noreferrer">Image</a></p>
<p>A terminal open everytime when I open Chrome or visual studio code. It started to do do this when I'm started coding in typescript</p> | <p>I solved. You need to do</p>
<p><code>npm uninstall typescript --g</code></p> | A terminal open everytime when I open Chrome or visual studio code | typescript|google-chrome|visual-studio-code|terminal | 0 | 29 | 1 | 71,847,643 | 71,847,643 | 0 | true | 2022-04-11T18:16:58.340Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
A terminal open everytime when I open Chrome or visual studio code<p><a href="https://i.stack.imgur.com/SQR1y.jpg" rel="nofollow noreferrer">Image</a></p>
<p... |
71,845,108 | I'm trying to use a local variable's value in another query in PLSQL package but every time the 2nd query is returning null value<pre><code>BEGIN
--{
SELECT CONCAT(CONCAT('''',REPLACE(VALUE_1, ',', ''',''')),'''') into glv_v_PROC_FEE
FROM TABLE_A ;
EXCEPTION WHEN NO_DATA_FOUND THEN
... | <p>You can't use such a value in <code>IN</code>; you'll have to split it to rows, such as</p>
<pre><code>SELECT sum(ORDER) INTO glv_v_PROCESSING_FEE_WITH_VAT
FROM TABLE_B
WHERE COL1 in (select regexp_substr(glv_v_PROC_FEE, '[^,]+', 1, level)
from dual
connect by level <= regexp_count... | I'm trying to use a local variable's value in another query in PLSQL package but every time the 2nd query is returning null value | plsql|plsqldeveloper|plsql-package | 0 | 19 | 1 | 71,848,302 | 71,848,302 | 0 | true | 2022-04-12T15:11:02.017Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
I'm trying to use a local variable's value in another query in PLSQL package but every time the 2nd query is returning null value<pre><code>BEGIN
--{
... |
71,847,886 | Radio button with different ids, different values, same name attribute<p>I got my radio Selector that looks like this</p>
<pre><code><div id="graph_selector" style="display:none; text-align: center;" >
<p><b>Tipo de Grafico: </b></p>
<div class="cc-selec... | <p>nvm, solved the issue, I was missing the checked property on my js</p>
<p>it went from this</p>
<pre><code>var graph_selector = document.querySelector('input[name=sel_graph]').value
</code></pre>
<p>to this</p>
<pre><code>var graph_selector = document.querySelector('input[name=sel_graph]:checked').value
</code></pre... | Radio button with different ids, different values, same name attribute | javascript|php|radio-button | 0 | 282 | 2 | 71,848,327 | 71,848,327 | 0 | true | 2022-04-12T19:04:19.943Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Radio button with different ids, different values, same name attribute<p>I got my radio Selector that looks like this</p>
<pre><code><div id="graph_s... |
71,846,740 | 301 redirection querystring to clean URL<p>I have a new version of the deuxia.com website</p>
<p>The site used URLs with Querystring, now "clean" URLs.</p>
<p>To avoid 404 errors and not lose SEO, I would like to redirect in the .htaccess (apache server 2.4)</p>
<p>Example old URL
<a href="https://www.deuxia.... | <p>In the .htaccess file</p>
<pre><code><IfModule mod_rewrite.c>
# OTHER CODE
RewriteEngine On
RewriteCond %{QUERY_STRING} ^rechercheRef=(\w+)
RewriteRule ^detail-produit-immobilier\.php$ /detail-annonce-immobilier/%1? [R=301,L]
# OTHER CODE
</IfModule>
</code></pre> | 301 redirection querystring to clean URL | regex|apache2 | 0 | 13 | 1 | 71,849,217 | 71,849,217 | 0 | true | 2022-04-12T17:13:45.130Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
301 redirection querystring to clean URL<p>I have a new version of the deuxia.com website</p>
<p>The site used URLs with Querystring, now "clean" U... |
71,847,771 | selecting measurements from specific points (crossectional) from longitudinal data in R<p>I have a list of longitudinal data for a specific measurement. I would like to select only the last measurement per sample. For example, lets say I have measured the time it takes for a group of people to run a mile. I only want t... | <p>You can use dplyr to filter for each Name the maximum value of Trial</p>
<pre><code>library(dplyr)
dat %>%
group_by(Name) %>%
filter(Trial == max(Trial)
</code></pre> | selecting measurements from specific points (crossectional) from longitudinal data in R | r|subset | 0 | 23 | 1 | 71,849,621 | 71,849,621 | 0 | true | 2022-04-12T18:53:46.533Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
selecting measurements from specific points (crossectional) from longitudinal data in R<p>I have a list of longitudinal data for a specific measurement. I wo... |
71,824,701 | Install/update package through a function in that very same package<p>I realized I probably did something stupid...I created my own package and put it into a Google drive.</p>
<p>I've written a function in that package <code>update_my_package</code> which downloads the tar.gz file from Google drive and then tries to i... | <p>Interestingly, installing/updating a package through a function of that package is possible after all. The "trick" was to first detach the package before installing the update, e.g.</p>
<pre><code>update_fun <- function()
{
detach(package:my_package, unload = TRUE)
remotes::install_local("my_pa... | Install/update package through a function in that very same package | r|installation | 0 | 30 | 1 | 71,849,730 | 71,849,730 | 0 | true | 2022-04-11T08:23:00.143Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Install/update package through a function in that very same package<p>I realized I probably did something stupid...I created my own package and put it into a... |
71,850,125 | I'm getting this error: filter object at 0x041A7F28 error when I run this program listed below<p>I'm trying to get this program to print the verbs, I get the same error in the interpreter and as a program ran from the command line. Any help would be great! Thank you in advance!</p>
<pre><code> from __future__ import ... | <pre><code><filter object at 0x041A7F28>
</code></pre>
<p>That's not an error. That's how filter objects print.</p>
<p>To get the <em>results</em> of the filter, you have to iterate over the filter object. The easiest way to do that is to pass it to <code>list()</code>:</p>
<pre><code>verbs = list(filter(lambda... | I'm getting this error: filter object at 0x041A7F28 error when I run this program listed below | python|nltk | 0 | 20 | 1 | 71,850,198 | 71,850,198 | 0 | true | 2022-04-12T23:17:19.027Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
I'm getting this error: filter object at 0x041A7F28 error when I run this program listed below<p>I'm trying to get this program to print the verbs, I get the... |
71,850,030 | SSRS in Visual Studio - breaking one table into two rows<p>I created a dataset that contains more than 10 fields. But the page can only hold, say 8 fields (after exporting to PDF). Is there a way to "move" those remaining 2 fields to the next row? So each record will have two rows of headers and two rows of d... | <p>You can add an extra row to the header by simply right-clicking one of the header textboxes, and then insert row below or above as required.</p>
<p>Then in your detail row, do the same thing, and then on the additional row you just added, set the textboxes to the remaining fields.</p> | SSRS in Visual Studio - breaking one table into two rows | visual-studio|reporting-services | 0 | 19 | 1 | 71,850,274 | 71,850,274 | 0 | true | 2022-04-12T23:01:10.687Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
SSRS in Visual Studio - breaking one table into two rows<p>I created a dataset that contains more than 10 fields. But the page can only hold, say 8 fields (a... |
71,848,586 | Change csound oscillator frequency while playing one note<p>I'm using CSound in the context of <strong>CSoundUnity</strong> to build a synthesizer with Unity.
I would like to have the possibility to change the frequency of one note of quasi infinite duration during play-time. Not between notes.</p>
<p>The communication... | <p>The channel reading at k-rate is fine, you just need to use a different oscillator that accepts k-rate frequency changes. Try oscili or oscil3 for example.</p> | Change csound oscillator frequency while playing one note | unity3d|csound | 0 | 22 | 1 | 71,850,443 | 71,850,443 | 0 | true | 2022-04-12T20:08:05.070Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Change csound oscillator frequency while playing one note<p>I'm using CSound in the context of <strong>CSoundUnity</strong> to build a synthesizer with Unity... |
71,850,499 | How do I have it so that sprites in a group all spawn in random locations only once in the draw function?<p>I want to have it in my code such that all of the sprites in a group variable spawn in different locations once in the draw function. The problem I am currently having is that since the draw function constantly r... | <p>You have two options:</p>
<ol>
<li>Move the random position code to the <code>setup()</code> function</li>
<li>Wrap the random position code in an if block such that it only runs once</li>
</ol>
<p>Option #1 is trivial, but here is an example of option #2</p>
<pre class="lang-js prettyprint-override"><code>let group... | How do I have it so that sprites in a group all spawn in random locations only once in the draw function? | random|position|sprite|draw|p5.js | 0 | 19 | 1 | 71,850,553 | 71,850,553 | 0 | true | 2022-04-13T00:26:16.703Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do I have it so that sprites in a group all spawn in random locations only once in the draw function?<p>I want to have it in my code such that all of the... |
71,851,132 | Can I disable an anchor tag with respect to an if condition which return a string<p>I have made an anchor tag (not a button) text to redirect me to another page</p>
<pre><code><StyledTableCell align="center">
<Link href={`/races/results/${race.id}`}>{race.race_name}</Link>
</StyledTabl... | <p>Would only placing a <code><Link></code> when the status is <code>Open</code>, otherwise just a <code>span</code> be ok to implement?</p>
<pre><code><StyledTableCell align="center">
{getRaceStatus === 'Open' ?
<Link href={`/races/results/${race.id}`}>{race.race_name}</Link&... | Can I disable an anchor tag with respect to an if condition which return a string | javascript|css|reactjs | 0 | 21 | 1 | 71,851,169 | 71,851,169 | 0 | true | 2022-04-13T02:26:35.363Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Can I disable an anchor tag with respect to an if condition which return a string<p>I have made an anchor tag (not a button) text to redirect me to another p... |
71,851,246 | How to create input text patterns (html forms)<p>I have tried to create an input text pattern that only allows 8 digits and a capital or simple "d" at the end of it but I can't seem to limit the number of digits. example 12345678d or 12345678D</p>
<pre><code><input type="text" name="studenti... | <p>You can specify that there should be exactly 8 digits with <code>pattern="[0-9]{8}[dD]"</code>.</p> | How to create input text patterns (html forms) | html|regex|forms | 0 | 31 | 3 | 71,851,297 | 71,851,297 | 0 | true | 2022-04-13T02:44:19.147Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to create input text patterns (html forms)<p>I have tried to create an input text pattern that only allows 8 digits and a capital or simple "d"... |
71,149,486 | Why does my react app show up fine on some decvices but on newer ones it only displays a white page<p>My app displays fine on older Macs but not on iPhones or new Mac models.
What could be the cause of this? I've been trolling web pages for hours and found nothing that makes any sense to me. Please can anyone help!</p>... | <p>The problem was not for newer machines or devices. It was not showing up on any devices that didn't have metamask already installed.</p> | Why does my react app show up fine on some decvices but on newer ones it only displays a white page | reactjs|react-native|deployment|web-deployment | 0 | 22 | 1 | 71,851,990 | 71,851,990 | 0 | true | 2022-02-16T21:28:04.913Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why does my react app show up fine on some decvices but on newer ones it only displays a white page<p>My app displays fine on older Macs but not on iPhones o... |
71,852,369 | Django Template extract list<p>I have a list:</p>
<ul>
<li>productlinks = [google.com, tes.com, lol.com]</li>
<li>prices = [$134, $123,$123]</li>
</ul>
<p>I wanna extract those list to my django template inside the bootsrap. Here is my django template code:</p>
<pre><code><section class="py-5">
... | <p>views</p>
<pre><code>return render(request, '/home.html', {
'data': zip(productlinks,productprices)
}
)
</code></pre>
<p>template</p>
<pre><code><section class="py-5">
<div class="container px-4 px-lg-5 mt-5">
<div class="row... | Django Template extract list | python|django|django-templates | 0 | 36 | 1 | 71,852,473 | 71,852,473 | 0 | true | 2022-04-13T05:36:13.990Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Django Template extract list<p>I have a list:</p>
<ul>
<li>productlinks = [google.com, tes.com, lol.com]</li>
<li>prices = [$134, $123,$123]</li>
</ul>
<p>I ... |
71,838,566 | getting data out of a list of dict's with same names eg. [{route number : 123,}, {happy customers : 1.5}, {route number : 456}, {happy customers : 0}]<p>i am having a bit of trouble with this not sure of best way to go</p>
<p>objective = import csv from file, convert to list of dict, get user input (number), print (num... | <pre><code> rec_routes = [route["route number"] for route in sorted_list]
</code></pre>
<p>found this to convert all route numbers in the list of dictionaries to a list of route numbers after they had been sorted.</p> | getting data out of a list of dict's with same names eg. [{route number : 123,}, {happy customers : 1.5}, {route number : 456}, {happy customers : 0}] | python|list|dictionary|splice | 0 | 33 | 1 | 71,852,603 | 71,852,603 | 0 | true | 2022-04-12T07:17:52.830Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
getting data out of a list of dict's with same names eg. [{route number : 123,}, {happy customers : 1.5}, {route number : 456}, {happy customers : 0}]<p>i am... |
71,853,579 | Displaying json data with parent and two childs using sectionlist/flatlist in reac-native<p>I am still new in react-native networking and I want to display json data using sectionlist
Here is my code</p>
<pre><code> import * as React from 'react';
import { Button, View ,Pressable,Text,StyleSheet,ActivityIndicator,Fla... | <p>I guess it should be like this.</p>
<pre><code><FlatList
data={this.state.data} // you should add this.state
keyExtractor={({ id }, index) => id}
renderItem={({ item }) => (
<Text>{item.firstName}, {item.lastName}</Text>
)}
/>
</code></pre> | Displaying json data with parent and two childs using sectionlist/flatlist in reac-native | json|react-native|networking | 0 | 28 | 1 | 71,853,995 | 71,853,995 | 0 | true | 2022-04-13T07:32:17.733Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Displaying json data with parent and two childs using sectionlist/flatlist in reac-native<p>I am still new in react-native networking and I want to display j... |
71,833,389 | Proxysql query rule starting with comment didn't work<p>On proxyql 2.2.0</p>
<p>I've the following rule which isn't working (stats_mysql_query_rules counter always on 0).
<code>INSERT INTO mysql_query_rules (active, match_digest, destination_hostgroup, apply, multiplex) VALUES (1, '/\* Master \*/', 1, 1, 1);</code></p>... | <p>The documentation isn't explicit about it but it seems that query rules match_digest evaluation is stripping comments (e.g. /* Comments */) within SQL queries. So the pattern used above need to be insert inside the match_pattern field</p> | Proxysql query rule starting with comment didn't work | proxysql | 0 | 25 | 1 | 71,854,793 | 71,854,793 | 0 | true | 2022-04-11T19:34:50.890Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Proxysql query rule starting with comment didn't work<p>On proxyql 2.2.0</p>
<p>I've the following rule which isn't working (stats_mysql_query_rules counter ... |
71,854,838 | JAVA CodeCov | CodeCov tests both main and test files, How to check only main files?<p>I have a file name AVLTree.java, to test I have created AVLTreetest.java but codecov tests both src/main 80% and src/test 0% folder so due to that my score is reduced</p>
<p>This is my src directory</p>
<pre><code>src
- main->... | <p>This resolved the issue after adding codecov.yml</p>
<p>I created codecov.yml in github</p>
<pre><code>ignore
- "src/test"
</code></pre> | JAVA CodeCov | CodeCov tests both main and test files, How to check only main files? | maven|code-coverage|junit4|codecov | 0 | 28 | 1 | 71,854,953 | 71,854,953 | 0 | true | 2022-04-13T09:10:03.380Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
JAVA CodeCov | CodeCov tests both main and test files, How to check only main files?<p>I have a file name AVLTree.java, to test I have created AVLTreetest.ja... |
71,856,125 | How to take positions from np.where<p>I created a dataframe of booleans, and i want to extract the values that are equal to True, and modify it in the original dataframe.</p>
<pre><code>up_val=(np.where(up['Balls']==True))
up_val
</code></pre>
<p>output: array([26, 28, 35, 36, 38], dtype=int64)</p>
<p>Then I want to go... | <p>Assuming <code>up_val</code> is a pandas DataFrame:</p>
<pre><code>up_val=(np.where(up['Balls']==True))
# now if you want to change these rows in the column to 99
up['Balls'].iloc[up_val[0]] = 99
</code></pre>
<p>The index behind <code>up_val</code> is necessary because <code>np.where</code> returns a tuple.</p> | How to take positions from np.where | python | 0 | 18 | 1 | 71,856,180 | 71,856,180 | 0 | true | 2022-04-13T10:42:10.797Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to take positions from np.where<p>I created a dataframe of booleans, and i want to extract the values that are equal to True, and modify it in the origin... |
71,856,361 | Why ifelse() works different than if(){}else{} in R<p>Does anyone know why the below code using if(){}else{} structure works:</p>
<pre class="lang-r prettyprint-override"><code>if(T){
y = 1
}else{y = 0}
</code></pre>
<p>but the below one using ifelse raises an error:</p>
<pre class="lang-r prettyprint-overrid... | <p>You should use <code>ifelse</code> in this way (instead of the asignment within <code>ifelse(...)</code>)</p>
<pre><code>y <- ifelse(T,1,0)
</code></pre> | Why ifelse() works different than if(){}else{} in R | r|if-statement | 0 | 31 | 1 | 71,856,393 | 71,856,393 | 0 | true | 2022-04-13T10:59:31.920Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why ifelse() works different than if(){}else{} in R<p>Does anyone know why the below code using if(){}else{} structure works:</p>
<pre class="lang-r prettypr... |
71,792,703 | MATLAB Simulink: Error evaluating 'InitFcn' callback of block_diagram 'BLDC_control_buck_converter'<p>I was modeling a vehicle with BLDC motor. After simulation when i run the model i received a <a href="https://i.stack.imgur.com/FWPgO.jpg" rel="nofollow noreferrer">Error Message</a> .So i've no idea about <strong>bldc... | <p>It looks like you have an initialization function "load bldcData" that should load variables from the .mat file "bldcData" to your workspace. You need to have this file on your matlab search path.
Or, if you don't need these variables, delete the "load bldcData" string from callbacks, f... | MATLAB Simulink: Error evaluating 'InitFcn' callback of block_diagram 'BLDC_control_buck_converter' | matlab|load|simulink|modeling | 0 | 529 | 1 | 71,857,436 | 71,857,436 | 0 | true | 2022-04-08T06:41:45.947Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
MATLAB Simulink: Error evaluating 'InitFcn' callback of block_diagram 'BLDC_control_buck_converter'<p>I was modeling a vehicle with BLDC motor. After simulat... |
71,858,024 | How to remove blanks in my slider ( Trying full screen slider )<p>sorry for the this basic question. I am new on front-end. And triying create a responsive portfolio site. And this is my problem actually I am trying full screen slider. How can I remove blanks and How can I do full stretch screen slider. My idea full sc... | <p>There is a css reset you can add to the body tag.</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snippet-code-css lang-css prettyprint-override"><code>/* ADD THIS CSS RESET */
body {
padding: 0;
margin: 0;
overflow: hi... | How to remove blanks in my slider ( Trying full screen slider ) | javascript|html|css | 0 | 32 | 1 | 71,858,082 | 71,858,082 | 0 | true | 2022-04-13T13:07:36.097Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to remove blanks in my slider ( Trying full screen slider )<p>sorry for the this basic question. I am new on front-end. And triying create a responsive p... |
71,858,174 | If the csv file is more than 3 lines, edit it to delete the first line (Not save as new file)<p>Im trying to code if the csv file is more than 3 lines, edit it to delete the first line.</p>
<p>I want to delete the first line from the existing file instead of saving it as a new file.</p>
<p>For this reason, I had to del... | <p>Take a 2-step approach.</p>
<p>Open the file for reading and count the number of lines. If there are more than 3 lines, re-open the file (for writing) and update it.</p>
<p>For example:</p>
<pre><code>lines = []
with open('./csv/selllist.csv') as csv:
lines = csv.readlines()
if len(lines) > 3:
with open('./cs... | If the csv file is more than 3 lines, edit it to delete the first line (Not save as new file) | python|pandas|dataframe|csv | 0 | 29 | 3 | 71,858,264 | 71,858,264 | 0 | true | 2022-04-13T13:18:15.300Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
If the csv file is more than 3 lines, edit it to delete the first line (Not save as new file)<p>Im trying to code if the csv file is more than 3 lines, edit ... |
71,858,152 | React fetch api keep requesting on loop<pre><code>function getCharacter(){
fetch("http://localhost:8001/tinder-card").then((resp)=>resp.json()).then((result)=>{
if(result.status==false){
alert("No card found in database")
}
else{
setpeople(re... | <p>Add an empty array as the second argument of <code>useEffect()</code>.</p>
<pre><code>useEffect(()=>{
getCharacter();
}, [])
</code></pre>
<p>Otherwise <code>useEffect</code> will run every time your component re-renders causing this infinite loop.</p> | React fetch api keep requesting on loop | node.js|reactjs|api | 0 | 34 | 3 | 71,858,307 | 71,858,307 | 0 | true | 2022-04-13T13:16:24.213Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
React fetch api keep requesting on loop<pre><code>function getCharacter(){
fetch("http://localhost:8001/tinder-card").then((resp)=>resp.json... |
71,857,972 | Set world backgroundcolor<p>How can you set the background color?</p>
<p>I tried setting this in onLoad:</p>
<pre><code>world.color.setRGB(0,0,255);
</code></pre>
<p>I also tried adding a component, but I maybe there is a better way:</p>
<pre><code>class Background extends PositionComponent with HasGameRef {
@overrid... | <pre><code> @override
Color backgroundColor() => const Color(0xFFeeeeee);
</code></pre> | Set world backgroundcolor | flame | 0 | 23 | 1 | 71,858,525 | 71,858,525 | 0 | true | 2022-04-13T13:04:12.267Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Set world backgroundcolor<p>How can you set the background color?</p>
<p>I tried setting this in onLoad:</p>
<pre><code>world.color.setRGB(0,0,255);
</code><... |
71,857,959 | ERROR - EF Core could not be translated. Either rewrite the query in a form that can be translated<p>EF Core 3.1, C#, .net core</p>
<p>I am trying to query the database table AnglerResult and return stats for an angler like below:</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>angler</th>
... | <p>EF Core 3.1 do not support such <code>Count</code>. You can emulate it by <code>Sum</code></p>
<pre class="lang-cs prettyprint-override"><code>Anglers = await _anglerResultRepo.GetTableContext()
.GroupBy(g => g.UserId)
.Select(x => new AnglerDTO
{
UserId = x.Key,
Name = x.Key,
... | ERROR - EF Core could not be translated. Either rewrite the query in a form that can be translated | c#|entity-framework-core | 0 | 799 | 2 | 71,859,058 | 71,859,058 | 0 | true | 2022-04-13T13:03:34.657Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
ERROR - EF Core could not be translated. Either rewrite the query in a form that can be translated<p>EF Core 3.1, C#, .net core</p>
<p>I am trying to query t... |
71,859,787 | How to adjust the composition of the site?<p>I don't understand why my <code><hr></code> takes the whole page horizontally the first two times I use it, then the third one stops a little from the left margin. After the third <code><hr></code> the whole page sitto of this moves from the margin as much as the... | <p>The third <code><hr></code> is inside the <code>div class="Property2"</code> which has css <code>margin-left: 90px;</code></p>
<pre><code><!-- open div, which has margin left -->
<div class="Property2">
<h3>Composition of bouquet</h3>
<div class="container1&... | How to adjust the composition of the site? | html|css | 0 | 23 | 1 | 71,859,841 | 71,859,841 | 0 | true | 2022-04-13T15:08:15.440Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to adjust the composition of the site?<p>I don't understand why my <code><hr></code> takes the whole page horizontally the first two times I use it... |
71,859,877 | is it possible to update NodeJS via script?<p>is there a way to update the <strong>nodejs</strong> version via a <strong>script</strong>. I am currently trying to run some code on <strong>play.js</strong> which is a <strong>javascript</strong> IDE for iPad but it does <strong>not</strong> have a terminal option, and I ... | <p>It is very unlikely that you'll be able to change the Node.js runtime of the app yourself.</p>
<p>According to the app landing page <a href="https://playdotjs.com" rel="nofollow noreferrer">https://playdotjs.com</a>, it seems the app comes with Node 12.16.0.</p>
<p>The app developer would have to implement a user-fa... | is it possible to update NodeJS via script? | javascript|ios|node.js | 0 | 35 | 1 | 71,860,042 | 71,860,042 | 0 | true | 2022-04-13T15:16:02.087Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
is it possible to update NodeJS via script?<p>is there a way to update the <strong>nodejs</strong> version via a <strong>script</strong>. I am currently tryi... |
71,848,031 | How to filter a SQL query table by clicking on a link on Web application in VB.net?<p>I am having trouble with pushing the SQL query through to filter the table after the user clicks on a link in the sidebar. I am using the sample database Northwind to create this app. I have implemented a search function and sorting f... | <p>I figured out what I needed to change in order to make the links in the sidebar filter. They needed to become <code>ActionLinks</code> in order to actually filter in the SQL table.
Changed from this:</p>
<pre><code><a href="#Argentina">
</code></pre>
<p>To this:</p>
<pre><code>@Html.ActionLink("... | How to filter a SQL query table by clicking on a link on Web application in VB.net? | vb.net | 0 | 23 | 1 | 71,861,124 | 71,861,124 | 0 | true | 2022-04-12T19:17:02.750Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to filter a SQL query table by clicking on a link on Web application in VB.net?<p>I am having trouble with pushing the SQL query through to filter the ta... |
71,861,323 | How do I create a button that consists of 2 different fonts? (In my case, Montserrat & Intro Script)<p>I'm trying to design a button that consists of 2 different fonts (and an icon). I've tried W3 Schools, but they don't cover that specific example.</p>
<p>The fonts in the button design are Montserrat and Intro Script.... | <p>You can wrap the text you want to make a different font in a span and then change the font for the span. You may need to play around with the vertical alignment to ge them to line up properly.</p>
<p>In the case below, I used <code>vertical-align: sub</code></p>
<p><div class="snippet" data-lang="js" data-hide="fals... | How do I create a button that consists of 2 different fonts? (In my case, Montserrat & Intro Script) | css|button|fonts | 0 | 28 | 2 | 71,861,731 | 71,861,731 | 0 | true | 2022-04-13T17:03:38.493Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do I create a button that consists of 2 different fonts? (In my case, Montserrat & Intro Script)<p>I'm trying to design a button that consists of 2 diffe... |
71,848,700 | REPL: How can I look up information about a type?<p>Coming from Haskell, I struggle finding an easy way to look up type definitions in Purescript's REPL. In Haskell, I can do the following inside GHCI:</p>
<pre><code>-- type class
:info Monad
-- shortcut
:i Monad
-- concrete types
:i []
:i (->)
-- type constructor... | <p>To get the type signatures, use <code>:type</code></p>
<pre><code>> :type (1 + _)
> Int -> Int
</code></pre>
<p>To display the kind of a type, use <code>:kind</code></p>
<pre><code>> :kind Maybe
> Type -> Type
</code></pre>
<p>To See all the functions, types, and type classes that a module e... | REPL: How can I look up information about a type? | purescript | 0 | 23 | 1 | 71,861,794 | 71,861,794 | 0 | true | 2022-04-12T20:20:21.883Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
REPL: How can I look up information about a type?<p>Coming from Haskell, I struggle finding an easy way to look up type definitions in Purescript's REPL. In ... |
71,862,233 | Mapped type producing unexpected results when created from generic type<p>I'm using static objects to describe contract definitions, and attempting to generate types based on them. These contracts can optionally have some options, which I want to describe using an array of option names. I then want to use this array to... | <p>Use a tuple to make sure that each constituent is not considered separately:</p>
<pre><code>type ConstructOptions<T1 extends Definition, T2 = T1['optionNames'][number]> = [T2] extends [string | number | symbol] ? Record<T2, string> : {}
</code></pre>
<p>Full example:</p>
<pre><code>const definition = { ... | Mapped type producing unexpected results when created from generic type | typescript|typescript-generics|template-literals | 0 | 31 | 1 | 71,862,290 | 71,862,290 | 0 | true | 2022-04-13T18:22:25.917Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Mapped type producing unexpected results when created from generic type<p>I'm using static objects to describe contract definitions, and attempting to genera... |
71,830,762 | How to limit MultipartFile size per endpoint or controller (NOT globally)?<p>I want to set a unique file size limit per endpoint or per controller.</p>
<p>I am aware I can set a global file size limit with the following properties, but this is NOT what I want to do, I want UNIQUE LIMIT PER ENDPOINT or CONTROLLER:</p>
<... | <p>Based on the tips provided by <a href="https://stackoverflow.com/a/71836997/12302982">swapyonubuntu</a>, create a bean to register a new filter. Then register your filter, may as well implement inline if this specific filter is only used for a very specific endpoint or two.</p>
<pre class="lang-java prettyprint-over... | How to limit MultipartFile size per endpoint or controller (NOT globally)? | java|spring-boot | 0 | 275 | 2 | 71,862,706 | 71,862,706 | 0 | true | 2022-04-11T15:50:50.183Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to limit MultipartFile size per endpoint or controller (NOT globally)?<p>I want to set a unique file size limit per endpoint or per controller.</p>
<p>I ... |
71,862,391 | How to share a list object with custom form<p>Am trying to share posted objects on list view but each time that I click on the share button which redirect me to share_form.html after typing into the shared textarea and submit the form it doesn't submit the shared object form, unless I use context variable {{ form }} be... | <p>So after i had taken sometime to carefully analyzed the issue i had stable on a solution, actually the problem was coming from the form model:</p>
<pre><code> this where the problem was
class ShareForm(forms.Form):
body = forms.CharField(label='',widget=forms.Textarea(attrs={
'rows': '3',
'placeholder':... | How to share a list object with custom form | html|django|django-views|django-forms | 0 | 19 | 1 | 71,862,969 | 71,862,969 | 0 | true | 2022-04-13T18:37:16.783Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to share a list object with custom form<p>Am trying to share posted objects on list view but each time that I click on the share button which redirect me... |
71,863,391 | Cannot override attribute in extended definition<p>After upgrading from Tiles 2 to Tiles 3, it seems overriding attributes stopped working.</p>
<p>My <code>tiles.xml</code> has something like this where <code>create-form</code> extends from <code>baseLayout</code>. I'm getting null for the "title" attribute (... | <p>This solved my problem. I don't know why overriding an attribute in Tiles 3 only worked using the <code>value</code> attribute (not using the body of the <code><put-attribute></code> tag).</p>
<pre><code><put-attribute name="title" value="Create New Item" />
</code></pre> | Cannot override attribute in extended definition | tiles|apache-tiles|tiles-3 | 0 | 16 | 1 | 71,863,392 | 71,863,392 | 0 | true | 2022-04-13T20:15:44.883Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Cannot override attribute in extended definition<p>After upgrading from Tiles 2 to Tiles 3, it seems overriding attributes stopped working.</p>
<p>My <code>t... |
71,864,333 | How to I search the MySQL Database with multiple PHP Arrays and output the results?<p>Okay. I don't know if this question has already been answered, but from what I searched up, it hasn't...?</p>
<p>So, my question is, how do I search the MySQL Database with multiple PHP Keywords?</p>
<p>Let's assume that this is my Da... | <p>Speaking only of MySQL you could do something like</p>
<pre class="lang-sql prettyprint-override"><code>SELECT * FROM Anime WHERE Session_ID IN (1,2);
</code></pre>
<p>You can also add <code>AND|OR</code> clauses</p>
<pre class="lang-sql prettyprint-override"><code>SELECT * FROM Anime WHERE Session_ID IN (1,2) AND D... | How to I search the MySQL Database with multiple PHP Arrays and output the results? | php|mysql | 0 | 19 | 1 | 71,864,422 | 71,864,422 | 0 | true | 2022-04-13T22:11:21.163Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to I search the MySQL Database with multiple PHP Arrays and output the results?<p>Okay. I don't know if this question has already been answered, but from... |
71,864,027 | ASM Issue with input/division calculation<p>I don't know why I can't get the desired output for division (rediv specifically). For multiplication, I got my desired output. Fortunately, I got the desired output for recar/carry. Man, it is frustrating because I have no idea why I'm not getting it right with rediv. Below ... | <blockquote>
<pre><code>mov ah,1
int 21h
mov temp3,ax <<<< This is the problem!
</code></pre>
</blockquote>
<blockquote>
<pre><code>mov ax,temp3
sub ax,48
mov bl,temp2
sub bl,48
div bl
</code></pre>
</blockquote>
<p>Your division is using an <code>AX</code> register that is too big!<br />
Returning fro... | ASM Issue with input/division calculation | assembly|x86-16 | 0 | 31 | 1 | 71,864,457 | 71,864,457 | 0 | true | 2022-04-13T21:30:37.417Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
ASM Issue with input/division calculation<p>I don't know why I can't get the desired output for division (rediv specifically). For multiplication, I got my d... |
71,864,160 | android shared data between onListItemClick (list, id) and listener<p>This is activity 1, here I do the implementation of my listener the method "onFabClick()"</p>
<pre><code>@Override
public void onFabClick() {
Intent intent = TimeOffRequestDetailsActivity.getActivityIntent(this);
intent.putExtra(Bun... | <p>You can modify the <code>onFabClick</code> to take the id as parameter and send it as extra when opening activity 2 like</p>
<pre><code>@Override
public void onFabClick(int id) {
Intent intent =
TimeOffRequestDetailsActivity.getActivityIntent(this);
intent.putExtra(BundleKeys.MODE_TIME_OFF,
... | android shared data between onListItemClick (list, id) and listener | android | 0 | 14 | 1 | 71,864,794 | 71,864,794 | 0 | true | 2022-04-13T21:47:42.570Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
android shared data between onListItemClick (list, id) and listener<p>This is activity 1, here I do the implementation of my listener the method "onFabC... |
71,835,764 | return zero instead of nothing when no rows in the corresponding index, and slicing from a list of tuples<p>I have two questions:
the first one:
I have the following code</p>
<pre><code>count_by_week=df[df['institution_id']==1].groupby(['group_ident','Year','Week'],observed=True, as_index=True)['activity_id','Teacher_I... | <p>I figured out the solution for the first question:
the last line should be modified be using reindex() function:</p>
<pre><code>count_by_week.loc[count_by_week.index.isin(lw),:].reindex((i for i in lw),fill_value=0)
</code></pre>
<p>this will make the code return zero when no instances in the corresponding indexes.... | return zero instead of nothing when no rows in the corresponding index, and slicing from a list of tuples | python|pandas|indexing|is-empty | 0 | 34 | 2 | 71,865,230 | 71,865,230 | 0 | true | 2022-04-12T00:47:04.473Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
return zero instead of nothing when no rows in the corresponding index, and slicing from a list of tuples<p>I have two questions:
the first one:
I have the f... |
71,865,555 | Beginner confusion on JavaScript syntax regarding nested object function<p>I ran into an odd problem in this older forum with no explanation for why it works (<a href="https://hashnode.com/post/how-to-create-nested-child-objects-in-javascript-from-array-cj9tsc3we01m0uowu4pyuesy0" rel="nofollow noreferrer">https://hashn... | <p>Logging the node inside the loop will give you an empty object because you're always assigning an empty object to it in the loop. If you're trying to figure things out, log the <code>list</code> instead, because that's the top-level object inside which everything else is assigned.</p>
<p>This:</p>
<pre><code>node = ... | Beginner confusion on JavaScript syntax regarding nested object function | javascript|arrays|nested|nested-lists | 0 | 28 | 2 | 71,865,581 | 71,865,581 | 0 | true | 2022-04-14T01:44:04.257Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Beginner confusion on JavaScript syntax regarding nested object function<p>I ran into an odd problem in this older forum with no explanation for why it works... |
71,215,244 | TFS: Working on new feature but want to retain changes that is not ready for check-in<p>I have made some changes, Feature A that is done shelved and sent for code review.
While Feature A is being reviewed, I want to start working on Feature B, at the same time, I wish to have the changes Feature A available when I'm w... | <p>So my workflow now is to shelve Feature B and remove the changes from local before checkin Feature A changes.
Once checkin, Feature B gets unshelved and life goes on.</p> | TFS: Working on new feature but want to retain changes that is not ready for check-in | tfs | 0 | 13 | 1 | 71,866,160 | 71,866,160 | 0 | true | 2022-02-22T02:29:26.320Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
TFS: Working on new feature but want to retain changes that is not ready for check-in<p>I have made some changes, Feature A that is done shelved and sent for... |
71,866,400 | button turn sideways anchor<p>I have a button that I am quite content with, and it animates well. However, I wish to rotate it 90 degrees to have it face down instead. I used <code>transform: rotate(90deg);</code>. However, this sorta skews it and the button moves to the right when hovered. Can anyone help? Here is my ... | <p>What I have found that is causing this kind of visual bugs is the way the transform origin is set.</p>
<p>In this case, you can set a <code>transform-origin: left</code> and it will make it transform correctly. Take a look:</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="... | button turn sideways anchor | html|css|button|rotation | 0 | 24 | 2 | 71,866,601 | 71,866,601 | 0 | true | 2022-04-14T04:04:40.583Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
button turn sideways anchor<p>I have a button that I am quite content with, and it animates well. However, I wish to rotate it 90 degrees to have it face dow... |
71,869,201 | I am trying to seperate the numbers to odd and even and then pass to to the url path using variable in jmeter<p>I have a get request from where I am taking all the id values , using json extractor I have extracted and named it id and used match number as -1</p>
<p>Now I want to pass this id variable into a post url pat... | <p>The <a href="https://jmeter.apache.org/usermanual/functions.html" rel="nofollow noreferrer">function or variable</a> you put in the If Controller must evaluate to <code>true</code>, only this way the If Controller will run its children. In your case you're providing just a string.</p>
<p>You need to wrap it into i.e... | I am trying to seperate the numbers to odd and even and then pass to to the url path using variable in jmeter | json|jmeter | 0 | 31 | 1 | 71,869,337 | 71,869,337 | 0 | true | 2022-04-14T09:13:46.360Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
I am trying to seperate the numbers to odd and even and then pass to to the url path using variable in jmeter<p>I have a get request from where I am taking a... |
71,869,471 | Cannot register. Username and password did not pass in the payload when using useRef<p>I tried to pass the username and password using useRef() to be able to register but after submit it, it said required username and password. I check the network payload at browser, it only has email without username and password.</p>... | <p>You're trying to access state that hasn't update yet.</p>
<p>If you're using refs, you can remove the useState hooks and change your code to something like below.</p>
<pre><code>const handleFinish = async (e) => {
e.preventDefault();
try {
await axios.post("auth/register", { username: usernameRef.curr... | Cannot register. Username and password did not pass in the payload when using useRef | reactjs | 0 | 14 | 1 | 71,869,824 | 71,869,824 | 0 | true | 2022-04-14T09:37:05.690Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Cannot register. Username and password did not pass in the payload when using useRef<p>I tried to pass the username and password using useRef() to be able to... |
71,867,002 | Images not getting displayed under Lightbox gallery function in R shiny<p>I'm trying to get input from the User( a bunch of images) and then display them on R shiny using Lightbox gallery. Unfortunately I'm unable to get the images, Please help with this regard,Thank you in advance for your help .</p>
<p>below is my c... | <p>The code below works. I removed the nesting of how you prepare the output for better readability.</p>
<p>I think the main problem was that you read the image files from a directory outside <code>www</code> in your project folder. I would keep everything in there. This makes it easier. Take a look at the code: when t... | Images not getting displayed under Lightbox gallery function in R shiny | r|shiny | 0 | 31 | 1 | 71,870,118 | 71,870,118 | 0 | true | 2022-04-14T05:46:19.043Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Images not getting displayed under Lightbox gallery function in R shiny<p>I'm trying to get input from the User( a bunch of images) and then display them on ... |
71,865,915 | how to publish a docker container port to one of the random available port in the host<p>I tried to do the following:</p>
<pre><code>docker run --expose 8765 --publish-all -it nginx
</code></pre>
<p>But this also exposes <code>80</code> along with port <code>8765</code></p>
<pre><code>[root@centos7]# docker port f4b608... | <p>The <code>nginx</code> base image already declares <code>EXPOSE 80</code> and there's no way to un-expose a port, so if you use the <code>docker run -P</code> or <code>--publish-all</code> option to publish every exposed port, it will always be published alongside your manually-exposed port.</p>
<p>You can use the l... | how to publish a docker container port to one of the random available port in the host | docker|containers | 0 | 517 | 1 | 71,870,427 | 71,870,427 | 0 | true | 2022-04-14T02:42:54.083Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
how to publish a docker container port to one of the random available port in the host<p>I tried to do the following:</p>
<pre><code>docker run --expose 8765... |
71,856,114 | Cant set List<String> value from <ui:repeat> var status<p>in my xhtml i define a inputText variable from which i want to set a specific value to a specific field in my List. Every time i click confirm and debug my code the value is returned as "" (that i set in my init function). I have also tried hardcoding ... | <p>I've fixed my issue by adding <code><p:ajax event="blur" process="@this" /></code> into my inputText so it saves the value before i click confirm. So the end code looks like this:</p>
<pre><code><p:inputText value="#{dashboardFilterDialogBean.dashboardObject.texts[loop.index]}"... | Cant set List<String> value from <ui:repeat> var status | java|jsf | 0 | 29 | 1 | 71,870,893 | 71,870,893 | 0 | true | 2022-04-13T10:41:11.813Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Cant set List<String> value from <ui:repeat> var status<p>in my xhtml i define a inputText variable from which i want to set a specific value to a specific f... |
71,800,978 | Ad Mob says that my app contains "Derogatory or dangerous content" and has layout problems after months of no problems<p>I have been using Google Ad Mob for almost three months without any problem, and then all of a sudden my app gets suspended because Google Ad Mob says that my app has the following problems:</p>
<ul>... | <p>UPDATE - SOLVED: I have uploaded a new version of the app in which I changed nothing, just the build and the version numbers, asked Google to check my new submission, and everything was fine. I received an email saying that they checked my app and saying "We have reviewed your app and found no policy violations... | Ad Mob says that my app contains "Derogatory or dangerous content" and has layout problems after months of no problems | swiftui|admob | 0 | 24 | 1 | 71,871,767 | 71,871,767 | 0 | true | 2022-04-08T17:18:42.717Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Ad Mob says that my app contains "Derogatory or dangerous content" and has layout problems after months of no problems<p>I have been using Google Ad Mob for ... |
71,871,907 | Impossible to delete object table "PLAYER_OBJECT",because it doesnt exists or you dont have the right<p>Im getting an error at DROP TABLE but I cant figure out why. My table PLAYER_OBJECT is already coded and working but even if the table is created the error on drop table wont go away. What I my doing wrong.</p>
<p><c... | <p>You could simply put IF EXISTS between TABLE AND PLAYER_OBJECT, like this:</p>
<p><code>DROP TABLE IF EXITS PLAYER_OBJECT</code></p>
<p>You problably have an error in the creation of you table or you didnt launch your code.</p> | Impossible to delete object table "PLAYER_OBJECT",because it doesnt exists or you dont have the right | sql | 0 | 14 | 1 | 71,871,912 | 71,871,912 | 0 | true | 2022-04-14T12:48:30.233Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Impossible to delete object table "PLAYER_OBJECT",because it doesnt exists or you dont have the right<p>Im getting an error at DROP TABLE but I cant figure o... |
71,868,506 | Creating reports for each unique value in column in PowerBI<p>I am trying to find an answer if it possible to automate creating powerBI reports for each unique value in one of columns(It's like filtering on whole report for one of the values and publish report than change value to next one and repeat steps for other va... | <p>This is typically called "Report Bursting", or "Data Driven Subscriptions", and here's a <a href="https://guyinacube.com/2021/04/28/report-bursting-with-the-power-platform/" rel="nofollow noreferrer">walkthrough</a> of how to do it with Power Automate and Power BI.</p> | Creating reports for each unique value in column in PowerBI | powerbi | 0 | 28 | 2 | 71,872,234 | 71,872,234 | 0 | true | 2022-04-14T08:17:18.267Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Creating reports for each unique value in column in PowerBI<p>I am trying to find an answer if it possible to automate creating powerBI reports for each uniq... |
71,870,292 | Reacthook loop traversal occurs many times, rendering speed is very slow<p>I try to show the array in the map loop. Filtergroup is a very large array. When I click to select one of them, the rendering is very slow. How can I solve it? (I tried to use usememo, but it didn't work)</p>
<pre><code>const FilterAccordionItem... | <p>The problem is that you memoize the entire list. This way each state change causes re-rendering of <strong>all</strong> elements instead of re-rendering only those that have their selection changed. What you should try instead is to factor out the code inside the map function into a separate component and wrap that ... | Reacthook loop traversal occurs many times, rendering speed is very slow | reactjs|react-hooks | 0 | 34 | 1 | 71,872,806 | 71,872,806 | 0 | true | 2022-04-14T10:40:03.317Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Reacthook loop traversal occurs many times, rendering speed is very slow<p>I try to show the array in the map loop. Filtergroup is a very large array. When I... |
71,872,712 | Acccessing Pandas series data<p>I am new to python Pandas and I am calculating the RSI Indicator via Python Pandas. I am getting an index series from type float64.</p>
<pre><code>0 100
2 200
</code></pre>
<p>I just need always the last value e.g. 200 but don't know how to get this. I tried to access it via index but no... | <p>If you want to access values of a pandas series you can use</p>
<pre><code>data = pd.Series(closes)
print(data.values[0])
</code></pre> | Acccessing Pandas series data | python|pandas | 0 | 18 | 1 | 71,872,838 | 71,872,838 | 0 | true | 2022-04-14T13:46:48.657Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Acccessing Pandas series data<p>I am new to python Pandas and I am calculating the RSI Indicator via Python Pandas. I am getting an index series from type fl... |
71,870,242 | Routing when there is multiple routing modules<p>I'm trying to create a blog using Angular 13. I want to separate admin from the main page. I have 3 routing modules.
app-routing.module.ts:</p>
<pre><code>import { NgModule } from '@angular/core';
import { RouterModule, Routes } from '@angular/router';
const routes: Rou... | <p>in app module you have</p>
<pre><code>{
path: 'blog',
loadChildren: () => import('./blog/blog.module').then(m => m.BlogModule)
}
</code></pre>
<p>which is the route <code>/blog</code>.</p>
<p>Then in your blog module you have</p>
<pre><code> {
path: 'blog',
component: BlogComponent,
childr... | Routing when there is multiple routing modules | angular|routes|lazy-loading | 0 | 269 | 1 | 71,873,760 | 71,873,760 | 0 | true | 2022-04-14T10:37:13.703Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Routing when there is multiple routing modules<p>I'm trying to create a blog using Angular 13. I want to separate admin from the main page. I have 3 routing ... |
71,851,898 | How to do global query on dynamodb table?<p>Dynamodb is a <code>name - value</code> database and query requires a partition key. I am saving user data in Dyanmodb table but I'd like to know what the best way to do a global search.</p>
<p>My table includes these fields:</p>
<pre><code>id (PK)
firstName
lastName
email
ph... | <blockquote>
<p>One solution I can think of is to create a separate field which has a fixed value for all items. And create a GIS on this field. In this way, I can use the fixed value as PK to query all users. But it will create a hot partition in the table I want to avoid. Is there any other way to do that?</p>
</bloc... | How to do global query on dynamodb table? | amazon-web-services|amazon-dynamodb | 0 | 28 | 1 | 71,874,247 | 71,874,247 | 0 | true | 2022-04-13T04:29:20.267Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to do global query on dynamodb table?<p>Dynamodb is a <code>name - value</code> database and query requires a partition key. I am saving user data in Dya... |
71,874,070 | producer send msg to rabbitmq, when does rabbitmq broker send confirm message? Is before broker storage or after<p>Bg:
Producer send a message to rabbitmq, its true rabbitmq will send a confirm msessage to producer. And rabbitmq will storage the message in exchange,queue. I have a question, when does the rabbitmq store... | <p>Read <a href="https://www.rabbitmq.com/confirms.html#publisher-confirms" rel="nofollow noreferrer">https://www.rabbitmq.com/confirms.html#publisher-confirms</a>. If you use publisher confirms, the broker will send an ack when the message has been stored.</p> | producer send msg to rabbitmq, when does rabbitmq broker send confirm message? Is before broker storage or after | rabbitmq | 0 | 12 | 1 | 71,874,611 | 71,874,611 | 0 | true | 2022-04-14T15:27:38.383Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
producer send msg to rabbitmq, when does rabbitmq broker send confirm message? Is before broker storage or after<p>Bg:
Producer send a message to rabbitmq, i... |
71,874,849 | How to search for a term in a Dataframe and return Yes or no<p>I have written that extracts a data from a API.That data is called <code>cadata</code>. I wanted to check whether a particular text contains in this column - <code>cadata['Source']</code> This column is of 2000 Rows. So what i wanted to do is that tell whet... | <p>I assume that you want add a column to the dataframe, containing the return for each row.</p>
<p>Use <code>contains</code> from string functions to look for a text fragment in each row. This return either <code>True</code> <code>False</code>. With replace you can map the result to yes or no.</p>
<pre><code>cdata['co... | How to search for a term in a Dataframe and return Yes or no | python|pandas|dataframe | 0 | 27 | 1 | 71,874,989 | 71,874,989 | 0 | true | 2022-04-14T16:28:11.233Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to search for a term in a Dataframe and return Yes or no<p>I have written that extracts a data from a API.That data is called <code>cadata</code>. I want... |
71,874,772 | Getting index and dtypes when getting a list from a column<p>I have a dataframe with two columns and I have a statement that I want to fill with the dataframe column values, so I can return a list will all the statements.</p>
<p>I have the following dataframe:</p>
<pre><code>d = {'col1': ['john', 'leo', 'maria', 'zack'... | <pre><code>import pandas as pd
d = {'col1': ['john', 'leo', 'maria', 'zack'], 'col2': ['14','13','45','2']}
df = pd.DataFrame(data=d, index=[0, 1, 2, 3])
df['stt'] = df.apply(lambda x: f"Hello my name is {x['col1']} and I am {x['col2']} years old.", axis=1)
print(df['stt'].tolist())
</code></pre>
<p>Output:... | Getting index and dtypes when getting a list from a column | python|pandas | 0 | 20 | 1 | 71,875,332 | 71,875,332 | 0 | true | 2022-04-14T16:22:34.623Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Getting index and dtypes when getting a list from a column<p>I have a dataframe with two columns and I have a statement that I want to fill with the datafram... |
71,876,867 | How to selectively put quotes around data in SQL Oracle<p>I am trying to load data into a table from a CSV file that I have dumped data into.
The problem is that the CSV file is delimited using | and some of the data has the | character included. Thus, I get an error when loading because some the extra | character is r... | <p>I see two options.</p>
<ol>
<li>change delimiter; it is usually a bad idea to use character that can be found within data</li>
<li>enclose values into double quotes (as you already said). You can do that for all columns, or only for those that cause problems</li>
</ol>
<p>If you use <strong>SQL Loader</strong> to lo... | How to selectively put quotes around data in SQL Oracle | sql|oracle | 0 | 18 | 1 | 71,876,950 | 71,876,950 | 0 | true | 2022-04-14T19:42:06.110Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to selectively put quotes around data in SQL Oracle<p>I am trying to load data into a table from a CSV file that I have dumped data into.
The problem is ... |
71,876,585 | how can i keep the gameobject only move in 90 degree withe another<p><a href="https://i.stack.imgur.com/dTuAj.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/dTuAj.png" alt="enter image description here" /></a></p>
<p>like this, how can I make the white one only move the 90-degree path with the red o... | <p>I hope this is somewhat what you are searching for.</p>
<pre><code>var radius = Vector3.Distance(redObject.transform.position, whiteObject.transform.position) ;
Vector3 direction = Quaternion.Euler(0, angle, 0) * Vector3.right;
var newPosition = redObject.transform.position + direction * radius;
whiteObject.transfor... | how can i keep the gameobject only move in 90 degree withe another | c#|unity3d | 0 | 33 | 2 | 71,877,060 | 71,877,060 | 0 | true | 2022-04-14T19:12:49.903Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
how can i keep the gameobject only move in 90 degree withe another<p><a href="https://i.stack.imgur.com/dTuAj.png" rel="nofollow noreferrer"><img src="https:... |
71,877,266 | Next.js and Nest.js authentification<p>I have a project where I use Next.js on the front-end and Nest.js on the back-end.</p>
<p>I want to use a JWT authentification method via email and password.</p>
<p>My question is:
What is the best way to implement an authentification for Next.js with custom Back-end.</p>
<p>I'm s... | <blockquote>
<p>For now my possible solution is to create a custom axios instance and somehow do the Auth check there.</p>
</blockquote>
<p>Yes. This is the correct way of going about it. Give the token to whatever you use for queries and let it handle it for you.</p>
<p>You have a number of different ways of achieving... | Next.js and Nest.js authentification | reactjs|next.js|nestjs|redux-saga | 0 | 512 | 1 | 71,877,395 | 71,877,395 | 0 | true | 2022-04-14T20:25:26.657Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Next.js and Nest.js authentification<p>I have a project where I use Next.js on the front-end and Nest.js on the back-end.</p>
<p>I want to use a JWT authenti... |
71,877,533 | React app deploy with Heroku not working. Module not found: Error: Can't resolve (...) in "/tmp/build..."<p>Im unable to deploy my react app to Heroku. It returns this error:</p>
<pre><code> ! [remote rejected] master -> master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/di... | <p>Most likely your reference to your assets directory is wrong. While you import source code by referencing relative your current file, you should reference assets as if you are in your public directory.</p>
<p>Assuming you have a structure like</p>
<pre><code> /public/
/assets/
/some.png
index.html
</code></p... | React app deploy with Heroku not working. Module not found: Error: Can't resolve (...) in "/tmp/build..." | reactjs|heroku|deployment|build | 0 | 1,294 | 1 | 71,877,959 | 71,877,959 | 0 | true | 2022-04-14T20:57:37.863Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
React app deploy with Heroku not working. Module not found: Error: Can't resolve (...) in "/tmp/build..."<p>Im unable to deploy my react app to Heroku. It re... |
71,878,701 | Creating centered widgets Reactjs<p>I want to create 3 widgets that are are equal in width and height and equal distance from each other, I understand that I must use CSS flexbox but not 100% where to start</p>
<p>Any help would be appreciated!</p> | <p>You can do this by creating a <code>div</code> with attributes <code>display: flex</code> and <code>flex-direction: row</code>. Then inside this <code>div</code>, create 3 smaller divs with your <code>width</code> and <code>height</code>, then you can use <code>column-gap</code> to create the gap between your widget... | Creating centered widgets Reactjs | html|css|flexbox | 0 | 23 | 2 | 71,878,715 | 71,878,715 | 0 | true | 2022-04-14T23:49:00.960Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Creating centered widgets Reactjs<p>I want to create 3 widgets that are are equal in width and height and equal distance from each other, I understand that I... |
71,878,766 | How to read n to n + i lines in c++?<p>This is the file to be read</p>
<blockquote>
<pre><code>5
Name1
Name2
Name3
Name4
Name5
</code></pre>
</blockquote>
<p>My current code to read this is:</p>
<pre class="lang-cpp prettyprint-override"><code>void readData(string fileName, string names[], int n) {
ifstream myFile(... | <p>You didnt read the whole first line when you did <code>myFile >> n</code>. So the first getline just read the rest of that line, which is empty</p>
<p>Do</p>
<pre><code> myFile >> n;
getline(myFile, line); // read rest of line
</code></pre>
<p>or</p>
<pre><code> getline(myFile, line); // read whole lin... | How to read n to n + i lines in c++? | c++|file|ifstream|getline | 0 | 21 | 1 | 71,878,828 | 71,878,828 | 0 | true | 2022-04-15T00:04:34.660Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to read n to n + i lines in c++?<p>This is the file to be read</p>
<blockquote>
<pre><code>5
Name1
Name2
Name3
Name4
Name5
</code></pre>
</blockquote>
<p... |
71,168,108 | How To Access Repository Secret<p>I've made a repository on GitHub and have added a Repository secret. However, I can't seem to grab the secret's value. Any help would be greatly appreciated!</p> | <p>So I made a workaround for this. Instead of using GitHub to store my secrets, I used a <code>.env</code> file and <code>.gitignore</code> to hide this file.</p>
<p>Giving a TOKEN value in the <code>.env</code> file, I call it within Python by importing <code>os</code> and <code>dotenv</code> like so:</p>
<pre><code>... | How To Access Repository Secret | python|python-3.x|github|operating-system|environment-variables | 0 | 36 | 1 | 71,879,613 | 71,879,613 | 0 | true | 2022-02-18T03:34:55.777Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How To Access Repository Secret<p>I've made a repository on GitHub and have added a Repository secret. However, I can't seem to grab the secret's value. Any ... |
71,880,655 | Calculate new MultiIndex level from existing MultiIndex level values<p>For a DataFrame with two MultiIndex levels <code>age</code> and <code>yearref</code>, the goal is to add a new MultiIndex level <code>yearconstr</code> calculated as <code>yearconstr = yearref - age</code>.</p>
<pre><code>import pandas as pd
df = p... | <p>For a concise and straight-forward approach, we can make use of</p>
<ul>
<li><a href="https://pandas.pydata.org/docs/reference/api/pandas.DataFrame.eval.html" rel="nofollow noreferrer"><code>eval</code></a> to generate a new Series calculated from the existing MultiIndex. This is easy since it treats index levels ju... | Calculate new MultiIndex level from existing MultiIndex level values | python|pandas|dataframe|multi-index | 0 | 30 | 1 | 71,880,656 | 71,880,656 | 0 | true | 2022-04-15T06:07:35.070Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Calculate new MultiIndex level from existing MultiIndex level values<p>For a DataFrame with two MultiIndex levels <code>age</code> and <code>yearref</code>, ... |
71,880,837 | The size of the image input to the neural network is abnormal<p>I need to input a 96 * 96 size picture to the network, but I get this exception:</p>
<pre><code>Model: "model"
_________________________________________________________________
Layer (type) Output Shape Param #
===... | <p>You need to pass numpy array into <code>model.predict</code> like this:</p>
<pre><code>predict = model.predict(np.array([image]))[0]
print(predict)
</code></pre>
<p>(Note that [0] at the end takes the first value of the output, because we passed array of only one value)</p> | The size of the image input to the neural network is abnormal | python|tensorflow|keras|deep-learning | 0 | 35 | 1 | 71,881,022 | 71,881,022 | 0 | true | 2022-04-15T06:35:00.643Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
The size of the image input to the neural network is abnormal<p>I need to input a 96 * 96 size picture to the network, but I get this exception:</p>
<pre><co... |
71,874,467 | Docker permissions with base image for non-root user<p>I have a base image that does a couple of installments with root permission, then create a new user, change owner of the <code>WORKDIR</code> then switch to the user. The child image will inherit this image with <code>FROM</code> and run its Python task as user.</p... | <p>I found the solution, just simply create the subfolder before setting it as <code>WORKDIR</code> in child image</p>
<pre><code>RUN mkdir worker
WORKDIR /master/worker
</code></pre> | Docker permissions with base image for non-root user | docker|permissions|chown | 0 | 277 | 1 | 71,881,072 | 71,881,072 | 0 | true | 2022-04-14T15:57:46.697Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Docker permissions with base image for non-root user<p>I have a base image that does a couple of installments with root permission, then create a new user, c... |
71,874,525 | How does BestMatch findall decide how many results to return?<p>I'm struggling to predict how many fuzzy matches <code>findall()</code> will return when using <code>regex</code> in Python with <code>BESTMATCH</code> enabled:</p>
<pre><code>>>> regex.findall(r'(?b)(North\ West){i<=0,s<=2,d<=1}', "... | <p>I think I have a partial explanation:</p>
<p>The behaviour appears to be:</p>
<ul>
<li>Return all perfect matches (with no substitutions, insertions or deletions)</li>
<li>Return all imperfect matches AFTER the last perfect match</li>
</ul>
<p>It appears (through testing), that <code>BESTMATCH</code> behaves like a ... | How does BestMatch findall decide how many results to return? | python|regex|python-regex | 0 | 31 | 1 | 71,881,259 | 71,881,259 | 0 | true | 2022-04-14T16:02:11.050Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How does BestMatch findall decide how many results to return?<p>I'm struggling to predict how many fuzzy matches <code>findall()</code> will return when usin... |
71,880,401 | Why parent component doesn't update when save form with spread operator ,but when use "push" it works ..Angular<p>When I Use [...this.characters, this.new] .. in characters.component.html doesn't update the list, but when I use this.characters.push( this.new) it works ...Why?</p>
<pre><code>//add.component.ts
import {... | <p>This is because of memory references.</p>
<p>You start with <code>MainPageComponent</code> where you declare an array of characters. We will call this, <code>memRef0</code>.</p>
<p>You then send it through an Input, into your components. So <code>memRef0</code> is applied to the components inputs. In <code>AddCompon... | Why parent component doesn't update when save form with spread operator ,but when use "push" it works ..Angular | javascript|angular | 0 | 33 | 1 | 71,881,860 | 71,881,860 | 0 | true | 2022-04-15T05:23:49.907Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why parent component doesn't update when save form with spread operator ,but when use "push" it works ..Angular<p>When I Use [...this.characters, this.new] .... |
71,881,856 | Find method not working for transform property<p>There are three divs and each of them got a different value of the <code>transform</code> property.</p>
<p>I save them into a variable by <code>getElementsByClassName</code> and then use the <code>find</code> method to find the element in which the <code>transform</code>... | <p>Your transform values will be converted to <a href="https://developer.mozilla.org/en-US/docs/Web/CSS/transform-function/matrix" rel="nofollow noreferrer">matrix values</a></p>
<blockquote>
<p>The values represent the following functions: matrix( scaleX(), skewY(), skewX(), scaleY(), translateX(), translateY() )</p>
... | Find method not working for transform property | javascript|css | 0 | 25 | 1 | 71,881,918 | 71,881,918 | 0 | true | 2022-04-15T08:41:32.473Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Find method not working for transform property<p>There are three divs and each of them got a different value of the <code>transform</code> property.</p>
<p>I... |
71,873,124 | How to add different tags to all elements of a list of user-defined dataclasses, when attempting to insert the list in influxdb using one call<p>I'm trying to insert an whole list of user-defined dataclasses in my influxdb server, and provide different tags to each, while also using <strong>a single write call</strong>... | <p>I was waylaid by how the <a href="https://aioinflux.readthedocs.io/en/stable/api.html#aioinflux.client.InfluxDBClient.write" rel="nofollow noreferrer">write</a> function is structured. Basically, it seems that its <code>extra_tags</code> argument has no effect on user-defined dataclass objects.</p>
<p>After doing a ... | How to add different tags to all elements of a list of user-defined dataclasses, when attempting to insert the list in influxdb using one call | python|python-asyncio|influxdb|aioinflux | 0 | 28 | 1 | 71,882,407 | 71,882,407 | 0 | true | 2022-04-14T14:18:21.520Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to add different tags to all elements of a list of user-defined dataclasses, when attempting to insert the list in influxdb using one call<p>I'm trying t... |
71,878,969 | AlarmMgr triggered sometime correct and sometimes wrong, Why?<p>I set the alarmMgr like this:</p>
<pre><code>alarmMgr.setRepeating(AlarmManager.RTC, calendar.getTimeInMillis(),
1000 * 60 * 5L, alarmIntent)
</code></pre>
<p>and BroadcastReceiver output</p>
<pre><code>public class BroadcastReciever extend... | <ul>
<li>As of API 19, all repeating alarms are inexact. If your application needs precise delivery times then it must use one-time exact alarms, rescheduling each time as described above. Legacy applications whose targetSdkVersion is earlier than API 19 will continue to have all of their alarms, including repeating al... | AlarmMgr triggered sometime correct and sometimes wrong, Why? | android|alarmmanager|logcat | 0 | 32 | 1 | 71,882,955 | 71,882,955 | 0 | true | 2022-04-15T00:48:03.897Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
AlarmMgr triggered sometime correct and sometimes wrong, Why?<p>I set the alarmMgr like this:</p>
<pre><code>alarmMgr.setRepeating(AlarmManager.RTC, calendar... |
71,883,009 | How to connect db ID to a db Value in javascript?<p>So I got a function that executes every X minutes/hours, when it executes it will select a random database array value, when it does, the selected will get + 1. Selected stands for the amount of times the row has been selected.</p>
<pre><code>id: 5 name: tom selected:... | <p>In the function removeMax(), the data is reduced to become just a list of the <em>selected</em> values. You would need to keep each item, not only the number of times it is selected.</p>
<p>Original code:</p>
<pre><code>function removeMax() {
const max = Math.max(result_arr.map(item => item.selected));
co... | How to connect db ID to a db Value in javascript? | javascript|mysql | 0 | 34 | 1 | 71,883,233 | 71,883,233 | 0 | true | 2022-04-15T10:39:04.020Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to connect db ID to a db Value in javascript?<p>So I got a function that executes every X minutes/hours, when it executes it will select a random databas... |
71,857,054 | Uncaught TypeError: Cannot read properties of undefined (reading 'success')<p>I am trying to resolve this next problem in which I am calling an external API to our website and embedding it into an iframe.</p>
<p>For doing so, I am passing an <code>addEventListener</code> to my window so that it invokes the function <co... | <p>I finally found the answer to the solution.
I just assigned <code>allow="camera *;microphone *"</code> to my iframe like this and it works like a charm:</p>
<pre><code> <iframe id="iframeTrial" src="" allow="camera *;microphone *"></iframe>
</code></pre>
<p>The abo... | Uncaught TypeError: Cannot read properties of undefined (reading 'success') | javascript|c#|html|.net | 0 | 779 | 1 | 71,883,416 | 71,883,416 | 0 | true | 2022-04-13T11:52:50.013Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Uncaught TypeError: Cannot read properties of undefined (reading 'success')<p>I am trying to resolve this next problem in which I am calling an external API ... |
71,883,467 | Launching activity from the background, doesn't run the function in onResume()<p>In my application, when the app stops recording audio it launches another activity and runs the function automaticSync() in the onResume(), but when the device is locked it does not run the function from the background, is there a way to r... | <p><a href="https://developer.android.com/guide/components/activities/activity-lifecycle#onresume" rel="nofollow noreferrer">OnResume</a> is the state in which the app interacts with the user. It's called when the app is in the foreground. As you said <em>"when the device is locked it does not run the function fro... | Launching activity from the background, doesn't run the function in onResume() | java|android|android-studio|android-activity | 0 | 35 | 2 | 71,883,622 | 71,883,622 | 0 | true | 2022-04-15T11:27:49.390Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Launching activity from the background, doesn't run the function in onResume()<p>In my application, when the app stops recording audio it launches another ac... |
71,879,008 | How to create a function that will add blocks to a grid?<p>I have this code that creates a 15x12 grid of blocks, but I am trying to access the index of each block and be able to remove or add blocks at that given index. I think I need to use a 2d array, but I am not sure how to add the blocks to an array that will make... | <p>Let's follow the idea you proposed.</p>
<h2>Step 1</h2>
<p>We can create a Dictionary were we map the index of a node (in the key) with the node (in the value).</p>
<pre><code>struct Index: Hashable {
let i: Int
let j: Int
}
private var grid:[Index: SKNode] = [:]
</code></pre>
<h2>Step 2</h2>
<p>Now when you... | How to create a function that will add blocks to a grid? | swift|sprite-kit|skspritenode | 0 | 23 | 1 | 71,884,668 | 71,884,668 | 0 | true | 2022-04-15T00:56:25.053Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to create a function that will add blocks to a grid?<p>I have this code that creates a 15x12 grid of blocks, but I am trying to access the index of each ... |
71,884,571 | Change input name according to a specific button in JS<p>I'm trying to create or import some datas</p>
<p>If data exist, I'm displaying the import button and if didn't exist, displaying the create button.
I'm working with autocomplete (jquery-ui)</p>
<p>So this is my html :</p>
<pre><code> <input name="Test&... | <p>Yes you can change the value of the <code>name</code> attribute using the <a href="https://api.jquery.com/attr/" rel="nofollow noreferrer"><code>attr()</code></a> method :</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snipp... | Change input name according to a specific button in JS | javascript|html|jquery | 0 | 31 | 1 | 71,884,700 | 71,884,700 | 0 | true | 2022-04-15T13:21:20.823Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Change input name according to a specific button in JS<p>I'm trying to create or import some datas</p>
<p>If data exist, I'm displaying the import button and... |
71,819,432 | Docker compose can't correct build react app<p>I have api (net-core) and react-app projects in root folder. I start dockerize my project from react application. If docker-compose and docker file in same react-app folder, dockerize works correct. But i want in future start two docker from root folder. This my folder str... | <p>I resolved error. Need to change Workdir /usr/src/app. Now my files are like this:</p>
<pre><code>FROM node:alpine
WORKDIR /usr/src/app
ENV PATH="./node_modules/.bin:$PATH"
COPY ./client-app/package*.json .
RUN npm install
COPY ./client-app/ .
RUN npm run build
version: "3.4"
services:
app:
... | Docker compose can't correct build react app | reactjs|docker|docker-compose|dockerfile | 0 | 283 | 2 | 71,884,742 | 71,884,742 | 0 | true | 2022-04-10T18:27:23.340Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Docker compose can't correct build react app<p>I have api (net-core) and react-app projects in root folder. I start dockerize my project from react applicati... |
71,883,611 | How to enforce Webpack to detect and recompile only files that were changed?<p>Is there (and should) be a way to tell Webpack to recompile just those changed that were made?</p>
<p>Webpack needs to recompile just the element that was added.</p> | <p>For live reloading there is e.g. <code>webpack-dev-server</code></p>
<p>For improving build speed, take look at <a href="https://webpack.js.org/configuration/cache" rel="nofollow noreferrer">https://webpack.js.org/configuration/cache</a> to cache certain information on disk.</p> | How to enforce Webpack to detect and recompile only files that were changed? | node.js|webpack | 0 | 27 | 1 | 71,885,415 | 71,885,415 | 0 | true | 2022-04-15T11:45:10.787Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to enforce Webpack to detect and recompile only files that were changed?<p>Is there (and should) be a way to tell Webpack to recompile just those changed... |
71,884,978 | my program is not responding to any request get nor post but database is correctly connected and everything else is working properly with no error<pre><code>const express = require("express")
const app =express()
const mongoose =require("mongoose");
const cors=require('cors');
const FeedbackModel=re... | <p>You are using <a href="https://www.npmjs.com/package/cors" rel="nofollow noreferrer">cors</a> package incorrectly.</p>
<p>It has to be called and then it returns whatever value is necessary to the middleware.</p>
<p>Imagine a function that returns a function, the first has to be called to reach the second one.</p>
<... | my program is not responding to any request get nor post but database is correctly connected and everything else is working properly with no error | node.js|mongodb|express | 0 | 22 | 1 | 71,885,440 | 71,885,440 | 0 | true | 2022-04-15T14:00:51.040Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
my program is not responding to any request get nor post but database is correctly connected and everything else is working properly with no error<pre><code>... |
71,885,449 | Send messages between apps within same browser window<p>I have two separate web apps, an angular parent app and a react child app. The parent app is loading the child app in an iframe. I am trying to have these apps talk to each other using <code>window.postMessage()</code> but either the message isn't being properly s... | <p>The parent must dispatch the message from the <code>window</code> of the target (child process, iframe in your case) not from the <code>window</code> object of the parent:</p>
<pre><code>const child = document.querySelector('iframe').contentWindow;
child.postMessage(message, "*")
</code></pre> | Send messages between apps within same browser window | javascript|typescript|dom | 0 | 34 | 1 | 71,885,641 | 71,885,641 | 0 | true | 2022-04-15T14:44:10.110Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Send messages between apps within same browser window<p>I have two separate web apps, an angular parent app and a react child app. The parent app is loading ... |
71,885,234 | Custom product note on checkout but only to products with specific stock status<p>I have created a custom stock status for preorders.</p>
<p>How can I make custom notes appear on checkout next to products, but only one with the status 'Preorder'?</p>
<p>I mean something like this. <a href="https://i.stack.imgur.com/ZRN... | <pre><code>add_filter('woocommerce_cart_item_name', 'woocommerce_cart_item_extra', 10, 3);
function woocommerce_cart_item_extra($item_name, $cart_item, $cart_item_key) {
if ('preorder' === $cart_item['data']->get_stock_status()) {
$release_attr = $cart_item['data']->get_attribute('pa_release');
... | Custom product note on checkout but only to products with specific stock status | php|woocommerce|product|hook-woocommerce|checkout | 0 | 33 | 1 | 71,886,016 | 71,886,016 | 0 | true | 2022-04-15T14:23:36.393Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Custom product note on checkout but only to products with specific stock status<p>I have created a custom stock status for preorders.</p>
<p>How can I make c... |
71,886,603 | Keep the indexes on an array<p>How can I change the following code so the <code>keys</code>of <code>$result</code> will not get overwritten by <code>[0], [1], ...</code> but instead be kept the way they were?</p>
<pre><code>$result = array_map(function($key, $value) {
return preg_replace("/(".$_POST['key... | <p>Use <code>array_walk</code>(<a href="https://www.php.net/manual/en/function.array-walk.php" rel="nofollow noreferrer">docs</a>) instead of <code>array_map</code> it will preserve keys:</p>
<pre class="lang-php prettyprint-override"><code>array_walk($result, function(&$key, $value) {
$key = preg_replace("... | Keep the indexes on an array | php|indexing|array-map | 0 | 23 | 1 | 71,886,920 | 71,886,920 | 0 | true | 2022-04-15T16:34:49.367Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Keep the indexes on an array<p>How can I change the following code so the <code>keys</code>of <code>$result</code> will not get overwritten by <code>[0], [1]... |
71,886,959 | Why Can't I Add The Same Image To Shopping Cart More Than Once<p>What I'm trying do is when the user adds item to cart more than once I would like it to be a separate image instead of just adding to the quantity. I have it now where if product exist in the cart it just adds to the quantity. The reason I need this chan... | <p>Are you sure you tried to modify the code?
In this chunk you are doing the quantity of the product and setting the flag for pushing or not the item with the image</p>
<pre><code>for(let i in cartItems){
if(cartItems[i].productId === item.product.id){
cartItems[i].qty++
productExists = true
... | Why Can't I Add The Same Image To Shopping Cart More Than Once | html|angular|typescript | 0 | 24 | 2 | 71,887,030 | 71,887,030 | 0 | true | 2022-04-15T17:14:30.177Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why Can't I Add The Same Image To Shopping Cart More Than Once<p>What I'm trying do is when the user adds item to cart more than once I would like it to be a... |
71,829,339 | SQFlite Database Order (ASC, DESC, Alphabetic)<p>I have created a SQFlite database for my app which is working very well. Basically, the app is to create a list of my client's company details. The company name appears in an Expansion Tile, and once you open the tile, you see the rest of the company's details. I know ho... | <p>Ok, I managed to figure this out. My question really shows my inexperience. Anyway, Query has a orderBy property. In my database I created the following code:</p>
<pre><code>Future<void> _createDB(Database db, int version) async {
await db.execute('''
CREATE TABLE todo(
id INTEGER PRIMARY KEY AUTOINCREME... | SQFlite Database Order (ASC, DESC, Alphabetic) | sql-order-by|sqflite | 0 | 30 | 1 | 71,887,094 | 71,887,094 | 0 | true | 2022-04-11T14:12:21.810Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
SQFlite Database Order (ASC, DESC, Alphabetic)<p>I have created a SQFlite database for my app which is working very well. Basically, the app is to create a l... |
71,888,371 | Using recursion to concatenate two strings<p>My goal is to concatenate two strings using recursion.</p>
<p>The input would be str1 = ("long string") str2 = ("yes so long")</p>
<p>and the output would be: 'lyoensg ssto rlionngg'</p>
<p>Assumptions are that both strings are the same length.</p>
<p>My ... | <pre class="lang-py prettyprint-override"><code>def concat_strings_rec(str1, str2):
if len(str1) < 1:
return ""
else:
curStr = str1[0] + str2[0]
return curStr + concat_strings_rec(str1[1:], str2[1:])
def concat_string_iter(str1, str2):
return "".join([str1[i]... | Using recursion to concatenate two strings | python|string|if-statement|recursion|concatenation | 0 | 267 | 3 | 71,888,508 | 71,888,508 | 0 | true | 2022-04-15T19:55:24.790Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Using recursion to concatenate two strings<p>My goal is to concatenate two strings using recursion.</p>
<p>The input would be str1 = ("long string"... |
71,888,860 | Prevent toggleClass to be used on every element on the page<p>I have a function which, when clicking on a link with the class .show-more, opens up the div with the class .productinfo. Now, it also adds a class to the link itself (.active) - the problem what I have is that I have a few links on this page with the same c... | <p>Why not:
$('a.show-more').on('click', function(e)</p>
<p>and then
$(this).toggleClass("active");</p> | Prevent toggleClass to be used on every element on the page | javascript|html|jquery | 0 | 16 | 1 | 71,888,884 | 71,888,884 | 0 | true | 2022-04-15T20:54:27.570Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Prevent toggleClass to be used on every element on the page<p>I have a function which, when clicking on a link with the class .show-more, opens up the div wi... |
71,888,838 | Calculate pixel from coordinates<p>Hello I have this image:</p>
<p><a href="https://i.stack.imgur.com/LMBgL.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/LMBgL.png" alt="enter image description here" /></a></p>
<p>This image has 16 pixels. White is 0, pink 1... like in image. My problem is that I n... | <p>If you know how many pixels per row you have, you can simply use the next formula :</p>
<p><code>(y * numberPerRow) + x</code></p>
<p>Example using a 16 pixels images (4x4)</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>x</th>
<th>y</th>
<th>calcul</th>
<th>value</th>
</tr>
</thead>
<tb... | Calculate pixel from coordinates | coordinates|formula|pixel | 0 | 264 | 1 | 71,888,895 | 71,888,895 | 0 | true | 2022-04-15T20:51:47.823Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Calculate pixel from coordinates<p>Hello I have this image:</p>
<p><a href="https://i.stack.imgur.com/LMBgL.png" rel="nofollow noreferrer"><img src="https://... |
71,889,692 | How to call and pass the value to function from another component<p>I'm trying to call the remove function that is in my ShoppingCartScreen component in my CartList component. I also want to pass in values from the CartList component class. I kept getting issues when I tried to call the add in my CartList class.</p>
<p... | <p>First, you pass <code>remove</code> to the <code>CartList</code> and then inside call <code>this.props.add</code>, so you need to change the name. Second, you need to upgrade <code>this.props.remove</code> call to an arrow function:</p>
<pre><code><TouchableOpacity onPress={() => this.props.remove(this.state.q... | How to call and pass the value to function from another component | javascript|reactjs|react-native | 0 | 33 | 1 | 71,889,859 | 71,889,859 | 0 | true | 2022-04-15T23:00:52.873Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to call and pass the value to function from another component<p>I'm trying to call the remove function that is in my ShoppingCartScreen component in my C... |
71,889,885 | ifelse conditional statement based on the value before and after a particular element<p>How can I create a conditional statement using <code>ifelse()</code> based on the value of a previous or following element in a vector in R?</p>
<pre><code>data ≤– c(NA, NA, 3, NA, 4, 6, 7, 9, NA)
ifelse(conditional statement, NA, d... | <p>I like to use lead and lag functions in dplyr for this. First set your vector in a dataframe.</p>
<pre><code>df <- data.frame(data = data)
df %>%
transmute(result = ifelse(is.na(lag(data)) & is.na(lead(data)), NA, data))
</code></pre> | ifelse conditional statement based on the value before and after a particular element | r|conditional-statements | 0 | 22 | 1 | 71,890,464 | 71,890,464 | 0 | true | 2022-04-15T23:41:28.623Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
ifelse conditional statement based on the value before and after a particular element<p>How can I create a conditional statement using <code>ifelse()</code> ... |
71,887,950 | Replace NULL with the Date in the WHERE clause in Mysql<p>So, in order to get 0s in my count column I have tried out this query which works.</p>
<pre><code>SELECT b.TXT_RECORD_DATE, a.TXT_CALL_TYPE,
SUM(CASE
WHEN b.TXT_CALL_TYPE IS NOT NULL
THEN 1
ELSE 0
END) AS StatusCount
FROM ... | <p>You need to generate a list of the dates you are interested in and <code>CROSS JOIN</code> that to the list of call types; then you can <code>LEFT JOIN</code> that to the call records to get the result you want. In MariaDB you can make use of the <a href="https://mariadb.com/kb/en/library/sequence-storage-engine/" r... | Replace NULL with the Date in the WHERE clause in Mysql | mariadb|mariasql | 0 | 23 | 1 | 71,890,591 | 71,890,591 | 0 | true | 2022-04-15T19:05:14.090Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Replace NULL with the Date in the WHERE clause in Mysql<p>So, in order to get 0s in my count column I have tried out this query which works.</p>
<pre><code>S... |
71,889,967 | Android Java Fragment Data/Layout Transfer<p>Keep getting no view found when calling dialog fragment from another fragment. I am trying to send image location to the dialog fragment to display.</p>
<p>Originating Fragment</p>
<pre><code>mLEFTBUTTON.setOnClickListener(new View.OnClickListener() {
@Override
... | <p>I cannot see you have define you xml or view in dialog fragment.Please add it to render view of your dialog</p>
<pre><code>public class PhotoLeft extends DialogFragment{
@Override
public Dialog onCreateDialog(Bundle savedInstanceState)
{
View view = getActivity()... | Android Java Fragment Data/Layout Transfer | java|android | 0 | 13 | 1 | 71,890,651 | 71,890,651 | 0 | true | 2022-04-15T23:57:11.240Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Android Java Fragment Data/Layout Transfer<p>Keep getting no view found when calling dialog fragment from another fragment. I am trying to send image locatio... |
71,891,320 | Voip Push not Working Production/Development<p>Hi I have successfully integrated Push Kit and call Kit and was working earlier with no code change in recent times, Voip Certs got expired and i created new using developer.apple.com</p>
<p><strong>Voip Push aren't received in the App</strong> and after creating the certi... | <p>Solution was apps_topic mismatch in certificate .voip was there but while using external apps it was just bundle id so, solution was BundleID+.voip</p> | Voip Push not Working Production/Development | ios|apple-push-notifications|voip|keychain|pushkit | 0 | 267 | 1 | 71,891,567 | 71,891,567 | 0 | true | 2022-04-16T05:17:50.960Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Voip Push not Working Production/Development<p>Hi I have successfully integrated Push Kit and call Kit and was working earlier with no code change in recent ... |
71,892,518 | Why does heap allocated data sparsely?<p>Why heap memory is allocated data sparsely.
for example.. in c++ vector can control own size, so To occupy own space to expand size,
heap memory is allocated data sparsely?
I can't understand..</p> | <p>Data allocation mainly depends on the the kernel code.
In a perfect world you could always have allocation made contiguously but in reality at the first deallocation you will have "holes" in your memory.
For this reason the kernel usually doesn't really try to keep everything contiguous across multiple all... | Why does heap allocated data sparsely? | memory-management|heap-memory | 0 | 21 | 1 | 71,892,606 | 71,892,606 | 0 | true | 2022-04-16T08:57:17.063Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why does heap allocated data sparsely?<p>Why heap memory is allocated data sparsely.
for example.. in c++ vector can control own size, so To occupy own space... |
71,891,682 | How to drop rows of dataframe with datetime not increasing<p>I have a dataframe indexed on datetime, with the following output:</p>
<p>2022-04-08 21:59:49 7651.8 7655.8</p>
<p>2022-04-08 21:59:50 7651.7 7655.7</p>
<p>2022-04-08 21:59:54 7651.7 7655.7</p>
<p>2022-04-08 21:59:55 7651.8 7655.8</p>
<p>2022-04-08 09... | <p><code>df.index.to_series().diff() < pd.to_timedelta('0 seconds')</code> returns a boolean Series, you can use boolean indexing to select rows:</p>
<pre class="lang-py prettyprint-override"><code>df = df.loc[~(df.index.to_series().diff() < pd.to_timedelta('0 seconds'))]
</code></pre> | How to drop rows of dataframe with datetime not increasing | pandas | 0 | 27 | 1 | 71,892,705 | 71,892,705 | 0 | true | 2022-04-16T06:41:51.550Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to drop rows of dataframe with datetime not increasing<p>I have a dataframe indexed on datetime, with the following output:</p>
<p>2022-04-08 21:59:49 7... |
71,893,092 | terrafor from - create 3 server over 2 subnets using count<p>In terraform, I wish to create 3 servers while I'm having 2 subnets.
Creating 2 servers according to the below code will route both server and subnet ID according to the count - But what if I want 3 servers? I don't mind on which of the subnet the third serve... | <p>Normally you would use <a href="https://www.terraform.io/language/functions/element" rel="nofollow noreferrer">element</a> to wrap-around indexing:</p>
<pre><code>subnet_id = element(var.private_subnet_id, count.index)
</code></pre> | terrafor from - create 3 server over 2 subnets using count | amazon-web-services|terraform|terraform-provider-aws | 0 | 30 | 1 | 71,893,127 | 71,893,127 | 0 | true | 2022-04-16T10:29:07.243Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
terrafor from - create 3 server over 2 subnets using count<p>In terraform, I wish to create 3 servers while I'm having 2 subnets.
Creating 2 servers accordin... |
71,891,533 | Can't use Context Provider properly<p>VolumeContext --</p>
<pre><code>const VolumeContext = React.createContext<IVolume>({volume: 1});
export default VolumeContext;
</code></pre>
<p>Interface --</p>
<pre><code>export interface IVolume {
volume: number;
}
</code></pre>
<p>Volume --</p>
<pre><code>import { useSta... | <p>Set volume value range between [0-1] here</p>
<pre><code>audioTag.current.volume = volume;
</code></pre> | Can't use Context Provider properly | reactjs|typescript | 0 | 35 | 2 | 71,893,538 | 71,893,538 | 0 | true | 2022-04-16T06:11:59.937Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Can't use Context Provider properly<p>VolumeContext --</p>
<pre><code>const VolumeContext = React.createContext<IVolume>({volume: 1});
export default V... |
71,894,463 | While setting my welcome channel ID to mongodb why my last two digit changes<p>When i am trying to set my welcome channel ID to MongoDB Why my channel last two digit chages to "<strong>00</strong>"
for example
<code>954226649841430572 --> (when i send to database it changes to) 954226649841430500</code></... | <p>In MongoDB large numbers can sometimes be cut due to the nature of storing large Ints. Instead of saving the value raw as a number, first use the <code>.toString()</code> method and store the value as a string. This will eliminate the issue of MongoDB cutting off large Ints and because JS is dynamically typed will h... | While setting my welcome channel ID to mongodb why my last two digit changes | javascript|node.js|mongodb|mongoose|discord.js | 0 | 25 | 1 | 71,894,535 | 71,894,535 | 0 | true | 2022-04-16T13:55:30.687Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
While setting my welcome channel ID to mongodb why my last two digit changes<p>When i am trying to set my welcome channel ID to MongoDB Why my channel last ... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.