teleren/devto huggingface dataset:
Daily Developer Jokes - Saturday, Aug 29, 2020
Tags: jokes, dailydeveloperjokes
Published: 2020-08-29 12:00:20

---
title: "Daily Developer Jokes - Saturday, Aug 29, 2020"
description: "Check out today's daily developer joke! (a project by Fred Adams at xtrp.io)"
series: "Daily Developer Jokes"
cover_image: "https://private.xtrp.io/projects/DailyDeveloperJokes/thumbnail_generator/?date=Saturday%2C%20Aug%2029%2C%202020"
published: true
tags: #jokes, #dailydeveloperjokes
---

Generated by Daily Developer Jokes, a project by [Fred Adams](https://xtrp.io/) ([@xtrp](https://dev.to/xtrp) on DEV)

___Read about Daily Developer Jokes on [this blog post](https://xtrp.io/blog/2020/01/12/daily-jokes-bot-release/), and check out the [Daily Developer Jokes Website](https://dailydeveloperjokes.github.io/).___
### Today's Joke is...
![Joke Image](https://private.xtrp.io/projects/DailyDeveloperJokes/public_image_server/images/5e1258c00f974.png)

---
*Have a joke idea for a future post? Email ___[xtrp@xtrp.io](mailto:xtrp@xtrp.io)___ with your suggestions!*

*This joke comes from [Dad-Jokes GitHub Repo by Wes Bos](https://github.com/wesbos/dad-jokes) (thank you!), whose owner has given me permission to use this joke with credit.*

<!-- 
Joke text:
___Q:___ What does a baby computer call his father?

___A:___ Data!
 -->
The JavaScript's Prayer
Tags: jokes, javascript, typescript, node
Published: 2020-08-29 11:25:59


Our JavaScript which art in v8,
Hallowed be thy data types.
Thy prototypes come,
Thy will be done in ES six,
as it is in ES five.
Give us this day our daily promises.
And forgive us our TypeErrors,
as we forgive our syntax sugared code.
And lead us not into 404, not in npm registry
but deliver us from broken builds and errors:
For thine is the classes,
the spreads, and the template strings,
for ever. Amen.
There is one more Google Developer Expert in the world! :)
Tags: angular, gde
Published: 2020-08-29 11:23:40


I am pleased to share with you the news that I have received the official title of Angular GDE. This gives new opportunities, but with it comes with even greater responsibility.

What is GDE? Google Developers Experts is a global network of tech experts, influencers, and influencers who actively support developers, businesses, and tech communities by speaking at events and posting content. These professionals actively contribute to and support developer and startup ecosystems around the world, helping them create and launch innovative applications.

About 700 experts represent 18+ Google technologies around the world! In my case, this technology is Angular. The GDE title does not mean that I work with Google or that Google gave me money :) It just means that Google recognizes my expertise in Angular.

GDE is getting:
1) Google Recognition
2) Ability to communicate with Angular developers and other Google teams
3) Access to closed groups of GDE experts
4) Invitations to events (aka a trip to Google I / O)

Here are some of the things that Google noted in my work:

- I have worked with the earliest versions of Angular (2.x) (before it became popular)
- Created one of the largest Russian-speaking Angular community with more than 5 thousand developers https://t.me/angular_ru
- Together with Tinkoff, organized more than 17 Angular meetups in Moscow and the regions. I helped people with the preparation of talks https://www.youtube.com/channel/UCpDTAtunmHBcI6CsJoUV7ww/videos
- Co-organized the first in Russia NgGirls https://ng-girls.org/moscow-2019/
- In collaboration with JetBrains, has awarded over 20 licenses for InteliJ products among Angular developers.
- Gave more than 30 talks (including talks on Angular) https://github.com/Semigradsky/events/blob/master/speakers.md#by-the-count-of-talks-more-than-one
- Made (with the help of the community) the Russian-language Angular documentation https://angular24.ru/
- Developed a fairly popular plugin (more than 1700 developers have already installed it) for automatic refactoring of Angular components https://marketplace.visualstudio.com/items?itemName=obenjiro.arrr
- Author of Russian-language articles on Medium https://medium.com/@obenjiro
- Author of Russian-language articles on Habr https://habr.com/ru/users/obenjiro/posts/
- The author of the Russian-language Telegram channel https://t.me/obenjiro_notes
- Author of the English-language Twitter blog https://twitter.com/obenjiro
- Author of English-language articles on dev.to https://dev.to/obenjiro

But I do not plan to stop there. Already now I am actively working on improving the quality of the Russian-language Angular documentation, developing Granula (an alternative Runtime for Angular) and Reagain (a tool for static analysis of the code base). I will also do my best to enlarge Angular community and make it soft and fluffy for everyone :)

Subscribe to my (RU) Telegram channel https://t.me/obenjiro_notes or (ENG) Twitter blog https://twitter.com/obenjiro to always keep abreast of my latest developments and articles;)
Continuous Integration (CI) for JS apps - GitHub Actions workflow
Tags: actionshackathon, javascript, github, vue
Published: 2020-08-29 11:15:22

## My Workflow
I create a basic CI workflow, called CI.yml, for any javascript or JS framework application.

In this post I explain each step and why is important to have at least these ones:

{% link https://dev.to/dawntraoz/how-to-add-ci-to-your-frontend-with-github-actions-nuxtjs-case-study-4fle %}

I'm using it in a SPA created with VueCLI for a TV Shows list. I'm also using it in other projects that are coming soon.

Please feel free to check it, fork it and ask me anything, here is the repo:

{% github https://github.com/Dawntraoz/tv-shows-spa no-readme %}


### Submission Category: 

Maintainer Must-Haves


### Yaml File

```yaml
# Name your workflow
name: CI

# Set on which events you want run the actions.
# In this case the workflow will run on push for master and on pull request for master and develop branches
on:
  push:
    branches: [ master ]
  pull_request:
    branches: [ master, develop ]

jobs:
  integration:
    strategy:
      matrix:
        os: [ubuntu-latest, macos-latest, windows-latest]
        node: [12]
    runs-on: ${{ matrix.os }}
  
    steps:
      - name: Setup Node.js environment
        uses: actions/setup-node@v1.4.3
        with:
          node-version: ${{ matrix.node }}

      - name: Checkout master branch
        uses: actions/checkout@v2

      - name: Cache node_modules
        uses: actions/cache@v2.1.0
        with:
          path: node_modules
          key: ${{ matrix.os }}-node-v${{ matrix.node }}-deps-${{ hashFiles(format('{0}{1}', github.workspace, '/package-lock.json')) }}

      - name: Install dependencies
        if: steps.cache.outputs.cache-hit != 'true'
        run: npm install

      - name: Run ESLint
        run: npm run lint
        
      - name: Run unit tests
        run: npm run test:unit

      - name: Code coverage
        uses: codecov/codecov-action@v1.0.12
```
PYTHON- what TYPE of work do you do? if you don't do Data science or Machine Learning, what separates Python from others?
Tags: python, react, datascience, machinelearning
Published: 2020-08-29 11:12:15

I'm trying to figure out the "TYPE" of work to pursue with learning/pursuing Python. 
is the need/for python stable vs Javascript? I've been concentrating one Vue and React for a while, up I want to narrow down the type of work. From End is mainly styling.. that's ALWAYS CHANGING.
-
so far, I'm at 5 hours into a course and I like Py. Tkinter or KIVY interests me, but that's limited to desktop?
Leadership In Software Development And Leading Developers
Tags: leadership, software, development, management
Published: 2020-08-29 11:09:33

First, everyone in the software industry must admit. I see that software developers are human beings, just like everyone else. Therefore they have strengths and weaknesses. There is no one who is perfect in every way, so there will be certain aspects of their work where they perform poorly.

Their work is also not something that they do for free but instead requires compensation. A developer will need to be properly compensated for their time and effort in order to have a positive attitude towards the task.

If they are not being properly compensated for their time and effort, then it will negatively affect the quality of the work that they do. If a developer is unhappy with how they are being treated or underpaid in some way (or simply tired from working too many hours), this can cause them to quit or burnout.

Therefore, management and leadership is an important consideration. If a leader can provide incentives for his employees to work hard on tasks, as well as treating them fairly and providing the necessary infrastructure to support their work, then this will help ensure that the development process goes smoothly.

But if these things are not done, then there is a good chance that the development process will be negatively affected. This can result in crashes and broken code or other similar problems that affect the team and the entire company in the long term.

A good leader, a good manager should be able to provide good leadership, not like a boss, so as to ensure that the processes go smoothly. 

One of the most important things for leadership is to know when to listen. This is something that many people do not understand, especially concerning certain social roles such as a leader or someone in a higher position than others. A good leader will have great insight into how much input he/she needs from his followers and also how much he should give them. 

The trick is learning how to balance listening with giving your own opinion enough weight so that you can be effective but without being too overbearing on those around you.
Another important thing about leadership is to learn how much of an opinion you need to have and then when it needs to be expressed. 

If you are in a situation where everyone around you is new, or they do not know what the best approach is for completing a task, it may be your job as the leader or more experienced person on the team to make suggestions. 

However, if there is someone with greater experience than yourself who has already come up with a strategy that will work well enough, then your contribution should probably just be suggestions. Being a tough leader, in characteristically set high standards and, are competitive and professional executors.

In summary, leadership is a delicate thing. You need to constantly be aware of how much input you have and when it might be time to give in or step up.
Hello to all at Dev.to!
Published: 2020-08-29 10:58:47

Founder, developer and innovator at Texmith.

Assisted MSCI in saving 400 man hours by designing an automation system, which was then implemented by eClerx at the organisational level. 

Python and technology are my passion. Designing, building and implementing solutions is something that I have done since my teenage years. 

Pokemon Go was a newly launched game by Google & Niantic, during my teenage years. We had to walk miles to catch a single imaginary/virtual Pokémon, collect items etc. Being the lazy person that I was, to avoid walking to the United States to catch a rare Pokémon, I developed a simple hack using Python. This hack allowed my in-game character to walk a thousand miles a day and catch all the Pokémon, from the comfort of my bedroom. 

My passion for technology stems from the concept on which Python is built - “Simple is better”. 

My team and I assisted Intelak, an Emirates company, in redesigning and implementing a B2B focused User interface with a fluid and rich User experience. We have assisted Amazingworkplaces, an initiative by BrandRecall, during the early days of launch with their marketing and web based platform.

For many years now, we have designed and implemented solutions ranging from a simple Website to High Complexity Systems like a CRM, and E-commerce Web App, built complete IT ecosystems on AWS, Heroku etc.

Currently we are working to bring a Simple Email Marketing tool into the market. A simple tool to help assist in your daily needs of email marketing, lead generation, customer engagement and much more all under a simple and easy to use Interface.

Check out [Texmith](https://texmith.com)
OctoberCMS Media Manager Fix
Tags: octobercms, php, files
Published: 2020-08-29 02:28:41

---
title: OctoberCMS Media Manager Fix
published: true
description: A small plugin that might just save your life
tags: octobercms, php, files
//cover_image: https://direct_url_to_image.jpg
---
The web is a very particular at times and for us developers, there are things that go unspoken, some "golden rules" that are so obvious to us that we forget that sometimes, the other species who share the world with us, regular humans, will also interact with systems we develop.

Please, before you get all defensive (if you are a regular human) or big-headed (if you are a developer), both of us have qualities and flaws, we are not better than each other, we are just ... different.

Anyways - I should cut back on my coffee before writing. 

Developers all know the rule - files for the web should *never* contain spaces or special characters. Even though file systems have gone a long, long way since 'em good ol' days, where file names were 9 characters long. Nowadays, you could actually write a tweet and save it as a file name.
This flexibility has spread unevenly, with legacy systems interacting with modern systems, and the web, well, it's not a place for the faint of heart.

As developers, we should worry about file names and their compatibility. As users, our world peers also worry about filenames but in a different context, and that is when things go boom.

OctoberCMS is a beautiful little piece of software for any PHP developer (if you don't know it - I urge you to have a look)[http://octobercms.com]
I love it and use it for pretty much anything I can. From internal little projects to huge projects serving content to  ~25K concurrent users, I've done it all, yet, one small oversight on my behalf cost me a sleepless weekend of troubles. 

I decided to use October's built-in Media Manager to handle all my CMS related images. All was fine during testing phases, but, when we put the system online, and actual regular humans started feeding the, literally hundreds of thousands of images into the system we started facing a series of issues with special characters and spaces in filenames causing all sorts of glitches on our client's site.

After some digging and a lot of pain, sweat, and tears, I eventually wrote a little script that would rename the existing files in the system.

It was then that I decided that I needed to avoid this happening again and that I would write some code I could use in my next projects to mitigate this issue. Rather than having a personal library script, I wrote out a small plugin you can add to your OctoberCMS installation that will rename the files you upload to your media manager, to a web-friendly name.

There are still a few little options I'd like to add to the plugin, but, none of them will be breaking changes. Feel free to give it a test-drive and leave me a comment if you have any suggestions, criticism or what not.

The link for the plugin is here:
https://octobercms.com/plugin/gregorybrown-mediamanagerfix
What to Do When You Accidentally Drop a Database in a Docker Environment
Tags: docker, django
Published: 2020-08-29 10:18:59

Today I accidentally dropped the mysql table `django_admin_log` in my docker + django environment. I both have django and mysql running in the docker container.

First, I used the following command.

```
docker-compose run --rm api python timeline/manage.py sqlmigrate admin 0001

CREATE TABLE `django_admin_log` (`id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY, `action_time` datetime(6) NOT NULL, `object_id` longtext NULL, `object_repr` varchar(200) NOT NULL, `action_flag` smallint UNSIGNED NOT NULL, `change_message` longtext NOT NULL, `content_type_id` integer NULL, `user_id` integer NOT NULL);
```

Although the message above indicates that it has created the table, I did not see any difference in my database server.
So after copying the sql sentence above, I entered the mysql container, and booted up mysql.
Inside mysql, I pasted the message from above.

```
$ docker exec -it db-container /bin/bash
# mysql
> CREATE TABLE `django_admin_log` (`id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY, `action_time` datetime(6) NOT NULL, `object_id` longtext NULL, `object_repr` varchar(200) NOT NULL, `action_flag` smallint UNSIGNED NOT NULL, `change_message` longtext NOT NULL, `content_type_id` integer NULL, `user_id` integer NOT NULL);
``` 

This recreated the table in my database server.
Spark Side Menu Micro-Interactions Deconstruction
Tags: microinteraction, email, spark, frontend
Published: 2020-08-29 10:14:25

Designing an interface that people will use on a daily basis, or even multiple times a day throughout the week can be overwhelming for any UI designer. Depending on the business you're in or the number of newsletters you're subscribed to, you are probably dealing with your mail client app from 5 to ∞ times a day. Imagine the level of responsibility for a UI/UX designer when determining the various ways for users to interact with it. 

In this article, I will deconstruct the "open side menu" interaction and all those micro-interactions happening while the user is trying to navigate to the desired destination.

{% vimeo 452872720 %}

**1. The scroll bar is immediately visible**

When I tapped the Menu icon, the side menu opened. While opening, even before I scrolled or did any interaction, the scroll bar was visible, giving me the hint that there is some content under the visible area. 


**2. Settings link is locked to the bottom of the menu**

When opening the side menu, except from expecting to find the navigation links there, in many cases you are also looking for some extra options to adjust your interface. Since there could be many e-mail accounts added, hence multiple links for any of them, Spark designers recognized the user need to have the Settings link always available and visible. They locked it on the bottom of the drawer. 


**3. Drop-down menus for accounts and folders have different behavior**

I have identified two types of different behaviors of the drop-down menu: 
- the first one is when the folder of a specific e-mail account is clicked. In that case movement of the drop-down is toward the bottom. 
- the second one is when the account is clicked. In that case, the name of the e-mail account is going toward the top, so that all the folders inside of it can be visible, and not hidden. That way no additional scrolling is needed. 


🙌 Fun little things if you deconstruct and analyze them. Great initiative from the Spark designers and front-end developers to recognize and implement useful micro-interactions important for frequent user actions.
Convenient Python Library for importing modules
Tags: python, library, pip, coding
Published: 2020-08-29 10:02:57

I released the Python library which is named [autoload_module](https://github.com/hiroki0525/autoload_module).
It will be more comfortable to your Python programming.

## What is the library?
[This library](https://github.com/hiroki0525/autoload_module) is enable to automatically import modules and get class objects. The example is below.

* Directory
```
project/
 ├ example.py
 └ validator/
   ├ validator_a.py
   ├ validator_b.py
   └ validator_c.py
```
* validator_a.py
```python
class ValidatorA:
    # b and c are same.
    def valildate(self, input):
        # process of validation
```
* example.py
```python
from autoload.module_loader import ModuleLoader

input = "foo bar baz"
loader = ModuleLoader()

# Automatically import modules and return class objects
validator_classes = loader.load_classes("validator")
try:
    # initialize and execute method
    [clazz().validate(input) for clazz in validator_classes]
except:
    print("input is invalid!!")
```

You can also get function objects.
```python
# This is the example you defined not classes but functions like 'validate_A', 'validate_B' and 'validate_C'
validate_functions = loader.load_functions("validator")
[func(input) for func in validate_functions]
```

## What is useful?
It will be useful to do something in bulk.
The following is assumed as a concrete usage example.

* validation
* pipeline

The example of pipeline is below.
* Directory
```
project/
 ├ example.py
 └ pipelineA/
   ├ get_data_a.py
   └ processing_data_a.py
 └ pipelineB/
   ├ get_data_b.py
   └ processing_data_b.py
```
* example.py
```python
from autoload.module_loader import ModuleLoader

package_names = ("pipelineA", "pipelineB")
loader = ModuleLoader()

# You should use library like `concurrent.futures`
for package_name in package_names:
    GetData, ProcessingData = loader.load_classes(package_name)
    data = GetData().get()
    processed_data = ProcessingData().process(data)
```
## Hot to use
Please read [this](https://github.com/hiroki0525/autoload_module).

## Conclusion
[This library](https://github.com/hiroki0525/autoload_module) give automatically importing modules.
I welcome your contribution!
Implemented Auto Responder
Tags: saas
Published: 2020-08-29 09:56:01

Somehow couldn't bring myself to create a follow up sequence for TeraCrawler.
Finally I did it. I implemented auto responder for both my SAAS company TeraCrawler(https://teracrawler.io/) and Proxies API(https://www.proxiesapi.com/) so good riddance.
Product Video Ready
Tags: saas
Published: 2020-08-29 09:47:42

Just finished making a product video for my new side project EdgeNet. Product video here. Here is the context for the product EdgeNet is going to be a SAAS service that converts your website into a static one and deploys it on a world wide CDN automatically. It also detects content changes and automatically syncs it. I am developing this because I needed a way to increase the page speed for many of my websites but wanted to retain the control that a CRM gives me. Does this video convey that? Does it show how easy and fast it is to create a new static website and keep it updated?