Posts

java - GWT Designer not working with Eclipse 4.2 service release 2? -

i'm trying this tutorial after having installed eclipse juno 4.2 service release 2 (java ee distribution) und following gwt installation instructions over here . however, neither windowbuilder entry under preferences, nor there windowbuilder entry in new projects dialog appearing. doing wrong? i'm running ubuntu 12.04.02 lts on amd64, , have tried oracle jdk 7u17 , ubuntu's own jdk6 distribution, no avail... just tried same in win2k3. exact same result. google starting annoy me. gwt 2.5.1 throws error when trying 1 of simplest projects... update: working extent. meaning: windowbuilder not recognize gwt designer's installation , offers install gwt designer eclipse 3.7 . designer toolbar's gwt selection possibilities therefore not there. update: bug filed . update: bug closed won't fix. don't care. they care. gwt magical development environment, under constant evolution. have race new versions of browsers, javascript , releases of ec...

machine learning - Duplicate detection of customers -

what current algorithms exist detecting duplicate accounts same costumer? customers trying hide fact opened 2 different accounts. example, maybe changed name shorter version or used email account in second account. what kind of algorithm used that? not sure if minhashing idea here.

python - Why does this pip call succeed in Makefile but not via command line? -

i ran across in makefile recently: develop: pip install "file://`pwd`#egg=myproject" this works fine when called make develop when call same command via command-line errors out " no such file or directory: /home/slack/tmp/myproject#egg=myproject' " why work when it's in makefile not called explicitly command line? the file:// bit telling pip install local resource. pwd command tells local resource in current directory, , tacks on egg called. i assume make file sets egg naming convention holds lookup, , there may default variables or commands in makefile adjust it.

sql - Why use named key constraint (Eg: Foreign Key) -

this question has answer here: differences between “foreign key” , “constraint foreign key” 3 answers i not familiar sql , please explain me difference of following 2 , best way use. there advantage using 1 on another. create table employee ( emp_id int not null, dep_id int not null, ... foreign key (dep_id) references department(dep_id) ); and create table employee ( emp_id int not null, dep_id int not null, ... constraint fk_empdept foreign key (dep_id) references department(dep_id) ); the difference in naming. if don't explicitly set name constraint, has auto generated name. example: fk_ employee _dep_id__164452b1 . , you'll see name in description of table keys, in different exceptions , on.

ios - Strange Swift Protocol behaviour -

this question has answer here: cannot assign property in protocol - swift compiler error 3 answers having trouble using swift protocol simplify uipageviewcontroller: i have protocol protocol pagable { var pageindex: int? { set } } which have of uiviewcontrollers being presented uipageviewcontroller conform to. then in uipageviewcontroller, this: var vc = storyboardscene.challenges.acceptedviewcontroller() as! pagable vc.pageindex = index return vc as? uiviewcontroller which works, want is: var vc = storyboardscene.challenges.acceptedviewcontroller() (vc as? pagable)?.pageindex = index return vc and reason, whenever instead (which me feels same snippet 1), error on (vc as? pagable)?.pageindex = index saying "cannot assign immutable expression of type int? ". i'm thoroughly confused. love insight why type system doing me. ...

python - Image not displaying Django 1.8 ImageField -

here's models.py class item(models.model): author = models.foreignkey('auth.user') name = models.charfield(max_length=200) price = models.decimalfield(max_digits=20,decimal_places=2) description = models.textfield() created_date = models.datetimefield(default=timezone.now) image = models.imagefield(upload_to=settings.media_root) def list(self): self.published_date = timezone.now() self.save() def __str__(self): return self.name views.py def item_list(request): items = item.objects.filter(created_date__lte=timezone.now()).order_by('-created_date') return render_to_response('item_list.html', {'items': items}, context_instance=requestcontext(request)) urls.py urlpatterns = [ url(r'^admin/', include(admin.site.urls)), url(r'', include('shop.urls')) ] + static(settings.static_url, document_root=settings.static_root) and settings.py base_dir = os.path.dirname(os.path.dirname(__file__)) ...

How do I keep reading from a keyboard in C while outputting results? -

i want read string , 4 integers display read read again string , 4 integers. want keep doing until end of file ( hitting ctrl + d). example : tennis 4 2 3 2 (hit enter) (the output) helloworld 2 8 7 4 (hit enter) (the output) here tried : #include <stdio.h> int main() { char name[30]; int won = 0; int lost = 0; int tie = 0; int streak = 0; int ch; while((ch = getchar()) != eof) { scanf("%s %d %d %d %d",name,&won,&lost,&tie,&streak); printf("%s%d%d%d%d",name,won,lost,tie,streak); } return 0; } while(scanf("%29s%d%d%d%d",name,&won,&lost,&tie,&streak) == 5) printf("%s%d%d%d%d",name,won,lost,tie,streak); from man -s3 scanf : these functions return number of input items matched , assigned