^ I've been <getting> this same error (only with t...
# troubleshooting
k
^ I've been getting this same error (only with targets, not taps). Updated OS (to mac 12.6.1) and now having errors using meltano at all. Should I be avoiding python 3.10 for meltano? suffering from pip pains
v
Yours is slightly different than the one above (and easier šŸ˜„ )
python -m ensurepip
if you run that my guess is you'll be off to the races (I don't use mac so maybe there's another step)
k
hm that's helped with pip! Pip seems fine, but still not with meltano
Copy code
% pipx install meltano
/Users/kcowie/.local/pipx/shared/bin/python: No module named pip
...
pipx.util.PipxError: '/Users/kcowie/.local/pipx/shared/bin/python -m pip --disable-pip-version-check install -q --upgrade pip setupt
ools wheel' failed
'meltano' already seems to be installed. Not modifying existing installation in
Copy code
% meltano --version
Traceback (most recent call last):
  File "/Users/kcowie/.local/bin/meltano", line 5, in <module>
    from meltano.cli import main
ModuleNotFoundError: No module named 'meltano'
v
did you try uninstalling with pipx uninstall meltano? It looks like pipx's python runtime is a bit wonky at
/Users/kcowie/.local/pipx/shared/bin/python
I tried a quick google on the pipx error and found https://github.com/pypa/pipx/issues/278 that looks to have an answer (reinstall pipx)
maybe you updated python versions or something and remove the old version or something, and pipx was left out of the know
Copy code
pipx reinstall-all
might do the trick too so it seems!
k
here's the output from reinstall, the log file just contains
/Users/kcowie/.local/pipx/venvs/meltano/bin/python: No module named pip
if you want a deeper dive into the log file, attaching latest
v
Reinstall all doesn't look good, did you try the uninstall pipx method?
k
yep! now reads
Nothing to uninstall for meltano 😓
v
From running what? the full uninstall of pipx returns that?
Solution
Well, I simply had to explicitly uninstall pipx from the old system Python version with
python3.7 -m pip uninstall pipx
and then reinstall it with the new system Python version with
python -m pip install --user pipx
, and reinstall all pipx packages.
Removing
~/.local/pipx
and reinstalling pipx also worked for me! Thanks.
Just copying from the issue 🤷
k
^^no that was
pipx uninstall meltano
. The log file is returned from installing again. I'll try those solutionsšŸ™‚
That's an improvement! I could try uninstalling 3.11?
uninstalled 3.11 and meltano is running 😃, back to adding taps with no trouble. But unfortunately, still seeing the original compiling error (that started in late October) when adding targets 😟.
Copy code
Loader 'target-postgres' could not be installed: failed to install plugin 'target-postgres'.
  error: subprocess-exited-with-error

  Ɨ python setup.py bdist_wheel did not run successfully.

...
 module.c:1:10: fatal error: 'Python.h' file not found
...
 ERROR: Failed building wheel for ciso8601
There are also some new pscyopg2 errors thrown in for target-postgres. I'll see if I can clean up Postgres and psychopg2 to make sure they're not dependent on the wrong thing. ....But not sure about the python header error. Will follow https://github.com/MeltanoLabs/Meta/issues/25
k
An update here, all is well now šŸ™‚! Fixed
target-csv
cisco wheel building failures by • re-installing pipx as @visch suggested, • removing meltano,
/.meltano
directory, and target-postgres from
meltano.yml
, • then specifying the python path, which made the difference:
Copy code
pipx install meltano --python /usr/local/bin/python3.10
To resolve the target-postgres issues with psycopg2, ran:
Copy code
pip install psycopg2_binary
brew install openssl
brew link openssl
# For compilers to find openssl@3:
export LDFLAGS="-L/usr/local/opt/openssl@3/lib"
export CPPFLAGS="-I/usr/local/opt/openssl@3/include"
c
So much easier on a GNU/Linux OS 😁