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)
83%
+8 −0
Setting custom HTTP status code messages in nginx

I think it would be funny if my web application that is hosted using an nginx reverse proxy (proxy_pass) returned something like 200 Could Be Worse rather than 200 OK, when the page load was succes...

1 answer  ·  posted 1y ago by luap42‭  ·  last activity 1y ago by Ancepaid‭

http nginx
71%
+3 −0
How to find the last line number of a section in a text file (particular format)

I'm writing a function which reads specified sections in a text file formatted a particular way, but I'm having a hard time figuring out how to locate the last line number. Here's an example of the...

1 answer  ·  posted 1y ago by pycoder‭  ·  edited 1y ago by hkotsubo‭

python python-3
66%
+2 −0
How is Temporal.PlainDate.from() constructed?

Continuing from What is the advantage of creating instances from a method rather than constructor?, I want to construct a method that create a new instance of a class without using the constructor....

0 answers  ·  posted 1y ago by Ooker‭  ·  edited 1y ago by ArtOfCode‭

javascript constructor class
42%
+1 −2
How can I autocomplete variable names in prompts in Cursor?

E.g., I have a variable name options. Then I write a prompt. How can I autocomplete the variable name in prompt in Cursor? (i.e., instead of typing options, I want to only type o then it'll autocom...

1 answer  ·  posted 1y ago by Franck Dernoncourt‭  ·  edited 1y ago by ArtOfCode‭

cursor-ai
50%
+0 −0
How can I automatically delete any deployment of a fine-tuned OpenAI model on Azure that hasn't been used in the past x hours? [duplicate]

How can I automatically delete any deployment of a fine-tuned OpenAI model on Azure that hasn't been used in the past x hours? I am aware of 15-day timeout. However, this is too long for me, as th...

0 answers  ·  posted 1y ago by Franck Dernoncourt‭  ·  closed as duplicate 1y ago by ArtOfCode‭

azure azure-cognitive-services
50%
+0 −0
How can I automatically delete any deployment of a fine-tuned OpenAI model on Azure that hasn't been used in the past x hours?

How can I automatically delete any deployment of a fine-tuned OpenAI model on Azure that hasn't been used in the past x hours? I am aware of 15-day timeout. However, this is too long for me, as th...

0 answers  ·  posted 1y ago by Franck Dernoncourt‭

azure azure-cognitive-services
50%
+0 −0
Why doesn't my Azure OpenAI model show up in Cursor?

I added my Azure OpenAI account show up in Cursor in the settings: But I don't see the Azure OpenAI model as one of the available models: Why doesn't my Azure OpenAI model show up in Cursor? ...

0 answers  ·  posted 1y ago by Franck Dernoncourt‭  ·  edited 1y ago by Franck Dernoncourt‭

cursor-ai
66%
+2 −0
What is the advantage of creating instances from a method rather than constructor?

Take the newly Temporal.PlainDate class as an example. New instances can be created via the constructor: new Temporal.PlainDate(year, month, day) new Temporal.PlainDate(year, month, day, calendar...

1 answer  ·  posted 1y ago by Ooker‭  ·  last activity 1y ago by Derek Elkins‭

javascript class
66%
+2 −0
Understanding "subprocess-exited-with-error" from Pip

This question is about the general case of subprocess-exited-with-error. It's intended to help you understand the situation if you get an error like this, and there are some common workarounds - ...

1 answer  ·  posted 1y ago by Karl Knechtel‭  ·  last activity 1y ago by Karl Knechtel‭

python pip
50%
+0 −0
Property 'DurationFormat' does not exist on type 'typeof Intl'

I run this code with Deno from Temporal.PlainDate.prototype.since() - JavaScript | MDN: const date = Temporal.PlainDate.from("2022-12-25"); const now = Temporal.Now.plainDateISO(); const duratio...

0 answers  ·  posted 1y ago by Ooker‭

javascript typeof deno
40%
+0 −1
.NET for ERP development [closed]

I am wondering if .NET is used in ERP development, or if i decide between using .NET or another technology for ERP project.

0 answers  ·  posted 1y ago by bilalzulficar‭  ·  closed 1y ago by Alexei‭

.net .net-core
60%
+1 −0
Which model is Cursor IDE using when I specify a random model name?

Example: I specify a random model name some random name: Then I call it: Which model is Cursor IDE using when I specify a random model name? Cross-posted: https://stackoverflow.com/q/79...

0 answers  ·  posted 1y ago by Franck Dernoncourt‭  ·  edited 1y ago by Franck Dernoncourt‭

cursor-ai
66%
+2 −0
Does the Rate limit (Tokens per minute) of an Azure OpenAI instance corresponds to the input tokens, the output tokens or the sum of both?

Does the Rate limit (Tokens per minute) of an Azure OpenAI instance corresponds to the input tokens, the output tokens or the sum of both? Crossposted at: https://serverfault.com/q/1176440/...

1 answer  ·  posted 1y ago by Franck Dernoncourt‭  ·  edited 1y ago by Franck Dernoncourt‭

azure azure-cognitive-services
57%
+2 −1
How shall I refer to the documents and the context in the prompt when using the Azure RAG-QA framework?

I use Azure OpenAI RAG-QA (aka "bring our data"): which I call via e.g.: import os import pprint from openai import AzureOpenAI #from azure.identity import DefaultAzureCredential, get_bear...

0 answers  ·  posted 1y ago by Franck Dernoncourt‭  ·  edited 1y ago by Franck Dernoncourt‭

azure azure-cognitive-services
66%
+2 −0
Why does Azure Command-Line Interface (CLI) list no groups and no resources in my Azure account?

I have several resource groups and instances in my Azure account. Yet, the Azure Command-Line Interface (CLI) lists no groups and no resources in my Azure account: franck [ ~ ]$ az group list [] ...

1 answer  ·  posted 1y ago by Franck Dernoncourt‭  ·  edited 1y ago by Franck Dernoncourt‭

azure
66%
+2 −0
How can I resolve the 403 Forbidden error when deploying a fine-tuned GPT model in Azure via Python?

I follow Azure's tutorial on fine-tuning GPT. I'm stuck at the deployment phase. Code: # Deploy fine-tuned model import json import requests token = '[redacted]' subscription = '[redacted...

0 answers  ·  posted 1y ago by Franck Dernoncourt‭

python azure
71%
+3 −0
Advanced Regex extension for VS Code

VS Code supports regex search, but the search/replace UI is just a tiny dialog box. It's okay if you know regex well and the expression is not complex, but when trying to apply complicated expressi...

0 answers  ·  posted 3y ago by matthewsnyder‭  ·  edited 1y ago by trichoplax‭

regex software-recommendation vs-code ide
75%
+4 −0
Why force designation of a remote main branch?

GitHub seems to require that one of the branches on it be marked as the "primary" branch. I understand this (perhaps mistakenly) to be the origin/HEAD. Why would they make it compulsory? On forked...

2 answers  ·  posted 1y ago by Michael‭  ·  last activity 1y ago by InfiniteDissent‭

git github
75%
+4 −0
Get the name of the remote tracked branch of my local branch for use in script

Can I programmatically get the name of the remote branch which my local branch is tracking? I'm interested in scripting around git-range-diff(1), so that I could do something like this: [alias] ...

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

git
66%
+2 −0
List charts in a helm repository

How to list all available helm charts in a helm repository, preferrably using the native helm CLI tool? This command lists the repos themselves, but I've yet to discover how to list their contents...

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

helm
77%
+5 −0
Casting a non-void pointer to uintptr_t

I came across the following code snippet on the SEI CERT C Coding Standard wiki: Compliant Solution Any valid pointer to void can be converted to intptr_t or uintptr_t and back with no change i...

1 answer  ·  posted 1y ago by mm1‭  ·  last activity 1y ago by Lundin‭

c pointers
81%
+7 −0
2D-array pointer as a struct member

I have an array of struct: static struct basket baskets[MAX_ITEMLEN + 1]; struct basket { char *items; // malloc(itemlen * itemcount) int itemcount; }; char *items does all I nee...

3 answers  ·  posted 1y ago by wasIzy‭  ·  last activity 1y ago by wasIzy‭

c array
77%
+5 −0
What are X macros and when to use them?

Occasionally I run into some strange pre-processor code with a list like this: #define LIST \ X(1) \ X(2) \ X(3) \ And then code followed by other obscure macros and ...

1 answer  ·  posted 1y ago by Lundin‭  ·  last activity 1y ago by Lundin‭

c x-macros preprocessor
71%
+3 −0
Keep failed CronJob Pods around in Kubernetes

It seems like pods created by a Kubernetes CronJob (or rather Job) are deleted as soon as they fail. This makes it difficult to figure out what went wrong (unless you have Prometheus or some other ...

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

kubernetes cronjob kubernetes-pod
75%
+4 −0
How to disable debug windows automatically opening up when I hit a breakpoint in vscode?

In vscode, when I hit a breakpoint it automatically opens "Run and Debug" window. I don't want that because I am using a small screen (and that sidebar takes up space) and I don't always need to us...

1 answer  ·  posted 1y ago by Vanity Slug ❤️‭  ·  last activity 1y ago by Alexei‭

debugging vs-code
70%
+5 −1
How to disable jobs in GitLab CI after they are successfully executed

I'm working with GitLab CI. The pipelines I'm designing contain several jobs that, once executed successfully, there shouldn't be any reason to retry/rerun them. This is an example: default: # ...

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

gitlab-ci
75%
+4 −0
Iterating over pixels in QImage (Qt): which method adapts better for any image size?

I asked this in SE years ago. I'm aware of two methods in order to access all the pixels in a QImage called img. Method 1 for (int y = 0; y < img.height(); y++) { QRgb *line = (QRgb *)...

1 answer  ·  posted 1y ago by aura-lsprog-86‭  ·  last activity 1y ago by Alexei‭

c++ qt qimage pixel-manipulation
50%
+0 −0
Proguard induced : No enum constants for class while deserializing using jackson

I'm getting the following exception with deserializing a json file using jackson. Any tips on how to fix it? com.fasterxml.jackson.databind.JsonMappingException: No enum constants for class com.dp...

1 answer  ·  posted 1y ago by Abbas Gadhia‭  ·  edited 1y ago by Abbas Gadhia‭

jackson proguard
62%
+3 −1
Call custom Lua function in Vimscript function

In init.vim, I have a Vimscript function that calls a Lua function and returns its value: function! CallLuaFunction() return luaeval("require('functions').say_hello()") endfunction The Lua ...

1 answer  ·  posted 1y ago by Matthias Braun‭  ·  last activity 1y ago by Matthias Braun‭

lua Neovim
60%
+1 −0
Why is a for loop getting stuck when using a uint64_t counter, whereas a while loop isn't?

I asked this question a while ago over SE. When I use a for loop with a uint64_t as a counter, it gets stuck forever, even though the condition seems to be well defined. Offending MCVE #includ...

3 answers  ·  posted 1y ago by aura-lsprog-86‭  ·  last activity 1y ago by Lundin‭

c integer loops
60%
+1 −0
How to correctly model the delay timer for a CHIP8 emulator written in C?

I asked this question in SE a while back. TL;DR I need to emulate a timer in C that allows concurrent writes and reads, whilst preserving constant decrements at 60 Hz (not exactly, but approxima...

1 answer  ·  posted 1y ago by aura-lsprog-86‭  ·  last activity 1y ago by aura-lsprog-86‭

c linux multithreading emulation chip-8
81%
+7 −0
Are email addresses case-sensitive?

Does the case of an email address make a difference? I.e. would sending emails to these addresses all lead to the same inbox? [email protected], [email protected], [email protected], Account...

1 answer  ·  posted 1y ago by Iizuki‭  ·  last activity 1y ago by Olin Lathrop‭

email
71%
+3 −0
Line-drawing algorithm prints nonsensical intermediate Y values. Where is the problem?

This question was originally asked in SE. I have a program that draws lines using line drawing algorithms. I use gcc 5.2.1 on Xubuntu 15.10 to compile it. Executing it throws a "Segment violati...

1 answer  ·  posted 1y ago by aura-lsprog-86‭  ·  last activity 1y ago by aura-lsprog-86‭

c casting struct graphics
71%
+3 −0
Get global gitconfig path

Is there a command I can run to get the path of global gitconfig for a user? Like git config --global --edit, but I want the path, not an editor window. I want the right path whether or not this f...

2 answers  ·  posted 1y ago by Michael‭  ·  last activity 1y ago by InfiniteDissent‭

git
60%
+1 −0
Scanner fails when executing Java with admin rights (sudo) in Eclipse in Linux

(Brought over from SE.) The problem I have followed this procedure in order to run Java applications as root when needed from Eclipse (as I use Xubuntu, for instance, when using jnetpcap to cap...

1 answer  ·  posted 1y ago by aura-lsprog-86‭  ·  edited 1y ago by aura-lsprog-86‭

java linux Eclipse sudo jnetpcap
60%
+1 −0
Android CameraPreview not rendering for MLKit barcode analyis on MAUI custom control

I have a QR code which needs to read through Google's ML kit for Android since Zxing.MAUI doesnt read it. I followed the code in ml-kit/vision/barcode-scanning/android and VinayByte/mlkit-qr-code-s...

1 answer  ·  posted 1y ago by carpeltunnel‭  ·  last activity 1y ago by carpeltunnel‭

c# android mobile .net-maui
60%
+1 −0
How can I set a private class instance variable to the File object used by an unmarshaller?

(Brought over from SE) The problem I'm coding a Java Swing application dealing with XML files, so I'm using JAXB in order to marshal classes into documents and unmarshal the other way around. ...

1 answer  ·  posted 1y ago by aura-lsprog-86‭  ·  last activity 1y ago by aura-lsprog-86‭

java event-handling callback jaxb
60%
+1 −0
How to do function composition in Spring Cloud Stream when using classes

I'm working on a proof of concept for a Spring Cloud Stream application. I want to define my processing logic using classes that implement Function, Consumer, or Supplier. I understand that Spring...

0 answers  ·  posted 1y ago by deleted user  ·  last activity 1y ago by Monica Cellio‭

spring-boot spring-cloud spring-cloud-stream
66%
+2 −0
How to Proxy 3x-UI Panel to a Specific Path on Nginx Web Server with Asset Path Rewriting?

I have two vps: First one is used for vpn/proxy. It runs 3x-ui that, simply saying, allows to create and manage vpn/proxy with UI. VPS' ip is connected to https://new-york.vpn.utils.example.co...

0 answers  ·  posted 1y ago by Botopodobniy‭

path-mapping nginx 3x-ui cloudflare
30%
+1 −5
How this recursive treewalker works?

Credit for User:Meriton for developing the following code (first published here). function replaceIn(e) { if (e.nodeType == Node.TEXT_NODE) { e.nodeValue = e.nodeValue.replaceAll("a", "");...

3 answers  ·  posted 4y ago by deleted user  ·  last activity 1y ago by hkotsubo‭

javascript recursion tree tree-traversal
66%
+2 −0
Dynamically do something after a useState variable has been set?

Since setState is asynchronously executed, how to dynamically do something after a useState variable has been set? Consider import { useState } from "react"; const [myVar, setMyVar] = useState("...

2 answers  ·  posted 1y ago by propatience‭  ·  last activity 1y ago by bignose‭

reactjs
66%
+2 −0
Labels and annotations not merging for specific resources in overlays

I'm trying to implement bases and overlays for some Kubernetes configurations that I have, but I'm running into an issue where labels and annotations are not being applied correctly to some specifi...

0 answers  ·  posted 1y ago by deleted user

kubernetes kustomize
83%
+8 −0
After git fetch, how to fast forward my branch?

I did git fetch to quickly get latest commits. I did this instead of git pull so I could deal with merge conflicts offline. But my repository is still stuck on the old commit, and now git pull fail...

2 answers  ·  posted 2y ago by matthewsnyder‭  ·  last activity 1y ago by hkotsubo‭

git
77%
+5 −0
Why utilize an FQDN in the stead of a domain (and/or TLD), relative to the root domain?

Until recently, I'd yet to come across a situation in which I'd had any reason to qualify a DNS namespace further than its TLD. Then, I authored softwareengineering.stackexchange.com/revisions/456...

0 answers  ·  posted 1y ago by Mr. Beedell, Roke Julian Lockhart (RJLB)‭

dns
77%
+5 −0
How does the strict aliasing rule enable or prevent compiler optimizations?

Inspired by https://meta.stackoverflow.com/questions/432242, and the relevant main-space questions. I have heard that C and C++ something called the "strict aliasing rule", which means for exa...

2 answers  ·  posted 2y ago by Karl Knechtel‭  ·  last activity 1y ago by Lundin‭

c c++ undefined-behavior optimization strict-aliasing
66%
+2 −0
How do I get a hexadecimal string representation of a GdkRGBA struct in C?

I have a program that reads a hexadecimal string representation from a configuration file, turns it into a GdkRGBA struct from Gdk, uses gtk_color_dialog_button_set_rgba () to set it as the default...

1 answer  ·  posted 1y ago by Newbyte‭  ·  last activity 1y ago by Newbyte‭

c
71%
+3 −0
Why is spacy word vectors showing unexpected similar words?

Why is spacy word vectors showing unexpected similar words? Here is the code I am using: import spacy import numpy as np nlp=spacy.load('en_core_web_md') with open ('data/us.txt') as f: ...

0 answers  ·  posted 1y ago by Asia‭  ·  edited 1y ago by celtschk‭

python-3 spacy word-vectors
66%
+2 −0
Unable to configure enhanced route discovery in Apache Camel

I'm currently working with Apache Camel in a Quarkus application. I would like to configure the application to not discover any routes by default, and only include those defined in specific package...

0 answers  ·  posted 1y ago by deleted user  ·  edited 1y ago by Alexei‭

java quarkus apache-camel enterprise-integration-patterns
70%
+5 −1
Is it a bad idea to block proxies/vpns for interacting with my app?

I run a small website and Im considering blocking proxies and vpns with ipquery to cut back on spam. I keep having bots autofill the contact us even though im using recaptcha. Does anyone have any ...

2 answers  ·  posted 2y ago by jefforce‭  ·  last activity 1y ago by matthewsnyder‭

proxy vpn
77%
+5 −0
How to keep git blame ignored commits up to date?

When I make a separate commit for code cleanup / style changes, I can suppress that commit from git blame so that I can follow a file's history easily without getting distracted by pure style chang...

1 answer  ·  posted 2y ago by HeavyRain‭  ·  last activity 1y ago by Alexei‭

git