79260819

Date: 2024-12-07 15:02:43
Score: 1.5
Natty:
Report link

Everything about your request is completely correct.

If you receive a product list from http://shop.tld/api/product you have used the request type GET instead of POST.

I have double checked it in a local installation.

POST will create your product: enter image description here

GET will get you a list of all products: enter image description here

Reasons:
  • Probably link only (1):
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: marcus.kreusch

79260815

Date: 2024-12-07 14:59:43
Score: 2
Natty:
Report link

SELECT COALESCE(ID, 'TOTAL') AS ID, Product, SUM(Quantity) AS TotalQuantity FROM Sales GROUP BY ROLLUP(ID, Product);

Here, Replaces NULL in the ID column with "TOTAL" in rolled-up rows. Helps create more meaningful outputs by avoiding NULLs in summary rows.

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Sunil Nakka

79260803

Date: 2024-12-07 14:52:42
Score: 0.5
Natty:
Report link

I encountered a similar issue and successfully resolved it by utilizing Xdebug, a powerful extension for PHP that enhances the development experience.

Xdebug offers several features that can help diagnose and solve performance problems:

To implement Xdebug in your project, visit the official website at https://xdebug.org for installation instructions and documentation. By leveraging these tools, you can gain deeper insights into your application's behavior and potentially identify the root cause of your performance issues

Reasons:
  • Long answer (-1):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Amirul Aziz

79260792

Date: 2024-12-07 14:44:40
Score: 3
Natty:
Report link

"extra": { "eas": { "projectId": "Your project id" } }

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Moon Rana

79260782

Date: 2024-12-07 14:39:39
Score: 1.5
Natty:
Report link

For my application, the output of yolo model differs from the camera input tensor, because output contains confidence scores and bounding boxes. It is just "description" for your image and you can't visualise them on image without your image, as it is not the case with yolo segmentation model whose output can be interpreted to see every pixel (but in android app reduced to 160x160px).

Further analysis of your output is similar to another I just answered, so it can be seen here: How to interpret output tensor from YOLOv8 web model.

Reasons:
  • No code block (0.5):
  • Low reputation (1):
Posted by: marci

79260770

Date: 2024-12-07 14:29:37
Score: 2
Natty:
Report link

0xed24fc36d5ee211ea25a80239fb8c4cfd80f12ee is the correct one.

If you go to Binance faucet and send yourself some, you can check in your wallet what the contract address of the token.

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Ferenc

79260769

Date: 2024-12-07 14:28:37
Score: 2.5
Natty:
Report link

You might try out dynalinks - it allows you to create up to 5k links for free.

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Single line (0.5):
Posted by: Piotr

79260759

Date: 2024-12-07 14:22:36
Score: 2
Natty:
Report link

Just for the record, this still does not work in 2024 with IntelliJ. Yet it worked (and still does) in Netbeans...

Reasons:
  • Whitelisted phrase (-1): it worked
  • Low length (1):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: garbi

79260757

Date: 2024-12-07 14:22:36
Score: 2.5
Natty:
Report link

At the moment the only way to have an effective body sensor or fit device in a Android device is with excessories and a app you will have to subscribe to for a fee per month after the free try period finishes.

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: Lee Brewster

79260753

Date: 2024-12-07 14:17:35
Score: 3.5
Natty:
Report link

Height customization is mentioned here: https://github.com/junegunn/fzf?tab=readme-ov-file#preview-window and they also mentioned to not export those variables (what exactly I didn't bother understanding) but I don’t know how you can implement it

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: ayumo

79260749

Date: 2024-12-07 14:14:35
Score: 1
Natty:
Report link
    public interface ISortedGroupWithMover<T> : ISortedGroup<T>
        where T : IMoveableHoldee<T>

I think the correct interface for this is like this, I dont think the previous version has the same meaning altough im not sure of the difference.

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (0.5):
Posted by: ChrisCross

79260725

Date: 2024-12-07 13:52:31
Score: 2
Natty:
Report link

XML sitemaps should include all valuable, indexable URLs and not (just) top-level subdirectory URLs: https://developers.google.com/search/docs/crawling-indexing/sitemaps/build-sitemap

However, search engines don't have to index your content; if they consider it low-quality then there's a good chance they won't index it.

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Cmastris

79260724

Date: 2024-12-07 13:52:31
Score: 0.5
Natty:
Report link

I've seen this issue Visual studio code runs NPM outside integrated terminal before and the only solution was to run VSCode as administrator. However, this solution restricts me from using AutoHotkeys and update VSCode automatically.

Here is the solution I randomly found today: check if node.exe isn't running as administrator, because this is most likely what's causing these node popups. Disable run as administrator in the properties of this file.

Reasons:
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (0.5):
Posted by: Michael

79260700

Date: 2024-12-07 13:39:28
Score: 0.5
Natty:
Report link

I have a class with the property display: flex. When I go to Chrome dev tools, it shows display: block, because of user-agent style sheet:

I had a very similar problem. Chrome dev tools showed me that my flex-direction: row; was inactive with the info:

The display: block property prevents flex-direction from having an effect.
Try setting the display: block property to display: flex.

I searched every single <div in my html and added class="TODO" to each div, then I set the CSS .TODO class to display: flex but nothing worked. This was a useful debugging exercise. The problem was that my:

#forecast {
    flex-direction: row;
    height: 100%;
}

was missing the display: flex; so flex-direction was inactive. Once I added display: flex everything started working (dumb mistake). The debugging process was useful and the TODO classes were easy to find and back out of the code once it was fixed. This process might help others looking to find this source of this type of bug. Working solution shown below.

#forecast {
    display: flex;
    flex-direction: row;
    height: 100%;
} 
Reasons:
  • Blacklisted phrase (1): but nothing work
  • Long answer (-1):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Clifford Cummings

79260698

Date: 2024-12-07 13:39:28
Score: 4
Natty:
Report link

not solved for screen recordings though. :(

Reasons:
  • Blacklisted phrase (1): :(
  • Low length (1.5):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: Nathanael Tse

79260688

Date: 2024-12-07 13:31:25
Score: 0.5
Natty:
Report link

I haven't seen answer for this question anywhere, even on Ultralytics pages, so I decided to, based on last month working with the same tools, write my conclusions about that:

In the beginning, my research wouldn't be possible without "comments" section at this page: Ultralytics tfjs integration. After doing some research using those tips, I chose to download prediction data in .txt format and analyze it in python.

This image shows all values in those predictions: output of yolo11n model in tfjs format Seeing those values at the beginning (between 0 and 640) and after index ~40000 (around 0) we can conclude that first few rows are about dimensions, and other about confidence. From this image: first four rows we can see that those dimensions are x_min, y_min, x_max, y_max.

To keep this answer clearer, I will post images only of first and last 100 boxes to see how they look like: first 100 bounding boxes, last 100 bounding boxes. It can be seen that detection started at upper left corner and is going to almost whole image. Because of me being in the middle of image, and taking the most space of it, confidence scores for class 0 ("person") from COCO dataset are around 0 for first ~8200 boxes, and higher than 0.8 for those at the end: confidence scores of class 0, confidence scores of other classes are negligible as you can see here: confidence scores of class "bus".

Taking only max values for every class (reshaping the data to 84 x 8400 and computing the max along axis 1) will give us clear view of what was taken on image: maximum confidence per class.

Reasons:
  • Long answer (-1):
  • No code block (0.5):
  • Low reputation (1):
Posted by: marci

79260681

Date: 2024-12-07 13:27:23
Score: 13 🚩
Natty: 5
Report link

@IntermediaryDeveloper I need help with integrating Adyen Web Drop In using sessions method. I would like to understand from you how you did the same for a test transaction step by step ! Can you please help me out ?

I have setup my test sandbox account, generated API credentials but stuck, you can refer my question at :

https://stackoverflow.com/staging-ground/79260476

Reasons:
  • Blacklisted phrase (1): help me
  • Blacklisted phrase (0.5): I need
  • Blacklisted phrase (2.5): I need help
  • Blacklisted phrase (1): stackoverflow
  • RegEx Blacklisted phrase (3): Can you please help me
  • RegEx Blacklisted phrase (2): help me out
  • No code block (0.5):
  • Contains question mark (0.5):
  • User mentioned (1): @IntermediaryDeveloper
  • Low reputation (1):
Posted by: Dialen d'souza

79260675

Date: 2024-12-07 13:24:22
Score: 1.5
Natty:
Report link

Amazon RDS Proxy is compatible with Amazon RDS for PostgreSQL single-instance deployments. However, it doesn't support automatic routing to read replicas for non-Aurora PostgreSQL databases. This means that while RDS Proxy can manage connections to your primary RDS PostgreSQL instance, it won't automatically distribute read queries to any associated read replicas.

Source: https://repost.aws/questions/QURgpYNcQWQ32HmZ8lDLmS8w/rds-postgres-rds-proxy-read-replicas

Reasons:
  • No code block (0.5):
  • Low reputation (1):
Posted by: xtepwxly

79260661

Date: 2024-12-07 13:13:19
Score: 1
Natty:
Report link

I've seen a few fixes floating around that say just disable all the warnings in node. But this kinda grinds my gears as it just hides all warnings, and you do want to see some of them. Investigate and then do something about it... or not.

The answer on this thread https://stackoverflow.com/a/78757478/3593217 is great, but there were so many different dependencies in my project using punycode i really didn't want to go down this route.

It would be better (at least for my situation) to disable the warning just for this package and at the repo level.

I also don't want to prepend every npm script in my packages.json, i want this work across the current project and all the scripts. So...

You can create a .npmrc file with the following contents:

node-options="--require ./node-warning-bypass.cjs"

Then create a file at the root of your project (you'll need to use the file ending .cjs due to the require in the node options).

const IGNORED_WARNINGS = [
  'punycode',
  // Add more packages here as needed
];

process.emitWarning = (warning, ...args) => {
  if (IGNORED_WARNINGS.some(pkg => warning?.includes(pkg))) return;
  return process.emitWarning.call(this, warning, ...args);
};

This way it only ignores punycode so you will see other issues if they arise. And you also have a tidy list of the things you're ignoring (things that will need to be updated at some point).

I had just been ignoring this error as mildly frustrating, but after some test refactors it was failing our CI and it moved from mildly aggravating to in the crosshairs.

Reasons:
  • Blacklisted phrase (1): stackoverflow
  • RegEx Blacklisted phrase (1): i want
  • Long answer (-1):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: xam

79260656

Date: 2024-12-07 13:08:18
Score: 1.5
Natty:
Report link

For ahk v2.

^7::
{
    Send("success")
}

b::
{
    Send("{LControl Down}7{LControl Up}")
}

enter image description here

Reasons:
  • Probably link only (1):
  • Low length (1):
  • Has code block (-0.5):
Posted by: Dieisson Silva dos Santos

79260655

Date: 2024-12-07 13:08:18
Score: 0.5
Natty:
Report link

In my case, I needed to recreate a group of many pods, controlled by different deployments/statefulsets with restartPolicy: Always

  1. Assign label for pods. On deployment/statefulset/daemonset manifest add label at the .spec.template.metadata.labels.
  2. Apply/recreate resources (in any way convenient for you). Then check if the changes have been applied:
# kubectl get po -l "app_group=my_grp"
  1. Recreate pods by deleting them (according to their controllers restart policy .spec.template.spec.restartPolicy):
# kubectl delete po -l "app_group=my_grp"

Make sure that the old pods are terminating and new ones should be created instead:

# kubectl get po -w

But there's probably a better way.

Reasons:
  • Blacklisted phrase (0.5): I need
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: dj_donut

79260651

Date: 2024-12-07 13:06:17
Score: 2.5
Natty:
Report link

There is a D3-interpolate npm repo also:

https://www.npmjs.com/package/d3-interpolate

use

npm install d3
npm install d3-interpolate
Reasons:
  • Probably link only (1):
  • Low length (1.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Dawesi

79260650

Date: 2024-12-07 13:05:17
Score: 2
Natty:
Report link

Yes it is safe. Actually there is no shared resource for any race condition to get happened.

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Low reputation (0.5):
Posted by: Parsa Noori

79260648

Date: 2024-12-07 13:05:17
Score: 0.5
Natty:
Report link
  1. Delete node_modules and package-lock.json coz smtms they are corrupted. use rm -rf node_modules package-lock.json
  2. Reinstall Dependencies after deleting u can reinstall u'r packages. use npm install
  3. Check Your package.json Ensure that ajv is listed as a dependency in your package.json. If it's missing, you can add it: use npm install ajv
  4. Verify Versions Sometimes, version mismatches can cause issues. Check if the version of ajv you are using is compatible with your project. You can specify a version by running: use npm install ajv@ 5.If the problem persists, try clearing the npm cache: u can use npm cache clean --force If you're using Create React App, ensure that react-scripts is up to date. If you have installed ajv globally, it might interfere with your local installation. Make sure to use the local version in your project. Sometimes, the error may arise from another underlying issue. Check the terminal for any additional error messages that could provide more context. also ensure that you're importing any modules correctly. If you're manually importing parts of ajv, ensure that the paths are correct. after that you can reinstart your project. hope gonna help ya
Reasons:
  • Long answer (-1):
  • No code block (0.5):
  • Low reputation (1):
Posted by: brythemaster

79260647

Date: 2024-12-07 13:03:16
Score: 1.5
Natty:
Report link
 DB::query("UPDATE users SET mobile_verified= IF(mobile_verified='yes', 'no', 'yes') WHERE user_id='$value1' ");
Reasons:
  • Low length (1):
  • Has code block (-0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: dvijai

79260644

Date: 2024-12-07 13:00:16
Score: 1
Natty:
Report link

Since both Extjs 4.x and Sencha Touch are no longer supported, there wouldn't be any fixes from Sencha.

You could see if there are any polyfills available from apple or generally for legacy js features.

I'd check the dev tab in Safari and see what 'information' items you get in the console - that could lead you to clues of depreciated features.

Reasons:
  • No code block (0.5):
  • Low reputation (0.5):
Posted by: Dawesi

79260637

Date: 2024-12-07 12:55:14
Score: 3
Natty:
Report link

Are you saying it works in extjs 6.5? Why not just use that version? (why not just go to 6.7 then?)

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: Dawesi

79260631

Date: 2024-12-07 12:53:14
Score: 1
Natty:
Report link

Your problem probably has nothing to do with floating vs numeric data type. From the definition of IRR and the linear optimization method it follows that sometimes the IRR estimate @X may be <= -1 (or -100 %), and raising zero to a negative power causes an error (as it is equivalent to raising (1/0) to a positive power). Also, IRRs at or below -100 % make little sense, so you may want to control the result somehow anyway.

I wrote a set-based solution, an inline table valued function for IRR (in TSQL), capable of calculating an unlimited number of IRRs simultaneously. See https://sqlperformancemeasurement.blogspot.com/2024/12/calculating-irr-dpi-rvpi-and-tvpi-part.html

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Kalle Saariaho

79260630

Date: 2024-12-07 12:52:14
Score: 3.5
Natty:
Report link

using this code we can fix that issue

npm install ajv@latest

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: Sahan Silva

79260629

Date: 2024-12-07 12:52:13
Score: 4
Natty:
Report link

I'd also have a look at some of the implementations from that era of extjs like : https://blog.thoughtwizards.com/2018/05/12/extjs-i18n-keys-translations-loaded-from-remote-endpoint/

Reasons:
  • Probably link only (1):
  • Low length (1.5):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: Dawesi

79260624

Date: 2024-12-07 12:50:13
Score: 1
Natty:
Report link

The issue arises because Next.js expects catch-all segments to be placed in their own folder and to be the last part of the URL. To resolve this, try restructuring your folder like this:

app/api/auth/[...nextauth]/route.js

this should fix the issue.

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Rahul

79260618

Date: 2024-12-07 12:45:12
Score: 2
Natty:
Report link

You would need to create a Calculated Service Metric based on the request attribute, where you include the request attribute itself as a dimension. Then in Grafana you would use the calculated service metric name with the available dimension.

At least, I think that might work. :)

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Mark Tomlinson

79260617

Date: 2024-12-07 12:43:11
Score: 1.5
Natty:
Report link

can't we clear the innerHTML of the driver time to time to reduce DOM size?

Clear the DOM

driver.execute_script("document.body.innerHTML = '';")

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Starts with a question (0.5): can't we
  • High reputation (-1):
Posted by: KawaiKx

79260615

Date: 2024-12-07 12:42:11
Score: 2
Natty:
Report link

Your code is working as intended. You're using the Llama-2-7b-chat-hf model, which is designed to align with human preferences and conversational contexts. As a result, when presented with a straightforward and common prompt like yours, the model tends to generate responses with high confidence, leading to the observed probabilities. If you were to ask a less common question, you would likely notice that the probabilities decrease, reflecting the model's uncertainty in those scenarios.

Reasons:
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: Ali Moameri

79260607

Date: 2024-12-07 12:38:10
Score: 1
Natty:
Report link

Encountered the same issue a while ago. Fb support admitted it’s a bug and they’re working on it.

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Single line (0.5):
  • High reputation (-1):
Posted by: Igor Loskutov

79260606

Date: 2024-12-07 12:38:10
Score: 4
Natty: 4.5
Report link

Future peeps can find this in the docs for the ux Ext.ux.TabReorderer : https://docs.sencha.com/extjs/7.8.0/classic/Ext.ux.TabReorderer.html

Reasons:
  • Probably link only (1):
  • Low length (1.5):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: Dawesi

79260604

Date: 2024-12-07 12:37:09
Score: 0.5
Natty:
Report link

At top of the page replace

<!DOCTYPE html>

with

<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-4.dtd">

And then close the html file and reopen. Warning should be gone without using thymeleaf plugin (Ultimate edition)

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Munish Mehta

79260598

Date: 2024-12-07 12:34:08
Score: 0.5
Natty:
Report link

To enable Azure AD authentication in your Angular application and trigger the login popup (or redirect, depending on your preference), you need to configure the client side alongside the server.

Microsoft provides a comprehensive guide on how to enable authentication in Angular using Azure AD. This guide explains the process step by step.

Azure offers two key libraries to facilitate this integration:

To implement Azure AD authentication, just follow the official documentation to configure your application. The setup includes registering your app in Azure AD, updating the angular configuration, and using the MsalService to handle login flows.

By correctly setting up the libraries, you can choose between a popup or redirect flow for authentication based on your application's requirements.

Reasons:
  • Blacklisted phrase (1): This guide
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: T. Jami

79260597

Date: 2024-12-07 12:34:08
Score: 3
Natty:
Report link

I wrote it like this in my CSS:

font-family: Harlow Solid Italic, cursive;

It works when I use it, so I hope this can be of help to you.

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Low reputation (1):
Posted by: Missmimi

79260595

Date: 2024-12-07 12:33:07
Score: 9.5 🚩
Natty: 6
Report link

bro can u please i need help urgently, i followed all the answers but i still cant fix this same error, i am trying to set up curl in VScode using mingw but i am not able to get it working, i keep getting the undefined reference error !!!

Reasons:
  • Blacklisted phrase (0.5): i need
  • Blacklisted phrase (1): i am not able to
  • Blacklisted phrase (1): i am trying to
  • Blacklisted phrase (2.5): i need help
  • RegEx Blacklisted phrase (2): urgently
  • Low length (0.5):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: Zuhayr Danish

79260593

Date: 2024-12-07 12:32:06
Score: 0.5
Natty:
Report link

I had same issue and in my situation the solution was to just set the requests_pathname_prefix like this:

app = Dash(requests_pathname_prefix="/your_prefix/")

Setting the environment variable or both requests_pathname_prefix and routes_pathname_prefix lead to the site being unavailable.

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Amuoeba

79260586

Date: 2024-12-07 12:28:06
Score: 1.5
Natty:
Report link

Can anyone help me how to convert that public key into raw-signature/binary...

The posted key is a PEM encoded key in X.509/SPKI format for curve secp384r1. This can be converted into a DER encoded key with the posted OpenSSL statement:

openssl ec -pubin -in key.pem -out out.der -outform DER

This conversion corresponds to the removal of header, footer, all line breaks and Base64 decoding of the rest.

At the end of the DER encoded key is the public key in uncompressed format (referred to as pub in the OpenSSL printout via -text option). The uncompressed format for secp384r1 has a length of 97 bytes (0x04|<x>|<y>; <x> and <y> are the coordinates of the EC point, each 384/8=48 bytes long).
Therefore, to extract the uncompressed key from the DER encoded key, only the last 97 bytes need to be taken.

...and vice versa?

The first 23 bytes contain length information and algorithm OIDs. This byte sequence is curve-specific and its length information specifies a key in uncompressed format (i.e. the byte sequence of a different curve and/or a key in compressed format would be different). It can therefore be used as a prefix to convert a secp384r1 key in uncompressed format into a DER encoded key in X.509/SPKI format.

...but it would be better if there is any standard command using openssl...

OpenSSL does not (to my knowledge) support the direct conversion of PEM/DER encoded public keys into the uncompressed (or compressed) format or vice versa.


For the sake of completeness: With the option -conv_form compressed in the OpenSSL statement above, the compressed format (<a>|<x>, with <a> = 0x02 for even <y> and <0x03> for odd <y>) can be used instead of the uncompressed format. This has a length of 49 bytes for secp384r1.
A DER (or PEM) encoded key can be easily analyzed when decoded with an ASN.1/DER parser, e.g. here for the posted key.

Reasons:
  • Blacklisted phrase (1): help me
  • RegEx Blacklisted phrase (3): Can anyone help me
  • Long answer (-1):
  • Has code block (-0.5):
  • Contains question mark (0.5):
  • Starts with a question (0.5): Can anyone help me
  • High reputation (-2):
Posted by: Topaco

79260579

Date: 2024-12-07 12:24:05
Score: 1.5
Natty:
Report link

You can remove the second Person definition because it's already linked to this itemtype via the same itemid:

<div itemtype="https://schema.org/Person" itemscope="" itemid="https://website.com/name/#profile">
    <meta itemprop="name" content="MyName">
</div>
<div itemtype="https://schema.org/ImageObject" itemscope="">
    <link itemprop="url" href="https://website.com/img.jpg">
    <meta itemprop="creator" itemid="https://website.com/name/#profile" itemscope="">
</div>

Schema validation screenshot

Reasons:
  • Probably link only (1):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Cmastris

79260576

Date: 2024-12-07 12:22:04
Score: 1.5
Natty:
Report link

It is easy to use the built-in commands . Before that, set the write permissions for the app/Controllers directory

command('make:controller API/Post')
Reasons:
  • Low length (1):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: ozornick

79260571

Date: 2024-12-07 12:17:03
Score: 1
Natty:
Report link

Ok, I realized what was the problem. What I missed was that matches[node_metadata['name']] returns a list of TSNode, not just one.

Doing matches[node_metadata['name']][1] instead works as expected.

Amazing what taking a break can do sometimes.

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (0.5):
Posted by: Antiphon0x

79260570

Date: 2024-12-07 12:17:03
Score: 2.5
Natty:
Report link

Operating in a D2D temperature but it's reflecting in a shadow the temperature movement is only 4 to 6 M off of ground footage but it carries 2 in above ground and it processes on the arms and legs

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: Melissa Sword

79260568

Date: 2024-12-07 12:16:03
Score: 3
Natty:
Report link

Yes. There is a view qsys2.sysfiles that has this information. There is a link to this view in the IBM online documentation for the (very complex) QDBRTVFD API.

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: TRS80 Model1

79260558

Date: 2024-12-07 12:10:01
Score: 0.5
Natty:
Report link

I get following error: AADSTS9002325: Proof Key for Code Exchange is required for cross-origin authorization code redemption.

To resolve the above issue, I added the below redirect URL to the Web Platform in the Api App registration.

http://localhost:8000/docs

enter image description here

After adding the redirect URL, I ran the application.

enter image description here

After clicking the Authorize button, I selected my account.

enter image description here

I successfully logged in without any issues.

enter image description here

Reasons:
  • RegEx Blacklisted phrase (1): I get following error
  • Has code block (-0.5):
Posted by: Aslesha Kantamsetti

79260547

Date: 2024-12-07 12:01:59
Score: 3
Natty:
Report link

SOLUTION for me

Thanks to Rakesh's comment, I installed @jest/globals and imported expect from that. I also set esModuleInterop to false in my tsconfig and installed this package: @types/testing-library__jest-dom

Now my code is without red squiggly lines :)

Reasons:
  • Blacklisted phrase (0.5): Thanks
  • Low length (0.5):
  • No code block (0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: Daniel Erdos

79260546

Date: 2024-12-07 12:01:59
Score: 1.5
Natty:
Report link

I was stuck on this for ages, but ChatGPT came to my rescue. It was a keyboard setting on my Mac that had converted the hyphens, so instead of displayed two hyphens (--) resulted in an unrecognised (–) causing an argument error because Hardhat doesn't recognise this syntax.

To fix I went to System Preferences and changed this:

Reasons:
  • No code block (0.5):
  • Low reputation (1):
Posted by: Jason Whittaker

79260545

Date: 2024-12-07 12:00:59
Score: 2
Natty:
Report link

I fixed the issue by updating to .NET 9. In VS 2022 i also had to click Tools => Options, and then enabling "Enable New .NET 9+ Mono Debugger"

Visual studio settings

Reasons:
  • Whitelisted phrase (-2): I fixed
  • Probably link only (1):
  • Low length (1):
  • No code block (0.5):
  • Self-answer (0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: Steffan Pallesen

79260541

Date: 2024-12-07 11:57:59
Score: 2.5
Natty:
Report link

You can pass an array of parameters into get_terms.

get_terms(array(
'taxonomy' => 'listing-categories',
'parent'   => 0
));

parent 0 means top level terms.
https://developer.wordpress.org/reference/functions/get_terms/

Reasons:
  • Probably link only (1):
  • Low length (1):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Eloi

79260539

Date: 2024-12-07 11:54:56
Score: 9 🚩
Natty: 5.5
Report link

I have given access to my google account. Can you please tell me how to remove access now. Can I do anything now? The code is similar to the following image. enter image description here

Reasons:
  • Blacklisted phrase (1): Can I do
  • Blacklisted phrase (1): enter image description here
  • Blacklisted phrase (1.5): tell me how to
  • RegEx Blacklisted phrase (2.5): Can you please tell me how
  • Low length (1):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Low reputation (1):
Posted by: Fatema Zohra Prottyasha

79260531

Date: 2024-12-07 11:49:55
Score: 1
Natty:
Report link

The issue happens because Google/Apple Pay uses a simplified checkout flow, which doesn't trigger your custom shipping options.

How to Fix

  1. Check plugin compatibility with Google/Apple Pay.
  2. You may need a custom code to make your custom shipping options work.
  3. Try disabling other plugins to identify conflicts.
  4. Alternatively, use a different payment gateway that supports your shipping methods. You’re not stuck with default shipping—adjustments are needed for compatibility with Google/Apple Pay.

If you like my answer, support me on wholesalers.

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Melton Classics

79260527

Date: 2024-12-07 11:46:55
Score: 1.5
Natty:
Report link

FormLabel is a general-purpose label used for form controls like checkboxes, radio buttons, or switches and typically paired with FormControl. It is styled more generically and is not specifically tied to text input fields.

InputLabel is specifically designed to label input fields (e.g., TextField, Select) and works seamlessly with form components like TextField and Select. It integrates features like floating labels when the input is focused or has a value.

Reasons:
  • No code block (0.5):
  • Low reputation (1):
Posted by: Nodirbek

79260523

Date: 2024-12-07 11:44:54
Score: 2.5
Natty:
Report link

If you're struggling with localization in a Laravel + Inertia.js (Vue.js) setup, I've got a solution that might simplify your process. Check this repo: 👉 https://github.com/abdessamadbettal/laravel-starter

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Abdessamad Battal

79260518

Date: 2024-12-07 11:41:53
Score: 3
Natty:
Report link

Checked. The trouble is Debug/Release library. In linker there should be .lib name according to your project Debug/Release. For Debug the .lib is name-d.lib (with -d.lib).

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Low reputation (1):
Posted by: valerk

79260516

Date: 2024-12-07 11:40:52
Score: 4
Natty: 5
Report link

same here why does this happen

Reasons:
  • Low length (2):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: Dominic Mathina

79260513

Date: 2024-12-07 11:34:51
Score: 1
Natty:
Report link

Solved!

Things I had to do:

Breakthrough:

When creating the client, Client ID must match the Issuer value sent in AuthNRequest because Keycloak pulls the issuer from the Authn SAML request and match it to a client by this value.

Next thing that needs to be done is to set IDP-Initiated SSO URL name. Leaving this blank will disable IDP initiated flow. The target URL that you need to reference from your browser will be in the following format:

The target Identity Provider (IdP)-initiated SSO URL is the Assertion Consumer Service (ACS) endpoint of your application. This is the endpoint where service you're integrating with, acting as the IdP, sends the SAML assertion after authenticating the user. This URL must be registered with service you're integrating with as part of the SAML integration, ensuring that SAML assertions are securely and correctly routed to your application.

Next, under Advanced tab, we need to set Assertion Consumer Service POST Binding URL. This should be the URL to your backend application that just do the redirect to your frontend application. Particularly in my case, I configured this endpoint on Ingress in way it does Permanent Redirect (301) to my frontend application (whenever it match https://myapp.com/saml-continue URL). However, it is also possible just to open simple endpoint in your backend server which will do the redirect to frontend.

Reasons:
  • Long answer (-1):
  • No code block (0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: Vujasinovic

79260512

Date: 2024-12-07 11:34:51
Score: 2
Natty:
Report link

It is likely the link security analysis tool from the email provider that parse and fuzzle and try the link to test it prior to deliver it to the client's inbox.

Like Microsoft Defender, Proofpoint, etc

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Pierre-Luc S.

79260495

Date: 2024-12-07 11:21:48
Score: 3.5
Natty:
Report link

I have just set the wrong domain... I changed the settings to accept tokens from every origin.

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Self-answer (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: erfin

79260488

Date: 2024-12-07 11:15:47
Score: 3.5
Natty:
Report link

It is a problem in computer CPU ram, I restarted my computer and everything seems to be fine now!

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Self-answer (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: LearnerZech

79260470

Date: 2024-12-07 11:05:44
Score: 1.5
Natty:
Report link
.goog-te-banner-frame.skiptranslate {
    display: none !important;
}
body {
    top: 0px !important;
}

for some browser this command stil doesnt work, so you should another command, and it would be like this :

iframe.skiptranslate {
    visibility: hidden !important;
}

.goog-te-banner-frame.skiptranslate {
    display: none !important;
}
body {
    top: 0px !important;
}
Reasons:
  • Blacklisted phrase (1): doesnt work
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Satriyo Rizkyansah

79260467

Date: 2024-12-07 11:04:43
Score: 4
Natty:
Report link

You're querying Users with a capital U, in contrast to your initial table check. Could that be it?

Reasons:
  • Low length (1):
  • Has code block (-0.5):
  • Ends in question mark (2):
  • Single line (0.5):
  • Low reputation (1):
Posted by: Cmastris

79260466

Date: 2024-12-07 11:04:43
Score: 1
Natty:
Report link
  1. I would try to not use any serial component here, as this will only work with serially connected printers
  2. If still going down the serial route I'd add \.\ before the COM3 in the code shown above as that would work with COM port numbers > 10 then.
  3. There is an API in Windows which can be used to send raw commands to a printer. Using that would mean that it won't matter how the printer is connected to the computer.
Reasons:
  • No code block (0.5):
  • Low reputation (0.5):
Posted by: Markus

79260462

Date: 2024-12-07 10:58:42
Score: 2
Natty:
Report link

It looks like now you need to add "debugpy.debugJustMyCode": false, to your user settings.json file in vscode. Changing the launch.json didn't work for me.

Reasons:
  • Low length (1):
  • Has code block (-0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: Logan Brase

79260458

Date: 2024-12-07 10:54:41
Score: 1
Natty:
Report link

The error occurs because CALL SYSPROC.ADMIN_CMD is a "forbidden statement" within compound SQL blocks in DB2 LUW 11.5. This restriction ensures transactional integrity, as ADMIN_CMD performs high-privilege operations.

Solutions:

1.Move Outside Block: Run CALL SYSPROC.ADMIN_CMD before or after the compound SQL block. sql code : CALL SYSPROC.ADMIN_CMD('REORG TABLE my_table'); BEGIN ATOMIC -- Other operations END;

2.Use a Wrapper Procedure: Encapsulate ADMIN_CMD in a stored procedure and call it separately. sql code : CREATE PROCEDURE RUN_REORG() BEGIN CALL SYSPROC.ADMIN_CMD('REORG TABLE my_table'); END; CALL RUN_REORG();

3.Transactional Separation: Keep ADMIN_CMD in standalone transactions for conflict-free execution.

For in-depth guidance on DB2 performance tuning and advanced SQL concepts, explore the DB2 LUW Administrator Course at VTUIT.COM.

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Techie

79260456

Date: 2024-12-07 10:53:41
Score: 1
Natty:
Report link

One more workaround:

RES=$(jq '.test = "test_val"' sample.json) && echo -e "$RES" > sample.json
  1. Save result of jq usage to variable,
  2. If (1) was successfull - echo variable, keeping linebreaks,
  3. Write terminal output to original file.
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Dmitry Petrouk

79260447

Date: 2024-12-07 10:47:40
Score: 3
Natty:
Report link

This means that the condition in the assertion is wrong. That is, cost.size() is not equal to torch.Size([1]). You should check the condition and debug.

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: zhikun zhao

79260440

Date: 2024-12-07 10:44:39
Score: 1
Natty:
Report link

You can manually call the onchange and onunfoucs method code:

function update (elem) {
  if (typeof elem.onchange == "function") {
    elem.onchange()
  }
  if (typeof elem.onunfoucs == "function") {
    elem.onunfoucs()
  }
}

call update() with the input element after every set value

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: 佩奇君

79260435

Date: 2024-12-07 10:40:38
Score: 1.5
Natty:
Report link

I am updating old Rails apps that worked with jquery and $ajax(), and that still works after the update. I would like to change the ajax call for a fetch() with .js.erb and params, all seems well, but the html does not get replaced by the workbar_work partial. Any suggestions?

in controller:

def switch_state
  permitted_params = params.permit(:partial)
  @partial = permitted_params[:partial].to_s
  @exercise = current_exercise  # defined somewhere else
  respond_to do |format|
     format.js
  end
end

in switch_state.js.erb

$('#workbar_switch').html("<%= j render(partial: @partial, :locals => {exercise: @exercise@}) %>");

the fetch call

function switchState(partial, exercise){
  const params = new URLSearchParams();
  params.append('partial', partial);

  fetch("/work/switch_state", {
    method: 'POST',
    headers: {
        'Accept': 'text/javascript, application/javascript, application/ecmascript, application/x-ecmascript',
        'X-CSRF-Token': document.querySelector('meta[name="csrf-token"]').content,
        'Content-Type': 'application/x-www-form-urlencoded'
    },
    body: params
  })
  .then(response =>  {
    if (!response.ok) {
      throw new Error('Network response was not ok');
    }
    return response.text()
  })  
  .then(responseText => {
    console.log("received js", responseText)
  })
  .catch(error => {
    console.log('Update failed', error)
    console.log('error', error.message)
  })
  .finally(() => {
  })
}

rails server log - seems to look ok:

Started POST "/work/switch_state" for ::1 at 2024-12-07 11:19:49 +0100
Processing by WorkController#switch_state as JS
  Parameters: {"partial"=>"workbar_work"}
  Exercise Load (0.3ms)  SELECT "exercises".* FROM "exercises" WHERE "exercises"."unit" = $1 LIMIT $2  [["unit", "ct100_1_ma3"], ["LIMIT", 1]]
  ↳ app/models/exercise.rb:81:in `find_exercise'
  CACHE Exercise Load (0.0ms)  SELECT "exercises".* FROM "exercises" WHERE "exercises"."unit" = $1 LIMIT $2  [["unit", "ct100_1_ma3"], ["LIMIT", 1]]
  ↳ app/models/exercise.rb:81:in `find_exercise'
  Rendering work/switch_state.js.erb
  Rendered work/_workbar_work.html.erb (Duration: 0.6ms | Allocations: 351)
  CACHE Exercise Load (0.0ms)  SELECT "exercises".* FROM "exercises" WHERE "exercises"."unit" = $1 LIMIT $2  [["unit", "ct100_1_ma3"], ["LIMIT", 1]]
  ↳ app/models/exercise.rb:81:in `find_exercise'
  Rendered work/switch_state.js.erb (Duration: 3.4ms | Allocations: 2535)
Completed 200 OK in 17ms (Views: 5.4ms | ActiveRecord: 2.1ms | Allocations: 9998)

browser console:

  [Log] response – Response {type: "basic", url: "http://localhost:3000/work/switch_state", redirected: false, …} (ctrl-dc34a42ad73de8380cf755f815535ed1b8bfc04007d2b4f4fad4a1f130e93d45.js, line 183)
  [Log] received js – "$('#workbar_switch').html(\"<ul>\\n\t\\n\t<a title=\\\"Klicke hier für eine leichte Übung\\\" id=\\\"bug_click\\\" href=\\\"\\\">\\n\t<l…" (ctrl-dc34a42ad73de8380cf755f815535ed1b8bfc04007d2b4f4fad4a1f130e93d45.js, line 190)

"$('#workbar_switch').html("\n \n <a title=\"Klicke hier für eine leichte Übung\" id=\"bug_click\" href=\"\">\n <li id=\"workbar_bug\">\n <i class=\"fa fa-bug\"><\/i>\n <span id=\"bug_text\"><\/span>\n <\/li>\n<\/a> <a title=\"andere Stufe\" id=\"back_to_base_click\" href=\"\">\n <li id=\"change_level\">\n <i class=\"fa fa-signal\"><\/i>\n andere Stufe<\/span>\n <\/li>\n<\/a> \n<\/ul>\n\n<form id=\"answerForm\"\n name=\"answerForm\"\n action=\"#dummy\">\n\n <div id= \"answer_field\"\n title= \"Tippe Deine Antwort hier\">\n <input type = \"text\"\n id = \"txtanswer\"\n name = \"txtanswer\"\n size = \"3\"\n maxlength = \"3\" />\n <\/div>\n \n <button type=\"submit\" \n id=\"submit_answer\">\n <i class=\"fa fa-level-down fa-rotate-90\"><\/i>\n OK<\/span>\n <\/button>\n\n<\/form>\n\n");"

Reasons:
  • RegEx Blacklisted phrase (2): Any suggestions?
  • Long answer (-1):
  • Has code block (-0.5):
  • Contains question mark (0.5):
  • Low reputation (0.5):
Posted by: Daniela

79260434

Date: 2024-12-07 10:40:38
Score: 2
Natty:
Report link

I've faced the same problem. Locally, with Azure Functions Core Tools I could upload the functions without any problem. But deploying with Github Actions just won't work. I didn't solve it to that time. But here is a similar issue on Github, worth a look: https://github.com/Azure/functions-action/issues/192#issuecomment-1782920933

Let me know if this works for you!

Reasons:
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Latzox

79260433

Date: 2024-12-07 10:39:38
Score: 1
Natty:
Report link

It may be useful if you need to stay the axis:

ax.spines[['top', 'right']].set_visible(False)
Reasons:
  • Low length (1):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Vlad

79260422

Date: 2024-12-07 10:34:37
Score: 3
Natty:
Report link

i downloaded aromafm.zip to my sd and put it into the galaxy tab 5 that im trying to bypass/erase the pattern lock bkuz i forgot my pattern lock and email i used back 3 yrs ago bfor i was sent to prison . so i downloaded the .zip file to my sd card put the sd card into my galaxy tab 5 held the lock and volume up buttons at the same time and the list pops up of options in recoveery mode like 4th or 5th one down said upload from sd card and use volume up n down to select and lock button to enter and then it says footer not found error 21 something about a verification signature any ideas what to do, i had read mabey mount or format the sd card and then try it again so i did that still nothing....

Reasons:
  • Blacklisted phrase (1): any ideas
  • Long answer (-0.5):
  • No code block (0.5):
  • Unregistered user (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: kbaby

79260417

Date: 2024-12-07 10:32:36
Score: 3
Natty:
Report link

We have a VPN and you will never block it. You will get tired of chasing the tail))

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: Serjaru

79260413

Date: 2024-12-07 10:28:35
Score: 3
Natty:
Report link

You can not use find and replace for tablepress plugin, because it have no tables in database and all the tables saved as json file. I believe it is an important problem of this plugin, but it makes it faster.

Reasons:
  • Blacklisted phrase (1): this plugin
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Sina Fekrazadeh

79260412

Date: 2024-12-07 10:27:34
Score: 5
Natty:
Report link

sudo: a password is required in jenkins

After adding it, it works fine.

Reasons:
  • Probably link only (1):
  • Low length (2):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: 이상빈

79260409

Date: 2024-12-07 10:25:33
Score: 1.5
Natty:
Report link

In the build_client function of cli_util.py, locate and fix the relevant part like this:

if 'connection_timeout' not in ctx.obj: ctx.obj['connection_timeout'] = 60 # Default to 60 seconds

if ctx.obj['connection_timeout']: if 'read_timeout' in ctx.obj and ctx.obj['read_timeout']: client.base_client.timeout = (ctx.obj['connection_timeout'], ctx.obj['read_timeout']) else: client.base_client.timeout = (ctx.obj['connection_timeout'], client.base_client.timeout[1]) else: if 'read_timeout' in ctx.obj and ctx.obj['read_timeout']: client.base_client.timeout = (client.base_client.timeout[0], ctx.obj['read_timeout'])

./create_backup_from_onprem --config-file /home/oracle/.oci/config --profile DEFAULT --display-name oradb --availability-domain $AD --edition ENTERPRISE_EDITION_HIGH_PERFORMANCE --opc-installer-dir /home/oracle/oci/opc_installer/opc_installer --tmp-dir /home/oracle/oci/onprem_upload --compartment-id

Reasons:
  • Long answer (-0.5):
  • No code block (0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: Nishchal Junghare

79260406

Date: 2024-12-07 10:22:33
Score: 1
Natty:
Report link

It would appear that as of 2024 it does. I timed a cp of a 3GB file from the nfs mounted drive to the same drive and it took 0.054 seconds (the underlying disks on the server are a btrfs CoW filesystem).

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: Daniel Kinsman

79260400

Date: 2024-12-07 10:16:32
Score: 0.5
Natty:
Report link

In recent versions of Docker Desktop there is only a single file that contains all volumes:

/Users/{YourMacOsUserName}/Library/Containers/com.docker.docker/Data/vms/0/data/Docker.raw

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (0.5):
Posted by: Bence Szalai

79260396

Date: 2024-12-07 10:13:31
Score: 3
Natty:
Report link

or, you can make your button transparent and send it back, below of the button

Reasons:
  • Low length (1.5):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: Farkas János

79260391

Date: 2024-12-07 10:11:31
Score: 1
Natty:
Report link

I had the same problem and solved it simply by removing the constant Trace and unticking the "Optimize code" box in the Build section of the UWP project for all platforms (X64, X86, ARM) in the "Release" configuration. The problem likely was that these options were not identical for the 3 platforms

Reasons:
  • Whitelisted phrase (-1): I had the same
  • Low length (0.5):
  • No code block (0.5):
  • Low reputation (1):
Posted by: Frank Chauvallon

79260390

Date: 2024-12-07 10:11:31
Score: 1
Natty:
Report link

Here is my answer to your questions:

Why does a IO device(NIC/SSD) need a IO page table for DMA?

An IO device does not necessarily need an IO page table. If the system supports IOMMU with Shared Virtual Addressing (SVA), the device can use a process's page table environment instead. This allows DMA operations to use virtual addresses (VA) directly instead of requiring IO virtual addresses (IOVA). For more details, refer to the article 'Shared Virtual Addressing for IOMMU': https://lwn.net/Articles/747230/.

If the IOVA is used only once and is not reused after a single DMA transfer, then is it really necessary to manage the IOVA-PA mapping through a page table?

The IO page table is used by IOMMU hardware to translate IOVA to physical addresses (PA). The IO page table is managed by the operating system, not by individual processes. It means IO page table is a shared resource. Even if the IOVA is used only once, the page table ensures hardware-level address translation and isolation, which are critical for system security and performance.

Is it possible that a single DMA operation uses the IOVA multiple times?

Yes, a single DMA operation can use the same IOVA multiple times. However, this is not recommended due to potential performance overheads and complexity in managing the mapping.

My proposal:

If you prefer to avoid using an IO page table, consider using Shared Virtual Addressing (SVA), which allows DMA operations to leverage process-level virtual addresses without the need for IOVA.

Reasons:
  • Long answer (-1):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Low reputation (1):
Posted by: Wan Heo

79260382

Date: 2024-12-07 10:03:30
Score: 0.5
Natty:
Report link

this needs explicit type narrowing -

if (typeof result === "object" && !Array.isArray(result)) {
  if (result?.error) {
     log(result.error)
  }
} else {
  if (Array.isArray(result)) {
    setData(result);
  }
}
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Self-answer (0.5):
Posted by: Ranu Vijay

79260380

Date: 2024-12-07 10:03:30
Score: 3
Natty:
Report link

I am not sure what is your exact question, but you can convert the time zone with a function in PowerAutomate: convertTimeZone(), etc: convertFromUtchttps://learn.microsoft.com/en-us/power-automate/convert-time-zone

Reasons:
  • Blacklisted phrase (1): what is your
  • Low length (0.5):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (0.5):
Posted by: Farkas János

79260378

Date: 2024-12-07 09:59:29
Score: 2.5
Natty:
Report link

To achieve that you can use powershell

Reasons:
  • Whitelisted phrase (-1.5): you can use
  • Low length (2):
  • No code block (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: Nick Pap

79260374

Date: 2024-12-07 09:58:28
Score: 1.5
Natty:
Report link

It is an interesting question that has multiple possible solutions or needs further explanations.

Your issue generally is not connected to SqlAlchemy, it is a very common Python problem. However, here it is triggered by specific SqlAlchemy behavior.

I'll try to explain the problem as I see it and you'll correct me if I misunderstand the situation.

From SqlAlchemy point of view: why do you try to use class reference instead of string reference? As far as I understand, class needs to be imported at the moment of execution, while string is processed by SqlAlchemy itself without the need to load the class. I'm using string references everywhere and haven't, so far, seen any tutorials that say I'm doing it wrong.

Also: why do you need relationship(Left) or relationship("Left") at all? You already has "Left" in lefts: Mapped[InstrumentedList["Left"]]. It is not an error, it is, I think, redundant. I use it this way:

breed_groups: Mapped[Optional[list["BreedGroup"]]] = relationship(secondary=user2breed_group)

And it works fine, as far as I can judge. What are you trying to achieve here?

Now, for your actual question, which is not about SqlAlchemy, but about Python.

Generally, you have 2 classes which reference each other. You try to execute a class Right, which imports class Left, but class Left imports class Right, so it tries to import it back, but can't, because class Right imports class Left. And so on, that's a circle. It is a very common problem in Python. It doesn't matter if you are using SqlAlchemy or not, if you are trying to import Left from Right AND Right from Left, it will tell you, at a runtime, that you can't do that. But obviously you need that connection, and often.

The solution (as I understand it, because there are as many opinions on the matter in the Internets and there are python programmers) is to load and initialise both classes before runtime, so at runtime they were both loaded and cached and could reference each other without problem. You can't do it from inside their files, it's just not how Python runs.

What I do: I add more files. First, I use init.py file for a module (lets call it "models") where both my classes are stored, in this way:

from .left import Left
from .right import Right

There are no imports inside my 'left.py' and 'right.py' classes! At least no imports referencing each other.

Then, when I need the classes to be actually USED, executed, be it, for example, for create_all, I load and initialise the module in full:

from models import *

At this point models' init.py loads and caches both Right and Left classes, and when any of the classes is run, the other, referenced, class is already loaded and cached and nothing needs to be imported. So when Right tries to do something with Left, Left is already loaded and initiated by models and vice versa.

@declared_attr, @classmethod and any other "solutions" do not, in any way, influence the problem of "file right.py imports from file left.py which imports from file right.py"

Also, do you understand what you are doing with TYPE_CHECKING? It is a VERY specific boolean needed for very specific reason (purely as a technical aid for IDEs and other tools) and I have a suspicion you don't understand why it's there and what does it does. I would advice you to not use it at all, despite what tutorials show, until you know why you need it. It may deceive you. It is always false at runtime, so none of your imports would actually work at runtime and other imports, non-obvious for you, would be used. Or not used. I don't really understand TYPE_CHECKING and never use it.

There are many, many, many tutorials and explanations about circular import and not all of them are any good, but you really should understand the concept, because it's one of the main problems and flaws of Python, in my opinion, and you would have to work around it for your whole programming life. Not that I have that much experience with Python, either. You may start with something like that https://medium.com/@hamana.hadrien/so-you-got-a-circular-import-in-python-e9142fe10591 and experiment further.

If I misunderstood something, I apologise, I'm using Python for less than half a year myself. If you want to correct me or add a question, please do. That goes for anyone who understand imports or SqlAlchemy better than me.

Reasons:
  • Blacklisted phrase (0.5): I need
  • Blacklisted phrase (0.5): medium.com
  • Long answer (-1):
  • Has code block (-0.5):
  • Contains question mark (0.5):
  • User mentioned (1): @declared_attr
  • User mentioned (0): @classmethod
  • Low reputation (0.5):
Posted by: Nikolajs Petrovs

79260348

Date: 2024-12-07 09:44:24
Score: 4
Natty:
Report link

Digital Marketing đang ngày càng trở thành yếu tố không thể thiếu cho các doanh nghiệp và cá nhân muốn xây dựng và phát triển thương hiệu trong thời đại công nghệ số. Với nhu cầu nhân lực chuyên nghiệp trong ngành ngày càng cao, các khóa học Digital Marketing được thiết kế để cung cấp kiến thức và kỹ năng từ cơ bản đến nâng cao. Vậy khóa học Digital Marketing bao gồm những nội dung gì? Hãy cùng tìm hiểu!

Reasons:
  • No code block (0.5):
  • Ends in question mark (2):
  • Single line (0.5):
  • Low reputation (1):
Posted by: Phu Tran

79260344

Date: 2024-12-07 09:42:23
Score: 3
Natty:
Report link

I would like to thank @kikon for the answer

box1: {
    type: "box",
    drawTime: "beforeDraw",
    yMin: 22,
    yMax: 40,
    backgroundColor: "rgba(255, 229, 153, 1)",
    borderColor: "rgba(100, 100, 100, 0.2)",
},

enter image description here

Reasons:
  • Probably link only (1):
  • Low length (0.5):
  • Has code block (-0.5):
  • User mentioned (1): @kikon
  • Self-answer (0.5):
  • Low reputation (0.5):
Posted by: Reydan Gatchalian

79260326

Date: 2024-12-07 09:28:20
Score: 1.5
Natty:
Report link

According to the Java documentation, an SQLException is thrown only when a database access error occurs. This can happen in the following situations:

Reasons:
  • No code block (0.5):
  • Low reputation (1):
Posted by: Mehrdad Bozorgmehr

79260314

Date: 2024-12-07 09:21:18
Score: 2.5
Natty:
Report link

transactions = [-100, -200, -100, 1000, 50, -90] l = (transactions) print(l) for i in range(l): if i > 0: print(suma(i))

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Low reputation (1):
Posted by: CN N

79260312

Date: 2024-12-07 09:19:18
Score: 1
Natty:
Report link

Step 1: Removing unused packages

!sudo apt autoremove

Step 2: Remove conflicting packages

!sudo apt-get remove --purge libnode-dev nodejs libnode72:amd64

Step 3: Update and install Node.js

!sudo apt-get update
!sudo apt-get install -y nodejs

Step 4: Verify the installation

!node -v
!npm -v
Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Low reputation (1):
Posted by: Ai_scanner Mit

79260311

Date: 2024-12-07 09:19:18
Score: 0.5
Natty:
Report link

Telegram
An error occurred:
PUBLIC_KEY_INVALID

Apart from the correct data from @jwilliamson45

Please note how to place the public_key. Here is an example that works for tests, Since the documentation of python-telegram-bot doesn't explain this in detail, it just mentions it (until today, December 7, 2024):

<?php
$tg_passport = empty($_GET["tg_passport"])? "":$_GET["tg_passport"];

?>
<!DOCTYPE html>
<html lang="en">
<head>
    <title> Telegram passport (test1) </title>
    <meta charset="utf-8">
    <meta content="IE=edge" http-equiv="X-UA-Compatible">
    <meta content="width=device-width, initial-scale=1" name="viewport">
</head>
<body>
    <h1>Telegram passport (test1)</h1>

    <?php
    if ($tg_passport == "cancel") {
        echo "Canceled!";
    }
    ?>
    <div id="telegram_passport_auth"></div>
</body>

<!--- Needs file from https://github.com/TelegramMessenger/TGPassportJsSDK downloaded --->
<script src="../telegram-passport.js"></script>
<script src="../uuid.min.js"></script>
<script>
    "use strict";

    var host = "https://your-host.net"

    var nonce = uuid.v4(), callback_url = host+"/apps/telegram_passport_auth",
    files_base_url = callback_url+"/files",
    files_dir = callback_url+"/files_saved";
    
    // Example of public key
    var p_k="-----BEGIN PUBLIC KEY-----\n"+
    "MIIBIjANBC\n"+
    "mPPAR7busb\n"+
    "TmxT4yQswX\n"+
    "2TLg46ccdi\n"+
    "Tbam9PQiw4\n"+
    "Sb7Tqii9xl\n"+
    "QQIAB\n"+
    "-----END PUBLIC KEY-----\n";
    
    Telegram.Passport.createAuthButton('telegram_passport_auth', {
        // ROLL BOT:
        bot_id: 999999999,
        // WHAT DATA YOU WANT TO RECEIVE:
        scope: {
            data: [{
                type: 'id_document',
                selfie: true
            }, 'address_document', 'phone_number', 'email'],
            v: 1
        },
        // YOUR PUBLIC KEY
        public_key: p_k,
        // YOUR BOT WILL RECEIVE THIS DATA WITH THE REQUEST
        nonce: nonce,
        // TELEGRAM WILL SEND YOUR USER BACK TO THIS URL
        callback_url: callback_url+"/?"
    });

</script>
</html>

The nonce is generated with uuid.v4() from uuid.min.js.

Maybe this detail influences or not in the error: PUBLIC_KEY_REQUIRED

Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • User mentioned (1): @jwilliamson45
  • Low reputation (1):
Posted by: Triplex

79260309

Date: 2024-12-07 09:17:18
Score: 3.5
Natty:
Report link

How about building the ONNX Runtime source code? You can run ONNX Runtime without relying on WinML or the .NET framework.

For your information - https://onnxruntime.ai/docs/build/inferencing.html

Reasons:
  • Low length (1):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Starts with a question (0.5): How
  • Low reputation (1):
Posted by: Wan Heo

79260307

Date: 2024-12-07 09:15:17
Score: 0.5
Natty:
Report link

As @dandavis says, I think you can do element.innerHTML to preserve formatting if what you mean by formatting is: list, font weight, font size, etc.

For example, for this page: https://www.linkedin.com/jobs/collections/hiring-in-network/?currentJobId=4093133656

I can do document.querySelector('article').innerHTML to obtain the job description with it's format as shown here:

<div class="jobs-description__content jobs-description-content
">
    <div class="jobs-box__html-content
  gCeSRvuwijzmTJHsHVmaREDPgtRKEJIw
  t-14 t-normal
  jobs-description-content__text--stretch" id="job-details" tabindex="-1">
        <h2 class="text-heading-large">
            About the job
        </h2>

        <!----> <div class="mt4">
            <p dir="ltr">
                <span><p><!---->Hi! We are GeekGarden, a consultant IT
                        company.<!----></p></span><span><p><!---->We're hiring
                        the best candidate for
                        position:<!----></p></span><span><p><span><br></span></p></span><span><p><!---->Backend
                        Developer Golang<!----><span><strong><span
                                    class="white-space-pre">
                                </span>OR<!----></strong></span><span
                            class="white-space-pre">
                        </span>Ruby<!----></p></span><span><p><span><br></span></p></span><span><p><!---->This
                        position is for our client : SaaS
                        company<!----></p></span><span><p><!---->Onsite
                        Yogyakarta<!----></p></span><span><p><!---->For 6 months
                        contract
                        base<!----></p></span><span><p><span><br></span></p></span><span><p><!---->Job
                        Descriptions<!----></p></span><span>
                    <ul><span><li><!---->Design, develop, and maintain backend
                                services and APIs using Golang or using Ruby on
                                Rails<!----></li></span><span><li><!---->Write
                                clean, maintainable, and efficient
                                code<!----></li></span><span><li><!---->Implement
                                scalable server-side logic and optimize
                                applications for
                                performance<!----></li></span><span><li><!---->Collaborate
                                with the product team to understand requirements
                                and translate them into technical
                                specifications<!----></li></span><span><li><!---->Integrate
                                third-party APIs and services as
                                needed<!----></li></span><span><li><!---->Identify,
                                troubleshoot, and resolve performance
                                bottlenecks and
                                bugs<!----></li></span><span><li><!---->Conduct
                                code reviews and provide constructive feedback
                                to other team
                                members<!----></li></span><span><li><!---->Ensure
                                data security, system scalability, and high
                                availability<!----></li></span><span><li><!---->Participate
                                in the full software development lifecycle,
                                including testing and
                                deployment<!----></li></span></ul>
                </span><span><p><span><br></span></p></span><span><p><!---->Job
                        Requirements<!----></p></span><span>
                    <ul><span><li><!---->Bachelor's degree in Computer Science,
                                Engineering, or a related field (or equivalent
                                experience)<!----></li></span><span><li><!---->3+
                                years of proven experience as a Backend
                                Developer<!----></li></span><span><li><!---->Strong
                                expertise in Golang or Ruby on Rails programming
                                languages<!----></li></span><span><li><!---->Experience
                                with RESTful APIs, microservices architecture,
                                and web service
                                frameworks<!----></li></span><span><li><!---->Familiarity
                                with SQL and NoSQL databases (e.g., PostgreSQL,
                                MySQL, MongoDB,
                                Redis)<!----></li></span><span><li><!---->Understanding
                                of version control systems (e.g.,
                                Git)<!----></li></span><span><li><!---->Strong
                                problem-solving skills and the ability to write
                                efficient, scalable
                                code<!----></li></span><span><li><span><strong><!---->Willing
                                        to work with project-based
                                        contract<!----></strong></span></li></span><span><li><span><strong><!---->Willing
                                        to join
                                        immediately<!----></strong></span></li></span><span><li><span><strong><!---->Willing
                                        to work onsite in
                                        Yogyakarta<!----></strong></span></li></span></ul>
                </span>
            </p>
            <!----> </div>
    </div>
    <div class="jobs-description__details">
        <!----> </div>
</div>

<div class="jobs-description__content jobs-description-content
">
    <div class="jobs-box__html-content
  gCeSRvuwijzmTJHsHVmaREDPgtRKEJIw
  t-14 t-normal
  jobs-description-content__text--stretch" id="job-details" tabindex="-1">
        <h2 class="text-heading-large">
            About the job
        </h2>

        <!----> <div class="mt4">
            <p dir="ltr">
                <span><p><!---->Hi! We are GeekGarden, a consultant IT
                        company.<!----></p></span><span><p><!---->We're hiring
                        the best candidate for
                        position:<!----></p></span><span><p><span><br></span></p></span><span><p><!---->Backend
                        Developer Golang<!----><span><strong><span
                                    class="white-space-pre">
                                </span>OR<!----></strong></span><span
                            class="white-space-pre">
                        </span>Ruby<!----></p></span><span><p><span><br></span></p></span><span><p><!---->This
                        position is for our client : SaaS
                        company<!----></p></span><span><p><!---->Onsite
                        Yogyakarta<!----></p></span><span><p><!---->For 6 months
                        contract
                        base<!----></p></span><span><p><span><br></span></p></span><span><p><!---->Job
                        Descriptions<!----></p></span><span>
                    <ul><span><li><!---->Design, develop, and maintain backend
                                services and APIs using Golang or using Ruby on
                                Rails<!----></li></span><span><li><!---->Write
                                clean, maintainable, and efficient
                                code<!----></li></span><span><li><!---->Implement
                                scalable server-side logic and optimize
                                applications for
                                performance<!----></li></span><span><li><!---->Collaborate
                                with the product team to understand requirements
                                and translate them into technical
                                specifications<!----></li></span><span><li><!---->Integrate
                                third-party APIs and services as
                                needed<!----></li></span><span><li><!---->Identify,
                                troubleshoot, and resolve performance
                                bottlenecks and
                                bugs<!----></li></span><span><li><!---->Conduct
                                code reviews and provide constructive feedback
                                to other team
                                members<!----></li></span><span><li><!---->Ensure
                                data security, system scalability, and high
                                availability<!----></li></span><span><li><!---->Participate
                                in the full software development lifecycle,
                                including testing and
                                deployment<!----></li></span></ul>
                </span><span><p><span><br></span></p></span><span><p><!---->Job
                        Requirements<!----></p></span><span>
                    <ul><span><li><!---->Bachelor's degree in Computer Science,
                                Engineering, or a related field (or equivalent
                                experience)<!----></li></span><span><li><!---->3+
                                years of proven experience as a Backend
                                Developer<!----></li></span><span><li><!---->Strong
                                expertise in Golang or Ruby on Rails programming
                                languages<!----></li></span><span><li><!---->Experience
                                with RESTful APIs, microservices architecture,
                                and web service
                                frameworks<!----></li></span><span><li><!---->Familiarity
                                with SQL and NoSQL databases (e.g., PostgreSQL,
                                MySQL, MongoDB,
                                Redis)<!----></li></span><span><li><!---->Understanding
                                of version control systems (e.g.,
                                Git)<!----></li></span><span><li><!---->Strong
                                problem-solving skills and the ability to write
                                efficient, scalable
                                code<!----></li></span><span><li><span><strong><!---->Willing
                                        to work with project-based
                                        contract<!----></strong></span></li></span><span><li><span><strong><!---->Willing
                                        to join
                                        immediately<!----></strong></span></li></span><span><li><span><strong><!---->Willing
                                        to work onsite in
                                        Yogyakarta<!----></strong></span></li></span></ul>
                </span>
            </p>
            <!----> </div>
    </div>
    <div class="jobs-description__details">
        <!----> </div>
</div>

If this is not what you're looking for, then please specify what you mean by format

Reasons:
  • Long answer (-1):
  • Has code block (-0.5):
  • User mentioned (1): @dandavis
  • Low reputation (1):
Posted by: Daffa' Alexander

79260304

Date: 2024-12-07 09:14:17
Score: 0.5
Natty:
Report link

Scan the qrcode with the built-in camera app. It should give you an url, and you just have to click on it to open in the development build

Reasons:
  • Low length (1):
  • No code block (0.5):
  • High reputation (-1):
Posted by: Poptocrack

79260297

Date: 2024-12-07 09:07:15
Score: 1
Natty:
Report link

From 30th Oct 2024, Your Firebase project must be on the pay-as-you-go Blaze pricing plan.

You can check the updated policy here: https://firebase.google.com/docs/storage/web/start#before-you-begin

This is still free & available same as before, but Blaze plan is required to access this feature.

Reasons:
  • Low length (0.5):
  • No code block (0.5):
Posted by: ankushlokhande

79260292

Date: 2024-12-07 09:05:15
Score: 0.5
Natty:
Report link

Here is a working solution, but I'm not sure if it's ok.

if (criteria.getActive() != null) {
    specification = specification.and((root, query, builder) -> {
        HibernateCriteriaBuilder hb = (HibernateCriteriaBuilder) builder;
        JpaExpression<Duration> oneMinute = hb.durationScaled(root.get(Activity_.duration), Duration.ofMinutes(1));
        Expression<ZonedDateTime> result = hb.addDuration(root.get(Activity_.dateStart), oneMinute);
        if (criteria.getActive()) {
            return builder.greaterThanOrEqualTo(result, ZonedDateTime.now());
        }

        return builder.lessThan(result, ZonedDateTime.now());
    });
}
Reasons:
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: RexusGo

79260287

Date: 2024-12-07 09:00:12
Score: 6.5 🚩
Natty: 4.5
Report link

do you find the answer? it also happen in my react-js code .

Reasons:
  • RegEx Blacklisted phrase (2.5): do you find the
  • Low length (1.5):
  • No code block (0.5):
  • Contains question mark (0.5):
  • Single line (0.5):
  • Low reputation (1):
Posted by: kosar mohammadi

79260284

Date: 2024-12-07 08:55:11
Score: 1
Natty:
Report link

enter image description here struct MessageTextField: View {

@Binding var inputText: String  
@FocusState private var isFocused: Bool  

var body: some View {  
    VStack {  
        Spacer()  
        HStack(alignment: .bottom) {  
            ZStack(alignment: .bottomLeading) {  
                TextEditor(text: $inputText)  
                    .frame(minHeight: 36)  
                    .fixedSize(horizontal: false, vertical: true)  
                    .submitLabel(.done)  
                    .focused($isFocused)  
                    .multilineTextAlignment(.leading)  
                    .lineLimit(4)  
                    .font(.system(size: 15))  
                    .padding([.top, .bottom, .leading], 2)  
                    .accentColor(Color.green)  
                    .ignoresSafeArea(.keyboard, edges: .bottom)  
                    .overlay(  
                        // Placeholder  
                        Group {  
                            if inputText.isEmpty {  
                                Text("Enter your message")  
                                    .foregroundColor(.gray.opacity(0.5))  
                                    .font(.system(size: 15))  
                                    .padding(.leading, 6)  
                            }  
                        },  
                        alignment: .leading  
                    )  
                    .onSubmit {  
                        dismissKeyboard()  
                    }  
                    .onChange(of: inputText) { textInput in  
                        var newValue = textInput  
                        if textInput.count > 400 {  
                            newValue = String(textInput.prefix(400))  
                            if (textInput.last?.isNewline) ?? false {  
                                isFocused = false  
                            }  
                        }  
                        inputText = newValue  
                    }  
            }  
            
            // Mic Button  
            Button(action: {  
                // Add microphone action here  
            }) {  
                Image(systemName: "mic")  
                    .font(.system(size: 20))  
                    .foregroundColor(.green)  
            }  
            .padding(.bottom, 8)  
            
            // Send Button  
            Button(action: {  
                if !inputText.isEmpty {  
                    // Add send message action here  
                }  
            }) {  
                Image(systemName: "arrow.up.circle.fill")  
                    .font(.system(size: 20, weight: .bold))  
                    .foregroundColor(inputText.isEmpty ? .gray : .green)  
            }  
            .padding(.trailing, 4)  
            .padding(.bottom, 8)  
            .disabled(inputText.isEmpty)  
        }  
        .padding()  
        .background(  
            RoundedRectangle(cornerRadius: 10)  
                .fill(Color.white)  
                .overlay(  
                    RoundedRectangle(cornerRadius: 10)  
                        .stroke(Color.gray.opacity(0.5), lineWidth: 1)  
                )  
        )  
    }  
    .padding([.leading, .trailing], 20)  
}  

// Helper function to dismiss the keyboard  
private func dismissKeyboard() {  
    withAnimation(.easeInOut(duration: 0.3)) {  
        isFocused = false  
    }  
    UIApplication.shared.sendAction(#selector(UIResponder.resignFirstResponder), to: nil, from: nil, for: nil)  
}  

}

extension View {
func onEnter(@Binding of text: String, action: @escaping () -> ()) -> some View {
onChange(of: text) { newValue in
if let last = newValue.last, last == "\n" {
text.removeLast()
action()
}
}
}
}

Reasons:
  • Probably link only (1):
  • Long answer (-1):
  • Has code block (-0.5):
  • User mentioned (1): @escaping
  • Low reputation (0.5):
Posted by: Saurabh Sharma