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)
50%
+0 −0
Eclipse Custom Errors for Annotation Processing

In Eclipse, is it possible to setup custom errors or markers in the editor, for annotation processing? For example, the standard squiggly lines with descriptions. This question is not important. ...

0 answers  ·  posted 16d ago by tylerbakeman‭

71%
+3 −0
What is a reasonable minimum for making a FOSS project inviting to contributors?

A lot of people who maintain FOSS projects would like to get more contributions. What can the maintainer do to ensure that potential contributors are converted into actual contributors? There are...

2 answers  ·  posted 1mo ago by matthewsnyder‭  ·  last activity 1mo ago by Michael‭

50%
+0 −0
How to test if chrome dev tools are open in JavaScript?

Some web sites are able to detect that Developer Tools is open as output a message in a the console. How does JavaScript know that the Chrome DevTools are open? Could this be spoofed?

0 answers  ·  posted 19d ago by kreijstal‭  ·  edited 18d ago by Alexei‭

71%
+3 −0
Privilege escalation from Python like from systemd

When you try to do a privileged systemd operation without the privilege, you get an escalation prompt: $ systemctl stop docker ==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-units ==== ...

1 answer  ·  posted 15d ago by matthewsnyder‭  ·  last activity 15d ago by Karl Knechtel‭

66%
+2 −0
When to use custom iterators versus pointers

I am working on a toy project where I have a container for which I would like to write an iterator that iterates over the values in the container. Because the values are stored in a (c-style) arra...

0 answers  ·  posted 7d ago by mr Tsjolder‭

60%
+1 −0
Adding dependency with cabal in gitlab-ci

I have a project I normally build with nix and cabal, however I also want to publish my documentation onto gitlab pages. It's impractical to run my nix on the gitlab CI, so I've just been using cab...

0 answers  ·  posted 13d ago by WheatWizard‭

60%
+1 −0
MongoDB Java Morphia case insensitive criteria query?

So I googled some on how to make a case insensitive criteria query but could not find the solution very easily. So I basically have code that looks like this: ... query.criteria("fieldName").con...

1 answer  ·  posted 3mo ago by propatience‭  ·  edited 3mo ago by propatience‭

85%
+10 −0
Are "strong passwords" at all meaningful?

Whenever registering to diverse sites on the net, you are often forced to enter a so called "strong password", which would ideally contain both upper case letters, lower case letters, digits, and s...

4 answers  ·  posted 4mo ago by Lundin‭  ·  last activity 2d ago by Alexei‭

50%
+0 −0
Why does `let map f = id >=> switch f` work in F#?

Asked How to implement map using the fish (>=>, Kleisli composition) operator in F#? a couple of hours ago, and r~~'s answer blew my mind: let map f = id >=> switch f It is perfect ...

1 answer  ·  posted 23d ago by toraritte‭  ·  edited 15d ago by Alexei‭

66%
+2 −0
Images won't fit flex container on chrome

I browse deviantArt from time to time and I wanted to make images display bigger, because there is so much useless whitespace on that site. On first glance that would be simple - remove the set di...

1 answer  ·  posted 16d ago by martixy‭  ·  last activity 15d ago by martixy‭

66%
+2 −0
Filter stashes by pathspec

The documentation for git stash list says list [<log-options>] List the stash entries that you currently have. Each stash entry is listed with its name (e.g. stash@{0} is the latest entry...

0 answers  ·  posted 27d ago by Michael‭  ·  edited 26d ago by Alexei‭

77%
+5 −0
Why does this work? .collect() automatic conversion to function return type

I'm completing the rustlings exercises as part of self-teaching Rust. While working on the third iterators exercise, I solved the exercise but don't quite understand why my solution works. Specifi...

1 answer  ·  posted 2mo ago by qohelet‭  ·  last activity 2mo ago by Iizuki‭

50%
+0 −0
ChromeOS Linux: Debian, how do I install Android SDK manager via command line?

ChromeOS Linux: Debian, how do I install Android SDK manager via command line? I wanted to try this repo https://github.com/JetBrains/compose-multiplatform/tree/master/examples/imageviewer and I g...

1 answer  ·  posted 1mo ago by propatience‭  ·  last activity 1mo ago by propatience‭

75%
+4 −0
Why does bash seem to parse `sh -c` commands differently when called via `execl`?

When I do this in a shell: $ /bin/sh -c 'echo hello world' hello world it's my understanding that I'm running a process with argv = {"/bin/sh", "-c", "echo hello world"}. That is, the quotes c...

1 answer  ·  posted 2mo ago by Emily‭  ·  last activity 2mo ago by Emily‭

22%
+0 −5
How to Select From Multiple images to display main product image? [closed]

Below are the links to code for my project. HTML CSS JavaScript I have created Magnifying Image which was successful now I am trying to add multiple images which can be display in main produc...

0 answers  ·  posted 3mo ago by abhishek27suvarna‭  ·  edited 22d ago by CPlus‭

66%
+2 −0
Method not found when emitting a custom signal, but the game seems to work when played.

In Godot 4.1.1 I moved some scenes and started getting parenting errors. I think I got that fixed, but I'm mentioning it in case it is important. I have an Area2d called House. house.gd has two c...

1 answer  ·  posted 5mo ago by TecBrat‭  ·  last activity 5mo ago by TecBrat‭

66%
+2 −0
How can I get a value as a node:stream from the Nest.js cache-manager?

Question How can I read data from a NestJS Redis Cache as a stream? I'm using Nest.js and its @nestjs/cache-manager (using the Redis implementation), I need to read data I have stored in the cach...

0 answers  ·  posted 6mo ago by gdfelt‭  ·  edited 6mo ago by MrDevel0per‭

66%
+2 −0
VS code - stop reopening old tabs

When I open VS Code inside a project dir, it reopens all the tabs that were open last time, and re-expands all the folders that were unfolded last time. I find this annoying. Usually, when I close...

0 answers  ·  posted 19d ago by matthewsnyder‭

25%
+0 −4
Having problems with my php script [closed]

The exam checking for the backend is working perfectly well but the front end keeps saying an error occurred. Am like ok then tried the demo version replaced the javascript and everything i can rep...

0 answers  ·  posted 4mo ago by zick853‭  ·  closed 4mo ago by Mithical‭

57%
+2 −1
How to write a bash function to sanitize filenames for Linux and Windows

I'm trying to write a bash function that can sanitize filenames to make them compatible with both Linux and Windows file systems. The function should perform the following operations: Replace in...

0 answers  ·  posted 18d ago by ShadowsRanger‭

66%
+4 −1
Does Python have a "ternary operator" (conditional evaluation operator like "?:" in other languages)?

Sometimes code needs to assign (or otherwise use) a value that depends on some condition. The naive approach is to use explicit branching, which in Python would look like: if some_condition(): ...

2 answers  ·  posted 5mo ago by Karl Knechtel‭  ·  last activity 5mo ago by matthewsnyder‭

57%
+2 −1
What is the difference between hashing and encryption?

According to this article: Since encryption is two-way, the data can be decrypted so it is readable again. Hashing, on the other hand, is one-way, meaning the plaintext is scrambled into a uniqu...

3 answers  ·  posted 2mo ago by Julius H.‭  ·  last activity 2mo ago by matthewsnyder‭

75%
+4 −0
How to troubleshoot ModuleNotFoundError?

I ran some Python code and it crashed with ModuleNotFoundError. What is the general approach for dealing with these situations?

2 answers  ·  posted 4mo ago by matthewsnyder‭  ·  last activity 3mo ago by Karl Knechtel‭

71%
+3 −0
Using an existing web server vs writing your own

When writing a dynamic web service, you broadly speaking have two paths: Use an existing web server (e.g. Apache, Nginx or Lighttpd) to handle the "raw" web requests and implement your own cod...

4 answers  ·  posted 6mo ago by Iizuki‭  ·  last activity 6mo ago by Basile Starynkevitch‭

60%
+1 −0
What is the difference between `static let` and `static member` in F#?

Taking the example from this Stackoverflow question: type Vector2D(dx : float, dy : float) = static let zero = Vector2D(0.0, 0.0) static let onex = Vector2D(1.0, 0.0) static let ...

1 answer  ·  posted 4mo ago by toraritte‭  ·  last activity 4mo ago by toraritte‭

f#
60%
+1 −0
Drop-down values in Excel cells are not specified in Data Validation rules and global search didn't find them in workbook, so where do they come from?

On top of values seemingly coming from nowhere in multiple columns, they also affect each other's behavior: In the GIF below, if the cells in the left column have no value selected, then there is n...

1 answer  ·  posted 5mo ago by toraritte‭  ·  edited 5mo ago by toraritte‭

71%
+3 −0
How do I pass field names containing dashes in dbt source yml file?

Working with dbt version 2 I'm trying to set up source checks but I'm running into an issue where the column names I'm setting tests for have dashes (e.g. my_table.some-field-with-dash). I current...

1 answer  ·  posted 7mo ago by Sigma‭  ·  last activity 7mo ago by Sigma‭

36%
+2 −5
What makes people able but unwilling to contribute to FOSS projects? [closed]

Suppose someone has the requisite knowledge and skillset to contribute to a FOSS project, they have the free time to do so and they are aware of the project. Yet, they decide not to contribute. Thi...

0 answers  ·  posted 1mo ago by matthewsnyder‭  ·  closed 1mo ago by Alexei‭

62%
+3 −1
What happens when you “Sign in with Google”?

I believe when you sign in with Google, the web application running in your browser calls a command to request the Google Sign In page, and includes a “callback URL” as a parameter in that HTTP req...

0 answers  ·  posted 2mo ago by Julius H.‭  ·  edited 2mo ago by Julius H.‭

50%
+0 −0
Why is inter-VLAN communication not working in my bus topology network set-up in Cisco Packet Tracer?

I have created a simple bus topology connecting 2 switches and a router, with each switch connected to their respective end devices through ordinary star topology. The switch model used was 3560-24...

0 answers  ·  posted 3mo ago by Phoenix‭  ·  edited 3mo ago by Alexei‭

77%
+5 −0
Can GitHub rewrite authorship of commits?

GitHub has a setting wherein they offer to "anonymize" your user email from, say, somebody@example.com to somebody@users.noreply.github.com. I presume this is to prevent you from getting spam from ...

1 answer  ·  posted 5mo ago by Michael‭  ·  edited 5mo ago by matthewsnyder‭

80%
+6 −0
Can I access an array element from a pointer to an object contiguous with but outside the array?

C prohibits accessing an array out of bounds even if measures were taken to ensure that what should lie outside those bounds were known: struct MyStruct { int x[2]; int y, z; }; static...

1 answer  ·  posted 23d ago by CPlus‭  ·  last activity 20d ago by Lundin‭

80%
+6 −0
How to compare a git stash to the current working tree?

In git you can put your current changes aside for a moment with git stash. This is really neat but what often ends up happening is that you forget what was in there, and what was the state of the b...

1 answer  ·  posted 6mo ago by Iizuki‭  ·  edited 6mo ago by Iizuki‭

66%
+2 −0
Is it okay to use python operators for tensorflow tensors?

TL;DR Is (a and b) equivalent to tf.logical_and(a, b) in terms of optimization and performance? (a and b are tensorflow tensors) Details I use Python with Tensorflow. My priorities are Make t...

1 answer  ·  posted 8mo ago by daniel_s‭  ·  edited 8mo ago by meta user‭

75%
+4 −0
Why does `Zip` require `Semialign`

The Zip class from Data.Zip requires an implementation of Semialign: class Semialign f => Zip f In my mind: Zip takes the intersection of two shapes. Semialign takes the union of two sha...

1 answer  ·  posted 2mo ago by WheatWizard‭  ·  last activity 2mo ago by r~~‭

66%
+2 −0
How to "materialize" Ionide function signature type hints as comments?

For example, given this function head, this is the hint that is generated: let updateCell workbook sheetIndex rowIndex columnIndex value = // XSSFWorkbook -> int -> int -> int -> stri...

0 answers  ·  posted 5mo ago by toraritte‭

40%
+0 −1
Addressing W25Q64 flash IC [closed]

I am using a W25Q64 flash ic to store some stuff for an ESP-32 project. I used this library from Github as it seems intended for ESP. It seemed weird that the read function uses two 16-bit paramet...

0 answers  ·  posted 20h ago by HinkyDinky‭  ·  closed 6h ago by Lundin‭

42%
+1 −2
Listen for key events in a CLI app

I have a Python program like this: done = False while u and not done: i = u.pop() print(f"Processing {i}") do_big_task(i) finish_up() Since this takes a long time, the user m...

1 answer  ·  posted 8mo ago by matthewsnyder‭  ·  last activity 8mo ago by mr Tsjolder‭

60%
+1 −0
How to validate Ansible role dictionary argument's "additionalProperties"

In JSON Schema one can use the additionalProperties key to validate properties whose names are not know. You can still impose restrictions on their type. How to do this in an Ansible role argument...

1 answer  ·  posted 7mo ago by Iizuki‭  ·  edited 7mo ago by Iizuki‭

50%
+0 −0
Why does `distutils` seem to be missing or broken? Isn't it part of the standard library?

Sometimes when I try to install a third-party library for Python, I get an error saying that either distutils, or some part of it like distutils.core or distutils.util, could not be found. It's sho...

1 answer  ·  posted 21h ago by Karl Knechtel‭  ·  last activity 20h ago by Karl Knechtel‭

60%
+1 −0
How to put text next to my ImageIcon on a cell in a JTable

I have an application that works with a JTable, and in this JTable, I want each cell to have both an ImageIcon and some text. I see at this link, JTable supports ImageIcon OR text, but seemingly n...

1 answer  ·  posted 8mo ago by davidalayachew‭  ·  edited 8mo ago by Alexei‭

50%
+1 −1
How to resolve a "ValueError: dimension 't' already exists as a scalar variable" arising when I am using xarray.Dataset.assign_coords()?

I have the following xarray Dataset: d: <xarray.Dataset> Dimensions: (x: 79, y: 63, t: 1) Coordinates: * x (x) float64 0.9412 1.882 2.824 3.765 ... 71.53 72.47 73.41 74.35 * ...

1 answer  ·  posted 8mo ago by Ivan Nepomnyashchikh‭  ·  last activity 8mo ago by mr Tsjolder‭

75%
+4 −0
Set transform of SVG element

I'm trying to set the transform attribute of a group within an SVG. Specifically, I'd like to set translate's value to 0 0. I tried using the set element for this but that didn't have an observab...

1 answer  ·  posted 7mo ago by Matthias Braun‭  ·  edited 7mo ago by Matthias Braun‭

svg
77%
+5 −0
Terms for types of functions with respect to side effects

Mathematically, the purpose of a function is to return an output. However, in a programming context functions often have side effects. It is even common to call functions for the side effects alone...

2 answers  ·  posted 9mo ago by matthewsnyder‭  ·  last activity 9mo ago by Lundin‭

75%
+4 −0
How can one import two classes with the same name in Java8?

Some development tools provide an error message when a user tries to import two things (classes, packages) with the same name. Some programming languages offer a syntax to import one of those thing...

2 answers  ·  posted 3mo ago by tarhalda‭  ·  last activity 15d ago by Michael‭

50%
+1 −1
Is there a text version of pickle?

Is there a Python serialization format that has capabilities similar to Pickle, but is text based? The problem I always have with pickle is that it's binary, so I can't manually view or edit the d...

0 answers  ·  posted 7mo ago by matthewsnyder‭

86%
+11 −0
Alternatives to `EXPLAIN ANALYZE` for queries that won't complete

I have a large and complex PostgreSQL SELECT query that I would like to make faster. EXPLAIN suggests it should run quickly, with the worst parts being scans of a few thousand rows. When run, it do...

2 answers  ·  posted 7mo ago by Emily‭  ·  last activity 7mo ago by matthewsnyder‭

75%
+4 −0
How do I share a type between a client and server, but make a specific field optional for one and required for the other?

Let's say I have a client/server application with a data structure on the server side: type User = { name: string; superSecretGovernmentIdNumber: string; }; These fields are both non-nul...

1 answer  ·  posted 6mo ago by Emily‭  ·  edited 6mo ago by Emily‭

71%
+3 −0
How to open VS code with a particular path expanded?

When you do: cd /some/path code . VS Code opens with that location shown in the "Explorer" sidebar. However, the state of the file tree and the currently open files will be the same as what wa...

0 answers  ·  posted 7mo ago by matthewsnyder‭  ·  edited 7mo ago by matthewsnyder‭

66%
+2 −0
PHP - Why using "global" considered bad?

In PHP why is using global like in the example below considered bad? $a = 1; class foo { public function bar() { global $a; // <-- Why is this considered bad? } } ...

1 answer  ·  posted 29d ago by Vanity Slug ❤️‭  ·  last activity 29d ago by matthewsnyder‭