-3

https://thegraph.com/docs/en/developing/creating-a-subgraph/#data-source-templates

The Graph supports starting a dynamically instantiated data source from a block earlier than the current block? The dynamic data source instantiated from a template begins processing events from the block where the .create() function was called. Is this correct?

What I wanna do is not to create a collection but to add an existing collection to the factory. In this case, I simply add a function which emits same events as the collection is created to the factory contract. But mapping function of factory contract works but template mapping function doesn't detect the minting events.

dolchain
  • 9
  • 2
  • Please read the mouse-over infos for the tags you selected. In one case it is surely wrong, in at least one other I highly doubt it is correct. Also please read [ask] and take the [tour]. Also, though perfect English is not required here, you should go and make fun of whoever told you that "wanna" is an English word suitable for an attempt to give a matter-of-fact impression, e.g. when trying to ask people for their help in their spare time. – Yunnosch Aug 18 '23 at 17:14

1 Answers1

0

Yes. It starts processing events from the block where the .create() function was called.

You can review Part 9 at https://thegraph.academy/developers/defining-a-subgraph/

What you ran into is incapability to process the historical data. Currently, I am not sure if there is a way to fetch past events without reading the current state of the contract? see this screenshot

Levi Morin
  • 16
  • 3
  • As it’s currently written, your answer is unclear. Please [edit] to add additional details that will help others understand how this addresses the question asked. You can find more information on how to write good answers [in the help center](/help/how-to-answer). – Community Aug 22 '23 at 13:28