Skip to content

Commit

Permalink
made cli fixes to make mac version work.: (#147)
Browse files Browse the repository at this point in the history
* made cli fixes to make mac version work.:

* version bump

---------

Co-authored-by: Red-Giuliano <red.giuliano@zero-true.com>
  • Loading branch information
Red-Giuliano and Red-Giuliano authored Jan 18, 2024
1 parent 468990f commit 388d56a
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 8 deletions.
2 changes: 1 addition & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name = zero-true
description = A collaborative notebook built for data scientists
long_description = file: README.md
long_description_content_type = text/markdown
version = 0.0.dev42
version = 0.0.dev43

[options]
include_package_data = true
Expand Down
2 changes: 1 addition & 1 deletion zt_backend/tests/test_e2e.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
import time


notebook_str = '''notebookId = "08bdd530-3544-473b-af28-bb04f8646dbd"
notebook_str = '''notebookId = "08bdd530-3544-473b-af28-bb04f8646dba"
[cells.57fbbd59-8f30-415c-87bf-8caae0374070]
cellType = "code"
Expand Down
13 changes: 7 additions & 6 deletions zt_dev_cli/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,11 +65,11 @@ def app(port: Annotated[Optional[int], typer.Argument(help="Port number to bind
log_path = os.path.normpath(pkg_resources.resource_filename('zt_dev_cli', 'log_config.yaml'))
os.environ['RUN_MODE'] = 'app'
frontend_cmd = ["yarn", "run", "app", str(port)]
backend_cmd = ["start", "uvicorn", "zt_backend.main:app", "--reload", f"--log-config={log_path}"]
backend_cmd = ["uvicorn", "zt_backend.main:app", "--reload", f"--log-config={log_path}"]

backend_process = subprocess.Popen(backend_cmd, shell=True)
backend_process = subprocess.Popen(backend_cmd, shell=(os.name == 'nt'))
os.chdir("zt_frontend")
frontend_process = subprocess.Popen(frontend_cmd, shell=True)
frontend_process = subprocess.Popen(frontend_cmd, shell=(os.name == 'nt'))

backend_process.wait()
frontend_process.wait()
Expand All @@ -82,11 +82,12 @@ def notebook(port: Annotated[Optional[int], typer.Argument(help="Port number to
log_path = os.path.normpath(pkg_resources.resource_filename('zt_dev_cli', 'log_config.yaml'))
os.environ['RUN_MODE'] = 'dev'
frontend_cmd = ["yarn", "run", "dev", str(port)]
backend_cmd = ["start", "uvicorn", "zt_backend.main:app", "--reload", f"--log-config={log_path}"]
backend_cmd = ["uvicorn", "zt_backend.main:app", "--reload", f"--log-config={log_path}"]

backend_process = subprocess.Popen(backend_cmd, shell=True)

backend_process = subprocess.Popen(backend_cmd, shell=(os.name == 'nt'))
os.chdir("zt_frontend")
frontend_process = subprocess.Popen(frontend_cmd, shell=True)
frontend_process = subprocess.Popen(frontend_cmd, shell=(os.name == 'nt'))

backend_process.wait()
frontend_process.wait()
Expand Down

0 comments on commit 388d56a

Please sign in to comment.