Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

move numberOfAttempts to state from options #889

Merged
merged 7 commits into from
Apr 25, 2019

Conversation

johnataylor
Copy link
Member

  • moves the numberOfAttempts property into the state from the options
  • adds a typed/named property to the top level for parity with the typing/discovery C# implementation

@johnataylor
Copy link
Member Author

also refer to microsoft/botbuilder-dotnet#1774

@benbrown
Copy link
Contributor

is defaulting it to 0 the right thing to do?

@coveralls
Copy link

coveralls commented Apr 24, 2019

Pull Request Test Coverage Report for Build #2222

  • 8 of 8 (100.0%) changed or added relevant lines in 3 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.02%) to 88.257%

Totals Coverage Status
Change from base Build #2213: -0.02%
Covered Lines: 3245
Relevant Lines: 3532

💛 - Coveralls

@johnataylor
Copy link
Member Author

Its interesting you should comment on that - the original was 0 based - the reason being one of the natural pieces of code to write was to look up the prompt test in an array and arrays are 0 based.
However, @gabog changed this to 1 based. I gave feedback commenting on that change.

Anyhow I'm not that strongly of an opinion on this, but i think the 0 based array is something to consider. I mean this actually is an index. (Unlike JavaScript month which is 0 based but isn't 😱 )

@cleemullins
Copy link
Contributor

cleemullins commented Apr 25, 2019

The tests are failing. Build error is:

(node:1019) UnhandledPromiseRejectionWarning: AssertionError [ERR_ASSERTION]:  text === "Send me a zero"
    at defaultInspector (/Users/vsts/agent/2.150.0/work/1/s/libraries/botbuilder-core/lib/testAdapter.js:206:469)
    at waitForActivity (/Users/vsts/agent/2.150.0/work/1/s/libraries/botbuilder-core/lib/testAdapter.js:209:119)
    at Promise (/Users/vsts/agent/2.150.0/work/1/s/libraries/botbuilder-core/lib/testAdapter.js:209:339)
    at new Promise (<anonymous>)
    at TestFlow.previous.then (/Users/vsts/agent/2.150.0/work/1/s/libraries/botbuilder-core/lib/testAdapter.js:207:8)
(node:1019) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 49)
(node:1019) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
BotFrameworkAdapter.processActivity(): 400 ERROR - Error: BotFrameworkAdapter.parseRequest(): invalid request body.
BotFrameworkAdapter.processActivity(): 400 ERROR - Error: BotFrameworkAdapter.parseRequest(): missing activity type.
BotFrameworkAdapter.processActivity(): 401 ERROR - Error: failed auth
BotFrameworkAdapter.processActivity(): 500 ERROR - Error: bot exception
(node:1019) UnhandledPromiseRejectionWarning: Error: Unauthorized
    at MicrosoftAppCredentials.getToken (/Users/vsts/agent/2.150.0/work/1/s/libraries/botframework-connector/lib/auth/microsoftAppCredentials.js:35:643)
    at process._tickCallback (internal/process/next_tick.js:68:7)

@benbrown benbrown merged commit 0f320cb into master Apr 25, 2019
@benbrown benbrown deleted the johtaylo/1748_numberOfAttemptsProperty branch April 25, 2019 21:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants