semvec/pypi-packages huggingface dataset:
gmsh-utils 1.1.1
Utilities for gmsh
Requires Python: >=3.8

# Gmsh utils

![Tests branch main](https://github.com/StemVibrations/gmsh_utils/actions/workflows/tests.yml/badge.svg)

Utilities to generate a finite element mesh with [gmsh](https://gmsh.info/).

## Rules

- max 1 level of inheritance
- only use license compatible packages
pybcp 0.1.3
Tool for importing data to MS SQL Server.
Requires Python: >=3.10

# Python module for uploading numpy arrays to MS SQL Server

This module allows dictionaries of numpy arrays to be uploaded to SQL
Server as database tables. The upload is carried out as a bulk insert,
which copies binary data to the server without any conversion to or
from text. This is faster than uploading text and exactly preserves
floating point values.

## Compilation

The module uses [freetds](https://www.freetds.org/) to communicate
with the database server. To build the module, set the location of the
freetds library and headers and then run pip install. E.g.:
```
SYBDB=/cosma/local/freetds/1.4.20/ LDFLAGS="-L${SYBDB}/lib/ -Wl,-rpath=${SYBDB}/lib/" CFLAGS="-I${SYBDB}/include/" pip install .
```

## Usage

### Connect to the database:
```
dbcon = pybcp.DBConnection(username, server, database, password=None)
```
Here, `username` and `password` are the database username and password.
`server` is the server name defined in freetds.conf and `database` is
the name of the database which contains the table to be created or
updated.

If the password is None then a password prompt will appear.

### Uploading a database table

```
dbcon.bulk_insert(table_name, columns, create_table=True, drop_existing=True)
```
Here, `table_name` is the name of the table to create or append to. `columns`
is a dict of numpy arrays with the data for each column. If `create_table` is
true then a new table will be created. If `drop_existing` is true then any
existing table is removed first.

Table column arrays should be stored in an OrderedDict if the ordering
of the columns is important.

### Executing SQL commands

For convenience there's a function to execute SQL commands:
```
dbcon.execute(sql)
```
where `sql` is a string with the command to execute. This can be useful for
creating indexes on newly uploaded tables, for example.

This returns a list containing any tables returned by the command. Any
returned tables are represented as dictionaries of arrays in the same way
as data to be bulk inserted.
py-interceptor 0.1.0
A library for intercepting and processing Python method calls.
Requires Python: >=3.9
Keywords: mocking, testing

# PyInterceptor

A library for intercepting and processing Python method calls.

## Introduction

Sometimes it might be interesting to get detailed knowledge about which methods of an object have been called with which
args, kwargs, at which time, etc. but without changing the underlying code.
This is especially useful for:

- Debugging
- Logging
- Creating call statistics, etc.

PyInterceptor enables exactly this - it installs a handler function into a target object that intercepts specified
methods and stores (meta-) data about the calls in `CallInfo` objects. These objects are then handed over to a
user-defined `interceptor` callable.

![call_sequence_detailed.png](doc/images/call_sequence_detailed.png)

PyInterceptor distinguishes between 2 modi:

- blocking mode: In this mode the handler does not execute the actual method and returns the return value from the
  `interceptor`. This mode is very useful when creating mocks or stubs.
- non-blocking mode: In this mode the handler executed the actual method and forwards its return value to the
  `interceptor` callable. Then it continues like in the blocking mode.

## Installation

To install PyInterceptor from pypi using pip type:
`pip install py-interceptor`

To install PyInterceptor from source, do the following steps:

1. Create an environment, e.g. with venv
    - `python -m venv env`
    - `env\Scripts\activate` (windows)
    - `source env/bin/activate` (linux)
2. Install the package from source
    - `cd py-interceptor`
    - `pip install -e .` (without dev dependencies)
    - `pip install -e .[dev]` (with dev dependencies)
3. Execute unit tests (requires dev dependencies)
    - `pytest`

## Examples

The following example demonstrates how easy it is to intercept an object's method. Here we want to print the name of the
executed API method together with the args and the return value:

```
from interceptor import CallInfo, intercept


class API:
    def add(self, a, b):
        return a + b

def interceptor(info: CallInfo):
    print(f"Executed {info.name} with args {info.args} -> returned {info.ret_value}")

api = API()
intercept("add", api, interceptor, blocking=False)
api.add(1, 2)
```
The output should be:
`Executed add with args (1, 2) -> returned 3`

More example can be found in the [examples](examples) folder.
ue-om-tests 0.0.1
Small package to extend metadata functionality
Requires Python: >=3.8

Introduction

!!! In the tools folders is needed to add a config.ini file and the public/private keys of the user in order to check passbolt !!!

This repository contains a Python package that can be built and uploaded to PyPI. Follow the steps below to build the package, upload it to PyPI.
    
Prerequisites

Before proceeding, ensure the following:

    Python 3.8 or higher is installed.
    pip is installed and up-to-date.
    Required tools are installed:

- pip install build twine

A PyPI account is set up, and an API token has been generated. Add this token to your environment variables, also it can be retrieved from passbolt but the example is using a export:

    export PYPI_API_KEY=<your-pypi-api-key>


---- Steps to Build and Upload ----

- Build the Package -

Run the following command in the root directory (where setup.py or pyproject.toml is located):

python -m build

This generates the package files in the dist/ directory.

- Upload the Package to PyPI -

To upload the package, run:

python -m twine upload dist/* -u __token__ -p "$PYPI_API_KEY"

    Ensure the PYPI_API_KEY environment variable is correctly set.

- Automated Process -

Use the provided build_or_upload_env.sh script for automation:

./tools/build_or_upload_env.sh

    The script allows you to:
        Build the package only.
        Upload the package to PyPI.
        Build and upload the package.

Test Your Package

Once uploaded, verify it by installing directly from PyPI:

    pip install <your-package-name>

Shell Script Usage

The build_or_upload_env.sh script is located in the repository. Here’s how it works:

    Make the script executable:

chmod +x ./tools/build_or_upload_env.sh

Run the script:

    ./tools/build_or_upload_env.sh

    Options:
        Build the package only.
        Upload the package to PyPI only.
        Build and upload the package.