Proposal: Interval Types / Inequality Types

Related Proposals:

Range as Number type: https://github.com/microsoft/TypeScript/issues/15480
Range type for arrays: https://gist.github.com/rbuckton/5fd81582fdf86a34b45bae82d842304c
NaN / integer / float type: https://github.com/Microsoft/TypeScript/issues/28682

This proposal is partly based on @AnyhowStep's comment and describes the addition of an IntervalType to TypeScript.
📃 Goals / Motivation
Provide developers with a type system that prevents them from forgetting range checks on numbers similar to how we prevent them from forgetting string validation and numeric constant checks.
An interval primitive defines a range of numbers, limited up to a specific value. For example, less than 10 is an interval boundary (this wording may be subject to change).
Non-Goals

Integer types
Dependent types
NaN or (-)Infinity literal type
Distinction between double and floats

Definitions
The idea is to extend type-narrowing for relational comparisons (<, >, <=, >=), in addition to the currently existing mechanism to narrow by equality (== !=, ===, !==).
The emerging type is one that lays between literal types (a type with a single value) and the number type.
Syntax
NonArrayType := ...
                | IntervalType

IntervalType := '(' RelationalOperator  IntervalTypeLimit ')'
RelationalOperator  := '<' | '<=' | '>' | '>='
IntervalTypeLimit   := NumberLiteral

So, in code we'd do something like this:
export interface IntervalType extends Type {
    limit: IntervalTypeLimit;
    constraint: RelationalOperator;
}

export type RelationalOperator =
    | SyntaxKind.LessThanToken
    | SyntaxKind.LessThanEqualsToken
    | SyntaxKind.GreaterThanToken
    | SyntaxKind.GreaterThanEqualsToken
    ;

Side-Note: There is also a suggestion by @btoo to use the new intrinsic type and generics instead of a distinct syntax (like GreaterThan<5>).
Semantics
// a must be a positive number
let a: (>0) = 1;
a = -1; // Error, cannot assign -1 to (>0)

function takePositiveNumber(v: (>0)) {
    // ...
}
takePositiveNumber(a);
takePositiveNumber(-1); // Error, cannot assign -1 to (>0)

Currently, IntervalTypeLimit can only ba a NumberLiteral. Allowing references to other types would make this feature significantly more different. There may be a useful opportunity when it comes to generics (see below).
Assignability
A variable of type A is assignable to one of type B:
let a: A;
let b: B = a; // ok, iff...

Control-Flow
The core idea is that we extend type narrowing and combine that with union and intersection types:
let a: number = 12;

if (a > 10) {
    a; // (>10)

    if (a < 20) {
        a; // (>10) & (<20)
    }

    a; // (>10)
}

if (a > 10 || a < 0) {
    a; // (>10) | (<0)
    if (a > 10) {
        a; // (>10)
    } else {
        a; // (<0)
    }
}

Union and Intersection Types
Interval types can be used in an intersection type:
type Probability = (>=0) & (<=1);
function random(): Probability { /* ... */ }

A union or intersection type may only contain at most two interval boundaries:

(>10) | (>20) will be reduced to (>10)
(>10) & (>20) will be reduced to (>20)
(<10) & (>10) will be reduced to never
(<10) | (>10) will not get simplified, it remains (<10) | (>10)
...
For (>=1) | (<1), see below

Other cases how interval boundaries interact with existing types:

number | (>1) is reduced to number
number & (>1) is reduced to (>1)
(>1) & <any non-number type> is reduced to never

Subject for discussion: Handling of (>1|2|3)
It may be appropriate to expand this as (>1) | (>2) | (>3) (which would be normalized to (>1)). Or we just prohibit this kind of use.
The case of (>=1) | (<1)
Consider this code:
let a: number = 10;
if (a > 9) {
	a; // (>9)
} else {
	a; // number
}

In the else branch, we widen the type back to number instead of narrowing to (<=9). This is because we'd also branch to else, if a would be NaN. So, number implicitly contains NaN.
If a variable's type is/contains an interval boundary, its value cannot be NaN.
This opens up the question on how we should handle (>=1) | (<1). Semantically, it is equivalent to number \ {NaN}, so number would not be equivalent here.
It would feel more natural to the developer if (>=1) | (<1) would become number (including NaN), since not reducing it to number would look weird.
If we'd have negated types (#29317) as well as a NaN type, we could model this as number & not NaN. This may outweigh practical use and would be against the design rules (see the third entry in "Non-Goals"; this is an opinion).
We also don't have a NaN type and there is currently no intent to introduce it.
If we'd decide against the simplification to number, it would make discriminated unions work more easily.
Discriminated Unions via Interval Boundary Types?
Having discriminated unions based on intervals is not yet evaluated that much. Considering the problem with (>=1) | (<1), this may not be possible. For example:
type A = {
    success: (>0.5)
    data: boolean;
};
type B = {
    success: (<=0.5);
    message: string;
};
type Result = A | B;
Result["success"]; // number

declare let res: Result;
if (res.success > 0.5) {
    res.data; // ok
} else {
    res; // still `Result`, because in the `else` branch, res.success is still `number`
}

Discriminated unions would work if the else branch of the example in (>=1) | (<1) would resolve to (<=9). For that to work, we need to drop NaN.
We could also solve this problem by not simplifying (>=1) | (<1) to number, so Result["success"] would be (>0.5) | (<=0.5) instead of number.
Normalization of Unions and Intersections
When n interval boundaries are unified or intersected, the result will always be a single boundary, exactly two boundaries, a number literal, number or never.
Normalization is commutative, so one half of the table is empty.
Normalizing A | B:

A\B
(> y)
(>= y)
(< y)
(<= y)

(> x)
(> min(x, y))
y <= x ? (>= y) : (> x)
y > x ? number : (> x) or (< y)
y < x ? (>= x) or (<= y) : number

(>= x)
-
(>= min(x, y))
y >= x ? number : (>= x) or (< y)
y < x ? (>= x) or (<= y) : number

(< x)
-
-
(< max(x, y))
y < x ? (< x) : (<= y)

(<= x)
-
-
-
(<= max(x, y))

(due to a limitation of markdown tables, we use or instead of |)
Normalizing A & B:

A\B
(> y)
(>= y)
(< y)
(<= y)

(> x)
(> max(x, y))
y <= x ? (> x) : (>= y)
y > x ? (> x) & (< y) : never
y > x ? (> x) & (<= y) : never

(>= x)
-
(>= max(x, y))
y > x ? (>= x) & (< y) : never
y < x ? never : (y == x ? y : (>= x) & (<= y))

(< x)
-
-
(< min(x, y))
x > y ? (<= y) : (< x)

(<= x)
-
-
-
(<= min(x, y))

If an interval is equality-compared to a literal, we either narrow down to the respective literal or never.
Further narrowing a boundary intersection via control flow will not increase the number of interval boundaries present in the type:
let a: number = 10;
if (a > 0) {
    a; // (>0)
    if (a < 10) {
        a; // (>0) & (<10)
        if (a < 5) {
            a; // (>0) & (<5)
            if (a > 4) {
                a; // (>4) & (<5)
                if (a > 5) {
                    a; // never
                }
            }
        }
    }
}

Assertions

We can do assertions like a as (>1) (where a is a number or another interval), just like with number literal types.

Widening and Arithmetics
Similar to literal types, type-level arithmetics are not supported and coerce to number. For example:
let a: (>1) = 4;
let b = a + 1; // _not_ (>2), but number

Also, applying operators like ++ and -- let the type widen to number:
let a: 1 = 1;
a++;
a; // number

let b: (>=1) = 1;
b++;
b; // number

However, due to the way interval types are always reduced to a maximum of two interval boundaries, it may be feasable to do type-level arithmetics. This proposal currently does not intent to do this.
Loops
With intervals, we can be more exact about loop variables. For example, narrowing a simple c-style for loop would come "for free" if we have flow-based type-narrowing that works for if-then-else:
for (let i = 0; i < 10; ++i) {
	i; // (<10)
}

Explanation on what happens:
for (
	let i = 0; // number
	i < 10; // i -> (<10)
	++i // i -> number again
) { }

// Equivalent to

let i = 0; // number
while (i < 10) {
	i; // (<10)

	++i; // number
}

With a little more work, it may be possible to let i be (>=initial-value) & (<10). But due to the type coercion that ++ causes, this is not possible out-of-the-box.
Enum Interaction
It may be an interesting addition to allow enum literals as limit value, so we can type something like this:
function isListTerminator(kind: (< ParsingContext.Count)): boolean {
    // ...
}

isListTerminator(ParsingContext.Count); // Error
isListTerminator(ParsingContext.ClassMembers); // Ok

type AssignmentOperator = (>=SyntaxKind.FirstAssignment) & (<=SyntaxKind.LastAssignment);
function isAssignmentOperator(token: SyntaxKind): token is AssignmentOperator {
    // (return type could also be inferred here)
    return token >= SyntaxKind.FirstAssignment && token <= SyntaxKind.LastAssignment;
}

It should also be possible to pass interval types to functions that take enums (just like numbers).
Generics
Generics may be valuable to support in this proposal, when they resolve to a literal type.
Consider this implementation of clamp:
function clamp<TMin extends number, TMax extends number>(min: TMin, max: TMax, value: number): (>=TMin) & (<=TMax) {
    if (value < min)
        return min;
    if (value > max)
        return max;
    return value;
}

const v = clamp(1, 2, 3); // (>=1) & (<=2)

const a = 1;
const b = 2;
const c = clamp(a, b, 3); // (>=1) & (<=2)

// if one of the parameters is a `number`, the result would be widened and normalized:
let d: number = 1;
let e: 2 = 2;
let f = clamp(d, e, 3); // (>=number) & (<=2) -> number & (<=2) -> (<=2)

let h: number = 1;
let i: number = 2;
let j = clamp(h, i, 3); // (>=number) & (<=number) -> number & number -> number

💻 Use-Cases
We could statically type/document some APIs more explicitly, for example:

Math.random
Math.abs
clamp
Number.range
Math.sin/cos/...
a % b if a is assignable to (>=0) and b resolves to a number literal (falling back to number otherwise)
[your example here]

Functions could express their assumptions about parameters.
They would be useful to force the developer to check if they are in range before passing (similar to literal types):
declare let a: number;

function takeProbability(p: (>=0) & (<=1)) { /* ... */ }

takeProbability(a); // Error, cannot assign number to (>=0) & (<=1)
if (a <= 1) {
    takeProbability(a); // Error, cannot assign number to (>=0)
    if (a >= 0) {
        takeProbability(a); // ok
    }
    takeProbability(a); // Error, cannot assign number to (>=0)
}

function takePercentage(p: (>=0) & (<=1)) { /* ... */ }
// in the case of takePercentage, the developer will notice that it expects something in the range of 0-1 instead of 0-100 because he will receive an error.

type SafeIntegerRange = (<= Number.MAX_SAFE_INTEGER) & (>= Number.MIN_SAFE_INTEGER);

Feel free to add more use-cases!
✅ Viability Checklist

[x] This wouldn't be a breaking change in existing TypeScript/JavaScript code

When interval types are not used, TS behaves the same

[x] This wouldn't change the runtime behavior of existing JavaScript code
[x] This could be implemented without emitting different JS based on the types of the expressions
[x] This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, new syntax sugar for JS, etc.)
[x] This feature would agree with the rest of TypeScript's Design Goals.

Subject for discussion

🔍 Search Terms / Keywords

interval type
interval primitives, boundaries

I wanted to get into the TS compiler, so I've implemented a simple prototype of this type system extension. You can play around with it here:
https://nikeee.github.io/typescript-intervals
These features are not implement / have bugs:

Discriminated unions (see above for reason why)
Enum support
Generics
else branch sometimes does not receive the correct flow type

It would be useful if we could do:
let a: number = 10;
if (a > 9) {
	a; // (>9)
} else {
	a; // (<=9) | NaN
}

Making NaN a viable type would pair nicely with this (proposal https://github.com/Microsoft/TypeScript/issues/28682)

Some other things to explicitly disregard as goals, but may help steer design and discussion:

positive vs. negative positional vectors
periodic vs. aperiodic series
convergent vs. divergent series

These features, if they existed, would allow for compile-time detection of changes to a value in a "direction" that is not supported. For instance, a model of a closed system with some variable representing a range of values for Entropy. Not only is it (>=0) & (<=1), it must always trend in one direction only.
From there, a periodic revolution allows for a "reversing" of the positional vector, but only if they exceed the threshold of the upper limit, and immediately returns to the lower limit. Support for this is not obvious to me, and would be difficult.
The third point is similar in that it's not obvious, but in my opinion would be even more difficult to do correctly. Given a positional vector and a limit, how can brief violations of this constraint be tolerated in order to facilitate convergent series which approximate some transcendental value, such as φ?

I'm not sure I can just do this, but I'd like to suggest the % type where x extends (% y) (assuming both x and y are number literals) iff x % y == 0. This would effectively make type integer = (% 1) possible, as well. Interaction with <, > etc should probably be left untouched except maybe (> 0) & (< 5) & (% 3) should become 3, and (> 0) & (< 2) & (% 3) becomes never
Might've also been proposed already, but I couldn't find anything

So did it ever get implemeneted?

Regarding to the roadmap, no.

In its current state, it's just a proposal that is subject for discussion. So feel free to post some questions, use-cases and enhancements!

This would be nifty!  I ran into a use case while building a Markdown parser, that shows some interaction with template literal types as well.  Here's a very simplified version:
type HeadingLevel = 1|2|3|4|5|6;

function makeHeading(level: HeadingLevel): HTMLHeadingElement {
	// already correctly inferred as a HTMLHeadingElement
	return document.createElement(`h${level}` as const);
}

function getHeadingLevel(text: string): HeadingLevel|null {
	let match = /(#{1,6}) (\w+)/.exec(text);
	if(match === null) { return null; }

	let pounds: string = match[1];
	// would be nice if this were inferred to be (>=0)
	let level = pounds.length;

	// interval types could help to avoid this cast!
	if(level > 0 && level <= 6) { return level as HeadingLevel; }

	return null;
}

let n = getHeadingLevel("#### heading");
if(n !== null) { makeHeading(n); }

Here's my use case.  I want to define a union type for an API result, something like this:
type ApiResult<T> =
  | {
      total_results: 0;
    }
  | {
      total_results: 1;
      data: T;
    }
  | {
      total_results: number; // integer >= 2
      data: T[];
    };

so that I can later narrow the type by checking the value of total_results, e.g.:
let apiResult: ApiResult<string>;

if (apiResult.total_results > 1) {
  // apiResult.data is string[]
} else if (apiResult.total_results === 1) {
  // apiResult.data is string
} else {
  // apiResult.data is not present
}

Maybe another wording could be something like "Inequality Types" originating from inequalities

is it inferable in extends clause ?
type MinRange<I extends number> = I extends (>= infer T) ? T : never;
type T0 = MinRange<(>= 100)>; // T0 will be 100

That should be possible aswell (when generic support is implemented, the playground does not support that).

can it work well with template type ?
type Hex = (>=0) & (<= 255)
type HexStr = `0x${Hex}`

can control flow analysis be able to infer the final types in an addition between two vars typed with Inequality Types ?
function add(a: (>= 1), b: (>= 2)) {
    return a + b;
}
type T0 = ReturnType<typeof add>; // T0 should be infered to (>= 3) by tsc

that would probably be considered type level arithmetic so no

can it works well with template type ?
type Hex = (>=0) & (<= 255)
type HexStr = `0x${Hex}`

I don't think that this would work as expected, since numbers are floats in the end and 0x0.30000000001 would be valid as well.

how can i use Interval Types to create an integer range ?
type MyRange1 = 1 | 2 | 3 | 4 | 5;
type MyRange2 = (>=1) & (<=5); // how to get 1 | 2 | 3 | 4 | 5 from Interval Types

type MyRange2 = (>=1) & (<=5);

Why would something like that deny e.g. const x: MyRange2 = 2.54;?

This proposal does not define any kind of integer semantics and it's currently not the goal. Integer types which have number as a base type seem to be out-of-scope.
However, if interval types are a thing, they could also be implemented for bigints (this proposal currently only defines them with number as a base-type), just like number/bigint literal types.
In fact, they would be much simpler using bigint, because there is no NaN.
One thing that would also be possible is that iff some kind of int exists, we could do stuff like (>0) & (<10) & int, which would be equivalent to 0 | ... | 10. But as int types aren't a thing, this likely won't be possible.

Rather than introduce a new syntax to express an interval-type with the existing type T =  declaration, couldn't a more general-solution, that uses arbitrary expressions or a single-parameter pure-function to express the constraints on the type, be used? This way:

No new syntax needs to be introduced and supported by the compiler .
The exact same code in TypeScript's internals that are used to detect type-narrowing can be re-used to define type-narrowing.
The end-result is a general precondition/postcondition checker, which is basically the same thing as Code Contracts.
The same (pure) functions to define the narrowed-type can be used as type-guards.

So rather than this:
type Probability = (>=0) & (<=1);
function random(): Probability { /* ... */ }

Have:
type Probability = number & isUnitInterval;
function isUnitInterval( value: number ): boolean
    return 0 <= value && value <= 1;
}

Note that isUnitInterval must be a boolean-returning pure function (no global/closure/static state, except literal constants and other pure-functions) that accepts a single argument value. The type of the argument doesn't need to be unknown provided the rest of the type definition is compatible with the parameter-type (in this case the number & part allows isUnitInterval to have a number-typed parameter.
...but rather than handle ranges and intervals as a special-case in the type-system (as TypeScript currently handles equality, as far as I know), this approach should be inherently more general - at the cost of making the flow-analysis keep track of every potentially type/value-narrowing operation though a function (though at least this way the in operator would actually be useful).
In the case of the cascading if statements, the flow-analysis logic would be similar to what's suggested, except it doesn't absolutely require that ranges/intervals be narrowed, instead each extra condition simply appends a new intersection to the subject variable's type, which can then be compared to the constraints imposed by the pure function - which, if my CS education is correct, can be reduced to a boolean satisfiability problem.

Alternative syntax would be to do it Python style or via set-interval notation:
type radix = 2 <= i32 <= 36

It would read as "type radix is an i32 between 2 and 23"

As a react dev, I'd really appreciate this. My current use case is allowing the user to specify the width of a cell in a css grid which has a max of 12 columns (at least in the framework I'm using). With your proposed syntax, I think it would be something like this:
interface CellProps {
  content: React.ReactNode;
  width: (>0) | (<=12);
}

const CellThing = ({ content, width }: CellProps) => ....

I'd also suggest some syntax sugar for ranges like other languages. Something like: (0..12)

As a react dev, I'd really appreciate this. My current use case is allowing the user to specify the width of a cell in a css grid which has a max of 12 columns (at least in the framework I'm using). With your proposed syntax, I think it would be something like this:
interface CellProps {
  content: React.ReactNode;
  width: (>0) | (<=12);
}

const CellThing = ({ content, width }: CellProps) => ....

I'd also suggest some syntax sugar for ranges like other languages. Something like: (0..12)

This would be awesome! A few use cases I could think of
type Key = NestedKeyOf<SomeObject, Depth> // no more infinite recursion warning or hard coding this

type ProcessPaymentAction = {
     type: "process-small-payment",
     payload: (<100)
} | {
    type: "process-large-payment",
    payload: (>=100)
}

type MatrixIndex<Matrix extends any[][] as const> =
     [
       ( <Matrix["length"] ),
       ( <Matrix[number]["length"] )
     ] // I don't know if this is possible but eventually would be possibly?

Very interesting proposal. My use case is that I have an object that represents a device memory. The memory goes from 0 to 65535 and I would love to be able to declare the type like this:
type Memory = { [key: (>=0) & (<=65535)]: number }

instead of having to type every number, and likely forget one, causing an error for the future myself.

Well, this good proposal which propose to finally complete Sigma-type (Σ type) and Π type from Dependent Types theory (TypeScript supports a limited form where you can only make сщтскуеу enumerations).

One thing I'd like to request is that conditional types be improved with regards to number literals, number intervals and numbers.
e.g.
type Test1 = 5 extends NumberRange<0, 10> ? true : false; // -> true
type Test2 = NumberRange<0, 10> extends number ? true : false; // -> true
type Test3 = number extends NumberRange<-Infinity, Infinity> ? true : false; // -> false

Imo creating a generic type is better than simply throwing a >= between parenthesis. Like this answer which supposedly only works for small numbers.

Yeah, maybe an intrinsic implementation for generic types like GreaterThan<T extends number | bigint> would be more DX-friendly.

I support the proposal. It can be implemented via intrinsic types or via a new syntax. This playground shows how the intrinsic generic types could behave by outputting the constrained types as strings for manual evaluation.
Instead of limiting the syntax to (> 0) I propose (number > 0). I am not sure about the full syntax implications, but it might look something like this in real world:
type Fill = {
  value: string
  repeat: number > 0
};

It would make this feature more open for extension, like putting any union of number literals or constrained number types on the left of the operator while the union on the right side is a bit meaningless, but still possible and still yields the expected result if the intrinsic generic types are distributive.
type PositiveNumbers = GreaterThan<number, 0>;// `(${number} > 0)`
type NegativeNumbers = LessThan<number, 0>; // `(${number} < 0)`

type Probability = GreaterThanOrEqual<number, 0> & LessThanOrEqual<number, 1>;
// resolves to `(${number} >= 0)` & `(${number} <= 1)`

// Subject for discussion: Handling of (>1|2|3)
type SubjectForDiscussion = GreaterThan<number, 1 | 2 | 3>;
// resolves to `(${number} > 1)` | `(${number} > 2)` | `(${number} > 3)`
// would be reduced to `(${number} > 1)`

// (>10) | (>20)
type Reduction1 = GreaterThan<number, 10> | GreaterThan<number, 20>;
// resolves to `(${number} > 10)` | `(${number} > 20)`
// would be reduced to `(${number} > 10)`

// The same, but rely on the distributive property
// (>10) | (>20)
type Reduction1_ = GreaterThan<number, 10 | 20>
// distributes to `(${number} > 10)` | `(${number} > 20)`
// would be reduced to `(${number} > 10)`

// (>10) & (>20)
type Reduction2 = GreaterThan<number, 10> & GreaterThan<number, 20>;
// resolves to `(${number} > 10)` & `(${number} > 20)`
// would be reduced to `(${number} > 20)`

// The same, but rely on the distributive property
// (>10) & (>20)
type Reduction2_ = GreaterThan<number, 10 | 20>;
// distributes to `(${number} > 10)` & `(${number} > 20)`
// would be reduced to `(${number} > 20)`

//
// Now apply the same operation on subsets of number
//
type Stars = 0 | 1 | 2 | 3 | 4 | 5;

type PositiveReviews = GreaterThan<Stars, 2>;
// distributes to
//   "(0 > 2)" | "(1 > 2)" | "(2 > 2)" | "(3 > 2)" | "(4 > 2)" | "(5 > 2)"
//   "(never)" | "(never)" | "(never)" | "(3)"     | "(4)"     | "(5)    "
//
//   3 | 4 | 5

type PositiveButNotExcellentReviews = LessThan<PositiveReviews, 5>;
// distributes to
//   "((0 > 2) < 5)" | "((1 > 2) < 5)" | "((2 > 2) < 5)" | "((3 > 2) < 5)" | "((4 > 2) < 5)" | "((5 > 2) < 5)"
//   "((never) < 5)" | "((never) < 5)" | "((never) < 5)" | "(3 < 5)      " | "(4 < 5)      " | "(4 < 5)      "
//   "(never)      " | "(never)      " | "(never)      " | "(3)          " | "(4)          " | "(never)      "
//
//   3 | 4

If you were just wanting to detect whether a value was a number or a numeric literal (e.g. 4), then this will works:
type IsNumericLiteral<T> = number extends T ? false : T extends number ? true : false;

type T = IsNumericLiteral<5>; // true
type U = IsNumericLiteral<number>; // false

You might also want to detect whether you are creating a union of types, too, which can be done like so:
type UnionToIntersection<U> = (U extends any ? (k: U) => void : never) extends (
  k: infer I
) => void
  ? I
  : never;
type IsUnion<T> = [T] extends [UnionToIntersection<T>] ? false : true;
type Not<A> = A extends true ? false : true;

type IsNotUnion<T> = Not<IsUnion<T>>;

type T = IsNotUnion<5>; // true
type U = IsNotUnion<5 | 3>; // false

As a temporary solution, you can use the following type:
type NumericRange<
  start extends number,
  end extends number,
  arr extends unknown[] = [],
  acc extends number = never,
> = arr['length'] extends end
  ? acc | start | end
  : NumericRange<start, end, [...arr, 1], arr[start] extends undefined ? acc : acc | arr['length']>;

type MyRange = NumericRange<1, 50>;

I support this proposal too.
It's a much needed feature when noUncheckedIndexedAccess tsconfig compiler option is turned on. Arrays constantly need undefined checks otherwise, like so:
const a = [1,2,3]
if(a[1] === undefined) {
	throw new Error('undefined')
}
const b: number = a[10] // ts can infer that there's been an undefined check, so the type of b can only be number now

It would be nice to have an method of guaranteeing the length and that the elements are therefore defined. Something like this type:
type Len<T extends readonly any[], L extends number> = Readonly<Pick<Required<T>, 0..L>>

The 0..L is where I need an interval or range type. I can use a union at the moment, but this is a very finite solution (I don't want to be typing out a union with 10's of thousands of entries) and inflexible. I can use a recursive type to build the union type automatically, but these fall down after ~3000 entries on my machine (due to stack overflow of recursion).

As a temporary solution, you can use the following type:
type NumericRange<
  start extends number,
  end extends number,
  arr extends unknown[] = [],
  acc extends number = never,
> = arr['length'] extends end
  ? acc | start | end
  : NumericRange<start, end, [...arr, 1], arr[start] extends undefined ? acc : acc | arr['length']>;

type MyRange = NumericRange<1, 50>;

how to make work with 00 ?
type NumericRange<
start extends number,
end extends number,
arr extends unknown[] = [],
acc extends number = never,
= arr['length'] extends end
? acc | start | end
: NumericRange<start, end, [...arr, 1], arr[start] extends undefined ? acc : acc | arr['length']>;
type Hours = NumericRange<0, 24>
type Minutes = NumericRange<0, 60>
type Seconds = NumericRange<0, 60>
type Time = ${Hours}:${Minutes}:${Seconds}
const a: Time[] = [
'',
'10:34:35',
'31:34:35',
]
const b: Time = '10:00:00';
const c: Time = '00:00:00';
b and c should be possible

My use-case is simple - User roles. The names are ambiguated
export enum UserRole {
  Guest = -1, CompanyManager, CompanyOwner, SuperManager, SuperOwner
}

export interface GeneralUser {
  id: string
  email: string
  firstName: string
  lastName: string
  avatar: string
}

export interface SuperUser extends GeneralUser {
  role: UserRole.SuperOwner | UserRole.SuperManager
  companyId?: string
  signed: true
}

export interface CompanyUser extends GeneralUser {
  role: UserRole.CompanyOwner | UserRole.CompanyManager
  companyId: string
  signed: true
}

export interface GuestUser extends GeneralUser {
  role: UserRole.Guest
  signed: false
}

export type User = SuperUser | CompanyUser | GuestUser

And currently I'm receiving error when I try to use User type by narrowing it with <= comparison:
    if (user.role <= UserRole.CompanyOwner) {
      // `CompanyUser` cast is used since TS doesn't handle `<=` properly.
      MyScript.set("COMPANY_ID", { companyId: (user as CompanyUser).companyId })
    }

So I'm putting the comment above to signalize it, I will also reference this issue, so maybe someone will refactor it in future 😘

BTW, I really like this proposal, I think it will be very handy.

@FrameMuse
I suppose your user variable is typed by User.
So inside the if block, user type is CompanyUser | GuestUser, but companyId doesn't exist for the GuestUser type, so you have a type error.
You can see this error by adding this line inside the if  block: const companyId: string = user.companyId;
You have the error :
Property 'companyId' does not exist on type 'User'.   Property 'companyId' does not exist on type 'GuestUser'.
The problem is not the Typescript parser, but your code.
Regards.

@vtgn

But you should not report this bug here, because this issue is about to add new types definition operators, not the types resolution implementation. Watch if an existing issue talks about your bug, otherwise create a new one.

I couldn't find one and now I'm too lazy to create a new one, so I leave it here...

@vtgn

But you should not report this bug here, because this issue is about to add new types definition operators, not the types resolution implementation. Watch if an existing issue talks about your bug, otherwise create a new one.

I couldn't find one and now I'm too lazy to create a new one, so I leave it here... Thanks anyway

You can be sure it will be ignored here... -_-°...


Changed formatting-action diff to compare to merge-base instead of upstream/main.

I noticed that the action could find "false positive" changes when files were updated on upstream/main that were not synced to the pushed branch.

Good catch!  Thank you for the update


ci: lint zig code with ZLint

What This PR Does
Adds a CI workflow to lint Zig source code with zlint.
ZLint checks for:

Compiler errors that are never emitted because they occur in dead code
Potentially unsafe logic
More idiomatic ways to do the same thing (e.g. foo() catch |e| return e -> try foo()
Dead code

This workflow can be configured to only check files changed in a pull request. I have turned this off for demonstration purposes. Please let me know if you would like it re-enabled.
Here's some sample output from zlint --quiet

Aren't all 3 of those in your example screenshot false positives?

Yeah, you can use try in comptime code...if it fails you get a compile error.
Uncomment the second print line to bring the failing code into the compilation unit
https://zigbin.io/9af430

Yeah, you can use try in comptime code...if it fails you get a compile error.
Uncomment the second print line to bring the failing code into the compilation unit
https://zigbin.io/9af430

I had no idea you could do that...
Thanks for the info, I'll add checks for that.

Thanks for this. I'm not interested in adding this for now, but please feel free to continue developing ZLint against the Ghostty codebase and if you find issues I'm happy to address specific issues. Once there is some more stability I'm happy to take another look.

@rockorager thanks for the info, this has been fixed.


Add multi-line editing support

This is my first draft on this idea.
I think it's pretty solid and the tests still pass.  I haven't tested it on any other platforms but Linux yet.
I'm definitely interested if anyone has feedback on the design of the trait.  I kept it really simple initially, and it suits my usage.  I think it should be flexible enough to be generally useful.
I wouldn't merge this until someone tests it on Mac and Windows.

What would this do with the history? Will it save the multi-line block as one entry?
When you say "multi-line editing", does this mean you can press up and edit the line above?

@hayd Yes, this saves the multiple line block as a single entry.
Essentially, this change just lets the user insert literal newline characters into the buffer if the Helper judges that current buffer is "invalid" (i.e. incomplete).
I didn't implement navigation across buffer lines using the up or down motion commands, but you can use the forward/back motion commands to navigate across the buffer text as normal, and this includes crossing newlines in the buffer. This is a bit less convenient for use, but I think the increased complexity in overloading the up/down motion commands is not really worth it.

A comment from the peanut gallery - I'm looking at this with keen interest as I am implementing a REPL frontend to a backend JDBC server, and having this would be a killer for multline queries.

It looks like this work has been moved to #182!


"My decks" stack in loading icon

"My decks" option in the page just stack in loading icon...

Give a link to your profile please

Same here, experiencing same error. I will PM you my profile link.

Here you go:
mtga.cc/decks/?richard.124390

Can't reproduce bug for now, I don't see endless load and any errors. Can you please take a screenshot of bugged screen with Chrome console open and JS errors visible in it?

https://mtgarena.pro/u/Cesarmgc
El mar., 1 oct. 2019 11:47 p. m., Razviar<EMAIL_ADDRESS>escribió:

Give a link to your profile please
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/Razviar/mtga-pro-tracker/issues/517?email_source=notifications&email_token=ANLVRFKN7EQRJDDG4S3WCGLQMQOHDA5CNFSM4I4QWJ52YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEADPRAY#issuecomment-537327747,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ANLVRFJ4VQ2IEESW7PJV5BLQMQOHDANCNFSM4I4QWJ5Q
.

El mar., 1 oct. 2019 11:47 p. m., Razviar<EMAIL_ADDRESS>escribió:

Give a link to your profile please
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/Razviar/mtga-pro-tracker/issues/517?email_source=notifications&email_token=ANLVRFKN7EQRJDDG4S3WCGLQMQOHDA5CNFSM4I4QWJ52YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEADPRAY#issuecomment-537327747,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ANLVRFJ4VQ2IEESW7PJV5BLQMQOHDANCNFSM4I4QWJ5Q
.

Try now, should be fixed


chore(deps): update dependency fluxcd/flux2 to v0.31.4

This PR contains the following updates:

Package
Update
Change

fluxcd/flux2
patch
v0.31.3 -> v0.31.4

Release Notes

fluxcd/flux2
v0.31.4
Compare Source
Highlights
Flux v0.31.4 is a patch release that comes with fixes. Users are encouraged to upgrade for the best experience.
Fixes

Fix SIGSEGV when resolving charts dependencies.
Fix Panic when no artifact in source.
decryptor: recover from SOPS store panic.
Fix spelling mistake in azure/exchanger.go.

Improvements

Retry downloading artifacts on not found errors.

Components changelog

source-controller v0.25.10
kustomize-controller v0.26.3
notification-controller v0.24.1
helm-controller v0.22.2
image-automation-controller v0.23.5
image-reflector-controller v0.19.3

CLI Changelog

PR #2905 - @fluxcdbot - Update toolkit components

Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.

[ ] If you want to rebase/retry this PR, click this checkbox.

This PR has been generated by Renovate Bot.

⚠ Artifact update problem
Renovate failed to update an artifact related to this branch. You probably do not want to merge this PR as-is.
♻ Renovate will retry this branch, including artifacts, only when one of the following happens:

any of the package files in this branch needs updating, or
the branch becomes conflicted, or
you click the rebase/retry checkbox if found above, or
you rename this PR's title to start with "rebase!" to trigger it manually

The artifact failure details are included below:
File name: cluster/base/flux-system/gotk-components.yaml
Command failed: docker pull docker.io/renovate/sidecar
Cannot connect to the Docker daemon at unix:///var/run/docker.sock. Is the docker daemon running?


[5.7] Hash::check breaks all apps with legacy hash

>>> Hash::check('s3cr3t', '$1$0590adc6$WVAjBIam8sJCgDieJGLey0');
RuntimeException with message 'This password does not use the Bcrypt algorithm.'

Use case: We have applications with sha1 AND bcrypt passwords.
On successful login, an event is triggered to update the hash stored in DB to the stronger hash algorithm.
Since the 5.7 update, all users with legacy passwords are not able to login anymore.
Please, reconsider this check in the Hash::check method or make it optional, it should be consistent with how password_verify() works.
Password hashing is not backward compatible nor future proof anymore...
Breaking changes introduced in: https://github.com/laravel/framework/issues/24162 / https://github.com/laravel/framework/pull/24178
Related issues: https://github.com/laravel/docs/issues/4509, https://github.com/laravel/framework/pull/25468, https://github.com/laravel/framework/issues/25458

In the meantime, for those stuck and who still would like to upgrade, here's how:
Create app/Hashing/BcryptHasher.php:
<?php

namespace App\Hashing;

use Illuminate\Hashing\BcryptHasher as BaseHasher;

class BcryptHasher extends BaseHasher
{
    /**
     * Check the given plain value against a hash.
     *
     * @param  string  $value
     * @param  string  $hashedValue
     * @param  array  $options
     * @return bool
     */
    public function check($value, $hashedValue, array $options = [])
    {
        if (strlen($hashedValue) === 0) {
            return false;
        }

        return password_verify($value, $hashedValue);
    }
}

Then in your AppServiceProvider add:
app('hash')->extend('legacy-bcrypt', function () {
    return new BcryptHasher($this->app['config']['hashing.bcrypt'] ?? []);
});

And set 'driver' => 'legacy-bcrypt' in config/hashing.php

I wonder why do we need to use Hash::check() for authentication verification if at the end we plan to support multiple hashing algorithm; bcrypt and argon1.
Shouldn't we respect whatever hashing used in the password as long as password_verify() can verify the password?

This has been fixed in 5.7.4

Thanks @crynobone !
Closing as this issue has been resolved.

@crynobone  See me comment in https://github.com/laravel/framework/pull/25677 why we should still use Hash::check() if we don't want to break existing apps that uses custom hasher.

Can we re-open this now that the partial fix has been reverted?

This also breaks your app if the user does not have a password set. This wasn't the case before Laravel 5.7.

#25468 has been merged, we await a new release...

Closing as this issue has been resolved (again).


Godot default android export template includes permission requests that were not requested

Godot version:
2.1.4 - 2,1.5
OS/device including version:
Android
Issue description:
Godot default android export template includes permission requests that were not requested.
A week back my apps were removed from Google Play for requesting sensitive permissions and for not including a Privacy Policy file. After talking to the support staff i was told that my games requested the following permissions:
android.permission.READ_PHONE_STATE
android.permission.RECORD_AUDIO
android.permission.GET_ACCOUNTS
android.permission.READ_CONTACTS
android.permission.CAMERA
Which i've never toggled during the export process.
And, i believe, purging everything between line 37 to line 202 off the AndroidManifest.xml.template is not enough, as there are still sensitive permissions being requested in the background.
After opening a compiled export template APK in Android Studio and doing a a global tree search, by hitting ctrl+shift+f and entering 'android.permission', there is, oddly, a fair amount of sensitive permissions being requested.
Here's a list of some of those i've found:
FILE NAME: FingerprintManagerCompat.smali
value = "android.permission.USE_FINGERPRINT"
FILE NAME: zzaqo.smali
const-string v2, "android.permission.ACCESS_COARSE_LOCATION"
const-string v2, "android.permission.ACCESS_FINE_LOCATION"
FILE NAME: zzaiw.smali
const-string v2, "android.permission.RECORD_AUDIO"
const-string v2, "android.permission.CAMERA"
FILE NAME: zzmw.smali
const-string v1, "android.permission.WRITE_EXTERNAL_STORAGE"
FILE NAME: WorkSourceUtil.smali
const-string v2, "android.permission.UPDATE_DEVICE_STATS"
These appear to be generated during the compilation process for no apparent reason.

Read here for instructions on how to fix the problems with placeholder permissions https://godotengine.org/article/fixing-godot-games-published-google-play

The problem of sensitive permissions being unwanted-ly requested continues even after doing that.

That's a duplicate of #18192.

Here's a list of some of those i've found:
FILE NAME: FingerprintManagerCompat.smali
value = "android.permission.USE_FINGERPRINT"
FILE NAME: zzaqo.smali
const-string v2, "android.permission.ACCESS_COARSE_LOCATION"
const-string v2, "android.permission.ACCESS_FINE_LOCATION"

I don't know what those are but they're not defined by Godot. (You can grep for those permission names, you'll only find references to the placeholders and the logic that can replace them when asked for by actual permissions).
When you upload a game to Google Play, or try to install it on a device, it doesn't ask for any of the permissions you listed above unless you explicitly requested them.

Understood, but i'd still like to know why these things are there, because they are.
If you:
-> open a compiled export template APK in Android Studio
-> do a a global tree search, by hitting ctrl+shift+f
-> enter android.permission in the search box
You will come across them too.

Closing as duplicate of https://github.com/godotengine/godot/issues/18192


Localization update

This PR was auto-generated with the localization pipeline build.

Closed at the moment since there are still English strings for already localized tasks


Unrecognized option "db_drivers" under "hautelook_alice"

I have installed hautelook/alice-bundle package package from symfony.sh on a Symfony Flex application, however when I run ./bin/console cache:run it outputs this error:
Unrecognized option "db_drivers" under "hautelook_alice"
I looked up the Configuration.php of the package. There are just two options:
fixtures_path and root_dirs.
I have used this bundle in old symfony packages without any issues.
I wonder whether I'm missing any necessary package?

Hi, I think you simply installed 2.0.0 which no longer has db_drivers for now at least :)

Thank you @theofidry !


When deploying multiple copies of Coroot, pvc will conflict

hello, I encountered a problem when installing coroot multiple copies in helm
coroot version 1.5.0, installed in Kubernetes using helm,database ,The database uses pg
https://github.com/coroot/helm-charts/blob/main/charts/coroot/templates/deployment.yaml
volumes:
- name: data
persistentVolumeClaim:
claimName: {{ template "coroot.fullname" . }}-data

NAME          STATUS   VOLUME                   CAPACITY   ACCESS MODES   STORAGECLASS                     AGE
coroot-data   Bound    d-uf6f9lzkoy1b56yj04uz   200Gi      RWO            alicloud-disk-topology-alltype   10m
kubectl -n coroot-nonprod get pods
NAME                    READY   STATUS              RESTARTS   AGE
coroot-b7f5b4f9-4vv4c   1/1     Running             0          14m
coroot-b7f5b4f9-kfqs2   0/1     ContainerCreating   0          14m
kubectl -n coroot-nonprod describe pod coroot-b7f5b4f9-kfqs2
Warning  FailedAttachVolume  15m                attachdetach-controller  Multi-Attach error for volume "d-uf6f9lzkoy1b56yj04uz" Volume is already used by pod(s) coroot-b7f5b4f9-4vv4c
Warning  FailedMount         96s (x6 over 12m)  kubelet                  Unable to attach or mount volumes: unmounted volumes=[data], unattached volumes=[data kube-api-access-ms2vd]: timed out waiting for the condition

In the case of coroot multiple copies, the pvc in the helm template is hardcoded

@def thank you!

@emanzat, Coroot doesn’t support shared disk access, so this might not work
So the coroot installed using helm requires multiple copies. What are the recommended solutions?


Cwd shows up in tab when terminals are in their initial cwd on a single folder workspace

Based on the description of cwdFolder, this should be hidden if it's the initial cwd.
"terminal.integrated.tabs.description": "${task}${separator}${local}${separator}${cwdFolder}"

${cwdFolder}: the terminal's current working directory, displayed for multi-root workspaces or in a single root workspace when the value differs from the initial working directory. On Windows, this will only be displayed when shell integration is enabled.

May only be an issue on Windows?

Seems related to Windows, doesn't happen on a mac


[Request] gtk#

Package Request
Criteria
For a package to be acceptable in the Main bucket, it should be:

[x] a non-GUI tool
[x] a reasonably well-known and widely used developer tool (e.g. if it's a GitHub project, it should have at least 500 stars and 150 forks)
[x] the latest stable version of the program
[x] the full version i.e. not a trial version
[x] a fairly standard install (e.g. uses a version-specific download URL, no elaborate pre/post install scripts)

Information
Name: [name of new package]
Gtk#
Description: [clear and concise details of what it is]
Gtk# is a Graphical User Interface Toolkit for mono and .Net
Homepage: [a URL/link]
https://www.mono-project.com/gtksharp
Download link(s): [URL(s)/link(s)]
https://xamarin.azureedge.net/GTKforWindows/Windows/gtk-sharp-2.12.45.msi
Some indication of popularity/repute: [GitHub stars/software reviews etc.]
406

Its actually not. Its a pure CLI library

To my understanding, this is neither a GUI tool nor a "simple" command-line tool.
It is a runtime library, just like VCRedist or Windows Desktop Runtime.
I think we should add this to Extras bucket, and run the MSI installer in pre_install. (instead of extracting it)

sandbox record (brief)
sandbox record (full)


SDK-4606 Add SetcodeMultisigWalletV2 giver

Steps to check new type of giver.
In this example, SetcodeMultisigWalletV2 is deployed to devnet, but the "se" network can also be used.
1. Deploy SetcodeMultisigWalletV2 giver:
1.1 Calculate future address
npm i
$ node cli.js contract info contracts/SetcodeMultisigWalletV2 -n devnet  -s seGiver
Configuration
  ------%<------------
Address:   0:0e0cbc3b116f66a2eed50fb6e08167e930e348315ad1e01a1b38a76c85e42cd8 (calculated from TVC and signer public)
Code Hash: d66d198766abdbe1253f3415826c946c371f5112552408625aeb0b31e0ef2df3 (from TVC file)

1.2 Deploy SetcodeMultisigWalletV2
$ node cli.js contract deploy contracts/SetcodeMultisig.tvc -n devnet  -s seGiver
----%<-----------
Parameters of constructor:
  Enter number of items in owners: 1
  owners 1 (uint256): 0x2ada2e65ab8eeab09490e3521415f45b6e42df9c760a639bcf53957550b25a16
  reqConfirms (uint8): 1
  lifetime (uint32): 10000

2. Set SetcodeMultisigWalletV2 giver as a default giver
$ node cli.js network giver devnet 0:0e0cbc3b116f66a2eed50fb6e08167e930e348315ad1e01a1b38a76c85e42cd8 -s seGiver -t SetcodeMultisigWalletV2

3. Deploy any contract using default giver
$ node cli.js contract deploy contracts/HelloWallet -n devnet -v<PHONE_NUMBER>0 -s seGiver
----%<--------------
Deploying...
Contract is deployed at address: 0:52495b5605861330bc11ef22949144f2bd1da09254bdf3d206ebdca457882800

@d3p Take into account that  SetcodeMultisigWalletV2  has been renamed to MsigV2


Add get_epoch_boundary_block to the fork choice spec

This PR introduces the function get_epoch_boundary_block and replaces any computation of epoch boundary blocks in the fork choice spec with a call to the newly introduced function.
The objective of this PR is to increase the readability of the spec by better clarifying when we are interested in calculating an epoch boundary block.

You need to change the corresponding files in different forks that changed on_block, eg. Bellatrix
:+1:
Done.

Please change the p2p network specs as well.
specs/phase0/p2p-interface.md:  `get_ancestor(store, block.parent_root, compute_start_slot_at_epoch(store.finalized_checkpoint.epoch))
specs/phase0/p2p-interface.md:  `get_ancestor(store, aggregate.data.beacon_block_root, compute_start_slot_at_epoch(store.finalized_checkpoint.epoch))
specs/phase0/p2p-interface.md:  `get_ancestor(store, attestation.data.beacon_block_root, compute_start_slot_at_epoch(attestation.data.target.epoch)) == attestation.data.target.root`
specs/phase0/p2p-interface.md:  `get_ancestor(store, attestation.data.beacon_block_root, compute_start_slot_at_epoch(store.finalized_checkpoint.epoch))

We should also update the pyspec correspondingly, if we want to apply this patch.
For example, in tests/core/pyspec/eth2spec/test/phase0/fork_choice/test_on_block.py, we should change the following.
finalized_slot = spec.compute_start_slot_at_epoch(store.finalized_checkpoint.epoch)
ancestor_at_finalized_slot = spec.get_ancestor(store, pre_store_justified_checkpoint_root, finalized_slot)

Please run git grep get_ancestor tests/ to see all the places that need a change.

make test report was

================================================================================================================================================= short test summary info ==================================================================================================================================================
FAILED eth2spec/test/deneb/unittests/polynomial_commitments/test_polynomial_commitments.py::test_validate_kzg_g1_not_in_g1 - AssertionError: expected an assertion error, but got none.
FAILED eth2spec/test/deneb/unittests/polynomial_commitments/test_polynomial_commitments.py::test_validate_kzg_g1_not_on_curve - AssertionError: expected an assertion error, but got none.
================================================================================================================================= 2 failed, 806 passed, 146 skipped in 2537.18s (0:42:17) ==================================================================================================================================

The fork choice & p2p spec do not refer to epoch boundary blocks before this PR. More generally, the spec refers to epoch boundary blocks as part of Checkpoints.
I'd prefer to avoid introducing the "epoch boundary block" nomenclature here, and instead rename get_ancestor_at_epoch_boundary to get_checkpoint_block.

Done


Invalid geometry of feature cause exception in geotrellis.spark.clip.ClipToGrid

Reported by Bert De Roo
error. org.locationtech.jts.geom.TopologyException: found non-noded intersection between LINESTRING ( 3125327.8980538994 3571729.6168265673, 3125328.649952571 3571732.4740763605 ) and LINESTRING ( 3125328.627648378 3571732.3893194045, 3126011.1691451804 3571351.0673861904 ) [ (3125328.6276483806, 3571732.389319403, NaN) ]. The workflow is run on different years, however the error only occurs for 2021. Can somebody have a look? job-id:j-231116047d824ec0aa46639f5bbb28d4  backend: openeo3-1.openeo-vlcc-prod.vgt.vito.be
Minimal reproduction graph:
{
  "process_graph": {
    "loadcollection1": {
      "arguments": {
        "bands": [
          "B02",
          "SCL"
        ],
        "id": "SENTINEL2_L2A",
        "properties": {
          "tileId": {
            "process_graph": {
              "eq1": {
                "arguments": {
                  "x": {
                    "from_parameter": "value"
                  },
                  "y": "29UNV"
                },
                "process_id": "eq",
                "result": true
              }
            }
          }
        },
        "spatial_extent": {
          "crs": "EPSG:3035",
          "east": 3140000,
          "north": 3580000,
          "south": 3560000,
          "west": 3120000
        },
        "temporal_extent": [
          "2021-10-01",
          "2021-10-03"
        ]
      },
      "process_id": "load_collection"
    },
    "resamplespatial1": {
      "arguments": {
        "align": "upper-left",
        "data": {
          "from_node": "loadcollection1"
        },
        "method": "near",
        "projection": 3035,
        "resolution": 10
      },
      "process_id": "resample_spatial"
    },
    "saveresult1": {
      "arguments": {
        "data": {
          "from_node": "resamplespatial1"
        },
        "format": "GTiff",
        "options": {
          "filename_prefix": "CROP_2021_E312N356-03035-010m_V100",
          "overview_method": "mode"
        }
      },
      "process_id": "save_result",
      "result": true
    }
  }
}

This product contained invalid geometry: /eodata/Sentinel-2/MSI/L2A_N0500/2021/10/02/S2B_MSIL2A_20211002T114349_N0500_R123_T29UNV_20230103T031448.SAFE

@EmileSonneveld  did you mention that this was now solved?

The MR just needs to get trough

@jdries This is merged and went through tests, can i deploy it on vlcc-3-1?

fine for me, thomas also asked for a deploy there

This is deployed and works on https://openeo-3-1.openeo-vlcc-prod.vgt.vito.be/


[SANDBOX PROJECT ONBOARDING] KubeClipper

Welcome to CNCF Project Onboarding!
This is an issue created to help onboard your project into the CNCF after the TOC has voted to accept your project.
We would like to complete onboarding within one month of acceptance.
From the project side, please ensure that you:

[ ] Understand the project proposal process and reqs: https://github.com/cncf/toc/blob/main/process/project_proposals.md#introduction
[ ] Understand the services available for your project at CNCF https://www.cncf.io/services-for-projects/
[ ] Ensure your project meets the CNCF IP Policy: https://github.com/cncf/foundation/blob/master/charter.md#11-ip-policy
[ ] Review the online programs guidelines: https://github.com/cncf/foundation/blob/master/online-programs-guidelines.md
[ ] Understand the trademark guidelines: https://www.linuxfoundation.org/en/trademark-usage/
[ ] Understand the license allowlist: https://github.com/cncf/foundation/blob/master/allowed-third-party-license-policy.md#approved-licenses-for-allowlist
[ ] Is your project working on written, open governance? see https://contribute.cncf.io/maintainers/governance/
[ ] Slack: Are your slack channels migrated to the Kubernetes or CNCF Slack? (see https://slack.com/help/articles/217872578-Import-data-from-one-Slack-workspace-to-another for more details)
[x] Is your project in its own separate neutral github organization?
[ ] Submitted a Pull request to add your project as a sandbox project to https://landscape.cncf.io
[ ] Create maintainer list + add to aggregated https://maintainers.cncf.io list by submitting a PR to it
[ ] Artwork: Submit a pull request to https://github.com/cncf/artwork with your artwork
[ ] Domain: transfer domain to the CNCF - https://jira.linuxfoundation.org/plugins/servlet/theme/portal/2/create/63

Things that CNCF will need from the project:

[ ] Provide emails for the maintainers added to https://maintainers.cncf.io in order to get access to the maintainers mailing list and ServiceDesk -<EMAIL_ADDRESS>is the best email to send those to
[ ] Trademarks: transfer any trademark and logo mark assets over to the LF - https://github.com/cncf/foundation/tree/master/agreements has agreements
[x] GitHub: ensure 'thelinuxfoundation' and 'caniszczyk' are added as initial org owners, this helps us make sure we have continuity of GH ownership that we will onboard to our GitHub Enterprise instance: https://github.com/enterprises/cncf
[ ] GitHub: ensure DCO or CLA are enabled for all GitHub repositories of the project
[ ] GitHub: ensure that that the CNCF Code of Conduct (or your adopted version of it) are explicitly referenced at the project's README on GitHub
[ ] Website: ensure LF footer is there and website guidelines followed (if your project doesn't have a dedicated website, please adopt those guidelines to the README file of your project on GitHub).
[ ] Website: Analytics transferred to<EMAIL_ADDRESS>[ ] OpenSSF Best Practices Badge: Start on an OpenSSF Best Practices Badge https://bestpractices.coreinfrastructure.org/en

Things that the CNCF will do or help the project to do:

[x] Devstats: add to devstats https://devstats.cncf.io/
[x] Insights: add to LFX Insights https://insights.v3.lfx.linuxfoundation.org/
[x] Events: update CFP + Registration + CFP Area forms
[ ] ServiceDesk: confirm maintainers have read https://www.cncf.io/services-for-projects/
[ ] CNCF Welcome Email Sent to confirm maintainer list access
[ ] Book time with the team with http://project-meetings.cncf.io
[ ] Adopt a license scanning tool, like FOSSA or Snyk

@wu-wenxiang @x893675
Hi! Is there any chance your team has been able to work on these tasks? It would be great to close out this onboarding issue for KubeClipper

I checked for registered email addresses internally and I only have an address for @x893675
Looking at https://github.com/kubeclipper/kubeclipper/blob/master/OWNERS I see approvers and reviewers
@x893675 it would be great if you could register the current maintainers by sending a list of maintainers and the email addresses that they use for repo commits  to<EMAIL_ADDRESS>Many thanks, @RobertKielty


Refactoring ChannelPool

InstrumentedChannel is now decoupled from header processing in ChannelPool.  This will allow a future PR to cache data API InstrumentedChannels for reuse across BigtableSession / AbstractBigtableConnection instances, which is a useful feature for Dataflow performance.

I addressed the comments, and did a bit more refactoring in ChannelPool.  I replaced uses of InstrumentedChannel with ManagedChannel.

I should break this up into smaller PRs.  There's a lot going on here.


orderBy text

The results of the orderBy name show lowercase and uppercase separately.
A
B
C
a
b
c

I'm not sure this is a bug, if you do a sort in javascript you'll get this result:
["A", "a", "C", "b"].sort((a, b) => a > b ? 1 : -1);
//  "A", "C", "a", "b"]

Also SQLite and MySQL sort in this way, so it'll likely remain the default behavior.
If you'd like to sort your rows a specific way you might just do the sorting after you query the rows:
nSQL("table").query("select").exec().then((rows) => {
    const sortedResults = rows.sort((a, b) => {
        return String(a.col).toUpperCase() > String(b.col).toUpperCase() ? 1 : -1;
    });
});


MSTransferor: support input data placement with Rucio

Fixes #9725
Status
In development
Description
Summary of changes are:

use a deployment configuration parameter useRucio to enable or not Rucio as a DM service (deployment changes need to be made)
made two new methods, one to deal with the Rucio rule and rule creation; one to deal with a subscription object and subscription requests in PhEDEx
separated method for the email notification (for too large data placement)

Is it backward compatible (if not, which system it affects?)
yes
Related PRs
none
External dependencies / deployment changes
Deployment changes: https://github.com/dmwm/deployment/pull/924

For some reason, the import cert, ckey from PycurlRucio does not want to work, I get the same import error in my container too:
Traceback (most recent call last):
  File "/home/dmwm/unittestdeploy/wmagent/1.3.6.pre4/sw/slc7_amd64_gcc630/external/py2-nose/1.3.7-comp3/lib/python2.7/site-packages/nose/loader.py", line 418, in loadTestsFromName
    addr.filename, addr.module)
  File "/home/dmwm/unittestdeploy/wmagent/1.3.6.pre4/sw/slc7_amd64_gcc630/external/py2-nose/1.3.7-comp3/lib/python2.7/site-packages/nose/importer.py", line 47, in importFromPath
    return self.importFromDir(dir_path, fqname)
  File "/home/dmwm/unittestdeploy/wmagent/1.3.6.pre4/sw/slc7_amd64_gcc630/external/py2-nose/1.3.7-comp3/lib/python2.7/site-packages/nose/importer.py", line 94, in importFromDir
    mod = load_module(part_fqname, fh, filename, desc)
  File "/home/dmwm/wmcore_unittest/WMCore/test/python/WMCore_t/MicroService_t/DataStructs_t/Workflow_t.py", line 8, in <module>
    from WMCore.MicroService.DataStructs.Workflow import Workflow
  File "/home/dmwm/wmcore_unittest/WMCore/src/python/WMCore/MicroService/DataStructs/Workflow.py", line 10, in <module>
    from WMCore.MicroService.Unified.Common import getMSLogger, gigaBytes
  File "/home/dmwm/wmcore_unittest/WMCore/src/python/WMCore/MicroService/Unified/Common.py", line 18, in <module>
    from WMCore.MicroService.Tools.PycurlRucio import getPileupDatasetSizesRucio, getPileupSubscriptionsRucio, \
  File "/home/dmwm/wmcore_unittest/WMCore/src/python/WMCore/MicroService/Tools/PycurlRucio.py", line 20, in <module>
    from WMCore.MicroService.Unified.Common import cert, ckey
ImportError: cannot import name cert

it must be missing some subtle detail of the import behavior.
As a workaround, I copied those 2 methods over to the PycurlRucio module.
@todor-ivanov I believe there will be further changes to this PR. But just in case you can have a look at these changes by tomorrow morning, it would be great! Thanks

Todor, thanks for your review. Following your review, I have made further changes in my last commit. Please have another look, and if you agree, mark those conversations as resolved.

Thanks @amaltaro I took a quick look at your new commit and I think you addressed everything I mentioned. I think the changes are good to go now.

@nsmith- and @ericvaandering I think I have finally converged on this PR and tested the most common use cases.
I'm not asking for your review because it became very big, but feel free to go through the initial description at the very top and ask/suggest anything else that you might consider important.
I might merge it today, but feel free to leave questions/comments at any time and I can follow up on those in a different PR, if needed.

All right, it should be tested enough by now...


Deleted Associations

In our demo today (3/4/207) we deleted an adopter, but it was still shown in the cat menu.
The association groupings in the view pages need to filter out "deleted" entities.

First issue fixed for deleted fosters and adopters in cat menu.


OrchestratorRecognizer update to 4.11 (main already done)

Fixes #
#4969
Description
Updated description for ModelPath in OrchestratorRecognizer and OrchestratorAdaptiveRecognizer.  Changes on main is already done.  PR to main: https://github.com/microsoft/botbuilder-js/pull/3067

Closing in favor of https://github.com/microsoft/botbuilder-js/pull/3072
@tsuwandy I prefer to use the git cherry-pick workflow. It maintains commit messages and includes the original pull request reference which helps us keep track of changes.


Support bundling with esbuild

Bundling with esbuild currently fails on this package and other libs that use this package like hypercast-podcore-next due to an issue in the batch dependency.
On line 15 of Batch's index.js it references a package called "emitter" that does not exist. When esbuild tries to resolve that package, it fails.
One solution: fork the Batch repo, work around that failed resolver, and publish that simple change as its own package.

@agrathwohl My updates were merged into the main Batch repo with this commit. So Batch can now be built with esbuild!
All we need to do here is install the latest version of Batch and cut a new release of little-media-box that the serverless repo can update to.


Table heading rows at normal size

@souperneon I think this is better... let me know

I understand why this needs to  happen… SIGH


how I close the ps.exe safely, ps.Application() seems no such function like "close() / quit()"

how I close the ps.exe safely, ps.Application() seems no such function like "close() / quit()"
I want to quit the ps.exe rather than its document

FYI:
https://community.adobe.com/t5/photoshop-ecosystem-discussions/exiting-photoshop-from-a-jsx-script/m-p/3451742

app.quit()


Data Cleaning

Before we can get into proper analysis we need to get a lay of the land and make sure the data is in the right format and there aren't any consistency issues.

Consistency of columns across datasets
Consider combining datasets together (this may or may not make sense)
Check for missing values - if there are any, does anything need to be down about these
Data types - check the data types of columns - e.g. are the count columns integers or strings
Check for naming inconsistencies with boroughs and wards

Aviation security in heathrow is its own borough in the ward crimes files (2010-2023), and I assume it's the same for the other airports, although I've not checked. Also, the first four columns are in a different order for those two files; not sure if this is an issue?

I don't know how to change column order, you have have to use the index?


HTTP Redirection check: Status 308 interpreted as 301

⚠ Please verify that this bug has NOT been raised before.

[X] I checked and didn't find similar issue

🛡 Security Policy

[X] I agree to have read this project Security Policy

Description
No response
👟 Reproduction steps

Define a HTTP check (not HTTPS!) for a website that has a permanent redirection enabled.
Set the redirects to 0.
Set the expected status code to 308
Verify via curl that you really get a 308
Uptime-Kuma reports the monitor as down, as it got thinks it got a 301 status code

Example:
$ curl -sI http://johanneskastl.de |head -n 1
HTTP/1.1 308 Permanent Redirect

Log from Uptime-Kuma:
Request failed with status code 301

👀 Expected behavior
Uptime-Kuma should properly recognize the 308 status code and report the monitor as UP.
😓 Actual Behavior
Uptime-Kuma detects a status code 301 where in reality it is getting a 308. Hence it sets the monitor to DOWN.
🐻 Uptime-Kuma Version
v1.11.1
💻 Operating System and Arch
not relevant, as Kubernetes only
🌐 Browser
Firefox
🐋 Docker Version
No response
🟩 NodeJS Version
No response
📝 Relevant log output
No response

Interesting. I did some testing and looks like curl is the odd one that's handling 308 correctly. Python requests, Chrome, Firefox and Node 17's fetch() all reports 301, so I guess the limitation runs pretty deep.

Would you mind to share the part of redirect logic of your website?
Tested with several platforms, they are different too.
Chrome = 307
curl -sI = 308
curl -v = 301
php = 301
$curl = new \Curl\Curl();
$curl->get("http://johanneskastl.de");
print_r($curl->httpStatusCode);

Node.js = 301
const options = {
    host: "johanneskastl.de",
};

http.get(options, (res) => {
    console.log(res.statusCode);
    res.resume();
});

Would you mind to share the part of redirect logic of your website?

In my case this is a Traefik Proxy running in Kubernetes that redirects HTTP to HTTPS using a redirectScheme middleware:
https://doc.traefik.io/traefik/middlewares/http/redirectscheme/
# Redirect to https
apiVersion: traefik.containo.us/v1alpha1
kind: Middleware
metadata:
  name: test-redirectscheme
spec:
  redirectScheme:
    scheme: https
    permanent: true

https://github.com/traefik/traefik/issues/7829#issuecomment-770210080
Found this, I think it is by design of traefik.

traefik/traefik#7829 (comment)
Found this, I think it is by design of traefik.

Thanks for your help, funny that Traefik is reporting different status codes depending on who is asking... :-(


feat: cleanup invalid symlinks in .local/state/mise/(tracked|trusted)-configs

Fixes #2020 by introducing an experimental mise config prune command to prune invalid config file references from .local/state/mise/(tracked|trusted)-configs.

I think I'd prefer mise prune --config but I'm open to a reason why we would put it here instead

Ah yeah I did not think of that

We probably also should also ensure in mise prune that both are cleaned up.

I'm not sure. I think there probably will be some small subset of users with directories that come and go which also use prune to clear out old tools—they may want references that don't exist

Up until now, the tracked configs have been cleanup up as part of Tracker::list_all(). I moved that out to make it more explicit but we can skip the cleanup of those for prune completely.

Here's a thought, maybe we put everything under mise prune but if you specify --tools or --config that would filter so as to only prune that type. No args would essentially be like a (nonexistent) --all.
It might be worth looking at what docker system prune is doing for a potential reference.


Perception: Change camera obstacle to use new topic. Modify related adapter manager. Change calibration exmaple for front camera

@eugenegx Does the topic changed on the driver side as well?


Revert "Add ability to set a classical condition on a list of bits (#7653)"

Summary
This reverts commit 592b9acb8d211dd3950c6be081da592cff9c00f2.
We intend to keep the visualisation components of this PR, but the
modifications to Instruction.condition have caused CI failures in
qiskit-experiments for code that should work.  The same logic in Terra
can currently be represented by adding a new register to the circuit
containing the desired bits (registers are permitted to overlap), and
conditioning on the register.
There is no hardware or simulator support for these cases yet, however
(nor was there before this reversion).  We intend to add a more complete
system of conditional expressions with the move towards more
OpenQASM-3-ish circuits, which will allow conditioning on arbitrary
boolean expressions, not just equality conditions.

Details and comments
With my sincere apologies to Edwin, because this should have been caught and mentioned far earlier in the process.  See also #7653.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

85 of 114 (74.56%)  changed or added relevant lines in 7 files are covered.
7 unchanged lines in 3 files lost coverage.
Overall coverage decreased (-0.006%) to 83.519%

Changes Missing Coverage
Covered Lines
Changed/Added Lines
%

qiskit/circuit/instruction.py
1
2
50.0%

qiskit/visualization/text.py
30
31
96.77%

qiskit/visualization/latex.py
28
30
93.33%

qiskit/dagcircuit/dagcircuit.py
11
16
68.75%

qiskit/visualization/matplotlib.py
0
20
0.0%

Files with Coverage Reduction
New Missed Lines
%

qiskit/dagcircuit/dagcircuit.py
1
89.17%

qiskit/pulse/library/waveform.py
3
89.36%

qiskit/visualization/matplotlib.py
3
25.58%

Totals

Change from base Build<PHONE_NUMBER>:
-0.006%

Covered Lines:
52539

Relevant Lines:
62907

💛  - Coveralls


demo: slight kv

Ensure that we have ability to integrate with current major usage of the component model.

The last problem is that definition order is matter in witc, but not it wit-bindgen, and this will keep going for a while


Need to list all items of a customer's shopcart

As a customer
I need an API to list all the items
So that I can see what I have in my shopcart (with no cart-representation)
Details and Assumptions

REST API endpoint: GET /shopcarts/<customer_id>/items
JSON response format:
[ {   "id": 2,   "customer_id": 123,   "product_id": 17,   "quantities": 1 }, {   "id": 1,   "customer_id": 123,   "product_id": 24,   "quantities": 3 }, ]

Acceptance Criteria
Given customer-id
When API is called
Then I should get a list of all the items in the customer's cart

@haseefathi  don't we already have a GET /shopcarts/<customer_id>/items api?

Yeah you're right...it should just be modified a bit


Bump MongoDB driver version, tidy up POMs.

There's no reason to avoid using the 3.x driver as it's backwards compatible. It brings variety of options that allow for better design and is generally nicer for developers to work with as they have the freedom of codecs and simple DBObjects.
Have also bumped the lombok version and made the appropriate changes to the compiler configuration - see rzwitserloot/lombok#905. Builds are now UTF-8, no previous encoding had been enforced so it was a case of whatever the system fancied. (Non-literal of course :wink:)

:+1:

Works without any problems etc. Still no errors with MongoDB 2.6 - Serverside. @mkotb


Made batchstack numpy docstyle compliant

Closes #260

I'll go ahead and merge this in. Any problem with docstring convention will be resolved later in #264.


Github collector is not working properly

When I am triggering the github collector, the job is running and is only connecting with 6 repo. I have downloaded the latest code from here and created the new jar file. But the result is still the same.

@Aomine-Daiki-5 are those 6 repos public?

So it is only connecting to 6 private repos?


could not be translated and will be evaluated locally.

Sql Where is not being generate when using properties of my base class.
The follow example is a basic version of the problem.
Exception message:
Stack trace:
Microsoft.EntityFrameworkCore.Query:Warning: The LINQ expression 'where (new PackageViewModel() {CreatedByUserName = [p.CreatedBy].UserName, Id = [p].Id}.CreatedByUserName == "Ivan")' could not be translated and will be evaluated locally.

public class BaseViewModel
{
   public String CreatedByUserName { get; set; }
}

public class PackageViewModel : BaseViewModel
{
   public Guid Id { get; set; }
}

public class myTest
{
        public void Test()
        {
           var query = _dbContext.Set<Package>().Select(p => new PackageViewModel()
            {
                CreatedByUserName = p.CreatedBy.UserName,
                Id = p.Id
            });

            var param = Expression.Parameter(typeof(PackageViewModel), "p");
            var exp = Expression.Lambda<Func<PackageViewModel, bool>>(
                Expression.Equal(
                    Expression.Property(param, "CreatedByUserName"),
                    Expression.Constant("Ivan", typeof(String))
                ), param
            );

            var result = query.Where(exp).ToList();
       }
}

If i try with:
var param = Expression.Parameter(typeof(BaseViewModel), "p");
It works, but then it doens't work with other properties like "Id", because they doesn't exist in the base class.
The problem is that in my final version I have some dynamic “where’s” over properties that are in my main class and others that are in my base class which will result in something like this : ( p => p.Id==”…” && p.CreatedByUserName==”…”)
Questions:
Is this a bug?
Why properties that are on my base class only evaluate locally?
Is there a workaround?
Is the solution to copy all properties from my base class to all my main classes?
Further technical details
EF Core version: 2.0.3
Database Provider: Npgsql.EntityFrameworkCore.PostgreSQL 2.0.1
Operating system:
IDE: Visual Studio 2017 15.7.2

Duplicate of #10807? Does it work in version 2.1.0?

@bricelam not working on 2.1.0, probably different problem

When the parameter is typed as a base (Expression.Parameter(typeof(BaseViewModel), "p")) relinq is smart enough to optimize the query into the following form:
from Package p in DbSet<Package>
where [p].CreatedBy.UserName == "Ivan"
select new PackageViewModel{
    CreatedByUserName = [p].CreatedBy.UserName,
    Id = [p].Id
}

which then EF can translate fully to the server. However when the parameter is typed as PackageViewModel, relinq gives us the following query model:
from Package p in DbSet<Package>
where new PackageViewModel{
    CreatedByUserName = [p].CreatedBy.UserName,
    Id = [p].Id
}
.CreatedByUserName == "Ivan"
select new PackageViewModel{
    CreatedByUserName = [p].CreatedBy.UserName,
    Id = [p].Id
}

which is the reason for client eval in where (we can't translate construction of dto in a predicate).
Additionally, if your dynamic predicate uses property that is defined on the derived type directly, then it translates nicely also.
                var param = Expression.Parameter(typeof(PackageViewModel), "p");

                var exp = Expression.Lambda<Func<PackageViewModel, bool>>(
                    Expression.Equal(
                        Expression.Property(param, "Id"),
                        Expression.Constant(Guid.NewGuid(), typeof(Guid))
                    ), param
                );

produces:
from Package p in DbSet<Package>
where [p].Id == 6db575e4-c366-4177-88f8-a8afd1d341c4
select new PackageViewModel{
    CreatedByUserName = [p].CreatedBy.UserName,
    Id = [p].Id
}

Filed https://www.re-motion.org/jira/browse/RMLNQ-121 to track this.

@parxal I've explained the details in https://www.re-motion.org/jira/browse/RMLNQ-121 but the TL:DR answer to solve your problem right now is the following:
You need to use the type where the property was originally declared, just like the C# compiler does it, e.g. "BaseViewModel" for "CreatedByUserName"

@parxal Did you ever get this resolved with your particular situation - where you are attempting to dynamically build a where statement that includes properties from BOTH your base class and your derived class? I know there's a workaround when accessing one of the other, but I don't see a workaround when including both.

I have a very similar issue caused by generic method as an expression source and then trying to apply it on a projected (Select()) queryable:

public interface ISomeable
{
    string Some { get; set; }
}

public static Expression<Func<T, bool>> GetCriteria<T>() where T : class, ISomeable
{  return e => (e.Some == "Hello"); }

...

Expression<Func<MySimpleEntity, bool>> someCriteria = e => (e.Some == "Hello");
Expression<Func<MySimpleEntity, bool>> someCriteria2 = GetCriteria<MySimpleEntity>();

var query = db.Entities
       .Select(s => new MySimpleEntity { Id = s.Id, Some = s.Some });
// if this Select is removed and MySimpleEntity in both expressions replaced with MyFullEntity,
// the issue disappears

// this succeeds
// var filteredQueryResults = query.Where(someCriteria).ToList();

// this fails: why is it evaluated locally and not in SQL? <-------------------------------
var filteredQueryResults = filteredQueryResults = query.Where(someCriteria2).ToList();
// someCriteria2 is set to the same e => (e.Some == "Hello");
// debugger shows that both someCriteria and someCriteria2 are essentially the same,
// however, Linq somehow knows about generic roots of someCriteria2 and treats it differently

/*
 * 'Microsoft.EntityFrameworkCore.Query.QueryClientEvaluationWarning:
 * The LINQ expression 'where (new MySimpleEntity() {Id = [s].Id, Some = [s].Some}.Some == "Hello")'
 * could not be translated and will be evaluated locally.'.
 */

Here's my Gist of a minimal application:
https://gist.github.com/progmars/eeec32a533dbd2e1f85e551db1bc53f8
Is there any workaround (casting, traversing the expression to replace types etc. etc.) to make it work for someCriteria2?

Found a somewhat dirty solution in some other issue:
https://github.com/aspnet/EntityFrameworkCore/issues/14118#issuecomment-519057279


Error in promises

Whenever I try to start the stream I get this. It was working one minute then the next I get this.

Power cycle your Xbox and re-enable remote play.


Update package.json

I add<EMAIL_ADDRESS>to dependencies.

"timeout-as-promise" is an unnecessary library. I already remove the line with requires this library. If you want to help - just star repository. Too you can help for the library with issues. Thank you.


Error while running the pipeline

Hello,
When try to run the ./vaclient/vaclient.sh run object_detection/person_vehicle_bike https://github.com/intel-iot-devkit/sample-videos/blob/master/person-bicycle-car-detection.mp4
Get the below error :
WARNING:tornado.access:404 GET /api/v1/deviceinfo//api/v1/deviceinfo/30 (<IP_ADDRESS>) 0.89ms
{"levelname": "ERROR", "asctime": "2021-11-24 13:04:11,589", "message": "Error on Pipeline 1: gst-core-error-quark: Your GStreamer installation is missing a plug-in. (12): ../gst/playback/gsturidecodebin.c(1024): no_more_pads_full (): /GstPipeline:pipeline9/GstURIDecodeBin:source:\nno suitable plugins found:\n../gst/playback/gstdecodebin2.c(4719): gst_decode_bin_expose (): /GstPipeline:pipeline9/GstURIDecodeBin:source/GstDecodeBin:decodebin0:\nno suitable plugins found:\nMissing decoder: text/html (text/html)\n", "module": "gstreamer_pipeline"}

Adding additional logs :
(gst-plugin-scanner:11): GStreamer-WARNING **: 13:11:21.773: Failed to load plugin '/opt/intel/openvino/data_processing/dl_streamer/lib/libgpurenderer.so': libsvml.so: cannot open shared object file: No such file or directory
(gst-plugin-scanner:11): GStreamer-WARNING **: 13:11:21.779: Failed to load plugin '/opt/intel/openvino/data_processing/dl_streamer/lib/libvasot_gpu.so': libimf.so: cannot open shared object file: No such file or directory
(gst-plugin-scanner:11): GLib-GObject-WARNING **: 13:11:22.060: cannot register existing type 'GstDashDemux'
(gst-plugin-scanner:11): GLib-CRITICAL **: 13:11:22.060: g_once_init_leave: assertion 'result != 0' failed
(gst-plugin-scanner:11): GStreamer-CRITICAL **: 13:11:22.060: gst_element_register: assertion 'g_type_is_a (type, GST_TYPE_ELEMENT)' failed
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,207", "message": "Loading Pipelines from Config Path /home/video-analytics-serving/pipelines", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,233", "message": "Loading Pipeline: action_recognition version: general type: GStreamer from /home/video-analytics-serving/pipelines/action_recognition/general/pipeline.json", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,236", "message": "Loading Pipeline: audio_detection version: environment type: GStreamer from /home/video-analytics-serving/pipelines/audio_detection/environment/pipeline.json", "module": "pipeline_manager"}
{"levelname": "WARNING", "asctime": "2021-11-24 13:11:22,237", "message": "Missing metaconvert element", "module": "gstreamer_pipeline"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,237", "message": "Loading Pipeline: video_decode version: app_dst type: GStreamer from /home/video-analytics-serving/pipelines/video_decode/app_dst/pipeline.json", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,241", "message": "Loading Pipeline: object_tracking version: object_line_crossing type: GStreamer from /home/video-analytics-serving/pipelines/object_tracking/object_line_crossing/pipeline.json", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,242", "message": "Loading Pipeline: object_tracking version: person_vehicle_bike type: GStreamer from /home/video-analytics-serving/pipelines/object_tracking/person_vehicle_bike/pipeline.json", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,242", "message": "Loading Pipeline: object_detection version: object_zone_count type: GStreamer from /home/video-analytics-serving/pipelines/object_detection/object_zone_count/pipeline.json", "module": "pipeline_manager"}
{"levelname": "WARNING", "asctime": "2021-11-24 13:11:22,243", "message": "Missing metaconvert element", "module": "gstreamer_pipeline"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,243", "message": "Loading Pipeline: object_detection version: app_src_dst type: GStreamer from /home/video-analytics-serving/pipelines/object_detection/app_src_dst/pipeline.json", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,244", "message": "Loading Pipeline: object_detection version: person_vehicle_bike type: GStreamer from /home/video-analytics-serving/pipelines/object_detection/person_vehicle_bike/pipeline.json", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,244", "message": "Loading Pipeline: object_classification version: vehicle_attributes type: GStreamer from /home/video-analytics-serving/pipelines/object_classification/vehicle_attributes/pipeline.json", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,245", "message": "===========================", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,245", "message": "Completed Loading Pipelines", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,245", "message": "===========================", "module": "pipeline_manager"}
{"levelname": "INFO", "asctime": "2021-11-24 13:11:22,335", "message": "Starting Tornado Server on port: 8080", "module": "main"}
WARNING:tornado.access:404 GET /api/v1/deviceinfo//api/v1/deviceinfo/30 (<IP_ADDRESS>) 4.44ms
WARNING:tornado.access:404 GET /api/v1/deviceinfo//api/v1/deviceinfo/30 (<IP_ADDRESS>) 0.92ms
{"levelname": "INFO", "asctime": "2021-11-24 13:11:59,762", "message": "Creating Instance of Pipeline object_detection/person_vehicle_bike", "module": "pipeline_manager"}
{"levelname": "ERROR", "asctime": "2021-11-24 13:12:00,470", "message": "Error on Pipeline 1: gst-core-error-quark: Your GStreamer installation is missing a plug-in. (12): ../gst/playback/gsturidecodebin.c(1024): no_more_pads_full (): /GstPipeline:pipeline9/GstURIDecodeBin:source:\nno suitable plugins found:\n../gst/playback/gstdecodebin2.c(4719): gst_decode_bin_expose (): /GstPipeline:pipeline9/GstURIDecodeBin:source/GstDecodeBin:decodebin0:\nno suitable plugins found:\nMissing decoder: text/html (text/html)\n", "module": "gstreamer_pipeline"}

Hi Smitesh,
I was able to recreate your issue, it is likely due to not using the raw format of the video.
Could you try:
./vaclient/vaclient.sh run object_detection/person_vehicle_bike https://github.com/intel-iot-devkit/sample-videos/blob/master/person-bicycle-car-detection.mp4?raw=true

The VA Serving README has the example command with the working URL for person vehicle bike. For other videos, you could get the raw format by going to the webpage of the media and right click on the "View raw"-> Copy link. In the upcoming release, we will have the commands separated out from the output in the README so they're easier to copy and try out.
If you continue to see issues, I would recommend checking proxy settings.

@smitesh-sutaria We believe this has been resolved with the http update provided above.  Please let us know if this is not the case.


Functions exercise

The functions exercise claims to be printing five characters, but it's printing six. The names should be updated.

Thx, I noticed the problem already last time, but some students figured out a way to do it :) So I would rather change the solution to fit the problem!


kernel/sched: Move thread suspend and abort under the scheduler lock

Historically, these routines were placed in thread.c and would use the
scheduler via exported, synchronized functions (e.g. "remove from
ready queue").  But those steps were very fine grained, and there were
races where the thread could be seen by other contexts (in particular
under SMP) in an intermediate state.  It's not completely clear to me
that any of these were fatal bugs, but it's very hard to prove they
weren't.
At best, this is fragile.  Move the z_thread_single_suspend/abort()
functions into the scheduler and do the scheduler logic in a single
critical section.
Signed-off-by: Andy Ross<EMAIL_ADDRESS>

Fix some plausible races that @andrewboie noticed before the holidays and that might be the cause of some SMP instability with userspace enabled.  I still can't manage to prove to myself that these could cause anything bad, but they should for sure be under unified locks.

and that might be the cause of some SMP instability with userspace enabled.

@andyross the problems I am seeing are orthogonal to user mode. You do not need my patch series to reproduce it.

This doesn't fix the issues I am seeing.
To reproduce more easily, apply this patch to the master branch, it happens without it but is much more frequent:
diff --git a/subsys/testsuite/ztest/src/ztest.c b/subsys/testsuite/ztest/src/ztest.c
index e1e0d60e39..544e99964c 100644
--- a/subsys/testsuite/ztest/src/ztest.c
+++ b/subsys/testsuite/ztest/src/ztest.c
@@ -349,6 +349,8 @@ void z_ztest_run_test_suite(const char *name, struct unit_test *suite)
                fail += run_test(suite);
                suite++;

+               k_sleep(200);
+
                if (fail && FAIL_FAST) {
                        break;
                }

And run sanitycheck -p qemu_x86_64

OK, let's open a bug on that.  FWIW: this change probably wants to go in at some point anyway, as the mismatched locking is a time bomb regardless.

@andyross there is a bug open, see https://github.com/zephyrproject-rtos/zephyr/issues/21317
No objections to this patch.


Feature/aws 2.3

Right, so, long time no speak. With Tour de France happening and awaiting the arrival of my first child I've had some time to review this.
There has been major changes to the AWS SDK Gem that I've now adopted for this one.
Major Changes

Further, code has been moved out of individual bin files and into a more structured Whenever::Elasticbeanstalk class. This has reduced duplication considerably.
By default, AWS EC2 Instance Credentials are passed as the credentials to use for checking tags etc.
Roles now include the traditional leader/non-leader in addition to the environmental from RACK_ENV environmental variable.

I've got this working on a staging environment but would like to get some feedback, particularly from @dignoe and @cyborgmaster due to their work.

I haven't used this gem in years (I've moved to using OpsWorks), so I don't feel that I can add much to this conversation. Please let me know if you need anything though (like github or rubygem permissions), and I'd be happy to help.

@jufemaiz, I really like the approach you've taken here.  Seems like the refactoring is going in a good direction.  I can't say wether it works correctly because the only real way to test it is to run in inside elastic beanstalk in a real instance, but assume it works, I'm all for it.

I can actually test this out, as I am have one spare Beanstalk instance running for testing. I have commented on an issue. @jufemaiz may be we can get in touch and figure out something

@binodmainali1 note the requirements to work with git based gems.

@jufemaiz It looks like you have access on Rubygems to update the packaged gem.

@dignoe yep, just wasn't really wanting to push something there without a bit of a review.
For those wanting to test, have a read of https://gist.github.com/jufemaiz/eba1ee62c3709d2db90cc16eb2c5c10b

Right I think I'm at a stage to make this a v2.0.0-beta0 release.
Any objections?

Hi!
I just tested it and webapp user's cron gives error (CRON) ERROR chdir failed (/home/webapp): No such file or directory on run (on /var/log/cron log).
I investigated it a bit and seems that cron needs user's home directory for internal needs, so I think the easiest workaround is to create it and give access to webapp user.
Also something weird happened to logs, there is a symlinks loop:
# ll /var/app/containerfiles/logs/production.log
lrwxrwxrwx 1 webapp webapp 35 Aug 11 13:32 /var/app/containerfiles/logs/production.log -> /var/app/current/log/production.log

#ll /var/app/current/log/development.log
lrwxrwxrwx 1 webapp webapp 36 Aug 11 13:32 /var/app/current/log/development.log -> /var/app/current/log/development.log

Seems related to config from Rails + GIT gist.

@jufemaiz Still thinking about a v2.0.0-beta0 release on rubygems.org?


Stratux reliably drops out in a Manhattan tour

Stratux version: v1.4r5

Stratux config:
SDR

[ ] single
[X] dual

GPS

[X] yes
[ ] no
type: Vk-162 USB puck

AHRS

[ ] yes
[X] no

power source: Previously-recommended EasyAcc 6Ah battery w/built-in USB-micro
usb cable: (see above)

EFB app and version: Latest ForeFlight
EFB platform: Latest iOS
EFB hardware: iPad Mini 2

Description of your issue:

My iPad reliably loses its connection to Stratux when I do a city tour, which involves circling the island of Manhattan at 1500-2000'. I thought the unit was simply flaky, since it has been in the past. But I did two flights in the same day last time - a ~100nmi round-trip, during which the Stratux worked 100% perfectly, and the city tour, during which it disconnected.
I have the ForeFlight track log, which I've attached. You can see when it dropped out by when the vertical lines representing the points disappear. It was disconnected the entire way south from about the Harlem River until the southern tip of Manhattan (missing a turn over Central Park and south down the East River), good around the Statue of Liberty, then disconnecting again between the southern tip and the Harlem River going back northbound.
I didn't think to enable the replay logs in advance (I'll do that next time), but I did open the webapp on the northbound return and the uptime was 50 minutes (since before engine start), so the unit hadn't rebooted. I was having trouble getting the webapp page to load, though it's a high workload time so I didn't notice specifically if that correlated with the outage.

Is it possible that the device is overloaded with traffic in the vicinity? Is this known to happen? I have the high-gain antennas, so I pick up tons of traffic in the area from the three major airports and all the choppers. It runs hot, but I have the cooling fan and it never gets what I'd consider dangerously hot for silicon.
Are there any known iPad performance requirements in the face of high traffic? The Mini 2 is showing its age; is it possible it just couldn't keep up?
Is it possible that some government security ... thing could jam the Stratux? It seems roughly centered on Trump Tower... I lose both traffic and GPS position, so it doesn't seem like a GPS jammer as that shouldn't affect traffic reception, right? (Foreflight considers the Stratux to have disconnected during the outage.)

Mostly I'm asking if there are any known explanations for this behavior, specifically if there's any known limits on nearby traffic density due to the SDRs or processing capability. I've never done the flight with a Stratus device, I could try that and see if it does better during that portion of the flight. Presumably if it's an overload issue, the non-commodity-hardware in a Stratus would do better. But maybe it's not that at all and I can try something else.
(I've been really impressed with the reliability recently. I had serious disconnect issues until the April build, resolved by minimizing and re-opening Foreflight, but since then - with the exception of this flight - it's been quite reliable. Thanks for all the hard work!)
kcdw-hudson-stratux.kml.zip

I am in the middle of the lines without GPS and (on the roof) I do get ~30 radius of ADS-B traffic (as of 7/31 7pm - when I was testing the high-gain and the white box) and GPS. I kept it running for 5min or so.

I doubt it is being overloaded by traffic. I had to turn off traffic in Foreflight during the arrival to Oshkosh since Foreflight was getting really bogged down.

It had been, but I just did a city tour on Saturday and it was fine, though I didn't do the East River that time.
A few things have changed:

New iPad Mini instead of v2 from ~2014. (But I seem to recall checking the Stratux logs the last time this happened and seeing evidence it was on the Stratux, not iPad.)
New low-power ASIC-based UAT radio, and updated Stratux image for compatibility.
Quiet airspace due to an imminent Yankees TFR.

I'll make sure logging is enabled next time in case it happens again, and I'll re-open if so.


Enhancement Request: Export and Import Settings

Description of the new feature / enhancement
Allow a user to export all the settings they have in PowerToys and then import them again.
Scenario when this would be used?
Scenario 1 - As a backup
Scenario 2 - Setting up PowerToys on a new computer.
Supporting information
No response

/dup #586 and #3381


[Task]: Refactor module instance in app

Is there an existing issue for this?

[X] I have searched the existing issues

SubTasks
No response

Already resolved through this issue
https://app.zenhub.com/workspaces/modules-pod-63e0d668a7fea03850c89c6f/issues/gh/appsmithorg/appsmith/28920


[4.0][FIX] select2 ajax dont update value on clear

Hey guys!
This issue have been reported in #2264
While working in solving this issue i noticed that ajax select didn't had the same rules applied as the other selects so i go ahead, fixed this issue and fixed inconsistencies i found.
Rules added:

If database column is nullable and developer don't force allows_null => false by default the select is nullable. Changing allows_null to false will make this select behave as a non-nullable column, always selecting one default option and don't allowing send empty values.

NOTE: As the options are gathered via ajax, when no default is provided we select the last entry in the connected entity.

If database column is not nullable, by default we don't allow empty selects and apply the behavior described above note.

We were also having the problem of the field already marked as loaded so i also re-write most of the field to JS so it would be usable in repeatable.
ABOUT TESTS: I tried to test every scenario. Also created a NON-NULLABLE column to test with with different column types. But please, test it again, as we talked manual browser tests could get rigged by taking so many scenarios and variables to test.
Best,
Pedro

Can this fix be merged please?

I was going to merge this right now, but I'm afraid some of the issues I've found could break people's apps, so I can't merge it as-is, and would like @pxpm 's feedback for the changes I proposed. @pxpm thanks a lot for taking the time to fix this, and to make it better. I've found a few issues with the PR though, please check my inline comments and make the changes if you agree and have the time. By the looks of it, this needs more testing, even after the changes I proposed.
@timbertens if you need this fix ASAP, and you're only using "id" as your primary columns, I suggest you do a php artisan backpack:publish crud/fields/select2_from_ajax to publish the file in your resources/views/vendor/backpack/crud/fields, and change the content to @pxpm 's updated file here. When we've merged the PR, you can just delete that custom file.

I am going to close this as the changes proposed here have been also made in #2308 and corrected @tabacitu issues.

Closing this in favor of #2426


[ISSUE-847][REFACTOR] Migrate codec conf to Celeborn Configuration System

What changes were proposed in this pull request?
Why are the changes needed?

What are the items that need reviewer attention?
Related issues.
close #847
Related pull requests.
How was this patch tested?
/cc @related-reviewer
/assign @main-reviewer

ping @pan3793