graphprotocol / graph-network-subgraph

The subgraph, the smart contracts, the tests, and documents for the Graph Explorer Decentralized Application
MIT License
70 stars 45 forks source link

Assign creatorAddress in handleSubgraphPublishedV2 #192

Closed mnlesane closed 2 years ago

mnlesane commented 2 years ago

The creatorAddress field has not been assigned for subgraphs created after 2022-02-23, as the graphAccount param is no longer associated with the SubgraphPublished event for v2. This PR uses event.transaction.from instead.

Demonstration: https://thegraph.com/hosted-service/subgraph/mnlesane/graph-network-mainnet


  subgraphs(orderBy:createdAt, orderDirection:desc
  ) {
    id displayName creatorAddress
  }
}```
juanmardefago commented 2 years ago

Hey @mnlesane! Looks good! I'm going to merge it to mainnet-staging now that we got the workflows back to a state where it's only going to be deploying to staing on pushes there.

I'm also gonna merge #182 there, and check if everything works as expected afterwards, before moving it to production!

Thanks a ton for the contributions and sorry for the long delays!