Skip to content

Commit

Permalink
4.0.0 (#167)
Browse files Browse the repository at this point in the history
  • Loading branch information
NeonDaniel authored Jun 7, 2023
2 parents bd73279 + 4f07efc commit 43ee221
Show file tree
Hide file tree
Showing 14 changed files with 464 additions and 556 deletions.
129 changes: 129 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,129 @@
# Byte-compiled / optimized / DLL files
__pycache__/
*.py[cod]
*$py.class

# C extensions
*.so

# Distribution / packaging
.Python
build/
develop-eggs/
dist/
downloads/
eggs/
.eggs/
lib/
lib64/
parts/
sdist/
var/
wheels/
pip-wheel-metadata/
share/python-wheels/
*.egg-info/
.installed.cfg
*.egg
MANIFEST

# PyInstaller
# Usually these files are written by a python script from a template
# before PyInstaller builds the exe, so as to inject date/other infos into it.
*.manifest
*.spec

# Installer logs
pip-log.txt
pip-delete-this-directory.txt

# Unit test / coverage reports
htmlcov/
.tox/
.nox/
.coverage
.coverage.*
.cache
nosetests.xml
coverage.xml
*.cover
*.py,cover
.hypothesis/
.pytest_cache/

# Translations
*.mo
*.pot

# Django stuff:
*.log
local_settings.py
db.sqlite3
db.sqlite3-journal

# Flask stuff:
instance/
.webassets-cache

# Scrapy stuff:
.scrapy

# Sphinx documentation
docs/_build/

# PyBuilder
target/

# Jupyter Notebook
.ipynb_checkpoints

# IPython
profile_default/
ipython_config.py

# pyenv
.python-version

# pipenv
# According to pypa/pipenv#598, it is recommended to include Pipfile.lock in version control.
# However, in case of collaboration, if having platform-specific dependencies or dependencies
# having no cross-platform support, pipenv may install dependencies that don't work, or not
# install all needed dependencies.
#Pipfile.lock

# PEP 582; used by e.g. github.com/David-OConnor/pyflow
__pypackages__/

# Celery stuff
celerybeat-schedule
celerybeat.pid

# SageMath parsed files
*.sage.py

# Environments
.env
.venv
env/
venv/
ENV/
env.bak/
venv.bak/

# Spyder project settings
.spyderproject
.spyproject

# Rope project settings
.ropeproject

# mkdocs documentation
/site

# mypy
.mypy_cache/
.dmypy.json
dmypy.json

# Pyre type checker
.pyre/
98 changes: 89 additions & 9 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,28 +1,108 @@
# Changelog

## [3.3.1a3](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.1a3) (2023-05-04)
## [3.3.2a12](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a12) (2023-06-05)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.1a2...3.3.1a3)
[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a11...3.3.2a12)

**Merged pull requests:**

- Specify Docker actions to use `diana` action runners [\#151](https://github.com/NeonGeckoCom/neon_speech/pull/151) ([NeonDaniel](https://github.com/NeonDaniel))
- Update dependencies to stable versions [\#166](https://github.com/NeonGeckoCom/neon_speech/pull/166) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.1a2](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.1a2) (2023-05-04)
## [3.3.2a11](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a11) (2023-06-03)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.1a1...3.3.1a2)
[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a10...3.3.2a11)

**Merged pull requests:**

- Troubleshoot Docker build failures [\#149](https://github.com/NeonGeckoCom/neon_speech/pull/149) ([NeonDaniel](https://github.com/NeonDaniel))
- Implement tests for CLI module [\#165](https://github.com/NeonGeckoCom/neon_speech/pull/165) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.1a1](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.1a1) (2023-05-03)
## [3.3.2a10](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a10) (2023-06-03)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.0...3.3.1a1)
[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a9...3.3.2a10)

**Merged pull requests:**

- Handle hotword engine exception handling with unit tests [\#148](https://github.com/NeonGeckoCom/neon_speech/pull/148) ([NeonDaniel](https://github.com/NeonDaniel))
- Update dependencies [\#164](https://github.com/NeonGeckoCom/neon_speech/pull/164) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.2a9](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a9) (2023-06-01)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a8...3.3.2a9)

**Merged pull requests:**

- Replace Hotword reload tests [\#163](https://github.com/NeonGeckoCom/neon_speech/pull/163) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.2a8](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a8) (2023-05-31)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a7...3.3.2a8)

**Merged pull requests:**

- Update Dinkum listener dependency and clean up config reload handling [\#162](https://github.com/NeonGeckoCom/neon_speech/pull/162) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.2a7](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a7) (2023-05-26)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a6...3.3.2a7)

**Merged pull requests:**

- Refactor config init to CLI and out of `main` method [\#160](https://github.com/NeonGeckoCom/neon_speech/pull/160) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.2a6](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a6) (2023-05-25)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a5...3.3.2a6)

**Closed issues:**

- Resolve non-server unit test failures [\#84](https://github.com/NeonGeckoCom/neon_speech/issues/84)

**Merged pull requests:**

- Refactor on Dinkum Listener [\#157](https://github.com/NeonGeckoCom/neon_speech/pull/157) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.2a5](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a5) (2023-05-24)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a4...3.3.2a5)

**Merged pull requests:**

- Refactor 'speech' to 'voice' for future compat. [\#159](https://github.com/NeonGeckoCom/neon_speech/pull/159) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.2a4](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a4) (2023-05-18)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a3...3.3.2a4)

**Merged pull requests:**

- Add malloc logging to speech service [\#156](https://github.com/NeonGeckoCom/neon_speech/pull/156) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.2a3](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a3) (2023-05-18)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a2...3.3.2a3)

**Merged pull requests:**

- Refactor on ovos-listener module [\#155](https://github.com/NeonGeckoCom/neon_speech/pull/155) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.2a2](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a2) (2023-05-11)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.2a1...3.3.2a2)

**Merged pull requests:**

- Add test coverage for non-streaming STT init [\#154](https://github.com/NeonGeckoCom/neon_speech/pull/154) ([NeonDaniel](https://github.com/NeonDaniel))

## [3.3.2a1](https://github.com/NeonGeckoCom/neon_speech/tree/3.3.2a1) (2023-05-11)

[Full Changelog](https://github.com/NeonGeckoCom/neon_speech/compare/3.3.1...3.3.2a1)

**Fixed bugs:**

- \[BUG\] Whisper STT plugins don't work with neon\_speech [\#150](https://github.com/NeonGeckoCom/neon_speech/issues/150)

**Merged pull requests:**

- Fix non-streaming plugin config compat. with ovos-plugin-manager [\#153](https://github.com/NeonGeckoCom/neon_speech/pull/153) ([NeonDaniel](https://github.com/NeonDaniel))



Expand Down
16 changes: 10 additions & 6 deletions neon_speech/__main__.py
Original file line number Diff line number Diff line change
Expand Up @@ -27,27 +27,31 @@
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

from ovos_utils import wait_for_exit_signal
from neon_utils.configuration_utils import init_config_dir
from neon_utils.log_utils import init_log
from neon_utils.process_utils import start_malloc, snapshot_malloc, print_malloc
from ovos_utils.log import LOG
from ovos_utils.process_utils import PIDLock, reset_sigint_handler
from neon_speech.service import NeonSpeechClient


def main(*args, **kwargs):
# Initialize configuration
init_config_dir()
init_log(log_name="voice")
if kwargs.get("config"):
LOG.warning("Found config kwarg, updating to 'speech_config'")
kwargs["speech_config"] = kwargs.pop("config")

from mycroft.lock import Lock
from mycroft.util.process_utils import reset_sigint_handler
from neon_speech.service import NeonSpeechClient
reset_sigint_handler()
Lock("speech")
PIDLock("voice")
malloc_running = start_malloc(stack_depth=4)
service = NeonSpeechClient(*args, **kwargs)
service.start()
wait_for_exit_signal()
if malloc_running:
try:
print_malloc(snapshot_malloc())
except Exception as e:
LOG.error(e)
service.shutdown()


Expand Down
3 changes: 3 additions & 0 deletions neon_speech/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@

from click_default_group import DefaultGroup
from neon_utils.packaging_utils import get_package_version_spec
from neon_utils.configuration_utils import init_config_dir


@click.group("neon-speech", cls=DefaultGroup,
Expand All @@ -52,6 +53,8 @@ def neon_speech_cli(version: bool = False):
@click.option("--force-install", "-f", default=False, is_flag=True,
help="Force pip installation of configured module")
def run(module, package, force_install):
init_config_dir()

from neon_speech.__main__ import main
from ovos_config.config import Configuration
speech_config = Configuration()
Expand Down
Loading

0 comments on commit 43ee221

Please sign in to comment.