Posts

Showing posts from March, 2013

linux - How to solve too many TCP connections on FIN_WAIT_2? -

server , client connected using port 8000. clients aborted unexpectively connections still there. besides restarting server, suggestion release legacy connections? $ net stat -an | grep 8000 tcp4 0 0 127.0.0.1.8000 127.0.0.1.58761 close_wait tcp4 0 0 127.0.0.1.58761 127.0.0.1.8000 fin_wait_2 tcp4 0 0 127.0.0.1.8000 127.0.0.1.58755 close_wait tcp4 0 0 127.0.0.1.58755 127.0.0.1.8000 fin_wait_2 tcp46 0 0 *.8000 *.* listen

java - How complete list of object into another object uqing Rxjava -

on service, client has on or many relationships. using rxjava when client want retrieve client object list of relationships. something like: datamanager.getclient(clientid) .zipwith(???) .observeon(androidschedulers.mainthread()) .subscribeon(schedulers.io()) .subscribe(); use map function change scope of data within observable: datamanager.getclient(clientid) .map(client -> client.relationships) .observeon(androidschedulers.mainthread) .subscribeon(schedulers.io()) .subscribe(list -> { *do something* });

angularjs wait for response from $http -

i have problem function doesn't wait response of http request , go further. know can use promise wait don't understand concept. i have data service have http request : function getgroupidfrombakery(bakeryid, successcallback, errorcallback) { $http.get(service.baseurl + "bakeriesgroup/bakeries/" + bakeryid) .then(function (result) { successcallback(result.data); }, errorcallback); } from service, call data service : var haspermission = function (permission, params) { permissionroute = permission; setidentity(params); (var = 0; < permissions.length; i++) { if (permissionroute.name === permissions[i].name) { if (permissions[i].scope == "system") return true; else if (permissions[i].scope == permissionroute.scope && permissions[i].identity == permissionroute.identity) return tr...

java - javax.xml.bind.UnmarshalException iccurs when unmarshalling an XML -

i use below code unmarshal xml using jaxb. responsexml contains xml string returned web service call. stringreader reader = new stringreader(responsexml); jaxbcontext = jaxbcontext.newinstance(testresponse.class); unmarshaller unmarshaller = jaxbcontext.createunmarshaller(); object idresponse = unmarshaller.unmarshal(reader); below exception occurs when unmarshalling. javax.xml.bind.unmarshalexception - linked exception: [exception [eclipselink-25004] (eclipse persistence services - 2.3.2.v20111125-r10461): org.eclipse.persistence.exceptions.xmlmarshalexception exception description: error occurred unmarshalling document internal exception: java.lang.illegalargumentexception: ] someone work on this. below testresponse class auto generated xsd @xmlaccessortype(xmlaccesstype.field) @xmltype(name = "", proporder = { "responsecode", "responsedescription", "responsemessage" }) @xmlrootelement(name = ...

mysql - myrocks (mariadb + rocksdb) php charset -

there plenty of posts choosing right charset mysql, it's again different (and frustrating) story rocksdb engine. firstly, decided use utf8-binary charset (latin1, utf8-bin , binary supported myrocks) because data may contain special chars , want on save side. furthermore, using php , pdo loading data mysql , connection looks this: $pdo = new pdo('mysql:host=localhost;dbname=dbname;charset=utf8', 'user', 'password'); so set charset utf8 (i tried use utf8_bin , not supported pdo). although, able insert rows, errors following one: incorrect string value: '\xf0\x9f\x87\xa8\xf0\x9f...' column 'column_name' but what's error now? hex sequence encodes unicode-smily (a regional indicator symbol letter c + regional indicator symbol letter n). seems me valid utf8 , mysql php configured use it. you gotta have utf8mb4 , not mysql's subset utf8 . 🇨 needs 4-byte utf-8 encoding, hex f09f87a8 . if rocksdb not support ...

javascript - JS Animation really buggy -

i'm trying build image slider automatically takes div ids , animates them. far works buggy. animation lagging lot , when minimized tab, slides animated @ same time. i made jsfiddle issue: https://jsfiddle.net/2cdwgvm7/ js: function slider() { var counter = 0; var sliderebene = document.getelementbyid(imageids[counter]); sliderebene.style.left = '0px'; var counter = 1; var flag = true; var functionisrunning = true; function clickslider() { forward.addeventlistener('click', function () { functionisrunning = true; if (counter >= imageids.length) { counter = 0; } else { var sliderebene = document.getelementbyid(imageids[counter]); var pos = browserwidth; var id = setinterval(frame, 0.6); function frame() { if (pos == 0) { sliderebene.style.zindex = ...

rust - Is there a way to add elements to a container while immutably borrowing earlier elements? -

i'm building gui , want store used textures in 1 place, have add new textures while older textures immutably borrowed. let (cat, mouse, dog) = (42, 360, 420); // example values let mut container = vec![cat, mouse]; // new container let foo = &container[0]; // container immutably borrowed container.push(dog); // error: mutable borrow is there kind of existing structure allows this, or can implement using raw pointers? the absolute easiest thing introduce shared ownership : use std::rc::rc; fn main() { let (cat, mouse, dog) = (42, 360, 420); let mut container = vec![rc::new(cat), rc::new(mouse)]; let foo = container[0].clone(); container.push(rc::new(dog)); } now container and foo jointly own cat . is there kind of existing structure allows this, yes, there tradeoffs. above, used rc share ownership, involves reference counter. another potential solution use arena: extern crate typed_arena; use typed_arena::arena; fn main(...

javascript - How change a google maps without access to original variable -

currently creating greasemonkey script change map on external site. site create google maps object inside private function , need add circle on map but, dont have access original map creation variable (created inside funcion). cenario moreless , cannot change creation function (is greasemonkey script): function createmap() { var map = new google.maps.map(document.getelementbyid('map'), { zoom: 18, center: {lat: 10.10, lng: 11.11}, maptypeid: 'terrain' }); } the "createmap" funcion provided original site , have lot of functions inside (i put here example). "map" variable private on function scope , cant change (i not have access site source code). so, need create circle element inside map using greasemonkey script. on documentation , not found way "list of maps on current page" or liked try add... i need add code... dont know how can populate new "map" variable "pointer"...

php - Capitalise Name and Initials in a String -

i have number of records store names in varying combinations, e.g. - first_name | last_name joe | bloggs jane louise | smith jb | smith b | jones i need displays these names in proper case - full_name joe bloggs jane louise smith jb smith ab jones i know php has various built-in functions converting string uppercase, lowercase, first letter capitalised, etc can't find handle initials correctly. does have script this? alternatively, if possible in mysql option. select concat(upper(substring(firstname, 1, 1)), lower(substring(firstname 2))) properfirstname from mysql website so problem: select case when length(first_name) = 2 or (length(first_name) = 3 , first_name '% %') -- check if initials first name concat(upper(replace(first_name, " ", "")), -- initials in upper, no spaces " ", upper(substrin...

vba - Copy all Powerpoint Picture Hyperlink to Excel (loop) -

i trying create loop go through each picture in slideshow , paste each picture's corresponding hyperlink in excel document list i loop loop through pictures in order left right (ie in this screenshot attached, select upper left image (target's ad), next image right (rite-aid's ad), cvs's, walgreens', , go next row starts benadryl walgreens , repeat process) here code have far 'code getting hyperlinks of images in powerpoint- , pasting excel sub getlinks() dim pptslide slide dim pptshape shape dim ppthlstring string dim xlapp object dim xlworkbook object set xlapp = createobject("excel.application") xlapp.visible = true set xlworkbook = xlapp.workbooks.open("c:\weekly ad recaps\non-fsi\lookuptable non fsi.xlsm") = 0 each pptslide in activepresentation.slides each pptshape in pptslide.shapes = + 1 if pptshape.type = shape on error resume next xlworkbook.sheets("ppt h-link index").ra...

java - How to adjust JLabel dimensions to fixed font and font size? -

this question has answer here: how calculate font's width? 6 answers calculate display width of string in java 4 answers i trying make java swing application involves use of several jlabels. each jlabel have different set of text , font size, depending on program input. every label must take little excess space possible. how can calculate minimum possible width , height jlabel, given fixed string of text, fixed font, , variable font size? define minimum height , width smallest possible dimensions jlabel before "..." displayed in label. "..." auto-generated , indicates jlabel small text displayed. for example: how narrow , short can jlabel contains text "hello world" written in 12 point tahoma font before label displays "..."? ...

c# - Console application integrating Slack Webhooks, but compiler says namespace "Slack" cannot be found -

i creating simple console app on run, checks date , sends notification via email, , works. tried adding slack webhooks package through nuget package manager , implemented simple post function package send notification slack channel, , on build , debug works perfectly. however, on compiling project, message appears: program.cs(1,7): error cs0246: type or namespace name 'slack' not found (are missing using directive or assembly reference?) i tried reinstalling package, though see "missing" reference in solution explorer, problem persists. using .net framework 4.5.2, have not changed framework version project (as i've seen solutions propose downgrading project's framework, presumably enforce compatibility) how can solve problem, though?

php - Resetting array pointer in PDO results -

i'm having trouble moving mysql select methods pdo methods. want iterate through fetched array twice, both times starting row zero. in mysql use: mysql_data_seek($result,0); using pdo methods, i'm not sure how accomplish same thing. code below how trying this. first while loop works fine second while loop returns nothing. can please tell me i'm going wrong? $pdo = new pdo('mysql:host=' . $host . ';dbname='.$database, $username, $password); $pdo->setattribute(pdo::attr_errmode, pdo::errmode_exception); $stmt = $pdo->prepare('select * mytable active = 1 order name asc'); $stmt->setfetchmode(pdo::fetch_assoc); $stmt->execute(); while($row = $stmt->fetch()) { //do starting row[0] } while($row = $stmt->fetch()) { //do else starting row[0] } thanks help. save results array , loop array twice. $pdo = new pdo('mysql:host=' . $host . ';dbname='.$database, $username, $password); $pdo->setatt...

angular - set md-paginator values dynamically -

i trying use pagination of angular-material2 . problem facing set values of md-paginator dynamically through service. i have managed create pagination using static values dont know how set them dynamically. below far. plunker ts import {component,changedetectorref, input,viewchild } '@angular/core'; import {http, response, requestoptions, headers, request, requestmethod} '@angular/http'; import {mdpaginator,pageevent} '@angular/material'; import {datasource} '@angular/cdk'; import {behaviorsubject} 'rxjs/behaviorsubject'; import {observable} 'rxjs/observable'; import 'rxjs/add/operator/startwith'; import 'rxjs/add/observable/merge'; import 'rxjs/add/operator/map'; @component({ selector: 'table-http-example', styleurls: ['table-http-example.css'], templateurl: 'table-http-example.html', }) export class tablehttpexample { displayedcolumns = ['dbquery', 'titl...

laravel - Search using words in any order or combination and return row -

my table has row stored d1234 hex screw gs0090 o109 . can d1234 hex or screw gs0090 , return row. want able enter words in combination or order d1234 gs0090 or hex d1234 , have return row. how can done? edit: i'm using laravel 5.4, mysql database uses myisam engine $products = db::connection('it') ->table('it') ->join('units','units.code', '=', 's.code') ->join('vendors', 'vendors.code', '=', 's.code') ->where('s.deleted', '=', 0) ->where('vendors.deleted', '=', 0) ->where('s.description', 'like', '%'.$term.'%') ->orwhere('s.vendorcode', 'like', '%'.$term.'%' ) ->orwhere('s.vendordefaultcode','like', '%'.$term.'%') ->orwhere('vend...

javascript - Break _.each loop -

how break _.each() loop? tried _.every(), looping through data once. sample code: _.each([1,2,3,4,5],function(num){ if(num < 3) console.log(num) else{ console.log(num); return false; } }); output: 1 2 3 4 5 _.every([1,2,3,4,5],function(num){ if(num < 3) console.log(num) else{ console.log(num); return false; } }); output: 1 false you cannot escape functional foreach loop. consider using regular loop instead. const arr = [1,2,3,4,5]; (let = 0; < arr.length; ++i) { const num = arr[i]; if(num < 3) { console.log(num) } else { console.log('break out'); break; } }

tensorflow - {TypeError}Using a `tf.Tensor` as a Python `bool` is not allowed -

i create tfrecord of sequences, , trying parse using: context, sequence = tf.parse_single_sequence_example( serialized_example, context_keys_to_features, # {'label': fixedlenfeature(shape=[], dtype=tf.int64, default_value=none)} sequence_keys_to_features # {'token': fixedlensequencefeature(shape=[], dtype=tf.int64, allow_missing=false, default_value=none)} ) if try evaluate value of context , sequence , following: tf.contrib.learn.run_n(sequence) >> {'token': array([ 17, 10, 6, 878, 25, ... ])} same context: tf.contrib.learn.run_n(context) >> {'label': 1} but when try, evaluate tensor inside the dict, raises error: # next line raise error tf.contrib.learn.run_n(sequence['token']) # line tf.contrib.learn.run_n(context['label']) >> {typeerror}using `tf.tensor` python `bool` not allowed. use `if t not none:` instead of `if t:` test if tensor defined, , ...

ios - Firebase get child name by value and remove it -

my json looks this: users username1: "wwodh96yr3qs4n3gwdvq3olqffb2" username2: "rj6pzttlmsg222ouygwhtwpvhdg1" i "username1" key (auth.uid)! , if found want delete it, after delete looks this: users username2: "rj6pzttlmsg222ouygwhtwpvhdg1" . self.ref.child("users").queryorderedbyvalue().queryequal(tovalue: user?.uid).observe(.value, with: { snapshot in if snapshot.exists() { print("\(snapshot.value)") snapshot.ref.child(snapshot.value as! string).removevalue() // deleting every thing wrong! } else{ print("not found--") } self.ref.removeallobservers() }) } this code deleting in users. want delete specific user. first of all, appr...

Excel - Call a function within a function -

scenerio - have excel formula counts number of "yes" entries in column divides count count of "yes" entries in different column =countif('all project tasks'!ac203:ac236,"yes")/countif('all project tasks'!ab203:ab236,"yes") this works. however, need add criteria checks see if date in date column <= today , if so, should result "not started" instead of division result. so far have this: =if(d12<=today(),countif('all project tasks'!ac2:ac18,"yes")/countif('all project tasks'!ab2:ab18,"yes"),"not started") the "not started" part works in formula division part failing. receive 0 instead of decimal number using first formula above. i'm thinking i'm missing 1 piece cannot find is. you try storing results formulas in different cells, diving cells eachother

vue.js - Vue 2 + Vuex: Using state variables in computed property -

i have vuex instance couple variables: const store = new vuex.store({ state: { start_date: moment().startof('year').format("mm/dd/yyyy"), end_date: moment().format("mm/dd/yyyy") }, mutations: { changedate(state, date_obj) { state.start_date = date_obj.start_date state.end_date = date_obj.end_date } } }) and have main vue instance date properties inherited store : var employees = new vue({ el: '#employees', computed: { start_date() { return store.state.start_date }, end_date() { return store.state.end_date }, leads() { let filter_obj = { start_date: this.start_date, end_date: this.end_date } return this.fetch('potential_clients', filter_obj) } }, methods: { fetch(model, args=null) { return new promise((resolve, reject) => { console.log(resolve, reject) let url = "/" + model + "....

python - Custom PDF from scipy.stats.rv_continuous unwanted upper-bound -

Image
i attempting generate random probability density function of qso's of luminosity form: 1/( (l/l_b^* )^alpha + (l/l_b^* )^beta ) where l_b^*, alpha, , beta constants. this, following code used: import scipy.stats st loglbreak = 43.88 alpha = 3.4 beta = 1.6 class my_pdf(st.rv_continuous): def _pdf(self,l_l): #"l_l" in log l l = 10**(l_l/loglbreak) d = 1/(l**alpha + l**beta) return d dist_log_l = my_pdf(momtype = 0, = 0,name='l_l_dist') distro = dist_log_l.rvs(size = 10000) (l/l^* rased power of 10 since being done in log scale) the distribution supposed produce graph approximates this , trailing off infinity, in reality graph produces looks this (10,000 samples). upper bound same regardless of amount of samples used. there reason being restricted in way is? your pdf not normalized. integral of pdf on domain must 1. pdf integrates approximately 3.4712: in [72]: scipy.integrate import quad...

oracle - PL/SQL: ORA-04063: view "OPS$DTEPROD.DTE_BLMB_TRD_ACCT_VW" -

i have view, created (oracle) create or replace force view "ops$dteprod"."dte_blmb_trd_acct_vw" ("bb_trd_acct", "description", "ici_trd_acct") select rtrim(strbk_book_name) bb_trd_acct, rtrim(strbk_description) description, trading_acct ici_trd_acct spider.sp_struct_books@spdn b1 , dte_trading_acct substr(rtrim(strbk_book_name),1,2)=ltrim(rtrim(fits_trading_acct)) , strbk_last_update_date = (select max(strbk_last_update_date) spider.sp_struct_books@spdn b2 b2.strbk_book_number = b1.strbk_book_number) in package, when compile shows me error 328/117 pl/sql: ora-04063: view "ops$dteprod.dte_blmb_trd_acct_vw" has errors could please me find reason? thanks errors package body rates_2dte: line/col error -------- -------------------------------------------------...

ruby on rails - Can't get notification when password change using devise-neo4j -

i removed comment in config/initializers/devise.rb guide show not working. # send notification email when user's password changed config.send_password_change_notification = true this part of gemfile.lock devise (4.3.0) bcrypt (~> 3.0) orm_adapter (~> 0.1) railties (>= 4.1.0, < 5.2) responders warden (~> 1.2.3) devise-neo4j (2.1.1) bcrypt (>= 3.0) devise (>= 3.5.2) neo4j (>= 3.0.0) orm_adapter (~> 0.5.0) railties (>= 4.2) warden (>= 1.2.1)

javascript - How to reference an element using @ViewChild/@ContentChild when transcluded -

i following this cookbook on how create components dynamically @ run time. works splendidly, long element trying reference using @viewchild not transcluded (aka content projection in angular 2) in element. let me elaborate. have code: @component({ selector: 'module-landing', templateurl: './module-landing.template.html', entrycomponents: [travelheadercontentcomponent] }) export class modulelandingcomponent implements afterviewinit { @viewchild(contenthostdirective) contenthost: contenthostdirective; ngafterviewinit() { console.log(this.contenthost); } } my module-landing.template.html looks this: <some-other-component></some-other-component> <ng-template content-host></ng-template> so far, good. console.log() outputs object expected. however, need transclude content-host element within some-other-component , this: <some-other-component> <ng-template content-host></...

hibernate - JPA Criteria Join did not give me a list -

hello i'm doing advanced search query using criteria , have this criteriabuilder criteriabuilder = entitymanager.getcriteriabuilder(); criteriaquery<tuple> criteriaquery = criteriabuilder.createtuplequery(); root<event> eventroot = criteriaquery.from(event.class); join<event,community> communityjoin = eventroot.join("community", jointype.left); join<event,user> user = eventroot.join("user", jointype.left); join<event,device> device = eventroot.join("device", jointype.left); join<event,list<auditlog>> auditlogs = eventroot.join("auditlogs", jointype.left); i have can see one-to-many relation auditlog entity (mapped auditlogs). i'm doing selection this selections.add(user.alias("user")); selections.add(device.alias("device")); selections.add(auditlogs.alias("auditlogs")); i'm getting result tuple list query...

java - sql issue with parameter 6 -

hello guys i'm still new java programming. i have problem no value specified parameter 6. i'm still searching problem. can guys me? here's code if (newdata == true) { int p = joptionpane.showconfirmdialog(null, "do save?","insert",joptionpane.yes_no_option ); if(checkinputs() && imgpath != null && imgpath2 != null) { try { connection con = getconnection(); preparedstatement ps = con.preparestatement("insert mmis(id,name,condi,image,image2,price,buyfrom,date)values(?,?,?,?,?,?,?,?)"); ps.setstring(1, txt_id.gettext()); ps.setstring(2, txt_name.gettext()); ps.setstring(3, txt_condi.gettext()); inputstream img = new fileinputstream(new file(imgpath)); ps.setblob(4, img); inputstream img1 = new fileinputstream(new file(imgpath2)); ps.setblob(5, img1); ps.executeupdate(); ...

c# - .NET Core output directory does not include platform -

i working on .net core project on visual studio 2015. when build project (webapi project) see output being built bin\debug\net461 but when try debug program, seems msvs2015 expects running assembly bin\debug\net461\win7-x64 . edit error message : the debug executable 'd:\...\bin\debug\net461\win7-x64\addyourswebapi.exe' debug profile not exist. i find hard figuring how either tell vs run without platform dir(win7-x64), or either, build output include platform dir. please help.

Couchbase vs MongoDB in terms of ease of administration and maintenance -

as know both couchbase , mongodb document nosql stores. understand difference between both in terms of operational/administration complexity , maintenance. which 1 more suited deployments no dedicated resource available admin/maintenance.

angular - How to Use Observables to update displayed data on insert -

i decided ask here i've been looking @ google whole day answer can't seem understand on how implement it. basically, want every time insert data modal once closes auto update list of parent view. in past go setting timeout function upon researching i've stumbled upon observables . want know how can implement on current setup. here component.ts import { component } '@angular/core'; import { navcontroller, navparams, modalcontroller,fabcontainer } 'ionic-angular'; import { modalcreatenewdirectorypage } '../../pages/modal-create-new-directory/modal-create-new-directory'; import {popupuploadcsvpage} '../../pages/popup-upload-csv/popup-upload-csv'; import { beaconrestapiprovider } '../../providers/beacon-rest-api/beacon-rest-api'; import {modalshowphonebookdirectorypage} '../../pages/modal-show-phonebook-directory/modal-show-phonebook-directory'; import { observable } 'rxjs/observable'; import { asyncpipe } '@an...

javascript - Can I reference a param type in JSDoc @return? -

i document function return type depends on supplied parameter: /** * @param {*} x thing * @return {????} thing in array */ function arrayof(x) { return [x]; } is possible name or otherwise reference actual type of function param, can use specify return?

plot - unit length arrows() R -

wondering if there way make arrows unit length in r using function arrows(). doing following: x0<- c(results_15[(1:3479),1]) y0<- c(results_15[(3479:1),2]) x1<- (x0 + c(results_m_cos_20[,9])) y1<- (y0 - c(results_m_sin_20[,9])) arrows(x0, y0, x1, y1, length = 0.1, angle = 25, code = 2, col = "black", lty = 1, lwd = 1, xpd=true) results_m_cos , results_m_sin give me increases in x , y respectively, make arrows maintain same direction (so same cos:sin ratio), want arrows unit length. ideas on how this? or should using totally different function and/or package plot arrows?

android - Toolbar TextInputLayout EditText - lost HINT -

Image
please have problem second toolbar. i want have textinputlayout in toolbar, not want focusable. used filters. user can not type edittext. my code: <android.support.v7.widget.toolbar android:id="@+id/toolbar_2" android:layout_width="match_parent" android:layout_height="wrap_content" android:background="@color/colorprimary" android:theme="@style/themeoverlay.appcompat.dark.actionbar" app:layout_collapsemode="none" app:elevation="0dp" app:layout_scrollflags="scroll" app:popuptheme="@style/themeoverlay.appcompat.light"> <linearlayout android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical...

mysql - jQuery Custom app integration with Wordpress -

i created html/jquery app, running embedding within 1 of pages raw html. website has wishlist member plugin running. i need integrate app wordpress in such way, able save/retrieve json data in database, under current user, user can have access it. i still fresh in programming, , help/direction highly appreciated. i find answer myself, , wasn't difficult after all... create custom template page, needs php file: <?php /** * template name: custom name * */ ?> <!doctype html> <html <?php language_attributes(); ?>> <head> <meta charset="<?php bloginfo( 'charset' ); ?>" /> <!-- page title, displayed in browser bar --> <title><?php bloginfo('name'); ?> | <?php is_home() ? bloginfo('description') : wp_title(''); ?></title> <!-- add feeds, pingback , stuff--> <link rel="profile" href="http://gmpg.org/xfn/11...

c# - How to save the checkboxes as Key-value pairs in asp.net webforms -

i have sql server table id, key , value columns , in front end have bunch of checkboxes. need save checkbox selections database. know process save when there separate column each checkbox in table, but, values saved key example: test , value: 1 if checkbox selected. have used checkbox control this: <div class="form-group"> <div class="check"> <asp:checkbox runat="server" id="chkreviewsubmit" text="review/submit" /> <br /> <asp:checkbox runat="server" id="chkstatuschange" text="show status change options" /> <br /> </div> </div> how save checkbox selections key value pairs? can please provide me examples.

Android Studio open tabs not showing -

Image
android studio used display open files tabs not getting displayed (picture attached). how can bring ? just reference, used like

ios - TestFlight app crash on launch -

xcode 8.3.3 ios 10.3 "capabilities" includes icloud/cloudkit (i suspect irrelevant) app built archive , pushed app store delivery testing via testflight, downloaded via test flight iphone 7+ (and iphone 6) crashes on launch, receiving could not load inserted library '…idebundleinjection' because image not found full output on console in xcode when launched there: dyld: not load inserted library '/private/var/containers/bundle/application/4070e1c3-2e03-44ed-bf6d-9a496f980fca/appname.app/frameworks/idebundleinjection.framework/idebundleinjection' because image not found message debugger: terminated due signal 6 seems idebundleinjection shouldn't linked app delivered app store. others have seemed have similar problem when running tests xcode. any insights this?

html - how to make a whole row in a table clickable as a link? -

i'm using bootstrap , following doesn't work: <tbody> <a href="#"> <tr> <td>blah blah</td> <td>1234567</td> <td>£158,000</td> </tr> </a> </tbody> you using bootstrap means using jquery :^), 1 way is: <tbody> <tr class='clickable-row' data-href='url://'> <td>blah blah</td> <td>1234567</td> <td>£158,000</td> </tr> </tbody> jquery(document).ready(function($) { $(".clickable-row").click(function() { window.location = $(this).data("href"); }); }); of course don't have use href or switch locations, can whatever in click handler function. read on jquery , how write handlers; advantage of using class on id can apply solution multiple rows: <tbody> <tr class='clickable-row...

Google Places API: Cannot get review summary -

i followed instructions here , , tried following query: https://maps.googleapis.com/maps/api/place/details/json?parameters&extensions=review_summary&placeid=chij-uosvl6-woarn7jral3xigk&key=<my_own_key> , result doesn't contain review summary , looks this: { "html_attributions" : [], "result" : { "address_components" : [ { "long_name" : "...", "short_name" : "...", "types" : [ "street_number" ] }, ... ], "adr_address" : "...", "formatted_address" : "...", "formatted_phone_number" : "...", "geometry" : { "location" : { "lat" : ..., "lng" : ... }, ... } }, "icon" : "...", ...

ios - How to obtain reference to a View Controller from UITabBarViewController -

Image
edit: off base in approach. i'm trying pass data 1 vc another. source vc not controlled tab bar, can't reference destination vc through it. attempting reference destination vc thorough storyboard, data still nil on destination vc. i'm using core data , wish pass managedobjectcontext vc. here code: ...... { try self.managedobjectcontext.save() appuserid = user.userid! } catch { fatalerror("error: \(error)") } } } self.passmanagedobjectcontext() } func passmanagedobjectcontext() { let profiletableviewcontroller = uistoryboard(name: "profile", bundle: nil).instantiateviewcontroller(withidentifier: "profileviewcontroller") as! profiletableviewcontroller profiletableviewcontroller.managedobjectcontext = self.managedobjectcontext } ...

flash - ActionScript 3 - MovieClip Scale, set to 1 when scale is less than 1 -

i have movieclip of image , have applied transformgestureevent , working well, having issues when trying scale less 1. dont want scale less 1 put condition in transformgestureevent when tries scale less 1 scale gets reset 1...i hope makes sense. here snippet of code giving me trouble. if(event.scaley < 1.1 && floorplanmc.scaley < 1){ floorplanmc.scalex=prevscalex; floorplanmc.scaley=prevscaley; } and here full method: function zoomfloorplan (event:transformgestureevent):void{ mytimermodel.stop(); mytimermodel.reset(); mytimermodel.start(); var locx:number=event.localx; var locy:number=event.localy; var stx:number=event.stagex; var sty:number=event.stagey; var prevscalex:number=floorplanmc.scalex; var prevscaley:number=floorplanmc.scaley; var mat:matrix; var externalpoint=new point(stx,sty); var internalpoint=new point(locx,locy); floorplanmc.scalex *= event.scalex; floorplanmc.scaley *= eve...

Ignore style cascading in React Native -

context: i using reactnavigation implement navigation on react native app. views far have no styles defined them, , fine if access them directly, without routing. when accessed through library's stacknavigator , however, extremely distorted, point components collapse one. suspect happening due cascading of navigator's styling. question: is there way disable style cascading particular component in reactnative?

trouble with writing regex java -

string consists of 2 distinct alternating characters. example, if string 's 2 distinct characters x , y, t xyxyx or yxyxy not xxyy or xyyx. but a.matches() returns false , output becomes 0. me understand what's wrong here. public static int check(string a) { char on = a.charat(0); char = a.charat(1); if(on != to) { if(a.matches("["+on+"("+to+""+on+")*]|["+to+"("+on+""+to+")*]")) { return a.length(); } } return 0; } use regex (.)(.)(?:\1\2)*\1? . (.) match character, , capture group 1 (.) match character, , capture group 2 \1 match same characters captured in group 1 \2 match same characters captured in group 2 (?:\1\2)* match 0 or more pairs of group 1+2 \1? optionally match dangling group 1 input must @ least 2 characters long. empty string , one-character string not match. as java code, be: if (a.match...

android - Open Link When Clicked on CardView -

my app uses asynctask fetch data webapi , displays them in recycler view. what intend open corresponding link when clicked on card view in browser installed on phone. i tried solutions mentioned app seems crash. if use sendbroadcast instead doesn't anything. my code recycler view adapter : @override public void onbindviewholder(viewholder holder, int position) { final news news = listnews.get(position); holder.tvtitle.settext(news.gettitle()); holder.tvdesc.settext(news.getdescription()); picasso.with(getcontext()).load(news.geturltoimage()).into(holder.ivnews); holder.newslayout.setonclicklistener(new view.onclicklistener() { @override public void onclick(view view) { intent intent = new intent(intent.action_view, uri.parse(news.geturl())); context.startactivity(intent); } }); } the app works fine , loads news items when click on news item crashes stopped responding message. you shou...

sql server - Storing SQL Table Data -

i using mvc entity framework , have table tracks daily events in hotel atmosphere. these events change daily such cleans room , time of cleaning. table fine save copy of table on daily basis. have read in forum serializing list of table entries not idea ( how store list in column of database table ). how go saving table data on daily basis if not using list of table entries? this units class/table public class units { [key] [required] public int unitid { get; set; } public int unitnumber { get; set; } public string unittype { get; set; } public string status { get; set; } public bool checkout { get; set; } public bool isempty { get; set; } public employees housekeeper { get; set; } public datetime? cleanstart { get; set; } public datetime? cleanend { get; set; } public bool isclean { get; set; } public employees laundry { get; set; } public datetime? laundrytime { get; set; } public bool islaund...

teamcity - Forward slash "/" in REST URL? -

i using rest team city: https://confluence.jetbrains.com/display/tcd10/rest+api#restapi-build_artifacts to download artifacts. need download artifacts latest successful build specific branch. currently works specific branch called (that have successful tc builds): mybranch http://tchost/httpauth/app/rest/builds/buildtype:mybuildconfigid,branch:(mybranch)/artifacts/archived but fails specific branch called (that have successful tc builds): prefix/mybranch http://tchost/httpauth/app/rest/builds/buildtype:mybuildconfigid,branch:(prefix/mybranch)/artifacts/archived i think because of forward slash "/" in latter case. need able create branches forward slashes. how create valid rest url "/" in branch name?

mysql - PHP - broken image displaying from database -

Image
every time user submits picture "profile pic" display "broken image" , noticed when physically insert image mysql data base , display it, works , size of file changes "blob - kib" instead of mb. when insert same image database using "upload file", image turns "blob mb" , doesn't display on website. saw post , said remove "addslashes" variable , did still didn't work. wan't display image database submitted user. works when physically insert database without file if one, doesn't work. here screen shot of database structure, upload file, , retrieving file. php upload file session_start(); if(empty($_files) && empty($_post) && isset($_server['request_method']) && strtolower($_server['request_method']) == 'post') { //catch file overload error... $postmax = ini_get('post_max_size'); //grab size limits... echo "<p style=\"color: #f0...

twitter - Error importing Tweepy with Python -

i've installed tweepy , have no problem "import tweepy" being in code. when try use in tweepy, however, i'm faced following error: "importerror: cannot import name 'oauthhandler'" tweepy import oauthhandler consumer_token = 'xxx' consumer_secret = 'yyy' auth = tweepy.oauthhandler(consumer_token, consumer_secret) all solutions on stackoverflow try this, still not work me tweepy.auth import oauthhandler consumer_token = 'xxx' consumer_secret = 'yyy' auth = tweepy.oauthhandler(consumer_token, consumer_secret) i bet file named tweepy.py or there's file/package nearby same name python tries import oauthhandler wrong location. try rename file, can change code to: import tweepy print(tweeps) to check path , insure it's correct.

Easy way to submit an array field with Spring MVC forms? -

i have form list of nested fieldsets corresponding collection of objects, backed form object server-side. fieldsets can added or removed client-side. want submit form without caring object indices or sparse lists in command object. here's controller method code: @postmapping("/foobar") public string dopost(foobarform form) { //... } in php, rails etc it's easy: <input name="prop[]"> , , automatically populate $_post["prop"] values. working spring mvc, tried these things: <input name="prop[]"> - doesn't work saying invalid property 'prop[]' of bean class [...]: invalid index in property path 'prop[]'; nested exception java.lang.numberformatexception: input string: "" <input name="prop"> - not bind list-typed bean property, when multiple fields present. <input name="prop[${i}]"> - implies hassle sparse list , index handling, both client-si...

Java - Scene Builder - User input in TextField and ComboBox disappears after switching a scenes -

i have few scenes in java project , 1 problem don't know how solve. first scene called "zadanie". there textfields , comboboxes in first scene called "zadanie". so, can see in image, wrote numbers in textfields , choosed options in comboboxes. switched on other scene clicking on "vypočítať" (button up). , switched on first scene "zadanie", in textfields , comboboxes gone. back on first scene "zadanie". please give me example of code or how keep in first scene. thank you. the problem when switch screens, object represents screen disposed of. variables such user input disposed of. when switch screen, it's different object of same type. means values of variables such user input freshly instantiated/initialized. solution: create global variables (for example, variables in main, should use different classes programming practices sake) store information. when user clicks switch screens, before screen switched (unloade...