teleren/devto huggingface dataset:
Video Game Studio Instability, Basecamp’s Mass Resignations, Apple’s Monopoly & more on DevNews!
Tags: news, podcast
Published: 2021-05-06 17:24:59

---
title: Video Game Studio Instability, Basecamp’s Mass Resignations, Apple’s Monopoly & more on DevNews!
published: true
description: Listen to S4E4 of the DevNews pod!
tags: news, podcast
series: DevNews Season 4
cover_image: https://dev-to-uploads.s3.amazonaws.com/i/zoxvbu0494gq3sxtjp4v.png
---

There’s a lot of fascinating developer news this week! @saronyitbarek and I are here to break it down 👇

{% podcast https://dev.to/devnews/s4-e4-video-game-studio-instability-basecamp-s-mass-resignations-apple-s-monopoly-and-donald-trump-s-facebook %}


### **In this episode, you’ll hear about...**
- The Facebook Oversight Board’s decisions about the (formerly) indefinite ban on Donald Trump’s account
- The European Union ruling that Apple has an unfair advantage when it comes to the distribution of music streaming apps
- The departure of many Basecamp employees following problematic statements made by the company’s co-founders

We also chatted with [Jason Schreier](https://twitter.com/jasonschreier), reporter at Bloomberg and the author of “Blood, Sweat, and Pixels” and now “Press Reset: Ruin and Recovery in the Video Game Industry” — coming out next week! Our conversation centered around video game studio instability (something we definitely enjoy talking about frequently on the show). 

Thanks for listening!


_You can [follow DevNews](dev.to/devnews) to get episode notifications and listen right in your feed_ — or subscribe on your platform of choice! Plus, if you leave us a review, we'll send you a free pack of thank-you stickers. Details [here](https://airtable.com/shr8oKAIMZgdYnBxx). 

## **Quick Listening Links**
- [Apple Podcasts](https://podcasts.apple.com/us/podcast/s4-e4-video-game-studio-instability-basecamps-mass/id1525581923?i=1000520445546)
- [Spotify](https://open.spotify.com/episode/7EKjc9nJPi0sCnA1Nj6adI)
- [Google](https://podcasts.google.com/feed/aHR0cDovL2ZlZWRzLmNvZGVuZXdiaWUub3JnL2Rldm5ld3NfcG9kY2FzdC54bWw/episode/aHR0cHM6Ly9kZXZwb2RzLmRldi9wb2RjYXN0cy9kZXZuZXdzLzI4?sa=X&ved=0CAQQkfYCahcKEwjw9q3iyLXwAhUAAAAAHQAAAAAQAg)
- [Stitcher](https://www.stitcher.com/show/devnews/episode/s4-e4-video-game-studio-instability-basecamps-mass-resignations-apples-monopoly-and-donald-trumps-facebook-83751060)
- [Listen Notes](https://www.listennotes.com/podcasts/devnews-dev-fH8hvsClkWp/)
- [TuneIn](https://tunein.com/podcasts/Technology-Podcasts/DevNews-p1352512/?topicId=162857332)
- [RSS Feed](http://feeds.codenewbie.org/devnews_podcast.xml)
- [Transcript](https://devpods.dev/podcasts/devnews/episodes/160)

_Acknowledgements_ 
- _@levisharpe for producing & mixing the show_
- Our season four sponsors, [Scout APM](https://scoutapm.com/devnews) and [Rudderstack](https://rudderstack.com/) ❤️ 

![Microphone](https://media.giphy.com/media/dW15ZwOHekcRyFpH70/giphy.gif)
How do Notion Web Clipper and Instapaper work?
Tags: discuss
Published: 2021-05-06 17:18:31

I read a lot of articles and when I don't have the time to through one I do three things:
- Save to Medium
- Save to Instapaper 
- Save to Notion

So what happens after that is Notion/Medium/Instapaper scrape the page so that when I do have the time I don't have to look for the link rather just open one of those platforms and the article will be saved under my profile.

So my question is how are they able to achieve that?

Because each website HTML document is different, and my knowledge around scraping is that you have to know how the document structure looks like to collect relevant info. For example:
- You might opt to use class names like `.article` which will house the article body but then if another developer uses a `css-in-js` library then that won't be effective.
- Another way maybe the developer uses HTML5 tags like `<article>` and houses the article body, [chrome reader mode works when you do it this way] inside but another developer might use `<div>`

I asked one of my friends he mentioned they might be doing some analysis on the page and figuring out when an article starts and ends.
Automate whatsapp massage using python
Tags: python
Published: 2021-05-06 17:17:50

For automating your WhatsApp messages with Python, we will need the following things:
python.org
code.visualstudio.com
pypi.org/project/pip
twilio.com
heroku.com
We will do this in a 3 step process
For detailed coding please read this article
<a href="https://pythonslearning.com/2021/05/how-to-automate-whatsapp-message-using-python-pywhatkit.html">Automate whatsapp massages using python</a>
WebSocket – Create Spring WebSocket Application with SpringBoot + SockJS + STOMP
Tags: springboot, websocket, sockjs, stomp
Published: 2021-05-06 17:12:31

https://grokonez.com/spring-framework/spring-websocket/create-spring-websocket-application-springboot-sockjs-stomp

WebSocket – Create Spring WebSocket Application with SpringBoot + SockJS + STOMP

The <strong>WebSocket</strong> protocol provides new capability for web applications: full-duplex, two-way communication. So in the system where the client and server need to exchange data at high frequency and with low latency, <strong>WebSocket</strong> is the best solution. That is the reason for us to create a <strong>Spring WebSocket Application</strong> with <strong>JavaSampleApproach</strong>.

Related Post: <a href="https://grokonez.com/spring-framework/spring-boot/spring-boot-websocket-with-angular-5-client-sockjs-stomp">Spring Boot WebSocket with Angular 5 Client | SockJS + STOMP</a>

<!--more-->
<h2>I. Spring WebSocket Application</h2>
<h3>1. Flow of messages</h3>
We create a <strong>Spring WebSocket Application</strong> with the below flow of messages:

<img src="https://grokonez.com/wp-content/uploads/2018/05/spring-websocket-architecture-ws.png" alt="spring-websocket-architecture-ws" width="741" height="372" class="alignnone size-full wp-image-12620" />

Detail explanations:
- WebSocket clients connect to the WebSocket endpoint at '/jsa-stomp-endpoint'
- Subscriptions to '/topic/hi' pass through the <strong>response channel</strong>, then are forwarded to the In-memory broker (Simple Broker).
- User objects sent to '/jsa/hello' pass through the <strong>request channel</strong> then are forwarded to the spring <strong>WebController</strong>. <strong>WebController</strong> will handle <code>User</code> objects by <code>@MessageMapping</code> and transform  to <code>Hello</code> messages then use <code>@SendTo</code> returns the messages to '/topic/hi' through the <strong>brokerChannel</strong>.

<pre><code class="language-java">
...

@MessageMapping("/hello")
@SendTo("/topic/hi")
public Hello greeting(User user) throws Exception {
    return new Hello(...);
}

...
</code></pre>

- The <strong>Simple Broker</strong> broadcasts messages to subscribers through the <strong>response channel</strong>.
<h3>2. Server side</h3>
In server side, we use <strong>SockJS</strong> and <strong>STOMP</strong> for our application.

What is <strong>SockJS</strong>?
-> <strong>SockJS</strong> lets applications use a WebSocket API but falls back to non-WebSocket alternatives when necessary at runtime, without the need to change application code.

Simple Java configuration to enable <strong>SockJS</strong> and <strong>Stomp</strong> in Spring application:

More at:

https://grokonez.com/spring-framework/spring-websocket/create-spring-websocket-application-springboot-sockjs-stomp

WebSocket – Create Spring WebSocket Application with SpringBoot + SockJS + STOMP
ASCII value in C
Published: 2021-05-06 17:07:16

#What is ASCII code?
The full form of ASCII is the American Standard Code for information interchange. It is a character encoding scheme used for electronics communication. Each character or a special character is represented by some ASCII code, and each ascii code occupies 7 bits in memory. In C programming language, a character variable does not contain a character value itself rather the ascii value of the character variable. The ascii value represents the character variable in numbers, and each character variable is assigned with some number range from 0 to 127. For example, the ascii value of 'A' is 65.In the above example, we assign 'A' to the character variable whose ascii value is 65, so 65 will be stored in the character variable rather than 'A'.
#a program which will display the ascii value of the character variable.
```#include <stdio.h>  
int main()  
{  
    char ch;    // variable declaration  
    printf("Enter a character");  
    scanf("%c",&ch);  // user input  
    printf("\n The ascii value of the ch variable is : %d", ch);  
    return 0;  
}  ```
The output of the above code shows that the user gave the input as 'A', and after giving input, the ascii value of 'A' will get printed, i.e., 65.
**Now, we will create a program which will display the ascii value of all the characters.**
```#include <stdio.h>  
int main()  
{  
 int k;   // variable declaration   
 for(int k=0;k<=255;k++)  // for loop from 0-255  
 {  
     printf("\nThe ascii value of %c is %d", k,k);  
 }  
return 0;  
}  ```
The above program will display the ascii value of all the characters. As we know that ascii value of all the characters starts from 0 and ends at 255, so we iterate the for loop from 0 to 255.
**Now we will create the program which will sum the ascii value of a string.**
```#include <stdio.h>  
int main()  
{  
    int sum=0;  // variable initialization  
    char name[20];  // variable initialization  
    int i=0;  // variable initialization  
    printf("Enter a name: ");  
    scanf("%s", name);  
    while(name[i]!='\0')  // while loop  
    {  
        printf("\nThe ascii value of the character %c is %d", name[i],name[i]);  
        sum=sum+name[i];  
        i++;  
    }  
    printf("\nSum of the ascii value of a string is : %d", sum);  
    return 0;  
}  ```
In the above code, we are taking user input as a string. After taking user input, we execute the while loop which adds the ascii value of all the characters of a string and stores it in a 'sum' variable.
Why you should volunteer for a tech user group
Tags: watercooler, career, motivation, discus
Published: 2021-05-06 17:03:19

## 1 | You get to inspire others

At the core of every user group is a desire to help others. It is to empower and inspire the next generation of tech professionals and enthusiasts for a given field of interest.

As someone fresh out of college back in 2016, I really didn't know what's next. There were so many subfields in IT to choose from and I needed time to appreciate them before I can choose a specialization. By showing me what's possible, the AWS User group inspired me to take my first AWS certification two years later and pursue a career in AWS.

As a community leader for the AWS User Group, I got to meet a lot of people who were just starting out in their journey. At this stage, support is crucial for them in order to build a career in AWS. Seeing them start out as pure beginners to having well-paid jobs in AWS truly makes me happy. 

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

## 2 | Meeting like-minded people and expanding your network

When I first started attending AWS meetups, I didn't know anyone but my officemates. It was awkward to start conversations with people I didn't know, but I did anyway. I was able to get different perspectives on things and know what other companies are doing. It helped rid me of my own biases of technologies I don't understand.

In the time of remote meetups, it’s just not possible to get to know people as you would in a normal meetup. Being a volunteer, however, you get to interact with leaders in the community. You also get to chat with the speakers and connect with them even after the event.

## 3 | You gain a platform for sharing your ideas

Being part of a community, you instantly get an audience for ideas you want to share. As a volunteer, you can help shape the events of the community and feature certain ideas that you might have. 

## 4 | It opens up opportunities for you

I probably didn't know it at that time but the best connection I made in the AWS User Group meetup was the sales director of my current employer, eCloudValley Philippines. We chatted about the topic and he encouraged me to apply to ECV. I told him that with just one AWS certification, I'm not ready yet. But I kept his calling card, hoping for the day that I would be ready. Two years later, I sent my resume to him with that same calling card. Now, I'm one year into eCloudValley and I'm managing a team of 4. The rest, they say, is history.

As a community leader, I am also in the loop for other events in AWS. Recently, I applied under the Community Track and got accepted as a speaker for the [AWS Summit ASEAN 2021](https://aws.amazon.com/events/summits/online/asean/) happening this May 2021.

## Do you have other reasons? Share them in the comments below

Photo by <a href="https://unsplash.com/@rekamdanmainkan?utm_source=unsplash&utm_medium=referral&utm_content=creditCopyText">ray sangga kusuma</a> on <a href="https://unsplash.com/s/photos/volunteer?utm_source=unsplash&utm_medium=referral&utm_content=creditCopyText">Unsplash</a>
Some Method
Published: 2021-05-06 15:21:49

1.Arrow function:
Arrow function give us an alternative way to write a shortest syntax function for expression.
Example:suppose,add two number
let add =function(a,b)
return a+b;
}
console(add(5,12));
output:17
Same thing with arrow function
let add = (a,b) => x + y;
console.log(add(5,12));
output:17

2.Try catch:
JavaScript provides six primitive types as undefined, null, boolean, number, string, and symbol , and a reference type object
try {
//code testing process
}
catch(err){
//error handling process
}

 3.ES6:
An Updated version of JavaScript
Syntax--const,var,Spread operator etc.

4. ES6 Destructuring:
Destructuring  that allows you to destructure an array into individual variables.
Example:
fuction addNumber(){
return[5,7,8]}
returned value to a variable
var number =addNumber();
for individual score
let a =number[1],
     b=number[2],
     c=number[3];

5.Error handling:
If a problematic situation come then two things happen. Programmer code is wrong or Forget to pass a required function.Other side if the program needs a name but it gets back an empty string .In that situation need error handle.

6.Cross browser testing:
Cross browser testing as the name suggests verifying the Functionality of the website on the different common browsers that are widely used right now in the market.
Its important because:
-->To verify that what is wrong with your web application’s layout on the “Essential Browser or OS list“.
--> To provide an excellent User experience without any Browser or Device preferences.

7.Client caches:
Client caches mean its always need for client. Sometimes it is not large.Its help limit data cost for keeping commonly referenced data locally.

8.slice()
The initial string in a certain portion and return a new string
Example: let str ="i love bd"
let res =str.slice(0,2);
console.log(res);
output: 'bd'

9.ChartAt():
It is a method in a string that returns a new string with the value of a certain index that is included as a parameter of the  method.
Example:
const x ="bangladesh"
console.log(x.chartAt(5))
output:"l"

10.replace():
Replace is a method that substring of a primary string which is given as a parameter of the method.
Example:
let str ="fatemin bd";
let addstr - str.replace("fatemin","bangladesh");
console.log(addstr);
output: "bangladesh,bd"
Me vs Me!
Tags: programming, motivation
Published: 2021-05-06 16:56:29

The battle I have when it comes to believing myself, to become a front-end-developer has been a on going battle. I'm currently learning JS and I can say it's been tough but I will not stop. I will continue program and get better everyday.So with that being said the journey to becoming a front-end-developer continues! Have a blessed day everyone.
RASA - Sessions
Tags: rasa, chatbot, nlp, ai
Published: 2021-05-06 16:52:17

A conversation session represents the dialogue between the assistant and the user.

When a user begins the conversation with the assistant, the session starts.

The default session configuration looks like this:

```yml
session_config:
  session_expiration_time: 60
  carry_over_slots_to_new_session: true
```

We can override those values in `domain.yml`.

`session_expiration_time` defines the time of inactivity in minutes after which a new session will begin. In our case, if the user does not respond fo 60 minutes, a new session is created. Setting this to 0 means infinitely long session.

`carry_over_slots_to_new_session: true` means that filled slot values are persisted between sessions. Set to `false` to forget slots between sessions.

You can start a new session anytime by typing `/session_start`.

Setting `carry_over_slots_to_new_session: false` and typing `/session_start` saves us from restarting the rasa shell each time we want to start a new conversation.

You can learn more about sessions in the [documentation](https://rasa.com/docs/rasa/domain#session-configuration).

In the next chapter, we will look at continuous integration using GitHub actions.

Repository for this tutorial:
{% github petr7555/rasa-dev-tutorial no-readme %}

You can checkout the state of the repository at the end of this tutorial by running:
```bash
git clone --branch 11-sessions git@github.com:petr7555/rasa-dev-tutorial.git
```
Download youtube video using python
Tags: python
Published: 2021-05-06 16:50:03

In my previous article, I used a library called pytube to download the videos. However, after some changes introduced by YouTube, it is not really usable anymore — any attempt to download videos results in KeyError: ‘url_encoded_fmt_stream_map’. Also, the library is not actively maintained anymore.
That is why in this article I suggest using pytube3, which is a fork of the original pytube library and has the error fixed (it only works with Python 3). 
All the functionalities of the original library are preserved and we actually still use import pytube to import the library (even though we install it using pip install pytube3).


For detailed coding read this article
<a href="https://pythonslearning.com/2021/04/how-to-download-youtube-videos-using-python-script-pytube.html">How to download youtube video using python</a>
Next.js, integrate React Context only in certain pages
Tags: nextjs, react, javascript, webdev
Published: 2021-05-06 16:43:31

Next.js is one of the most popular and widely used React frameworks.

Using the Context API in Next.js is very simple but there are specific cases where you may need to wrap only certain pages by the provider.

To do this, create a new next project
```jsx
npx create-next-app my-app
```
We are going to create a context that will increment and decrement a number.

Create a new folder `components` and inside create a new file named `context.js` then paste this code
```jsx
import { createContext, useContext, useState, useCallback } from "react";

const Context = createContext({});

export const CountProvider = ({ children }) => {
  const [count, setCount] = useState(0);

  const increment = useCallback(() => {
    setCount((prevState) => prevState + 1);
  }, [count]);

  const decrement = useCallback(() => {
    setCount((prevState) => prevState - 1);
  }, [count]);

  return (
    <Context.Provider value={{ count, increment, decrement }}>
      {children}
    </Context.Provider>
  );
};

export function useCount() {
  return useContext(Context);
}
```
the custom hook `useCount()` will allow us to use the values passed to the context provider.

In the _app.js file, add this new component
```jsx
const Noop = ({ children }) => <>{children}</>;
```

Then in `MyApp` component which is exported by default, we will add a prop named `provider` which will be accessible in all pages and its value will be `<Noop/>`if no context provider is passed as a value.

Now the _app.js file will be like this
```jsx
import "../styles/globals.css";

const Noop = ({ children }) => <>{children}</>;

function MyApp({ Component, pageProps }) {
  const ContextProvider = Component.provider || Noop;
  return (
    <ContextProvider>
      <Component {...pageProps} />
    </ContextProvider>
  );
}

export default MyApp;
```

We will consume the provider in the home page like this

```jsx
import styles from "../styles/Home.module.css";
import { CountProvider, useCount } from "../components/context";

export default function Home() {
  const { increment, count, decrement } = useCount();
  return (
    <div className={styles.container}>
      <button onClick={increment}>Increment</button>
      <h1>{count}</h1>
      <button onClick={decrement}>Decrement</button>
    </div>
  );
}
```

If you try it in the browser, you won't be able to increment or decrement a number because we don't have the provider as a prop in the page.

To make it work, add
```jsx
Home.provider = CountProvider;
```
After reloading the page, you can increment and decrement the number.


[Source code](https://github.com/enochndika/next-with-context-on-certain-pages)
python online compiler for Android
Tags: python, python3, programming
Published: 2021-05-06 16:40:50

In the previous post we saw best python online compiler .
so in this post we will see How to run python code in Android phone
Read this article
<a href="https://pythonslearning.com/2021/04/which-is-python-online-compiler-editor-interpreter-for-android.html">Python online compiler for android</a>
Answer this hardware hacking question to be featured on our podcast 👀
Tags: podcast, discuss, hardware
Published: 2021-05-06 16:37:48

---
title: Answer this hardware hacking question to be featured on our podcast 👀 
published: true
description: 
tags: podcast, discuss, hardware
cover_image: https://dev-to-uploads.s3.amazonaws.com/uploads/articles/126c39qp7h1uvwb2n8s1.png
---

The [DevDiscuss Podcast](dev.to/devdiscuss) begins with an interview and ends with commentary from listeners — and we like to feature the actual voices from our community!

To inform an upcoming episode of the show, we'd like to know...

> ### **“What is the coolest hardware hacking project you've seen — or done?”**

For your chance to hear your actual comments on an upcoming episode, answer the question above by:

- Calling our Google Voice at +1 (929)500-1513 and leave a message 📞

- Sending a voice memo to pod@dev.to 🎙

- OR, leaving a comment here (we'll read your response aloud for you) 🗣

Please send in your recordings by Wednesday, May 12th at Midnight, ET (9 PM PT, 4 AM UTC)

#### Voice recordings will be given priority placement 😉