title
stringlengths
13
150
body
stringlengths
749
64.2k
label
int64
0
3
token_count
int64
1.02k
28.5k
How to work a setOnEditorActionListener in a BottomSheet called from a Fragment?
<p>I'm currently developing an application using android-studio with Kotlin.</p> <p>I want to use my function when a <code>setOnEditorActionListener</code> in a <code>BottomSheet</code> called from a <code>Fragment</code> fires.</p> <p>But in my code <code>setOnEditorActionListener</code> doesn't fire.</p> <p>*I want t...
3
4,321
How can i change icons from SVG to IMG?
<p>Can someone help me to change ICONS from SVG to an PNG image or link ?</p> <p>I have this code here :</p> <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false"> <div class="snippet-code"> <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;?php if ($wo[...
3
6,598
media query for scrolling slideshow for display on different size devices
<p>I want to create a media query for a scrolling slideshow so that the images display at their native resolution of 960x540 px on a 1920x1080 monitor; but at 768x432 on a 1366x768 monitor. I tried plugging in the recomputed values of the keyframes for the smaller screen in the media query but it did not work. </p> ...
3
3,422
sqlite error in database
<p>This is my code for connection manager class</p> <pre><code>public class ConnectionFactory { Connection con = null; Statement stmt = null; ResultSet rs = null; boolean flag=false; //Constructor starts public ConnectionFactory(){ try{ Class.forName("org.sqlite.JDBC"); con=DriverManager.get...
3
2,746
type object 'StudentPerformance' has no attribute 'objects'
<p>Here is my code models.py</p> <pre><code>class StudentPerformance(models.Model): student_activity=models.ForeignKey(StudentsActivity,db_index=True) student_subactivity=models.ForeignKey(StudentSubactivity,db_index=True) student_detail=models.ForeignKey(StudentDetail,db_index=True) grade_section=mode...
3
1,105
the logic of pushing up and sorting a data list
<p>I have 100 rows of textarea(s) that a user may add information to (not in any particular order) the textareas look like this:</p> <pre><code>var item='&lt;textarea class="itemv"id="k'+k+'"rows="1"style="width:100%;border:none;border-bottom:1px solid #CCC;outline:none;resize:none;background:none;font-weight:bold;"&g...
3
1,426
How to Get Matching records from both F1 & F2 in output file1 and Non-Matching Records from F2 in output File 2 using Sort
<p>Hi I am trying to Find Matching and Un Matching records from 2 file, one file is a Error file with 181 LRECL, second file F2 is valid records file with same 181 LRECL.</p> <p>Example ERROR File</p> <pre><code>12345678901 11111111111 11111111111 22222222222 </code></pre> <p>VALID File has</p> <pre><code>33333333333 1...
3
1,383
ActiveJob perform_later from inside Redis subscription block
<p>I want to use the ruby redis client to subscribe to a channel. When subscription was successful I want to start an ActiveJob (Sidekiq is used) job using <code>perform_later</code>. This Job will then do some work and produce a result which will be published to the <code>channel</code> Redis channel. This produces th...
3
2,132
Is there anything wrong with this Google App Engine url-fetching code that I have here?
<p>When I view the source of the page in my browser (FireFox) (View->Page Source), copy it and paste it into my HTML editor, I view almost the same page (In this example it is www.google.com) as it appears in my browser. But when I get the HTML source through this code (through Googles App Engines)</p> <pre><code>from...
3
1,124
Modal Not Functioning
<p>I am trying to add a modal to my website, yet such section is not functioning. The Id and data target have the same name while the scripts are assigned on the bottom side of the body section. What is exactly wrong, please?</p> <p>Below is the code </p> <p><div class="snippet" data-lang="js" data-hide="false" data-...
3
1,889
Why is filteredList empty even though I update it in the thread?
<p>I am performing a background operation in a background thread in android, like so: </p> <pre><code>switch (position) { final List&lt;Profile&gt; filteredList = new ArrayList&lt;&gt;(0); case BELATED: Runnable belatedRunnable = new Runnable() { @Override publi...
3
1,208
Fatal error of "failed to become active master" while running hbase in cluster mode
<p>I have 4 nodes, one master and 3 slaves.</p> <p>master: * .* .*.18, slaves: * .*. *.12, 104, 36.</p> <p>Configurations for Hadoop on Namenode:</p> <p>core-site.xml:</p> <pre><code>&lt;configuration&gt; &lt;property&gt; &lt;name&gt;fs.defaultFS&lt;/name&gt; &lt;value&gt;hdfs://localhost:9000&lt;/value&gt;...
3
4,912
RavenDb - Write query and select item where it's propertyName equals a string
<p>Is it possible to write a query and select an item where its <code>propertyName</code> equals a string?</p> <p>I want to pass in a string to a method, where my string holds the value of a <code>propertyName</code>. And then use it in a query to select my property that equals that string. Is this possible?</p> <p>I...
3
1,379
debugging old fortran code
<p>I have an old Fortran code for calculation of Lyapunov exponent which I tried converting to modern Fortran syntax.</p> <pre><code>PROGRAM ODE integer, PARAMETER :: N=3 integer, PARAMETER :: NN=12 EXTERNAL FCN DIMENSION Y(NN),ZNORM(N),GSC(N),CUM(N),C(24),W(NN,9) Y(1) = 10.0 Y(2) = 1.0 Y(3) = 0.0 ! INITIAL CO...
3
1,607
C code inside a loop not being executed
<p>Background: the overall program is designed to carry out 2D DIC between a refference image and 1800 target images, (for tomographic reconstruction) In my code, there is this for loop block </p> <pre><code>for (k=0; k&lt;kmax; k++) { K=nm12+(k*(h-n+1))/(kmax-1); printf("\nk=%d\nL= ", K); for (l=0; l&lt;l...
3
1,492
Entity Framework 6 updates all records with data of the one getting updated
<p>I am trying to implement entity framework 6 in my application, but I have a problem performing updates on the records.</p> <p>If I have 2 records in the database, lets say:</p> <div class="s-table-container"> <table class="s-table"> <thead> <tr> <th>Id</th> <th>Name</th> <th>Lastname</th> </tr> </thead> <tbody> <tr>...
3
3,143
conn.onmessage function not working in PHP
<p>I am working with websocket(Ratchet) with Php(Codeigniter),My &quot;conn.onmessage&quot; function is not working for me,&quot;conn.onopen&quot; function is working but unable to get response(message) Here is my code,Where i am wrong ? Thanks in advance.</p> <pre><code>&lt;div id=&quot;container&quot;&gt; &lt;d...
3
1,211
How to test express + dynamodb using Jest?
<p>I am new to Jest and unit testing, I have an express API deployed on serverless(Lambda) on AWS.Express api uses dynamodb for crud operations</p> <p><strong>Note:- my api is based out of express and not just plain node, because on <a href="https://jestjs.io/docs/dynamodb" rel="nofollow noreferrer">jest website</a> th...
3
1,420
Parse Cloud Code modifying variables
<p>I'm working on Microsoft Translator integration into Parse's Cloud Code. I can successfully obtain access token - example:</p> <pre><code>http%253a%252f%252fschemas.xmlsoap.org%252fws%252f2005%252f05%252fidentity%252fclaims%252fnameidentifier%3Dcapital-dev%26http%253a%252f%252fschemas.microsoft.com%252faccesscontro...
3
1,156
Android Service Losing an ArrayList
<p>Edit: <a href="http://pastebin.com/YqBcQDvU" rel="nofollow">here's</a> the source on PasteBin. I feel like I might need to just redesign the entire Service.. :(</p> <p>I'm the developer of <a href="https://market.android.com/details?id=com.cryclops.ringpack&amp;feature=search_result" rel="nofollow">RingPack</a>. Th...
3
2,134
Data Studio inconsistent in summing metrics?
<p>I've come across what appear to be random inconsistencies in how Data Studio is aggregating data from the same Analytics source. I can't tell if it's an issue on the software's end, or a result of my incorrectly summing and joining the data in question (or possibly misunderstanding how the aggregation is supposed to...
3
6,937
Exporting XML header and doctype to XML file
<p>I want to use a java script for my bachelor thesis that uses XML files as input. Since most of my other work was done in python, i want to create a bridge between the two programs by opening the XML file in python and changing some class attribute values to previously calculated results from my python code. Then i w...
3
1,219
Trying a different approach for Projet Euler Problem 8
<p>So I'm new to Java and I'm trying a different solution for <a href="https://projecteuler.net/problem=8" rel="nofollow noreferrer">Project Euler Problem 8</a>. In this I have used <code>BigInteger</code> class datatype to store the 1000-digit number but I'm not able to traverse the particular values at any index or ...
3
1,340
Why does my navigation bar disappear when scrolling?
<p>This is the website I'm currently have to work with: <a href="https://www.mpc.gov.my/home" rel="nofollow noreferrer">https://www.mpc.gov.my/home</a>. Everything seems fine when you view using a desktop or big screen, but when you try to browse it using a mobile/smaller screen the navigation menu is giving the user a...
3
10,144
PostgreSQL 9.6 query run more than 24 hours in nested loop
<p>I have a query that I run in my PostgreSQL 9.6 database and it runs for more than 24 hours and doesn't finish.</p> <p>My select consist from few joins :</p> <pre><code>SELECT a.inst_prod_id, product_id, nap_area2, nap_phone_num, nap_product_id, b.nap_makat_cd, b.nap_discount...
3
3,431
OpenGl with http://www.arcsynthesis.org/gltut/ tutorials
<p>I have downloaded tutorial 0.3.8 from <a href="http://www.arcsynthesis.org/gltut/" rel="nofollow">http://www.arcsynthesis.org/gltut/</a> then according to instruction I have build visual studio 2010 files by premake4.exe. But when I'm trying to debug project console shows for a second and in output shows:</p> <pre>...
3
1,257
htm form to disappear after submission
<p>I am a bit new to coding. I have made a HTML form which is posting to one website after submission and is also landing on the other page for acknowledgement. but my form page is not disappearing. i am using google sites for this form so cant use any scripting language. Have to rely on html only</p> <pre><code>&lt;f...
3
1,803
Display texts of a checkbox on AlertDialogue
<p>I want to display the text on the AlertDialogue (e.g. "Sports") from a checkbox when it is checked, along with the name, email and date of birth message. When the name and email and date is set, An AlertDialogue shows what i have typed in or set. I want it to show also which checkbox's i have checked</p> <p><div cl...
3
4,007
Inserting HTML Table Row "Heading" Based On Dynamic Visible Element Data Attribute
<p>Let's say I have a table containing rows which contain a table cell having a data-time attribute and may or may not be visible (ie. display: none). This visibility is dynamic and at any point a row may change.</p> <p>Only the first of three table cell in these rows contains a data-time attribute.</p> <p>The table ...
3
1,397
Add conditions to the general slider js
<p>I have the same slider on my site on two pages, for which one common <code>js</code> file is used</p> <pre><code> // Slider const slider = document.getElementById('generalSlider'); const sliderRow = document.getElementById('generalSliderRow'); const slides = document.querySelectorAll('.general'); const INTERVAL ...
3
3,414
Sorting Plotly bar chart data overlaid on candlestick chart
<p>I am overlaying a barchart on a candlestick plot, all data is referenced from the same data frame. I want to sort the data ascending from the bar chart data but cannot find any guide to help with an overlay. Has anyone gotten this to work? I've attached the current output but want the grey bars sorted.</p> <pre><co...
3
2,317
Django Carton App - Getting Ajax Working
<p>I am using the Django Carton shopping cart add on and have got it working. I am now trying to add to cart via an ajax call and struggling to get the code working. I get an error which says "TypeError at /api/cart/↵Object of type 'property' is not JSON serializable" (on the Chrome Console).</p> <p>Views.py</p> <pre...
3
2,985
Hover transform scale issue on Chrome
<p>I showed my problem on <a href="http://youtu.be/UQ7gwPmbRz8" rel="nofollow">this film</a> and the browser is Chrome (v. 44.0.2403.107 m). The background image should scale up and down after mouse hover and left. But sometimes Chrome skips animation giving this rough movements. I tested it also on IE, Mozilla, Opera ...
3
1,261
C++ Blocking Queue Segfault w/ Boost
<p>I had a need for a Blocking Queue in C++ with timeout-capable <code>offer()</code>. The queue is intended for <strong>multiple producers, one consumer</strong>. Back when I was implementing, I didn't find any good existing queues that fit this need, so I coded it myself.</p> <p>I'm seeing segfaults come out of the ...
3
1,358
Native Image - Spring Boot - AWS Serverless Java Container - startup error - missing ServletWebServerFactory bean
<p>I am trying to create a native image for my Spring Boot application that also uses the AWS serverless Java container.</p> <p>The Spring Boot app is a simple petstore application.</p> <pre><code>&lt;dependencies&gt; &lt;dependency&gt; &lt;groupId&gt;org.springframework.boot&lt;/groupId&gt; &lt;art...
3
4,906
Smooth scale animation in ffmpeg
<p>How can I smooth the animations of scale?</p> <pre><code>ffmpeg -i bg.mp4 -loop 1 -i blank.png -filter_complex "[1:v]drawtext=fontfile=ariblk.ttf:text=EXAMPLE:x=(main_w-text_w)/2:y=(main_h-max_glyph_a)/2:fontcolor=0xFFFFFF:fontsize=200:alpha=1[txt];[txt]sendcmd=f=data.cmd,scale=w=0:h=-1[txtscale];[0:v][txtscale]ove...
3
1,934
"www.googleapis.com" response recently changed
<p>Request with the following URL. *Replace "domain.com" with your gsuite domain.</p> <pre><code>https://www.googleapis.com/admin/directory/v1/groups/ac-c.ou_n-t_16f30a06336@domain.com/members?fields=members/type,members/email,members/role,nextPageToken&amp;maxResults=200&amp;prettyPrint=false&amp;roles=OWNER https://...
3
1,557
Unable to load requested class CSSMin in the Production Server
<pre><code>ubuntu@ip-10-0-0-116:/var/www$ grep -ri cssmin . ./projectapp/public_html/application/logs/log-2016-09-20.php:ERROR - 2016-09-20 06:19:15 --&gt; Unable to load the requested class: Cssmin ./projectapp/public_html/application/logs/log-2016-09-20.php:ERROR - 2016-09-20 06:19:31 --&gt; Unable to load the reques...
3
1,326
Why is my notebook in tkinter not fully visible within a frame whereas it expands correctly outside?
<p>Here is my problem: I'm writing a GUI in python with tkinter and of course without being an expert the more complex it becomes, the more stange problems I find. So Here I am. The small script bellow is a part of my main app and still generate my problem. I've several sub-frames in a main containing frame. In the fi...
3
1,695
Working with payment
<p>I have a dilema, quite a big one.</p> <p>I am working stripe as my payment gateway and it works in a 2 way process.</p> <ol> <li>Collect billing info which generated a token</li> <li>charge the client using token</li> </ol> <p>problem is that token can only be used once and on step 1 i am unable to verify if clie...
3
1,087
How to present a CardView when FAB is touched
<p>I have a fragment that gets a list of students vocabulary words from my server using Volley. The list of words is displayed in a RecyclerView with a FAB on top. How can I wire up my FAB so that when it is pressed a CardView will be displayed like a pop up over the RecylerView. The purpose of this is to use that Card...
3
1,192
Complex RANK in SQL
<p>I have a complex query which is really over the top of my head. I think RANK of the RANK-ing is needed, but there must be a better, and an existing way.</p> <p>Here I have a simpe table:</p> <pre><code>Manufacturer DateOF Status Prefer Dell 05-2014 ComputerInstalled 30 Dell ...
3
2,626
Migrating a PostgreSQL stored proc to MYSQL
<p>I have the following PostgreSQL which I want to re-write to make it compatible for MySQL stored function.</p> <pre><code>CREATE OR REPLACE FUNCTION test.yearly_demand_function(IN paramstartdate date, OUT network character varying, ...
3
2,595
Boost Graph Library - crash in topological_sort with remove_vertex
<p>The following piece of code crashes in topological_sort with what appears to be corruption. Can anyone spot something in the code that could be causing this ? Or is it triggering a bug in BGL ?</p> <pre><code>#include &lt;boost/graph/graph_traits.hpp&gt; #include &lt;boost/g...
3
3,611
jQuery - selector inside another selector - passed in variable loses its value and becomes an indexer?
<p>I'm somewhat new to jQuery and am just wondering how I go about passing in a string value rather than what appears to be a reference to a jQuery item from a selector? I'm having a hard time explaining so here's a sample demo. Don't even know what to title this so please have at editing the title if you can think o...
3
1,266
Issue updating the state in react
<p>In my Login component, I am trying to validate the user input and set the errors using React state, but I am facing issue updating the <code>errorState</code>.</p> <p>Here's my Login component</p> <pre class="lang-js prettyprint-override"><code>const Login = () =&gt; { const [state, setState] = React.useState({e...
3
2,073
Display raster over shapefile in shiny R
<p>I am trying to display a raster over my shapefile in my shiny app. Here's my approach. </p> <pre><code># Load libraries and create sample data library(raster) library(shiny) library(dplyr) library(leaflet) library(ggplot2) library(ggthemes) library(tmap) fr.shp &lt;- getData('GADM', country='FRA'...
3
1,540
Inserting row in QTableView
<p>I have a PostgreSQL parent table called 'rooms' and a related table called 'configurations'. I have a form which would allow the user to add edit and add new configurations to individual rooms in a QTableView. In the configuration table, room is a foreign key to the rooms table. The form looks like this:</p> <p>...
3
1,906
How can i get the values out of multiple html form elements?
<p>I made a test and I'm trying to get the values associated with each answer so i can give the user a score based on those values. Right now the code gives me double the answers worth. Right now there are 7 questions and each time the user clicks the radio button with the right answer it should be worth 1 point. At ...
3
2,068
Node.js unexpected stack overflow with multiple get requests
<p>I have a function that GETs a JSON object from a remote server, or from a local cache on-disk.</p> <p>In a use-case, i have to call this function several thousand times with varying arguments, but when i do so, i get max stack overflow errors. I must be making a recursive call somewhere, but i can't see where it co...
3
2,083
Facebook Share/Like Default Image, Title, Description text
<p>We are making use of the FB Like/Share functionality on various pages for our client's site(s). On each page we want shared, we add the following in the meta tags:</p> <pre><code>&lt;head id="ctl00_Head1"&gt; &lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8" /&gt; &lt;meta http-equiv="Expires" ...
0
1,042
Merge maps inside list in terraform
<p>I have a list of maps like this -</p> <pre><code>[ { "outer_key_1" = [ { "ip_cidr" = "172.16.6.0/24" "range_name" = "range1" }, { "ip_cidr" = "172.16.7.0/24" "range_name" = "range2" }, { "ip_cidr" = "172.17.6.0/24" "range_name" = "r...
0
1,192
if(process.env.NODE_ENV === 'production') always false
<p>When trying to build an angular-webpack application by running the build command from this scripts list on the package.json:</p> <pre><code>"scripts": { "test": "NODE_ENV=test karma start", "build": "if exist dist rd /s /q dist &amp;&amp; mkdir dist &amp;&amp; set NODE_ENV=production &amp;&amp; webpack &am...
0
1,798
Unity Error: The given assembly name or codebase was invalid
<p>I am using the microsoft unity frame work and getting this error:</p> <pre><code>********** 4/15/2012 9:46:08 AM ********** Inner Exception Type: System.IO.FileLoadException Inner Exception: The given assembly name or codebase was invalid. (Exception from HRESULT: 0x80131047) Inner Source: mscorlib Inner Stack Trac...
0
1,643
ECS unable to assume role
<p>From the console, I am invoking a lambda which submits a batch job. The batch job fails, indicating that ECS is unable to assume the role that is provided to execute the job definition.</p> <p>For the role, I've added the lambda and ECS services.</p> <p>The error message:</p> <blockquote> <p>"ECS was unable to ...
0
1,109
Getting the length of a nested JSON array in JavaScript
<pre><code> { "wordsacross": [ {"ACHE": [ { "letter":"A" , "square":"A1" }, { "letter":"C" , "square":"A2" }, { "letter":"H" , "square":"A3" }, { "letter":"E" , "square":"A4" } ]}, ...
0
1,222
WPF ''local' is an undeclared prefix
<p>I have a problem with a defined <code>local</code> alias; why is it not valid?</p> <p>I have all of these classes which are not found.</p> <p>Error list</p> <pre><code>Error 3 ''local' is an undeclared prefix. Line 1, position 2.' XML is not valid. c:\..\SofiaCarRental.WPF\Views\AddEditWindow.xaml 1 2 S...
0
2,079
kendoui grid select all
<p>I, working with MVC + kendoui grid and this is my code:</p> <hr> <p>model</p> <hr> <pre><code> public class User { [StringLength(9)] public int UserId { get; set; } [StringLength(50)] public string UserName { get; set; } public bool IsSelecte...
0
1,280
React Native "onViewableItemsChanged" not working while scrolling on dynamic data
<p>I have a React Native FlatList. base on <a href="https://facebook.github.io/react-native/docs/flatlist.html#onviewableitemschanged" rel="nofollow noreferrer">Documentation</a> I used <strong>onViewableItemsChanged</strong> for getting the current showing item on the screen. but while scrolling or when scrolling stop...
0
1,234
Using SignalR with Redis messagebus failover using BookSleeve's ConnectionUtils.Connect()
<p>I am trying to create a Redis message bus failover scenario with a SignalR app.</p> <p>At first, we tried a simple hardware load-balancer failover, that simply monitored two Redis servers. The SignalR application pointed to the singular HLB endpoint. I then failed one server, but was unable to successfully get an...
0
5,382
model item passed into the dictionary is of type PagedList.PagedList[] but this dictionary requires a model item of type
<p>Im trying to use view models in my project but I have this error:</p> <blockquote> <p>The model item passed into the dictionary is of type 'PagedList.PagedList<code>1[ContosoUniversity.Models.Course]', but this dictionary requires a model item of type 'System.Collections.Generic.IEnumerable</code>1[ContosoUnive...
0
1,050
could not find method compile() for arguments
<p>I'm trying to execute some <code>.sql</code> scripts and then deploy web app using <code>gradle tomcat plugin</code>.</p> <p>But when I make any attempt to run <code>gradle</code> I've got an error</p> <p><img src="https://i.stack.imgur.com/RrJJu.png" alt="enter image description here"></p> <p>My <code>buildscrip...
0
1,225
Could not resolve all files for configuration CompileClasspath
<p>I'm trying to run my project with `.\gradlew assembleDenug' but I keep getting this output</p> <pre><code>Could not resolve all files for configuration ':app:mobileGoogleZappDebugCompileClasspath'. &gt; Could not resolve com.applicaster:GrandeFamily:0.3.+. Required by: project :app &gt; Failed to list ve...
0
5,847
ListItem disc displaying at vertical bottom
<p>I have a couple un-ordered lists on my page. Both lists use <code>list-style: disc inside;</code>. Each list's list-items have a couple <code>div</code>'s inside them. The problem is that the list-item's content takes up multiple lines and the disc is appearing vertically, at the bottom of the multi-line list-item.<...
0
1,574
Can't save custom subclassed model
<p>Inspired by <a href="https://www.tensorflow.org/guide/keras#model_subclassing" rel="noreferrer">tf.keras.Model subclassing</a> I created custom model.<br> I can train it and get successfull results, but <strong>I can't save it</strong>.<br> I use python3.6 with tensorflow v1.10 (or v1.9) </p> <p>Minimal complete c...
0
1,857
Failed to get absolute path to installed module
<p>I'm with a problem that I believe that is something related to my package.json or the version of the cordova platform.</p> <p>When I try to run an <code>ionic state restore</code> it returns the following output:</p> <pre><code>Attempting to restore your Ionic application from package.json Restoring Platforms co...
0
1,954
Bootstrap 3: Create an overlay on panel-body
<p>I want to display some information on the panel for which I need a overlay which should be displayed on user raised event.</p> <p>I've created a demo on <a href="http://www.bootply.com/116313" rel="noreferrer">BootPly</a>:</p> <p><strong>HTML of a single panel:</strong>(Rest is written in the link.. NOt relavent t...
0
1,491
Android Studio fails to debug with error org.gradle.process.internal.ExecException
<p>I am trying to run the app in debug mode but I get the following error:</p> <pre><code>Error:Execution failed for task ':app:dexDebug'. &gt; com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process 'command 'C:\Program Files\Java\jdk1.7.0_11\bin\java.exe'' finished with no...
0
1,369
How to add a custom User Provider in Laravel 5.4
<p>I have a Laravel 5.4 app, in which I have to authenticate my admin users from an external API, which when successfully logged in it returns a JSON with user information. </p> <p>I am creating a custom guard to make this:</p> <pre><code> 'guards' =&gt; [ 'web' =&gt; [ 'driver' =&gt; 'session'...
0
1,157
Mongo aggregation, project a subfield of the first element in the array
<p>I have a sub collection of elements and I want to project a certain subfield of the FIRST item in this collection. I have the following but it only projects the field for ALL elements in the array.</p> <p>Items is the subcollection of Orders and each Item object has a Details sub object and an ItemName below that. ...
0
1,110
how to set height of BottomSheet full parent?
<p>I am trying to call BottomSheet using a<a href="http://android-developers.blogspot.in/2016/02/android-support-library-232.html" rel="noreferrer">ndroid-support-library 23.2</a> on Click of button. Its working fine but not taking full height. It reside below <code>AppBarLayout</code>. I didn't find any solution on <a...
0
2,371
CSS Border transitions infinite animation loop
<p>I've captured <a href="https://jsfiddle.net/edgarkamdem/gofby5oc/" rel="noreferrer">this snippet of css</a> code on internet which perform an animation around the border of a button when hovering. I find it very nice.</p> <p>Is there a way to customize it in order to make the border animation looping infinitely and...
0
1,337
Use values from a function and pass it to another function
<p>I have the below two functions and I want the SOURCE and TARGET of the ROBOCOPY function used within the Comparision function. Can anyone tell me how to do this please. Thanks.</p> <pre><code>Write-Host "==================================" -ForegroundColor Magenta -BackgroundColor White Write-Host "Pre-Staging Scri...
0
2,443
(Hibernate) java.sql.SQLException: Field 'xxxx' doesn't have a default value
<p>Hibernate is throwing the following exception:</p> <pre><code>Caused by: java.sql.SQLException: Field 'catVerb_id' doesn't have a default value </code></pre> <p>People say that the problem is with my PKs that haven't the AUTO_INCREMENT statement, however you can see that I've done this in my database and the issue...
0
1,461
Failed prop type: The prop `children` is marked as required in `e`, but its value is `null`
<p>In my React app, I'm getting the following error but it doesn't tell me where it's happening. Any idea how I can pinpoint its location? The only place I have <code>this.props.children</code> doesn't seem to make any sense for this error.</p> <p><a href="https://i.stack.imgur.com/49DVc.png" rel="nofollow noreferrer"...
0
1,899
CRC-16 (IBM) Reverse Lookup in C++
<p>I'm having trouble with creating a Maxim CRC-16 Algorithm that would match a specific output. I've listed the resources I've used to help me write the program below:</p> <ul> <li><a href="http://www.maximintegrated.com/app-notes/index.mvp/id/27" rel="nofollow">Maxim App Note 27</a></li> <li><a href="http://www.san...
0
3,270
Socket tcp c# how to clear input buffer?
<p>I'm writing an application for windows phone and I need to communicate with a server and transmit data. The SERVER is written in C++ and I cannot modify it. The CLIENT is what I have to write. The Server is designed such that the client connect to it and transmit data. The connection remains open for all the transmi...
0
1,753
Insufficient stack to continue executing the program safely. ASP.NET MVC 4
<p>My search functionality seems to continue in a infinite loop, everytime my debug hits the action below the POST actionresult gets fired.</p> <p>In my Masterpage.cshtml I have following action:</p> <pre><code> &lt;li&gt;@Html.Action("Search", "Search")&lt;/li&gt; </code></pre> <p>This is the part that gets the err...
0
1,252
How to redirect to a new page in Angular 4 through button click?
<p>In <code>home.component.html</code> page I want the button to redirect the url to a new page when clicked. </p> <p>I expect that when I clicked the button, the current url <code>http://localhost:24282/home</code>, will be redirected to this url <code>http://localhost:24282/master</code> and <code>master.component....
0
1,069
Kube flannel in CrashLoopBackOff status
<p>We just start to create our cluster on kubernetes.</p> <p>Now we try to deploy tiller but we have en error:</p> <blockquote> <p>NetworkPlugin cni failed to set up pod "tiller-deploy-64c9d747bd-br9j7_kube-system" network: open /run/flannel/subnet.env: no such file or directory</p> </blockquote> <p>After that...
0
5,821
SelectedValue which is invalid because it does not exist in the list of items
<p>This is the error I get: </p> <blockquote> <p>ddlRankEdit' has a SelectedValue which is invalid because it does not exist in the list of items. Parameter name: value</p> </blockquote> <p>I have a form wiht several dropdownlists that are nested in a panel that is by default set to invisible. When a user selects...
0
1,250
Radio buttons in android studio
<p>I want to have list of radio buttons and after i select one and click next I would like to perform different actions depending on which button was pressed. i am trying currently to set text for some test TextView and for every radio button it says it is -1.</p> <pre><code>import android.os.Bundle; import android.su...
0
2,957
Create a custom sklearn TransformerMixin that transforms categorical variables consistently
<p>This question is not a <a href="https://stackoverflow.com/questions/48034035/how-to-consistently-hot-encode-dataframes-with-changing-values">duplicate</a> as someone suggested. Why? Because in that example, all possible values ARE KNOWN. In this example, they aren't. Further, this question - in addition to using a c...
0
1,428
Guidelines to do constexpr operator-overloading?
<p>Consider a simple int <code>Wrapper</code> class with overloaded multiplication <code>operator*=</code> and <code>operator*</code>. For "old-style" operator-overloading, one can define <code>operator*</code> in terms of <code>operator*=</code>, and there are even libraries like <a href="http://www.boost.org/doc/libs...
0
1,120
Calling activity from ViewHolder in RecyclerView?
<p>I've got a RecyclerView which is loading the content of my String arrays which works fine, however I want to open a new activity depending on which view they have pressed.</p> <p>What I have done is created an array called classes like so:</p> <pre><code>&lt;array name="classes"&gt; &lt;item&gt;ClassOne&lt;/i...
0
1,185
Django Cannot convert float to Decimal. First convert the float to a string
<p>I have a model that automatically re sizes the image and save the original also when you upload a picture.</p> <p>The problem is , when I save the image at the admin panel, I get this error </p> <p>Cannot convert float to Decimal. First convert the float to a string</p> <pre><code>File "C:\o\mysite\fruit\models....
0
1,290
No releases available for package
<p>I'm trying to install some pear packages such as gnupg in a Ubuntu OS in virtualbox, but if i use <code>sudo pecl install gnupg</code>, it throws </p> <pre><code>No releases available for package "pecl.php.net/gnupg" install failed </code></pre> <p>It is not only happening for gnupg, but for all pear packages. But...
0
1,887
Cannot deserialize instance of `java.lang.String` out of START_OBJECT token
<p>I am getting the below error message, can someone please help or suggest how best to debug this.</p> <blockquote> <p>Cannot deserialize instance of <code>java.lang.String</code> out of START_OBJECT token at [Source: (PushbackInputStream); line: 1, column: 37610] (through reference chain: com.model.ProductL...
0
1,712
How do I handle multiple calls in one thunk function?
<p>I don’t know if everybody has read this: <a href="https://medium.com/@stowball/a-dummys-guide-to-redux-and-thunk-in-react-d8904a7005d3?source=linkShare-36723b3116b2-1502668727" rel="noreferrer">https://medium.com/@stowball/a-dummys-guide-to-redux-and-thunk-in-react-d8904a7005d3?source=linkShare-36723b3116b2-15026687...
0
1,312
ng-boostrap not workingIf 'ngb-xx' is an Angular component, then verify that it is part of this module
<p>Getting the message </p> <blockquote> <p>If 'ngb-xx' is an Angular component, then verify that it is part of this module</p> </blockquote> <p>for every angular bootstrap components that i try </p> <p>Setup process </p> <pre><code>npm install angular-cli ng new project npm install npm install --save bootst...
0
1,731
Java Mail Exception Error;
<p>MyCode:</p> <pre><code>import java.util.Properties; import javax.mail.Message; import javax.mail.MessagingException; import javax.mail.PasswordAuthentication; import javax.mail.Session; import javax.mail.Transport; import javax.mail.internet.InternetAddress; import javax.mail.internet.MimeMessage; public class Send...
0
1,377
Classic ASP Authenticate Against Active Directory
<p>I have a Classic ASP website (sorry!). Some parts of it need to be NT authentication enabled. </p> <p>I would ideally like to present the user with a nice login form (rather than a browser prompt) which I then authenticate against AD and then do the usual "log in if success, show error if failure"</p> <p>Is this e...
0
1,136
EF Code First 4.1 - How to configure one to many relationship with default
<p>I have a Customer entity which references a collection of Addresses. The complication here is that I want to be able to identify a particular address as the default address.</p> <p>If possible I would like to hold the FK of the default address in the Customer table. This seems more elegant than having a column in...
0
2,322
Why is my SQL Server ORDER BY slow despite the ordered column being indexed?
<p>I have an SQL query (generated by LINQ to Entities) which is roughly like the following:</p> <pre><code>SELECT * FROM [mydb].[dbo].[employees] JOIN [mydb].[dbo].[industry] ON jobs.industryId = industry.id JOIN [mydb].[dbo].[state] ON jobs.stateId = state.id JOIN [mydb].[dbo].[positionType] ON jobs.positionTyp...
0
1,514
C# httpClient does not return content
<pre><code>public const string CloudApi = "https://www.idxhome.com/restServices/cloud-idx/login"; public const string password = "cloudidx"; public const string clientId = "65912"; public async Task&lt;ActionResult&gt; Index() { HttpClient client = new HttpClient(); client.BaseAddress = new Uri(CloudApi); c...
0
2,776
How I get ajax response from controller in magento 2
<p>I try to make an ajax call and pass the dropdown value in controller and get that particular related order information in view file. Response comes true but how to utilize that response in my view file.</p> <p><strong>Here is my phtml file</strong>:</p> <pre><code>&lt;select id="chartOption"&gt; &lt;option valu...
0
1,282
Inflate fragment from activity
<p>Here is my activity class. I am trying to inflate fragment to this activity.</p> <pre><code>public class MainActivity extends AppCompatActivity { @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); ...
0
1,440
Unable to configure second level cache of hibernate-ehcache-4.3.5.Final.jar in Hibernate 5.1.0.Final
<p>I'm trying to achieve second level cache in my Java EE project using Hibernate. My Hibernate version is 5.1.0.Final. I've created a table <code>employee</code> in my MySQL database. I've included <code>hibernate-ehcache-4.3.5.Final.jar</code> in my project, but it's throwing <code>Unable to create requested service ...
0
2,271
Webdriver Unable to connect to host 127.0.0.1 on port 7055 after 45000 ms
<p>I have box where I run tests. It seems like Jenkins would ssh in and execute commands described in the specific job that's running. </p> <p>Here I am trying to run my Selenium Webdriver tests, but it tells me that I have errors in launching firefox. The end idea is to run the webtests on this box entirely, and also...
0
1,372
Installing chatterbot but getting "ERROR: Could not build wheels for spacy which use PEP 517 and cannot be installed directly"
<p>I'm trying to install chatterbot on macOS with</p> <pre><code>python3 -m pip install chatterbot </code></pre> <p>and every time I get the same error during the step "Installing build dependencies ... /"</p> <pre><code>ERROR: Failed building wheel for spacy Running setup.py clean for spacy Failed to build spacy ER...
0
1,200