Segfault: using generics

Hi, thank you for crystal. I am moving from ruby and scala to crystal because i think it is better than both of them. This is a segfault i stumbled upon (code abstracted from a project):
require "http/request"

class Ctx # think "Context"
  @req :: HTTP::Request
  getter :request

  def initialize(@request : HTTP::Request)
  end
end

class CCtx(T) < Ctx
  def initialize(@original : T)
    @request = @original.request
  end
end

class SCtx(T) < Ctx
  def initialize(@original : T)
    @request = @original.request
  end
end

class M # think "Middleware"
  getter :successor
  def initialize(@successor = nil)
  end
  def call(ctx : Ctx) : HTTP::Response
    case s = successor
    when M then s.call(ctx)
    when Nil then HTTP::Response.not_found
    else raise "invalid param"
    end
  end
end

class CM < M
  def call(ctx : T) : HTTP::Response
    super(CCtx(T).new(ctx))
  end
end

class SM < M
  def call(ctx : T) : HTTP::Response
    super(SCtx(T).new(ctx)) # this line seems to cause the segfault. remove this one and uncomment the next line and it does not segfault.
    #super(ctx)
  end
end

m = CM.new(SM.new)
puts "a"
r = HTTP::Request.new("GET", "")
r.headers.merge!({"Cookie" => "test=1;"})
ctx = Ctx.new(r)
puts "b"
m.call(ctx)
puts "c"

version: 0.7.7

I am moving from ruby and scala to crystal because i think it is better than both of them

@Ragmaanir Wow! That's a really nice compliment! We are trying to keep the language simple but at the same time powerful :-)
The segfault in your code is because of an infinite expansion of a generic type. This is a duplicate of #793. And because it's such a common error, I decided to partially fix this by setting a limit on the nesting of generic instance types (right now is 100, which should be enough... a generic type like Foo(Bar(Baz(... 100 times))) should be pretty rare. That's until we find a proper "mathematically correct" solution to this.
In your example, you have CM#call do  CCtx(T) and SM#call do SCtx(T), and then invoking super with those... which in turn invoke call with those types, so you'll get CCtx(CCtx(T)), CCtx(CCtx(CCtx(T))) and so on.
With the HEAD compiler you should now get an error on this:

generic type too nested: SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(SCtx(CCtx(Ctx+)))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))

@asterite We are getting this error while running test suite of postgres_adapter.cr: https://github.com/waterlink/postgres_adapter.cr/commits/updating_deps_version
Was the number of maximum allowed generic nestedness decreased?
Error message can be found here: https://github.com/waterlink/postgres_adapter.cr/pull/8#issuecomment-232515763
It doesn't seem to be anywhere near 100 nestedness.. It is < 30.

I think the limit is <= 10 in the code currently.

The limit will be extended in the future once we figure out a way to detect recursive generic instantiation.
I would try to model the problem in a different way, creating so many types (each generic instantiation is a different type) will lead to slower compilation and more memory consumed. I'd move that query construction to runtime.

Could a higher limit be set? I'm also doing some work on query construction at compile time and I'm hitting this limit away too quickly, with just 5 nested levels (because the generic of some classes use splat, so I guess it each level count as two). Anywhere between 30 and 100 should be good.

I think we actually don't need a limit. The problem is that if this isn't limited then a stack overflow will happen in the compiler, and it's hard to figure out why, this way.
The solution is to figure out a correct way to detect this recursion, without checking a limit. But I don't know how, yet.
Some examples:
class Gen(T)
end

def foo
  Gen(typeof(foo))
end

foo

class Gen(T)
end

def foo
  Gen(typeof(bar))
end

def bar
  Gen(typeof(foo))
end

foo

The limit was reduced here: https://github.com/crystal-lang/crystal/commit/ce51d5c8
But after 0.16.0 this code doesn't compile and requires a type annotation. I think we can remove the limit and eventually try to fix it well. But in this way we don't fail to compile valid programs.

Another example, reduced from the above:
class Gen(T)
end

class Foo
  def call(ctx : T)
    call(Gen(T).new)
  end
end

m = Foo.new
m.call(1)

I actually wonder if detecting this is similar to solving the halting problem... other compiles deal well with this because they don't "instantiate" methods on specific types, they just check that it compiles well.
@waterlink @lbguilherme What are your use cases? I understand that modelling integer addition with generic classes is nice, or modelling SQL expressions with generic types is nice, but once you add some dynamism (generating a math expression conditionally, or generating part of an sql expression conditionally) then there will be runtime dispatch between the different generic types, so there will always be a runtime overhead. I think it's better to model these things in a simpler way: without generic types.

My usecase actually didn't involve any generic types until recently, when I
had to type-annotate everything, I had to provide type for something that
can really be of any type, but it can not be of query type though, so maybe
in my case more specific type annotation might remove need for generics.
Additionally, having implicit interfaces (as discussed in some other issue)
will help me greatly with all sorts of problems I face with current type
system (and hacks I have to do, which will probably break in the next
version of crystal).
Ary Borenszweig<EMAIL_ADDRESS>schrieb am So., 17. Juli 2016 um
7:05 PM:

Another example, reduced from the above:
class Gen(T)end
class Foo
def call(ctx : T)
call(Gen(T).new)
endend
m = Foo.new
m.call(1)
I actually wonder if detecting this is similar to solving the halting
problem... other compiles deal well with this because they don't
"instantiate" methods on specific types, they just check that it compiles
well.
@waterlink https://github.com/waterlink @lbguilherme
https://github.com/lbguilherme What are your use cases? I understand
that modelling integer addition with generic classes is nice, or modelling
SQL expressions with generic types is nice, but once you add some dynamism
(generating a math expression conditionally, or generating part of an sql
expression conditionally) then there will be runtime dispatch between the
different generic types, so there will always be a runtime overhead. I
think it's better to model these things in a simpler way: without generic
types.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/crystal-lang/crystal/issues/1408#issuecomment-233192127,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AAlLFn2dwY2EjZJylQ54JNDsVkYe0RZIks5qWmDTgaJpZM4F5KH1
.

@waterlink Maybe you can use an empty module as an "interface"?
In any case, we'd have to look at the code to know the problem.

I will try to cleanly re-write the query mechanism in a separate snippet of code and reproduce the issue, so that we can look at possible solutions. Plus I will try out some of the solutions.

For my usecase, I'm implementing the query language of RethinkDB, it is mostly a simple functional language without recursion.
Previously (the current version) the query was being built and stored in a JSON::Type-like structure. It works, but makes things like pretty-printing the query hard. Next method was to consider each query function as a class and create a tree representing the query, where there is an abstract base class that serves as a type to describe any of them. Again, this works, and also allow to easily print/inspect the query.
I advanced from that to using generics first because it would be nicer and because it would be probably much faster at runtime (everything could be structs, not classes. no polymorphic calls needed, no GC pressure). This has let me add some compile-time checks if the query is consistent (errors that would be returned by the database server upon execution).
So, this is just something nice to have, and that could improve runtime performance, but not critical.

@lbguilherme Out of curiosity, where are the RthinkDB docs of how a driver should map API methods to JSON? I couldn't find it anywhere. Also, maybe Term and all of its subclasses could be structs? They seem to be immutable.

@asterite The entire available documentation about driver writing is this page: http://rethinkdb.com/docs/writing-drivers/
I had to read source code of a few other drivers to understand some details. A example of query:
conn = r.connect(host: "localhost")
p r([15, 16, 17]).
    map {|x| r.branch(x % 2 == 0, "even", "odd") }.
    reduce {|a, b| a + "-" + b }.
    run(conn) # "odd-even-odd"

All executed server-side. The blocks are evaluated on the client once replacing the arguments by a special argument Term and the whole thing is sent to the server. About encoding:
r.db("database").table("table").get("document_id")

Is converted to:
r.get(r.table(r.db("database"), "table"), "document_id") # this query is also valid and equivalent

Which becomes:
[GET, [[TABLE, [[DATABASE, ["database"]], "table"]], "document_id"]] # the constants are numbers

and is sent as JSON to the server. The query is always represented as a tree or function calls and their arguments. Every "function" struct could extend a base Term, but then the only way to store their arguments as instance variables are if generics is used, or if they are classes and not structs. Or else, the structure will be recursive, but they are indeed immutable.

If the query is always an array of terms, which are either those constants or string/ints (JSON::Any), can't the query be just a struct wrapping an array of these? Then there's no type recursion.
(By the way, your driver implementation looks really nice! I also like it that the result is a cursor that includes Iterator, for example)

can't the query be just a struct wrapping an array of these?

It can. Actually, this is how it is now. The problem is that I want to implement inspect for queries, returning the query written in Crystal as a string. I could implement it by decoding the query from the JSON form, but then I would be implementing both encoding and decoding of queries on the client. There is no need for that.

(By the way, your driver implementation looks really nice! I also like it that the result is a cursor that includes Iterator, for example)

Thanks! A pleasure of language to work with :)

I tried to think of other languages which could lead to an infinite recursive expansion of generics. Java and C# don't have this problem because the return type is never inferred. Then I remembered D. Let's see:
class Gen(T) {
}

auto call(T)(T x) {
  return call(new Gen!T);
}

void main() {
  call(1);
}

Compiling:

recursive expansion
d2.d(5): Error: template instance d2.call!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!(Gen!int)))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))) recursive expansion

The number of "Gen!" there is 300, so search a bit: https://github.com/dlang/dmd/blob/f1719912f1bfe75072ebd3857626f88e415cb23c/src/dtemplate.d#L8264-L8279
So at least in D the limit is bigger. I think we can increase the limit, but I guess there will always be a limit... I'll change it to 300 for now.

Just as reference, C++ does the same:
GCC (limit = 900)
main.cpp: In instantiation of 'auto call(T) [with T = Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<int> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >]':
main.cpp:9:30:   recursively required from 'auto call(T) [with T = Gen<Gen<int> >]'
main.cpp:9:30:   required from 'auto call(T) [with T = Gen<int>]'
main.cpp:12:20:   required from here
main.cpp:9:31: fatal error: template instantiation depth exceeds maximum of 900 (use -ftemplate-depth= to increase the maximum)
 auto call(T gen) {return call(Gen<T>());}
                               ^~~~~~~~
compilation terminated.

Clang (limit = 256)
main.cpp:9:31: fatal error: recursive template instantiation exceeded maximum depth of 256
auto call(T gen) {return call(Gen<T>());}
                              ^
main.cpp:9:26: note: in instantiation of function template specialization 'call<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<int> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >' requested here
auto call(T gen) {return call(Gen<T>());}
                         ^
main.cpp:9:26: note: in instantiation of function template specialization 'call<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<int> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >' requested here
main.cpp:9:26: note: in instantiation of function template specialization 'call<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<int> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >' requested here
main.cpp:9:26: note: in instantiation of function template specialization 'call<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<int> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >' requested here
main.cpp:9:26: note: in instantiation of function template specialization 'call<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<Gen<int> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > > >' requested here
main.cpp:9:26: note: (skipping 247 contexts in backtrace; use -ftemplate-backtrace-limit=0 to see all)
main.cpp:9:26: note: in instantiation of function template specialization 'call<Gen<Gen<Gen<Gen<Gen<int> > > > > >' requested here
main.cpp:9:26: note: in instantiation of function template specialization 'call<Gen<Gen<Gen<Gen<int> > > > >' requested here
main.cpp:9:26: note: in instantiation of function template specialization 'call<Gen<Gen<Gen<int> > > >' requested here
main.cpp:9:26: note: in instantiation of function template specialization 'call<Gen<Gen<int> > >' requested here
main.cpp:12:5: note: in instantiation of function template specialization 'call<Gen<int> >' requested here
    call(Gen<int>());
    ^
main.cpp:9:31: note: use -ftemplate-depth=N to increase recursive template instantiation depth
auto call(T gen) {return call(Gen<T>());}
                              ^
1 error generated.

Microsoft Visual C++ (limit = 400)
source_file.cpp(9): fatal error C1202: recursive type or function dependency context too complex

@lbguilherme Interesting! So I guess for now this solution is OK, as either the solution to the problem doesn't exist or it's very hard to solve.

I have pin-pointed minimal example from my use case: is to be able to iterate over the hash pairs of key and values and be able to construct respective query with key1 = value1 && key2 = value2 && key3 = value3 && .... The code:
require "spec"

module EqualityHelper
  def self.equals(left : Criteria, right : Criteria)
    left.name == right.name
  end

  def self.equals(left : Criteria, right)
    false
  end

  def self.equals(left, right)
    left == right
  end
end

class Query
  def &(other)
    And.new(self, other)
  end
end

class EmptyQuery < Query
end

class BiOperator(A, B) < Query
  getter left
  getter right

  def initialize(@left : A, @right : B)
  end

  def ==(other : self)
    EqualityHelper.equals(left, other.left) &&
    EqualityHelper.equals(right, other.right)
  end

  def ==(other)
    false
  end
end

class And(A, B) < BiOperator(A, B)
end

class Equals(A, B) < BiOperator(A, B)
end

class Criteria
  getter name

  def initialize(@name : String)
  end

  def ==(other)
    Equals.new(self, other)
  end
end

def criteria(name)
  Criteria.new(name)
end

it "can be used to append things" do
  q = EmptyQuery.new
  query_hash = {"number_of_dependents" => 0}

  query_hash.each do |key, value|
    q = q.& criteria(key) == value
  end

  q.should eq(
    Equals.new(Criteria.new("number_of_dependents"), 0)
  )
end

I am getting:
Error in line 68: instantiating 'Hash(String, Int32)#each()'

in line 68: instantiating 'Hash(String, Int32)#each()'

in line 69: instantiating '(And(And(And(And(And(And(And(And(And(EmptyQuery, Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)) | And(And(And(And(And(And(And(And(EmptyQuery, Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)) | And(And(And(And(And(And(And(EmptyQuery, Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)) | And(And(And(And(And(And(EmptyQuery, Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)) | And(And(And(And(And(EmptyQuery, Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)) | And(And(And(And(EmptyQuery, Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)) | And(And(And(EmptyQuery, Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)) | And(And(EmptyQuery, Equals(Criteria, Int32)), Equals(Criteria, Int32)) | And(EmptyQuery, Equals(Criteria, Int32)) | EmptyQuery)#&(Equals(Criteria, Int32))'

in line 19: generic type too nested: And(And(And(And(And(And(And(And(And(And(EmptyQuery, Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32)), Equals(Criteria, Int32))

https://carc.in/#/r/1477
I am not even sure how compiler produces this. Such loops seems to force compiler to find out all possible generic types, that can be result of this.
I have an idea, is to explicitly specify, that I return an abstract type, like Query, so that compiler would not have to expand all of this stuff.

Strangely enough even that doesn't work, adding : Query at the end of all methods that produce queries, still forces compiler to expand all types. I can't seem to understand why compiler even would need that?

Oh, I have found some bug in compiler: https://carc.in/#/r/147a

@asterite Smaller version of that bug:
class Query
end

class Equals(T) < Query
  def initialize(@left : Query, @right : T)
  end
end

pp Equals.new(Query.new, 32)

I am not sure what is happening here:
Error: you've found a bug in the Crystal compiler. Please open an issue, including source code that will allow us to reproduce the bug: https://github.com/crystal-lang/crystal/issues

Bug: Equals(Int32) doesn't implement add_def
[135833699] ???
[142726759] ???
[144137863] ???
...
[136080965] ???
[135919612] main +19596
[3072771382] __libc_start_main +246
[135823234] ???

https://carc.in/#/r/147i

Ok. Now I start to understand how that works. Compiler seems to be lacking an abstraction feature, where some class hierarchy can be hidden completely behind some sort of an interface and what exactly is there will matter only at runtime via polymorphism.
What I mean, is that, when I say, that something returns : Query, compiler should not bother with what I actually am returning as long as it has Query in its inheritance hierarchy (base class, included module, or currently non-existing interfaces/protocols).
I see that as soon as I have converted Query to abstract module. It has blown up immediately even with that test commented out, since it has tried to instantiate all the possible types, that could satisfy being Query, and obviously the count is infinity.
To me it feels, that I want Query to be a proper interface. Like java interface or go interface. Something that I can rely on as an abstraction that does not let any types leak through.

I ran into that error myself. It looks like it has to do with #inspect. This one works:
class Query
  def inspect(io : IO)
    io << "Query"
  end
end

class Equals(T) < Query
  def initialize(@left : Query, @right : T)
  end

  def inspect(io : IO)
    io << "Equals(#{@left.inspect},#{@right})"
  end
end

pp Equals.new(Query.new, 32)

https://carc.in/#/r/1485

@Ragmaanir thanks, that helped me to overcome this error!

Ok. That seems to be a good start:
require "spec"

module EqualityHelper
  def self.equals(left : Criteria, right : Criteria)
    left.name == right.name
  end

  def self.equals(left : Criteria, right)
    false
  end

  def self.equals(left, right)
    left == right
  end
end

class Query
  def &(other) : Query
    And.new(self, other)
  end

  def inspect(io)
    io << "Query"
  end
end

class EmptyQuery < Query
  def ==(other : EmptyQuery)
    true
  end

  def ==(other)
    false
  end

  def inspect(io)
    io << "EMPTY_QUERY"
  end
end

class BiOperator(T) < Query
  getter left
  getter right

  def initialize(@left : Query, @right : T)
  end

  def ==(other : self)
    EqualityHelper.equals(left, other.left) &&
      EqualityHelper.equals(right, other.right)
  end

  def ==(other)
    false
  end

  def inspect(io)
    io << "#{self.class.name}(#{left.inspect}, #{right.inspect})"
  end
end

class And(T) < BiOperator(T)
end

class Equals(T) < BiOperator(T)
end

class Criteria < Query
  getter name

  def initialize(@name : String)
  end

  def ==(other) : Query
    Equals.new(self, other)
  end

  def inspect(io)
    io << "Criteria(#{name.inspect})"
  end
end

def criteria(name)
  Criteria.new(name)
end

it "can be used to append things" do
  q = EmptyQuery.new
  query_hash = {"number_of_dependents" => 0}

  query_hash.each do |key, value|
    q = q.& criteria(key) == value
  end

  q.should eq(
    And.new(EmptyQuery.new, Equals.new(Criteria.new("number_of_dependents"), 0))
  )
end

And if I run it:
.

Finished in 108 microseconds
1 examples, 0 failures, 0 errors, 0 pending

https://carc.in/#/r/148j
Will check tomorrow if it works with more queries (like Not and Or and others).

Seems, that expecting @left : Query is the key to overcoming this problem.. This way we can append with q = q.& ... and only type of ... will have to be completely expanded. And the type of expression in my concrete use case will always be no deeper than 3 levels because of that.

@waterlink Yes, there are two things here:

The bug with inspect: it's a macro method, and the compiler tries to add that method to a generic type instance, something that's currently not possible. We didn't consider this scenario, but it can be done, so just a bug.
Hiding hierarchies behind an interface. This can be done right now, more or less: you can use an abstract class or a module. The "problem" is that the compiler will try to figure out the type of a method by checking at all subclasses or including types. This is a problem with generic types because then the compiler depends on which types were instantiated.

Point 2 is this:
# We have a module (kind of like an interface)
module Moo
  abstract def moo
end

# This generic class implements this interface
class Foo(T)
  include Moo

  def initialize(@x : T)
  end

  def moo
    @x
  end
end

class MooHolder
  def initialize(@moo : Moo)
  end

  def some
    # We need to check all `moo` methods,
    # but Foo(T) is generic
    @moo.moo
  end
end

moo_holder = MooHolder.new(Foo.new(1))

# What's the type of this?
moo_holder.some

Before Crystal 0.16.0 the answer is easy: Int32. This is because Foo(Int32) is the only instantiation that includes Moo. After 0.16.0 this same algorithm is more or less applied too, but what we need is to infer the type without knowing all the types that were instantiated (otherwise it's much harder to do incremental compilation, or an efficient compilation).
One solution is to consider Foo(T) as being an implementation of Moo, and when invoking Moo#moo, we have Foo(T)#moo which returns @x. @x is of type T, which can be basically an object, so the return type is deduced to be Object. No need to check which types were instantiated.
To make it complete and more useful, one should be able to say Foo(T < X) so that instead of inferring Foo(T)#moo to be Object it would be X.
I'll link #2665 because this is basically that: we need to redesign some parts of the compiler and type system to work in the above way. It's not a huge change but it needs a bit of design time + implementation.

Ok, I have made everything work here well: https://github.com/waterlink/query.cr/
Will need to write documentation for this thing and integrate it to active_record.cr.

@asterite @Ragmaanir @lbguilherme
Thank you everyone for their help!


spots not shown correctly for my Visium data

Dear Cirro Team,
Thanks again for the great tool and active support. I have one Visium data with ~500 spots and processed with Seurat. When I tried to visualize the data with cirro launch (1.1.54), the spots are not shown but only the image. Please see below a screenshot:

Below is what I expected to see with Seurat SpatialPlot() with option crop=F

It seems that the spot coordinates are incorrect in the data but I am not sure which slot cirro is using and how to incorporate the correct ones.
Many thanks for your support!
Zhigang

Hi,
Thanks for your email. Please create a spatial directory with the following:
Directory containing 10x visium spatial data (tissue_hires_image.png,
scalefactors_json.json, and tissue_positions_list.csv) or a directory
containing image.png, positions.image.csv with
                    headers barcode, x, and y, and optionally

diameter.image.txt containing spot diameter
Best,
Josh
On Mon, May 29, 2023 at 1:58 AM Zhigang Lu @.***> wrote:

Dear Cirro Team,
Thanks again for the great tool and active support. I have one Visium data
with ~500 spots and processed with Seurat. When I tried to visualize the
data with cirro launch (1.1.54), the spots are not shown but only the
image. Please see below a screenshot:
[image: Screenshot 2023-05-29 at 07 08 28]
https://user-images.githubusercontent.com/12518670/241654439-99ac13cd-82aa-470a-89db-7fae14651ee9.png
Below is what I expected to see with Seurat SpatialPlot() with option
crop=F
[image: Screenshot 2023-05-29 at 07 10 30]
https://user-images.githubusercontent.com/12518670/241654774-dafc38fc-8712-4848-945c-829d1700b96e.png
It seems that the spot coordinates are incorrect in the data but I am not
sure which slot cirro is using and how to incorporate the correct ones.
Many thanks for your support!
Zhigang
—
Reply to this email directly, view it on GitHub
https://github.com/lilab-bcb/cirrocumulus/issues/193, or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABH6TH222A4K3MZX73QNLGLXIQ3H5ANCNFSM6AAAAAAYSL2NF4
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>

Hi Josh,
Here is the directory with files: https://drive.google.com/drive/folders/1L4rc3bRKD99ELpu3SayKYyAQDFDJpKHx?usp=sharing
Many thanks!
Zhigang

I believe the issue is that tissue_positions_list.csv should contain a
header row with the columns barcode, x, and y. Also please note that the
diameter should be in a file named diameter.image.txt.
Best,
Josh
On Tue, May 30, 2023 at 9:53 AM Zhigang Lu @.***> wrote:

Hi Josh,
Here is the directory with files:
https://drive.google.com/drive/folders/1L4rc3bRKD99ELpu3SayKYyAQDFDJpKHx?usp=sharing
Many thanks!
Zhigang
—
Reply to this email directly, view it on GitHub
https://github.com/lilab-bcb/cirrocumulus/issues/193#issuecomment-1568477146,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABH6TH3H7V64TH3RGO67CJTXIX3VTANCNFSM6AAAAAAYSL2NF4
.
You are receiving this because you commented.Message ID:
@.***>

Sorry, I take that last note back. Since this is 10x data, it should handle
the output without issue. Let me investigate.
Best,
Josh
On Tue, May 30, 2023 at 10:46 AM Joshua Gould @.***>
wrote:

I believe the issue is that tissue_positions_list.csv should contain a
header row with the columns barcode, x, and y. Also please note that the
diameter should be in a file named diameter.image.txt.
Best,
Josh
On Tue, May 30, 2023 at 9:53 AM Zhigang Lu @.***>
wrote:

Hi Josh,
Here is the directory with files:
https://drive.google.com/drive/folders/1L4rc3bRKD99ELpu3SayKYyAQDFDJpKHx?usp=sharing
Many thanks!
Zhigang
—
Reply to this email directly, view it on GitHub
https://github.com/lilab-bcb/cirrocumulus/issues/193#issuecomment-1568477146,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABH6TH3H7V64TH3RGO67CJTXIX3VTANCNFSM6AAAAAAYSL2NF4
.
You are receiving this because you commented.Message ID:
@.***>

Hi Josh, thanks a lot for your support. I will ask for permission from the data owner and then send you the files.

Please note that you can subset the h5ad file to include only one gene as
don’t need this part of the data to debug. Thanks
On Tue, May 30, 2023 at 4:40 PM Zhigang Lu @.***> wrote:

Hi Josh, thanks a lot for your support. I will ask for permission from the
data owner and then send you the files.
—
Reply to this email directly, view it on GitHub
https://github.com/lilab-bcb/cirrocumulus/issues/193#issuecomment-1569067858,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABH6THZ54K4KZU2S4LYYNGTXIZLLLANCNFSM6AAAAAAYSL2NF4
.
You are receiving this because you commented.Message ID:
@.***>

Hi Josh,
Thanks for the tip and your patience. I just figured it out that this happens when I split data of one section from a harmony-integrated object. When I use a single section data, the visualisation is normal.
Regarding this, what would be the best way to visualize an integrated object containing multiple sections? I am not sure how to concatenate the spatial images that match the integrated dataset.
Many thanks,
Zhigang

Please see the concat command -
https://cirrocumulus.readthedocs.io/en/latest/commands.html#concatenate
On Thu, Jun 1, 2023 at 9:35 AM Zhigang Lu @.***> wrote:

Hi Josh,
Thanks for the tip and your patience. I just figured it out that this
happens when I split data of one section from a harmony-integrated object.
When I use a single section data, the visualisation is normal.
Regarding this, what would be the best way to visualize an integrated
object containing multiple sections? I am not sure how to concatenate the
spatial images that match the integrated dataset.
Many thanks,
Zhigang
—
Reply to this email directly, view it on GitHub
https://github.com/lilab-bcb/cirrocumulus/issues/193#issuecomment-1572066592,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABH6THZMRXWK2SECZN7YKA3XJCLDXANCNFSM6AAAAAAYSL2NF4
.
You are receiving this because you commented.Message ID:
@.***>


fix(stax): loading multiple invalid pictures and going back will navigate on correct page

📝 Description
Back arrow on error page navigate to initial page.
Before
https://github.com/LedgerHQ/ledger-live/assets/146743014/974e9a79-eace-498b-a4d9-88f6bc6f6f49
After
https://github.com/LedgerHQ/ledger-live/assets/146743014/95089369-8154-41e9-9d90-818dc898e2e1
❓ Context
LLM
LIVE-7703
✅ Checklist
Pull Requests must pass the CI and be code reviewed. Set as Draft if the PR is not ready.

[x] npx changeset was attached.
[ ] Covered by automatic tests.
[ ] Impact of the changes:

Change the back arrow component on error page
Change navigation of the back arrow button on the error page

🧐 Checklist for the PR Reviewers

[ ] The code aligns with the requirements described in the linked JIRA or GitHub issue.
[ ] The PR description clearly documents the changes made and explains any technical trade-offs or design decisions.
[ ] There are no undocumented trade-offs, technical debt, or maintainability issues.
[ ] The PR has been tested thoroughly, and any potential edge cases have been considered and handled.
[ ] Any new dependencies have been justified and documented.
[ ] Performance considerations have been taken into account. (changes have been profiled or benchmarked if necessary)

@ak-ledger, it looks like the Experimental header overlaps the head with the back button with this change as in the"before" video we don't have the issue, could you have a look, please?


Add active bookmark in Mercurial repositories

Issue
I love the spaceship theme, but I use Mercurial bookmarks, which are not currently displayed in the prompt. I would suggest that if there's an active bookmark then the bookmark name is displayed in place of the current branch. The currently active bookmark can be determined using the command hg log -r . -T '{activebookmark}'
Screenshot

Environment
Operating system: macOS
Terminal emulator: iTerm2
ZSH version: zsh 5.4.1 (x86_64-apple-darwin16.7.0)

Thank you @davehunt for the suggestion. Could you send please a PR for this ?
// @dguay @geromueller

I would like this too.

Does this mean that this feature is added in a future release?

Hey there. Any progress on this? Would love to see it shipped :)


Jpeg2000 read/write image fix

When TypeDesc is set to INT8 plugin should save 8-bit data to the file, not 16-bit (read_scanlin write_scanline should be typed to uint8_t).
Run the testsuite and this patch don't broke anything.

Are there signed 8 bit J2K's out there?
If you look at jpeg2000input.cpp, line 202, we can't possibly set the format to INT8.  But in some sense, that is where the real bug is (if there are INT8 JPEG's).  So your new code can't change any behavior.
There is a similar bug in jpeg2000output.cpp, where I think it won't behave properly if the user passes a non-UINT8, non-UINT16 buffer.  I think the lines you changed are just one part of the chain of events that needs to be fixed.

Ah, thats good points, now I'm not sure why I prepared this pull request, brobably was tired when writing this code:) I close this pull request and prepare other


Exception calling "Replace"  with "2" argument(s): "The RegEx engine has timed out while trying to match a pattern to an input string'

Issue
When this task is run within an Azure DevOps pipeline a Windows agent the following error is sometimes seen

##[error]Import-Json : Import failed for
'E:\Agent_work\92\s\Src\Expenses\BlackMarble.ISS.Bicep\ARMOutput\RootTemplate-Main.json': Exception calling "Replace"
with "2" argument(s): "The RegEx engine has timed out while trying to match a pattern to an input string. This can
occur for many reasons, including very large inputs or excessive backtracking caused by nested quantifiers,
back-references and other factors." Exception calling "Replace" with "2" argument(s): "The RegEx engine has timed out
while trying to match a pattern to an input string. This can occur for many reasons, including very large inputs or
excessive backtracking caused by nested quantifiers, back-references and other factors." Exception calling "Replace"
with "2" argument(s): "The RegEx engine has timed out while trying to match a pattern to an input string. This can
occur for many reasons, including very large inputs or excessive backtracking caused by nested quantifiers,

I suspect the issue is down to the complexity of the ARM template being analyzed
Analysis
If I RDP onto my on prem self hosted agent VM I can get the same error if I follow the following process
From Command Prompt with PowerShell

Open a Command Prompt (CMD)
Run the command powershell.exe E:\Agent\_work\_tasks\RunARMTTKTestsXPlat_cb27e003-8534-4da9-aaa0-35ca8756ae29\1.2.2\powershell\ps-runner.ps1 -templateLocation E:\Agent\_work\92\s\Src\Expenses\BlackMarble.ISS.Bicep\ARMOutput\* -resultLocation E:\Agent\_work\92\s -recurse
The same error as seen in a pipeline run is seen

From Command Prompt with PowerShell Core

Open a Command Prompt (CMD)
Run the command pwsh.exe E:\Agent\_work\_tasks\RunARMTTKTestsXPlat_cb27e003-8534-4da9-aaa0-35ca8756ae29\1.2.2\powershell\ps-runner.ps1 -templateLocation E:\Agent\_work\92\s\Src\Expenses\BlackMarble.ISS.Bicep\ARMOutput\* -resultLocation E:\Agent\_work\92\s -recurse
The script runs as expect (I do have ARM TTK issue with the file under test)

From PowerShell 5 Prompt

Open a PowerShell 5 Prompt
Run the command E:\Agent\_work\_tasks\RunARMTTKTestsXPlat_cb27e003-8534-4da9-aaa0-35ca8756ae29\1.2.2\powershell\ps-runner.ps1 -templateLocation E:\Agent\_work\92\s\Src\Expenses\BlackMarble.ISS.Bicep\ARMOutput\* -resultLocation E:\Agent\_work\92\s -recurse
The script fails  as expected

From PowerShell 7 Prompt

Open a PowerShell 7 Prompt
Run the command E:\Agent\_work\_tasks\RunARMTTKTestsXPlat_cb27e003-8534-4da9-aaa0-35ca8756ae29\1.2.2\powershell\ps-runner.ps1 -templateLocation E:\Agent\_work\92\s\Src\Expenses\BlackMarble.ISS.Bicep\ARMOutput\* -resultLocation E:\Agent\_work\92\s -recurse
The script runs as expected (I do have ARM TTK issue with the file under test)

Suggestion
The issue appears to be the use of the PowerShell 5 (powerhell.exe) as opposed to PowerShell 7 (pwsh.exe).  I think the best option is to give the user the choice to force the use of PWSH, whilst leaving the current default behavior as it is
I will create a PR with this change

Note: This maybe replaced to the problem (arm-ttk-extension #10)[https://github.com/sam-cogan/arm-ttk-extension/issues/10)

Just looked that the source and realized usePSCore already exists, once set to true this fixed the parsing problem.
# Generate the ARM from the Bicep
 - task: BicepBuild@0
    inputs:
      process: 'multiple'
      sourceDirectory: '$(Build.SourcesDirectory)\Src\Bicep\RootTemplate-*.bicep'
      stdout: false
      outputDirectory: '$(Build.SourcesDirectory)\Src\Bicep\ARMOutput' # Only when 'stdout' is false or not defined

 # Good practice to version your ARM
  - task: VersionJSONFile@2
    inputs:
      Path: '$(Build.SourcesDirectory)\Src\Bicep\ARMOutput'
      recursion: true
      VersionNumber: '$(Build.BuildNumber)'
      useBuildNumberDirectly: False
      VersionRegex: '\d+\.\d+\.\d+\.\d+'
      versionForJSONFileFormat: '{1}.{2}.{3}.{4}'
      FilenamePattern: '\w+.json'
      Field: 'contentVersion'
      OutputVersion: 'OutputedVersion'

  - task: RunARMTTKTestsXPlat@1
    displayName: 'Run ARM-TTK on all ARM templates'
    inputs:
      templatelocation: '$(Build.SourcesDirectory)\Src\Bicep\ARMOutput\*'
      resultLocation: '$(Build.SourcesDirectory)'
      usePSCore: true
    continueOnError: true

 - task: PublishTestResults@2
    displayName: 'Publish ARM-TTK test results'
    inputs:
      testResultsFormat: 'NUnit'
      testResultsFiles: '$(Build.SourcesDirectory)\*-armttk.xml'
      testRunTitle: 'Run_$(Build.BuildNumber)'
      failTaskOnFailedTests: true

Hopefully save some other people some time if they hit this issue


Bug in filter on main page

When I clicked on "recently requested" filter in main search page I got stuck in a white screen loop.

This should now be fixed w/ the recent fixes for search sorting and review/request counts.


debug relations between nav-main and footer

I noticed the nav-main had too much margin, always assuming the footer is in expanded position, and even than it was inaccurate. Fixed it.
To reproduce the issue, open an admin interface page with the footer not expanded, and resize your browsers height. You will notice the nav-main does not take up all the space it has, leaving a significant margin unused.
This PR fixes that.

Might I add I am very suprosed a mature CMS like Wagtail has simple front-end issues like these? Glad I could help.

Also fixed this transparent background, by giving the footer a background, rather than just the submenu. commit: 1ee4bba

Right, apologies.
I have tested on desktop in firefox 61.0.2 at various resolutions. I also tested in on the android version of Firefox  (also 61.0.2). It looks, feels, acts and smells excatly as expected (it smelled refreshing).
I do not expect odd behavior on other browsers, as the css used wasn't spectaculary cutting edge, but of course it should be tested, that is what testing is for.
You meantion rather using flex-box. One of the other PR's I recnetly opened turns most of the main-nav section into a flex box, doing exactly that. This footer however still relies on the magic number approach for now. I will go see if I can include it in the flex-box when I have more time.
Never the less, I do recommand pulling this in. It is a working fix, and it will be compatible with the other PR, which turns the main-nav into a flex box. It will at least adress an ugly issue untill I get some time to refactor the whole thing.
Please do reply with any questions or feedback, I have this thing fresh in my head still.

@Meteor0id thanks for having a shot at this. I have rebased this onto the latest master and will now review.


Update security-overview.md

Updates for default rules <IP_ADDRESS>/0 and ServiceBus tag available on premium Sku only

@malopMSFT : Thanks for your contribution! The author, @jimdial, has been notified to review your proposed change.

@Jak-MS : Thanks for your contribution! The author, @jimdial, has been notified to review your proposed change.


[Icon Request] Support for AngularDart plus extension files

[X] I'm sure this issue is not a duplicate.

[X] I'm submitting an icon request:

Type: filename
Icon Name: angulardart, ng_*_dart
Sample original Icon:
Filenames: ng_component_dt, ng_guard_dt, ng_service_dt, ng_directive_dt, ng_pipe_dt, ng_routing_dt/ng_routes_dt

More info: AngularDart

You guys kinda did the same with the Angular files at this issue: #1016. I am making the custom AngularDart svg and will post soon an image with all the icons following the guidelines. 😄
Note: There is no Module file at AngularDart since all the providers, imports, and so on are already placed at the component.

I don't think you need to do any custom AngularDart svg. It's just a matter of adding the .dart extension to the existing ones. Why would you need to create different icons?

What I meant, adding the little dart icon to the right bottom side of the icons.


Twitter Listener is renamed to Twitter Example

Not valid anymore.
When Camilla selects the "Twitter Listener" connection

@jludvice how cool it would be to load the names upon suite start? :)

@dsimansk I don't think we want to do that -> one more thing to go wrong imho :(
Why is it not valid anymore?
This connection should be created as part of @datamapper e2e test.
https://github.com/syndesisio/syndesis-e2e-tests/pull/1/files#diff-9a8ae2f50cc0264d26b8d6df57963b0eR18
What changed?

${title} says it all :)

Who and why renamed my connection ?

Nevermind, the create connection page is not loading my bad.

I've opened issue to track this https://github.com/syndesisio/syndesis-ui/issues/645. Once again I'm sorry that I missed the root cause and deducted wrong conclusion :)

Root cause is fixed, closing.


Add unit tests for Utils & URI

Hi,
I've analysed your codebase and produced some unit tests for the following classes - Utils and URI.
I've written the tests for these functions with the help of Diffblue Cover.
Hopefully, these tests should help you detect regressions caused by future code changes.

The tests look good to me.
Sorry, I should have said earlier, I think the classes listed in the commit messages and PR heading should be fully qualified. I'm fairly sure I've submitted PR's with unqualified class names before but, following recent comments on other PR's, and looking at the generic names of these classes, it is possible the same names could occur elsewhere in the source tree. Maybe wait for more comments before addressing this?

Looks good. have you ever squashed a commit?


Program page: Low- and medium-access users see the "Add indicator" button

Affects: Users with Low or Medium level access to a program
Issue
I see the "Add indicator" button above the indicator list. I should not see this button because only High level users are allowed to add, edit, and delete indicators.
It does not appear that I can actually save a new indicator because required form fields are grayed out.
From Sanjuro: The commit date is Aug 21, so it happened a little while ago.  It’s a super easy fix for that one item, though I’ll need to check whether there could be other things affected.
Acceptance criteria

[x] 1. When I have Low or Medium access to a program, I don't see the "Add indicator" button .

[x] 2. Ensure that the Aug 21 commit didn't cause other issues related to roles and permissions.

@sanjuroj Assigned the issue to you because you've already begun investigating.
I added it to Ghost Pepper not because it's catastrophic but because it affects a significant percentage of users who are seeing a call to action that they shouldn't see. If the problem turns out to be isolated and low-risk to fix, it seems worth considering a patch release.
I don't feel strongly about this, though, if you'd prefer to wait for LevelUp.

I think a patch release makes sense.  That said, as far as I can tell, there are no other effects outside of that visible Add Indicator button.

As mentioned in Slack, this looks good to go!


JRuby support

\0/
@bartkamphorst, @sunny: what say you?
Would it be a good idea to move https://github.com/repotag/gollum-lib_rjgit_adapter to the gollum org (and add travis tests, coverage, etc.)?

Exciting to see all the lights green! :tada: Nice work with the gemspec. I'm in favor of merging.
Adding Travis, coverage, etc. is also a good idea at this point, moving the gem can be decided at a later time I think.

Good job there, also like the way the gemspec is gemerated!
Shouldn't lib/version.rb be under lib/gollum-lib/?

Good point @sunny :) Are you also ok with using kramdown als the default markdown gem for gollum ( https://github.com/gollum/gollum/pull/994)? I was thinking of bumping gollum to 4.0 after that.

Yup, sounds good to me.


Reorganize internals to host SWRL as extension to the OWL core

SWRL reasoning subsystem should be threated like an extension, having dedicated OWLSharp.Extensions.SWRL namespace and capabilities.

Completed in commit fd40121


Generation tool should annotate deprecated fields with @Deprecated.

GraphQL schema provides isDeprecated flag to deprecate fields.
Generation tool should annotate accessor methods to these fields with @Deprecated annotation.
Would be nice even provide the reason that specified in deprecationReason

Yes, it would be nice to optional provide support for this.  This is basically the approach we took for swift using attributes.
The problem I ran into with trying to surface this information for java was that our mobile-shopify project was already using a bunch of deprecated android fields to support older android versions, so just marking methods as deprecated wouldn't make their use obvious enough to make sure all usage of deprecated fields are removed.
So if you are going to add support for deprecation attributions, then make sure you can enable a lint check that allows deprecated fields usage to be noticed and removed quickly after they are deprecated.


Map of all deaths for a single hero on Death Map

From Twitter - "was looking at teamfight death map - would be cool to see all deaths of 1 hero mapped, too. also, overlaid with heat map?"

Are you interested in doing this?  I am not

Reasons:

The current implementation of death map is hacky.  We're reverse-lookuping the hero who died's approximate position at death time (based on the position data we collect every second).  I don't really want to build on top of this shaky foundation.
The map is annoying to render because the position CSS puts the top left corner of the icon on the map.  better would be centering it at that location.

Assigning to @albertcui , if you think it's still worth doing, you can take ownership of it.  If not, close :)

Haven't heard anything on this lately.  The current death map is based only on teamfight deaths, not all deaths.  If we want to do a comprehensive death map, we need to track the death positions of all heroes, not just those who die in teamfights.

@albertcui   Can you do this?


Form Error State Rendering

When rendering a form with errors, currently each form group gets a class associated with it (either error or "has-success").  The class "has-success" attracts unwanted visual attention to fields that don't have any issues by turning the whole form group green.  Yes, green typically means good, but it also raises the question of why did every field change color.
The proposed change here is to only add classes to form-groups that need attention (the ones that errored), which is a more common pattern on many sites.  That way, the rendered error form is more focused and less distracting.
For other examples in the community see the screenshots below (you can pick about any site and the results will be the same):

Closing old issues. Suddenly see that there is indeed duplicate code that adds the hardcoded error class. Oldest issue I ever closed, but I just fixed it in develop.


CONNACK not returning "session present" flag

( Sorry if I am opening many issues, but we're heavily testing VerneMQ and I find this can be an opportunity for improvements :-) )
I found that VerneMQ isn't correctly returning the "session present" flag on CONNACK packets when using "clean session" set to false. It is always returned as false even though
vmq_reg:status({"", <<"some-client">>}).

returns
{ok,{offline,fanout,0,0,false}}

i.e., a session is indeed present.
Currently this isn't much of a problem for us, but anyway it would be great if you could have a look at this :-)

Thank you very much for opening any issues! very welcome :)

Working on it here, still some more work necessary.
https://github.com/erlio/vmq_server/pull/30

@dergraf Great to hear that! Many thanks!

@testark is it possible that you could get in touch with us over email? we'd love to know more about you and your usecase as it helps us to better promote VerneMQ (which eventually results in an even better product)! What do you think?


dnd5e: Actor Sheet Inline Activities

The default actor sheets present Activities inline when expanding item summaries:

Parity:

Show actions within each item's summary on the actor sheet
Allow clicking to use the target activity
Context menu
Favorite Activities (to be implemented in #772)

For Tidy 5e Sheets, achieve feature parity plus

Drag and drop to sort
Have independent columns that are more relevant to activities

Usage / Activation Cost
Atk / DC / Dmg calculations
...?

Remove usage column from main inventory table
Tentative: show on description expand
Tentative: classic controls (Favorite, Edit, Delete, ...?)

Some things to remember:

Activities are tagged with [data-activity-id]
Activities have their own context menu setup: dnd5e.documents.activity.UtilityActivity.onContextMenu(item, element)
Inventory delta changes also account for activities, particularly managing system.uses.value <-> system.uses.spent and uses.value <-> uses.spent

As a thought for independent columns used for activities, I believe that the most important information (in my opinion) is, from most to least important:

Uses/resource costs, good to quickly to know if the activity is usable at a glance

Activation costs, (action/bonus action/reaction etc.), good to quickly parse to see how different activities fit into your turn
The above are the highest priority because they are widely applicable and determine whether an ability can be used at all at a given moment, making them the most important to parse with a glance.

Targets,

Range,
These features determine how useful an activity is in many situations, and are almost universally useful fields to all activities.

Damage

Save/DC
These are still quite useful, but not nearly universal, as there are many activities that do not deal damage or require saves. I know for my personal use only about half of activities would be likely to deal damage or require a save, and most damaging/save related activities would be the primary activity for the given item, open that information to effective display elsewhere.


FR2: Need single script to run in both Windows batch and Linux Bash

FR2: Need single script to run in both Windows batch and Linux Bash:
http://stackoverflow.com/questions/17510688/single-script-to-run-in-both-windows-batch-and-linux-bash

It's simpler to have two separate scripts:

metracer.sh - for *nix systems
metracer.cmd - for Windows

This way it's very clear for user which one to use. Also this would render a better integration with OS

Fixed in revs:
1928056ba549cdad6b0ea6b291ba04d62d75a348
f080ca5265bbe276f9002135969f8c891cc2a0ff
83328c7c7d255bce50708949dbb8afe5243bfe5d
2bd7d32b4457eb63e69f8fa1877c2de44449d86d


Ability to launch currently-active Xcode via scripting

Tell us how we can improve Xcodes
Is your feature request related to a problem? Please describe.
I love binding a key command to launch Xcode — it makes it super fast to get back into Xcode.  (I use Many Tricks' Butler app)
However, the key binding I use launches an app called "Xcode.app"… which would work normally, but since Xcodes installs and activates different versions of the app, my macro/key binding now needs to launch "Xcode-13.0.0-Beta.3.app" (and tomorrow, Beta.4).
What would you like to see? How would you like it to work?
Feature request:
Create a way to launch/switch the currently-activiated Xcode via scripting in Xcodes.  Perhaps via AppleScript?  Or perhaps by creating an alias that I can open (that changes when different Xcode is activated).

I was running into something similar with a script that assumed /Applications/Xcode.app as the root to some dev libraries.
Alternate proposal: symlink to make Xcode.app always point to whichever we say is the active one, via Xcodes. Obviously if we go Xcode-selecting on our own you can't control that, but if we use Xcodes it'd be nice.
(Or, if for some reason symlinks break anything else or break things like Alfred from actually seeing them, maybe just have an option that when we make an Xcode the active one it gets renamed to Xcode.app and the previously active one gets renamed back to a versioned name.)

Adding the ability to automatically create symbolic links (if it can) named Xcode.app when you Select/Activate through Xcodes in #200


Update readme mysql chart

Update delete release instruction in README.md for stable/mysql chart to include --purge argument.

/ok-to-test

/lgtm


Refactor file structure for heroku deployment

The backend folder was deleted. The start and heroku-postbuild commands were created in the new package.json. Closes #16.

We need to make sure that none of @ayanmallik's recent work is erased by this pull request before merging.


Adding a gzip-ed text file for requests download system test.

This has revealed at least two errors and this is intended to be checked in in a broken state, so that subsequent PRs can fix it. (See https://github.com/dhermes/google-resumable-media-python/commit/29617b6fa0c4d3275dd54b42a78a9c0ed99cb2ce for a preview of one such fix).
In order to make this easy, I re-factored the tests in a commit before, so it's likely easier to review this PR commit-by-commit.
/cc @tseaver @mfschwartz

Thanks @tseaver!


CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory

Hi i know already another post has been answer this problem before but, i just want to know what the differences between using
method 1 : node --max_old_space_size=8192 node_modules/\@angular/cli/bin/ng build --prod --aot
and using
method 2 : ng build --prod --aot false
if i using node --max_old_space_size=8192 node_modules/\@angular/cli/bin/ng build --prod --aot
the results always stuck on 92% like this

but if i using ng build --prod --aot false all process working well

i really not understand why just add false everything it works, but if i not using false the build will show error message CALL_AND_RETRY_LAST Allocation failed - JavaScript heap out of memory
can you tell me what the problem in method 1?

Bug Report or Feature Request (mark with an x)
- [X ] bug report -> please search issues before submitting
- [X ] feature request

Versions.

npm : 4.5.0
node : 7.6.0
windows 7
the pacakge.json.

"dependencies": {
"@angular/animations": "^4.0.0",
"@angular/common": "^4.0.0",
"@angular/compiler": "^4.0.0",
"@angular/core": "^4.0.0",
"@angular/forms": "^4.0.0",
"@angular/http": "^4.0.0",
"@angular/platform-browser": "^4.0.0",
"@angular/platform-browser-dynamic": "^4.0.0",
"@angular/router": "^4.0.0",
"angular2-jwt": "^0.2.3",
"angular2-select": "^1.0.0-beta.3",
"angular2-toaster": "^4.0.0",
"bootstrap": "^3.3.7",
"core-js": "^2.4.1",
"jquery": "^3.2.1",
"jquery-flot": "^0.8.3",
"jquery-slimscroll": "^1.3.8",
"jqueryui": "^1.11.1",
"metismenu": "^2.7.0",
"ng2-bs3-modal": "^0.10.4",
"primeng": "^4.1.0",
"rxjs": "^5.1.0",
"zone.js": "^0.8.4"
},
"devDependencies": {
"@angular/cli": "1.2.0",
"@angular/compiler-cli": "^4.0.0",
"@angular/language-service": "^4.0.0",
"@ types/jasmine": "~2.5.53",
"@ types/jasminewd2": "~2.0.2",
"@ types/jquery": "^3.2.6",
"@ types/node": "~6.0.60",
"codelyzer": "~3.0.1",
"gulp": "^3.9.1",
"gulp-gzip": "^1.4.0",
"jasmine-core": "~2.6.2",
"jasmine-spec-reporter": "~4.1.0",
"karma": "~1.7.0",
"karma-chrome-launcher": "~2.1.1",
"karma-cli": "~1.0.1",
"karma-coverage-istanbul-reporter": "^1.2.1",
"karma-jasmine": "~1.1.0",
"karma-jasmine-html-reporter": "^0.2.2",
"protractor": "~5.1.2",
"ts-node": "~3.0.4",
"tslint": "~5.3.2",
"typescript": "~2.3.3"
}

I also met this error

To answer your question, --aot false disabled AOT compilation. Other than that, this is a duplicate of https://github.com/angular/angular-cli/issues/5618.


Refactor run command

python3 ParseInject.py UserCode.c OutCode.c references.json
As of right now this command needs to be run to use the the smartGC. Refactor this by making it easier for the user
eg:
./smartGC UserCode.c
should do all the work
hint: write a shell script to do this.

Can you assign this

alright im assigning you @Nightwing000
i will be giving you 30 min as of now, based on your progress we shall extend the time if needed

!assign @Nightwing000 30

thanks

Yeah its running the code that's enough right if there's some issues with libraries and stuff I don't need to solve those right?

yup, as long as i can replicate your work and its correct you will get points

make sure once you are done you create a pull request into a new branch and not main

when you are done and want to create a pullrequest please send me a message so that i can confirm which branch you will need to create the pull request to @Nightwing000

yeah i'm done

create the pull request to issue2

wait do i need to fork first? I forgot how it works

I just cloned it on vscode so

you can also refer contributing.md

!extend 20

do you need to add time or can I still push?

yea you should still be able to push and create the pull request dont worry about the time now

!deassign @Nightwing000

!assign @Nightwing000

can you see it?

!extend 60

!assign @Nightwing000

Hi can you check the comments on the pull request

!deassign

!deassign

im so sorry i have fixed that

you can work on other issues now


Update karma to v0.12.0

Fix an error that occurs during the npm install process

Thanks @spoonben!


sg_create_image with OpenGL + SG_FILTER__MIPMAP produces GL_INVALID_ENUM (1280)

tiny bug: in _sg_gl_create_image uses _sg_gl_filter to convert sokol filter enums -> GL enums, but glTexParameteri(GL_TEXTURE_MAG_FILTER, ...) only accepts GL_NEAREST and GL_LINEAR as parameters, so _sg_gl_filter returns invalid enums for mipmap-ing filters (see https://registry.khronos.org/OpenGL-Refpages/gl4/html/glTexParameter.xhtml)
        sg_make_image(
            &(sg_image_desc) {
                .type = SG_IMAGETYPE_ARRAY,
                .width = 1024,
                .height = 1024,
                .num_slices = 4,
                .pixel_format = SG_PIXELFORMAT_RGBA8,
                .min_filter = SG_FILTER_NEAREST_MIPMAP_NEAREST,
                .mag_filter = SG_FILTER_NEAREST_MIPMAP_NEAREST,
                .usage = SG_USAGE_DYNAMIC,
                .num_mipmaps = 4
            });

produces GL_INVALID_ENUM for me.
I'll get a PR up when I verify a fix, should I just split _sg_gl_filter into _sg_gl_min_filter and _sg_gl_mag_filter?

(PS: I'll keep this ticket open until the 'separate sampler objects' update goes live. It will be a little while though, because I'm currently not sure if this will be a separate update before WebGPU support, or if WebGPU support will be part of the update.

Linking the associated PR: https://github.com/floooh/sokol/pull/842
(not ready yet though)

Ok, closing this ticket because that PR is now merged.


sbt plugin using published core jar

idea is to automatically update code based on changes to api.json

See https://github.com/gilt/apidoc-cli project for a way to do this


Fix launch issue when GodotProjectDir not same as SolutionDir

If the Solution for a Godot project is not the same as the project directory the extension will
fail to launch the debug target with a MessageBox showing 'No Godot editor instance connected'.
The reason is that the extension takes SolutionDir as the Godot project dir. While this hold true for
simple default Godot projects this must not be the case. In complex projects developers may
restructure their projects into a alternative structure, where the solution may be at another location.
The *.csproj file has the MSBuild property 'GodotProjectDir'. Now the value of this property is fetched
and will be used as the project dir.
Note: Godot itself has some issues with projects varying to the default project. To fix this godot issues,
modifications in the GodotSDK MSBuild props file have to be done.

Currently, Godot doesn't support this. It expects both the solution and csproj to be at the Godot project root (next to the project.godot). I plan to change this for Godot 4.0, but it's unlikely to ever change for Godot 3.x.

Note: Godot itself has some issues with projects varying to the default project. To fix this godot issues,
modifications in the GodotSDK MSBuild props file have to be done.

Yes, the Sdk makes these assumptions because the Godot editor does.

So what does this mean for this PR? Do you consider merging it? Or not, because this fix is currently not needed?
IMO this way of resolving the GodotProjectDir is the more MSBuild like way of doing so (considering MSBuild does not know what Solutions are 😉  ). Also while not needed for Gotdot3 this fix should be fully compatible and not break anything, but should also work with Godot versions that allow a more flexible Project structure in the future (as long as the property name stays the same).
BTW: Godot3 may not officially support SlnDir!=ProjDir. The workaround to make it work was to this small change
    <GodotProjectDir Condition=" '$(SolutionDir)' != '' ">$(SolutionDir)</GodotProjectDir>
    <GodotProjectDir Condition=" '$(SolutionDir)' == '' ">$(MSBuildProjectDirectory)</GodotProjectDir>

to
    <GodotProjectDir>$(MSBuildProjectDirectory)</GodotProjectDir>

I did not test everyting, but all I need for now (some custom nodes, addins etc.) work fine as far as I can tell.
Note that the first XML fragment is a little weird under the assumption that SolutionDir == ProjectDir. In that case you can just use ProjectDir that always exists anyway. It will have the same value as SolutionDir but unlike that one, it is always defined.
Its fine if you say you will not merge this. In that case sorry for the trouble. I did not find any contribution guidelines that define what the PR process is. If so, I will make a forked version of the addin, where I will also do a second fix for #10.

Godot3 may not officially support SlnDir!=ProjDir.

What I do with Godot Mono is this:
In my object tree in the Godot editor, I have one object, called Main and I attach to it one script, called Main.cs. Everything else goes in folders and is built entirely from code at runtime.
 But I didn't start form the assumption that I wanted Godot: I started from the assumption that I wanted open source, C#, VR support and spend as little time as possible on low level hardware stuff so Godot was the only option at the time. I'd probably go with StereoKit or something else if I was starting from scratch right now. (no offense to Godot)

I may have misunderstood this. Is it only about the solution being on a different directory and not the csproj? The Godot editor still expects a solution to be in the project root, but I suppose you have another one you use in Visual Studio. That should be possible then, so this change makes sense.
We can update the Sdk too, although you can already make this work by adding <GodotProjectDir>$(MSBuildProjectDirectory)</GodotProjectDir> in a Directory.Build.props.

Currently the extension does this:
// Pseudocode
_godotProjectDir = ActiveSolution.Directory

A project for that IsGodotProject() is true, has a MSBuild Prop $(GodotProjectDir) that
already holds a value that represents this directory.
So in my opinion doing this:
// Pseudocode
_godotProjectDir = godotProject.$(GodotProjectDir)

is the correct/idiomatic approach to determine the project directory for a Godot
project, while the former approach works because of implementation details.
My Godot project runs completely fine in the GodotEditor. The Visual Studio
extension refuses to launch it. The PR applies changes, so that the extension
will launch my project and keep launching all projects it could launch prior to this.
So I'd argue this is an improvement (as long as this change does not
introduce regressions).
So my impression is, this may be an up-stream worthy fix. So I opened this PR.
Now the maintainer of this project has to decide if this really
is an up-stream worthy change - weight risk of regression vs. impact of improvements ... -
and decide accordingly.
If, Godot itself supports Solutions in some other Directory, or whatever MSBuild
tricks are needed to make it work, is IMO not relevant for the PR at hand.
This is the best I can do, to articulate why I opened this PR (I'm not a native English
speaker).

@paiden could U join here to add your idea of PR and if possible UPDATE this view to the dotnet6 Godot4


[Feature] Add support to PowerShell Cmdlets to Download FileRecords

The PowerShell Module is currently unable to download FIleRecords. This would be useful in scenarios where a user may use certificate based authentication and they store the certificate as an attachment to a Login Record. Implementation of this is as simple as a FileCommands.ps1 file with the code that would return a MemoryStream:
`function Get-FileRecord {
param(
[string] $recordUid
)
[KeeperSecurity.Vault.VaultOnline]$vault = getVault
if ($recordUid) {
[KeeperSecurity.Vault.FileRecord] $record = $null
if ($vault.TryGetKeeperRecord($recordUid, [ref]$record)) {
$fileStream = [System.IO.MemoryStream]::new()
$vault.DownloadFile($record, $fileStream).GetAwaiter().GetResults() | Out-Null
return $fileStream
}}
}`

PowerCommander v0.9.8 adds Copy-KeeperFileAttachment cmdlet.
Downloads filename.txt file attachment from all records into 'OutFolder' folder
Copy-KeeperFileAttachment -Folder \ -Recursive -Name 'filename.txt' 'OutFolder'

Downloads all file attachments for a record
Copy-KeeperFileAttachment -Record <RECORD_UID>

Is it possible to also add the ability to return the file as a MemoryStream so that users of the function don't have to write a file to the system? This would allow users to directly use the file in memory so they don't have to write the file to the system then read it back in a again?

Copy-KeeperFileAttachmentToStream cmdlet is added.
$stream = New-Object System.IO.MemoryStream
Copy-KeeperFileAttachmentToStream -Record <RECORD_UID> -AttachmentName <OPTIONAL_ATTACHMENT_NAME> $stream
$stream.Seek(0, 0)


Users/akataria/mongovcorefixes

Motivation and Context

Description

Contribution Checklist

[ ] The code builds clean without any errors or warnings
[ ] The PR follows the SK Contribution Guidelines and the pre-submission formatting script raises no violations
[ ] All unit tests pass, and I have added new tests where possible
[ ] I didn't break anyone :smile:

Hi @aayush3011, this PR contains 0 edited files. Is there some other work you'd like to do related to this? I will close this PR out for now.


[Event Request] table 383 Detailed CV Ledg. Entry Buffer - OnInsertDtldCVLedgEntryOnAfterReset

We woud like to insert data in the record DtldCVLedgEntryBuf after the reset method at the end of the procedure InsertDtldCVLedgEntry, table 383 "Detailed CV Ledg. Entry Buffer". In this purpose, we need an event at the end of this procedure, as follows :

We would need these parameters :
OnInsertDtldCVLedgEntryOnAfterReset(DtldCVLedgEntryBuf, CVLedgEntryBuf, NewDtldCVLedgEntryBuf, NextDtldBufferEntryNo, IsHandled)

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. We will update this issue with information about availability.


chore: Update ODH Manifests README

Description of your changes:
Updates README to reference correct artifact names
Environment tested:

Python Version (use python --version): n/a
Tekton Version (use tkn version): n/a
Kubernetes Version (use kubectl version): n/a
OS (e.g. from /etc/os-release): n/a

Checklist:

[x] The title for your pull request (PR) should follow our title convention. Learn more about the pull request title convention used in this repository.

/lgtm

/approve


You can't style the tooltip arrow because TooltipClassKey type is missing the arrow key

https://github.com/mui-org/material-ui/blob/master/packages/material-ui/src/Tooltip/Tooltip.d.ts#L49 should also include the arrow key. A problem if you are using TS.

@dufia Thanks for the report 👍

@dufia Do you want to work on a pull request?

@oliviertassinari I'd love to do it, please assign me

@oliviertassinari Hey, I've noticed 4.7.1 was released and it included this fix. But somehow, it didn't make it into the released code. When I check my node_modules for @material-ui/core/Tooltip/Tooltip.d.ts, type TooltipClassKey remains unchanged. Any ideas why?

@dufia #18645 was not included in 4.7.1. It was released before the PR was merged: https://github.com/mui-org/material-ui/compare/v4.7.1...master


Add explicit I/O gates e2e tests

Part of this duo:

https://github.com/liveblocks/liveblocks-cloudflare/pull/628
https://github.com/liveblocks/liveblocks/pull/1333 👈 this PR

This adds as a new E2E test to deliberately test I/O gates behavior of storage. The way the test works is that it will tell the server to simulate the next Op processing to be slow (which will trigger a lot of useless writes to storage), effectively ensuring that any concurrently incoming Ops will be blocked.

Closing. This wasn't meant to be merged.


Rendering issue with Firefox  39.0a2

It seems like Firefox 39.0a2 produces a fixed sized rendering window no matter what width or height is specified.
var renderer = PIXI.autoDetectRenderer(256, 256, {antialiasing: false, transparent: false, resolution: 1});
document.body.appendChild(renderer.view);

Is this a pixi bug, or an issue in Firefox?
Does this happen is native canvas? Did you happen to track down why this is happening in FF but not elsewhere?

Closing for now as seems to have gone quiet. :+1:


Autonity v1.0.1

New commands:

[x] protocol max-schedule-duration
[x] protocol schedule
[x] protocol total-schedules
[x] protocol epoch-info
[x] protocol epoch-by-height
[x] protocol unbonding-share
[x] protocol is-unbonding-released
[x] governance create-schedule
[x] governance set-max-schedule-duration
[x] governance set-oracle-reward-rate
[x] governance set-proposer-reward-rate
[x] governance set-slasher
[x] governance set-withholiding-threshold
[x] governance set-withheld-rewards-pool
[x] governance set-omission-accountability-contract
[x] governance set-liquid-logic-contract

LGTM but before merging, it would be better to wait for autonity.py release to update and test the branch.

I've updated autonity.py the version.

merged


Changed to version two

@JamesVanWaza thanks for these changes!  In the future you can combine them into one Pull Request, no need to do one per file.


Attempt to new the mapped command when not present in the container

#33 :  Attempt to new mapped command names when no factory has been registered with the container
Targeting master because develop does not yet exist.
Would it be better to make this behaviour opt-in? To do that, the command loader would likely need a factory, therefore, the lib would need a config provider for the configuration flag…
Also, this impl does not attempt to discern whether the mapped command points at a new-able class with class_exists. Should it?

Targeting master because develop does not yet exist.

master is fine here as we're still in the 0.X phase, and new features can be added to patch releases.

this impl does not attempt to discern whether the mapped command points at a new-able class with class_exists. Should it?

Yes, please!

Would it be better to make this behaviour opt-in?

No, I don't think so. The idea is mainly to simplifiy command registration when the command has no dependencies, and thus has no need for a factory. The nice side-benefit of this approach is that if another package or the application does provide dependency configuration for the command class, then that will be used, so we get the same benefits as if it were registered already.

Thanks, @gsteel!


[Bug] Your Bug Report Here Requesting changes to 'Lists all sources in IdentityNow.' (list-sources)

Describe the bug
Need to add a note to the page for v3/sources API call to mention that we do not guarantee consistency in the order results are returned if the sorters parameter is omitted.

Is this necessary to document on each API? I feel like this should be assumed for all endpoints. Consistency should never be assumed unless using a sort parameter.

closing due to no response


Custom montage

Thanks for this great dataset!
It looks like you are using a custom montage, but I couldn't find the file montage.csv anywhere in the repo or OpenNeuro.
Could you upload it?
Many thanks!
https://github.com/zhangzihan-is-good/Chisco/blob/bb2cf1e47c48dc7c3e2ce2db49457bfb543353df/preprocessing.py#L68

We appreciate your interest in our research. As the EEG cap manufacturer did not provide an official montage file, we have developed a custom montage, which has been added to the repository.

Perfect, thanks a lot!


Starting Neo Cli rpc Fails on amazon linux after broken pipe

I have installed a node on my server and was able to run cli from terminal. Terminal returned broken pipe after no activity for sometime. I tried starting neo cli rpc from another terminal (like I usually do) it fails with below error.

Neo.IO.Data.LevelDB.LevelDBException
IO error: lock Chain/LOCK: Resource temporarily unavailable
at Neo.IO.Data.LevelDB.NativeHelper.CheckError(IntPtr error)
at Neo.IO.Data.LevelDB.DB.Open(String name, Options options)
at Neo.Implementations.Blockchains.LevelDB.LevelDBBlockchain..ctor(String path)
at Neo.Shell.MainService.OnStart(String[] args)
at Neo.Services.ConsoleServiceBase.Run(String[] args)
at Neo.Program.Main(String[] args)

The command I used was cd /home/ec2-user/neo-cli/   dotnet neo-cli.dll /rpc
How can I solve this error? Please Help!!

sudo dotnet neo-cli.dll ?

This error would occur if you try and start a second neo-cli instance running from same Chain folder. Are you sure you are not already running neo-cli on your AWS instance (in a screen or detached terminal?)

It solved by itself after a few hours.. I don't know what caused it though


Add implementation for np.positive

closes #5786
I have added the lowering and tests and have unecessary class. Please do tell if any changes are required.

Thanks for the PR! Once CI passes, I'll mark it ready for review.

Thanks very much for the PR, I've queued it for review.


PIXI-side NeutrinoParticles integration.

This is not actually an issue. This is a request for integration for NeutrinoParticles
I made external variant of such integration (without changing any framework code). You can find it here. My integration is a kind of hack, because I need to reset some internal renderer features from outside. And also I'm not a JavaScript guy. My land is C++, and I don't actually know, how you guys develop your code and how you glue it together to have single .js file.
So, if you like NeutrinoParticles, you could make full integration (internal renderer and object) for effects. My code is a good base. It is well optimized, uses generic WebGL calls and it works well with both Canvas and WebGL renderers. But, I think it would be much better to use internal shaders, vertex buffers internal loader and etc.
I could make any support for such integration and will be happy to see official PIXI's support for NP.
The video tutorial for the Editor are not well organized and they need for updated, but you still can learn how to make effects on different levels of complexity. I'm working on them hard.

Awesome! I can help with it a bit later :)

@ivanpopelyshev Great :) I can't find your email. And I didn't really understand where should I join to.

@ymiroshnyk<EMAIL_ADDRESS>

If this gets done, it will certainly be a plugin; not in the core library. Good luck to anyone wanting to work on this! Sound awesome!


Line number mismatch in task title

If you haven’t already, check out our contributing guidelines for onboarding and email<EMAIL_ADDRESS>to request to join our Slack channel!

Action Performed:

Click FAB button => assign task
Input multiple line title
Next
In page confirm task click title section, Observe that the title has only 1 line

Expected Result:
Title should be multiple lines when clicking on title
Actual Result:
title has only 1 line but when create multiple line
Workaround:
Can the user still use Expensify without this being fixed? Have you informed them of the workaround?
Platforms:

Which of our officially supported platforms is this issue occurring on?

[ ] Android / native
[ ] Android / Chrome
[ ] iOS / native
[ ] iOS / Safari
[x] MacOS / Chrome / Safari
[ ] MacOS / Desktop

Version Number: 1.3.43-1
Reproducible in staging?: y
Reproducible in production?: y
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
https://github.com/Expensify/App/assets/43996225/fe37f432-b77b-49a5-ad60-f94d4da73d2d
https://github.com/Expensify/App/assets/43996225/62eb675a-1758-415c-94a0-e3c1e1f3fe05
Expensify/Expensify Issue URL:
Issue reported by: @namhihi237
Slack conversation: https://expensify.slack.com/archives/C049HHMV9SM/p1689634358039939
View all open jobs on GitHub

Proposal
Please re-state the problem that we are trying to solve in this issue.
Title should be multiple lines when clicking on the title
What is the root cause of that problem?
The problem here is that we don't allow multiple lines for input
https://github.com/Expensify/App/blob/ab3d0e876e311ed1ce3cd859ad6dd77a5d8e3cdf/src/pages/tasks/NewTaskTitlePage.js#L95-L102
What changes do you think we should make in order to solve the problem?
We need to add an attribute to allow multiple line input:
autoGrowHeight
textAlignVertical="top"
containerStyles={[styles.autoGrowHeightMultilineInput]}

And update onEntryTransitionEnd so that the cursor is at the end
<ScreenWrapper
    onEntryTransitionEnd={() => focusAndUpdateMultilineInputRange(inputRef.current)}

What alternative solutions did you explore? (Optional)
N/A

Closing this in favor of https://github.com/Expensify/App/issues/23025


[Fix] Overconstraints involving identity point

This replaces https://github.com/axiom-crypto/halo2-lib/pull/71, see that PR for details about the problem.
In this new fix, we add an optional skip input to divide_unsafe:

If skip = 1 as a variable, then divide_unsafe won't check
anything, to prevent divide by zero overconstrained panics.
We propagate this to ec_{add,sub}_unequal, with a new enum
AddUnequalMode that generalizes the previous is_strict flag. Now
you can pass a conditional skip boolean to be passed along to
divide_unsafe in cases where you need to prevent divide by zero.

In addition, we discovered some extraneous code here: https://github.com/axiom-crypto/halo2-lib/blob/8b9bdc2ba0d1f6f44e6b313847d2f0268e523c36/halo2-ecc/src/ecc/mod.rs#L232
This is already done in neg_divide_unsafe and not necessary!

To be part of more extensive refactor


Remove verbose flag from pytest setup.cfg

This was added accidentlly as we copied over the setup.cfg settings from
dask-ml.  Unfortunately this makes testing logs long enough that they don't fit
in Travis-CI easily.

[ ] Tests added / passed
[ ] Passes flake8 dask

Only failing test is boto, reported in #4276 .  Merging


@conda-forge-admin, please update team

@conda-forge-admin, please update team
Not sure when this gets triggered otherwise, but this should definitely address #1 now that it's been merged.

Hi! This is the friendly automated conda-forge-webservice.
I just wanted to let you know that I updated the team with maintainers from master.