Michael Garcia avatar

Use nectar without using hive-nectar?

thecrazygm

Published: 29 Mar 2025 › Updated: 29 Mar 2025Use nectar without using hive-nectar?

Use nectar without using hive-nectar?

Let me explain...

Been trying to get the attention of people for our proposal and just to show people how important this stuff is to me, I step out of my comfort zone and try to show how it could be important for people that don't even use python or hive-nectar.

nectarflower profile

The account_json_metadata of nectarflowerHive account@nectarflower, which when done will be updated hourly, contains a the list of working nodes and benchmarks against them. I'm running it daily as I'm still working out bugs and make it nice. Along with the metrics and pretty output that nectarflowerHive account@nectarflower will put out daily.

Seems like something pretty useful? No?

So, I broke out of my comfort zone and wrote a little function in javascript to use dhive to query the data and create a new instance with the updated nodelist. So, now my dhive apps and scripts will use the most up to date nodelist based on benchmark scores. Pretty sweet I think.

// Example usage
updateNodesFromAccount('nectarflower')
  .then(updatedClient => {
    console.log('Node update complete');
    // Use the updated client for further operations
    return updatedClient.database.getDynamicGlobalProperties();
  })
  .then(result => {
    console.log('Test query with updated client successful:', result.head_block_number);
  })
  .catch(error => {
    console.error('Error:', error);
  });

I don't know about you, but I hate when my scripts and cron jobs and such die because your favorite node is down. I find it frustrating, and the fullnodeupdateHive account@fullnodeupdate account hasn't been updated since '22, which is what beem uses. Well, in order to make hive-nectar work as it's supposed to, that is a very integral part of it. So, I've been reverse engineering the benchmarks and output to match as close as possible, with some bonus data.

The full source of the updateNodesFromAccount{'nectarflower') example can be found it's own github repo here: https://github.com/TheCrazyGM/nectarflower-js

So, even if you don't believe that beem hive-nectar needs to exist, I feel it's pretty important stuff that we are doing for the community as a whole.

Maybe this will help someone, maybe it won't. But it is the kind of stuff I do daily just because I enjoy doing it. Perhaps you will support our vision:
Proposal 339: A modular open-source development framework with critical library maintenance.

As always,
Michael Garcia a.k.a. TheCrazyGM

Leave Use nectar without using hive-nectar? to:

Written by

Solving IT puzzles and crafting Python solutions. When not coding, I'm rolling dice in RPGs, navigating Linux (MCMXCVI), and keeping a keen eye on the Crypto space.

Read more #nectar posts


Best Posts From Michael Garcia

We have not curated any of thecrazygm's posts yet. But you can encourage our curation team to review posts by visiting them regularly and by referring other readers. Because we give priority to frequently read content.

More Posts From Michael Garcia