Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: print-env when missing data #44

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open

fix: print-env when missing data #44

wants to merge 2 commits into from

Conversation

Cifko
Copy link
Collaborator

@Cifko Cifko commented May 23, 2024

When missing some data, print everything you can instead of failing.

@Cifko Cifko requested a review from jorgeantonio21 May 23, 2024 14:40
@@ -2,15 +2,19 @@ use crate::prelude::*;

pub(crate) async fn command(context: &mut Context) -> Result<()> {
let package = context.unwrap_package_id();
let atoma_db = context.get_or_load_atoma_db().await?;
let manager_badge = context.get_or_load_db_manager_badge().await?;
let atoma_db = context.get_or_load_atoma_db().await.ok();
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How did you encounter this error anyway? There should always be atoma DB and manager badge if you provide a correct package ID. Not sure if we should be silent on the error because that means something went very wrong.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

when I register a node from a non admin account

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Doesn't matter if it's non admin or not, everyone needs to know atoma DB and everyone can know it. What error did you get? Can you replicate? You cannot register a node without knowing the object ID of the DB.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants