Skip to main content

Lab-SMP-PSU

Interface to the LAB-SMP DC Power Supply source

Clone repository

cd <path-to-directory>
git clone git@gitlab.com:pass-testing-solutions/lab-smp-psu.git
cd lab-smp-psu/
git pull origin main
git checkout -b <your-new-branch>  # Please follow the branch naming convention as mentioned in the coding guidelines

Virtual environment on MacOS

1. Virtualenvwrapper

You can install virtualenv and virtualenvwrapper with:

pip3 install virtualenv
pip3 install virtualenvwrapper
mkdir ~/.virtualenvs
# Might need to query where the virtualenv and virtualenvwrapper.sh are
which virtualenv
which virtualenvwrapper.sh
which python3

Add these lines in the ~/.zshrc file

# Setting PATH for Python 3 installed by brew
export PATH=<path-to-your-python3>:$PATH

# Configuration for virtualenv
export WORKON_HOME=$HOME/.virtualenvs
export VIRTUALENVWRAPPER_PYTHON=<path-to-your-python3>
export VIRTUALENVWRAPPER_VIRTUALENV=<path-to-your-virtualenv>
source <path-to-your-virtualenvwrapper.sh>

source $ZSH/oh-my-zsh.sh

Make sure to save these changes in your file and close your terminal for them to take effect. Now you can create a virtual environment by simply typing:

mkvirtualenv <name-of-your-virtual-env>
cd <your-git-repository>
workon <name-of-your-virtual-env>
deactivate <name-of-your-virtual-env>

To add the correct interpreter for your repository on PyCharm:

- PyCharm IDE > Preferences > Project > Python Interpreter
- Select the 'Add' button for interpreters
- Choose the 'Existing environments' in 'Virtualenv'
- Add the python3 file from /bin/ of your venv folder
E.g. - .virtualenvs/demo_repo_venv/bin/python3

After setting up the venv for the repo please install all the requirements and allow some time for the IDE to do indexing. If your repository has a requirements.txt:

pip3 install -r requirements.txt

2. Pipenv

Install pipenv

pip3 install pipenv 
# or
brew install pipenv

pipenv shell         # will create a virtualenv for the project
pipenv install       # will install dependencies for the repo from the Pipfile and Pipfile.lock

# Install any further packages in this environment as

pipenv install rich  # rich is a python library to nicely print on terminal

Your pipenv environment will be in the ~./virtualenvs folder. Make sure to add the interpreter on your IDE if not automatically added by navigating to the virtualenv folder for your repo and selecting the correct python3 file from /bin/.


Maintainers

Maintainers: @julianpass and @shuparnadeb_pts

Release files for pts-lab-smp-psu 0.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pts-lab-smp-psu 0.0.1
File Size Uploaded
pts_lab_smp_psu-0.0.1.tar.gz 5.2 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pts-lab-smp-psu 0.0.1
File Interpreter ABI Platform
pts_lab_smp_psu-0.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 10.8 kB

Release files / pts_lab_smp_psu-0.0.1.tar.gz

Download URL pts_lab_smp_psu-0.0.1.tar.gz
Size 5.2 kB
Tags Source
SHA-256 checksum
How to use checksums
e4435606c855b6a855b0a904d168dc51b8167878736cc84cb83547579904c18b
BLAKE2b-256 checksum
How to use checksums
d24e55b6c01b9462c94bb4852d8e3a6866bb387fbbe2202d1d6a96f5b3d6c979
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.13

Release files / pts_lab_smp_psu-0.0.1-py3-none-any.whl

Download URL pts_lab_smp_psu-0.0.1-py3-none-any.whl
Size 5.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e033c848dce9b9af57530e791d7f2362dd86709123f5cc05326892b9a25ba79b
BLAKE2b-256 checksum
How to use checksums
8212964178ce5a37bddd8b0035ba2032fcda88505429f60bd1a1e99c49ed9ca0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.1 CPython/3.9.13

Release history Release notifications | RSS feed

This release

0.0.1 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page