StackOverflow.com

VN:F [1.9.22_1171]
Rating: 8.5/10 (13 votes cast)

Random snippets of all sorts of code, mixed with a selection of help and advice.

Android Compose: Text overlapping status bar in Preview(showSystemUi = true), not on device

1 June 2026 @ 11:45 am

I am starting my first Compose project with Android Studio (Panda 4 | 2025.3.4 Patch 1). I just opened Android Studio, slected New Project > Empty Activity, and did not add one line of code. When I start the new app on my device, I see the "Hello Android!" displayed on top left corner of the screen, what I suppose is the expected result. enter image description here Now when I select Preview (on my Mac) it shows "Hello Android!" messed up with the status bar. enter image description here Do I miss something ?

CXF does not find SecurtyPolicy classes "Please check that (the correct version of) Apache WSS4J is on the classpath: null"

1 June 2026 @ 11:42 am

I am passing an app that was developed for weblogic into tomcat. One specific call to a remote WS is falling. 2026-06-01 13:13:45,285 \[http-nio-8080-exec-9\] INFO org.apache.cxf.wsdl.service.factory.ReflectionServiceFactoryBean - Creating Service {http://\[REDACTED\]}\[REDACTED\] from WSDL: https:\[REDACTED\]?wsdl 2026-06-01 13:13:46,243 \[http-nio-8080-exec-9\] WARN org.apache.cxf.ws.security.policy.WSSecurityPolicyLoader - Could not load or register WS-SecurityPolicy related classes. Please check that (the correct version of) Apache WSS4J is on the classpath: null 2026-06-01 13:13:46,270 \[http-nio-8080-exec-9\] WARN org.apache.cxf.ws.security.policy.WSSecurityPolicyLoader - Could not load or register WS-SecurityPolicy related classes. Please check that (the correct version of) Apache WSS4J is on the classpath: Could not initialize class org.apache.wss4j.stax.setup.WSSec 2026-06-01 13:13:46,287 \[http-nio-8080-exec-9\] WARN org.apache.cxf.ws.policy.Assertion

misunderstanding of pointer-interconvertible definition in the standard

1 June 2026 @ 11:39 am

the definition of pointer-interconvertible (https://eel.is/c++draft/basic.compound#6) states that: If two objects are pointer-interconvertible, then they have the same address, and it is possible to obtain a pointer to one from a pointer to the other via a reinterpret_cast ([expr.reinterpret.cast]). Yet in reinterpret_cast section https://eel.is/c++draft/expr.reinterpret.cast, there is no mention of it, while it is mentioned for static_cast (https://eel.is/c++draft/expr.static.cast#12): A prvalue of type “pointer to cv1 void” can be converted to a prvalue of type “pointer to cv2 T”, where T is an object type and cv2 is the same cv-qualificatio

Vlookup using string as reference sheet name

1 June 2026 @ 11:34 am

I have two workbooks, one contains my formulas/calculations, the other my data in multiple sheets. I am trying to do a vlookup where the lookup array comes from a cell with a concat formula. Example: =VLOOKUP(B1,(vars!A17&'calc formula'!B2&vars!A15),MATCH($D4,[SALES.xlsx]NGFS_LD!$1:$1,0),FALSE) B1: reference ID to search A17&B2&A15 Is the reference to the second workbook: the text result of this part is: [SALES.xlsx]TEST!$A:$AF Here A17 is [SALES.xlsx], B2 is TEST and A15 is !$A:$AF. If I try to pass the concatenated string I get the #N/A result. Is there a to perform this kind of operation where the reference array name in the vlookup function is a concatenation of other cells (strings)?

OpenTelemetry with .NET filters low duration spans

1 June 2026 @ 11:33 am

I am using OpenTelemetry to do some monitoring and have the following config. I am trying to filter out very low duration spans from the monitoring, but for some reason they are still showing. I have it set to 1 second in the example, in production this will be more like 10ms. builder.Services.AddOpenTelemetry() .ConfigureResource(resource => resource .AddService(serviceName: serviceName, serviceVersion: serviceVersion) .AddAttributes(new Dictionary<string, object> { ["deployment.environment"] = builder.Environment.EnvironmentName })) .WithTracing(tracing => tracing .AddSqlClientInstrumentation() .AddSource(serviceName) .AddAspNetCoreInstrumentation() .AddHttpClientInstrumentation() .AddOtlpExporter(options => { options.Endpoint = new Uri("https://api.uptrace.dev/v1/traces&

Auditing Claude's binary regressions in CI/CD? [closed]

1 June 2026 @ 11:24 am

I am trying to set up an automated quality gate in a GitHub Actions CI/CD pipeline to catch microarchitecture-level performance regressions (such as instruction bloat, branch mispredictions, or bad spatial locality leading to cache misses) before deployment. The application is written in [Insert your language here, e.g., C++ / Rust], and while the source code passes standard semantic unit tests, different compilation targets occasionally result in binaries that cause unexpected 100% CPU utilization spikes on physical silicon. Because general source-code static analysis tools do not map to final machine code behavior, I am looking to automate this at the compiled level. What I have tried / analyzed so far: Dynamic Profiling (eBPF / Valgrind): Running runtime benchmarks via emulators (QEMU) or remote test rigs inside the runner. However, this introduces massive time overhead and flaky pipeline runs due to environmental noise in virtualized runners. M

Django + HTMX vs Next.js + Django REST API: Is React/Next.js necessary for a modern frontend?

1 June 2026 @ 11:13 am

I'm building a web application where Django is my primary framework and backend. I currently have two frontend approaches: Option 1: Next.js + Django REST API Django serves only APIs. Next.js consumes the APIs. Requires maintaining separate frontend and backend projects. Frontend directory is about 700 MB with ~30,000 files (node_modules, build tooling, etc.). Additional effort is needed for API serialization, authentication flow, and frontend-backend integration. Option 2: Django Templates + HTMX + Alpine.js + Tailwind CSS Django views pass data directly to templates. HTMX handles partial page updates. Alpine.js is used for lightweight interactivity. Tailwind CSS for styling. Only a few template files are needed. No separate frontend application or AP

Fine-tuning Qwen3-TTS-12Hz-1.7B-Base for Bengali (A new language, not by default supported): Foreign/Hindi Accent Bias and Lack of Naturalness [closed]

1 June 2026 @ 11:08 am

Problem I fine-tuned Qwen3-TTS-12Hz-1.7B-Base on a Bengali / Bangla dataset of around 7 hours from a single speaker. I am planning to train on 150+ hours of multi-speaker Bengali data later. For inference, I used the custom_voice type model functions. The fine-tuning process itself runs successfully after applying a few patches, and the trained model is able to generate Bengali speech. However, the generated speech does not sound like native Bengali. It sounds more like Bengali spoken with a Foreign/Hindi accent or Hindi-influenced prosody. The pronunciation is somewhat Bengali-like, but the accent, rhythm, intonation, and speaking style are noticeably Hindi-influenced and not natural for Bengali. Dataset Language: Bengali / Bangla Dataset size: around 7 hours Number of samples: 8k+ Speaker setup: single Bengali female speaker Text format: Bengali letters and punctuation

iText.Commons.Utils.DIContainer.GetInstance[T] NullReferenceException in Android Unity

1 June 2026 @ 8:52 am

I am working with iText to generate PDF. It is working fine in the editor (Windows), but when I am running the Andriod build, it throws the following exception: 2026/06/01 12:45:41.669 29785 29810 Error Unity NullReferenceException: Object reference not set to an instance of an object. 2026/06/01 12:45:41.669 29785 29810 Error Unity at iText.Commons.Utils.DIContainer.GetInstance[T] () [0x00000] in <00000000000000000000000000000000>:0 2026/06/01 12:45:41.669 29785 29810 Error Unity at iText.Kernel.Pdf.PdfPagesTree..ctor (iText.Kernel.Pdf.PdfCatalog pdfCatalog) [0x00000] in <00000000000000000000000000000000>:0 2026/06/01 12:45:41.669 29785 29810 Error Unity at iText.Kernel.Pdf.PdfCatalog..ctor (iText.Kernel.Pdf.PdfDictionary pdfObject) [0x00000] in <00000000000000000000000000000000>:0 2026/06/01 12:45:41.669 29785 29810 Error Unity at iText.Kernel.Pdf.PdfDocument.Open (iText.Kernel.Pdf.PdfV

Show Windows 11 netification in "Your battery is very low" style

31 May 2026 @ 9:12 pm

There are few notifications in Windows that are shown ass full screen overlays or something like that. I'm writing a tool that monitors some pirepheral statuses and i want to show same style messages that can be hardly ignored. Is there an API that be utilized for other apps to show windows like this, without creating custom window styles ? "your battery is running low" windows message, old style"your battery is running low" windows message, new style