Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

You can't use onInit with pipe extension #603

Closed
jcubic opened this issue Jul 21, 2020 · 3 comments
Closed

You can't use onInit with pipe extension #603

jcubic opened this issue Jul 21, 2020 · 3 comments
Labels
Bug resolved if issue is resolved, it will be open until merge with master

Comments

@jcubic
Copy link
Owner

jcubic commented Jul 21, 2020

Issue summary

If you use onInit with pipe file included pipe is never initialized because pipe onInit is overwritten by options.

Expected behavior

I expect onInit to work the same with or without pipe extension

Actual behavior

Pipe don't work if there is onInit.

Steps to reproduce

  1. You can use Cowsay demo.
  2. Add onInit with echo that is after the function.
  3. Type fortune | say.
@jcubic jcubic added the Bug label Jul 21, 2020
@jcubic
Copy link
Owner Author

jcubic commented Jul 24, 2020

The onInit is executed but you can't use term variable only use this. One caveat is that you can't use exec to use Pipe interpreter.

@jcubic jcubic closed this as completed Jul 24, 2020
@jcubic jcubic added the Invalid label Jul 24, 2020
@jcubic
Copy link
Owner Author

jcubic commented Aug 6, 2020

reopening to document usage of term + exec with pipe.

@jcubic jcubic reopened this Aug 6, 2020
jcubic added a commit that referenced this issue Nov 27, 2020
This require breaking change set_interpreter return a promise now
@jcubic
Copy link
Owner Author

jcubic commented Nov 27, 2020

I was able to fix the issue, by invoking patched onInit when new pipe interpreter finished initializing, it require breacking change low level set_interpreter now return a promise.

@jcubic jcubic added the resolved if issue is resolved, it will be open until merge with master label Nov 27, 2020
@jcubic jcubic closed this as completed Nov 27, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug resolved if issue is resolved, it will be open until merge with master
Projects
None yet
Development

No branches or pull requests

1 participant