teleren/devto huggingface dataset:
Day 003 and the site begins
Tags: 100daysofcode, womenintech, webdev, html
Published: 2020-08-01 22:38:25

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/1e9zst9aesfwxokwlp57.PNG)

Hoje eu acordei ligeiramente mais disposta do que ontem e só isso já fez toda a diferença. Não recordo se comentei nos dias anteriores, mas, este início está sendo basicamente uma revisão para mim, com isso estou aproveitando para estudar as coisas mais profundamente.
Dito isso, essa metodologia de só ler e anotar, mesmo que só por dois dias **não estava dando certo para mim**. Acredito que no meu caso em específico eu:
* Fico entediada deveras rápido com questões sendo tratadas apenas como conceituais.
*Acho mais divertido por a mão na massa.

Que foi basicamente o que eu fiz hoje. Juntei minhas anotações, fui para frente do meu computador e usei minha uma hora de estudo para fazer a produção inicial do meu site. 
Estou fazendo upload no github e usando o github pages para a hospedagem do site já que se trata de um site pessoal e também acredito que fica mais fácil de acompanhar o meu progresso.
A imagem nessa postagem, foi o que eu consegui desenvolver hoje e caso alguém queira ver o site em sim: 
* https://sarah-rfs.github.io/

Obrigada a todxs <3
Manejando peticiones http desde Nodejs sin Express.
Tags: node, javascript
Published: 2020-08-01 22:15:35

Hace unos días tuve la necesidad de comprender como [Expressjs](https://expressjs.com/) maneja las peticiones http. Leyendo la documentación de [Nodejs](https://nodejs.org/es/docs/) y algunos otros blogs en inglés pude encontrar la forma de hacerlo con dos módulos:

- [http](https://nodejs.org/api/http.html)
- [url](https://nodejs.org/api/http.html)

```
const http = require('http');
const url = require('url');

http.createServer((req, res) => {

    let path = url.parse(req.url, true);
    if(path.pathname === '/api/ver/json'){
        res.setHeader('content-type', 'application/json');
        res.write(JSON.stringify([{
            "Testeando json": "Este es un json",
            "numero" : 245
        }]))
    }

    else if(path.pathname === '/api/crear/usuario'){
        let usuarios = new Array();
        res.setHeader('content-type', 'application/json');
        usuarios.push(JSON.stringify(path.query.nombre));
        console.log(usuarios);
    }

    else if(path.pathname === '/pagina'){
        res.write('<h1>Esta es mi pagina web</h1>');
    }

    res.end();
}).listen(3000, () => {
    console.log('Funcionando en puerto 3000');
})
```

Creamos nuestro servidor con http e inicializamos el módulo url para poder manipular todos los componentes de nuestra url por separado, pueden encontrar mucha mas información sobre el paquete en la documentación de Node.

```
let path = url.parse(req.url, true);
```
Con url.parse le decimos al módulo que queremos manipular las url de las peticiones, luego de esto configuramos unas rutas básicas para filtar las url / y poder devolver y/o recibir la información que queramos.

En el primer caso creamos una api estática que va a mostrar un Json muy simple, cada vez que entren a /api/ver/json esos datos van a estar disponibles.

Ahora se viene lo interesante, cuando enviemos una petición a /api/crear/usuario vamos a obtener los datos del usuario, ya sea por GET o por POST, esto lo podemos hacer porque que al parsear la url accedemos a las queries enviadas por el usuario.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/wgpjxwz8g9n9g7no9zij.png)

Esto es recomendable solo para experimentar y tratar de entender que hacen los frameworks por atrás. 

Espero que sea de su agrado :)
What made you interested in learning how to write tests or how to TDD?
Tags: testing, career, discuss
Published: 2020-08-01 21:57:56

I got interested in learning how to TDD and how to write tests because I wanted to improve my overall skills as a developer. 

I had this idea that there are too many technologies, and they change so fast that I can't learn all of them in-depth, so my countermeasure was to improve my testing skills. Tests will tell me if what I'm building is working or not. They will also give me feedback on the design of what I'm building. And all of this independently of the frameworks/tools I'm using. So even when I have to dig in a codebase that uses technologies that I'm not so familiar with, I'm always reasonably confident that by writing tests and by reading the technologies' documentation, that I can get productive pretty quickly.

What about you? What made you interested in learning how to write or learning how to TDD?
Why are Apple computers considered "high quality", when their hardware has so many flaws (by design)?
Published: 2020-08-01 21:46:58

I don't want to flame Apple in anyway. Windows machines are probably just as bad. I just want to understand why Apple is considered "high quality" when in fact their products has so many flaws:
https://youtu.be/AUaJ8pDlxi8

Usually, people who continue to buy it aren't iOS developers. So, they could just use any other computer.
What are examples of expression statements in JavaScript?
Tags: discuss, javascript, codenewbie
Published: 2020-08-01 21:28:32

I know what an expression is and I know what a statement is in JavaScript. But what are expression statement in JavaScript?

I know that the ternary operator (... ? ... : ...) and function calls (alert("Hello World")) are expression statements. But what else? Or are only these two considered expression statements?
Basic Principles of Redux
Tags: redux, react, javascript, beginners
Published: 2020-08-01 20:58:02

Redux is a state managing library used in JavaScript applications. It manages the state of your application or in simple words, it is used to manage the data of the application. 

It is used with a library like React etc. 

In this article we will cover three basic principles of Redux.

#The first principle of Redux

###**You represent whole state of your application as a single JavaScript object**

State example for a counter application
```
{
	CounterValue: 0
}
```
Your application may be a simple one like counter example, TodoList example or a complex application with a lot of UI, and change of state, you are going to represent the whole state of your application as a single JavaScript object.

#The second principle of Redux

###**State tree is read only. You cannot modify or write to it.**

**How you change the state?**

Anytime you want to change the state, you need to dispatch an action.

**What is Action?**

An action is a plain JavaScript object describing the change. Example increment counter value or decrement counter value. 
```
{
       type: 'INCREMENT'
}
```
```
{
       type: 'DECREMENT'
}
```

##Pure vs Impure Functions
To understand this principle we will have to differentiate between pure and impure functions. 

**Pure functions:**

Pure functions do not have any network or database calls.

* They just calculate the new value.
* If you call the pure function with the same set of arguments or parameters, you’re going to get the same returned value.
* Pure functions are predictable.
* They do not modify the values passed to them, see following example
```
function cube(x) {
  return x*x*x;
}
```
**Impure functions:**

Any function that changes the internal state of one of its arguments or the value of some external variable is an impure function . They may have any side effects like network or database calls and it may modify the arguments which are passed to them.
```
function getSquare(items) {
  var len = items.length;
  for (var i = 0; i < len; i++) {
    items[i] = items[i] * items[i];
  }
  return items;
}
```
* These functions may call the database or the network,
* They may operate on the DOM,
* They may override the values that you pass to them.


#The third principle of Redux

###**To describe state mutations/changes, you have to write a function that takes the previous state of the app, the action being dispatched, and returns the next state of the app.**

* This function has to be pure.
* This function is called the “Reducer.”

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/ajiy2h501p5s0tt753oi.png)


[Complete Article link and more related to Redux and React](https://www.techbrainshub.com/technology/redux/basic-principles-of-redux/)
My links 
Published: 2020-08-01 20:39:11

Compiled the links which I like.

https://dev.to/sargalias/how-to-learn-web-application-security-2ji1
https://dev.to/jessicagarson/resources-for-learning-python-hd6?signin=true
https://dev.to/aspittel/my-favorite-free-resources-for-new-programmers-bia
https://dev.to/aspittel/my-favorite-free-resources-for-new-programmers-bia?signin=true
https://dev.to/murkrage/five-git-commands-i-started-using-that-might-be-helpful-to-you-536e
https://medium.com/@earlg3/google-cloud-architect-exam-study-materials-5ab327b62bc8
https://medium.com/hackernoon/react-redux-for-lazy-developers-b551f16a456f
Jumpstart your engineering career
Published: 2020-08-01 20:22:48

Some quick advice to any new engineers starting their new career.

# 1. Ask questions (put your pride away)
Engineers only know one thing, and it's that they don't know everything. Especially for _entry-level_ engineers, you're going to have a __lot__ of questions and that's _ok_. Don't feel like your team is going to think less of your skills. It's better to ask questions than fail because you didn't know about the requirements.

Put your ego aside and ask questions early.

It's exponentially better to ask questions early so that you can plan project beforehand. It's okay to have questions down the line as you work towards the goal but try to have more of it before the project starts. 

Your team will thank you for it. Seriously, they have much more patience in the beginning than the end.

With that being said however, be cognizance of bombarding your team members questions. Remember they have their own work too. My advice is to always do you research (aka stack-overflow) if you think you are asking too many questions.

# 2. Imposter Syndrome happens to everyone
Essentially Imposter Syndrome is the feeling of not belonging to the team or somehow being a fraud. This phenomenon happens to everyone in the engineering community, even 10+ year experienced devs. 

The problem with imposter syndrome is that it takes a lot of your headspace and can cause worrying levels of stress / anxiety. Keeping untreated stress can cause dips in productivity.

From my experience, an actionable task to tackle this problem is 
1. Focus on your strengths. There are legitimate reasons why your employer has chose you. Figure them out and embrace it. Write them down and share it with a friend


2. Find a mentor - someone that can help you when you get stuck. The most important thing a mentor can do is to tell you that it's ok to struggle (and that everyone goes through them)

3. Create a brag document. Truthfully you have accomplished a lot already in your career. Every win, make sure you have them documented somewhere. This psychology enforces positivity and self worth.


Luckily Imposter Syndrome, it has been heavily researched, and I recommend you read some more on it. I recommend starting on the wikipedia page.

# 3. Don't assume you are always right
When diving into a codebase, it can very tempting to refactor everything but realize many times developers have already thought it through and decided to do it that way.

Example: 

You see this code

```javascript
let bool;
if (isDirty) {
  bool = isAbove0
} else {
  bool = false
}
```
and want to refactor it to this because you're thinking this is so much cleaner. Well is it really? Even if it is, is it worth the time? A senior engineer might not think so especially if coding standards have been established that way.

With that being said though, it doesn't hurt to have a conversation with your team about it _casually_;

```javascript
const bool = isDirty ? (isAbove0 ? true : false) : false;
```
How to Publish Files to Github using Visual Studio Code
Tags: github, git, visualstudiocode, sourcecontrol
Published: 2020-08-01 20:14:52

Did you love my post? <a href="https://www.buymeacoffee.com/willydavidjr"><img src="https://img.buymeacoffee.com/button-api/?text=Buy me a coffee&emoji=&slug=willydavidjr&button_colour=f25a71&font_colour=000000&font_family=Lato&outline_colour=000000&coffee_colour=FFDD00"></a>

Hello coders!

I will be sharing some basic fundamentals on publishing your code files to Github using Visual Studio Code. Normally we do this using Visual Studio but we can also easily do this via Visual Studio Code.  So let's start.

First open your Visual Studio and click the Source Control Icon in the left (Ctrl + Shift + G):

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/963y464zj64un3j26vtj.PNG)

This will tell you that you need valid Git Installation. You can get Git on this link: https://git-scm.com/downloads

Afterwards, go to the folder/workspace which contains your files that you want to publish on your Visual Studio Code. Click again Source Control Icon and select Publish to Github:

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/1kfo7md0zzrw44pb1a83.PNG)

This time it will launch your browser which will authenticate your request:

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/rxpa1tqlh79gsl80e6rr.PNG)

Select Continue button and on the next page of the browser, copy the token, switch back to VS Code and click Signing in to github.com in your status bar. Paste the token and hit enter.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/tg1dh7zsvhch4p784k82.PNG)

Once done, let's start committing and publishing your changes to your Github master branch!

First, try to edit one of your file, and click the Source Control Icon, by now you should be familiar with the Source Control Icon. If not, it looks like this:

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/o3pjd2hmok5xvtzp27kd.PNG)

Your next task is to stage your changes. Click the plus sign on the files that was changed and you want to commit:

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/vw8qdsikea0qz3izk0qv.PNG)

You will notice that your selected files will be moved to Stage Changes category. Type your initial description then click the Check/Commit sign.

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/0hcrg8cmqdmv8u0cb7f8.PNG)

Lastly click the three dots and click the Push option to push your changes to your master branch:

![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/pbpq9ri2k0t2xornwjl2.PNG)

Take note that you are pushing here on your master and private branch on Github. To modify your preferred settings and make your Github repository public, you can always go to Github and make your changes on the site. Happy coding!
Debian üzerinde RPM Paketi oluşturma
Tags: rpm, debian, paket
Published: 2020-08-01 20:11:45

Debian tarafında Centos, RHEL veya Fedora gibi sistemlerde kullanılan RPM paket yapısı oluşturulabilmektedir. Oluşturulduktan sonra kurulum için ise RPM tabanlı dağıtımlar kullanılabilmektedir.

## Paketin Yüklenmesi

Debian tabanlı sistemlerde rpm paketinin yüklenmesi gerekmektedir.

```bash
sudo apt install rpm
```

## Temel RPM build klasörü

Öncelikle temel RPM build alınacaksa öncelikle **.rpmmacros** dosyası ile varsayılan **rpmbuild** klasörünün belirlenmesi gerekmektedir. Eğer bu yol değiştirilmezse ev dizininin altında /rpmbuild klasörü oluşmaktadır. Bu durumda ~/rpmbuild olarak düşünülmektedir.

Eğer rpmbuild klasörünü değiştirmek isterseniz ev dizini altında bulunan **~/.rpmmacros** dosyası düzenlenmelidir. Herhangi bir dosya yoksa aşağıdaki şekilde düzenlenmelidir:

```
%_topdir            /home/aciklab/calismalar/rpmtest/rpmbuild
```

Bu gibi durumda aşağıdaki komut ile rpmmacros dosyası içindeki build klasöründe aşağıdaki klasörler oluşturulmalıdır:

```bash
mkdir -p /home/aciklab/calismalar/rpmtest/rpmbuild/{BUILD,BUILDROOT,RPMS,SOURCES,SPECS,SRPMS}
```

## SPEC dosyasının düzenlenmesi

RPM Paketinde belki de en önemli madde SPEC klasörü içerisinde spec dosyasının oluşturulması. Bunun için aşağıdaki gibi örnek dosya oluşturulabilinir. Buradaki en temel satır requires kısmında belirtilen bağımlı paketlerin listelenmesidir.

```
Name:       merhabadunya
Version:    0.10
Release:    1
Summary:    Temel RPM paketi
License:    GPLv2
Packager:   Ali Orhun Akkirman
Requires:   bash

%description
Örnek ve basit bir RPM paketi

%prep
# hazırlık içerikleri

%pre
# yükleme öncesi yapılacak betikler

%post
# yükleme sonrası yapılacak betikler

%build
cat > merhabadunya.sh <<EOF
#!/usr/bin/bash
echo "Merhaba Dünya"
EOF

%install
mkdir -p %{buildroot}/usr/bin/
install -m 755 merhabadunya.sh %{buildroot}/usr/bin/merhabadunya

%files
/usr/bin/merhabadunya

%changelog
# degisenler
```

İlgili dosyada build edilecek kısımda oluşturmak istediğiniz dosyaları oluşturabiliyorsunuz. Örneğin yukarıdaki örnekte /rpmbuild/BUILD klasörü altında içerisinde "Merhaba Dünya" yazısını barındıran merhabadunya.sh dosyası oluşturulmaktadır.

Yukarıdaki örnekte install kısmında ise kök dizini üzerinde klasör oluşturma ve bu klasöre bir dosyayı göndermek yer almaktadır. Ve tabi bu klasörü files kısmında da belirtmek gerekmektedir.

## Paketin İnşaası

Gerekli SPEC dosyasını hazırladıktan sonra aşağıdaki komut ile RPM paketi oluşturulabilmektedir:

```bash
rpmbuild -ba  /home/aciklab/calismalar/rpmtest/rpmbuild/SPECS/merhabadunya.spec
```

Paket inşaa edildiğinde /home/aciklab/calismalar/rpmtest/rpmbuild/RPMS/x86_64/ klasörü içerisinde dosya adı ve sürüm numarasına göre **rpm paketi** oluşturulmaktadır.

Dum spiro spero
Create Your Github readme with automated news data 
Tags: github, productivity, node, javascript
Published: 2020-08-01 19:26:44

GitHub added a new feature ,where you could have a README on your GitHub profile.It could be used as portfolio or just a fun project.

##GitHub profile README
So what is that GitHub profile README thingy? Its a cool new feature by GitHub which allows you to have a README on your profile. Sounds cool? Surely it is. Time to get creative 😋.

#How to include TeachCrunch news api data in readme
So to access the news API, you need to have an access key.
which you can get here https://newsapi.org/
So how do we get TeachCrunch news? Well, the answer is really easy. So we will do it in NodeJS. We will install some dependencies.

We installed 3 dependencies here, but *express* , *dotenv* and *isomorphic-unfetch*.
`npm i isomorphic-unfetch`

*index.js*
(code snipit)
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/zfx4k911nkzmylfpp56x.PNG)

#The auto updating README

Create README.template.md with replacement tags


![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/c98amj1li06kt7cw0jdb.PNG)

#Using Github Actions for AutoUpdate

Now we have created the scripts, we need to automate it to update the README every hour. For this, we will use GitHub's actions.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/kxab5p0mvez27w6micl4.PNG)
As a bonus, I also used the Programming Quotes API to get the quote of the hour.

##what you get
github link: {% github mridul037/mridul037 %}
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/f5kq9new4bzq1lpsi8xf.PNG)
THE COLLABORATION BETWEEN TWO TECH GIANTS
Tags: googlecloud, apple, covid19, app
Published: 2020-08-01 19:21:34

Hello Everyone
Today's post is not going to be a technical one but it contains one of the most valuable information for the tech-enthusiasts.
So ,here Spectrum club of College of Engineering and Technology,Bhubaneswar is going to inform you about the greatest collaboration of this year.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/f8j9zb1phvdbmtkoq71j.jpg)

                      DESIGNED BY:-PRAJOJITA NAYAK  

_Can you imagine the tech giants  APPLE and GOOGLE endulge into partnership?_
Well in the wake of covid pandemic we see the spirit of collaboration between the two giants.
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/f8dt8f4p2ghw74hezjpz.jpg)

                      DESIGNED BY:-PRAJOJITA NAYAK 

Let's see a glimpse of their work:-
##Apple and Google will be launching a comprehensive solution 
    that includes application programming interfaces (APIs) and 
    operating system-level technology to assist in enabling 
    contact tracing
![Alt Text](https://dev-to-uploads.s3.amazonaws.com/i/79ir8ecat9q8xusiqxsh.png)

##Location-based surveillance has been floated for everything from tracking past movements and tracing contacts of infected persons to enforcing quarantines and social distancing##

_APPLE and GOOGLE believe there has never been a more important moment to work together to solve one of the world’s most pressing problems.A simple cause wiped the competition_

Let's cherish such innovative move and celebrate their progress in this friendship day with a motive of putting forward  a helping hand to mankind.Well that's the main motive of technology and yes it's in safer hands.

**So "programmers"and all the "techies". Here's a small quote for you:-)
Try to be a semicolon( ; ) for all problem statements**

HAPPY FRIENDSHIP DAY ❣️



HOPE THIS ARTICLE WILL BE HELPFUL:)
How can I collect this type of dataset?
Tags: ai, discuss, machinelearning, datascience
Published: 2020-08-01 19:16:11

---
title: How can I collect this type of dataset?
published: true
description: 
tags: ai, discuss, machinelearning, datascience
//cover_image: https://direct_url_to_image.jpg
---
Hey there! I'm developing an AI analytics service called [Tractific](https://www.tractific.com). We give solutions to optimize trial to paid conversion rate. We have some kind of model already in place that was trained on our own usage data; however this turned out not to be enough. How can I acquire some more user behavior data to train our service? My first thought was to search for someone to integrate with our platform and get some real-life data; however nobody agreed to this yet. Is it just impossible to get that data?
Digital Marketing Future
Tags: digital, marketing, future, seo
Published: 2020-08-01 19:09:50

The importance of digital marketing has increased gradually in the coronavirus process. People are now exploring the methods of getting everything they're looking for without leaving their homes. This leads the company owners to digital marketing.

There has been increasing interest in digital marketing, especially in Turkey. Even people shopping from a nearby market have become able to shop on the online site of the market.

This is an improvement even in the machinery industry. People want to buy the machines they want to buy by seeing them on the internet. We, as [pakmakina.com](https://www.pakmakina.com) project team, do our best to improve our site in this process. The reason we register on this site is to improve our skills.
Controlling access to your API Key
Published: 2020-07-21 15:13:24

The Firstclasspostcodes [dashboard](https://dashboard.firstclasspostcodes.com) provides you with a number of security controls that help restrict access with your API key.

## Enabled Operations
Today, we're releasing this to all of our customers! We've heard feedback from our customers asking us to provide a mechanism to disable operations that aren't required for their use cases, such as Geolocation Lookup; this can help to prevent accidental usage.

![A view of security mechanisms](https://dev-to-uploads.s3.amazonaws.com/i/h7i3n7urgh2gng8n88ls.png)

Let's also review all of the other ways we help to secure your API key.

## Whitelisted domains
You can control access to your API key by whitelisting domains that you'll be using the API key on. For example, if your website lives on `https://e-shop.com`, you can restrict access by setting `e-shop.com` as a whitelisted domain.

This would prevent access to your API key for requests originating from any domain other than `e-shop.com`. 

We also allow you to use wildcard subdomains, so feel free to provide `*.e-shop.com` too.

## Whitelisted IPs
If you're integrating with our API from the back-end, you can provide whitelisted IPs and CIDR ranges to restrict access to your API key from any requests not matching that IP or address range.

---

We're also working on a mechanism to limit the number of requests that can be sent for a specific operation within a billing period.