Skip to content

Instantly share code, notes, and snippets.

// .../pharmakonRequests/index.js
export const getS2LOrder: (client: Client, pkReq: PKS2LOrderRequest) => Promise<PKS2LOrderResponse>
// Note this particular example is contrived, insofar as we know that `pkReq` is just an
// Order ID -
// * its type would just be `string | number`, not the fancy name used above
// * it doesn't need a (request-side) transformation - if it has it would just be `identity`
// function
const ax = require('axios')
const f = require('./requesterFunction')
const input = {
type: 'Dish',
id: 'f9abece6-10d6-4f49-8297-ae2fe6e07550',
data: {
name: 'cheese slice',
size: 'yield sign',
price: '5.50'
{
"data": {
"relationships": {
"prescription": {
"data": {
"type": "Prescription",
"id": "1331017"
}
}
},
{
"data": [
{
"type": "DispatchPoint",
"id": "-1",
"attributes": {
"updated_at": "2019-07-08T19:00:35.624363Z",
"display_name": "DummyDispatchPoint",
"facility": 1
},
{
"type": "Error",
"exception": {
"message": "Failed step: UpdateDeliveryWindow",
"stackTrace": [
{
"className": "orchestrator.Orchestrator",
"fileName": "Orchestrator.kt",
"lineNumber": 402,
"methodName": "pipeline",
declare namespace lafs_gui_signon {
interface UserIdent {
id: number;
}
/** checkUserCredentials
*
* Resolve with a `UserIdent` value if the supplied `username` and `password` are valid
[NodeError] The value of "offset" is out of range. It must be >= 0 and <= 610557. Received 610558
at boundsError internal/buffer.js:81
at readUInt8 internal/buffer.js:247
at nextUInt8 exif-parser/lib/bufferstream.js:14 var value = this.buffer.readUInt8(this.offset);
at readExifValue exif-parser/lib/exif.js:5 case 1: return stream.nextUInt8();
at readExifTag exif-parser/lib/exif.js:73 values.push(readExifValue(format, stream));
at readIFDSection exif-parser/lib/exif.js:88 tag = readExifTag(tiffMarker, stream);
at parseTags exif-parser/lib/exif.js:145 readIFDSection(tiffMarker,
@cmonacaps
cmonacaps / addendum.md
Last active April 23, 2020 19:15
different ways to import, to arrive at "addTwo is not a function" ... also, obviously I should have been mocking `_utils4`

for the entire run, this was true: util.js

const getNextTaskPreviewForUser = (...
const getNextAssignedTaskPreview = ( ...
const addTwo = (x, y) => {
  console.log('real addTwo');
  return x + y;
};
@cmonacaps
cmonacaps / App.jsx
Last active April 18, 2020 14:36
exception presentation fails when actual error is lost, possibly during threadsjs post-error-to-window
const App = () => (
<Worker>
{props => (
<ErrorBoundary {...props}>
<Juicy>
<ApplicationComponents />
</Juicy>
</ErrorBoundary>
)}
</Worker>
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.