semvec/pypi-packages huggingface dataset:
PyCLOS 0.2
CLOS-style generic functions with annotation based syntax
License: MIT
Keywords: clos generic

PyCLOS
======

PyCLOS implements CLOS-style generic functions for Python 3. Current
implementation is pure python with optional dependency on C
implemented lru-dict which gets used for dispatch caches in case of
specialization on value.

Example usage::

  from py_clos import generic
  @generic
  def display(what, where):
      return "{} on {}".format(what, where)

  @generic.around
  def display(what, where: Webpage, next_method):
      return "<html>{}</html>".format(next_method(what, where))

  @generic
  def display(what: User, where):
      return "user"
subnetting 0.0.4
IPv4 subnetting calculator CLI
License: MIT
Keywords: subnetting,CIDR,calculating,network,troubleshooting

subnetting.py is a CLI help neteng and sysadmin speed up subnetting, calculating and troubleshooting.
For more ops tools, check the master project repo [opsPykit](https://github.com/thimoonxy/opsPyKit).
flyenv 0.0.1
a tool helps manage environment variable portably and safely
License: MIT
Keywords: flyenv help environment variable management

flyenv
=============================================================
a tool helps manage environment variable portably and safely
-------------------------------------------------------------

Installation
------------

::

    pip install flyenv


Usage
-----

::

    usage: flyenv.py [-h]
                     {set,unset,delete,get,list,require,clear,load,encrypt,decrypt}
                     ...

    a tool helps manage environment variable portably and safely

    positional arguments:
      {set,unset,delete,get,list,require,clear,load,encrypt,decrypt}

    optional arguments:
      -h, --help            show this help message and exit


Usage in Django or Flask or others
----------------------------------
1. In the same directory with manage.py, create a file name "flyenv.txt", then you can add environment variables in this file directly with this format "name=value", one key-value
   pair a line, this file allow empty lines and comment lines starts with "#". You can also set environment variables in the command line.

2. In any source file you want to use environment variables

::

    from flyenv import set_env, get_env

    set_env(name, val)
    get_env(name)

3. You can encrypt your env file to protect sensitive data.
   In the command line:

::

    $flyenv encrypt secret_key[a string with length 16]

flyenv will remove "flyenv.txt" and generate a file name "flyenv_encrypt.txt" with encrypted environment variables in it.
Then you can add this file to your git repository.

4. When you want to use the encrypted environment variables, you can decrypt the file in command line:

::

    $flyenv descrypt secret_key[a string with length 16]
canvasgrader 1.0.2
Simple grading interface with the Canvas API
License: MIT
Keywords: canvas learning management system lms grade grades grading

canvasgrader
============

This package provides a simple interface with the Canvas grading API to
save you the hassle of dealing with the web gradebook.

Installation
------------

.. code:: bash

    pip install canvasgrader

Usage
-----

1. Generate a new Access Token at
   ``https://<canvas-installation>/profile/settings``
2. Grab your course ID from the web interface:
   ``https://<canvas-installation>/courses/<course-id>``
3. Choose a
   `key <https://canvas.instructure.com/doc/api/file.object_ids.html>`__
   by which you want to identify students

.. code:: python

    >>> from canvasgrader import CanvasGrader
    >>> api_key = 'your access token'
    >>> canvas_grader = CanvasGrader(api_key=api_key, base_uri='umich.instructure.com',
                                     course_id=85425, id_key='sis_login_id')
    >>> assignment_id = canvas_grader.create_assignment(name='Homework 01',
                                                        points_possible=4)
    >>> canvas_grader.grade_assignment(assignment_id, {
            'mterwil': 4,
        })

Alternatively, you may place the API key in a dotfile:

.. code:: bash

    $ echo "my api key" > ~/.canvasgrader
    $ chmod 600 ~/.canvasgrader