Duplicate call of FilterChainProxy with SpringSecurity, MVC and
-
تاریخ: 1405/6/7 ساعت: 2:40
I encounter a strange behaviour in my Spring-Boot project (v4.0.6):When I execute a Controller which retu s ResponseEntity<StraingResponseBody> for writing NDJSON-Lines the FilterChainProxy of SpringSecurity will get invoked twice. In the second invocation it looses the previous resolved Authenticat...
Unable to open 3 VS Code windows attached to the same Docker container
-
تاریخ: 1405/6/7 ساعت: 2:40
I have a Docker container with OrbStack that contains a directory repos with a repository app-main and worktrees like app-feature-a to develop in parallel. Configuration is done in order to prevent modification of the container configuration file in the running Docker. project/ ├── .devcontainer/ # ...
How to use Hibernate StatelessSession with open-in-view
-
تاریخ: 1405/6/7 ساعت: 2:40
We would like to use Hibe ate StatelessSession injected into our Spring Data JPA repositories. Our understanding is this requires Hibe ateTransactionManager and SharedSessionCreator.createSharedStatelessSession. Our setup is like follows: @Bean public Hibe ateTransactionManager transactionManager(En...
how to commit change while leaving all the staged and unstaged changes?
-
تاریخ: 1405/6/7 ساعت: 2:40
I created a file with one line "bug line", initialized git repository and committed change. Then I added the second line "staged" and staged the change. Then I added the third line "unstaged". How to add a commit changing the first line to "bug line changed" so that I still get the second line as st...
Detaching a posix thread vs detaching a std؛ thread
-
تاریخ: 1405/6/7 ساعت: 2:40
I was reading a (quite old) book on POSIX API, and in the chapter on threads it says that on retu from main() all the threads (including detached ones) are terminated. I would expect that std::thread::detach() inte ally uses POSIX threads API, and yet it seems that a detached std::thread is sort of ...
How to prevent googles recaptcha v2 box to load multiple times (onclick script)
-
تاریخ: 1405/6/7 ساعت: 2:40
I get this error, if I click my script multiple times: Uncaught (in promise) Error: reCAPTCHA has already been rendered in this element. I know, that error is correct, but how can I fix this? I have got a cookie-icon that shows a banner to accept or to reject the recaptcha/form. I hide or show the r...
Use a group by to have as results a count of 'value = x' and a count of 'value
-
تاریخ: 1405/6/7 ساعت: 2:40
I'm writing a query in Oracle SQL. I'm using a count - group by query, for example: select column_a, count(*) from table_1 group by column_a COLUMN_A COUNT(*) value_1 5 value_2 6 value_3 2 (null) 1 Can I write a group by that allows me to get two result rows, one with value_1 and its count, and anot...
How to resolve access of variables in a nested chain of templated classes?
-
تاریخ: 1405/6/7 ساعت: 2:40
The following code snipped defines a nested chain of templated C++ classes. The problem I have starts on the third level. The initialization of the three level nested class works well, which can easily checked in a debugger. However, a problem arises when attempting to access the nested class member...
Apply where clauses after union in Eloquent ORM
-
تاریخ: 1405/6/7 ساعت: 2:40
I'm working on a Laravel project and I need to search through 2 models as the same time. I decided to use a union for this query, as I would do it in SQL. One of my models is converted into the other, and then the two queries are unioned. I was expecting to be able to filter as well after that, but ...
Gcc cannot find shared library
-
تاریخ: 1405/6/7 ساعت: 2:40
I am having trouble compiling a C program that uses a shared library. To reduce the problem as much as possible, I am following a tutorialI have two source files, in the same directoryfoo.c:#include <stdio.h> exte void foo(void); void foo(void) { puts("Hello, I am a shared library"); } main.c:#i...
Alternative way to check if input value is present in `enum` or not. Currently
-
تاریخ: 1405/6/7 ساعت: 2:40
When working with keyboard input in a situation like the one shown in the next simplified example: // abc.hpp #pragma once #include <array> // ranges of integer values in the enum could be contiguous or // not, so question is for a general scenario. However if being // a contiguous range of integer ...
Raspberry Pi - robot [closed]
-
تاریخ: 1405/6/7 ساعت: 2:40
I am trying to make a small robot with raspberry pi 3, Arduino uno and python sockets. Here is my code :On windows, i open the server socket and i send the command like so :def connect_client_and_get_id(server): client, _ = server.accept() full_id = '' first_message = True while 1: msg = client.recv...
VS Code terminal issue
-
تاریخ: 1405/6/7 ساعت: 2:40
I'm lea ing Python and using VS Code (Windows). I wanted to clear the terminal from the long paths when running code, so I installed Code Runner and went to Settings -> Executor Map, and changed python map from "python -u" to "clear && python3 -u". But when I run code, I get what's in the picture in...
How optimize SEO for Alternative Manufacturer Part Numbers in a REACT SPA
-
تاریخ: 1405/6/7 ساعت: 2:40
I am working on improving the SEOP of an e-shop built as a React SPA. (I know its bad). The e-shop contains products that have one main Manufacturer Part Number, but some products can also have one or more alte ative manufacturer part numbers. I need to make sure that wehn people search on Google us...
Why is my look_at method is inverted for camera transformation?
-
تاریخ: 1405/6/7 ساعت: 2:40
I'm trying to lea graphics programming. Currently, I'm trying to make my camera look at the world origin at (0, 0, 0), but I can't understand why this operation is inverted for the camera. For example, if I have a camera at (0, 0, -5), it tries to look at (0, 5, 0). Instead of looking at the desired...
Allocation stratified sampling with R
-
تاریخ: 1405/6/7 ساعت: 2:40
This is my dataset set.seed(2026) n <- 1000 img_id <- sprintf("IMG_%04d", seq_len(n)) strata <- sample(c("A", "B", "C"), size = n, replace = TRUE, prob = c(0.8, 0.1, 0.1)) split <- sample(c("train", "test", "val"), size = n, replace = TRUE, prob = c(0.7, 0.2, 0.1)) dataset <- data.frame(img_id, spli...
Stuck on old limits with allways free
-
تاریخ: 1405/6/7 ساعت: 2:40
Im trying to resurrect my compute instance, but im stuck on ai chat and inability to create service request, i had 4 OCPU + 24GB ram instance, but after change in limits, im stuck with locked instance which i cannot even edit to comply with new rules, any chance to get out of this hell of ai chatbot...
Mac fails to locate git after update (Tahoe 26.6.2), still won't work even after
-
تاریخ: 1405/6/7 ساعت: 2:40
As the title mentions, after updating Mac to Tahoe 26.6.2, each time I open terminal it says "Failed to locate 'git', requesting installation of command line developer tools." And even when I install the tools, it still doesn't work, and the pop-up keeps popping up each time I run a git command. Som...
Python match-case vs dictionary performance internals
-
تاریخ: 1405/6/7 ساعت: 2:40
When conditional branching logic grows large in Python, the advice has always been to map keys to functions or values using a dictionary lookup mapping.get(key) to achieve O(1) time complexity, rather than using a long, O(n) sequence of if-elif statements. However, with structural patte matching (ma...
type casting boost multiprecision integer returns wrong answer
-
تاریخ: 1399/7/22 ساعت: 20:22
امروزدخترم رابردم دندانپزشکی .یکی ازهمکاران قدیمی به اسم خانم شریفی رادیدم خوشحال شدم ،راستش برای من فرقی نمی کنه که خاطره خوب ازهمکارام داشته باشم یانه وقتی بعدازمدتهااونهارامی بینم خوشحال میشم،بعدرف