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

Programmatic use: "additional options" aren't additional #2247

Closed
jerrygreen opened this issue Apr 4, 2022 · 2 comments
Closed

Programmatic use: "additional options" aren't additional #2247

jerrygreen opened this issue Apr 4, 2022 · 2 comments

Comments

@jerrygreen
Copy link

In the docs, Programmatic usage section, this code is mentioned:

  // Additional API options
  stdout?: ...,
  stderr?: ...,
  readFile?: ...,
  writeFile?: ...,
  listFiles?: ...,
  reportDiagnostic?: ...,
  transforms?: ...

When I try the simplest code like this:

asc.main(['myModule.ts'])

I'm getting errors then:

Error: 'options.stdout' must be specified

When I pass options.stdout, it raises error about stderr requirement, then readFile, etc.

Those options, though called "additional"... Aren't additional.

Due to the issue #2241, I'm not using the most recent version and instead I'm using assemblyscript@0.19.23, but this "additional" problem seems to be around for an eternity anyway, and I guess it is present in the recent versions, too.

Please make this programmatic usage to be what it's shown to be: make additional options truly additional. Thanks.

@dcodeIO
Copy link
Member

dcodeIO commented Apr 4, 2022

This is fixed in 0.20, where stdout and stderr now default to a memory stream.

@jerrygreen
Copy link
Author

Ok, then I'm closing this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants