Skip to content

Conversation

@alfarok
Copy link
Contributor

@alfarok alfarok commented Jan 14, 2019

Purpose

This PR reverts #9393 as QA testing revealed the following regression. When attempting to submit a crash report from Dynamo, while not logged in to GitHub, it is easily possible to exceeding the maximum URI length leading to 414 Request-URI Too Large error in the browser. Previously users were taken to https://github.com/DynamoDS/Dynamo/issues no matter what which does not require auth.

The team is concerned this will lead to users failing to report errors if they are not always logged in to GitHub. We will revert this PR in RC2.1 but leave it in Master and address the issue in DYN-1194.

image

Issue/Solution

According to the HTTP specification:

Various ad hoc limitations on request-line length are found in practice. It is RECOMMENDED that all HTTP senders and recipients support, at a minimum, request-line lengths of 8000 octets.

If the URL is too long, the web server fails with the 414 Request-URI Too Long HTTP status code.

The common workaround for these problems is to use POST instead of GET and store the parameters in the request body. The length limits on request bodies are typically much higher than those on URL length. For example, the limit on POST size, by default, is 2 MB on IIS 4.0 and 128 KB on IIS 5.0. The limit is configurable on Apache2 using the LimitRequestBody directive, which specifies the number of bytes from 0 (meaning unlimited) to 2147483647 (2 GB) that are allowed in a request body.

Declarations

Check these if you believe they are true

  • The code base is in a better state after this PR
  • Is documented according to the standards
  • The level of testing this PR includes is appropriate
  • User facing strings, if any, are extracted into *.resx files
  • All tests pass using the self-service CI.
  • Snapshot of UI changes, if any.
  • Changes to the API follow Semantic Versioning, and are documented in the API Changes document.

Reviewers

@QilongTang @mjkkirschner @smangarole

FYIs

@Racel @radumg

radumg and others added 3 commits January 11, 2019 18:03
* add /new to GitHubBugReportingLink url

* add bug report title to .resx

* add support for pre-filled new Github issue text when reporting

* Revert resx un-necessary changes

* simplify query construction

since we make a new Uri, it would never have any existing query parameters

* rename variables for legibility

* add fallback values for text to prevent null exceptions

* invert IF logic to bail early

* add XML comment for public method

* get rid of conditional logic ✌️

* scaffold unit tests for CrashReporting

* add CrashReportingTests.cs to DynamoCoreWpfTests proj

* remove public access modifiers

* add logged out fallback and make tab detection case-insensitive

* move issue text & url formatting to new CrashUtilities.cs file

* add test for long stack trace

* Revert "Revert resx un-necessary changes"

This reverts commit 01fc93c.

* add description to issue crash report

* fix XML comments

* further formatting to crash report

* Include issue details from old template

* additional new line required

* remove browser interaction from unit tests

* decrement Dynamo version to make release

* comment spelling

* spelling - GithhubCrashReportBody becomes GitHubCrashReportBody
@mjkkirschner
Copy link
Member

LGTM (pr is busted because of eng ops job, please restart with correct params)

@alfarok alfarok added the LGTM Looks good to me label Jan 14, 2019
@QilongTang
Copy link
Contributor

@mjkkirschner Resource changes in it? I will let localization team know

@QilongTang QilongTang merged commit df13d94 into DynamoDS:RC2.1.0_master Jan 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

LGTM Looks good to me

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants