Random snippets of all sorts of code, mixed with a selection of help and advice.
Does V8 optimize curried functions like a typical functional programming language?
22 February 2026 @ 4:44 am
Functional programming languages like Haskell or OCaml go though some effort to make
curried functions have reasonable performance compared to uncurried functions. I am curious if V8 has any optimizations specially for curried functions.
Does V8 optimize direct calls?
Consider the example shown below. Here addFourCurry and addFourUncurry are
both called directly. Assuming that they're not inlined, do both of their calls generate the same or at least similar machine code? Does currying change whether either example is inlined?
What can I expect in general of directly calling curried functions?
const example = [1, 2, 3];
const addFourCurry = a => b => c => d => console.log(a + b + c + d);
const addFourUncurried = (a, b, c, d) => console.log(a + b + c + d);
for (let i = 0; i < example.length; i++) {
let e = example[i];
addFourCurry(e)(e)(e)(e);
}
for (let i
Is maintaining manual per-file and per-function change logs alongside Git considered a professional practice in 2026?
22 February 2026 @ 4:42 am
I’m working on a project where we already use modern version control practices:
Git with GitFlow branching
Pull requests with mandatory reviews
Conventional commit messages
CI-based checks
Despite this, our internal engineering guideline mandates manual change tracking inside source files, in addition to Git history.
I’d like feedback from experienced engineers on whether this approach is considered legitimate and professional in 2026, or if it is generally viewed as redundant in modern workflows.
Requirement 1: Mandatory File-Level Modification History
Every source file must contain a large comment block at the top that manually tracks changes, including author, date, version, and description.
Example (JavaScript)
/*
* @file utils.js
* @description Utility functions for .........
* @author Monjel Morsh
Why refreshing a single page application causes blank page when caching?
22 February 2026 @ 4:41 am
I'm building a web app using rust actix_web as backend and react with react-router as frontend.
I noticed that when I go to any route other than / then hit refresh the page turns blank.
Going to the Network tab in dev tools I noticed that the response if empty even though it should return index.html
I also noticed that hard refresh using Ctrl+R loads the page with no issues.
Here is my actix_web service that serves react frontend
.service(
Files::new("/", "./frontend")
.index_file("index.html")
.use_last_modified(true)
.prefer_utf8(true)
.default_handler(web::get().to(spa_handler))
and this is my spa_handler
I also noticed that hard refresh using Ctrl+R loads the page with no issues.
Here is my actix_web service that serves react frontend
.service(
Files::new("/", "./frontend")
.index_file("index.html")
.use_last_modified(true)
.prefer_utf8(true)
.default_handler(web::get().to(spa_handler))
and this is my spa_handler
How do you debug a small off-by-one runtime error in a big project?
22 February 2026 @ 4:32 am
I am currently making a blackjack simulator app, and my house edge is about 1%, when it is supposed to be 0.5%.
I have tested individual parts. I have gone through 100 hands to make sure they are all correct. Nothing seems to be wrong, yet my code still does not work.
My question is about my code, but also in general. How would you debug a small error in a big project, especially when it might depend on random numbers and such?
https://github.com/Iamlel/Blackjack-Analyst
Android Oauth2 redirect_uri_mismatch
22 February 2026 @ 4:15 am
I know this is a common problem and I have read many articles about how to resolve but I am afraid that I am still stuck.
I would be very grateful for any help on this.
I have spent 10 hours so far trying out various settings.
I am showing unredacted details in my personal google account - this account will not be used for production - please tell me if this is a personal risk to myself.
I am working in Android Studio Otter 3
I am using the demo app net.openid.appauthdemo that is provided with the https://github.com/openid/AppAuth-Android library
I have only changed :
build.gradle(app)
AndroidManifest.xml
auth_config.json
Many of the end point settings have been gleaned from a tutorial
https://aster.cloud/2022/01
Herramienta/aplicación/ modelo (openai, perplexity, gemini, Claude....)
22 February 2026 @ 4:04 am
¿Que aplicación de AI es la mejor herramienta para que se convierta en un tutor excepcional de programación desde las bases? ¿Cuáles son las fortalezas de cada una? ¿Que enseña mejor cada una en lo relacionado a programación, como lenguajes, frameworks...? ¿Cuál es la mejor forma y que ejemplos reales hay, para abordar la integración avanzada de tecnologías?
How should we handle centralize logging in Hexagonal Architecture? Should there be a logging service?
22 February 2026 @ 3:47 am
When it comes to logging in Rust many people will use a library like tracing. Most examples I found import tracing into their file in their program through use.
use tracing::{error, info, warn};
How should one handle logging under a Hexagonal (Port & Adapter) Architecture? From the hexagonal pattern standpoint, would it make sense to wrap tracing as a driven/outbound adapter and create a logging service?
---
In theory, doing that would help abstract the logging parts of the application with the benefits like separation of concerns and flexible integration. I would pass a reference of my logging service instead of sprinkling use tracing::{...} through out my program.
I experimented creating a logging service and use it to set up tracing configuration before anything starts being l
Is anyone attending the AI Summit London 2026?
22 February 2026 @ 3:36 am
I’m looking for someone who would be interested in sharing a hotel room so we can split the cost and make the stay much more affordable for both of us 🙂. If you’re planning to book accommodation around the same dates and are open to sharing, please let me know. Happy to discuss details!
The issue where the implemented PPO algorithm fails to train
22 February 2026 @ 3:31 am
I wrote a PPO-based reinforcement learning code for the Gymnasium CarRacing-v3 environment.
(The code was generated with the help of Gemini)
However, even after 200,000 frames, the training does not seem to improve.
<Result>
Frame: 40000 | Mean Reward: 0.07 | Loss: 3.1248
Frame: 80000 | Mean Reward: 0.04 | Loss: 7.0629
Frame: 120000 | Mean Reward: 0.06 | Loss: 3.9565
Frame: 160000 | Mean Reward: 0.07 | Loss: 5.4525
Frame: 200000 | Mean Reward: 0.03 | Loss: 3.8550
I would like to know if there are any issues or mistakes in the code below.
import gymnasium as gym
from collections import deque
from gymnasium.spaces import Box
from gymnasium.wrappers import GrayscaleObservation, ResizeObservation
import torch
import torch.nn as nn
import torch.optim as optim
import torch.nn.functional as F
from torch.distributions import Normal
import numpy as np
max_frames = 200000
action_repeat = 4
class EarlyStopWrapper(gym
How to sideload a custom Swift app for personal use without a paid Apple Developer Program?
22 February 2026 @ 3:21 am
Hi everyone,
I have developed a personal application using Swift and would like to install it on my own iPad. Since I am the only user and have no plans to publish this app to the App Store, I am looking for a way to use the app long-term without subscribing to the $99/year Apple Developer Program.
I am currently using the free Apple ID provisioning method via Xcode. However, the main drawback is the 7-day expiration limit, which requires me to re-sign and re-install the app every week.
I have a few questions regarding this:
1. Are there any legitimate ways or workflows to extend the 7-day signing period for personal development?
2. Is there a way to automate the re-signing process so the app remains functional without manual intervention every week?
3. For those who develop apps strictly for their own devices, what is the most stabl