-
Notifications
You must be signed in to change notification settings - Fork 4
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
Separate types definition from the sdk so web app client side could import them #50
Conversation
4123d38
to
76b62bd
Compare
@v9n, could you help take a look the below home runner path issue in the failed tests? Based on the config of
tests running locally could resolve the path reference such as |
export TEST_API_KEY="$(docker compose exec aggregator /ava create-api-key --role=admin --subject=apikey)" | ||
export ENDPOINT="localhost:2206" | ||
yarn test |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we need to run yarn run build
somewhere? or it's automatically run ? the test is still import from the dist
file, not from the typescript file so we still need to ru build before test.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, if we need dist files, yarn build
from the root is required.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
looks good to me. i think we do need to run build
somewhere before test run to generate the dist package
Fix #49. This solves the
http2
issue that blocked import on the next.js client side. Thehttp2
is required by@grpc/grpc-js
depenedency which we can’t really get rid of, so my idea is to create a separate light-weight library for the types import.These changes have been published into the following libraries, and tested in web app.
@avaprotocol/sdk-js@1.3.0
@avaprotocol/types@0.9.2-dev.0
Note that
Since we need yarn workspace for the monorepo, I switched from npm to
yarn
for managing depenedencies.There are a few changes before this PR that were accidentally checked into main: