This PR is part of the effort to improve strategy interface and increase ease of adding new contracts.
I recommend reviewing individual commits. Combining comments from individual commits here:
Strategies can now optionally define outputFilename in crawlPath. For the following crawl path.
{
name: "get-tokenuri",
extractor: {
args: [resolve(env.DATA_DIR, "soundxyz-call-tokenuri-transformation")],
outputFilename: "soundxyz-get-tokenuri"
},
transformer: {},
}
The results for get-tokenuri will be written to soundxyz-get-tokenuri-extraction.
Added a generic call-tokenuri strategy to remove the need for diffferent strategies such as soundxyz-call-tokenuri, zora-call-tokenuri, catalog-call-tokenuri etc.
The benefits include:
- Less number of files to mantain
- Easier to refactor
- Easier to integrate new indie contracts
This new call-tokenuri strategy has been modified to not need logs-to-subgraph strategy. I have tested this strategy and the output files are the same as before.
Future scope of work:
- Remove no longer needed strategies such as *-call-tokenuri.
- Create more such blueprint strategies. Maybe we can combine all filter-contracts strategies.
- Remove call-tokenuri strategy factory.