Communities

Writing
Writing
Codidact Meta
Codidact Meta
The Great Outdoors
The Great Outdoors
Photography & Video
Photography & Video
Scientific Speculation
Scientific Speculation
Cooking
Cooking
Electrical Engineering
Electrical Engineering
Judaism
Judaism
Languages & Linguistics
Languages & Linguistics
Software Development
Software Development
Mathematics
Mathematics
Christianity
Christianity
Code Golf
Code Golf
Music
Music
Physics
Physics
Linux Systems
Linux Systems
Power Users
Power Users
Tabletop RPGs
Tabletop RPGs
Community Proposals
Community Proposals
tag:snake search within a tag
answers:0 unanswered questions
user:xxxx search by author id
score:0.5 posts with 0.5+ score
"snake oil" exact phrase
votes:4 posts with 4+ votes
created:<1w created < 1 week ago
post_type:xxxx type of post
Search help
Notifications
Mark all as read See all your notifications »
Q&A

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)
71%
+3 −0
Why content delivery networks often require a www. redirect?

Why do Content Delivery Networks are often developed in such a way that they would require adding a Cname value such as www. before example.com? I ask this after switching from one CDN (Cloudflare...

2 answers  ·  posted 3y ago by deleted user  ·  last activity 3y ago by corporat‭

60%
+1 −0
Saving modified data in gridview on clicking SaveButton

I am struggling to do a save button in C# Windows Form Application where I have a GridView and I want to save all modifications I do in GridView Table(I connected it to SQL). This is the data sourc...

1 answer  ·  posted 3y ago by Cri‭  ·  edited 3y ago by Alexei‭

66%
+2 −0
How to work with current entity changes when working with @ngrx/store and @ngrx/entity?

I am fairly new to working with @ngrx pattern in Angular which is a state management pattern relying on Reactive Extensions. One of the convenient structures is @ngrx/entity which helps with manag...

0 answers  ·  posted 3y ago by Alexei‭

50%
+0 −0
Merge a pair of columns where in each row one is blank, without a formula

A Q on Stack Overflow asks how to merge two columns where each row has only one populated cell. The example was from (on the left) to (on the right): a|b a 0| ...

0 answers  ·  posted 3y ago by pnuts‭  ·  last activity 3y ago by pnuts‭

81%
+7 −0
Multiple catches with almost the same code.

I find myself often writing code like this. try { // code } catch( FailedReadException const & ex) { file.close(); std::cerr << "Read failure " << ex.readFailure() <&...

2 answers  ·  posted 3y ago by Estela‭  ·  edited 3y ago by Ayxan Haqverdili‭

90%
+18 −0
Does the location of an import statement affect performance in Python?

When writing Python-based apps (e.g. Django, Flask, etc.), it's often the case that import statements can be found all over the place, often more than once for the same module. For example, you can...

1 answer  ·  posted 3y ago by ghost-in-the-zsh‭  ·  last activity 3y ago by ghost-in-the-zsh‭

87%
+12 −0
For scripting what are the pros and cons of command line arguments versus capturing input at the start?

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...

6 answers  ·  posted 3y ago by Charlie Brumbaugh‭  ·  last activity 10mo ago by Dirk Herrmann‭

85%
+10 −0
Destroy std::mutex referenced but not owned by std::unique_lock?

Is it correct to destroy a mutex which is referenced but not owned by an unique_lock as in this code? { std::unique_ptr<std::mutex> mutex = std::make_unique<std::mutex>(); std::u...

1 answer  ·  posted 3y ago by Estela‭  ·  last activity 3y ago by Angew‭

c++
66%
+2 −0
How much memory is allocated for a MySQL VARCHAR variable in a stored procedure?

In a stored procedure let's say I have a VARCHAR variable, DECLARE example_variable VARCHAR(100); how much memory is allocated to it and is that independent of the length of the data in the var...

2 answers  ·  posted 3y ago by Charlie Brumbaugh‭  ·  last activity 3y ago by Alexei‭

83%
+8 −0
How can I emulate regular expression's branch reset in Java?

I've got this sample regex: Pattern p = Pattern.compile("(?:([aeiou]+)[0-9]+|([123]+)[a-z]+)\\W+"); It basically has the following parts: one or more lowercase vowels ([aeiou]+), followed by one ...

2 answers  ·  posted 3y ago by hkotsubo‭  ·  last activity 3y ago by hkotsubo‭

66%
+2 −0
Confusion about using std::async with class member function

So,I'm having a doubt when I call std:async() on a member function of a class. The book I'm reading says (emphasis mine) You can also pass a pointer to a member function to async(). In that case...

1 answer  ·  posted 3y ago by hamsasimon‭  ·  last activity 3y ago by Chris Jester-Young‭

50%
+1 −1
How to temporarily disable a MySQL user?

Sometimes I will need to temporarily lock out other MySQL users when I am making large structure changes and want to make sure that nobody else is inputting or changing the data. The other use case...

2 answers  ·  posted 3y ago by Charlie Brumbaugh‭  ·  edited 3y ago by Charlie Brumbaugh‭

22%
+0 −5
Which body supervises country-specific internet associations and what designations it assigned to these? [closed]

I am trying to save my question that was deleted from "Webmasters StackExchange" for not being about "a problem in a website" which I published there anonymously ; below is a shortened, directly-in...

0 answers  ·  posted 3y ago by deleted user  ·  closed 3y ago by Alexei‭

70%
+5 −1
How do I get the error message out of a requests exception?

I'm trying to log error messages from Requests exceptions. Example: try: make_web_request() except RequestException as ex: logging.error(ex) Example output: ERROR : ('Connection abo...

2 answers  ·  posted 3y ago by ajv‭  ·  last activity 3y ago by hoverhell‭

75%
+4 −0
How can I customize the default project templates, or create my own, in Android Studio 4.2.1

I want to remove a deprecated entry from the default build.gradle file as well as change the default layout of an empty activity to use Relative Layout instead of constraint. I'm using Android Stu...

0 answers  ·  posted 3y ago by TecBrat‭

40%
+0 −1
How do World Wide Web interactions happen in a general level? [closed]

I understand that any World Wide Web interaction works this way: Stage 1: Client (human or software) ⟶ User agent ⟶ HTTP/S web-server request (with an unresolved domain) Stage 2: ISP-initiated Rou...

0 answers  ·  posted 3y ago by deleted user  ·  last activity 3y ago by Alexei‭

web
30%
+1 −5
How can software track [1] how many subscribers to subreddits, [2] if subreddit is private, [3] if submissions are restricted?

Master lists like 82 food subreddits and 128 tech subreddits don't indicate each's subscribers. if it's private. Sometimes moderators can make the sub private for several days, to clean i...

1 answer  ·  posted 3y ago by TextKit‭  ·  last activity 3y ago by r~~‭

16%
+0 −8
Why most hosting providers support ticket systems allow text only (no formatting)? [closed]

Through the years I have "tasted" several website hosting companies; none of them had Markdown available in their support-ticket-systems (if all any formatting method available). Why is it? What's...

1 answer  ·  posted 3y ago by deleted user  ·  last activity 3y ago by Alexei‭

62%
+3 −1
What is the difference between a hook and a code injection?

I would define a hook as: A piece of code which changes the response to a certain event, without changing the original code that caused the event How is that different than "code injection", if a...

2 answers  ·  posted 3y ago by deleted user  ·  last activity 2y ago by BobJarvis‭

33%
+1 −4
Convert .npy files in a directory to images (.png)

I have around 20,000 .npy files in a directory. That main directory has no subfolders:- Main_dir | |--1.npy |--2.npy |--3.npy |--........ The absolute file paths are stored ...

2 answers  ·  posted 3y ago by Neel_Gupta‭  ·  last activity 3y ago by hoverhell‭

71%
+3 −0
Error: 18456, Severity: 14, State: 5; SSMS > Network sever from PC

I just completed my first install of SQL as a server-based, Enterprise Edition. I wanted to check it out using SSMS on PC using my Admin Access. But could not connect. For security reasons my adm...

1 answer  ·  posted 3y ago by James Jenkins‭  ·  edited 3y ago by Alexei‭

80%
+6 −0
How to do "out-of-source" build properly with cmake?

There are two broad types of build environments - in-source and out-of-source. "In-source" means the compiled files will appear in the same directory as source files. "Out-of-source" means there is...

2 answers  ·  posted 3y ago by anatolyg‭  ·  last activity 3y ago by alex‭

60%
+1 −0
In a stored procedure, is it possible to get the total number or rows updated by different statements?

I have a bunch of stored procedures that look like something this CREATE PROCEDURE example() BEGIN UPDATE STATEMENT A; UPDATE STATEMENT B; UPDATE STATEMENT C; END// When I run them thr...

2 answers  ·  posted 3y ago by Charlie Brumbaugh‭  ·  last activity 3y ago by Alexei‭

71%
+3 −0
How do I configure Jenkins to strip the leading “origin/” in git branch parameter?

I'm using Jenkins with a branch parameter to specify the branch to build from. Other stuff downstream needs the branch name to not have the leading "origin/" -- just "feature/blahblah" or "bugfix/1...

1 answer  ·  posted 3y ago by Monica Cellio‭  ·  last activity 3y ago by Monica Cellio‭

75%
+4 −0
dig -6 works but dig -4 does not

I can't get a response from IPv4 dig on my server but I can get one from IPv6 dig. See the below output: $ dig +short myip.opendns.com a @resolver1.opendns.com # Doesn't return anything, this used ...

1 answer  ·  posted 3y ago by cobertos‭  ·  last activity 3y ago by Canina‭

75%
+4 −0
Is there an equivalent way of returning early in a MySQL stored procedure?

In programming instead of arrowcode where one has many layers of indented if statements, you can return a result as soon as possible. So instead of, if if end if end if It looks like if ret...

1 answer  ·  posted 3y ago by Charlie Brumbaugh‭  ·  edited 3y ago by Moshi‭

71%
+3 −0
How to manage views and stored procedures in an ASP.NET Core project?

I am slowly modernizing an older ASP.NET Core Web API and one of the steps involved migrating from database first to code first. Now, all schema changes and seeding is covered by migrations which ...

0 answers  ·  posted 3y ago by Alexei‭

50%
+2 −2
What is REST and how different it is from HTTP? [closed]

Based on my understanding HTTP is something client and server speak in, I mean it is like a language for a server and client to communicate(not exactly a programming language). Then how to understa...

0 answers  ·  posted 3y ago by aditya98‭  ·  closed 3y ago by Alexei‭

50%
+1 −1
What solutions available for a CMS-agnostic contact form?

By principle, I normally work with two different companies for establishing websites for myself: One for domain registration and domain-sole email address One for web application hosting My ...

2 answers  ·  posted 3y ago by deleted user  ·  last activity 2y ago by Alexei‭

77%
+5 −0
Is it worth using the Java Platform Module System in application code?

Is it worth using the Java Platform Module System introduced in Java 9 to structure application code? Given that the Java Platform Module System introduced in Java 9 doesn't manage dependency vers...

1 answer  ·  posted 3y ago by meriton‭  ·  edited 11mo ago by __blackjack__‭

80%
+6 −0
How to read lines into an array in Bash

I wish to fill an array with strings, using Bash scripting. The strings are in a file, one per line. Here is what I've tried: declare -a my_array=() while read line; do my_array+=( "$line"...

3 answers  ·  posted 3y ago by LVx0‭  ·  edited 2y ago by Alexei‭

85%
+10 −0
Scheme for cross-platform warning control?

tl;dr I'd like to learn a compact, cross-compiler way of selectively suppressing compiler warnings. Consider the case where you really mean to make an exact floating-point comparison using ==, o...

1 answer  ·  posted 3y ago by dmckee‭  ·  last activity 3y ago by Someone‭

66%
+2 −0
Save migration info in separate DB schema

When creating a code-first solution in dot net core using Visual Studio, you manipulate the database by changing model classes and migrating the changes. I can set the schema for tables that I cre...

1 answer  ·  posted 3y ago by mcalex‭  ·  last activity 3y ago by Alexei‭

70%
+5 −1
What do the number entries mean in the sympy poly.diff(...) tuple syntax?

I am looking to take a partial derivative of a sympy polynomial with respect to a symbol in the polynomial. In the sympy documentation for poly.diff(...) it gives sample code like this: from sympy ...

2 answers  ·  posted 3y ago by jrh‭  ·  last activity 3y ago by Derek Elkins‭

66%
+2 −0
How do I configure log4net from an arbitrary data structure?

I'm used to working in Python, but my current project is in C#/.NET and uses log4net for logging. Out of the box, log4net uses an XML file for configuration. I dislike XML and want to use something...

1 answer  ·  posted 3y ago by ajv‭  ·  last activity 3y ago by Peter Taylor‭

60%
+1 −0
How to use LazyCache library with Unity Container?

I want to use LazyCache and UnityContainer together in an ASP.NET classic application (.NET framework 4.6.1+). Namely, to be able to inject IAppCache in various services. For ASP.NET Core and its d...

1 answer  ·  posted 3y ago by Alexei‭  ·  last activity 3y ago by Alexei‭

83%
+8 −0
Is there a way to estimate the execution time of a statement in MySQL?

From time to time I will have large structural changes to make on my MySQL DB, things like adding columns, changing datatypes, adding indexes etc. These types of changes result in downtime and what...

1 answer  ·  posted 3y ago by Charlie Brumbaugh‭  ·  last activity 3y ago by meriton‭

66%
+2 −0
Search paths where all nodes are in a relationship with same node

Using the below graph as an example: I am trying to determine all Persons which are_sons of Persons all born in the same country. Is there an elegant way to achieve this with Cypher?

1 answer  ·  posted 3y ago by Guilherme Costa‭  ·  last activity 3y ago by r~~‭

50%
+1 −1
Running remote scripts (cloud scripts) locally --- valid and securely as possible

I use CentOS with Bash and I would like to download, execute and delete the executed downloaded file (running a remote/cloud script locally). I often prefer to load my own shell scripts from my ow...

1 answer  ·  posted 3y ago by deleted user  ·  last activity 3y ago by Peter Taylor‭

44%
+2 −3
What is the latest, efficient way to create a login page in JAVA?

I am a noob Java programmer. I want to create a simple login page with just username and password. So I have to combine Java and HTML. While googling I found that Servlets do the job but people are...

1 answer  ·  posted 3y ago by aditya98‭  ·  last activity 3y ago by meriton‭

77%
+12 −2
What gets allocated on the stack and the heap?

I was told by my professor/book that computer programs use two kinds of memory and that all variables get allocated either on the stack or on the heap. Is this true? How can I tell where a variable...

2 answers  ·  posted 3y ago by Lundin‭  ·  edited 3y ago by Alexei‭

83%
+8 −0
How do I find the order that yields the shortest path?

The Problem I have a path optimization problem that in some ways reminds me of the Traveling Salesman Problem, but differs in some key respects. I have a group of items that need to be used by a m...

1 answer  ·  posted 3y ago by matthewb‭  ·  edited 3y ago by matthewb‭

71%
+3 −0
In MySQL is there a limit to the number of keys in a IN() clause?

I have a PHP program that does a SELECT and then updates some of the values based on an algorithm. Rather than updating one row at a time UPDATE example_table SET COLUMN_A = 1 WHERE primary_k...

2 answers  ·  posted 3y ago by Charlie Brumbaugh‭  ·  last activity 3y ago by Alexei‭

50%
+2 −2
Having trouble adding include directories

I'm trying to set up a simple test project, to unit test a change I'm working on. The change is to a file inside some existing project. I've tried to set up the includes as the original has it, but...

1 answer  ·  posted 3y ago by Hyperlynx‭  ·  last activity 3y ago by Hyperlynx‭

86%
+11 −0
Can regex be used to check if input conforms to a very strict subset of HTML?

Tldr; I don't need to parse HTML, but I need to check if user submitted input conforms to a very strict subset of HTML. Can regex be a suitable tool for this? Details I have a frontend sanitiser th...

4 answers  ·  posted 3y ago by jla‭  ·  last activity 3y ago by Stephen C‭

60%
+1 −0
What should healthcheck of an Web API application actually check?

I have to add health checks to a rather new application (Web API, not a microservice) and I and a colleague are not agreeing about what other systems I should include in the check. This application...

1 answer  ·  posted 3y ago by Alexei‭  ·  edited 3y ago by Alexei‭

50%
+0 −0
How to drop all stored procedures from a MySQL database

I need to drop all of the stored procedures from my MySQL database before I recreate them. How can I do so?

1 answer  ·  posted 3y ago by Charlie Brumbaugh‭  ·  edited 3y ago by Peter Mortensen‭

60%
+1 −0
Is it necessary for a build server to remove node_modules before an AOT build?

I am currently dealing with an Angular application that is being deployed using an CI orchestrator and Jenkins. Jenkins job is configured to do the following (relevant steps only): fetch source...

2 answers  ·  posted 3y ago by Alexei‭  ·  last activity 3y ago by Derek Elkins‭

50%
+0 −0
TRUE/FALSE flags for alternating colouring by group

For use in connection with conditional formatting with alternating coloured fills in OpenOffice Calc, several years ago a user of Super User was applying this Ruby script: f = File.readlines("sha...

0 answers  ·  posted 3y ago by pnuts‭  ·  last activity 3y ago by pnuts‭

75%
+4 −0
What is a standard definition (or a CS theory based formal definition) for Escaping?

I personally would define "escaping" in software development in general and coding in particular as follows: Making an exception to match data which otherwise would not be allowed to be matched: I...

1 answer  ·  posted 3y ago by deleted user  ·  edited 3y ago by Alexei‭