sharjeelyunus/github-issues-dataset huggingface dataset:
Repository: tensorflow
Issue: Image-Scaling Attacks: Discuss threat and mention secure scaling options to prevent attacks
Labels: comp:ops,type:docs-feature

## URL(s) with the issue:

https://www.tensorflow.org/api_docs/python/tf/image/resize

## Description of issue:
TensorFlow is vulnerable to image-scaling attacks if specific scaling algorithms and parameters are used. These attacks
allow an adversary to arbitrarily change the output image of a downscaling operation. It is a threat for machine learning applications, similar to adversarial examples. 

The resize documentation should therefore at least mention the risk of scaling attacks with specific resize settings, and motivate the usage of secure algorithms/parameters.

### Clear description
Downscaling is an important step in machine learning, as deep neural networks usually expect small fixed-sized inputs. An adversary can control the output of the downscaling step by slightly manipulating the input image. We see another image what the ML system uses for learning. This allows an attack, similar to adversarial examples. The attack is easy to deploy with a considerable impact on the security of machine learning. It is relevant whenever TF scales images that users did not create themselves.

We verified that TensorFlow provides vulnerable scaling algorithms, such as nearest, bilinear or bicubic scaling. In the default settings, many pixels are hardly or not at all included in the reduction. Attacks can thus only change those pixels that are relevant to the scaling. The remaining pixels are not changed, so that the attack is rather unnoticeable. A secure scaling algorithm should thus consider all pixels (equally).

To prevent the attack in TensorFlow, a user can either choose area scaling or set ```antialias = True``` with TensorFlow 2.x. This parameter was introduced in TF 2.x, but it is set to False by default (probably for compatibility to older version). Nearest neighbor scaling is still vulnerable if ```antialias = True``` (antialias is here ignored as documented). For older TensorFlow versions, only area scaling prevents the attack without changing the code base.

Our project website ([https://scaling-attacks.net](https://scaling-attacks.net)) shows some examples and gives more information. In our research paper on scaling attacks [1], presented at the USENIX Security Symposium, we provide a detailed root-cause analysis and discuss possible defenses.

_All in all, the resize documentation should raise the awareness for the risk of scaling attacks in machine learning. 
In the long run, scaling algorithms with secure parameters should be used as default (e.g. ```antialias = True``` as default)._



[1] Adversarial Preprocessing: Understanding and Preventing Image-Scaling Attacks in Machine Learning, Erwin Quiring et al., USENIX Security Symposium 2020. [Paper-Link](https://www.sec.cs.tu-bs.de/pubs/2020-sec.pdf)
Repository: godot
Issue: Creating signals generates no code in external editor
Labels: bug,topic:editor,confirmed

***Bugsquad edit:** This issue has been confirmed several times already. No need to confirm it further.*

___

**Godot version:**
3.2.2 stable


**OS/device including version:**
linux mint 64 bit


**Issue description:**
I am using latest VSCode. External editor opens/switches to vscode when accessing code ok. However when I select to create a signal, it sets the signal as created in the godot IDE, it switches to vscode and opens the correct script file, but no code is generated, as per video, it simply jumps to line 1.

Additionally when you double click on the signal to go to the code it doesn't open editor. If I manually create the signal in the correct place, double clicking still does not open the editor. If I go to an existing signal already created then it switches to vscode fine.

As a side note, if I create a new script file and open it, vscode opens and the default templates are populated ok, so it is just signals and nothing to do with creating new code...

![vscode](https://user-images.githubusercontent.com/12863685/90313580-996b5480-df05-11ea-947d-3fd306d27898.gif)



Project settings for vscode are:
code
-g {file}:{line}:{col}


**Steps to reproduce:**
1. create a signal
2. no code is created
Repository: youtube-dl
Issue: [RUTV] russia.tv: Failed to parse JSON  (caused by ValueError.....
Labels: cant-reproduce

<!--

######################################################################
  WARNING!
  IGNORING THE FOLLOWING TEMPLATE WILL RESULT IN ISSUE CLOSED AS INCOMPLETE
######################################################################

-->


## Checklist

<!--
Carefully read and work through this check list in order to prevent the most common mistakes and misuse of youtube-dl:
- First of, make sure you are using the latest version of youtube-dl. Run `youtube-dl --version` and ensure your version is 2020.07.28. If it's not, see https://yt-dl.org/update on how to update. Issues with outdated version will be REJECTED.
- Make sure that all provided video/audio/playlist URLs (if any) are alive and playable in a browser.
- Make sure that all URLs and arguments with special characters are properly quoted or escaped as explained in http://yt-dl.org/escape.
- Search the bugtracker for similar issues: http://yt-dl.org/search-issues. DO NOT post duplicates.
- Finally, put x into all relevant boxes (like this [x])
-->

- [x] I'm reporting a broken site support
- [x] I've verified that I'm running youtube-dl version **2020.07.28**
- [x] I've checked that all provided URLs are alive and playable in a browser
- [x] I've checked that all URLs and arguments with special characters are properly quoted or escaped
- [x] I've searched the bugtracker for similar issues including closed ones


## Verbose log

<!--
Provide the complete verbose output of youtube-dl that clearly demonstrates the problem.
Add the `-v` flag to your command line you run youtube-dl with (`youtube-dl -v <your command line>`), copy the WHOLE output and insert it below. It should look similar to this:
 [debug] System config: []
 [debug] User config: []
 [debug] Command-line args: [u'-v', u'http://www.youtube.com/watch?v=BaW_jenozKcj']
 [debug] Encodings: locale cp1251, fs mbcs, out cp866, pref cp1251
 [debug] youtube-dl version 2020.07.28
 [debug] Python version 2.7.11 - Windows-2003Server-5.2.3790-SP2
 [debug] exe versions: ffmpeg N-75573-g1d0487f, ffprobe N-75573-g1d0487f, rtmpdump 2.4
 [debug] Proxy map: {}
 <more lines>
-->

```
PASTE VERBOSE LOG HERE
```


## Description

<!--
Provide an explanation of your issue in an arbitrary form. Provide any additional information, suggested solution and as much context and examples as possible.
If work on your issue requires account credentials please provide them or explain how one can obtain them.
-->

WRITE DESCRIPTION HERE
Repository: neovim
Issue: Alternative to vim `norestore` to exclude a terminal buffer from history/jumplist
Labels: enhancement,terminal

I cannot find any way to avoid adding a terminal buffer to the jump list, Vim has an option that can be passed to `termopen` called `norestore` that accomplishes that. Is there a way to do the same in neovim?
Repository: create-react-app
Issue: Support babel macros on dependencies.
Labels: issue: proposal,needs triage

Currently, CRA only supports babel macros when they are in the application's code. It doesn't support macros on dependencies.

### Is your proposal related to a problem?

Yes.

I have an internal library meant to be used by several React applications.

This library uses [the babel plugin "preval" through a babel macro](https://github.com/kentcdodds/babel-plugin-preval#use-with-babel-plugin-macros) to transform its code at build-time. These transformations can't happen when building the library; they need to happen when building the application because they depend on the application's environmental variables.

Unfortunately, I can't use this library on CRA applications without ejecting.

Here's a code example:

`node_modules/my-library/index.js`
```jsx
import preval from 'babel-plugin-preval/macro'

// complex computation based on environmental variables
export const one = preval`module.exports = 1 + 2 - 1 - 1`
```

`src/App.js`
```jsx
import React from 'react';
import { one } from 'my-library';

function App() {
  return <div>The number: {one}</div>;
}

export default App;
```

This produces the following error: `MacroError: The macro you imported from “undefined” is being executed outside the context of compilation with babel-plugin-macros.`


### Describe the solution you'd like

This could be solved by adding `babel-plugin-macros` to the list of plugins on `packages/babel-preset-react-app/dependencies.js`.

Currently, `babel-plugin-macros` is present only on `packages/babel-preset-react-app/create.js`.

### Additional context

Related issues, PRs, and resources:
- https://github.com/facebook/create-react-app/issues/2730
- https://github.com/facebook/create-react-app/pull/3675
- [All about macros with babel-plugin-macros](https://www.youtube.com/watch?v=nlAHtAQlFGk) - Video by @kentcdodds 

This pattern works in Gatsby, but I couldn't find documentation about it, so I don't know if it's officially supported. Here's the relevant PR:
- https://github.com/gatsbyjs/gatsby/pull/7129
Repository: youtube-dl
Issue: How to automatically resume?? [Errno 11001]
Labels: question

<!--

######################################################################
  WARNING!
  IGNORING THE FOLLOWING TEMPLATE WILL RESULT IN ISSUE CLOSED AS INCOMPLETE
######################################################################

-->


## Checklist

<!--
Carefully read and work through this check list in order to prevent the most common mistakes and misuse of youtube-dl:
- Look through the README (http://yt-dl.org/readme) and FAQ (http://yt-dl.org/faq) for similar questions
- Search the bugtracker for similar questions: http://yt-dl.org/search-issues
- Finally, put x into all relevant boxes (like this [x])
-->

- [x] I'm asking a question
- [x] I've looked through the README and FAQ for similar questions
- [x] I've searched the bugtracker for similar questions including closed ones


## Question

<!--
Ask your question in an arbitrary form. Please make sure it's worded well enough to be understood, see https://github.com/ytdl-org/youtube-dl#is-the-description-of-the-issue-itself-sufficient.
-->

How can I get it to resume the download when this error occurs?

![imagen](https://user-images.githubusercontent.com/30112536/90316515-b6e1f380-def0-11ea-8725-3f27b2ab0382.png)

The program is great but it must cover some needs such as retrying to connect for any error without user intervention like any basic program to download from YouTube.
Repository: pytorch
Issue: [docs] LR schedulers' get_last_lr missing in docs online
Labels: module: docs,triaged

https://pytorch.org/docs/master/search.html?q=get_last_lr&check_keywords=yes&area=default#
![image](https://user-images.githubusercontent.com/1041752/90317248-3f2fbb00-df28-11ea-8d29-0ee16e078b3f.png)


shows nothing. despite get_last_lr being recommended by PyTorch warnings for getting the last computed lr

cc @jlin27
Repository: go
Issue: x/tools/gopls: add a work-around for file watching bug in VS Code
Labels: gopls,Tools,gopls/metadata

VS Code currently does not allow the language server to watch files outside of the workspace root:  https://github.com/microsoft/vscode/issues/100870.

This means that users who open subdirectories of modules or modules with replace directives may see bugs because `gopls`'s view of the workspace state is incorrect.

@heschik has suggested that we should add a work-around to address this -- we could clear out the entire cache when we see >= 10 (or fewer?) batched `didChangeWatchedFiles` notifications. We can do this for any module with a replace directive or for any workspace whose root is not the module root.
Repository: scrcpy
Issue: Copy / Paste Broken on Android 10
Labels: copy_paste,root

 - [X] I have read the [FAQ](https://github.com/Genymobile/scrcpy/blob/master/FAQ.md).
 - [X] I have searched in existing [issues](https://github.com/Genymobile/scrcpy/issues).

**Environment**
 - OS: Windows 10
 - scrcpy version: v1.16
 - installation method: Windows release
 - device model: Samsung Galaxy S9
 - Android version: 10

**Problem**
Unable to copy content from desktop to phone. Clipboard not syncing and paste (alt+v / ctl+v) not working. Last worked in v1.14. Issues https://github.com/Genymobile/scrcpy/issues/1658 and https://github.com/Genymobile/scrcpy/issues/1668 did not seem relevant. Text injection however (alt+shift+v) _does_ work.

```
INFO: scrcpy 1.16 <https://github.com/Genymobile/scrcpy>
* daemon not running; starting now at tcp:5037
* daemon started successfully
C:\Users\#\Scrcpy\scrcpy-server: 1 file pushed, 0 skipped. 59.8 MB/s (33622 bytes in 0.001s)
[server] INFO: Device: samsung SM-G960F (Android 10)
INFO: Renderer: direct3d
INFO: Initial texture: 1080x2216
[server] INFO: Device clipboard set
```

**Screen cap:**

![screencap](https://i.imgur.com/LHUAthQ.gif)
Repository: godot
Issue: Saved OccluderPolygons get scaled incorrectly
Labels: bug,topic:editor

<!-- Please search existing issues for potential duplicates before filing yours:
https://github.com/godotengine/godot/issues?q=is%3Aissue
-->

**Godot version:**
<!-- Specify commit hash if using non-official build. -->
3.2.2-stable


**OS/device including version:**
<!-- Specify GPU model, drivers, and the backend (GLES2, GLES3, Vulkan) if graphics-related. -->
Windows 10 Home 2004

**Issue description:**
<!-- What happened, and what was expected. -->
The saved OccluderPolygon gets squished between ancestor and descendent scenes.
![ezgif-4-6214342714cc](https://user-images.githubusercontent.com/12777564/90319565-f3e0d100-df56-11ea-9c13-2aa4ec4d78ee.gif)

**Steps to reproduce:**
1. Make ancestor `KinematicRigidbody2D` and add a `LightOccluder2D`. Create and save its `OccluderPolygon2D`.
1. Inherit this scene. Attempt to load the `OccluderPolygon2D` from FileSystem.

**Minimal reproduction project:**
<!-- A small Godot project which reproduces the issue. Drag and drop a zip archive to upload it. -->
Couldn't be reproduced minimally.
Repository: godot
Issue: Division by float 0 in rasterizer_scene_high_end_rd.cpp
Labels: bug,topic:rendering

**Godot version:**
4.0.dev.custom_build. 69c81309c



**OS/device including version:**
<!-- Specify GPU model, drivers, and the backend (GLES2, GLES3, Vulkan) if graphics-related. -->


**Issue description:**
When I open project then dividing by float 0 happens:
```
servers/rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp:1136:52: runtime error: division by zero
servers/rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp:1137:52: runtime error: division by zero
```
https://github.com/godotengine/godot/blob/e0ee38b128fa84b8e7db499ead66264ca4ec9c60/servers/rendering/rasterizer_rd/rasterizer_scene_high_end_rd.cpp#L1134-L1137

**Steps to reproduce:**
1. Open minimal project with undefined sanitizer support

**Minimal reproduction project:**
https://github.com/qarmin/RegressionTestProject/archive/3.2.zip
Repository: godot
Issue: Implicit conversion from type 'CharType' to type 'char' changed the value in file_access.cpp
Labels: bug,topic:core

<!-- Please search existing issues for potential duplicates before filing yours:
https://github.com/godotengine/godot/issues?q=is%3Aissue
-->

**Godot version:**
4.0.dev.custom_build. 69c81309c


**OS/device including version:**
Ubuntu 20.04

**Issue description:**
Error 
```
core/os/file_access.cpp:309:19: runtime error: implicit conversion from type 'CharType' (aka 'wchar_t') of value 196 (32-bit, signed) to type 'char' changed the value to -60 (8-bit, signed)
```

https://github.com/godotengine/godot/blob/c2151e18135817c9f926a5a00341016ac77301d4/core/os/file_access.cpp#L302-L315


**Steps to reproduce:**
1. Open minimal project

**Minimal Project**
https://github.com/qarmin/RegressionTestProject/archive/master.zip
Repository: flutter
Issue: WidgetSpans not working in the override of buildTextSpan in a custom TextEditingController
Labels: framework,d: api docs,a: typography,a: error message,P3,team-framework,triaged-framework

Here is the code I am using:
```
class MentioningTextEditingController extends TextEditingController {

  BuildContext context;
  MentioningTextEditingController({String text}) : super(text: text);

  @override
  TextSpan buildTextSpan({TextStyle style, bool withComposing}) {
    return TextSpan(
      style: style,
      children: _InteractiveTextState.buildTextSpans(context, text, style, false, null),
    );
  }
}
```

The "_InteractiveTextState.buildTextSpans" method is very complex but simply returns some WidgetSpans with constant dimension (they are are RichText widgets in Containers), but to simplify also just returning basic widgets inside WidgetSpans still gives this error:
```

════════ Exception caught by rendering library ═════════════════════════════════════════════════════
The following assertion was thrown during performLayout():
'package:flutter/src/widgets/widget_span.dart': Failed assertion: line 105 pos 12: 'dimensions != null': is not true.`
```
It seems that using WidgetSpans in an override of buildTextSpan always doesn't work and gives this error. Also using those same WidgetSpans (returned by "_InteractiveTextState.buildTextSpans") in a RichText Widget in a normal Widgets hierarchy works perfectly.
<details>
 <summary>flutter doctor -v</summary>

```
[√] Flutter (Channel master, 1.21.0-9.0.pre, on Microsoft Windows [Version 10.0.18363.1016], locale en-US)
    • Flutter version 1.21.0-9.0.pre at C:\src\flutter
    • Framework revision 77b4505c80 (9 days ago), 2020-08-06 18:51:02 -0700
    • Engine revision cd3ea1e839
    • Dart version 2.10.0 (build 2.10.0-3.0.dev fcafd43f2c)


[√] Android toolchain - develop for Android devices (Android SDK version 30.0.0)
    • Android SDK at C:\Users\Steven\AppData\Local\Android\sdk
    • Platform android-30, build-tools 30.0.0
    • Java binary at: C:\Program Files\Android\Android Studio\jre\bin\java
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)
    • All Android licenses accepted.

[√] Chrome - develop for the web
    • Chrome at C:\Program Files (x86)\Google\Chrome\Application\chrome.exe

[√] Android Studio (version 4.0)
    • Android Studio at C:\Program Files\Android\Android Studio
    • Flutter plugin version 48.1.2
    • Dart plugin version 193.7361
    • Java version OpenJDK Runtime Environment (build 1.8.0_242-release-1644-b01)

[√] Connected device (3 available)
    • Web Server (web) • web-server • web-javascript • Flutter Tools
    • Chrome (web)     • chrome     • web-javascript • Google Chrome 84.0.4147.125
    • Edge (web)       • edge       • web-javascript • Microsoft Edge 81.0.416.62

• No issues found!
```
</details>
Repository: bitcoin
Issue: qa: Functional tests are intrinsic vulnerable to timeouts
Labels: Brainstorming,Tests

On master (3ab2582c7fe76d2839ab493512758d5601903c86) with this patch:
```diff
--- a/src/net.cpp
+++ b/src/net.cpp
@@ -2868,7 +2868,7 @@ int64_t CConnman::PoissonNextSendInbound(int64_t now, int average_interval_secon
 
 int64_t PoissonNextSend(int64_t now, int average_interval_seconds)
 {
-    return now + (int64_t)(log1p(GetRand(1ULL << 48) * -0.0000000000000035527136788 /* -1/2^48 */) * average_interval_seconds * -1000000.0 + 0.5);
+    return now + (int64_t)(log1p(((1ULL << 48) - 1) * -0.0000000000000035527136788 /* -1/2^48 */) * average_interval_seconds * -1000000.0 + 0.5);
 }
 
 CSipHasher CConnman::GetDeterministicRandomizer(uint64_t id) const
```

a bunch of functional tests fail due to the timeout:
```
feature_notifications.py                | ✖ Failed  | 62 s
interface_rest.py                       | ✖ Failed  | 63 s
interface_zmq.py                        | ✖ Failed  | 64 s
mempool_persist.py                      | ✖ Failed  | 62 s
mempool_unbroadcast.py                  | ✖ Failed  | 32 s
p2p_blocksonly.py                       | ✖ Failed  | 61 s
p2p_feefilter.py                        | ✖ Failed  | 63 s
p2p_getaddr_caching.py                  | ✖ Failed  | 62 s
p2p_permissions.py                      | ✖ Failed  | 63 s
p2p_segwit.py                           | ✖ Failed  | 69 s
p2p_tx_download.py                      | ✖ Failed  | 75 s
rpc_deprecated.py                       | ✖ Failed  | 62 s
rpc_psbt.py                             | ✖ Failed  | 65 s
rpc_psbt.py --descriptors               | ✖ Failed  | 67 s
rpc_rawtransaction.py                   | ✖ Failed  | 64 s
wallet_abandonconflict.py               | ✖ Failed  | 63 s
wallet_balance.py                       | ✖ Failed  | 63 s
wallet_basic.py                         | ✖ Failed  | 68 s
wallet_basic.py --descriptors           | ✖ Failed  | 72 s
wallet_bumpfee.py                       | ✖ Failed  | 64 s
wallet_groups.py                        | ✖ Failed  | 62 s
wallet_implicitsegwit.py                | ✖ Failed  | 62 s
wallet_listreceivedby.py                | ✖ Failed  | 62 s
wallet_listtransactions.py              | ✖ Failed  | 62 s
wallet_resendwallettransactions.py      | ✖ Failed  | 62 s
```

Just bumping timeout values only decreases the probability of a new timeout failure occurrence.

Suggested solution #19588 was ugly and controversial, and it has being closed for now.

Related issues:
- #18832
- #18969
- #19265
- #19311
- #19711
Repository: godot
Issue: PosKey in tilemap use int16_t but allows to set to this variable int(int32_t)
Labels: bug,topic:core

**Godot version:**
4.0.dev.custom_build. 69c81309c


**OS/device including version:**
Ubuntu 20.04


**Issue description:**
```
scene/2d/tile_map.cpp:838:17: runtime error: implicit conversion from type 'int' of value 61913 (32-bit, signed) to type 'int16_t' (aka 'short') changed the value to -3623 (16-bit, signed)
scene/2d/tile_map.cpp:838:12: runtime error: implicit conversion from type 'int' of value 65129 (32-bit, signed) to type 'int16_t' (aka 'short') changed the value to -407 (16-bit, signed)
```
https://github.com/godotengine/godot/blob/e0ee38b128fa84b8e7db499ead66264ca4ec9c60/scene/2d/tile_map.cpp#L837-L838

**Steps to reproduce**
1. Compile Godot with this flags(output may be a little spammed)
```
scons p=x11 -j6 use_asan=yes use_ubsan=yes CCFLAGS="-fsanitize=pointer-compare,pointer-subtract,shift,shift-exponent,integer-divide-by-zero,unreachable,vla-bound,null,return,signed-integer-overflow,bounds,float-divide-by-zero,float-cast-overflow,nonnull-attribute,returns-nonnull-attribute,bool,enum,vptr,pointer-overflow,builtin,nullability-return,nullability-arg,function,nullability-assign,implicit-integer-sign-change,implicit-signed-integer-truncation,implicit-unsigned-integer-truncation" use_llvm=yes;sudo cp bin/godot.x11.tools.64.llvms /usr/bin/godots
```
**Minimal reproduction project:**
Probably most project with a little advanced tiles should work but this happens with
https://github.com/qarmin/The-worst-Godot-test-project/archive/master.zip