semvec/pypi-packages huggingface dataset:
PyIsEven 0.8.12
Check is a integer is even
License: MIT
Keywords: even

# Is Even

![PyPI - Downloads](https://img.shields.io/pypi/dm/PyIsEven)
[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=rosineygp_PyIsEven&metric=alert_status)](https://sonarcloud.io/dashboard?id=rosineygp_PyIsEven)

Check if interger is even using `isevenapi`.

https://isevenapi.xyz/

Main features:

- cache memoization
- api retry handler
- hide ads

## Install

```bash
pip install PyIsEven
```

## Usage

```python
from is_even import is_even as ie

ie.is_even(10)
> True

# Get AD
v = ie.is_even(10)

v.ad
> "HONDA CIVIC '96, AM/FM/CD, low miles, Good condition. Speaks Spanish $3500 339-555-6289"

ie.is_even(10).ad
> "CHINA CABINET, buffet, hutch solid pine, 6.5 tall x 4.5 wide, lighted windows. few cat scratches but cat has died. $700. Call 435-555-6421"
```
reapit-cdk.active-ruleset 0.1.2
This construct returns the currently active SES receipt RuleSet, or creates one. This enables you to add rules to it.
License: MIT
Requires Python: ~=3.8

# @reapit-cdk/active-ruleset

![npm version](https://img.shields.io/npm/v/@reapit-cdk/active-ruleset)
![npm downloads](https://img.shields.io/npm/dm/@reapit-cdk/active-ruleset)
![coverage: 99.02%25](https://img.shields.io/badge/coverage-99.02%25-green)
![Integ Tests: ✔](https://img.shields.io/badge/Integ%20Tests-%E2%9C%94-green)

This construct returns the currently active SES receipt RuleSet, or creates one. This enables you to add rules to it.

## Package Installation:

```sh
yarn add --dev @reapit-cdk/active-ruleset
# or
npm install @reapit-cdk/active-ruleset --save-dev
```

## Usage

```python
import { CfnOutput, Stack, App } from 'aws-cdk-lib'
import { ActiveRuleset } from '@reapit-cdk/active-ruleset'

const app = new App()
const stack = new Stack(app, 'stack-name')
const activeRuleset = new ActiveRuleset(stack, 'active-ruleset')
new CfnOutput(stack, 'activeRulesetName', {
  value: activeRuleset.receiptRuleSet.receiptRuleSetName,
})
```
reapit-cdk.replicated-secret 0.1.2
Creates a Secret and replicates it across the given regions. Requires a [ReplicatedKey](../replicated-key/readme.md) be passed in.
License: MIT
Requires Python: ~=3.8

# @reapit-cdk/replicated-secret

![npm version](https://img.shields.io/npm/v/@reapit-cdk/replicated-secret)
![npm downloads](https://img.shields.io/npm/dm/@reapit-cdk/replicated-secret)
![coverage: 97.06%25](https://img.shields.io/badge/coverage-97.06%25-green)
![Integ Tests: ✔](https://img.shields.io/badge/Integ%20Tests-%E2%9C%94-green)

Creates a Secret and replicates it across the given regions. Requires a [ReplicatedKey](../replicated-key/readme.md) be passed in.

## Package Installation:

```sh
yarn add --dev @reapit-cdk/replicated-secret
# or
npm install @reapit-cdk/replicated-secret --save-dev
```

## Usage

```python
import { Stack, App } from 'aws-cdk-lib'
import { Function, Runtime, Code } from 'aws-cdk-lib/aws-lambda'
import { ReplicatedKey } from '@reapit-cdk/replicated-key'
import { ReplicatedSecret } from '@reapit-cdk/replicated-secret'

const app = new App()
const stack = new Stack(app, 'stack-name', {
  env: {
    region: 'us-east-1', // region must be specified
  },
})
const replicatedKey = new ReplicatedKey(stack, 'key', {
  replicaRegions: ['af-south-1', 'cn-north-1'],
})
const replicatedSecret = new ReplicatedSecret(stack, 'secret', {
  replicaRegions: ['af-south-1', 'cn-north-1'],
  replicatedKey,
})
const lambda = new Function(stack, 'lambda', {
  runtime: Runtime.NODEJS_18_X,
  handler: 'lambda.handler',
  code: Code.fromInline('export const handler = () => {}'),
  environment: {
    usSecretArn: replicatedSecret.getRegionalSecret('us-east-1').secretArn,
    afSecretArn: replicatedSecret.getRegionalSecret('af-south-1').secretArn,
    cnSecretArn: replicatedSecret.getRegionalSecret('cn-north-1').secretArn,
  },
})
replicatedSecret.grantWrite(lambda)
```
reapit-cdk.service-quotas 0.1.2
This construct allows you to IaC your service quotas
License: MIT
Requires Python: ~=3.8

# @reapit-cdk/service-quotas

![npm version](https://img.shields.io/npm/v/@reapit-cdk/service-quotas)
![npm downloads](https://img.shields.io/npm/dm/@reapit-cdk/service-quotas)
![coverage: 0%25](https://img.shields.io/badge/coverage-0%25-red)
![Integ Tests: X](https://img.shields.io/badge/Integ%20Tests-X-red)

This construct allows you to IaC your service quotas

## Package Installation:

```sh
yarn add --dev @reapit-cdk/service-quotas
# or
npm install @reapit-cdk/service-quotas --save-dev
```

## Usage

```python
import { Stack, App } from 'aws-cdk-lib'
import { AWSService, AmazonCloudFrontQuota, ServiceQuotas } from '@reapit-cdk/service-quotas'

const app = new App()
const stack = new Stack(app, 'stack-name')
const quotas = new ServiceQuotas(stack, 'service-quotas', {
  // Fail the stack if your requests aren't granted yet
  failIfNotGranted: true,
  // Make another request if an existing one is denied
  rerequestWhenDenied: true,
})

quotas.requestQuota(
  // region
  'us-east-1',
  // service (use the AWSService.${Service} helper or specify the e.g. 'cloudfront' string as any)
  AWSService.AMAZON_CLOUD_FRONT,
  // quota (use the ${Service}Quota e.g. AmazonCloudFrontQuota helper or specify the 'LL-' string as any)
  AmazonCloudFrontQuota.CACHE_BEHAVIORS_PER_DISTRIBUTION,
  // desired value
  100,
)
```
reapit-cdk.reapit-product 0.1.2
Creates a product in the organisations service
License: MIT
Requires Python: ~=3.8

# @reapit-cdk/reapit-product

![npm version](https://img.shields.io/npm/v/@reapit-cdk/reapit-product)
![npm downloads](https://img.shields.io/npm/dm/@reapit-cdk/reapit-product)
![coverage: 0%25](https://img.shields.io/badge/coverage-0%25-red)
![Integ Tests: X](https://img.shields.io/badge/Integ%20Tests-X-red)

Creates a product in the organisations service

## Package Installation:

```sh
yarn add --dev @reapit-cdk/reapit-product
# or
npm install @reapit-cdk/reapit-product --save-dev
```

## Usage

```python
import { CfnOutput, Stack, App } from 'aws-cdk-lib'
import { ReapitProductProvider } from '@reapit-cdk/reapit-product'
import { RestApi } from 'aws-cdk-lib/aws-apigateway'

const app = new App()
const stack = new Stack(app, 'stack-name')

const orgsApiGwId = '' // imported from somewhere or hard coded

const organisationsServiceApiGateway = RestApi.fromRestApiId(stack, 'orgs-api-gw', orgsApiGwId)

const productProvider = new ReapitProductProvider(stack, 'product-provider', {
  organisationsServiceApiGateway,
  stageName: 'api',
})

const product = productProvider.createProduct(stack, 'product', {
  name: 'a product name',
  callbackUrls: [],
  grant: 'authorizationCode',
  isInternalApp: true,
  requiresUserAdmin: false,
  scopes: [],
  signoutUrls: [],
})

new CfnOutput(stack, 'client-id', {
  value: product.externalId,
})
```
reapit-cdk.cloudfront-invalidation 0.1.2
CloudFront invalidations are [very error prone](https://github.com/aws/aws-cdk/issues/15891#issuecomment-966456154), making it hard to invalidate distributions reliably. This construct aims to solve this problem by using a step function which is triggered on stack update, and uses exponential backoff to retry the invalidation. Inspired by https://github.com/aws/aws-cdk/issues/15891#issuecomment-1362163142.
License: MIT
Requires Python: ~=3.8

# @reapit-cdk/cloudfront-invalidation

![npm version](https://img.shields.io/npm/v/@reapit-cdk/cloudfront-invalidation)
![npm downloads](https://img.shields.io/npm/dm/@reapit-cdk/cloudfront-invalidation)
![coverage: 99.02%25](https://img.shields.io/badge/coverage-99.02%25-green)
![Integ Tests: ✔](https://img.shields.io/badge/Integ%20Tests-%E2%9C%94-green)

CloudFront invalidations are [very error prone](https://github.com/aws/aws-cdk/issues/15891#issuecomment-966456154), making it hard to invalidate distributions reliably. This construct aims to solve this problem by using a step function which is triggered on stack update, and uses exponential backoff to retry the invalidation. Inspired by https://github.com/aws/aws-cdk/issues/15891#issuecomment-1362163142.

## Package Installation:

```sh
yarn add --dev @reapit-cdk/cloudfront-invalidation
# or
npm install @reapit-cdk/cloudfront-invalidation --save-dev
```

## Usage

```python
import { Stack, App } from 'aws-cdk-lib'
import { Distribution } from 'aws-cdk-lib/aws-cloudfront'
import { HttpOrigin } from 'aws-cdk-lib/aws-cloudfront-origins'

import { CloudfrontInvalidation } from '@reapit-cdk/cloudfront-invalidation'

const app = new App()
const stack = new Stack(app, 'stack-name', {
  env: {
    region: 'us-east-1', // region must be specified
  },
})
const distribution = new Distribution(stack, 'distribution', {
  defaultBehavior: {
    origin: new HttpOrigin('example.org'),
  },
})
new CloudfrontInvalidation(stack, 'invalidation', {
  distribution,
  items: ['/index.html', '/config.js'], // path patterns you want invalidated
})
```
reapit-cdk.email-receiver 0.1.2
This construct sets up everything necessary to receive email. The emails get stored in a dynamodb table, queryable by recipient. This is designed to be used in end-to-end tests, with the [@reapit-cdk/email-receiver-client](../../libs/email-receiver-client) helper library.
License: MIT
Requires Python: ~=3.8

# @reapit-cdk/email-receiver

![npm version](https://img.shields.io/npm/v/@reapit-cdk/email-receiver)
![npm downloads](https://img.shields.io/npm/dm/@reapit-cdk/email-receiver)
![coverage: 99.02%25](https://img.shields.io/badge/coverage-99.02%25-green)
![Integ Tests: ✔](https://img.shields.io/badge/Integ%20Tests-%E2%9C%94-green)

This construct sets up everything necessary to receive email. The emails get stored in a dynamodb table, queryable by recipient. This is designed to be used in end-to-end tests, with the [@reapit-cdk/email-receiver-client](../../libs/email-receiver-client) helper library.

## Package Installation:

```sh
yarn add --dev @reapit-cdk/email-receiver
# or
npm install @reapit-cdk/email-receiver --save-dev
```

## Usage

```python
import { CfnOutput, Stack, App } from 'aws-cdk-lib'
import { HostedZone } from 'aws-cdk-lib/aws-route53'
import { EmailReceiver } from '@reapit-cdk/email-receiver'

const app = new App()
const stack = new Stack(app, 'stack-name', {
  env: {
    region: 'us-east-1', // region must be specified
  },
})

const hostedZone = new HostedZone(stack, 'hostedZone', {
  zoneName: 'example.org',
})

const emailReceiver = new EmailReceiver(stack, 'domain', {
  hostedZone,
  // you can optionally override the parent domain
  // (e.g. your hosted zone is example.org but you want to use dev.example.org)
  // parentDomain: '',
  // you can optionally override the subdomain
  // this defaults to 'email' so the resulting domain will be email.example.org
  // subdomain: '',
})

new CfnOutput(stack, 'emailReceiverDomainName', {
  value: emailReceiver.domainName,
})
new CfnOutput(stack, 'emailReceiverTableArn', {
  value: emailReceiver.table.tableArn,
})
```
reapit-cdk.replicated-key 0.1.2
Creates a KMS key and replicates it to the desired regions. Useful when replicating secrets across regions.
License: MIT
Requires Python: ~=3.8

# @reapit-cdk/replicated-key

![npm version](https://img.shields.io/npm/v/@reapit-cdk/replicated-key)
![npm downloads](https://img.shields.io/npm/dm/@reapit-cdk/replicated-key)
![coverage: 99.02%25](https://img.shields.io/badge/coverage-99.02%25-green)
![Integ Tests: ✔](https://img.shields.io/badge/Integ%20Tests-%E2%9C%94-green)

Creates a KMS key and replicates it to the desired regions. Useful when replicating secrets across regions.

## Package Installation:

```sh
yarn add --dev @reapit-cdk/replicated-key
# or
npm install @reapit-cdk/replicated-key --save-dev
```

## Usage

```python
import { Stack, App } from 'aws-cdk-lib'
import { ReplicatedKey } from '@reapit-cdk/replicated-key'
import { Code, Function, Runtime } from 'aws-cdk-lib/aws-lambda'

const app = new App()
const stack = new Stack(app, 'stack-name', {
  env: {
    region: 'us-east-1', // region must be specified
  },
})
const key = new ReplicatedKey(stack, 'key', {
  replicaRegions: ['af-south-1', 'cn-north-1'],
})

const lambda = new Function(stack, 'lambda', {
  runtime: Runtime.NODEJS_18_X,
  handler: 'lambda.handler',
  code: Code.fromInline('export const handler = () => {}'),
  environment: {
    usKeyArn: key.getRegionalKey('us-east-1').keyArn,
    afKeyArn: key.getRegionalKey('af-south-1').keyArn,
    cnKeyArn: key.getRegionalKey('cn-north-1').keyArn,
  },
})

key.grantEncryptDecrypt(lambda)
```
reapit-cdk.cross-region-stack-export 0.1.2
Allows you to share values between stack across regions and accounts.
License: MIT
Requires Python: ~=3.8

# @reapit-cdk/cross-region-stack-export

![npm version](https://img.shields.io/npm/v/@reapit-cdk/cross-region-stack-export)
![npm downloads](https://img.shields.io/npm/dm/@reapit-cdk/cross-region-stack-export)
![coverage: 71.85%25](https://img.shields.io/badge/coverage-71.85%25-orange)
![Integ Tests: X](https://img.shields.io/badge/Integ%20Tests-X-red)

Allows you to share values between stack across regions and accounts.

## Package Installation:

```sh
yarn add --dev @reapit-cdk/cross-region-stack-export
# or
npm install @reapit-cdk/cross-region-stack-export --save-dev
```

## Usage

```python
import { CfnOutput, Stack, App } from 'aws-cdk-lib'
import { CrossRegionStackExport } from '@reapit-cdk/cross-region-stack-export'
import { Bucket } from 'aws-cdk-lib/aws-s3'

const app = new App()
const euStack = new Stack(app, 'stack-eu', {
  env: {
    account: '11111111',
    region: 'eu-west-1',
  },
})

const exporter = new CrossRegionStackExport(euStack, 'exporter')
exporter.setValue('thing', 'avalue')

const bucket = new Bucket(euStack, 'bucket')
exporter.setValue('bucketArn', bucket.bucketArn)

const usStack = new Stack(app, 'stack-us', {
  env: {
    account: '2222222222',
    region: 'us-east-1',
  },
})

const importer = exporter.getImporter(usStack, 'eu-importer')

const euThing = importer.getValue('thing')
const euBucket = Bucket.fromBucketArn(usStack, 'eu-bucket', importer.getValue('bucketArn'))

new CfnOutput(usStack, 'euThing', {
  value: euThing,
})

new CfnOutput(usStack, 'euBucketName', {
  value: euBucket.bucketName,
})
```
twitch-utils 1.0.0
Utility functions for interacting with Twitch.
License: MIT

Certainly! Here's the complete README.md file for the twitch_api library in English:

```markdown
# Twitch API

Twitch API is a library providing convenient tools for interacting with the Twitch platform programmatically.

## Installation

You can install the library via pip:

```bash
pip install twitch-api
```

## Usage

### Getting Stream Information

```python
from twitch_api import TwitchUtils

# Example: Get stream information for a specific streamer
streamer_name = "archangel_hs"
TwitchUtils.get_stream_info(streamer_name)
```

### Downloading Videos

```python
from twitch_api import TwitchUtils

# Example: Download a video from a Twitch URL
video_url = "https://clips.twitch.tv/GiantRelentlessBunnyTheTarFu"
TwitchUtils.download_video_from_url(video_url, filename="my_video.mp4")
```

### Parsing Twitch Profile Information

```python
from twitch_api import TwitchUtils

# Example: Parse Twitch profile info for a specific username
username = "archangel_hs"
profile_info = TwitchUtils.parse_profile_info_by_username(username)
print(profile_info)
```

## License

This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
```

This README.md provides usage examples, installation instructions, and license information for the twitch_api library.
molecular-rectifier 1.0.1
Given an RDKit molecule that does not sanitise, correct it until it does, regardless of the severity of the change.
License: MIT
Requires Python: >3.6

# Molecular Rectifier
Given an RDKit molecule that does not sanitise, correct it until it does, regardless of the severity of the change.

![horror](horror.png)

## Install

Requires RDKit.

    pip3 install molecular-rectifier

## Beyond RDKit Sanitisation

The command `rdkit.Chem.SanitizeMol` fixes minor issues with the molecule.
However, more drastic changes such as valence correction and removal of weird bonds is not done,
hence the molecular rectifier!

    from molecular_rectifier import Rectifier
    
    recto = Rectifier(wrong_mol)
    recto.fix()
    fixed_mol = recto.mol
    # this works:
    Chem.SanitizeMol(fixed_mol, sanitizeOps=Chem.SanitizeFlags.SANITIZE_ALL)

A lot of the corrections are based on arbitrary choices. These choices are manually encoded.
I am sure that sooner or later some ML module will do this, but for now the Rectifier does the job.

The attribute `valence_correction` controls how the valence is fixed up
—either by shifting the element (`'element'`) or by adding a charge (`'charge'`)

* protonating ring nitrogens if required
* forcing all atoms/bonds in a ring to be aromatic or not (unless part of another ring)
* Texas carbon -> Sulfur
* Hydrogen -> Fluoride shifted downwards
* Carbon in aromatic ring -> single bond ring
* kills bridging bonds with no atoms in the bridge within rings.
* correcting `BondType.UNSPECIFIED`
* preventing 3- and 4- membered rings fused to another ring
* preventing allene

For more see (rules note)[rules.md].

## Rationale

This is used by [Fragmenstein](https://github.com/matteoferla/Fragmenstein) in the automatic merging mode (`combine`).
Originally part of it, but moved apart because it may be useful for other uses, outside of Fragmenstein.
Or a better module is found to fix the molecules.