semvec/pypi-packages huggingface dataset:
Attendance-Module 0.3
An Attendance webapp component created for the CSCN73030 at Conestoga College, Ontario, Canada
Requires Python: >=3.7, <4

[![Python application](https://github.com/CSCN73030-projectv-group9/Attendance/actions/workflows/pytest.yml/badge.svg?branch=main)](https://github.com/CSCN73030-projectv-group9/Attendance/actions/workflows/pytest.yml)

# Introduction 
TODO: Give a short introduction of your project. Let this section explain the objectives or the motivation behind this project.
pytest-dbx 0.1.0
Pytest plugin to run unit tests for dbx (Databricks CLI extensions) related code
Requires Python: >=3.9,<4.0

# pytest-dbx

Pytest plugin for testing [dbx](https://github.com/databrickslabs/dbx)-based projects.

## Install

To use the fixtures in your project, simply add `pytest-dbx` to your project's dev-dependencies
(where you would place all your test and build dependencies).

## Fixtures

In unit tests you can use the `dbx_spark` fixture to have a spark session available as in Databricks

```python
def test_function(dbx_spark):
    sdf = dbx_spark.createDataFrame([[1], [2], [3]], ['a'])
    assert sdf.count() == 3
```

The `dbutils_fixture` and `mlflow_local` are automatically used.
pycomposite 1.0.2
Generic implementation of the Composite Design Pattern as a Python class decorator.
Requires Python: >=3.8

# Composite Class Decorator

This project contains a generic implementation of the [Composite Design Pattern](https://en.wikipedia.org/wiki/Composite_pattern) as a Python class decorator.

This is a targeted solution addressing the particular need of creating composite [Builders](https://en.wikipedia.org/wiki/Builder_pattern). All existing solutions we observed so far assumed manual reproduction on every abstract method in Composite, which is problematic from a maintenance point of view.

For more technical in-depth discussion please refer to our article: [Generic Composite in Python](https://python.plainenglish.io/generic-composite-in-python-4b88d6727ad0)

## Usage Example

```python
from abc import ABC, abstractmethod
from typing import Tuple, Any
from pycomposite import composite

class Configuration:
    '''
    Just an example to demostrate side-effect
    '''
    def __init__(self):
        self._configuration = {}
        
    def configure(self, name: str, value: Any) -> None:
        self._configuration[name] = value
        
class Builder(ABC):

    @abstractmethod
    def build_part_one(self, arg: int) -> Tuple: #better coveres a general case
        pass
        
    @abstractmethod
    def build_part_two(self, arg: str) -> Tuple:
        pass
        
    @abstractmethod
    def configure_part_three(self, arg: Configuration) -> None:
        pass

class BuilderA(Builder):

    def build_part_one(self, arg: int) -> Tuple: #better coveres a general case
        return arg*10, arg+5,
        
    def build_part_two(self, arg: str) -> Tuple:
        return f'A: {arg}', 
        
    def configure_part_three(self, arg: Configuration) -> None:
        arg.configure('A', 'A builder')

class BuilderB(Builder):

    def build_part_one(self, arg: int) -> Tuple: #better coveres a general case
        return arg-100, arg*5,
        
    def build_part_two(self, arg: str) -> Tuple:
        return f'B: {arg}', 
        
    def configure_part_three(self, arg: Configuration) -> None:
        arg.configure('B', 'B builder')

@composite
class CompositeBuilder(Builder):
    pass
    
builder = CompositeBuilder(BuilderA(), BuilderB())
config = Configuration()

builder.configure_part_three(config)
assert (70, 12, -93, 35) == builder.build_part_one(7)
assert ('A: high', 'B: high') == builder.build_part_two('high')
assert {'A': 'A builder', 'B': 'B builder'} == config._configuration
```