instruction stringlengths 0 30k ⌀ |
|---|
I am working on a project in Mercurial with CMake in Windows Visual Studio 2022.
CMake reruns every time I swith from one revision to another, which changes CMakeLists.txt, and a very time costly build follows.
Could one explain please how CMake decides the time passed to rerun?
Does cmake rerun always mean re... |
How to prevent CMake rerun after Cmake changed? |
|cmake|compilation|mercurial|revision|cmakelists-options| |
null |
In v5 the default value for the `Button` color prop changed from `default` to `primary`. So in v5 the following two buttons are identical (apart from the text in them):
```
<Button variant="contained" color="primary">Primary</Button>
<Button variant="contained">Grey</Button>
```
The easiest way I see t... |
|swiftui|swiftui-list| |
The apk needs to be zipaligned with parameter '4' for this specific purpose. If an external apk is used, then zipalign must be done manually or else the .so file inside the apk will refuse to load because of the wrong alignment. Even though you might think that the gradle build of you app already did a zipalign, that z... |
**CONTEXT:**
I have a component called GenericTable which receives an Enumerable of T (classes) and displays it in a [table][1]. Every column comes with 2 buttons one for update and inactivate which are eventcallbacks.
This is the razor code (I'll try to paste the part where the problem is produced I don't want... |
Bool value is not triggering loader Blazor |
|c#|.net|razor|blazor| |
I have a list with json data filled in `GetListView()` view. now i am showing this list in SecondView. here i want to show the GetListView from white view bottom to screen bottom to 20. but i can able to give only height: 500 for the GetListView.. i want it should be bottom to 20 of the screen
**How to show list up... |
Swift UI design issues |
|swift|list|swiftui|design-patterns| |
Depends on the JSON Schema version used which you didn't indicate, AJV defaults to draft-07 with the `import` statement you are using
Couple things:
- Your schema definition is partially ignored because you can't have siblings to a `$ref` in older draft versions of JSON Schema. So the `$ref` defined with `baseRes... |
ok, heres whats wrong with your code
1. after assigning the srcObject of a video element you have to call play
2. in the setInterval function you get the image data in your let statement but you havent drawn anything to the canvas yet, although it would be available in the second iteration
3. when you actua... |
You are adding the view to the cell directly and setting the constraints on the contentView.
When you add the view to the content view it will work as expected, so looking at your code if we only have to change the 4th line to `contentView.addSubview(view)` like so it would become:
let controller = UIHostingC... |
|vba|ms-project| |
Can out-of-order execution of CPU affect the order of new operator in C++? |
I've read a lot of articles and guides online stating that I need to install this [npgsql program](https://github.com/npgsql/Npgsql/releases) in order to connect Power BI to a PostgreSQL database. Unfortunately none of them provide instructions on how to actually install it. On the website there are two zip files that ... |
Error **net::ERR_CONNECTION_RESET** error while uploading files to AWS S3 using multipart upload and Pre-Signed URL |
|amazon-web-services|amazon-s3|next.js|connection-reset| |
null |
Instead of using `openai.Completion.create()`, you need to instantiate a client object using `client = openai.OpenAI()` and then utilize `client.chat.completions.create()` method for generating completions.
Here's an example which shows how you can do it (taken from official OpenAI [documentation][1]):
```python
f... |
I'm using a custom Select component in a React application, which includes SelectValue and SelectItem components. I want to change the font weight of the SelectValue component to bold when a SelectItem is selected.
For example, a user clicks the "TO:" option in the dropdown, so the placeholder of the SelectValue c... |
How to change the Font Weight of a SelectValue component in React when a SelectItem is selected? |
|reactjs|node.js|select|fonts|dropdown| |
null |
`setTimeout` creates a new macrotask queued into the event loop after the timeout, so your promises are queued in different macrotasks and have no relation at all. |
Indeed, the redirection URL is not specified in some DOM element in your case.
It gets fetched by JS from 'https://services.tmmumbai.in/BotService/fetchUrl?productCode=XXX' on element click.<br>
You have to pass the code of the desired product instead of the 'XXX'. <br>
But the product code is not specified in th... |
Here's an executable example:
With SrcTable as (SELECT 'product_id' as key, 'iphone_14' as value from dummy union all
SELECT 'product_id' as key, 'iphone_14_pro' as value from dummy union all
SELECT 'country_code' as key, 'USA' as value from dummy union all
SELECT 'country_code' as key, 'CA' as va... |
**The problem**
When i try to scaffold the nordhwind.accdb i get a COM Exception
In VSCode Powershell Terminal:
```lang-ps
dotnet ef dbcontext scaffold "Provider=Microsoft.ACE.OLEDB.12.0;Data Source=<PATH>\northwind.accdb" EntityFrameworkCore.Jet -o Models
```
In Visual Studio 2022 Paket Manager Console:
`... |
EntityFrameworkCore.Jet: Scaffold doest not work - COMException (0x800A0CB3) |
|ms-access|entity-framework-core|jet|scaffold| |
null |
I have HTML table with following structure:
```
<table>
<thead>..</thead>
<tbody>
<tr>
<td>some</td>
<td>content</td>
<td>etc</td>
</tr>
<tr class="certain">
<td><div class="that-one"></div>some</td>
<td>content</td>
<td>etc</td>
</tr>
several other rows..
<tbody>
</table>
```
And I am tr... |
The following KQL query gives me the logs regarding memory usage for an app
traces
| where timestamp > ago(1d)
| where message startswith_cs "memory_profiler_logs:"
| parse message with "memory_profiler_logs: " LineNumber " " TotalMem_MiB " " IncreMem_MiB " " Occurrences " " Contents
| un... |
How to install NPGSQL and connect a PostgreSQL database to Power BI? |
|database|postgresql|powerbi|npgsql| |
null |
Ok, this seems to be by design. After RTC init mode exits, SSR is reset:
https://community.st.com/t5/stm32-mcus-products/stm32-rtc3-mixed-mode-writing-tr-resets-ssr/m-p/655899/highlight/true#M239486 |
|excel|vba|outlook| |
im using Next.js to create a web application and next-intl to translate it to multiple languages. I created the not-found.tsx file to handle 404 errors.
What im seeing now if i inspect the html of the 200 pages is that the translations of the 404 page, are loaded as next js <script> tags (self.__next_f.push).
How... |
Next intl 404 translations loaded on all non-404 pages |
|javascript|reactjs|next.js|next-intl| |
null |
You are using Spring Boot 3.2 which pulls in JUnit 5. While also using `cucumber-junit` which depends on JUnit 4.
Support for JUnit 5 was introduced into Surefire somewhere around v2.22. But Surefire can not run JUnit 4 and JUnit 5 together at the same time and so defaults to the latest version of JUnit when both ar... |
Apple store's webhook (notification api v2) signs all requests. I would like to verify that the object was indeed signed by Apple in order to be sure that the request is coming from them.
Apple provides libraries that are able to do that, but unfortunately in the environment I work on, all I can use is the library c... |
I'm trying to use native api. I have the following code to get the 5 most used apps. It's a Native Android module with TypeScript because I can't call APIs with React Native:
```
fun getUsageData(startTime: Double, endTime: Double, successCallback: Callback) {
val usageStatsManager = reactApplicationContext.ge... |
{"Voters":[{"Id":1417694,"DisplayName":"Squashman"},{"Id":9214357,"DisplayName":"Zephyr"},{"Id":3074564,"DisplayName":"Mofi"}]} |
Xampp not connecting to DBForge what to do?
[xampp](https://i.stack.imgur.com/xycb6.png)[dbforge](https://i.stack.imgur.com/aCrDu.png) I clicked on xampp mysql start and opened dbforge then i clicked to new connection in dbforge but the user and root did not popped up only that window what i attached here as a dbf... |
Xampp not connecting to DBForge what to do? |
|xampp|dbforge| |
null |
I have a database with points, and want to subtract the points I just added after a year.
I figured I would use a queue job and subtract my points later. I followed this official laravel link: https://laravel.com/docs/4.2/queues#queueing-closures
Here is a snippet:
```
DB::table('users')->where('id', $user_id)-... |
How to use Queue::late in laravel 4.2? |
|laravel|php-carbon|laravel-4.2| |
In my project, we work with constantly update of components. In a specific screen, we have a TabView with a dynamic list of items, these items may be updated. The problem is: If these items is inside a TabView with .tabViewStyle(.page), the item updated isn’t updated. I made a example code that can reproduce this behav... |
I am using `mathjax` and `Shiny` to display equations. But the output text doesn't seem to me to be of very high quality. How do I increase the dpi or the resolution of the output, which seems to be a dull or transparent black or isn't at it's full "brightness", if that makes sense?
library(shiny)
library(m... |
How to increase quality of mathjax output? |
|css|r|text|shiny|mathjax| |
One way to handle this is to put a timeout on the socket with settimeout(), and handle socket.timeout exceptions raised by recv() or recvfrom(). Normally you will simply retry the recv() in a loop, but each time the socket times out, you have a chance to poll for a shutdown flag, etc. The downside, of course:
- The... |
{"Voters":[{"Id":6738015,"DisplayName":"Compo"},{"Id":9214357,"DisplayName":"Zephyr"},{"Id":3074564,"DisplayName":"Mofi"}],"SiteSpecificCloseReasonIds":[11]} |
I've been coding for awhile now and I was wondering what I could do to be more efficient when it comes to coding or any advice of what I'm doing incorrect. I think the things I can probably point out right off the bat is my misuse of width on majority of the tags. I also remember reading something that I should be usin... |
KQL : how to get memory increments above certain threshold? |
|kql| |
Use the [`row_number()`][2] window function, but don't forget you also need an adequate [collation][3] for that to work properly with your week codes: [demo at db<>fiddle][4]
```
CREATE COLLATION num_ignore_punct
(provider = icu, locale = 'und-u-ka-shifted-kn');
SELECT "WeekCode",
"Revenue",
... |
The problem is that you are trying to assign the same ref for all your components. a ref needs to be assined to a single instance of a component so we can modify your code to the following
```
import React, { useRef, useEffect } from "react";
const DynamicComponent = React.forwardRef(({ name }, ref) => {
// Som... |
Working on upgrading an application from JDK 11 to JDK 17 and it has an issue with Avro that I'm not certain how to get around. I did have a lot of messages about the new LocalDate(string) method was being deprecated and removed and I was able to take care of that in the regular code. Howver in the Avro avdl file I... |
Avro after upgrading to JDK 17 |
|java|gwt|avro| |
I believe the root issue happens when creating the 'selectedInvoices' variable, that map creates an array of strings and the values you retrieve later on from your database sheet are integers. Please try this code:
function promptUserToSelectInvoices(data) {
// Prompts the user to enter invoice numbers se... |
Note that the formula for slope in simple linear regression without intercept is
```sum(x*y)/sum(x^2)```. We can utilize this in matrix form:
```
diag(t(M.x) %*% M.y) / diag(t(M.x) %*% M.x)
[1] 0.142780158 -0.688172617 0.591777820 1.096226652 0.458449019 -0.729486974 -0.161225471
[8] -0.275493553 0.500602... |
**Environment:** Laravel with Filament on Docker (Laravel Sail)
The request is made using `https://` but there are 2 files (`table.js` and `select.js`) which seem to be being requested by `http://` which is causing the following CORS error:
```
Access to script at 'http://test.docker.localhost/js/filament/forms/... |
CORS Error caused by JS files being requested by http in an https environment using Laravel Filament with Sail / Docker |
|laravel|docker|laravel-sail|laravel-filament|filamentphp| |
This is caused due to reverse-proxying and the app thinking that it is being served by http when actually it's being served by https.
The following can be added to the `bootstrap/app.php` file in Laravel 11+ to resolve this:
```
->withMiddleware(function (Middleware $middleware) {
$middleware->trust... |
What can I do to improve my coding on both html and css |
|html|css|nested|structure| |
null |
*There is very good post about trimming 1fr to 0: https://stackoverflow.com/questions/52861086/why-does-minmax0-1fr-work-for-long-elements-while-1fr-doesnt*
In general I would like to have a cell which expands as the content grows, but within the limits of its parent.
Currently I have a grid with cell with such ... |
You did not answer my clarification question...
1. **There is not any command line able to write in the workbook**. You can see the list of available command lines [here](https://support.microsoft.com/en-us/office/command-line-switches-for-microsoft-office-products-079164cd-4ef5-4178-b235-441737deb3a6?ui=en-us&rs=en... |
I'm working on a .net project.
I am trying to pay out some amount to my connected account.
I tried with amount = 15
This is my account balance object.
```
"object": "balance",
"available": [
{
"amount": 1929490,
"currency": "aud",
"sourceTypes": {
"card": 192949... |
Stripe connect payout - throws exceptions |
|.net|stripe-payments|payout| |
I need to initialize list of uint. I read that one can initialize each item in list, but I need efficient way, i.e. as in systemverilog where you can initialize with {1,2,3...} |
How to initialize list of uint in Specman? |
|specman| |
I have a list of things and want to get them in two seperate colums. Can I do that by using search and replace ? or How do I do this ?
Here is an example
[how it is now](https://i.stack.imgur.com/ZwIC0.png)
[how it should be](https://i.stack.imgur.com/Jl8Ly.png)
google sheets, find and replace, next column |
google sheets, search and replace for next colum |
|google-sheets|find-replace| |
null |
This is from a .ipynb jupyter notebook in vscode in windows 10:
even when I pip install pandas in the terminal it still gives this error:
---------------------------------------------------------------------------
ModuleNotFoundError Traceback (most recent call last)
Cell In[1], line 2
... |
|tcp|tcpclient|tcpdump| |
null |
This is possible by modifying the default code in the main (also make sure to import ssl)
import ssl
if __name__ == "__main__":
try:
ssl_context = ssl.create_default_context(ssl.Purpose.CLIENT_AUTH)
ssl_context.load_cert_chain('./certs/cert.pem', './certs/key.pem')
... |
I'm having a small problem with my code.
The case is: I have a <img> element and a button to browse for a file. When I click the button I can select an image (jpg or png) max size of 2mbs.
The "strange" is this, when I click the button for the first time, nothing shows on the <img>, but if a click the second time and... |
How to update an item inside if a TabView with .tabViewStyle(.page)? |
|ios|swift|swiftui|scrollview|tabview| |
null |
I am trying to create a function that generates a question and stores it into the database using Java Spring. I'm uncertain whether the issue lies in the JSON or the structure of my code. (I've provided both below.)
Here's the structure I'm currently using:
**Question Service Implementation**
```
@Service
p... |