text:
feat: Select component (Iteration 1)

SUMMARY
This PR introduces a new Select component based on the Antdesign Select. The goal of the refactoring is to eliminate all the various instances of selects throughout the codebase and merge them into one, while getting rid of the react-select entirely.
PROPS
At the moment only some of the Antd props have been exposed in the interface on top of the custom props. This is to make sure that the Select component is used with the intended behaviors. However, as the implementation of the new component goes, we might realize that other default props should be exposed.

Prop Name
Origin
Type
Description
Prop exposed
Default behavior (prop not exposed)

mode
Antd
multiple OR tags
Set mode of Select
x

truncateOptions
Custom
true (default) OR false
When true it truncates the options with a long text and shows a tooltip. When false, it wraps options with a long text to a new line.

x

maxTagCount
Antd
number OR responsive
Max tag count to show. responsive will cost render performance

x

showSearch
Antd
true OR false (default)
Whether show search input in single mode
x

allowNewOptions
Custom
true OR false
It allows to create a new option when no options match the search. This is true by default when the property mode is set to tags OR multiple. Otherwise it's false by default.
x

options
Antd
{ label, value }[] OR Promise => { label, value }[]
Select options. It can accept an array or a promise that resolves an array or rejects
x

loading
Antd
true OR false (default)
Indicate loading state
x

onChange
Antd
function(value, option:Option OR Array)
Called when select an option or input value change
x

placeholder
Antd
ReactNode
Placeholder of select
x

value
Antd
string OR string[]number OR number[]LabeledValue OR LabeledValue[]
Current selected option
x

tokenSeparators
Antd
string[]
Separator used to tokenize on tag and multiple mode

x

autoFocus
Antd
true OR false (default)
Get focus by default
x

allowClear
Antd
true OR false (default)
Show clear button
x

disabled
Antd
true OR false (default)
Whether disabled select
x

filterOption
Antd
true (default) OR false OR function(inputValue, option)
If true, filter options by input, if function, filter options against it. The function will receive two arguments, inputValue and option, if the function returns true, the option will be included in the filtered set; Otherwise, it will be excluded
x

aria-label
Antd
string
Aria label (for assistive tech)
x

getPopupContainer
Antd
function(triggerNode)Default:() => document.body
Parent Node which the selector should be rendered to. Default to body. When position issues happen, try to modify it into scrollable content and position it relative.

x

name
Custom
string
Used for the test cases
x

notFoundContent
Antd
ReactNode
Specify content to show when no result matches
x

header
Custom
ReactNode
Header of the Select
x

paginatedFetch
Custom
true OR false (default)
Makes the async select paginated
x

CUSTOM FEATURES
Few abilities have been added on top of the default Antd Select component, as follows:

The creation of custom options for single mode
Options as an array or as a Promise to fetch data from the server (more information below in Async Select section)
Header as a prop
Sorting of the selected options at the top of the dropdown
Automatic scroll at the top of the dropdown

ASYNC SELECT
The Select component now has the ability to fetch data. The options property can accept a Promise. The Select component will do this for you:

Runs the fetch when the component mounts to load the initial options
It will check if the searched value already exists in the options and won't run the fetch in that case
It allows pagination when the property paginatedFetch is set and will automatically run the fetch by passing the current page as the user scrolls through the options
It will handle and print errors

WHAT'S MISSING (Upcoming in Iteration 2)

Paginate few px before the bottom of the scroll for better UX
Check/Discuss whether we need the onPaste and on closeOnScrollOut props
Remove the usage of any from the implementation
When allowNewOptions is true, showSearch should be true as well in Storybook
Our interface should only expose single and multiple modes
Test cases

This first iteration should be merged as it does not affect any existing functionality. @michael-s-molina  will take over the "WHAT'S MISSING" and any other change request in a separate PR as soon as this is merged (Iteration 2).

@geido First thoughts:

You can rename AntdSelect and AntSelect.stories to Select and Select.stories  using the index to resolve any name conflicts.
I think it would be nice to simulate a service API for the storybook. We can support search, pagination and also throw errors to test the error handling.
You can use React useReducer to manipulate multiple state values if the number of states increases.
Replace handleOnDeselect = (option: any) with handleOnDeselect = (value: string | number | AntdLabeledValue)
Replace handleOnSelect = (option: any) with handleOnSelect = (value: string | number | AntdLabeledValue)
It would be nice to add one Select on each corner of the viewport on the storybook page. Then we can test the drop-down behavior for each corner and when scrolling.

@geido First thoughts:

You can rename AntdSelect and AntSelect.stories to Select and Select.stories  using the index to resolve any name conflicts.

This is just to simplify the review and to avoid that the new implementation would appear as changes made on the original file. Once this PR is merged, we can just rename it.

I think it would be nice to simulate a service API for the storybook. We can support search, pagination, and also throw errors to test the error handling.

I have enhanced the storybook to provide an Async Select dedicated story. However, I am looking to do more improvements there as soon as I am done with the rest of the implementation.

You can use React useReducer to manipulate multiple state values if the number of states increases.

I am definitely going to if the number of changes to the state should increase.

Replace handleOnDeselect = (option: any) with handleOnDeselect = (value: string | number | AntdLabeledValue)
Replace handleOnSelect = (option: any) with handleOnSelect = (value: string | number | AntdLabeledValue)

I tried, however, typescript still complaints. I am avoiding dedicating too much time to this and leaving it for when the main implementation is completed.

It would be nice to add one Select on each corner of the viewport on the storybook page. Then we can test the drop-down behavior for each corner and when scrolling.

This is now done.
Thank you!

/testenv up

/testenv up

I think this first iteration is great. Thanks for organizing the work so well.

+💯 This is some awesome foundational work, which is going to put Superset on a much more clean and consistent path with these components. Thank you also for the great pre-coding audit process of all the features and props that our "select party" offered.
For those who haven't seen it, this new component aims to (eventually) replace all of these:

authors: geido michael-s-molina rusackas


text:
chore: migrate AnchorLink component from jsx to tsx

SUMMARY

PR for migrating AnchorLink react component from JSX to TSX
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

TESTING INSTRUCTIONS

ADDITIONAL INFORMATION

[x] Has associated issue: #10004
[x] Enhancement (new features, refinement)
[ ] Required feature flags:
[ ] Changes UI
[ ] Includes DB Migration (follow approval process in SIP-59)

[ ] Migration is atomic, supports rollback & is backwards-compatible
[ ] Confirm DB migration upgrade and downgrade tested
[ ] Runtime estimates and downtime expectations provided

[ ] Introduces new feature or API
[ ] Removes existing feature or API

@etr2460 Ptal, thx!

source: gharchive/pull-request

repo: apache/superset

license_type: permissive

license_source: github-api


text:
fix: can't trigger delete event on SqlaTable

SUMMARY
The SqlaTable model can't remove associative sl_tables when triggering delete event.
BEFORE/AFTER SCREENSHOTS OR ANIMATED GIF

N/A
TESTING INSTRUCTIONS

CI
ADDITIONAL INFORMATION

[ ] Has associated issue:
[ ] Required feature flags:
[ ] Changes UI
[ ] Includes DB Migration (follow approval process in SIP-59)

[ ] Migration is atomic, supports rollback & is backwards-compatible
[ ] Confirm DB migration upgrade and downgrade tested
[ ] Runtime estimates and downtime expectations provided

[ ] Introduces new feature or API
[ ] Removes existing feature or API

this issue has fixed by https://github.com/apache/superset/pull/19421, so closed it.


text:
No need for REs

https://github.com/apache/www-site/blob/9f860a8bcd6e5b0172857f6587e4a5ecb82a62eb/theme/plugins/asfgenid.py#L42
The fixups don't currently use REs.
They would be simpler as string replacements.
Alternative, change to use something like:
(re.compile(r'<(/?(script|style|iframe))'), '<\1')

This example did not work properly. I tried, but then reverted it.

source: gharchive/issue

repo: apache/template-site


text:
c_glib: Compiler: Omit processing-function defs for empty services

With this change the compiler omits the processing-function-definition array for a service with no methods, corresponding to the checks on lines 2555 and 2562 that omit the code that would use this array under the same condition.

Committed as part of THRIFT-3284

authors: jfarrell simonsouth

repo: apache/thrift


text:
Settings for max origin connections changed in ATS 9.0

I'm submitting a ...

improvement request (usability, performance, tech debt, etc.)

Traffic Control components affected ...

Traffic Ops ORT

Current behavior:
Currently, ORT uses a delivery service's max_origin_connections field to configure/override the ATS records.config setting proxy.config.http.origin_max_connections. In ATS 9.0, this setting was removed and replaced: https://docs.trafficserver.apache.org/en/9.0.x/release-notes/upgrading.en.html#connection-management.
New behavior:
When generating configs for ATS < 9.0, ORT should continue to use the proxy.config.http.origin_max_connections setting, but for ATS >= 9.0, ORT should use the new settings instead.

Fixed by https://github.com/apache/trafficcontrol/pull/5641

repo: apache/trafficcontrol


text:
Duplicate parameter names

If a function has two parameters with the same name, the second parameter shadows the first one, which makes the code hard to understand and error-prone.

Can one of the admins verify this patch?

Done.

Please fill out the Pull Request template to the best of your ability.

+1

This was resolved in #3601

authors: MatheusRV asfgit dangogh ocket8888


text:
Validation of YAML root structure for WIP SplitDNS YAML config

This contains just the file loading and root validation part of a YAML loader for SplitDNS. I foresee that the complete feature will be a large change, and I would like feedback now while the changes are small to help guide my design and to increase the effectiveness of the code review.
I am marking this as a draft PR because all these changes are 'dead code' and are not useful yet by themselves.

[approve ci clang-format]

[approve ci centos]

I have to add FetchSM to the new stub now.

[approve ci rat]

authors: JosiahWI bneradt

repo: apache/trafficserver


text:
Fix Http/2 priority crashes.

This addresses the crashes reported in issue #4057
I will probably make another pass to remove some of the debugging asserts.  The main problem was in the first call to _change_parent in reprioritize.  This call should only be done of the change in dependence would cause a loop.  Otherwise that call will cause a direct crash or a parent loop.
From section 5.3.3 of the spec https://http2.github.io/http2-spec/#reprioritize
If a stream is made dependent on one of its own dependencies, the formerly dependent stream is first moved to be dependent on the reprioritized stream's previous parent. The moved dependency retains its weight.

Looks reasonable. This looks also fix #3990. If the reprioritization could make a loop by somehow, it spins cpu.
@shinrich Could you add a test to cover this case in test_Http2DependencyTree.cc ?

Will try to add a unit test case for the spinning.  It has been running in one of our prod boxes for a day without incident.  Will clean out the extra asserts too.

Pushed a new commit with two unit tests and removing the extra release asserts.

[approve ci autest]

I'm testing this on Docs / CI again, where we ran into these issues.

This has been running on Docs / CI for a few days now, and no crashes. Are we good with this change for v8.0.0 ?

@shinrich Can you please make a PR against the 7.1.x branch for this?

authors: masaori335 shinrich zwoop


text:
traffic_dump: Fixing content:size collection.

traffic_dump was collecting the client-request body information too
early, resulting in an incorrect content:size value (it was always
zero). This holds off on collecting the body size until later so the
value is accurate. A traffic_dump AuTest is being added to verify
correct behavior with requests containing bodies.
Also, this updates the Traffic Dump post_process.py script to add
proxy-request and server-response nodes to transactions without them
because the proxy replied locally to the request. This is useful in
replay scenarios in which the test version of Traffic Server likely
won't have the cached responses.

Is this something we need for 9.0.x or 9.1.x? Please mark accordingly. Also, it doesn't cherry-pick cleanly to 9.0.x, it needs at least 452d60ea7878b202e45b297083641ed3968fc3fb as well, so mark that as well if so.

Hi Leif. Yes, getting the various traffic_dump changes into the 9 branches will be helpful. I believe the 452d60e commit you reference is in 9.0.x, if I'm reading github correctly:
https://github.com/apache/trafficserver/commit/617c6f5a3587f3fb63f2fab1c11e909d9a487cf9
That said, there might be other commits in master that should get pulled to 9.0.x which would cause a merge issue.
I'll work on getting the various traffic_dump commits marked for 9. (I'm not authorized to do so.)

Cherry picked to 9.0.x

authors: bneradt bryancall zwoop


text:
Fix error in cert lookup

Noticed while writing the tests for PR #6483.  Originally had the fix there, but @maskit suggested pulled out the obvious error into a separate PR from the original, involved PR, which seemed quite reasonable.

Turns out this fix was really intrinsic to the original PR.  Closing.


text:
[COMMUNITY] new committer -- gromero

Add @gromero to committers list.
cc @tqchen @gromero

Congrats!

Congrats @gromero!!

authors: areusch junrushao1994 mehrdadh

repo: apache/tvm


text:
[LLVM] Fix registerCallbacks API after recent change

LLVM upstream recently changed their API for registerCallbacks in https://reviews.llvm.org/D146160 and this causes an error while building

cc @kparzysz-quic

Are you sure that this api has changed since the version 17.0.0? I used your version to compile tvm with llvm 17.0.0, but failed. When I use the fam instead of the mam, it runs smoothly.

Version 17 of LLVM at this moment refers to the main branch of it.  If you refresh your sources of LLVM, you will get the changes that this patch reflects.

authors: LRY89757 kparzysz-quic quic-sanirudh


text:
[Cleanup] Remove using namespace tvm::runtime from headers

Prior to this commit, various header files had using namespace tvm::runtime, which imports all names from tvm::runtime into the current namespace.
These imports can cause compilation errors depending on the order of #include statements.  For example, the #include <tvm/relay/attrs/transform.h> file uses the unqualified name Bool to refer to ::tvm::Bool, a subclass of PrimExpr.  If a different header file specifies using namespace tvm::runtime within the tvm::relay namespace, then the unqualified name Bool ambiguously refers to either ::tvm::Bool or ::tvm::runtime::Bool.
In MSVC, this can cause even further compilation errors.  By default, MSVC does not follow the C++ standard for name resolution in templates.  The standard requires that any names in a template that do not depend on template parameters be resolved when the template is declared.  However, MSVC instead resolves these names when the template is instantiated.  As a result, the same using namespace tvm::runtime may cause a compilation error if it occurs after the template's declaration, but before the template's usage.
(TVM provides the /permissive- flag to MSVC builds specifically to disable MSVC's non-standard name resolution, so this only impacts downstream forks that disable this flag.  See https://github.com/apache/tvm/pull/16343 for more details.)
This commit removes using namespace tvm::runtime, replacing them with explicit using tvm::runtime::SOME_SPECIFIC_SYMBOL where necessary.  This resolves both the include-order dependency for standards-compliant compilers, and the compilation errors for MSVC's default build.

temp block this in light of #16183 (comment)

Good point.  I think this change is beneficial regardless of #16183, but the FFI changes touch so many parts of TVM that I wouldn't want to declare them 100% independent.

Rebased these changes onto main, and this PR should be land-able now that the performance regressions from #16183 have been resolved.


text:
STM32: add as a new target

@areusch
This small pull request aims at adding the STM32 as a new target to a set of TVM targets.

@stoa shall we progress this one as well? i think it needs some lint fixes and perhaps a rebase.

@areusch
Hello, Andrew
Yes. If you agree it is ready to become a PR, I fix the issues and publish ?

@stoa yep it looks ok to merge to me, it just needs the rebase and lint fixing.

@areusch
Made lint checks and rebased. Please review.
cheers
Arthur

@stoa this looks ready to go when Jenkins is happy with it. I retriggered it to see if it will pass now.

@areusch
Hello, Andrew
It seems that the CI failed on some doc issues that look not related to this PR.
Can you double-check ?

@stoa agreed, i retriggered it. we were having some network flakiness last week, hopefully it's gone now.

ah--i think you need to sync the PR and re-run
docker/bash.sh ci_cpu tests/lint/git-clang-format.sh -i
sorry for this--the version of git-clang-format has changed i believe since the last commit here.

@areusch
Hello, Andrew
Seems to pass now.

thanks @stoa and sorry this took so long!

authors: areusch stoa


text:
[ZEPPELIN-2749] Use scalable file structure for zeppelin web

What is this PR for?
We have improved zeppelin-web, but some parts are still messy. As part of keeping zeppelin-web module healthy (ZEPPELIN-2725), I suggest having these file structure. (Refer the screenshot section)
Here are few reasons.

unified directory, file name helps us to recognize, find which part we should modify / fix

Let's say we need to modify the resize feature of paragraph, where the developer can find it? currently, it's under component/resizable not under paragraph/resizeable and also it's not the shareable component. There is no reason to keep that files in component/**

this structure is what the angularjs community has verified for few years. so newly joined developers can feel more comfortable.
this is necessary for Modular archiecture and it eventually helps us to make a smooth transition toward next technologies (even whatever we will use)

Additionally,

This is not the meaningless refactoring PR and doesn't block developing new features / fixes (Please refer the Some Details section)
I will handle conflicts for few days would be brought by other WIPs

For your information,

https://github.com/toddmotto/angularjs-styleguide#file-naming-conventions
https://github.com/johnpapa/angular-styleguide/blob/master/a1/README.md#naming

How to Review This PR?
Please follow the commits. I modified submodules by splitting commits. Thus commit message includes what has been done in that PR. For example,

Some Details

Didn't change the widely used variable names not to make many conflicts. For example, websocketMsgSrv, arrayOrderingSrv
Since there are helium packages already published, didn't change the HTML file names like pivot_setting.html (it's better to use pivot-setting.html if we following the rule)

What type of PR is it?
[Improvement | Refactoring]
Todos
Please refer the commit message.
What is the Jira issue?
ZEPPELIN-2749
How should this be tested?
All functionalities must work as like before, CI will test it.
Screenshots (if appropriate)
Before: messy, mixed directory structure

After: only the shared components will be placed under components/

Questions:

Does the licenses files need update? - NO
Is there breaking changes for older versions? - NO
Does this needs documentation? - NO

Cool, I also experienced as like what your describing at especially filename and messy folders.
And Tested and LGTM. Everything is working.

@soralee Thanks for the review. We need to keep the zeppelin-web module clean. :)
Merge if no more discussion.

rebased to fix some commit message which can't be handled in the merge script. (*)

Rebased to clean commit messages.

Left a comment for history.
I tried to merge this one before 11 hours ago and at that time it looks merged. (no error on the script) But ASF git didn't reflect the commit. That's the reason why I rebased twice. (I thought long commit message or some invalid chars are the problem).

repo: apache/zeppelin

license_source: bigquery


text:
[ZEPPELIN-5802][MINOR] fix rimraf version

What is this PR for?
In the [ZEPPELIN-5786] Remove sap interpreter  pr, the rimraf version overrided from 3.0.2 to 2.5.4 unintentionally.
Therefore it needs to be fixed back to 3.0.2 version.
What type of PR is it?
Bug Fix
Todos

[ ] - fix rimraf version to 3.0.2

What is the Jira issue?
https://issues.apache.org/jira/browse/ZEPPELIN-5802
How should this be tested?

CI

Screenshots (if appropriate)
Questions:

Does the licenses files need to update? N
Is there breaking changes for older versions? N
Does this needs documentation? N

@kkoldduck2 Could you please handle the review?

There was also a change in the zeppelin-web/package-lock.json. This should also be changed back. Related PR: #4437

Oh! I will change it back too! thank you


text:
🛑 InterHop (Website) is down

In be5b4ed, InterHop (Website) (https://interhop.org) was down:

HTTP code: 0
Response time: 0 ms

Resolved: InterHop (Website) is back up in 13441cf after 5 minutes.

license: MIT


text:
Not visible when text is too long

When text is very long. How can we show the full text ?
Right now, it's ending with ... (triple dot)
For ex-
The real text is Coimbatore Chinna Swami Muthu Swami Venu Gopal lyer. But it's showing Coimbatore Chinna Swami Mut...
There is lots of name like this, so all text seems to be same.
Please let me know the solution. Thanks

Better if you add a marquee like function.
please help

repo: apasccon/SearchTextField

license: mit


text:
virtualmachine/vmrun: fix an issue where machines with no display server could not boot VMs.

I also wrapped the output of the vmrun command into the error, so that it's more visible when things fail.

LGTM!

authors: erikh zquestz

repo: apcera/libretto


text:
Improve filtering/prioritization via tj/go-archive

Relies on https://github.com/tj/go-archive/pull/3
Also gives lower presence to .upignore after the UX step; see #84
fixes #50

Ahh interesting, I suppose ideally the ordering alone gives the next node_modules precedence, but if this works that's not bad

hmm seems a little strange that this one requires **, I'm not sure that's the same as GIT

ah damn might have to revert, adding .git should ignore .git/foo etc

yeah - I was just doing extensive testing locally, hold up on this and the other PR

Recap: tj/go-archive#3 allows users to specify only the minimum files to run their api:
* # because we use a wildcard to collect _everything_ to use node_modules in your project add /**
!node_modules/**
!index.js
!package.json

authors: hhsnopek tj

repo: apex/up


text:
Get rid of this pack

Hey,
using this pack will lead to frustrated users because the dependencies are not up to date.
I would recommend users to just copy the contents of the composer.json and put it in their own with adapted versions.

Hi, what dependencies were an issue?

I would recommend users to just copy the contents of the composer.json and put it in their own with adapted versions.

You can use composer unpack api (Symfony Flex).

I cannot reproduce:
$ symfony new test-pack
$ composer req api
$ composer show api-platform/core
> versions : * v2.5.0

It looks ok to me, or am I missing something?

Hey,
seems I ended up on version 2.4.something while reading docs for 2.5...

authors: MLDMoritz dunglas soyuka teohhanhui

repo: api-platform/api-pack


text:
Unable to resolve module events from node_modules/@apify/log/logger.js:

Getting this error Unable to resolve module events from /Users/hubino/Documents/RN_Projects/Homi/node_modules/@apify/log/logger.js:
Is this package supports Expo React native?

Hmm, interesting. events is a Node.js only module, so it makes sense that it's not available in React Native. Interestingly, we've been using apify-client in the browser for quite some time without any problems. I guess Webpack polyfills it for us.
Can you polyfill events in Expo?

authors: karthikeyan-kandasamy mnmkng

repo: apify/apify-client-js


text:
Generic response type on RequestQueue.getInfo()

Now describe the bug
RequestQueue.prototype.getInfo returns Promise<object> instead of a strongly typed response.
To Reproduce
The following will fail to compile because getInfo's response is generically defined.
const { handledRequestCount, totalRequestCount, pendingRequests } = await this.requestQueue.getInfo();

Expected behavior
apify/types/request_queue.d.ts
type QueueInfo = {
    id: string;
    name: string;
    userId: string;
    createdAt: Date;
    modifiedAt: Date;
    accessedAt: Date;
    totalRequestCount: number;
    handledRequestCount: number;
    pendingRequestCount: number;
}

...

getInfo(): Promise<QueueInfo>;

const { handledRequestCount, totalRequestCount, pendingRequests } = await this.requestQueue.getInfo();

System information:

Apify SDK version [e.g. 0.21.0]

Additional context
I'd just augment the types myself and PR, but they're generated via JSDoc comment and I'm unsure where to add the QueueInfo type

Thanks, will fix it in the next release.

Fixed in c777a0ea3c12a1fbafe1a756742d7df4a96e995e

authors: kazazes mnmkng

repo: apify/apify-js


text:
Python Client Hello World Fails with https status of 401 "apify_client._errors.ApifyApiError: User was not found or authentication token is not valid"

TLDR - Hello world python example fails with auth error, debugging http request I don't see my auth token sent anywhere
Hello,
I got an issue with a real apify scraper so I tried the hello world and am getting the same auth error
Thanks,
Ben
See details below:

Code
Response error
debugger output
full traceback

Code:
from apify_client import ApifyClient

# Initialize the ApifyClient with your API token
client = ApifyClient("apify_api_....")

# Prepare the Actor input
run_input = {
    "first_number": 1,
    "second_number": 2,
}

# Run the Actor and wait for it to finish
run = client.actor("apify/python-example").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

Error:
apify_client._errors.ApifyApiError: User was not found or authentication token is not valid

I also did a debugger breakpoint in the _BaseHttpClient() class on line 169 in method _make_request() and have this information below. Biggest thing that sticks out to me is the API token is not sent anywhere? Unless im looking in the wrong spot
(Pdb) request.url
URL('https://api.apify.com/v2/acts/apify~python-example/runs')
(Pdb) request.headers
Headers({'host': 'api.apify.com', 'accept-encoding': 'gzip, deflate', 'connection': 'keep-alive', 'accept': 'application/json, */*', 'user-agent': 'ApifyClient/1.6.2 (darwin; Python/3.11.6); isAtHome/False', 'authorization': '[secure]', 'content-type': 'application/json; charset=utf-8', 'content-encoding': 'gzip', 'content-length': '54'})

Extra info:
Full Traceback
Traceback (most recent call last):
  File "/Users/benshaughnessy/code/py_zillow/apify_test.py", line 13, in <module>
    run = client.actor("apify/python-example").call(run_input=run_input)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/benshaughnessy/code/py_zillow/venv/lib/python3.11/site-packages/apify_client/_logging.py", line 82, in wrapper
    return fun(resource_client, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/benshaughnessy/code/py_zillow/venv/lib/python3.11/site-packages/apify_client/clients/resource_clients/actor.py", line 266, in call
    started_run = self.start(
                  ^^^^^^^^^^^
  File "/Users/benshaughnessy/code/py_zillow/venv/lib/python3.11/site-packages/apify_client/_logging.py", line 82, in wrapper
    return fun(resource_client, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/benshaughnessy/code/py_zillow/venv/lib/python3.11/site-packages/apify_client/clients/resource_clients/actor.py", line 219, in start
    response = self.http_client.call(
               ^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/benshaughnessy/code/py_zillow/venv/lib/python3.11/site-packages/apify_client/_http_client.py", line 195, in call
    return retry_with_exp_backoff(
           ^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/benshaughnessy/code/py_zillow/venv/lib/python3.11/site-packages/apify_client/_utils.py", line 64, in retry_with_exp_backoff
    return func(stop_retrying, attempt)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/benshaughnessy/code/py_zillow/venv/lib/python3.11/site-packages/apify_client/_http_client.py", line 193, in _make_request
    raise ApifyApiError(response, attempt)
apify_client._errors.ApifyApiError: User was not found or authentication token is not valid

Hi @bs7280, thank you for reporting the problem. I tried replicating it with my API token and it seems to be working fine.

Could you confirm if you are using Python 3.8 or a newer version?
Are you using the latest version of apify-client?
Please double-check if you are passing in the token correctly.

Closing it since we haven't received any responses from the questioner. If this is still a problem, let's reopen it.

repo: apify/apify-sdk-python


text:
useIncognitoPages doesn't rotate fingerprints

Which package is this bug report for? If unsure which one to select, leave blank
None
Issue description
If you run the code with incognito pages, you will always get the same browser. If you comment incognito pages and uncomment one page per browser, you will get different user agents.
Code sample
import { Actor } from "apify";
import { PlaywrightCrawler } from 'crawlee';

const proxyConfiguration = await Actor.createProxyConfiguration();

const crawler = new PlaywrightCrawler({
    proxyConfiguration,
    browserPoolOptions: {
        useFingerprints: true,
        // maxOpenPagesPerBrowser: 1,
    },
    launchContext: {
        useIncognitoPages: true,
    },
    preNavigationHooks: [
        async ({ page }) => {
            page.once('request', async (req) => {
                try {
                    const headers = await req.allHeaders()
                    console.dir(headers);
                } catch (e) {
                    console.log('req inspection failed')
                }
            })
        }
    ],
    requestHandler: async ({ request, page, log}) => {
        const text = await page.innerText('pre');
        log.info(text);
    },
});

await crawler.run([
    'https://api.ipify.org?format=json&a',
    'https://api.ipify.org?format=json&b',
    'https://api.ipify.org?format=json&c',
    'https://api.ipify.org?format=json&d',
    'https://api.ipify.org?format=json&e',
    'https://api.ipify.org?format=json&f',
]);

Package version
3.7.2
Node.js version
18
Operating system
MacOS
Apify platform

[ ] Tick me if you encountered this issue on the Apify platform

I have tested this on the next release
No response
Other context
No response

Seems like a sign of a much larger underlying issue:
New sessions / fingerprints / proxyUrls are generated only on a browser launch.
The following snippet doesn't rotate the fingerprints correctly - all requests are done with one session only. This is because the useIncognitoPages was written with Playwright contexts in mind - we relied on the "newPage() creates a separate environment" invariant, so all the pages/contexts are launched in one browser.
sessionPoolOptions: {
    sessionOptions: {
        maxUsageCount: 1,
    },
},
launchContext: {
   useIncognitoPages: true,
},

The following snippet rotates the fingerprints correctly:
sessionPoolOptions: {
    sessionOptions: {
        maxUsageCount: 1,
    },
},
launchContext: {
   useIncognitoPages: false,
},

This works well because an "expired" session throws away the whole browser instance, causing the new pages to launch a whole new browser (see the parallel with the maxOpenPagesPerBrowser, which does the same thing). This is crazy expensive though, while launching and closing a context 100 times in one browser takes ~3.9 seconds, launching and closing a browser 100 times takes 40 seconds.
The entire browser-pool and session rotation logic is quite convoluted and worth a total rewrite.

authors: barjin mnmkng

repo: apify/crawlee


text:
build: add missing transitive deps

This PR fixes the errors thrown by yarn 4 when using crawlee in another project.

Thanks for the fast feedback. Crawlee is really great!


text:
一些问题或意见

1.参数是实体的话不显示参数呢
2.返回值好像也不展示。
3.检验，默认这个是通过什么来描述

接口参数如果是boolean类型的话，解析出来的文档不显示该参数呢

返回数据最多显示多少层数据呢，多深
{
"code" : 0,
"message" : "",
"data" : {
"current" : "1",
"size" : "20",
"total" : 0,
"pages" : 0,
"list" : [ ]
}
}
返回值list里面的对象显示不出来

repo: apigcc/apigcc-maven-plugin


text:
Refactor 'name' field to ID on style guide and manifest proto definition

Summary
In the registry, the convention that we use is that name fields are typically given to resource names. A resource name is one that matches: projects/{project_id}/locations/{location}/apis/{api}/versions/{version}/specs/{spec}/artifacts/{artifact}.
However, in the case of manifests and style guides, the name field is actually being used as an identifier rather than an actual resource name. Thus, we should correct our terminology and call them what they really are, ids.
Test
Existing unit tests should pass. There is no extra manual test that needs to be done, since all of the tests pertaining to this are automated.

Look good.
Can you update the manifest defined here as well? https://github.com/apigee/registry/blob/main/tests/controller/testdata/manifest.yaml
This doesn't show up in the tests, but is used as part of an end-to-end walkthrough

Done!

@muhammadharis thank you!

authors: muhammadharis timburks

repo: apigee/registry


text:
Consider adding more specific uncertainty fields to SonarRanges

@valschmidt says:

Two fields that might be added are travel time uncertainty and beam pointing angle uncertainty. Admittedly most sonars do not report these values directly, but it is where all other uncertainty values are derived. I admit this is tough one. Reson reports depth uncertainty as a fraction of the depth measurement for the beam. Kongsberg reports uncertainty in x, y and z. When they are not otherwise provided, to a first approximation one can assume the beam pointing uncertainty is zero and calculate the range uncertainty as sigmaR = sin(beam_pointing_angle) * sigmaZ. But maybe this is too much to provide guidance for. In any event, it is really useful to provide an estimate of the uncertainty in the soundings if possible. I’m happy to talk more about this one if you want.

This can get really complex. The process of getting from travel time and beam pointing uncertainty to sounding uncertainty is not as simple as propagation of the uncertainty through a rotation because of the refraction involved. [Also sometimes the transmitted signal has to be ray-traced separately from the receive signal, but I won't even go there.]
I wonder if this topic might deserve a REP to take the time to explain some of these details and some simplifying assumptions that can be made that will work for most people, as well as the conventions used by these messages. And then define the message definitions that make those assumptions.
The simplifying assumptions with regard to uncertainty I would suggest:

There is no refraction, or alternatively, the errors caused by refraction are neglected. For folks doing deep water mapping there is little to no sound speed variability (except maybe near vents) and this assumption is pretty valid.
The uncertainties in range and angle are small, such that standard, first order, linear, "propagation of variance" calculations are sufficient to propagate uncertainty, as is usually done in robotics.

Beam width can cause angular uncertainty in the detection when the range to an object varies over the size of the beam. This can be hard to quantify unless you know the object ahead of time. For the seafloor that is guaranteed to extend across the whole of the beam, it is given by
sigma = d [ 1 - cos (bw/2)]
where sigma is the 1-sigma depth uncertainty due to this effect, d is the depth to the detected seafloor detected at the edge of the beam (the worst case), and bw is the beam width of the beam. Typically the only beam width that is considered is the along-track beam width, because in the across track direction, detections are made using the split beam phase method which can resolve detections within the beam. Technically amplitude detections suffer from this uncertainty in both along-track and across-track directions, but it's usually neglected.
-Val

Thanks for the reply @valschmidt. Based on your experience do you have a suggestion for what messages the sensor should report.   I think it's important that we keep the fields in the message as close to what's reported by the sensor as possible.
From your comments it looks like angular uncertainty is pretty negligible relative to beam width.   2 way travel time doesn't seem to be a big factor in the uncertainty according to your equation but it may be reported by the sonar.
Therefore I propose this:

only report in the 2-way-travel-time uncertainty in the message.
From there leave it to the MBESmsg to Pointcloud converter to handle the uncertainty analysis based on 2 way travel time and beam widths.

I think this method removes most assumptions from the message itself for data logging purposes.
What do you think?
-Kris

authors: CaptKrasno lauralindzey valschmidt


text:
Requests that return HttpDuplex (eg docker exec start) hang when using named pipe on windows.

Found an interesting situation that i was able to track down a bit. I am unsure if this is a bug with docker-modem or potentially how Docker for Windows sets up the named pipe to begin with.
Here is a file to reproduce (uses latest node-docker-api but upgraded to docker-modem 1.0.0), the same thing happens if you use analogous code for dockerode
'use strict'
const Docker = require('node-docker-api').Docker

const promisifyStream = (stream) => new Promise((resolve, reject) => {
  stream.on('data', (d) => console.log(d.toString()))
  stream.on('end', () => {
      if (process.stdin.setRawMode) {
        process.stdin.setRawMode(false);
      }
      process.stdin.pause();
      resolve()
  })
  stream.on('error', reject)
})

var thing
const docker = new Docker({ socketPath: '//./pipe/docker_engine' })
//const docker = new Docker({host: '127.0.0.1', port: 2375})
let _container

  docker.container.create({
    Image: 'debian:jessie',
    Cmd: [ '/bin/bash', '-c', 'tail -f /var/log/dmesg' ]
  })
  .then((container) => container.start())
  .then((container) => {
    _container = container
    return container.exec.create({
	    AttachStdin: true,
	    AttachStdout: true,
	    AttachStderr: true,
	    Cmd: ['echo', 'thing'],
	    Tty: true
    })
  })
  .then((exec) => {
    return exec.start({
      hijack: false,
      Detach: false,
      Tty: true,
      stdin: true,
    })
  })
  .then((stream) => {
  	thing = stream
  })
  .then(() => {
  	thing.pipe(process.stdout);

  	// Restart stdin with correct encoding
  	process.stdin.resume();
  	process.stdin.setEncoding('utf8');

  	// Make sure rawMode matches up
  	if (process.stdin.setRawMode) {
  	  process.stdin.setRawMode(true);
  	}

  	// Send our processes stdin into the container
  	process.stdin.pipe(thing);

  })
  .then(() => promisifyStream(thing))
  .then(() => _container.delete({force: true}))
  .catch((error) => console.log(error))

If you connect over tcp (need to allow insecure connections in the docker for windows app first), it works as expected but if you switch over to the named pipe it will hang after "thing" is written to stdout. What is extremely interesting is after this happens you can get the stream to close and the process to resume by pressing any key three times.
Another interesting data point here is it looks like docker-compose itself avoids using the API for this on Windows, deciding to just delegate directly to a shell call to docker exec.
see: https://github.com/docker/compose/blob/master/compose/cli/main.py#L411
My best guesses at this point are:

there is is some additional buffer with named pipes that is not being correctly flushed and its causing things to hang up
writes are not happening or getting lost duringish reads

Any thoughts about why this could be happening?

Hi, I'm most likely running in to the same problem with Dockerode 2.5.4 which relies on Docker-modem 1.0.4 . Anything with exec.start gets stuck and won't terminate properly.

docker desktop 4.12 has a compatibility shim that should fix this.
https://docs.docker.com/desktop/release-notes/#bug-fixes-and-minor-changes
see my comments about it here: https://github.com/apocas/dockerode/issues/534

authors: JoonasVali nicks pirog

repo: apocas/docker-modem


text:
GraphQL Subscriptions with WebSocketServer "graphql-ws"

Is there a way to handle Graphql subscriptions with this package?
For example using this package: graphql-ws
Or it is meant to run only Queries and Mutations?

Please see #127, #110, #100, #91, #74

authors: huesoskywalker martinnabhan


text:
[Normalized Cache] bump SqlDelight version

See https://github.com/apollographql/apollo-android/issues/2504
SqlDelight 1.4.0 introduced an incompatible change with 1.3.0. Bumping the version at least gives a path forward. It doesn't solve issues if another dependency is compiled against 1.3.0 but if all dependencies update to 1.4.0, the problem should disappear.

Corresponding SQLDelight issue: https://github.com/cashapp/sqldelight/issues/1865
I'm not sure a hotfix is worth the hassle given that it won't retroactively fix any lib compiled against 1.3.0. What I'm hoping is that most SQLDelight usages are from app modules and not through transitive dependencies (like is the case here)... Then this issue should not stick too long.

repo: apollographql/apollo-android


text:
Improve the usage documentation for maintainers

So some issues that I encountered when I was trying to check for spec compliance locally, that I think should be addressed to help other maintainers with their implementations.

There aren't very clear instructions on how to run everything without docker. Usually when I am testing this I am just trying to get it to run with a local instance so that I can verify the fixes that go into caliban, so I don't really want to have to deploy and run docker. There are scripts for running the user and inventory graphs, but the script for running the gateway doesn't point to a real directory (also I had to change the paths of the subgraphs because they point to dist folders that don't get built).
The testing schemas appear inconsistent, the required one is this but the one in the reference for graphql-yoga is this
There should probably be a step to have the implementation generate the schema, at the moment it is just sitting alongside the implementation but the two could be completely different.

Great feedback @paulpdaniels, thanks! We'll be working on this shortly.

Hello 👋
I've added docs on how to run local instances without docker in https://github.com/apollographql/apollo-federation-subgraph-compatibility/pull/168

The testing schemas appear inconsistent, the required one is this but the one in the reference for graphql-yoga is this

With the recent changes to the test schemas we are now run better checks to ensure that subgraph schemas are correct.

There should probably be a step to have the implementation generate the schema, at the moment it is just sitting alongside the implementation but the two could be completely different.

We compare the schemas returned form the _service { sdl } query which is used by federation. Functionality is verified by running queries testing specific features against expected data set.

We are always looking for feedback to make this repo better. Feel free to open new issue/s to better track outstanding problems. Contributions are always welcome!

authors: dariuszkuc hwillson paulpdaniels


text:
schemaBased test builders

When working with Jetpack Compose @Preview, faking data is useful in the main source set while currently, the test builders are only generated for the test source set by default. This can be overriden but it's not straightforward. Also because the current test builders are responseBased, they generate a fair amount of code, not to mention that specific code is generated for each and every operation.
Instead, we could generate schemaBased test builders only once and add them to the main source set. For a query like this:
query HeroName {
  hero {
    name
  }
}

generate a fake model like this:
// pseudo code, not sure this can work exactly like this
val data = buildFakeData<HeroName> {
  hero = humanHero {
    name = "Luke"
    // Here it's not really type safe but that's certainly OK for fake models
    height = 180
  }
}

We could even enable strict mode so that errors are caught at runtime: see https://github.com/apollographql/apollo-kotlin/issues/3344

Current proposal for generated code:
class HeroQuery {
  class Data(val hero: Hero) {

  }
  class Hero(val name: String)

  companion object {
    fun Data(block: QueryBuilder.() -> Unit): Data {
      // Code goes here
    }
  }
}

class AliasedProperty(val alias: String, val map: MutableMap<String, Any?>) {
  infix fun to(value: Any) {
    map[alias] = value
  }
}

@Suppress("PropertyName")
abstract class ObjectBuilder {
  protected val __map = mutableMapOf<String, Any?>()

  var __typename: String by __map

  fun alias(alias: String): AliasedProperty {
    return AliasedProperty(alias, __map)
  }
}

class QueryBuilder: ObjectBuilder() {
  var hero: Character? by __map

  fun build(): Query {
    return Query(__map)
  }
}

fun buildQuery(block: QueryBuilder.() -> Unit): Query {
  val builder = QueryBuilder()
  builder.__typename = "Query"

  builder.block()

  return builder.build()
}

class Query(map: Map<String, Any?>): Map<String, Any?> by map

class HumanBuilder: ObjectBuilder()  {
  var name: String? by __map

  var height: Double? by __map

  fun build(): Human {
    return Human(__map)
  }
}
fun buildHuman(block: HumanBuilder.() -> Unit): Human {
  val builder = HumanBuilder()
  builder.__typename = "Human"

  builder.block()

  return builder.build()
}

class DroidBuilder: ObjectBuilder()  {
  var name: String? by __map

  var primaryFunction: String? by __map

  fun build(): Droid {
    return Droid(__map)
  }
}

fun buildDroid(block: DroidBuilder.() -> Unit): Droid {
  val builder = DroidBuilder()
  builder.__typename = "Droid"

  builder.block()

  return builder.build()
}

interface Character
class Human(map: Map<String, Any?>): Character, Map<String, Any?> by map
class Droid(map: Map<String, Any?>): Character, Map<String, Any?> by map

HeroQuery.Data {
  hero = buildHuman {
    name = "Luke"
    height = 1.7
  }

  alias("hero1") to buildDroid {
    name = "c3pO"
    primaryFunction = "translation"
  }
}

Will be available in 3.6.0

repo: apollographql/apollo-kotlin


text:
How to import ConnectionRecordMerger

Question
I'm currently trying to implement pagination and would like to realize cache merging. I've been implementing this based on the file below, but I can't find ConnectionRecordMerger.
https://github.com/apollographql/apollo-kotlin/blob/main/tests/pagination/src/commonTest/kotlin/CursorBasedPaginationTest.kt#L54

Can't I import ApolloExperimental?
memo:
https://github.com/apollographql/apollo-kotlin/blob/7690bf5c06b6469228f899380c6fc9f7a3ee910f/apollo-normalized-cache-api/src/commonMain/kotlin/com/apollographql/apollo3/cache/normalized/api/RecordMerger.kt
https://github.com/apollographql/apollo-kotlin/blob/main/tests/pagination/src/commonTest/kotlin/CursorBasedPaginationTest.kt#L54
https://github.com/apollographql/apollo-kotlin/releases/tag/v3.4.0

You probably need to import apollo-normalized-cache-incubating instead of apollo-normalized-cache

Thanks!!
I solved it.
    implementation "com.apollographql.apollo3:apollo-normalized-cache-incubating:$gradle.ext.apollo3"
    implementation "com.apollographql.apollo3:apollo-normalized-cache-sqlite-incubating:$gradle.ext.apollo3"
    // implementation "com.apollographql.apollo3:apollo-normalized-cache:$gradle.ext.apollo3"
    // implementation "com.apollographql.apollo3:apollo-normalized-cache-sqlite:$gradle.ext.apollo3"

Heads up this is (as the name implies) pretty much incubating. I'm pretty sure the performance isn't great and I wouldn't use that in production (contrary to alphas 😄 ). It's mostly a test bed to gather feedback and iterate on API design. If you have any feedbacks abuot the ergonomics, please let us know!

OK. I plan to only use 'incubating' for testing, not in a production environment. Currently, our pagination code is not clean, but  it's working, so there's no problem. First, I'll test it, and then I plan to refactor it again after the official release.
In our pagination code, we hold the values to paginate as a list in the Jetpack Compose state. However, we want to replace the state with a cache.

authors: martinbonnin sonatard


text:
non-global dataIdFromObject?

When I write an implementation for dataIdFromObject, it seems like if I have two entities with the same ID that they'll end up at the same place in the store. Is there a way to implement a non-global dataIdFromObject function? Or alternatively have access to the path for the data so that that can be considered when assigning an ID?

dataIdFromObject is specifically to tell apollo client that two objets with different paths are actually the same. If you don't want that, you can just not assign it an id, in which case apollo client will use the path.

@helfer I understand that, but the problem arises when you have two entities that have the same ID, but are different.
For example, if I make a query for a user with ID 1:
user(id: 1) {
  id
  name
}

And then make a query for a message with ID 1:
message(id: 1) {
  id
  from
  to
}

The dataIdFromObject isn't able to distinguish between these two, which are separate entities, but with the same ID.

@kesne ah, I see. In that case you want to make sure to include __typename and use a combination of __typename and id for the globally unique id by providing the dataIdFromObject argument to the ApolloClient constructor: dataIdFromObject: obj => obj.__typename + obj.id or something like that.

@helfer That's pretty unfortunate. It seems less than ideal to require adding __typename to every query to get entity mapping working. It seems like this situation would be a common one based on how most people store their data?

@kesne Right now you can use queryTransformer for that, but we have an open PR that changes it to addTypename, and it will be true by default, so you won't have to add __typename to every query.

authors: helfer kesne

repo: apollostack/apollo-client


text:
Version 0.6

This PR is for version 0.6 of Apollo Client, with the following breaking changes planned. Changes will be made in separate PRs using this branch as the base.

[x] Remove fragment support
[ ] Refactor error handling to go through observer.next and no longer use observer.error
[ ] deep freezing of results in development mode
[ ] ... ?

And #1069 ? :))))

And https://github.com/apollostack/apollo-client/pull/1041 :))))

what about exposing mockNetworkInterface?

@kamilkisiela If you have time to update the PR today, I could merge it into the zero-decimal-six branch!

@makstr I think there's a PR by in the works, but it doesn't look like it will be ready in time for 0.6

@helfer Expect it done in couple of hours!

@kamilkisiela rollup now prints a bunch of info/warnings to the command line. Is there any way to suppress that?

@helfer Not sure if it's possible but I will try though.
One thing, since we completely removed lodash, I'm going to create another PR to get rid of my work around making lodash to work with rollup, mocha etc. So wait for it before merging :)

@helfer Done, I will wait for Uri to release it.
I really like the communication from past two days! All the changes goes smooooth

authors: helfer intellix kamilkisiela makstr


text:
Need some improvement on the background image of home page by adding light transition effect.

Description
To make this website more responsive and attractive, I can add some transitions on the background by working on the image and its CSS. Please assign it to me.

Screenshots
No response
Additional information
No response

@aasthagracy No need
Find another improvements in functionality

authors: aasthagracy apoorvaron

repo: apoorvaron/Shorty


text:
JWT Auth - To be added

Hello @DharmikUnagar,
Please add the JWT Auth on top of the latest version.

Fixed! Ty @DharmikUnagar
Closing

repo: app-generator/react-horizon-ui-chakra


text:
Add availability zone to vpc request subnets

I've noticed that when we create a subnet we generaly provide a availability zone, so I'm adding this to the vpc-request schema.

One example of how this is going to look like:
subnets:
  public:
  - availability_zone: us-east-1a
    cidr_block: 10.107.0.0/24
  - availability_zone: us-east-1b
    cidr_block: 10.107.1.0/24
  private:
  - availability_zone: us-east-1c
    cidr_block: 10.107.2.0/24
  - availability_zone: us-east-1d
    cidr_block: 10.107.3.0/24

repo: app-sre/qontract-schemas


text:
adds latency metrics

npm package:
https://www.npmjs.com/package/express-prom-bundle

cc @aditya-konarde @rporres

jenkins build is failing:
npm ERR! peer dep missing: prom-client@^12.0.0, required by express-prom-bundle@6.0.0
Traceback (most recent call last):
  File "/coreapi/main.py", line 168, in <module>
    main()
  File "/coreapi/main.py", line 152, in main
    request_id = run_sa_post(gateway_url, gateway_user_key)
  File "/coreapi/main.py", line 79, in run_sa_post
    if generate_deps_file(ecosystem, manifest) is None:
  File "/coreapi/main.py", line 35, in generate_deps_file
    out = sp.check_output(command, shell=True)
  File "/usr/lib64/python3.6/subprocess.py", line 356, in check_output
    **kwargs).stdout
  File "/usr/lib64/python3.6/subprocess.py", line 438, in run
    output=stdout, stderr=stderr)
subprocess.CalledProcessError: Command 'cd /coreapi/repo; npm install; npm list --prod --json > npmlist.json' returned non-zero exit status 1.
Build step 'Execute shell' marked build as failure
Setting status of 43cc0817cd73ccedf2c865ffdf1f646ffbba45dd to FAILURE with url https://ci.ext.devshift.net/job/app-sre-qontract-server-gh-pr-check/27/ and message: ' '
Using context: ci.ext.devshift.net PR build
Finished: FAILURE

I have rebased a lot of things, so I'm closing this PR and submitting a new one.

authors: jmelis rporres

repo: app-sre/qontract-server


text:
chrome ext

https://chrome.google.com/webstore/detail/dejavu/jopjeaiilkcibeohjdmejhoifenbnmlh
open error 404

@siaron thank you for reporting this
There are some changes in chrome extension store policies, we are working on it.
This should be fixed soon!

any other way to try this out? doing a PoC at the moment and stuck here.

@Rathna-K You can try via https://dejavu.appbase.io.

yes but i am trying it with the local elasticsearch instance inside debian console. anyway to download this as a package or is there a way to download the chrome extension in developer mode?

@Rathna-K You can use Docker Hub: https://hub.docker.com/r/appbaseio/dejavu to get Dejavu locally.

Any chance to get back in the chrome store or provide us with an installable bin? Installing docker just to get this plugin is not really an option for me ...

Really sad this is not in Chrome store anymore. Our new data analysis team wants it but don't have ability to run their own infrastructure :(

@siberian1967 It's still available in a hosted form at dejavu.appbase.io.

@siberian1967 It's still available in a hosted form at dejavu.appbase.io.

But that only work for clusters reachable from the internet, doesn't it?

This is a fair point. Maybe we should bring it back.
For now, I'm closing the issue as the extension isn't available and we've also removed all references to it from README.

authors: Rathna-K freddiN lakhansamani siaron siberian1967 siddharthlatest

repo: appbaseio/dejavu


text:
Makes passed style props additive rather than replacing in tooltipbutton

Working on components for snoop-doc revealed that style props passed in would overwrite an existing style prop necessary for properly handling disabled state.
This change makes the passed in style props complement, rather than overwrite the existing behavior

Thanks! Just one thing, your commit needs to follow conventional commits so the version gets bumped automatically:
https://github.com/appfolio/react-gears#commit-messages

authors: JeremyRH KjWhal

repo: appfolio/react-gears


text:
spread operator being used on buttons, buttons aligned right, and UL element now wraps around the list items.

fixes #22 #23 #27

Looks good - only thing is prefix the list items alternative colors class

+1

repo: appitierre/aptr-uikit


text:
fix error for v1.5 not supporting name selector

fix the error since Appium v1.5 not supporting name selector strategy any longer.

Awesome! Thanks!

repo: appium/sample-code


text:
when cancelling a job in web interface, please take me back to the jobs listing

Cancelling many jobs via the web interface is tedious because every time I cancel one, the Cups browser takes me to a new page. The new page only contains a message saying that the job was cancelled. I would prefer for the Cups browser to just reload the jobs listing, perhaps with this 'job cancelled' message going on top of the listing, so that I can cancel multiple jobs without having to hit "back" each time. Thanks.

Also, I notice there are other places where the web interface has similar issues, for instance when I select "Administration > Set Default Options", then click the button "Set Default Options", a new page loads saying
Printer [printer name] default options have been set successfully.

After a few seconds, this page redirects to the printers page. Such UI design is disorienting and unconventional. I think users would prefer and expect that clicking the "Set Default Options" button should keep them on the same page. It's easy enough to indicate that the options have been set successfully via a header on this page. This would be especially preferable since the options come in three groups, "General", "Banners", and "Policies"; a user who modifies an option under "General" would probably want to click on the other two groups to see what else might need to be changed. Instead he is taken somewhere else, and has to hit the "Back" button.

Will bring this up with our HI folks but don't expect any quick changes (if we make any - the web interface is not a high priority and isn't intended as the primary UI...)

just curiosity: what is the intended primary UI?

@jgrumboe The OS-supplied UI is primary, the web UI is a "backup" for remote admin (and one that we'd very much like to get rid of)...
After review, we've decided that we are not going to address this specific issue...

@michaelrsweet thx for your answer.
Sad to hear that you wanna get rid of the web-ui. I do understand that for client/desktop usage of CUPS it is not important and that a OS-supplied UI is available.
But what about central CUPS printservers, where the support-team has no linux/cmdline knowledge (or either access) and a web UI is "mission-critical"?

@jgrumboe We are constrained by the HTTP server capabilities of cupsd and the security issues that come with using a single server to manage both web and IPP traffic. For now we've adopted a "disabled by default" policy, but longer term we want a different solution for headless servers.
Personally I'd prefer to see a CUPS web interface running from Apache (or some other dedicated web server) that can also serve as a front-end for other management interfaces (Mailman, etc.) typically provided with servers.

@michaelrsweet OK, the plan sounds good and i do understand your concerns with managing web and IPP traffic.
Do you know any web-interface replacement running on Apache/... (outside of cupsd)?

I know of some NAS solutions that have some basic CUPS support in them, but otherwise no.
(FWIW, the CUPS web interface isn't going away soon, but we also are not investing a lot of development effort into it - bug fixes and simple changes only)

authors: archenemies jgrumboe michaelrsweet

repo: apple/cups


text:
why isn't the "CUPS Software Administrators Manual" part of the official documtentation...

at least i didn't find it on the "cups.org"-website.

It was replaced by a set of smaller help files many years ago.

authors: michaelrsweet utonsal


text:
Fix lifetime issues in tests

A number of tests were failing with the -Onone lifetime changes.
Regardless of what happens with that change, I'd like to keep our tests
passing with the stricter rules since we also test in release builds.

@swift-ci please test

repo: apple/sourcekit-lsp


text:
Fix uses of deprecated non-throwing AbsolutePath.init

These warnings appeared after an update to TSC deprecated this initializer.

@swift-ci test

@swift-ci test macOS

@swift-ci test

@swift-ci test


text:
[SR-6581] Mark FileManager.attributesOfFileSystem unavailable on Android

Fixes SR-6581.

@ruipfcosta Can you note in the comment that this fixes SR-6581 at a minimum?
@swift-ci Please test.

What was the problem with Android here, specifically? It has no way to retrieve this info?

Android was #if'ing just this method to crash — I'm not sure what to do here, but the correct outcome would be that someone implement the Android version of this method.
In the meantime, I wanted to make this apparent to clients rather than not

(It would be real weird if Android couldn't do the equivalent of stat(), though, honestly.)

Looks like a similar change already went in.

authors: millenomi parkera ruipfcosta

repo: apple/swift-corelibs-foundation


text:
TestFoundation: make xdgTestHelper build on Windows

Windows does not have kill but it does have TerminateProcess.  This
utility is poorly named at this point and is used as a test helper
utility rather than XDG helper specifically.

CC: @millenomi @spevans @gmittert

@swift-ci please test

authors: compnerd millenomi


text:
[wasm] Port use of dirent for wasi-libc

wasi-libc defines d_name as "flexible array member" which is not supported by ClangImporter yet. This patch replaces the use of d_name with a helper function _direntName to work around the issue.

@swift-ci test

This doesn't seem to be exclusive to WASI #if branches, so I'll defer to @parkera.

authors: MaxDesiatov kateinoigakukun


text:
Remove obsolete AnyObject cast

This cast is no longer needed, and produces a warning indicating that it always succeeds.

@swift-ci Please test

repo: apple/swift-corelibs-xctest


text:
ActorAddress: Paths become ActorTags and use them for DAs

This is a great first step ticket and could be picked up by a motivated contributor at any time.
It would greatly unlock the "remove tree" work.

What:
When we spawn we take a name today:
spawn(naming, ...)
This name is stored in the Actor's ActorAddress
This ticket:

keep it there but also introduce a field ActorTags which is a dict from actorTagID (UInt8) to Any OR String? not sure yet...
when we spawn, store a .name = name in the tags
implement the actor's .name and similar using this rather than delegating to the address

Eventually the address can then become an ActorID based one, and thus not have the name/path at all.

Relates to the ancient https://github.com/apple/swift-distributed-actors/issues/479 but I don;'t think this is so large as that other issue mentions

Paths as tags is implemented, but more cleanup to follow

repo: apple/swift-distributed-actors


text:
Fix DA/ClusterSystem retain cycles - system actors cannot be strong retained; release them on shutdown

We weakened the actors holding it only via a weak yet should investigate more what could hold it more than necessary.
See https://github.com/apple/swift-distributed-actors/pull/565 and https://github.com/apple/swift-distributed-actors/pull/322

Implemented an actor leak detector:

Test Case '-[DistributedActorsTests.ClusterDiscoveryTests test_discovery_shouldInitiateJoinsToNewlyDiscoveredNodes]' started.
DistributedActorsTestKit/ClusterSystemXCTestCase.swift:60: Fatal error: !!!!!! DETECTED LEAKED ACTORS: 3 !!!!
BEFORE ============================================
NOW ===============================================
DistributedActors.OpLogDistributedReceptionist
  - count: 1
  - ids: ["0x11f70f380"]
DistributedActors.ClusterEventStreamActor
  - count: 1
  - ids: ["0x1281089e0"]
DistributedActors.ClusterControl.(MembershipHolder in _1E7381868A8BFB9E946FBA4168BEE1E3)
  - count: 1
  - ids: ["0x600003cc0180"]
DIFF ==============================================
DistributedActors.OpLogDistributedReceptionist
  - count: 1
  - ids: ["0x11f70f380"]
DistributedActors.ClusterEventStreamActor
  - count: 1
  - ids: ["0x1281089e0"]
DistributedActors.ClusterControl.(MembershipHolder in _1E7381868A8BFB9E946FBA4168BEE1E3)
  - count: 1
  - ids: ["0x600003cc0180"]
DIFF ==============================================
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

`// TODO: Enable and fix leaks; today we have reference cycles between system actors and the system that don't get broken

See InspectKit https://github.com/apple/swift-distributed-actors/pull/1055/commits/9cc0673606a0bab34cf121186fb790b669ba14d9


text:
Compatibility updates to reflect the toolchain symlink removals

swift-indent hasn't been included in toolchains for a while now, so remove all references to it.
swift-autolink-extract was removed from macOS toolchains fairly recently, so #if-out the linux linker tests that rely on it on macOS.

@swift-ci test

@swift-ci test

repo: apple/swift-driver


text:
Adds support for case insensitivity

We don't want to do this all through consumer functions, but this allows for case insensitive matching throughout.

@swift-ci Please test

@swift-ci Please test


text:
Add convenience initializer for RuleResult

Make RuleResult conform to Equatable.
Destroy owned build keys when destroying rule result.
rdar://50298961
This is some independent pre-work done for https://github.com/apple/swift-llbuild/pull/525

@swift-ci please smoke test

@swift-ci please smoke test

@swift-ci please smoke test

repo: apple/swift-llbuild


text:
[Reproducers] Add a bridging header test

Add a test that ensures we can reproduce Swift programs that use a
bridging header.

@swift-ci please test with https://github.com/apple/swift-lldb/pull/1734

https://github.com/apple/swift-lldb/pull/1734
@swift-ci please test

repo: apple/swift-lldb


text:
Fix TestAttachDenied on macOS Mojave

TestAttachDenied tries to attach to a process that is ptracing itself and
verifies that we error out. Starting with macOS Mojave, processes need
an entitlement to be able to ptrace. This commit adds the entitlement for
the test binary when building on Darwin.
git-svn-id: https://llvm.org/svn/llvm-project/lldb/trunk@337029 91177308-0d34-0410-b5e6-96231b3b80d8

@swift-ci test and merge


text:
Fix request and response translation

Motivation
Fix the translation between Foundation types and HTTP types.
Modifications
The code is mostly borrowed from swift-http-types:
https://github.com/apple/swift-http-types/tree/main/Sources/HTTPTypesFoundation
Translates the string encoding (URLSession expects ISOLatin1) and handles multi-value fields.
Result
Should address the cookie issue among other issues.
Test Plan
All existing tests still pass.

Change looks great, thank you @guoye-zhang!
Do you think we can extend the tests to cover the different delimiter appending logic based?

I updated the test with multiple values. ; joining is already tested by the cookie header.

@swift-server-bot test this please

@swift-server-bot add to allowlist

The failed CI is a transitive infra issue, rekicking.

@swift-server-bot test this please

authors: czechboy0 guoye-zhang simonjbeaumont

repo: apple/swift-openapi-urlsession


text:
[PackageGraph] Filter unversioned pins before running the debug algo

rdar://problem/39616386 Crash under BasePackageContainer.versions(filter:)
https://bugs.swift.org/browse/SR-8177

@swift-ci test with toolchain

Need to add a test

@swift-ci please smoke test

repo: apple/swift-package-manager


text:
[runner.py] Fix args passed via --add-xcodebuild-flags not being concatenated properly

They were being concatenated without adding a leading space to separate them
from the preceding arguments, breaking some project builds.
Also updates the xfails for run_sk_stress_test now that the broken projects are building, and for some recent fixes.

@swift-ci please test

repo: apple/swift-source-compat-suite


text:
Revert "Handle pattern as editor placeholder"

Reverts apple/swift-syntax#2150
Part of https://github.com/apple/swift-syntax/issues/2178

@swift-ci please test

@swift-ci Please test macOS

@kimdv Could you cherry-pick this to release/5.10? I just noticed that https://github.com/apple/swift-syntax/pull/2150 made it into release/5.10 but this PR didn’t, which means that currently release/5.10 has EditorPlaceholderPatternSyntax.

authors: ahoppen kimdv

repo: apple/swift-syntax


text:
missed optimization opportunity for elimination of retain/release and tail recursion

Describe the bug
Unnecessary retain/release seem to be inhibiting tail recursion optimization in
var leftMost: Expr { args.count == 0 ? self : args.first!.leftMost }
final class Expr {
    unowned(unsafe) var parent: Expr? = nil
    var args: ContiguousArray<Expr>
}

To Reproduce
Compiling the above generated a recursive function with retain/release around each step.
Expected behavior
I expected the retain/release to be optimized away and the recursive call to be reduced to an iteration.
Environment (please complete the following information):

OS: 12.3.1 (21E258)
Xcode 13.3.1 (13E500a)

Additional context
(I think I checked this in a previous version of Xcode about a year ago, and at that time the compiler did do a tail recursion optimization, so this behavior may be a regression. However, my memory may be faulty confusing this with something else, and I can't remember which previous compiler version to check against.)
Discussion and disassembly are at https://forums.swift.org/t/arc-tail-recursion/57054
Writing the function without the tail recursion still leaves the retain/release around each step.
    var leftMost: Expr {
        var expr = self
        while expr.args.count > 0 { expr = expr.args.first! }
        return expr
    }

Jordan Rose writes at https://forums.swift.org/t/arc-tail-recursion/57054/7

Swift will not let you do anything with a value without it being retained, or without a promise that someone else is retaining it in the mean time. There aren't many generally supported ways to spell the latter if it can't be inferred from the structure of the code.
In this case, the code in question is enough to guarantee that, since the compiler can see that indeed no mutations can happen at all here. So I'd say this is a missed optimization opportunity and leave it at that.

The first problem is that the compiler in Xcode 13.3 does not inline the ContiguousArray.subscript getter co-routine.
That seems to be fixed on main.
But the retain-release pair around the recursive call is still there and we need to improve inter-procedural side-effect analysis to be able to handle this. Not sure why and if an older compiler could optimize this.
rdar://93912198

authors: RonAvitzur eeckstein

repo: apple/swift


text:
Sovler-based cursor info is reporting refactorings that aren’t applicable with AST-based refactoring implementation

The solver-based cursor info reports rename refactorings based on whether it resolved the current item. But since the refactoring itself uses the AST-based implementation the refactoring might not actually be applicable. We probably need to still run the AST-based implementation for cursor info to tell if rename is actually available.
The proper solution here would probably be to create two requests: One that just returns the cursor info and another one that returns the available refactorings. The latter could then use the AST-based implementation while the former is purely solver-based.

The local refactoring action has been removed but the underlying issue probably still persists when getting local rename ranges.


text:
[AST Verifier] Don't verify parsed function bodies in a type-checked AST

Eliminates an AST verifier crash on reasonable ASTs where we ended up
synthesizing the body for a function (e.g., from the Clang importer)
that we don't actually need to type-check. Fixes
rdar://problem/32774779.

@swift-ci please smoke test and merge


text:
[Syntax] Serialize top level decls as an array

Previously the syntax serialization test printed each top-level decl individually. This now prints them as an array of top-level decls.

@swift-ci please smoke test

@swift-ci please smoke test


text:
[Migrator] Make sure to lowercase properties in SetterToProperty

Previously we were only stripping set from the name and not
lowercasing the property.
rdar://problem/32845968

@swift-ci Please test

@swift-ci Please test

@swift-ci Please test

Build failed
Jenkins build - Swift Test OS X Platform
Git Commit - 35d7b6e7da8bea9957b753b21f89c00cc479282a
Test requested by - @bitjammer

Build failed
Jenkins build - Swift Test Linux Platform
Git Commit - 35d7b6e7da8bea9957b753b21f89c00cc479282a
Test requested by - @bitjammer

authors: bitjammer swift-ci


text:
[docs] Linkify Driver.md

Convert references to other documentation pages in docs/Driver.md into links.
GitHub supports relative links, I believe in the form of [link text](./File.md),
but I chose URLs here because that's what's used in docs/ABIStabilityManifesto.md.

This doesn't make sense for other branches, or for local development. Relative links are better but wouldn't play nice if we ever rendered the whole thing to HTML. Hm.

Maybe we could use the wiki?

Yeah, I guess there's nothing perfect. My rationale for the change was that I was browsing this doc on my phone, and thought it'd at least be a little more convenient to be able to traverse links instead of typing the name of the doc in the address bar.

I prefer keeping documentation in source, and not hosted on GitHub, but I also feel that's a much larger discussion. If this "linkification" isn't a good incremental change then I'm fine closing the pull request, no big deal :)

Unfortunately it doesn't seem like the docs themselves are very consistent: whereas docs/ABIStabilityManifesto.md uses URLs,  docs/CompilerPerformance.md uses relative file paths. The former may not link to the same branch as it's currently being viewed on, the latter may not work when rendered to HTML outside of GitHub.

My personal opinion is "done is better than perfect" in this case and that having any links would be better than none at all. If it's important then someone can start a discussion on the mailing list as to how to make links consistent across all docs.

I guess I'd leave things as is for now, then, sorry.

No worries, thanks for letting me know!

authors: felix91gr jrose-apple modocache


text:
Revert "[stdlib] Add faster 32-bit and 64-bit binade, nextUp, ulp"

Reverts apple/swift#15021
This change breaks the stdlib/FloatingPoint.swift.gyb test in optimized mode.
See https://ci.swift.org/job/oss-swift_tools-RA_stdlib-RDA_test-simulator/626/consoleFull#-1198550690ba62d58e-7248-467b-91e0-c7508d5cf947

@swift-ci smoke test and merge

@eeckstein That's my bad. We intentionally changed the exact encoding of NaN results from nextUp but I didn't pick up that the test is looking for a specific bit pattern. I will update and restore the original commit.

@xwu ok. Please make sure that this test passes in optimized mode by running it locally (optimized mode is not included in PR testing)

authors: eeckstein xwu


text:
[WIP][stdlib] Finalize Hasher ABI

This PR will finalize the ABI of Hasher. It looks like we may need to keep Hasher fixed-layout, with some extra padding to allow for potential future changes.
However, before committing to do that, let's try making the tail buffer inlinable first.

@swift-ci smoke benchmark

Build comment file:
Performance: -O

TEST
OLD
NEW
DELTA
RATIO

Regression

SetIsSubsetBox25
180
454
+152.2%
0.40x

SetIntersectionBox0
151
317
+109.9%
0.48x

SetIsSubsetBox0
357
653
+82.9%
0.55x

SetIntersectionBox25
286
501
+75.2%
0.57x

SetSubtractingBox0
156
247
+58.3%
0.63x

SetSymmetricDifferenceBox25
536
840
+56.7%
0.64x

SetExclusiveOr_OfObjects
7324
11133
+52.0%
0.66x

SetSymmetricDifferenceBox0
734
1114
+51.8%
0.66x

SetSubtractingBox25
274
385
+40.5%
0.71x

SetUnionBox0
587
806
+37.3%
0.73x

SetUnion_OfObjects
5860
8036
+37.1%
0.73x

SetIsSubsetInt50
152
207
+36.2%
0.73x

Dictionary4OfObjects
347
460
+32.6%
0.75x

DictionaryGroup
220
286
+30.0%
0.77x

SetUnionInt100
70
91
+30.0%
0.77x

SetUnionBox25
372
483
+29.8%
0.77x

PrimsSplit
787
1016
+29.1%
0.77x

SetIsSubsetInt100
308
397
+28.9%
0.78x

Dictionary3OfObjects
559
716
+28.1%
0.78x

DictionarySwapOfObjects
8020
10240
+27.7%
0.78x

FrequenciesUsingReduceInto
1184
1495
+26.3%
0.79x

SetSubtractingInt0
73
92
+26.0%
0.79x

Prims
788
992
+25.9%
0.79x

SetSubtractingInt25
113
142
+25.7%
0.80x

Dictionary4
281
353
+25.6%
0.80x

StringRemoveDupes
417
517
+24.0%
0.81x

SetIntersectionInt0
68
84
+23.5%
0.81x

StringHashing_ascii
34
42
+23.5%
0.81x

SetIntersect
689
841
+22.1%
0.82x

DictionarySwap
1104
1343
+21.6%
0.82x

DictionaryRemoveOfObjects
20775
25144
+21.0%
0.83x

SetIntersectionInt25
157
190
+21.0%
0.83x

SetSymmetricDifferenceInt100
252
304
+20.6%
0.83x

SetIntersectionInt50
237
285
+20.3%
0.83x

Dictionary3
173
208
+20.2%
0.83x

SetSymmetricDifferenceInt25
250
299
+19.6%
0.84x

SetSubtractingInt100
183
218
+19.1%
0.84x

Dictionary
401
475
+18.5%
0.84x

SetSubtractingInt50
152
180
+18.4%
0.84x

Histogram
590
695
+17.8%
0.85x

Dictionary4Legacy
664
782
+17.8%
0.85x

SetIntersectionInt100
394
464
+17.8%
0.85x

SetSymmetricDifferenceInt50
264
308
+16.7%
0.86x

SetSymmetricDifferenceInt0
391
456
+16.6%
0.86x

SetExclusiveOr
3903
4551
+16.6%
0.86x

Dictionary4OfObjectsLegacy
771
899
+16.6%
0.86x

SetUnion
3247
3777
+16.3%
0.86x

SetUnionInt0
324
376
+16.0%
0.86x

WordCountUniqueASCII
1502
1739
+15.8%
0.86x

DictionaryCompactMapValuesOfNilValue
5123
5927
+15.7%
0.86x

SetUnionInt50
124
143
+15.3%
0.87x

RGBHistogram
2277
2592
+13.8%
0.88x

RGBHistogramOfObjects
18089
20574
+13.7%
0.88x

CountAlgoString
3364
3820
+13.6%
0.88x

SetUnionInt25
149
169
+13.4%
0.88x

TwoSum
1239
1401
+13.1%
0.88x

DictionarySwapAt
1133
1277
+12.7%
0.89x

DictionarySubscriptDefaultMutation
359
404
+12.5%
0.89x

DictionaryFilter
60164
67636
+12.4%
0.89x

Dictionary2
617
693
+12.3%
0.89x

DictionaryCopy
75538
82896
+9.7%
0.91x

Improvement

AnyHashableWithAClass
115351
88843
-23.0%
1.30x

IterateData
1762
1615
-8.3%
1.09x (?)

Code size: -O

TEST
OLD
NEW
DELTA
RATIO

Regression

ErrorHandling.o
2758
3589
+30.1%
0.77x

OpenClose.o
3890
4721
+21.4%
0.82x

AnyHashableWithAClass.o
3717
4285
+15.3%
0.87x

DictTest4.o
24908
28620
+14.9%
0.87x

DictTest4Legacy.o
26218
29890
+14.0%
0.88x

DictionarySwap.o
29854
33942
+13.7%
0.88x

DictionarySubscriptDefault.o
31163
35299
+13.3%
0.88x

TestsUtils.o
23957
26013
+8.6%
0.92x

DictTest2.o
20320
21960
+8.1%
0.93x

DictTest3.o
28528
30488
+6.9%
0.94x

DictionaryGroup.o
17751
18895
+6.4%
0.94x

StringRemoveDupes.o
15909
16933
+6.4%
0.94x

Prims.o
43745
46257
+5.7%
0.95x

StringEnum.o
14459
15284
+5.7%
0.95x

PrimsSplit.o
43793
46233
+5.6%
0.95x

ReduceInto.o
24399
25695
+5.3%
0.95x

CountAlgo.o
21172
22261
+5.1%
0.95x

DictionaryRemove.o
17006
17862
+5.0%
0.95x

SetTests.o
59697
62265
+4.3%
0.96x

WordCount.o
65279
67287
+3.1%
0.97x

DictTest.o
51887
53431
+3.0%
0.97x

RGBHistogram.o
26605
27237
+2.4%
0.98x

BinaryFloatingPointConversionFromBinaryInteger.o
11477
11677
+1.7%
0.98x

Performance: -Osize

TEST
OLD
NEW
DELTA
RATIO

Regression

SetIsSubsetBox25
182
414
+127.5%
0.44x

SetIntersectionBox0
146
325
+122.6%
0.45x

SetIntersectionBox25
283
525
+85.5%
0.54x

SetSubtractingBox0
152
258
+69.7%
0.59x

SetSymmetricDifferenceBox25
552
871
+57.8%
0.63x

SetSymmetricDifferenceBox0
745
1152
+54.6%
0.65x

SetExclusiveOr_OfObjects
7458
11510
+54.3%
0.65x

SetSubtractingBox25
284
411
+44.7%
0.69x

SetIsSubsetBox0
422
599
+41.9%
0.70x

SetUnion_OfObjects
5924
8348
+40.9%
0.71x

SetUnionBox0
594
834
+40.4%
0.71x

Dictionary4OfObjects
360
500
+38.9%
0.72x

SetIsSubsetInt50
156
215
+37.8%
0.73x

SetIntersect
626
861
+37.5%
0.73x

SetIntersectionInt0
63
86
+36.5%
0.73x

SetSubtractingInt0
71
96
+35.2%
0.74x

SetIsSubsetInt100
312
421
+34.9%
0.74x

SetIsSubsetInt25
78
105
+34.6%
0.74x

SetUnionBox25
375
501
+33.6%
0.75x

SetUnionInt100
70
93
+32.9%
0.75x

Dictionary4
280
362
+29.3%
0.77x

DictionarySwap
1099
1417
+28.9%
0.78x

SetIntersectionInt25
152
194
+27.6%
0.78x

DictionarySwapOfObjects
8324
10556
+26.8%
0.79x

SetIntersectionInt50
229
287
+25.3%
0.80x

SetSubtractingInt25
111
139
+25.2%
0.80x

SetSubtractingInt50
149
184
+23.5%
0.81x

PrimsSplit
870
1072
+23.2%
0.81x

DictionaryRemoveOfObjects
21291
26060
+22.4%
0.82x

Prims
875
1070
+22.3%
0.82x

SetUnionInt50
116
140
+20.7%
0.83x

SetIntersectionInt100
392
473
+20.7%
0.83x

StringHashing_ascii
34
41
+20.6%
0.83x

Dictionary4Legacy
652
783
+20.1%
0.83x

FrequenciesUsingReduceInto
1196
1435
+20.0%
0.83x

DictionaryCompactMapValuesOfNilValue
5634
6743
+19.7%
0.84x

SetUnionInt0
316
377
+19.3%
0.84x

StringRemoveDupes
428
510
+19.2%
0.84x

SetSymmetricDifferenceInt25
231
275
+19.0%
0.84x

Dictionary3
179
213
+19.0%
0.84x

SetUnion
3167
3766
+18.9%
0.84x

SetSymmetricDifferenceInt50
244
290
+18.9%
0.84x

SetUnionInt25
139
165
+18.7%
0.84x

SetSymmetricDifferenceInt100
243
287
+18.1%
0.85x

Dictionary
417
491
+17.7%
0.85x

CountAlgoString
3225
3797
+17.7%
0.85x

WordCountUniqueASCII
1581
1858
+17.5%
0.85x

DictionaryCopy
75831
87136
+14.9%
0.87x

DictionarySwapAtOfObjects
7976
9130
+14.5%
0.87x

DictionaryGroup
316
360
+13.9%
0.88x

SetSymmetricDifferenceInt0
384
435
+13.3%
0.88x

Dictionary4OfObjectsLegacy
810
917
+13.2%
0.88x

RGBHistogram
2402
2677
+11.4%
0.90x

SetExclusiveOr
3879
4316
+11.3%
0.90x

Dictionary2
646
706
+9.3%
0.92x

Improvement

AnyHashableWithAClass
133123
110409
-17.1%
1.21x

IterateData
1799
1577
-12.3%
1.14x (?)

Code size: -Osize

TEST
OLD
NEW
DELTA
RATIO

Regression

ErrorHandling.o
3062
3781
+23.5%
0.81x

OpenClose.o
3747
4467
+19.2%
0.84x

DictTest4Legacy.o
22633
26873
+18.7%
0.84x

ReduceInto.o
16746
19675
+17.5%
0.85x

DictTest4.o
20939
24155
+15.4%
0.87x

DictionarySubscriptDefault.o
27347
30291
+10.8%
0.90x

TestsUtils.o
19357
21085
+8.9%
0.92x

DictionarySwap.o
26771
28947
+8.1%
0.92x

AnyHashableWithAClass.o
3965
4277
+7.9%
0.93x

StringRemoveDupes.o
9037
9741
+7.8%
0.93x

CountAlgo.o
14432
15536
+7.6%
0.93x

Prims.o
38541
41349
+7.3%
0.93x

PrimsSplit.o
38589
41397
+7.3%
0.93x

DictionaryGroup.o
16327
17367
+6.4%
0.94x

StringEnum.o
13674
14396
+5.3%
0.95x

DictionaryRemove.o
14827
15531
+4.7%
0.95x

WordCount.o
54720
56776
+3.8%
0.96x

SetTests.o
52825
54633
+3.4%
0.97x

RGBHistogram.o
23949
24557
+2.5%
0.98x

BinaryFloatingPointConversionFromBinaryInteger.o
11349
11549
+1.8%
0.98x

DictTest3.o
23106
23498
+1.7%
0.98x

DictTest2.o
16498
16762
+1.6%
0.98x

DriverUtils.o
146129
147649
+1.0%
0.99x

Performance: -Onone

TEST
OLD
NEW
DELTA
RATIO

Regression

FloatingPointPrinting_Double_description_uniform
36047
44669
+23.9%
0.81x

SetExclusiveOr
10028
12250
+22.2%
0.82x

SetUnionInt0
800
959
+19.9%
0.83x

SetUnion
8014
9600
+19.8%
0.83x

SetSymmetricDifferenceInt0
1025
1224
+19.4%
0.84x

SetIntersectionInt0
217
253
+16.6%
0.86x

SetIntersect
2175
2534
+16.5%
0.86x

SetIntersectionInt25
400
464
+16.0%
0.86x

FloatingPointPrinting_Float80_description_uniform
64610
74355
+15.1%
0.87x

SetIntersectionInt100
874
1001
+14.5%
0.87x

SetSymmetricDifferenceInt25
747
850
+13.8%
0.88x

SetIntersectionInt50
575
649
+12.9%
0.89x

SetSymmetricDifferenceInt50
752
829
+10.2%
0.91x

Dictionary4Legacy
1174
1285
+9.5%
0.91x (?)

DictionaryFilter
206209
225176
+9.2%
0.92x

CharIteration_russian_unicodeScalars_Backwards
223327
241079
+7.9%
0.93x

Improvement

ObjectiveCBridgeStubToNSDate2
1597
1443
-9.6%
1.11x (?)

Code size: Swift libraries

TEST
OLD
NEW
DELTA
RATIO

Regression

libswiftDarwin.dylib
32768
36864
+12.5%
0.89x

libswiftSwiftReflectionTest.dylib
49152
53248
+8.3%
0.92x

libswiftDispatch.dylib
114688
118784
+3.6%
0.97x

libswiftNetwork.dylib
172032
176128
+2.4%
0.98x

How to read the data
The tables contain differences in performance which are larger than 8% and differences in code size which are larger than 1%.
If you see any unexpected regressions, you should consider fixing the regressions before you merge the PR.
Noise: Sometimes the performance results (not code size!) contain false alarms. Unexpected regressions which are marked with '(?)' are probably noise. If you see regressions which you cannot explain you can try to run the benchmarks again. If regressions still show up, please consult with the performance team (@eeckstein).

Hardware Overview
  Model Name: Mac Pro
  Model Identifier: MacPro6,1
  Processor Name: 12-Core Intel Xeon E5
  Processor Speed: 2.7 GHz
  Number of Processors: 1
  Total Number of Cores: 12
  L2 Cache (per Core): 256 KB
  L3 Cache: 30 MB
  Memory: 64 GB

Next up, let's start using _BridgeStorage.

@swift-ci please smoke benchmark

@swift-ci please smoke benchmark

I spawned #19688 to test the _BridgeStorage changes on their own, in isolation.

Build comment file:
Performance: -O

TEST
OLD
NEW
DELTA
RATIO

Regression

DictionarySwapAtOfObjects
7515
48692
+547.9%
0.15x

DictionarySwapAt
1123
5805
+416.9%
0.19x

SetIntersectionBox0
146
263
+80.1%
0.56x

SetIsSubsetBox25
179
317
+77.1%
0.56x

SetSubtractingBox0
158
266
+68.4%
0.59x

SetIntersectionBox25
285
475
+66.7%
0.60x

SetExclusiveOr_OfObjects
7380
11163
+51.3%
0.66x

SetSymmetricDifferenceBox0
749
1113
+48.6%
0.67x

SetIsSubsetInt50
149
221
+48.3%
0.67x

SetSymmetricDifferenceBox25
566
827
+46.1%
0.68x

SetSubtractingBox25
283
412
+45.6%
0.69x

SetIntersect
680
986
+45.0%
0.69x

SetIntersectionInt0
68
98
+44.1%
0.69x

SetIsSubsetInt25
76
109
+43.4%
0.70x

SetIsSubsetBox0
358
507
+41.6%
0.71x

SetUnionBox0
598
834
+39.5%
0.72x

SetUnion_OfObjects
6008
8352
+39.0%
0.72x

SetSubtractingInt0
70
95
+35.7%
0.74x

SetUnionBox25
382
513
+34.3%
0.74x

SetIsSubsetInt100
315
422
+34.0%
0.75x

DictionaryGroup
214
286
+33.6%
0.75x

SetIntersectionInt50
238
314
+31.9%
0.76x

SetIntersectionInt25
160
209
+30.6%
0.77x

SetUnionInt50
125
162
+29.6%
0.77x

DictionaryRemove
4230
5439
+28.6%
0.78x

SetIntersectionInt100
389
497
+27.8%
0.78x

SetUnionInt25
150
190
+26.7%
0.79x

SetUnionInt100
72
91
+26.4%
0.79x

SetSubtractingInt25
118
149
+26.3%
0.79x

Dictionary4OfObjects
346
427
+23.4%
0.81x

SetUnionInt0
325
399
+22.8%
0.81x

SetSymmetricDifferenceInt0
395
484
+22.5%
0.82x

FrequenciesUsingReduceInto
1197
1465
+22.4%
0.82x

Prims
778
950
+22.1%
0.82x

SetUnion
3279
4000
+22.0%
0.82x

SetSubtractingInt50
161
195
+21.1%
0.83x

SetExclusiveOr
3977
4807
+20.9%
0.83x

DictionaryRemoveOfObjects
20626
24913
+20.8%
0.83x

StringHashing_ascii
34
41
+20.6%
0.83x

SetSymmetricDifferenceInt50
272
327
+20.2%
0.83x

SetSubtractingInt100
193
231
+19.7%
0.84x

PrimsSplit
787
941
+19.6%
0.84x

SetSymmetricDifferenceInt25
263
311
+18.3%
0.85x

Dictionary3OfObjects
562
662
+17.8%
0.85x

StringRemoveDupes
429
500
+16.6%
0.86x

SetSymmetricDifferenceInt100
262
305
+16.4%
0.86x

CharacterPropertiesPrecomputed
991
1150
+16.0%
0.86x

Dictionary4Legacy
653
747
+14.4%
0.87x

Dictionary4
280
320
+14.3%
0.88x

DictionaryCompactMapValuesOfNilValue
5121
5764
+12.6%
0.89x

SetIsSubsetInt0
253
283
+11.9%
0.89x

DictionaryBridgeToObjC_Bridge
19
21
+10.5%
0.90x

RGBHistogramOfObjects
18064
19957
+10.5%
0.91x

Dictionary4OfObjectsLegacy
785
867
+10.4%
0.91x

DictionaryLiteral
2147
2350
+9.5%
0.91x

Dictionary
402
440
+9.5%
0.91x

DictionaryCompactMapValuesOfCastValue
11335
12283
+8.4%
0.92x

IterateData
1767
1907
+7.9%
0.93x (?)

Improvement

AnyHashableWithAClass
125208
88909
-29.0%
1.41x

DictionaryCopy
73900
60608
-18.0%
1.22x

DictionarySubscriptDefaultMutation
345
294
-14.8%
1.17x

DictionarySubscriptDefaultMutationArray
736
643
-12.6%
1.14x

DictionaryFilter
59094
52421
-11.3%
1.13x

StringComparison_latin1
699
641
-8.3%
1.09x

Code size: -O

TEST
OLD
NEW
DELTA
RATIO

Regression

ErrorHandling.o
2758
3589
+30.1%
0.77x

OpenClose.o
3890
4721
+21.4%
0.82x

DictTest4.o
24908
29900
+20.0%
0.83x

DictTest4Legacy.o
26218
31202
+19.0%
0.84x

DictionarySubscriptDefault.o
31163
35987
+15.5%
0.87x

AnyHashableWithAClass.o
3717
4285
+15.3%
0.87x

TestsUtils.o
23957
27517
+14.9%
0.87x

DictionarySwap.o
29854
34146
+14.4%
0.87x

DictionaryRemove.o
17006
19266
+13.3%
0.88x

DictTest3.o
28528
32112
+12.6%
0.89x

DictTest2.o
20320
22756
+12.0%
0.89x

Prims.o
43745
47297
+8.1%
0.92x

PrimsSplit.o
43793
47273
+7.9%
0.93x

DictionaryGroup.o
17751
19071
+7.4%
0.93x

RGBHistogram.o
26605
28549
+7.3%
0.93x

WordCount.o
65279
69448
+6.4%
0.94x

StringEnum.o
14459
15284
+5.7%
0.95x

StringRemoveDupes.o
15909
16805
+5.6%
0.95x

ReduceInto.o
24399
25711
+5.4%
0.95x

SetTests.o
59697
62897
+5.4%
0.95x

CountAlgo.o
21172
22229
+5.0%
0.95x

DictTest.o
51887
54131
+4.3%
0.96x

BinaryFloatingPointConversionFromBinaryInteger.o
11477
11677
+1.7%
0.98x

DriverUtils.o
167649
170529
+1.7%
0.98x

Improvement

DictionaryLiteral.o
1392
1344
-3.4%
1.04x

NSDictionaryCastToSwift.o
2065
2000
-3.1%
1.03x

Histogram.o
4604
4476
-2.8%
1.03x

HashQuadratic.o
6328
6200
-2.0%
1.02x

DictionaryCopy.o
9992
9794
-2.0%
1.02x

DictionaryBridge.o
3715
3650
-1.7%
1.02x

DictionaryBridgeToObjC.o
7199
7119
-1.1%
1.01x

Performance: -Osize

TEST
OLD
NEW
DELTA
RATIO

Regression

DictionarySwapAtOfObjects
8074
49059
+507.6%
0.16x

DictionarySwapAt
1111
5007
+350.7%
0.22x

SetIsSubsetBox25
184
344
+87.0%
0.53x

SetIntersectionBox0
148
270
+82.4%
0.55x

SetSubtractingBox0
154
267
+73.4%
0.58x

SetIntersectionBox25
286
489
+71.0%
0.58x

SetSymmetricDifferenceBox25
549
881
+60.5%
0.62x

SetExclusiveOr_OfObjects
7461
11528
+54.5%
0.65x

SetSymmetricDifferenceBox0
746
1151
+54.3%
0.65x

SetSubtractingBox25
278
425
+52.9%
0.65x

SetIsSubsetBox0
357
544
+52.4%
0.66x

SetIntersect
612
919
+50.2%
0.67x

SetIntersectionInt0
61
91
+49.2%
0.67x

SetUnion_OfObjects
5937
8750
+47.4%
0.68x

SetUnionBox0
593
873
+47.2%
0.68x

SetIsSubsetInt50
155
226
+45.8%
0.69x

SetIsSubsetInt25
78
111
+42.3%
0.70x

SetUnionBox25
376
533
+41.8%
0.71x

SetIsSubsetInt100
307
423
+37.8%
0.73x

SetSymmetricDifferenceInt25
230
316
+37.4%
0.73x

SetSubtractingInt25
113
155
+37.2%
0.73x

WordCountUniqueASCII
1581
2162
+36.7%
0.73x

SetSubtractingInt50
151
206
+36.4%
0.73x

SetUnionInt100
70
95
+35.7%
0.74x

SetIntersectionInt25
152
202
+32.9%
0.75x

SetSubtractingInt0
74
98
+32.4%
0.76x

SetSymmetricDifferenceInt50
250
331
+32.4%
0.76x

SetIntersectionInt50
231
304
+31.6%
0.76x

SetIntersectionInt100
388
503
+29.6%
0.77x

Dictionary4OfObjects
364
468
+28.6%
0.78x

SetUnionInt50
119
152
+27.7%
0.78x

SetUnion
3139
3938
+25.5%
0.80x

SetSymmetricDifferenceInt100
243
304
+25.1%
0.80x

FrequenciesUsingReduceInto
1212
1515
+25.0%
0.80x

StringHashing_ascii
33
41
+24.2%
0.80x

SetSymmetricDifferenceInt0
386
478
+23.8%
0.81x

SetExclusiveOr
3865
4761
+23.2%
0.81x

PrimsSplit
867
1065
+22.8%
0.81x

SetUnionInt0
321
394
+22.7%
0.81x

Prims
868
1061
+22.2%
0.82x

SetUnionInt25
144
176
+22.2%
0.82x

DictionaryGroup
316
380
+20.3%
0.83x

DictionaryRemoveOfObjects
21600
25743
+19.2%
0.84x

SetSubtractingInt100
195
229
+17.4%
0.85x

Dictionary4Legacy
651
759
+16.6%
0.86x

DictionarySwapOfObjects
8305
9657
+16.3%
0.86x

StringRemoveDupes
428
496
+15.9%
0.86x

Dictionary4
281
323
+14.9%
0.87x

SetIsSubsetInt0
257
295
+14.8%
0.87x

Dictionary4OfObjectsLegacy
787
892
+13.3%
0.88x

DictionaryCompactMapValuesOfNilValue
5724
6475
+13.1%
0.88x

DictionaryRemove
4721
5323
+12.8%
0.89x

TwoSum
1243
1394
+12.1%
0.89x

DictionaryLiteral
2761
3045
+10.3%
0.91x

CharacterPropertiesPrecomputed
1510
1661
+10.0%
0.91x (?)

RGBHistogramOfObjects
19170
20670
+7.8%
0.93x

CStringLongAscii
3306
3562
+7.7%
0.93x

Improvement

DictionaryCopy
76052
64332
-15.4%
1.18x

DictionarySubscriptDefaultMutationArray
757
657
-13.2%
1.15x

FloatingPointPrinting_Float_description_uniform
5803
5178
-10.8%
1.12x

Code size: -Osize

TEST
OLD
NEW
DELTA
RATIO

Regression

ErrorHandling.o
3062
3781
+23.5%
0.81x

DictTest4Legacy.o
22633
27401
+21.1%
0.83x

OpenClose.o
3747
4467
+19.2%
0.84x

DictTest4.o
20939
24907
+19.0%
0.84x

ReduceInto.o
16746
19707
+17.7%
0.85x

DictionarySubscriptDefault.o
27347
30619
+12.0%
0.89x

DictionaryRemove.o
14827
16443
+10.9%
0.90x

DictionarySwap.o
26771
29579
+10.5%
0.91x

TestsUtils.o
19357
21261
+9.8%
0.91x

CountAlgo.o
14432
15680
+8.6%
0.92x

DictTest2.o
16498
17898
+8.5%
0.92x

WordCount.o
54720
59048
+7.9%
0.93x

AnyHashableWithAClass.o
3965
4277
+7.9%
0.93x

Prims.o
38541
41397
+7.4%
0.93x

PrimsSplit.o
38589
41445
+7.4%
0.93x

StringRemoveDupes.o
9037
9661
+6.9%
0.94x

DictTest3.o
23106
24554
+6.3%
0.94x

DictionaryGroup.o
16327
17303
+6.0%
0.94x

StringEnum.o
13674
14396
+5.3%
0.95x

SetTests.o
52825
55473
+5.0%
0.95x

RGBHistogram.o
23949
24989
+4.3%
0.96x

main.o
41785
43561
+4.3%
0.96x

DictTest.o
49097
50409
+2.7%
0.97x

BinaryFloatingPointConversionFromBinaryInteger.o
11349
11549
+1.8%
0.98x

StringEdits.o
14174
14334
+1.1%
0.99x

Improvement

NSError.o
1763
1683
-4.5%
1.05x

SevenBoom.o
2111
2019
-4.4%
1.05x

Histogram.o
4480
4352
-2.9%
1.03x

NSDictionaryCastToSwift.o
1941
1893
-2.5%
1.03x

DictionaryBridge.o
3751
3671
-2.1%
1.02x

DictionaryLiteral.o
1525
1493
-2.1%
1.02x

HashQuadratic.o
5832
5720
-1.9%
1.02x

DictionaryCopy.o
9105
8969
-1.5%
1.02x

Performance: -Onone

TEST
OLD
NEW
DELTA
RATIO

Regression

DictionarySwapAt
3706
23318
+529.2%
0.16x

DictionarySwapAtOfObjects
16221
97031
+498.2%
0.17x

FloatingPointPrinting_Double_interpolated
91571
112670
+23.0%
0.81x

SetUnion
7928
9150
+15.4%
0.87x

SetSubtractingInt100
556
637
+14.6%
0.87x

SetSubtractingInt50
488
556
+13.9%
0.88x

SetIntersectionInt100
865
980
+13.3%
0.88x

SetUnionInt50
469
521
+11.1%
0.90x

SetSymmetricDifferenceInt100
719
793
+10.3%
0.91x

ArrayOfPOD
782
860
+10.0%
0.91x (?)

SetUnionInt0
832
914
+9.9%
0.91x

DictionaryFilter
207043
226885
+9.6%
0.91x

SetUnionInt100
328
359
+9.5%
0.91x

SetIntersectionInt25
412
450
+9.2%
0.92x

SetIntersectionInt50
573
623
+8.7%
0.92x

CaptureProp
330292
355380
+7.6%
0.93x

Code size: Swift libraries

TEST
OLD
NEW
DELTA
RATIO

Regression

libswiftDarwin.dylib
32768
36864
+12.5%
0.89x

libswiftSwiftReflectionTest.dylib
49152
53248
+8.3%
0.92x

libswiftDispatch.dylib
114688
118784
+3.6%
0.97x

libswiftNetwork.dylib
172032
176128
+2.4%
0.98x

libswiftFoundation.dylib
1851392
1875968
+1.3%
0.99x

How to read the data
The tables contain differences in performance which are larger than 8% and differences in code size which are larger than 1%.
If you see any unexpected regressions, you should consider fixing the regressions before you merge the PR.
Noise: Sometimes the performance results (not code size!) contain false alarms. Unexpected regressions which are marked with '(?)' are probably noise. If you see regressions which you cannot explain you can try to run the benchmarks again. If regressions still show up, please consult with the performance team (@eeckstein).

Hardware Overview
  Model Name: Mac Pro
  Model Identifier: MacPro6,1
  Processor Name: 12-Core Intel Xeon E5
  Processor Speed: 2.7 GHz
  Number of Processors: 1
  Total Number of Cores: 12
  L2 Cache (per Core): 256 KB
  L3 Cache: 30 MB
  Memory: 64 GB

Closing; this work is being completed in #20185 and #20202.

authors: lorentey swift-ci


text:
Fix typo regarding supported FreeBSD architectures

While I'm not testing on FreeBSD, I strongly suspect that whoever added support didn't do it for every architecture besides x86_64, and that an error was made during refactoring.

@CodaFi - automerges are blocked, but, I believe that members of @apple can merge manually.

authors: compnerd coypoop


text:
Allow dynamic replacement initializers to be non delegating

rdar://48125765

@swift-ci Please test

@swift-ci Please test


text:
DebugInfo: fix debugging on SIL level

The fix is to set the DebugCompilationDir when -gsil is used.
Otherwise no debug info is generated if the source file name does not contain a path.
rdar://problem/49796695

@swift-ci smoke test

@swift-ci smoke test linux


text:
Vim: Use 4 spaces instead of 2

By default, Xcode uses 4 spaces, instead of 2. Having ts and sw 2 here
makes formatting incompatible with existing files created with Xcode. To
ensure that files created with Vim and Xcode look the same, 4 sounds
ideal.

This project uses 2 spaces in its C++ and Swift code.

Wouldn't it be better to tailor this for general use rather than being project-specific?

My understanding is that this file was committed by the standard library folk to help them get some useful defaults up for writing stdlib code in vim. This file isn't meant for general usage - and you should probably petition vim itself to get their definition changed.

authors: CodaFi bitigchi xwu