date stringlengths 10 10 | nb_tokens int64 60 629k | text_size int64 234 1.02M | content stringlengths 234 1.02M |
|---|---|---|---|
2018/03/12 | 632 | 2,428 | <issue_start>username_0: I hope someone can help/guide me here. I had a working application, but today I keep getting the following error:
```
LNK2019 unresolved external symbol main referenced in function "int __cdecl invoke_main(void)" (?invoke_main@@YAHXZ)
```
The only thing that changed was that I updated VS2017... |
2018/03/12 | 511 | 1,832 | <issue_start>username_0: I would like to exclude or include certain test from test-suites. I would like to have some control of this via annotations/groups rather than naming specific files or folders in `phpunit.xml`
I have attempted something like this, but its appears to be ignoring the and/or
```
Unit
Integ... |
2018/03/12 | 2,357 | 8,379 | <issue_start>username_0: As an exercise I am adding 7 integers (each integer is between 1 and 39) to an ArrayList and then printing out the integers with a for loop. I seem to be getting the expected output (Eg. Lottery numbers: 3 5 10 14 15 27 37). However my code is failing the automated test. The test gives the foll... |
2018/03/12 | 330 | 1,259 | <issue_start>username_0: I'm trying to implement a double dropdown menu table on PHP.
I would like the user to choose two languages and then submit them to perform some queries.
Unfortunately, only one of the two values selected is selected, does anyone know why?
I'll leave the code here:
```
echo '';
ech... |
2018/03/12 | 512 | 1,641 | <issue_start>username_0: I ran this code on a different IDE and it was successful. For some reason I get the above error message on Xcode. I assume I'm missing a header of some kind, but I'm not sure which one.
```
#include
#include
#include
#include
int main() {
vector listRestaurants; // error: Implicit instan... |
2018/03/12 | 522 | 1,769 | <issue_start>username_0: I'm aware of the functionality of using `printProbs` from a classifier to print the probabilities that a particular token is a particular ner type. However, how can I access the CRFClassifier used by the CoreNLP pipeline in the bottom code to actually call the `printProb` method?
```
// cr... |
2018/03/12 | 672 | 1,928 | <issue_start>username_0: In Python, to format a string with a dictionary, one can simply do:
```
geopoint = {
'latitude': 41.123,
'longitude':71.091
}
print('{latitude} {longitude}'.format(**geopoint))
```
The output will be `41.123 71.091`. How do I achieve the same keyword unpacking of maps for string formatt... |
2018/03/12 | 812 | 2,467 | <issue_start>username_0: Firstly I am completely new to Linux as I set up an AWS Ubuntu instance for this project so be kind.
I have downloaded approximately 1 million .zip files containing .csv's in the following folder structure (financial data):
```
Main Folder
βββ Exchange1
β βββ Pair1
β β βββ Month
β β ... |
2018/03/12 | 817 | 2,854 | <issue_start>username_0: I have a user input where the user enters year, month and day and I create a date object
```
let userDate = new Date(year, month, day)
```
and then from a user input where the user enters minutes and hours (into variables minutes and hours)
I need to convert this date and time into UTC ti... |
2018/03/12 | 632 | 1,636 | <issue_start>username_0: This syntax would be very usefulβis there a reason for this not working? Thanks!
```
module Foo = {
let bar: string = "bar"
};
let bar = Foo.bar; /* works */
let { bar } = Foo; /* Unbound record field bar */
```
[Try it online!](https://reasonml.github.io/try.html?reason=LYewJgrgNgpgBAMRC... |
2018/03/12 | 430 | 1,592 | <issue_start>username_0: I'm using LiveData and ViewModel from the architecture components in my app.
I have a list of items that is paginated, I load more as the user scrolls down. The result of the query is stored in a
```
MutableLiveData>
```
When I do the initial load and set the variable to a new list, it tri... |
2018/03/13 | 853 | 2,680 | <issue_start>username_0: I have following code in Playgraound which doesn't work as I wish.
```
class Obj: NSObject {
var va1: String? = nil
var va2: Int? = nil
init(_ v1: String,_ v2: Int){
va1 = v1
va2 = v2
}
static func ==(lhs: Obj, rhs: Obj) -> Bool {
guard lhs.va1 == ... |
2018/03/13 | 1,261 | 3,383 | <issue_start>username_0: Let's consider this very simple code
```
int main(void)
{
char buff[500];
int i;
for (i=0; i<500; i++)
{
(buff[i])++;
}
}
```
So, it just goes through 500 bytes and increments it. This code was compiled using gcc on x86-64 architecture and disassembled using o... |
2018/03/13 | 564 | 1,857 | <issue_start>username_0: I have set the color of my main window in QT to be grey.
```
ui(new Ui ::MainWindow)
ui-> setupUi(this)
this->setStyleSheet("background-color: grey;");
```
I have tried multiple ways to set the color of the QFrame, however it takes on the default grey color that I have set. One way I tried ... |
2018/03/13 | 1,573 | 5,637 | <issue_start>username_0: I have some code that seems to be working, but in a rather odd fashion. When I first refresh the page I have the close button that seems to work fine, but when I make a new to-do list item the close button seems to cease working and I can't pinpoint why.
```js
let addItem = document.getElement... |
2018/03/13 | 937 | 3,206 | <issue_start>username_0: Here's an example. Writing a function to multiply two doubles is pretty simple:
```
func MultiplyDoubles(_ x: Double, _ y: Double) {
return x * y
}
MultiplyDoubles(3,5) // returns 15
```
But suppose I wanted to write a generic function to do this:
```
func MultiplyValues(\_ x: T, \_ y: ... |
2018/03/13 | 399 | 1,504 | <issue_start>username_0: Clojure is using persistent data structures , is there a way to access older versions of vector or maps since it is keeping it internally ?
Lets say for a Vector ,what i meant is since clojure is not copying full structure and keeping it in a tree internally (see <https://hypirion.com/musings... |
2018/03/13 | 493 | 1,254 | <issue_start>username_0: Fairly new to bash, I have a few different files, all with thousands of lines each, I want to take each line from each file, and put them together on one line, in a new file,
for example, if file1 contains IPs
```
192.168.1.1
192.168.1.2
192.168.1.3
192.168.1.4
192.168.1.5
```
file2 contain... |
2018/03/13 | 1,653 | 4,263 | <issue_start>username_0: I'm struggling to re-work a bit of code that I have to perform a slightly different function. Basically I have a list:
```
totalRank = [['P1'], 0], [['P2'], 0], [['P3'], 0], [['P4'], 0], [['P5']]
```
I also have a second similar list:
```
playerPoints = [['P1', 5], ['P2', 5], ['P3', 0]. ['P... |
2018/03/13 | 787 | 2,802 | <issue_start>username_0: This might be a double of some question, but I couldn't find the answer to the specific question that I have. I have the following code:
import React, { Component } from 'react'
```
class FAQContent extends Component {
constructor(props) {
super(props);
this.state = {
... |
2018/03/13 | 1,063 | 3,260 | <issue_start>username_0: How can I store list names inside a list in Python?
I have six lists that I need to combine into one big list. If any list from six lists is empty then I want to add empty brackets "()" to this final big list to indicate an empty list.
Here is what I tried but it didn't work as I stored list ... |
2018/03/13 | 1,722 | 3,782 | <issue_start>username_0: I have a dataframe nf as following:
```
DateTime Class Count
0 2017-10-01 00:00:00 1 0
1 2017-10-01 00:00:00 2 240
2 2017-10-01 00:00:00 3 17
3 2017-10-01 00:00:00 4 0
4 2017-10-01 00:00:00 5 1
5 2017-10-01 00:00:00 6 0
6 2017-... |
2018/03/13 | 463 | 1,801 | <issue_start>username_0: I have this task given to me and have no idea how to approach it.. Everywhere online says that this isn't possible without .dll or mocking.
>
> The server, when launched with an argument of βw should open a windowed interface that
> permits an operator to control the functions of the server.... |
2018/03/13 | 655 | 2,519 | <issue_start>username_0: Okay so I'm creating a personal to-do list program inside of VB(Using visual studio) and I'm having trouble implementing the function where the items inside of the listbox get added to a textfile.
Here is the code I have tried:
Private Sub btnAddItem\_Click(sender As Object, e As EventArgs) H... |
2018/03/13 | 558 | 2,247 | <issue_start>username_0: Is there a way to issue access tokens that are valid for a single use? My use case is to invoke Lambda functions from browser but want to restrict the number of invocations to one per token.
If a short lived token is issued then there is still potential for it to be used for multiple invocatio... |
2018/03/13 | 1,499 | 5,226 | <issue_start>username_0: I'm doing a small school project of object detection by color. When the object arrives in the center of the screen, it must have a sound. So the sound does not stay uninterrupted, I tried to put a delay on it. But every time the application arrives at the point of playing the sound, it closes. ... |
2018/03/13 | 183 | 698 | <issue_start>username_0: I am writing the query that will return the courses with the longest description. Here, what am I thinking but it wont work?
```
SELECT Max(DESCRIPTION)
FROM course
```<issue_comment>username_1: Have you tried playing the sound in a different thread ([AsyncTask](https://developer.android.co... |
2018/03/13 | 328 | 1,009 | <issue_start>username_0: I have a string with the following value:
```
COND_STRING = '(TRUE AND FALSE AND TRUE) OR FALSE'
```
How can I evaluate the outcome if it is True or False (1 or 0) in a SQL Server stored procedure?<issue_comment>username_1: i can only think of this way. Using `Dynamic SQL`
```
declare @str ... |
2018/03/13 | 344 | 1,516 | <issue_start>username_0: I have just discovered the extraordinary power of mongodb indexes. Building indexes on just a few fields has allowed me to speed up some operations 1000 fold, and more. My apologies for what might seem a stupid question: once I have built an index on particular fields in my database, will that ... |
2018/03/13 | 565 | 1,641 | <issue_start>username_0: How to round a modal screen like this [link](https://i.pinimg.com/236x/a9/7b/5c/a97b5c103c945d0cb0aba5fed9cb9f11.jpg) ?
My CSS code is:
```
.modal {
background: rgba(0, 0, 0, 0.5) !important;
padding: 25% 15% !important;
display: block;
border-radius: 25px;
}
```
modal.html
`... |
2018/03/13 | 538 | 1,906 | <issue_start>username_0: Why can we only put images on Docker hub and no docker-compose files. I mean there are a lot of applications using multiple containers which might be reusable, maybe with slight configurations.
Or is there a way to do exactly that? For now I use Docker hub for my images and a git repository fo... |
2018/03/13 | 489 | 1,829 | <issue_start>username_0: I'm trying to come up with a way of parameterizing some config files for a docker image using env vars. A sample input file could look something like:
```
${DB\_HOST}
${DB\_NAME}
${DB\_USER}
${DB\_PASSWORD}
```
and I'd want the output to basically be exactly the same, but with the field... |
2018/03/13 | 1,189 | 4,493 | <issue_start>username_0: I'm a newbie in React. Why can't my data pass to another component?? My idea is after the user select option tag, then it will load some audio files based off the selection. But it's not working. What did I miss?
Or is there a better to do it?
This is my dropdown component
```
import React ... |
2018/03/13 | 511 | 1,923 | <issue_start>username_0: Using Angular 5 and Firebase, I am storing and retrieving movie review information. When creating and editing the review, line breaks are kept (I assume using an ngModel has something to do with this). However, when retrieving the review from a reader's perspective, the `ReviewComponent`, the l... |
2018/03/13 | 590 | 2,139 | <issue_start>username_0: I'm using the GAS code bellow to add a new contact into Google Contacts (<https://contacts.google.com/>):
```
var contact = ContactsApp.createContact('Bbbb', 'Cccc', '<EMAIL>').addUrl(ContactsApp.Field.WORK_WEBSITE, 'https://sites.google.com/site/...');
```
The code works perfectly but for a... |
2018/03/13 | 570 | 1,692 | <issue_start>username_0: the type is defined as follows:
gap :: (Eq a) => a -> a -> [a] -> Maybe Int
I have been stuck on this problem for more than an hour and have no idea how to approach the problem. I am aware that it requires the use of fold and am familiar with that topic.
Please take into consideration that eith... |
2018/03/13 | 582 | 1,792 | <issue_start>username_0: Can't understand how this is possible:
```
A = object_list.filter( Q(sales__sale_starts__lte=today) & Q(sales__sale_ends__gte=today) )
# query inside filter catches 2 objects
B = object_list.exclude( Q(sales__sale_starts__lte=today) & Q(sales__sale_ends__gte=today) )
# query inside exclude ca... |
2018/03/13 | 592 | 2,191 | <issue_start>username_0: I have the following code, when going through the python, the options aaabaaaa, zzzazzazz gave me the false test.Here is the code, I am not too sure on how to fix it.
```
def checkPalindrome(inputString):
n=len(inputString)
#if string is one letter
if n==1:
return True
... |
2018/03/13 | 655 | 2,036 | <issue_start>username_0: I am trying to display array item of an array in a single line divided by 'commas' but the last array item should be preceded by 'and' and a full stop should be added at the end of the last element.
For example:
```
var cars = new Array("Saab", "Volvo", "BMW", "ZEST", "Audi");
```
Should b... |
2018/03/13 | 1,041 | 3,745 | <issue_start>username_0: I'm trying to retrieve the link for the audio only file on youtube using youtube\_dl. I wonder if it's possible to do so. I'm using youtube\_dl as in python code not with terminal.
Many thanks<issue_comment>username_1: If you want to download the audio only, you can do this,
```
ydl_opts = {
... |
2018/03/13 | 2,601 | 7,693 | <issue_start>username_0: First thing, I understand (almost) fold functions. Given the function I can work out easily what will happen and how to use it.
The question is about the way it is implemented which leads to slight difference in the function definition which took some time to understand.To make matters worse ... |
2018/03/13 | 606 | 2,166 | <issue_start>username_0: I have a class that takes an Action for the constructor, let's say class A.
```
public class A
{
public A(Action action) {...}
}
```
and I instantiate it.
```
class Program
{
void Main()
{
A a = new A(() => { DoSomethingWith(x); });
}
}
```
The question is: How can... |
2018/03/13 | 1,859 | 7,226 | <issue_start>username_0: I'm getting multiple errors. As I'm new to this async/await process. So with little research I've done this bit:-
I've a function like:-
```
public async Task GetMultipleTblResult(AdminBundle aBundleFetch)
{
if (!string.IsNullOrEmpty(aBundleFetch.ListType) && aBundleFetch.ListType.Equals(Co... |
2018/03/13 | 1,340 | 4,119 | <issue_start>username_0: I am trying to copy a date (Y-m-d) from one database table to another database table with format (Y-m-d H:i:s), with the following code:
```
php
$host = "host";
$user = "user";
$password = "<PASSWORD>";
$database1 = "home";
$database2 = "teste";
$con1 = mysqli_connect($host, $user... |
2018/03/13 | 637 | 2,077 | <issue_start>username_0: Using the split method in java to split `"<NAME> (111) 123-4567"` to `"John"` `"Smith"` `"111"`. I need to get rid of the comma and the parentheses. This is what I have so far but it doesn't split the strings.
```
// split data into tokens separated by spaces
tokens = data.split(" , \... |
2018/03/13 | 561 | 1,871 | <issue_start>username_0: I'm working on a King of the Hill/Elimination bracket spreadsheet & I have a cell that I want to return the cut (last score in the top 50%). Would anyone know how to go about this?
I have a formula for the average of the range, excluding 0's, but that isnt accurate since it isnt actually showi... |
2018/03/13 | 663 | 2,266 | <issue_start>username_0: Im trying to create an encrypted cookie using Javascript Code that Laravel can understand.
My current laravel project includes a pure JS code. In that JS code I displayed a JQVMAP.com Map and people click to define their country. In order to create a location cookie I included the following co... |
2018/03/13 | 746 | 2,808 | <issue_start>username_0: I want to copy files from source directory to destination. If the file already exists in the destination directory, then append the new file to be copied with its timestamp so that there is no overwrite. How do I check for duplicates and append timestamp to the new file name? Please help!
```
... |
2018/03/13 | 1,094 | 4,507 | <issue_start>username_0: I have a game in a 3D space, and rigidbody comp. to a player. I have implemented a jump mechanic that is not working at intended, with this code:
```
using UnityEngine;
public class PlayerMovement : MonoBehaviour
{
public bool Travel;
public Rigidbody rb;
public Transform tf;
... |
2018/03/13 | 2,013 | 7,183 | <issue_start>username_0: I am currently working with a somewhat complicated (deep) structure within an ngrx project. It can be thought of as an array of parent objects, with multiple levels of child objects. It is normalized/flattened on the server side, and my the feature within my store looks something like this:
``... |
2018/03/13 | 1,364 | 5,051 | <issue_start>username_0: I pass struct into a function as `interface{}`. Then inside I work with it using `reflect` to get the struct attributes. Here's the code:
```
func (db *DB) Migrate(domain ...interface{}) {
// statement := "CREATE TABLE IF NOT EXISTS %s (%s, %s, %s, %s, %s)"
for _,i := range domain {
... |
2018/03/13 | 721 | 2,937 | <issue_start>username_0: Say we have a certain parent process with some arbitrary amount of data stored in memory and we use `fork` to spawn a child process. I understand that in order for the OS to perform copy on write, the certain page in memory that contains the data that we are modifying will have its Read-only bi... |
2018/03/13 | 3,095 | 11,793 | <issue_start>username_0: **Issues**
So I try to decouple my application to multiple module project ( each has its own **composer.json** ), then the real application will load all this project through composer
Each of this module project will have a user-interface accessible through browser and can start individually,... |
2018/03/13 | 1,484 | 4,746 | <issue_start>username_0: I want users to be able to right click and have the custom contentmenu have two choices:
Contact (with link <https://rowurbux.weebly.com/contact.html>)
Support (with link <https://rowurbux.weebly.com/support.html>)
```html
if (document.addEventListener) { // IE >= 9;other browsers
docume... |
2018/03/13 | 329 | 1,215 | <issue_start>username_0: I have a website with more than 35k users, who can opt-in to receive coupons, offers, discounts and some other information.
I have a huge issue, the list is too big!
Months ago, I would just make a for-each and everything was fine, but now, obviously the script just timeout.
Here a real exam... |
2018/03/13 | 436 | 1,383 | <issue_start>username_0: I'm working with two servers (Server 2012 Std) and (Server 2016).
On 2012 when I run the command:
```
[System.DateTime]::UtcNow.ToString([System.Globalization.CultureInfo]::GetCultureInfo("en-NZ"))
```
I get back the result:
>
> 13/03/2018 12:49:55 a.m.
>
>
>
When I run the same comma... |
2018/03/13 | 227 | 809 | <issue_start>username_0: I have a folder of several images, and I would like to choose one randomly and add it to a subplot (using offsetbox for example).
How can I do this?<issue_comment>username_1: Take a look at [Output of times (AM/PM) changed in Windows 10 when using DateTime.ToString("tt")](https://stackoverflow... |
2018/03/13 | 1,153 | 4,135 | <issue_start>username_0: I want to read two non-consecutive lines once in a very big file in python, that is, the expected result is the following(the number is the line number):
1 6 (the first time reads the 1st and 6th line)
2 7 (the second time reads the 2nd and 7th line)
3 8 (the third time reads the 3rd and 8th... |
2018/03/13 | 1,134 | 3,190 | <issue_start>username_0: ADB Table

Todays Date

I have a ADB table. I want to extract the Column name base on system date
I'm currently trying the following which is not working.
```
SELECT (
SELECT DISTIN... |
2018/03/13 | 2,376 | 9,286 | <issue_start>username_0: I am working to automate a process. Currently, I am uploading Excel (`.xlsx`) files to a specific folder in Drive. I then manually convert them into a Google Sheet file, and move it into a separate folder. I would like to automate this process. I know I would have to write the script to iterate... |
2018/03/13 | 1,717 | 6,750 | <issue_start>username_0: I am trying to assign a URL to a variable
```
css <- " "
```
but I get the
```
CMS.R:49:22: unexpected symbol
```
I did search previous answers and tried escaping with \ and what not but to no avail. Thanks in advance for your help.<issue_comment>username_1: Either of your codes, if they... |
2018/03/13 | 1,433 | 5,619 | <issue_start>username_0: I have an issue with my alexa app. I am fairly new with NodeJS and Alexa,
Here is my issue. I have a dynamodb that contains an array. From that array, I will go and get all my values from a rest website that will provide me with JSON data. I will pass this data to a template and finally call ... |
2018/03/13 | 573 | 1,981 | <issue_start>username_0: OK so I'm primarily a Angular 1.\* developer and I thought I'd give angular 5 a try and so far I must say it is giving me hell. Way more complicated than it needs to be but anyhow....
So I make an HTTP call and **I have this node API that returns something**
like this:
```
apiRoutes.route('/a... |
2018/03/13 | 1,041 | 3,341 | <issue_start>username_0: I am trying to read a 2D matrix from a .txt file into a dynamically sized 2D array. The matrix in the .txt file is tab delimited and could be of any size but for simplicity, we have:
```
1 2 3
4 5 6
7 8 9
```
I parse the file for a row and column count, dynamically create an empty 2D ar... |
2018/03/13 | 359 | 1,214 | <issue_start>username_0: i want to use base url in javascript file using codeigniter function `base_url()`
i am doing it as below but this is not working ,
```
$('.toggleimg').attr('src','=base_url?assets/front/img/sidebar1.jpg');
```
Please helpe me how can i make it work in a js file .<issue_comment>username_1:... |
2018/03/13 | 415 | 1,481 | <issue_start>username_0: I'm using a form that needs to pass a hidden field:
```
var ss\_form = {'account': 'XXXXX', 'formID': 'XXXXX'};
ss\_form.width = '100%';
ss\_form.height = '500';
ss\_form.domain = 'app-XXXXX.marketingautomation.services';
ss\_form.hidden = {'field\_XXXXX': 'test item, another item' };
... |
2018/03/13 | 1,730 | 7,239 | <issue_start>username_0: I am currently working on a Windows 10 UWP C++ project under Visual Studio Community 2017 for Windows 10 version 10.0.16299.0.
The following procedure: I have a TCP server running on my computer, which sends a message to the connected clients at certain events. The project I am working on now ... |
2018/03/13 | 1,534 | 5,919 | <issue_start>username_0: So.... I'm having a weird behavior when replacing data after AJAX POST success.
I have a table which contains products and after editing this products I replace the old data with the new one.
The weird thing is that if I edit 1 row works fine **BUT** if I edit for example: row 1 and after tha... |
2018/03/13 | 1,390 | 4,411 | <issue_start>username_0: I have this code in a Xamarin type solution
```
public async Task GetList(string urlBase, string servicePrefix, string controller)
{
try
{
var client = new HttpClient();
client.BaseAddress = new Uri(urlBase);
var url = string.Format("{0}{1}", servicePrefix, controller);
var response = aw... |
2018/03/13 | 315 | 992 | <issue_start>username_0: ```
33 S 3rd st
95130
United
States
```
This is my XML.I need a country code "US".I am using XML dom4j and following its tutorial.
Here is my code snippet
```
List list1 = e.selectNodes("//\*[name() = 'Address']");
for(Node n: list1)
{
System.out.println("CC"+n.valueOf("@is... |
2018/03/13 | 405 | 1,398 | <issue_start>username_0: I have a `BoxView` that I want to change the color of when the user taps it. I created a `BoxView` called tapView and set the `GestureRecognizer` like so:
```
var tapGestureRecognizer = new TapGestureRecognizer();
tapGestureRecognizer.Tapped += (s, e) => {
// handle the tap
OnTapGestur... |
2018/03/13 | 780 | 2,286 | <issue_start>username_0: How I can SUM 2 Union all's for a field?
Basically, I got 1 table working with 2 rows on it. Now I want
to add
3rd row wherein I want to SUM a field in the first row and
SUM a field
of
2nd row and have the two SUM results appear in the third row,
just as
a query (not create a new table). ... |
2018/03/13 | 1,137 | 4,325 | <issue_start>username_0: I wonder why it returns null when I tried in postman it has data returns. Here is my code.
```
public async Task> GetUserJobs(LoginResult token)
{
var result = new List();
string url = "JobHeaders?userName=" + token.userName;
HttpResponseMessage httpResponse = await \_requestHelper.GetHttpR... |
2018/03/13 | 604 | 2,381 | <issue_start>username_0: I am new to Python 3, coming over from R.
I have a very large time series file (10gb) which spans 6 months. It is a csv file where each row contains 6 fields: Date, Time, Data1, Data2, Data3, Data4. "Data" fields are numeric. I would like to iterate through the file and create & write individu... |
2018/03/13 | 1,073 | 4,317 | <issue_start>username_0: I made a small program in VB.NET that injects Dlls into processes. This will help me learn how reverse engineering and form design. The only issue is I made the form a borderless form meaning I cant drag it. So what I did was added a GroupBox element that covers the form size. I want to be able... |
2018/03/13 | 504 | 1,911 | <issue_start>username_0: I'm trying to copy all of the content from a p tag using javascript. It works, but it copies the text in one long line of text. I want it to copy with the format using the break tags, like if someone were to copy / paste using their mouse like so:
Current Time: :
Time Found: :
Ambient Temp: ... |
2018/03/13 | 421 | 1,570 | <issue_start>username_0: I am new to linux bash, here is a problem confusing me. I don't understand "hash wget". what's the purpose of it, why there should be a if check?
```
if [ ! -e text8 ]; then
if **hash wget 2>/dev/null**; then
wget http://mattmahoney.net/dc/text8.zip
else
curl -O http://mattmahoney.... |
2018/03/13 | 385 | 1,495 | <issue_start>username_0: I have 400 json files in a folder and I want to create 400 lists of that name.
So, for example, I have these 4 json files: john.json ; rick.json; tom.json; sean.json
Now I want to create 4 lists in Python containing the data of each of these json files. I want to do this in a loop<issue_commen... |
2018/03/13 | 758 | 2,288 | <issue_start>username_0: I have a two array with with different values. I'd like to match the arrays and spearate the values that is not match. It's my current script:
```
var array_must_exist = ['4','5'];
var array_to_compare = [{"NO": "1"},{"NO": "2"},{"NO": "5"},{"NO": "7"}];
$.each(array_to_compare, function(i, r... |
2018/03/13 | 1,476 | 4,548 | <issue_start>username_0: I'm working on a GET request that finds an id and the amount of holdings a user has saved in the database. It takes that id and calls a function that retrieves updated information about the item. What i'm trying to do is also include the holdings in the GET request, however, I want it inside of... |
2018/03/13 | 1,333 | 4,926 | <issue_start>username_0: When I scroll the tableView the UIImageView is not displaying the correct image. How can I accomplish this correctly in the **swift 4 language.**
```
func tableView(_ tableView: UITableView, cellForRowAt indexPath: IndexPath) -> UITableViewCell {
let cell = tableView.dequeueReusableCe... |
2018/03/13 | 1,181 | 4,256 | <issue_start>username_0: I'm trying to update array in Codeigniter but but I can't figure out the syntax.
Error:
A PHP Error was encountered
Severity: Notice
Message: Array to string conversion
Filename: database/DB\_driver.php
Line Number: 1525
```
public function allowregis()
{
$data = $this->input->... |
2018/03/13 | 1,858 | 4,055 | <issue_start>username_0: I have a list of object looks like this, and i want to turn it to a list of values by id.
```
Original = [
{id: 1, value: 12.2494, time: "00:00:00.14"},
{id: 1, value: 4.5141, time: "00:00:01.138"},
{id: 1, value: 2.85930, time: "00:00:02.138"},
{id: 1, value: 1.0364, time: "0... |
2018/03/13 | 843 | 3,142 | <issue_start>username_0: I need to track some logs event(**only once**) when App launch and close.
First I do this in `Home` screen `componentDiMount()`, but it will be instantiated several times in some case, causing repetitive launch event log.
=============== Edit =================
`AppState` can only listen **ba... |
2018/03/13 | 1,013 | 3,213 | <issue_start>username_0: How do we select a column that is not in a `GROUP BY` clause?
When executing the below code I get the error:
>
> An aggregate may not appear in the WHERE clause unless it is in a
> subquery contained in a HAVING clause or a select list, and the column
> being aggregated is an outer refere... |
2018/03/13 | 406 | 1,286 | <issue_start>username_0: I want to delete all documents where a certain **field** exists
I tried to POST to the *\_delete\_by\_query* API
```
{
"query": {
"bool": {
"must": [
{ "exists":"field_name" }
]
}
}
}
```
That's giving me this *query malformed* error:
```
{
"error": {
"... |
2018/03/13 | 442 | 1,710 | <issue_start>username_0: Hello I am trying to learn python from the beginning and I keep running into an issue when importing modules. I am running python 3.6.4 and it was installed via anaconda 4.4.10. Here is an example of my issue: If I go to cmd line and run 'pip install requests' I get 'requirements already satisf... |
2018/03/13 | 422 | 1,524 | <issue_start>username_0: ```
def main:
with open(sourcefile, 'r', encoding='utf-8') as main_file:
for line in main_file:
htmlcontent = reader(line)
def reader(line):
with urllib.request.urlopen(line) as url_file:
try:
url_file.read().decode('UTF-8')
except urllib.error.URLError a... |
2018/03/13 | 599 | 2,544 | <issue_start>username_0: I keep doing classes and typing away at learning programming and in a few different lesson they say this is how you declare a null variable(java and Kotlin if i remember right python is a "none" not exactly the same).
But everything I read or learn says don't do it.
Why do it or is there a l... |
2018/03/13 | 852 | 3,142 | <issue_start>username_0: I am trying to create a 2-dimensional array without using ArrayList. I was successful at creating the array but I run into a snag when trying to print the array from another method because the array is not static. However, I cannot make the array static because I am also allowing the user to de... |
2018/03/13 | 1,048 | 3,052 | <issue_start>username_0: There seems to be a change in the way equality metamethods are executed, but I cannot find the documentation in any of the 5.1, [5.2](https://www.lua.org/manual/5.2/manual.html#8) or [5.3](https://www.lua.org/manual/5.3/manual.html#8) reference manuals (under the Change in the Language sections... |
2018/03/13 | 606 | 2,193 | <issue_start>username_0: I'm getting these warnings in my android build.
```none
Warning:(19, 9) Attribute `layout_marginVertical` is only used in API level 26 and higher (current min is 24)
Warning:(20, 9) Attribute `layout_marginHorizontal` is only used in API level 26 and higher (current min is 24)
```
Clearly ou... |
2018/03/13 | 846 | 3,183 | <issue_start>username_0: I'm running into an error where when I try
`from PIL import Image, ImageFilter`
in a Python file I get an error stating `ModuleNotFoundError: No module named 'PIL'`.
So far I've tried uninstalling/reinstalling both PIL and Pillow, along with just doing `import Image`, but the error keeps on... |
2018/03/13 | 877 | 3,152 | <issue_start>username_0: no matter what numbers I put in for x or y
even if I change the values of 16 or 250
```
x = anyRandomNumber
y = anyRandomNumber
print ((x + y == 16) == ((10*x) + (25*y) == 250))
```
This was code provided by an instructor in a lesson and it's only suppose to execute true when x = 10 and y ... |
2018/03/13 | 802 | 3,090 | <issue_start>username_0: I request data from a link on the internet using Volley.
In that link there are four objects and I added them to the array.
If I now want to add another object or remove that object from the array after restarting the application. The data of the array remains as I have manipulated them. How to... |
2018/03/13 | 2,005 | 7,772 | <issue_start>username_0: In my game I got the ball to fall straight down but I want to implement a collision method that detects when the ball touches the net, then deletes the ball and adds one point to my score. I dont know where to start and how to do this so any help is extremely appreciated. thank you.
Main activ... |
2018/03/13 | 502 | 1,844 | <issue_start>username_0: When I execute following SQL code to create database and tables, I got error message: `Error Code: 1215. Cannot add foreign key constraint`. If I make `test.book.storeID` to be primary key, the code works. Does the referenced column need to be primary key?
```
CREATE SCHEMA IF NOT EXISTS `tes... |
2018/03/13 | 474 | 1,822 | <issue_start>username_0: I'm using a logger inside Python process (multiprocessing.process) to log. I declare a FileHandler to log to disk, once the job is done I try to close the underlying file but can't achieve that. My real problem is that I spawn a lot of process resulting in `IOError: [Errno 24] Too many open fil... |
2018/03/13 | 704 | 2,585 | <issue_start>username_0: There have been questions asked similar to this but I've tried every solution I've come across in 3 straight days of chasing this issue and I can't figure it out.
This started with me not being able to import .xlsx files in the import wizard; I got the error noted [here](https://stackoverflow.... |
2018/03/13 | 362 | 1,351 | <issue_start>username_0: This is really simple stuff, why is it not working?
Script window:
```
x <- 8
y <- 5
x + y
```
Console:
```
> x + y
Error: object 'x' not found
```
Even if I get rid of y and just input x I still get the same error.<issue_comment>username_1: You could try restarting R. Also, do no... |