Let's take the example of the SimpleStorage contract that comes with the truffle box drizzle-box

How can we listen to the event StorageSet and console.log it to the JS console?


import SimpleStorage from './../build/contracts/SimpleStorage.json'

const drizzleOptions = {
web3: {
    block: false,
    fallback: {
    type: 'ws',
    url: 'ws://'
contracts: [
events: {
    SimpleStorage: ['StorageSet'],
polls: {
    accounts: 1500

export default drizzleOptions

2 Answers 2


I guess you use Metamask, so the problem might be the following: "The current provider doesn't support subscriptions: MetamaskInpageProvider".

I don't either see this error message, since drizzle doesn't print it. You can have a look here. On this way, you should be able to test that event subscription thing on your own/manually. Something like that:

    .StorageSet({/* eventOptions */}, (error, event) => {
        console.log(error, event);
    .on('data', (event) => console.log(event))
    .on('changed', (event) => console.log(event))
    .on('error', (error) => console.log(error));

Here you can find the documentation for web3 events.

Optionally, you could check for events in the transaction receipt.

  • I can indeed reproduce this. I wonder how drizzle is useful in production where you only have MM as a provider? Did you find a solution @marius?
    – pors
    Commented Oct 5, 2018 at 6:56

I'm attempting to do a similar thing but from my understanding, Drizzle does not yet support this. Here's the issue I found to track it: https://github.com/trufflesuite/drizzle/issues/147

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.