Hey, playing around with `pyflyte register` and ho...
# ask-the-community
h
Hey, playing around with
pyflyte register
and how do adopt it in our set up. When I package code using
pyflyte package
I usually provide the dot-delineated python packages to operate on i.e.,
Copy code
pyflyte --pkgs flyte.workflows package --image $REGISTRY/$REPO:$TAG -o $(PACKAGE_OUTPUT_DIR)/package.tgz
When I run
pyflyte register
I would like to do the same in order to fast-register to the same workflow i.e.,
Copy code
pyflyte register flyte.workflows \
		             --version=$VERSION \
					 --image $REGISTRY/$REPO:$TAG \
					 --project $PROJECT \
	                 --domain $DOMAIN
However running that command yields
Copy code
Usage: pyflyte register [OPTIONS] [PACKAGE_OR_MODULE]...
Try 'pyflyte register --help' for help.

Error: Invalid value for '[PACKAGE_OR_MODULE]...': Path 'flyte.workflows' does not exist.
gmake: *** [Makefile:42: flyte-fast-register] Error 2
Do I need to provide the path to the workflow? If I pass
flyte/workflows/wf.py
to
pyflyte register
my workflow is registered under
<http://wf.wf|wf.wf>
instead of
<http://flyte.workflows.wf.wf|flyte.workflows.wf.wf>
as with
pyflyte package
Copy code
(.venv) tree .
.
├── Dockerfile
├── Makefile
├── flyte
│   ├── __init__.py
│   ├── <http://in_container.mk|in_container.mk>
│   ├── launchplans
│   │   └── lp.py
│   └── workflows
│       ├── __init__.py
│       └── wf.py
s
@Hampus Rosvall, you’ll need to send a directory as path to `pyflyte register`:
pyflyte register flyte/workflows
. Concerning the path
<http://wf.wf|wf.wf>
, I’m not sure why that’s happening. I believe it should be
<http://flyte.workflows.wf.wf|flyte.workflows.wf.wf>
. @Yee, is this expected?
123 Views