System.TypeLoadException: Could not load type 'OpenCvSharp.MatExpr' from assembly 'opencvsharp

Summary of your issue

Environment
Windows 10
VSCode
What did you do when you faced the problem?
Create new project
Example code:
opencvsharp.csproj
<Project Sdk="Microsoft.NET.Sdk">

  <PropertyGroup>
    <OutputType>Exe</OutputType>
    <TargetFramework>net7.0</TargetFramework>
    <ImplicitUsings>enable</ImplicitUsings>
    <Nullable>enable</Nullable>
  </PropertyGroup>

  <ItemGroup>
    <PackageReference Include="OpenCvSharp4" Version="<IP_ADDRESS>20608" />
    <PackageReference Include="OpenCvSharp4.runtime.win" Version="<IP_ADDRESS>20608" />
  </ItemGroup>

</Project>

Program.cs
using OpenCvSharp;

var canvas = Mat.Ones(10, 10);

Output:
Unhandled exception. System.TypeLoadException: Could not load type 'OpenCvSharp.MatExpr' from assembly 'opencvsharp, Version=<IP_ADDRESS>, Culture=neutral, PublicKeyToken=null'.
   at Program.<Main>$(String[] args)

What did you intend to be?
Should not crash

Turns out naming my project 'opencvsharp' was a bad idea 🤦
Naming it something else fixed it


Problems with adding new e-mail address to the existing account

Describe the issue
After logging to datatracker with<EMAIL_ADDRESS>I am trying to add a new e-mail address<EMAIL_ADDRESS>to the existing account<EMAIL_ADDRESS>However, I get following error message:
"Email address<EMAIL_ADDRESS>is already assigned to account 'None' (Krzysztof Szarkowicz)"
After logging out from datatracker, and trying to restore datatracker password of<EMAIL_ADDRESS>I get following message:
"Didn't find a matching account. If you don't have an account yet, you can create one."
So,  the account<EMAIL_ADDRESS>doesn't exist in datatracker, but I am not able to add<EMAIL_ADDRESS>e-mail address to the<EMAIL_ADDRESS>datatracker account.
Code of Conduct

[X] I agree to follow the IETF's Code of Conduct

Try again please - adjustments have been made. If you still have issues, please send email to<EMAIL_ADDRESS>with the details.


Release/2.0.0

:x: Build TheIdServer 2.0.3.build.961 failed (commit https://github.com/Aguafrommars/TheIdServer/commit/f1f6d9fa46 by @semantic-release-bot)


Allow configuration on container if it should be automatically cleaned up

In reference to https://github.com/testcontainers/testcontainers-node/pull/849#issuecomment-2437020917 I'd like to be able to override the default behaviour where a container is cleaned up when it is stopped.
What I suggest is adding a new function on GenericContainer:

withRemoveWhenStopped(removeWhenStopped: boolean)

So the default behaviour is still that the container is removed when you call container.stop(). But to override you can explicitly configure it with .withRemoveWhenStopped(false) when creating the container. It should probably still be possible to override the configured value by options container.stop({ remove: true }).
It also made sense to me that you'd to be able to configure withAutoRemove(autoRemove: boolean), so if the container is stopped in other ways than via the testcontainers-node API it is also cleaned up.
I've taken a stab at adding both withRemoveWhenStopped and withAutoRemove here (including tests): https://github.com/testcontainers/testcontainers-node/compare/main...cbrevik:testcontainers-node:support-configured-auto-remove

@cbrevik Could you add some info why the logic for adding withRemoveWhenStopped and withAutoRemove cannot just be put in the container.stop({ ... }). IMO having the same option in 2 places, with one overriding the other is confusing

The main use case for me would be if I enable withReuse() on a container, I normally don't want it to be removed when stopped. So it made sense to me that I could configure that "in the same place" as I configure re-use.
In other words something like:
const container = await new PostgreSqlContainer()
    .withReuse()
    .withRemove(false)
    .start()

Or something like that. I normally "pass" the container somewhere else, and then I have to remember to call container.stop({ remove: false }) in the other module.
It's not a huge deal though, just made sense that it would be configureable somehow to me.


az login failed

This is autogenerated. Please review and update as needed.
Describe the bug
Command Name
az login
Errors:
'NoneType' object is not callable
Traceback (most recent call last):
python3.7/site-packages/knack/cli.py, ln 206, in invoke
    cmd_result = self.invocation.execute(args)
cli/core/commands/__init__.py, ln 603, in execute
    raise ex
cli/core/commands/__init__.py, ln 661, in _run_jobs_serially
    results.append(self._run_job(expanded_arg, cmd_copy))
cli/core/commands/__init__.py, ln 654, in _run_job
    six.reraise(*sys.exc_info())
...
azure/cli/core/_profile.py, ln 807, in find_through_interactive_flow
    result = self._find_using_common_tenant(token_entry[_ACCESS_TOKEN], resource)
azure/cli/core/_profile.py, ln 837, in _find_using_common_tenant
    client = self._arm_client_factory(token_credential)
azure/cli/core/_profile.py, ln 759, in create_arm_client_factory
    base_url=self.cli_ctx.cloud.endpoints.resource_manager))
TypeError: 'NoneType' object is not callable

To Reproduce:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.

Put any pre-requisite steps here...
az login

Expected Behavior
Environment Summary
Linux-3.10.0-862.11.6.el7.x86_64-x86_64-with-centos-7.6.1810-Core
Python 3.7.2
Shell: bash

azure-cli 2.0.72

Additional Context

Looks like a reference issue. Could please reinstall and see it works?

Closing due to no update. If the issue persists, please let us know.


[Tables] Add support for AzureNamedKeyCredential

This should be in place of the current dict/str based implementation.
The only supported types for the credential parameter will now be AzureNamedKeyCredential, AzureSasKeyCredential or via connection string (with samples/readme etc updated to match).
The azure-core dependency version will also need to be updated to match.

No, AzureNamedKeyCredential
https://github.com/Azure/azure-sdk-for-python/blob/master/sdk/core/azure-core/azure/core/credentials.py#L117


[Suggestion] Existing Item Filter Active/ Passive

I don't know for sure if anyone has already asked for this, but it's the kind of thing that makes a huge difference...
I would like the existing item filter to have a passive/active option, where Passive makes it so you have to take a snapshot everytime you want the filter to change, and Active makes the filter update everytime the inventory next to it recieves a new item by the player.
This way it would be possible to (for example) have a chest just for raw ores and everytime you wished to add or divert the flow of ores to somewhere else (say, a grinder) you could just do it by placing or removing ores from their chest.
There are many applications, this is also quite useful when doing sorting mechanisms since you can just add newly discovered items to a system simply by placing them on chests.
Overall makes things more dynamic.
Here's hoping this will get implemented!
Bordissed

When you clear the snapshot of the existing item filter it will use the current inventory content as filter.


Add OCL-type constraints

Originally reported on Google Code with ID 187
Owned by redeyedmars

OCL constraints would be built on top of the before and after capability that already
exists in Umple

Reported by @umple on 2011-06-25 02:53:40

This issue is a longstanding issue. Constraints need to be continually evolved. I am lowering the priority, however as remaining work is enhancement.

I am closing this issue. Other issues can be raised about constraints as we expand them.


[FEATURE] Cache miss on deserialization error in L2 cache

Problem
On a few occations I have accidentally broken cache deserialization by adding non-nullable properties to the DTO class for the cache entry, while existing entries in Redis are missing these. This mistake is easy to make, and it can effectively cause downtime for an API resource attempting to read the cache entry with GetOrSet semantics.
Solution

Add option, e.g. FusionCacheEntryOptions.TreatDistributedCacheDeserializationErrorAsCacheMiss, to treat it as cache miss

For GetOrSet, it will invoke the factory method
For Get, it will return no result

I first considered to evict the distributed cache entry, but I realize that may add a performance hit and it may be better to just treat it as a cache miss and only update the cache entry if the factory successfully produces a new fresh value.
Alternatives
Using Events to invalidate cache on deserialization error. However, this still results in one failed API request for each cache entry.
I want to achieve zero failed API requests if the cache entry is invalid for any reason, without having to try-catch everywhere or add my own extensions methods on top of GetOrSet.
fusionCache.Events.Distributed.DeserializationError += OnDistributedOnDeserializationError;

private static void OnDistributedOnDeserializationError(object? sender, FusionCacheEntryEventArgs args)
{
    if (sender is IFusionCache senderCache)
    {
        senderCache.Remove(args.Key);
    }
}

Additional context
None
I'm up for attempting a pull request on this, if that helps move this along.

Hi @angularsen , this is a good one!
In theory it would also help when there are wire format versioning updates.
I have to think about it a little bit cause edge cases, potentially infinite update cycles and so on but... it may work!
Will update.

ps: right now I'm deep into Tagging which is uber complex and very delicate (and if you'd like to spend some time reading the proposal and sharing you think it would be really helpful), but I'll tackle this one right after that.

Great! Yes, I would think it helps a lot.
I just stumbled on the Tagging thread while posting this, and that also looks super interesting. Following closely, as I've struggled to find a good strategy to invalidate say all cache for a particular user, and your proposal looks like a real nice solution to that 👏

Hi @angularsen I was just re-reading this issue and I thought that I haven't mentioned setting ReThrowSerializationExceptions to false... have you already tried it?

@jodydonetti No I have not, and I'm not sure I understand how that would work based on the description. How can I use this to ignore or invalidate invalid JSON? Will it simply treat it as cache miss already, or will something else happen?

🧙 ReThrowSerializationExceptions
bool
true
Set this to false to disable the bubble up of serialization exceptions (default is true).

I may expand the docs a little bit, but yeah: with false it would be as if there was nothing to deserialize, so basically a cache miss.
Now that I think about it though, it would be better to be able to differentiate between reads and writes: an error on read (deserialize) may be ignorable, but an error when writing would mean 99.999% of the times a bad configuration, which would not go away anyway unless fixed in code.
Should I add 2 separate options maybe? Thoughts?

Is there any usecase for not rethrowing on write serialization error? Not sure when anyone would ever want that.
I see two options:

Rewrite the documentation for the existing property and let it only control reads, and let writes always fail.
Or deprecate this one, and add a new property that is more explicit in its name TreatDistributedDeserializationErrorAsCacheMiss

Is there any usecase for not rethrowing on write serialization error? Not sure when anyone would ever want that.

Well... I mean, I can't think of any right now 😑
Back when I added that option, I did so while also adding ReThrowDistributedCacheExceptions and ReThrowBackplaneExceptions so maybe I got carried away by making a parallel as if the ones for the distributed cache and the backplane would be the same as the one for the serializer.
In fact there is already a difference between the first 2 and the last one: by default the first two are set to false (because they can be transient and we have Auto-Recovery to cover those errors) while the last one is set to true, because of the different nature of it.
You know what? Probably I can just... (see below)

I see two options:

Rewrite the documentation for the existing property and let it only control reads, and let writes always fail.

... this, I think it's the way to go.
I'll think about it a bit more, but this is probably the right approach.

Either way, it's kind of a breaking change for both default options and for users explicitly configuring ReThrowSerializationExceptions already.

Two things here:

if there's no reason to suppress serialization exceptions (on write) but only de-serialization, in theory it's not actually a breaking change, since we just decided that there's no reason to disable the write ones
also yes, I understand that it technically is, but still: the change will come with v2

And v2 is a major version, which allows for breaking changes (and I'm already making some, although hopefully backward compatible for 99.999% of the cases).
So yeah I think we have a solution here.
Agree?

Sounds great to me 👍
I'm unblocked already I guess since I don't have any issues with serialization on writes. I'll try disabling this and see if achieves what I was asking for in this ticket.

Verified that setting ReThrowSerializationExceptions = false does treat JSON deserialization error in distributed cache as cache miss 🎉

Awesome, happy you're unblocked now!

Closing this as solved, although the solution we discussed still makes sense 👍

Yep, I'll create an issue to track that change and will include it in v2.

Hi all, v2.0.0-preview-3 is out 🥳


CLOUDP-47511: Renamed struct fields to match API

With this PR we update the names of all struct fields in the atlas  package to match their counterparts in the Atlas API.

I'm happy to see these changes! it keeps it more consistent.


Remove atomic from form new container

Remove atomic from form new container
Fixes: https://github.com/ManageIQ/manageiq/issues/8612
Screenshot:

@simon3z this override the default supported_types_and_descriptions_hash it can be removed once ems-container will support atomic.

@miq-bot add_label providers/containers, ui

@miq-bot add_label darga/yes

@simon3z is this for both upstream and downstream?

@simon3z is this for both upstream and downstream?

@chessbyte yes (it may need considerations about productization).

@chessbyte The change looks fine, not sure about your concern for downstream as far as merging, so up to you.

@chessbyte The change looks fine, not sure about your concern for downstream as far as merging, so up to you.

@dclarizio my only concern is whether permissions.yml is taken in account or not (I assume it should be, but I'd like to be sure about that).

@simon3z  @dclarizio  This hack overrides the original function, it will not see the yml file.
if we need to use changes to the .yml file, we will need to change this PR.
The original function checks the yml file using Vmdb::PermissionStore:
def self.supported_types_and_descriptions_hash
  supported_subclasses.each_with_object({}) do |klass, hash|
    if Vmdb::PermissionStores.instance.supported_ems_type?(klass.ems_type)
      hash[klass.ems_type] = klass.description
    end
  end
end

@simon3z @dclarizio Changed the PR to override  supported_subclasses,  so now it will also check the yml file :-)
The only other place we use supported_subclasses is in the api controller, so I think it's ok.

@simon3z @dclarizio Changed the PR to override supported_subclasses, so now it will also check the yml file :-)
The only other place we use supported_subclasses is in the api controller, so I think it's ok.

@yaacov please remove also the lines (in this PR):
- ems-type:atomic
- ems-type:atomic_enterprise

from config/permissions.tmpl.yml
Then please verify that moving config/permissions.tmpl.yml to config/permissions.yml and removing the lines:

ems-type:kubernetes
ems-type:openshift

Will display just OpenShift Enterprise as an option in the combobox.
Thanks.

Will display just OpenShift Enterprise as an option in the combobox.

@simon3z cute :+1:

LGTM :+1: cc @chessbyte ready for merge.

Closing/reopening since #8684 was merged to fix master


Added json support for tokens

In the installation generator script, the migration template checks to see if the app is using postgres by seeing what sub-class of ActiveRecord::ConnectionAdapter the app is using. If it is postgres, the app will use a token column instead of a text one.

Since the tests run with SQLite, what do you think the best way to add tests are? I just did it manually.

hmm sorry it looks like my branch is out of sync. I'll update that soon

Could be nice to change column too ;)

fwiw, I got the inspiration from this comment: https://github.com/lynndylanhurley/devise_token_auth/issues/121#issuecomment-113790105

@shicholas - I think we need an additional check on pg_types as json was not supported until 9.3, and just checking the adapter is insufficient. see also: http://www.postgresql.org/docs/current/interactive/catalog-pg-type.html
Likewise, MySQL is now rolling json support, so we should account for that possibility as well. Not sure about SQLite at this point ...

okay sounds good, I will do a check for mysql and postgres with the right versions. I'll push up the some code soon. How should I test this though? Should we run the tests w/ those database versions?

pushed, let me know what you think.

@shicholas - LGTM ... would you mind rebasing and squashing your commits?

np, rebased and squashed.

thanks @shicholas !


Some locales are not supported on PayPal

I configured the payment method with a sandbox account. After clicking on the place order button in the checkout, i land on the payment page but the paypal form/buttons are missing (instead the credit card tab is filled):

And in the console i found this:

GET https://www.paypal.com/sdk/js?components=hosted-fields,buttons&locale=it&client-id=&merchant-id=&intent=capture net::ERR_ABORTED 400

If I call the URL i get this error:

"Invalid query value for locale: it"

If i call it with it_IT locale it works.
As i can see from the supported locales in the Paypal docs (https://developer.paypal.com/docs/api/reference/locale-codes/#supported-locale-codes) they do not support 2-digit locales.
So probably a mapping between Sylius locales and Paypal locales is needed?

Hi @LucaGallinari! What prevents you from setting the locale to it_IT? It's still the recommended way to do it in Sylius. I understand, that having a regular it selectable in the locales list can be confusing, but it's provided by the PHP intl component so we have no control over it.
Still, some mechanism that would map 2-digit locales to their extended, default versions (it -> it_IT, pl -> pl_PL etc.) would be definitely an improvement 👌

Hi @Zales0123 sorry for the late response. We used "it" cause this locale is bound to the "it" channel in which you can ship to Italy (it_IT), San Marino (it_SM) and Città del Vaticano (it_VA). So the resulting URL will be mywebsite.com/it and not mywebsite.com/it_IT cause this one would be misleading, we don't want to depend on the region. Moreover, from a SEO perspective is better, cause the language is a generic "italian" not bound to the region.


Colab: frame_count zfill hotfix

Running the colab results in an error because zfill cannot be invoked on an integer

I have incorporated this fix in my fork which also includes the other pending PRs present in this repo.

@AlphaGit I tried using your fork yesterday and ran into an issue. I was about to open a pull request on your fork because GitHub doesn't support

Hi @echometerain, thanks for letting me know. I have enabled issues (as you said, they're disabled by default on forks), so we can discuss over there. Interestingly enough, I would have tried your same steps. Let me give it a try.


Coverage HTML report colors should follow coverageThreshold values

🚀 Feature Proposal
Istanbul / lcov provides a way to define min/med values to correspond to the red/yellow/green visual clues.
This is done via settings in a .lcovrc file:
https://www.systutorials.com/docs/linux/man/5-lcovrc/
https://stackoverflow.com/questions/40618939/lcov-html-report-coverage-limits
Jest allows us to define custom coverage thresholds using --coverageThreshold CLI argument/config file setting.
The coloration of the lcov HTML report should follow these values and not color a missed threshold green.
Motivation
We've set our global thresholds to 100%:
coverageThreshold: {
  global: {
    // 100%!
    branches: 100,
    functions: 100,
    lines: 100,
    // no uncovered statements!
    statements: 0,
  },
},

But (outside of the CLI) we have to painstakingly scan our coverage report to find that one 98.72% miss:

Example
Some possible solutions:
Zero-config?
We realize that Jest's coverageThreshold is more granular, allowing for global and per-glob overrides, but at least mapping the global lines/branches/functions to lcov's genhtml_hi_limit/genhtml_branch_hi_limit/genhtml_function_hi_limit would be a big improvement.
.lcovrc support?
Allow a discoverable .lcovrc (this would allow the use of all lcov config options). Start discovery in package root or sibling to config.js? Or add an --lcovConfig arg alongside --config/-c?
Pitch
Since the coverageThreshold setting is a core setting, and not only supported by a custom reporter, we feel that this belongs here.

@nemoDreamer you can use .istanbul.yml for this purpose.
For Example:
reporting:
    watermarks:
        statements: [50, 90]
        lines: [50, 90]
        functions: [50, 90]
        branches: [50, 90]

Where the firs value is top border for low coverage and the second one is bottom border for high coverage.

I think we can fold this into #4103 - it's basically "configure coverage reporter".


Vdebug causing SIGSEGV in Vim, and jibberish python errors.

To reproduce this error:

Start live Ubuntu-GNOME 16.04
Get vim 7.4
Setup Vdebug for python 3 (I used pydbgp version 11.0.2 from activestate)
start Vdebugingtest.py of github.com/s-c-p/simple-reactive-py
Just keep stepping over and vim will crash at main()

Seg-faults seem to be serious trouble, perhaps similar to https://github.com/vim-vdebug/vdebug/issues/320

Ubuntu Reports
vim.basic crashed with SIGSEGV in PyGC_Collect()
and
vim --version reports
VIM - Vi IMproved 7.4 (2013 Aug 10, compiled Nov 24 2016 16:44:48)
Included patches: 1-1689
Extra patches: 8.0.0056
Modified by<EMAIL_ADDRESS>Compiled by<EMAIL_ADDRESS>Huge version without GUI.  Features included (+) or not (-):
+acl             +farsi           +mouse_netterm   +tag_binary
+arabic          +file_in_path    +mouse_sgr       +tag_old_static
+autocmd         +find_in_path    -mouse_sysmouse  -tag_any_white
-balloon_eval    +float           +mouse_urxvt     -tcl
-browse          +folding         +mouse_xterm     +terminfo
++builtin_terms  -footer          +multi_byte      +termresponse
+byte_offset     +fork()          +multi_lang      +textobjects
+channel         +gettext         -mzscheme        +timers
+cindent         -hangul_input    +netbeans_intg   +title
-clientserver    +iconv           +packages        -toolbar
-clipboard       +insert_expand   +path_extra      +user_commands
+cmdline_compl   +job             -perl            +vertsplit
+cmdline_hist    +jumplist        +persistent_undo +virtualedit
+cmdline_info    +keymap          +postscript      +visual
+comments        +langmap         +printer         +visualextra
+conceal         +libcall         +profile         +viminfo
+cryptv          +linebreak       -python          +vreplace
+cscope          +lispindent      +python3         +wildignore
+cursorbind      +listcmds        +quickfix        +wildmenu
+cursorshape     +localmap        +reltime         +windows
+dialog_con      -lua             +rightleft       +writebackup
+diff            +menu            -ruby            -X11
+digraphs        +mksession       +scrollbind      -xfontset
-dnd             +modify_fname    +signs           -xim
-ebcdic          +mouse           +smartindent     -xsmp
+emacs_tags      -mouseshape      +startuptime     -xterm_clipboard
+eval            +mouse_dec       +statusline      -xterm_save
+ex_extra        +mouse_gpm       -sun_workshop    -xpm
+extra_search    -mouse_jsbterm   +syntax
   system vimrc file: "$VIM/vimrc"
     user vimrc file: "$HOME/.vimrc"
 2nd user vimrc file: "~/.vim/vimrc"
      user exrc file: "$HOME/.exrc"
  fall-back for $VIM: "/usr/share/vim"
Compilation: gcc -c -I. -Iproto -DHAVE_CONFIG_H   -Wdate-time  -g -O2 -fPIE -fstack-protector-strong -Wformat -Werror=format-security -U_FORTIFY_SOURCE -D_FORTIFY_SOURCE=1
Linking: gcc   -Wl,-Bsymbolic-functions -fPIE -pie -Wl,-z,relro -Wl,-z,now -Wl,--as-needed -o vim        -lm -ltinfo -lnsl  -lselinux  -lacl -lattr -lgpm -ldl     -L/usr/lib/python3.5/config-3.5m-x86_64-linux-gnu -lpython3.5m -lpthread -ldl -lutil -lm

Why is nobody seeing this?

The above comment was just to increase number of comments, so on issues pages people will think "Oh! This issue is getting a lot of attention, I should look at it too."

Why is nobody addressing this issue

@s-c-p Sorry I missed this

@learningJava4ds Because time is limited, I'm also doing this in my free time so if you can help fixing bugs please open a Pull Request, that would be more usefull.

@s-c-p So I'm doing the following:
$ sudo pip3 install komodo-python3-dbgp
$ pydbgp -d <IP_ADDRESS>:9000 test.py

The debugger connects properly:

I can properly step to main():

I can step into main():

Eventually I end up having an error stating the debugger is in interactive mode and that is not supported:

Closing because no further feedback


shopify watch doesn't run

Hi all,
Both the shopify_theme gem and the themekit binary have spontaneously developed the same problem for two developers when we setup a new test store using a shopify partner account.
The problem is that running theme watch simply doesn't do anything. It hangs for a moment then brings you back to the terminal command prompt with no error message of any kind.
theme check says "Shopify API is accessible and configuration is valid"
What's going on? I suspect this may have to do with my new partner account store seeing as this issue started when we switched over.
As an aside - this is also another vote for the shopify developers to take a stand on the two competing shopify dev tools (shopify_theme and themekit). It's really crazy that the two projects continue to coexist with no clear messaging on which is the dominant tool moving forward.

After some debugging, I was able to determine that the CLI is erroring out because the APIChecker object is getting a 404 unauthorized on its request to the shopify API. Why?
I definitely have the correct credentials and have set all the permissions to read/write. Any ideas?

I had the same issue. I was able to fix it by setting all permissions on the private app in my store to the highest available.
Shopify folks, can you please:

Update the README to explain what permissions need to be set
Update the shopify_theme gem to give a useful error message in this situation instead of just timing out with no message.


Link to changelog format in PR template

I keep forgetting the new changelog format, so this adds a link to the formatting guidelines in CONTRIBUTING.md to our PR template.
The link replaces the previous link to ./unreleased/ – the directory is empty after cutting a release and not much help (unless I'm overlooking a use case).

Codecov Report

Merging #2035 (3727cb4) into main (7630e98) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main    #2035   +/-   ##
=======================================
  Coverage   77.76%   77.76%
=======================================
  Files         419      419
  Lines       12841    12841
  Branches      586      586
=======================================
  Hits         9986     9986
  Misses       2855     2855

:mega: Codecov can now indicate which changes are the most critical in Pull Requests. Learn more


Tagged template string considered an expression, not a function call

Intro
Template strings are a way to interpolate variables with strings. It's nice, and often more readable than traditional string concatenation
Tagged template strings take this behavior a bit further, and allow functions to be called as if they were strings - but instead the functions receive multiple strings, and a trailing array of positional arguments that the have been used for interpolation. This allows operating on the string and adding all sorts of interesting behavior.
Example
var css = require('sheetify')

// this is a static expression
`
  .js-yellow { color: #f7df1e }
  .bg-js-yellow { background-color: #f7df1e }
`

// this is a function call, which in this case has side effects
css`
  .js-yellow { color: #f7df1e }
  .bg-js-yellow { background-color: #f7df1e }
`

Bug
It appears that standard@9 has introduced a regression where tagged template strings are now considered static expressions - even though they're functions. I think we should probably look into this.
❯ standard
standard: Use JavaScript Standard Style (http://standardjs.com)
  /Users/anon/src/yoshuawuyts/berlinjs/index.js:14:1: Expected an assignm
ent or function call and instead saw an expression.

Thanks!

Thanks for the issue, @yoshuawuyts. This sounds like a bug in ESLint's no-unused-expressions rule. I'll open an issue with them.

Thank you :D
On Fri, Mar 17, 2017, 01:28 Feross Aboukhadijeh<EMAIL_ADDRESS>wrote:

Thanks for the issue, @yoshuawuyts https://github.com/yoshuawuyts. This
sounds like a bug in ESLint's no-unused-expressions
http://eslint.org/docs/rules/no-unused-expressions rule. I'll open an
issue with them.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/feross/standard/issues/822#issuecomment-287232687,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ACWleuW4Kz7xzeDtLmEPlVyQ_a9AFqneks5rmdOcgaJpZM4Mf-lN
.

Issue filed here: https://github.com/eslint/eslint/issues/8268

They actually already have a PR out that adds an option to ignore tagged template literals: https://github.com/eslint/eslint/pull/8253 When that makes it into a release, I'll add the option and publish a new version on the v9 line.

@feross FYI, today's release will most likely contain this fix!

@vitorbal Excellent! Just saw that. I'll do a standard as soon as the ESLint release is out. 👍

Fix published as 9.0.2.
(Also, for users of the v10 beta, published as 10.0.0-beta.2.)

Hi, I still get an error on this line :
errors.push[`Missing Parameter : ${requiredParams.name}`]

I'm using VSCode and this extension : https://marketplace.visualstudio.com/items?itemName=chenxsan.vscode-standardjs
that uses my global install of standard
From the doc :
To use JavaScript Standard Style in this workspace please install standard using 'npm install standard' or globally using 'npm install -g standard'.
You need to reopen the workspace after installing standard.)

the error I'm getting is :
[standard] Expected an assignment or function call and instead saw an expression. (no-unused-expressions)
let errors: any[]


Added the static wado client access to OHIF v2

Run against the static-wado for local access.
@swederik - who do you want looking at v2 changes?

@igoroctaviano - here is the first of a bunch of small changes.  I believe the failing checks are race condition ones.


Fix unit tests culture

What does the pull request do?
This PR fixes some tests that are now failing after #12876 if the current culture doesn't use a dot as a decimal point.
These tests already had a InvariantCultureFixture, which likely only work in the past with the .NET Framework (which didn't flow the current culture through the execution context, IIRC). This is now replaced by an InvariantCultureAttribute, setting the culture right before a test is run.

You can test this PR using the following package version. 11.0.999-cibuild0039972-beta. (feed url: https://nuget-feed-all.avaloniaui.net/v3/index.json) [PRBUILDID]


ze_kernel_max_group_size_properties_ext_t does not have a defined structure type

ze_kernel_max_group_size_properties_ext_t does not have its type defined in ze_structure_type_t (should be ZE_STRUCTURE_TYPE_KERNEL_MAX_GROUP_SIZE_PROPERTIES_EXT)

thanks @Kerilk . Actually, we have another error here: the correct suffix should be ext_properties_t. https://spec.oneapi.io/level-zero/latest/core/EXT.html#naming-convention. But we cannot change that w/o breaking compatibility. I will add the stype and think how to fix the issue with wrong naming convention.

Indeed.
I think adding a type alias would solve your issue:
typedef ze_kernel_max_group_size_ext_properties_t ze_kernel_max_group_size_properties_ext_t;


Add xcframeworks test case

Summary
Adding some test cases for xcframeworks. Currently, it looks like virtual frameworks and xcframeworks have some issues when used together. In the example test case I've added, if you run:
bazel build tests/ios/xcframeworks --apple_platform_type=ios

The build will pass without issues.
However, if you then enable virtual frameworks:
bazel build tests/ios/xcframeworks --apple_platform_type=ios --features apple.virtualize_frameworks

You will see an error about a missing type. I'd like to understand why this happens and see if we can fix this up. I've only noticed this issue for the Plaid xcframework so far.

This PR depends on #511


Jackhmmer failed without error message

Hi, I have one run that failed at the Jackhmmer step while the other run passed it. The one failed did not give any error message. But I guess it might be related to memory. Just in case you wanna debug it, I'm attaching the info for reproducing it.
The one failed
The requested node parameter: one A100, 2GB RAM, 1vCPU.
Log:
...
I0526 10:11:57.089518<PHONE_NUMBER>9232 utils.py:36] Started Jackhmmer (uniref90.fasta) query

I0526 10:34:06.416362<PHONE_NUMBER>9232 utils.py:40] Finished Jackhmmer (uniref90.fasta) query in 1329.325 seconds
Traceback (most recent call last):
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/alphafold/run_alphafold.py", line 422, in <module>
    app.run(main)
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/miniconda3/envs/alphafold_v2.2.0/lib/python3.8/site-packages/absl/app.py", line 312, in run
    _run_main(main, args)
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/miniconda3/envs/alphafold_v2.2.0/lib/python3.8/site-packages/absl/app.py", line 258, in _run_main
    sys.exit(main(argv))
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/alphafold/run_alphafold.py", line 398, in main
    predict_structure(
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/alphafold/run_alphafold.py", line 172, in predict_structure
    feature_dict = data_pipeline.process(
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/alphafold/alphafold/data/pipeline_multimer.py", line 264, in process
    chain_features = self._process_single_chain(
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/alphafold/alphafold/data/pipeline_multimer.py", line 212, in _process_single_chain
    chain_features = self._monomer_data_pipeline.process(
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/alphafold/alphafold/data/pipeline.py", line 163, in process
    jackhmmer_uniref90_result = run_msa_tool(
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/alphafold/alphafold/data/pipeline.py", line 94, in run_msa_tool
    result = msa_runner.query(input_fasta_path, max_sto_sequences)[0]  # pytype: disable=wrong-arg-count
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/alphafold/alphafold/data/tools/jackhmmer.py", line 171, in query
    single_chunk_result = self._query_chunk(
  File "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/alphafold/alphafold/data/tools/jackhmmer.py", line 142, in _query_chunk
    raise RuntimeError(
RuntimeError: Jackhmmer failed
stderr:
$

The one passed
The requested node parameter: four A100, 64GB RAM, 32vCPU.
Log:
I0526 10:15:50.349001<PHONE_NUMBER>9104 utils.py:36] Started Jackhmmer (uniref90.fasta) query
I0526 10:23:10.575799<PHONE_NUMBER>9104 utils.py:40] Finished Jackhmmer (uniref90.fasta) query in 440.226 seconds
I0526 10:23:36.492806<PHONE_NUMBER>9104 jackhmmer.py:133] Launching subprocess "/sw/csg/alphafold/2.2.0/el7.9_python_jupyter/miniconda3/envs/alphafold_v2.2.0/bin/jackhmmer -o /dev/null -A /tmp/tmp6ao2aae4/output.sto --noali --F1 0.0005 --F2 5e-05 --F3 5e-07 --incE 0.0001 -E 0.0001 --cpu 8 -N 1 /tmp/tmpu5uqvbyz.fasta /ibex/ai/reference/alphafold/2.1.1/all_alphafold_data/mgnify/mgy_clusters_2018_12.fa"

I have the same problem, did I you fix it?

It did not happen often later. So, I did not fix it.

已收到，谢谢！


No more than 1 PV-inverter?

Hi, I am using a couple of decentralized Hoymiles invertes additionally to my Victron MPPT loader. They are all nicely integrated into Victron via the openDTU.
The integration manages to find the find first one, but only one. The others don't show up as devices.

Hello @AminShAT,
Most likely the unit ID of your other pv inverters isn't being scanned by the 0.1.7 release.
The main branch contains code that will most likely cause your pv inverters to be detected correctly.
You can install this via going to:

HACS

Selecting the hass-victron integration

Selecting the hamburger menu in the top right.

Selecting redownload

Clicking the drop down and selecting main as the version

Clicking download

Restarting HA
Rescanning all available devices

Please let me know if after installing the main version your other PV inverters are being correctly detected

Hello, thanks for your detailed instructions. I followed them, but to no avail so far.
Here are a few screenshots:
Installed version of the Victron integration

Found devices

List of openDTU inverters registered in the Cerbo

That would also be helpfull as a future test.
Please see https://github.com/victronenergy/dbus_modbustcp/blob/master/CCGX-Modbus-TCP-register-list.xlsx for a list of unit id's that victron is supposed to expose.
Just to confirm, have you managed to get the pvinverter detected with the latest main version?
Since there are also other users (with for example issue #137) that report unit's with id 35 and 36 not being found.
If you are able to get it detected with id 35 in the latest main version it would allow me to create an release that would solve unit detection issues for a lot of people.

Unfortunately not. I tried both. Switching to 101-103 and leaving at 34-36. in both cases, it shows only the one at 34. even when switching to 101-103 it does not find anything new and still claims to have only one at 34.

Could you perhaps send me another screenshot of the installed commit with which you performed the test?
And just to confirm the manual triggered rescan only resulted in 34 being found as a device?

Apologies, I was too quick in clicking. Seems, you need to wait until the right version is really selected before installing.
I tried now with 34-36 and all inverters are found.

No worries, I've made the same mistake in the past :).
Thanks for testing and your quick replies.
Great to hear that units 35 and 36 are now discovered by the integration.
This means that in the next release a lot of unit id related issues are going to be closeable. #8 #36 #137 and possibly #129, #157, #179.

The release (v0.2.0) has been shipped.
Closing issue, feel free to re-open if the issue persists with the new release

I got a forth microinverter meanwhile. It is at ID 37, but is not found by the integration. I think you only included up to 36.
Is it possible to add the numbers above as well? I will get even 2 more microinverters, so a total of 6 (range 34 - 39).
Thanks in advance
Amin

Hello Amin,
Please open a new issue so that this can be tracked seperately.


Update workflow branch and add the unit test badge back to README.md

Overview
A few things to twiddle.
Deliverables

[x] Update the workflow branch
[x] Add the coverage badge back to the README.md

Work for this issue will begin begin on branch work-liquid-labs/regex-repo/15.


Add Header content control template for Fluent and Simple themes

What does the pull request do?
The HeaderedContentControl does not currently have any template. This adds one to both the Simple and Fluent themes. As was discussed in https://github.com/AvaloniaUI/Avalonia/discussions/7875
It also adds a new page to the Control Catalogue with some examples showing how to use HeaderedContentControl.
What is the current behavior?
Currently there is no template at all for HeaderedContentControl, which makes any attempt to use it render non-tangible content.
What is the updated/expected behavior with this PR?
The control should now show a header and content according to their templates and header/content values when using the Simple or Fluent themes.
How was the solution implemented (if it's not obvious)?
A new template was added to the Simple and Fluent themes.
Checklist

[ ] Added unit tests (if possible)?
[ ] Added XML documentation to any related classes?
[ ] Consider submitting a PR to https://github.com/AvaloniaUI/avalonia-docs with user documentation

Breaking changes
None known. But it's possible it may cause some issues with people who have themed the control themselves previously.
Obsoletions / Deprecations

Fixed issues

Fixes https://github.com/AvaloniaUI/Avalonia/discussions/7875

You can test this PR using the following package version. 11.0.999-cibuild0040016-beta. (feed url: https://nuget-feed-all.avaloniaui.net/v3/index.json) [PRBUILDID]

You can test this PR using the following package version. 11.0.999-cibuild0040020-beta. (feed url: https://nuget-feed-all.avaloniaui.net/v3/index.json) [PRBUILDID]

You can test this PR using the following package version. 11.0.999-cibuild0040058-beta. (feed url: https://nuget-feed-all.avaloniaui.net/v3/index.json) [PRBUILDID]

You can test this PR using the following package version. 11.0.999-cibuild0040156-beta. (feed url: https://nuget-feed-all.avaloniaui.net/v3/index.json) [PRBUILDID]


Some statistics are not correct after reopen

After reopen, live blob file num/size is zero.

It is because we initialize the stats_ after vset_->Open.

/cc @tabokie


How to get cookies?

how to get cookies, like steamlogin,steamloginsecure using this code?

This is a class for Steam's OpenID login, not logging into steam itself.


make TLS config params can be setup in the file

Signed-off-by: Frank Yang<EMAIL_ADDRESS>
Ⅰ. Describe what this PR did
make TLS config params can be setup in the config file which introduce by falg --config-file
Ⅱ. Does this pull request fix one issue?

Ⅲ. Describe how you did it
Ⅳ. Describe how to verify it
Ⅴ. Special notes for reviews
@Ace-Tang

Codecov Report

Merging #1126 into master will decrease coverage by <.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #1126      +/-   ##
==========================================
- Coverage   15.74%   15.74%   -0.01%
==========================================
  Files         172      172
  Lines        9648     9630      -18
==========================================
- Hits         1519     1516       -3
+ Misses       8020     8005      -15
  Partials      109      109

Impacted Files
Coverage Δ

client/client.go
30% <0%> (-9.4%)
:arrow_down:

pkg/kernel/kernel.go
72.72% <0%> (-7.28%)
:arrow_down:

cli/cli.go
0% <0%> (ø)
:arrow_up:

ctrd/client.go
0% <0%> (ø)
:arrow_up:

LGTM.
Since encoding/json cannot do the trick with ">some>deep>childnode" like encoding/xml can do. Nested structs is the way to go.

I want to re-implement daemon config merge function.


Error: Cannot find page for "STATICBUILDER_URL_PREFIX/STATICBUILDER_URL_PREFIX"

Hello, I cannot get this plugin to work.
I keep getting redirected to: http://localhost:8000/STATICBUILDER_URL_PREFIX/STATICBUILDER_URL_PREFIX every time I click on "build everything"
If I try to build a single page, I'm not redirected but an error is shown on the page:
Error: Cannot find page for "STATICBUILDER_URL_PREFIX/STATICBUILDER_URL_PREFIX"

It happens on both PHP 5.5 and 7.0
Already tried #17 but same result.
PS: the site is multilingual and I'm using the one-pager solution from Kirby's cookbook I'm not sure if that is related. (anyway, regarding this one-pager solution, I was already counting on merging the .html files after building, but I wonder if your plugin is capable of finding out that each page is being served as a section)
Thanks

Oh no, I'm so sorry, nevermind all this.
It only occurred to me after posting.
If it is a one-pager I just need to Build the homepage!!!! I was slow sorry.
Building the homepage worked.
So sorry.


Merge edge degree filtering feature into master

This feature is ready to be merged into master. It is working, tested, and documented.
Unless there are further concerns, I will release this shortly as v1.3.0.

Coverage increased (+0.2%) to 94.267% when pulling e9fee81d51d2915a1867e8ddfd34d79992e6e7a2 on edge_degree_filtering into 3429b9a747d4d169ee558f09064336844de5b95a on master.

Coverage increased (+0.2%) to 94.267% when pulling 55907b37b00e970ed1e820b72bfe964a37366f17 on edge_degree_filtering into 3429b9a747d4d169ee558f09064336844de5b95a on master.

Coverage increased (+0.2%) to 94.267% when pulling 55907b37b00e970ed1e820b72bfe964a37366f17 on edge_degree_filtering into 3429b9a747d4d169ee558f09064336844de5b95a on master.


Remove Base58PublicKey and replace PublicKey with that impl

After #453, the alias of PublicKey to Vec<u8> can be replaced with the Base58PublicKey type so we don't need two types for the same functionality (one only for JSON serde impl).
cc: @ChaoticTempest https://github.com/near/near-sdk-rs/pull/453#issuecomment-871037521

Note that the right name for the thing is PublicKey, Base58 prefix is not needed.


Baaaad x space?

this is showing up in
Amstelvar-Roman-VF
https://videoproof.typenetwork.com/compositions, 26 point that doesn't exist in the font. the x spacing is very bad, and I think it's weird....


Update archlinux.md so it renders section title correctly

Describe the proposed changes
As reading through the installation guide, I found that the Uninstallation is render as "## Uninstallation". This seems to be the result of lack of newline before the ## Uninstallation in the md file. Thus, I just basically add a newline there.
See the website for the issue.
Project version
Not really sure. It may apply to all version that support uninstallation.
Related issue
None.
Related issue or PR in another project
None.
Please take a look
None.
Add newline before the Uninstallation section since it is displayed as the raw text (## Uninstallation) on the website.

Thanks, @krerkkiat !


Feature: optionally return secret contents to driver instead of writing files

The driver's gRPC interface has been expanded to allow providers to return a view of the filesystem in the RPC response, making the driver responsible for writing the files to the actual mount.
Creating this bug as the AWS-specific version of https://github.com/kubernetes-sigs/secrets-store-csi-driver/issues/551

Thank you for your feedback. We have noted this as a feature request.

Sorry for the delay. This has been pushed in PR 33.


HTTP connector documentation missing

Link to article:
https://docs.microsoft.com/en-us/connectors/
Problem:
The documentation for the built-in HTTP connector (for Power Automate, Power Apps, and Logic Apps) is missing entirely from the site. Similar connectors (e.g., FTP) are fully-documented, but HTTP is... just missing.

@delfuego Do you mean HTTP with Azure AD at https://docs.microsoft.com/en-us/connectors/webcontents/ ?

@rootsmusic No, a year-plus ago, I meant the straight, plain "HTTP" connector… which now, a year-plus later, appears to have disappeared, at least in our tenant. And was replaced by the "HTTP with Azure AD" connector, which (of course) is a premium connector... meaning that users no longer have any way to just make a straight HTTP call. sigh

@delfuego You can complain by clicking on the button at the bottom of https://docs.microsoft.com/en-us/connectors/webcontents/

(Sorry @delfuego, the doc's author isn't the connector's developer.)  You can suggest a connector on the product's ideas forum.


"Unimatics"

I've deliberately avoided extended character sets so far as this gets into a whole heap of encoding/decoding pain.  However, it might be that UTF-8 does the trick now, though, and I could move to full unicode.
Support for UTF8 in Linux and OSX looks pretty well established.  However,  Windows support is suspect.  Although there is codepage 65001, it would appear the glyphs are very limited.  More investigation required...

In addition to box characters, the new version could also use braille characters for line drawing like https://github.com/yaronn/blessed-contrib

Had a little play on Windows/3.x and Linux/2.7.  Looks like output isn't too bad.  I've already got some basic box characters working!  Windows needs work to get up and running - e.g. chcp 65001 plus a custom font install for extended unicode chars - as per http://webservices20.blogspot.co.uk/2015/04/running-terminal-dashboards-on-windows.html
And input is going to be harder...  Curses on Python (up to 3.3) only offers getch() which is now unicode aware, so I'm going to have to do some byte stream parsing before handing off to a codec.  It looks like Windows may need the same unless we pass the unicode char form of key events all the way through.

And it's really easy to mess up unicode cross-version compatilibiity in Python.  Sigh.  Make sure to check against http://python-future.org/compatible_idioms.html

Turns out Windows input is tricky.  The input for Unicode characters pasted into the console doesnt generate key down events, just key up.  However, standard input only guarantees to get key down in the right order and uses key down for repeats.  In an attempt to be future proof, I've therefore taken to tracking which keys are pressed and just assuming random injected key ups need to be processed as new key presses.  See https://github.com/peterbrittain/asciimatics/commit/58a14c7bdb1b60177f49ff2d4b755ffca2cdb8ae for details.

OK - it looks like getch() returns the byte stream, which can be passed to a UTF-8 decoder for curses.  First pass of doing this done in https://github.com/peterbrittain/asciimatics/commit/cea0a94f939769a392b541f4c4dfba2410678449

Ok, so we have proved unicode input and output is possible... What's left before closing this?

A simple way to set/check whether unicode should be used.
Updates to some effects to use better characters when unicode is enabled - box chars, snowflakes, stars, ticks and braille chars for lines.
Docs for the new feature - including README and CHANGES

It might be worth checking out the future package which offers Python3 semantics for Python2 constructs, including some support to the str/unicode.

Already using it, but thanks for checking!

I've now added a unicode_aware flag for Screen construction, that can be accessed by all other objects to decide whether to display unicode or not.  Next step on that front is to try to provide an auto-detect mode (rather than defaulting to False).
I've also played some more with using unicode chars for slicker output.  Looks like FreeMono isn't great on Windows.  Might be worth finding another...  Perhaps http://dejavu-fonts.org/wiki/Main_Page

Yup - DejaVu looks a lot better and joins its box chars...  Windows looks fine with this font and now auto detects utf-8 support based on use of the 65001 code page.

Unicode is now ready and waiting!


Support half-open connections (FIN)

This is particularly useful for some TCP/IP-based protocols where the client sends a FIN message to the server indicating that it will no longer write any data but is still willing to accept incoming data.
Opening this ticket as a reminder and to spark the discussion - the implementation likely depends on  https://github.com/reactphp/stream/issues/27

Hi guys!
I started to work on this. While still not sure if I can finish, I think I got some results by changing React\Stream\WritableResourceStream::close() and replacing lines:
 if (is_resource($this->stream)) {
    fclose($this->stream);
}

with
@stream_socket_shutdown($this->stream, 1);
stream_set_blocking($this->stream, false);

i.e. keeping it readable in DuplexResourceStream.
Do you think this is a reasonable direction?

@pronskiy Thank you for looking into this! Sounds like this makes perfect sense on a lower level. This will likely cause a number of tests to fail, but this can probably shouldn't be too much work either. But I'm really curious how this could be exposed API-wise. Have you looked into this yet?

@clue I plan to submit some draft for your consideration so that we have a basis for discussion.

@clue here are couple PRs with an early draft. Basically, I add $options array as a parameter to various classes' costructor. It's kinda bad because the same array is passed from one class to another. I'm thinking of how to improve it. What do you think of such direction?

I still think that this feature makes perfect sense :+1: However, there are currently no immediate plans to build this from my end (no demand at the moment and more important outstanding issues currently), but I suppose we would be happy to accept PRs in case anybody feels there's a need for this :+1:


docs(readme): Add badges

Add some badges
Also should we remove the LICENSE and Downloads section at the bottom?

@rajarsheechatterjee  Discord server widget needs to be enabled for that badge to work

I should update the screenshots as well.


feat: Ignore __doc__ from parent classes

Closes  #55.

Seems like some or all of the CI failures are occurring on master too, and so are unrelated to this change.

make format works.
make check fails on master and on these changes with the same error:TypeError: __init__() missing 1 required positional argument: 'metrics'

make test runs all of the tests without failure:will ~/workshop/griffe (master) $ make test
> Currently selected Python version: python3
> pdm run duty test (python3.7)
✓ Running tests
> pdm run duty test (python3.8)
✓ Running tests
> pdm run duty test (python3.9)
✓ Running tests
> pdm run duty test (python3.10)
✓ Running tests
> pdm run duty test (python3.11)
✓ Running tests
> Restored previous Python version: python3

Yeah don't worry about CI :slightly_smiling_face:


Python: Add http header parameter in AzureChatCompletion function

For python, could we add http header parameter in AzureChatCompletion function? We need to pass "X-User-Id" when calling Azure open AI chat complete function.
In C# version, we can pass a httpcllient parameter to WithAzureChatCompletionService.

This is now possible by using the AsyncAzureOpenAI option for the AzureChatCompletion class, thereby you create your own instance of the OpenAI client class with the required settings, including additional headers. @alexChiu127 does that work for you or do you also expect to be able to use a parameters on the AzureChatCompletion class itself?


How I can train setfit model on my Apple M1 Mac GPU?

Hi,
I have been trying to train setfit model on Apple M1 Mac but I guess it is using CPU to train. I have installed pytorch dependencies for M1 GPU to work but I can't see that in working with Setfit.
Can you please help to make train the setfit model on Apple M1 mac GPU ?
Also,If I train on NVIDIA GPU do I need to specify any device parameter set to "cuda" before training setfit model or it is automatically handled?

Hello! It is my understanding that a model is automatically placed on GPU if that is available. However, you can also use model.to("cuda") to be sure that it's correct.
model = SetFitModel.from_pretrained("...")
model.to("cuda")
trainer = SetFitTrainer(
    model=model,
    ...
)

One way to verify whether the model is indeed on GPU is through
print(model.model_body)

And you can verify that torch is indeed compiled with CUDA through:
import torch
print(torch.cuda.is_available())

Hello! It is my understanding that a model is automatically placed on GPU if that is available. However, you can also use model.to("cuda") to be sure that it's correct.
model = SetFitModel.from_pretrained("...")
model.to("cuda")
trainer = SetFitTrainer(
    model=model,
    ...
)

One way to verify whether the model is indeed on GPU is through
print(model.model_body)

And you can verify that torch is indeed compiled with CUDA through:
import torch
print(torch.cuda.is_available())

Hope this helps a bit,
Tom Aarsen

Thanks @tomaarsen
This would work in NVIDIA GPU with CUDA enabled.
How I can transfer the model in M1 Mac to be used by it M1 GPU?

Oops, my apologies, I believe you would need to use model.to("mps").

Oops, my apologies, I believe you would need to use model.to("mps").

Thanks @tomaarsen
I have following doubt.

How we can plot confusion matrix or classification report and score for F1, RECALL and precision?
How I can get confidence score for the predictions?

Please help me on this.
Thanks

You can evaluate a SetFitModel using SetFitTrainer.evaluate(). This uses the metric provided to the SetFitTrainer, which is either an evaluate metric like "f1":
# Create trainer
trainer = SetFitTrainer(
    model=model,
    train_dataset=train_dataset,
    eval_dataset=eval_dataset,
    metric="f1",
)

or a function called with two arguments (y_pred, y_test). You can write any function that you'd like here, i.e. one that uses sklearn.metrics.confusion_matrix.
Example script
from datasets import load_dataset
from sentence_transformers.losses import CosineSimilarityLoss

from setfit import SetFitModel, SetFitTrainer, sample_dataset
from sklearn.metrics import confusion_matrix

# Load a dataset from the Hugging Face Hub
dataset = load_dataset("sst2")

# Simulate the few-shot regime by sampling 8 examples per class
train_dataset = sample_dataset(dataset["train"], label_column="label", num_samples=8)
eval_dataset = dataset["validation"]

# Load a SetFit model from Hub
model = SetFitModel.from_pretrained("sentence-transformers/paraphrase-mpnet-base-v2")

def confusion_matrix_metric(y_pred, y_test) -> None:
    matrix = confusion_matrix(y_test, y_pred)
    print(matrix)

# Create trainer
trainer = SetFitTrainer(
    model=model,
    train_dataset=train_dataset,
    eval_dataset=eval_dataset,
    metric=confusion_matrix_metric,
    column_mapping={"sentence": "text", "label": "label"},  # Map dataset columns to text/label expected by trainer
)

# Train and evaluate
trainer.train()
metrics = trainer.evaluate()

Which produces
Applying column mapping to training dataset
Generating Training Pairs: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 20/20 [00:00<00:00, 9210.15it/s]
***** Running training *****
  Num examples = 640
  Num epochs = 1
  Total optimization steps = 40
  Total train batch size = 16
Iteration: 100%|███████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 40/40 [00:04<00:00,  9.07it/s]
Epoch: 100%|█████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████████| 1/1 [00:04<00:00,  4.41s/it]
Applying column mapping to evaluation dataset
***** Running evaluation *****
[[368  60]
 [ 48 396]]

As for 2, we you can use model.predict_proba to get the probabilities for each of the classes:
>>> model.predict_proba(["This movie was amazing", "That film was bad!"])
tensor([[0.0414, 0.9586],
        [0.9369, 0.0631]], dtype=torch.float64)

Tom Aarsen

You can evaluate a SetFitModel using SetFitTrainer.evaluate(). This uses the metric provided to the SetFitTrainer, which is either an evaluate metric like "f1":
# Create trainer
trainer = SetFitTrainer(
    model=model,
    train_dataset=train_dataset,
    eval_dataset=eval_dataset,
    metric="f1",
)

or a function called with two arguments (y_pred, y_test). You can write any function that you'd like here, i.e. one that uses sklearn.metrics.confusion_matrix.
Example script
As for 2, we you can use model.predict_proba to get the probabilities for each of the classes:
>>> model.predict_proba(["This movie was amazing", "That film was bad!"])
tensor([[0.0414, 0.9586],
        [0.9369, 0.0631]], dtype=torch.float64)

Tom Aarsen

Thankyou so much @tomaarsen

Glad to help! I'll close this for now, as I think this should be solved!


Use external POS-Taggers into the parser

It might be interesting for people to add and document how they could add their POS-Taggers.
I red somewhere someone was able to use Standford's (see #13 ), it might be great if you can document this !

I'm interested to help with this


Display numbers in hex, binary, etc

Hi. Nice project, love the programmer-friendly bit manipulation. However, this was a little disappointing:
mathcat> 0b1101001 << 1
210

I wish I could get the result out in bits/hex/etc.

Hi, thanks for the feedback.
I like this idea, perhaps add a command like @mode <mode> where <mode> is decimal, hex or binary. It would be difficult and perhaps undesireable to automatically return the result in for example binary if binary happens to be used in the expression.

Yeah. Though I can't help but wonder what would happen if one treats the output format of a number a "sticky" property as values are passed through computation, with combining rules in the spirit of Go's untyped constants.
mathcat> 0b1
0b1
mathcat> 0b1 + 1    ("untyped" 1)
0b10

Then have rules that say which one wins in case of multiple conflicting ones; e.g.
mathcat> 0b1 + 0d1
2  (decimal wins)
mathcat> 0b1 + 0d1
0b10  (left one wins)
mathcat> 0b1 + 0d1
2  (right one wins)

(Instead of my invented 0d42 decimal literal format, you could also do just dec(42))
Right one wins has the nice property that you can often arrow-up, +0b0, enter to change the format. Kinda like how some dynamic languages do data types. Not sure if that's a good idea ;)

That would be ideal, but tough to implement as the parser has no concept of hex, binary or decimal, everything is a float in the end. I'm sure it's doable though. For example by lexing it first and checking the most common type of literal, since the lexer is aware of the type literal.
I'll have to look into this some more, if you have any ideas I'd be glad to hear them.


Shaka player not picking up lower quality / other variants when url of one variant does not respond

Have you read the FAQ and checked for duplicate open issues?
Yes
What version of Shaka Player are you using?
v4.2.1
Can you reproduce the issue with our latest release version?
Yes
Can you reproduce the issue with the latest code from main?
Did not check
Are you using the demo app or your own custom app?
Custom app
If custom app, can you reproduce the issue using our demo app?
Yes
What browser and OS are you using?
Mac M1 Pro 2021, Chrome 107.0.5304.110
For embedded devices (smart TVs, etc.), what model and firmware version are you using?
Originally happening on Smart TVs, but reproducible on Macs as well.
What are the manifest and license server URIs?

NA
What configuration are you using?  What is the output of player.getConfiguration()?

{   "drm": {     "retryParameters": {       "maxAttempts": 2,       "baseDelay": 1000,       "backoffFactor": 2,       "fuzzFactor": 0.5,       "timeout": 30000,       "stallTimeout": 5000,       "connectionTimeout": 10000     },     "parseInbandPsshEnabled": false   },   "manifest": {     "retryParameters": {       "maxAttempts": 2,       "baseDelay": 1000,       "backoffFactor": 2,       "fuzzFactor": 0.5,       "timeout": 30000,       "stallTimeout": 5000,       "connectionTimeout": 10000     },     "dash": {       "clockSyncUri": "",       "ignoreDrmInfo": false,       "disableXlinkProcessing": false,       "xlinkFailGracefully": false,       "ignoreMinBufferTime": false,       "autoCorrectDrift": true,       "initialSegmentLimit": 1000,       "ignoreSuggestedPresentationDelay": false,       "ignoreEmptyAdaptationSet": false,       "ignoreMaxSegmentDuration": false,       "keySystemsByURI": {         "urn:uuid:1077efec-c0b2-4d02-ace3-3c1e52e2fb4b": "org.w3.clearkey",         "urn:uuid:e2719d58-a985-b3c9-781a-b030af78d30e": "org.w3.clearkey",         "urn:uuid:edef8ba9-79d6-4ace-a3c8-27dcd51d21ed": "com.widevine.alpha",         "urn:uuid:9a04f079-9840-4286-ab92-e65be0885f95": "com.microsoft.playready",         "urn:uuid:79f0049a-4098-8642-ab92-e65be0885f95": "com.microsoft.playready",         "urn:uuid:f239e769-efa3-4850-9c16-a903c6932efb": "com.adobe.primetime"       },       "sequenceMode": false     },   },   "streaming": {     "retryParameters": {       "maxAttempts": 2,       "baseDelay": 1000,       "backoffFactor": 2,       "fuzzFactor": 0.5,       "timeout": 30000,       "stallTimeout": 5000,       "connectionTimeout": 10000     },     "rebufferingGoal": 2,     "bufferingGoal": 10,     "bufferBehind": 30,     "ignoreTextStreamFailures": false,     "alwaysStreamText": false,     "startAtSegmentBoundary": false,     "gapDetectionThreshold": 0.5,     "durationBackoff": 1,     "forceTransmux": false,     "safeSeekOffset": 5,     "stallEnabled": true,     "stallThreshold": 1,     "stallSkip": 0,     "useNativeHlsOnSafari": true,     "inaccurateManifestTolerance": 2,     "lowLatencyMode": false,     "autoLowLatencyMode": false,     "forceHTTPS": false,     "preferNativeHls": false,     "updateIntervalSeconds": 1,     "dispatchAllEmsgBoxes": false,     "observeQualityChanges": false,     "maxDisabledTime": 30,     "parsePrftBox": false   },   "abr": {     "enabled": true,     "useNetworkInformation": true,     "defaultBandwidthEstimate": 1000000,     "switchInterval": 8,     "bandwidthUpgradeTarget": 0.85,     "bandwidthDowngradeTarget": 0.95,     "restrictions": {       "minWidth": 0,       "maxWidth": null,       "minHeight": 0,       "maxHeight": null,       "minPixels": 0,       "maxPixels": null,       "minFrameRate": 0,       "maxFrameRate": null,       "minBandwidth": 0,       "maxBandwidth": null     },     "advanced": {       "minTotalBytes": 128000,       "minBytes": 16000,       "fastHalfLife": 2,       "slowHalfLife": 5     },     "restrictToElementSize": false,     "restrictToScreenSize": false,     "ignoreDevicePixelRatio": false   },   "autoShowText": 3,   "preferredAudioLanguage": "",   "preferredTextLanguage": "",   "preferredVariantRole": "",   "preferredTextRole": "",   "preferredAudioChannelCount": 2,   "restrictions": {     "minWidth": 0,     "maxWidth": null,     "minHeight": 0,     "maxHeight": null,     "minPixels": 0,     "maxPixels": null,     "minFrameRate": 0,     "maxFrameRate": null,     "minBandwidth": 0,     "maxBandwidth": null   }, }
What did you do?

Stop one mp4 chunk of one variant from responding. It is not blocked, but the server does not respond.
NOTE: Player works fine if the server is very slow and some part of variant gets downloaded. It switches to lower bitrate and tries to play it. 1003 error is seen in our production environment, and above is a simulation which may be what is occurring in production.
What did you expect to happen?
Shaka player should try playing a different variant (preferable lower?)
What actually happened?

Shaka player throws 1003 error without trying for another variant.

There's more information about it here #4728
The case that's causing issues for me is segments that are in the manifest but files are missing, returning 404. This results in a BAD_HTTP_STATUS (1001) as demonstrated by that issue ^, but I also mentioned that I thought TIMEOUT (1003) should be covered by this.
Then I started making a PR, and the tests intentionally used TIMEOUT as the invalid event, which made me hesitate as I'm not sure there might be

I feel this is not an issue, Since the demo version is general and minimalistic, It doesn't handle such cases and allows us to manually handle that. You can add a listener for this event and add your custom logic, for example switching down to a lower resolution playback set!

I feel this is not an issue, Since the demo version is general and minimalistic, It doesn't handle such cases and allows us to manually handle that. You can add a listener for this event and add your custom logic, for example switching down to a lower resolution playback set!

The functionality being requested here already exists in Shaka. It's just the condition (one line of code) that's keeping it from being used here.


Fix create_object_pool C++ client for affinity set

Summary
Before, we called CHECK_FORMAT checking the cmd_tokens to a maximum of 4 tokens. However, if a user supplies an affinity set regex string, this will be marked as invalid. This PR simply changes the maximum to 5 tokens.
This is a simple one line change.

Ignore this - read the syntax for the comamnd wrong, sorry.


Refactor forms.py (Work in progress)

Objectives
This PR is a refactor of forms.py.
The immediate objectives of this refactor are listed in the section titled "Code Changes".
The longer-term objective of this refactor is to move toward using AdminAttributes internally. A lot of the code right now is hard to manage because there is no concept that relates a single SQLA/wtforms field/column/property. Ultimately, a List[AdminAttribute] should be generated by the ModelAdmin() instance, instead of inside get_model_form().
In my opinion, more and more parsing/app logic should move toward AdminAttribute internals, and then the rest of the code can focus more on the core framework logic. Right now, a lot of parsing, and generation of defaults, is being handled at multiple parts of the code. AdminAttribute can be a single spot for all the "ugly but necessary" stuff, and the rest of the code (the parts we want to actually add features) will be cleaner as a result.
Code Changes
Consistent typing:

Create a ConverterCallback type with a sensible signature. (In this case, pulled from Flask-Admin's pattern.)
Apply the signature to decorated @converts(...) methods.
wtforms has very weird typing (or rather, a lack of typing). I added a type for the wtforms validators. I got the type right (check wtforms/validators.py), but it's unclear whether this is appropriate.

Renames
Converter Callbacks
The main purpose of the renaming in this refactor is to enforce the distinction between a converter and a converter callback. The class is called ModelConverter, which implies that a ModelConverter() object is the converter. But, in the code, get_converter() does not get a converter instance, it gets a callable that is not a converter per se (based on the convention that a ModelConverter is a converter.
To have consistent naming, the function should be called a "converter callback," to distinguish it from the converter class. All references to the decorated functions should then make clear that these are "converter callbacks" and not mere "converters."

ModelConverterBase.get_converter() --> ModelConverterBase.get_callback()
ModelConverterBase.converters --> ModelConverterBase._callbacks
Create a type called ConverterCallback to reinforce both the concept and the signature.

Property vs attribute
mapper.attrs misleadingly returns objects of type Union[ColumnProperty, RelationshipProperty]. I think we should move toward referring to objects with this typing as props. In the function get_model_form, I adhere to this behavior. (Although I don't make any additional changes in the rest of the code.)

It's possible even if this is good enough that it should be merged into a dev branch.
I don't think anyone is going that deep into this project's internals yet, but it is possibly breaking of existing workflows.

Thanks for the effort @dwreeves . I think the refactoring is a good idea, but I suggest to split it into multiple PRs so that we can review this more quickly. Do you think that's possible?

I'll think about it, but I'm having a hard time figuring out what I should split out of this PR. This was as atomic as I could get it; I only touched forms.py and deliberately did not touch models.py.

I think the titles you mentioned make sense, so maybe start with the renaming callbscks, then typing improvements and then property and attrs. Does that make sense?

Sounds good!


refactor: hpmn rename to evo for DIP-0028

DIP-0028 needs to be aligned with implementation (https://github.com/dashpay/dash/pull/5508)

Note: https://github.com/dashpay/FAQs/pull/10 should be merged first.


Uploading a JSON file for JSON to CSV should load in the JSON text box

Save your testcase (click on the Save link in CSVJSON menu bar) and copy/paste the URL here.
Test case involves file upload. Test file attached

Describe your request.
Uploading a JSON file for JSON to CSV should load in the JSON text box. Right now the JSON loads in the result box.

Test JSON (github doesn't support .json)

This is now fixed. Thanks for reporting.


Setting Density in PNG (with transparent bg) is not working

Opened this issue because I couldn't find something.
I have a PNG image with transparent background.
However when I try to set the density of the output image,  doesn't seem to work.
Wanted output =>
a PNG image with :

custom size
keep the transparent background
custom density/DPI (set by me)

My code which produces the issue(tried many snipets)
NOTE: You need an input PNG image with Transparent Background
buffer = await sharp(input).
  toFormat(format). // png
  resize(sharpOpts). // set height and width
  withMetadata({density: 70}).
  toBuffer();
return buffer;

However when I apply flatten() in the code above, setting density is working!
Of course this is not the output I wanted, because my final image has background😢
Thanks for your time

Hi, I'm unable to reproduce this using https://github.com/lovell/sharp/blob/main/test/fixtures/full-transparent.png and the following code:
sharp('full-transparent.png')
  .resize({ width: 8 })
  .withMetadata({ density: 70 })
  .toFile('out70.png');

sharp('full-transparent.png')
  .resize({ width: 8 })
  .withMetadata({ density: 80 })
  .toFile('out80.png');

which produces the expected resolution:
$ pnginfo out*.png | grep Resolution
  Resolution: 70, 70 (pixels per meter)
  Resolution: 80, 80 (pixels per meter)

If you still require help, please provide the exact code and a specific image that allows someone else to reproduce.

I'm so sorry, @lovell , I used the Windows Explorer(to check the density/DPI) which  IS NOT precise.
I'm currently using a more advanced tool to check DPI, and the code works perfectly! 🙂
Thanks for your reply.


Clusters not working on Virtual Network Templates

Description
"When a network is created by instantiating a Virtual Network Template it is associated to the default cluster. You can control which clusters the networks will be in with the CLUSTER_IDS attribute." This is not working
To Reproduce
Create a Virtual Network Template with a similar config to this:
AUTOMATIC_VLAN_ID = "YES"
CLUSTERS = "0,100,101"
PHYDEV = "bond0"
VN_MAD = "802.1Q"

Expected behavior
Any vnet instantiated from the previous vnet template should belong to clusters 0, 100 and 101. It only belongs to default cluster (0), although an attribute is created called "CLUSTERS" with the cluster config set on the vnet template.
Details

Affected Component: Sunstone, CLI
Version: 5.10.1

Additional context
Add any other context about the problem here.

Progress Status

[ ] Branch created
[ ] Code committed to development branch
[ ] Testing - QA
[ ] Documentation
[ ] Release notes - resolved issues, compatibility, known issues
[ ] Code committed to upstream release/hotfix branches
[ ] Documentation committed to upstream release/hotfix branches

The xmlrpc call vntemplate.instantiate does not have any parameter for cluster ID like vn.allocate. vntemplate.instantiate receives the call from the oca inserting the cluster id(s) on the template, which is later on used as an attribute of the newly created VM, it does not add the new vnet to those clusters

Hello @sergiojvg, as you said:

You can control which clusters the networks will be in with the CLUSTER_IDS attribute.

You have to use CLUSTER_IDS attribute for specifying the cluster which the newly created vnet will belong to. But you are using CLUSTERS instead.
Regarding the XMLRPC call, one.vntemplate.instantiate takes care of parsing this attribute and add the network to the specified clusters:
https://github.com/OpenNebula/one/blob/944f12446d639b1c3a725ab102d1daa8fcfeb9bd/src/rm/RequestManagerVNTemplate.cc#L198

Hi @christian7007 , long time no see :) You are totally right, CLUSTER_IDS worked like a charm. I was looking in the wrong place by thinking the xmlrpc call could be related, but there is still a problem.
The vntemplate's template (that sounds weird) was not generated by me, but by Sunstone. This means that the fix is even easier but Sunstone should use CLUSTER_IDS instead of CLUSTERS when generating the template. To make things worst, the template can not be updated from sunstone, so users will need to use the CLI for this.
I did not try generating the vntemplate from the CLI, not sure if this issue will also arise if generated from the CLI.

Hello @sergiojvg, yes it's nice to see you around. To create a vntemplate using CLI you need to provide a file with the vntemplate description so it should works fine but might by a bit tricky for some users.
As workaround, while Sunstone is fixed, you can keep creating the vntemplates via Sunstone and just updated the CLUSTERS attribute name to CLUSTER_IDS by using CLI.

PRs to merge:
• one: #4182
• docs: waiting for release

@tinova @sbbarragan , small issue on the PR, it says CLUSTERS_IDS when it should be CLUSTER_IDS. Besides this code works like a charm

Thanks for the heads up Sergio!

:+1:


TX: Create a state profile to assess hospital partnerships for ETOR

Research
Create a state profile to assess hospital partnerships for ETOR for the state. What would make them a good candidate for partnership? What would encourage them to partner with us?
Completion Criteria

[x] We've identified hospitals that may have the interest and ability to implement our ETOR solution within the state.
[x] We've identified reasons that would make the PHL a good or poor fit for our solution

Research Tasks
State

[x] Population
[x] Rural/vs urban % of state
[x] Annual births in each state

Hospitals

[x] Number of hospitals in state (defined by aha.org data as community hospitals)
[x] Number of critical access hospitals: location, and which of these have birth facilities
[x] Total number of healthcare systems in state
[x] Percentage of community hospitals with births
[x] Percentage of births in top 3 healthcare systems
[ ] Hospitals up to 199 beds that fit org persona
[x] Relationship with HIE

HIE

[x] Does the state have an active HIE? If so, how is it being used?
[x] Any FHIR capabilities?

NBS

[x] State NBS overview + any NBS result/transport metrics

PHL

[x] Overview
[x] LIMS system
[x] Other portals used
[ ] Relationship with HIE
[x] Are they collecting metrics for NBS? Do they have birthing data available?

Persona Targets

[ ] What hospitals might be a good candidate for a SMART on FHIR app?
[ ] How many hospitals fit our existing small hospital persona?
[ ] Any other criteria to help define a hospital candidate for SMART on FHIR?
[ ] Are there other opportunities to partner with hospitals that do not have FHIR capabilities?

Research Definition of Done

[x] One page profile? Infographic?

Other Notes

CDC provided a list of target hospitals. Once we get confirmation that Texas is part of the pilot program we will hold off on additional research around potential hospital partners and the PHL relationship with the HIE


Wide tables create poor query performance

On the MNIST handwritten digits data set (787 columns) query performance is very poor. On the order of several minutes for a 70K row data set.
time dolt sql -q 'SELECT count(id) FROM samples'
real	12m22.745s user	12m25.863s sys	0m1.296s

Thanks for the great report. Resolved here: https://github.com/liquidata-inc/dolt/commit/9611b2d2ca9187706f83cff2c7313ff038a71566.


Return exit code if file is not formatted

A bit like rubocop, I'd like CI to flag pull requests that do not have .erb files already formatted, and fail the build. I tried sendin erb-format's output to /dev/null, but its exit code is zero even when I have unformatted input.
Is there a good way to do this?
thanks for erb-formatter, it appears one of a kind.

You can sort of beat around the bush to accomplish this. We us CircleCI and we just run the formatter with the -w argument then run a git diff HEAD which will exit code how you'd like.
erbformat:
  executor:
    name: ruby
  steps:
    - checkout
    - restore_gems
    - restore_bootsnap_cache
    - restore_node_modules
    - run:
        name: erbformat
        command: bundle exec erb-format app/views/**/*.erb -w --print-width 120
    - run:
        name: No erbformat errors found
        command: git diff HEAD --exit-code

@fdr @darrenterhune I'd be happy to accept a PR for this.
Differently from rubocop which main aim is checking files and has autocorrection attached, erb-formatter is a formatter first and only secondarily can be used for checking.
Rubocop has a --fail-level option that is used to control the exit status.
I think we can go along the same lines and use the same name with these values:

[C] check fail when any file needs correction
[E] error fail when any other error occurs

Happy to get other levels suggested if anyone wants to venture into sending a PR for this feature 🙌

You can sort of beat around the bush to accomplish this. We use CircleCI and we just run the formatter with the -w argument then run a git diff HEAD which will exit code how you'd like.
erbformat:
  executor:
    name: ruby
  steps:
    - checkout
    - restore_gems
    - restore_bootsnap_cache
    - restore_node_modules
    - run:
        name: erbformat
        command: bundle exec erb-format app/views/**/*.erb -w --print-width 120
    - run:
        name: No erbformat errors found
        command: git diff HEAD --exit-code

Thank you for sharing, here's a GitHub Action version that I'm using :point_down:
name: format

on: push

jobs:
  erb-formatter:
    runs-on: ubuntu-latest
    steps:
    - uses: actions/checkout@v4
    - name: Set up Ruby
      uses: ruby/setup-ruby@v1
    - name: Install Gems
      run: bundle install
    - name: Run erb-formatter
      run: erb-formatter --write --print-width 120 app/views/**/*.html.erb
    - name: Check for changes
      run: git diff --quiet app/views


Add option to derive Debug identical to Display

Feature request: in failure_derive, add an option to fail attribute that would automatically generate a Debug implementation that is identical to (or, perhaps more appropriately, delegating to) the Display implementation (as generated by #[fail(display=...)]).
Context:
I am defining my own Fail types, for example:
#[derive(Fail)]
#[fail(display = "Aborting by user request")]
pub struct AbortedByUser;

I am also using fn main() -> Result<(), failure::Error>. This means that the std::process::Termination trait comes into play, and its implementation for Result ends up calling eprintln!("Error: {:?}", err);. If I derive Debug for my type, I get the output Error: AbortedByUser, which is not ideal UX-wise. So I ended up doing this:
impl Debug for AbortedByUser {
    fn fmt(&self, f: &mut Formatter) -> Result<(), Error> {
        Display::fmt(self, f)
    }
}

Now the program prints: Error: Aborting by user request.
This was fine while I only had one such failure type, but then I added the second one for which I wanted the same kind of reporting experience. Obviously, I can remove most of the boilerpaste with a macro, but that's still a macro that I'd have to write and put somewhere in my code. It would be much nicer if I could just write something like #[fail(display = "Aborting by user request", debug_as_display)].

To increase the web's connectivity:

relevant discussion in the tracking issue for Termination: https://github.com/rust-lang/rust/issues/43301#issuecomment-388575730
mentions exitfailure crate


How to ignore net::SMTPFatalError: 552 "RCPT TO" mailbox unavailable?

to make the mail sent, and the admin of the SMTP server told me it is caused by client options and the mail was sent with outlook client. thx

If you want to ignore it, just append a rescue nil to the line and it will be silently rescued.


eject: unable to eject, last error: Inappropriate ioctl for device

Using abcde.conf referenced here to rip CDs or makemkv to rip DVDs I have. I have noticed that when I put a CD in the drive, it will rip it over and over (overwriting the ripped files continuously). Checking ripper.log, I can see the following
eject: unable to eject, last error: Inappropriate ioctl for device
Executing customizable pre-read function... done.
I also tried a DVD and similar happens, re-ripping over and over, same error in ripper.log (until container is stopped or disc is manually removed).
Any ideas?

Are you running the container with the required "privileged" flag?

My bad, Running on unRaid ticked "Priviledged", restarted container and all seems to be well. Thanks!

Glad I could help ;)


⚠ Bofrost.es has degraded performance

In db1dfdb, Bofrost.es (https://www.bofrost.es) experienced degraded performance:

HTTP code: 200
Response time: 1607 ms

Resolved: Bofrost.es performance has improved in 8c32f27 after 6 minutes.


With lighthouse effect, units do not get additional turn when built

Tested this on trireme. Basically when it gets built it has 3 turns, but in the next turn 4 turns.

Alright... I believe this means that the game handles unit actions first, then city actions. I did this the other way around. Hopefully, by reversing this, I won't introduce any new bugs. :-)

This should be opened again. When I build my sail, it has 3 turns (when leaving the city). In the next turn it has 4 turns.

Doesn't it now work like it's supposed to? I remember testing it against the game. The turn that the Lighthouse gets built, your unit still has 3 turns. Only the next turn will it get 4. I will need to test this.


Change a typo in health probe doc

@KarlErickson could you please help to merge this pull request？

@KarlErickson
Can you review the proposed changes?
When the changes are ready for publication, add a #sign-off comment to signal that the PR is ready for the review team to merge.
#label:"aq-pr-triaged"
@MicrosoftDocs/public-repo-pr-review-team

#sign-off


Is there an example of a public Siren api?

Is there a public example anywhere? It would be great place to get a handle on the format.

Unfortunately only one of @kevinswiber 's examples is still working: http://fizzbuzzaas.herokuapp.com/
This is a really great and simple example of an REST API, I'd definitely recommend adding this to the README.


modernize runit_service provider

Modernizing runit_service provider

Converting to LWRP DSL
Increading readability
Initial ChefSpec
Debian 7 now works
RHEL 7 support

Switching from Minitest to Serverspec

Makes it easier to tell if resources update on 2nd and 3rd runs
Integration tests not run in context of initial converge
Utilize test-kitchen bussers

Awesome!
Let's get centos-7.0 and debian-7.8 into the default .kitchen.yml, as not everyone has DO :smile_cat:.

Also ln -s Berksfile.disabled Berksfile works a treat :cake:.

added!

@jtimberman
:+1:

@someara could we get this as two PRs, the first to bring in the new tests, and the second with the LWRP changes? That would allow confirming that the old provider code works with the new tests, and then confirming that the new providers work with those tests (i.e. behavior is functionally intact).
New tests and new providers at the same time is essentially a whole new cookbook, and we're limited by our ability to mentally parse the code and by manual smoke tests to ensure that new_thing == old_thing.

#108 and #109

Evaluating the split PRs took some time because not all tests in #108 pass. This is due to Gemfile changes that should be in #109, and needed ServerSpec changes that are present in #109.
That said, having the changes split out into logical chunks has helped me to digest these changes and I think I am comfortable merging this PR at once instead of piece meal.
Now that I've bumped development branch to 1.6.1 so that I can merge this PR, we've got a merge conflict.
@someara can you please rebase this on master to address the conflict?

Your merge button is now green, sir.

https://www.youtube.com/watch?v=KiQzUEc_FmI


Consider page dependencies?

I have several pages in my site, whose content is generated based on YAML data in _data, or which display the items of a collection. Currently, only changes to the page source itself are reflected by page.last_modified_at. I would like page.last_modified_at to reflect when the page content changes due to changes in the underlying data / collection (such that the jekyll-sitemap plugin generates correct <lastmod> tags).
Is this feature currently supported, or planned?
If it's not yet supported, I would be willing to take a look into this issue myself, if you could give me some guidance.

A relatively simple solution might be to have users explicitly declare dependencies in the frontmatter. I'd be happy with this solution, but others may find it tedious. On the other hand, it gives you complete control over which dependencies you want to be considered, and which should be ignored.
Alternatively, jekyll seems to do some dependency tracking itself: https://github.com/jekyll/jekyll/blob/6855200ebda6c0e33f487da69e4e02ec3d8286b7/lib/jekyll/regenerator.rb#L106-L114
I don't know how difficult it would be to access this information from a plugin.

I have a minimal draft of the first variant (explicitly specifying dependencies): https://github.com/gjtorikian/jekyll-last-modified-at/compare/master...maul-esel:jekyll-last-modified-at:specify-dependencies
Usage:
https://github.com/maul-esel/personal-website/blob/main/publications.markdown?plain=1#L10-L11
https://github.com/maul-esel/personal-website/blob/main/talks.markdown?plain=1#L9-L10
The second variant (using jekyll's dependency tracking) seems a bit farther off, after some investigation:

Dependency tracking is only enabled for incremental builds (that is the only application so far)
Dependencies on data files are currently not tracked:

jekyll/jekyll#7682
jekyll/jekyll#8771 implemented the feature, but it was reverted in jekyll/jekyll#9170

Based on some experimentation, it seems dependencies on documents in collections are also currently untracked


Feature request: Ionization / "FRESH" mode

Some models of Midea (and other compatible brands) A/C and (de)humidifier units have option to switch on Ionization by pressing a button called "FRESH" on the remote control. For example, if you see this manual for what seems to be BreezeleSS+, on PDF Page 8, you will see how it indicates that the Ionization mode is working - leaf icon on the LED panel.
I personally have a different A/C brand and model but it also has that same "FRESH" feature that is present in many other Midea devices of different classes.
Is it possible to have this feature added for compatible devices with a toggle, just like "ECO Mode", "Prompt Tone", "Swing Vertical" etc?
Kind regards.

Any news on this one? I think more and more midea-ACs are delivered with Ionization. On the remote its called "air magic".

I'm also interested in this but as I see not even the Midea mobile app has this option. Currently the only option to turn on air magic is the remote control.

I’m sorry, but I believe this feature is unnecessary and I don’t foresee myself investing effort into it.

Hi - any chance you could reconsider this please?

Hi - any chance you could reconsider this please?

What is the feature you want?

As the comments from other people above: the ability to control the ionisation feature. On my remote it's called 'Air Magic'.
Thanks

As the comments from other people above: the ability to control the ionisation feature. On my remote it's called 'Air Magic'.
Thanks

Well, can this feature be controlled from the app, or can it only be controlled by the remote?
And, please tell me the model of device showing in "Settings -> Devices & Services -> Midea AC LAN -> Devices -> Device Info".

I can only find it on the remote, however perhaps we should wireshark this to see if the device puts out anything on the network once the remote button has been pressed?
For me, my device is:
Air Conditioner 00000Q1B
Thanks for looking into this.

Any chance of considering this again?  Is there anything I can do to help you?

Hi @georgezhao2010, any chance of considering this again? Is there anything I can do to help you? Thanks


UniFi Security Gateway 3P

Will this work with my UniFi Security Gateway 3P? How do I install this? on the unit?

It will work with your USG 3P, however, it needs to run on another machine on your network with access to your Unifi Controller.
It doesn't run on the USG.

Sorry to ask, what type of machine is this? Could you be more specific how
this works.
Thanks,
Mike Triber
508-254-4649 Cell
<EMAIL_ADDRESS>On Tue, Jun 5, 2018 at 3:27 PM, Troy Dack<EMAIL_ADDRESS>wrote:

It will work with your USG 3P, however, it needs to run on another machine
on your network with access to your Unifi Controller.
It doesn't run on the USG.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/tdack/unifi-parental/issues/4#issuecomment-394831029,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AmG2jTWdiFDzVzE5oDtH6DVPreP-sJ1wks5t5tuXgaJpZM4UbEry
.

Hello,
Is it possible I could pay you to implement this feature in my device?

Sorry I don't really have the time to be able to do this.
I currently have it installed on a machine running Linux. You could run it in a Linux virtual machine, or even on a cloud based virtual machine.
This "software" is really a bit of a kludge to meet some specific needs I had. It is not pretty or refined, and more than likely to break without warning. If you haven't the knowledge to install it, then keeping it running would be even harder.
Cheers,
Troy


Additive Blending

Hi I'm coming from another raylib project where I can set the blending to achieve some nice lighting effects:

using things like rl.BeginBlendMode(rl.BLEND_ADDITIVE) and rl.EndBlendMode. However I cant seem to find it in Taylor. How would I achieve this?
btw Ruby + Raylib seems pretty fun so far.

Hi,
I haven't yet implemented this function but will be doing so once I've finished my refactor work.
Thanks for taking an interest in Taylor!
Cheers,
Sean


Release PR for public release r1.2 (M4)

What type of PR is this?
Add one of the following kinds:

documentation
subproject management

What this PR does / why we need it:
Create the public release r1.2, see #352

API Readiness Checklists and CHANGELOG are anticipating the merge of

#349
#354
#356
These PRs have to be merged before the release PR!

Which issue(s) this PR fixes:

Fixes #352
Special notes for reviewers:
Changelog input
 Updates of file versions, CHANGELOG and README for public release

Added #356 proactively to CHANGELOG and updated the PR description.

All PRs for v0.11.0 so far closed, adding @camaraproject/release-management_maintainers as reviewer.

@jlurien @RandyLevensalor @eric-murray @tlohmar: I've addressed #340 here with https://github.com/camaraproject/QualityOnDemand/pull/353/commits/e7bd70188974562853d3d96132ca54585b560c6b. Please have a look if that is ok for you.

I do not see the updated User Story file in this PR, but I have a comment on the Summary section:
"As an application developer belonging to an enterprise, I want to request (using my application server/backend service), stable latency and/or stable throughput for a specified App-Flow from a Communication Service Provider (CSP), so that I can ensure better quality of experience for our end users including under network congestion"
I would propose to drop the "from a Communication Service Provider (CSP)" as the app can also talk to an Aggregator.
Or would it be "for a specified App-Flow from a given device connected to the application through the network, so that ..." ?
Also suggest to drop the word "our" from "our end users".

I think you can remove the LICENCE.APACHE.2.0 file from the code/Test_definitions folder as it is already present in the main folder.

@tanjadegroot Thanks a lot for the intensive review. See my answer on your comments. Please have a view if ok for you. I have also deleted the duplicated license file (I recently added the file at the right place but have overseen that there was one in /code). For the User Story I don't see the changes as urgent and have kept it untouched (but I merged main into the PR branch, so that now the User Story is part of it).
@eric-murray @jlurien @RandyLevensalor please check the latest changes and approve the PR if ok for you.

@jlurien @eric-murray @RandyLevensalor I've addressed all review comments from Tanja, so from Release Management there is green light. But I can't merge the release PR without a Codeowner review.

@tanjadegroot Thanks a lot for the intensive review. See my answer on your comments. Please have a view if ok for you. I have also deleted the duplicated license file (I recently added the file at the right place but have overseen that there was one in /code). For the User Story I don't see the changes as urgent and have kept it untouched (but I merged main into the PR branch, so that now the User Story is part of it).

Review done by RM: LGTM


Getting Http Error for .search

HTTPResponse(_body=None,buffer=<_io.BytesIO object at 0x107204af0>,code=406,effective_url='http://localhost:9200/build_items//_search?headers={'Content-Type'%3A+'application%2Fjson'}',error=HTTP 406: Not Acceptable,headers=<tornado.httputil.HTTPHeaders object at 0x1072430f0>,reason='Not Acceptable',request=<tornado.httpclient.HTTPRequest object at 0x107220898>,request_time=0.0065157413482666016,time_info={})
Please help!!!

I was having the same issue in search. After investigation found out that when it's making the request its not setting the content-type in the header. You can resolve this issue by initialising the connection in following way.
es_connection = ESConnection("localhost", 9200, http_request_kwargs={"headers": {'Content-Type': 'application/json'}})
I think the source need to change. Is anyone maintaining this code?

@aftab0000 thanks for your finding. Would you mind to create a PR with this change? I believe you're right, but it's important to make sure that it won't break running with older versions of ES.

@jonathansp I made the changes in my branch but had to change few test cases because of ES 6.x compatibility issue. Those test cases are applicable for 5.x but not for 6.x. Moreover this issue is only happening in 6.x. Should we create separate branch for 6.x or merge the change with this one?
Note: I tested the fix for version 5.1 and 6.1. It working fine for both version.

@aftab0000 please, create a separated branch for 6.x.


docs: Fix minor typos

Fixed minor typos (E.g Dashbard to Dashboard, IF to If).
Modified some punctuation marks for easier reading (E.g replacing some dashes " - "with commas " , ").
Added URL for fyipe.com

Thank you!