Union type for error disappears in typescript-fetch v0.10

Description
The union type for the error object returned by fetch has changed in typescript-fetch v0.10 and later versions.
Reproduction
I updated typescript-fetch to v0.10.1.
After the update, the type inference for the error object returned by fetch changed as follows:
Before v0.9.7

const error: { message: string } | Record<string, never> | undefined

v0.10.0 and Later

const error: { message: string } | undefined

OpenAPI YAML
I change the error response based on the type of error. For example, in the case of a 404 error, only a message is returned. For a 422 error, error messages are returned for each field.
# Partial YAML
      responses:
        '404':
          description: NotFound
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                required:
                  - message
        '422':
          description: Bad parameters
          content:
            application/json:
              schema:
                title: ''
                type: object
                properties:
                  errors:
                    type: object
                    properties: {}
                required:
                  - errors

Expected result
It would be great if the error type could be the same as in previous versions:
const error: { message: string } | Record<string, never> | undefined
Checklist

[ ] I’m willing to open a PR (see CONTRIBUTING.md)

This was an intentional change in 0.10.0 that stemmed from some changes in how the error union was formed.
It’s now an approach for errors where it’s “take the first you find” because many schemas have a single defined error type, and some other responses being null or an impossible union. That seemed to be a more common pattern than different response codes returning a completely different error shape. i.e. many error responses are unintentional/accidental,
data was kept as a union because typically those are more intentional by comparison, and the union is something handled.
Unfortunately there’s not really a way to make both behaviors work—either keeping the error union results in many schemas being unusable because of irreconcilable unions. Or keeping this “take the first match” behavior results in some error types being left out. But this change felt safer because the worst case scenario is “represent one shape correctly” rather than “misrepresent all shapes incorrectly.”
Removed the bug label, but happy to gather feedback from people, or possible solutions that make both scenarios easier for people. At its root it’s just multiple conflicting approaches to schema design, neither being “right” or “wrong.”

Would this change effect non-errors? I tried upgrading today and noticed a similar problem.  We have an API endpoint that takes a PATCH.
On updates it returns an empty 202.
However, if a 'complete' property is sent as true, then it returns a 200 with a body of a particular shape.
I found that the data property of this response was set to never.  Even if I were to check the response status to differentiate between 200 and 202, it was still never.
eg: this didn't work
if (response.status === 200) {
  console.log(response.data.something)  // ts error on something
}

This change seems to pretty badly break typing in my case.  This is a typical flow in my code:
  const client = createClient<paths>({ baseUrl: "..." });
  const { data, error } = await client.GET("/path");
  if (error) {
   // handle error
  }
  // handle data, which is now guaranteed to be the 200 case

As of v0.10, error above is now always undefined in the typing.  However, that's not true, at runtime it still behaves as in v0.9.7.  So the typing is apparently just wrong now.
Another note, in v0.10, if there is an error then response is typed as never, which is not right.  At runtime, response is a normal object and I can use response.status in the error handling, for instance.
At this point, I cannot upgrade, frankly, because the typing is totally wonky.

Came here for the same reason as @markedwards, error is now always undefined, especially as the first error being matches is always a 5XX, which usually do not have a useful body, while 4XX have like validation errors or similar structures.
There should be a way to have a proper union of returned responses for either, data and error.
Might be worth returning a status directly on the FetchResponse type to do so.

Is it possible to get some confirmation that this issue indeed needs to be fixed, or if this is the intended behavior moving forward?

@drwpow Do you have examples of impossible unions? Apart from "hello" | string collapsing to just string, I cannot think of real-world examples. It looks like the changes in v0.10 originated from unions with empty responses (#1609), which caused troubles.
I am super curious about this because I managed to create unions of all possible success and error responses bodies in OpenAPI-MSW without known edge cases (source code).
Further, I added a response helper, which allows constructing responses according the API-Specs, which feels much nicer than dealing with the union from a DX point of view.
When creating an extensive example with multiple error and success codes and content-types, I also noticed problems of loosing inference/discrimination on the discriminated data-error union in OpenAPI-Fetch, which others have already described as well. This leads to an unpleasant DX for some OpenAPI specs.
I think the best solution that solves everyones problems is some sort of response helper, which can avoid dealing with unions. Just like OpenAPI-MSW's helper but for handling responses instead of constructing them. My rough idea is something like pattern matching, where status code and content-type are mapped to response handlers.
const client = createClient<paths>();
const response = await client.GET("/some/path");
return handleResponse(response, {
  // provided data would be typed according to the 200 application/json body.
  // I can also imagine just providing a response and the consumer calls `res.json()`,
  // as long as it can be type-safe.
  "200/json": (data) => return data,
  "404/empty": () => throw new Error("Not found.")
  "400/text": (text) => throw new Error("Invalid: " + text)
})

I think the code example would not have proper type inference but it provides a rough idea of what I mean with a response helper for handling responses. It would also allow us to delay parsing the response body, so consumers that are not interested in the response result don't have to parse the body in the first place.
Are you interested in collaborating on this problem and finding a solution for it? @luchsamapparat and I are really interested in solving this.

@drwpow any guidance here?  openapi-fetch is totally useless to us as of 0.10.  The typing is completely broken.  Is there any interest in addressing this, or should I start investigating alternatives?
Thanks.

@christoph-fricke I love that approach, and I would gladly welcome solving it from that angle! Thanks for putting so much time and thought into it.
Current lift events have prevented me from spending time on this library myself past few weeks, but I’d gladly approve and ship PRs that tackle the solution in the manner outlined

Hey :wave:
I have a proposition type for keeping error types without them intersecting and overriding each other, similar to how @christoph-fricke wanted to have a helper function.
ErrorReturn needs to be fed paths, the path literal, and the method literal and it will spit out a descriminated union without swallowing any overlapping responses !

No swallow

If this is an approach that is alright for you I can make a PR :smile:
If I missed something please let me know !
type ErrorReturn<
  KP extends keyof paths,
  M extends 'put' | 'get' | 'delete' | 'post',
  Response extends {
    put?: any;
    post?: any;
    delete?: any;
    get?: any;
  } = paths[KP],
  G extends Expand<{
    [Code in keyof Response[M]['responses']]: Response[M]['responses'][Code]['content'];
  }> = Expand<{
    [Code in keyof Response[M]['responses']]: Response[M]['responses'][Code]['content'];
  }>,
> = G;

type ErrorShape = Record<number | string, { [resType: string]: any }>;

type AddMissingKeys<T extends ErrorShape> = Prettify<
  { [K in Exclude<ErrorStatusTuple[number], keyof T>]: {} } & T
>;

// infer prevents "swallowing"
export type Expand<
  T extends ErrorShape,
  G = AddMissingKeys<T> extends {
    'default': infer XX;
    499: infer WW;
    498: infer VV;
    497: infer UU;
    451: infer TT;
    450: infer SS;
    444: infer RR;
    431: infer QQ;
    430: infer PP;
    429: infer OO;
    428: infer NN;
    427: infer MM;
    426: infer LL;
    425: infer KK;
    424: infer JJ;
    423: infer II;
    422: infer HH;
    421: infer GG;
    420: infer FF;
    418: infer EE;
    417: infer DD;
    416: infer CC;
    415: infer BB;
    414: infer AA;
    413: infer Z;
    412: infer Y;
    411: infer X;
    410: infer W;
    409: infer V;
    408: infer U;
    407: infer T;
    406: infer S;
    405: infer R;
    404: infer Q;
    403: infer p;
    402: infer O;
    401: infer N;
    400: infer M;
    511: infer L;
    510: infer K;
    508: infer J;
    507: infer H;
    506: infer G;
    505: infer F;
    504: infer E;
    503: infer D;
    502: infer C;
    '4xx': infer B;
    '5xx': infer A;
  }
    ?
        | {
            [P in keyof C]: Prettify<
              C[P] & { code: ErrorKey<Stringulator<P>, '502'> }
            >;
          }[keyof C]
        | {
            [P in keyof D]: Prettify<
              D[P] & { code: ErrorKey<Stringulator<P>, '503'> }
            >;
          }[keyof D]
        | {
            [P in keyof E]: Prettify<
              E[P] & { code: ErrorKey<Stringulator<P>, '504'> }
            >;
          }[keyof E]
        | {
            [P in keyof F]: Prettify<
              F[P] & { code: ErrorKey<Stringulator<P>, '505'> }
            >;
          }[keyof F]
        | {
            [P in keyof G]: Prettify<
              G[P] & { code: ErrorKey<Stringulator<P>, '506'> }
            >;
          }[keyof G]
        | {
            [P in keyof H]: Prettify<
              H[P] & { code: ErrorKey<Stringulator<P>, '507'> }
            >;
          }[keyof H]
        | {
            [P in keyof J]: Prettify<
              J[P] & { code: ErrorKey<Stringulator<P>, '508'> }
            >;
          }[keyof J]
        | {
            [P in keyof K]: Prettify<
              K[P] & { code: ErrorKey<Stringulator<P>, '510'> }
            >;
          }[keyof K]
        | {
            [P in keyof L]: Prettify<
              L[P] & { code: ErrorKey<Stringulator<P>, '511'> }
            >;
          }[keyof L]
        | {
            [P in keyof M]: Prettify<
              M[P] & { code: ErrorKey<Stringulator<P>, '400'> }
            >;
          }[keyof M]
        | {
            [P in keyof N]: Prettify<
              N[P] & { code: ErrorKey<Stringulator<P>, '401'> }
            >;
          }[keyof N]
        | {
            [P in keyof O]: Prettify<
              O[P] & { code: ErrorKey<Stringulator<P>, '402'> }
            >;
          }[keyof O]
        | {
            [P in keyof p]: Prettify<
              p[P] & { code: ErrorKey<Stringulator<P>, '403'> }
            >;
          }[keyof p]
        | {
            [P in keyof Q]: Prettify<
              Q[P] & { code: ErrorKey<Stringulator<P>, '404'> }
            >;
          }[keyof Q]
        | {
            [P in keyof R]: Prettify<
              R[P] & { code: ErrorKey<Stringulator<P>, '405'> }
            >;
          }[keyof R]
        | {
            [P in keyof S]: Prettify<
              S[P] & { code: ErrorKey<Stringulator<P>, '406'> }
            >;
          }[keyof S]
        | {
            [P in keyof T]: Prettify<
              T[P] & { code: ErrorKey<Stringulator<P>, '407'> }
            >;
          }[keyof T]
        | {
            [P in keyof U]: Prettify<
              U[P] & { code: ErrorKey<Stringulator<P>, '408'> }
            >;
          }[keyof U]
        | {
            [P in keyof V]: Prettify<
              V[P] & { code: ErrorKey<Stringulator<P>, '409'> }
            >;
          }[keyof V]
        | {
            [P in keyof W]: Prettify<
              W[P] & { code: ErrorKey<Stringulator<P>, '410'> }
            >;
          }[keyof W]
        | {
            [P in keyof X]: Prettify<
              X[P] & { code: ErrorKey<Stringulator<P>, '411'> }
            >;
          }[keyof X]
        | {
            [P in keyof Y]: Prettify<
              Y[P] & { code: ErrorKey<Stringulator<P>, '412'> }
            >;
          }[keyof Y]
        | {
            [P in keyof Z]: Prettify<
              Z[P] & { code: ErrorKey<Stringulator<P>, '413'> }
            >;
          }[keyof Z]
        | {
            [P in keyof AA]: Prettify<
              AA[P] & { code: ErrorKey<Stringulator<P>, '414'> }
            >;
          }[keyof AA]
        | {
            [P in keyof BB]: Prettify<
              BB[P] & { code: ErrorKey<Stringulator<P>, '415'> }
            >;
          }[keyof BB]
        | {
            [P in keyof CC]: Prettify<
              CC[P] & { code: ErrorKey<Stringulator<P>, '416'> }
            >;
          }[keyof CC]
        | {
            [P in keyof DD]: Prettify<
              DD[P] & { code: ErrorKey<Stringulator<P>, '417'> }
            >;
          }[keyof DD]
        | {
            [P in keyof EE]: Prettify<
              EE[P] & { code: ErrorKey<Stringulator<P>, '418'> }
            >;
          }[keyof EE]
        | {
            [P in keyof FF]: Prettify<
              FF[P] & { code: ErrorKey<Stringulator<P>, '420'> }
            >;
          }[keyof FF]
        | {
            [P in keyof GG]: Prettify<
              GG[P] & { code: ErrorKey<Stringulator<P>, '421'> }
            >;
          }[keyof GG]
        | {
            [P in keyof HH]: Prettify<
              HH[P] & { code: ErrorKey<Stringulator<P>, '422'> }
            >;
          }[keyof HH]
        | {
            [P in keyof II]: Prettify<
              II[P] & { code: ErrorKey<Stringulator<P>, '423'> }
            >;
          }[keyof II]
        | {
            [P in keyof JJ]: Prettify<
              JJ[P] & { code: ErrorKey<Stringulator<P>, '424'> }
            >;
          }[keyof JJ]
        | {
            [P in keyof KK]: Prettify<
              KK[P] & { code: ErrorKey<Stringulator<P>, '425'> }
            >;
          }[keyof KK]
        | {
            [P in keyof LL]: Prettify<
              LL[P] & { code: ErrorKey<Stringulator<P>, '426'> }
            >;
          }[keyof LL]
        | {
            [P in keyof MM]: Prettify<
              MM[P] & { code: ErrorKey<Stringulator<P>, '427'> }
            >;
          }[keyof MM]
        | {
            [P in keyof NN]: Prettify<
              NN[P] & { code: ErrorKey<Stringulator<P>, '428'> }
            >;
          }[keyof NN]
        | {
            [P in keyof OO]: Prettify<
              OO[P] & { code: ErrorKey<Stringulator<P>, '429'> }
            >;
          }[keyof OO]
        | {
            [P in keyof PP]: Prettify<
              PP[P] & { code: ErrorKey<Stringulator<P>, '430'> }
            >;
          }[keyof PP]
        | {
            [P in keyof QQ]: Prettify<
              QQ[P] & { code: ErrorKey<Stringulator<P>, '431'> }
            >;
          }[keyof QQ]
        | {
            [P in keyof RR]: Prettify<
              RR[P] & { code: ErrorKey<Stringulator<P>, '444'> }
            >;
          }[keyof RR]
        | {
            [P in keyof SS]: Prettify<
              SS[P] & { code: ErrorKey<Stringulator<P>, '450'> }
            >;
          }[keyof SS]
        | {
            [P in keyof TT]: Prettify<
              TT[P] & { code: ErrorKey<Stringulator<P>, '451'> }
            >;
          }[keyof TT]
        | {
            [P in keyof UU]: Prettify<
              UU[P] & { code: ErrorKey<Stringulator<P>, '497'> }
            >;
          }[keyof UU]
        | {
            [P in keyof VV]: Prettify<
              VV[P] & { code: ErrorKey<Stringulator<P>, '498'> }
            >;
          }[keyof VV]
        | {
            [P in keyof WW]: Prettify<
              WW[P] & { code: ErrorKey<Stringulator<P>, '499'> }
            >;
          }[keyof WW]
        | {
            [P in keyof B]: Prettify<
              B[P] & { code: ErrorKey<Stringulator<P>, '4xx'> }
            >;
          }[keyof B]
        | {
            [P in keyof A]: Prettify<
              A[P] & { code: ErrorKey<Stringulator<P>, '5xx'> }
            >;
          }[keyof A]
        | {
            [P in keyof XX]: Prettify<
              XX[P] & { code: ErrorKey<Stringulator<P>, 'default'> }
            >;
          }[keyof XX]
    :
      never,
> = G;

type Prettify<T> = {
  [K in keyof T]: T[K];
} & {};

type Stringulator<T extends string | number | symbol> = T extends number
  ? `${T}`
  : T extends string
    ? T
    : 'was a symbol';

type ErrorKey<
  ContentType extends string,
  RawCode extends string | number | symbol,
  Code extends string = Stringulator<RawCode>,
> = ContentType extends `${infer _}/${infer Type}` ? `${Code}/${Type}` : never;

type ErrorStatusTuple = [
  499,
  498,
  497,
  451,
  450,
  444,
  431,
  430,
  429,
  428,
  427,
  426,
  425,
  424,
  423,
  422,
  421,
  420,
  418,
  417,
  416,
  415,
  414,
  413,
  412,
  411,
  410,
  409,
  408,
  407,
  406,
  405,
  404,
  403,
  402,
  401,
  400,
  511,
  510,
  508,
  507,
  506,
  505,
  504,
  503,
  502,
  '4xx',
  '5xx',
  'default',
];

This is also a show stopper for us

FWIW, I wound up working around this by writing my own fetch client + helper that can discriminate on HTTP codes and types its data.content and data.headers accordingly.
This is far from polished for general use, and there are some parts of the OpenAPI 3.x spec that it likely won't handle... but it works for my specific use-case of pairing with a Poem OpenAPI server.
Here's the code, if this helps anyone:
types.ts
Note: schema.gen is the file generated by openapi-typescript.
import { paths } from "./schema.gen";

// Methods that are allowed by this spec.
export type Method = "get" | "post" | "put" | "delete";

// Filter down the list of paths to only those that support
// the given method.
export type Paths<M extends Method> = {
  [K in keyof paths]: paths[K] extends { [key in M]: any } ? K : never;
}[keyof paths];

// Get the request body type for a given path and method. This is unlikely
// to apply to all paths, so we need to use a conditional type to check
// if the path supports a request body.
export type RequestBody<
  M extends Method,
  P extends Paths<M>,
> = paths[P][M] extends {
  requestBody: {
    content: { [key in string]: infer R };
  };
}
  ? R
  : void;

// Define the "inner" parameters that can be passed to a request. This
// includes param values for the query, header, path, and cookie.
export type InnerParams = {
  query?: object;
  header?: object;
  path?: object;
  cookie?: object;
};

// Get the parameters for a given path and method. This is unlikely
// to apply to all paths, so we need to use a conditional type to check
// if the path supports parameters.
export type Params<M extends Method, P extends Paths<M>> = paths[P][M] extends {
  parameters: infer Params extends InnerParams;
}
  ? Params
  : never;

// Extract the `responses` key on a path and method and return a map of the
// status codes -> content/headers. We can use this to narrow further to headers
// and content for a specific status code.
export type Responses<
  M extends Method,
  P extends Paths<M>,
> = paths[P][M] extends {
  responses: infer R extends {};
}
  ? R
  : never;

// Extract the headers for a given status code.
export type HeadersByStatus<
  M extends Method,
  P extends Paths<M>,
  S extends number,
> =
  Responses<M, P> extends {
    [key in S]: {
      headers?: infer H;
    };
  }
    ? H
    : never;

// Extract the content data for a given status code.
export type ContentByStatus<
  M extends Method,
  P extends Paths<M>,
  S extends number,
> =
  Responses<M, P> extends {
    [key in S]: {
      content?: { [key in string]: infer C };
    };
  }
    ? C
    : never;

// The `data` object contains the headers and content for a given status code.
export type DataByStatus<
  M extends Method,
  P extends Paths<M>,
  S extends number,
> = {
  headers: HeadersByStatus<M, P, S>;
  content: ContentByStatus<M, P, S>;
};

// A full response contains the status code (that we can discriminate on) and
// the header + content `data` object. We can use the `checkStatus()` function to
// narrow the type of the `data` object based on the status code.
export type Result<M extends Method, P extends Paths<M>, S extends number> = {
  status: S;
  contentType: string | null;
  data: DataByStatus<M, P, S>;
};

// Params for the `handleRequest` function
export type HandleRequestParams<M extends Method, P extends Paths<M>> = {
  path: P;
  method: Uppercase<M>;
  params?: InnerParams;
  body?: object;
  requestInit?: RequestInit;
};

// Type for a function that modifies the request before it's sent. This can
// be used to add headers for auth or other purposes.
export type ModifyRequestFunc = (req: RequestInit) => RequestInit;

//
// Argument types for `client` functions.
//

// GET
export type GetArgs<P extends Paths<"get">> =
  Params<"get", P> extends {
    [K in keyof Params<"get", P>]: never;
  }
    ? [path: P]
    : [path: P, params: Params<"get", P>];

// POST
export type PostArgs<P extends Paths<"post">> =
  Params<"post", P> extends {
    [K in keyof Params<"post", P>]: never;
  }
    ? [path: P, body: RequestBody<"post", P>]
    : [path: P, body: RequestBody<"post", P>, params: Params<"post", P>];

client.ts
import type {
  Method,
  Paths,
  HandleRequestParams,
  GetArgs,
  PostArgs,
  Result,
  Responses,
  ModifyRequestFunc,
} from "./types";

const CONTENT_TYPE_HEADER = "Content-Type";
const APPLICATION_JSON = "application/json";

// Create a type-safe client using the OpenAPI schema and fetch
export function createClient(baseURL: string) {
  // Start with an identity function for modifying the requests.
  // This will be used by default, and can be overridden by the user.
  let modifyRequestFunc: ModifyRequestFunc = (req) => req;

  // Define a function to handle requests, closing over `baseURL`
  const handleRequest = async <M extends Method, P extends Paths<M>>({
    path,
    method,
    params = {},
    body,
    requestInit = {},
  }: HandleRequestParams<M, P>): Promise<Result<M, P, number>> => {
    // Replace path parameters with values
    let substitutedPath = Object.entries(params?.path || {}).reduce(
      (acc, [key, value]) => {
        return acc.replace(`{${key}}`, value);
      },
      path as string
    );

    // Build the request URL
    let url = new URL(baseURL + substitutedPath);

    // Add the search params to the URL for `GET` requests
    if (requestInit.method === "GET" && params.query) {
      Object.entries(params.query).forEach(([key, value]) => {
        url.searchParams.append(key, value);
      });
    }

    // Build the final request by merging request opts
    let finalRequestInit = modifyRequestFunc({ ...requestInit, method });

    // If we have a body, add it to the request
    if (body) {
      finalRequestInit.body = JSON.stringify(body);

      // Add headers to the request
      finalRequestInit.headers = {
        ...finalRequestInit.headers,
        [CONTENT_TYPE_HEADER]: APPLICATION_JSON,
      };
    }

    // Make the request and infer the response based on the expected code.
    // We'll leave the caller to catch exceptions and handle them as needed.
    const res = await fetch(url, finalRequestInit);

    // Initialise a data object to hold the headers and the content.
    // We're trusting here that this maps 1:1 to what's in the spec!
    //
    // For now, we'll type this as `any` to build the object dynamically
    // and we'll narrow it later based on the content type.
    let data = {
      headers: {},
      content: null,
    } as any;

    // Insert the headers.
    res.headers.forEach((value, key) => {
      data.headers[key] = value;
    });

    // Parse the response based on the content type.
    const contentType = res.headers.get(CONTENT_TYPE_HEADER);

    // If we *do* have a content type header, we'll assume it's
    // either JSON or plain text we need to parse.
    if (contentType) {
      data.content = await (async () => {
        if (contentType.includes(APPLICATION_JSON)) {
          return res.json();
        } else {
          return res.text();
        }
      })();
    }

    // Return a mapping of status -> content. Initially, this
    // will map to `number`, but this will be narrowed later with
    // a call to `checkStatus` to get the relevant content.
    return {
      status: res.status,
      contentType,
      data,
    };
  };

  return {
    // Allow the user to modify the request before it's sent.
    modifyRequest(func: (req: RequestInit) => RequestInit) {
      modifyRequestFunc = func;
    },
    // GET paths
    get<P extends Paths<"get">>(...args: GetArgs<P>) {
      return handleRequest<"get", P>({
        path: args[0],
        method: "GET",
        params: args[1],
      });
    },
    // POST paths
    post<P extends Paths<"post">>(...args: PostArgs<P>) {
      return handleRequest<"post", P>({
        path: args[0],
        method: "POST",
        body: args[1]!,
        params: args[2],
      });
    },
  };
}

// Narrow the type of a response based on the status code.
export function checkStatus<
  M extends Method,
  P extends Paths<M>,
  const S extends keyof Responses<M, P> & number,
>(res: Result<M, P, any>, status: S): res is Result<M, P, S> {
  return res.status === status;
}

And an example of how it can be used...
// This example code is extracted from a Next.js submit
// handler I wrote for a registration form.

// Instantiate the client. I have two methods here -- one for
// server-side requests and one for client-side requests, which
// inject HTTP headers for each environment accordingly.
const client = clientApi();

// Type safe. `client.post` will only accept known string paths,
// and `data` must match the body request.
const res = await client.post("/auth/register", data);

// We check use the `checkStatus` helper to narrow down the
// response type. This accepts known key constants -- e.g. "300" here
// would be a type error. Since this is coded using `const T` on the
// function, this provides implicit narrowing on `res.data.*`
if (checkStatus(res, 200)) {
  setEmailConfirmation(res.data.content);
  return;
}

// This is the crux of why I need this: a 422 response in my server
// API typically contains a union of possible types (mapped using Rust
// enums), so we need to a) narrow based on the HTTP code and b) further
// narrow based on the content (in this case, the `type` key)
if (checkStatus(res, 422)) {
  const { content } = res.data;

  if (content.type === "RegisterFailed") { // <-- fully known, typed!
    switch (content.reason) {
      case "EmailExists": // <-- another discriminant.
        setError("email", { message: "Email already exists" });
        return;
    }
  }

  // If .type != "RegisterFailed", Typescript knows it must therefore
  // be an "InputErrors" which is a typed array of field-mapping errors
  content.errors.forEach(({ path, message }) => {
    setError(path, { message });
  });
}

Thanks all for giving additional feedback! I agree now that we made the wrong call on this.

@drwpow Do you have examples of impossible unions?

If you look at the original issue, it was less that the raw schema object type union was impossible, and more that in an API serving multiple content types often the desired one will get dropped. But the change didn’t necessarily fix this at a core level. Perhaps we do something like allow an optional generic param to fix that, e.g;
client<paths, "application/ nd.api+json">

Anyways, again, thanks all for sharing feedback and providing solutions.
@Twiggeh, I think that would work, and we’d accept a PR for that 🙂.

As an aside, I think this project is probably reaching the state where we could do some RFCs for upcoming breaking changes. We’ll certainly have one for 1.0, and I think this pretty much counts as an RFC for reverting this change.
I don’t think RFCs magically notify the right people every time who are key decision-drivers. But they can highlight 2 things:

Provide a clearer summary of why changes were made, and
Identify, in hindsight, that a RFC with little input may not have taken everything into consideration and needs to be reversed.

Thanks all for giving additional feedback! I agree now that we made the wrong call on this.

Any ideas on a timeline for repairing the situation?  We're still pinned to <0.10.0.  Is it possible to revert this change and get back to the previous behavior, and then work out a better solution from there?

same here, were are also pinned to 0.9.8 since we actually provide different response bodies depending on the HTTP status code:
      const response = await apiClient.POST('/foo');

      handleErrorResponse(response, {
        403: MissingPermissionsError,
        409: FooAlreadyExistsError,
      });

      return response.data;

Updating to 0.10 breaks our handleErrorResponse function we use in all API calls.

We also have to revert back to 0.9.8 because we need to be able to handle different response bodies for different status codes.

Anyways, again, thanks all for sharing feedback and providing solutions.
@Twiggeh, I think that would work, and we’d accept a PR for that 🙂.

Sorry, I completely missed that email, glad this is resolved now :smile:

I'm still experiencing a weird behavior with openapi-fetch 0.13.0, in one of the POST methods for an endpoint:
const { data, error, response } = await client.POST("/method", {...});
if (error) {
  throw new Error(...);
}
setDataId(data.id);  // <-- TS says "'data' is possibly 'undefined'"

But if I check data like data?.id I get "Unnecessary conditional".  So the typing is still a bit broken for me.

I'm having the same issue as @markedwards. 0.12.5 also seems to have the issue, but version 0.12.4 works okay!

Should we create a new issue for this at this point?  I still am unable to update from <0.10.0.

Same issue here


gl 3d render not display but show imgui

Tired a simple 3d cube rotate and it not displaying. Just showing the imgui. Need help.

Hello.
Can you show me your full source code, please?

Sorry About that. Here my project build test. https://github.com/Lightnet/sfml_rpgen   main_sfml_rpgen.cpp main file for 3d render test.


[wip] refactor: parrallel tests

What is the reasoning for this refactor? This PR conflicts with a WIP test refactor I am doing for making room to onboard EnvoyGateway. Basically I am creating "istio tests", so we can later add "envoy gateway tests".

What is the reasoning for this refactor? This PR conflicts with a WIP test refactor I am doing for making room to onboard EnvoyGateway. Basically I am creating "istio tests", so we can later add "envoy gateway tests".

@eguzki Just seeing how easy / difficult it is to do this / what issues are there and to see if it's worth it generally (can be seen as part of https://github.com/Kuadrant/kuadrant-operator/issues/564). Not particularly looking to merge this soon if it's a concern

I thought we had already did this parallel test thing, but it was on the limitador-operator https://github.com/Kuadrant/limitador-operator/pull/134.
There is a big conflict with https://github.com/Kuadrant/kuadrant-operator/pull/645 but we will workout as needed. :+1:

Closing this and opening up another PR since it's a big rebase


Remove Istio reconciler

Description
Changes proposed in this pull request:

Remove Istio reconciler as part of clean up after module rollout

Related issue(s)

/hold
Cannot be removed until Kyma releases with component Istio are no longer supported

already done with: https://github.com/kyma-project/control-plane/pull/3221


add maori (mi-nz)

Generally this is fine, but the comments need to have your name in them as the author. In the future, if people wish to make changes to this locale, we will ping you on github to approve those changes, as we don't speak this language. See the other locale files for the expected format. We do use a script to automatically parse locale information, so please keep the spacing/punctuation the same.

Thanks @maggiepint I'll make the change and push it up.

@johnideal - Please make the minor change to add your info in the comments.  See the other locale files for examples.  Thanks.

Sorry for the delay, added contact info.

Merged in ae03e51


Runtime panic with go 1.6

Not sure if this package is still maintained.
When I use go 1.5, the library seems to work. But with go 1.6 I get this error
panic: runtime error: cgo argument has Go pointer to Go pointer

goroutine 8 [running]:
panic(0x40fa8e0, 0xc82000a2e0)
	/usr/local/Cellar/go/1.6/libexec/src/runtime/panic.go:464 +0x3e6
github.com/ninjasphere/go-openzwave._cgoCheckPointer0(0x40d1a00, 0xc8200600c0, 0x0, 0x0, 0x0, 0x0)
	??:0 +0x4d
github.com/ninjasphere/go-openzwave.(*api).Run.func2(0xc8200600c0, 0xc820056150)
	/Users/laibulle/Eliocity/www/go/src/github.com/ninjasphere/go-openzwave/run.go:113 +0x62
created by github.com/ninjasphere/go-openzwave.(*api).Run
	/Users/laibulle/Eliocity/www/go/src/github.com/ninjasphere/go-openzwave/run.go:198 +0x178
exit status 2

Thanks @laibulle I will have a look at it.

Seems I have fallen foul of this change - https://github.com/golang/go/issues/12416 .  I will have to re-examine how I share a references to go structures with the C world.

Closed via #5


2nd Release - M101.0.4921.0 - AVX2 is brocken

Both installer and portable. Error: RESULT_CODE_MISSING_DATA

Use Compatibility Mode with win 7 or 8.

@Lehner82 @oka1q Yep! Known upstream bug.

@Lehner82 Checking back in before I close this issue, do you have it working now?


Grammar Fix

Agree the verb with the plural subject "OGGs", by changing the verb form to "are".

Missed this. Thanks!


Update 00_Load_and_Display_Image.js

this example doesn't seem to run as expected. i would hope to see 2 images of different sizes, but i see 1 image. tested on Chrome latest on Windows 8.1
remove my // TODO when fixed

Thanks, I'll take a look at this one.

it seems to work now.
thanks.


refactor: spec_finder.py

This PR

applies ruff format
adds missing docstrings for main
uses %s formatting in logging functions
adds encoding
refactors extract_spec_map & parse_rust_files code from main
refactors get_spec function
adds logging config
adds docstrings for _demarkdown & get_spec function
improves message sentence

Notes
Also, fixes parsing error for the specification.json

hey @prnam thanks for the contribution, but there are too many unrelated changes in one PR, which makes it tedious to review. For example, don't apply a radical formatting, which changes mostly single quotes strings to double quotes. This is just a helper script, not really sure it needs proper logging or docstrings. Please create separate PRs for a subset of changes, then it can be reviewed better.

@justinabrahms you may be interested in this one 😄


Error while executing

I have cloned all the files and executed the main.py file. Below is the error being received
Shape must be at least rank 3 but is rank 2 for '{{node BiasAdd}} = BiasAdd[T=DT_FLOAT, data_format="NCHW"](add, BiasAdd/ReadVariableOp)' with input shapes: [?,2048], [2048].
@arya46

@Deepak3693 Use TF 2.1. Also, run the app with GPU.

@Deepak3693 Use TF 2.1. Also, run the app with GPU.

It is asking me to sign in to local host. What the username and password?

Also can i run this without gpu?

It is showing error that "  [Errno 2] No such file or directory: 'static/m.jpg'  ". What should i do ?

@MrinalBanchhor The app first uploads the file to a folder named "static" before it can proceed with other steps. Make sure that your file is getting saved in the "static" folder.

It is showing error that " [Errno 2] No such file or directory: 'static/m.jpg' ". What should i do ?

I am facing the same issue. Any leads?

@hirafs Please make sure that you have a folder named 'static' in your project root. The logic tries to find the image that is saved in the static folder during prediction (the image is saved there when you upload the image). If the folder is not present, the saving of the file will not be complete, and you could face that error.

@Devika2020 Yes, both the train and inference is set to run on GPU.

Hey! Can the inference be run without a GPU? If so, could you please help me how to go about it?
Thanks!

@AbhimanyuSethi-98 I have not tried that out. I would be glad if you can try doing that and let me know.


CNNO-2264: Add status filter

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.


correct the --save option

currently the logic for --no-save and checking the flag is inverted -- running without the flag doesn't save, and using --no-save essentially enforces same.
change to --save and store as TRUE

@googlebot I signed it!


evaluate_performance: traverse correlation across a migration season

Here's the function I was talking about today that calculates the traverse correlation across a season (plus the buffer), by predicting forward from the single time-step marginal distribution at the beginning of the season (minus the buffer).  I think it could be great to have this in the package, either as its own function or as an extension of the evaluate_performance function.  My function below also calculates a correlation for the migration start week (minus the buffer), but I think that's probably not 100% necessary because this gets baked into the end_traverse_cor as well.
Happy to do a PR if you think it needs to be its own function or if that makes it easier, but if you're taking a look at evaluate_performance soon anyway, maybe it makes just as much sense for you to roll it in to those changes?  I'm not wedded to any particular naming conventions herein.
# Evaluate how well the STS marginal distribution correlates with ebirdST distribution at the season start point
# AND
# Evaluate how well the ebirdST end date distribution correlates with the forwarded-projected distribution when starting with the marginals

evaluate_performance_route <- function (x, season = 'all')
{
  if (!has_dynamic_mask(x))
    x <- add_dynamic_mask(x)
  season_timesteps <- lookup_season_timesteps(x, season)
  start <- season_timesteps[1]
  end <- tail(season_timesteps, 1)

  start_distr_ebirdst <- get_distr(x, start, from_marginals = FALSE)
  start_distr_marginals <- get_distr(x, start, from_marginals = TRUE)
  start_dm <- get_dynamic_mask(x, start)
  start_cor <- cor(start_distr_ebirdst[start_dm], start_distr_marginals[start_dm])
  end_distr_ebirdst <- get_distr(x, end, from_marginals = FALSE)
  projected <- predict(x, distr = start_distr_marginals, start = start,
                       end = end, direction = "forward")
  end_dm <- get_dynamic_mask(x, end)
  end_traverse_cor <- cor(end_distr_ebirdst[end_dm], projected[end_dm, ncol(projected)])
  # get_distr(bf, start, TRUE) |> rasterize_distr(bf) |> terra::plot()
  # get_distr(bf, start, FALSE) |> rasterize_distr(bf) |> terra::plot()
  # get_distr(bf, end, TRUE) |> rasterize_distr(bf) |> terra::plot()
  # get_distr(bf, end, FALSE) |> rasterize_distr(bf) |> terra::plot()
  list(start_cor = start_cor,
       end_traverse_cor = end_traverse_cor)
}
#evaluate_performance_route(bf, 'prebreeding')

I think it could make sense to have "..." (which could be a season argument, or anything else that works with lookup_timestep_sequence) apply to all of the metrics in the output, not just the partial traverse.  And this would also simplify it, since that could just be returned as 'traverse correlation' but it would reflect the timestep sequence used.
If we also want to know full year, could just run the function twice, but I think typically we'll just be interested in either or, depending on the question.
I like "distribution performance"

Sounds like a plan.  I'll rename it distribution_performance(), but will leave evaluate_performance() as a temporary wrapper to the new function for a few weeks so the update doesn't break anything immediately

Re "..." time subset affecting all metrics.

Calculating all metrics consistently from the time subset makes sense to me.  I'll do that.
That leaves us with two very similar traverse metrics.  The only remaining difference (post bug fix),  being whether we start with the ebird S&T distribution or the marginal distribution.

Do you have a sense for how big a difference that is?
Implementation wise it's easy to calculate both versions at once with vectorized code so I don't think there's much of a performance penalty for doing both, but there mere be a cost in interpretability.
I'm tempted to just have one traverse metric.  Conceptually I liked the original version based on projecting the S&T distribution through the model and then comparing to the projected to the S&T distribution for the ending step, but I'm having trouble saying why, also I'm all for empiricism if starting from the marginal works better.
If we keep both traverse metrics and apply the time subset to both the "partial_" name I proposed doesn't make sense.   Possible names:  st_traverse_correlation md_traverse_correlation  (for eBirds S&T, and marginal distribution).  Something better?

Calculating both is fine, but I'll probably keep using the one that's the equivalent of my end_traverse_cor. I haven't tested how big of a difference it is but conceptually I like it to make it start with the marginals because that should be harder, especially when the model is tempted to under-emphasize the range edges. Maybe abbreviate to _cor like the old ones to keep the variable names a little shorter?
I haven't compared these two options with each other, but there was a big difference sometimes between end_traverse_cor and mean_distr_cor

Renaming it via a temporary wrapper is a nice touch from a public package perspective, although if I'm the only one using this function right now, don't do it just for me.  I always check the recent commits and news before I pull, and only pull when I'm ready to potentially make a few changes :-)


Unauthorized RenewWebhook flow

Context: https://dust4ai.slack.com/archives/C05F84CFP0E/p1709406567198239

When a renew webhook fails because the connection is unauthorized
mark the connector as errored
skip the connector for future webhook renewal
make sure the connector error is removed on re-authorization

Logs https://app.datadoghq.eu/logs?query="Failed to renew webhook" &cols=host%2Cservice&fromUser=true&index=*&messageDisplay=inline&refresh_mode=sliding&storage=hot&stream_sort=desc&viz=stream&from_ts=1709553933717&to_ts=1709640333717&live=true


Gha updates

PR description
Fixed Issue(s)
fixes #6695

No longer defers testing till after approval, functionality to be redesigned
concurrent runs for the same branch will be cancelled on update to the ref
new develop floating pre-release to be maintained with downloadable artifacts on push to main
codeql job deferred to nightly runs on main

Thanks for sending a pull request! Have you done the following?

[x] Checked out our contribution guidelines?
[x] Considered documentation and added the doc-change-required label to this PR if updates are required.
[x] Considered the changelog and included an update if required.
[x] For database changes (e.g. KeyValueSegmentIdentifier) considered compatibility and performed forwards and backwards compatibility tests

Most advanced CI tests are deferred until PR approval, but you could:

[x] locally run all unit tests via: ./gradlew build
[x] locally run all acceptance tests via: ./gradlew acceptanceTest
[x] locally run all integration tests via: ./gradlew integrationTest
[x] locally run all reference tests via: ./gradlew ethereum:referenceTests:referenceTests

@jflo develop workflow looks great, thanks! 👍


Live reload not working

The browser page does not refresh whenever I edit and save the file.
[OS: Windows 10]

Unfortunately I’m not able to reproduce this issue on OSX. (And also unable to debug because I don’t have a Windows PC.)
To be precise, the expected behavior is that when your Markdown file changes, the rendered page should update transparently without a refresh – note that this is different from how “Live Reload” works.

Yes, even the transparent update doesn't work unfortunately.
Is there something I can help you debug it?

Would you please point me towards the part of the code that does file-watching? I'll see if I can fix and send a PR.
Thanks!

I have located the issue: the address <IP_ADDRESS> does not work on Windows (or maybe it's not configured to route to localhost by default)
Changing it here: https://github.com/yuanqing/rdd/blob/f85dc5dba860f41cc29ee04399e551c529df1097/src/js/serve.js#L87
and here: https://github.com/yuanqing/rdd/blob/f85dc5dba860f41cc29ee04399e551c529df1097/src/js/client.js#L5
to <IP_ADDRESS> works!
Would you like me to send a PR?

Is there a way to make a change that would work for both MacOS and Windows?

I believe the address <IP_ADDRESS> should work everywhere - Linux/Mac/Win.
Does it not work for you?

@rashil2000 Are you able to verify if the fix in https://github.com/yuanqing/rdd/pull/3 fixes the issue on WIndows?

Hi @yuanqing
Yes, the address change fixes the live-reloading issue.
However, there are multiple other quirks in rdd that prevent it from building under, and running properly on Windows.

The build script uses cat command, which does not exist on Windows: https://github.com/yuanqing/rdd/blob/f85dc5dba860f41cc29ee04399e551c529df1097/package.json#L63
The path resolution library globby, that is being used to resolve markdown files, does not work with Windows-style paths. https://github.com/yuanqing/rdd/blob/f85dc5dba860f41cc29ee04399e551c529df1097/src/js/resolve-markdown-files.js#L22

The fix for 1. is replacing both mkdirp and rimraf with the shx library, which, in addition to providing mkdir and rm commands, also provides a cat command.
The fix for 2. is removing the library globby altogether (this may not be what you want), and letting Nodejs's core path module handle the paths.

I have a fork of rdd, which is 2 commits ahead of upstream, and fixes these problems.

f5434da6e9ddae3220f2e8244bf79ec9f8baa943
e10cbbdc3f10b630ccc3be24f0990324cd19bc7b


Add about us page

Related Issue
fixes #891
Description

I have created separate page for about us.
About us page is responsive.
updated about us link in each html files.
removed about us section from index.html.

Type of PR

[ ] Bug fix
[x] Feature enhancement
[ ] Documentation update
[ ] Other (specify): _______________

Screenshots / videos (if applicable)

Checklist:

[x] I have performed a self-review of my code
[x] I have read and followed the Contribution Guidelines.
[x] I have tested the changes thoroughly before submitting this pull request.
[x] I have provided relevant issue numbers, screenshots, and videos after making the changes.
[x] I have commented my code, particularly in hard-to-understand areas.

Additional context:
Kindly please let me know if any changes required!

@Suchitra-Sahoo can you please provide level 2 badge for this pr. I have added a new separate page. I think the changes might be enough the get a level 2 badge.

Okay but before that change the font of about page to the one as in home page.

Before doing that pull all the changes from origin

Okay but before that change the font of about page to the one as in home page.

Sure. May I create a new pr?

Yes you can but i'll add the level in this PR so mention your PR number and issue number in your new PR.

Yes you can but i'll add the level in this PR so mention your previous PR number and issue number in your new PR.

Sure. Got it.

@Suchitra-Sahoo, Thank you for your consideration.


FIX: ipython support

This PR uses ipython magic to fix the "freezing" happening when block=False in an Ipython environment.
It also adds dependency to scooby to detect the aforementioned ipython environment.
Closes https://github.com/mne-tools/mne-qt-browser/issues/72
Related to https://github.com/mne-tools/mne-python/pull/10472

Amazing! It works for me!
@agramfort I cannot merge due to lack of privileges :'(

We should cut a release once this is merged

Thank you @GuillaumeFavelier, this is a great solution.

We should cut a release once this is merged

Done

Great!


Start making patchew more hackable, and some django fixes

First steps towards fixing issue #20.

Because I didn't know anything about Django and copied what the patchew-server script was doing...

Applied manually with some tweakings, so closing this PR.


audit-avt1-homepage: invalid role on element main

Environment:

Operating system: Mac
Browser: Chrome
AVT :one:
Page: Homepage

Detailed Description:
The WAI-ARIA role or attribute 'presentation' is not valid for the element <main>
What to do:

If a native HTML element fits the intended behavior, use that;
OR, update the role and/or attributes using the guidance in W3C ARIA in HTML Document conformance requirements for use of "ARIA" attributes in HTML.

Why is this important?
Some HTML elements or attributes have native semantics that map by default to an implied WAI-ARIA semantics. For predictable interaction and behavior of UI controls, these implicit semantics should only be overridden in specific ways,

This bug will be fixed by the PR opened in the Carbon Gatsby Theme: https://github.com/carbon-design-system/gatsby-theme-carbon/pull/944


Optimize AVX2 CGEMM

Replace KERNEL_8x3 with KERNEL_8x6 to slow down reading on packed matrix A, similar to the optimization of AVX2 ZGEMM in #2344 .
1-thread performance in GFLOPS:
On Xeon Gold 6149 (TARGET=HASWELL, MKL_CBWR="AVX2"):
Old kernel:  21.0
New kernel:  22.4
MKL2018:  23.2
Theoretical:  24.8
On Ryzen 7 3700x fixed at 3.6 GHz (TARGET=ZEN, MKL_DEBUG_CPU_TYPE=5):
Old kernel: 24.9
New kernel:  27.2
MKL2018:  27.5
Theoretical: 28.8
Use the new ZGEMM kernel from #2344 on ZEN as well.

A simple test of m=n=k=5000 using 1 thread on i9-9900K
(AVX-OFFSET = 6, theoretical 35.2 GFLOPS):
old kernel:

new kernel:

The new kernel passed reliability test.


ReactDOMServer.renderToStaticMarkup() compatibility?

Are there any plans to support ReactDOMServer.renderToStaticMarkup()? I mean, is it even possible with current Highcharts codebase? If positive, I'd be happy to dig it deeper for a solution.
const React = require('react');
const ReactDOMServer = require('react-dom/server');
const ReactHighCharts = require('react-highcharts');

const markup = ReactDOMServer.renderToStaticMarkup(React.createElement(ReactHighCharts, { config: {"credits":false,"chart":{"type":"column","height":300} } }));
console.log(markup);

Output:

That's kind of related to #224.
I couldn't find a good solution for this, maybe it would be possible to make it work with JSDom?
Last time I checked JSDom didn't work well with svg, but this might have been fixed since then.
I'm happy to hear your inputs/potential solutions on that.

It seems Highcharts is strongly coupled to DOM itself. Unless we can inject JSDOM (or Cheerio) to Highcharts I don't think it would be possible to use JSDOM with current Highcharts codebase in order to render it server-side (or to make a better DOM diff as #224).

Closing and there has been no activity in this issue for a while.
if this is still relevant, please feel free to reopen


fix: ensure that each post should only be processed once

Fix a serious bug: When used with certain plugins, sometimes post_permalink is called more than once, causing abbrlink to be incorrect.
Now ensure that each post is only processed once.

Move abbrlink cache to model, make the logic clearer.

Update README with current configurations.

@ohroy Sorry to disturb, but I have found a serious bug about post_permalink. Has been fixed here.🫠


[HUDI-393] Add azure pipelines configs

Use a separate maven profile azp-unit-tests to exclude some failing tests in Azure pipelines.
Committer checklist

[ ] Has a corresponding JIRA in PR title & commit

[ ] Commit message is descriptive of the change

[ ] CI is green

[ ] Necessary doc changes done or have another open PR

[ ] For large changes, please consider breaking it into sub-tasks under an umbrella JIRA.

Codecov Report

Merging #2582 (8d8ca80) into master (5d2491d) will decrease coverage by 41.36%.
The diff coverage is n/a.

@@             Coverage Diff              @@
##             master   #2582       +/-   ##
============================================
- Coverage     51.04%   9.68%   -41.37%
+ Complexity     3181      48     -3133
============================================
  Files           433      53      -380
  Lines         19865    1931    -17934
  Branches       2042     230     -1812
============================================
- Hits          10140     187     -9953
+ Misses         8900    1731     -7169
+ Partials        825      13      -812

Flag
Coverage Δ
Complexity Δ

hudicli
?
?

hudiclient
?
?

hudicommon
?
?

hudiflink
?
?

hudihadoopmr
?
?

hudisparkdatasource
?
?

hudisync
?
?

huditimelineservice
?
?

hudiutilities
9.68% <ø> (-59.71%)
0.00 <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.


Netatmo Presence not shown

Hi,
is it possible to get the Netatmo presence in the node?

This would definitely be a plus to also get the Netatmo presence in the node with the Netatmo welcome cameras

I am no longer updating this code as I haven’t had a Netatmo device to test it with for several years.  It’s quite simple code, so fork the repo and take a shot at extending it for your needs.
Regards
Sam
Sent from my iPhone

On Sep 25, 2020, at 12:09 PM, Anthony-vdm<EMAIL_ADDRESS>wrote:

This would definitely be a plus to also get the Netatmo presence in the node with the Netatmo welcome cameras
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

I have checked and the netatmo presence has nothing to do with this code.
It is instead the authentication scope missing in the netatmo.js (dependency)
To fix it, update the netatmo.js by changing the scope = ... with the following line
scope = args.scope || 'read_station read_thermostat write_thermostat read_camera write_camera access_camera read_presence access_presence read_smokedetector read_homecoach';
You will then see the presence cameras (read_presence access_presence)

@Anthony-vdm  can you please create a pull request for your netatmo presence fix?
cheers, Thorsten

@ecdlguy
I have made a pull request on Sep 28 on the netatmo project managed by @floetenbaer on which this node-red-contrib-netatmo has a dependency: https://github.com/floetenbaer/netatmo/pulls
Changing the netatmo.js file on line 96 and restarting node red will allow you to get the netatmo presence information


v2.ODataModel inconsistency between code and documentation

First: I hereby declare to agree to the OpenUI5 Individual Contributor License Agreement.
The documentation for v2.ODataModel.prototype.update states that the default value of the merge parameter is boolean false. But if a parameter map is provided but doesn't list the merge parameter, it is defaulted to true.
This PR fixes this problem by adjusting the code to match the documentation (as documentation has already been released, adjusting the documentation is not an option).
See internal incident<PHONE_NUMBER>

Hi Maximilian,
thanks, the responsible developer will have a look at this (maybe after this week, he's very busy) and we'll let you know.
Internal tickets that come with a fix are the best ones... ;-)
Regards
Andreas

Closing this PR. The fix is part of 3201b0980015de9a2d8ed7b2637dd4fcaf31d01a.


Receive RTMP input support

Hi, do you have plan to include RTMP input support along with webrtc and rtsp?
Looking forward to hearing from you ~
Thank you ~

Hi @Codename-404, we have it in our roadmap for Jellyfish 0.5.0. You can track this issue: https://membraneframework.atlassian.net/browse/RTC-439


Reinstate Check Jobs for SoCo Development

Travis CI withdrew the ability for open source projects to run check jobs, during the development of SoCo v0.21.
It's important that we reinstate an alternative process, otherwise SoCo development velocity will be significantly impeded and there'll need to be excessive manual testing.

Take a look at https://hynek.me/articles/python-github-actions/ (for github actions) or https://hynek.me/articles/simple-python-azure-pipelines/ (for azure pipelines, which requires quite a bit more effort but is not bound to github).

Take a look at https://hynek.me/articles/python-github-actions/ (for github actions) or https://hynek.me/articles/simple-python-azure-pipelines/ (for azure pipelines, which requires quite a bit more effort but is not bound to github).

I'm already working on a tox configuration for SoCo, which makes it easier to setup Github Actions. I will post a PR shortly.

I'm already working on a tox configuration for SoCo, which makes it easier to setup Github Actions. I will post a PR shortly.

As a temporary measure, I've instantiated a 'brute force' Github actions workflow that performs the same checks as the previous Travis job, across Python 3.5 to 3.9. It appears to be working correctly for PRs and merges to master.
This can be junked when we have a tox configuration.


Always run pretty with the default sort conf when saving cfbs.json

We could add a basic test for this. I tested locally, manually, and it seems to work correctly.

@oleorhagen FYI, I added some more fixes / followups here: https://github.com/cfengine/cfbs/pull/182


Implement empty screen

fixes #483
fixes #485

TODOS:

Adding the rest of the states of the textfield validation (loading, valid).

This PR focuses on the design in the right content panel and the popup that uploads files.
It was hard for me to separate these two implementations so I did them in the same PR. I will create a different PR to work on the file menu for #483

@roll I am stuck in the textfield re-rendering after typing each letter here: https://github.com/okfn/opendataeditor/pull/484/files#diff-3d1d6a77a9f6f10734c1402fc43da1d9e84a6936aba152ee056291861c79b785R234
The textfield works properly when placed outside the tabs. Do you have any suggestions? It seems like React.memo only works when there are props.

@guergana
I think I ran into something similar with MuI a long time ago, but I'm not sure what the problem was. I would probably split the big components into smaller ones for starter to identify a problem (obviously with re-rendering)

@guergana
I think I ran into something similar with MuI a long time ago, but I'm not sure what the problem was. I would probably split the big components into smaller ones for starter to identify a problem (obviously with re-rendering)

@roll I have identified the problem. The tab re-renders each time onChange is called in the textfield so the textfield loses focus. I already tried extracting the textfield to a component but the problem is the same as long as it's inside the tab.. I couldn't figure out a way of stopping the tab re-render.

Have you tried extracting CustomTabPanel?

Have you tried extracting CustomTabPanel?

@roll Hi, I found a way of listening to the event using the onComplete and onBlur events , the issue now is that the button below is disabled until the user blurs from the textfield... Probably there is another solution but maybe this could be ok for now?

cc @romicolman

@guergana this is looking good! With the changes made in #503 this should be almost done.
I will just simplify the button to just use the normal MUI button and we can merge it and works on further improvements (if needed) on next PRs.

@guergana this is looking good! With the changes made in #503 this should be almost done.
I will just simplify the button to just use the normal MUI button and we can merge it and works on further improvements (if needed) on next PRs.

Thanks! @pdelboca will get a new design for the MUI button? do i need to style the MUI button to fit more the design? waiting for the new design.

@guergana as a first step you can just simplify the button to use the MUI default one:
import Button from '@mui/material/Button'
<Button variant="contained" onClick={() => store.openDialog('fileUpload')}>Upload your data</Button>

I will check the Boxes with Faith.

@guergana I really like the implementation. Feel free to merge and we can discuss more styling details in an upcoming sprint.


Added installation instructions and a usage guide to README.md

Note that some of the code referred to in the usage guide as well as the reference to CHANGELOG.md reflect changes that are from #14

Note that builds don't pass because this branch is based off of master.  I recommend we merge #14 before merging this pull request.


Replace task runner

Coverage remained the same at 100.0% when pulling c47a5b95cd11691f5d86000f18446f90047a8a4c on dev into 707fb17c52d0c8a58f201718ccb07687cec71708 on master.


Add --watch option for linters

We won't do this, because it's not common feature and you can implement it by yourself by using onchange package and npm scripts.
Example:
{
    "scripts": {
        "lint-ts": "ffbt lint-ts ./src --force",
        "lint-ts-watch": "onchange 'src/**/*.ts' -i -d 500 -- npm run lint-ts",
     }
}


Add Integration tests to .net sdk repo

Expected Behavior
Add integration tests that can be run end-to-end on every PR.
Actual Behavior
No end-to-end tests
Steps to Reproduce the Problem

Especially actors

Closing this because it has no actionable information. We'll add tests as we make changes and investments going forward.


Improve README.

I've added my recording as mp4 video, converted it to a GIF using
ffmpeg and included it in the README to give a quick introduction of
what iPuzzler is looking like.
The README if following Key elements of the Art of README. I'm willing to tweak it further :)
Signed-off-by: André Jaenisch<EMAIL_ADDRESS>

https://github.com/dylanbeattie/ipuzzler/blob/391d293136249c9e3289a9082a8f90661bbb5571/README.md shows how the new README would look like


Doesn't compile on Ubuntu (linux).

Currently the project does not compile on Ubuntu, while browsing through the code I found this:
// FUTURE
// Currently the most popular linux distro (ubuntu) is replacing the xserver
// display server with Mir. An example Mir shell can be found at:
//     http://unity.ubuntu.com/mir/demo_shell_8cpp-example.html
// Work on the linux portion will be delayed until there is an
// ubuntu version that fully supports Mir.

// The ubuntu (linux) native layer implementation.
// This wraps the linux windows API's (where the real work is done).

// // The following block is C code and cgo directvies.

You can use Qt5 to create an openGL context and this is supported under Mir.
Ubuntu on the phone fully supports Mir and I have been able to get openGL contexts working under QT5 with QML and Go.

Same issue and it doesn't compile on Centos 7 too.

Same on Arch


Error while updating property 'marginRight' in shadow node of type: RCTView

I am not very good at English, please understand. Below is my issue:
Environment
Only appear on android platfrom.
Below is my global environment, and I modify version of react and react-native by my package.json
React Native Environment Info:     System:       OS: macOS High Sierra 10.13.3       CPU: x64 Intel(R) Core(TM) i5-5257U CPU @ 2.70GHz       Memory: 26.08 MB / 8.00 GB       Shell: 3.2.57 - /bin/bash     Binaries:       Node: 8.4.0 - ~/.nvm/versions/node/v8.4.0/bin/node       npm: 4.6.1 - ~/.nvm/versions/node/v8.4.0/bin/npm       Watchman: 4.7.0 - /usr/local/bin/watchman     SDKs:       iOS SDK:         Platforms: iOS 11.4, X 10.11, macOS 10.12, macOS 10.13, tvOS 11.4, watchOS 4.3       Android SDK:         Build Tools: 23.0.1, 23.0.2, 23.0.3, 24.0.0, 24.0.1, 24.0.2, 24.0.3, 25.0.0, 25.0.1, 25.0.2, 25.0.3, 26.0.1, 26.0.2, 27.0.3, 28.0.0, 28.0.0, 28.0.1         API Levels: 16, 23, 24, 25, 26, 27, 28     IDEs:       Android Studio: 3.1 AI-173.4907809       Xcode: 9.4.1/9F2000 - /usr/bin/xcodebuild     npmPackages:       react: 16.0.0-alpha.6       react-native: 0.43.4      npmGlobalPackages:       react-native-cli: 2.0.1       react-native-git-upgrade: 0.2.7
I so sorry, I can't run 'react-native info' success. So, I display a package.json and .babelrc information:
part of package.json：
"dependencies": {     "ajv": "^6.5.2",     "mobx-utils": "^3.0.0",     "fbemitter": "2.1.1",     "mobx": "3.1.0",     "mobx-react": "4.1.8",     "raven-js": "3.11.0",     "react": "16.0.0-alpha.6",     "react-native": "0.43.4",     "react-native-measureme": "0.0.1",     "react-native-keyboard-aware-scroll-view": "^0.2.8"   },   "devDependencies": {     "react-native": "0.43.4"     "babel-eslint": "8.2.6",     "babel-jest": "23.4.0",     "babel-plugin-transform-decorators-legacy": "1.3.5",     "babel-preset-react-native": "2.1.0",     "babel-preset-react-native-stage-0": "1.0.1",     "eslint": "3.19.0",     "eslint-plugin-react": "6.10.3",     "eslint-plugin-react-native": "2.3.2",     "jest": "23.4.1",     "react-test-renderer": "16.0.0-alpha.6"   }
.babelrc:
{   "presets": ["react-native"],   "plugins": ["transform-decorators-legacy"],   "sourceMaps": true }
Description
Background Introduction: I have two activity react native container(such as A, B).
Scene Introduction: When I stay at A, then open B. then I open other a page(component) of B, at last, I close A container by native bridge(operation flow: B -> native bridge -> A -> A close self)
screenshot:

Reproducible Demo
I so sorry, I can't provide a example project because my project is private. And my error unable to reproduce stably.please please understand. Thanks

Can you run react-native info and edit your issue to include these results under the Environment section?
If you believe this information is irrelevant to the reported issue, you may write [skip envinfo] under Environment to let us know.

I am not sure if it is my environmental problem, so I gave the global environment configuration and I modified version of react and react-native by my package.json. I desire to get help. Thanks

Can you run react-native info and edit your issue to include these results under the Environment section?
If you believe this information is irrelevant to the reported issue, you may write [skip envinfo] under Environment to let us know.

Remarks: Only appear on android platfrom.

大佬，解决了吗？我调试的时候也会经常报这个错，重新run-android就好了，完全找不到问题在哪。

没解决

Please update to the latest version of React Native. #21755, which @mvanroon flagged as being the same issue as this one, is fixed in the latest 0.57 as well as in 0.58-rc.

我们也会遇到这种类型的错
Error while updating property 'xxx' in shadow node of type: RCTText(RCTView....)


Failed to deploy a model locally on a remote worker

Describe the bug

Steps to reproduce

Install GPUStack server and and a  worker.
Add a label to the worker as shown in the screenshot.

Deploy a model locally on the worker and configure the worker seclector.

View the model instance.

Result

Failed to parse GGUF file: open mmap file: try lock file: open /opt/models/ollama/deepseek_coder: no such file or directory

Expected behavior

Environment

GPUStack version: main e4a7bf3
OS: MacOS + Ubuntu 22.04
GPU: Apple M2 + NVIDIA 4080

Additional context
Add any other context about the problem here.

GPUStack version: main 63c9248
Failed to schedule when --tensor-split is manually configured.

2024-11-21T13:09:09+08:00 - gpustack.server.controllers - DEBUG - Created model instance for model gemma-2-27b-it-Q8_0
2024-11-21T13:09:09+08:00 - gpustack.scheduler.scheduler - DEBUG - Scheduling model instance gemma-2-27b-it-Q8_0-ksgJz
2024-11-21T13:09:09+08:00 - gpustack.policies.worker_filters.gpu_matching_filter - DEBUG - model gemma-2-27b-it-Q8_0, filter gpus with gpu matching policy, instance gemma-2-27b-it-Q8_0-ksgJz
2024-11-21T13:09:09+08:00 - gpustack.policies.worker_filters.label_matching_filter - DEBUG - model gemma-2-27b-it-Q8_0, filter workers with label matching policy, instance gemma-2-27b-it-Q8_0-ksgJz
2024-11-21T13:09:09+08:00 - gpustack.policies.worker_filters.status_filter - DEBUG - model gemma-2-27b-it-Q8_0, filter workers with status policy, instance gemma-2-27b-it-Q8_0-ksgJz
2024-11-21T13:09:09+08:00 - gpustack.policies.candidate_selectors.gguf_resource_fit_selector - DEBUG - model gemma-2-27b-it-Q8_0, filter candidates with resource fit selector: find_single_worker_single_gpu_full_offloading_candidates, instance gemma-2-27b-it-Q8_0-ksgJz
2024-11-21T13:09:09+08:00 - gpustack.policies.candidate_selectors.gguf_resource_fit_selector - DEBUG - model gemma-2-27b-it-Q8_0, filter candidates with resource fit selector: find_single_worker_multi_gpu_full_offloading_candidates, instance gemma-2-27b-it-Q8_0-ksgJz
2024-11-21T13:09:09+08:00 - gpustack.policies.utils - DEBUG - Worker sealgpuhost4080 reserved memory:<PHONE_NUMBER>, reserved gpu memory: 0, allocatable memory:<PHONE_NUMBER>0, allocatable gpu memory: {1:<PHONE_NUMBER>6, 0:<PHONE_NUMBER>6}
2024-11-21T13:09:09+08:00 - gpustack.scheduler.scheduler - ERROR - Failed to find candidate for model instance gemma-2-27b-it-Q8_0-ksgJz: list index out of range
2024-11-21T13:09:09+08:00 - gpustack.scheduler.scheduler - ERROR - Failed to schedule model instance: cannot unpack non-iterable NoneType object

Verified on main bab9613


Added Terms of Use page

Added "Term of use" page to the website.
Issue: #300
https://github.com/user-attachments/assets/c1c13cfa-91fe-46dd-a5b0-102379b1919a

@vanshchauhan21 I have opened new PR for https://github.com/vanshchauhan21/CryptoTracker/pull/343 because of conflicts.
Please review it and level it with 3. Thank You!!


Aligned implements Eq, Ord, Hash if available

The motivations are to allow Aligned to be used easily in types
that are stored in sets and maps. Implementing PartialEq also allows
to make tests that assert_eq! that Aligned values are equal.

Thanks for merging https://github.com/japaric/aligned/pull/9 !
This is the last PR like this that I foresee.

Thanks!


Photino.NET 2.0.12 buggy?

Hi,
I updated the sample Photino template to version 2.0.12 from 2.0.11, and I got this when running dotnet run?
Also, the text comes up in Chinese?

We noticed an error on the macOS version of the Photino sample apps, preventing Photino to be opened on macOS. After compiling Photino.NET on macOS it worked on macOS but broke the Windows version of Photino. Please use 2.0.11 for now. Today we are trying to work through this issue and release a new version that resolves this issue on both operating systems.

We posted a new version to NuGet yesterday that fixes this issue. Please give it a try. Thanks.

Thanks it doesn't happen anymore


Blog Post: About Velo Promo

https://www.facebook.com/scottmmckinley/posts/10209373634484287

Northern California is lucky to have a thriving bike racing community. On any given weekend between January and September you can show up with a bike, tighten your shoes, and pit yourself against 100 other clean shaven, Lycra-clad, Type A freaks to see who's got the brain, the brawn, the perseverance, and desire to get to the line first. Norcal has produced dozens of world class bike racers and entertained thousands of weekend warriors over the years. It's a safe guess that there isn't a single US pro cyclist past or present who hasn't ridden a Velo Promo race at some point in their careers. And if you were to try to figure out why, it would be impossible for you not to find Robert A. Leibold and his organization Velo Promo right at the center of it all.

Bob has been thanklessly promoting local bike races since 1971. The races aren't particularly fancy; often you find yourself literally in the middle of nowhere sprinting for a finish line observed only by chickens and cows, with perhaps a nearly new water bottle as the prize. And that's perfectly fine, because local bike racing is all about grass roots grit and guts, and there's nothing quite like it in any other sport.
I raced in my first Velo Promo event in 1983 as a 14 year old kid, and I rode my last one yesterday - with something like 300 in between. This is a massive shout out and humble thank you to an unassuming guy who has been the backbone of NorCal bike racing for 45 years. Thanks Bob and Velo Promo!
Scott McKinley
1988 Olympics, Cycling


METRON-43: Refactor Deployment Scripts for Correctness and Ease of Use

Runs with single node Vagrant, multi-node Vagrant and multi-node cloud instance of 12 nodes.
Includes:
METRON-44: passwd_less_ssh.yml overwrites authorized_keys and leaves artifacts on local host
METRON-45: Remove host references from global variables
METRON-43: Deployment scripts should fail fast
METRON-47: Vagrant multi-node deployment script only deploys to one node
METRON-32: Added Ansible role to install and load data into MySQL

Sorry- forgot to run RAT last night. Fixed it this morning. There was one file, geoip_ddl.sql, that did not pass. I corrected that by adding a license to it.
I also excluded .iml files as they're .gitiignored.

Why pull all variables, even those unlikely to change, up to the inventory level?  For example, why define metron_jar_name in deployment/inventory/singlenode-vagrant/group_vars/all?
Previously these sorts of vars were pushed down into the role itself.  The logic being that these will rarely change and that the user need not worry about them.  For example, metron_jar_name is defined in incubator-metron/deployment/roles/metron_streaming/vars/main.yml.

Why install OpenJDK as part of deployment/roles/yaf/tasks/main.yml?  Previously the scripts were standardized on Oracle Java 8, which I believe is preferred for HDP, no?

That makes sense. Unless there's something badly broken here, can we push it to a separate issue? It was a major effort getting a passing run on all three integration tests and now that I'm there, I'm reluctant to  re-run them- it's a 2 hour end-to-end and I'm a little concerned about getting back into merge-land while that's happening.

That wasn't my change. Oracle is used when it's provided, open-jdk is
selected otherwise. In cases where there was no jdk without a side effect,
I continued that pattern.
On Tue, Feb 23, 2016 at 7:38 AM, nickwallen<EMAIL_ADDRESS>wrote:

Why install OpenJDK as part of deployment/roles/yaf/tasks/main.yml?
Previously the scripts were standardized on Oracle Java 8, which I believe
is preferred for HDP, no?
—
Reply to this email directly or view it on GitHub
https://github.com/apache/incubator-metron/pull/28#issuecomment-187682551
.

Also, seeing that promisc enablement was turned off as part of this change in deployment/vagrant/multinode-vagrant/Vagrantfile.  This needs to be on to sniff network traffic.

I don't see that change- which line?

# enable the hostmanager plugin
    config.hostmanager.enabled = true
 @@ -44,11 +44,6 @@ Vagrant.configure(2) do |config|
        node.vm.provider "virtualbox" do |vb|
          vb.memory = host[:memory]
          vb.cpus = host[:cpus]
 -
 -        # enable promisc mode on the network interface
 -        if host.has_key?(:promisc)
 -          vb.customize ["modifyvm", :id, "--nicpromisc#{host[:promisc]}", "allow-all"]
 -        end
        end

Got it, thanks- I'll get that back in, move the variables and re-test.

Testing passed with latest commit. Thanks for looking it over!


Does relay_all_normal mirror any bridged message to MUC?

We have set up an XMPP bridge with Rocket.Chat serving 2 MUCs and 1 JID (to a single user), using a common bridge-JID and defining separate webhooks for each room in RC.
We have the result, that messages mirrored to the JID are also seen in each MUC. Is this because we have enabled at each MUC:
- relay_all_normal: true
Or what exactly is this option good for?
                if relay_all_normal: self.outgoing_mappings['all_normal'].append(outgoing_webhook)
https://github.com/saqura/xmppwb/blob/master/CONFIGURATION.rst says:

The bridge can also relay all messages received from normal JIDs. Note that this will only trigger outgoing webhooks

So, does this mirror any message which is passing the bridge-JID to the MUC, where it is set true, even if the message was not targeted to the MUC?
In the sample configuration file, this option is set to true, which may be probably not the desired effect at least for our use cases.
bridge.conf.anonymized.txt

Or what exactly is this option good for?

The intention of relay_all_normal is to forward "normal" XMPP messages that the XMPP bot receives to Rocket.Chat. Here "normal" means messages not coming from a groupchat (MUC). So if you write directly to the XMPP bot (no matter your JID) without using the MUC, than this option makes those messages also appear in Rocket.Chat.

So, does this mirror any message which is passing the bridge-JID to the MUC, where it is set true?

I'm not sure whether I fully understand your question, but with this option no new XMPP messages should be created. It should only affect Rocket.Chat.

We have the result, that messages mirrored to the JID are also seen in each MUC.

So the third bridge in your config file that bridges messages between a Rocket.Chat room and a single XMPP JID also affects the messages sent to the MUCs of the other two bridges?

Thanks for explaining. Well, if any message that the bot receives is forwarded, then this is not what we want.
Yes, in this set-up, messages in the third bridge appear also in the Rocket.Chat room, which should bridge only to the corresponding MUC.
So disabling relay_all_normal  should prevent that. We'll test, but need a test machine first, can't do it on the production environment, not to confuse users in rooms.

I have updated the documentation in that regard and removed this setting from the sample configurations, since it might be confusing at first. I think this option is only needed for more specialized uses cases anyways.

Good to have the relay_all_normal not activated as default in the sample configuration, thanks for updating.
It seems we need some different kind of relaying messages from JID users, maybe you can give us a hint, how to do it. Let me briefly explain our case:
We need to serve Windows Phone users with Rocket.Chat rooms. There is no chance to build a WP App  for RC in a usable quality (we tried several paths, the problem is that webkit can't be included). So we thought we connect the WP users with xmpp. The only xmpp client for WP is IM+, but we discovered that this one does not support MUCs (the Android version does). So what we try to do is bridging JIDs to one RC room. That works in both ways (even using only one webhook for several JIDs), however if xmpp user A sends a message to the RC room, xmpp user B won't see it (also not if we set up a webhook for each user separately).
It seems that RC is not relaying messages from one webhook to another one.
Any chance to relay a message piped through xmppwb from one xmpp_endpoint to another one?

I understand the problem. The bridge currently works best when bridging one RC room to one XMPP MUC, as relaying messages between the XMPP parts of a bridge is not currently implemented. This might be a feature that I could add in a later version though. I have created a separate issue for this feature [#7], but I don't yet know when this will be implemented.

Great if that uses case could be rolled out with an enhancement of xmppwb and if it would not need any extension on RC, as asked here https://github.com/RocketChat/Rocket.Chat/issues/3721
We might back issue #7, as we have an urgent customer need for it, send me a PM to ras [ät] osalliance.com .

Thank you for your interest in this, however I can't currently accept financial contributions as I have only limited time to work on this project. This feature is something that I am interested in aswell though, so I am going to implement it. Please track #7 for further updates about this.
But I think the main use of this feature is the connection of multiple XMPP MUCs (and to keep the XMPP endpoints of a bridge in sync), and not the connection of multiple "normal JIDs", since MUCs are better suited for this. You should be aware that using it like this (while it will probably work) is a workaround and I don't know how well it scales with more than a few JIDs. A better solution (and user experience) would be if the XMPP client supported MUCs, so if you have the option it might be worthwile to approach the IM+ developers regarding MUC support.

Thank you for considering an extension to keep XMPP endpoints of a bridge in sync. For our use case it does not need to scale, we just have to include a few WP users via a XMPP bridge. I will then follow #7.  I am totally aware that MUCs would have been the better option, but the development of the IM+ clients stopped  2014 and it is the only XMPP product which is available for Windows Phones.

Ok, I am closing this issue then. I will update #7 for further information.


Saving and retreiving a string value from client storage adds quotation marks

Description
Saving and retreiving a string value from the client storage adds quotation marks around it.
Code example to reproduce the issue:
import flet
from flet import Page, TextField

class MyApp:
    @staticmethod
    def static_run(page: Page) -> None:
        MyApp(page)

    def __init__(self, page: Page):
        self.page: Page = page
        self.text_field = TextField(label="Value Store", value=self.get_text(), on_submit=self.save_text)
        self.page.add(self.text_field)
        self.text_field.focus()

    def get_text(self) -> str:
        key = "text"
        if self.page.client_storage.contains_key(key):
            return self.page.client_storage.get(key)
        else:
            return "Enter some text here."

    def save_text(self, e):
        key = "text"
        self.page.client_storage.set(key, self.text_field.value)

if __name__ == '__main__':
    flet.app(target=MyApp.static_run, assets_dir="assets")
    # flet.app(target=MyApp.static_run, assets_dir="assets", view=flet.WEB_BROWSER, port=8080)

Describe the results you received:

Start the application
Enter some text and press enter to save it to client storage

3. Stop and reopen the app. There are now quotations around the text

Flet version (pip show flet):
Version: 0.1.63

Operating system:
Arch Linux x86
Additional environment details:
I am using a venv with these requirements installed:

flet
py-staticmaps[cairo]

I tried adding a print to see the issue better.

And had this..

This is quite «bizard»/strange.

Can confirm - it's a bug. Thanks for reporting!

Fixed in the next release coming later this week.
For workaround unwrap the value with json.loads(), for example:
v = json.loads(page.client_storage.get("AAA"))

Thanks for reporting!

You're welcome. Many thanks for your quick replies. Should I close this issue then or leave it open until the next release?

It will be closed automatically when PR is merged.


[Issue-464] Temporarily remove Add custom network

Related issue

#464

Is your feature request related to a problem? Please describe.

Temporarily remove Add custom network

Describe the solution you'd like

Hide Add network button

Describe alternatives you've considered

No

Additional context

No

Pls check in PR #479


Explain in the DOC what to find in the DOM, in case the camera doesn't show up

Is your feature request related to a problem? Please describe.
Actually, when running BarcodeScanner.startScan() the camera does not show up.
I tried to debug & fix with the following https://github.com/capacitor-community/barcode-scanner/issues/7#issuecomment-744441148 or https://github.com/capacitor-community/barcode-scanner/issues/26 as explained in the doc, but some of the information written are for over a year and doesn't seems to fit the solution anymore.
I've tried to do the thing with the background color to the  element but couldn't find it.
Describe the solution you'd like
Add in the documentation what we're expected to see in the DOM, to know if we do have indeed it loaded correctly
Describe alternatives you've considered
Could also provide step, in the doc, to know directly what to do instead as reading the issue through and trying outdated solution.
Additional context
Maybe it should have been a bug report, not sure though

Okey, after digging a bit more, this should be the element we should see appearing in the DOM, just under the body tag

BESbswy

For me it wasn't appearing at all, so I did try to move the logic in the app.component.ts and then it worked.
It seems that the component who call the logic shall not be to low in the DOM tree.
For me it was the fourth Element from the route

This was something else, basically nothing will be shown in the DOM


GC overhead limit exceeded

Hi,
We're experiencing GC overhead limit exceeded every couple of days. Scheduler dies and it's not restarted by marathon.
So:
Mesos framework log:
    2015-09-11 09:53:33,589:6395(0x7f197eff5700):ZOO_INFO@zookeeper_init@786: Initiating client connection, host=master.mesos:2181 sessionTimeout=10000 watcher=0x7f19bd4d8860 sessionId=0 sessionPasswd=<null> context=0x7f19440015b0 flags=0
    2015-09-11 09:53:33,591:6395(0x7f1969ddd700):ZOO_INFO@check_events@1703: initiated connection to server [<IP_ADDRESS>:2181]
    2015-09-11 09:53:33,594:6395(0x7f1969ddd700):ZOO_INFO@check_events@1750: session establishment complete on server [<IP_ADDRESS>:2181], sessionId=0xd84f3f334beb0051, negotiated timeout=10000
    I0911 09:53:33.594823  6480 group.cpp:313] Group process (group(1)@<IP_ADDRESS>:57079) connected to ZooKeeper
    I0911 09:53:33.594868  6480 group.cpp:790] Syncing group operations: queue size (joins, cancels, datas) = (0, 0, 0)
    I0911 09:53:33.594898  6480 group.cpp:385] Trying to create path '/mesos' in ZooKeeper
    I0911 09:53:33.596679  6483 detector.cpp:138] Detected a new leader: (id='126')
    I0911 09:53:33.596853  6470 group.cpp:659] Trying to get '/mesos/info_0000000126' in ZooKeeper
    I0911 09:53:33.597592  6477 detector.cpp:452] A new leading master (UPID=master@<IP_ADDRESS>:5050) is detected
    I0911 09:53:33.597689  6479 sched.cpp:254] New master detected at master@<IP_ADDRESS>:5050
    I0911 09:53:33.597853  6479 sched.cpp:264] No credentials provided. Attempting to register without authentication
    I0911 09:53:33.600744  6470 sched.cpp:448] Framework registered with 20150703-081340-2281701386-5050-48159-0000
    2015-09-11 17:18:48,022:6395(0x7f197dff3700):ZOO_WARN@zookeeper_interest@1557: Exceeded deadline by 12ms
    Exception in thread "Thread-162360" java.lang.OutOfMemoryError: GC overhead limit exceeded
            at java.lang.String.substring(Unknown Source)
            at java.lang.String.subSequence(Unknown Source)
            at com.google.protobuf.TextFormat$TextGenerator.print(TextFormat.java:526)
            at com.google.protobuf.TextFormat$Printer.printSingleField(TextFormat.java:334)
            at com.google.protobuf.TextFormat$Printer.printField(TextFormat.java:283)
            at com.google.protobuf.TextFormat$Printer.print(TextFormat.java:273)
            at com.google.protobuf.TextFormat$Printer.access$400(TextFormat.java:248)
            at com.google.protobuf.TextFormat.print(TextFormat.java:71)
            at com.google.protobuf.TextFormat.printToString(TextFormat.java:118)
            at com.google.protobuf.AbstractMessage.toString(AbstractMessage.java:106)
            at java.lang.String.valueOf(Unknown Source)
            at java.lang.StringBuilder.append(Unknown Source)
            at java.util.AbstractCollection.toString(Unknown Source)
            at io.mesosphere.mesos.util.ProtoUtils.protoToString(ProtoUtils.java:50)
            at io.mesosphere.mesos.frameworks.cassandra.scheduler.CassandraScheduler.resourceOffers(CassandraScheduler.java:112)
    I0914 05:07:29.821909  6475 sched.cpp:1623] Asked to abort the driver
    I0914 05:07:29.825697  6475 sched.cpp:856] Aborting framework '20150703-081340-2281701386-5050-48159-0000'
    I0914 05:07:30.358397  6396 sched.cpp:1589] Asked to stop the driver
    I0914 05:07:30.361979  6473 sched.cpp:831] Stopping framework '20150703-081340-2281701386-5050-48159-0000'

Then In marathon we're getting: (But it never get's scaled to 1)
[2015-09-14 05:07:30,415] INFO Need to scale /cassandra/cluster from 0 up to 1 instances (mesosphere.marathon.SchedulerActions:529)

The json for marathon is:  (We only copied cassandra.tar.gz and java to local web server from downloads.mesosphere.io)
    {
      "id": "/cassandra/cluster",
      "instances": 1,
      "cpus": 0.5,
      "mem": 512,
      "ports": [10050],
      "uris": [
        "http://repo.marathon.mesos:9022/cassandra-mesos-0.2.0-1.tar.gz",
        "http://repo.marathon.mesos:9022/jre-7u76-linux-x64.tar.gz"
      ],
      "env": {
        "MESOS_ZK": "zk://master.mesos:2181/mesos",
        "JAVA_OPTS": "-Xms256m -Xmx256m",
        "CASSANDRA_CLUSTER_NAME": "kong-cluster",
        "CASSANDRA_ZK": "zk://master.mesos:2181/cassandra-mesos",
        "CASSANDRA_NODE_COUNT": "3",
        "CASSANDRA_RESOURCE_CPU_CORES": "2.0",
        "CASSANDRA_RESOURCE_MEM_MB": "2048",
        "CASSANDRA_RESOURCE_DISK_MB": "2048",
        "CASSANDRA_HEALTH_CHECK_INTERVAL_SECONDS": "60",
        "CASSANDRA_ZK_TIMEOUT_MS": "10000"
      },
      "cmd": "$(pwd)/jre*/bin/java $JAVA_OPTS -classpath cassandra-mesos-framework.jar io.mesosphere.mesos.frameworks.cassandra.framework.Main",
      "constraints": [
            ["net_video", "CLUSTER", "false"]
      ],
      "healthChecks": [
        {
          "gracePeriodSeconds": 120,
          "intervalSeconds": 30,
          "maxConsecutiveFailures": 0,
          "path": "/health/cluster",
          "portIndex": 0,
          "protocol": "HTTP",
          "timeoutSeconds": 5
        },
        {
          "gracePeriodSeconds": 120,
          "intervalSeconds": 30,
          "maxConsecutiveFailures": 3,
          "path": "/health/process",
          "portIndex": 0,
          "protocol": "HTTP",
          "timeoutSeconds": 5
        }
      ]
    }

To get it up and running again we had to manually restart the cassandra framework app in marathon.
Is this a Marathon problem or the framework ?
thanks.

hey @samek
It would be great to understand the details of how you got an OOM situation.  Are you dealing with a large cluster env?    Also the logs are incomplete on the mesos log.   It seems something requested the framework to stop.  Was this a shutdown request? or a dcos package uninstall?
regarding the marathon restart failure.  The likely cause of this based on the information provided is this....  If a framework was asked to be shutdown, then a restart of cassandra would not startup based on values in zookeeper.  In order to start cassandra with the same framework name, it is necessary to clear zk.   This appears to be working as expected.
let me know if there is more to follow up on here.

@kensipe
My cluster is small in all views, cassandra: 3 nodes, mesos: 20 slaves.
No human actually did request the shutdown or tried to uninstall it. This just happens after a few days. (repeatable)
I've added -XX:-UseConcMarkSweepGC to JAVA_OPTS (currently JAVA_OPTS=-Xms256m -Xmx256m -XX:-UseConcMarkSweepGC) in marathon json. Currently it's up for 5 days.
When it stops again (if it does) I'll try getting more logs out of it.

This repository is deprecated. Please use the latest supported framework here: https://github.com/mesosphere/dcos-cassandra-service, and provide feedback for us here:  https://dcosjira.atlassian.net/browse/CASSANDRA.


outline always loading

VSCode Version:1.28.2
OS Version: macos 10.14

Steps to Reproduce:

when i write vue file ,i find my vscode outline always loading .
if i needn't outline how can i disable it

Does this issue occur when all extensions are disabled?: Yes/No

#https://github.com/neilsustc/vscode-markdown/issues/42 #


Packaging

We should determine an effective strategy to package and distribute the polyfill. Looking at https://github.com/GoogleChromeLabs/container-query-polyfill it looks like we can use esbuild to produce module and commonjs artifacts. Is that good enough? Are there better approaches?

As of f0435e24ccbdec46363f8200d8828b3afa1a029c we now have a build step that produces esm and iife bundles inside a dist folder. Now we just need to actually publish the package to npm, would love to get guidance on the best way to do that, preferably in some automated way.
@mirisuzanne the demo site is now broken because index.html now refers to /dist/css-toggles.js, which doesn't exist unless you run yarn build. Could you add that to the Netlify config? Happy to do it myself if you grant me access

Thanks! Just updated the config and the demo site is back online

We now have automated releases whenever we push to main (publishes to next) or stable (publishes to latest). Changelog is auto-generated and available at https://github.com/oddbird/css-toggles/releases.
This also allows people to use the polyfill via CDNs like unpkg.


 Other then a vessel for joke delivery
but this is nonsense.
@doc """
Function of a surface with two hills.
"""
@spec boobs(float, float) :: float
def boobs(x, y) do
  x = (x - 40) / 4
  y = (y - 40) / 4

  :math.exp(-:math.pow(:math.pow(x - 4, 2) + :math.pow(y - 4, 2), 2) / 1000) +
    :math.exp(-:math.pow(:math.pow(x + 4, 2) + :math.pow(y + 4, 2), 2) / 1000) +
    0.1 * :math.exp(-:math.pow(:math.pow(x + 4, 2) + :math.pow(y + 4, 2), 2)) +
    0.1 * :math.exp(-:math.pow(:math.pow(x - 4, 2) + :math.pow(y - 4, 2), 2))
end

I like jokes probably more than the next person unless they offend or cause
potential harm. Also I am just as guilty for this kind of thing, because we all
are idiots. MISTAKES MADE. LESSONS LEARN. WE GROW, IF GIVEN ROOM.
Formally and moreover:

... this form of code and practice may cause potential harm to some all
participants in OSS. In a larger overarching context, condones and perpetuates
this insidious behavior in a larger community. Dudes, basically ...

Not my intention to be self-righteous judge and high-horse executioner.
They may not be so lenient in thought and/or action.  So to speak.

Sounds sane to me.
Function is used for testing purposes, so I don't want to remove it, unless you suggest some other surface-generating function(s) to replace it.
But I renamed it to twin_peaks/2 for now.


Thellimist/pi 1192 refactor snake_case to camelCase

Fixes https://github.com/cloudflare/Cloudflare-CPanel/issues/129
I've formatted all the files one by one. I'm %90 confident that there won't be any errors. Tests pass. I've tested on dev environment, checked the logs but I haven't tested DNS stuff. So far so good.
I know it's hard to review a change like this. I'd like you to review two things:

Any function name I have changed which may be used somewhere like a string (like in routes)
This perl file. I tried to change all results in search which matches get_host_api_key. I'm not sure though. 5bad444
Any other edge case you might think of which is not php

The perl function is called here so I think you're good.
Rather than code review this I'd rather merge it and then test it heavily on my development environment.  We won't do a cPanel release for a while so there will be time to hammer this.


return ErrResourceNotFound if app not exist

Codecov Report

Merging #200 (a8e73dc) into master (cca9638) will decrease coverage by 0.04%.
The diff coverage is 33.33%.

@@            Coverage Diff             @@
##           master     #200      +/-   ##
==========================================
- Coverage   68.41%   68.37%   -0.05%
==========================================
  Files          71       71
  Lines        4924     4930       +6
==========================================
+ Hits         3369     3371       +2
- Misses       1124     1126       +2
- Partials      431      433       +2

Impacted Files
Coverage Δ

api/application.go
77.57% <33.33%> (-0.35%)
:arrow_down:

api/node.go
71.29% <33.33%> (-0.36%)
:arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update cca9638...a8e73dc. Read the comment docs.


Revert "[kotlin] remove constructor method from generated code (#3156)"

This reverts commit b0582584a9beeedf72d416582d713d7099753906.
Fix for Issue #4820

Reverting this is the only solution? I believe there should be other options to fix that.
@omuomugin can you please take a look?

Hey, thanks for the quick reply!
I'm almost certain that the changes by @omuomugin could never have worked because they violate Kotlin's type system.
However I'm a bit intrigued that no one else seems to have run into these problems before, during the past half year...you'd think with >3000 weekly downloads for graphql-codegen/kotlin others would have reported this problem

For easier review, here is a Repl to illustrate the problem: https://repl.it/@xwalled/CodegenCompilerProblem
Lines 20-22 is what versions of graphql-codegen/kotlin prior to 1.10.0 would have created from the query definition in lines 9-11.
Line 29 is what the same query definition gets converted to, as of v.1.10.0.
To see the desired behavior Run the Repl once (no output is shown, but we get no compiler errors).
To see the error behavior, comment out lines 20-22 and uncomment line 29. Then run the Repl again.
=> you'll get a compiler error from line 36, where we try to instantiate the QueryItemArgs
from the graphql arguments we received.

error: type mismatch: inferred type is Map<String, Any> but Long was expected

Got it. Thank you @danielw93 :)


Use singular version of commits when only 1 commit is made

This should be singular:

Applies for all repository home pages.

Report it to GitHub. This is a bug, but not worth the effort since it’s so rare and minimal.


Add dynamic prompt color

Added support for automatically changing the prompt color.

Looks good!

I want detail better since I was in a bit of a hurry before; I created this pr so anyone can with their own interpretation of the prompt trait change the color that was previously by default to blue.

Do you want to make additional changes before merging?

No thanks, for me it's fine