<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Andrii Leitsius</title>
    <description>The latest articles on DEV Community by Andrii Leitsius (@leits).</description>
    <link>https://dev.to/leits</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F88288%2Ffe86cda3-1787-41cc-9177-d5e7298035ef.jpeg</url>
      <title>DEV Community: Andrii Leitsius</title>
      <link>https://dev.to/leits</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/leits"/>
    <language>en</language>
    <item>
      <title> Follow GitHub repos the way you like</title>
      <dc:creator>Andrii Leitsius</dc:creator>
      <pubDate>Tue, 31 Aug 2021 20:07:39 +0000</pubDate>
      <link>https://dev.to/leits/follow-github-repos-the-way-you-like-9pa</link>
      <guid>https://dev.to/leits/follow-github-repos-the-way-you-like-9pa</guid>
      <description>&lt;p&gt;Hi, DEV!&lt;br&gt;
I'm looking for GitHub users to help me with feedback.&lt;/p&gt;

&lt;p&gt;GitHub notification sucks. It's so easy to be overwhelmed when there is a lot of activity in the repositories.&lt;/p&gt;

&lt;p&gt;So I build a newsletter service to be up to date with desired repository activity:&lt;br&gt;
&lt;a href="https://ohmycode.cc"&gt;https://ohmycode.cc&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--W_L93RDc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hdvcrfrokm88umke7qd2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--W_L93RDc--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/hdvcrfrokm88umke7qd2.png" alt="Alt Text"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;Any feedback is welcome!&lt;/p&gt;

</description>
      <category>opensource</category>
      <category>github</category>
      <category>saas</category>
    </item>
    <item>
      <title>Satisfy your very first user</title>
      <dc:creator>Andrii Leitsius</dc:creator>
      <pubDate>Sat, 03 Apr 2021 09:18:28 +0000</pubDate>
      <link>https://dev.to/leits/satisfy-your-very-first-user-274a</link>
      <guid>https://dev.to/leits/satisfy-your-very-first-user-274a</guid>
      <description>&lt;p&gt;I have good news for you. When you launch something, your first user appears very quickly. And it's you.&lt;/p&gt;

&lt;p&gt;First, you solve your pain, and then you solve this pain for others.&lt;/p&gt;

&lt;p&gt;But there is also bad news: resolving pain for you may not wholly solve others' pain. Or maybe it's not so painful for them. Pretty harsh, right?&lt;/p&gt;

&lt;p&gt;I have been thinking about this for a month since my previous post. When the previous issue was in the email boxes, PoC had already been working and meeting my needs. I received a report every morning.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--6XypPw6v--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tix7wqou9l58yn4yw3w5.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--6XypPw6v--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tix7wqou9l58yn4yw3w5.png" alt="report"&gt;&lt;/a&gt; &lt;/p&gt;

&lt;p&gt;I've made a lot of useful but not important improvements this month. This time I will skip them and the technical details of their implementation.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Tell me, are you interested in reading low-level implementation details? Please reply to this letter with even one sentence, to let me know. Interested in your opinion.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;Among handy things, the name is first.&lt;/p&gt;

&lt;p&gt;OhMyCode&lt;/p&gt;

&lt;p&gt;It seems easy and friendly to me. And not even overused by other products.&lt;/p&gt;

&lt;p&gt;Next, I realized that my pain solvers are quite specific, and it isn't actually a pain for others. Two out of two, yeah?&lt;/p&gt;

&lt;p&gt;Why specific? I am interested in very particular data very peculiarly grouped—for example, the total downloads of all releases' assets. And I don't need info about new commits in the repository because only I have the right to push and merge.&lt;/p&gt;

&lt;p&gt;But why it isn't a pain for others? I can't find a similar service, so I decided to ask the audience if they would find it helpful. I prepared a post with a link to the waitlist, published it on several subreddits, IndieHackers, and HackerNews.&lt;/p&gt;

&lt;p&gt;And didn't get any reply or upvote. It's good that I've already gathered a dozen people interested in the beta; because of such a result, the project could be curtailed.&lt;/p&gt;

&lt;p&gt;So I decided to go with something simple so people could try it. But the current version is not suitable at all. Just because it solves only my problems.&lt;/p&gt;

&lt;p&gt;Next, I'll try to abstract from them and make a simple MVP that will be useful for more people.&lt;/p&gt;

&lt;p&gt;And while I'm working on it, you might find handy &lt;a href="https://sourcekarma.vercel.app"&gt;SourceKarma&lt;/a&gt;. Simple tiny service to discover how people react to your comments on GitHub. I want to do something just that "easy".&lt;/p&gt;

</description>
    </item>
    <item>
      <title>How I create GitHub project reporting from scratch</title>
      <dc:creator>Andrii Leitsius</dc:creator>
      <pubDate>Fri, 05 Mar 2021 16:41:22 +0000</pubDate>
      <link>https://dev.to/leits/how-i-create-github-project-reporting-from-scratch-mji</link>
      <guid>https://dev.to/leits/how-i-create-github-project-reporting-from-scratch-mji</guid>
      <description>&lt;p&gt;The &lt;a href="https://leits.substack.com/p/leits-makes-stuff-1"&gt;previous issue&lt;/a&gt; was about the idea and scoping of Proof Of Concept. And now it's time to implement it! Below I will tell you how I came from nothing to this:&lt;br&gt;
&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--jyTiOnQm--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/s3fv9f1q0kur1budkyxr.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--jyTiOnQm--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/s3fv9f1q0kur1budkyxr.png" alt="diagram"&gt;&lt;/a&gt;   &lt;/p&gt;

&lt;p&gt;One of the most important things for PoС is the speed of implementation, so I decided to use boring technologies that I’m familiar with.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;All source code you can find on GitHub &lt;a href="https://github.com/leits/OhMyCode"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;h3&gt;
  
  
  Data collection
&lt;/h3&gt;

&lt;p&gt;First of all, I started with a python script that collects data from GitHub.&lt;/p&gt;

&lt;p&gt;This source has two interfaces: REST API and GraphQL. The last one is optimized and recommended. It gives you more information with the same rate limit of 5K requests per hour. However, the REST API has a well-documented PyGithub client library, so I used it as a start point.&lt;/p&gt;

&lt;p&gt;Data that I needed:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;Numbers of downloads, views, stars, and open issues&lt;/li&gt;
&lt;li&gt;Issues and Pull Requests that have been updated&lt;/li&gt;
&lt;li&gt;Main referrers and views over the past two weeks&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Almost all data can be easily collected by several client methods. Only traffic info requires an access token which can be obtained in the account settings.&lt;/p&gt;

&lt;h3&gt;
  
  
  Data visualization
&lt;/h3&gt;

&lt;p&gt;Now we need to visualize the views on the repository with a line chart.&lt;/p&gt;

&lt;p&gt;Firstly, I tried the most popular visualization library &lt;a href="https://github.com/matplotlib/matplotlib"&gt;matplotlib&lt;/a&gt;. But its configuration didn’t seem clear to me, so moved on with other options. &lt;/p&gt;

&lt;p&gt;Stopped at &lt;a href="https://github.com/altair-viz/altair"&gt;altair&lt;/a&gt;, its result from the box was quite nice and simple. But I abandoned it as well while implementing the email sending. The reason was that altair saves the rendered image in a specified path. And I would like to avoid disk operations (writing and reading the image in the same process).&lt;/p&gt;

&lt;p&gt;Fortunately, I found a chart generator in &lt;a href="https://github.com/pandas-dev/pandas"&gt;pandas&lt;/a&gt; (a library for data analysis) that uses matplotlib under the hood. Working with it is very simple: create a table, add data, and plot lines.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--FNDd95CV--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kipic2lkqfbqm6y67hq2.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--FNDd95CV--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kipic2lkqfbqm6y67hq2.png" alt="Views chart"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;I redirected the chart output to the buffer using built-in &lt;a href="https://docs.python.org/3/library/io.html#io.BytesIO"&gt;bytesIO&lt;/a&gt;, thus avoiding writing then reading from disk.&lt;/p&gt;

&lt;h3&gt;
  
  
  Data presentation
&lt;/h3&gt;

&lt;p&gt;Regarding the format of the letter, markdown was the first idea I came up with. As it turned out, it was a terrible one.&lt;/p&gt;

&lt;p&gt;At the outset, I found out that email can be only html or plain text. Therefore, the markdown must be rendered in html to have an intended look.&lt;/p&gt;

&lt;p&gt;For this purpose, I tried &lt;a href="https://github.com/Python-Markdown/markdown"&gt;markdown&lt;/a&gt; library. It's good to create markdown files and very convenient in working with text and tables. However, it renders the content in html without any styles. Hence, the result was far from a pretty looking markdown in editors.&lt;/p&gt;

&lt;p&gt;At this point, my inner desire to make things prettily overcame my need to minimize the effort on PoC.&lt;/p&gt;

&lt;p&gt;So I found &lt;a href="https://github.com/markedjs/marked"&gt;marked.js&lt;/a&gt; and learned that tables are an extension to the original markdown. While I was trying to run CLI of this lib in the console, I got the same result: bare html without css.&lt;/p&gt;

&lt;p&gt;Next was &lt;a href="https://github.com/markdown-it/markdown-it"&gt;markdown-it.js&lt;/a&gt;. It was getting even harder because this lib didn’t have a CLI. But the &lt;a href="https://markdown-it.github.io"&gt;demo&lt;/a&gt; looked tempting, so I wrote a js script that reads the file, uses markdown-it, and writes the result back to the file. And you know what? The same result. Bare html. &lt;/p&gt;

&lt;p&gt;That was a failure.&lt;/p&gt;

&lt;p&gt;And at the moment when I found &lt;a href="https://github.com/sindresorhus/generate-github-markdown-css"&gt;script&lt;/a&gt; that gets styles from GitHub for markdown rendering, I stopped.&lt;/p&gt;

&lt;p&gt;The first thing I realized was that I don't really need tables. I can display this information in plain text and it looks readable.&lt;/p&gt;

&lt;p&gt;The second is that I don't need a markdown at all. I chose it because I liked its simple and nice look. But if I need to send html, why not to generate it directly?&lt;/p&gt;

&lt;p&gt;So I went back to boring technology. I took &lt;a href="https://github.com/pallets/jinja"&gt;Jinja2&lt;/a&gt; and rendered html from the template. The code has almost halved, and rationality has doubled.&lt;/p&gt;

&lt;h3&gt;
  
  
  Data sending
&lt;/h3&gt;

&lt;p&gt;The last step is sending it all by email.&lt;/p&gt;

&lt;p&gt;As an email service, I took Mailgun. It’s free for three months with 5K emails/month, and then $0.8 for every 1K emails. The interface is as simple as possible: send a request for a specific URL with an authentication token. Used &lt;a href="https://github.com/psf/requests"&gt;requests&lt;/a&gt; for HTTP calls.&lt;/p&gt;

&lt;p&gt;To send pictures in the body of the letter (not as an attachment), you need to enclose them as a MIME object. The name of the object is specified in the image tag, and the email client displays it in the body.&lt;/p&gt;

&lt;p&gt;The built-in &lt;a href="https://docs.python.org/3/library/email.mime.html"&gt;email.mime&lt;/a&gt; handles this perfectly.&lt;/p&gt;

&lt;p&gt;Well, the script works, so let’s make it run automatically. Following reliable "boring" technologies, I took &lt;a href="https://www.heroku.com"&gt;Heroku&lt;/a&gt;. For the current solution, a free instance and Heroku Scheduler are enough to run the script at a certain time.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--l1V-v0L6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/swzy7pc97cxr8io6tdqu.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--l1V-v0L6--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/swzy7pc97cxr8io6tdqu.png" alt="email"&gt;&lt;/a&gt; &lt;/p&gt;

&lt;h3&gt;
  
  
  So,
&lt;/h3&gt;

&lt;p&gt;The Proof Of Concept is completed. &lt;/p&gt;

&lt;p&gt;Next, I plan to save the data to show the trends, make the report more informative and prettier.&lt;/p&gt;

&lt;p&gt;And I also noticed the strange behavior of issue filtering in GitHub API, which I need to research.&lt;/p&gt;




&lt;p&gt;The main motto of this post:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;Use boring technologies&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;This is almost always the right choice.&lt;/p&gt;

</description>
      <category>python</category>
      <category>webdev</category>
      <category>programming</category>
      <category>opensource</category>
    </item>
    <item>
      <title>Shaping idea into Proof Of Concept</title>
      <dc:creator>Andrii Leitsius</dc:creator>
      <pubDate>Wed, 24 Feb 2021 21:07:58 +0000</pubDate>
      <link>https://dev.to/leits/leits-makes-stuff-1-from-idea-to-proof-of-concept-f89</link>
      <guid>https://dev.to/leits/leits-makes-stuff-1-from-idea-to-proof-of-concept-f89</guid>
      <description>&lt;p&gt;While working on MeetingBar, I noticed that I refresh the statistic pages on GitHub very often. I even wrote a telegram bot that sends me a count of installs and repository stars every morning. So I decided to make a service for analytics and reports for open-source projects.&lt;/p&gt;

&lt;h3&gt;
  
  
  Let's start from a blank page
&lt;/h3&gt;

&lt;p&gt;When I open my project page, I have two needs: dopamine and useful information.&lt;/p&gt;

&lt;p&gt;Dopamine is stored in numbers. Downloads, stars, views. I want to receive this data often and to be able to compare their values with the previous ones.&lt;/p&gt;

&lt;p&gt;Useful information lies deeper. In comments on the issues, updates to the pull requests, new project referrers. It already comes in GitHub notifications, but they are generated for each action. So it would be convenient to receive a full report for a certain time instead of viewing a dozen notifications during the day.&lt;/p&gt;

&lt;p&gt;In addition to all this, it would be nice to have a project status visualization that can be shared. Thus, every project on GitHub can get the basis to become an open startup without additional effort.&lt;/p&gt;

&lt;p&gt;So I need to build a platform that collects&amp;amp;stores data from GitHub, makes dashboards, and sends reports. It looks like a great bunch of work!&lt;/p&gt;

&lt;h3&gt;
  
  
  Scoping
&lt;/h3&gt;

&lt;p&gt;Let's start with simple Proof Of Concept.&lt;/p&gt;

&lt;p&gt;The easiest way to validate an idea is to build a service that periodically collects necessary data and sends an email report. At this point, we will skip the UI part with dashboards and data storing for metrics comparison.&lt;/p&gt;

&lt;p&gt;This data will be collected every morning and send to me by email.&lt;/p&gt;

&lt;p&gt;The letter will have the following structure:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;&lt;p&gt;First, there will be numbers to satisfy my excitement.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;Then issues and pull requests that have changed over the past day.&lt;/p&gt;&lt;/li&gt;
&lt;li&gt;&lt;p&gt;And in the end, there will be traffic.&lt;/p&gt;&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;&lt;a href="https://res.cloudinary.com/practicaldev/image/fetch/s--CurjGv6k--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/yv5e2wcyiuezvxthvz8y.png" class="article-body-image-wrapper"&gt;&lt;img src="https://res.cloudinary.com/practicaldev/image/fetch/s--CurjGv6k--/c_limit%2Cf_auto%2Cfl_progressive%2Cq_auto%2Cw_880/https://dev-to-uploads.s3.amazonaws.com/uploads/articles/yv5e2wcyiuezvxthvz8y.png" alt="letter"&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The traffic section requires a lot of effort with authorization and visualization. But I decided to include it in PoC because it will cover all my needs for opening a GitHub every morning.&lt;/p&gt;

&lt;h3&gt;
  
  
  What's next?
&lt;/h3&gt;

&lt;p&gt;The implementation story.&lt;/p&gt;

&lt;p&gt;Then I'll try to use it for a week. So I'll understand whether it's useful and what needs to be improved.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;📌 If you are interested in this idea, contact me. I'll notify you as soon as I plan the beta.&lt;/p&gt;
&lt;/blockquote&gt;




&lt;p&gt;&lt;a href="https://leits.substack.com/welcome?r=h8qz8&amp;amp;utm_campaign=account&amp;amp;utm_medium=web&amp;amp;utm_source=dev.to"&gt;Subscribe&lt;/a&gt; to receive the next issue when it's ready!&lt;/p&gt;

</description>
      <category>showdev</category>
      <category>writing</category>
      <category>startup</category>
      <category>buildinpublic</category>
    </item>
    <item>
      <title>Intro</title>
      <dc:creator>Andrii Leitsius</dc:creator>
      <pubDate>Mon, 22 Feb 2021 22:58:32 +0000</pubDate>
      <link>https://dev.to/leits/leits-makes-stuff-0-hello-world-1i93</link>
      <guid>https://dev.to/leits/leits-makes-stuff-0-hello-world-1i93</guid>
      <description>&lt;p&gt;Hi there! I'm leits.&lt;/p&gt;

&lt;p&gt;This is my public journal where I think aloud and share what I learned while making stuff (mostly software and around).&lt;/p&gt;

&lt;p&gt;Behind my back are seven years in software engineering. During this time, I saw many products from the inside. Launched and scaled a big bunch of them. Made many great and some not the best architectural decisions.&lt;/p&gt;

&lt;p&gt;The thing I learned well over that time:&lt;/p&gt;

&lt;p&gt;There is no right way to make new stuff&lt;/p&gt;

&lt;p&gt;Every time you start doing something new, you move by trial and error. It's quite healthy to master new skills and build your own opinion. &lt;/p&gt;

&lt;p&gt;I already have experience in building things in public. &lt;/p&gt;

&lt;p&gt;In early 2020, when I had a lot of meetings, I created &lt;a href="https://apps.apple.com/app/id1532419400"&gt;MeetingBar&lt;/a&gt; to be more comfortable with them. I published this project, and now it has 17K+ installations. The public codebase on &lt;a href="https://github.com/leits/MeetingBar"&gt;GitHub&lt;/a&gt; gathered 1.8K stars and 20 contributors.&lt;/p&gt;

&lt;p&gt;I realized that my experience in building and running projects can be useful. Or just interesting for someone.&lt;/p&gt;

&lt;p&gt;Now I'm working on an analytics service for the open-source community. In this place, I'll share my trials and errors on how I make stuff.&lt;/p&gt;

&lt;p&gt;Sign up now, so you don't miss the first issue:&lt;br&gt;
&lt;a href="https://leits.substack.com/p/coming-soon?r=h8qz8&amp;amp;utm_campaign=post&amp;amp;utm_medium=web&amp;amp;utm_source=devto"&gt;https://leits.substack.com&lt;/a&gt;&lt;/p&gt;

</description>
      <category>showdev</category>
      <category>writing</category>
      <category>startup</category>
    </item>
  </channel>
</rss>
