Skip to content

A parameter type that takes an "equals" does not work. #2

@Firstyear

Description

@Firstyear

I have the following code.

def ui_command_test(self, ldapurl, binddn):
    print(ldapurl)
    print(binddn)

Given this command line:

/> help test

SYNTAX
======
test ldapurl binddn 

/> test ldapurl=ldap://localhost binddn="cn=Directory Manager"
ldap://localhost


Note the "blank" output for binddn. This is due to the quoting of the value.

If we remove the quotes

/> test ldapurl=ldap://localhost binddn=cn=Directory Manager
ldap://localhost
cn

The final = is then turned into another parameter, and we drop part of the value.

Additionally, escaping does not function.

/> test ldapurl=ldap://localhost binddn=cn\=Directory Manager
ldap://localhost
cn\

So this doesn't help either.

It would be great if values could be quoted, and the internal content of the quotes taken as a whole string regardless of whitespace or char presence until the next matching quote.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions