diff --git a/Makefile b/Makefile index a122b371..cd493f4d 100644 --- a/Makefile +++ b/Makefile @@ -27,14 +27,14 @@ DIST_DIR = ./dist SITE_DIR = ./site SHINYLIVE_DIR = ./_shinylive -# Read htmltools and shiny versions from the package code. It's done with grep -# because if we try to load the package and read shiny.__version__, it requires -# the packages to be loadable first, which isn't possible without their -# dependencies being installed first. -HTMLTOOLS_VERSION = $(shell grep '^__version__ = ' $(PACKAGE_DIR)/py-htmltools/htmltools/__init__.py | sed -E -e 's/^__version__ = "(.*)"/\1/') -SHINY_VERSION = $(shell grep '^__version__ = ' $(PACKAGE_DIR)/py-shiny/shiny/_version.py | sed -E "s/.*['\"]([^'\"]+)['\"]/\1/") -SHINYWIDGETS_VERSION = $(shell grep '^__version__ = ' $(PACKAGE_DIR)/py-shinywidgets/shinywidgets/__init__.py | sed -E -e 's/^__version__ = "(.*)"/\1/') -FAICONS_VERSION = $(shell grep '^__version__ = ' $(PACKAGE_DIR)/py-faicons/faicons/__init__.py | sed -E -e 's/^__version__ = "(.*)"/\1/') +# Extract package versions by grepping source files. Each package may define +# __version__ in __init__.py, _version.py, or __version.py (hatch-vcs). +# We use a consistent helper that checks all three locations. +_get_version = $(shell grep '^__version__ = ' $(1)/__version.py $(1)/__init__.py $(1)/_version.py 2>/dev/null | head -1 | sed -E "s/.*['\"]([^'\"]+)['\"]/\1/") +HTMLTOOLS_VERSION = $(call _get_version,$(PACKAGE_DIR)/py-htmltools/htmltools) +SHINY_VERSION = $(call _get_version,$(PACKAGE_DIR)/py-shiny/shiny) +SHINYWIDGETS_VERSION = $(call _get_version,$(PACKAGE_DIR)/py-shinywidgets/shinywidgets) +FAICONS_VERSION = $(call _get_version,$(PACKAGE_DIR)/py-faicons/faicons) HTMLTOOLS_WHEEL = htmltools-$(HTMLTOOLS_VERSION)-py3-none-any.whl SHINY_WHEEL = shiny-$(SHINY_VERSION)-py3-none-any.whl @@ -274,23 +274,22 @@ package-faicons: $(PACKAGE_DIR)/$(FAICONS_WHEEL) $(PACKAGE_DIR)/$(HTMLTOOLS_WHEEL): $(PYBIN) $(PACKAGE_DIR)/py-htmltools # Remove any old copies of the package rm -f $(PACKAGE_DIR)/htmltools*.whl - $(PYBIN)/pip install -e $(PACKAGE_DIR)/py-htmltools[dev] - . $(PYBIN)/activate && cd $(PACKAGE_DIR)/py-htmltools && make install && mv dist/*.whl ../ + . $(PYBIN)/activate && cd $(PACKAGE_DIR)/py-htmltools && pip wheel --no-deps -w ../ . $(PACKAGE_DIR)/$(SHINY_WHEEL): $(PYBIN) $(PACKAGE_DIR)/py-shiny # Remove any old copies of the package rm -f $(PACKAGE_DIR)/shiny*.whl - . $(PYBIN)/activate && cd $(PACKAGE_DIR)/py-shiny && make install && mv dist/*.whl ../ + . $(PYBIN)/activate && cd $(PACKAGE_DIR)/py-shiny && pip wheel --no-deps -w ../ . $(PACKAGE_DIR)/$(SHINYWIDGETS_WHEEL): $(PYBIN) $(PACKAGE_DIR)/py-shinywidgets # Remove any old copies of the package rm -f $(PACKAGE_DIR)/shinywidgets*.whl - . $(PYBIN)/activate && cd $(PACKAGE_DIR)/py-shinywidgets && make install && mv dist/*.whl ../ + . $(PYBIN)/activate && cd $(PACKAGE_DIR)/py-shinywidgets && pip wheel --no-deps -w ../ . $(PACKAGE_DIR)/$(FAICONS_WHEEL): $(PYBIN) $(PACKAGE_DIR)/py-faicons # Remove any old copies of the package rm -f $(PACKAGE_DIR)/faicons*.whl - . $(PYBIN)/activate && cd $(PACKAGE_DIR)/py-faicons && make install && mv dist/*.whl ../ + . $(PYBIN)/activate && cd $(PACKAGE_DIR)/py-faicons && pip wheel --no-deps -w ../ . $(PACKAGE_DIR)/$(LIBSASS_WHEEL): $(PYBIN) $(PACKAGE_DIR)/$(LIBSASS_WHEEL) rm -f $(PACKAGE_DIR)/libsass*.whl diff --git a/package-lock.json b/package-lock.json index fdfd76a3..b5d7d541 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "shinylive", - "version": "0.10.7", + "version": "0.10.9", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "shinylive", - "version": "0.10.7", + "version": "0.10.9", "license": "MIT", "devDependencies": { "@codemirror/autocomplete": "^6.4.2", diff --git a/package.json b/package.json index fd923995..21e60f27 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "private": true, "name": "shinylive", - "version": "0.10.8", + "version": "0.10.9", "description": "Run Shiny applications with R or Python running in the browser.", "main": "index.js", "repository": { diff --git a/packages/py-htmltools b/packages/py-htmltools index e2df351e..0e6f479a 160000 --- a/packages/py-htmltools +++ b/packages/py-htmltools @@ -1 +1 @@ -Subproject commit e2df351e47aa68688599c2a9130ea80fbb646574 +Subproject commit 0e6f479a7ca3cdaf27be425e2fc29399cac682f5 diff --git a/packages/py-shiny b/packages/py-shiny index 75a39675..5a6f254c 160000 --- a/packages/py-shiny +++ b/packages/py-shiny @@ -1 +1 @@ -Subproject commit 75a396750c0fc583a48f1a95319fe4a500032390 +Subproject commit 5a6f254ca42c731bc306fae29d6c7dfc355a3271 diff --git a/packages/py-shinywidgets b/packages/py-shinywidgets index c46111f6..83932fb5 160000 --- a/packages/py-shinywidgets +++ b/packages/py-shinywidgets @@ -1 +1 @@ -Subproject commit c46111f610d4062fe0a564873fa9b122bfba89cd +Subproject commit 83932fb557f66f2d4a4c9734df0a6e61667776e6 diff --git a/shinylive_lock.json b/shinylive_lock.json index 52dcf7c3..7c5f7971 100644 --- a/shinylive_lock.json +++ b/shinylive_lock.json @@ -1,8 +1,8 @@ { "htmltools": { "name": "htmltools", - "version": "0.6.0", - "filename": "htmltools-0.6.0-py3-none-any.whl", + "version": "0.6.1", + "filename": "htmltools-0.6.1-py3-none-any.whl", "sha256": null, "url": null, "depends": [ @@ -15,8 +15,8 @@ }, "shiny": { "name": "shiny", - "version": "1.6.0", - "filename": "shiny-1.6.0-py3-none-any.whl", + "version": "1.6.1", + "filename": "shiny-1.6.1-py3-none-any.whl", "sha256": null, "url": null, "depends": [ @@ -40,16 +40,16 @@ }, "shinywidgets": { "name": "shinywidgets", - "version": "0.5.2", - "filename": "shinywidgets-0.5.2-py3-none-any.whl", + "version": "0.8.0", + "filename": "shinywidgets-0.8.0-py3-none-any.whl", "sha256": null, "url": null, "depends": [ + {"name": "anywidget", "specs": []}, {"name": "ipywidgets", "specs": [[">=", "7.6.5"]]}, - {"name": "jupyter_core", "specs": []}, - {"name": "shiny", "specs": [[">=", "0.6.1.9005"]]}, + {"name": "jupyter-core", "specs": []}, {"name": "python-dateutil", "specs": [[">=", "2.8.2"]]}, - {"name": "anywidget", "specs": []} + {"name": "shiny", "specs": [[">=", "0.6.1.9005"]]} ], "imports": [ "shinywidgets"