teleren/devto huggingface dataset:
VS Code hacks
Tags: vscode
Published: 2022-05-24 06:35:50

Install VS code and install it.

To have a better look at the terminal, move it to right. 
1. From the terminal, select `Move to right`. 

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/tzpk4bggtf3mbh3d6o1m.png)
 

2. Install "Code Runner".
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/huq2qt2wwfatyo8alua8.png)
 
3. Now, go to the settings icon and go to `Extensions` and go to "Run Code Configurations" and uncheck this one
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ckclvc2wpgllh5kp642h.png)
Also, check this one

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/9yrk6wr8qy9j2rwsegi2.png)

Now, your code will be ready and clean everytime.
So, after running the code , it will look like this
![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/x111yd6fp5gpywv0c809.png)
npm error
Tags: beginners
Published: 2022-05-24 06:32:56

- 

1. 

1. 
ERR_SSL_DECRYPTION_FAILED_OR_BAD_RECORD_MAC
npm ERR! 4304:error:1408F119:SSL routines:ssl3_get_record:decryption failed or bad record mac:c:\ws\deps\openssl\openssl\ssl\record\ssl3_record.c:677:
npm ERR!

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\AMEC PC 2\AppData\Local\npm-cache\_logs\2022-05-24T06_20_27_188Z-debug-0.log
JS Solutions for CodeWars Katas: Part 2
Tags: javascript, challenge, programming, webdev
Published: 2022-05-24 06:05:33

1.Write an algorithm that takes an array and moves all of the zeros to the end, preserving the order of the other elements.

moveZeros([false,1,0,1,2,0,1,3,"a"]) // returns[false,1,1,2,1,3,"a",0,0]

My solution:
```js
const moveZeros = arr => arr.filter(num => num !== 0).concat(arr.filter(num => num === 0))
```
Long version:
```js
function moveZeros(arr) {
  let zerosArr = arr.filter(num => num === 0)
  let nonZerosArr = arr.filter(num => num !== 0)
  return nonZerosArr.concat(zerosArr)
}
```
2.Write a function that accepts an array of 10 integers (between 0 and 9), that returns a string of those numbers in the form of a phone number.

Example
createPhoneNumber([1, 2, 3, 4, 5, 6, 7, 8, 9, 0]) // => returns "(123) 456-7890"
The returned format must be correct in order to complete this challenge.
Don't forget the space after the closing parentheses!
```js
const createPhoneNumber = numbers =>
   `(${numbers.slice(0,3).join('')}) ${numbers.slice(3,6).join('')}-${numbers.slice(6, 10).join('')}`
```
Unable to Log In
Tags: android, javascript, webdev, programming
Published: 2022-05-24 05:58:39

If you or an agency member or colleague have trouble logging on to the Upwork desktop app, it could be a problem with the Sign in with Google feature. Try the following solution.

Disable authorization via **[tools apk](https://mhapks.com/category/apps/tools/)** Google. Go to Profile Settings -> Connected services -> [Sign in with Google] -> Disconnecting, then reattempt login via the desktop app.
Next, log in to your desktop app using your username only.
If the issue still persists, please contact Upwork Support directly for further review of your account settings.
WSL system moving
Tags: wsl
Published: 2022-05-24 05:58:24

* First, close wsl：`wsl --shutdown`
* Second, export wsl: `wsl --export Debian D:\WSL\Debian.tar`
* Third, unregister wsl: `wsl --unregister Debian`
* Lastly, we import the system: `wsl --import Debian D:\WSL\Debian D:\WSL\Debian.tar`
* (optionly: change the default login user: `debian config --default-user Zhang`)
Why Data Science
Published: 2022-05-24 05:38:35

I decided quite some time ago that I wanted to delve into the Data Science realm. I've worked in healthcare for awhile now and I've always been fascinated by the advances in medicine. In particular- the future of transplant medicine and clinical trials. I wondered what kind of skills were needed to jump into the fray. 
It can be daunting when deciding to take that next step. There are a plethora of programs, courses and bootcamps out there. I ultimately chose Flatiron because they've been around for sometime. They are constantly tweaking and fine-tuning their curriculum based on student feedback. And most importantly, they have partnerships and a proven track record.
What level of React are you in?
Tags: javascript, react, beginners, showdev
Published: 2022-05-24 05:23:49

Hey there! 

I was trying to figure out **where do I stand from a React learning perspective?** to set my next learning goal. But I couldn't find anything specific to where to draw the line between a beginner, intermediate and an advanced React developer. 

So, I made a list of topics related to React and some other stuff I'd like to learn, then grouped them into those three categories. These topics are not 100% React. Those fall into foundation topics that you need or libraries/tools that you will face at any point in your career.   

For the grouping part, I thought: "If I wanted to learn from scratch React today, what would be the order I'd need them?" With that in mind, this is the list I came up with:

#### Beginner:
- Basic HTML and CSS knowledge
- CRA setup
- Basic JSX syntax
- Component creation (functional and class components)
- Props and Children
- State (useState and useEffect hooks)
- Conditional render
- Router

#### Intermediate:
- Lifecycle methods
- Error boundary 
- Using one state management library (Context, Redux, Zustand, etc.)
- More state (useMemo and useCallback hooks)
- Controlled and Uncontrolled components
- Typescript
- Testing components (React Testing Library, Jest or both) 
- Adding a CSS Framework (TailwindCSS)
- Customizing component styles (SASS, Styled-Components or JSS)
- Bundler configuration (Webpack)

#### Advance:
- Create your custom hooks
- Storybook 
- React Suspense and Lazy
- Mocking services for tests purposes (like overwriting the render to add a ThemeProvider - React Testing Library) 
- Server-side rendering
- Rewiring React 
- Frameworks like NextJS or Gatsby
- Creating your own component's library
 

After creating this initial list, I gave them a score. Mostly because their learning difficulty is different. It's not the same to learn how to pass props to a component, as learning how to implement Redux! Also because I thought it would be cool to have a small app that will do this for us! And that's how I ended up creating this!

[![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/s7zq116f1eb8kdj63d8i.jpg)](http://react-knowledge-checker.overlapweb.com/)
[React Knowledge Check](http://react-knowledge-checker.overlapweb.com/)

Please, be aware that this list comes from my own experience working on different companies as a React developer, and is probably (if not extremely) incomplete. If you guys have any suggestions, let me know what topics you'd like to see reflected in the list. 

#### What was purpose of this, again? right! the goal:
It's going to be **Suspense and Lazy!** 


[![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jb0y5eujn1hatc1r5f0w.png)](https://www.buymeacoffee.com/danielp)
Cloud Resume Challenge - Part 3
Tags: aws
Published: 2022-05-24 05:23:12

I completed writing the backend as IaC in Terraform. As this was the first complicated project I have done in Terraform, I used an incremental approach to build each component and testing before expanding scope. While most of the essential parts, such as S3 buckets, IAM permissions, Route 53, and CloudFront were quite straightforward; there were a few issues that required a lot of research to fix, primarily due to cryptic error messages. For example, in the API Gateway Integration, I would receive an "BadRequestException: Enumeration value for HttpMethod must be non-empty" error. After digging through documentation and many searches on Stack Overflow, I discovered that this was due to not having used the integration_http_method argument, which the documentation identified as being optional, in addition to the required http_method argument.

After the Terraform code was competed and tested, the next step was to learn how to migrate the activation and distribution to GitHub Actions. This went fairly smoothly, as I had already learned the basics for the frontend code. I had a slight misstep in initializing tfvars, and in forgetting to remove reference to AWS credentials that had been stored locally during testing.

Once the backend had been proven as functional from GitHub Actions, the last step was for me to write a test. I had seen multiple references to a testing framework called Cypress, which interested me as an end-to-end tool for testing web applications. I used Cypress to request a GET on my API, then validate the response as 200 status and a number. This test was then integrated into my GitHub Action workflow to be run from a Docker image after Terraform apply has completed.
Popular Matrimony site for Christians
Tags: design, matrimony, ui
Published: 2022-05-24 05:15:56

[Christian Matrimony](https://www.christiansmatrimonial.com/) is the popular matrimonial site for Christian to find bride groom for marriage. Build with advance features that helps to find Christian partner from the same background and interests. Find your perfect match from any country with the helps of Christian matrimony.
Recurring Background Jobs in Flask
Tags: flask, python, rss, blogs
Published: 2022-05-24 05:07:48

---
title: Recurring Background Jobs in Flask
published: true
description: 
tags: flask, python, rss, blogs
cover_image: https://i.imgur.com/vX2RLmB.png
---
Feeling some frustration with most RSS reader apps being way too feature-heavy for my liking, I recently tried building a [very simple RSS feed reader](https://github.com/jmarhee/rss-reader-simple) that pulls from a `feeds.yaml` file that lists URLs and does little else beyond aggregating those links and, where available, providing the article body.  

In the app, a function like this builds the data body that is populated when Flask renders the template on the page in `parser.py`:

```python

import feedparser
import os
import yaml

def buildConfig():
    with open(os.environ['FEED_YAML_PATH']) as f:
        dict = yaml.load(f, Loader=yaml.FullLoader)
    return dict['feeds']

def buildFeed(feeds):
    feed_body = []
    for url in feeds:
        feed_data = feedparser.parse(url)
        new_feed = {"feed" : url, "data": [feed_data]}
        feed_body.append(new_feed)
    return feed_body
```

basically just dumping all of the feed data into a larger JSON object for Flask to render in the template. 

I wanted to be able to see new feeds I added to this file without restarting Flask, and one way of doing this was to regenerate this data object on every page load, but that would make it take forever to load unless I added a bunch of additional logic or other dependencies or components (storing feeds in memory, etc.) 

In order to avoid adding new components to the app (it's a very small Docker image, and restoring app data only amounts to this Yaml file being available), I decided to add a recurring background task using the `apscheduler` package which has a `BackgroundScheduler` function in `app.py`:

```python
from apscheduler.schedulers.background import BackgroundScheduler
```
then I have it define on app startup the variable that will store the feed_data object to be updated by the recurring job we'll define in a moment, and initialize it:

```python
feed_data = None

@app.before_first_request
def initialize_feeds():
	feeds = buildConfig()
	global feed_data
	feed_data = buildFeed(feeds)
	return feed_data

```

and then adding an `updateFeeds` function that behaves similarly to the above function (in a production app, you could avoid repeating yourself and have the above function reference this one, but for the sake of demonstration):

```python
def update_feeds():
	feeds = buildConfig()
	global feed_data
	feed_data = buildFeed(feeds)
	return feed_data

scheduler = BackgroundScheduler()
job = scheduler.add_job(update_feeds, 'interval', minutes=1)
scheduler.start()
```

and then having that function run as an argument to the `scheduler.add_job()` function above, with an interval of 1 minute. 

So, now, on changes to your Yaml file containing a new URL, the feed_data object will be updated in the background, and load time will be unaffected.
JavaScript Context Thoughts
Tags: javascript, webdev
Published: 2022-05-24 05:04:25

I am in a process of learning a new programming language. It is no surprise that the language is JavaScript. It seems like today every developer needs to know it. I used to work with .Net most of the time back in the days when writing code served as a mean to pay for the things I needed and the things I did not need. Today it is just a memory of the past which I learned to live with. The feature of C# I remember enjoying the most was it's static nature. Nicely defined variables with strong type that propelled intellisense when connecting pieces together. The satisfaction I had when those pieces clicked rewarded the extra time spend defining them. "Some people favor being explicit" remains my most beloved StackOverflow quote buried somewhere under those snappy comments below the popular answers. Yes there was an option to write dynamic code with var but that idea never really appealed to me. Now, with JavaScript, things are different. I have to rely more heavily on debugging due to silly mistakes such as variables not being defined. Overall this feels more like a script than a language to me. Take the function context as an example. You can set it to some other object to your liking by appending .call(), .apply() or .bind() to a function invocation. Then the function's context object can be accessed using 'this.'. Why would such a technique be of any benefit? How do I know what 'this' is referring to by looking at the function's definition? I would have to track down all the places where the function is called to have a feeing 'this.name' refers to a city name and not my cat's name for example. Why not just pass the the object to a function and name it properly instead? This seems like a hack added to the language in order to bridge some of the shortcomings. Of course I might be wrong about the purpose of such context alteration of a function. Anyway, it is OK to be wrong. That's inevitable part of a learning process.
LOOKING FOR REMOTE JAVA/C# or C++ SDE'S!
Tags: java, csharp, job, lookingforwork
Published: 2022-05-24 04:50:07

If you have 3+ years experience in Java,C++ or C# ( all three great! ) message me back I have a few roles open for you. FULLY REMOTE/ COMPETITIVE PAY STRUCTURE/ONLY 1 INTERVIEW
Amazon QuickSight Federation with Google Workspace
Tags: googleworkspace, federation, aws, quicksight
Published: 2022-05-24 04:43:13

Amazon QuickSight is a scalable, 𝙨𝙚𝙧𝙫𝙚𝙧𝙡𝙚𝙨𝙨, embeddable, 𝙢𝙖𝙘𝙝𝙞𝙣𝙚 𝙡𝙚𝙖𝙧𝙣𝙞𝙣𝙜 (𝙈𝙇)-𝙥𝙤𝙬𝙚𝙧𝙚𝙙 𝙗𝙪𝙨𝙞𝙣𝙚𝙨𝙨 𝙞𝙣𝙩𝙚𝙡𝙡𝙞𝙜𝙚𝙣𝙘𝙚 (𝘽𝙄) service built for the cloud that supports 𝙞𝙙𝙚𝙣𝙩𝙞𝙩𝙮 𝙛𝙚𝙙𝙚𝙧𝙖𝙩𝙞𝙤𝙣 in both Standard and Enterprise editions. 

𝙈𝙖𝙣𝙮 𝙤𝙧𝙜𝙖𝙣𝙞𝙯𝙖𝙩𝙞𝙤𝙣𝙨 use Google 𝙒𝙤𝙧𝙠𝙨𝙥𝙖𝙘𝙚 to control and manage 𝙪𝙨𝙚𝙧 𝙖𝙪𝙩𝙝𝙚𝙣𝙩𝙞𝙘𝙖𝙩𝙞𝙤𝙣 𝙖𝙣𝙙 𝙖𝙪𝙩𝙝𝙤𝙧𝙞𝙯𝙖𝙩𝙞𝙤𝙣 centrally. You can 𝙚𝙣𝙖𝙗𝙡𝙚 𝙛𝙚𝙙𝙚𝙧𝙖𝙩𝙞𝙤𝙣 to Amazon 𝙌𝙪𝙞𝙘𝙠𝙎𝙞𝙜𝙝𝙩 accounts without needing to create and manage users. 

Thanks to Sriharsh Adari and Srikanth Baheti for showing the steps to configure 𝙛𝙚𝙙𝙚𝙧𝙖𝙩𝙚𝙙 𝙨𝙞𝙣𝙜𝙡𝙚 𝙨𝙞𝙜𝙣-𝙤𝙣 (𝙎𝙎𝙊) between a Google 𝙒𝙤𝙧𝙠𝙨𝙥𝙖𝙘𝙚 instance and an Amazon 𝙌𝙪𝙞𝙘𝙠𝙎𝙞𝙜𝙝𝙩 𝙖𝙘𝙘𝙤𝙪𝙣𝙩. 

(1) Download the Google 𝙄𝙙𝙋 information
(2) Create an 𝙄𝘼𝙈 𝙄𝙙𝙋 with Google as 𝙎𝘼𝙈𝙇 𝙄𝙙𝙋
(3) Configure 𝙄𝘼𝙈 𝙥𝙤𝙡𝙞𝙘𝙞𝙚𝙨 for Amazon 𝙌𝙪𝙞𝙘𝙠𝙎𝙞𝙜𝙝𝙩 roles
(4) Configure 𝙄𝘼𝙈 𝙌𝙪𝙞𝙘𝙠𝙎𝙞𝙜𝙝𝙩 𝙧𝙤𝙡𝙚𝙨 for federated users
(5) Create a 𝙘𝙪𝙨𝙩𝙤𝙢 𝙪𝙨𝙚𝙧 𝙖𝙩𝙩𝙧𝙞𝙗𝙪𝙩𝙚 in Google Workspace
(6) Add the Amazon Web Services (AWS) 𝙎𝘼𝙈𝙇 𝙖𝙩𝙩𝙧𝙞𝙗𝙪𝙩𝙚𝙨 to the Google Workspace 𝙪𝙨𝙚𝙧 𝙥𝙧𝙤𝙛𝙞𝙡𝙚
(7) Set up the Amazon Web Services (AWS) 𝙎𝘼𝙈𝙇 𝙖𝙥𝙥 in Google Workspace
(8) Grant access to users in Google Workspace
(9) Verify 𝙛𝙚𝙙𝙚𝙧𝙖𝙩𝙚𝙙 𝙖𝙘𝙘𝙚𝙨𝙨 to the 𝙌𝙪𝙞𝙘𝙠𝙎𝙞𝙜𝙝𝙩 instance

𝙀𝙣𝙖𝙗𝙡𝙚 𝘼𝙢𝙖𝙯𝙤𝙣 𝙌𝙪𝙞𝙘𝙠𝙎𝙞𝙜𝙝𝙩 𝙛𝙚𝙙𝙚𝙧𝙖𝙩𝙞𝙤𝙣 𝙬𝙞𝙩𝙝 𝙂𝙤𝙤𝙜𝙡𝙚 𝙒𝙤𝙧𝙠𝙨𝙥𝙖𝙘𝙚
https://aws.amazon.com/blogs/big-data/enable-amazon-quicksight-federation-with-google-workspace/

𝙎𝙩𝙖𝙮 𝙩𝙪𝙣𝙚𝙙 𝙗𝙮 𝙛𝙤𝙡𝙡𝙤𝙬𝙞𝙣𝙜
https://www.linkedin.com/feed/hashtag/?keywords=did_you_know_that

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/scy3nrldf471nahcoy23.png)

https://www.linkedin.com/posts/mahmoudrabie2004_didabryouabrknowabrthat-cloud-cloudcomputing-activity-6934725327881428993-Nthr?utm_source=linkedin_share&utm_medium=member_desktop_web
¿CSS en HTML en JS? Opinión de un futuro React Dev
Tags: tailwindcss, react, css, html
Published: 2022-05-24 04:23:24

A lo largo de los últimos 3 años, mi vida ha tomado un giro de 360°, pasando de dedicarme a la ingeniería de producción en fábricas a desarrollar software desde mi casa.

Ahora, ese cambio pasa a ser transformación y mejora, como lo es dejar de usar Javascript, CSS y HTML aisladamente y sumarlos en React.

Pero ¿Qué tal si le añadimos un poco de sabor a la receta añadiendo el CSS dentro de HTML como si se le pusiera la salsa de tomate al spaggetti revuelta desde el inicio en vez de solo encima de él?

Esto hace Tailwind CSS, para mi es una manera ágil y flexible de manejar el estilizado de nuestros sitios que más temprano que tarde probaré.

En su versión 3.0 ofrece un sin fin de sabores comparada con su versión anterior, el cual debo admitir, me tiene deleitado y no me hostiga por más que lo uso en mi nativo HTML o su primo mamado TWIG.

Para mi es una manera de mejorar la forma de trabajar sin sentir que perdemos nuestras bases de conocimiento en CSS o JS como puede pasar con otras herramientas que buscan potenciar la manera de hacer estilos.

Con esta breve opinión animo al curioso lector a dejarse deleitar por el sabor de proeza y libertad que Tailwind ofrece... y que mejor a probarlo con React.
Undefined error
Tags: react
Published: 2022-05-24 04:15:06

`const ProductScreen = ({ match }) => {
    const [product, setProduct] = useState({})
    useEffect(() => {
        const fetchProduct = async () => {
            const { data } = await axios.get(`/api/products/${match.params.id}`)
            setProduct(data)
        }
        fetchProduct();
    })`

I'm using useEffect and axios to get the data from backend but the console keeps on showing me this error

>  TypeError: Cannot read properties of undefined (reading 'params')
Resist the Mist: Bouncing From Topic to Topic
Tags: javascript, beginners, codenewbie
Published: 2022-05-24 04:03:52

#What coding language should I learn first? 

I don't know about you but I am a frequent flyer of the [r/learnprogramming](https://www.reddit.com/r/learnprogramming/) subreddit. One of the posts I see the most is "What coding language should I learn first?" While I'm by no means a professional, my answer to any and everyone is the same,"the one you start with it". I actually had to take my own advice this week. I have an amazing fellow at my work who is hosting a little Python class biweekly. To include homework and all. When it first started I was so pumped. I was like OH YEAH, I'm gonna learn JavaScript and Python at the same time. 

**FULL STOP** 

What I am doing? It only took a few lessons to realize, that advice I was giving others, that advice I'd hear and read over and over again was so true. I need to slow down and learn the first thing I started with. JavaScript. Python isn't going anywhere right now, and it'll be easier to get a grip on once I learn my one language first. So I call my "instructor" friend and tell him what's up. He already knew I was trying to learn to code and was concentrating on web-development. He wholeheartedly agreed. 

## What HAVE I been learning? 

We just started touching on Node.js, an asynchronous event-driven JavaScript runtime. I learned that computers don't translate JavaScript directly, but there is an engine inside the browser, the JavaScript V8 engine, that is written in C++. The V8 engine compiles our JavaScript into machine code. Net Ninja on YouTube has a great little Intro to Node course if you want to learn more. I'm chipping through it now. 

I can create a server with simple HTTP and FS requests listening on a port channel. And even managed to manipulate the DOM for a coin flip server side with some help from a GREAT 100Devs stream team member [Mayanwolfe](https://www.twitch.tv/mayanwolfe). 

Even on days where I feel like I'm not making any progress, I just have to look at how far I've come. I'll continue to build small apps to practice what I'm learning and review my ANKI cards. Pushing through that "what am I going to build" has been hard. I know what I like and enjoy but I want to make something that helps not just me but others too. I want to do a little series on what I'm building when the time comes. For now, you get to see me for me. Just a girl trying to learn to code and make it in this world!
Hunter Atkins Houston, born in Manhattan, New York.
Published: 2022-05-24 03:57:51

[Hunter Atkins Houston](https://www.crunchbase.com/person/hunter-atkins-houston) was born in the New York city of Manhattan. Hunter Atkins Houston got his first job at The Chicago Sun-Times when he was 17 years old.

Hunter Atkins Houston went to Northwestern University and got his degree from the Medill School of Journalism in 2011. The Wall Street Journal, ESPN The Magazine, SI.com, NationalGeographic.com, Maxim.com, Newsday, Virginia Coastal, Men's Journal, Popular Science, VICE.com, and VIBE have all published articles by Hunter Atkins Houston.



Hunter Atkins Houston has also written for The New York Times, Rolling Stone, and Forbes, among other publications.
What is a proxy server and what is the difference between reverse proxy and forward proxy server?
Tags: proxyserver, reverseproxy, forwardproxy
Published: 2022-05-24 03:56:42

Link to my blog for a very short 2 minute read on , what is a proxy server and what is the difference between reverse and forward proxy server.

[Blog Link](http://belowthemalt.com/2022/05/23/what-is-a-proxy-server-and-what-is-the-difference-between-reverse-proxy-and-forward-proxy-server/)