title stringlengths 13 150 | body stringlengths 749 64.2k | label int64 0 3 | token_count int64 1.02k 28.5k |
|---|---|---|---|
download from URL to file using Java (BufferedInputStream, FileOutputStream, Commons IO library, NIO) | <p>I have tried all the ways above to download from URL to file in java.
All the ways work, they really downloading the files to the correct directory. There is one issue:
The file content always in gibberish.</p>
<p>File content example:</p>
<p>"ãˇ¨ΩKìÏ»é&∂ü_˜l¥πUñëôÁ’ªnõ±QõFY˜’h°ë¡@A"Èx¸ëå∂˛Ô2w2y™n¡£Zã{... | 3 | 1,449 |
Dapper multi-mapping error | <p>I'm struggling to get multi mapping working in dapper.</p>
<p>Here's my code:</p>
<pre><code>var contactDictionary = new Dictionary<Guid, Contact>();
IEnumerable<Contact> contacts = connection.Query<Contact, Activity, Contact>(
@"SELECT ContactId, Title, FirstName, Surname,
... | 3 | 1,056 |
Handling failed file and directory operations in C# | <p><strong>The Problem:</strong> During an installation process, files and folders are created, moved, and renamed. Services are also starting and stopping during installation, which can cause locking issues on one or more files or folders. I have a solution to avoid most locking scenarios, but would like a better appr... | 3 | 1,313 |
Having issue with running Angular Protractor test behind corporate firewall on Sauce lab? | <p>I am not able to run protractor test on Sauce Lab. I am behind corporate firewall and I have active Tunnel to Sauce Lab using Sauce Connect. Below is my protractor conf.js</p>
<pre><code>var HttpsProxyAgent = require("https-proxy-agent");
var agent = new HttpsProxyAgent('http://userName:password@proxy.example.com:8... | 3 | 1,148 |
jQuery Rateyo rating plugin integration with AngularJS | <p>I am trying to integrate the <a href="http://rateyo.fundoocode.ninja/" rel="nofollow noreferrer">Rateyo plugin</a> with AngularJS and getting problem in defined rating value from directive, following are codes:</p>
<p><strong>EDIT: Here is the working <a href="https://embed.plnkr.co/K8mItqe42jNvDPs3GjyV/" rel="nofo... | 3 | 1,072 |
printing the closest pair of points | <p>I was writing this code to find the minimum distance between 2 points.The code I have written gives me the minimum distance correctly but does not give the correct coordinates from which the minimum distance is computed.Kindly help me identify the problem according to me this is the correct approach to print the poi... | 3 | 1,203 |
Wrong calculations | <pre><code>#include <stdio.h>
#include <cs50.h>
#include <string.h>
#include <math.h>
int letters = 0;
int words = 0;
int sentences = 0;
int main(void)
{
string text = get_string("Text: ");
printf("\n");
for(int j = 0; j < strlen(text); j++)
{
... | 3 | 1,573 |
How to make changing MSI install folder work in WiX? | <p>I created a MSI installer to install per-user.</p>
<pre><code><?xml version="1.0" encoding="UTF-8"?>
<Wix xmlns="http://schemas.microsoft.com/wix/2006/wi">
<Product
Id="*"
Language="1033"
Manufacturer="my company"
Name="... | 3 | 1,557 |
Different Relative path inside External Js file | <p>I have an Html file on 1 domain (let's say <a href="https://a.com" rel="nofollow noreferrer">https://a.com</a>) that calls a Javascript file on a different domain (let's call this <a href="https://b.com" rel="nofollow noreferrer">https://b.com</a>). One of the functions of the JS file is to load SVG files. The SVG f... | 3 | 1,202 |
How can I make sure a BS4 request is being made with a socket on a list? | <p>I have a list of proxies like this one I would like to use in scraping with python:</p>
<pre><code>proxies_ls = [ '149.56.89.166:3128',
'194.44.176.116:8080',
'14.203.99.67:8080',
'185.87.65.204:63909',
'103.206.161.234:63909',
'110.78.177.100:65103']
</c... | 3 | 1,485 |
How to create spec from data | <p>I am trying to create spec just from data. I have very complex data structure - all nested map.</p>
<pre><code>{:contexts
({:importer.datamodel/global-id "01b4e69f86e5dd1d816e91da27edc08e",
:importer.datamodel/type "province",
:name "a1",
:importer.datamodel/part-of "8cda1baed04b668a167d4ca28e3cef36"}
{... | 3 | 1,767 |
how can i make grid (design) responsive? | <p>i've tried everything to make this design responsive but i haven't got anything</p>
<p>Looking for some help or suggestion would be great..</p>
<p>Thank you </p>
<p><a href="https://jsfiddle.net/bobharry/w1j7anvx/1/" rel="nofollow noreferrer">JsFiddle</a></p>
<pre><code> <div class="box-section">
<d... | 3 | 1,027 |
Why won't this align middle or bottom? | <p>OK, so my stupid little login form almost looks how I want it to look. (This is basically my first CSS project ever and first HTML project since <strike>updating</strike> attempting to update my 15 year old HTML skills.) For the life of me, I can't figure out how to get the "forgot password?" link to move down, eit... | 3 | 1,556 |
Jenkins send e-mail notification to github committers | <p>We want to send out e-mail notifications to our contributors if the Jenkins build was successful or not.</p>
<p>we are using the email extension plugin: <a href="https://plugins.jenkins.io/email-ext/" rel="nofollow noreferrer">https://plugins.jenkins.io/email-ext/</a></p>
<p>Notifications should be sent in the follo... | 3 | 1,155 |
Error configuring CMake for Ethereum project with Visual Studio 2015 Community on Windows 10 | <p>I have visual studio 2015 community version on Windows 10. I downloaded Ethereum project on github and tried running
CMake .. -G "Visual Studio 14 2015 ARM"
command but it failed with following message. (The failing step seems to be the installation of Boost through hunter):</p>
<pre><code>-- Selecting Windows... | 3 | 3,478 |
How to get image from file/database and display in list view? | <p>I am new to android i want to make an application of list of image in which i want save image from camera to data base and retrieve from database.I want to do this by saving uri of database .I did it in following way
1. I am saving image in file and set it in image view further
2. I am going to save images ur... | 3 | 2,017 |
XML android:windowSoftInputMode isn't working exactly how I want | <p>I have a simple layout, shown below:</p>
<pre><code><RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:orientation="vertical" >
<ScrollView
android:layout_width="match_parent"
... | 3 | 1,033 |
EXC_BAD_ACCESS KERN_INVALID_ADDRESS 0x0000000000000000 : Xamarin Forms, iOS, intermittent Crash | <ul>
<li>Xamarin Forms Version : 4.8.0.1560</li>
<li>Happens for multiple iOS versions</li>
<li>iPhone & iPad</li>
</ul>
<p>Crash is intermittent & happens in production release for 12 % of overall users.</p>
<p>firebase crash analytics shows below line as a crashing point & the list is never null or empty<... | 3 | 3,973 |
Turn Koeppen Climate Legend into meaningful csv with regex | <p>I have this table:</p>
<pre><code> 1: Af Tropical, rainforest [0 0 255]
2: Am Tropical, monsoon [0 120 255]
3: Aw Tropical, savannah [70 170 250]
4: BWh Arid, desert, hot [255 0 0]
5: BWk Arid, desert, cold ... | 3 | 1,135 |
react, redux why button is not updating its view after click | <p>so i i've been building admin panel for my app, and main window is dashboard with the list of users, so i can delete, or verify them (for now);
delete part is working fine here, but i struggle with update part (verification of user) when click on the button (ACTIVE) react sends request to server to verify user, and ... | 3 | 2,455 |
Postgresql Fill in missing dates using raw sql | <p>I have the following tables (simplified below):</p>
<p><code>Orders:</code></p>
<pre><code><id: 1, shipping: 6.0, price: 20.0>
<id: 2, shipping: 10.0, price: 30.0>
<id: 3, shipping: 7.0, price: 12.0>
<id: 4, shipping: 5.0, price: 0.0> #0 dollars because it was updated after return
</code></pr... | 3 | 1,098 |
Button and text box wont go Visible=false | <p>Hello I have a page which displays some information retrieved from the database. And I have a textbox and a button I want to hide when I get emptydataset from the database.</p>
<p>This is the aspx code</p>
<pre><code><asp:FormView ID="BookDetailView" runat="server" ItemType="WebApplication1.Models.Book" SelectM... | 3 | 1,752 |
move some data from excel to sql | <p>I want to move some data from an Excelfile to my database. I use c#
this is my code:</p>
<pre><code> //conecting to DB
SqlConnection sqlcon = new SqlConnection("Data Source=.;Initial Catalog=ghalamchi;Integrated Security=True");
SqlCommand SqlCmd = new SqlCommand();
SqlCmd.Connection ... | 3 | 2,133 |
Find overlapping segments in multiple columns | <p>I have following data set and would like to get in a separate column the number of overlapping labels (<code>n.overlaps</code>), the name of the overlapping labels (<code>overlap.labels</code>) and also the duration of the overlap (<code>overlap.duration</code>). </p>
<p>This is my data set:</p>
<pre><code>label ... | 3 | 1,080 |
Unexpected EOF while parsing on a very simple class | <p>No inputs, just some pseudo private fields and basic assignments, but it is still giving me the unexpected EOF while parsing error. The exception is given at line 28, when there are 24 lines of code. </p>
<pre class="lang-py prettyprint-override"><code>class Word:
def _init_(self,text,size):
self._te... | 3 | 1,741 |
Python XML parsing with ElementTree: How to find values of elements with the same name? | <p>Disclaimer: I am new to Python, XML, and programming in general. The code (that I stole from the internet) works but has some problems that I can't seem to find the answer to or wrap my brain around...</p>
<p>I am trying to parse XML files from the <a href="http://www.grants.gov/web/grants/xml-extract.html" rel="no... | 3 | 2,295 |
ASP.NET MVC2 model binding problem | <p>Why is my controller receiving an empty model in this case?</p>
<p>Using</p>
<pre><code><%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<X.Models.ProductModel>" %>
<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="s... | 3 | 1,457 |
Filtering data in a table - how to organize it correctly | <p>I study the spring+Hibernate bundle there Is an entity:</p>
<pre><code>public class PersonEntity {
private Long id;
private String name;
private Integer age;
private City city;
private Countrycountry;
...
}
</code></pre>
<p>I need to perform filtering. data in this table to display in the browser... | 3 | 1,101 |
Extract RSSI, Lat, Lng for each TagId from log file | <p>I have a txt log file like so, and I want to extract the RSSI values, lat, long for each TagID.</p>
<pre><code>INFO:received msg from tag : : {"tagId": "8593e96004019a2e", "anchor": [{"RSSI": -71, "ID": "P ID 00010c"}, {"RSSI": -71, "ID&quo... | 3 | 1,300 |
Firebase Flutter StreamBuilder when dismiss the list from listview the Screen is lagging a bit | <p>The link is my situation in .mp4 for 3 secs
<a href="https://drive.google.com/file/d/1NHzRgB8OU5TzWHUpPBFC-cy0D6Zqc_3T/view?usp=sharing" rel="nofollow noreferrer">the lagging screen</a>.
I found my screen shows some lagging situation after I dismiss the listview and update the doc.</p>
<p>This is my dismissible widg... | 3 | 1,870 |
How to return int from select option value in plain html in django | <p>I have a plain html form which contains a select option, the select option value should return an int to be stored in the database.</p>
<p>I have tried converting the value to int in the view but it still doesnt work.</p>
<p>This is the ScrummyGoals Model</p>
<pre class="lang-py prettyprint-override"><code>class ... | 3 | 1,103 |
Different types doesnt write to file | <p>I am creating three text files, and try to write to them from a list. When I have the code like in the first example, nothing is written to the first file, only second or third. If written like in the second code, nothing is written to the first or second file, only third. What is wrong and how can I correct this co... | 3 | 1,096 |
Displaying images from a MySQL Database with MAMP | <p>I'm trying to query images from a MySQL Database through MAMP on MacOS.</p>
<p>I'm using this code:</p>
<pre><code><!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<!-- <meta name="viewport" content="width=device-width, intial-scale=1.0"/> -->
<link rel="stylesheet" href=... | 3 | 2,207 |
How to design chat talking layout has leftside and rightside when use Firebase? | <p>I use Firebase realtime databse to complete chat app.</p>
<p>I want to design when the name is <code>Tom</code>, the textView will show on right side side, others will show on left side.</p>
<p>Here's my layout: two textView design for left and right:</p>
<pre><code><RelativeLayout xmlns:android="http://schema... | 3 | 3,028 |
How to sort array of objects based on number of nested sub-childs of objects? | <p>What is the best way to sort the following array in order on number of sub childs (i.e. number of <code>ISBN</code>s in this case).</p>
<pre><code>const data = [{
"Arnold Bennett": {
"9781784872359": {
"thumbnail_image_url": "https://books-sn.s3.amazonaws.com/571b8c01-ed88-4cc1-8e0c-efe3d... | 3 | 3,888 |
Datatable child row not appearing in first column when in responsive mode | <p>I'm not sure what I am doing wrong here but when I click on the details contro,. the child row is dsiplayed but it pushed to a new column at the end of the data table.</p>
<p>Here is my code:</p>
<pre><code><div class="col-xs-4">
<table id="exp_datatable" class="display ">
<thead>
<... | 3 | 1,279 |
How to test promises in Mongo(ose)/Express app? | <p>I'm using promises to wrap asynchronous (Mongo) DB ops at the end of an (expressJS) route.
I want to try and figure out how to test the following code.</p>
<p><strong>userService</strong></p>
<pre><code>userService.findOne = function (id) {
var deferred = q.defer();
User.findOne({"_id" : id})
.e... | 3 | 1,107 |
C# find differences between images | <p>I'm trying to compare screenshots and write only the differences.</p>
<p>This is my code</p>
<pre><code>public Bitmap Difference(Bitmap bmp0, Bitmap bmp1)
{
Bitmap bmp2;
int Bpp = bmp0.PixelFormat == PixelFormat.Format24bppRgb ? 3 : 4;
bmp2 = new Bitmap(bmp0.Width, bmp0.Height, bmp0.PixelF... | 3 | 1,833 |
mariadb, add 4th galera node failed | <p>I have three <code>node</code> setup and running perfectly for the past months.
Recently I want to add another <code>node</code> in a different location but somehow I keep on getting errors.</p>
<p>At first, I was just following this tutorial (where I setup the first time few months ago) <a href="https://www.howtof... | 3 | 1,435 |
Django background thread exiting unexpectedly when running in Azure web service | <p>First post to Stack Overflow and not (yet) that experienced with Python/Django so be kind :)</p>
<p>I am working on a Django web app which is exhibiting some odd behavior when deployed to an Azure web service container. The application includes a page from which you can upload a CSV file containing records to be e... | 3 | 1,223 |
How to bring dragged div to top of everything while using two scrollers? | <p>I have two horizontal scrollers and I need to drag div from upper scroller to lower scroller. This is working fine but the problem is that the dragged div gets lost under the scroller borders while dragged. Dragging comes from <code>jquery-UI</code> and scrollers smoothdivscroll.</p>
<p>Is there a way to fix it or ... | 3 | 2,592 |
Use xslt:analyze-string to add acronyms to HTML - now with synonyms | <p>I already posted the question how to add acronym tags to HTML text and got a nice solution (see <a href="https://stackoverflow.com/questions/4445567/use-xsltanalyze-string-to-add-acronyms-to-html">Use xslt:analyze-string to add acronyms to HTML</a> ). Thank you!</p>
<p>Now I added synonyms to my acronyms and adapte... | 3 | 2,117 |
Change button function at runtime in pyqt5 | <p>When the program starts running, I assign the CreateNew function to the btn_UpdateDelete button in the constructor function. But I want to replace it with UpdateFunc after the program starts running. When I click the Update button after the program starts running, the CreateNew function works. Is there a method to c... | 3 | 1,878 |
How to merge php and html code? | <p>I want to show a table. I am getting rows from database and according to that I want to show the data in table data.</p>
<p>I want to show an image which will have source from database.</p>
<p>As I am using ajax I am calling getPosts from ajax and showing it in a table, so I am returning the data from getPosts.php... | 3 | 1,799 |
Why not close modal window?CSS | <p>I have this modal window</p>
<p><a href="https://jsfiddle.net/wxorg152/" rel="nofollow">https://jsfiddle.net/wxorg152/</a></p>
<p>(seen bad because I copied from the site and CSS code as there's not)</p>
<p>The window opens problem is not going to close ... how can I close it?</p>
<p><strong>CODE HTML:</strong><... | 3 | 1,873 |
Npm install falied | <p>I'm trying to perform JP Morgan(Virtual Internship) Task 3. According to instructions I have done the setup.</p>
<p>But while running the script <code>npm install</code> on kali linux, I get this error.
I'm using the latest linux and npm version. Is my current version of npm conflicting with the preferred version of... | 3 | 13,496 |
MongoDb extract array | <p>I have a mongodb which I want to extract some specific data.
Here is my json:</p>
<pre><code> {
"jobs" : [
{
"id": 554523,
"code": "1256-554523",
"name": "Banco de Talentos",
"status": &q... | 3 | 3,237 |
Why does a multiprocessing process do the same job twice as long? | <p>I am doing some image analyzer within Blender and want to use multiprocessing in order to reduce calculation time. But when I split a list of pixels values into 4 parts between 4 processes, each of which then copy its list inside an invoked function, it turns out that one multiprocessing process do its work on copie... | 3 | 1,134 |
(VB.NET) display the lower half of a textfile to a listbox | <p>I have to make a application that organizes a list of runners and their teams. In the following text file, I have to remove the top half of the text file (the top half being the listed teams) and display only the bottom half (the runners)in a listbox item. </p>
<p><strong>The Text file:</strong></p>
<pre><code> # ... | 3 | 1,707 |
How to destroy/free an anonymousThread | <p>On windows, to stop and destroy an anonymous thread, i simply do <strong>FmyTask.free</strong> => that will call <strong>destroy</strong> => and that inside the destroy will set <strong>terminate = true</strong> and call <strong>waitfor</strong> to wait the task is finished => and finally clean the memory used</p>
... | 3 | 1,334 |
Swift framework for iOS and macOS | <p>currently i'm developing an app for my graduation project. The problem is, that it's not just one app, it consists of an iOS app that is made for the users and a macOS app for the "Owner". In the mac App the owner can create a file that should then be red in the iOS app.</p>
<p>Until now I have made a script that h... | 3 | 1,537 |
Piano Keys-- Not overlapping and now not showing up | <p>Note: I'm working with jFugue.</p>
<pre><code>public class Piano extends JFrame implements KeyListener {
ArrayList<Keys> keys = new ArrayList<Keys>();
Player playNote = new Player();
public Piano() {
drawGrid();
this.addKeyListener(this);
this.setVisible(true);
... | 3 | 1,373 |
jQuery's $.append() breaks my loop, why? | <p>I'm trying to draw some text in an array of colors to the screen. However, when using jQuery's <code>$.append()</code> with the <code><span></code> tag, it stops my loop and does not color anything. This is what it looks like:</p>
<pre><code> var pixelsjson = '[{"red":232,"green":255,"blue":255},{"red"... | 3 | 4,633 |
iOS RealityKit. Changing Entity's translation causes unexpected behaviour | <p>I am trying to create some AR experience.</p>
<p>I load the <strong>Model</strong> with animations as an <strong>Entity</strong>. Lets call it a <strong>Toy</strong>.
I create an <strong>AnchorEntity</strong>.
I attach the Toy to the <strong>AnchorEntity</strong>. Up to this point everything works great.</p>
<p>I wa... | 3 | 1,369 |
Extract Ticket Number from a URL | <p>In Amazon Redshift, we capture the Ticket Number for Survey we do in our company in one of the responses of the survey question:</p>
<p>Data</p>
<pre><code> question response
Q10 https://test-auth.xyz.com/login?next=%2FSSO%2Fredirect%3Fredirect_uri%3Dhttps%253A%252F%252... | 3 | 1,112 |
Show LoggedIn username on successful login [getting JSX and Router related error in code] -- | <p>My aim is to show logged in user name and a logout link in the header section.
User logs in to my app. with username and password. Upon successful login,
I would like to show the respective username in the top right header strip, along with a logout link.</p>
<p>header strip html [located in App.js] -</p>
<pre><co... | 3 | 5,150 |
Php unit test when using Promise | <p>I use the Promise by AWS SDK to save many files to S3 bucket. I fail to build the unit test for that.</p>
<p>My functions </p>
<pre><code>function save($item, array $layers)
{
$promises = [];
foreach ($layers as $key => $layer) {
$filename = $this->getS3Filename($item, $key);
$promise... | 3 | 1,142 |
The iisexpress is loading infinitely | <p>I am facing a very weird problem on my iisexpress. I can run my application once but when I stop and restart it, it doesn't exit loading ... it loads infinitely.</p>
<p>I already disabled windows firewall, antivirus, edit and continue options and nothing resolves.
If I close visual studio and delete the applicatio... | 3 | 3,077 |
Specification Predicate to Search Nested jsonb column Objects | <p>I have stored jsonb object in postgresql like</p>
<pre><code>{"sample": {"lastName": "Sahani", "firstName": "Sanjay"}, "address": "Address2", "bedrooms": 2, "postcode": "40 BS", "propertyType": "Type 2"}
</code></pre>
<p>My table name is <strong>valuation_report_json</strong>
and <strong>jsonb column</strong> name... | 3 | 1,245 |
Process finished with exit code instead of returning back to main function | <p>I am creating an grocery store system as an assignment in C for a class I put off until my senior year. It uses a linked list to keep track of products in the store. I have gotten it mostly working, but for some reason each time I select a menu option, it will run until it tries to access a NULL memory location (Pro... | 3 | 4,276 |
Adding new related entities in a single action | <p>Every riddle has one or more questions, how can add both a Riddle and a Question to that riddle by submitting a single form?</p>
<p>This is RiddlesController Create action code:</p>
<pre><code>public ActionResult Create(RiddleViewModel model)
{
if (ModelState.IsValid)
{
... | 3 | 1,333 |
In a Windows dockerfile, how can I pass an ARG value to a RUN command? | <p>I cannot find any syntax that works. Even suggested solutions on stackoverflow do not work. Running them shows blank output where values are expected.</p>
<p>ENV variables are not persisted in the built image (i.e. running 'set' from the command line in the running container shows that the variable is not set).</p>
... | 3 | 1,322 |
How to determine CC / BCC selection using VBA GetSelectNameDialog from Global Address List | <p>Hi knowledgeable people!</p>
<h2>Background:</h2>
<p>I am developing a custom mail merge tool in MS Word VBA for our team so that we have extra functionality beyond the standard Office Word mail merge package. 3rd party products or add-ons are <strong><em>not</em></strong> possible. But, the ability to automatical... | 3 | 1,599 |
Setting Nullable Enum to $null - Should this really cause PSInvalidCastException? | <p>Setting a Nullable Enum to $null in PowerShell causes a<code>System.Management.Automation.PSInvalidCastException</code> exception. This is unexpected (to me at least). Is there a reasonable explanation for this? Here is an example that shows how setting a Nullable Int32 is successful, but setting a Nullable Enum ca... | 3 | 2,212 |
CSS Transform happens instantly in Safari | <p>i'm a huge noob just trying to learning to code on my own.. and i'm at the point where i want my code to work in all the popular browsers .. :) .. i'm starting with Safari.. my code runs fine in chrome.. but the -webkit-transition: transform 1.0s; just happens instantly on safari for some reason.. not sure if there ... | 3 | 5,063 |
$_SESSION not seeming to work | <p>I have a php script that should detect the <code>$_SESSION['Username']</code> and fwrite it into a txt file. I have a similar script running on my site but for a different use and it is working just fine. As you can see I have </p>
<pre><code>$nickname = $_SESSION['Username'];
</code></pre>
<p>and </p>
<pre><cod... | 3 | 1,837 |
NullPointerException with adapter | <p>I have this observer for my viewmodel so that I can setup my adapter but, when I run the app, it gives me the NullPointerException error on this line:</p>
<pre><code>japaneseAdapter = it.data?.let { it1 -> JapaneseAdapter(it1) }!!
</code></pre>
<p>This is the activity with that line:</p>
<pre><code>@AndroidEntryP... | 3 | 2,153 |
AWS Load Balanced socket.io server, running behind a Proxy on NGINX | <p>I'll be candid - I know very little about websockets, my config file was setup by a developer we had years ago, and even then I dont think his configuration was correct. All the HTTP(S) REST API responses work, but the websockets features are having issues.</p>
<p>I am getting an error from the web console in produc... | 3 | 5,147 |
From the leakCanary report How to understand which objects are garbage collected and which are not ? | <p>Here is my Code . I need to understand which objects are Garbage collected and which are not. Which objects values are assigned <strong>null</strong> here , are they garbage collected ? By observing this report how to understand which methods , classes are garbage collected or not . where can I get a resource to un... | 3 | 3,497 |
Stripe redirectToCheckout error. Will not load stripe checkout when I click the button to submit | <p>So I've set everything up with stripe to load when I hit submit in my checkout page in react however, I only seem to get this error below. On the stripe dashboard I can see that the POST request is status 200 and the email I am using along with price from the basket etc is reaching stripe. I just don't seem to have ... | 3 | 1,513 |
Reactjs props keep getting re-rendered | <p>I am pretty newbie to react and its lifecycles, I am trying to get a specific profile data that created a specific post. I am able to receive data from the profile props but it has a strange behavior. </p>
<p>So when I <code>console.log(profile)</code> in render method, profile stays null along with rendering post ... | 3 | 2,165 |
How to consolidate arrays under one single MultiLineString GeoJSON array using jq? | <p>There are coordinates within an array that are divided up between multiple GeoJSON <code>MultiLineString</code> structures. I would like to consolidate all the coordinates, maintaining them in their own array, under one single MultiLineString structure. How do i do this with <code>jq</code> ?</p>
<p>This is the ori... | 3 | 2,072 |
FileChannel close is too slow. Will pre allocating space improve things? | <p>I use a FileChannel to write 4GB files to a spin disc and although I have tweaked the buffer size to maximise write speed and flush the channel every second the file channel close can take 200 ms. This is enough time that the queue that I read from overflows and starts dropping packets.</p>
<p>I use a direct byte ... | 3 | 1,436 |
Tkinter and PIL error | <p>I am trying to get a .gif animation to work next to a picture with buttons on it. but i seem to be having a issue, I am importing these modules
"import Tkinter" and "from PIL import Image, ImageTk, ImageSequence"
But, as soon as I make "import Tkinter"---"from Tkinter import *"
It says Tkinter is not defined, I ha... | 3 | 1,056 |
Android App Unfortunately App has stopped | <p>I am still learning Android programming, had this app and its giving me the unfortunately stopped error.</p>
<p><strong>MainActivity</strong></p>
<pre><code>package com.nyt.ilm.ilmsarf;
import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentActivity;
import android... | 3 | 2,617 |
Cannot find bounds of current function (Code::Blocks) C++ | <p>I am using the latest version of Code::Blocks. I have a function that passes in a string and a vector. The function compiles with no errors. However, when I run the debugger, it immediately leads me to line 118 (which I have noted) and gives me trouble. The error that comes up says "Cannot find bounds of current fun... | 3 | 1,780 |
GitLab global post-receive server hook for all repositories not executed after CI job completion | <h2>Context</h2>
<p>After setting up a GitLab server, GitLab runner CI, and creating a test-repository that completes a CI-job successfully, I was experiencing some difficulties in ensuring a <code>post-receive</code> script is completed after the CI is finished successfully on the test repository commit.</p>
<h2>MWE</... | 3 | 1,287 |
run a python file by calling from php file | <p>i have a php file through which i am sending variables to python file using:</p>
<pre><code> echo
shell_exec("C:/xampp/htdocs/Ai_Edutech_trial_project/eclipse_workspace
/Project/dbConn.py '$sess'");
</code></pre>
<p>it is working fine and but only a very small portion of python file is getting executed. I want... | 3 | 1,563 |
php preg replace not replacing variation of link | <p><strong>UPDATE SOLVED (added answer here so you don't waste your time) this is just to help others in the same pickle</strong></p>
<p>I have just noticed the link text is being cut in the post turning the html portion to:</p>
<pre><code><a href="https://twitter.com/digitalOcean/status/723205273226190848" target... | 3 | 1,359 |
how to show filecount on UI in windows application | <p>what I am trying to do is to update the file count on UI every time it reads the file. Similarly it is not even showing the total number of files on the UI , the moment user clicks on the ok button of the browseFolder event.Any help would be appreciated. Below Is my Code :</p>
<pre><code>private void browse_Click(o... | 3 | 1,772 |
Task scheduling gets stuck | <p>I am currently trying to get my grip on OptaPlanner as it seems to be the perfect solution for <a href="https://softwareengineering.stackexchange.com/questions/237431/algorithm-to-calculate-scheduling-of-task-list-check-feasability">a problem I have</a>.</p>
<p>Basically the <a href="https://www.optaplanner.org/docs... | 3 | 1,546 |
A page can only have one server tag | <p>i have a master page with me but when i run the shopcart page, it shows me the error "A page can have only one server-side Form tag". i dont know which runat to be removed
Any help would be appreciated thanks :)</p>
<p>this are my codes for master page</p>
<pre><code><asp:ContentPlaceHolder ID="headersContainer... | 3 | 2,544 |
Using a Java Stream instead of a for-loop skips code execution | <p>Switching a bunch of for-loop code to use a parallel stream is apparently causing a certain part of the code to be ignored.</p>
<p>I'm using MOA and Weka with Java 11 to run a simple recommendation engine example, taking cues from the source code of <code>moa.tasks.EvaluateOnlineRecomender</code>, which uses MOA's ... | 3 | 1,582 |
Puzzling behaviour of Firefox with some CSS | <p>This XHTML seems to me to be rendered incorrectly by Firefox 34, inasmuch as FF doesn't cascade the font-size declaration in class 'all' to the table scope in the body. Is it just my misunderstanding of CSS? See the comment in the XHTML.</p>
<pre><code><?xml version="1.0" encoding="UTF-8"?>
<html>
... | 3 | 1,121 |
Pivot from long format to wide format in a dataframe | <p>I have the dataframe below:</p>
<pre><code>dput(Moment[1:15,])
structure(list(SectionCut = c("1", "1", "1", "1", "2", "2", "2",
"2", "3", "3", "3", "3", "Left", "Left", "L... | 3 | 1,193 |
How to pass the selected value in dropdown in table to another page? | <p>In this code, I have 2 dropdowns in the table (one is the options from MySQL and I checked the condition for options) and I want to pass their values for each row to the next page when I push the button "call" in that row.</p>
<p>So, how can I do this?</p>
<pre><code><table class="table-info"&... | 3 | 2,313 |
Prism.js Disturbs Ajax? | <p>I have two simple Python code files <code>hello.py</code> and <code>world.py</code>.</p>
<pre><code>print("hello")
</code></pre>
<pre><code>print("world")
</code></pre>
<p>Based on <a href="https://stackoverflow.com/questions/39913138">this way</a>, I wrote, using both Prism.js and Ajax, an HTML ... | 3 | 1,282 |
A simple C++ program | <pre><code>#include<iostream>
using namespace std;
int main()
{
char res[13][6];
int i,j;
int choices=0;
// Declaration of all the variable.
int row0,row1=0,row2=0,row7,row8;
int class_choices=0;
for(i=0;i<13;i++)
for(j=0;j<6;j++)
res[i][j]='*';
do
{
cout<<"Type of service provided.... | 3 | 2,823 |
How to optimize this LINQ query for Visual Studio? | <p>I have this one gigantic complex LINQ to SQL query that I need to optimize somehow, because the background C# compiler completely hogs the CPU and I can't type or edit my <code>.cs</code> file normally in Visual Studio 2010 (every letter, especially if IntelliSense wants to pop up, lags horribly).</p>
<p>The culpri... | 3 | 1,762 |
C# Regex Issue Getting URLs | <p>To explain briefly, I'm trying to search Google with a keyword, then get the URLs of the top 10 results and save them.</p>
<p>This is the stripped down command line version of the code. It should return 1 result at least. If it works with that, I can apply it to my full version of the code and get all the results.<... | 3 | 2,345 |
System.Windows.Forms.Timer Tick interval shorter than defined interval | <p>I am developing a Powershell script using System.Windows.Forms to monitor and process contents of a folder. To automatically check the contents of a folder i used System.Windows.Forms.Timer with an interval of 2000ms. Each Tick the function Timer_Tick is invoked, which in its turn invokes another function.</p>
<p>Wh... | 3 | 2,630 |
onClick called repeatedly (not supposed to) when component re-renders | <p>I have a react component which is a form. When user clicks on the send/submit button, a function is called to handle data saving and do some other tasks. </p>
<p>The issue is after the user clicks the button, the component seems to re-render several times (most likely because the external props it receives from oth... | 3 | 1,233 |
App not showing after import new component in App JS | <p>After I import a new component in <code>app.js</code> the app renders nothing on the browser and does not even get an error. The new component is <code>cart.js</code>. Also sharing the <code>modal.js</code> code because it's used in the cart component as a wrapper.
Also when I remove the Cart component from App JS, ... | 3 | 1,334 |
Reduce JavaScript execution time (mobile device check) | <p>I have this problem: <a href="https://i.stack.imgur.com/TG4x2.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/TG4x2.png" alt="enter image description here" /></a></p>
<p>And that's my code for the mobile.html function:</p>
<pre><code><!-- Mobile Redirect -->
<script type="tex... | 3 | 1,692 |
Capturing a local variable in a local function | <p>I have this maze-like thing with 2 points in it and I want the distance between those points through the maze. To do this I will use A* (unless there is a better algorithm I don't know about), but to use A* I need my <code>SN</code> (search node) struct to implement the <code>Ord</code> trait. I want to use the Manh... | 3 | 1,078 |
java.lang.IllegalStateException: couldn't execute method of the activity | <pre><code>import android.app.Activity;
import android.content.Intent;
import android.database.Cursor;
import android.database.sqlite.SQLiteDatabase;
import android.os.Bundle;
import android.view.Menu;
import android.view.MenuItem;
import android.view.View;
import android.widget.Button;
import android.widget.Toast;
pu... | 3 | 1,749 |
Nested lists references not working | <p>I'm a noob in middle school. I have a short piece of code that isn't working:</p>
<pre><code>board=[]
temp=[]
for var0 in range(17):
temp.append(' ')
for var in range(17):
board.append(temp)
class group:
def __init__(self):
self.f=[]
self.x=[]
self.y=[]
groupb=[]
groupw=[]
wh... | 3 | 1,488 |
mongo query from loopback issue | <p>I am trying to query in mongo db from loopback model. But i am not getting any result from monogdb</p>
<p>This is how my document looks like in mongodb</p>
<pre><code>{"_id":"5b9f8bc51fbd7f248cabe742",
"agentType":"Online-Shopping",
"projectId":"modroid-server",
"labels":["category","price"],
"phrases":["Look for ... | 3 | 1,275 |
Why is my bison/flex not working as intended? | <p>I have this homework assignment where I have to transform some input into a particular output. The problem I'm having is that I can only convert the first line into the output I need, the other lines return a "syntax error" error.</p>
<p>Additionally, if I change the lines order, no lines are converted so only one ... | 3 | 1,640 |
Javascript Waiting for result before continuing | <p>I am new to Javascript and trying to run before I can walk but I have to produce a result so here I am.</p>
<p>I thought I had found the answer to this in another question but it did not work for me as expected, below is my script the function of which is to look at a SharePoint list and return some values into 3 a... | 3 | 5,103 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.