title
stringlengths
13
150
body
stringlengths
749
64.2k
label
int64
0
3
token_count
int64
1.02k
28.5k
Implementing Google Adsense inside a p(react) project using javascript
<p>I have an issue and I've spent A LOT OF TIME trying to solve this. I am trying to add the Google Adsense code to my Preact project which works the same as React. My status stays stuck at: &quot;<strong>Your site needs work</strong>&quot;. the additional information explains that Google can't find the code. Even thou...
2
1,297
log4net message text problem
<p>I'm trying to make log4net work using File Appender.</p> <p>I use specified pattern layout for messages, but the problem is that I get no text in my log file. only '??' symbols</p> <p>It seems that the the message text somehow gets corrupted before being written to file.</p> <p>I'm using Visual Studio 2008 on win...
2
2,213
Type 'AngularFireObject<{}>' is not assignable to type 'FirebaseObjectObservable<User>'
<p>I have a big trouble because of this error. I am creating a signup module using Angular4 and angularfire2.</p> <p>Here is the package.json code.</p> <pre><code>"dependencies": { "@angular/animations": "^4.2.4", "@angular/cdk": "^5.1.0", "@angular/common": "^4.2.4", "@angular/compiler": "^4.2.4", "@angular/core": "...
2
1,620
AnyObject array returned by NSFetchRequest errors with "Swift dynamic cast failed" upon cast in Swift XCode 6 Beta 4 in XCTestCase
<p>I know this has been asked before <a href="https://stackoverflow.com/questions/24072937/executefetchrequest-doesnt-return-the-nsmanagedobject-subclass">here</a> but the answer did not solve my problem, and I wanted to post my full test case. </p> <p>I setup my Entities as in the screenshot: <a href="https://imgur.c...
2
2,104
Why are files are different when downloading from an ASP.NET (AJAX download with Blob)
<p>Using MVC 4.0, I have used the following code to create a download files from the server from an ajax source (using the latest firefox):</p> <p>This works fine if the output involves are textual files such as csv or txt files, however, when it comes to files like zip or xlsx, it seems the downloaded file is differe...
2
1,496
Make Azure powershell wait for task to complete
<p>I have a powershell script that stops/starts VM in parallel at specific time using Jenkins. This script uses the -AsJob powershell cmdlet, this way the VMs show they are stopped in Jenkins output but really they are in process of deallocating in the Azure portal. </p> <p>I also have a sleep timer for 5 minutes to g...
2
1,094
Unable to Yield From inside async function and get yielded data
<p>I am trying to Yield From a function from within an asynchronous function. Having spent hours trying to figure this out and traversing Stack Overflow to find similar questions previously answered but unable to help me find a solution to my own problem, I find myself here.</p> <p>Quite simply, I want to query the As...
2
1,656
SOAP specified type was not recognized
<p>I'm trying to use a SOAP webservice with VS2013 + .net 4.5 but I'm getting the exception above calling the <code>getVechicles</code> method, I can't find the reason for this exception.</p> <p>Here is few things that I figured out:</p> <ul> <li>At the end of the exception I'm seeing a souspicious thing, the method ...
2
4,984
WCF service client: Customized soap envelope not being sent on the wire
<p>I am calling a 3rd party web service from a WCF client. The problem is that the service requires a specific soap envelope format.</p> <p>The question <a href="https://stackoverflow.com/questions/11322104/wcf-soap-format">WCF Soap Format</a> deals with the same problem and the solution suggested was to write a Custo...
2
1,178
React, Conditionally rendering a component based upon communication between a parent and two children components
<p>I am kinda new to React, what I am trying to do is this, I have a parent component that carries the state, and two children that are considered to be the so-called presentational components lets say <strong>(X,Y)</strong>. So, Component <strong>X</strong> receives an array of Items as a prop from the parent and ren...
2
2,379
Dumping a RETS Data Feed
<p>So I have a RETS data feed from Paragon I am trying to dump all this data into a CSV using phRETS library. I have tried many different ways to dump data from this RETS feed via dmql or libRETS and none of them are working. Here is my php code using phRETS to try to dump the data feed.</p> <p>Right now it just gener...
2
2,533
Model Mapper Get Null Pointer Exception When Calling Method on Testing Class
<p>When I call the model mapper Entity to DTO converter method I always get null pointer exception.</p> <p>This is converter service to convert dto to entity and vice versa</p> <p>I have not deal with DTO previously and this is the first time I use DTO and I also need to know is this the best way I've implemented DTO c...
2
1,113
yum install complains about already installed dependency
<p>I mean to install a package that is apparently not available in my registered repos (see <a href="https://stackoverflow.com/questions/48170542/redhat-which-package-provides-hdf5-h">RedHat, which package provides hdf5.h</a>).</p> <p>So I downloaded <code>hdf5-openmpi-devel-1.8.5.patch1-10.el6.i686.rpm</code> from <c...
2
1,864
Dynamic Textbox event TextChanged is not firing
<p>I have a problem with a Dynamic Textbox event. I got other dynamic textbox with their textchanged events, the others work good, but this one never get into the event, the property AutoPostBack = true, EnabledViewState too, EnabledViewTheming too, and it's into an UpdatePanel and I create a Dynamic Trigger.</p> <p>T...
2
1,057
vertical-align content in middle of nested column (bootstrap)
<p>I want my content (H3 + p) to be in the middle (horizontally and vertically) of their <code>&lt;div class="col-md-12 inside-row"&gt;</code>. </p> <p>I tried to display: flex and align-items: center. It did positioned my content in the middle of my <code>&lt;div&gt;</code> but then the whole column was starting from...
2
1,381
Python - Logging from multiple modules using structlog
<p>I am trying to use Structlog to to log to a file and then using filebeat to send the log to my logging service.</p> <p>I have made the everything work, but I would like to be able to use the same logger across multiple modules, like with Pythons default logger (see <a href="https://docs.python.org/2/howto/logging.h...
2
1,047
Custom search configuration in sitecore 7
<p>I have been working on the sitecore contentSearch API recently.When i try to build the custom Index,I'm getting the runtime errors as follows.</p> <pre><code>Could not find property 'initializeOnAdd' on object of type: Sitecore.ContentSearch.LuceneProvider.LuceneIndexConfiguration </code></pre> <p>This is my sampl...
2
2,083
Downloading encrypted file from Window Azure storage
<p>I have created a MVC WebRole Window Azure application where i upload encrypted files to Azure blob storage using SymmetricAlgorithm (Rijndael) like this</p> <p>Controler>Action is</p> <pre><code>[HttpPost] public ActionResult UploadImage_post(HttpPostedFileBase fileBase) { if (fileBase.ContentLength &gt; 0) ...
2
1,588
Why would identical copies of the same C loop in the same program take significantly but consistently different times to execute?
<p>I hope that I have reduced my question to a simple and reproducible test case. The source (which is <a href="https://gist.github.com/nkurz/0fbb2f2332a3142c9d15">here</a>) contains 10 copies of an identical simple loop. Each loop is of the form: </p> <pre><code>#define COUNT (1000 * 1000 * 1000) volatile uint64_t ...
2
2,647
ExtJS 4.2 filefield multiple upload
<p>IΒ΄m having some troubles with the multi file upload</p> <p>In my controller I generate a window with a form and the form has a filefield and a grid:</p> <pre><code>var ventanaSubirDocumento=new Ext.Window({ title: '&lt;span style="color:#C85E00;"&gt;Subida de Documento&lt;/span&gt;', plain: true, ...
2
2,950
Memory issue in application in android
<p>I am getting a large or big value from the webservice. I am using sax parser to parse the value and add it to an arraylist. From the arraylist I am adding to tablelayout with scrollview at the I am getting an out of memory error in android. Can anybody tell me what I need to do to solve the issue? Is there any way t...
2
5,498
Hibernate OneToMany using annotations with legacy database
<p>I'm working with a legacy database that isn't normalized at all. They've been coding relationships directly in the program (written in Uniface). Now, they are migrating to Java. Sadly, I can't change the database, but I need to map a OneToMany relationship between tables.</p> <p>For instance, I have a table Invoice...
2
1,793
Passing data between android and server using JSON parsing
<p>I'm trying to send and receive data between <strong>android</strong> app and <strong>server</strong> using <strong>JSON</strong> but unfortunately i am unable to do it i searched a lot but it didn't help. My code is as follows: </p> <p>In android </p> <pre><code>try { JSONObject jsonObject = new JSONObje...
2
1,260
Exact CUDA / cudNN versions for TensorFlow 2.4.0
<p>I'm trying to use Anaconda3 (2020.11 with Python 3.8.5 64-bit) with Tensorflow 2.4.0 on Windows 10 but I must say this technology seems to be still very... unstable!</p> <p>It's really puzzling to understand that each library depends on an exact version of another library, not more, not less!</p> <p>So far I managed...
2
2,445
Error getMethod(java.lang.String,java.lang.Class,java.lang.Class) not found in java.lang.Class
<p>I am stuck in Javassisst. I want to put code in the method that is located in other class. I have "no method" exception. When I just start Test2 class by itself it starts ok, without any errors. I think problem in Classloader because I am trying to invoke methods from SUTTest class in order to conduct assertions and...
2
3,309
Do two numbers contain same digits
<p>Ok, so I was wondering how can one check whether two numbers have the same digits, e.g. <code>21</code> and <code>12</code> are ok, also <code>1233</code> and <code>2313</code>, but <code>123</code> and <code>1233</code> are not, meaning that the digits are permutation of another number's digits.</p> <p>I know how ...
2
1,619
Ruby 1.87 Rails 3.03 and Devise. Paperclip image not being saved although it says it is in log file
<p>I have gotten paperclip to work on my system without a problem. In this recent app that I have been building, for some reason I can't get paperclip to save the image, even though the log file says it is, it doesn't show up in the sql datase either.</p> <p>The only difference that I have, is using Devise and wonder...
2
1,865
How to scale an image using eye tracking in WPF?
<p>I'm trying to zoom in and out each frame from a live video stream from a webcam, by opening or squinting my eyes. I already have the eye tracking part working, but I can't figure out where to fit in the ScaleTransform. Below is the existing code I have:</p> <pre><code>using System; using System.Collections.Generi...
2
1,124
VS CODE / MSBUILD : error MSB1003: Specify a project or solution file. The current working directory does not contain a project or solution file
<p>I've tried many different ways but I get the error MSBUILD : error MSB1003: Specify a project or solution file. The current working directory does not contain a project or solution file. in Visual Studio code when trying to run my Net Core.</p> <p>I think I have this configured correctly. The project builds with no...
2
1,236
Why can I not connect to an RDS Aurora DB via proxy?
<p>I setup a Postgresql Aurora DB and a Proxy via Terraform (code below), which is apparently running fine. But for some reason I can not connect to the DB through the proxy. The proxy claims that there are lacking credentials for the role, but if I connect directly to the DB everything is fine and the credentials are ...
2
2,808
How to display Icons with the styled-component icons that are hidden even after being inserted into the component? (GATSBY)
<p>I'm trying to show the icons in the aside. Below is the styled-components code and the way in which its logic was organized but the icons are not being shown by default. a curious behavior is that if I write anything directly next to the icon component it start to display it but in different sizes.</p> <p>MenuBar ...
2
1,027
How to set the namespace of marshalled xml using camel jaxb?
<p>For starters, I'm creating some routes using Camel ver 2.15 (in Fuse 6.2.1).</p> <p>In my route, i'm trying to create a XML from a pojo that was generated using cxf-xjc maven plugin (cxf-xjc read some xsd somewhere then from the xsd, the pojos with jaxb annotations were produced). </p> <p>The pojos are TempProject...
2
1,287
How to use "RectangleSelector " widget of Matplotlib in TKinter
<p>I am working on a project where i have to plot some data which is read from a sensor then the user must select a part of this data from the plot and extract it. I am using python3, tkinter for gui and matplotlib for plotting. I thought "RectangleSelector" widget of matplotlib is suitable for this job. However, I cou...
2
2,345
DataGrid won't update ViewModel
<p>I've got a datagrid which is bound to an ObservableCollection of the ViewModel below. The Datagrid will display all values correctly, so the binding seems to be working, but if I change some value the Grid won't call the setter's of my VM. Could somebody tell me why?</p> <p>Here's my ViewModel:</p> <pre><code> ...
2
1,131
Integrating IdentityServer4 With WebAPI
<p>I am trying to integrate IdentityServer4 with ASP.NET MVC WebAPI.I want to achieve role based authorization. I have the following projects running.</p> <ol> <li>IdentityServer4 [a separate project]</li> <li>WebApi </li> <li>Javascript Application [using Extjs]</li> </ol> <p>I have implemented the <strong>ResourceO...
2
4,831
Laravel Default Auth with Modals
<p>I'm trying to modify laravel's default authentication system by using modal windows and by adding some new fields. So, I have a modal window to register a new users which looks like this:</p> <pre><code>&lt;!-- Modal Register area --&gt; &lt;div class="modal fade" id="registerModal" tabindex="-1" role="dialog" aria...
2
2,198
Spring MVC MultipartFile problems
<p>I am trying to run a simple controller with a method that will receive</p> <ul> <li>A String with a value</li> <li>A file (MultipartFile object)</li> </ul> <p>After some investigation (<a href="https://stackoverflow.com/questions/4118670/sending-multipart-file-as-post-parameters-with-resttemplate-requests">Sending...
2
1,374
MySQL Optimization - Need advices
<p>I have a CentOS 7 VM with 32 GB RAM (4 cores/8 threads) 3.4 GHz+ I ran the MySQLTuner script, and followed the recommendations that they gave, but it's still very slow</p> <p>My current config in my my.cnf file is:</p> <pre><code>[mysqld] local-infile=0 datadir=/var/lib/mysql socket=/var/lib/mysql/mysql.sock symb...
2
2,009
How to set listview selected item is null in carousel view
<p>I have setup list view inside carousel view but how can archive set list view selected item is null, Now when I tap any item carousel view inside list view items it show's default color but we need to remove that color. Please suggest any idea. Thanks in advance.</p> <p>Sample Code :</p> <pre><code> &lt;cv:Carouse...
2
6,566
Does Zend_Db_Adapter::beginTransaction() stack?
<p>Consider the following:</p> <pre><code>/** (Cas_Template_Tree::DeleteNode) * Deletes the given node from the tree, and all of it's children. * * @static * @throws Exception * @param Cas_Template_Node $node * @return void */ public static function DeleteNode(Cas_Template_Node $node) { $table = new Cas_Tab...
2
1,277
Two pages are "merged" together if include jQuery Mobile in 1st page
<p>I have a very simple HTML two page demo that ilustrates a very confusing behavior in jQuery Mobile 1.1.0. (The real app is much more complicated but I've been able to "massively" simplify the problem.)</p> <p>Page 1 consists of a single href to jump to Page 2. If Page 1 does <em>NOT</em> include jQuery Mobile 1.1...
2
1,900
Tensorflow 2.0 & Java API
<p>(note, I've resolved my problem and posted the code at the bottom)</p> <p>I'm playing around with TensorFlow and the backend processing must take place in Java. I've taken one of the models from the <a href="https://developers.google.com/machine-learning/crash-course" rel="nofollow noreferrer">https://developers.g...
2
2,117
Python: Replace one list with another list?
<p>I'm stuck. I'm moving folders around on our network which all have a unique ID into a central location. There are a few folders with typos and therefore do not match a unique ID in the central location. I have found the correct IDS but I need to rename these folders before I move them. For example, I have created a...
2
2,404
CRC32C - appending 0s/CRC to message
<p>I am trying to get a better understanding of CRC, however I am stuck a bit.</p> <p>There are few sample vectors here <a href="http://reveng.sourceforge.net/crc-catalogue/17plus.htm#crc.cat.crc-32c" rel="nofollow noreferrer">1</a> which I can calculate correctly, however I am stuck with verifying that the calculated...
2
3,049
LinearLayout cannot be cast to DrawerLayout
<p>I'm trying to add an image on top of the navigation drawer but every time I run it the application crash; the logcat gives me this error: <code>java.lang.ClassCastException: android.widget.LinearLayout$LayoutParams cannot be cast to android.support.v4.widget.DrawerLayout$LayoutParams</code></p> <p>Here is what I'm ...
2
4,660
How to plot correlation plot for selected columns
<p>I want to plot a correlation plot for DNA vs RNA of my samples from my data table. How can I selected a range of columns (DNA) for X-axis and the rest for Y-Axis (RNA) and make the plot.</p> <h3>Sample Data</h3> <pre><code>structure(list(RNA_T_0d = c(123.3540196, 2555.009918, 372.8928872, 197.7139756, 197.7558796...
2
4,410
mingw64 system("command") not same as "command" in shell
<p>A program "execinput" reads input lines from stdin and stores them into a character array "buffer" and then does this:</p> <pre class="lang-c prettyprint-override"><code>system(buffer); </code></pre> <p>Let "command" be any valid set of programs, parameters, and bash syntax. Ideally the next two lines would give ...
2
1,033
access img tag inside asp:FormView at codebehind
<p>I have a asp .net form and need to check a specific image tags current image and move ahead , refer the markup below </p> <pre><code>&lt;%@ Page Title="" Language="C#" MasterPageFile="~/Site.Master" AutoEventWireup="true" CodeBehind="SessionDetails.aspx.cs" Inherits="CodeCamper.UIWebLayer.WebUI.SessionDetails" %&gt...
2
3,482
Kafka integration in unity3d throwing Win32Exception error
<p>I am trying to run a code sample of <strong>Kafka</strong> in unity environment and for this reason, I created a <strong>consumer</strong> client (Code given below).</p> <pre><code>using System.Collections; using System.Collections.Generic; using UnityEngine; using Confluent.Kafka; using Confluent.Kafka.Serializati...
2
1,274
Remove White Border and vertical / Horizontal image in html table cell
<p>From my searching both on the wider web and on here it seems this is a question asked many many times but for the last few weeks I have not been able to find a answer that does what I want.</p> <p>I am using a third party (paid for) responsive template on blogger.com.</p> <p>I am creating a new page (not a post) t...
2
1,633
frisbyjs test is failing because get() is not sending the HTTP headers
<p>I have a frisbyjs test inside another frisbyjs test's afterJSON() that is failing. When I debug the server code, it appears that the x-access-token and x-key HTTP headers are not getting sent. Am I sending them wrong? Surely I'm doing something silly.</p> <p>Below is the outer test. The first test in afterJSON() is...
2
1,750
Sendgrid v3 not working for me with rails my_mailer.rb
<p>I want to send a transactional mail via Sendgrid when a user registers (I use devise for authentication). I had this working fine in my_mailer.rb using SMTP as follows:</p> <pre><code> def confirmation_instructions(record, token, opts={}) # SMTP header for Sendgrid - v2 # headers["X-SMTPAPI"]= { # "su...
2
1,738
Unexplained LightHouse start_url audit error
<p>I'm running a PWA LightHouse audit with the ServiceWorker code below. The audit reports failures: -</p> <ul> <li>. Current page does not respond with a 200 when offline </li> <li>. start_url does not respond with a 200 when offline</li> </ul> <p>The PWA is recognized as Installable.</p> <p>I am using remote debug...
2
1,348
Values passed to redux-form initialValues are not rendered
<p>I have a problem rendering initialValues passed to a form using redux-form/immutable (v6.0.5) with a custom component:</p> <pre><code>// WRAPPER COMPONENT import React from 'react'; import {connect} from 'react-redux'; import DocumentsEditForm from './documentsEditForm'; import {documentsGetOneInfo} from './../.....
2
2,146
pass variable script argument to another script then qsub to program
<p>After reading through numerous bash script threads and help sites, I cannot find a solution that works.</p> <p>I want to pass a variable argument 'i' from a script to another script $i, then qsub this to a program "$1". In the program I read the variable from the argument vector (**argv) and then use this variable...
2
1,098
On Android, do gesture events work on the emulator?
<p>I am trying to detect gesture events on the emulator by making mouse clicks, should this work? I've tried double clicking (which i would expect to produce a onDoubleTap), clicking (which I would expect to produce a onSingleTapConfirmed), and dragging (to hopeful produce a onScroll), but these all produce the same t...
2
1,366
Delete LiveData with Room onClick
<p>I have created a database using <code>LiveData</code> and <code>Room</code> following <a href="https://codelabs.developers.google.com/codelabs/android-room-with-a-view/#0" rel="nofollow noreferrer">google codelabs</a> tutorial.</p> <p>Problem is I am unable to delete an entry with <code>onClick</code>. This is my <...
2
1,491
Issue when trying to play media file using android.media.MediaPlayer and SurfaceView?
<p>I am trying to play a <strong>.mp4</strong> file using the <strong>android.media.MediaPlayer</strong> class.I am trying it out on the <strong>emulator</strong>.Unfortunately all i see is a blank screen when running the application.</p> <p>I have placed the file testmp4 in the folder <strong>mnt/sdcard/</strong> </p...
2
1,156
python PIL YCbCr support
<p>Trying to create an PIL image in YCbCr mode crashes even a fresh python/PIL installation from synaptic in my ubuntu 11.04 </p> <pre><code>wim@wim-ubuntu:~$ python Python 2.7.1+ (r271:86832, Apr 11 2011, 18:13:53) [GCC 4.5.2] on linux2 Type "help", "copyright", "credits" or "license" for more information. &gt;&gt;&...
2
4,564
Is there a faster way to blit many images on Pygame?
<p>I have a "map" / track:</p> <pre><code>track_data = [ [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1], [1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 1], [1, 1, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 1, 1], [1, 1, 2, 2, 1, 1, 1, 1, 1, 1, 1, 1, 2, 2,...
2
1,736
I’d like to scrape the text in nested elements within multiple divs
<p>Using BeautifulSoup4 for python3 I’d like to scrape the text in nested elements within divs. But first, I want to extract links also nested in elements within divs.</p> <p>How would I go about grabbing a link <code>LINK-I-WANT.COM</code> and an image <code>IMAGE-I-WANT.JPG</code> nested in something like this:</p> ...
2
1,032
Does anyone know how to appropriately deal with user timezones in rails 2.3?
<p>We're building a rails app that needs to display dates (and more importantly, calculate them) in multiple timezones.</p> <p>Can anyone point me towards how to work with user timezones in rails 2.3(.5 or .8)</p> <p>The most inclusive article I've seen detailing how user time zones are supposed to work is here: <a h...
2
1,718
index.php:212 Uncaught ReferenceError: FusionCharts is not defined
<p>i want to retrieve data from mysql database into bar chart using Fusion chart. but i get this error when try to debug with console log (ctrl+shift+j in chrome): index.php:212 Uncaught ReferenceError: FusionCharts is not defined</p> <p>here is my code so far</p> <pre><code>&lt;?php inclu...
2
2,450
How to get click event using Jquery when control is in UpdatePanel in asp.net?
<p>I have three <code>div</code> div1,div2div3 containing <code>DataList</code> control in each <code>div</code>. When i click on item in <code>DataList1</code> then <code>DataList2</code> will be loaded asynchronously which in UpdatePanel of <code>div2</code>. </p> <p><strong>Problem:</strong> When i click on control...
2
4,313
Debugging PHP email form
<p>I have been trying to set up a simple form on my website that sends an email to my inbox (not the website visitor's) with email address that the visitor enters into the form. It isn't very complicated, but as I am testing, I can't seem to get any email address to work. I don't get any error message either. I will...
2
1,186
Why is my bootstrap navbar button not showing the nav items on mobile?
<p>I'm trying to create a bootstrap navbar. I've used the code from <a href="https://getbootstrap.com/docs/4.3/components/navbar/" rel="nofollow noreferrer">this site</a> to implement it. It's mostly working. The nav items are showing, and when I shrink down to a mobile size, the navbar collapses, but when I try to pre...
2
2,258
java.lang.NullPointerException upon file I/O
<p>When I run the code, I get an error. The strange thing is when I change <code>files.getTimeScore();</code> to <code>files.getLineScore();</code>, it executes without errors. However, these functions are almost identical to each other.</p> <p>When I run the <code>getTimeScore()</code> method from a main in the <code...
2
1,724
Golang Program leaking memory
<p>I am trying to write a simple program that behaves like find | grep in golang. I have the program all working using goroutines using the following pattern:</p> <p>goroutine (filech &lt;- each file as found) goroutine (store files in extension based category &lt;- grepch)</p> <p>goroutine for each filech file (grep...
2
2,864
why Zend_Db_Adapter is much slower than mysql_query
<p>I use Zend Framework in my project. I need to insert multiple records and I found that Zend_Db suprisingly slower thatn my_sql query (several times), that made me think I did something wrong. Here are two examples.</p> <p>Zend_Db_Adapter:</p> <pre><code> $startTime = microtime(true); $db = Zend_Db_T...
2
3,928
Character encoding in com.sun.net.httpserver
<p>I'm trying to write a mock HTTP server for unit tests, I'm using the com.sun.net.httpserver classes for that. I'm having problem with the encoding of the URL: the query parameters are ISO-8859-1 encoded, but the URI that is passed to the handler (via HttpExchange) is not. As I can't change the encoding of the origin...
2
2,408
How test onUpdate method of my widget not waiting 30min
<p>After 3 days learning widgets, I finally understand about setOnClickPendingIntent,RemoteViews... and I've done my widget. It has been done with help of a lot of tutorials. But now I'd like to test if it works. As I read, the minimum update rate is 30min. And the other way is using AlarmManager. But I cant find any e...
2
1,106
MongoDB nested object aggregation sum and sort
<p>I have highly nested mongodb set of objects and i want to sort subofdocuments according to the result of sum their votes for example :</p> <pre><code>{ "_id":17846384es, "company_name":"company1", "products":[ { "product_id":"123785", "product_name":"product1", "user_votes...
2
1,123
ERROR: Failed building wheel for pqcrypto
<p>I am trying to install python packages in the <code>requirements.txt</code> and get this fatal error.</p> <pre class="lang-js prettyprint-override"><code>note: This error originates from a subprocess, and is likely not a problem with pip. ERROR: Failed building wheel for pqcrypto Failed to build pqcrypto ERROR: Co...
2
6,367
How to disable surface detection in ARCore Android
<p>I am working on a project and facing an issue with ARCore. I used <a href="https://github.com/appoly/ARCore-Location" rel="nofollow noreferrer">ARCore Location</a> in my project, I set the location of object using latitude and longitude. but when I see it in the device, object location varies in AR.</p> <pre><code>...
2
3,040
Bootstrap modal not working with codeigniter form_open()
<p>Bootstrap Modal code </p> <p><div class="snippet" data-lang="js" data-hide="false"> <div class="snippet-code"> <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;!-- Signup Modal --&gt; &lt;div class="modal fade" id="signUpForm" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hi...
2
1,082
Ajax TabPanels trigger validation for other tabs in ASP.Net 4.0
<p>I have Ajax TabPanel with Tab "Employee List" "Add Employee" "Edit Employee"</p> <p>On <strong>Employee List</strong> Tab i use gridview to display list of employee along with link Button to view details of employee on same tab and "Del" button to delete employee. It worked fine but when i added Controls to Second ...
2
8,408
Cannot open connection if the server is not local
<p>I have this code in Transaction.cs</p> <pre><code>using (TransactionScope scope = new TransactionScope()) { // Setup nhibernate configuration Configuration config = new Configuration(); config.SetProperty("hibernate.connection.connection_string", GlobalVar.TRUECONNSTRING); ...
2
1,364
I am getting java.lang.runtimeexception parcelable encountered ioexception writing serializable object
<p>I am newbie to android and working on a demo app with two screens to pass a data from one to another activity, During this i am getting below exception,</p> <blockquote> <p>java.lang.RuntimeException: Parcelable encountered IOException writing serializable object (name = one.tusk.stush.connect.Post)</p> </block...
2
1,915
Spark structured streaming Elasticsearch integration issue. Data source es does not support streamed writing
<p>I am writing a Spark structured streaming application in which data processed with Spark needs be sink'ed to elastic search.</p> <p>This is my development environment, hence I have a standalone Elastic search.</p> <p>I have tried following two ways to sink the data in the DataSet to ES.</p> <p>1.<code>ds.writeStr...
2
1,466
How to fix AWS Config generating AccessDenied error?
<p>I am trying to allow AWS Config to write to a non-public S3 bucket.</p> <p>Based on <a href="https://docs.aws.amazon.com/config/latest/developerguide/iamrole-permissions.html" rel="nofollow noreferrer">the official documentation</a>, I should have two policies assigned to the AWS role. However, It is not possible t...
2
1,230
springboot2.0 integrate hikariCP2.7.9, throws "Default transaction isolation level detection failed (Proxy Warning - near ".": syntax error)."
<p>HikariCP version: 2.7.9 JDK version : 1.8.0_111 Database : MySQL</p> <p><strong>Exception</strong>:</p> <p>HikariPool-1 - Exception during pool initialization. 2018-06-28 21:09:36.545 WARN 35084 --- [nio-8008-exec-2] c.z.h.p.PoolBase : HikariPool-1 - Default transaction isolation level detection failed ...
2
2,885
jqGrid TreeGrid with checkboxes, check in parent, mark all child checkboxes
<p>I have a TreeGrid with checkboxes in both parent and child nodes. Checking a checkbox in parent node should mark all checkboxes in child nodes. My TreeGrid works ok, I tried to bind an event only to parent node in a custom formatter. It also worked. Later on I tried to mark child nodes but with no effect. Child nod...
2
2,773
FormGroup in FormArray containing object displaying [object Object]
<p>I'm working on a prototype for an editor sending data according to a model to an api. Here's the model :</p> <pre><code>title: string, desc: string, pairs: [ { left: { label: string }, right: { label: string } }, ... ] </code></pre> <p>The problem here is that I need to work with angular forms and t...
2
1,724
use same class for data target modal in same page
<p>im have a profile list page. inside the page it have modal with data-target .popupmessage. the problem is i will using the same class as much as the profile i have. how to make specific when client press the modal? because when i click the button modal to show the modal, all the modal got show up</p> <pre><code>&l...
2
1,413
Pyspark divide column by its subtotals grouped by another column
<p>My problem is similar to <a href="https://stackoverflow.com/questions/50493426/pyspark-divide-column-by-its-sum?rq=1">this</a> and <a href="https://stackoverflow.com/questions/48552672/how-to-divide-a-column-by-its-sum-in-a-spark-dataframe">this</a>. Both posts show how to divide a column value by the total sum of t...
2
1,304
Android binding and JUnit testing of notification
<p>I want to test my Android view models. Especially when the setter should notify about changes or not.</p> <p>The view model looks like this (with more bindable properties):</p> <pre class="lang-java prettyprint-override"><code>public class EditViewModel extends BaseObservable { private String _comment; @Binda...
2
1,098
AngularJS directive inside a ng-repeat loop with variable-based templateUrl
<p>Ok, I'm kinda new to the whole AngularJS thing and I'm probably getting my hands dirtier than I should, but here's what I'm trying to do:</p> <ul> <li>loop through an array of fields (array of objects actually) for a customer entity</li> <li>call a directive that chooses the template from a field property</li> <li>...
2
1,031
Object oriented data in Vue.JS
<p>I have a simple Vue.JS example simulating people playing lottery. I enter the names of the players, pushed into a list and get them listed on the screen At the end, I find the winner which is select from the list. I want to change this to a object oriented example. I want to have a player object with two attributes;...
2
2,948
Keras binary classification: same prediction output class
<p>I am using Keras sequential model for image classification. My problem is to find a particular watermark present in any part of the image or not. I am using a dataset of 9000 images. Keras backend is Tensorflow.</p> <pre><code>Keras==2.0.4 tensorflow==1.2.1 </code></pre> <p>While training, I am getting an accura...
2
1,521
ClassNotFoundException when creating new ClassPathXmlApplicationContext
<p>I'm getting through <a href="http://www.tutorialspoint.com/spring/spring_bean_scopes.htm" rel="nofollow">this</a> tutorial on Spring bean scopes. I set up everything by hand and then packaged it using maven. This is my project's structure:</p> <pre><code>. β”œβ”€β”€ pom.xml β”œβ”€β”€ src β”‚Β Β  └── main β”‚Β Β  β”œβ”€β”€ java β”‚Β Β  β”‚...
2
2,301
A non-HTTP 200 response was received (400) for URL https://developerservices2.apple.com/services/xxx
<p>Has someone run into this problem in Xcode? </p> <p>I was trying to run a sample iOS project on real device with personal team. with automatically manage signing on. But Xcode show the error: </p> <blockquote> <p>Communication with Apple failed A non-HTTP 200 response was received (400) for URL <a href="https:...
2
2,461
Sorting an Array List using Merge Sort
<p>I am having trouble with converting my sorting class to sort objects with arraylists. It is currently sorting objects, but I am having trouble converting it to sorting Arraylists. Here is the code:</p> <pre><code>package Merge_Sort_Objects_ArrayList; import java.util.ArrayList; public class mergesort { /** ...
2
1,250
selenium firefox 52.0.2 along with intellij idea is crashing
<p>I'm using IntelliJ and selenium to automate a very simple test case but It's crashing in the beginning itself. </p> <p>Also, I tried changing the firefox browser to <code>46</code> but it still opens <code>52.0.2</code> and crashes. </p> <p>Questions:<br> - <strong><em>How can I get it to work?</em></strong><br> ...
2
3,571
Change a div class if li selected
<p>I have a webpage with a prettyphoto gallery.Each images thumbnail has a different colored overlay(When you hover over the image). I have 4 categories and for each category there is a different thumbnail overlay color and that is fine.</p> <p>But I also have a 5th category where all the images from the gallery are d...
2
1,160
Groovy: Using Closure to create and return Map Elements
<p>I am importing an XML and then creating a list of objects based on the information from the XML.</p> <p>This is a sample of my XML:</p> <pre><code>&lt;DCUniverse&gt; &lt;SuperHeroes&gt; &lt;SuperHero&gt; &lt;SuperHeroName&gt;SuperMan&lt;/SuperHeroName&gt; &lt;SuperHeroDesc&gt;Surviv...
2
1,496
3D with value interpolation in R (X, Y, Z, V)
<p>Is there an R package that does X, Y, Z, V interpolation? I see that Akima does X, Y, V but I need one more dimension. </p> <p>Basically I have X,Y,Z coordinates plus the value (V) that I want to interpolate. This is all GIS data but my GIS does not do voxel interpolation</p> <p>So if I have a point cloud of XY...
2
3,216
Segmentation fault when using pthreads
<p>I'm having a segmentation fault while i'm doing a simulation of a metro station using threads The idea i'm going with is that i have 4 stations with 4 paths and 4 trains each train goes by a path to a certain station and the train moves by a thread my initial simulation was working just find until i try to enter a ...
2
3,393
Generating moderately interesting images
<p>Abstract: Can you propose a mathematical-ish algorithm over a plane of pixels that will generate a moderately interesting image, preferably one that on the whole resembles something?</p> <p><strong>The story thus far:</strong></p> <p>Once upon a time I decided in an effort to reduce cycle waste on my (admittedly t...
2
2,333
Trouble wiring Hibernate, JDBC and SpringSecurity together
<p>I am working on a simple Spring web app. I'm using Spring Security for user authentication, and Hibernate for persistence. I want Spring Security to use the database (as opposed to basic in-memory authentication).</p> <p>However, I am getting an exception when running the app.</p> <pre><code> SEVERE: Servlet /k...
2
6,361
How to implement a clustering process, using a genetic algorithm in python?
<p>I'm a novice in python coding. I have a question regarding clustering using genetic algorithm in python.</p> <p>I would like to cluster the station based on not only distance but also the other index of the cluster. I want to maximize the total index of all clusters.<br> I have 900 bike stations GPS coordinate data...
2
1,071