Giter Club home page Giter Club logo

rfcs's Introduction

SAFE Network RFCs

This process attempts to emulate the success of the Rust programming language and as such has almost mirrored the RFC process the Rust developers use, which is tried and tested and appears to work very well.

Introduction

Many changes, including bug fixes and documentation improvements can be implemented and reviewed via the normal GitHub pull request workflow.

Some changes though are "substantial", and we ask that these be put through a bit of a design process and produce a consensus among the community and the core team.

The "RFC" (request for comments) process is intended to provide a consistent and controlled path for new features to enter the network and core libraries, so that all stakeholders can be confident about the direction in which the network is evolving.

Table of Contents

When you need to follow this process

You need to follow this process if you intend to make "substantial" changes to SAFE libraries, dependencies, algorithms or the RFC process itself. What constitutes a "substantial" change is evolving based on community norms, but may include the following:

  • Any semantic or syntactic change to the existing algorithms and process that is not a bug fix.
  • Any proposed additions to existing algorithms
  • Any proposed additional functionality
  • Anything that reduces interoperability (e.g. changes to the wire protocol or data serialisation.)

Some changes do not require an RFC:

  • Rephrasing, re-organising, refactoring, or otherwise "changing shape does not change meaning"
  • Additions that strictly improve objective, numerical quality criteria (warning removal, speedup, better platform coverage, more parallelism, trap more errors…etc…)
  • Additions only likely to be noticed by other developers-of-safe, invisible to app-developers-of-safe (i.e. API users)

If you submit a pull request to implement a new feature without going through the RFC process, it may be closed with a polite request to submit an RFC first.

Before creating an RFC

A hastily proposed RFC can hurt its chances of acceptance. Low quality proposals, proposals for previously rejected features, may be quickly rejected, which can be demotivating for the unprepared contributor. Laying some groundwork ahead of the RFC can make the process smoother.

Although there is no single way to prepare for submitting an RFC, it is generally a good idea to pursue feedback from other project developers beforehand to ascertain that the RFC may be desirable. Having a consistent impact on the project requires concerted effort toward consensus-building.

The most common preparations for writing and submitting an RFC include filing and discussing ideas on the RFC issue tracker, and occasionally posting "pre-RFCs" on the SAFE Dev Forum for early review.

As a rule of thumb, receiving encouraging feedback from long-standing project developers, and particularly members of the core team or existing contributors, is a good indication that the RFC is worth pursuing.

What the process is

In short, to get a major feature added, one must first get the RFC merged into the RFC repo as a markdown file. At that point, the RFC is "proposed" and may be implemented with the goal of eventual inclusion into SAFE, at which point it becomes "active".

  • Fork the RFC repository
  • Decide on a clear and brief title for the new rfc, make it descriptive and unique. Copy 0000-template.md to text/0000-my-new-rfc/0000-my-new-rfc.md, where 'my-new-rfc' is the kebab-cased version of the RFC title, any non-letters removed. Don't assign an RFC number yet!
  • Fill in the RFC. Put care into the details: RFCs that do not present convincing motivation, demonstrate understanding of the impact of the design, or are disingenuous about the drawbacks or alternatives tend to be poorly-received.
  • Submit a pull request. As a pull request the RFC will receive design feedback from the larger community, and the author should be prepared to revise it in response.
  • Each pull request will be labelled with the most relevant sub-team, which will lead to its being triaged by that team in a future meeting and assigned to a member of the sub-team.
  • Build consensus and integrate feedback. RFCs that have broad support are much more likely to make progress than those that don't receive any comments. Feel free to reach out to the RFC assignee in particular to get help identifying stakeholders and obstacles.
  • The sub-team will discuss the RFC pull request, as much as possible in the comment thread of the pull request itself. Offline discussion will be summarised on the pull request comment thread.
  • RFCs rarely go through this process unchanged, especially as alternatives and drawbacks are shown. You can make edits, big and small, to the RFC to clarify or change the design, but make changes as new commits to the pull request, and leave a comment on the pull request explaining your changes. Specifically, do not squash or rebase commits after they are visible on the pull request.
  • At some point, a member of the sub-team will propose a "motion for final comment period" (FCP), along with a disposition for the RFC (merge, close, or postpone).
    • This step is taken when enough of the tradeoffs have been discussed that the sub-team is in a position to make a decision. That does not require consensus amongst all participants in the RFC thread (which is usually impossible). However, the argument supporting the disposition on the RFC needs to have already been clearly articulated, and there should not be a strong consensus against that position outside of the sub-team. Sub-team members use their best judgement in taking this step, and the FCP itself ensures there is ample time and notification for stakeholders to push back if it is made prematurely.
    • For RFCs with lengthy discussion, the motion to FCP is usually preceded by a summary comment trying to lay out the current state of the discussion and major tradeoffs/points of disagreement.
    • Before actually entering FCP, all members of the sub-team must sign off; this is often the point at which many sub-team members first review the RFC in full depth.
  • The FCP lasts ten calendar days, so that it is open for at least 5 business days. This way all stakeholders have a chance to lodge any final objections before a decision is reached.
  • In most cases, the FCP period is quiet, and the RFC is either merged or closed. However, sometimes substantial new arguments or ideas are raised, the FCP is cancelled, and the RFC goes back into development mode.

The RFC life-cycle

Once an RFC becomes active then authors may implement it and submit the feature as a pull request to the repo. Being "active" is not a rubber stamp and in particular still does not mean the feature will ultimately be merged. It does mean that in principle all the major stakeholders have agreed to the feature and are amenable to merging it.

Furthermore, the fact that a given RFC has been accepted and is "active" implies nothing about what priority is assigned to its implementation, nor does it imply anything about whether a developer has been assigned the task of implementing the feature. While it is not necessary that the author of the RFC also write the implementation, it is by far the most effective way to see an RFC through to completion. Authors should not expect that other project developers will take on responsibility for implementing their accepted feature.

Modifications to active RFCs can be done in follow up PRs. We strive to write each RFC in a manner that it will reflect the final design of the feature, however, the nature of the process means that we cannot expect every merged RFC to actually reflect what the end result will be at the time of the next major release. We therefore try to keep each RFC document somewhat in sync with the network feature as planned, tracking such changes via followup pull requests to the document.

An RFC that makes it through the entire process to implementation is considered "implemented" and is moved to the "implemented" folder. An RFC that fails after becoming active is "rejected" and moves to the "rejected" folder.

Reviewing RFCs

While the RFC pull request is up, the sub-team may schedule meetings with the author and/or relevant stakeholders to discuss the issues in greater detail, and in some cases the topic may be discussed at a sub-team meeting. In either case a summary from the meeting will be posted back to the RFC pull request.

A sub-team makes final decisions about RFCs after the benefits and drawbacks are well understood. These decisions can be made at any time, but the sub-team will regularly issue decisions. When a decision is made, the RFC pull request will either be merged or closed. In either case, if the reasoning is not clear from the discussion in thread, the sub-team will add a comment describing the rationale for the decision.

Implementing an RFC

Some accepted RFCs represent vital features that need to be implemented right away. Other accepted RFCs can represent features that can wait until some arbitrary developer feels like doing the work. Every accepted RFC has an associated issue tracking its implementation in the affected repositories. Therefore, the associated issue can be assigned a priority via the triage process that the team uses for all issues in the appropriate repositories.

The author of an RFC is not obligated to implement it. Of course, the RFC author (like any other developer) is welcome to post an implementation for review after the RFC has been accepted.

If you are interested in working on the implementation for an "active" RFC, but cannot determine if someone else is already working on it, feel free to ask (e.g. by leaving a comment on the associated issue).

RFC Postponement

Some RFC pull requests are tagged with the "postponed" label when they are closed (as part of the rejection process). An RFC closed with "postponed" is marked as such because we want neither to think about evaluating the proposal nor about implementing the described feature until some time in the future, and we believe that we can afford to wait until then to do so. Historically, "postponed" was used to postpone features until after 1.0. Postponed pull requests may be re-opened when the time is right. We don't have any formal process for that, you should ask members of the relevant sub-team.

Usually an RFC pull request marked as "postponed" has already passed an informal first round of evaluation, namely the round of "do we think we would ever possibly consider making this change, as outlined in the RFC pull request, or some semi-obvious variation of it." (When the answer to the latter question is "no", then the appropriate response is to close the RFC, not postpone it.)

Help! This is all too informal

The process is intended to be as lightweight as reasonable for the present circumstances. As usual, we are trying to let the process be driven by consensus and community norms, not impose more structure than necessary.

License

This SAFE Network library is dual-licensed under the Modified BSD (LICENSE-BSD https://opensource.org/licenses/BSD-3-Clause) or the MIT license (LICENSE-MIT https://opensource.org/licenses/MIT) at your option.

Contributing

Want to contribute? Great 🎉

There are many ways to give back to the project, whether it be writing new code, fixing bugs, or just reporting errors. All forms of contributions are encouraged!

For instructions on how to contribute, see our Guide to contributing.

rfcs's People

Contributors

19eddyjohn75 avatar afck avatar bochaco avatar canndrew avatar cretz avatar dan-da avatar david-maidsafe avatar dirvine avatar fizyk20 avatar frabrunelle avatar gnunicorn avatar hitman401 avatar iancoleman avatar inetic avatar jimcollinson avatar joshuef avatar lionel-faber avatar madadam avatar maqi avatar nbaksalyar avatar pierrechevalier83 avatar pravarseth avatar s-coyle avatar safeshane avatar ustulation avatar vinipsmaker avatar vinitha-vasanthkumar avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

rfcs's Issues

Clarifications to launcher JSON API definitions

Some suggestions to help App developers understand this (including myself :-))...

Add a stand alone description for each API, that doesn't assume context or terminology. Define any terminology or abbreviations used - for example:

Description should make clear: What is a service? What is the effect of registering a service? What does this permit me to do once registered? Do I have to register all services (is "www" a realistic example) or are some built in?

What is DNS? I think this has lots of scope for confusion because it is like the existing DNS but different, and it isn't clear what is similar and how they differ. And those who don't know about DNS and services will be absolutely lost.

Also, I think having "www" in both the example service and at the end of "/path/to/an/existing_directory_www" is confusing. Especially because the comment makes reference to the "last token" of the latter, without clarifying what this is in the example (I assume it is referring to "existing_directory_www" but I'm not sure, and it could will be taken to mean "www" which we've hinted is "special" just above).

Discuss PR proposed/0018-launcher-as-rest-server/0018-launcher-as-local-rest-server.md

I'm not sure if this is the place to start this off but can't find any discussion so far - maybe because this is still a PR? Sorry if I'm jumping the gun :-)

The scheme seems very sound and versatile and well thought out (although I can't comment on implementation as a RESTful server as I don't know the details of this).

I have some observations that relate to earlier proposals, including a couple from myself. These are not criticisms, but things I want to mention as relevant or state for clarification:

  • Dynamic Web Apps/Sites: I think that it would be possible to extend this approach to provide for dynamic website support in a similar way to that proposed in my RFC PR SAFE browser plugin URL handling / dynamic HTML on client side. The purpose of that would be to allow a single URL to specify both the HTML file needed for rendering something, and the data object(s) it will render. For example, in the case of a blog these would correspond to the HTML that renders a blog post (e.g. the URL for blogpost.html) and the particular blog post content (e.g. a URL containing a post-id). I suggest that we consider if there are any things needed to ensure this could be added in a backwards compatible manner, and whether it is worth including from the start if it is not too onerous to do so - unless of course an alternative scheme is available, or we make a decision not to support this kind of web application. I'm assuming we do want to, but am not aware of MaidSafe's thinking on this kind of application/website.
  • Invalid URL Handling: this scheme, using a TLD of ".safenet", would I think make it impractical to have a SAFE style URL that defaults to a real but conventional website address as in the forum discussion SAFE URL: use a real internet domain such as safenetwork.net because that would require us to own and enable ".safenet" as a real TLD which I think is not feasible due to cost (~$200k I think).
  • TLD Vulnerability: related to the preceding point, what do we think about the possibility that someone (e.g. a government agency) might choose to register the ".safenet" TLD as a means to snoop on users visiting SAFE URLs without the RESTful server installed/running, or to set up a rival domain space that confuses users, and so on. A way to avoid this would be for the MaidSafe Foundation to register the ".safenet" TLD, but that would be expensive and I would think difficult for the Foundation to justify.
  • safe://" format URLs: As I understand it this scheme alone would not allow support of "safe:" style URLs because a browser without a special extension would treat them as a search string and not invoke the RESTful server. If at some point we provide browser plugins or extensions that can intercept "safe:" URLs and forward them to the RESTful interface they could be supported, but the "cost" of doing this would be confusion through multiple URL formats which would need to be considered.

Sub-Directories make it hard to link to RFCs: how about using a status-field instead?

I understand and totally agree that the way rust handles their RFCs is pretty unclear regrading the state of each RFC and see the reason behind creating the folders. However, this makes it hard to link to any RFC as their link throughout the development cycle changes significantly, one reason why RFCs can't properly link to each other directly within the document.

Coming from the Python PEP Process (which the rust RFC process is largely inspired by), how about adding a top-level field status instead like they do (and maybe one that mentions the release version once it was published)? This way, each RFC could stay in one place and be linked to.

In regards to have a good overview, I'd suggest to do it similarly as Rust does it and just link the RFCs from the Readme.md, but as sections depending their status (ordered by number, optionally descending). Changing the status then needs to be PR which also moves them from one section to another.

sync rfcs discussions with forum using Zapier or IFTT

Is it possible to setup an automatic post to https://forum.safenetwork.io/ under the rfcs category whereby the contents of a pull request can be the conversation starter and the Discussions in the within pull request or issue against it be put as posts on for the conversation.

The forum servers as a quick reminder of where you left of in following a discussion. This will give the rfcs much more traffic and followers than it currently has.

Was looking into setting up a personal notification system using zapier on the github notifications from the repo but if it can be implemented to suite everyone it would be good i think.

P.s hope this is the right way to contribute such an issue that does not necessarily impact the features to go into safe but a concern on how to handle this repo

Interoperability

Under conditions that requires an RFC, I would add anything that reduces interoperability (e.g. changes to the wire protocol.)

Questioning loss of session base encryption (SAFE Launcher API v0.5)

Refering to: https://github.com/maidsafe/rfcs/blob/master/text/0036-launcher-api-v0.5/0036-launcher-api-v0.5.md#remove-session-based-encryption-between-application-and-launcher

I'm late to questioning this sorry! It seemed a reasonable case was made for removing encryption at first, and I was perhaps too pleased to be getting rid of this encumbrance to question it properly at the time. I have now revisited this decision and after thinking about it I'd like to put forward some arguments for re-instating encryption.

From memory I think the reasoning for removing encryption was broadly as follows (@cretz please correct/elaborate where I'm lacking here):

Since the information that could be gleaned from intercepting App <> SAFE Launcher communications would likely be stored on or available elsewhere on the client machine, there's little to be gained by encrypting it just when it passes between App and Launcher. Doing so is therefore of little benefit, while generating costs in terms of performance, implementation time, and learning curve.

I think that one way or another I think that most of this is true. The information will be available in some way or other in an unencrypted form, so I don't pretend that encrypting this interface ensures protection except perhaps in some very limited cases, where (as I recall @cretz pointed out), it would make sense for the App itself to encrypt the data before transmission.

What I now think though is that encryption will still create a significantly more secure client platform and in practice will end up protecting data that would otherwise be stolen and exploited - and that this could be more than just significant, and in fact have a large impact on the data security of the SAFE App ecosystem, though how large is hard to predict or prove.

I have two reasons for thinking this.

1) General Case. Firstly, while attackers can in theory obtain unencrypted information by other means such as the filesystem, a keylogger, or indeed the memory space of individual apps, these methods are in no way comparable to the ease of some malware simply logging or monitoring all App <> Launcher communications. By leaving that channel wide open, malware can focus in on and collect everything the user saves and retrieves from the "Secure" SAFE Network. It brings all manner of attacks across any and all SAFE Apps into the scope of the script kiddie level of un-sophistication, multiplying the number of potential attackers and attack targets many fold - i.e. to anyone who can google and follow a how-to guide, and all SAFE apps that don't explicitly encrypt.

I think this alone means that we should reconsider this decision, in order to satisfy ourselves that there are other modes of attack that are as easy and general purpose as this and that encrypting App communications really isn't likely to have this much impact.

2) Specific Case. Suppose we have data that is created in the App that needs to be stored safely, but the App developer has not really considered or recognised the importance of keeping that data secure. Or perhaps doesn't have the time or skill to figure out how to use an encryption library and so skimps on security. So a problem can arise through: a simple oversight, a lack of consideration of security, lack of time or skill, or simply being unable to anticipate that certain kinds of data that the app generates might pose a security or privacy risk at some future date. Here for one reason or another the App developer has not encrypted the data before storage on SAFE network and yet the data is never available outside the App or on the client filesystem, or even through the keyboard and UI in a form that could readily be "stolen" by anything but the most sophisticated malware (ie from App memory), yet because we didn't encrypt Launcher communications it is now wide open.

I don't know how much data might fall into this category over time, but I suggest that we can't assume that it will be small, and yet by this simple omission we've left it all, wide open, to any "script kiddie" level of malware to gather and steal with ease, without any need for targeting by the type of attack, or any sophistication.

In fact, we might infer that since the user is using Apps that store their data on SAFE Network, we have helped narrow the attacker's data surface towards the very data that is more likely to be useful and valuable to steal, than it would obtain by searching many more GB of data on the filesystem, for example.

So again, I think we should re-consider the decision based on the idea that we are leaving something open with potentially large security implications, simply because we can't foresee the specific nature or estimate the likely magnitude of those consequences in future.

__
I follow @cretz' point (in the earlier discussion) that it is up to the App developer to secure and therefore encrypt data where needed, but that runs contrary to the approach of needing to try where we can to protect users (and in this case App devs) from themselves where that is possible.

I recognise that there is also an overhead that makes it harder for developers to climb the learning curve of the SAFE Launcher API, but this will surely be overcome easily with simple API helper libraries that we're already seeing arise from the community. There's also a positive side effect for those devs (such as myself) who are forced, kicking and screaming, to learn how to handle encrypted data and for which I am now grateful and in a far better position to write more secure apps in future.

These and other factors (performance) for example may need to be given more weight than the issues I've raised here, but I don't recall anyone making the above case when this was originally discussed. So I'd like these points to be considered and then we can review the decision and whether or not to reverse it while it is still relatively early :-).

Again, sorry I didn't think of this earlier and am raising this after the fact (and the point where I was planning to move my own dev work from the encrypted to the unencrypted interface with some relief), but it has only just occurred to me that this might not really be a good idea after all. Thanks for reading!

Glossary with Gitbook maybe?

Discussing the understanding issues of #118 lead me to think that it'd be very useful to offer a Glossary for these kind of terms to make the RFCs more accessible and widen its audience. Unfortunately, markdown itself doesn't really offer any good way to do this by itself (other than linking directly), but Gitbook does. And as with #121 we now have a nice overview of RFCs as well, I played around with it a little as an alternative way of rendering the repository, you can find the results here:

https://ligthyear.gitbooks.io/maidsafe-rfcs/content/index.html

Preview:
screen shot 2016-05-03 at 21 24 17

And an example of what it looks like with their (automatic) glossary here (hover over "safecoin" or "farming" to see it in action): https://ligthyear.gitbooks.io/maidsafe-rfcs/content/text/0004-Farm-attempt/0004-Farm-attempt.html

I've to say I like this way of rendering it very much, and it brings many formats (epub, pdf) for free once set up (gitbook rerenders on every push to github). Maybe something to consider?

RFC 0004: 10% or 110%

I'm just going through all the RFCs and make some general typo, grammar and formatting updates, when I found this current section in the RFC 0004 - Farming that reads:

1. PmidNodes -> tested at 100% of FR [i.e. Farming rate * 1]
2. App Developer -> tested at 10% of FR [i.e. Farming rate * 1.1]
3. Publisher -> tested at 10% of FR [i.e. Farming rate * 1.1]
4. Core development -> tested at 5% of FR [i.e. Farming rate * 1.05]

Which is clearly confusing, as 1 describes 100% as equaling 1, while two and all following describe the percentage (10% or 5%) as an additional (* 1.1 or * 1.05) – which one is it? I assume that it is meant as additional, so may I propose to the change percentages from 2 down to contain a + or the word "additional"?

(If accepted I can make that part of the bigger PR I am planning for the general wording and stuff).


I am not sure, where to suggest that, so I'll leave it here for now: I think for many RFCs a "definitions" sections on the top clearly defining words would be very helpful, like in this case what does "Farming" mean? There is a spec but it is totally unclear.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.