Proof protocol

PR that implements the protocol for generating and distributing the dzkp proofs.
It does not include verification and only includes some simple tests. I will add extensive tests once the verification is also implemented. All previous tests that check the mathematical components still pass.
I changed some of the structs in prover.rs to work more smoothly with iterators. Unfortunately, the PR became larger than I initially anticipated.

Comment from Andy:

It would be helpful to have a summary of what is changing and why in the PR description.
If I understand right, λ is renamed to R, and the R type parameter is used directly in places where the parameter N=2λ+1 was used before. How does this simplify the code?
The ProofGenerator type seems to be replaced with UVStore. Part of what I understand (based on in-person discussions, as opposed to studying the PR) to be going on here is that the first pass of the proof will work with an iterator over u and v values rather than storing them all in an array, since that is (1) possible for the first pass, and (2) a fully expanded copy of u and v for the first pass would be very large -- a significant multiple larger than the raw multiplication intermediates, at least until we implement packing. Writing the proof generation routines in terms of iterators enables them to work either from an array or iterator of u/v values. Since the name UVStore implies a data storage type, I think it would be better not to implement complex prover functionality in methods on the UVStore type. Similarly, if we're getting rid of the ZeroKnowledgeProof type in favor of using GenericArray directly, then we can't implement complex prover functionality as methods on GenericArray. Possibly the prover functionality could be implemented as free functions in the prover module. I see how the methods are serving as constructors for UVStore and ZeroKnowledgeProof, but I'm not sure there's a compelling reason for them to be that way. I feel like the logic that structures and terminates the recursion should also be implemented here, rather than left to the caller, but maybe there's a good reason an abstraction around that doesn't work.
It would be useful to have some additional comments on these routines explaining what they do and how they are to be used. Some amount of the detail is in the paper and when it is, references to the paper are fine, but I don't think it's possible to match the notation in the paper precisely enough that no additional explanation is necessary. It would also be nice if the implementation had enough self-contained documentation that it is possible to use the proof system without referring to the paper. (This concern is not new with the changes in this PR -- I feel the same about the original.)
Assuming we can align on the changes, is there a reason not to go ahead and update the tests to reflect the revisions (instead of leaving some routines as deprecated but used by tests)?


Dockerization

We currently have a Dockerfile but it would be nice to have a docker-compose file, perhaps we can have one for every one of the most common ways to run renterd, e.g. as a single or multi-node setup.

can i take this one ?

@dbarnwal assigned to you

unassigned so others can pick it up

@ChrisSchinnerl push this back to backlog?

I think it's fine to keep it as TODO since it's also a "good first issue"


Clarification on network traffic pricing

It would be useful to address data traffic price implications of a Storage Account service endpoint (or other) versus default bevahiour. EG. A VM downloading data from a service-endpoint for a storage account, both in the same regions, will be considered ______  traffic and charged at ___$.

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

ID: 1eb0407d-f4a5-6059-488d-fd082915c675
Version Independent ID: 7c2fb429-743c-aea0-f1d5-de6dc2e62e8e
Content: Azure virtual network service endpoints
Content Source: articles/virtual-network/virtual-network-service-endpoints-overview.md
Service: virtual-network
GitHub Login: @sumeetmittal
Microsoft Alias: sumeet.mittal

@gcormier , Thanks for your feedback. We are looking into this query and will update you as soon as possible.

@gcormier there are no price differences for using Azure Storage in a Service Endpoint vs accessing from public internet. The only difference is how your traffic is routed to your storage account.

I have a ticket open (<PHONE_NUMBER>02138 ) that is indicating otherwise...
On Mon, Jun 3, 2019 at 4:23 PM TravisCragg-MSFT<EMAIL_ADDRESS>wrote:

@gcormier https://github.com/gcormier there are no price differences
for using Azure Storage in a Service Endpoint vs accessing from public
internet. The only difference is how your traffic is routed to your storage
account.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/MicrosoftDocs/azure-docs/issues/32620?email_source=notifications&email_token=ACAAC57QTBIE2RKZEQKMP23PYV4T7A5CNFSM4HSIXPZKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODW2STVI#issuecomment-498411989,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACAAC54AQPEW7BARJ7CPK7TPYV4T7ANCNFSM4HSIXPZA
.

@gcormier Thanks, I will have a look over that ticket!

@gcormier I have looked over that ticket, and the only charges you should be seeing from that VM to a storage account in the same region are for your Block Blob Storage read operations, and these charges should occur regardless of how you access the storage account.
From the Virtual Network side, there is no charge for service endpoints, and no charge for data transfer within the same region. The only other charge you could be seeing on the VM is if it is in an Availability Zone, there is an inbound and outbound transfer charge.
Have you tried transferring the data in a VNET in the same region without Service Endpoints and see if there is a difference?

Nice to hear.. as it feels like I've lost my mind or something on that ticket. The ticket has been quite a journey.
Indeed, I cannot see any billing for data egress on my storage account. So it reflects what you mention.It would be great to get a confirmation in writing from MS support this is the case and working as intended :)
If support isn't even clear on the pricing model, perhaps docs need updating. Not the vnet-peering docs per se, but potentially storage account documentation? On the AWS side, I believe they DO charge egress unless the storage (s3) is VPC peered.

@gcormier It looks like your ticket is going in the right direction, and should reflect what I stated here. If you need any additional clarification or are having any issues with the CSS ticket, please tag me in a reply!
We will now proceed to close this thread. If there are further questions regarding this matter, please tag me in your reply. We will gladly continue the discussion and we will reopen the issue.


How to use CSS Modules with TanStack Start?

Which project does this relate to?
Start
Describe the bug
I'm struggling to make CSS Modules work properly. Currently, the styles are being loaded only on the client, causing a flash of unstyled content (FOUC) during initial render.
I tried in this repo https://github.com/tanstack/router/tree/main/examples/react/start-basic
Your Example Website or App
https://github.com/nikolayemrikh/start-css-modules-bug
Steps to Reproduce the Bug or Issue

Clone repo https://github.com/nikolayemrikh/start-css-modules-bug
Add CSS Modules support by creating a .module.css file and importing it into a React component.
Run the server and open the app in a browser.
Observe that the styles are applied only after the client-side hydration, causing a flash of unstyled content (FOUC).

Expected behavior
I would like to see a working example or documentation on how to properly configure TanStack Router with CSS Modules and SSR.
The desired behavior is to have styles included in the server-rendered HTML, so there is no flash of unstyled content (FOUC).
Screenshots or Videos
No response
Platform

OS: [e.g. macOS, Windows, Linux]
Browser: [e.g. Chrome, Safari, Firefox]
Version: [e.g. 91.1]

Additional context
No response

In addition to this. on build, the CSS is not referenced by cloudflare-pages. I also ran a build using the node-server preset and it also has the same behavior.
app.config.ts
export default defineConfig({
  server: {
    preset: 'node-server',
    // preset: 'cloudflare-pages',
    // unenv: cloudflare,
  },
})

client.tsx
import<EMAIL_ADDRESS>import './client.css'

Having the same flash of unstyled content (FOUC) problem. Waiting for a Messiah.

This worked:

Add a '?url' to the css import:
import CSS from '../app.css?url'

Add this line to the Route object head:
links: [{ rel: 'stylesheet', href: CSS }]

Full code:
import {
   Outlet,
   ScrollRestoration,
   createRootRoute,
} from '@tanstack/react-router'
import { Meta, Scripts } from '@tanstack/start'
import type { ReactNode } from 'react'
import CSS from '../app.css?url'      // this

export const Route = createRootRoute({
   head: () => ({
      meta: [
         {
            charSet: 'utf-8',
         },
         {
            name: 'viewport',
            content: 'width=device-width, initial-scale=1',
         },
         {
            title: 'TanStack Start Starter',
         },
      ],
      links: [{ rel: 'stylesheet', href: CSS }]          // and this
   }),
   component: RootComponent,
})

function RootComponent() {
   return (
      <RootDocument>
         <Outlet />
      </RootDocument>
   )
}

function RootDocument({ children }: Readonly<{ children: ReactNode }>) {
   return (
      <html>
         <head>
            <Meta />
         </head>
         <body>
            {children}
            <ScrollRestoration />
            <Scripts />
         </body>
      </html>
   )
}

"@tanstack/start": "^1.91.3",

Thx @gioruu. I verified this works as well.

@roboncode are you sure, I cloned this guys repo and I can clearly see both his red and green squares loading without styling and then being hydrated giving the 'flicker' effect.
I am having the same error using pigment css

@gioruu your example works because you use url directly in the root. But it doesn't make sense, we need to have ability to write css and place it next to a component using CSS modules. Neither CSS modules neither import work in a component work properly.
It does work as expected in other frameworks like nextjs.

@SeanCassiere could you please reopen it? Not everyone use tailwind.

I agree with @nikolayemrikh

@j-mcfarlane, not sure about his repo but when i added the the ?url it worked for me and it started including it in my build

import { AppProvider } from '@shopify/polaris'
import POLARIS_CSS from '@shopify/polaris/build/esm/styles.css?url'
import enTranslations from<EMAIL_ADDRESS>import type { ReactNode } from 'react'
import CLIENT_CSS from '../client.css?url'
import { QueryProvider } from '../providers/QueryProvider'

export const Route = createRootRoute({
  head: () => ({
    meta: [
      {
        charSet: 'utf-8',
      },
      {
        name: 'viewport',
        content: 'width=device-width, initial-scale=1',
      },
      {
        title: 'TanStack Start Starter',
      },
    ],
    links: [
      { rel: 'stylesheet', href: CLIENT_CSS },
      { rel: 'stylesheet', href: POLARIS_CSS },
    ],
  }),
  component: RootComponent,
})

@j-mcfarlane, not sure about his repo but when i added the the ?url it worked for me and it started including it in my build
import { AppProvider } from '@shopify/polaris'
import POLARIS_CSS from '@shopify/polaris/build/esm/styles.css?url'
import enTranslations from<EMAIL_ADDRESS>import type { ReactNode } from 'react'
import CLIENT_CSS from '../client.css?url'
import { QueryProvider } from '../providers/QueryProvider'
export const Route = createRootRoute({
head: () => ({
meta: [
{
charSet: 'utf-8',
},
{
name: 'viewport',
content: 'width=device-width, initial-scale=1',
},
{
title: 'TanStack Start Starter',
},
],
links: [
{ rel: 'stylesheet', href: CLIENT_CSS },
{ rel: 'stylesheet', href: POLARIS_CSS },
],
}),
component: RootComponent,
})

That's because you're not using CSS Modules in your example ;)

I got a hydration error after running pnpm start following a build.
import tailwind from "~/styles/tailwind.css?url";

export const Route = createRootRoute({
  head: () => ({
    meta: [
      {
        charSet: "utf-8",
      },
      {
        name: "viewport",
        content: "width=device-width, initial-scale=1",
      },
      {
        title: "TanStack Start Starter",
      },
    ],
    links: [{ rel: "stylesheet", href: tailwind }],
  }),
  component: RootComponent,
});

"tailwindcss": "4.0.0-beta.8",
"@tanstack/react-router": "^1.92.6",
"@tanstack/start": "^1.92.6",
"react": "^19.0.0",
"react-dom": "^19.0.0",
"vinxi": "^0.5.1"


Add oxen-revision-id header to the GET file response

This adds the revision id in the response's header.
If the file is requested through a revision id, ie. /api/repos/lewazo/repo_1/file/e44f1df241b9e64a/file_1.csv, oxen-revision-id will equal to e44f1df241b9e64a.
If the file is requested through a branch name, ie. /api/repos/lewazo/repo_1/file/main/file_1.csv, oxen-revision-id will equal to main's HEAD commit id.

Tested end to end with hub changes


{Packaging} Pin telemetry version in setup.py

Description

With pip install --upgrade azure-cli to update existing azure-cli package, azure-cli-telemetry will not be updated as there is no version requirement for it. We should pin its version as the latest azure-cli does not work with previous azure-cli-telemetry versions.
Testing Guide

History Notes

[Component Name 1] BREAKING CHANGE: az command a: Make some customer-facing breaking change.
[Component Name 2] az command b: Add some customer-facing feature.

This checklist is used to make sure that common guidelines for a pull request are followed.

[ ] The PR title and description has followed the guideline in Submitting Pull Requests.

[ ] I adhere to the Command Guidelines.

Packaging


failed on fix schema when first coulmn is index

file_example_XLSX_10.xlsx
tried to run fix schema on the next file and it failed cause the first column is index (don't think it should be an issue or at least throw better exception cause the exception we get is "0"

3f4c70e1ab88550063c43f8af2ae1183b21c7619

Will be fixed in the next version: v1.1.20


getting node version from 'admin/chain/0x1' endpoint

Hello team.
Im working on a telegram bot to help me manage my node server, most of the data I get from my node is by the /admin/chain/0x1 endpoint.
I would like to know if its possible to add the current node version in the server in that endpoint or if there is another place where I can get that data.
Thanks!.

https://github.com/icon-project/goloop/blob/master/doc/goloop_admin_api.md#view-system

thanks!


Fix MODULES-1919: "bind" statements should be sorted by IP, not lexigraphically

Fix MODULES-1919

How does this behave when the bind parameter contains something other than IP addresses? See for example https://github.com/puppetlabs/puppetlabs-haproxy/blob/master/spec/defines/frontend_spec.rb#L196-L205
Also, why this change? Does order really matter when specifying bind options?

Why this change?
It is not just cosmetic. While debugging haproxy.cfg files we found the lexicographical sorting was making it difficult to spot errors that would otherwise be obvious.
How does this behave with non IPs?
It sorts them just fine, alphabetically. There are spec tests that show it works as one would hope.
Partitioning the list into things that look like IPs and others:
Luckily thanks to the designers of ASCII, the non-IPs sort to the top of the list. Therefore, the results are approximately the same without the additional coding.  For example, the test case you pointed to formats as:
listen apache
  bind fd@${FD_APP1}
  bind :443,:8443 ssl crt public.puppetlabs.com no-sslv3
  bind /var/run/ssl-frontend.sock user root mode 600 accept-proxy
  bind <IP_ADDRESS>:80
  bind <IP_ADDRESS>:8000-8010 ssl crt public.puppetlabs.com
  balance roundrobin
  option tcplog
  option ssl-hello-chk

What about IPv6?
Right now IPv6 will sort lexicographically since it doesn't include any periods in the address.   I'd like to improve this in the future. I think this is beyond my ruby skills and I'd appreciate help.  IPv6 support in this module is pretty lacking already.

I think that sounds good and is reasonable to implement, yes. So :+1: from me, whatever that's worth :)
I am wondering about the failing tests, though. Seems the main problem is Ruby 1.8.7, but https://travis-ci.org/puppetlabs/puppetlabs-haproxy/jobs/57502537 and https://travis-ci.org/puppetlabs/puppetlabs-haproxy/jobs/57502538 fail with a NameError and uninitialized constant RSpec::Support::Differ::Encoding while in https://travis-ci.org/puppetlabs/puppetlabs-haproxy/jobs/57502531 Ruby seems to think :443 ... should come before fd@${FD_APP1} (https://travis-ci.org/puppetlabs/puppetlabs-haproxy/jobs/57502531#L414). No idea what to make of this.

ping @hunner for some… enlightenment…

This was discussed briefly on the puppet-users mailing list and answered by the great jcbollinger: https://groups.google.com/forum/#!topic/puppet-users/9xPXkGW6Pk8
Quoting:

but it looks like the sort order you are trying to apply does not very effectively cover the space of keys it may be used to sort.  In particular, what order is supposed to be used when the bind_address does not start with a dotted-quad IP address?  Some order will fall out from your code, but there's plenty of room for implementation-defined behavior there.

He also provides an implementation for the sort_by block that looks good, but it requires ipaddr.

Thanks to @jcbollinger's better algorithm, it now passes all tests.  PTAL

@TomOnTime we will review this again in the thursday community meeting


Multiple copies of a single variant in the same Checkout/Order

This feature branch contains implementation for the split variant in the multiple checkout lines feature, this will allow dynamic prices to be used to their full extent.
Consider an example where a product can be engraved, and the price depends on the number of letters. A person can't order two such items without placing two separate orders (and paying for shipping twice).
General assumptions
Introduce the following concepts:

add forceNewLine flag to CheckoutLineInput and OrderLineCreateInput - this will allow force splitting the same variant into multiple lines by skipping the matching logic
add lineId parameter to CheckoutLinesUpdate mutation

extend the CheckoutLineUpdateInput with an optional lineId (allowing a particular line to be targeted)
reject checkoutLinesUpdate if variantId is passed and it matches more than one line
deprecate variantId parameter

API and logic changes
Inputs
CheckoutLineInput and OrderLineCreateInput

New forceNewLine flag added

input CheckoutLineInput {
  forceNewLine: Boolean = false
  quantity: Int!
  variantId: ID!
  price: PositiveDecimal
}

input OrderLineCreateInput {
  forceNewLine: Boolean = false
  quantity: Int!
  variantId: ID!
}

CheckoutLineUpdateInput

New optional lineId parameter added
Make variantId as optional and depreacted

input CheckoutLineUpdateInput {
  quantity: Int
  variantId: ID
  price: PositiveDecimal
  lineId: ID
}

Mutations
DraftOrderCreate and OrderLinesCreate

create a new line for line input with forceNewLine set to true

CheckoutCreate

create a new line for line input with forceNewLine set to true
combine checkout rows when:

same variants without custom price passed
same variants with the same custom price passed

CheckoutLinesAdd

create a new line when forceNewLine set to true
create a new line when new variant is added
create a new line when existing variant but with new custom price is added
update line when existing variant with the same custom price is added
update line when existing variant without a custom price is added

CheckoutLinesUpdate

uselineId to target particular line
allow to split line with quantity > 1 into multiple lines not needed
return error if variantId is passed and it matches more than one line

CheckoutLineDelete and CheckoutLinesDelete already support line ID as parameter so no changes needed.
CheckoutLinesUpdate, CheckoutLineDelete, CheckoutLinesDelete mutations can be called by App or Customer. At this moment we would like to block to make those actions via customer API key on lines when there is a custom price added or a single variant in multiple lines.
Additional things to do

adjust checkoutLimits to calculate if limit is exceeded when same variant occurs in multiple lines
for each unique checkout line, create a separate order line - orderCreateFromCheckout

Impact

[ ] New migrations
[x] New/Updated API fields or mutations
[x] Deprecated API fields or mutations
[ ] Removed API types, fields, or mutations
[x] Documentation needs to be updated

Pull Request Checklist

[ ] Privileged queries and mutations are guarded by proper permission checks
[ ] Database queries are optimized and the number of queries is constant
[ ] Database migration files are up to date
[ ] The changes are tested
[ ] GraphQL schema and type definitions are up to date
[ ] Changes are mentioned in the changelog

The draft of the new API looks good to me. One question about this point:

At this moment we would like to block to make those actions via customer API key on lines when there is a custom price added or a single variant in multiple lines.

I think we don't currently track which line uses custom prices and we can only guess that by comparing line and variant prices (correct me if I'm wrong). I'm wondering if it wouldn't be convenient to add a model field hasCustomPrice or similar to track this fact and make permission checks easier.

@maarcingebala on checkout line we have price_override field.

@SzymJ How:
input CheckoutLineUpdateInput {
  forceNewLine: Boolean = false
  quantity: Int
  variantId: ID
  price: PositiveDecimal
  lineId: ID
}

will work?
forceNewLine means that we will create a new, separate CheckoutLine. In that case, shouldn't we just call mutation with CheckoutLineInput?  Setting forceNewLine to True in CheckoutLineUpdateInput, means that we create a new line, right? In that case (maybe I am missing something) but we will have two mutations that do the same (checkout-create-line and checkout-update-line)

@SzymJ How:
input CheckoutLineUpdateInput {
  forceNewLine: Boolean = false
  quantity: Int
  variantId: ID
  price: PositiveDecimal
  lineId: ID
}

will work?
forceNewLine means that we will create a new, separate CheckoutLine. In that case, shouldn't we just call mutation with CheckoutLineInput? Setting forceNewLine to True in CheckoutLineUpdateInput, means that we create a new line, right? In that case (maybe I am missing something) but we will have two mutations that do the same (checkout-create-line and checkout-update-line)

I was thinking that it would be nice to allow split already created line with the quantity  > 1, but I'm not sure if there is a use case for that. I not we can remove its flag from update input.

We shouldn't forget about validating LineUpdate and LineDelete mutation required that one of the params lineId and variantId.

IMO we should describe OrderLienes CRUD in Mutations section.

@SzymJ looks good, but make sure that you checked your code with:

voucher for entire order
voucher for specific products
AvataxPlugin

I think @eCzerniak was testing those cases


Support for OAuth2 for GMail Relay?

msmtp now supports OAUTH2 for Gmail
See here
How is this possible in this docker setup?
I would like to avoid to rebuild everything to make it working.
A manual/documentation would be nice for this feature.

Maybe better to use google applications passwords ? see here


fixed overfitting lesson link broken issue

the link to overfitting lesson is broken (below screenshot). root cause is this commit merged overfitting content to framework lesson's readme.
the PR fixed the link to direct the navigation to the overfitting section in framework lesson.

okay i'll look into it
---------- Forwarded message ---------
From: Pikachú @.>
Date: Wed, May 29, 2024 at 8:49 PM
Subject: Re: [microsoft/AI-For-Beginners] fixed overfitting lesson link
broken issue (PR #287)
To: microsoft/AI-For-Beginners @.>
Cc: Subscribed @.***>
Merged #287 https://github.com/microsoft/AI-For-Beginners/pull/287 into
main.
—
Reply to this email directly, view it on GitHub
https://github.com/microsoft/AI-For-Beginners/pull/287#event-12973616813,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/A6JFXCO7OJ3QY7UTXSX5N4DZEXWZTAVCNFSM6AAAAABBNM2XYOVHI2DSMVQWIX3LMV45UABCJFZXG5LFIV3GK3TUJZXXI2LGNFRWC5DJN5XDWMJSHE3TGNRRGY4DCMY
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>


Switch to maps

I would say, it needs to be backwards-compatible

That's a good point. I meant to make this against my own fork :/
At the moment pgapp points to the devel branch for epgsql. I ran into the examples for this repo breaking when I went to use this.
I'll see if I can get some time to make this backwards compatible and update the examples as well.

@seriyps updated, please let me know what you think!

It's fine. Another approach would be to just convert proplist to map and use map after that, like it was done in epgsql:
https://github.com/epgsql/epgsql/blob/5304480f24789d370fb637dcc649d12688f525ff/src/epgsql.erl#L155
https://github.com/epgsql/epgsql/blob/5304480f24789d370fb637dcc649d12688f525ff/src/epgsql.erl#L455-L459
But I'm ok with your solution as well. Maybe @davidw have smth to add?


"Unit tests" for constraint and variable generation - advice and a feature request?

From a user perspective, what suggestions do you have regarding writing unit tests for models implemented in linopy?  Are there any plans to improve the opportunities for comparing constraint and variable objects with pre-generated fixtures?
One key feature I'm looking for in a modelling framework is being able to test individual components and test the integration of these components into a complete optimisation model.  I think this would make the process of developing and maintaining modelling frameworks considerably more robust and efficient. The task is particularly challenging because of the intertwined nature of constraints and variables in optimisation models. It is very difficult to effectively separate individual components. In practice, this means that testing is only possible with a complete and often complex model. Debugging can be tortuous because errors in constraint definitions, masks or conditional operators etc. do not manifest in an obvious way.  There are degrees of freedom outside the control of the model developer - for example, solutions to an ill-posed optimisation problem can differ between solvers, be caused by floating point errors and solver tolerances etc.
From a readability perspective, it would be great to use in an assertion the printout you get returned from the constraint construction e.g.
[SIMPLICITY, HEATER, 2010]: 1.0 AccumulatedNewCapacity[SIMPLICITY, HEATER, 2010] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2010]
However, this is a little brittle, and could result in tests failing if e.g. coefficient precision was updated, or the ordering of terms in the constraint were changed.  From a mathematical perspective, it doesn't matter if the order of the terms in the constraint as long as they are all present and have the correct sign and coefficient.
Another option is to manually create the linopy.Constraint using a completely separate linopy.Model instance, and then assert that the actual and expected are equal.  Note that for many linopy objects __equal__ is often overridden and doesn't allow comparison.
It would also be good to think about how to use Mock effectively (e.g. to avoid creating variables when testing a constraint).
Example
Here's my new constraint, encapsulated in a function I can call at run time. Now, I would like to write a unit test, so that I can check that the constraint is correctly generated under different conditions.  I might like to check corner cases, such as if there is a technology with an OperationalLife of 0 or write a regression test to ensure that behaviour doesn't change as dependencies are updated.
def capacity_adequacy_a(ds, m):
    """Add capacity adequacy constraint to the model

    Arguments
    ---------
    ds: xarray.Dataset
        The parameters dataset
    m: linopy.Model
        A linopy model

    Returns
    -------
    linopy.Model
    """
    new_cap = m['NewCapacity'].rename(YEAR="BUILDYEAR")
    mask = (ds.YEAR - new_cap.data.BUILDYEAR >= 0) & (ds.YEAR - new_cap.data.BUILDYEAR < ds.OperationalLife)
    con = m['AccumulatedNewCapacity'] - new_cap.where(mask).sum("BUILDYEAR") == 0
    m.add_constraints(con, name='CAa1_TotalNewCapacity')
    return m

And here are some options I have explored for testing:
Fixtures
Some fixtures to set up the parameters needed to test the constraint creation:
import pytest
import numpy as np
import xarray as xr

@pytest.fixture()
def operational_life():
    data = np.empty((1, 1))
    data.fill(1)

    coords = {
        'REGION': ['SIMPLICITY'],
        'TECHNOLOGY': ['HEATER'],
    }
    dims = ['REGION', 'TECHNOLOGY']
    return xr.DataArray(data, coords, dims, name='OperationalLife')

@pytest.fixture()
def coords():
    return {
        '_REGION': ['SIMPLICITY'],
        'REGION': ['SIMPLICITY'],
        'TECHNOLOGY': ['HEATER'],
        'TIMESLICE': ['1'],
        'MODE_OF_OPERATION': [1],
        'FUEL': ['ELC', 'HEAT'],
        'YEAR': [2010]
        }

Tests
A now the test itself:

import pytest
from constraints import add_demand_constraints, capacity_adequacy_a
import xarray as xr
import numpy as np
from linopy import Model

class TestCapacityAdequacyA:

    @pytest.fixture()
    def dataset(self, coords, operational_life):
        data_vars = {
            'OperationalLife': operational_life
        }

        # Dataset containing all the parameters read in from an OSeMOSYS file
        ds = xr.Dataset(data_vars=data_vars, coords=coords)

        return ds

    def test_capacity_adequacy(self, dataset):
        """Vanilla test with one technology with an operational life of 1 and 1 year
        """

        model = Model(force_dim_names=True)

        RTeY = [dataset.coords['REGION'], dataset.coords['TECHNOLOGY'], dataset.coords['YEAR']]

        model.add_variables(lower=0, upper=np.inf, coords=RTeY, name='NewCapacity', integer=False)
        model.add_variables(lower=0, upper=np.inf, coords=RTeY, name='AccumulatedNewCapacity', integer=False)

        actual = capacity_adequacy_a(dataset, model).constraints

        assert model.variables.get_name_by_label(0) == 'NewCapacity'
        assert model.variables.get_name_by_label(1) == 'AccumulatedNewCapacity'

        # This is not very readable!
        assert actual.labels.CAa1_TotalNewCapacity.shape == (1, 1, 1)
        assert (actual['CAa1_TotalNewCapacity'].vars.values == [[[[1, 0]]]]).all()
        assert (actual['CAa1_TotalNewCapacity'].coeffs.values == [[[[1, -1]]]]).all()

    def test_capacity_adequacy_longer(self, dataset):
        """Vanilla test with one technology with operational life of 3 and 5 years
        """

        dataset = dataset

        dataset['YEAR'] = range(2010, 2015)
        dataset['OperationalLife'][0, 0] = 3

        model = Model(force_dim_names=True)

        RTeY = [dataset.coords['REGION'], dataset.coords['TECHNOLOGY'], dataset.coords['YEAR']]

        model.add_variables(lower=0, upper=np.inf, coords=RTeY, name='NewCapacity', integer=False)
        model.add_variables(lower=0, upper=np.inf, coords=RTeY, name='AccumulatedNewCapacity', integer=False)

        actual = capacity_adequacy_a(dataset, model).constraints

        assert model.nvars == 10

        # A utility function to check the number of variables of each type would be handy
        for var in range(0, 5):
            assert model.variables.get_name_by_label(var) == 'NewCapacity'
        for var in range(5, 10):
            assert model.variables.get_name_by_label(var) == 'AccumulatedNewCapacity'

        # This is fragile but the most readable
        expected = """LinearExpression (REGION: 1, TECHNOLOGY: 1, YEAR: 5):
-----------------------------------------------------
[SIMPLICITY, HEATER, 2010]: 1.0 AccumulatedNewCapacity[SIMPLICITY, HEATER, 2010] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2010]
[SIMPLICITY, HEATER, 2011]: 1.0 AccumulatedNewCapacity[SIMPLICITY, HEATER, 2011] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2010] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2011]
[SIMPLICITY, HEATER, 2012]: 1.0 AccumulatedNewCapacity[SIMPLICITY, HEATER, 2012] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2010] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2011] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2012]
[SIMPLICITY, HEATER, 2013]: 1.0 AccumulatedNewCapacity[SIMPLICITY, HEATER, 2013] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2011] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2012] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2013]
[SIMPLICITY, HEATER, 2014]: 1.0 AccumulatedNewCapacity[SIMPLICITY, HEATER, 2014] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2012] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2013] - 1.0 NewCapacity[SIMPLICITY, HEATER, 2014]"""
        assert str(actual['CAa1_TotalNewCapacity'].lhs) == expected

Hey @willu47! This is a good point and can indeed be a bit fiddly. As you implied, a separation of the unit tests in

testing the data model of constraints via .vars/.coeffs
testing the representation of constraint via str

is sensible. I would also prefer the first option as it yields more stable results.  Another form of it could be achieved by manually reconstructing single constraints, like

m = Model()
coords=[range(10)]
x = m.add_variables(coords=coords, name="x")
y = m.add_variables(coords=coords, name="y")
mask = np.array([True, True, True, True, True, False, False, False, False, False])
con = m.add_constraints(x - y.shift(dim_0=1) >= 0, mask=mask)

# check the constraint at `0`
assert all(con.vars[0] == (x[0].label, -1)) # -1 is the mask value from the shift

# check the constraint at `1`
assert all(con.vars[1] == (x[1].label, y[0].label))

# checkt the constraint at `9`
# the following would be intuitive, but is not the case
assert all(con.vars[9] == -1)
# as the mask is applied to the labels only, probably we should change this

# instead it is
assert all(con.vars[9] == (x[9].label, y[8].label))
# and
assert con.labels[9] == -1

Could that improve the tests?

Hi @FabianHofmann. Many thanks for your patience with my long and wordy issues! I realise my original question was unclear - I was trying to work out exactly what I want to ask and I hope the following is easier to follow now.
I think there are two main use cases for writing tests. The first is for the development of linopy itself, and for linopy developers I think the option you present is acceptable. However, the second set of users of tests I perceive are users of linopy, like myself, who want to test that their model is correctly generated. For me, the readability of the tests is paramount - I want something as close to the model formulation as possible.  For example, when I create a constraint, I see this pretty printed readout:
Constraint `CAa1_TotalNewCapacity` (REGION: 1, YEAR: 1, TECHNOLOGY: 2)
----------------------------------------------------------------------
[BB, 2016, gas_import]: 1.0 AccumulatedNewCapacity[BB, gas_import, 2016] - 1.0 NewCapacity[BB, gas_import, 2016] =  0
[BB, 2016, gas_plant]:  1.0 AccumulatedNewCapacity[BB, gas_plant, 2016] - 1.0 NewCapacity[BB, gas_plant, 2016]   =  0

What I would like is to be able to test the constraint generation like so:
actual = m.add__my_constraint(data, model)  # Function which adds the constraint to the model

assert actual['BB', '2016', 'gas_import'] == m.variables['AccumulatedNewCapacity']['BB', 'gas_import', 2016] - m.variables['NewCapacity']['BB', 'gas_import', 2016] == 0

assert actual['BB', '2016', 'gas_plant'] == m.variables['AccumulatedNewCapacity']['BB', 'gas_plant', 2016] - m.variables['NewCapacity']['BB', 'gas_plant', 2016] == 0

There are a few roadblocks I perceive at the moment to this exact syntax. The first is that == is over-ridden, but this could be solved with the addition of a testing.assert_constraint_equal helper function. The second is that Constraint objects are not currently subscriptable. Could __getter__ access be provided using the labels of the coordinates as m.constraints['CAa1_TotalNewCapacity'].labels[0,0,1] is not as readable?

Hey @willu47
I added some testing functions. Now the following syntax functionality is supported:
import pandas as pd
import linopy
from linopy.testing import assert_varequal, assert_linequal, assert_conequal

m = linopy.Model()
x = m.add_variables(coords=[pd.RangeIndex(10, name="first")], name="x")
assert_varequal(x, m.variables.x)
# or
assert_varequal(x, m.variables["x"])

y = m.add_variables(coords=[pd.RangeIndex(10, name="first")], name="y")

expr = 2 * x + y
assert_linequal(expr, 2 * x + y)

con = m.add_constraints(expr >= 3, name='con')

assert_conequal(con, m.constraints.con)

# con object gets labels when adding to model, cannot compare the original
# anonymous constraint with assigned constraint but we can do this
assert_conequal(expr >= 3, con.lhs >= con.rhs)

Hope that helps! Feel free to close the issue or leave open if there are more things to consider.

@FabianHofmann - many thanks for this. I'll try these new testing functions out and provide some feedback (if any) here, so I'll leave the issue open for now.


Handle some of breaking none cases

This PR handles some case where either a None value or an empty input table would cause the code to break.

@siddharth-krishna I had to modify the benchmarks to make this one pass, but I can see that some of the GAMS runs are failing. I'll merge after fixing them.


Accelerating Faiss retrieval using FastScan in Faiss

Thank you for the amazing software. I am particularly interested in the interesting applications of vector search. I am still in the process of setting up, but I plan to try running it soon.
While reading the source code, I noticed a point of concern in the faiss part and created an issue.
Currently, IVF512 is used in retrieval.
While I think this is simple and effective as a baseline on the GPU, I believe there are better index factory options when running on the CPU.
https://github.com/liujing04/Retrieval-based-Voice-Conversion-WebUI/blob/6c7c1d933ffe2217edc74afadff7eec0078d6d16/infer/train-index.py#L19
This can be done using the FastScan method, by simply changing the index factory from "IVF512,Flat" to "IVF512PQ128x4fsr,Rflat" (512 is the original IVF's parameter, PQ128 indicates half of 256 dimention).
Since I haven't been able to run RVC yet, I'm not sure if this parameter is effective, but in most cases, it works effectively on both the CPU and GPU.
Once I run it and find it effective, I will report back in this issue.

I would like to see the acceleration if this modification doesn't change the behavior of index-training.

Is there a benchmark to compare the two index_factory strings? Speed and recall.

@liujing04

Is there a benchmark to compare the two index_factory strings? Speed and recall.
This is official benchmark
https://github.com/facebookresearch/faiss/wiki/Indexing-1M-vectors#4-bit-pq-comparison-with-scann

and this is famous benchmark
http://ann-benchmarks.com/
While ScaNN outperforms other methods in cost performance for approximate nearest neighbor search in embeddings, FastScan demonstrates equivalent or even better performance compared to ScaNN.

Part of the code was wrong. very sorry.
I experimented with three types of indexes on the GUI.
I measured the time to convert to 2min audio data.
The feature size used in the experiment is (535514, 256).

default
added_IVF13731_Flat_nprobe_17.index was created and it takes 2.2 sec to convert.

BruteForce (for comparision)

index = faiss.index_factory(256, "Flat")
index.train(big_npy)
faiss.write_index(index, 'trained_Flat_src_feat.index')
index.add(big_npy)
faiss.write_index(index,"added_Flat_src_feat.index")

added_Flat_src_feat.index was created and it takes 5.4 sec to convert.

FastScan

index = faiss.index_factory(256, "IVF512,PQ128x4fs,RFlat")
print("training")
index.train(big_npy)
faiss.write_index(index, 'trained_IVF512_fastscan_src_feat.index')
print("adding")
index.add(big_npy)
faiss.write_index(index,"added_IVF512_fastscan_src_feat.index")

added_IVF512_fastscan_src_feat.index was created and it takes 2.0 sec to convert.
Although it is slight, performance improvement was seen compared to the default setting.

The improvement seems great. Maybe you can open a draft PR to show your modification and I will test it later.

@RVC-Boss @fumiama
Now that the code has been cleaned up, I think it's time to improve search with faiss.
I would like to create a PR that commits in the following order. Please merge up to the necessary functions.

Extract train_index into a function and share it
Change default index factory to parameters recommended by faiss
Create a parameter that takes the weighted average of top-k inferences from top-1 inferences.
Enable index compression by kmeans.

@RVC-Boss @fumiama Now that the code has been cleaned up, I think it's time to improve search with faiss.
I would like to create a PR that commits in the following order. Please merge up to the necessary functions.

Extract train_index into a function and share it
Change default index factory to parameters recommended by faiss
Create a parameter that takes the weighted average of top-k inferences from top-1 inferences.
Enable index compression by kmeans.

@nadare881 Create a parameter that takes the weighted average of top-k inferences from top-1 inferences:
Does this option always achieve better results? Perhaps this option should be frozen (always open it) and not open to users?
Change default index factory to parameters recommended by faiss:
Waiting for your latest report and recommended index string~

@RVC-Boss

Does this option always achieve better results? Perhaps this option should be frozen (always open it) and not open to users?
The option to get top-k smoothes the audio and is better in some cases.

Waiting for your latest report and recommended index string~
I have created a doc on parameter tuning for faiss. Please refer here.

https://github.com/RVC-Project/Retrieval-based-Voice-Conversion-WebUI/blob/b05487b6cacc17578541f8b5096bd2424ff3b0dd/docs/faiss_tips_en.md


Incomplete auth system urls

in the base.html template, there is this code:
{% if request.user.is_authenticated %}

  {% trans "My Profile" %}

  {% trans "Sign Out" %}

{% else %}

  {% trans "Sign Up" %}

  {% trans "Sign In" %}

{% endif %}

but 'account_signup', 'account_login', and 'account_logout' are not named url's defined in any urls.py in the project. is this intentional and the user is expected to provide these routes/functions themselves? seems like there should at least be placeholders for them.

@chrickso , ain't those are provided by django-allaith?

@chrickso , see allauth/account/urls.py

@webyneter thanks.

Excellent question @chrickso. Added a383fa23788e976a6d9f30a2425cb33394042ce6 to clarify things.
Thanks @webyneter for the answer. 😄

@pydanny, always welcome :)


Syntactic sugar for ADTs... Don't close! Listen to me for a moment.

Let's start with the fact: Everybody loves ADTs .
We already have product types, we are just missing a nicer way to create tagged sum types. We are also missing a nicer way pattern match tagged sum types.
enum is the most obvious choice to implement this feature on top because it already breaks the "Gotta stay similar to JS" rule and Rustlang also uses it to achieve ADTs.
I know that the aforementioned rule is very serious for TS core team; but if there's anything we want to bend the rules for, it must be for ADTs, right?
Actually, the code can be converted in such a way that it has no runtime component.

e.g.
enum X<Q> {
  A(t: T);
  B(t: T, u: U);
}

match(X.A(foo)) {
  case A(t): t;
  case B(t, u): t;
  default: bar;
}

would be transformed to the following, potentially at the syntax level, just to make it a syntactic sugar and nothing else:
type X<Q> = { tag: 'A', value: { t: T } | { tag: 'B', value: { t: T; u: U } };

const X = {
  A: <Q>(t: T): X<Q> => ({ tag: 'A' as 'A', value: { t } }),
  B: <Q>(t: T, u: U): X<Q> => ({ tag: 'B' as 'B', value: { t, u } }),
};

(() => {
  const val = X.A(foo);
  switch(val.tag) {
    case 'A': return val.value.t;
    case 'B': return val.value.t;
    default: return bar;
  }
})();

Those who opt-in for ADTs would surely welcome little complexity this transformation introduces.

https://github.com/Microsoft/TypeScript/wiki/TypeScript-Design-Goals

@MartinJohns It would be great if you could also specify which goal/non-goal this contradicts with.

It looks like you want to follow https://github.com/tc39/proposal-pattern-matching
We don't want to add new runtime syntax to JS ourselves (especially something this invasive) and I don't know how to be any clearer about that.

@RyanCavanaugh Let's ignore match for a moment.
How about extending enum for tagged unions? It won't be solved by any JS proposals and it would be extending an already existing mechanism. Or is that invasive too?

See also #36336, #42497
There are very compact ways to write tagged unions today if that's the intent:
interface Taggo {
    "alpha": {
        a: number,
        b: string
    };
    "beta": {
        c: boolean;
    };
    "gamma": {
        d: object;
    };
}

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

type M = ToADT<Taggo>;
declare const m: ToADT<Taggo>;
switch(m.kind) {
    case "alpha":
        m.a;
        break;
    case "gamma":
        m.d;
}

That doesn't work with a generic Taggo though.


Feature/add help html link

Description
added help attribute
Fixes: # (issue)
Type of change

[ ] Bug fix (non-breaking change which fixes an issue)
[ ] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] This change requires a documentation update

How Has This Been Tested?

Test Configuration:
Aditional Notes

Checklist

[ ] My code follows the Coding Conventions
[ ] I have performed a self-review of my code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[ ] My changes generate no new warnings
[ ] I have added tests that prove my fix is effective or that my feature works
[ ] New and existing unit tests pass locally with my changes
[ ] Any dependent changes have been merged and published in downstream modules

Needs updating to latest changes from develop. Will test as soon as this is done

Please provide a proper description with links to other interdependencies.

p!

/azp run

:tada: This PR is included in version 1.6.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


RHEL support in Docker with Mono

Hi,
I have an asp.net RC1 app that is used in RHEL 7.1 Docker image using DNX with Mono runtime instead of .NET Core. I added dependency to "RdKafka": "0.9.1-ci-99". I can run the app fine in Windows. However when I publish it and package it in Docker and run it with DNX Mono I get the following stacktrace
Application startup exception: System.Reflection.TargetInvocationException: Exception has been thrown by the target of an invocation. ---> System.TypeInitializationException: The type initializer for 'RdKafka.Internal.LibRdKafka' threw an exception. ---> System.DllNotFoundException: librdkafka
  at (wrapper managed-to-native) RdKafka.Internal.LibRdKafka+NativeMethods:rd_kafka_version ()
  at RdKafka.Internal.LibRdKafka.version () <0x410b05c0 + 0x00022> in <filename unknown>:0
  at RdKafka.Internal.LibRdKafka..cctor () <0x410acf60 + 0x03073> in <filename unknown>:0
  --- End of inner exception stack trace ---
  at RdKafka.Internal.SafeConfigHandle.Create () <0x410ac810 + 0x0000b> in <filename unknown>:0
  at RdKafka.Config..ctor () <0x410ac7a0 + 0x0000f> in <filename unknown>:0
  at RdKafka.Producer..ctor (RdKafka.Config config, System.String brokerList) <0x410ac680 + 0x00057> in <filename unknown>:0
  at RdKafka.Producer..ctor (System.String brokerList) <0x410ac5d0 + 0x0001b> in <filename unknown>:0
  at SampleApp.Startup.ConfigureKafka (IServiceCollection services) <0x410ac2b0 + 0x00247> in <filename unknown>:0
  at SampleApp.Startup.ConfigureServices (IServiceCollection services) <0x41031240 + 0x001cb> in <filename unknown>:0
  at (wrapper managed-to-native) System.Reflection.MonoMethod:InternalInvoke (System.Reflection.MonoMethod,object,object[],System.Exception&)
  at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) <0x7f8e42778940 + 0x000a3> in <filename unknown>:0
  --- End of inner exception stack trace ---
  at System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) <0x7f8e42778940 + 0x000f1> in <filename unknown>:0
  at System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) <0x7f8e425aff00 + 0x0002a> in <filename unknown>:0
  at Microsoft.AspNet.Hosting.Startup.ConfigureServicesBuilder.Invoke (System.Object instance, IServiceCollection exportServices) <0x41031000 + 0x000ad> in <filename unknown>:0
  at Microsoft.AspNet.Hosting.Startup.ConfigureServicesBuilder+<>c__DisplayClass4_0.<Build>b__0 (IServiceCollection services) <0x41030fb0 + 0x00023> in <filename unknown>:0
  at Microsoft.AspNet.Hosting.Internal.HostingEngine.EnsureApplicationServices () <0x40f8d420 + 0x0003e> in <filename unknown>:0
  at Microsoft.AspNet.Hosting.Internal.HostingEngine.BuildApplication () <0x40f8cdb0 + 0x0005b> in <filename unknown>:0

I'm not that clear on how C# handles native packages, but I can see that in my published output librdkafka.so in packages/RdKafka/0.9.1-ci-99/runtimes/linux-x64/native Should that be enough to make Mono pick it up? Or is it possible this native package is for Debian based systems?
Trying to figure out if I'm screwing up my setup or if it's not a supported environment.

Yes, RHEL 7 is supported since a few days ago! Give RdKafka 0.9.1-ci-111 a try. The old linux-x64 package was compiled on Ubuntu 14.04 and was referencing the wrong libsasl on RHEL.
I think you're getting 0.9.1-ci-99 due to silly nuget sorting, will fix that by removing the old packages from nuget.

I must have missed the newer version when I was adding the reference.
I tried 0.9.1-ci-111 and I got the same error of librdkafka not found. So then I entered the container and moved the librdkafka.so file from packages/RdKafka/0.9.1-ci-99/runtimes/rhel-x64/native to under /usr/lib64 and restarted the process inside the container and it worked. I was able to produce and consume messages. Note when I did that in the previous package it didn't work.
I'm not that quiet sure how DNX handles detection of runtime in Linux. I tried changing around the native folder name, or messing around with DNX_RUNTIME_ID environment variable but nothing seemed to make it detect the native dependency. I will try to give it few more tries, but I figure maybe I'm missing something or I should wait till RC2 to see if they handle this better.
In the meantime I'm fine with just adding a step in my Dockerfile to make sure librdkafka is under /usr/lib4 since it saves me time from having to build it.
Thanks.

Great, good to hear you got it to work! I think the previous one did not work because it could not find dependencies of librdkafka.so, you can check by running ldd librdkafka.so.
Given that RC2 should be coming out next week I think it's probably not worth digging around too much in RC1. With dotnet publish you should be getting a bin folder with all the native dependencies in it.

Had a chance to use RC2 and and looked at output of dotnet publish and yeah it is simpler than RC1.
Thanks for the help.


Fix container img url

Fixes

https://issues.redhat.com/browse/RHTAPBUGS-141
Description

fix https:// append
Type of change

[ ] Feature
[x] Bugfix
[ ] Code style update (formatting, renaming)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] Documentation content changes
[ ] Other (please describe):

Screen shots / Gifs for design review

How to test or reproduce?

Browser conformance:

[x] Chrome
[ ] Firefox
[ ] Safari
[ ] Edge

/lgtm
/approve


Support Conda as a dependabot ecosystem

It'd be great to allow the support of conda environment yaml files similar to the requirement.txt support for pip.
There are a few tickets I've found for this but each points me to the new-ecosystem projects and I can't see an open ticket for this issue.
Previous tickets:
https://github.com/dependabot/dependabot-core/issues/1249
https://github.com/dependabot/dependabot-core/issues/2227

Thanks for opening this issue @adamsuk, I'm going to close this out in favour of https://github.com/dependabot/dependabot-core/issues/2227 as that's the issue we are tracking for Conda support in general.
Apologies for the lack of movement on this, as discussed in our Contributing guidelines we've paused on accepting new ecosystems in the last year to focus on some other priorities.
We are hopeful to start addressing extensibility in the new year in order to make it easier to add and support more ecosystems.

@brrygrdn thanks for taking the time to reply. I wasn't sure if the other tickets were still active but that makes sense to me. Can't wait to give it a whirl when it's available!


Correcting example from namespaces-walkthrough task

https://k8s.io/docs/tasks/administer-cluster/namespaces-walkthrough/ page creates snowflake deployment with run command. But as the run command is deprecated, the same deployment is now created using deployment manifest and apply command.

Deploy preview page: https://deploy-preview-19294--kubernetes-io-master-staging.netlify.com/docs/tasks/administer-cluster/namespaces-walkthrough/

/lgtm
/approve


Change the #\Bell character to #\Bel

In recent versions of SBCL (>=1.2.2), the character #\Bell produces a unicode bell character and does not ring the terminal bell, which is triggered by #\Bel.

Merged, thanks!


Add Walker and Morgan

https://github.com/RamonGilabert/Walker
https://github.com/RamonGilabert/Morgan
Hope you like it! :)

Other stuff got edited too for some reason. :heart:

Hey @RamonGilabert, what's the difference between the two libraries? The READMEs are really good, but it didn't explain much

Hey @lfarah! :) While the first library, Walker, is an animation engine that provides you with a sugared way to do animations, the second library, Morgan, is a work in progress with a set of different animations.
We could say that Walker is the engine where Morgan is just a set of predefined animations.

@RamonGilabert awesome! Really well done. Congrats. :smile:

This message was created automatically by mail delivery software.
A message that you sent could not be delivered to one or more of its
recipients. This is a temporary error. The following address(es) deferred:
<EMAIL_ADDRESS>Domain joe-jackson.net has exceeded the max emails per hour (111/100 (111%)) allowed.  Message will be reattempted later
------- This is a copy of the message, including all the headers. ------
Received: from github-smtp2-ext4.iad.github.net ([<IP_ADDRESS>]:33039 helo=github-smtp2a-ext-cp1-prd.iad.github.net)
by rs5.websitehostserver.net with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256)
(Exim 4.86_1)
(envelope-from<EMAIL_ADDRESS>id 1afmMT-001xT3-QP
for<EMAIL_ADDRESS>Tue, 15 Mar 2016 06:38:01 -0400
Date: Mon, 14 Mar 2016 13:29:23 -0700
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=github.com;
s=pf2014; t=1457987363;
bh=lVP4+HmeW/Krot6+ATPd2y229fAX41qlDpQBIgyT4l0=;
h=From:Reply-To:To:In-Reply-To:References:Subject:List-ID:
List-Archive:List-Post:List-Unsubscribe:From;
b=NaRDsVMvnBfwcfrE7+jF8isfT5eOonFt3vRFcwrTAhuv+YokqJJ5feop3kKY3bhq4
pxfm9Tp0WB7h8NHweBfxZxRUnYGmFwJ87NdRTLKW7qnGYb+RToTB0E9UifFyqHkeAI
Z8amDe0kyktmkFd74MYN2cpu7MSJwgrg3PjjAncI=
From: Lucas Farah<EMAIL_ADDRESS>Reply-To: vsouza/awesome-ios<EMAIL_ADDRESS>To: vsouza/awesome-ios<EMAIL_ADDRESS>Message-ID<EMAIL_ADDRESS>In-Reply-To<EMAIL_ADDRESS>References<EMAIL_ADDRESS>Subject: Re: [awesome-ios] Add Walker and Morgan (#686)
Mime-Version: 1.0
Content-Type: multipart/alternative;
boundary="--==_mimepart_56e71f23c4348_5ea3fa872e2d2b88075df";
charset=UTF-8
Content-Transfer-Encoding: 7bit
Precedence: list
X-GitHub-Sender: lfarah
X-GitHub-Recipient: jcj52436999
List-ID: vsouza/awesome-ios <awesome-ios.vsouza.github.com>
List-Archive: https://github.com/vsouza/awesome-ios
List-Post<EMAIL_ADDRESS>List-Unsubscribe<EMAIL_ADDRESS>https://github.com/notifications/unsubscribe/AA-U97NzcMlRQvte6E4MubpVbgZNPTqHks5ptcUjgaJpZM4Hv4eN
X-Auto-Response-Suppress: All
X-GitHub-Recipient-Address<EMAIL_ADDRESS>----==_mimepart_56e71f23c4348_5ea3fa872e2d2b88075df
Content-Type: text/plain;
charset=UTF-8
Content-Transfer-Encoding: 7bit
@RamonGilabert awesome! Really well done. Congrats. :smile:

Reply to this email directly or view it on GitHub:
https://github.com/vsouza/awesome-ios/pull/686#issuecomment-196508479
----==_mimepart_56e71f23c4348_5ea3fa872e2d2b88075df
Content-Type: text/html;
charset=UTF-8
Content-Transfer-Encoding: 7bit
@RamonGilabert awesome! Really well done. Congrats.
—Reply to this email directly or view it on GitHub.

----==_mimepart_56e71f23c4348_5ea3fa872e2d2b88075df--

This message was created automatically by mail delivery software.
A message that you sent could not be delivered to one or more of its
recipients. This is a temporary error. The following address(es) deferred:
<EMAIL_ADDRESS>Domain joe-jackson.net has exceeded the max emails per hour (113/100 (112%)) allowed.  Message will be reattempted later
------- This is a copy of the message, including all the headers. ------
Received: from github-smtp2-ext1.iad.github.net ([<IP_ADDRESS>]:34205 helo=github-smtp2a-ext-cp1-prd.iad.github.net)
by rs5.websitehostserver.net with esmtps (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256)
(Exim 4.86_1)
(envelope-from<EMAIL_ADDRESS>id 1afmMd-001xYL-Tg
for<EMAIL_ADDRESS>Tue, 15 Mar 2016 06:38:11 -0400
Date: Mon, 14 Mar 2016 13:29:27 -0700
DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=github.com;
s=pf2014; t=1457987367;
bh=OWqHcba3T7+D+ODQH2LIHBmYLVfAouWg+jWeMq76YIE=;
h=From:Reply-To:To:In-Reply-To:References:Subject:List-ID:
List-Archive:List-Post:List-Unsubscribe:From;
b=oDKaj3H39AOonsk9XVvWz2CCJDpRDY74Q0OOxsHGbK3BiQixOBk5QxmHqbUPH1Vep
CtViaL0S+eub8lS4flLIoXLFMDQB714H+zC0mHwGbR1KV8OtbTLV9Sv04RhGNwTezT
0GBR4021R9NC98z2HRd3RUKW3Af3IvHl69HEPJHc=
From: Lucas Farah<EMAIL_ADDRESS>Reply-To: vsouza/awesome-ios<EMAIL_ADDRESS>To: vsouza/awesome-ios<EMAIL_ADDRESS>Message-ID<EMAIL_ADDRESS>In-Reply-To<EMAIL_ADDRESS>References<EMAIL_ADDRESS>Subject: Re: [awesome-ios] Add Walker and Morgan (#686)
Mime-Version: 1.0
Content-Type: multipart/alternative;
boundary="--==_mimepart_56e71f27992ea_bd93fe7fd5392b86523cf";
charset=UTF-8
Content-Transfer-Encoding: 7bit
Precedence: list
X-GitHub-Sender: lfarah
X-GitHub-Recipient: jcj52436999
List-ID: vsouza/awesome-ios <awesome-ios.vsouza.github.com>
List-Archive: https://github.com/vsouza/awesome-ios
List-Post<EMAIL_ADDRESS>List-Unsubscribe<EMAIL_ADDRESS>https://github.com/notifications/unsubscribe/AA-U92h2E2DkDIYuDOvj7CdMqdzxMOnYks5ptcUngaJpZM4Hv4eN
X-Auto-Response-Suppress: All
X-GitHub-Recipient-Address<EMAIL_ADDRESS>----==_mimepart_56e71f27992ea_bd93fe7fd5392b86523cf
Content-Type: text/plain;
charset=UTF-8
Content-Transfer-Encoding: 7bit
Merged #686.

Reply to this email directly or view it on GitHub:
https://github.com/vsouza/awesome-ios/pull/686#event-589330895
----==_mimepart_56e71f27992ea_bd93fe7fd5392b86523cf
Content-Type: text/html;
charset=UTF-8
Content-Transfer-Encoding: 7bit
Merged #686.
—Reply to this email directly or view it on GitHub.

----==_mimepart_56e71f27992ea_bd93fe7fd5392b86523cf--


Backward compat removal 1.7.1

I'm opening this PR right now since it's ready for review.
It should land at the very end of the release when we're sure we're ready to migrate the internal build to git.

@jakub-g
this HUGE PR sounds great ! :+1: :ok: to be delivered when needed.


rstan can no longer execute 8 schools example

Summary:
Install of rstan on mac os x 10.14.6 seems to have problem with compiling stan models.
Description:
> library(rstan)
Loading required package: StanHeaders
Loading required package: ggplot2
rstan (Version 2.19.2, GitRev: 2e1f913d3ca3)
For execution on a local, multicore CPU with excess RAM we recommend calling
options(mc.cores = parallel::detectCores()).
To avoid recompilation of unchanged Stan programs, we recommend calling
rstan_options(auto_write = TRUE)
> J            <- 8
> y            <- c(28, 8,-3, 7,-1, 1,18,12)
> sigma        <- c(15, 10, 16, 11, 9, 11, 10, 18)
> schools_data <- c("J", "y", "sigma")
>
> fit1 <- stan(file="schools.stan",
+              data=schools_data,
+              iter=100, chains=4)
DIAGNOSTIC(S) FROM PARSER:
Info: assignment operator <- deprecated in the Stan language; use = instead.

Trying to compile a simple C file
Running /Library/Frameworks/R.framework/Resources/bin/R CMD SHLIB foo.c
clang -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   "-isystem /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include"'   -fPIC  -Wall -g -O2  -c foo.c -o foo.o
/bin/sh: -c: line 0: unexpected EOF while looking for matching `''
/bin/sh: -c: line 1: syntax error: unexpected end of file
make: *** [foo.o] Error 2
Error in compileCode(f, code, language = language, verbose = verbose) :
  Compilation ERROR, function(s)/method(s) not created! /bin/sh: -c: line 0: unexpected EOF while looking for matching `''
/bin/sh: -c: line 1: syntax error: unexpected end of file
make: *** [file9e6546f79efa.o] Error 2
In addition: Warning message:
In system(cmd, intern = !verbose) :
  running command '/Library/Frameworks/R.framework/Resources/bin/R CMD SHLIB file9e6546f79efa.cpp 2> file9e6546f79efa.cpp.err.txt' had status 1
Error in sink(type = "output") : invalid connection
> R.version.string
[1] "R version 3.6.1 (2019-07-05)"
> packageVersion("rstan")
[1] ‘2.19.2’
> Sys.info()
                                                                                sysname
                                                                                "Darwin"
                                                                                release
                                                                                "18.7.0"
                                                                                version
"Darwin Kernel Version 18.7.0: Tue Aug 20 16:57:14 PDT 2019; root:xnu-4903.271.2~2/RELEASE_X86_64"

$ clang --version
Apple LLVM version 10.0.1 (clang-1<IP_ADDRESS>)
Target: x86_64-apple-darwin18.7.0
Thread model: posix
InstalledDir: /Library/Developer/CommandLineTools/usr/bin

update: I will upgrade to Catalina to see if this aids in resolving the above error.

No, dont do that! See https://discourse.mc-stan.org/t/dealing-with-catalina/11285/115

This line seems wrong
schools_data <- c("J", "y", "sigma")

I think it should be
schools_data <- list(J, y, sigma)

Nice catch. My system seems to have some underlying (compiler?) issue...
> library(rstan)

Loading required package: StanHeaders
Loading required package: ggplot2
rstan (Version 2.19.2, GitRev: 2e1f913d3ca3)
For execution on a local, multicore CPU with excess RAM we recommend calling
options(mc.cores = parallel::detectCores()).
To avoid recompilation of unchanged Stan programs, we recommend calling
rstan_options(auto_write = TRUE)
> J            <- 8
y            <- c(28, 8,-3, 7,-1, 1,18,12)
sigma        <- c(15, 10, 16, 11, 9, 11, 10, 18)

> schools_data <- list(J, y, sigma)

>
fit1 <- stan(file="schools.stan",
             data=schools_data,
             iter=100, chains=4)

> + + DIAGNOSTIC(S) FROM PARSER:
Info: assignment operator <- deprecated in the Stan language; use = instead.

Error in new_CppObject_xp(fields$.module, fields$.pointer, ...) :
  Exception: variable does not exist; processing stage=data initialization; variable name=J; base type=int  (in 'model143135fbb4e2_schools' at line 2)

failed to create the sampler; sampling not done

$ more schools.stan
data {
      int<lower=0> J; // number of schools
      real y[J];      // estimated treatment effects
      real<lower=0> sigma[J]; // s.e. of effect estimates
    }
    parameters {
      real mu;
      real<lower=0> tau;
      vector[J] eta;
    }
    transformed parameters {
      vector[J] theta;
      theta <- mu + tau * eta;
    }
    model {
      eta ~ normal(0, 1);
      y ~ normal(theta, sigma);
}

I've been imprecise before, the elements in the list should be named. Try the following:
schools_data <- list(J=J, y=y, sigma=sigma)

While you are there, replace the <- with an = in the stan file.

Thank-you, that was it.
Steps taken in resolution:

upgrade to macOS Catalina (to force the upgrade of command line developer tools via xcode-select --install
Changed schools_data as you describe (schools_data <- list(J=J, y=y, sigma=sigma))
Replaced the <- with an = in the stan file.

Great to hear, so you can close this. Next time it may be better to post your problem on https://discourse.mc-stan.org first, which is designed to debug cases like this.

Thank-you. Closing.


Renamed Sentinel

Renamed 'Azure Sentinel ' to 'Microsoft Sentinel' (was renamed). Added in the heading.

@lukemurraynz Thank you very much for the correction.
You are welcome to add additional relevant content.


Configure: move --noexecstack probe to Configure.

config probe doesn't work in cross-compile scenarios or with clang.

Ping @dot-asm to rebase please.

Closing in favour of equivalent solution adapted for latest circumstances.


Retrieving class properties underlying type

Is there any way to get the value of a property without knowing its underlying type? The method variant::get_value() is a function template that requires the class member type, which kind of defeat the purpose of the registration?
struct Foo {
    int bar;
};

RTTR_REGISTRATION {
    rttr::registration::class_<Foo>("Foo")
        .property("bar", &Foo::bar);
}

void serialize(Stream& stream, int& value) {
    // serialize int value...
}

void serialize(Stream& stream, Foo& foo) {
    auto type = rttr::type::get<Foo>();
    for (auto& prop : type.get_properties()) {
        auto name = prop.get_name();
        auto var = prop.get_value(foo);
        stream.serialize(name, var.get_value</* here how to get Foo::bar original type? */>());
    }
}

Perhaps there is a way to store metadata along each property to store its underlying type? I'm looking for whatever solution that works, could be metadata, plugin, anything!
Thanks

You can do following:
void serialize(Stream& stream, Foo& foo) {
    auto type = rttr::type::get<Foo>();
    for (auto& prop : type.get_properties()) {
        auto name = prop.get_name();
        auto var = prop.get_value(foo);
        if (var.get_type() == type::get<int>())
        stream.serialize(name, var.to_int());
      else if (var.get_type() == type::get<double>())
        stream.serialize(name, var.to_double());
     else if (....)
    }
}

Does this help?

No unfortunately, the type is unknown at the time I need to get the member value. And anyway how would that work for my own types? I would have expected variant to be a template class, so that get_value() doesn't require we pass a type.

@gouletr
When variant it would be a class template, RTTR would not work how it works.
Because with RTTR you can work with types, which are unknown at compile time. You don't even need the header file. variant::get_value<T> is a function template. there you can provide your needed type.
However, you can always register functions so that the variant can convert to these types. E.g. providing a function which converts your custom type to a std::string.
Then you could simply write: stream.serialize(name, var.to_string());
See:
type::register_converter_func

Yes I get that right now RTTR works with types that are unknown at compile time. But my point is that it would be nice if it also supported types that are known at compile time, so that we can iterate through members with types preserved. Right now the type erasure is a major drawback imho.

@gouletr
Actually, its not a major draw back. It's a missing feature. Because having the possibility to work with unknown types is one of RTTR's major feature.
However, I have a PR https://github.com/rttrorg/rttr/pull/154 ready to merge (after some more added unit tests), which basically allows you to do what you want. Iterate over all members of an object at compile time. Right, that is what you want?

Yes, this is what I need. Can you share a snippet of what the code will look like? Your PR is quite massive.

There is an scripting example and a unit test for it. Take a look here:
Test:
https://github.com/rttrorg/rttr/pull/154/files#diff-94c545f2663bcabce4f5ce5fc027fd65
Scripting:
https://github.com/rttrorg/rttr/pull/154/files#diff-6d632bcaf15bd4e69c4fe2c9c82130ff

Done. It's now merged and ready to used. See the examples and the unit test for more information.


Object has no attribute 'unique_id'

Home Assistant release with the issue:

Last working Home Assistant release (if known):
0.88.2
Operating environment (Hass.io/Docker/Windows/etc.):
Hass.io
Component/platform:
melcloud.climate
https://community.home-assistant.io/t/mitsubishi-melcloud-integration-with-home-assistant/26275
https://github.com/o0Zz/ha-melcloud/
Description of problem:
Before was working. Now is problem:
AttributeError: 'MelCloudClimate' object has no attribute 'unique_id'
Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):
Traceback (if applicable):
/
Additional information:
Log Details (ERROR)
Thu Mar 07 2019 14:07:21 GMT+0100 (Central European Standard Time)
Error doing job: Task exception was never retrieved
Traceback (most recent call last):
File "/usr/local/lib/python3.7/site-packages/homeassistant/helpers/entity_platform.py", line 257, in _async_add_entity
if entity.unique_id is not None:
AttributeError: 'MelCloudClimate' object has no attribute 'unique_id'

This is a custom component, this bug tracker is only for official components. Please raise the issue with the author of the component.
The issue likely is this line:
https://github.com/o0Zz/ha-melcloud/blob/master/custom_components/climate/melcloud.py#L68
The location of the ClimateDevice class has changed.

Sorry to say but this line to me mean nothing... How to fix it? That would mean something to me...
I will try to contact developer... Also hopes that someone will officialy support this component.

It's a code issue that needs to be fixed by the code author. I also can't fix it because I don't know the component well enough. That's why the author needs to fix it.
For the component to become official someone needs to create a pull request in this repository, again a developer must do this.

Split 68 line from this:

from homeassistant.components.climate import (ClimateDevice, SUPPORT_TARGET_TEMPERATURE, SUPPORT_FAN_MODE, SUPPORT_OPERATION_MODE, SUPPORT_ON_OFF, SUPPORT_SWING_MODE)

to this:

from homeassistant.components.climate import (ClimateDevice)
from homeassistant.components.climate.const import (SUPPORT_TARGET_TEMPERATURE, SUPPORT_FAN_MODE, SUPPORT_OPERATION_MODE, SUPPORT_ON_OFF, SUPPORT_SWING_MODE)

Everything works again.

Perfect - works again, thanks alot


Link mailinabox to the Github Repo

As the title says. I find it more convenient and reliable to get sent to the github repo since I expect to see the opensource project first.

You're right.
Thanks for the MR


Posibility to run without log

Can you provide option for disable logging? Without disabling from outside like this:
log.SetOutput(ioutil.Discard)
//jpegquality using
...
log.SetOutput(os.Stdout)

Made a solution with logger object inside jpegReader and ability to predefine it's output before running New. Please, take accept pull request.

Sorry for toooo late reply. I will redesign the logger part soon. and PRs is welcome.


Create Conv3D Layers in beyondml.tflow.layers

Need to create and test the following layers:

beyondml.tflow.layers.MaskedConv3D
beyondml.tflow.layers.MultiMaskedConv3D
beyondml.tflow.layers.SparseConv3D
beyondml.tflow.layers.SparseMultiConv3D
beyondml.tflow.layers.MaxPool3D

Also need to rename the SparseConv and SparseMultiConv to SparseConv2D and SparseMultiConv2D
Need to ensure all functions in beyondml.tflow.utils work with the new layers

Also need to add MultiConv3D layer

All layers added.  Need to alter beyondml.tflow.utils and also build test cases

All changes made.  Need to write new tests

Changes pushed to branch v0.1.2, merged into staging and released as version 0.1.2.dev1 of BeyondmL


Upgrade to Storm 2.6.2, fix #1188

Currently fails with java.lang.NoClassDefFoundError: org/apache/hadoop/hdfs/client/HdfsDataOutputStream$SyncFlag

Currently fails with java.lang.NoClassDefFoundError: org/apache/hadoop/hdfs/client/HdfsDataOutputStream$SyncFlag

<dependency>
    <groupId>org.apache.hadoop</groupId>
    <artifactId>hadoop-client-api</artifactId>
    <version>3.3.6</version>
</dependency>

will fix it (for now). We should open a Jira in Storm to get the Hadoop Client API back into storm-hdfs ;-)

Currently fails with java.lang.NoClassDefFoundError: org/apache/hadoop/hdfs/client/HdfsDataOutputStream$SyncFlag

<dependency>
    <groupId>org.apache.hadoop</groupId>
    <artifactId>hadoop-client-api</artifactId>
    <version>3.3.6</version>
</dependency>

will fix it (for now). We should open a Jira in Storm to get the Hadoop Client API back into storm-hdfs ;-)

See https://issues.apache.org/jira/browse/STORM-4053


Feature: Implement buffer protocol for mlx.core array to support memoryview

mlx.core arrays are great already. To support better interoperability with other frameworks, even mlx.data, implementing the buffer protocol as for numpy arrays would help.
This should address https://github.com/ml-explore/mlx-data/issues/20 and will allow to use memoryview from python.

Gave it a quick shot in #323. There are some little edge cases, see inline comments in the draft PR.


convert setuppy output filename ignored

python3 -m dephell deps convert --traceback --from setup.py --to setup.py.new --to-format setuppy should create a file setup.py.new which is a parse and dump of the existing setup.py
Instead it writes to setup.py (and for dephell repo it changes stuff :P)

You specified --to instead of --to-path :) I've created #307 to be explicit about it.


the voronoi mark should consider the pointer as indicating which cell to show

The voronoi diagram is computed at render for the subset (grouped by Z) of the index, but with Plot.pointer what we mean is "show this cell from the (unpointed) voronoi", not "create a voronoi from this one point".

I prefer to frame this more generally as: the Voronoi mark should compute the Voronoi diagram during initialization, and then render a subset of cells using the passed index at runtime. In other words, the Voronoi mark shouldn’t know about the pointer transform, but it should respect the index that is passed to the render function, which may be a subset of the index during initialization.


Ensure mention lookups work

Description
I noticed that calls to resolveHandle were failing: it appears the pdsURL was being replaced with an access token JWT. This was preventing my Bsky client from being able to post @-mentions.
In providing this fix, I made two changes:

I set the pdsURL to the session's pdsURL rather than the access token. This must've been an error made earlier.
I also noted that the response JSON from the AT protocol endpoint returns a did property, not a handleDID. Changing that got it all flowing right again.

Linked Issues
#45
Type of Change

[x] Bug Fix
[ ] New Feature
[ ] Documentation

Checklist:

[ ] My code follows the ATProtoKit API Design Guidelines as well as the Swift API Design Guidelines.
[ ] I have performed a self-review of my own code and commented it, particularly in hard-to-understand areas.
[ ] I have made corresponding changes to the documentation.
[ ] My changes generate no new warnings or errors in the compiler or runtime.
[ ] My code is able to build and run on my machine.

Screenshots (if applicable)
Attach any screenshots or GIFs showcasing the changes effect.
Additional Notes
Add any other notes about the Pull Request here.
Credits
If you want to be credited in the CONTRIBUTORS file, you can fill out the form below. Please don't remove the square brackets.

Name: [Replace this with your first and last name or an alias]
GitHub: [Replace with your GitHub username]
Bluesky: [Replace with your Bluesky handle if you have one]
Email: [Replace with your email address, or delete this line]

I'll approve the PR and release it with 0.19.2 tomorrow.
There's one thing that I wanted to say I wanted to change, but thinking about it further, I think it makes sense in context to the Swift API Design Guidelines, so I'll allow it and implement similar changes to the rest of the project overtime.


⚠ Mobitopup has degraded performance

In 9ed59d8, Mobitopup (https://napcard.voz.tech) experienced degraded performance:

HTTP code: 200
Response time: 8380 ms

Resolved: Mobitopup performance has improved in 07d45c2.


it's annoying to type -- to pass arguments through to invoked process

I'm tired of typing obi go -- --show-fipser, that's a whole three keystrokes wasted.
Why shouldn't obi automatically pass unrecognized flags through to the process it invokes? If I type obi go --show-fipser can't obi infer that I want to pass that flag through because obi doesn't have a fipser to show?

Extra args should be explicitly separated because otherwise we can never
add new flags to obi without risk of breaking users.
On Thu, Feb 16, 2017 at 01:52 Aaron Rice<EMAIL_ADDRESS>wrote:

I'm tired of typing obi go -- --show-fipser, that's a whole three
keystrokes wasted.
Why shouldn't obi automatically pass unrecognized flags through to the
process it invokes? If I type obi go --show-fipser can't obi infer that I
want to pass that flag through because obi doesn't have a fipser to show?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/Oblong/obi/issues/100, or mute the thread
https://github.com/notifications/unsubscribe-auth/AAow_Qkx_ebIoJ7LRKKEkaTYAxuCFntdks5rdBxpgaJpZM4MCy9H
.


Delta T off

I don't normally look at Delta T, so I don't know when it went wonky.
Per HA the delta T is -43.2F which is impossible (under most conditions), and the app reports 9.7F.
I don't know if this is limited to just us non-metric users or if this is an issue for metric also.
Air Temp, Wet Bulb Temp, Dew Point, Humidity all track, so it appears to be a calculation in Delta T.
Documenting for now, I will look at the code after I change out some light switches.

Is 'temp' always in Celsius or does it change depending on imperial or metric.
I think it is always in Celsius, that is what I assumed in the visibility calculation.
If it is always in Celsius then the Delta-T function is off since it assumes it changes based on metric or imperial.
For me it looks like that temp is in Celsius and then the self generated wetbulb is in Fahrenheit and thus a negative number is generated as a return.
I will go with the assumption that temp is always in C and make a PR based on that.

PR submitted

I always assume that the raw data we get from the station is in metric values, and it seems to be like that. I will look at the PR now.

Still off, not negative thou.
App 8.5, HA 40.5
All the bouncing back for metric and imperial makes the code a little confusing

Yes it does. But I have found the error now, and it is fixed. Will be out in the next release.

Visibility is acting funky.  Don't know if it is related or not.  I will rework this so there is only metric formula and the imperial is just a conversion from the metric.  Are you making changes directly and not doing a PR, just asking since I can't seem to see changes you've made recently (as in comparing them); nothing wrong with that, just asking.

as reported by tempest software
Delta T
1.4 °F
WF Delta T
1 minute ago
33.5 ˚F
Something looks off just a fyi

He just identified the issue, it has not been resolved yet.  Won't be till Sunday that he gets this done.

I am so not as well versed as you guys just reporting thank you all for your hard work truly appreciated

@robertw
Any other issues, please feel free to report.  The more eyes looking at something, the greater the chance to make it  better.
FYI, the visibility calculation is a little of and I hopefully corrected it in the pending change.

This is released in 2.0.15. Please let me know if it is still OFF. Closing for now, but just reopen if needed.


update exiftool version. add ZIP support to exiftool

Taking a stab at resolving #9.
Changes

Update Exiftool version to 12.02
Update Exiftool download path
Add cpanminus and install zip libraries to enable decompression capabilities for Exiftool

Regarding @tomerf-sndbox's point on adding compression capabilities it is indeed very beneficial, below is example output against a maldoc. When Exiftool is able to decompress the document, much more metadata can be extracted.

 Hopefully I'll get time by the end of the week. Thanks!

LGTM, thank you!


⚠ Samsung has degraded performance

In 0d04c95, Samsung (https://samsung.com) experienced degraded performance:

HTTP code: 200
Response time: 2397 ms

Resolved: Samsung performance has improved in d2ab849.


Changed javascript code blocks to typescript

For #37
Does not correct menubaro.md

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

@alexkokkinos Thank you for your contribution (actually you have several, thank you!), we are reviewing it and will get back to you shortly. Please accept our apologies for this initial delay while we work though the initial backlog of contributions.

@alexkokkinos Sorry for the delay, Thank you for your contribution, I am merging it now and it should be live shortly.


debug for repeated messages

[x] debug to get rid of the repeated message after changing nickname
[x] some formatting updates


Indicator Level error handling prevents completion of target creation when editing indicator in IPTT

Originally noted by @camgnostic:

looks like I may have a breaking bug - editing an indicator from the IPTT page appears to have some validation issues related to the indicator level (keeps telling me to fill out the field despite already having filled out the field) - would love if someone on a cleaner branch than mine can double-check me here

I can replicate this issue on my local with the latest mangosteen (c282c32). Steps to reproduce:

Select any program and time period in IPTT quickstart
In the IPTT, select an indicator with targets & open its edit popup
Check that Level on the Performance tab has a value (e.g. Goal)
Remove all Targets on the Targets tab
Select a new Target frequency and click Create Targets
ERROR on Performance tab prevents form from saving!
I did however correctly remove my targets! (see screenshot below)

Here’s a hint:
I can’t reproduce this bug when editing an indicator in the popup on the Program page (so I think this might be as simple as copypasting some JS between templates)

@KennyMonster  — This may be related to #885

That's all I changed to pass this, so that's all I can think of for testing, I also tried to find another way in which editing was broken but couldn't.  I also tested target creation, but that's it.


Add photo uploads, cropping and marking tools

EDIT
Added two Activities

PhotoSendActivity to crop captured image and/or upload photo.
This uses CropImageView of https://github.com/ArthurHub/Android-Image-Cropper open source library as a View.

PhotoEditActivity to allow drawing on captured image and upload this edited photo.
This uses a custom view DrawCustomView

Improved performance of bitmap decoding.
https://drive.google.com/open?id=0B4jK5QX65b0ZMHFPYWlwNERqS2c

Automated message from Dropbox CLA bot
@Sam1301, it looks like you've already signed the Dropbox CLA. Thanks!

@kunall17 can you review this?  Thanks!

Will do this one today!

@timabbott @kunall17 Can i also review the codes? If you allow. :)

@saketkumar95 yeah, go ahead but it might not be the final review to be merged in!

@Sam1301 I think there should be an option to rotate the image after clicking it.

Thanks for working on this @Sam1301
When i first tried the cropping tools, I got a timeout error
12-27 22:17:54.441 998-1018/? E/ActivityManager: ANR in com.zulip.android.dev (com.zulip.android.dev/com.zulip.android.activities.PhotoSendActivity)
                                                 PID: 24430
                                                 Reason: Input dispatching timed out (Waiting to send non-key event because the touched window has not finished processing certain input events that were delivered to it over 500.0ms ago.  Wait queue length: 12.  Wait queue head age: 5865.2ms.)
                                                   I am investigating more into this issue.
Yes, your right.. I enabled crop before edit, to add crop after edit, I guess I'll just redirect the user to sendActivity from editActivity.

I also tried to reproduce the error which I was not able to, so we can ignore this one! :)

Added crop to PhotoEditActivity and renamed photo_buttons style.
https://drive.google.com/open?id=0B4jK5QX65b0ZWmJFajFpVWtDOU0

@kunall17 overridden the back button functionality and added a cancel button in PhotoSendActivity.

In PhotoEditActivity, on CROP press it takes me to photoSendActivity but the crop control doesn't shows up!
Rest seems nice! :)

@kunall17 Oh so should I enable the crop button on this redirection?

Yeah, also I encountered these two issues
01-02 10:55:55.425 1782-1782/com.zulip.android.dev E/AndroidRuntime: FATAL EXCEPTION: main
                                                                     Process: com.zulip.android.dev, PID: 1782
                                                                     java.lang.IllegalArgumentException: x must be >= 0
                                                                         at android.graphics.Bitmap.checkXYSign(Bitmap.java:363)
                                                                         at android.graphics.Bitmap.createBitmap(Bitmap.java:683)
                                                                         at android.graphics.Bitmap.createBitmap(Bitmap.java:653)
                                                                         at com.zulip.android.activities.PhotoEditActivity.screenShot(PhotoEditActivity.java:231)
                                                                         at com.zulip.android.activities.PhotoEditActivity$4.onClick(PhotoEditActivity.java:128)
                                                                         at android.view.View.performClick(View.java:5198)
                                                                         at android.view.View$PerformClick.run(View.java:21147)
                                                                         at android.os.Handler.handleCallback(Handler.java:739)
                                                                         at android.os.Handler.dispatchMessage(Handler.java:95)
                                                                         at android.os.Looper.loop(Looper.java:148)
                                                                         at android.app.ActivityThread.main(ActivityThread.java:5417)
                                                                         at java.lang.reflect.Method.invoke(Native Method)
                                                                         at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
                                                                         at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

01-02 22:11:16.521 3821-3821/com.zulip.android.dev E/AndroidRuntime: FATAL EXCEPTION: main
                                                                     Process: com.zulip.android.dev, PID: 3821
                                                                     java.lang.ClassCastException: com.bumptech.glide.load.resource.bitmap.GlideBitmapDrawable cannot be cast to android.graphics.drawable.BitmapDrawable
                                                                         at com.zulip.android.activities.PhotoSendActivity$3.onClick(PhotoSendActivity.java:114)
                                                                         at android.view.View.performClick(View.java:5280)
                                                                         at android.view.View$PerformClick.run(View.java:21239)
                                                                         at android.os.Handler.handleCallback(Handler.java:739)
                                                                         at android.os.Handler.dispatchMessage(Handler.java:95)
                                                                         at android.os.Looper.loop(Looper.java:234)
                                                                         at android.app.ActivityThread.main(ActivityThread.java:5526)
                                                                         at java.lang.reflect.Method.invoke(Native Method)
                                                                         at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
                                                                         at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)

@kunall17 I have resolved the second issue. I couldn't replicate the first one. Can you provide more context on when this happens?

It appeared only once, I clicked Edit -> Crop -> Cropbutton then it occurred!

@Sam1301 Is the first crash fixed by the latest commit changes?

The crash occurred because the layout wasn't ready yet and hence getWidth() was returning 0. I have fixed this in the latest commits :+1:

@Sam1301 Any other feature left for this PR?

@kunall17 For me, I have implemented all features I could think of regarding photo uploads, the attachment uploads pr will build upon this :)

Awesome, thanks for working on this one..:)
@timabbott LGTM! :)

@kunall17 Just fixed a typo in a previous commit message :+1:

@Sam1301 wow this is a lot of commits; does it make sense to squash them before merging this?  It seems unlikely that the intermediate states here all work properly...
Regardless it looks like we have a merge conflict from one of the other PRs I merged today.

@timabbott sorry for not squashing the commits earlier. I have resolved the merge conflict. Let me know in case I need to squash more commits. Thanks :)

Update
resolved merge conflict and lint issues.

Merged, thanks @Sam1301!!


CVARS feature?

Can we have some kind of cvar feature as Valve games have.
so let's the implementation would be something like, and executing cl_showfps 1 will change the bool avlue?
[Cvar("cl_showfps"]
public bool ShowFps;

an example: https://github.com/terrehbyte/TBYTEConsoleApp


Add proper min/max values to Rasdaman color map

The permafrost mini-map color map does not have proper min/max values. This is evident on the permafrost mini-maps when large portions of dark red or dark blue appear. For example:

The Rasdaman colormap has been updated to go from -20 to 20 based on the min/max values of the source GeoTIFFs. The abrupt splotches of intense red in southwest Alaska (as in the screenshot above), and intense blue splotches elsewhere, are due to sharp differences in the data itself, so not a colormap problem.
Stretching out the color map also had the effect of making the permafrost maps less garish looking, and help the map marker stand out better.


Flatten components

Trying out manual trigger.
/test all

/override pre-master-knative-components-channel

/override pre-master-knative-kafka-components-channel


Fix formatting in network network migration guide.

Deleted some invisible characters that prevent proper rendering of headers.
Added missing comma in the first JSON.

Thanks @janisz!
    .  o ..
     o . o o.o
          ...oo
            __[]__          Shippin'
         __|_o_o_o\__         it!
         \""""""""""/
          \. ..  . /
     ^^^^^^^^^^^^^^^^^^^^


SAMZA-2755: Pin jdk to 8.0.232 (fix up rat / broken master build)

See: https://github.com/gradle/gradle/issues/9764 for additional details
For an example of how we might fix rat, see: https://github.com/apache/samza/pull/1619 (note that checkstyle, and maybe something else, also needs to be fixed)

Thanks for the fix!


build fails on uClibc-ng

When compiling with buildroot and uClibc-ng is used as C library the build fails.
libtool: compile:  /home/hthiery/sources/mainline/buildroot/output/host/bin/i686-buildroot-linux-uclibc-gcc -DHAVE_CONFIG_H -I. -I../.. -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -I../../src -I/home/hthiery/sources/mainline/buildroot/output/host/bin/../i686-buildroot-linux-uclibc/sysroot/usr/include/dbus-1.0 -I/home/hthiery/sources/mainline/buildroot/output/host/bin/../i686-buildroot-linux-uclibc/sysroot/usr/lib/dbus-1.0/include -D_LARGEFILE_SOURCE -D_LARGEFILE64_SOURCE -D_FILE_OFFSET_BITS=64 -Os -MT ../shared/log.lo -MD -MP -MF ../shared/.deps/log.Tpo -c ../shared/log.c  -fPIC -DPIC -o ../shared/.libs/log.o
../shared/log.c:13:10: fatal error: execinfo.h: No such file or directory
   13 | #include <execinfo.h>
      |          ^~~~~~~~~~~~

The include of execinfo.h is needed for backtrace_symbols. But this is only used when DEBUG is defined.
Should the file be included only in case of DEBUG?

Yes, this functionality is not available in all libc libraries, so indeed it might be in the #if DEBUG. However, I think that the better idea is to actually check for backtrace functionality with autotools. I'll try to fix that. Thanks for reporting this issue :)

thank you

Hi, retested with current HEAD and now it builds fine. Thank you again.


Fix errors and warnings for Godot3.2.

The assert keyword expects parens
Warnings for unused parameters can be turned on. Prefix delta with an underscore to indicate it is intentionally unused.

Thank you!


About Simple Seg head

How did 'Simple Seg head' achieve dimension upgrading,  which 2d bev-feat to 3d occ-pred?

The dimension upgrading is very similar to FlashOcc's practice (https://github.com/Yzichen/FlashOCC), the last nn.Linear layer remaps the feature channel to num_class * height_channel, then permute height_channel to h, w, l and num_class channel to the last.

The dimension upgrading is very similar to FlashOcc's practice (https://github.com/Yzichen/FlashOCC), the last nn.Linear layer remaps the feature channel to num_class * height_channel, then permute height_channel to h, w, l and num_class channel to the last.

Thanks


Repo License

Hello,
Your work looks impressive, i wonder what license would you use for this work, something like Stark ?

updated. MIT License

Thankyou!


Added a new preset category - music and sound. added a "play music or…

… sound" preset to it. Removed "players" category from plugins - added the respective plugins to "audio" and "video" categories instead, removing duplicate listings.

lgtm


CMAKE_CUDA_ARCHITECTURES ALL will not insert 62 or 72

The logic to determine if we should generate for NVIDIA Drive integrated GPUs was incorrect and could cause bad
code generation for non drive based ARM platforms.
Since RAPIDS doesn't deploy multi-arch projects to DRIVE we can remove this logic.

@gpucibot merge


OpenCV issue

Hi,
I'm trying to deploy this SDK in China but having network issue due to "the firewall".
I installed OpenCV supplied and the powershell script failed to function.
Is there a way I could manually config OpenCV2, k4a, and re-route lib folder?
attached screenshot for reference

Please redirect your question to an OpenCV forum.


feat: Add configuration params LlamaSharp provider models

Add some important configuration parameters (like the number of CPU threads and GPU layers) to every LLamaSharp model.

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

@all-contributors please add @fiorelorenzo for infrastructure, tests and code

Thank you very much for your contribution. Please write me your name in discord if you want and I will add you to the list of contrubutors and dev channel discussing development and immediate plans

Sure! My Discord username is the same as here, fiorelorenzo.


'expires' option in @prop decorator missing

Hi.
It's very usefull the 'expires' option for the schema field definition when data type is Data.
Below a mongoose example:
new Schema({
   createdAt: { type: Date, expires: 60*60*24 }
});

Please, can you consider to implement it?
Thank you!

Hi @pgsfredda
It is a good idea to add this functionality to typegoose, We would appreciate it if you could create a pull request. If not, we will try to do it ourselves when we some free time for the project.
Cheers,
Daniel

Of course but it would be the first time for me creating a pull request.
I'll try the solution by me and when I'm ready I'll create the request.
Thank you!

Hi.
I tried to add  expires field in the interface BasePropOptions in the ts and d.ts of prop file as listed below.
It seems work correctly! The saved rows are deleted after the time indicated in the expires field (string for time notation and number for milliseconds as with mongoose).
export interface BasePropOptions {
  required?: RequiredType;
  enum?: string[] | object;
  default?: any;
  unique?: boolean;
  index?: boolean;
  expires?: string | number;
}

Hi @pgsfredda
Can you please create a pull request about this, with a test covering the new feature.
Cheers,
Daniel

because of https://github.com/szokodiakos/typegoose/blob/ea1c0ec6bbebdd6b27ba4580ec39c1d3535b2084/src/prop.ts#L51
this can be closed
@Ben305


Nudge to set on-chain identity on profile

When user open their profile, show them hint they can set their identity "[Add on-chain recognition for X](URL-to-identity-form)" @vikiival -- what's the price for identity?
direct people to set up their on-chain identity https://nft.kodadot.xyz/identity
show costs for identity on form

what's the price for identity?

Currently Kusama locks 0.0333 KSM