Configuration Errors
These examples illustrate common configuration errors, for various misconfigurations of Example 5 Isotopes and Rayleigh fractionation
Syntax error in .yaml config file
The model configuration (file examples/error_examples/config_ex5_syntax_error.yaml
) contains a syntax error in the .yaml config file, hence the initial parsing of the file fails.
############################################
# Example 5
# First order decay of a scalar variable
# with transfer of flux to a second variable
# Two domains, with isotopes
###########################################
example5_syntax_error:
parameters:
EIsotope: IsotopeLinear # hypothetical element E
domains:
fluxBoxes:
# yaml is whitespace sensitive, so this generates a syntax error
reactions:
flux:
class: ReactionFluxTarget
parameters:
target_prefix: flux_
fluxlist: ["B::EIsotope"] # extra space
global:
reactions:
sum_E:
class: ReactionSum
parameters:
vars_to_add: ["Box1.A", "Box2.B"]
variable_links:
sum: E_total
Box1:
# scalar domain
reactions:
reservoir_A:
class: ReactionReservoirScalar
parameters:
field_data: external%EIsotope
variable_links:
R*: A*
variable_attributes:
R:initial_value: 10.0
R:norm_value: 10.0
Adecay:
class: ReactionExample5
parameters:
field_data: external%EIsotope
kappa: 0.5
variable_links:
input_particle*: A*
output_flux: fluxBoxes.flux_B
Box2:
# scalar domain
reactions:
reservoir_B:
class: ReactionReservoirScalar
parameters:
field_data: external%EIsotope
variable_links:
R*: B*
variable_attributes:
R:initial_value: 0.0
R:norm_value: 10.0
transfer_fluxBoxes:
class: ReactionFluxTransfer
parameters:
input_fluxes: fluxBoxes.flux_$fluxname$
output_fluxes: $fluxname$_sms
This results in an error when the file is parsed (note that the informative message indicating that there is a problem with the YAML parsing is near the top of the stack trace):
julia> include(joinpath(ENV["PALEO_EXAMPLES"], "error_examples/run_ex5_syntax_error.jl"))
┌ Info: │ ================================================================================ │ create_model_from_config: configmodel example5_syntax_error │ config_file: /home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/config_ex5_syntax_error.yaml └ ================================================================================ ERROR: LoadError: YAML.ParserError while reading .yaml config file(s) ["/home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/config_ex5_syntax_error.yaml"]. If the error isn't obvious by looking at the file(s) (often this is a whitespace issue), install the VS Code YAML plugin, or try an online YAML validator eg http://www.yamllint.com in expression starting at /home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/run_ex5_syntax_error.jl:11
Missing / unlinked Variables
The model configuration (file examples/error_examples/config_ex5_reservoir_A_missing.yaml
) omits a ReactionReservoirScalar
, resulting in Variable Dependencies and Contributors with no corresponding Properties and Targets.
##################################################################
# ../reservoirs/config_ex5.yaml with common configuration errors
#################################################################
example5_reservoir_A_missing:
parameters:
EIsotope: IsotopeLinear # hypothetical element E
domains:
fluxBoxes:
reactions:
flux:
class: ReactionFluxTarget
parameters:
target_prefix: flux_
fluxlist: ["B::EIsotope"]
global:
reactions:
# remove this to check that 'missing A' is also correctly handled elsewhere
# sum_E:
# class: ReactionSum
# parameters:
# vars_to_add: ["Box1.A", "Box2.B"]
# variable_links:
# sum: E_total
Box1:
# scalar domain
reactions:
# configuration error: no reservoir_A
# reservoir_A:
# class: ReactionReservoirScalar
# parameters:
# field_data: external%EIsotope
# variable_links:
# R*: A*
# variable_attributes:
# R:initial_value: 10.0
# R:norm_value: 10.0
# R:initial_delta: -10.0
Adecay:
class: ReactionExample5
parameters:
field_data: external%EIsotope
kappa: 0.5
variable_links:
input_particle*: A*
output_flux: fluxBoxes.flux_B
Box2:
# scalar domain
reactions:
reservoir_B:
class: ReactionReservoirScalar
parameters:
field_data: external%EIsotope
variable_links:
R*: B*
variable_attributes:
R:initial_value: 0.0
R:norm_value: 10.0
R:initial_delta: 0.0
transfer_fluxBoxes:
class: ReactionFluxTransfer
parameters:
input_fluxes: fluxBoxes.flux_$fluxname$
output_fluxes: $fluxname$_sms
This results in an error when the Variables are linked:
julia> include(joinpath(ENV["PALEO_EXAMPLES"], "error_examples/run_ex5_reservoir_A_missing.jl"))
┌ Info: │ ================================================================================ │ create_model_from_config: configmodel example5_reservoir_A_missing │ config_file: /home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/config_ex5_reservoir_A_missing.yaml └ ================================================================================ ┌ Info: Model.parameters: └ EIsotope = IsotopeLinear ┌ Info: │ ================================================================================ │ creating Domains └ ================================================================================ [ Info: generated Reaction catalog with 74 Reactions ┌ Info: │ ================================================================================ │ creating domain 'global' ID=1 └ ================================================================================ ┌ Warning: create_domain_from_config Domain 'global' empty 'reactions:' key in .yaml file └ @ PALEOboxes ~/.julia/packages/PALEOboxes/PtQTd/src/Domain.jl:349 ┌ Info: │ ================================================================================ │ creating domain 'fluxBoxes' ID=2 └ ================================================================================ ┌ Info: create_reaction_from_config: fluxBoxes.flux classname ReactionFluxTarget │ set parameters: [config.yaml] fluxlist =["B::EIsotope"] │ set parameters: [config.yaml] target_prefix =flux_ │ set parameters: [Default] flux_totals =false └ set parameters: [Default] const_stub =false ┌ Info: │ ================================================================================ │ creating domain 'Box2' ID=3 └ ================================================================================ ┌ Info: create_reaction_from_config: Box2.reservoir_B classname ReactionReservoirScalar │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear │ set parameters: [Default] const =false └ set parameters: [Default] state_norm =false ┌ Info: create_reaction_from_config: Box2.transfer_fluxBoxes classname ReactionFluxTransfer │ set parameters: [config.yaml] input_fluxes =fluxBoxes.flux_$fluxname$ │ set parameters: [config.yaml] output_fluxes =$fluxname$_sms │ set parameters: [Default] transfer_multiplier =1.0 └ set parameters: [Default] transfer_matrix =Identity ┌ Info: │ ================================================================================ │ creating domain 'Box1' ID=4 └ ================================================================================ ┌ Info: create_reaction_from_config: Box1.Adecay classname ReactionExample5 │ set parameters: [config.yaml] kappa =0.5 │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear └ set parameters: [Default] Delta =-10.0 ┌ Info: │ ================================================================================ │ set_model_geometry └ ================================================================================ ┌ Info: │ ================================================================================ │ register_reaction_methods! └ ================================================================================ ┌ Info: │ ================================================================================ │ link_variables: first pass └ ================================================================================ ┌ Info: │ ================================================================================ │ link_variables: register_reaction_dynamic_methods and configure variables └ ================================================================================ ┌ Info: _configure_variables: ReactionReservoirScalar Box2.reservoir_B variable_links: │ set variable_links: R -> B │ set variable_links: R_sms -> B_sms │ set variable_links: R_norm -> B_norm │ set variable_links: R_delta -> B_delta │ _configure_variables: ReactionReservoirScalar Box2.reservoir_B variable_attributes: │ set attribute: R :norm_value = 10.0 │ set attribute: R :initial_value = 0.0 └ set attribute: R :initial_delta = 0.0 ┌ Info: _configure_variables: ReactionExample5 Box1.Adecay variable_links: │ set variable_links: input_particle -> A │ set variable_links: input_particle_sms -> A_sms │ set variable_links: input_particle_delta -> A_delta └ set variable_links: output_flux -> fluxBoxes.flux_B ┌ Info: │ ================================================================================ │ link_variables: second pass: └ ================================================================================ ┌ Info: │ ================================================================================ │ link_variables! unlinked variables: └ ================================================================================ ┌ Info: │ ================================================================================ │ create_model_from_config: done └ ================================================================================ ┌ Info: │ ================================================================================ │ PALEOmodel.initialize! start └ ================================================================================ ┌ Warning: check_variable_links: unexpected host-dependent Variable Box1.A_sms (usually an unlinked Variable due to eg a missing renaming in the :variable_links sections in the .yaml file, a spelling mistake either in a Variable default name in the code or renaming in the .yaml file, or a missing Reaction) │ PALEOboxes.VariableDomContribTarget "Box1.A_sms" links: │ target: nothing │ contributors: ["Box1.Adecay.do_example5.input_particle_sms"] │ dependencies: String[] └ @ PALEOboxes ~/.julia/packages/PALEOboxes/PtQTd/src/Model.jl:380 ┌ Warning: check_variable_links: unexpected host-dependent Variable Box1.A (usually an unlinked Variable due to eg a missing renaming in the :variable_links sections in the .yaml file, a spelling mistake either in a Variable default name in the code or renaming in the .yaml file, or a missing Reaction) │ PALEOboxes.VariableDomPropDep "Box1.A" links: │ property: nothing │ dependencies: ["Box1.Adecay.do_example5.input_particle"] └ @ PALEOboxes ~/.julia/packages/PALEOboxes/PtQTd/src/Model.jl:380 ┌ Warning: check_variable_links: unexpected host-dependent Variable Box1.A_delta (usually an unlinked Variable due to eg a missing renaming in the :variable_links sections in the .yaml file, a spelling mistake either in a Variable default name in the code or renaming in the .yaml file, or a missing Reaction) │ PALEOboxes.VariableDomPropDep "Box1.A_delta" links: │ property: nothing │ dependencies: ["Box1.Adecay.do_example5.input_particle_delta"] └ @ PALEOboxes ~/.julia/packages/PALEOboxes/PtQTd/src/Model.jl:380 ┌ Error: check_variable_links failed └ @ PALEOboxes ~/.julia/packages/PALEOboxes/PtQTd/src/Model.jl:387 ERROR: LoadError: check_variable_links failed in expression starting at /home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/run_ex5_reservoir_A_missing.jl:20
A duplicated Variable or a name collision
The model configuration (file examples/error_examples/config_ex5_reservoir_A_duplicate.yaml
) contains two copies of a ReactionReservoirScalar
, both attempting to create the same VariableDomains
##################################################################
# ../reservoirs/config_ex5.yaml with common configuration errors
#################################################################
example5_reservoir_A_duplicate:
parameters:
EIsotope: IsotopeLinear # hypothetical element E
domains:
fluxBoxes:
reactions:
flux:
class: ReactionFluxTarget
parameters:
target_prefix: flux_
fluxlist: ["B::EIsotope"]
global:
reactions:
sum_E:
class: ReactionSum
parameters:
vars_to_add: ["Box1.A", "Box2.B"]
variable_links:
sum: E_total
Box1:
# scalar domain
reactions:
reservoir_A:
class: ReactionReservoirScalar
parameters:
field_data: external%EIsotope
variable_links:
R*: A*
variable_attributes:
R:initial_value: 10.0
R:norm_value: 10.0
# configuration error: duplicate reservoir_A
reservoir_Adup:
class: ReactionReservoirScalar
parameters:
field_data: external%EIsotope
variable_links:
R*: A*
variable_attributes:
R:initial_value: 10.0
R:norm_value: 10.0
Adecay:
class: ReactionExample5
parameters:
field_data: external%EIsotope
kappa: 0.5
variable_links:
input_particle*: A*
output_flux: fluxBoxes.flux_B
Box2:
# scalar domain
reactions:
reservoir_B:
class: ReactionReservoirScalar
parameters:
field_data: external%EIsotope
variable_links:
R*: B*
variable_attributes:
R:initial_value: 0.0
R:norm_value: 10.0
transfer_fluxBoxes:
class: ReactionFluxTransfer
parameters:
input_fluxes: fluxBoxes.flux_$fluxname$
output_fluxes: $fluxname$_sms
This results in an error when the Variables are linked:
julia> include(joinpath(ENV["PALEO_EXAMPLES"], "error_examples/run_ex5_reservoir_A_duplicate.jl"))
┌ Info: │ ================================================================================ │ create_model_from_config: configmodel example5_reservoir_A_duplicate │ config_file: /home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/config_ex5_reservoir_A_duplicate.yaml └ ================================================================================ ┌ Info: Model.parameters: └ EIsotope = IsotopeLinear ┌ Info: │ ================================================================================ │ creating Domains └ ================================================================================ [ Info: generated Reaction catalog with 74 Reactions ┌ Info: │ ================================================================================ │ creating domain 'global' ID=1 └ ================================================================================ ┌ Info: create_reaction_from_config: global.sum_E classname ReactionSum │ set parameters: [config.yaml] vars_to_add =["Box1.A", "Box2.B"] │ set parameters: [Default] vars_prefix = │ set parameters: [Default] component_to_add =0 └ set parameters: [Default] vectorsum =false ┌ Info: │ ================================================================================ │ creating domain 'fluxBoxes' ID=2 └ ================================================================================ ┌ Info: create_reaction_from_config: fluxBoxes.flux classname ReactionFluxTarget │ set parameters: [config.yaml] fluxlist =["B::EIsotope"] │ set parameters: [config.yaml] target_prefix =flux_ │ set parameters: [Default] flux_totals =false └ set parameters: [Default] const_stub =false ┌ Info: │ ================================================================================ │ creating domain 'Box2' ID=3 └ ================================================================================ ┌ Info: create_reaction_from_config: Box2.reservoir_B classname ReactionReservoirScalar │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear │ set parameters: [Default] const =false └ set parameters: [Default] state_norm =false ┌ Info: create_reaction_from_config: Box2.transfer_fluxBoxes classname ReactionFluxTransfer │ set parameters: [config.yaml] input_fluxes =fluxBoxes.flux_$fluxname$ │ set parameters: [config.yaml] output_fluxes =$fluxname$_sms │ set parameters: [Default] transfer_multiplier =1.0 └ set parameters: [Default] transfer_matrix =Identity ┌ Info: │ ================================================================================ │ creating domain 'Box1' ID=4 └ ================================================================================ ┌ Info: create_reaction_from_config: Box1.Adecay classname ReactionExample5 │ set parameters: [config.yaml] kappa =0.5 │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear └ set parameters: [Default] Delta =-10.0 ┌ Info: create_reaction_from_config: Box1.reservoir_Adup classname ReactionReservoirScalar │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear │ set parameters: [Default] const =false └ set parameters: [Default] state_norm =false ┌ Info: create_reaction_from_config: Box1.reservoir_A classname ReactionReservoirScalar │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear │ set parameters: [Default] const =false └ set parameters: [Default] state_norm =false ┌ Info: │ ================================================================================ │ set_model_geometry └ ================================================================================ ┌ Info: │ ================================================================================ │ register_reaction_methods! └ ================================================================================ ┌ Info: register_methods: global.sum_E PALEOboxes.VariableStats.ReactionSum │ add 1 * Box1.A └ add 1 * Box2.B ┌ Info: │ ================================================================================ │ link_variables: first pass └ ================================================================================ ERROR: LoadError: Duplicate variable name: Linking VariableReactProperty Box1.reservoir_A.do_reactionreservoirscalar.R_norm --> Box1.A_norm Variable Box1.A_norm already exists and has a property Variable, links: PALEOboxes.VariableDomPropDep "Box1.A_norm" links: property: "Box1.reservoir_Adup.do_reactionreservoirscalar.R_norm" dependencies: String[] in expression starting at /home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/run_ex5_reservoir_A_duplicate.jl:11
Mismatch in :field_data Type (eg isotopes) (Reservoir)
The model configuration (file examples/error_examples/config_ex5_reservoir_A_noisotope.yaml
) contains one ReactionReservoirScalar
with :field_data=ScalarData
where this species should have :field_data=IsotopeLinear
:
##################################################################
# ../reservoirs/config_ex5.yaml with common configuration errors
#################################################################
example5_reservoir_A_noisotope:
parameters:
EIsotope: IsotopeLinear # hypothetical element E
domains:
fluxBoxes:
reactions:
flux:
class: ReactionFluxTarget
parameters:
target_prefix: flux_
fluxlist: ["B::EIsotope"]
global:
reactions:
sum_E:
class: ReactionSum
parameters:
vars_to_add: ["Box1.A", "Box2.B"]
variable_links:
sum: E_total
Box1:
# scalar domain
reactions:
reservoir_A:
class: ReactionReservoirScalar
parameters:
# configuration error: :field_data not set to IsotopeLinear
# (defaults to ScalarData)
# field_data: external%EIsotope
variable_links:
R*: A*
variable_attributes:
R:initial_value: 10.0
R:norm_value: 10.0
Adecay:
class: ReactionExample5
parameters:
field_data: external%EIsotope
kappa: 0.5
variable_links:
input_particle*: A*
output_flux: fluxBoxes.flux_B
Box2:
# scalar domain
reactions:
reservoir_B:
class: ReactionReservoirScalar
parameters:
field_data: external%EIsotope
variable_links:
R*: B*
variable_attributes:
R:initial_value: 0.0
R:norm_value: 10.0
R:initial_delta: 0.0
transfer_fluxBoxes:
class: ReactionFluxTransfer
parameters:
input_fluxes: fluxBoxes.flux_$fluxname$
output_fluxes: $fluxname$_sms
This results in an error when the Variables are linked:
julia> include(joinpath(ENV["PALEO_EXAMPLES"], "error_examples/run_ex5_reservoir_A_noisotope.jl"))
┌ Info: │ ================================================================================ │ create_model_from_config: configmodel example5_reservoir_A_noisotope │ config_file: /home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/config_ex5_reservoir_A_noisotope.yaml └ ================================================================================ ┌ Info: Model.parameters: └ EIsotope = IsotopeLinear ┌ Info: │ ================================================================================ │ creating Domains └ ================================================================================ [ Info: generated Reaction catalog with 74 Reactions ┌ Info: │ ================================================================================ │ creating domain 'global' ID=1 └ ================================================================================ ┌ Info: create_reaction_from_config: global.sum_E classname ReactionSum │ set parameters: [config.yaml] vars_to_add =["Box1.A", "Box2.B"] │ set parameters: [Default] vars_prefix = │ set parameters: [Default] component_to_add =0 └ set parameters: [Default] vectorsum =false ┌ Info: │ ================================================================================ │ creating domain 'fluxBoxes' ID=2 └ ================================================================================ ┌ Info: create_reaction_from_config: fluxBoxes.flux classname ReactionFluxTarget │ set parameters: [config.yaml] fluxlist =["B::EIsotope"] │ set parameters: [config.yaml] target_prefix =flux_ │ set parameters: [Default] flux_totals =false └ set parameters: [Default] const_stub =false ┌ Info: │ ================================================================================ │ creating domain 'Box2' ID=3 └ ================================================================================ ┌ Info: create_reaction_from_config: Box2.reservoir_B classname ReactionReservoirScalar │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear │ set parameters: [Default] const =false └ set parameters: [Default] state_norm =false ┌ Info: create_reaction_from_config: Box2.transfer_fluxBoxes classname ReactionFluxTransfer │ set parameters: [config.yaml] input_fluxes =fluxBoxes.flux_$fluxname$ │ set parameters: [config.yaml] output_fluxes =$fluxname$_sms │ set parameters: [Default] transfer_multiplier =1.0 └ set parameters: [Default] transfer_matrix =Identity ┌ Info: │ ================================================================================ │ creating domain 'Box1' ID=4 └ ================================================================================ ┌ Info: create_reaction_from_config: Box1.Adecay classname ReactionExample5 │ set parameters: [config.yaml] kappa =0.5 │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear └ set parameters: [Default] Delta =-10.0 ┌ Info: create_reaction_from_config: Box1.reservoir_A classname ReactionReservoirScalar │ set parameters: [Default] field_data =PALEOboxes.ScalarData │ set parameters: [Default] const =false └ set parameters: [Default] state_norm =false ┌ Info: │ ================================================================================ │ set_model_geometry └ ================================================================================ ┌ Info: │ ================================================================================ │ register_reaction_methods! └ ================================================================================ ┌ Info: register_methods: global.sum_E PALEOboxes.VariableStats.ReactionSum │ add 1 * Box1.A └ add 1 * Box2.B ┌ Info: │ ================================================================================ │ link_variables: first pass └ ================================================================================ ┌ Info: │ ================================================================================ │ link_variables: register_reaction_dynamic_methods and configure variables └ ================================================================================ [ Info: Reaction global.sum_E Variable global.E_total adding data=PALEOboxes.ScalarData ERROR: LoadError: Reaction global.sum_E not all variables to be summed have the same :field_data Type: Box2.B PALEOboxes.IsotopeLinear != Box1.A PALEOboxes.ScalarData in expression starting at /home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/run_ex5_reservoir_A_noisotope.jl:11
Mismatch in :field_data Type (eg isotopes) (Flux)
The model configuration (file examples/error_examples/config_ex5_flux_noisotope.yaml
) contains a Variable defined by a ReactionFluxTarget
with default :field_data=ScalarData
where this species should have :field_data=IsotopeLinear
:
##################################################################
# ../reservoirs/config_ex5.yaml with common configuration errors
#################################################################
example5_flux_noisotope:
parameters:
EIsotope: IsotopeLinear # hypothetical element E
domains:
fluxBoxes:
reactions:
flux:
class: ReactionFluxTarget
parameters:
target_prefix: flux_
# configuration error: fluxlist not set to IsotopeLinear
# (defaults to ScalarData)
# fluxlist: ["B::EIsotope"]
fluxlist: ["B"]
global:
reactions:
sum_E:
class: ReactionSum
parameters:
vars_to_add: ["Box1.A", "Box2.B"]
variable_links:
sum: E_total
Box1:
# scalar domain
reactions:
reservoir_A:
class: ReactionReservoirScalar
parameters:
field_data: external%EIsotope
variable_links:
R*: A*
variable_attributes:
R:initial_value: 10.0
R:norm_value: 10.0
R:initial_delta: -10.0
Adecay:
class: ReactionExample5
parameters:
field_data: external%EIsotope
kappa: 0.5
variable_links:
input_particle*: A*
output_flux: fluxBoxes.flux_B
Box2:
# scalar domain
reactions:
reservoir_B:
class: ReactionReservoirScalar
parameters:
field_data: external%EIsotope
variable_links:
R*: B*
variable_attributes:
R:initial_value: 0.0
R:norm_value: 10.0
R:initial_delta: 0.0
transfer_fluxBoxes:
class: ReactionFluxTransfer
parameters:
input_fluxes: fluxBoxes.flux_$fluxname$
output_fluxes: $fluxname$_sms
This results in an error when the Variables are linked:
julia> include(joinpath(ENV["PALEO_EXAMPLES"], "error_examples/run_ex5_flux_noisotope.jl"))
┌ Info: │ ================================================================================ │ create_model_from_config: configmodel example5_flux_noisotope │ config_file: /home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/config_ex5_flux_noisotope.yaml └ ================================================================================ ┌ Info: Model.parameters: └ EIsotope = IsotopeLinear ┌ Info: │ ================================================================================ │ creating Domains └ ================================================================================ [ Info: generated Reaction catalog with 74 Reactions ┌ Info: │ ================================================================================ │ creating domain 'global' ID=1 └ ================================================================================ ┌ Info: create_reaction_from_config: global.sum_E classname ReactionSum │ set parameters: [config.yaml] vars_to_add =["Box1.A", "Box2.B"] │ set parameters: [Default] vars_prefix = │ set parameters: [Default] component_to_add =0 └ set parameters: [Default] vectorsum =false ┌ Info: │ ================================================================================ │ creating domain 'fluxBoxes' ID=2 └ ================================================================================ ┌ Info: create_reaction_from_config: fluxBoxes.flux classname ReactionFluxTarget │ set parameters: [config.yaml] fluxlist =["B"] │ set parameters: [config.yaml] target_prefix =flux_ │ set parameters: [Default] flux_totals =false └ set parameters: [Default] const_stub =false ┌ Info: │ ================================================================================ │ creating domain 'Box2' ID=3 └ ================================================================================ ┌ Info: create_reaction_from_config: Box2.reservoir_B classname ReactionReservoirScalar │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear │ set parameters: [Default] const =false └ set parameters: [Default] state_norm =false ┌ Info: create_reaction_from_config: Box2.transfer_fluxBoxes classname ReactionFluxTransfer │ set parameters: [config.yaml] input_fluxes =fluxBoxes.flux_$fluxname$ │ set parameters: [config.yaml] output_fluxes =$fluxname$_sms │ set parameters: [Default] transfer_multiplier =1.0 └ set parameters: [Default] transfer_matrix =Identity ┌ Info: │ ================================================================================ │ creating domain 'Box1' ID=4 └ ================================================================================ ┌ Info: create_reaction_from_config: Box1.Adecay classname ReactionExample5 │ set parameters: [config.yaml] kappa =0.5 │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear └ set parameters: [Default] Delta =-10.0 ┌ Info: create_reaction_from_config: Box1.reservoir_A classname ReactionReservoirScalar │ set parameters: [config.yaml] field_data =external%EIsotope │ expandvalue: external%EIsotope -> IsotopeLinear │ after substitution field_data=IsotopeLinear │ set parameters: [Default] const =false └ set parameters: [Default] state_norm =false ┌ Info: │ ================================================================================ │ set_model_geometry └ ================================================================================ ┌ Info: │ ================================================================================ │ register_reaction_methods! └ ================================================================================ ┌ Info: register_methods: global.sum_E PALEOboxes.VariableStats.ReactionSum │ add 1 * Box1.A └ add 1 * Box2.B ┌ Info: │ ================================================================================ │ link_variables: first pass └ ================================================================================ ┌ Info: │ ================================================================================ │ link_variables: register_reaction_dynamic_methods and configure variables └ ================================================================================ [ Info: Reaction global.sum_E Variable global.E_total adding data=PALEOboxes.IsotopeLinear ┌ Info: _configure_variables: ReactionSum global.sum_E variable_links: └ set variable_links: sum -> E_total ┌ Info: _configure_variables: ReactionReservoirScalar Box2.reservoir_B variable_links: │ set variable_links: R -> B │ set variable_links: R_sms -> B_sms │ set variable_links: R_norm -> B_norm │ set variable_links: R_delta -> B_delta │ _configure_variables: ReactionReservoirScalar Box2.reservoir_B variable_attributes: │ set attribute: R :norm_value = 10.0 │ set attribute: R :initial_value = 0.0 └ set attribute: R :initial_delta = 0.0 ┌ Info: _configure_variables: ReactionExample5 Box1.Adecay variable_links: │ set variable_links: input_particle -> A │ set variable_links: input_particle_sms -> A_sms │ set variable_links: input_particle_delta -> A_delta └ set variable_links: output_flux -> fluxBoxes.flux_B ┌ Info: _configure_variables: ReactionReservoirScalar Box1.reservoir_A variable_links: │ set variable_links: R -> A │ set variable_links: R_sms -> A_sms │ set variable_links: R_norm -> A_norm │ set variable_links: R_delta -> A_delta │ _configure_variables: ReactionReservoirScalar Box1.reservoir_A variable_attributes: │ set attribute: R :norm_value = 10.0 │ set attribute: R :initial_value = 10.0 └ set attribute: R :initial_delta = -10.0 ┌ Info: │ ================================================================================ │ link_variables: second pass: └ ================================================================================ ┌ Info: │ ================================================================================ │ link_variables! unlinked variables: └ ================================================================================ ┌ Info: │ ================================================================================ │ create_model_from_config: done └ ================================================================================ ┌ Info: │ ================================================================================ │ PALEOmodel.initialize! start └ ================================================================================ ┌ Info: │ ================================================================================ │ allocate_variables! (modeldata arrays_idx=1) └ ================================================================================ [ Info: Domain global data dimensions PALEOboxes.NamedDimension[] allocating 1 variables (hostdep=nothing) [ Info: Domain fluxBoxes data dimensions PALEOboxes.NamedDimension[] allocating 1 variables (hostdep=nothing) [ Info: Domain Box2 data dimensions PALEOboxes.NamedDimension[] allocating 4 variables (hostdep=nothing) [ Info: Domain Box1 data dimensions PALEOboxes.NamedDimension[] allocating 5 variables (hostdep=nothing) [ Info: set_default_solver_view: ┌ Info: SolverView: │ host-dependent Variables: │ ------------------------------------------------------------------------------------------------------------------------------------------------ │ Domain operatorID VF_StateExplicit VF_Total VF_Constraint VF_StateTotal VF_State VF_Undefined │ global 0 0 0 0 0 0 0 │ fluxBoxes 0 0 0 0 0 0 0 │ Box2 0 1 0 0 0 0 0 │ Box1 0 1 0 0 0 0 0 │ ------------------------------------------------------------------------------------------------------------------------------------------------ │ Total - 2 0 0 0 0 0 │ ------------------------------------------------------------------------------------------------------------------------------------------------ │ n_state_vars 2 (stateexplicit 2 + statetotal 0 + state 0) │ n_equations 2 (stateexplicit 2 + total 0 + constraint 0) │ including all host-dependent non-state Variables └ host-dependent non-state Variables (:vfunction PB.VF_Undefined): Any[] ┌ Info: │ ================================================================================ │ initialize_reactiondata! (modeldata arrays_indices=1:1) └ ================================================================================ ┌ Warning: create_accessor: VariableReaction Box1.Adecay.do_example5.output_flux -> fluxBoxes.flux_B: invalid :field_data combination - attempting to link a Variable with :field_data=PALEOboxes.IsotopeLinear to a Variable with :field_data=PALEOboxes.ScalarData └ @ PALEOboxes ~/.julia/packages/PALEOboxes/PtQTd/src/VariableReaction.jl:759 ERROR: LoadError: MethodError: no method matching create_accessor(::Type{PALEOboxes.IsotopeLinear}, ::PALEOboxes.Field{PALEOboxes.ScalarData, PALEOboxes.CellSpace, Vector{Float64}, 0, Nothing}, ::Nothing; forceview::Bool, components::Bool) Closest candidates are: create_accessor(::Union{Type{FieldData}, Type{PALEOboxes.UndefinedData}}, ::PALEOboxes.Field{FieldData, Space, V, N, Mesh}, ::Union{Nothing, PALEOboxes.AbstractSubdomain}; forceview, components) where {FieldData, Space, V, N, Mesh} @ PALEOboxes ~/.julia/packages/PALEOboxes/PtQTd/src/Fields.jl:480 create_accessor(::Type{PALEOboxes.ScalarData}, ::PALEOboxes.Field{PALEOboxes.IsotopeLinear, S, V, W, M}, ::Union{Nothing, PALEOboxes.AbstractSubdomain}; forceview, components) where {S, V, W, M} @ PALEOboxes ~/.julia/packages/PALEOboxes/PtQTd/src/data/IsotopeData.jl:380 in expression starting at /home/runner/work/PALEOtutorials.jl/PALEOtutorials.jl/examples/error_examples/run_ex5_flux_noisotope.jl:20