Welcome to Software Development on Codidact!
Will you help us build our independent community of developers helping developers? We're small and trying to grow. We welcome questions about all aspects of software development, from design to code to QA and more. Got questions? Got answers? Got code you'd like someone to review? Please join us.
General Q&A about programming, scripting, software design & architecture, process, tools, testing, and more.
Filters (None)
Problem How can I compress each column of a dataframe to the output of a function (i.e., mean), preserving columns? MWE import pandas as pd data = {"A": [1, 2, 3, 4], "B": [5, 6, 7, 8]} ...
I am looking for a way to programmatically edit and save .dbc files that are meant for J1939 CAN communication. I have a few large files that need to be compared/edited. Being able to import, edit...
Temporary notice: this is part of an ongoing project of transferring and splitting my canonical from Stack Overflow on common errors in Google Apps Script. As soon as the Q&As are finalized, ...
I have the following code: use serde::{Deserialize, Serialize}; #[derive(Sereialize, Deserialize)] struct Container<const SIZE: usize> { contents: [String; SIZE] } But I'm getti...
I installed Node.js using NVS to manage my node installations. This works great, except that I haven't been able to figure out how to debug using VS Code. When trying to launch, I receive this err...
I have a git repository with some submodules. When the submodule repos get new commits on the remote, how can I pull them all?
Temporary notice: this is part of an ongoing project of transferring and splitting my canonical from Stack Overflow on common errors in Google Apps Script. As soon as the Q&As are finalized, ...
I have a function that loads JSON data and is declared to return a dictionary with string keys and values of any type (Dict[str, Any]). However, mypy is raising an error stating that I am returning...
I like using NATURAL JOIN in Snowflake, because I find it more elegant than explicit join clauses. However, it appears that the natural join behaves similar to an inner join, in that null values o...
Is there a way to add support for "move symbol" in Python code for VS Codium? PyCharm can do this, but I am looking for a VSC solution. PyLance can do this, but PyLance itself is closed source, a...
In the last few months, AI has advanced considerably, notably in the area of generating images. We now have powerful models like DALL-E, Stable Diffusion, etc. These are quite competent at generati...
I am working on adding uncertainty to some of my dynamics within a larger Monte Carlo simulation. As a way to perform multiple operations on each value, I decided to make and use a new function to ...
I am migrating an application from Log4j1 to Log4j2 using the API bridge jar. All references to the log4j1.jar have already been removed. I set the system property in Websphere as a JVM argument -...
I am all new with using Redux Toolkit, I followed the official documentation to setup the store: // store.ts import { configureStore, ThunkAction, Action, combineReducers } from '@reduxjs/toolkit...
I wanna make a form in React native. A field in this form in (non-native) React would be like this: <div> <label htmlFor="lastName">Last Name:</label> <input type="text...
Can anyone explain to me why my Haskell function gives rise to a type-definition error? Originally, I wrote the following function to subtract one from the first n elements in a list: dec_first :...
I'm experiencing an issue where my program appears to freeze when executing the post_comments_to_lemmy function. This function fetches comments from the GitHub API and posts them to a Lemmy instanc...
How do I add functionality to the back button in Android without reimplementing the back button entirely? Prior to last year, I would just call onBackPressed() and then simply override it: overri...
Context Using the lemmy API, I'm trying to get a list of sublemmies (lemmy communities) that a user is following. Reading the documentation, I using the /site endpoint, I should be able to get a ...
Functions in C have external linkage by default. In other words, the storage class specifier extern is applied to functions by default, with the effect that they are visible to all translation unit...
Flutter supports packaging a SQLite instance with a Flutter app using the Sqflite plugin. I do not like the speed of SQLite or the fact that it does not enforce column datatypes and want to use som...
I want a way to make it so that I can use list B to find out if a copy of itself exists in list A. listA = ['1', '1', '0', '1', '0', '1', 'down'] 2 ['0', '0', '1', '1', '1', '1', 'up'] 2 ['1', '...
#include<stdio.h> struct Book { char title[20]; char author[20]; int pages; }; void init_Book_types(struct Book* aTitle,struct Book* aAuthor,struct Book* aPages){ aTitle->ti...
Question What is the current state of the art database app? How does it compare to SQL? Can pandas be used in place of either? If not, is there something that bridges the gap between SQL and pand...
I am cleaning up java code in vscode to make it more readable. When I format my document there are instances when vscode inserts new line character when I don't want it. Here I show 2 examples of w...
I have a dataset of car bookings like this: car_id user_id 1 1 2 1 1 2 3 3 1 2 3 3 In this dataset, two separate groups/sets of cars and users...
When using the Array.prototype.sort method, we can pass a compare function as argument. Then, this function can be used to process array's elements, so the comparison is made using some custom crit...
When reading posts at programming sites such as this one, I frequently encounter people saying things like: "There is no pass-by-reference in C, everything is passed by value." People claiming su...
As this is the first question about Google Apps Script, here is a very brief description: it is a platform that helps people easily get programmatic access to Google apps data like Gmail messages, ...
Context I have started working on an Angular upgrade for a medium-sized project (from v. 10 to v. 15) and this is a rather long activity that is interrupted by other changes that need to be perfor...
I am using Rancher Desktop as an alternative to Docker Desktop. After using docker for a while I have noticed that C:\Users\user\AppData\Local\Docker\wsl\data\ext4.vhdx has grown quite a bit (20GB+...
When I run pip install foo, pip looks for foo in PyPi. I want it to look for it first in a private repo, let's say pypi.bar.com. Only if foo cannot be found in pypi.bar.com, should pip then look f...
My large, multi-module Maven project validation (Maven Enforcer plug-in) is playing tricks on me. moduleA> mvn validate correctly finds all modules runs enforcer on all of them displays co...
How to make Husky run git hook? I have a working git hook, prepare-commit-message, but the moment Husky was installed, the hook stopped working. Not finding much luck, I then tried to make it a "H...
Let's say I have a script that needs the user to set X number of variables at the start. One can either Pass the arguments in on the command line. Start the program and then have the user input...
I need to load a site based on a cookie. I wrote code to validate that, like this. if(!isset($_COOKIE['cookie'])){ $domain = $_SERVER['SERVER_NAME']; setcookie('cookie', $cookie, time() ...
If I have some text in a cell, how can I find the number of times another piece of text appears in it? For example, suppose A1 contains Peter Piper picked a peck of pickled peppers.. pick occurs 2...
We have a console application using the Azure WebJob SDK. The WebJob relies on a WCF service using SOAP, which it accesses through a DLL we wrote that wraps the auto-generated WCF types in somethin...
This is a rather vague question, but I'm trying to solve a specific problem and I'm inexperienced in most of the potential solutions, so please forgive the inherent ambiguity. I have access to a d...
A couple of year ago a user of Super User reported difficulties with summing values purporting to be Euros imported to LibreOffice Calc in CSV format. In the Q the user does not mention the locale...
What does lifting state up in Flutter mean, and how does it work?
Perl is by far the language I have the most experience with, and I have (big) parts of the functionality I want in the new program in existing programs. So I'm looking for a way to do this in perl,...
A Q on Stack Exchange from a very long time ago included: I have first names in one column and second names in another, I want to create a third column that contains the first character from the...
A user of Web Applications asked "How should I fix the formula?" with reference to: =IF($K4<2,$K4) applied as a Conditional Formatting [CF] formula to J4:J8, where the desired (green fill) f...
An as yet unanswered question on Web Applications, INDIRECT cell reference - Can't copy cell as reference cell pattern remains same, from @Daniel Klose is: I have an Overview Sheet where I want ...
In this Q a user asked for a simple way to represent this data: - PERSON 1 | PERSON 2 | YES - PERSON 1 | PERSON 3 | YES - PERSON 2 | PERSON 1 | YES - PERSON 2 | PERSON 3 | YES - PERSON 3 | PER...
I have text (xml actually) files. Some files contain 'foo', some contain 'bar', some contain neither and some contain both. It's the both I'm interested in. How do I do an AND search on words in...
I am working with PHP and RedBean PHP ORM. I have a table user like so: id | username ---|--------- 1 | Alice 2 | Bob I want Alice and Bob to become friends. So I want to create M-M juncti...
I am trying to implement DocuSign's eSignature REST API by using Java SDK. I am following instructions here: https://developers.docusign.com/docs/esign-rest-api/sdks/java/setup-and-configuration/ ...
Suppose we have N points on XY plane, ie. (x, y) and x, y are integers and multiple queries where each query is of the form y = mx + c and m, c are integers. Is it possible to count number of poin...