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

Describe the bug

I'm doing a router.push using url, as, and passing query object in options parameter.

When the page is rendered from the server side, the query string is processed fine. However, when using router.push, query seems to be ignored.

To Reproduce

Steps to reproduce the behavior, please provide code snippets or a repository: https://github.com/hgezim/nextjs-scrolll-custom-route-bug

Clone https://github.com/hgezim/nextjs-scrolll-custom-route-bug/

Checkout query_param branch

Run npm run dev

Navigate to http://localhost:4000/recipes/diet-halal?cuisine=greek

Notice in the dev console that the query is set to query L7: Object { cuisine: "greek", filter: "diet-halal" }.

Click the button labeled 95 on the page.

Notice that cuisine isn't picked up here and it only shows filter parameter as part of query in dev console: query L7: Object { filter: "diet-halal" }

Expected behavior

I expect the log statement to look the same when I press button 95, namely: query L7: Object { cuisine: "greek", filter: "diet-halal" }

A clear and concise description of what you expected to happen.

System information

OS: macOS

Browser (if applies) Firefox 70.0.1

Version of Next.js: 9.1.4

Additional context

Add any other context about the problem here.

Issue 2:
Bug report

Describe the bug

Using Next 9's routing solution for a Universal App, "router.query" for post-SSR client-side navigation is never populated even if asPath contains a query string for any of the following

router access methods:

import { SingletonRouter, useRouter, withRouter } from 'next/router';

To Reproduce

Perform an initial navigation to /search?term=hello, the server rendered page's router information contains a populated "query":

const router = useRouter();
console.log({ router }); // asPath: "/search?term=hello", pathname: "/search", query: { term: "hello" }

Then navigate to the same pathname, with a different query string: /search?term=bye. At this point Router empties "query", but has the correct new asPath:

const router = useRouter();
console.log({ router }); // asPath: "/search?term=hello", pathname: "/search", query: {}

Expected behavior

For the client side navigation to a route with specified query parameters such as /search?term=bye, router.query contains the parsed query string.

If this is not expected, it would be helpful to better document this behavior and the correct approach on the client. I would prefer to always access routing information off of the available hook / HOC rather than off window on the client to avoid a split-brain solution between the client and the server.
Issue 1:
It would be a great idea to obtain these utilities through the Windows Store and would be easier for the end user to update them when available.

Issue 2:
Summary of the new feature/enhancement

The idea is to be able to use more than one zone with one window. For example if we have 2 windows, and 3 zones (e.g. 3 vertical zones) I would like that one window uses 2 of them and the other only one.

There are some cases that I can use these 3 zones, but I don't think that switch all the time between different layouts makes sense.

The "auto-dragging" feature, will just when resizing a window pull your window to the next active limit in a zone.
Issue 1:
VSCode Version: 1.0

OS Version: Mac OS X 10.11.4

Steps to Reproduce:

Open the Command Panel which is translated to Chinese

Cannot type English command, only Chinese are accepted

Command should be in English, or add an option to switch that.

Issue 2:
VSCode Version:

バージョン 0.10.12-insider

コミット ef2a1fc

日付 2016-03-21T11:33:38.240Z

シェル 0.35.6

レンダラー 45.0.2454.85

ノード 4.1.1

Even Japanese people, typing Japanese words are very painful and time-consuming because of IME composition problems.

We expects that the commands are all in English.

For example, if I want to execute git pull, I will type "git pull"; not "git プル".

Hope you can understand our situation.
Issue 1:
Mention the authors (see Definitions by: in index.d.ts) so they can respond.

Authors: @bonnici @CodeAnimal @DABH

It would be great, if definitions for winston 3.0.x could be provided.

Issue 2:
I tried using the @types/winston 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: @bonnici @CodeAnimal @DABH

The function "createLogger" to create a new logger instance isn't included in the TS definitions
Issue 1:
Riccardo opened SPR-2861 and commented

All the beans defined in any configuration file are visible from the whole project. t would be useful to be able to limit the visibility of a bean to only the file where it is defined. Something like <bean-local ... >. I have looked in the forum and jira and I couldn't find anything like this.

Issue Links:

#11829 Support @Bean method visibility ("duplicates")

Issue 2:
Eberhard Wolff opened SPR-7170 and commented

In JavaConfig beans created by protected methods with @Bean annotation had visibility inside the @Configuration class only but were not exported into the global ApplicationContext and therefore cannot be referenced from there or other @Configuration annotated classes:

@Configuration
public class MyConfiguration {
@Bean
public ABean globallyVisible() { ... }

@Bean
protected ABean visibleOnlyInThisClass() { ... }
}

This is great to structure large configuration because beans can be hidden. Bring that feature back please.

Affects: 3.0 GA, 3.0.1, 3.0.2

Issue Links:

#12839 Revised support for bean definition visibility and overriding ("is depended on by")

#7548 Allow to restrict the visibility of beans to a file ("is duplicated by")

#10325 Consider using javassist for proxy generation

#12637 Support profile exclusivity and/or bean definition finality

#8713 Exporting / Importing beans across ApplicationContexts

27 votes, 22 watchers
Issue 1:
I keep getting this problem after completing a task. Duplicate user problem?

Issue 2:
After completing some challenges (using ctrl+enter twice) I get redirected to http://www.freecodecamp.com/map where a banner pops up and says "Oops! Something went wrong. Please try again later"

I'm on the beginning of the HTML5 and CSS section

Edit:

I just looked at the console after this happened again and here are the 2 error messages:

[Error] Failed to load resource: the server responded with a status of 403 (Forbidden) (sidecar.js.map, line 0)

[Error] Failed to load resource: the server responded with a status of 404 (Not Found) (jquery.min.map, line 0)
Issue 1:
I have two pieces of logically identical code below with differences only in the order of class definitions. However, that resulted in two different ways being used to define the defineProperty method in the compiled output.

Version 1 compiled into:

import _Object$defineProperty from "babel-runtime/core-js/object/define-property";

Version 2 compiled into:

var _defineProperty = require("babel-runtime/core-js/object/define-property");

Input Code

Version 1

"use strict";

class Test2 {}
class Test1 {
async test() {}
}

Version 2

"use strict";

class Test1 {
async test() {}
}
class Test2 {}

Babel/Babylon Configuration (.babelrc, package.json, cli command)

// .babelrc
{
"presets": ["env", "stage-2"],
"plugins": [
["transform-runtime", {
"helpers": false,
"polyfill": true,
"moduleName": "babel-runtime"
}]
]
}

Expected Behavior

The two different versions of the code here should be compiled in the same way.

Current Behavior

Compiled Version 1

"use strict";

import _Object$defineProperty from "babel-runtime/core-js/object/define-property";

var _promise = require("babel-runtime/core-js/promise");
var _promise2 = _interopRequireDefault(_promise);
var _regenerator = require("babel-runtime/regenerator");
var _regenerator2 = _interopRequireDefault(_regenerator);

/* ... skipping the rest of the file */

Compiled Version 2

"use strict";

var _promise = require("babel-runtime/core-js/promise");
var _promise2 = _interopRequireDefault(_promise);
var _defineProperty = require("babel-runtime/core-js/object/define-property");
var _defineProperty2 = _interopRequireDefault(_defineProperty);
var _regenerator = require("babel-runtime/regenerator");
var _regenerator2 = _interopRequireDefault(_regenerator);

/* ... skipping the rest of the file */

Your Environment

software
version(s)

Babel
6.26.0

node
6.10.3

npm
3.10.10

Operating System
macOS 10.12.6

Issue 2:
💻

Would you like to work on a fix?

How are you using Babel?

babel-loader (webpack)

Input code

no code

Configuration file name

No response

Configuration

No response

Current and expected behavior

If I install newest preset-env with npm, I have to install plugin-syntax-dynamic-import manually due to plugin-syntax-dynamic-import in both dependencies and devDependencies.

update 2021-09-07

Seem like duplicate dependency didn't cause my problem, but we still need to delete plugin-syntax-dynamic-import in devDependencies.

Environment

System:

OS: macOS 11.5.2

Binaries:

Node: 14.17.0 - ~/.nvm/versions/node/v14.17.0/bin/node

Yarn: 1.22.10 - /usr/local/bin/yarn

npm: 6.14.13 - ~/.nvm/versions/node/v14.17.0/bin/npm

npmPackages:

@babel/preset-env: ^7.15.0 => 7.15.0

@babel/runtime: 7.1.2 => 7.1.2

babel-eslint: 8.2.6 => 8.2.6

babel-helper-vue-jsx-merge-props: 2.0.3 => 2.0.3

babel-loader: ^8.0.5 => 8.2.2

Possible solution

delete plugin-syntax-dynamic-import in devDependencies

Additional context

No response
Issue 1:
This has been bugging me for a while:

To guard yourself against mistakes, it's nice to use type aprameters to give a type signatures that depend on its unit, without having any actual members of type T in the structure. Example:

#[derive(Copy)]
pub struct Vector2D<T> {
pub x: f32,
pub y: f32,
}

And make sure operators such as Add only work on vectors of the same space.

Ok, now the problem is that unless T also implements Copy, Vector2D does not actually implement Copy.

fn foo<T>(a: Vector2D<T>) {
let b = a;
let c = a;
// ...
}

The compiler says:

error: use of moved value: `a`
`a` moved here because it has type `math::Vector2D<T>`, which is non-copyable

This can be worked around by specifying that T must be Copy in the definiton of foo

fn foo<T: Copy>(a: Vector<T>) {

While this isn't a blocking issue, it is very confusing, since T is part of the type of Vector2D but isn't instanciated in the structure, so whether T implements copy should have no influence on whether Vector2D is copyable.

The error message doesn't help because it doesn't say anything about T which is what is apparently confusing the compiler. Instead it points to the structure Vector2D which has derive(Foo) right next to it's definition.

Issue 2:
For example:

#[deriving(Clone)]
struct Filter<A, I, P> where I: Iterator<A>, P: FnMut(&A) -> bool {
it: I,
p: P,
}

expands to:

impl<A: Clone, I: Clone, P: Clone> Clone for Filter<A, I, P> where /* .. */ { /* .. */ }

The A: Clone bound is incorrect. Instead deriving should expand to:

impl<A, I, P> Clone for Filter<A, I, P> where
I: Clone,
P: Clone,
/* .. */ { /* .. */ }

This requires generalized where clauses to handle more complex fields like &'a T: Clone.

@nikomatsakis Are where clauses like &'a int: Clone (note: no generic parameter) going to be allowed? If not, writing the syntax extension is going to be harder.
Issue 1:
📝 Add the ability to duplicate custom templates

When creating a template there are 2 basic ways to go about it. Edit an existing template type and Edit the "Create new custom" template type. I believe the ability to duplicate a template would be useful. This is because the largest barrier to entry to creating new templates is the process of creating the zones to start with. This can be time-consuming based on the number and placement of zones in the template.

If you'd like to see this feature implemented, add a 👍 reaction to this post.

Issue 2:
Same issue here with the latest v19.1, even after remapping Alt+Space to different keymap eg. Alt+P, it's not opening up Run at all.

Originally posted by @teekamsuthar in #4938 (comment)
Issue 1:
Using import() with a module seems to just give it an id as a name. It would be nice to either be able to name the chunk, or to use a name derived from the name of the import.

Issue 2:
I have require('moment') in my own module, also I use bootstrap-daterangepicker which also depends on moment, then I saw this in my build log:

./~/moment/moment.js 104 kB {0} [built]
...
[10] ./~/bootstrap-daterangepicker/~/moment/moment.js 104 kB {0} [built]

it seems moment.js has been bundled two times by webpack, and I have enabled DedupePlugin

plugins: [
new webpack.optimize.DedupePlugin(),
new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/),
...
],

How to get rid of the duplication?
Issue 1:
System info

Playwright Version: [v1.32.0]

Operating System: [Windows 11]

Browser: [Chromium]

Other info:

Source code

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

I used a template with electron, vite and playwright set up. Running one test passes no problems, but running multiple ones fails with this error Error: electron.launch: Process failed to launch!. I prepared a simple repo which has the same test duplicated.

Here is a test snippet:

import { test, expect, _electron as electron } from "@playwright/test";

test("homepage has title and links to intro page", async () => {
const app = await electron.launch({ args: [".", "--no-sandbox"] });
const page = await app.firstWindow();
expect(await page.title()).toBe("Electron + Vite + React");
await page.screenshot({ path: "e2e/screenshots/example.png" });
await app.close();
});

Link to the GitHub repository with the repro

https://github.com/IhsenBouallegue/electron-pw

Steps

yarn install

yarn e2e

Expected

All tests run and pass

Actual

A test is failing because of electron.launch()

Issue 2:
Hello amazing team. My team really need some small improvements from you:

Could I ask you about add possibility to put snapshot's picture in some common folder instead of spec name folder. Because better to save some snapshots in one place and not duplicate it in such different folders. (for example: I have 3 spec file spec1.ts, spec2.ts, spec3.ts -it's different tests/suites but as expected I have one file comprising, but I need to keep three folders with one file -> spec1/sample.png; spec2/sample.png; spec3/sample.png)

And could we please skip the automatic generation name of snapshots for different OS (for example: I create snapshot step.png, but MacOS it saved as step-drawing.png, linux - step-linux.png). So it's a little bit complexing for us to run tests on different system and keep updating all this bunch of pictures

Thank you so much!
Issue 1:
Today my Atom crashed and I realized that there is no such thing as restore your unsaved work.

Since this is more than standard nowadays - please add this!

Issue 2:
I love that you can view a file's location when hovering on the tab, but waiting for things to appear on hover is not the strong suit of most devs I know. 😄

Seems context click (two finger, right click, etc) is not being used for anything on tabs currently, what do you think about adding support for displaying that info on both hover AND context click?
Issue 1:
These duplicate the functionality of e.g. uint::range

Issue 2:
The signature of from_raw_buf is:

fn from_raw_buf<T>(p: &'a *const T, len: uint) -> &'a [T]

The fact that the lifetime of the returned slice is the same as the lifetime of the pointer is a very bad idea. And now that CVec is gone, this is the only way to build a slice from a raw pointer.

I can see many potential problems, but the ones that I've encountered while removing CVec is that you can't cast your pointers, not even from mut to const: (http://is.gd/eW1KmQ)

struct Foo { data: *mut i8, len: uint }
impl Foo {
fn as_slice(&self) -> &[i8] {
unsafe {
// value "self.data as *const i8" does not live long enough
std::slice::from_raw_buf(&(self.data as *const i8), self.len)
}
}
}

And that you can't use raw pointers in iterators anymore: (http://is.gd/UsePsX)

struct Iter<'a> { data: *const u8, marker: ContravariantLifetime<'a> }
impl<'a> Iterator for Iter<'a> {
type Item = &'a [u8];
fn next(&mut self) -> Option<&'a [u8]> {
Some(unsafe {
// cannot infer an appropriate lifetime for borrow expression due to conflicting requirements
std::slice::from_raw_buf(&self.data, 1)
})
}
}

If I'm manipulating raw pointers which are unsafe by nature, please let me be unsafe!

The first example can be bypassed by using from_raw_mut_buf and casting the returned &mut [i8] to a &[i8], which means that the unsafe API is more restrictive than the safe API!
Issue 1:
Needs to do a check to see if document is available, otherwise this throws a document is undefined on the server.

https://github.com/callemall/material-ui/blob/47bf496d977d0ff1ef9e1a7615c405b49e81ac2a/src/overlay.jsx#L57-L59

Issue 2:
In my code I added

import {DatePicker} from 'material-ui';

Then i've got error

ReferenceError: document is not defined

at [object Object].componentWillMount (~/node_modules/material-ui/lib/overlay.js:64:34)

I also change my import to

const DatePicker = require('material-ui/lib/date-picker/date-picker');

Still no luck
Issue 1:
Bug Report

Current Behavior

When using object destruction on function parameter types, babel seems not to understand this syntax. Error keep's saying

SyntaxError: /path/to/my/file/inputs.tsx: Unexpected token, expected ")"

I'm pretty sure this is a problem with babel because it works perfectly on ts-loader and tsc.

Also, I've tried two different babel settings

create-react-app 2.1

custom webpack config with @babel/preset-typescript

Input Code

type NumChangeHandler = ({ target }: any) => void

Expected behavior/code

ts-loader with webpack supported this syntax. Also is fine with tsc.

Babel Configuration (.babelrc, package.json, cli command)

create-react-app 2.1 configurations

OR

{
"presets": [
"@babel/typescript"
],
"plugins": [
"@babel/proposal-class-properties",
"@babel/proposal-object-rest-spread"
]
}

Environment

Babel version(s): 7.1.6

Node/npm version: Node 10.13/npm 6.4.1

OS: mac OS 10.13.6

Monorepo: no

How you are using Babel: Create-react-app 2.1.1

Possible Solution

Additional context/Screenshots

Issue 2:
Bug Report

Current Behavior

Code fails with Babel, works with TSC.

Input Code

Babel REPL (ps: needs to install the @babel/plugin-transform-typescript plugin)

TypeScript Playground

This code fails on Babel but not on TSC:

type MyType = ({ theme }: { theme: string }) => string

const x: MyType = {}

This code works on both:

type MyType = (param: { theme: string }) => string

const x: MyType = {}

Expected behavior/code

Support this syntax, because tsc supports it.

Babel Configuration (.babelrc, package.json, cli command)

The one inside Create React App v2, plus typescript preset. (file)

Environment

Babel version(s): 7.1.0

Node/npm version: 5.6.0

OS: macOS 10.14

Monorepo yes (yarn workspace)

How you are using Babel: CRA

Additional context

Possibly related: #8365
Issue 1:
I have a problem of alignment with glyphicons in Android Chrome when use a navbar:

The code of this menu is:

<nav class="navbar navbar-default" role="navigation">
<div class="container-fluid">
...
<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
...
<form action="index.php?comp=search" method="post" class="navbar-form navbar-right" role="search">
<div class="form-group has-feedback">
<input accesskey="b" name="search" id="search" class="form-control " type="text" value="Search..." />
<span class="glyphicon glyphicon-search form-control-feedback"></span>
</div>
</form>
</div>
</div>
</nav>

Issue 2:
When using the has-feedback class on a form and if the label on the form group is not specified then it does not render correctly.

<form>
<div class="form-group has-success has-feedback">
<input type="text" class="form-control" id="inputSuccess2">
<span class="glyphicon glyphicon-ok form-control-feedback"></span>
</div>
</form>

The above code renders like this.
Issue 1:
I am calling to_string() without any parameters and it beautifully fixed-formatted my dataframe apart from my very wide filename column, that is being truncated with "...". How can I avoid that?

FILENAME OBS_ID XUV
0 'mvn_iuv_l1a_IPH3-cycle00007-mode040-muvdark_2... 40 MUV
1 'mvn_iuv_l1a_IPH2-cycle00047-mode050-muvdark_2... 50 MUV
2 'mvn_iuv_l1a_apoapse-orbit00127-mode2001-muvda... 2001 MUV
3 'mvn_iuv_l1a_APP1-orbit00087-mode1031-fuvdark_... 1031 FUV
4 'mvn_iuv_l1a_IPH2-cycle00005-mode060-fuvdark_2... 60 FUV

I tried calling it like this, but to no avail (same output):

with open('test_summary_out.txt','w') as f:
f.write(summarydf.head().to_string(formatters={'filename':lambda x: "{:100}".format(x)}))

Version: 0.16 with Python 3.4

Issue 2:
Bit of a PITA to repeat the information in every PR in a release note for that PR as well. The automation tools in IPython for this work well there and in statsmodels. Would be nice to consider adding these to pandas.

https://github.com/ipython/ipython/blob/master/tools/gh_api.py

https://github.com/ipython/ipython/blob/master/tools/github_stats.py
Issue 1:
It's an incredibly simple feature, but sooo useful. I've had a utility installed to do this for a few years now and I never go on a new windows install without it. When I use other people's PCs as well, I really miss the ability to keep a specific window in front.

How it works:

As I have it at the moment, pressing Ctrl+Space on any desktop window will toggle the always on top state of that window. When that's done, they effectively stay in front, even when focus changes to another window after that.

What it's for:

Doing that allows me to put some content I want to see (a video, browser tab, some instructions, or notes) on my display whilst I work/type into a different window.

When I'm done I just focus my pinned window and use Ctrl+Space to return it to normal.

What I'd change:

Admittedly, the Ctrl+Space key combination is sometimes problematic when gaming, where I might need the same combination for something else. That's why I suggest changing it to some combination with the Win key instead.

Win+Space is (annoying) used to switch keyboard layouts, so it might have to become something like Win+Alt instead.

It would also help, though, to allow the user to configure the shortcut, as well as a visible button to pin/unpin windows similar to the "Maximize to new desktop widget".

Issue 2:
crutkas: Should look at #49 also for additional feature implementation idea

And #641 for transparency
Issue 1:
🐛 Bug

To Reproduce

Reproducer:

import torch

class Bug(torch.nn.Module):
def forward(self, x):
# no bug
# bug: "IndentationError: unexpected indent"
return x

f = torch.jit.script(Bug())

$ python bug.py

Traceback (most recent call last):
File "bug.py", line 9, in <module>
f = torch.jit.script(Bug())
File "/home/mvz/pytorch/torch/jit/__init__.py", line 1188, in script
return torch.jit.torch.jit._recursive.recursive_script(obj)
File "/home/mvz/pytorch/torch/jit/_recursive.py", line 166, in recursive_script
stubs = list(map(make_stub, filtered_methods))
File "/home/mvz/pytorch/torch/jit/_recursive.py", line 163, in make_stub
return torch.jit.script_method(func, _jit_internal.createResolutionCallbackFromClosure(func))
File "/home/mvz/pytorch/torch/jit/__init__.py", line 1265, in script_method
ast = get_jit_def(fn, self_name="ScriptModule")
File "/home/mvz/pytorch/torch/jit/frontend.py", line 164, in get_jit_def
py_ast = ast.parse(dedent_src)
File "/home/mvz/local/anaconda3/envs/ve3/lib/python3.7/ast.py", line 35, in parse
return compile(source, filename, mode, PyCF_ONLY_AST)
File "<unknown>", line 1
def forward(self, x):
^
IndentationError: unexpected indent

cc @suo

Issue 2:
nvcc fatal : The version ('90000') of the host compiler ('Apple clang') is not supported