summarypip packages
linesdk
push data for line and slack
| def helpme(): | |
| print('help') | |
| # unit test function | |
| def testAddTransaction(testData, expectedResponse): | |
| result = addTransaction(testData, '') | |
| # check if status code is the same | |
| assert result['statusCode'] == expectedResponse['statusCode'], f"status code is incorrect, it should be {expectedResponse['statusCode']}, {result}" | |
| # check if transaction id is the same | |
| if result.get('transactionId'): |
| name="my-env" | |
| version="3.7" | |
| # Create a new conda environment for the given Python version | |
| conda create -y -n "$name" python="$version" | |
| # Activate the environment | |
| source /home/ec2-user/anaconda3/bin/activate "$name" | |
| # Create a Jupyter kernel for your new environment |
| setattr(cls, func.__name__, wrapper) |
| import traceback | |
| traceback.format_exc() |
| from villaWalletDatabase.database import getMember, setMember, addMember, removeMember, test |
| aws s3api \ | |
| --profile villaaws \ | |
| put-bucket-accelerate-configuration \ | |
| --bucket chatterbot-data \ | |
| --accelerate-configuration Status=Enabled |
| #export | |
| from functools import wraps # This convenience func preserves name and docstring | |
| def add_method(cls): | |
| def decorator(func): | |
| @wraps(func) | |
| def wrapper(self, *args, **kwargs): | |
| return func(self, *args, **kwargs) | |
| setattr(cls, func.__name__, wrapper) |