[ 
https://jira.nuxeo.com/browse/CMIS-53?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=95791#comment-95791
 ] 

Florent Guillaume edited comment on CMIS-53 at 6/3/11 6:15 PM:
---------------------------------------------------------------

It's incorrect to construct a path by adding a cmis:name at the end of a 
parent's path. The cmis:name is distinct from the relative path segment, which 
should be used instead to construct paths.


      was (Author: fguillaume):
    It's incorrect to construct a path by adding a cmis:name at the end of a 
parent's path. The cmis:name is distinct from the relative path segment and 
should be used instead.

  
> Can't create documents with long names (> 24 chars)
> ---------------------------------------------------
>
>                 Key: CMIS-53
>                 URL: https://jira.nuxeo.com/browse/CMIS-53
>             Project: Nuxeo Chemistry
>          Issue Type: Bug
>    Affects Versions: nuxeo-5.4.2
>            Reporter: Stéfane Fermigier
>            Assignee: Florent Guillaume
>
> Use this python script to reproduce the issue:
> {code}
> import time, sys
> from StringIO import StringIO
> from cmislib.model import CmisClient
> REPOSITORY_URL = "http://localhost:8080/nuxeo/atom/cmis";
> REMOTE_PATH = "/default-domain/workspaces/test"
> USERNAME = PASSWORD = "Administrator"
> client = CmisClient(REPOSITORY_URL, USERNAME, PASSWORD)
> repo = client.getDefaultRepository()
> folder = repo.getObjectByPath(REMOTE_PATH)
> name = "123456789012345678901234567890.txt"
> content = "Some random content"
> content_file = StringIO(content)
> folder.createDocument(name, contentFile=content_file)
> children = folder.getChildren()
> for child in children:
>     print child.getName()
> doc = repo.getObjectByPath(REMOTE_PATH + "/" + name)
> assert content == doc.getContentStream().read()
> print doc.getName()
> doc.delete()
> {code}

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

       
_______________________________________________
ECM-tickets mailing list
[email protected]
http://lists.nuxeo.com/mailman/listinfo/ecm-tickets

Reply via email to