teleren/devto huggingface dataset:
Recommend me webdev softwares and packages I need to try
Tags: programming, discuss, javascript, webdev
Published: 2022-05-25 18:21:02

So I have run out of stuffs and am searching for new things to try. So please recommend all you know.

As of now I plan to give a while to each of the things recommended and then write a review about them on my [blog](https://error434.xyz/blog). 
You can see the stuff I am currently trying out over [here](https://error434.xyz/trial)
Sharing my experience after scanning 400 APIs
Tags: programming, api, tutorial, security
Published: 2022-05-25 18:16:15

We have recently launched a free instant API security testing DAST (Dynamic Application Security Testing) Ethical Check web tool on GitHub.

Here is the GitHub URL for the tool:
https://apisec-inc.github.io/pentest/

**What kind of vulnerabilities does EthicalCheck find?**
Most automated scanners would find vulnerabilities like SQL Injections, NoSQL Injections, XSS, etc.
EthicalCheck performs different checks, including OAuth 2.0, JWT, BasicAuth, OWASP API #2, and broken authentication defects in web, mobile, and public-facing APIs.

**How EthicalCheck work?**

It requires two inputs:
1. API (OpenAPI Spec/Swagger) documentation URL.
2. Email address for receiving security testing report
 
After a soft launch across a couple of developer forums in the past three months. We weren't hoping that we would get anywhere close to 400 tests.

**Here are the stats:**

- Duration: **Feb 2022 - Apr 2022 (3 months)**
- Total APIs Tested: **400**
- Total APIs with Vulnerabilities: **164**
- Total APIs with 10+ Vulnerabilities: **16**
- Max vulnerabilities found in an API: **65**
- Total Vulnerabilities Found: **948**
- Total Bug Bounty Savings: **$1,896,000** (Based on HackerOne's payout model)
- Total API Penetration Test Savings: **$343,000** (Based on avg penetration testing cost)
- Percentage of APIs with Vulnerabilities: **47.9%**

**Conclusion:**
On an average, close to 50% of the APIs tested had security vulnerabilities. These vulnerabilities can easily be picked up by automated bots and hackers alike. Security breaches are expensive and can cost exponentially upwards of $8.64m to startups and large organizations alike.
Your public-facing mobile/web API has a close to 50% chance of having security vulnerabilities. You can instantly test your public-facing APIs for vulnerabilities @ https://apisec-inc.github.io/pentest/
Python3. Difference between array and list.
Tags: programming, python, array, list
Published: 2022-05-25 17:27:21

In Python, lists and arrays are sets of values. This values are called elements. 

Usually, elements are any type of data, including even objects and other arrays and lists. 

But not for array in Python. Arrays in Python are vary simmilar to lists. But they have some difference. The size and type of an element in an array is determined when it is created.

Let look how we can create an array in Python. 


```
from array import array

numbers = array('i', [2, 4, 6, 8])
print numbers[0]
```


In example, first of all, the array module is imported for work with arrays in Python.

Next, a new array is created. In this array all elements are the integer type.

First argument is a typecode. It define which type of data will be in array. For example, ‘i’ it is int type. But ‘u’ means type of elements in array will be unicode characters. For type float need mention ‘d’.

With lists in Python, work will be a little differently. Lists can contain elements of different data types. 

```
list1 = [] #Creating of empty list
list2 = ['a', 'b', 2, ['c', 3]]
```


Here we created two lists. One of them are emtpy. Second list conteains elements of different data types.
Add custom methods to Javascript built-in classes
Tags: javascript, programming, tutorial, beginners
Published: 2022-05-25 18:15:52

Some people do not know this but you can actually add your own custom methods to strings, arrays and much more

## Prototypes
As we know, every class in Javascript has a prototype containing all the methods that the instances of that class can use and we can access it using `Class.prototype`.

## Adding methods to a prototype
Let's create a method called reverse to the String prototype that reverses the string:
```javascript
String.prototype.reverse = function() {
    let rev = "";
    for (let i = 0; i < this.length; i++) {
        rev = this[i] + rev;
    }
    return rev;
}
```
Now that will do the trick.
so the thing is that prototypes are also objects, and objects can have methods, so we attached the method reverse to the string prototype object, the this keyword inside the method will refer to the string we calling the method on.
now to use it we simply call it like any other method
```javascript
console.log("Hello".reverse()); //olleH
```
Now i don't know how would this be useful but i thought it's a cool thing to know!
OpenThyroo 🖥
Tags: csharp, angular, dotnet, opensource
Published: 2022-05-25 18:13:17


[OpenThyroo](https://github.com/HeyBaldur/OpenThyroo) is an open source project that allows users to interact with each other, ask questions, do business and communicate via messages internally. OpenThyroo is also a developer for those developers who want to participate in an open source project and gain experience for future jobs.

The project uses:
Angular 2+ in version 12 - FrontEnd
ASP.NET Core 3.1 Back End
Users can choose to use MySQL or MSSQL.
This project also comes with certain bugs which, thanks to everyone's collaboration, we can build a more robust and interesting platform. The code is totally thanks and free.

Characteristics of the project.
Posting of questions
Connection between users
Messaging between users (if they are contacts)
Business page
Interests between users and pages
Voting (likes/comments)
Groups
Marketing (like facebook)
Notifications (Like on LinkedIn, when someone views your profile or sends you a message)
If you like this project, don't hesitate to enter our slack and be part of the developer community, you can also follow me on twitter, follow my posts on dev.to, among others. If you want to learn, and get some extra experience, this open source project is for you.

✅ Improvements
✅ Bugs
✅ Growth
✅ Testing
Installation
Installation of the FrontEnd, open seed folder, and run

`cd thyroo-spa
npm install`
Once we have completed this process we can run

`ng serve -o`
Create a database in MySQL or MSSQL and run the first migration.

`dotnet ef migrations add InitialCreate`
Verify, your database contains the right information, if you need help with this process, please feel free to ask in our slack channel https://OpenThyroo.slack.com

After this, we can open .NET solution. You should be able to see everything just one click. you can navigate to.

`thyroo-api\thyroo-api
dotnet watch run`
Metaverse Gaming scripts
Tags: opensim, programming, secondlife, virtualeducation
Published: 2022-06-02 00:41:08

---
title: Metaverse Gaming scripts
published: true
date: 2022-05-25 18:00:15 UTC
tags: OpenSim,Programming,SecondLife,VirtualEducation
canonical_url: 
---

Hi everyone! The word ‘Metaverse’ is hot again so I’d like to invite you along on a journey I am taking down memory lane by re-immersing myself as an Educational Tool developer in the virtual world of Second Life and Opensim. This blog post will serve as the first part of a series of posts about the tools I am using to get the job done.

So let’s jump in and get ourselves a good code editor so we can hack away at some juicy LSL scripts! We could actually just use Second Life’s in-world editor, however using it is quite painful.  The text is small and hard to read, and there is on auto code completion! ![](https://b3dmultitech.com/wp-content/uploads/2022/05/in-world-script-engine.png)

For this task, I will download and install the [Eclipse IDE](https://www.eclipse.org/downloads/packages/) and then install the [LSL Forge](https://wiki.secondlife.com/wiki/LSLForge) plugin which will provide us the very handy code completion tool, so we won’t have to look up every LSL command

- Please download and install [Eclipse IDE](https://www.eclipse.org/downloads/packages/)
- Then click here to install the [LSL Forge](https://wiki.secondlife.com/wiki/LSLForge)  plugin

Once the LSLForge plugin is installed, your Metaverse Scripting experience will improve dramatically.

Here is what the editor looks like in comparison with the in-world editor displayed above:

[![Eclipse with LLSForge Plugin](https://b3dmultitech.com/wp-content/uploads/2022/05/eclipse-example-940x1030.png)](https://b3dmultitech.com/metaverse-gaming-scripts/eclipse-example/)

Good job!  Now, for fun, here is a script I created called valueKey.lslp.  Second Life’s version of the array is called a “list”.    This script will read through the list, and print it out as key value pairs.  Being able to store and retrieve key’s and values is an essential part when creating scripts with a even a moderate bit of logic and complexity.

Here it is:

 

```
keyValuesToString(list keyValues)
{ 
    integer index=0; 
    list records = llList2ListStrided(keyValues,0,-1,2); 
    integer length = llGetListLength(records); 
    llSay(0,"Length of records is : "+(string)length); 
    integer stride=2; 
    while (index < length) { 
      list item = llList2List(keyValues,index+index,index*stride+1); 
      string param = llList2String(item, 0); 
      string value = llList2String(item, 1); 
      llSay(0,(string)index+": key:"+param+", value:"+value); index++; 
   } 
} 
default { 
  state_entry() 
  { 
     llSay(0,"-----"); 
     list paramList=["name","fire","email","fire@b3dmultitech.com"]; keyValuesToString(paramList); 
  } 
}
```

 

Happy coding!

The post [Metaverse Gaming scripts](https://b3dmultitech.com/metaverse-gaming-scripts/) appeared first on [Paul Preibisch](https://b3dmultitech.com).
I am building a graphql dashboard builder with sveltekit.
Tags: svelte, graphql, discuss, javascript
Published: 2022-05-25 17:45:37

Still in very early development

Try it with your graphql endpoint ore use one of the available ones in one click. Please tell me what you think.

MOBILE ONLY. https://graphboarder.netlify.app/queries

Get in touch: development-vargamarcel development.vargamarcel@gmail.com
Simple REST API
Published: 2022-05-25 17:41:00

#DEMO: [Simple REST API](https://codesandbox.io/s/simple-restapi-mc4epc)

This example is mainly to present, use the functions of ES6 Classes to achieve API encapsulation and access of the same type ...

Source & Dependencies
- [REST API](https://reqres.in)
- [template7](https://v5.framework7.io/docs/template7)
- [lodash](https://lodash.com)
- [axios](https://axios-http.com/docs/intro)
- [sweetalert2](https://sweetalert2.github.io/) (css include fail :( )
Link Jupyter Notebook to Github
Tags: data, jupyter, python
Published: 2022-05-25 17:38:50

---
title: Link Jupyter Notebook to Github
published: true
description: A short guide on linking jupyter notebook to github. 
tags: #data #jupyter #python
cover_image: https://dev-to-uploads.s3.amazonaws.com/uploads/articles/3wrgrsbs7tet0nfptagd.png
---
This post will explore (and serve as a personal reference) for linking a jupyter notebook to github. This guide assumes you have a github account, basic knowledge of git and the command line, and is currently using Jupyter notebook. 

Firstly, spin up jupyter notebook using your CLI and this command:

```
jupyter notebook
```
This should bring you to the jupyter notebook interface as seen as the screenshot below:
<img src="https://dev-to-uploads.s3.amazonaws.com/uploads/articles/yddai854kc75kjtw2rgt.png">
Click the dropdown on the right, and select "Python 3". This will spin up the IDE, which you can then name appropriately. For this example, I copy pasted code from [W3Schools](https://www.w3schools.com/python/matplotlib_pyplot.asp).

The below screenshot is the result:
![jupyter notebook example code and accompanying visualization](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/7wkfad21khmx7e166wcm.png)

Great. Now we have the code. In Jupyter, go to "File" and go to "Download As:", select "Notebook"(.ipynb)

Now, sign into your github account, and create a new repository. On the Quick set up page select the "…or create a new repository on the command line" option
![Github repo setup options](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/h9sdgonrqw5mynmfj0e9.png)
Copy paste the code into your command line like so: 
![git command](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/uai0o179exjwq18bcvij.png)

Go back to github and refresh the page.
![Github add new files page](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/jzjs8hy8u7mkgqlgbq8r.png)
Select "Upload files".
Choose the file you've just downloaded from the jupyter gui and select "Commit changes". This will then take you back to the file screen where you can now click on the file you just uploaded. The screenshot below shows the final result. 
![Code and viz on github-final result](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/kcxtbcik3mecy0l34ky2.png)

Your jupyter notebook work is now shareable to others.
AWS Testing Service - DEVICE FARM
Published: 2022-05-25 17:30:51

###What is Device farm ?
  - Device Farm is a testing service from AWS.
  - Test native, hybrid and web applications on real Android and IOS device in the cloud.
  - Also test desktop browser apps using device farm.
  - AWS Device Farm supports native and hybrid Android, iOS, and web apps, and cross-platform apps.
  - Best part of AWS Device Farm is tests are run on real, non-rooted devices. The devices are a mixture of OEM and carrier-branded devices.
  - AWS Device Farm works on Internet Explorer 9 or later and the latest versions of Chrome, Firefox, and Safari.
  - Max file size is 4 GB applications will be allowed.
  **Device Farm is only available in the us-west-2 (Oregon) region.**

###Test automation framework supported for mobile

 Appium Java JUnit, Appium Java TestNG, Appium Python, Calabash, Instrumentation (Including JUnit, Espresso, Robotium, and any instrumentation-based tests), UI Automation, UI Automator, and XCTest (Including XCUI and KIF)

###Test automation framework supported for web application
 
 Selenium, Appium Java JUnit, Appium Java TestNG, or Appium Python.

###Test in Browsers 

 - Supports selenium scripts.
 - All browsers are hosted on EC2 Windows instances which run on Microsoft Windows Server.
 - Supports Chrome, FireFox, Microsoft - IE and Edge.

##_**Pricing :**_
 
**For desktop browsers :**
   - charged $0.005 per browser instance minute

**For Mobile device app :**
   - Standard rate of $0.17 per device minute.
   - Unlimited testing and remote access starting at $250 per month for both ios and android,  priced at $250 per slot per month. Device slots correspond to concurrency.
Mapping the African Tech Ecosystem
Tags: javascript, python, react, opensource
Published: 2022-05-25 17:22:34

The African Tech ecosystem is indubitably an exciting place to be in.

- Africa is the undisputed home of the mighty M-PESA. 

- Africa is experiencing exponential start-up funding growth - $4.65 billion in 2021

- Big tech is continuing to expand into Africa 

Let's explore the different facets of the African tech space. Read more: https://www.dzemo.com/blog/mapping-the-african-tech-ecosystem #growth #tech #africa #funding
Azure Static Web Apps CLI is now GA (global access)
Tags: azure, javascript, tutorial, webdev
Published: 2022-05-25 17:15:55

---
title: Azure Static Web Apps CLI is now GA (global access)
published: true
description: Use Azure Static Web Apps CLI for your SWA projects, work locally, simulate production and deploy.
tags: azure, javascript, tutorial, webdev
cover_image: https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qecnsmj80sr8mjtu0wko.png
---

## What is Azure Static Web Apps or SWA (Static Web Apps)

Azure Static Web Apps is a service that's perfect for your full stack as well as static files projects. Yes, you heard that correctly. Regardless if you are dealing with
- A static resume site 
- SPA application
- Static site generator like Gatsby etc

Azure Static Web Apps is there for you and enables you to deploy your files to Azure.

> how does that work?

When you create an Azure resource, it connects your GitHub repo to Azure via workflow file in yaml. This ensures that all your future work can be pushed to Azure with nothing but Git and GitHub.

> https://azure.microsoft.com/en-us/services/app-service/static/

Sounds like it's worth trying? If, so have a look at these resources
- https://docs.microsoft.com/en-us/learn/paths/azure-static-web-apps/
- https://docs.microsoft.com/en-us/azure/static-web-apps/overview

## What is Azure Static Web Apps CLI?

It's a CLI you run from your console. With it, you can do a lot of things like the below:

- 🔥 Work on your JAMstack app locally
- 🔥 Built-in framework detection
- 🔥 Serverless support
- 🔥 Authentication & Authorization
- 🔥 Login to Azure
- 🔥 Deploy & Ship from the CLI
- 🔥 New documentation site

Check it out, how it can accelerate your workflow building SWA apps :)

> https://github.com/Azure/static-web-apps-cli
Benchmarking Python JSON serializers - json vs ujson vs orjson
Tags: python, json
Published: 2022-05-25 17:12:15

## Introduction

If you work with a large datasets in json inside your python code, then you might want to try using 3rd party libraries like [ujson](https://github.com/ultrajson/ultrajson)and [orjson](https://github.com/ijl/orjson) which are replacements to python’s json library.

As per their documentation

- [ujson](https://github.com/ultrajson/ultrajson) (UltraJSON) is an ultra fast JSON encoder and decoder written in pure C with bindings for Python 3.7+.

- [orjson](https://github.com/ijl/orjson) is a fast, correct JSON library for Python. It is the fastest python library for json encoding & decoding. It serializes dataclass, datetime, numpy, and UUID instances natively.

## Benchmarking

I did a basic benchmark comparing json, ujson and orjson. The benchmarking results were interesting.

```python
import time
import json
import orjson
import ujson

def benchmark(name, dumps, loads):
    start = time.time()
    for i in range(3000000):
        result = dumps(m)
        loads(result)
    print(name, time.time() - start)

if __name__ == " __main__":
    m = {
        "timestamp": 1556283673.1523004,
        "task_uuid": "0ed1a1c3-050c-4fb9-9426-a7e72d0acfc7",
        "task_level": [1, 2, 1],
        "action_status": "started",
        "action_type": "main",
        "key": "value",
        "another_key": 123,
        "and_another": ["a", "b"],
    }

    benchmark("Python", json.dumps, json.loads)
    benchmark("ujson", ujson.dumps, ujson.loads)

    # orjson only outputs bytes, but often we need unicode:
    benchmark("orjson", lambda s: str(orjson.dumps(s), "utf-8"), orjson.loads)

# OUTPUT:
# Python 12.502133846282959
# ujson 4.428200960159302
# orjson 2.3136467933654785

```

> [ujson](https://github.com/ultrajson/ultrajson) is 3 times faster than the standard json library

> [orjson](https://github.com/ijl/orjson) is over 6 times faster than the standard json library

## Conclusion

For most cases, you would want to go with python’s standard json library which removes dependencies on other libraries. On other hand you could try out [ujson](https://github.com/ultrajson/ultrajson)which is simple replacement for python’s json library. If you want more speed and also want dataclass, datetime, numpy, and UUID instances and you are ready to deal with more complex code, then you can try your hands on [orjson](https://github.com/ijl/orjson)
Day-94 Training At Ryaz
Tags: javascript, webdev, beginners, programming
Published: 2022-05-25 17:11:49

- Date:25/05/2022
- Day:Wednesday

Today, I started at about 10:30 am as I was in progress to complete the java script cource and the bidding project so, today I started with the left over part and firstly I started with bidding project firstly I did some changes in the frontend part as when we login in the project so, we see an screen as no items in the queue so, I felt this starting as simple so, I added the image in the home page which enhance the bidding site and after this I changed some of the heights and width adjustments and after this I changed the login window padding and after this I observed that the sign in and sign out and home and profile are in same line so I seprated them as I did the sign in and sign out at right most to look better so, this way my day ended up and I got to learn many new things.
If you're a Tech interviewer .. what's the quality you search the most in the interviewee ?
Tags: discuss, career, webdev, watercooler
Published: 2022-05-25 17:08:29

If you're a Tech interviewer .. what's the quality you search the most in the interviewee, beside problem solving techniques, analytical mindset and good knowledge of the tool/technology/programming language you're hiring for .. ?

Subscribe in Bek Brace YT Channel
https://www.youtube.com/bekbrace

Join Bek Brace Page @bekbraceinc
https://www.facebook.com/bekbraceinc

Insagram
https://www.instagram.com/bek_brace/

DEV
https://dev.to/bekbrace
React should change the documentation to React Hooks
Tags: discuss, javascript, webdev, programming
Published: 2022-05-25 16:41:20

React Hooks came out around 4 years ago, and almost any React project made today uses functional components and hooks instead of the class-component model.

![functional component](https://miro.medium.com/max/1102/1*HOuxJqyY4_6kXohawnUdxA.png)

If we go to [React's documentation](https://reactjs.org/docs/handling-events.html) a lot of explanation is done using class components, and they don't introduce hooks in the **Main Concepts** section, don't even mention it in the [handling events](https://reactjs.org/docs/handling-events.html) page.

I think that mixing functional and class components can be misleading and confusing to anyone that wants to learn React as a first JS framework, also frameworks like [NextJS](https://nextjs.org/learn/basics/navigate-between-pages/link-component) made all the documentation using Functional Components.

I'm not saying that people shouldn't learn how to use class components, all the react projects that came out more than 4 years ago use them, but when I learned React some years ago I encounter this issue.

Would you change something about the documentation?