Skip to content

Update AssemblyScript to 0.19.10 #690

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

Merged
merged 28 commits into from
Aug 10, 2021
Merged

Conversation

evaporei
Copy link
Contributor

@evaporei evaporei commented Jun 15, 2021

This PR:

  • Updates AssemblyScript dependency on package.json
  • Updates codegen for the newer version
  • Adds migration changes for apiVersion on subgraphs

What's missing:

  • throw error when subgraph's apiVersion isn't the one with the newest AssemblyScript version

Related PRs:

@evaporei evaporei requested review from schmidsi and leoyvens June 15, 2021 19:39
@evaporei evaporei self-assigned this Jun 15, 2021
@evaporei evaporei changed the title Update AssemblyScript Update AssemblyScript to 0.19.2 Jun 15, 2021
@evaporei
Copy link
Contributor Author

I'll fix the tests soon, it seems that's because it's pointing to the wrong graph-ts. Let me just open that PR first 🙂

Copy link
Contributor

@schmidsi schmidsi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm not very deep into this codebase, but it looks good. Can't wait for this update actually.

@evaporei evaporei force-pushed the otavio/update-assembly-script branch 15 times, most recently from 47f0bc3 to ff558fe Compare June 25, 2021 20:51
@evaporei evaporei force-pushed the otavio/update-assembly-script branch 5 times, most recently from fa64647 to b829070 Compare July 1, 2021 23:42
evaporei added 21 commits August 9, 2021 20:37
This isn't completly necessary, but version 10 isn't
supported anymore and the new graph-ts version will
support these three as well. Keeping it standardized
seems a good fit :)
This needs to stay commented while we don't release a docker
tag that can handle both versions of AssemblyScript in its runtime.
Sometimes the AssemblyScript compiler would crash and that is done
internally by calling process.exit, which is terrible for catching
errors.

To fix this I've added a listener for the process.exit event, and
I remove it if the compiler succeds.
Without this the tests would break because
manifest.{dataSources, templates} weren't Arrays so
they didn't have the Array.prototype.some method.
@evaporei evaporei force-pushed the otavio/update-assembly-script branch from 3ae1a69 to d35134b Compare August 9, 2021 23:39
@evaporei evaporei force-pushed the otavio/update-assembly-script branch from 435b79e to c81aac9 Compare August 10, 2021 22:47
This is very important because before we would download
graph-cli from the latest version to run the tests against it.

However this is bad, because we could not be sure a new version
passes against the tests from the example folder, since the release
needed to be done before (it would go to master still pointing to
the old version).

This commit fixes the issue by pointing to the local graph-cli
so that the example tests fail before we do a release. This also
removes the necessity to bump the version everytime on these files.
@evaporei evaporei force-pushed the otavio/update-assembly-script branch from c81aac9 to bedf4c2 Compare August 10, 2021 22:50
@evaporei evaporei merged commit abcdb79 into master Aug 10, 2021
@evaporei evaporei deleted the otavio/update-assembly-script branch August 10, 2021 23:21
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

Successfully merging this pull request may close these issues.

3 participants