Same email is received multiple times by the bot

Hi
When I send an email to the Bot registered email address, i get between 3 to 5 replies from the bot. When I debug the bot locally I can see it receives the same email multiple times. The Activity has the same ID every time so I know I can check the ID before replying to avoid these multiple replies. However this behavior sounds like a bug and I'm not sure what causes it.
Here's the code from the OnTurnAsync and the EmailDialog:
OnTurnAsync:
 public async Task OnTurnAsync(ITurnContext turnContext, CancellationToken cancellationToken = default(CancellationToken))
        {
            if (turnContext.Activity.Type == ActivityTypes.Message && turnContext.Activity.ChannelId != "email")
            {

                // Establish dialog state from the conversation state.

                UserInfo userInfo = await _accessors.UserInfoAccessor.GetAsync(turnContext, () => new UserInfo(), cancellationToken);

                await _accessors.UserInfoAccessor.SetAsync(turnContext, userInfo, cancellationToken);

                // Continue any current dialog.
                DialogTurnResult dialogTurnResult = await dc.ContinueDialogAsync();

                // Process the result of any complete dialog.
                if (dialogTurnResult.Status is DialogTurnStatus.Complete)
                {
                    var i = 0;
                    await turnContext.SendActivityAsync("Thank you, see you next time");

                }

                // Every dialog step sends a response, so if no response was sent,
                // then no dialog is currently active.

                else if (!turnContext.Responded)
                {
                    var h = 0;

                    await dc.BeginDialogAsync(MainDialogId, null, cancellationToken);

                }

                // Save the new turn count into the conversation state.
                await _accessors.ConversationState.SaveChangesAsync(turnContext, false, cancellationToken);
                await _accessors.UserState.SaveChangesAsync(turnContext, false, cancellationToken);
            }
            else if (turnContext.Activity.Type == ActivityTypes.Message && turnContext.Activity.ChannelId == "email")
            {
                // Establish dialog state from the conversation state.

                UserInfo userInfo = await _accessors.UserInfoAccessor.GetAsync(turnContext, () => new UserInfo(), cancellationToken);

                await _accessors.UserInfoAccessor.SetAsync(turnContext, userInfo, cancellationToken);

                // Continue any current dialog.
                DialogTurnResult dialogTurnResult = await dc.ContinueDialogAsync();

                // Process the result of any complete dialog.
                if (dialogTurnResult.Status is DialogTurnStatus.Complete)
                {

                }

                // Every dialog step sends a response, so if no response was sent,
                // then no dialog is currently active.

                else if (!turnContext.Responded)
                {

                    var h = 0;
                    // if the user attempted to many times to enter an invalid ticket, this condition is met and the if should open a Too many attempts dialog.

                    await dc.BeginDialogAsync(EmailDialogId, null, cancellationToken);

                }

                // Save the new turn count into the conversation state.
                await _accessors.ConversationState.SaveChangesAsync(turnContext, false, cancellationToken);
                await _accessors.UserState.SaveChangesAsync(turnContext, false, cancellationToken);
            }

            else
            {
                // Commenting this to avoid "event detected" message over the chat.
                // await turnContext.SendActivityAsync($"{turnContext.Activity.Type} event detected");

            }
        }

EmailDialog:
using EchoTest.Utils;
using MarvinModels;
using MarvinServices;
using Microsoft.Bot.Builder;
using Microsoft.Bot.Builder.Dialogs;
using Microsoft.Bot.Builder.Dialogs.Choices;
using Newtonsoft.Json;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Threading;
using System.Threading.Tasks;

namespace EchoTest.Dialogs
{
    public class EmailDialog : ComponentDialog
    {
        private readonly BotAccessors _accessors;

        // Nested Dialog Id, required to be used with the ReplaceDialog
        private const string EmailDialogId = "emailDialogId";

        public EmailDialog(string id, BotAccessors accessors) // id inhereted from the parent Dialog.
            : base(id)
        {
            // The InitialDialogId needs to be set to the ID of a dialog in the nested/child dialog, the one to start when the waterfall starts
            InitialDialogId = EmailDialogId;
            _accessors = accessors;

            // Define the conversation flow using a waterfall model.
            WaterfallStep[] waterfallSteps = new WaterfallStep[]
            {
                CheckQuestionAsync,
                FAQChoicePromptAsync,

            };
            AddDialog(new WaterfallDialog(EmailDialogId, waterfallSteps));

        }

        private async Task<DialogTurnResult> CheckQuestionAsync(
        WaterfallStepContext stepContext,
        CancellationToken cancellationToken = default(CancellationToken))
        {

            stepContext.Values["emaildata"] = stepContext.Context.Activity.ChannelData;

            var json = stepContext.Values["emaildata"];

            var h = 0;
            var strings = json.ToString();
            var j = 0;
            ChannelDataJson EmailObject = new ChannelDataJson();

            EmailObject = JsonConvert.DeserializeObject<ChannelDataJson>(strings);
            await stepContext.Context.SendActivityAsync(EmailObject.TextBody.Text);
            return await stepContext.ContinueDialogAsync();
        }

        private static async Task<DialogTurnResult> FAQChoicePromptAsync(
       WaterfallStepContext stepContext,
       CancellationToken cancellationToken = default(CancellationToken))
        {

            return await stepContext.EndDialogAsync();

        }

    }
}

I think the problem is in CheckQuestionAsync. Change to last line to return EndOfTurn;.
This method is one of your waterfall steps. Calling stepContext.ContinueDialogAsync causes the context to continue the active dialog, which is your waterfall at this point, so you have an unexpected and unsupported type of loop in the code.
Let me know if that fixes it for you.

Thank you for the answer.
Before I try it, a small question.
As you explained, stepContext.ContinueDialogAsync would cause the context to continue to the next waterfallstep. This would be FAQChoicePromptAsync.
In here I return a stepContext.EndDialogAsync();
Wouldn't this end the dialog and, therefor, avoid any kind of loop?

When you're turn handler calls dc.BeginDialogAsync(EmailDialogId... that puts the EmailDialog on the stack and starts it. Since EmailDialog is a ComponentDialog, it creates an inner dialog stack, puts the email waterfall dialog on the inner stack, and starts it. This then causes the stack to run the first step of the waterfall. Once that exits, control trickles back down to the turn handler. If you call stepContext.ContinueDialogAsync from the first step of the waterfall, it tells the active dialog on the stack to execute the next step, but you haven't completed the first yet. I'm guessing that it tries to perform the first step of the waterfall again, since that is what's on top of the stack. If you simply return Dialog.EndOfTurn here, then control returns normally to the turn handler. On the next turn, when it calls dc.ContinueDialogAsync, the component dialog is continued, which causes it to execute the second step of the waterfall.
Sorry if that's a bit dense. Hopefully, it helps.

Sadly this didn't work.
I changed the ContinueDialogAsync for NextAsync and the EndDialog for Dialog.EndofTurn but the email keeps getting received and processed by the bot after the first Send, so the bot replies between 3 and 5 times to the same first email I send.
It's as if the Bot Channel Service wasn't filtering the email's activity ID (which is the same all the time, because the email received by the bot is the same) and it loops through the same single one email over and over again.
This is not the Infinite Loop issue . The bot stops processing the same email after 3-5 times and the replies stops, but it shouldn't process the activity more than once.

A couple clarifications:

At the end of step one, return EndOfTurn, instead of return awaiting ContinueDialogAsync or NextAsync.
At the end of step two, stick with return awaiting EndDialogAsync.

This doesn't explain why you're getting so many emails, though. It may be that your bot is receiving other activities, in addition to the message activity, such as one or two ConversationUpdate activities.

In your turn handler code, add an if (turnContext.Activity.Type is ActivityTypes.Message) { } statement, and only continue the dialog if the incoming activity is a message activity.

Did the changes, but it still didn't solve it.
The incoming activity is the same email, so it's a type message. It's a duplicated activity of the first email I send.

I've run out of immediate suggestions. You should post this to Stack Overflow using the botframework tag. If you find specific incorrect or missing information in our docs, please open another issue, and we'll update the documentation.
Please note that Stack Overflow has guidelines such as requiring a descriptive title, a complete and concise problem statement, and enough details to reproduce your issue. Feature requests or overly broad questions are off-topic; new users should visit the Stack Overflow Help Center for more details.

@JonathanFingold
Thank you for your help.
I think I found the answer and it should be added to the docs:

If the email channel's Bot Connector Service (which is what is sending the activity to your bot) does not receive an ack (HttpStatusCode.OK: 200) within 15 seconds, it will resend the email. I think it will retry up to three times.

That is good to know. I will add this note to the email channel topic in the next day or two. Thanks much.


Added ATR Percentage movement indicator

PRs that wont be accepted

typos
editing comments (unless critical)
edits in documentation (unless critical)

What are you addressing in this PR

Place X in the slot...

[x] Functionality
[ ] Ease of use
[ ] Bug fix

How have you tested this PR

Validation must be ran in both prod and test (see TEST_MODE)
Enter a description here. Empty descriptions will be closed.

In your own words, please share how this makes the codebase better.

Great work mate.
Do you reckon you could change the MOVEMENT and ATR_MOVEMENT booleans to be an Enum instead (or a class representation of an Enum)? I think this would be better as it means you can only have one state rather than the possibility of someone incorrectly setting both booleans to True.
Let me know what you think?


Write a new doc page on reshaping / reorganizing data

Topics:

stack/unstack
transpose
to_array/to_dataset
rename/swap_dims?

Fixed by https://github.com/pydata/xarray/pull/702


More revisions to travis logic

Looking at the travis API, the "sender" in travis-ci parlance is whomever merged the pull request, not who opened it.
https://api.travis-ci.org/v3/build/607854388  - under Created By, at the bottom.
Editing the travis logic to reflect this discovery.
This PR also moves release-tagging and documentation to their own stage;

Codecov Report

Merging #375 into master will decrease coverage by 0.03%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master     #375      +/-   ##
==========================================
- Coverage   72.55%   72.51%   -0.04%
==========================================
  Files          30       30
  Lines        2700     2700
  Branches      460      460
==========================================
- Hits         1959     1958       -1
  Misses        646      646
- Partials       95       96       +1

Impacted Files
Coverage Δ

taskcat/_lambda_build.py
85.24% <0%> (-1.64%)
:arrow_down:

Continue to review full report at Codecov.

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

/do-e2e-tests


common_single_host_mode not being used consistently? quorum check fails

centos 7.7
ceph nautilus
ansible 2.8
ceph-ansible 4.0.5
I have set
common_single_host_mode: true
but setup is failing, waiting for my single monitor, to establish a quorum?
ASK [ceph-mon : start the monitor service] *******************************************************
Friday 06 December 2019  12:46:46 -0800 (0:00:00.148)       0:01:17.516 *******
ok: [localhost]
TASK [ceph-mon : include_tasks ceph_keys.yml] *****************************************************
Friday 06 December 2019  12:46:48 -0800 (0:00:01.955)       0:01:19.472 *******
included: /home/xxx/ceph-ansible-4.0.5/roles/ceph-mon/tasks/ceph_keys.yml for localhost
TASK [ceph-mon : waiting for the monitor(s) to form the quorum...] ********************************
Friday 06 December 2019  12:46:48 -0800 (0:00:00.280)       0:01:19.752 *******
fatal: [localhost]: FAILED! =>
msg: |-
The conditional check '(ceph_health_raw.stdout | length > 0) and (ceph_health_raw.stdout | default('{}') | from_json)['state'] in ['leader', 'peon']
' failed. The error was: error while evaluating conditional ((ceph_health_raw.stdout | length > 0) and (ceph_health_raw.stdout | default('{}') | from_json)['state'] in ['leader', 'peon']
): 'dict object' has no attribute 'stdout'

please share the full ansible logs with verbosity, inventory and all variables defined in group_vars/*.yml

okay. I'll start with the inventory, aka hosts file. whichis nothing more than:
[mons]
localhost
[mgrs]
localhost
[mdss]
localhost
[grafana-server]
localhost

attempting to attach my all.yml file...
file:///tmp/all.yml.upload

all.yml.txt

what are you specifically asking for, when you ask for,
" full ansible logs with verbosity," ?
Do you just want me to save and upload the output of
ansible-playbook -v -kK site.yml
?

If so, then here that is.
ansible.log

mons.yml file:

dummy:
mon_group_name: mons
monitor_secret: "{{ monitor_keyring.stdout }}"
admin_secret: 'XXXXXX'
client_admin_ceph_authtool_cap:
mon: allow *
osd: allow *
mds: allow *
mgr: allow *
crush_rule_config: false
crush_rule_hdd:
name: HDD
root: HDD
type: host
default: false
crush_rule_ssd:
name: SSD
root: SSD
type: host
default: false

workaround:
I just took the whole task
name: waiting for the monitor(s) to form the quorum.
out.
Things happily are proceeding after that.

I found the problem.
A few other things were failing down the line.
I noticed that the common problem was that they all had a
{{ container_exec_cmd }}
clause.
in the all.yml file,  there are two lines:
#container_exec_cmd:
#docker: false
I thought I had to define the first one, to allow me to define docker as false.
when I commented out both lines, everything was happier.
It could be helpful if you added a comment, right below,
##########
DOCKER
##########
to say,
if you are not using docker, leave this entire section commented out.

@ppbrown do you mind sending a PR for that?
Thanks!


a bug

const Vec2& center={0.0,0.0},
in VecND.h
T& x = entries_[0];
T& y = entries_[1];
T& z = entries_[2];
when it is running at " T& z = entries_[2];"
array subscript out of range

Thanks for pointing this out!
I fixed this bug in the development branch and will include the solution in the next release.
Best regards
Flo


add data passing mechanism in kubevela

Background
When there eixst interactions between multiple applications, applications usually have a requirement of data passing, e.g. in these senario

There are call relations in applications, one need to provide arguments to one who call it, for example app A requies the service of database D, hence D neet to transimit it address to A.
Applications cooperate to complete the request processing. e.g. after a request arrive, it shoud be process by the authenticate app at first, then follow by the processing by other service logic apps.
As described in Resource Dependency in OAM, the object in one OAM application can inicate a dependency, however there is no implement of data passing. In our proposal, we discuss a mechanism to support the data passing based on the resourece dependency, therefore reduce the burden on service deployment.
Goals
This proposal aims to realizing the data passing mechanism in OAM based on Resource Dependency in OAM, and specifically include:
The availability of data passing in creating the components: The data passing among objects during the creation phase. This mechanism can judge the dependencies of different objects in one application configration, and pass dynamic data of between objects.
The data integration ability: During data passing, one object can collect many data and then process as needed, such as jsonPath.
Use case
1.Service application call PaaS middleware
In the cloud native senario, on-demand deployment has become a trend. When deploy a service application, if we need middlewares such as message queue or key-value storage, we usually create middlewares instance and then provide the related information to service. Considered that middleware is the ability provided by PaaS, we hope to support clients can call the middleware by configurations, and do not need to develop while deploying.
2.Configuration argument requirement and handling
In complicated service and application, such as searching engine, it require other components' data as it startup parameters. For standardized management, those components use json string to record parameters. In this situation, OAM need provide data processing ability to help service process that data, e.g. store the persisitent storage address in path 'data.url' in json file.
3.Service intermediate result passing and determination
In processing multiple services, one may have dependency on others' intermediate result to execute the following operations, e.g. in a ML trainning platform, requests are processed by authentication component and judge users' validity and group, and after that the notebook creation component use the data from authentication component to determine whether accept or refuse requst and create different kind of notebook.
Proposal
The overall idea is on the basis of Resource Dependency, we add an intermediate storage with processing logic and realized functions of condition judgement of data input and output, data collection, data processing and output. In the OAM runtime, when the data output conditions are satisfied, write the data to the reference indicate by client, and when the data input conditions are satisfied, read the data from that reference and provide it to components.
Add outputStore field in dataOutputs to indicate reference that output to, and if reference does not exist, OAM will automatically create one and manage it life cycle. If the reference is not automatically created, OAM won't be responsible for its life cycle management.dataOutputs:

outputStore:
apiVersion:
kind:
name:
The declaration below indicate a ConfigMap named sample-config to write out intermediate data
dataOutputs:

outputStore:
apiVersion: v1
kind: ConfigMap
name: sample-config

In outputStore field we add operations to indicate specific output operation, those operations will be process in declaration order. When all the conditions are satisfied, it will trigger the output operation. toFieldPath is the path defined by K8s, and toDataPath is the path defined in a string, for example a field in json. What's more, output data support both data from valueFrom and directly indicate in value.
dataOutputs:

outputStore:
apiVersion: v1
kind: ConfigMap
name: sample-config
operations:

type:
op:
toFieldPath: <the outputStore path specified in Pass, such as k8s>
value: ''
type:
op:
toFieldPath: <the outputStore path specified in Pass, such as k8s>
toDataPath:
valueFrom:
fieldPath: <the object path specified in Pass, such as k8s>
The declaration below indicate data field in outputStore, create a filed that key is redis, and set it to "{}", then write in the dataoutputs components' value in the field status.instanceID. Finally the value in data.redis is "{instanceID: ***}"
dataOutputs:

outputStore:
apiVersion: v1
kind: ConfigMap
name: sample-config
operations:

type: "jsonPatch"
op: "add"
toFieldPath: "data.redis"
value: '"{}"'
type: "jsonPatch"
op: "add"
toFieldPath: "data.redis"
toDataPath: "instanceID"
valueFrom:
fieldPath: "status.instanceID"

Similarly, we add inputStore in dataInputs to indicate data input's reference, if it's not exist then will report an error and stop the data input process.
dataInputinputStores:

inputStore:
apiVersion:
kind:
name:
The declaration below indicate a ConfigMap named sample-config to read in intermediate data
dataInputs:
inputStore:
apiVersion: v1
kind: ConfigMap
name: sample-config

Similarly, we add operations to indicate specific input operations, those operations will be process in declaration order. fieldPath is the path defined in K8s and other PaaS, and toDataPath is the path defined in a string, for example a field in json. Also, output data support both data from valueFrom and directly indicate in value.
dataInputs:

inputStore:
apiVersion: v1
kind: ConfigMap
name: sample-config
operations:

type:
op:
toFieldPath: <the object path specified in Pass, such as k8s>
toDataPath:
valueFrom:
fieldPath: <the inputStore path specified in Pass, such as k8s>
The declaration below indicate reading data from data.redis field in inputStore, and write to datainputs components' spec.containers.0.env.0.value field.
dataInputs:

inputStore:
apiVersion: v1
kind: ConfigMap
name: sample-config
operations:

type: "jsonPatch"
op: "add"
toFieldPath: "spec.containers.0.env.0.value"
valueFrom:
fieldPath: "data.redis"

In outputStore field of dataOutputs and inputStore's every operations in dataInputs, we can add condition to judge whether the condition is satisfied, the determination logic is same with that in resource-dependency, please refer to Resource Dependency.
What should be point out is that, for compatibility of origin dependency relations, when there is no inputStore filed  declaration in dataInputs, we will process as original logic.
Solution example
In this section we provide solution examples for data passing based on our implementation.
1.Data passing example
In this example, sample-output-component write data to ConfigMap named "sample-config", then workload corresponding to sample-input-component read data from it.

kind: Component
metadata:
  name: sample-input-component
spec:
  workload:
    apiVersion: apps/v1
    kind: Deployment
    metadata:
      name: ***
---
kind: Component
metadata:
  name: sample-output-component
spec:
  workload:
    apiVersion: bach.damo.alibaba.com/v1alpha1
    kind: Redis
    metadata:
      name: ***
---
kind: ApplicationConfiguration
metadata:
  name: sample-application-config
spec:
  components:
    - componentName: sample-output-component
      dataOutputs:
      - name: sample-dataoutput
        outputStore:
          apiVersion: v1
          kind: ConfigMap
          name: sample-config
          operations:
          - type: "jsonPatch"
            op: "add"
            toFieldPath: "data"
            value: "{}"
          - type: "jsonPatch"
            op: "add"
            toFieldPath: "data.redis"
            value: '"{}"'
          - type: "jsonPatch"
            op: "add"
            toFieldPath: "data.redis"
            toDataPath: "instanceID"
            valueFrom:
              fieldPath: "status.instanceID"
            conditions:
            - op: "notEq"
              value: ""
              fieldPath: "status.instanceID"
    - componentName: sample-input-component
      dataInputs:
      - inputStore:
          apiVersion: v1
          kind: ConfigMap
          name: sample-config
          operations:
          - type: "jsonPatch"
            op: "add"
            toFieldPath: "spec.containers.0.env.0.value"
            valueFrom:
              fieldPath: "data.redis"
            conditions:
            - op: "notEq"
              value: ""
              fieldPath: "data.redis"

2. Data Collection Example
This example is based on example 1, using operations field in dataInputs to illustrate how to collect and process complicated data. This example integrates instanceID of redis and kafka and content in kafka topic into one json and set it as the first env value for use.
...
- componentName: sample-input-component
      dataInputs:
      - inputStore:
          apiVersion: v1
          kind: ConfigMap
          name: sample-config
          operations:
          - type: "jsonPatch"
            op: "add"
            toFieldPath: "spec.containers.0.env.0.value"
            toDataPath: "redis"
            value: '"{}"'
          - type: "jsonPatch"
            op: "add"
            toFieldPath: "spec.containers.0.env.0.value"
            toDataPath: "redis.intanceID"
            valueFrom:
              fieldPath: "data.instanceID"
            conditions:
            - op: "notEq"
              value: ""
              fieldPath: "data.redis"
      - inputStore:
          apiVersion: v1
          kind: ConfigMap
          name: another-sample-config
          operations:
          - type: "jsonPatch"
            op: "add"
            toFieldPath: "spec.containers.0.env.0.value"
            toDataPath: "kafka"
            value: '"{}"'
          - type: "jsonPatch"
            op: "add"
            toFieldPath: "spec.containers.0.env.0.value"
            toDataPath: "kafka.intanceID"
            valueFrom:
              fieldPath: "data.instanceID"
          - type: "jsonPatch"
            op: "add"
            toFieldPath: "spec.containers.0.env.0.value"
            toDataPath: "kafka.topic"
            valueFrom:
              fieldPath: "data.topic"
            conditions:
            - op: "notEq"
              value: ""
              fieldPath: "data.topic"
          - ...

Similar PR in oam-kubernetes-runtime is:


Just not working in my VS2017 Pro/Community

Hi Cezary,
I've used your plug-in successfully in a previous contract but though I've installed it, it just doesn't present itself. It shows as installed within the VS Extensions & Updates but that's as much as I get. Any hints to try to resolve it?
I'm running VS2017 Vsn 15.9.7 and get the same issue on the latest Community Edition
Cheers,
Will

Hi
Please check the hints from the #50 and let me know if this solved the issue.

Thanks. It was the resharper settings re. the lightbulb.
Nice one,
On Mon, 18 Feb 2019 at 13:55, Cezary Piątek<EMAIL_ADDRESS>wrote:

Hi
Please check the hints from the #50
https://github.com/cezarypiatek/MappingGenerator/issues/50 and let me
know if this solved the issue.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/cezarypiatek/MappingGenerator/issues/70#issuecomment-464740000,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AQ4w9bLzZFr6tSdmfe0P_gTV5nyT4tkOks5vOrDpgaJpZM4bAt_j
.


Update outdated solace links

Update Solace links to point directly to  binder docs in solace-spring-cloud project here: https://github.com/SolaceProducts/solace-spring-cloud/tree/master/solace-spring-cloud-starters/solace-spring-cloud-stream-starter#spring-cloud-stream-binder-for-solace-pubsub
Squash & merge suggested.

Looks good. Squashed the commits and merged upstream.


Does AWS-SDK-CPP only read credentials from ~/.aws/

What platform/OS are you using?
linux  ubuntu:18.04
Which version of the SDK?
aws-sdk-cpp-1.7.135
What compiler are you using? what version?
gcc (Ubuntu 7.4.0-1ubuntu1~18.04.1) 7.4.0
What is your problem?
I am trying to running a cpp program that access to DynamoDB to read something.
The code is like
Aws::InitAPI(Aws::SDKOptions());
this->client_ = make_shared<DynamoDBClient>(ClientConfiguration());
GetItemRequest req;
req.SetTableName(String("test_table"));
AttributeValue av;
av.SetS("test_id");
req.AddKey(String("test-key"), av);
const GetItemOutcome &result = this->client_->GetItem(req);

But it throws the exception like
Unable to connect to endpoint with address : <IP_ADDRESS>

I checked that my host has the access to aws through IAM role and sts by:
$ aws sts get-caller-identity
{
    "UserId": "55555555555:abc",
    "Account": "55555555555",
    "Arn": "arn:aws:sts::55555555555:federated-user/abc"
}

# output the expected result
$ aws dynamodb scan --table-name test_table --region us-east-1
....
# output the expected result

So at the current stage, from CLI, it can access to AWS DynamoDB, but from cpp code, it cannot.
I did some research, and found out that after I installed aws-credential-client and use it to generate the credential files under ~/.aws/credentials. Then the cpp program can access DDB.
My question is that do I have to use  aws-credential-client to generate ~/.aws/credentials for my cpp program to access DDB through aws-sdk-cpp? Can I have my cpp program access to DDB through sts and assumed IAM role?

Hi @sichao-uber ,
We are working on this but, the current way the sdk works is:
By default it does take the credentials from ~/.aws/credentials like CLI does, but it does not take the region, which I think causes your "cannot connect to endpoint" error.
That being said the error could have other causes so I'll give you a couple solutions for the region case, and if they don't work let me know and I'll take a closer look.

The simpler way is to give the ClientConfiguration a region:

ClientConfiguration client_config();
client_config.region ="us-west-1";
this->client_ = make_shared<DynamoDBClient>(ClientConfiguration());

Alternately, if you have a ~/.aws/config file set up with a profile that has the region defined, you can do:
this->client_ = make_shared<DynamoDBClient>(ClientConfiguration("default"));
and that should look for a profile of name [default] in ~/.aws/config

Hi @KaibaLopez,
The region is not the problem. Even without the line
client_config.region ="us-west-1";

It will still have the problem

It tried both
this->client_ = make_shared<DynamoDBClient>(ClientConfiguration("default"));

and
this->client_ = make_shared<DynamoDBClient>(ClientConfiguration());

Neither of them work

Currently the situation is that I am trying to deploy my service to EC2 instance with an IAM role that has the permission to talk to DynamoDB.
If I run the awscli, it works. but when I run in cpp, since it will read from ~/.aws/, which I does not have it in EC2 instance, it will fail.
Theoretically in my case, my cpp service should work with Instance Profile Credentials , right?

My bad, I misunderstood the issue.
But yes, you're correct.

but currently, it does not work with my Instance Profile Credentials.
not sure if there is any setup I did wrong, or it's aws-sdk-cpp does not support "Instance Profile Credentials".
If it's the former one, please let me know what kind of info you need to help you investigate this

and also, is there anyway that I can discuss the issue with you directly to solve the problem faster?

yea sorry, multiple questions get confusing to answer, but the idea is that the sdk does not know the ec2 instance's IAM roles, so you'll need to provide the credentials, meaning it will check for them in ec2's ~/.aws/credentials the same way that it would if ran in your local machine, or expect you to provide them in the code.
The IAM role you used to create the ec2 instance is not carried over as far as the sdk knows.
So the simplest way to have the sdk run in your ec2 instance, is to simply copy the credentials from where you were able to run it and put them in the ec2's ~/.aws/credentials.

So the simplest way to have the sdk run in your ec2 instance, is to simply copy the credentials from where you were able to run it and put them in the ec2's ~/.aws/credentials.

This will not work since the credential expires after a while. It's not practical to keep copying the credential from my local machine to EC2 server.
May I ask from the code level, in aws-sdk-cpp, is there a way to get the IAM credential from the code. if so, we can do something similar to this:
Credential credential = get_credential_from_host_iam();
ClientConfiguration config(credential);
DynamoDBClient client(config);

This may not be exactly what you're looking for but a way you'd be able to do this would be by modifying (or creating your own) Credentials provider and Credentials provider chain.
The AWSCredentialsProviderChain defines how the credentials are looked for, and I think this is what you could use to get your implementation to work.
Look for AWSCredentialsProviderChain in aws-sdk-core for the base class and I'd recommend using DefaultAWSCredentialsProviderChain as an example or base for your own implementation.
The Client class uses the default provider chain, as the name implies 'by default', but you could create your own which in turn can be used to define the client, and that way tell it where to find the credentials.
So you'd be writing something like:
class AWS_CORE_API MyAWSCredentialsProviderChain : public AWSCredentialsProviderChain
 {
 // your code specifying which provider to call and in what order if multiple sources....
}
AWSCredentials MyAWSCredentialsProvider::GetAWSCredentials()
{
//your code on where to find the credentials
}
MyAWSCredentialsProviderChain providerChain("some location or call");
ClientConfiguration config();
DynamoDBClient client(providerChain,config);

I believe there are many aws customers who

write in cpp
use ec2 hosts
access to dynamodb
what is the standard process for them to get the things work

For your solution above,
AWSCredentials MyAWSCredentialsProvider::GetAWSCredentials()
{
//your code on where to find the credentials
}

currently i have no idea how to get credentials from ec2 iam role

Hi @KaibaLopez , can I get an update on this?

How can I get the credential from IAM that is set up in the EC2 host? Is it in some file? or it's an env variable?

How does other EC2 customers who write the cpp program to access the DynamoDB solve this problem?

Thanks

Hi @sichao-uber, so I did some digging, and first I want to apologize for my confusion yesterday.
regarding your last questions:

Here is documentation on how to get the credentials from the IAM role attached to the EC2 instance.

This is not a common issue really, The sdk Should take the credentials from the IAM role by default via a call to AWSCredentials InstanceProfileCredentialsProvider::GetAWSCredentials()

I've tested this on my own EC2 instance with a IAM Role attached, and no ~/.aws/credentials file on my instance, and the sdk connects as expected to dynamodb.
I tested also with no IAM role attached and the error I'm getting is "Request is missing Authentication Token with address", which makes more sense than endpoint connection.
This tells me that the problem not with the credentials provider... but the error of connection to endpoint is a little too generic though, could be as simple as a timeout, wrong region or it could be related to an EC2 service bug... Can you activate and provide the full trace log ? (make sure to sanitize personal info).
options.loggingOptions.logLevel = Aws::Utils::Logging::LogLevel::Debug;
Aws::InitAPI(Aws::SDKOptions(options));
/*rest of your code */

Sorry again for the confusion

Hi @KaibaLopez , thanks for the response.
Currently it's working after I

create a permernant credentials
When build the docker image that is deployed to EC2 hosts, I hard-coded the credentials in the image under the path ~/.aws/creadentials

Later I can change it back and add the logging option you provided, and see if it helps your investigation.

Hi @KaibaLopez ,
Do I need to add any other code to see the extra logs.
After I added the code you provided above, when the exception is thrown, the error message is the same:
[19-11-08 22:44:15][info]: Query on table: model_version_manager_test for model version with id 1.
[19-11-08 22:44:41][error]: Failed to get the model version with id: 1, due to:
Unable to connect to endpoint with address : <IP_ADDRESS>
[19-11-08 22:44:41][error]: GRPC request is throwing the exception:
[AWS_DYNAMODB_EXCEPTION]: Failed to get the model version with id: 1, due to:
Unable to connect to endpoint with address : <IP_ADDRESS>
Converting it to GRPS status with code: 13

@sichao-uber , activating the logs won't really change the exceptions thrown, rather it will save the trace in a seperate file, it should be in the source folder with a name like : aws_sdk_2019-11-08-22.log
That's the file I'd like you to upload here(again, after sanitizing private info).

Here is the log
0 response headers:
[WARN] 2019-11-11 22:47:35.187 AWSClient [140290669143808] If the signature check failed. This could be because of a time skew. Attempting to adjust the signer.
[DEBUG] 2019-11-11 22:47:35.187 AWSClient [140290669143808] Date header was not found in the response, can't attempt to detect clock skew
[WARN] 2019-11-11 22:47:35.187 AWSClient [140290669143808] Request failed, now waiting 50 ms before attempting again.
[DEBUG] 2019-11-11 22:47:35.238 InstanceProfileCredentialsProvider [140290669143808] Checking if latest credential pull has expired.
[DEBUG] 2019-11-11 22:47:35.238 AWSClient [140290669143808] Request Successfully signed
[DEBUG] 2019-11-11 22:47:35.238 CurlHandleContainer [140290669143808] Attempting to acquire curl connection.
[INFO] 2019-11-11 22:47:35.238 CurlHandleContainer [140290669143808] Connection has been released. Continuing.
[DEBUG] 2019-11-11 22:47:35.238 CurlHandleContainer [140290669143808] Returning connection handle 0x7f97fc1b6a90
[DEBUG] 2019-11-11 22:47:35.238 CurlHttpClient [140290669143808] Obtained connection handle 0x7f97fc1b6a90
[ERROR] 2019-11-11 22:47:35.238 CurlHttpClient [140290669143808] Curl returned error code 77 - Problem with the SSL CA cert (path? access rights?)
[DEBUG] 2019-11-11 22:47:35.238 CurlHandleContainer [140290669143808] Releasing curl handle 0x7f97fc1b6a90
[DEBUG] 2019-11-11 22:47:35.238 CurlHandleContainer [140290669143808] Notified waiting threads.
[DEBUG] 2019-11-11 22:47:35.238 AWSClient [140290669143808] Request returned error. Attempting to generate appropriate error codes from response
[ERROR] 2019-11-11 22:47:35.238 AWSClient [140290669143808] HTTP response code: -1
Exception name:
Error message: Unable to connect to endpoint
0 response headers:
[WARN] 2019-11-11 22:47:35.238 AWSClient [140290669143808] If the signature check failed. This could be because of a time skew. Attempting to adjust the signer.
[DEBUG] 2019-11-11 22:47:35.238 AWSClient [140290669143808] Date header was not found in the response, can't attempt to detect clock skew
[WARN] 2019-11-11 22:47:35.238 AWSClient [140290669143808] Request failed, now waiting 100 ms before attempting again.
[DEBUG] 2019-11-11 22:47:35.339 InstanceProfileCredentialsProvider [140290669143808] Checking if latest credential pull has expired.
[DEBUG] 2019-11-11 22:47:35.339 AWSClient [140290669143808] Request Successfully signed
[DEBUG] 2019-11-11 22:47:35.339 CurlHandleContainer [140290669143808] Attempting to acquire curl connection.
[INFO] 2019-11-11 22:47:35.339 CurlHandleContainer [140290669143808] Connection has been released. Continuing.
[DEBUG] 2019-11-11 22:47:35.339 CurlHandleContainer [140290669143808] Returning connection handle 0x7f97fc1b6a90
[DEBUG] 2019-11-11 22:47:35.339 CurlHttpClient [140290669143808] Obtained connection handle 0x7f97fc1b6a90
[ERROR] 2019-11-11 22:47:35.339 CurlHttpClient [140290669143808] Curl returned error code 77 - Problem with the SSL CA cert (path? access rights?)
[DEBUG] 2019-11-11 22:47:35.339 CurlHandleContainer [140290669143808] Releasing curl handle 0x7f97fc1b6a90
[DEBUG] 2019-11-11 22:47:35.339 CurlHandleContainer [140290669143808] Notified waiting threads.
[DEBUG] 2019-11-11 22:47:35.339 AWSClient [140290669143808] Request returned error. Attempting to generate appropriate error codes from response
[ERROR] 2019-11-11 22:47:35.339 AWSClient [140290669143808] HTTP response code: -1
Exception name:
Error message: Unable to connect to endpoint
0 response headers:
[WARN] 2019-11-11 22:47:35.339 AWSClient [140290669143808] If the signature check failed. This could be because of a time skew. Attempting to adjust the signer.
[DEBUG] 2019-11-11 22:47:35.339 AWSClient [140290669143808] Date header was not found in the response, can't attempt to detect clock skew
[WARN] 2019-11-11 22:47:35.339 AWSClient [140290669143808] Request failed, now waiting 200 ms before attempting again.
[DEBUG] 2019-11-11 22:47:35.540 InstanceProfileCredentialsProvider [140290669143808] Checking if latest credential pull has expired.
[DEBUG] 2019-11-11 22:47:35.540 AWSClient [140290669143808] Request Successfully signed
[DEBUG] 2019-11-11 22:47:35.540 CurlHandleContainer [140290669143808] Attempting to acquire curl connection.
[INFO] 2019-11-11 22:47:35.540 CurlHandleContainer [140290669143808] Connection has been released. Continuing.
[DEBUG] 2019-11-11 22:47:35.540 CurlHandleContainer [140290669143808] Returning connection handle 0x7f97fc1b6a90
[DEBUG] 2019-11-11 22:47:35.540 CurlHttpClient [140290669143808] Obtained connection handle 0x7f97fc1b6a90

Alright,
So the error is on curl ssl verification:
Curl returned error code 77 - Problem with the SSL CA cert (path? access rights?)

As a workaround, if you're just trying to run this without going too deep on what's going on, you can add:
client_config.verifySSL = false
and that should at least make it run.

If you want more info on what's going on and where or what file it's trying to find, I will need you to turn on the flag : ENABLE_CURL_LOGGING on your cmake arguments, and then tell us what you got and we'll be able to help further. But probably what's happening is that it's trying to use a custom CA Cert that's on an unexpected location or under special privileges.
If it is a custom ca cert and you know where it is, you can also tell the client configuration by adding:
client_config.caFile="";
client_config.caPath="";


fix: make file globbing behave more as expected

Previously we were just supplying the plain globs. However that also matched files in sub-folders (e.g. build.txt would match lib/build.txt and so on).
Now we are always prepending a / in front, so that these files are matched based on the root folder (and a plain build.txt would only match /build.txt, not lib/build.txt).

I like this change  and i think we should merge it, But this might be breaking for want to mention that in the changelog


Workaround for the build break on visionOS

This is likely not the proper solution, but it does get my projects building.

Thanks! Going to make sure we have visionOS CI set up and then will merge this as a fix.


Implementing GitHub reusable workflows

PR Summary
What started just being me fixing a regression (#123) - went a little bigger 🤣
Closes #123
Closes #125
BYO vnet CI/CD Workflow

Refactored the Java app smoke tests to reusable workflows
Conditionally applying Azure Key Vault Access Policies regression
Java App workflow

Targeting JavaAppV3 Chart in minihelm
Optionally uninstalls the java app before attempting install. (Good for when AGIC knots up)
Using loops with short sleeps to wait for DNS/Certificate issue/App ready, rather than random length sleeps

Wizard/Helper

Changed Network Plugin preset to Azure from Calico (and added a Playwright test to cover 😎 )
A few spelling mistakes

GitHub pages publish helper workflow

Added spell checker to stop typo's slipping through
Move release tag to env variable since it was used in 2 places and caused a problem with the v3.0.0-preview release

Documentation

Added doc for the regression workflow to the contribution guide
Quite a few spelling mistakes, throughout various files
A few stray markdown whitespace warnings taken care of that the VSCode docs plugin cared about

PR Checklist

[x] PR has a meaningful title
[x] Summarized changes
[x] This PR is ready to merge and is not Work in Progress
[x] Link to a filed issue

@Gordonby you may need to run me through this one

for sure 🙄
🤣

@Gordonby you may need to run me through this one

for sure.
just get your people to call my people.


Toggle timeline view's filter button to indicate excluded contributors (#145769)

This PR closes #145769 by allowing submenu-type action buttons to specify a toggled ContextKeyExpression that leverages existing infrastructure to use the actionBar-toggledBackground colour whenever the expression is true.
Here's how the Timeline view's Filter button now changes appearance when the user deselects at least one of the timeline contributors:

The contrast of that colour in the Dark Modern theme maybe needs tweaking.
The recording also shows the highlighted filter button on the Problems tab of Panel, which was already using custom logic in its toolbar widget to achieve a similar effect. However it uses different colours:
https://github.com/microsoft/vscode/blob/d878a801801af60a91b8b50c16032386f40bdcc3/src/vs/workbench/browser/parts/views/media/views.css#L297-L301
Perhaps controversially, this PR had to increase the paneview header height from 22 to 23 pixels, otherwise the toggled button's background would overlap the focus rectangle on the header when focused. This happened because headers have a 1px top border to help separate them from the view above them, and this border pushes the action buttons down such that they overlap the bottom section of the focus rectangle when it appears.

/assign @daviddossett

Pinging @bpasero who contributed to the issue discussion.

Cool! Open question: should we use this subtle hover background-esque styling or the use the louder toggle state as shown above in the input? I'll actually pass this to @hbons since we was just exploring this recently.

Adding some more people as this change seems to touch different areas. I only observe that going from 22px to 23px seems wrong to me and will result in inconsistent height assumptions. 22px is our standard used throughout all of the workbench.

It looks a bit weird to me that the toggled state appears on buttons that only show up on hover... If there is a change of state that needs to be reflected at all times we should make that button always visible?

I reverted the 23px changes. Here's an image of the problem caused by the 1px border-top added here when the view is anywhere other than at the top of the primary sidebar container:
https://github.com/microsoft/vscode/blob/d7ce6f942494744686fcfb258bdb4b2ecfb526dc/src/vs/base/browser/ui/splitview/paneview.ts#L309

Closing this and replacing it with #198979 as a result of the feedback from @jrieken


wanna export selected items in xls through alasql

Untitled 1.txt

Please ask a question and provide any information within the issue - not a .txt file.


Profile performances of arbitrary attributes

We should profile the amount of new memory allocation when manipulating arbitrary attributes, and organize the API in a way that hints the user into using the most efficient approach. For instance:
v1.attributes["uv"] = new FloatAttributeValue(0.0f, 0.0f);

is less efficient than
var uv = v1.attributes["uv"].asFloat();
uv.data[0] = 0.0f;
uv.data[1] = 0.0f;

but the latter is a bit annoying to write.

So I was going to add some QoL to the attribute API to encourage better (and easier) usage, but I realized that it is kind of limited and clunky as is. For example doesn't support other types like bool, or string.
So I was thinking refactoring it, but I saw in a comment in AttributeType you mention using data buffers. Are you able to elaborate on what you had in mind?

Storing vertex attribute values on a per-vertex basis fragments the memory and does a lot of repeated allocations when adding a new attribute. It would be much more efficient to allocate an array with all values for an attribute written consecutively (making the vertex list a struct of arrays rather than an array of structs), but this makes the addition/deletion of vertices trickier so I am not decided yet about the best design. (ofc it goes the same for edge, loop and face attributes).


test: add smart contract CI test

Description

This PR has following changes.

add smart contract CI test

closes: #226
Motivation and context

How has this been tested?

Screenshots (if appropriate):
Checklist:

[ ] I followed the contributing guidelines and code of conduct.
[ ] I have added a relevant changelog to CHANGELOG.md
[ ] I have added tests to cover my changes.
[ ] I have updated the documentation accordingly.

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


My bug report

Steps to reproduce
$Global:Error.Clear()
# This line will produce an error which is expected for this example:
Get-Service -Name 'Unknown'
$Global:Error | Select-Object -Property *
# This Try Catch construct will try to process that error but the Type cannot be found!
Try
{Get-Service -Name 'Unknown' -ErrorAction Stop}
# This line tries to handle the service unknown error but cannot find the type
Catch [NoServiceFoundForGivenName,Microsoft.PowerShell.Commands.GetServiceCommand]
{'Service cannot be found'}
Catch
{'Some other error occurred'}

Expected behavior
The catch statement to work as intended

Actual behavior
It fails to find the type and a separate error is produced
Get-Service: S:\pny-processed\PowerShellScripts\Test\GetServiceTryCatchTypeError.ps1:3
Line |
   3 |  Get-Service -Name 'Unknown'
     |  ~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | Cannot find any service with service name 'Unknown'.

PSMessageDetails      :
Exception             : Microsoft.PowerShell.Commands.ServiceCommandException: Cannot find any service with service
                        name 'Unknown'.
TargetObject          : Unknown
CategoryInfo          : ObjectNotFound: (Unknown:String) [Get-Service], ServiceCommandException
FullyQualifiedErrorId : NoServiceFoundForGivenName,Microsoft.PowerShell.Commands.GetServiceCommand
ErrorDetails          :
InvocationInfo        : System.Management.Automation.InvocationInfo
ScriptStackTrace      : at <ScriptBlock>, S:\pny-processed\PowerShellScripts\Test\GetServiceTryCatchTypeError.ps1:
                        line 3
                        at <ScriptBlock>, <No file>: line 1
PipelineIterationInfo : {0, 1}

InvalidOperation: S:\pny-processed\PowerShellScripts\Test\GetServiceTryCatchTypeError.ps1:9
Line |
   9 |  Catch [NoServiceFoundForGivenName,Microsoft.PowerShell.Commands.GetSe …
     |        ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     | Unable to find type [NoServiceFoundForGivenName,Microsoft.PowerShell.Commands.GetServiceCommand].

Environment data

----                           -----
PSVersion                      7.1.0
PSEdition                      Core
GitCommitId                    7.1.0
OS                             Microsoft Windows 10.0.19042
Platform                       Win32NT
PSCompatibleVersions           {1.0, 2.0, 3.0, 4.0…}
PSRemotingProtocolVersion      2.3
SerializationVersion           <IP_ADDRESS>
WSManStackVersion              3.0

The operand for catch clauses must be a type (class), more specifically one that derives from System.Exception.
In your case you must use [Microsoft.PowerShell.Commands.ServiceCommandException].
You can find that name as follows:
Get-Service -ErrorAction SilentlyContinue nosuch; $Error[0].Exception.GetType().FullName

You can also easily verify whether a type literal ([...]) refers to an existing (loaded). NET type simply by executing it by itself; this tells you that your type literal isn't valid:
PS> [NoServiceFoundForGivenName,Microsoft.PowerShell.Commands.GetServiceCommand]

The operand for catch clauses must be a type (class), more specifically one that derives from System.Exception.
In your case you must use [Microsoft.PowerShell.Commands.ServiceCommandException].
You can find that name as follows:
Get-Service -ErrorAction SilentlyContinue nosuch; $Error[0].Exception.GetType().FullName

You can also easily verify whether a type literal ([...]) refers to an existing (loaded). NET type simply by executing it by itself; this tells you that your type literal isn't valid:
PS> [NoServiceFoundForGivenName,Microsoft.PowerShell.Commands.GetServiceCommand]

P.S.: It's unfortunate that the issue-template offers "My Bug Report" as the default title, but it's always better to create a custom title that summarizes the issue being reported.

P.S.: It's unfortunate that the issue-template offers "My Bug Report" as the default title, but it's always better to create a custom title that summarizes the issue being reported.

Thanks for your reply apologies regarding the title - my bad
The answer you supplied obviously worked - Thanks
The question remains how do I get from the reported error:
FullyQualifiedErrorId : NoServiceFoundForGivenName,Microsoft.PowerShell.Commands.GetServiceCommand
to your solution:
[Microsoft.PowerShell.Commands.ServiceCommandException]
Is taking the last part of the category info:
CategoryInfo          : ObjectNotFound: (Unknown:String) [Get-Service], ServiceCommandException
and replacing the last item in the exception message along with removing the bit from the start to the comma going to work every time.
Each time I have used the construct in the past I have found the FullyQualifiedErrorId  works. I am guessing that that is not a reliable source of such information, it would be helpful if there was a standard - I have not found that so far. Any pointers?

Thanks for your reply apologies regarding the title - my bad
The answer you supplied obviously worked - Thanks
The question remains how do I get from the reported error:
FullyQualifiedErrorId : NoServiceFoundForGivenName,Microsoft.PowerShell.Commands.GetServiceCommand
to your solution:
[Microsoft.PowerShell.Commands.ServiceCommandException]
Is taking the last part of the category info:
CategoryInfo          : ObjectNotFound: (Unknown:String) [Get-Service], ServiceCommandException
and replacing the last item in the exception message along with removing the bit from the start to the comma going to work every time.
Each time I have used the construct in the past I have found the FullyQualifiedErrorId  works. I am guessing that that is not a reliable source of such information, it would be helpful if there was a standard - I have not found that so far. Any pointers?

You're welcome; no worries re title; I'm hoping the default title will be removed from the templates soon, so that it'll be more obvious that a custom title should be specified.
As stated, catch expects an exception type as the operand, and the specific type can be determined via the .Exception property of the System.Management.Automation.ErrorRecord instances that represent PowerShell errors:
# Provoke the error of interest.
Get-Service -ErrorAction SilentlyContinue nosuch;
# Examine the .Exception property of the most recent error record  to get the exception's full type name.
$Error[0].Exception.GetType().FullName

The above outputs Microsoft.PowerShell.Commands.ServiceCommandException.

You're welcome; no worries re title; I'm hoping the default title will be removed from the templates soon, so that it'll be more obvious that a custom title should be specified.
As stated, catch expects an exception type as the operand, and the specific type can be determined via the .Exception property of the System.Management.Automation.ErrorRecord instances that represent PowerShell errors:
# Provoke the error of interest.
Get-Service -ErrorAction SilentlyContinue nosuch;
# Examine the .Exception property of the most recent error record  to get the exception's full type name.
$Error[0].Exception.GetType().FullName

The above outputs Microsoft.PowerShell.Commands.ServiceCommandException.

@mklement0 Thanks for that - All resolved now.

@mklement0 Thanks for that - All resolved now.


[FR] Offer an example usage command in the default header comment

What's the problem this feature will solve?
There's confusion as to how the output files are to be used and the header only shows how they were generated.
Describe the solution you'd like
I want the header to have an example on using the generated files as constraint. Specifically, suggesting to perform the installation via PIP_CONSTRAINT=requirements.txt pip install -r requirements.in -c requirements.txt. With the proper filenames, of course.
Alternative Solutions
Letting the confusion live on..?
Additional context
This idea occurred to be having observed how different people have different expectations about using the pip-compile generated files in #2051.

Is explicitly specifying PIP_CONSTRAINT needed when using the -c option on the command line?

Is explicitly specifying PIP_CONSTRAINT needed when using the -c option on the command line?

This is for the constraints to leak into the ephemeral PEP 517 build env provisioning subprocess.


loss becomes nan

lib.utils.logging INFO: [Step 10470/182650] [Epoch 2/50]  [multi]
loss: nan,    time: 5.862533,    eta: 11 days, 16:23:31
meanstd-tanh_auxiloss: nan, 		meanstd-tanh_loss: nan, 		msg_normal_loss: nan, 		pairwise-normal-regress-edge_loss: nan, 		pairwise-normal-regress-plane_loss: nan, 		ranking-edge_auxiloss: nan, 		ranking-edge_loss: nan, 		abs_rel: 0.211080,       whdr: 0.087764,
group0_lr: 0.001000,       group1_lr: 0.001000,
您好，当我在用taskonomy DiverseDepth HRWSI Holopix50k这四个数据集训练的时候，loss变成了nan，请问您在训练的时候有遇到这样的问题吗？如果有应该怎么解决呢？谢谢！下面是我输入的参数
--backbone resnext101
--dataset_list taskonomy DiverseDepth HRWSI Holopix50k
--batchsize 16
--base_lr 0.001
--use_tfboard
--thread 8
--loss_mode ranking-edge_pairwise-normal-regress-edge_msgil-normal_meanstd-tanh_pairwise-normal-regress-plane_ranking-edge-auxi_meanstd-tanh-auxi
--epoch 50
--lr_scheduler_multiepochs 10 25 40
--val_step 5000
--snapshot_iters 5000
--log_interval 10 \

I didn't face this issue. You can clip your gradient to avoid this issue.

Thanks very much, I will try! However, I didn't change the code (the latest) and only change the batchsize and thread and use 8 nvidia V100 to train, what batchsize and thread did you set as you train?

The change of batchsize will not cause the loss nan. I ever faced the "loss nan" problem due to the crop operation. If the depth image becomes invalid(0) for the whole image after cropping, the loss will be nan. I will try to debug and avoid it but it may be time-consuming due to the need for 8 nvidia V100 GPUs.
How many iterations have you trained before the loss nan? You can try to clip the gradient to avoid it, or wait for my debugging. Thank you!

Thanks for your reply！The loss became nan after I trained about 12000 iterations (the 3rd epoch), and I see the code you released contains gradient clip, it seems not work.

Thanks for your reply！The loss became nan after I trained about 12000 iterations (the 3rd epoch), and I see the code you released contains gradient clip, it seems not work.


Your Package Might See More Action ;)

Hey @pederhan :smile:
Just a casual chat - your stellar package could become quite the hot spot soon, due to the Chinese Docker Hub waving goodbye.
A gentle nudge, hope it's all smooth sailing!

Hi, thank you for informing me! Sorry for the low activity on this package; I have been quite busy the past few months with other things. I'll get better at maintaining the package in the future!


[CRITICAL] PSR-4 path to SymfonyStandard is incorrect

It was simply replaced at 6272b3388862e57f6fd688f06a1d1c9896fd4ffd psr-0 with psr-4 but it additionally requires fixing the path to the namespace.

:+1:

Do this affect only the new directory structure as @zerkms explained here?

Thank you @zerkms.

@gremo it affects creating a new directory structure and a demo Acme bundle

@fabpot This should get into a release as you get the Class SymfonyStandard\Composer is not autoloadable, can not call post-root-package-install script when running the install script by composer.
    composer create-project symfony/framework-standard-edition my_project_name "2.7.*"

@peterrehm Seems this problem can be solved if you use the symfony-installer?

Should be the case, however the composer install should be still supported as long as we have it documented.

@Pierstoval I use the directory structure Symfony 3.0 that is not supported symfony-installer

This should help for now:
composer create-project symfony/framework-standard-edition my_project_name "2.7.x-dev*"

2.7.*@dev would be the correct thing here.

This should be in the new 2.7.1 tag now.


Mark as deprecated

This project appears to be dead, with an official successor in bazel-deps (see this comment). Users are, however, sent here by the official Bazel documentation. This wastes everybody's time, and erodes trust in the bazel ecosystem.
This PR marks the repository as deprecated, and redirects visitors to the bazel-deps repo.
If this project is still maintained, and the comment referenced above is wrong, then please disregard this PR.

I signed it!


Added instructions for Android gradle build

More instructions for Android Gradle build. See #35

These our outdated now that javaconfig.json has been deprecated and dependency resolution has been simplified


Question about the exemplar memory

Thank you for your amazing job. When I read the paper, I got a question about the  exemplar memory.
As you said in the Supplementary Material of the paper, the exemplar memory takes about 34MB. Does it mean the extra size of the model  to avoid forgetting? But the number of classes is varibale, how many classes is 34MB  for?

34MB is the size of the exemplar store (when saved to disk) in the 15+5 setting.


Client can join room but app does not open

Hello,
thanks for helping me out with issue #35
Client can now join room.
I have created a new app, copying the MRBike and adjusting it to my needs.
Host can spawn it but client can't go past the icon.
I understand the client should get straight into the app (at least this is what it's happening with the MRBike app).
I attach the logcat of the client.
Thank you for your help.
logcat2.txt

You are saying that the MRBike works as expected but your version of it doesn't, correct?
Does the components of your new app have network behaviours and are setup for networking? I'm asking because if they are networked then your client should see them spawn even if the app is not fully setup properly (like colocation not working).
If you don't see the network object of your new application, make sure that they are spawned properly using the fusion spawn functionality not just game object instantiate.

Hello @AlexThiv
A bit more info here.
I copied/pasted the MRBike folder and renamed it as follows:

I edited the scripts (just renamed some of them):

...and changed the namespace to them all:

Added my app to the manifests:

...and to the list:

My app prefab looks pretty much like the MRBike one:

Also created my icon:

So when my Client connects to the room, it sees my app's puck in the right position but the app does not start (whilst the MRBike app brings him straight into the scene). Clicking on the puck does not do anything. Am I missing something?

Hi @carloposo,
Looking at this there isn't anything that seems wrong in your setup. I just did a simple test to see if I would run into the same issue and it all worked as expected. Could you try to do the same test and see if you run into the same issue? I did it directly from main.

Make a Copy of the BikeNetworkApplication prefab name C123NetwrokApplication
Open it and remove the BikeInteraction Child
Add a cube as a child of the prefab and Save
Regenerate Fusion Prefab tables

Make a copy of Configs/AppManifest/Bike to C123
Update the Unique name, Display Name and link the C123 NetApp prefab in AppPrefab

Add the AppManifest to the AppList
Run application for both Host and Client

Run the App on Host and Client, the app should launch for both and you can see the cube on the client and Host.

Thanks @AlexThiv
Your process worked for me, too.
So I thoroughly inspected my app and found out - my bad - some thing was missing here:

Now everything works as expected.
Thank you for your time!
Carlo


Performance issues when nesting DIVs subscribed to element-resize

Hello!
We're facing performance "issues" while nesting several DIVs subscribed  to element-resize. We tried having a container DIV with 9 inner DIVs. The main container is subscribed to element-resize (and changes its children's width dynamically), and the 9 inner DIVs are also subscribing to their element-resize, and perform other actions to their children.
It takes lots of time of javascript processing (most of it in ResetTriggers()), and the frame rate drops to 1fps, 2fps...  Have you encountered the same? Or have any solution or hint for that?
Thank you!

resetTriggers not only read/write thrashes the DOM, but because it manipulates scroll offsets on DOM elements it also triggers a paint operation on those DOM elements. When said DOM elements don't have their own isolated compositing layer, it will trigger a repaint on the entire layer.
That's just the way this library works and there's little you can do about it without completely changing how resizes are detected.


Error running Quillman code with modal serve src.app

Hi there,
I am experiencing an error running the code with modal serve src.app. Here is the error message:
Building image im-uapgkrskiwyzvdznvrsjdwytfles

=> Step 0: FROM base

=> Step 1: RUN cd /FastChat && python download-model.py anon8231489123/vicuna-13b-GPTQ-4bit-128g
Traceback (most recent call last):
  File "download-model.py", line 196, in <module>
    links, sha256, is_lora = get_download_links_from_huggingface(model, branch)
  File "download-model.py", line 130, in get_download_links_from_huggingface
    fname = dict[i]['path']
KeyError: 0
Terminating task due to error: command "cd /FastChat && python download-model.py anon8231489123/vicuna-13b-GPTQ-4bit-128g" had exit status: 1

Could you please help me identify the root cause of this error and provide guidance on how to fix it?
Thank you

I encountered the same error as well.
The root cause is that download-model.py does not work because HuggingFace appears to have changed their API, which no longer accepts an empty value for the cursor parameter.
https://github.com/thisserand/FastChat/blob/4a57c928a906705404eae06f7a44b4da45828487/download-model.py#L111
Here is a quick and simple workaround to fix this issue. I modified the code to manually download the necessary files, without using download-model.py.
diff --git a/src/llm_vicuna.py b/src/llm_vicuna.py
index c3b210a..8be1b92 100644
--- a/src/llm_vicuna.py
+++ b/src/llm_vicuna.py
@@ -12,7 +12,7 @@ from modal import Image, method
 from .common import stub

 MODEL_NAME = "anon8231489123/vicuna-13b-GPTQ-4bit-128g"
-
+MODEL_DIR = "anon8231489123_vicuna-13b-GPTQ-4bit-128g"

 stub.vicuna_image = (
     Image.from_dockerhub(
@@ -22,7 +22,7 @@ stub.vicuna_image = (
             "RUN apt-get install -y python3 python3-pip python-is-python3",
         ],
     )
-    .apt_install("git", "gcc", "build-essential")
+    .apt_install("git", "gcc", "build-essential", "wget")
     .run_commands(
         "git clone https://github.com/thisserand/FastChat.git",
         "cd FastChat && pip install -e .",
@@ -33,7 +33,14 @@ stub.vicuna_image = (
         "cd /FastChat/repositories/GPTQ-for-LLaMa && python setup_cuda.py install",
         gpu="any",
     )
-    .run_commands(f"cd /FastChat && python download-model.py {MODEL_NAME}")
+    .run_commands(f"mkdir /FastChat/models/{MODEL_DIR}")
+    .run_commands(f"cd /FastChat/models/{MODEL_DIR} && wget https://huggingface.co/anon8231489123/vicuna-13b-GPTQ-4bit-128g/resolve/main/config.json")
+    .run_commands(f"cd /FastChat/models/{MODEL_DIR} && wget https://huggingface.co/anon8231489123/vicuna-13b-GPTQ-4bit-128g/resolve/main/generation_config.json")
+    .run_commands(f"cd /FastChat/models/{MODEL_DIR} && wget https://huggingface.co/anon8231489123/vicuna-13b-GPTQ-4bit-128g/resolve/main/pytorch_model.bin.index.json")
+    .run_commands(f"cd /FastChat/models/{MODEL_DIR} && wget https://huggingface.co/anon8231489123/vicuna-13b-GPTQ-4bit-128g/resolve/main/special_tokens_map.json")
+    .run_commands(f"cd /FastChat/models/{MODEL_DIR} && wget https://huggingface.co/anon8231489123/vicuna-13b-GPTQ-4bit-128g/resolve/main/tokenizer.model")
+    .run_commands(f"cd /FastChat/models/{MODEL_DIR} && wget https://huggingface.co/anon8231489123/vicuna-13b-GPTQ-4bit-128g/resolve/main/tokenizer_config.json")
+    .run_commands(f"cd /FastChat/models/{MODEL_DIR} && wget https://huggingface.co/anon8231489123/vicuna-13b-GPTQ-4bit-128g/resolve/main/vicuna-13b-4bit-128g.safetensors")
 )

Thanks for the report @holyMolyTolli and for the diagnosis @yoshinorisano!


TUREEN'S QOL FUNCTIONS

custom freeplay difficulty sprites, seperate from story mode difficulty sprites

you could do this by reading for a difficulty name (eg. hard) with the prefix of "freeplay" in "images/freeplay"

customisable stage editor hotkey in options

the opportunity for hidden songs to only be visible AFTER completion (WITHOUT SOURCE)

you could do this by making a new array called dependencies, with the song name, it reads if you've completed it yet and if you havent its hidden from menus

midsong stage change event that swaps the currently active json (value 1) with the stage json you WANT to be active (value 2)

weekName variable in the week.json should be whats loaded in the freeplay panel's details under the song name where it says "WEEK (week number)"

you should be able to add ALBUM COVER ART as well as the SONG RATINGS WITH STARS underneath,

On the side of the screen, these album covers would be within a folder, mods/images/freeplay/albumart, where you would add whatever image name you want. then, in the week.json, there should be another variable called album, where you would enter the image name, if it returns null, it should become the placeholder art from the base game!!
The stars underneath would just correspond to the song rating on the freeplay panel where it tells you the difficulty rating on the right side!!!
Thanks for reading, may add more soon
Tureen

Good idea. I didn't though about addit it as a moddable feature, but would make for a great addition.
I couldn't care less about the stage editor
I think you could do that with existing system for locking weeks, but I'll not make anything explicit for it
"Can be done in Lua"
Awaits for merge
No.

Closing because someone else suggested custom Freeplay graphics already

Closing because someone else suggested custom Freeplay graphics already

yeah. it was me.


Roll Engine from 112fb84b5dc1 to c2aa726c735c (1 revision)

https://github.com/flutter/engine/compare/112fb84b5dc1...c2aa726c735c
2021-10-19<EMAIL_ADDRESS>Roll Skia from 835345aaa349 to e1bfa18fc512 (33 revisions) (flutter/engine#29243)
If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-engine-flutter-autoroll
Please CC<EMAIL_ADDRESS>on the revert to ensure that a human
is aware of the problem.
To file a bug in Flutter: https://github.com/flutter/flutter/issues/new/choose
To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug
Documentation for the AutoRoller is here:
https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md

Commit queue failed; closing this roll.


Dashboard > Get started > Section 2: Sunbird Module selection

To start the setup without any sample data user can do the selection from this section.
Multi-selection is available for this section
Next settings steps will be populated based on the selectionsin this section
User will be redirected to Create schema step after clicking on the start button.
Create schema page will be empty, New entity creation button will be displayed
By default, none of the checkboxes will be selected

Attestation & claim
Create Schema -> Configure Workflow -> VC template(attestation workflow) -> Test & Publish
Issuance:
Create schema -> VC template (Overall Schema template) -> Test & Publish
Ownership & Roles
On selection 'Ownership & roles' step will be included in the setup
If none of the options have been selected
Create schema -> Test & Publish


Support setting address mode for textures

I want repeating textures please.

Whoops, this is fixed!
GitHub's closing words didn't pick up "Addresses"


[stdlib] ManagedBuffer: Fix misapplied linkage names for legacy entry points

I accidentally copy and pasted the mangled symbol names in the wrong order, so existing callers got directed to the wrong entry points, and things got terribly, terribly wrong.
(We badly need a sensible replacement for these @_silgen_name hacks.)
Huge thanks to @edymtt for spotting this!
rdar://127016847

@swift-ci test

@swift-ci test


Regression in DataFrame indexing in <IP_ADDRESS>227.

pandas-stubs versions <IP_ADDRESS>227 and later (also tested the most recent and most recent yanked versions) treat [] indexing as producing a Series, even when the result is a DataFrame.
To Reproduce
pandas-stubs-bug.py
from pandas import DataFrame

df = DataFrame({"a": (1,)})
reveal_type(df["a"])
reveal_type(df[["a"]])

python -m mypy pandas-stubs-bug.py
The correct output from pandas-stubs==<IP_ADDRESS>214:
pandas-stubs-bug.py:4: note: Revealed type is "pandas.core.series.Series[Any]"
pandas-stubs-bug.py:5: note: Revealed type is "pandas.core.frame.DataFrame"

The output from pandas-stubs==<IP_ADDRESS>227 or later:
pandas-stubs-bug.py:4: note: Revealed type is "pandas.core.series.Series[Any]"
pandas-stubs-bug.py:5: note: Revealed type is "pandas.core.series.Series[Any]"

Please complete the following information:

OS: GuixSD on WSL2
N/A / Windows 11
Python 3.8.2
mypy 1.1.1
Pandas 1.1.0
pandas-stubs as described above.

Additional context
#537 seems a likely culprit, but I'm not sure how to bisect to make sure (or how to write a test suite to catch the regression). I'm happy to do either if pointed in the right direction.

I can confirm that the issue does not appear in that version of Pandas. I was under the impression that the stubs had some tested level of backwards compatibility, but see that the version checks are minimal and restricted to the test suite. Is the intention to only support indicated releases? Would a change to restore the <IP_ADDRESS>214 behavior for this particular case be accepted?

We only test the stubs against the latest released version of pandas, especially since the pandas API evolves with each new minor version.
You can try to restore the behavior, but you'd have to do so without changing any of the existing tests, and make sure it works with 1.5.3. In particular, the PR you pointed to as the possible culprit has nothing to do with DataFrame.__getitem__(), which is what your examples are looking for when type checking occurs.
I think the reason that this occurred with an older version of pandas is because of how mypy works.  It looks at the stubs, but it will also look inside the python source if it thinks something is missing.  We try to keep the organization of the file hierarchy to match the pandas source, so you also may be running into an issue where files got reorganized in pandas between 1.1.0 and 1.5.3, so mypy can easily get confused.  One thing you might try is to try using pyright and your old version of pandas to see if the error is reported there.  AFAIK, pyright doesn't look inside the code to do type checking (unless a module is completely missing).

In particular, the PR you pointed to as the possible culprit has nothing to do with DataFrame.__getitem__(), which is what your examples are looking for when type checking occurs.

You're absolutely correct; It was a bad guess and bisecting to figure that out was nice and easy.

I think the reason that this occurred with an older version of pandas is because of how mypy works. It looks at the stubs, but it will also look inside the python source if it thinks something is missing.

There's some deep magic working because #550 is the patch which broke this for Pandas 1.1.0.

mypy can easily get confused

It sure looks like that's happening, inside or outside the Pandas source. Is there a way to set the equivalent of a breakpoint at those two lines to see how they're affecting the checks in my example?

One thing you might try is to try using pyright and your old version of pandas to see if the error is reported there.

Thanks, I'll look into this. As you might guess based on the Python and library versions, the environment this issue affects is rather weird, and that prevents the obvious installation of pyright. Suspect I'll need to compile Node for myself or somesuch.
Anyway, I can probably hack together a monkey-patch for this since it's just two lines. No idea if #571 is at all related, but I noticed that issue title the other day and seeing time types pop up again here seems awfully coincidental.

It sure looks like that's happening, inside or outside the Pandas source. Is there a way to set the equivalent of a breakpoint at those two lines to see how they're affecting the checks in my example?

These things can be really hard to track down.  I've done it by incrementally changing the stubs (sometimes line by line) to figure out what particular change causes mypy to change its results.  The challenge here is that it takes about a minute for mypy to check the stubs.  mypy can sometimes have behaviors with a small change that are hard to understand what is the actual root cause.
If you want to fix it in your own code without messing with the stubs, you could write cast(pd.DataFrame, df[["a"]]) to get the type checker to know the right type.

I'm going to close this issue, because we won't be able to support using pandas-stubs with older versions of pandas.


ERR: no data received, TCP connection refused, high CPU and memory usage

Running InfluxDB 1.7.4 on Debian buster/sid
Kernel: Linux 4.19.0-3-amd64 #1 SMP Debian 4.19.20-1 (2019-02-11) x86_64 GNU/Linux
All was working fine until now, a simple SELECT on a measurement fails like this:
> select count(*) from my_measurement
ERR: no data received
> select count(*) from my_measurement
ERR: Post http://localhost:8086/query?chunked=true&db=test&epoch=ns&q=select+count%28%2A%29+from+my_measurement: dial tcp <IP_ADDRESS>:8086: connect: connection refused
> select count(*) from my_measurement
ERR: Post http://localhost:8086/query?chunked=true&db=test&epoch=ns&q=select+count%28%2A%29+from+my_measurement: dial tcp <IP_ADDRESS>:8086: connect: connection refused
> select count(*) from my_measurement
ERR: no data received

At the same time, CPU usage reaches 200%, and memory usage also grows:
PID   USER      PR  NI    VIRT    RES    SHR S  %CPU  %MEM     TIME+ COMMAND
21836 influxdb  20   0 8022072   6.0g 828588 S 200.0  79.1   2:07.78 influxd

After making a backup of all the databases, I tried droping the measurement, took some time with high CPU usage, still the measurement appears:
> drop measurement my_measurement
> show measurements
name: measurements
name
----
test
my_measurement
> select count(*) from my_measurement
>

Also high CPU usage for some seconds in the last SELECT. Trying to drop the measurement again, it's still there:
> drop measurement my_measurement
> show measurements
name: measurements
name
----
test
my_measurement

Also, I don't have that much series (most likely < 1 million). After backing up all databases in ./influxdb_backup directory, here is the disk usage:
$ du -sh /var/lib/influxdb influxdb_backup
768M	/var/lib/influxdb
496M	influxdb_backup

Same problem exists after droping the database containing my_measurement and restoring the backup.

Did you found any solution ?
Actually I am also getting the same error.

Same problem after using SELECT ... INTO. Rebooting didn't help. Looks like the database is busted.
I've put up for a few years with InfluxDB's annoying limitations, but data corruption is too much. I will definitely NOT choose InfluxDB for my next time series project. TimescaleDB is based on PostgreSQL, which has a far better reliability track record.

I have gotten the same exact issues, although with a larger table ~20 million rows (although I was under the impression it would be able to handle much more).

same problem ,
I've write a program to transport  counts of 379,773,838 records from MySql to InfluxDB1.7 OSS
`show databases
name: databases
name
_internal
collectd
mSensorDB
terminal_sensors
terminal_sensors_history`
terminal_sensors  is old database ,everything is ok
` use terminal_sensors
Using database terminal_sensors

select *   from history_sensor_t  order by time desc limit 1
name: history_sensor_t
time                alarmLevel dataValue sensorNo status tno

1563763931270000000 02         67        E11      1      LZSGAJ0056`
but the new database   terminal_sensors_history
can't select , it always refused
`
SHOW MEASUREMENTS
name: measurements
name
history_sensor_t

select * from history_sensor_t order by time limit 1
ERR: no data received
`

During the transporting , the disk space is full, and influxDB  got killed by system
`[root@VM_33_2_centos /var/lib/influxdb/data]# du -h -d1

1.5G	./terminal_sensors_history
189M	./terminal_sensors
251M	./mSensorDB
64M	./collectd
27M	./_internal
2.0G	.

`
I did not config the log to write to file....

How do I reopen ?

Hi,my influxdb version is 1.8.6。 For my select operation, I also encountered this problem. so, has this problem been solved ？ please


Compute tests seems to fail randomly

Compute tests seem to fail randomly on the sdk CI https://github.com/nevermined-io/sdk-js/actions/runs/5402080743/jobs/9813860561?pr=542

moved already to nightly, we will review the compute stack in a further phase


feat: identification summary workflow

The quantification summary workflow and associated files have been copied into the identification directory. Filenames have been adapted.

validation should be the same as in quantification; currently only checks for presence of bed columns (not checking content of score col) are performed, as well as a comparison of the chromosome naming format between input and gtf file (have to be both with or without leading "chr")
compute_metrics has to be adapted:

function definitions should be written in identification_metrics.py. There, the functions from the quantification metric calculation are also still present, those should be either adapted if needed, or otherwise deleted from the script.
function calls have to be adapted in compute_metrics.py. Currently the calls are commented out and instead the variables holding the metrics are set to arbitrary values, in order to test the workflow (delete those)

consolidation should be the same as in quantification.
test files might have to be adapted to identification specific cases

The workflow runs through on my Ubuntu 20.04 machine with the specified dummy metric values.
Fixes nothing
Checklist

[ ] I have performed a self-review of my own code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have updated corresponding READMEs (if applicable)
[ ] My code follows the templates/style guidelines of the repository
[ ] In- and output formats comply with APAeval specifications
[ ] No parameters or file names are hardcoded
[ ] Results, logs or other output is not commited to the repository
[ ] I have tested my code

Please see PR description for instructions

Tests for metrics calculations:
identification_metrics_test_report.pdf


RoBERTa support?

RoBERTa is not supported yet, is it? I tried to apply the instructions here but there's no vocab.txt for RoBERTa but two other files (vocab.json and merges.txt).

Will be included in the new version!
Model here: https://github.com/explosion/spacy-models/releases/tag/en_pytt_robertabase_lg-2.1.0 –  requires spacy-pytorch-transformers>=0.3.0.


append_dir_all appears to be working, but is returning an error

Hello!
I'm using append_dir_all to recursively add a directory and all subdirectories to a tar archive list this:
    let tarball_name = "my_tarball.gz";

    let tarball = File::create(tarball_name).unwrap();
    let mut tar_builder = Builder::new(tarball);

    let hab_pkgs_path = temp_dir_path.clone().join("rootfs/hab");

    tar_builder.append_dir_all("hab", hab_pkgs_path);

The odd thing is this code DOES work - it recursively adds the directory to the tar archive - but this line
tar_builder.append_dir_all("hab", hab_pkgs_path);

returns this error "thread 'main' panicked at 'could not export.: "Is a directory (os error 21)"', /checkout/src/libcore/result.rs:906:4"
I have been trying different things, googling left and right, running backtraces, and I have been unable to find a solution to this error.  Do you know of anything in this code that might cause that?

I think #48 solves this issue

Thanks!


Updated to latest version of vue.js and converted to use @Component and @Props, etc.

Thanks for this great starter project.
In this pull request, I updated the project to work with an unmodified version of Vue by converting it to use @Component from vue-class-component and @Prop from vue-property-decorator. I also did some modifiationcs to make better use of Visual Studio Code's build-in compiler functions.

@jdiehl,
Thanks for your contribution.
To ensure that the project team has proper rights to use your work, please complete the Contribution License Agreement at https://cla.microsoft.com.
It will cover your contributions to all Microsoft-managed open source projects.
Thanks,
Microsoft Pull Request Bot

@jdiehl, thanks for signing the contribution license agreement. We will now validate the agreement and then the pull request.
Thanks, Microsoft Pull Request Bot

I didn't know, you could do that... That's awesome! Fixed.

Hey there, I think the goal we had with this starter (while it is a work-in-progress) is that we are trying to stick with plain-old Vue.
While I personally think decorators can be awesome, and appreciate the flexibility that Vue has in how you can use it, the way I've come to think about this is that a TypeScript Vue project shouldn't look drastically different from a canonical JavaScript Vue project. We actually put a lot of work into TypeScript 2.3 to accurately type libraries like Vue, Ember, and others so that decorators wouldn't have to be the way TypeScript users write Vue.
That said, I would love to hear your thoughts. I'm sure a lot of people aren't hung up on how they write Vue as long as they can write Vue.

@jdiehl Do you mind updating README.md as well as part of this PR? It depicts the very use-case why custom build is used
Thanks!

@DanielRosenwasser One could argue that using .vue single file components is already different from a canonical JavaScript Vue project. But vue-loader and vue-class-component are both maintained by the core team and you can find them on the official vuejs.org docs.
In particular, Class-Style Vue Components with vue-class-component are on the official website under the TypeScript support section, so I think it is pretty clear that Vue encourages TypeScript users to use this style.
Note also the advantages about type inference that are explained in the docs.

I appreciate your efforts in keeping TypeScript projects as similar as possible to plain vanilla Vue projects and I am sure that this will help many experienced Vue programmers. However, I believe starter projects like this also have the opportunity (and maybe the responsibility) to teach programmers new and easier ways of building apps. Whether the @Component-approach falls under that category is not my decision to make.

@peterblazejewicz I'll be happy to work on the Readme but I think we should resolve the issue raised by Daniel first.

Don't underestimate the cost of migration to decorators. One of the major factor in TS's popularity is its low migration cost. Just rename .js to .ts and you get better type check, IntelliSense, etc.
Now it's possible to do that migration by just changing <script> to <script lang="ts"> and wrapping the export object in Vue.extend. That's much better than rewriting your whole app with decorators.
Also, the updated type definition can also be used to enhance the editor support for existing Vue projects with js, and the only thing people have to do is to update their vue dependency.
I suggest that you to fork this project or create your own starter template for TypeScript + Vue.

@DanielRosenwasser One could argue that using .vue single file components is already different from a canonical JavaScript Vue project.

Well that's why I show an ordinary component and then showed a .vue file. I think it's fair to say that at this point, .vue files are pretty common at this point.
In fact, you can see there's a relatively small gap between vue and vue-loader npm downloads (a smaller margin than vuex and vue-router!). While that is not necessarily the most in-depth analysis, it gives a decent picture.
For what it's worth, I think that having a section about using classes with decorators in Vue would be really useful as well. We might talk about why one might use them over the current approach since there are caveats to the declaration files we've authored when members circularly reference each other.

I have update the readme and fixed several consistency issues. If you do not want to merge this pull request, I would be happy to host it on my fork and would appreciate a link from your readme.

What's about the status of this PR?
It'd be great if this project could be updated with the latest changes of vue 2.5.

This pull request is about decorators. I noticed that the example has significantly changed from the time I created the pull request, so I updated my changes to reflect the current project. I also added the decorators example as an optional part, so everyone can choose how they want to work with Vue and Typescript.

@DanielRosenwasser: Thanks for the feedback. I hope the changes address all of your issues.

@jdiehl there seems to be a huge diff based on whitespace. Can you revert the whitespace changes and amend the commit?

Whatever happened there... It is fixed now.
I appreciate you double-checking everything - should have seen that one myself...

@jdiehl, I apologize; I meant to send out some changes that I guess got backed out on README.md as a PR, but accidentally committed directly to your branch. Let me know if the changes look good and I'll pull it in!

@DanielRosenwasser Looks good.

Thanks so much!!

This is a huge DX improvement here, bravo !

Thank you guys!


Dont use DefinitionDecorator on symfony 3.3+

Fixes #345

@chalasr thank you!
Will you create a new release with this fix?

@xthiago you're welcome! just released in v2.4.1


early error returning when having spaces in .env comment

I read the specification of defining the .env file and realize that we can define a variable with spaces inside,
However, using laravel framework version 5.2.35, I got an error when having this line in .env  like this
TIMEOUT=100000 # increase if import times out.
And the exception gone away when I removed the comment.
or when change it to
TIMEOUT=100000 # "increase if import times out."
Regarding to this issue, the thrown exception is
Class log does not exist
and it's very hard to know the exact error.

This is a known bug in laravel, sorry.


The default PowerShell profile is not properly handled.

The following checks have been done.

[X] I could not find another bug report that covers what I discovered.
[X] This report does not request new features or enhancements.

What is the current behavior?
The application does not integrate into the correct PowerShell profile.
What is the expected behavior?
The application properly detects the active PowerShell profile and uses it for integration.
Some additional context.

The application assumes that the profile is always in one location, which is not necessarily the case.
A StackOverflow provided a nice explanation on how PowerShell profiles can be discovered.

It would be nice to also warn the user during the PowerShell integration process that the aws-login shell install command may need to be executed for other profiles they may be using.


Test

Changes

Submitter Checklist

[ ] Includes tests if functionality changed/was added
[ ] Includes docs if changes are user-facing
[ ] Set a kind label on this PR
[ ] Release notes block has been filled in, or marked NONE

See the contributor guide
for details on coding conventions, github and prow interactions, and the code review process.
Release Notes

This was by mistake. Closing


[Feature Request] Support for Gymnasium

Motivation
Gymnasium is a fork of the OpenAI Gym project by that same people that maintained Gym for the last 18 months.
Our understanding from OpenAI is that they are not planning on maintaining Gym currently therefore, we would recommend using Gymnasium.
For more information about this, see our announcement - https://farama.org/Announcing-The-Farama-Foundation
Solution
Currently, the Gymnasium and Gym are identical repos so should be compatible between the two projects.
try:
   import gymnasium as gym
except ImportError:
   import gym

However in the future, we are planning on adding a new feature improvements that this repo would be interested in

Thanks for this @pseudo-rnd-thoughts
I like the idea! We're as excited as can be about gymnasium and looking forward to adopting it.
We're in the process of making the library compatible with gym 0.13 and on -- quite a herculean task!
I would be glad to have your thoughts on that.
## Some context:
Currently, for instance, we do not support the new step method (which I believe returns 2 Booleans instead of one done state). This is something we should work on, I'm planning to do that once we have our versioning utils in place.
Many of our users stick to a specific gym version (e.g. habitat or robotic people) and they're happy with it. As a SOTA library we obviously want to support latest changes too!
Versioning
I see that gymnasium starts at 0.26.3, meaning that it's one step ahead of gym. So I guess we'd be good with the code snippet you provided above (since we'll be calling if parse(gym.__version__) < smth frequently).
Therefore I guess that our end it's mostly going to be just a matter of replacing gym import in the gym.py file and changing the CI configuration to install gymnasium instead.
I guess we can take care of that. I'll keep you posted on the progress.

Thanks for the quick response. That works for us
Do you mind me asking why 0.13 is the minimum?
It is a 3 year old version with a number of critical differences in the core API between 0.13 and the latest version. In addition to the bug fixes and features that it is missing, plus it only supports python 3.7.

For what it's worth, if you want to keep old API compatibility and a more supported older version of Gym, we'd recommend using 0.21. Upgrading from 0.13 to 0.21 shouldn't even be especially difficult

Do you mind me asking why 0.13 is the minimum? It is a 3 year old version with a number of critical differences in the core API between 0.13 and the latest version. In addition to the bug fixes and features that it is missing, plus it only supports python 3.7.

Mainly hardware requirements.
Some libs for robot control have been written with gym 0.13 and upgrading to a new gym version is going to be hard for these users -- once it holds you don't touch it.


Optional promise with reload first promise

HI,
I read all documentation but I don't response my question with successfull.
I have this scenario

I call the authenticated api point

If the response is 200 to 299 I fullfill
If the response is 401 I call the api for refresh the token

If i refreshed the API token I need to re-call the first api point (for recovery the needed data).
Can you help me with this problem?
Thanks

func firstThing() -> Promise { /*…*/ }

firstly {
    firstThing()
}.then {
    if !ok {
        return refreshToken().then(firstThing)
    } else {
        return Promise(value: something)
    }
}

Thanks mxci
I have another situation
1- I call the authenticated api point
2- I create the object if the call work fine
If the response is 401 I call the api for refresh the token and I need to return the point 1
If I want to return at the first point of the Promise?
With your example in this point
if !ok {
return refreshToken().then(firstThing)
} else {
return Promise(value: something)
}
I work out of the Promise workflow
Thanks

Sorry I don’t understand your question.

Hi,
`    @IBAction private func loadNotification(){
    firstly{

        provaRequest()

        }.then { dictionary -> Void in

            print(dictionary)

        }.catch{ (error) in

            if true{

                self.provaRefresh().then{ dictionary -> Void in

                    self.loadNotification()
                }
            }
    }
}`

In this moment I solved my problem like this...but I don't like
I need restart (from the firstly) when the self.provaRefresh is executed (in the catch I capture the expiring of token, I refresh it end I recall the first endpoint "provaRequest()"
Thanks

@IBAction private func loadNotification(){

    func foo() -> Promise {
        firstly {
            provaRequest()
        }.then { dictionary -> Void in
            //…
        }
    }

    firstly {
        provaRequest()
    }.recover { error in
        if case Error.foo = error {
            return provaRequest()
        } else {
            throw error
        }
    }.then { dictionary -> Void in
        //…
    }.catch { error in
        // other errors
    }
}

Thanks @mxcl but I have the warning
`firstly{
        provaRequest()

        }.recover { (error) -> Promise<Any> in

            if true {

                  return self.provaRefresh().then { dictionary -> Void in

                    print(dictionary)
                    # self.provaRequest()
                }

            } else {

                throw HttpRequest.errorObject()
            }

        }.then { dictionary -> Void in

            print(dictionary)

        }.catch{ (error) in

            print(error)
    }`

Result of call to 'provaRequest()' is unused

Hi,
I solved with this but I'm not sure it's okay
`let refresh:Promise = provaRefresh().then{_ in
        self.provaRequest()

    }

    firstly{

        provaRequest()

        }.recover { (error) -> Promise<Any> in

            if true {

                return refresh

            } else {

                throw HttpRequest.errorObject()
            }

        }.then { dictionary -> Void in

            print(dictionary)

        }.catch{ (error) in

            print(error)
    }`

The async tasks in refresh immediately start executing, so no, it isn't doing what you want. You need to wrap the whole thing in a function that returns the promise just like the example code I provided.

You got a warning because you didn't return… just like the warning said…