fix: Add missing parameters when using auto unseal

Q
A

Bug fix?
yes

New feature?
no

API breaks?
no

Deprecations?
no

Related tickets
fixes #1787

License
Apache 2.0

What's in this PR?
This PR checks the seal type and uses the according parameters in the init API call. Furthermore, I updated the vault go api.
Checklist

[x] Code meets the Developer Guide
[x] User guide and development docs updated (if needed)
[x] Related Helm chart(s) updated (if needed)

To Do

[ ] Test it with all unseal methods (tested with shamir)

Hey @mkroman,
I would be glad if you could test the mentioned PR with your configuration (https://github.com/banzaicloud/bank-vaults/pull/1795). 😊
You can find test instructions over here (banzaicloud.com/docs/bank-vaults/contributing/#operator).

Hey @mkroman,
I would be glad if you could test the PR with your configuration. blush

Thanks for looking into this! Sorry, but I'm struggling to find the time to test it.

You can find test instructions over here (banzaicloud.com/docs/bank-vaults/contributing/#operator).

I've checked out your branch, but when I run make operator-up I get the following error:
operator/pkg/controller/vault/vault_controller.go:58:2: package github.com/banzaicloud/bank-vaults/internal/vault imports github.com/hashicorp/go-version from implicitly required module; to add missing requirements, run:
	go get<EMAIL_ADDRESS>test/pkg/mod/k8s.io/apimachinery@v0.21.1/pkg/labels/selector.go:25:2: missing go.sum entry for module providing package github.com/google/go-cmp/cmp (imported by k8s.io/apimachinery/pkg/labels); to add:
	go get<EMAIL_ADDRESS>test/pkg/mod/golang.org/x/term@v0.5.0/term_unix.go:11:2: missing go.sum entry for module providing package golang.org/x/sys/unix (imported by golang.org/x/term); to add:
	go get<EMAIL_ADDRESS>make: *** [Makefile:162: operator-up] Error 1

Full output is available here: operator-up.log
If I add the missing requirements as it suggests:
% go get<EMAIL_ADDRESS>% go get<EMAIL_ADDRESS>go: downloading github.com/google/go-cmp v0.5.7
% go get<EMAIL_ADDRESS>go: downloading golang.org/x/sys v0.5.0

I instead get this:
% make operator-up
kubectl replace -f operator/deploy/crd.yaml || kubectl create -f operator/deploy/crd.yaml
customresourcedefinition.apiextensions.k8s.io/vaults.vault.banzaicloud.com replaced
kubectl apply -f operator/deploy/rbac.yaml
serviceaccount/vault unchanged
role.rbac.authorization.k8s.io/vault unchanged
rolebinding.rbac.authorization.k8s.io/vault unchanged
clusterrolebinding.rbac.authorization.k8s.io/vault-auth-delegator unchanged
OPERATOR_NAME=vault-dev go run operator/cmd/manager/main.go -verbose
# github.com/banzaicloud/bank-vaults/internal/vault
internal/vault/plugins.go:118:13: cannot use pluginType (variable of type consts.PluginType) as "github.com/hashicorp/vault/api".PluginType value in struct literal
internal/vault/plugins.go:149:11: cannot use pluginType (variable of type consts.PluginType) as "github.com/hashicorp/vault/api".PluginType value in struct literal
make: *** [Makefile:162: operator-up] Error 1

Go version: go version go1.20 linux/amd64

Hey @mkroman,
I would be glad if you could test the PR with your configuration. blush

Thanks for looking into this! Sorry, but I'm struggling to find the time to test it.

You can find test instructions over here (banzaicloud.com/docs/bank-vaults/contributing/#operator).

I've checked out your branch, but when I run make operator-up I get the following error:
operator/pkg/controller/vault/vault_controller.go:58:2: package github.com/banzaicloud/bank-vaults/internal/vault imports github.com/hashicorp/go-version from implicitly required module; to add missing requirements, run:
	go get<EMAIL_ADDRESS>test/pkg/mod/k8s.io/apimachinery@v0.21.1/pkg/labels/selector.go:25:2: missing go.sum entry for module providing package github.com/google/go-cmp/cmp (imported by k8s.io/apimachinery/pkg/labels); to add:
	go get<EMAIL_ADDRESS>test/pkg/mod/golang.org/x/term@v0.5.0/term_unix.go:11:2: missing go.sum entry for module providing package golang.org/x/sys/unix (imported by golang.org/x/term); to add:
	go get<EMAIL_ADDRESS>make: *** [Makefile:162: operator-up] Error 1

Full output is available here: operator-up.log
If I add the missing requirements as it suggests:
% go get<EMAIL_ADDRESS>% go get<EMAIL_ADDRESS>go: downloading github.com/google/go-cmp v0.5.7
% go get<EMAIL_ADDRESS>go: downloading golang.org/x/sys v0.5.0

I instead get this:
% make operator-up
kubectl replace -f operator/deploy/crd.yaml || kubectl create -f operator/deploy/crd.yaml
customresourcedefinition.apiextensions.k8s.io/vaults.vault.banzaicloud.com replaced
kubectl apply -f operator/deploy/rbac.yaml
serviceaccount/vault unchanged
role.rbac.authorization.k8s.io/vault unchanged
rolebinding.rbac.authorization.k8s.io/vault unchanged
clusterrolebinding.rbac.authorization.k8s.io/vault-auth-delegator unchanged
OPERATOR_NAME=vault-dev go run operator/cmd/manager/main.go -verbose
# github.com/banzaicloud/bank-vaults/internal/vault
internal/vault/plugins.go:118:13: cannot use pluginType (variable of type consts.PluginType) as "github.com/hashicorp/vault/api".PluginType value in struct literal
internal/vault/plugins.go:149:11: cannot use pluginType (variable of type consts.PluginType) as "github.com/hashicorp/vault/api".PluginType value in struct literal
make: *** [Makefile:162: operator-up] Error 1

Go version: go version go1.20 linux/amd64

Thanks for giving it a shot. 😊
I will try to look into it tomorrow.

While I was syncing the fork, GitHub did a force-push and closed the PR. I don't know why. I will open a new PR...

See #1808


Update 08_HSBN Deployment.md

Corrected some minor mistakes and naming consistency.

The website has been archived; closing.


How to understand the extracted features from VISSL (shape-dimensionality understanding)

I have trained my satellite image data set using DC_v2 VISSL, rnet50 in the trunk:

The image size is 100x100 pixels:

Extracted the features from a single test data image
first layer :["conv1", ["AvgPool2d", [[10, 10], 10, 4]]], output feature shape is (1, 1600)
and the last layer: ["res5avg", ["Identity", []]], output feature shape is (1, 2048)

Maybe I sound stupid, but to understand the extracted feature relation with the original test image, should I reshape them, or am I missing something?
Kindly advice!!
Edit -
I forgot to write -
I have checked the options of MODEL.SHOULD_FLATTEN_FEATS: True/False . But the dimensions of the features are the same.

Hi @DC95,
The relation is not very direct and requires a bit of explanation indeed. The ResNet50 architecture is built upon a tower of conv layer and pooling layer that will reduce the size of your feature map (initially 100 times 100) by a factor of 32 reaching "res5" and then average pool and flatten these features at "res5avg".
So at the end you should get (1, 2048) as you noted and the feature map will reduce in size along the way:
model = models.resnet50()
model.fc = nn.Identity()
model(torch.randn(size=(1,3,100,100))).shape # shape is (1, 2048)

So that is expected. Now, regarding the "conv1" layer:
model.conv1(torch.randn(size=(1,3,100,100))).shape # shape is (1, 64, 50, 50)
avg_pool = torch.nn.AvgPool2d([10, 10], 10, 4)
avg_pool(torch.randn(size=(1, 64, 50, 50))).shape # shape is (1, 64, 5, 5)

If flattened, this gives the shape (1, 1600) as you observe.
If you want to disable the flattening, you should use the option config.MODEL.FEATURE_EVAL_SETTINGS.SHOULD_FLATTEN_FEATS=False and you should get (1, 65, 5, 5) as output.
Tell me if this is working or not for you.

Dear @QuentinDuval
Thank you for the descriptive answer.
I have tried the option of config.MODEL.FEATURE_EVAL_SETTINGS.SHOULD_FLATTEN_FEATS=False for both the layers and the output is still -
(1,1600) and (1, 2048). I don't understand why?
I have checked with the middle layers also, but it is throwing flatten outputs.
Kindly find the configuration attached -
dcv2_juelich_85x2_FB.txt

Hi @DC95,
I will have a look at that !

Hi @DC95,
I integrated a fix at 474a1d7c3a1373035249f5324d072b5a7a724d17 which should fix your issue.
Could you try at head?
Thank you,
Quentin

Dear @QuentinDuval
Thank you very much for fixing the bug so quickly and integrating it. It works well now.
We can close this now.
regards,
DC

Awesome ! Thank you for finding the bug :)
Closing the issue :)


Save to library

Hi,
It would be nice to be able to save the current song playing to our Spotify library without having to open the app.

Closing issue as it is related to / duplicate of issue #3


jcenter()

This library does not work without the jcenter() repository, but the jcenter() repository is going to shut down soon as it is mentioned.

I added the this ZCustomCalendar Library. But when I build the project it says you've not added the library. And this library implementation is also not showing up in XML. Help me out plz. I've already wasted two days on it but didn't get any result.

I added the this ZCustomCalendar Library. But when I build the project it says you've not added the library. And this library implementation is also not showing up in XML. Help me out plz. I've already wasted two days on it but didn't get any result.

Have you tried using jcenter()?


Liquid Water Path (LWP): UWisc climatology not available anymore

Hi,
I have been struggling to get my hand on the UWisc dataset used in clouds/recipe_lauer13jclim.yml
The dataset is listed in the NCAR Climate Data Guide:
https://climatedataguide.ucar.edu/climate-data/liquid-water-path-lwp-uwisc-climatology
But the FTP server is not responding (I have tried many times over the last few weeks)
ftp://reef.atmos.colostate.edu/incoming/odell/lwp_climatology/v3_1988_2008/lwp/
I have contacted colorado.
In the mean time I have contacted one of the authors, Ralf Bennartz:
The dataset is superseded by MAC-LWP which is used in the clouds/recipe_lauer22* recipes.
The authors don't have the data handy anymore and suggested I get it from DKRZ if it was still available there.
I know the UWisc dataset is available at DKRZ and I would very much like to have a copy (for legacy purpose).
Question is: What do we do with the clouds/recipe_lauer13jclim.yml recipe?
Should it be considered broken?
@remi-kazeroni ?

Hi @rbeucher, thanks for identifying this problem and thinking about solutions. I think that we should certainly discuss whether that recipe should be marked as broken if (some of) its obs data is no longer available from the data providers.
It'd be good to get an opinion from the @ESMValGroup/scientific-lead-development-team and the author @axel-lauer. E.g. Should the UWisc part of the recipe be suppressed?

Thanks @alistairsellar. If someone has a copy of the dataset, I am interested. For legacy.

MAC-LWP is the new version of the UWisc dataset. Both are tier 3 datasets. Please email me for possible options.
I am not sure the recipe needs to be flagged as broken. UWisc is a tier3 dataset because the data were obtained directly from the authors. Data from any other source might therefore not be identical. Since this wasn't a problem so far, I would leave the recipe as is. I could add a comment to the recipe and the documentation that preferably MAC-LWP should be used now.

Thanks @axel-lauer. I have sent you an email via the DLR website.


incorporate translations in the release pipeline

Terue Takatsuki (@TerueTakatsuki) has put together a Japanese translation of the MP.
This file is now in src/ontology/translations.
We need to update the release pipeline to include the translation.

This is done, first release with translation was 10/31/23


Duplicate console log messages when conflicting reporters are defined

Description of the problem:
In our project we have both Mocha & Remap-Istanbul defined as reporters for our Karma Tests. It seems as though these two reporters both have similar functionality in that they both intercept console.log messages that are written out from the JavaScript so there are always two log messages for every console.log message that we write. I do not think there is a feature yet, but it would be neat to add functionality that basically disables console.log messages for one plugin but leaves them for another so that way you can have the functionality of both plugins but only allow 1 of them to output console.log messages.
Environment Details
Karma Version 0.13.22
Steps to reproduce the behaviour

Defined reporters: ["mocha", "coverage", "karma-remap-istanbul"] in the karma.conf.js for my angular app
Ran my tests
Console logs that were written in the code were duplicated for every test that had been executed.
Removed "karma-remap-istanbul" from the reporters list, reran the tests, and the duplication went away.
Added "karma-remap-istanbul" back to the reports list and removed "mocha", reran the tests, and the duplication went away.

@eklundjoshua could you post config for karma-remap-istanbul?
Thanks!

@maksimr Thanks for the follow up! Here is the karma.conf.js that I'm currently using:
`var path = require('path');
var webpackConfig = require('./webpack.config');
module.exports = function (config) {
var _config = {
    // base path that will be used to resolve all patterns (eg. files, exclude)
    basePath: '',

    // frameworks to use
    // available frameworks: https://npmjs.org/browse/keyword/karma-adapter
    frameworks: ['jasmine'],

    // list of files / patterns to load in the browser
    files: [
        { pattern: './karma-shim.js', watched: false }
    ],

    // list of files to exclude
    exclude: [],

    // preprocess matching files before serving them to the browser
    // available preprocessors: https://npmjs.org/browse/keyword/karma-preprocessor
    preprocessors: {
        './karma-shim.js': ['coverage', 'webpack', 'sourcemap']
    },

    webpack: webpackConfig,

    webpackMiddleware: {
        // webpack-dev-middleware configuration
        // i. e.
        stats: 'errors-only',
        noInfo: true
    },

    coverageReporter: {
        dir: 'coverage/',
        reporters: [{
            type: 'json',
            dir: 'coverage',
            subdir: 'json',
            file: 'coverage-final.json'
        }, {
            type: 'html',
            dir: 'coverage',
            subdir: 'html'
        }]
    },

    remapIstanbulReporter: {
        src: 'coverage/json/coverage-final.json',
        reports: {
            lcovonly: 'coverage/json/lcov.info',
            html: 'coverage/html',
            'text': null
        },
        timeoutNotCreated: 1000, // default value
        timeoutNoMoreFiles: 1000 // default value
    },

    webpackServer: {
        noInfo: true // please don't spam the console when running in karma!
    },

    // test results reporter to use
    // possible values: 'dots', 'progress', 'mocha'
    // available reporters: https://npmjs.org/browse/keyword/karma-reporter
    reporters: ["mocha", "coverage", "karma-remap-istanbul", "html"],

    htmlReporter: {
        outputFile: 'reports/unit_tests/index.html',
        pageTitle: 'Unit Test Results',
        useCompactStyle: true,
        groupSuites: true
    },

    // web server port
    port: 9876,

    // enable / disable colors in the output (reporters and logs)
    colors: true,

    // level of logging
    // possible values: config.LOG_DISABLE || config.LOG_ERROR || config.LOG_WARN || config.LOG_INFO || config.LOG_DEBUG
    logLevel: config.LOG_INFO,

    // enable / disable watching file and executing tests whenever any file changes

    // start these browsers
    // available browser launchers: https://npmjs.org/browse/keyword/karma-launcher
    browsers: ['PhantomJS'], // you can also use Chrome

    // Continuous Integration mode
    // if true, Karma captures browsers, runs the tests and exits
    singleRun: true
};

config.set(_config);

};`

@eklundjoshua
From remap-instanbul

Try remove 'text': null from remapIstanbulReporter reporters
Thanks

I've seen this issue in my app as well, it turns out that it doesn't matter what reporters you are using with remap-istanbul - I was able to isolate it as a karma coverage reporter issue.

After doing some chasing around, I am mostly convinced this is because karma-remap-istanbul is using baseReporterDecorator, so when writes are triggered in the base reporter, it propagates to the karma-mocha-reporter and karma-remap-istanbul.
I would recommend for fixing this that the writing of the logs be delegated to another reporter type that is not base, and have dots and progress use that. This would be a breaking change, and would need to be scheduled for a major release if this approach is adopted.

Thank you @maksimr. I tried your recommendation but still saw the duplication of logs. Thank you @wesleycho for your detailed findings as well!

Just so a solution is out in the open, we could either move to create another reporter type that can be decorated around, or we can try making a mixin pattern of sorts to do this. A mixin pattern would probably be more flexible than an inheritance pattern here, and not create problems in case we missed other features of the reporter we missed.

I've got similar issues when running with the karma coverage reporter and the karma mocha reporter. Any of the config options to turn off console reporting do it for both, can't find a way to turn one of and not the other without rewriting them. Wish there was an option for which reporter to send console output to. Also unrelated, but I don't understand why the coverage reporter doesn't respect the color flag for console reporting.

Alternatively, we could add a new hook inside karma for running actions after reporters, since some of the things being done by reporters like the karma-junit-reporter and karma-remap-istanbul are actually doing post test processing. This would minimize pain to other reporters, and the reporters causing the multiple logging can then be refactored to avoid this. Maybe a postReporters config option that takes an array of plugins to run after the reporters are finished running.
Thoughts on this @dignifiedquire ?

The reporters really need some work, as we have already seen in https://github.com/karma-runner/karma/pull/2397 and https://github.com/karma-runner/karma/issues/1411. I am okay with creating a breaking change if we can figure out a good solution that gets rid of the varying issues and makes it easy and clear on how to correctly extend and add reporters.

Any news regarding this issue? It is labeled as discussion. But nothing happened for nearly 8 month.

I'm here as an Angular developer. The Angular CLI by default configures three reporters: one which is built-in to the Angular build setup (needed for clear messages due to webpack), one for Chrome integration (kjhtml), and one is the base progress reporter. Thus, any time there's an error in the test, the console logs three times. Unfortunately, this makes the console output almost useless as trying to figure out which error to read and whether a new error has appeared causes me to go cross-eyed.
I've worked around this for now by setting reporters: [/*'progress', 'kjhtml'*/], but this doesn't seem like the right long-term fix. Ideally, I'd be able to configure each reporter individually to suppress console output.
@dignifiedquire do you still have an opinion on the issue?

I am also running into this issue using karma-mocha-reporter and karma-coverage-istanbul-reporter.
My intention is to have the mocha reporter display test results in the console while the coverage reporter generates lcov+html files and displays a text-summary in the console. This works great except for the fact that the coverage reporter displays duplicate test results.
I expected to find an option in the coverage reporter for disabling test results in the console, but according to the author this is a karma issue that he cannot work around.
Thoughts @vojtajina or @dignifiedquire?
Thanks!

Any updates or a solution to this problem? I'm also interested because we have the same problem.

In case anyone happens to stumble upon this issue as I did, it turns out that some reporters have implemented a "guard" that detects if they are not the last reporter, in which case they suppress log messages. This fix seems to have originated with the angular-cli project here: https://github.com/angular/angular-cli/pull/9529/files. This has also been implemented in the karma-coverage-istanbul-reporter here: https://github.com/mattlewis92/karma-coverage-istanbul-reporter/blob/master/src/reporter.js#L26. However, it does not appear that any similar guard was implemented in the karma-mocha-reporter.
The reason why this is relevant is that we have the exact same configuration as @JPMardelli above. We're using both 'coverage-istanbul' and 'mocha' reporters. As such, our reporters array was originally setup as:
reporters: ['mocha', 'coverage-istanbul']

However, once we realized what was going on behind the scenes (and after far too long of putting up with duplicate logs), we tried putting 'coverage-istanbul' before 'mocha' in the array. This allowed the guard in the 'coverage-istanbul' reporter to correctly identify that there is another reporter present and no longer duplicates log messages to the console:
reporters: ['coverage-istanbul', 'mocha']

Hope this helps others save some time!


Migrate incorrectly merged changes into dev branch.

Checklist

[x] Used a personal fork of the feedstock to propose changes
[x] Bumped the build number (if the version is unchanged)
[x] Reset the build number to 0 (if the version changed)
[x] Re-rendered with the latest conda-smithy (Use the phrase @conda-forge-admin, please rerender in a comment in this PR for automated rerendering)
[x] Ensured the license file is being packaged.

@michaelweinold please wait. Let me try to fix things first.


Abort partial commit

We need to be able to abort a partial commit in the event of a rare error (e.g. out-of-memory while appending or failure to write to WAL) and rollback all the previously committed rows. Currently our commit code assumes no failures occur here, which leads to incorrect behavior when one of these rare errors show up.

This issue has been fixed


Support stable Rust

This crate can only be used with a nightly Rust toolchain.
As of 2017-10-12, here's the list of unstable features that we currently depend on:

global_asm (documentation, tracking issue)
macro_reexport (documentation, tracking issue)
used (documentation, tracking issue)
const_fn (documentation, tracking issue)

I think the thing to do here is just to wait for the features to be stabilized, or for svd2rust to be updated to not use them anymore. Personally, I don't feel in any hurry here.

As of #47, this crate uses no experimental features and builds on the beta channel. It should build on stable when the next stable version is released.


[QUESTION] After the activity is completed and worker is terminated (graceful), the last event is still ActivityTaskScheduled

Hi @48d90782 , thanks for the fix.
But I encountered another issue.
When the activity is complete and the worker is terminated, but in temporal web, the last event in the workflow is still ActivityTaskScheduled.
I expected when the activity is complete and worker is successfully terminated, I can see the last event in temporal web is ActivityTaskCompleted.
I already update my samples code here, if you need it.
I just lower the sleep to 20s.
Originally posted by @khoerintus in https://github.com/spiral/roadrunner/issues/610#issuecomment-827694080

@khoerintus Hey. Could you please try to update docker-compose components to the latest verions:

temporalio/web:1.9.0
temporalio/admin-tools:1.8.2
temporalio/auto-setup:1.8.2

Hi @48d90782 , I already update the temporal to latest version and retry it. But the result is still same as above.
Here is the screenshots:
The Activity task is completed from worker, and worker is terminated:

But in temporal web, the workflow is still running, and the last activity task is still pending.

Hey @khoerintus. I see that the activity Plugin isn't stopped properly. I guess this is why you see such workflow status as on the screenshot, but I'll double-check that.

Ok, I dig into your problem and understand what did you mean. 😄
This is not a bug but the actual behavior of the Temporal. Your activity (state) is stored in the temporal server. When you stop the worker, it does not mean that RR will stop the activity immediately. It will be trying to continue execution due to the timeout period (5min by default). Only after that period, if the worker is still down, the Temporal will stop the activity (and the reason will be - timeout). You may, for example start RR, fire the LongRunningActivity.php, then stop RR and stop LongRunningActivity.php. Then without starting LongRunningActivity.php, start the RR server and you'll see, that the Temporal will start the counter even without re-running the activity. To cancel the activity, you should directly cancel it with a proper command https://docs.temporal.io/docs/concepts/activities/#cancellation.`

Forgot - extended status:

Hi @48d90782 ,
I am sorry, but I think that we don't understand each other.
For you to understand easier, here is the detail action and event that actually happened and what I expect:
00:00:00  -  start roadrunner worker with grace_period 30s
00:00:00  -  start an activity which sleep for 20s
00:00:01  -  terminate roadrunner worker, start graceful shutdown, waiting for 30s
00:00:20  -  activity completed, but does not send completed event to temporal server (I expect that when this activity completed, activity state in temporal will update to completed)
00:00:21  -  worker stop gracefully

Hey @khoerintus, let me double-check this and re-open the issue if a completed event does not arrive in the temporal server.

Ok guys, got u, reopening the issue. I guess, that I missed something. I'll investigate this, thanks.

@khoerintus , @changwuf31 Hey, I guess this is normal behavior when the worker is in the stopping state according to the temporal go-sdk sources:
https://github.com/temporalio/sdk-go/blob/6d79cfde669a309a23463318d7b5fe45a9dfd751/internal/internal_task_pollers.go#L879.
I can also see this error in the logs: INFO    temporal        Task processing failed with error       {"Namespace": "default", "TaskQueue": "default", "WorkerID": "197549@rustatian@default@3", "WorkerType": "ActivityWorker", "Error": "worker stopping"}.
When the worker is in the stopping state it returns the worker stopping error and stop all task processing (polling) for the activities and workflows.
It's hard to say if that's behavior correct or not. But I generally agree, that if the worker is in the stopping state, you can skip checking for the activity completion state since the worker was interrupted.
You may also ask this question at the Temporal support forum: https://community.temporal.io/

ref?: https://github.com/temporalio/sdk-go/issues/480

@khoerintus We are waiting for the temporal team to fix this issue, then I'll update dependencies.


How can i calculate accuracy?

loss is not enough for my experiment, how can i calculate accuracy? thanks!

Have you solved the problem?


[FEATURE] Request: Allow varying widths in pie/doughnut chart of multiple datasets

Expected Behavior
Allow us to change the width of one of the datasets in a pie/doughnut chart. It would be handy to be able to set your own values or allow the graph to use the data to create a "weight" attribute (dataset 1 has points 5,4,3 while dataset 2 has points 50,40,30, so dataset 2 could be thicker).
Current Behavior
Currently it is split evenly between the amount of datasets and will all be equal width.
Possible Solution
A simple weight attribute in a dataset could work. Say, a weight of 1 will retain the original size. A dataset of weight 0.5 will have half as much weight as a dataset of 1, so it will be half as thick.
Context
I am trying to add a ring around my pie chart that indicates if a percentage has been reached. It is meant to show (in my example work) how many customers it took to reach 80% of the total sales. I am currently doing this with a second dataset consisting of data 80,20. However, I want to reduce the size of the ring as it is not the relevant information to be displayed, and make it so that it is simply a "border" or "outline" to the actual data. I am also interested if there is a marker option in chart.js that accomplishes this, similar to drawing a line y = 5 on a line graph to compare your actual line graph to.

+1 on this. I've faked it by duplicating the datasets to make some "thicker" than other... Far from ideal but it creates the desired outcome

+1! Any way to achieve this?

If you have multiple datasets currently they still stack.

You might have to create a custom callback for the tooltips since they don't work correctly. This is what I used:
tooltips: {
    callbacks: {
        label: function(tooltipItem, data) {
            var label = data.datasets[tooltipItem.datasetIndex].labels[tooltipItem.index];
            var value = data.datasets[tooltipItem.datasetIndex].data[tooltipItem.index];
            return label + ': ' + numeral(value).format("$0,0.00");
    }
}

Thanks @GammaGames but I need to make the inner pie (most significant) wider then the external (less significant).
I'm OK with the tooltips :)

Smart one xD
Thanks @GammaGames for the explanation.
I'd rather keep it like this than hacking, let's wait for a proper way to customise it :)

Exactly my thoughts, though I did like @sheixt's creative workaround

Also needing this, @sheixt's workaround gets us where we need to be, but we have the canvas artifacts inbetween each dataset, as shown in @GammaGames' screenshot, so not perfect unfortunately.
Please could this be reviewed?
Thanks!

Exactly my thoughts, though I did like @sheixt's creative workaround

"Creative" is one way of looking at it... I felt it was a bit of a hack. On larger scale data processing, I'd imagine this may begin to be a performance hit as you are forcing the processing of multiple datasets where it shouldn't be necessary.
I actually ended up hacking a display for a speed-o-meter with an additional dataset and using the datalabels plugin. This shows the flexibility possible when you think outside of the box. But I think there is scope to extend the default functionality to allow for additional options such as the widths (as discussed here) and other chart type (e.g. a gauge).

This is an example of what I was able to achieve with utilising multiple datasets. I think in total the main bar in the gauge actually uses 3 of the same dataset to make it so wide in comparison to one for the labels (so it kept that thin).
Obviously if you wanted a bigger difference in the datasets, you could end up having to duplicate many time... which is far from ideal.


2.0.8-9 works and 2.0.10-11 don't

Hello.
I'm just writing most simple app on riot.

with versions 2.0.8 and 2.0.9 everything work. but 2.0.10 and 2.0.11 don't work and write this errors:

Screenshots are nice in some cases, but people most likely will not be ask quick to help you if they have to retype your work to do their own testing. Please use something like jsfiddle.

Oh, thank you, I forget about this tool.
This works: http://jsfiddle.net/#&togetherjs=suPHCmL7xs
but this doesn't work: http://jsfiddle.net/#&togetherjs=GSrv0SxKiG
jsfiddle hasn't so amazing tool like a console in a browser.
I realy don't understand that is going on. Cause I didin't see any changes in syntax in release notes. And I confused, why so simple code isn't working.

sorry for these links. It seems Im sleeping yet. )
I understand why doen't work.
http://jsfiddle.net/rudinandrey/gy0yuad4/ this works
http://jsfiddle.net/rudinandrey/maaz4awn/ this doen't work
why positions so important ? I mean I need to write code on the same column, for example if some close bracket is on the other column, it will be not working.

@rudinandrey The http://jsfiddle.net/rudinandrey/maaz4awn/ one does not work not because of position but because there is a space in your closing tag </test_> but I used underscored to point it out here. Make sure your tag is </test> and it works.

@tipiirai These probably should be white spaced trimmed by riot

Oh, thank you. But I think where were something else. Cause on the screen I have the same situation, and it's not working.
Ok, why aren't working next sample ?
http://jsfiddle.net/maaz4awn/3/
if I move close bracket under B of word body: ... it is working. Why so?

@tipiirai  I get a "TypeError: (intermediate value).bind is not a function", it looks to be trying to treat the "box" object definition block as if it was a function.
riot.tag('content', '
 riot.tag(\'h1\', \'{box.title}\', function(opts) { });
{box.body}

', function(opts) {

this.box = {
    title: "Good morning!",
    image: "http://trinixy.ru/pics5/20130614/podb_07.jpg",
    body: "It is when SO!"
}.bind(this);

});

It also has a literal riot.tag('h1', 'Good morning!', function(opts) ); defined in the html template of this tag.

@tipiirai Distilled it down to http://jsfiddle.net/pw43u9L8/
riot.tag('test', '', function(opts) {
riot.tag('div', '{test}', function(opts) {
}.bind(this);
this.test = "hello"

});

If the div is on the same indention as the opening of the custom tag define it causes issues. Another way this happens is when the open and closing tags of the custom tag are not on the same indention level even if the rest are indented in.

@sheastreet It seems a side effect of https://github.com/muut/riotjs/commit/91a602b169877f73ef0b61c70d0a3b93f19d76ac
I can PR the fix soon, maybe ;)

@cognitom any progress on this?

Hi, I think this issue won't fix. @GianlucaGuarini
Because we need a real parser for fixing this issue perfectory, not just regex. I made patch in #487 by just regex, but I felt it was little bit fragile. Finally I gave up this approach.
After some discussion, @tipiirai said...

My vote is forced indent with a syntax error message and also make this clear on the documentation.
I think we need a stronger argument for a full parser. I really like current RegExp one. It's super fast and small.

BTW, we got to add some warning on the document.

So could you please make a patch using console.warn?

Sure! I'll make it this night, maybe ;)


Add Terraria egg to DBH.

Terraria egg addition.

😂

https://github.com/DanBot-Hosting/pterodactyl-eggs/blob/67e5daf8973e5989c7782834b358bf39902f1ae7/README.md?plain=1#L2
Don't get me wrong but it's a repository for custom docker images, not parkervcp copycat.

https://github.com/DanBot-Hosting/pterodactyl-eggs/blob/67e5daf8973e5989c7782834b358bf39902f1ae7/README.md?plain=1#L2
Don't get me wrong but it's a repository for custom docker images, not parkervcp copycat.

I definitely I agree with this, I'll ask Dan tomorrow about it but there's 99% chance this will be closed.


add 'oraclejdk10' to Travis build matrix

The build was failing due to conflicts with Maven Surefire plugin and Mockito.


Add support to read attribute data

Add support to read attribute data

Any progress on this enhancement? I would love this

Alas it sounds easier than implemented in the current version of sleuthkit. The challenge here is that TSK_FS_ATTR does not offer a read and/or seek function. Also see: https://github.com/sleuthkit/sleuthkit/blob/develop/tsk/fs/tsk_fs_i.h#L88
This would mean that pytsk has to implement such a function itself, dealing with all the file system specific intricacies of reading attribute data.

Closing issue, long term investment in pytsk does not seem effective use of resources
See https://github.com/sleuthkit/sleuthkit/issues/1002 for context


Hangouts Bot  Edit Campaigns/Small Adjustments

The bot 'Edit Existing Campaigns' button is functional and allows users to jump back into the configuration process after picking the campaign of interest.  Additionally, improved error handling for the monetary settings (only accepts a decimal value message), make the bot skip negative locations if USA is not a target location (also allow the bot to accept n/a as negative location),  re-organized phase numbers to be in the same order as campaign overview, and fixed small typo errors with the messages.
Next steps include, allowing users to edit individual settings before submitting the campaign, check the DSACampaign Datastore Entities to ensure that duplicate campaign names are not being created, and allow users to view campaign results. I think after these features are added then the bot should be complete.

LGTM - just to confirm, you didn't handle default values for the dates in this PR right? Also

Move max CPC above daily budget
Remove advanced settings button

Added and no I did not add default date values yet, that's part of next steps.

Also wanted to add that I moved the bot to a different domain so the coexist issue is not there anymore.


My tutorial topic

Merge my tutorial topic after review.

Review requested for pr-72

It looks like this needs:

Sync fork
In clone, pull main branch of fork
In feature branch, rebase to main
Push feature branch to fork (this get's it up-to-date)
In feature branch, squash your commits
Push feature branch to fork (this pushes the single commit)
Update this pull request to be active, again (not Draft). In Draft mode, I can't do much with it.

Then it should be ready to go!
Thanks.

I followed your instructions for most part and opened a pull request again,
but am not sure how to submit a pull request with "no draft mode". What I
did differently last time was I selected "convert to draft" in my pull
request. I thought the exact opposite - that this will give more control
for you to freely edit in draft mode.
Also. I got stranded in step 4. After rebasing to main, I do not see a push
feature. I only got a message to create a Pull request. I assumed that the
pull request will update and reopen the existing pull request # 72.  How do
I do a push command from GitHub Desktop after rebasing a feature branch
with the main branch?
I'm still not getting the hang of it! Hopefully with my next practice, I
get better. Thx!
On Thu, May 16, 2024 at 4:21 PM Bob Watson @.***> wrote:

It looks like this needs:

Sync fork
In clone, pull main branch of fork
In feature branch, rebase to main
Push feature branch to fork (this get's it up-to-date)
In feature branch, squash your commits
Push feature branch to fork (this pushes the single commit)
Update this pull request to be active, again (not Draft). In Draft
mode, I can't do much with it.

Then it should be ready to go!
Thanks.
—
Reply to this email directly, view it on GitHub
https://github.com/UWC2-APIDOC/to-do-service-public/pull/72#issuecomment-2116111581,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AJBGKQZK5GU2GLODXOPL6N3ZCUIOLAVCNFSM6AAAAABHW74UBCVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCMJWGEYTCNJYGE
.
You are receiving this because you modified the open/close state.Message
ID: @.***>


unable to get packages what I have upload on my own Nuget Gallery azure website?

I have created a new azure website and uploaded code of NugetGallery on that.
Everything working fine (register new user,upload packages etc)
But When I enter my website url into package manager - package source - I do not get any packages it is just loading.
Created new available package source -
name - mytest
source- http://mydemosite-nuget.azurewebsites.net/packages
then also not loaded all packages :( why so?

Try source: http://mydemosite-nuget.azurewebsites.net/api/v2

thanka a lot


Feature: Switch by default to P2P version of web site when available

👍 👍 👍

Okay here's how I propose we do this:

[ ] Add a global setting to "Automatically redirect to dat:// when available", default on (auto_redirect_to_dat)
When a dat:// version is detected...

[ ] ...If auto_redirect_to_dat=1, then immediately redirect to the dat:// version
[ ] ...else, show the current "P2P version available" badge

[ ] After an auto-redirect to dat://, show a new badge that says "HTTPS version available" which will redirect to the https:// version. When clicked, the auto-redirect-to-dat for that site should be disabled for the browsing session.

Feature merged! Thanks to @Septimus for doing this!


Persistance + per branch tracking?

Hi, just to be clear, the harpoons are not saved to file currently, right? So that you can access your harpoons after quitting and reopening kak?
If so, do you have any plans to implement this? Would also be nice with the feature from the Neovim version of Harpoon that keeps track of harpoons per branch.
Anyway, thanks for the plugin!

Sorry for missing this, my github notifications are a mess right now.
I plan on persisting harpoons by the $PWD of the kakoune server in the future. As for branches, I didn't think about that, but it sounds awesome so I could potentially do that as well.

This ended up being significantly easier than I had anticipated. I've been wanting this for a while, and now it's finally in! Let me know if you have any problems with it.


[BEAM-1272] Align the naming of "generateInitialSplits" and "splitIntoBundles" to better reflect their intention

Be sure to do all of the following to help us incorporate your contribution
quickly and easily:

[X] Make sure the PR title is formatted like:
[BEAM-<Jira issue #>] Description of pull request
[X] Make sure tests pass via mvn clean verify. (Even better, enable
Travis-CI on your fork and ensure the whole test matrix passes).
[X] Replace <Jira issue #> in the title with the actual Jira issue
number, if there is one.
[X] If this contribution is large, please file an Apache
Individual Contributor License Agreement.

As discussed in the ML, rename generateInitialSplits and splitIntoBundles methods to splitIntoSubSources as well as @Test methods and description in javadoc.
R: @jkff
R: @staslev

linked to https://github.com/apache/beam-site/pull/210

R: @jbonofre

Coverage decreased (-0.003%) to 70.089% when pulling da52c7bff0004553d3cb605e843d88f4aa5ac820 on echauchot:BEAM-1272-renaming_generateInitialSplits_and_splitIntoBundles into 21a2b96a1f617870aa5926d69878a72533ba259e on apache:master.

Sorry I did not mention this in on the dev list thread, but I have a minor preference towards split over splitIntoSubSources, mainly because SubSource sounds like a new term we have not used before (as opposed to a split).
@echauchot  @jkff What do you think?

@staslev me too (as mentioned on the mailing list).

I find split a bit less precise on the intent than splitInto*Sources. But I agree than subSource seems like a new term. Maybe a simple splitIntoSources ?

The purpose of a split (in an IO) is to create sources anyway.

The purpose of a split (in an IO) is to create sources anyway.

+1

Maybe a simple splitIntoSources?

Source#splitIntoSources() looks a bit confusing, perhaps because it may not be immediately apparent why one needs to have more sources from the source she already has. I guess that while this method does return a list of things that are technically sources, it may not be intuitive for us humans to thinks of this process as splitting a source into sources (sounds a bit off).
What I like about simply split is that it does not put the emphasis on what the source is being split into (bundles/sources/sub-sources, etc.), but on the mere fact the it is being split (so that it can be parallelised).
Makes sense?

I'm fine with split.

It seems we have an consensus about split(). @echauchot can you update the PR accordingly please ? Thanks !

sure I'll update it. I'm fine with split also considering it is a method of *Source object, it's precise enough. Thanks for your feedback guys !

Coverage increased (+0.4%) to 70.451% when pulling 393839d1f50f81b1e0bd988004efb13fe8feb590 on echauchot:BEAM-1272-renaming_generateInitialSplits_and_splitIntoBundles into 21a2b96a1f617870aa5926d69878a72533ba259e on apache:master.

@echauchot This test error is no fault of this PR - it is because Dataflow worker depends on this method. Dealing with that in 1 commit requires a rather complicated process. Meanwhile, I suggest to simply add a (final and @Deprecated) method splitIntoBundles back to BoundedSource, which simply calls split(), and I'll help remove it afterwards.

+1 @jkff
@echauchot this is great stuff -- need any help pushing it through?

retest this please

@jbonofre this won't be mergeable until Etienne updates it with the (temporary) suggestion from Eugene in https://github.com/apache/beam/pull/2523#issuecomment-294162285

Coverage increased (+0.6%) to 70.661% when pulling 393839d1f50f81b1e0bd988004efb13fe8feb590 on echauchot:BEAM-1272-renaming_generateInitialSplits_and_splitIntoBundles into 21a2b96a1f617870aa5926d69878a72533ba259e on apache:master.

Good point, I missed that. Thanks.

Coverage increased (+0.6%) to 70.67% when pulling d1b8d3ac78913a89e8d7a11584e9535a36416ce4 on echauchot:BEAM-1272-renaming_generateInitialSplits_and_splitIntoBundles into 21a2b96a1f617870aa5926d69878a72533ba259e on apache:master.

It's still not good on the WordCount.

Yes, that's why it failed on the previous build. Let's wait this one.

Yes, I'm trying without the final method right now :)

Coverage increased (+0.6%) to 70.667% when pulling d568f55a6f156c54d9c0c9eea350c8ae83bb7d8a on echauchot:BEAM-1272-renaming_generateInitialSplits_and_splitIntoBundles into 21a2b96a1f617870aa5926d69878a72533ba259e on apache:master.

It's ok with the non-final deprecated splitIntoBundles method in BoundedSource for the dataflow integration. The build now passes.
PTAL

LGTM; @jbonofre feel free to merge. Thanks @echauchot !

Run Dataflow ValidatesRunner

actually please wait for this Dataflow test to pass, just in case.

@jkff , with pleasure ! Do you want that I fill a jira in DataflowRunner component to remember to rebuild the dataflow worker and remove the deprecated method?

@jbonofre @jkff: if you merge this PR, please don't forget that there is also a website update with it (https://github.com/apache/beam-site/pull/210)

Yeah, fixing the conflict and doing a new pass.


request: leveling: add counter between levels

Description
Hi!
I would suggest to add to leveling command an option to calculating the level between two adjacent levels that are not in order.
Now the script works so that when you reach level 21 you will get a message about reaching an empty level (no role)
For example
Level 20 - Marquis
Level 21 -
Level 22 -
e.t.c
Level 30 - Count
Solution
I suggest instead to take the name of an existing lower level role and add a step counter to the next role. That is, in the above example:
Level 20 - Marquis.
Level 21 - Marquis [2 lvl]
Level 22 - Marquis [3 lvl]
Level 23 - Marquis [4 lvl]
Level 24 - Marquis [5 lvl]
Level 25 - Marquis [6 lvl]
Level 26 - Marquis [7 lvl]
Level 27 - Marquis [8 lvl]
Level 28 - Marquis [9 lvl]
Level 29 - Marquis [10 lvl]
level 30 - Count
Code of Conduct

[X] I agree to follow this project's Code of Conduct.

To my knowledge, at present, the leveling system does not include the role reward in its level-up message; rather, it only mentions the new level. As such, I'm not too sure what to make of your request -- would you mind clarifying what exactly you're proposing? Thanks.

Closing as stale. Happy to reopen if you clarify your request per my previous reply.


HARVESTER: hide view config for backup

https://github.com/harvester/harvester/issues/1978
This PR hides the 'config' view for backups. The ResourceDetail Masthead renders the 'Detail' and 'Config' buttons when the resource has components defined in /view and /edit respectively: this is not appropriate for harvesterhci.io.virtualmachinebackup because the /edit/harvesterhci.io.virtualmachinebackup component is for the creation of harvesterhci.io.virtualmachinerestore resources. Initially I thought to restructure the backup/restore components to align with the assumptions made in ResourceDetail and type-map but it required many changes just to hide a button so I think this approach of making type-map and ResourceDetail more configurable is better.

Hi,  @mantis-toboggan-md,  harvester manages issues through zenhub so you need to install it

When the issue is completed，When the pr is submitted and in reviewable status, please move the issue into the review column.

When the issue is moved to the review column, the following content will be automatically generated in the comment of the issue.  Please help to fill in the checklist

When the issue is merged and ready for testing, please help move the issue into the Ready For Testing column.

thanks.

Thank you @WuJun2016 , I've installed zenhub and updated the associated harvester/harvester issue as requested.


O365 license required to run the solution

Hello,
I'm testing the solution on my tenant where I have all kind of subscription and Azure services so I don't have any license limitation.
It's very hard to understand which license are required by a "common" customer, could you please help me?
Thanks a lot!

@rferazzi the only licenses required are as follows -

Office 365 license - A1 and up so A1,A3,A5,E3,E5 etc
Paid Azure subscription (for the billable Azure components)

NO premium licenses for Power Apps or Power Automate are required.
Does that help?

@rferazzi hope you are sorted now, I'll be closing this issue.
Please raise a new one if you are still stuck.
Thanks


chef-client not usable after bootstrap with recipe rvm::system

I've bootstrapped an ubuntu 10.04 system with rvm::system in the run list.
chef 11..4.0 was installed to /opt/chef
Now chef-client doesn't run.  For the time being I've manually installed chef into the global gemset (which I will roll into my recipe later), but I'm wondering if anyone knows of a supported way to get this to work without using a custom bootstrap as @fnichol mentions in #91?  Or is installing chef gems into the global gemset the best there is for the time being?
Thanks

Is this still an issue?

Probably, as I still have the same recipes in production.  However, I've found another workaround by changing rubies by running rvm system.  Then chef is able to find it's embedded ruby.

Ok, closing this for now


Simplified payment button customisation. #196

With this PR it is possible to customise the payment button by doing just this:
from django.utils.html import format_html

from paypal.standard.forms import PayPalPaymentsForm

class CustomPayPalPaymentsForm(PayPalPaymentsForm):

    def get_html_submit_element(self):
        return format_html(
            """<button type="submit">Continue on PayPal website</button>"""
        )

This looks like a nice improvement, thanks!
Would you be able to write some docs? I think a new section on overriding the form at the bottom of this page would be good: https://django-paypal.readthedocs.io/en/latest/standard/ipn.html

@spookylukey I updated the docs adding the button customisation block and fixing a broken link.

Thanks!


Cache-aware functionality

Since some API calls can be cached, it would be nice if ratelimit could somehow be made aware of the cache.
For example, with the very simple to use requests_cache library you can cache all responses made by the requests library by default.
If your request is r = requests.get('http://example.com/api') you can check r.from_cache which will return True if the response was read from cache.
It would be awesome if I could easily make ratelimit aware of the last time an actual API call was made using r.from_cache in my function so it would only rate limit actual API calls. Something like this:
@ratelimit(1, 10)
def apiCall():
    r = requests.get('http://example.com/api')
    if r.from_cache:
        ratelimit.skip()

Would this be terribly difficult to implement or is there already a way to do this that isn't documented in the readme? The hook method doesn't account for time the rest of the script is running between API requests so it wastes a lot of time.

Can't you have a cache decorator wrap around what you have? So the cache decorator would be hit first and it would return the results if there's something in the cache. If not, the rate limit decorator would be hit that would check if there have been to many API calls.
I haven't tried it, but I'm using Django's [cache_memoize](https://github.com/peterbe/django-cache-memoize) and I think it could work like this:
@cache_memoize(3600)
@ratelimit(1, 10)
def apiCall():
    return requests.get('http://example.com/api').text

If that works that would be awesome. I'd be happy to add it to the documentation.


Can't build from tar.gz or zip

$ wget https://github.com/oakes/SolidOak/archive/0.1.0.tar.gz
$ tar -xzf 0.1.0.tar.gz
$ cd SolidOak-0.1.0
$ cargo build
...
src/utils.rs:30:20 30:76 error: couldn't read resources/soak/after/syntax/rust.vim ...
...

It looks like resources/soak is empty, so perhaps whatever you're using to create the source packages isn't doing a git submodule init && git submodule update? Building from master works.

Github makes the source archives automatically, so I'm not sure what to do about that.

I'll close for now, but if you know of a way to adjust how Github creates the archives then please let me know.

I think the only real way of doing this is to put some tooling in build.rs to pull down an archive of soak if soak is going to remain a separate repository.
I built an AUR package for git head, but this prevented me from making one based on your 0.1.0 release. Maybe later...


Delete vault by force instructions are not cross-platform

The "Delete the Recovery Services vault by force" section only works on Windows as far as I can tell.

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

ID: 728cc3f4-d5da-a270-a3c0-53f179147cc0
Version Independent ID: 32d276c0-0980-ff36-933b-5012a39f75c5
Content: Delete a Recovery Services vault in Azure '
Content Source: articles/backup/backup-azure-delete-vault.md
Service: backup
GitHub Login: @rayne-wiselman
Microsoft Alias: raynew

You can use Cloud Shell available in portal to achieve this. Please select PowerShell after you launch Cloud Shell.

@samuela We will now proceed to close this thread. If there are further questions regarding this matter, please tag me in your reply. We will gladly continue the discussion and we will reopen the issue.


fix: replace sed with vgrep

[x] I have reviewed CONTRIBUTING.md.
[x] My commits and title use the Conventional Commit format.
[x] I have documented changes and additions in the CHANGELOG.md.

tested on Arch & OS X

(remove the date as well, heading should just be ## Unreleased)


Implement a simple matching web service

Implement a simple matching web service to post GPX files and get the snapped response as GPX or GraphHopper JSON

Make executable via script and add some better documentation


Create a table under a non exsting schema

Please provide a sample json on how to specify schemas with tables.

Hi @althaf004 👋
There is currently no way to create a new schema with a pgroll migration. Migrations are expected to run in an already-existing schema.
Once the schema exists, the schema in which the migration should run is specified with the --schema flag, eg:
pgroll start examples/01_create_tables.json --schema my_schema_name

This will ensure that the tables created by the migration are created under my_schema_name.

if I have 15 custom database schemas, and there are changes needed in all the tables within these schemas, do I have to create 15 different JSON files and execute each JSON file separately for each schema?

If the migration is the same for each schema you only need one migration file. For example to run a migration called 01_create_tables.json in each of the 15 schema you could run:
#!/bin/bash

# Define an array of schema names
declare -a schemas=(
  "schema1"
  "schema2"
  # and so on for each of the schema names
)

# Loop through each schema name and invoke pgroll
for schema in "${schemas[@]}"; do
  echo "Running pgroll with --schema=$schema"
  pgroll start 01_create_tables.json --schema="$schema"
done

The script runs the same migration file in each of the 15 schema.

hey, But migration scripts should not be same for each schemas, it could differ from schema to schema.
Say - schema A needs to have a table created.

schema B needs to have an alter column

is it possible to have the above statements in a single json and run it.

hey, But migration scripts should not be same for each schemas, it could differ from schema to schema.
Say - schema A needs to have a table created.

schema B needs to have an alter column

is it possible to have the above statements in a single json and run it.

In that case you would need different migration files for each schema.
If you wanted to automate it you could use a script like:
#!/usr/bin/env bash

# Declare an associative array to map schema names to migration files
declare -A schema_to_json=(
  ["schema1"]="examples/01_create_tables.json"
  ["schema2"]="examples/02_create_another_table.json"
  # and so on for each schema
)

# Run the migration file for each entry in the associative array
for schema in "${!schema_to_json[@]}"; do
  json_file="${schema_to_json[$schema]}"
  pgroll start "$json_file" --schema="$schema"
done


Implement queue parameters feature

We can now interact with all the queue parameters (like read-ahead, request queue depth, and the IO scheduler)

+1


apps/speed.c: add -aead flag.

Goal is to exercise AEAD ciphers in TLS-like sequence, i.e. 13-byte
AAD followed by payload.
[While we are at it, address even some styling issues.]

I had a brainslip, pushed update...

Red cross from travis is unrelated, and [should be] addressed in #6315.


Create user deferral and change standard deferral to "application hidden"

We should give the user an option to manually defer and then count that amount of times (+ calculate seconds deferred).
some ideas:

Simple Counter
Date Selector and part2

204 resolved the manual defer and 210 resolved the logging of counts


Custom Extension Activity Bar Icon Disappears

I am in progress of updating an extension.  The extension adds an activity bar icon to help manage a custom server I am creating.  I have had the extension on the marketplace for about a year with no issues with regards to the icon being used.
With the latest update, I find that, when I hit F5 to debug, the activity bar icon randomly "disappears" from the left sidebar.  I can pretty well duplicate it by doing the following:

Closing out of Code
Relaunching from scratch
F5 to debug the extension
The icon will show up on the first time through.
I close the Extension Development Host
I relauch F5 to debug
The "spot" where the icon is supposed to be still "works" (i.e. the action button still launches the extension), but the icon itself is blank

Things I have tried:

Totally cleaning out my Code install and reinstalling from scratch so that there are no extensions or customizations.  Can reproduce still.
Trying a number of different icons.  Same result.
I did try going back one version (1.53).  Doing this fixed the issue and the icon never disappears with no change to my codebase at all.

I looked through the documentation and saw nothing that would indicate the requirements have changed for the icon and this is the one I've been using for a year, so I can only surmise perhaps something changed in this release?
Thanks in advance for any assistance!

Version: 1.54.1
Commit: f30a9b73e8ffc278e71575118b6bf568f04587c8
Date: 2021-03-04T22:42:18.719Z
Electron: 11.3.0
Chrome: 87.0.4280.141
Node.js: 12.18.3
V8: <IP_ADDRESS>-electron.0
OS: Darwin x64 20.3.0

This is my relevant package.json information.
        "viewsContainers": {
            "activitybar": [
                {
                    "id": "omnihive",
                    "title": "OmniHive",
                    "icon": "resources/images/activitybar.svg"
                }
            ]
        },

Here is a Dropbox link to the SVG since that cannot be pasted here:
https://www.dropbox.com/s/8qorzpfmqwot8q3/activitybar.svg?dl=0

I have also reported a duplicate of this with VSCode 1.54.1.
I will close mine out as a duplicate https://github.com/microsoft/vscode/issues/118338

I see it as well with CodeStream and its .svg icon
Version: 1.54.3 (user setup)
Commit: 2b9aebd5354a3629c3aba0a5f5df49f43d6689f8
Date: 2021-03-15T10:55:45.459Z
Electron: 11.3.0
Chrome: 87.0.4280.141
Node.js: 12.18.3
V8: <IP_ADDRESS>-electron.0
OS: Windows_NT x64 10.0.19041

"viewsContainers": {
			"activitybar": [
				{
					"id": "codestream-activitybar",
					"title": "CodeStream",
					"icon": "assets/images/codestream.svg"
				}
			]
		},
		"views": {
			"codestream-activitybar": [
				{
					"id": "activitybar.codestream",
					"type": "webview",
					"name": "CodeStream",
					"icon": "assets/images/codestream.svg",
					"contextualTitle": "CodeStream"
				}
			]
		},

I've also encountered this bug.
This is the extension i'm developping that adds a viewsContainers to the activity bar: https://github.com/boltex/leointeg

same issue!
it've occurred for all installed extensions.

Hi,
I have version 1.63 in portable mode on my laptop where all icons are visibles (W10)  If a use this version on my desktop PC (W10), the icons of all installed extensions are invisibles.

Hello,
I've have found a difference between my laptop and may desktop PC :

laptop :  I can preview svg icon  in the Developper Tools (and the activity bar looks fine)
desktop : I have a "nothing to preview" message but I can see the icon outside VS Code.

Hello there,
It had the problem in VSCode-win32-x64-1.63.0 and  VSCode-win32-x64-1.64.0 in portable mode.
Version VSCode-win32-x64-1.66.0 fixe the problem for me !
I use the same portable "data" folder than version 1.64
Note : Icons are also visibles in the developper tool (no more "Nothing to preview")
Great !
Cheers

@doug-shontz Sorry for attending to this after a long time. Since it is a long time, can you please try to reproduce it again with our latest updated build and let us know if you still see the issue? If so, can you please provide steps to repro?

This issue has been closed automatically because it needs more information and has not had recent activity. See also our issue reporting guidelines.
Happy Coding!


Downloads: Make subset modal scrollbars always visible

Taken from #656:
When the subsetting results table is large enough that the user needs to scroll down to see the bottom of the table, the left/right scroll bar is cut off from view. Please make this scroll bar always visible (like up/down scroll, which is always visible regardless of what part of the table you are looking at)

This issue has been addressed in the Download Tab PR. 😄

ClinEpi outreach team has review the functionality of the scroll bars and have determined that it meets our initial request.


fix sass imports from npm modules

As of npm v3, dependencies get flattened automatically so we can't rely on absolute paths for our codemirror (and potentially other) sass imports. This fixes the issue. Also removes responsive-filenames from our gulp script, since it's unused in kiln.

👍


Create tray-indicators

Displays your hitpoints, prayer, or absorption in the system tray.
Icons can be disabled individually. Colors are fully customizable.

Please add a support URL to your runelite.properties file. (it can be your plugin's repository URL, for instance)
Please also license your repository.

@Nightfirecat I added a support URL to the runelite.properties file. I also added the license to the repository.


Purpose of opts.extensions?

When calling fileOpen, AFAIK the extensions doesn't really do anything on top of mimeTypes. At least on Windows (via Excalidraw) it does not.
What is it supposed to do, and why do/should we supply both mimeTypes and extensions?

Some operating systems support extensions, some support MIME types, and some support both. It’s a recommended best practice to supply both for maximum compatibility. For example:
.jpeg, .jpg
image/jpeg
We have the same behavior in the <input type=file> element: https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/file#attr-accept.

Thanks. I was also wrong it doesn't do anything, Excalidraw was just on an older version.


Not so small-fixes

@GunshipPenguin could you please review branch locally before deploying?
Check README for new instructions on building

Migrated from Less to SCSS
Migrated from Browserify to Webpack
Migrated from Typescript to Babel
Began using yarn
Registered service worker
Removed Bootstrap dependency
Sick hot module replacement and dev dashboard. npm run watch
Standard JS code style
Fixed duplicate cards in specific trends caused by non-unique key attribute
Fixed not pulling more cards in specific trends
Usability improvement on all trends chart, swiping left and right instead of clicking arrows
Fixed all trends chart horizontal labels getting slanted
Added unit tests for network bus
Added routing using react router
Article cards show and hide description style change

@GunshipPenguin let's work towards moving this branch forward.
Worth pointing out that routing is in place, the entry point is not necessarily senti.social, it is possible to also enter from senti.social/trends/{name}.
When deploying this code, the webserver needs to redirect all traffic (senti.social/*) to the index page, the router I implemented will handle displaying the correct page.
It would also be helpful if trend data is never deleted in order to avoid 404 errors.


VQE example is broken due to SDK mismatch in Braket notebooks

Currently, the VQE Chemistry example notebook uses FreeParameter in the notebook. The SDK in notebooks uses an older version than where FreeParameter occurs. Long term fix is being worked on internally.
Short term fix:
under the Imports and setup cell, you can change it to read::
# create a directory named "data" to store intermediate classical computation results from OpenFermion
!mkdir -p "data"
!pip install amazon-braket-sdk==1.17.0
!pip show amazon-braket-sdk

Issue has been fixed with newest notebooks.
Recommendation: Customers to stop-start their notebooks to pull in the latest changes.


Add ability to define default values

Right now, it is not possible to define default values for classes. This is due to dart not allowing default values on redirecting constructors.
We should support this, possibly using the same approach as freezed by using a special annotation (https://pub.dev/packages/freezed#default-values).

@jankuss hey there! Thanks for an amazing tool. Is this default value feature coming any time soon?

@jankuss hey there! Thanks for an amazing tool. Is this default value feature coming any time soon?

hey, I'm still working on it - unfortunately this is a bit more complex to solve, as we did not have to implement expressions yet.


Add option to specify --fixed-model-name

This implements issue #23.

Until this PR is approved, this version of the github action can be used by referencing<EMAIL_ADDRESS>

@camattin or @trammell do you have time to review this PR?

Agree with @lumpidu, if you can remove those two blocks from this PR then it will be good to go.

Yes, the other PR should be reviewed and merged first.


Can't get the sample work

Hi. I'm trying to get your sample works but actually I can't find what I'm doing wrong.
This line fails:
let JSONString = Mapper().toJSONString(user, prettyPrint: true)
I took your entire class to try to make it work but I'm getting this error:
Cannot invoke 'toJSONString' with an argument list of type '(User?, prettyPrint: Bool)'
Do you know this problem?

I believe you are getting this error because you are passing in an optional User object into the toJSONString function.
I suppose my sample could be updated to the following:
let user = Mapper<User>().map(JSONString)

if let user = user {
     let JSONString = Mapper().toJSONString(user, prettyPrint: true)
}

or you can force unwrap the user object
let JSONString = Mapper().toJSONString(user!, prettyPrint: true)

Hope this helps

Thanks for your quick answer. Indeed my error was there, thanks for your time.


[Extension] Improve EVM network fee

Hotfix fee for BSC
Build middleware for EVM fee service

Action
Transaction type

Send native token
EVM

Send local token
EVM

Send xcm
Substrate

Send NFT
EVM

Native staking
Substrate

Stella staking
EVM

Version test: http://<IP_ADDRESS>:8900/s/5EPspG5fszByBde
Validation passed for cases:
| Action | Transaction type | Test result
| --- | --- || --- |
| Send native token | EVM: Call API | Passed: https://bscscan.com/tx/0xd02d044e5b6d1cbd47e78a56cf4ded6beaf14761437ea545a24386b8cdef0492
| Send local token | EVM: Call API | Passed:
| Send xcm | Substrate: Do not call API | Passed: Check log call API
| Send NFT | EVM: Call API | Passed: Check log call API and send https://moonbeam.subscan.io/extrinsic/0x64d586b50755e62665bb17db4e35460d6fa4994923f6ee6dfb4484dac31971cb
| Native staking | Substrate: Do not call API | Passed: Check log call API
| Stella staking | EVM: Call API | Passed: Check log call API
| Check fallback | EVM: Call API (Moonbase, Moonriver) | Passed https://moonriver.subscan.io/extrinsic/0x4519eb602775fa6b05a8b89642be4d7fe4b07d2a1b73b0255a6e309cb53ca96c


Domain activation is Failed - Added CNAMEs after a delay, and now "Retry" is not working

App Id: d3sucvvj2fsjhr
Region: eu-west-1
Step: Domain activation
Status: Failed
Issue/question
Domain activation is failing for my subdomain xxx.yyyy.zzz (example). I had previously tried to add it as a subdomain for my Amplify app, couldn't get it to work, and then deleted and re-added it.  Upon re-adding it, verification under "Status details" proceeds successfully up to SSL verification, then fails on the final step. I have tried the "Retry" button a couple of times, but it's not working.
Error message
A red banner at the top of the page shows: "We had issues connecting your custom domain: xxxx.yyyy.zzz. Please visit the Domain Management page for more information."
And then under "Status details":
"Something went wrong. Please refer to our troubleshooting guide below to diagnose the issue. After fixing the issue, choose retry below. If retrying fails, please create an issue in our GitHub issue tracker.
Error message: One or more aliases specified for the distribution includes an incorrectly configured DNS record that points to another CloudFront distribution. You must update the DNS record to correct the problem. For more information, see https://docs.aws.amazon.com/AmazonCloudFront/latest/DeveloperGuide/CNAMEs.html#alternate-domain-names-"
Additional information
I have verified, using a DNS lookup, that the new CNAME record for is set up on the domain, not the old one.

@JohJonker Please see:
https://docs.aws.amazon.com/amplify/latest/userguide/custom-domains.html#cnamealreadyexistsexception-error
https://aws.amazon.com/premiumsupport/knowledge-center/resolve-cnamealreadyexists-error/
These guides are helpful for getting started with custom domains, for existing domains there are number of steps that will need to be completed (as outlined in the docs above) depending on your current hosting and DNS providers.
A CNAME alias (mydomain.com, sub.mydomain.com) can only be associated with a single CloudFront distribution at a time, if you receive this error then the domain is already associated with another CF distribution (either within the same AWS account, or potentially in a different account) and must be disassociated from the previous distribution before the distribution created for you by Amplify Console will work, the docs help outline how to do this (and you may need to check more than one account if you or your organization owns multiple accounts)
Additionally, if you manage your domain through Route53, make sure to clean up any hosted zone CNAME or ALIAS records that point to the old distribution. After completing the above, I would remove the domain from Amplify Console and start the flow over.

Thanks for the response @kahdojay .
I don't have any Cloudfront distributions. I only use Amplify, i.e. it creates the distributions for me automatically, and I have no way of managing it directly.
I tried removing the subdomain and re-adding it, but I'm hitting the same error.
How can I force Amplify to 'release' the Cloudfront distribution, so that it can be added anew?

Hi @JohJonker I do see that the domain is pointing to a cloudfront domain but it no longer exists. Can you delete the DNS records, and if it won't cause disruption, delete and recreate the custom domain?

Closing this issue, please feel free to reopen it if you still face custom domain issues. Thanks!


nomad: 0.9.3 -> 0.9.4

Motivation for this change
Nomad 0.9.4 was released yesterday.
Things done

[ ] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS)
Built on platform(s)

[x] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[x] Tested compilation of all pkgs that depend on this change using nix-shell -p nix-review --run "nix-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[x] Ensured that relevant documentation is up to date
[x] Fits CONTRIBUTING.md.

Notify maintainers
cc @rushmorem @pradeepchhetri

Looks good with sandbox on too.

This pull request has been mentioned on Nix community. There might be relevant details there:
https://discourse.nixos.org/t/prs-already-reviewed/2617/53


The type 'Task<>' is defined in an assembly that is not referenced

Hi
update the android SDK, and update version library <IP_ADDRESS>, and after that I generated this error.
any idea that I needed to update
Severity	Code	Description	Project	File	Line	Source
Error	CS0012	The type 'Task<>' is defined in an assembly that is not referenced. You must add a reference to assembly 'System.Threading.Tasks, Version=<IP_ADDRESS>, Culture=neutral,

Sounds like some of your project references are not quite correct.  Going to need some more info, maybe post a reproducible sample with the error.

Hey there
adds reference to the project in VS 2015
" the System.Threading.Tasks.dll explicitly from C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework.NETCore\v4.5.
and compiles and not generates errors
when testing the phone I commented
thanks


First impressions tracking issue

Using my day off to build a little HTTP server on top of the stdlib and http; Here's some issues @ashleygwilliams and I are finding. I'm not suggesting it has to be this way, mind you, just things to consider.

[ ] https://github.com/steveklabnik/simple-server/issues/3
[ ] https://github.com/steveklabnik/simple-server/issues/2

I'm going to assume this is resolved now.


Feature: WAF using ModSecurity CRS 3 and concern with WAF rules

Hi, is there a plan to explore the use of Modsecurity OWASP CRS v3 for the Roxy-Wi?
Also, I've been testing the Roxy-Wi for quite sometime and it works, but previously I've been testing the WAF and it seems the CSRF rules are not working by default(even though the rules is included in the waf/rules directory, I've looked through some documentations and modified modsecurity.conf to link the csrf and other relevant rules to it but when I tried to, the WAF is unable to start, and cannot find any detailed logs but assuming it is related to the rules I've enabled, namely csrf and hijacking_session.
would you be able to give me an advise. realyl appreciate it. Thanks

Hi,
About Modsec v3, one day it will happen.
Not all rules work by default, Roxy-WI includes only rules which work with ModSec v2 by default. By default Modsec writes log into /var/www/waf.log, if it has been installed via Roxy-WI. I guess something could be there, I didn't dive deep


Make links work, basically it's just datasets vs dataset

https://www.opendataphilly.org/dataset/police-activity-league-centers
https://next.opendataphilly.org/datasets/2009-2012-police-advisory-commission-complaints/
Setup a redirect

This is much more difficult then I first though, but not impossible: https://github.com/jekyll/jekyll-redirect-from/issues?q=is%3Aissue+wildcard+is%3Aclosed
Instead of being a wildcard, we would need to generate a new copy file for each one (or modify each dataset).  I'm dropping from the initial goals.


Unable to download docker images from registry.k8s.io due to x509: certificate is not valid for any names, but wanted to match prod-registry-k8s-io-ap-south-1.s3.dualstack.ap-south-1.amazonaws.com

Is there an existing issue for this?

[X] I have searched the existing issues

What did you expect to happen?
Image should have been downloaded, but stuck in below error.
docker pull registry.k8s.io/kube-scheduler:v1.26.9
v1.26.9: Pulling from kube-scheduler
a7ca0d9ba68f: Already exists
fe5ca62666f0: Already exists
b02a7525f878: Already exists
fcb6f6d2c998: Already exists
e8c73c638ae9: Already exists
1e3d9b7d1452: Already exists
4aa0ea1413d3: Already exists
7c881f9ab25e: Already exists
5627a970d25e: Already exists
167eb620404e: Already exists
23d25d10ce41: Retrying in 1 second
error pulling image configuration: download failed after attempts=6: tls: failed to verify certificate: x509: certificate is not valid for any names, but wanted to match prod-registry-k8s-io-ap-south-1.s3.dualstack.ap-south-1.amazonaws.com
Debugging Information
dig registry.k8s.io working
TL;DR
;; ANSWER SECTION:
registry.k8s.io.	764	IN	A	<IP_ADDRESS>
curl -v https://registry.k8s.io/v2/  working
TL;DR

GET /v2/ HTTP/2
Host: registry.k8s.io
user-agent: curl/7.68.0
accept: /

TLSv1.3 (IN), TLS handshake, Newsession Ticket (4):
TLSv1.3 (IN), TLS handshake, Newsession Ticket (4):
old SSL session ID is stale, removing
Connection state changed (MAX_CONCURRENT_STREAMS == 100)!
< HTTP/2 200
< docker-distribution-api-version: registry/2.0
< x-cloud-trace-context: 529ad23c3077eb99aaddb7b7a87f384e
< date: Tue, 10 Oct 2023 04:38:49 GMT
< content-type: text/html
< server: Google Frontend
< content-length: 0
< via: 1.1 google, 1.1 google
< alt-svc: h3=":443"; ma=2592000,h3-29=":443"; ma=2592000
<
Connection #0 to host registry.k8s.io left intact

Anything else?
When trying to check ssl certificate of prod-registry-k8s-io-ap-south-1.s3.dualstack.ap-south-1.amazonaws.com by manually, its giving following errors
-- verify error:num=20:unable to get local issuer certificate
-- verify error:num=21:unable to verify the first certificate
openssl s_client -showcerts -connect prod-registry-k8s-io-ap-south-1.s3.dualstack.ap-south-1.amazonaws.com:443 </dev/null
CONNECTED(00000003)
depth=0 CN = untangle
verify error:num=20:unable to get local issuer certificate
verify return:1
depth=0 CN = untangle
verify error:num=21:unable to verify the first certificate
verify return:1
depth=0 CN = untangle
verify return:1
Certificate chain
0 s:CN = untangle
i:C = US, ST = California, L = Sunnyvale, O = Untangle, OU = Security, CN = www.untangle.com
a:PKEY: rsaEncryption, 2048 (bit); sigalg: RSA-SHA1
v:NotBefore: Jan  2 03:04:05 2010 GMT; NotAfter: Jan  2 03:04:05 2038 GMT
-----BEGIN CERTIFICATE-----
MIIDiDCCAnCgAwIBAgIIFAJXJkkAAAAwDQYJKoZIhvcNAQEFBQAwdzELMAkGA1UE
BhMCVVMxEzARBgNVBAgTCkNhbGlmb3JuaWExEjAQBgNVBAcTCVN1bm55dmFsZTER
MA8GA1UEChMIVW50YW5nbGUxETAPBgNVBAsTCFNlY3VyaXR5MRkwFwYDVQQDExB3
d3cudW50YW5nbGUuY29tMB4XDTEwMDEwMjAzMDQwNVoXDTM4MDEwMjAzMDQwNVow
EzERMA8GA1UEAxMIdW50YW5nbGUwggEiMA0GCSqGSIb3DQEBAQUAA4IBDwAwggEK
AoIBAQCue1N+lqJX2p1/tSOhMwFZsFxmVuOFqb4RiCYG+n6VUsERL7A2zt3uzom+
KgmcACMnDnmAhZsfTpLEZzBWT5o1uqfiAWj4TBXbo1EU0vaHn9jwp5kC+sNkzVmJ
1M7pJ/B9dL2jcpY17OEKm72a4hZPlo6q+FnjR2o8XWjeSbeNDC5lo22lA14KwjeK
UufScnIyQmEAC+tq4QvpXwt6lWyFPHqARWv0tlkoRrtAtXQB7/Yg92j5B1FG2mUl
Zq3/HqlEBb3o7hPjIzXK6HZcX5IOFdFS5nMPkHbkI9PMr8fp4EEjZGnZ84f78HL5
d8ONqT3ZMDjbHBNcsNfyNHfwI2OzAgMBAAGjfDB6MAkGA1UdEwQCMAAwLQYJYIZI
AYb4QgENBCAWHlVudGFuZ2xlIENlcnRpZmljYXRlIEF1dGhvcml0eTAdBgNVHQ4E
FgQUffPtvUkw2RgzJmRzufEYZZHq/hwwHwYDVR0jBBgwFoAUo3aMax6f0Bs2Vy2M
CaXqmORZQ4kwDQYJKoZIhvcNAQEFBQADggEBAKqn9Q+T3N2G4NaehiGZ3WVroskf
bIUadeZsKOYv0HryIfCrtZRqz1W3Wi3z4y4s8gXDWZ5s/XayldkYhEMtBxHUfMUr
zetYP19c1GgPjrxUXZHoWzjOPFQnkZvIWx53UzbJicjgE5CYlwbemVS7F2SrPyof
jc7xMgflFZhQkELeWngSQIlKg3iChVFfkF0FIOVm7upuUHhGN4xqacNjFXPqQSav
ccjM42EJ4k4HX+HpKenZ96Y3rsE3FMl6teJ6MgbXXrH+v3oMK8qoS4JYAqiRrbpQ
HbxBHSnPZUeVIPjgQlUh3Dzzmy649M9rLUWnhFlAdgFJmrtPtsh0tduM3dY=
-----END CERTIFICATE-----
Server certificate
subject=CN = untangle
issuer=C = US, ST = California, L = Sunnyvale, O = Untangle, OU = Security, CN = www.untangle.com
No client certificate CA names sent
Peer signing digest: SHA256
Peer signature type: RSA-PSS
Server Temp Key: X25519, 253 bits
SSL handshake has read 1440 bytes and written 455 bytes
Verification error: unable to verify the first certificate
New, TLSv1.3, Cipher is TLS_AES_256_GCM_SHA384
Server public key is 2048 bit
Secure Renegotiation IS NOT supported
Compression: NONE
Expansion: NONE
No ALPN negotiated
Early data was not sent
Verify return code: 21 (unable to verify the first certificate)
DONE
Code of Conduct

[X] I agree to follow this project's Code of Conduct

Duplicate issue created by mistake.


input error: attempted to use tensor with unrecognized shape: 1,1,196,200,3

Issue Description
I'm getting the occasional strangely shaped tensor in production:
input error: attempted to use tensor with unrecognized shape: 1,1,196,200,3
Steps to Reproduce
Use the attached file for face detection:

const tf = require('@tensorflow/tfjs-node') // Required
const Human = require("@vladmandic/human").default
const app = require("express")()

const human = new Human({
  modelBasePath: 'file://../../node_modules/@vladmandic/human/models'
})

const configuration = {
  backend: 'tensorflow',
  face: {
    enabled: true,
    detector: { maxDetected: 10 }
  },
  body: { enabled: false },
  hand: { enabled: false },
  gesture: { enabled: false },
  filter: { enabled: true, width: 2048 },
  cacheSensitivity: 0
}

    const tensor = human.tf.tidy(() => {
      const decode = human.tf.node.decodeImage(req.files.image.data, 3)
      const expand = human.tf.expandDims(decode, 0)

      return human.tf.cast(expand, 'float32')
    })

    human.detect(tensor, configuration).then(result => {
      res.json(
        map(filter(result.face, { faceScore: 1 }), (face) => {
          return pick(face, ['box', 'boxRaw', 'boxScore'])
        })
      )
    }).catch(() => {
      Bugsnag.notify
      res.status(500).send("Unable to process the image for faces.")
    }).finally(() => {
      human.tf.dispose(tensor)
    })

Expected Behavior
It shouldn't find a face and shouldn't raise an error.
Environment
    "@tensorflow/tfjs-node": "^4.21.0",
    "@vladmandic/human": "^3.3.2",

I agree, but please post reproducible code snippet if possible, makes any kind of solution much faster.

Ok, will do :) Just a simple node script?

Ok, here you go :)
const fs = require('fs')
const tf = require('@tensorflow/tfjs-node') // Required
const Human = require("@vladmandic/human").default

const human = new Human({
  modelBasePath: 'file://../../node_modules/@vladmandic/human/models'
})

const configuration = {
  backend: 'tensorflow',
  face: {
    enabled: true,
    detector: { maxDetected: 10 }
  },
  body: { enabled: false },
  hand: { enabled: false },
  gesture: { enabled: false },
  filter: { enabled: true, width: 2048 },
  cacheSensitivity: 0
}

human.tf.ready().then(human.load()).then(() => {
  fs.readFile('image.gif', (_err, data) => {
    const tensor = human.tf.tidy(() => {
      const decode = human.tf.node.decodeImage(data, 3)
      const expand = human.tf.expandDims(decode, 0)

      return human.tf.cast(expand, 'float32')
    })

    human.detect(tensor, configuration)
  })
})

You'll just need to adjust 'file://../../node_modules/@vladmandic/human/models' depending on where your models are.

seems like tf.node.decodeImage changed default behavior in recent version of tfjs-node.
remove this

const expand = human.tf.expandDims(decode, 0)

with that, you end up with extra dimension.
without that, your tensor is in a correct shape: 1,1,196,200,3 = batch=1 x height=196 x width=200 x channels=rgb

That's interesting. I've had a look at the source code:
https://github.com/tensorflow/tfjs/blob/8fcd129f3c1daaaf503a3c8f0a6697e11e1f2e1b/tfjs-node/src/image.ts#L155-L186
Is it not related to this being a GIF and decodeImage returning a 4 element array in that instance (by default since it expands the animations by default)? I'll do some additional testing but I suspect we instead need to tell decodeImage to not expand animations and then still expandDims to get the right tensor shape.

In my testing, simply removing that line didn't account for animated GIF's. This is what seemed to work:
const decode = human.tf.node.decodeImage(data, 3, 'int32', false)
const expand = human.tf.expandDims(decode, 0)

However, now we can also remove const expand = human.tf.expandDims(decode, 0) and it still works. I don't know enough details as to why that is ok :D

ahh, animated gif - that explains it - each frame gets decoded into batch.
what you just did would result in only first frame being decoded.
or you can decode all and then check if batch dimension exists - if not, then do expanddim conditionally.

Indeed :) For the purposes of a single face detection for cropping purposes the first frame works fine. It's an unlikely use case in any regard, just need to stop it from blowing up even if the outcome of cropping a GIF based on the face in the first frame would be weird! :D