https://github.com/anynodes/shdw-node-stats
Science Score: 26.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
○CITATION.cff file
-
✓codemeta.json file
Found codemeta.json file -
✓.zenodo.json file
Found .zenodo.json file -
○DOI references
-
○Academic publication links
-
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (14.3%) to scientific vocabulary
Repository
Basic Info
- Host: GitHub
- Owner: AnyNodes
- License: mit
- Language: Python
- Default Branch: main
- Size: 110 KB
Statistics
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
- Releases: 30
Metadata Files
README.md
shdw-node-stats
This Python package, shdw-node-stats, is designed to fetch and record information about blockchain nodes. It has two features:
Retrieve data such as the node's rank, total rewards, and status from a specified API endpoint, then records this information in a CSV file for chart purpose if you need.
Send notification to your Telegram when the node status is
not_eligible.
Installation
This package has been published to pypi: https://pypi.org/project/shdw-node-stats/
To install shdw-node-stats as a package, simply use pip:
pip install shdw-node-stats
This command installs shdw-node-stats along with all required dependencies. Ensure you have Python installed on your system (version 3.8 or later is recommended).
Usage
As a Standalone Script
If you prefer to use NodeStats.py as a standalone script:
Ensure you have Python installed on your system (version 3.8 or later is recommended) and clone the repository or download the script.
Install the required dependencies:
pip install -r requirements.txt
Prepare a file named
nodes.txtornodes.jsonwith the node addresses.Run the script from the terminal or command prompt:
python3 NodeStats.py
As a Python Package
To install shdw-node-stats as a package, simply use pip:
pip install shdw-node-stats
This command installs shdw-node-stats along with all required dependencies. Ensure you have Python installed on your system (version 3.8 or later is recommended). After installing shdw-node-stats via pip, you can use it in your Python scripts as follows:
Prepare a file named
nodes.txtornodes.jsoncontaining the addresses of the nodes you wish to query.Use the package in your script:
```python from shdwnodestats import NodeStats
Assuming you have a 'nodes.txt' or 'nodes.json' file in your current directory
nodestats = NodeStats('nodes.txt') # or NodeStats('nodes.json') nodestats.run() ```
This will fetch the node information and output it to a CSV file named node_rankings.csv.
File Formats Supported
- JSON (.json): Should contain an array of node addresses.
- Text (.txt): Should contain node addresses, one per line.
Output
Both usage methods generate a CSV file named node_rankings.csv, which includes the following columns: Timestamp, Node Address, Rank, Rewards, and Status. The console output will display the node information and the total rewards accumulated by the nodes listed in the input file.
Community Contribution
Contributions are what make the open-source community such an amazing place to learn, inspire, and create. Any contributions you make are greatly appreciated.
If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement".
Don't forget to give the project a star! Thanks again!
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature) - Commit your Changes (
git commit -m 'Add some AmazingFeature') - Push to the Branch (
git push origin feature/AmazingFeature) - Open a Pull Request
License
Distributed under the MIT License. See LICENSE for more information.
Note
This package/script is intended for educational and demonstration purposes. It showcases how to interact with web APIs, process data in Python, and write output to a CSV file. Ensure you have the necessary permissions to use the API and data.
Owner
- Name: AnyNodes
- Login: anynodes
- Kind: user
- Website: anynodes.org
- Repositories: 1
- Profile: https://github.com/anynodes
GitHub Events
Total
Last Year
Issues and Pull Requests
Last synced: 7 months ago
All Time
- Total issues: 0
- Total pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Total issue authors: 0
- Total pull request authors: 0
- Average comments per issue: 0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 0
- Pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Issue authors: 0
- Pull request authors: 0
- Average comments per issue: 0
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
Pull Request Authors
Top Labels
Issue Labels
Pull Request Labels
Packages
- Total packages: 1
-
Total downloads:
- pypi 11 last-month
- Total dependent packages: 0
- Total dependent repositories: 0
- Total versions: 15
- Total maintainers: 1
pypi.org: shdw-node-stats
A tool to fetch and record ShadowDrive node statistics from an API and save them to a CSV file.
- Documentation: https://shdw-node-stats.readthedocs.io/
- License: MIT
-
Latest release: 0.4.1
published almost 2 years ago
Rankings
Maintainers (1)
Dependencies
- actions/checkout v4 composite
- actions/setup-python v5 composite
- python-semantic-release/python-semantic-release master composite
- requests >=2.25.1
- requests *