hauntsaninja / pyp

Easily run Python at the shell! Magical, but never mysterious.
MIT License
1.41k stars 39 forks source link

failure in pipetools example in documentation #16

Closed dbieber closed 4 years ago

dbieber commented 4 years ago

I tried this example from the README: seq 1 110 | pyp 'lines > foreach(int) | where(X > 100) | group_by(X % 3) | sort_by(X[0])'

but I get the error ModuleNotFoundError: No module named 'X'.

I do have from pipetools import * in my config.

dbieber commented 4 years ago

Hmm, I see there is pipetools.X, so I must not have the config set up right. Let me check that.

dbieber commented 4 years ago

Yes, it was just an environment variable issue. Please disregard. :)

hauntsaninja commented 4 years ago

Thanks for reporting, it's still possible for pyp to produce a more helpful error in this case. I just pushed https://github.com/hauntsaninja/pyp/commit/f716a84922abac805b892a514949378c5991ab1f and I'll cut a new release with it soon.