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,150,618 | LZ77 Extra Bits in DEFLATE<p>In the LZ77 phase of the DEFLATE compression, extra bits are used to represent the length and distances of the back reference. However, are these extra bits concatenated onto the base values to form a unique code to be Huffman coded, or is the base value alone Huffman coded with the extra b... | <p>The base value alone is Huffman coded, with that code followed by the associated number of extra bits representing a value to be added to the base.</p> | LZ77 Extra Bits in DEFLATE | compression|huffman-code|deflate|lz77 | 0 | 51 | 1 | 72,152,947 | 72,152,947 | 1 | true | 2022-05-07T08:02:31.873Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
LZ77 Extra Bits in DEFLATE<p>In the LZ77 phase of the DEFLATE compression, extra bits are used to represent the length and distances of the back reference. H... |
72,147,541 | Feed formats other than pbf to Osmosis<p>I've written code in Java using the <a href="https://wiki.openstreetmap.org/wiki/Osmosis" rel="nofollow noreferrer">Osmosis</a> framework and specifically OsmosisReader for Java, for OSM processing.</p>
<p>As far as I understand, OsmosisReader can only work with <code>*.pbf</cod... | <p>The <code>osmosis-xml</code> package offers the <a href="https://javadoc.io/doc/org.openstreetmap.osmosis/osmosis-xml/latest/org/openstreetmap/osmosis/xml/v0_6/XmlReader.html" rel="nofollow noreferrer"><code>XmlReader</code></a> class. It can be used to read OSM data in XML-based formats (.osm, .osm.bz2 and .osm.gz)... | Feed formats other than pbf to Osmosis | java|openstreetmap|osmosis|osm.pbf | 0 | 68 | 1 | 72,153,001 | 72,153,001 | 1 | true | 2022-05-06T21:27:54.337Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Feed formats other than pbf to Osmosis<p>I've written code in Java using the <a href="https://wiki.openstreetmap.org/wiki/Osmosis" rel="nofollow noreferrer">... |
72,152,694 | In Firestore security rules, can a custom function be used inside another custom function?<p>In Firestore security rules, I'm writing a custom function (<code>isEitherNotSecretOrIsOwner()</code>), with another custom function (<code>belongsToRequestor()</code>) inside of it, but the <a href="https://firebase.google.com... | <p>Calling one custom functions from within another one is indeed supported in Firestore security rules, as long as the function you're calling is in scope at the call site.</p> | In Firestore security rules, can a custom function be used inside another custom function? | firebase|google-cloud-firestore|firebase-security | 0 | 45 | 1 | 72,153,144 | 72,153,144 | 1 | true | 2022-05-07T12:51:42.960Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
In Firestore security rules, can a custom function be used inside another custom function?<p>In Firestore security rules, I'm writing a custom function (<cod... |
72,153,281 | AWS Lambda Runtime.UserCodeSyntaxError: Syntax error in module 'salesAnalysisReport': invalid syntax<p>I am working on AWS Solutions Architecting Module 13 Challenge Lab. I have written the following code in my AWS Lambda SalesAnalysisReport function's <code>salesAnalysisReport.py</code> file :</p>
<pre><code> respo... | <p>You need to enclose it in single quotes, so it is a <code>string</code> as required by Boto3.</p>
<p>Try:</p>
<pre class="lang-py prettyprint-override"><code>response = snsClient.publish(
TopicArn = 'arn:aws:sns:us-east-1:507782174659:SalesReportTopic',
Subject = 'Daily Sales Analysis Report',
... | AWS Lambda Runtime.UserCodeSyntaxError: Syntax error in module 'salesAnalysisReport': invalid syntax | python|python-3.x|amazon-web-services|aws-lambda | 0 | 1,143 | 1 | 72,153,309 | 72,153,309 | 1 | true | 2022-05-07T14:09:16.533Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
AWS Lambda Runtime.UserCodeSyntaxError: Syntax error in module 'salesAnalysisReport': invalid syntax<p>I am working on AWS Solutions Architecting Module 13 C... |
72,151,176 | check weather the user readed data or not in flutter using firestore<p>I was developing the chat app in flutter using firestore, the users successfully chat one-to-one. but I also want to send the notification to the user that someone sends him/her a message. For that I decided to use the cloud messaging service of fir... | <p>There is nothing built into Cloud Firestore to track which user has read a specific document already.</p>
<p>The two most common approaches that I know of are:</p>
<ul>
<li><p>To track for each individual message and each individual user whether they have read it, so by keeping a list of the user IDs in each message... | check weather the user readed data or not in flutter using firestore | flutter|dart|google-cloud-firestore | 0 | 41 | 1 | 72,153,310 | 72,153,310 | 1 | true | 2022-05-07T09:24:05.480Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
check weather the user readed data or not in flutter using firestore<p>I was developing the chat app in flutter using firestore, the users successfully chat ... |
72,153,076 | RenderFlex children have non-zero flex but incoming width constraints are unbounded in flutter<p>I ran into an error using <code>DropdownButton</code> and deleted the method in it that I do not use selectedItemBuilder and accordingly received an error, as it says that the error is due to the GFCheckboxListTile widget. ... | <p>You can replace <code>Expanded</code> with <code>SizedBox.shrink</code></p>
<pre class="lang-dart prettyprint-override"><code>child: StatefulBuilder(
builder: (context, setStateSB) => SizedBox.shrink(
child: GFCheckboxListTile(
</code></pre>
<p>More about <a href="https://api.flutter.dev/flutter/widgets/Siz... | RenderFlex children have non-zero flex but incoming width constraints are unbounded in flutter | flutter|dart | 0 | 70 | 1 | 72,153,328 | 72,153,328 | 1 | true | 2022-05-07T13:40:57.763Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
RenderFlex children have non-zero flex but incoming width constraints are unbounded in flutter<p>I ran into an error using <code>DropdownButton</code> and de... |
72,152,846 | Django display a dynamic json file content in template<p>I have a json file on Django server</p>
<ul>
<li>The file content is <strong>dynamically changing</strong></li>
<li>I <strong>don't</strong> want to store the json data as Django model <strong>in database</strong></li>
</ul>
<p>My question is: is there a techinic... | <p>There are some options, the one I recommend is to store your data in a json file inside your project, each time yo need to update your json file, could be through a signal if it is when you save some data, or in the time you need it.</p>
<p>Then in a view, read and throw to render your json file, this way, doesn't r... | Django display a dynamic json file content in template | json|django|django-templates | 0 | 113 | 2 | 72,153,334 | 72,153,334 | 1 | true | 2022-05-07T13:11:39.833Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Django display a dynamic json file content in template<p>I have a json file on Django server</p>
<ul>
<li>The file content is <strong>dynamically changing</s... |
72,153,099 | How to use the result of a completionHandler for the destination of a NavigationLink in Swift?<p>I have a function which calls a REST API and returns the result via a completionHandler.</p>
<p>I want to call this function when pressing a NavigationLink but use the result as the object passed into the destination. Can't... | <p>Assuming it's an iOS app, if you can deploy for iOS 15, you can use the recent async/ await environment, by using an async function and returning a <code>Programme</code>, instead of using a completion handler.</p>
<ol>
<li>Turn your function into async and return a <code>Programme</code>:</li>
</ol>
<pre><code> f... | How to use the result of a completionHandler for the destination of a NavigationLink in Swift? | swift|swiftui|completionhandler | 0 | 222 | 1 | 72,153,409 | 72,153,409 | 1 | true | 2022-05-07T13:45:00.657Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to use the result of a completionHandler for the destination of a NavigationLink in Swift?<p>I have a function which calls a REST API and returns the res... |
72,153,376 | Multiple charts in one page - Chartjs<p>I tried to add multiple charts in one page, but had the error <code>Canvas is already in use. Chart with ID '0' must be destroyed before the canvas can be reused</code>.</p>
<p>After research, I read that I had to set my canvas in div because :</p>
<blockquote>
<p>Detecting when ... | <p>You are passing <code>ctx</code> as a parameter for chart2, which should be <code>ctx2</code>. Right now both of your graphs are pointing to same document element i.e. to element with id <code>chart1</code>.</p>
<pre><code>const myChart2 = new Chart(ctx2, {
type: 'line',
data: data2,
options: options2
})... | Multiple charts in one page - Chartjs | javascript|canvas|chart.js | 0 | 200 | 1 | 72,153,417 | 72,153,417 | 1 | true | 2022-05-07T14:20:48.793Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Multiple charts in one page - Chartjs<p>I tried to add multiple charts in one page, but had the error <code>Canvas is already in use. Chart with ID '0' must ... |
72,153,410 | React Router Link not loading the page<p>I'm trying to redirect to page onclick of a button from my main page App.js, But my redirected page /SelectAirport does not seem to load.
I think there might be something with the link path but I can't figure out how to fix it.</p>
<p><em>TLDR: The link changes but the content d... | <p>Use Routes and Route , inside of Route define your component and path for example <code>path='/airports'</code></p>
<pre><code>import { Button } from "@mui/material";
import React from "react";
import { NavLink } from "react-router-dom";
import SelectAirport from "./SelectAirport&q... | React Router Link not loading the page | reactjs|react-router|react-link | 0 | 973 | 2 | 72,153,558 | 72,153,558 | 1 | true | 2022-05-07T14:25:23.407Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
React Router Link not loading the page<p>I'm trying to redirect to page onclick of a button from my main page App.js, But my redirected page /SelectAirport d... |
72,153,323 | TypeError: cross_entropy_loss(): argument ‘input’ (position 1) must be Tensor, not Linear<p>I was following a youtube video and learning to make a chat bot, the teacher explained this step to make the training model, the code compiled perfectly for the teacher but im getting an error. What am i doing wrong?</p>
<pre><c... | <p>The issue is with the <code>NeuralNet</code> code specifically in the line:</p>
<p><code>out = self.l3</code></p>
<p>You are setting out to be the <strong>Linear layer</strong> instead of <strong>calling</strong> the linear layer on the data. Change it to
<code>out = self.l3(out)</code>
and it will work</p> | TypeError: cross_entropy_loss(): argument ‘input’ (position 1) must be Tensor, not Linear | python|pytorch | 0 | 119 | 1 | 72,153,655 | 72,153,655 | 1 | true | 2022-05-07T14:14:29.203Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
TypeError: cross_entropy_loss(): argument ‘input’ (position 1) must be Tensor, not Linear<p>I was following a youtube video and learning to make a chat bot, ... |
72,147,678 | Meshes loaded via Assimp look distorted<p>So I'm trying to load and render mesh with assimp and DirectX11.(Im loosely following tutorials on youtube) The problem is that it looks weird and distorted. I've checked my meshes - blender and assimp viewer load them correctly.
Results of rendering suzanne from obj file:
<a h... | <p>So I've figured it out. The issue was that in some other file i already defined structure named Vertex. That structure contained also uv's so ultimately my vertex buffer ended up being a mess. Silly mistake.</p> | Meshes loaded via Assimp look distorted | c++|direct3d|assimp | 0 | 78 | 1 | 72,153,669 | 72,153,669 | 1 | true | 2022-05-06T21:47:35.870Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Meshes loaded via Assimp look distorted<p>So I'm trying to load and render mesh with assimp and DirectX11.(Im loosely following tutorials on youtube) The pro... |
72,153,609 | Newtonsoft Unexpected character while parsing value<p>I have the problem that I always get this error when deserializing an object. But when I use the bracketed code it works, but not when I retrieve it from my api</p>
<p><strong>Unexpected character encountered while parsing value: S. Path '', line 0, position 0.</str... | <p>The GetData Function is Async so you should await for it.</p>
<pre><code> var JsonString = GetData().ToString();
</code></pre>
<p>should be</p>
<pre class="lang-c# prettyprint-override"><code> var JsonString = await GetData();
</code></pre> | Newtonsoft Unexpected character while parsing value | c#|api|rest|json.net | 0 | 99 | 1 | 72,153,672 | 72,153,672 | 1 | true | 2022-05-07T14:48:56.277Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Newtonsoft Unexpected character while parsing value<p>I have the problem that I always get this error when deserializing an object. But when I use the bracke... |
72,151,299 | SVG image tag doesn't work on github README<p>I wrote sipmple server with <code>golang</code> witch should return a SVG with stats from stack-overflow. Everything works fine as long as it tests the response from my server in a browser or Postman, but when I try to pin this response as an image in the github <code>READM... | <p>GitHub serves your SVG through its own domain <code>camo.githubusercontent.com</code> and does not directly refer to your image.</p>
<pre><code><img src="https://camo.githubusercontent.com/f9e51abbda49dfb31243a3642e1f4a2f7b31371cf61e23c103c584c189a0791f/68747470733a2f2f737461636b2d73746174732e6865726f6b75617... | SVG image tag doesn't work on github README | image|github|svg|readme|stackexchange | 0 | 139 | 1 | 72,153,778 | 72,153,778 | 1 | true | 2022-05-07T09:40:04.117Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
SVG image tag doesn't work on github README<p>I wrote sipmple server with <code>golang</code> witch should return a SVG with stats from stack-overflow. Every... |
72,152,849 | How to List Blobs in a Container iwth C# API using a SAS token<p>I am using a SAS token to access Azure Blob Store using the c# API. I can successfully create new blobs in a container and, given the name of a blob, I can read that blob and get the contents. However, I am unable to LIST the blobs in the container as I g... | <p>The reason you are running into issues is because you are using a Blob Container SAS URI to create <code>BlobServiceClient</code> and when you create a BlobContainerClient instance using the service client, the container name is repeated twice.</p>
<p>Possible solutions:</p>
<ol>
<li>Directly create an instance of <... | How to List Blobs in a Container iwth C# API using a SAS token | c#|azure|.net-core|azure-blob-storage | 0 | 320 | 1 | 72,153,891 | 72,153,891 | 1 | true | 2022-05-07T13:11:55.997Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to List Blobs in a Container iwth C# API using a SAS token<p>I am using a SAS token to access Azure Blob Store using the c# API. I can successfully creat... |
72,153,187 | TypeError: unsupported operand type(s) for -: 'str' and 'pandas._libs.tslibs.offsets.CustomBusinessDay'<p>I've created a class which takes in minute data and returns the daily ohlc for that day. A simple version looks like so:</p>
<pre><code>import pandas as pd
from datetime import time
from IPython.display import disp... | <p>try to put date to this format : datetime64 :</p>
<pre><code>from pandas.tseries.holiday import USFederalHolidayCalendar
from pandas.tseries.offsets import CustomBusinessDay
US_BUSINESS_DAY = CustomBusinessDay(calendar=USFederalHolidayCalendar())
date='2018-7-2'
pd.to_datetime(date) - 2 * US_BUSINESS_DAY # 2018-7... | TypeError: unsupported operand type(s) for -: 'str' and 'pandas._libs.tslibs.offsets.CustomBusinessDay' | python|pandas | 0 | 59 | 1 | 72,153,954 | 72,153,954 | 1 | true | 2022-05-07T13:56:41.347Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
TypeError: unsupported operand type(s) for -: 'str' and 'pandas._libs.tslibs.offsets.CustomBusinessDay'<p>I've created a class which takes in minute data and... |
72,153,945 | Connecting to a web server in Python 3<p>I am trying to connect to a web server in Python 3 and it just doesn't work!
I wrote the following in my code editor VS Code and btw, I don't have telnet installed.
So, here's my code:</p>
<pre><code>import socket
mysock = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
mysock... | <p>The error is saying name lookup fails, and for good reason. When using raw sockets, you mustn't put the <code>http://</code> protocol in the hostname string.</p>
<pre><code>mysock.connect(('http://data.pr4e.org', 80))
</code></pre>
<p>must be</p>
<pre><code>mysock.connect(('data.pr4e.org', 80))
</code></pre> | Connecting to a web server in Python 3 | python|python-3.x|sockets|websocket | 0 | 25 | 1 | 72,153,980 | 72,153,980 | 1 | true | 2022-05-07T15:31:09.437Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Connecting to a web server in Python 3<p>I am trying to connect to a web server in Python 3 and it just doesn't work!
I wrote the following in my code editor... |
72,153,836 | Issue running c++ code from 2013 using Clion<p>[I have very little experience with c++, and this is the first time I use it after more than 10 years].</p>
<p>I need to run some c++ code from 2013, and I am having issues doing so. I am using Clion on OSX Monterey (M1 Silicon chip). If I run a very simple script (main.cc... | <p>The problem has nothing to do with architecture or the version of C++. The definition of <code>Hair::read</code> couldn't be found because your <code>CMakeLists.txt</code> wasn't compiling the file that contained it. You need to tell it to compile <code>Hair.cpp</code> in addition to <code>main.cpp</code>, like this... | Issue running c++ code from 2013 using Clion | c++|macos-monterey | 0 | 30 | 1 | 72,154,029 | 72,154,029 | 1 | true | 2022-05-07T15:18:49.940Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Issue running c++ code from 2013 using Clion<p>[I have very little experience with c++, and this is the first time I use it after more than 10 years].</p>
<p... |
72,142,565 | scikit-learn neural net beginner - results not what I expect<p>I have a simple example for which I am attempting to perform a classification using the MLPClassifier.</p>
<pre class="lang-py prettyprint-override"><code>from sklearn.neural_network import MLPClassifier
# What are the features in our X data?
# 0. do .X f... | <p>The order of probabilities from <code>predict_proba</code> are not "reversed", they are stored in (presumably) alphabetical order; you can check the order in the attribute <code>classes_</code>. And instead of discretizing yourself at the threshold 0.999, consider calling <code>predict</code>, which will t... | scikit-learn neural net beginner - results not what I expect | python|machine-learning|scikit-learn|mlp | 0 | 31 | 1 | 72,154,040 | 72,154,040 | 1 | true | 2022-05-06T13:48:55.023Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
scikit-learn neural net beginner - results not what I expect<p>I have a simple example for which I am attempting to perform a classification using the MLPCla... |
72,154,046 | Filter array of associative arrays with a dynamic associative array where all elements must be matched<p>I need to filter my indexed array of associative arrays using an associative that may have different combinations of elements and potentially a variable number of elements.</p>
<pre><code>$users = [
[
&q... | <p>To filter, you need to iterate over all the filters in the <code>filterFunc</code> callback function and check if the filter applies. If one does not apply return false immediatly, else return true:</p>
<pre><code><?php
$users = array(
0 => array(
"name" => "ali",
"age&... | Filter array of associative arrays with a dynamic associative array where all elements must be matched | php|arrays|multidimensional-array|filtering|associative-array | 0 | 118 | 2 | 72,154,105 | 72,154,105 | 1 | true | 2022-05-07T15:42:35.190Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Filter array of associative arrays with a dynamic associative array where all elements must be matched<p>I need to filter my indexed array of associative arr... |
72,153,975 | Pre-commit causing the following error when trying to commit locally<p>I am working on a project and am required to use pre-commit.
After making a small code change, I tried to commit the change (in my local git repo). I got the following error:</p>
<pre><code>dmk@DESKTOP-I1DLS2O:~/Markus$ git commit -m "Removed G... | <p>it appears that your linux installation does not have a ruby executable (which <code>pre-commit</code> currently requires when <code>language_version</code> is not specified for <code>language: ruby</code> hooks)</p>
<p>you can install one on ubuntu/debian via <code>sudo apt install ruby-dev</code></p>
<hr />
<p>dis... | Pre-commit causing the following error when trying to commit locally | ruby-on-rails|ruby|pre-commit-hook|pre-commit|pre-commit.com | 0 | 483 | 1 | 72,154,200 | 72,154,200 | 1 | true | 2022-05-07T15:35:01.717Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Pre-commit causing the following error when trying to commit locally<p>I am working on a project and am required to use pre-commit.
After making a small code... |
72,154,072 | Unity - "Unrecognized escape sequence"<p>I have a really annoying error, I made a stopwatch in unity and this error keep showing up...
Here's the code:</p>
<pre><code>using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class StopWatch : MonoBehaviour
{
float currentTime;
pu... | <p>change:</p>
<pre><code>currentTimeText.text = time.ToString("@mm\:ss\:fff");
</code></pre>
<p>to:</p>
<pre><code>currentTimeText.text = time.ToString(@"mm\:ss\:fff");
</code></pre>
<p>or:</p>
<pre><code>currentTimeText.text = time.ToString("mm\\:ss\\:fff");
</code></pre> | Unity - "Unrecognized escape sequence" | c#|unity3d | 0 | 71 | 1 | 72,154,215 | 72,154,215 | 1 | true | 2022-05-07T15:44:42.120Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Unity - "Unrecognized escape sequence"<p>I have a really annoying error, I made a stopwatch in unity and this error keep showing up...
Here's the code:</p>
<... |
72,153,452 | How to change card status in Angular nebular?<p>I am trying to make flip-card component to flip after button clicked
I tried the following but I am getting this error</p>
<blockquote>
<p>TS2322: Type '{ isFlipped: boolean; }' is not assignable to type 'boolean'.</p>
</blockquote>
<p>this is my code
flip-card.component.... | <p>Try to change your template’s code by the next</p>
<pre><code>nb-flip-card [showToggleButton]="false"
[flipped]=“isFlipped”>
</code></pre> | How to change card status in Angular nebular? | angular|nebular | 0 | 69 | 1 | 72,154,242 | 72,154,242 | 1 | true | 2022-05-07T14:30:04.683Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to change card status in Angular nebular?<p>I am trying to make flip-card component to flip after button clicked
I tried the following but I am getting t... |
72,153,850 | Read NDEF Message from Android/IOS using NFC Reader<p>I want to transfer a tiny bit of data from my phone to an NFC reader (max 256 chars). It seems that IOS and Android can read/write tags, is there any way I can read these NDEF messages using an NFC reader and then process them?</p>
<p>Minimal experience with NFC stu... | <p>First off yes what you want to do is possible with the right hardware and software.</p>
<p>The NFC specification does have a peer to peer specification but forget about using that as this is not available on iOS and on Android it has been removed from Android 10 onwards.</p>
<p>In NFC there are 2 types of devices NF... | Read NDEF Message from Android/IOS using NFC Reader | android|ios|nfc | 0 | 279 | 1 | 72,154,405 | 72,154,405 | 1 | true | 2022-05-07T15:20:24.880Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Read NDEF Message from Android/IOS using NFC Reader<p>I want to transfer a tiny bit of data from my phone to an NFC reader (max 256 chars). It seems that IOS... |
72,154,249 | Uncaught ReferenceError: data is not defined at HTMLDocument.<anonymous<p>I am trying to render a Json Response on a html site using AJAX but i keep getting the error:</p>
<pre><code>Uncaught ReferenceError: data is not defined
at HTMLDocument.<anonymous
</code></pre>
<blockquote>
</blockquote>
<p>JsonResponse i... | <p>You are sending <code>data</code> as the body of your request, but first you have to defined the object you are sending to API</p>
<pre><code><div class="row">
<div id="test">
<h1> Test </h1>
</div>
</div>
{% endblock %}
{% block js %}
<script>... | Uncaught ReferenceError: data is not defined at HTMLDocument.<anonymous | javascript|ajax | 0 | 879 | 1 | 72,154,428 | 72,154,428 | 1 | true | 2022-05-07T16:05:35.793Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Uncaught ReferenceError: data is not defined at HTMLDocument.<anonymous<p>I am trying to render a Json Response on a html site using AJAX but i keep getting ... |
72,151,016 | Calling function from for loop - issue with parameters: NameError: name 'row' is not defined<p>I am calculating commute distances (home to offices) for all employees. This works for a single office with this piece of code:</p>
<pre><code>#Calculate distances from home to all other offices
def distances_to_offices(row):... | <p>Can't say for sure because I don't know what df_joined is, but it looks like it is some object representing a data table on which you can call <code>apply()</code> passing in a function, and <code>apply()</code> will loop through the table, calling the function you have supplied while passing in a row index or name ... | Calling function from for loop - issue with parameters: NameError: name 'row' is not defined | python|loops|for-loop|geopy | 0 | 61 | 1 | 72,154,448 | 72,154,448 | 1 | true | 2022-05-07T09:00:45.293Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Calling function from for loop - issue with parameters: NameError: name 'row' is not defined<p>I am calculating commute distances (home to offices) for all e... |
72,151,927 | Pass context to store data in Room<p>I am trying to save received data to local storage using Room library.
I have created a database class in which I define the parameters I need and define the context</p>
<p>And also I have a class in which I define the content I need for the database. But my problem is that I can't ... | <p>Your code to create <code>db</code> requires <code>context</code> as a param: <code>NetworkDatabase.getInstance(this)</code>. So you can pass a context as a param to your interceptor, something like:</p>
<pre><code>class PocketScoutInterceptor(val context: Context) : Interceptor {
...
NetworkDatabase.getInst... | Pass context to store data in Room | android|kotlin|save|android-room | 0 | 55 | 1 | 72,154,455 | 72,154,455 | 1 | true | 2022-05-07T11:10:16.033Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Pass context to store data in Room<p>I am trying to save received data to local storage using Room library.
I have created a database class in which I define... |
72,153,399 | Property 'uuid' does not exist on type 'unknown'.ts(2339)<p>This is for a Discord bot and the error pops up when trying to fetch api data. It should reply with the fetched uuid but the bot can't even start since the error pops up on start.
Code:</p>
<pre><code>import fetch from "node-fetch";
export default {... | <p>Error happens because typescript does not know what type of data you fetched;</p>
<p>You need to manually specify type of <code>data</code> using <code>as</code>.</p>
<p>Or, you can use libraries like <code>zod</code> and <code>joi</code> for validation and auto type inferring.</p> | Property 'uuid' does not exist on type 'unknown'.ts(2339) | node.js|typescript|discord.js|fetch|node-fetch | 0 | 170 | 1 | 72,154,549 | 72,154,549 | 1 | true | 2022-05-07T14:24:17.890Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Property 'uuid' does not exist on type 'unknown'.ts(2339)<p>This is for a Discord bot and the error pops up when trying to fetch api data. It should reply wi... |
72,153,514 | Estimation of time required for calculation in Eratosthene's sieve algorithm<p>I am using Qt and cpp to calculate some time consuming calculation like prime number calculation using Eratosthene's sieve algorithm as shown below.</p>
<pre><code> QElapsedTimer timer;
timer.start();
int p;
for ( p ... | <p>Lets ignore if a number is prime or not. Estimating that is a big math problem involving the density of primes and such. Lets just assume every number is prime. That gives:</p>
<p>The code marks all even numbers, so that is N/2 operations. Then all numbers divisible by 3, so N/3 operations. Then N/4, N/5, N/6, N/7, ... | Estimation of time required for calculation in Eratosthene's sieve algorithm | c++|qt|math | 0 | 39 | 1 | 72,154,577 | 72,154,577 | 1 | true | 2022-05-07T14:38:08.917Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Estimation of time required for calculation in Eratosthene's sieve algorithm<p>I am using Qt and cpp to calculate some time consuming calculation like prime ... |
72,154,315 | Display the values in the console log when Submit button is clicked<p>I can't seem to make this work. Beginer here.
I want to display in the console the values of first and last name.
html</p>
<pre><code> `<form id="form1" onsubmit="getFormValue()">
First name: <input type="text... | <p>A better approach would be to add an event handler rather than using an inline function. There are enough resources to guide you on that so I will not address it here. The answer below addresses your specific question.</p>
<p>To start with you need to pass the <code>event</code> and the prevent the browser executing... | Display the values in the console log when Submit button is clicked | javascript | 0 | 550 | 2 | 72,154,597 | 72,154,597 | 1 | true | 2022-05-07T16:13:38.843Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Display the values in the console log when Submit button is clicked<p>I can't seem to make this work. Beginer here.
I want to display in the console the valu... |
72,154,596 | Python: Hash function always produces same (empty) hash for any file<p>So I did a ton of googling around but can't really find an answer to my problem.
I tried to make a function to hash bigger files, and I made two different functions, yet both seem to produce the same output for any file I hash, to be precise:</p>
<p... | <p>The code is <em>calling</em> the hash constructor repeatedly instead of creating a single hash instance and updating it.</p>
<p>This should work:</p>
<pre class="lang-py prettyprint-override"><code>from hashlib import sha256 as hashfun
bs = 1048576 # I'll just use 1024kb chunks as an example
selec... | Python: Hash function always produces same (empty) hash for any file | python|file|hash | 0 | 46 | 1 | 72,154,660 | 72,154,660 | 1 | true | 2022-05-07T16:49:12.010Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Python: Hash function always produces same (empty) hash for any file<p>So I did a ton of googling around but can't really find an answer to my problem.
I tri... |
72,152,297 | How would I add imformation to an "if" statement?<p><code>if { $chan == $chan_(1) || $chan == $chan_(2) && $nick == $ircbotnick } {</code> .....more code</p>
<p>The chan is defined with <code>set chan_(1) "#1"</code> etc</p>
<p>but when I add additional fields ie <code>$chan == $chan_(3)</code> that t... | <p>Instead of adding more and more <code>$chan == ...</code> conditions, try creating a list and then check for list inclusion with <code>in</code>.</p>
<pre><code>set valid_chans [list $chan_(1) $chan_(2) $chan_(3)]
if {$chan in $valid_chans && $nick == $ircbotnick } {
...
}
</code></pre>
<p>Adding additi... | How would I add imformation to an "if" statement? | tcl | 0 | 36 | 1 | 72,154,786 | 72,154,786 | 1 | true | 2022-05-07T12:04:11.493Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How would I add imformation to an "if" statement?<p><code>if { $chan == $chan_(1) || $chan == $chan_(2) && $nick == $ircbotnick } {</code> .....more ... |
72,154,668 | Rename multiple files in Bash with random strings<p>Assuming an arbitrary number of files with random names and the same file extension (e.g., <code>file1.txt</code>, <code>file2.txt...fileN.txt</code>). How could you rename them all reliably with a random string?</p>
<p>Such as, <code>file1.txt, file2.txt...fileN.txt<... | <p>quickest hack to get a random-letters string I can think of is</p>
<pre><code>head -c24 /dev/urandom | base64 | tr -dc a-zA-Z
</code></pre>
<p>so</p>
<pre><code>randomname() { head -c24 /dev/urandom | base64 | tr -dc a-zA-Z; }
for f in file*.txt; do mv "$f" `randomname`.txt; done
</code></pre>
<p>and your ... | Rename multiple files in Bash with random strings | linux|bash|terminal|rename | 0 | 272 | 2 | 72,154,849 | 72,154,849 | 1 | true | 2022-05-07T16:57:45.837Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Rename multiple files in Bash with random strings<p>Assuming an arbitrary number of files with random names and the same file extension (e.g., <code>file1.tx... |
72,154,818 | Convert IntRange to listOf String in Kotlin<p>I want to convert a IntRange:</p>
<pre><code>val years = 1900..2020
</code></pre>
<p>to a <code>listOf<String></code> with all the values from 1900 to 2022, how do I do it?</p>
<p>I need it as a String list cause I'm passing it with other String lists into an composab... | <p><code>val listOfStings = years.map { it.toString() }</code></p> | Convert IntRange to listOf String in Kotlin | android|list|kotlin | 0 | 49 | 1 | 72,154,859 | 72,154,859 | 1 | true | 2022-05-07T17:16:47.573Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Convert IntRange to listOf String in Kotlin<p>I want to convert a IntRange:</p>
<pre><code>val years = 1900..2020
</code></pre>
<p>to a <code>listOf<Strin... |
72,151,851 | optional parameters when defining routes<p>I am working on <code>deno</code> equivalent of my <code>node (express)</code> server application for study purposes and I can't find a way to apply <code>optional</code> chunks when defining <code>routes</code>.</p>
<p>For example in <code>express</code> application i have ro... | <p>I don't know a whole lot about <code>abc</code>, but <a href="https://deno.land/x/oak" rel="nofollow noreferrer"><code>oak</code></a> is currently the most commonly-used http server framework for Deno (and I think it would be the analog of Express based on the metric of popularity).</p>
<p>It uses <a href="https://g... | optional parameters when defining routes | typescript|routes|deno | 0 | 90 | 2 | 72,154,923 | 72,154,923 | 1 | true | 2022-05-07T10:57:56.733Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
optional parameters when defining routes<p>I am working on <code>deno</code> equivalent of my <code>node (express)</code> server application for study purpos... |
72,154,930 | Access EventTarget of addEventListener without using a variable<p>This codes removes the focus from the <code>select</code> element after you click it:</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 pret... | <p>yes it is possible. just modify your code a bit.</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>document.querySelector('select').addEventListener('focus', (e) => {
e.t... | Access EventTarget of addEventListener without using a variable | javascript | 0 | 29 | 2 | 72,154,966 | 72,154,966 | 1 | true | 2022-05-07T17:31:22.327Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Access EventTarget of addEventListener without using a variable<p>This codes removes the focus from the <code>select</code> element after you click it:</p>
<... |
72,155,023 | Requiring a Hook to update on state change<p>So this is a component I have in React JS</p>
<pre><code>const EnterSetData = ({ user_card_set }) => {
const [cardlist, setCardlist] = useState({ data: [] });
let setlist= useGetSetDB();
//Save and reset form
const sendSets = () => {
const dupes = find... | <p>You can pass <code>cardlist</code> to <code>useGetSetDB</code> like below</p>
<pre><code>const [cardlist, setCardlist] = useState({ data: [] });
let setlist = useGetSetDB(cardlist); //whenever cardlist gets updated, we trigger side-effect again
</code></pre>
<p>You also need to modify <code>useGetSetDB</code> to ali... | Requiring a Hook to update on state change | javascript|reactjs|react-hooks | 0 | 37 | 1 | 72,155,140 | 72,155,140 | 1 | true | 2022-05-07T17:43:02.490Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Requiring a Hook to update on state change<p>So this is a component I have in React JS</p>
<pre><code>const EnterSetData = ({ user_card_set }) => {
cons... |
72,150,229 | How set active condition on subrequest?<p>As Product model has many to many relations with Category (using ProductCategory model).</p>
<p>I try to add an additive condition in the request.</p>
<pre><code>$productsWithActiveCategories = Product
::getByTitle($filter_title)
->getByStatus('A')
->getByPub... | <p>Instead of <code>->getByActiveCategory(true)</code>, you can use the dot nested notation in whereHas to filter your model like following :</p>
<pre><code>$productsWithActiveCategories = Product
(...)
->whereHas('productCategories.category', function ($category) {
$category->where('active', ... | How set active condition on subrequest? | laravel|eloquent | 0 | 48 | 1 | 72,155,370 | 72,155,370 | 1 | true | 2022-05-07T07:03:04.467Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How set active condition on subrequest?<p>As Product model has many to many relations with Category (using ProductCategory model).</p>
<p>I try to add an add... |
72,154,259 | Google Play Console: the meaning of "Active Devices"<p>I see it always differ from Installed audience and is mostly more. I am curious how this value gets calculated ?</p>
<p><a href="https://i.stack.imgur.com/NbxBM.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/NbxBM.png" alt="enter image descripti... | <h4>Active devices are defined as:</h4>
<blockquote>
<p>An active device is one that has been turned on at least once in the previous 30 days.</p>
</blockquote>
<p><a href="https://support.google.com/googleplay/android-developer/answer/10770882?hl=en" rel="nofollow noreferrer">Source: View and understand your app's qua... | Google Play Console: the meaning of "Active Devices" | google-play-console | 0 | 71 | 1 | 72,155,384 | 72,155,384 | 1 | true | 2022-05-07T16:06:47.567Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Google Play Console: the meaning of "Active Devices"<p>I see it always differ from Installed audience and is mostly more. I am curious how this value gets ca... |
72,152,873 | Problem in accessing the data of a dictionary at runtime in kivy gui with python<p>How I can access the data of the Dictionary "selected_items" of class "Item_Menu" when the data is transferred in the dictionary at run time according to the user Selection of checkboxes in the Kivy gui and I want to ... | <p>the code was hard to debug but your problem was that your second screen <code>Description_item</code> was created at the beginning so it takes the dictionary <code>selected_items</code> empty
so you should create it when Change_window is called:</p>
<pre><code> def Change_window(self,instance):
MyApp.sm.a... | Problem in accessing the data of a dictionary at runtime in kivy gui with python | python|kivy|kivymd | 0 | 36 | 1 | 72,155,478 | 72,155,478 | 1 | true | 2022-05-07T13:14:50.037Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Problem in accessing the data of a dictionary at runtime in kivy gui with python<p>How I can access the data of the Dictionary "selected_items" of ... |
72,154,300 | Spring Data JDBC: No such property found for type<p>I am a beginner in Spring Data JDBC. I am following Spring in action 6th edition and have created the repository as follows:</p>
<pre><code>package com.springinaction.tacocloud;
import java.util.Optional;
import org.springframework.data.repository.CrudRepository;
p... | <p>Just remove the method <code>getIngredients()</code> and use <code>findAll()</code> (provided by the super interface) instead.</p>
<p>You should also remove the other methods, because they are already provided by the super interface</p>
<ul>
<li><code>save()</code> <- provided by <code>CrudRepository</code></li>
... | Spring Data JDBC: No such property found for type | java|spring|spring-data-jpa|spring-data | 0 | 63 | 1 | 72,155,499 | 72,155,499 | 1 | true | 2022-05-07T16:11:32.523Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Spring Data JDBC: No such property found for type<p>I am a beginner in Spring Data JDBC. I am following Spring in action 6th edition and have created the rep... |
72,155,379 | Why is <ul> empty when using requests but not in browser?<p>I am trying to scrape a list of trade publications from: <code>https://www.webwire.com/IndustryList.asp</code>, using beautifulsoup and requests. When I inspect the page contents with my browser, I see a list:</p>
<pre><code><ul id="syndication-list&qu... | <p>It's working</p>
<pre><code>import requests
from bs4 import BeautifulSoup
url = "https://www.webwire.com/TradePublications.asp?ind=LEI"
page = requests.get(url)
#print(url)
soup = BeautifulSoup(page.content, 'html.parser')
for e in soup.select('#syndication-list li'):
print(e.get_text())
</code></pr... | Why is <ul> empty when using requests but not in browser? | python|python-3.x|beautifulsoup|python-requests | 0 | 31 | 2 | 72,155,558 | 72,155,558 | 1 | true | 2022-05-07T18:30:40.200Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why is <ul> empty when using requests but not in browser?<p>I am trying to scrape a list of trade publications from: <code>https://www.webwire.com/IndustryLi... |
72,154,452 | save values of arrays inside a state from different input fields<p>i want to get the values from 5 input fields and save them inside a single state of arrays , how can i achieve that ?</p>
<pre><code>const [features,setFeatures] = useState([]);
const handleChange = e => {
setFeatures(prev => ({ ...prev, feat... | <p>You can check the below implementation</p>
<p><em>Note that I hardcoded the array length and I'd assume your input array is static. If your input array is dynamic, you can use iteration for generating input fields. Besides that, I modified <code>Input</code> to <code>input</code> and <code>change</code> to <code>onC... | save values of arrays inside a state from different input fields | arrays|reactjs | 0 | 38 | 1 | 72,155,578 | 72,155,578 | 1 | true | 2022-05-07T16:30:37.603Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
save values of arrays inside a state from different input fields<p>i want to get the values from 5 input fields and save them inside a single state of arrays... |
72,155,451 | rust private generics in function signature<p>I try to create <code>actix</code> web app and I would like to register routes in separated function</p>
<pre class="lang-rust prettyprint-override"><code>use actix_web::{web, App, HttpResponse, HttpServer, Responder};
#[actix_web::main]
async fn main() -> std::io::Resu... | <p>You can use <code>App::configure</code> for that, avoiding the need to pass an <code>App<AppEntry></code> directly, like they show in <a href="https://actix.rs/docs/application/#configure" rel="nofollow noreferrer">this example</a>.</p>
<p>By the way, in your <code>register_routes</code> function, you just cre... | rust private generics in function signature | rust|actix-web|rust-actix|function-signature | 0 | 66 | 1 | 72,155,692 | 72,155,692 | 1 | true | 2022-05-07T18:39:37.973Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
rust private generics in function signature<p>I try to create <code>actix</code> web app and I would like to register routes in separated function</p>
<pre c... |
72,149,599 | Outlook VSTO - Get all items in a group calendar<p>I am looking for a way to access a group calendar in Outlook VSTO Add-In. I am only able to search the default calendar in outlook. I have shared an image from outlook below that shows several group calendars. How can I access those group calendars from VSTO code?</p>
... | <p>You can use the <a href="https://docs.microsoft.com/en-us/office/vba/api/outlook.navigationmodule" rel="nofollow noreferrer">NavigtionModule</a> object in Outlook to get access to group calendars (or shared ones). The NavigationModule object provides access to the various navigation modules that are displayed in the... | Outlook VSTO - Get all items in a group calendar | c#|outlook|vsto|outlook-addin|office-addins | 0 | 108 | 2 | 72,155,693 | 72,155,693 | 1 | true | 2022-05-07T04:57:02.343Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Outlook VSTO - Get all items in a group calendar<p>I am looking for a way to access a group calendar in Outlook VSTO Add-In. I am only able to search the def... |
72,155,762 | How to create several plots within a for loop?<p>I have the following Python code:</p>
<pre><code>for key in my_dict:
Sc = StandardScaler()
X = Sc.fit_transform(my_dict[key])
pca = PCA(2)
pca_data = pd.DataFrame(pca.fit_transform(X),columns=['PC1','PC2'])
kmeans = KMeans(n_clusters=2).fit(X)
pca... | <p>You need to create a figure for each by calling <code>plt.figure()</code></p> | How to create several plots within a for loop? | python|iteration|seaborn | 0 | 26 | 1 | 72,155,784 | 72,155,784 | 1 | true | 2022-05-07T19:23:40.147Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to create several plots within a for loop?<p>I have the following Python code:</p>
<pre><code>for key in my_dict:
Sc = StandardScaler()
X = Sc.fi... |
72,155,804 | Inserting a value in a list of lists<p>My data is as follows,</p>
<pre><code>data = [[2, 1, 2, 2], [2, 2, 1, 5], [1, 2, 2, 2], [2, 1, 2, 5], [2, 5, 2, 1]]
</code></pre>
<p>I would like to transform this such that there is a 0 at 0, 1, 2, 3 and 4th positions of the internal lists and get it look like below,</p>
<pre><co... | <p>Use the <code>list.insert()</code> method</p>
<pre><code>for i in range(len(data)):
data[i].insert(i, 0)
</code></pre>
<p>result :</p>
<pre><code>print(data)
>>> [[0, 2, 1, 2, 2], [2, 0, 2, 1, 5], [1, 2, 0, 2, 2], [2, 1, 2, 0, 5], [2, 5, 2, 1, 0]]
</code></pre> | Inserting a value in a list of lists | python|list | 0 | 33 | 2 | 72,155,844 | 72,155,844 | 1 | true | 2022-05-07T19:31:10.667Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Inserting a value in a list of lists<p>My data is as follows,</p>
<pre><code>data = [[2, 1, 2, 2], [2, 2, 1, 5], [1, 2, 2, 2], [2, 1, 2, 5], [2, 5, 2, 1]]
</... |
72,155,802 | How to detect mouse release<p>I have a button that activates an animation. I want to stop the animation when I release the click. I have just this:</p>
<pre><code>Private Sub AnimationButton_Click()
Call AnimationStart
End Sub
</code></pre>
<p>I tried searching, but I didn't find anything related to buttons.</p> | <p>If you look in the list of events on your form for your button you will find <code>Mouse_Down</code> and <code>Mouse_Up</code> for the command button.</p>
<p>At the top of the code editor window select your command button on the left hand drop down list and the events available are in the right hand drop down list.<... | How to detect mouse release | excel|vba|button|click | 0 | 53 | 1 | 72,155,876 | 72,155,876 | 1 | true | 2022-05-07T19:30:54.313Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to detect mouse release<p>I have a button that activates an animation. I want to stop the animation when I release the click. I have just this:</p>
<pre>... |
72,147,210 | Can't cast database type character to Guid<p>I updated my solution from .Net 3.1 to .Net 6. Also updated the Npgsql nuget package from 5.0.10 to 6.0.4 as part of this upgrade.</p>
<p>Since then, I am receiving an error "Can't cast database type character to Guid" when I try to retreive data from the database.... | <p>EF Core has a built-in value converter which implicitly converts .NET Guid properties to text columns (<a href="https://docs.microsoft.com/en-us/ef/core/modeling/value-conversions?tabs=data-annotations#built-in-converters" rel="nofollow noreferrer">see docs</a>. Note that PostgreSQL has a <a href="https://www.postgr... | Can't cast database type character to Guid | .net-6.0|npgsql | 0 | 85 | 1 | 72,155,879 | 72,155,879 | 1 | true | 2022-05-06T20:49:02.613Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Can't cast database type character to Guid<p>I updated my solution from .Net 3.1 to .Net 6. Also updated the Npgsql nuget package from 5.0.10 to 6.0.4 as par... |
72,155,868 | OverflowError cannot fit int into an index-sized integer<p>Hello Guys I am new to the python, I am learning the basic & during my practice i found one Issue</p>
<p><strong><strong>(OverflowError: cannot fit 'int' into an index-sized integer)</strong></strong></p>
<p>Below are my Code</p>
<pre><code># Ask user their... | <p>Your issue is with these 3 lines:</p>
<pre><code>userAgeTenTime = (userAge * 10)
userAgeTenTimeInt = int(userAgeTenTime)
print ("Your Age ten times is" * userAgeTenTimeInt )
</code></pre>
<p>Here, you take the <code>userAge</code> string, let's say <code>"123"</code> and repeat it 10 times - <cod... | OverflowError cannot fit int into an index-sized integer | python-3.x | 0 | 79 | 1 | 72,155,943 | 72,155,943 | 1 | true | 2022-05-07T19:40:45.693Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
OverflowError cannot fit int into an index-sized integer<p>Hello Guys I am new to the python, I am learning the basic & during my practice i found one Is... |
72,148,477 | How can I get type names and member TypeObjects from a ts.TypeObject?<p>I'm working with a TypeScript compiler to perform some code generation. This is my first time working with the compiler API directly.</p>
<p>With some ugly narrowing below (improvement of which I will save for another question), I'm able to get a <... | <p>I guess I was just feeling a bit too lazy when I wrote this. There is an example in the <a href="https://github.com/microsoft/TypeScript/wiki/Using-the-Compiler-API#using-the-type-checker" rel="nofollow noreferrer">docs</a>.</p> | How can I get type names and member TypeObjects from a ts.TypeObject? | typescript|typescript-typings|typescript-compiler-api | 0 | 103 | 1 | 72,155,992 | 72,155,992 | 1 | true | 2022-05-07T00:08:01.677Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How can I get type names and member TypeObjects from a ts.TypeObject?<p>I'm working with a TypeScript compiler to perform some code generation. This is my fi... |
72,155,991 | generate set number of names used by shell split naming profile<p>ok so when you run the split function from terminal it generates the names it names all the parts starting with an x followed by an 2 letter alphabetical incremental pair.
aa,ab,ac ect.</p>
<p>What I am looking to o is generate a list of these names usin... | <p>You can use <code>string.ascii_lowercase</code>, <code>itertools.product</code>, and string formatting to do what you want.</p>
<pre><code>from string import ascii_lowercase
from itertools import product
def make_patterns(n):
letters_iter = product(ascii_lowercase, ascii_lowercase)
return [
f'x{a}{b... | generate set number of names used by shell split naming profile | python|alphabetical | 0 | 42 | 2 | 72,156,162 | 72,156,162 | 1 | true | 2022-05-07T20:03:20.917Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
generate set number of names used by shell split naming profile<p>ok so when you run the split function from terminal it generates the names it names all the... |
72,156,173 | how to remove words start with # from string<p>i have title like this "hello my #name is #ahmed kotsh"
and i want to remove #name #ahmed , any word start with # and the extra spaces after delete the hashtag</p>
<p>expect result "hello my is kotsh"
my try works but i know there is better code and mor... | <p>Use a regular expression that matches <code>#</code> followed by non-space characters, and replace with nothing.</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 text =... | how to remove words start with # from string | javascript | 0 | 21 | 1 | 72,156,182 | 72,156,182 | 1 | true | 2022-05-07T20:34:12.633Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
how to remove words start with # from string<p>i have title like this "hello my #name is #ahmed kotsh"
and i want to remove #name #ahmed , any word... |
72,155,605 | Bootstrap 5: Change caret height of input fields (form-control)<p>I want to change the height of an input field (form-control) in Bootstrap 5. Any ideas how to solve this? An example to make it higher and shorter is appreciated :)</p>
<p><a href="https://i.stack.imgur.com/YM1Os.png" rel="nofollow noreferrer"><img src="... | <p>You could make it higher or lower by adjusting padding or line-height to the input field.</p>
<pre><code>input {
padding: 3px 5px;
}
</code></pre>
<p>or</p>
<pre><code>input {
line-height: 25px;
}
</code></pre> | Bootstrap 5: Change caret height of input fields (form-control) | css|bootstrap-5 | 0 | 337 | 2 | 72,156,219 | 72,156,219 | 1 | true | 2022-05-07T18:59:52.323Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Bootstrap 5: Change caret height of input fields (form-control)<p>I want to change the height of an input field (form-control) in Bootstrap 5. Any ideas how ... |
72,155,237 | Why doesn't callback work for Redis on node<p>The following code works on redis version 3.1.2, but when I upgrade the redis libary to 4.1.0, the call back stops working. There is a REDIS server running on localhost with no password. I am using node 16 LTS.</p>
<pre><code>'use strict'
import {createClient} from 'redis';... | <p>Node Redis 4.x, following semver conventions, introduced many breaking changes. One of them is that it uses promises instead of callbacks. You can read all the details at <a href="https://github.com/redis/node-redis" rel="nofollow noreferrer">https://github.com/redis/node-redis</a>.</p> | Why doesn't callback work for Redis on node | node.js|redis | 0 | 413 | 1 | 72,156,227 | 72,156,227 | 1 | true | 2022-05-07T18:09:44.443Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why doesn't callback work for Redis on node<p>The following code works on redis version 3.1.2, but when I upgrade the redis libary to 4.1.0, the call back st... |
72,156,258 | Is there a way to use a TypeScript file in place of ormconfig.json?<p>I do want to export my ormConfig from a TypeScript file located by the path <em><strong>src/config/ormconfig.ts</strong></em> with the following content</p>
<pre><code>export const ormConfig = {
type: 'postgres',
host: 'localhost',
port: 5432,
... | <p>You just need to specify the type of your <code>ormConfig</code></p>
<pre><code>import { PostgresConnectionOptions } from "typeorm/driver/postgres/PostgresConnectionOptions";
const ormConfig: PostgresConnectionOptions = {
</code></pre> | Is there a way to use a TypeScript file in place of ormconfig.json? | typescript|typeorm | 0 | 224 | 1 | 72,156,308 | 72,156,308 | 1 | true | 2022-05-07T20:47:07.080Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Is there a way to use a TypeScript file in place of ormconfig.json?<p>I do want to export my ormConfig from a TypeScript file located by the path <em><strong... |
72,156,399 | Cant parse JSON (nested dictionary) into ForEach with SwiftUI<p>I want to parse the following JSON into a list with SwiftUI, however I am experiencing some issues with this.</p>
<p>JSON (there are many more entires than this with random Identifiers as the entry. This is what caused it to be much harder to perform):</p>... | <p>Your JSON doesn't have any keys called <code>list</code>, which is why it's failing. Because it's a dynamically-keyed dictionary, you will want to decode it as <code>[String:FeedValue]</code>.</p>
<p>I used a wrapper to keep the <code>id</code> from the original JSON, but you could also do some fancier decoding if y... | Cant parse JSON (nested dictionary) into ForEach with SwiftUI | ios|json|swift|swiftui|codable | 0 | 115 | 1 | 72,156,482 | 72,156,482 | 1 | true | 2022-05-07T21:11:21.030Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Cant parse JSON (nested dictionary) into ForEach with SwiftUI<p>I want to parse the following JSON into a list with SwiftUI, however I am experiencing some i... |
72,156,440 | Number of Islands using DFS<p>Help me spot the error</p>
<p>Wrong Answer
Details
Input
[["1","1","0","0","0"],["1","1","0","0","0"],["0","0","1","0","0"],["0",&... | <p>The problem is that <code>position</code> has nothing to do with <code>visited</code>. <code>position</code> is the <em>content</em> of a cell, while <code>visited</code> should collect <em>coordinates</em> of a cell.</p>
<p>So change the relevant part to:</p>
<pre><code> if (row, col) in visited:
return ... | Number of Islands using DFS | python|depth-first-search | 0 | 44 | 1 | 72,156,500 | 72,156,500 | 1 | true | 2022-05-07T21:19:04.753Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Number of Islands using DFS<p>Help me spot the error</p>
<p>Wrong Answer
Details
Input
[["1","1","0","0","0"... |
72,156,378 | DRF How to select specific fields to display in a nested serializer relationship? (without additional serializers)<p>I have a serializer</p>
<pre><code>class CategoryListSerializer(serializers.ModelSerializer):
class Meta:
model = Category
fields = ["id", "name", "name_en", "a... | <p>As Mentioned by @<a href="https://stackoverflow.com/users/17242503/mtzd">mtzd</a> in the comments:</p>
<p>Creating a generic Dynamic Serializer Class (As in <a href="https://www.django-rest-framework.org/api-guide/serializers/#dynamically-modifying-fields" rel="nofollow noreferrer">DRF Docs here</a>) worked!</p>
<p>... | DRF How to select specific fields to display in a nested serializer relationship? (without additional serializers) | django|serialization|django-rest-framework|drf-queryset | 0 | 729 | 3 | 72,156,563 | 72,156,563 | 1 | true | 2022-05-07T21:06:10.383Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
DRF How to select specific fields to display in a nested serializer relationship? (without additional serializers)<p>I have a serializer</p>
<pre><code>class... |
72,156,132 | ASP.Net MVC application with multiple users<p>I am creating an ASP.Net MVC application related to design, buildings and etc. I need to have two types of users - Normal People and Companies. <a href="https://stackoverflow.com/questions/25627165/how-can-i-create-two-types-of-users-in-mvc5">Here</a> I read how I can do it... | <p>There's two different scopes of problems related to having different "Types" of users in your application.</p>
<h1>Permissions / Authorization</h1>
<p>This is the scope for what different types of Users are <strong>allowed</strong> to do. What endpoints are they allowed to call? What are they allowed to ac... | ASP.Net MVC application with multiple users | c#|sql|asp.net-mvc|database|multiple-users | 0 | 390 | 1 | 72,156,612 | 72,156,612 | 1 | true | 2022-05-07T20:27:36.740Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
ASP.Net MVC application with multiple users<p>I am creating an ASP.Net MVC application related to design, buildings and etc. I need to have two types of user... |
72,152,685 | Problem with Queue browsing when upgrading from 5.15.14 to 5.16.2<p>Has anyone also noticed an issue with queue browsing with 5.16.2?
It happens when using an XA connection and starting a session without a transaction context.
This always worked fine but no longer does. Instead one can see a exception, but only when de... | <p>This was changed a few years back in 5.16.0 via <a href="https://issues.apache.org/jira/browse/AMQ-2659" rel="nofollow noreferrer">AMQ-2659</a>. You need to set <code>xaAckMode=1</code> on your URL now, e.g.:</p>
<pre><code>tcp://localhost:61616?jms.xaAckMode=1
</code></pre> | Problem with Queue browsing when upgrading from 5.15.14 to 5.16.2 | jms|activemq|spring-jms|distributed-transactions | 0 | 91 | 1 | 72,156,676 | 72,156,676 | 1 | true | 2022-05-07T12:50:29.750Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Problem with Queue browsing when upgrading from 5.15.14 to 5.16.2<p>Has anyone also noticed an issue with queue browsing with 5.16.2?
It happens when using a... |
72,156,607 | Referencing Variables Between Methods<p>I'm new to C# so this is quite a noobie question; how would I reference variable <strong>OEint</strong> in my SQLCOMMAND method</p>
<p>Error: The name 'OEint' does not exist in the current context</p>
<p>If there are some good docs out there that go into detail on C# referencing,... | <blockquote>
<p>Error: The name 'OEint' does not exist in the current context</p>
</blockquote>
<p>Because each block has its own <a href="https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/language-specification/basic-concepts#77-scopes" rel="nofollow noreferrer">scope</a>, "visibility" so to ... | Referencing Variables Between Methods | c# | 0 | 59 | 1 | 72,156,703 | 72,156,703 | 1 | true | 2022-05-07T21:54:39.700Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Referencing Variables Between Methods<p>I'm new to C# so this is quite a noobie question; how would I reference variable <strong>OEint</strong> in my SQLCOMM... |
72,156,765 | How to remove duplicate words within columns using group_concat?<p>I have a table with records in TableA.ColumnA like this:</p>
<pre><code>New York City
New York
New Rochelle
York Town
</code></pre>
<p>I am doing</p>
<blockquote>
<p>Select group_concat(ColumnA SEPARATOR ';') from TableA</p>
</blockquote>
<p>but natural... | <p>The easiest way assuming your mySql supports <em>json_table</em> is to convert the strings to a json array and split into rows, then you can aggregate the distinct list:</p>
<pre><code>select group_concat(words separator '; ') result
from (
select distinct words
from tableA t
join json_table(
replace(json_... | How to remove duplicate words within columns using group_concat? | mysql | 0 | 19 | 1 | 72,156,834 | 72,156,834 | 1 | true | 2022-05-07T22:26:17.070Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to remove duplicate words within columns using group_concat?<p>I have a table with records in TableA.ColumnA like this:</p>
<pre><code>New York City
New ... |
72,109,102 | excel365 - Conditionally format rows based on two string values?<p>Excel noob here. Lets say I have a sheet.</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>.</th>
<th>A</th>
<th>B</th>
<th>C</th>
<th>D</th>
</tr>
</thead>
<tbody>
<tr>
<td>1</td>
<td>Adam</td>
<td>3</td>
<td>No</td>
<td>No<... | <p>Your observed behaviour is because of the commonality between rules 2 & 3, i.e. if C2 differs from D2 then it is, superficially, because the content of those cells differ but, if one of the cells is blank, when the other isn't, then both rules 2 & 3 are satisfied <em>simultaneously</em>.</p>
<p>In the screen... | excel365 - Conditionally format rows based on two string values? | excel|excel-365 | 0 | 24 | 1 | 72,156,903 | 72,156,903 | 1 | true | 2022-05-04T07:06:35.900Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
excel365 - Conditionally format rows based on two string values?<p>Excel noob here. Lets say I have a sheet.</p>
<div class="s-table-container">
<table class... |
72,156,669 | Script not exec<pre><code>import random
import subprocess
current_machine_id = str(subprocess.check_output('wmic csproduct get uuid'), 'utf-8').split('\n')[1].strip()
ids = open('ids.txt','r')
for line in ids:
if line == current_machine_id:
print("STAGE 1 TRIGGERD") #remove once dev stage is do... | <p>You have not considered the case where the txt file is empty that's why the for does not work, also I always recommend opening the files with the with construct it is much safer, in addition you forgot to open the file in append mode (I assume you want to add id at the end and not have a file with a single id)</p>
<... | Script not exec | python|python-3.x | 0 | 43 | 2 | 72,156,910 | 72,156,910 | 1 | true | 2022-05-07T22:04:46.727Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Script not exec<pre><code>import random
import subprocess
current_machine_id = str(subprocess.check_output('wmic csproduct get uuid'), 'utf-8').split('\n')[... |
72,156,902 | Pandas adding previous row and current row into current row<p>I have a Data Frame which is around 100x100 and I want to add previous cell + current cell = current cell</p>
<p>An example of the Data Frame:</p>
<pre><code>User A B C D
Apple 0 5 6 4
Orange 23 0 3 5
Grape 5 10 ... | <p>The operation is called cumulative sum:</p>
<pre><code>df.cumsum(axis=1)
</code></pre>
<p>(I assume that "User" is the index).</p> | Pandas adding previous row and current row into current row | python|python-3.x|pandas|dataframe | 0 | 26 | 1 | 72,156,919 | 72,156,919 | 1 | true | 2022-05-07T22:54:23.227Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Pandas adding previous row and current row into current row<p>I have a Data Frame which is around 100x100 and I want to add previous cell + current cell = cu... |
72,156,795 | Return only results of specific field - Mongodb java<p>Hello I am using MONGODB java driver version 4.5.1, I created a method to query a document and grab a specific field.</p>
<p>(id is a discord id not document _id)</p>
<pre><code>final MONGODB mongodb = new MONGODB();
public ArrayList<Document> getRoom(lon... | <p>The term for this is projection, you can have a look at: <a href="https://www.mongodb.com/docs/manual/tutorial/project-fields-from-query-results/" rel="nofollow noreferrer">https://www.mongodb.com/docs/manual/tutorial/project-fields-from-query-results/</a></p>
<p>As the documentation suggests;</p>
<blockquote>
<p>Yo... | Return only results of specific field - Mongodb java | java|mongodb|mongodb-java | 0 | 40 | 2 | 72,156,941 | 72,156,941 | 1 | true | 2022-05-07T22:32:26.440Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Return only results of specific field - Mongodb java<p>Hello I am using MONGODB java driver version 4.5.1, I created a method to query a document and grab a ... |
72,156,733 | Python & Selenium: How to avoid StaleElementReferenceException error from dividend.com<p>I'd like to get company names from <a href="https://www.dividend.com/dividend-champions/" rel="nofollow noreferrer">https://www.dividend.com/dividend-champions/</a> with Python & Selenium.</p>
<p>But the following error is disp... | <p><code>StaleElementReferenceException</code> means selected element may no longer in html dom.However,there are plenty of reasons behind this exception like incorrect element selection,load time and so on. So You need to use <code>webdriverwait</code>.</p>
<pre><code>from selenium import webdriver
from selenium.webdr... | Python & Selenium: How to avoid StaleElementReferenceException error from dividend.com | python|selenium|screen-scraping | 0 | 46 | 1 | 72,156,955 | 72,156,955 | 1 | true | 2022-05-07T22:18:39.590Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Python & Selenium: How to avoid StaleElementReferenceException error from dividend.com<p>I'd like to get company names from <a href="https://www.dividend.com... |
72,156,959 | How does the second variable work in "for i, j in enumerate" vs list[i]<p>I understand that it is for 'index', 'value' in enumerate, I thought that I could use the second variable as list[index] but it doesn't seem to work as such, I was wondering what the difference was.</p>
<pre><code>codeCopy = [1,2,1,1]
currentSequ... | <blockquote>
<p>which outputs their original values instead of their new value of 'none'</p>
</blockquote>
<p>It's not supposed to do that. The values <code>n</code> and <code>b</code>, as returned by <code>enumerate</code>, are pointers to the objects, but setting them to <code>None</code> only changes what those vari... | How does the second variable work in "for i, j in enumerate" vs list[i] | python | 0 | 54 | 2 | 72,157,017 | 72,157,017 | 1 | true | 2022-05-07T23:04:25.013Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How does the second variable work in "for i, j in enumerate" vs list[i]<p>I understand that it is for 'index', 'value' in enumerate, I thought that I could u... |
72,156,298 | Mongo invalid document for insert: keys cannot begin with "$": "$date"<p>I'm working on a script that is moving some documents from one collection to another, so if a document met the needed criteria I'm inserting it into another collection and removing it from the original collection. And one document failed with the ... | <pre><code>{
"$date" : {
"$numberLong" : "1485872000000"
}
</code></pre>
<p>is BSON date in canonical extended JSON format <a href="https://mongodb.com/docs/manual/reference/mongodb-extended-json/#mongodb-bsontype-Date" rel="nofollow noreferrer">https://mongodb.com/docs/manual/... | Mongo invalid document for insert: keys cannot begin with "$": "$date" | mongodb | 0 | 156 | 1 | 72,157,042 | 72,157,042 | 1 | true | 2022-05-07T20:53:26.960Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Mongo invalid document for insert: keys cannot begin with "$": "$date"<p>I'm working on a script that is moving some documents from one collection to another... |
72,156,263 | Dependencies vs devDependencies in monorepo<p><a href="https://github.com/changesets/changesets/blob/main/packages/cli/README.md#getting-started" rel="nofollow noreferrer">This cl tool</a> can be installed as a devDependency. But they say to install it as a dependency if you are in a monorepo.</p>
<p>Why is that?</p> | <p><code>devDependencies</code> in the root package.json can be used in all packages in the monorepo. This is generally used to co-locate test-related deps and config (jest, eslint, etc).</p>
<p>A couple caveats:</p>
<ol>
<li>This only works for non-CLI <code>devDependencies</code>. If you need to run a
CLI from a chil... | Dependencies vs devDependencies in monorepo | javascript|dependencies|monorepo|cl | 0 | 189 | 1 | 72,157,068 | 72,157,068 | 1 | true | 2022-05-07T20:47:57.510Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Dependencies vs devDependencies in monorepo<p><a href="https://github.com/changesets/changesets/blob/main/packages/cli/README.md#getting-started" rel="nofoll... |
72,157,080 | Why won't my foreach loop compile in Unity?<p>I know this shouldn't be such a big issue, but for some reason a Foreach loop in a Unity project of mine won't compile. As far as I can see it follows the syntax perfectly, but Unity throws 10 syntax errors upon compilation. I've tried restarting both Unity and my computer,... | <p>I think the problem might be <code>object</code> is a keyword for c#, you can try to use @ to escape <a href="https://docs.microsoft.com/en-us/dotnet/csharp/language-reference/keywords/" rel="nofollow noreferrer">keyword</a>, otherwise use other name instead of <code>object</code></p>
<pre><code>foreach (GameObject ... | Why won't my foreach loop compile in Unity? | c#|unity3d|foreach | 0 | 45 | 1 | 72,157,103 | 72,157,103 | 1 | true | 2022-05-07T23:37:50.190Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Why won't my foreach loop compile in Unity?<p>I know this shouldn't be such a big issue, but for some reason a Foreach loop in a Unity project of mine won't ... |
72,157,124 | How to convert multiple row list to a single row list?<pre><code>[[0, 0, 3, 50], [50, 100, 4, 20]]
</code></pre>
<p>I want to convert the above list to ,</p>
<pre><code>[0, 0, 3, 50, 50, 100, 4, 20].
</code></pre>
<p>I tried using the split() but it doesn't work.</p> | <p>Try the following:</p>
<pre><code>list_2d = [[0, 0, 3, 50], [50, 100, 4, 20]]
list_1d = [i for nested in list_2d for i in nested]
print(list_1d)
</code></pre> | How to convert multiple row list to a single row list? | python|list | 0 | 40 | 1 | 72,157,153 | 72,157,153 | 1 | true | 2022-05-07T23:49:37.127Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to convert multiple row list to a single row list?<pre><code>[[0, 0, 3, 50], [50, 100, 4, 20]]
</code></pre>
<p>I want to convert the above list to ,</p>... |
72,157,118 | How to share cloudformation or cdk with shared development infrastructure?<p>I asked question about how to code cost-efficient way with CDK in here.</p>
<p><a href="https://stackoverflow.com/questions/71836274/what-is-the-cost-efficient-approach-for-aws-serverless-team-development?noredirect=1#comment127052075_71836274... | <p>Depending on what kind of recurses they are using in their branches. If the resources are regional such as lambda and API gateway, then they can depoly their branches to <strong>different regions</strong>. CloudFormation is regional, so they will not clash with each other.</p>
<p>But ideally, the developers A and B ... | How to share cloudformation or cdk with shared development infrastructure? | amazon-cloudformation | 0 | 75 | 1 | 72,157,186 | 72,157,186 | 1 | true | 2022-05-07T23:47:44.643Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to share cloudformation or cdk with shared development infrastructure?<p>I asked question about how to code cost-efficient way with CDK in here.</p>
<p><... |
72,155,265 | antd InputNumber: execute function onChangeComplete instead of onChange<pre><code><Form.Item
label="Amount"
name={[index, 'amount']}
>
<InputNumber
style={{ width: '100%' }}
min={1}
// onChange={() => {
// const array = [...fo... | <p>Maybe use onInput instead of onChange?
-- OR --
Maybe a delayed call wrapped in a closure?</p>
<pre><code>function setCurrentAccountArray(arr){
// whatever your doing here
console.log("hi", arr)
}
var TO_later;
function delayedCall(fn, arg, delay){
clearTimeout(TO_later);
TO_later = setTim... | antd InputNumber: execute function onChangeComplete instead of onChange | javascript|reactjs|event-handling|antd | 0 | 47 | 1 | 72,157,200 | 72,157,200 | 1 | true | 2022-05-07T18:14:55.980Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
antd InputNumber: execute function onChangeComplete instead of onChange<pre><code><Form.Item
label="Amount"
name={[index, 'amoun... |
72,156,289 | How to determine the location of the deno script?<p>Let's say I issue the following command:</p>
<pre><code>deno run --allow-read /scripts/where-am-i.ts
</code></pre>
<p>What would need to be inside <code>where-am-i.ts</code> for it to output:</p>
<pre><code>/scripts
</code></pre>
<p>I've tried:</p>
<pre><code>console.... | <p>You can use some utilities from the <a href="https://deno.land/std@0.138.0/path" rel="nofollow noreferrer"><code>std/path</code></a> module to determine the directory of a module, based on its <a href="https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Statements/import.meta" rel="nofollow noreferrer"... | How to determine the location of the deno script? | javascript|typescript|deno | 0 | 128 | 1 | 72,157,311 | 72,157,311 | 1 | true | 2022-05-07T20:52:21.267Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to determine the location of the deno script?<p>Let's say I issue the following command:</p>
<pre><code>deno run --allow-read /scripts/where-am-i.ts
</co... |
72,149,369 | Java Spring Webflux on Kubernetes: always [or-http-epoll-1], [or-http-epoll-2], [or-http-epoll-3], [or-http-epoll-4] despite configured resource<p>Small question regarding a Java 11 Spring Webflux 2.6.6+ web app, containerized and deployed using Kubernetes please.</p>
<p>From the web app application logs, I am seeing t... | <p>By default WebFlux uses Netty as an underlining web server. Here is how Netty determine number of threads in the pool <a href="https://github.com/reactor/reactor-netty/blob/main/reactor-netty-core/src/main/java/reactor/netty/resources/LoopResources.java#L41" rel="nofollow noreferrer">Netty - LoopResources</a></p>
<p... | Java Spring Webflux on Kubernetes: always [or-http-epoll-1], [or-http-epoll-2], [or-http-epoll-3], [or-http-epoll-4] despite configured resource | spring-boot|kubernetes|spring-webflux | 0 | 269 | 1 | 72,157,323 | 72,157,323 | 1 | true | 2022-05-07T03:52:29.527Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Java Spring Webflux on Kubernetes: always [or-http-epoll-1], [or-http-epoll-2], [or-http-epoll-3], [or-http-epoll-4] despite configured resource<p>Small ques... |
72,157,302 | How to generate odd numbers based on user input conditions<p>The application should print the first <code>n</code> odd numbers, where <code>n</code> is between 1 and 25, starting at <code>start</code>. <code>start</code> is between 100 and 200 and it says where the odd number sequence should start. If <code>start</code... | <p>You only need one <code>Scanner</code>. You should perform input validation <em>before</em> your display loop. And your <code>for</code> loop syntax is incorrect, the second part should resolve to a <code>boolean</code> test (not an assignment) and <code>i=start+1+=2</code> is just wrong. Fixing it might look someth... | How to generate odd numbers based on user input conditions | java | 0 | 76 | 5 | 72,157,344 | 72,157,344 | 1 | true | 2022-05-08T00:38:47.213Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to generate odd numbers based on user input conditions<p>The application should print the first <code>n</code> odd numbers, where <code>n</code> is betwe... |
72,157,397 | clang++ library not found even when providing library path<p>I was trying to create a new OpenGL project with glfw and glad using vs code on an m1 Mac, and setup the files such that I have the include folder and lib folder which contains the necessary headers and library (libglfw3.a) files and the src folder that conta... | <p>Normally when you give libraries to link with the -l flag, you omit the lib prefix. For example: "-lglfw3" links the file "libglfw3.a". It looks like you should change your -llibglfw3 option.</p> | clang++ library not found even when providing library path | c++|visual-studio-code|clang++ | 0 | 193 | 1 | 72,157,403 | 72,157,403 | 1 | true | 2022-05-08T01:05:57.400Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
clang++ library not found even when providing library path<p>I was trying to create a new OpenGL project with glfw and glad using vs code on an m1 Mac, and s... |
72,157,497 | Reshape some rows in columns and columns in rows<p>I'd like to reorganize a data frame and Imake:</p>
<pre><code># Open my dataset
res_F <- read.csv("https://raw.githubusercontent.com/Leprechault/trash/main/ds_bandsIVs.csv")
str(res_F)
# 'data.frame': 16 obs. of 7 variables:
# $ TILE: chr "T22KBC&q... | <p>You can do this with <code>pivot_longer()</code>, followed by <code>pivot_wider()</code>, or, equivalently with <code>melt()</code>, followed by <code>dcast()</code></p>
<ol>
<li>with <code>tidyverse</code></li>
</ol>
<pre><code>library(tidyverse)
res_F %>%
pivot_longer(cols = MEAN:MAX,names_to = "STATS&q... | Reshape some rows in columns and columns in rows | r|dataframe|dplyr | 0 | 32 | 1 | 72,157,599 | 72,157,599 | 1 | true | 2022-05-08T01:40:17.020Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Reshape some rows in columns and columns in rows<p>I'd like to reorganize a data frame and Imake:</p>
<pre><code># Open my dataset
res_F <- read.csv("... |
72,157,352 | Flexbox, mobile responsive<p>how can i make this flexbox responsive with mobile? i would like the same result on mobile screen like the desktop version, i know the issue is caused by the responsivness of the flexbox and the mobile screensize, but how would I fix something like this? I think it has to do with the width ... | <p>You should use CSS Media Queries to make that mobile responsive or the way you think it should look on mobile screen devices.</p>
<p><strong>Typical media query looks like:</strong></p>
<pre><code>@media screen and (max-width:650px;){
.col{
width:100%;
}
}
</code></pre>
<p>By this way you can set styles of v... | Flexbox, mobile responsive | html|css|mobile|flexbox|responsive | 0 | 87 | 1 | 72,157,645 | 72,157,645 | 1 | true | 2022-05-08T00:51:19.657Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Flexbox, mobile responsive<p>how can i make this flexbox responsive with mobile? i would like the same result on mobile screen like the desktop version, i kn... |
72,157,562 | Divide DataFrame by constant, avoid divide by zero error<p>I want to divide 1 by the data I have in a multiindex Dataframe. The df:</p>
<pre><code>weekday Sunday Monday \
sort pre twi pre
error ... | <p><code>object</code> dtype is the problem. I can reproduce your error when I cast the data you've provided to dtype object. But if you cast it to float, the problem disappears.</p>
<p>If you don't want to change the dtype of the DataFrame, you can <code>mask</code> the 0s and element-wise divide 1 by it:</p>
<pre><co... | Divide DataFrame by constant, avoid divide by zero error | python|pandas | 0 | 31 | 1 | 72,157,661 | 72,157,661 | 1 | true | 2022-05-08T01:57:33.987Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Divide DataFrame by constant, avoid divide by zero error<p>I want to divide 1 by the data I have in a multiindex Dataframe. The df:</p>
<pre><code>weekday ... |
72,157,618 | How do I convert this pandas dataframe into records?<p>I am trying to use the yfinance package and I am not good at pandas. I'm just trying to store the data in a DB (without using to_sql, which fails).</p>
<p>The colums would be ticker | date | open | high | low | close | volume</p>
<p>But what pandas provides is not ... | <p>You can <code>stack</code> <code>prices</code> to get the output in the desired shape and select the relevant columns::</p>
<pre class="lang-py prettyprint-override"><code>out = prices.stack().rename_axis(['Date','Ticker']).reset_index()[['Ticker','Date','Open','High','Low','Close','Volume']]
</code></pre>
<p>Output... | How do I convert this pandas dataframe into records? | python|pandas|yfinance | 0 | 39 | 1 | 72,157,702 | 72,157,702 | 1 | true | 2022-05-08T02:14:15.480Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How do I convert this pandas dataframe into records?<p>I am trying to use the yfinance package and I am not good at pandas. I'm just trying to store the data... |
72,157,699 | Load a React component at runtime from a plain JSX external script<p>In general terms, what are the options that I have to load and render in runtime a React component that I have in an uncompiled JSX plain script somewhere: maybe from a string or from a url. Obviously the component script can have imports from other (... | <p>The only easy-ish option I'm aware of for something like that is to use Babel Standalone, which does JSX to JS transformation on the client-side. Insert the JSX string into a <code><script type="text/babel"></code>, and include React, React DOM, and Babel Standalone as scripts on the page.</p>
<p><di... | Load a React component at runtime from a plain JSX external script | reactjs|compilation|react-component|external-script | 0 | 59 | 1 | 72,157,712 | 72,157,712 | 1 | true | 2022-05-08T02:43:16.390Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Load a React component at runtime from a plain JSX external script<p>In general terms, what are the options that I have to load and render in runtime a React... |
72,157,695 | How to recursively access every value of every key in dict, including nested ones?<p>I have a dict that has an undetermined number of elements with undetermined number of child elements. Like this:</p>
<pre><code>data3 {
'data4': {
'world.bmp': []}, 'world_elements.png': []
}
data2 -> {'world_files.pdf': []... | <p>How about this:</p>
<pre class="lang-py prettyprint-override"><code>def recursive_dict_access(some_dict: dict):
print (f'recursive_dict_access called on {some_dict["name"]}')
for key, value in some_dict.items():
# if value is an empty list
if isinstance(value, list) and not value:
... | How to recursively access every value of every key in dict, including nested ones? | python|dictionary|recursion | 0 | 121 | 2 | 72,157,826 | 72,157,826 | 1 | true | 2022-05-08T02:42:04.603Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to recursively access every value of every key in dict, including nested ones?<p>I have a dict that has an undetermined number of elements with undetermi... |
72,157,738 | Azure Function Cron Expression on 3rd weekday of the month<p>Is there any relevant CRON expression to trigger the azure function on the 3rd weekday of the month on specific months .I tried the cron expression "0 0 22 3W 2,5,8,11 ?"..The CRON expression indicates " At 22:00:00pm, on the nearest weekday to... | <p>Here is the main documentation to the cron expressions for timer triggers: <br> <a href="https://docs.microsoft.com/en-us/azure/azure-functions/functions-bindings-timer?tabs=in-process&pivots=programming-language-csharp#ncrontab-expressions" rel="nofollow noreferrer">https://docs.microsoft.com/en-us/azure/azure-... | Azure Function Cron Expression on 3rd weekday of the month | azure|cron|azure-functions|azure-web-app-service | 0 | 153 | 1 | 72,157,864 | 72,157,864 | 1 | true | 2022-05-08T02:56:09.383Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Azure Function Cron Expression on 3rd weekday of the month<p>Is there any relevant CRON expression to trigger the azure function on the 3rd weekday of the mo... |
72,157,773 | Converting multiple UTC timestamps columns to US/Pacific in pandas dataframe<p>I have a dataset containing 2 timestamp columns with string format <code>YYYY-mm-dd HH:mm:ss</code>. The timezone of these timestamps is not included in the string, but they are in UTC and I want to convert them to US/Pacific.</p>
<p>My data... | <p>It seems you are looking for <a href="https://pandas.pydata.org/docs/reference/api/pandas.Series.dt.tz_convert.html" rel="nofollow noreferrer"><code>dt.tz_convert</code></a>:</p>
<pre><code>pd.to_datetime(df.timestamp_col, utc=True)
#0 2022-10-10 10:10:00+00:00
#Name: timestamp_col, dtype: datetime64[ns, UTC]
pd.... | Converting multiple UTC timestamps columns to US/Pacific in pandas dataframe | python|pandas|datetime|python-datetime | 0 | 67 | 2 | 72,157,877 | 72,157,877 | 1 | true | 2022-05-08T03:08:37.843Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Converting multiple UTC timestamps columns to US/Pacific in pandas dataframe<p>I have a dataset containing 2 timestamp columns with string format <code>YYYY-... |
72,157,434 | Input and Floating Strings errors<p><em>I'm trying to construct a Price calculator on Python and I'm receiving the following error:</em> <code>TypeError: 'str' object is not callable</code>
<strong>On this line of my code:</strong></p>
<pre><code>tax_rate = float(input("What is the sales tax rate? "))
</code>... | <p>On the 5ht and 6th lines of your code, you have a bit of a mess up here. Which is fine!</p>
<p><strong>What You Have</strong></p>
<pre><code>child_number = input=("What is the number of childrens? ")
adult_number = input=("What is the number of adults? ")
</code></pre>
<p><strong>What You Want</s... | Input and Floating Strings errors | python|string|floating-point|integer | 0 | 72 | 2 | 72,157,943 | 72,157,943 | 1 | true | 2022-05-08T01:21:02.103Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Input and Floating Strings errors<p><em>I'm trying to construct a Price calculator on Python and I'm receiving the following error:</em> <code>TypeError: 'st... |
72,157,894 | Render react component from jsx fetch result<p>I am trying to render fetched data, which is an array of JSX to be rendered.</p>
<pre><code>return(dataList.map((data) => (
<CustomComponent1>
<CustomComponent2>{data.name}</CustomComponent2>
</Cu... | <blockquote>
<p>How can I give a unique key to each entry?</p>
</blockquote>
<p>You should add <a href="https://reactjs.org/docs/lists-and-keys.html#keys" rel="nofollow noreferrer"><code>key</code></a> prop to child elements in iteration. That will help you to identify elements in multiple similar elements.</p>
<p><em>... | Render react component from jsx fetch result | reactjs|jsx | 0 | 36 | 1 | 72,158,010 | 72,158,010 | 1 | true | 2022-05-08T03:43:11.773Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Render react component from jsx fetch result<p>I am trying to render fetched data, which is an array of JSX to be rendered.</p>
<pre><code>return(dataList.ma... |
72,149,546 | Subprocess $Env:Path python: The filename, directory name, or volume label syntax is incorrect<p>I am trying to change the windows environment variables, but I am having trouble doing so.</p>
<p>Before I tried to use <code>os.environ()</code> I tried out using powershell commands and adding a string to <code>$Env:Path<... | <p>Python's <code>subprocess</code> on Windows does not call Powershell by default but CMD shell. So try the analogous CMD command:</p>
<pre class="lang-py prettyprint-override"><code>subprocess.run("echo %Path%", shell=True)
</code></pre>
<p>But if you need Powershell, explicitly call it with your command:</... | Subprocess $Env:Path python: The filename, directory name, or volume label syntax is incorrect | python|windows|powershell|environment-variables|subprocess | 0 | 188 | 1 | 72,158,069 | 72,158,069 | 1 | true | 2022-05-07T04:38:20.110Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Subprocess $Env:Path python: The filename, directory name, or volume label syntax is incorrect<p>I am trying to change the windows environment variables, but... |
72,151,153 | data accumulation with pandas<p>I'd like to accumulate like this.</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th style="text-align: left;">timestamp</th>
<th style="text-align: center;">id</th>
<th style="text-align: right;">strength</th>
</tr>
</thead>
<tbody>
<tr>
<td style="text-align: ... | <pre><code>df['group_me'] = df.apply(lambda x: x.squareid1 if x.squareid1 - 1 != x.squareid2 else x.squareid2, axis=1)
output = df.groupby(['timestamp', 'group_me'], as_index=False)['strength'].sum()
print(output)
</code></pre>
<p>Output:</p>
<pre><code> timestamp group_me strength
0 1383260400000 1.0 0... | data accumulation with pandas | python|pandas | 0 | 71 | 1 | 72,158,103 | 72,158,103 | 1 | true | 2022-05-07T09:21:22.897Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
data accumulation with pandas<p>I'd like to accumulate like this.</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th style="text-al... |
72,158,046 | How to access fetched data from an API<p>I would like to fetch stock market data from <a href="https://www.alphavantage.co/query?function=TIME_SERIES_DAILY&symbol=IBM&apikey=https://www.alphavantage.co/query?function=TIME_SERIES_DAILY&symbol=IBM&apikey=demo" rel="nofollow noreferrer">this API</a> and st... | <p>With <code>Object.keys(obj)</code> you can get list of unknown key. With those key you can fetch object properties.</p>
<p>below snippet may help you.</p>
<pre><code>import React, { useState, useEffect } from 'react';
import axios from 'axios';
function App(props) {
var baseUrl = `https://www.alphavantage.co/q... | How to access fetched data from an API | javascript|reactjs|api|axios|fetch | 0 | 50 | 2 | 72,158,152 | 72,158,152 | 1 | true | 2022-05-08T04:24:04.350Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to access fetched data from an API<p>I would like to fetch stock market data from <a href="https://www.alphavantage.co/query?function=TIME_SERIES_DAILY&a... |
72,144,591 | Extending Vuetify's VBtn component to create a reusable icon button component<p>I've been using the example Codepen (<a href="https://codepen.io/whoistobias/pen/yLNgjwy" rel="nofollow noreferrer">https://codepen.io/whoistobias/pen/yLNgjwy</a>) to try to extend the Vuetify <code>VBtn</code> component to create a reusabl... | <p>The problem is your icon names are incorrect. The default icon names are prefixed with <code>mdi-</code>. You can see the list of available icons from <a href="https://materialdesignicons.com/" rel="nofollow noreferrer">https://materialdesignicons.com/</a>.</p>
<p>I'm assuming <code>mdi-plus</code> is a good icon fo... | Extending Vuetify's VBtn component to create a reusable icon button component | javascript|vue.js|vuetify.js|extend | 0 | 90 | 1 | 72,158,156 | 72,158,156 | 1 | true | 2022-05-06T16:18:48.777Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
Extending Vuetify's VBtn component to create a reusable icon button component<p>I've been using the example Codepen (<a href="https://codepen.io/whoistobias/... |
72,158,188 | cannot unpack non-iterable int object creating shop and cart in Django with session<p>I am creating a store and when executing this address <a href="http://127.0.0.1:8000/carro/agregar/3/" rel="nofollow noreferrer">http://127.0.0.1:8000/carro/agregar/3/</a> it has to load the product in the store widget where the cart ... | <p>You can't just pass a single integer positional argument to the <code>get</code> or <code>filter</code> functions, you need to pass keyword arguments where the key is the name of the field you want to filter on.</p>
<p>If you are passing the <code>id</code> of the instance then use "id" as your keyword arg... | cannot unpack non-iterable int object creating shop and cart in Django with session | python|django|session | 0 | 189 | 1 | 72,158,214 | 72,158,214 | 1 | true | 2022-05-08T04:58:54.533Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
cannot unpack non-iterable int object creating shop and cart in Django with session<p>I am creating a store and when executing this address <a href="http://1... |
72,158,185 | trouble with the map function<p>I'm pretty new to python, and am playing around with codes for prime numbers, I created a function that tests the goldbach conjecture on any positive integer given, and returns False, 0, 0 if the conjecture does not apply, and returns True, p1, p2 if the given number follows the goldbach... | <p>I took a crack at creating the program from your specifications. I am not sure that you've implemented the functions you haven't listed the same way that I have, but I have tested this on my machine and have verified that I get the results you desire. Note that the post by jwillis0720 uses a more elegant list filt... | trouble with the map function | python | 0 | 56 | 2 | 72,158,346 | 72,158,346 | 1 | true | 2022-05-08T04:57:49.923Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
trouble with the map function<p>I'm pretty new to python, and am playing around with codes for prime numbers, I created a function that tests the goldbach co... |
72,158,381 | C# How to get rid of "\" from JSON?<p>I have following C# code which generates output like this:</p>
<pre><code> Task<OnlineResponse> task = client.Execute(query);
OnlineResponse response = task.Result;
Result result = response.Results[0];
dynamic resultJson = JsonConvert.SerializeObject(result.Da... | <p>you serialized json string twice. just return the result.Data as it is. its already a json string. if you remove backslashes you wont be able deserilze the object.</p> | C# How to get rid of "\" from JSON? | c#|json | 0 | 38 | 1 | 72,158,402 | 72,158,402 | 1 | true | 2022-05-08T05:36:23.830Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
C# How to get rid of "\" from JSON?<p>I have following C# code which generates output like this:</p>
<pre><code> Task<OnlineResponse> task = client.... |
72,158,388 | When cursor in textbox make it green border<p>In the following code I try to make the border green when the user is typing in keyboard, but the following does not work</p>
<pre><code><div id="container">
<!-- This element's contents will be replaced with your component. -->
</div><!DO... | <p>your code is fine the issue is when you select the text field there is a outline showing it is selected which covers the green border to fix this just add <code>outline: none;</code> to your input box style i.e.</p>
<pre><code> input[type="text"] {
width: 100%;
padding: 12px 20px;
... | When cursor in textbox make it green border | html|css | 0 | 37 | 3 | 72,158,441 | 72,158,441 | 1 | true | 2022-05-08T05:38:06.430Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
When cursor in textbox make it green border<p>In the following code I try to make the border green when the user is typing in keyboard, but the following doe... |
72,158,371 | How would I modify my code to delete chars from the beginning?<p>So instead of starting from the last index I would like it to do the opposite where it would start removing the start of the string (first index).</p>
<pre><code>public class Sample
{
public static void main(String[] args)
{
char y[] = ... | <p>Here is the code for your answer. This should work for you.</p>
<pre><code>public class MyClass {
public static void main(String[] args) {
char y[] = {'L','E','M','O','N','A','D','E'};
int len = y.length;
for (int z = 0; z < len; z++){
for(int w = z; w < len; w++){
... | How would I modify my code to delete chars from the beginning? | java|arrays|for-loop|queue|stack | 0 | 63 | 3 | 72,158,467 | 72,158,467 | 1 | true | 2022-05-08T05:33:11.163Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How would I modify my code to delete chars from the beginning?<p>So instead of starting from the last index I would like it to do the opposite where it would... |
72,151,278 | How to count how many times document was downloaded in Firebase?<p>I have a collection in my Firestore Database with posts. Each post has some comments as a document in the collection <code>comments</code> in the main post document (screenshot)<a href="https://i.stack.imgur.com/HadLY.jpg" rel="nofollow noreferrer"><img... | <blockquote>
<p>I want to increment the value of <code>timesViewed</code> for each comment which has been downloaded and displayed.</p>
</blockquote>
<p>If you're looking for something that does that automatically, please note that there is nothing built-in.</p>
<blockquote>
<p>Is it possible to do that?</p>
</blockquo... | How to count how many times document was downloaded in Firebase? | android|firebase|kotlin|google-cloud-platform|google-cloud-firestore | 0 | 52 | 2 | 72,158,742 | 72,158,742 | 1 | true | 2022-05-07T09:37:26.660Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to count how many times document was downloaded in Firebase?<p>I have a collection in my Firestore Database with posts. Each post has some comments as a ... |
72,158,390 | How to compare text and select similar sentences in sqlite?<p>I'm using NLP to extract sentences containing certain keywords from SEC filings across different years. I store the output via pandas dataframe in sqlite. So far so good.
The problem comes when I want to compare sentences from two different years, say 2022 a... | <p>sqlite3 supports full text search with the <a href="https://www.sqlite.org/fts5.html" rel="nofollow noreferrer">FTS5 Extension</a>.</p>
<p>You have to create a <a href="https://sqlite.org/vtab.html" rel="nofollow noreferrer">virtual table</a>, and then you can use the <code>MATCH</code> keyword.</p>
<pre class="lang... | How to compare text and select similar sentences in sqlite? | python|sql|sqlite|sentence-similarity | 0 | 72 | 2 | 72,158,789 | 72,158,789 | 1 | true | 2022-05-08T05:38:19.570Z | Please answer the following Stackoverflow question on Programming. Answer it like you are a developer answering Stackoverflow questions.
Stackoverflow question:
How to compare text and select similar sentences in sqlite?<p>I'm using NLP to extract sentences containing certain keywords from SEC filings across differen... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.