Component and Organization Contract Initialization Guidelines

All Components, Organization contracts and contracts that implement them are EthereansOS-developed Factory capable contracts that follow the development and initialization pattern explained here.

In this documentation, on each page of the Organizations section, you can find an explanation of how to initialize data for the contract type that the page discusses.

Examples

Organization Root layer

As a child contract of DynamicMetadataCapableElement, this must be initialized with:

  1. The host*, at the level of LazyInitCapableElement.

  2. plainUri and dynamicUriResolver, at the level of DynamicMetadataCapableElement.

  3. A Component[] struct, at the level of Organization.

SubDAO

As a child contract of Organization, this must be initialized with:

  1. The host**, at the level of LazyInitCapableElement.

  2. plainUri and dynamicUriResolver, at the level of DynamicMetadataCapableElement.

  3. A Component[] struct, at the level of Organization.

  4. A SubDAOProposalModel[] struct, at the level of SubDAO.

**the host of a SubDAO must be equal to the SubDAO Manager address as explained in the Governance Layer section.

ProposalManager

As a child contract of LazyInitCapableElement, this must be initialized with:

  1. The host, at the level of LazyInitCapableElement.

  2. _collections, _objectIds, _weights, _canTerminateAddresses, _validatorsAddresses, at the level of ProposalManager.

SubDAOProposalManager

As a child contract of ProposalManager, this must be initialized with:

  1. The host, at the level of LazyInitCapableElement.

  2. _collections, _objectIds, _weights, _canTerminateAddresses, _validatorsAddresses, at the level of ProposalManager.

  3. Nothing at the level of SubDAOProposalManager, because it doesn't require specific data.

DelegationsTreasurySplitManager

As a child contract of LazyInitCapableElement, this must be initialized with:

  1. The host, at the level of LazyInitCapableElement.

  2. callerPercentage, _treasuryPercentages, at the level of DelegationsTreasurySplitManager.

The host of a Component such as a Proposal Manager or Treasury Manager if not specified does not have to be the address of the Organization to which it is attached. The reference is in fact the key and the active/inactive state, not the host address saved at LazyInitCapableElement level.

Last updated