-
Notifications
You must be signed in to change notification settings - Fork 932
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
Rename nID
to namespace
where applicable
#2301
Comments
Re 2. We want to move on Namespace from the app once it becomes a single slice. IIRC, with aligned on that in sync. When and how can we do it? Node team can help there |
I don't think celestia-app can make this change in the short-term b/c it's breaking and we've already cut celestia-app v1.0.0-rcs. IIRC celestia-node doesn't want to adopt the existing celestia-app |
That's fair. The good thing is the change is not consensus-breaking, so we can still do it. Adding it to my list of things to take during share pkg extraction. Meanwhile, cleaning up and defining the type in celestia-node makes total sense. Assigning this on me. |
@rootulp, thinking about this more, the namespace in NMT should be called just the namespace then as well because NMT commits to the version as well thus, it operates over namespaces rather than IDs. I am not sure anymore it is worth renaming in celestia-node only without nmt |
+1 to renaming in NMT. Created celestiaorg/nmt#206 |
Mostly copied from the app's Namespace type with multiple modifications. In preparation for #2301. We want a more straightforward Namespace type from what the app provides: * Repsents 1:1 mapping of the serialized form of Namespace [version byte + namespace id] * So that it does not allocate on the hot path when getting data by namespace * and had simpler json serialization
## Notable Changes - `namespace.ID` to `share.Namespace` - Changes every comment namespace ID mentioning to just namespace. I renamed every such mention besides in ADRs. I don't want to touch ADRs here, as they need a more holistic re-review and up-to-date catchup. - Uses all the utility methods on the type, where suitable - Namespace constructor now only creates Blob Namespaces. For other reserved namespaces, the predefined globals should be used. - Uses namespace.ValidateDataNamespace everywhere data is requested. This is guarantees we verify the namespace are 100% valid and forbids requesting parity and padding namespaces. - Restricts PFBs for reserved namespaces - Reversed the dependency from `share -> share/ipld` to `share/ipld -> share` - NewBlobV0 constructor. Similar to NewNamespaceV0 - `sharetest` pkg for share related testing utilities - `edstest` pkg for eds related testing utilities ## Follow-ups - `blobtest` pkg to generate node's blob type ## Refs * Substitutes zombie PR #2376. I push to the branch, but GH does not see commits. * Based on #2367 * Closes #2301 * Closes #2309 * Blocked on #2256
Mostly copied from the app's Namespace type with multiple modifications. In preparation for celestiaorg/celestia-node#2301. We want a more straightforward Namespace type from what the app provides: * Repsents 1:1 mapping of the serialized form of Namespace [version byte + namespace id] * So that it does not allocate on the hot path when getting data by namespace * and had simpler json serialization
Context
celestia-node/share/get.go
Line 52 in c77f6db
Problem
In a few locations in this repo,
nID: namespace.ID
is used when I think a namespace is being passed (i.e. version + ID).Proposal
nID
tonamespace
orns
where applicable.namespace.ID
with celestia-app type NamespaceThe text was updated successfully, but these errors were encountered: