Latest Questions

How to configure the cluster to provide signing

I have deployed DigitalOcean Chatwoot. Now I need to add the certificate created in the cluster config so that it can be accessed using HTTPS. I am following th

How to extract and access data from JSON with PHP?

This is intended to be a general reference question and answer covering many of the never-ending "How do I access data in my JSON?" questions. It is here to

Finding the third largest string from an array of strings in Java

One of my friends asked me about a coding challenge that their lecturer gave them as an exercise. I got a solution working to solve it. But I think the solution

Unix command to add 2 numbers from 2 separate files and write it to a 3rd file

I have 2 files. I need to add the count of rows of the both and write it to 3rd file. If the content of 3rd file is >25 , i need to print error.txt and if =&

how can use exception handling when we are calling a function in java

This is my code i want to call a method with another parameter with use of exception handling i want to sorround with try and catch my calling function. That Ha

how to ignore tilde accent in search filter js?

When I look in the search engine for a word with an accent, for example: Débora, Lázaro, Ángela, Álvaro, Arquímedes, etc. doe

Ensure a class always uses its own version of a method rather than the one defined in a subclass?

I have this code: class A: def __init__(self, vals: list): self._vals = vals def __len__(self) -> int: # some side effects like logg

Promise returns undefined nodejs

i am back with a same issue for my promise returning undefined please help. Here, i am using ipfs to save data with savedata() which takes in a json string,a do

Adding custom cidr to ingress security group using Lambda without default vpc

First of all I have been searching stackflow and the internet for this but I didn't find exactly where the issue is. Basically I am trying to add custom cidr ip

AWK command to read value from Json

I want to read a value using awk command from below json by giving the key name as input, can you please help me on this "[{\"key\":\"ResourceClass\",\"value\":

Android Compose keeps recomposing

I am writing a LazyColumn, items are LazyRows. But the PasserItem keeps recomposing when gently swipe, I see log keep pringing and never stop. I come here for h

SwiftUI View wrapped up in Menu doesn't resize

I want to use View inside Menu and my View has @State property, but I faced the problem that view wrapped up in Menu doesn't resize. I checked documentation and

TKInter Option list to run a command to move to next level

I have attempted to create a function that will look at the current value in the OptionList and run the assigned code depending on its value. Here I have set-up

Setting Vim whitespace preferences by filetype

At my work, I am required to follow the house style for indentation, which goes as follows: 2 spaces when coding html and ruby tabs when coding javascript, wit

Deleting cookie in client from server failing (Firefox)

Im trying to delete the cookies in the client that my server created every time the user logout, they have httpOnly:true attr so only the server response can de

How do I add the values from three arrays?

Is there an easy way to add the elements of arrays together? Let's say I have 3 arrays. [15,22,35,40] [10,20,12,20] [11,24,14,22] What I want to do is add up

Incorrect result in JavaScript calculation [duplicate]

I'm fairly new to JavaScript and wanted to convert one of my calculation spreadsheets to something I can use on a web page. However, the calcu

Trying to make images as sprites in pygame

Why isn't this code working? I'm trying to create a class to quickly create players for my game in pygame. I was trying to create a sprite based on what he did

How to access prefix S3 while auto record with Amazon IVS?

Today I tried to use Amazon Interactive Video Service with auto record to an Amazon S3 bucket. The problem is that after live streaming ended I want to get the

Why do I have an https www redirect error with my single SSL certificate enabled domain?

My web server is in the cloud, a VPS on Vultr. I have added the following lines to my apache.conf file: Options -Indexes +FollowSymLinks AllowOverride A

React Image gallery issues - return outside the function

Im having issues turning a html and js file into a react component (image gallery). The below is the component and the images are taken from a shop.js file. Whe

Random Lottery Number Generator without repeat sets?

Random gen() picks a repeated number, the same number as 33, 33, in a list. I want to get a different list from numbers [0.99]. What method should be used to fi

How to customize hover text of box plot trace in plotly.js?

I would like to create a box plot and customize the hover text. Creating the boxplot was successful. However, the goal is to have measurement title, min, q1, me

Unit testing for python function-using post requests and get requests

I am trying to test the below function using unit test mocks but i am not able to do it since the return type from request get/post is of type <class 'reques

ssh works on putty and terminal but not vscode Remote ssh (Error: connection could not be established)

I recently came across this issue with the Vscode remote ssh extension. Everything was working fine but ssh suddenly has issues (connection could not be establi

How to get all the dependencies of Maven packages

To start off, I am still a student and trying to learn things, but I am quite stuck on how to get all the dependencies of each package from Maven. Initially, I

kubernetes go sdk simple demo

the demo source code package main import ( "fmt" "time" "k8s.io/apimachinery/pkg/util/wait" "k8s.io/client-go/informers" "k8s.io/client-go

Spring cloud stream merge responses from two different functions

I'm trying to use spring cloud stream to solve the following problem: I have a class that calls two separated functions (Function A and B), both of those funct

How to send JSON body from API Gateway without using Lambda in CDK

Is there a way to send JSON body as response for 'GET' method in AWS API Gateway without using AWS Lambda. Here JSON is constant. It will be same every time thi

PostgreSQL subqueries as values

I am trying to use a postgreSQL INSERT query with a subquery as parameter value. This is to find the corresponding user_id from an accompanying auth_token in us