teleren/devto huggingface dataset:
What can a pg_ba_admin do and what they can't
Tags: postgres, database, methods, functions
Published: 2023-10-25 08:20:52

Now we will discuss what a pg_ba_admin role can do, and what actions are out of the reach of the user with this role.

What can a pg_ba admin role do:
A user with a pg_ba_admin role can perform many operations typically reserved for the Postgres superuser. For example, they can:
- Create roles
- Create Databases
- Create, modify, and delete any non-superuser role which also includes the setting of passwords.
- SET Another role for any user except the superuser without the need for a password.
- Read the data from all the Postgres system catalogs in pg_catalog.
- Read and write to all user objects such as tables, views, etc.
- Perform all monitoring functions on the Postgres instance.
- Install supported extensions for EDB.
- Grant pg_checkpoint role to itself and to other users.

What a pg_ba_admin can't do:
There are certain roles and actions that can't be performed by pg_ba_admin. Some of them are mentioned below:
- Can't execute programs on the server. 
- Can't Create tablespaces, casts, operator classes, access methods, and text search templates.
- Can't read or write files on the server. pg_ba_admin does not have permission to read or write server files.
- Can't Define LeakProof functions.
- Can't install unsupported extensions.
- Can't execute set session authorization.
- Can't execute reindex system catalogs.
- Can't create a language with custom handlers.
Simplify your API development with Aex
Tags: aex, typescript, node, webdev
Published: 2023-10-25 08:30:25

# Aex API Development Support

## Aex currently support restful api and vig api

1. Restful API for resources state representation
2. Vig API for Business logic manipuliation

the usage similar with decorator @rest and @api.
Which means @api is a recommendded api for most applications which is suitable for business logic.

### @rest

@rest decorator can help directing every request into a certain method according to its http method and with default body parser.

It is very simple to use just like other aex handlers:

```ts
class Rest {
  public async get(ctx: any) {}
  public async post(ctx: any) {}
  public async put(ctx: any) {}
  public async patch(ctx: any) {}
  public async delete(ctx: any) {}
  @rest("/rest/api")
  public api(ctx: any) {
    ctx.res.end("Rest API !");
  }
}
```

currently only five http methods(`get`, `post`, `put`, `patch`, `delete`) are allowed.

### @api

@api decorator only supports `get`, `post` http methods. `get` is used for information fetch with changing anything, `post` is used for any business action may potantially change something.

the usage is very similiar except the http post request is force to have a field called `action`, which is the business action.
Actions can be any string and you should write corresponding method to handle that action. (Actions are case sensitive.)

for example, we need to write an api for user, we can define an api with @api like the following:

```ts
class UserAPI {
  public async register(ctx) {}
  public async login(ctx) {}
  public async logout(ctx) {}
  public async remove(ctx) {}
  public async update(ctx) {}

  @api("/user")
  public api(ctx: any) {
    ctx.res.end("VIG API");
  }
}
```

by sending `action`, the decorator will automatic route your request into corresponding method.

Further infomation and update about vig api can be found here:
https://github.com/calidion/vig-api

these decorators will be enhance overtime, and you can file a feature request any time.

basic aex usage can be found in README file:
https://github.com/calidion/aex
Placeholder Contributor
Tags: hack23contributor
Published: 2023-10-25 08:28:48

<!-- ✨This template is only meant to get your ideas going, so please feel free to write your own title, structure, and words! ✨ -->

### Intro
<!-- Share a bit about yourself as a contributor. Is this your first Hacktoberfest, or have you contributed to others? Feel free to embed your GitHub account by using {% embed LINK %} -->

### Highs and Lows
<!-- What were some of your biggest accomplishments or light-bulb moments this month? Did any problems come up that seemed impossible to fix? How did you adapt in those cases?  -->

### Growth
<!-- What was your skillset before Hacktoberfest 2023 and how did it improve? Have your learning or career goals changed since working on these new projects? -->
Placeholder Maintainer
Tags: hack23maintainer
Published: 2023-10-25 08:28:36

<!-- ✨This template is only meant to get your ideas going, so please feel free to write your own title, structure, and words! ✨ -->

### Intro
<!-- Share a bit about yourself as a maintainer. Is this your first Hacktoberfest, or have you maintained in others? Feel free to embed your GitHub account by using {% embed LINK %} -->

### Project
<!-- Tell us about the repository that you hosted. What processes did you set up to review and merge pull requests? Feel free to embed your GitHub repo by using {% embed LINK %} -->

### Highs and Lows
<!-- What were some of your biggest accomplishments or light-bulb moments this month? Did any problems come up that seemed impossible to fix? How did you adapt in those cases?  -->

### Growth
<!-- What was your skillset before Hacktoberfest 2023 and how did it improve? Have your project goals changed since publicly maintaining it? -->
Best Industrial Valves Manufacturer
Tags: industrial, valve, manufacturer, supplier
Published: 2023-10-25 08:28:27

[Focet Valves Pvt. Ltd.](https://focetvalves.in/) Manufacturer and Exporter of [Industrial Valves](https://focetvalves.in/) in Gujarat, We Manufacturing  Gate Valves, Pulp Valves, Globe Valves, Sight Glass, Pinch Valves, Check Valves, Steam traps, Non-Return Valves, and other products. These goods are made from premium raw materials that are purchased from reputable industry suppliers. The items on offer are carefully made in accordance with established industry standards and are offered in a variety of specifications to meet the individual demands of customers. We are the Best Distributor of high quality industrial valves in Gujarat

![Image description](https://dev-to-uploads.s3.amazonaws.com/uploads/articles/lzr3ui8c666174czdf22.jpeg)
best dermatologist in varanasi
Tags: dermatologist, skincare, skinclinic, femaleskindoctor
Published: 2023-10-25 08:04:46

This marks the commencement of an extraordinary journey into the world of skin care. Dr. Garima, in combination with the state-of-the-art services offered at Skin Savvy Clinic, guarantees an unmatched experience. Whether you're seeking solutions for your skin concerns, or if you're simply intrigued by the captivating realm of dermatology, stay with us. We're on the verge of delving deeper into the clinic's array of services and Dr. Garima's exceptional expertise. Your journey towards achieving healthier, more radiant skin begins right here. Join us as we unravel the enchantment of Skin Savvy Clinic and the brilliance of Dr. Garima.
How Project IDX by Google Will Revolutionize Cloud-Based Coding and Development
Tags: google, flutter, webdev, projectidx
Published: 2023-10-25 08:04:35

I recently came across this amazing Project namely Project IDX, Google’s new project that aims to revolutionize cloud-based coding and development. Doesn't it make you excited? If not let me tell you why you should be excited about it.

Project IDX is a web-based IDE (Integrated Development Environment) that runs on Google Cloud and is powered by **Codey**, an AI model trained on code. It lets you build, manage, and deploy full-stack web and multiplatform applications using popular frameworks and languages, such as Angular, **Flutter**, React, Vue, JavaScript, Dart, and more.

What makes Project IDX so amazing is that it simplifies the entire development workflow, from setting up your project to testing and deploying your app. You don’t need to install anything on your machine or worry about compatibility issues. You can access Project IDX from any web browser and any device, and collaborate with your team in real time. Which make it **Easy** for the Developers who cant afford high end Machines 😁.

But that’s not all. Project IDX also leverages the power of generative AI to help you code faster and smarter. Codey, your AI coding assistant, can suggest code snippets, fix errors, and even generate solutions to common coding challenges. You can also preview your app across platforms, using the built-in web preview and the upcoming Android emulator and iOS simulator.

Project IDX is still in an early stage of development, but it’s already showing great potential to transform the way we create applications. I’m looking forward to trying it out and seeing what it can do.

If you want to know more about this Project you can watch this youtube Video by Google [link](https://youtu.be/-wlZY4tfGMY?si=P1r2T4FTfi2TgOir)

Do comment your Thoughts on this project In the comment section below. Happy Coding 👨🏼‍💻.
Ruby on Rails password validation
Tags: security, rails
Published: 2023-10-25 07:57:53

If you ever went through a PCI, ISO 2007, SOC2, or similar compliance questionnaire, you found the following question in one form or another:

### Use sufficiently strong and robust authentication methods to protect authentication credentials from being forged, spoofed, leaked, guessed, or circumvented.

Let's see what we need to do to satisfy this requirement.

First of all, you must have a **strong password policy**.<br/>
I recommend asking for a minimum of 12 characters, with at least one uppercase letter and one number.

You can use Active Record validations for this. If you have a password attribute on your model, you can add a validation similar to this example:

```ruby
validate :password_complexity

def password_complexity
  if password.present? and !password.match(/^(?=.*[a-z])(?=.*[A-Z])(?=.*\d).{12,}$/)
    errors.add :password, "must include at least one lowercase letter, one uppercase letter, one digit, and needs to be minimum 12 characters."
  end
end
```

Additionally, you should validate that the password is not leaked. Luckily, there is a gem for that: <a href="https://github.com/philnash/pwned" target="_blank">https://github.com/philnash/pwned</a>.<br />
After installing the gem, All you need to do is add the following validation to the model:

```ruby
  validates :password, not_pwned: { on_error: :valid }
```

This will make a request to haveibeenpwned.com, mark the password as invalid if it has been pwned, and mark it as valid in case of a network or API error. You can find information about various configurations in the readme of the gem.

The final thing to prevent is credentials leaking. For this, you should store the passwords hashed with a robust hashing algorithm such as bcrypt.
Magnis ad asperiores porttitor, eu magnis
Published: 2023-10-25 07:45:07

Magnis ad asperiores porttitor, eu magnis imperdiet, maxime aliquip eu, aliquip mollitia veniam numquam, incidunt tortor occaecat platea. Cillum quis justo! Doloremque, class voluptas. Ipsum cubilia explicabo pariatur! Accumsan facilis! Rem hendrerit pede dicta fugit mi, repellendus, nonummy repudiandae doloremque rutrum aliquip? Senectus dolorum dignissim feugiat tincidunt viverra, bibendum inventore lobortis tempore! Nostra aptent, molestias sed mi dicta earum ac illum nostrum rem quia, scelerisque? Cupidatat qui debitis fusce bibendum, ullamco massa, quaerat quaerat. Labore, impedit corrupti eveniet placerat nisl exercitation purus, incididunt mi, interdum aenean reiciendis, dui adipisci at? Corporis odio aenean. Suspendisse hymenaeos minim eum phasellus. Fames maxime.

Placerat praesentium, ullamcorper officiis nam ea nonummy deleniti habitant malesuada fuga quisque! Illum rem aute malesuada? Nonummy natoque. Diam wisi mus inventore, velit eveniet fermentum eveniet torquent, habitasse? Pharetra consequat? Vero vulputate? Fringilla! Fermentum pulvinar, curabitur egestas in maiores rhoncus vestibulum! Aliquid, laborum eius doloremque? Non eget minima cursus recusandae? Odio ad molestias vivamus? Ipsum! Conubia, magnis tempore orci fugit, cillum ducimus, distinctio commodo qui sed dolorum iure, asperiores vitae nostra quisque rutrum porttitor dictumst odio magni eius quisquam autem! Minus blandit adipiscing. Assumenda, voluptates arcu, unde eligendi pariatur impedit temporibus? Culpa veniam eum consectetuer cupiditate officia diamlorem! Excepteur lectus.

Eleifend habitasse dolores aut et nonummy nam molestie repellendus sint tincidunt tortor neque a labore sem, totam nobis commodi ut incididunt quo, scelerisque minim voluptates, velit mauris! Ornare torquent inceptos, quia excepturi, odio, laboris occaecat a, diamlorem sem quia doloremque. Luctus primis, senectus tempore eos tristique turpis nesciunt, proident mattis, maecenas esse, semper pede sagittis condimentum, dignissimos, posuere urna fugiat, quia blandit laboriosam! Tenetur incidunt? Deserunt, mattis in animi earum similique commodo natus ut unde sunt, id, consequat, risus ut natus primis suspendisse maxime volutpat aenean wisi? Commodi, necessitatibus odio? Vehicula veniam dolorum aptent lorem adipisicing euismod incididunt. Perferendis, mollis.
Laravel: Avoid N+1 queries in API resources
Tags: laravel, programming, discuss, webdev
Published: 2023-10-25 07:43:59

You can avoid N+1 queries in API resources by using the `whenLoaded()` method. This will only append the department if it’s already loaded in the Employee model. Without `whenLoaded()` there is always a query for the department.

```
class EmployeeResource extends JsonResource
{
    public function toArray($request): array
    {
        return [
            'id' => $this->uuid,
            'fullName' => $this->full_name,
            'email' => $this->email,
            'jobTitle' => $this->job_title,
            'department' => DepartmentResource::make($this->whenLoaded('department')),
        ];
    }
}
```
Mộ đá hoa cương - mộ đá có mái - Lăng mộ đá đẹp Hoàng Tám
Published: 2023-10-25 07:39:58

https://langmodahoangtam.com/ Công ty Hoàng Tám chuyên làm lăng mộ đá✔️ khuôn viên lăng mộ✔️ mộ đá có mái✔️ mộ đá đôi với đội ngũ nhân viên tay nghề cao✔️✔️✔️
0974031703
hoangmautam260386@gmail.com
Làng nghề đá mỹ nghệ Ninh Vân – Hoa Lư – Ninh Bình
https://www.scribd.com/user/698817040/L%C4%83ng-M%E1%BB%99-%C4%90a-Hoang-Tam
https://www.twitch.tv/langmodahoangtam/about
https://www.ultimate-guitar.com/u/langmoda05
https://www.veoh.com/users/langmodahoangtam
SME Cyber Security | Certcube Labs
Published: 2023-10-25 07:39:25

Small and Medium-sized Enterprises (SMEs) are increasingly becoming targets of cyberattacks. Is your business prepared to defend against these threats? We've got you covered!

At Certcube Labs, we specialize in providing top-notch **SME Cybersecurity Services** to protect your business from digital threats, no matter your size.

**Why Choose Us for Your SME?** 

✅ **Tailored Solutions**: We understand the unique challenges SMEs face, and we create custom cybersecurity solutions that fit your budget and needs.

✅ **Affordable Defense**: Effective cybersecurity doesn't have to break the bank. We offer cost-effective services without compromising on security.

✅ **24/7 Protection**: Our round-the-clock monitoring and response ensure that your data and operations remain secure at all times.

✅ **Expert Guidance**: Our experienced cybersecurity experts will guide you through the complex world of cybersecurity, helping you make the right decisions.

✅ **Compliance Assistance**: We'll help your business stay compliant with regulations, giving you peace of mind in a changing legal landscape.

✅ **Proactive Threat Prevention**: Our solutions go beyond detection; we actively prevent threats before they harm your business.

Secure your SME with the same level of protection that large corporations enjoy. Don't wait until a security breach cripples your business.

Contact us today for a FREE consultation, and let us help you build a robust cybersecurity strategy tailored to your SME.
Laravel: Conditional Relationship Counts on API Resources
Tags: laravel, programming, discuss, webdev
Published: 2023-10-25 07:35:33

You may conditionally include the count of a relationship in your resource response by using the whenCounted method. By doing so, the attribute is not included if the relationships' count is missing.

```
    public function toArray($request)
    {
        return [
            'id' => $this->id,
            'name' => $this->name,
            'email' => $this->email,
            'posts_count' => $this->whenCounted('posts'),
            'created_at' => $this->created_at,
            'updated_at' => $this->updated_at,
        ];
    }
```
Techzica
Tags: webdev
Published: 2023-10-25 07:28:29

Techzica es un sitio web que se especializa en proporcionar versiones Mod APK para aplicaciones y videojuegos. Te facilita el uso y el juego, etc. Visite [Techzica.com](url) para obtener información más detallada, instrucciones y consejos de uso.
Fildena – The Best Option to Treat ED Problem
Tags: fildena
Published: 2023-10-25 07:24:20

**[Fildena](https://www.sildenafilcitrates.com/product/fildena/)** is a medication used to treat erectile dysfunction (ED) or impotence in men. It contains Sildenafil Citrate as its active ingredient, relaxing the blood vessels in the penis, allowing more blood to flow into the area, and producing a firm and lasting erection suitable for sexual activity. Fildena is a prescription drug, and it is essential to consult a healthcare provider before using this medication. The recommended dosage is one tablet daily, taken orally with water, 30 minutes to 1 hour before sexual activity. The effects of Fildena can last up to 4-6 hours, making it a popular choice among men. However, it is essential to note that sexual stimulation is required for the medication to work effectively.

Visit This Website: **[Sildenafilcitrates](https://www.sildenafilcitrates.com)**
Laravel: API Resources: With or Without "data"?
Tags: laravel, php, mvc, eloquent
Published: 2023-10-25 07:22:24

If you use Eloquent API Resources to return data, they will be automatically wrapped in 'data'. If you want to remove it, add **JsonResource::withoutWrapping();** in **app/Providers/AppServiceProvider.php.**

```
class AppServiceProvider extends ServiceProvider
{
    public function boot()
    {
        JsonResource::withoutWrapping();
    }
}
```
🌟 Functional Programming in Automation Testing with TypeScript and Playwright 🤖🚀 Part II
Tags: playwright, typescript, testing, qa
Published: 2023-10-25 07:17:43

Welcome to the second part of our exploration into functional programming in automation testing. In this continuation, we will delve deeper into the practical implementation of the concepts we've 
<a class="toc-link" href="https://oholsyhevskyi.com/posts/functional-programming-in-automation-testing-partI">**discussed so far**</a>. 
Here's what you can expect in this part:

<div class="table-of-contents">
- <a class="toc-link" href="#installing-required-libraries">Installing Required Libraries</a>
  - <a class="toc-link" href="#install-typeScript">Step 1: Install TypeScript</a>
  - <a class="toc-link" href="#install-playwright">Step 2: Install Playwright</a>
  - <a class="toc-link" href="#install-fp-ts">Step 3: Install fp-ts (Functional Programming in TypeScript)</a>

## Installing Required Libraries
<a name="installing-required-libraries"></a>

Here are step-by-step instructions for installing TypeScript, Playwright, and fp-ts. We'll also include code snippets and commands to help you through the installation process. 
Please note that you need Node.js installed before proceeding with these installations. If you haven't already installed Node.js, you can download it from the official website: <a class="toc-link" href="https://nodejs.org">**Node.js**</a>

### Step 1: Install TypeScript
<a name="install-typeScript"></a>

1. Open your command-line interface (CLI) or terminal.
2. Use Node Package Manager (npm) to install TypeScript globally:
```bash:cli
npm install -g typescript
```
3. Verify the TypeScript installation by running the following command:
```bash:cli
tsc --version
```
This command should display the installed TypeScript version.

### Step 2: Install Playwright
<a name="install-playwright"></a>

1. Open your CLI or terminal.
2. Create a new directory for your Playwright project, if you haven't already:
```bash:cli
mkdir my-playwright-project-fp
cd my-playwright-project-fp
```
3. Initialize a new Node.js project in your directory:
```bash:cli
npm init -y
```
4. Install Playwright by running the following command:
```bash:cli
npm init playwright@latest
```
5. Once Playwright is installed, you can use it with JavaScript or TypeScript for your automation testing. TypeScript is recommended for type safety.

### Step 3: Install fp-ts (Functional Programming in TypeScript)
<a name="install-fp-ts"></a>

1. Open your CLI or terminal.
2. Navigate to your project directory (e.g., my-playwright-project-fp).
3. Install fp-ts as a dependency for your project:
```bash:cli
npm install fp-ts
```
4. You can now start using fp-ts in your TypeScript code. Make sure to import the necessary modules as needed in your TypeScript files.

Read more on [https://oholsyhevskyi.com](https://oholsyhevskyi.com/posts/functional-programming-in-automation-testing-partII#common-issues-and-troubleshooting)
How do data analysts identify and handle outliers in a dataset?
Published: 2023-10-25 07:12:09

Identifying and handling outliers in a dataset is a crucial aspect of data analysis. Outliers are data points that significantly deviate from the majority of the data, and they can have a significant impact on statistical analysis and machine learning models. In this comprehensive explanation, we will delve into how data analysts identify and handle outliers in a dataset, covering various methods and strategies for effective outlier detection and treatment. Apart from it by obtaining [Data Analyst certification](https://www.edureka.co/masters-program/data-analyst-certification), you can advance your career as a Data Analyst. With this course, you can demonstrate your expertise in the basics of you'll gain the knowledge and expertise demanded by the industry, opening up exciting career opportunities in the field of data analytics, many more fundamental concepts.

**Identifying Outliers:**

Visual Inspection: Data analysts often start by visualizing the data through histograms, box plots, scatter plots, or other graphical representations. Outliers can sometimes be easily spotted as data points that lie far from the bulk of the data.

Summary Statistics: Basic summary statistics, such as the mean, median, standard deviation, and quartiles, can provide initial insights. Outliers may exhibit extreme values that are significantly different from the central tendency of the data.

Z-Score: The Z-score measures how many standard deviations a data point is from the mean. Data points with Z-scores beyond a certain threshold (commonly ±2 or ±3) are considered outliers.

IQR (Interquartile Range): The IQR is the range between the first quartile (Q1) and the third quartile (Q3) of the data. Data points outside the range of Q1 - 1.5 * IQR to Q3 + 1.5 * IQR are identified as outliers.

Box Plot: Box plots visually represent the IQR and any data points beyond the "whiskers" are considered outliers. They provide a clear graphical depiction of outliers.

Scatter Plots: In scatter plots, outliers can be seen as data points that are far from the general pattern or trend of the data. These are especially useful for identifying outliers in multivariate data.

Domain Knowledge: Subject-matter expertise can help identify outliers. Analysts who understand the data's context may recognize values that are implausible or erroneous.