teleren/devto huggingface dataset:
[PT-BR] Conhecendo o DBeaver
Tags: database, dba, administrator
Published: 2020-01-24 11:50:50

Recentemente eu comecei a trabalhar com infra e desenvolvimento, e aqui existem dois sistemas que usam databases diferentes. Eu costumava a usar o HeidiSQL, mas como estava com problemas para realizar as conexões, uma amiga me recomendou o DBeaver, que foi paixão a primeira vista.

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/e8mbu9fj74hjntyt8lhh.png)

##**Mais sobre o DBeaver**##

O DBeaver é uma ferramenta universal para banco de dados. Isso significa que ele nos dá a possibilidade de manipular vários SGBDs, como Oracle, Postgres, MySQL, e daí em diante. A lista de todos os bancos de dados suportados, está [aqui](https://dbeaver.com/databases/).

Se você curte a IDE Eclipse, saiba que a ferramenta é baseada nela.

##**Conexões**##

Nós que trabalhamos com infra, em variadas situações precisamos nos conectar em vários bancos de dados, e isso pode ser um problema. Para nos ajudar com isso, a ferramenta tem um bom gerenciador interno. Além de guardar os dados das suas conexões. Ele também trata de conexões que envolvem túneis SSH.

##**Visualizar dados e Edição**##

O DBeaver tem um visualizador simples, porém possui várias coisas úteis, como ordenar os dados direto da tabela, filtrar elementos e exportá-los em pdf, texto, csv e excel. No DBeaver também temos a possibilidade de gerar diagramas automaticamente e depois exportá-los em GIF, PNG, BMP e GraphML.

##**Não posso deixar de lado, o tão querido modo dark**##

No DBeaver é possível fazer a escolha de temas, Dark do Mac, Dark do Linux ou apenas o Dark. Para isso, na barra de ferramentas clique em *Window > Preferences > Appearance* e escolha o tema desejado.

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/hq4elnmxox2k5b35hw67.png)

No mais, é isso aí gente. Até a próxima!
Downloading Anything Off the Internet Without Searching It.
Tags: linux, rssfeed, automation, noobie
Published: 2020-01-24 11:41:44

### This setup helps you download anything off the internet without even searching for it.

I was just amused by this automation and found it to my utmost satisfaction and 

We're gonna setup our SABnzbd++ to download webseries and its upcoming episodes without user interaction. Hence Automating the whole process of searching and downloading.

## Setup SABnzbd
```
$ sudo apt-get install software-properties-common

$ sudo add-apt-repository multiverse

$ sudo add-apt-repository universe

$ sudo add-apt-repository ppa:jcfp/nobetas

$ sudo add-apt-repository ppa:jcfp/sab-addons

$ sudo apt-get update && sudo apt-get dist-upgrade

$ sudo apt-get install sabnzbdplus python-sabyenc

$ sudo apt-get install par2-tbb
```


### Start SABNzbdplus with 
`$ sabnzbdplus`

### Or open a localhost instance
from http://localhost:8080

## Let's make ourselves a free account

- Vist here https://free-usenet.com/login/

Go to Free Account tab and copy the credentials and use them to login to [http://localhost:8080](http://localhost:8080)
After Logging in,
 - click _Config_. Beneath _Config_, click _General_. First you'll find the configuration for the SABnzbd web server. Set bandwidth limit to 1Mbps
 - In the last config sub-category, _Sorting_, you can do some pretty neat things with the organization of your downloads. There are a couple of sorting options, You can use this to sort episodes however you'd like. Here's one example:

> Sort string:  
> %sn - Episode %s%0e - %en.%ext
> 
> Output:  
> Show Name - Episode 105 - Episode Name.avi

Now that you've set up SAB, it's time to give it something to download. SAB downloads and processes files via NZBs.

**Head over to
https://www.nzbindex.com/search**

We'll find RSS feed of our favorite series, movies or any packages that we need to download.

 1. Search for any show or webseries
 2. Click on the RSS Feed option, you'll be redirected to a new tab containing XML version 
 3. Copy the URL of the new tab and headover to your [http://localhost:8080](http://localhost:8080) and add a new RSS url with the url you copied
 4. Leave and Enjoy
Types of Software Testing and Their Impact on Your Product Quality
Tags: testing, qa, typesoftesting, softwaretesting
Published: 2020-01-24 11:39:05

Most of you may probably know what software testing is and why it’s so important. But what about the exact types of testing which are a must for a successful product release? 
https://medium.com/@HireTester/types-of-software-testing-and-their-impact-on-your-product-quality-ef45f1d3230a
Tools for Automated API Testing. Our Experience
Tags: softwaretesting, qa, apitesting, tools
Published: 2020-01-24 11:37:19

Postman, Katalon Studio or REST Assured: which one to choose?

Being great tools for automated API testing, they, however, still have certain drawbacks and merits. Let’s see when and in what situations they can best fit your testing expectations.

https://www.linkedin.com/pulse/tools-automated-api-testing-our-experience-alex-khobotnya/
From a beginner to a beginner: where to begin?
Tags: beginners, codenewbie, webdev, inspiration
Published: 2020-01-24 11:17:52

By definition, a “beginner” needs somewhere to “begin”.  But with an overwhelming amount of examples projects and tutorials online and all the possible ideas in your mind, the starting point can become blurry.

Truth is, there is none. Programming is a vast land: multiple intertwined roads, obstacles, grey areas and promising destinations fill its map but no one has drawn a point of entry. Luckily, it doesn’t matter where you enter - it only matters that you do!

With that being said, drawing your own map can help you navigate the complex environment. There is a list of resources to draw from; narrow down the selection of possible languages and development tools by looking under the hood of something you want to do. Then narrow down the level of complexity by lowering the standards of the hood you’re looking under. I.E. if you want to build a game from scratch, begin with a 2D flash game before producing the next great VR hit.  However, I suggest you aim high with your destination or you might quickly run out of challenges. 

After you’ve taken a peek at the “engine” under the hood, try to reverse engineer it. There are several example projects that can help you do this, but first ask yourself why the developer has built a certain feature. Once you have your answer, ask yourself _how_ they did it.
If you don’t know what you want to do at all, then ask yourself why do you want to become a programmer in the first place? This isn’t a mocking question, but a question with an answer that’s likely taking you a step closer to finding what you need to learn.

“You learn to swim quickly after dipping your toes into water… yet jumping into the deep end of a pool can drown you.”

The quote above sounded better before I wrote it down. Similarly, the idea for my first development project sounded better before writing it in code. Point is, I still wrote it and I can learn something from doing so.

Here’s a few suggestions If you still struggle to find something to do:

* Search for beginner tutorials
* Enroll in an online code academy
* Find a coding group near you
* Read a book on entry level programming
* Spend time on this site

Every step is a step forward. 

Keep on,
Mikael
Free Google Tools Should Use | Ameya eMarketing
Published: 2020-01-24 11:03:11

Google offers a lot of free tools to use with the comfort of having the option to get to them with one login.

Let's see Free Google <a href="https://www.ameyamarketing.com/services/search-engine-optimization/" target="_blank">SEO</a> Tools Should Use.<br /> Tools Should Use.

<b>1. Google My Business</b>

Google My Business is a free and simple to-use tool for businesses and organizations to deal with their online presence across Google, including Search and Maps. In the event that you check and alter your business data, you can both assist clients with finding your business and disclose to them your story.
<b>Benefits of Google My Business</b>
Manage your information
Interact with customers
Understand and expand your presence

<b>2. Google Ads Express</b>
Adwords Express is an essential <a href="https://www.ameyamarketing.com/services/ppc/" target="_blank">Google Ads</a> administration that is intended for publicists who don't feel certain crunching every one of the numbers and tinkering with the different settings related with a customary Google Ads (or Adwords) account.

Get before clients when they're looking for organizations like yours on Google Search and Maps. Pay for results, similar to snaps to your site or calls to your business.
<b>3. Google AdSense</b>
Google AdSense gives an approach to publishers to earn money from their online substance. AdSense works by coordinating promotions to your site dependent on your substance and guests. The advertisements are made and paid for by publicists who need to advance their items. Since these sponsors follow through on various costs for various promotions, the sum that you gain will change.

<b>AdSense in three steps</b>

You make your advertisement spaces accessible by sticking the promotion code on your site, and picking where you need the advertisements to show up.

Advertisers offer to be shown in your promotion spaces in a continuous closeout. The most lucrative promotions appear on your site.

Google handles the way toward charging all sponsors and systems for the advertisements on your site, to ensure that you get your installments.
Python - Object and Variable Difference
Tags: python, beginners, opensource, oop
Published: 2020-01-24 10:39:43

__Let's quickly resolve confusion surrounding an Object and a Variable :__

Let's say you've a list as - 
```python
fruits = ['apple','orange','grape']
```
When such a list is created, the *__fruits is a variable__* holding the location of memory where the list exists.

The location can be checked with the help of the following function:
```python
id(fruits)
```
Now when you try to update the list as:
```python
fruits = ['mango','banana','Tomato']
```
(It's no typo, Tomato is actually a fruit)

You think that you've updated the earlier existing list with new values, but instead you've have actually created a new python object altogether and it's memory location is fed to the variable fruits.

This can be verified by checking -
```python
id(fruits)
```
Clearly there would be stark contrast between the memory value obtained previously and the latest one.

If no other variable is now referring to the older list, then python's garbage collector will auto-delete it from memory.

Now if you really want to update the list with fresh values, then use the following code instead : 
```python
fruits.clear()  #It clears all elements from the existing list
fruits.extend(['mango','banana','Tomato']) #populates list with new elements
```

Hope this was helpful for you!
Connecting Gridsome to NetlifyCMS - Step by step tutorial
Tags: vue, javascript, webdev, opensource
Published: 2020-01-24 10:23:12

For the last past months, I have been searching for a **Headless CMS** to connect with a modern Javascript framework like **Vue.js** to use for my clients.

After a long search, I found the perfect combination for my needs thanks to a **static site generator** like [Gridsome](https://gridsome.org/) and a **headless CMS** like [NetlifyCMS](https://www.netlifycms.org/).

**Static site generators** have become very popular because they are straightforward to use, and they are based on **JavaScript frameworks** like **Vue.js or React**.


**Headless CMS** make easy to access content via RESTful API.


These create a new architectural concept also called **JAMstack**, which I talk about more in [this article](https://medium.com/notonlycss/why-the-jamstack-is-becoming-so-popular-a26133b12a30), I recommend you read it to be able to better understand the topic we’re going to deal with today.


Today we will use the **JAMstack** architecture by connecting **Gridsome** to **NetlifyCMS**.

## What are we going to develop?

We will develop a simple blog with a list of articles and the specific page of the article, to show the basic functions and how to connect the two technologies **step by step**.

Then it’s up to you to discover all the features.

By following this tutorial you will be able to create your CMS with these technologies in **9 steps**.

Check out the tutorial on Medium 👇

{% medium https://medium.com/notonlycss/connecting-gridsome-to-netlifycms-823fea90c93c %}

_Ps. If you are not happy that the tutorial is on Medium, nobody forces you to read it.
Peace and love_  ✌️❤️
Installing GitHub repos or Gists directly as npm packages
Tags: npm, install, github, gist
Published: 2020-01-24 10:07:37

This is something that came across in our project that we think it's pretty useful. And despite now having the ability to host your own `npm` packages on the [Github package Registry](https://help.github.com/en/github/managing-packages-with-github-packages/about-github-packages); some people might find this helpful, even if the repo itself didn't mean to be an `npm` isntallable module.

## Install from a GitHub Repository

```
> npm install <githubname>/<githubrepo>
```

That's the basic syntax, although you might want to use the explicit version:


```
> npm install github:<githubname>/<githubrepo>
```

BTW, this works with private repos too! Also does [Github Package Registry](https://help.github.com/en/github/managing-packages-with-github-packages/about-github-packages) ones. But it is possible that you will be prompted with the Git Credentials Manager to put your user/pass in order to continue.

### Specify a version to install

The good part, is that you can also specify versions (using **semver**), as in every `npm` package. And update them afterwards accordingly.


```
> npm i github:<githubname>/<githubrepo>[#semver:<semver>]
# Example:
> npm i github:lodash/lodash#semver:4.17.15
```

And another cool thing about this github option is that `npm` allows you to specify specific **commits** too!

```
> npm i github:lodash/lodash#ddfd9b1 
```

It will use the main branch in the respository, by default; usually `master`.


## Installing from a gist directly

"Installing from a gist?" You might say. Sometimes it's useful to have little snippets that aren't as important as to make an npm package out of them in [Github Gists](gist.github.com).

Take a look this example: https://gist.github.com/gangsthub/0bce1161cfd2aa91ae7cad9abb42c342

{% gist https://gist.github.com/gangsthub/0bce1161cfd2aa91ae7cad9abb42c342 %} 

If they have a `package.json` properly configured, you can install them.

You can then do:

```
> npm i gist:0bce1161cfd2aa91ae7cad9abb42c342
```

Note, the hash is the id of the gist, also used in the URL.



That's it! Also it's my first published post on Dev.to! Make sure to:

❤ 😜
big brother is here ! 
Tags: watercooler
Published: 2020-01-24 09:43:25

On the same day we find out the [NYPD is spending $10M on hacking iphones](https://www.dailymail.co.uk/sciencetech/article-7921707/NYPD-running-10million-forensics-lab-dedicated-cracking-iPhones.html) 

FB's instagram AI is telling me that goog photo app AI has created a pirate video !

AND why is goog stripping all audio and truncating this 1:18 video PUBLICLY to 0:03 seconds ?

https://photos.app.goo.gl/cfPTf24EPwFtaykX6

{% twitter 1220633334512005120 %}
{% twitter 1220633831914594304 %}
Having trouble😫 with VS code💻 formatOnSave lately?
Tags: vscode, tutorial, todayilearned
Published: 2020-01-24 09:31:57

If you are like me, then you like your tools.

One of the most important tools in a coder's workflow is automation & I really like automating repetitive tasks like code formatting & linting. 

With the availability of extensions like **eslint** for VS code, setting it up is as simple as installing the extension and maintaining a **.eslintrc.js** file in the repo. 

But lately, I have been facing some issues with the **formatOnSave** in VS code. My code seemed to behave weird like it was getting formatted and getting un-formatted on every save:

![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/i9amalnof1hhp6txsx5y.gif)

I had to do some research around it and got to the bottom of it. It was related to this settings migration by VS code: https://github.com/microsoft/vscode-eslint#settings-migration

The solution to fix it was simple:
![Alt Text](https://thepracticaldev.s3.amazonaws.com/i/iwjighbohqyu7d90lk6c.png)

From the vs code settings *(which you can open by doing cmd+, or opening settings.json)*, remove the line number 88 and add line numbers 89-92. Doing that will successfully migrate you to the new settings. 

Hope that saved you from an afternoon of headache.

Cheers!
My Top Ten VS Code Plugins
Tags: javascript, vscode, web
Published: 2020-01-24 09:30:39

---
title: My Top Ten VS Code Plugins
published: true
description: My Top Ten VS Code Plugins
tags: JavaScript, VS Code, Web
---

## #1 — Peacock

![](https://cdn-images-1.medium.com/max/8534/1*WwbBEwh-NXEZOFh-XxUmBQ.jpeg)

## #2 — Bracket Pair Colorizer 2

![](https://cdn-images-1.medium.com/max/8534/1*8WJv4vmvY-sK0Dg4W1wceg.jpeg)

## #3 — Material Theme

![](https://cdn-images-1.medium.com/max/8534/1*I2VDi1XmBzTRhu_rex0_rA.jpeg)

## #4 — GitLens

![](https://cdn-images-1.medium.com/max/8534/1*0eETh-Arjp2hPDB17_9kWw.jpeg)

## #5 — Auto Close Tag

![](https://cdn-images-1.medium.com/max/8534/1*9yTHnI4RpIPHvKqvD7yciQ.jpeg)

## #6 — Better Comments

![](https://cdn-images-1.medium.com/max/8534/1*WMzfi-fDnQ-1a7zE4BhHBA.jpeg)

## #7 —Import Cost

![](https://cdn-images-1.medium.com/max/8534/1*obq-fMXcgIGOWPpZdTUdDQ.jpeg)

## #8— Debugger for Chrome

![](https://cdn-images-1.medium.com/max/8534/1*Wxe5gtfoKGlElsDXTD-p4A.jpeg)

## #9 — Turbo Console Log

![](https://cdn-images-1.medium.com/max/8534/1*WFZuq9_q9kLcOfIeVVZJsg.jpeg)

## #10 — Prettier

![](https://cdn-images-1.medium.com/max/2048/1*ur7nfBmepIoGo0xAzvFYrw.png)
RapidAPI extends offer for GraphQL APIs
Tags: graphql, showdev, webdev, productivity
Published: 2020-01-24 09:19:29

---
title: RapidAPI extends offer for GraphQL APIs
published: true
description: RapidAPI is the world’s largest API Marketplace & they just announced support for GraphQL APIs
tags: graphql,showdev,webdev,productivity
cover_image: https://thepracticaldev.s3.amazonaws.com/i/a5387huyxp1gm905v54c.png
canonical_url: https://blog.graphqleditor.com/rapidapi-graphql/
---


**[RapidAPI](https://rapidapi.com/) is the world’s largest API Marketplace** that helps developers find and connect to thousands of APIs.

RapidAPI was founded in 2014 by Iddo Gino and after two years on the market raised $3.5 million, then to grab a stunning amount of **$38 million in The Series B** (including $25 million from Microsoft).

Yesterday RapidAPI **announced support for GraphQL APIs** to its and has published the first batch of them. Right now the platform offers just a few GraphQL-based APIs including GitHub, GitLab, Yelp, Reddit or Hacer News, with a lot more coming soon.
![RapidAPI support GraphQL](https://thepracticaldev.s3.amazonaws.com/i/fe3s7g79tdayjbuxuwga.png)
RapidAPI deciding to provide its marketplace users a choice between native GraphQL and REST API is a very clear signal that that GraphQL's market position is on a rise and will play an important role in the future of APIs.

[![GraphQL APIs avaiable on RapidAPI](https://thepracticaldev.s3.amazonaws.com/i/q6odvzifd9387e469fyu.png)](https://rapidapi.com/search/graphql)

Developers using RapidAPI will get access to **GraphQL-native experience** allowing them to explore schema, develop, build & test their queries along with the same benefits known for RapidAPI users from its REST API experience:

- Publishing APIs via introspection or by uploading a schema file for easier onboarding,

- Interactive automatically generated docs enabling users testing the API right from a browser,

- Code snippets for easier integration with all the API provider’s applications,

- API management tools enabling to monitor performance metrics and data usage

![RapidAPI](https://thepracticaldev.s3.amazonaws.com/i/tsxb05kqswvyffgyjr4l.png)

---

## Speed up your GraphQL API development

[**GraphQL Editor**](https://graphqleditor.com/) is a supportive tool for both advanced **GraphQL users** as well as those taking their first steps with GraphQL APIs. Our all-in-one development environment for GraphQL will help you build, manage & deploy your **GraphQL API** much faster thanks to dozens of built-in micro features.

[![GraphQL Editor](https://thepracticaldev.s3.amazonaws.com/i/835ac1nun474qfgn1tfi.gif)](https://graphqleditor.com)
Jestip, clear mocks automatically
Tags: jest
Published: 2020-01-24 08:59:51

---
title: Jestip, clear mocks automatically
published: true
description: How to clear mocks without the clearAllMocks function
cover_image: https://thepracticaldev.s3.amazonaws.com/i/91mq6tpua5op66kj38l8.jpg
canonical_url: https://maximeblanc.fr/blog/jestip-clear-mocks-automatically
tags: jest
---

Let's take the following code as example.

```js
function functionYouNeedToMock(a, b) {
  return a + b
}

beforeEach(() => {
  jest.clearAllMocks()
})

functionYouNeedToMock = jest.fn()

it("should call function", () => {
  functionYouNeedToMock()
  expect(functionYouNeedToMock).toBeCalledTimes(1)
})

it("should call function", () => {
  functionYouNeedToMock()
  expect(functionYouNeedToMock).toBeCalledTimes(1)
})
```

It considers that you mocked a function and you want your tests to be independent. So you're using the `jest.clearAllMocks()` function to avoid undesired behaviours.

Did you know that you can activate the `clearMocks` option in the config in order to avoid calling `jest.clearAllMocks()` in each test suite ?

```js
// jest.config.js

module.exports = {
  clearMocks: true,
}
```

Now you can write

```js
function functionYouNeedToMock(a, b) {
  return a + b
}

functionYouNeedToMock = jest.fn()

it("should call function", () => {
  functionYouNeedToMock()
  expect(functionYouNeedToMock).toBeCalledTimes(1)
})

it("should call function", () => {
  functionYouNeedToMock()
  expect(functionYouNeedToMock).toBeCalledTimes(1)
})
```

Thanks for reading
Collab Lab Week 6 - A wild infinite loop
Tags: collablab
Published: 2020-01-24 08:27:59

Apparently, this has happened in every cohort so far but I had the distinction of pushing code that caused us to hit the daily read limit on Firestore. 

![box of shame](https://media.giphy.com/media/d7fTn7iSd2ivS/giphy.gif)

I am grateful for every mistake and difficulty I've faced as part of this team. I felt bad for making the team wait to access our data but other than a little waiting, no one was hurt. I didn't cost anyone a lot of money with my mistake.

I keep saying this, and I'll continue to say it. These are the great conditions for making mistakes and learning from them. It's real enough that I care about the job I'm doing, but there's a safety net. No mistake I make will be catastrophic.

I will relive my shame and share the offending code. Maybe I'll save someone else from the same kind of error. Can you spot the issue? 

{% gist https://gist.github.com/prophen/124c63cb285d00475091afebe1f4732c  %}

The useEffect block was the offender and wasn't needed at all. I was refactoring the code using a hook our mentor Steve provided and failed to notice the infinite fetching of the Firebase data. At some point, there were all these different state variables passing the token around between the app and localStorage. I'm much happier with how the token works now. There is one source of truth. 

I swear I'm not doing it on purpose, but I do appreciate all the learning by mistakes I'm getting in with The Collab Lab. Everything about this has been a stretch and a learning experience. 

As great as everything is, there is a downside. No one gets paid for doing this (our mentors are volunteers🙏🏾) and it feels like work. At the end of eight weeks (maybe nine?) I will have learned a lot, grown as a developer, and leave with better communication skills than I came in with. I will also be happy that a good thing has come to an end.

<a href="https://www.buymeacoffee.com/nikema" target="_blank"><img src="https://cdn.buymeacoffee.com/buttons/default-orange.png" alt="Buy Me A Coffee" width="150px"></a>