You shouldn't use the JPATH_ROOT constant, because at possible it won't be defined. Stick with `dirname(__FILE__) . '/src/field'`.