teleren/devto huggingface dataset:
Rails: Prevent users from logging out after each deployment
Tags: rails, programming, devops
Published: 2021-10-29 14:08:33

Here's a quick one, and it may be obvious to some of you but I didn't know about it. I noticed that my Rails app ([Fugu](https://fugu.lol)) kept logging out all users after every deployment.

First, I thought it's an issue with Devise, but it turns out that it's related to a variabled called `secret_key_base` that Rails uses to sign and encrypt cookies (among other things).

For production, there are multiple places to define `secret_key_base`. A glance at the [Rails soure code](https://github.com/rails/rails/blob/9f980664fc1bc1fb9845e17d2c5a9ab710156303/railties/lib/rails/application.rb#L411-L419) shows that Rails looks for it in `ENV["SECRET_KEY_BASE"]`, `credentials.secret_key_base`, or `secrets.secret_key_base`.

In my case, I hadn't set up any credentials or secrets, nor was I providing an environment variable.

Digital Ocean (and, [as it looks, Heroku](https://blog.heroku.com/container_ready_rails_5#secret_key_base)) automatically sets the `SECRET_KEY_BASE` environment variable for you, and it changes with every deployment. And this was the problem. After each deployment, my Rails app couldn't decrypt the existing session cookies anymore beause `secret_key_base` had a different value, and my users needed to log in again.

To solve the problem, just provide a `SECRET_KEY_BASE` environment variable in your production server. The simplest way to generate it is to run `rake secret` in your terminal (make sure you're in a Rails project folder).
I just bought 👩‍💻👨‍💻.to!
Tags: discuss, webdev, showdev
Published: 2021-10-29 14:07:26

Yes, you read that right, I now own [👩‍💻👨‍💻.to](https://👩‍💻👨‍💻.to). 

Now for a split second you may have thought I meant dev.to - of course not, I don't want a 5(6) character long domain, it is way too long! **I want a 4(5) character domain! 😉**

But you can copy and paste 
<br>
👩‍💻👨‍💻.to 
<br>
into the URL bar and you will end up at my DEV profile...and that is pretty weird and fun!  

## Why buy an Emoji domain?

A sensible answer to that question is that you shouldn't buy an Emoji domain! 

They are not very useful, they end up changing to horrible sets of character codes as the domain name ("xn--qq8hb0wb.to" is the actual domain I bought!) and they are not very professional.

However I don't care about such things, I want something silly and fun to play with and I like to do weird and wonderful things on the internet...so why not buy an emoji domain, something different!

## What next?
I don't really know, it was a silly Friday thing to do, I mean...who buys emoji domains?

If anyone has any good ideas for what to do with the domain then let me know!

### Let's see what problems it causes
Next step is to set up an email account for the domain. 

I can't wait to see if I can actually set my email address to g@👩‍💻👨‍💻.to as that would be hilarious!

---

**Update:** Email works kind of - unfortunately combined emojis (I can't remember the proper name) don't work so you end up with "g@👩💻👨💻.to" instead of "g@👩‍💻👨‍💻.to", but I can still receive emails at "g@👩‍💻👨‍💻.to", so feel free to send me an email!:

![Email received shows from g@👩💻👨💻.to](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/iirql749xx7wyd5qs0lk.png)

---

## Over to you!
So have you ever bought an emoji domain? 

Can you think of a good use for my domain? 

Do you think emoji domains will ever catch on?
New Scaring And Bombing Tool - HalloBomber
Tags: halloween, python, bash, hacking
Published: 2021-10-29 14:00:36

Hello Everyone 
Today I will be going to tell you how you can send scary messages in Whatsapp and do sms bombing using termux.

Firstly install Termux from Play Store

Then upgrade packages

```shell
apt update && apt upgrade -y
```

Then install Git Package

```shell
pkg install git -y
```

Then clone this repo

```shell
git clone https://github.com/ProHarshit/HalloBomber
```

Then navigate to it

```shell
cd HalloBomber
```

Then run it

```shell
bash hallobomber.sh
```

Then enter victim's phone number.
It will automatically load msgs you just need to press send.
Also keep a large number in sms bombing minimum 50.
Also I recommend you to use a scary profile pic.

Thank you
(Followers Goal 50)
Pls tell how did you like it
Responsive Personal Portfolio Website with HTML CSS JS - Part 1
Tags: css, javascript, webdev, beginners
Published: 2021-10-29 13:16:43

{% youtube 6A5Kpjx5lz8 %}

How to create Responsive personal portfolio website with html css js

In this video series, 
I will show you how to build a Complete Responsive Personal Portfolio Website using HTML CSS JavaScript. 

🌟 Website features
---------------------------------
+ 5 pages
+ Fully Responsive and mobile friendly
+ Awesome Page Navigation
+ Filterable item showcase

---

HI 👋
I'm Sadee (webdev)
In this channel I make videos about Complete Responsive website.
You can checkout my channel 👇

📺 My Channel : [codewithsadee](https://www.youtube.com/channel/UC1PZHWV6VvICTL1LgFUZq6g)
🔔 Subscribe : [subscribe now](https://www.youtube.com/channel/UC1PZHWV6VvICTL1LgFUZq6g?sub_confirmation=1)
🕐 New videos Every Friday & Tuesday

---

🔗 Essential links
-----------------------------
Images : [image.zip](https://drive.google.com/file/d/1CZZcnaOEVDDneSve6qpSUoyAfEBuPrqD/view)
Font : [Poppins](https://fonts.google.com/specimen/Poppins?query=poppins)
Ionicon : https://ionic.io/ionicons
How to use ionicon : https://youtu.be/TTrYjLOJeKs
Source Code : https://www.patreon.com/codewithsadee

---

⏱️ Timestamp
------------------------
0:00 - Demo
1:12 - File Structure
1:28 - Initial html setup
2:09 - CSS variables
2:47 - Custom scrollbar
3:15 - Reset and default style
5:15 - Mobile navbar
8:15 - Sidebar
14:15 - Hero
18:15 - Service
21:25 - Testimonials
25:50 - Client
27:52 - Media queries

---

👤 Like - Follow & Subscribe Me
----------------------------------------------------
Twitter : https://twitter.com/codewithsadee
Github : https://github.com/codewithsadee
YouTube : [codewithsadee](https://www.youtube.com/channel/UC1PZHWV6VvICTL1LgFUZq6g)
Buy Me A Coffee : https://www.buymeacoffee.com/codewithsadee
Patreon : https://www.patreon.com/codewithsadee

---

[![Buy Me A Coffee](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9kn6vwn4mulhsx6o69is.png)](https://www.buymeacoffee.com/codewithsadee)
Does React Hooks Replace Redux: Where to use Which?
Tags: react, redux, programming, beginners
Published: 2021-10-29 12:48:16

<a href="https://codersera.com/blog/react-redux-hooks-with-typescript/">Redux vs React Hooks</a> is a pretty much old debate. Which one to go for and which may be replaced by what. Let's find out.

<h2>What is Redux?</h2>

Redux is a predictable state management library and architecture which easily integrates with React.
The primary selling points of Redux are:

<ul>
<li>Deterministic state resolution (enabling deterministic view renders when combined with pure components).</li>
<li>Transactional state.</li>
<li>Isolate state management from I/O and side effects.</li>
<li>Single source of truth for application state.</li>
<li>Easily share state between different components.</li>
<li>Transaction telemetry (auto-logging action objects).</li>
<li>Time travel debugging.</li>
</ul>

To put it another way, Redux provides you with superpowers in terms of code structure and debugging. It's easier to write more maintainable code, and it's a lot easier to figure out what's wrong when anything goes wrong.

<h2>What is React?</h2>

React hooks let you use state and React lifecycle features without using class and React component lifecycle methods. They were introduced in React 16.8.
The primary selling points of React hooks are:

<ul>
<li>Use state and hook into the component lifecycle without using a class.</li>
<li>Colocate related logic in one place in your component, rather than splitting it between various lifecycle methods.</li>
<li>Share reusable behaviors independent of component implementations.</li>

It's worth noting that these wonderful benefits don't actually overlap with Redux's. To obtain consistent state updates, you should indeed utilize React hooks, but that has always been a part of React, and Redux's deterministic state model fits right in. That's how React allows for deterministic view rendering, and it's one of the main reasons for the framework's inception.
Code Smell 98 - Speling Mistakes
Tags: oop, programming, tutorial, javascript
Published: 2021-10-29 12:34:53

*Spelling and readability are very important for humans and not important for machines.*

> TL;DR: Take care of your names.

# Problems

- Readability

# Solutions

1. Spellcheck your code.

2. Use an IDE with spellchecking

# Context

Many of us don't speak English as our first language. 

We need to have extra care for our texts and names.

*This article has a typo in its title as proof of context and also a clickbait*😀

# Sample Code

## Wrong

[Gist Url]: # (https://gist.github.com/mcsee/a4c5716a56fdb9b1b743debae3adfb4c)
```javascript
comboFeededBySupplyer = supplyer.providers();
```

## Right

[Gist Url]: # (https://gist.github.com/mcsee/1fc16a4982d8f423107d3e64d3c31e48)
```javascript
comboFedBySupplier = supplier.providers();
```

# Detection

[X] Manual
- We need to read the code in a peer review.

[X] Automatic
- Some IDEs have warnings on the typos.

# Tags

- Readability

- Naming

# Conclusion

Pay close attention to your names. 

You will probably be the person reading the code in a few months. 

# More Info

- {% post https://dev.to/mcsee/what-exactly-is-a-name-part-i-the-quest-61k %}

- {% post https://dev.to/mcsee/what-exactly-is-a-name-part-ii-rehab-20gd %}

# Credits

Photo by <a href="https://unsplash.com/@brett_jordan">Brett Jordan</a> on <a href="https://unsplash.com/s/photos/alphabet">Unsplash</a>
  
> Inside every well-written large program is a well-written small program.

_C.A.R. Hoare_

{% post https://dev.to/mcsee/software-engineering-great-quotes-26ci %}

* * *

This article is part of the CodeSmell Series.

{% post https://dev.to/mcsee/how-to-find-the-stinky-parts-of-your-code-1dbc %}
Gelungene Sales-Funnels: Best Practices
Tags: onlinemarketing, leadgenerierung
Published: 2021-11-02 13:55:59

---
title: Gelungene Sales-Funnels: Best Practices
published: true
date: 2021-10-29 12:23:19 UTC
tags: OnlineMarketing,leadgenerierung
canonical_url: https://bloggerpilot.com/sales-funnel/
---

![Gelungene Sales-Funnels: Best Practices](https://bloggerpilot.com/wp-content/uploads/2021/10/sales-funnel-1.png)

Verkaufstrichter (auch bekannt als Marketingtrichter oder Marketingkanäle) sind eine großartige Möglichkeit, dein Produkt oder deine Dienstleistung potenziellen Kunden vorzustellen. Sie sind auch ein hervorragendes Instrument für Unternehmen, die ihre Konversionsraten von einem Tag auf den anderen verdreifachen wollen.

Doch obwohl sie eine weit verbreitete Methode sind, werden Verkaufstrichter oft zugunsten komplexerer Marketingstrategien übersehen. In diesem Artikel gehen wir auf die Grundlagen der Erstellung von Verkaufstrichtern ein und stellen einige Best Practices vor, mit denen du deinen Erfolg steigern kannst.

Der Original-Artikel erschien auf [Gelungene Sales-Funnels: Best Practices](https://bloggerpilot.com/sales-funnel/).
Today's Daily Dose of Programming Humor
Tags: jokes, dailydeveloperjokes
Published: 2021-10-29 12:00:03

---
title: "Today's Daily Dose of Programming Humor"
description: "Check out today's daily developer joke! (a project by Fred Adams at xtrp.io)"
series: "Daily Developer Jokes"
published: true
tags: #jokes, #dailydeveloperjokes
---

Hi there! Here's today's Daily Developer Joke. We hope you enjoy it; it's a good one.

![Joke Image](https://private.xtrp.io/projects/DailyDeveloperJokes/public_image_server/images/5e12594523a5e.png)

---

For more jokes, and to submit your own joke to get featured, check out the [Daily Developer Jokes Website](https://dailydeveloperjokes.github.io/). We're also open sourced, so feel free to view [our GitHub Profile](https://github.com/dailydeveloperjokes).

### Leave this post a ❤️ if you liked today's joke, and stay tuned for tomorrow's joke too!

_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 did the process say after working in an infinite loop all day?

___A:___ I need a break.
 -->
BUILDING WITH DEVOPS
Tags: devops
Published: 2021-10-29 11:49:51

In a broad topic like DevOps, one of the best ways to get this deliberate practice is not to watch YouTube tutorials, or repeat step-by-step guides, but to build things.

In other words, find problems that you can solve, and you’ll be learning without even realising it. This knowledge will help you get into a DevOps role.
How to fix the #CALC! Error In Excel Office 365? – [With Example]
Tags: calcerrorinexceloffi, excelerrors
Published: 2021-10-30 05:50:26

---
title: How to fix the #CALC! Error In Excel Office 365? – [With Example]
published: true
date: 2021-10-29 11:46:54 UTC
tags: CALCErrorInExcelOffi,ExcelErrors
canonical_url: https://geekexcel.com/how-to-fix-the-calc-error-in-excel-office-365-with-example/
---

In this article, we are going to learn **what is**   **CALC! Error in Excel Office 365** , why it occurs, and how to fix it. Let’s get into this article!! Get an official version of ** MS Excel**  from the following link: [https://www.microsoft.com/en-in/microsoft-365/excel](https://www.microsoft.com/en-in/microsoft-365/excel)

## CALC! Error – Causes

- The #CALC! Error occurs when a **formula** runs into a **calculation error with an array**.
- If you have a nested formula, you can try using the **Evaluate Formula tool** to identify where the #CALC! Error is occurring in your formula.

## Practical Example

- For example, you need to **create a sample data** in Excel.

![](https://geekexcel.com/wp-content/uploads/2021/10/Sample-data-69.png)<figcaption>Sample data</figcaption>

- Then, you have to use the below-mentioned formula in any cell.

```
=FILTER(B5:D11,B5:B11="x")

```

![](https://geekexcel.com/wp-content/uploads/2021/10/Use-the-Formula-20.png)<figcaption>Use the Formula</figcaption>

- Now, the formula is asking for all data in the **group “x”** , which doesn’t exist, you will get the result as #CALC! Error as shown below.

![](https://geekexcel.com/wp-content/uploads/2021/10/CALC-Error.png)<figcaption>Error Output</figcaption>

## How To Fix It?

- Fix this error by **adjusting the filter criteria** to return valid results.
- You need to provide a **“not found” value** to return when **no results** are returned.

## Wrap-Up

From this article, you can learn **what is CALC! Error in Excel Office 365** , and how to fix it. If you have any other  **ideas**  or  **questions** , do share them with us here in the  **comment**  section below. Thank you so much for visiting  **[Geek Excel](https://geekexcel.com/)!!**

**Read Also:**

- **[How to Select Cells with Error Values in Excel Office 365?](https://geekexcel.com/how-to-select-cells-with-error-values-in-excel-office-365/)**
- **[How to Change the Signs of Numbers in Excel Office 365? – Quick Steps!!](https://geekexcel.com/how-to-change-the-signs-of-numbers-in-excel-office-365-quick-steps/)**
- **[Excel Formulas to Find the First Error Using MATCH function!!](https://geekexcel.com/excel-formulas-find-position-first-error-match/)**
- **[Excel Formulas to Hide the #N/A Error with VLOOKUP Function!!](https://geekexcel.com/excel-formulas-to-hide-the-n-a-error-with-vlookup-function/)**
- **[How to Use Excel ERROR.TYPE Function in Office 365?](https://geekexcel.com/how-to-use-error-type-function-in-microsoft-excel-365/)**
Top 10 trending github repos of the week💛.
Tags: music, downloader, spotify, react
Published: 2021-10-29 11:37:49

---
title: Top 10 trending github repos of the week💛.
published: true
description: Most popular trending Github repos in this week.
cover_image: https://source.unsplash.com/featured/?coding
tags: music,downloader,spotify,react
series: Weekly Github top 10
---
GitHub is where over 65 million developers shape the future of software, together. Contribute to the open source community, manage your Git repositories, review code like a pro, track bugs and features, power your CI/CD and DevOps workflows, and secure code before you commit it.

Here is the most popular repos published on this platform.

## #1
![social banner of repo](https://opengraph.githubassets.com/0094864329bec4000f7ae8c5387476a906aff0424fc7eda0ea847ae897f76a9f/Footsiefat/zspotify)
{% github Footsiefat/zspotify %}

## #2
![social banner of repo](https://opengraph.githubassets.com/7be337bc3dface4e21cf1b97c26bfd644357c9cbd85fa689f10199b95a1ee639/CyberPunkMetalHead/gateio-crypto-trading-bot-binance-announcements-new-coins)
{% github CyberPunkMetalHead/gateio-crypto-trading-bot-binance-announcements-new-coins %}

## #3
![social banner of repo](https://opengraph.githubassets.com/ca1825c705578e4d0b400918922863d91c9b14eabc04f7af129a33cbc43eec49/modern-js-dev/modern.js)
{% github modern-js-dev/modern.js %}

## #4
![social banner of repo](https://opengraph.githubassets.com/78b5b3992aa647fb18a46a15825dcdf2765b266f079b8888d6e6f5de842c2943/ifzhang/ByteTrack)
{% github ifzhang/ByteTrack %}

## #5
![social banner of repo](https://repository-images.githubusercontent.com/126577260/3c924980-61ac-11e9-8e4e-6e50e0cec366)
{% github trekhleb/javascript-algorithms %}

## #6
![social banner of repo](https://opengraph.githubassets.com/08c0baa8a74993c86984befb378d46e9b761cdfb432b0f31bf670924fa412ecb/Dusk-Labs/dim)
{% github Dusk-Labs/dim %}

## #7
![social banner of repo](https://opengraph.githubassets.com/74bd12c302473b05f8ba74b8f75c2336a66a8f374d18ecdfe403e7ba71990820/shengcaishizhan/kkndme_tianya)
{% github shengcaishizhan/kkndme_tianya %}

## #8
![social banner of repo](https://opengraph.githubassets.com/532e245eeb48c518078790df665f451c202d575f7313299caf24e9778e90c788/misterokaygo/MapAssist)
{% github misterokaygo/MapAssist %}

## #9
![social banner of repo](https://opengraph.githubassets.com/6406f174088cad9e2085a346532864d49696d225485a887920652a61ce9bc77d/deepfakes/faceswap)
{% github deepfakes/faceswap %}

## #10
![social banner of repo](https://opengraph.githubassets.com/cca07d21eded679de9d3b4475e387b150bd3ce68f5ea8c6ead0f0bd6f87b7c6a/cloudreve/Cloudreve)
{% github cloudreve/Cloudreve %}

Enjoy these repos.
Follow me for more articles.
Thanks 💖💖💖
KISS
Tags: javascript, webdev, programming, productivity
Published: 2021-10-29 11:34:55

Este é um conceito que pode te salvar de muito sofrimento!😀

<p>
KISS -  **Keep It Simple, Stupid!**
Traduzindo para o português você pode pensar que este principio fala: "Mantenha simples, estupido" e não, ele não está te chamando de estúpido kkk 😂.
O entendimento que você teve ter sobre este conceitos é: "Mantenha simples e estúpido"
<p/>


---

#### Agora vamos descobrir a ponto principal, que é aplicar no dia-a-dia!
<p>Um dos ponto principais é saber como aplicar no dia-a-dia, porque não adianta nada você só saber o conceito e não aplicar nada! Então vamos aplicar, basicamente esse conceito te diz que você deve manter o seu código simples...
**Primeiramente**, ele não está falando para você deixar o seu código o menor possível.
Mas o que é para você fazer então?
O conceito te propõe que você deixei o seu código o mais legível possível, o mais simples possível e entendível para qualquer DEV que tiver que ler e dar manutenção naquele seu código, independente se o outro desenvolvedor for júnior, pleno, ou sênior!
<p/>

---

#### Exemplo 
<p>É muito comum pelos Dev's javascript criar uma função qualquer e passar parâmetros, agora vamos ver o jeito errado(de acordo com o conceito KISS) e o jeito certo de se criar essa mesma função!<p/>
Então vamos supor que nós estamos precisando criar uma função que recebe como parâmetro uma lista de úsuarios! E a partir disso, vai fazer um `.map` e vai retornar o nome e idade de cada úsuario! Uma coisa bem simples para quem meche com javascript em geral!

---

##### ***Errado!***
```js
  function getInfo(infos) {
    return infos.map(u => ({
     name: u.name,
     age: u.age
    }))
  }
```
Primeiramente, eu nomeei a função como `getInfo`, se eu for nesse código daqui a vários meses, eu vou saber o que a função faz somente pelo nome, acredito que não!
O parametro que eu passe `info`, será que daqui a um tempo sem ver esse código eu vou saber que é uma lista de usuários que eu tenho que passar ali, acredito que também não!
E ali no meu `.map` eu declarei `u`, o que que é esse **u**, nunca que eu vou saber kkk 😂😂!

---
##### ***Certo!***
```js
  function getUserNameAndAge(users) {
    return users.map(user => ({
     name: user.name,
     age: user.age
    }))
  }
```
Agora sim, está bem mais fácil de saber o que cada coisa faz, começando pelo nome da função que já me diz claramente o que ela faz, pegar o nome e a idade do usuário!No parâmetro posso ver claramente que eu vou passar `users`, que como está no plural, remete a vários usuários!
E no `.map` eu deixo explicito que eu estou retornando um usuário e que desse usuário eu retorno o nome e a idade!

---

### Conclusão
Você pode ver que eu dei um exemplo bem simples, mas que pode ocorrer muito no dia-a-dia de um desenvolvedor e isso se aplica a qualquer linguagem ou ferramente que você use, eu espero que você tenha compreendido o sentido do conceito **KISS**, até mais 😀

---

Estou deixando alguns link onde compartilho mais conteúdo além do blog aqui !
- [Instagram](https://instagram.com/onicolasteofilo)
- [Linkedin](https://www.linkedin.com/in/nicolasteofilo/)