instruction stringlengths 0 30k ⌀ |
|---|
|python|turtle-graphics| |
null |
I own a domain called bigstore.com and have developed a Laravel website for it: www.bigstore.com. It's hosted on an Ubuntu 22.04 server utilizing Apache2, and the website is HTTPS-enabled. The server hosts both the domain (bigstore.com) and a subdomain (m.bigstore.com), intended for mobile browsers.
Here is the top-... |
Python pivot_table where one values column is comprised of lists of values |
|python|pivot|pivot-table| |
when I submit a job to my self hosted agent, the job will run, however at the end of the job the post-job checkout is hanging for like 12 minutes or so before the job completes and I am not sure why.
I have noticed that I get this behavior even when I don't checkout any repo as part of the pipeline. Any thoughts on... |
Post-Job Checkout Hanging |
|azure|azure-devops|azure-pipelines|pipeline|repo| |
null |
Why use tasks and async await in C# inline? |
I have a program that gets requests (an array of strings of size `n`) from different domains (each input value is called as a domain) for each second `i`.
Within 5 seconds for a given domain the program should accept at most 2 successful requests.
Also at most 5 successful requests in 30 seconds.
For each req... |
If you're getting this error on every **other** request, like the OP mentioned, you're probably getting hit by a very tricky little internal caching issue (details below). Your options are:
1. Set `CryptoProviderFactory.Default.CacheSignatureProviders = false` in a spot where it'll run before any other crypto stuff ... |
Why can't I import this dependency into this nix flake? |
|nix| |
`packages` in mkShell [ends up getting merged into nativeBuildInputs](https://github.com/NixOS/nixpkgs/blob/d5766175de1b5b0e09f7d25c0d552fe4ee617a91/pkgs/build-support/mkshell/default.nix#L41) which is [a parameter on stdenv.mkDerivation](https://github.com/NixOS/nixpkgs/blob/d5766175de1b5b0e09f7d25c0d552fe4ee617a91/pk... |
I have the simplest nasm program in the world:
global main
section .text
main:
nop
I compile it like this:
nasm -f coff -o program.o program.asm
Then, when I try to link it with `LINK.EXE`, it results in the following error:
link program.o
Microsoft (R) Incremental Linke... |
link.exe unresolved external symbol _mainCRTStartup |
|assembly|linker| |
{"Voters":[{"Id":17562044,"DisplayName":"Sunderam Dubey"},{"Id":497193,"DisplayName":"Nubok"},{"Id":10871073,"DisplayName":"Adrian Mole"}]} |
Given this directory structure (empty `__init__.py` and `logging.yml` is fine):
<!-- language: lang-none -->
foo
│ setup.py
│
└─── foo
│ __init__.py
│
└─── config
logging.yml
Here is my attempt, this `setup.py`:
<!-- language: lang-python -... |
I took a look at the opcodes generated by these assembly codes :
```
xor rsi, rsi
mov sil, 0xFF
```
and
```
mov rsi, 0xFF
```
The first code turns into `48 31 F6 40 B6 FF` and the second into `48 C7 C6 FF 00 00 00`.
1. Is code with more instructions slower?
2. Is what matters more the size taken up by t... |
1. Initially Formate `dict` into `str` by adding triple quotes before and after. 2. Formate further by removing curly braces, double quotes etc. This you can do programmatically
txt = '''{"A": "Red",
"A": "Blue",
"A": "Green",
"B": "Yellow",
"C": "Black"
}
'''
txt = txt... |
I have a null object reference but object exist.
My model
```
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public String getPlayerName() {
return playerName;
}
public void setPlayerName(String playerName) {
... |
How to use `ffprobe` to select a subtitle from an `mkv` file and display its content?
I expect to have the subtitle content printed on the terminal like the command `cat` would do to a subtitle file.
I know its possible to export the subtitle file and then `cat` it, but is there a direct use for probe? |
Use `ffprobe` to display subtitle content like the `cat` command |
|terminal|subtitle|ffprobe| |
null |
You should add a simple log statement in your component to find out how many times it renders, and the value of `authUser` at each rendering. It's almost certainly the case that your component is rendering more than once:
- First with the initial value of `authUser`, which will be `null` when the page first loads
... |
null |
I was creating a validation form and by chance, I changed innerHTML of a div tag without declaring it at the top but that worked. I am not getting why that works without even declaring the error variable for div where I want to show the error
if(name == "") {
// why it works although I didn't
/... |
Didn't declared variable still not getting any error in JavaScript |
|javascript|html|jquery|css| |
With "Android Studio 2023.2.1", now in 2024-04, my binaries are at
"AndroidStudioProjects\{project name}\app\build\outputs\apk\debug"
=> "app-debug.apk" or "app-release-unsigned.apk".
"AndroidStudioProjects\{project name}\app\build\outputs\bundle\debug"
=> "app-debug.aab" or "app-release.aab". |
I'm trying to avoid this new cost ([public IPv4][1]) in aws for small projects because it will represent a big percentage of the cost.
In my ECS cluster, I use EC2 instances as capacity providers, therefore, I followed [this doc][2] to make every new EC2 instance use IPV6 instead of IPV4 -- which worked.
However ... |
null object reference with intent,parcelable and getting data sqlite |
|null| |
null |
|sql|mysql| |
Have you seen the dataflow cookbook examples on GitHub?
- [Reading from pubsub subscription with python](https://github.com/GoogleCloudPlatform/dataflow-cookbook/blob/main/Python/pubsub/read_pubsub_subscription.py)
- [Writing to bigtable with python](https://github.com/GoogleCloudPlatform/dataflow-cookbook/blob/m... |
hi I'm looking for the script that already exist, a theme or a guide on how to create a basic website from scratch. A concept is a language learning website that will allow a parent to pick 5 pictures at a time from the gallery, when clicking the picture, a sound 'phonics' is heard. The site should have login signup/re... |
Call Databricks API from a asp.net core Web application |
|asp.net-core|oauth-2.0|scope|databricks|openid-connect| |
null |
I want to create a storybook for my ag-grid component. I have tried the usual way that I follow for other angular components. But this doesn't seem to work.
const meta: Meta<AgGridAngular> ={
title: 'GridCell',
component: AgGridAngular,
tags: ['autodocs'],
decorators: [
... |
angular ag-grid doesn't work with storybook |
|angular|ag-grid|storybook|ag-grid-angular|angular-storybook| |
{"Voters":[{"Id":-1,"DisplayName":"Community"}]} |
{"Voters":[{"Id":681865,"DisplayName":"talonmies"},{"Id":1974224,"DisplayName":"Cristik"},{"Id":3581217,"DisplayName":"Bart"}],"SiteSpecificCloseReasonIds":[16]} |
I'm encountering an issue with the PUT method in my Laravel application when trying to update a student record. Whenever I attempt to make a PUT request to update a student's information, I'm receiving the following error message:The PUT method is not supported for route students/10/edit. Supported methods: GET, HEAD.
... |
How about try `asp-action` , like
<form id="FormActive" asp-action="Index">
</form>
Then in controller:
[HttpPost]
public IActionResult Index(int id)
{
return View();
}
result:
[![enter image description here][1]][1]
[1]: https://i.stack.imgur... |
I have a Spring MVC web app with Spring Security using Keycloak v24.0.2 and Spring Boot v3.2.4. In Keycloak I set up parameters "SSO Session Idle" and "Access Token Lifespan" to 1 minute, but a session still doesn't expire after user being idle during 1 minute. I expect redirection to login screen after being idle this... |
- You come in here: https://github.com/extremecoders-re/pyinstxtractor
- Downloading the archive: pyinstxtractor-master.zip
- File: pyinstxtractor.py unpack to the directory of the executable
file.
- In the address bar of the window-(the folder of the executable
file), enter t... |
For example, given the inventory
```ini
shell> cat hosts
test_01
test_02
test_03
```
and the files */tmp/fstab* (all the same) for testing
```bash
shell> ssh admin@test_01 cat /tmp/fstab
UUID=423d168c-5a90-44f9-94b2-d2da9f0e1e4f / ext4 errors=remount-ro 0 1
UUID=0F15-7883 ... |
Check your maths
200 % 26 = 18 (shift)
'9' + 18 = 57 + 18 = 75 ('K')
75 + '0' = 75 + 48 = 123 ('{')
123 - '9' = 123 - 57 = 66 ('B')
66 - 1 = 65 ('A')
Now, the problem is, between '9' and 'A' there are 7 other characters, so `character = (char) (character + ('0' - '9') - 1);` would have to ... |
Usually using a variable is an additional overhead, but in your case Chrome was able to provide the same performance. But if a variable is reused, that could actually boost performance. So the rule could be - don't create unnecessary variables.
If you create a variable it could be considered a write operation, but w... |
I loaded promox and didnèt update host had a static ip and could connect once I trying windows 10 to rpi4 window you goto apps add options feature add botth openssh goto rp1 copy ssh/ssh_config paste .ssh/config put it folder says that missing when you do ssh -vvv root@raspberry pi you hvae to do ssh-keygen command in... |
I'm trying to replace a picture in NetBox by uploading a replacement picture using curl. I'm finding that depending on which form of the URL I use, I get different error messages.
Note that I get the same error messages if I use PUT instead of PATCH.
The file is only 4Mb and is in the current directory.
File ... |
Curl URL syntax for uploading files |
They say, that tasks are good, cause they are non-blocking. That makes sense. Since some time, we have everything async - async action in mvc, async web api calls, async ef methods, etc.
The one thing I do not understand - why?
Let's assume we have a method:
```
public async Task<User> GetUserAsync(int id, Canc... |
The question is a bit old but still has many views so here's is a simpler and more efficient way to get the value of a structure member using the CreateExtractValue method. It avoids storing the whole structure in memory using CreateStore then reloading the member that you need. Your code above would look something lik... |
The DataSource class has an option called `clusterMaxZoom` which specifies the maximum zoom level the map will cluster points to. This is set to 18 by default. If you have points that will be at the same location, it would best to set this to 24 (max possible zoom level of the map). You can either set this when creatin... |
when you use a string to refer to a variable name, it doesn't directly access the variable itself. Instead, you can achieve this using a dictionary to store your arrays with their corresponding names.
Try this:
Solution 1:
J2 = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
arrays = {'J2': J2... |
Troubleshooting incorrect content on mobile redirect |
There are two types of Reed Solomon code, which Wikipedia refers to as "original view" and "BCH view", and within each view, there are two encoding methods, "simple" encoding and "systematic" encoding.
https://en.wikipedia.org/wiki/Reed%E2%80%93Solomon_error_correction
G = [I|A] corresponds to original view, syst... |
I have done it through the temporary table,
```sqlite
create temp table temp_view as select target_col from target_table
-- first store the values of the target col in the temp. table
alter table target_table drop target_col;
-- Drop the column
alter table target_table add target_col new_type;
-- Add the c... |
You probably need to specify [more properties][1] for the column chart for this to look how you want it.
let T = datatable(TimeGenerated:datetime, StatusCode:int, ErrorCount:int) [
datetime("2024-03-26"), 304, 3,
datetime("2024-03-26"), 404, 5,
datetime("2024-03-27"), 304, 10,
datetime... |
Consider I have the following asynchronous task runner. It puts tasks in a queue and executes them one by one, calling lambdas on completion. If func yields result of some type, then onComplete callback should receive argument of the same type.
```cpp
class TaskRunner
{
public:
TaskRunner() :
mPool(ne... |
Qt: running callback in the main thread from the worker thread |
|c++|multithreading|qt|callback|signals-slots| |
null |
{"Voters":[{"Id":1464592,"DisplayName":"MrMojoRising"}],"DeleteType":1} |
Im Creating slider using Swiper JS wich reveals next slider partially As following
(https://i.stack.imgur.com/L0e9N.png)
How ever its work great until end of original slides and when the loop mode enabled duplicate slides
start next slide is dissapear and appear on next one
Following Is What I tries so far in... |
I am looking into making a vertical scroll timeline as here https://web.archive.org/web/20220701063638/https://cuvette.tech/. How do I create such timelines in react? |
How to make a timeline as below |
|reactjs| |
I´m expermenting with Tauri beta app development and have a problem to start my angular project with...
npm run tauri ios dev
In my tauri.conf.json I have the following config section
````
"build": {
"frontendDist": "../dist",
"devUrl": "http://localhost:4200",
"beforeDevCommand": "npm run star... |
Tauri with ng-app uses local ip instead localhost for accessing dev server |
|angular|tauri| |
I was trying to extract a sudoku grid using OpenCV by finding the square contour with the largest area. But some sudokus have more than one outer boundary, thus the program detects only the outermost boundary. This affects the later parts of the program because the sudoku is split into 9 parts row wise and column wise,... |
I used **"lock"** in the **"task"** it **doesn't work and race condition occurred**
I have defined a Counter, which should eventually return 0, because a Method increases the value of the Counter and a Method decreases it.
**And when I use Thread it is not a problem. This problem occurs when I use Task**
I use... |
|python|pandas|pivot|pivot-table| |
Pandas pivot_table where one values column is comprised of lists of values |
### Problem Description
Recently, I tried to build the CMake documentation with its gettext `.po` files generated by the `gettext` builder. However, I wonder how to translate the content of the `parsed-literal` directive if there exist hyperlinks?
Take this [part](https://github.com/Kitware/CMake/blob/v3.28.4/Hel... |
|cmake|python-sphinx|gettext|restructuredtext| |
{"Voters":[{"Id":1007220,"DisplayName":"aynber"},{"Id":5468463,"DisplayName":"Vega"},{"Id":6461462,"DisplayName":"M--"}],"SiteSpecificCloseReasonIds":[16]} |
I am getting **POST http://localhost:3000/api/user-profile net::ERR_ABORTED 500 (Internal Server Error)** error message in developer console when trying to submit data to my Supabase Database. The terminal says **TypeError: res.status is not a function at POST**. This is my first time attempting to make an API route in... |
I am trying to achieve below chart but its failed so could anyone help me out?
[Donutchart image](https://i.stack.imgur.com/6O3gb.jpg)
here's my code:
```
import React from 'react'
import { Doughnut } from 'react-chartjs-2'
import { Chart as ChartJS, ArcElement, Tooltip, Legend } from 'chart.js'
Chart... |
|curl|url|syntax|upload|netbox| |
null |
The "Amplify" command is returning an error message that says "Pkg: error reading from file." |
"stolen" the idea of AT82, we can has a recursive function that return an observable. Well, instead of use "tap", we can use map to return an object with two properties: name (the control has changed) and value.
So some like
mergeForm(form: FormGroup | FormArray, suffix: string) {
if (form instance... |
I am retired aerospace engineer. Never used Python, just picking it up on the fly. Not a programmer either.
Using Visual Studio to write a propeller performance analysis code using Blade Element Momentum Theory. This requires using a free, available online, external code called XFOIL.
I have actually made a lot o... |
I am new to sequelize.js and basically am trying to refactor code that I've written in the controller and came across classMethods and instanceMethods. I see instance methods defined like so:
**/lib/model/db/users.js**
module.exports = function(sequelize, DataTypes) {
var instance_methods = get_i... |
Swiper Js Slider Reveal Next Slider Partially |
|frontend|slider|swiper.js| |
null |
<!-- language-all: sh -->
* Your attempt to enclose `$appCheck.UninstallString` in _embedded_ `"..."` is unnecessary (and happens to make no difference in this case)
* PowerShell, when it constructs the process command line ultimately used behind the scenes, would _automatically_ enclose the value of `$appCheck.... |
{"Voters":[{"Id":1464592,"DisplayName":"MrMojoRising"}]} |
Consider the following variable:
```lang-hcl
variable "instances_count" {
type = number
default = 10
description = "Number of instances to create."
}
```
### [Using variables in the command line](https://developer.hashicorp.com/terraform/cli/config/environment-variables#tf_var_name)
You ... |
I have a for loop with nested if else statements. What I am trying to do is for each row in my DataFrame
1. check if a trade is open by checking if a TP or SL has already been set. If it has move on to the next row, because I don't want to open a trade when one is already running.
2. If a trade isn't open, dete... |