When transpiling TypeScript you could get the error:

error TS2585: Promise only refers to a type, but is being used as a var here. Do you need to change your target library? Try changing the 'lib' compiler option to es2015 or later.

It's an interesting scenario, since the code below shouldn't be throwing errors.

It's a commom TypeScript error and in most of the cases it should be solved in two ways:

npm instal@types/node

After that, magically the error has disapeared!


Photo by James Yarema on Unsplash

I assume if you're here you are trying to learn or to remember how to do something, so, the golden rule before you proceed is: do a backup.

If you're not familiar with some Git concepts it's really very easy to mess up with thing and lose work. We don't want that!

In your terminal, because I know you have one, type the line below:

cp -r <current_dir> <backup_dir>

Now let's create a new branch:

git checkout -b <name_of_your_branch>

Awesome! Now the usual process you used to do. Let's add the files to stage:

git add .

And finally, let's…


For those who don't know, Behave is a powerful tool to write BDD automated tests with Python.

In PyCharm Professional you are able to debug Behave out of the box, but of course it's a paid tool. And it's an expensive tool.

But fear not, because it’s possible to use PyCharm CE’s debugger and Behave with just a couple of settings.

What's the benefit of using a debugger in you workflow? There's a lot of reasons to do so but to name a few: breakpoints and expressions evaluators.

Let's give a shot with PyCharm CE dubugging tool

Setting up PyCharm CE debugger to run Behave

2. Specify…


This tutorial applies to all distros which use PulseAudio.

It’s no secret that Linux Desktops are powerful and customizable tools. But sometimes you have to dive a little deeper to achieve the level of productivity you want.

In some Linux Distros, at this moment there’s no straightforward method to set a default audio device using a GUI. But we can deal with that easily through a single configuration file. That’s nice!

Enough talk, open the terminal and let’s rock.

Step one

List all available devices:

pacmd list-cards

Identify the device and the profile you’re searching for and save it to a text…


Love it or hate it, if you’re a web developer, chances are big that sooner or later you’ll have to handle a Wordpress project. Probably you already have had to.

Photo by Alain Pham on Unsplash

One of the features WP has out of the box is the ability to organize your posts in categories. But sometimes you need to impose your own kind of content hierarchy.

How to remove Wordpress category base prefix without plugins?

Let’s imagine you need an url structure like “news/category-name/” to show posts by given category. Using the out of the box feature will do the job perfectly.

Now let’s supose you have to deal with a multi language website


Interviews are still the focal point to connect professionals and companies. But those are hardly optimised to spot the best developers.

Photo by Anthony Martino on Unsplash

Most of hiring processes still uses the same questions and the same methods of decades ago. And of course it’s possible to hack them all. Actually people are doing this every day. For example: 99% of interviews will have the question “Tell me about yourself”.

I’m not advocating interviews shouldn’t ask you such a question, but the way it’s being done. …


Flask is a well known Python Micro Framework. One can say Python is an easy language to learn and I would say maybe. It depends on what you want to do.

Photo by Louis Reed on Unsplash

I wouldn't say Python is easy to debug for a beginner. Neither easy to setup if you are not familiar with some basic concepts, most of all from *nix realm.

I'll bring here quick tips to aid the beginner in the process of Dockerising a Flask Application.

Why Flask?

Flask is a Micro Framework written in Python, extremely flexible, with low footprint and lightweight.

BEFORE WE BEGIN — A BIG disclaimer…


WordPress is a wonderful tool, there’s no doubt about that. As estimated by Who is Hosting this, WordPress takes a slice of 20% of all web today. It's an incredible mark of 75.000.000 websites running WP as you read this article. To me is pretty impressive. Specially if you think about the huge number of websites misconfigured, vulnerable and miserably sluggish and slow. But it doesn’t need to be that way. We all want more speed, right? There we go!

Credits and image licensing

First things first. I need to tell you that this article is intended for coders. If you’re not a developer…


Weird, strange or annoying errors are part of our lives as miserable developers we are. :)

To all of you beginners in the black art, I'll share a quick antidote for this curse.

Most of cases are related to a bad Node installation or maybe related to the modules your [wrongly] are copying and pasting from another project.

So, to solve this issue all you have to do is:


Is it possible to alter your data structure without losing any data?

Yes, you can! And it's pretty straightforward.

Credits and image licensing

As stated in Laravel manual:

To rename a column, you may use the renameColumn method on the Schema builder. Before renaming a column, be sure to add the doctrine/dbal dependency to your composer.json file:

Schema::table('users', function (Blueprint $table) {
$table->renameColumn('from', 'to');
});

You can do this following a few steps:

1) Check if you have the Doctrine DBAL library installed.
If you don’t know how to do this, just check at your composer.json file.
There should be a line like “doctrine/dbal”: “v2.4.2”

Gabriel Guerra

FullStack Developer

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store