instance_id
stringlengths
10
65
repo
stringlengths
5
59
pr_number
int64
1
313k
task_type
stringclasses
1 value
base_commit
stringlengths
40
40
review_commit
stringlengths
40
40
title
stringlengths
2
282
body
stringlengths
7
3k
patch
stringlengths
202
204k
n_defects
int64
1
72
n_supported
int64
1
65
n_major
int64
0
32
defects
stringlengths
140
18.8k
certifier_count
int64
yarnpkg__yarn__2279
yarnpkg/yarn
2,279
defect
2843f24fe5500e3c00ec699be55129a18f14a84a
c5b7bab2d7f9c07ddd947af9e35a83f1bac2944d
Fixed #1242 - missing transitive dependencies
**Summary** Fixes #2142, transitive dependencies now inherit "ignored" state from parent dynamically **Test plan** Test has been added before and now is enabled
diff --git a/__tests__/commands/install/integration.js b/__tests__/commands/install/integration.js index b4d07b5f0c..902459ff63 100644 --- a/__tests__/commands/install/integration.js +++ b/__tests__/commands/install/integration.js @@ -696,20 +696,6 @@ test('install a scoped module from authed private registry with a mi...
3
2
0
[{"id": "G0", "claim": "Move the fsevents comment to above the `if (process.platform !== 'darwin')` block so it explains why the test is skipped.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Use the shorter arrow-function form `() => ref.ignor...
null
yarnpkg__yarn__2419
yarnpkg/yarn
2,419
defect
e48cd2ab06a0f9ebbe501ec2e2f23175051a594e
50cf3a452e554a69f7587fe6ed5710045c377a7d
feature: check --verify-tree for verifying node_modules structure
**Summary** Yarn needs an independend of resolving mechanism way of verifying node_modules correctness **Test plan** Manual test plan for React Native with these modifications: - removed `node_modules/chalk` (direct and hoisted dep) - removed `node_modules/symbol-tree` (dev dep) - modified version of `nod...
diff --git a/__tests__/commands/check.js b/__tests__/commands/check.js new file mode 100644 index 0000000000..2fdcda08c5 --- /dev/null +++ b/__tests__/commands/check.js @@ -0,0 +1,68 @@ +/* @flow */ + +import type {CLIFunctionReturn} from '../../src/types.js'; +import * as reporters from '../../src/reporters/index.js';...
4
4
2
[{"id": "G0", "claim": "The new --commonjs check needs cleanup and tests before merging.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The --commonjs flag name is unrelated to what it does and should be renamed, e.g. --verify-tree, --resolve-correctly ...
null
yarnpkg__yarn__2440
yarnpkg/yarn
2,440
defect
c3191986dd0c75214441b6c9160019014b1fa34d
a0eaf83f4c7639cd73ec74979799fba523f06f86
Set boolean config values correctly
* Fixes #2434 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. --> `yarn config set [option] [false|true]` should set the option value to false/true respectively. Currently it's set to string value "fa...
diff --git a/__tests__/commands/cache.js b/__tests__/commands/config.js similarity index 65% rename from __tests__/commands/cache.js rename to __tests__/commands/config.js index a169a64067..54c5db38f1 100644 --- a/__tests__/commands/cache.js +++ b/__tests__/commands/config.js @@ -31,3 +31,21 @@ test('cache-folder flag ...
2
1
0
[{"id": "G0", "claim": "It would be better for the config command to use `yarnConfig` instead of importing `BaseRegistry` to normalize the option.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The PR appears to have introduced a regression: setting a co...
null
yarnpkg__yarn__2768
yarnpkg/yarn
2,768
defect
81261369f8161dfbcdc9f3f35cfd6210f467a9ac
3dec8d495fb859996664065e63ef30c0a0558fcd
Adds versioning to the cache path
cc @bestander **Summary** Cf #2035 - sometimes the cache structure changes, and things break. This commit adds an additional part in the cache path that allows to invalidate previous caches. These old caches will not get removed until after running `yarn cache clean`, which allows for some easy rollback, just...
diff --git a/__tests__/commands/install/integration.js b/__tests__/commands/install/integration.js index 327822c08c..07d5f394df 100644 --- a/__tests__/commands/install/integration.js +++ b/__tests__/commands/install/integration.js @@ -1,5 +1,7 @@ /* @flow */ +import type Config from '../../../src/config'; +import {r...
6
5
4
[{"id": "G0", "claim": "The new versioned cache path behaviour should be covered by tests, ideally an integration test in __tests__/commands/install/integration.js that installs and checks the cache folder contents.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", ...
null
yarnpkg__yarn__2970
yarnpkg/yarn
2,970
defect
1c36baff78fdd5dfab932f7e4d71f1082a775622
6e6ccde56a92f16df58b88ba030c9b966174624d
[breaking?] - When using offline mirror yarn.lock does not change anymore
**Summary** Related rfc : https://github.com/yarnpkg/rfcs/pull/51 When enabling the offline mirror, Yarn updates the lockfile by stripping the registry URL from its `resolved` fields. This feature aims to simplify this process by making such an update unneeded. Related issues: https://github.com/yarnpkg/yarn...
diff --git a/__tests__/commands/add.js b/__tests__/commands/add.js index b05baeb169..d93afb2a24 100644 --- a/__tests__/commands/add.js +++ b/__tests__/commands/add.js @@ -115,9 +115,13 @@ test.concurrent('add should ignore cache', (): Promise<void> => { const lockFileWritten = await fs.readFile(path.join(config....
2
1
1
[{"id": "G3", "claim": "The offline-mirror blog post (and the docs page linking to it) now misdescribes the lockfile and should be updated.", "category": "documentation", "verdict": "uncertain", "priority": "P1", "scope": "introduced"}, {"id": "G4", "claim": "This change has broken git+https dependencies (as reported i...
null
yarnpkg__yarn__3190
yarnpkg/yarn
3,190
defect
08974574710ae11499ed1544b3d292cff815963c
8cd2f6481d555e3b6889a192483096079dede63a
feat(Upgrade): add scope flag to the upgrade command
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. --> The `upgrade` command now supports the `-S, --scope <scope>` flag. If the flag is set and a scope is provided yarn upgrade only the packages, which belong ...
diff --git a/__tests__/commands/upgrade.js b/__tests__/commands/upgrade.js index 9d123606b9..825b28604d 100644 --- a/__tests__/commands/upgrade.js +++ b/__tests__/commands/upgrade.js @@ -292,3 +292,16 @@ test.concurrent('can prune the offline mirror', (): Promise<void> => { expect(await fs.exists(path.join(config....
7
7
5
[{"id": "G0", "claim": "The change leaves stray console.log debug statements in the upgrade command (one for allDependencies, one for remoteSource).", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The flags.scope value is used without any check t...
null
yarnpkg__yarn__3510
yarnpkg/yarn
3,510
defect
1f84d37ddebeb1d5f18ecf128d6a812a42be4a72
c48806cf6cf94dfac0f93bcfddb891006f2a5d6b
Add "latest" flag to "yarn upgrade"
Implements requested feature in #3384 Adds a `yarn upgrade [--latest/-L]` flag. This flag instructs Yarn to upgrade all dependencies to the latest version specified by it's registry, ignoring the versions specified in `package.json`. This is functionally equivalent to running `yarn upgrade <package>` and pass...
diff --git a/__tests__/commands/upgrade.js b/__tests__/commands/upgrade.js index d449d61dd2..12f5aefbd8 100644 --- a/__tests__/commands/upgrade.js +++ b/__tests__/commands/upgrade.js @@ -102,6 +102,70 @@ test.concurrent('upgrades from fixed version to latest', (): Promise<void> => { }); }); +test.concurrent('upgr...
7
4
1
[{"id": "G0", "claim": "The new flag should be named `--all` instead of `--latest`, since it is functionally equivalent to passing all dependency names to `yarn upgrade`.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The `.map` callback for the `--latest`...
null
yarnpkg__yarn__3544
yarnpkg/yarn
3,544
defect
db5edeaa22dd27898ab5c5f1b45f88b6b2095e39
5aa7dd87d84b49aa139e042f5e93a1207dc7d168
Auto detect and merge lockfile conflicts
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. --> **Summary** Git merge conflicts are common with `yarn.lock`. This PR allows you to run `yarn` to automatically merge the two versions of `yarn.lock` whi...
diff --git a/__tests__/lockfile.js b/__tests__/lockfile.js index 3f0ddad6f2..6e57c41b4b 100644 --- a/__tests__/lockfile.js +++ b/__tests__/lockfile.js @@ -193,3 +193,27 @@ test('Lockfile.getLockfile (sorting)', () => { expect(actual).toEqual(expected); }); + +test('parse merge conflicts', () => { + const file = ...
15
11
3
[{"id": "G0", "claim": "Drop the \"GIT_\" prefix from the conflict marker constants, since other tools generate similar conflict markers.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The constant name has a typo: MERGE_CONFLCIT_END should be M...
null
yarnpkg__yarn__3667
yarnpkg/yarn
3,667
defect
30d3e53ecc861b9a959ee5bd35bab0174e055a4c
d112a9b087234c205352f188a9a7b6eac5b297b6
Update: Make tests great again on Travis CI macOS
**Summary** macOS tests on Travis CI keep timing out and they run very slowly. This patch attempts to solve this by doing the following: - Use ramfs for `__tests__` folder and for `$TMPDIR` for faster file system - Remove unnecessary `brew update` and `brew install yarn` commands - Remove unnecessary `--max-wor...
diff --git a/.travis.yml b/.travis.yml index de396dc87a..87ecd43955 100644 --- a/.travis.yml +++ b/.travis.yml @@ -28,7 +28,7 @@ env: - TEST_TYPE="build-dist" - TEST_TYPE="check-lockfile" - TEST_TYPE="lint" - - TEST_TYPE="test-ci -- -- --maxWorkers 3" + - TEST_TYPE="test-ci" matrix: exclude: ...
1
1
0
[{"id": "G0", "claim": "The runUnlink helper should use await instead of a .then chain to run unlink after link.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}]
null
yarnpkg__yarn__3803
yarnpkg/yarn
3,803
defect
472a051ec830f1da19f0df5a37823155a9acc0e7
4766ab954a2a556ea7524807e24bb6dd7ecdd527
Fix: Peer dependencies should only be looked up from top level dependencies
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. --> **Summary** This is a bug fix for https://github.com/yarnpkg/yarn/issues/3710 The previous implementation of satisfying peer dependencies of an added d...
diff --git a/__tests__/commands/add.js b/__tests__/commands/add.js index 2fea1c10a1..1f219140d2 100644 --- a/__tests__/commands/add.js +++ b/__tests__/commands/add.js @@ -803,6 +803,29 @@ test.concurrent('warns when peer dependency is incorrect during add', (): Promis ); }); +test.concurrent('should only refer to...
2
1
1
[{"id": "G0", "claim": "The find callback should not assign to foundPattern in the outer scope; instead return the package with root and patterns from the callback and derive foundPattern from it afterwards.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": ...
null
yarnpkg__yarn__3811
yarnpkg/yarn
3,811
defect
e0e119e9195cb6fd0b885f61b0a9f7a7e5d0326a
3da8965ce0f40e15d44e7169b67d7b3bbfb7a55d
Bugfix 3306: Check top level patterns during integrity check
**Summary** Fixes [issue 3306](https://github.com/yarnpkg/yarn/issues/3306). Previously changes to the package.json dependencies would not throw an error during integrity checks, unless there were zero dependencies, in which case an empty yarn.lock would be written. A condition was added to the integrity checker fo...
diff --git a/src/cli/commands/install.js b/src/cli/commands/install.js index 79964e00f3..2f070ec0cd 100644 --- a/src/cli/commands/install.js +++ b/src/cli/commands/install.js @@ -359,6 +359,13 @@ export class Install { return true; } + if (!match.integrityMatches && match.integrityError == 'PATTERNS_DO...
2
2
2
[{"id": "G0", "claim": "Setting this.flags.force = true when top-level patterns don't match is too blunt — force also rebuilds binary dependencies — so the bailout should not force and the mismatch handling (cleaning up / regenerating the lockfile) should live where the lockfile is saved instead of in the bailout funct...
null
yarnpkg__yarn__4038
yarnpkg/yarn
4,038
defect
357dc225505adbf2e9cc8ddd1374e16d4dc5d1a3
7d1214a8f7feaf01db7f67130235dc97a2bb68fb
Fix: use `git add` with relative path to git root in version command
**Summary** Refs #3610. Some versions of `git` doesn't support passing absolute paths to `git add` causing it to fail. This patch runs `git rev-parse --show-toplevel` to git root and uses the relative path of `package.json` to that directory when calling `git add`. **Test plan** Manual tests for now.
diff --git a/__tests__/commands/version.js b/__tests__/commands/version.js index 124ea87af7..d19033a855 100644 --- a/__tests__/commands/version.js +++ b/__tests__/commands/version.js @@ -1,7 +1,7 @@ /* @flow */ jest.mock('../../src/util/execute-lifecycle-script'); -jest.mock('../../src/util/child'); +jest.mock('../...
3
3
1
[{"id": "G0", "claim": "Use `() => Promise.resolve()` instead of `Promise.resolve.bind(Promise)` for the no-op return, as it is easier to parse and can have lower runtime overhead.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The git add, comm...
null
yarnpkg__yarn__4047
yarnpkg/yarn
4,047
defect
709296432b656fc38ffcd625e310b7c6291e2435
7ab24959ecf6f2d6b4d39bb7269150cf06c0dc0f
Check for npmrc in home directory for linux root users
**Summary** Fix for https://github.com/yarnpkg/yarn/issues/3920. In this [commit](https://github.com/wtgtybhertgeghgtwtg/yarn/commit/f4fe7431ed992862a1c1d2357e6521c268bad7a7), `userHome` for linux users running as root was changed to `/usr/local/share`, mainly to allow for other users to run globally added bins. Ho...
diff --git a/__tests__/registries/npm-registry.js b/__tests__/registries/npm-registry.js index 27adabe28d..245ba8105a 100644 --- a/__tests__/registries/npm-registry.js +++ b/__tests__/registries/npm-registry.js @@ -50,12 +50,17 @@ function createMocks(): Object { getScopedOption: jest.fn(), }, }; - cons...
6
6
1
[{"id": "G0", "claim": "The new home-dir override should not be limited by whitelisting only Linux (blacklist Windows instead), and the reviewers ask whether the root logic should cover other platforms like BSD too.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "...
null
yarnpkg__yarn__4165
yarnpkg/yarn
4,165
defect
f513948fb19d79dcc490be295b5e3df2a7dd95ed
666c8b700745e3cefb356a0f6c2f9fb50d6319c9
Add private flag for yarn init command
**Summary** Close #4113, this PR create the `private` flag for `yarn init` command. Can use both `yes` and `private` flags. Or can use `private` flag alone to set `private` is `true` when run command. **Test plan** Have added tests
diff --git a/__tests__/commands/__snapshots__/init.js.snap b/__tests__/commands/__snapshots__/init.js.snap index 0a0ae8c986..c5365716bf 100644 --- a/__tests__/commands/__snapshots__/init.js.snap +++ b/__tests__/commands/__snapshots__/init.js.snap @@ -5,6 +5,7 @@ Object { "license": "MIT", "main": "index.js", "...
5
1
0
[{"id": "G0", "claim": "Add `validation`/`validationError` to the private question (or only accept \"true\"/\"false\" and drop the \"yn\" dependency) so the user enters something \"yn\" can convert to a boolean.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim"...
null
yarnpkg__yarn__4174
yarnpkg/yarn
4,174
defect
634c239980d53440e506425e38877228f0920ec1
c2f367957052629fa9d71e8ffab09bed7a1e0810
Add cwd flag
**Summary** Fixes #692. This adds a `--cwd` flag to change the current working directory. This is so you can specify another working directory to perform an operation that's not the current one. But Sebastian, why not just cd into it and run Yarn there? 1. In Node the cwd is `realpath`d which means that if you cd...
diff --git a/__tests__/fixtures/rc/empty/.yarnrc b/__tests__/fixtures/rc/empty/.yarnrc new file mode 100644 index 0000000000..8b56506f1d --- /dev/null +++ b/__tests__/fixtures/rc/empty/.yarnrc @@ -0,0 +1 @@ +--foo true diff --git a/__tests__/fixtures/rc/inside/.yarnrc b/__tests__/fixtures/rc/inside/.yarnrc new file mod...
11
7
3
[{"id": "G0", "claim": "A `--cwd` flag inside a `.yarnrc` file should be honoured — the initial `.yarnrc` search should follow it, restart relative to it, and bail out on recursion — so that yarnrc options are read relative to the requested working directory instead of only the launch directory.", "category": "design",...
null
yarnpkg__yarn__4195
yarnpkg/yarn
4,195
defect
a9e343c2843ad04f2a2b4ee5c48636e88abd8e45
adbf29082415029146f1643142ac4c1497cc339c
Fix: Lockfile should be updated when merge conflcits are resolved
**Summary** Follow up to #3544. Currently, `yarn` happily keeps moving if it detects merge conflicts and is able to resolve them in the lockfile. That said it doesn't persist the resolution by saving the lockfile to disk again. This patch ensures writing the lockfile if it is "dirty". This patch also causes `...
diff --git a/__tests__/commands/_helpers.js b/__tests__/commands/_helpers.js index 7d496de79f..2417373bf7 100644 --- a/__tests__/commands/_helpers.js +++ b/__tests__/commands/_helpers.js @@ -38,7 +38,7 @@ export async function createLockfile(dir: string): Promise<Lockfile> { lockfile = parse(rawLockfile).object; ...
3
1
0
[{"id": "G0", "claim": "The Lockfile constructor's third argument should be an optional object with a `parseResultType` key (e.g. `new Lockfile(..., { parseResultType: 'success' })`) instead of an unnamed positional argument.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id...
null
yarnpkg__yarn__4246
yarnpkg/yarn
4,246
defect
e6211fef8914fa41a4737ce44b82886a22f4ad30
a5f49290a93f2e71f6e7dbb0658bdd9f8e84d41e
Better active directory selection
**Summary** Fix #2709 - Yarn will now try to move to the closest ancestor directory that contains a `package.json` file if it can. If none is to be found, the current directory will be used as usual. Note that the same behavior if applied to the `--cwd` option, so `--cwd foo/bar` will go to `foo` if `foo/package.jso...
diff --git a/__tests__/index.js b/__tests__/index.js index 4d2a46eb4b..89cd6c8ee9 100644 --- a/__tests__/index.js +++ b/__tests__/index.js @@ -243,7 +243,7 @@ if (process.platform !== 'win32') { } test.concurrent('should run bin command', async () => { - const stdout = await execCommand('bin', [], '', false); + c...
3
3
0
[{"id": "G0", "claim": "The new test should build the nested subdirectory with path.join(cwd, 'a', 'b', ...) segment arguments instead of a 'a/b/c/d/e/f/g/h/i' path string for cross-platform compatibility.", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim...
null
yarnpkg__yarn__4278
yarnpkg/yarn
4,278
defect
b9e15c96262d7700237a0be7370fd3f89a50bc78
6448d3ca318915a846cc1f70dd94551bea2f3a67
Fix 4263: Make upgrade and upgrade-interactive compatible with workspaces
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. --> **Summary** Fix for https://github.com/yarnpkg/yarn/issues/4263 <!-- Is the feature a substantial feature request? Please use https://github.com/yarnpkg/...
diff --git a/__tests__/commands/upgrade.js b/__tests__/commands/upgrade.js index 8e38e89134..16b3bf10ed 100644 --- a/__tests__/commands/upgrade.js +++ b/__tests__/commands/upgrade.js @@ -104,6 +104,14 @@ test.concurrent('upgrades from fixed version to latest', (): Promise<void> => { }); }); +test.concurrent('upgr...
6
1
0
[{"id": "G0", "claim": "The added `!this.ignoreWorkspaces` condition may break running `yarn install` at the root of the workspace: the workspaces' dependencies would no longer be installed and their own dependencies would not have the same layout as with workspace-aware hoisting.", "category": "correctness", "verdict"...
null
yarnpkg__yarn__4377
yarnpkg/yarn
4,377
defect
b33fe264db334f90a821e919c16c079cc5d52ce2
f0b949b14a01ed03cfdf59431aba51d37163cfdf
feat(config): Add custom config for init private flag
**Summary** Here is a small custom; I add this because it relates to https://yarnpkg.com/en/docs/cli/init#toc-setting-defaults-for-yarn-init. I discovered this was necessary while writing introduces for this flag. **Test plan** New init and config tests.
diff --git a/src/cli/commands/init.js b/src/cli/commands/init.js index a34055fc0b..78a61de447 100644 --- a/src/cli/commands/init.js +++ b/src/cli/commands/init.js @@ -31,6 +31,8 @@ export async function run(config: Config, reporter: Reporter, flags: Object, arg email: config.getOption('init-author-email'), ur...
5
3
1
[{"id": "G0", "claim": "The added two-step String-cast handling of the `init-private` default is over-complicated and less accurate; a simpler form such as `config.getOption('init-private') || ''` should be used instead of casting to a string and comparing against 'undefined'.", "category": "maintainability", "verdict"...
null
yarnpkg__yarn__4464
yarnpkg/yarn
4,464
defect
6fdbb39a43387fcbdafc364d698c752696795668
275b1031723e73370baf67013bd0c82ab2d082f6
fix(init): prevent init command from traversing up
**Summary** Fixes #4441. **Test plan** Added new test case.
diff --git a/src/cli/index.js b/src/cli/index.js index 2c5cb74ffc..af9c143d36 100644 --- a/src/cli/index.js +++ b/src/cli/index.js @@ -443,7 +443,8 @@ export function main({ return errorReportLoc; } - const cwd = findProjectRoot(commander.cwd); + const shouldUseProjectRoot = commandName !== 'init'; + const...
2
2
2
[{"id": "G0", "claim": "Instead of hardcoding a command-name check in main(), store the decision as a shouldRunInCurrentCwd property on the init command class and compute the cwd as command.shouldRunInCurrentCwd ? commander.cwd : findProjectRoot(commander.cwd).", "category": "design", "verdict": "supported", "priority"...
null
yarnpkg__yarn__4471
yarnpkg/yarn
4,471
defect
6fdbb39a43387fcbdafc364d698c752696795668
6d5cb2fd8c41f103b7cf57bca5a95d36135b953e
Support save-exact true
**Summary** Fixes #4343. Currently there is no way to remove the package prefix inside `.yarnrc` file, this PR add support for `save-exact` in `.yarnrc` as discussed in #4343. Full credit goes to @jambonrose ``` save-exact true ``` One small thing, should `yarn` be backwards compatible with the old behavior ...
diff --git a/src/cli/commands/add.js b/src/cli/commands/add.js index 68f82e323b..cb0175f0c4 100644 --- a/src/cli/commands/add.js +++ b/src/cli/commands/add.js @@ -83,7 +83,7 @@ export class Add extends Install { let prefix; if (tilde) { prefix = '~'; - } else if (exact) { + } else if (e...
2
2
1
[{"id": "G0", "claim": "The exact-versus-prefix logic should be hoisted above as `const exact = this.flags.exact || Boolean(this.config.getOption('save-exact')); const tilde = this.flags.tilde;` so that save-exact takes precedence over save-prefix.", "category": "design", "verdict": "supported", "priority": "P2", "scop...
null
yarnpkg__yarn__4478
yarnpkg/yarn
4,478
defect
8b665e32a3cce6f8c1ce9e355fefa317cf205081
a1ab4b3e2c3964aec5db262ee195230ed29c72db
Fix: Resolve peerDependencies from all higher levels, not just root
**Summary** Fixes #4446, fixes #4433, fixes #2688, fixes #2387. Follow up to #3803. The fix in #3893 was too aggressive, allowing only top-level dependencies to be used in peer dependency resolution which was incorrect. This patch allows resolving peer dependencies from the same or higher levels in the dependenc...
diff --git a/package.json b/package.json index 6a11197696..4fdf9b37f0 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,7 @@ "request": "^2.81.0", "request-capture-har": "^1.2.2", "rimraf": "^2.5.0", - "semver": "^5.1.0", + "semver": "^5.4.1", "strip-bom": "^3.0.0", "tar-fs": "^1....
2
2
1
[{"id": "G0", "claim": "The semver devDependency bump from ^5.1.0 to ^5.4.1 is not required, so the author offers to revert it.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Peer dependency resolution should not just take the first match with f...
null
yarnpkg__yarn__4484
yarnpkg/yarn
4,484
defect
96c215c1ce5944a6fe993ab0d9b13e6edfe65675
16d504a84d2cb6828f14097ad3bbba4da526611c
fix(resolver): `parentNames` is missing in package warning breadcrumbs
**Summary** Bugfix for #4480. Change suggested by @BYK **Test plan** Running yarn on local. _**Before Changes**_ ```bash warning node-uuid@1.4.8: Use uuid module instead ``` _**After Changes**_ ```bash warning raven > node-uuid@1.4.8: Use uuid module instead ```
diff --git a/src/package-request.js b/src/package-request.js index 4f807c772c..41f2d09022 100644 --- a/src/package-request.js +++ b/src/package-request.js @@ -28,7 +28,7 @@ type ResolverRegistryNames = $Keys<typeof registryResolvers>; export default class PackageRequest { constructor(req: DependencyRequestPattern, ...
1
1
1
[{"id": "G0", "claim": "Tests need to be added so the new parentNames propagation cannot be broken again.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
yarnpkg__yarn__4488
yarnpkg/yarn
4,488
defect
0e16ee9a3edf0bf9381458eba6ac9f12047f51d2
f584536d0493ae4f23d93bad068d2843f25057c3
Fix: 'yarn --flat' unbound transitive deps shouldn't conflict with top level deps
**Summary** Fixes #3780, and makes the failing test from #3779 passing. As a final step of package resolution, for each dependency we check whether any version satisfies all resolved version ranges. **Test plan** Fixes an existing (failing) test: "unbound transitive dependencies should not conflict with to...
diff --git a/__tests__/commands/install/integration.js b/__tests__/commands/install/integration.js index 02f936afca..c3206e893d 100644 --- a/__tests__/commands/install/integration.js +++ b/__tests__/commands/install/integration.js @@ -1049,8 +1049,7 @@ test.concurrent('transitive file: dependencies should work', (): Pr...
6
5
2
[{"id": "G0", "claim": "The lockfile-entry guard should exclude only the locked patterns and still optimize the rest instead of returning early whenever any pattern is locked.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The new code should reuse ...
null
yarnpkg__yarn__4848
yarnpkg/yarn
4,848
defect
002ce4ad707622e28d2287d5d6ac92a3934ab22c
d25cb1e2da2b5e62e4251991f1745bf519eb6090
feat(run): Include the workspace root .bin in env path
**Summary** Partial resolution for #4543. Previously, when running `yarn run` the env PATH would be set to look in node_modules/.bin, however, in workspaces the root workspace .bin path was not being included. This PR adds the workspace root node_modules/.bin path after the individual package's path. This ...
diff --git a/src/util/execute-lifecycle-script.js b/src/util/execute-lifecycle-script.js index 2e44d6e9ad..b89d002355 100644 --- a/src/util/execute-lifecycle-script.js +++ b/src/util/execute-lifecycle-script.js @@ -148,6 +148,9 @@ export async function makeEnv( // add .bin folders to PATH for (const registry of O...
1
1
1
[{"id": "G0", "claim": "The pull request should include at least one test for the change before it is merged.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
yarnpkg__yarn__4866
yarnpkg/yarn
4,866
defect
c5e2dc59fe0d7eb328c49c3f98d741cace40e6b9
57288307cb1a975654d173df8c7f85b7ecf7f60e
test(util): Add tests for boolify() and boolifyWithDefault()
**Summary** This adds tests for `boolify()` and `boolifyWithDefault()`. It also fixes a bug in `boolify()` discovered in the process: the number `0` should evaluate to `false`, not `true`. The functions are moved from cli/index.js to util/conversion.js since they can be generally useful. **Test plan** Addi...
diff --git a/__tests__/util/conversion.js b/__tests__/util/conversion.js new file mode 100644 index 0000000000..dab2c9b04a --- /dev/null +++ b/__tests__/util/conversion.js @@ -0,0 +1,43 @@ +/* @flow */ + +import {boolify, boolifyWithDefault} from '../../src/util/conversion.js'; + +describe('boolify', () => { + test('s...
4
4
0
[{"id": "G0", "claim": "The 'should be consistent with boolify()' test should mock boolify and assert it is being called instead of generating expectations by calling it directly.", "category": "testing", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The falsy string literals ...
null
yarnpkg__yarn__4883
yarnpkg/yarn
4,883
defect
2a7b19067dcfa818fee026e5f1fbe1871767a203
1aba6be48f541e14306b44b780916012e28290ab
feat(workspaces): Adds a `workspaces` command
**Summary** Adds a command name `workspaces` that display useful data about the workspaces layout. Can be used for debugging, or for integrating other tools on top of Yarn itself. Currently only expose the two following information, but can be easily expanded if we need to add more fields: - Workspace name - Wor...
diff --git a/__tests__/commands/workspaces.js b/__tests__/commands/workspaces.js new file mode 100644 index 0000000000..fc26b371bb --- /dev/null +++ b/__tests__/commands/workspaces.js @@ -0,0 +1,44 @@ +// @flow + +import {BufferReporter} from '../../src/reporters/index.js'; +import {run as workspace} from '../../src/cl...
9
4
1
[{"id": "G0", "claim": "Assigning `path.resolve(fixturesLoc)` to a variable would make the test expectation easier to read.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The test helper should rethrow the error or drop the try/catch block inste...
null
yarnpkg__yarn__4989
yarnpkg/yarn
4,989
defect
ddf2f9ade211195372236c2f39a75b00fa18d4de
7d14aea40a5862e03f0337c5ea325d1a61215354
Fix for issue #2840
**Summary** This is a fix for issue #2840 . It fixes the issue by comparing the name of the git repo with the entries on the lockfile, instead of comparing the whole git url (which wouldn't match with the version already on the lockfile, since the url would be different). **Test plan** We tested with multip...
diff --git a/__tests__/commands/add.js b/__tests__/commands/add.js index e3c89d8594..c98ae5837f 100644 --- a/__tests__/commands/add.js +++ b/__tests__/commands/add.js @@ -609,6 +609,27 @@ test.concurrent('upgrade scenario 2 (with sub dependencies)', (): Promise<void> }); }); +test.concurrent('install another fork...
3
3
1
[{"id": "G0", "claim": "Add a test case covering the fix for issue #2840 before merging.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Use the guessName util (excludeNames.push(guessName(pattern))) instead of git-specific parsing in install.js, so othe...
null
yarnpkg__yarn__5016
yarnpkg/yarn
5,016
defect
ddf2f9ade211195372236c2f39a75b00fa18d4de
cb40d6aaaa99438853f3841597aa4a9075027189
Fix transient symlinks overriding direct ones v2
**Summary** This PR is a replacement for #5012 with a different fix. fixes #4937 Added a sort to the top level bin links to ensure that direct dependencies are linked last. Since bin links are overwritten if they already exist, this will ensure that direct deps bin links will overwrite transitive ones. **Te...
diff --git a/__tests__/commands/install/bin-links.js b/__tests__/commands/install/bin-links.js index 3e78a5c4ab..59208a058d 100644 --- a/__tests__/commands/install/bin-links.js +++ b/__tests__/commands/install/bin-links.js @@ -145,6 +145,17 @@ test('first dep is installed when same level and reference count and one is ...
1
1
0
[{"id": "G0", "claim": "Splitting the array instead of doing a full sort would give better algorithmic complexity.", "category": "performance", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
yarnpkg__yarn__5026
yarnpkg/yarn
5,026
defect
ddf2f9ade211195372236c2f39a75b00fa18d4de
6e538c8fa09f791847febc8cf0533f088f917517
feat(resolution) Local .git repositories are now locally cloned
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. --> **Summary** This fixes #3670. Verifies that the url parser returns a `file:` url, and stops using the added `file://` prefix when invoking git commands. ...
diff --git a/src/util/git.js b/src/util/git.js index b9ccc68422..dfaf3e5ebe 100644 --- a/src/util/git.js +++ b/src/util/git.js @@ -20,6 +20,7 @@ import map from './map.js'; const GIT_PROTOCOL_PREFIX = 'git+'; const SSH_PROTOCOL = 'ssh:'; const SCP_PATH_PREFIX = '/:'; +const FILE_PROTOCOL = 'file:'; type GitUrl = ...
7
5
3
[{"id": "G0", "claim": "The fallback return in npmUrlToGitUrl can now use the FILE_PROTOCOL constant instead of the 'file:' string literal.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The new file:-protocol early return duplicates the return ...
null
yarnpkg__yarn__5216
yarnpkg/yarn
5,216
defect
fb6511c96057d999420a0c4b4e5e6efbe3f99932
6a4b0d4b56b61affb50b9eda486dc05e237a92e8
fix(auth): Fixes authentication conditions and logic with registries
### Summary Supersedes #5162 (for now). Fixes #4157, #4451, #4672, #4119. This PR brings 2 changes. **Fix for private npm packages** Fixes unauthed requests to yarnpk.com by treating yarnpkg.com as requests to npmjs.org in `isRequestToRegistry`. **Feature - simpler support for multipath registries** B...
diff --git a/__tests__/registries/npm-registry.js b/__tests__/registries/npm-registry.js index 6fa85aac66..ce0f97e464 100644 --- a/__tests__/registries/npm-registry.js +++ b/__tests__/registries/npm-registry.js @@ -72,138 +72,504 @@ function createMocks(): Object { } describe('request', () => { - test('should call...
3
2
1
[{"id": "G0", "claim": "The inline requestToRegistryHost/requestToYarn closure functions in isRequestToRegistry may be unnecessary and should be checked and simplified for readability.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "requestNeedsA...
null
yarnpkg__yarn__5227
yarnpkg/yarn
5,227
defect
543f649d355bb5b3b0b56e1c73c6e3ca93a299c8
b8a932090227b7cad305d423d536d10415826f73
feat(upgrade, add): Separately log added/upgraded dependencies
Implementation of feature https://github.com/yarnpkg/rfcs/blob/master/accepted/0000-show-updated-packages-only.md When adding or upgrading dependencies, group them into directly required ones vs. transitive ones so that version shown is clearer to the end user. https://github.com/yarnpkg/rfcs/blob/master/accep...
diff --git a/__tests__/__snapshots__/integration.js.snap b/__tests__/__snapshots__/integration.js.snap index 88b894d032..54b355d641 100644 --- a/__tests__/__snapshots__/integration.js.snap +++ b/__tests__/__snapshots__/integration.js.snap @@ -8,5 +8,8 @@ exports[`yarnrc-args 1`] = ` {\\"type\\":\\"step\\",\\"data\\":{...
2
2
1
[{"id": "G0", "claim": "Converting this test to a snapshot would be easier than maintaining this index-of-line-of-output approach.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The two reporter.tree() calls should use different keys; change this one to...
null
yarnpkg__yarn__5290
yarnpkg/yarn
5,290
defect
543f649d355bb5b3b0b56e1c73c6e3ca93a299c8
c0b644ed9d71c208493d75f8e808da49aa97d6a1
feat(publish): Publish command uses publishConfig.access in package.json
fixes #5279 **Summary** For npm compatibility, `yarn publish` should check `publishConfig.access` in package.json and use it as if the `--access` option was passed. If `--access` is also passed, then the command line parameter takes precedence. **Test plan** Added unit tests regarding "access" in `__test...
diff --git a/__tests__/__mocks__/npm-registry.js b/__tests__/__mocks__/npm-registry.js new file mode 100644 index 0000000000..c5f54cb2a7 --- /dev/null +++ b/__tests__/__mocks__/npm-registry.js @@ -0,0 +1,10 @@ +/* @flow */ + +import Registry from '../../src/registries/base-registry.js'; +import type {RegistryRequestOpt...
1
1
0
[{"id": "G0", "claim": "In the publish command tests, use jest's `toBeCalledWith` matcher instead of reaching into the mock objects via `config.registries.npm.request.mock.calls`.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
yarnpkg__yarn__5293
yarnpkg/yarn
5,293
defect
d68b6c96d161ad58833f7751668bfee25a3d4252
5946fe9224acc171a48dbf9e9b9523185bc8bf0d
feat(install): Implement a very basic hook system
**Disclaimer:** This is NOT a public feature, we reserve the right to change it as we wish, including between patch releases. --- This PR adds a very basic and undocumented hook system. I plan to use it internally to get better stats on how Yarn performs, and how much time is spent on the linking step. **Test...
diff --git a/src/cli/commands/install.js b/src/cli/commands/install.js index 118b739845..f24d57676e 100644 --- a/src/cli/commands/install.js +++ b/src/cli/commands/install.js @@ -7,6 +7,7 @@ import type {Manifest, DependencyRequestPatterns} from '../../types.js'; import type Config from '../../config.js'; import type...
6
3
1
[{"id": "G0", "claim": "The exported hook helper `callThroughHook` should be renamed to `triggerHook` or `callHook`.", "category": "maintainability", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Hook names should be typed with an enum or `Symbol`s rather than free-form strings....
null
yarnpkg__yarn__5322
yarnpkg/yarn
5,322
defect
7fcf4dd4d95cdfa8856cea8a5daa29d48eb2d70b
6e5a3b562bc989b4a9a2d5f360d3e91a13137c7a
feat(auth): Add basic auth support for pathed registries
**Summary** Builds on top of https://github.com/yarnpkg/yarn/pull/5216. Adds support for using Basic auth like so: ``` @scope:registry=https://artifactory.example.com/api/npm/registry/ //artifactory.example.com/api/npm/registry/:username=uuuu //artifactory.example.com/api/npm/registry/:_password=pppp //art...
diff --git a/__tests__/registries/npm-registry.js b/__tests__/registries/npm-registry.js index ce0f97e464..739b078054 100644 --- a/__tests__/registries/npm-registry.js +++ b/__tests__/registries/npm-registry.js @@ -6,6 +6,11 @@ import NpmRegistry from '../../src/registries/npm-registry.js'; import {BufferReporter} fro...
2
2
0
[{"id": "G0", "claim": "The two new Buffer constructor calls in the test helper should use Buffer.from instead, because the Buffer constructor is deprecated.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "An entry for this change should be added...
null
yarnpkg__yarn__5336
yarnpkg/yarn
5,336
defect
18bed13c654a8ca39d68a9cb808df05acadbbacd
4d1aeda573773a0fb55b73de9babe28a03c191f2
RFC: feat(config): Use more conventional paths for config and data
This implements: * Supporting user-defined environment variables adhering to the [XDG Specification](https://specifications.freedesktop.org/basedir-spec/basedir-spec-0.6.html) to override yarn's defaults * Supporting equivalent environment variables on Windows such as %LOCALAPPDATA% * More conventional defaults for th...
diff --git a/__tests__/util/user-dirs.js b/__tests__/util/user-dirs.js new file mode 100644 index 0000000000..41fa7909b3 --- /dev/null +++ b/__tests__/util/user-dirs.js @@ -0,0 +1,132 @@ +/* @flow */ + +import {getDataDir, getCacheDir, getConfigDir} from '../../src/util/user-dirs'; +import userHome from '../../src/util...
2
1
1
[{"id": "G0", "claim": "Changing the default data/global directory from ~/.config/yarn/global to ~/.local/share/yarn/global would disrupt users' existing setups and may cause confusion; keep the old paths unless there is a stronger reason to migrate.", "category": "design", "verdict": "supported", "priority": "P1", "sc...
null
yarnpkg__yarn__5606
yarnpkg/yarn
5,606
defect
66a0143a753cd4ade1a0fffee2174890d564c129
78566eb0e1fb7cb6957c6a3826a2bd9d9b9cff64
fix(upgrade): No longer warn when upgrading a devDependency
fixes #4840 **Summary** Previously the upgrade command would call add with the list of packages to upgrade to. No "--dev" flag would be carried over and this list would contain all dependencies. As a result, Add would report a warning `{package} is already in "devDependencies". Please remove existing entry f...
diff --git a/__tests__/commands/upgrade-interactive.js b/__tests__/commands/upgrade-interactive.js index c1525333eb..e13c8b4dbb 100644 --- a/__tests__/commands/upgrade-interactive.js +++ b/__tests__/commands/upgrade-interactive.js @@ -11,6 +11,7 @@ const path = require('path'); const fixturesLoc = path.join(__dirnam...
1
1
0
[{"id": "G0", "claim": "Move the list of command names that silence dependency-type warnings into a named constant array at the top of the file (e.g. SILENCE_DEPENDENCY_TYPE_WARNINGS) instead of storing the computed boolean on the class instance, and check membership with array.indexOf() === -1 in the if condition.", "...
null
yarnpkg__yarn__5640
yarnpkg/yarn
5,640
defect
077313467855c5a913f96c36cd2070878917c0ad
d388277e09af2df1a9b3b9e559924b414638b898
feat(version): Ability to disable commit hooks on versioning
**Summary** Last year I contributed the ability to disable commit hooks when versioning with npm (See [this commit](https://github.com/npm/npm/commit/2dec601c6d5a576751d50efbcf76eaef4deff31e#diff-2992be03e25e9f38300b7ce175e4f4e1)). It makes sense to add the same functionality to yarn. The original motivation for ...
diff --git a/src/cli/commands/version.js b/src/cli/commands/version.js index fb8d2537b3..8f0e2c8555 100644 --- a/src/cli/commands/version.js +++ b/src/cli/commands/version.js @@ -23,6 +23,7 @@ export function setFlags(commander: Object) { commander.option(NEW_VERSION_FLAG, 'new version'); commander.option('--mess...
5
4
1
[{"id": "G0", "claim": "Abstracting the commit-args construction into buildCommitArgs adds little value unless the helper is also used in a unit test.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Allowing an empty args value in buildCommitArgs...
null
yarnpkg__yarn__5681
yarnpkg/yarn
5,681
defect
8a7ee772c1b2bec108597567dd8e754abb34778e
88fa307cd716f112e5d09188acf0d87b0e6b1196
fix(resolution): Prevent duplicate patterns in PackageResolver patternsByPackage array
**Summary** Fixes #5676. Previously duplicate patterns would be inserted into this array, causing unnecessary looping and manifest reading of the same patterns. It also caused a bug when duplicate patterns were marked as peerDeps. We now prevent these duplicate entries. **Test plan** Added test to `package-re...
diff --git a/__tests__/package-resolver.js b/__tests__/package-resolver.js index 3444226cc8..836b824384 100644 --- a/__tests__/package-resolver.js +++ b/__tests__/package-resolver.js @@ -16,25 +16,34 @@ const path = require('path'); // regexp which verifies that cache path contains semver + hash const cachePathRe = /...
2
1
0
[{"id": "G0", "claim": "Prefer object spread notation over Object.assign when building the config object in the test helper createEnv (nit).", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "A Set would be more efficient than the array plus indexOf...
null
yarnpkg__yarn__5687
yarnpkg/yarn
5,687
defect
2f1ad7f4277c147834a1e3c7160ca9d16ac00fae
2c16fe881acdc1b3c95053a71aefc6dfd852474d
test: Fix failing tests on master
**Summary** We had an integration test relying on a specific version of a package without coding that version into the test. We also had some tests using snapshots with `test.concurrent` which are not safe to use per https://github.com/facebook/jest/issues/1630#issue-175391968. These were randomly failing, mostl...
diff --git a/__tests__/index.js b/__tests__/index.js index 7d71a8cb11..d2b46703e6 100644 --- a/__tests__/index.js +++ b/__tests__/index.js @@ -106,22 +106,22 @@ test('should add package', async () => { }); test('should add package with no-lockfile option', async () => { - const stdout = await execCommand('add', ['...
1
1
0
[{"id": "G0", "claim": "The pull request's CI tests do not pass (they failed, contrary to the reviewer's initial assumption that they would pass).", "category": "testing", "verdict": "supported", "priority": "P0", "scope": "pre_existing"}]
null
yarnpkg__yarn__5712
yarnpkg/yarn
5,712
defect
9e97f50aea60f58042403ff503d757a732756d6a
a83cfd7bea28e76f730318e4f701b04ae0ea9905
fix(publish): Run pre and postpack lifecycle scripts on publish
**Summary** npm runs the pre and post pack scripts on publish, but yarn was not. Added these scripts. fixes #5707 **Test plan** Added a test that regex's the output to look for scripts being run. If you look at the test, the regex is kinda weird, but I did it that way to make sure the log statements were i...
diff --git a/__tests__/commands/publish.js b/__tests__/commands/publish.js index aaee892112..789eb5ab21 100644 --- a/__tests__/commands/publish.js +++ b/__tests__/commands/publish.js @@ -99,3 +99,22 @@ test.concurrent('publish should allow `--access` to override publishConfig.acces ); }); }); + +test.concurren...
2
1
0
[{"id": "G0", "claim": "The pack lifecycle scripts (prepack/postpack) should be executed by the pack command rather than in publish.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The explanation of why the pack lifecycles run in publish should be record...
null
yarnpkg__yarn__5722
yarnpkg/yarn
5,722
defect
cbc6c8857cd74b658068c8ebec38d142dc3e6a7c
9223e9ee80ffbc240f2e136a303f2b716bd76587
fix(console-reporter): Fix issue where tree logger was ignoring --silent/-s flag
**Summary** This PR fixes #5721 where `upgrade` was not being silent when the `--silent`/`-s` flags were provided. It still printed the tree. 🖨🌳 **Test plan** Added two new test cases. Manual CLI tests: Before: ``` > yarn-local upgrade --silent └─ left-pad@1.3.0 └─ left-pad@1.3.0 ``` After: ...
diff --git a/src/reporters/console/console-reporter.js b/src/reporters/console/console-reporter.js index 6b2123da4d..ab4596bb46 100644 --- a/src/reporters/console/console-reporter.js +++ b/src/reporters/console/console-reporter.js @@ -232,6 +232,9 @@ export default class ConsoleReporter extends BaseReporter { tree(k...
1
1
1
[{"id": "G0", "claim": "Add tests covering the isSilent fix to __tests__/reporters/console-reporter.js before the pull request is merged.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
yarnpkg__yarn__5751
yarnpkg/yarn
5,751
defect
eee5bee556670ea2e99b038643f96694965af804
cb40a10de3f9f65c6b97a90d280e7518fb37f432
Remove logic to skip updating of existing symlinks
**Summary** This removes the current logic which skips the updating of existing symlinks. Fixes #4941 The PR supersedes #5065 by adding tests. **Test plan** Added an automated test which updates the 'dodgem' package for which this bug was originally reported and checks whether the symlink is updated. The...
diff --git a/__tests__/commands/global.js b/__tests__/commands/global.js index b018931c4c..9056755963 100644 --- a/__tests__/commands/global.js +++ b/__tests__/commands/global.js @@ -149,3 +149,19 @@ test.concurrent('upgrade', async (): Promise<void> => { ); }); }); + +test.concurrent('symlink update', async (...
1
1
1
[{"id": "G0", "claim": "The pull request's tests fail in CI (though they pass locally on macOS and Ubuntu) and BYK asks that they be made to pass on all platforms, suggesting committing the generated request-cache files or switching to a dependency without transitive dependencies.", "category": "testing", "verdict": "s...
null
yarnpkg__yarn__5893
yarnpkg/yarn
5,893
defect
ec7e671f2b13944579aec000ae55b0cbd510ebee
e5c54b6ebd7466c5a00f78ea7eab8aa85770565e
fix #5881: allow folder name of focused workspace to not match package name
**Summary** fix #5881. Previously, the focused workspace logic determined the target workspace name by looking at the folder it was contained in. This was a mistake and it should have looked at the package.json name field. I also moved the focus property to the config object rather than just as a flag for the insta...
diff --git a/__tests__/commands/_helpers.js b/__tests__/commands/_helpers.js index b26eb8a114..3a2da9203c 100644 --- a/__tests__/commands/_helpers.js +++ b/__tests__/commands/_helpers.js @@ -91,6 +91,7 @@ export function makeConfigFromDirectory(cwd: string, reporter: Reporter, flags: prefix: flags.prefix, ...
4
1
0
[{"id": "G0", "claim": "The comment '// --no-lockfile or --pure-lockfile or --frozen-lockfile or --focus flag' in install.js was left in from a previous commit and is no longer true.", "category": "documentation", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The getFlatHoiste...
null
yarnpkg__yarn__5966
yarnpkg/yarn
5,966
defect
ed76c6a8979983049dce409b735a051091fe61b7
9479172ddff95fc37cb34dc037c4dfe1de8ff198
Allow bundleDependencies to be respected during `pack`
**Summary** Yarn pack does not include bundleDependencies during `yarn pack`. This was due to 3 issues: 1. The normalized property is `bundleDependencies` and not `bundledDependencies`. This was causing the destructuring to always be undefined even if bundledDependencies or bundleDependencies were set in package....
diff --git a/__tests__/commands/pack.js b/__tests__/commands/pack.js index caff3b438e..cd825c67b8 100644 --- a/__tests__/commands/pack.js +++ b/__tests__/commands/pack.js @@ -160,8 +160,7 @@ test.concurrent('pack should exclude all files in dot-directories if not in file }); }); -// Broken: https://github.com/yar...
2
2
2
[{"id": "G0", "claim": "Pack-related tests appear to fail with this change.", "category": "testing", "verdict": "supported", "priority": "P0", "scope": "unclear"}, {"id": "G1", "claim": "The pull request should avoid depending on the little-used hash-for-dep package for depsFor if walking the node_modules tree with yar...
null
yarnpkg__yarn__6239
yarnpkg/yarn
6,239
defect
003b6b7d5d41afc94dbc1d9ae9755cb44bdf2848
5512472fd3755133de41646d51884f229b753359
fix(cli-create): fix scoped creation
This one works as it should: yarn create @scope/name => @scope/create-name There were problems when name was omitted: Before: yarn create @scope => create- yarn create @scope/ => @scope/create- After: yarn create @scope => @scope/create yarn create @scope/ => @scope/create Fixes #6233 **Summary** ...
diff --git a/src/cli/commands/create.js b/src/cli/commands/create.js index 0f998965fa..fb9926b3eb 100644 --- a/src/cli/commands/create.js +++ b/src/cli/commands/create.js @@ -16,6 +16,42 @@ export function hasWrapper(commander: Object, args: Array<string>): boolean { return true; } +const coerceName = (name = '')...
3
2
2
[{"id": "G0", "claim": "The parseBuilderName test expectations written as a code comment should be moved into a real test file __tests__/commands/create.js by exporting the symbol, so they are actually run; otherwise the comment should just be removed since it will never be run.", "category": "testing", "verdict": "sup...
null
yarnpkg__yarn__6244
yarnpkg/yarn
6,244
defect
7eba4959449413b72d47e2e0c202d8858861640f
ab92bcf0981b00e5469413855cb62ddfe851357b
Added ability to run script on all workspaces
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. --> **Summary** Added the ability to run a script on every workspace in a project. `yarn workspaces run script` Motivation was to be able to run build or...
diff --git a/__tests__/commands/workspaces.js b/__tests__/commands/workspaces.js index 3b8254dc2a..ad81f2df76 100644 --- a/__tests__/commands/workspaces.js +++ b/__tests__/commands/workspaces.js @@ -1,12 +1,17 @@ // @flow +jest.mock('../../src/util/child'); import {BufferReporter} from '../../src/reporters/index.js...
5
2
1
[{"id": "G0", "claim": "Options passed to `yarn workspaces run` (e.g. `--all`) may be swallowed by yarn's CLI parsing instead of reaching the child processes, and the author should check whether the existing mechanism in src/cli/index.js for avoiding this can be applied here.", "category": "correctness", "verdict": "un...
null
yarnpkg__yarn__6255
yarnpkg/yarn
6,255
defect
7eba4959449413b72d47e2e0c202d8858861640f
9c37edcb4242888e769ce79c43cd8a8aebb3f7eb
Adds an auto-add-integrity option
**Summary** This PR gives a way to disable the behavior that makes Yarn automatically add the integrity in the package.json if it is missing. This helps large codebases to adapt (they won't be blocked until the change can be done). Note that this PR doesn't obsolete #6248 - I'll have to rebase one of them, but th...
diff --git a/__tests__/commands/install/integration.js b/__tests__/commands/install/integration.js index 1e7aa082d1..1155b03fd5 100644 --- a/__tests__/commands/install/integration.js +++ b/__tests__/commands/install/integration.js @@ -738,6 +738,15 @@ test('install should create integrity field if not present', () => ...
2
1
0
[{"id": "G0", "claim": "A deprecation warning of some sort should be added, otherwise the project may have to forever support non-integrity lockfiles.", "category": "design", "verdict": "opposed", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The config option should be renamed to something that flag...
null
yarnpkg__yarn__6515
yarnpkg/yarn
6,515
defect
9bb2cfbb35fc8623713ba15744ae9f283cfc81d4
88759f171a17ec1bed9c98517e9c876259fc656b
Fix: handle empty bin strings
<!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. --> **Summary** This is a followup PR for #6512. It prevents yarn from creating a link to a dependency's root directory within the `.bin/` directory if ...
diff --git a/__tests__/__snapshots__/normalize-manifest.js.snap b/__tests__/__snapshots__/normalize-manifest.js.snap index 6485c0b6fa..c5a78707da 100644 --- a/__tests__/__snapshots__/normalize-manifest.js.snap +++ b/__tests__/__snapshots__/normalize-manifest.js.snap @@ -90,6 +90,12 @@ Array [ ] `; +exports[`empty b...
2
2
1
[{"id": "G0", "claim": "The pull request should add an entry to CHANGELOG.md describing this change.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "A test should be added to __tests__/commands/install/bin-links.js that tests the actual existence o...
null
yarnpkg__yarn__6671
yarnpkg/yarn
6,671
defect
f8e42c563f7c10adb5f53afc59104f541e145176
bf63d746801b4a12d5196b014a0906994a3d78ed
Implements optional peer dependencies
**Summary** This PR implements https://github.com/yarnpkg/rfcs/pull/105 (Optional Peer Dependencies). It uses a new `peerDependenciesMeta` field to specify which peer dependency warnings can be safely ignored. **Test plan** Added tests.
diff --git a/__tests__/commands/install/integration.js b/__tests__/commands/install/integration.js index cad6455f0e..116f59c4c4 100644 --- a/__tests__/commands/install/integration.js +++ b/__tests__/commands/install/integration.js @@ -1123,3 +1123,19 @@ test('install will not warn for missing peerDep when both shallowe...
2
2
1
[{"id": "G0", "claim": "The `optional:*` peer-dependency range syntax will break downstream consumers and people using older versions of yarn or any version of npm, so the approach should be reconsidered.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "It...
null
yarnpkg__yarn__6926
yarnpkg/yarn
6,926
defect
fb03788279278084e81aac9cde40151a3134761b
977e65e1c453e4288a08f6216fcbc5ba44d2fdea
fix(run): Preserve none zero exit code
resolve #6925 **Summary** `index.js` ```js const process = require('process'); process.exit(78) ``` `npm start` will yield 78, but `yarn start` will yield 1. <img width="1031" alt="screen shot 2019-01-15 at 8 44 31 pm" src="https://user-images.githubusercontent.com/1057756/51181533-61a1c280-1906-11e9-9c...
diff --git a/__tests__/fixtures/index/preserve-exit-code/exitWithCode78.js b/__tests__/fixtures/index/preserve-exit-code/exitWithCode78.js new file mode 100644 index 0000000000..4337f69e0e --- /dev/null +++ b/__tests__/fixtures/index/preserve-exit-code/exitWithCode78.js @@ -0,0 +1 @@ +process.exit(78); diff --git a/__t...
1
1
1
[{"id": "G0", "claim": "As of S1 the change only preserves the exit code for the direct path (`yarn node index.js`); `yarn start` (lifecycle scripts) still exits 1.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
yarnpkg__yarn__7070
yarnpkg/yarn
7,070
defect
ea81393292003e447b981b2fba36cb6804703b9a
8ea424ef3c97d8b9a0e0fd13588d078aaeec3a1b
fix: handle npm prefix config environment variables
Fixes #4682 <!-- Thanks for submitting a pull request! Please provide enough information so that others can review your pull request. The two fields below are mandatory. --> **Summary** <!-- Explain the **motivation** for making this change. What existing problem does the pull request solve? --> Passing `npm_...
diff --git a/CHANGELOG.md b/CHANGELOG.md index 052b960d0e..afc65b11fc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,10 @@ Please add one entry in this file for each change in Yarn's behavior. Use the sa ## Master +- Fix `npm_config_` environment variable parsing to support `_auth`, `_authToken`, `_userna...
1
1
0
[{"id": "G0", "claim": "The underscore-to-dash replacement in mergeEnv should be implemented in a more generic way that supports `__` (e.g. key.replace(/([^_])_/g, '$1-')) instead of hard-coding the four keys that keep their underscores.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introd...
null
yarnpkg__zpm__292
yarnpkg/zpm
292
defect
20354755c2febbd1a8b7a98c2738b8fc9dd43743
b16a65602266f0bd1005af5ddfe07b19d96b773b
Updates switch to dowload berry from npm
Closes #287
diff --git a/packages/zpm-switch/src/cache.rs b/packages/zpm-switch/src/cache.rs index e36ca2c5..d8eafe5d 100644 --- a/packages/zpm-switch/src/cache.rs +++ b/packages/zpm-switch/src/cache.rs @@ -2,13 +2,12 @@ use std::{future::Future, io::Write}; use serde::{Deserialize, Serialize}; use zpm_parsers::JsonDocument; -...
3
1
1
[{"id": "G0", "claim": "The new berry branch of to_npm_url builds its download URL from the wrong npm package — @yarnpkg/cli-bin should be @yarnpkg/cli-dist.", "category": "correctness", "verdict": "supported", "priority": "P0", "scope": "introduced"}, {"id": "G1", "claim": "The postinstall test changes (.profile → .ba...
null
yarpc__yarpc-go__1426
yarpc/yarpc-go
1,426
defect
8238cc8b0013654ddbfe802e2c48297dcd04332e
04b5dfaf0d23619bdf0ce6c3e7d33b10aca5c685
Add options to use raw headers in TChannel transport
Summary: TChannel headers are case-sensitive and downstream TChannel server could depend on some non-lowercase header keys. For proxying purpose, we should not change case of the header keys. In this diff, we provide an option in TChannel Transport. With it, the tchannel outbound will use the non canonicalized head...
diff --git a/api/transport/header.go b/api/transport/header.go index 4f953d93cf..c55594f103 100644 --- a/api/transport/header.go +++ b/api/transport/header.go @@ -38,6 +38,8 @@ func CanonicalizeHeaderKey(k string) string { type Headers struct { // This representation allows us to make zero-value valid items map[st...
13
12
4
[{"id": "G0", "claim": "Preserve the previous guarantee that the last equivalent header wins on collision, e.g. with a single map from canonical key to a struct of {raw key, value}, so equivalent headers overwrite each other.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"},...
null
yarpc__yarpc-go__1456
yarpc/yarpc-go
1,456
defect
400866dbf9c6ec32f3deaae890b625eba4602371
52507626b429effff0b66de8ed238d87b279b13a
Expose phased dispatcher start & stop
Today, the dispatcher exposes its lifecycle via all-in-one start and stop methods. This requires that users start and stop all transports, inbounds, and outbounds at the same time. In our internal Fx module, this makes it impossible to correctly order `OnStart` and `OnStop` hooks: ideally, the dispatcher would star...
diff --git a/CHANGELOG.md b/CHANGELOG.md index 0b10b8ead0..9623563721 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -12,6 +12,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. accept Thrift requests with or without envelopes. This feature was originally added in 1.26.0 and r...
6
3
1
[{"id": "G0", "claim": "The phased start/stop API should enforce exactly-one use, e.g. via an atomic swap on a flag so that a repeat PhasedStart/PhasedStop call returns an error.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "If an outbound doesn't suppo...
null
yarpc__yarpc-go__1505
yarpc/yarpc-go
1,505
defect
3a2c7753fa88bc6b5a0c30ded069b8994df4ad20
9ac7cc45348679036b92595a2d42e2103908e987
Expose capacity option for pending heap peer chooser
This change threads the existing `Capacity` option through such that it can be used with YARPC's configurator.
diff --git a/CHANGELOG.md b/CHANGELOG.md index 323900fbad..dd45b2844a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## [Unreleased] ### Added - Added `Outbounds()` on `Dispatcher` to provide access to the configured outbo...
4
2
0
[{"id": "G0", "claim": "The invalid-argument error should include the value of cfg.Capacity so the failure is diagnosable.", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The test's sentinel values (minus1, zero, twenty) should be constants rather th...
null
yarpc__yarpc-go__1506
yarpc/yarpc-go
1,506
defect
3a2c7753fa88bc6b5a0c30ded069b8994df4ad20
29ed0414f13136452be37c56d9fee663e41f5743
Expose capacity option for round-robin peer chooser
This change threads the existing `Capacity` option through such that it can be used with YARPC's configurator.
diff --git a/CHANGELOG.md b/CHANGELOG.md index 323900fbad..6acda0c6db 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,6 +7,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## [Unreleased] ### Added - Added `Outbounds()` on `Dispatcher` to provide access to the configured outbo...
4
3
1
[{"id": "G0", "claim": "Apply the same change the reviewer requested in their previous PR to the invalid-capacity error return in Spec()'s BuildPeerList (anchored at the \"Capacity must be greater than 0\" error).", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": ...
null
yarpc__yarpc-go__1520
yarpc/yarpc-go
1,520
defect
17c9ad0932d439bd0651d70dd5283da7bb4c8ab2
9b903c4148ab35fe804018bbf35d709198aaf444
Add transport headers to `transport.Request`
This adds additional fields to the `transport.Request` struct: - unique request ID for later request/response validation - host to determine which host server issued the request - environment to indicate the environment of the deployed service Relates to T1860945.
diff --git a/api/encoding/call.go b/api/encoding/call.go index 4ec9842d58..2e92928bea 100644 --- a/api/encoding/call.go +++ b/api/encoding/call.go @@ -59,6 +59,30 @@ func (c *Call) WriteResponseHeader(k, v string) error { return nil } +// ID returns the ID for the request. +func (c *Call) ID() string { + if c == n...
4
1
0
[{"id": "G0", "claim": "The ID field doc should not imply a uniqueness guarantee to the server; it should say the ID is chosen by the client and that the response ID must match the request ID.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Since t...
null
yarpc__yarpc-go__1559
yarpc/yarpc-go
1,559
defect
929082975f4e37f58de03e4de553d9f2627bba2d
bc2c6c332c29016b4752f389b9ffaea3b6add29e
Expose grpc/proto reflection information in generated code
This modifies the protoc plugin to expose grpc/proto reflection information to for compatible yarpc services through a new Fx group `yarpcfx`.
diff --git a/CHANGELOG.md b/CHANGELOG.md index 0794b2358c..49f0848848 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,11 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - Added `peer/tworandomchoices`, an implementation of the Two Random Choices load balancer algorithm....
10
9
2
[{"id": "G0", "claim": "The generated reflection field can use the existing `yarpcfx` group name instead of introducing a separate `yarpcprotoreflectionfx` group, since the types are different.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The CHANGELOG...
null
yarpc__yarpc-go__1561
yarpc/yarpc-go
1,561
defect
2ec6c2954f93dc2546bca094d754c2c6843e9b31
ccf533826c12df15799a4ab73a1d9efdba3eb2c3
Adding logging to tchannel handler error cases
Zap logging was added to understand when handler calls failed, when SendSystemError failed, and when responseWriter failed to close. To test these changes, I added a responseWriter interface factory to the struct of the handler so I could control reponseWriter during testing. A recorder interface was also added to ...
diff --git a/internal/observability/middleware_test.go b/internal/observability/middleware_test.go index 4f7aad2555..f76dd62a62 100644 --- a/internal/observability/middleware_test.go +++ b/internal/observability/middleware_test.go @@ -589,5 +589,4 @@ func TestMiddlewareFailureSnapshot(t *testing.T) { }, }, } -...
8
8
1
[{"id": "G0", "claim": "The nil-logger fallback that assigns t.logger inside the start() loop is an unnecessary, confusing side effect on invariant state (newChannelTransport already sets a nop logger) and should be removed.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id"...
null
yarpc__yarpc-go__1567
yarpc/yarpc-go
1,567
defect
7e4b0ffebcdb6ab40ee20e44e7fac62c80598666
ed2e423002c7977dee0bb130b62e67a94a131a2c
[spring] Update JSON encoding to match new Request/Response API
This follows from #1566. Now that the `Request`/`Response` API has changed to be more symmetric, this updates the JSON encoding to respect the new interfaces. This removes the `ResponseWriter` and introduces a preliminary `yarpc.Buffer`. Note: Build errors are expected as this is being merged into the feature ...
diff --git a/etc/bin/generate.sh b/etc/bin/generate.sh index 0e2c02595c..3e3dc42d8b 100755 --- a/etc/bin/generate.sh +++ b/etc/bin/generate.sh @@ -66,6 +66,7 @@ strip_thrift_warnings() { grep -v '^\[WARNING:.*emphasize the signedness' | sed '/^\s*$/d' } +# v1 mocks mockgen -destination=api/middleware/middlewaret...
3
2
0
[{"id": "G0", "claim": "The inbound Handle's TODO note should be recorded in the CHANGES document as a follow-up item: now that a Response struct is propagated back, the Response should hold the actual application error, and errors returned by the handler (not through the Response) could be considered fatal, affecting ...
null
yarpc__yarpc-go__1568
yarpc/yarpc-go
1,568
defect
57163f1e97e7bf5573c50329be0fc302e7b145ca
12a129e6d7e2a94392b8c36e54763b8b449fd74d
Adding connection failure detection for remotely closed peers
Intercepting low-level connection FIN packets received from remotely closed peers and disconnecting those peers.
diff --git a/CHANGELOG.md b/CHANGELOG.md index e4ef045c7c..56aee7d264 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,11 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic ...
1
1
0
[{"id": "G0", "claim": "The test-only option functions DialerCalled and CloserCalled should not be exported from production transport.go; APIs needed exclusively for testing belong in a transport_test.go file, and here they need not even be exported since they are used from within the same package.", "category": "desig...
null
yarpc__yarpc-go__1591
yarpc/yarpc-go
1,591
defect
6cde3969f7b6bc59a9ed633e8e3340e81f7da3a9
5364efb9d6d57207844c2bf09d01cf4a07d512e6
[spring/yarpcprotobuf] Add integration tests for generated streaming APIs
Now that the gRPC transport layer has been migrated to the v2 APIs, this adds integration tests for the generated streaming APIs in the new `protoc-gen-yarpc-go` plugin. This includes a test for each of the different gRPC handler types: unary, client-side streaming, server-side streaming, and bidirectional strea...
diff --git a/v2/yarpcprotobuf/protoc-gen-yarpc-go/integration_test.go b/v2/yarpcprotobuf/protoc-gen-yarpc-go/integration_test.go index 3e12656cb1..c6ace13078 100644 --- a/v2/yarpcprotobuf/protoc-gen-yarpc-go/integration_test.go +++ b/v2/yarpcprotobuf/protoc-gen-yarpc-go/integration_test.go @@ -22,6 +22,8 @@ package mai...
3
3
0
[{"id": "G0", "claim": "Use a listener on port 0 instead of a static port so tests don't collide, and thread the resulting address through the client constructors.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Rename startProcedures to startInbounds si...
null
yarpc__yarpc-go__1608
yarpc/yarpc-go
1,608
defect
880a1f8dac9d2582c0cc5e20351ee353ef87a3ca
965b085efc630c573cc5e62748e50cf6972a231f
Randomize insertion order for fewest-pending-heap
This ensures that peers are randomly inserted into the heap among equally scored peers, by randomly swapping 'last' with another peer on insertion. We've observed behaviour where batch deploys 'herd' towards a select few instances. The theory is that when the FPH degenerates to round-robin behaviour, batches of ...
diff --git a/peer/pendingheap/heap.go b/peer/pendingheap/heap.go index 271fbc4391..9e23266c93 100644 --- a/peer/pendingheap/heap.go +++ b/peer/pendingheap/heap.go @@ -23,6 +23,7 @@ package pendingheap import ( "container/heap" "context" + "math/rand" "sync" "go.uber.org/yarpc/api/peer" @@ -34,11 +35,13 @@ ty...
7
7
2
[{"id": "G0", "claim": "The new Rand field on pendingHeap should not be exported.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Consider Rand.Intn(len(ph.peers)) instead of the float32-to-int conversion, which is expensive and avoidable.", "category": "...
null
yarpc__yarpc-go__1614
yarpc/yarpc-go
1,614
defect
e6814ff75bd16d6c41c44820ac1cc06016a56cb2
dd361a4900f6779b244f45d6f61625531867368f
[spring][PART2] Implement JSON codec
This implements the JSON version of the codec interface introduced in #1588. This interface allows each encoding to encapsulate its encoding/decoding logic so callers of EncodingProcedures will have access to the decoded request/response bodies. This will ultimately be used to implement encoding level middleware. ...
diff --git a/etc/bin/generate.sh b/etc/bin/generate.sh index 85e936edf0..5e1eff4ffa 100755 --- a/etc/bin/generate.sh +++ b/etc/bin/generate.sh @@ -81,9 +81,10 @@ mockgen -destination=api/transport/transporttest/transport.go -package=transport # v2 mocks mockgen -destination=v2/yarpctest/mock_middleware.go -package=...
7
7
1
[{"id": "G0", "claim": "TestNewCodec only calls newCodec and discards the result, so validate the behavior with assertions, such as asserting the returned jsonCodec's reader type via an expected-reader field in the test struct.", "category": "testing", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {...
null
yarpc__yarpc-go__1770
yarpc/yarpc-go
1,770
defect
b8d433de4e84ff84567c63650266b278a8c964b1
d42bf37a84d882183829e76448710cfa86e8ab4f
Add improved metrics for streams and streaming messages
Augmenting #1769, this introduces introduces improved metrics for opening, closing, sending and receiving messages through streams. T3395799. Here we, piggyback on these existing metrics for streams: - `calls` for initiating the RPC stream - `successes` for successfully creating the stream - `caller_failures` an...
diff --git a/CHANGELOG.md b/CHANGELOG.md index f31d941c23..af1a6c94dd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). ## [Unreleased] +##...
6
3
0
[{"id": "G0", "claim": "It should be fine to shadow the outer `err` name in the stream send/receive failure handling instead of introducing `err2`.", "category": "maintainability", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "EndStreamHandshakeWithError should reduce nesting by...
null
yarpc__yarpc-go__1785
yarpc/yarpc-go
1,785
defect
49e445ad93cffa1c718888177b29ec6f2b72e010
903c7a0fb1bfa4c6a0700f18cb04181e44ceb84c
Add custom dialer function to HTTP transport
This adds a custom dial function to the HTTP transport's underlying `http.Transport`. This is a back port of an identical feature in v2 (D2681895). Note that this option is passed in through the `Transport` since all `Outbound`s share the same HTTP client. See: https://golang.org/pkg/net/http/#Transport.DialC...
diff --git a/CHANGELOG.md b/CHANGELOG.md index af1a6c94dd..72e3e95eda 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. combination of inbound and outbound, for success, failure, and application error. - A peer list and...
1
1
0
[{"id": "G0", "claim": "The DialContext option's doc comment should mention that the default dial context has a 30 second timeout and respects the KeepAlive option, whereas the override will not.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
yarpc__yarpc-go__1789
yarpc/yarpc-go
1,789
defect
49e445ad93cffa1c718888177b29ec6f2b72e010
8b6fe817ce2e77181594f5ef86dd23441c656de3
Introduce direct peer chooser
This introduces a new peer chooser, `direct`, that returns the peer identified by `transport.Request#ShardKey`. This supports directly addressable peers across transports. The `direct` chooser is not a `peer.List` as it only holds onto peers for as long as it takes for a call to succeed. Therefore, it has no `Up...
diff --git a/CHANGELOG.md b/CHANGELOG.md index af1a6c94dd..d54eaf18c8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -11,6 +11,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. combination of inbound and outbound, for success, failure, and application error. - A peer list and...
2
2
1
[{"id": "G0", "claim": "Thread a logger into the direct chooser and log the error from releasing the peer in Choose's onFinish instead of discarding it.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "Fold peer/direct/peer.go into the one file and dr...
null
yarpc__yarpc-go__1827
yarpc/yarpc-go
1,827
defect
9d1680284a6029bcbe64d30e7782134520395783
e4332e61f8eea2490e1dc446b4c0881c6f18260b
Avoid listening on public interfaces and fixed ports
This change adjusts a couple tests to avoid listening on fixed ports and public interfaces. The first change obtains an open port from the OS and immediately closes it to obtain an address that is very unlikely to answer. It’s not absolute, but it’s better than attempting to connect to a random but fixed port and ho...
diff --git a/internal/integrationtest/util.go b/internal/integrationtest/util.go index d15a19611f..89164ee63b 100644 --- a/internal/integrationtest/util.go +++ b/internal/integrationtest/util.go @@ -24,6 +24,7 @@ import ( "bytes" "context" "fmt" + "net" "sync" "testing" "time" @@ -108,7 +109,10 @@ func (s T...
1
1
1
[{"id": "G0", "claim": "The listen-then-close ephemeral port trick added in TestConnectAndStopRoundRobin may hit port reuse races; use a reliably unconnectable host:port such as \"0.0.0.1:1\" to force connection refused.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
yarpc__yarpc-go__1829
yarpc/yarpc-go
1,829
defect
184c1f3a74d2ce9434762ff3d1ce2092d19855db
b7298706f354f0bd57f8c7c6743232ac33cd0f15
Pivot fewest-pending-requests to use new abstract list
This change replaces the abstract list implementation for the pending request heap. The new abstract list tracks pending request counts itself instead of coordinating with the transport. #1828. The most sensitive change to this implementation is that the heap no longer relies on peer.Status() at all (avoiding anothe...
diff --git a/peer/abstractlist/doc.go b/peer/abstractlist/doc.go new file mode 100644 index 0000000000..6240a25dd9 --- /dev/null +++ b/peer/abstractlist/doc.go @@ -0,0 +1,51 @@ +// Copyright (c) 2019 Uber Technologies, Inc. +// +// Permission is hereby granted, free of charge, to any person obtaining a copy +// of this...
2
2
1
[{"id": "G0", "claim": "In popAndVerifyHeap's failure message, the text 'lower pending' should read 'fewer pending' since pending is a count.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "TestReleaseLockWithStaleSubscriber should keep some contex...
null
yarpc__yarpc-go__1871
yarpc/yarpc-go
1,871
defect
e317329bb77eb6cb7351dad566fd96bf00ee77c0
321f3ec12edc5830c5bed29aad602eafff1a4a02
Add panic counter to observability middleware
We want to add alerting if we see panics in our handler. Since Yarpc already recovers the panic in the same GoRoutine, best place to do this is in Yarpc middleware so any service on Yarpc can add alerting on this and pro-actively keep the panics in their runtime to 0. I browsed code of api/transport, observability mid...
diff --git a/internal/observability/call.go b/internal/observability/call.go index ba70ee3006..25b3d63818 100644 --- a/internal/observability/call.go +++ b/internal/observability/call.go @@ -276,3 +276,11 @@ func errToMetricString(err error) string { } return "unknown_internal_yarpc" } + +// EndWithPanic ends the ...
5
5
1
[{"id": "G0", "claim": "The panic behaviour augmented into the existing TestStreamingMetrics should be separated into its own subtest instead of adding more `if tt.panics` branches, even if it is largely a copy of the original test.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced...
null
yarpc__yarpc-go__1923
yarpc/yarpc-go
1,923
defect
f2a8e51640928dfb1283c0f1287fef05705c0f44
36da14cb87d65c0732fdbc60361a9888459f4e7f
Fix gRPC streaming when used with the direct peer chooser
We have an issue in the gRPC streaming outbound where we call OnFinish on the chosen peer, after the initial request was made. The direct peer list uses places its "ReleasePeer" call in the "OnFinish" function, which the gRPC transport is prematurely calling. Therefore, when streaming is used with the direct peer...
diff --git a/CHANGELOG.md b/CHANGELOG.md index b286f958fe..d122219046 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). ## [Unreleased] -- ...
2
2
1
[{"id": "G0", "claim": "The CHANGELOG entry line should end with a period.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The comment above the Chooser function is copied from ShardKey and does not describe Chooser, causing a lint/build failure be...
null
yarpc__yarpc-go__1933
yarpc/yarpc-go
1,933
defect
4632f2ba4839ecedcb83dc3b768eb21feb48c2df
577494efaefe027cbe07ab84b7f3b0108a9b3154
tchannel: Only log system error failures when clients haven't timed out
This fixes a minor logging annoyance. Some users have reported large amounts of `SendSystemError failed` and `responseWriter failed to close` logs. This was introduced in #1561 to help improve observability of TChannel failures. However, if a client times out, we still log the failures; these logs are are uninforma...
diff --git a/CHANGELOG.md b/CHANGELOG.md index 4e782a9032..14bc7c021b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -20,6 +20,9 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. - The `x/yarpcmeta` package is completely removed. - tchannel: dropped "handler failed" log. Context err...
1
1
0
[{"id": "G0", "claim": "Move the SendSystemError call on handler.go line 153 closer to where its result is actually used, e.g. inside the following conditional block.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
yarpc__yarpc-go__1954
yarpc/yarpc-go
1,954
defect
d85597c121c5b906472b44f07885e5cbfd8a3be7
b727cc13f97671e2fe49d691b0c50a792c8254bd
Add support for sending and reading stream headers
- [x] Description and context for reviewers: one partner, one stranger - [x] Docs (package doc) - [x] Entry in CHANGELOG.md This change adds support for [gRPC Streaming Response Headers](https://grpc.github.io/grpc/cpp/md_doc__p_r_o_t_o_c_o_l-_h_t_t_p2.html). `Response → (Response-Headers *Length-Prefixed-Messa...
diff --git a/CHANGELOG.md b/CHANGELOG.md index e4055783a0..d89c120e0f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## [Unreleased] ### Added +- gRPC Streaming: Added the ability to send and read stream response headers....
7
5
1
[{"id": "G0", "claim": "Rename the new sending API for consistency: the interface StreamHeadersWriter should be StreamHeadersSender and the helper WriteStreamHeaders should be SendStreamHeaders.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The...
null
yarpc__yarpc-go__1977
yarpc/yarpc-go
1,977
defect
3d283f20ecf05005819a63ecfd220f92372b6924
cfff0e3eef37c390a146c89c6185b827367189f6
Observability: add ttl histogram for inbound requests
This change adds histogram distribution for incoming requests TTL set by the caller, which could be used to find callers making requests with very small TTL - [x] Description and context for reviewers: one partner, one stranger - [x] Entry in CHANGELOG.md
diff --git a/.dockerignore b/.dockerignore index 8fa4340258..30d1086291 100644 --- a/.dockerignore +++ b/.dockerignore @@ -23,3 +23,4 @@ internal/examples/thrift-keyvalue/keyvalue/server/server internal/examples/thrift-oneway/thrift-oneway internal/service-test/service-test .idea +.vscode/ diff --git a/.gitignore b/...
3
3
2
[{"id": "G0", "claim": "The CHANGELOG entry for the TTL histogram should be written on one line instead of wrapping over two lines.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The PR only emits yarpc.edge.ttl, but the ticket it implements also ...
null
yarpc__yarpc-go__2028
yarpc/yarpc-go
2,028
defect
0a681da4189be1b91800ba8b2e2b212d15bac7ca
efb918c2569be40aaeb462ef261abf0891e0900a
Added tags filtering for YARPC middleware
Added tags filtering for YARPC middleware allowing to selectively preempt emission of certain tags on the configuration level to allow to avoid blow-up in cardinality due to some high-cardinality aspects (like "routing_delegate" for city-sharded services) More context could be found in the (internal) ticket RPC-366....
diff --git a/config.go b/config.go index 7123c81dbc..d00dcd0e92 100644 --- a/config.go +++ b/config.go @@ -131,6 +131,9 @@ type MetricsConfig struct { // default, metrics are collected in memory but not pushed. // TODO deprecate this option for metrics configuration. Tally tally.Scope + // Tags that should be sup...
10
7
0
[{"id": "G0", "claim": "The godoc comment on the new TagsBlocklist field in config.go should start with 'TagsBlocklist represents ...' and end with a period.", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The '__redacted__' literal should be extra...
null
yarpc__yarpc-go__2052
yarpc/yarpc-go
2,052
defect
b7ba06c0dfa8658b705622e338b0ad35d14bfb78
c22165654ddf1bbb04f23b523e3f144bdf43e902
Accept gRPC keepalive parameters from gRPC outbound config
- [X] Description and context for reviewers: one partner, one stranger - [ ] Docs (package doc) - [X] Entry in CHANGELOG.md This allows clients to pass gRPC keepalive parameters from the YAML configurator, similar to compress/TLS configs. This is useful when keepalive must be enabled from YARPCFx clients who do no...
diff --git a/CHANGELOG.md b/CHANGELOG.md index 3cbff8e229..99728950d2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). ## [Unreleased] -- ...
4
3
0
[{"id": "G0", "claim": "The CHANGELOG entry mispells \"parameters\" as \"paramters\" and could be simplified to \"gRPC: accept keepalive parameters for gRPC outbound configuration\".", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The `grpc-` prefi...
null
yarpc__yarpc-go__2055
yarpc/yarpc-go
2,055
defect
ef4f325c634c378eaa9e27888edbc5d82b23593a
1703d8a95dfaefe96595e3cc7b404095ec8e9503
grpc: log headers values upon validation error
In gRPC, there is validation on reserved headers to ensure there are not more than one values associated with header (e.g. rpc-service, rpc-caller). I experienced this today, and logging the header values would have saved me some debugging time.
diff --git a/transport/grpc/handler_test.go b/transport/grpc/handler_test.go index f860681a16..255cc82730 100644 --- a/transport/grpc/handler_test.go +++ b/transport/grpc/handler_test.go @@ -116,7 +116,7 @@ func TestInvalidStreamMultipleHeaders(t *testing.T) { _, err = h.getBasicTransportRequest(ctx, "service/proc") ...
2
2
0
[{"id": "G0", "claim": "The PR should make the same logging change in getApplicationHeaders() at line 216 as it made in metadataToTransportRequest(), so the logs stay consistent.", "category": "maintainability", "verdict": "supported", "priority": "P1", "scope": "pre_existing"}, {"id": "G1", "claim": "The respective te...
null
yarpc__yarpc-go__2062
yarpc/yarpc-go
2,062
defect
29e65175f62ef13fcc79903baacf68350439219e
a1a487d6b8306afa8f6b5e0e10d3999d3638187e
Fixed: Clarify error when zero peer list updaters are registered
Clarify error message for the special case of attempting to use a peer list updater when none have been registered. By default, `yarpc` does not have any registered peer list updaters. Instead, they are typically implemented and registered by other libraries. When the consumer forgets to register any peer list...
diff --git a/yarpcconfig/chooser.go b/yarpcconfig/chooser.go index e87e4a2cb8..59acd3807d 100644 --- a/yarpcconfig/chooser.go +++ b/yarpcconfig/chooser.go @@ -288,10 +288,15 @@ func buildPeerListUpdater(c config.AttributeMap, identify func(string) peer.Iden switch len(foundUpdaters) { case 0: + updaterSpecNames ...
3
3
0
[{"id": "G0", "claim": "The new test's table struct fields `env` and `test` could be removed since the test does not use them.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Instead of duplicating all the test logic, allow the test table of Test...
null
yarpc__yarpc-go__2071
yarpc/yarpc-go
2,071
defect
db9502da70e684595619a8f7ef75f349a4cbd21f
9930a227f1bad09dbdb270714fc3ffc939bbf2a6
Fixed: error created with protobuf.NewError with invalid code does not return unknown error
The following PR (https://github.com/yarpc/yarpc-go/pull/2067) added a regression in the way error are handled with protobuf. Before https://github.com/yarpc/yarpc-go/pull/2067, error created with `protobuf.NewError` would return an unknown yarpcerror if a wrong code was given (for instance 99). This capability was ...
diff --git a/CHANGELOG.md b/CHANGELOG.md index d2ea44729a..1a36792ae2 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,9 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). ## [Unreleased] -- ...
2
2
1
[{"id": "G0", "claim": "The CHANGELOG entry for the invalid-code protobuf error fix should drop the word 'again'.", "category": "documentation", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The expected error message in the new 'unsupported code' test case seems wrong: the co...
null
yarpc__yarpc-go__2086
yarpc/yarpc-go
2,086
defect
c422bff89c47239c67afd8fb286aacb2641e838e
6d2c7beb57d1cd689163af3c727f3018109368ad
Fixed: remove HTTP2 pseudo-headers when propagating HTTP/2 request to HTTP/1 service
- [x] Description and context for reviewers: one partner, one stranger In case grpc inbound (HTTP/2) -> http outbound (HTTP/1) (for instance with a YARPC middleware), and the request contains http2 specific pseudo-header fields, the http outbound call will fail. All pseudo-headers are being removed for the requ...
diff --git a/CHANGELOG.md b/CHANGELOG.md index db3d0bf256..31580d9758 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,13 +6,15 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## [Unreleased] - http: allow multiple interception options and execute in order at runtime. +- http: ...
2
1
0
[{"id": "G0", "claim": "An integration test should verify a gRPC request being forwarded to an HTTP outbound, ideally covering all transport combinations, probably at the top level rather than in transport/http.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "cla...
null
yarpc__yarpc-go__2120
yarpc/yarpc-go
2,120
defect
600cb49cc6331d8d15f65c058615a7649447efa7
6c4e9b2357161685d6888518d5ffa69f87e99e2e
add an option to disable Rpc-Service response header for tchannel transport
Adding an option to disable adding $rpc$-service header for tchannel transport. The config (excludeServiceHeaderInResponse) is a TransportOption and by default it is false and preserves existing functionality. One would have to explicitly turn it on by using ExcludeServiceHeaderInResponse() transport option. If exclude...
diff --git a/transport/tchannel/handler.go b/transport/tchannel/handler.go index 06439881d6..c6a9f2c811 100644 --- a/transport/tchannel/handler.go +++ b/transport/tchannel/handler.go @@ -98,12 +98,13 @@ func (c tchannelCall) Response() inboundCallResponse { // handler wraps a transport.UnaryHandler into a TChannel H...
6
5
2
[{"id": "G0", "claim": "The PR description should be expanded to explain how long the header-disabling behaviour is expected to remain and how and whether it will eventually be removed.", "category": "documentation", "verdict": "uncertain", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Disabling the ...
null
yarpc__yarpc-go__2123
yarpc/yarpc-go
2,123
defect
ef97418bd548cf1e05cf87e62a69c4fff843e062
0bd3c52e94c9012f286e1d24dabe0fe481881a38
Fixing build Failures
- [ ] Description and context for reviewers: one partner, one stranger This diff aims to fix the build failure caused by the usage of deprecated [golang/protobuf/proto](https://github.com/golang/protobuf/blob/master/proto/proto.go#L12) pkg.
diff --git a/encoding/protobuf/v2/error.go b/encoding/protobuf/v2/error.go index 3df1a7b831..0031fe28c3 100644 --- a/encoding/protobuf/v2/error.go +++ b/encoding/protobuf/v2/error.go @@ -25,21 +25,19 @@ import ( "fmt" "strings" - "github.com/golang/protobuf/proto" "github.com/golang/protobuf/ptypes/any" "go.u...
5
4
2
[{"id": "G0", "claim": "Giving up on buffer reuse in marshalProto increases allocations, so the PR should use the proto append-marshal API with a pooled zero-length byte slice and put the slice back in the cleanup function.", "category": "performance", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {...
null
yarpc__yarpc-go__2124
yarpc/yarpc-go
2,124
defect
47f390dcd7da7df7465a77313249f6c0c866f5c2
16cbc85ec0061b966a78e4fb96131c550dd6a27b
Added internal APIs for reading and writing a proto.Message from a stream
- [ ] Description and context for reviewers: one partner, one stranger This diff aims to add APIs for reading and writing a proto.Message from a stream. This is almost similar to what we have in v1/gogo APIs currently. Integrations test will be added later once v2 plugin is merged.
diff --git a/encoding/protobuf/v2/stream.go b/encoding/protobuf/v2/stream.go new file mode 100644 index 0000000000..daeb1eba75 --- /dev/null +++ b/encoding/protobuf/v2/stream.go @@ -0,0 +1,79 @@ +// Copyright (c) 2022 Uber Technologies, Inc. +// +// Permission is hereby granted, free of charge, to any person obtaining ...
1
1
0
[{"id": "G0", "claim": "Drop the extra blank line before the final assertion in TestReadFromStreamDecodeError (line 61) and likewise at line 92 of stream_unit_test.go.", "category": "maintainability", "verdict": "supported", "priority": "P3", "scope": "introduced"}]
null
yarpc__yarpc-go__2138
yarpc/yarpc-go
2,138
defect
707eebcd86a25ec5c88e2607664696506426f53e
23a2f0d0bc1b73022601126d20f638c675e928aa
[6/n] tlsmux: add metrics observer
Emit metrics on creating TLS/plaintext connections and count of TLS handshake errors. For reviews: start review from `observer.go` file
diff --git a/transport/internal/tlsmux/listener.go b/transport/internal/tlsmux/listener.go index 526093bfd3..e284a53eac 100644 --- a/transport/internal/tlsmux/listener.go +++ b/transport/internal/tlsmux/listener.go @@ -23,20 +23,39 @@ package tlsmux import ( "crypto/tls" "net" + + "go.uber.org/net/metrics" + "go.u...
5
2
2
[{"id": "G0", "claim": "The error log for the tls_connections counter creation failure should not say \"plaintext connections\" — fix the copy-pasted message.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "The error log for the tls_handshake_failure...
null
yarpc__yarpc-go__2139
yarpc/yarpc-go
2,139
defect
707eebcd86a25ec5c88e2607664696506426f53e
5cb228258ffadecd544582a30f8b28509310ce5c
[7/n] tlsmux: add non-blocking mux listener
Currently, a new connection accepted from the original listener goes through muxer, sniffs bytes and completes handshake (if tls connection). The above flow is synchronous, and a slow connection can block/slowdown sniffing & handshake, which causes the head of the line blocking issue for other connections waiting to ge...
diff --git a/transport/internal/tlsmux/listener.go b/transport/internal/tlsmux/listener.go index 526093bfd3..106817b22b 100644 --- a/transport/internal/tlsmux/listener.go +++ b/transport/internal/tlsmux/listener.go @@ -22,44 +22,124 @@ package tlsmux import ( "crypto/tls" + "errors" "net" + "sync" + + "go.uber.o...
1
1
0
[{"id": "G0", "claim": "Starting the connection server in NewListener would remove the need for the sync.Once in Accept.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}]
null
yarpc__yarpc-go__2145
yarpc/yarpc-go
2,145
defect
09df5192426c7bfab694ae9d190a34cdd0ce1273
7b68d8875843ce13de54147b94ffed2bbc6ca314
[8.1/n] support TLS modes
Define supported modes of TLS listener: * permissive: accept TLS and plaintext connections * enforced: accept TLS connections only. Integrate the modes into the tlsmux listener to reject plaintext connections in enforced mode.
diff --git a/api/transport/inboundtlsmode.go b/api/transport/inboundtlsmode.go new file mode 100644 index 0000000000..8248973f9d --- /dev/null +++ b/api/transport/inboundtlsmode.go @@ -0,0 +1,75 @@ +// Copyright (c) 2022 Uber Technologies, Inc. +// +// Permission is hereby granted, free of charge, to any person obtaini...
8
4
1
[{"id": "G0", "claim": "The hand-written String method should be generated with golang.org/x/tools/cmd/stringer instead of maintained by hand.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The inline error returned in handlePlaintextConn should...
null
yarpc__yarpc-go__2146
yarpc/yarpc-go
2,146
defect
09df5192426c7bfab694ae9d190a34cdd0ce1273
cb1cd1c2d7232c04d59ddf58a0dec24725ccb2bb
[gRPC] accept custom header list sizes
- [X] Description and context for reviewers: one partner, one stranger - [X] Entry in CHANGELOG.md Expose transport options to set gRPC maximum header list size for the client and server. Max header sizes are also configurable through config YAML: ``` yarpc: transports: grpc: clientMaxHeaderListS...
diff --git a/CHANGELOG.md b/CHANGELOG.md index b5e891276c..09cc30a1dd 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,8 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## [Unreleased] - No changes yet. +### Added +- grpc - option to set custom maximum header list size. ...
5
3
1
[{"id": "G0", "claim": "The newly added defaultServerMaxHeaderListSize constant is never used anywhere and should be dropped.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The header list sizes should be modelled as plain values with a default ...
null
yarpc__yarpc-go__2158
yarpc/yarpc-go
2,158
defect
ffc30ddaa014ce9d291fc2979d99ef03b0b62ce6
9e9d1efb20db22a447fd6efa4f47074ddbafb067
Added integration test for inbound and outbound with any resolver
This PR aims to add integration for inbound and outbound with anyresolver. The test simulates (un)marshalling with anytypes provided no resolver and resolver.
diff --git a/encoding/protobuf/v2/inbound_test.go b/encoding/protobuf/v2/inbound_test.go new file mode 100644 index 0000000000..384e3a71ce --- /dev/null +++ b/encoding/protobuf/v2/inbound_test.go @@ -0,0 +1,86 @@ +// Copyright (c) 2022 Uber Technologies, Inc. +// +// Permission is hereby granted, free of charge, to any...
5
3
0
[{"id": "G0", "claim": "In TestInboundAnyResolver the handler should use Require.NoError instead of assert.NoError so the subtest stops before touching a nil Any field.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The v2 codec sets DiscardUnknown on t...
null
yarpc__yarpc-go__2177
yarpc/yarpc-go
2,177
defect
051667d2b1b8dc520e07007108a72e26c0b69a00
b38e1361be6087c64cbfb016a97a19b715b1d1a3
[7/n] tls: integrate http outbound tls
HTTP outbounds can be configured with client-provided TLS config via the `OutboundTLSConfigProvider` interface. Services can configure the outbound TLS like: ``` yarpc: outbounds: test-svc: http: url: http://127.0.0.1:5453 tls: mode: enforced spiffe-ids: ...
diff --git a/transport/http/config.go b/transport/http/config.go index dc737445e0..45e39a04a8 100644 --- a/transport/http/config.go +++ b/transport/http/config.go @@ -21,6 +21,7 @@ package http import ( + "errors" "fmt" "time" @@ -241,7 +242,6 @@ type OutboundConfig struct { // URL to which requests will be...
4
3
1
[{"id": "G0", "claim": "The indentation of the `- destination-id` line in the TLS example config comment is off.", "category": "documentation", "verdict": "supported", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "The nil-check on the TLS option returned by options() is unnecessary and the prepend lo...
null
yarpc__yarpc-go__2183
yarpc/yarpc-go
2,183
defect
792f032c626787c98d49051aac80d6fb44fb56c0
4cbcb0fd457dd2c45b133e792bc862ac1c6d4532
[3/n] tchannel-mtls: integrate tchannel outbound tls
Tchannel outbounds can be configured with client-provided TLS config via the `OutboundTLSConfigProvider` interface. Services can configure the outbound TLS like: ``` yarpc: outbounds: test-svc: tchannel: peer: 127.0.0.1:5453 tls: mode: enforced spiffe-ids: ...
diff --git a/CHANGELOG.md b/CHANGELOG.md index 1a1aa74e7e..1550675465 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,7 +5,8 @@ The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/) and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html). ## [Unreleased] -- ...
3
2
0
[{"id": "G0", "claim": "Move the inline errors created in getPeerTransport to a top-level var section.", "category": "maintainability", "verdict": "opposed", "priority": "P3", "scope": "introduced"}, {"id": "G1", "claim": "Explain why the dialer-invoked assertion requires more than one call and update the comment to re...
null
yarpc__yarpc-go__2270
yarpc/yarpc-go
2,270
defect
23c069fdaf9c389c674dd1f55e5c9bfd9c8a818f
16778b67450f8fc4abce2549960ed2ce6f840999
feat: Opt for concatenation instead of using fmt.Sprintf
## Summary The procedure.ToName function, a frequently used pathway, currently relies on `fmt.Sprintf` to merge strings. However, this method could inadvertently cause additional memory allocations. By directly concatenating these strings instead of utilizing fmt and constructing a format template, we can re...
diff --git a/CHANGELOG.md b/CHANGELOG.md index da56c06cec..ec669ba32a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -8,6 +8,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ## [Unreleased] - Upgraded go version to 1.21, set toolchain version. - Reverted rpc-caller-procedure val...
2
2
0
[{"id": "G0", "claim": "The randomized benchmark looks flaky (at length 10 it likely just re-randomizes the same strings, producing the nonsensical -100% allocs delta), so use a single basic benchmark with a hardcoded value.", "category": "testing", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id...
null
yarpc__yarpc-go__2317
yarpc/yarpc-go
2,317
defect
31a6e88b74a5211b9a0f22b594d4e8fd7b50c801
f39bae63f36b5b8af115581df97009a6b314beca
Feat: Add http2 server support
- [X] Description and context for reviewers: one partner, one stranger - Add http2 server support - version2 accept both http1 and http2 request. So all existing inbounds should work as expected. - Add config that can be used to override this - [Test Checklist ](https://docs.google.com/document/d/1mYfH0DmC3R...
diff --git a/CHANGELOG.md b/CHANGELOG.md index fc53993aab..5f9ecb9b76 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,7 +6,10 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0. ======= ## [Unreleased] -- No changes yet. +### +- Added HTTP2 server support for the HTTP inbound. + ...
2
2
1
[{"id": "G0", "claim": "The UseHTTP2 option name reads as if HTTP/2 is disabled by default, so it should be inverted to a DisableHTTP2-style option.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The pull request should include real integration tests wit...
null
yarpc__yarpc-go__2367
yarpc/yarpc-go
2,367
defect
7df43bc24b317717ca7fcb6e2a3533c9dce502c0
f4b455bc96f21710cdaedc67cdb46a5a6a197537
Feat: set content-type based on encoding for http outbounds
- [X] Description and context for reviewers: one partner, one stranger - set content-type based on encoding for http outbounds RELEASE NOTES: set content-type based on encoding for http outbounds
diff --git a/transport/http/constants.go b/transport/http/constants.go index fcc5bf515b..db66eb2d02 100644 --- a/transport/http/constants.go +++ b/transport/http/constants.go @@ -60,6 +60,9 @@ const ( // to finish. TTLMSHeader = "Context-TTL-MS" + // Content Type of the request + CONTENTType = "Content-Type" + ...
2
1
0
[{"id": "G0", "claim": "The new exported constant should be spelled ContentType, not CONTENTType.", "category": "maintainability", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "getYARPCContentType could use a map lookup instead of a switch statement.", "category": "design", "v...
null
yarpc__yarpc-go__2409
yarpc/yarpc-go
2,409
defect
07420c24e447031c0839761b86b264ce26eda67b
29d621f1d7a156cd1b80c8324de94ea2b9f507fb
Upgrade go version to 1.23 and use iterators for headers
### Description **TLDR** With this change, services will spend less CPU cycles when getting the header names for a given yarpc call. This change also upgrades the go version for `yarpc-go` to the `v1.23`. **What** This diff introduces `HeaderNamesAll()` for the `Call` struct and `All()` for the `Header` struct...
diff --git a/.buildkite/pipeline-default.yml b/.buildkite/pipeline-default.yml index 4457b0aefb..025ad2656e 100644 --- a/.buildkite/pipeline-default.yml +++ b/.buildkite/pipeline-default.yml @@ -64,7 +64,7 @@ steps: - docker-compose#v3.13.0: run: yarpc-go-1.21 - - name: ":go: 1.22 test - %n" + - n...
4
3
0
[{"id": "G0", "claim": "Add a Call-level OriginalHeadersLen() count of the original headers, for consistency with the other header accessors.", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The HeaderNamesAll docstring should say when to use it over Heade...
null
yarpc__yarpc-go__2432
yarpc/yarpc-go
2,432
defect
25d2ad20043166f991fa2b0ef5a74e527ee9f259
76ad71798288c35a80561e1c20442413c1234a54
add support for header mapping
Adds support for header key mapping RELEASE NOTES:
diff --git a/api/transport/header.go b/api/transport/header.go index f63699129c..076721a047 100644 --- a/api/transport/header.go +++ b/api/transport/header.go @@ -45,6 +45,11 @@ type Headers struct { originalItems map[string]string // overrideOriginalItemWithCanonicalizedKey indicates whether to override override...
4
3
3
[{"id": "G0", "claim": "WithHeaderCaseMapping should not be exposed as a public method, because services could then potentially modify the header mapping on the fly.", "category": "design", "verdict": "supported", "priority": "P1", "scope": "introduced"}, {"id": "G1", "claim": "buildInbound should fail open when header...
null
yarrick__iodine__101
yarrick/iodine
101
defect
68b0a7b16e214f0b50a6a849fc30756d580b480a
5574b776ba41ecae5c6823ced5fecb7f8c1f757f
common: get_addr should return -1 on error
Closes #96 1. Update `get_addr()` to always return -1 on error 2. Add test to ensure the error value is returned when host, port, flags, or result struct are invalid
diff --git a/src/common.c b/src/common.c index 8d2fec0d..cb689cbf 100644 --- a/src/common.c +++ b/src/common.c @@ -158,14 +158,15 @@ get_addr(char *host, int port, int addr_family, int flags, struct sockaddr_stora hints.ai_protocol = IPPROTO_UDP; res = getaddrinfo(host, portnum, &hints, &addr); - if (res == 0) { ...
1
1
1
[{"id": "G0", "claim": "The addrlen declaration is now mixed in with the code, which is not allowed on older C compilers; move the variable to the top or add a new scope.", "category": "correctness", "verdict": "supported", "priority": "P1", "scope": "introduced"}]
null
yaxitech__ragenix__68
yaxitech/ragenix
68
defect
c87f3d672aeb5133c2c0acb64ad7c8a159eb5f41
c174737b9973304f02d112b7f6a66b749da91f48
Integration with age plugins
This adds support for age plugins, such as the [YubiKey](https://github.com/str4d/age-plugin-yubikey). PR to add `age-plugin-yubikey` to `nixpkgs`: https://github.com/NixOS/nixpkgs/pull/152042
diff --git a/Cargo.lock b/Cargo.lock index 613610f..b270e93 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -19,110 +19,80 @@ checksum = "f26201604c87b1e01bd3d98f8d5d9a8fcbb815e8cedb41ffccbeb4bf593a35fe" [[package]] name = "aead" -version = "0.3.2" +version = "0.4.3" source = "registry+https://github.com/rust-lang/cra...
6
5
1
[{"id": "G0", "claim": "The example plugin should override `pkgs.rage` (or at least use its `src`) so that the version of `rage` used throughout the checks is aligned.", "category": "correctness", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "The check should make the plugin a...
null
yayaa__LocationManager__104
yayaa/LocationManager
104
defect
f1cbd826994b8b9891f0fee3093857a36fad900b
18d75b3552062aae0c18874654a7d1bd45048a8b
add an interface for more custom logging
Thanks for this library! Due to debugging issues we would like to use our custom logging when using this library. Usually App developers tend to use something like Timber. Therefore I proposed the following interface between LogUtils and `android.util.Log` to be able to replace the `DefaultLogger` with one which logs s...
diff --git a/library/src/main/java/com/yayandroid/locationmanager/LocationManager.java b/library/src/main/java/com/yayandroid/locationmanager/LocationManager.java index 8e3b927..3840377 100644 --- a/library/src/main/java/com/yayandroid/locationmanager/LocationManager.java +++ b/library/src/main/java/com/yayandroid/loca...
3
3
1
[{"id": "G0", "claim": "Fix the typo in the new setLogger Javadoc on LocationManager: \"it can be replaces\" should read \"it can be replaced\".", "category": "documentation", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim": "Add the @NonNull annotation to the new setLogger method...
null
yayaa__LocationManager__107
yayaa/LocationManager
107
defect
62185eaec719279a52666c22b66a24e1487efb7b
6ad3362849be8e54905257f9f2d6d82cc3b3d464
Updated to connectionless APIs (fix #105)
Fix #105 Remove deprecated FusedLocationProviderApi, use [FusedLocationProviderClient](https://developers.google.com/android/reference/com/google/android/gms/location/FusedLocationProviderClient). **Public API changes**: - Delete fields: GooglePlayServicesConfiguration.java : delete failOnConnectionSuspended...
diff --git a/README.md b/README.md index 1561e49..94ee000 100644 --- a/README.md +++ b/README.md @@ -14,7 +14,7 @@ What are those? Let's see... </ul> Let's assume we got the permission, now what? -We have this cool Google Play Services optimised location provider [FusedLocationProviderApi][1] which provides a commo...
17
13
5
[{"id": "G0", "claim": "The added check whether activeProvider is already a DefaultLocationProvider in continueWithDefaultProviders() is unnecessary and should be removed (and its expected behaviour clarified).", "category": "design", "verdict": "supported", "priority": "P2", "scope": "introduced"}, {"id": "G1", "claim...
null