Bläddra i källkod

Merge pull request #2805 from mnaamani/giza-drop-pre-sumer-legacy-types

Drop old legacy types
Mokhtar Naamani 3 år sedan
förälder
incheckning
0ad8e61cb8
3 ändrade filer med 4 tillägg och 438 borttagningar
  1. 0 71
      types/augment/all/defs.json
  2. 0 213
      types/augment/all/types.ts
  3. 4 154
      types/src/legacy.ts

+ 0 - 71
types/augment/all/defs.json

@@ -1,75 +1,4 @@
 {
-    "ChannelContentType": "Null",
-    "ChannelCurationStatus": "Null",
-    "ChannelPublicationStatus": "Null",
-    "CurationActor": "Null",
-    "Curator": "Null",
-    "CuratorApplication": "Null",
-    "CuratorApplicationId": "Null",
-    "CuratorApplicationIdSet": "Null",
-    "CuratorApplicationIdToCuratorIdMap": "Null",
-    "CuratorOpening": "Null",
-    "CuratorOpeningId": "Null",
-    "Lead": "Null",
-    "LeadId": "Null",
-    "OptionalText": "Null",
-    "Principal": "Null",
-    "PrincipalId": "Null",
-    "WorkingGroupUnstaker": "Null",
-    "Credential": "Null",
-    "CredentialSet": "Null",
-    "Nonce": "Null",
-    "EntityId": "Null",
-    "ClassId": "Null",
-    "VecMaxLength": "Null",
-    "TextMaxLength": "Null",
-    "HashedTextMaxLength": "Null",
-    "PropertyId": "Null",
-    "SchemaId": "Null",
-    "SameController": "Null",
-    "ClassPermissions": "Null",
-    "PropertyTypeSingle": "Null",
-    "PropertyTypeVector": "Null",
-    "PropertyType": "Null",
-    "PropertyLockingPolicy": "Null",
-    "Property": "Null",
-    "Schema": "Null",
-    "Class": "Null",
-    "ClassOf": "Null",
-    "EntityController": "Null",
-    "EntityPermissions": "Null",
-    "StoredValue": "Null",
-    "VecStoredValue": "Null",
-    "VecStoredPropertyValue": "Null",
-    "StoredPropertyValue": "Null",
-    "InboundReferenceCounter": "Null",
-    "Entity": "Null",
-    "EntityOf": "Null",
-    "EntityCreationVoucher": "Null",
-    "Actor": "Null",
-    "EntityReferenceCounterSideEffect": "Null",
-    "ReferenceCounterSideEffects": "Null",
-    "SideEffects": "Null",
-    "SideEffect": "Null",
-    "Status": "Null",
-    "InputValue": "Null",
-    "VecInputValue": "Null",
-    "InputPropertyValue": "Null",
-    "ParameterizedEntity": "Null",
-    "ParametrizedPropertyValue": "Null",
-    "ParametrizedClassPropertyValue": "Null",
-    "CreateEntityOperation": "Null",
-    "UpdatePropertyValuesOperation": "Null",
-    "AddSchemaSupportToEntityOperation": "Null",
-    "OperationType": "Null",
-    "InputEntityValuesMap": "Null",
-    "ClassPermissionsType": "Null",
-    "ClassPropertyValue": "Null",
-    "Operation": "Null",
-    "ReferenceConstraint": "Null",
-    "FailedAt": "Null",
-    "IPNSIdentity": "Null",
-    "ServiceProviderRecord": "Null",
     "ContentId": "Null",
     "ContentParameters": "Null",
     "DataObjectStorageRelationship": "Null",

+ 0 - 213
types/augment/all/types.ts

@@ -46,9 +46,6 @@ export interface ActiveStake extends Struct {
   readonly source_account_id: GenericAccountId;
 }
 
-/** @name Actor */
-export interface Actor extends Null {}
-
 /** @name ActorId */
 export interface ActorId extends u64 {}
 
@@ -63,9 +60,6 @@ export interface AddOpeningParameters extends Struct {
 /** @name Address */
 export interface Address extends AccountId {}
 
-/** @name AddSchemaSupportToEntityOperation */
-export interface AddSchemaSupportToEntityOperation extends Null {}
-
 /** @name AdjustCapacityBy */
 export interface AdjustCapacityBy extends Enum {
   readonly isSetting: boolean;
@@ -229,9 +223,6 @@ export interface ChannelCategoryUpdateParameters extends Struct {
   readonly new_meta: Bytes;
 }
 
-/** @name ChannelContentType */
-export interface ChannelContentType extends Null {}
-
 /** @name ChannelCreationParameters */
 export interface ChannelCreationParameters extends Struct {
   readonly assets: Option<StorageAssets>;
@@ -239,9 +230,6 @@ export interface ChannelCreationParameters extends Struct {
   readonly reward_account: Option<GenericAccountId>;
 }
 
-/** @name ChannelCurationStatus */
-export interface ChannelCurationStatus extends Null {}
-
 /** @name ChannelId */
 export interface ChannelId extends u64 {}
 
@@ -270,9 +258,6 @@ export interface ChannelOwnershipTransferRequest extends Struct {
 /** @name ChannelOwnershipTransferRequestId */
 export interface ChannelOwnershipTransferRequestId extends u64 {}
 
-/** @name ChannelPublicationStatus */
-export interface ChannelPublicationStatus extends Null {}
-
 /** @name ChannelUpdateParameters */
 export interface ChannelUpdateParameters extends Struct {
   readonly assets_to_upload: Option<StorageAssets>;
@@ -290,24 +275,6 @@ export interface ChildPositionInParentCategory extends Struct {
 /** @name Cid */
 export interface Cid extends Bytes {}
 
-/** @name Class */
-export interface Class extends Null {}
-
-/** @name ClassId */
-export interface ClassId extends Null {}
-
-/** @name ClassOf */
-export interface ClassOf extends Null {}
-
-/** @name ClassPermissions */
-export interface ClassPermissions extends Null {}
-
-/** @name ClassPermissionsType */
-export interface ClassPermissionsType extends Null {}
-
-/** @name ClassPropertyValue */
-export interface ClassPropertyValue extends Null {}
-
 /** @name ContentActor */
 export interface ContentActor extends Enum {
   readonly isCurator: boolean;
@@ -326,33 +293,6 @@ export interface ContentIdSet extends BTreeSet<Cid> {}
 /** @name ContentParameters */
 export interface ContentParameters extends Null {}
 
-/** @name CreateEntityOperation */
-export interface CreateEntityOperation extends Null {}
-
-/** @name Credential */
-export interface Credential extends Null {}
-
-/** @name CredentialSet */
-export interface CredentialSet extends Null {}
-
-/** @name CurationActor */
-export interface CurationActor extends Null {}
-
-/** @name Curator */
-export interface Curator extends Null {}
-
-/** @name CuratorApplication */
-export interface CuratorApplication extends Null {}
-
-/** @name CuratorApplicationId */
-export interface CuratorApplicationId extends Null {}
-
-/** @name CuratorApplicationIdSet */
-export interface CuratorApplicationIdSet extends Null {}
-
-/** @name CuratorApplicationIdToCuratorIdMap */
-export interface CuratorApplicationIdToCuratorIdMap extends Null {}
-
 /** @name CuratorGroup */
 export interface CuratorGroup extends Struct {
   readonly curators: BTreeSet<CuratorId>;
@@ -365,12 +305,6 @@ export interface CuratorGroupId extends u64 {}
 /** @name CuratorId */
 export interface CuratorId extends u64 {}
 
-/** @name CuratorOpening */
-export interface CuratorOpening extends Null {}
-
-/** @name CuratorOpeningId */
-export interface CuratorOpeningId extends Null {}
-
 /** @name DataObject */
 export interface DataObject extends Struct {
   readonly accepted: bool;
@@ -523,27 +457,6 @@ export interface ElectionStake extends Struct {
   readonly transferred: u128;
 }
 
-/** @name Entity */
-export interface Entity extends Null {}
-
-/** @name EntityController */
-export interface EntityController extends Null {}
-
-/** @name EntityCreationVoucher */
-export interface EntityCreationVoucher extends Null {}
-
-/** @name EntityId */
-export interface EntityId extends Null {}
-
-/** @name EntityOf */
-export interface EntityOf extends Null {}
-
-/** @name EntityPermissions */
-export interface EntityPermissions extends Null {}
-
-/** @name EntityReferenceCounterSideEffect */
-export interface EntityReferenceCounterSideEffect extends Null {}
-
 /** @name EntryMethod */
 export interface EntryMethod extends Enum {
   readonly isPaid: boolean;
@@ -566,9 +479,6 @@ export interface ExecutionFailed extends Struct {
   readonly error: Text;
 }
 
-/** @name FailedAt */
-export interface FailedAt extends Null {}
-
 /** @name FillOpeningParameters */
 export interface FillOpeningParameters extends Struct {
   readonly opening_id: OpeningId;
@@ -585,9 +495,6 @@ export interface Finalized extends Struct {
   readonly stakeDataAfterUnstakingError: Option<ActiveStake>;
 }
 
-/** @name HashedTextMaxLength */
-export interface HashedTextMaxLength extends Null {}
-
 /** @name HiringApplicationId */
 export interface HiringApplicationId extends u64 {}
 
@@ -598,36 +505,15 @@ export interface InactiveApplicationStage extends Struct {
   readonly cause: ApplicationDeactivationCause;
 }
 
-/** @name InboundReferenceCounter */
-export interface InboundReferenceCounter extends Null {}
-
-/** @name InputEntityValuesMap */
-export interface InputEntityValuesMap extends Null {}
-
-/** @name InputPropertyValue */
-export interface InputPropertyValue extends Null {}
-
 /** @name InputValidationLengthConstraint */
 export interface InputValidationLengthConstraint extends Struct {
   readonly min: u16;
   readonly max_min_diff: u16;
 }
 
-/** @name InputValue */
-export interface InputValue extends Null {}
-
-/** @name IPNSIdentity */
-export interface IPNSIdentity extends Null {}
-
 /** @name IsCensored */
 export interface IsCensored extends bool {}
 
-/** @name Lead */
-export interface Lead extends Null {}
-
-/** @name LeadId */
-export interface LeadId extends Null {}
-
 /** @name LookupSource */
 export interface LookupSource extends AccountId {}
 
@@ -684,9 +570,6 @@ export interface NextAdjustment extends Struct {
   readonly at_block: u32;
 }
 
-/** @name Nonce */
-export interface Nonce extends Null {}
-
 /** @name ObjectOwner */
 export interface ObjectOwner extends Null {}
 
@@ -751,15 +634,6 @@ export interface OpeningType extends Enum {
   readonly isWorker: boolean;
 }
 
-/** @name Operation */
-export interface Operation extends Null {}
-
-/** @name OperationType */
-export interface OperationType extends Null {}
-
-/** @name OptionalText */
-export interface OptionalText extends Null {}
-
 /** @name PaidMembershipTerms */
 export interface PaidMembershipTerms extends Struct {
   readonly fee: u128;
@@ -769,15 +643,6 @@ export interface PaidMembershipTerms extends Struct {
 /** @name PaidTermId */
 export interface PaidTermId extends u64 {}
 
-/** @name ParameterizedEntity */
-export interface ParameterizedEntity extends Null {}
-
-/** @name ParametrizedClassPropertyValue */
-export interface ParametrizedClassPropertyValue extends Null {}
-
-/** @name ParametrizedPropertyValue */
-export interface ParametrizedPropertyValue extends Null {}
-
 /** @name Person */
 export interface Person extends Struct {
   readonly controlled_by: PersonController;
@@ -852,30 +717,6 @@ export interface PostTextChange extends Struct {
   readonly text: Text;
 }
 
-/** @name Principal */
-export interface Principal extends Null {}
-
-/** @name PrincipalId */
-export interface PrincipalId extends Null {}
-
-/** @name Property */
-export interface Property extends Null {}
-
-/** @name PropertyId */
-export interface PropertyId extends Null {}
-
-/** @name PropertyLockingPolicy */
-export interface PropertyLockingPolicy extends Null {}
-
-/** @name PropertyType */
-export interface PropertyType extends Null {}
-
-/** @name PropertyTypeSingle */
-export interface PropertyTypeSingle extends Null {}
-
-/** @name PropertyTypeVector */
-export interface PropertyTypeVector extends Null {}
-
 /** @name ProposalDecisionStatus */
 export interface ProposalDecisionStatus extends Enum {
   readonly isCanceled: boolean;
@@ -1008,12 +849,6 @@ export interface Recipient extends Struct {
 /** @name RecipientId */
 export interface RecipientId extends u64 {}
 
-/** @name ReferenceConstraint */
-export interface ReferenceConstraint extends Null {}
-
-/** @name ReferenceCounterSideEffects */
-export interface ReferenceCounterSideEffects extends Null {}
-
 /** @name Reply */
 export interface Reply extends Struct {
   readonly owner: GenericAccountId;
@@ -1074,15 +909,6 @@ export interface RoleStakeProfile extends Struct {
   readonly exit_unstaking_period: Option<u32>;
 }
 
-/** @name SameController */
-export interface SameController extends Null {}
-
-/** @name Schema */
-export interface Schema extends Null {}
-
-/** @name SchemaId */
-export interface SchemaId extends Null {}
-
 /** @name SealedVote */
 export interface SealedVote extends Struct {
   readonly voter: GenericAccountId;
@@ -1129,18 +955,9 @@ export interface SeriesParameters extends Struct {
   readonly meta: Option<Bytes>;
 }
 
-/** @name ServiceProviderRecord */
-export interface ServiceProviderRecord extends Null {}
-
 /** @name SetLeadParams */
 export interface SetLeadParams extends ITuple<[MemberId, GenericAccountId]> {}
 
-/** @name SideEffect */
-export interface SideEffect extends Null {}
-
-/** @name SideEffects */
-export interface SideEffects extends Null {}
-
 /** @name Slash */
 export interface Slash extends Struct {
   readonly started_at_block: u32;
@@ -1221,9 +1038,6 @@ export interface StaticBagId extends Enum {
   readonly asWorkingGroup: WorkingGroup;
 }
 
-/** @name Status */
-export interface Status extends Null {}
-
 /** @name StorageAssets */
 export interface StorageAssets extends Struct {
   readonly object_creation_list: Vec<DataObjectCreationParameters>;
@@ -1265,12 +1079,6 @@ export interface StorageObjectOwner extends Null {}
 /** @name StorageProviderId */
 export interface StorageProviderId extends u64 {}
 
-/** @name StoredPropertyValue */
-export interface StoredPropertyValue extends Null {}
-
-/** @name StoredValue */
-export interface StoredValue extends Null {}
-
 /** @name SubscriptionId */
 export interface SubscriptionId extends u64 {}
 
@@ -1282,9 +1090,6 @@ export interface TerminateRoleParameters extends Struct {
   readonly working_group: WorkingGroup;
 }
 
-/** @name TextMaxLength */
-export interface TextMaxLength extends Null {}
-
 /** @name Thread */
 export interface Thread extends Struct {
   readonly id: ThreadId;
@@ -1326,9 +1131,6 @@ export interface UnstakingApplicationStage extends Struct {
   readonly cause: ApplicationDeactivationCause;
 }
 
-/** @name UpdatePropertyValuesOperation */
-export interface UpdatePropertyValuesOperation extends Null {}
-
 /** @name UploadingStatus */
 export interface UploadingStatus extends Null {}
 
@@ -1343,18 +1145,6 @@ export interface UploadParameters extends Struct {
 /** @name Url */
 export interface Url extends Text {}
 
-/** @name VecInputValue */
-export interface VecInputValue extends Null {}
-
-/** @name VecMaxLength */
-export interface VecMaxLength extends Null {}
-
-/** @name VecStoredPropertyValue */
-export interface VecStoredPropertyValue extends Null {}
-
-/** @name VecStoredValue */
-export interface VecStoredValue extends Null {}
-
 /** @name Video */
 export interface Video extends Struct {
   readonly in_channel: ChannelId;
@@ -1454,7 +1244,4 @@ export interface WorkingGroup extends Enum {
   readonly isOperationsGamma: boolean;
 }
 
-/** @name WorkingGroupUnstaker */
-export interface WorkingGroupUnstaker extends Null {}
-
 export type PHANTOM_ALL = 'all';

+ 4 - 154
types/src/legacy.ts

@@ -1,93 +1,18 @@
 /*
-  Legacy types in Babylon runtime of unused modules:
-    - version-store
-    - versioned-store-permissions
-    - content-working-group
-    - old 'content-directory' which is now being replaced by new 'content' module
+  Legacy types from sumer runtime.
 
   We only add them here to make it possible for this version of the types library to be usable
-  against babylon runtime without expectation of using these deprecated runtime modules and their
-  types, primarily to perform a runtime upgrade of babylon for example.
+  against older runtime without expectation of using these deprecated types.
+  This is primarily to perform a runtime upgrade of prior runtime for example.
 
   Important Note: When new modules are added and happen to use type names that match the ones defined here
   make sure to remove them from this file!
-
-  In the following runtime upgrade (after "Sumer" release), remove these types entierly.
 */
 
 import { RegistryTypes } from '@polkadot/types/types'
 import { Null } from '@polkadot/types'
 
-// from: versioned-store, versioned-store permissions, content-working-group
-export class ChannelContentType extends Null {}
-export class ChannelCurationStatus extends Null {}
-export class ChannelPublicationStatus extends Null {}
-export class CurationActor extends Null {}
-export class Curator extends Null {}
-export class CuratorApplication extends Null {}
-export class CuratorApplicationId extends Null {}
-export class CuratorApplicationIdSet extends Null {}
-export class CuratorApplicationIdToCuratorIdMap extends Null {}
-export class CuratorOpening extends Null {}
-export class CuratorOpeningId extends Null {}
-export class Lead extends Null {}
-export class LeadId extends Null {}
-export class OptionalText extends Null {}
-export class Principal extends Null {}
-export class PrincipalId extends Null {}
-export class WorkingGroupUnstaker extends Null {}
-export class Credential extends Null {}
-export class CredentialSet extends Null {}
-
-// from: old content-directory
-export class Actor extends Null {}
-export class Nonce extends Null {}
-export class EntityId extends Null {}
-export class ClassId extends Null {}
-export class VecMaxLength extends Null {}
-export class TextMaxLength extends Null {}
-export class HashedTextMaxLength extends Null {}
-export class PropertyId extends Null {}
-export class SchemaId extends Null {}
-export class SameController extends Null {}
-export class ClassPermissions extends Null {}
-export class PropertyTypeSingle extends Null {}
-export class PropertyTypeVector extends Null {}
-export class PropertyType extends Null {}
-export class PropertyLockingPolicy extends Null {}
-export class Property extends Null {}
-export class Schema extends Null {}
-export class Class extends Null {}
-export class EntityController extends Null {}
-export class EntityPermissions extends Null {}
-export class StoredValue extends Null {}
-export class VecStoredValue extends Null {}
-export class VecStoredPropertyValue extends Null {}
-export class StoredPropertyValue extends Null {}
-export class InboundReferenceCounter extends Null {}
-export class Entity extends Null {}
-export class EntityCreationVoucher extends Null {}
-export class EntityReferenceCounterSideEffect extends Null {}
-export class ReferenceCounterSideEffects extends Null {}
-export class SideEffects extends Null {}
-export class SideEffect extends Null {}
-export class Status extends Null {}
-export class InputValue extends Null {}
-export class VecInputValue extends Null {}
-export class InputPropertyValue extends Null {}
-export class ParameterizedEntity extends Null {}
-export class ParametrizedPropertyValue extends Null {}
-export class ParametrizedClassPropertyValue extends Null {}
-export class CreateEntityOperation extends Null {}
-export class UpdatePropertyValuesOperation extends Null {}
-export class AddSchemaSupportToEntityOperation extends Null {}
-export class OperationType extends Null {}
-export class ClassPermissionsType extends Null {}
-export class ClassPropertyValue extends Null {}
-export class Operation extends Null {}
-export class ReferenceConstraint extends Null {}
-export class InputEntityValuesMap extends Null {}
-export class FailedAt extends Null {}
+// From "sumer" data_directory (old storage modules)
 export class ContentId extends Null {}
 export class ContentParameters extends Null {}
 export class DataObjectStorageRelationship extends Null {}
@@ -100,82 +25,7 @@ export class StorageObjectOwner extends Null {}
 export class UploadingStatus extends Null {}
 export class VoucherLimit extends Null {}
 
-// From discovery_service
-export class IPNSIdentity extends Null {}
-export class ServiceProviderRecord extends Null {}
-
 export const legacyTypes: RegistryTypes = {
-  ChannelContentType,
-  ChannelCurationStatus,
-  ChannelPublicationStatus,
-  CurationActor,
-  Curator,
-  CuratorApplication,
-  CuratorApplicationId,
-  CuratorApplicationIdSet,
-  CuratorApplicationIdToCuratorIdMap,
-  CuratorOpening,
-  CuratorOpeningId,
-  Lead,
-  LeadId,
-  OptionalText,
-  Principal,
-  PrincipalId,
-  WorkingGroupUnstaker,
-  Credential,
-  CredentialSet,
-  Nonce,
-  EntityId,
-  ClassId,
-  VecMaxLength,
-  TextMaxLength,
-  HashedTextMaxLength,
-  PropertyId,
-  SchemaId,
-  SameController,
-  ClassPermissions,
-  PropertyTypeSingle,
-  PropertyTypeVector,
-  PropertyType,
-  PropertyLockingPolicy,
-  Property,
-  Schema,
-  Class,
-  ClassOf: Class,
-  EntityController,
-  EntityPermissions,
-  StoredValue,
-  VecStoredValue,
-  VecStoredPropertyValue,
-  StoredPropertyValue,
-  InboundReferenceCounter,
-  Entity,
-  EntityOf: Entity,
-  EntityCreationVoucher,
-  Actor,
-  EntityReferenceCounterSideEffect,
-  ReferenceCounterSideEffects,
-  SideEffects,
-  SideEffect,
-  Status,
-  InputValue,
-  VecInputValue,
-  InputPropertyValue,
-  ParameterizedEntity,
-  ParametrizedPropertyValue,
-  ParametrizedClassPropertyValue,
-  CreateEntityOperation,
-  UpdatePropertyValuesOperation,
-  AddSchemaSupportToEntityOperation,
-  OperationType,
-  InputEntityValuesMap,
-  ClassPermissionsType,
-  ClassPropertyValue,
-  Operation,
-  ReferenceConstraint,
-  FailedAt,
-  IPNSIdentity,
-  ServiceProviderRecord,
   ContentId,
   ContentParameters,
   DataObjectStorageRelationship,