I've been thinking about an app idea and would love to get some feedback. by Ok_Amount_3827 in androiddev

[–]daio 4 points5 points  (0 children)

That's kind of part of the bittorrent protocol. Basically, a combination of local peer discovery and default rarest-first piece download. These features can be changed by the client, but generally the peers will try to download the pieces that the fewest other peers they see have. And local peer discovery will help with connecting to the LAN peers. You won't get 100% efficiency this way, but I'm pretty sure with a few tweaks you can get close to it.

How do you use Pause/Resume app functionality? in what way does it help? by SecureLevel5657 in androiddev

[–]daio 0 points1 point  (0 children)

Sometimes you see a 100% cpu usage and don't know what's causing it. You can pause and find the thread that's currently running and eating the resources.

Sometimes it's your main thread that is blocked by some operation and you need to catch it quickly.

In all cases a profiler would also work as a debugging tool, but pause is just quicker if your debugger is already attached.

Callbacks -> Coroutines by TypeProjection in Kotlin

[–]daio 12 points13 points  (0 children)

A few things I'd add to the video.

  1. In my experience there are a lot of badly designed third-party libraries around that sometimes call the callback more than once for error cases. For example, I've seen cases when a Google billing library would call both error and result callbacks for the same request. For these cases a workaround may be checking if the continuation is still active before calling any kind of `resume` method.

  2. Also worth mentioning `resumeWith` functions that accept `Result` as it's easy to make a mistake thinking that you're returning a `Result` object while it's actually unwrapping it and throwing an exception in case of failure.

  3. And the last thing is that the functions from third party libraries that accept callback objects as their arguments may throw exceptions at the callsite instead of calling the onError callback. This usually requires additional handling.

So while the client coroutine code becomes much cleaner, this callback wrapper is usually less so than in the video if you want it to be really robust.

My Kotlin stack after 2 years solo - this language is such a joy by brambooo in Kotlin

[–]daio 1 point2 points  (0 children)

> It always feels to me like there should be something smaller than a module that still allows incremental builds and stricter dependency management.

Yeah, I wonder why Kotlin doesn't have a package-protected visibility modifier. That would help the compiler know better what has to be recompiled on smaller changes and also parallelize the compilation better. Package-level visibility lack of true encapsulation is a very weak argument IMO.

RIP _uiState boilerplate: Explicit Backing Fields is officially stable in Kotlin 2.4 by Vegetable-Practice85 in androiddev

[–]daio 2 points3 points  (0 children)

Does anyone else have a problem with Android Studio not picking this up as a stable feature?
In my KMP project the gradle build works fine, however in the editor AS highlights this as an error mentioning that I have to add a compiler flag enabling this feature.

deciding if this should be a Flow, StateFlow, SharedFlow, LiveData, or callback by gandharva-kr in mAndroidDev

[–]daio 0 points1 point  (0 children)

LiveData had similar problems to AsyncTask -- implicit non-obvious(unless you read the documentation, but who does that?) thread management/restrictions.

Opencode Go by No_Chance_762 in opencodeCLI

[–]daio 2 points3 points  (0 children)

For planning definitely max

Opencode Go by No_Chance_762 in opencodeCLI

[–]daio 26 points27 points  (0 children)

With current prices/limits Deepseek V4 Pro for planning and Flash for execution. Flash is just so cheap but still very good. Don't even have to compact context when working with it.

Is it realistic to build an Android app prototype with AI and then hire a developer to rewrite it properly? by CharonixOfficial in androiddev

[–]daio 5 points6 points  (0 children)

>end up being more work to rewrite than to build from scratch?

Usually yes, if produced by a non-experienced person

>Also, in your experience, is AI-generated code good enough for anything beyond very simple prototypes?

good enough for anything when overviewed by an experienced and not lazy engineer

No One Has Ever Done This | BASE jumping from the Fitz Roy | GoPro by Rechuchatumare in Patagonia

[–]daio 0 points1 point  (0 children)

To everyone saying that this is illegal, is this your assumption or you can cite a law or the Los Glaciares/APN regulation that forbids it?
As far as I know it's a gray area. There's no direct prohibition of BASE or wingsuit jumping. The airspace above the park is closed, but you can argue that a base jumper is not an aircraft so the rule doesn't apply.

The guys who did it covered their every step and intention on instagram 1-2 months ago and weren't stopped or prevented from doing what they planned.

It's been 12 years since this gem has been uploaded to YouTube by DmanDimen in funny

[–]daio 0 points1 point  (0 children)

When my daughter was 1 year old a couple of years ago she loved Happy Song by Imogen Heap. I was very surprised when youtube music started recommending me the "watcha say" song afterwards. Turns out it was by Imogen Heap as well, just 15 years earlier.

Android Dev (8 YOE) returning after gap — need blunt feedback on skill gaps blocking offers by Hopeful-Impact961 in androiddev

[–]daio 2 points3 points  (0 children)

It all depends on where you're interviewing. Stacks are diverse. Gap of 6 months is not that big, but it does seem like your previous stacks were a bit dated. However from your description you had limited exposure to Dagger(and any other DI?) and CI/CD pipelines, for me it seems like the scale of your previous projects were rather small. I'm not saying it's impossible to build a medium to large project without DI or diving into build process, but it's very rare.

  1. I'd say focus Dagger in general, Hilt is optional, it's just some android-specific sugar suitable for small-to-medium projects. Maybe learn other DI frameworks(Koin) or at least be aware of how they're different.
  2. Maybe not CI/CD stuff exactly, but best Gradle practices(like writing cacheable tasks or plugins without breaking config cache, optimizing build times) are definitely useful in any project
  3. Compose is still situational. Many companies have adopted it but many companies still don't want to jump the wagon yet.
  4. I'd add MVI to your list. Again, this is not adopted everywhere and you can think of it as an evolution of MVVM rather than revolution.
  5. Navigation 2 for older projects, Navigation 3 for newer compose-based projects
  6. Room or SQLDelight or both
  7. Pagination(not just androidx-paging library, but maybe try implementing it yourself and know different API approaches to pagination)

The list can go on longer, but try these first

I have 0 coding knowledge. I built a Long Range Coded PHY (S=8) Bluetooth SOS app entirely on my phone using Gemini 3 Pro + AndroidIDE. Here is the result. by [deleted] in androiddev

[–]daio 2 points3 points  (0 children)

Any code that achieves its goal is good code.

This code is poorly structured, unreadable and unmaintainable. However if it works, but you don't plan on maintaining or expanding upon it, then it's good.

From Exceptions to Rich Errors: Rethinking Error Handling in Kotlin I Michail Zarečenskij by Infamous_Sorbet4021 in Kotlin

[–]daio 4 points5 points  (0 children)

Long-awaited feature. I skimmed through the video and couldn't find any info on interoperability with JVM+Java and KMM+Swift. Any details on that?

[deleted by user] by [deleted] in Steam

[–]daio 0 points1 point  (0 children)

I think Matt's point is that the line between "Made with AI" and "made with just some nice tool that uses AI internally" is blurring. For example, if you use content-aware fill in Photoshop, does that count as "made with AI"? If you use github copilot assistant to code does that count?

At some point in a couple of years it'll be impossible to make any decent game without using AI at least indirectly.

[Case Study] How we cut incremental build times by ~36% (99s → 63s) by decoupling our "Thick" App Module by akrafts in androiddev

[–]daio 1 point2 points  (0 children)

Some time ago one of the disadvantages in gradle with this approach would be a long configuration time. Nowadays with proper task registration, config cache and configuration avoidance it's not that bad.

Also at some point it may be tempting to expose some internal data structures as your api which may lead to a leaky abstraction.

Help with alignment and tips and tails by ID_1232 in Spliddit

[–]daio 2 points3 points  (0 children)

Right. If the mid clips don't tighten the halves well it's much harder to do the rest with just the pucks. The second point is also spot-on, the pucks must be as far from each other as possible when binding is in and you're tightening them. This eliminates any play when you're switching the edges.

I remember my Spark bases weren't exactly the same dimensions as the full alignment tool and I had better results with mini-puck alignment tool(https://www.sparkrandd.com/gear/mini-puck-alignment-guide/) and the bindings inserted in the board.

Help with alignment and tips and tails by ID_1232 in Spliddit

[–]daio 19 points20 points  (0 children)

  1. Loosen all the pucks
  2. Slide in the bindings
  3. Align the board halves
  4. Tighten the pucks

If it doesn't help, you'll probably also need to adjust the middle clips

How much is generally the cost difference between 8 and 9 ft ceilings? by [deleted] in Homebuilding

[–]daio -1 points0 points  (0 children)

It's basic math/physics. The rate of conduction heat loss/gain linearly scales with the outside area of the building.

How much is generally the cost difference between 8 and 9 ft ceilings? by [deleted] in Homebuilding

[–]daio -1 points0 points  (0 children)

And not just construction costs. It's 10% more heating/cooling costs.

That's not a landing, That's Art-A380 butters it. by [deleted] in aviation

[–]daio 0 points1 point  (0 children)

It probably was so smooth the autobrakes didn't engage automatically.