WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
Repro Steps:

kubectl create -f nginx-deployment.yaml
deployment "nginx-deployment" created

kubectl get deployments
NAME DESIRED CURRENT UP-TO-DATE AVAILABLE AGE
nginx-deployment 3 3 3 3 0s

kubectl rollout history deployment/nginx-deployment
deployments "nginx-deployment":
REVISION CHANGE-CAUSE
1 <none>

Note: CHANGE-CAUSE has value <none>, since deployment file did not contain any annotations.

Modify nginx-deployment.yaml file adding annotation foo-bar like so:

apiVersion: extensions/v1beta1
kind: Deployment
metadata:
name: nginx-deployment
annotations:
kubernetes.io/change-cause: foo-bar
spec:
replicas: 3
template:
metadata:
labels:
app: nginx
spec:
containers:
- name: nginx
image: nginx:1.7.9
ports:
- containerPort: 80

Delete nginx-desployment and re-create one from scratch

kubectl delete deployment/nginx-deployment
deployment "nginx-deployment" deleted

Assert deployment is gone:

kubectl get deployments

Create new nginx-deployment:

kubectl apply -f nginx-deployment.yaml
deployment "nginx-deployment" created

kubectl rollout history deployment/nginx-deployment
deployments "nginx-deployment":
REVISION CHANGE-CAUSE
1 kubectl apply -f nginx-deployment.yaml

Note: CHANGE-CAUSE reflect the actual command and not the value from the file

Apply the same change again:

kubectl apply -f nginx-deployment.yaml
deployment "nginx-deployment" configured

kubectl rollout history deployment/nginx-deployment
deployments "nginx-deployment":
REVISION CHANGE-CAUSE
1 foo-bar

Note: second time around annotation is correctly updated. Since there were no other changes to the deployment, no new pods/replicasets were created.

Repeat applying the same deployment file and observe alternating value in CHANGE-CAUSE

kubectl apply -f nginx-deployment.yaml
deployment "nginx-deployment" configured

kubectl rollout history deployment/nginx-deployment
deployments "nginx-deployment":
REVISION CHANGE-CAUSE
1 kubectl apply -f nginx-deployment.yaml

kubectl apply -f nginx-deployment.yaml
deployment "nginx-deployment" configured

kubectl rollout history deployment/nginx-deployment
deployments "nginx-deployment":
REVISION CHANGE-CAUSE
1 foo-bar

Issue 2:
what

Let the user override the default change-cause generated by kubectl by specifying it in the metadata of the resource file

Example:

why

The automatic annotations are not very helpful if the same command is always executed

The end-user can provide more meaningful annotations in the context of their application (i.e. git commit messages, git hash, release version, etc)

note

Specifying change-cause sometimes works. Not sure if this is due to a race-condition.
Issue 1:
I am suggesting to create opencollective and spent this money to contests and grants.

For example:

grant for new Three.js UI

contest with particles

etc.

This is not duplicate of #11318 because this issue more about contests than OpenCollective and suggesting how to spend this fund.

Issue 2:
Being able to provide an optional callback function to customize the URLs being requested by ColladaLoader would be very appreciated.The function would be unique per ColladaLoader instance, and would create the URL parameter of the THREE.ImageUtils.loadTexture() call around line 3483, and possibly the DAE around 109 (I know we can already provide the exact URL there, but it might be nice to be able to provide a general filename to ColladaLoader.load() and have it wrapped through the same URLizer as well).
Issue 1:
Sergio Bossa opened SPR-4433 and commented

The protected ServletRequestAttributes#getSession(boolean ) method returns a null session on child threads.

This is wrong because it doesn't get into account what happens in the constructor:

[code]

public ServletRequestAttributes(HttpServletRequest request) {

Assert.notNull(request, "Request must not be null");

this.request = request;

// Fetch existing session reference early, to have it available even

// after request completion (for example, in a custom child thread).

this.session = request.getSession(false);

}

[/code]

I think that the following code into the getSession method:

[code]

this.session = this.request.getSession(allowCreate);

return this.session;

[/code]

Should be as follows:

[code]

HttpSession newSession = this.request.getSession(allowCreate);

if (newSession != null) {

this.session = newSession;

}

return this.session;

[/code]

Affects: 2.0.8

Issue Links:

#9112 ServletRequestAttributes wrongly returns a null http session on child threads. ("duplicates")

Issue 2:
Sam Brannen opened SPR-9619 and commented

Status Quo

Unlike the Spring .NET Expression Language, the Spring Expression Language currently does not provide a means to retrieve unique elements within a collection.

Use Case and Work-Around

With raw collection projection, the resulting collection may well contain duplicates due to the nature of the data. Some use cases, however, may require that the projection contains unique results.

To solve this problem within a SpEL expression (in Spring 3.0.x and 3.1.x) we can implement a work-around by adding the projected elements to a Set that will automatically remove any duplicates (assuming the objects stored in the collection properly implement equals()).

In the following example we instantiate a HashSet, passing it a list projection, thereby removing duplicates.

// Book contains: List<Author> authors;
// Author contains: Address address;
// Address contains: String country;

// Book book = ...
EvaluationContext context = new StandardEvaluationContext(book);

ExpressionParser parser = new SpelExpressionParser();

Expression exp = parser.parseExpression("new java.util.HashSet(authors.![address.country])");

Set<String> uniqueCountries = (Set<String>) exp.getValue(context);

Deliverables

Add a unique() collection processor to SpEL, analogous to the distinct() collection processor from Spring .NET (see Further Resources)

Consider supporting the remaining 'collection processors and aggregators' from .NET

Further Resources

Distinct Processor functionality from the Spring .NET Expression Language

Affects: 3.0 GA, 3.1.2
Issue 1:
I have searched the issues of this repository and believe that this is not a duplicate.

Expected Behavior

Steps to Reproduce (for bugs)

next.config.js

module.exports = (phase, { defaultConfig }) => {
return {
publicRuntimeConfig: {
defaultEnvironmentSettings: 'test',
},
webpack: (config, { buildId, dev, isServer, defaultLoaders }) => {
// XXX https://github.com/evanw/node-source-map-support/issues/155
config.node = {
fs: 'empty',
module: 'empty',
};
return config;
},
};
};

page

const { publicRuntimeConfig } = getConfig();
const { groupSettings, url } = this.props;
const schoolName = url.query.schoolName;
console.log('publicRuntimeConfig', publicRuntimeConfig) // publicRuntimeConfig undefined
console.log('getConfig()', getConfig()) // getConfig() serverRuntimeConfig:{}, publicRuntimeConfig: undefined

Context

publicRuntimeConfig is undefined

This only happens when I use NODE_ENV staging, it works fine in development mode. (I haven't tested against production env)

Note that my staging environment is hosted on AWS lambda, but it's maybe not related to the issue.

Issue 2:
Although I see the use case for this, I personally will never use this feature.

I lose too much flexibility & reusability (and/or gain awkwardness) by not using SASS/Stylus/whatever. And with a cached, single (or not) stylesheet, I won't suffer any performance loss by not taking the small, as-needed css module approach.

Plus, imo, the CSS module / Shadow-dom styles approach isn't fully solved yet. As mentioned, when each component prints its own styles, excessive duplicates add up quickly. Of course, this is not a next.js or glamor issue specifically, but part of the reason why I find it makes more sense to compile styles ahead of time.

So, with as easy as it is to attach static assets in the <Head />, I think glamor should be opt-in or opt-out.

As it is, I have to require & load all of glamor regardless of my choice of architecture. 😿
Issue 1:
does not work in production

I'm having an issue with next link, on my development environment the component work really well, i have included the code for the component bellow, my main issue is when i deploy to production (im using zeit now) the link does not work and anything happens when the button is clicked, no consol errors

Component

import Link from 'next/link'; import { ShopingCartNavIcon } from '../../lib/icons'; const CheckoutButton = () => { return ( <Link href='/cart'> <button class='nav--cart--btn' title='Shopping Cart'> <span>Shopping Cart</span> <ShopingCartNavIcon /> </button> </Link> ); }; export default CheckoutButton;

Expected behavior

To redirect the user to the Cart page.

System information

OS: Windows 10

Browser chrome

Version of Next.js: 9.1.4

Issue 2:
This is bug report

Link does not work with css-module imported. That happens when page with Link has no css, and linked page has. No errors in console, so im not sure about reasons, but there is minimal repo to reproduce:

https://github.com/standy/next-css-error

Bug appears in next@7.0.0 + next-css@1.0.1,

Older next@6.1.2 + next-css@0.2.0 works fine
Issue 1:
Hello.

We using react for some our projects and found, what on staging servers it start generate warning about "It looks like you're using a minified copy of the development build of React. When deploying React apps to production, make sure to use the production build which skips development warnings and is faster".

We still need all possible warnings about propTypes or about controlled/uncontrolled components to debug all issues on environment, which as close as possible to production, but still is not production. In this case "staging" environment should be builded with minification to check app before delivering on production.

Proposal: remove this warning (

react/src/renderers/dom/ReactDOM.js

Lines 94 to 100
in
67f8524

warning(

(testFunc.name || testFunc.toString()).indexOf('testFn') !== -1,

'It looks like you\'re using a minified copy of the development build ' +

'of React. When deploying React apps to production, make sure to use ' +

'the production build which skips development warnings and is faster. ' +

'See https://fb.me/react-minification for more details.'

);

) for NODE_ENV === 'staging' env, if this possible.

Thanks.

Issue 2:
Hello. Since upgrading to v15 I get this all over the place in my unit tests:

Warning: It looks like you're using a minified copy of the development build of React. When deploying React apps to production, make sure to use the production build which skips development warnings and is faster. See https://fb.me/react-minification for more details.

This warning makes sense in prod but in my case, my toolchain is a little different; I use React with Scala and build a special test-deps.js containing all external JS required by unit tests. Minimising it means it loads faster and so I end up with a valid case for a minimisation of the React dev.

Is there a way to remove this warning? It appears a heap of times as my tests are concurrent.
Issue 1:
Before filing a bug, please check whether it has been fixed since
the latest release: run "hg pull -u" and retry what you did to
reproduce the problem. Thanks.

What steps will reproduce the problem?
1.goinstall github.com/mattn/go-gtk/gtk
2.open browser to http://godashboard.appspot.com/package

What is the expected output?

Should be display github.com/mattn/go-gtk/gtk

What do you see instead?

display github.com/mattn/go-gtk

Which compiler are you using (5g, 6g, 8g, gccgo)?

It is not a problem of golang. This is a bug in $GOROOT/misc/dashboard.
Then, I don't know about appengine's description.

Which operating system are you using?

same above.

Which revision are you using? (hg identify)

same above.

Please provide any additional information below.

same above.

Issue 2:
The following problem occurs in the gcc5 branch and trunk. It was found when testing on pp64le Ubuntu 14.04 and 14.10 but the problem also occurs on x86 with gccgo. It works with golang on both platforms.

Here is a testcase that demonstrates the failure:

package main

import (

"encoding/json"

"fmt"

)

type HostConfig struct {

Memory int64

}

type Config struct {

Hostname string

}

type hostConfigWrapper struct {

InnerHostConfig *HostConfig

}

type ContainerConfigWrapper struct {

*Config

*hostConfigWrapper

}

func main() {

conf := Config{
Hostname: "test1",
}

hostConf := HostConfig{
Memory: 2048,
}

var hc hostConfigWrapper
hc.InnerHostConfig = &hostConf
var cf ContainerConfigWrapper
cf.Config = &conf
cf.hostConfigWrapper = &hc
out1, _ := json.Marshal(cf)
fmt.Println("marshalled data %v\n",string(out1))

}

Output should be:

marshalled data %v

{"Hostname":"test1","InnerHostConfig":{"Memory":2048}}

Output with gccgo:

marshalled data %v

{"Hostname":"test1"}
Issue 1:
Hi,

I've searched the sources to find an equivalent to the Parser and Formatter-concept in AngularJS 1.x. As it looks like, we can use custom Value-Accessors to format and parse bindings.

Is this a good idea?

If yes, is the following implementation (that works and parses/formats a German Date in the format Day.Month.Year) ok?

We are using multi-bindings here. How does Angular 2 behave, when there is more then one Accessor for one component?

Wishes,

Manfred

import {Directive, Renderer, ElementRef, Self, forwardRef, Provider} from 'angular2/core';

import {NG_VALUE_ACCESSOR, DefaultValueAccessor } from 'angular2/common';
import {CONST_EXPR} from 'angular2/src/facade/lang';

const PROVIDER = CONST_EXPR(new Provider(
NG_VALUE_ACCESSOR, {useExisting: forwardRef(() => DateValueAccessor), multi: true}));

@Directive({
selector:
'input[date]',
host: {'(input)': 'input($event.target.value)', '(blur)': 'blur()'},
bindings: [PROVIDER]
})
export class DateValueAccessor extends DefaultValueAccessor {

constructor(_renderer: Renderer, _elementRef: ElementRef) {
super(_renderer, _elementRef);
}

blur() {
this.onTouched();
}

input(value) {

// Write back to model
if (value) {
value = value.split(/\./);
value = value[2] + "-" + value[1] + "-" + value[0];
}

this.onChange(value);
}

writeValue(value: any): void {

// Write to view
if (value) {
var date = new Date(value);
value = date.getDate() + "." + (date.getMonth()+1) + "." + date.getFullYear();
}

super.writeValue(value);

}

}

Issue 2:
I'm submitting a ... (check one with "x")

[x] bug report => search github for a similar issue or PR before submitting
[ ] feature request
[ ] support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question

Current behavior

When navigating between routes that reuse nodes (i.e. different URLs triggering the same route config branches), the guards are fired out of order. Specifically, the guards for the reused node are called before any other guards are checked.

Expected behavior

The guard order should universally be deactivations from leaf to root and then activations from root to leaf.

Minimal reproduction of the problem with instructions

See http://plnkr.co/edit/TQjNmR?p=preview

When changing both nodes in a navigation (i.e. from /A/A to /B/B), the guards are called in the order:

DEACTIVATE: branch

ACTIVATE: branch

DEACTIVATE: leaf

ACTIVATE: leaf

The order should be:

DEACTIVATE: leaf

DEACTIVATE: branch

ACTIVATE: branch

ACTIVATE: leaf

What is the motivation / use case for changing the behavior?

Maintaining a consistent ordering of guards. Deactivating a service tied to a parent route before the service tied to the child could break programmers expectations about flow.

Please tell us about your environment:

Mac OSX, Atom, npm, webpack, served via webpack-dev-server (dev) & nginx (prod).

Angular version: 2.0.X, 2.1.X (plunker demonstrates 2.1.0)

Browser: Only tested in Chrome 53, but should be relevant to all

Language: TypeScript 2.0.3, but should be relevant to all
Issue 1:
React version: 18.2

Steps To Reproduce

download npx create-react-app my-app --template redux-typescript

npm start

Link to code example:

function Ddd() { return ( <React.StrictMode> <Dd /> </React.StrictMode> ); }

function Dd() { console.log(12); return <div>12</div>; }

root.render( <Ddd /> );

The current behavior

Dd render 2 times

The expected behavior

Dd render 1 times

Issue 2:
React version:18.0.0

with 18

import ReactDOM from "react-dom/client";
const root = ReactDOM.createRoot(
document.getElementById("root") as HTMLElement
);
root.render(
<React.StrictMode>
<App />
</React.StrictMode>
);

with 17

import ReactDOM from "react-dom";
ReactDOM.render(
<React.StrictMode>
<App />
</React.StrictMode>,
document.getElementById("root") as HTMLElement
);

and my app demo

import { useEffect } from "react";
import "./App.css";
import "xterm/css/xterm.css";

import { Terminal } from "xterm";
import { io } from "socket.io-client";
import { FitAddon } from "xterm-addon-fit";

const ids = {} as any;
function getTerminal(id: string) {
if (!ids[id]) {
ids[id] = new Terminal();
return ids[id];
} else {
return ids[id];
}
}

let chunk = "";

function App() {
console.log("here");
useEffect(() => {
console.log("run effect");
const term = getTerminal("t1") as Terminal;
const el = document.getElementById("xterm-container") as HTMLDivElement;
const socket = io("ws://localhost:3000");
const fitAddon = new FitAddon();
term.loadAddon(fitAddon);
term.open(el);
fitAddon.fit();

window.addEventListener("resize", (s) => {
fitAddon.fit();
});

term.write("welcome\r\n");

socket.on("to", function (msg: string) {
console.log("receive", msg);
term.write(msg + "\r\n");
});

term.onData((arg1: string) => {
console.log("data-", arg1, chunk);
if (arg1.charCodeAt(0) === 13) {
term.write("\r\n");
console.log("data", arg1);
if (!!chunk) {
if (chunk === "clear") {
term.clear();
chunk = "";
} else {
socket.emit("chat message", chunk);
}
}
chunk = "";
} else if (arg1.charCodeAt(0) === 127 || arg1.charCodeAt(0) === 8) {
chunk = chunk.slice(0, chunk.length - 1);
console.log(chunk);
term.write("\b \b");
} else {
term.write(arg1);
chunk += arg1;
}
});

// return () => {
//	term.dispose()
// }
}, []);

return (
<div className="App">
<header className="App-header">terminal test</header>
<div id="xterm-container"></div>
</div>
);
}

export default App;

code is ok with react17

I'm very confused, may I get your help?
Issue 1:
Rather than the complex script for radio buttons, we should go for a more semantically meaningful option similar to the one in the link below (yes I know it's using javascript but that's only to apply the active class for demonstration).

It is more complex semantically but it gets rid of the javascript and adds native form support.

<div class="btn-group">
<label for="one" class="btn">
<input id="one" name="num" type="radio" />
One
</label>
<label for="two" class="btn">
<input id="two" name="num" type="radio" />
Two
</label>
<label for="three" class="btn">
<input id="three" name="num" type="radio" />
Three
</label>
<label for="four" class="btn">
<input id="four" name="num" type="radio" />
Four
</label>
</div>

http://jsfiddle.net/JamesKyle/RWa7M/

Issue 2:
My data source returns objects instead of strings (because they carry additional metadata besides the autocomplete label)

I can get away with this by overriding every callback to perform the requested logic only on the label, but for some reason, the 'updater' callback returns an [Object object] string instead of my actual data. Browsing the source, I found out that typeahead stores the value it passes to the updater callback in the data-value attribute of the generated entity, which is where it gets coerced to string.

The most obvious solution (that I have applied already to my local code) is to JSON encode the value before being sent to the data-value attribute, but that comes with a performance hit, which is why I'm not providing the patches.

While it could be argued that this could have been avoided by monkeypatching the metadata to the string label, there's no direct way of achieving this using just JSON.
Issue 1:
As Unicode TR11 suggested, all neutral characters map to halfwidth or narrow characters.

According to EastAsianWidth following characters are neutral:

✖ 0x2716

✚ 0x271A

✭ 0x272D

✹ 0x2739

so they should be halfwidth or narrow, but is rendered full-width in CMD.exe, which is causing terminal disarrangement.

Your Windows build number: (Type ver at a Windows Command Prompt)

Microsoft Windows [Version 10.0.16299.125]

Issue 2:
Environment

Windows build number: 10.0.18362.239
Windows Terminal version (if applicable): 0.2.1831
Any other software? No

Steps to reproduce

Just open the terminal and write some text.

Expected behavior

Normal font rendering

Actual behavior

Text is displayed with blurry and aliased font. (The font is Consolas)
Issue 1:
Environment

Windows build number: Microsoft Windows [Version 10.0.18362.418]
Windows Terminal version (if applicable): Version: 0.6.2951.0

Steps to reproduce

1.) Set the initialRows value to 30, and open a new wt instance

2.) Shrink the window to approximately half the size vertically (Drag the bottom up)

3.) Spam a few invalid commands (asd, <Enter>, asd, <Enter>, asd, <Enter>, asd, <Enter>, asd, <Enter>, asd, <Enter>) until the scrollbar appears (It will appear later than expected)

4.) Note that you unable to scroll to the current input location

Expected behavior

You are able to scroll to the current input location

Actual behavior

You are unable to scroll to the current input location without resizing. The scrollbar also only appears when the lines exceed the initialRows value and ignore the actual window height.

Similar to #1494, but that one deals more with the scroll bar not working at all more so than the scrollbar scrolling to the incorrect location / appearing later than expected.

Issue 2:
Environment

Windows build number: 18972

Any other software?: WSL installed

Steps to reproduce

Sign out of Windows

Sign back in

Start Terminal really quickly and open up a WSL instance

The WSL instance does not have Windows file paths connected to it (e.g: typing in cmd.exe fails)

Expected behavior

Even if you open up WSL quickly it should add Windows paths correctly.

Actual behavior

Opening WSL quickly from Windows Terminal upon signing in does not add in Windows file paths correctly

Additional notes

We (the WSL team) don't think this is a WSL specific issue since we use environment variables to add the Windows path. If you open up a CMD window and run wsl very quickly upon startup you still get the correct Windows paths added. This seems to be an issue with how Windows Terminal treats environment variables.