WhereIsAI/github-issue-similarity huggingface dataset:
Issue 1:
code:

pub fn str_join(strs: &[AsRef<str>], join: str) -> String {
strs.iter().fold(String::new(), |mut acc, s| {
if !acc.is_empty() { acc.push_str(join); }
acc.push_str(s);
acc
});
}

fn main() {}

message:

<anon>:2:10: 2:16 error: no method named `iter` found for type `&[core::convert::AsRef<str>]` in the current scope
<anon>:2 strs.iter().fold(String::new(), |mut acc, s| {
^~~~~~
<anon>:2:10: 2:16 note: the method `iter` exists but the following trait bounds were not satisfied: `core::convert::AsRef<str> : core::marker::Sized`, `core::convert::AsRef<str> : core::marker::Sized`
<anon>:1:38: 1:42 error: the trait `core::marker::Sized` is not implemented for the type `str` [E0277]
<anon>:1 pub fn str_join(strs: &[AsRef<str>], join: str) -> String {
^~~~
<anon>:1:38: 1:42 note: `str` does not have a constant size known at compile-time
<anon>:1 pub fn str_join(strs: &[AsRef<str>], join: str) -> String {
^~~~
<anon>:3:13: 3:27 error: the type of this value must be known in this context
<anon>:3 if !acc.is_empty() { acc.push_str(join); }
^~~~~~~~~~~~~~
note: in expansion of closure expansion
<anon>:2:37: 6:6 note: expansion site
error: aborting due to 3 previous errors
playpen: application terminated with error code 101

in particular, the 'not satisifed' trait bounds has two duplicated results:

note: the method iter exists but the following trait bounds were not satisfied: core::convert::AsRef<str> : core::marker::Sized, `core::convert::AsRef : core::marker::Sized``

this currently happens on the beta and nightly release channels (stable doesn't display this message at all)

playpen link

Issue 2:
At present, fd_set is defined as libnative::io::c::fd_set, on both Windows and Linux. However, I can't use this, as it's not made "pub mod c" in mod.rs.

I'm writing a binding from a C network-related library (libircclient) to Rust, and would like fd_set to be available without having to duplicate effort.
Issue 1:
I have a simple panel with four button groups in a fluid grid system, but they keep detaching one from another when I try to scale down the parent. Is there any way of fixing this?

EDIT: Basically what I want is the groups to stay together. And also there is another bug with this, that is if I have a button with icon only, it gets smaller that the button with text and/or icon. In the fiddle there is no such a bug i.e. it doesn't show up IDK why. Notice on the picture my quick little dirty way of fixing it with a dot after the OK glyph. Here is a picture of that: http://i.imgur.com/MelvudM.png

Fiddle: http://jsfiddle.net/Jy7e6/3/

Issue 2:
I am not sure if it should be fixed or not. If I use grouped action buttons in a <td> without specified width it will look like in example above.

Tried to apply white-space: nowrap or removing a space between <button> tags but it didn't help.
Issue 1:
System Info

transformers version: 4.25.1

Platform: Linux-5.15.0-58-generic-x86_64-with-glibc2.35

Python version: 3.9.13

Huggingface_hub version: 0.10.0

PyTorch version (GPU?): 1.12.1.post201 (False)

Tensorflow version (GPU?): not installed (NA)

Flax version (CPU?/GPU?/TPU?): 0.6.3 (cpu)

Jax version: 0.4.1

JaxLib version: 0.4.1

Using GPU in script?: No

Using distributed or parallel set-up in script?: No

Who can help?

@rooa @patrickvonplaten @patil-suraj

Information

The official example scripts

My own modified scripts

Tasks

An officially supported task in the examples folder (such as GLUE/SQuAD, ...)

My own task or dataset (give details below)

Reproduction

The CodeGen tokenizer seems to remove the newline symbol in certain scenarios.

In particular, decode(encode(text)) does not always equal the original text.

The following is the smallest example that reproduces the error but other text examples will have this issue as well.

from transformers import CodeGenTokenizer

# other checkpoints in the CodeGen series have the same issue
tokenizer = CodeGenTokenizer.from_pretrained("Salesforce/codegen-350M-multi")

# new line (10), space (32), space (32)
text = "\n "
print([ord(c) for c in text])
# output: [10, 32, 32]

encoded = tokenizer.encode(text)
print(encoded)
# output: [50286]

decoded = tokenizer.decode(encoded)
print([ord(c) for c in decoded])
# actual: [32, 32]
# expected: [10, 32, 32]

Expected behavior

Expected: the decoded string is equal to the original string.

Actual: the decoded string is missing the leading new line symbol.

Issue 2:
System Info

transformers version: 4.24.0

Platform: Linux-5.4.0-135-generic-x86_64-with-glibc2.31

Python version: 3.10.8

Huggingface_hub version: 0.11.1

PyTorch version (GPU?): 1.13.1 (True)

Tensorflow version (GPU?): not installed (NA)

Flax version (CPU?/GPU?/TPU?): not installed (NA)

Jax version: not installed

JaxLib version: not installed

Using GPU in script?: no

Using distributed or parallel set-up in script?: no

Who can help?

@ArthurZucker

Information

The official example scripts

My own modified scripts

Tasks

An officially supported task in the examples folder (such as GLUE/SQuAD, ...)

My own task or dataset (give details below)

Reproduction

Steps to reproduce the behavior:

load a PreTrainedTokenizer that contains unique_no_split_tokens, e.g. EleutherAI/gpt-j-6B.

tokenizer = transformers.GPT2Tokenizer.from_pretrained('EleutherAI/gpt-j-6B')

use the tokenizer to split a string that contains a unique_no_split_tokens, e.g. " 
 ".

print(tokenizer(" 
 ").input_ids)

Expected behavior

The tokenizer splits the string into 3 tokens (" ", "
" and " "), and gives their ids ([220, 50257, 220]). This is the behavior of PreTrainedTokenizerFast.

But the actual behavior is that the PreTrainedTokenizer only gives the id of "
", i.e. 50257
Issue 1:
Issue Type:

Bug Report

Bugfix Pull Request

Ansible Version:

1.9.4

Ansible Configuration:

[defaults]
inventory=inventory

Environment:

./inventory/g
./host_vars/h1
./host_vars/h2
./playbook.yml

Summary:

host_vars are not loaded when using inventory directory and --limit flag

Steps To Reproduce:

#./inventory/g
h1
h2

#./host_vars/h1

---
key: h1

#./host_vars/h2

---
key: h2

#./playbook.yml

---

- name: test host_vars includes
gather_facts: no
hosts: all
tasks:
- debug: var=hostvars['h1'].key
- debug: var=hostvars['h2'].key

ansible-playbook playbook.yml -l h1

Expected Results:

PLAY [test host_vars includes] ************************************************

TASK: [debug var=hostvars['h1'].key] ******************************************
ok: [h1] => {
"var": {
"hostvars['h1'].key": "h1"
}
}

TASK: [debug var=hostvars['h2'].key] ******************************************
ok: [h1] => {
"var": {
"hostvars['h2'].key": "h2"
}
}

PLAY RECAP ********************************************************************
h1 : ok=2 changed=0 unreachable=0 failed=0

Actual Results:

PLAY [test host_vars includes] ************************************************

TASK: [debug var=hostvars['h1'].key] ******************************************
ok: [h1] => {
"var": {
"hostvars['h1'].key": "h1"
}
}

TASK: [debug var=hostvars['h2'].key] ******************************************
ok: [h1] => {
"var": {
"hostvars['h2'].key": "{{hostvars['h2'].key}}"
}
}

PLAY RECAP ********************************************************************
h1 : ok=2 changed=0 unreachable=0 failed=0

Issue 2:
This bug report is a result investigating https://groups.google.com/forum/#!searchin/ansible-project/limit$20hostvars$20/ansible-project/ZZ12KPiOE2s/rfdotpnmKgAJ .

It turns out that the host_vars/ directory must be relative to the inventory file when the host is not included in --limit. Ansible can define any such requirement, but note that it is inconsistent to be more liberal with the placement of the host_vars directory when a file is not excluded with --limit (i.e., if the host is included in the run, either the directory relative to the playbook can be used, or the directory relative to the inventory file).

To reproduce, see the project in http://feliksik.nl/ansible-limit.tgz structure, which structure looks as follows (modify inventory to your environment, of course).

.
├── host_vars
│ └── outlimit
├── inventory
├── playbook.yml
└── sub
└── inventory -> ../inventory

There is the following calls possible:

root1) ansible-playbook -i inventory playbook.yml --limit inlimit

root2) ansible-playbook -i inventory playbook.yml --limit inlimit,outlimit

sub1) ansible-playbook -i sub/inventory playbook.yml --limit inlimit

sub2) ansible-playbook -i sub/inventory playbook.yml --limit inlimit,outlimit

Expected behaviour:

if root2 works, then root1 should also work

if sub2 works (i.e. it is legal for the host_vars directory to not be in the same directory as the inventory file), then sub1 should also work.

Actual behavior:

root1 works

root2 works

sub1 fails!

sub2 works
Issue 1:
When my server returns a 400 response with text, the xhr backend does not route this through to the error observer, and instead calls the success path.

I am porting a service from angular 1 to angular 2, and this was not a problem in angular 1, nor is it a problem with rxjs-dom, which I am using in the meantime.

Affected area:

https://github.com/angular/angular/blob/master/modules/angular2/src/http/backends/xhr_backend.ts#L41

What rxjs-dom does and I think angular 2 should do similarly:

https://github.com/Reactive-Extensions/RxJS-DOM/blob/master/src/ajax/ajax.js#L76

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

Test Repo - https://github.com/mildfuzz/angular-mockError

I am unable to test predicted HTTP error responses. Mockbackend can either send a response with an error code (which my app treats as a successful response in the test environment, but as an error in real world)

I am unable to send status codes with an error response in my tests, so I can not test any error handling my application might implements.

Expected behavior

at least one of the defined test cases passes

Minimal reproduction of the problem with instructions

Test Repo - https://github.com/mildfuzz/angular-mockError

this is a re-opening of issue #7471, which was closed due to lack of repro steps.

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

To be able to test all responses

Please tell us about your environment:

OsX

Angular version: 2.0.X

Angular 2.1.0

Browser: [all | Chrome XX | Firefox XX | IE XX | Safari XX | Mobile Chrome XX | Android X.X Web Browser | iOS XX Safari | iOS XX UIWebView | iOS XX WKWebView ]

Chrome 54

Language: TypeScript 2.0.3

Node (for AoT issues): node --version = 6.9.1
Issue 1:
With 0.20, we now have an excellent Color Picker in PowerToys (thanks to @martinchrzan). There's an opportunity here to create something that goes beyond just picking colors and really speeding up the workflow for (front-end) developers and designers. An editor window could really help to expand the current feature set.

Here's a breakdown of features that might be interesting to add.

Current color picker improvements (Should have)

Support more zoom levels (100% / 500%?)

Theming support (light / dark / high contrast)

(Visual) feedback that the color is copied to clipboard

Support for color-picking :hover states of e.g. a button (this can be done by using the zoom functionality)

Add keyboard shortcuts to zoom (+ - - ) and using arrow keys to control the picker for pixel accuracy.

Making the zoom-in feature more accessible / easy to use / discoverable

Change cursor to a color dropper when in color-picking mode.

Show color name (for accessibility)

Add a way to still support page/window scrolling when in picker mode (e.g. color picker zoom only activated on holding keyboard key (Ctrl?)?) (Can be done by scrolling first?)

Color editor

A color editor could be a view that will show up automatically after picking a color, or can be launched directly. It would provide the following features.

History of colors (Should have)

The ability to see previously picked colors.

Color palette & tweaking (Nice to have)

Automatically generate similar color tones based on the selected color (for e.g. having a nice hover color for a button)

Tweaking the selected color within the editor to do some fine-tuning

More/configurable color code formats (Should have)

It would be great to support more color formats. And for front-end developers, it would be even better to provide code snippets for popular languages (e.g. CSS) to make it even more useful. Clicking on a color code would automatically copy it to clipboard.

Support for more color formats (Must have)

Configurable color formats: let the user create custom color formats so they have the complete freedom to create something custom. It would be nice to re-sort the list or to set a format as the default copy-to-clipboard. The format editor would live in Settings. (Should have)

Proposal: plug-in based?

There's a WinUI 2.4 UWP mock-up available for anyone to check out here: https://github.com/niels9001/ColorPickerUX

Looking forward to see other feature requests.

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

Issue 2:
Compare the time in the taskbar and the texts in Run

This was shot from a 1366x768 WXGA screen.
Issue 1:
http://typescript.codeplex.com/workitem/645

At the moment it's not possible to call super getter/setter when overriding properties:

class A {
private _property: string;
get property() { return this._property; }
set property(value: string) { this._property = value }
}

class B extends A {
set property(value: string) {
super.property = value + " addition";
}
}

Issue 2:
Enum value incrementation does not consider previously defined values, nor does the compiler throws an error on duplicate values.

Which means you can end up with potential bugs:

enum Color {Red = 3, Green = 2, Blue};

Color.Red == Color.Blue; //true
Issue 1:
If a id hidden-xs to a glyphicon it breaks. So it is not in one row.

<h1>dazorni <span class="hidden-xs glyphicon glyphicon-headphones"></span> music</h1>

Issue 2:
related to issues #8500 , #7808 , #4929 ; using .hidden-sm to hide span within .nav > li > a . Because class is display: block above -sm then text wraps to new line. Would you consider .hidden-* classes to be display: inline-block instead ?

Here's a jsfiddle of the two cases - but the repercussions could be greater outside of this situation so probably needs more consideration... http://jsfiddle.net/jholl/P86yf/
Issue 1:
Stefan Rufer opened SPR-9013 and commented

AbstractEnvironment calls the overridable method customizePropertySources from the default constructor. This gives subclasses a good chance to run into uninitialized member variables (see attached test case for an example).

Affects: 3.1 GA

Attachments:

CustomizedEnvironment.java (486 bytes)

CustomizedEnvironmentTest.java (362 bytes)

Issue Links:

#14288 Revisit AbstractEnvironment constructor invocation of protected #customizePropertySources ("is duplicated by")

Referenced from: commits 7535e24

3 votes, 6 watchers

Issue 2:
Joern Barthel opened SPR-1338 and commented

Hence I configure my @Entity (and such) annotated domain objects as Spring beans I was reluctant to provide a list of them to the AnnotationSessionFactoryBean FactoryBean's setAnnotatedClasses() method. Instead I wrote a rather trivial BeanPostProcessor which provides a list of @Entity beans to the SessionFactory.

If there is an interest in putting this into e.g. org.springframework.orm.hibernate3.annotation I'd post the classes here.

Attachments:

AnnotationSessionFactoryBean.java (1.92 kB)

entity-discovery.zip (4.07 kB)

Issue Links:

#9415 Scan classpath for persistence annotations when creating session factory for hibernate ("is duplicated by")

6 votes, 7 watchers
Issue 1:
... the right layout is shown in background (see yellow arrow).

Workaround is to restart application.

Issue 2:
Environment

Windows build number: 10.0.18363.836
PowerToys version: 0.18.1
PowerToy module for which you are reporting the bug (if applicable):Fancy Zones

Not sure if this specific issue is already mentioned, but just to be sure it is...

Steps to reproduce

I have two screens, using two different grids. For argument's sake let's call them monitor 1 and 2, and grid 1 and 2.

In the Windows Settings i changed the Primary Display from 1 to 2 (or the other way around). As it turns out, it's more about expanding desktops

Expected behavior

Either no change of position (= fixed to display device) OR to have them swapped around (= fixed to primary/secondary screen)

Actual behavior

After the swap (edit: expansion and/or swaping), both grids appear on the same monitor.

When i swap the priority back, both grids appear on their original screen.

Screenshots
Issue 1:
the package dson_core-0.13.2 raises a compiler error, but flutter build apk does not stops and produces a crashing apk, here the output of the command:

Running "flutter packages get" in flutter_seafuture... 0.5s
Initializing gradle... 0.6s
Resolving dependencies... 1.1s
Running 'gradlew assembleRelease'...
Configuration 'compile' in project ':barcode_scan' is deprecated. Use 'implementation' instead.
compiler message: file:///home/sherpya/.pub-cache/hosted/pub.dartlang.org/dson_core-0.13.2/lib/src/deserializer.dart:167:43: Error: The method 'add' isn't defined for the class 'dart._internal::EfficientLengthIterable<dynamic>'.
compiler message: Try correcting the name to the name of an existing method, or defining a method named 'add'.
compiler message: fillerList.forEach((item) => resultList.add(_convertValue(subType, item, "@LIST_ITEM")));
compiler message: ^
Compiler terminated unexpectedly.
Built build/app/outputs/apk/release/app-release.apk (9.0MB).

After two runs the compiler error disappears but obviously the apk is incorrect

Initializing gradle... 0.6s
Resolving dependencies... 0.9s
Running 'gradlew assembleRelease'...
Configuration 'compile' in project ':barcode_scan' is deprecated. Use 'implementation' instead.
Built build/app/outputs/apk/release/app-release.apk (9.0MB).

Issue 2:
Using nested Scaffolds can cause unexpected behaviors that rush new issues into this repository,

to prevent further issue reports related, I suggest an assertion in the Scaffold Class just for Debug Mode:

assert(() {
assert(context.ancestorWidgetOfExactType(Scaffold) == null);
});

These are some of the issues:

#23051

#20289

#12084

#20295
Issue 1:
Hey guys,

First, thanks for your hard work. I appreciate it. I can't get Pager to work with a <span>. This surprised me because <span> is an inline element like <a>.

Here's the problem: EDITED http://jsfiddle.net/rEvmb/

This is related to: #2680

you can still use other inline tags like em, b, span or any other if permitted by your template engine.

<ul class="pager">
<li><span id="blogPosts:backLink" class="previous">Previous</span></li>
<li><a href="#" id="blogPosts:forwardLink" class="next">Next</a></li>
</ul>​

Why a span? Sigh. I don't want to make excuses or use this to justify my bug report... but when my template engine disables a link programmatically, it transforms it from <a> to <span>. This is sort of duplicate functionality that Bootstrap also provides.

Issue 2:
If .show or .hide is called on a tooltip or popover, the tip is first .removed, effectively destroying all bindings applied to itself and all child elements of it.

This makes the creation of form-like elements, i.e. the reaction on buttons, very cumbersome.

Instead of using .remove, a .detach could be used on the .open and .close method.

In order to allow the total removal of a tooltip/popover, a .destroy or .remove method could be implemented that effectively duplicates the current state of the .hide method.
Issue 1:
The first time I launch the DatePicker the OK button at the bottom seems to be disabled. Clicking outside the DatePicker and then relaunching it the second time has the button enabled. material-ui v 0.8.0

It appears that since I did not specify an initial value for the DatePicker that it picks the current date which is invalid in my use case. But the OK button does not become enabled by selecting a valid date.

Issue 2:
If you set a minDate after the current date the OK button is disable and date cannot be chosen.
Issue 1:
System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow):no

OS Platform and Distribution (e.g., Linux Ubuntu 16.04):CentOS Linux release 7.2

TensorFlow installed from (source or binary):Anaconda python 3.6.5(conda install)

TensorFlow version (use command below):1.8.0

Python version: 3.6.5

Bazel version (if compiling from source): 0.7.0

GCC/Compiler version (if compiling from source): 4.8.5

CUDA/cuDNN version:cuda-9.0

GPU model and memory: P40

Phone: N/A

Describe the problem

Hi ~

When I used API 'tf.contrib.quantize.experimental_create_training_graph' to add quantization nodes, it will match some layers**(not all convs layers)** to add quantization nodes. This will lead to some layers using float32, but some with float8(quantization bit is 8). When I use 'toco_convert', it just support inference_type: Currently must be {FLOAT, QUANTIZED_UINT8}. I think it need all layers to be FLOAT or QUANTIZED_UINT8. So it will raise this errors.

Error log

F tensorflow/contrib/lite/toco/tooling_util.cc:1445] Array model/resnet_model/Relu, which is an input to the Conv operator producing the output array model/resnet_model/conv2d_1/Conv2D, is lacking min/max data, which is necessary for quantization. Either target a non-quantized output format, or change the input graph to contain min/max information, or pass --default_ranges_min= and --default_ranges_max= if you do not care about the accuracy of results.\n'

So I think it is contradictory in the API. pls help me, thank you.

Network

Network: ResNet20

TF version: r1.8(I find it dose not support --default_ranges_min and --default_ranges_max in the python api of r1.8. But in r1.9 it supports)

Issue 2:
System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow):no

OS Platform and Distribution (e.g., Linux Ubuntu 16.04):CentOS Linux release 7.2

TensorFlow installed from (source or binary):Anaconda python 3.6.5(conda install)

TensorFlow version (use command below):1.8.0

Python version: 3.6.5

Bazel version (if compiling from source): 0.7.0

GCC/Compiler version (if compiling from source): 4.8.5

CUDA/cuDNN version:cuda-9.0

GPU model and memory: P40

Phone: N/A

Hi~

When I use 'tf.contrib.quantize.experimental_create_training_graph' it will add fake quantization in the graph. reference this picture(find positions to insert fake quantization nodes).

I think it will add a fake quantization node in the bypass, but I can not find it in the tensorboard graph(in the red box, it is the bypass). In other convs, I can find the quantization node.

My network architecture is ResNet20, tensorflow version is 1.8.0

pls help me. thank you.
Issue 1:
Windows does some funny things with environmental variables. There are 2 interfaces: an ASCII and a Unicode one: a problem arises in that any libraries "getting" from the ASCII one (in my case, R) won't see anything "set" by the Unicode one (which is used by Julia).

See discussion on julia-users:

https://groups.google.com/d/msg/julia-users/hqHnMbrnHT4/qTeEkYvU5xgJ

Issue 2:
Loading the array literal in this gist either at the REPL or via include leads to an ERROR: OverflowError() on v"0.4.0-dev+5994", but works fine on v0.3.8.