-
Notifications
You must be signed in to change notification settings - Fork 9
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
es5 spec feedback #23
Comments
14 inclusively or exclusively?
I'm sensing conflicting signals here.
Probably shouldn't put secrets in the list that introduces the public parts of the public address. Especially as they aren't referenced in this (sub-) section.
Neither "replica" nor their "instantiation" have been defined.
Again, probably best to simply omit this.
Does this section really belong to the spec?
I'm feeling validated in my observations. This is a lot of specification real estate for nothing but a app-level SHOULD. But I will admit that this is more about style then a "real flaw", whatever that even means.
But
This usage of MUST (effectively a definition) does not conform to the meaning outlined in rfc2119. I also expect ephemerality to be defined elsewhere too, and duplicate definitions are usually a bad idea.
See above, perhaps rephrase in the spirit of "hey, if you come across a path that contains
Tricky again. The whole path definition might require a careful rewrite because of its lack of escaping.
What is this supposed to tell me?
"file extension" is not defined (and good luck =/). Later: nvm, might want a forward pointer here though. Slightly later still: nvm the nvm, the section on file extensions doesn't define them either.
Just marking this as another thing that needs to be rewritten when tackling the
This should be mentioned in the document ingestion algorithm, at the very least as a comment to the
Neither "beginning", "middle" or "end" are defined.
I genuinely don't know which of several interpretations of "path/document" is intended here.
Attachments have already been defined at this point, reference that definition boldly rather than sorta kinda reintroducing the terminology.
So I cannot reference multiple attachments of different file extensions without violating a "should" (changed to SHOULD in my pr btw). That makes me sad =(
If you invoke the power of MUST NOT, do not give into the temptation of listing possible reasons for the disallowed behavior; you might encourage people with other reasons. In particular, I'm also not allowed to use filename extensions that have nothing to do with my content. Furthermore, "using" a filename extension is not defined, be consistent in talking about "paths ending with a file extension".
Do you have recommendations for documents without a clear interpretation of the text contents? And in particular for "directories" like they are used in the wiki-like examples throughout the pacification? Are those an anti-pattern because paths are supposed to correspond to text files rather than directories?
(way up high in the specification) Contradicted by the file extension path rules. (And also by the example 2 lines below that definition, now that I'm looking closely at this:).
Should be "[...]/displayName(txt)"? Or should only Windows users do that? =P Does the specification gain anything by introducing the concept of path segments, as opposed to considering a path as a flat sequence of characters? Humans might like to group paths into meaningful segments based on the occurrence of the |
Remove trailing
Is there no length limit?
Genuine question: is Less genuine question: does that mean that so-called documents of older or newer format are not really documents?
"integer" is not defined, unless you really mean this (you don't). Later: well, this is another good place for a forward pointer.
And what is that thing?
Can this be reformulated to "Extra fields are FORBIDDEN." without losing information?
No string field is specified above as allowing
See above.
Does this sentence carry meaning? "order of fields" is not a well-defined concept, and listing things a specification does not define within that specification is probably not a good idea anyways.
This section should probably backpoint to the document ingestion algorithm.
"syncing" is neither defined as a concept nor specified in this document, why do we suddenly have MUSTs relating to it?
Doesn't this contradict that "Invalid documents MUST be individually ignored when peers are syncing". If that rule was followed, no invalid documents can exist in the "storage" (would be nice to have a well-defined name for the data held by a peer) at any time. Because they cannot originate from a local write either by the definition of how to assign timestamps.
And for formats I do not know about (yet)? What about es.3? Do I have to know about that one? And what's so special about this es.5 anyways that it's being mentioned here? Inside a MUST is not a good place for details that are meant to be helpful.
Does this differ from "share is a valid share address stringEND_OF_LINE"?
What about |
That second sentence is a really bad idea. Luckily, the first sentence ensures that the "If the data is not valid utf-8" condition is never satisfied. If you really absolutely undoubtedly wish to introduce undefined behavior, you need to reformulate the second sentence. In that case, please give me a chance to talk you out of it or at least discuss some better alternatives than introducing "undefined behavior" ("undefined" is not defined in this context btw, and it is probably a good idea to keep things that way).
"naive string length" is not defined and doesn't need to be, considered dropping those last four words.
This whole paragraph assumes that documents have at most one attachment, which is not true.
The textHash (typo already fixed in the pr) is just an arbitrary string adhering to the formatting rules of a hash. It MUST be equal to the sha256 hash of the
"short string" is not defined.
Cool. What does that mean for me? And how do I have to react to older formats? How to newer ones? How to incomparable ones (e.g. General note: be careful that you don't exclude documents adhering to an old format from the set of valid documents (unless that is exactly your intention). Currently, you pretty much do.
Do changes that break forward compatibility exist? Does forward compatibility exist?
You are specifying how to write earthstar specifications here, which is not part of the stated scope of this specification. The intended audience doesn't care about any of this, the particularly if the MUSTy guarantee they might gleam from this is followed by a (completely unnecessary? and) confusing SHOULD.
Now this is the definition of being ephemeral that I was looking forward to. And I'm not disappointed =)
Using "MUST NOT" and then immediately giving wiggling room goes against rfc2119 (See what you've done, you've made me memorize the number of an rfc =/).
This contradicts "In order to mitigate scenarios 2, 3, and 4, peers MUST consider documents with timestamps further than ten minutes in the future invalid."
"attachments for a document" is not defined.
Which is not required to exist, so should it really be mentioned here?
Implied by definition of ephemeral documents. This would need a MUST, but probably easiest to just cut it?
signature of what? And again, you cannot assume that this is the case, you have to state that the document is invalid if it is not the case.
See above. also, who computes this? probably not the share, right?
No leading
Is that so?
Should this also be reflected in the |
But
Why are you telling me this? Which Fields exists this predetermined by the format.
Again, the reader doesn't need to care.
Bold predictions =P
Aren't old versions required to be deleted?
"reverse of that" is not well-defined in this context
"coming after a certain point" is not defined
What is that? is not elaborated upon, it never occurs outside the pseudocode.
"after a localIndex" is not defined
"after a path" is not defined
Either specify their semantics or don't put them in the specification. |
Over and out. |
Everything in here also appears in #25 |
This is going to take a while, so I will split this up into several comments. Small nitpicks appear here instead.
Disclaimer: When I'm asking for information about the current state of earthstar, I'm usually expressing that the information should appear in the specification at that point, which is unrelated to whether I happen to know the answer to the question.
Any particular reason you prescribe this? If I fork the reference implementation and make it add always add the byte string "I like trains" to the attachment database on start up, would you consider it to not be an implementation of earthstar anymore? Later: I see, this is about enforcing deletion of removed content. Perhaps foreshadow this here already?
Again, oddly restrictive - use SHOULD instead?
What happens in case of equal timestamps?
Isn't this a contradiction?
This uses an effectful tiebreaker rather than a pure one such as comparing hashes. Any chance I can convince you to change this?
SHOULD? the specification is not about defining apps - who would be enforcing MUST requirements of apps, why?
This sentence heavily implies that attachments can arrive unrelated to and independently from documents. I personally think this is an elegant and ultimately simple choice. Yet, the attachment ingestion algorithm that follows only checks for ingesting an attachment in combination with a particular document. How about letting the attachment ingestion algorithm start by querying for documents that refer to the would-be-new attachment, and abort if the set of such documents is empty?
Isn't this unnecessary, considering that ingestion is idempotent?
This is a very delicate topic in conjunction with the admirable aspiration "It's safe to use the identity keypair from multiple devices simultaneously.". As written, the specification successfully ensures that a single peer is free from conflicting timestamps, but at the cost of forcing distinct peers to choose nondeterministically between any two documents with equal
(path, identity, timestamp)
. The consequence of this that you cannot rely on distinct peers eventually settling on the same view of the share, even after an arbitrarily long time without new document creations. Which is to say, earthstar is not even eventually consistent. I can go into more details in a different context if you'd like. But this is probably unintended and bad?Again I would recommend using hashes as tiebreakers (as freedom of hash collisions is indeed assumed to hold) to make those choices deterministic for and across all peers.
The text was updated successfully, but these errors were encountered: