I have discovered an issue with installing Meltano...
# troubleshooting
e
I have discovered an issue with installing Meltano
v2.6.0
and my custom tap via Juju inside LXD.. it seems the tap is not finding poetry.. even if I have added the path to the default user (
ubuntu
) my plan is to just.. modify the taps
.sh
file and inject the path there.. but this feels a bit heavy handed or hacky.. is there a step I am missing when installing poetry via pipx and doing
pipx ensurepath
as well as manually adding the path to the ubuntu users
.bash_profile
??
Copy code
2022-09-18T14:16:36.502056Z [info     ] Running extract & load...      name=meltano run_id=5b74bdd0-af22-4e38-bf4e-c5cda1381169 state_id=ibkr-to-postgres-tickers
2022-09-18T14:16:36.585453Z [info     ] /home/ubuntu/stonks-tap-ibkr/tap-ibkr/tap-ibkr.sh: 13: poetry: not found cmd_type=extractor name=tap-ibkr-tickers run_id=5b74bdd0-af22-4e38-bf4e-c5cda1381169 state_id=ibkr-to-postgres-tickers stdio=stderr
the error from meltano
my
tap-ibkr.sh
Copy code
#!/bin/sh

# This simple script allows you to test your tap from any directory, while still taking
# advantage of the poetry-managed virtual environment.
# Adapted from: <https://github.com/python-poetry/poetry/issues/2179#issuecomment-668815276>

unset VIRTUAL_ENV

STARTDIR=$(pwd)
TOML_DIR=$(dirname "$0")

cd "$TOML_DIR" || exit
poetry install 1>&2
poetry run tap-ibkr $*
e
Even if the tap used poetry for development, you don't poetry to install it. A more or less recent version of
pip
and setting
poetry-core>=1.0.8
in the `pyproject.toml`'s build-system section should allow you to not rely on poetry for installing the tap.
e
cool, I will play around with that.. thanks Edgar. workaround for now was to just modify the .sh file to get the path updated and seems to work but.. obviously it should not need that in the long run if others start using the tap
a
I use poetry’s dedicated installer instead of pipx. Not sure if it would help here. https://github.com/python-poetry/install.python-poetry.org