Skip to content

Fix jug drip initializer#63

Merged
rmulhol merged 2 commits intostagingfrom
fix-jug-drip-initializer
Dec 13, 2019
Merged

Fix jug drip initializer#63
rmulhol merged 2 commits intostagingfrom
fix-jug-drip-initializer

Conversation

@rmulhol
Copy link
Copy Markdown
Contributor

@rmulhol rmulhol commented Dec 13, 2019

Fixes an oversight from my previous PR 😅

Second commit is not as urgent but felt like a worthwhile simplification - can remove if others aren't on board

- Populate config and pass non-nil converter
- Since we're passing the db connection as an arg and no longer
  setting it as a property of the converter, we no longer need
  the initializer to have a pointer to the converter
@rmulhol rmulhol force-pushed the fix-jug-drip-initializer branch from be83956 to 6a748ac Compare December 13, 2019 04:31
Copy link
Copy Markdown
Contributor

@gslaughl gslaughl left a comment

Choose a reason for hiding this comment

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

:shipit:

Nice catch! Would be nice if we could use our actual initializers in our integration tests. I can't remember why we're not but I'm sure there's a good reason 🤔

@rmulhol
Copy link
Copy Markdown
Contributor Author

rmulhol commented Dec 13, 2019

Interesting thought! I'd definitely be in favor of using more of our actual source code in the integration tests 👍

I think the main reason we aren't doing this now is to make it easier to configure the block number that the transformer executes over. The initializer derives the starting block number from the config, and returns a struct implementing the EventTransformer interface (where the config is no longer writable). Going to put a story on the board to consider whether we should enable setting the configured block number so that the integration tests can use the initializers

Copy link
Copy Markdown
Contributor

@elizabethengelman elizabethengelman left a comment

Choose a reason for hiding this comment

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

:shipit:

@rmulhol rmulhol merged commit 8bc3b38 into staging Dec 13, 2019
@rmulhol rmulhol deleted the fix-jug-drip-initializer branch December 13, 2019 15:46
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