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 |
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
72,962,301 | How to make a 3 ✕ 3 grid using HTML and Css<p>I have 20 element for a grid view. But I want only 3✕3 grid view, where there will be only 9 element in the view window. And the rest of the element should be placed in the right side of the window as a scrollable asset.**</p>
<p>No matter what the screen size is I want to ... | <p>In this case the grid should flow vertically. And you can set it up like this with some calculation:</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>.cards {
/* how many... | How to make a 3 ✕ 3 grid using HTML and Css | javascript|html|css|reactjs | 0 | 73 | 4 | 72,962,390 | 72,962,390 | 2 | true | 2022-07-13T07:16:48.367Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to make a 3 ✕ 3 grid using HTML and Css<p>I have 20 element for a grid view. But I want only 3✕3 grid view, where there will be only 9 element in the vie... |
72,859,513 | C linked list - head is always NULL<p>I want to implement a simple linked list in C. However I only have access to the list element locally, inside the list_append function, but not inside the main-function.</p>
<pre><code>#include <stdio.h>
#include <stdlib.h>
typedef struct list_element {
struct list... | <p>I will address the problem from a slightly different perspective. Let's look at these lines one by one:</p>
<pre><code>int list_append(list_t *list, int value) {
</code></pre>
<p>So far, we know that <code>list</code> is a pointer. It may point at something or it may be <code>NULL</code>. Chances are, it does point ... | C linked list - head is always NULL | c|list|pointers|scope | 0 | 73 | 2 | 72,860,709 | 72,860,709 | 2 | true | 2022-07-04T16:10:41.153Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
C linked list - head is always NULL<p>I want to implement a simple linked list in C. However I only have access to the list element locally, inside the list_... |
72,950,868 | How to add a missing closing parenthesis to a string in R?<p>I would like to add a closing parenthesis to strings that have an open parenthesis but are missing a closing parenthesis.
For instance, I would like to modify "The dog walked (ABC in the park" to be "The dog walked (ABC) in the park".</p>
... | <p>Try this</p>
<pre><code>stringr::str_replace_all(text, '\\([A-Z]+(?!\\))\\b', '\\0\\)')
</code></pre>
<ul>
<li>output</li>
</ul>
<pre><code>"The dog walked (ABC) in the park"
</code></pre> | How to add a missing closing parenthesis to a string in R? | r|regex|string | 2 | 73 | 3 | 72,950,981 | 72,950,981 | 2 | true | 2022-07-12T10:31:14.043Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to add a missing closing parenthesis to a string in R?<p>I would like to add a closing parenthesis to strings that have an open parenthesis but are missi... |
72,844,358 | Codeigniter 4 is_unique rule validation throws not unique error when I update record<p>I have a simple form that stores some data in the database and for the <strong>Title</strong> field I have an <strong>is_unique</strong> validation rule along with others. Following are my validation rules from the <strong>TaskModel<... | <p>You can pass the Id of row as parameter in the <strong>is_unique</strong> rule. Like</p>
<pre><code>is_unique[tasks.Title,Id,{Id}]
</code></pre>
<p>Hope this helps :)</p>
<p><strong>UPDATE: More Detailed Explanation</strong></p>
<p>Second parameter <strong>Id</strong> is database field name. Third one is the <strong... | Codeigniter 4 is_unique rule validation throws not unique error when I update record | php|codeigniter|validation|codeigniter-4|codeigniter-query-builder | 0 | 73 | 1 | 72,844,484 | 72,844,484 | 2 | true | 2022-07-03T06:27:09.420Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Codeigniter 4 is_unique rule validation throws not unique error when I update record<p>I have a simple form that stores some data in the database and for the... |
72,905,619 | how to convert a string into an array of characters - java 8<p><strong>Passed in string:</strong> hello</p>
<p><strong>populate arrayA[] with:</strong> ["h", "e", "l", "l", "o"];</p>
<p>Without using any packages or imports</p>
<pre><code> int size = a.length();
... | <p>I believe this could be solved using <code>String#split</code>.</p>
<pre><code>String[] lettersOfHello = "hello".split("");
</code></pre>
<p>Will need to circle back if it is preinstalled in Java 8 or no introduced until a later package.</p> | how to convert a string into an array of characters - java 8 | java|arrays|string | -1 | 73 | 4 | 72,905,727 | 72,905,727 | 2 | true | 2022-07-08T00:52:53.103Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
how to convert a string into an array of characters - java 8<p><strong>Passed in string:</strong> hello</p>
<p><strong>populate arrayA[] with:</strong> [&quo... |
72,891,074 | How to fill countries with their respective flags with geom_map?<p>I'm working with package <code>ggplot2</code> and using the function <code>geom_map</code> to <code>fill</code> the countries with different colors.</p>
<p>I was wondering if it is possible to fill with <strong>flags</strong> instead of colors?</p>
<p>D... | <p>Here is an option using the excellent <a href="https://github.com/coolbutuseless/ggpattern" rel="nofollow noreferrer"><code>ggpattern</code></a> and <a href="https://coolbutuseless.github.io/2020/04/03/introducing-flagon-a-package-of-just-flag-images-in-png-and-svg-format/" rel="nofollow noreferrer"><code>flagon</co... | How to fill countries with their respective flags with geom_map? | r|ggplot2 | 2 | 73 | 1 | 72,891,484 | 72,891,484 | 2 | true | 2022-07-07T00:19:32.883Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to fill countries with their respective flags with geom_map?<p>I'm working with package <code>ggplot2</code> and using the function <code>geom_map</code>... |
72,772,119 | Tilt element pane on mousemove<p>I'm trying to redo the animation that I saw on a site where an image changes it's x and y values with the movement of the mouse. The problem is that the origin of the mouse is in the top left corner and I'd want it to be in the middle.
To understand better, here's how the mouse axis val... | <p>The exact 3D effect you're up to is called <em><strong>"tilting"</strong></em>.</p>
<p>Long story short, it uses CSS <code>transform</code>'s <code>rotateX()</code> and <code>rotateY()</code> on a child element inside a <code>perspective: 1000px</code> parent. The values passed for the rotation are calcula... | Tilt element pane on mousemove | javascript|html|css | 1 | 73 | 3 | 72,775,694 | 72,775,694 | 2 | true | 2022-06-27T12:28:33.507Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Tilt element pane on mousemove<p>I'm trying to redo the animation that I saw on a site where an image changes it's x and y values with the movement of the mo... |
72,863,095 | Fix Cipher decryption<p>I am trying to fix a code that takes a ciphered input file and runs a frequency analysis of the letters and then decrypts the ciphered text. I got it to work for the most part, but the ciphered text is not fully decrypted. Can I get some suggestions on how I would fix it?</p>
<pre><code>ETAOIN =... | <p>The key is this is a Caesar cipher, so the OP's algorithm is wrong. A Caesar cipher only rotates the alphabet so a frequency analysis of more than the most common letter isn't needed.</p>
<p>The most common letter in the solution text is likely E. The most common letter in the cipher text is R, so if E=R then the ... | Fix Cipher decryption | python|caesar-cipher | 1 | 73 | 1 | 72,874,879 | 72,874,879 | 2 | true | 2022-07-05T00:57:05.820Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Fix Cipher decryption<p>I am trying to fix a code that takes a ciphered input file and runs a frequency analysis of the letters and then decrypts the ciphere... |
72,807,028 | SVG fade color of object<p>I want to fade the fill color of a svg circle from one color to another color, like from red to black.</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-html lang-html prettyprint-override">... | <p>You will want to use the radial gradient to have this work. You can play around with the offset numbers for the desired effect.</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-html lang-html prettyprint-override"... | SVG fade color of object | svg|fade | 2 | 73 | 2 | 72,807,091 | 72,807,091 | 2 | true | 2022-06-29T19:44:50.790Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
SVG fade color of object<p>I want to fade the fill color of a svg circle from one color to another color, like from red to black.</p>
<p><div class="snippet"... |
72,824,735 | delete files yyyy-mm-dd.pdf more than a month old<p>I have pdf files that I want to delete based on the file name that aremore than a month old. For example, if (today - 1 month) is '2022-06-01.pdf' then I want to delete files like '2022-04-13.pdf' and '2021-01-22.pdf'. I don't want to base the selection criteria based... | <p>I would do this entirely server-side.</p>
<ol>
<li>Construct a <code>DateTime</code> instance for <em>"1 month ago"</em></li>
<li>Create a filename from that instance</li>
<li>Iterate the files and compare the <a href="https://www.php.net/manual/function.basename.php" rel="nofollow noreferrer">basename</a>... | delete files yyyy-mm-dd.pdf more than a month old | javascript|php | -1 | 73 | 1 | 72,825,194 | 72,825,194 | 2 | true | 2022-07-01T05:27:21.980Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
delete files yyyy-mm-dd.pdf more than a month old<p>I have pdf files that I want to delete based on the file name that aremore than a month old. For example,... |
72,799,110 | How to move cursor to next textfield automatically after fill previous textfield in Swift Collectionview cells<p>I am working on Swift application, In that I have OTP verification screen.
So, User can enters 6 digits otp in 6 textfields.
I have created collection view and in that cell I have added dynamically 6 cells.
... | <p>This is the logic of moving cursor b/w textfields of OTP just map to your collectionview otp cells</p>
<pre><code> func textField(_ textField: UITextField, shouldChangeCharactersIn range: NSRange, replacementString string: String) -> Bool {
if (textField.text?.count)! < 1 && string.count > ... | How to move cursor to next textfield automatically after fill previous textfield in Swift Collectionview cells | ios|swift|uicollectionview|uitextfield|text-cursor | 0 | 73 | 2 | 72,799,366 | 72,799,366 | 2 | true | 2022-06-29T09:35:43.923Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to move cursor to next textfield automatically after fill previous textfield in Swift Collectionview cells<p>I am working on Swift application, In that I... |
72,972,592 | Identifying a Ruby module method invoked by super?<p>Ruby 2.7+.</p>
<p>I have methods in a couple of modules that are mixed in, and are invoked with <code>super</code>. Each of the module methods invokes <code>super</code> in turn, so all methods by that name in the mixed-in modules are invoked, although perhaps not i... | <p>My first attempt was to call <code>super_method</code> to get all the initializers up the stack:</p>
<pre class="lang-rb prettyprint-override"><code>module A
def initialize
A # return for comparison
end
end
module B
def initialize
B
end
end
class C
include A
include B
def initialize
C
... | Identifying a Ruby module method invoked by super? | ruby|mixins|ruby-module | 1 | 73 | 1 | 72,976,287 | 72,976,287 | 2 | true | 2022-07-13T21:00:42.650Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Identifying a Ruby module method invoked by super?<p>Ruby 2.7+.</p>
<p>I have methods in a couple of modules that are mixed in, and are invoked with <code>su... |
72,791,551 | Vlookup with multiple criteria with returned array inserted into ComboBox<p>Is there a way to use VBA to Vlookup with multiple criteria and then have those multiple returned values then inserted into a ComboBox? For the table below, I would like to have "Marlins" as the search criteria, and then have {RBI, Sc... | <h2>Populate a ComboBox</h2>
<p><strong>A Simple Example</strong></p>
<pre class="lang-vb prettyprint-override"><code>Sub PopulateComboBox()
' Reference the worksheet.
Dim ws As Worksheet: Set ws = ThisWorkbook.Worksheets("Metadata")
' Write the values of the range to a 2D one-based arra... | Vlookup with multiple criteria with returned array inserted into ComboBox | excel|vba|vlookup | 1 | 73 | 3 | 72,792,042 | 72,792,042 | 3 | true | 2022-06-28T18:33:55.903Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Vlookup with multiple criteria with returned array inserted into ComboBox<p>Is there a way to use VBA to Vlookup with multiple criteria and then have those m... |
72,796,364 | How to convert dictionary to pandas DataFrame in Python when dictionary value is a List?<p>I want to convert Python dictionary into DataFrame. Dictionary value is a List with different length.</p>
<p>Example:</p>
<pre><code>import pandas as pd
data = {'A': [1], 'B': [1,2], 'C': [1,2,3]}
df = pd.DataFrame.from_dict(da... | <p>You can use:</p>
<pre><code>df = pd.DataFrame({'name':data.keys(), 'value':data.values()})
print (df)
name value
0 A [1]
1 B [1, 2]
2 C [1, 2, 3]
</code></pre>
<hr />
<pre><code>df = pd.DataFrame(data.items(), columns=['name','value'])
print (df)
name value
0 A [1]
1 B... | How to convert dictionary to pandas DataFrame in Python when dictionary value is a List? | python|pandas|list|dataframe|dictionary | 2 | 73 | 1 | 72,796,378 | 72,796,378 | 3 | true | 2022-06-29T05:49:56.533Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to convert dictionary to pandas DataFrame in Python when dictionary value is a List?<p>I want to convert Python dictionary into DataFrame. Dictionary val... |
72,823,370 | Fastest way to "sort" bit sequence by toggling bits<p>Given a finite random sequence of bits, how can the minimum number of bit toggles necessary to result in a sorted sequence (i.e. any and all 0's are before any and all 1's) be determined?</p>
<p>Note, homogeneous sequences (e.g. <code>0000000</code> and <code>111111... | <p>Let Z(n) be the cost of setting the first n bits all 0.</p>
<p>Let X(n) be the cost of minimum cost of "sorting" the first n bits.</p>
<p>We have:</p>
<p>Z(0) = 0, X(0) = 0</p>
<p>if the ith bit is 0: Z(i) = Z(i-1), X(i) = min( Z(i-1), X(i-1)+1 )</p>
<p>if the ith bit is 1: Z(i) = Z(i-1)+1, X(i) = X(i-1)</... | Fastest way to "sort" bit sequence by toggling bits | algorithm|sorting|binary|toggle | 1 | 73 | 2 | 72,823,820 | 72,823,820 | 3 | true | 2022-07-01T00:49:34.583Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Fastest way to "sort" bit sequence by toggling bits<p>Given a finite random sequence of bits, how can the minimum number of bit toggles necessary to result i... |
72,831,509 | how to get max No between 1 to Next 1 in sql<pre><code>
CREATE TABLE #t1 ( ID int, Furnace_life INT);
INSERT INTO #t1(ID,Furnace_life) VALUES (1,1)
INSERT INTO #t1(ID,Furnace_life) VALUES (2,2)
INSERT INTO #t1(ID,Furnace_life) VALUES (3,3)
INSERT INTO #t1(ID,Furnace_life) VALUES (4,4) ---
INSERT INTO #t1(ID,Furnace_l... | <p>You can use below script. Note than records must be sorted by ID!</p>
<pre><code>CREATE TABLE #t2 ( ID int, Furnace_life INT, TopLife INT NULL);
INSERT INTO #t2
(
ID,
Furnace_life,
TopLife
)
SELECT t.ID,t.Furnace_life,
LAG(t.Furnace_life) OVER (ORDER BY t.ID) TopLife
FROM #t1 t
ORDER BY ID
S... | how to get max No between 1 to Next 1 in sql | sql|sql-server|gaps-and-islands | 1 | 73 | 4 | 72,837,217 | 72,837,217 | 3 | true | 2022-07-01T15:28:23.167Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
how to get max No between 1 to Next 1 in sql<pre><code>
CREATE TABLE #t1 ( ID int, Furnace_life INT);
INSERT INTO #t1(ID,Furnace_life) VALUES (1,1)
INSERT I... |
72,853,498 | Why use lazy var when adding stackview?<p><a href="https://i.stack.imgur.com/FbL0L.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/FbL0L.png" alt="enter image description here" /></a></p>
<pre><code>class SummaryLabelTVC: UITableViewCell {
static let identifier = "SummaryLabelTVC"
var summ... | <p>The difference is not about stack views vs any other kind of view. As the error message suggests, it's about whether you have used any instance members in the initialiser of the property.</p>
<p>In the initialiser of <code>stackView</code>, you have used <code>summaryIcon</code> and <code>label</code>, which are ins... | Why use lazy var when adding stackview? | ios|swift | 0 | 73 | 1 | 72,853,769 | 72,853,769 | 3 | true | 2022-07-04T08:03:33.043Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why use lazy var when adding stackview?<p><a href="https://i.stack.imgur.com/FbL0L.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/FbL0L.p... |
72,881,524 | VBA Word - Find unique text then note page number<p>TLDR: having successfully used a .FIND object to locate some text in a Word document, how can I find out what page this text was found on?</p>
<p>Longer explanation: I have a Word document of shipping labels, one per page. I want to search this file for a specific ord... | <p><code>Find.Parent.Information(wdActiveEndPageNumber)</code> will give you the result.
<code>Find.Parent</code> returns the range that has been found - and on that you apply <code>Information</code>.</p>
<p>BTW: It's good coding practice to <strong>not use code words</strong> as variable names</p> | VBA Word - Find unique text then note page number | vba|ms-word|find | 3 | 73 | 2 | 72,881,774 | 72,881,774 | 3 | true | 2022-07-06T10:03:08.107Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
VBA Word - Find unique text then note page number<p>TLDR: having successfully used a .FIND object to locate some text in a Word document, how can I find out ... |
72,891,355 | How to add table cell value in Google Slides using script?<p>I am trying to update the value of a table cell in Google Slides using <code>Google App Script.</code></p>
<p>Here is the code.</p>
<pre class="lang-js prettyprint-override"><code>function calculateResourceCapacity() {
const FIXED_ROWS = 4;
const COL_AVA_... | <p>In your script, how about the following modification?</p>
<h3>From:</h3>
<pre><code>const cell = table.getCell(i, COL_AVA_PD).editAsText().setText(monthPD);
</code></pre>
<h3>To:</h3>
<pre><code>const cell = table.getCell(i, COL_AVA_PD);
cell.getText().setText(monthPD);
</code></pre>
<h3>References:</h3>
<ul>
<li><a... | How to add table cell value in Google Slides using script? | google-apps-script|google-slides | 0 | 73 | 1 | 72,891,383 | 72,891,383 | 3 | true | 2022-07-07T01:23:41.270Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to add table cell value in Google Slides using script?<p>I am trying to update the value of a table cell in Google Slides using <code>Google App Script.<... |
72,891,810 | What is the opposite of unpacking **kwargs in Python?<p>I've been learning about Python decorators and to practice using them, I'm writing a logging decorator that records when a function is called, the <code>*args</code> and <code>**kwargs</code> passed to the function, and a <code>__repr__</code> of the function so i... | <p>There's some serious caveats here, as not everything passed to any type of keyword argument will necessarily have a good representation and the representation may not work as you expect (reconstructing a copy of the original when evaluated).</p>
<p>Having said that, something like this:</p>
<pre><code>def print_args... | What is the opposite of unpacking **kwargs in Python? | python|iterable-unpacking | 1 | 73 | 1 | 72,892,048 | 72,892,048 | 3 | true | 2022-07-07T02:55:23.160Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
What is the opposite of unpacking **kwargs in Python?<p>I've been learning about Python decorators and to practice using them, I'm writing a logging decorato... |
72,902,348 | split string by comma so that each sentence will be a separate string<p>I want to split my string in separate sentences.
My code is below</p>
<pre><code> import tensorflow as tf
import pandas as pd
text = 'My cat is a great cat, this is very nice, you are doing great job'
text = text.split(',')
</code></pre>
<p>O... | <p>Yes it's possible, we have answers already given above but
to match exact expected output as mentioned above use below:</p>
<pre><code>inputlist = "apple,banana,cherry"
print(*[[s] for s in inputlist.split(',')],end=" ")
</code></pre>
<p>output:</p>
<pre><code>['apple'] ['banana'] ['cherry']
</c... | split string by comma so that each sentence will be a separate string | python|string|list | 2 | 73 | 6 | 72,902,570 | 72,902,570 | 3 | true | 2022-07-07T18:00:11.200Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
split string by comma so that each sentence will be a separate string<p>I want to split my string in separate sentences.
My code is below</p>
<pre><code> imp... |
72,966,603 | How to convert a generic function with lifetimes into a function pointer<p>This is of course a simplified version of my actual problem.</p>
<pre><code>fn my_func<'a, 'b>(a: &'a i32, b: &'b i32) -> i32 {
a + b
}
fn my_func_generic<'a, 'b, T>(a: &'a T, b: &'b T) -> T
where
&... | <p><strong>TL;DR:</strong> In your case, you can do it as follows:</p>
<pre class="lang-rust prettyprint-override"><code>fn apply_function<'a, 'b>(x: &'a i32, y: &'b i32, function: fn(&'a i32, &'b i32) -> i32) -> i32
</code></pre>
<p>But in general, this is impossible.</p>
<hr />
<p>There ar... | How to convert a generic function with lifetimes into a function pointer | rust | 2 | 73 | 2 | 72,966,833 | 72,966,833 | 3 | true | 2022-07-13T12:48:27.807Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to convert a generic function with lifetimes into a function pointer<p>This is of course a simplified version of my actual problem.</p>
<pre><code>fn my_... |
72,994,416 | Reverse a Map (A - B List) to (B - A List)<p>I made up this function, it seems to make the work, but I wondered if there was an even cleaner solution.</p>
<pre class="lang-java prettyprint-override"><code> public static <K, V> Map<V, List<K>> reverseMap(Map<K, List<V>> map) {
re... | <p>Since you did not necessitate streams in your question, I'm going to advocate for a non-stream solution:</p>
<pre><code>//example input
Map<Integer, List<Integer>> map = new HashMap<>();
map.put(1, Arrays.asList(11, 12, 13, 4));
map.put(2, Arrays.asList(21, 22, 23, 4));
map.put(3, Arrays.asList(31,... | Reverse a Map (A - B List) to (B - A List) | java|java-stream | -2 | 73 | 1 | 72,994,653 | 72,994,653 | 3 | true | 2022-07-15T13:01:14.927Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Reverse a Map (A - B List) to (B - A List)<p>I made up this function, it seems to make the work, but I wondered if there was an even cleaner solution.</p>
<p... |
72,912,762 | setup.py - building c-extension with Numpy dependency<p>I have created a simple c-function (using the guide here <a href="https://numpy.org/doc/stable/user/c-info.ufunc-tutorial.html" rel="nofollow noreferrer">Create Numpy ufunc</a>) and I'm now trying to distribute my package on pypi. For it to work, it needs to compi... | <p>You can query <code>numpy</code> for the include directory from python via</p>
<pre class="lang-py prettyprint-override"><code>import numpy
numpy.get_include()
</code></pre>
<p>This should return a string (<code>/usr/lib/python3.10/site-packages/numpy/core/include</code> on my system) which you can add to the <code>... | setup.py - building c-extension with Numpy dependency | python|c|numpy|packaging | 2 | 73 | 1 | 72,931,947 | 72,931,947 | 3 | true | 2022-07-08T14:17:29.167Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
setup.py - building c-extension with Numpy dependency<p>I have created a simple c-function (using the guide here <a href="https://numpy.org/doc/stable/user/c... |
72,864,596 | iterate over a Variadic Template function and choose pointer arguments<p>I have a Variadic Template function in C++ and I want to iterate over the template arguments and cherry-pick those arguments that are pointers.</p>
<p><strong>PLEASE SEE THE UPDATE SECTION BELOW.</strong></p>
<p>So, I have the following code below... | <pre class="lang-cpp prettyprint-override"><code>template <int N, typename Arg, typename... Args>
void helper(std::vector<std::pair<int, void*>>& v, Arg arg, Args... args) {
if constexpr(std::is_pointer_v<Arg>) {
v.emplace_back(N, (void*)arg);
}
if constexpr(sizeof...(ar... | iterate over a Variadic Template function and choose pointer arguments | c++|templates|c++17|variadic-templates|c++-templates | 1 | 73 | 2 | 72,865,115 | 72,865,115 | 3 | true | 2022-07-05T05:58:19.013Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
iterate over a Variadic Template function and choose pointer arguments<p>I have a Variadic Template function in C++ and I want to iterate over the template a... |
72,793,598 | Label visibility on filtered list search in JavaFX<p>I'm using a TextField with a listener to filter a TableView. I've got if statements that set the predicate if newText matches part of the ID or Name.</p>
<p>The search functionality works like I want.</p>
<p>However, my project guidelines require me to also create so... | <blockquote>
<p>my project guidelines require me to also create some form of output upon a search not matching any objects in the TableView.</p>
</blockquote>
<p>That will happen by default, when the filtered table does not have any matches for the filter, the table will display a <a href="https://openjfx.io/javadoc/18... | Label visibility on filtered list search in JavaFX | java|javafx|label|listener|predicate | 2 | 73 | 1 | 72,793,926 | 72,793,926 | 3 | true | 2022-06-28T22:01:33.903Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Label visibility on filtered list search in JavaFX<p>I'm using a TextField with a listener to filter a TableView. I've got if statements that set the predica... |
73,013,895 | Compare list with an exact or scrambled match of a long text<p>I have the following list I want to iterate over it and find if there's a scramble match with the long string <code>aapxjdnrbtvldptfzbbdbbzxtndrvjblnzjfpvhdhhpxjdnrbt</code> and return the number of matches. <strong>The below example should return 4</strong... | <p>This creates sorted match strings for each different word length required. It builds them on the fly to avoid excess processing.
(Edit: Oops, the previous version assumed one long string in doing the caching. Thanks for the catch, @BeRT2me!)</p>
<pre><code>long_string = 'aapxjdnrbtvldptfzbbdbbzxtndrvjblnzjfpvhdhhp... | Compare list with an exact or scrambled match of a long text | python | -2 | 73 | 4 | 73,014,267 | 73,014,267 | 3 | true | 2022-07-17T17:24:21.943Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Compare list with an exact or scrambled match of a long text<p>I have the following list I want to iterate over it and find if there's a scramble match with ... |
72,827,965 | Will private functions be included when I compile a rust project to WASM?<p>If I have a lib.rs file and I'm using a function from a module in the mod.rs file, and that function uses another function within the mod.rs file but isn't made public to lib.rs. Thus is inaccessible to the lib.rs.</p>
<p>What happens if I publ... | <p>It's not exactly clear what you mean, as there are two aspects here:</p>
<ol>
<li><p>Yes, if you access a private function from a public function (including via indirections, nested calls, modules, etc.), the code of the private function will be included in the final executable. This is obviously true, as the public... | Will private functions be included when I compile a rust project to WASM? | rust|wasm-bindgen|rust-wasm | 1 | 73 | 1 | 72,830,095 | 72,830,095 | 3 | true | 2022-07-01T10:33:43.427Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Will private functions be included when I compile a rust project to WASM?<p>If I have a lib.rs file and I'm using a function from a module in the mod.rs file... |
72,822,838 | JSON C# deserialization<p>I am having trouble with deserializing data from a JSON string:</p>
<pre><code>[{
"Example A": [{
"Parameter1": "Example A",
"Parameter2": "aaa",
"Parameter3": "2022-06-30 21:15:00.0000000&... | <p>you have an array in your json Try this</p>
<pre><code>List<Examples> someVar = JsonConvert.DeserializeObject<List<Examples>>(JsonString);
</code></pre> | JSON C# deserialization | c#|json|.net-core | 1 | 73 | 1 | 72,822,863 | 72,822,863 | 4 | true | 2022-06-30T23:00:16.413Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
JSON C# deserialization<p>I am having trouble with deserializing data from a JSON string:</p>
<pre><code>[{
"Example A": [{
"P... |
72,907,260 | Perl: grep from multiple arrays at once<p>I have multiple arrays (~32). I want to remove all blank elements from them. How can it be done in a short way (may be via one foreach loop or 1-2 command lines)?</p>
<p>I tried the below, but it's not working:</p>
<pre><code> my @refreshArrayList=("@list1", "... | <p>You can create a list of list references and then iterator over these, like</p>
<pre><code>for my $list (\@list1, \@list2, \@list3) {
@$list = grep (!/^\s*$/, @$list);
}
</code></pre>
<p>Of course, you could create this list of list references also dynamically, i.e.</p>
<pre><code>my @list_of_lists;
push @list_... | Perl: grep from multiple arrays at once | arrays|perl|blank-line | 2 | 73 | 2 | 72,907,562 | 72,907,562 | 4 | true | 2022-07-08T06:04:57.010Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Perl: grep from multiple arrays at once<p>I have multiple arrays (~32). I want to remove all blank elements from them. How can it be done in a short way (may... |
72,819,899 | Why do we need map function in jq?<p>I am just playing with <code>jq</code>. Please check the following outputs.</p>
<pre><code>% FRUITS='[
{
"name": "apple",
"color": "green",
"price": 1.2
},
{
"name": "banana",
"color... | <p>There's absolutely no difference between <code>[ .[] | ... ]</code> vs <code>map( ... )</code>. You can <a href="https://github.com/stedolan/jq/blob/cff5336ec71b6fee396a95bb0e4bea365e0cd1e8/src/builtin.jq#L3" rel="nofollow noreferrer">see</a> this in jq's source.</p>
<p>Languages often provide syntactical shortcuts ... | Why do we need map function in jq? | jq | 0 | 73 | 1 | 72,820,193 | 72,820,193 | 4 | true | 2022-06-30T17:36:58.903Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why do we need map function in jq?<p>I am just playing with <code>jq</code>. Please check the following outputs.</p>
<pre><code>% FRUITS='[
{
"nam... |
72,989,037 | Pandas array filter NaN and keep the first value in group<p>I have the following pandas dataframe. There are many NaN but there are lots of <code>NaN</code> value (I skipped the <code>NaN</code> value to make it look shorter).</p>
<pre><code>0 NaN
...
26 NaN
27 357.0
28 357.0
29 357.0
3... | <p>Take only values that aren't nan, but the value before them is nan:</p>
<pre class="lang-py prettyprint-override"><code>df = df[df.col1.notna() & df.col1.shift().isna()]
</code></pre>
<p>Output:</p>
<pre><code> col1
27 357.0
247 357.0
304 58.0
334 237.0
</code></pre>
<hr />
<p>Assuming all values are ... | Pandas array filter NaN and keep the first value in group | python|pandas | 5 | 73 | 2 | 72,989,169 | 72,989,169 | 4 | true | 2022-07-15T04:26:28.590Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Pandas array filter NaN and keep the first value in group<p>I have the following pandas dataframe. There are many NaN but there are lots of <code>NaN</code> ... |
72,847,668 | Please explain me why i am getting this error in snakemake? I´ve been strugling for days please advise me on whats going wrong<p>I wrote this pipeline in snakemake to process my fastq files and get the raw counts but for some reason that I don't understand in the last rule (featurecounts) I get this error:</p>
<blockqu... | <p>Snakemake uses pattern in the output to infer which inputs to use. In the last rule, output is <code>raw_Counts</code>, which gives no indication of what to use for <code>{sample}</code> wildcard. Changing it to something like this might work for your use case:</p>
<pre class="lang-py prettyprint-override"><code>rul... | Please explain me why i am getting this error in snakemake? I´ve been strugling for days please advise me on whats going wrong | python|pipeline|wildcard|snakemake|rna-seq | 0 | 73 | 1 | 72,847,780 | 72,847,780 | 4 | true | 2022-07-03T15:19:00.693Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Please explain me why i am getting this error in snakemake? I´ve been strugling for days please advise me on whats going wrong<p>I wrote this pipeline in sna... |
72,826,704 | From boiler plate code to template implementation<p>I am implementing a finite state machine where all possible states are stored within a <code>std::tuple</code>.</p>
<p>This is a minimum compiling example of the problem I am facing and its godbolt link <a href="https://godbolt.org/z/7ToKc3T3W" rel="nofollow noreferre... | <p>If you only want to avoid adding another line like</p>
<pre><code>if (index == 4) return transit_to<4>();
</code></pre>
<p>when you add a new state, e.g. <code>struct state5</code>, you may implement <code>transit_to(std::size_t)</code> like this:</p>
<pre><code>// Helper function: Change state if I == idx.
//... | From boiler plate code to template implementation | c++|templates|c++17|stdtuple | 2 | 73 | 3 | 72,826,957 | 72,826,957 | 5 | true | 2022-07-01T08:48:56Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
From boiler plate code to template implementation<p>I am implementing a finite state machine where all possible states are stored within a <code>std::tuple</... |
72,901,504 | "The cheater's coin" python riddle<p>I tried for hours to solve this python riddle in my level of knowledge and I don't know what to write past the thinking part "I need to make tails more frequent by using +1 to something" maybe. The riddle goes like that:</p>
<pre><code>import random
def broken_coin():
... | <p>If I read your problem correctly, you need to provide a method to compensate for the broken coin producing a relatively fair amount of results. With that instead of calling the broken_coin() function every time directly, one could call a function that calls the function and every other time returns the reverse resu... | "The cheater's coin" python riddle | python | -4 | 73 | 1 | 72,902,400 | 72,902,400 | -2 | true | 2022-07-07T16:42:28.373Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
"The cheater's coin" python riddle<p>I tried for hours to solve this python riddle in my level of knowledge and I don't know what to write past the thinking ... |
72,884,831 | Spark 3.1.3 with spark cassandra connector 3.1.0 is giving ClassNotFoundException on spark-submit even with jars attached<p>I have used Spark 3.1.3 to connect Astra as well as Cassandra local server, but I am getting <code>java.lang.ClassNotFoundException</code> error on <code>spark-submit</code>. I have confirmed that... | <p>I have found a way around the solution. The solution is to use <code>sbt assembly</code> instead of <code>sbt package</code> and solve merger conflicts. However, if there are any solutions any solution to use <code>sbt package</code> in this way, please add as an answer.</p>
<p>So, here is what I did:</p>
<p>In fold... | Spark 3.1.3 with spark cassandra connector 3.1.0 is giving ClassNotFoundException on spark-submit even with jars attached | apache-spark|apache-spark-sql|cassandra|spark-cassandra-connector|datastax-astra | 0 | 73 | 3 | 72,893,810 | 72,893,810 | -1 | true | 2022-07-06T13:54:26.457Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Spark 3.1.3 with spark cassandra connector 3.1.0 is giving ClassNotFoundException on spark-submit even with jars attached<p>I have used Spark 3.1.3 to connec... |
72,770,174 | My personel Assistants project : AttributeError: Could not find PyAudio; check installation<p>I'm trying to make a personel assistant. When I run the code, the code works, it says what it should say at the beginning, but when it comes to the line of code I've shown below, it throws an error. Here is that error</p>
<pr... | <p>there have two possible solution for solving this problem</p>
<p><strong>1st solution:</strong></p>
<pre><code>pip install pipwin
</code></pre>
<p>then</p>
<pre><code>pipwin install pyaudio
</code></pre>
<p><strong>2nd solution:</strong></p>
<pre><code>sudo apt-get install portaudio19-dev python-pyaudio
</code></pre... | My personel Assistants project : AttributeError: Could not find PyAudio; check installation | python|speech-recognition|pyaudio | 0 | 74 | 1 | 72,770,302 | 72,770,302 | 0 | true | 2022-06-27T09:57:29.880Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
My personel Assistants project : AttributeError: Could not find PyAudio; check installation<p>I'm trying to make a personel assistant. When I run the code, ... |
72,799,302 | Python Jupyter notebook ossystem / nbconvert path change<p>Currently I have Jupiter notebooks with reports that I wish to convert into html format with the output from the notebook run (no codes). To achieve this I am using os.system and a python script (see bellow). However, this is saving the file in the same folder ... | <p>nbconvert seems to support an alternative solution, where you might <a href="https://nbconvert.readthedocs.io/en/latest/usage.html" rel="nofollow noreferrer">output your file to --stdout</a> and redicted it to the desired folder something like so:</p>
<pre class="lang-py prettyprint-override"><code>cmd = f'jupyter n... | Python Jupyter notebook ossystem / nbconvert path change | python|jupyter-notebook|path|operating-system|nbconvert | 0 | 74 | 1 | 72,807,282 | 72,807,282 | 0 | true | 2022-06-29T09:49:30.053Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Python Jupyter notebook ossystem / nbconvert path change<p>Currently I have Jupiter notebooks with reports that I wish to convert into html format with the o... |
72,794,440 | How I can use emojis with React?<p>I need to know if is there an emoji library that allows using of emojis and also gets an HTML emoji decimal or hexadecimal code to use as an HTML entity like <code>&#x1F3AF;</code> for
I also want to retrieve a list of emojis codes too.</p>
<p>I want to render at a React componen... | <p>If I get you correctly, you want to find <strong>full emoji references list.</strong></p>
<p>You can <strong>check out</strong> this emoji <strong>unicode reference</strong> from W3Schools: <a href="https://www.w3schools.com/charsets/ref_emoji.asp" rel="nofollow noreferrer">https://www.w3schools.com/charsets/ref_emo... | How I can use emojis with React? | javascript|html|reactjs | -1 | 74 | 1 | 72,810,550 | 72,810,550 | 0 | true | 2022-06-29T00:16:06.033Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How I can use emojis with React?<p>I need to know if is there an emoji library that allows using of emojis and also gets an HTML emoji decimal or hexadecimal... |
72,811,739 | Parameter value [2019-05-15,23:00] did not match expected type [java.time.LocalDateTime (n/a)]<p>firstly I'm a beginner in Java. I want to ask you, I try to GET request, and I catch an exception.</p>
<pre><code>GET http://localhost:8080/api/criteria/byParam?name=dateTimeAppointment&value=2019-05-15,23:00
java.lang... | <p>Try something like this:</p>
<pre><code>DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyy-MM-dd,HH:mm");
Predicate predicate = criteriaBuilder.equal(root.get(name),LocalDateTime.parse(value , formatter));
</code></pre> | Parameter value [2019-05-15,23:00] did not match expected type [java.time.LocalDateTime (n/a)] | java|spring-boot|hibernate|date|localdatetime | 0 | 74 | 1 | 72,812,365 | 72,812,365 | 0 | true | 2022-06-30T07:19:03.850Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Parameter value [2019-05-15,23:00] did not match expected type [java.time.LocalDateTime (n/a)]<p>firstly I'm a beginner in Java. I want to ask you, I try to ... |
72,814,401 | C# communication from Arduino to a UI written in WPF<p>I want to receive data via serial port. I want to show this data in a textbox on a UI written in C# -- WPF</p>
<p>I understand that the UI and the comms. run on 2 different threads, but I am unable to get much further.</p>
<p>How can I do this?</p> | <p>They don't necessarily need to run on different threads. Generally with a serial port class, it will have a callback mechanism when data is received, which you can hook in your WPF models. Have you read the official MS documentation?</p>
<p>From <a href="https://www.codeproject.com/Articles/130109/Serial-Communic... | C# communication from Arduino to a UI written in WPF | c#|arduino|serial-port|serial-communication | -1 | 74 | 1 | 72,815,028 | 72,815,028 | 0 | true | 2022-06-30T10:42:27.737Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
C# communication from Arduino to a UI written in WPF<p>I want to receive data via serial port. I want to show this data in a textbox on a UI written in C# --... |
72,815,994 | Is there any way to hide default yAxes line and only show the values on yAxes in react-chartjs-2?<p>I have a little experience with chartjs but I am unable to find a way to hide the default line. I'm adding this image here which I need to fix.
I need to hide the line like this one
<a href="https://i.stack.imgur.com/UXM... | <p>set display to false in the grid settings of the x axis and drawBorder to false in both axes like so:</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-js lang-js prettyprint-override"><code>const options = {
typ... | Is there any way to hide default yAxes line and only show the values on yAxes in react-chartjs-2? | javascript|reactjs|chart.js|react-chartjs-2 | 0 | 74 | 1 | 72,816,250 | 72,816,250 | 0 | true | 2022-06-30T12:38:07.173Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Is there any way to hide default yAxes line and only show the values on yAxes in react-chartjs-2?<p>I have a little experience with chartjs but I am unable t... |
72,823,106 | How to transform a dataset into a presence/absence matrix?<p>My dataset follows this model:</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>Species</th>
<th>Year</th>
</tr>
</thead>
<tbody>
<tr>
<td>Species_1</td>
<td>2000</td>
</tr>
<tr>
<td>Species_1, Species_2</td>
<td>2003</td>
</tr>
<t... | <p>Here's a tidy solution:</p>
<pre class="lang-r prettyprint-override"><code>library(stringr)
library(dplyr)
library(tidyr)
dat <- data.frame(
species = c("species_1", "species_1, species_2", "species_2, species_3"),
year = c(2000, 2003, 2005)
)
library(stringr)
dat %>%
roww... | How to transform a dataset into a presence/absence matrix? | r|excel|excel-formula|dataset|data-transform | -1 | 74 | 1 | 72,823,214 | 72,823,214 | 0 | true | 2022-06-30T23:49:03.857Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to transform a dataset into a presence/absence matrix?<p>My dataset follows this model:</p>
<div class="s-table-container">
<table class="s-table">
<thea... |
72,838,055 | Rust clone/ copy issues<p>trying to wrap my head around how to do some simple plotting in egui. I have a data member in myapp struct that is a Vec::<Value>.</p>
<p>Is there a way to pass that into Points::new(Values::from_values(data.to_vec()) without creating a copy of the values?
Examples generally generate on ... | <blockquote>
<p>but it feels a bit excessive to reading in from disc and parse the text data for each frame.</p>
</blockquote>
<p>You don't have to (and should not) do this every frame. Parse it once and store the results in a persistent structure, and copy from there during your <code>show</code> closure.</p>
<p>That ... | Rust clone/ copy issues | rust|egui | -1 | 74 | 1 | 72,840,923 | 72,840,923 | 0 | true | 2022-07-02T09:41:47.517Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Rust clone/ copy issues<p>trying to wrap my head around how to do some simple plotting in egui. I have a data member in myapp struct that is a Vec::<Value... |
72,770,992 | Push object to specific position of nested array<p>I am using tree view in my angular project and I want to push object to the specific position into array.</p>
<p>array</p>
<pre><code>const TREE_DATA: TreeNode[] = [{"name":"Demo","id":"demo_1","children":[{"name&q... | <p>@DanteDX, I was looking something like below code, maybe my question was not cleared so you did not answered me ,</p>
<pre><code>private search(items: TreeNode[], term: string): any[] {
return items.reduce((acc: TreeNode[], item: TreeNode) => {
if (this.contains(item.name, term)) {
... | Push object to specific position of nested array | javascript|typescript | -1 | 74 | 1 | 72,854,788 | 72,854,788 | 0 | true | 2022-06-27T10:59:25.983Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Push object to specific position of nested array<p>I am using tree view in my angular project and I want to push object to the specific position into array.<... |
72,866,642 | change the default localhost path react<p>change the default localhost path. For example: http://localhost:3001/ by the path http://localhost:3001/home . I would like the when I launch npm start that I arrive directly on this path http://localhost:3001/ home . I tried modifying in the package.Json file, but it doesn't ... | <p>the solution : <code><Route path="/" element={ <Navigate to="/pastry" /> } /></code></p> | change the default localhost path react | reactjs|react-router|react-router-dom | -1 | 74 | 3 | 72,868,690 | 72,868,690 | 0 | true | 2022-07-05T08:57:56.637Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
change the default localhost path react<p>change the default localhost path. For example: http://localhost:3001/ by the path http://localhost:3001/home . I w... |
72,871,943 | Print PDFs automatically with python<p>I am building a website which accepts pdf from users and the options, like pages to print, copies, color or black&white and the shop from which they want to get it printed.</p>
<p>The pdf will be stored in server and will be passed on to the shop to print. How do i get it prin... | <p>You can do the following:</p>
<pre><code>import os
os.startfile("C:/Users/TestFile.txt", "print")
</code></pre>
<p>This will start the file, in its default opener, with the verb 'print', which will print to your default printer.Only requires the os module which comes with the standard library</p... | Print PDFs automatically with python | python|pdf|printing | 0 | 74 | 1 | 72,872,202 | 72,872,202 | 0 | true | 2022-07-05T15:26:02.080Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Print PDFs automatically with python<p>I am building a website which accepts pdf from users and the options, like pages to print, copies, color or black&... |
72,831,839 | Chrome extension won't redirect to localhost with port number<p>I built a Chrome extension (manifest V3) that has dynamic domain redirect functionality. In general it works as expected, even if I redirect to <code>localhost</code>. However, if I attempt to redirect to localhost with a port number, e.g. <code>localhost:... | <p>I'll answer my own question here, based on what @wOxxOm correctly pointed out in a comment, as it may be useful to soemone else.</p>
<p>When forwarding to a domain with an specified port, the port needs to be specified sepearately.</p>
<p>The corrected code would be as follows:</p>
<pre><code>chrome.declarativeNetRe... | Chrome extension won't redirect to localhost with port number | redirect|chrome-extension-manifest-v3 | 0 | 74 | 1 | 72,872,691 | 72,872,691 | 0 | true | 2022-07-01T15:55:56.537Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Chrome extension won't redirect to localhost with port number<p>I built a Chrome extension (manifest V3) that has dynamic domain redirect functionality. In g... |
72,863,332 | How to decode some strange JSON data in Swift?<p>My JSON file is like this:</p>
<pre><code>> {
"skill_list": [
{
"Skill": 78
},
{
"Skill": 57
},
"None"
]
},
{
"skill_list": [
{
... | <p>finally i got this, the code is :</p>
<pre><code> let myJson = """
{
"armor": {
"param": [
{
"skill_list": [
{
"Skill": 56
},
"None",
... | How to decode some strange JSON data in Swift? | json|swift|decode | 0 | 74 | 1 | 72,877,441 | 72,877,441 | 0 | true | 2022-07-05T02:04:41.573Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to decode some strange JSON data in Swift?<p>My JSON file is like this:</p>
<pre><code>> {
"skill_list": [
{
&quo... |
72,782,079 | Multiple React app with same azure app configuration ? can we Implemented SingleSIgn ON?<p>I have 3 React Application #</p>
<ol>
<li><a href="http://www.grnadfatherap.com" rel="nofollow noreferrer">www.grnadfatherap.com</a></li>
<li><a href="http://www.parenatapp.com" rel="nofollow noreferrer">www.parenatapp.com</a></l... | <p>To support Azure AD in your react application add <a href="https://www.npmjs.com/package/@azure/msal-react" rel="nofollow noreferrer">@azure/msal-react</a> package to each of them, configure cacheLocation as localStorage to <a href="https://docs.microsoft.com/en-us/azure/active-directory/develop/msal-js-sso#sso-betw... | Multiple React app with same azure app configuration ? can we Implemented SingleSIgn ON? | reactjs|oauth-2.0|single-sign-on|msal.js|adal.js | 0 | 74 | 1 | 72,877,788 | 72,877,788 | 0 | true | 2022-06-28T07:09:12.747Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Multiple React app with same azure app configuration ? can we Implemented SingleSIgn ON?<p>I have 3 React Application #</p>
<ol>
<li><a href="http://www.grna... |
72,880,175 | My Button to clear all input fields wont work<p>i made a list where u can input the amount of a product u want to buy and it cauculates the price for. I am trying to make a button that clears all input fields when pressed i dont want the input fields to be cleared when cauculated only when the delete button is pressed.... | <p>You have to wrap your <strong>tag Id</strong> into ''.
Try the below code for the reset button.</p>
<pre><code><button
onclick="document.getElementById('MullkompressenAmount').value = ''"
>
Löschen
</button>
</code></pre> | My Button to clear all input fields wont work | javascript|html | 0 | 74 | 6 | 72,880,311 | 72,880,311 | 0 | true | 2022-07-06T08:26:56.237Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
My Button to clear all input fields wont work<p>i made a list where u can input the amount of a product u want to buy and it cauculates the price for. I am t... |
72,883,093 | Undefined array key 1 Laravel<p>I am having this problem in visualizing, through a card, the elements present in the db.</p>
<p>This is the controller:</p>
<p><strong>Controller.php</strong></p>
<pre><code>
class PublicController extends Controller
{
public function homepage(){
$articles = A... | <p>You are using the wrong type of brackets/parentheses here:</p>
<pre><code>@foreach {$articles as $article}
</code></pre>
<p>It should be like this:</p>
<pre><code>@foreach ($articles as $article)
</code></pre> | Undefined array key 1 Laravel | php|arrays|eloquent|laravel-8 | 0 | 74 | 1 | 72,883,123 | 72,883,123 | 0 | true | 2022-07-06T11:49:26.863Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Undefined array key 1 Laravel<p>I am having this problem in visualizing, through a card, the elements present in the db.</p>
<p>This is the controller:</p>
<... |
72,886,867 | Basic authentication using Fetch API in JS<p>I'm working on a script featured in an HTML document to display a map of the Boston area using leaftlet, and I'd like to get a list of locations to put on the map from this website. I'm using <code>fetch</code> to do this, and so far the code looks like this.</p>
<p>const KE... | <blockquote>
<pre><code>mode: "no-cors"
</code></pre>
</blockquote>
<p>Setting the mode to <code>"no-cors"</code> causes any attempt to do something that requires CORS permission to silently fail (instead of throwing an exception).</p>
<p>Setting <code>Authorization</code> and <code>Content-Type</co... | Basic authentication using Fetch API in JS | javascript|async-await|fetch-api | 0 | 74 | 1 | 72,886,910 | 72,886,910 | 0 | true | 2022-07-06T16:17:21.483Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Basic authentication using Fetch API in JS<p>I'm working on a script featured in an HTML document to display a map of the Boston area using leaftlet, and I'd... |
72,889,976 | Dutch Number & 2 Decimal Place Validation Power APP<p>A UK number looks like this 233.25 .</p>
<p>For a Dutch Number, it looks like this in the Power APP 233,25.</p>
<p>This works for the Power App in the UK but not in Holland, due to the comma for the decimal separator. How can I change this to get it to work? I have ... | <p>You could try to format it yourself. Regardless of what the user inputs.</p>
<pre><code>Left(Value(TextInput.Text),Len(Value(TextInput.Text))-2) & "," & Right(Value(TextInput.Text),2) & "."
</code></pre>
<p><a href="https://i.stack.imgur.com/hwFCm.png" rel="nofollow noreferrer"><img s... | Dutch Number & 2 Decimal Place Validation Power APP | regex|powerapps | 0 | 74 | 1 | 72,899,507 | 72,899,507 | 0 | true | 2022-07-06T21:21:01.407Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Dutch Number & 2 Decimal Place Validation Power APP<p>A UK number looks like this 233.25 .</p>
<p>For a Dutch Number, it looks like this in the Power APP 233... |
72,902,508 | Why does GraphQL only query 10 entries when using Custom Post Types?<p>Not sure if this is a silly question but I am trying to query Custom Post Types from WordPress using GraphQL, there Custom Post Types also contain Advanced Custom Fields.</p>
<p>As you can see here I have published 17 in total:</p>
<p><a href="https... | <p>By default, it only pulls through the first 10, specify the limit of how much you want in the query</p>
<pre><code> {
slumpMedias (first:100) {
edges {
node {
title
slumpMeta {
image {
mediaItemUrl
}
... | Why does GraphQL only query 10 entries when using Custom Post Types? | wordpress|graphql|advanced-custom-fields|custom-post-type | 0 | 74 | 1 | 72,903,046 | 72,903,046 | 0 | true | 2022-07-07T18:15:22.953Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why does GraphQL only query 10 entries when using Custom Post Types?<p>Not sure if this is a silly question but I am trying to query Custom Post Types from W... |
72,902,837 | How to allow users to download an excel file using python/Flask?<p>I have a method that takes in an excel file, read the excel file, extracts data from it and save. The issue I am having now is how to write a method that returns the excel file and allow users to download it from the frontend.</p>
<p>This is the main fi... | <p>This line solved my problem</p>
<pre><code>return send_from_directory('directory-path', file.filename)
</code></pre>
<p>This is the full code here</p>
<p>from flask import send_from_directory
class UploadFileForm(FlaskForm):
file = FileField('File', validators=[InputRequired()])
submit = SubmitField('Download File')... | How to allow users to download an excel file using python/Flask? | python|excel|flask|openpyxl | -1 | 74 | 2 | 72,907,455 | 72,907,455 | 0 | true | 2022-07-07T18:49:01.917Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to allow users to download an excel file using python/Flask?<p>I have a method that takes in an excel file, read the excel file, extracts data from it an... |
72,911,838 | Android Kotlin Fragments: ''Attempt to invoke virtual method on a null object reference''<p>My code in MainActivity:</p>
<pre><code> val buttonbckbrowse = findViewById<Button>(R.id.buttonbck)
buttonbckbrowse.setOnClickListener {
val webView = findViewById<WebView>(R.id.webViewBrowse)
... | <p>Having an activity directly accessing a view of a fragment will always cause complications. I suggest you rethink you approach.</p>
<p>The fragment containing the button should set the click listener. When the button is clicked the fragment raises the event to an object shared with the hosting activity. (Something... | Android Kotlin Fragments: ''Attempt to invoke virtual method on a null object reference'' | android|android-studio|kotlin|android-fragments|android-tablayout | 0 | 74 | 1 | 72,912,233 | 72,912,233 | 0 | true | 2022-07-08T13:03:06.213Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Android Kotlin Fragments: ''Attempt to invoke virtual method on a null object reference''<p>My code in MainActivity:</p>
<pre><code> val buttonbckbrowse =... |
72,917,142 | voximplant integration into existing app: user management & client login<p>I'm evaluating <a href="https://voximplant.com/" rel="nofollow noreferrer">VoxImplant</a> for embedding video chat into my react native application.</p>
<p>I'm using <a href="https://aws.amazon.com/amplify/" rel="nofollow noreferrer">AWS Amplify... | <p>Yes, one time keys seem to be the solution for your case. You need to store password (or md5(username+':voximplant.com:'+password) for more security) in your backend and use it to calculate the token to send to the client.</p>
<p>The client doesn't transmit password to backend. The authentication flow is the followi... | voximplant integration into existing app: user management & client login | amazon-cognito|aws-amplify|voximplant | 0 | 74 | 1 | 72,935,950 | 72,935,950 | 0 | true | 2022-07-08T21:24:50.643Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
voximplant integration into existing app: user management & client login<p>I'm evaluating <a href="https://voximplant.com/" rel="nofollow noreferrer">VoxImpl... |
72,866,006 | Querydsl - How to get sum of columns<p>These below is my STOCK TABLE info</p>
<pre><code>id, bigint(20)
available_quantity, int(11)
allocation_quantity, int(11)
stop_quantity, int(11)
damage_quantity, int(11)
standby_quantity, int(11)
</code></pre>
<p>I'd like to do a query than in sql it's:</p>
<pre class="lang-sql pr... | <p>The error message gives you a great hint about the issue. The value stock.availableQuantity, stock.standbyQuantity, and stock.allocationQuantity are all objects of type NumberExpression. Read the NumberExpression documentation here:</p>
<p><a href="https://querydsl.com/static/querydsl/latest/apidocs/com/querydsl/c... | Querydsl - How to get sum of columns | java|spring-boot|querydsl | 0 | 74 | 1 | 72,946,587 | 72,946,587 | 0 | true | 2022-07-05T08:07:22.717Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Querydsl - How to get sum of columns<p>These below is my STOCK TABLE info</p>
<pre><code>id, bigint(20)
available_quantity, int(11)
allocation_quantity, int(... |
72,911,766 | Synchronization of multiple catalogs in hybris<p>I need help on this issue. I am upgrading hybris to version 2105, I ran into the problem that the 'DefaultSetupSyncJobService' class has changed its methods from 'SyncItemJob' to 'SyncItemJobModel'. How could I adapt these classes so that the catalogs are correctly synch... | <p>The new implementation for synchronization is stored in <code>CatalogSynchronizationService.synchronizeFully(source,target)</code> for a full synchronization. There are other methods to perform partial syncs with a select subset of items aswell in that service.</p>
<p><strong>Do note</strong> that this will always <... | Synchronization of multiple catalogs in hybris | upgrade|sap-commerce-cloud | 1 | 74 | 1 | 72,953,263 | 72,953,263 | 0 | true | 2022-07-08T12:56:24.440Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Synchronization of multiple catalogs in hybris<p>I need help on this issue. I am upgrading hybris to version 2105, I ran into the problem that the 'DefaultSe... |
72,965,338 | logic app standard - managed identity connection NOT visible<p>I'm creating Azure logic app standard, However, in logic app standard I'm unable to see the option to create managed identity connection for Azure Blob Storage.
I have enabled Identity and added a contributor role to the Azure storage.
<a href="https://i.st... | <p>You can able to find it under the <strong>Azure >> When a blob is added or modified (properties only) (V2)</strong></p>
<p><a href="https://i.stack.imgur.com/Ymve9.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/Ymve9.png" alt="enter image description here" /></a></p>
<p><a href="https://i.s... | logic app standard - managed identity connection NOT visible | azure-logic-app-standard | 0 | 74 | 1 | 72,965,515 | 72,965,515 | 0 | true | 2022-07-13T11:15:05.183Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
logic app standard - managed identity connection NOT visible<p>I'm creating Azure logic app standard, However, in logic app standard I'm unable to see the op... |
72,968,242 | Golang Twitter API - update_profile_banner Image COMPRESSION_ERROR<p>I am trying to update banner image using <a href="https://developer.twitter.com/en/docs/twitter-api/v1/accounts-and-users/manage-account-settings/api-reference/post-account-update_profile_banner" rel="nofollow noreferrer">account/update_profile_banner... | <p>Resolved the problem. Carelessness!</p>
<p>I learned that Twitter used the <a href="https://developer.twitter.com/en/docs/twitter-api/v1/media/upload-media/api-reference/post-media-upload" rel="nofollow noreferrer">media/upload</a> method and then updated the <code>media_id</code> value by sending it to the <a href=... | Golang Twitter API - update_profile_banner Image COMPRESSION_ERROR | api|http|go|twitter | 1 | 74 | 1 | 72,974,203 | 72,974,203 | 0 | true | 2022-07-13T14:46:43.847Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Golang Twitter API - update_profile_banner Image COMPRESSION_ERROR<p>I am trying to update banner image using <a href="https://developer.twitter.com/en/docs/... |
72,992,576 | Firebase multiple real time databases, custom auth issues<p>I'm attempting to use multiple real time databases for my single project in Firebase. For my setup, I'm generating tokens and sending to users from a server that is not part of Google's servers.</p>
<p>Everything works so far for the default database, but issu... | <p>Okay so that link at the end was the answer, I just didn't expect to have to do this.</p>
<p>If you specify auth for each database, since the databases are declared in different apps, you have to authenticate the user with each one before being able to read/write.</p>
<p>In other words, to make it work I had to sign... | Firebase multiple real time databases, custom auth issues | javascript|firebase|firebase-realtime-database | 0 | 74 | 2 | 73,000,847 | 73,000,847 | 0 | true | 2022-07-15T10:27:29.183Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Firebase multiple real time databases, custom auth issues<p>I'm attempting to use multiple real time databases for my single project in Firebase. For my setu... |
73,015,437 | Generator Efficiency in Python<p>I understand that generators in Python can help for reading and processing large files when specific transformations or outputs are needed from the file (i.e. such as reading a specific column or computing an aggregation).</p>
<p>However, for me it's not clear if there is any benefit in... | <p>The DataFrame you get from <code>pd.read_csv('sample_file.csv')</code> might fit into memory; however, <code>pd.read_csv</code> itself is a memory intensive function so while reading a file that will end up consuming 10 gigabytes of memory your actual memory usage may exceed 30-40 gigabytes. In cases like this, read... | Generator Efficiency in Python | python|pandas|generator | 2 | 74 | 1 | 73,015,775 | 73,015,775 | 0 | true | 2022-07-17T21:19:35.380Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Generator Efficiency in Python<p>I understand that generators in Python can help for reading and processing large files when specific transformations or outp... |
73,020,543 | Nested v-for Loop in Vue Selecting Wrong Checkbox<p>I have a nested loop in a vue component. The first loop is to create four dropdown boxes, the second loop is to create three options within each dropdown box. I have attached the image to illustrate. They work correctly in that if I select the checkbox for any of the ... | <p>It happens because the input <strong>id</strong> was the same for all inputs with the same letter, so 1b and 3b have the same <strong>id</strong>. Try to modify the <strong>id</strong> attribute, e.g. add a number to differentiate ids.</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="false"... | Nested v-for Loop in Vue Selecting Wrong Checkbox | vue.js|checkbox|vue-component|v-for | 1 | 74 | 2 | 73,020,852 | 73,020,852 | 0 | true | 2022-07-18T10:06:26.900Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Nested v-for Loop in Vue Selecting Wrong Checkbox<p>I have a nested loop in a vue component. The first loop is to create four dropdown boxes, the second loop... |
72,903,106 | CircleCI is unable to read the JUnit xml generated by Behave while splitting the test by timings<p>Ok, so I am trying to split my Appium tests by their timing in CircleCI for running the test in parallel. My tests are written in behave(Python) and I am generating the JUnit XML file. Here is my config.yml file</p>
<pre>... | <p>If anyone face such issue, please take a look at the classname in the JUnit report. There is a format in which CircleCI read the classname. In my case, the classname in the JUnit report was mentioned as</p>
<pre><code>features.featurefiles.Login.feature
</code></pre>
<p>But the CircleCI was looking for the classname... | CircleCI is unable to read the JUnit xml generated by Behave while splitting the test by timings | junit|circleci|python-behave | 0 | 74 | 1 | 73,064,475 | 73,064,475 | 0 | true | 2022-07-07T19:12:52.373Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
CircleCI is unable to read the JUnit xml generated by Behave while splitting the test by timings<p>Ok, so I am trying to split my Appium tests by their timin... |
72,822,474 | How to fix Label in StackLayout Xamarin<p>When the <code>Label</code> moves to another line, the <code>Grid</code> shifts.
There is a grid with two <code>Columns</code> and two <code>Rows</code>. The left rows are connected. They should have a <code>BoxView</code> with an image, the <code>BoxView</code> creates a borde... | <p>So I dug into the truth, it turns out my problem was the empty bottom row of the grid.</p>
<pre><code><ContentPage.Content>
<Grid rainbow:DebugRainbow.ShowColors="True">
<Grid.RowDefinitions>
<RowDefinition Height="*"/>
<RowDefinition... | How to fix Label in StackLayout Xamarin | xamarin|grid|label|cell|stacklayout | 0 | 74 | 2 | 72,861,137 | 72,861,137 | 0 | true | 2022-06-30T21:59:36.477Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to fix Label in StackLayout Xamarin<p>When the <code>Label</code> moves to another line, the <code>Grid</code> shifts.
There is a grid with two <code>Col... |
72,840,822 | How can i set full page size textbox ( like notepad ) with tkinter python?<p>I want to set a full page size textbox with tkinter in python. I want to do this because if the program run with full page textbox, i can write value from rfid automatically. Otherwise i have to click the page if i want to write value with rfi... | <p>You should use <code>tk.Text</code>. It has <code>-height</code> and <code>-width</code> options. You can use <code>root.width()</code> for the window's width and <code>root.height()</code> for the window's height.</p>
<pre class="lang-py prettyprint-override"><code>text = tk.Text(root, width = root.width(), height ... | How can i set full page size textbox ( like notepad ) with tkinter python? | python|python-3.x|tkinter | 1 | 74 | 1 | 72,841,712 | 72,841,712 | 0 | true | 2022-07-02T16:48:48.187Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How can i set full page size textbox ( like notepad ) with tkinter python?<p>I want to set a full page size textbox with tkinter in python. I want to do this... |
72,834,945 | Is it possible to map multiple query string parameters to a property of an Angular service component?<p>Question: Is it possible to retrieve a collection of query string values and assign them to a property of type <code>Filter</code> in a service component class?</p>
<pre class="lang-js prettyprint-override"><code>int... | <p>You could make it very simple, as long as your class properties are the same name as the query string keys, you can do something like this:</p>
<pre class="lang-js prettyprint-override"><code>export class SearchPageComponent {
title = '';
genreId = '';
inCinemas = '';
upcomingReleases = '';
constructor(p... | Is it possible to map multiple query string parameters to a property of an Angular service component? | angular|typescript | -2 | 74 | 2 | 72,835,063 | 72,835,063 | 0 | true | 2022-07-01T21:54:50.570Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Is it possible to map multiple query string parameters to a property of an Angular service component?<p>Question: Is it possible to retrieve a collection of ... |
72,884,675 | Margin between card with bootstrap<p>I have some card with bootstrap and I would like to have left margin...I would like the cards to be evenly distributed across the width.
Basically, You can see that there is red on the right, and I wish there wasn't...</p>
<p><div class="snippet" data-lang="js" data-hide="false" dat... | <p>Remove the <code>margin-right: 1rem;</code> from the <code>.card-annuaire</code> class, and replace <code>g-0</code> on your <code>row</code> class to <code>gx-3</code>. This adds gutters in between your cards</p>
<p>Edit: Check this link out for more info on how gutters work in bootstrap: <a href="https://getbootst... | Margin between card with bootstrap | html|css|bootstrap-5 | 0 | 74 | 3 | 72,884,963 | 72,884,963 | 0 | true | 2022-07-06T13:44:35.177Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Margin between card with bootstrap<p>I have some card with bootstrap and I would like to have left margin...I would like the cards to be evenly distributed a... |
72,910,257 | Linux kernel - tracefs vs debugvs<p>How do <code>tracefs</code> and <code>debugfs</code> differ? It looks like both can trace functions, system calls, etc. When to go for <code>debugfs</code> and when should we should use <code>tracefs</code>?</p> | <p><strong>You should use <code>/sys/kernel/tracing</code>.</strong> Both <code>/sys/kernel/tracing</code> and <code>/sys/kernel/debug/tracing</code> are <code>tracefs</code> mounts, so in theory they are equivalent. However, the second one depends on <code>debugfs</code> being available (since it is created inside the... | Linux kernel - tracefs vs debugvs | debugging|linux-kernel|trace | 0 | 74 | 1 | 72,911,117 | 72,911,117 | 0 | true | 2022-07-08T10:43:41.940Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Linux kernel - tracefs vs debugvs<p>How do <code>tracefs</code> and <code>debugfs</code> differ? It looks like both can trace functions, system calls, etc. W... |
72,955,922 | How to complete reminders with no due date (or due today) in 1 line without creating a dummy reminder?<p>I am trying to write an AppleScript that completes all reminders that match a name and list, but if they're either without a due date OR overdue (due date < today).</p>
<p>I know that I can loop over reminders to... | <h1>Updated Answer</h1>
<p>There was a problem with my first answer which I worked out. Neither my script nor the script in the other answer would complete a due reminder shown in the Reminders app as not completed. I think that this is due to either a reminder synch issue (between multiple devices) or due to the fac... | How to complete reminders with no due date (or due today) in 1 line without creating a dummy reminder? | types|applescript|typeerror|reminders | 0 | 74 | 1 | 72,995,936 | 72,995,936 | 0 | true | 2022-07-12T16:59:50.427Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to complete reminders with no due date (or due today) in 1 line without creating a dummy reminder?<p>I am trying to write an AppleScript that completes a... |
73,009,215 | How can I deserialize my JSON for C# so that I can request a specific duplicate variable?<p>I have a JSON string that I would like to de-serialize for my Unity game using C#. The string looks like this:
<a href="https://i.stack.imgur.com/cq5CF.png" rel="nofollow noreferrer">https://i.stack.imgur.com/cq5CF.png</a></p>
<... | <p>If I got you correctly, I think the easiest way is to generate a class with something like this <a href="https://json2csharp.com/" rel="nofollow noreferrer">https://json2csharp.com/</a></p>
<p>That will give you this:</p>
<pre><code>// Root myDeserializedClass = JsonConvert.DeserializeObject<Root>(myJsonRespon... | How can I deserialize my JSON for C# so that I can request a specific duplicate variable? | c#|json|unity3d|json.net|json-deserialization | 0 | 74 | 2 | 73,009,833 | 73,009,833 | 0 | true | 2022-07-17T04:14:30.900Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How can I deserialize my JSON for C# so that I can request a specific duplicate variable?<p>I have a JSON string that I would like to de-serialize for my Uni... |
72,897,770 | fetching data using redux<p>I'm new to redux and I'm trying to fetch some data in my slice file, then put it in my state to use it across my app.
so I read the documentation in redux website. it says:</p>
<p>"Let's start by adding a thunk that will make an AJAX call to retrieve a list of posts. We'll import the cl... | <p>Oh yeah now i understand what you want, client is just like fetch, i assume they are using axios , then in client.js file they are exporting axios at the end.
An example, client.js file:</p>
<pre><code>import axios from "axios";
export const client = axios.create({
baseURL: 'https://some-domain.com/api/'... | fetching data using redux | reactjs|redux|react-redux | 0 | 74 | 3 | 72,898,858 | 72,898,858 | 0 | true | 2022-07-07T12:23:59.757Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
fetching data using redux<p>I'm new to redux and I'm trying to fetch some data in my slice file, then put it in my state to use it across my app.
so I read t... |
72,785,345 | Attempt to invoke virtual method 'void androidx.recyclerview.widget.RecyclerView.setLayoutManager(androidx.recyclerview..)' on a null object reference<p>I want to write a good chat application with bottom navigation using Fragments. In ChatsFragment.kt I got a problem: <a href="https://i.stack.imgur.com/buB0V.png" rel=... | <p>To solve this issue you need to pass the context of fragment. in Kotlin below code can solve your problem. Just pass "activity"</p>
<pre><code> val layoutManager = LinearLayoutManager(activity)
</code></pre>
<p>You can also user</p>
<pre><code> layoutManager = LinearLayoutManager(requireActivity())
</cod... | Attempt to invoke virtual method 'void androidx.recyclerview.widget.RecyclerView.setLayoutManager(androidx.recyclerview..)' on a null object reference | android|kotlin|android-recyclerview|linearlayoutmanager | 0 | 74 | 4 | 72,786,973 | 72,786,973 | 0 | true | 2022-06-28T11:07:08.753Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Attempt to invoke virtual method 'void androidx.recyclerview.widget.RecyclerView.setLayoutManager(androidx.recyclerview..)' on a null object reference<p>I wa... |
72,970,145 | Setting a property in Blazor<p>I've spent too many hours trying to accomplish something that should be very simple, so reaching out to this group. I'm simply trying to update the value of a property of a Blazor form but it doesn't execute the code--it only renders the code on the browser page.</p>
<p>I'm trying to set ... | <p>I think this is what you want. I didn't test it.</p>
<pre><code>@{
string priorWorkspace = "";
foreach (var rpt in rptObj)
{
<tr>
@if (priorWorkspace == rpt.WorkspaceName)
{
<td></td>
<t... | Setting a property in Blazor | c#|razor|blazor|blazor-server-side | 0 | 74 | 1 | 72,970,296 | 72,970,296 | 0 | true | 2022-07-13T17:10:27.590Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Setting a property in Blazor<p>I've spent too many hours trying to accomplish something that should be very simple, so reaching out to this group. I'm simply... |
72,839,807 | merging .tif files via gdalbuildvrt not working<p>I have a piece of code that I have used for a while now to transform .xyz files to .tif and then merge all those .tif files into one big .tif. It has worked well when I last used it 2 years ago, but it seems like the current updates/discontinuation of packages have lead... | <p>You can do</p>
<pre><code>library(terra)
ff <- list.files(path =".", pattern = '\\.tif$', full.names = TRUE)
v <- vrt(ff, "dem.vrt")
writeRaster(v, "out.tif")
</code></pre> | merging .tif files via gdalbuildvrt not working | r|merge|tiff|gdal|rgdal | 0 | 74 | 1 | 72,840,345 | 72,840,345 | 0 | true | 2022-07-02T14:25:12.230Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
merging .tif files via gdalbuildvrt not working<p>I have a piece of code that I have used for a while now to transform .xyz files to .tif and then merge all ... |
72,867,085 | Azure Devops construct variable from map parameter<p>The <a href="https://docs.microsoft.com/en-us/azure/devops/pipelines/process/templates?view=azure-devops" rel="nofollow noreferrer">Azure Devops template</a> I am working on I want to construct a variable from input parameter named <code>terraformVars</code>:</p>
<pr... | <p>The way you are using is wrong, there is no such way of using expression. Note the use of Directives and the use of compile-time parameters, do not confuse the two.</p>
<p>Directives are not supported for expressions that are embedded within a string. Directives are only supported when the entire value is an express... | Azure Devops construct variable from map parameter | azure-devops|azure-pipelines | 0 | 74 | 1 | 72,885,437 | 72,885,437 | 0 | true | 2022-07-05T09:31:09.887Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Azure Devops construct variable from map parameter<p>The <a href="https://docs.microsoft.com/en-us/azure/devops/pipelines/process/templates?view=azure-devops... |
73,000,833 | Report pytest-stress results individually for each iteration in pytest-html<p>I need to use <a href="https://github.com/pytest-dev/pytest-stress/blob/main/src/pytest_stress/pytest_stress.py" rel="nofollow noreferrer">pytest-stress</a> to run tests for a period of time. Previously, I was using <a href="https://github.co... | <p>Created my own pytest plugin called pytest-loop. It merges pytest-stress and pytest-repeat with a fix to clear previous reports.</p>
<p><a href="https://github.com/anogowski/pytest-loop" rel="nofollow noreferrer">https://github.com/anogowski/pytest-loop</a></p>
<p><a href="https://pypi.org/project/pytest-loop/" rel=... | Report pytest-stress results individually for each iteration in pytest-html | python|pytest|pytest-html | 0 | 74 | 1 | 73,029,370 | 73,029,370 | 0 | true | 2022-07-16T00:59:06.663Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Report pytest-stress results individually for each iteration in pytest-html<p>I need to use <a href="https://github.com/pytest-dev/pytest-stress/blob/main/sr... |
72,874,956 | AWK match string using regex and combine with previous string<p>I have been reviewing articles and posts on how to match and compare strings but I am struggling to put the two together, unfortunately, I do not have an example awk command that I am trying to make work because I can't seem to even get that far. Below is ... | <p>Using <code>sed</code></p>
<pre><code>$ sed 's#\(\<[[:digit:].]\+\)[^[:digit:]]*\([[:digit:]]\+\)#\1/\2#g' input_file
hostname1 hostname2 127.0.0.1/27 127.0.0.2/24 127.0.0.3/28 hostname3 127.0.0.4/27 127.0.0.5/24 127.0.... | AWK match string using regex and combine with previous string | linux|bash|awk|sed|grep | 0 | 74 | 4 | 72,875,100 | 72,875,100 | 0 | true | 2022-07-05T20:03:08.353Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
AWK match string using regex and combine with previous string<p>I have been reviewing articles and posts on how to match and compare strings but I am struggl... |
72,820,434 | subtracting column from unmatched dataFrame by mapping it to matching column<p>I have two DataFrame as listed below</p>
<pre class="lang-py prettyprint-override"><code>plusMinusOne = pd.DataFrame({0: [2459650, 2459650,2459650,2459654,2459654,2459654,2459660], 1: [100, 90,80,14,15,16,2]},index=[3,4,5,12,13,14,27])
bia... | <p>Vectorized solution,</p>
<pre><code>def bias_diff(row):
value = 0
if (row[0] == bias[0]).any():
value = row[1] - bias[(row[0]) == bias[0]].iloc[0,1]
elif ((row[0]+1) == bias[0]).any():
value = row[1] - bias[(row[0]+1) == bias[0]].iloc[0,1]
else:
value = row[1] - bias[(row[0]-1... | subtracting column from unmatched dataFrame by mapping it to matching column | python|pandas|dataframe | 1 | 74 | 2 | 72,822,616 | 72,822,616 | 0 | true | 2022-06-30T18:24:37.950Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
subtracting column from unmatched dataFrame by mapping it to matching column<p>I have two DataFrame as listed below</p>
<pre class="lang-py prettyprint-overr... |
72,931,669 | How do I extract a substring from a larger string?<p>I'm very new to webscraping and I'm grabbing from a website from Billboard that compiled the top 10 summer songs for each year from 1958 to 2021. My main goal is to end up with a dictionary with the year number as the key and a list with the 10 songs as the associate... | <p>There is no need for <code>regex</code> - To get your expected output select only the <code><p></code> that has an <code><strong></code> and iterate over its texts <code>[s.split(', ')[1] for s in p.find_all(text=True)[2:]]</code>:</p>
<pre><code>from bs4 import BeautifulSoup
import pandas as pd
import r... | How do I extract a substring from a larger string? | python|regex|string|list|web-scraping | 0 | 74 | 1 | 72,932,053 | 72,932,053 | 0 | true | 2022-07-10T20:28:36.370Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do I extract a substring from a larger string?<p>I'm very new to webscraping and I'm grabbing from a website from Billboard that compiled the top 10 summ... |
72,812,030 | Is it possible to query Firebase Firestore by both a location and age range?<p>How can I query my Firestore database based on age range and location.</p>
<p>For example, let's say I want to get all users that are between the age of 18 and 30, and are within 5 miles me.</p>
<p>Here's a simplified version of my current d... | <p>Based on @Frank van Puffelen's <a href="https://stackoverflow.com/a/72818922/16602527">answer</a>, I think the best solution (at least in the case of an app that needs to scale) is the pre-filtering option because we can keep database storage and read costs at a minimum (explained under the <strong>Best Solution</st... | Is it possible to query Firebase Firestore by both a location and age range? | swift|firebase|google-cloud-firestore | 0 | 74 | 2 | 72,943,100 | 72,943,100 | 0 | true | 2022-06-30T07:44:35.870Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Is it possible to query Firebase Firestore by both a location and age range?<p>How can I query my Firestore database based on age range and location.</p>
<p>... |
73,024,144 | Subgroup ArcPy list Query<p>Mornig, folks.</p>
<p>I have two equal sets of layers, disposed in subgroups in my ArcGIS Pro (2.9.0), as shown <a href="https://i.stack.imgur.com/3vFP2.png" rel="nofollow noreferrer">here</a>.
It's important that they have the same name (Layer1, Layer2, ...) in both groups.
Now, I'm writing... | <p>The layer's <code>name</code> (or <code>longName</code>) does not include the group layer's name.</p>
<p>Try using a <a href="https://pro.arcgis.com/en/pro-app/latest/arcpy/mapping/map-class.htm" rel="nofollow noreferrer">wildcard</a> (follow the link and search for <code>listLayers</code>) and filter for the partic... | Subgroup ArcPy list Query | python|arcgis|arcpy | -1 | 74 | 1 | 73,028,536 | 73,028,536 | 0 | true | 2022-07-18T14:39:46.250Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Subgroup ArcPy list Query<p>Mornig, folks.</p>
<p>I have two equal sets of layers, disposed in subgroups in my ArcGIS Pro (2.9.0), as shown <a href="https://... |
72,984,833 | F#: Remove an event that was added in code I don't control<p>I'm working with F# and ScottPlot, and I need to replace ScottPlot's built-in right click event with my own. As ScottPlot's website describes (<a href="https://scottplot.net/faq/right-click-menu/" rel="nofollow noreferrer">https://scottplot.net/faq/right-clic... | <p>In the end, basically what <a href="https://stackoverflow.com/users/2088029/mrd-at-kookerellaltd">MrD at KookerellaLtd</a> suggested, I created the plot in a C# project, removed the event handler, and returned the modified plot to the F# code. Thanks for your suggestions, but this ended up being the cleanest, especi... | F#: Remove an event that was added in code I don't control | f# | 1 | 74 | 3 | 73,026,476 | 73,026,476 | 0 | true | 2022-07-14T17:59:27.100Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
F#: Remove an event that was added in code I don't control<p>I'm working with F# and ScottPlot, and I need to replace ScottPlot's built-in right click event ... |
72,807,520 | create a new nested JSON column in Snowflake<p>I'm trying to convert a few columns in Snowflake table into a nested JSON and have tried <code>OBJECT_CONSTRUCT</code> & <code>ARRAY_CONSTRUCT</code> - but, unable to create a nested JSON</p>
<p><strong>Input:</strong></p>
<div class="s-table-container">
<table class="... | <p>Solution, with hard-coding field-names only, just need to put functions <code>ARRAY_CONSTRUCT</code> and <code>OBJECT_CONSTRUCT</code> in proper order.</p>
<pre><code>with cte(id,product_1,product_1_purchase_date,product_2,product_2_purchase_date) as
(select * from values
(100,'XCTMR','01/02/2003','IOPWER','01/02/20... | create a new nested JSON column in Snowflake | pandas|snowflake-cloud-data-platform | 0 | 74 | 1 | 72,808,602 | 72,808,602 | 0 | true | 2022-06-29T20:32:18.027Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
create a new nested JSON column in Snowflake<p>I'm trying to convert a few columns in Snowflake table into a nested JSON and have tried <code>OBJECT_CONSTRUC... |
72,913,818 | How To Access my Sprite properties from outside a function in Phaser3 and Matterjs<p>I'm using phaser 3 and Matterjs. I created a function (arrow function) and created a sprite within and it worked fine, but when I set it's velocity within the function it moves a little while and stops, it happens in other instances ou... | <p>Well the reason why the <code>sprite</code> slows down, is because in <code>matterjs</code> the velocity is <em>"dampened"</em>, if you don't want that the velocity to be slowed down, just set the friction to <code>0</code>, with the function <code>setFriction</code> (link <a href="https://photonstorm.gith... | How To Access my Sprite properties from outside a function in Phaser3 and Matterjs | javascript|phaser-framework|matter.js | 1 | 74 | 1 | 72,914,249 | 72,914,249 | 0 | true | 2022-07-08T15:38:07.807Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How To Access my Sprite properties from outside a function in Phaser3 and Matterjs<p>I'm using phaser 3 and Matterjs. I created a function (arrow function) a... |
72,928,079 | The await expression can only be used in an async function. Although there is async in this function in Flutter/Dart<p>I have an asynchronous function for checking internet access which is in another file. Here is its code:</p>
<pre class="lang-dart prettyprint-override"><code>//Check User Connection
class CheckUserCon... | <p>you called <code>bool _internetAvailable = await _checkUserConnection.checkInternetAvailability();</code> in build method, In the event that build method can't be <code>async</code>.</p>
<p>you must be do like below code:</p>
<pre><code>class _MainWidgetState extends State<MainWidget> {
bool? _internetAvail... | The await expression can only be used in an async function. Although there is async in this function in Flutter/Dart | flutter|dart|flutter-layout | -1 | 74 | 2 | 72,928,143 | 72,928,143 | 0 | true | 2022-07-10T11:17:34.050Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
The await expression can only be used in an async function. Although there is async in this function in Flutter/Dart<p>I have an asynchronous function for ch... |
72,770,977 | why cant my vscode check for C++17 (my compiler is clang 12)?<p><a href="https://i.stack.imgur.com/Ap1GF.png" rel="nofollow noreferrer">This follow is my remote server and local vscode </a></p>
<p>this follow context</p>
<pre><code> "configurations": [
{
"name": "Linux&qu... | <p>This problem is because of a cmake tool plugin, find your <code>compile_commands.json</code> file in your remote server, and edit to add the option <code>-std=c++17</code>; thus, change e.g.</p>
<pre><code>"command": "/usr/bin/clang++-12 -g -o CMakeFiles/linuxCode.dir/main.cpp.o -c /home/source/mai... | why cant my vscode check for C++17 (my compiler is clang 12)? | visual-studio-code|clang++|vscode-remote | 2 | 74 | 1 | 72,772,152 | 72,772,152 | 0 | true | 2022-06-27T10:58:11.050Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
why cant my vscode check for C++17 (my compiler is clang 12)?<p><a href="https://i.stack.imgur.com/Ap1GF.png" rel="nofollow noreferrer">This follow is my rem... |
72,825,800 | My "Edit Build Pipeline" Permissions in Azure DevOps are set to Deny but I can still edit the YAML file in both classic/repo?<p>I have a build pipeline permissions question in Azure DevOps.</p>
<p>I have selected "deny" for "edit build pipeline" which Microsoft docs describes as: "Can create pi... | <p>Since the YAML files are stored as the source files in the corresponding Git repository, if you have the permissions to edit the source files in the repository, you can edit the YAML files. It is not affected by the "<strong>Edit build pipeline</strong>" option.</p>
<p>For the YAML pipeline, the "<str... | My "Edit Build Pipeline" Permissions in Azure DevOps are set to Deny but I can still edit the YAML file in both classic/repo? | azure-devops|permissions|continuous-integration|azure-pipelines | 0 | 74 | 1 | 72,827,201 | 72,827,201 | 0 | true | 2022-07-01T07:31:41.070Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
My "Edit Build Pipeline" Permissions in Azure DevOps are set to Deny but I can still edit the YAML file in both classic/repo?<p>I have a build pipeline permi... |
72,828,114 | How fix this null check issue?<p>Dart Language:</p>
<p>This is plugin issue
xmpp_stone plugin
I can't fix this issue
anyone known please replay
[![enter image description here]
https://i.stack.imgur.com/FHe0O.png</p>
<p>Dart Language:</p>
<p>This is plugin issue
xmpp_stone plugin
I can't fix this issue
anyone known ple... | <p>Your problem is that you are not using <code>xmpp_stone</code> correctly and therefore ends up in a situation where the internal state of <code>xmpp_stone</code> does not match what the developer of the package have intended.</p>
<p>I do, however, think the package are badly designed in such a way that wrong usage a... | How fix this null check issue? | dart | -2 | 74 | 2 | 72,837,366 | 72,837,366 | 0 | true | 2022-07-01T10:46:55.860Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How fix this null check issue?<p>Dart Language:</p>
<p>This is plugin issue
xmpp_stone plugin
I can't fix this issue
anyone known please replay
[![enter imag... |
72,773,631 | Heroku flask + socket.io 400 BAD REQUEST<p>Hello im trying to deploy my flask app on heroku. Im using flask_socketio module and socket.io in version 4.5(i didn't know how to initialize in 2.3.x version - io())</p>
<p>Here's my flask code:</p>
<pre><code>from flask import Flask, render_template, url_for, redirect, sessi... | <p><code>eventlet==0.30.2</code> in requirements.txt and <code>python-3.8.13</code> in runtime.txt did the job!
Procfile: <code>web: gunicorn --worker-class eventlet -w 1 main:app</code></p> | Heroku flask + socket.io 400 BAD REQUEST | flask|heroku|socket.io|flask-socketio | 0 | 74 | 1 | 72,782,928 | 72,782,928 | 0 | true | 2022-06-27T14:18:47.787Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Heroku flask + socket.io 400 BAD REQUEST<p>Hello im trying to deploy my flask app on heroku. Im using flask_socketio module and socket.io in version 4.5(i di... |
72,778,989 | Kotlin multi platform flow block convert to custom wrapper flow use for ios<p>I have a kotlin multi platform project which contains apollo graphql api</p>
<p><strong>in this project i have BaseRepository Class and in this class there is a method to execute query or mutations</strong></p>
<pre><code>suspend fun <D : ... | <p>We have pretty much the same thing in one of our projects. We have a extension function that converts the regular flow to a "common" flow so it can be used in both Android and iOS.</p>
<p>You can created flow like always, and wrap it at the end.</p>
<pre><code>fun <T> Flow<T>.wrap(): CommonFlow... | Kotlin multi platform flow block convert to custom wrapper flow use for ios | java|kotlin|graphql|kotlin-coroutines|kotlin-multiplatform | 0 | 74 | 1 | 72,782,226 | 72,782,226 | 1 | true | 2022-06-27T22:43:44.263Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Kotlin multi platform flow block convert to custom wrapper flow use for ios<p>I have a kotlin multi platform project which contains apollo graphql api</p>
<p... |
72,785,920 | Pass function into pandas groupby<p>I have a df that looks like this:</p>
<pre><code>d = {'type': ['A', 'A', 'A' ,'A' , 'A', 'A', 'A','A' ,'A' ,'A', 'A', 'A', 'A','B', 'B', 'B' ,'B' , 'B', 'B', 'B','B' ,'B' ,'B', 'B', 'B', 'B'],
'Date': ['Jun-21','Jul-21','Aug-21','Sep-21','Oct-21','Nov-21','Dec-21','Jan-22','Feb-22'... | <p>Try grouping by <code>type</code> and apply <code>my_function()</code>. One change to make it work is to iterate over the index instead of <code>range(len(df))</code>, because the program needs to run in different groups.</p>
<pre class="lang-py prettyprint-override"><code>def my_function(d):
# initialize with 0... | Pass function into pandas groupby | python|pandas|numpy | 1 | 74 | 1 | 72,790,908 | 72,790,908 | 1 | true | 2022-06-28T11:52:42.283Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Pass function into pandas groupby<p>I have a df that looks like this:</p>
<pre><code>d = {'type': ['A', 'A', 'A' ,'A' , 'A', 'A', 'A','A' ,'A' ,'A', 'A', 'A'... |
72,987,182 | Azure DevOps Artifacts getting deleted<p>I have a bunch of Azure Pipeline and Release packages. The piplines build and publish my code to a testing environment every night, and as part of that publish they create artifacts used by the selenium testing software.</p>
<p>This has been working correctly for several years ... | <p>It seems I have figured out the problem, and it appears to be a change in the way Azure Devops works with the newest version. This is the first version I have noticed this issue in:</p>
<p>Azure DevOps Server 2020 Update 1.1</p>
<p>The settings indicate that artifacts should be kept for 20 days in my instance. How... | Azure DevOps Artifacts getting deleted | azure-devops | 0 | 74 | 1 | 73,419,431 | 73,419,431 | 0 | true | 2022-07-14T22:16:47.767Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Azure DevOps Artifacts getting deleted<p>I have a bunch of Azure Pipeline and Release packages. The piplines build and publish my code to a testing environm... |
72,246,515 | Deploying React front end with Django session based auth doesnt work over HTTPS<p>So I have a working LOCAL Twitter clone called Hater but cant deploy front end b/c I cant access secured Cookies(<a href="https://github.com/mustafabin/hater" rel="nofollow noreferrer">https://github.com/mustafabin/hater</a>)</p>
<p>I use... | <p>Super late reply but its not possible to securely use session based auth when my backend service was deployed on a different domain.</p>
<p>front end was on netifly
back end was on heroku</p>
<p>a better alternative that I used was django knox tokens it behaves the same way as JWT authentication but has more functio... | Deploying React front end with Django session based auth doesnt work over HTTPS | django|cookies|django-rest-framework|web-deployment|django-csrf | 0 | 74 | 1 | 73,557,857 | 73,557,857 | 0 | true | 2022-05-15T08:01:23.087Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Deploying React front end with Django session based auth doesnt work over HTTPS<p>So I have a working LOCAL Twitter clone called Hater but cant deploy front ... |
72,248,495 | would anything happen if I pass a pointer function as a parameter?<p>I wonder that what would happen if I pass a <strong>pointer function</strong> as a parameter, is it valid and is the memory of that <strong>pointer function</strong> stuck somewhere in RAM?</p>
<p>This is the example:</p>
<pre><code>char* Function1(ch... | <p>It is <strong>valid</strong> to write these kind of function calls but as you suspected, the memory you've allocated for the character array in subsequent function calls will be stuck in RAM, a <strong>memory leak</strong>. Let me explain with the following code.</p>
<pre class="lang-cpp prettyprint-override"><code>... | would anything happen if I pass a pointer function as a parameter? | c++|pointers | 0 | 74 | 3 | 72,248,846 | 72,248,846 | 0 | true | 2022-05-15T12:59:56.840Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
would anything happen if I pass a pointer function as a parameter?<p>I wonder that what would happen if I pass a <strong>pointer function</strong> as a param... |
72,255,444 | How to click and drag a large view like in google maps?<p>Suppose I have a large view with scroll in both x and y direction and instead of scrolling with mouse scroll, I need to drag and move to navigate through the entire view like in google maps</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-consol... | <p>Thanks to the solution provided by @grisuu in the comments</p>
<p>I was able to whip up this:</p>
<p><a href="https://jsfiddle.net/vzc9brka/3/" rel="nofollow noreferrer">jsfiddle</a></p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre c... | How to click and drag a large view like in google maps? | javascript|html|css | 0 | 74 | 1 | 72,257,677 | 72,257,677 | 0 | true | 2022-05-16T07:19:45.487Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to click and drag a large view like in google maps?<p>Suppose I have a large view with scroll in both x and y direction and instead of scrolling with mou... |
72,257,372 | Why does Jooq Code Generator makes un-necessary changes to all files?<p>I'm using Jooq Code Generator and I noticed that when I make a change in the DB and run the code generator, it makes changes to all files, not just to those that should have been changed.</p>
<p>For example, I add a new table, so I see the new clas... | <p>The jOOQ code generator doesn't produce that particular import you've shown, i.e. <code>import org.jooq.*;</code>. You must have done that yourself, either manually, or via some post processing on generated code.</p>
<ul>
<li>If you did this manually, then this is clearly against the idea of what jOOQ generated code... | Why does Jooq Code Generator makes un-necessary changes to all files? | jooq|jooq-codegen | 1 | 74 | 1 | 72,258,427 | 72,258,427 | 0 | true | 2022-05-16T09:57:55.910Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why does Jooq Code Generator makes un-necessary changes to all files?<p>I'm using Jooq Code Generator and I noticed that when I make a change in the DB and r... |
72,257,531 | Any solutions on splitting output file?<p>I'm a newbie here in Talend and what I am trying to do is to split different output file, here is an example of the file that I am working on...</p>
<p><a href="https://i.stack.imgur.com/v7cyb.png" rel="nofollow noreferrer">File of Example</a></p>
<p>For example:</p>
<p>Wheneve... | <p>I would try this :</p>
<p>tFileInputExcel -> main -> tReplicate -> main -> tFilterRow (quoteName equals quote1
) -> tlog</p>
<pre><code> -> main -> tFilterRow (quoteName equals
quote2
... | Any solutions on splitting output file? | etl|talend|talend-mdm | 1 | 74 | 2 | 72,261,575 | 72,261,575 | 0 | true | 2022-05-16T10:10:50.887Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Any solutions on splitting output file?<p>I'm a newbie here in Talend and what I am trying to do is to split different output file, here is an example of the... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.