Latest Questions

Which design pattern is useful to evaluate conditions and return Boolean value

I would like to know best coding practice or design pattern which I can follow to achieve following task in Java: I need to enable check box in UI based on cert

New color terminal prograss bar in pip

I find the new version pip(package installer for Python) has a colorful progress bar to show the downloading progress. How can I do that? Like this:

Problems matching values from nested dictionary

In TestRail, I have created several testruns. When I execute: test_runs = client.send_get('get_runs/1') pprint(test_runs) The following results are returned:

I can't run pipenv install django

Whenever I enter pipenv install django in the cmd an error appears: " 'pipenv' is not recognized as an internal or external command, operable program or batch f

How can I edit this code so that it prints the result a certain way?

I'm trying to get this code: line = input("String: ") letters = "" words = line.split() for word in words: letters = letters + word[0] print(" ".join(letter

Laravel 9 dynamic Email configurations

I am coming to you with a problem to which I couldn't find a solution on google after hours of googling. I want to be able to send emails by using different SMT

php throws exception "Call to undefined function oci_connect()"

Here is my configuration: Window Server 2016 build 14393 From phpinfo: PHP Version 8.1.5 Architecture X64 Server API CGI/FastCGI Loaded configuration file: D:

Sending FCM Batch request for legacy HTTP API

Using the legacy FCM HTTPS API is it possible to send messages to a device or a device group as stated in the documentation here, but their is not information r

message.author.id TypeError: Cannot read properties of undefined (reading 'id')

Why i didnt get message.author.id and create the channel with special permissions? const {SlashCommandBuilder} = require("@discordjs/builders") const { Client,

How to remove slowness of powerbuilder 12.6 application?

It's taking more than 15 minutes to search for Library entry.can anybody suggest how i can remove slowness of the application? Below image

Can't display OpenCV VideoCapture in Qt

I want to display the content of my VideoCapture in a QGraphicsView, however if I run the Program my WebCam activates, but nothing is displayed onto my Graphics

Executing command on Plink command line fails with "not found"

Goal: connect to AntMiner via SSH, and send poweroff command. command: plink.exe -v -t -ssh antminer -l root -pw xxx poweroff Connecting to 10.0.1.11 port 22

Is it possible to replace a value in a json string that occurs multiple times only at the top level of the structure via regex?

Hiho, I have a json string with the following structure: { "version": "1.0.0", "dependencies": { "version": "1.0.0" } } It can also look like th

Can a C# object "kill" itself?

In C#, can an object method invoke the object's own d-tor? and making any reference to the object invalid? I'm trying to build an "object control" in memory sys

Weird behavior of object references, "ghost" object

I was messing around with some sample code to check if I understood how objects behave when referring to one another when I stumbled upon this situation: public

PostgreSQL restoration throwing error : replication slot does not exist

Environment: Postgresql 13.x (dockerized) I was trying to test the DR setup for PostgreSQL nodes. pg_basebackup and wal_files archive was taken from the standby

slicing with .loc in pandas

I was reading the book - "Python for Data Analysis" and doing code side-by-side on Jupiter notebook. Here is my DataFrame named data : one t

How to pagination data to optional parameters

I'm Using react-bootstrap-table-next pagination module, In that I am using sizeperpage How do I pass sizeperpage data to the params. code excuted: <Bootstra

In SOClass, how to prevent an Operation from completing from the client side?

Sometimes in your client code, you want to cancel the current operation or prevent it from completing. How can you do that?

Jetpack Compose structure

I have a question Now, for example, in the old days, we had different activities, we had different fragments The code was divided into different files For examp

Module not found: Error: Can't resolve 'trusted-types' in '' angular

getting Module not found: Error: Can't resolve 'trusted-types' installed trusted types using this command npm i @types/trusted-types --force. and npm install t

Angular module federation on azure app service

I’m creating a website with webpack federation module. For this I have 3 projects out of 3 different git repos. So I have 3 here in azure devops. My quest

How to call a non-class function from a class method?

I'm trying to call the sh method from FileUtils. class A def self.method sh('echo hello') end end def function sh('echo hello') end function # this

ElectronJS: Window always-on-bottom (inverse of top-most / widget)

I am currently creating a system monitor application for which I would like it to work as a widget. Please see example of my application below: ElectronJS syste

Python, Convert Arbitrary List of Floats to Decimals with Most Precision without Rounding Errors

I'm writing code that has to take a bunch of floats in Python and convert them to decimals without any rounding errors but with as much precision as possible. I

Cannot access a directive before initialization. Reference error

I have an Angular module with a static function called forRoot() that receives an object as a parameter and a service with a parameter in the constructor called

Pulling another dev's PR to my local machine

A dev on my team made a PR to merge his changes from his branch to our "develop" branch. I want to run his changes to our code on my machine, since I have to wr

How do I resolve InflateException: Binary XML file line problem?

I'm going to inflate the recycler view in the home fragment using the Navigation component. There are two problems here. InflateException Issues Only one first

Flutter formkey exception displayed _CastError (Null check operator used on a null value)

I have created a form by wrapping a column widget in Form() as so Form( key: formKey, child: Column( children: [ But when I try to set fina

PostgreSQL year, quarter calculator

Given a year and a quarter, a procedure should INSERT values into table tb_quarter, which is empty and have this structure: CREATE TABLE erp.tb_quarter (