title stringlengths 13 150 | body stringlengths 749 64.2k | label int64 0 3 | token_count int64 1.02k 28.5k |
|---|---|---|---|
Unable to instantiate activity ComponentInfo java.lang.ClassCastException | <p>I am trying to move to the activity below, but it is not working. on the emulator says that "the project keeps stopping".
That is my first app that i am trying to build, so i would appreciate if you could explain in details.</p>
<pre><code>package com.example.project3;
import android.content.Context;
import androi... | 1 | 4,276 |
How to match US-ASCII characters in T-SQL? | <p>I want to store URLs in a column. According to <a href="https://www.rfc-editor.org/rfc/rfc3986#section-2" rel="nofollow noreferrer">RFC 3986</a>, US-ASCII is the character set from which URLs are composed.</p>
<p>SQL Server has the VARCHAR type, which can encode all the characters from the US-ASCII character set, an... | 1 | 1,574 |
Algorithm to find a common multiplier to convert decimal numbers to whole numbers | <p>I have an array of numbers that potentially have up to 8 decimal places and I need to find the smallest common number I can multiply them by so that they are all whole numbers. I need this so all the original numbers can all be multiplied out to the same scale and be processed by a sealed system that will only deal ... | 1 | 1,070 |
Mockito verify not working correctly | <p>I am quite new to Mockito, though I have been running tests successfully before and today it just look so strange why mockito verify() method keeps telling me that a <code>View</code> method is required but not called even though I am sure <code>Presenter</code> method is calling it correctly. Here is my test code: ... | 1 | 2,191 |
Showing Different Document Types in Kibana from ElasticSearch | <p>I'm in the process of trying to setup a Kibana dashboard. This dashboard is hitting an ElasticSearch index. My index has the following mappings:</p>
<pre><code>"myindex": {
"mappings": {
"animals": {
"properties": {
"@timestamp": {
"type": "date",
"format": "dateOptionalTime"... | 1 | 3,240 |
Oracle circle distance search: missing results | <p>EDIT: (If u want see the old problematic, see at the bottom of this question)</p>
<p>With your helps i modified my statement:</p>
<pre><code>SELECT *
FROM (
SELECT
dest.ZC_ZIP,
dest.ZC_LOCATION_NAME,
ACOS(
SIN(RADIANS(src.ZC_LAT)) * ... | 1 | 3,230 |
How to reduce "sort" cost (t-SQL) | <p>I have a T-SQL query. Using <em>Display Estimated Execution Plan</em> in Microsoft SQL Server Management Studio (SSMS), I find the last of the <code>sort</code> operations to consume 83% of the totalt cost. </p>
<p>The weird thing is that when I remove the <code>WHERE</code> and <code>ORDER BY</code>, it only incre... | 1 | 1,538 |
GreenRobot Exception : de.greenrobot.event.EventBusException: Invoking subscriber failed | <p>Time to time I get this exception. </p>
<p>I just use green-robot the standard way, between views, fragments, activities, services and the app, with the default instance, and time to time some stickyEvents.</p>
<p>I did't find any other post that are related to this exception. Any idea, or hint to start my investi... | 1 | 1,544 |
Can't pass Eloquent model to Laravel Job | <p>I'm following the documentation for Laravel to pass an Eloquent model to a Laravel Job. However, despite my best efforts, I can't pass the Eloquent model - it is always "undefined" or another weird error.</p>
<p>This is for a Laravel 5.7 application, currently running on MacOS/Darwin, MySQL 5.5, and PHP 7.2. This j... | 1 | 3,313 |
Node.js - Express session data not persisting | <p>login works as expected and session data returned but beyond that I am unable to get session data to persist. For example, when I call getUser (below) the session data is not returned.</p>
<p><strong>app.js (setup)</strong></p>
<pre><code>const express = require('express')
const bodyParser = require('body-parser')... | 1 | 1,845 |
Change arrow style of matplotlib quiver function | <p>Is there a way to change the style of the arrows of the <a href="http://matplotlib.org/api/axes_api.html?highlight=quiver#matplotlib.axes.Axes.quiver" rel="nofollow noreferrer">matplotlib quiver function</a>?</p>
<p>I tried passing the <code>arrowprops=dict()</code> kwarg to the function, but that seems to only wor... | 1 | 1,039 |
select ng-options list of years and see current year by default | <p>I am using <code>select</code> and <code>ng-options</code> in angularjs to show a list of years that I construct myself.</p>
<p><strong>here is the <a href="https://plnkr.co/edit/UVGwuJjEqgL2rS0hMVMF?p=preview" rel="nofollow noreferrer">plunker link</a>.</strong></p>
<h2>My question is:</h2>
<p>How to show the cu... | 1 | 1,212 |
Transposing a 3D list in Python | <p>I have to transpose a 3d list the following way:</p>
<p>Input:</p>
<pre><code>matrix7 = [[['A ', 'E ', 'C#'], ['B ', 'E ', 'C#'], ['C ', 'E ', 'C#']],
[[' ', 'F#', 'D '], [' ', 'F#', 'D '], [' ', 'F#', 'D ']],
[[' ', 'E ', 'B '], [' ', 'E ', 'B '], [' ', 'E ', 'B ']],
[[' ', 'E ', 'C#'], [' ', 'E ', 'C#... | 1 | 1,032 |
Keep D3 objects size constant on Map while zoom in/out | <p>I am following the example from <a href="http://bl.ocks.org/d3noob/raw/5193723/" rel="nofollow">http://bl.ocks.org/d3noob/raw/5193723/</a></p>
<p>The cirles drawn in the example increases in size when zoomed-in. I am not able to figure out a way in which the circles' size can be kept same. </p>
<p>Any ideas?</p>
... | 1 | 1,339 |
JavaFX java.lang.IllegalArgumentException: argument type mismatch [scene builder] | <p>I'm using Scene Builder for my Java FXML.</p>
<p>When I run the code, on startup, an IllegalArgumentException is seen, but the program continues to run perfectly.</p>
<p>This is the Controller, mostly generated by Scene Builder (sample controller skeleton).</p>
<p><strong>FXMLDocumentController:</strong></p>
<pr... | 1 | 7,086 |
"error": "invalid_client" from custom OWIN implementation | <p>I am implementing OWIN authentication on a mysql backend, I dont thnk thats a problem as my registration work pretty well. I have basically worked off <a href="http://bitoftech.net/2014/06/01/token-based-authentication-asp-net-web-api-2-owin-asp-net-identity/" rel="nofollow">this post</a> (i.e. nicked most of the co... | 1 | 1,398 |
Python pexpect sendline contents being buffered? | <p>I have the following code in Python using the pexpect module to run a perl script which asks a series of questions. I have used this for quite some time and works well until now.</p>
<h2>pexpect python</h2>
<pre><code>index = child.expect(['Question 1:'])
os.system('sleep 2')
print 'Question 1:' + 'answer1'
child.... | 1 | 1,402 |
Faraday::ConnectionFailed Connection refused - connect(2) for "localhost" port 9200 | <p>I have add elasticsearch in my rails app, also i have include these gems in my Gemfile:</p>
<pre><code>gem "elasticsearch-rails"
gem "elasticsearch-model"
gem 'ngram'
</code></pre>
<p>All work fine, but every time when i restart my pc i get this error message</p>
<pre><code>Faraday::ConnectionFailed Connection re... | 1 | 4,162 |
Directory.GetFiles fails with error The process cannot access the file because it is being used by another process | <p>My code is </p>
<pre><code>var files = Directory.GetFiles(this.DirectoryPath, this.File.FileMatchPattern, SearchOption.TopDirectoryOnly);
</code></pre>
<p>Where File.FileMatchPattern looks something like "FileName*.csv" and DirectoryPath is a unc share.</p>
<p>In dev this code executes fine but in uat we're getti... | 1 | 3,034 |
How is the Tf-Idf value calculated with analyzer ='char'? | <p>I'm having a problem in understanding how we got the Tf-Idf in the following program:</p>
<p>I have tried calculating the value of <code>a</code> in the document 2 (<code>'And_this_is_the_third_one.'</code>) using the concept given on the <a href="https://www.kaggle.com/divsinha/sentiment-analysis-countvectorizer-t... | 1 | 1,079 |
K8s pod priority & outOfPods | <p>we had the situation that the k8s-cluster was running out of pods after an update (kubernetes or more specific: ICP) resulting in "OutOfPods" error messages. The reason was a lower "podsPerCore"-setting which we corrected afterwards. Until then there were pods with a provided priorityClass (1000000) which cannot be ... | 1 | 2,515 |
Extract GUID from line in C# | <p>I try to simplify some legacy code using IndexOf to retrieve a GUID from lines. Can I further simplify the code below to get rid of using guids.Any and guids.First?</p>
<pre><code>// Code using regular expression
private static string RetrieveGUID2(string[] lines)
{
string guid = null;
foreach (var line in ... | 1 | 1,432 |
How to parse Inner-XML return from SharePoint Web Services | <p>I have a program as such</p>
<pre><code> // establish proxy obj
SPLists.Lists listservice = new SPLists.Lists();
// credentials
listservice.PreAuthenticate = true;
// user name
Console.Write("Username (e.g. bobdole@xyz.com): ");
string usrname = Console.ReadLine().Trim();
Console.W... | 1 | 1,776 |
Import Another File Error | <p>My folder/file structrue is:</p>
<pre><code>testpkg/test/__init__.py;
testpkg/test/test1.py
testpkg/test/test2.py
testpkg/setup.py
</code></pre>
<p><code>testpkg/test/__init__.py</code> file is empty.<br>
<code>testpkg/test/test1.py</code> file content:</p>
<pre><code>class Test1:
def __init__(self, name):
... | 1 | 1,293 |
What's the difference between URL.standardized and URL.absoluteURL? | <p>In Swift's <code>URL</code> class, there are <a href="https://developer.apple.com/reference/foundation/url/2293170-standardized" rel="noreferrer"><code>.standardized</code></a> and <a href="https://developer.apple.com/reference/foundation/url/1780323-absoluteurl" rel="noreferrer"><code>.absoluteURL</code></a> proper... | 1 | 1,350 |
Nested AJAX Calls | <p>in first ajax call server returns a json string that is converted to js array. I want to run an ajax call for each element of array.</p>
<p>For example, first ajax call returns semester 1,2,3,4. Now i want to retrieve subjects for semester 1 and show them in a table, then retrieve subjects of semester 2 and show al... | 1 | 1,189 |
Stored procedures in SQL Server master-child relationships not tables | <p>In college last year I came across something I found very interesting with regard to stored procedures. It was mostly with regard to reducing code repetition for transaction management, error handling, and security. But I have researched it since and cannot find it anywhere. Perhaps I don't know what it is called so... | 1 | 3,638 |
handleChange is not working for formik inside a modal | <p>i am new to react and i was trying to make render a form inside a modal from antd but my handeChange is not working.
this normally works if i write everything inside the modal but i want to know how this can be done by using a different component and by using formik</p>
<pre><code>const InnerForm=({
... | 1 | 1,653 |
Apache Airflow SqlSensor MSSQL issues on Docker running on Windows 10 | <p>I'm trying to run the SqlSensor locally under docker on a Windows 10 machine, it runs on Linux but get below errors when trying to run the same simple DAG locally.</p>
<p>The reason I'm trying to set this up is so that I can develop locally and test to speed up the development cycle.</p>
<p>Error from Airflow log:... | 1 | 1,670 |
google cloud authentication with bearer token via nodejs | <p>My client has a GraphQL API running on Google cloud run.</p>
<p>I have recieved a service account for authentication as well as access to the gcloud command line tool.</p>
<p>When using gcloud command line like so:</p>
<pre><code>gcloud auth print-identity-token
</code></pre>
<p>I can generate a token that can b... | 1 | 1,311 |
Gulp prompt before running a task | <p>Id like to prompt the user before running the main <code>build</code> task at the bottom. I was looking at gulp-prompt as a solution but cant figure out how to implement it before any of the tasks run. I want the user to be able to cancel the entire <code>build</code> task before anything runs. Is that possible? Any... | 1 | 1,415 |
BlueJ - 'no suitable method found' for sort method | <p>I'm using <em>BlueJ</em> for a project. Here is my code:</p>
<pre><code>import javax.swing.*;`
import java.awt.*;
import java.util.Collection;
import java.util.Collections;
import java.awt.event.*;
import java.util.*;
import java.util.List;
public class SongSorter extends JFrame
{
private JPanel main, header, ... | 1 | 3,403 |
calling .net core method from angular gives error: failed to load resource: the server responded with a status of 404 () | <p>I am very new to both angular and .net core. I am writing a sample project,
In this project, I am calling a method from angular to .net core. I keep
getting an error saying:</p>
<pre><code>Failed to load resource: the server responded with a status of 404 () api/AllItProjectsLists/index:1
</code></pre>
<p>I... | 1 | 5,201 |
How to embed JavaFX Canvas into BorderPane? | <p>I'm trying to make a application using JavaFX.</p>
<p>What I want to make is the window with <code>MenuBar</code> on the top of it and <code>Canvas</code> in the center.
I also want the window to be able to resize.
Referring to the following link, which shows how to make <code>Canvas</code> resizable, I first made ... | 1 | 1,732 |
Changing the color of <option> in firefox | <p>I'm trying to change the text color of the option that is selected. It's working in IE but not in Firefox.</p>
<pre><code><html>
<head>
<script type="text/javascript">
$(document).ready(function(){
$("option:selected").css("color", "green");
});
</sc... | 1 | 1,502 |
R: calculating column sums & row sums as an aggregation from a dataframe | <p>I am trying to obtain column sums & row sums by aggregating with previous row sums & column sums.</p>
<p>For eg. </p>
<p>My initial data frame is:</p>
<pre><code> Flag1 Flag2 Flag3 Type1 Type2 Type3
1 Level1 A FIRST 2 0 0
2 Level1 A SECOND 1 9 0
3 Lev... | 1 | 3,044 |
Cordova POST - Request Forbidden 403. Not reaching Dispatcher Servlet | <p>I am developing a Cordova application.</p>
<p>When I submit an $.ajax POST request from the Cordova app running on my physical device (not emulator) I receive a status code 403 forbidden.</p>
<p>I can make a GET request from the device no problem. I can also login using a POST (receiving a 302 Found Response).</p>... | 1 | 2,846 |
'setter for mainClassName: String' is deprecated. Deprecated in Java | <p>I have a vert.x web app written in Kotlin and Gradle as the build tool. The web app has been generated with <a href="https://start.vertx.io/" rel="noreferrer">https://start.vertx.io/</a>.</p>
<p>In the <code>build.gradle.kts</code> it shows:</p>
<p><a href="https://i.stack.imgur.com/oEoEs.png" rel="noreferrer"><img ... | 1 | 1,213 |
The first 10 shortest paths in a graph - Igraph 0.6 - Python 2.7 | <p>I was wondering about this ever since I've started to successfully implement Igraph into my coding: Can you retrieve with <strong>get_all_shortest_paths</strong> as many shortest paths as you like. Let's say first 10.</p>
<p>I've understood so far that retrieving ALL shortest paths in a undirected graph is non-sens... | 1 | 1,578 |
Last Item in recyclerview is cut off | <p>I am using recyclerview to display a list of items and constraint layout is the parent view. The layout is displayed below: </p>
<pre><code> <?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout
xmlns:android="http://schemas.android.com/apk/res/android"
x... | 1 | 2,863 |
VerifyError deploying on API 1.6 | <p>I've come across a backwards compatibility issue when deploying my application on android 1.6. Im getting a VerifyError on this piece of code:</p>
<pre><code>if(android.os.Build.VERSION.SDK_INT >= 11) {
getActionBar().setBackgroundDrawable(getResources().getDrawable(R.drawable.actionbar_bg));
}
</code></pre>... | 1 | 1,536 |
Bootstrap horizontal menu collapse to sidemenu | <p>For a website I need one horizontal menu in Bootstrap 4 (.container) after the header (.container-fluid) which should collapse into right sidebar using slideout.js.</p>
<p>Currently I have horizontal menu (code below) but I can't figure out how to properly collapse items for slideout. <strong>How can I do it?</str... | 1 | 1,581 |
Hiding specific div elements when resizing window | <p>I have written a simple web application with the default web app project in Visual Studio 2012. What I want to do, is to hide two <code><div></code> elements when I resize the browser window. How am I able to do that?</p>
<p>CSS</p>
<pre><code>html {
width: 100%;
height: 100%;
min-height: 100%;
}... | 1 | 2,920 |
Where is boost::filesystem::last_write_time? | <p>This is the linker error I'm getting. All the rest of my boost::filesystem things are resolving. I'm not understanding why this one does not. I thought it was a problem with boost 1.40, so I upgraded to 1.44 and the problem remains. I'm using <code>#define BOOST_FILESYSTEM_VERSION 3</code> but I see no mention o... | 1 | 1,045 |
How to customize Bootstrap 4 using SASS for different grid columns and breakpoints? | <p>fellow devs,</p>
<p>I'm trying to get 12 columns and 24 gutter size on large size, while 6 columns and 18 gutters when it's medium and lower on one container view, while another container view it would be 15 columns and 12 gutters on the large size while resizing accordingly on lower views??</p>
<p>This is what I ... | 1 | 1,334 |
how to redirect to homepage after successful login in ReactJS? | <p>how to redirect to homepage after <code>successful login</code> in ReactJS? and also i want to show <code>error message</code> whenever user enter wrong credential.
<br/>
i am probably new to ReactJS, it would be great if anybody could help me out what i am trying to solve is. thank you so much in advance and also ... | 1 | 1,383 |
Javascript: How to get a list of an object's prototype chain constructor names? | <p>I recently encountered an interesting problem. I am developing with some existing code where, for better or worse, there are often several levels of prototypical inheritance ending in constructors for all kinds of various objects. Each of these ultimately inherit from a <em>single</em> base 'class'.</p>
<p>Each cons... | 1 | 1,184 |
Request failed with status code 429 Axios | <p>I am trying to parse lots of data from external API endpoint to my Database, I keep getting error 429.</p>
<p>I've tried timeout and sleep lib but it doesn't work for some reason.</p>
<p>Here is the code :</p>
<pre class="lang-js prettyprint-override"><code>async function(req, res) {
console.log("usa sam&qu... | 1 | 1,239 |
Python selenium webdriver Chrome - Chrome is being controlled by an automated software | <p>I am using selenium webdriver and creating a chrome driver instance. When i try to do scroll down and scroll up,I am getting the following error message. Further I can see an error message 'Chrome is being controlled by an automated software'. Its annoying to see this error though I am not able to change any setting... | 1 | 1,465 |
Multithreaded Java Web Server - java.net.SocketTimeoutException | <p>I've implemented a simple HTTP/1.1 compliant multithreaded web server which handles GET and HEAD requests. When I make a request through the web server, although it works, I'm getting a SocketTimeoutException after the 12 second timeout I set.</p>
<p>I'm testing my webserver by running it in Eclipse and directing t... | 1 | 10,170 |
Recyclerview IndexOutOfBoundsException: Inconsistency detected. Invalid view holder adapter positionViewHolder | <p>I have a chat application in which when a new chat is created, there are no messages in the message list. When the user goes in the chat and the first message is sent. The app crashes with the following error code</p>
<pre><code>java.lang.IndexOutOfBoundsException: Inconsistency detected. Invalid view holder adapte... | 1 | 6,499 |
sequelize.sync(): error in SQL syntax near NUMBER | <p>I made 4 Sequelize Models with use of <code>sequelize.define();</code>. Models are pretty much the same thing but with different table names. since I don't wanted to make them manually on MySQL cli, I decided to use sequelize.sync() in my main index.js file to let Sequelize to create the table but when I ran the app... | 1 | 2,984 |
autoselect shipping method in magento | <p>hey guys I have only one shipping method called JNE <a href="http://www.magentocommerce.com/magento-connect/suhanto-jne.html" rel="nofollow">http://www.magentocommerce.com/magento-connect/suhanto-jne.html</a> in my magento store </p>
<p>I want to the shipping method automaticly selected when my customer fill his ci... | 1 | 1,628 |
WPF Flip Animation | <p>I'm trying to create a control in WPF, similar to a card, that will have bound data on both "sides". Using the following code I can get it to flip from FIRST NAME to LAST NAME, just not back. Once it flips to LAST NAME and I click it just flashes like it's performing the same animation and not running the reverse.... | 1 | 2,230 |
typescript does not find jszip types | <p>I have a strange issue where typescript does not find the types for <code>jszip</code>.</p>
<ul>
<li>other types work fine</li>
<li>the types seem to be in the correct location </li>
</ul>
<p>in my source-file I use these <strong>imports</strong> e.g. </p>
<pre><code>import * as fast_csv from 'fast-csv';
import {... | 1 | 1,038 |
Can not find libz.dylib when build libzip by homebrew in Mac OS 10.16 (Big Sur) | <p>When building libzip by homebrew (Mac OS 10.16), it complains <code>make[2]: *** No rule to make target /usr/lib/libz.dylib', needed by `lib/libzip.5.3.dylib'. Stop.</code>, but I have <em>/usr/lib/libz.dylib</em> as a soft link, the real lib (libz.1.dylib) is missing.</p>
<p>So how could I fix this?</p>
<ol>
<li>o... | 1 | 2,114 |
null is not an object (evaluating 'internalInstance.getHostNode') in React Native component | <p>My React Native application has a component that is supposed to show a scrollable list. I'm also using <a href="https://github.com/react-native-community/react-native-elements" rel="noreferrer">React Native Elements</a>, although leaving that out doesn't seem to make a big difference.</p>
<p>My component looks like... | 1 | 3,648 |
spring ldap security without xml | <p>This documentation explains how to configure Spring-Security LDAP:</p>
<p><a href="http://docs.spring.io/spring-security/site/docs/3.2.4.CI-SNAPSHOT/reference/htmlsingle/#ldap" rel="noreferrer">http://docs.spring.io/spring-security/site/docs/3.2.4.CI-SNAPSHOT/reference/htmlsingle/#ldap</a></p>
<blockquote>
<pre><c... | 1 | 1,423 |
Xamarin.Forms implement Lazy Loading in CollectionView | <p>This is my CollectionView xaml file:</p>
<pre><code> <ContentPage.Content>
<Grid>
<StackLayout>
<RefreshView IsRefreshing="{Binding IsRefreshing, Mode=OneWay}"
Command="{Binding LoadRefreshCommand}">
&... | 1 | 3,358 |
HOW to CONVERT Touch Input To Mouse Input C# unity? | <p>i want to play my Unity Game in Mouse Input mode too (my Script now is Touch Input), can everyone help me to convert my script to Mouse input??
using if unity_editor , endif:</p>
<pre><code>#if UNITY_EDITOR
//some code for mouse input
#endif
</code></pre>
<p>my script in here : <a href="http://pastebin.com/HJwb... | 1 | 1,097 |
Tomcat 7.0.33 JAVA_OPTS configuration | <p>I want to use JMX to monitoring tomcat and ActiveMQ with a remote connection.</p>
<p>For activeMQ I added this in JAVA_OPTS in startup.bat:</p>
<pre><code>JAVA_OPTS=
-Dwebconsole.type=properties \
-Dwebconsole.jms.url=tcp://localhost:61616 \
-Dwebconsole.jmx.url=service:jmx:rmi:///jndi/rmi://localhost:1099/ jmxrmi... | 1 | 1,994 |
Spring boot test fails with No qualifying bean of type 'org.springframework.boot.autoconfigure.web.servlet.DispatcherServletPath' | <p>I have a Spring Boot application which works when run, but I am getting an error when I try to do some testing with MockMVC. The error is triggered by one line in the SecurityConfig:</p>
<pre><code>val publicUrls = arrayOf(
"/telemetry/**",
"/login",
"/logout"
)
override fun configure(http: HttpSecurit... | 1 | 2,138 |
Cant Solve "inc() takes 1 positional argument but 2 were given" | <p>I am trying to develop a list(lets called "l") of list of tuple of two natural numbers(excluding 0) such as "a" can be a memeber of "l" if len(a) == len and for every member(lets call p) of "a", p[0] <= max and p[1] <= max</p>
<p>For example poslist_all(max=2,len=1)</p>
<pre><code>[[(1,1)],[(1,2)],[(2,1)],[(... | 1 | 1,033 |
linq to entities does not recognize the method System.Collections.Generic.List | <p>I have below entities :</p>
<pre><code>public class Person
{
#region Primitive Properties
public virtual int PersonId {get; set;}
public virtual string FirstName{get; set;}
public virtual string LastName { get; set; }
#endregion
#region Navigation Projperties
public virtual ICollection&... | 1 | 1,435 |
Activity has leaked IntentReceiver Error | <p>before marking this post as closed or duplicate i want to say that i have done all the things that are mentioned on similar posts but none of them worked.</p>
<p>I have 2 receivers which i get data from. So i want to register the receivers when the activity starts and unregister them when the activity is not visibl... | 1 | 1,415 |
system command rm not working in expect program | <p>I have a code (1) that is supposed to execute test in another code (its a pseudo-bash). This code (1) is wrote using the "expect" for the 'user simulation'.</p>
<p>The problem is when this code (1) execute a system ( on this case, system "rm totoExpect.txt titiExpect.txt") when its just doesnt find the titiExpected... | 1 | 1,552 |
Failed Facebook Authorization Android SDK | <p>I am trying to make a class to handle all my interactions with Facebook. I am passing the the Login activity I created to the FacebookConnector object (the object in question) to store the credentials and etc. Please view the video to see what I am dealing with <a href="http://www.youtube.com/watch?v=OkHEy9Mh1hc" r... | 1 | 2,111 |
Python2.7 MySQL Connector Error on LOAD DATA LOCAL INFILE | <p>I'm trying to dynamically load census data into a mysql database (from .csv files) using Python and MySQL Connector. </p>
<p>I can't figure out why I am getting the error:</p>
<pre><code>Traceback (most recent call last):
File "miner.py", line 125, in <module>
cursor.execute(add_csv_file, csv_info)
F... | 1 | 1,029 |
How to add git repo path in the Dockerfile? | <p>Can someone please tell me how to add the git repo path in the Dockerfile. Here is my Docker file</p>
<pre><code>FROM ubuntu:14.04.3
MAINTAINER Upendra Devisetty
RUN apt-get update && apt-get install -y g++ \
make \
git \
zlib1g-dev \
python \
wge... | 1 | 1,206 |
Flume configuration to upload files with same name | <p>I have 10 files with some data varying in length.I would like to store corresponding data in same file and with same filename, but flume is splitting up the data and saving as FlumeData.timestamp. I am using the configuration as below:</p>
<pre><code> a1.sources = r1
a1.sinks = k2
a1.channels = c1
a1.channels.c1.... | 1 | 7,443 |
Angular2: Routing to the same page and changing query parameters | <p>I have an <code>Angular 2</code> project where I want to do the following:</p>
<p>Lets say I have a <code>Component</code> which has a datatable that supports paging and sorting.
What I want to achieve is that every time the table page/size and sorting changes, to also change the <code>URL Parameters</code>. </p>
... | 1 | 1,337 |
CodeIgniter Update query not working | <p>I want to terminate a employee from the system. When clicks on terminate button it will popup a moadal asking whether wants to terminate or cancel. If terminate database value resign should be updated as 0, but right now button does not working.</p>
<p>Here is my code</p>
<p><strong>controller</strong></p>
<pre><... | 1 | 2,405 |
TypeError: '>=' not supported between instances of 'datetime.date' and 'str' | <p>My pandas <code>df3</code> looks like this:</p>
<pre><code>df3 = pd.DataFrame([['23.02.2012', '23.02.2012', 'aaa'], ['27.02.2014', '27.02.2014', 'bbb'], ['17.08.2018', '17.08.2018', 'ccc'], ['22.07.2019', '22.07.2019', 'ddd']], columns=['date', 'period', 'text'])
</code></pre>
<p>I want to make column <code>period</... | 1 | 1,036 |
C++11: cannot convert argument from 'T *const' to 'T *&&' | <p>I have variadic template class representing a thread with function and input arguments.</p>
<pre><code>template<typename F> class my_thread;
template<typename Return, typename... Input>
class my_thread<Return(Input...)>
{
template<typename F>
my_thread(F&& f, Input&&... | 1 | 1,519 |
Spring: can't persist entity annotated with @JsonIgnore | <p>I'm a beginner in Spring Boot and can't manage to solve a problem. I have an entity class (Customer) and a REST repository (CustomerRepository). The class contains some sensitive fields that I don't want to be exposed by the REST repository. So, I annotated these fields with the @JsonIgnore annotation as follows:</p... | 1 | 2,129 |
Can Angular `HttpClient` `.get()` generics have non-simple property types? (e.g. other than `string` or `number`) | <p>I've burned a day researching the subject, and I haven't found any clues. All I have found is <em>omission</em>, in that nothing I've read states that you <em>can</em> use non-simple types (by which I mean <code>string</code> and <code>number</code>) for the generic interface ("shape") when calling an Angular 4.4 <... | 1 | 1,144 |
Simple and flexible method to run java as a windows service | <p>I read SO q&a about launch java as windows service wrappers, but can't find/choose product, suitable for my requirements :</p>
<ol>
<li><p>Wrapper reads all java launch parameters from config file. In registry must be only commands to run wrapper itself - path to exe and maybe path to config. Always grant admin... | 1 | 1,376 |
Make image fit fullscreen on iphone x with React Native | <p>As the title says, i want my image to fit the whole screen on my Iphone X simulator. I have tested to set the imageContainer to "with: 100%" and also the container that holds everything, but it does not work. Happy with any suggestions.</p>
<p>Image of the problem :
<a href="https://i.stack.imgur.com/JiVQu.jpg" re... | 1 | 1,809 |
Retrofit API data pass in Fragment | <pre><code>public class MainActivity extends AppCompatActivity implements
GoogleApiClient.ConnectionCallbacks, GoogleApiClient.OnConnectionFailedListener,
LocationListener {
private GoogleApiClient googleApiClient;
private LocationRequest locationRequest;
private Geocoder geocoder;
priv... | 1 | 8,021 |
Why I cannot initialize group definition from jar file? | <p>I am trying to create bean from jar file from our company to retrieve data from database.
I added</p>
<pre><code><context-param>
<param-name>parentContextKey</param-name>
<param-value>common.context</param-value>
</context-param>
</code></pre>
<p>to my web.xml,
then ther... | 1 | 3,889 |
Java - Running Total in Simple GUI Banking Program | <p>I am having trouble trying to figure out how to code the deposits and withdrawals for my banking program and keep a running total. The program should start you with $0 in the bank and cannot go below $0. You are able to deposit and withdraw from this account and you can view who deposited and withdrew from the menu.... | 1 | 6,096 |
TypeError: Cannot read property 'slice' of undefined ng2-bootstrap typeahead | <p>I'm trying to setup a Google Maps Autocomplete. But I'm getting this error</p>
<pre><code>TypeError: Cannot read property 'slice' of undefined
</code></pre>
<p>I've followed the example here: <a href="https://valor-software.com/ng2-bootstrap/index-bs4.html#/typeahead" rel="nofollow">https://valor-software.com/ng2... | 1 | 2,417 |
PERL SCRIPT ERROR (DBD ERROR: error possibly near <*> indicator atrror possibly near <*> indicator at char 53 in 'insert | <p>i am getting below error while running below perl script. Can anybody help to figure it out?</p>
<pre><code> $ENV{PATH}= '/appl/OMS/scripts:/etc:/usr/bin:/usr/sbin:/b...';
$ENV{PATH}= '/appl/OMS/scripts:/etc:/usr/bin:/usr/sbin:/bin:/usr/local/bin:/usr/local/opt/oracle/client/11.2.0.4/bin';
$ENV{ORACLE_HO... | 1 | 1,708 |
Callback after orientation change becomes null | <p>I have have a <code>FragmentActivity</code> with two tabs which are <code>ListFragment</code>s. Each <code>ListFragment</code> has a callback.</p>
<p>An example of a callback</p>
<p>The callback is associated inside of the <em>onAttach(...)</em> method</p>
<pre><code>OnStatusUpdateListener mStatusUpdateCallback;
... | 1 | 1,130 |
Cannot solve Android Error:Execution failed for task ':app:compileDebugJavaWithJavac' | <p>still having the following error:</p>
<pre><code> Error:Execution failed for task ':app:compileDebugJavaWithJavac'.
Compilation failed; see the compiler error output for details.
</code></pre>
<p>Even after trying solutions on stackoverflow, I am still stuck on how to solve this issue. Anyone guide me through how... | 1 | 2,201 |
submit button does not trigger server-side code | <p>the question says it all. i've an asp.net page using jquery. at first when i clicked the submit button, it'd show the object expected error. i ran the firebug and it displayed the error of 'return validate()' function which was added onClientClick of the button.</p>
<pre><code> <script type="text/javascript">... | 1 | 2,370 |
Getting error on Kafka as and consumer is not able to read from topics -- Failed authentication with /10.2.***.* (SSL handshake failed) | <p>I am using apachekafka latest version 2.3.0, I am deploying kafka as a multi node cluster and using SSL for interbroker communication.
The set up is deployed onto kubernetes </p>
<hr>
<h2> server.properties</h2>
<pre><code># Licensed to the Apache Software Foundation (ASF) under one or more
# contributor license ... | 1 | 2,242 |
Apache2 SSL "SSL_ERROR_RX_RECORD_TOO_LONG" | <p>I need help to check SSL implementation.</p>
<h2>Informations :</h2>
<ul>
<li>Server version: Apache/2.4.29 (Ubuntu)</li>
<li>Server version: Apache/2.4.29 (Ubuntu)</li>
<li>OpenSSL 1.1.1d 10 Sep 2019</li>
</ul>
<h2>Verifications checked :</h2>
<ul>
<li>a2ensite,</li>
<li>a2enmod,</li>
<li>apache2ctl configtest... | 1 | 3,265 |
Can't resolve all parameters for [...] | <p>Looks like a pretty common problem. I want to use Service1 in Service2 and I get the exception </p>
<blockquote>
<p>Error: Can't resolve all parameters for ILIASRestProvider: (Http, ?).</p>
</blockquote>
<p>even though in other Components Service2 seems to be injectable. And I think I have everything together:<... | 1 | 1,401 |
UnrecognizedClientException","errorMessage":"The security token included in the request is invalid when testing lambda function locally | <p>I am trying to use aws sam to invoke my lambda function locally for testing. The function reads an item from a dynamodb table. I have spin up a local dynamodb container where the desired table is created.</p>
<p>Ran below commands to create a local dynamodb container.</p>
<ol>
<li>docker network create lambda-local<... | 1 | 1,504 |
Flexslider fullscreen BG fade-in effect hides div | <p>I'll start with the fade-in effect where the touch works perfect and the images change responsively on swipe - BUT - the div container i have my site in, gets sent to the background and not in front of the image.</p>
<p>I am trying to use flexslider as a Fullscreen background slider with touch. Here is my code, if ... | 1 | 1,570 |
android AsyncTask xml parsing | <p>i try to parse a large xml document in a AsyncTask. The FeinstaubActivity starts but i only see a black screen and then get back to the RSSReaderActivity from where i started the other Activity.</p>
<p>Log:</p>
<pre><code>DEBUG/SntpClient(58): request time failed: java.net.SocketException: Address family not suppo... | 1 | 1,103 |
Flutter refresh JSON every minute automatically | <p>I have searched the web for auto refresh widgets and auto refresh future JSON for Flutter but the results all seem to be for pull down refresh.</p>
<p>What I need is like a function that I can call and every minute that said function repeats.</p>
<p>I know I have to integrate something like: </p>
<pre><code>var f... | 1 | 1,062 |
Using CIColorMatrix filter in Swift | <p>The following Swift func is supposed to tint a greyscale image 'greyImage' using specified 'tintColor':</p>
<pre><code>import UIKit
func colorizeImage(greyImage : UIImage, tintColor : UIColor) -> UIImage? {
let colorMatrixFilter = CIFilter(name: "CIColorMatrix")
var r:CGFloat = 0
var g:CGFloat = 0... | 1 | 1,109 |
Query argument foo not found in the list of parameters provided during query execution | <p><a href="http://www.objectdb.com/java/jpa/query/parameter" rel="nofollow">How</a> do I set the parameter for the argument of the query below:</p>
<p>entity:</p>
<pre><code>package net.bounceme.dur.usenet.model;
import java.io.Serializable;
import java.util.logging.Logger;
import javax.mail.Folder;
import javax.ma... | 1 | 2,566 |
Can't clone an existing repository with ssh, and ssh config seems fine | <p>Here's my situation:
I have two <strong>private</strong> repositories.</p>
<ul>
<li>git@github.com:syra37fGIT/Angular.git</li>
<li>git@github.com:syra37fGIT/temp.git</li>
</ul>
<p>Currently i added a remote just for one of them by cloning it.</p>
<pre><code>$ git remote -v
origin git@github.com:syra37fGIT/temp.g... | 1 | 1,241 |
Excel interop workbook.SaveAs() removes original formatting? | <p>How can I preserve a worksheet's formatting when using <code>Microsoft.Office.Interop.Excel.Workbook.SaveAs(...)?</code></p>
<p>For example, I open a previously created workbook with Excel 2010 and I see that it looks beautiful: bold fonts in column headers, nice grid lines, good highlight colors showing input cell... | 1 | 1,877 |
NavigationView slide from right | <p>Im using new <strong>NavigationView</strong> from android support design library. It works fine but when I try to set it <strong>slide from right side</strong> it gets crashed with that exception:</p>
<pre><code>java.lang.IllegalArgumentException: No drawer view found with gravity LEFT
</code></pre>
<p>My main lay... | 1 | 1,339 |
Data sent by WCF client is broken | <p>We are getting following exception in the <code>.svclog</code> file generated through system diagnostics config settings at server side.</p>
<blockquote>
<p>Exception: System.ServiceModel.ProtocolException<br>
Message: The number of bytes available is inconsistent with the HTTP Content-Length
header. There m... | 1 | 3,275 |
c++ sin not return correct values | <p>I am trying to complete a program that converts degrees to radians and vice versa. After that, users can find sin, cosine, asin and acos. The program now keeps returning incorrect answers. I have looked through a few previous questions but none of them have helped. The incorrect answer is usually like sin(90)=.84654... | 1 | 1,226 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.