<?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 Akubue Kenechukwu on Medium]]></title>
        <description><![CDATA[Stories by Akubue Kenechukwu on Medium]]></description>
        <link>https://medium.com/@akubuekenechukwu?source=rss-1b16ceeb8c16------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/1*lTP6XkpmtXAcSy0PuS-08w.jpeg</url>
            <title>Stories by Akubue Kenechukwu on Medium</title>
            <link>https://medium.com/@akubuekenechukwu?source=rss-1b16ceeb8c16------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Wed, 02 Dec 2026 18:14:12 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@akubuekenechukwu/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[Java Signatures: A nightmare of Pyjnius newbies]]></title>
            <link>https://medium.com/@akubuekenechukwu/java-signatures-a-nightmare-of-pyjnius-newbies-2d9e3dd45ead?source=rss-1b16ceeb8c16------2</link>
            <guid isPermaLink="false">https://medium.com/p/2d9e3dd45ead</guid>
            <category><![CDATA[android]]></category>
            <category><![CDATA[python]]></category>
            <category><![CDATA[pyjnius]]></category>
            <category><![CDATA[kivy]]></category>
            <category><![CDATA[java]]></category>
            <dc:creator><![CDATA[Akubue Kenechukwu]]></dc:creator>
            <pubDate>Wed, 22 Jan 2025 18:03:02 GMT</pubDate>
            <atom:updated>2025-01-22T19:44:40.466Z</atom:updated>
            <content:encoded><![CDATA[<p>Before you get along with me on this article, please do well to glance through my previous article:</p><p><a href="https://medium.com/@akubuekenechukwu/pyjnius-for-dummies-087474436be0">Pyjnius for Dummies</a></p><p>I must warn you, this article is rated MG (Mental Guidance). Only the bravest of heart will get through this article and understand the miracles of Pyjnius and how to harness it’s full powers. In this article, I will try to communicate with your brain cells and make direct connection with your neurons so as to infuse the knowledge of Java signatures into your synapses.</p><p>Let’s start with understanding what a signature in a common sense is. Signatures are a unique identities of an individual to authorise a document, transaction or even cheque. In computer science, signatures are form of a digital stamp to verify the authenticity of a data. An example of this could be your private and public key in crypto currencies, ssl certificates, ssh handshakes etc… In Java, signatures are the “blueprint” for Java methods, enabling the JVM to efficiently and correctly manage method calls and ensure program correctness. These signatures are unique across all methods in the world of java. An example would help you understand what’s going on. Let’s take a look at the below hello world java code.</p><pre>public class HelloWorld {<br><br>    public static void main(String[] args) {<br>        System.out.println(&quot;Hello, world!&quot;);<br>    }<br><br>}</pre><p>The above code is similar to the below python code:</p><pre>class HelloWorld:<br>    def main(*args: str):<br>        print(&quot;Hello, World&quot;)<br><br># But you can simply just do:<br>print(&quot;Hello, world&quot;)<br><br># same difference</pre><p>I don’t really need to explain both the java code and python code to you, do I? You can cry me a bucket of tears if you don’t understand it, there’s scarcity of water in the sahel states. Let’s get going to see how the signature looks like for the hello world java class:</p><pre>public static void main(String[] args);<br>  Signature: ([Ljava/lang/String;)V</pre><p>I will break the signature part Signature: ([Ljava/lang/String;)V down for you. The signature says, I’m accepting an array of String [Ljava/lang/String and returning nothing or void V the brackets () around the string Signature ([Ljava/lang/String;) shows that the main method is accepting a list of string argument. The one stupid thing your brain is concerned about is the [, L and ; , I would suggest you to calm down and follow me. So what if I choose to stop this article 🙄. Don’t mind me joor. I will explain as we go but, they are not that relevant but needed.</p><p>Break down of Java signatures. We will look at the very basics of java signatures and try to understand really what this magic symbols are. It can look quite scary at first but, relax for a bit and let me walk you through the lyrics.</p><pre>L&lt;java class&gt;; = represent a Java object of the type &lt;java class&gt;<br><br>Z = represent a java/lang/Boolean;<br><br>B = represent a java/lang/Byte;<br><br>C = represent a java/lang/Character;<br><br>S = represent a java/lang/Short;<br><br>I = represent a java/lang/Integer;<br><br>J = represent a java/lang/Long;<br><br>F = represent a java/lang/Float;<br><br>D = represent a java/lang/Double;<br><br>V = represent void, available only for the return type</pre><p>The above alphabetical letters by the left are the signatures and the sentence on the right are descriptions of what’s going on. Pretend you don’t see java/lang/ and pick only what’s after it. What do you see? Data types, isn’t it? Now those alphabets represent the data types on the right. You might notice something awkward about the stupid L&lt;java class&gt;; bla bla. Just like in Python, you can create you own kind of data type. The L is used to represent other non primitive data types. For example, In Java, String is not a primitive data type so to represent the signature, you have to do this Ljava/lang/String same thing for other data types that are non primitive. Let’s look an example. Say I have a java method that looks like this:</p><pre>public static void run(String a, Boolean b);</pre><p>its signature will be:</p><pre>Signature: (Ljava/lang/String;Z;)V</pre><p>If I explain that for you, then the dowry used in marrying your mother was really wasted (That’s a parable in my language; Igbo). Another example:</p><pre>public static Boolean fuckOff(int[] stupid);</pre><p>its signature will be:</p><pre>Signature: ([I;)Z</pre><p>Remember [ means that its an array of I. If you don’t know what data type it is, you can hug the nearest transformer. Am I making sense? You can read more about this Signatures <a href="https://pyjnius.readthedocs.io/en/latest/api.html#java-signature-format">here</a>.</p><p>It’s quite stressful trying to understand what this signatures are and how to harness their powers. Your question might be, “Bloody heck, I’m supposed to be reading java codes now? I don’t want JAVAAAAAA!!!”. Spare me your bloody tears please, cry the sahel states a river, there’s scarcity of water over there. Well, good thing is that I’m too kind to mess with your little brain (laughs hahahahaha). There’s another way to get the signatures without reading any damned java source code (But you won’t escape reading java code either, I will just make your work a little be easier).</p><p>In my next article, we will see how we can use the power of command line and to extract some signatures. You might want to read through this <a href="https://pyjnius.readthedocs.io/en/latest/api.html#reflection-classes:~:text=%24%20javap%20%2Ds%20java.util.Iterator">https://pyjnius.readthedocs.io/en/latest/api.html#reflection-classes:~:text=%24%20javap%20%2Ds%20java.util.Iterator</a> while I prepare for my next article.</p><p>Bonsoir 🙄</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=2d9e3dd45ead" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Pyjnius for Dummies]]></title>
            <link>https://medium.com/@akubuekenechukwu/pyjnius-for-dummies-087474436be0?source=rss-1b16ceeb8c16------2</link>
            <guid isPermaLink="false">https://medium.com/p/087474436be0</guid>
            <category><![CDATA[python]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[pyjnius]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[kivy]]></category>
            <dc:creator><![CDATA[Akubue Kenechukwu]]></dc:creator>
            <pubDate>Fri, 17 Jan 2025 12:20:34 GMT</pubDate>
            <atom:updated>2025-01-17T12:40:43.991Z</atom:updated>
            <content:encoded><![CDATA[<p>Hey, you’re back!! I see you are hungry to really know more about Pyjnius. But hold up, if you haven’t read my previous article on pyjnius you need to read the shit out of it. Here is the link:</p><p><a href="https://medium.com/@akubuekenechukwu/why-is-pyjnius-hard-8bc7166ecf7a">Why is Pyjnius Hard?</a></p><p>WHERE ARE MY ONIONS? I need to keep my eyes hydrated!! Alright, shall we continue?</p><p>After reading the previous article, you may get excited real quick that the rebels has solved the problem of not using a third party Programming Language like Java/Kotlin. Well, you really have to think again. SimpleJnius, KvDroid and Android-For-Python is not even close enough to solving the problem of not worrying about third party languages. Though they have extensive features that really touches core API of the Android operating system, but android will always come out with new features, android third party libraries will always come out with new update or completely rewrite their entire codebase and it’s always a pain in the neck to keep up with the Jones. One thing the Kivy Community lacks in general is financial support and the developers of sister projects to kivy (kvdroid, Android-For-Python, SimpleJnius, there are others though) also lacks financial support and won’t spend their whole time working on these projects and attend to every issues raised by other developers or even work on a new feature. So keeping up with the Jones will always be tough. I know what you’re thinking… “But React native and Flutter has more extensive native support for the android operating system”, you may say to yourself. You’re not far from the truth but React native has a lot of financial backing same as Flutter. And both Languages also access android native features through a bridge to Java/Kotlin also same thing Kivy does with Pyjnius. “THE SYSTEM IS RIGGED DOGGG”. So that’s why we as a community have to support each other, we have to watch each other six!! All hands on deck!! (Say it like a motivational speaker). We all have to learn to keep the train going, but if you’re reading this and you have lots of money and you would like to support the kivy team heavily you can motor over to <a href="https://opencollective.com/kivy">https://opencollective.com/kivy</a> and bless the team.</p><p>Let’s snap back to reality!!!! (suspense music plays). The reality is that you need to learn Pyjnius, it’s quite simple to use but scary at first sight. I will break it down the very much I can, but always feel free to drop your comment with your concerns and confusions.</p><p>Pyjnius is a tool to bridge Java and Python. Understand it this way:</p><blockquote>Python: Hey Java, you piss of shit, I need your printing function</blockquote><blockquote>Java: Fuck off ass hole, I don’t have anything for you</blockquote><blockquote>Pyjnius: Don’t worry Python, I can bridge into Java for you and force him to give you that printing function.</blockquote><blockquote>Java: Pyjnius you don’t even dare me. Oh!! Ouch!! get that concrete wall off my f**king toes. (screams) BLOODY F**KER</blockquote><blockquote>Python: (replies to java) Whose the ass hole now?</blockquote><blockquote>Pyjnius: Java stop yelling like a bitch, the bridge goes sideways. You can also use python for yourself too.</blockquote><blockquote>Python: PYJNIUS!!!!!! You know how much I hate that motherf**ker. Please keep that verbose piss of shit away from me.</blockquote><blockquote>Pyjnius: (replies to Python) Shut the fuck up and use each other<br>Java: (screams in laughter and keeps quite instantly)</blockquote><p>(All three throws a huge laughter)</p><p>Here’s a code that translates the fight scene:</p><pre># let&#39;s install pyjnius<br><br>$ pip install pyjnius<br><br># now let&#39;s begin the fight <br><br>from jnius import autoclass<br><br>System = autoclass(&quot;java.lang.System&quot;)<br>System.out.println(&quot;What&#39;s up motherf**kers&quot;)</pre><p>Let’s break the above code down and understand what’s going on. I don’t need to explain what pip does, you can kiss diddy’s ass if you don’t know what that is.</p><p>from jnius import autoclass : Here, autoclass is pyjnius function that takes a java class together with it’s package reference in string format and then does some magic behind the scene to find the class and also check if java virtual machine is existing on the current Operating System before accessing that class. Don’t worry your confusion will be clarified next…</p><p>System=autoclass(&quot;java.lang.System&quot;) : “java.lang” is the package name. Understand it this way: “java” is a folder that contains a subfolder “lang”, just like we have packages too in Python. “System” is a class file which looks like this “System.java” in raw format and “System.class” in compiled format. This class file contains a java code that looks like this:</p><pre>package java.lang;<br><br>import androidx.annotation.RecentlyNonNull;<br>import androidx.annotation.RecentlyNullable;<br>import java.io.Console;<br>import java.io.IOException;<br>import java.io.InputStream;<br>import java.io.PrintStream;<br>import java.nio.channels.Channel;<br>import java.util.Map;<br>import java.util.Properties;<br><br>public final class System {<br>  System() {<br>    throw new RuntimeException(&quot;Stub!&quot;);<br>  }<br>  <br>  public static void setIn(@RecentlyNullable InputStream in) {<br>    throw new RuntimeException(&quot;Stub!&quot;);<br>  }<br>  <br>  public static void setOut(@RecentlyNullable PrintStream out) {<br>    throw new RuntimeException(&quot;Stub!&quot;);<br>  }<br><br>public static final PrintStream err = null;<br>  <br>public static final InputStream in = null;<br>  <br>public static final PrintStream out = null;</pre><p>You can view the source code by installing the sources on ubuntu sudo apt-get install openjdk-8-source I don’t know about other platforms (you can google them) and then unzip this file /usr/lib/jvm/java-8-openjdk-amd64/src.zip . Navigate to java.base/java/lang/System.java . I know I know, we are not here to learn java, but just keep this knowledge handy, you will need it later.</p><p>System.out.println(&quot;What&#39;s up motherf**kers&quot;) : Now we have access to the System java class we can now access all the methods and variables associated with the class. And that’s how you call a java class/method in python. Side note: When you run the above code on android, it will work but nothing will display on the logcat if you opened a logcat using this command adb logcat -s python . The reason is because kivy team made that to display only python logs and not logs from java, even though you called java from python. If you want to see the System.out.println output, you will have to run adb using this flag adb logcat -s System.out (I don’t remember whether it’s -s flag or another flag). But on desktop, it prints the java logs perfectly fine.</p><p>I bet, most of you knows how autoclass works already. And some of you always use chatgpt to do some pyjnius magic and you end up debugging your code for months (Stay the f**k away from chatgpt for now).</p><p>Hey, since pyjnius can access java class, there’s a java library that I would like to use in my code can i just autoclass it? See, that’s the mistake most newbies make. A newbie once sent me a message that looks like this:</p><blockquote>Hey bro, I ran this code and it doesn’t work. Here’s the code:</blockquote><pre>from jnius import autoclass<br><br>VERSION = autoclass(&quot;android.os.VERSION&quot;)<br>print(VERSION.SDK_INT)</pre><blockquote>And it throws this error</blockquote><pre>Traceback (most recent call last):<br>  File &quot;&lt;stdin&gt;&quot;, line 1, in &lt;module&gt;<br>  File &quot;/home/kengo/.local/lib/python3.12/site-packages/jnius/reflect.py&quot;, line 209, in autoclass<br>    c = find_javaclass(clsname)<br>        ^^^^^^^^^^^^^^^^^^^^^^^<br>  File &quot;jnius/jnius_export_func.pxi&quot;, line 22, in jnius.find_javaclass<br>  File &quot;jnius/jnius_utils.pxi&quot;, line 79, in jnius.check_exception<br>jnius.JavaException: JVM exception occurred: android/os/Version java.lang.NoClassDefFoundError</pre><p>My conversation with him was:</p><blockquote>Me: Where did you run your code?<br>Him: On my Pycharm<br> — — — — — — <br>Me: I guess on a laptop or desktop?<br>Him: Yeah, but what does that have to do with any of this<br> — — — — — — <br>Me: You’re running an android code on a desktop. It’s like installing Pycharm 64bit on an android mobile device<br>Him: So what do I do?<br> — — — — — — <br>Me: Compile your app down to android apk and open the app to test your code, remember to use logcat to view the output of the print log.<br>Him: Yeah, it works, you’re a jnius<br> — — — — — — <br>Me: Yeah, I know, I use it on my code too😹</blockquote><p>After reading the above conversation, you will say to yourself but compiling all the time to test your code is kinda stressful, that’s why I built a tool called <a href="https://github.com/kengoon/PyJniusTester">Pyjnius Playground</a> to test any Pyjnius code that relates to android. You can download the apk <a href="https://github.com/kengoon/PyJniusTester/releases/tag/v0.2">here</a> or compile yours.</p><p>Break time, see you on my next article.</p><p>Bye 👋</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=087474436be0" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why is Pyjnius Hard?]]></title>
            <link>https://medium.com/@akubuekenechukwu/why-is-pyjnius-hard-8bc7166ecf7a?source=rss-1b16ceeb8c16------2</link>
            <guid isPermaLink="false">https://medium.com/p/8bc7166ecf7a</guid>
            <category><![CDATA[ios]]></category>
            <category><![CDATA[kivy-tutorial]]></category>
            <category><![CDATA[kivy-python]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[kivy]]></category>
            <dc:creator><![CDATA[Akubue Kenechukwu]]></dc:creator>
            <pubDate>Thu, 16 Jan 2025 23:06:45 GMT</pubDate>
            <atom:updated>2025-01-17T12:43:07.701Z</atom:updated>
            <content:encoded><![CDATA[<p>When I started my journey using the kivy framework, I noticed that I can’t access native features of the android operating system. I used the same knowledge of building apps on desktop to build apps for mobile. It was really entirely 2 different world. For example when I ran this code on desktop:</p><pre>with open(&quot;~/Dowloads&quot;, &quot;w&quot;) as file:<br>    file.write(&quot;don&#39;t f**k with me&quot;)</pre><p>… it worked, but on android version 10 higher, it just slaps the shit out of my face with stupid Permission Denied error. But I gave storage access!! WHO CAN TELL ME WHAT THE F**k IS GOING ON HERE!!! This must be a joke right? Well the truth is that there’re only 2 ways to access Android API and direct access to hardware: either you use the native Java or Kotlin code to access it or you gather the strength of your ancestors to use C or C++ or any compiled language (I guess) and then use android NDK to compile it (correct me on this C or C++ thing if I’m wrong, I just have small knowledge on that, I don’t know how OpenCV did the magic though).</p><p>The Kivy team saw this problem coming, and built a tool to bridge “Python and Java/Kotlin (<a href="https://github.com/kivy/pyjnius">PyJnius</a>) (android/desktop)”, and to bridge “Python and Objective C (<a href="https://github.com/kivy/pyobjus">PyObjus</a>) (ios/mac)”. Hey, snap back to Pyjnius!!! But there’s an issue (suspense background music plays…. dan dan ddddan). See, developers coming into Kivy are really excited that they have hit a big jackpot and can kill 1 billion birds with one Kivy Stone. Until they get to the part where they will have to access some native features, they will not know that you can’t use Python alone to build Kivy apps. The Kivy team also saw this problem and deemed it fit to keep the framework at a certain level that you will rarely have to write any other Language apart from Python, so they architected a new tool to solve this problem, <a href="https://github.com/kivy/plyer">Plyer!!!</a> (read it with a deep voice so that you will get that movie vibe feeling). Plyer has many features: from accessing storage to reading gps and many more. All these features are cross platform, which means you write one code for all platform. Exciting right? Not so exciting because Plyer came with some limitations: you don’t have control over how you read gps, or make call, or use the wifi, etc… Also not all features are implemented on Plyer, for example reading contacts on android, opening custom tab webview on android or ios, accessing storage media and writing file, etc… Though, as much as the Kivy Team tries their best to keep kivy to a very high Pythonic standard, there might always be a drawback somehow.</p><p>In the Kivy Community exist The Rebels (say that slowly and mean it). Not rebel rebel, but developers that don’t go by the rules and does not allow Kivy limitations stop them from dancing with the Python goddess. I kinda fall in the <em>rebel thingy. </em>Tools like <a href="https://github.com/Android-for-Python/">Android-For-Python</a>, <a href="https://github.com/kvdroid/Kvdroid">KvDroid</a> and <a href="https://github.com/SimpleJnius">SimpleJnius</a> sprang up due to this limitiations that plyer has. Android-For-Python is notoriously known for building an extensive and vast tools which gives developers a sense of freedom to an extent, that uses pyjnius to couple native android code to develop tools like <a href="https://github.com/Android-for-Python/androidstorage4kivy">androidstorage4kivy</a>, <a href="https://github.com/Android-for-Python/Camera4Kivy">camera4kivy</a> and even wrote a very descriptive article on <a href="https://github.com/Android-for-Python/Android-for-Python-Users">working with kivy on android</a>. KvDroid on the other hand came with 2 ideas, one to make kivy developers not to worry about java in their life and two to kinda use PyJnius tobuild a complete mobile app without using Kivy at all. <a href="https://github.com/kvdroid/Kvdroid/tree/master/demo/android_native_ui">Here</a> is a proof of concept. KvDroid built features like notification, contact reading, sms, wifi, etc… KvDroid noticed also that autoclassing java class (calling java classes) at the top level of the code or even at the top level of any function or method kinda creates a more runtime overhead, so they sought out a lazy loading method where they wrap autoclass in a function and then call the function whenever a java class object needs to be created. That way, you can still import a Java class (which is a python function technically) without slowing down your app. here’s a sample code of what I mean:</p><pre>from jnius import autoclass<br>from kvdroid.jclass import _class_call<br><br><br>def Dimen(*args, instantiate: bool = False):<br>    return _class_call(autoclass(&quot;android.R$dimen&quot;), args, instantiate)<br><br># Then you can now import `Dimen` like so:<br>from kvdroid.jclass.android import Dimen<br><br># so whenever you need to use Dimen java object, you can do this:<br>dimen = Dimen()<br><br># no slowdown at the importation level</pre><p>…. You can checkout this <a href="https://github.com/kvdroid/Kvdroid/tree/master/kvdroid/jclass">https://github.com/kvdroid/Kvdroid/tree/master/kvdroid/jclass</a> to know more. Finally, SimpleJnius. This tool tends to use pyjnius to tap into third party android libraries written in Java or Kotlin and make it accessible in python. So instead of building a certain tool from scratch in python, SimpleJnius just directly taps into an already existing tool in Java. SimpleJnius has built tools like <a href="https://github.com/SimpleJnius/sj-firebase-python">sjfirebase</a> to access the firebase api built with java and make it available for pythonista and also the <a href="https://github.com/SimpleJnius/sj-gemini-vertex-ai">sjgemini-firebase-vertext-ai</a> to access the gemini vertex api written in Kotlin and make it available on python too. Here SimpleJnius uses the power of Java Signatures to make that possible because Pyjnius is also in love with Java Signatures. Here is a sample code for accessing Java class and methods through Signatures:</p><pre>from jnius import (<br>    JavaClass,<br>    MetaJavaClass,<br>    JavaStaticMethod<br>)<br><br>package_path = &quot;com/google/firebase/vertexai&quot;<br><br>__all__ = (&quot;BlockThreshold&quot;, )<br><br><br>class BlockThreshold(JavaClass, metaclass=MetaJavaClass):<br>    __javaclass__ = f&quot;{package_path}/type/HarmCategory&quot;<br>    UNSPECIFIED = JavaStaticMethod(f&quot;L{package_path}/type/BlockThreshold;&quot;)<br>    LOW_AND_ABOVE = JavaStaticMethod(f&quot;L{package_path}/type/BlockThreshold;&quot;)<br>    MEDIUM_AND_ABOVE = JavaStaticMethod(f&quot;L{package_path}/type/BlockThreshold;&quot;)<br>    ONLY_HIGH = JavaStaticMethod(f&quot;L{package_path}/type/BlockThreshold;&quot;)<br>    NONE = JavaStaticMethod(f&quot;L{package_path}/type/BlockThreshold;&quot;)<br>    values = JavaStaticMethod(f&quot;()[L{package_path}/type/BlockThreshold;&quot;)<br>    valueOf = JavaStaticMethod(<br>        f&quot;(Ljava/lang/String;)&quot;<br>        f&quot;L{package_path}/type/BlockThreshold;&quot;<br>    )</pre><p>I will draw my curtain here for now, Now you know a little bit about the history of pyjnius, my next article which I’m currently working on will make you understand how pyjnius works and how to use it. It’s quite simple and fun. Sidenote, I’m a core developer and member at KvDroid and the core developer of SimpleJnius.</p><p><a href="https://medium.com/@akubuekenechukwu/pyjnius-for-dummies-087474436be0">Pyjnius for Dummies</a></p><p>See ya 👋</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=8bc7166ecf7a" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Guess who’s back? (Kivy)]]></title>
            <link>https://medium.com/@akubuekenechukwu/guess-whos-back-kivy-d88528ddc385?source=rss-1b16ceeb8c16------2</link>
            <guid isPermaLink="false">https://medium.com/p/d88528ddc385</guid>
            <category><![CDATA[gemini]]></category>
            <category><![CDATA[python]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[kivy]]></category>
            <category><![CDATA[artificial-intelligence]]></category>
            <dc:creator><![CDATA[Akubue Kenechukwu]]></dc:creator>
            <pubDate>Fri, 08 Nov 2024 19:09:07 GMT</pubDate>
            <atom:updated>2024-11-09T04:51:23.289Z</atom:updated>
            <content:encoded><![CDATA[<p>Guess who’s back? (Kivy)</p><p>When was the last time I wrote an article? So many months ago I guess… I’ve been so occupied with some software projects that I want to turn into startups. By the way I had a startup that I co-founded in 2020 as a student and it crashed in early 2022. It was an e-commerce for students to buy and sell their fairly used products. It was going smoothly until my partner decided to go wild and I left, 2 months later the whole stuff crashed. I already knew it was going to crash due to the way my partner was overseeing the business (long story short, he left people hanging). I understood the business but I preferred being behind the computer (a mistake I should have never mind, I needed to be fully involved).</p><p>Ouch 🤕, where are my manners!!! I was talking about my current project yeah 😀? It might interest you that these projects are all based in kivy. Yeah, I know. I can’t stop using kivy either. I have 3 projects that solve 3 different problems:</p><ul><li>Chollof: food delivery app</li><li>Parkkly : solves traffic issues and helps you find safe parking space and move your car off the streets <a href="https://play.google.com/store/apps/details?id=com.parkkly.parking">https://play.google.com/store/apps/details?id=com.parkkly.parking</a></li><li>FarmiAI: uses Google Gemini ai to help farmers analyze their crops, predict their yield, ai chat, etc..</li></ul><p>Hmm 🤔 yea, all are written in kivy. It took a lot of work to bring parkkly and Farmi AI to life.</p><p>Parkkly made me go back to a subject I hated, Geography. I hated that subject due to the teacher we had then I always failed it and my dad will complain of other failures on my report sheet apart from geography because he knows I wasn’t interested in that subject. I had to go back to geography because the kivy mapview lacked the feature I needed like the poly line and mapview locations focus (made a pull request for that already, it’s merged). Long story short I completed the project successfully and am currently onboarding users.</p><p>With Farmi AI, I had to implement Google Gemini vertex AI for Android java in pyjnius. It was a lot of work getting the java signatures and mapping them to python. Don’t worry I know what you are thinking 😉, I made a library for it and it’s on GitHub <a href="https://github.com/SimpleJnius/sj-gemini-vertex-ai">https://github.com/SimpleJnius/sj-gemini-vertex-ai</a> . With this I implemented chatting features with the ai and crop analysis by taking pictures of the crops and sending them to the Gemini ai.</p><p>Take a pause here, see you on Sunday with a detailed update. Just know that I’m back on medium and I want to spread the gospel of Kivy and inspire you with my own experience and projects 😉.</p><p>✌️</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=d88528ddc385" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Why would I use Kivy when considered not the best option by “experts”?]]></title>
            <link>https://medium.com/@akubuekenechukwu/why-would-i-use-kivy-when-considered-not-the-best-option-by-experts-1591511f718d?source=rss-1b16ceeb8c16------2</link>
            <guid isPermaLink="false">https://medium.com/p/1591511f718d</guid>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[software-engineering]]></category>
            <category><![CDATA[kivy]]></category>
            <category><![CDATA[flutter]]></category>
            <category><![CDATA[software-architecture]]></category>
            <dc:creator><![CDATA[Akubue Kenechukwu]]></dc:creator>
            <pubDate>Tue, 09 Apr 2024 23:26:37 GMT</pubDate>
            <atom:updated>2024-04-10T15:13:22.657Z</atom:updated>
            <content:encoded><![CDATA[<blockquote>Why would I use Kivy when considered not the best option by “experts”?</blockquote><p>Allow me to discuss this question in depth. Let’s begin by analyzing who is an expert and what makes an expert. An expert according to Oxford is, (Noun) “a person who is very knowledgeable about or <a href="https://www.google.com/search?newwindow=1&amp;client=ms-android-xiaomi-terr1-rso2&amp;sca_esv=f84ae1a24cb31e32&amp;sxsrf=ACQVn08ASZJlWtChwL9JdtbtBwVEMzlyLw:1712699529473&amp;q=skilful&amp;si=AKbGX_r0zqXEeLlZhGfi3fbO0QSWbHjYNd3jDqATljGLaRlr1WV6IUCukhdrVm_vos5CnPxxgVOX7GhQj_GCiFLQsfzIZ3rdSw%3D%3D&amp;expnd=1&amp;biw=360&amp;bih=729&amp;dpr=2">skilful</a> in a particular area. E.g ‘an expert in healthcare’”. (Adjective) “having or involving a great deal of knowledge or skill in a particular area. E.g ‘he had received expert academic advice’”. Now we know who is an expert and what makes an expert. Before you continue reading, I want you to take a pause and digest this question: Will you hire an engineer with a vast experience and skill in mobile development with 10% skill in Machine Learning previously working for “google” or would you hire an engineer with 99.9% experience and skill in Machine learning building real world A.I models at his/her garage for your A.I startup and why?</p><p>I have had different developers tell me why what I’m trying to build wouldn’t work with Kivy. When I ask them why, I get replies like this: Kivy widgets are old and ugly, Kivy takes time to startup on Android, Kivy is not a native framework, Kivy cannot access the android Hardwares or Android API’s, My app works on desktop but crashes on mobile, etc… Among the developers that have complained the above issues about Kivy are those that term themselves as experts or have heard experts give advices like, “using the right tool for a specific task”. Let me make something clear before I try to breakdown the above problems, Kivy has documentation and if you read the documentation, you would in reality bring your idea to live on any platform. With that said, let’s try to breakdown and analyze why the so called experts complain about Kivy and after the analysis, we would ask a question based on the meaning of an expert.</p><p>What would make an “expert” complain:</p><ul><li>Did they read the documentation?</li><li>Did they study the source code?</li><li>Did they follow the installation or deployment instructions?</li><li>Did they “WATCH A VIDEO TUTORIAL AND THEN TRIED TO BUILD A COMPLEX APPLICATION WITHOUT VISITING THE DOCUMENTATION”?</li><li>Were they trying to access a native feature on Android and they quickly saw “how impossible it is”?</li></ul><p>There could be many more but let’s dissect these few. I would try to kill so many birds with one stone. If you are an expert,</p><blockquote>having or involving a great deal of knowledge or skill in a particular area.</blockquote><p>Why did you not read the documentation? Let’s assume you read, but you find it difficult to access native Android features. Are you being for real? If there are projects out there that use kivy and have access to Android native features, is that enough proof to remove the sentence, “expert in mobile application” from your title. Because it appears you</p><blockquote>have little or involve a less deal of knowledge or skill in Kivy</blockquote><p>I will go ahead and drop a link to popular library <a href="https://github.com/kvdrioid/kvdroid">https://github.com/kvdroid/kvdroid</a> in the Kivy community which I’m one of the core contributors.</p><p>The knowledge you posses only exist in Flutter. How did you get to even understand Flutter? Well I know how, you watched some YouTube videos and almost anything you wish to implement has been done by many developers on YouTube. Let me ask you a question, “Can you from your existing knowledge build upon what you know to create something new, say a new style of button that bubbles assuming that button has not been implemented yet?”. You had it easy with building apps fast because you could go to YouTube and drop some keywords and YouTube coughs out exactly what you asked for because of the popularity and wide adoption of Flutter. You are not an expert my dear, you my friend is an end user. (The “you” here represents the imaginary expert)</p><p>Wait, I’m not done yet. Those that take advice like “use the right tool for a specific task”. What is the right tool? Why is it the right tool? What does not make it the right tool? Yes, the truth is that you my friend, have never asked yourself this questions, you just used Kivy for while and for some certain reason you don’t know why you are facing a particular issue or what is causing it. With little or no research you jump to the conclusion that Kivy is not the right tool for this task, let’s switch to another framework. What research did you even make? Yeah I tried looking for youtube tutorial and then asked a question on discord or stackoverflow and got no feedback. Let me ask you, “Did you actually pay close attention to your expert advisor, Did you heard him loud and clear when he said READ THE DOCUMENTATION?” You my friend is an end user and not a developer or an engineer. Using the best tool for a task isn’t jumping to using your preferred language, Python, it’s about calming your soul down to analyze carefully what Python can do before building. Can Python perform the functionalities you have on your Wireframe or Flowchart or Pseudo Code? And how can you check if it has? It’s simple, please go and READ THE DOCUMENTATION.</p><p>I would take a pause here and continue the dissection of the above problems developers face while using Kivy and provide a simple solution to all.</p><p>Good Early Morning from Nigeria (12:24 AM)</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1591511f718d" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[About Me]]></title>
            <link>https://medium.com/@akubuekenechukwu/about-me-981a3379f7f9?source=rss-1b16ceeb8c16------2</link>
            <guid isPermaLink="false">https://medium.com/p/981a3379f7f9</guid>
            <category><![CDATA[comedy]]></category>
            <category><![CDATA[racism]]></category>
            <category><![CDATA[nature]]></category>
            <category><![CDATA[romance]]></category>
            <category><![CDATA[love]]></category>
            <dc:creator><![CDATA[Akubue Kenechukwu]]></dc:creator>
            <pubDate>Sat, 30 Mar 2024 17:46:12 GMT</pubDate>
            <atom:updated>2024-03-30T17:46:12.677Z</atom:updated>
            <content:encoded><![CDATA[<p>About Me</p><p>I want to tell you a story. A story about me. Let’s go back to the beginning.</p><p>Mr Izundụ, a young seminarian was still discovering his path in life. His path to priesthood wasn’t so sure of him. Nature was speaking to him in a different language. He did well as a Philosopher and as a Theologian. He loved books, his room is always filled with books, newspapers, bulletin and definitely the Bible. Was he going to read the Quran too? Ehhn, never mind let’s move on. But I wouldn’t be surprised if he did.</p><p>During his 3rd year as a Theologian, he left the seminary in search of answers, answers to what nature spoke to him of. He went to the prestigious University of Nigeria Nsukka to find that answer. He completed his master’s degree successfully. The University never had the answers he was looking for, didn’t they? Few years later he met a goddess in human form. A goddess that will change his life forever.</p><p>Miss Adaobi, a young lady teaching at a girl’s Catholic school in her home town. She earned her NCE at the northern part of the country. And was on her way to getting a degree certificate at a College in Owerri. Oh, she loves farming more than you can think of.</p><p>Fate is one crazy motherf**ker, Mr Izundụ taught Miss Adaobi chathecism and they both are from the same town. Life always revolves around you sometimes. You just have to listen to Nature when it speaks to you.</p><p>Who says that this is a story about Mr Izundụ and Miss Adaobi. Sorry for spoiling your mood. This story isn’t about two lovers. Ya they both are my parents now.</p><p>The year is 199*… hold it right there. What does my birth year got to do with this? Sorry back to the story, I was correcting the writer. I was born on the 19th of May. That was on a Wednesday morning. My mom said it was a morning but my stupid as cousin made fun of me all the time because of how dark my skin was, they said I was actually born in the middle of the night. That the nurses literally had to get a lantern to see me very well. Oh for f**k sake, I never knew Africans were racist against their own blood too. What the f**k is going on here? The most funny thing was, when I was in a boarding school, I was described in a whole lot of ways. For example: some students said when God Said let there be light, I was nowhere to be found. Another said I looked like under the bed. Some said that once it’s time for lights out, I was literally the electricity that they switched on. Some of these niggers are f**king dark in the mind men. I have been called names more than a human being can survive. Thank God I can’t commit suicide because that rope is as painful as hell. I can’t even stab myself with a knife that shit hurts. Or imagine me drowning, oh boy, no way I’m doing that my soul will leave my fucking body. Wait a minute, that’s the essence of commiting a suicide, for the soul to leave the body. Nah I’m good, I still got more names to be called you know. If I die now, the remaining names, who will take the hit? So that’s my fucking spot. I need to stay f**king alive to take the hit.</p><p>Was I telling a story of myself, or was I freelancing? Dude!!! What the f**k. Hey you the reader. I just want to let you know that I want to start writing love stories too. I still write tech articles too. I’m working on a love and romantic story. It is going to be big. I can’t give a name yet for it. But I did hope to catch your attention with it. Trust me, it’s really good.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=981a3379f7f9" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[It has nothing to do with Kivy? Is that a Lie?]]></title>
            <link>https://medium.com/@akubuekenechukwu/it-has-nothing-to-do-with-kivy-is-that-a-lie-fd69c8bec2e3?source=rss-1b16ceeb8c16------2</link>
            <guid isPermaLink="false">https://medium.com/p/fd69c8bec2e3</guid>
            <category><![CDATA[kivy]]></category>
            <category><![CDATA[life]]></category>
            <category><![CDATA[programming]]></category>
            <category><![CDATA[software-development]]></category>
            <category><![CDATA[software-engineering]]></category>
            <dc:creator><![CDATA[Akubue Kenechukwu]]></dc:creator>
            <pubDate>Wed, 27 Mar 2024 15:21:07 GMT</pubDate>
            <atom:updated>2024-03-27T15:21:07.556Z</atom:updated>
            <content:encoded><![CDATA[<p>It has nothing to do with Kivy? Is that a Lie?</p><p>Hey there 👋, before you go on to read this article, I would like to check up on you 😉. How is it going? Hope life is not too hard on you? I did be happy to get a response from you in the comment section. If things are tough, don’t worry we are all in this life together 💞. Life will definitely have a positive meaning in our life as time goes on 😊.</p><p>You know for the past 2 months, I have been all over the place, working on different ideas, freelancing here and there and still learning new things about Software Engineering. But one thing that doesn’t seem to change is the tool I use. I guess you know what I’m about to say 😂, “Kivy”. You got that right ▶️. Before I continue further, I would like to take out time to thank everyone that read my previous article. I never knew my writing could hold people’s attention and I have you the readers to thank for it and make me discover that.</p><p>In my last article, I wasn’t going to start comparing Kivy to any other framework out there. That wasn’t the goal in the first place. You see, different tools have different goals they accomplish. You wouldn’t want to cook food in a cup, like you wouldn’t want to hit a nail with a screw driver. But that doesn’t mean you can’t actually do that. It’s doable, but how effective is it? This question right here calls for upgrading or modifying the existing tool to achieve a goal that will be more effective, efficient and less time consuming. That’s exactly what I wanted you my readers to take away from my previous article.</p><p>The year is 2011, the year Kivy was born. Fast-forward 4 to 5 years later when Flutter came out. You would notice that few knows about Kivy, everybody knows about Flutter. Why is that? Does that mean that Flutter has the answers that developers are looking for or that Kivy has some weird old looking kinda design and is not yet ready to accept the modern UI looks? Or (whispers) Flutter is backed by google with enough funding and Kivy isn’t. The point I’m trying to make here is that these two tools are similar in different cases and solve almost the same problem and even have comparable speed (More details in a later article….). But the difference is in the marketing and funding. Flutter got google that makes noise about them but Kivy has people like me with tiny voices (I literally mean empty pockets 😂) that say one or two nice things about Kivy things to a small group of audience. Another test case is the job market. Kivy is nowhere close to Flutter in the job market 😂.</p><p>Going back to what I said earlier about upgrading a tool that’s not efficient enough to do a certain task. Let me rewind your brain to how technology evolved. Think of how riding a horse evolved to a horse with a carriage, further evolved to a fuel car and here we are talking about electric vehicles. See the pattern? The cup in this case can actually be used to cook a nice meal more effectively if the cup can be modified and upgraded to a much larger cup, in this case a pot.</p><p>Is there a light bulb 💡 in your brain right now? Aha, there’s nothing like the best tool for a job. A hammer can be the best option for hitting a nail at the moment but that’s sure not the best that’s not the best tool for the job because there’s an actual machine that can drill a nail straight into a wood without much muscle flexing. But that doesn’t make the drilling machine the best tool for the job either. It’s still prone to evolving into something much easier with zero noise.</p><p>Kivy has nothing to do with your app being slow, neither is any other framework out there. It depends on your ability to evolve your thought process. Let’s assume we are racing to Ghana from Nigeria and there’s a straight road that leads to Ghana from Nigeria and there’s another that goes through different countries that are far from Ghana and not sharing any border with Nigeria. You take the straight route and I take the other. Who do you think will win the race?</p><p>It’s not the car it’s the driver (but sometimes it is the car, and it’s your duty to either evolve the car or evolve your mind by looking for the shortest route possible). Kivy is as good as any other framework, what you choose to do with it all depends on you. Kivy has helped me evolve my mind in different ways. Kivy made me see Programming as not just writing code but as a tool given to me by nature to have powers like a god. I can create as much as I can destroy.</p><p>Kivy has never been the problem, step back and analyze the approach you took while using Kivy. How effective is it?</p><p>Let your mind evolve 🌟⭐✨💡</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=fd69c8bec2e3" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Is Kivy the right choice of framework for your mobile app? development?]]></title>
            <link>https://medium.com/@akubuekenechukwu/is-kivy-the-right-choice-of-framework-for-your-mobile-app-development-1f507b113490?source=rss-1b16ceeb8c16------2</link>
            <guid isPermaLink="false">https://medium.com/p/1f507b113490</guid>
            <category><![CDATA[kivy]]></category>
            <category><![CDATA[android]]></category>
            <category><![CDATA[flutter]]></category>
            <category><![CDATA[kivy-python]]></category>
            <category><![CDATA[java]]></category>
            <dc:creator><![CDATA[Akubue Kenechukwu]]></dc:creator>
            <pubDate>Tue, 06 Feb 2024 22:47:04 GMT</pubDate>
            <atom:updated>2024-02-06T22:47:38.590Z</atom:updated>
            <content:encoded><![CDATA[<h3>Is Kivy the right choice of framework for your mobile app development?</h3><p>My name is Kenechukwu Akubue and I have been an active user of the Kivy framework for the past 5 years. I have 7 years of experience as a software developer/engineer-ish.</p><p>Why am I starting with my years of experience? Well, I have had interest in writing an article about Kivy and how awesome the framework is since I built my first kivy app. I wanted to prove to everyone who thinks python can’t be used to build mobile apps wrong. I wanted to preach the gospel of python to the whole world 🌍. I despised every other Programming Language. I was <em>what</em> you may call a Python fanatic (there will be a whole article for this later in the future).</p><p>I was still getting into the world of mobile app development, when developing apps with Java was more of a thing before Kotlin came knocking. I had zero experience of how Java works and I hated the fact that I have to use java to build an android app. I read a few pages of Java for dummies and Android for dummies, to be frank, I got lost in the middle of understanding XML markups. I had to shutdown Android for dummies and focused my attention on Java for dummies. I understood to an extent what was going on in the book due to the fact that I have had previous knowledge of Python. But with time I got bored, I saw myself in a tutorial hell, I kept repeating some pages over and over again. Guess what, I deleted the PDF 😅 out of frustration. The reason why I was stuck wasn’t because I was not understanding, but because I was doing exactly what the book says and not trying out something creative on my own (more on this in a later article of my Python journey). I’m the kind of guy that hates doing exactly what the rules say. I rather break the rule and know what the punishment feels like than to die and keep on wondering what the punishment would have felt like 😂. I used the knowledge I got from Python to navigate my way around building an android app with Java. I watched a few YouTube videos on how to set up my development environment on Android studio and make some designs with XML, the rest of my learning journey ended up in me googling stackoverflow and reading different articles (I still hate watching video tutorials). With time I became quite good with Java and started building my own stupid apps. By the way, my XML skill was full of shit 😄. I used drag and drop and I cursed Google because I never understood the layouts and how they work. My designs were pretty messy 😭.</p><h4>Welcome to my Kivy Experience 😂</h4><p>I still hated Java and I kept on believing that there are spiritual Python libraries out there that can be used to build Android apps. I began scraping the Internet in search of these magical gems. I first discovered “Tinker&quot; but, it’s just a Graphical User Interface (GUI) for desktop only. But wait a minute, there’s this app called pydroid3 on Android which runs Tkinter without stress on Android. How is that possible? Anyways, with consistent scraping, I stumbled upon Kivy at first, the simple “hello world&quot; code looked so simple but the UI is ugly(I must confess).</p><p>If you leave me, I will write a whole Bible on my kivy Experience 😂. Don’t worry, I will still tell you more of my experience in a later article.</p><p>After 7 years of software development, I have come to realize that there is no right or wrong. It all depends on your variables(your needs). I have had a taste of Java, Flutter and Kivy and I choose Kivy every single time. Here are my reasons:</p><ul><li>I love Python (it’s a fact)</li><li>I was able to understand the concept of GUI clearly in Kivy (although QT has python bindings, It’s nowhere near Kivy when it comes to simplicity and clarity. More on this in a future article).</li><li>Is Kivy faster than Kotlin, Java and Swift? Not even close. Is Kivy comparable to Flutter? Yes, but I’m not saying for sure. Is Kivy faster than Flutter? I don’t know. Is Kivy better than Flutter? Hey man, look, I haven’t done any benchmark tests yet. So why Kivy? It’s simple to set up and use.</li><li>Among all the Frameworks and Programming Languages I have used to build mobile apps, I found Kivy to be the most friendly when it comes to customizing the User Interface to anything you can imagine. Thanks to Kivy I was able to understand that XML thing I was struggling with earlier during my Java days of nightmare. (More on this in a later article).</li><li>Ya, I heard you Bob!! I know that Flutter has a flawless state management and the same applies to their hot reload. But guess what Bob, I can do the same state thingys with Kivy bind functions and yea Kivy’s hot reloader is still sucking momma’s breast compared to grandaddy Flutter. Guess what again, I don’t care Bob.</li><li>Kivy is now a part of me, I mean chew Kivy source code like I chew a peanut. I understand a concept better by looking at the source code and kivy did a great job in structuring their source code.</li><li>Kivy is not the best, but I will choose Kivy over any other framework out there every f**kin time. I guess I’m already too comfortable with Kivy.</li><li>But you know there are not plenty of jobs out there in kivy? Yeah Bob!! I know that. But guess what Bob, I have developed 48+ apps in Kivy, for different corporate organizations. It’s not the car Bob, it’s the driver. I was able to showcase and prove what I have been able to achieve with Kivy before I got all these jobs.</li></ul><h4>Conclusion</h4><p>It’s not the car, it’s the driver!!! How you build your app matters, the tools you use do not have much of an effect. They only have an effect when you have critically analyzed what you want to build and then come to a decision on what tool to use to bring your idea to life. I will tell you this, I will always choose kivy any day even if Kivy may not be the best option. My reason remains, “I would rather break the rule to know what the punishment feels like than to die wondering what the punishment feels like”.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=1f507b113490" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>