Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

object(xxxx:array(),xxxxx:array()) throws exception #12

Closed
ObliviousHarmony opened this issue Dec 16, 2016 · 4 comments
Closed

object(xxxx:array(),xxxxx:array()) throws exception #12

ObliviousHarmony opened this issue Dec 16, 2016 · 4 comments
Assignees
Labels

Comments

@ObliviousHarmony
Copy link

Hello,

The string "@rest\response 200 object(modifications:array(ModificationHistory),users:array(User))" throws an exception.

Call Stack:

SwaggerGen\Exception: Unparseable string definition: 'ModificationHistory),users:array(User' in C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Type\ReferenceObjectType.php:24
Stack trace:
#0 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Type\AbstractType.php(37): SwaggerGen\Swagger\Type\ReferenceObjectType->parseDefinition('ModificationHis...')
#1 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Type\ArrayType.php(188): SwaggerGen\Swagger\Type\AbstractType->__construct(Object(SwaggerGen\Swagger\Type\ArrayType), 'ModificationHis...')
#2 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Type\ArrayType.php(93): SwaggerGen\Swagger\Type\ArrayType->validateItems('ModificationHis...')
#3 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Type\ArrayType.php(69): SwaggerGen\Swagger\Type\ArrayType->parseItems('array(Modificat...', Array)
#4 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Type\AbstractType.php(37): SwaggerGen\Swagger\Type\ArrayType->parseDefinition('array(Modificat...')
#5 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Type\Property.php(77): SwaggerGen\Swagger\Type\AbstractType->__construct(Object(SwaggerGen\Swagger\Type\Property), 'array(Modificat...')
#6 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Type\ObjectType.php(61): SwaggerGen\Swagger\Type\Property->__construct(Object(SwaggerGen\Swagger\Type\ObjectType), 'array(Modificat...')
#7 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Type\ObjectType.php(42): SwaggerGen\Swagger\Type\ObjectType->parseProperties('object(modifica...', Array)
#8 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Type\AbstractType.php(37): SwaggerGen\Swagger\Type\ObjectType->parseDefinition('object(modifica...')
#9 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Schema.php(76): SwaggerGen\Swagger\Type\AbstractType->__construct(Object(SwaggerGen\Swagger\Schema), 'object(modifica...')
#10 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Response.php(113): SwaggerGen\Swagger\Schema->__construct(Object(SwaggerGen\Swagger\Response), 'object(modifica...')
#11 C:\Application\vendor\vanderlee\swaggergen\SwaggerGen\Swagger\Operation.php(142): SwaggerGen\Swagger\Response->__construct(Object(SwaggerGen\Swagger\Operation), 200, 'object(modifica...', '')
@vanderlee
Copy link
Owner

The issue is confirmed on the latest version.
Thanks for reporting it.
It'll hopefully be fixed shortly.

@vanderlee vanderlee self-assigned this Dec 17, 2016
@vanderlee vanderlee added the bug label Dec 17, 2016
@ObliviousHarmony
Copy link
Author

ObliviousHarmony commented Dec 17, 2016 via email

@vanderlee
Copy link
Owner

Should be fixed now in 2.3.10.

Please test and verify it works for you now.

Case is explicitely tested in test case tests/issues/Issue0012Test.php and more thoroughly tested in the regular testsuite.

@ObliviousHarmony
Copy link
Author

It works as expected now, thanks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants