title stringlengths 13 150 | body stringlengths 749 64.2k | label int64 0 3 | token_count int64 1.02k 28.5k |
|---|---|---|---|
NestJs Kafka to Spring Kafka | <p>I Have Simple NestJs Kafka producer and Springboot Kafka Consumer . when i send messge in kafka producer the kafka consumer give the following error.</p>
<p>//</p>
<pre><code>java.lang.IllegalStateException: This error handler cannot process 'SerializationException's directly; please consider configuring an 'ErrorHa... | 3 | 2,228 |
State set method did not effect the main object - ReactJS | <p>I have three components in my project, <strong>App</strong>, <strong>DataTable</strong> and <strong>Table</strong>. </p>
<p>The <strong>App</strong> will render a <strong>DataTable</strong> that contains the Table component. I just called DataTable with data and columns props in it.</p>
<pre><code>// data sample
c... | 3 | 2,625 |
Float dropdown elements push each other to the right | <p>I'm working on a project where there are multiple dropdowns on one page. To get these dropdowns in order I use float left, the problem is that when I open one of the dropdowns on the left it pushes some of them to the right. What needs to happen is that the dropdowns underneath the open dropdown need to move down, a... | 3 | 1,536 |
How do I make an int object into something that is subscriptable? | <p>My specific question is if anyone can recognize why when I run this code below, I am getting this specific error. Or better yet, how to fix it. I'm trying to map a department description of a department number in df5 to a second data frame's (df2) TrueDepartment column. Df2 has a column called "Department" that I wa... | 3 | 1,313 |
Flagging/hiding posts twitter api 1.1 php | <p>I am calling a php file from an angular front end, and then showing a timeline of tweets.</p>
<p>The php file checks for tweets every ten minutes, and after this time updates a json file which is then called from angular. I want to create an admin ability to flag/hide posts from appearing in the timeline. Does anyo... | 3 | 1,462 |
Entry value shows an empty string with entry_value.get() on new window | <p>I'm setting up a makeshift tkinter window client that looks like this:
<img src="https://i.imgur.com/VlxJLWC.png" alt="">
His further information can be accessed by a secondary window like this:
<img src="https://i.imgur.com/oXgtaYB.png" alt=""></p>
<p>When I try updating his address by just clicking update, it end... | 3 | 1,077 |
Problems clearing a linked list, seg faulting delete | <pre><code>template <typename T>
void LinkedList<T>::clear()
{
LinkedList* p = this;
LinkedList* q = this;
while(p->m_next != NULL)
{
p = p->m_next;
delete q;
q = p;
}
return;
}
class LinkedList
{
public:
T m_data; // Data to be stored
LinkedList<T>*... | 3 | 1,133 |
How do you map the Accountability pattern to SQL with NHibernate | <p>We have implemented our domain model using the accountability pattern, which we are trying to persist using NHibernate with fluent NHibernate to define the maps.</p>
<p>Effectively we have 3 entities, Accountability (used to define the relationship between parties), Party (used to define the party, i.e. contact, pe... | 3 | 1,651 |
Strange behavior of Ext.JS stores with paging and grids | <p>I had some strange behavior of the stores in ext.js, when I was working with grids and with pagination.
Problem: I have a grid, a store with pagination is attached to it. When removing a row from the grid, the row from the next page does not get to the current one.
I tried reload store, commitChanges(), refresh(), p... | 3 | 1,256 |
How to delete a node from the firebase real-time database after creating another node with same IDs | <p>I am trying to delete a node requests when the accept option of the alert dialog is clicked,and also when the node contacts created successfully. What I am getting however is that the node contact is being created as expected, but the node requests is not.
<a href="https://i.stack.imgur.com/KN7JQ.png" rel="nofollow ... | 3 | 6,286 |
jQuery draggable+sortable: how to change the draggable element before append to sortable | <p>I'm trying to make a <strong>drag&drop html builder (like mailchimp)</strong> and I would like to have 15 <strong>pictures on the right that represent html code</strong> and drop them on a sortable list. But when the picture is dropped to the sortable list I want to change the dragged picture in an html code. Th... | 3 | 5,922 |
Removing Dynamically added views in android crashing application on view ClickListener for removing | <p>I want to implement the dynamically add and removing Views in android layout and Save the changes in shared preferences,<br/><br/> Everything works fine But while i m clicking on the specific view to remove on that specific view ClickListener something went wrong and its crashing the application but its removing tha... | 3 | 2,674 |
Encoding string data back to JSON is giving an error | <p>I've removed <code>jsonCallback (</code> and <code>)</code> from the URL <a href="https://www.apple.com/support/systemstatus/data/developer/system_status_en_US.js" rel="nofollow noreferrer">https://www.apple.com/support/systemstatus/data/developer/system_status_en_US.js</a> using the below.</p>
<pre><code> va... | 3 | 1,591 |
Difference Python on Windows & Linux: datetime.datetime object has no attribute total_seconds | <p>A python script I developed in Linux works fine in Linux. It uses openpyxl to iterate over cells in an Excel-file, compares values to lists, and calculates total time spent by adding different timedelta objects (in total seconds). So far so good...</p>
<p>But the script does not work on my Windows laptop I use for w... | 3 | 1,656 |
strange behaviour of pyplotlib upper menubar | <p>I am willing to integrate a matplotlib figure into a GUI designed with pyqt5:
I wrote the code above:</p>
<pre><code>from PyQt5 import QtCore, QtWidgets
from PyQt5.QtWidgets import QMainWindow
from matplotlib.backends.backend_qt5agg import FigureCanvasQTAgg as FigureCanvas
from matplotlib.backends.backend_qt5agg imp... | 3 | 1,678 |
How do you ensure all child elements of an angular component are a specific type? | <p>I have this use case I am trying to implement in Angular — A header component that can be placed on a page that has a container for small icon buttons. Something like this:</p>
<p><a href="https://i.stack.imgur.com/OteXf.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/OteXf.png" alt="Heading with... | 3 | 1,147 |
Python Exercise: Using repetition and concatenate | <p>I am extremely new to Python and programming in general, and have been thinking about this supposedly simple exercise from a book called 'Think Python'and would like some help in understanding and solving this better. I apologize in advance if this is considered too 'simple' or off-topic, but I wasn't sure how to go... | 3 | 1,264 |
counting methodolegy in SQL Server query | <p>Good day everyone…
I have a database that has the following:
Division table that linked to Employee table.
Group table, i.e. courses categories, that linked to Courses table.
and these table linked together thru Curses_Employee table .
so far I managed to come up with a query that give me the number of users who tok... | 3 | 1,137 |
pubsub_v1 TypeError: __init__() got an unexpected keyword argument 'serialized_options' | <h3>my version of python is 3.6.9</h3>
<p>and I tried install many versions of google-cloud-pubsub
2.1.0
1.5.0
1.3.0 .....</p>
<p>but I still have problem import
" "</p>
<p>the error message is
""" <code>from google.cloud import pubsub_v1</code></p>
<pre><code>---------------------------------... | 3 | 1,326 |
Expected all tensors to be on the same device, but found at least two devices, cpu and cuda:0(when checking arugment mat1 in method wrapper_addmm | <p>I trained a faster r cnn in order to detect tools. I already define my model and every thing worked. But to have a cleaner code without gloabal variables I tried to write a class MyModel who will automatically define every objet and train the model. So on this class I defined a class called self.dataset = ToolDatase... | 3 | 8,728 |
operator _surrogate_func: no matching overload found and 2 other errors | <p>I've written a code which creates a list of buses that you can modify and manage. The whole managing process is proceed by writing strings in console. After running code I'm receiving 3 errors, none of which I understand therefore can fix. Code is planned this way:</p>
<p>NEW_BUS - Adds new bus in list by taking it... | 3 | 2,218 |
class not applying to all html elements in reactjs after adding new data | <pre><code> import React from 'react';
import { CodeGenerator } from '@babel/generator';
class Test extends React.Component {
constructor(props){
super(props);
this.state = {
data:[{"type": "Beverages", "sub_types": ["Water", "Coffee"]}]
}
... | 3 | 1,546 |
actionEventListener ("click") does not work after inserting another item | <p>I'm trying to add dynamically div elements inside <code>filtersSpace</code> div element and at the same time add an eventListener for each button inside the div elements but when I insert the second element the first one to be added does not work.</p>
<p>Can anybody help me ?</p>
<pre><code>case "status":
... | 3 | 1,577 |
How to display arrays in an JSX column, NOT a row | <p>I am working on a react app. I am receiving data in arrays from the back end. For example, I am receiving an array of titles, another array of prices, etc... I have a total of four arrays. I set those arrays to state, then I want to render them to the web page in a table. The problem is that the tag puts any data a... | 3 | 1,279 |
How to group the same patient name into one cell using rowspan even if we have multiple rows returned to Ajax and displayed | <p>I need to re-format my html table that is displaying results from an Ajax response.</p>
<p>Usually, each patient may have 1 or more medicine and the table would be like the following:</p>
<p><a href="https://i.stack.imgur.com/LuILC.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/LuILC.png" alt="... | 3 | 2,136 |
AppBar shadow not being removed, android | <p>I'm working on a android application and I'm trying to remove the shadow under my AppBar, I tried to use <code>android:elevation="0dp"</code> but it didn't work for me, I tried <code><item name="android:windowContentOverlay">@null</item></code> on the style but it didn't work either, here's my code :</p>... | 3 | 1,202 |
Is there some neat way to make Threads (in Java) wait for theoretical time units as opposed to using Thread.sleep()? | <p>Currently working on a university assessment, so I won't share specifics and <em>I'm not asking for any explanation that will help me solve the main problem</em>. I've already solved the problem, but my solution might be considered a little messy.</p>
<p>Basically, we're working with concurrency and semaphores. Ther... | 3 | 1,117 |
ReactJS Call function inside a function error | <p>I have a project in <em>ReactJS</em>.</p>
<p>In <strong>onTaskHero</strong> function I'am trying to call <strong>setTheKick</strong> function but it show me an <strong>error</strong>.</p>
<p><strong>TypeError: Cannot read properties of undefined (reading 'setTheKick')</strong></p>
<p>This is because the function I w... | 3 | 3,892 |
Replace a function pointer in a shared library with ctypes | <p>I am trying to replace an existing function pointer in a shared library with a callback defined in Python, through ctypes.</p>
<p>The source of the shared library in C:</p>
<pre><code>#include <assert.h>
#include <stdio.h>
void (*plot)();
int c_main(int argc, void** argv) {
printf("plot is %p\n&... | 3 | 1,273 |
TensorArray is not updating values from tf.cond() | <p>Using Tensorflow 1.3 and python 2.7</p>
<p>TensorArray is not updating values from tf.cond(). </p>
<pre><code>import tensorflow as tf
temp1 = tf.TensorArray(dtype=tf.float32, size=0, dynamic_size=True)
temp2 = tf.TensorArray(dtype=tf.float32, size=0, dynamic_size=True)
temp1 = temp1.write(temp1.size(), tf.constant... | 3 | 1,067 |
Bootstrap- elements overlap on extra small size | <p>I have <code>recent-posts</code> div that show two post with their images and text. after <code>recent-posts</code> I have another div <code>contact-us</code> that contain an image and some text. My issue appear in extra-small size where <code>recent-posts</code> posts go under <code>contact-us</code> part. How can ... | 3 | 3,290 |
Trying to Convert a string to another string from array in a file on only the first space | <p>Disclaimer, I've been at java for about a month. I'm completely lost on this. I'm trying to have a user input a phrase and if any strings in that phrase is found on the array, it returns the corresponding string in one line. if the string isn't found, it would just skip it. </p>
<p>so if someone typed in "dog e... | 3 | 1,050 |
Understanding React Structure | <p>I'm having a few issues understanding how react works. I have the below code, and am wondering where I can do stuff with the returned DataRows</p>
<pre><code>function App() {
const [DataRows, setDataRows] = useState([]);
async function getPageData() {
const ShowId = window.location.pathname.split(&... | 3 | 1,203 |
JUnit/Mockito verifying `any(HttpPut.class)` however passes when other instances used too | <p>I have a service class that calls a REST API to get, create, update and delete subscribers. The Uri remains the same, but the HTTP method changes as you'd expect. I want to test the correct method is given. Below is an example of the updateSubscriber and its test.</p>
<pre><code>public class MyService {
HttpCl... | 3 | 1,199 |
Error when trying to create a Heatmap: '<=' not supported between instances of 'int' and 'str' | <p>I am trying to figure out the reason why I keep getting this error</p>
<pre><code>pt_gov = gov.pivot_table(values="Income", columns="Year", index="State", aggfunc="sum")
plt.figure(figsize=(32,20), dpi=150)
ax = sns.heatmap(pt_gov, cmap="viridis_r", annot=True,
... | 3 | 1,931 |
Underscore js to retrieve data from array | <p>I'm assigned a task to get data using underscore js. </p>
<p>This is my JSON :</p>
<pre><code>$scope.myData= {
"buslist":
{
"code":"1",
"message":"Success",
"fromStationCode":"71",
"searchResult": [
{
"arrivalTime": "17:00:00",
"availableSeats": "42",
"bo... | 3 | 1,518 |
How to grouping and summing Jarrays based on certain keys | <p>i have data and code like this for filtering by country and count it.
but i can only filter them one by one.</p>
<p>Data :</p>
<pre><code>[
{
"Name":"Amal",
"Country":"India",
"salary":"4.000,00"
},
{
"Name":"... | 3 | 1,185 |
Nonce function of blockchain in C. Concatenation of unsigned char array in C | <p>I try to add a nonce to my blockchain program. But when I test a program performance by trying to repeat the result (I need to be able to do to verify my chain), I do not get an identical result.</p>
<p>First I have a function which transform a <code>structure</code> to <code>unsigned array pointer</code> :</p>
<p... | 3 | 1,431 |
Get Google Refresh token from existing user auth code | <p>I'm trying to get the Google Refresh token, the thing is that i haven't seen my current scenario anywhere, what i'm trying to accomplish is get the refresh token from a user auth token already generated by a google sign in from a native android app, basically i request every google permission i need on the app, and ... | 3 | 1,794 |
Combining queries in a SQL Server stored procedure | <p>I want to combine privileges from the user and their roles in a stored procedure. To do so currently I am running many queries. The first gets the roles the user has. Then a query to get the privileges for each role. Then a query to get the privileges for the user. Then I combine them all from the code. I would like... | 3 | 1,351 |
dropdown hover not staying open in IE9 | <p>I swear I have done something this simple dropdown a million times, but for some reason IE9 doe snot want to cooperate. If you are testing it in Chrome it will work just fine, but go to IE9 and the dropdown doesn't stay open while being hovered. </p>
<p>At first I thought I was adding the pseudoclass :hover to the ... | 3 | 2,566 |
MulterError: Unexpected field at wrappedFileFilter in Insomnia | <p>I'm trying to upload a picture where the user registers in the app. When I'm trying to test it in insomnia I get the following error: <strong>MulterError: Unexpected field at wrappedFileFilter</strong></p>
<p>I've been reading online and I know this error occurs when there is a mismatch between the field name provid... | 3 | 1,741 |
How to fix code have select all asp:CheckBoxList within current table only in .NET C# same as "JQuery - Select All CheckBoxes within..." question? | <p>How to fix code have select all <strong>asp:CheckBoxList</strong> within current table only in .NET C# same as "JQuery - Select All CheckBoxes within current table only" question ?</p>
<p>Because I try coding with sample but can't select all <strong>asp:CheckBoxList</strong> within current table only.</p>
<p>Link ... | 3 | 5,621 |
RequestParam shows null value | <p>I'm trying to retrieve the value from view and use it in controller by using RequestParam. However, the RequestParam attribute shows null.
Below is my code -
JSP Page</p>
<pre><code> <form th:action="@{/schedule}" method="post">
<!-- page start-->
<div class=&quo... | 3 | 2,923 |
How send and receive a enum parameter? | <p>How send and receive a enum parameter?
I have several type enum and I want to make a generic method to get of descriptions</p>
<pre><code> public enum Lista_Size
{
[Description("Chica")] Chica,
[Description("Grande")] Grande,
[Description("Extra Grande")] Extra_Grande,
}
public enum Lista_Color
{
[... | 3 | 2,535 |
Make empty table cells transparent | <p>The title is pretty much self-explanatory.</p>
<p>I have also tried the answer from here without any success as you might guess:</p>
<blockquote>
<p><em>"<a href="https://stackoverflow.com/questions/23583774/how-to-make-background-of-table-cell-transparent/28142391">How to make background of table cell transpar... | 3 | 1,767 |
How to handle generated at JAVA side JSF Form? | <p>I'm generating my JSF Form html element at java (adding inputs, labels, etc) at <code>parseHtml()</code> method. I need to handle it. When I'm putting to every input value #{foo.bean} it shows me this symbols into input. How to do it correctly?</p>
<pre><code> @ManagedBean(name = "parserBean")
@RequestScoped
pub... | 3 | 2,007 |
Bootstrap Row spacing issue | <p>So basically I want to have 2 extra panels show up on the left and right on md and higher, but hide it when on sm and xs. The hiding works fine, but not the showing. </p>
<p>They do show up on the left and right, but the problem is the spacing between the crumbs and navigation. The crumbs get pushed down as I add ... | 3 | 1,526 |
R difference between vector elements, split into columns | <p>I have a vector of values:</p>
<pre><code>data <- c(3L, 4L, 6L, 9L, 11L, 14L, 22L, 33L, 34L, 35L, 38L, 46L, 48L,
49L, 55L, 56L, 64L, 69L, 70L, 71L, 81L, 85L, 87L, 90L, 94L, 97L,
99L, 100L, 102L, 112L, 115L, 118L, 123L, 125L, 131L, 139L, 144L,
145L, 156L, 159L, 160L, 161L, 162L, 163L, 165L, 167L, 168L, 170L,
... | 3 | 6,580 |
Why the "/index" redirect to the UnauthorizedUrl in shiro? | <p>I test the shiro with springboot,but no matter what urls like 127.0.0.1:8080/index are redirected to the the UnauthorizedUrl("/error");</p>
<p>Here is my ShiroConfig:</p>
<pre><code>@Configuration
public class ShiroConfig {
@Bean(name = "lifecycleBeanPostProcessor")
public LifecycleBeanPostProcessor lifec... | 3 | 2,048 |
Generalizing a reference counting class for use with non-specific protected classes | <p>Trying to retro-fit a non-COM class with reference count based protection that prevents its deconstruction when any of its members methods are currently in process.</p>
<p>Wrote a small class designed to call AddRef on construction, and Release on deconstruction; declare an instance upon entry into the protected cl... | 3 | 1,436 |
Problem resolving Nuget Packages in Devops Build Agent due to Certificate issues | <p>We are hosting DevOps Server on Premise with one Build Agent. The Build agent behave strange if i start running NuGet restore against .NET 5.0 Project. In special against a Test Project Template from VS2019 (MS-Test Testproject). As soon as i run the Nuget restore it failed with a loot of 'NU3028' 'NU3034' 'NU3037' ... | 3 | 6,194 |
React table loads but disappears on clicking pagination links | <p>I am new to React and trying to develop my first web application. What I am trying to achieve is pretty basic. I am trying to fetch some data from an API and display it in a table. To the table I am trying to add pagination so that all the records are not displayed on the same screen. I have added the page numbers b... | 3 | 2,623 |
gerrit throwing an gerrit@localhost: Permission denied (publickey) error | <p>I have setup the Gerrit using docker-compose.</p>
<p>ref doc: <a href="https://github.com/GerritCodeReview/docker-gerrit" rel="nofollow noreferrer">https://github.com/GerritCodeReview/docker-gerrit</a></p>
<p>I am trying to login on the Gerrit server using SSH protocol.
http is working fine. but i need ssh as well f... | 3 | 3,191 |
IPv6 Server in c - recvfrom failed | <p>i have written a small c-program for an IPv6 server with winsock2.h When I run the program in Visual Studio, I get the following message all the time: recvfrom failed</p>
<p>I just can't find the error in the recvfrom function. Maybe someone can see why my program does not work at this point, thanks! :-)</p>
<p>B... | 3 | 1,066 |
How the xpath should be like to get this value | <p>How the xpath should be like to return the value <code>Rua Jorge de Lima, Boa Viagem</code>?</p>
<blockquote>
<p><code>xpath('//div[@class="simple-card__actions"]/p[@class="color-dark text-regular simple-card__address"]')</code></p>
</blockquote>
<p>I have been tried to get this value inside HTML... | 3 | 3,523 |
Why not @Valid trigger the validation with hibernate validator ? | <p>I am trying to validate a incoming Json request when it is getting bind in Spring Boot controller with <code>Hibernate- validator</code>. Here is my simple Boot application</p>
<pre><code>@SpringBootApplication
@RestController
public class ValidationTestApplication {
private static final Logger logger = LoggerFact... | 3 | 1,674 |
How to make series in HighCharts change Dynamically using Javascript and not Jquery | <p>I have searched all over the Stack Overflow Website and can't find a Perfect Solution. So someone who is good at HighCharts can help me out.
Any answers will be Appreciated.....Please answer in Javascript and not Jquery....
Generally I am creating empty variables in Series according to my usage.But I want them t... | 3 | 1,366 |
Attaching a Listener to JTree | <p>I previously asked this question: <a href="https://stackoverflow.com/questions/23900512/jtree-selection-issue">JTree selection issue</a></p>
<p>Which was answered by <a href="https://stackoverflow.com/users/177145/aterai">https://stackoverflow.com/users/177145/aterai</a> with the following code:</p>
<pre><code>im... | 3 | 3,203 |
C++ - cin.get() requires user to press enter twice | <p>In my code I added an <code>if</code> statement which captures an empty string if the user accidentally presses the "enter" key. Without this piece of code the program will crash, below is the link to the screenshot:</p>
<p><a href="http://gyazo.com/59cfe26c76043022b807d533f932838d" rel="nofollow">http://gyazo.com/... | 3 | 1,718 |
AWS Instance Fleets with multiple ec2 types | <p>I am getting ready to move my team to AWS instance fleets. Thus far in testing, it's been great; it has really helped with capacity issues via instance diversification.</p>
<p>However, I expected AWS would choose a mix of instances based on the types I supply to the instance fleet template. For example, I target 15 ... | 3 | 1,568 |
Devart/EFCore Permanent failure if First Query attempted while DB server is unavailable | <p>We have several microservices built on top of aspnetcore and entity framework and using the MySQL EntityFramework connector from Devart. I've noticed that if the first query that any of our applications attempts fails due to the data store being inaccessible, then the failure seems to be cached, and when the DB is f... | 3 | 3,464 |
Vue/VueX date or text input with v-model doesn't reset after failed change | <p>I'm using computed properties in a Vue form component to bind input fields to model properties with one-way data flow. This works fine with <code><input type="number"></code>:</p>
<pre class="lang-html prettyprint-override"><code><input v-model.number.lazy="copies" type="number"... | 3 | 1,243 |
xdebug failing to go into the laravel app | <p>I'm a big fan of using xdebug with laravel (esp in <a href="https://vi.stackexchange.com/a/14161/14510">vim</a>). However recently something weird has been happening (Note: my xdebug works perfectly when I'm running it on unit tests with this command: </p>
<blockquote>
<p>php -dxdebug.remote_enable=1 -dxdebug.rem... | 3 | 2,425 |
SVN - Sparse Checkout Files of Certain Type -or- Matching Certain Pattern | <p>I am working with a massive SVN repository -- which is made up of hundreds of directories (all at varying depths), and thousands of files (all of varying types). I need to make bulk updates to a couple hundred JavaScript files contained in this repo. Instead of downloading the entire repo, I was hoping to selectivel... | 3 | 1,839 |
when attaching submit event to my form, the form is submitted with default handler | <p>This happens in IE and Firefox. Not in chrome.</p>
<p>I have this form:</p>
<pre><code> <form id="enviaEmail" method="post">
<label for="nombre">Nombre</label>
<input id="nombre" type="text" name="nombre" required="" />
<label for="apellido">... | 3 | 1,792 |
How can i return value from async block? | <p>This is the function I want to return value from but I know I am doing fool thing to return value from a closure that I used in from a library and it returns void, I think it is async void block, I am new in it please help. :(</p>
<pre><code> func xmlRequest(_ id:Int) -> String{
var array1:Array<... | 3 | 1,202 |
Use patient ID to retrieve specific record from Access DB | <p>I have an Access database containing fictional patients, along with various data (such as address, consultation notes and date), and so forth.</p>
<p>I have set it up so that each time a record is committed to the database, it is given a unique ID number, i.e 1001, 1002, and so on.</p>
<p><strong>(For those who ar... | 3 | 1,804 |
whmcs invoice in new tab | <p>I want to open the invoices of whmcs in a new tab or a popup window.
The biggest part of this problem is solved but one thing remains a problem. I used some js to open up the invoice in a new tab, but on the original page, after opening the invoice, it also loads and returns a 404. The invoice opens without any prob... | 3 | 1,371 |
Tumblr like button not working for my tumblr blog | <p>Tumblr like button is not working for my Tumblr blog, the button's color change after clicking but after refreshing the page no updates happen</p>
<p>URL: <a href="http://cs.jumzler.com/" rel="nofollow">http://cs.jumzler.com/</a></p>
<p>HTML code: `</p>
<pre><code>{block:Posts}<p align="right"><div class... | 3 | 1,528 |
The application crashes on a StackOverflow error | <p>The application crashes from time to time on a StackOverflow error with the <em>stacktrace see below</em>.</p>
<p>The error occurs unexpectedly in various scenarios. We are not able to simulate it or predict its occurrence.</p>
<p>Is there any workaround for this bug in version 5?
Or maybe there is a chance that thi... | 3 | 3,102 |
Loading trained model to make prediction of single image | <p>I have trained a ResNet50 model on intel image multiclass classification task. The task is trying to predict an image whether it is a building a street or glacier etc. The model is succesfully trained and able to make prediction. I have save the model and trying to use the saved model on new image.
Here is the code ... | 3 | 1,152 |
how to add class 'active' to nav item whose href is in the location.pathname | <p>I'm trying to build on top of a Jekyll template to build a blog style site. I'm currently in the process of writing and styling the navigation, which is giving me a couple of problems. Using the answer to <a href="https://stackoverflow.com/questions/20060467/add-active-navigation-class-based-on-url">this question</a... | 3 | 1,069 |
Parsing an XML file properly for CSV output | <p>I've built out this script that is meant to parse an XML file and retrieve the contents of the id, created-date, author-id and comments nodes and print them to a CSV. It's <em>mostly</em> working with one exception...</p>
<p>I'm running into a problem where the script is looping through every id in the XML and prin... | 3 | 1,490 |
Using csv data file for reducing the length of the code gets error a.all() or a.any() | <p>I wrote the following code. for fast running and briefing, I write a <code>31*31</code> matrix in a <code>csv</code> file as we can see in <code>CovSN</code>. I wonder how should I do it for <code>xx</code> and <code>yy</code> to remove <code>for loop</code> and <code>f_list[]</code> in <code>def SN(Om, A, al, M):</... | 3 | 1,364 |
No error, but some functions of a library don't make their work | <p>I am using cdi (climate data interface, <a href="https://code.zmaw.de/projects/cdi/wiki" rel="nofollow">https://code.zmaw.de/projects/cdi/wiki</a> ) to create a netcdf file. I made the example in the documentation to write a netcdf file, and it works ok. But when using cdi operatively for the first time, it doesn't ... | 3 | 1,048 |
How to use "oneOf" in this schema? | <p>I'd like to have either A or B, but not both (mutual exclusive.)</p>
<p>I have to use whatever is avaliable in Draft 3, even though it says 4 on the top. Reason being, when using array for "required", it throws an error that it can't convert an array to a boolean. If I remove arrays without putting that I'... | 3 | 1,212 |
When is `__index__` called for lists and numpy arrays? | <p>Since some days ago I was unaware of the <code>__index__()</code> method until reading <a href="https://stackoverflow.com/questions/49633222/slicing-elements-from-a-python-list-using-boolean-indexing">this question</a>. After that, I have been reading about it in the <a href="https://docs.python.org/3/reference/data... | 3 | 1,241 |
XML deserialization stuck | <p>I've generated a xsd file from xml and then <code>priceResponse.cs</code> from xsd file using <code>xsd.exe</code>.</p>
<p>Here is <code>priceResponse.cs</code> code:</p>
<pre><code>using System.Xml.Serialization;
//
// This source code was auto-generated by xsd, Version=4.6.1055.0.
//
/// <uwagi/>
[Sys... | 3 | 5,032 |
angular bootstrap lightbox throws unknown provider error | <p>Am newbie to AngularJS and trying to learn stuffs. I am trying to create a gallery with <strong><a href="https://github.com/compact/angular-bootstrap-lightbox/blob/master/src/lightbox.html" rel="nofollow"><code>angular-bootstrap-lightbox</code></a></strong> and I've included all the necessary dependencies required f... | 3 | 1,652 |
Need to convert piece of PHP code to C# | <p>I need to convert two PhP functions (sfGetCategoryAllTree and sfSideTree) to C#. I'm not used to PhP at all. I will show you the functions and what I did by now.</p>
<pre><code>/**
* Retrieves user data given a user id or user object.
*
* @param string $output Optional, default is Object. Either OBJECT, ARRAY_A,... | 3 | 2,146 |
XML data save in NSUserDefaults or in Documents Directory | <p>I am making an simple news app, and trying to save (title, description, date, image with its data) in NSUserDefaults for offline read. I want when it save data in NSUserDefaults, it shows in offline and also when new data is available it rewrite or replace with previous data.
I know how to save string arrays in NSUs... | 3 | 4,415 |
Wxpython - convert static positioning to sizer | <p>I have been using static positioning in wxpython for a while now but need to switch to using sizers, but I just can't get the hang of it. Below is a cut down version of my application using static positioning. could someone give me some pointers as to how I go about converting this layout to using sizers please. I w... | 3 | 1,753 |
What is the right way to safely finish goroutines in my code? | <p>I am writing a simple tcp server, the goroutine model is very straight forward: </p>
<p>One goroutine is responsible for accepting new connections; for every new connection, three goroutines are started :</p>
<ol>
<li>one for read</li>
<li>one for process and handle application logic</li>
<li>one for write </li>
<... | 3 | 1,444 |
jQuery classList.toggle not working properly | <p>I'm new to javascript and i'm trying to get 2 functions to work when click on a button;
first function is to transform the menu button to an "X" (typical 3 lines menu icon)</p>
<p>the second function is, <code>TranslateX</code> the <code>#mobileMenu</code> so it enters the screen from the left.</p>
<p>The first f... | 3 | 1,726 |
href won't work when using frames and expandable lists | <p>I have a website that includes two frames. One on the left for Table of contents and one on the right. The table of contents on the left is an expandable list which I implemented using jquery. Each of the final children is a hyperlink for another html that will be opened in the frame on the right.</p>
<p>The code fo... | 3 | 1,318 |
App crashes after custom cell is created 250 times | <p>I use a custom cell in my app. When a user taps a table row, a custom cell appears:</p>
<pre><code>#import "SonaraamatuKontroller.h"
#import "TolkegaLahter.h"
//Lahtris kasutatava teksti fondi suurus
#define FONT_SIZE 14.0f
//Tabelilahtri laius
#define CELL_CONTENT_WIDTH 320.0f
//Tabeli sisu äärise kaugus lahtri ... | 3 | 4,316 |
handle edit action in a data table | <p>I have a form with 3 input fields and two command buttons(Submit and Cancel). Once the user submits the form, the information should be populated in the data table below with 3 columns.There is also a action column with EDIT and DELETE command links for each row inserted. On click of EDIT, the information for that r... | 3 | 1,483 |
makemigrations results in django.db.utils.OperationalError: no such column: (Python 3.10 and Django 4.0.3) | <p>First, and this is really important, this error is being returned WHEN I run <code>python manage.py makemigrations</code> (Python 3.10 and Django 4.0.3)</p>
<p>In my research of the many instances of this error I've seen that as the first suggestion for this particular error message. Unfortunately this issue is NOT ... | 3 | 8,039 |
GLWF capturing mouse leads to a segmentation fault | <p>For an opengl veteran this is probably easy, but I am completely new to opengl and I am currently working through a tutorial.</p>
<p>I am now at the point where it is about to capture mouse events (to setup camera movement).</p>
<p>However, although I am running the original code from the author, I am getting a se... | 3 | 2,265 |
Can/Should custom $resource action methods be tested? | <p>In a angular service I have $resource action methods such as :</p>
<pre><code>class FooService {
/*@ngInject*/
constructor($resource) {
this.Foo = $resource('/foo/:fooId/',
{fooId: '@fooId'},
{
bar: {
... | 3 | 1,193 |
Facebook - The proxied app is not already installed | <p>I am working on an an android app that requires facebook login. But when I try to login i keep getting the error : <strong>The proxied app is not already installed</strong></p>
<p>I am asking for only email permission. No publish permissions are asked.</p>
<p>The following is my code:</p>
<pre><code>package com.z... | 3 | 5,126 |
get all nodes from multi level hash in perl | <p>I want all nodes of each key sorted by key in hash ref or array or something like so that I can iterate that according to my need since I have to display each key with its all children.
following is my data structure:</p>
<pre><code> $hash1 = {
'3' => {
'title' =&... | 3 | 2,501 |
How to send push notifications form javascript using quickblox | <p>I am trying to send push notifications messages through Quickblox from my backend server. The code that does this goes like the following:</p>
<pre><code> app.post('/requests', function(req, res) {
var mobileNumber = req.param('mobile_number');
if (typeof mobileNumber === 'undefined') {
return ... | 3 | 2,675 |
Why is my Python timer class not working? | <p>I'v written my own class to measure the time of different parts of my script:</p>
<pre><code>class SimulationTimer:
accumulated_elapsed_time = 0.0
def __init__(self):
self._simulation_start_time = None
self._simulation_stop_time = None
def start(self):
"""start a... | 3 | 1,184 |
images from database not getting loaded in Jssor Slider | <p>Hi I am working on integrating JSSOR slider with my database images.</p>
<p>I added code in my index.html.</p>
<pre><code><div id="slider1_container" style="position: relative; top: 0px; left: 0px; width: 600px; height: 327px; background: #fff; overflow: hidden; ">
<!-- Slides Container -->
<... | 3 | 3,607 |
Using sed with regex to remove text from a file | <p>I'm trying to use sed with regex to remove specific patterns from a file.
Here is the command I'm using:</p>
<pre><code>sed '/location .*?\/\s+{(?:[\w\W]+?)}\s*(?=(?:location|$))/d'
</code></pre>
<p>Here is a sample text I'm testing with:</p>
<pre><code>location / {
try_files $uri $uri/ /index.php?$a... | 3 | 1,590 |
An error occurred when trying to create a controller of type 'xxx'. Make sure that the controller has a parameterless public constructor. Ninject | <p>I am working in .Net framework 4.7.2. I am facing a problem while using NInject dependency injection resolver. I am getting the following error when trying to access NotificationController, which has no parameterless constructor:</p>
<pre><code>"Message": "An error has occurred.",
"Excep... | 3 | 5,848 |
IDR - File is not valid PE | <p>I want to reverse old .exe file; I'm 90% sure it is Delphi (class names are being with 'T' => "TCommonDialog")</p>
<p>I can't load file into IDR (becouse it is not valid PE-executable?) jet still .exe works just fine and icon is showing just right.</p>
<p>I was trying to maniupulate header but every time I just co... | 3 | 3,163 |
error 10011 Unknown role with present defined role | <p>I'm trying to create a reactroles function for my server, I've gone through hundreds of stack overflow and reddit forums to find bits and pieces to make this work but nothing has fixed this last error.</p>
<p>The roles are present on my server and properly defined (as far as i know) in the code but still returns err... | 3 | 1,172 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.