<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Nitish Gadangi on Medium]]></title>
        <description><![CDATA[Stories by Nitish Gadangi on Medium]]></description>
        <link>https://medium.com/@nitishgadangi?source=rss-38fe773ec71d------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*QOLyl4m-5PbmzeG9wxa2ow.png</url>
            <title>Stories by Nitish Gadangi on Medium</title>
            <link>https://medium.com/@nitishgadangi?source=rss-38fe773ec71d------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Sat, 05 Dec 2026 22:33:43 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@nitishgadangi/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Building Modular iOS Apps That Scale | Part 1: The Foundation]]></title>
            <link>https://nitishgadangi.medium.com/building-modular-ios-apps-that-scale-part-1-the-foundation-2b6c0c05c758?source=rss-38fe773ec71d------2</link>
            <guid isPermaLink="false">https://medium.com/p/2b6c0c05c758</guid>
            <category><![CDATA[ios]]></category>
            <category><![CDATA[swift]]></category>
            <category><![CDATA[mobile-app-development]]></category>
            <category><![CDATA[ios-development]]></category>
            <category><![CDATA[ios-app-development]]></category>
            <dc:creator><![CDATA[Nitish Gadangi]]></dc:creator>
            <pubDate>Sat, 21 Mar 2026 11:47:14 GMT</pubDate>
            <atom:updated>2026-03-21T13:01:45.189Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*TlWy6uudNm-YRlEeW52vOw.png" /></figure><p>The way we build apps has changed. AI can write your networking layer, generate view controllers, and scaffold features in minutes. But the bottleneck has shifted. Writing code is no longer the hard part. Structuring it is. In a world where AI makes everyone a fast coder, the ones who understand structure become the architects that teams actually need.</p><p>This series covers modular architecture, app launch optimization, dependency injection, analytics, configuration, and benchmarking. We start with a solid foundation and improve one piece at a time, tackling real problems as they come up.</p><p>In this first article, we set up the basement. How should an app be structured so that we can plug in new features, swap out libraries, and still have a developer-friendly codebase?</p><blockquote><strong>TLDR; </strong>If you are not patient enough to read through the whole article and want to jump straight to code, here is the <a href="https://github.com/NitishGadangi/ios-modular-arch">GitHub repo</a>. Clone it, open in Xcode, and explore. Totally fine in this short attention span era.</blockquote><h3>What we are building</h3><p>ModularShop is a small, dummy e-commerce app. Four screens, six utility libraries, nothing fancy on the UI side. The idea is to have just enough features to mirror the problems you run into in large-scale, real-world apps. Simple UI, less overwhelming code, but all the structural components intact.</p><p>The entire thing is built with UIKit, Combine, and Swift Package Manager. Zero third-party dependencies. You can clone the repo, open it in Xcode, and everything just resolves.</p><h3>The app at a glance</h3><p>The app has four screens:</p><ul><li><strong>Home</strong>: Fetches and lists products from a remote API.</li><li><strong>Details</strong>: Shows a single product with an “Add to Cart” button.</li><li><strong>Cart</strong>: Lists items the user has added, with a running total.</li><li><strong>Checkout</strong>: A confirmation screen that clears the cart on completion.</li></ul><p>Navigation between these screens supports push, present, and root replacement. The app also handles deeplinks, so you can jump directly to any screen on launch or while the app is running.</p><p>On the library side, we have six shared modules that any feature can use:</p><ul><li><strong>NetworkLib</strong>: HTTP client with request/response logging.</li><li><strong>CacheLib</strong>: Two-tier cache (memory + disk).</li><li><strong>LoggingLib</strong>: Console logger with configurable log levels.</li><li><strong>AnalyticsLib</strong>: Event tracking with batching and flushing.</li><li><strong>ConfigLib</strong>: App configuration with remote config support.</li><li><strong>UIComponents</strong>: Reusable UI elements and extensions.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*pshmsf8xHbBQ9-FCVKjheg.png" /><figcaption><em>All navigation paths between the four screens, including deeplink entry points</em></figcaption></figure><h3>The real deal: Split features into Interface, Implementation and Test modules</h3><p>Here is where the real decisions start. Every feature in ModularShop is split into three distinct parts, and the reason for this split is fundamental to how the entire architecture works.</p><p><strong>Interface module</strong> (HomeInterface): This is the public contract. It contains protocols and shared models only. Nothing concrete. Other modules that need to talk to Home depend on this, not on Home&#39;s actual code. The interface is intentionally thin. Here is the entire HomeBuildable protocol (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/Modules/Home/HomeInterface/Sources/HomeBuildable.swift"><em>View on GitHub</em></a>):</p><pre>public protocol HomeBuildable {<br>    func buildHomeScreen() -&gt; UIViewController<br>}</pre><p>That is the whole file. One protocol, one method. Any module that needs to create a Home screen depends on this protocol, not on the coordinator, not on the view model, not on any of the internal wiring. This is dependency inversion at the module level.</p><p><strong>Implementation module</strong> (Home): This is where the actual code lives. Coordinator, ViewModel, ViewController, Repository, UseCase. All internal. No other feature module ever imports this. The HomeCoordinator conforms to HomeBuildable and handles the construction chain (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/Modules/Home/Home/Sources/Coordinator/HomeCoordinator.swift#L1-L25"><em>View on GitHub</em></a>):</p><pre>public final class HomeCoordinator: HomeBuildable {<br>    private let router: SharedRouterProtocol<br>    private let networkService: NetworkServiceProtocol<br>    // ... other dependencies<br>    public func buildHomeScreen() -&gt; UIViewController {<br>        let repository = HomeRepository(networkService: networkService)<br>        let useCase = GetProductsUseCase(repository: repository)<br>        let viewModel = HomeViewModel(getProductsUseCase: useCase, analytics: analytics)<br>        viewModel.navigationDelegate = self<br>        return HomeViewController(viewModel: viewModel)<br>    }<br>}</pre><p>Notice the imports at the top of the actual file: HomeInterface, SharedRouterInterface, NetworkLib, AnalyticsLib. Only interfaces and libraries. There is no import Details or import Cart anywhere. This is the key rule: <strong>no feature depends on another feature&#39;s implementation.</strong> Home does not know Details exists. Details does not know Cart exists. They communicate through interface protocols, and a shared router handles the actual screen transitions. We will get to that shortly.</p><p><strong>Test target</strong> (HomeTests): Uses @testable import Home to access internals. Stubs and spies are local to the test target. Here is how a typical test looks (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/Modules/Home/HomeTests/HomeViewModelTests.swift"><em>View on GitHub</em></a>):</p><pre>private func makeSUT(products: [ProductSummary] = []) -&gt; HomeViewModel {<br>    let repo = StubHomeRepository(products: products)<br>    let useCase = GetProductsUseCase(repository: repo)<br>    return HomeViewModel(getProductsUseCase: useCase, analytics: StubAnalytics())<br>}<br><br>func testNavigationOnProductSelected() {<br>    let sut = makeSUT()<br>    let spy = SpyNavDelegate()<br>    sut.navigationDelegate = spy<br>    sut.actionHandler.send(.selectProduct(id: &quot;42&quot;))<br>    XCTAssertEqual(spy.receivedEvents.count, 1)<br>    // assert the event is .productSelected with id &quot;42&quot;<br>}</pre><p>The makeSUT() pattern (make System Under Test) wires up just enough to test the ViewModel in isolation. StubHomeRepository returns canned data, StubAnalytics is a no-op, and SpyNavDelegate captures navigation events so we can assert on them. Because every dependency is injected through a protocol, we can stub any of them. This is the testability payoff of the entire module structure.</p><p><strong>Why this three-way split?</strong> Because it gives you real isolation. When a developer changes something inside the Home implementation, the Details module does not recompile. The test target does not accidentally leak internal types into other modules. And if you ever want to run a feature in isolation (say, with its own Xcode scheme for faster iteration), the interface boundary is already clean enough to support that.</p><p>While each feature module can have its own internal architecture, we went with MVVM + Coordinator across the board. ViewModels expose state via CurrentValueSubject and accept actions via PassthroughSubject. Coordinators build screens and handle navigation. Consistent, but not enforced. A new feature could use a different pattern without affecting anything else.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*i6F1D6mHHF8g5yvsHmMQBA.png" /><figcaption><em>Three-part split for the Home feature: Interface, Implementation, and Test modules.</em></figcaption></figure><h3>The dependency graph</h3><p>The module split above gives us a clean dependency graph with a simple rule: features point down to abstractions and libraries, never sideways to other features’ implementations.</p><p>Here is what the Home target’s dependencies look like in Package.swift(<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/Package.swift#L86-L97"><em>View on GitHub</em></a>):</p><pre>.target(<br>    name: &quot;Home&quot;,<br>    dependencies: [<br>        &quot;HomeInterface&quot;,<br>        &quot;SharedRouterInterface&quot;,<br>        &quot;NetworkLib&quot;,<br>        &quot;AnalyticsLib&quot;,<br>        &quot;LoggingLib&quot;,<br>        &quot;UIComponents&quot;,<br>    ],<br>    path: &quot;Modules/Home/Home/Sources&quot;<br>),</pre><p>HomeInterface and SharedRouterInterface are abstractions. NetworkLib, AnalyticsLib, LoggingLib, and UIComponents are self-contained utility libraries. There is no Details, Cart, or Checkout anywhere in that list.</p><p>This matters for a few concrete reasons:</p><p><strong>Build times.</strong> When someone changes a file inside the Details module, Xcode does not recompile Home. In a monolithic target, any change recompiles everything. With four features this barely matters. With forty, it is the difference between a 10-second incremental build and a 2-minute one.</p><p><strong>Parallel development.</strong> Two developers working on Home and Details at the same time will not step on each other’s code. Their modules do not share implementation files. Merge conflicts drop dramatically.</p><p><strong>Separation of concerns.</strong> Each feature owns its own domain logic, its own data layer, its own view layer. There is no shared “Models” folder where every feature dumps its types. If Home needs a ProductSummary model, it lives in HomeInterface. If Details needs a ProductDetail model, it lives in DetailsInterface.</p><p>The same pattern applies across the board. Details depends on DetailsInterface, SharedRouterInterface, and CartInterface (because it needs to add items to cart). But it imports CartInterface, not Cart. It knows the protocol for adding to cart. It does not know or care how cart storage is implemented.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*OKc4T5vi7WizMp_6VJp-nw.png" /><figcaption><em>Full dependency graph across all modules.</em></figcaption></figure><h3>SPM: One Package.swift for everything</h3><p>All of these modules, every library, interface, feature, and test target, are defined in a single Package.swift file. No CocoaPods, no Carthage, no scattered xcframework references. One file describes the entire module graph. (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/Package.swift#L1-L30"><em>View on GitHub</em></a>)</p><pre>let package = Package(<br>    name: &quot;ModularShop&quot;,<br>    platforms: [.iOS(.v17)],<br>    products: [<br>        // Libraries<br>        .library(name: &quot;LoggingLib&quot;, targets: [&quot;LoggingLib&quot;]),<br>        .library(name: &quot;NetworkLib&quot;, targets: [&quot;NetworkLib&quot;]),<br>        // ... other libraries<br><br>        // Interface modules<br>        .library(name: &quot;SharedRouterInterface&quot;, targets: [&quot;SharedRouterInterface&quot;]),<br>        .library(name: &quot;HomeInterface&quot;, targets: [&quot;HomeInterface&quot;]),<br>        // ... other interfaces<br><br>        // Concrete modules<br>        .library(name: &quot;SharedRouter&quot;, targets: [&quot;SharedRouter&quot;]),<br>        .library(name: &quot;Home&quot;, targets: [&quot;Home&quot;]),<br>        // ... other features<br>    ],<br>    dependencies: [],<br>    // targets: [ ... ]<br>)</pre><p>The advantage of this approach is simplicity. You clone the repo, open in Xcode, and SPM resolves everything. No setup scripts, no dependency managers to install, no pod install that takes 3 minutes. Adding a new module means adding a few lines to this file. The full Package.swift has all 17 library products and their corresponding targets, including test targets with their dependencies. Check the repo for the complete file.</p><h3>SharedRouter: Cross-module navigation</h3><p>This is where the “features do not know about each other” promise gets tested. When the user taps a product on the Home screen, Home needs to show the Details screen. But Home does not import Details. It does not even know Details exists. So how does navigation work?</p><p>The answer is a shared router that sits between all features. Features tell the router <em>what</em> they want to navigate to (a route), and the router figures out <em>how</em> to build that screen and present it.</p><p>The routing contract lives in SharedRouterInterface as three small types (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/Modules/SharedRouter/SharedRouterInterface/Sources/"><em>View on GitHub</em></a>):</p><pre>public enum Route: Equatable {<br>    case home<br>    case productDetail(productId: String)<br>    case cart<br>    case checkout<br>}<br><br>public enum NavigationStyle {<br>    case push<br>    case present(fullScreen: Bool = false)<br>    case replaceRoot<br>}<br><br>public protocol SharedRouterProtocol: AnyObject {<br>    func navigate(to route: Route, style: NavigationStyle)<br>}</pre><p>Route defines every possible destination. NavigationStyle controls how we get there. And SharedRouterProtocol is what features actually depend on. This is all in the Interface module, so every feature can use it without depending on the concrete router.</p><p>The concrete SharedRouter is the only module that knows about all the feature builders. It receives them through init, maps routes to screens, and performs the navigation (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/Modules/SharedRouter/SharedRouter/Sources/SharedRouter.swift#L29-L56"><em>View on GitHub</em></a>):</p><pre>public func navigate(to route: Route, style: NavigationStyle) {<br>    let viewController = buildScreen(for: route)<br>    switch style {<br>    case .push:<br>        navigationController?.pushViewController(viewController, animated: true)<br>    case .present(let fullScreen):<br>        // handle modal presentation<br>    case .replaceRoot:<br>        navigationController?.setViewControllers([viewController], animated: true)<br>    }<br>}<br><br>private func buildScreen(for route: Route) -&gt; UIViewController {<br>    switch route {<br>    case .home: return homeBuilder.buildHomeScreen()<br>    case .productDetail(let id): return detailsBuilder.buildDetailsScreen(productId: id)<br>    case .cart: return cartBuilder.buildCartScreen()<br>    case .checkout: return checkoutBuilder.buildCheckoutScreen()<br>    }<br>}</pre><p>Notice that SharedRouter depends on HomeBuildable, DetailsBuildable, CartBuildable, CheckoutBuildable. Those are all interface protocols. It does not import any feature&#39;s implementation module. The concrete coordinators get injected from the outside (by CompositionRoot, which we will get to).</p><p>Back in the Home module, the coordinator uses the router through its delegate. When the ViewModel fires a navigation event, the coordinator translates it into a route (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/Modules/Home/Home/Sources/Coordinator/HomeCoordinator.swift#L27-L36"><em>View on GitHub</em></a><em>)</em>:</p><pre>extension HomeCoordinator: HomeViewModelNavigationDelegate {<br>    func homeViewModel(_ viewModel: HomeViewModel, didRequest event: HomeViewModel.NavigationEvent) {<br>        switch event {<br>        case .productSelected(let id):<br>            router.navigate(to: .productDetail(productId: id), style: .push)<br>        case .cartTapped:<br>            router.navigate(to: .cart, style: .push)<br>        }<br>    }<br>}</pre><p>The flow is: user taps a product -&gt; ViewModel sends a .selectProduct action -&gt; Coordinator catches it via delegate -&gt; Coordinator tells the router &quot;navigate to .productDetail&quot; -&gt; Router builds the Details screen and pushes it. Home never touches Details directly. The router is the single orchestrator for all cross-module navigation.</p><h3>AppConfigurator: Managing app launch</h3><p>Before any screen appears, there is work to do. Config needs to load. Logging needs to initialize. The network layer needs a base URL. Analytics needs to know if it is enabled. All of this has to happen before the first ViewController is presented.</p><p>AppConfigurator puts all of that under one roof. A single performLaunchSetup() call that runs each step and measures the total time (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/ModularShop/Core/AppConfigurator.swift#L26-L38"><em>View on GitHub</em></a>):</p><pre>func performLaunchSetup() {<br>    let startTime = CFAbsoluteTimeGetCurrent()<br><br>    setupConfig()<br>    setupLogging()<br>    setupNetwork()<br>    setupAnalytics()<br>    setupCache()<br>    setupAppearance()<br><br>    let durationMs = (CFAbsoluteTimeGetCurrent() - startTime) * 1000<br>    logger.info(&quot;App launch setup completed in \(String(format: &quot;%.2f&quot;, durationMs))ms&quot;)<br>}</pre><p>Each setup method receives its dependencies through the initializer (logger, config provider, analytics service, network service), does its configuration, and logs what it did. The timing measurement at the end gives us a baseline number for launch performance.</p><p>This is straightforward and it works. But it is also the simplest possible approach, and it will not scale. Right now we have six steps that run in under a millisecond. In a real production app, you might have twenty steps: remote config fetches, database migrations, feature flag evaluation, A/B test assignment, push notification registration. Some of these are slow. Some depend on each other. Some could run in parallel but do not because everything is sequential.</p><p>We will tackle this properly in the next article using NSOperation and OperationQueue, where each step becomes an operation with explicit dependencies and the queue handles parallelism for us.</p><h3>CompositionRoot: Wiring it all together</h3><p>We have features behind protocols, libraries behind protocols, a router behind a protocol. Now someone has to actually create the concrete instances and connect them. That is what CompositionRoot does.</p><p>This is the single place in the entire app that imports both interface and implementation modules. It creates the libraries, creates the coordinators, creates the router, and returns the first screen. Every protocol meets its concrete type here and nowhere else.</p><p>But there is an interesting problem. Coordinators need a router to navigate. The router needs coordinators (as builders) to construct screens. Neither can be created first. Classic chicken-and-egg.</p><p>The workaround is LazyRouter: a lightweight proxy that conforms to SharedRouterProtocol but defers the actual routing to a closure that resolves later (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/ModularShop/Core/CompositionRoot.swift#L98-L112"><em>View on GitHub</em></a>):</p><pre>private final class LazyRouter: SharedRouterProtocol {<br>    private let resolver: () -&gt; SharedRouterProtocol?<br><br>    init(_ resolver: @escaping () -&gt; SharedRouterProtocol?) {<br>        self.resolver = resolver<br>    }<br><br>    func navigate(to route: Route, style: NavigationStyle) {<br>        resolver()?.navigate(to: route, style: style)<br>    }<br>}</pre><p>With this in place, assembleAndStart() can create coordinators first (with a LazyRouter that will resolve to the real router), then create the real router with those coordinators, and everything connects (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/ModularShop/Core/CompositionRoot.swift#L56-L91"><em>View on GitHub</em></a>):</p><pre>func assembleAndStart() -&gt; UIViewController {<br>    homeCoordinator = HomeCoordinator(<br>        router: LazyRouter { [weak self] in self?.router },<br>        networkService: networkService,<br>        analytics: analyticsService<br>    )<br>    // ... same pattern for Details, Cart, Checkout coordinators<br>    router = SharedRouter(<br>        navigationController: navigationController,<br>        homeBuilder: homeCoordinator,<br>        detailsBuilder: detailsCoordinator,<br>        cartBuilder: cartCoordinator,<br>        checkoutBuilder: checkoutCoordinator<br>    )<br>    return homeCoordinator.buildHomeScreen()<br>}</pre><p>By the time the user actually taps something and triggers navigation, the real router is already set. The LazyRouter resolves to it, and everything works.</p><p>The boot sequence in SceneDelegate ties it all together. This is the entry point of the app (<a href="https://github.com/NitishGadangi/ios-modular-arch/blob/3b24d4a/ModularShop/SceneDelegate.swift#L9-L34"><em>View on GitHub</em></a>):</p><pre>let navigationController = UINavigationController()<br>compositionRoot = CompositionRoot(navigationController: navigationController)<br><br>// Configure all services before anything else<br>compositionRoot.appConfigurator.performLaunchSetup()<br><br>// Wire up all modules and get the first screen<br>let rootVC = compositionRoot.assembleAndStart()<br>navigationController.viewControllers = [rootVC]<br><br>window = UIWindow(windowScene: windowScene)<br>window?.rootViewController = navigationController<br>window?.makeKeyAndVisible()<br><br>// Deeplink handling<br>deeplinkHandler = compositionRoot.makeDeeplinkHandler()</pre><p>The order matters: create the navigation controller, create the CompositionRoot, run launch setup (config, logging, network, analytics, etc.), assemble all the modules, set the root screen, then make the window visible. Deeplink handling is set up last so it has access to the fully wired router.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*Ir0ySwAdZ3EP9GYMgeMS4Q.png" /><figcaption><em>Boot sequence from SceneDelegate to the first visible screen.</em></figcaption></figure><h3>Why does any of this matter?</h3><p>You could build a four-screen app in a single Xcode target and ship it in a day. So why go through all this structure?</p><p>Because apps do not stay four screens forever. Features get added. Teams grow. And the decisions you make early shape whether adding the tenth feature feels the same as adding the second, or whether it requires untangling months of accumulated coupling.</p><p>With this setup, adding a new feature is mechanical: create its Interface and Implementation modules, add the target to Package.swift, wire it up in CompositionRoot. The existing features do not change. Need to replace the networking library? Write a new one that conforms to NetworkServiceProtocol. No feature code changes. Two developers working on different features? Their modules are isolated. They can work, build, and test independently without waiting on each other.</p><p>And because every dependency is injected through a protocol, testing is natural. You do not need a running app to test business logic. Stub the network, stub analytics, stub the router, and test the ViewModel in isolation.</p><p>This is not over-engineering. It is the minimum viable structure. Just enough boundaries to keep a growing codebase from becoming a monolith where every change touches everything.</p><h3>What is not great yet</h3><p>This foundation works, but there are problems worth calling out honestly.</p><h4>Issue 1: CompositionRoot and SharedRouter</h4><p>Look at assembleAndStart() again:</p><pre>func assembleAndStart() -&gt; UIViewController {<br>    // All four coordinators created eagerly, even though<br>    // only Home is needed at launch. At 40 features, this hurts.<br>    homeCoordinator = HomeCoordinator(<br>        router: LazyRouter { [weak self] in self?.router },  // &lt;-- hack: resolver returns nil until router is set<br>        // ...<br>    )<br>    // ... Details, Cart, Checkout all created here too<br><br>    router = SharedRouter(<br>        // demands ALL builders upfront<br>        homeBuilder: homeCoordinator,<br>        detailsBuilder: detailsCoordinator,<br>        cartBuilder: cartCoordinator,<br>        checkoutBuilder: checkoutCoordinator<br>    )<br>    return homeCoordinator.buildHomeScreen()<br>}</pre><p>SharedRouter demands all builder instances through its init. This forces CompositionRoot to eagerly create every coordinator upfront. LazyRouter is a hack to break the circular dependency, and if navigate is called before assembly finishes, it silently does nothing. On top of that, SharedRouter has no protection against double-present race conditions when two .present navigations fire back to back.</p><h4>Issue 2: Synchronous AppConfigurator</h4><pre>func performLaunchSetup() {<br>    // Everything runs serially on the main thread.<br>    // setupAnalytics() waits for setupConfig() to finish, fine.<br>    // But setupCache() and setupAppearance() have zero dependencies<br>    // on each other. They could run in parallel but don&#39;t.<br>    setupConfig()<br>    setupLogging()<br>    setupNetwork()<br>    setupAnalytics()<br>    setupCache()<br>    setupAppearance()<br>}</pre><p>Six lightweight steps in milliseconds is fine. But add remote config fetches, database migrations, feature flag evaluation, and serial execution starts blocking the main thread and delaying the first frame.</p><p>We will solve both of these in the upcoming articles. A proper DI container for lazy dependency resolution and navigation queuing. NSOperation and OperationQueue for parallel, dependency-aware launch steps. Stay tuned.</p><h3>Feedback</h3><p>I have put together what I think is a solid starting point, but there is always room for different approaches. If you have built something similar and made different trade-offs, I would genuinely like to hear about it.</p><p>If you found this useful, like/clap this article and follow along for the rest of the series on <a href="https://medium.com/@nitishgadangi">Medium</a>, <a href="https://nitishgadangi.hashnode.dev/">Hashnode</a>, and <a href="https://www.linkedin.com/in/nitish-gadangi/">LinkedIn</a>.</p><p>The repo is open source. Feel free to explore, fork, or contribute</p><p><a href="https://github.com/NitishGadangi/ios-modular-arch">GitHub - NitishGadangi/ios-modular-arch: Yet another iOS modular architecture sample - but this one&#39;s worth stealing from.</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2b6c0c05c758" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Android CI/CD with GitLab — Slack bot that can build Apks on the fly.]]></title>
            <link>https://nitishgadangi.medium.com/android-ci-cd-with-gitlab-slack-bot-that-can-build-apks-on-the-fly-a877e26307db?source=rss-38fe773ec71d------2</link>
            <guid isPermaLink="false">https://medium.com/p/a877e26307db</guid>
            <category><![CDATA[android]]></category>
            <category><![CDATA[gitlab]]></category>
            <category><![CDATA[slackbot]]></category>
            <category><![CDATA[ci-cd-pipeline]]></category>
            <category><![CDATA[slack]]></category>
            <dc:creator><![CDATA[Nitish Gadangi]]></dc:creator>
            <pubDate>Sun, 02 May 2021 06:01:48 GMT</pubDate>
            <atom:updated>2021-10-17T13:14:11.006Z</atom:updated>
            <content:encoded><![CDATA[<h3>Android CI/CD with GitLab — Slack bot that can build Apks on the fly.</h3><p>I recently realized most of the Engineers at our workplace have stuck in this constant loop of Building Apks and passing it over to the QA team on Slack. All that we do every time is, manually build the Apk from the feature branch which we are working on and upload it to Slack for the QA team to get it tested. If any changes come in between or later the loop goes on again. You got the point right! So, Why do it manually when you can make it automated. 🤷‍♂️</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1000/1*r-YCy6is_BXIjwC14Ah9Hg.jpeg" /></figure><p>So let&#39;s use the power of GitLab CI and combine it with Slack API to build a bot that will give you the list of all the available branches on our repo, and on select, the corresponding repo will be built and Apk will be uploaded to Slack.</p><h3>Goals</h3><ol><li>Interactive Slack-bot that displays all available branches on the repo. (We will be using <a href="https://api.slack.com/legacy/message-menus">Message Menus</a> from Slack API)</li><li>Setup a GitLab CI with a job that will run only when <a href="https://docs.gitlab.com/ee/ci/triggers/">triggered</a> by our Slack-bot.</li><li>Automatically build app variants on CI for selected repo on slack and upload it back to slack.</li><li>Additionally, let&#39;s add few more features like options to check the status of the CI Job. Help command that provides instructions on how to use the bot. (We will be using <a href="https://api.slack.com/interactivity/slash-commands">slash commands</a> from Slack API).</li><li>Finally, let&#39;s ensure that the Specific user who requested for Apk is pinged when the Apk build is successfully finished.</li></ol><h3>TL;DR</h3><p>If you are right way interested to dig into code. Here is the spoiler. Also you can go right to the bottom to check out the final functionality.</p><p><a href="https://github.com/NitishGadangi/apk-dispatcher-slack-bot">NitishGadangi/apk-dispatcher-slack-bot</a></p><h3>Required Ingredients</h3><ol><li>We need a CI/CD instance for this. Fortunately, GitLab has a simple and free CI/CD system that is available in private repositories.</li><li>You must have permission to create a new Slack App and launch it in your Workspace.</li><li>As we are going to use Slash commands for Slack-bot, we need an HTTP instance that responds to calls from Slack. (We will be using a simple Node.js app deployed on Heroku)</li><li>Obviously some basic understanding of how CI/CD works and some knowledge on Node.</li></ol><h3>Let&#39;s start cooking…</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*0uoIFZUYSi680yq4-BQBmA.png" /><figcaption>Flow of the implementation</figcaption></figure><h4>GitLab Setup</h4><p>You need to add CI/CD configuration file to you GitLab repo. This can be done by adding <strong>.gitlab-ci.yml </strong>file to the Android project root. For further detailed walkthrough you can always go through the documentation <a href="https://gitlab.com/help/ci/quick_start/README">here</a>.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*VbZsz12NQkBYrYZjqHe_EQ.png" /></figure><p>The CI configuration yml file essential consists all the instructions required to run the CI pipeline. For environment setup, we can run the standard Android SDK instance. However, we can use the <a href="https://docs.docker.com/get-started/part2">Docker image</a> by <a href="https://github.com/jangrewe/gitlab-ci-android">Jangrewe</a> which is pre-configured for Android. Later we need to add remaining instructions that help to build Apk and upload on to slack. Here is how it looks finally.</p><iframe src="" width="0" height="0" frameborder="0" scrolling="no"><a href="https://medium.com/media/9313105200d61004f002104c5a13b5ce/href">https://medium.com/media/9313105200d61004f002104c5a13b5ce/href</a></iframe><p>Before moving further lets look into the above configuration file and understand keyword and their use:</p><ol><li><strong>image: </strong>This tag is used to specify a Docker image to be used for execution. Gitlab runners will use this Docker image to run the pipeline.</li><li><strong>cache: </strong>Caching the gradle folder significantly reduces the build time when generating multiple builds. The cache will be downloaded and extracted at the beginning and uploaded at the end of every job. ${CI_PROJECT_ID}is the unique project ID in Gitlab.</li></ol><p>Now, we define a <strong>job </strong>to build a debug APK and its contents are explained below.</p><ol><li><strong>stages: </strong>This signifies which stage the job belongs to.</li><li><strong>before_script: </strong>This is used to set up stuff before the actual work is started. In our case, we set GRADLE_USER_HOME to avoid using the complete path to gradle, and make the gradlew executable.</li><li><strong>rules: </strong>Here, we can define various conditions such that the job runs only when based on these specified <a href="https://docs.gitlab.com/ee/ci/yaml/#rules">rules</a>. As we need our job to be running only when triggered manually, we are adding an if condition specifying the $CI_PIPELINE_SOURCE must be a <a href="https://docs.gitlab.com/ee/ci/triggers/">trigger</a>.</li><li><strong>script: </strong>The shell script executed by the Gitlab Runner. It is the only mandatory keyword for a job to run.</li></ol><ul><li>Firstly, we run the command to assemble the debug build</li><li>After the build is generated, we use <strong>curl, </strong>a command line tool to transfer data.</li><li>Also, ${SLACK_CHANNEL_ID} and ${SLACK_REFERRER_ID} are used to refer to the channel from where user triggered the pipeline and the corresponding user id for mentioning him to give a notification. These two variables will be sent by our Node.js App which inturn is triggered by Slack-bot.</li><li>Similarly we also used ${CI_COMMIT_REF_NAME} and ${CI_PIPELINE_ID} to add more info to the message along with the Apk.</li><li>Finally for file upload, Slack defines a pretty easy-to-use <a href="https://api.slack.com/methods/files.upload">API</a>. Put the file name of generated APK (for example, <em>app-debug.apk</em>). If your gradle generates distinct build names as per the build version/type then use the find command with the initial characters of the file, as shown above.</li></ul><p><strong>Node.js App setup</strong></p><p>As we gonna use <a href="https://api.slack.com/interactivity/slash-commands">slash commands</a> for our slack bot, we need to have a server application that can respond to incoming requests from slack-api. I would like to keep things as short as possible. Here we go.</p><ol><li>Clone this repo (<a href="https://github.com/NitishGadangi/apk-dispatcher-slack-bot">apk-dispatcher-slack-bot</a>)</li><li>Here we can observe we will be having the base route as /android under which there 4 more post routers available.</li></ol><ul><li>/android/actions is used as Request URL for Interactivity actions in slack. Any interactions interactive components (such as buttons, select menus, and datepickers) will be sent to this end point.</li><li>/android/get_apk , /android/help , /android/get_status are triggered from slash commands and each of it will do corresponding actions and post the response back to slack-api.</li></ul><p>We also need to provide the environment variables by placing them in .env file or placing in Config vars(in case you use heroku) when deployed. We get back to this part later for now you can deploy the project directly.</p><p>That being said you can always look at the complete code base to get more clarity on what actually happening in the back. Anyway lets move forward.</p><p><strong>Slack App setup</strong></p><p>Lastly, we need to create own slack app for our workspace and link it to our node.js app.</p><ol><li>Login to your slack workspace, or create one at <a href="https://slack.com/create#email">Slack Workspace</a>.</li><li>Go to the <a href="https://api.slack.com/apps">Apps</a> section, and create a new app. All you need to enter is App Name, and select the workspace from drop down. In the first page of App Settings add in basic details of your app under display info section.</li><li>Under Features go to <strong>OAuth &amp; Permissions, </strong>first install the app to your works space and copy and secure the Bot User OAuth Token. And below under <strong>Scopes </strong>section add the following <strong>OAuth Scopes, </strong><a href="https://api.slack.com/scopes/commands">commands</a> and <a href="https://api.slack.com/scopes/files:write">files:write</a> .</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/1*YSOMyGqiqeZqc6j74QXP4g.png" /></figure><p>4. Next go to <strong>Interactivity &amp; Shortcuts </strong>section under <strong>Features </strong>. Turn on the <strong>Interactivity </strong>and paste the /actions end point of your Node.js App after its deployment.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/800/1*tiuO6FhNkJjw_Gt-WIzi1w.png" /></figure><p>5. Finally go to <strong>Slash Commands </strong>section under features and <strong>Create new command. </strong>Here we are planning to have 3 slash commands and therefore we have 3 corresponding end points in our backend. Add the slash commands, its request URL and the description as requied.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/867/1*GamNQraj9PoTAyyEcC8GEw.png" /></figure><p>The Slack App is ready and we are good to go. However we have to bind together all the pieces in order to make them work together.</p><p><strong>Lets bind all of them…</strong></p><p>As we have discussed before, we need to specify the environment variables In our Node App inorder to make it functional. Let look in how we can fetch each of those environment variables and later we can place them into <a href="https://devcenter.heroku.com/articles/config-vars">Config Vars</a> in out Heroku settings.</p><p><strong>SLACK_CHANNEL_ACCESS_TOKEN:</strong> This can be fetched from <strong>OAuth &amp; Permissions </strong>section from your Slack App setup. It has been discussed above in step-3 of Slack App setup.</p><p><strong>AUTH_TOKEN: </strong>This is basically your GitLab Personal Access Token. You can fetch it from your <a href="https://gitlab.com/-/profile/personal_access_tokens">GitLab profile preferences → Access token</a> and create one for you. (scope read_repository is enough for our use case).</p><p><strong>TRIGGER_TOKEN: </strong>Go to your GitLab repo Settings → CI/CD and under <strong>Pipeline triggers</strong> , add trigger. Copy the Token and that will be your TRIGGER_TOKEN . You can read more about triggers from <a href="https://docs.gitlab.com/ee/ci/triggers/">here</a>.</p><p><strong>PROJECT_ID: </strong>Under the same <strong>Pipeline triggers</strong> section from cUrl copy the project id. You can refer the below image.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*AUF7O2_Oj_WsmiN5HoQXTQ.png" /><figcaption>The underlined number is the PROJECT_ID</figcaption></figure><p>Now that we got all the variables required lets place it in the <a href="https://devcenter.heroku.com/articles/config-vars">Config Vars</a> section in Heroku, and the final state looks like this.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1021/1*HdjvLhHSkEXq7vyF-2EmzA.png" /></figure><p><strong>Finally, lets test the functionality…</strong></p><p>Jump on to your slack workspace and invite our all new Slack bot to any channel where you want to use it. Start typing any slack commands by typing <strong>/ </strong>followed by the command. Slack will automatically start suggesting all the available slash commands.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/502/1*yDSvBriB-_iOvfjx4mxmxw.png" /><figcaption>All three slash commands which we have added before are listed.</figcaption></figure><p>Here we are having 3 slash commands lets test all of them.</p><p>Doing <strong>/help</strong> will give us following instruction on how to use the bot.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/836/1*z_F2whjrfH1dhpPstClQqg.png" /><figcaption>/help</figcaption></figure><p>Doing<strong> /get_apk </strong>will prompt you with a drop down menu asking you to select a branch from which you want to get build and get the apk.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/847/1*B3OsguD_Bdi8EleEwkqS4A.png" /></figure><p>Once you select any branch it will give you details about the branch selected and estimated time for the build. Also a ticked_id is provided which can be later used to know the status of the pipeline if required.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/836/1*Nzl1EmrJk6gT_kaMktdbAg.png" /><figcaption>on select of a branch</figcaption></figure><p>The given ticked_id can be use in combination with <strong>/get_status </strong>to know the status of the build process.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/842/1*DnFGT5a3NQoVo9P9K4eu9w.png" /><figcaption>/get_status [ticket_id]</figcaption></figure><p>Finally once the build has finished the bot will ping you with the final Apk.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/838/1*eedzaHYr-yKBzUif5wHwaQ.png" /></figure><p>Yeah ! Thats the whole App which we have built. You can always extend it further by adding more slash commands or adding more instructions to CI config. Anyway, I would say this is more that enough.</p><p>That being said I hope you have understood the whole build and hope you like this implementation. In case of any doubts comment down below.</p><p>Finally, I would like to attach two other Medium articles which broadly helped me during the whole process. Credits to them too. 🎉</p><ul><li><a href="https://proandroiddev.com/a-quick-guide-to-setup-gitlab-ci-cd-for-android-6bb5faec1491">A Quick Guide to Setup Gitlab CI/CD for Android</a></li><li><a href="https://medium.com/@pallavtrivedi03/slack-app-bot-users-interactive-components-slash-commands-and-more-6b34d58c4d11">Slack App : Bot Users, Interactive Components, Slash Commands and more</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a877e26307db" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[MLH Fellowship: Memories that I always love to bring back.]]></title>
            <link>https://nitishgadangi.medium.com/mlh-fellowship-memories-that-i-always-love-to-bring-back-12f74cdebe8b?source=rss-38fe773ec71d------2</link>
            <guid isPermaLink="false">https://medium.com/p/12f74cdebe8b</guid>
            <category><![CDATA[fellowship]]></category>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[mlh]]></category>
            <category><![CDATA[github]]></category>
            <dc:creator><![CDATA[Nitish Gadangi]]></dc:creator>
            <pubDate>Thu, 14 Jan 2021 12:04:44 GMT</pubDate>
            <atom:updated>2021-01-14T12:04:44.397Z</atom:updated>
            <content:encoded><![CDATA[<p>You know they say “part of the journey is the end” right? So, this October 2020, I started a small journey alongside the journey of shaping the better me. A journey with Major League Hacking and 12 strangers turned friends.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*fhjCH0H6fmbDUIB2donqqg.jpeg" /><figcaption>FellowMap</figcaption></figure><p>Not gonna lie, the day I woke up and saw my acceptance mail, it felt so unreal that I pinched myself, just to confirm I am not in a dream. Yes, it&#39;s real that I am one among those 170 Fellows who got selected from 22 countries and 30k+ applications. Every moment that Nitish experienced till this day is pretty darn real.</p><p>If you haven&#39;t read about the back story of me, getting selected for the MLH Fellowship, I highly recommend you to go through that article before proceeding further. (Trust me it&#39;s nowhere less than a Thriller story 😉)</p><p><a href="https://nitishgadangi.medium.com/i-selected-for-mlh-fellowship-twice-but-accepted-once-7b2d41c8d3e7">I selected for MLH Fellowship twice but accepted once.!</a></p><blockquote>I am writing this article because there are some amazing moments that I wanted to look back and appreciate what I and my friends were able to learn and achieve in those 12 weeks of Fellowship. It can also give you an insider perspective of being an MLH Fellow. So sit back and hold tight while I take you through my MLH Fellowship Experience. 🚀</blockquote><h4>First things first, Whats is MLH Fellowship?</h4><p>In the words of MLH, “<a href="https://fellowship.mlh.io/"><em>MLH Fellowship</em></a><em> is an internship alternative by Major League Hacking (powered by GitHub and Facebook) where students contribute to open source projects that are used by millions of developers worldwide.</em>”</p><p>In simple terms, it&#39;s more of a mixed bag of good things that are picked from Internship, opensource, mentorship, and hackathons.</p><p><strong>Ok Now, let&#39;s get back to the real experience…!</strong></p><p>Oct 6, 2020 (10 AM IST): Day1, the first-ever official meet (of course on Zoom) after filling and signing up all the required onboarding docs. This day I got to meet all our amazing pod mates and equally amazing pod leader.</p><p><strong>The Interaction session:</strong> This meeting is intended to get everyone to connect with each other and it was planned so well that it exactly reassembled those initial ragging (sorry interaction**) sessions with my seniors in my first year of BTech 😂. All the 12 Fellows of the pod are randomly distributed into 6 different rooms, i.e 2 per each where each one has to get to know about the other in such a way that he/she should introduce the other person to the whole pod in the best way possible and the same goes with everyone.</p><p>Once it&#39;s done we got to went on to decide a name for our pod 1.0.2. The theme is ‘Birds’. After enough brainstorming decided to go with BitLoons. And yeah later we also designed a logo for the same 😅.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/500/1*NGfa98ZynU2hRRd9hRMTsQ.jpeg" /></figure><p>The next days of the week, we need to schedule mandatory one-on-one calls with every other pod mate in order to get to know each other (yeah that is 12 calls of 30mins each). But trust me these meetings not just allowed us to get to know each other but quickly established a bond with each other so well.</p><p>Along with that we were supposed to work on a project for the Orientation hackathon with a team of 3 (which again is randomly selected). If you want to have a look at what our team has worked on, check this out</p><p><a href="https://github.com/MLH-Fellowship/CovidAid">MLH-Fellowship/CovidAid</a></p><p>By the end of week2, we are done with Hackathon and got assigned to the respective projects which we are supposed to work on in the next coming weeks. But this is where the actual fun begins…</p><h4>Here is how a standard week looks like:</h4><p><strong>StandUp: </strong>where we discuss what we have been doing since yesterday, what we are planning do today, and also about the blockers and shoutouts if any.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/627/1*SfFhhpQs6C-RgtGmp2QCtA.jpeg" /><figcaption>That&#39;s how a normal standUp looks like</figcaption></figure><p><strong>Show &amp; Tells:</strong> where every week each fellow gets a chance to demo something interesting to the whole pod (preferably non-technical but not always). We discussed Novels, Art, Maths, Design, Inclusiveness ….</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*jfMeZQCdLvVVH8l-qKRl8A.jpeg" /><figcaption>Here is one about paradoxes in Mathematics by Garima</figcaption></figure><p><strong>Retrospectives: </strong>Retros were the most valuable times in the fellowship as we used to reflect on our traffic lights for the week i.e., what went wrong (Reds), what can be improved (Yellows), and what we did well (Greens).</p><p><strong>Team Building Activities: </strong>These are the most interesting ones ever, I can only wish we had more of these. Basically, these are some games/activities which help in building team participation. Scavenger Hunt, Guess the Lie, are some of them</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*yD4CefAjbmSOwFFjZphHrg.jpeg" /><figcaption>A small sneak peek: Guess the Lie | Scavenger hunt</figcaption></figure><p><strong>Weekly Mentor Meet: </strong>We get to meet our mentors <a href="https://www.linkedin.com/in/cory-massaro-94403465/">Cory Massaro</a> and <a href="https://www.linkedin.com/in/chrisewald8/">Chris Ewald</a> where we discuss the progress of the project and the blockers with the maintainer. We also had an amazing Meditation session with Chris 🧘‍♂️</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*hCxVT1Ybpg-UreZ1nYgVIg.jpeg" /><figcaption>A usual meet with our mentors</figcaption></figure><p><strong>Developer Round Table: </strong>In a<strong> </strong>typical round table conference, we would have an open discussion within our pod on a predecided topic (mostly non-technical).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*8NiaRYDBSUyFzxsK97s0Sg.jpeg" /></figure><p>Finally not but not the least,<strong> the late-night gaming sessions</strong> where we hang out on discord and play AmongUs, Skribble, CodeWords to an extent where I got trained to be a Pro Skribble player in no time 😂 (still can&#39;t beat Kunal, Ayush).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*uJTukXW0w-XZ-5-sp-6ikg.jpeg" /><figcaption>Sorry, unable any screenshots of AmongUs or Codewords 😅</figcaption></figure><p>In the Midway of the Fellowship there is another <a href="https://devpost.com/software/project-folio">Hackthon </a>and also the very famous and highly exciting CTF challenge which is conducted in the final week of the Fellowship. In simple terms those events were just continuous adreline rush and equally helping us to explore all new tech. <br>Here is a snapshot of MLH CTF leaderboard where our team (flag captured) managed to stay on top 😁 for a while. Special credits to <a href="https://www.linkedin.com/in/iamabhishek0/">Abhishek</a> for staying up all night to solve those challs which were dropped in the late night.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*ZujYyZYKk-S11mODp0DZxw.png" /></figure><p>There are several other optional tech events and workshops going on every week. All these events are continuously added to the calender, so one thing which you instantly learn after coming to Fellowship is good calender habits. Everyday soon after we wakeup, can look at the calender and plan our schedule accordingly.</p><p>Also forgot to mention, we were put on to a common <em>MLH Fellowship Discord Server</em> where fellows from all different pods can interact. We usually used to hang around in the voice channels discussing various things during our free time (which sometimes won&#39;t even make sense 😂). Here is one such occasion where <a href="https://awalvie.me/">Vishesh</a> is performing a private Magic Session for me and <a href="https://twitter.com/_pandafy_">Gagan</a>. (I know you guys are not expecting this to be here 😛).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*2ZSL6lfLtGDT2rYhVwm5Zg.jpeg" /></figure><h4><strong>So when are you even working?</strong></h4><p>Yeah, after all this. It&#39;s ok to have this thought in mind. I will try to keep this brief as the blog is about the fellowship experience.<br>All of us were assigned to various projects and we were actively working on them at the same time. One thing I liked, in particular, was <em>flexible work hours</em>. There is no constraint to when a fellow must work on the project. By the end of the Fellowship, everyone is supposed to complete the tasks assigned to us. I am assigned to project <a href="https://github.com/JuliaEarth/GeoStats.jl">GeoStats.jl</a> which is currently under the JuliaEarth organization. I worked on it with the help of amazing maintainer <a href="https://www.linkedin.com/in/j%C3%BAlio-hoffimann-834936116/">Julio Hoffimann</a> and was able to successfully get by PR merged.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*F_ddyNiXOLr06DStgHg8_A.jpeg" /></figure><h4>Final thoughts:</h4><p>MLH fellowship was a new beginning which I never wanted to end but as they say, all good things must come to an end and so here we are. I loved working on my project, made some brilliant friends, learned a lot from them, and left with a lot of memories as a better human being and a step closer towards my goal.</p><p>There is no way we can point the shortcoming in such an amazing experience but we tried our best to keep the best and worst things of the whole experience together in our final Retrospective. Fell free to zoom in.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*akAnBhbWGGKgKPSUgPTQdg.jpeg" /></figure><p>Oh yeah! we also got awards. Credits to our Pod leader the very famous <a href="https://twitter.com/kush_kunal">Kunal Kushwaha</a> 🤩</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/434/1*BQzj1PnuGh3fgI_FdrMXnA.png" /></figure><p>If you have read all the way down till here, I hope you have enjoyed the tour, I tried my best to convey the experience as visually as possible. Thank you! Reach me out with your suggestions, as always my inbox is waiting for your feedback 😁.</p><p>As final words, This blog is not just to share my memories or experiences but to show, how well the MLH Fellowship is planned and executed perfectly to help us learn various ascepts of the current day Software Engineering, yet keeping it fun, exciting and keeping us continuously engaged with the opensource contributions.</p><p>If interested, you can also apply for MLH Fellowship at <a href="https://fellowship.mlh.io/">https://fellowship.mlh.io/</a>. We also did a live-stream sharing our experiences. You can check that out here.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FKc7ZZYzDdLw%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DKc7ZZYzDdLw&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FKc7ZZYzDdLw%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/8272f40721af0b841b5877aad2bdbd6f/href">https://medium.com/media/8272f40721af0b841b5877aad2bdbd6f/href</a></iframe><blockquote>Finally, Thanks for bearing with me 😅! Without further a do, In the name of MLH Tradition - lets clap this out 👏</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*IKxbN1ppGlO701oEvVznJA.png" /></figure><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=12f74cdebe8b" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[I selected for MLH Fellowship twice but accepted once.!]]></title>
            <link>https://nitishgadangi.medium.com/i-selected-for-mlh-fellowship-twice-but-accepted-once-7b2d41c8d3e7?source=rss-38fe773ec71d------2</link>
            <guid isPermaLink="false">https://medium.com/p/7b2d41c8d3e7</guid>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[mlhgrad]]></category>
            <category><![CDATA[mlh-fellowship]]></category>
            <category><![CDATA[mlh]]></category>
            <dc:creator><![CDATA[Nitish Gadangi]]></dc:creator>
            <pubDate>Thu, 24 Dec 2020 07:24:46 GMT</pubDate>
            <atom:updated>2021-01-14T13:34:05.207Z</atom:updated>
            <content:encoded><![CDATA[<p>As I just finished my journey as MLH Fellow, I tried to look back where it all started, and trust me it is no more than a Thriller Movie with enough plot twists. Here is the back story of how I almost got selected for the first iteration of MLH Fellowship and missed it because of Gmail.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oPnw61XDfAlLL7TfSOEvrw.jpeg" /></figure><blockquote>I’m writing about this today, because it is one of those phases of my life where I almost questioned my decisions and thought I need to change my paths. I want to look back and appreciate how I got through all of these. So sit back and watch me giving a walkthrough.</blockquote><p>May 4, 2020: The day GSoC 2020 results were out. The first time in my life I cried the whole night for a failure that I never expected. It felt like something which is almost within my hands has been taken away. Maybe, at that instance, I haven’t prepared to face a negative result. And the other thing is I already missed few opportunities because of Covid and got rejected for 3 interviews just in the final rounds. Several other weird reasons added up and kicked the optimism out of me.</p><p>May 5, 2020: The exact next day morning. Holding up my self-confidence I started scrolling through my LinkedIn feed watching all the posts about GSoC selection. Suddenly one of the maintainers (<a href="https://www.linkedin.com/in/prudhvir3ddy/">Prudhvi Reddy</a>) of the projects which I contributed before dropped a message about the opensource program from MLH. I went through the article in the <a href="https://dev.to/devteam/dev-is-participating-in-the-mlh-fellowship-powered-by-github-5afk">dev.to</a> and got to know this is something more exciting than other similar opensource programs. Without any second thought, I filled out the application form. All my hopes which buried into ashes the last night are live again. 😂</p><p>May 15, 2020: A message to schedule my first interview dropped into my Mailbox. I quickly filled in details and confirmed the slots. I got a slot on 20th and successfully finished my interview. It really went smooth and within no time I received a reply to fill in a form with details about my Github profile and asked me to submit one of my projects with a suitable tech stack mentioned. I know this form is for filtering students to technical interview, so I submitted one of the most popular projects I have worked on.</p><p>Everything is going super smooth. It was told to me that, I will be hearing back with a rejection or a call for a technical interview in the next 2–3 days.</p><p>May 23, 2020: It&#39;s already 4 days and I am really terrified, neither I got a rejection mail nor a call for the next interview. I became more scared and almost confirmed about rejection as I went through the Fellowship <a href="https://www.reddit.com/r/csMajors/comments/gdmymj/mlh_fellowship/">Reddit thread</a> where people discussing their technical interview experiences and rejections. Until I realized that there is something to do with Gmail.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/577/1*zft6T5vdYMj931KpXTnCfQ.jpeg" /></figure><p>Later that night I realized that I received the mail for Technical Interview on the next day of my previous Interview itself, <strong>but it was landed in Spam 🤦‍♂️</strong>. I cursed my self so bad for not checking the Spam folder. I have no clue what to do next as there are no slots available for scheduling interviews as it&#39;s already the last day of the application period.</p><p>I tried my last luck writing to <a href="https://www.linkedin.com/in/theycallmeswift/">Mike Swift</a> (The Founder and CEO of MLH) as it is no fault on both sides (coz, who expects a mail to attend interview lands in Spam). In no time I got a reply to schedule an Interview on the same day but as all the Interviewers are already away, Swift himself took my Interview. Yes! Mike Swift himself !!</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/984/1*769JEe1sVdUhzC7uM_IZeA.png" /><figcaption>Invitation to attend the Technical Interview</figcaption></figure><p>It was a 25min interview and it went really smooth. I was asked about a few of the code snippets from three of my projects on GitHub. Later we discussed few other things related to Fellowship and how unique it is from other opensource programs. Finally swift told me that <em>I will either be accepted or will be on the waiting list</em> as the spots are almost filled (as slots are allotted on a first come first serve basis for the students qualified in the tech interview) and MLH is looking for sponsors to make few more spots available. The final result will be sent to mail within a week.</p><p>Later that weekend, I received two emails updating me that I am still on the waiting list and I will be taken in if any of the accepted applicants opt-out from the program. Finally, after a week I realized there is no way I will be in, as the Fellowship has already begun. This was another unusual failure and I am not sad this time.</p><p>Right from the next day, I started participating in every random hackathon every weekend. It felt like I want to do something to prove myself. Within 5 weeks I participated in 4 Hackathons and won 3 of them. I also got an Internship offer in an amazing Startup (called <a href="https://www.linkedin.com/company/subconscious101/">Atom</a>) for SDE (Android) role. As it is my major tech stack I directly went in. I learned so many things and made several connections that I won&#39;t be forgetting in a lifetime. In short, it helped me to shape my development career. I also participated in many more hackathons in the meantime and won a handful of them. <em>I will be writing a separate blog about that experience soon.</em></p><p>Four months passed by and applications for MLH Fellowship (Fall 2020) were out. I applied on the first day again but this time with a fresh new email 😅. (I don&#39;t want to land in the SPAM scene again). Turned out there is a plot twist again. But this time it&#39;s not from Gmail.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/500/1*ILZF-EXmN3Du-PeZMVMYFw.jpeg" /></figure><p>As I was not getting any automated response even after 15days after my application submission, I reached Swift again and got to know that my application has not reached their database at all. It is sure that I have made something wrong on my end as I didn&#39;t receive the automated response soon after submission. So I submitted my application again and <em>It&#39;s really awesome that Swift still remembers me from the previous SPAM scene</em>. So he said he will mark my application for faster review.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/973/1*NE0IEeeJgQSrPdC_JEw8kQ.png" /></figure><p>Later everything went super smooth and within the next few days I completed all my interviews and received this mail…..! Drum roll, please 🥁🥁🎉</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/890/1*mlPK37NsVk50nlMoKdgQIA.png" /></figure><p>Frankly speaking, after all these hurdles and chaos I never expected this is coming. But it has come in and the next three months were some of the most memorable days in my life, I have made several new friends who helped me to explore a whole new world with several experiences that I surely might not be experiencing anywhere. Trust me MLH is just 💖.</p><blockquote>Don’t forget to read the next article where I described the journey in MLH Fellowship. It’s more fun and interesting than this tragic article 💯. Something which you shouldn’t be missing.</blockquote><p><a href="https://nitishgadangi.medium.com/mlh-fellowship-memories-that-i-always-love-to-bring-back-12f74cdebe8b">MLH Fellowship: Memories that I always love to bring back.</a></p><p>If you are someone who read all the way till here bearing my disastrous storytelling talent. Thank you! Reach me out with your suggestions, my inbox is waiting for your feedback 😁.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/577/1*w9e9Oe9ayKkiFQcn3WrwWw.jpeg" /><figcaption>Ok, now it&#39;s finally done..!!</figcaption></figure><p><em>Consider these lines 👇 as post-credit scenes 😂 !!</em></p><p>Few of the instances might seem very easy to get through but they are some of those instances where I understood how hard it would be to get through failures and rise back. Most importantly to stay prepared for both success and failure. I always believe<em> everything happens for a reason</em> and this is one such phase that made my belief stronger. I would have missed exploring hackathons and also I would have completely missed the opportunity of working in an amazing startup (This is something I believe every developer must begin their career with) if I would have into GSoC or MLH Fellowship on the first attempt itself.</p><p><strong>Finally, never take GMail for granted, always use a separate mail for careers and keep checking SPAM mail too…</strong></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=7b2d41c8d3e7" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[What's special in Designing Apps for Android TV?]]></title>
            <link>https://nitishgadangi.medium.com/whats-special-in-designing-apps-for-android-tv-5f88447c523a?source=rss-38fe773ec71d------2</link>
            <guid isPermaLink="false">https://medium.com/p/5f88447c523a</guid>
            <category><![CDATA[anita-borg-institute]]></category>
            <category><![CDATA[fire-tv]]></category>
            <category><![CDATA[android-tv-box]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[android-tv]]></category>
            <dc:creator><![CDATA[Nitish Gadangi]]></dc:creator>
            <pubDate>Mon, 15 Jun 2020 05:22:24 GMT</pubDate>
            <atom:updated>2020-06-15T17:33:16.705Z</atom:updated>
            <content:encoded><![CDATA[<p>TV celebrates content by making it front and center. Whether you’re looking for movies, games, or TV, it’s about finding and enjoying content with the least amount of friction.</p><p>We have an entire living room or other rooms dedicated and focused around the TV. TV is colorful, guided by ambient movement, with immediate access to content. These qualities define the experience of TV and form the foundation of Android TV’s design.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/995/1*qfKinJvKOo4a4MdFbdTFNg.png" /></figure><blockquote><strong>The current explanation is based on the Design Propopal written by me for Building </strong><a href="https://github.com/NitishGadangi/stem-diverse-android-tv">STEM DIVERSE TV</a><strong> of </strong><a href="https://github.com/anitab-org">AnitaB .org</a>. Hence most part of the below text sound like me explaining to someone, how I will be building an application based on given requirements.</blockquote><blockquote><strong>Refer to </strong>below Repo <strong>to get Raw version of all the Design Templates used in this proposal.</strong></blockquote><p><a href="https://github.com/NitishGadangi/Android-TV-Prototpe">NitishGadangi/Android-TV-Prototpe</a></p><blockquote><strong>All MockUps are Designed using </strong><a href="https://www.adobe.com/in/products/xd.html">AdobeXD</a></blockquote><h3>What Users Expect?</h3><p>As a potential user of TV Apps myself, I prefer to have these following features which I think has already been satisfied based on the App Design explained above.</p><ul><li>People often use the TV in a relaxed mindset. Casual consumption is the primary use case of Android TV.</li><li>While searching for content, every part of the experience should be simple. New content should be easy to discover.</li><li>The default action should be one click away.</li><li>Minimize the number of navigation steps required to perform actions. Build apps with the fewest screens possible between app entry and content immersion.</li><li>Avoid making users enter text whenever possible, and use voice interfaces when you require text input.</li><li>Because anyone in a trusted household might have access to it, app content should be appropriate for mixed audiences. This makes a TV an inherently shared device.</li><li>Place controls, like the search action, in locations that don’t overlap with other clickable elements.</li><li>Categories can be traversed on the vertical axis, and items within each category can be browsed on the horizontal axis.</li></ul><p>Every point of the above-mentioned user stories must be considered while building the APP UI and correspondingly REST API should be designed. And I think you will witness them while going through the proposal.</p><p>Users come for content and stay for the app. Hence it really matters how user friendly and intuitive you build the app. According to my the main focus of building a TV app revolves around these three building blocks.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/397/0*OVZzdSSgnPc2iuw0" /></figure><p>Now let’s dive into the technical discussions of the App design.</p><h3>App Design</h3><p>You can use the <em>below link to </em>view all the Mockups mentioned in the proposal at the highest resolution possible.</p><p><a href="https://drive.google.com/open?id=1n0w_uteuTSFm4Wa9-akaQZqM-hUokkJa">MOCKUPS - Google Drive</a></p><h3>Designing Principles</h3><p>As TV is quite different from Mobile there are several design principles which are quite different and they must be considered while building the app for TV. For example, we should make an app so that we can navigate the application only using ↑↓→← direction keys, instead of touchpad navigation. Because the user uses a remote controller, and cannot use the “touch screen” function with TV.</p><p><strong>Navigation: </strong>TV should provide the shortest possible path to content. Place the fewest screens possible between the viewer and content. When screens are necessary, they are consistent and simple to operate with an input device.</p><p><strong>Information density:</strong> Due to the viewing distance of the TV, users may not be able to process as much information on TV as they would on a computer or mobile device. Limit the amount of text and reading on TV screens.</p><p>Hence my App mockups follow all these principles in order to make UI as User Friendly as possible.</p><h3>Colors</h3><p>Colors on TV can look very different from colors on computers or mobile devices, and some color combinations may not work on both.</p><p>Using colors two to three levels darker than those using a mobile device is recommended. Alternatively, we can use colors from the 700–900 range of the material color palette.</p><p>I have opted to go with Darker UI as it will reduce the Eye Strain and Makes users stay for the content for a longer duration.</p><p><strong>TV WHITE:</strong> Pure white (#FFFFFF) can be very harsh on a bright TV screen. Light gray (#EEEEEE) is recommended as the default text color on dark backgrounds.</p><p>And so does the remaining colors and each color has its own significance.</p><p>Here is the Colour Pallete I had used for the whole Design.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*7Ev34pc18iN36DHV" /></figure><h3>Typography</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Jp_s3b876ybFp13l" /></figure><h3>UI States</h3><p>This explains how the user interacts with each of the UI elements and how they respond to each element.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*CeIb9lKnJn9_-iDk" /></figure><h3>App Structure</h3><p><strong>The MVP will contain the following features explained below with mocks and backend.</strong></p><p>Here is a basic overview of the flow of the app. Basically shows all the screens and interlinks between them in brief.</p><p>The Structure of the App is basically divided into three segments</p><ol><li><strong>BrowseView</strong>: where the user browses for the content.</li><li><strong>InAppSearch</strong>: where users search for the content.</li><li><strong>ConsumptionView (Player)</strong>: where user watches(consumes) the content.</li></ol><p><a href="https://drive.google.com/open?id=1UA7rYkcXcMgP-XXHQZeysVtNqxVsQDQ4">Go Here</a> to view it at a higher resolution.</p><p>*The mentioned figures are available below in the further discussion,(Use figure numbers)</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/700/0*EzKl262_0b_VQv91" /></figure><h3>Splash</h3><p>Splash screen presented as soon as the app launches. It basically enables us to load the background content in the meantime. So that the user will be presented with the homepage with at least partially loaded content.</p><p>*The Logo used is provided by Anna and however it can be changed in future if necessary.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*JgzuVJRMWOOMeyEY" /><figcaption>[Figure 1.0] SplashScreen</figcaption></figure><h3>Home</h3><p>This is the place where users land up for the content.</p><p>The homePage can be structurally divided into three parts.</p><ol><li><strong>TitleRow</strong>: up top where Titles of each page can be displayed in a row</li><li><strong>BrowseRow: </strong>Browse Row organizes content into categories. These categories are displayed in the form of horizontal lists, which are stacked vertically on top of one another. By default, only one row scrolls horizontally at a time.</li><li><strong>SideLane/BrowseLane: </strong>where major controls for Activity shifting lies.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*AyqUE9UntJHSpW_a" /><figcaption>[Figure 2.1] Home with TittleRow and BrowseRow</figcaption></figure><p>On hitting the left button the D-Pad user can navigate into the SideLane which looks like this.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*zzKRabFqAN4OvclS" /><figcaption>[Figure 2.5] BrowseLane/SideLane</figcaption></figure><h3>GridView</h3><p>The BrowseRow will be containing only few number of videos of the content, so after reaching at the end of each row there will be an option to SEE ALL from that content</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*xRzVKYW8qlBFzVTn" /><figcaption>[Figure 2.3] SEE ALL</figcaption></figure><p>Later on clicking on SEE ALL , a new page opens displaying all the content related to the corresponding topic/category. I like to call it GridView.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*zji0zQKoVyLUH2DO" /><figcaption>[Figure 2.4] GridView</figcaption></figure><h3>In-app Search</h3><p>In-app search provides a consistent search experience for all participating Android TV apps. Users may quickly search across apps that contain large amounts of information.</p><p>Invoking in-app search is simple. Press the microphone button on your controller or select the on-screen search button from the SideLane.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*DY0k8j8n7r_D8hQ_" /><figcaption>[Figure 3.1] Search</figcaption></figure><p>On making a Search, the search results will be stacked as a row in the bottom, so that users quickly select one to watch. Also, enabling auto search will help to uplift the user experience.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*u2O_e2swC34iTNqU" /><figcaption>[Figure 3.2] Search Results</figcaption></figure><p>There is also a provision to integrate Google Assistant with the search which makes it more user intuitive. However, it might not be possible for version1 of MVP.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Va9N6bObbO8bylmp" /></figure><h3>Continue Watching</h3><p>Because there are many reasons users pause content, provide multiple avenues for users to quickly pick up from where they left off. Continue watching Row will help us to achieve this.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*c14Z5NiaTF_LDcgM" /><figcaption>[Figure 2.2] Continue Watching</figcaption></figure><h3>ConsumptionView (Player)</h3><p>The Consumption View is where the user will engage with or watch content. Users will spend most of their time in this immersive experience.</p><h3>Transport Controls</h3><p>Transport Controls give users control of the content currently playing.</p><ol><li>The controls are displayed by pressing any navigational button on an Android TV controller.</li><li>The center action is focused by default, so it should be the most commonly used action. In most cases, this action is Play/Pause.</li><li>To Keep the number of available actions to a minimum, I have added quick shortcuts to go to next and previous content.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*9ZkhQBD81-06I7OT" /><figcaption>[Figure 4.0] ConsumptionView (Player)</figcaption></figure><h3>Techstack</h3><p>Here is a list of libraries and programming practices that I would like to propose and would follow while building the Android App.</p><h3>Leanback</h3><p>The leanback library provides a templated UI so developers can focus on the important parts of their app.</p><p>When using leanback, content is shown in rows. Leanback supplies a rectangular card view, ImageCardView, to easily display content. The card size scales when selected and has shadows to accent the content. This is great for content such as movie posters and album art.</p><p>API Reference:</p><p><a href="https://developer.android.com/reference/androidx/leanback/app/package-summary">androidx.leanback.app</a></p><p><a href="https://developer.android.com/reference/androidx/leanback/database/package-summary">androidx.leanback.database</a></p><p><a href="https://developer.android.com/reference/androidx/leanback/graphics/package-summary">androidx.leanback.graphics</a></p><p><a href="https://developer.android.com/reference/androidx/leanback/media/package-summary">androidx.leanback.media</a></p><p><a href="https://developer.android.com/reference/androidx/leanback/preference/package-summary">androidx.leanback.preference</a></p><p><a href="https://developer.android.com/reference/androidx/leanback/system/package-summary">androidx.leanback.system</a></p><p><a href="https://developer.android.com/reference/androidx/leanback/widget/package-summary">androidx.leanback.widget</a></p><p><a href="https://developer.android.com/reference/androidx/leanback/widget/picker/package-summary">androidx.leanback.widget.picker</a></p><p>Refer <a href="https://developer.android.com/jetpack/androidx/releases/leanback">Leanback</a>, for a complete description about the library.</p><h3>Exoplayer</h3><p>Player Constitutes the major section of the app. Because, it is where the user will engage with or watch content. Users will spend most of their time in this immersive experience. It’s better to have an inbuilt player instead of opening another app to play videos.</p><p><a href="http://google.github.io/ExoPlayer/">ExoPlayer</a> is an open source project that is not part of the Android framework and is distributed separately from the Android SDK. ExoPlayer’s standard audio and video components are built on Android’s MediaCodec API, which was released in Android 4.1 (API level 16). Because ExoPlayer is a library, you can easily take advantage of new features as they become available by updating your app.</p><p>ExoPlayer supports features like Dynamic adaptive streaming over HTTP (DASH), SmoothStreaming, and Common Encryption, which are not supported by <a href="https://developer.android.com/reference/android/media/MediaPlayer">MediaPlayer</a>. It’s designed to be easy to customize and extend.</p><p>Here is a small snippet which explains the initialization procedure for Exoplayer</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*Vh38nXRlJmp_j9bb" /></figure><h3>Supported Media formats</h3><p>In version 1 of the MVP, mostly we might be added content from the youtube directly. Basically embedding sources from youtube into the Exoplayer.</p><p>Here is how we can extract the source link from youtube and play them in exoplayer.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*GP_1Ryuc6g8hHI6X" /></figure><p>However, in ExoPlayer every piece of media is represented by MediaSource. The ExoPlayer library provides MediaSource implementations for several stream types:</p><ul><li>DashMediaSource for <a href="https://exoplayer.dev/dash.html">DASH</a>.</li><li>SsMediaSource for <a href="https://exoplayer.dev/smoothstreaming.html">SmoothStreaming</a>.</li><li>HlsMediaSource for <a href="https://exoplayer.dev/hls.html">HLS</a>.</li><li>ProgressiveMediaSource for <a href="https://exoplayer.dev/progressive.html">regular media files</a>.</li></ul><h3>Glide</h3><p>Images form the major part of the App and hence we need to make sure loading images into Imageviews goes frictionless.</p><p><a href="https://github.com/bumptech/glide">Glide</a> is a fast and efficient open-source media management and image loading framework for Android that wraps media decoding, memory and disk caching, and resource pooling into a simple and easy to use interface.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*oe_hdwqergEs1rT5" /></figure><h3>Retrofit</h3><p><a href="https://square.github.io/retrofit/">Retrofit</a> is a REST Client library (Helper Library) used in Android and Java to create an HTTP request and also to process the HTTP response from a REST API.</p><p>REST Client in our case is the Retrofit library that is used on the client side (Android) to make HTTP requests to the REST API.</p><p>Here is small snippet as proposed in the <a href="https://square.github.io/retrofit/">Retrofit documentation</a></p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*hLSJhTjG-JeInqhh" /></figure><h3>RxJava</h3><p><a href="https://github.com/ReactiveX/RxJava">RxJava</a> provides an opportunity for making parallel network calls efficiently and easily.</p><p>RxJava is a Java VM implementation of Reactive Extensions: a library for composing asynchronous and event-based programs by using observable sequences.</p><h3>Kotlin and MVVM</h3><p>Of course, Kotlin being the android-first language it’s obvious that it will be beneficial for future sustainment of the project. Basically, less code, more robustness, better safety, and a strong community.</p><p>As everyone knows about the perks of shifting towards Kotlin, I would like to stop the Kotlin discussion here and move towards dependency injection.</p><p>Coming to MVVM, MVVM combines the advantages of separation of concerns provided by MVP, while leveraging the advantages of data bindings. The result is a pattern where the model drives as many of the operations as possible, minimizing the logic in the view. MVVM being itself a suggested architecture by Google Developers, it’s quite obvious to have such advantages</p><h3>Dependency Injection</h3><p>Usage of dependency injection frameworks gives you various benefits that improve the app performance and allowing the app features to stay decoupled, helps us in testing components individually. And there are several more advantages that make up my whole proposal if I continued explaining… Hence, Keeping the advantages aside let me explain which framework I am going to opt for.</p><p>There are two major types of Dependency Injection frameworks available right now.</p><ol><li>Dagger2</li><li>Koin</li></ol><p>Out of Dagger and Koin, would prefer to go with Koin, and Koin has its own reasons and perks for opting it over Dagger. I will list them briefly below.</p><h3>Why Koin</h3><p>Since Koin isn’t a dependency injector but a service locator with a clever reified trick that you can use to manually perform dependency injection, the boilerplate will scale disproportionally.</p><p>This below stats might give a small idea.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*HbW11DkAGvWp04PA" /></figure><p>To make the situation clearer, let me give more details on the Koin framework.</p><ul><li>Koin DSL allows you to declare your components graph, through functions and constructor dependency injection.</li><li>Koin is a real DI container which manages all components instances and definitions. We don’t use any introspection or proxy mechanism. It’s all about pure function resolution.</li><li>Service Locator is only needed in Activity/Fragment classes, to inject your components (lazily or not) due to the fact we can’t inject them by a constructor.</li></ul><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*z7N_koMfZ-5rQXz7" /></figure><p>The thing is that frameworks like Koin reduce the 90% boilerplate thanks to the reified trick, making it very interesting.</p><p>That summed with the problems that annotation processing brings, increasing compile times and making it harder to do an incremental compilation in modules makes me want to re-evaluate if Dagger is worth it.</p><p>I mean having to add one line per each class that I want to add to the service locator is way better than having to re-compile all the graphs every time I do a clean build…</p><h3>Testing</h3><p>Testing is the most important step of the development life cycle as it will help us to verify the functionality of all the features of the app. Here is a list of libraries which I will be using for testing.</p><ul><li>Functional tests with <a href="http://google.github.io/android-testing-support-library/docs/espresso">Espresso</a></li><li>Unit tests with <a href="http://mockito.org/">Mockito</a></li><li><a href="http://checkstyle.sourceforge.net/">Checkstyle</a>, <a href="http://findbugs.sourceforge.net/">FindBugs</a>, and <a href="https://pmd.github.io/">PMD</a></li></ul><h3>DevOps</h3><p>In order to make it dev-ops friendly firstly I would like to use a Trunk based approach during the development of the app.</p><p>Here, We only have one main branch. Then, we would branch off master when doing any features and anything that gets merged into master should be ready to ship to users. The image given can explain it in a better way.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/0*sPO5WYLhfiooH_Nq" /></figure><h3>Fastlane (optional)</h3><p>I made this optional, as it might not be possible to implement it for the first version of MVP.</p><p><a href="https://fastlane.tools/">Fastlane</a> is a great tool that developers can use to automate their release process &amp; significantly reduce their release cycle times. The 4 major features offered by Fastlane are:</p><ul><li><a href="https://docs.fastlane.tools/getting-started/android/screenshots/">AUTOMATE SCREENSHOTS</a>: Automatically generate localized screenshots for the app store.</li><li><a href="https://docs.fastlane.tools/getting-started/android/beta-deployment/">BETA DEPLOYMENT</a>: Easily distribute beta builds to testers.</li><li><a href="https://docs.fastlane.tools/getting-started/android/release-deployment/">APP STORE DEPLOYMENT</a>: Publish a new release to the app store in seconds.</li><li><a href="https://docs.fastlane.tools/codesigning/getting-started/">CODE SIGNING</a>: Reliably and consistently code sign your app–no more headaches.</li></ul><p>Since Fastlane allows plugins, there is no restriction on the capabilities.</p><h3>What about Amazon FireTV</h3><p>Most apps that work on Android will also work on Fire TV because Fire TV is built on Android. The only difference is with services — for Fire TV, you’ll want to use Amazon services instead of Google services.</p><p><a href="https://developer.amazon.com/docs/fire-tv/differences-from-android-tv-development.html">How Fire TV Development Differs from Android TV Development</a></p><p>Hence building an Android App based on Android 5.1 / Android 7.1 will work on FireOs5 / FireOs6 seamlessly.</p><h3>What&#39;s Next?</h3><p>I hope my explanation gives you a basic idea upon the various design guidelines that one must follow while building for TV.</p><p>Ultimately this is the basic approach and you must be able to relate it to your requirements.</p><p>That&#39;s the End for now.</p><p>I will try to add more about the Backend in the upcoming days. Until then Keep Exploring.</p><p>Check out my website to know more about me and my other projects</p><p><a href="https://nitishgadangi.github.io/">Nitish Gadangi</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5f88447c523a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[We built a Drone which can Estimate yield and Disease in the Crop]]></title>
            <link>https://nitishgadangi.medium.com/we-built-a-drone-which-can-estimate-yield-and-disease-in-the-crop-991873d9f5cd?source=rss-38fe773ec71d------2</link>
            <guid isPermaLink="false">https://medium.com/p/991873d9f5cd</guid>
            <category><![CDATA[crops]]></category>
            <category><![CDATA[drones]]></category>
            <category><![CDATA[jntuh]]></category>
            <category><![CDATA[agriculture-technology]]></category>
            <category><![CDATA[agriculture]]></category>
            <dc:creator><![CDATA[Nitish Gadangi]]></dc:creator>
            <pubDate>Sat, 25 Apr 2020 18:25:56 GMT</pubDate>
            <atom:updated>2020-06-15T17:34:23.680Z</atom:updated>
            <content:encoded><![CDATA[<h3>We built a Drone which can Estimate Yield and Disease in the Crop</h3><p>We Team Agro-Vators under the guidance of our professor has done a project that can help farmers to solve their issues. This article will give you a brief idea about it.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*rbR8TqX8l-tfgAxpAEegcQ.jpeg" /></figure><blockquote>In India, about 15,963 farmers are committing suicides every year. Among them, 20% is due to crop failure (mainly due to diseased crops) and about 35% is due to price crash and share bankruptcy (i.e., inaccurate Minimum Support Price (MSP) given by the government). As a consequence, it is leading to decrease in agriculture productivity, food scarcity, and an increase in consumer rates. <strong>Our project forms a solution to these issues.</strong></blockquote><p>TL;DR 😅, if you think that you can’t read a huge article ahead just watch this video 😉.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FKBaRUaZX-8o%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DKBaRUaZX-8o&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FKBaRUaZX-8o%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/e6d9e6e838f1e73d5011cbd9492e02f8/href">https://medium.com/media/e6d9e6e838f1e73d5011cbd9492e02f8/href</a></iframe><h4>What is the actual issue?</h4><p>In India, Mostly the yield of the crop is reduced due to diseases. If they have detected in the early stages itself, we can take necessary measures to get more yield. However, it is not an efficient process to diagnose each plant individually by the farmer and even by the remote sensing data (which is captured from satellite, because of its less resolution).</p><p>By taking previous year statistics and present year’s rainfall, amount of agricultural land, demand into account, the government decides MSP to the farmer. This MSP value depends on the supply. Both of them are inversely related. But, when the farmer gets less yield than expected from the land, he has to sell the yield at a higher price than MSP to avoid loss, But, As MSP is fixed by the government; either government or farmer has to suffer the loss.</p><p>Hence, we need to find a way to get stats of the current yield and also make sure we are able to diagnose the crop during the early stages of the disease. This project aims at achieving these goals.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-8pHdQQ1YTTS5MkWSwTNsg.jpeg" /><figcaption>Our Drone during its Test flight</figcaption></figure><h4>How did we solve?</h4><p>An area can be efficiently analyzed if it is done from the Ariel Perspective. Hence we decided to use a Drone for this project.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*HTCaczuLPdwVTZrLpflR5A.png" /><figcaption>The drone which is used for this project</figcaption></figure><p><strong>Step-1:</strong> The Drone used for this project has several advanced features such as Geo-Fencing, Path Tracing, Autonomous Flying, etc. The surveillance area of the field is initially fed to the drone. The drone captures all the required data by moving over the field in a particular predefined path.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*cVuImWOwzs9smQfn8fUmfw.jpeg" /><figcaption>Setting up the flight plan in the Mission Planner software that interacts with the drone.</figcaption></figure><p><strong>Step-2:</strong> It is equipped with NIR and RGB cameras to capture high-resolution image data in Near IR and Visible Spectrums simultaneously. At the same time the gathered info from the drone is transmitted to the base station instantly (using Node MCU). At the base station, the received data is analyzed.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/835/1*7D1ytstBSLSdBUAeJnoOBA.jpeg" /><figcaption>Images captured during a Test Flight</figcaption></figure><p><strong>Step-3: </strong>We use NDVI (Normal Difference Vegetative Index) as the main parameter to measure the crop’s health status. Further feeding of these NDVI data to a Regression pattern generated by AI and ML algorithms(generated based on several test cases) gives precise information about the disease of the crop (cotton crop). Inturn it also helps us in the estimation of yield from the crop.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*lh3eEa9_tRRGFZanbNPENw.png" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_N-JT7EQc-pJ0tJ_UcPBCw.png" /><figcaption>NDVI value for a crop ranges from -1 to +1</figcaption></figure><p>Now that we have gathered the required data. It helps the government in giving a better MSP (MINIMUM SUPPORT PRICE). Also, as we are having the health status of the crop we can help the farmer to determine the diseased zones in the cropland and thus helps in reducing the crop loss.</p><p>By 2025 it is estimated that India’s population increases by 10% (which demands an increase in Agricultural Productivity), It will be compulsory to gather more accurate crop data in a lesser period. Hence it is important to develop such mechanisms that can deliver more precise data in a smaller duration without the intervention of any human contact.</p><h4>Testimonials</h4><p>We also shared this idea with a few of the farmers of a village nearer to our college and they are quite excited to hear about this. Here is feedback from few of those farmers.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*SkaZwNoOi-02nx_RB9hP2A.jpeg" /></figure><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*oxGRmAEO3RVuIVkVq88elQ.jpeg" /></figure><blockquote>We have submitted this project for <strong>AICTE-Vishwakarma Awards-2019</strong> under the theme ‘<strong>How to enhance the income of Villages through the intervention of Technology/Management practice(s)</strong>.’ and got selected in the first phase. Thanks to our mentor who guided and helped us in every stage of our project.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-mNSp-FyQJJ4zm5UKtsNnA.png" /></figure><p>Also, Check out my website to know more about me and my other projects</p><p><a href="https://nitishgadangi.github.io/">Nitish Gadangi</a></p><p>Enjoyed reading this article? 😁. Also, try reading my other articles.</p><ul><li><a href="https://medium.com/@nitishgadangi/why-its-not-that-easy-to-build-a-drone-b59d265abcb0">Why it&#39;s not that easy to build a Drone?</a></li><li><a href="https://medium.com/@nitishgadangi/how-i-hacked-my-college-results-eb8473978991">How I hacked my college results?</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=991873d9f5cd" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why it's not that easy to build a Drone?]]></title>
            <link>https://nitishgadangi.medium.com/why-its-not-that-easy-to-build-a-drone-b59d265abcb0?source=rss-38fe773ec71d------2</link>
            <guid isPermaLink="false">https://medium.com/p/b59d265abcb0</guid>
            <category><![CDATA[drones]]></category>
            <category><![CDATA[jntuh]]></category>
            <category><![CDATA[quadcopter]]></category>
            <category><![CDATA[uav]]></category>
            <category><![CDATA[hyderabad]]></category>
            <dc:creator><![CDATA[Nitish Gadangi]]></dc:creator>
            <pubDate>Tue, 14 Apr 2020 11:09:56 GMT</pubDate>
            <atom:updated>2020-06-15T17:36:09.009Z</atom:updated>
            <content:encoded><![CDATA[<h3>Why it’s not that easy to build a Drone?</h3><p>Even though you have followed every bit of the manual/documentation and assembled everything perfectly, there is a fair chance that your drone will not fly 🤷‍♂️.</p><blockquote>This article gives a glance over the hurdles and obstacles that I faced during my initial days of building a full-size multi-rotor drone 🚁.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*-8pHdQQ1YTTS5MkWSwTNsg.jpeg" /></figure><p>It’s my Second Year of B.Tech when we finally managed to get hands-on to the ideation hub of our department. There we came across a half-built Drone which is made by our seniors 5years ago. So I and my friend Rahul decided to make that drone flying so that we can compete in the Expo for the Annual Tech fest.</p><p>So we went on googling all the stuff regarding these drones and there was no exact clue on how to test its functionality. We tried all the methods possible, and there is no hope that this will someday fly. Until when came across <a href="https://ardupilot.org/planner/">Ardupilot Misson Planner Software</a> which mentioned that it can wirelessly control the drone. So we connected the ground module to the laptop and turned it on. Then this happened…🙌</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FWOwk49mCryg%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DWOwk49mCryg&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FWOwk49mCryg%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/1b07b38959213ee98a72be9b4e591b46/href">https://medium.com/media/1b07b38959213ee98a72be9b4e591b46/href</a></iframe><p>Even though it is completely a miss fire, we are glad that we got to confirm that it’s working😌. At that instance, we are so naive that we don’t even know how to remove propellers from the flight. We don’t even know how to disassemble.</p><p>The problem is there are very fewer people who are familiar with handling this equipment and there are not enough resources available online. Then with the help of an online forum and one of our seniors we got to disassemble everything and realized a few parts of it are missing. No sooner we headed towards <a href="https://www.thehindu.com/life-and-style/gujarati-galli-is-the-hub-of-all-electronic-items-spare-parts-and-repairing-centres/article19845067.ece">Gujrathi Gulli</a>, which is like a home for electronic parts in Hyderabad. From Led to microprocessor everything can be found here. Even though a bit costly, we somehow managed to find all the required parts.</p><p>At that instance, our goal is to make a 360° Enabled VR Drone. So we started assembling all the parts using the instructions from random youtube videos. Every part is well inserted into its place and all are calibrated perfectly. But in the end, the Drone didn’t even start 😢. No clue and no idea about what might be the issue. We tried posting in all the forums and there is no one who faced the same issue. A week passed 😫, Leave that idea of attaching 360° Camera aside, we are not even able to make the drone fly.</p><p>Then we realized it already late and we decided to change the flight controller. We decided to use the <a href="https://www.dronetrest.com/t/kk2-1-flight-controller-guide/379">KK2.1</a> controller which is a simple one (kinda noob version) with very fewer features instead of a current high-end controller(<a href="https://ardupilot.org/copter/docs/common-apm25-and-26-overview.html">APM 2.8</a>). Again headed to Gujarathi Gulli to grab one.</p><blockquote>A <strong>flight controller</strong> (FC) is a small circuit board of varying complexity. Its function is to direct the RPM of each motor in response to input. It’s basically the brain of the flight which receives the commands from remote and controls flight accordingly.</blockquote><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*BcA6jozFCJLeU5N4dSfApA.jpeg" /></figure><p>Then we removed already having <a href="https://ardupilot.org/copter/docs/common-apm25-and-26-overview.html">APM2.8</a> flight controller and installed this KK2.1.5 flight controller and assembled everything. Luckily this time everything seemed working. But this flight controller is so naive that there is no auto feedback and balancing system. Which means our drone cannot fly to the air resistance. <em>Thus controlling it is like making a bird with half-broken wings fly</em>. 😅</p><p>As there is no time remaining we managed ourselves to get accustomed to the controls and tweaked the controller in such a way that it can fly steadily to some extent. Later we used sponges as landing gears to reduce the impact (desi hack 💡). And finally made it fly to smaller distances.</p><iframe src="https://cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fwww.youtube.com%2Fembed%2FTEACSMinvdQ%3Ffeature%3Doembed&amp;display_name=YouTube&amp;url=https%3A%2F%2Fwww.youtube.com%2Fwatch%3Fv%3DTEACSMinvdQ&amp;image=https%3A%2F%2Fi.ytimg.com%2Fvi%2FTEACSMinvdQ%2Fhqdefault.jpg&amp;key=a19fcc184b9711e1b4764040d3dc5c07&amp;type=text%2Fhtml&amp;schema=youtube" width="854" height="480" frameborder="0" scrolling="no"><a href="https://medium.com/media/561465b384cdcf7ffed18fcc7d91ca98/href">https://medium.com/media/561465b384cdcf7ffed18fcc7d91ca98/href</a></iframe><p>In this way, 🤦‍♂️ <em>our idea of building a VR enabled Drone ended up building a low standard naive quadcopter</em> that can fly only up to a certain extent. and we anyhow managed to exhibit to our professors during the Fest.</p><p>But this is not what we thought of, So we didn’t stop over there. I know that there is some mistake on our side but not in the equipment. The later days I constantly went through the documentation and researched a lot about how the internals of flight controllers. I analyzed every part about how they work and how they are interconnected with each other.</p><p>Within two months we realized that the fault was due to the Youtube Videos which we followed blindly.</p><blockquote>Later, under the mentorship of one of our professors, we managed to build <strong>an Advanced Drone that can estimate yield and detect diseases in the crop Autonomously</strong> and got selected for <strong>AICTE-Vishwakarma Awards-2019 [phase1] </strong>🥳<strong>.</strong></blockquote><p>Check out my website to know more about me and my other projects</p><p><a href="https://nitishgadangi.github.io/">Nitish Gadangi</a></p><p>Enjoyed reading this article ? 😁. Also, try reading my other articles.</p><ul><li><a href="https://medium.com/@nitishgadangi/we-built-a-drone-which-can-estimate-yield-and-disease-in-the-crop-991873d9f5cd">We built a Drone which can Estimate yield and Disease in the Crop</a></li><li><a href="https://medium.com/@nitishgadangi/how-i-hacked-my-college-results-eb8473978991">How I hacked my college results?</a></li></ul><p>Happy Quarantine. Stay Home. Stay Safe.✌</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=b59d265abcb0" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[How I hacked my college results?]]></title>
            <link>https://nitishgadangi.medium.com/how-i-hacked-my-college-results-eb8473978991?source=rss-38fe773ec71d------2</link>
            <guid isPermaLink="false">https://medium.com/p/eb8473978991</guid>
            <category><![CDATA[hashing]]></category>
            <category><![CDATA[reverse-engineering]]></category>
            <category><![CDATA[exam-result]]></category>
            <category><![CDATA[jntuh]]></category>
            <category><![CDATA[hyderabad]]></category>
            <dc:creator><![CDATA[Nitish Gadangi]]></dc:creator>
            <pubDate>Fri, 03 Apr 2020 09:55:46 GMT</pubDate>
            <atom:updated>2020-06-15T17:42:18.311Z</atom:updated>
            <content:encoded><![CDATA[<h3>How I found an interesting loophole in my college results website?</h3><p>This article explains how and why I was able to hack my college results database and was able to view them before they even get published.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*6LZ4KG52GtrZIvG89wFQHQ.png" /><figcaption><strong>Btw, this👆 is not the way it goes 😅</strong></figcaption></figure><blockquote>In my college, the results are made available to the students who have cleared all their hostel dues in time. So, if you are a hosteller and you haven’t cleared your dues then you won’t be able to get to know you results in time. You need to wait until the memos come out. This led me to start moving my thoughts towards finding a loop hole in my colleges results website.</blockquote><p>This was my 1st year second semester days, first semester results were out and many hostelers were unable to get their results from the website,(because of the obvious ‘‘Mess Due’’ reason). So my friend Rahul is one such victim. So I am as excited as him to know his result😅. So I was scrolling through the backend code of the website to make some XSS attacks. But it&#39;s just useless.</p><p>The later day, our examination branch started distributing the Memos to the students who have cleared their pending dues. I got hands-on my Memo, As it was my first memo of the college, I was quite excited and started keenly observing the memo appearance(🤷‍♂️ standard geeky way).</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/693/1*jLRcZ459lhiRijOgc-369A.jpeg" /><figcaption>This is how the Memo Looks Like</figcaption></figure><p>So, I came across these two things which I am really curious about. In the next minute, I started scanning the barcode and QR. The QR given here is to verify the originality of the memo, which basically gives a web-link to the website that gives all details about the memo including your score. This is where I got my confidence back 😉.</p><p>So this is how the scanned result of QR looks like</p><pre><strong>https://results.jntuhceh.ac.in/verify/memo/44f7cd44c8e07ff6d93846fd5fac17411084fc695eecaeb8f0dc3a63c9662f85</strong></pre><p>Within my first glance, I found that the thing at the end of the link is some kind of hash.🤔</p><pre><strong>44f7cd44c8e07ff6d93846fd5fac17411084fc695eecaeb8f0dc3a63c9662f85</strong></pre><p>Later after Googling about types of hashes available, I found that this hash is basically <a href="https://www.movable-type.co.uk/scripts/sha256.html"><strong>SHA 256</strong></a><strong>.</strong></p><blockquote>A <a href="https://en.wikipedia.org/wiki/Cryptographic_hash_function"><em>hash function</em></a> is a function that takes an input and produces a value of fixed size. In layman terms, it basically converts the given data into a different format by making it random (into a specified number of characters). Which basically is irreversible.</blockquote><p>But there are few websites that can reverse these hashes based on the leaked databases online. Luckily, after further Googling, I found <a href="https://md5hashing.net/hash/sha256">this</a> website that was able to reverse that SHA 256 hash.</p><p>After reversing I got this as a result</p><pre><strong>111251</strong></pre><p>This is quite similar to what I got by scanning the Barcode given on the memo beside QR code.</p><p>Later I have added 2 to that memo number and generated the corresponding hash for <strong>111253. </strong>And it looks like this,</p><pre><strong>04af7999888ebae7cc5bb6da8d87030204266b1b45a7994301afe5bdfb6a03e5</strong></pre><p>Next, I replaced the old hash in the link with the new hash</p><pre><strong>https://results.jntuhceh.ac.in/verify/memo/04af7999888ebae7cc5bb6da8d87030204266b1b45a7994301afe5bdfb6a03e5</strong></pre><p>And Boom 🎉 this link gave the result of my friend whose roll number is 2 steps away from my roll number.</p><p>This allowed me to crack the whole backend structure of the database 😜 and thus was able to get the result of everyone irrespective of the dues.🕺</p><p>This talk spread over the college like wildfire and rest is history ✌.</p><p>Thanks to Quarantine, this is my first article on Medium 😁.</p><p>Check out my website to know more about me and my other projects</p><p><a href="https://nitishgadangi.github.io/">Nitish Gadangi</a></p><p>Hope you have enjoyed reading this article 😃 . If yes, try reading my other articles.</p><ul><li><a href="https://medium.com/@nitishgadangi/why-its-not-that-easy-to-build-a-drone-b59d265abcb0">Why it&#39;s not that easy to build a Drone?</a></li><li><a href="https://medium.com/@nitishgadangi/we-built-a-drone-which-can-estimate-yield-and-disease-in-the-crop-991873d9f5cd">We built a Drone which can Estimate yield and Disease in the Crop</a></li></ul><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=eb8473978991" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>