Data dodania Pytanie
2016-11-26 23:11 Rspec Controllers - works when I run individual test, but not all tests in file? »
If I run the below spec by running rspec spec/controllers/brands_controller_spec.rb the last test fails giving me the PG error that the user is not i...
(1) odpowiedzi
2016-11-26 22:11 Error "'Validate_default_type!': An option's default must match its type (ArgumentError)" when running Ruby on Rails generate on Windows »
I am following this tutorial and have just started. I have installed Ruby on Rails with gem install rails and have created a blog with rails new blog....
(3) odpowiedzi
2016-11-26 22:11 Why Rails still needs Ruby => 1.9.3 after upgrade to 2.2.6? »
I am re-installing Ruby (last version 1.9.1) to version 2.2.6. I am doing this because I was trying to install the Rails gem, but when I did gem insta...
(0) odpowiedzi
2016-11-26 22:11 Why can't I import from a module alias? »
I just stumbled across this unexpected behavior in python (both 2.7 and 3.x): >>> import re as regexp >>> regexp <module 're' fr...
(4) odpowiedzi
2016-11-26 22:11 'rails new' creates a `validate_default_type!': An option's default must match its type. (ArgumentError) error »
I am trying to create a new Ruby on Rails application. Every time I type in rails new after, I get this error /usr/local/lib/ruby/gems/2.2.0/gems/tho...
(4) odpowiedzi
2016-11-26 22:11 Can not click checkbox with element from by.repeater »
For some reason I can not click a checkbox with by.repeater. There are no errors. When viewing the browser, the checkbox is simply not getting checked...
(1) odpowiedzi
2016-11-26 22:11 Python Requests Performance is low »
I am developing an RestAPI, and there is a part where I need to take a file from request, pass it to the Microsoft Cognitive Service and response back...
(0) odpowiedzi
2016-11-26 21:11 Unable to attach debugger in Android Studio - localhost:8600 java.net.ConnectException »
I cannot attach the debugger in Android Studio while running debug on a phone. I’m currently using a Samsung S4, running Android 4.4.4 (but have tr...
(2) odpowiedzi
2016-11-26 21:11 Performance gain on call chaining? »
Do you gain any performance, even if it's minor, by chaining function calls as shown below or is it just coding style preference? execute() -> ...
(1) odpowiedzi
2016-11-26 21:11 C# Sum Value From Foreach »
So Im doing a cshtml website and I cant seem to figure out how to sum the product of each row from the database and the foreach! var db = Database.Op...
(1) odpowiedzi
2016-11-26 21:11 JavaScript canvas ctx.getImageData running out of memory »
I made a program in JavaScript that draws a cycloid. It works fine but if it runs for a few minutes it sometimes gets an error and the whole thing sto...
(0) odpowiedzi
2016-11-26 21:11 Style guide for R - how can I write a good code in R? What I should avoid »
Hope this is a legitimate question. I am relatively new to R, I am looking for an equivalent of python's PEP 20 or python's PEP 8 style guide. I can n...
(0) odpowiedzi
2016-11-26 20:11 Simplify multiple subqueries in UPDATE statement »
I want to make my Flarum forum update its discussion records after manual intervention into the database. (Flarum is still in beta and still lacks man...
(1) odpowiedzi
2016-11-26 20:11 Why does incorrect assignment to a global variable raise exception early? »
a = 10 def f(): print(1) print(a) # UnboundLocalError raised here a = 20 f() This code of course raises UnboundLocalError: local variable 'a' ...
(3) odpowiedzi
2016-11-26 20:11 render records in databales »
I am rendering the data created and edited in a js.erb to a datatable, the problem is that when making use of pagination, such data disappears. this m...
(0) odpowiedzi
2016-11-26 20:11 Facebook graph API not working as expected »
When I try to upload a photo using the graph API, I get the following error: { "error": { "message": "(#324) Requires upload file", "type":...
(1) odpowiedzi
2016-11-26 20:11 Batch connecting with sqlplus »
I am trying to make a batch script which checks all customers automatically in a database if there are invalid objects. The issue I have is that when...
(1) odpowiedzi
2016-11-26 20:11 django-autocomplete-light error = 'list' object has no attribute 'queryset' »
i am new on django and i need your help, trying since many days to understand django-autocomplete-light, after setup my test, http://192.168.0.108:800...
(1) odpowiedzi
2016-11-26 19:11 Did Objective C start using + instead of | for combining bits? »
Anytime you combine two flags or more, you use |. Except Swift, which changed it to use array syntax. But now I am staring at some documentation on lo...
(1) odpowiedzi
2016-11-26 19:11 What is problematic about below ocaml code? »
let rec funli li k = match li with | [x] -> if k==1 then Some(x) else None | x::ll -> funli ll k-1;; utop shows Error: This expression has t...
(2) odpowiedzi
2016-11-26 19:11 Swift - Complete action after NSURLSession resumes »
I am trying to complet an an action after the URLSession resumes. So I am downloading several images from my server with the url, which all works goo...
(1) odpowiedzi
2016-11-26 19:11 Asp.Net core dbcontext issue »
I am creating Asp.net core application and trying to connect to the database. I am getting an error at the following line of code in ConfigureServices...
(2) odpowiedzi
2016-11-26 19:11 Asp.Net MVC razor graph using jquery ajax call »
I am trying to bind data to graph through razor. I pull data through a jquery ajax call and planning to bind the resultant data to graph. Is there any...
(2) odpowiedzi
2016-11-26 18:11 How to retrieve the count of the number of rows in asp.net mvc from sql database? »
I am trying to print something if the number of rows returned is more than 0 based on a query: using (SqlConnection con = new SqlConnection("Connecti...
(5) odpowiedzi
2016-11-26 18:11 Is there a difference between [] and list() when using id()? »
Can somebody explain the following? Why is the id the same, but the lists are different? >>> [] is [] False >>> id([]) == id([]) T...
(1) odpowiedzi
2016-11-26 18:11 How generate list of string with Bogus library in C#? »
I use Bogus library for generate test data. for example I have a class : public class Person { public int Id {get; set;} public List<string...
(1) odpowiedzi
2016-11-26 18:11 Casting IEnumerable<dynamic> with custom class »
I've been using dapper lately and wanted to make a dynamic method that would make it easier to select things out with sql. This is my code: Class: p...
(1) odpowiedzi
2016-11-26 18:11 setting default form mail in rails »
I am trying to build a contact form in Rails 5, where the form takes a name, email, and body it to my gmail. Upon clicking "Submit", this form send to...
(0) odpowiedzi
2016-11-26 18:11 Detect current input language »
I am building an app which allows users to check the local time in any place around the world. The information is being fetched using Google APIs and ...
(1) odpowiedzi
2016-11-26 18:11 Numpy Average distance from array center »
I have the center point of an array, center_point = (array.shape[0]/2.,array.shape[1]/2.) I have a binary image array, array, which has a shape wh...
(2) odpowiedzi
2016-11-26 18:11 student enrolled for same courses »
Student_table std_name course_enrolled S1 C1 S1 C2 S2 C1 S3 C4 S4 C1 S4 C2 S5 ...
(2) odpowiedzi
2016-11-26 18:11 Oracle SQL - Joining tables to include one column to the other (vice versa) »
These are my sample tables, columns and records... Table: tbl1 ----------------------- Columns: ID | DEPT | WK | MANHRS Records:...
(2) odpowiedzi
2016-11-26 18:11 Laravel Request::is() - is there a better way? »
@if(Request::is('login') OR Request::is('tags') OR Request::is('categories') OR Request::is('posts') OR Request::is('tags/..') OR Request::is('categor...
(1) odpowiedzi
2016-11-26 17:11 Laravel query builder not using variable from get method »
I have this function in one of my controller. public function tourList($country, $category) { $tour = Tour::whereHas('country', function($q) { ...
(1) odpowiedzi
2016-11-26 17:11 WordPress - persist user session & state across devices on local server »
CONTEXT I have a WordPress & WooCommerce installation running on a local server. Users can select the items they want, customize them, etc. I wan...
(0) odpowiedzi