Supporting multiple filter conditions per field

Is your feature request related to a problem? Please describe.
Hi @woylie, first off, thanks so much for maintaining this project. It's fantastic and I've really enjoyed the API you expose.
The problem: I'm building a relatively static form where I'd like to allow users to enter a min and max range for a specific value. The interface for this would provide 2 separate inputs per field.
EDIT: I believe this problem is well-described here: https://github.com/woylie/flop_phoenix/issues/88. There's a mention to PR #89, but I'm not sure if this issue ever got resolved?
As an example, let's say we'd like to enter a minimum and maximum age, I believe the field definitions would look like:
[
  age: [label: "Minimum age", op: :>=, type: "number"],
  age: [label: "Maximum age", op: :<=, type: "number"]
]

From my implementation efforts and research, it appears this structure with the same field and different operators isn't yet supported by the library.
In researching this issue, I found the work you did to use separate labels for multiple fields, and stumbled across this conversation as well which I believe is pertinent.
Right now, I believe the age fields in the example would  appear separately in the UI; however, upon collating the filter values, they would be merged, taking the value of the first age filter, the second one being discarded, and values from the UI being assigned to different inputs via the zip-based implementation here.
I could be totally wrong here, if you have any advice to support the use case above, it would be extremely helpful!
Describe the solution you'd like
My ideal solution would be that this library supports an arbitrary number of independently configured inputs per field just based on the fields configuration described above.
Describe alternatives you've considered
As an alternative, I tried creating a more manual implementation of the filter_fields component as described here, but was unsuccessful.
Additional context
As I mentioned, I could be totally off base here, but I've been struggling with this for a few hours and would love any advice.
Thanks so much!

Hi @masiamj, thanks for the issue. I think you're right, and you already found the place where it goes wrong. I'll try to look into this on the weekend, unless you're up for opening a PR.

I was able to look a bit further into this, and it appears that the problem actually lies in the to_form/4 implementation, specifically:
https://github.com/woylie/flop_phoenix/blob/123e1fede3d28c3dbaab8d479c0f4f561757e181/lib/flop_phoenix/form_data.ex#L145
I didn't find the time to fix this yet, but I should be able to get back to it in the next couple of days.

Scratch that. I updated the tests with assertions on the value inputs, and they pass. The function I linked would only be problematic if two filters for the same field with the same operator would be used. I don't think that's a use case (if it is, let me know).
The zip you linked should be fine for static forms, since the number of filters returned in the meta struct should always match the number of fields in the options passed to the filter_fields function.
I'll need to test this in an actual application.

Hey @woylie thanks for looking into this!
First off, in my specific case, you're correct to say the same field with the same operator is not a desired use case.
Taking a deeper look at the code, I also think you're right that the zip is fine for static forms (not sure for the dynamic use case).
My new hypothesis is that the issue actually lies in the hidden_inputs_for_filter and potentially the use of inputs_for from Phoenix. My idea is that if 2 filters have the same name, age in the example above, then there would be 2 inputs named age, and one would get overridden leading to a mismatched/unexpected number of fields being submitted by the form, causing a mismatch where number of filters != number of form values.
If you think this is a valid idea I'm happy to help explore solutions.
Any thoughts here? Thanks!

I just tested it in a real-world application, and it works fine. Are you actually having min/max age filters in your form? Or do you by any chance have something like a min/max date or date time?
One thing to look out for is that the Flop filter value will be the string value as produced by the HTML input, and it will be passed back as it is to your input component.
I had a case with a start date and an inclusive end date, both represented by date inputs. The DB column was a date time, not a date, and before passing the end date to the query function, I added T23:59:59 to the end date value. On the way back, the full date time string was passed to the HTML input, but since the input only expected a date, it saw the string as invalid, which caused the input to be reset as soon as another field was changed. I had to make sure to turn the date/time string back into a date string that the date input could understand. Maybe something similar is going on in your form?

Interesting, thanks for checking this out.
Maybe this is just an issue with my implementation. I use string, select, and date filters, maybe my form fields below will provide better context:
[
    name: [label: "Name", op: :ilike_or, placeholder: "Search by name...", type: "search"],
    daily_trends_symbol: [
      label: "Symbol",
      op: :ilike,
      placeholder: "Search by ticker...",
      type: "search"
    ],
    price_min: [label: "Minimum Price ($)", op: :>=, type: "number"],
    price_max: [label: "Maximum Price ($)", op: :<=, type: "number"],
    change_percent: [label: "Minimum change today (%)", op: :>=, type: "number"],
    change_percent: [label: "Maximum change today (%)", op: :<=, type: "number"],
    market_cap: [label: "Minimum market cap ($)", op: :>=, type: "number"],
    market_cap: [label: "Maximum market cap ($)", op: :<=, type: "number"],
    trend: [
      label: "Trend",
      options: [{"Uptrend", "up"}, {"Neutral", "neutral"}, {"Downtrend", "down"}],
      prompt: "",
      type: "select"
    ],
    trend_change: [
      label: "Trend change today",
      options: [
        {"Neutral to Uptrend", "neutral_to_up"},
        {"Neutral to Downtrend", "neutral_to_down"},
        {"Uptrend to neutral", "up_to_neutral"},
        {"Uptrend to downtrend", "up_to_down"},
        {"Downtrend to Uptrend", "down_to_up"},
        {"Downtrend to neutral", "down_to_neutral"}
      ],
      prompt: "",
      type: "select"
    ],
    close_above_day_200_sma: [
      label: "Close > 200D SMA",
      options: [{"Yes", true}, {"No", false}],
      prompt: "",
      type: "select"
    ],
    close_above_day_50_sma: [
      label: "Close > 50D SMA",
      options: [{"Yes", true}, {"No", false}],
      prompt: "",
      type: "select"
    ],
    day_50_sma_above_day_200_sma: [
      label: "50D SMA > 200D SMA",
      options: [{"Yes", true}, {"No", false}],
      prompt: "",
      type: "select"
    ],
    sector: [
      label: "Sector",
      options: [
        {"Communications", "Communication Services"},
        {"Consumer Discretionary", "Consumer Cyclical"},
        {"Consumer Staples", "Consumer Defensive"},
        {"Energy", "Energy"},
        {"Financials", "Financial Services"},
        {"Healthcare", "Healthcare"},
        {"Industrials", "Industrials"},
        {"Materials", "Basic Materials"},
        {"Real Estate", "Real Estate"},
        {"Technology", "Technology"},
        {"Utilities", "Utilities"}
      ],
      prompt: "",
      type: "select"
    ],
    pe: [label: "Minimum PE Ratio ($)", op: :>=, type: "number"],
    pe: [label: "Maximum PE Ratio ($)", op: :<=, type: "number"],
    eps: [label: "Minimum EPS ($)", op: :>=, type: "number"],
    eps: [label: "Maximum EPS ($)", op: :<=, type: "number"],
    pe_ratio_ttm: [label: "Minimum PE Ratio (TTM)", op: :>=, type: "number"],
    pe_ratio_ttm: [label: "Maximum PE Ratio (TTM)", op: :<=, type: "number"],
    peg_ratio_ttm: [label: "Minimum PEG Ratio (TTM)", op: :>=, type: "number"],
    peg_ratio_ttm: [label: "Maximum PEG Ratio (TTM)", op: :<=, type: "number"],
    cash_ratio_ttm: [label: "Minimum Cash Ratio (TTM)", op: :>=, type: "number"],
    cash_ratio_ttm: [label: "Maximum Cash Ratio (TTM)", op: :<=, type: "number"],
    current_ratio_ttm: [label: "Minimum Current Ratio (TTM)", op: :>=, type: "number"],
    current_ratio_ttm: [label: "Maximum Current Ratio (TTM)", op: :<=, type: "number"],
    dividend_yield_ttm: [label: "Minimum Dividend Yield (TTM)", op: :>=, type: "number"],
    dividend_yield_ttm: [label: "Maximum Dividend Yield (TTM)", op: :<=, type: "number"],
    earnings_yield_ttm: [label: "Minimum Earnings Yield (TTM)", op: :>=, type: "number"],
    earnings_yield_ttm: [label: "Maximum Earnings Yield (TTM)", op: :<=, type: "number"],
    price_to_book_ratio_ttm: [
      label: "Minimum Price to Book Ratio (TTM)",
      op: :>=,
      type: "number"
    ],
    price_to_book_ratio_ttm: [
      label: "Maximum Price to Book Ratio (TTM)",
      op: :<=,
      type: "number"
    ],
    price_to_sales_ratio_ttm: [
      label: "Minimum Price to Sales Ratio (TTM)",
      op: :>=,
      type: "number"
    ],
    price_to_sales_ratio_ttm: [
      label: "Maximum Price to Sales Ratio (TTM)",
      op: :>=,
      type: "number"
    ],
    quick_ratio_ttm: [label: "Minimum Quick Ratio (TTM)", op: :>=, type: "number"],
    quick_ratio_ttm: [label: "Maximum Quick Ratio (TTM)", op: :<=, type: "number"],
    return_on_assets_ttm: [
      label: "Minimum Return on Assets (TTM)",
      op: :>=,
      type: "number"
    ],
    return_on_assets_ttm: [
      label: "Maximum Return on Assets (TTM)",
      op: :<=,
      type: "number"
    ],
    return_on_equity_ttm: [
      label: "Minimum Return on Equity (TTM)",
      op: :>=,
      type: "number"
    ],
    return_on_equity_ttm: [
      label: "Maximum Return on Equity (TTM)",
      op: :<=,
      type: "number"
    ],
    ipo_date: [label: "Minimum IPO date", op: :>=, type: "date"],
    ipo_date: [label: "Maximum IPO date", op: :<=, type: "date"]
  ]

price_min: [label: "Minimum Price ($)", op: :>=, type: "number"],
price_max: [label: "Maximum Price ($)", op: :<=, type: "number"],

Are these two different columns? Or should this both be price?

^Sorry yes edited to both be price, that was a bad config. My mistake.

Does it work after changing it?

Unfortunately not (sorry I copied that from an experiment I was trying, the initial implementation is still having an issue). In an effort to provide as much helpful debugging information as possible, I'm copying the LiveView implementation and resulting filters, hopefully this will help.
LiveView:
defmodule LoinWeb.ScreenerLive do
  use LoinWeb, :live_view

  alias Loin.{FMP, Intl}

  @fields [
    name: [label: "Name", op: :ilike_or, placeholder: "Search by name...", type: "search"],
    daily_trends_symbol: [
      label: "Symbol",
      op: :ilike,
      placeholder: "Search by ticker...",
      type: "search"
    ],
    price_min: [label: "Minimum Price ($)", op: :>=, type: "number"],
    price_max: [label: "Maximum Price ($)", op: :<=, type: "number"],
    change_percent: [label: "Minimum change today (%)", op: :>=, type: "number"],
    change_percent: [label: "Maximum change today (%)", op: :<=, type: "number"],
    market_cap: [label: "Minimum market cap ($)", op: :>=, type: "number"],
    market_cap: [label: "Maximum market cap ($)", op: :<=, type: "number"],
    trend: [
      label: "Trend",
      options: [{"Uptrend", "up"}, {"Neutral", "neutral"}, {"Downtrend", "down"}],
      prompt: "",
      type: "select"
    ],
    trend_change: [
      label: "Trend change today",
      options: [
        {"Neutral to Uptrend", "neutral_to_up"},
        {"Neutral to Downtrend", "neutral_to_down"},
        {"Uptrend to neutral", "up_to_neutral"},
        {"Uptrend to downtrend", "up_to_down"},
        {"Downtrend to Uptrend", "down_to_up"},
        {"Downtrend to neutral", "down_to_neutral"}
      ],
      prompt: "",
      type: "select"
    ],
    close_above_day_200_sma: [
      label: "Close > 200D SMA",
      options: [{"Yes", true}, {"No", false}],
      prompt: "",
      type: "select"
    ],
    close_above_day_50_sma: [
      label: "Close > 50D SMA",
      options: [{"Yes", true}, {"No", false}],
      prompt: "",
      type: "select"
    ],
    day_50_sma_above_day_200_sma: [
      label: "50D SMA > 200D SMA",
      options: [{"Yes", true}, {"No", false}],
      prompt: "",
      type: "select"
    ],
    sector: [
      label: "Sector",
      options: [
        {"Communications", "Communication Services"},
        {"Consumer Discretionary", "Consumer Cyclical"},
        {"Consumer Staples", "Consumer Defensive"},
        {"Energy", "Energy"},
        {"Financials", "Financial Services"},
        {"Healthcare", "Healthcare"},
        {"Industrials", "Industrials"},
        {"Materials", "Basic Materials"},
        {"Real Estate", "Real Estate"},
        {"Technology", "Technology"},
        {"Utilities", "Utilities"}
      ],
      prompt: "",
      type: "select"
    ],
    pe: [label: "Minimum PE Ratio ($)", op: :>=, type: "number"],
    pe: [label: "Maximum PE Ratio ($)", op: :<=, type: "number"],
    eps: [label: "Minimum EPS ($)", op: :>=, type: "number"],
    eps: [label: "Maximum EPS ($)", op: :<=, type: "number"],
    pe_ratio_ttm: [label: "Minimum PE Ratio (TTM)", op: :>=, type: "number"],
    pe_ratio_ttm: [label: "Maximum PE Ratio (TTM)", op: :<=, type: "number"],
    peg_ratio_ttm: [label: "Minimum PEG Ratio (TTM)", op: :>=, type: "number"],
    peg_ratio_ttm: [label: "Maximum PEG Ratio (TTM)", op: :<=, type: "number"],
    cash_ratio_ttm: [label: "Minimum Cash Ratio (TTM)", op: :>=, type: "number"],
    cash_ratio_ttm: [label: "Maximum Cash Ratio (TTM)", op: :<=, type: "number"],
    current_ratio_ttm: [label: "Minimum Current Ratio (TTM)", op: :>=, type: "number"],
    current_ratio_ttm: [label: "Maximum Current Ratio (TTM)", op: :<=, type: "number"],
    dividend_yield_ttm: [label: "Minimum Dividend Yield (TTM)", op: :>=, type: "number"],
    dividend_yield_ttm: [label: "Maximum Dividend Yield (TTM)", op: :<=, type: "number"],
    earnings_yield_ttm: [label: "Minimum Earnings Yield (TTM)", op: :>=, type: "number"],
    earnings_yield_ttm: [label: "Maximum Earnings Yield (TTM)", op: :<=, type: "number"],
    price_to_book_ratio_ttm: [
      label: "Minimum Price to Book Ratio (TTM)",
      op: :>=,
      type: "number"
    ],
    price_to_book_ratio_ttm: [
      label: "Maximum Price to Book Ratio (TTM)",
      op: :<=,
      type: "number"
    ],
    price_to_sales_ratio_ttm: [
      label: "Minimum Price to Sales Ratio (TTM)",
      op: :>=,
      type: "number"
    ],
    price_to_sales_ratio_ttm: [
      label: "Maximum Price to Sales Ratio (TTM)",
      op: :>=,
      type: "number"
    ],
    quick_ratio_ttm: [label: "Minimum Quick Ratio (TTM)", op: :>=, type: "number"],
    quick_ratio_ttm: [label: "Maximum Quick Ratio (TTM)", op: :<=, type: "number"],
    return_on_assets_ttm: [
      label: "Minimum Return on Assets (TTM)",
      op: :>=,
      type: "number"
    ],
    return_on_assets_ttm: [
      label: "Maximum Return on Assets (TTM)",
      op: :<=,
      type: "number"
    ],
    return_on_equity_ttm: [
      label: "Minimum Return on Equity (TTM)",
      op: :>=,
      type: "number"
    ],
    return_on_equity_ttm: [
      label: "Maximum Return on Equity (TTM)",
      op: :<=,
      type: "number"
    ],
    ipo_date: [label: "Minimum IPO date", op: :>=, type: "date"],
    ipo_date: [label: "Maximum IPO date", op: :<=, type: "date"]
  ]

  @impl true
  def mount(_params, _session, socket) do
    socket =
      socket
      |> assign(:filtered_data, [])
      |> assign(:meta, %{})
      |> assign(:form_fields, @fields)

    {:ok, socket}
  end

  @impl true
  def render(assigns) do
    ~H"""

Screener filters

            <button
              class="text-blue-500 text-xs px-2 py-1 bg-white hover:bg-blue-50 rounded"
              phx-click="reset-filter"
            >
              Reset filters
            </button>

          <.form
            :let={f}
            class="grid grid-cols-2 lg:grid-cols-1 gap-4 p-4"
            for={@meta}
            phx-change="update-filter"
          >
            <Flop.Phoenix.filter_fields :let={i} form={f} fields={@form_fields}>
              <.input
                id={i.id}
                name={i.name}
                label={i.label}
                type={i.type}
                value={i.value}
                field={{i.form, i.field}}
                {i.rest}
              />
            </Flop.Phoenix.filter_fields>
          </.form>

          <Flop.Phoenix.table
            items={@filtered_data}
            meta={@meta}
            opts={[
              container: true,
              container_attrs: [class: "w-full screener-table-container lg:h-[88vh]"],
              table_attrs: [class: "min-w-full border-separate", style: "border-spacing: 0"],
              tbody_td_attrs: [class: "px-2 py-0.5 bg-white border-b border-gray-200 text-xs"],
              thead_th_attrs: [
                class: "bg-gray-100 sticky top-0 px-2 py-2 text-left text-xs font-medium"
              ]
            ]}
            path={~p"/screener"}
          >
            <:col :let={item} col_style="min-width:200px;" label="Name" field={:name}>
              <.link class="flex flex-col" patch={~p"/s/#{item.fmp_securities_symbol}"}>

                  <%= item.name %>

                <%= item.fmp_securities_symbol %>
              </.link>
            </:col>
            <:col :let={item} col_style="min-width:100px;" label="Price/share" field={:close}>
              <%= Intl.format_money_decimal(item.price) %>
            </:col>
            <:col :let={item} col_style="min-width:100px;" label="Change" field={:change_value}>

                <%= Intl.format_money_decimal(item.change_value) %>

            </:col>
            <:col :let={item} col_style="min-width:100px;" label="Change %" field={:change_percent}>

                <%= Intl.format_percent(item.change_percent) %>

            </:col>
            <:col :let={item} col_style="min-width:100px;" label="Market cap" field={:market_cap}>
              <%= Intl.format_money_decimal(item.market_cap) %>
            </:col>
            <:col :let={item} col_style="min-width:120px;" label="Trend" field={:trend}>
              <.trend_badge trend={item.trend} />
            </:col>
            <:col :let={item} col_style="min-width:120px;" label="Trend at" field={:daily_trends_date}>
              <%= item.daily_trends_date %>
            </:col>
            <:col :let={item} col_style="min-width:120px;" label="Prev trend" field={:previous_trend}>
              <.trend_badge trend={item.previous_trend} />
            </:col>
            <:col :let={item} col_style="min-width:120px;" label="Trend change" field={:trend_change}>
              <.trend_change_badge trend_change={item.trend_change} />
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Price > 200D"
              field={:close_above_day_200_sma}
            >
              <%= boolean_content(item.close_above_day_200_sma) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Price > 50D"
              field={:close_above_day_50_sma}
            >
              <%= boolean_content(item.close_above_day_50_sma) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="50D SMA > 200D SMA"
              field={:day_50_sma_above_day_200_sma}
            >
              <%= boolean_content(item.day_50_sma_above_day_200_sma) %>
            </:col>
            <:col :let={item} col_style="min-width:100px;" label="200D SMA" field={:fmp_securities_day_200_sma}>
              <%= Intl.format_money_decimal(item.fmp_securities_day_200_sma) %>
            </:col>
            <:col :let={item} col_style="min-width:100px;" label="50D SMA" field={:fmp_securities_day_50_sma}>
              <%= Intl.format_money_decimal(item.fmp_securities_day_50_sma) %>
            </:col>

            <:col :let={item} col_style="min-width:120px;" label="Sector" field={:sector}>
              <%= item.sector %>
            </:col>
            <:col :let={item} col_style="min-width:120px;" label="Industry" field={:industry}>

                <%= item.industry %>

            </:col>
            <:col :let={item} col_style="min-width:100px;" label="PE Ratio" field={:pe}>
              <%= Intl.format_decimal(item.pe) %>
            </:col>
            <:col :let={item} col_style="min-width:100px;" label="EPS" field={:eps}>
              <%= Intl.format_money_decimal(item.eps) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="PE Ratio (TTM)"
              field={:pe_ratio_ttm}
            >
              <%= Intl.format_decimal(item.pe_ratio_ttm) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="PE Growth Ratio (TTM)"
              field={:peg_ratio_ttm}
            >
              <%= Intl.format_decimal(item.peg_ratio_ttm) %>
            </:col>

            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Cash Ratio (TTM)"
              field={:cash_ratio_ttm}
            >
              <%= Intl.format_decimal(item.cash_ratio_ttm) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Current Ratio (TTM)"
              field={:current_ratio_ttm}
            >
              <%= Intl.format_decimal(item.current_ratio_ttm) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Dividend Yield (TTM)"
              field={:dividend_yield_ttm}
            >
              <%= Intl.format_percent(item.dividend_yield_ttm) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Earnings Yield (TTM)"
              field={:earnings_yield_ttm}
            >
              <%= Intl.format_percent(item.earnings_yield_ttm) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Net Profit Margin (TTM)"
              field={:net_profit_margin_ttm}
            >
              <%= Intl.format_percent(item.net_profit_margin_ttm) %>
            </:col>

            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Price/Book Ratio (TTM)"
              field={:price_to_book_ratio_ttm}
            >
              <%= Intl.format_decimal(item.price_to_book_ratio_ttm) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Price/Sales Ratio (TTM)"
              field={:price_to_sales_ratio_ttm}
            >
              <%= Intl.format_decimal(item.price_to_sales_ratio_ttm) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Quick Ratio (TTM)"
              field={:quick_ratio_ttm}
            >
              <%= Intl.format_decimal(item.quick_ratio_ttm) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Return on Assets (TTM)"
              field={:return_on_assets_ttm}
            >
              <%= Intl.format_percent(item.return_on_assets_ttm) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Return on Equity (TTM)"
              field={:return_on_equity_ttm}
            >
              <%= Intl.format_percent(item.return_on_equity_ttm) %>
            </:col>
            <:col
              :let={item}
              col_style="min-width:100px;"
              label="Employees"
              field={:full_time_employees}
            >
              <%= Intl.format_decimal(item.full_time_employees, :short) %>
            </:col>

            <:col :let={item} col_style="min-width:100px;" label="IPO Date" field={:ipo_date}>
              <%= Intl.format_date(item.ipo_date) %>
            </:col>
          </Flop.Phoenix.table>

          <Flop.Phoenix.pagination
            meta={@meta}
            path={~p"/screener"}
            opts={[
              current_link_attrs: [class: "text-white bg-blue-500 p-1 rounded text-xs"],
              next_link_attrs: [
                class:
                  "bg-gray-50 hover:bg-gray-100 p-1 rounded text-xs text-gray-500 hover:text-gray-800 order-last"
              ],
              next_link_content: "Next",
              page_links: {:ellipsis, 3},
              pagination_link_attrs: [
                class:
                  "bg-gray-50 hover:bg-gray-100 p-1 rounded text-xs text-gray-500 hover:text-gray-800"
              ],
              pagination_list_attrs: [class: "flex flex-row items-center gap-2"],
              previous_link_attrs: [
                class:
                  "order-first bg-gray-50 hover:bg-gray-100 p-1 rounded text-xs text-gray-500 hover:text-gray-800"
              ],
              previous_link_content: "Previous",
              wrapper_attrs: [
                class: "flex flex-row items-center gap-2 w-full justify-center min-h-[6vh] py-2"
              ]
            ]}
          />

    """
  end

  @impl true
  def handle_event("update-filter", params, socket) do
    {:noreply, push_patch(socket, to: ~p"/screener?#{params}")}
  end

  @impl true
  def handle_event("reset-filter", _, %{assigns: assigns} = socket) do
    flop = %Flop{} |> Flop.set_page(1) |> Flop.reset_filters()
    path = Flop.Phoenix.build_path(~p"/screener", flop, backend: assigns.meta.backend)
    {:noreply, push_patch(socket, to: path)}
  end

  @impl Phoenix.LiveView
  def handle_params(params, _, socket) do
    case FMP.filter_screener(params) do
      {:ok, {results, meta}} ->
        {:noreply, assign(socket, %{filtered_data: results, meta: meta})}

      _ ->
        {:noreply, push_navigate(socket, to: ~p"/screener")}
    end
  end

  # Private

  defp boolean_content(value) do
    case value do
      true -> "✅"
      false -> "❌"
      _ -> "-"
    end
  end

  defp class_for_value(value) do
    case value do
      x when x > 0 -> "text-green-600"
      x when x < 0 -> "text-red-600"
      _ -> "text-gray-500"
    end
  end

  defp trend_badge(%{trend: nil} = assigns) do
    ~H"""

    """
  end

  defp trend_badge(%{trend: "up"} = assigns) do
    ~H"""

      Uptrend

    """
  end

  defp trend_badge(%{trend: "down"} = assigns) do
    ~H"""

      Downtrend

    """
  end

  defp trend_badge(%{trend: "neutral"} = assigns) do
    ~H"""

      Neutral

    """
  end

  defp trend_change_badge(%{trend_change: nil} = assigns) do
    ~H"""

    """
  end

  defp trend_change_badge(%{trend_change: trend_change} = assigns)
       when trend_change in ["down_to_up", "neutral_to_up"] do
    ~H"""

      To Uptrend

    """
  end

  defp trend_change_badge(%{trend_change: trend_change} = assigns)
       when trend_change in ["up_to_down", "neutral_to_down"] do
    ~H"""

      To Downtrend

    """
  end

  defp trend_change_badge(%{trend_change: trend_change} = assigns)
       when trend_change in ["up_to_neutral", "down_to_neutral"] do
    ~H"""

      To Neutral

    """
  end
end

Params on update-filter event:
%{
  "_target" => ["filters", "8", "value"],
  "filters" => %{
    "7" => %{"field" => "trend_change", "value" => ""},
    "27" => %{"field" => "earnings_yield_ttm", "op" => "<=", "value" => ""},
    "25" => %{"field" => "dividend_yield_ttm", "op" => "<=", "value" => ""},
    "14" => %{"field" => "eps", "op" => ">=", "value" => ""},
    "8" => %{"field" => "close_above_day_200_sma", "value" => "up"},
    "36" => %{"field" => "return_on_equity_ttm", "op" => ">=", "value" => ""},
    "20" => %{"field" => "cash_ratio_ttm", "op" => ">=", "value" => ""},
    "31" => %{
      "field" => "price_to_sales_ratio_ttm",
      "op" => ">=",
      "value" => ""
    },
    "5" => %{"field" => "market_cap", "op" => "<=", "value" => ""},
    "6" => %{"field" => "trend", "value" => ""},
    "3" => %{"field" => "change_percent", "op" => "<=", "value" => ""},
    "33" => %{"field" => "quick_ratio_ttm", "op" => "<=", "value" => ""},
    "34" => %{"field" => "return_on_assets_ttm", "op" => ">=", "value" => ""},
    "26" => %{"field" => "earnings_yield_ttm", "op" => ">=", "value" => ""},
    "21" => %{"field" => "cash_ratio_ttm", "op" => "<=", "value" => ""},
    "15" => %{"field" => "eps", "op" => "<=", "value" => ""},
    "23" => %{"field" => "current_ratio_ttm", "op" => "<=", "value" => ""},
    "12" => %{"field" => "pe", "op" => ">=", "value" => ""},
    "0" => %{"field" => "name", "op" => "ilike_or", "value" => ""},
    "11" => %{"field" => "sector", "value" => ""},
    "17" => %{"field" => "pe_ratio_ttm", "op" => "<=", "value" => ""},
    "10" => %{"field" => "day_50_sma_above_day_200_sma", "value" => ""},
    "18" => %{"field" => "peg_ratio_ttm", "op" => ">=", "value" => ""},
    "39" => %{"field" => "ipo_date", "op" => "<=", "value" => ""},
    "38" => %{"field" => "ipo_date", "op" => ">=", "value" => ""},
    "35" => %{"field" => "return_on_assets_ttm", "op" => "<=", "value" => ""},
    "32" => %{"field" => "quick_ratio_ttm", "op" => ">=", "value" => ""},
    "28" => %{"field" => "price_to_book_ratio_ttm", "op" => ">=", "value" => ""},
    "29" => %{"field" => "price_to_book_ratio_ttm", "op" => "<=", "value" => ""},
    "30" => %{
      "field" => "price_to_sales_ratio_ttm",
      "op" => ">=",
      "value" => ""
    },
    "2" => %{"field" => "change_percent", "op" => ">=", "value" => ""},
    "22" => %{"field" => "current_ratio_ttm", "op" => ">=", "value" => ""},
    "24" => %{"field" => "dividend_yield_ttm", "op" => ">=", "value" => ""},
    "37" => %{"field" => "return_on_equity_ttm", "op" => "<=", "value" => ""},
    "4" => %{"field" => "market_cap", "op" => ">=", "value" => ""},
    "13" => %{"field" => "pe", "op" => "<=", "value" => ""},
    "16" => %{"field" => "pe_ratio_ttm", "op" => ">=", "value" => ""},
    "9" => %{"field" => "close_above_day_50_sma", "value" => ""},
    "1" => %{"field" => "daily_trends_symbol", "op" => "ilike", "value" => ""},
    "19" => %{"field" => "peg_ratio_ttm", "op" => "<=", "value" => ""}
  }
}

In code you posted, it still says price_min and price_max. Can you confirm that this was changed?

Flop will not render inputs for fields that are not filterable.

You are completely correct, I don't know how I missed it, but with the change to price the code is functioning as expected.
I'm so sorry for any stress/confusion I caused here, thank you so much for your amazing library and help.

No worries!


Crx package icon update, with the latest version of Cognifide logo

Cognifide logo changed to the newest version

Coverage remained the same at 71.684% when pulling c0ad56de36c13a58a4ab4eb10f664b6252af8d3a on cognifide-logo-update into 50c2317b460460de153550b4d92f7d1cf5dd301d on master.


ENH: Check signals every 10000 ufunc iteration

This mitigates #1349 by breaking the ufunc inner loop on a SIGINT.
There is really no good way of adjusting the memory allocation of GEOS. One could try to link against a custom malloc function, but that will also affect the Python interpreter. This seems a bad idea to me. If we want to control the memory allocation itself, GEOS will need to add custom memory allocators in its CAPI. trac ticket: https://trac.osgeo.org/geos/ticket/540.
Anyway, this PR offers the user to stop the function gracefully by sending a SIGINT (Ctrl+C). Now the numpy loop is stopped whenever a SIGINT is received. Before, the signals were only handled after the function resurfaced into the Python world.
Test by calling points with a big array and then hit (Ctrl+C).
For this to work, we need to acquire the GIL every 10000 iterations. I tried to hit a balance here between the performance hit and usability.
By the way, there are GEOS CAPI functions for an interrupt callback too: https://github.com/libgeos/geos/blob/5f02e3c4b70d10225c54602f69bb2106d94ae731/capi/geos_c.h.in#L301 . I experimented with these, but in the end they appeared to be not called at all in the points constructor. I guess they are mainly for the more heavy GEOS functions. Breaking the numpy loop instead seemed to be a better (more generic) way for now.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 81.11%

Totals

Change from base Build<PHONE_NUMBER>:
0.0%

Covered Lines:
2061

Relevant Lines:
2541

💛  - Coveralls

By the way, there are GEOS CAPI functions for an interrupt callback too: https://github.com/libgeos/geos/blob/5f02e3c4b70d10225c54602f69bb2106d94ae731/capi/geos_c.h.in#L301 . I experimented with these, but in the end they appeared to be not called at all in the points constructor. I guess they are mainly for the more heavy GEOS functions. Breaking the numpy loop instead seemed to be a better (more generic) way for now.

Looking at the GEOS code base, they seem to have a GEOS_CHECK_FOR_INTERRUPTS macro, which is indeed only used in certain places (such as overlay ops)

This looks like a nice solution.
I am a little bit worried about the impact of regularly acquiring the GIL again, if you would use this in a multithreaded context (something to check, I can also try to do that)

Some timing tests with 4 threads:
interrupt interval = 10000: 187 ms ± 906 µs
interrupt interval = 10000: 187 ms ± 906 µs
interrupt interval = 10000: 187 ms ± 906 µs

Some further investigation (see also the commit):

Python signal handlers are always executed in the main Python thread of the main interpreter, even if the signal was received in another thread. This means that signals can’t be used as a means of inter-thread communication. You can use the synchronization primitives from the threading module instead.
source: https://docs.python.org/3/library/signal.html#signals-and-threads

Indeed the function I used (PyErr_CheckSignals) first checks if the current thread is the main one (and if the current interpreter is the main one) over here: https://github.com/python/cpython/blob/804f2529d8e545a8d59eaf260ee032d014e681ba/Modules/signalmodule.c#L1798
So it only makes sense to check for signals from the main thread. There are however no public C API functions to check for that... I added a draft for that in the latest commit that checks the current thread ident against a one that I set when importing pygeos, but I am not very enthusiastic about this solution.
Next question is: how to terminate a multithreading script like the one in https://github.com/pygeos/pygeos/issues/164?
Tou have to set this up manually like for instance done using threading.local in the dask threadpool scheduler (https://distributed.dask.org/en/stable/_modules/distributed/threadpoolexecutor.html)

@brendan-ward  @jorisvandenbossche   I have finished this PR, now every ufunc does the signal check and (if it is running on the main thread) can be terminated with Ctrl+C.
The benchmark did not show any noticable performance deterioration. This branch is even a bit faster than the main branch, which is weird. Benchmarks are hard.
this branch:
interval = 10     182 ms ± 612 µs per loop (mean ± std. dev. of 7 runs, 10 loops each)
interval = 100    182 ms ± 703 µs per loop (mean ± std. dev. of 7 runs, 10 loops each)
interval = 1000   182 ms ± 507 µs per loop (mean ± std. dev. of 7 runs, 10 loops each)
interval = 10000  181 ms ± 434 µs per loop (mean ± std. dev. of 7 runs, 10 loops each)
interval = 100000 182 ms ± 260 µs per loop (mean ± std. dev. of 7 runs, 10 loops each)

main branch:
190 ms ± 603 µs per loop (mean ± std. dev. of 7 runs, 10 loops each)

Script used:
(see https://github.com/pygeos/pygeos/issues/164 for source for test_parallel)
import shapely
import numpy as np

coords = np.random.rand(100_000, 2)

# Running this 4 times but in parallel:
@test_parallel(4)
def g():
    shapely.points(coords)

%timeit g()

Thanks @brendan-ward  for your review. I included your suggestions and by dropping Py3.6 the tests now pass. Not sure if this can be included in 2.0 still @jorisvandenbossche  ?

@caspervdw raising this again, just because it impacts location of some of the code in this PR:

What do you think about adding this to the loops within STRtree (could be a follow-up PR)? That would probably mean moving the implementation of the signal handler to geos.c so it could be used in more places.

It's also fine for that to be refactored in a follow-up PR.

Yes sorry I forgot to reply to that. Absolutely in favour of doing this also in the STRtree. But maybe as a next PR indeed.

Test failures with GEOS main branch are unrelated:
FAILED tests/test_create_inconsistent_dimensionality.py::test_create_from_wkt[MULTIPOINT (1 1 1, 2 2)-MULTIPOINT Z (1 1 1, 2 2 0)]
FAILED tests/test_create_inconsistent_dimensionality.py::test_create_from_wkt[MULTIPOINT (1 1, 2 2 2)-MULTIPOINT Z (1 1 0, 2 2 2)]
FAILED tests/test_create_inconsistent_dimensionality.py::test_create_from_wkt[LINESTRING (1 1 1, 2 2)-LINESTRING Z (1 1 1, 2 2 0)]
FAILED tests/test_create_inconsistent_dimensionality.py::test_create_from_wkt[POLYGON ((0 0 0, 1 0 0, 1 1, 0 1 0, 0 0 0))-POLYGON Z ((0 0 0, 1 0 0, 1 1 0, 0 1 0, 0 0 0))]
FAILED tests/test_create_inconsistent_dimensionality.py::test_create_from_wkt[LINESTRING (1 1, 2 2 2)-LINESTRING (1 1, 2 2)]
FAILED tests/test_create_inconsistent_dimensionality.py::test_create_from_wkt[POLYGON ((0 0, 1 0 1, 1 1, 0 1, 0 0))-POLYGON ((0 0, 1 0, 1 1, 0 1, 0 0))]


Fix SchemaStats to return (somewhat) correct data

What should be done?
We need to find a way to calculate the data needed from SchemaStats.
It also should work when we have a concurrent deletion of schemas and tables (we should receive some data but not PostgreSQL errors). See the test TestCommandsAdministrationServerStatusStress.
// SchemaStats returns a set of statistics for FerretDB server, database, collection
// - or, in terms of PostgreSQL, database, schema, table.
// If schema is empty, it calculates statistics across the whole PostgreSQL database.
// If collection is empty it calculates statistics across the whole PostgreSQL schema.
func (pgPool *Pool) SchemaStats(ctx context.Context, schema, collection string) (*DBStats, error) {

Ref'd PR: https://github.com/FerretDB/FerretDB/pull/2322/files


Display warning if cache cannot be used for hardlinks

Problem description
Hi everyone! I've just started playing with pixi and I really find it cool! I just wanted to report on an aspect that puzzled me on my first experience. I'm adding this as a feature request since it is not a bug.
TL; DR
It would be very important to display a clear warning to the user if pixi is falling back from the hardlink to the copy mechanism for the cache upon the pixi install, init or add commands (maybe somewhere else as well?).
Full story
In my Windows 10x64 system I have two physical disk drives, C: (for system) and D: (for data and work). All of my coding work is done on drive D:. However, on a default pixi installation, the default location of PIXI_HOME and PIXI_CACHE_DIR is on the C: drive where all the system is installed.
In this way, IIUC, for all projects on the D: drive, the pixi cache will work only as a cache for downloaded files, but it will not use cache to hardlink the packages. Therefore, it (silently) keeps on creating copies of the package files for all instantiated projects on the D: drive.
It took some time to me to inspect the .pixi folders and files with fsutil and verify that indeed copies were created, not hardlinks, thereby significantly growing the used space on the drive. This is due to hardlinking not being possible across different filesystems.
Solution to avoid the problem
Change the PIXI_HOME and PIXI_CACHE_DIR to be D:\.pixi and D:\.pixi\cache (or any location within the drive your projects live in) and hardlinking works fine.

I already made the following comment in another issue but found afteward that this one may be more appropriate.
Another interesting feature would be to have an option in pixi.toml to either disable or specify the cache directory. This would allow to people using several pixi projects in various file systems to specify, for each project, a cache directory that is compatible with hard links.
Disabling cache or having the possibility to set a value relative to PIXI_PROJECT_ROOT would make it possible to build a fully self contained project directory.


Remote service method override for #760

RedissonRemoveService now supports method overload

This is aded to fix #760

Thank you!


Declaration order

It would be awesome if you could make it so that it also orders the properties like this
.selector {
    /* Positioning */
    position: absolute;
    z-index: 10;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;

    /* Display & Box Model */
    display: inline-block;
    overflow: hidden;
    box-sizing: border-box;
    width: 100px;
    height: 100px;
    padding: 10px;
    border: 10px solid #333;
    margin: 10px;

    /* Other */
    background: #000;
    color: #fff;
    font-family: sans-serif;
    font-size: 16px;
    text-align: right;
}

Or the way someone specifies. :blush:

+1

We can sort declarations using CSScomb. But, actually, I think it is necessary for CSSfmt :D
CSSfmt must not have a configuration file, so we decide one order rule. Here is default sort order of CSScomb. https://github.com/csscomb/csscomb.js/blob/master/config/csscomb.json#L28-L327
Do you have any ideas?

:+1:

I think CSSfmt should not support to sort declarations, because now CSSfmt supports SCSS syntax.
E.g:
@mixin fontSize ($size) {
  font-size: $size;
}

.class {
  @include fontSize('14px');
  font-size: 12px;
  color: #eee;
  position: absolute;
  top: 0;
  left: 0;
}

If CSSfmt formats this code, following is the result.
@mixin fontSize ($size) {
  font-size: $size;
}

.class {
  position: absolute;
  top: 0;
  left: 0;
  color: #eee;
  font-size: 12px;
  @include fontSize('14px');
}

In this case, a value of font-size is overrided.
I think, formatter tools like CSSfmt should not change source code destructive.
What do you think about it?

I think, formatter tools like CSSfmt should not change source code destructive.

I agree with you :+1:

I decide to not support sorting declaration order.

I would love if this was reconsidered. If a user's .stylelintrc includes a declaration-block-properties-order section, they would presumably be ok with updating the sort order with stylefmt. I don't think the destructive argument makes sense here since the whole premise of this tool is to rewrite files.
FWIW, I've used CSScomb in the past, but it would be way nicer to be able to maintain a single file with the preferred sort order.

@jasonlong Exactly. But, do you have any ideas to decide the declaration order with @include or @extend in SCSS code?
If there are no way to fix automatically without destructive changes, it's not the role of a formatter tool.

I agree that rules shouldn't be moved around if they aren't specified in declaration-block-properties-order.
Ideally, the sort algorithm would reposition rules just enough to make stylelint pass. If stylelint doesn't care whether an @extend is at the top or bottom (or middle), then it should stay where it is.
I realize this is easier said than done, but I think this would be incredibly handy.

Can we integrate https://github.com/hudochenkov/postcss-sorting somehow? It's not used in stylelint but it is used as part of my css format task and it'd be nice to just pass some sort of configuration into this one.


BUG in tree_topology_ex

Function kth, should be     if (k <= d[x] - d[z]) {

This should be trivial to fix, but please also include a test case which covers this bug.

Resolved by #26


tests(core): add coverage

[x] Add python coverage to generate reports.
[x] Use Github workflows to run tests
[x] Use github workflows to generate coverage report and publish it to codecov.io

Issues
Buildkit not working inside github workflows + docker compose
Before this PR we used buildkit --mount feature to cache pip dependencies: cache dependencies of pip is on my device, I mount it to docker so it does not need to download every package every time.
I had to remove this because buildkit does not work well with github workflows. I know it supports it through an official action but it does not work. I got this error:
[2055] Failed to execute script docker-compose
Traceback (most recent call last):
  File "docker-compose", line 3, in <module>
  File "compose/cli/main.py", line 81, in main
  File "compose/cli/main.py", line 203, in perform_command
  File "compose/metrics/decorator.py", line 18, in wrapper
  File "compose/cli/main.py", line 970, in run
  File "compose/cli/main.py", line 1437, in run_one_off_container
  File "compose/project.py", line 664, in up
  File "compose/service.py", line 364, in ensure_image_exists
  File "compose/service.py", line 1133, in build
  File "compose/service.py", line 1950, in build
IndexError: list index out of range

Example of failed job.
I tried to investigate but I did not manage to make it works. So I removed the --mount, it's ok because I do not download a lot of heavy libraries but it would be a nice to have... Will investigate when I have time.
I tried to use --mount only if buildkit is enabled using if/else without success.
Sources:

https://github.com/docker/compose/issues/7842

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@7577bc7). Click here to learn what that means.
The diff coverage is n/a.

:exclamation: Current head 9fa9c07 differs from pull request most recent head ba38cfb. Consider uploading reports for the commit ba38cfb to get more accurate results

@@            Coverage Diff            @@
##             master     #206   +/-   ##
=========================================
  Coverage          ?   67.97%
=========================================
  Files             ?       86
  Lines             ?     2192
  Branches          ?        0
=========================================
  Hits              ?     1490
  Misses            ?      702
  Partials          ?        0

Continue to review full report at Codecov.

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


Resource intensive and stop the service?

Started using IBeam a couple days ago. Love it!
The big issue that stops me from using it consistently is that while active, it eats up 95% of the eight gigs of RAM on my laptop. Is this intentional?
The other thing is I don't know how to stop IBeam after its running. CTRL + C in the terminal does nothing. Trying to kill the process in the task manager returns 'Access denied'. I can reboot or use a malware handler, but surely there is an easier way?
I'm on Windows 10.

Hey @ThirdGhostHand 👋 Thanks for the kind words and for reporting your issue 👍 Sorry it took me a while to get back to you!
Eating up up to 8GB of RAM is certainly not expected. On my dev environment it eats up only about .
Provide more context on which versions of IBeam are you using and whether it's the image or standalone?
@aflew61 thanks for sharing your observations 👍

Closing this issue due to lack of activity. Feel free to reopen if you'd like to continue the discussion 👍


Viewer legend is not synchronised with in-viewer filter in a specific case

Steps to reproduce:

Open a table
Add a viewer that supports in-viewer filtering (scatter plot, bar chart, line chart)
Configure viewer so that showing legend is applicable (e.g. color by column for scatter plot, or split by column for line chart)
Set-up in-viewer filter so that there are no data shown in viewer
Change in-viewer filter so that there is some data shown in viewer
Expected results: Legend should be shown.
Actual results: Legend is still hidden.
Save layout
Close and open the same table and re-apply layout
Expected results: Legend is shown, legend is synchronised with in-viewer filter and is not showing categories that are hidden on the plot.
Actual results: Legend is shown, but it is not synchronised with in-viewer filter. All existing categories are shown instead.

Fixed in 1.9.1

v1.9.2: issue is reproduced as described above
v1.10.2 (public):

Cases described above fixed.
New case (not reproduced in 1.9.2): legend is not updated when in-viewer filter is removed

Fixed in v.1.10.3

v1.11.1

Original case fixed
Legend update when filter is removed is fixed

New case discovered - legend disappears when specific filter is applied:

Open SPGI
Add a scatter plot: CAST Idea ID/Chemical Space Y, coloured by Stereo Category
Add in-viewer filter: ${Stereo Category} in "S_PART"

Expected results: legend is still shown.
Actual results: legend disappears.
Issue can be reproduced if filter contains "S_ACHIR", "S_PART", "S_UNKN", but not for "R_ONE" and "S_ABS" values.

DG v. 1.14.0


Misleading warning about source enumeration not being complete when cancelling job

Which version of the AzCopy was used?
AzCopy 10.1.2
Which platform are you using? (ex: Windows, Mac, Linux)
Windows 10
What command did you run?
> azcopy.exe sync "https://myaccount.blob.core.windows.net/myContainer?<sasToken>" "myFolder/"
What problem was encountered?
I'm copying many files (~200k+), azcopy seems to enumerate source with 5k items at the time, then copying them before enumerating the next batch. When trying to cancel the job with the intent of resuming it later, azCopy warns me with:

"The source enumeration is not complete, cancelling the job at this point means it cannot be resumed. Please confirm with y/n"

Listening to this warning would block me from stopping/resuming the job altogether. When I do confirm the cancel, it does not cancel immediately, but stops copying and continues to enumerate source instead. The job actually was able to resume by jobId.
So, while the provided warning was probably adequately describing the state in that specific moment in time, it was confusing and deeply misleading regarding the actual effect to user.
How can we reproduce the problem in the simplest way?
Use slow-enough connection, copy from blob storage with many files (20k+?) to local disk. Press Ctr-C once copy process has started.
Have you found a mitigation/solution?
The warning can presumably be ignored if you let the follow-up enumeration to finish.

Hi @ImrePyhvel, thanks for reaching out!
I've logged this item for further investigation. To clarify though, in a sync command, the tool enumerates the local directory first, and then scans the remote resource to figure out which files need to be transferred. We do this so that data can start to be transferred while enumeration is still happening.

Hi there! When I try Ctr-C during the transfer/copy process with the latest AzCopy, I do not see the message you have shared with us. Instead, I see this INFO: Cancellation requested. Beginning clean shutdown...
Please try the latest AzCopy version and let us know if this issue still persists!


Update Choose 4.x or Core for 3.0

When 3.0 previews, update this doc for 3.0
Also Update Choosing between .NET Core and .NET Framework for server apps
https://github.com/aspnet/Announcements/issues/324

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 51aecd70-d07a-3e43-0f93-63fc1a4ed1b1
Version Independent ID: fbc66624-1597-225a-3945-1f16e08ddaec
Content: Choose between ASP.NET and ASP.NET Core
Content Source: aspnetcore/fundamentals/choose-aspnet-framework.md
Product: aspnet-core
GitHub Login: @Rick-Anderson
Microsoft Alias: riande

Completed update for  first topic for this issue (Choose between ASP.NET and ASP.NET Core) with PR 13310.
Now moving on to fix 2nd topic  Choosing between .NET Core and .NET Framework for server apps..


Customize the @FeignClient bean name

package net.devh.feign;

import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

@FeignClient("service-b")
public interface ServiceBClient {

    @RequestMapping(value = "/", method = RequestMethod.GET)
    String printServiceB();
}

I see this bean name is net.devh.feign.ServiceBClient
Is there any way I can set a bean name replace default bean name

#790 is the reason why. Can you tell me why you need to set the bean name?

@spencergibb thanks.
Use full packge name + class name in every autowired.
@Autowired
@Qualifier("net.devh.feign.ServiceBClient")

I think it is unfriendly.
I think class name to the default bean name better, and @FeignClient provide a property to override the bean name.
like
@FeignClient(beanName="****")

Why don't you autowire by type?

use autowire by type, it  @work.
class name is bean name in spring.
but package name + class name is bean name in spring-cloud-netflix
Use org.springframework.beans.factory.support.BeanNameGenerator to change bean name generator way like spring.
Can you think about it?

Another use case that is going to stop us from upgrading is in integration with Camel. It references beans by name, and it will be really annoying to not have control over the names of our own beans.

This is a duplicate, though I don't have time to find the other issue.

Never mind

Just going through this issue, and I think this can be closed, but the docs need to be updated I think (at least from my current test). I was able to change the name of the bean in version 1.2.4.RELEASE with specifying the 'qualifier' value of the FeignClient annotation.
The docs however, make no mention of this and they still say the alias is generated from the name value you provided which does not seem to be the case.

@nick-pww want to submit a PR for the documentation and then we can close out this issue?

@ryanjbaxter Will take a stab at it.

Actually, reading the docs again, I guess it does mention it, just managed to gloss over it. It still seems it should be updated though as this part no longer appeared to be true:

. An alias is also created which is the 'name' attribute plus 'FeignClient'. For the example above, @Qualifier("storesFeignClient") could be used to reference the bean.

Will change PR...

Ooo...gets weirder, some have them and some don't. It appears I may getting hit by this: #1079
Not sure where to go for now. Clients that do not have @RequestMapping at the top level have the alias, where the others do not....

We don't support feign clients with top level request mapping

@spencergibb Well they seem to work ok otherwise...perhaps an exception should be thrown or something logged if you find this at startup as it's not officially supported and behavior is undefined? (realize thats what the other story is kind of covers, but would think more then just a documentation change should be done if it's truly not supported)


Disabling the dragging of paper

Awesome work Nadeeshaan!
This issue was there for some time now, it's glad that we were able to fix it! Again great work!


For Actions, the DMG supplies optional extra actions

Pages 271 / 272

Climb onto a bigger creature
Disarm
Mark
Overrun
Shove Aside
Tumble

I dont' know how to do the fork/fix thing, otherwise I would, but it would be great if these could be added to the reference sheet, here's an upvote on the off-chance @crobi happens to have some time to add them.

@FranboLobo @Jeeve65 I forked and modified the content. I also created a pull request with those changes, but seems like the project was abandoned, so not sure if this will get pulled here. In the meantime you can use https://mfriik.github.io/dnd5e-quickref/quickref.html


cmd: Remove snake case deprecation warning

While working on #625 I discovered this. We have aliases for both types of commands, so I don't think there's any need to issue a warning here.

PR checklist

[ ] Tests written/updated
[ ] Changelog entry added in .changelog (we use unclog to manage our changelog)
[ ] Updated relevant documentation (docs/ or spec/) and code comments

The changes make sense technically. However, I have the impression that they added the "deprecate snake case warning" because they were planning to remove the (snake_case) aliases in a subsequent breaking release.
(take a look at this and this)

Do we still want to remove the snake_case aliases then? Or shouldn't we just offer both? (kebab-case is easier to type when using the CLI)
And wasn't the snake_case deprecation part of the broader effort to kebab-case the config file?

Do we still want to remove the snake_case aliases then? Or shouldn't we just offer both? (kebab-case is easier to type when using the CLI)

I think that deserves a (maybe short) synchronous discussion? I've added a point for tomorrow's internal meeting. I apologize for adding a point to a meeting I'll probably not be able to attend :-|
But I am OK with whatever you folks decide.

And wasn't the snake_case deprecation part of the broader effort to kebab-case the config file?

I think so, although, by the age of tendermint/tendermint#5786 and tendermint/tendermint#5777, I'd say they first tackled this, and later (as of v0.35.x) they tackled the config.toml.

I think that deserves a (maybe short) synchronous discussion?

We spoke about it in the team call today and we decided it'd be less disruptive to users to:

Continue to offer kebab-case CLI commands as the default, as it's generally more ergonomic to type than snake_case when using the CLI.
Continue to provide snake_case CLI aliases to not break folks who depend on them.
Remove the deprecation warning.


Converting project to Godot 4.x

This PR converts the project so it works in Godot 4.
Known todos:

fix various visual issues such as missing trees and missing materials
fix issues with car setup as it bounces around like crazy (see truck town demo as a reference point)
re-enable VR mode

Would be great - on my own, I couldn't get vehiclebody NOT to bounce around :/


[Feature Request] run jitless by default

Lots of chromium exploits rely on high severity bugs in the jit compiler. Running the browser jitless by default would improve the security of the browser significantly. I don't know the exact performance loss, but on most websites it will be insignificant.

on most websites it will be insignificant

Do you have any proofs? Here they measure Speedometer 2.0 is intended to represent a typical web application, which is more than 40% slower. And Web Tooling Benchmark is nearly 80% slower.
Anyways I doubt ungoogled-chromium needs being JIT-less by default. Anyone willing could do it locally.

Luckily this isn't something that needs any code changes!
You can run jitless by adding --js-flags='--jitless' to your launch flags.

I hope your question has been answered, otherwise please let us know.
Closing this issue for now.


Is anyone kind enough to share the weights?

I am trying to get access to BEVformerV2-t8 weights but can't get access to Baidu pan. Can someone who has access kindly share?

The link has updated to google driver. See the README.


In the mobile view, Language and currency options are not visible on the header menu navigation bar.

Terms

[X] Before you openning this issue, i have checked if the issue has already been reported.

Bagisto Version(s) affected
master
Issue Description
In the mobile view, Language and currency options are not visible on the header menu navigation bar.
Preconditions

Admin should be enabled for one locale and currency.

Steps to reproduce

Go to 'Shop'
Open mobile view
Click on the Navigation button
See the error

Expected Result
It should be shown the language and currency options.
Actual Result
It does not show both options. Here
Screenshots
No response
Additional context
No response

@Amitk-webkul Assign this issue to me
Thanks


Fix to support multiple roles in one condition (or command line arguments)

Same with https://github.com/sonots/ec2-host/pull/10

0.4.4 is released


Managers would love "estimated completion date" per feature

The forecast tool is great and we use it for checking quickly if a sprint is "overbooked" during planning.
However, I'd (respectively my manager) like to see a column which displays the "estimated completion date" or "forecast date", based on the forecast, for every feature/user story.
This date would simply be the end date of the iteration that has been estimated by the forecast for backlog every item (independent of the potentially assigned iteration path)

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 9e47f8c5-7b66-ec49-a03c-1240ad9fe4f0
Version Independent ID: 21551259-e300-329a-3ce1-95dbb4730bc5
Content: Forecasting - Azure Boards
Content Source: docs/boards/sprints/forecast.md
Product: devops
GitHub Login: @KathrynEE
Microsoft Alias: kaelli

@maxkreilein - Thank you for the feedback. To give product feedback, please visit https://developercommunity.visualstudio.com/spaces/21/index.html, and click on Suggest a feature.


Multi Worm Viewer now works with raw videos (imgstore format only) + bug fix

To fix a bug in which background subtraction would only work for loopbio videos (because I was using some loopbio-specific property), I added a len() method to all video readers. In some cases (if a video is read via opencv or via ffmpeg) the len() at the begniing will provide an estimate of the video's number of frames. After the video has been read, the len() will be the exact count of frames.


English pages not yet showing correct info

No films listed in http://localhost:4000/en/films

To do:

English pages to show correct info, labels, values
Links to include locale (ex /**en/**flawless) when on pages in foreign language
Finally add language links to choose from


Wrong error for anonymous function

Hi, i've created an anonymous function and intelephense can not parse the correct number of arguments.
Like this:

It's a bug.

Are you on 1.0.3? Please check version under extensions -> PHP intelephense

Ok, i've updated and the error is gone. Thanks for this amazing extension and for the support.


Please check all of the platforms you are having the issue on (if platform is not listed, it is not supported)

[ ] iOS
[ ] Android
[ x] UWP
[ ] .NET Standard

Version of Library <IP_ADDRESS>6
Version of OS(s) listed above with issue: Windows 10 pro
Steps to Reproduce

Execute project (UWP)

Expected Behavior
UserDialogs.Instance.Loading is supposed to show a loading box.
Actual Behavior
The loading box does not appear. The rest of the project works fine.
This happens, if I use a version of Xamarin.Forms above version <IP_ADDRESS>1864.

This project has nothing to do with Xamarin Forms


Add @philipc as a recognized contributor

I am nominating or self-nominating a Recognized Contributor.
Name: Philip Craig
GitHub Username: @philipc
Projects/SIGs:

Wasmtime

Nomination
Extensive work on Wasmtime's DWARF debugging support: https://github.com/bytecodealliance/wasmtime/commits?author=philipc
Optional: Endorsements

@fitzgen

[X] I have read and understood the qualifications for a Recognized Contributor

The TSC has discussed this and agree that the contributions are worthy of recognition in the Bytecode Alliance.
@philipc, to finalize the addition, please send an email to<EMAIL_ADDRESS>to let us know which address to use for communicating with you as a Recognized Contributor, and to confirm that you accept the nomination.
That address will be added to our RCs mailing list, which receives community and project updates every few weeks or so.
Once we've received that email, we'll add you to the mailing list and merge this PR.
Thank you!

Email confirming acceptance of the nomination has been received, and our RC mailing list updated accordingly. Thanks, @philipc, and welcome!


Book: typo foreign field arithmetics

Added quite a few clarifications on the text, but ultimately still want to understand the trick with the u range check before merging...

Clarified it. Ready now. cc @querolita


Not work or I'm doing wrong?

Well, I follow the readme, but get this error:
undefined is not an object (evaluating \'this._navigator.navigationContext\')'

I'm using RN 0.11.4, with ES6/ES7 features (like the readme say).
Thanks!

Ok, with the pull #2 solve the first error, but get a new:
undefined is not an object (evaluating \'element.ref\')'
// cloneReferenceElement.js:7

Hey @jadsonlourenco sorry about that. I just pushed a fix for that error in #2

Hey @jeremyschoenherr thank you!


Upgrade real-life-example react-native to 0.44.0

Upgraded from react-native version 0.42.0
Ran react-native upgrade and corrected all changes.

👍

Hi. We are upgrading to RN 57, so closing this PR. Thank you!


should include exports

The following shoud be updated if isRelativePath moves and also if moving the bellow file, these relative paths should update.
export {
  default as isRelativePath,
} from './isRelativePath';

Also supports export all declarations.
export * from './isReleativePath';


HardwareBinder giving different UUID

I am using the HardwareBinder class to generate a UUID and include it in the license file generated by a license creator java app. Then I use this UUID to validate the license in the actual app. The problem is that the HardwareBinder class gives me a different UUID after some time. For example, the UUID is the same for two days then it changes. Also, there was a time when I restarted the computer and the UUID changed. What can this be related to? Is it maybe the OS? Has anybody had this problem before?

Same issue here, the UUID changed after reboot,  any idea?
I'm using Windows 7, JDK 1.7.

Since this is an operating system problem I close this issue. It seems that some operating systems and network drivers provide different information from time to time and thus the hardware binding can not be used reliably.
Since such a feature is also questionable the hardware binder is provided in the library as something that is there but is recommended not to be used, not only because of technical issues but also because of customer relationship problems.


feat: add optional support for TLS trusted_ca_keys extension

feat: add documentation
fix: consistent type naming convention applied
fix: failed tests
feat: added signal to stop stop server
feat: SA_RESTART flag + notes on client certificates fix: memory leak
feat: testing non-blocking read
feat: patched test only includes the test that would fail
on an unpatched OpenSSL
fix: logging to omit filename and line information fix: partial config support improved where trust anchors are missing
Describe your changes
Added support for TLS trusted_ca_keys extension.
Note its use is disabled since changes to EVSE Security are needed to obtain the trust anchor certificates needed by the extension
Issue ticket number and link
Checklist before requesting a review

[X] I have performed a self-review of my code
[X] I have made corresponding changes to the documentation
[X] I read the contribution documentation and made sure that my changes meet its requirements

Please wait for a review from @AssemblyJohn before merging

Please wait for a review from @AssemblyJohn before merging

@Pietfried review complete, awaiting code owner review/approval.


integration test

Write a proper test that I can run and get a failure. This PR doesn't have any userspace code.

This was solved on discord - at fault was incorrect alignment of hash table values IIRC.


Docs for Registers window seems out of date

these instructions no longer seem to work as the "Registers" pane is just some uneditable text which shows just a tiny fraction of the total registers.  The suggested action of tabbing around does nothing.
(I'm in Microsoft Visual Studio Community 2019 Version 16.8.3)

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 7af6b2d7-e498-7f7c-9fc6-adce4de5faeb
Version Independent ID: 2e99794c-5881-2e98-0849-dd8d8e73c173
Content: Edit a Register Value - Visual Studio (Windows)
Content Source: docs/debugger/how-to-edit-a-register-value.md
Product: visual-studio-windows
Technology: vs-ide-debug
GitHub Login: @Mikejo5000
Microsoft Alias: mikejo

Another note, you can enter register names into the watch window and edit them there so if this may be good to document in this page.


Mesosphere DCOS issue

Hey,
There seem to be an issue with the packae on mesosphere dcos.
Marathon gets stuck lanching/staging/failing ... And judginf from my mesos logs, there doesn't seem to be java installed.
The problem might come from from the marathon fetch and JAVA_HOME set in "cmd".
Anyone can relate to this?

arf damn.
Actually, I didn't had this issue, but maybe the way env is created with the last dcos 1.1 would make that failed -_-.
In the package I install the jvm as well, but it might be hardened. I'll need to check that later this evening :-(

Cool.
Yes I suspect there might be some changes in 1.1. Or maybe I mis-adjusted some settings/
Btw, might be nice to update te notebook to spark-1.4.1 or 1.5  :-)
Cheers Andy.


Watch for numberless entries that have the f/d demarcation but no option number.

https://github.com/Tristan-Anderson/Slifer_Lab_NMR_Toolsuite/blob/dfd73f01d272b4fc72c491b4f4fc781cae557c12/asciigui.py#L135
In entering just a 'f' or 'd' in the dict_choice method of the AsciiGUI object, you're going to get a value error because a sentinel ('') is not something you can turn into an int. This is caused by the user not entering the number preceding the f/d.

Took care of it in 39499db


Bug with v8 Paths, but not sure what is the root cause

I followed the example provided in the README, but the issue I'm seeing with my system is that the v8 data strips out the sourcePath from the file. This does not happen if the jest config does not have coverageProvider: 'v8'. The thing is, I'm not sure why this is happening. I'm opening this issue more to discuss. I have not made a way to publicly reproduce because this is on our internal monorepo with Bazel.
Basically, the lcov file generate is missing path/to/file.ts with that option on. It just returns file.ts.
I have some theories, but nothing concrete. Any ideas?

This path issue could be a sourcemap issue. The sourcemap of the file didn't provide the full path of the file.
{"version":3,"sources":["file.js"],"sourcesContent":[ ...

Please try to normalize the sourcePath with option sourcePath.
Possible solutions:
sourcePath: (filePath, info)=> {
    if (!filePath.includes('/') && info.distFile) {
      return `${path.dirname(info.distFile)}/${filePath}`;
   }
    return filePath;
  },

Thanks I believe that did it! That's definitely worth documenting in the README. Should it go in this repo or the monocart main one?

Thank you for the reminder, I have updated the document for both jest-monocart-coverage and monocart-coverage-reports repo.


Is there a way to fetch the original PDF files that contain both tables and all other document contents?

You can retrieve, store, and use the content of arXiv e-prints by arXiv APIs, under the terms of use.
The filenames of SciTSR data are the arXiv ids. You can get the corresponding document contents with these ids.


Change theme colours of the app

Use some website like coolers.co to change the main colours of the app

How about yellow (primary colour) and light blue (secondary): https://coolors.co/eff9f0-fdc921-fdd85d-99d6ea-13070c

Gradients: https://www.eggradients.com/category/yellow-gradient
Figma: https://www.figma.com/file/RmznVxbcnCwYCu6gZXEpFA/Apple-Wallet-Pass-Kit-(Community)?type=design&node-id=9%3A2660&mode=design&t=ft3fT0mKtr6eUS4r-1


create RestTemplate with LoadBalancerInterceptor using @LoadBalanced qua...

...lifier.
fixes https://github.com/spring-cloud/spring-cloud-netflix/issues/267
@dsyer is this along the lines of what you were thinking?

I like the @LoadBalanced. Where does it get used though? Don't you need to inject it somewhere?

We don't inject RestTemplate anywhere, just make it available to users.  When you want the load balanced RestTemplate you do:
@Autowired
@LoadBalanced
private RestTemplate loadBalanced;

OK, I like. Can we do the same thing with OAuth2RestTemplate?

yup

in the case of OAuth2RestTemplate should we create both one with @LoadBalanced and one without?

https://github.com/spring-cloud/spring-cloud-security/issues/51


Text classification: The prediction score should be calibrated and normalized to 1 for the generated Console App and Web API projects.

System Information (please complete the following information):
Windows OS: Windows-11-Enterprise-22H2
ML.Net Model Builder 2022: <IP_ADDRESS>6301 (Main Build)
Microsoft Visual Studio Enterprise: 2022(17.5.5)
.Net: 6.0, 7.0
Describe the bug

On which step of the process did you run into an issue:
The prediction score should be calibrated and normalized to 1.

TestMatrix
https://testpass.blob.core.windows.net/test-pass-data/wikipedia-detox-250-line-data.tsv
To Reproduce
Steps to reproduce the behavior:

Select Create a new project from the Visual Studio start window.
Choose the C# Console App (.NET Core) project template.
Add model builder by right click on the project.
Select "Text classification" scenario.
Choose "Local (CPU)" environment.
On the Data page, choose data source to complete the training.
Go to the Consume page, click "Add to solution" button to generate the Console App and Web API projects.
Debug the generated Console App and Web API projects and check the prediction score.

Expected behavior
The prediction score should be calibrated and normalized to 1.
Screenshot

Additional context

This issue has been discussed in bug #2360, but it was closed. Hence, I open this new bug to tracking the issue.

@zewditu Can you take a look at it?

The bug has been fixed on the latest main build <IP_ADDRESS>0401.


FR: Update existing check_date or survey:date if already present

If an updated feature already has a survey:date tag - it's better to update it instead of adding extra check_date (quite popular StreetComplete uses survey:date)

quite popular StreetComplete uses survey:date

To add some context: while StreetComplete does indeed use survey:date (among other tags) to determine if place should be resurveyed, when the mapper does confirm the place still exist, StreetComplete will remove survey:date and other similar tags and replace them with check_date (set to today, obviously).
There was also a discussion in https://github.com/streetcomplete/StreetComplete/issues/2592 few years ago about survey:date vs. check_date where the decision to use check_date was reaffirmed; so that thread might provide some background on the reasoning.

Yeah, I assessed all the options when choosing the key, and check_date seems better fitting. Idk why people started adding survey:date in the first place.


Ipynb file may get overwritten, causing updates to fail.

Describe the bug
If the ipynb file is overwritten, for example if the user has an autosave autocmd, the update command fails.

Does converting the notebook to/from ipynb with jupytext on the command line work?

No if using the --update argument, yes otherwise.
I'm unsure about the best way to go about this, but possibly, if jupytext fails to update, try again without the update? Potentially with a check for the ipynb file contents now being the same as the buffer?

@goerz do you have any thoughts here?

Hello @goerz , @BlueDrink9. I am not an advanced VIM user, but maybe I can contribute my own experience with this.
I use paired notebooks (py/ipynb), and open them simultaneously in Jupyter (ipynb) and in my text editor (py file, in PyCharm Pro). Conflicts do occur, either because of the autosave, or because I have changed the notebook in both Jupyter and my text editor. In this situation, Jupyter and the editor both tell me that the file has changed on disk, and give me the option to reload or overwrite. Most of the time I am happy with overriding the notebook with one of the two versions. But sometimes I prefer to merge the two edits, and here I find PyCharm very convenient, as it lets me compare the two different version of the .py file (in memory vs on disk), and merge them.
Would that work in VIM as well? Do you need something else than paired notebooks (i.e. jupytext --set-formats ipynb,py notebook.ipynb)?

The problem is not that they become out of sync. This plugin opens a buffer called [].ipynb, but fills it with the translated content. The write command that this plugin uses to then translate it back to the ipynb format in the file doesn't always replace the default vim write command, meaning the ipynb file sometimes ends up as a plaintext file, rather than a valid json.

Are you able to reproduce a situation where the plain text ends up being written to the ipynb file? I think I’ve had that happen once or twice, but wasn’t able to determine the cause.

@mwouts To be clear: I think if you actually have linked notebooks in a directory, it’s best not to use the jupytext.vim plugin and to just open the actual py or md file in vim. I don’t have much experience with this, though, as I haven’t really used linked notebooks so far.

I think this is one of the things causing it.
function! Autosave()
    " Don't autosave if there is no buffer name.
    if bufname('%') != '' && &ro != 1 && &modifiable == 1
        " Automatically save before commands like :next and :make
        set autowrite
        " If no changes, don't touch modified timestamp.
        silent! update
    endif
endfunction
au! FocusLost,InsertLeave,BufLeave * call Autosave()

If you actually have linked notebooks in a directory, it’s best not to use the jupytext.vim

Linked notebooks we definitely not part of the design of the original plugin. But, since I've since started to use paired notebooks myself quite extensively, and also finally made the switch to Neovim with a full Lua configuration a few months ago: This should now be fully supported in the rewrite of this plugin at https://github.com/goerz/jupytext.nvim


xen: Change load address and entry point to 0x88080000

This is just fixup to already changed addresses used
for xen-chosen and for u-boot parameters.
Signed-off-by: Ruslan Shymkevych<EMAIL_ADDRESS>

Reviewed-by: Volodymyr Babchuk<EMAIL_ADDRESS>

Reviewed-by: Volodymyr Babchuk<EMAIL_ADDRESS>

RB is added.
PR was tested by a build of prod-devel-rcar for h3ulcb-4x2g-kf and successfully ran on board with domD and domU started.
@iusyk could you please merge?


Create template pull-request

@AdrianoKF kind request for your review. I assumed that .github directory is suitable place for PR template.

@AdrianoKF True, there is only .md option for PR (it was my wishful thinking to do this in yaml). Replaced .yaml with .md template.

@Maciej818, feel free to merge after the final touches!


Allow for Short-Circuiting on Step that Returns Success

A dry-transaction only short-circuits when a step returns a Failure. I want it to be possible to short-circuit upon a step returning a  Success. I was not able to figure out a clean way to do this.
Besides being able to short-circuit upon a singular step resulting in a Success, another similar feature could be to have an option that makes all of the steps glued together with or instead of bind, but this wouldn't be as flexible as I would want.
Current options:

Custom step: I didn't find a way to short-circuit out of the list of steps since it is hard-coded to join steps with #bind
Return a Failure and have outside code deal with the (Failure) result know that it is actually a success
Handle the Failure with a matcher that changes the eventual output (see below)

gem 'dry-transaction', '=0.11.1'
require 'dry-transaction'

class Tranx
  include ::Dry::Transaction

  step :one
  step :two
  step :three

  def call(input, &block)
    if block
      super
    else
      super(input) do |result|
        result.failure(:two) { |v| Success(v.to_s + ': failure') }
        result.success(:two) { |v| Success(v.to_s + ': success') }
      end
    end
  end

  private

  def one(*)
    Success(1)
  end

  def two(*)
    Failure(2)
  end

  def three(*)
    Success(3)
  end
end

Tranx.new.call('foo') # => Success('2: failure')

Thanks for the note, @nannery. I'm not sure if this kind of behaviour really fits within the design of dry-transaction.
I can see 2 alternative options that could work well for you:

Create a plain class using dry-monads' "do notation", which is still a very clean API  but one that gives you more control, allowing you to short-circuit with a simple early return, like regular old Ruby :)
Consider using something like trailblazer-operation or trailblazer-activity, which provide much more sophisticated control flow APIs.

Awesome, those are great ideas. I hadn't seen the Do Notation when I wrote this, looks great!

Another alternative I see here is to use an around step with catch and then throw from any step.


Upgrade to SLF4J 1.7.21

I've updated to SLF4J 1.7.21.
Please review this.

Thanks! We did the same change almost at the same time.


Add leftPadTo(int, T)

We already have Seq<T> padTo(int, T).
Now we want to add Seq<T> leftPadTo(int, T) in a similar way.
Motivated by this article.

Meaning Javaslang won't be found on NPM after all? :stuck_out_tongue_winking_eye:

Successfully finished.


Add description to all python methods

Add description to all python methods
Add empty build/ directory, ensure it stays empty

Helps to actually add the changed files...


(PUP-4668) Fix leading 'class...' 3.x resource type conversion

Before this the use of references such as Classroom, Classroom[x] would
when converted to a 3.x parameter value i.e. used this way:
notify { bad: require => Classroom[nbr3] }
would misinterpret the leading 'Class' (or 'class') as if it was a
reference to the class nbr3 not the resource Classroom[nbr3].
This was caused by a non end-anchored regular expression.

CLA signed by all contributors.


Crash during <IP_ADDRESS> installation

Microsoft PowerToys version
0.74.0
Installation method
PowerToys auto-update
Running as admin
No
Area(s) with issue?
General
Steps to reproduce
Clicked to approve update from the PowerToys update available prompt.
2023-09-27.txt
✔ Expected Behavior
installation success
❌ Actual Behavior
"Something went wrong" popup with log displayed.  Log file is attached.
Exception:
System.UnauthorizedAccessException: Access to the path 'C:\Users\ssaari\AppData\Local\Microsoft\PowerToys\PowerToys Run\Settings\Plugins\Microsoft.Plugin.Shell\ShellPluginSettings.json' is denied.
However I restarted the program and it shows version <IP_ADDRESS>.  I do not know what the previous version was that was installed, but I never skip updates.
Other Software
No response

"C:\Users\ssaari\AppData\Local\Microsoft\PowerToys\PowerToys Run\Settings\Plugins\Microsoft.Plugin.Shell\ShellPluginSettings.json"
Is this a file you can access if you go there through File Explorer, for example?
The error seems to be about access to that file.
/needinfo

Yes, I opened the file that I attached.
Regards,
Scott Saari
@.***
602-230-7824
On Wed, Sep 27, 2023 at 9:34 AM Jaime Bernardo @.***>
wrote:

"C:\Users\ssaari\AppData\Local\Microsoft\PowerToys\PowerToys
Run\Settings\Plugins\Microsoft.Plugin.Shell\ShellPluginSettings.json"
Is this a file you can access if you go there through File Explorer, for
example?
The error seems to be about access to that file.
/needinfo
—
Reply to this email directly, view it on GitHub
https://github.com/microsoft/PowerToys/issues/28810#issuecomment-1737638901,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AA7K2VAO765RB56I6I7LMHDX4RBQ7ANCNFSM6AAAAAA5JPYSKI
.
You are receiving this because you authored the thread.Message ID:
@.***>

This looks like a crash in PT Run and is unrelated to the update process.
PT Run failed to read the settings file of the shell plugin in local appdata folder. Maybe we need better error handling when reading the "wox" plugin settings files using the wox code.

@ssaari
To investigate this we need the complete stack trace. Please upload a bug report. /bugreport

@ssaari
To investigate this we need the complete stack trace. Please upload a bug report. /bugreport

Sory. I saw the log file to late.

System.UnauthorizedAccessException: Access to the path 'C:\Users\ssaari\AppData\Local\Microsoft\PowerToys\PowerToys Run\Settings\Plugins\Microsoft.Plugin.Shell\ShellPluginSettings.json' is denied.
   Source: System.Private.CoreLib
   TargetAssembly: System.Private.CoreLib, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=7cec85d7bea7798e
   TargetModule: System.Private.CoreLib.dll
   TargetSite: Microsoft.Win32.SafeHandles.SafeFileHandle CreateFile(System.String, System.IO.FileMode, System.IO.FileAccess, System.IO.FileShare, System.IO.FileOptions)
   at Microsoft.Win32.SafeHandles.SafeFileHandle.CreateFile(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options)
   at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable`1 unixCreateMode)
   at System.IO.File.OpenHandle(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)
   at System.IO.File.WriteToFile(String path, FileMode mode, String contents, Encoding encoding)
   at System.IO.Abstractions.FileWrapper.WriteAllText(String path, String contents)
   at Wox.Infrastructure.Storage.JsonStorage`1.Save()
   at Microsoft.Plugin.Shell.Main.Save()
   at Microsoft.Plugin.Shell.Main.UpdateSettings(PowerLauncherPluginSettings settings)
   at Wox.Plugin.PluginPair.Update(PowerLauncherPluginSettings setting, IPublicAPI api)
   at PowerLauncher.SettingsReader.ReadSettings()
   at PowerLauncher.App.<>c__DisplayClass19_0.<OnStartup>b__0()
   at Wox.Infrastructure.Stopwatch.Normal(String message, Action action)
   at PowerLauncher.App.OnStartup(Object sender, StartupEventArgs e)
   at System.Windows.Application.<.ctor>b__1_0(Object unused)
   at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
   at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

@ssaari , Does this still happen after a computer restart, or was it just once after install? /needinfo

Hello,
It only occurred during the initial software update sequence.
Regards,
Scott Saari
@.***
602-230-7824
On Wed, Sep 27, 2023 at 1:11 PM Jaime Bernardo @.***>
wrote:

@ssaari https://github.com/ssaari , Does this still happen after a
computer restart, or was it just once after install? /needinfo
—
Reply to this email directly, view it on GitHub
https://github.com/microsoft/PowerToys/issues/28810#issuecomment-1737938910,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AA7K2VBV3JMKODXPIVHYKQTX4R24PANCNFSM6AAAAAA5JPYSKI
.
You are receiving this because you were mentioned.Message ID:
@.***>

Hi,
just wanted to mention that I get the error with <IP_ADDRESS>, too.
Pops up when logging into Windows.
Details

Version: <IP_ADDRESS>
OS Version: Microsoft Windows NT 10.0.19044.0
IntPtr Length: 8
x64: True
Date: 11.12.2023 06:40:14
Exception:
System.UnauthorizedAccessException: Access to the path 'C:\Users\ma099801\AppData\Local\Microsoft\PowerToys\PowerToys Run\Settings\Plugins\Microsoft.Plugin.Shell\ShellPluginSettings.json' is denied.
at Microsoft.Win32.SafeHandles.SafeFileHandle.CreateFile(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options)
at Microsoft.Win32.SafeHandles.SafeFileHandle.Open(String fullPath, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize, Nullable1 unixCreateMode)    at System.IO.File.OpenHandle(String path, FileMode mode, FileAccess access, FileShare share, FileOptions options, Int64 preallocationSize)    at System.IO.File.WriteToFile(String path, FileMode mode, String contents, Encoding encoding)    at System.IO.Abstractions.FileWrapper.WriteAllText(String path, String contents)    at Wox.Infrastructure.Storage.JsonStorage1.Save()
at Microsoft.Plugin.Shell.Main.Save()
at Microsoft.Plugin.Shell.Main.UpdateSettings(PowerLauncherPluginSettings settings)
at Wox.Plugin.PluginPair.Update(PowerLauncherPluginSettings setting, IPublicAPI api, Action refreshPluginsOverviewCallback)
at PowerLauncher.SettingsReader.ReadSettings()
at PowerLauncher.App.<>c__DisplayClass19_0.b__0()
at Wox.Infrastructure.Stopwatch.Normal(String message, Action action)
at PowerLauncher.App.OnStartup(Object sender, StartupEventArgs e)
at System.Windows.Application.<.ctor>b__1_0(Object unused)
at System.Windows.Threading.ExceptionWrapper.InternalRealCall(Delegate callback, Object args, Int32 numArgs)
at System.Windows.Threading.ExceptionWrapper.TryCatchWhen(Object source, Delegate callback, Object args, Int32 numArgs, Delegate catchHandler)

Thanks, Mathias

I asume we can do this one if you find other bugs with the same error:
System.UnauthorizedAccessException: Access to the path 'C:\Users\ssaari\AppData\Local\Microsoft\PowerToys\PowerToys Run\Settings\Plugins\Microsoft.Plugin.Shell\ShellPluginSettings.json' is denied.

Thank you ;)

This has been worked on during the 0.79.0 release cycle.
Please update to the latest: https://github.com/microsoft/PowerToys/releases


Closes: #1

Updated validations.py python script
Added function calls to end of script
Edited comment to reflect changes of validating username so that it
begins with only case-insensitive letter.
Fixes #<issue_number_goes_here>

It's a good idea to open an issue first for discussion.

[ ] Tests pass
[ ] Appropriate changes to README are included in PR

@googlebot I signed it


'Camera' object error

We get this error on startup (it still loads and seems to work ok).
AttributeError: 'Camera' object has no attribute '_rep_registry'
Exception ignored in: <function Camera.__del__ at 0x7f0454780ca0>
Traceback (most recent call last):
  File "/home/ubuntu/IsaacLab/source/extensions/omni.isaac.lab/omni/isaac/lab/sensors/camera/camera.py", line 139, in __del__
    for _, annotators in self._rep_registry.items():
AttributeError: 'Camera' object has no attribute '_rep_registry'

We managed to install isaacsim using the normal (omniverse client) method. This changes the errors to this:
Summary: 1 package finished [1.09s]
Traceback (most recent call last):
  File "/home/ubuntu/go2_omniverse/main.py", line 25, in <module>
    from omniverse_sim import run_sim
  File "/home/ubuntu/go2_omniverse/omniverse_sim.py", line 7, in <module>
    from omni.isaac.lab.app import AppLauncher
  File "/home/ubuntu/IsaacLab/source/extensions/omni.isaac.lab/omni/isaac/lab/app/__init__.py", line 15, in <module>
    from .app_launcher import AppLauncher  # noqa: F401, F403
  File "/home/ubuntu/IsaacLab/source/extensions/omni.isaac.lab/omni/isaac/lab/app/app_launcher.py", line 27, in <module>
    from omni.isaac.kit import SimulationApp
ModuleNotFoundError: No module named 'omni.isaac.kit'

Thanks for the report! I know this issue, don't have time to fix it.

Face the same issue.

Running into the same issue mentioned by @ahanjaya

system is freezing

What hardware are you using? Can you try one more time with --robot_amount 1 param, please?

I will close this issue, if you have the same errors just open a new one, thanks! Also, use --robot_amount 1 if you have a weak PC hardware setup.

I still face the same issue with "AttributeError: 'Camera' object has no attribute '_rep_registry'" is added_copter branch.


Update samples for "vela show xxx --web"

Also stop generating components/traits docs under
docs/en/end-user and remove the command from Makefile
Fix #1602

please create a new issue about "generate the sample automatically （low priority）" if you want to close #1602


Add TE custom partitioning support to Paxml

This PR updates TE to add support for custom partitioning in Paxml. In particular, this PR

reverts the pinning of TE
adds the required praxis patch to the patchlist

This should be merged after the existing t5x and paxml TE patches have been updated to include custom partitioning support.

This PR was merged without an all-green presubmit CI. Is this what we are trying to avoid going forward?


Adds test for Mars TMS

This PR adds tests and support for a Mars planetary TMS. This test adds planetcantile as a dependency (to get the planetary TMS) included. That repo has a PR open here that adds the necessary _geographic_crs key to the TMS specifications. This ensures that the default (WGS84) that morecantile encodes is respected and that we do not get PROJ errors about missing transformations. So, #15 needs to land before this lands.
Now, I am still seeing errors about incorrect negative dimensions in these tests. It looks like the bbox used in find_extrema is not properly populating.
Also, It is necessary to pass the TMS to the burntiles() calls in order to get the encoding working properly. So, clients are going to need to be able to pass in the TMS to cogeo-mosaic. I have not looked at if and how that happens yet. I assume that this passes in through TiTiler.

@jlaura I think adding planetcantile as a dependency is too heavy-handed. At most it could be considered a dev dependency, alternatively copying over a tms json file into the test fixtures folder for this project could be a easier solution. That said, I don't know what this test brings for cogeo-mosaic's perspective. It may make more sense to move this test into planetcantile.

@AndrewAnnex Sure, removing the planetcantile dependency and then loading a single TMS as a string would working fine. The larger issue with the PR is that this still is not loading the TMS properly. The round trip on the point burn is failing to convert back to projected space properly.

@jlaura maybe then it's worth converting the test to just use a Earth projection like EPSG:4087, may require making the TileMatrixSet object in the test if there isn't a default morecantile TMS that would work but that shouldn't be too difficult

I don't think this is relevant to cogeo-mosaic directly but will be better suited within planetcantile


Fix logging and force folder creation for JSON export

There was double logging for asset file export in lines 247 and 163 which was removed.
And when trying to write JSON files, the export fails if the folder doesn't exist. This is now changed to the same behaviour as with PDF reports (force folder creation).

Gracias! ☺


Issue726 1.8

We're making more use of the OLCStringsAsUTF8 capability marker and eliminating some duplication of logic.
Resolves #726, which reported that a .cpg file was being overlooked.
In the process, I discovered that the coutwildrnp.shp lacked a valid code page. I've added a ISO-8859-1 .cpg file for it.

The AppVeyor errors are (the pip exception) annoying and (build failure with 2.4) baffling.

Coverage decreased (-0.5%) to 82.632% when pulling 47facf2c50413e8330ff8e225301066b51b9fff0 on issue726-1.8 into 0a9d57e7192c21c9315d6eda36c0809e87de38aa on maint-1.8.

I'm away from home this week, but will look at this when I get back.


Use the compatible constructor Buffer(byte[], int, int) when Buffer() does not exist

This is a fix to deal with an issue https://github.com/embulk/embulk/issues/1409 that the library does not work well with Embulk v0.9.
The reason of this class structure is described at:
https://github.com/embulk/embulk-util-file/pull/13/files#diff-de61943700f059ae63ebc175aae5418df031ca2748bc08136c4fa518b64fbda2R32-R46

Confirmed it works with locally-built https://github.com/hiroyuki-sato/embulk-parser-jsonpath/tree/topic/try-v0_9-v0_10 on Embulk v0.9.23.

Thanks!


Run analysis failed ....

While I was trying to run the analysis, it returns the following error:
: CommandLine Error: Option 'print-summary-global-ids' registered more than once!
LLVM ERROR: inconsistency in registered CommandLine options
[1]    545666 IOT instruction (core dumped)  cargo ffi-checker

Oh, someone provided a good solution before: https://github.com/lizhuohua/rust-ffi-checker/issues/1#issuecomment-1286469596
Issue is resolved.


Add prune to Gopkg.toml

We've been using separate prune command, but that's not obvious for external contributors. This is an attempt to use "prune" built in the dep itself. It deletes even more files than external prune command, let's tune if needed.

Cool


Things to discuss with @pokey

[ ] Are hats only ever one character? Currently we export a start/and range because it the decoration range

Today they're only one character, but it's possible they could be more than one in the future, eg https://github.com/cursorless-dev/cursorless/issues/71
I wouldn't go crazy trying to support more than one character, but if it doesn't make life harder I'd be inclined to support ranges

OK. @rntz was a little confused about the API in the JSON that we were writing, since they were expressed as ranges but were only ever one character long. Guess we'll leave them as ranges for now!

Yeah that's fair. If you think it will be simpler / less confusing to assume they're one char, that's prob fine


[port bug][libmicrohttpd] Failed to install on Ubuntu 16.04

$ ./vcpkg install libmicrohttpd

The following packages will be built and installed:
    libmicrohttpd[core]:x64-linux
Starting package 1/1: libmicrohttpd:x64-linux
Building package libmicrohttpd[core]:x64-linux...
-- Using cached /home/vcpkg/vcpkg/downloads/libmicrohttpd-0.9.63.tar.gz
-- Configuring x64-linux-dbg
-- Configuring x64-linux-rel
-- Building x64-linux-dbg
CMake Error at scripts/cmake/vcpkg_build_cmake.cmake:202 (message):
    Command failed: /home/vcpkg/vcpkg/downloads/tools/cmake-3.14.0-linux/cmake-3.14.0-Linux-x86_64/bin/cmake;--build;.;--config;Debug;--target;install;--;-v
    Working Directory: /home/vcpkg/vcpkg/buildtrees/libmicrohttpd/x64-linux-dbg
    See logs for more information:
      /home/vcpkg/vcpkg/buildtrees/libmicrohttpd/install-x64-linux-dbg-out.log

Call Stack (most recent call first):
  scripts/cmake/vcpkg_install_cmake.cmake:24 (vcpkg_build_cmake)
  ports/libmicrohttpd/portfile.cmake:21 (vcpkg_install_cmake)
  scripts/ports.cmake:71 (include)

Error: Building package libmicrohttpd:x64-linux failed with: BUILD_FAILED
Please ensure you're using the latest portfiles with `.\vcpkg update`, then
submit an issue at https://github.com/Microsoft/vcpkg/issues including:
  Package: libmicrohttpd:x64-linux
  Vcpkg version: 2018.11.23-unknownhash

Additionally, attach any relevant sections from the log files above.

Log file: install-x64-linux-dbg-out.log

The same issue appears on OSX too.