**** BEGIN LOGGING AT Wed Dec 30 02:59:59 2015 Dec 30 03:01:25 AmR|EiSa: what aspect of it are you asking about? Dec 30 03:02:38 AmR|EiSa: well, it should gives you some kind of id. if you feel lucky it will be imei ) Dec 30 03:02:50 I'm not java coder and I don't have tools for debug java code right now, So I want know if it's right code or have some bugs ? Dec 30 03:03:15 AmR|EiSa: If you're going to be writing a decent amount of Java code, I recommend spending some time setting up Android Studio Dec 30 03:03:18 AmR|EiSa: did you try compile it/ Dec 30 03:03:36 yes Dec 30 03:04:12 vigilancer: it's build fine but Qt Creator 3.6.0 like I think not debug java code. Dec 30 03:04:29 if final method is the only one you need not to extend Activity Dec 30 03:04:46 CedricBeust_: I Do that right now I download it. Dec 30 03:05:11 vigilancer: K Dec 30 03:06:48 AmR|EiSa: but to get system service you need context.. so.. dunno. don't make it static and startActivityForResult i guess Dec 30 03:15:47 Fun Statistics: 31% of the code in the average Google app lives in the com.google.analytics package. Alone this code is equal to the amount of code that was in Quake 3. Dec 30 03:16:12 The YouTube app has as much code as CryEngine 2, Age of Empires Online (backend and frontend), or an F-22 Raptor Jet (all chips and systems combined) Dec 30 03:16:52 All Google apps combined have as much code as Windows 7 Dec 30 03:18:06 Most of which is duplicated. Based on a dump a few months ago when Google accidentally published unobfuscated versions of their apps on the play store, as much as 60% of the code of the Google apps is shared between all of them, and could be put into libraries. Code shared between 2 or more of them is even more. Dec 30 03:18:29 The Official YouTube app is, also, on average 20 times larger than the average Android or iOS app. Dec 30 03:18:46 End of fun statistics. Dec 30 03:19:07 and in more important news, Lemmy Kilmister is dead Dec 30 03:19:09 sorry, carry on Dec 30 03:19:22 'news' from more than 24 hours ago... Dec 30 03:19:23 nah, I don’t have any fun statistics anymore right now Dec 30 03:19:46 I didn't know! Dec 30 03:19:59 just came home and it was on the front of the news paper outside my door Dec 30 03:20:16 ah, okay. Dec 30 03:20:18 news... paper? Dec 30 03:20:43 And I just read a thread on /r/Android of someone complaining why they couldn’t install more than 6 apps on a Moto E, as Google Apps take 1.6 Gigabytes of storage Dec 30 03:20:54 On a system with only 1.6 Gigabytes of /data Dec 30 03:21:18 Leeds: yeah, I'm old school... Dec 30 03:21:30 Newspapers are awesome. Dec 30 03:21:35 Their battery is never empty! Dec 30 03:21:41 Nonsense, they no longer make newspapers Dec 30 03:21:42 1.6GB seems excessive - but anyway, that's because you get two copies of all the google apps, the original one in /system and the updated ones in /data Dec 30 03:21:42 they have no DRM, you can just copy articles Dec 30 03:22:02 Leeds: I had an idea on how to fix that, too – but my idea only works if no obfuscation ever happens. Dec 30 03:22:09 deduplication on system level. Dec 30 03:22:43 if you install an update, and an older version lives on /system, Android would only store the diff on /data Dec 30 03:22:48 my S4 is full and I have no idea of what to delete. going to clean it as soon as my montly buss ticket runs out Dec 30 03:22:51 doesn’t work with obfuscation, though Dec 30 03:23:33 anyone konws how to find the shit that takes all the place, btw? Dec 30 03:23:37 never mind, this is dev Dec 30 03:23:46 Yes, remove everything from Google, Dec 30 03:23:53 then install only the stuff you actually need. Dec 30 03:24:24 Do you have beta groups of your apps that you have to administrate? if not, you can throw out G+ Dec 30 03:25:20 I do :/ Dec 30 03:25:45 or, they are pretty damn static. I guess I could do without the app Dec 30 03:26:13 youtube app is 20x bigger than average? Dec 30 03:26:26 Yup. Dec 30 03:26:27 that's the problem... nothing is Dec 30 03:26:40 Average is around 50k, YouTube app is 970k Dec 30 03:26:46 970k? Dec 30 03:26:48 (Lines of code) Dec 30 03:26:51 oh Dec 30 03:26:57 thought they're talking final apk size Dec 30 03:27:01 there was a few months an unobfuscated build on the play store Dec 30 03:27:06 like I said, when apps get large, cost of runtime libraries goes down Dec 30 03:27:29 yeah, but when 30% of the app lives in com.google.analytics, then you know where the bloat is going Dec 30 03:27:42 30% in analytics sounds very wrong Dec 30 03:27:48 300k lines of code? that's pretty bogus Dec 30 03:28:02 eh, sorry, Dec 30 03:28:08 30% of bytes in analytics, Dec 30 03:28:13 970k LOC Dec 30 03:28:16 different metrics. Dec 30 03:28:27 analytics probably compresses worse Dec 30 03:28:27 basically, everything's inflated to make stuff seem worse than it is Dec 30 03:28:41 anyway, 970k loc doesn't sound like much Dec 30 03:28:45 Well, that’s still a lot. Dec 30 03:28:51 my media app has like 300k loc and that's only from source + apklib Dec 30 03:28:53 especially for such an app. Dec 30 03:28:57 if you include libraries, which seems to be the case here Dec 30 03:29:02 that's easily well over 500k lines Dec 30 03:29:07 I agree with pfn Dec 30 03:29:07 Well, that’s another issue. Dec 30 03:29:15 It’s not an issue with the app itself, Dec 30 03:29:22 but with the way the ecosystem works. Dec 30 03:29:30 We have no system-provided libraries. Dec 30 03:29:38 All libraries are statically compiled into the apps. Dec 30 03:29:54 We have to deal with lots of boilerplate code, because of ancient versions of Java Dec 30 03:29:54 so Android sucks and long live iOS? Dec 30 03:30:02 No, iOS doesn’t do it better. Dec 30 03:30:09 I was just trolling :) Dec 30 03:30:17 firefoxOS FTW! Dec 30 03:30:46 $ find . -name '*.java' | xargs wc -l | tail -1: 70969 total Dec 30 03:30:49 hmm Dec 30 03:30:57 where'd all my loc go, it used to be close to 300k... Dec 30 03:31:01 For libraries which use semantic versioning (aka, major.minor.patch means any version with major.minor identical is completely ABI compatible), it would be nice to see deduplication Dec 30 03:31:18 pfn: did you accidentally do it before while including the build/ folder? Dec 30 03:31:21 justJanne, you'd still have tons of boilerplate in java8 Dec 30 03:31:26 yeah, but less. Dec 30 03:31:31 not much less Dec 30 03:31:35 especially if you work lots with lambdas Dec 30 03:31:38 java8 still doesn't have properties Dec 30 03:31:46 True. Dec 30 03:31:47 with lambdas, you save maybe 4 lines per lambda Dec 30 03:31:56 4 lines per 1-line function ;) Dec 30 03:31:58 gah, lambdas suck so hard in java... Dec 30 03:32:01 class decl, method decl, 2 closing braces Dec 30 03:32:04 that’s quite a lot. Dec 30 03:32:13 depends on how much you're doing in each lambda Dec 30 03:32:15 the cost is amortized Dec 30 03:32:19 Yup. Dec 30 03:32:47 also depends on how much you re-use functions Dec 30 03:33:08 java also lacks type inference, which is among the things that makes coding such a bear Dec 30 03:33:33 well, it has type inference, but it doesn’t support auto typing Dec 30 03:33:40 unless you use lombok’s val type Dec 30 03:33:48 justJanne, and I always include build/ in loc metrics Dec 30 03:33:51 (which just abuses the compiler for that) Dec 30 03:33:56 it's compiled, it's a loc count Dec 30 03:34:00 well, pfn, that will double your size then. Dec 30 03:34:05 no, it doesn't Dec 30 03:34:14 it's about 1500 lines per R.java Dec 30 03:34:18 but that's not that many Dec 30 03:34:32 I’ll get metrics for my apps... Dec 30 03:34:33 and there's Manifest and whatnot, but that's nothing Dec 30 03:35:18 20320 when clean... Dec 30 03:35:37 this is probably just me... but I feel c# did lambdas so much better that it was terrible to go back to java Dec 30 03:35:50 40310 with build/ Dec 30 03:35:55 that’s doubled. Dec 30 03:36:13 eh, c# delegates are just weird Dec 30 03:36:20 how? Dec 30 03:36:34 @pfn: for QuasselDroid, it doubles the LOC count Dec 30 03:36:38 syntax is awkward Dec 30 03:36:39 if you add build/ Dec 30 03:37:00 justJanne, that's a bit odd, it shouldn't, unless gradle is copying sources Dec 30 03:37:02 pfn: I think it's way better than the java one, but could be just because that's what I tried first Dec 30 03:37:10 Eplebit, well, it's better than java, yes Dec 30 03:37:14 Eplebit, I don't disagree Dec 30 03:37:25 but delegate syntax in c# isn't all that great either Dec 30 03:37:37 that could be Dec 30 03:37:42 well, it has the R.java from all libs Dec 30 03:37:54 justJanne, yeah, about 1500 lines for each R.java Dec 30 03:37:58 depending on how many you have Dec 30 03:38:06 that’s 19990 lines for a project with very few libs, Dec 30 03:38:27 justJanne, the size is coming from somewhere else, not R.java I would think Dec 30 03:38:49 nope, I checked. Dec 30 03:39:15 $ find . | grep "R\.java" | xargs cat | wc -l Dec 30 03:39:21 19964 Dec 30 03:39:26 oh, I see where I lost loc in this app, I switched a bunch of apklib dependencies to aar Dec 30 03:39:41 analytics and a video player component Dec 30 03:39:44 And that’s how you lost 50% LOC Dec 30 03:40:00 50% in your app, it was a much smaller margin in mine Dec 30 03:40:25 well, you said you went from 300k to 70k Dec 30 03:40:37 yeah, it wasn't from R.java Dec 30 03:41:28 hmm Dec 30 03:41:36 from intermediate generated files? Dec 30 03:42:06 $ find . -name 'R.java' | xargs wc -l 2> NUL | tail -1: 12394 total Dec 30 03:42:15 hm Dec 30 03:42:22 not that much Dec 30 03:42:28 less than for mine Dec 30 03:42:29 $ find . -name '*.scala' | xargs wc -l 2> NUL | tail -1: 5820 total Dec 30 03:42:31 heh Dec 30 03:42:41 that is my own app, and 5800 lines? how the hell is my shit that long Dec 30 03:43:40 must go on expressiveness binge Dec 30 03:44:34 I’d think if RxJava/RxAndroid, Butterknife, Guava and co would be deduplicated based on semantic versioning in Android, we could save a lot of space with each app. Dec 30 03:44:50 you can't dedupe that way Dec 30 03:44:57 unless you install the library into each device first Dec 30 03:45:00 which is undesirable Dec 30 03:45:04 Not necessarily. Dec 30 03:45:16 You could have Android automatically pull the lib from maven. Dec 30 03:45:29 the app puts in its manifest Dec 30 03:45:29 Think of all the bugs Samsung would introduce! Dec 30 03:45:49 you don't need semantic versioning to do that Dec 30 03:45:50 Dec 30 03:46:05 How does that work with offline devices? Dec 30 03:46:07 well, you do, to make sure that it could say 3.7.4 and 3.7.5 have the same ABI Dec 30 03:46:24 you should not automatically upgrade the library version an app uses Dec 30 03:46:42 JakeWharton, can download from play store, can download from a repository Dec 30 03:46:45 Well, that’s one issue. offline devices. But even that could be solved, by packaging a version of the library in the apk, and stripping it from the apk upon install if the same lib is already in the system Dec 30 03:46:53 3.7.4 and 3.7.5 should not be treated as the same thing Dec 30 03:47:07 (And the playstore would only distribute with the apk stripped from libs) Dec 30 03:47:17 What if I sideload? Dec 30 03:48:03 JakeWharton: that’s what I just explained one solution for: You’d package a version of the lib in the apk, if the same version exists in the system, it’s removed from the apk during install. Dec 30 03:48:05 JakeWharton, distribute an all-inclusive apk, or assume the sideloader has internet access Dec 30 03:48:29 The playstore would remove all libs automatically, and let the system just load from a central repository. Dec 30 03:48:36 anyway, interesting concept, but not necessarily trust-worthy Dec 30 03:48:45 especially when it comes to determining which repository to download artifacts from Dec 30 03:48:59 if a library specifies that in major.minor.patch the .patch always only fixes bugs, without changing the api, you could even dedupe similar releases Dec 30 03:49:01 as it is, people can't decide if they want to put shit on jcenter, central, jitpack, github.io, etc. Dec 30 03:49:12 Well, pfn, that’s why Google would provide one central one Dec 30 03:49:42 justJanne: what if there's two versions of the same lib with the same coordinates? Dec 30 03:49:46 (and that’d also be how the installer knows if .patch releases are compatible or not) Dec 30 03:50:06 JakeWharton: that’s one issue, but as Google would control the central repository, they could prevent that. Dec 30 03:50:15 similar to how app IDs are unique Dec 30 03:51:01 think about how many apps use Guava, or AppCompat, or so on. You’d save a lot of storage without losing any functionality. Dec 30 03:51:24 true Dec 30 03:51:28 hmm, I need a usb3 cable or something, my type C -> A -> A to A extension makes my phone "charge slowly" Dec 30 03:51:34 Obviously, if you wonder if this sounds familiar, this is practically what it looks like on most linux systems. Dec 30 03:51:57 I'm not disagreeing in the premise, but the implementation is unlikely to happen because of all the problems. Dec 30 03:52:09 One central repository, packages specify dependencies (commercial packages come with prepackaged dependencies), deduplication of .patch releases, etc Dec 30 03:52:24 JakeWharton: it would solve one huge issue currently, though: Dec 30 03:52:28 there's no deduplication there, other than shared libraries Dec 30 03:52:41 If a bug in a library is found, it could be fixed globally. Without requiring recompilation. Dec 30 03:52:51 Quick question(I think it's quick): Is there an easy way to hide API keys in public github repos? Dec 30 03:52:56 until said fix introduces a regression Dec 30 03:53:02 keheira, don't check it in... Dec 30 03:53:13 keheira: put the api key into a separate gradle file, which you don’t check in? Dec 30 03:53:19 or put them into environment variables Dec 30 03:53:28 separate gradle file, properties file, etc. tons of choices Dec 30 03:53:30 (environment variables work better with travis, too) Dec 30 03:53:46 justJanne: that's a great attack vector Dec 30 03:53:59 Indeed it is. And it’s a troubling one. Dec 30 03:54:05 I mean I have the variables in my string file and I'm pulling from it...is that the same as your suggestion? Dec 30 03:54:22 But, JakeWharton, it’s already a great vector today Dec 30 03:54:34 keheira, yes Dec 30 03:54:38 I could just introduce malware into the version of apache HTTP Utils today, Dec 30 03:54:45 and wait for people to recompile their apps, Dec 30 03:54:51 and also have done the same Dec 30 03:54:54 coolio. Thanks Dec 30 03:54:59 And ship them, and everyone update Dec 30 03:55:00 (Who checks the changelog of the libs they depend on?) Dec 30 03:55:33 It's irrelevant. They manually upgraded. Dec 30 03:56:04 Yeah, at that point you’d have to either allow cross-version dedupe only for trusted parties, Dec 30 03:56:06 or not at all Dec 30 03:56:18 cross version dedupe should not be allowed at all Dec 30 03:56:27 winsxs is an example to learn from, not avoid Dec 30 03:56:34 microsoft has perfected the art of backward compatibility Dec 30 03:57:16 fixing issues in a library that’s statically compiled into systems, like the recent Java deserialization issue where one single library had a bug, and thousands of programs depended on it, is problematic, though Dec 30 03:57:37 imagine if all projects that used OpenSSL had compiled it statically, Heartbleed still wouldn’t be fixed anywhere. Dec 30 03:58:23 there is probably no consumer system in existence that has been regularly updated, yet still be able to run a binary 40 years old Dec 30 03:58:25 it’s the danger, but also the advantage with shared libraries. Dec 30 03:58:47 eh, actually, you do that all the time. Dec 30 03:59:10 A bunch of GNU coreutils are decades old. With some BSD coreutils, actually you might reach 40 years Dec 30 03:59:20 no, not /source/ packages Dec 30 03:59:22 actual binaries Dec 30 03:59:37 let me try the original version of grep, brb Dec 30 03:59:45 a 40 year old binary of `ls` from svr4 is not going to run on any system today Dec 30 04:00:41 erm, I think I added a decade, 30 years Dec 30 04:00:42 whatever Dec 30 04:00:45 I think my uni still has somewhere a system running Unix 4 Dec 30 04:01:04 svr4 has not been regularly updated Dec 30 04:01:10 True indeed. Dec 30 04:01:32 So, I'm trying to use RecyclerView for the first time, and it's embedded inside a Fragment in an Activity with a ViewPager. There is a Toolbar above the ViewPager. Dec 30 04:01:52 What I'm finding is that if I scroll on the RecyclerView, the Header above the ViewPager gets pushed up a bit, seemingly the size of the top toolbar. Dec 30 04:02:04 And then if I switch pages, it remains scrolled, even on pages that do not scroll. Dec 30 04:02:18 scrolling a recyclerview does not move anything outside it Dec 30 04:02:20 So, basically my Toolbar remains scrolled slightly off the screen indefinitely. Dec 30 04:02:23 unless you're using something like a coordinatorlayout Dec 30 04:03:15 justJanne, the point I was making was, you can run most any DOS executable from 1985 on a windows10 machine today, and as long as it doesn't make direct bios calls, it probably still works Dec 30 04:03:19 It is in fact inside a Coordinator Layout. Dec 30 04:03:27 pfn: eh, not really. Dec 30 04:03:32 Both are. Dec 30 04:03:40 Since Windows 7, support for 16-bit emulation was abandoned Dec 30 04:03:43 TheDracle, then you need to provide much more details Dec 30 04:03:52 on windows 7 64 or above, you can’t run them anymore Dec 30 04:04:06 is that so Dec 30 04:04:12 * pfn still on win7, x64 though Dec 30 04:04:13 * pfn shrugs Dec 30 04:04:20 Hm, I think perhaps it isn't needed. Dec 30 04:04:30 pfn: Agreed, Microsoft has a very impressive record in that area Dec 30 04:06:04 CedricBeust_, about earlier, indeed, maybe if I feel like taking up kotlin for fun, I'd consider it Dec 30 04:06:11 that doesn’t solve the original issue – 1.6 GB of GApps on recent devices, and apps getting larger and larger, with storage sizes long stagnant – though. Dec 30 04:06:13 hard to say though Dec 30 04:06:17 pfn: Great Dec 30 04:06:31 Are any of you at 32C3? Dec 30 04:07:35 no Dec 30 04:09:18 justJanne: buy a new phone that's all Dec 30 04:10:01 vigilancer: I’m a dev, I’m more concerned about the millions of people out there on 8GB Moto Gs, or 8GB Samsung Galaxy SIII mini Dec 30 04:10:19 Hell, those two phones are /still/ in the top #5 most sold in many countries this year Dec 30 04:10:29 sucks to be them Dec 30 04:10:29 pin, Thanks for the tip about the CoordinatorLayout, it was just scroll flags that were set on my toolbar within it. Dec 30 04:10:49 are you conserning about auto update of you dependencies with possible regression bugs? Dec 30 04:11:12 always Dec 30 04:11:33 justJanne: Just FYI, I find your out-of-the-box thinking (pun intended) interesting Dec 30 04:11:37 justJanne: ^ Dec 30 04:11:48 Eh, it’s not out-of-the-box Dec 30 04:11:55 it’s literally stealing from an existing system Dec 30 04:12:05 I understand, it was an easy pun Dec 30 04:12:38 Extending maven resolution to runtime and not just packaging is interesting Dec 30 04:12:40 also, vigilancer, I’m more concerned about users like the one on /r/android today who complained that the stock install, with only updates of non-removable apps, already leaves only 400MB for apps on the Moto E Dec 30 04:12:43 yeah yeah it's rich. but in current draft it's unusable imho Dec 30 04:13:09 the moto e is like an $80 phone Dec 30 04:13:20 mostly because devs concerning, but google dont Dec 30 04:13:21 Yes, which means lots of people are using it. Dec 30 04:13:22 having apps at all is... a blessing Dec 30 04:13:31 At least in Europe most people are on Prepaid Dec 30 04:13:52 which means they won’t end up buying 900$ phones like the iPhone (price here is around that) Dec 30 04:14:00 but instead phones like the moto G (200$) Dec 30 04:14:08 or moto E (around 140$) Dec 30 04:14:11 There are a lot of Android phones out there with minimal specs, emerging markets, etc... A lot. We tend to forget that if you live in the US or an industrialized country. Dec 30 04:14:44 And that’s just Europe. as CedricBeust_ said, especially in emerging markets it’s often even cheaper devices. Dec 30 04:15:09 And then most devs, thanks to the Nexus program, forget that most people don’t buy that high end devices. Dec 30 04:15:28 integrating protify into a run profile in intellij is the best thing ever... Dec 30 04:16:24 you should make a small intelliJ addon, so it automatically shows you before you press run if it will be able to instant-run, or not ;) Dec 30 04:16:33 why would i do that Dec 30 04:16:36 I don't instant-run Dec 30 04:16:37 :p Dec 30 04:16:47 well, I meant profity with instant-run Dec 30 04:16:52 I can always protify Dec 30 04:16:58 Always? Dec 30 04:17:02 * justJanne is amazed Dec 30 04:18:26 justJanne: you think it's profitable idea? lots of poor people with cheap devices.. Dec 30 04:18:41 vigilancer: and lots of rich people with cheap devices. Dec 30 04:19:40 my family’s an example for that. Europe, upper class, our friends own companies, or are millionaires, we live in the same street as the governor of our state – everyone we know uses SGSIII mini or similar devices, many even on Samsung Galaxy Ace. Dec 30 04:19:47 * vigilancer thinking Dec 30 04:20:18 justJanne, pretty much, only manifest changes and some resource changes prevent it Dec 30 04:20:21 Only below 25 people are actually on more recent devices, and of those only the few who are in compsci or similar professions care about recent versions Dec 30 04:20:54 I don’t think I’ve ever seen anyone run post-Jellybean except for my university’s compsci students Dec 30 04:21:08 It’s really bad. Dec 30 04:21:37 And then people complain why nothing runs on the Samsung Galaxy Ace they bought last year (!) Dec 30 04:22:08 It’s so weird, they really cheap out on the weirdest things. Dec 30 04:22:16 Have 2 or 3 BMWs, but a Galaxy Ace Dec 30 04:23:31 is there a chance they will cheap out on apps? Dec 30 04:24:00 everybody cheaps out on apps Dec 30 04:27:17 yup, everyone cheaps out on apps. Dec 30 04:27:21 Why Ndk is poor ? Dec 30 04:27:26 Although, sometimes, they actually buy stuff. Dec 30 04:28:13 justJanne maybe Android N , they will allow you to completely uninstall apps - like Windows Phone Dec 30 04:28:57 i'd rather the phone came with nothing, then just add gmail, pretty much it for me Dec 30 04:30:35 g00s: well, I’d love to see that, too. Dec 30 04:30:52 But with SecurityNet, it seems like Google is actively trying to punish anyone who wants to remove GApps Dec 30 04:30:56 for no added use Dec 30 04:31:13 (as you can still do system-less root, and, with root, just manipulate things at runtime) Dec 30 04:31:20 minimum level of expected compliance on devices Dec 30 04:34:47 Oh, I know why Android Pay tries to use SecurityNet: They don’t use any hardware, Dec 30 04:34:56 but the whole card and token data is purely done in software Dec 30 04:35:18 hahaha, trying to keep that secure is going to be fun. Dec 30 04:35:49 I bet we’ll see apps soon that use the known root exploits on samsung devices to get to this data. Dec 30 04:42:36 even if done in hardware, there's no protecting that data if you have root access on the phone Dec 30 04:42:37 no matter what Dec 30 04:43:10 the new AndroidKeyStore stuff is partially good for that Dec 30 04:43:24 and it should be protected behind hardware Dec 30 04:43:35 but whether that's usable for android pay stuff Dec 30 04:43:36 * pfn shrugs Dec 30 04:44:10 well, in hardware would allow protection Dec 30 04:44:30 there are hardware modules that allow you to only tell it to sign, or decrypt a message, Dec 30 04:44:34 and to get the public key, Dec 30 04:44:45 yes, that's the AKS mechanism added in android 4.3 Dec 30 04:44:45 but the private key is always stored only in the module Dec 30 04:44:49 and android pay is used that Dec 30 04:44:52 er, uses that Dec 30 04:44:59 Well, according to Google, it doesn’t. Dec 30 04:45:10 Google Wallet did, that’s why it worked on so few phones Dec 30 04:45:21 no, google wallet had a separate thing that was on the secure element Dec 30 04:45:24 Android Pay implements the same feature in software, according to what Google told the media Dec 30 04:46:16 the card features are implemented in software Dec 30 04:46:23 all cryptographic functions are protected behind hardware Dec 30 04:47:06 well, they /can/ be, depending on whether the device has hardware protected crypto storage Dec 30 04:47:08 If that’s true, and the media just misinterpreted what Google said, than that’s at least better. Dec 30 04:47:25 AKS tries to use hardware crypto vaults if available Dec 30 04:47:25 ah, yeah. The issue with GWallet was that it only worked on devices with protected crypto. Dec 30 04:47:28 otherwise it's just software Dec 30 04:47:41 google wallet required a secure element in the SIM or whatnot Dec 30 04:47:51 Well, then that explains the issue the payment processors have. Dec 30 04:48:03 Using a software keystore shouldn’t be done, EVER. Dec 30 04:48:09 GMS now has that feature to detect if tampered Dec 30 04:48:16 and this only applied to the original google wallet that shipped with android 4.0 Dec 30 04:48:17 Yeah, we talked about that. Dec 30 04:48:27 google wallet dropped the secure element requirement shortly after Dec 30 04:49:03 man, all my older phones feel so much smaller everytime I handle them (6p -> moto x -> previous moto x -> galaxy nexus -> droid, etc.) Dec 30 04:49:09 yeah Dec 30 04:49:14 same here Dec 30 04:49:23 Ideos X3 -> Moto G -> Moto G 2 Dec 30 04:49:42 although every time my fingers started hurting more and more, and I started using the phone less and less Dec 30 04:49:51 the moto G was already impossible to use with one hand Dec 30 04:50:13 I should flash my galaxy nexus back down to 4.2 Dec 30 04:50:23 so I have a wider array of versions to test on Dec 30 04:52:00 i'm about to put minSdk=19, no need for that :D Dec 30 04:52:17 How many days does it take to learn android development? Dec 30 04:52:27 How many days to become android developer? Dec 30 04:52:28 42 Dec 30 04:52:34 42 days? Dec 30 04:54:13 7 days Dec 30 04:54:30 Really? Dec 30 04:54:44 Android development is that easy? Dec 30 04:54:52 actually you can do it in 24 hours Dec 30 04:55:22 24 hours? How? Dec 30 04:55:38 Easy guys, shibly's probably not getting the sarcasm Dec 30 04:55:56 thosehttp://www.amazon.com/Android-Application-Development-Yourself-Edition/dp/0672334445 Dec 30 04:56:01 oops http://www.amazon.com/Android-Application-Development-Yourself-Edition/dp/0672334445 Dec 30 04:56:12 Eh, shibly, it depends. Dec 30 04:56:27 Writing an app, or becoming a dev, takes only hours or days. Dec 30 04:56:32 Becoming good at it... Dec 30 04:56:34 Is years. Dec 30 04:57:26 Like always, writing something that barely runs, is easy, mastering the task takes a long time, and is less about "Android dev", and more about understanding programming as a whole. Dec 30 04:57:37 shibly: What's your background? Dec 30 04:57:49 PHP,mysql, java, python Dec 30 04:57:57 c,c++ Dec 30 04:58:41 And what do you want to do? Master Android to the point where you understand everything, and can write everything? Just write a simple app? Dec 30 04:58:55 (Cause, as I said, that's very different time scales) Dec 30 04:59:15 I want to become master Dec 30 05:02:04 lol "Oh come on. I can bolt lettuce onto bacon but that doesn't make it a salad. It's not a fair comparison." Dec 30 05:03:10 Yup, it's like the difference between heating up microwave food and being a chef with 5 Michelin stars. Dec 30 05:03:30 Is netbeans good for android development? Dec 30 05:03:57 shibly: No. Use Android Studio. Dec 30 05:05:36 Also, become familiar with the Android javadocs, they're often the best (and only) documentation of the APIs. Dec 30 05:06:35 And then there are lots of third-party libraries that will make your life a lot easier, like ButterKnife or JodaTime. Dec 30 05:07:50 shibly there is an official google udacity course too Dec 30 05:09:50 And having already knowledge of Java, and also academic knowledge about programming in general, will be helpful. Dec 30 05:10:59 I remember my first days "programming" Android apps (read: copy-pasting together code from stackoverflow and blindly trying to follow the API documentation) Dec 30 05:12:33 https://www.instagram.com/p/_uutvxq4WB Dec 30 05:12:37 neat Dec 30 05:13:13 combining Louis Vuitton and final Fantasy Dec 30 05:13:45 Great, that page is un-scrollable, and constantly jumps around when trying to scroll... Dec 30 05:14:07 :/ Dec 30 05:15:06 Huh, Android is moving to openjdk? Neat Dec 30 05:20:20 yawkat, What does that mean? Dec 30 05:32:12 Hello everybody. I am trying to use a custom viewgroup which extends another parent viewgroup. I am facing a problem with the gravity of the children which i am adding to my customized viewgroup Dec 30 05:32:25 how can i resolve that ? Dec 30 05:32:57 The children are the views inside the arrayadapter of a listview which is added to the customized viewgroup Dec 30 06:05:50 g00s: Seems my GS3 requires I force it to 2.4gz ... it wasn't playing well with the new dual-band router Dec 30 06:12:33 http://venturebeat.com/2015/12/29/google-confirms-next-android-version-wont-use-oracles-proprietary-java-apis/ Dec 30 06:12:47 actually doesnt mean anything Dec 30 06:13:04 I got my hopes up thinkign hey were gonna ditch java =( Dec 30 06:13:11 ron_frown lol Dec 30 06:13:21 well, if they dont ditch java, this is the next best thing ;) Dec 30 06:13:36 not REALLY Dec 30 06:13:47 well let me back up Dec 30 06:13:55 if they didn't ditch java, what were they to do - stay on java 6 forever :/ Dec 30 06:14:00 that might mean taht it will no longer depend on google updating java Dec 30 06:14:04 so theoretically upgrades Dec 30 06:14:24 but apis really arent diff between googles and openjdk as far as java6 is concerned Dec 30 06:14:35 i read they were merging openjdk 9 also, ;) Dec 30 06:15:08 5 more years of java Dec 30 06:15:11 * ron_frown yawns Dec 30 06:15:24 me and my extreme hatred =) Dec 30 06:15:48 ron_frown y0u can use kotlin and soon ceylon Dec 30 06:15:52 :D Dec 30 06:15:58 if it uses java vm Dec 30 06:15:59 its out Dec 30 06:16:01 I'm done Dec 30 06:16:06 I've dealt with java 15yr Dec 30 06:16:15 I'm just too old to deal with their bullshit Dec 30 06:16:19 and oracle in general Dec 30 06:18:39 so .. openjdk 9, i wonder if that means we get jni 2 also Dec 30 06:18:48 well, some years from now :D Dec 30 06:20:46 guess that comes with java 10 http://openjdk.java.net/jeps/191 Dec 30 06:21:54 do not care Dec 30 06:21:55 honeslty rather use c++ =) Dec 30 06:22:33 I wish there was a supported widget toolkit for c++ Dec 30 06:22:50 and tools and bundling that I could use to totally avoid all things java, jni etc Dec 30 06:22:56 I almost said google supproted Dec 30 06:23:09 but if it was like the disaster that the ui apis they have now are Dec 30 06:23:14 just not interested =) Dec 30 06:23:44 ron_frown you must realize, you're one of the few people left that voluntarily want to use c++ for application dev ;) Dec 30 06:23:57 its not because I find c++ to be fantastic or antyhign Dec 30 06:24:03 I just feel like writing java, dealing with the java vm Dec 30 06:24:07 its just dumb. Dec 30 06:24:13 anyone has any idea how to save a filtered audio as a wav file? Dec 30 06:24:16 I found it easier to build stuff in c++ on ios =) Dec 30 06:24:27 when I go to my directory and play the .wav file it is the original audio Dec 30 06:25:07 I ahvent built anything in go, but it'd be better Dec 30 06:25:18 the dart engine stuff for android is actually pretty damn impressive Dec 30 06:27:12 http://flutter.io/getting-started/ Dec 30 06:28:15 and supposedly the way to interop with native shit is way better than jni Dec 30 06:29:51 "On Wednesday, the North Pole will be warmer than Western Texas, Southern California, and parts of the Sahara." d'oh Dec 30 06:31:26 jna is great Dec 30 06:34:44 in google Play Books - when you are reading a book, in immersive mode, and touch the screen, the book 'zooms out' - i need to do this also, but with a recyclerview + grid of things. anyone have any idea ? Dec 30 09:20:09 hello, is there a place in android where i could put a binary to run at boot? Dec 30 10:06:35 No. Dec 30 10:06:43 There's an intent for that. Dec 30 11:14:17 ivali: if you want to do it while having root over the device, there is a way to do it — using the init.rc script in /system. But that's more something if you want to modify the Android runtime itself. Dec 30 11:20:25 Even the runtime stuff will use the boot completed event because that makes sure the OS is in a stable state. Dec 30 11:24:52 Yeah, but if you already compile a binary for Android, it's possible that you want to deal with modifying the runtime itself. Dec 30 11:25:38 Perhaps. In 99% cases it's someone trying to do something very dumb because they think they're dealing with a rebranded Gentoo. Dec 30 11:37:01 am I not allowed to use log methods in my jUnit tests? Cause im getting : java.lang.RuntimeException: Method d in android.util.Log not mocked. Dec 30 11:44:09 no. use system.out.println Dec 30 11:50:10 Wasn't there some time ago a way to do JUnit tests for Android apps without emulator, and with full access to Log and similar stuff? Dec 30 11:50:25 I think I heard of something like that before... Dec 30 11:50:28 possibly via roboelectric Dec 30 11:50:40 but i've never used it so don't know Dec 30 11:50:47 Might have been that. I'll bookmark it. Dec 30 11:53:31 is there any reason to override Fragment.onAttach? Dec 30 11:57:12 anyone here? Dec 30 11:58:44 yes, lots of reasons Dec 30 11:59:23 would you tell me some pls? Dec 30 11:59:42 when an activity is killed and recreated (e.g. a rotation event), onDetach and onAttach is called. If you have any code that relies on getActivity(), if this code is executed while the fragment is detached (e.g. an async callback firing during a rotation event) you'll be in trouble Dec 30 12:02:02 I'm a beginner, trying to understand things, and this is what I know so far... Fragment.onCreate - use it for non-GUI things initializations... Fragment.onCreateView - inflate view... Fragment.onViewCreated - wire up the UI elements Dec 30 12:02:33 so what stuff goes into onAttach and onDetach? Dec 30 12:07:14 Shouldnt there be a Logcat Pane when im on my Debug View ? http://i.imgur.com/4hpmPr1.png Dec 30 12:08:20 but you are in console view Dec 30 12:10:17 Nick007, http://i.imgur.com/Q4hS05b.png Dec 30 12:11:07 press alt+6 Dec 30 12:11:09 how am i supposed to view Logcat when running tests? If I switch to Android Monitor > Logcat there's nothing there Dec 30 12:11:25 csst0111, alt+6, try that Dec 30 12:13:44 hello Dec 30 12:14:41 csst0111, did it work? Dec 30 12:14:42 Nick007, that's where i am now, but I dont see any output from the System.out.print method I use in my unit test Dec 30 12:14:47 on certain phone and android version (5 and 6) my FloatingActionButton gets half overlapped by the android button (the back, menu and option buttons bar triangle, circle and rectangle) Dec 30 12:29:19 anyone here who could help me with fragments? Dec 30 12:30:19 <_genuser_> hey people. Dec 30 12:44:52 http://venturebeat.com/2015/12/29/google-confirms-next-android-version-wont-use-oracles-proprietary-java-apis/ Dec 30 12:45:27 ugh Dec 30 12:51:04 hmm, interesting. i set android:ems to 12 for three different edit texts. two of them are android:inputType="textPassword". These two turn out a tad bit narrower than the third Dec 30 13:01:33 what are the reviews without app version, in google play console? Dec 30 13:02:39 any tips on smooth scrolling recyclerview so that a specific position ends up nearish to the center? -.- Dec 30 13:02:57 I hate how there's no "smooth scroll x pixels" Dec 30 13:03:03 or I can't find one any way Dec 30 13:07:25 lxknvlk, current version i think Dec 30 13:15:19 gah, I'm stupid Dec 30 13:15:23 smoothScrollBy, duh? Dec 30 13:42:34 Hi guys, how will migrating android from oracle java to openjdk influence android devs? Dec 30 13:42:58 There's no information about that atm. Dec 30 13:44:54 Any info on how it will change android in general? Dec 30 13:45:42 There's right now a single commit that links into a library that's not really used yet. Dec 30 13:45:47 That's what started the bruhaha. Dec 30 13:45:53 nothing will change for developers in all likelihood Dec 30 13:46:05 The commit itself currently doesn't even influence libart so it's practically impossible to tell until Google releases more. Dec 30 13:46:21 Everything you read on the internet it blind leading the blind :P Dec 30 13:47:19 Oh I see. thanks. Dec 30 13:49:23 By link you mean library linking right? Dec 30 13:49:50 Linking via compiler... Dec 30 13:50:47 No. Dec 30 13:51:02 It's literally code that isn't used as it comes to what we see in public now. Dec 30 13:52:57 I'm lost now! Dec 30 13:53:27 They said google confirmed moving to openjdk in android n. Dec 30 13:53:43 And I don't know what that may cause. Dec 30 13:53:47 it means nothing Dec 30 13:53:58 it changes nothing for developers Dec 30 13:54:32 What about android itself? Dec 30 13:54:52 irrelevant to this channel Dec 30 13:55:06 at the moment, it is purely a political change Dec 30 13:55:59 Ok, thanks. Dec 30 15:05:20 I have one activity which would host any one of three fragments at a time... all these three fragments contain only of RecyclerViews... all the three fragments would show different data in the RecyclerViews... how many RecyclerView layout XML files do I need to create - one or three? Dec 30 15:08:40 anyone here? Dec 30 15:09:05 *crickets* Dec 30 15:09:59 Mavrik, could you help me? Dec 30 15:11:49 If the layout XML is the same for all of them, then you can have only one layout file. Dec 30 15:13:55 Mavrik, the three fragments would have a FrameLayout as root... so can I create an XML which contains a RecyclerView as root and insert the RecyclerView in the three fragments using the include tag? Dec 30 15:14:24 playing with canvas & customview: http://imgur.com/nP8uf8w & http://imgur.com/ng4vzRR Dec 30 15:15:26 pretty Dec 30 15:15:35 Nick007, just inflate the same xml in the fragment Dec 30 15:27:57 Mavrik, thanks Dec 30 15:32:37 ugh, nexus phones don't have a photo widget anymore? Dec 30 15:32:52 I guess I need to build aosp gallery Dec 30 15:50:50 Hi, I need to add a few android projects to my resume. Any ideas of an android app which could complete within 2-3 months? Dec 30 15:51:33 a hello world program Dec 30 15:51:39 done that Dec 30 15:51:50 tinder :p Dec 30 15:52:09 a reddit app Dec 30 15:52:30 an rss reader Dec 30 15:52:41 jayeshsolanki, what app do you want to use? make that Dec 30 15:54:09 i was thinking to make an app which would record my phone calls Dec 30 15:54:40 yes maybe i should start with this Dec 30 15:55:42 If I'm writing an Android library that uses the latest okhttp, is there any way for me to ensure that users don't have issues with their classpath if for example they are using an older version of okhttp Dec 30 15:56:04 yiati, wat Dec 30 15:56:10 ah library. Dec 30 15:56:13 i misread Dec 30 15:56:56 One choice I have is to not use okhttp in my library, then no dependency issues :P Dec 30 15:57:22 Just wrote a sample app using an older version, and I'm definitely seeing classpath issues Dec 30 15:59:59 why do you need okhttp Dec 30 16:00:54 it only matters if users are on an older version Dec 30 16:01:04 I mean, majorly older version Dec 30 16:02:38 you can jarjar okhttp Dec 30 16:03:33 pfn: Right, another option I definitely have is to tell users to use the latest version of okhttp. I also saw that 3.0 should have a different package name so moving forward okhttp 2.0+ there shouldn't be an issue Dec 30 16:03:56 Would be nice to know how many people use 1.0 Dec 30 16:04:21 0 people Dec 30 16:04:56 missingno: OkHttp perseveres when the network is troublesome: it will silently recover from common connection problems. If your service has multiple IP addresses OkHttp will attempt alternate addresses if the first connect fails. Dec 30 16:04:58 would be nice if maven central had download statistics like bintray Dec 30 16:05:43 that'd be cool Dec 30 16:05:44 yiati: did you know that android internally uses okhttp Dec 30 16:06:30 missingno: An older version on 4.4+ yes Dec 30 16:11:50 guess I meant how many use 1.x to be technical Dec 30 16:12:20 no one Dec 30 16:12:31 https://static.slo-tech.com/65381.jpg Dec 30 16:12:38 Funny for some reason. Dec 30 16:16:15 * pfn crosses fingers that he's able to build aosp stuff this time Dec 30 16:23:11 where is everybody? Dec 30 16:23:17 out to lunch? Dec 30 16:23:56 http://venturebeat.com/2015/12/29/google-confirms-next-android-version-wont-use-oracles-proprietary-java-apis/ Dec 30 16:24:10 :) Dec 30 16:24:15 thoughts, comments, apathy? Dec 30 16:24:16 changes nothing Dec 30 16:24:20 political Dec 30 16:25:45 I don't know why they have wasted some much time in court Dec 30 16:26:34 irrelevant here Dec 30 16:27:50 why does it change nothing Dec 30 16:27:55 that's nothing, compared to cyanogen mod, that mod creation and development is entirely politically driven Dec 30 16:28:05 sounds like java 9 support in N Dec 30 16:28:12 that's a good analogy for this Dec 30 16:28:24 cyanogenmod changes nothing from the perspective of developers Dec 30 16:28:30 and the vast majority of users, even those on cyanogenmod Dec 30 16:28:34 it's the same thing, still android Dec 30 16:28:55 Until Google officialy makes a statement we won't even know if they'll break any APIs. Dec 30 16:29:10 if it does, watch android/N wither and die Dec 30 16:30:05 I think the only impact will be if you rely on harmony-specific behavior Dec 30 16:30:13 Yeah. Dec 30 16:30:23 I just hope those AWT classes they pulled in won't be exposed. Dec 30 16:30:32 Imagine a bunch of shitty devs using AWT for apps :P Dec 30 16:31:54 lexton, it is good those creeps at oracle get cut off Dec 30 16:32:48 I can't stand oracle Dec 30 16:33:20 missingno: Android java X support is all about dex byte code creation, which is why APIs change nothing here Dec 30 16:33:33 Mariu, that doesn't cut off oracle in the least Dec 30 16:33:44 pfn, oh? Dec 30 16:33:48 either this will force aosp to become gpl, or google will pay oracle an obscene sum of money Dec 30 16:34:07 I see Dec 30 16:34:47 once again, irrelevant here Dec 30 16:34:53 all speculation, doesn't matter Dec 30 16:38:48 herp da derp. per my question earlier I suppose there is no problem if my library uses okhttp 3.x Dec 30 16:39:06 jarjar it or dont use it Dec 30 16:39:10 heh Dec 30 16:39:29 lol Dec 30 16:39:38 yiati, well, there is something of a problem, your use of okhttp 3.x will evict okhttp <3.x from dependencies Dec 30 16:39:44 unless okhttp 3.x changes their artifact name Dec 30 16:39:56 It did Dec 30 16:40:04 oh, well then, no problem there, carry on Dec 30 16:40:08 :D Dec 30 16:40:24 Thanks @JakeWharton Dec 30 16:40:39 sorry irc users, too much hipchat Dec 30 16:40:44 I know, know @ sign required Dec 30 16:40:53 s/know/no/ Dec 30 16:40:56 :P Dec 30 16:40:57 hipchat sucks, I'm glad that I'm not going to be using it anymore Dec 30 16:41:11 Hi, in Studio 2 preview, is there a way to identify what theme tag is styling a particular piece of text? I know you can click on the samples in prefs/editor/colors, just wondering if there's a way to identify out of prefs (i.e., in an open file). Dec 30 16:44:34 ERROR: Cannot launch Jack server Dec 30 16:44:36 * pfn kicks aosp build Dec 30 16:44:37 why damnit Dec 30 16:46:09 maybe it doesn't like make -jN Dec 30 16:47:13 missingno: pfn: just looked up jarjar, never heard of it. Not ideal, but I guess that's a solution too, thanks Dec 30 16:47:44 you could also proguard your library and obfuscate only the okhttp section while keeping everything else Dec 30 16:49:16 interesting, jack doesn't like make -j4 Dec 30 16:50:18 pfn: Huh, yeah I had considered proguarding the entire library, but hadn't considered I could keep most open, and only obfuscate part. Guess there are actually a handful of solutions Dec 30 16:51:01 pfn, wait hipchat sucks? what *should* we be using? Dec 30 16:51:14 thebishop, slack is much better than hipchat Dec 30 16:52:05 I don't mind hipchat. It's alright. I do like slack a bit more though. Also I think thebishop is going for irc though as the answer Dec 30 16:52:06 scales well, the clients are awesome Dec 30 16:52:33 hipchat has such a shitty client on all platforms Dec 30 16:52:53 The hipchat beta app is pretty nice Dec 30 16:53:19 https://source.android.com/source/jack.html#jack_troubleshooting Dec 30 16:53:25 indeed Dec 30 16:53:43 pfn, strange, we evaluated both and went with hipchat. slack seemed to require a lot more github permission for its integration. We also preferred hipchat's log minimizing behavior. for the most part they seemed similar. I do think Slack's UI is more "fun" fwiw Dec 30 16:55:01 the integrations in slack are also much nicer Dec 30 16:55:09 only thing I remotely like about hipchat is auto-integration with jira Dec 30 16:55:40 they must've made a lot of progress in the last 9 months. Dec 30 17:03:52 Is it possible to launch the jack server once before a paralell make and leave it running, then do the make -jN when the server is already up? Maybe two different invocations of jack are trying to launch the server simultaneously and that fails. Dec 30 17:04:15 * duboisj knows nothing about jack at all Dec 30 17:04:21 I have a simple app that sends a mail using javamail. I have added the libs needed (I'm using libgnumail-java for mail.jar and libgnujaf-java for activation.jar). It is building correctly in android studio 1.5.1 but when It's run in a phone it shows this exception http://paste.debian.net/357225/. I have copy and paste the code for sending a mail to a netbeans project with the same libs and the project works fine. What could be the issue? Dec 30 17:04:32 hmm, gallery2 hasn't been updated since api17, it looks like ass Dec 30 17:06:59 I see the DataHandler.class in activation.jar, i don't know what is happening here Dec 30 17:10:35 duboisj: jack is mono-user. for new user you need new ports Dec 30 17:11:52 dunno, don't care, for this, I am ok with not using make -j Dec 30 17:13:09 thebishop, yiati, pfn : any slack/hipchat alternatives? honestly I'm looking for skype alternatives, able to make group voice/video calls are important to me Dec 30 17:14:05 vigilancer: The places I've worked usually just use slack+hipchat for text communication, and a separate service for voice/video calls such as google hangouts for business Dec 30 17:14:19 pretty much the above Dec 30 17:14:22 or webx which is terrible Dec 30 17:14:37 for video/voice Dec 30 17:14:57 s/slack+hipchat/slack\/hipchat/ Dec 30 17:15:17 vigilancer, i think slack and hipchat are feature complete enough. i'd only look for an alternative if you want something Free that you can self-host, which has a few decent options Dec 30 17:15:47 team pretty much agaist solutions which require more than one app ( Dec 30 17:16:04 well, hipchat has autointegration with hangouts Dec 30 17:16:13 vigilancer, so you need a group chat with good conference call built-in? Dec 30 17:16:13 just /hangout to start a call Dec 30 17:16:14 * pfn shrugs Dec 30 17:16:23 thebishop: yeap Dec 30 17:16:37 conference and screen sharing Dec 30 17:16:58 pfn: thanks didn't know, will take a look Dec 30 17:18:53 vigilancer, https://rocket.chat/ might be worth a look Dec 30 17:26:01 thebishop: hm, rocketchat-0.0.9.dmg. seems they are fresh new. well, let see Dec 30 17:29:30 g00s: morning Dec 30 17:29:51 hey thepoosh Dec 30 17:29:59 i hate doing code review Dec 30 17:30:03 pfn: are you here? Dec 30 17:30:17 thepoosh how many wtfs so far :D Dec 30 17:30:29 lolz Dec 30 17:31:06 i had a huge fight with a colleague about his code, he had a while(true) Dec 30 17:31:15 my boss forced me to merge it in Dec 30 17:31:39 we had one guy making network requests every 2 seconds for 2 days Dec 30 17:32:06 thepoosh wouldn't android 6 just put the app to sleep ? Dec 30 17:32:08 Why did you dislike the `while (true)`? Dec 30 17:32:27 TacticalJoke: because of exactly what happened Dec 30 17:32:34 g00s: the guy didn't have M Dec 30 17:32:36 thepoosh was it while (true) { sleep(2000); sendNetworkRequest() ; } ? Dec 30 17:32:44 thepoosh: What happened? Dec 30 17:33:46 it was while(true) { getStuffFromDb(); sendRequestToServer(); if(noMoreStuffInDB()){ break;}} Dec 30 17:33:59 server returned an undocumented error Dec 30 17:34:05 lol, maybe you can have him fired Dec 30 17:34:08 there was always stuff in the db Dec 30 17:35:07 lol Dec 30 17:35:13 that sucked balls Dec 30 17:35:18 was this supposed to sync the local db with the server? Dec 30 17:35:27 our server team had to ninja-hack a solution Dec 30 17:35:35 something like that Dec 30 17:35:59 at that point I would just refuse the connection for the specific client Dec 30 17:36:24 idk Dec 30 17:36:42 we told them what hackish response to return in order to stop this DDoS Dec 30 17:36:45 and they did Dec 30 17:38:18 thepoosh should have the dev do a rotation in server team, devops ! Dec 30 17:38:32 sounds fun Dec 30 17:41:04 thepoosh, yeah, clone the android-sdk-plugin repo, sbt publishLocal Dec 30 17:41:24 just a sec Dec 30 17:41:54 thepoosh, then addSbtPlugin("com.hanhuy.sbt", "android-sdk-plugin", "1.5.13-SNAPSHOT") Dec 30 17:42:05 thepoosh, should get past the problem yesterday Dec 30 17:42:11 cool Dec 30 17:42:26 pfn: from master? Dec 30 17:43:01 yes Dec 30 17:43:29 mocked arraylist of objects with mockito returns zero size - is this correct ? Dec 30 17:44:03 csst0111, did you try to mock the ArrayList class or is it an array of mocket objects Dec 30 17:44:28 i mocked the arraylist class Dec 30 17:44:54 why? Dec 30 17:45:26 because the object is a Marker item and cant mock it Dec 30 17:45:48 if you mock array list, you are respoonsible to what it return Dec 30 17:46:30 hmm Dec 30 17:47:24 the mock cant know its size because its a mock and wont work like a normal list Dec 30 17:47:44 is there an Android-dev chat? or do we just kinda do that in there? Dec 30 17:47:46 here? Dec 30 17:47:56 how should i test if my method populates a Marker ArrayList ? I thought to check the size of the arraylist Dec 30 17:48:23 pfn: java.lang.RuntimeException: Manifest merger failed : Attribute application@label value=(@string/protify_app_name_internal) from AndroidManifest.xml:9:18-67 Dec 30 17:48:23 is also present at [/Users/thepoosh/Documents/development/protify/android/test1/android/intermediates/aars/com.android.support.test-rules-0.3] AndroidManifest.xml:7:18-50 value=(@string/app_name). Dec 30 17:52:40 thepoosh, why is test library not in testCompile? Dec 30 17:52:56 thepoosh, you would have to tools:ignore it Dec 30 17:53:09 all i did was clone and run sbt publishLocal Dec 30 17:53:35 huh? Dec 30 17:53:39 not protify Dec 30 17:53:41 android-sdk-plugin Dec 30 17:53:44 oh Dec 30 17:54:07 https://github.com/pfn/passifox/issues/426 Dec 30 17:54:10 oops Dec 30 17:54:22 https://github.com/pfn/android-sdk-plugin Dec 30 17:57:49 I wish KeePassX has plugin infrastructure to utilize that plugin. Dec 30 17:58:17 *had. Dec 30 18:02:26 sudhirkhanger, there are patches to add support to keepassx Dec 30 18:02:33 like pr 111 Dec 30 18:03:06 pfn: will have to look. KeePassX 2.0 is out. Not sure how that affects state of things. Dec 30 18:03:47 Although I don't really miss it a lot because I fill in passwords using Ctrl+V command of keepassx which fills both username and password. Dec 30 18:06:03 I have been meaning to give pass a try. Dec 30 18:13:49 yeah, I don't use keepassx, but I thought someone merged support officially, guess not Dec 30 18:25:52 g00s: https://infinum.co/the-capsized-eight/articles/android-development-is-30-percent-more-expensive-than-ios Dec 30 18:26:40 and yet, on gigster, the amount for Android is usually less than that for iOS Dec 30 18:27:23 maybe it's the influx of android programmers Dec 30 18:27:42 the barrier to entry is lower which brings worse programmers Dec 30 18:27:51 like me :P Dec 30 18:28:05 no, it’s a study from a company on their own projects Dec 30 18:28:12 thepoosh, I assume it all works now? Dec 30 18:28:18 they say the quality of engineers on both sides is about equal Dec 30 18:28:40 pfn: i did the prep work but I've been up for over 16 hours Dec 30 18:28:55 so waiting till tomorrow Dec 30 18:34:50 16 hours isn't impressive :p Dec 30 18:35:51 you know what is impressive? 16 billion hours Dec 30 18:37:43 http://www.wolframalpha.com/input/?i=16+billion+days+to+millenia Dec 30 18:38:03 16 billion hours = 43807 millenia Dec 30 18:38:12 That's a bit excessive Dec 30 18:59:09 does anyone use assertions in their android code? Dec 30 19:01:15 false Dec 30 19:02:08 no Dec 30 19:02:14 lol Dec 30 19:02:18 okay Dec 30 19:02:18 assertions are never enabled. and thus useless Dec 30 19:02:22 just curious Dec 30 19:02:30 well in java it's not really any different Dec 30 19:02:39 you have to pass the -ea flag yourself to jvm Dec 30 19:37:13 <_abc_> Hello. What's the exact extent of "patching" possible with the usual "recovery mode" boot of android phones? I see it can "patch" from sd card, but I assume that cannot be used to directly install a phone from scratch? Dec 30 19:37:48 <_abc_> Specifically I have a busted GT-B5510 I need to reflash from scratch, someone made it unusable software wise before I got it Dec 30 19:54:14 "The application may be doing too much work on its main thread." Does it means that definitely something is wrong with my code or is it ok since im *actually* doing a lot of work on main thread adding and removing views on google map Dec 30 19:54:38 it means there's something definitely wrong with your code Dec 30 19:54:52 csst0111, is it the emulator or a real device? Dec 30 19:55:01 its emulator Dec 30 19:55:04 on emulator this seems to come up randomly for me Dec 30 19:55:26 but its a sign for you to think over your algorithms Dec 30 19:55:27 ok thanks i'll try it on a real device soon Dec 30 19:55:39 yeap :( Dec 30 19:56:32 I get it all the time on the emulator. Dec 30 19:56:44 Even a blank activity will show that for me. Dec 30 20:37:48 I have a generic class for which I will be overriding 1-2 functions a lot Dec 30 20:38:04 how can I avoid duplicating that override class? Dec 30 20:41:31 huh Dec 30 20:42:46 Yeah I guess that wasn't entirely clear Dec 30 20:43:32 currently I instantiate a class by going new ClassThingy() { @Overrides here } Dec 30 20:43:44 I will have to do that, with the same TypeSelection and Overrides, in a lot of activities Dec 30 20:44:02 so make it it’s own separate class? Dec 30 20:44:16 Yes, but how do I do that? Dec 30 20:44:17 eeyup Dec 30 20:44:24 uh Dec 30 20:44:27 I need to ensure that ClassThingy's methods are still available Dec 30 20:44:39 public class Meh extends ClassThingy Dec 30 20:44:48 YourClass extends ClassThingy Dec 30 20:45:09 but then I have to implement a lot of constructors, don't I? Dec 30 20:45:13 why? Dec 30 20:45:17 no Dec 30 20:45:29 unless theres no parameterless constructor Dec 30 20:45:36 but still youd need only add one super(...) Dec 30 20:45:37 android studio seemed to get pissed if I didn't Dec 30 20:45:51 oh okay, so as long as I implement _one_ constructor I am all good? Dec 30 20:45:55 just few more lines codes once Dec 30 20:46:08 eeyup Dec 30 20:49:25 right.. thanks! Dec 30 20:53:12 Should I always be checking whether a TextField is null before attempting setText? Dec 30 20:54:33 No. Why would you do that? Dec 30 20:54:48 you mean textField.set(null) or null.set(text) Dec 30 20:55:25 I mean doing if (textField != null) { textField.setText("value"); } Dec 30 20:55:33 rather than textField.setText("value"); without any check Dec 30 20:55:56 TacticalJoke: well, I do get a lot of NullPointerExceptions during development Dec 30 20:56:07 because I forget that some items aren't quite ready yet etc Dec 30 20:56:13 it alright but depends whether you really dont know if textField isnt null Dec 30 20:56:17 then you shouldn’t be using them Dec 30 20:56:24 It's good that you get NullPointedExceptions -- you're finding bugs. Dec 30 20:56:29 If you didn't get them the bugs would take longer to find. Dec 30 20:56:31 normally you initialize it onCreate Dec 30 20:56:47 so generally it is "okay" to assume your elements are there (as long as they should be)? Dec 30 20:57:11 no, generally you structure your code in such a way that they should always be there after initialization Dec 30 20:57:23 w0bni: If it's required to be there then don't check. Dec 30 20:57:38 very well, thank you! Dec 30 20:59:10 One problem with Java (and other languages) is that you can't opt out of nullability. Most of the time, we want a non-nullable reference, and Java goes against our wishes. Dec 30 21:40:12 Anyone out there? Dec 30 21:54:17 does anyone know what "launchFromMain" does to a WebActivity Intent? I'm trying to debug some issues with this code but I didn't write it so I don't know what this is here for Dec 30 21:59:33 my bad this is code from our library I thought it was from Android Dec 30 22:32:37 looks like everybody is already gettin their drink on for the new year Dec 30 22:32:47 too drunk to type, woah... Dec 30 22:42:24 * lexton cracks open a pabst blue ribbon Dec 30 23:09:57 hello all.. i have a question. How do you identify the current Fragment (RecyclerView) from the cardview's onBindViewHolder? (Im using https://github.com/florent37/MaterialViewPager) Dec 30 23:10:59 pass it in? Dec 30 23:12:11 missingno: I didnt get you? Dec 30 23:12:24 I did not get you either Dec 30 23:12:28 noob here, so sorry if i ask stupid questions Dec 30 23:12:32 ) Dec 30 23:12:48 like I don't know what your code is like or where this fragment is or how many fragments there are Dec 30 23:13:10 or what you want to do with it Dec 30 23:13:36 okay, have a quick look at https://github.com/florent37/MaterialViewPager/blob/master/sample/src/main/java/com/github/florent37/materialviewpager/sample/TestRecyclerViewAdapter.java Dec 30 23:13:43 but onBindViewHolder is part of RecyclerView.Adapter, so you can pass in this Fragment as an argument of your constructor Dec 30 23:16:27 is there a way to get the id/tag of the current fragment from the viewholder instance? Dec 30 23:17:55 there's probably a really long way Dec 30 23:18:03 the easiest way is to pass it in Dec 30 23:19:46 sorry, but i dont know how to do that :( or im not understanding what youre trying to say.. Dec 30 23:33:07 I’ve got a question. Dec 30 23:33:33 If I have the situation that I want to have a service that connects to a server, and keeps a list of data always up to date, Dec 30 23:33:45 and then use that list and display it in an activity (or in a widget, etc) Dec 30 23:34:11 is there a simple way to use Observables (RxJava) with IPC? Dec 30 23:34:24 Or would I have to build something myself to emulate that? Dec 30 23:34:58 Or am I just looking at it the wrong way and there’s a simpler concept? Dec 30 23:38:23 justJanne don't know offhand, have you seen http://reactivesocket.io Dec 30 23:38:41 ben christensen is working on it. i haven't used it Dec 30 23:39:06 well, the issue is, I have a library that connects to the server (with the custom format) etc already Dec 30 23:39:20 the problem is how to best send updates of a data structure between two processes Dec 30 23:39:25 (and update the UI accordingly) Dec 30 23:40:16 oh you have 2 processes ... Dec 30 23:41:10 Well, I could just use a service, but that supposedly doesn’t work too well with binding to a widget and an activity at the same time Dec 30 23:47:32 g00s: what would you do? any ideas? Dec 30 23:48:45 justJanne i only have one process; i still use contentProviders - so i'm old school Dec 30 23:49:16 also haven't done a widget yet, but thats on my list Dec 30 23:50:56 Hm. Dec 30 23:51:07 i'd try to keep it in one process, unless your UI takes up lots of memory and the service is going on in the background a lot Dec 30 23:51:40 well, the service is going to be in background 24/7, but the app only open a few minutes at a time Dec 30 23:52:06 the issue I fear most is keeping it properly synced Dec 30 23:52:07 so you have one of those brutal foreground services :D Dec 30 23:52:22 yeah, that’s what it’ll end up as, yeah. Dec 30 23:52:24 IRC apps... Dec 30 23:52:33 the kind of scenario dianne H keeps trying to squash with every new version of android Dec 30 23:52:54 the kind of scenario that’s impossible to solve sometimes Dec 30 23:54:13 I'm using databinding in my app and I have an Edittext field, when I enter text into the field the text appears in reverse Dec 30 23:54:30 so entering dog into the field the user would then see the word god Dec 30 23:54:38 has anyone run into this issue? Dec 31 00:11:43 g00s: how do you update the content of your recyclerviews? I mean, doing it on the same thread is simple, but with a service it’s more complicated. Dec 31 00:12:50 okay, I’ll just write a custom observable lis Dec 31 00:12:52 *t Dec 31 00:15:38 anyone know a good way to test audio focus ducking? Dec 31 00:15:52 i.e. whether or not my media player reduces volume when a text message comes in Dec 31 00:15:57 and raises it again after Dec 31 00:16:10 using an emulator Dec 31 00:17:34 you might try the new emulator, otherwise that’s kinda the thing you need a device to test Dec 31 00:17:43 justJanne, yeah, don't ipc unless you absolutely have to Dec 31 00:17:56 binder transaction for irc is overkill Dec 31 00:18:06 UI in background gets gc anyway Dec 31 00:18:16 s73v3r me? Dec 31 00:18:26 what does the new emulator have regarding this that genymotion wouldn't? Dec 31 00:18:45 ability to simulate receiving a text? Dec 31 00:19:38 oh, i didn't know it had that Dec 31 00:19:47 welly well then, looks like i'm hitting the download page, thanks much Dec 31 00:20:08 sigmabeta also free for commercial use :D Dec 31 00:20:28 and new adb protocol i guess, haven't tried that Dec 31 00:20:33 i plan to switch to it anyway once it's stable, i don't reeeeally need to be sold on it Dec 31 00:20:44 but i'm also not using genymotion for anything non commercial, so that's not a huge selling point Dec 31 00:23:36 s73v3r i saw it a little late, thepoosh mentioned android dev costs - i saw that article a while back (actually, there were a few sources) but you said something that contradicted the idea ... Dec 31 00:24:19 i couldn’t remember what it was Dec 31 00:24:34 something about gigster Dec 31 00:24:58 FWIW, there' an API demos sample that simulates a text notification Dec 31 00:26:09 oh yeah Dec 31 00:26:35 I’ve only been looking for a few days, but for devs, it seems they offer less for android than they do for ios Dec 31 00:27:26 s73v3r and these are for projects with android / ios versions ? Dec 31 00:27:30 or 'on average' Dec 31 00:27:48 it’s only a couple of data points, but it was for the same project on ios and android Dec 31 00:28:34 i wonder why they would do that. i have seen company do iOS first, and think they were going to have easier time doing android version because - they thought they would reuse the iOS UI / UX (and save money) Dec 31 00:28:57 'all you have to do is copy the ios version' heh Dec 31 00:29:15 well, maybe not the UI/UX, but i would imagine a lot of the hard work in figuring how to set something up would carry over Dec 31 00:29:24 i mean set up the server and stuff Dec 31 00:29:36 apis and such Dec 31 00:30:43 I can't open the SDK manager on Windows 8.1! I've installed the Java 1.7 JDK and forced android.bat to refer to it, but I still get this stack trace http://pastebin.com/YFJZCxiQ Any tips? Dec 31 00:33:15 eclipse? Dec 31 00:33:39 blindbox: No. I'm not using Eclipse at all. Dec 31 00:34:02 g00s, usually why costs goes up, imo Dec 31 00:34:10 But now that you mention it, I recall that Android Studio *is* based on Eclipse...maybe I'll try installing that. Dec 31 00:34:17 lots of. back and forth having to revise designs for android Dec 31 00:34:19 no no, don't Dec 31 00:34:26 it's working perfectly fine for me Dec 31 00:34:30 or a lot of wasted implementation trying to make it work like ios Dec 31 00:34:37 both ways increase costs Dec 31 00:34:39 is there SDK Manager.exe on your pc somewhere? Dec 31 00:34:44 try running that Dec 31 00:34:53 android studio is now based on intellij, btw Dec 31 00:34:56 on windows you run sdk manager Dec 31 00:35:02 not android.bat Dec 31 00:35:07 blindbox: Yep. No output, nothing runs. Dec 31 00:35:29 blindbox: Also, didn't know that. Dec 31 00:35:32 why 1.7 though? isn't the latest jdk is like, jdk8u66? Dec 31 00:35:38 BlueProtoman, set JAVA_HOME in your environment Dec 31 00:35:48 http://www.oracle.com/technetwork/java/javase/downloads/index.html Dec 31 00:35:49 blindbox: Yes, but Android apparently requires 1.7. Dec 31 00:35:52 nope Dec 31 00:35:55 i'm uing jdk 8u66 Dec 31 00:35:56 BlueProtoman, not set path to java.exe in bat Dec 31 00:35:59 pfn: I'll give it a try. Dec 31 00:36:42 I hate Windows development so much. Dec 31 00:39:22 why? Dec 31 00:40:22 Eplebit: I find that I have to screw around with inane shit like this more often than I do on Linux. Dec 31 00:40:53 could be Dec 31 00:40:56 eh, i've used both linux (of the linux mint variant, which i fund to have the best desktop) and windows for dev. they all have their ups and downs, and i actually prefer windows because i have this tool called 'Everything', and the fact that creating desktop shortcuts is trivial Dec 31 00:41:06 I couldn't even get android studio to run on my mac, though, so +1 to windows on that front... Dec 31 00:41:20 s/fund/found* Dec 31 00:42:07 huh? I develop just fine on windows Dec 31 00:42:17 And this is my problem; we're all giving different answers! Dec 31 00:42:29 and setting JAVA_HOME is standard on all operating systems Dec 31 00:43:00 BlueProtoman, yeah and your comment on windows is really unfounded. if you're working on ubuntu i swear, i'd give you the same answer Dec 31 00:43:06 update your bloody java Dec 31 00:43:58 blindbox: I did. And I'm sorry, I'm just frustrated. Dec 31 00:44:23 it's java, so that's allowed Dec 31 00:44:28 anyway, i use windows when i could get away with it, and my web-dev work are all on windows, but with the web server running on a vm. works amazingly well Dec 31 00:44:49 I normally use Ubuntu, but I use Windows for Unity Dec 31 00:44:56 hmm, I actually ahd some problem with android studio as well not long ago because one program required java_home to be to the jre and program required it to be to the sdk Dec 31 00:45:08 java_home isn't even set on my windows Dec 31 00:45:17 i'm surprised you need it Dec 31 00:45:31 android studio told me i needed it, at least Dec 31 00:45:32 Hold on, must reboot Dec 31 00:45:36 weird that your didn't... Dec 31 00:45:49 it wouldn't boot until I changed it Dec 31 00:45:51 JAVA_HOME is required Dec 31 00:45:54 breaking the other program :( Dec 31 00:46:05 -> echo %JAVA_HOME% ---> gets back %JAVA_HOME% Dec 31 00:46:23 just to be sure since i hate windows command line, i tried echo %PATH% Dec 31 00:46:24 that works Dec 31 00:47:42 beats me... Dec 31 00:48:07 not on my work computer now so can't check Dec 31 00:49:06 * pfn shrugs Dec 31 00:49:15 most things require it Dec 31 00:49:36 simply using Java from path will not always work Dec 31 00:50:01 and will most often not if the first java in path is from jre Dec 31 00:50:41 lots of things in the android toolchain tries to detect a suitable java though Dec 31 00:54:38 ugh, I wish there were a way to use viewserver without polluting code Dec 31 00:57:14 android_hvproto has never worked for me Dec 31 01:02:19 hmm, launching monitor and adb after setting android_hvproto works Dec 31 01:39:23 is there a way to push a message via GCM which is received by the Android OS rather than your application? Dec 31 01:39:36 say if you want to alert the user with a message Dec 31 01:49:22 https://www.codenameone.com/blog/analysis-google-moving-to-openjdk-what-that-really-means.html Dec 31 01:51:21 erisco, that makes no sense Dec 31 01:52:22 on iOS, for example, the device can receive a push notification and display a text payload in the status bar (or drawer, whatever it is called) Dec 31 01:54:18 erisco, so? there's an app to receive those Dec 31 01:54:33 or ios is dumb and renders random notifications Dec 31 01:54:47 and the latter is extremely unlikely Dec 31 01:56:02 that's a great way to spam users without permission Dec 31 02:28:29 android has come a really long way, i can say 5.0 is nearly as good as iOS finally Dec 31 02:39:23 Wait what Dec 31 02:39:28 http://venturebeat.com/2015/12/29/google-confirms-next-android-version-wont-use-oracles-proprietary-java-apis/ Dec 31 02:40:16 i kinda like that PreferenceFragmentCompat is missing list dividers, looks much more clean. kinda think dividers should go away unless separating groups of things Dec 31 02:41:02 Whats the deal with Google using the OpenJDK for Android? Dec 31 02:41:20 drose379 something is happening ! Dec 31 02:41:31 we'll have to wait and find out though ;) Dec 31 02:41:36 Whats going on g00d Dec 31 02:41:44 Theyre not ditching java are they? Dec 31 02:41:52 yes g00s is g00d :D Dec 31 02:42:06 g00s * :P Dec 31 02:43:30 drose379 https://www.codenameone.com/blog/analysis-google-moving-to-openjdk-what-that-really-means.html Dec 31 02:44:26 i hear mixed info about whether this is openjdk 7 or 9 tho Dec 31 02:45:15 Is openjdk just open source java? Dec 31 02:45:33 yup Dec 31 02:45:44 its what oracle's JVM adds upon Dec 31 02:45:58 extra goodies, profiling things Dec 31 02:46:49 Do people enjoy using java for Android? Dec 31 02:47:28 Mostly I'd say yes. People who don't use Kotlin Dec 31 02:47:39 CedricBeust_, have you started using Kotlin? Dec 31 02:47:39 Certainly beats Objective C (albeit not Swift) Dec 31 02:47:49 I've been using Kotlin for almost four years now Dec 31 02:48:22 CedricBeust_ wow, thought you got into it within the last 6mos or so Dec 31 02:48:27 Wow Dec 31 02:48:39 CedricBeust_, so you enjoy it more then Java? Dec 31 02:48:54 Actually four years and a half, here is the oldest blog post I can find about Kotlin: http://beust.com/weblog/2011/07/20/five-reasons-why-should-rejoice-about-kotlin/ Dec 31 02:49:15 more than* Dec 31 02:49:24 Yes, I definitely enjoy Kotlin more than Java Dec 31 02:49:37 CedricBeust_, are you solely a Android dev? Or do you develop for other platforms also? Dec 31 02:49:55 I develop for ALL THE THINGS Dec 31 02:49:59 Like what Dec 31 02:50:10 Actually, most of my career has been on the back end, mobile is relatively a small portion of it Dec 31 02:50:24 Are you self employed or for a company Dec 31 02:50:39 Company Dec 31 02:50:50 So you work on the server side mostly Dec 31 02:51:10 I do both Dec 31 02:51:26 Which langs for what? Dec 31 02:52:01 Essentially Java and Kotlin. Lot of other languages too but mostly for personal studies Dec 31 02:52:47 Interesting CedricBeust_ Dec 31 02:53:10 So you didnt like Obj-C? Dec 31 02:54:06 This is #android-dev, not #cedric-beust, let's get back to that Dec 31 02:54:26 Lol Dec 31 02:55:36 So if I want to do something on the background thread, is IntentService best? Dec 31 02:55:40 Its what I've been using **** ENDING LOGGING AT Thu Dec 31 02:59:58 2015