WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
Summary of the new feature/enhancement

Detect URLs and make them clickable (open the URL in the default browser). This is a convenience feature present in many other terminals.

I believe the value is self-evident, but here's a concrete use case example regardless: when I run yarn outdated (Yarn is a package manager) it outputs a repository/homepage URL for every listed package. I want to be able to click one of those URLs to open the page quickly/easily and have a look at what has changed in the new version of the package.

Implementation details

Probably don't need to support anything more than text starting with http:// or https://.

URLs that span multiple lines (due to being truncated by the window width) should be handled correctly.

There should probably be an indication that the URL is clickable, e.g. cursor change + underline on mouse hover.

Most other terminals require an alt or ctrl click, I presume to guard against accidental clicks when copying and so forth.

You can look at something like VS Code's terminal for inspiration. Again this is all probably self-evident.

Stretch goal (covered in #204)

Issue 2:
The marketing video for Terminal included a part where they show links previewing on hover. Is this functionality currently available?
Issue 1:
Test is simple to wait for an element to be visible and then click on it. During the debugging of the test, I found out that after the #1 retry, the click action is successful, but during a normal run, this click is very flaky and only happens like 1-2 times in 5 executions, and the next step fails.

System info

Playwright Version: [v1.30]

Operating System: [All, Windows 11, Ubuntu 20, macOS 13.2, etc.]

Browser: [All, Chromium, Firefox, WebKit]

Other info:

Source code

[ await this.next.waitFor({ state: 'visible' });

await Promise.all([this.next.click(), this.page.waitForNavigation(), this.page.waitForResponse(testReg)]);] I provided exact source code that allows reproducing the issue locally.

Config file

// playwright.config.ts
const config: PlaywrightTestConfig = {
fullyParallel: true,
use: {
actionTimeout: ACTION_TIMEOUT,
navigationTimeout: NAVIGATION_TIMEOUT,
screenshot: 'only-on-failure',
ignoreHTTPSErrors: true,
},
};

Test file (self-contained)

await this.next.waitFor({ state: 'visible' });
await Promise.all([this.next.click(), this.page.waitForNavigation(), this.page.waitForResponse(testReg)]);

Expected

locator.click() action should happen each time without flakiness.

Actual

locator.click() action is not happening each time and showing flaky.

Issue 2:
System info

Playwright Version: [v1.XX]

Operating System: [All, Windows 11, Ubuntu 20, macOS 13.2, etc.]

Browser: [All, Chromium, Firefox, WebKit]

Other info:

Source code

I provided exact source code that allows reproducing the issue locally.

await this.page
.getByRole('row', {
name: new RegExp(`\b${escapeRegExp(skill)}\b`, 'u'),
})
.locator('span')
.click()

Link to the GitHub repository with the repro

[https://github.com/your_profile/playwright_issue_title]

or

Config file

// playwright.config.ts
import { defineConfig, devices } from '@playwright/test';

export default defineConfig({
projects: [
{
name: 'chromium',
use: { ...devices['Desktop Chrome'], },
},
});

Test file (self-contained)

it('should check the box using setChecked', async ({ page }) => {
await page.setContent(`<input id='checkbox' type='checkbox'></input>`);
await page.getByRole('checkbox').check();
await expect(page.getByRole('checkbox')).toBeChecked();
});

Steps

[Run the test]

[...]

Expected

Selector getByRole('row', { name: /�cabce�/u }).locator('span') works

[Describe expected behavior]

Actual

Selector getByRole('row', { name: /�cabce�/u }).locator('span') doesn't work, but getByRole('row', { name: /\bcabce\b/u }).locator('span') does work.

one of the playwright generated:

> playwright.generateLocator($0)
< getByRole('row', { name: 'Ca# cabce ' }).locator('label')

So my code looks correct

[Describe actual behavior]
Issue 1:
parse_qs and then urlencode, things will changed.

test code and result

Thank you for this great lib,

the result of parse_qs is something like {'oauth': ['sig'], 'status': ['hanzi ok']}

urlencode can't handle list as dictionary value without doseq

doseq does three things,

if value is not list or unicode, behave like doseq=False

if value is unicode, decode unicode

if value is list, handle list as dict value

it will fall to decode if the unicode value is not encoded in ascii, Chinese for example.

but _encode_params already made sure that no unicode will pass to urlencode,

so I think it's safe to add doseq.

snippet from Python2.7/Lib/urllib.py

if not doseq:
# preserve old behavior
for k, v in query:
k = quote_plus(str(k))
v = quote_plus(str(v))
l.append(k + '=' + v)
else:
for k, v in query:
k = quote_plus(str(k))
if isinstance(v, str):
v = quote_plus(v)
l.append(k + '=' + v)
elif _is_unicode(v):
# is there a reasonable way to convert to ASCII?
# encode generates a string, but "replace" or "ignore"
# lose information and "strict" can raise UnicodeError
v = quote_plus(v.encode("ASCII","replace"))
l.append(k + '=' + v)
else:
try:
# is this a sufficient test for sequence-ness?
len(v)
except TypeError:
# not a sequence
v = quote_plus(str(v))
l.append(k + '=' + v)
else:
# loop over the sequence
for elt in v:
l.append(k + '=' + quote_plus(str(elt)))

it's the first time I use github, I'm sorry for the duplicated pull request

reallly appreciate for this great lib, it helps me a lot.

and I'm looking forward to oauth feature so I don't need to roll my own:)

@@ -230,7 +230,7 @@ class Request(object):
for (k, v) in data.items():
result[k.encode('utf-8') if isinstance(k, unicode) else k] \
= v.encode('utf-8') if isinstance(v, unicode) else v
- return result, urllib.urlencode(result)
+ return result, urllib.urlencode(result, doseq=True)
else:
return data, data

Issue 2:
We have a whole code branch that does chunked uploads that is not and has never been tested. That's a problem, because sometimes it breaks and we don't notice (#2861). I'd like to add more testing for chunked uploads.

However, we can't use httpbin to do this testing. This is because the WSGI spec staunchly refuses to let applications see chunked transfer encoding at the app layer. For this reason, to test chunked transfer encoding requires a new style of testing, one that doesn't involve running a WSGI server but instead running something that can see the bytes as they hit the wire. Basically, something like the socket level tests of urllib3.
Issue 1:
I tried using the @types/leaflet package and had problems.

I tried using the latest stable version of tsc. https://www.npmjs.com/package/typescript

I have a question that is inappropriate for StackOverflow. (Please ask any appropriate questions there).

Mention the authors (see Definitions by: in index.d.ts) so they can respond.

Authors: @alejo90

Currently, only function style is supported by typings for GeoJSON style. Typings should be updated to support a simple object as styles as well.

See documentation: http://leafletjs.com/examples/geojson/

The style option can be used to style features two different ways. First, we can pass a simple object that styles all paths (polylines and polygons) the same way:

var myLines = [{
"type": "LineString",
"coordinates": [[-100, 40], [-105, 45], [-110, 55]]
}, {
"type": "LineString",
"coordinates": [[-105, 40], [-110, 45], [-115, 55]]
}];

var myStyle = {
"color": "#ff7800",
"weight": 5,
"opacity": 0.65
};

L.geoJSON(myLines, {
style: myStyle
}).addTo(map);

Alternatively, we can pass a function that styles individual features based on their properties. In the example below we check the "party" property and style our polygons accordingly:

var states = [{
"type": "Feature",
"properties": {"party": "Republican"},
"geometry": {
"type": "Polygon",
"coordinates": [[
[-104.05, 48.99],
[-97.22, 48.98],
[-96.58, 45.94],
[-104.03, 45.94],
[-104.05, 48.99]
]]
}
}, {
"type": "Feature",
"properties": {"party": "Democrat"},
"geometry": {
"type": "Polygon",
"coordinates": [[
[-109.05, 41.00],
[-102.06, 40.99],
[-102.03, 36.99],
[-109.04, 36.99],
[-109.05, 41.00]
]]
}
}];

L.geoJSON(states, {
style: function(feature) {
switch (feature.properties.party) {
case 'Republican': return {color: "#ff0000"};
case 'Democrat': return {color: "#0000ff"};
}
}
}).addTo(map);

Issue 2:
The current style property of GeoJSONOptions is defined as a function returning style properties:

style?: (featureData: any) => any;

However, the real definition is wider, as I am allowed to pass in a regular object like so:

var geoJson = L.geoJson(geoJsonRoute, {
style: {
"color": "#ff7800",
"weight": 5,
"opacity": 0.65
}
});

which gets rejected by the current typing. Can we widen the definition of style?

(see also http://leafletjs.com/examples/geojson.html)

(cc-ing @rgripper ?)
Issue 1:
Environment

Windows build number: Version 1909 (OS Build 18363.836)
PowerToys version: 0.81.1
PowerToy module for which you are reporting the bug (if applicable): uninstall

Steps to reproduce

Just prior to uninstall I uninstalled several old and new Microsoft programs including "Microsoft Mouse and Keyboard", "Microsoft Office Suite", and others. System bahavior was normal after these and I rebooted. Then...

uninstall via Control Panel

"/" Programs

"/" Programs and Features

"/" Uninstall or change a program

"->" PowerToys (Preview)

"->" uninstall

Expected behavior

uninstall successful

Actual behavior

First attempt:

three exceptions thrown resulting in dialog w/ execution addresses

(sorry I did not capture these)

continuing process, uninstall process crashed with no visible clue except associated windows all closed.

PowerToys (Preview) still listed

Second attempt:

uninstall process again crashed with no visible clue except associated windows all closed.

Ran Task Manager and sorted processes according to CPU usage. There seemed to be about 5% extra overhead not seen before uninstall including system interrupts, churning of a few other normally quieter software... I have not idea if these are related to the uninstall or not.

Screenshots

The screen shot is the state of the System after failed uninstall atempt

Issue 2:
We've seen multiple reports of 'uninstalling' fails and when we dive in, it is due to when a user does it in the old control panel.

Workaround

Windows 10 Settings -> Apps -> Apps & features

How are people hitting this

This is how people are referencing the old dialog.
Issue 1:
When I run any benchmark I get 0 for all metrics except renderTime:

BENCHMARK ng2.tree.create.viewcache
Description:
- depth: 9
- forceGc: false
- lang: js
- regressionSlopeMetric: scriptTime
- runId: 4bba7970-5100-11e5-a97c-1be2da562e8f
- sampleSize: 20
- userAgent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/45.0.2454.85 Safari/537.36
- viewcache: true
Metrics:
- gcAmount: gc amount in kbytes
- gcTime: gc time in ms
- majorGcTime: time of major gcs in ms
- pureScriptTime: script execution time in ms, without gc nor render
- renderTime: render time in ms
- scriptTime: script execution time in ms, including gc and render

gcAmount | gcTime | majorGcTime | pureScriptTime | renderTime | scriptTime
------------------ | ------------------ | ------------------ | ------------------ | ------------------ | ------------------
0.00 | 0.00 | 0.00 | 0.00 | 0.75 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 1.48 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.37 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.56 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.69 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.70 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.86 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.66 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 2.51 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.51 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.46 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.38 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.89 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.41 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.44 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.45 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.51 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.66 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.74 | 0.00
0.00 | 0.00 | 0.00 | 0.00 | 0.61 | 0.00
================== | ================== | ================== | ================== | ================== | ==================
0.00 | 0.00 | 0.00 | 0.00 | 0.73+-64% | 0.00

This is for any benchmark, both JS and dart2js. cc @tbosch

Issue 2:
Benchpress does not report script time or gc in the upcoming Chrome 45. Changes to their tracing events:

script time:

Is reported with category devtools.timeline,v8 and name FunctionCall (used to be other category).

gc time:

Is reported via category devtools.timeline,v8 and name MinorGC / MajorGC (used to be other category and different name). Also, the name majorGC is not reported for category v8 any more.
Issue 1:
Bug Report

For English only, other languages will not accept.

Before report a bug, make sure you have:

Searched open and closed GitHub issues.

Read documentation: ShardingSphere Doc.

Please pay attention on issues you submitted, because we maybe need more details.

If no response anymore and we cannot reproduce it on current information, we will close it.

Please answer these questions before submitting your issue. Thanks!

Which version of ShardingSphere did you use?

shardingsphere-jdbc-core-spring-boot-starter 5.1.2

Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?

ShardingSphere-JDBC

Expected behavior

when use Druid to encript password,I use connec-properties,there are two method both named "setConnectProperties"

so when yaml use string to config connecProperties,it will throw "java.lang.String can't cast to java.util.Map",i think setter method should check fieldName and type，not only fieldName, in org.apache.shardingsphere.infra.datasource.pool.creator.DataSourceReflection

Actual behavior

Reason analyze (If you can)

org.apache.shardingsphere.infra.datasource.pool.creator.DataSourceReflection

Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.

Example codes for reproduce this issue (such as a github link).

Issue 2:
Bug Report

Which version of ShardingSphere did you use?

v5.2.0

Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?

ShardingSphere-JDBC

Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.

Create a druid datasource, and then add some filters.

DruidDataSource druidDataSource = new DruidDataSource();
// ...
druidDataSource.setProxyFilters(buildFilters());

Create a shardingsphere datasource by ShardingSphereDataSourceFactory

Exception occurs: Can't construct a java object for tag:yaml.org,2002:com.alibaba.druid.filter.stat.StatFilter; exception=Class is not accepted: com.alibaba.druid.filter.stat.StatFilter.

Example codes for reproduce this issue (such as a github link).

https://github.com/caol64/sharding-test
Issue 1:
hi all

Follow the tutorial(Loading a PyTorch Model in C++)

1.cmake

-- Caffe2: CUDA detected: 10.0

-- Caffe2: CUDA nvcc is: /usr/local/cuda-10.0/bin/nvcc

-- Caffe2: CUDA toolkit directory: /usr/local/cuda-10.0

-- Caffe2: Header version is: 10.0

-- Found cuDNN: v7.4.2 (include: /usr/include, library: /usr/lib/x86_64-linux-gnu/libcudnn.so)

-- Automatic GPU detection failed. Building for common architectures.

-- Autodetected CUDA architecture(s): 3.0;3.5;5.0;5.2;6.0;6.1;7.0;7.0+PTX

-- Added CUDA NVCC flags for: -gencode;arch=compute_30,code=sm_30;-gencode;arch=compute_35,code=sm_35;-gencode;arch=compute_50,code=sm_50;-gencode;arch=compute_52,code=sm_52;-gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_61,code=sm_61;-gencode;arch=compute_70,code=sm_70;-gencode;arch=compute_70,code=compute_70

-- Configuring done

-- Generating done

2. make

make[2]: *** No rule to make target '/usr/local/cuda/lib64/libculibos.a', needed by 'example-app'. Stop.

CMakeFiles/Makefile2:67: recipe for target 'CMakeFiles/example-app.dir/all' failed

make[1]: *** [CMakeFiles/example-app.dir/all] Error 2

Makefile:83: recipe for target 'all' failed

make: *** [all] Error 2

please ....

Issue 2:
🐛 Bug

The sample C++ program for libtorch results in an incorrect Makefile because the path to libculibos.a is hardcoded somewhere as /usr/local/cuda/lib64/libculibos.a.

On Arch Linux, the default install directory for CUDA is /opt/cuda.

This is handled correctly for other linked libraries.

Workaround

After running CMake, modify CMakeFiles/(project).dir/build.make and modify the line:

(project): /usr/local/cuda/lib64/libculibos.a

to:

(project): /opt/cuda/lib64/libculibos.a

This fixes the problem for me with CUDA 10.

To Reproduce

Steps to reproduce the behavior:

Be on Arch Linux with libtorch downloaded from the official download link.

Try to follow the [minimal C++ example]: https://pytorch.org/cppdocs/installing.html

You will get an error when running make, which can be fixed with the temporary workaround shown above.
Issue 1:
Tomasz Nurkiewicz opened SPR-8943 and commented

Spring 3.1 introduces several @Enable* annotations. However this code snippet:

<context:mbean-export/>

cannot be expressed with annotations. There is a valid simple workaround:

@Bean
public AnnotationMBeanExporter annotationMBeanExporter() {
return new AnnotationMBeanExporter();
}

but it would be nice to have built-in @Enable... annotation. Note that in JavaConfig project there was @MBeanExport annotation.

Affects: 3.1 GA

Sub-tasks:

#14552 Document @EnableMBeanExport in reference manual

Issue Links:

#12963 Provide @Configuration support for automatic MBean registration ("is duplicated by")

#17728 Add an enum for MBeanExporter Autodetect Mode

Referenced from: commits 0bd4dab, d52e868, 5d4d1ea, cae08db

5 votes, 3 watchers

Issue 2:
Nicolas Demengel opened SPR-7589 and commented

Hi people,

I might have found an odd behavior in the AbstractUrlHandlerMapping class : given two controllers, one annotated with @RequestMapping("/**") and the another one annotated with @RequestMapping("/access/{resourceType}/{resourceSubType}/{resourceName}"), when the path "/access/document/text/sometextdocument" is evaluated I would expect the second controller to be chosen to handle the request but it is the first one that is taken.

Looking at the code of AbstractUrlHandlerMapping.lookupHandler() one can see that when several patterns are found that match the path, they are ordered using an AntPatternComparator to find the most pertinent one for it. Digging in further, this comparator orders patterns based on their level of incertitude, counting the occurrences of wildcards and brackets. In my opinion it should read patterns as we do (i.e. from left to right in our countries) to see if the pattern start makes it more suitable to handle the path that is evaluated.

I attached a JUnit test to illustrate my point.

Thanks

Affects: 3.0.4

Attachments:

AntPatternComparatorTest.java (1.45 kB)

Issue Links:

#11407 RequestMapping with 3 PathVariable doesn't work ("duplicates")

#13325 AntPathMatcher.AntPatternComparator algorithm wrong for hierarchical matches

1 votes, 1 watchers
Issue 1:
Which version of ShardingSphere did you use?

master branch(5.0.0-RC1)

Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?

ShardingSphere-Proxy

Expected behavior

create CREDENTIAL table successfully, in actual table,this is four table on mysql server

Actual behavior

o.a.s.p.f.c.CommandExecutorTask - Exception occur:com.mysql.jdbc.exceptions.jdbc4.MySQLIntegrityConstraintViolationException: Can't write; duplicate key in table 'credential_1'

Reason analyze (If you can)

The foreign key name was not changed when the table was split

Steps to reproduce the behavior, such as: SQL to execute, sharding rule configuration, when exception occur etc.

schemaName: test

dataSources:
ds_0:
url: jdbc:mysql://db:3306/test?useSSL=false
username: root
password: root
connectionTimeoutMilliseconds: 30000
idleTimeoutMilliseconds: 60000
maxLifetimeMilliseconds: 1800000
maxPoolSize: 50
minPoolSize: 1
rules:
- !SHARDING
tables:
CREDENTIAL:
actualDataNodes: ds_0.CREDENTIAL_${0..3}
tableStrategy:
standard:
shardingColumn: ID
shardingAlgorithmName: credential_inline

defaultDatabaseStrategy:
none:
defaultTableStrategy:
none:
bindingTables:
- CREDENTIAL

shardingAlgorithms:
credential_inline:
type: INLINE
props:
algorithm-expression: CREDENTIAL_${Math.abs(ID.hashCode() % 4)}

keyGenerators:
snowflake:
type: SNOWFLAKE
props:
worker-id: 123

Create database statement is

CREATE TABLE CREDENTIAL (

ID varchar(36) NOT NULL,

SALT tinyblob,

TYPE varchar(255) DEFAULT NULL,

USER_ID varchar(36) DEFAULT NULL,

CREATED_DATE bigint(20) DEFAULT NULL,

USER_LABEL varchar(255) DEFAULT NULL,

SECRET_DATA longtext,

CREDENTIAL_DATA longtext,

PRIORITY int(11) DEFAULT NULL,

PRIMARY KEY (ID),

KEY IDX_USER_CREDENTIAL (USER_ID),

CONSTRAINT FK_PFYR0GLASQYL0DEI3KL69R6V0 FOREIGN KEY (USER_ID) REFERENCES USER_ENTITY (ID)

) ENGINE=InnoDB DEFAULT CHARSET=utf8;

Issue 2:
Which version of ShardingSphere did you use?

My version is ShardingSphere 5.3.1

Which project did you use? ShardingSphere-JDBC or ShardingSphere-Proxy?

I use ShardingSphere-JDBC

Operation steps

I imported ShardingSphere in the SpringBoot project and reported an error.

<dependency>
<groupId>org.apache.shardingsphere</groupId>
<artifactId>shardingsphere</artifactId>
<version>5.3.1</version>
<type>pom</type>
<scope>import</scope>
</dependency>

Could not transfer artifact org.springframework:spring-jdbc:jar:${springframework.version}

After repeated debugging, the original pom.xml of the parent module does not define the <springframework.version/> variable.

I hope to solve this problem. Thank you very much.