Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

0.0.35 #180

Merged
merged 29 commits into from
Jul 20, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
29 commits
Select commit Hold shift + click to select a range
ea54394
Add unit tests for shutdown/restart (#170)
NeonDaniel Jun 21, 2023
98db714
Increment Version to 0.0.35a1
JarbasAl Jun 21, 2023
d7b8f99
Update Changelog
JarbasAl Jun 21, 2023
ea5c78a
hotfix/missing_value_qml_upload (#173)
JarbasAl Jun 28, 2023
554a522
Increment Version to 0.0.35a2
JarbasAl Jun 28, 2023
9b3404f
Update Changelog
JarbasAl Jun 28, 2023
95722ad
fix/enclosure message.context
JarbasAl Jul 4, 2023
dee443f
Increment Version to 0.0.35a3
JarbasAl Jul 4, 2023
8df5fa8
Update Changelog
JarbasAl Jul 4, 2023
9aeefc0
SkillApi docs and tests (#174)
NeonDaniel Jul 4, 2023
2de0b61
Increment Version to 0.0.35a4
NeonDaniel Jul 4, 2023
c5ea2f6
Update Changelog
NeonDaniel Jul 4, 2023
ca88e1e
Fix bug in `dev` branch with refactoring and added unit test (#176)
NeonDaniel Jul 4, 2023
12bed88
Increment Version to 0.0.35a5
JarbasAl Jul 4, 2023
3640772
Update Changelog
JarbasAl Jul 4, 2023
a4ef6ae
Enable GUI module resource file resolution (#177)
NeonDaniel Jul 6, 2023
bb7507f
Increment Version to 0.0.35a6
JarbasAl Jul 6, 2023
7fdb974
Update Changelog
JarbasAl Jul 6, 2023
0a7ff8c
Volunteer GUI upload on init (#178)
NeonDaniel Jul 7, 2023
b185158
Increment Version to 0.0.35a7
NeonDaniel Jul 7, 2023
83a4c93
Update Changelog
NeonDaniel Jul 7, 2023
083f0a0
fix ui directores (#179)
JarbasAl Jul 13, 2023
9247c25
Increment Version to 0.0.35a8
JarbasAl Jul 13, 2023
44bb28e
Update Changelog
JarbasAl Jul 13, 2023
e6b4af2
feat/threaded_timeout_util (#169)
JarbasAl Jul 19, 2023
04c2ff1
Increment Version to 0.0.35a9
NeonDaniel Jul 19, 2023
56a1b29
Update Changelog
NeonDaniel Jul 19, 2023
7253692
Increment Version to 0.0.35
NeonDaniel Jul 19, 2023
91f306a
Update Changelog
NeonDaniel Jul 19, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
74 changes: 31 additions & 43 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,89 +1,77 @@
# Changelog

## [0.0.34](https://github.com/OpenVoiceOS/ovos-utils/tree/0.0.34) (2023-06-15)
## [V0.0.35a9](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.35a9) (2023-07-19)

[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.34a9...0.0.34)
[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.35a8...V0.0.35a9)

**Merged pull requests:**
**Implemented enhancements:**

- Fix dev branch coverage action [\#166](https://github.com/OpenVoiceOS/ovos-utils/pull/166) ([NeonDaniel](https://github.com/NeonDaniel))
- feat/threaded\_timeout\_util [\#169](https://github.com/OpenVoiceOS/ovos-utils/pull/169) ([JarbasAl](https://github.com/JarbasAl))

## [V0.0.34a9](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.34a9) (2023-06-15)
## [V0.0.35a8](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.35a8) (2023-07-13)

[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.34a8...V0.0.34a9)
[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.35a7...V0.0.35a8)

**Merged pull requests:**
**Fixed bugs:**

- Add timeout to `get_ip` to prevent tests failing on timeout [\#165](https://github.com/OpenVoiceOS/ovos-utils/pull/165) ([NeonDaniel](https://github.com/NeonDaniel))
- fix ui directores [\#179](https://github.com/OpenVoiceOS/ovos-utils/pull/179) ([JarbasAl](https://github.com/JarbasAl))

## [V0.0.34a8](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.34a8) (2023-06-15)
## [V0.0.35a7](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.35a7) (2023-07-07)

[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.34a7...V0.0.34a8)
[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.35a6...V0.0.35a7)

**Merged pull requests:**

- Cleanup deprecation logs [\#164](https://github.com/OpenVoiceOS/ovos-utils/pull/164) ([NeonDaniel](https://github.com/NeonDaniel))
- Volunteer GUI upload on init [\#178](https://github.com/OpenVoiceOS/ovos-utils/pull/178) ([NeonDaniel](https://github.com/NeonDaniel))

## [V0.0.34a7](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.34a7) (2023-06-14)
## [V0.0.35a6](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.35a6) (2023-07-06)

[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.34a6...V0.0.34a7)
[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.35a5...V0.0.35a6)

**Merged pull requests:**

- Add options to deprecation logging to configure logged caller [\#163](https://github.com/OpenVoiceOS/ovos-utils/pull/163) ([NeonDaniel](https://github.com/NeonDaniel))
- Enable GUI module resource file resolution [\#177](https://github.com/OpenVoiceOS/ovos-utils/pull/177) ([NeonDaniel](https://github.com/NeonDaniel))

## [V0.0.34a6](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.34a6) (2023-06-14)
## [V0.0.35a5](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.35a5) (2023-07-04)

[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.34a5...V0.0.34a6)
[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.35a4...V0.0.35a5)

**Fixed bugs:**

- Fix compat. with `pages2uri` extra\_directories [\#162](https://github.com/OpenVoiceOS/ovos-utils/pull/162) ([NeonDaniel](https://github.com/NeonDaniel))

## [V0.0.34a5](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.34a5) (2023-06-13)

[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.34a3...V0.0.34a5)

**Implemented enhancements:**

- Add deprecation log helpers [\#161](https://github.com/OpenVoiceOS/ovos-utils/pull/161) ([NeonDaniel](https://github.com/NeonDaniel))
- bus upload qml [\#140](https://github.com/OpenVoiceOS/ovos-utils/pull/140) ([JarbasAl](https://github.com/JarbasAl))
- Fix bug in `dev` branch with refactoring and added unit test [\#176](https://github.com/OpenVoiceOS/ovos-utils/pull/176) ([NeonDaniel](https://github.com/NeonDaniel))

**Fixed bugs:**
## [V0.0.35a4](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.35a4) (2023-07-04)

- Codecov automation [\#159](https://github.com/OpenVoiceOS/ovos-utils/pull/159) ([NeonDaniel](https://github.com/NeonDaniel))
[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.35a3...V0.0.35a4)

**Merged pull requests:**

- Fix codecov automation [\#160](https://github.com/OpenVoiceOS/ovos-utils/pull/160) ([NeonDaniel](https://github.com/NeonDaniel))
- SkillApi docs and tests [\#174](https://github.com/OpenVoiceOS/ovos-utils/pull/174) ([NeonDaniel](https://github.com/NeonDaniel))

## [V0.0.34a3](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.34a3) (2023-06-09)
## [V0.0.35a3](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.35a3) (2023-07-04)

[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.34a2...V0.0.34a3)
[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.35a2...V0.0.35a3)

**Fixed bugs:**
**Closed issues:**

- Annotate GUI Module and refactor resource resolution [\#158](https://github.com/OpenVoiceOS/ovos-utils/pull/158) ([NeonDaniel](https://github.com/NeonDaniel))
- Non-blocking error when running on MacOS natively [\#175](https://github.com/OpenVoiceOS/ovos-utils/issues/175)

## [V0.0.34a2](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.34a2) (2023-06-08)
## [V0.0.35a2](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.35a2) (2023-06-28)

[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.34a1...V0.0.34a2)
[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.35a1...V0.0.35a2)

**Merged pull requests:**

- Troubleshooting GUI shell plugin resource file resolution [\#157](https://github.com/OpenVoiceOS/ovos-utils/pull/157) ([NeonDaniel](https://github.com/NeonDaniel))
- hotfix/missing\_value\_qml\_upload [\#173](https://github.com/OpenVoiceOS/ovos-utils/pull/173) ([JarbasAl](https://github.com/JarbasAl))

## [V0.0.34a1](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.34a1) (2023-06-08)
## [V0.0.35a1](https://github.com/OpenVoiceOS/ovos-utils/tree/V0.0.35a1) (2023-06-21)

[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.33...V0.0.34a1)

**Fixed bugs:**

- Event Scheduler Interface tests [\#156](https://github.com/OpenVoiceOS/ovos-utils/pull/156) ([NeonDaniel](https://github.com/NeonDaniel))
[Full Changelog](https://github.com/OpenVoiceOS/ovos-utils/compare/V0.0.34...V0.0.35a1)

**Merged pull requests:**

- Add unit test coverage for SkillApi [\#145](https://github.com/OpenVoiceOS/ovos-utils/pull/145) ([NeonDaniel](https://github.com/NeonDaniel))
- Add unit tests for shutdown/restart [\#170](https://github.com/OpenVoiceOS/ovos-utils/pull/170) ([NeonDaniel](https://github.com/NeonDaniel))
- Fix dev branch coverage action [\#166](https://github.com/OpenVoiceOS/ovos-utils/pull/166) ([NeonDaniel](https://github.com/NeonDaniel))



Expand Down
37 changes: 37 additions & 0 deletions ovos_utils/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,43 @@
from ovos_utils.log import LOG, deprecated


def threaded_timeout(timeout=5):
"""
Start a thread with a specified timeout. If timeout is exceeded, an
exception is raised and the thread is terminated.
Adapted from https://github.com/OpenJarbas/InGeo
@param timeout: Timeout in seconds to wait before terminating the process
"""

def deco(func):
@wraps(func)
def wrapper(*args, **kwargs):
res = [Exception(f'function [{func.__name__}] timeout '
f'[{timeout}] exceeded!')]

def func_wrapped():
try:
res[0] = func(*args, **kwargs)
except Exception as e:
res[0] = e

t = Thread(target=func_wrapped)
t.daemon = True
try:
t.start()
t.join(timeout)
except Exception as je:
raise je
ret = res[0]
if isinstance(ret, BaseException):
raise ret
return ret

return wrapper

return deco


class classproperty(property):
"""Decorator for a Class-level property.
Credit to Denis Rhyzhkov on Stackoverflow: https://stackoverflow.com/a/13624858/1280629"""
Expand Down
Loading
Loading