Git Product home page Git Product logo

bounties's People

Contributors

dzhelezov avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

bounties's Issues

Grafana-friendly squid to monitor block times

Motivation

Squid Archives proved to be an invaluable tool for Substrate developers. This bounty will bring additional utility by adding an additional monitoring squid, that can be launched against either one for the public Archives or a local archive (for devnets and testnets).

The squid can be tapped directly into grafana dashboards for monitoring and allow developers to monitor block times and validator statistics straight out of the squid in real time.

Bounty

To complete this bounty:

Bonus points:

  • Deploy a squid to Aquarium for a Polkadot and Kusama
  • Make a video on how to setup the Grafana and connect the dashboard to the deployed squid

Data validation tool for Giant Squid

Motivation

Giant Squid API is a one-stop-shop for Polkadot data, used by wallets and explorers like Calamar. The purpose of this bounty is to build a tool for cross-validating Giant Squid data against other data providers in the ecosystem:

  • Polkadot.js
  • Subscan
  • Sub.ID
  • Polkaholics

Implementation Strategies

One possible strategy is to mine a set of hand-picked data fixtures, which is then matched against the data served by the Giant Squid. Another option is to try to automatically scrape the relevant data from external sources.

Requirements

  • The tool should be easily runnable from a command line
  • The tool should provide reproducible results

Bonus points

Giant Squid Bugs reports and inconsistencies will be considered and awarded separately on the case-by-case basis

Resources

Docs: https://docs.subsquid.io/giant-squid-api/
Source code:

Develop an indexer for Moonbeam Assets

πŸ“ Short description

A Substrate blockchain often times implements the Assets pallet, which allows it to support multiple Assets. The value of Assets is, in the vast majority of cases, represented by tokens.

It is useful to track them and keep tabs on the total supply, the number of total users holding an Asset, the distribution, and other useful information.

πŸ”– Challenge

The project should be able to track and provide information about:

  • the Asset name
  • the Asset ID
  • the Asset symbol
  • the Asset owner
  • the Asset Issuer
  • the total supply of an Asset
  • the total number of holders
  • the historical data regarding activities on the Asset, such as:
    • Creation
    • Issuance
    • Transfer
    • Burning
    • Destroying
    • Freezing (of tokens and of Asset)
    • Thawing (of tokens and of Asset)
    • Change of Owner

This list above is not exhaustive and hackers are invited to investigate and implement indexing for additional Asset activities they find relevant. It is worth noticing that many of these activities are covered by Events generated by the Assets pallet, but some information can only be found in the Storage functions of such pallet.

βœ… Submission Requirements

The final work should be delivered via a Squid deployed to the Aquarium

πŸ§‘β€βš–οΈ Judging criteria

  • Data completeness and validity
  • Quality of usage of Subsquid's SDK
  • Documentation provided

πŸ“ Resources

Develop a tracker for the Gromlins NFT collection

πŸ“ Short description

Gromlins are the first collection to be featured in Raresama, the NFT marketplace by Moonsama project.
You are tasked with building a hypothetical backend for such marketplace, one that (for simplicity) exclusively tracks the Gromlins collection.

For this, we are providing you with the Gromlin's collection contract: 0xF27A6C72398eb7E25543d19fda370b7083474735
And the smart contract's ABI

πŸ”– Challenge

The project should be able to track and provide information about:

  • Token ID
  • Token name
  • Token symbol
  • Token's total supply
  • Token owner
  • Token metadata, including:
    • Gromlin attributes
    • NFT image
    • artist
    • description
  • historical transfers of tokens, including
    • seller
    • buyer
    • timestamp
    • block
    • transaction hash

βœ… Submission Requirements

The final work should be delivered via a Squid deployed to the Aquarium

πŸ§‘β€βš–οΈ Judging criteria

  • Data completeness and validity
  • Performance and elegance of the solution to access smart contract status
  • Quality of usage of Subsquid's SDK
  • Documentation provided

πŸ“ Resources

[$2000] Create a "DotSama Degen score" indicator (with Subsocial)

Short description

Create a "DotSama Degen Score" indicator, with sub.id integration.

Prize

$2000

Challenge

We came up with the idea of a β€œDotSama Degen score”, an account metric showing how degen is the account holder. It's calculated based on the wallet activity and should include:

  • crowdloan participation (taking into account the contribution amount and number of crowdloans)
  • staking
  • asset teleporting
  • is holding or traded Kanaria NFT on RMRK
  • commented, reacted, posted on Subsocial
  • traded NFTs on Singular, Unique and other NFT pratforms
  • Has transacted to/from Moonriver/Moonbeam
  • Has bridged to Moonriver/Moonbeam
  • Participated in DEX trading
  • Liquid staking on Acala/Karura

Much of the information above may be sourced from Giant Squid API. Note, however, that the API is experimental and may be updated or may be down for extended periods of time.

Submission Requirements

The submission must use one or multiple Squids or Subsquid's Super API to obtain the relevant information for the degen score

Judging Criteria

  • Data collection and exploration using Subsquid's SDK
  • Design of a weighting formula, along with justification
  • Integration with Sub ID

Resources

[$5000] Build a Moonsama NFT data explorer (with Moonsama)

Short description

Moonsama NFT on Moonriver has taken the Dotsama NFT space by storm. For this bounty you'd need to develop an explorer for a deep dive to Moonsama data

Prize Pool

$5000

Challenge

The explorer should satisfy the basic needs of Moonsama NFT holders and degens:

  • It should be possible to see recent trades and historical volumes
  • It should be possible to see current and historical floor price
  • It should be possible to see top holders
  • It shoud be possible to sort by rarity
  • It should be possible to see Moonsama NFTs hold by an address

This list above is not exhaustive and the teams may decide to implement other features for better UX.

πŸ“Hint:
It's likely one'd need to use the following Squid features:

Submission Requirements

The data should be taken from a single or multiple Squids deployed to the Aquarium

Judging criteria

  • Creativity and UX
  • Documentation provided

Resources

Status React component for Giant Squid APIs

Motivation

The goal of this bounty is to provide real-time information on the status of the Giant Squid API endpoints

Description

The bounty is a React component displaying the status of the Giant Squid endpoint together with the current block height of the network. For each network, the component should query an RPC endpoint to get the latest block, and then query the status of the GS endpoint by sending the status query:

query MyQuery {
  squidStatus {
    height
  }
}

One can take inspiration on the Archives Status page

Bonus points

Bonus points for making a PR to the Status page in Docs

New Giant Squid API: Delegate account -> Delegators (proxies)

Recently discussed for the upcoming hackathon, it would be fantastic if a new API was introduced to the Giant Squid service that returned a delegate's proxied accounts.

Currently to fetch a list of proxy accounts for a particular delegator, we query proxy.proxies on chain. The issue here is that we are querying the delegator account, and getting its delegates, and not the other way round, which is what Dapps require for a seamless UX.

This is an issue for Dapps because the accounts we are importing from wallets are delegates. We cannot query the chain right now and determine whether this delegate account is indeed a delegate - and for which type of proxy. We would need both the delegator and the delegate account imported in the Dapp to get this info (without explicitly telling the dapp that the delegate is indeed a delegate).

For more context, I have posted this issue on Substrate's repo and in the Polkadot forum, suggesting a reverse lookup be introduced to the proxy pallet, but we ultimately fell back to first principles of not having repeated data on-chain.

Substrate issue: paritytech/polkadot-sdk#204
Polkadot forum: https://forum.polkadot.network/t/proxies-to-have-delegate-proxies-reverse-lookup/2312

So we now look for an API to solve this problem, whereby we provide an account to an endpoint, and that endpoint return an array of proxied accounts (delegators [the account that registers the proxy]) and the proxy type. We can describe the call like so:

getProxiedAccounts(AccountId: string) -> Array<DelegateItem>

Where:

interface DelegateItem {
  delegator: string;
  proxyType: ProxyType;
}

type ProxyType =
  | 'Any'
  | 'NonTransfer'
  | 'Governance'
  | 'Staking'
  | 'IdentityJudgement'
  | 'CancelProxy'
  | 'Auction';

This would allow Polkadot apps like the staking dashboard to immediately determine whether the imported accounts have been registered as a proxy, and for which type. The supported proxy types planned for staking dashboard are the Staking and All proxy types.

For staking dashboard specifically, I envisage a Giant Squid plugin (turned on by default), that we can expand upon in the future to solve more problems like this. This proxy problem is a great first step in bootstrapping such a plugin.

[$5000] Build a block explorer from a Subsquid Archive

Short description

Prize

Total 5000 USDC. Successful projects will qualify for a fast-track grant application from Subsquid to develop a full-fledged explorer for Substrate chains.

Background

Archives provide a powerful tool for exploring on-chain data with an intuitive GraphQL interface. For example one can easily search for the recent XCM asset teleports on Kusama by navigating to the Kusama Archive console and running the following query:

query MyQuery {
  substrate_extrinsic(where: {name: {_eq: "xcmPallet.teleportAssets"}}, limit: 10, order_by: {blockNumber: desc}) {
    name
    args
  }
}

Similarly, one could easily search for the recent extrinsics signed by the given address (say E8ky1h79157Fpcm8cXFyYvRHhN5pb67z6MPcbQ9Z7kgiTV9):

query {
substrate_extrinsic(where: {signer: {_eq: "E8ky1h79157Fpcm8cXFyYvRHhN5pb67z6MPcbQ9Z7kgiTV9"}}, limit: 10, order_by: {blockNumber: desc}) {
    name
    signer
    args
  }
}

This exploration queries proved to be useful both for developers and users alike.

The explorer may also the following additional endpoints. Beware that these endpoints are currently in beta and may be change or be offline without any notice

Challenge

The challenge is to create a UI interface for the GraphQL backend provided by the archive. Below is a list of features that should be implemented. The teams may choose to build additional features based on the perceived UX.

  • It should be possible to see transaction details by a hash -- transaction arguments, emitted events, etc.
  • It should be possible to see transactions by the signer address
  • It should be possible to see events and transactions in a given block, both by height and block hash
  • It should be possible to filter events by event names
  • It should be possible to filter transaction by name
  • (big bonus) support EVM transaction hashes for Moonbeam and Astar archives

Submission Requirements

  • The submission must provide clear setup instructions
  • It should be possible to run the explorer against the public Archives run by Subsquid (see Subsquid Archive Registry) as well as against a locally run Archive (see setups here)
  • Bonus points for EVM-enabled archives

Judging Criteria

  • Creativity and the set of features will be the top criteria
  • Design, Ergonomics and UX
  • Code extensibility and maintainability
  • Ease of setup
  • Extra bonus for a creative use-case of the GraphQL API provided by Archives

Resources

squid-gen for Gear programs

Objective

The objective of the bounty is to simply building indexers for Gear program using Squid SDK. While Squid SDK is a powerful and flexible tool to extract and transform Gear messages (see doc) the learning curve is arguably steep. A squid-gen is a tool that generates a turn-key indexer just based on the program metadata. It may be then used as is or a starter pack for further customisations by the developer.

For Gear programs, the squid gen should take the metadata file as a parameter, and output a squid code that indexes decoded messages sent and received by the program into the target database. For the current bounty the scope of the target database is limited by Postgres DB.

SquidGen design

Currently there are already squid gen tools for EVM and Ink! contracts. A squid gen consists of a

  • a template github repo (say https://github.com/subsquid-labs/squid-gear-program-template)
  • a tool to generate the Squid SDK code specific to the program, accepting the gear metadata file as an input argument (let's name it gear-squid-gen)

The user flow is the follows:

  1. Init a squid using the template:
sqd init my-gear-squid -t https://github.com/subsquid-labs/squid-gear-program-template

The template should include the squid gen tool as a dev dependency in package.json

  1. Install the dependecies:
cd my-gear-squid
npm i
  1. Add the gear program metadata file and run the squid gen tool
npx gear-squid-gen --metadata my.program.metadata.wasm

The generator should output:

  • schema.graphql -- schema definition
  • processor.ts -- main processor code
  • types.ts -- types for messages

The squid should persist all in and out messages to/from the Gear program into the target database using ctx.strore.save() method

Deliverables

References

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.