Closed (fixed)
Project:
Deploy - Content Staging
Version:
7.x-2.x-dev
Component:
Code
Priority:
Minor
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
1 Apr 2012 at 14:31 UTC
Updated:
1 May 2012 at 10:40 UTC
When attempting to deploy a Basic Page node errors are logged in the following order:
Notice: Undefined property: stdClass::$nid in node_access() (line 2847 of /.../modules/node/node.module).
Notice: Undefined index: CONTENT_TYPE in RESTServer->parseRequest() (line 249 of /.../modules/services/servers/rest_server/includes/RESTServer.inc).
Not sure if the content is deployed correctly. The content seems to appear correctly, and no errors are reported by the source server.
Comments
Comment #1
Rory commentedThinking this could be an issue integrating changes with the other modules involved.
Comment #2
aspilicious commentedAre you on latest dev (uuid, services and deploy?)
The second notice is not that bad, deploy works with that one.
Did you install UUID services on both sides?
Comment #3
wOOge commentedI'm having the same issue — using the latest dev of
uuid,servicesanddeploy, on a clean install of drupal 7.12 — just have one content type, same on both sites, and it's a basic, basic content type, with title, body (long text + split).Using the example endpoints and plans, with the appropriate credentials input into the endpoint — Deploy tells me it's succeeded but I get the original poster's error on the
endpointlogs.let me know if you need any more info to help diagnose.
Comment #4
stongo commentedI'm getting the exact same error on the destination server. Using newest dev versions of UUID, Deploy and Services. I am also pushing a node that is of the default Basic Page content type. The source server logs the deployment as a success in watchdog.
Comment #5
aspilicious commentedI also get these errors, but they are services related, so it's no problem.
Comment #6
stongo commentedI don't think Deploy is setting the correct headers, according to a similar issue from the Services issue queue.
http://drupal.org/node/1348766
Comment #7
aspilicious commentedOk I'll investigate this when I find some time :)
Comment #8
stongo commentedaspilicious, I have some cycles I can put in to investigating this, if you can point me roughly in the right direction to start digging through the code.
Comment #9
aspilicious commentedIn deploy => plugins => DeployServiceRestJSON.inc the content_type got set.
$this->config['headers']['Content-Type'] = 'application/json';
I wonder why that is put inside the foreach...
Should also work outside of it, normaly...
Maybe it has to be contentType or CONTENT_TYPE or Content_Type...
You should try one of those.
Comment #10
stongo commentedI was able to fix the undefined index notice in watchdog by tracing it back to my apache config.
I added this to my httpd.conf:
And this to the source/destination .htaccess files within
<IfModule mod_rewrite.c>:The bad news is that nodes still aren't being created on the destination server.
In watchdog, it seems like Deploy is logging in and then logging out without doing anything else.
Comment #11
aspilicious commentedMarking this fixed now