Closed DevMude closed 1 year ago
@DevMude can you list all the plugins you have active and their versions? And provide an export of your ACF Field Group(s)?
Would be super helpful to see if I can reproduce this.
@DevMude could you try the attached version of the plugin and see if the errors go away? The .zip below is built from the upcoming v2.0.0-beta.5.0.0 release PR
Hello @DevMude, I'm going to go ahead and close this for now. We can revisit if needed later. Thank you for helping!
Description
When loading graphiql, getting the following error:
``` PHP Fatal error: Uncaught TypeError: WPGraphQL\Acf\Registry::get_field_group_graphql_type_name(): Argument #1 ($field_group) must be of type array, bool given, called in /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php on line 294 and defined in /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php:507 Stack trace: #0 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php(294): WPGraphQL\Acf\Registry->get_field_group_graphql_type_name(false) #1 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php(612): WPGraphQL\Acf\Registry->get_field_group_interfaces(Array) #2 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/FieldType/Repeater.php(26): WPGraphQL\Acf\Registry->register_acf_field_groups_to_graphql(Array) #3 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/AcfGraphQLFieldType.php(293): WPGraphQL\Acf\FieldType\Repeater::WPGraphQL\Acf\FieldType\{closure}(Object(WPGraphQL\Acf\FieldConfig), Object(WPGraphQL\Acf\AcfGraphQLFieldType)) #4 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/FieldConfig.php(179): WPGraphQL\Acf\AcfGraphQLFieldType->get_resolve_type(Object(WPGraphQL\Acf\FieldConfig)) #5 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php(474): WPGraphQL\Acf\FieldConfig->get_graphql_field_config() #6 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php(444): WPGraphQL\Acf\Registry->map_acf_field_to_graphql(Array, Array) #7 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php(611): WPGraphQL\Acf\Registry->get_fields_for_field_group(Array) #8 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/FieldType/Group.php(26): WPGraphQL\Acf\Registry->register_acf_field_groups_to_graphql(Array) #9 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/AcfGraphQLFieldType.php(293): WPGraphQL\Acf\FieldType\Group::WPGraphQL\Acf\FieldType\{closure}(Object(WPGraphQL\Acf\FieldConfig), Object(WPGraphQL\Acf\AcfGraphQLFieldType)) #10 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/FieldConfig.php(179): WPGraphQL\Acf\AcfGraphQLFieldType->get_resolve_type(Object(WPGraphQL\Acf\FieldConfig)) #11 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php(474): WPGraphQL\Acf\FieldConfig->get_graphql_field_config() #12 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php(444): WPGraphQL\Acf\Registry->map_acf_field_to_graphql(Array, Array) #13 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php(611): WPGraphQL\Acf\Registry->get_fields_for_field_group(Array) #14 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/WPGraphQLAcf.php(101): WPGraphQL\Acf\Registry->register_acf_field_groups_to_graphql(Array) #15 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/class-wp-hook.php(307): WPGraphQLAcf->init_registry(Object(WPGraphQL\Registry\TypeRegistry)) #16 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters(NULL, Array) #17 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/plugin.php(476): WP_Hook->do_action(Array) #18 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql/src/Registry/TypeRegistry.php(600): do_action('graphql_registe...', Object(WPGraphQL\Registry\TypeRegistry)) #19 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/class-wp-hook.php(307): WPGraphQL\Registry\TypeRegistry->init_type_registry(Object(WPGraphQL\Registry\TypeRegistry)) #20 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters('', Array) #21 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/plugin.php(476): WP_Hook->do_action(Array) #22 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql/src/Registry/TypeRegistry.php(262): do_action('init_graphql_ty...', Object(WPGraphQL\Registry\TypeRegistry)) #23 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql/src/Registry/SchemaRegistry.php(36): WPGraphQL\Registry\TypeRegistry->init() #24 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql/src/WPGraphQL.php(777): WPGraphQL\Registry\SchemaRegistry->get_schema() #25 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql/src/Request.php(156): WPGraphQL::get_schema() #26 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql/src/Router.php(468): WPGraphQL\Request->__construct() #27 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql/src/Router.php(263): WPGraphQL\Router::process_http_request() #28 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/class-wp-hook.php(307): WPGraphQL\Router::resolve_http_request(Object(WP)) #29 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/class-wp-hook.php(331): WP_Hook->apply_filters(NULL, Array) #30 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/plugin.php(524): WP_Hook->do_action(Array) #31 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/class-wp.php(398): do_action_ref_array('parse_request', Array) #32 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/class-wp.php(770): WP->parse_request('') #33 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-includes/functions.php(1330): WP->main('') #34 /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-blog-header.php(16): wp() #35 /Applications/XAMPP/xamppfiles/htdocs/my-website/index.php(17): require('/Applications/X...') #36 {main} thrown in /Applications/XAMPP/xamppfiles/htdocs/my-website/wp-content/plugins/wp-graphql-acf/src/Registry.php on line 507 ```Steps to reproduce
Updated wp-graphql from 1.13.8 -> 1.16.0 (graphiql still works) Updated wp-graphql-acf from 0.6.1 -> 2.0.0-beta.4.0.0 (graphiql breaks)
PHP or JSON export of the ACF Field Group(s)
Moved all field groups to trash and error still occuring.
Additional context
No response
WPGraphQL Version
1.16.0
WPGraphQL For ACF Version
2.0.0-beta.4.0.0
ACF (Advanced Custom Fields) Version. Free or Pro?
6.2.1.1 Pro
WordPress Version
6.0.2
PHP Version
8.0.2
Additional enviornment details
No response
Please confirm that you have searched existing issues in the repo.
Please confirm that you have disabled ALL plugins except for WPGraphQL, WPGraphQL For ACF, ACF, etc.