mpl_candy_machine_core/
errors.rs1use anchor_lang::prelude::*;
2
3#[error_code]
4pub enum CandyError {
5 #[msg("Account does not have correct owner")]
6 IncorrectOwner,
7
8 #[msg("Account is not initialized")]
9 Uninitialized,
10
11 #[msg("Mint Mismatch")]
12 MintMismatch,
13
14 #[msg("Index greater than length")]
15 IndexGreaterThanLength,
16
17 #[msg("Numerical overflow error")]
18 NumericalOverflowError,
19
20 #[msg("Can only provide up to 4 creators to candy machine (because candy machine is one)")]
21 TooManyCreators,
22
23 #[msg("Candy machine is empty")]
24 CandyMachineEmpty,
25
26 #[msg("Candy machines using hidden uris do not have config lines, they have a single hash representing hashed order")]
27 HiddenSettingsDoNotHaveConfigLines,
28
29 #[msg("Cannot change number of lines unless is a hidden config")]
30 CannotChangeNumberOfLines,
31
32 #[msg("Cannot switch to hidden settings after items available is greater than 0")]
33 CannotSwitchToHiddenSettings,
34
35 #[msg("Incorrect collection NFT authority")]
36 IncorrectCollectionAuthority,
37
38 #[msg("The metadata account has data in it, and this must be empty to mint a new NFT")]
39 MetadataAccountMustBeEmpty,
40
41 #[msg("Can't change collection settings after items have begun to be minted")]
42 NoChangingCollectionDuringMint,
43
44 #[msg("Value longer than expected maximum value")]
45 ExceededLengthError,
46
47 #[msg("Missing config lines settings")]
48 MissingConfigLinesSettings,
49
50 #[msg("Cannot increase the length in config lines settings")]
51 CannotIncreaseLength,
52
53 #[msg("Cannot switch from hidden settings")]
54 CannotSwitchFromHiddenSettings,
55
56 #[msg("Cannot change sequential index generation after items have begun to be minted")]
57 CannotChangeSequentialIndexGeneration,
58
59 #[msg("Collection public key mismatch")]
60 CollectionKeyMismatch,
61
62 #[msg("Could not retrive config line data")]
63 CouldNotRetrieveConfigLineData,
64
65 #[msg("Not all config lines were added to the candy machine")]
66 NotFullyLoaded,
67
68 #[msg("Instruction could not be created")]
69 InstructionBuilderFailed,
70
71 #[msg("Missing collection authority record")]
72 MissingCollectionAuthorityRecord,
73
74 #[msg("Missing metadata delegate record")]
75 MissingMetadataDelegateRecord,
76
77 #[msg("Invalid token standard")]
78 InvalidTokenStandard,
79
80 #[msg("Missing token account")]
81 MissingTokenAccount,
82
83 #[msg("Missing token record")]
84 MissingTokenRecord,
85
86 #[msg("Missing instructions sysvar account")]
87 MissingInstructionsSysvar,
88
89 #[msg("Missing SPL ATA program")]
90 MissingSplAtaProgram,
91
92 #[msg("Invalid account version")]
93 InvalidAccountVersion,
94}