teleren/devto huggingface dataset:
A11y with Ben Myers
Tags: webdev, javascript, beginners, podcast
Published: 2022-09-12 13:23:01


Original: https://codingcat.dev/podcast/2-38-a11y-with-ben-myers

{% youtube https://youtu.be/pnRUoW2OZOU %}

## Questions

1. Tell us about yourself Ben?
2. Has accessibility always been important and we just keep dropping the ball? Or was it the famous Domino’s case where they excluded people with disabilities from using it’s website?
3. A11y is a [Numeronym](https://en.wikipedia.org/wiki/Numeronym)!
4. What are some good tools to use to check for accessibility?
5. What things are included in A11y? 
  1. Color Contrast  
      1. [Contrast Checker](https://www.notion.so/160cd5bd1ef14296ae79f113a10dcbcd)
    2. [Another Contrast Checker](https://app.contrast-finder.org/)
    3. [Axe](https://github.com/dequelabs/axe-core)
    4. [Color Contrast Post](https://benmyers.dev/blog/fix-low-contrast-text/)
    5. [Contrast Finder](https://app.contrast-finder.org/)
  2. Only use a website with Keyboard
      1. Tab order
    2. [skip to content](https://accessibility.oit.ncsu.edu/it-accessibility-at-nc-state/developers/accessibility-handbook/mouse-and-keyboard-events/skip-to-main-content/)
6. What is Aria? A filler for your markup. 
  1. [Ben Meyers on What is Aria](https://benmyers.dev/blog/aria/)
  2. [Accessibility Tree](https://www.notion.so/Ben-Myers-d5cee3c690db477f99108d9c14ae2fe5)
7. Alt tags, do you describe decorative images?  
  1. Telling a story of the image.
  2. Convey the message, but also the tone.
  3. Not where it isn’t relevant.
  4. If you don’t need alt text, use `alt=""`.
8. Since you work on Microsoft Docs, what are they doing to help assist those who use Docs in a non-traditional way?

> In the United States, 61 million adults are living with a disability, according to current [federal data](https://www.cdc.gov/ncbddd/disabilityandhealth/infographic-disability-impacts-all.html) . A [2017 National Health Interview Survey](https://www.afb.org/research-and-initiatives/statistics/adults) found that 26.9 million people in the United States (10% of adult Americans) reported experiencing vision loss. An estimated 15% of American adults (37.5 million) reported some trouble hearing, according to a [2012 National Health Interview Survey](https://www.nidcd.nih.gov/health/statistics/quick-statistics-hearing) .

### Links

[Inaccessible Recipe List Site](https://inaccessible-recipes.netlify.app/) - [Repo](https://github.com/BenDMyers/inaccessible-recipe-list)

[https://blog.codinghorror.com/falling-into-the-pit-of-success/](https://blog.codinghorror.com/falling-into-the-pit-of-success/)

[https://en.wikipedia.org/wiki/Spherical_cow](https://en.wikipedia.org/wiki/Spherical_cow)
Introducing the On-Call Me Maybe Podcast!
Tags: observability, oncall, devops, news
Published: 2022-09-12 13:18:43


Y’all, I am so excited to announce that [Ana Margarita Medina](https://twitter.com/Ana_M_Medina) and I just launched the [On-Call Me Maybe podcast](oncallmemaybe.com)! This podcast is dedicated to nerding out on all things DevOps, SRE, Observability, On-Call, and everything in between. Want to learn more? Then read on, my friend!

## Your most awesome hosts

Ana and I met when we both joined Lightstep as Developer Advocates in April of this year, and though we haven’t known each other for very long, we are very much partners in crime. 

I’m super excited about this collaboration because Ana is a fellow Latina in tech. Being in a male-dominated industry, it’s been beyond super cool to work with a fellow tech gal from a similar cultural background. I was originally born in Rio de Janeiro, Brazil, and moved to Canada when I was 10. Ana hails from Costa Rica, and her parents are from Nicaragua. She moved to the US when she was in elementary school. We bring some of the flair of our respective backgrounds to this podcast. 😎

## Our guests

We want to use this podcast as a platform for nerdy tech discussions, sociotechnical systems, mental health, and diversity & inclusion…and our guests reflect that!  We want to connect our audience with folks from all walks of tech. You’ll hear from some familiar faces, and some not-so-familiar faces. Our conversations are fun and casual, with chill vibes all around. 

## Give us a listen!

Our [first episode](https://oncallmemaybe.com/episodes/tech-origin-stories) dropped on **September 6th**. It features a conversation between Ana and me, as we talk about our beginnings in tech. We’ll be coming at you with new episodes on a weekly basis. You’ll be hearing from folks at [Honeycomb](honeycomb.io), [Jeli](jeli.io), [ThoughtWorks](thoughtworks.com), [HashiCorp](hashicorp.com), [Wavelo](wavelo.com), and more! We’ve also got a couple of guest hosts, including [Alex Boten](https://twitter.com/codeboten) and [Ted Young](https://twitter.com/tedsuo).

So what are you waiting for? Be sure to give us a listen, follow [On-Call Me Maybe](oncallmemaybe.com) on [Twitter](twitter.com/oncallmemaybe), follow our [LinkedIn](linkedin.com/company/on-call-me-maybe-podcast) page, and subscribe via your favourite podcasting app!

Peace, love, and code. 🌈 🦄 💫
Admission controllers for policy enforcement - motivation and theory
Tags: kubernetes, policy
Published: 2022-09-12 13:18:35

##### What are they?
Admission controllers are gates that validate (or mutate) incoming API requests before persisting them onto etcd.

**Context**
After the authentication module has established the identity of the user, the authorization module is consulted in order to determine whether the user is allowed to perform the request. The authorization module does this by asking all the _authorizers_ configured to run inside of the module. This query, sent to each authorizer in the order they appear in the configuration, is called a SubjectAccessReview.

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

RBAC policies are not expressive enough to specify business rules on the requests and users identified by the AuthN agent. This is where admission controllers can help. There are two types of admission controllers in kubernetes.
###### Compiled-in admission controllers
	These are compiled into the `kube-apiserver` binary, and may only be configured by the cluster administrator.
Enabling or disabling them is through:
```shell
kube-apiserver --enable-admission-plugins=NamespaceLifecycle,LimitRanger ...
# --disable-admission-plugins to disable
```
Listing the currently enabled ones can be done through
```shell
kube-apiserver -h | grep enable-admission-plugins
```
While they are very powerful and useful, they have three limitations:
- kube-apiserver needs a restart when they are to be (re-)configured
- configurations only possible by a cluster administration who has an OS level access
- extending them is not possible

[Detailed documentation](https://kubernetes.io/docs/reference/access-authn-authz/admission-controllers/)

###### Dynamic admission controllers
These are admission plugins can be developed as extensions and run as webhooks configured at runtime. Admission webhooks are HTTP callbacks that receive admission requests and do something with them. You can define two types of admission webhooks, [validating admission webhook](https://kubernetes.io/docs/reference/access-authn-authz/admission-controllers/#validatingadmissionwebhook) and [mutating admission webhook](https://kubernetes.io/docs/reference/access-authn-authz/admission-controllers/#mutatingadmissionwebhook). Mutating admission webhooks are invoked first, and can modify objects sent to the API server to enforce custom defaults. After all object modifications are complete, and after the incoming object is validated by the API server, validating admission webhooks are invoked and can reject requests to enforce custom policies.

[Kubernetes documentation](https://kubernetes.io/docs/reference/access-authn-authz/extensible-admission-controllers/#initializers)
10 RANSOMWARE PREVENTION AND RECOVERY TIPS
Tags: cybersecurity, cybersecop
Published: 2022-09-12 13:08:52

The new head of the FBI’s San Antonio office stated that ransomware attacks in particular have skyrocketed as more of us work and go to school from home. And when it comes to ransomware, the FBI focuses on critical infrastructure: anything that involves national security or the economy.

“We don't advise companies to pay ransoms,” Rich says. “However, even if they do, we still ask them to let us know what's happening because if they report it to us, and report it to us early, we can help identify who the threat actor is.”

10 RANSOMWARE PREVENTION AND RECOVERY TIPS 
Quick steps you can take now to PROTECT yourself from the threat of ransomware:


1. Use antivirus software at all times
Set your software to automatically scan emails and flash drives.

2. Keep your system patched and up to date 
Run scheduled checks to keep everything up-to-date.

3. Block access to the ransomware site
Use security products or services that block access to known ransomware sites.

4. Restrict Application
Configure operating systems or use third-party software to allow only authorized applications on computers.

5. Restrict personally owned devices on work networks
Organizations should restrict or prohibit access to official networks from personally-owned devices.

6. Restricting Administrative Privileges
Use standard user accounts vs. accounts with administrative privileges whenever possible.

7. Avoid using personal applications
Avoid using personal applications and websites – like email, chat, and social media – from work computers.

8.  Beware of Unknown sources 
Don't open files or click on links from unknown sources unless you first run an antivirus scan or look at links carefully.

RANSOMWARE READINESS RECOVERY TIP
  Steps you can take now to help you RECOVER from a future ransomware attack:

9. Have An Incident Response Plan
   Develop and implement an incident recovery plan with defined roles and strategies for decision making. 2 Carefully plan, implement, and test a data backup and restoration strategy – and secure and isolate backups of important data. Have a team of incident response professionals on retainer to quickly respond in the event of a breach. 

10. Have Backup & Restore Capability 
  Create a business continuity plan, and maintain an up-to-date list of internal and external contacts for ransomware attacks, including law enforcement.

**Recovery Strategies**

**Business impact analysis**

There is a lot more not covered in this article like incident response tabletop exercise, ransomware negotiation, and ransomware payment.

[Read more](https://cybersecop.com/news/2022/9/9/ransomware-prevention-and-recovery-tips)
The best apps for Windows and Mac
Tags: cloud, app, comparison
Published: 2022-09-12 13:03:53

Information management has become a challenge for users and companies due to a need to increase storage space. In response to this need, cloud services have emerged, which help us store the data we need quickly and easily. The cloud gives users the opportunity to store information from a laptop or mobile phone on platforms owned by large companies such as Google or Amazon. That's why you won't need to use your own hard drive.

But what do you do when you have more than one cloud storage service and are looking to manage both? You use an app that can manage all of your favorite platforms in one place. Today we’re going to review and compare two of the most popular Mac and Windows applications: CloudMounter vs Rclone. Applications have fundamentally different interfaces, while both support similar operations. For more detail, you can read this article:
https://cloudmounter.net/compare-cloudmounter-vs-rclone/
How to Setup Postman with Laravel Project
Published: 2022-09-12 13:00:12

Postman is an API platform for developers to design, build, test and iterate their APIs. Often, postman has been an essential API tool for developers.

As a Laravel developer, it is advisable you know how to work in postman while building your projects.

In this content, I'm going to be listing simple clear steps on how to can communicate with your laravel project through postman.

**Step 1**
**Own a Postman Free Account**

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

Create a free postman account by visiting [POSTMAN](https://www.postman.com/) or click on [signup for postman](https://identity.getpostman.com/signup).

**Step 2**
**Create a Workspace and Collection**

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/5ugrsa6mywp39g4ojzy0.PNG)

You can choose any preferred name as your workspace name.

**Create Collection**

After you are done creating a workspace, it is advisable you create a Collection with any preferred name of your choose as indicated below.

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


**Step 3**
**Download and Install Postman Agent**
To download postman desktop agent, click [DOWNLOAD](https://www.postman.com/downloads/postman-agent/), after downloading, don't forget to install it.


**Step 4**
**Working with Laravel**

If you've already setup your laravel project, follow the codes blocks to setup and test your connection.

Create a route on `route` -> `api.php` 

```
Route::post('test_data', [TestController::class, 'test_data'])->name('api.test_data');
```

Goto your controller and create a function according to your the name used in `api.php` route.

```
 public function test_data(Request $request)
    {
        return $request;
    }
```

Next thing is to serve your project by running `php artisan serve` on your terminal, copy the link and lets move to the next step.

**Step 5**
**Testing the Connection**


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


Add a request by clicking the `add a request` as shown on the image above.

Now, you can now paste the copied link, after we served the project on terminal and click on "send".


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

If it return and empty array [] for you, it means you got it right.


We can decide to send a extra parameter as request and return the response from you controller.


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

If you got similar results as mine on the screenshot above, congratulation.
Crypto Leverage & Margin Trading Exchange Software
Tags: blockchain, javascript, webdev, cryptocurreny
Published: 2022-09-12 12:19:04

Crypto leverage trading is margin trading approach that is used by traders in crypto markets to get maximize profits. So most of the crypto traders are interested to invest their margin trading process. While compare to spot trading, margin trading requiring putting digital assets up as collateral to increase purchasing power. Professional traders can borrow funds to engage in margin trading on Popular crypto leverage & margin trading platforms like Binance. If you are an aspiring entrepreneur who want to start their crypto leverage & margin trading platform then you are in the right place.

**What is Crypto Leverage & Margin Trading Exchange Software?**

Crypto leverage and margin trading exchange software is a 100% multi-tested and whitelabel crypto leverage and margin trading software solutions that helps to launch cryto leverage platform within 10 days. Hivelance offers whitelabel crypto leverage and margin trading software that comes with  exclusive features and enhanced security.

**Create your feature-rich and robust Crypto leverage and margin trading exchange platform!!!**

Hivelance is the top-notch **[Crypto leverage and margin trading exchange development company](https://www.hivelance.com/crypto-margin-trading-exchange-development)** having a pool of skilled developers to bestow a feature-rich exchange platform. We are particular in offering a fully regularized and hassle-free functioning exchange for buying/ selling cryptocurrencies. Our front-end and back-end developers are expertise in discovering the platform with no defects. Vulnerability tests will be performed for testing the exchange for proper functioning. As we are the market’s best crypto exchange platform developers, we can guarantee you in providing the security of the platform at the highest level.

**Key Features of White Label Cryptocurrency Leverage & Margin Trading Exchange Software**

High-end security
Advanced order types
Multiple cryptocurrencies support
Powerful trading engine
Robust admin panel
Trading history display
Attractive themes, backgrounds, and add-on features

Ready to build High-ROI generating Cryptocurrency Leverage & Margin Trading Exchange Platform Using Our Ready-made Crypto Leverage & Margin Trading Exchange Software?

We develop and deliver highly-secure **[crypto leverage and margin trading exchange software](https://www.hivelance.com/crypto-margin-trading-exchange-development)** integrated with robust features such as- SSL implementation, encrypted user access, two-factor authentication, automatic limits on fund withdrawal, and other security features. Create own leverage & margin trading exchange with Hivelance today.
Generating Customizable Mock Data with a Fluent Interface
Tags: javascript, test, mock, data
Published: 2022-09-12 12:45:33

---
title: Generating Customizable Mock Data with a Fluent Interface
published: true
description: A flexible tool for generating customizable mock data with a fluent interface
tags: javascript, test, mock, data
# cover_image: https://i.imgur.com/qLGGhTh.jpg
# Use a ratio of 100:42 for best results.
---

I just published a mock data library for javascript [fluentfixture](https://github.com/fluentfixture/fluentfixture).

## Why we made this?
Generating mock data is hard, and customizing the fake data is more challenging. Libraries like Faker provide rich and realistic data but lack fluent interface and extensibility. In this project, we aim to provide programmability and extensibility.

## An E-Commerce Scenario

Create ten products. Each product's barcode must be similar to ids. Sort the products by id.

```typescript
import { alphabetic, int, obj, pick } from '@fluentfixture/core';

const price = obj({
  amount: int(1, 100),
  currency: pick(['USD', 'EUR', 'GBP', 'TRY']),
});

const product = obj({
  id: int(100, 999),
  name: alphabetic(10).capitalCase(),
  price
});

const productWithBarcode = product
  .lazy('barcode', (p) => `##${p.id}`);

const products = productWithBarcode
  .array(10)
  .sort((p1, p2) => p1.id - p2.id);

console.log(
  products.single(),
);
```

## Links

Thank you for feedback and contributions :)

- [Code](https://github.com/fluentfixture/fluentfixture)
- [Docs](https://docs.fluentfixture.com/)
- [Sample for format package](https://codesandbox.io/s/github/fluentfixture/fluentfixture/tree/main/sample/01-format)
- [Sample for core package](https://codesandbox.io/s/github/fluentfixture/fluentfixture/tree/main/sample/02-core)
Python - If Else in List Comprehension
Tags: python, beginners, tutorial
Published: 2022-09-12 12:27:44

In this tutorial, we will look at how to create a list using a list comprehension that uses an if else logic to decide the final list values.

[List comprehensions](https://datascienceparichay.com/article/python-list-comprehension-with-examples/) offer a concise way to create lists in Python and are particularly useful when creating lists using other iterables, filtering lists, etc.

Let's say you have a list, say `ls` of integers 1 to 10 (both inclusive) and you want to create a new list, say `new_ls` that contains the string "odd" or "even" depending on whether the corresponding value in `ls` is odd or even. 

Using a list comprehension can be a valid approach for such cases. 

## How to use `if else` logic inside a list comprehension in Python?

Use the following syntax to incorporate an `if else` logic inside a list comprehension.

```python
new_ls = [expression if condition else other_expression for member in iterable]
```

Here, for each `member` in the `iterable` we are checking for our `condition` which if it evaluates to `True`, we use the value resulting from `expression` otherwise we use the value resulting from `other_expression` as our resulting value in the list comprehension. 

Let's now look at an example.

Let's create a list with string values "odd" and "even" for corresponding value in the `ls` list.

```python
# list of integers from 1 to 10
ls = range(1, 11)
# create list using list comprehension
new_ls = ["odd" if num % 2 != 0 else "even" for num in ls]
print(new_ls)
```
Output:

```
['odd', 'even', 'odd', 'even', 'odd', 'even', 'odd', 'even', 'odd', 'even']
```

We get a list with "odd" and "even" values. For example, for the value `4` in the list `ls`, its corresponding value in the list `new_ls` is "even"

## Filter values with `if` in list comprehension

Note that you can also just use the `if` statement (without the `else` part) inside the list comprehension. This is commonly used when filtering lists. 

Use the following syntax to use just the `if` construct inside a list comprehension.

```python
new_ls = [expression for member in iterable if condition]
```
Here, for each `member` in the `iterable` we are checking for our `condition` which if it evaluates to `True`, we use the value resulting from `expression` as our resulting value in the list comprehension otherwise we don't do anything (skip that member).

For example, let's filter the above list of integers `ls` to create a new list with only odd integers. 

```python
# list of integers from 1 to 10
ls = range(1, 11)
# create list of odd values in ls using list comprehension
odd_ls = [num for num in ls if num % 2 != 0]
print(odd_ls)
```
Output:

```
[1, 3, 5, 7, 9]
```
We get a list of only the odd numbers in `ls`.
Get advice while stuck on a project
Tags: java, discuss, help, webdev
Published: 2022-09-12 12:21:53

Hi,

Not sure if this is the correct place to ask or not, but said I would try!
I am creating a web app using a quarkus server, I am at a part of the app where I want my users to have an option of uploading files. There is a million+ tutorials on that and I am not stuck on that part.

What I am having trouble is I don't want to just upload a file, I want to upload a file with with extra information too, such as the name, description, expiry date, if it's required etc. Now this is something I can't seem to find anywhere and I am not sure where to go with this.

I dunno if the file is uploaded in it's own call and then the object is uploaded. Seems like a lot to me tbh.

Also with file management, is it better to save the file to the db or is it better to save it in a location on the server and then attach the path to the object saved in the db? 

Really need help on this as I am stuck and haven't a clue.

TL;DR
Want to upload file over REST endpoint but also include other properties external to the file, like expiry date, required etc.