qid int64 4 19.1M | question stringlengths 18 48.3k | answers list | date stringlengths 10 10 | metadata list |
|---|---|---|---|---|
74,436,005 | <p>I want to use an older commit and add different changes (but I do not want to delete my commit history). Currently, something like this will delete the last 3 commits in my GitHub pull request history and show a new commit with my new changes:</p>
<pre><code>git reset HEAD~3
git add .
git commit -m "New changes... | [
{
"answer_id": 74436396,
"author": "knittl",
"author_id": 112968,
"author_profile": "https://Stackoverflow.com/users/112968",
"pm_score": 1,
"selected": false,
"text": "$ git rebase -i A\n$ # now change the line \"pick B\" to \"edit B\" and save the file\n$ # make your changes and stage ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436005",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/8710452/"
] |
74,436,017 | <p>I'm having difficulty setting the <code>References:</code> field in the header of an outgoing SMTP email for Gmail. I'm using Python 3.8 with <code>smtplib</code> and <code>email.message</code> libraries. The code is:</p>
<pre><code>reference_ids = [
'<BN8PR17MB27372595A957D7912CEE184FBF6F9@BN8PR17MB2737.na... | [
{
"answer_id": 74436396,
"author": "knittl",
"author_id": 112968,
"author_profile": "https://Stackoverflow.com/users/112968",
"pm_score": 1,
"selected": false,
"text": "$ git rebase -i A\n$ # now change the line \"pick B\" to \"edit B\" and save the file\n$ # make your changes and stage ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436017",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7792905/"
] |
74,436,043 | <p>Please help me with a solution to extract in a new array only the specific object that has the paramenter checked: true.
See the example below:</p>
<pre><code> {nodeName: 'node1', nodeId: 1, checked: false },
{nodeName: 'node2', nodeId: 2, checked: true },
{nodeName: 'node3', nodeId: 3, checked: false },
... | [
{
"answer_id": 74436059,
"author": "Chris Heald",
"author_id": 271475,
"author_profile": "https://Stackoverflow.com/users/271475",
"pm_score": 1,
"selected": false,
"text": "// Find the first checked node, or undefined if none are checked\nconst checkedNodes = nodes.find(node => node.che... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436043",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9971933/"
] |
74,436,073 | <p>I have this code:</p>
<pre><code> tbl <- with(mydata, table(Species, Depth))
library(ggplot2)
ggplot(as.data.frame(tbl), aes(factor(Depth), Freq, fill = Species)) +
geom_col(position = 'dodge')
</code></pre>
<p>and this dataframe</p>
<pre><code> Site Depth Substrate PoePres HaliPres Species
1 2 0... | [
{
"answer_id": 74436059,
"author": "Chris Heald",
"author_id": 271475,
"author_profile": "https://Stackoverflow.com/users/271475",
"pm_score": 1,
"selected": false,
"text": "// Find the first checked node, or undefined if none are checked\nconst checkedNodes = nodes.find(node => node.che... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436073",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9410595/"
] |
74,436,096 | <p>I find it difficult to force the deserialize operation to <strong>actually fail</strong> if the data doesn't match exactly what's expected for the output class.</p>
<pre><code>class ContainerClass {
string SomeString { get; set; } // <-- not nullable
}
</code></pre>
<p>Json file :</p>
<pre><code>[
{
&quo... | [
{
"answer_id": 74436161,
"author": "Daniel A. White",
"author_id": 23528,
"author_profile": "https://Stackoverflow.com/users/23528",
"pm_score": 0,
"selected": false,
"text": "JsonProperty JsonProperty [JsonProperty(Required = Required.DisallowNull)]\n"
},
{
"answer_id": 74436736... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436096",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9359785/"
] |
74,436,183 | <p>I am absolutely NOT a developer, but I am trying to get this abandoned app to work</p>
<p>This is the code in a file called layout.erb which is HTML</p>
<pre><code><div class="container">
<%= yield %>
</div>
</code></pre>
<p>It's throwing this error:</p>
<p>SyntaxError - /wallop/app/views... | [
{
"answer_id": 74436161,
"author": "Daniel A. White",
"author_id": 23528,
"author_profile": "https://Stackoverflow.com/users/23528",
"pm_score": 0,
"selected": false,
"text": "JsonProperty JsonProperty [JsonProperty(Required = Required.DisallowNull)]\n"
},
{
"answer_id": 74436736... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436183",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20503357/"
] |
74,436,206 | <p>Hi I am trying to store Request Response of a client to a file.I was easily able to do it for HttpRequest</p>
<p>But when I am trying to write Encoder decoder for HttpResponse I am not able to understand how to write it for entity of HttpResponse in scala.</p>
<p>Heres the code for HTTP Request encoder decoder</p>
<... | [
{
"answer_id": 74458347,
"author": "Stanislav Kovalenko",
"author_id": 8099169,
"author_profile": "https://Stackoverflow.com/users/8099169",
"pm_score": 0,
"selected": false,
"text": "HttpResponse Future Stream Encoder entity.toStrict(timeout) data val r: Future[EntityResponse] = \n resp... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436206",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11526227/"
] |
74,436,238 | <p>I have a custom user model with a field 'customer'. Each user has a customer. I am trying to get the logged in users customer so that when I add infringer, the correct customer is added for the record.</p>
<ol>
<li>I think below is wrong in views. customer=request.user.customer</li>
<li>think below is wrong in forms... | [
{
"answer_id": 74436913,
"author": "omer-bental",
"author_id": 14147658,
"author_profile": "https://Stackoverflow.com/users/14147658",
"pm_score": 3,
"selected": true,
"text": "form = InfringerForm(customer=customer) self.fields['customer'].queryset = Customer.objects.filter(customer=cus... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436238",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20453400/"
] |
74,436,263 | <p>I combined Firebase auth, riverpod, and Gorouter via Luca Venir's <a href="https://github.com/lucavenir/go_router_riverpod/tree/master/firebase_example" rel="nofollow noreferrer">repository here</a>. It really works great. Now my issue is that I'm making a web app, and I don't know how to access the GoRouter routes ... | [
{
"answer_id": 74436913,
"author": "omer-bental",
"author_id": 14147658,
"author_profile": "https://Stackoverflow.com/users/14147658",
"pm_score": 3,
"selected": true,
"text": "form = InfringerForm(customer=customer) self.fields['customer'].queryset = Customer.objects.filter(customer=cus... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436263",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16922954/"
] |
74,436,293 | <p>i would like to have a "global" object that persist in the application, even when you start other activity or fragment, its kind of annoying to use a bundle to pass the same elements in the app. Maybe with viewmodels? i dont know too much about that , so it would be handy if you give me an example or some ... | [
{
"answer_id": 74436783,
"author": "Parneet Raghuvanshi",
"author_id": 13939499,
"author_profile": "https://Stackoverflow.com/users/13939499",
"pm_score": 0,
"selected": false,
"text": "import android.app.Application;\n\npublic class MyApplication extends Application {\n\n public Stri... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436293",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19861170/"
] |
74,436,294 | <p>I have a</p>
<pre><code>Querysnapshot snapshot
</code></pre>
<p>I can supply an index and access the fields of the document perfectly like:</p>
<pre><code>snapshot.data!.docs[index]
</code></pre>
<p>However, I want to access the field of document 'thisParticularDocument' which is the id (name) of the document in Clo... | [
{
"answer_id": 74436476,
"author": "Gwhyyy",
"author_id": 18670641,
"author_profile": "https://Stackoverflow.com/users/18670641",
"pm_score": 0,
"selected": false,
"text": "QuerySnapshot snapshot.data!.docs[index]\n snapshot.data!.docs[index].data() as Map<String, dynamic>\n (snapshot.da... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436294",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12917683/"
] |
74,436,295 | <p>Dear R community on SO,</p>
<p>I am trying to create a wrapper function around <code>ggplot2::facet_wrap()</code>.</p>
<p>My goal would be to pass a <code>split_by</code> parameter to <code>ggplot2::facet_wrap()</code>, possibly unquoted, as follows:</p>
<p><code>my_ggplot2_wrapper(my_data, x = some_x_col, y = some_... | [
{
"answer_id": 74436790,
"author": "Gregor Thomas",
"author_id": 903061,
"author_profile": "https://Stackoverflow.com/users/903061",
"pm_score": 3,
"selected": true,
"text": "p <- p + facet_wrap... p + facet_wrap... vars() {{ missing() NULL ncol = 2 nrow = 2 split_by my_ggplot2_wrapper <... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436295",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16468630/"
] |
74,436,325 | <p>I want to achieve the following Header Style with flexbox in React Native. The Image should always be centered and the Arrow Button must always stick on the left side.</p>
<p>What I tried so far:</p>
<pre><code> <View style={{ flexDirection: 'row' }}>
<Ionicons name="chevron-back"... | [
{
"answer_id": 74436545,
"author": "user18309290",
"author_id": 18309290,
"author_profile": "https://Stackoverflow.com/users/18309290",
"pm_score": 2,
"selected": true,
"text": "justifyContent position <View style={{ flexDirection: 'row', justifyContent: 'center' }}>\n <Ionicons style={... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436325",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10232665/"
] |
74,436,369 | <p>I have a <code>tweet();</code> function in a cronjob that executes every hour, and in one of my files used to get data for that function I have an if else statement. What I want to do is; if the statement is true, I want the <code>tweet()</code> function not to execute at that time, and since this is an hourly cronj... | [
{
"answer_id": 74436545,
"author": "user18309290",
"author_id": 18309290,
"author_profile": "https://Stackoverflow.com/users/18309290",
"pm_score": 2,
"selected": true,
"text": "justifyContent position <View style={{ flexDirection: 'row', justifyContent: 'center' }}>\n <Ionicons style={... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436369",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17164833/"
] |
74,436,421 | <p>I have a list that I want to edit. For all the elements that start with '[x]', I want the list to remove those elements and place them into new list. But for the new list, in doing so, it should remove the '[x]' from the front of the elements.</p>
<pre><code>list1 = ['[x]final', '[x]gym', 'midterm', '[x]class', 'sch... | [
{
"answer_id": 74436545,
"author": "user18309290",
"author_id": 18309290,
"author_profile": "https://Stackoverflow.com/users/18309290",
"pm_score": 2,
"selected": true,
"text": "justifyContent position <View style={{ flexDirection: 'row', justifyContent: 'center' }}>\n <Ionicons style={... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436421",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20495138/"
] |
74,436,430 | <p>I want to debounce same function in two diferent scenarios, when user clicks search button and when user stops typing. So if the user types cat and in less than 1 second he clicks 3 times search icon we will only search one time, after 1 second he stops clicking search button.</p>
<p>I tried this:</p>
<pre><code>fun... | [
{
"answer_id": 74436431,
"author": "Dan.py",
"author_id": 8947060,
"author_profile": "https://Stackoverflow.com/users/8947060",
"pm_score": 0,
"selected": false,
"text": "function debounce(your_func,time=1000){...}\nfunction search_api(){...}\nconst debounce_search = debbounce(search_api... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436430",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/8947060/"
] |
74,436,435 | <p>I am in Uni and I am required to do a specific task the task is:</p>
<blockquote>
<p>Create a class that represents a system of linear algebra equations
(system of equations), finding roots and checking whether some set of
numbers exists as a solution of the system. Based on this class,
create descendant classes rep... | [
{
"answer_id": 74436522,
"author": "Tim Roberts",
"author_id": 1883316,
"author_profile": "https://Stackoverflow.com/users/1883316",
"pm_score": 2,
"selected": true,
"text": "a c self.a = a self.c = c x solve() import numpy as np\nclass Linear:\n # linear equation ax + by + c = 0\n ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436435",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19399005/"
] |
74,436,462 | <p>am developing a flutter application with firestore. in firestore I have a field called role and I managed to access it in my code. The role is printed correctly in the console.But I need help in displaying differnt page for each user.</p>
<p>`</p>
<pre><code>class _UserMangmentState extends State<UserMangment>... | [
{
"answer_id": 74436522,
"author": "Tim Roberts",
"author_id": 1883316,
"author_profile": "https://Stackoverflow.com/users/1883316",
"pm_score": 2,
"selected": true,
"text": "a c self.a = a self.c = c x solve() import numpy as np\nclass Linear:\n # linear equation ax + by + c = 0\n ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436462",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20478151/"
] |
74,436,466 | <p>I want to pull out a string from a txt file that shows how fast my SQL Server backups run. This shows me the line that contains the information:</p>
<pre><code>Select-String -Path "DatabaseBackup - USER_DATABASES - FULL*.txt" -pattern "MB/sec"
</code></pre>
<p>The problem is that the line of tex... | [
{
"answer_id": 74436519,
"author": "frankM_DN",
"author_id": 20034020,
"author_profile": "https://Stackoverflow.com/users/20034020",
"pm_score": 0,
"selected": false,
"text": "Select-String MatchInfo Matches (Select-String -Path \"DatabaseBackup - USER_DATABASES - FULL*.txt\" -pattern \"... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436466",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3047366/"
] |
74,436,483 | <p>I am trying to create an output that will be an array that contains 5 "sub-arrays". Every array should include 10 random numbers between 0 and 10.</p>
<p>I have this code:</p>
<pre><code>def count_tweets():
big_array = []
for i in range(5):
array = []
for p in range(10):
... | [
{
"answer_id": 74436519,
"author": "frankM_DN",
"author_id": 20034020,
"author_profile": "https://Stackoverflow.com/users/20034020",
"pm_score": 0,
"selected": false,
"text": "Select-String MatchInfo Matches (Select-String -Path \"DatabaseBackup - USER_DATABASES - FULL*.txt\" -pattern \"... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436483",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20503523/"
] |
74,436,485 | <p>Let's say I have a function called bars()</p>
<pre><code>bars () {
const bars = []
for (let i = 0; i < this.numberOfBars; i++) {
bars.push(Math.sqrt(this.numberOfBars * this.numberOfBars - i * i))
}
return bars
}
</code></pre>
<p>If I'm reducing the bars array to approximate PI, what should... | [
{
"answer_id": 74436519,
"author": "frankM_DN",
"author_id": 20034020,
"author_profile": "https://Stackoverflow.com/users/20034020",
"pm_score": 0,
"selected": false,
"text": "Select-String MatchInfo Matches (Select-String -Path \"DatabaseBackup - USER_DATABASES - FULL*.txt\" -pattern \"... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436485",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19803609/"
] |
74,436,487 | <p>I am using OR-Tools to solve a problem similar to the Nurse Scheduling problem. The difference in my case is that when I schedule a "Nurse" for a shift, they must then work consecutive days (i.e., there can be no gaps between days worked).</p>
<p>Most of the similar questions point to this <a href="https:/... | [
{
"answer_id": 74436519,
"author": "frankM_DN",
"author_id": 20034020,
"author_profile": "https://Stackoverflow.com/users/20034020",
"pm_score": 0,
"selected": false,
"text": "Select-String MatchInfo Matches (Select-String -Path \"DatabaseBackup - USER_DATABASES - FULL*.txt\" -pattern \"... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436487",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18497033/"
] |
74,436,491 | <p>What is the difference between this:</p>
<pre class="lang-cpp prettyprint-override"><code>#include <iostream>
using namespace std;
int n, d, nr;
int main()
{
cin >> n;
for(d = 1; d * d < n; d++){
if (n % d == 0){
if (d % 2 == 0) nr++;
if (n / d % 2 == 0) ... | [
{
"answer_id": 74436543,
"author": "AndyG",
"author_id": 27678,
"author_profile": "https://Stackoverflow.com/users/27678",
"pm_score": 2,
"selected": false,
"text": "0 int n,d,nr; 0 nr main int n,d,nr;"
}
] | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436491",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19061985/"
] |
74,436,507 | <p>Given a user <code>id</code>, I want to find the followers that the user follows (i.e. follow each other)</p>
<p>My Prisma model looks like the following:</p>
<pre><code>model User {
id Int @id @default(autoincrement())
name String?
followedBy Follows[] @relation("following")
fo... | [
{
"answer_id": 74438469,
"author": "G.G.",
"author_id": 931594,
"author_profile": "https://Stackoverflow.com/users/931594",
"pm_score": 1,
"selected": false,
"text": "function getFollowersMutual(userId: User[\"id\"]) {\n return prisma.$queryRawUnsafe<User[]>(\n `SELECT u.* FROM \"Fol... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436507",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/931594/"
] |
74,436,515 | <p>I am trying to set an alias name for column challenge_name especially when I encounter 'challenge' based on timestamp/date as challenge 1, challenge 2, etc. If it's not 'challenge' I would like to set the column name the same as challenge_name</p>
<p>This is my current input</p>
<pre><code>+-----------+-------------... | [
{
"answer_id": 74438469,
"author": "G.G.",
"author_id": 931594,
"author_profile": "https://Stackoverflow.com/users/931594",
"pm_score": 1,
"selected": false,
"text": "function getFollowersMutual(userId: User[\"id\"]) {\n return prisma.$queryRawUnsafe<User[]>(\n `SELECT u.* FROM \"Fol... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436515",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11221870/"
] |
74,436,528 | <p>I have a dataframe which i'd like to repeatedly sample, with replacement. Everytime I sample the df, I would like to increase the size of the sample (n) by one, up to N.</p>
<p>For example:</p>
<div class="s-table-container">
<table class="s-table">
<thead>
<tr>
<th>id</th>
<th>value_1</th>
<th>value_2</th>
</tr>
</... | [
{
"answer_id": 74438469,
"author": "G.G.",
"author_id": 931594,
"author_profile": "https://Stackoverflow.com/users/931594",
"pm_score": 1,
"selected": false,
"text": "function getFollowersMutual(userId: User[\"id\"]) {\n return prisma.$queryRawUnsafe<User[]>(\n `SELECT u.* FROM \"Fol... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436528",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/15243986/"
] |
74,436,564 | <p>I am using Kotlin.</p>
<p>I have a stored password (val password = 1111). I have an editText (passcode) that takes a "numberPassword" input. I would like the user to input the code and if it matches I will do something.</p>
<p>I have tried:</p>
<p><code>if (passcode.equals(1111)) { //do something }</code><... | [
{
"answer_id": 74438469,
"author": "G.G.",
"author_id": 931594,
"author_profile": "https://Stackoverflow.com/users/931594",
"pm_score": 1,
"selected": false,
"text": "function getFollowersMutual(userId: User[\"id\"]) {\n return prisma.$queryRawUnsafe<User[]>(\n `SELECT u.* FROM \"Fol... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436564",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19934720/"
] |
74,436,580 | <p>I have a directory (<code>2022</code>) that has subdirectories with a date as their name (<code>20220101</code>, <code>20220102</code>, etc).</p>
<p>In each subdirectory I have files that I want to archive. These files have a name that starts with either <code>L0283</code> or <code>L0284</code> and then numbers and ... | [
{
"answer_id": 74438469,
"author": "G.G.",
"author_id": 931594,
"author_profile": "https://Stackoverflow.com/users/931594",
"pm_score": 1,
"selected": false,
"text": "function getFollowersMutual(userId: User[\"id\"]) {\n return prisma.$queryRawUnsafe<User[]>(\n `SELECT u.* FROM \"Fol... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436580",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3215970/"
] |
74,436,582 | <p>I'm in the process of trying to connect the front end of my MERN application to the back end. The back end works just fine on its own, and I have no problem accessing data by manually executing HTTP requests. Now that I'm trying to connect it to the front end, I seem to be getting stuck everywhere.</p>
<p>My current... | [
{
"answer_id": 74438469,
"author": "G.G.",
"author_id": 931594,
"author_profile": "https://Stackoverflow.com/users/931594",
"pm_score": 1,
"selected": false,
"text": "function getFollowersMutual(userId: User[\"id\"]) {\n return prisma.$queryRawUnsafe<User[]>(\n `SELECT u.* FROM \"Fol... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436582",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20187870/"
] |
74,436,601 | <p>I am writing a class in python that combines the functionality of dict, defaultdict, and SimpleNamespace</p>
<p>So far I have the following code:</p>
<pre><code>import warnings
class fluiddict:
"""! A class that emulates a dictionary, while also being able to support attribute assignment and d... | [
{
"answer_id": 74436911,
"author": "Tim Roberts",
"author_id": 1883316,
"author_profile": "https://Stackoverflow.com/users/1883316",
"pm_score": 3,
"selected": true,
"text": "__setattr__ class xdict:\n def __init__(self):\n self.datastore = {}\n def __getitem__(self,key):\n ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436601",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5166365/"
] |
74,436,619 | <p>I have this form:</p>
<pre><code><form>
<input type="text" class="name" id="name1">
<input type="text" class="name" id="name2">
<input type="text" class="name" id="name3">
...
<input type="text&q... | [
{
"answer_id": 74436911,
"author": "Tim Roberts",
"author_id": 1883316,
"author_profile": "https://Stackoverflow.com/users/1883316",
"pm_score": 3,
"selected": true,
"text": "__setattr__ class xdict:\n def __init__(self):\n self.datastore = {}\n def __getitem__(self,key):\n ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436619",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1990897/"
] |
74,436,624 | <p>I have <code>LazyColumn</code> and I want to pass 2 lists in <code>items</code>, how I can do it</p>
<p>I want to do something like that if it is possible</p>
<pre><code>LazyColumn(
modifier = Modifier.fillMaxHeight(0.85f)
) {
items(cartItems,products) { cartItems,product ->
CardProduct2(cartItems... | [
{
"answer_id": 74436911,
"author": "Tim Roberts",
"author_id": 1883316,
"author_profile": "https://Stackoverflow.com/users/1883316",
"pm_score": 3,
"selected": true,
"text": "__setattr__ class xdict:\n def __init__(self):\n self.datastore = {}\n def __getitem__(self,key):\n ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436624",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18823812/"
] |
74,436,654 | <p>I am trying to extract the user id from generated file name. First I wrote them as :</p>
<pre><code>id_timestamp.ext
</code></pre>
<p>And now I need to read the list and filter out of the list of files only specific user with the id owned files.</p>
<p>I think doing</p>
<pre><code>substring(fileName, id.length)
</co... | [
{
"answer_id": 74437479,
"author": "Jakob Em",
"author_id": 8995812,
"author_profile": "https://Stackoverflow.com/users/8995812",
"pm_score": 1,
"selected": false,
"text": "const filename = 'id_timestamp.ext';\nconst regex = /^(\\w+)_timestamp\\.ext$/;\nconst id = filename.match(regex)[1... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436654",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13603485/"
] |
74,436,665 | <p>I am trying to write a frontend for my API but I stuck at some point and couldn't figure out the solution. I get the issue that my "getResult" can not invoke map function at rendering. I tried everything and I end up with nothing.</p>
<p>So my Filter component as in the following. At the end of the render ... | [
{
"answer_id": 74436966,
"author": "David",
"author_id": 328193,
"author_profile": "https://Stackoverflow.com/users/328193",
"pm_score": 1,
"selected": true,
"text": ".map() GameTable games.map(game =>\n <Game key={game.id} game={game} />\n)\n .map() const GameTable = ({games}) => {\n <... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436665",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/5012090/"
] |
74,436,676 | <h2>start code</h2>
<pre><code><table style="width:100%">
<tr>
<th>Company</th>
<th>Contact</th>
<th>Country</th>
</tr>
<tr>
<td>Alfreds Futterkiste</td>
<td>Maria Anders</td>
<td>Germany<... | [
{
"answer_id": 74436966,
"author": "David",
"author_id": 328193,
"author_profile": "https://Stackoverflow.com/users/328193",
"pm_score": 1,
"selected": true,
"text": ".map() GameTable games.map(game =>\n <Game key={game.id} game={game} />\n)\n .map() const GameTable = ({games}) => {\n <... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436676",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20406999/"
] |
74,436,686 | <p>In a classic version of states, each state implementing some interface. So we can pass execution to any current state</p>
<pre><code>class Context
{
private State _state;
public void MethodA()
{
_state.MethodA();
}
public void MethodB()
{
_state.MethodB();
}
}
</code></p... | [
{
"answer_id": 74436966,
"author": "David",
"author_id": 328193,
"author_profile": "https://Stackoverflow.com/users/328193",
"pm_score": 1,
"selected": true,
"text": ".map() GameTable games.map(game =>\n <Game key={game.id} game={game} />\n)\n .map() const GameTable = ({games}) => {\n <... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436686",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7769540/"
] |
74,436,704 | <p>I am coding a tip calculator for my class and we need to create 3 functions. The second function needs to use the number I got in the first function, and the third function needs to use the number I got in the second function.</p>
<p>What I tried:</p>
<pre><code>// Grab the HTML Elements you want to work with
const ... | [
{
"answer_id": 74437163,
"author": "Lucasbk38",
"author_id": 20480528,
"author_profile": "https://Stackoverflow.com/users/20480528",
"pm_score": 3,
"selected": true,
"text": "// Grab the HTML Elements you want to work with\nconst billTotal = document.querySelector(\"#billTotal\");\nconst... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436704",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20503678/"
] |
74,436,717 | <p>In my application I am listing in an appBar several Containers that have the names of product categories, these categories are being listed in the body with their respective products.</p>
<p>The ListView that is in the appBar has the same indexes of the ListView of the body, so the idea was to press the index 'x' in... | [
{
"answer_id": 74436928,
"author": "Yeasin Sheikh",
"author_id": 10157127,
"author_profile": "https://Stackoverflow.com/users/10157127",
"pm_score": 1,
"selected": false,
"text": "scrollDirection: Axis.vertical, \nclass TFW extends StatefulWidget {\n const TFW({super.key});\n\n @overri... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436717",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16797604/"
] |
74,436,760 | <p>I have a Users table (id, name, created_at) and a Transaction table(id, user_id, created_at, amount).
For each month, I would like to know the number of users who did not have any transaction in the 3 months interval before that month.
For example, for April 2022, the query would return number of users who did not h... | [
{
"answer_id": 74437477,
"author": "Akina",
"author_id": 10138734,
"author_profile": "https://Stackoverflow.com/users/10138734",
"pm_score": 0,
"selected": false,
"text": "SELECT count(*) \nFROM users \nWHERE NOT EXISTS (\n SELECT NULL\n FROM transactions \n WHERE users.id = tra... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436760",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3884029/"
] |
74,436,767 | <p>When I compute the following in Matlab</p>
<pre><code>myeps = abs(3*(4/3-1)-1);
format long e
eps_myeps = [eps ; myeps]
</code></pre>
<p>The output is as follows:</p>
<pre><code>eps_myeps =
2.220446049250313e-16
2.220446049250313e-16
</code></pre>
<p>Why is <code>myeps</code> not 0? Why does this not hold... | [
{
"answer_id": 74438012,
"author": "chux - Reinstate Monica",
"author_id": 2410359,
"author_profile": "https://Stackoverflow.com/users/2410359",
"pm_score": 2,
"selected": false,
"text": "4/3"
},
{
"answer_id": 74439782,
"author": "X Zhang",
"author_id": 1321247,
"aut... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436767",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20354019/"
] |
74,436,801 | <pre class="lang-none prettyprint-override"><code>function[function name](parameters){
console.log(string attached to parameter, string attached to parameter, parameter) and print)
}
</code></pre>
<p>Now what I have is this:</p>
<p><a href="https://i.stack.imgur.com/pABjJ.png" rel="nofollow noreferrer"><img src="http... | [
{
"answer_id": 74438012,
"author": "chux - Reinstate Monica",
"author_id": 2410359,
"author_profile": "https://Stackoverflow.com/users/2410359",
"pm_score": 2,
"selected": false,
"text": "4/3"
},
{
"answer_id": 74439782,
"author": "X Zhang",
"author_id": 1321247,
"aut... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436801",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20095017/"
] |
74,436,805 | <p>I have the following DataFrame</p>
<pre><code> Value Date
0 1 2022-01-01
1 2 2022-01-01
2 3 2022-01-01
3 4 2022-01-02
4 5 2022-01-02
5 6 2022-01-02
6 7 2022-01-03
7 8 2022-01-03
8 9 2022-01-03
</code></pre>
<p>I would like to obtain the following ... | [
{
"answer_id": 74437069,
"author": "I'mahdi",
"author_id": 1740577,
"author_profile": "https://Stackoverflow.com/users/1740577",
"pm_score": 3,
"selected": true,
"text": "pandas.DataFrame.pivot nan df_new = df.pivot(columns='Date', values='Value').apply(\n lambda x: pd.Series(x.dropna... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436805",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12064467/"
] |
74,436,806 | <p>Consider whether <code>x</code> in the declaration <code>int x;</code> is an expression.</p>
<p>I used to think that it's certainly not, but the grammar calls the variable name an <em><a href="http://eel.is/c++draft/dcl.decl.general#nt:declarator-id" rel="noreferrer"><code>id-expression</code></a></em> here.</p>
<p>... | [
{
"answer_id": 74437105,
"author": "n. m.",
"author_id": 775806,
"author_profile": "https://Stackoverflow.com/users/775806",
"pm_score": 2,
"selected": false,
"text": "x expression expression x int x; expression int x; x id-expression id-expression expression declaration x x expression e... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436806",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2752075/"
] |
74,436,810 | <p>I hope everyone is doing great! I'm currently learning how to use R. I'm trying to download Stock DATA from Yahoo Finance. In this case, I'm trying just to get closing prices from these securities. However, I'd like to extract only daily data from let's day September 1st 2022 to November 13rd 2022. How could I do t... | [
{
"answer_id": 74437323,
"author": "Ric Villalba",
"author_id": 6912817,
"author_profile": "https://Stackoverflow.com/users/6912817",
"pm_score": 1,
"selected": false,
"text": "library(quantmod)\n\nsymbols <- c(\"SPY\", \"JNK\", \"EEM\", \"EMB\", \"TLT\", \"USO\")\ngetSymbols(symbols)\n\... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436810",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20503653/"
] |
74,436,815 | <p>I'm trying to deserialize json-formatted response below.</p>
<pre><code>{
"context": "xxxxxx"
"value": [
{
"Id": "123"
"Time": "2022-12-01"
}
{
"Id": "123"
"Time":... | [
{
"answer_id": 74437323,
"author": "Ric Villalba",
"author_id": 6912817,
"author_profile": "https://Stackoverflow.com/users/6912817",
"pm_score": 1,
"selected": false,
"text": "library(quantmod)\n\nsymbols <- c(\"SPY\", \"JNK\", \"EEM\", \"EMB\", \"TLT\", \"USO\")\ngetSymbols(symbols)\n\... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436815",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20503681/"
] |
74,436,837 | <p>I have a txt file I need to turn into a usable dataframe in R. An example row looks like this:</p>
<pre><code>10040 1491 32006 820085011 .007 .009 .043 -.003 .008 .036 -.031 -.036 .076 .056 .124 .093 -.112 -.091 .034 .043 .00600 .01200 .004500000000 .042333333333 .0568 .0058 -.0542 -.0304 .08625 .... | [
{
"answer_id": 74437323,
"author": "Ric Villalba",
"author_id": 6912817,
"author_profile": "https://Stackoverflow.com/users/6912817",
"pm_score": 1,
"selected": false,
"text": "library(quantmod)\n\nsymbols <- c(\"SPY\", \"JNK\", \"EEM\", \"EMB\", \"TLT\", \"USO\")\ngetSymbols(symbols)\n\... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436837",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19542535/"
] |
74,436,838 | <p>Does anyone know if the <a href="https://github.com/davidstutz/bootstrap-multiselect" rel="nofollow noreferrer">Boostrap Multiselect</a> plugin works in <code>default_popup</code> for chrome extensions with Manifest V3?</p>
<p>I saved jQuery, Bootstrap & <a href="https://github.com/davidstutz/bootstrap-multisele... | [
{
"answer_id": 74437157,
"author": "user1731468",
"author_id": 1731468,
"author_profile": "https://Stackoverflow.com/users/1731468",
"pm_score": 1,
"selected": false,
"text": "\"content_security_policy\": \"default-src 'none'; style-src 'self' 'unsafe-inline'; script-src 'self' 'unsafe-i... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436838",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/8719001/"
] |
74,436,846 | <p>I have created a standalone Google Apps Script (it does not belong to any document). The script get triggered automatically at some fixed intervals. This script</p>
<ul>
<li>creates a couple of folder (if they don't exist)</li>
<li>creates a Google spreadsheet (if it doesn exist). Read said
spreadsheet.</li>
<li>upd... | [
{
"answer_id": 74437503,
"author": "Rubén",
"author_id": 1595451,
"author_profile": "https://Stackoverflow.com/users/1595451",
"pm_score": 0,
"selected": false,
"text": "/**\n * @OnlyCurrentDoc\n */\n"
}
] | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436846",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7926503/"
] |
74,436,856 | <p>I have such an array of card objects:</p>
<pre><code>const cards = [
{
type: { method: 'listen' },
reference: ['destroyed', 'word 2']
},
{
type: { method: 'synonym' },
reference: ['destroyed']
},
{
type: { method: 'listen' },
reference: ['destroyed']
},
{
type: { method: 'di... | [
{
"answer_id": 74436953,
"author": "caTS",
"author_id": 18244921,
"author_profile": "https://Stackoverflow.com/users/18244921",
"pm_score": 1,
"selected": false,
"text": "const cards = [\n {\n type: { method: 'listen' },\n reference: ['destroyed', 'word 2']\n },\n {\n type: {... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436856",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/10715551/"
] |
74,436,868 | <p>We have a user facing web app powered by a SQL Server that allows users top update a table in our SQL Server that also needs to update a document record in our dynamo database table.</p>
<p>How could I reliably ensure that both commits have taken place? We can allow up to a few seconds in latency.</p>
| [
{
"answer_id": 74444042,
"author": "Borislav Stoilov",
"author_id": 5625696,
"author_profile": "https://Stackoverflow.com/users/5625696",
"pm_score": 1,
"selected": false,
"text": "<begin trx>\nsave item in SQL db\nsave item in Dynamo DB\n<commit trx>\n"
}
] | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436868",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1030135/"
] |
74,436,878 | <p>i have file.txt like this</p>
<pre><code>
</code></pre>
<p>It is necessary to use a script or command to make it look like this:</p>
<pre><code>
</code></pre>
<p>i try <code>sort -k2,2nr file.txt</code> it works, but I also change the column in the middle)
maybe you can help me with something, I also know that <str... | [
{
"answer_id": 74444042,
"author": "Borislav Stoilov",
"author_id": 5625696,
"author_profile": "https://Stackoverflow.com/users/5625696",
"pm_score": 1,
"selected": false,
"text": "<begin trx>\nsave item in SQL db\nsave item in Dynamo DB\n<commit trx>\n"
}
] | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436878",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20503633/"
] |
74,436,917 | <p>I have a register form which shows the label "Birthdate" overwritten in the same place as the dd/mm/yyyy placeholder. Is there anyway I can remove it?</p>
<p>I tried this in CSS but it didn't work:</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div cl... | [
{
"answer_id": 74444042,
"author": "Borislav Stoilov",
"author_id": 5625696,
"author_profile": "https://Stackoverflow.com/users/5625696",
"pm_score": 1,
"selected": false,
"text": "<begin trx>\nsave item in SQL db\nsave item in Dynamo DB\n<commit trx>\n"
}
] | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436917",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17525000/"
] |
74,436,920 | <p>I want to split a text by different words and not by periods. Here is a code I tried:</p>
<pre><code>string StringFromTheInput = TextBox1.Text;
string[] splichar1 = Regex.Split(StringFromTheInput, @"(?<=[\because\and\now\this is])");
</code></pre>
<p>I want to use these words or phrases as delimiter in ... | [
{
"answer_id": 74439187,
"author": "Zakaria Najim",
"author_id": 10155157,
"author_profile": "https://Stackoverflow.com/users/10155157",
"pm_score": 2,
"selected": false,
"text": "String.Contains Method String.Substring Method string stringfromtheinput = \"Sentence blah blah blahh becaus... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436920",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20465780/"
] |
74,436,959 | <p>Is there a possibility to evaluate multiple IP networks within the same condition for advanced rule like its possible for counties ? [Currently function inIpRange allows to process only 1 IP range][1]</p>
<p>this works
<code>'AT,DE,NL,CZ,IT,CH,SK,HR,HU,SI,PL'.contains(origin.region_code) </code></p>
<p>this not
<cod... | [
{
"answer_id": 74439187,
"author": "Zakaria Najim",
"author_id": 10155157,
"author_profile": "https://Stackoverflow.com/users/10155157",
"pm_score": 2,
"selected": false,
"text": "String.Contains Method String.Substring Method string stringfromtheinput = \"Sentence blah blah blahh becaus... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436959",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7786358/"
] |
74,436,974 | <p>I have deployed a model on real-time inference in a single gpu instance, it works fine.</p>
<p>Now I want to use a multiple GPUs to decrease the inference time, what do I need to change in my inference.py to make it work?</p>
<p>Here is some of my code:</p>
<pre><code>DEVICE = "cuda" if torch.cuda.is_avail... | [
{
"answer_id": 74437401,
"author": "Giuseppe La Gualano",
"author_id": 20249888,
"author_profile": "https://Stackoverflow.com/users/20249888",
"pm_score": 0,
"selected": false,
"text": "torch.nn.DataParallel torch.nn.parallel.DistributedDataParallel from torch.nn.parallel import Distribu... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436974",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19583119/"
] |
74,436,975 | <p>I have a dataframe, <code>df</code>, with <code>datetimeindex</code> and a single column, like this:</p>
<p><a href="https://i.stack.imgur.com/X66I0.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/X66I0.png" alt="enter image description here" /></a>
<a href="https://i.stack.imgur.com/z0dEo.png" re... | [
{
"answer_id": 74437401,
"author": "Giuseppe La Gualano",
"author_id": 20249888,
"author_profile": "https://Stackoverflow.com/users/20249888",
"pm_score": 0,
"selected": false,
"text": "torch.nn.DataParallel torch.nn.parallel.DistributedDataParallel from torch.nn.parallel import Distribu... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436975",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12297666/"
] |
74,436,976 | <p>I have to join user_name from user table where as first_name and last_names from user_profile table. Until here everything is fine, but when I try to fetch respective roles assigned from user_role tables it gives multiple rows for single user as 1 user can have multiple roles.</p>
<p>While trying to apply <code>stri... | [
{
"answer_id": 74437141,
"author": "JNevill",
"author_id": 2221001,
"author_profile": "https://Stackoverflow.com/users/2221001",
"pm_score": 2,
"selected": true,
"text": "GROUP BY SELECT users.user_name, user_profiles.first_name, user_profiles.last_name,\n string_agg (roles.na... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436976",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3117920/"
] |
74,436,986 | <p>I just recently started learning Angular and I have a question. I want to implement a search method to search for a product on my site, I made search.pipe.ts, which works, but the input for input is in the header.component.ts component, and the products array is in the car-list.component.ts component.</p>
<h3>car-li... | [
{
"answer_id": 74437141,
"author": "JNevill",
"author_id": 2221001,
"author_profile": "https://Stackoverflow.com/users/2221001",
"pm_score": 2,
"selected": true,
"text": "GROUP BY SELECT users.user_name, user_profiles.first_name, user_profiles.last_name,\n string_agg (roles.na... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74436986",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20468277/"
] |
74,437,020 | <p>So I have an array of cities which I map to a react-router component (so I can redirect to the home page after the data for the city that is clicked is fetched). I put the .map index (index of the item in array) as an html id. This project was originally in JS but now I'm transforming it to TS. I get an error on id=... | [
{
"answer_id": 74437107,
"author": "Lucasbk38",
"author_id": 20480528,
"author_profile": "https://Stackoverflow.com/users/20480528",
"pm_score": 1,
"selected": false,
"text": "const cities = city.map((town, i) => {\n return <Link \n className={`citiy ${props.dark ? 'dark' : ''}`}\n... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437020",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19118115/"
] |
74,437,061 | <p>I want to alert on failure of any serverless dataproc job. I think that I may need to create a log based metric and then an alerting policy based on that metric.</p>
<p>I tried creating an alerting policy with the filter below:</p>
<pre><code> filter = "metric.type=\"logging.googleapis.com/log_entry_c... | [
{
"answer_id": 74437107,
"author": "Lucasbk38",
"author_id": 20480528,
"author_profile": "https://Stackoverflow.com/users/20480528",
"pm_score": 1,
"selected": false,
"text": "const cities = city.map((town, i) => {\n return <Link \n className={`citiy ${props.dark ? 'dark' : ''}`}\n... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437061",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19582145/"
] |
74,437,065 | <p>I have a "main" function that reads data from input data and generates an output dtoOut of a kind of Employee ID with a random name, surname, etc.</p>
<p>Example of input data</p>
<pre><code> const dtoIn = {
count: 50,
age: {
min: 19,
max: 35
}
}
</code></pre>
<p>Example of output data</p>
<p... | [
{
"answer_id": 74437107,
"author": "Lucasbk38",
"author_id": 20480528,
"author_profile": "https://Stackoverflow.com/users/20480528",
"pm_score": 1,
"selected": false,
"text": "const cities = city.map((town, i) => {\n return <Link \n className={`citiy ${props.dark ? 'dark' : ''}`}\n... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437065",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/18225712/"
] |
74,437,128 | <p>I am trying to setup a local Beam Runner for easier testing/developing.
I'd like to allow testing python pipeline which uses kafka IO locally on my mac.
Here's my current plan for the entire framework looks like:</p>
<p><a href="https://i.stack.imgur.com/Rg1nc.png" rel="nofollow noreferrer"><img src="https://i.stack... | [
{
"answer_id": 74437107,
"author": "Lucasbk38",
"author_id": 20480528,
"author_profile": "https://Stackoverflow.com/users/20480528",
"pm_score": 1,
"selected": false,
"text": "const cities = city.map((town, i) => {\n return <Link \n className={`citiy ${props.dark ? 'dark' : ''}`}\n... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437128",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19259600/"
] |
74,437,146 | <p>I´m trying to convert a local md file to json in my API, but I get syntax errors.</p>
<p>The problem seems to be that when I read the file and store it as a string variable, it gets stored without the new rows that are required by md2json to work. When I console log the variable it gets printed line by line looking ... | [
{
"answer_id": 74437107,
"author": "Lucasbk38",
"author_id": 20480528,
"author_profile": "https://Stackoverflow.com/users/20480528",
"pm_score": 1,
"selected": false,
"text": "const cities = city.map((town, i) => {\n return <Link \n className={`citiy ${props.dark ? 'dark' : ''}`}\n... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437146",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20349251/"
] |
74,437,149 | <p>I'm writing a simple utility in C and I'm writing codes to print error messages in STDERR.</p>
<p>I have a struct, defined as:</p>
<pre><code>struct arguments
{
FILE *source;
int modifier_value;
int filesize;
};
</code></pre>
<hr />
<p>I have declared a pointer to the above struct, and allocated memory t... | [
{
"answer_id": 74437393,
"author": "John Bollinger",
"author_id": 2402272,
"author_profile": "https://Stackoverflow.com/users/2402272",
"pm_score": 3,
"selected": true,
"text": "malloc() malloc() & {\n struct arguments arg = {0};\n init_arguments(&arg);\n do_something(&arg);\n ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437149",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20333834/"
] |
74,437,156 | <p>In trying to clone the flickr homepage I've become stuck trying to get the background images to transition just as they do on the <a href="https://flickr.com" rel="nofollow noreferrer">flickr homepage</a>.</p>
<p>I tried using keyframes instead of javascript and the transition-duration and animation-duration propert... | [
{
"answer_id": 74437393,
"author": "John Bollinger",
"author_id": 2402272,
"author_profile": "https://Stackoverflow.com/users/2402272",
"pm_score": 3,
"selected": true,
"text": "malloc() malloc() & {\n struct arguments arg = {0};\n init_arguments(&arg);\n do_something(&arg);\n ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437156",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20503271/"
] |
74,437,160 | <p>I'm pushing a large repo into another on Azure DevOps Repos and I'm getting error because one repo policy only allows author with <strong>@abc.com</strong> pattern for email.</p>
<blockquote>
<p>The push was rejected because one or more commits contain author email 'user1@xyz.com' which does not match the policy-spe... | [
{
"answer_id": 74437393,
"author": "John Bollinger",
"author_id": 2402272,
"author_profile": "https://Stackoverflow.com/users/2402272",
"pm_score": 3,
"selected": true,
"text": "malloc() malloc() & {\n struct arguments arg = {0};\n init_arguments(&arg);\n do_something(&arg);\n ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437160",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1038554/"
] |
74,437,199 | <p><strong>TL;DR (i.e. asking the question first):</strong></p>
<p>Is there any way to write an <code>INSERT INTO...SELECT FROM...GROUP BY...ON DUPLICATE KEY UPDATE</code> statement using row alias(es) in the <code>ON DUPLICATE KEY UPDATE</code> clause instead of the <code>col1 = VALUES(col1)</code> syntax that has bee... | [
{
"answer_id": 74437393,
"author": "John Bollinger",
"author_id": 2402272,
"author_profile": "https://Stackoverflow.com/users/2402272",
"pm_score": 3,
"selected": true,
"text": "malloc() malloc() & {\n struct arguments arg = {0};\n init_arguments(&arg);\n do_something(&arg);\n ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437199",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/6516263/"
] |
74,437,231 | <p>How to write the correct Makefile if I want to define generic targets of the form <code>a.ext1.new_ext</code>, <code>a.ext2.new_ext</code>, <code>b.ext1.new_ext</code>, <code>b.ext2.new_ext</code> etc. with prerequisites <code>a.ext1</code>, <code>a.ext2</code>, <code>b.ext1</code>, <code>b.ext2</code> respectively?... | [
{
"answer_id": 74437495,
"author": "MadScientist",
"author_id": 939557,
"author_profile": "https://Stackoverflow.com/users/939557",
"pm_score": 1,
"selected": false,
"text": "%.new_ext: %\n compiler --input $< --output $@\n"
},
{
"answer_id": 74438304,
"author": "Denis... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437231",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/2160656/"
] |
74,437,245 | <p>I am trying to query the location of an object (x,y,z coordinates) with xform, and then set the values harvested from xform to use in a setAttr command to influence the translation of a different object.</p>
<pre><code>pos = cmds.xform('pSphere1', r=True, ws=True, q=True, t=True )
print(pos)
cmds.setAttr('pSphere2',... | [
{
"answer_id": 74437495,
"author": "MadScientist",
"author_id": 939557,
"author_profile": "https://Stackoverflow.com/users/939557",
"pm_score": 1,
"selected": false,
"text": "%.new_ext: %\n compiler --input $< --output $@\n"
},
{
"answer_id": 74438304,
"author": "Denis... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437245",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20454312/"
] |
74,437,249 | <p>I am trying to convert a performance critical part of a Java code to a C++ code.</p>
<p>In Java I work with lists containing a small sample of the original list. When I add objects of the first list to the second list actually only a reference to the object is stored, so I do not copy the object. This is what I woul... | [
{
"answer_id": 74437495,
"author": "MadScientist",
"author_id": 939557,
"author_profile": "https://Stackoverflow.com/users/939557",
"pm_score": 1,
"selected": false,
"text": "%.new_ext: %\n compiler --input $< --output $@\n"
},
{
"answer_id": 74438304,
"author": "Denis... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437249",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1854563/"
] |
74,437,266 | <p>I am trying to do commands to discord.py in other file but when i try to setup them i get error
'Client' object has no attribute 'add_cog'
My main.py file:</p>
<pre><code>import discord
import music
from discord.ext import commands
client = commands.Bot(command_prefix="!", intents=discord.Intents.all())
t... | [
{
"answer_id": 74437495,
"author": "MadScientist",
"author_id": 939557,
"author_profile": "https://Stackoverflow.com/users/939557",
"pm_score": 1,
"selected": false,
"text": "%.new_ext: %\n compiler --input $< --output $@\n"
},
{
"answer_id": 74438304,
"author": "Denis... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437266",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20202578/"
] |
74,437,274 | <p>I'm trying to use mat-chip in a component. My code used to work before I upgraded to Angular 15</p>
<p>I am importing the module, which seems to be a common mistake</p>
<p>I think I've included everything according to the docs.</p>
<p>Assistance much appreciated. Thanks</p>
<p>The error is:</p>
<pre><code>Error: src... | [
{
"answer_id": 74460264,
"author": "JSON Derulo",
"author_id": 5470544,
"author_profile": "https://Stackoverflow.com/users/5470544",
"pm_score": 2,
"selected": false,
"text": "<mat-chip-list> <mat-chip-listbox> MatLegacyChipsModule"
}
] | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437274",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7462902/"
] |
74,437,275 | <p>When I run the application and search I got this error</p>
<blockquote>
<p>System.InvalidCastException - column contains NULL data</p>
<p>at Oracle.ManagedDataAccess.Client.OracleDataReader.GetDecimal</p>
</blockquote>
<p>This is my code DB repository code :</p>
<pre><code>public List<LabResult> Search(string ... | [
{
"answer_id": 74437998,
"author": "Mohm Zanaty",
"author_id": 1609232,
"author_profile": "https://Stackoverflow.com/users/1609232",
"pm_score": 1,
"selected": false,
"text": "public decimal? PatientNo { get; set; }\n public List<LabResult> Search(string term)\n {\n var dec... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437275",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/14008146/"
] |
74,437,284 | <p>I have a Pandas data frame, <code>attack_probability_df</code>:</p>
<pre><code> city date attack probability
0 Rome 1996-02-23 0.163317
1 Rome 1996-02-24 0.219221
2 Rome 1996-02-25 0.180625
3 Rome 1996-02-26 0.149749
4 Rome 1996-02-27 0.121288
</code... | [
{
"answer_id": 74437377,
"author": "cmauck10",
"author_id": 19935366,
"author_profile": "https://Stackoverflow.com/users/19935366",
"pm_score": 3,
"selected": true,
"text": ".values[0] attack_probability"
},
{
"answer_id": 74437562,
"author": "medium-dimensional",
"author... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437284",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19547474/"
] |
74,437,288 | <p>I am new in flutter I want to know how can i concatenate the list of strings into a single string.
I tried to do phrase.toString(). i have also tried</p>
<p>But I am not getting the required result. How can I get the concatenation of only tags of the list? Any help will be appreciated.</p>
<pre><code>List phrase = [... | [
{
"answer_id": 74437377,
"author": "cmauck10",
"author_id": 19935366,
"author_profile": "https://Stackoverflow.com/users/19935366",
"pm_score": 3,
"selected": true,
"text": ".values[0] attack_probability"
},
{
"answer_id": 74437562,
"author": "medium-dimensional",
"author... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437288",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20503995/"
] |
74,437,296 | <p>I'm building an app with flutter and I have a question about <a href="https://pub.dev/packages/provider" rel="nofollow noreferrer"><code>Provider.of</code></a>. In my <code>Widget</code> I call this :</p>
<pre class="lang-dart prettyprint-override"><code>Provider.of<Auth>(context, listen: false).signup(emailCo... | [
{
"answer_id": 74437377,
"author": "cmauck10",
"author_id": 19935366,
"author_profile": "https://Stackoverflow.com/users/19935366",
"pm_score": 3,
"selected": true,
"text": ".values[0] attack_probability"
},
{
"answer_id": 74437562,
"author": "medium-dimensional",
"author... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437296",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13947830/"
] |
74,437,303 | <p>I have a list of 50k+ URL's, and am looking for the most common 3/4/5/6 letters in these URLs (barring .com/.org/etc).</p>
<p>So if the URLs are <code>strings.com</code> and <code>string2.com</code>, it would tell me that <code>string</code> is the most common sequence of letters.</p>
<p>Is there a way to do this?</... | [
{
"answer_id": 74438452,
"author": "JvdV",
"author_id": 9758194,
"author_profile": "https://Stackoverflow.com/users/9758194",
"pm_score": 2,
"selected": false,
"text": "C2 =LET(x,TOCOL(DROP(REDUCE(0,SEQUENCE(4,,3),LAMBDA(a,b,HSTACK(a,LET(c,REDUCE(0,A1:A3,LAMBDA(d,e,VSTACK(d,LET(f,MID(e,S... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437303",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20504067/"
] |
74,437,311 | <p>I have the following text file and I need to calculate average of sold units.</p>
<pre><code>"Time";"unit"
"2022-09-23 12:00:00";8.10
"2022-07-19 14:00:00";8.11
"2022-09-21 14:00:00";7.88
"2022-08-11 07:00:00";7.42
"2022-07-07 00:00:00";7.81
"... | [
{
"answer_id": 74437391,
"author": "Cobra",
"author_id": 17580381,
"author_profile": "https://Stackoverflow.com/users/17580381",
"pm_score": 2,
"selected": false,
"text": "with open('data.txt', newline='', encoding='utf-8') as file:\n lines = file.readlines()\n if (count := len(lin... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437311",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20503939/"
] |
74,437,324 | <p>I am trying to determine the distance from the top of the page in JavaScript, and I am faced with a Problem that the return command won't update the new distance.</p>
<p>I tried to get the distance like this:</p>
<pre><code>document.addEventListener('wheel', getDistance);
function getDistance() {
var scrollTop ... | [
{
"answer_id": 74437422,
"author": "Lucasbk38",
"author_id": 20480528,
"author_profile": "https://Stackoverflow.com/users/20480528",
"pm_score": 1,
"selected": false,
"text": "function getDistance() {\n const scrollTop = $(window).scrollTop(),\n elementOffset = $('#distance-c... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437324",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20361409/"
] |
74,437,349 | <p>Let's assume that my Angular 14 app has a <code>FireService</code> that will fetch the latest information for an object when the application loads. A page on the application must wait for the <a href="https://rxjs.dev/guide/observable" rel="nofollow noreferrer">Observable</a> on the <code>FireService</code> to be re... | [
{
"answer_id": 74437575,
"author": "Ali Adravi",
"author_id": 586227,
"author_profile": "https://Stackoverflow.com/users/586227",
"pm_score": 0,
"selected": false,
"text": "forkJoin(\n this.FireService.thingA$(),\n this.FireService.thingB$()\n).subscribe(\n ([thisngA, thingB]) =... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437349",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/3893519/"
] |
74,437,405 | <p>I have two strings for url and I am building a regexp to take out the domain, project and repo from url.</p>
<p>The urls looks like this:</p>
<pre><code>1. https://bitbucket.org/test/test-x.git
2. ssh://git@bitbucket.org/test/test-x
</code></pre>
<p>I have this regexp working:</p>
<pre><code>r"(?:ssh|https):\... | [
{
"answer_id": 74437575,
"author": "Ali Adravi",
"author_id": 586227,
"author_profile": "https://Stackoverflow.com/users/586227",
"pm_score": 0,
"selected": false,
"text": "forkJoin(\n this.FireService.thingA$(),\n this.FireService.thingB$()\n).subscribe(\n ([thisngA, thingB]) =... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437405",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7994074/"
] |
74,437,459 | <p>I am making a Hangman game for practice. The game is set so that the computer randomly chooses a word from a list I have provided and returns the word in list form. A function then compares user input with the list and checks if user_input in list. If True, then it removes the input from the word to prevent the user... | [
{
"answer_id": 74437577,
"author": "Jean-Claude Arbaut",
"author_id": 13963867,
"author_profile": "https://Stackoverflow.com/users/13963867",
"pm_score": 1,
"selected": false,
"text": "choose_word() choice check_input original_word choice check_input None"
},
{
"answer_id": 74437... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437459",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20022629/"
] |
74,437,465 | <p>How to check for each row in dataframe if all its values are in specified range?</p>
<pre><code>import pandas as pd
new = pd.DataFrame({'a': [1,2,3], 'b': [-5,-8,-3], 'c': [20,0,0]})
</code></pre>
<p>For instance range <-5, 5>:</p>
<pre><code>>> a b c
>> 0 1 -5 20 # abs(20) > 5, hence ... | [
{
"answer_id": 74437664,
"author": "BeRT2me",
"author_id": 11865956,
"author_profile": "https://Stackoverflow.com/users/11865956",
"pm_score": 3,
"selected": true,
"text": "out = (df.gt(-5) & df.lt(5)).all(axis=1)\n# Or if you just want to supply a single value:\n# df.abs().lt(5).all(axi... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437465",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/19363912/"
] |
74,437,466 | <p>I have four polynomial (degree 2) functions and I need to find the intersection of these functions. but I do not know is any way to find all intersections in one step. my suggestion is to equalize two functions and find their roots using <code>numpy.roots</code>. but I am not sure if is it true or not. what should I... | [
{
"answer_id": 74439025,
"author": "Vin",
"author_id": 7955271,
"author_profile": "https://Stackoverflow.com/users/7955271",
"pm_score": 2,
"selected": false,
"text": "import numpy as np\nfrom numpy.polynomial import Polynomial as Poly\n\n\nfrom matplotlib import pyplot as plt\n\n# Your ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437466",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11013499/"
] |
74,437,560 | <p>In my Flink project I cannot find certain libraries for connectors (specifically I need to ingest a CSV once and read several TBs of parquet data in either batch or streaming mode). I think I have all the required packages, but I am still getting:</p>
<pre class="lang-xml prettyprint-override"><code>[ERROR] import o... | [
{
"answer_id": 74439025,
"author": "Vin",
"author_id": 7955271,
"author_profile": "https://Stackoverflow.com/users/7955271",
"pm_score": 2,
"selected": false,
"text": "import numpy as np\nfrom numpy.polynomial import Polynomial as Poly\n\n\nfrom matplotlib import pyplot as plt\n\n# Your ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437560",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/11039211/"
] |
74,437,598 | <p>When I hit play the game scene behaves as normal, <strong>even if I come from a different scene</strong>.</p>
<p>But when I am on the game scene and go to other scene and back again to the game scene some components from some game objects.</p>
<p>I am using <code>SceneManager.LoadScene("SceneName");</code>... | [
{
"answer_id": 74439025,
"author": "Vin",
"author_id": 7955271,
"author_profile": "https://Stackoverflow.com/users/7955271",
"pm_score": 2,
"selected": false,
"text": "import numpy as np\nfrom numpy.polynomial import Polynomial as Poly\n\n\nfrom matplotlib import pyplot as plt\n\n# Your ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437598",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/14694660/"
] |
74,437,600 | <p>I have a data frame of individual animals with a unique ID, the lat/long where they were found, and the date they were found. The database has frequent returns of the same individual. I have over 2000 individuals. I want to add a column to my data frame to calculate euclidian distance between current location & ... | [
{
"answer_id": 74439025,
"author": "Vin",
"author_id": 7955271,
"author_profile": "https://Stackoverflow.com/users/7955271",
"pm_score": 2,
"selected": false,
"text": "import numpy as np\nfrom numpy.polynomial import Polynomial as Poly\n\n\nfrom matplotlib import pyplot as plt\n\n# Your ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437600",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20504219/"
] |
74,437,606 | <p>I just updated my solution to .NET7. I have a build/release pipeline setup on Azure Devops which now fails in the "Restore" step.</p>
<p>This is first error, which is then followed by multiple other errors of the same type:</p>
<blockquote>
<p>2:3>Target "_CheckForUnsupportedNETCoreVersion" i... | [
{
"answer_id": 74517408,
"author": "Vlad Rudenko",
"author_id": 901333,
"author_profile": "https://Stackoverflow.com/users/901333",
"pm_score": 0,
"selected": false,
"text": " - task: UseDotNet@2\n displayName: 'Install .NET Core SDK 7.x'\n inputs:\n version: 7.x\n"
}
] | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437606",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/64157/"
] |
74,437,634 | <p>So I have dataframe that looks like this:</p>
<pre><code> STORE PRODUCT INVENTORY
1 store1 a 1
2 store1 b 0
3 store2 a 0
4 store2 b 0
5 store3 a 1
6 store3 b 1
</code></pre>
<p>I want to filter this such th... | [
{
"answer_id": 74437696,
"author": "Anoushiravan R",
"author_id": 14314520,
"author_profile": "https://Stackoverflow.com/users/14314520",
"pm_score": 3,
"selected": true,
"text": "df.loc[(df.groupby('STORE')['INVENTORY'].transform(sum) > 0)]\n\n STORE PRODUCT INVENTORY\n1 store1 ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437634",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/17902784/"
] |
74,437,641 | <p>From the JSON string below I'm trying to pull just all the waiverId's:</p>
<pre><code>data =
{
"version": 4,
"id": "(requestId)",
"ts": "2022-11-14T20:24:50+00:00",
"type": "checkins",
"checkins": {
"fromDts": &q... | [
{
"answer_id": 74437696,
"author": "Anoushiravan R",
"author_id": 14314520,
"author_profile": "https://Stackoverflow.com/users/14314520",
"pm_score": 3,
"selected": true,
"text": "df.loc[(df.groupby('STORE')['INVENTORY'].transform(sum) > 0)]\n\n STORE PRODUCT INVENTORY\n1 store1 ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437641",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20504251/"
] |
74,437,648 | <p>I have a string containing words, whitespace and numbers (integers and decimals). I want to separate them into two columns in a data frame so that column <code>A</code> contains the text and column <code>B</code> contains the number. It seems like a super simple task but I cannot figure out how to capture the text. ... | [
{
"answer_id": 74437667,
"author": "Wiktor Stribiżew",
"author_id": 3832970,
"author_profile": "https://Stackoverflow.com/users/3832970",
"pm_score": 3,
"selected": true,
"text": "extract(x, c(\"A\", \"B\"), \"^(.*?)\\\\s*(\\\\d+(?:\\\\.\\\\d+)?)$\")\n ^ (.*?) \\s* (\\d+(?:\\.\\d+)?) . $... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437648",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/4308815/"
] |
74,437,650 | <p>I want to find the text that is visible on screen from a div (i.e. that is not clipped by the scrollbar regions). Is there a way to see if a child node part is visible on screen?
I can't find anywhere to even find the node coordinates, let alone how to see coords of the word parts of a node.</p>
<p><div class="snipp... | [
{
"answer_id": 74437667,
"author": "Wiktor Stribiżew",
"author_id": 3832970,
"author_profile": "https://Stackoverflow.com/users/3832970",
"pm_score": 3,
"selected": true,
"text": "extract(x, c(\"A\", \"B\"), \"^(.*?)\\\\s*(\\\\d+(?:\\\\.\\\\d+)?)$\")\n ^ (.*?) \\s* (\\d+(?:\\.\\d+)?) . $... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437650",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1432181/"
] |
74,437,663 | <p>I'm a beginner-casual, web developer, I want to surround my menu with a background image, I've tried to do it by myself, but still, it's shows the default white background, can someone please help me out?</p>
<p>Here is my CSS script:</p>
<pre class="lang-css prettyprint-override"><code> body {
background-i... | [
{
"answer_id": 74438058,
"author": "Edy",
"author_id": 18466936,
"author_profile": "https://Stackoverflow.com/users/18466936",
"pm_score": 0,
"selected": false,
"text": "<!DOCTYPE html>\n<html lang=\"en\">\n\n<head>\n <meta charset=\"UTF-8\">\n <meta http-equiv=\"X-UA-Compatible\" ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437663",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/20504207/"
] |
74,437,669 | <p>I wish to convert a DataFrame into a dictionary where columns are the keys and (column-wise) rows are its values. I also need to use grouping when doing so.</p>
<pre><code> team id name salary
0 Alpha 10 Jack 1000
1 Alpha 15 John 2000
2 Alpha 20 John 2000
3 Bravo ... | [
{
"answer_id": 74437853,
"author": "BeRT2me",
"author_id": 11865956,
"author_profile": "https://Stackoverflow.com/users/11865956",
"pm_score": 2,
"selected": false,
"text": "Groupby to_dict out = df.groupby('team').agg(list).to_dict('index')\nprint(out)\n {'Alpha': {'id': [10, 15, 20],\n... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437669",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/9855909/"
] |
74,437,705 | <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>//Code that I have tried but it doesnt work:
$('#historyOfStatus table td').not(':contains("Revisions Required – CM")').parents("t... | [
{
"answer_id": 74437853,
"author": "BeRT2me",
"author_id": 11865956,
"author_profile": "https://Stackoverflow.com/users/11865956",
"pm_score": 2,
"selected": false,
"text": "Groupby to_dict out = df.groupby('team').agg(list).to_dict('index')\nprint(out)\n {'Alpha': {'id': [10, 15, 20],\n... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437705",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/603380/"
] |
74,437,709 | <p>So I got a numeric list <code>[0-12]</code> that matches the length of my columns in my spreadsheet and also replaced the column headers with that list <code>df.columns = list</code>.
Now i want to drop specific columns out of that spreadsheet like <a href="https://i.stack.imgur.com/f0Tt9.png" rel="nofollow noreferr... | [
{
"answer_id": 74437853,
"author": "BeRT2me",
"author_id": 11865956,
"author_profile": "https://Stackoverflow.com/users/11865956",
"pm_score": 2,
"selected": false,
"text": "Groupby to_dict out = df.groupby('team').agg(list).to_dict('index')\nprint(out)\n {'Alpha': {'id': [10, 15, 20],\n... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437709",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/12719205/"
] |
74,437,715 | <p>I'm trying to print some words stored in a list using for loop:</p>
<pre><code>#!/bin/sh
list="bla1 bla2 * bla3"
for i in $list
do
echo "$i"
done
</code></pre>
<p>I want this output:</p>
<pre><code>bla1
bla2
*
bla3
</code></pre>
<p>Running the script gives:</p>
<pre><code>bla1
bla2
[LIST OF... | [
{
"answer_id": 74437762,
"author": "Charles Duffy",
"author_id": 14122,
"author_profile": "https://Stackoverflow.com/users/14122",
"pm_score": 2,
"selected": true,
"text": "/bin/sh #!/usr/bin/env bash\n\nlist=( bla1 bla2 \"*\" bla3 )\nfor i in \"${list[@]}\"; do\n echo \"$i\"\ndone\n #!... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437715",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/13399725/"
] |
74,437,717 | <p>Consider two tibbles <code>data</code> and <code>key</code>, given here:</p>
<pre><code>library(tidyverse) # v1.3.2
set.seed(123)
data <- tibble(id = rep(LETTERS[1:10], each = 10),
position = rep(1:10, 10),
zip = sample(letters, 100, replace = T),
zap = sample(letters... | [
{
"answer_id": 74437752,
"author": "akrun",
"author_id": 3732271,
"author_profile": "https://Stackoverflow.com/users/3732271",
"pm_score": 3,
"selected": true,
"text": "slice library(dplyr)\ninner_join(data, key) %>% \n group_by(id) %>%\n slice(first(start):first(end)) %>% \n ungroup ... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437717",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/7976890/"
] |
74,437,727 | <p>I have this hook in Wordpress that will convert any uploaded PNGs or JPEGS to WebP images:</p>
<pre><code> add_filter( 'wp_handle_upload', 'create_webp' );
function create_webp($file) {
if ($file['type'] === "image/png") {
// Create and save
$img = imagecreatefrompng($file['file']);
... | [
{
"answer_id": 74473852,
"author": "Николай",
"author_id": 9098414,
"author_profile": "https://Stackoverflow.com/users/9098414",
"pm_score": 2,
"selected": true,
"text": "$posts = get_posts([\n 'post_mime_type' => 'image',\n 'post_type' => 'attachment',\n 'post_status' => 'inher... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437727",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/1356860/"
] |
74,437,741 | <p>Given the following dictionary:</p>
<pre><code>dict1 = {'AA':['THISISSCARY'],
'BB':['AREYOUAFRAID'],
'CC':['DONOTWORRY']}
</code></pre>
<p>I'd like to update the values in the dictionary given the information in the following table</p>
<pre><code>Table = pd.DataFrame({'KEY':['AA','AA','BB','CC'],
... | [
{
"answer_id": 74473852,
"author": "Николай",
"author_id": 9098414,
"author_profile": "https://Stackoverflow.com/users/9098414",
"pm_score": 2,
"selected": true,
"text": "$posts = get_posts([\n 'post_mime_type' => 'image',\n 'post_type' => 'attachment',\n 'post_status' => 'inher... | 2022/11/14 | [
"https://Stackoverflow.com/questions/74437741",
"https://Stackoverflow.com",
"https://Stackoverflow.com/users/16922748/"
] |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.