instruction
stringlengths
0
30k
|if-statement|
null
You have to use a `\U` + 8-hexadecimal code instead of `\u` + 4-hexadecimal code. You'lll also need an appropriate font so it may or may not show up below on your system. ```py import unicodedata as ud mystr = 'ABC' trans_dict = {'A':'\U00011D72','B':'\U00011D73','C':'\U00011D74'} mytable = mystr.maketrans(tran...
I'm struggling edit a Jtabel with a picture on it. So basically, i can edit the table ONLY if i edit the picture on it. I can't edit anything if i am not editing the coloumn on the picture on it: trying to debug but the listener isn't doing the query on the server. here the code ``` public class Visualizzapro...
Issue edit a jtable with a pictures
|java|jtable|
null
I have producer and consumer configuration Producer @Bean public KafkaTemplate<String, BeltEventDescription> kafkaBeltEventDescriptionTemplate(final ProducerFactory<String, BeltEventDescription> producerFactory) { return new KafkaTemplate<>(producerFactory); } with config properties ...
No method found for class java.lang.String in Kafka
|java|apache-kafka|json-deserialization|
I have a google sheet with values on it. Think it like this: | header1 | col1 | header 3 | col2 | | -------- | -------------- | --------- | -------- | First | | row | | | Second | | row | | I will have another data that will come and fill the 2nd and 4th column by respectively. So wha...
It is impossible to achieve using a single Lua pattern, but you can chain a few of them: ``` local s = "/<\\/>//b\\\\/c" -- 4 payloads here (the second one is empty) for x in s :gsub("/", "/\1") -- make every payload non-empty by prepending string.char(1) :gsub("\\(.)", "\2%1") -- replace magi...
We are [splitting][1] the files into the component.vue, styles.scss and template.html, something like: <script setup lang="ts"> // Common elements import Category from '@/components/Elements/Category/Category.vue'; // COMPOSABLES const localePath = useLocalePath(); // DATA ...
When splitting SFC components in multiple lint provides false positives
|nuxt.js|eslint|typescript-eslint|false-positive|no-unused-vars|
**FluentD 1.16.3** and **Fluent-bit 1.8.11** I have the following lines in my container log file */var/log/containers/*.log* **When a ldap user credentials fail (bad user/password)** 024-03-28T16:09:23.048182266Z [28/Mar/2024:16:08:58.721901994 +0000] conn=13532278 op=0 BIND dn="uid=f_lastname,ou=People,dc...
It does not have a preconditioned and it's not supposed to. I mixed it up with HPCG which does incorporate a precondtioner.
@helder-sepulveda's answer has a minor bug - validation will fail when all variables are set to `"false"` Here's a working example: ```terraform variable "sc1_default" { default = "true" } variable "sc2_default" { default = "false" } variable "sc3_default" { default = "false" } variable "sc4...
i have created a 10k lines dictionary for program iam making , some of the entries has duplicate keys because of the way the data need to be presented . the fix for this is to turn the "value" into a list removing duplicate keys . i was wondering if there is an automated way to do this ? (pycharm) for example : ...
I am trying to disable the builtin `kill` in the bash running inside the container, and I would like to know if it is possible to run a command after the container start running, or if it is possible to run `/bash/bash` with some specific parameter to disable a builtin function. I have a `Dockerfile` with the follow...
How to disable a bash builtin inside a docker container
|bash|docker|
I am trying to install GMP (c++) for Windows using MSYS2. I made sure that when I installed msys2 that I installed gcc and set the PATH to C:\\msys64\\mingw64\\bin. I restarted my computer to check if GCC is working (gcc --version in the cmd works), but when I try to install GMP it doesn't work. When I try to do ....
GMP Windows installation "configure: error: could not find a working compiler"
|c++|gcc|gmp|msys|
null
I have a code that works like this: template<size_t size> struct myClass { public: std::array<uint8_t, size> bytes; bool operator==(const myClass<size>& o) const { for (size_t i{0}; i < size; ++i) { if (bytes[i] != o.bytes[i]) return false; ...
I use shared preference in my project to store user information, but I encounter problems that the program encounters an error and does not load at all, and in terms of code, there is no problem with my code. But the application does not come up, And the error text is not sent, so that I can put it to you, the applicat...
I'm currently working on a maven project where I would like to have 2 docker container where one launch all the tests and the other compile the project if all the tests succeed. The problem is that both containers launch the prod dockerfile. So my question is why after pointing each Dockerfile in the docker compo...
I'm making an app in Swift that connects to a web service. I want to make requests, such as login. After logging in, I want to navigate to HomeView but never switch. I have these files: ` MainView: struct MainView: View { @ObservedObject var viewModel = MainViewViewModel() var body: some ...
Navigate after logged in with webservice
|swift|swiftui|
null
In your `ProductModel` schema the `category` property has a `name` property given to it. That suggests you want `category` to be an Object with a `name` property. I pressume that was not your intention. You need to remove that so that `category` is just a property with a value of type `ObjectId`. ````js const Pro...
hope you are all doing well :) I'm having a bit of a problem with my Dart app. The app is a to-do list creator where the user can create several lists and add items to each one of them. With this in mind, I started adding functionalities and from a simple, single-list app, now I have created a more complete thin...
Flutter + Dart: Editing name of a tab shows up a black screen
|android|flutter|dart|
null
Could my question look a bit silly, I am a newbie in R, I don't have much experience. Is there a straightforward way to extract a colored table into Excel? I created this matrix using ggplot [colored Table/matrix](https://i.stack.imgur.com/RiUjJ.png) How can I extract an editable table into excel with same colors...
I created this matrix using ggplot [colored Table/matrix](https://i.stack.imgur.com/RiUjJ.png) How can I extract an editable table into excel with same colors to adjust? Could my question look a bit silly, I am a newbie in R, I don't have much experience. Is there a straightforward way to extract a colored table...
Pending more details from the poster, here is an example that has a `MainThreadClass` running on the main thread of a program and an `asyncio` event loop running on another thread. When `MainThreadClass.event` is called, it sends a message to the event loop via an `asyncio.Queue` and `asyncio.run_coroutine_threadsafe`....
FluentD / Fluent-Bit: Concatenate multiple lines of log files and generate one JSON record for all key-value from each line
|elasticsearch|parsing|multiline|fluentd|fluent-bit|
This would pull out the decimal day duration between two rows in your specific format [![enter image description here][1]][1] let Source = Excel.CurrentWorkbook(){[Name="Table1"]}[Content], #"Convert" = Table.TransformColumns(Source,{{"Column1", each let a=_, b = Text.Replace(a,"Days...
With go 1.22+, I'd use `slices.Reverse()`: ```go package main import ( "fmt" "slices" ) func main() { s := []int{5, 2, 6, 3, 1, 4} slices.Reverse(s) fmt.Println(s) } ``` https://go.dev/play/p/he4pn_5ySq0
My issue was caused by using an enum in the class late final RelationshipStatus _status; Caused an issue: Map<String, dynamic> toJson() => { '_status': _status, }; Solution: Map<String, dynamic> toJson() => { '_status': _status.name };
In our company, we have a private repo on Github where we have our internal nuget packages. On my laptop, on another API solution, I can restore the nuget packages using my github credentials. I'm configuring the github actions to check the PR and deploy the API but when I want to restore nugets, I have an 403 erro...
If you want to get table of today forecast you can use this example: ```py import pandas as pd import requests from bs4 import BeautifulSoup headers = {"User-Agent": "Mozilla/5.0"} url = "https://weather.com/en-IN/weather/today/l/a0e0a5a98f7825e44d5b44b26d6f3c2e76a8d70e0426d099bff73e764af3087a" soup = Beau...
i found a way, using: - integer pixel coordinates which is much more intuitive and convenient at least for what i'm doing here - and considering the "pixel size" i wanted to paste my code but the crazy blocking rules pretending my code is not "formatted" correctly prohibits it! ctrl-k does not work ... so i w...
|javascript|vue.js|vuejs3|vue-i18n|matter.js|
In one iteration over the input array you can: * Collect the unique values in their order of first appearance * Count how many you have of each (Both can be captured by using a hash map that maintains insertion order, like for instance a dict in Python 3.6+, a Map in JavaScript, or a LinkedHashMap in Java) ...
So I'm having a problem when building my Flutter app in release mode for flutter. When I build my Flutter app in debug mode it works fine and I can use my app in any emulator without any problem. But when I click edit scheme and try to run it in release mode the build fails and I get cloud_firestore module not found...
you can use PrimeVue config options import PrimeVue, { PrimeVueConfiguration } from 'primevue/config'; app.use(PrimeVue, { locale:{ matchAll: "جميع الشروط", .... } } as PrimeVueConfiguration); alternatively you may modify only a portion of it like this: import PrimeVue, { PrimeVu...
I am having issues with my SQL statement below. The NOT LIKE and OR statement is producing FALSE statements, in that it is producing the output when it should not, since I am using a NOT LIKE. When I put the statement as a stand-alone (without the OR condition), it works as intended. For example, I am still seeing ...
I created `person` table, then inserted 2 rows into it as shown below: ```sql CREATE TABLE person ( id INTEGER, name VARCHAR(20) ); INSERT INTO person (id, name) VALUES (1, 'John'), (2, 'David'); ``` Then, I created `my_func()` which returns `person` table as shown below: ```sql CREATE FUNCTION ...
**Monster script** (it is connected to 2DSprite in Monster.tscn) ``` extends Sprite2D var monster = preload("res://Monster.tscn") func _process(delta): if Input.is_action_just_pressed("ui_accept"): var random_right = randi() % 10 + 1 var random_left = randi() % 10 + 1 var random_up = randi() % 10 + 1...
I have a query that I was asked to modify. The original field is: Startdate with a MM/DD/YYYY format. 1/1/2020 In the source table, startdate is a string field. I was asked to change the format to YYYY-MM-DD (mod_startdate1), but will need a 00:00:00 timestamp included. 2020-01-01 The best i can get to is ...
> 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...
can I override c++ operator[] with only one function?
|c++|constants|overriding|operator-keyword|
I have written a pipeline , which reads streaming data from PubSub, and aggregate the results and write the result to Bigquery. The pipeline is working fine and writing agg result to Bigquery table. But, I am not able to understand, how its calculating the result. Below is my code of apache-beam: ``` import json...
Can anyone explain the output of apache-beam streaming pipeline with Fixed Window of 60 seconds?
|python|google-cloud-platform|google-cloud-dataflow|apache-beam|
null
I am having this problem. Basically I want to parse an integer string to an int** where the sub int arrays are two long. The first index is the digit and the second is the power of ten associated to the digit. For example 12345 would give [[1, 4], [2, 3], [3, 2], [4, 1], [5, 0]] Here is the code: ```c #includ...
Mallocing int* inside of int** gives unexpected integer values in the first and sometimes second allocation
|c++|c|memory-management|malloc|
I don't really know how I would fix this problem, but my past experience with tkinter has told me that it might be a problem with the font. You can use the command "xfd -fa "[your font here]"" to see all possible emojis/symbols for your font. I believe you have to have the emojis pack for ubuntu installed, [1]: http...
The modal is designed to appear when there is an empty filled that has no value except some input fields. It shows up, yes, but after clicking OK, It won't hide. I did some troubleshoot but nothing really happened. Any advise or help would be appreciated. <!--Required Fields modal --> ...
{"Voters":[{"Id":1773237,"DisplayName":"Hhovhann"}]}
I've got a solution for you which required 2 basic changes 1. Convert the SVG to a .svg image URL. 2. Add a `::before` to the anchor tag and add the SVG to its `content` Example: <!-- begin snippet: js hide: false console: true babel: false --> <!-- language: lang-css --> p { max-width: 140...
I don't 100% understand what you are after. ``<nobr>`` can keep content together: <!-- begin snippet: js hide: false console: true babel: false --> <!-- language: lang-css --> p { width: 140px } <!-- language: lang-html --> <p>This is some text that includes a link <nob...
I need to set up a remote clocking system for my employees as they have the flexibility to come in whenever they want. This system should be capable of remotely storing employees' arrival and departure times using iris and fingerprint recognition. My questions are as follows: 1. What hardware do you recommend for...
Setting Up a Remote Employee Clocking System with Biometric Recognition
|laravel|client-server|system|communication|
null
Doesn't accept Spring MVC ResponseEntity<Resource> an InputStreamResource?
I have created an ASP.NET Core 6 Web API in C# with Docker support and it worked perfectly when I try to run from Visual Studio. When I deploy the docker build image to docker desktop app, I get an error: > <sup>2024-03-29 17:50:53 info: Microsoft.Hosting.Lifetime[14] > 2024-03-29 17:50:53 Now listening on: h...
Unable to connect to Azure Keyvault when I deploy ASP.NET Core 6 Web API (C#) , the docker image to docker desktop app
I no longer see this issue you mention on the emulator or preview. The `.padding(start=` should add padding to the start. The `paddingFromBaseline(top=` should add padding from Baseline (ie) you should see top padding getting added. This is the output of your code that I see [![enter image description here][1]][1] ...
when I clicked on publish in vs 2022, it gives a dialog to choose specifications of my release when i click on show all settings the ef migrations gives this error. > Entity Framework Migrations > X dotnet tool install dotnet-ef > The tool package could not be restored. Tool 'dotnet-ef' failed to install. This fai...
VS Community 2022 cannot install dotnet-ef when i try to publish
|c#|.net|visual-studio|asp.net-core|
null
I have problem in this sample code. ``` #include <stdio.h> #include <stdlib.h> int main() { int i = 1, j = 2 ; int **ipp = NULL; int *ip1 = &i, *ip2= &j ; ipp = &ip1; // both below lines cause segmentation fault // *ipp = ip1 ; // **ipp = 3; printf("ipp: %p...
change the value of double pointer with indirection operator cause segmentation fault
|c|pointers|segmentation-fault|double-pointer|multiple-indirection|
null
If you are using VS Code, you can put a breakpoint after `rdpcap()`, then run the script via Python debugger. In the VS Code debug panel you should be able to expand the object and find readable information.
I'm trying to load offline a VGG19 checkpoint from a local file instead of the regular pytorch method (which download it online) and got problems. so basicly i'm doing this : https://pytorch.org/tutorials/advanced/neural_style_tutorial.html and instead of cnn = models.vgg19(pretrained=True).features.to(dev...
Using your code I was able to reproduce the problem. You are running into a well-known, decades old, "_Won't Fix_" bug in Delphi. The workaround is to set the `Form.AutoSize` property to `False` at design time: ![Delphi designer showing form and properties](https://i.stack.imgur.com/LvwiQ.png) This then lets ...
# Option #1 We can do that with a [lifecycle precondition][1] in a null_resource A couple of things before we dive into the code: - Your code has two `sc1_default` variables I'm assuming that the second one was a typo and it what we need there is `sc1_default` - For additional validation use `type` in the varia...
I'm trying to create a monster that spreads in every direction infinitely but for some reason it's just making a "+" symbol
|2d|godot|gdscript|
null
This will correctly infer keys in the return value, you have to add params etc, but this should be a good start ```typescript type StringSetting = 'outputPath' | 'fileName' type StringSettingWithParam = 'emailAddress' | 'homeDirectory' type ArrayOfStringsSetting = 'inputPaths' type Settings = StringSetting | S...
The problem I am trying to solve is that the loop I wrote that to read All `NetCDF` files nested in multiple folders is not able to process `CDO` operation as I expect doing for individual files. Below is a brief description of what I am looking for; I have a directory on my Linux machine, let's name it MYDIR_SST, ...
Best list implementation for ordering objects by field in Java?
Assuming your data frame is called `bird_df` after you've read it in with `read.csv()`, you can subset the data to only contain rows where `Order1` is equal to Passeriformes, Charadriiformes, Psittaciformes, or Struthioniformes using: ```r subset_bird_df <- bird_df[bird_df$Order1 %in% c("Passeriformes", "Charadriif...
Extensions on tuples must conform tuples of any number of elements to a protocol. Your use case only makes sense to use 3-tuples, so a tuple extension isn't very suitable. You should keep your `Brio` struct, and create a result builder for `Brio`s, ``` @resultBuilder enum BrioBuilder { static func buildExp...