raritygems
Provably Rare Gem Raritygems API, currently focused on mining.
Run on Google Colab
# 1. Install packages
# !pip install --force-reinstall jsonschema==3.2.0
!python --version
!python -m pip --version
!pip install web3==5.23.0
!pip install raritygems==0.5.0
# 2. Download "raritygems_salt_finder" and give permission to execute
!wget --no-check-certificate 'https://docs.google.com/uc?export=download&id=10K-ZTxj14_BrY_ZxupvOkGXYl2Eo9mEq' -O raritygems_salt_finder
!chmod 755 raritygems_salt_finder
# 3. Run with Python
from raritygems import raritygems
david = raritygems.Miner(
user_address="0xxxxx",
gem_kind=0, # 0 = Turquoise, 1 = Pearl, ...
salt_finder_path="/content/raritygems_salt_finder",
private_key="", # if "" is provided then it will only find a salt then exit
line_token="", # if "" is provided then it will not notify you via LINE
)
david.mine()
note
- If you got "jsonschema" error then click "Runtime > Restart and run all".
- "raritygems_salt_finder" is built by golang code that can be found here https://github.com/jojoee/raritygems/blob/master/main.go
- You can check more about gem kind here
How it works?
It basically finds a "salt" and sign a transaction for you. The program will do the following
- Get the information that needed for mining:
user_nonceandgem_difficulty - Use raritygems_salt_finder to find a salt
- Sign a transaction to claim a gem
- Go back to step 1.
raritygems_salt_finder
At first, I start with Python and try to optimize it but I realize Go is must faster. So, I write this "raritygems_salt_finder" part with Go language instead, and this is command I used to built it.
# to build "raritygems_salt_finder"
go build -o raritygems_salt_finder main.go
go build -o raritygems_salt_finder-0.5.0 main.go
# to build "raritygems_salt_finder" for Google Colab
GOOS=linux GOARCH=amd64 go build -o raritygems_salt_finder_linux main.go
GOOS=linux GOARCH=amd64 go build -o raritygems_salt_finder_linux-0.5.0 main.go
Feature
- mining: auto update
gem_difficulty - lint: setup linting: flask8
- ci-cd: pypi: publish to pypi
- ci-cd: CI & CD with GitHub Actions
- ci-cd: integrate semantic release
- test: writing automated test
- perf: performance evaluation
- info: display your current balance
- info: display your gems
- info: estimate how many times you can mine (before your have no gas left)
- gas: optimize gas price
- parallel: make it support parallel / multi-threading
- gpu: create GPU support version
- noti: refactor notification message
- noti: add more channels e.g. Facebook Messenger, email
- web3: auto claim gems
- network: support Ethereum chain
- network: support Fantom network
- info: bot nickname
- salt_finder: auto load by default when it is not provided
Project setup & CMD
TODO
conda create --name raritygems python=3.7.11
conda activate raritygems
pip uninstall raritygems -y && pip install .
go run main.go \
-user-nonce=1234 \
-user-address=0x28bc92e7b7e77d348fd262fb8e29da129308fbd3 \
-chain-id=250 \
-gem-difficulty=535996 \
-gem-address=0x342EbF0A5ceC4404CcFF73a40f9c30288Fc72611 \
-gem-entropy=0x000080440000047163a56455ac4bc6b1f1b88efadf17db76e5c52c0ca594fd9b \
-gem-kind=0 \
-salt=41543544848 \
-n=800000 \
-debug=true
Other projects
Ref
Metadata
Release files for raritygems 0.6.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| raritygems-0.6.0.tar.gz | 6.5 kB | Without provenance | Details for raritygems-0.6.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| raritygems-0.6.0-py3-none-any.whl | Python 3 | none | any | Details for raritygems-0.6.0-py3-none-any.whl |
Total release size: 14.5 kB
Release files / raritygems-0.6.0.tar.gz
| Download URL | raritygems-0.6.0.tar.gz |
|---|---|
| Size | 6.5 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f8941d9ae955653f033fac51f1735083041dce7fa205c1f8c99c2f0f9bfd7952
|
|
BLAKE2b-256 checksum How to use checksums |
82324574e29b19aefff0037958398b994e5de787a434bc4049a60a7abc9dcf87
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.7.12
|
Release files / raritygems-0.6.0-py3-none-any.whl
| Download URL | raritygems-0.6.0-py3-none-any.whl |
|---|---|
| Size | 7.9 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
eeffaaabcfa2abca4af59ee8a9a6f95fdb697ff9c51006034947afe580e1c0b3
|
|
BLAKE2b-256 checksum How to use checksums |
28d6b35adb560d7332c6b7f6c7618bf35cfbaffa90624a65147bc72b5f6a8165
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.2 importlib_metadata/4.8.1 pkginfo/1.7.1 requests/2.26.0 requests-toolbelt/0.9.1 tqdm/4.62.3 CPython/3.7.12
|
Security for raritygems 0.6.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.