WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
Bug Report

COMPONENT NAME

docker inventory plugin

ANSIBLE VERSION

ansible 2.4.0 (fix-docker-api 16c324eff6) last updated 2017/08/16 10:35:51 (GMT +200)
config file = /home/yannig/.ansible.cfg
configured module search path = [u'/home/yannig/.ansible/plugins/modules', u'/usr/share/ansible/plugins/modules']
ansible python module location = /home/yannig/dev/ansible/lib/ansible
executable location = /home/yannig/dev/ansible/bin/ansible
python version = 2.7.13 (default, Jan 19 2017, 14:48:08) [GCC 6.3.0 20170118]

CONFIGURATION

None

OS / ENVIRONMENT

Ubuntu 17.04

SUMMARY

With last docker-py 2.0, Docker inventory plugin is broken.

STEPS TO REPRODUCE

Install last version of docker-py (pip install docker-py --upgrade) then launch docker.py in contrib/inventory

EXPECTED RESULTS

$ ./docker.py --list --pretty
{
"38af95bd3ea31": [
"bla1"
],
"38af95bd3ea3131f05cbe0021723cc360b8fd531ceba96611aa21bc299f6c205": [
"bla2"
],
"40b7bccc9f393": [
"bla3"
],

ACTUAL RESULTS

./docker.py --list --pretty
Traceback (most recent call last):
File "./docker.py", line 418, in <module>
class AnsibleDockerClient(Client):
NameError: name 'Client' is not defined

Issue 2:
From @hoall on 2016-09-23T09:35:55Z

ISSUE TYPE

Bug Report

COMPONENT NAME

user

ANSIBLE VERSION

ansible --version
ansible 2.1.2.0 (stable-2.1 4c9ed1f4fb) last updated 2016/09/23 11:24:18 (GMT +200)
lib/ansible/modules/core: (detached HEAD af67009d38) last updated 2016/09/23 11:27:16 (GMT +200)
lib/ansible/modules/extras: (detached HEAD 1bde4310bc) last updated 2016/09/23 11:27:16 (GMT +200)
config file =
configured module search path = Default w/o overrides

CONFIGURATION

OS / ENVIRONMENT

SUMMARY

I'm creating a user with primary group and some other groups.

When using the stable branch, the task from below keeps changed = true. I couldn't find out what is changed, though.

Running the same task with ansible and the modules from devel works correct. Maybe you can merge the changes in ansible-modules-core in stable. Unfortantly, I can't tell which commits.

STEPS TO REPRODUCE

- name: add oracle user
user:
name=oracle
group=oinstall
groups=oinstall,dba
password=foobar
update_password=on_create

EXPECTED RESULTS

On second run, the change should be false and state ok.

TASK [oracle-12c-preparation : add oracle user] ********************************
ok: [mysecret] => {"append": false, "changed": false, "comment": "", "group": 1001, "groups": "oinstall,dba", "home": "/home/oracle", "move_home": false, "name": "oracle", "password": "NOT_LOGGING_PASSWORD", "shell": "/bin/bash", "state": "present", "uid": 1002}

ACTUAL RESULTS

State keeps changed.

TASK [oracle-12c-preparation : add oracle user] ********************************
changed: [mysecret] => {"append": false, "changed": true, "comment": "", "group": 1001, "groups": "oinstall,dba", "home": "/home/oracle", "move_home": false, "name": "oracle", "password": "NOT_LOGGING_PASSWORD", "shell": "/bin/bash", "state": "present", "uid": 1002}

Copied from original issue: ansible/ansible-modules-core#4982
Issue 1:
Eberhard Wolff opened SPR-5001 and commented

Currently a parameter to a Web MVC method can be annotated using @RequestMapping so that a part of the HTTP request is bound to this parameter. I would suggest to add @SessionMapping that allows the same for the HTTP Session.

Issue Links:

#18468 Convenient access to session and request attributes in controller methods ("is superseded by")

Issue 2:
Scott Murphy opened SPR-5377 and commented

Add an additional Annotation for passing objects in the session to a function. Currently it is a little cumbersome to do this because you have to pass the HttpServletRequest object to your function even if that is all you use it for.

For example:

@RequestMapping("/myController.do")
public String doGet(HttpServletRequest request) {
MyObject object = (MyObject) WebUtils.getSessionAttribute(request, "myObject");
return "MyJSP";
}

Should be replaced with:

@RequestMapping("/myController.do")
public String doGet(@SessionParam("myObject") MyObject myObject) {
return "MyJSP";
}

If the object is not in the session, null is passed.

Furthermore, an additional boolean parameter can be supplied to initialize the object and put it in the Session if it is not already there:

e.g.:

@RequestMapping("/myController.do")
public String doGet(@SessionParam(value="myObject", initialize=true) MyObject myObject) {
return "MyJSP";
}

If myObject is not in the session, a MyObject object will be created and placed in the Session.

Affects: 3.0 M1

Issue Links:

#16171 Provide @ModelAttribute(required="false") for session attributes

#18468 Convenient access to session and request attributes in controller methods ("is superseded by")

4 votes, 4 watchers
Issue 1:
The Flask Mailinglist page:

http://flask.pocoo.org/mailinglist/

mentions this page:

http://flask.pocoo.org/mailinglist/archive/

Which shows the latest email from 2012-10-29, giving the impression that the Flask community is no longer active

This page seems to be up to date:

http://librelist.com/browser/flask/

Please update http://flask.pocoo.org/mailinglist/ to reflect this change.

Thank you.

Issue 2:
Install flask:

pip install flask

If test.py contains:

import flask

A PendingDeprecationWarning is emitted:

python -Werror test.py

Traceback (most recent call last):
File "test.py", line 1, in <module>
import flask
File "C:\Users\John Hagen\AppData\Local\Programs\Python\Python35-32\lib\site-packages\flask\__init__.py", line 21, in <module>
from .app import Flask, Request, Response
File "C:\Users\John Hagen\AppData\Local\Programs\Python\Python35-32\lib\site-packages\flask\app.py", line 28, in <module>
from .config import ConfigAttribute, Config
File "C:\Users\John Hagen\AppData\Local\Programs\Python\Python35-32\lib\site-packages\flask\config.py", line 12, in <module>
import imp
File "C:\Users\John Hagen\AppData\Local\Programs\Python\Python35-32\lib\imp.py", line 33, in <module>
PendingDeprecationWarning, stacklevel=2)
PendingDeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses
Issue 1:
With a generic base class,

class GenericBase<T> {
value: T;
}

this compiles without errors:

class StringBase extends GenericBase<string> { }
class Foo extends StringBase { }
var foo = new Foo();
foo.value.charCodeAt(0); // OK

but this produces an error that Property 'charCodeAt' does not exist on type 'T':

function makeBase<T>() {
return class extends GenericBase<T> { };
}
class Bar extends makeBase<string>() { }
var bar = new Bar();
bar.value.charCodeAt(0); // compile error

Since string has been used as the generic parameter for makeBase, it seems that none of the properties on Bar should be typed as T.

Issue 2:
When using extends in a class expression, the generic types do not propagate correctly to the super class of the expression. The below example should compile (I think!), but fails with Type 'C' is not assignable to type 'T'.

class A<T> {
genericVar: T
}

function B<T>() {
return class extends A<T> {
}
}

class C extends B<C>() {
name: string;
}

var c = new C();
c.genericVar = c;
Issue 1:
Bug report

Babel is running translations on files which are inside ignored folder(s)

Expected Behavior

Ignore everything inside ignored folder(s)

Current Behavior

Babel translates items inside the folder if it finds things that tell babel to translate is

Possible Solution

Properly ignore folders, don't even check inside them

Context

Cross-linking reference: hawk#277

Basically we have our src folder in our repo, and our dist repo (uncommitted). The build server runs yarn in the src folder, runs all unit tests inside of it.

If this completes it runs babel translation with the following .babelrc

{
"ignore": [
"node_modules",
"test"
],
"plugins": [
"transform-async-to-generator",
"transform-runtime"
],
"presets": ["es2015"]
}

However, taking a look in my build server, I can see the following log:

src/folder1/handler.js -> dist/folder1/handler.js
src/folder2/handler.js -> dist/folder1/handler.js
...
src/node_modules/hawk/client.js -> dist/node_modules/hawk/client.js
src/node_modules/hawk/dist/browser.js -> dist/node_modules/hawk/dist/browser.js
src/node_modules/hawk/lib/browser.js -> dist/node_modules/hawk/lib/browser.js
src/node_modules/hawk/lib/client.js -> dist/node_modules/hawk/lib/client.js
src/node_modules/hawk/lib/crypto.js -> dist/node_modules/hawk/lib/crypto.js
src/node_modules/hawk/lib/index.js -> dist/node_modules/hawk/lib/index.js
src/node_modules/hawk/lib/server.js -> dist/node_modules/hawk/lib/server.js
src/node_modules/hawk/lib/utils.js -> dist/node_modules/hawk/lib/utils.js
...
src/folder_last/index.js -> dist/folder_last/index.js

Hawk has the following items which (I think) is causing this issue:

.babelrc

Hawk already has said they will not fix this issue, and technically, this is a babel issue imho.

Issue 2:
Feature Request

This is related to @babel/preset-env and @babel/runtime

useBuiltIns:usage is a great feature that helps avoiding unnecessary polyfills. The drawback though is that other libraries still import core-js explicitly. Because of that, I usually have many core-js modules imported twice:

Once as /core-js/modules (via @babel/runtime with 'useBuiltIns:usage') and the second time as /core-js/library/modules

I assume there should be the way to avoid that. Like, for @babel/runtime to import core-js as /core-js/library/modules or programmatically detect polyfills that are already imported
Issue 1:
The objectives right now are pretty confusing:

Your green-box class should give the bottom of elements 20px of padding.

Your green-box class should give the left of elements 40px of padding.

This suggests, to me at least, that through Clockwise Notation it is possible to assign padding to just the Bottom and Just the Left. Total NewB here, but it seems to me that you have to assign it to the top/bottom and left/right. I can't find anyway other than padding-bottom, etc to change the top without changing the top.

Issue 2:
Conflicting statements to confuse new beginners. In the Top portion it asks for "10-pixel-wide green border"; but below in your checks it states "Your image should have a border with a width of 10 pixels."; yet your code must have this:

.thick-green-border {

border-width: 10px;

border-color: green;

border-style: solid;

}

Nothing in there states to make the border solid, the top asks for color while the bottom doesn't not state the color.

I consider myself pretty well beyond beginners level HTML/CSS although not a master by any means, and this one stumped me for a few minutes where i had to ask for help.
Issue 1:
From here:

Hey folks, I think this is a bug. When using ES7 async/await, if I require "babel/polyfill", it's going to be used before polyfill is required (regeneratorRuntime.mark).

Following code:

'use strict';

import {} from 'babel/polyfill';
import fs from 'fs';

async function* foo () {
console.log('foo');
}

async function* bar () {
console.log('bar');
}

Will be transpiled to

'use strict';

function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { 'default': obj }; }

var marked0$0 = [foo, bar].map(regeneratorRuntime.mark);

require('babel/polyfill');

var _fs = require('fs');

var _fs2 = _interopRequireDefault(_fs);

function foo() {
return regeneratorRuntime.async(function foo$(context$1$0) {
while (1) switch (context$1$0.prev = context$1$0.next) {
case 0:
console.log('foo');

case 1:
case 'end':
return context$1$0.stop();
}
}, marked0$0[0], this);
}

function bar() {
return regeneratorRuntime.async(function bar$(context$1$0) {
while (1) switch (context$1$0.prev = context$1$0.next) {
case 0:
console.log('bar');

case 1:
case 'end':
return context$1$0.stop();
}
}, marked0$0[1], this);
}

as you can see, the require statement in line 7 comes too late.

Issue 2:
require("babel/polyfill");
function *hello () {};

After babelification:

"use strict";

var hello = regeneratorRuntime.mark(function hello() {
return regeneratorRuntime.wrap(function hello$(context$1$0) {
while (1) switch (context$1$0.prev = context$1$0.next) {
case 0:
case "end":
return context$1$0.stop();
}
}, hello, this);
});

require("babel/polyfill");
;

This would result in ReferenceError: regeneratorRuntime is not defined was found when discussion this issue with @zeusdeux
Issue 1:
The comma and right parenthesis emitted from JSX-transforming a line like that in the title will result in the following:

// source JSX
var ExampleCommaIssue = React.createClass({
render: function () {
return <div style={({'margin':'42px'})} className="test" />;
}
});

// transforms to
... React.createElement("div", {style: ({'margin':'42px'}, )className: "test"}); ...

// instead of
... React.createElement("div", {style: ({'margin':'42px'}), className: "test"}); ...

Notably, this only seems to be a problem if some attribute follows the one with the paren-hugged object literal.

Also, I did not test to see if arbitrary values in parentheses also result in this.

Issue 2:
I'm keeping the last values passed as props without force a re-render, I'm using the useRef to store the elements without re-render the output.

The weird part is that the values showed are different from what I'm storing, duplicating the last elements.

React version: 17.0.2

Link to code example:

https://codesandbox.io/s/stupefied-ride-m1did?file=/src/App.js

import React from "react";

const ComR = React.memo(function Compo({ id, value }) {
const lastElements = React.useRef([0, 0, 0, 0, 0]);
const [_, ...m] = [...lastElements.current, value]; // remove first and insert last
lastElements.current = m;
console.log("rendering", id, value, memo.current);
return (
<div>
{id} - {lastElements.current.join(", ")}
</div>
);
});

export default function App() {
const [value, setValue] = React.useState(0);

React.useEffect(() => {
setInterval(() => {
setValue(Math.ceil(Math.random() * 10000));
}, 7000);
}, [setValue]);

return (
<div className="App">
<ComR id="1" value={value} />
</div>
);
}

The current behavior

The console.log is showing different what is printing into the component

The expected behavior

expects work as linear array operations, since was called/rendered once
Issue 1:
I find myself in many situations executing Ansible to deploy systems but frequently want to use the same credential set to SSH to those machines. Currently for static hosts I am keeping two lists of the same information .ssh/config and a hosts file.

So what I am suggesting would be to use Ansible's inventory to enable more rapid SSH connections including but not limited to connecting to static hosts and to dynamic inventory when the result set is a single node.

Issue 2:
There's a lot of useful information in the ansible inventory, including remote usernames, connection methods, etc. I wish I could take advantage of that when I need a shell on a "remote" host by running something like 'ansible-connect hostname'.

This would, ideally, launch an interactive shell on the target host taking into account ansible_host, remote_user, become, become_user, connection type, etc.
Issue 1:
https://drive.google.com/file/d/0BxmeIv484tR5R1JhRjlYTTRIVUk/view?usp=sharing

This is bug? Or how to disable...

My system:

Ubuntu 14.04

Resolution 1920x1080 (13 inch display)

Issue 2:
I've just installed Atom from a git checkout on Ubuntu 12.10, and the attached screenshot is what I see (I've shrunk the editor font size). I'm assuming that fonts aren't really meant to be that large.
Issue 1:
Feature request

Is it possible to use next.config.ts instead of next.config.js?

Currently none of the typescript examples use typescript in the config file. Is it even possible?

@resir014

Issue 2:
Hi, I'm developing web using Next and Express. Currently i'm facing issue when applying moment locale on the web. It shows that mark up that generated on server and client is different (Screenshot attached).

I'm applying moment's locale on custom _document.js. How to fix this issue?

I have searched the issues of this repository and believe that this is not a duplicate.

Expected Behavior

It should generate same markup on server and client

Current Behavior

It generate different markup on server and client

Steps to Reproduce (for bugs)

Repository

Context

Your Environment

Tech
Version

next
^3.0.1-beta.8

express
^4.15.3

moment
^2.18.1

react
^15.6.1

node
v6.11.0

OS
macOS Sierra 10.12.1

browser
Chrome Version 59.0.3071.115
Issue 1:
TypeScript Version:

nightly (1.9.0-dev.20160429)

Code

function isFoo(value: any): value is Foo {
return value && typeof value.foo === 'function';
}

interface Foo {
foo(): string;
}

interface Bar {
bar(): string;
}

function convertBar(input: Foo | Bar): () => string {
return isFoo(input) ? function () {
return input.foo(); // <-- Property 'foo' does not exist on type 'Foo | Bar'.
} : input.bar;
}

Expected behavior:

Receive no errors (as per 1.8)

Actual behavior:

Receive the error Property 'foo' does not exist on type 'Foo | Bar'.

Issue 2:
TypeScript Version:

1.7.5 (TS6029)

Code

// var t = 0; if(t) { document.write('defined'); } else { document.write('undefined'); }

Expected behavior:

the variable is defined

Actual behavior:

the variable is undefined

Prove at Playground:

http://goo.gl/UI4ymi
Issue 1:
Apache Airflow version:

2.0.0

Kubernetes version (if you are using kubernetes) (use kubectl version):

1.15.x

Environment:

Cloud provider or hardware configuration: AWS

What happened:

Apparently removed task state causes Airflow to consider dag_run as active, due to removed not being part of finished frozenset:

https://github.com/apache/airflow/blob/v2-0-stable/airflow/utils/state.py#L103

What you expected to happen:

Removed state is counted as finished

How to reproduce it:

Create a dag run, backfill with success (-m) and then deploy a change removing some tasks. Airflow will now count it as active

Issue 2:
Apache Airflow version: 2.0.0

Kubernetes version (if you are using kubernetes) (use kubectl version):

Environment:

OS (e.g. from /etc/os-release): Debian GNU/Linux 10 (buster)

Kernel (e.g. uname -a): Linux 6ae65b86e112 5.4.0-52-generic #57-Ubuntu SMP Thu Oct 15 10:57:00 UTC 2020 x86_64 GNU/Linux

Others: Python 3.8

What happened:

After migrating one of our development Airflow instances from 1.10.14 to 2.0.0, the scheduler started to refuse to schedule tasks for a DAG that did not actually exceed its max_active_runs.

When it did this the following error would be logged:

DAG <dag_name> already has 577 active runs, not queuing any tasks for run 2020-12-17 08:05:00+00:00

A bit of digging revealed that this DAG had task instances associated with it that are in the removed state. As soon as I forced the task instances that are in the removed state into the failed state, the tasks would be scheduled.

I believe the root cause of the issue is that this filter does not filter out tasks that are in the removed state.

What you expected to happen:

I expected the task instances in the DAG to be scheduled, because the DAG did not actually exceed the number of max_active_runs.

How to reproduce it:

I think the best approach to reproduce it is as follows:

Create a DAG and set max_active_runs to 1.

Ensure the DAG has ran successfully a number of times, such that it has some history associated with it.

Set one historical task instance to the removed state (either by directly updating it in the DB, or deleting a task from a DAG before it has been able to execute).

Anything else we need to know:

The Airflow instance that I ran into this issue with contains about 3 years of task history, which means that we actually had quite a few task instances that are in the removed state, but there is no easy way to delete those from the Web UI.

A work around is to set the tasks to failed, which will allow the scheduler to proceed.
Issue 1:
I have searched the issues of this repository and believe that this is not a duplicate.

Expected Behavior

Expected at least nested objects be supported and parsed correctly from query

Current Behavior

It takes the whole thing as a key, instead of creating an nested object

Doesn't matter the format, none of them works

/?nested[key]=value

or

/?nested.key=value

Steps to Reproduce (for bugs)

Open the page with the pattern above

Print the this.props.url.query in top level page component

Does not work

Context

I can't pass nested object over arbitrarily if I am not using <Link /> component, actually I'm not sure if <Link /> would work with nested object since it is using npm 'url' which does not supported nested object parsing...

Btw, I'm currently using https://github.com/ljharb/qs for parsing atm, I hope this saves you all time if you are looking for alternatives.

Your Environment

Tech
Version

next
2.4.6

node
8.1.3

OS
macOS Sierra

browser
chrome

etc

Issue 2:
I have searched the issues of this repository and believe that this is not a duplicate.

Specific to the with-apollo-auth example:

When I try to access a page when NOT authenticated, I get errors "Network error: document is not defined", which is coming from with-data.js, "document.cookie" in the parseCookies function.

This behavior looks like to happens on the SSR side (when the page is refreshed or directly accessed for example).

Expected Behavior

I should be able to access a page with graphQL queries even if the user is not authenticated.

Steps to Reproduce (for bugs)

Install with-apollo-auth example repo.

Add a page using a react component with a graphQL query.

Access with page with an unauthenticated user.

Context

I have a bunch of pages on the app that should be public, with authenticated users having edit privileges.

My Environment

Tech
Version

next
3.2.1

node
8.4.0

OS
Mac

browser
Chrome
Issue 1:
I run pip install scrapy, and it only gives me the error:

then I realized there is something wrong with cryptography, then I found this would be helpful: Install Cryptography using your own openssl on os x

Accroding to the link above, I run the following command:

$ brew install openssl
$ env ARCHFLAGS="-arch x86_64" LDFLAGS="-L/usr/local/opt/openssl/lib" CFLAGS="-I/usr/local/opt/openssl/include" pip install cryptography
$ pip install scrapy

Then I successfully installed scrapy.

I don't know whether it's common for OS X users, if so, I think maybe the installation guide could be more specific for OS X.

System: OS X Yosemite 10.10.2

Python : 2.7.9

Issue 2:
[jooddang@a ~]$ scrapy startproject tutorial

Traceback (most recent call last):

File "/usr/local/bin/scrapy", line 7, in

from scrapy.cmdline import execute

File "/Library/Python/2.7/site-packages/scrapy/init.py", line 48, in

from scrapy.spiders import Spider

File "/Library/Python/2.7/site-packages/scrapy/spiders/init.py", line 10, in

from scrapy.http import Request

File "/Library/Python/2.7/site-packages/scrapy/http/init.py", line 12, in

from scrapy.http.request.rpc import XmlRpcRequest

File "/Library/Python/2.7/site-packages/scrapy/http/request/rpc.py", line 7, in

from six.moves import xmlrpc_client as xmlrpclib

ImportError: cannot import name xmlrpc_client

On Python console

import scrapy

makes error - can't import _monkeypatches module