Skip to content

Commit

Permalink
Dev1.3 (#46)
Browse files Browse the repository at this point in the history
* Add Inspyre_Toolbox.conversions

'Conversions' is a new usb-package that aims to have all kinda of unit-conversions. The first one added is;
    * .roman_numerals

* Bugfix, functionality extension

Issues Addressed:
    - #41
        Wrote code to reset timer, as well as some supporting errors.

* General code clean-up

* Version Bump -> 1.3

* Update issue templates (#43)

* Update docs

* Addresses Issues:

* #41
* #40
* #39
* #26
* #2

* Code cleanup

* 'Refactored by Sourcery' (#45)

Co-authored-by: Sourcery AI <>

Co-authored-by: sourcery-ai[bot] <58596630+sourcery-ai[bot]@users.noreply.github.com>
  • Loading branch information
tayjaybabee and sourcery-ai[bot] committed Jun 30, 2022
1 parent 2a71c7f commit 92f689b
Show file tree
Hide file tree
Showing 31 changed files with 9,247 additions and 344 deletions.
32 changes: 32 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
---
name: Bug report
about: See something, say something.
title: "[Bug Report]"
labels: bug
assignees: tayjaybabee

---

## Bug Description
_A clear and concise description of what the bug is._

## To Reproduce
_Steps to reproduce the behavior:_

## Expected behavior
_A clear and concise description of what you expected to happen._

## Screenshots
_If applicable, add screenshots to help explain your problem._

## Needed Information
_In order to more effectively address this issue it would be helpful if some information was provided;_

**Operating System**:

**Python Version**:

**Inspyre-Toolbox Version**:
_Putting anything akin to "whatever the latest version is" will earn a response that's equally as helpful._
## Additional context
_Add any other context about the problem here._
7 changes: 4 additions & 3 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ name: Python package

on:
push:
branches: [ main ]
branches: [ main,
v1.3
]
pull_request:
branches: [ main ]

Expand All @@ -15,7 +17,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.6', '3.7', '3.8']
python-version: ['3.6', '3.7', '3.8', '3.9', '3.10']

steps:
- uses: actions/checkout@v2
Expand All @@ -37,4 +39,3 @@ jobs:
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
- name: Youtrack issue action
uses: dt-co/youtrack-githooks@1.1

9 changes: 7 additions & 2 deletions examples/humanize/example_1.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,14 @@
In this example we demonstrate simple usage of the humanize module in conjunction with the 'live_timer' module.
"""
from inspyre_toolbox.humanize import Numerical # Numerical is the only class in humanize that would be remotely useful to anyone
from inspyre_toolbox.live_timer import Timer # Just demonstrating the timer, the timer is not needed to utilize Numerical
from time import sleep

from inspyre_toolbox.humanize import \
Numerical # Numerical is the only class in humanize that would be remotely useful to anyone
from inspyre_toolbox.live_timer import \
Timer # Just demonstrating the timer, the timer is not needed to utilize Numerical


class Logging:
def __init__(self):
from inspy_logger import InspyLogger
Expand Down Expand Up @@ -43,4 +47,5 @@ def do_it(do_log=False, no_sleep=False, num_iters=1000):
if not no_sleep:
sleep(.1)


do_it(do_log=True, no_sleep=True, num_iters=1500)
10 changes: 6 additions & 4 deletions examples/live_timer/simple_timer.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,11 @@
Created: 12/12/2020 - 12:37AM
"""
from inspyre_toolbox.live_timer import Timer

from time import sleep

from inspyre_toolbox.live_timer import Timer

timer = Timer()
timer.start()
acc = 0
Expand All @@ -18,10 +21,9 @@
elif acc == 25:
timer.unpause()

print(timer.get_elapsed())
if acc == 31:
print(timer.get_elapsed())
print(timer.get_elapsed(True))
break
else:
print(timer.get_elapsed())
sleep(1)
sleep(1)
4 changes: 2 additions & 2 deletions examples/live_timer/timer_demo_GUI.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
timer.start()

layout = [
[GUI.Text("00:00:00", key="TIMER")],
[GUI.Button("Quit", tooltip="Quit the program", enable_events=True, key="QUIT_BUTTON")]
[GUI.Text("00:00:00", key="TIMER")],
[GUI.Button("Quit", tooltip="Quit the program", enable_events=True, key="QUIT_BUTTON")]
]


Expand Down

0 comments on commit 92f689b

Please sign in to comment.