Skip to content

Instantly share code, notes, and snippets.

@landbryo
Created February 6, 2024 17:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save landbryo/816cc9525ae1c96a0587c4dcb294ce06 to your computer and use it in GitHub Desktop.
Save landbryo/816cc9525ae1c96a0587c4dcb294ce06 to your computer and use it in GitHub Desktop.
Package GraphQL error
{
"errors": [
{
"debugMessage": "Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource::Vox_Media\\Vox_Media_Theme\\Components\\Packages\\{closure}(): Argument #1 ($post) must be of type WP_Post, bool given",
"message": "Internal server error",
"extensions": {
"category": "internal"
},
"locations": [
{
"line": 423,
"column": 2
}
],
"path": [
"resource",
"hero"
],
"trace": [
{
"file": "/var/www/wp-content/themes/vox-media-theme/php/components/packages/class-package-resource.php",
"line": 239,
"function": "array_map(instance of Closure, array(1))"
},
{
"file": "/var/www/wp-content/themes/vox-media-theme/php/components/packages/class-package-resources-retriever.php",
"line": 99,
"call": "Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource::get_posts('hero_ids')"
},
{
"file": "/var/www/wp-content/themes/vox-media-theme/php/components/packages/class-package-graphql-extensions.php",
"line": 325,
"call": "Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resources_Retriever::get_resources()"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/src/Utils/InstrumentSchema.php",
"line": 145,
"call": "Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_GraphQL_Extensions::Vox_Media\\Vox_Media_Theme\\Components\\Packages\\{closure}(instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource, array(0), instance of WPGraphQL\\AppContext, instance of GraphQL\\Type\\Definition\\ResolveInfo)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 623,
"call": "WPGraphQL\\Utils\\InstrumentSchema::WPGraphQL\\Utils\\{closure}(instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource, array(0), instance of WPGraphQL\\AppContext, instance of GraphQL\\Type\\Definition\\ResolveInfo)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 549,
"call": "GraphQL\\Executor\\ReferenceExecutor::resolveFieldValueOrError(instance of GraphQL\\Type\\Definition\\FieldDefinition, instance of GraphQL\\Language\\AST\\FieldNode, instance of Closure, instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource, instance of GraphQL\\Type\\Definition\\ResolveInfo)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 1195,
"call": "GraphQL\\Executor\\ReferenceExecutor::resolveField(GraphQLType: PackageResourceType, instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource, instance of ArrayObject(1), array(2))"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 1145,
"call": "GraphQL\\Executor\\ReferenceExecutor::executeFields(GraphQLType: PackageResourceType, instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource, array(1), instance of ArrayObject(35))"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 1105,
"call": "GraphQL\\Executor\\ReferenceExecutor::collectAndExecuteSubfields(GraphQLType: PackageResourceType, instance of ArrayObject(1), array(1), instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 973,
"call": "GraphQL\\Executor\\ReferenceExecutor::completeObjectValue(GraphQLType: PackageResourceType, instance of ArrayObject(1), instance of GraphQL\\Type\\Definition\\ResolveInfo, array(1), instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 789,
"call": "GraphQL\\Executor\\ReferenceExecutor::completeAbstractValue(GraphQLType: ResourceType, instance of ArrayObject(1), instance of GraphQL\\Type\\Definition\\ResolveInfo, array(1), instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 740,
"call": "GraphQL\\Executor\\ReferenceExecutor::completeValue(GraphQLType: ResourceType, instance of ArrayObject(1), instance of GraphQL\\Type\\Definition\\ResolveInfo, array(1), instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 654,
"call": "GraphQL\\Executor\\ReferenceExecutor::completeValue(GraphQLType: ResourceType, instance of ArrayObject(1), instance of GraphQL\\Type\\Definition\\ResolveInfo, array(1), instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 556,
"call": "GraphQL\\Executor\\ReferenceExecutor::completeValueCatchingError(GraphQLType: ResourceType, instance of ArrayObject(1), instance of GraphQL\\Type\\Definition\\ResolveInfo, array(1), instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 1195,
"call": "GraphQL\\Executor\\ReferenceExecutor::resolveField(GraphQLType: RootQuery, null, instance of ArrayObject(1), array(1))"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 264,
"call": "GraphQL\\Executor\\ReferenceExecutor::executeFields(GraphQLType: RootQuery, null, array(0), instance of ArrayObject(6))"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 215,
"call": "GraphQL\\Executor\\ReferenceExecutor::executeOperation(instance of GraphQL\\Language\\AST\\OperationDefinitionNode, null)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/Executor.php",
"line": 156,
"call": "GraphQL\\Executor\\ReferenceExecutor::doExecute()"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/GraphQL.php",
"line": 161,
"call": "GraphQL\\Executor\\Executor::promiseToExecute(instance of GraphQL\\Executor\\Promise\\Adapter\\SyncPromiseAdapter, instance of WPGraphQL\\WPSchema, instance of GraphQL\\Language\\AST\\DocumentNode, null, instance of WPGraphQL\\AppContext, array(1), 'RequestData', null)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Server/Helper.php",
"line": 302,
"call": "GraphQL\\GraphQL::promiseToExecute(instance of GraphQL\\Executor\\Promise\\Adapter\\SyncPromiseAdapter, instance of WPGraphQL\\WPSchema, instance of GraphQL\\Language\\AST\\DocumentNode, null, instance of WPGraphQL\\AppContext, array(1), 'RequestData', null, array(29))"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Server/Helper.php",
"line": 211,
"call": "GraphQL\\Server\\Helper::promiseToExecuteOperation(instance of GraphQL\\Executor\\Promise\\Adapter\\SyncPromiseAdapter, instance of GraphQL\\Server\\ServerConfig, instance of GraphQL\\Server\\OperationParams)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Server/StandardServer.php",
"line": 136,
"call": "GraphQL\\Server\\Helper::executeOperation(instance of GraphQL\\Server\\ServerConfig, instance of GraphQL\\Server\\OperationParams)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/src/Request.php",
"line": 703,
"call": "GraphQL\\Server\\StandardServer::executeRequest(instance of GraphQL\\Server\\OperationParams)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/src/Router.php",
"line": 466,
"call": "WPGraphQL\\Request::execute_http()"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/src/Router.php",
"line": 258,
"call": "WPGraphQL\\Router::process_http_request()"
},
{
"file": "/var/www/wp-includes/class-wp-hook.php",
"line": 324,
"call": "WPGraphQL\\Router::resolve_http_request(instance of WP)"
},
{
"file": "/var/www/wp-includes/class-wp-hook.php",
"line": 348,
"call": "WP_Hook::apply_filters(null, array(1))"
},
{
"file": "/var/www/wp-includes/plugin.php",
"line": 565,
"call": "WP_Hook::do_action(array(1))"
},
{
"file": "/var/www/wp-includes/class-wp.php",
"line": 418,
"function": "do_action_ref_array('parse_request', array(1))"
},
{
"file": "/var/www/wp-includes/class-wp.php",
"line": 813,
"call": "WP::parse_request((empty string))"
},
{
"file": "/var/www/wp-includes/functions.php",
"line": 1336,
"call": "WP::main((empty string))"
},
{
"file": "/var/www/wp-blog-header.php",
"line": 16,
"function": "wp()"
},
{
"file": "/var/www/index.php",
"line": 17,
"function": "require('/var/www/wp-blog-header.php')"
}
]
},
{
"debugMessage": "Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource::Vox_Media\\Vox_Media_Theme\\Components\\Packages\\{closure}(): Argument #1 ($post) must be of type WP_Post, bool given",
"message": "Internal server error",
"extensions": {
"category": "internal"
},
"locations": [
{
"line": 423,
"column": 2
}
],
"path": [
"node",
"hero"
],
"trace": [
{
"file": "/var/www/wp-content/themes/vox-media-theme/php/components/packages/class-package-resource.php",
"line": 239,
"function": "array_map(instance of Closure, array(1))"
},
{
"file": "/var/www/wp-content/themes/vox-media-theme/php/components/packages/class-package-resources-retriever.php",
"line": 99,
"call": "Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource::get_posts('hero_ids')"
},
{
"file": "/var/www/wp-content/themes/vox-media-theme/php/components/packages/class-package-graphql-extensions.php",
"line": 325,
"call": "Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resources_Retriever::get_resources()"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/src/Utils/InstrumentSchema.php",
"line": 145,
"call": "Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_GraphQL_Extensions::Vox_Media\\Vox_Media_Theme\\Components\\Packages\\{closure}(instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource, array(0), instance of WPGraphQL\\AppContext, instance of GraphQL\\Type\\Definition\\ResolveInfo)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 623,
"call": "WPGraphQL\\Utils\\InstrumentSchema::WPGraphQL\\Utils\\{closure}(instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource, array(0), instance of WPGraphQL\\AppContext, instance of GraphQL\\Type\\Definition\\ResolveInfo)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 549,
"call": "GraphQL\\Executor\\ReferenceExecutor::resolveFieldValueOrError(instance of GraphQL\\Type\\Definition\\FieldDefinition, instance of GraphQL\\Language\\AST\\FieldNode, instance of Closure, instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource, instance of GraphQL\\Type\\Definition\\ResolveInfo)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 1195,
"call": "GraphQL\\Executor\\ReferenceExecutor::resolveField(GraphQLType: PackageResourceType, instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource, instance of ArrayObject(1), array(2))"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 1145,
"call": "GraphQL\\Executor\\ReferenceExecutor::executeFields(GraphQLType: PackageResourceType, instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource, array(1), instance of ArrayObject(35))"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 1105,
"call": "GraphQL\\Executor\\ReferenceExecutor::collectAndExecuteSubfields(GraphQLType: PackageResourceType, instance of ArrayObject(1), array(1), instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 973,
"call": "GraphQL\\Executor\\ReferenceExecutor::completeObjectValue(GraphQLType: PackageResourceType, instance of ArrayObject(1), instance of GraphQL\\Type\\Definition\\ResolveInfo, array(1), instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 789,
"call": "GraphQL\\Executor\\ReferenceExecutor::completeAbstractValue(GraphQLType: Node, instance of ArrayObject(1), instance of GraphQL\\Type\\Definition\\ResolveInfo, array(1), instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/ReferenceExecutor.php",
"line": 651,
"call": "GraphQL\\Executor\\ReferenceExecutor::completeValue(GraphQLType: Node, instance of ArrayObject(1), instance of GraphQL\\Type\\Definition\\ResolveInfo, array(1), instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/Promise/Adapter/SyncPromise.php",
"line": 148,
"call": "GraphQL\\Executor\\ReferenceExecutor::GraphQL\\Executor\\{closure}(instance of Vox_Media\\Vox_Media_Theme\\Components\\Packages\\Package_Resource)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/Promise/Adapter/SyncPromise.php",
"line": 53,
"call": "GraphQL\\Executor\\Promise\\Adapter\\SyncPromise::GraphQL\\Executor\\Promise\\Adapter\\{closure}()"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Executor/Promise/Adapter/SyncPromiseAdapter.php",
"line": 149,
"call": "GraphQL\\Executor\\Promise\\Adapter\\SyncPromise::runQueue()"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Server/Helper.php",
"line": 214,
"call": "GraphQL\\Executor\\Promise\\Adapter\\SyncPromiseAdapter::wait(instance of GraphQL\\Executor\\Promise\\Promise)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/vendor/webonyx/graphql-php/src/Server/StandardServer.php",
"line": 136,
"call": "GraphQL\\Server\\Helper::executeOperation(instance of GraphQL\\Server\\ServerConfig, instance of GraphQL\\Server\\OperationParams)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/src/Request.php",
"line": 703,
"call": "GraphQL\\Server\\StandardServer::executeRequest(instance of GraphQL\\Server\\OperationParams)"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/src/Router.php",
"line": 466,
"call": "WPGraphQL\\Request::execute_http()"
},
{
"file": "/var/www/wp-content/plugins/wp-graphql/src/Router.php",
"line": 258,
"call": "WPGraphQL\\Router::process_http_request()"
},
{
"file": "/var/www/wp-includes/class-wp-hook.php",
"line": 324,
"call": "WPGraphQL\\Router::resolve_http_request(instance of WP)"
},
{
"file": "/var/www/wp-includes/class-wp-hook.php",
"line": 348,
"call": "WP_Hook::apply_filters(null, array(1))"
},
{
"file": "/var/www/wp-includes/plugin.php",
"line": 565,
"call": "WP_Hook::do_action(array(1))"
},
{
"file": "/var/www/wp-includes/class-wp.php",
"line": 418,
"function": "do_action_ref_array('parse_request', array(1))"
},
{
"file": "/var/www/wp-includes/class-wp.php",
"line": 813,
"call": "WP::parse_request((empty string))"
},
{
"file": "/var/www/wp-includes/functions.php",
"line": 1336,
"call": "WP::main((empty string))"
},
{
"file": "/var/www/wp-blog-header.php",
"line": 16,
"function": "wp()"
},
{
"file": "/var/www/index.php",
"line": 17,
"function": "require('/var/www/wp-blog-header.php')"
}
]
}
],
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment