question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

TypeError: Cannot read property 'operation' of undefined and relative path bug

See original GitHub issue

Hello,

With this swagger.json : https://gist.github.com/julienkosinski/c0872ed8df120b631c1146adc5d78220.js

With 3.0.12 : When trying to send a request to the API (POST for example), I have this error :

swagger-ui-bundle.js:68397 Uncaught TypeError: Cannot read property 'operation' of undefined at Object.i [as buildRequest] (swagger-ui-bundle.js:68397) at swagger-ui-bundle.js:26026 at swagger-ui-bundle.js:15207 at swagger-ui-bundle.js:9555 at swagger-ui-bundle.js:38005 at Object.r [as executeRequest] (swagger-ui-bundle.js:6562) at swagger-ui-bundle.js:26026 at swagger-ui-bundle.js:15207 at swagger-ui-bundle.js:9555 at swagger-ui-bundle.js:71635

With 3.0.4 : It’s working but I need to specify the host (like "host": "127.0.0.1:8080") because relative path isn’t working.

Plus, I need to have #2923 fixed for my complete spec.

Thanks 😃.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:13 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
domeniconappocommented, Oct 12, 2017

@shockey , Thank you for trying. Sorry, my bad. Just tested again and it works. Yesterday I was testing 3.0.12 and then switched to latest version but probably Chrome’s aggressive chaching policy had confused me a bit…

0reactions
shockeycommented, Oct 11, 2017

@domeniconappo, I just tested an operation with an operationId defined (one of the Petstore operations) and it worked fine with Swagger-UI 3.3.1 and Chrome 61.

Can you open a new issue and follow the issue template, so we can reproduce the problem you’re having? Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Unhandled Runtime Error TypeError: Cannot read properties ...
javascript - Unhandled Runtime Error TypeError: Cannot read properties of undefined (reading 'call') when I try to use the Image component of ...
Read more >
'TypeError: Cannot read property 'components' of ... - TI E2E
TMS320F28379D: 'TypeError: Cannot read property 'components' of undefined' when using .syscfg to add a GPIO target board LAUNCCXL-F28379.
Read more >
Can't load gltf models with relative path - Bugs - Babylon.js
It throws: TypeError: Cannot read properties of undefined (reading 'asset') at e._getLoader . and from GLTFFileLoader.ts , e == loader . Edit # ......
Read more >
How to prevent cannot read property split of undefined
The error "Cannot read property split of undefined" can occur when performing any of these types of operations if the variable is undefined....
Read more >
error typeerror: cannot read properties of undefined ... - You.com
It is because there is no res object in the getAllUsers function. You need to create a mock response and request and pass...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found