title stringlengths 13 150 | body stringlengths 749 64.2k | label int64 0 3 | token_count int64 1.02k 28.5k |
|---|---|---|---|
Android: not able to trace down a ClassCastException with SimpleExpandableListAdapter | <p>I get the following exception running my program:</p>
<pre><code>05-12 08:29:06.907: ERROR/AndroidRuntime(460): FATAL EXCEPTION: main
05-12 08:29:06.907: ERROR/AndroidRuntime(460): java.lang.ClassCastException: java.util.ArrayList
05-12 08:29:06.907: ERROR/AndroidRuntime(460): at android.widget.SimpleExpandable... | 2 | 2,418 |
Check if a form is dirty and inform user before dynamically removing it | <p>My page has a list of forms. Each form will be dynamically built by D3 when the user clicks on the form name in the list. Below is the code:</p>
<p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
<div class="snippet-code">
<pre class="snippet-code-js lang-js prettyprint... | 2 | 2,364 |
NullPointerException when trying to set item texture - minecraft 1.8 modding | <p>I'm learning how to java and trying to build a minecraft mod. </p>
<p>The problem is I'm having trouble with the 1.8 item texture adding system and even though Google is my best friend I still haven't found what I should do to fix this NPE. </p>
<p>Here is the Base Mod class:</p>
<pre><code>package rocha.sekai;
... | 2 | 1,331 |
Installation of MS Build Tools fails on Windows Docker Container | <p>I'm trying to set up a Windows container for a CI pipeline.
My Project uses C++ and CMake, so I'm using the Microsoft Build Tools installer.</p>
<p><em>Note: I do not intend to use any part of the .NET framework for my project</em></p>
<p>Unfortunately, the installation of MS Build Tools in my Docker container fai... | 2 | 3,275 |
There is Error While Installing twisted in pipenv | <p>I was trying to install twisted in pipenv for my project But I came across this error I will be thanked if anyone help me. I am using python=3.8.2</p>
<p>I install the package by this command:</p>
<pre><code>pipenv install twisted
</code></pre>
<p>Here's the error</p>
<pre><code>Installing twisted…
Adding twisted to... | 2 | 4,549 |
Including objects to a shared library from a C++ archive (.a) | <p>I am trying to include some object files into a shared library I am building. Take the following command (things in [ETC] have been omitted for brevity):</p>
<blockquote>
<p>/usr/bin/c++ -fPIC -std=c++14 -pthread -Iinclude/ext/liveMedia -Iinclude/ext/groupsock [ETC] -g -shared -Wl,-soname,libValkka.so -o lib/lib... | 2 | 1,065 |
Pushwoosh create message get 200, but say UnknownDevices | <p>My system running at least two years. Most push notification requests got 200. But, recently, I found I got 500 frequently. </p>
<p>Nealy 10% push notifications got 500.</p>
<p>Please HELP!!!</p>
<p>I have resend the problem messages, every thing is fine. </p>
<p>Example:
Request is: </p>
<pre><code>{
"reque... | 2 | 1,363 |
System.Import in Typescript not overriding the default path | <p>I am a newbie to Typescript and Angular2.I have an <code>app</code> folder where I am creating ts files and I am trying to generate transpiled 'js' files to another folder built. 'Js' files are being generated successfully but when I try to <code>import</code> the files to html using <code>System.import('built')</co... | 2 | 1,026 |
How to do yahoo integration in Android? | <p>I'm developing a yahoo login integration in Android App and return into main Activity. I have completed all the steps of yahoo integration.I have spent several days for searching yahoo integration in android but i cant find proper way.When i run this code and proper sign in yahoo email and when i click agree button ... | 2 | 2,015 |
Bootstrap inside Django block | <p>I am creating a couple pages for my website by extending a base.html template that I made. I want to be able to put bootstrap forms on some of the pages, but when I have the <code>{% bootstrap_form formname %}</code> tag inside the <code>{% block content %}</code> tag I get an error: <em>Invalid block tag: 'bootstr... | 2 | 1,406 |
Unexpected result for a type counter using templates with function local types in Clang | <p>I wrote a class template based on two types that is assigned a unique index based on its template parameters:</p>
<pre><code>template<typename SK,typename T>
struct Component {
static uint const index;
};
</code></pre>
<p>The expectation is that for each new type, <code>index</code> is incremented:</p>
... | 2 | 1,657 |
Access Buttons VBA Problems and Subform Issues | <p>Im working on a key inventory database. Something to manage who signs out room keys and when they bring them back in. I've created the tables I plan on using and have started working on the forms. However, I am having trouble getting the forms/subforms to work as desired. </p>
<p>I've created buttons to add/edit/de... | 2 | 1,185 |
Invoking an href click event JavaScript in winforms webbrowser control | <p>I`m trying to automatically login into one of the online browser games from my application. However when I inspect the login button, I see this html code.</p>
<pre><code><div id="js_login_button">
<a href="#" onclick="$('#login_submit_button').click()" class="login_button">
... | 2 | 1,855 |
how to gone toolbar menu when collapsed appBarLayout in android | <p>I want <strong>gone</strong> <code>toolbar</code> Menu when <strong>collapsed</strong> <code>appBarlayout</code>, but I don't know how can it.<br>
<strong>My code is here:</strong></p>
<pre><code> public class MainFragment extends BaseFragment implements Toolbar.OnMenuItemClickListener ...
@Override
... | 2 | 1,608 |
JavaFX TableView bold whole row iff `message.isUnread()==true` | <p>I am trying to replicate Gmail behavior in Javafx TableView. Row of new Unread message should be shown in bold. Here is what I was able to do so far:</p>
<p><a href="https://i.stack.imgur.com/CzQXg.jpg" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/CzQXg.jpg" alt="enter image description here"></a><... | 2 | 2,743 |
I am facing an issue to Google Sign in IN IOS 13.1 | <h2>At the time for calling this (GIDSignIn.sharedInstance().signIn()) is Showing error ("reason: 'presentingViewController must be set.')</h2>
<p>Full Error below</p>
<blockquote>
<p>2019-10-25 12:12:31.060880+0530[7575:70886] <strong>* Terminating app due to uncaught exception 'NSInvalidArgumentException', reason... | 2 | 1,617 |
Andengine - Shooting bullets in front of a rotating sprite (Turret / Ship) | <p>I'm making a game with Andengine and i'm stuck for 2 days on shooting from a rotating sprite. I'm not a hero at geometry and already ask a teacher but he could also not provide me the correct answer. So who is a mathematics hero and help me out :).</p>
<p>The problem is that i cannot figure out where the bullet has... | 2 | 1,476 |
Tic Tac Toe C++ algorithm debugging help | <p>Please help me understand why this isn't working. I don't know if there is a bug in my code, or whether my algorithm is fundamentally logically flawed. </p>
<p>My algorithm is based on minimax, but I've forgone a heuristic evaluation function for a more simple technique. Because of the simplicity of plain 3x3 tic... | 2 | 1,115 |
How to instantiate AsyncTask | <pre><code>package com.markana.yamba;
import winterwell.jtwitter.Twitter;
import winterwell.jtwitter.TwitterException;
import android.app.Activity;
import android.graphics.Color;
import android.os.AsyncTask;
import android.os.Bundle;
import android.text.Editable;
import android.text.TextWatcher;
import android.util.Lo... | 2 | 1,947 |
Javascript not working when uploading file to AWS S3 via presigned URL | <p>I generate a pre-signed URL for uploading files to AWS S3 via a Python-backed API. This part receives filename info once the user selects the file in a browser (see below), and returns a JSON payload (see below) with the base URL and fields.</p>
<pre class="lang-py prettyprint-override"><code>import logging
import b... | 2 | 1,517 |
How to make sure Synfony Entity is loaded to trigger postLoad event? | <p>I'm new to Symfony and following <a href="http://jobeet.symfony.gr.jp" rel="nofollow">the Jobeet tutorial</a>. I'm trying to inject Container into Entity using service listener and <code>postLoad</code>. The purpose is to use <a href="https://github.com/liip/LiipImagineBundle/" rel="nofollow">LiipImagineBundle</a> t... | 2 | 1,804 |
How do I parse nested objects with Retrofit 2? | <p>I'm consuming a <code>newsapi</code> whose JSON response is similar to this;</p>
<pre><code>{
"status": "ok",
"articles": [
{
"source": {
"id": "bbc-news",
"name": "BBC News"
},
"author": "BBC News",
"title": "Jubilation greets end of Mugabe era",
... | 2 | 1,917 |
How to use custom validator in Grails | <p>I'm new in Grails. I would like to use custom validator for matching two passwords during registration in my application. Unfortunetly doesn't work it.</p>
<p><strong>Account.groovy</strong></p>
<pre><code>@Validateable
class Account {
String login
String password
String confirm
String passwordHas... | 2 | 3,334 |
How to sign (x.509) XML element? | <p>I need sign a XML file with <code>X.509</code> certificate</p>
<p>In this moment I have (copy form msdn)</p>
<pre><code> public static void SignXml(XmlDocument xmlDoc, X509Certificate2 uidCert)
{
RSACryptoServiceProvider rsaKey = (RSACryptoServiceProvider)uidCert.PrivateKey;
// Check argu... | 2 | 1,079 |
How to set heightForRowAt based the number of numberOfItemsInSection? | <p>I'm using <code>UITableViewController</code> and put <code>UICollectionView</code> in second row in Table View Cell. The problem is how I can get heightForRowAt dynamically. </p>
<p>I have tried using <code>return UITableViewAutomaticDimension</code>. But not working.</p>
<p>Any help is really appreciated.</p>
<p... | 2 | 1,026 |
python sqlite not returning None even though it is None? | <p>This is an assignment I have to do for an online course. We are learning about data modeling and relational databases. For this assignment, We have to take input data from an iTunes xml playlist file and put them into a database. Here is the code:</p>
<pre><code>import xml.etree.ElementTree as ET
import sqlite3
c... | 2 | 4,994 |
Clear all SharedPreferences android | <p>Iam saving my user login details into my SharedPreferences file. The problem is when I try to clear the ShredPreferences, the details dont clear. When the next user logs in his details are not shown.</p>
<p>Here is my code:-</p>
<p>Save.java</p>
<pre><code>sessionManager.createLoginSession(username, deviceId, na... | 2 | 1,818 |
In Spring WebClient used with block(), get body on error | <p>I am using WebClient from Spring WebFlux to communicate with a REST API backend from a Spring client.</p>
<p>When this REST API backend throws an exception, it answers with a specific format (ErrorDTO) that I would like to collect from my client.</p>
<p>What I have tried to do is to make my client throw a GestionUti... | 2 | 1,682 |
display data from XML using php simplexml | <p>I have a piece of XML which is as follows</p>
<pre><code><records count="2">
<record>
<firstname>firstname</firstname>
<middlename>middlename</middlename>
<lastname>lastname</lastname>
<namesuffix/>
<address>
<street-number&g... | 2 | 1,761 |
Display filtered ffmpeg frame with GTK | <p>I want to display cropped and scaled frames using the ffmpeg api and I am using GTK+ 3 for the GUI components. From following the <a href="http://jan.newmarch.name/LinuxSound/Diversions/Gtk/#heading_toc_j_11" rel="nofollow">this tutorial</a> and the <a href="http://ffmpeg.org/doxygen/trunk/filtering_video_8c-exampl... | 2 | 5,858 |
Using Ansible playbook to create instances in google cloud (gcp) | <p>I'm using the following code </p>
<pre><code>- name: create a instance
gcp_compute_instance:
name: test_object
machine_type: n1-standard-1
disks:
- auto_delete: 'false'
boot: 'true'
source: "{{ disk }}"
metadata:
startup-script-url:
cost-center:
labels:
enviro... | 2 | 1,218 |
My simplified neural network can't learn XOR gate | <p>I'm trying to validate the results of the book: <a href="http://www.academia.dk/BiologiskAntropologi/Epidemiologi/DataMining/Artificial_Intelligence-A_Guide_to_Intelligent_Systems.pdf" rel="nofollow noreferrer">'Artificial Intelligence: A guide to Intelligent Systems 2nd Edition' by Michael Negnevitsky</a>, pages 18... | 2 | 1,583 |
Django Rest Framework is it possible to serialize a geojson from a query using a geometry_field via foreignkey? | <p>I have two models: one to maintain a grid of points and a second one to save geospatial data</p>
<pre><code>from django.contrib.gis.db import models as geomodels
from django.db import models
class Grid(geomodels.Model):
geom = geomodels.PointField(srid=4326, unique=True)
elevation = geomodels.FloatField(b... | 2 | 1,609 |
Use one button for both save and edit on Gridview in c# | <p>I have a scenario where I can save the name and phone number. but now I want to use my "Save" button as update button from clicking on grid view data.</p>
<p>Also after clicking on gridview data "save" button automatically change as "Update"
I want to know if there is any event or something to make it. </p>
<p>Scr... | 2 | 1,904 |
Read inner attribute/tags in RSS Items like (media:content) in windows phone 8 | <p>I recently had a problem with xml parsing in my Windows Phone 8 application, I can read all tags in the XML feed like title, description, etc. straight away. But I'm not able to get the inner attribute from tags which is contains a ":" symbol for example: <code><media:content ... /></code> or <code><media:... | 2 | 2,166 |
Android - retrieving json via HTTPS | <p>I've a problem with parsing json from facebook graph api.<br>
When I'm using facebook URL:<br><code>https://graph.facebook.com/interstacjapl/feed?access_token=MyTOKEN</code> to grab json it's no working, but when I copied that json (it works in browser) and paste to my webiste <code>http://mywebsite/fb.json</code> a... | 2 | 3,000 |
Valgrind reports hundreds of errors in Hello World program on RaspberryPi 4B | <p>I have RaspberryPi 4B with latest Raspbian fully updated. I am trying to make things work like on RaspberryPi 3B, but even simple <code>hello_world.c</code> executed via <code>valgrind</code> is not without errors. Installed valgrind version is <code>valgrind-3.7.0</code>. </p>
<p>When I run this hello world progra... | 2 | 1,808 |
Verify if user is authenticated in symfony2 | <p>I tried to create a simple login application in symfony2 and I don't understand a thing.
My routing file :</p>
<pre><code>shop_show_login_page:
path: /login
defaults: { _controller: ShopDesktopBundle:User:loginPage }
shop_login_user:
path: /loginUser
defaults: { _controller: ShopDesktopBundle:User:loginCheck }
</c... | 2 | 1,934 |
:CSS keyframe elements animate only when visible in viewport? | <p><a href="http://www.samnorris.co.nz" rel="nofollow">http://www.samnorris.co.nz</a></p>
<p>In the About section under 'Proficiencies' I have a "Skills Progression Bar" list made with CSS, which is supposed to animate using keyframes - but the animation cannot be seen on my page presumably because it is running as so... | 2 | 1,525 |
Drawing a rectangle bounding box on PDF to get coordinate but inner rectangle filled with white color!! I tried this with online example code only | <p>In this code, I have preview the PDF and I can able to draw the bounding box but its filling white color and added screenshot of mine. I can able to get the coordinate using (check it in the console) but the inner text is not visible apart from I need to copy the coordinate once I drew the rectangle in mouse listene... | 2 | 8,397 |
Sending e-mail with inline images using JavaMail API | <p>I am using the following code to send a email along with the image and it is working perfectly. When I send the image, it is getting displayed in the body instead of getting attached in the e-mail. So, that I can easily download that image from the attachment.</p>
<p>Is there any way to add image in the attachment ... | 2 | 1,497 |
Throttle function (lodash inspired) to handle resize event using React hooks only (with Sandbox) | <p>Sorry for the long question, but I needed to make an introduction in order to make it clearer.</p>
<p>I was in need of some code to toggle between my Headers components <code><HeaderDesktop></code> and <code><MobileHeader></code>.</p>
<p>At first I was using CSS media queries to toggle between them usi... | 2 | 1,403 |
swift: Parsing JSON data from alamofire into Dictionary with Array | <p>I have the below <code>JSON</code> response and i want to get the <code>id</code> for the hit objects</p>
<pre><code>{
"totalHits":500,
"hits":[
{
"largeImageURL":"https://pixabay.com/get/ea32b90a2af3073ed1584d05fb1d4190e070e4d71aac104491f1c270a0eeb7b0_1280.jpg",
"webformatHe... | 2 | 1,856 |
Spring batch xmlns xsd schema error | <p>I am developing an application using Spring Batch in eclipse</p>
<p>Error I while starting the server is</p>
<pre><code>SEVERE: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
org.springframework.beans.factory.BeanCreationException:
... | 2 | 2,880 |
Get values from JSON result C# | <p>I am trying to get the values from a computer vision api result from reading text on an image using Azure. The output is JSON data but the syntax of the result looks strange.</p>
<p>Ultimately I am trying to get the value "text" stripped out of it and written to a text file without any escape characters etc. </p>
... | 2 | 1,228 |
Retrofit GSON Returning null | <p>I am trying to make a simple app using the Retrofit that will parse the JSON Array and will fetch some data such as latitude and longitude but the problem is that is is returning null. I am new to Retrofit. Please explain whatever you post the solution</p>
<p>Here is my code</p>
<p>MainActivity.java</p>
<pre><cod... | 2 | 2,453 |
Exception in thread "main" java.lang.NullPointerException at database project | <p>Im trying to see all the data in my database or insert a data to my database. Both methods are giving the same response.
my pojo class:</p>
<pre><code>public class Title {
private Integer id;
private String name;
private String code;
public Integer getId() {
return id;
}
public void setId(Integer id) {
t... | 2 | 1,284 |
formatting string output with linebreaks and tabs in Python? | <p>Im trying to extract some data from a large batch of files and convert them to a specific (JSON) format for importing into a database using Django Fixtures</p>
<p>I've been able to get this far:</p>
<p>'{ {\n "pk":2,\n "model": trials.conditions,\n "fields": {\n "trial_id": NCT00... | 2 | 1,561 |
Airflow initdb with mysql as backend is not working | <p>when I initialize airflow using mysql as backend I see below error</p>
<blockquote>
<pre><code>File "/usr/local/lib/python3.7/site-packages/sqlalchemy/engine/default.py",
</code></pre>
<p>line 453, in connect
return self.dbapi.connect(*cargs, **cparams)
File "/usr/local/lib/python3.7/site-pa... | 2 | 2,375 |
Make webpack-dev-server to do hot reloading AND eliminate EMPTY response error in React | <p>I have been trying to make <code>React</code> app development easier by using reloading of the app when I modify the files and I tried <code>webpack-dev-server</code> for that (Please, see my previous thread: <a href="https://stackoverflow.com/questions/55345229/cant-set-up-webpack-dev-server-to-start-react-app">Can... | 2 | 1,487 |
How to fix marker on google map and move map? | <p>I've done current location show on google map, but I want to fix marker in center on the map when selected "autoPlace city" and then this location is shown on a google map. </p>
<p>My code is below:</p>
<pre><code>public class PostAdsFragmentFifth extends Fragment implements View.OnClickListener, GoogleApiClient.... | 2 | 4,923 |
curl from shell script | <p>I am trying to delete few objects using curl. I have a list of ids for the onjects in a file.
I loop through the list and issue a del like this:</p>
<pre><code>bash -x del.sh tempId.log
+ read id
+ curl -H 'Authorization:OAuth 00D30000001FxvA%21AQEAQKkcrruykRDNDapigaEdJXOc4SS_D27o686DScK8pU22BeMsgWVsWJ.Nv0DXimx2z... | 2 | 1,672 |
C++ HTTP over SOCKS5 (TOR) 400 Bad Request | <p>I have working C++ code getting the HTML source of a specific website.
One function creates the HTTP Request and other functions send it.</p>
<p>But when I try to access the website the same way, except with TOR (SOCKS5), I'm getting <code>HTTP 400 Bad Request response</code>. The request is identical both times, ... | 2 | 3,521 |
how to save the state of my CheckBox items in ListView with BaseAdapter | <p>My CourseFragmentActivity class extends FragmentActivity that uses a ViewPager with 5 tabs. I have a ListView in each tab that displays an ArrayList of CheckBox items. On the 5th tab of my ViewPager, I have a single button to navigate to another FragmentActivity class. The problem is when I select a CheckBox item i... | 2 | 2,518 |
ERC20: transfer amount exceeds allowance Smart contract with brownie and NFT | <p>Hello there I have two smart contracts, one is an ERC1155 contract which mints a NFT from Moralis IPFS server, the other is a ERC20 token. I want users to be able to pay for the minted NFT using the ERC20 token but I'm receiving an error on the <code>transferfrom()</code> function: brownie.exceptions.VirtualMachine... | 2 | 1,393 |
Rails 3.1: Polymorphic Association @commentable - how to do it right? | <p>I am having troubles with a polymorphic association in Rails. I have an application where it should be possible to comment on different models, such as <code>Posts, Images, Projects</code></p>
<p>Right now I just have Posts to comment on. On the start page there is an index view of the latest Posts and each Post ha... | 2 | 1,084 |
Complications converting Swing application to an Applet | <p>I finally got this calculator application in Netbeans to compile correctly and run client-side with no errors but for some reason I cannot get it to work as an applet. I have spent a lot of time trying to figure this out and researching but to no avail. Any experts around to take a quick look and see what the proble... | 2 | 3,074 |
@Formula pattern in hibernate | <p>I was reading some interview questions on Hibernate and came across Hibernate derived properties. I was trying a simple example using @Formula annotations but it is not working. Can anyone please tell me what am i missing. Code snippets below</p>
<p>The output and the SQL queries are display at the end.</p>
<p><st... | 2 | 1,562 |
log4j2 DynamicThresholdFilter not picking up property value | <p>Trying to set different printing levels for console and file. </p>
<p>Goal is: when <strong>debug=true</strong>, print <strong>debug level</strong> (console & file), else only print <strong>error level</strong> (console). </p>
<p>Change it <em>programatically</em> like this:</p>
<pre><code> @Override
publi... | 2 | 1,392 |
How to prevent Ansible from re-ordering JSON? | <p>Given the following playbook fetching some data from some random <a href="http://jsonplaceholder.typicode.com/users" rel="nofollow noreferrer">webservice</a>:</p>
<pre><code>---
- name: sorting json
hosts: localhost
tasks:
- name:
uri:
url: http://jsonplaceholder.typicode.com/users
method:... | 2 | 1,040 |
DbUpdateConcurrencyException error when saving record in EF Core 1.1 | <p>I have an ASP .Net Core 1.1 Web Api using EF Core 1.1</p>
<p>I have a controller that gets triggered when a post is performed:</p>
<pre><code>// POST: api/People
[HttpPost]
public async Task<IActionResult> PostPerson([FromBody] Person person)
{
if (!ModelState.IsValid)
{
return BadRequest(Mod... | 2 | 1,677 |
How to add "jni/*.c/cpp" files to CMakeLists.txt file? | <p>I have created a new project including c++ ndk. So it automatically created a <code>CMakeLists.txt</code> file and a <code>cpp</code> directory. But When I created a new directory named <code>jni</code> and tried to put <code>test.c</code>, <code>Android.mk</code> and <code>Application.mk</code> files on it, I got t... | 2 | 1,266 |
python git-submodule importing from other git-submodule | <p>Using Python 3.6
I did create multiple modules (like DBmanager or jsonParser etc which I use across multiple different python projects)</p>
<p>For simplicity: I have created a module, lets call it 'gitmodule03'.
Internally it is supposed to be using yet another module from github 'gitmodule01' for parsing data. I h... | 2 | 1,184 |
wxWidgets painting wxGLCanvas on a wxPanel | <p>I am trying to draw my wxGLCanvas in a panel and fill the area of the panel but the result is shown in the image below. I had the OpenGL cube sample running fine but in that example, the wxGLCanvas is parented to a wxFrame. When I try to parent it to a wxPanel, I get a fraction of the panel displaying my wxGLCanvas.... | 2 | 2,748 |
ImportError: dynamic module does not define module export function (PyInit_m3d1cf20adb1014f04986e6a344a55bde) | <p>This is an error message I get when I execute <code>import theano</code>:</p>
<blockquote>
<p>ImportError: dynamic module does not define module export function (PyInit_m3d1cf20adb1014f04986e6a344a55bde)</p>
</blockquote>
<p>I'm using Python 3.5.2 on Windows 10.</p>
<p>I have also asked this of the authors of T... | 2 | 6,129 |
Creating a Matrix Class: Error on adding | <p>I am trying to create a Matrix class using c++. So far, I have the following accomplished:</p>
<ul>
<li>Creating the Matrix</li>
<li>Deleting the Matrix</li>
<li>Getting and setting values inside of the matrix</li>
</ul>
<p>Right now, I am working on overriding all of the operators (ie., +, -, *, /) and returning ... | 2 | 2,651 |
PostgreSQL: Load testing throws error - Npgsql.PostgresException: '53300: sorry, too many clients already' | <p>i have a simple code that tries to simulate a load test for my Postgres database</p>
<pre><code> List<Values> values = new List<Values>();
for (int i = 0; i < 200; i++)
{
var mythread = new Thread(() =>
{
Databa... | 2 | 1,572 |
Cannot read property 'name' of undefined Axios, Vuex | <p>In my mounted i call axios to get profile datail, then if success i send payload to 'set_account' vuex.</p>
<p>For recovery this data i use MapGetters (currentAccount) in computed.</p>
<p>When thy recover this data ex: currentAccount.profile.name in console i receive: <code>TypeError: Cannot read property 'name' o... | 2 | 1,532 |
SolrNet with Castle Windsor and basic authentication | <p>I use Windsor container in purpose of SolrNet multicore access, but my Solr cores requires basic authentication. Is it possible use SolrNet Windsor intergation with authentication?</p>
<p>I'm tried next:</p>
<pre><code>static SolrInteractServer()
{
container.Register(Component.For<ISolrConnection>... | 2 | 1,399 |
using multiple columns css from left to right, instead of top to bottom | <p>I'm using on a page on my website on wordpress, css columns to display some content from its children page.
all my page titles are displayed in 2 colums, alpahbeticaly.</p>
<p>like this :</p>
<p>Column 1 | Column 2</p>
<p>Page Title A | Page Title F</p>
<p>Page Title B | Page Title G</p>
<p>Page Title C | ... | 2 | 1,137 |
Spring Security error in displaying custom page | <p>I am working on Spring Security Integration,
My application with inbuilt security page works fine.
But for custom login page its giving error</p>
<pre><code>The localhost page isn’t working
</code></pre>
<p>Here is my code for reference</p>
<p>inside spring-security.xml</p>
<pre><code> <http use-expressions=... | 2 | 1,473 |
SOAP org.xmlpull.v1.XmlPullParserException: expected: START_TAG | <p>I'm try call web-method "Registration" from web Service. It contain one input parameter and one output. </p>
<pre><code>HttpTransportSE httpTransport=null;
try
{
String organization = "Слоник Зеленый";
String method = "Registration";
SoapObject request = new ... | 2 | 2,173 |
Multi-Pane fragments within viewpager | <p>I'm currently working on an app that will hopefully act like an "eBook" player. Having read through a number of tutorials related to fragments, I decided to take the 'Fragment/ Viewpager' approach.</p>
<p>Moving into a little more detail, I decided to follow a great tutorial on nested fragments by Linden Darlinghtt... | 2 | 1,914 |
SKPaymentQueue finishTransaction: within network completion block? | <p>This problem has been giving me headaches for a while now.</p>
<p>My app operates on an auto-renewable subscription model. I have an SKPaymentQueue transactionObserver that is notified when a purchase is successfully completed through Apple, and at this point I send the Apple receipt to my server to verify on my en... | 2 | 1,038 |
Performance degradation using Azure CDN? | <p>I have experimented quite a bit with CDN from Azure, and I thought i was home safe after a successful setup using a web-role.</p>
<p><strong>Why the web-role?</strong></p>
<p>Well, I wanted the benefits of compression and caching headers which I was unsuccessful obtaining using normal blob way. And as an added bon... | 2 | 1,505 |
SQLite 1.0.91.3 and EntityFramework 6.0.2 in VisualStudio 2013 project register sqlite | <p>I create project with entityframework 5 and SQLite 1.0.91.3 and create entity data model. But after update entity to entityframework 6.0.2 I have error: </p>
<p>Error 175: The ADO.NET provider with invariant name 'System.Data.SQLite' is either not registered in the machine or application config file, or could not b... | 2 | 1,125 |
Redirection HTTP/1.1 301 Moved Permanently | <p>I have the following files. The objective of this is to redirect to the correct news. For example:
localhost/tostadotv/esto-es-una-noticia-28.html</p>
<p>If I intentionally modify the url, for example:
localhost/tostadotv/esto-es-una-noticia-modificada-incorrecta-28.html</p>
<p>I should redirect myself to the corr... | 2 | 1,377 |
Shiny modularized inputs inside pop-up modal aren't being written to reactiveValues when dismissed [flexdashboard/shinydashboard] | <p>As a minimally-viable example, I <a href="https://shiny.rstudio.com/articles/modules.html" rel="noreferrer">modularized</a> the basic example from here: <a href="https://rmarkdown.rstudio.com/flexdashboard/shiny.html#simple_example" rel="noreferrer">https://rmarkdown.rstudio.com/flexdashboard/shiny.html#simple_examp... | 2 | 1,982 |
SingleChildScrollView not working with List View Builder | <p>The ListView is not scrollable in this widget although I am using SingleChildScrollView as the body.
In order for me to scroll the widget, I should start scrolling from the very first part of the page which is the Stack inside the Column, if I try to scroll the ListView it is not Scrollable and it doesn't produce an... | 2 | 3,167 |
Qt Resizing a QMainWindow with a Splitter | <p>I have a QMainWindow with:</p>
<ul>
<li>Two widgets in a horizontal splitter. "m_liner" is on the right side
<ul>
<li>Both widgets have a minimum size of say, 300 pixels.</li>
</ul></li>
<li>A checkbox to hide/show the right-side widget m_liner.</li>
</ul>
<p>I want the overall QMainWindow to <strong>expand</stron... | 2 | 1,132 |
Get fragment in fragment layout android | <p>I have an android application with this architecture :</p>
<p>I have an Activity : MainActivity, this one contain a FrameLayout. In this FrameLayout I'm loading a fragment. This one is named Feed. In this Feed Fragment i have a google map fragment. So i want to call getMapAsync on my feed.java but i can't get my ma... | 2 | 1,747 |
Mail dynamically created .ics file attachment unable to open file for reading | <p><strong>Environment:</strong><br>
- Laravel 5.3 </p>
<p><strong>Case:</strong><br>
Mail about an 'event' including an attachment with an iCalendar file (<code>.ics</code>). The <code>ics</code> file is being generated using <code>PHP</code>.</p>
<p><strong>Problem:</strong><br>
While sending the mail <em>with</... | 2 | 1,449 |
EF6, Unit of Work and Repository Pattern - Is this the wrong pattern for a sync service? | <p>I'm writing a sync service between our Salesforce environment and our local environment. My use of the Salesforce API is purely on a batch level due to limitations on # of API requests per day, although I do have details on failures at the atomic level. However, I would like to save changes on a atomic level in my... | 2 | 2,522 |
How to access Kafka bridge | <p>I am using strimzi and I want to learn how to use Kafka bridge and to understand it's working I created a Kafka cluster using following yml file</p>
<pre><code>apiVersion: kafka.strimzi.io/v1beta1
kind: Kafka
metadata:
name: my-cluster
spec:
kafka:
version: 2.6.0
replicas: 3
listeners:
... | 2 | 9,557 |
IHostedService is not working perfectly some lines of code not firing how to handle it? | <p>I am using IHostedService to manage bulk of log inserting. It will run as a background service. But It is not keep going on after for loop in AsyncConsumer method. How can I use IHostedSErvice as a Background worker permonently always cheking any logs in logs list and consume it.Thank for your help.(Please look at ... | 2 | 1,103 |
Python 3 Unicode Objects must be encoded before hashing | <p>I use this code for hashing and salt: </p>
<pre><code>def make_hash(password):
"""Generate a random salt and return a new hash for the password."""
if isinstance(password, str):
password = password.encode('utf-8')
salt = b64encode(urandom(SALT_LENGTH))
print (salt, type(salt))
#print (salt.encode('utf-8'), type... | 2 | 1,086 |
Server Side EOFException | <p>I'm trying to write a messaging applicaton, and I'm able to send messages (shown as the server client displays the message correctly) but then kicks my client off of the server. The server prints the following error:</p>
<blockquote>
<p>java.io.EOFException at
java.io.ObjectInputStream$BlockDataInputStream.pee... | 2 | 5,965 |
If conditional in batch (inside a for, inside an if) | <p>I have an application that reads through all the files in the directory and will rename those files (if necessary) and create log files from the innards of them, however there are a couple of catches....</p>
<ol>
<li>If the files 15th character is something other than a "." or "_", substring the 14 characters previ... | 2 | 1,598 |
Issue to hide Toolbar when scrolling in android | <p>I've an Activity with an NavigationDrawer and a Toolbar. I'm facing a problem when i want disappear a toobar when one of child fragment view is scrolled. Everything works fine except that there is some view coming up from the bottom which has the exact same size as the toolbar that is disappearing.</p>
<p>I made an... | 2 | 1,763 |
Amount to words Odoo qweb report for Purchase Requisition | <p>I am trying to achieve amount to words in odoo 10. I am overriding the purchase requisition template. I will share my .py and .xml files please check what am I doing wrong. Thanks in advance!</p>
<p>Step1: Created module with scaffold command.</p>
<p>Step2: model.py</p>
<pre><code># -*- coding: utf-8 -*-
from odo... | 2 | 2,451 |
Grails JNDI data source not working | <p>I have a grails application with a data source defined in DataSource.groovy as:</p>
<pre><code>dataSource {
pooled = true
driverClassName = "oracle.jdbc.OracleDriver"
username = "myusername"
password = "mypassword"
}
hibernate {
cache.use_second_level_cache = true
cache.use_query_cache = fal... | 2 | 6,575 |
How to receive the message from stomp websocket with spring boot on android? | <p>I've got the simple WebSocket example from <a href="https://spring.io/guides/gs/messaging-stomp-websocket/" rel="nofollow noreferrer">https://spring.io/guides/gs/messaging-stomp-websocket/</a></p>
<pre class="lang-java prettyprint-override"><code>package com.example.chatservice.message;
import org.springframework.c... | 2 | 1,811 |
Kafka Streams - Rebalancing exception in Kafka 1.0.0 | <p>In Kafka Streams 1.0.0, we saw a strange error coming my way. My stream app ingest a kafka topic and emit multiple aggregations on different state stores, now the app works on a cluster of 2 nodes, but the moment the third one is added the stream app crashes on all the nodes.</p>
<p>Following is the exception that ... | 2 | 1,181 |
Language agnostic cookie encoding / decoding standards | <p>I'm having difficulties to figure out what is the standard (or is there any?) for encoding/decoding cookie values regardless to backend platforms.</p>
<p>According to <a href="http://www.ietf.org/rfc/rfc2109.txt">RFC 2109</a>:</p>
<blockquote>
<p>The VALUE is opaque to the user agent and may be anything the orig... | 2 | 1,126 |
How to divide work between processes in MPI | <p>I have the following code to count the number of primes, I have divided the work in the loop across processors. The problem is that when the subroutine assigns sub-sections of the loop to processors it assigns according to rank and i cant seem to control the order in which they arrive </p>
<p>i.e i would like then... | 2 | 1,136 |
g++ SSE intrinsics dilemma - value from intrinsic "saturates" | <p>I wrote a simple program to implement SSE intrinsics for computing the inner product of two large (100000 or more elements) vectors. The program compares the execution time for both, inner product computed the conventional way and using intrinsics. Everything works out fine, until I insert (just for the fun of it) a... | 2 | 2,806 |
How to send push notification using php in windows phone? | <p>Hi I need to send toast push notification from my windows phone app using PHP. I have used some codes but I can't send push notification.</p>
<p>My code is given below:</p>
<pre><code> private void Click_Login(object sender, RoutedEventArgs e)
{
string url = "http://www.best.com/Best_Windows... | 2 | 3,538 |
Mock mongoose aggregate function in jest | <p>I have a middleware as below, for which I am trying to do unit testing using jest,</p>
<p><strong>Middleware:</strong></p>
<pre><code>import Ph from './Ph.model';
fAP = (req, res, next) => {
const pN = req.body.pN;
if (pN != null) {
Ph.aggregate([
{ $match: { ... | 2 | 1,612 |
.Net Core app can't write file to any folder OSX | <p>I am building a .net core 2.0 app in OSX, its a WebAPI app that when an API endpoint is hit creates a .xlsx with dummy data. When I try to run it (dotnet run) I get </p>
<pre><code>System.UnauthorizedAccessException: Access to the path '/Users/myuser/projects/myproject' is denied. ---> System.IO.IOException: Per... | 2 | 1,040 |
TypeScript error: Type 'string' is not assignable to type 'number | ""' | <p>I'm new to TypeScript and I'm having a hard time understanding the following error.</p>
<pre><code>Type '{ order: string; }[]' is not assignable to type 'TestType[]'.
Type '{ order: string; }' is not assignable to type 'TestType'.
Types of property 'order' are incompatible.
Type 'string' is not assignabl... | 2 | 1,318 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.