Skip to content

Commit

Permalink
Merge pull request #16 from protofire/develop
Browse files Browse the repository at this point in the history
UI Fixes, API Definition and CODE_OF_CONDUCT
  • Loading branch information
cmalfesi authored Jan 28, 2021
2 parents de14c55 + 9ed6ba0 commit e0e42e3
Show file tree
Hide file tree
Showing 12 changed files with 355 additions and 28 deletions.
8 changes: 6 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
# Changelog

## 1.0.3
Published by **[jarcodallo](https://github.com/jarcodallo)** on **2021/01/28**
- [#16](https://github.com/protofire/polkadot-mempool-explorer/pull/16) UI Fixes, API Definition and CODE_OF_CONDUCT

## 1.0.2
Published by **[jarcodallo](https://github.com/jarcodallo)** on **2021/01/26**
- [#13](https://github.com/protofire/polkadot-mempool-explorer/pull/15) UI Fixes
- [#15](https://github.com/protofire/polkadot-mempool-explorer/pull/15) UI Fixes

## 1.0.1
Published by **[jarcodallo](https://github.com/jarcodallo)** on **2021/01/26**
- [#13](https://github.com/protofire/polkadot-mempool-explorer/pull/14) Fix extrinsic URL and added empty data component.
- [#14](https://github.com/protofire/polkadot-mempool-explorer/pull/14) Fix extrinsic URL and added empty data component.

## 1.0.0
Published by **[jarcodallo](https://github.com/jarcodallo)** on **2021/01/19**
Expand Down
52 changes: 52 additions & 0 deletions CODE_OF_CONDUCT.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
# Contributor Covenant Code of Conduct

## Our Pledge

In the interest of fostering an open and welcoming environment, we as contributors and maintainers pledge to making participation in our project and our community a harassment-free experience for everyone, regardless of age, body size, disability, ethnicity, gender identity and expression, level of experience, nationality, personal appearance, race, religion, or sexual identity and orientation.

## Our Standards

Examples of behavior that contributes to creating a positive environment include:

* Using welcoming and inclusive language
* Being respectful of differing viewpoints and experiences
* Gracefully accepting constructive criticism
* Focusing on what is best for the community
* Showing empathy towards other community members

Examples of unacceptable behavior by participants include:

* The use of sexualized language or imagery and unwelcome sexual attention or advances
* Trolling, insulting/derogatory comments, and personal or political attacks
* Public or private harassment
* Publishing others' private information, such as a physical or electronic address, without explicit permission
* Other conduct which could reasonably be considered inappropriate in a professional setting

### Facilitation, Not Strongarming

We recognise that this software is merely a tool for users to create and maintain their blockchain of preference. We see that blockchains are naturally community platforms with users being the ultimate decision makers. We assert that good software will maximise user agency by facilitate user-expression on the network. As such:

* This project will strive to give users as much choice as is both reasonable and possible over what protocol they adhere to; but
* use of the project's technical forums, commenting systems, pull requests and issue trackers as a means to express individual protocol preferences is forbidden.

## Our Responsibilities

Project maintainers are responsible for clarifying the standards of acceptable behavior and are expected to take appropriate and fair corrective action in response to any instances of unacceptable behavior.

Project maintainers have the right and responsibility to remove, edit, or reject comments, commits, code, wiki edits, issues, and other contributions that are not aligned to this Code of Conduct, or to ban temporarily or permanently any contributor for other behaviors that they deem inappropriate, threatening, offensive, or harmful.

## Scope

This Code of Conduct applies both within project spaces and in public spaces when an individual is representing the project or its community. Examples of representing a project or community include using an official project e-mail address, posting via an official social media account, or acting as an appointed representative at an online or offline event. Representation of a project may be further defined and clarified by project maintainers.

## Enforcement

Instances of abusive, harassing, or otherwise unacceptable behavior may be reported by contacting the project team at <[email protected]>. The project team will review and investigate all complaints, and will respond in a way that it deems appropriate to the circumstances. The project team is obligated to maintain confidentiality with regard to the reporter of an incident. Further details of specific enforcement policies may be posted separately.

Project maintainers who do not follow or enforce the Code of Conduct in good faith may face temporary or permanent repercussions as determined by other members of the project's leadership.

## Attribution

This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4, available at https://contributor-covenant.org/version/1/4

[homepage]: https://contributor-covenant.org
24 changes: 18 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,17 @@ Mempool Explorer allow users to monitor pending transactions on [Polkadot](https

## Demo

[https://mempool.dot.protofire.io](https://mempool.dot.protofire.io)
[mempool.dot.protofire.io](https://mempool.dot.protofire.io)

## Custom Polkadot Node

In order to track extrinsics lifecycle. We added a new RPC method ([author_trackExtrinsic](https://github.com/protofire/polkadot-mempool-explorer/blob/develop/api/services/polkadot/custom-rpc-methods.js)) on [Substrate core](https://github.com/jarcodallo/substrate/blob/master/client/rpc-api/src/author/mod.rs).

This basically allows someone to subscribe and track status changes in the extrinsics lifecycle, for example movements getting in or out of queues, and everything that matters for us before including those extrinsics in blocks.

- Substrate change: https://github.com/jarcodallo/substrate/commits/master
- Polkadot dependencies update: https://github.com/jarcodallo/polkadot/commits/master
- Docker image of the polkadot binary: https://hub.docker.com/repository/docker/jarcodallo/polkadot
- Substrate change: [github.com/paritytech/substrate](https://github.com/jarcodallo/substrate/commits/master)
- Polkadot dependencies update: [github.com/paritytech/polkadot](https://github.com/jarcodallo/polkadot/commits/master)
- Docker image of the polkadot binary: [hub.docker.com/polkadot](https://hub.docker.com/repository/docker/jarcodallo/polkadot)

## Get Started

Expand All @@ -30,7 +30,7 @@ In the project directory, you can run:
### `npm start:dev`

Runs the docker containers in the development mode.\
Open [http://localhost:8084](http://localhost:8084) to view it in the browser.
Open [localhost:8084](http://localhost:8084) to view it in the browser.

The page will reload if you make edits.\
You will also see any lint errors in the console.
Expand Down Expand Up @@ -83,6 +83,18 @@ Displays log output from custom `polkadot-westend` service.

Displays log output from custom `polkadot-main` service.

## Mempool Explorer API Definition

<p align="center"><img src="./assets/swagger.png"/></p>

You can read more about the API Definition [here](https://mempool.dot.protofire.io/api/v1/api-docs).

## Contributing

### Code of Conduct

[Code of Conduct](CODE_OF_CONDUCT.md)

## License

Mempool Explorer is [Apache 2.0 licensed](LICENSE).
Mempool Explorer is [Apache 2.0 licensed](LICENSE).
15 changes: 14 additions & 1 deletion api/package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion api/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "api",
"version": "1.0.2",
"version": "1.0.3",
"engines": {
"node": ">= 14.0.0"
},
Expand All @@ -25,6 +25,7 @@
"moment": "^2.29.1",
"pino": "^6.8.0",
"pino-http": "^5.3.0",
"swagger-ui-express": "^4.1.6",
"uuid": "^8.3.2"
},
"devDependencies": {
Expand Down
2 changes: 1 addition & 1 deletion api/routes/explorer.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ router.get('/networks', (req, res) => {
}
});

router.get('/networks/:networkId/reset', async (req, res) => {
router.post('/networks/:networkId/reset', async (req, res) => {
try {
await PolkadotService.resetWatchPendingExtrinsics(req.params.networkId || '');

Expand Down
Loading

0 comments on commit e0e42e3

Please sign in to comment.