instruction
stringlengths
0
30k
How to click the save or print button inside Google Chrome print window using selenium when the HTML page has shadow-root?
My opinion is try to Wrap your `SuperTextIconButton` with a `FittedBox`. Container( alignment: Alignment.center, // back icon height: Get.height * 0.0494, width: Get.width * 0.1, decoration: BoxDecoration( ...
I am creating a flask project and I have to write this in my html: `onclick="location.href="/article/{{ article["id"] }}""` But I need three separate sets of quotes to do it, is there anyway to insert something like backslash quote in python? I've tried using "" and '', also using \" and \' but I can't get any...
Multiple quote symbols in HTML code, Flask project
|html|
null
You can user wait for an event in below fashion as explained [here and it helps][1] var waitForRequestTask = page.WaitForRequestAsync("**/*logo*.png"); await page.ClickAsync(".foo"); var request = await waitForRequestTask; Alternatively expect can be used, then it will wait for it before movin...
I adjusted the for loop to make it a bit more easy to handle: for stage in df["Stage"].unique(): # for every unique stage subD = df[df["Stage"]==stage] # get the data for that specific case plt.scatter(x=subD["Cost"], # cost on x axis y=subD["Duration"], # duration on y ...
2 problems with the code: 1. Functional. By default, disk is closed when its corresponding handle is (which happens automatically when the program ends). So, the disk was opened (and shown in *Explorer*), but only for a very short period of time (after the *AttachVirtualDisk* call till program end), so you were not ...
I have some images and folders to rename. They are contained in the folder with the same filename as such. /abc123 /abc123/abc123.jpg None of the filenames or folder names have a dash which I want to add after the alphabet. And some of the filenames are already capitalised, but none of the folder names ...
- Create a variant array with `aTxt = Split(.Text, "; ")`, then populate the string array `ArrTxt()` with `aTxt()` ```vb Option Explicit Sub AlphaCites() Application.ScreenUpdating = False Dim ArrTxt() As String, i As Long, j As Long Dim aTxt As Variant With ActiveDocument.Content Wi...
I like to implement data mapping using the [Spatie Laravel Data][1] package. The Spatie package uses classes to define data objects which are filled from arrays or json data. The names of the properties are the field names you want to use in your code and the package provides a [MapInputName][2] attribute modifier t...
{"OriginalQuestionIds":[4644860],"Voters":[{"Id":11082165,"DisplayName":"Brian61354270"},{"Id":12002570,"DisplayName":"user12002570","BindingReason":{"GoldTagBadge":"c++"}}]}
We have ways to solve the above bug. 1. If your test ng method has a non-void return type[Not void]. If we remove the non-void return type for the test method. 2. Instead of removing the non-void return type we can add a line to the testng.xml file that accepts any return type for testNg methods. Line <suite...
I've been using selenium to take screenshots of Reddit posts and comments, and I've run into an issue that I can't find a fix for online. My code gives selenium the ID of the object I want to take a screenshot of, and with the main reddit post itself, this works great. When it comes to the comment though, it always tim...
Selenium cannot find the ID of reddit comments, why?
|python|selenium-webdriver|reddit|
null
{"OriginalQuestionIds":[68209351],"Voters":[{"Id":7758804,"DisplayName":"Trenton McKinney","BindingReason":{"GoldTagBadge":"python"}}]}
You should use a dictionary for the Parameters. Parameters = new Dictionary<string, object> { { "Name", "/my-param" }, { "WithDecryption", true } } Ref: https://docs.aws.amazon.com/cdk/api/v2/dotnet/api/Amazon.CDK.CustomResources.AwsSdkCall.html
So i have a template that i'm using on wordpress and doing small adjustments to make it the way i want although now there is an animation on the header done with javascript and i wanted to "eliminate" i will post the code for the mentioned event: // Breadcrumb effect if ($(".dt_pagetitle .canvas")....
discord.py - Oauth2 - join user to guild
|oauth-2.0|discord|discord.py|
null
As shown below, within the mqst environment, there are two different python binary files: python and python3. But they have the same version, being 3.12. If I do ``` which python ``` I get the python file path. And I will get the python3 file path if I do ``` which python3 ``` Does anyone knows why this is th...
Overview ======== This is a very interesting question with a surprising number of answers. The "correct" answer is something you must decide for your specific application. With months, you can choose to do either *chronological computations* or *calendrical computations*. A chronological computation deals wit...
I installed OpenVINO dependencies and converted the model to OpenVINO format. I have OpenCL device available: ``` $ clinfo -l Platform #0: Intel(R) OpenCL HD Graphics `-- Device #0: Intel(R) Graphics [0xa7a0] ``` Trying to run `yolo predict` on a GPU always results in `Invalid CUDA device requested`, e.g. ``` ...
What is the parameter for CLI YOLOv8 predict to use Intel GPU?
|gpu|opencl|intel|yolov8|
OP Here. Both of the following commands are working for me: curl -Lfs "https://motivatedsisters.com/2019/07/08/arabic-review-sr-rahat-basit/" | rg -o '<li>.*?href="(.*?)".*?</a> (.*?)<\/li>' -r 'echo $1 $(unescape_html "$2")' | bash | rg -o '(https?://\S+)\s(.*)' -r 'echo $1 $(unescape_html "$2")' -r '{"url"...
this worked for me I'v created a atrigger with this insert INSERT INTO pr2_product_carrier (id_product, id_carrier_reference, id_shop) VALUES (NEW.id_product, '10', '1'); My id_carrier is 10. I could understand this solution is not acceptable for many cases that you could need. In my case it was eno...
guard let url = URL(string:"https://blaaaajo.de/getHiddenUsers.php") else { return } let postString = "blockedUsers=245,1150" var request = URLRequest(url: url) request.httpMethod = "POST" request.httpBody = postString.data(using: String.Encoding.utf8); do{ ...
Ok turns out all I had to do was upgrade flutter.
I'm studying into a Boot Camp and one of past challenge was create a Pokedex with pokeapi. I over the challenge and now i'm going to fix some thinks. I have a strange problem when i'm into details of the single pokemon. When into interpolation i put the various propriety i don't get a problem, into screen stamp it but...
Pokedex on Angular 17
null
I'm studying into a Boot Camp and one of past challenge was create a Pokedex with pokeapi. I over the challenge and now I'm going to fix some thinks. I have a strange problem when I'm into details of the single pokemon. When into interpolation I put the various propriety I don't get a problem, into screen stamp it but...
If you want to use a `switch` statement for ranges, generally you need to map the ranges to specific values. They could be discrete integers, but in Java it makes sense to use `enum`s, because the `enum` definition can have a method that does the mapping. `enum`s can be public, but they can also be private, within a...
The error message suggests there might be an issue with the AuthenticationStateProvider being used. Make sure you are using the correct provider for Blazor WebAssembly. It should be RemoteAuthenticationStateProvider. builder.Services.AddScoped<AuthenticationStateProvider, RemoteAuthenticationStateProvider>();
If you are programming in C only, what i can recommend is [nuklear][1], it is a free open source GUI library that is surprisingly flexible to use and you can even create your own custom widgets. Initializing the library context/loading a single font & baking it into a texture: #include <nuklear.h> /* s...
Can someone explain me why i get error " INSERT statement conflicted with the FOREIGN KEY constraint "FK_ArticleTag_Tags_ArticleId". The conflict occurred in database "Blog", table "dbo.Tags", column 'TagId'". ``` public class Article { public Article() { Comments = new HashSet<Comment>(); ...
In the following code, no matter where I attach the second `.actionSheet` I cannot make them work. My understanding was that as long as they were attached to different views, it would work but that theory doesn't seem to be true. struct ContentView: View { @State private var showFirst...
null
The easiest change is to simply listen for the `input` (or `change` if you prefer) event, and then toggle a class on the `<body>` element based on the checked/unchecked state of the `<input>` as below, with explanatory comments in the code: <!-- begin snippet: js hide: false console: true babel: false --> <!-- ...
In the following Java code, `PropertyChangeListener` is implemented in two ways: 1) using a class that implements `PropertyChangeListener` interface, and 2) using a method reference. According to the API, the `addPropertyChangeListener` method takes, as argument, an object of type `PropertyChangeListener`. The first...
To access your data, you simply need to access the `0` (string, not number) key of the returned object, so you *could* just do: ``` this.job = job['0']; ``` However, since you always want your service to return the `Job` and not the full object, you should transform your response: ``` // service getJob(id:...
I am new to React native i have a problem withe the expo DocumentPicker for some reason the DocumentPicker does not select any file, and it always shows that Selected Document: None ``` import React, { useState } from "react"; import { Button, StyleSheet, Text, View } from "react-native"; import * as Doc...
expo DocumentPicker is not selecting any document
|javascript|reactjs|react-native|expo|
remove particle animation on javascript
|javascript|wordpress|
> However, I'm wondering about the safest approach to utilize it for local testing without compromising security. Cryptography is an API that doesn't have any side effects. It operates on the key and data you provide, and for most functions the key and data isn't even altered. For instance, for a cipher, you put in ...
I am running locally a react app that i expose to the network with the the `--host` flag and a C# API, i added to the cors policy the ip address and port number that the app is exposed on. from my desktop all works fine, but when i attempt to access the site through my mobile phone thats connected to the same networ...
null
The `std::less` compare functor as used in [this answer](https://stackoverflow.com/a/71246646/1614903) does not yield the expected result. The reason is that it uses the **content** of the reference of type `MyType` instead of the **reference to the variable** of type `MyType` as index into the set. Try this: ````c+...
Windows 11 Visual Studio 2015 I would like to filter double values. [enter image description here][1] [enter image description here][2] [1]: https://i.stack.imgur.com/ZckkI.png [2]: https://i.stack.imgur.com/ICCrr.png I can filter Strings Dim srchStr As String = Me.TextBox1.text Dim...
Filtering a double value
|filtering|
I have character code: ``` extends CharacterBody3D @onready var camera_mount = $camera_mount @onready var animation_player = $visuals/mixamo_base/AnimationPlayer @onready var visuals = $visuals @onready var camera_3d = $camera_mount/Camera3D @export var is_current:bool = true @export var is_main = true @...
XmlHttpRequest cannot load due to access control, but access is configured?
|reactjs|asp.net-web-api|cors|
The new operator in C++ performs the following actions: 1. Allocates Memory: It allocates memory on the heap for a single object or an array of objects. The amount of memory allocated is enough to hold the object(s) of the specified type. 2. Initializes Object(s): After allocating memory, new initializes the obje...
I am using useContext to get user information in the login page and display it in the home page it displays the information at first but when i refresh the home page the information get lost why please i am a beginner in react this is where i'm setting the context ```reactjs const { setContext } = useContext(Con...
{"Voters":[{"Id":777985,"DisplayName":"Ray"},{"Id":14868997,"DisplayName":"Charlieface"},{"Id":1043380,"DisplayName":"gunr2171"}],"SiteSpecificCloseReasonIds":[13]}
The problem is that the command specifies `1,6`, which will match only the first 6 lines. You could write a `sed` script that does what you want, but not a one-liner. On the other hand, this is easy to do with `awk`, like this: awk '/.*please.*/ {n++} !/.*please.*/ || n > 3 {print}' There are actually two ...
New to coding and getting this error message: ``` > "Cannot convert value of type 'Tab.Type' to expected argument type 'Binding<Tab>'" ``` What can I change to fix this? Here's my code: ```swift enum Tab: String, CaseIterable{ case house case person case message case gearshape } ...
How to correct "cannot convert value" error?
|swift|swiftui|
null
I am new to coding and get this error message: > "Cannot convert value of type 'Tab.Type' to expected argument type 'Binding<Tab>'" What can I change to fix this? Here's my code: ```swift enum Tab: String, CaseIterable{ case house case person case message case gearshape } struct C...
How to correct error: "Cannot convert value of type 'MyType.Type' to expected argument type 'Binding<MyType>'"?
I'm trying to create a simple R Shiny app that takes the chromosome, start, and end positions of CpGs as inputs and outputs boxplots for each CpG within the range. It works fine on the subset of data but fails for the real data ("all_data_reduced.RDS") because of its big size (almost 3 GB). I'm also not sure if the cod...
I have a weather app that refreshes asynchronously. While I've never seen it crash myself, I do see about a crash per day in Apple's reports, and not from a specific device. The app does have a good amount of users and it refreshes every few minutes, but I have no idea what kind of percentage send reports to Apple, so ...
I'm attempting to display a list of movies on a website using Jinja2 (a template engine for Python) and Bootstrap (a front-end framework). However, I'm having difficulty getting the movie cards to display correctly.When trying to display the movie cards using Jinja2 and Bootstrap, the cards aren't being displayed as ex...
If you don't use bootstrap components like me, you can use the **noninteractive** directive instead: <!-- language-all: html --> <div v-b-tooltip.noninteractive="{title: `I'm a tooltip`}">Hover me!</div> For futher reference: [tooltip directives][1] [1]: https://bootstrap-vue.org/docs/directives/toolt...
It seems that pydoc has a bug when It comes to files with DB models. I ended up using pdoc. pip isntall pdoc pdoc objects.py
> Will this impact the integrity of data? **No**. This exception was triggered in a `ReadStage` thread - This type of thread is responsible for local reads, which don't modify the dataset in any way. > And is there something I can do to avoid the error e.g. resize some param on Cassandra.yaml? **Yes**. I woul...
I have an issue with the default month calendar control on Windows and Delphi 2007. By default, my dev environnemet is in French. I need to translate the texts into Flemish (`nl-BE`). No worries, I use the *“Localizer”* tool and it’s ok. On the other hand, with the [**TMonthCalendar** component][1], I have the...
Flying chracter godot
|godot|gdscript|godot4|
null
Guys if you are using app folder structure in next 14 your api/auth/[...nextauth]/route.ts folder must be at same folder auth/signin page. and if you are using next 14 route grouping like (auth) carefull this folder leveling
i am currently facing an issue where i just hosted my react application on Netify(web hosting website) [enter image description here](https://i.stack.imgur.com/pQ6mc.png) the above pic show the code i used to route them, now when i refresh the page it show "Looks like you've followed a broken link or entered a URL t...
Route not working on refreshing the page in react deployed application
|reactjs|deployment|react-router|react-router-dom|
null
well in my case, i just avoid saving data to directly in state and add data inside an object instead. like before: const initialData = []; state.push(...); after: const initialData = { data: [] }; state.data.push(....);
`g++ test.c -o test.exe -lncursesw` this worked for me I installed ncurses using MSYS on windows 10 using ` pacman -S mingw-w64-x86_64-ncurses` command
{"Voters":[{"Id":207421,"DisplayName":"user207421"},{"Id":14732669,"DisplayName":"ray"},{"Id":466862,"DisplayName":"Mark Rotteveel"}]}
{"OriginalQuestionIds":[4086107],"Voters":[{"Id":266309,"DisplayName":"waldyrious"},{"Id":-1,"DisplayName":"Community","BindingReason":{"DuplicateApprovedByAsker":""}}]}
I use the inherited concept of the object. I am using the `TextEditingController`. 1. Assign this `TextEditingController` to the parent page. 2. Pass this controller into the child widget. 3. Put the child function into the `addListener` at the `initState`. 4. Using this controller in the parent function like `c...
So, i'm making site with spring boot, and i've decided to make base.html, that gets extended with other html files. ```<!DOCTYPE HTML> <html xmlns:th="http://www.thymeleaf.org"> <head> <!-- <title th:text="${title}"></title>--> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> ...
Rather than any of the above, I would use the [basic dispose pattern](https://learn.microsoft.com/en-us/dotnet/standard/design-guidelines/dispose-pattern#basic-dispose-pattern) to return some `IDisposable` that wraps the rented array and returns it when disposed. First define the following disposable wrapper: ```...
It appears that it's important to express that you want the 7 specific items extracted by calling for tokens=1-7. Token 1 will be %%G, with each successive, stipulated token using %%H, %%I, etc. Wanting to express one line for each token comes by echoing them 1 echo command at a time for each token's variable, either...
i'm building the backend of an app in python and i wanted to use Django, the problem is, i installed pipenv with pip3 the first time and it run smoothly, now if i try to install with pip only it tells me: Requirement already satisfied: pipenv in c:\users\marco\appdata\roaming\python\python39\site-packages (20...
Can't install Pipenv on Windows
|python|django|powershell|pip|pipenv|
I trying to build account checker in python, when i run scripts to check the account is working or not like a u can sign in on website with that username and password or not. i getting always failed to login and when i try to put my real account in combo.json still cant login into website idk why i trying to my ...
How to make an R Shiny app with big data?
|r|shiny|bigdata|