Meteor: add extra data to user on social sign up
Vote count: 0 In Meteor, I'd like to add a referrer field to new user signups. I can do this for users that register with a password, by passing in extra options to be used with Accounts.onCreateUser(function (options, user). But this doesn't seem to work with social login. Any ideas how I can get t...
Inserting info from a file into a struct
Vote count: 0 I want to extract data from a file and store them into the myWorld but my for loop doesn't work, the program doesn't loop one time once it gets to the for loop. I'm not sure what the problem is. This is my code so far. #include <iostream> #include <fstream> #include <string> #include <...
Connecting gevent-socketio to Server
Vote count: 0 https://github.com/abourget/gevent-socketio/blob/master/examples/simple_chat/chat.py def __call__(self, environ, start_response): path = environ['PATH_INFO'].strip('/') if not path: start_response('200 OK', [('Content-Type', 'text/html')]) retu ['<h1>Welcome. ' 'Try the <a href="/chat....
OpenCV with CUDA compilation selecting arch for GTX980
Vote count: 0 I have a GTX 980 Gpu and want to compile OpenCV with Cuda. For that reason, I have installed Cuda Toolkit 7.5. In the configuration of CMake, NVIDIA GPU arch is 20 21 30 35and PTX archs is 30. When I compile OpenCV.sln, I get this two errors: 3126 error : Could not open file for write ...
Unexpected PaxHeader inside gzip file created using gulp-gzip
Vote count: 0 I am using a gulp task to gzip my source files and set into a dist folder. I am able to successfully generate xyz.tar.gz file, but when I try to see the files in it using a 7zip on windows 7, I see a lot of files named "PaxHeader" each of different size. Tried searching on inte et, but...
Crawling slows down drastically towards the end
Vote count: 0 I've got a set of 25,000+ urls that I need to scrape. I'm consistently seeing that after about 22,000 urls the crawl rate drops drastically. Take a look at these log lines to get some perspective: 2016-04-18 00:14:06 [scrapy] INFO: Crawled 0 pages (at 0 pages/min), scraped 0 items (at ...
PhantomJS for loop hangs during second loop
Vote count: 0 I'm trying to iterate a collection of img tags on phantomjs, but it always hangs during the second loop console.log("length is: " + imgs.length); for (var i = 0; i < imgs.length; i++){ console.log("Position: " + i + " Code: " + imgs[i].outerHTML); } phantom.exit(); }; I've tried changi...
React: adding props to an existing component
Vote count: 1 I'm trying to figure out how to clone an existing element with additional props. For reference: this.mainContent = <Hello message="Hello world!" /> I attempted to do something like React.createElement(this.mainContent, Object.assign({}, this.mainContent.props, { anotherMessage: "nice t...
android 5.0 ask for security warning while open.camera
Vote count: 0 Please see this attachment. Why I see this on my screen, I am using all permissions <uses-permission android:name="android.permission.READ_PHONE_STATE" /> <uses-permission android:name="android.permission.INTERNET" /> <uses-permission android:name="android.permission.ACCESS_NETWORK_STA...
Multiple row layouts in CursorAdapter based on next item
Vote count: 0 I need to display a sort of visitor logs in a RecyclerView and the data to display comes from a SQLiteDatabase DESC-ordered by DateTime (column enter_time, UNIX value). I have already implemented a simple CursorAdapter and I'm able to display data in the RecyclerView. Next step is to m...
Define contra and co-variance for a generic object
Vote count: 0 In Java, co-variance for a generic can be defined as <? extends Clazz> and contra-variance can be defined as <? super Clazz>, but is it possible to define both of these traits at once? Take this case for example: interface Foo{} interface Fizz extends Foo{} interface Buzz extends Foo{}...
Springboot, hibernate4 and hsql accessing schema incorrectly?
Vote count: 0 I'm trying to use springboot, hsql and hibe ate together to persist and retrieve some fairly boring data. The issue I'm ru ing into is that hibe ate seems unable to reference my tables correctly, throwing the following exception: ERROR [main] (SpringApplication.java:826) - Application ...