Sub-environment variables don't work with gRPC
See original GitHub issueDescribe the bug
I recently discovered that the latest version of Insomnia supports environment variables; however I am unable to get this to work. When I put in an environment variable of 127.0.0.1:6565
and attempt to use this, nothing happens in the UI (there are errors in the dev console). If I directly paste 127.0.0.1:6565
in, it works as expected (old behavior). I have tried downgrading to 2020.1.0 but that doesn’t fix the issue either.
To Reproduce In the environment tab, add a new variable. Fill that variable in and make a gRPC request.
Expected behavior The request should be successful, but it is not
Screenshots (These are intentionally cropped)
Desktop (please complete the following information): Version: Insomnia 2021.1.1 Release date: 3/9/2021 OS: Darwin x64 19.6.0 Electron: 9.1.1 Node: 12.14.1 V8: 8.3.110.13-electron.0 Architecture: x64 node-libcurl: libcurl/7.69.1 OpenSSL/1.1.1g zlib/1.2.11 brotli/1.0.7 libidn2/2.1.1 libssh2/1.9.0 nghttp2/1.41.0
Additional context Error message:
18:24:20.309 › Unhandled Promise PromiseRejectionEvent {isTrusted: true, promise: Promise, reason: Error: attempted to output null or undefined value
at file:///Applications/Insomnia.app/Content…, type: "unhandledrejection", target: global, …}bubbles: falsecancelBubble: falsecancelable: truecomposed: falsecurrentTarget: global {parent: global, opener: null, top: global, length: 0, frames: global, …}defaultPrevented: falseeventPhase: 0isTrusted: truepath: [global]promise: Promise__proto__: Promise[[PromiseStatus]]: "rejected"[[PromiseValue]]: Error: attempted to output null or undefined value
at file:///Applications/Insomnia.app/Contents/Resources/app.asar/bundle.js:37548:26
at /Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/nunjucks/src/environment.js:41:5
at RawTask.call (/Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/asap/asap.js:40:19)
at flush (/Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/asap/raw.js:50:29)
at processTicksAndRejections (internal/process/task_queues.js:76:11)location: {line: 1, column: 1}path: "url"reason: "undefined"type: "render"message: "attempted to output null or undefined value"stack: "Error: attempted to output null or undefined value↵ at file:///Applications/Insomnia.app/Contents/Resources/app.asar/bundle.js:37548:26↵ at /Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/nunjucks/src/environment.js:41:5↵ at RawTask.call (/Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/asap/asap.js:40:19)↵ at flush (/Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/asap/raw.js:50:29)↵ at processTicksAndRejections (internal/process/task_queues.js:76:11)"__proto__: Errorreason: Error: attempted to output null or undefined value
at file:///Applications/Insomnia.app/Contents/Resources/app.asar/bundle.js:37548:26
at /Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/nunjucks/src/environment.js:41:5
at RawTask.call (/Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/asap/asap.js:40:19)
at flush (/Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/asap/raw.js:50:29)
at processTicksAndRejections (internal/process/task_queues.js:76:11)returnValue: truesrcElement: global {parent: global, opener: null, top: global, length: 0, frames: global, …}target: global {parent: global, opener: null, top: global, length: 0, frames: global, …}timeStamp: 595062.414999993type: "unhandledrejection"__proto__: PromiseRejectionEvent
setTimeout (async)
consoleLog @ /Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/electron-log/src/transports/console.js:93
transport @ /Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/electron-log/src/transports/console.js:46
runTransport @ /Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/electron-log/src/log.js:44
runTransports @ /Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/electron-log/src/log.js:27
log @ /Applications/Insomnia.app/Contents/Resources/app.asar/node_modules/electron-log/src/log.js:21
Issue Analytics
- State:
- Created 2 years ago
- Reactions:2
- Comments:9 (3 by maintainers)
Top GitHub Comments
I misread your post. It seems that this isn’t a work around (always resolves the base). Hopefully this is not too hard of an issue to address. I’m a big fan of the recent gRPC support nonetheless!
I have faced the same issue with Insomnia regarding env