title stringlengths 13 150 | body stringlengths 749 64.2k | label int64 0 3 | token_count int64 1.02k 28.5k |
|---|---|---|---|
Error after creating a foreign key: django.db.utils.IntegrityError: MyApp_job__new.level_id may not be NULL | <p>I've created a new attribute <code>level</code> in my model. I've forgot to put there <code>null=True</code> before migrations. When the cmd asks whether I want to put a default value, I've typed <code>None</code>. Now, I can't do <code>migrate</code>. So I tried to remove <code>level</code> column and do new <code>... | 3 | 2,928 |
Cannot start rails server, I get an error | <p>I'm new to Ruby on Rails. So, I'd got this error before, and I reinstalled rails and ruby and installed them again, but I still get it.
The error is:</p>
<pre><code>/home/X/.rvm/gems/ruby-2.2.1/gems/bundler-1.11.2/lib/bundler/runtime.rb:80:in `rescue in block (2 levels) in require': There was an error while trying ... | 3 | 1,422 |
Button click makes gui freezes | <p>I want to call method from jButton. But when I hit the button, the GUI freezes. I've done so many research, and of course I know this kind of question has asked many times but I still can't find the solution. So I'm just gonna ask myself.</p>
<p>here's my method:</p>
<pre><code> private void c2(){
try{
... | 3 | 2,218 |
Create subcolumns from old dataframes | <p>I'm trying to create a DataFrame with subcolumns where the subcolumns are Dataframes.</p>
<p>Data:</p>
<pre class="lang-py prettyprint-override"><code>import pandas as pd
from pandas import Timestamp
df1={'Open': {Timestamp('2020-12-15 01:05:00'): 152.28, Timestamp('2020-12-15 01:10:00'): 151.59, Timestamp('2020-12... | 3 | 2,416 |
Need help creating TicTacToe with GTK using C | <p>I'm currently working on an assignment for class that requires me to use GTK with C to create a TicTacToe game, and I'm almost there, but for some reason, whenever I click a box to put an "x" or "o" into, the does what it's supposed to do, but also adds a row, to the point where whenever I click anything, it just ad... | 3 | 11,275 |
vuedraggable is triggered under the modal window and breaks the list | <ul>
<li>Rails 6
<ul>
<li>Vue 2.6.10</li>
<li>vuedraggable 2.23.0</li>
</ul></li>
</ul>
<p>The problem is the following, there is a list with Cards inside, when you click on Card, a modal window with Card pops up, after that if you hold down the left mouse button on the modal window and hold the mouse, the vuedraggab... | 3 | 4,543 |
Unable to see code coverage tab on sonar dashboard for selected applications | <p>I have couple of unit testcases written in my project. On the sonar dashboard the code coverage tab is completely missing.
For some other projects the sonar dashboard is showing expected code coverage though. </p>
<p>the pom file of project is as attached : </p>
<pre><code> <plugins>
<plug... | 3 | 6,410 |
Windows: FlushFileBuffers system call fails on network mapped drive | <p><code>fsync</code> doc states</p>
<blockquote>
<p>Calling fsync() does not necessarily ensure that the entry in the directory containing the file has also reached disk. For that an explicit fsync() on a file descriptor for the directory is
also needed.</p>
</blockquote>
<p>I'm trying to sync a directo... | 3 | 1,059 |
How to fix strange rendering issue in 2d pygame using math | <p>Im trying to create a 2D game engine that will later be upgraded to 3D in a Duke Nukem 3D style. Right now I'm making a top down 2D view where I can check all the coordinates are in the right place then I can start work on the 3D engine. It is meant to work by allowing the player to move in 2D and showing where the ... | 3 | 1,118 |
AssertionError is raised when running an example from sklearn library | <pre><code>import pandas as pd
import numpy as np
from sklearn.learning_curve import learning_curve
import matplotlib.pyplot as plt
def plot_learning_curve(estimator, title, X, y, ylim=None, cv=None,
n_jobs=1, train_sizes=np.linspace(.1, 1.0, 5)):
"""
Generate a simple plot of the test... | 3 | 1,453 |
NPE in Drag and Drop | <p>I'm tested this code in Windows JVM 7_25 it works well.</p>
<pre><code>import java.util.Random;
import javafx.application.Application;
import javafx.collections.ObservableList;
import javafx.event.EventHandler;
import javafx.scene.Node;
import javafx.scene.Scene;
import javafx.scene.input.ClipboardConte... | 3 | 12,819 |
python policy gradient reinforcement learning with continous action space is not working | <p>i am trying to learn an agent to navigate to a target in my custom environment.
The agent is learning with a neural net (2 hidden Dense layer, one dropout and one output layer of dimension 4). As input nodes the agent uses a sensor which measures the distance to the surrounding obstacles and also the angle and dista... | 3 | 7,322 |
How to check if a column is empty? | <p>I'm attempting to check if each column is empty. I need it for more calculations.</p>
<p>I need to do it for nine of the columns f through n and for each I need that value as a Boolean afterwards which is why I made it the way I did based on a tutorial.</p>
<p>I'm trying to get a message that tells me if a column is... | 3 | 1,336 |
ListView (placed under fragment activity and shown via a ViewPager) doesn't show all items | <p>this is the first time posting here. So I have a screenwriting app I am creating using Java on Android. It has a simple layout as shown below.<a href="https://i.stack.imgur.com/mtZ4B.jpg" rel="nofollow noreferrer">layout of the activity</a></p>
<p>So, when user clicks write, they will be able to write their screenpl... | 3 | 9,369 |
How to do LEFT JOIN in MongoDB aggregate function? | <p>I'm trying to use the aggregate function for getting a particular value from the referenced <code>collection</code>. But it's only selecting the records when the main collection is having the field that's used for reference acting like JOIN in RDBMS as like follows,</p>
<p><code>movies</code> collection structure:<... | 3 | 2,140 |
how to dockerize a spring microservices app that uses Eureka and Cloud config | <p>i'm working in this spring microservices application, and everything works fine untill i want to dockerize the microservices. Having a little knowledge about docker i'm struggling to make it work, Here's what i've done till now:</p>
<p><strong>1.Config server</strong>
this server is a centralized server that contai... | 3 | 1,890 |
Matlab: Calling a legend in a plot which is created with an ''if'' statement | <p>I am trying to plot some functions and display a legend. My code can be found below:</p>
<pre><code>%% DATCOM spanloading method
tol = Input.tol;
iteration = 0;
difference =0;
AVL_step = 0.25;
Interp_step =0.1;
AVLruns = 3;
Angle = ((1:AVLruns)*AVL_step)+AOA;
while sum(difference < 0) <= fix(tol*Input.Sur... | 3 | 1,658 |
Cross Domain Ajax in Chrome Extensions Failing Inside Functions | <p>My extension is doing a cross-domain ajax post -- whenever I perform the function:</p>
<pre><code>$.ajax({
crossDomain: true,
type: 'post',
url: 'url/to/my.php',
data: {
"username" : $user,
"score" : $score,
"action" : "update"
},
success: function (data) {
i... | 3 | 1,047 |
JQuery form submit Question? | <p>I'm kind of new to JQuery and was wondering how can I have the following text appear when the user submits there changes <code><p>Your changes have been saved.</p></code>? How do I fix my code so it displays this message?</p>
<p>JQuery script.</p>
<pre><code>$(function() {
$(".save-button").click(func... | 3 | 1,621 |
onSharedPreferenceChanged not fired all the time | <p>I have a weird problem with this method. It's called, when i edit a EditTextPreference, only when i change the value, and on a MultiSelectListPreference only the first time i change.
This is my fragment code.</p>
<pre><code>public class PrefFragment extends PreferenceFragment implements OnSharedPreferenceChangeList... | 3 | 1,043 |
Stripe session: how to add additional data? | <p>This is my session:</p>
<pre><code>const stripe = require('stripe')(process.env.NEXT_PUBLIC_STRIPE_SECRET_KEY);
export default async function handler(req, res) {
if (req.method === 'POST') {
try {
const params = {
submit_type: 'pay',
mode: 'payment',
... | 3 | 1,436 |
Add 5 rows for each row using VBA Macros | <p>Hi All i have two worksheets from Sheet1 i am copying to Sheet2 which copy data to each row once now i want my data should be look like "To be Version" :
First column will be repeated 5 time and other column should be only once i am trying but it does not working ..</p>
<p>I am using Macros to do this</p>... | 3 | 1,493 |
How would I re add a notification request if I previously removed it from the pending requests? | <p>I have a reminder app and currently if I delete a reminder it also removes the notification if the reminder has a date or time associated with it which you can see in the LocalNotificationManager below. now I want to remove a reminder as well if the user checks off the reminder but doesn't delete it and you can see ... | 3 | 2,036 |
Retain URL in browser with Flask redirect | <p>I have a Bokeh server application deployed on Heroku, with multiple styles that result in cumbersome URLs. For example: <a href="https://invlabs-bokehserver.herokuapp.com/avyview?style=snowpacktracker" rel="nofollow noreferrer">https://invlabs-bokehserver.herokuapp.com/avyview?style=snowpacktracker</a></p>
<p>I am ... | 3 | 1,717 |
Always block with posedge triggering somehow works at time 0 | <p>I wrote a basic piece of Verilog code. </p>
<pre><code> `timescale 1ns / 1ps
module lab3_2(
input[3:0] command,
input CLK,
input mode,
output reg [7:0] total_time1,
output reg [7:0] total_time0
);
initial begin
total_time1 = 8'b00000000;
... | 3 | 1,281 |
How to properly ensure a custom UITableViewCell can be reused | <p>I have a <code>UITableViewController</code> that is rendering out a custom <code>UITableViewCell</code>'.</p>
<p>This cells are related to chat messages, as such the config is almost identical, apart from how the elements are constrained.</p>
<blockquote>
<p>bot cell is: <em>avatar > message</em></p>
<p>user cell... | 3 | 3,746 |
Quick help changing color of bar in html email signature | <p>I have a very basic issue, but my html skills are limited. I have html code for an email signature below. I am trying to change the color of the vertical bar to the same color gray as the name. I can't locate the bar. Thanks </p>
<pre><code><html>
<head>
<base target="_blank">
<style>
<... | 3 | 1,745 |
C++ - Unable to get prefixed uint16_t header | <p>Here is how I form up my message with FlatBuffers and how I send it over via Boost ASIO.</p>
<pre><code>enum ServerOpcode : uint16_t{
SMSG_AUTH_CONNECTION_RESPONSE = 0x001,
SMSG_LOGIN_REQUEST = 0x002,
SMSG_LOGIN_REQUEST_RESPONSE_TEST = 0xA9... | 3 | 1,105 |
Why can I deadlock in a single-threaded FLTK application? | <p>I have a supposedly single-threaded FLTK application with a popup menu, created with Fluid. I have a class that sub-classes Fl_Gl_Window and implements a handle() method. The handle() method calls a function that creates a popup window on right-click. I have a long operation that I do for one of the menu items. ... | 3 | 1,103 |
Checking that the conditions are correct accordingly | <p>I would like to know if the code below is properly written for generating <code>group_cols</code>. Making a brief explanation of the code I made:</p>
<p>My first <code>if()</code> is if I have any row where <code>PV$DTT == DTest & PV$Week== Wk</code>. The <code>else if</code> is when I have <code>PV$Week == Wk</... | 3 | 1,036 |
React App build failing suddenly on devops pipeline | <p>We have a react app which we build at least daily using Azure devops pipeline, which was building fine until Tuesday. The app still builds fine locally. We have had several build issues in the past which have not been related to any code change but annoyingly something has changed on the build environment (e.g. nod... | 3 | 5,789 |
Add "File" name on RibbonApplicationMenu in WPF Ribbon | <p>I am new in making WPF projects.</p>
<p>I searched on how to add Text in <code>RibbonApplicationMenu</code> maybe it looks that, there's the same questions to this in this site but trust me I implemented it but didn't works in me.</p>
<p>I've tried putting a "File" name in my <code><RibbonApplicationMen... | 3 | 3,019 |
Spark datagrid crash on sort column only in release (updated with temporary fix) | <p>Having some trouble for some time with this, wondering if some more eyes on the problem will help. </p>
<p>This is a standalone Air application for Windows/Mac</p>
<p><strong>UPDATE: I can get the release version to actually sort and not crash! If I add the compiler flag (-optimize=false) it works as intended. Now... | 3 | 3,894 |
aws ssm session - how do I set "runAsDefaultuser" to be a interactive parameter when starting a session | <p>I'm trying to create a document that I call and specific my IAM user as the user to connect with. This document will be a shared document that has a parameter "runAsDefaultuser". It will default to a user that doesn't exist. This will force me to provide an argument like,
--parameters '{"runAsDefaultU... | 3 | 1,499 |
In Coq, are there tactics for working with Rabs, Rineq? | <p>I am new to Coq, and my primary interest is in using it to do simple real analysis problems. For a first exercise, I managed to bash through a proof that x^2+2x tends to 0 as x tends to 0. See code below.</p>
<p>This seems pretty clunky, and I would be interested in any general feedback on how to shorten this pro... | 3 | 1,186 |
Change view from SKScene to a ViewController | <p>I am making a game using ARKit. Im having trouble witching to the ARSCNview from a SKSecene. </p>
<p>I have this so far:</p>
<pre><code>import Foundation
import SpriteKit
//Back button
let backToBrand = SKLabelNode(fontNamed: "Electric Boots")
class Lamborghini: SKScene {
override func didMove(to view: SKVie... | 3 | 1,041 |
requirejs() returns undefined when mixing node and amd modules | <p>I am trying to write some JS modules which should be usable in both a browser and node.js environment. </p>
<p>To facilitate this I'm writing these modules as <a href="https://github.com/amdjs/amdjs-api/wiki/AMD" rel="nofollow">AMD modules</a>, and using <a href="http://requirejs.org/docs/node.html" rel="nofollow">... | 3 | 1,418 |
Not able to add gms and FCM dependencies | <p>I'm new to android. I'm building an App that requires Map as well as FCM. So to customize markers and set latitude and langitude I'm using gms. </p>
<p>This is my app level gradle build file.</p>
<pre><code>apply plugin: 'com.android.application'
android {
compileSdkVersion 23
buildToolsVersion "21.1.2"
defaultC... | 3 | 1,157 |
MissingMethodException on domain class save in Grails 1.3.7 | <p>I'm having a problem calling the save method on a domain object. The error is: </p>
<pre><code>groovy.lang.MissingMethodException: No signature of method: static my.awesome.Class.FeedHit.save() is applicable for argument types: () values: []
Possible solutions: save(), save(java.lang.Boolean), save(java.util.Map), ... | 3 | 1,396 |
Android admob fatal exception | <p>I am trying to ad admob ads to my app but I am getting this error in the logcat when it launches. The app ran fine before I added the admob so I think it's something to do with that.</p>
<pre><code>03-16 19:08:00.683: E/AndroidRuntime(529): java.lang.RuntimeException: Unable to start activity ComponentInfo{com.musi... | 3 | 4,828 |
How to redirect CBV login_required to a specific route? | <p>I have a HomeView Class which I added a login_required, but I don't know how to redirect it with the custom login page that I made.</p>
<p>Here are the urls.py and settings.py in my project:</p>
<p>myblog\urls.py</p>
<pre><code>from django.contrib import admin
from django.urls import path,include
from .settings impo... | 3 | 1,242 |
Powerpoint layout algorithm for box-in-box view | <p>I am trying to write some code in VBA and PowerPoint to automatically create a poster (basically a box in box view) however, its proving to be a little more challenging than my skills can cope.</p>
<p>looking to get some guidance on how best to structure the code (and patterns)
at the moment:</p>
<ul>
<li>Im readin... | 3 | 4,842 |
@RunWith(MockitoJUnitRunner.class) mocks are null | <p>I am using the "RunWith(MockitoJUnitRunner.class)", the @Mock notationt to mock the service and the @InjectMocks notation to inject the mock service to the controller. I get a NullPointerException in the ChargingStationsControllerTest:40, in the "when". I debugged and realized that the mocks are ... | 3 | 2,234 |
Strange inconsistency when using ComputeSignedDistancePairClosestPoints in pydrake | <p>I'm using drake to generate a walking gait for a legged robot. To do this, I need a way to determine when it's appropriate to apply contact forces. For this I'm using ComputeSignedDistancePairClosestPoints between the claws (feet) of the robot and a box which I'm using as the floor (world body):</p>
<pre><code># Rel... | 3 | 24,629 |
Wordpress custom wp-cron class doesn't firing the scheduled handler | <p>So, we use the Bedrock to help to code our products and I need to build a generic class to handle custom cronjobs.</p>
<p>This is the base cronjob class:</p>
<pre><code><?php
namespace namespace\to\the\class;
abstract class CronHelper extends AbstractHelper {
/** Declare all attributes and other methods *... | 3 | 1,028 |
Standalone Wamp server ssl auth setup | <p>Want to setup a portable server from Apache, PHP and MySQL, all of them from the newest binary.</p>
<p>Downloaded and configured each other, but have 2 issue, which i think is only one.
First:
I set the loglevel to Info in httpd.conf, and started the server.
Error.log contains:</p>
<pre><code>[Sat Aug 25 17:32:35.... | 3 | 5,128 |
Refreshing or Updating row with corresponding button click in Angular4 | <p>I have this code to render details from <em>json</em> to my component:</p>
<pre><code><tr *ngFor="let wall of userWall">
<td *ngFor="let item of keys" [hidden]="!item.visible" [ngStyle]="{'text-align':'left'}">
<span *ngIf="item.fieldName=='walladdress' && wall[ item.fieldName]!='... | 3 | 1,029 |
Visual Studio crashes - Newtonsoft.json Bower error | <p>I am using VS Community 2015, but when I try to open a project using bower (containing bower.json), VS crashes. The event log error and bower.json code is shown below. When I rename bower.json, the project will open and run just fine. The same bower.json file works fine on other computers.</p>
<p>I have already uni... | 3 | 2,081 |
Using OnItemClickListener on CheckBoxes in ListView with Adapter | <p>I have a row which is represented by an image, some text and a CheckBoxes. Whenever I'm trying to use the OnItemClickListener for the rows, the event won't fire up when clicking the CheckBoxes. </p>
<p>I also tried checkbox.onCheckedChangedListener but it gives me Null Pointer at findViewByID. I checked, the ID I a... | 3 | 3,122 |
Removing text field created with a SpringLayout | <p>I'm using the code from the example on the official page of Oracle. The one for sorting and filtering table data. In the original variant it has two fields - one for entering a filtering criteria and second for showing which row from the grid is selected. I don't need the second one, want to leave just the filter fi... | 3 | 1,692 |
HTML table wont removing padding | <p>I am creating a calendar using a HTML table. I have a problem where each <strong>td</strong> element has a padding in it which I want to remove.</p>
<p><strong>Can you help me so that the link(& the img & text) inside the td element extend the whole width of the td element so you cannot see any of the backg... | 3 | 3,142 |
Matlab's GlobalSearch function : error message and can't start the searching for minimum | <p>I have a system of matricial equations where I want to find 2 matrices of 7x7 (so I am working with (1x98) vectors).</p>
<p>I have an issue when I want to use <a href="https://fr.mathworks.com/help/gads/globalsearch.html" rel="nofollow noreferrer">GlobalSearch</a> Matlab function. Here my code :</p>
<pre><code>Eq1 =... | 3 | 1,779 |
How to store some data in array from another json data? | <p>I want to store only renewal dates from given array, is there any way to store renewal dates in another array . I tried</p>
<pre class="lang-js prettyprint-override"><code> const rnDates = [res.result.renewals.renewal_date];
this.setState({rn_dates:rnDates}).
</code></pre>
<p>But it shows undefined. If anyon... | 3 | 2,540 |
Row within a row with JSON | <p>I have a webpage where it shows the lists of Projects and the monitoring of its progress/finances for every quarter. As shown below:</p>
<p><a href="https://i.stack.imgur.com/uNqjg.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/uNqjg.png" alt="Figure One"></a></p>
<p>As you can see, my table is... | 3 | 1,247 |
Rails putting JSON Data into HTML table | <p>Sorry this could be a real newbie question, but in my Rails 5 app I am trying to parse some JSON and display it into my view as a HTML table. I tried using <a href="https://datatables.net/" rel="nofollow noreferrer">https://datatables.net/</a> but couldn't get it to work, might be worth another post.</p>
<p>So I t... | 3 | 1,297 |
Updating map polygons and map legend with selected color option from dropdown menu? | <p>I am a rookie programmer trying to make an interactive map with d3. So far, I have been able to update the colors of the polygons in the SVG choropleth (quantile) map by selecting a Colorbrewer CSS color scheme from a dropdown menu. </p>
<pre><code>d3.select("select#ColorSelection")
.on("keyup", function() {d... | 3 | 1,280 |
My list from JSON not showing on listview in mobile application, why? | <p>This is my code. What can I change?</p>
<p>Notification fragment</p>
<pre><code>public class NotificationsFragment extends Fragment {
private ArrayList<String> arrayList;
private ListView listView;
private RequestQueue queue;
private ArrayAdapter arrayAdapter;
private List<Earthquake>... | 3 | 2,449 |
Notification not vibrating or showing the light | <p>I'm using Visual Studio 2019 16.6.0 Preview 2.1 and I'm trying to get vibrate and the light to work on the Galaxy S10 (Android 10) I'm testing my app on. I get the notification, but the phone doesn't vibrate and the light doesn't come on. I'd also like to have a sound as well, but nothing I've tried on here compli... | 3 | 6,326 |
Increasing angle of rotation around center with sin and cos Canvas Js | <p>Hy everyone,
i'm making some little exercices in canvas with sin and cos. I can now make a point rotating around another one with the angle incrementation in the animate function it work, like in the code below. My purpose is to put angle incrementation in the update function of the Class viefinder</p>
<p><div class... | 3 | 2,203 |
jQuery Ajax request in Sharepoint 2007 (SOAP) | <p>I have the following web service:</p>
<pre><code>SOAP 1.1
The following is a sample SOAP 1.1 request and response. The placeholders shown need to be replaced with actual values.
POST /_vti_bin/QuickLinks.asmx HTTP/1.1
Host: myintracomm-design.ec.europa.eu
Content-Type: text/xml; charset=utf-8
Content-Length: leng... | 3 | 1,478 |
App Store Rejection: Unable to reproduce crash | <p>The App Store Review-Team finally took a look at my new application.
Sadly they found a crash in a key functionality which i can't reproduce. </p>
<p>They are using an Retina-iPad, which i don't have, but the application has been successfully tested on a Retina-iPad, so i guess this is not the cause of the crash. ... | 3 | 12,816 |
Trying to accomplish without dynamic SQL (sql server) | <p>All,</p>
<p>I'm trying to pull off an insert from one table to another without using dynamic sql. However, the only solutions I'm coming up with at the moment use dynamic sql. It's been tricky to search for any similar scenarios. </p>
<p>Here are the details:</p>
<p>My starting point is the following legacy table... | 3 | 2,340 |
Ruby Net::SSH get Exit Status in PTY | <p>I'm trying to write in some functionality into the Net::SSH::Telnet Library for a project of mine. Specifically I need to be able to read the exit-status of any command that I write.</p>
<p>Here's the Original source from the Net::SSH::Telnet Library that I'm modifying</p>
<pre><code>@buf = ""
@eof = false
@chann... | 3 | 1,063 |
How to graph these three columns of data with two y-axis in R? | <p>I have data:</p>
<p>structure(list(Group.1 = structure(c(17897, 17928, 17956, 17987,
18017, 18048, 18078, 18109, 18140, 18170, 18201, 18231, 18262,
18293, 18322, 18353, 18383, 18414, 18444, 18475, 18506, 18536,
18567, 18597), class = "Date"), w_VidP = c(92.5925925925926,
95.0391644908616, 91.2820512820513,... | 3 | 1,418 |
How to store image width as a number in a variable with xsl | <p>I'm trying to store an image width as a number so I can add a class value to the figure wrapper so I can control the image placement with css, (small, medium, or large image).</p>
<p>This is my xml example:</p>
<pre><code><?xml version="1.0" encoding="UTF-8"?>
<root>
<section>
<fig... | 3 | 1,471 |
Close UIView when UIButton is tapped | <p>In my app I have a Horizontal Image Gallery wherein when I tap the image, <code>UIView</code> is called displaying enlarged images. The <code>UIView</code> contains, a <code>scrollView</code>, <code>imageviews</code> (dynamically created) and a <code>UIButton</code> (close button) programmatically created. However, ... | 3 | 1,804 |
my text is arabic. and text separate in column to half above another half . and go on the next row text and take foreground of next column text | <p>my text is arabic. and text separate in column to half above another half . and go on the next row text and take foreground of next column text i am just start programming a week so please explain simple sorry for bad English </p>
<pre><code>enter code here
<LinearLayout
android:layout_width="match_parent"... | 3 | 3,352 |
Why do I receive key release event when key release is not in event mask. (xcb) | <p>I am making a simple xcb application and I noticed that when <code>XCB_EVENT_MASK_KEY_PRESS</code> is in the event mask and <code>XCB_EVENT_MASK_KEY_RELEASE</code> is not in the event mask I still get <code>XCB_KEY_RELEASE</code> events in my event loop if I hold down a key so that it repeats the key press event. Su... | 3 | 1,257 |
Problems sorting a list of data in ASP.net MVC3 | <p>I am trying to implemeny the sorting functionality thats shown in the Entity Framework tutorials on the the Asp.net MVC Site, here</p>
<p><a href="http://www.asp.net/entity-framework/tutorials/sorting-filtering-and-paging-with-the-entity-framework-in-an-asp-net-mvc-application" rel="nofollow">http://www.asp.net/ent... | 3 | 1,104 |
ffmpeg how to shorten volume range | <p>I use this command below to get volume information</p>
<pre><code>ffmpeg -i {fileName} -af "volumedetect" -f null -
</code></pre>
<p>and get result below:</p>
<pre><code>[Parsed_volumedetect_0 @ 000001b4f9675ec0] mean_volume: -25.1 dB
[Parsed_volumedetect_0 @ 000001b4f9675ec0] max_volume: -4.0 dB
[Parsed_... | 3 | 1,092 |
Is there a way to use NumberFormat() formatter (Google Charts) in vue-google-charts vue.js wrapper | <p>I have been tasked with formatting some columns in charts using vue-google-charts, a vue.js wrapper for Google Charts and I am not sure that 'NumberFormat()' is even supported in vue-google-charts.</p>
<p>First, if somebody knows if it is or isn't, I would like to know so I don't waste much time pursuing something ... | 3 | 2,581 |
Integer not being updated properly | <p>I have a fairly long javascript file below, but it's not important to understand the entire file, only the 'totalItemCount' variable and how it is updated. This code uses the Igloo API to recursively count the number of files within a directory (and that count is stored in the totalItemCount var). I have never used ... | 3 | 2,065 |
Need help dealing with spacing issue in MaterialUI Dialog Content | <p>Im trying to have a summary page and using a MUI Dialog to acheive this.</p>
<p>This is the dialog I have:
<img src="https://i.stack.imgur.com/erhVo.png" alt="This" /></p>
<p>But I am trying to make the two sides line up at the top instead of there being space above "Title 2". It seems that the Typographys... | 3 | 1,351 |
Google Pie chart not displaying in IE <= 8 | <p>I need to execute this .php file for different IE versions but the following errors appear when I emulate to:</p>
<ul>
<li>IE 8:"gvjs_VL" is undefined.</li>
<li>IE <8: "JSON" is undefined.</li>
</ul>
<p>I have tried also to use json2 when the IE version was <= 8 but it did not solve the issue.
What could be... | 3 | 1,181 |
In PYTHON how do I associate values in dataframes to pass them both to a SQL update? | <p>Use Case:
Project team emails the DBAs an excel with a list of hundreds of usernames that need to be updated for a system in an oracle db. The dba should be able to run a python script that automates the process of importing the data from the excel, connecting to the db and updating the table.</p>
<p>My Idea:
Use p... | 3 | 1,668 |
Elasticseach bulk load strangely missing 1 of 3 documents | <p>I'm running into strange problems following the shingles example at <a href="https://www.elastic.co/guide/en/elasticsearch/guide/current/shingles.html" rel="nofollow noreferrer">https://www.elastic.co/guide/en/elasticsearch/guide/current/shingles.html</a></p>
<p>When I try to index the three documents on that tutor... | 3 | 1,615 |
MYSQL Advanced select distinct values with corresponding ID which are not in anothe table | <p>EDITED:</p>
<p>I have a huge problem with <code>SELECT</code> <code>DISTINCT</code> values from one of my table.</p>
<p>Table 1 :<code>T1</code></p>
<pre><code>pid thing sub-thing tnumber
-------------------------------------------
1 A1212 A01A00001 123456
2 A1212 ... | 3 | 1,069 |
Create DataGridRowsDetails in code behind WPF | <p>i'm working on a new program that will show information about Test on some Tools in my factory.
For doing that i'm creating a DataGrid Control at run time and populate it.This part is working very well.</p>
<p>My problem is to add RowDetails, How can i do that in code behind? </p>
<pre><code>if (datatable.Rows.Cou... | 3 | 3,662 |
Sending mail large attachment - ZF2 | <p>i just ran into a problem, when sending mails with attachments larger than about 2.5Mb from a server. Sending emails with smaller attachments work, but as soon the critical size of about 2 or 2.5Mb is reached, the mail is not send anymore.</p>
<p>The PDF files and merged target PDF are created without problem, no m... | 3 | 1,285 |
Flutter Container remove (bottom) border completely | <p>How do I remove the tiny part of the border beneath the "Choose Path" part ?
Tried to remove the border completely but it didn't work and giving it the width of 0.0 didn't do the trick</p>
<pre><code>Container(
width: double.maxFinite,
child: ClipRRect(
... | 3 | 1,248 |
What's the best way to fuzzy join (multiple) dataframes by multiple columns? | <p>I need to join multiple data frames, but given that the experiment ran online and participants were often sloppy when entering their ID, I added redundancy. The also had to add letters of their parents name and their zip code. I checked manually (a bit) and there's a good amount of errors. Now I need to merge by mul... | 3 | 1,337 |
Can geom_text in gg_tree be coded to not stagger the distance from the nodes? | <p>I have aligned some amino acid sequences in R and imported the distance matrix (dist_mat) for use in ggtree using <code>tree <- ape::nj(dist_mat)</code>. It looks something like this:</p>
<pre><code> node parent branch.length x y label isTip branch angle
1 1 14 0.0000000... | 3 | 3,309 |
LZ4 not compressing data (JavaBindings - org.lwjgl.lz4) | <p>I am using a Java-Binding for the popular LZ4 compression library, in my case <em>org.lwjgl.lz4</em> with the intend of compressing and managing a variety assets that way. I have working compression and de-compression of my custom format, verified by tests, which is basically able to:</p>
<ul>
<li>to put a bunch of ... | 3 | 1,153 |
python program Remove duplicate string with sequence of number without using pandas DataFrame | <p><strong>Replace a csv file duplicated string with sequence of numbers WITHOUT using PANDAS DATAFRAME</strong> </p>
<blockquote>
<p>python
I have a csv file that contain 4 column i want to replace a string of all the column with a sequence of number if any duplicate will be there then it should give the prevoius... | 3 | 3,259 |
How to get data automatically from MySQL to Android without clicking a button? | <p>I want the result of a barcode scan to automatically get data from MySQL without clicking a button again.</p>
<p>This is my code for the button being clicked to get the data from MySQL. How do I get the same data without clicking the button again?</p>
<pre><code>public class EditPerangkat extends AppCompatActivity... | 3 | 1,106 |
Unable to retrieve DBMS_ALERT for a C# application | <p>I am trying to use <code>DBMS_ALERT</code> to provide feedback to a C# application from an Oracle 11g database. In testing the stored procedures in the oracle tool TOAD, I am unable to retrieve any alerts.</p>
<p>I'll show the stored procedures that I have written.</p>
<p>My reason for doing this is to provide fe... | 3 | 1,522 |
Alternative Way to Pass Checkbox Array to $_GET - Besides Square Braces | <p>I understand that if I use a checkbox value of name[], then I will receive a data array on the server (when using PHP), named 'name[]'. This has worked fine for me, but I'm running into some URL sizes that could cause issues with less robust IE browsers and all the encoded square braces are killing me in this area, ... | 3 | 1,070 |
Is it possible to schedule Kivy StringProperty set() method using Clock? | <p>I would like to delay Kivy screen manager transition, which I can do for example like this:</p>
<pre><code>#!/usr/bin/env python
from kivy.app import App
from kivy.lang import Builder
from kivy.uix.floatlayout import FloatLayout
from kivy.properties import StringProperty
from kivy.uix.button import Button
from kiv... | 3 | 1,486 |
Getting Wrong position of RecyclerView Item in next Fragment after applying SearchFilter and OnClick on RecyclerView Item | <p>I have set <code>RecyclerView</code> on Fragment.I have set <code>OnClick</code> listener for RecyclerView item from RecyclerView Adapter.I get Filtered item using <code>SearchFilter</code>.After onClick of RecyclerView Item I need to get the Item Position and pass in Bundles to Next Fragment.But I am getting wrong ... | 3 | 1,639 |
How to flip the text inside the div tag? | <p><div class="snippet" data-lang="js" data-hide="false">
<div class="snippet-code">
<pre class="snippet-code-css lang-css prettyprint-override"><code>.hot-deals-row{
margin-top: 30px;
background: #eaeaea;
}
.hot-deals-box{
border: 1px solid #eaeaea;
}
.hot-deals-box .hot-deals-tab {
display: table;
width: 10... | 3 | 4,311 |
Better way to refactor $scope operations like this in AngularJS? | <p>My coffeescript codes looks like this</p>
<pre><code>.controller('SignInController',
($scope, CONFIG, restAuth, cookieAuth) ->
$scope.signInData = {}
$scope.res = {}
# TODO: Refactor this to service
$scope.processRegistration = ->
console.log($scope.signInData)... | 3 | 1,055 |
Combine 2 ajax calls into 1 callback | <p>I'm building a Chrome extension and I need to combine 2 separate AJAX calls so that I have 1 callback on success. What is the best way to do that?</p>
<pre><code>Auth.prototype.updateContact = function(id, contact_obj) {
var self = this,
contact_str = JSON.stringify(contact_obj);
return new RSVP.Promise(... | 3 | 1,486 |
how to save data to database from JCombobox and JTextarea in eclipse juno | <p>I'm using eclipse Juno to write my code. I would like to input my data to database but when I click the save button I got error on JTextarea and JCombobox.</p>
<p>Here's the error:</p>
<blockquote>
<p>Cannot refer to a non-final variable textALAMAT inside an inner class
defined in a different method Cannot ref... | 3 | 1,742 |
When set value to the tablecell's elements, it will crashed | <p>I want a tableview to show my car's status, it only have 7 cells. And the value is get through the network.When I get the value, and set the cell's label text, it will crash. </p>
<h3>This is my Table View Controller code</h3>
<pre><code>@interface CarStatusController ()
@end
@implementation CarStatusController
... | 3 | 4,415 |
Property 'take' does not exist on type 'AngularFireObject<unknown>'.ts | <p>Property 'take' does not exist on type 'AngularFireObject'.ts</p>
<p>I have this error in my code at 4 places in the Ionic app I am working on and I can't find a way to resolve it, even after looking on-line and trying myself. Seems to be no information about the take() method about what it does or did. I just can... | 3 | 7,059 |
Amcharts guides | <p>When I add the <code>guides</code> into <code>valueAxesSettings</code> but it doesn't work even I choose <code>valueAxesSettings</code> into <code>valueAxes</code>.
Furthermore, what the difference between <code>valueAxesSettings</code> and <code>valueAxes</code>, as the reference said <code>If you change a propert... | 3 | 2,915 |
C# - Variable values changes after it's executed | <p>Can someone help me with this code?</p>
<p>EDIT: <strong>Path is 2 points that form the last straight last line.</strong></p>
<p>Basically I want to draw BLUE the last <code>profundidadePinca</code> {0 to profundidadePinca} if the path is bigger than it's value and the rest <code>TubeConfig.OutsideColor</code> . O... | 3 | 1,124 |
Python package setup: setup.py with customisation to handle wrapped fortran | <p>I have a python package i would like to distribute. I have the package set-up and am able to download the tarball, unzip and install it using:</p>
<pre><code>python setup.py install
</code></pre>
<p>which works fine.</p>
<p>I would also like to upload the package to PyPi, and enable it to be installed using pip.<... | 3 | 2,073 |
Back button not working after displaying Contact | <p>I am playing with the "Clickable List Items" code from Pro Android 4. The code is basically:</p>
<pre><code>public class MainActivity extends ListActivity implements OnItemClickListener
{
@Override
public void onCreate(Bundle savedInstanceState)
{
super.onCreate(savedInstanceState);
Cur... | 3 | 1,098 |
Problem with CSS column-count and first element | <p>I've this masonry CSS layout make with CSS column-count:</p>
<pre><code>.container-post{
column-gap: 20px;
margin: 0 auto;
column-count: 2;
}
.box-article {
display: inline-block;
background: #ffffff;
padding: 20px;
margin: 0 0 15px;
width: 100%;
box-sizing: border-box;
border: solid 1px gray;
}
.box-articl... | 3 | 1,143 |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.