id
int64
393k
2.82B
repo
stringclasses
68 values
title
stringlengths
1
936
body
stringlengths
0
256k
labels
stringlengths
2
508
priority
stringclasses
3 values
severity
stringclasses
3 values
316,529,644
neovim
While recording a macro, no pause is given to see result of command
<!-- Before reporting: search existing issues and check the FAQ. --> - `nvim --version`: v0.3.0-1056-ga1530ec - Vim (version: 7.4) behaves differently? no - Operating system/version: Linux/WSL - Terminal name/version: conhost/1803 - `$TERM`: xterm-256color N/A ### Steps to reproduce using `nvim -u NORC` ``` nvim -u NORC q :echo "foo" ``` ### Actual behaviour status line reads `recording @q` ### Expected behaviour status line should temporarily display `foo` before reverting to `recording @q`
enhancement,ux
low
Minor
316,539,507
vscode
end keyword matching for Ruby, Lua, Julia, Elixir, Crystal and others
<!-- Do you have a question? Please ask it on https://stackoverflow.com/questions/tagged/vscode. --> <!-- Use Help > Report Issue to prefill these. --> - VSCode Version: 1.22.0 - OS Version: Manjaro Linux 17.1.8 Steps to Reproduce: 1. Open a Ruby `.rb` file 2. Try to match `end` keywords <!-- Launch with `code --disable-extensions` to check. --> Does this issue occur when all extensions are disabled?: Yes Hi community! I'm happy user of Vim and VSCode :smile: On Vim I can match Ruby, Lua, Julia, Elixir, Crystal `end` keywords using matchit. By example, the following code is for Crystal on Vim: ![crystal](https://user-images.githubusercontent.com/3067335/29022601-a35ac1f2-7b2f-11e7-9067-fd6b626068ed.gif) Would be nice to have something similar on VSCode.
feature-request,languages-basic,editor-bracket-matching
medium
Major
316,556,598
pytorch
[caffe2] global average pool in caffe2
- Caffe2: - from source - Python version:2.7 - CUDA/cuDNN version:cuda 8.0/cudnn 6 - GPU models and configuration:1070 How can achieve the global average pool in caffe2
caffe2
low
Minor
316,558,103
puppeteer
Serialize Uint8Arrays better
### Steps to reproduce **Tell us about your environment:** * Puppeteer version: 1.3.0 * Platform / OS version: macOS Sierra * URLs (if applicable): ... * Node.js version: master **What steps will reproduce the problem?** _Please include code that reproduces the issue._ 1. Open a new page with puppeteer 2. Run `page.evaluate(() => new Uint8Array(1024 * 1024 * 10)` **What is the expected result?** Puppeteer takes over 20 seconds to serialize/deserialize 10MB and the resulting object is not a Uint8Array. **What happens instead?** A Uint8Array should be returned and it should take a reasonable amount of time (single-digit miliseconds tops and not seconds). ---- This basically would require inspecting objects returned from `evaluate`, detecting they're Uint8Arrays and then serializing them differently.
feature,good first issue,chromium
medium
Major
316,571,903
godot
[Bullet] Bullet Physics HingeJoint motor stops and restarts spinning every 360°
**Godot version:** Godot 3.0.2 official **OS/device including version:** macOS Sierra 10.12.6 **Issue description:** Using HingeJoint and activating motor it stops and restarts spinning every 360°. This happens only using default physics engine settings (Bullet). Switching to Godot physic engine the motor spins regurarly. **Steps to reproduce:** Create a simple 3D scene and add a camera. Add a StaticBody and a RigidBody with its own MeshInstance and CollisionShape using a cube as mesh. Add a HingeJoint and in its nodes properties set the StaticBody (Node A) and the RigidBody (Node B). In the HingeJoint properties enable the motor and run the project. I made also a video, see the second half. https://youtu.be/htBEKQu8Iy4 **Minimal reproduction project:** <!-- Recommended as it greatly speeds up debugging. Drag and drop a zip archive to upload it. --> [HingeJoint_issue.zip](https://github.com/godotengine/godot/files/1935516/HingeJoint_issue.zip)
bug,confirmed,topic:physics,topic:3d
medium
Critical
316,572,384
pytorch
Jetson TX1 Caffe2 installation fails on latest JetPack release
PyTorch GitHub Issues Guidelines -------------------------------- Using the Latest Jetpack 3.2 on a Jetson TX1 and a completely fresh OS setup, Caffe2 installation fails. Steps: git clone --recursive https://github.com/pytorch/pytorch.git cd pytorch git submodule update --init cd scripts ./build_tegra_x1.sh Error message: ``` [ 79%] Linking CXX executable ../bin/operator_fallback_gpu_test ../lib/libcaffe2_gpu.so: undefined reference to `void caffe2::math::BiasCHW<float, caffe2::CUDAContext>(float const*, int, int, float*, caffe2::CUDAContext*)' collect2: error: ld returned 1 exit status caffe2/CMakeFiles/elementwise_op_gpu_test.dir/build.make:115: recipe for target 'bin/elementwise_op_gpu_test' failed make[2]: *** [bin/elementwise_op_gpu_test] Error 1 CMakeFiles/Makefile2:1614: recipe for target 'caffe2/CMakeFiles/elementwise_op_gpu_test.dir/all' failed make[1]: *** [caffe2/CMakeFiles/elementwise_op_gpu_test.dir/all] Error 2 [ 79%] Building CXX object caffe2/CMakeFiles/caffe2_pybind11_state_gpu.dir/python/pybind_state_mkl.cc.o ../lib/libcaffe2_gpu.so: undefined reference to `void caffe2::math::BiasCHW<float, caffe2::CUDAContext>(float const*, int, int, float*, caffe2::CUDAContext*)' collect2: error: ld returned 1 exit status caffe2/CMakeFiles/operator_fallback_gpu_test.dir/build.make:115: recipe for target 'bin/operator_fallback_gpu_test' failed make[2]: *** [bin/operator_fallback_gpu_test] Error 1 CMakeFiles/Makefile2:1570: recipe for target 'caffe2/CMakeFiles/operator_fallback_gpu_test.dir/all' failed make[1]: *** [caffe2/CMakeFiles/operator_fallback_gpu_test.dir/all] Error 2 [ 80%] Building CXX object caffe2/CMakeFiles/caffe2_pybind11_state_gpu.dir/python/pybind_state_gpu.cc.o [ 80%] Linking CXX shared module python/caffe2_pybind11_state_gpu.so [ 80%] Built target caffe2_pybind11_state_gpu Makefile:138: recipe for target 'all' failed make: *** [all] Error 2 ``` Can someone give me a hint on how to get things running?
caffe2
low
Critical
316,573,506
flutter
Fill remaining space between slivers with sliver
Is there a sliver to fill the remaining space between slivers? I'm having a lot of trouble trying to find something that works in Flutter for this. Here is an example of two `ListView` slivers. I'm looking for a sliver to push down the second sliver to the bottom of the screen. ![bitmap](https://user-images.githubusercontent.com/36620537/39094757-2def8d0c-4678-11e8-8ce8-5b68cd714894.png) `SliverFillRemaining` (which fills up the empty space if it's available) nearly does this but "there is never any room for anything beyond this sliver" so you can't display the second `ListView` sliver. Also, you can't measure the `ListView` at run time so you can't just create your own Sliver that calculates the height of the remaining space - height of the second `ListView`. ``` class _MyHomePageState extends State<MyHomePage> { @override Widget build(BuildContext context) { final outer = new SliverList( delegate: new SliverChildListDelegate(new List<Text>.generate(20, (int i) { return new Text("List 1 - Item $i"); }))); final inner = new SliverList( delegate: new SliverChildListDelegate(new List<Text>.generate(3, (int i) { return new Text("List 2 - Item $i"); }))); return new Scaffold( body: new CustomScrollView( slivers: <Widget>[outer, inner], ), ); } } ```
c: new feature,framework,f: scrolling,customer: crowd,P3,team-framework,triaged-framework
medium
Major
316,583,272
youtube-dl
error occurs at Freshlive.tv
## Please follow the guide below - You will be asked some questions and requested to provide some information, please read them **carefully** and answer honestly - Put an `x` into all the boxes [ ] relevant to your *issue* (like this: `[x]`) - Use the *Preview* tab to see what your issue will actually look like --- ### Make sure you are using the *latest* version: run `youtube-dl --version` and ensure your version is *2018.04.16*. If it's not, read [this FAQ entry](https://github.com/rg3/youtube-dl/blob/master/README.md#how-do-i-update-youtube-dl) and update. Issues with outdated version will be rejected. - [x] I've **verified** and **I assure** that I'm running youtube-dl **2018.04.16** ### Before submitting an *issue* make sure you have: - [x] At least skimmed through the [README](https://github.com/rg3/youtube-dl/blob/master/README.md), **most notably** the [FAQ](https://github.com/rg3/youtube-dl#faq) and [BUGS](https://github.com/rg3/youtube-dl#bugs) sections - [x] [Searched](https://github.com/rg3/youtube-dl/search?type=Issues) the bugtracker for similar issues including closed ones - [x] Checked that provided video/audio/playlist URLs (if any) are alive and playable in a browser ### What is the purpose of your *issue*? - [ ] Bug report (encountered problems with youtube-dl) - [x] Site support request (request for adding support for a new site) - [ ] Feature request (request for a new functionality) - [ ] Question - [ ] Other --- ### The following sections concretize particular purposed issues, you can erase any section (the contents between triple ---) not applicable to your *issue* --- ### If the purpose of this *issue* is a *bug report*, *site support request* or you are not completely sure provide the full verbose output as follows: 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 here. It should look similar to one below (replace it with **your** log inserted between triple ```): ``` MacBook-Pro-3:Downloads gaeaearth$ youtube-dl --cookies cookies.txt https://freshlive.tv/sakuragakuin/199580 -F -v [debug] System config: [] [debug] User config: [] [debug] Custom config: [] [debug] Command-line args: [u'--cookies', u'cookies.txt', u'https://freshlive.tv/sakuragakuin/199580', u'-F', u'-v'] [debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8 [debug] youtube-dl version 2018.04.16 [debug] Python version 2.7.10 (CPython) - Darwin-17.5.0-x86_64-i386-64bit [debug] exe versions: ffmpeg git-2018-04-21-e5ba5fa, ffprobe git-2018-04-21-e5ba5fa, rtmpdump 2.4 [debug] Proxy map: {} [FreshLive] 199580: Downloading webpage [FreshLive] 199580: Downloading m3u8 information [info] Available formats for 199580: format code extension resolution note hls-324 mp4 256x144 324k , avc1.77.21, mp4a.40.2 hls-1207 mp4 512x288 1207k , avc1.77.30, mp4a.40.2 hls-2635 mp4 768x432 2635k , avc1.77.40, mp4a.40.2 hls-3472 mp4 1280x720 3472k , avc1.77.41, mp4a.40.2 (best) MacBook-Pro-3:Downloads gaeaearth$ youtube-dl --cookies cookies.txt https://freshlive.tv/sakuragakuin/199580 -f hls-3472 -v [debug] System config: [] [debug] User config: [] [debug] Custom config: [] [debug] Command-line args: [u'--cookies', u'cookies.txt', u'https://freshlive.tv/sakuragakuin/199580', u'-f', u'hls-3472', u'-v'] [debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8 [debug] youtube-dl version 2018.04.16 [debug] Python version 2.7.10 (CPython) - Darwin-17.5.0-x86_64-i386-64bit [debug] exe versions: ffmpeg git-2018-04-21-e5ba5fa, ffprobe git-2018-04-21-e5ba5fa, rtmpdump 2.4 [debug] Proxy map: {} [FreshLive] 199580: Downloading webpage [FreshLive] 199580: Downloading m3u8 information [debug] Invoking downloader on u'https://movie.freshlive.tv/playlist/2061359.m3u8?token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1' [hlsnative] Downloading m3u8 manifest WARNING: hlsnative has detected features it does not support, extraction will be delegated to ffmpeg [download] Destination: #FRESHマンデー 「さくら学院の顔笑れ!!FRESH!マンデー」#41-199580.mp4 [debug] ffmpeg command line: ffmpeg -y -loglevel verbose -headers 'Accept-Language: en-us,en;q=0.5 Accept-Encoding: gzip, deflate Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:59.0) Gecko/20100101 Firefox/59.0 (Chrome) Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 Cookie: P=258f3b63-38cb-44a3-bfc7-07af1894c515; __gads=ID=7322cf2fccefe783:T=1524274229:S=ALNI_MYckkk5yr0zgTgfEaqDdW-PANc2pA; _ga=GA1.2.1187550676.1524274229; utm=j%3A%7B%7D; segmentId=4977; connect.sid=s%3A9e3381d5-574d-4cf1-b4e0-6d0b192e2254.PlMR%2FsY31FbOZ0YWADlkSuhfyx6CVpE7MqpTvrF1EKc ' -i 'https://movie.freshlive.tv/playlist/2061359.m3u8?token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1' -c copy -f mp4 '-bsf:a' aac_adtstoasc 'file:#FRESHマンデー 「さくら学院の顔笑れ!!FRESH!マンデー」#41-199580.mp4.part' ffmpeg version git-2018-04-21-e5ba5fa Copyright (c) 2000-2018 the FFmpeg developers built with Apple LLVM version 9.1.0 (clang-902.0.39.1) configuration: --prefix=/usr/local/Cellar/ffmpeg/HEAD-e5ba5fa --enable-shared --enable-pthreads --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-gpl --enable-libfdk-aac --enable-libmp3lame --enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --enable-opencl --enable-videotoolbox --disable-lzma --enable-nonfree libavutil 56. 15.100 / 56. 15.100 libavcodec 58. 19.100 / 58. 19.100 libavformat 58. 13.100 / 58. 13.100 libavdevice 58. 4.100 / 58. 4.100 libavfilter 7. 18.100 / 7. 18.100 libavresample 4. 0. 0 / 4. 0. 0 libswscale 5. 2.100 / 5. 2.100 libswresample 3. 2.100 / 3. 2.100 libpostproc 55. 2.100 / 55. 2.100 [hls,applehttp @ 0x7f9f39800400] HLS request for url 'https://movie.freshlive.tv/ts/2061359/movie/fresh199580/hls/720/ts/1.ts?pd=1&token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1', offset 0, playlist 0 Unable to open key file abemafresh://abemafresh/199580t2212f5e4556956e2a97ebd7959a9dc1c52a1/9a62571da4165ef4e06bc94179523927 [hls,applehttp @ 0x7f9f39800400] Opening 'crypto+https://movie.freshlive.tv/ts/2061359/movie/fresh199580/hls/720/ts/1.ts?pd=1&token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1' for reading [hls,applehttp @ 0x7f9f39800400] Error when loading first segment 'https://movie.freshlive.tv/ts/2061359/movie/fresh199580/hls/720/ts/1.ts?pd=1&token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1' https://movie.freshlive.tv/playlist/2061359.m3u8?token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1: Invalid data found when processing input ERROR: ffmpeg exited with code 1 File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 162, in _run_module_as_main "__main__", fname, loader, pkg_name) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 72, in _run_code exec code in run_globals File "/usr/local/bin/youtube-dl/__main__.py", line 19, in <module> youtube_dl.main() File "/usr/local/bin/youtube-dl/youtube_dl/__init__.py", line 471, in main _real_main(argv) File "/usr/local/bin/youtube-dl/youtube_dl/__init__.py", line 461, in _real_main retcode = ydl.download(all_urls) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1993, in download url, force_generic_extractor=self.params.get('force_generic_extractor', False)) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 800, in extract_info return self.process_ie_result(ie_result, download, extra_info) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 854, in process_ie_result return self.process_video_result(ie_result, download=download) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1627, in process_video_result self.process_info(new_info) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1900, in process_info success = dl(filename, info_dict) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1839, in dl return fd.download(name, info) File "/usr/local/bin/youtube-dl/youtube_dl/downloader/common.py", line 365, in download return self.real_download(filename, info_dict) File "/usr/local/bin/youtube-dl/youtube_dl/downloader/hls.py", line 76, in real_download return fd.real_download(filename, info_dict) File "/usr/local/bin/youtube-dl/youtube_dl/downloader/external.py", line 64, in real_download self.get_basename(), retval)) File "/usr/local/bin/youtube-dl/youtube_dl/downloader/common.py", line 166, in report_error self.ydl.report_error(*args, **kargs) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 617, in report_error self.trouble(error_message, tb) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 579, in trouble tb_data = traceback.format_list(traceback.extract_stack()) MacBook-Pro-3:Downloads gaeaearth$ youtube-dl --cookies cookies.txt https://freshlive.tv/sakuragakuin/199580 -f hls-3472 -v --hls-prefer-native [debug] System config: [] [debug] User config: [] [debug] Custom config: [] [debug] Command-line args: [u'--cookies', u'cookies.txt', u'https://freshlive.tv/sakuragakuin/199580', u'-f', u'hls-3472', u'-v', u'--hls-prefer-native'] [debug] Encodings: locale UTF-8, fs utf-8, out UTF-8, pref UTF-8 [debug] youtube-dl version 2018.04.16 [debug] Python version 2.7.10 (CPython) - Darwin-17.5.0-x86_64-i386-64bit [debug] exe versions: ffmpeg git-2018-04-21-e5ba5fa, ffprobe git-2018-04-21-e5ba5fa, rtmpdump 2.4 [debug] Proxy map: {} [FreshLive] 199580: Downloading webpage [FreshLive] 199580: Downloading m3u8 information [debug] Invoking downloader on u'https://movie.freshlive.tv/playlist/2061359.m3u8?token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1' [hlsnative] Downloading m3u8 manifest WARNING: hlsnative has detected features it does not support, extraction will be delegated to ffmpeg [download] Destination: #FRESHマンデー 「さくら学院の顔笑れ!!FRESH!マンデー」#41-199580.mp4 [debug] ffmpeg command line: ffmpeg -y -loglevel verbose -headers 'Accept-Language: en-us,en;q=0.5 Accept-Encoding: gzip, deflate Accept: text/html,application/xhtml+xml,application/xml;q=0.9,*/*;q=0.8 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:59.0) Gecko/20100101 Firefox/59.0 (Chrome) Accept-Charset: ISO-8859-1,utf-8;q=0.7,*;q=0.7 Cookie: P=258f3b63-38cb-44a3-bfc7-07af1894c515; __gads=ID=7322cf2fccefe783:T=1524274229:S=ALNI_MYckkk5yr0zgTgfEaqDdW-PANc2pA; _ga=GA1.2.1187550676.1524274229; utm=j%3A%7B%7D; segmentId=4977; connect.sid=s%3A9e3381d5-574d-4cf1-b4e0-6d0b192e2254.PlMR%2FsY31FbOZ0YWADlkSuhfyx6CVpE7MqpTvrF1EKc ' -i 'https://movie.freshlive.tv/playlist/2061359.m3u8?token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1' -c copy -f mp4 '-bsf:a' aac_adtstoasc 'file:#FRESHマンデー 「さくら学院の顔笑れ!!FRESH!マンデー」#41-199580.mp4.part' ffmpeg version git-2018-04-21-e5ba5fa Copyright (c) 2000-2018 the FFmpeg developers built with Apple LLVM version 9.1.0 (clang-902.0.39.1) configuration: --prefix=/usr/local/Cellar/ffmpeg/HEAD-e5ba5fa --enable-shared --enable-pthreads --enable-version3 --enable-hardcoded-tables --enable-avresample --cc=clang --host-cflags= --host-ldflags= --enable-gpl --enable-libfdk-aac --enable-libmp3lame --enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --enable-opencl --enable-videotoolbox --disable-lzma --enable-nonfree libavutil 56. 15.100 / 56. 15.100 libavcodec 58. 19.100 / 58. 19.100 libavformat 58. 13.100 / 58. 13.100 libavdevice 58. 4.100 / 58. 4.100 libavfilter 7. 18.100 / 7. 18.100 libavresample 4. 0. 0 / 4. 0. 0 libswscale 5. 2.100 / 5. 2.100 libswresample 3. 2.100 / 3. 2.100 libpostproc 55. 2.100 / 55. 2.100 [hls,applehttp @ 0x7fe7dc800000] HLS request for url 'https://movie.freshlive.tv/ts/2061359/movie/fresh199580/hls/720/ts/1.ts?pd=1&token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1', offset 0, playlist 0 Unable to open key file abemafresh://abemafresh/199580t2212f5e4556956e2a97ebd7959a9dc1c52a1/9a62571da4165ef4e06bc94179523927 [hls,applehttp @ 0x7fe7dc800000] Opening 'crypto+https://movie.freshlive.tv/ts/2061359/movie/fresh199580/hls/720/ts/1.ts?pd=1&token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1' for reading [hls,applehttp @ 0x7fe7dc800000] Error when loading first segment 'https://movie.freshlive.tv/ts/2061359/movie/fresh199580/hls/720/ts/1.ts?pd=1&token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1' https://movie.freshlive.tv/playlist/2061359.m3u8?token=199580t2212f5e4556956e2a97ebd7959a9dc1c52a1: Invalid data found when processing input ERROR: ffmpeg exited with code 1 File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 162, in _run_module_as_main "__main__", fname, loader, pkg_name) File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/runpy.py", line 72, in _run_code exec code in run_globals File "/usr/local/bin/youtube-dl/__main__.py", line 19, in <module> youtube_dl.main() File "/usr/local/bin/youtube-dl/youtube_dl/__init__.py", line 471, in main _real_main(argv) File "/usr/local/bin/youtube-dl/youtube_dl/__init__.py", line 461, in _real_main retcode = ydl.download(all_urls) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1993, in download url, force_generic_extractor=self.params.get('force_generic_extractor', False)) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 800, in extract_info return self.process_ie_result(ie_result, download, extra_info) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 854, in process_ie_result return self.process_video_result(ie_result, download=download) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1627, in process_video_result self.process_info(new_info) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1900, in process_info success = dl(filename, info_dict) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 1839, in dl return fd.download(name, info) File "/usr/local/bin/youtube-dl/youtube_dl/downloader/common.py", line 365, in download return self.real_download(filename, info_dict) File "/usr/local/bin/youtube-dl/youtube_dl/downloader/hls.py", line 76, in real_download return fd.real_download(filename, info_dict) File "/usr/local/bin/youtube-dl/youtube_dl/downloader/external.py", line 64, in real_download self.get_basename(), retval)) File "/usr/local/bin/youtube-dl/youtube_dl/downloader/common.py", line 166, in report_error self.ydl.report_error(*args, **kargs) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 617, in report_error self.trouble(error_message, tb) File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 579, in trouble tb_data = traceback.format_list(traceback.extract_stack()) ``` --- ### If the purpose of this *issue* is a *site support request* please provide all kinds of example URLs support for which should be included (replace following example URLs by **yours**): - Single video: https://freshlive.tv/sakuragakuin/199580 --- My youtube-dl and ffmpeg are the last version. I read some issue so I tried the option '--hls-prefer-native' with pycrypto, but this is not working (I also attach that code). I think that they not just use m3u8, they use series of .ts files. How to download the video using youtube-dl? Please help me. And I am sorry for my poor english.
account-needed
low
Critical
316,606,474
rust
Rustc should be able to unify `<T as A<'static>>::B>` with `<T as A<'a>>::B>` for all `'a`, given `A::B: 'static`
I had to use [this trick](https://github.com/rust-lang/rfcs/pull/1598#issuecomment-215962891) to work around the [lack of working GATs](https://github.com/rust-lang/rust/issues/50115): Ended up with this code: https://play.rust-lang.org/?gist=5f14fd0600bf0b1e1e9eac2c8a3d194a&version=stable It works but to be able to do ```rust pub struct AppMgr<T: for<'a> DeviceApp<'a>> { device: Option<T::Dev>, app: T, // ... } ``` I had to split up my trait ```rust pub trait DeviceApp<'a> { type Dev: Device; // ... ``` into two ```rust pub trait DeviceSpecific { type Dev: Device; } pub trait DeviceApp<'a>: DeviceSpecific { // ... ``` to pull `Dev` out of the quantification scope of `'a`. I thought it should work if I put `Dev` back inside `DeviceApp` but make it `: 'static` so that `rustc` can infer that it's the same for all `'a`: ```rust /* pub trait DeviceSpecific { type Dev: Device; } pub trait DeviceApp<'a>: DeviceSpecific { */ pub trait DeviceApp<'a> { type Dev: Device + 'static; // ... pub struct AppMgr<T: for<'a> DeviceApp<'a>> { // device: Option<T::Dev>, device: Option<<T as DeviceApp<'static>>::Dev>, // because Dev: 'static, i thought it will be unifyable with any 'a app: T, // ... } ``` But it doesn't work. Now I get this error: ``` error[E0495]: cannot infer an appropriate lifetime for lifetime parameter 'a in function call due to conflicting requirements --> src/main.rs:79:53 | 79 | device.frame(now, |device, input| { app.process(device, input, v) }) | ^^^^^^^ | note: first, the lifetime cannot outlive the lifetime 'a as defined on the method body at 75:5... --> src/main.rs:75:5 | 75 | pub fn process<'a>(&mut self, now: u64, msgs: Vec<<T as DeviceApp<'a>>::Msg>, v: &'a mut <T as DeviceApp<'a>>::BorrowedState) -> Vec<<T as DeviceApp<'a>>::Event> { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ = note: ...so that the expression is assignable: expected &mut <T as DeviceApp<'_>>::BorrowedState found &mut <T as DeviceApp<'a>>::BorrowedState = note: but, the lifetime must be valid for the static lifetime... = note: ...so that the expression is assignable: expected &mut <T as DeviceApp<'_>>::Dev found &mut <T as DeviceApp<'static>>::Dev ``` https://play.rust-lang.org/?gist=d4084c0a87890d4ed17d0491e453565b&version=stable Why can't `rustc` unify `<T as DeviceApp<'static>>::Dev>` with `<T as DeviceApp<'a>>::Dev>` for all `'a`, when it **KNOWS** that `Dev: 'static` (the type doesn't depend on `'a`, so it can only be the same for all `'a`)? It should be able to infer it..
C-enhancement,A-trait-system,T-compiler
low
Critical
316,626,756
pytorch
[feature request] More `index_*_` functionality and/or lambda functionality
Could additional index-based functions be added to the tensor library? Specifically I am thinking of an `index_mean_` and `index_max_` or `index_min_`? In the first case, all that I foresee being required is an extra counter per index. In the latter, it's just a matter or replacing element-wise addition with an element-wise binary comparator. Even better would be an `index_lambda_` function in which a user can implement their own index-wise operation. If I could find the source code, I'd take a stab at a PR, but I am not sure where to find these implementations (all I found was aten/Tensor.h), nor am I CUDA proficient if they are implemented in that way. Hence, I'm making a feature request and am hoping someone can take the ball and run with it. cc @nikitaved @pearu @cpuhrsch @aocsa @mruberry
feature,triaged,module: scatter & gather ops
low
Major
316,639,702
rust
Work out the actual policy for macros across editions wrt dependencies updating
I don’t think we’ve adequately worked out what we _want_ for macros with editions. Are we okay with a Rust 2015 crate that exposes a macro updating to Rust 2018 (including new idioms) with a minor bump? I.e. should our edition hygiene account for this? Or are macro authors instructed to do major bumps when they Taking a hypothetical: if `dyn` were something we _only_ exposed on Rust 2018, and a macro crate upgraded to the new edition, should _we_ do the heavy lifting of ensuring that crates on Rust 2015 can use macros from crates on Rust 2018 that use 2018-only features? Or do we require the crate author to do a major version bump? Similarly, what level of trouble are we okay with for crates attempting to upgrade to the 2018 edition that use macros from 2015 crates? cc @rust-lang/lang
C-enhancement,T-lang,WG-epoch
low
Minor
316,724,017
pytorch
[caffe2] Understanding WorkFlow for Training and Testing
hello, I am trying to compare all c++ framework(caffe2, tiny-dnn, etc.) with NNPACK. the comparison that i do: Speed (exclude image loading), Memory size, and Code size. I am new in caffe/caffe2 and worked with pytorch. I looking a good way to learn caffe2(i already read the tutorial), the current is not sufficient. some open issues from my side: 1. Can i stream images and labels and change the input at runtime?(do back-propagation on the mini-batch) 2. Why i need to use db input and why it's need to duplicated the data? can i avoid it? 3. How the back-propagation work? where the forward/backward implementation? when the gradients are summit? 4. How can i insert labels for loss function on the minibatch input(i tried with tensorCPU input det as "data" and vectors of int's to "label" i get exception so it's probably not the best way) 5. Why there isn't interface like in other framework that simply run train on image: for example in tiny- dnn i simply runed nn->train<tiny_dnn::cross_entropy>(optimizer, minibatch, labels,minibatch.size(), 1); where std::vector<tiny_dnn::vec_t> minibatch; std::vector<tiny_dnn::label_t> labels; 6. I tried to switch engine to NNPACK - does it work(implement) only on arm or at intel process as well(i avoiding MKL), i get some warning that some operators are not supported - what is the fallback can i defined it? some warning that i am not sure what im doing wrong about the input size. I would be very happy to help! All done in c++. Thanks, Liron
caffe2
low
Major
316,775,004
rust
Public "stdcall" symbol not exported on cdylib on i686-pc-windows-gnu
I'm making a cdylib crate which exports a function in the following manner: ```rust #[no_mangle] pub extern "system" fn SomeFunction() {} ``` The library is then supposed to be loaded by another program at runtime and the function dlsym'd from it. This works everywhere (32/64-bit Linux, macOS, 32/64-bit Windows MSVC, 64-bit Windows GNU) _except_ the `i686-pc-windows-gnu` target where the function isn't being exported from the resulting DLL for some reason. Minimal example is the code above in a clean crate with `crate-type = ["cdylib"]`. Possibly related: #50007, although for me the bug occurrs in both debug and release. Rust: stable (1.25.0), beta, nightly.
A-linkage,A-FFI,T-compiler,O-windows-gnu,C-bug,O-x86_32
medium
Critical
316,908,914
pytorch
[Caffe2] Android NNApi integration bugs.
## Issue description I found a few bugs in NNApi integration while running benchmarks. ## Code example Bug 1: Invalid size is passed for tensors. Caffe2 seems to be passing invalid size for tensors in setInput and setOutput. If I am not wrong, they should be passing tensor->nbytes() instead of tensor->bytes() https://github.com/caffe2/caffe2/blob/master/caffe2/mobile/contrib/nnapi/nnapi.cc#L659 In ANeuralNetworksExecution_setInput the length parameter is number of bytes, not number of elements in the tensor. https://developer.android.com/ndk/reference/group___neural_networks.html#gaf5540f8785a31b550ba7e7a78eed6a85 Bug 2: The scale is only supported for Quantized int8 tensors and should be 0 otherwise. https://github.com/caffe2/caffe2/blob/master/caffe2/mobile/contrib/nnapi/nnapi.cc#L517 NNApi::addTensorOperand should assign scale conditionally.
caffe2
low
Critical
316,916,007
go
x/tools: unify I/O semaphores
grepping for the word "semaphore" reveals five separate I/O semaphores in x/tools. Some of them could easily be used in the same executable, e.g. those in `go/loader`, `go/buildutil`, `refactor/importgraph`, and `cmd/guru`. This makes them less effective. I suggest we add a single exported semaphore to x/tools, which all x/tools packages can import and use, thus providing an actual process-wide limit on I/O concurrency. It could be in an internal package or not; I don't feel strongly. cc @bradfitz @alandonovan @kevinburke for opinions
NeedsDecision,Tools
low
Major
316,931,401
rust
Tracking issue for Cell::update
This issue tracks the `cell_update` feature. The feature adds `Cell::update`, which allows one to more easily modify the inner value. For example, instead of `c.set(c.get() + 1)` now you can just do `c.update(|x| x + 1)`: ```rust let c = Cell::new(5); let new = c.update(|x| x + 1); assert_eq!(new, 6); assert_eq!(c.get(), 6); ```
T-libs-api,B-unstable,C-tracking-issue,disposition-merge,finished-final-comment-period,Libs-Tracked,Libs-Small
high
Critical
316,933,419
kubernetes
Enable RealProxier in 5k-node kubemark
Our kubemark-5k job (https://k8s-testgrid.appspot.com/sig-scalability-kubemark#kubemark-5000) started failing sometime mid- last week. E.g failed runs: - https://k8s-gubernator.appspot.com/build/kubernetes-jenkins/logs/ci-kubernetes-kubemark-gce-scale/963 - https://k8s-gubernator.appspot.com/build/kubernetes-jenkins/logs/ci-kubernetes-kubemark-gce-scale/964 - https://k8s-gubernator.appspot.com/build/kubernetes-jenkins/logs/ci-kubernetes-kubemark-gce-scale/965 From run-964's build-log for e.g, I'm finding that quite some pods weren't started by hollow-nodes during the load test: ``` I0419 22:36:53.886] I0419 22:36:53.882724 15900 runners.go:176] Pod load-medium-1232-9bpsg hollow-node-kmznc Running <nil> I0419 22:36:53.886] I0419 22:36:53.882733 15900 runners.go:176] Pod load-medium-1232-9stph hollow-node-2lq5z Pending <nil> I0419 22:36:53.887] I0419 22:36:53.882742 15900 runners.go:176] Pod load-medium-1232-btvw9 hollow-node-7bqx9 Running <nil> ... I0419 22:36:53.892] Apr 19 22:36:53.882: INFO: Unexpected error occurred: Only 29 pods started out of 30 ``` My suspicion is that some hollow-nodes are dying due to resource starvation and hence not able to run pods that are assigned to those. It's quite likely related to @krzysied 's change adding kube-dns to kubemark (which I think merged around that time). cc @kubernetes/sig-scalability-bugs @wojtek-t
kind/bug,sig/scalability,lifecycle/frozen
medium
Critical
316,938,966
flutter
Transitioning a TabBarView manually doesn't honor the duration and curve
## Steps to Reproduce Calling `TabController.animateTo` with a duration and curve doesn't affect the behavior of the `TabBarView` animation. Although it's correctly affecting the behavior of the `TabPageSelector` and the `TabBar` animations. Sample: https://gist.github.com/osama-lionheart/bab886d774f4e87b77104835edffbc49 Video: https://youtu.be/FzRBgflZrR4 ## Flutter Doctor ``` [✓] Flutter (Channel master, v0.3.3-pre.10, on Mac OS X 10.13.4 17E199, locale en-US) [✓] Android toolchain - develop for Android devices (Android SDK 27.0.3) [✓] iOS toolchain - develop for iOS devices (Xcode 9.3) [✓] Android Studio ✗ Flutter plugin not installed; this adds Flutter specific functionality. ✗ Dart plugin not installed; this adds Dart specific functionality. [✓] Android Studio (version 3.1) [✓] VS Code (version 1.22.2) [✓] Connected devices (1 available) • No issues found! ```
framework,f: material design,a: fidelity,has reproducible steps,P3,found in release: 2.8,found in release: 2.9,team-design,triaged-design
medium
Major
316,948,308
pytorch
[Bug] VS reports unresolved external symbol from caffe2 observer
## Issue description VS 2017 complains about error LNK2001 unresolved symbols when enable caffe2 observer. This is due to the missing import/export hint for creating DLL. ## System Info - PyTorch or Caffe2: Caffe2 - Build command you used (if compiling from source): CMake - OS: Win10 - Python version: 3.6 - Visual Studio version (if compiling from source): VS 2017 15.6 - CMake version: 3.11
caffe2
low
Critical
316,974,399
opencv
MKL_WITH_TBB failed to found the latest TBB 2018 on Windows
##### System information (version) - OpenCV => master - Operating System / Platform => Windows 10 64 Bit - Compiler => Visual Studio 2015 ##### Detailed description Failed to found TBB from OpenCVFindMKL. The latest TBB 2018 is installed to places like `C:\Program Files (x86)\IntelSWTools\compilers_and_libraries\windows\tbb\lib\intel64\vc14` by default, which has the compiler version "vc14" (and also vc12, vc_mt...) Currently `OpenCVFindMKL.cmake` is using `${MKL_ROOT_DIR}/../tbb/lib/${MKL_ARCH}` which is incorrect in this case. ##### Steps to reproduce Install the latest MKL and TBB and make sure you don't have other version on your system. Also make sure OpenBLAS is not installed. Do a CMake build with "-DMKL_WITH_TBB=ON", and you'll see LAPACK failed because there's no BLAS. The MKL is found first but then failed while adding tbb in the following code ``` if(NOT ${lib}) mkl_fail() endif() ```
feature,category: build/install
low
Critical
317,025,725
go
runtime: android backtraces do not include go backtrace
The android native backtrace always goes back to the abort() call, and does not include the more useful go backtrace. Therefore, in the Google Play Console, we're left with very unhelpful backtraces like: ![image](https://user-images.githubusercontent.com/10643/39159270-023e05a6-4765-11e8-84f7-9e95ef611a89.png) It would be useful to have the backtrace here include information from Go's backtrace.
OS-Android,NeedsInvestigation,compiler/runtime
low
Major
317,041,511
TypeScript
Have QuickInfo use import types to display type aliases that are not in scope
**Search Terms:** type alias, import, display, quickinfo, intellisense **Code** ```ts // @Filename: file1.ts export type ComplicatedType<T, U> = { [K in Exclude<keyof T, U>]: T[K] } // could be anything here export declare function getComplicatedType<T, U extends keyof T>(arg: T, exclude: U): ComplicatedType<T, U> // @Filename: file2.ts import { getComplicatedType } from "./file1" interface SomeInterface { a: string b<T>(arg: T): T, c: { c2: string } | { c3: number }, d?: boolean } declare const test: SomeInterface const result = getComplicatedType(test, "a") // quickinfo on result currently displays something like: /* const result: { b: <T>(arg: T) => T; c: { c2: string; } | { c3: number; }; d: boolean | undefined; } */ ``` **Current behavior:** The quick info type shown for `result` is a fully expanded anonymous type because `ComplicatedType` is not in scope in `file2`. Importing `ComplicatedType` in `file2` makes quick info display `const result: ComplicatedType<SomeInterface, "a">`, but I don't think it's common to import a type alias purely for the quick info benefit if it isn't actually used anywhere in the file. While the example above isn't that bad, in some cases (#18754, #23458) the fully expanded types can be so large that they actually cause a performance issue for the language service. **Suggested behavior:** Use `import` types from #22592 to display an accurate qualified reference to `ComplicatedType`. So in the example above quick info for `result` could instead display something like: ```ts const result: import("./file1").ComplicatedType<SomeInterface, "a"> ``` Which, although a little verbose, would be much more readable than many fully expanded types. **Related Issues:** #22592 added `import` types. #18754, #23458, #6070, #13095 - Various issues related to the display of types.
Suggestion,Awaiting More Feedback,Domain: Quick Info
low
Major
317,078,251
flutter
Possibility to give Widgets a name in the view hierarchy (so the Play Store "Pre-launch report" Sign-in credentials can be configured)
I was looking into the "Pre-launch Report" Sign in credentials configuration in the Play Store console. I pulled open Android Device Monitor while running the app on the login-screen, and did not expect to get a valid view XML snapshot returned, that's actually pretty nice work! It appears however that it is not possible to give a widget a 'resource name', as required by the pre-launch report Sign-in credentials configuration. Will it become possible at some point to set this value? I guess once its there, it would allow developers to use all kinds of automated testing tools on their apps.
c: new feature,platform-android,framework,engine,customer: crowd,dependency: android,a: release,P2,team-android,triaged-android
low
Critical
317,095,768
react-native
InputAccessoryView doesn't update its height when multiline TextInput grows in height
I'm using an InputAccessoryView to create a sticky TextInput. When using a growing multiline TextInput, the TextInput's height increases and grown down _behind_ the keyboard. ## Environment Environment: OS: macOS High Sierra 10.13.4 Node: 9.11.1 Yarn: 1.5.1 npm: 5.6.0 Watchman: 4.9.0 Xcode: Xcode 9.3 Build version 9E145 Android Studio: 3.0 AI-171.4443003 Packages: (wanted => installed) react: 16.3.1 => 16.3.1 react-native: 0.55.2 => 0.55.2 ## Steps to Reproduce Add `multiline` to a TextInput wrapped inside an InputAccessoryView. ## Expected Behavior InputAccessoryView's bottom edge is always sticky to the keyboard top and does not grow behind the keyboard. ## Actual Behavior ![multiline](https://user-images.githubusercontent.com/779321/39171273-82e33ed6-479e-11e8-9938-cee8b26ccd6f.gif)
Component: TextInput,📮Known Issues,Bug,Never gets stale
medium
Critical
317,208,485
pytorch
[Caffe2] cudnn versions compatibility issue.
## Issue description For any cudnn update (minor or patch level) user have to rebuild caffe2. This is wrong from cudnn7 and on. Please, take a look: https://github.com/tensorflow/tensorflow/issues/17566#issuecomment-372749050 In short: cudnn 7.0.x is backward compatible with cudnn 7.0.1. cudnn 7.1.x is also backward compatible down to cudnn 7.0.1. This code from caffe2/core/common_cudnn.h is root of problem: ``` // report the version of cuDNN Caffe2 was compiled with inline size_t cudnnCompiledVersion() { return CUDNN_VERSION; } // report the runtime version of cuDNN inline size_t cudnnRuntimeVersion() { return cudnnGetVersion(); } // Check compatibility of compiled and runtime cuDNN versions inline void CheckCuDNNVersions() { // Version format is major*1000 + minor*100 + patch // Major, minor and patch versions must all match bool version_match = cudnnCompiledVersion() == cudnnRuntimeVersion(); CAFFE_ENFORCE(version_match, "cuDNN compiled (", cudnnCompiledVersion(), ") and " "runtime (", cudnnRuntimeVersion(), ") versions mismatch"); } ``` For now we have a little bit hackish workaround for this: ``` diff --git a/caffe2/core/context_gpu.cu b/caffe2/core/context_gpu.cu index 46e73f3..56a4ed5 100644 --- a/caffe2/core/context_gpu.cu +++ b/caffe2/core/context_gpu.cu @@ -183,8 +183,10 @@ static void Caffe2InitializeCuda() { RegisterTensorInfoFunction( TypeMeta::Id<Tensor<CUDAContext>>(), GetCUDATensorInfo); +#if CUDNN_MAJOR < 7 // Check the versions of cuDNN that were compiled and linked with are compatible CheckCuDNNVersions(); +#endif } #ifdef CAFFE2_USE_CNMEM ```
module: cudnn,caffe2
low
Minor
317,230,965
vscode
[folding] fold all but comments
Now that we have syntax aware folding, I wonder if we could prevent comments from being folded (configurable, if wanted). This would enable to get an overview of a file very quickly. **Now** ``` /** ... reload() { ... } ``` **Desired** ``` /** * This important comment documents the signature of `reload()` * @param force Enforce reloading */ reload(force: boolean) { ... } ```
feature-request,editor-folding,editor-comments
low
Minor
317,263,217
pytorch
[Caffe2] [feature request] Dilations in grouped convolutons
`caffe2/operators/conv_pool_op_base.h` has the following check: ```cpp if (group_ != 1) { for (int dim = 0; dim < kernel_.size(); ++dim) { CAFFE_ENFORCE_EQ( dilation_[dim], 1, "When group is used, dilation should not be set at the same time."); } } ``` Why is there such condition and is it possible to add support for dilated grouped convolutions?
caffe2
low
Minor
317,279,431
pytorch
[Caffe2] Flatten Layer in caffe2
I'm having trouble building my inceptionv3 model. I build my model by following the diagram from netscope for caffe as shown below. https://dgschwend.github.io/netscope/#/preset/inceptionv3 I came to almost the last layer, where i need implement a flatten layer. I tried to use brew, but it seems that flatten isn't registered in brew. Can anybody show me a code example of building a flatten layer?
caffe2
low
Minor
317,348,096
go
cmd/compile/internal/types: lazy/incremental type expansion
The compiler now supports an indexed data format for package export data that enables efficient random-access of package data. We already use this to implement lazy expansion of declarations and inline bodies, but we still currently fully expand types whenever they're referenced. I expect in larger projects that a lot of deeply nested details are never needed and we could avoid reading that data into memory. I think the steps are largely: 1. Hide remaining Type fields behind setter/getter methods. 2. Create a new TSTUB Type with a way to register an expander function that rewrites the Type into a real Go type. 3. Add a `Type.expand` method that checks for Etype==TSTUB and calls the expander function. 4. Insert calls to `expand()` at the top of every(?) public Type method. 5. Update iimport.go to create TSTUB types instead of normal types. Another useful (but non-critical) step would be to review the Type API and try to prune/simplify unnecessary methods. This would reduce how many places we need to instrument with `expand` calls.
ToolSpeed,compiler/runtime
low
Major
317,356,417
node
https?.Server.keepAliveTimeout introduced boundary condition that results in client-side socket hang-ups
* **Version**: `v8.11.1` * **Platform**: `Darwin C02PQ4SHFVH8 17.5.0 Darwin Kernel Version 17.5.0: Mon Mar 5 22:24:32 PST 2018; root:xnu-4570.51.1~1/RELEASE_X86_64 x86_64` * **Subsystem**: `http` With the introduction of #2534, there now appears to be a window of opportunity after the trailing edge of `server.keepAliveTimeout` whereby a client and server have an inconsistent view of the state of a `keep-alive` socket's connection. In this situation, the server has closed the client's socket, however the client has not yet recognized this and attempts to re-use the persistent connection resulting in a `read ECONNRESET`. Below is a reproduction. Notice that the interval of `5000`ms coincides with the default value of `keepAliveTimeout`. This script may run for some time before producing the error as I don't know how to better time things to hit the window of inconsistent state. ```js const Http = require('http'); const server = Http.createServer((req, res) => { res.writeHead(204); res.end(); }); const agent = new Http.Agent({ keepAlive: true, maxSockets: Infinity, }); server.listen(0, '127.0.0.1', () => { const address = server.address(); let requestCount = 0; const requestOnce = () => { const n = requestCount++; const clientReq = Http.get( { agent, hostname: address.address, path: '/', port: address.port, }, clientRes => { clientRes.on('end', () => console.log(`Ended request ${n}`)); clientRes.on('error', err => { throw err; }); clientRes.resume(); } ); clientReq.on('error', err => { throw err; }); console.log(`Starting request ${n}`); }; setInterval(requestOnce, 5000); }); ``` On my machine, this produced the following output: ```sh % node node8-socket-timeout.js Starting request 0 Ended request 0 Starting request 1 Ended request 1 Starting request 2 /path/to/node8-socket-timeout.js:31 clientReq.on('error', err => { throw err; }); ^ Error: read ECONNRESET at _errnoException (util.js:1022:11) at TCP.onread (net.js:615:25) ``` If the above is indeed the intended behaviour of this new feature, I think the community would benefit from a bit of a warning in the `http` / `https` docs to the effect that there is this boundary condition. Maybe users can be told that one of two things should be done: 1. Servers should now deliberately set `keepAliveTimeout` to `0` and suffer the same memory inefficiencies as `node <= 8`; or 2. Clients should implement retry logic specific to these boundary condition socket hang ups In the 2nd case, I think there is quite a bit of room for doing it incorrectly, especially requests to services or endpoints that are not idempotent. From this perspective, I think it would be pretty helpful to have some guidance from Node Core Team on how to properly detect this specific class of error and how to work around this new behaviour.
help wanted,http,https
low
Critical
317,417,991
kubernetes
add ability to specify base resourceVersion for three-way server-side patch
The PATCH handler has some ... interesting behavior. From the comments: ``` // first time through, // 1. apply the patch // 2. save the original and patched to detect whether there were conflicting changes on retries // on a conflict (which is the only reason to have more than one attempt), // 1. build a strategic merge patch from originalJS and the patchedJS. Different patch types can // be specified, but a strategic merge patch should be expressive enough handle them. Build the // patch with this type to handle those cases. // 2. build a strategic merge patch from originalJS and the currentJS // 3. ensure no conflicts between the two patches // 4. apply the #1 patch to the currentJS object ``` I think there are three modes of operation which it potentially makes sense for patch to have: 1. User specifies RV; patch makes one try. Fail if RV no longer matches. (This makes sense if the user's patch depends on some part of the object in an unpredictable way.) 2. User does not specify RV; patch makes multiple tries, fails if the patch stops applying cleanly. (User is opting out of any locking--'.spec.replicas' should be X, I don't care what anyone else said.) 3. User specifies a base object and a patch; patch interprets the patch changes as having an implicit "from" precondition for every change. It retries as long as the patch with the implied preconditions continues to apply cleanly. (User wants concurrency-safe application and wants the server to do the retry loop. And the patch is predictable.) ~~Unfortunately the code today does NONE of those sensible things, and is instead a conflation of 2 and 3 above.~~ edit: 1 and 2 were addressed by https://github.com/kubernetes/kubernetes/pull/63146 If a user tries case 1 today, we think that it still does 5 retries, even though if the first one has a conflict it is certain that the others will, too. If a user today doesn't specify an RV, today's retry loop does a bunch of conflict detection that is pretty pointless: the user didn't specify any relation to the RV, therefore using the RV when the request first came in as a "base object" is an arbitrary choice. If a conflict is generated, user is just going to retry with the exact same patch. And if a user wants behavior 3, there is no way to get it today. I personally recall 3 as being the originally advertised behavior of PATCH but this doesn't seem to be a universal memory. So, I propose changes: 1. ~~If the user specifies a RV in the patch, do not do any retries. This is backwards compatible because they all would have failed anyway.~~ done in https://github.com/kubernetes/kubernetes/pull/63146 2. ~~If the user doesn't specify an RV, don't do the conflict detection mentioned in the comments, just retry with the original patch. I think this is backwards compatible because all the failures this causes are actually spurious.~~ done in https://github.com/kubernetes/kubernetes/pull/63146 3. Add a mechanism for the user to deliberately invoke behavior 3. This would be a "new" feature.
sig/api-machinery,kind/feature,lifecycle/frozen
low
Critical
317,426,062
vscode
Add support for bulk actions in extensions list view
We currently support multi-select in the extensions list view but there are no actions a user can take once you have items selected. I would expect the same actions from a single extension be made available (enable/disable/uninstall). **Example** An example where I attempt to disable multiple extensions but only one gets disabled. ![ezgif com-video-to-gif 1](https://user-images.githubusercontent.com/35271042/39218393-5b9d7ffe-47d9-11e8-9fa8-6501cf079df2.gif)
feature-request,extensions,papercut :drop_of_blood:
low
Minor
317,481,464
go
x/build/maintner: GithubIssue.NotExist resurrection does not set Created
Noticed while investigating #25031 that in Corpus.processGithubIssueMutation, when an issue is resurrected from NotExist state, its Created field is not set, as that only happens when the issue is first encountered. No idea when NotExist is set, so not sure if it's an issue, but it looks like that codepath is either unused or broken. /cc @bradfitz
NeedsInvestigation
low
Critical
317,487,602
angular
Animation callbacks fire even if the animation itself is not performed
<!-- PLEASE HELP US PROCESS GITHUB ISSUES FASTER BY PROVIDING THE FOLLOWING INFORMATION. ISSUES MISSING IMPORTANT INFORMATION MAY BE CLOSED WITHOUT INVESTIGATION. --> ## I'm submitting a... <!-- Check one of the following options with "x" --> <pre><code> [ ] Regression (a behavior that used to work and stopped working in a new release) [x] Bug report <!-- Please search GitHub for a similar issue or PR before submitting --> [ ] Performance issue [ ] Feature request [ ] Documentation issue or request [ ] Support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question [ ] Other... Please describe: </code></pre> ## Current behavior <!-- Describe how the issue manifests. --> I use angular animations. If i have a parent item animation, its child items' animations are blocked as intended, but the child items animations' <code>.done</code> callbacks are executed. ## Expected behavior <!-- Describe what the desired behavior would be. --> If the animation is skipped then its callbacks should also be skipped. ## Minimal reproduction of the problem with instructions <!-- For bug reports please provide the *STEPS TO REPRODUCE* and if possible a *MINIMAL DEMO* of the problem via https://stackblitz.com or similar (you can use this template as a starting point: https://stackblitz.com/fork/angular-gitter). --> Controller fragment: ``` @Component({ selector: 'task-list', templateUrl: 'task-list.html', animations: [ trigger('fadeInOut', [ state('void', style({ opacity: '0', height: 0 })), state('*', style({ opacity: '1' , height: '2.6em'})), transition('void => *', animate('2000ms')) ]), trigger( "blockInitialRenderAnimation", [ transition( ":enter", [] ) ] ) ] }) export class TaskListComponent { ... ``` Template fragment: ``` ... <ion-list class="tasks__list-completed" [@blockInitialRenderAnimation] (@blockInitialRenderAnimation.done)="blockInitialRenderAnimationDone()" > <ion-item-sliding *ngFor="let task of taskList.completedTasks" #slidingItem [@fadeInOut] (@fadeInOut.done)="completedTaskFadeInDone($event, task, slidingItem)" > ... ``` ## What is the motivation / use case for changing the behavior? <!-- Describe the motivation or the concrete use case. --> I want to animate only new items in a list. For this purpose i block the existing items' animation on first load by adding empty animation on the parent element (the list itself). I also need to use child items animation callbacks for some logic but only when the animation actually happens. ## Environment <pre><code> Angular version: @angular/animations": "^5.2.10", "@angular/core": "^5.1.0", <!-- Check whether this is still an issue in the most recent Angular version --> Browser: - [X] Chrome (desktop) version 65.0.3325.181 - [ ] Chrome (Android) version XX - [ ] Chrome (iOS) version XX - [ ] Firefox version XX - [ ] Safari (desktop) version XX - [ ] Safari (iOS) version XX - [ ] IE version XX - [ ] Edge version XX For Tooling issues: - Node version: XX <!-- run `node --version` --> - Platform: <!-- Mac, Linux, Windows --> Others: Ionic (3.20) <!-- Anything else relevant? Operating system version, IDE, package manager, HTTP server, ... --> </code></pre>
type: bug/fix,area: animations,freq2: medium,P3
low
Critical
317,490,111
pytorch
Feature request: SSIM/MS-SSIM
The Structural Similarity Index (SSIM) is generally considered to be a milestone in the recent history of Image Quality Assessment (IQA). It would be nice to see in-build **SSIM/MS-SSIM** function in pytorch. cc @fmassa @vfdev-5
triaged,module: vision,function request
high
Critical
317,498,547
rust
unsizing fails when associated types are involved
I am trying to implement something very generic, and in the course of doing so, am using trait associated types. That, in turn, apparently doesn't allow the unsizing rules to kick in. The following compiles fine: ```rust #![crate_type="lib"] use std::cell::UnsafeCell; struct Foo<T: ?Sized>(UnsafeCell<T>); impl<T> Foo<T> { fn new(t: T) -> Foo<T> { Foo(UnsafeCell::new(t)) } } pub fn foo() { let foo: &Foo<[i32]> = &Foo::new([1,2,3]); } ``` Now, adding some nesting in the above fails: ```rust #![crate_type="lib"] use std::cell::UnsafeCell; trait Wrapper { type Type: ?Sized; } struct Wrap<T: ?Sized>(T); impl<T: ?Sized> Wrapper for Wrap<T> { type Type = T; } struct Foo<T: Wrapper + ?Sized>(UnsafeCell<T::Type>); impl<T> Foo<Wrap<T>> { fn new(t: T) -> Self { Foo(UnsafeCell::new(t)) } } pub fn foo() { let foo: &Foo<Wrap<[i32]>> = &Foo::new([1,2,3]); } ``` That fails with: ``` error[E0308]: mismatched types --> src/lib.rs:23:34 | 23 | let foo: &Foo<Wrap<[i32]>> = &Foo::new([1,2,3]); | ^^^^^^^^^^^^^^^^^^ expected slice, found array of 3 elements | = note: expected type `&Foo<Wrap<[i32]>>` found type `&Foo<Wrap<[i32; 3]>>` ``` In fact, it fails similarly with a simplified version that differs even less with the original: ```rust #![crate_type="lib"] use std::cell::UnsafeCell; trait Wrapper { type Type: ?Sized; } impl<T: ?Sized> Wrapper for T { type Type = T; } struct Foo<T: Wrapper + ?Sized>(UnsafeCell<T::Type>); impl<T> Foo<T> { fn new(t: T) -> Self { Foo(UnsafeCell::new(t)) } } pub fn foo() { let foo: &Foo<[i32]> = &Foo::new([1,2,3]); } ``` ``` error[E0308]: mismatched types --> src/lib.rs:21:28 | 21 | let foo: &Foo<[i32]> = &Foo::new([1,2,3]); | ^^^^^^^^^^^^^^^^^^ expected slice, found array of 3 elements | = note: expected type `&Foo<[i32]>` found type `&Foo<[i32; 3]>` ``` (In fact, the `UnsafeCell` is irrelevant, and can be removed too) ```rust #![crate_type="lib"] trait Wrapper { type Type: ?Sized; } impl<T: ?Sized> Wrapper for T { type Type = T; } struct Foo<T: Wrapper + ?Sized>(T::Type); impl<T> Foo<T> { fn new(t: T) -> Self { Foo(t) } } pub fn foo() { let foo: &Foo<[i32]> = &Foo::new([1,2,3]); } ``` ``` error[E0308]: mismatched types --> src/lib.rs:19:28 | 19 | let foo: &Foo<[i32]> = &Foo::new([1,2,3]); | ^^^^^^^^^^^^^^^^^^ expected slice, found array of 3 elements | = note: expected type `&Foo<[i32]>` found type `&Foo<[i32; 3]>` ```
A-trait-system,T-lang,C-bug
low
Critical
317,506,744
go
cmd/link: include DWARF declaration position for types
The linker should include the declaration position for types so that we can use this information in editors and disambiguate where the types come from. The easiest to replicate the confusion is to have a project which has multiple main packages and to try to go to a specific type declared in both those main package. In this case, the type contains only the ` main.TypeName ` information so an editor would be forced to implement additional logic to infer where the ` main ` package is located in the binary. Thank you.
NeedsInvestigation,Debugging,compiler/runtime
low
Minor
317,544,760
godot
RichTextLabel append_bbcode doesn't add the string to bbcode_text property
<!-- Please search existing issues for potential duplicates before filing yours: https://github.com/godotengine/godot/issues?q=is%3Aissue --> **Godot version:** 3.0.2 <!-- Specify commit hash if non-official. --> **OS/device including version:** Linux (but probably any platform) <!-- Specify GPU model and drivers if graphics-related. --> **Issue description:** <!-- What happened, and what was expected. --> RichTextLabel *bbcode_text* field is empty during runtime no matter what changes you do to it. The display is valid though and plain *text* field contains the text as expected. **Steps to reproduce:** ``` extends RichTextLabel func _ready(): append_bbcode("[color=red]red[/color]/n") prints("BBCODE:", bbcode_text) ``` **Expected:** The output is: ``` [color=red]red[/color] ``` **Actual:** The ouput is an empty string. **NOTE:** Remote inspector shows the field is empty as well
bug,confirmed,topic:gui
low
Major
317,563,384
vscode
FileSystemProvider: no way of handling permissions issues
Refs: https://github.com/Microsoft/vscode/issues/48421 **Setup:** * clone https://github.com/bpasero/remote-fs * F5 * click "Refresh" in the explorer * you should see the current working directory as a remote folder using the file system provider for scheme `datei://` I can think of 2 reasons why a permission error raises: * user needs elevated rights to change a file or folder * a file can be readonly (e.g. Windows) and to save it you need to first remove the readonly flag Currently there does not seem to be a way to signal a) to save as elevated user or b) to remove the readonly flag. I am not sure how relevant this is for any other file system provider that does not have these concepts but this is something our file service can do (via the options `overwriteReadonly` and `writeElevated`).
feature-request,remote,file-io
high
Critical
317,604,121
vscode
Revamp findFiles
Hello, [`findFiles`](https://code.visualstudio.com/docs/extensionAPI/vscode-api#workspace.findFiles)'s `exclude` argument says that if you pass in `undefined`, default excludes will apply. I have found this to not work in my extension despite my configuration being correct. Consider this piece of code: ```typescript const files = await workspace.findFiles('**/*.md'); // https://github.com/Microsoft/vscode/issues/47645 // TODO: Figure out https://github.com/Microsoft/vscode/issues/48674 console.log(workspace.getConfiguration('search.exclude')); for (const file of files) { console.log(file.fsPath); } ``` Above, `workspace.getConfiguration('search.exclude')` returns: ```json { "**/node_modules": true, "**/bower_components": true } ``` This is merged from the default settings, I never change this configuration section. Despite that, the `workspace.findFiles('**/*.md')` (with or without `undefined` explicitly passed as a 2nd argument, shouldn't make a difference unless some weird parameter counting is going on) returns MarkDown files from my `node_modules` directory. I do not know how to run extension debugging in a "none but this extension" mode, but I installed a published version of my extension and tried installing it alone in my Insiders instance and was able to reproduce the problem. I am using VS Code 1.22.2 and VS Code Insiders 1.23.0-insider`. Is there anything else I can do to debug this further?
feature-request,search,on-testplan,api-proposal
medium
Critical
317,612,605
rust
Rust cannot use universal LLVM on macOS
I install Rust using [MacPorts](https://www.macports.org) on macOS. Rust was recently [updated](https://github.com/macports/macports-ports/commit/77b2ac31e027672243e78942002737e7185ba125#diff-9b88aea0a5317f434b5fe2a6d02cb0c1) from 1.24.1 to 1.25.0. For version 1.24.1, the Rust compiler did not seem to care if LLVM was built as a [universal binary](https://en.wikipedia.org/wiki/Universal_binary). Starting with version 1.25.0, I get the error > error: failed to add native library /opt/local/libexec/llvm-6.0/lib/libLLVMX86Disassembler.a: File too small to be an archive Rust was compiled with `--llvm-root=/opt/local/libexec/llvm-6.0`. If I reinstall LLVM so it is **not** universal, Rust compiles correctly. There is a MacPorts [bug report](https://trac.macports.org/ticket/56351).
A-LLVM,O-macos,T-compiler,C-bug
medium
Critical
317,710,930
kubernetes
gce pd WaitForAttach never returned
<!-- This form is for bug reports and feature requests ONLY! If you're looking for help check [Stack Overflow](https://stackoverflow.com/questions/tagged/kubernetes) and the [troubleshooting guide](https://kubernetes.io/docs/tasks/debug-application-cluster/troubleshooting/). If this may be security issue, please disclose it privately via https://kubernetes.io/security/. --> **Is this a BUG REPORT or FEATURE REQUEST?**: @kubernetes/sig-storage-bugs **What happened**: Encountered a strange test failure, where WaitForAttach never returned Test logs: https://k8s-gubernator.appspot.com/build/kubernetes-jenkins/pr-logs/pull/63045/pull-kubernetes-e2e-gce/32404/ The volume got successfully attached to the node: ``` I0425 00:03:50.491024 1 pv_controller.go:1432] volume "pvc-1f70b335-481c-11e8-a540-42010a280002" for claim "e2e-tests-subpath-bhnsz/pvc-c66qg" created I0425 00:03:50.491047 1 pv_controller.go:1449] provisionClaimOperation [e2e-tests-subpath-bhnsz/pvc-c66qg]: trying to save volume pvc-1f70b335-481c-11e8-a540-42010a280002 I0425 00:03:53.196916 1 reconciler.go:285] attacherDetacher.AttachVolume started for volume "pvc-1f70b335-481c-11e8-a540-42010a280002" (UniqueName: "kubernetes.io/gce-pd/e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002") from node "e2e-63045-674b9-minion-group-rcbf" 0425 00:03:58.170436 1 operation_generator.go:332] AttachVolume.Attach succeeded for volume "pvc-1f70b335-481c-11e8-a540-42010a280002" (UniqueName: "kubernetes.io/gce-pd/e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002") from node "e2e-63045-674b9-minion-group-rcbf" I0425 00:03:58.170499 1 actual_state_of_world.go:464] Report volume "kubernetes.io/gce-pd/e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002" as attached to node "e2e-63045-674b9-minion-group-rcbf" I0425 00:03:58.172518 1 event.go:218] Event(v1.ObjectReference{Kind:"Pod", Namespace:"e2e-tests-subpath-bhnsz", Name:"pod-subpath-test-gcepdpvc-j2v7", UID:"1f71bc74-481c-11e8-a540-42010a280002", APIVersion:"v1", ResourceVersion:"6789", FieldPath:""}): type: 'Normal' reason: 'SuccessfulAttachVolume' AttachVolume.Attach succeeded for volume "pvc-1f70b335-481c-11e8-a540-42010a280002" ``` Kubelet logs show it detected the attached volume, however WaitForAttach never returned: ``` I0425 00:04:01.880943 1163 operation_generator.go:1170] Controller attach succeeded for volume "pvc-1f70b335-481c-11e8-a540-42010a280002" (UniqueName: "kubernetes.io/gce-pd/e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002") pod "pod-subpath-test-gcepdpvc-j2v7" (UID: "1f71bc74-481c-11e8-a540-42010a280002") device path: "/dev/disk/by-id/google-e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002" I0425 00:04:01.895746 1163 reconciler.go:237] Starting operationExecutor.MountVolume for volume "pvc-1f70b335-481c-11e8-a540-42010a280002" (UniqueName: "kubernetes.io/gce-pd/e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002") pod "pod-subpath-test-gcepdpvc-j2v7" (UID: "1f71bc74-481c-11e8-a540-42010a280002") I0425 00:04:01.895856 1163 reconciler.go:252] operationExecutor.MountVolume started for volume "pvc-1f70b335-481c-11e8-a540-42010a280002" (UniqueName: "kubernetes.io/gce-pd/e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002") pod "pod-subpath-test-gcepdpvc-j2v7" (UID: "1f71bc74-481c-11e8-a540-42010a280002") 0425 00:04:01.895978 1163 operation_generator.go:486] MountVolume.WaitForAttach entering for volume "pvc-1f70b335-481c-11e8-a540-42010a280002" (UniqueName: "kubernetes.io/gce-pd/e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002") pod "pod-subpath-test-gcepdpvc-j2v7" (UID: "1f71bc74-481c-11e8-a540-42010a280002") DevicePath "/dev/disk/by-id/google-e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002" I0425 00:04:01.996191 1163 reconciler.go:237] Starting operationExecutor.MountVolume for volume "pvc-1f70b335-481c-11e8-a540-42010a280002" (UniqueName: "kubernetes.io/gce-pd/e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002") pod "pod-subpath-test-gcepdpvc-j2v7" (UID: "1f71bc74-481c-11e8-a540-42010a280002") I0425 00:04:02.096800 1163 reconciler.go:237] Starting operationExecutor.MountVolume for volume "pvc-1f70b335-481c-11e8-a540-42010a280002" (UniqueName: "kubernetes.io/gce-pd/e2e-63045-674b9-dynami-pvc-1f70b335-481c-11e8-a540-42010a280002") pod "pod-subpath-test-gcepdpvc-j2v7" (UID: "1f71bc74-481c-11e8-a540-42010a280002") ... ```
kind/bug,sig/storage,lifecycle/frozen
low
Critical
317,750,512
go
cmd/link: enable linker dead code pruning when using reflect
Follow-up from https://groups.google.com/d/topic/golang-nuts/syC4LpVf7sw The link-time optimisation to prune unused methods is disabled when reflect.Value.Call() is used anywhere within a program. With large codebases with many vendored libraries, it's hard to avoid including something which calls reflect.Value.Call(), e.g. anything that uses text/template. This problem is causing serious bloat on kubernetes and openshift binaries. One improvement that might be feasible is to enable pruning of methods of a type where: - the set of packages which use that type is statically determinable (e.g., the type doesn't leak from the package set via an exported identifier), and - no packages in the set reference reflect.Value.Call() The intention is to be able to prune methods which are provably non-reachable from any reflect.Value.Call() callpoint. Such an improvement may be complex but I believe the commensurate reduction in binary sizes for projects such as kubernetes make it highly worth considering.
NeedsInvestigation,compiler/runtime
low
Minor
317,779,575
go
cmd/compile: add bounds information from non-control ops to prove pass
Probably low priority; I'm not sure. Some ops have strongly bounded output. For example, Ctz64 is always in [0,64], and Ctz64NonZero is in [0, 63]. Rsh by a constant also provides bounds. The prove pass seems unaware of this. Does it / should it care? Where/how should it be added? @rasky
Performance,compiler/runtime
low
Major
317,780,225
TypeScript
Proposal: new "invalid" type to indicate custom invalid states
## Proposal A new `invalid` type that is not assignable to or from any other types. This includes not being assignable to or from `any` or `never`. It probably shouldn't even be assignable to `invalid` itself if that is possible, although I doubt that one really matters. I'd additionally suggest that, unlike other types, `invalid | any` is not reduced to `any` and `invalid & never` is not reduced to `never`. The idea is to make sure that there is a compile error any time an `invalid` type is inferred or otherwise pops up in a users code. `invalid` types would come from conditional types to represent cases where the conditional type author either expects the case to never happen, or expects that it might happen but intentionally wants that case to cause a compile error indicating to the user that something is invalid with the code they wrote. The `invalid` type should also allow optionally passing an error message that would be displayed to the user when they encounter a compile error caused by the type that could give them a better idea of exactly what the problem is and how to fix it. ## Motivating Examples ### Allowing either `true` or `false` but not `boolean` - https://github.com/Microsoft/TypeScript/issues/23493#issuecomment-384369226 ```ts type XorBoolean<B extends boolean> = boolean extends B ? invalid<'only literal true or false allowed'> : boolean declare function acceptsXorBoolean<B extends boolean & XorBoolean<B>>(arg: B): void acceptsXorBoolean(true) // allowed acceptsXorBoolean(false) // allowed declare const unknownBoolean: boolean acceptsXorBoolean(unknownBoolean) // would have error message: // Argument of type 'boolean' is not assignable to parameter of type invalid<'only literal true or false allowed'> ``` It's possible to write the above example today([playground link](https://www.typescriptlang.org/play/#src=type%20XorBoolean%3CB%20extends%20boolean%3E%20%3D%20boolean%20extends%20B%20%3F%20never%20%3A%20boolean%0D%0A%0D%0Adeclare%20function%20acceptsXorBoolean%3CB%20extends%20boolean%20%26%20XorBoolean%3CB%3E%3E(arg%3A%20B)%3A%20void%0D%0A%0D%0AacceptsXorBoolean(true)%20%2F%2F%20allowed%0D%0AacceptsXorBoolean(false)%20%2F%2F%20allowed%0D%0A%0D%0Adeclare%20const%20unknownBoolean%3A%20boolean%0D%0AacceptsXorBoolean(unknownBoolean)%0D%0A%2F%2F%20Argument%20of%20type%20'boolean'%20is%20not%20assignable%20to%20parameter%20of%20type%20'never'.)) using `never` instead of `invalid`, but it generates an error message saying: `Argument of type 'boolean' is not assignable to parameter of type 'never'.` which is very likely to be confusing to a user who encounters it. ### Preventing duplicate keys - https://github.com/Microsoft/TypeScript/issues/23413#issuecomment-381369843 ```ts type ArrayKeys = keyof any[] type Indices<T> = Exclude<keyof T, ArrayKeys> type GetUnionKeys<U> = U extends Record<infer K, any> ? K : never type CombineUnion<U> = { [K in GetUnionKeys<U>]: U extends Record<K, infer T> ? T : never } type Combine<T> = CombineUnion<T[Indices<T>]> declare function combine< T extends object[] & { [K in Indices<T>]: { [K2 in keyof T[K]]: K2 extends GetUnionKeys<T[Exclude<Indices<T>, K>]> ? invalid<"Duplicated key"> : any } } & { "0": any } >(objectsToCombine: T): Combine<T> const result1 = combine([{ foo: 534 }, { bar: "test" }]) // allowed const error1 = combine([{ foo: 534, dupKey: "dup1" }, { bar: "test", dupKey: "dup2" }]) // error ``` Today([playground link](https://www.typescriptlang.org/play/#src=type%20ArrayKeys%20%3D%20keyof%20any%5B%5D%0D%0Atype%20Indices%3CT%3E%20%3D%20Exclude%3Ckeyof%20T%2C%20ArrayKeys%3E%0D%0Atype%20GetUnionKeys%3CU%3E%20%3D%20U%20extends%20Record%3Cinfer%20K%2C%20any%3E%20%3F%20K%20%3A%20never%0D%0Atype%20CombineUnion%3CU%3E%20%3D%20%7B%20%5BK%20in%20GetUnionKeys%3CU%3E%5D%3A%20U%20extends%20Record%3CK%2C%20infer%20T%3E%20%3F%20T%20%3A%20never%20%7D%0D%0Atype%20Combine%3CT%3E%20%3D%20CombineUnion%3CT%5BIndices%3CT%3E%5D%3E%0D%0A%0D%0Adeclare%20function%20combine%3C%0D%0A%20%20T%20extends%20object%5B%5D%20%26%0D%0A%20%20%20%20%7B%0D%0A%20%20%20%20%20%20%5BK%20in%20Indices%3CT%3E%5D%3A%20%7B%0D%0A%20%20%20%20%20%20%20%20%5BK2%20in%20keyof%20T%5BK%5D%5D%3A%20K2%20extends%20GetUnionKeys%3CT%5BExclude%3CIndices%3CT%3E%2C%20K%3E%5D%3E%20%3F%20never%20%3A%20any%0D%0A%20%20%20%20%20%20%7D%0D%0A%20%20%20%20%7D%20%26%20%7B%20%220%22%3A%20any%20%7D%0D%0A%20%20%20%20%3E(objectsToCombine%3A%20T)%3A%20Combine%3CT%3E%0D%0A%0D%0A%0D%0Aconst%20result1%20%3D%20combine(%5B%7B%20foo%3A%20534%20%7D%2C%20%7B%20bar%3A%20%22test%22%20%7D%5D)%0D%0A%0D%0Aconst%20error1%20%3D%20combine(%5B%7B%20foo%3A%20534%2C%20dupKey%3A%20%22dup1%22%20%7D%2C%20%7B%20bar%3A%20%22test%22%2C%20dupKey%3A%20%22dup2%22%20%7D%5D)%0D%0A)) using `never` instead of `invalid` the error message for `error1` is: ``` Argument of type '[{ foo: number; dupKey: string; }, { bar: string; dupKey: string; }]' is not assignable to parameter of type 'object[] & { "0": { foo: any; dupKey: never; }; "1": { bar: any; dupKey: never; }; } & { "0": any...'. Type '[{ foo: number; dupKey: string; }, { bar: string; dupKey: string; }]' is not assignable to type '{ "0": { foo: any; dupKey: never; }; "1": { bar: any; dupKey: never; }; }'. Types of property '"0"' are incompatible. Type '{ foo: number; dupKey: string; }' is not assignable to type '{ foo: any; dupKey: never; }'. Types of property 'dupKey' are incompatible. Type 'string' is not assignable to type 'never' ``` which would be basically impossible to understand if you didn't expect the function would reject duplicated keys. Using `invalid<"Duplicated key">` however the error message could read: ``` Argument of type '[{ foo: number; dupKey: string; }, { bar: string; dupKey: string; }]' is not assignable to parameter of type 'object[] & { "0": { foo: any; dupKey: invalid<"Duplicated key">; }; "1": { bar: any; dupKey: invalid<"Duplicated key">; }; } & { "0": any...'. Type '[{ foo: number; dupKey: string; }, { bar: string; dupKey: string; }]' is not assignable to type '{ "0": { foo: any; dupKey: invalid<"Duplicated key">; }; "1": { bar: any; dupKey: invalid<"Duplicated key">; }; }'. Types of property '"0"' are incompatible. Type '{ foo: number; dupKey: string; }' is not assignable to type '{ foo: any; dupKey: invalid<"Duplicated key">; }'. Types of property 'dupKey' are incompatible. Type 'string' is not assignable to type 'invalid<"Duplicated key">' ``` Which gives a very clear hint that the problem is that `dupKey` is duplicated. ### Conditional cases which should never happen I could also see `invalid` potentially being used for some conditional types where there is a branch that presumably never gets taken because you are just using the conditional type for the `infer` capability. For example at the end of #21496 there is a type: ```ts type AnyFunction = (...args: any[]) => any; type ReturnType<T extends AnyFunction> = T extends (...args: any[]) => infer R ? R : never; ``` Maybe `invalid<"should never happen">` is used instead of `never` for the false branch so it's easier to track down the problem if it ever turns out the assumption that the branch will never be taken is wrong. (Of course if `T` is `any`, both the true and false branches are always taken so you might not want to change it away from `never`, but at least there'd be the option) ## Related Issues #20235 - _Generics: Cannot limit template param to specific types_ - Could benefit from an approach like `XorBoolean` above. #22375 - _how do i prevent non-nullable types in arguments_ - Solution here is basically the same idea as `XorBoolean`. The error message for this specific issue is already understandable but it shows there is more interest in the pattern. #13713 - _[feature request] Custom type-error messages_ - Similar sounding idea, but it seems to be focused on changing the wording of existing error messages. ## Search Terms invalid type, custom error message, generic constraint, conditional types
Suggestion,In Discussion
high
Critical
317,780,308
go
cmd/compile: use bounds from prove pass to simplify shifts
Shifts generally require extra code to correctly handle shifting by more than the width of the value. We have a bunch of ad hoc rewrite rules to detect and handle this. But the prove pass might be able to do a better job of this, and more simply too. CL 109358 uses the prove pass to simplify CtzNN. Maybe we should do something similar for shifts. (And anything else?) cc @rasky @randall77
Performance,compiler/runtime
low
Major
317,796,947
terminal
Create exporting interface to allow more formats than just .ini
As follow on from #19, this issue encompasses making the export feature generic through an interface like ISchemeExporter so we can export in more formats than .ini
Product-Colortool,Help Wanted,Area-Settings,Issue-Task
low
Minor
317,830,576
rust
Associated types bounds seem to be ignored in generic impls
Consider the following code: ```rust #![crate_type="lib"] use std::marker::PhantomData; trait Foo { type Type: Qux; } struct Bar<T>(PhantomData<T>); trait Qux {} impl<T: Foo> From<T::Type> for Bar<T> { fn from(t: T::Type) -> Self { Bar(PhantomData) } } ``` This fails to build with: ``` error[E0119]: conflicting implementations of trait `std::convert::From<Bar<_>>` for type `Bar<_>`: --> src/lib.rs:13:1 | 13 | impl<T: Foo> From<T::Type> for Bar<T> { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = note: conflicting implementation in crate `core`: - impl<T> std::convert::From<T> for T; ``` This implies the compiler thinks `T::Type` might be `Bar<T>`, but because of the `Qux` bound, and the fact that there is no `impl<T> Qux for Bar<T> {}`, it's not possible. In fact, doing some handholding works: `impl<T: Foo<Type=U>, U: Qux> From<U> for Bar<T>` yields no error and is equivalent, albeit unnecessarily verbose.
A-trait-system,C-bug,T-types
low
Critical
317,831,021
rust
Spurious "downstream crates may implement trait ..."
Consider the following code, close to the one in #50237: ```rust #![crate_type="lib"] use std::marker::PhantomData; trait Foo { type Type: Qux<Self>; } struct Bar<T>(PhantomData<T>); trait Qux<T> {} impl<T: Foo<Type=U>, U: Qux<T>> From<U> for Bar<T> { fn from(t: U) -> Self { Bar(PhantomData) } } ``` This fails to build with: ``` error[E0119]: conflicting implementations of trait `std::convert::From<Bar<_>>` for type `Bar<_>`: --> src/lib.rs:13:1 | 13 | impl<T: Foo<Type=U>, U: Qux<T>> From<U> for Bar<T> { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = note: conflicting implementation in crate `core`: - impl<T> std::convert::From<T> for T; = note: downstream crates may implement trait `Qux<_>` for type `Bar<_>` ``` But how can a downstream crate implement `Qux<_>` for `Bar<_>`?
A-trait-system,T-compiler,C-bug
medium
Critical
317,836,478
flutter
Would like a benchmark tracking embedding latency
Now that more folks are embedding flutter, I'm being asked for two numbers: 1. How much time does adding Flutter to your binary affect startup time (not necessarily displaying a FlutterView at all). Presumably this is zero or close to? 2. How long does it take to bring a FlutterView on screen (presumably there are 2 numbers here. one for first Flutter view and a second for any future view?) Thoughts @mravn-google @yjbanov This isn't urgent, just something we should eventually track.
engine,c: performance,a: existing-apps,customer: dream (g3),team: benchmark,P3,team-engine,triaged-engine
low
Minor
317,846,248
flutter
Improve error message for type error in maybePop()/pop()
## Steps to Reproduce Create a new project and have this pop-up box: ```dart return showDialog<Null>( context: context, barrierDismissible: false, // user must tap button! child: new AlertDialog( title: new Text(title), content: new SingleChildScrollView( child: new ListBody( children: <Widget>[ new Text(msg) ], ), ), actions: <Widget>[ new FlatButton( child: new Text('NO'), onPressed: () { //Navigator.pop(context, "CANCEL"); Navigator.maybePop(context, "CANCEL"); }, ), new FlatButton( child: new Text('YES'), onPressed: () { //Navigator.pop(context, "OK"); Navigator.maybePop(context, "CANCEL"); }, ), ], ), ).then((val){ return val; }); ``` Once the cancel or OK button is clicked, it generates an error ## Logs ``` E/flutter ( 4523): [ERROR:topaz/lib/tonic/logging/dart_error.cc(16)] Unhandled exception: E/flutter ( 4523): type 'String' is not a subtype of type 'Null' of 'result' where E/flutter ( 4523): String is from dart:core E/flutter ( 4523): Null is from dart:core E/flutter ( 4523): E/flutter ( 4523): #0 _ModalRoute&TransitionRoute&LocalHistoryRoute.didPop (package:flutter/src/widgets/routes.dart) E/flutter ( 4523): #1 NavigatorState.pop (package:flutter/src/widgets/navigator.dart:1683:15) E/flutter ( 4523): #2 NavigatorState.maybePop (package:flutter/src/widgets/navigator.dart:1648:9) E/flutter ( 4523): <asynchronous suspension> E/flutter ( 4523): #3 Navigator.maybePop (package:flutter/src/widgets/navigator.dart:1024:34) E/flutter ( 4523): #4 showMainFrameDialogWithCancel.<anonymous closure> (package:myapp/src/util/ScreenUtils.dart:1334:23) E/flutter ( 4523): #5 _InkResponseState._handleTap (package:flutter/src/material/ink_well.dart:490:14) E/flutter ( 4523): #6 _InkResponseState.build.<anonymous closure> (package:flutter/src/material/ink_well.dart:545:30) E/flutter ( 4523): #7 GestureRecognizer.invokeCallback (package:flutter/src/gestures/recognizer.dart:102:24) E/flutter ( 4523): #8 TapGestureRecognizer._checkUp (package:flutter/src/gestures/tap.dart:161:9) E/flutter ( 4523): #9 TapGestureRecognizer.handlePrimaryPointer (package:flutter/src/gestures/tap.dart:94:7) E/flutter ( 4523): #10 PrimaryPointerGestureRecognizer.handleEvent (package:flutter/src/gestures/recognizer.dart:315:9) E/flutter ( 4523): #11 PointerRouter._dispatch (package:flutter/src/gestures/pointer_router.dart:73:12) E/flutter ( 4523): #12 PointerRouter.route (package:flutter/src/gestures/pointer_router.dart:101:11) E/flutter ( 4523): #13 _WidgetsFlutterBinding&BindingBase&GestureBinding.handleEvent (package:flutter/src/gestures/binding.dart:143:19) E/flutter ( 4523): #14 _WidgetsFlutterBinding&BindingBase&GestureBinding.dispatchEvent (package:flutter/src/gestures/binding.dart:121:22) E/flutter ( 4523): #15 _WidgetsFlutterBinding&BindingBase&GestureBinding._handlePointerEvent (package:flutter/src/gestures/binding.dart:101:7) E/flutter ( 4523): #16 _WidgetsFlutterBinding&BindingBase&GestureBinding._flushPointerEventQueue (package:flutter/src/gestures/binding.dart:64:7) E/flutter ( 4523): #17 _WidgetsFlutterBinding&BindingBase&GestureBinding._handlePointerDataPacket (package:flutter/src/gestures/binding.dart:48:7) E/flutter ( 4523): #18 _invoke1 (dart:ui/hooks.dart:134:13) E/flutter ( 4523): #19 _dispatchPointerDataPacket (dart:ui/hooks.dart:91:5) ``` ## Flutter Doctor ``` [✓] Flutter (Channel dev, v0.3.0, on Mac OS X 10.13.4 17E199, locale en-PH) • Flutter version 0.3.0 at /Users/macbook/Documents/flutter • Framework revision c73b8a7cf6 (13 days ago), 2018-04-12 16:17:26 -0700 • Engine revision 8a6e64a8ef • Dart version 2.0.0-dev.47.0.flutter-4126459025 [!] Android toolchain - develop for Android devices (Android SDK 26.0.3) • Android SDK at /Users/macbook/Library/Android/sdk • Android NDK at /Users/macbook/Library/Android/sdk/ndk-bundle • Platform android-27, build-tools 26.0.3 • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java • Java version OpenJDK Runtime Environment (build 1.8.0_112-release-b06) ! Some Android licenses not accepted. To resolve this, run: flutter doctor --android-licenses [✓] iOS toolchain - develop for iOS devices (Xcode 9.3) • Xcode at /Applications/Xcode.app/Contents/Developer • Xcode 9.3, Build version 9E145 • ios-deploy 1.9.2 • CocoaPods version 1.3.1 [✓] Android Studio (version 2.3) • Android Studio at /Applications/Android Studio.app/Contents ✗ Flutter plugin not installed; this adds Flutter specific functionality. ✗ Dart plugin not installed; this adds Dart specific functionality. • Java version OpenJDK Runtime Environment (build 1.8.0_112-release-b06) [✓] IntelliJ IDEA Community Edition (version 2017.2.5) • IntelliJ at /Applications/IntelliJ IDEA CE.app • Flutter plugin version 19.1 • Dart plugin version 172.4343.25 [!] VS Code (version 1.17.2) • VS Code at /Applications/Visual Studio Code.app/Contents • Dart Code extension not installed; install from https://marketplace.visualstudio.com/items?itemName=Dart-Code.dart-code [✓] Connected devices (1 available) • Android SDK built for x86 • emulator-5554 • android-x86 • Android 7.0 (API 24) (emulator) ```
c: crash,framework,f: routes,a: error message,has reproducible steps,P2,found in release: 3.7,found in release: 3.8,team-framework,triaged-framework
low
Critical
317,862,369
neovim
binding ALT (or CTRL) + function key (F1-F12) works with some $TERM but not others
- `nvim --version`: NVIM v0.3.0-1029-g48967695c, Build type: RelWithDebInfo - Vim (version: ) behaves differently? `vim.tiny version 8.0.707`. Yes. - Operating system/version: MX Linux 17 Horizon - Terminal name/version: `terminator 1.90`, `xfce4-terminal 0.8.3 (Xfce 4.12)`, `GNOME Terminal 3.22.2` - `$TERM`: `xterm-256color` - [infocmp output](https://hastebin.com/oyozusapam.pl) - If I hit <c-v> on the terminal and type `<M-F5>` I get this: `^[[15;3~`. - `nnoremap <M-F53> :UUU<cr>` doesnt work either. - [the rest of my environment](https://gist.github.com/mrbig033/63fd7f4f51b6a8ae379abae74c52aff2) ### Steps to reproduce using `nvim -u NORC` 1. open this version of nvim on any of the terminals I listed when `$TERM` variable is set to `xterm-256color` or `xterm`. 2. `:nnoremap <M-F5> echo "testing"<cr>` 3. Press `<M-F5>` 4. Echoed message is not printed. The problem appears in every condition unless $TERM is different than `xterm-256color` or `xterm`. I tried nvim with `-u NONE`, `-u NORC`, `--no-plugins` and all of those combined. I also tried on the terminals mentioned above, as root, as root on the tty and without dotfiles. `vim.tiny` doesn't have the problem. Unfortunately other setting as my $TERM is unacceptable, because it will breaks many things. As far as I know `xterm256color` is the only setting that is able to correctly display my nvim colorschemes and non-ascii characters. ### Output of `nvim -V3log` in several conditions: - `Xfce4-terminal` with `xterm-256color` (issue present): `&term: xterm-256color` `Description: xterm with 256 colors` `Aliases: xterm-256color` - `Xfce4-terminal` after the command `export TERM=xterm` (issue present): `&term: xterm` `Description: X11 terminal emulator` `Aliases: xterm | ` `xterm-debian` - `Xfce4-terminal` under `Tmux` with `$TERM = screen-256color` (issue not present): `&term: screen-256color` `Description: GNU Screen with 256 colors` `Aliases: screen-256color - `Xfce4-terminal` after the command `export TERM=xterm-color` (issue not present): `&term: xterm-color` `Description: generic "ANSI" color xterm (X Window System)` `Aliases: xterm-color` ### Actual behaviour Mappings like <M-F5>, involving function keys in combination with others, do not work whem $TERM is set to `xterm-256color` or `xterm`. ### Expected behaviour nvim should be able to use those mappings when the `$TERM` variable is set to `xterm-256color` or `xterm-color`. I use the former.
bug,tui,input
medium
Major
317,865,742
pytorch
[Caffe2] Is there any way to load custom operators in c++?
It's easy to load custom operators [in Python](https://github.com/caffe2/caffe2_bhtsne). But when I wanted to load operators of a .so file in c++ by linking the .so file, I got ``` Key already registered. Offending key: simple ``` when I ran my binary file. Could you please tell me how to load custom operators in c++?
caffe2
low
Minor
317,867,429
flutter
Scrolling and Tap not working in flutter driver
## Steps to Reproduce I have been using `driver.scroll(...)` and `driver.tap(...)` elsewhere, but have been unable to automate this particular game since tap and scroll time outs even though an unique key is being assigned to each of the element. ```dart Widget _buildItem(int index, String text, Status status, ShakeCell shaker) { return new MyButton( key: new ValueKey<int>(index), text: text, status: status, shaker: shaker, onPress: () { print("Pressed Index: ${index}"); print("Pressed Text: ${text}"); print("Pressed Statuses before checking: ${_statuses}"); int numOfVisible = _statuses.fold(0,(prev, element) => element == Status.Visible ? prev + 1 : prev); if (_pressedTileIndex == index || _statuses[index] == Status.Visible || numOfVisible >= 2 || cnt > 2) return; cnt++; setState(() { _statuses[index] = Status.Visible; }); print("Pressed Statuses1: ${_statuses}"); if (cnt == 2) { if (_pressedTile == text) { new Future.delayed(const Duration(milliseconds: 250), () { setState(() { _letters[_pressedTileIndex] = null; _letters[index] = null; _statuses[_pressedTileIndex] = Status.Disappear; _statuses[index] = Status.Disappear; _pressedTileIndex = -1; _pressedTile = null; cnt = 0; }); }); _matched++; widget.onScore(2); widget.onProgress((_progressCnt) / (_allLetters.length / 2)); _progressCnt++; print("Rajesh-Matched${_matched}"); if (_matched == 8) { _matched = 0; new Future.delayed(const Duration(milliseconds: 250), () { print("Rajesh Game-End"); widget.onEnd(); }); } print("Pressed Statuses2: ${_statuses}"); print("Matched"); } else { new Future.delayed(const Duration(milliseconds: 50), () { setState(() { _shaker[_pressedTileIndex] = ShakeCell.Wrong; _shaker[index] = ShakeCell.Wrong; }); }); new Future.delayed(const Duration(milliseconds: 500), () { setState(() { _shaker[_pressedTileIndex] = ShakeCell.Right; _shaker[index] = ShakeCell.Right; }); }); new Future.delayed(const Duration(milliseconds: 800), () { setState(() { _statuses[_pressedTileIndex] = Status.Hidden; _statuses[index] = Status.Hidden; _pressedTileIndex = -1; _pressedTile = null; cnt = 0; }); print("Pressed Statuses3: ${_statuses}"); }); print("Unmatched"); } print("Pressed Statuses4: ${_statuses}"); return; } _pressedTileIndex = index; _pressedTile = text; }); } @override Widget build(BuildContext context) { print("MyTableState.build"); MediaQueryData media = MediaQuery.of(context); print(media); if (_isLoading) { return new SizedBox( width: 20.0, height: 20.0, child: new CircularProgressIndicator(), ); } int j = 0; return new ResponsiveGridView( rows: _size, cols: _size, children: _letters .map((e) => _buildItem(j, e, _statuses[j], _shaker[j++])) .toList(growable: false), ); } } class MyButton extends StatefulWidget { MyButton({Key key, this.text, this.status, this.shaker, this.onPress}) : super(key: key); final String text; Status status; ShakeCell shaker; final VoidCallback onPress; @override _MyButtonState createState() => new _MyButtonState(); } class _MyButtonState extends State<MyButton> with TickerProviderStateMixin { AnimationController controller, shakeController; Animation<double> animation, shakeAnimation; AnimationController flipController; String _displayText; initState() { super.initState(); print("_MyButtonState.initState: ${widget.text}"); _displayText = widget.text; controller = new AnimationController(duration: new Duration(milliseconds: 250), vsync: this); shakeController = new AnimationController(duration: new Duration(milliseconds: 40), vsync: this); flipController = new AnimationController(duration: new Duration(milliseconds: 250), vsync: this); animation = new CurvedAnimation(parent: controller, curve: Curves.easeIn) ..addStatusListener((state) { print("$state:${animation.value}"); if (state == AnimationStatus.dismissed) { print('dismissed'); if (widget.text != null) { setState(() => _displayText = widget.text); controller.forward(); } } }); controller.forward().then((f){flipController.reverse();}); shakeAnimation = new Tween(begin: -6.0, end: 6.0).animate(shakeController); _myAnim(); } void _myAnim() { shakeAnimation.addStatusListener((status) { if (status == AnimationStatus.completed) { shakeController.reverse(); } else if (status == AnimationStatus.dismissed) { shakeController.forward(); } }); shakeController.forward(); } @override void dispose() { shakeController.dispose(); controller.dispose(); super.dispose(); } @override void didUpdateWidget(MyButton oldWidget) { print("Rajesh"); super.didUpdateWidget(oldWidget); if (oldWidget.text == null && widget.text != null) { flipController.reverse(); print("Rajesh1"); _displayText = widget.text; controller.forward(); } else if (oldWidget.text != widget.text) { print("Rajesh2"); controller.reverse(); } else { print("Rajesh3"); if (oldWidget.status != widget.status) { print("Rajesh4"); if (widget.status == Status.Visible) { print("Rajesh5"); flipController.forward(); } else { print("Rajesh6"); flipController.reverse(); } } } print("_MyButtonState.didUpdateWidget: ${widget.text} ${oldWidget.text}"); } @override Widget build(BuildContext context) { print("_MyButtonState.build"); return new Shake( animation: widget.shaker == ShakeCell.Wrong ? shakeAnimation : animation, child: new FlipAnimator( controller: flipController, front: new ScaleTransition( scale: animation, child: new RaisedButton( onPressed: () => widget.onPress(), padding: const EdgeInsets.all(8.0), color: Colors.teal, shape: new RoundedRectangleBorder( borderRadius: const BorderRadius.all(const Radius.circular(4.0))), child: new Text(_displayText, style: new TextStyle( color: Colors.white, fontSize: 24.0)))), back: new RaisedButton( onPressed: () => widget.onPress(), padding: const EdgeInsets.all(8.0), color: Colors.teal, shape: new RoundedRectangleBorder( borderRadius: const BorderRadius.all(const Radius.circular(8.0))), child: new Text(' ', style: new TextStyle(color: Colors.teal, fontSize: 24.0))))); } } ``` I am not sure if the problem lies with the Shake class or using the responsive grid because its been working fine in other games. This is the flutter driver script that I am using for automating the test: ``` import 'dart:async'; import 'package:flutter_driver/flutter_driver.dart'; import 'package:test/test.dart'; const Duration kWaitBetweenActions = const Duration(milliseconds: 1000); void main() { group('login', () { FlutterDriver driver; setUpAll(() async { driver = await FlutterDriver.connect(); }); tearDownAll(() async { if (driver != null) await driver.close(); }); test('task', () async { final SerializableFinder user = find.byValueKey('user-Chimple'); await driver.tap(user); final SerializableFinder game = find.text('Game'); await driver.tap(game); final SerializableFinder memory = find.byValueKey('memory'); await driver.tap(memory); final SerializableFinder upc = find.text('Upper Case Letters'); await driver.tap(upc); final SerializableFinder mode = find.byValueKey('single'); await driver.tap(mode); final SerializableFinder index = find.byValueKey(0); await driver.tap(index); }); }); } ``` ## Logs ``` 00:12 +0 -1: login task [E] DriverError: Error in Flutter application: Timeout while executing tap: TimeoutException after 0:00:05.000000: Future not completed #0 FlutterDriverExtension.call (package:flutter_driver/src/extension/extension.dart:168:31) <asynchronous suspension> #1 BindingBase.registerServiceExtension.<anonymous closure> (package:flutter/src/foundation/binding.dart:370:32) <asynchronous suspension> #2 _runExtension (dart:developer/runtime/libdeveloper.dart:85:23) #3 Widget.canUpdate (package:flutter/src/widgets/framework.dart:432:15) #4 Element.update (package:flutter/src/widgets/framework.dart:2745:19) #5 RenderObjectElement.update (package:flutter/src/widgets/framework.dart:4268:11) #6 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4642:11) #7 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #8 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4644:14) #9 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #10 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3636:16) #11 Element.rebuild (package:flutter/src/widgets/framework.dart:3478:5) #12 StatefulElement.update (package:flutter/src/widgets/framework.dart:3782:5) #13 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #14 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3636:16) #15 Element.rebuild (package:flutter/src/widgets/framework.dart:3478:5) #16 StatelessElement.update (package:flutter/src/widgets/framework.dart:3685:5) #17 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #18 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4644:14) #19 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #20 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4644:14) #21 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #22 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3636:16) #23 Element.rebuild (package:flutter/src/widgets/framework.dart:3478:5) #24 StatelessElement.update (package:flutter/src/widgets/framework.dart:3685:5) #25 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #26 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4644:14) #27 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #28 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3636:16) #29 Element.rebuild (package:flutter/src/widgets/framework.dart:3478:5) #30 StatefulElement.update (package:flutter/src/widgets/framework.dart:3782:5) #31 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #32 RenderObjectElement.updateChildren (package:flutter/src/widgets/framework.dart:4362:32) #33 MultiChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4752:17) #34 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #35 _TheatreElement.update (package:flutter/src/widgets/overlay.dart:507:16) #36 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #37 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3636:16) #38 Element.rebuild (package:flutter/src/widgets/framework.dart:3478:5) #39 StatefulElement.update (package:flutter/src/widgets/framework.dart:3782:5) #40 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #41 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3636:16) #42 Element.rebuild (package:flutter/src/widgets/framework.dart:3478:5) #43 ProxyElement.update (package:flutter/src/widgets/framework.dart:3892:5) #44 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #45 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4644:14) #46 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #47 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3636:16) #48 Element.rebuild (package:flutter/src/widgets/framework.dart:3478:5) #49 StatefulElement.update (package:flutter/src/widgets/framework.dart:3782:5) #50 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #51 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4644:14) #52 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #53 SingleChildRenderObjectElement.update (package:flutter/src/widgets/framework.dart:4644:14) #54 Element.updateChild (package:flutter/src/widgets/framework.dart:2682:15) #55 ComponentElement.performRebuild (package:flutter/src/widgets/framework.dart:3636:16) #56 Element.rebuild (package:flutter/src/widgets/framework.dart:3478:5) #57 BuildOwner.buildScope (package:flutter/src/widgets/framework.dart:2225:33) #58 __DriverBinding&BindingBase&ServicesBinding&SchedulerBinding&GestureBinding&PaintingBinding&RendererBinding&WidgetsBinding.drawFrame (package:flutter/src/widgets/binding.dart:621:20) #59 __DriverBinding&BindingBase&ServicesBinding&SchedulerBinding&GestureBinding&PaintingBinding&RendererBinding._handlePersistentFrameCallback (package:flutter/src/rendering/binding.dart:208:5) #60 __DriverBinding&BindingBase&ServicesBinding&SchedulerBinding._invokeFrameCallback (package:flutter/src/scheduler/binding.dart:990:15) #61 __DriverBinding&BindingBase&ServicesBinding&SchedulerBinding.handleDrawFrame (package:flutter/src/scheduler/binding.dart:930:9) #62 __DriverBinding&BindingBase&ServicesBinding&SchedulerBinding._handleDrawFrame (package:flutter/src/scheduler/binding.dart:842:5) #63 _invoke (dart:ui/hooks.dart:120:13) #64 _drawFrame (dart:ui/hooks.dart:109:3) Original error: null Original stack trace: null package:flutter_driver/src/driver/driver.dart 342:7 FlutterDriver._sendCommand ===== asynchronous gap =========================== dart:async/future_impl.dart 22 _Completer.completeError package:flutter_driver/src/driver/driver.dart FlutterDriver._sendCommand ===== asynchronous gap =========================== dart:async/zone.dart 1055 _CustomZone.registerUnaryCallback dart:async-patch/dart:async/async_patch.dart 77 _asyncThenWrapperHelper package:flutter_driver/src/driver/driver.dart 319:68 FlutterDriver._sendCommand package:flutter_driver/src/driver/driver.dart 368:11 FlutterDriver.tap ===== asynchronous gap =========================== dart:async/zone.dart 1047 _CustomZone.registerCallback dart:async/zone.dart 964 _CustomZone.bindCallbackGuarded dart:async/schedule_microtask.dart 147 scheduleMicrotask dart:async/future.dart 198 new Future.microtask package:flutter_driver/src/driver/driver.dart 367:73 FlutterDriver.tap test_driver\mem_test.dart 36:20 main.<fn>.<fn> ===== asynchronous gap =========================== dart:async/zone.dart 1055 _CustomZone.registerUnaryCallback dart:async-patch/dart:async/async_patch.dart 77 _asyncThenWrapperHelper test_driver\mem_test.dart 19:27 main.<fn>.<fn> package:test/src/backend/declarer.dart 161:27 Declarer.test.<fn>.<fn>.<fn> ===== asynchronous gap =========================== dart:async/zone.dart 1055 _CustomZone.registerUnaryCallback dart:async-patch/dart:async/async_patch.dart 77 _asyncThenWrapperHelper package:test/src/backend/declarer.dart 159:70 Declarer.test.<fn>.<fn>.<fn> package:test/src/backend/invoker.dart 249:15 Invoker.waitForOutstandingCallbacks.<fn> ===== asynchronous gap =========================== dart:async/zone.dart 1047 _CustomZone.registerCallback dart:async/zone.dart 964 _CustomZone.bindCallbackGuarded dart:async/schedule_microtask.dart 147 scheduleMicrotask dart:async/future.dart 198 new Future.microtask package:test/src/backend/invoker.dart 246:23 Invoker.waitForOutstandingCallbacks.<fn> dart:async/zone.dart 1126 _rootRun dart:async/zone.dart 1023 _CustomZone.run dart:async/zone.dart 1501 runZoned package:test/src/backend/invoker.dart 246:5 Invoker.waitForOutstandingCallbacks package:test/src/backend/declarer.dart 159:33 Declarer.test.<fn>.<fn> dart:async/zone.dart 1126 _rootRun dart:async/zone.dart 1023 _CustomZone.run dart:async/zone.dart 1501 runZoned package:test/src/backend/declarer.dart 158:13 Declarer.test.<fn> ===== asynchronous gap =========================== dart:async/zone.dart 1047 _CustomZone.registerCallback dart:async/zone.dart 964 _CustomZone.bindCallbackGuarded dart:async/schedule_microtask.dart 147 scheduleMicrotask dart:async/future.dart 198 new Future.microtask package:test/src/backend/declarer.dart 143:66 Declarer.test.<fn> package:test/src/backend/invoker.dart 403:25 Invoker._onRun.<fn>.<fn>.<fn>.<fn> ===== asynchronous gap =========================== dart:async/zone.dart 1047 _CustomZone.registerCallback dart:async/zone.dart 964 _CustomZone.bindCallbackGuarded dart:async/schedule_microtask.dart 147 scheduleMicrotask dart:async/future.dart 198 new Future.microtask package:test/src/backend/invoker.dart 402:31 Invoker._onRun.<fn>.<fn>.<fn>.<fn> dart:async/future.dart 174 new Future.<fn> package:stack_trace/src/stack_zone_specification.dart 209:15 StackZoneSpecification._run package:stack_trace/src/stack_zone_specification.dart 119:48 StackZoneSpecification._registerCallback.<fn> dart:async/zone.dart 1122 _rootRun dart:async/zone.dart 1023 _CustomZone.run dart:async/zone.dart 925 _CustomZone.runGuarded dart:async/zone.dart 965 _CustomZone.bindCallbackGuarded.<fn> package:stack_trace/src/stack_zone_specification.dart 209:15 StackZoneSpecification._run package:stack_trace/src/stack_zone_specification.dart 119:48 StackZoneSpecification._registerCallback.<fn> dart:async/zone.dart 1126 _rootRun dart:async/zone.dart 1023 _CustomZone.run dart:async/zone.dart 949 _CustomZone.bindCallback.<fn> dart:async-patch/dart:async/timer_patch.dart 21 Timer._createTimer.<fn> dart:isolate-patch/dart:isolate/timer_impl.dart 382 _Timer._runTimers dart:isolate-patch/dart:isolate/timer_impl.dart 416 _Timer._handleMessage dart:isolate-patch/dart:isolate/isolate_patch.dart 165 _RawReceivePortImpl._handleMessage ===== asynchronous gap =========================== dart:async/zone.dart 1047 _CustomZone.registerCallback dart:async/zone.dart 964 _CustomZone.bindCallbackGuarded dart:async/timer.dart 52 new Timer dart:async/timer.dart 87 Timer.run dart:async/future.dart 172 new Future package:test/src/backend/invoker.dart 402:15 Invoker._onRun.<fn>.<fn>.<fn> ===== asynchronous gap =========================== dart:async/zone.dart 1047 _CustomZone.registerCallback dart:async/zone.dart 964 _CustomZone.bindCallbackGuarded dart:async/schedule_microtask.dart 147 scheduleMicrotask dart:async/future.dart 198 new Future.microtask package:test/src/backend/invoker.dart 389:27 Invoker._onRun.<fn>.<fn>.<fn> dart:async/zone.dart 1126 _rootRun dart:async/zone.dart 1023 _CustomZone.run dart:async/zone.dart 1501 runZoned package:test/src/backend/invoker.dart 389:9 Invoker._onRun.<fn>.<fn> package:test/src/backend/invoker.dart 443:15 Invoker._guardIfGuarded package:test/src/backend/invoker.dart 388:7 Invoker._onRun.<fn> package:stack_trace/src/chain.dart 101:24 Chain.capture.<fn> dart:async/zone.dart 1126 _rootRun dart:async/zone.dart 1023 _CustomZone.run dart:async/zone.dart 1501 runZoned package:stack_trace/src/chain.dart 99:12 Chain.capture package:test/src/backend/invoker.dart 387:11 Invoker._onRun package:test/src/backend/live_test_controller.dart 188:11 LiveTestController._run package:test/src/backend/live_test_controller.dart 40:31 _LiveTest.run dart:async/future.dart 200 new Future.microtask.<fn> dart:async/zone.dart 1122 _rootRun dart:async/zone.dart 1023 _CustomZone.run dart:async/zone.dart 925 _CustomZone.runGuarded dart:async/zone.dart 965 _CustomZone.bindCallbackGuarded.<fn> dart:async/zone.dart 1126 _rootRun dart:async/zone.dart 1023 _CustomZone.run dart:async/zone.dart 925 _CustomZone.runGuarded dart:async/zone.dart 965 _CustomZone.bindCallbackGuarded.<fn> dart:async/schedule_microtask.dart 41 _microtaskLoop dart:async/schedule_microtask.dart 50 _startMicrotaskLoop dart:isolate-patch/dart:isolate/timer_impl.dart 391 _Timer._runTimers dart:isolate-patch/dart:isolate/timer_impl.dart 416 _Timer._handleMessage dart:isolate-patch/dart:isolate/isolate_patch.dart 165 _RawReceivePortImpl._handleMessage 00:12 +0 -1: login (tearDownAll) 00:12 +0 -1: Some tests failed. Unhandled exception: Dummy exception to set exit code. #0 _rootHandleUncaughtError.<anonymous closure> (dart:async/zone.dart:1114) #1 _microtaskLoop (dart:async/schedule_microtask.dart:41) #2 _startMicrotaskLoop (dart:async/schedule_microtask.dart:50) #3 _Timer._runTimers (dart:isolate-patch/dart:isolate/timer_impl.dart:391) #4 _Timer._handleMessage (dart:isolate-patch/dart:isolate/timer_impl.dart:416) #5 _RawReceivePortImpl._handleMessage (dart:isolate-patch/dart:isolate/isolate_patch.dart:165) Stopping application instance. I/FlutterActivityDelegate( 4749): onResume setting current activity to this Driver tests failed: 255 ```
a: tests,tool,t: flutter driver,P2,team-tool,triaged-tool
low
Critical
317,992,091
vue
Vue breaks the styling when using comments in inline style attribute
### Version 2.5.16 ### Reproduction link [https://jsbin.com/gutivaf/edit?html,css,js,output](https://jsbin.com/gutivaf/edit?html,css,js,output) ### Steps to reproduce - Add a comment inside any style attribute on an element within the Vue app instance. Example: ... style="color:blue; /* This is a comment */ background-color:yellow;" ... ### What is expected? The element should have blue text on yellow background. ### What is actually happening? The comment breaks the attribute and all the style properties *after* the comment are ignored (not coming in effect). In the reproduction example the text is blue but the background is *not* yellow. --- (The JSBin contains a slightly different example. I hope you can live with that.) <!-- generated by vue-issues. DO NOT REMOVE -->
improvement
low
Minor
317,998,488
angular
Angular Elements should keep an HTML attribute value in sync with a property value
<!-- PLEASE HELP US PROCESS GITHUB ISSUES FASTER BY PROVIDING THE FOLLOWING INFORMATION. ISSUES MISSING IMPORTANT INFORMATION MAY BE CLOSED WITHOUT INVESTIGATION. --> ## I'm submitting a... <!-- Check one of the following options with "x" --> <pre><code> [ ] Regression (a behavior that used to work and stopped working in a new release) [X] Bug report <!-- Please search GitHub for a similar issue or PR before submitting --> [ ] Performance issue [X] Feature request [ ] Documentation issue or request [ ] Support request => Please do not submit support request here, instead see https://github.com/angular/angular/blob/master/CONTRIBUTING.md#question [ ] Other... Please describe: </code></pre> ## Current behavior <!-- Describe how the issue manifests. --> We encountered a bug/missing feature in Angular Elements in synchronizing between the property and the HTML attribute that reference to the same variable. In other words, when the HTML attribute is changed using setAttribute() method, it will change the property value. However, changing the property value will not affect the HTML attribute value (please see the example below). **Component Declaration** ``` @Component({ selector: 'test-component', templateUrl: './test-component.component.html', styleUrls: ['./test-component.component.scss'] }) export class TestComponent implements OnInit { @Input('custom-name') public customName : string = "test some string"; ngOnInit() { } } ``` **Component Usage** ``` // Changing Attribute value --> affects the corresponding property document.querySelector('test-component').setAttribute('custom-name', 'from attribute'); console.log(document.querySelector('test-component).customName); // "from attribute" // Changing Property value --> DOSE NOT affect the corresponding attribute document.querySelector('test-component).customName = 'from property'; console.log(document.querySelector('test-component').getAttribute('custom-name')); //"from attribute" ``` ## Expected behavior <!-- Describe what the desired behavior would be. --> Properties and HTML Attributes should still in sync, regardless how they were changed. **E.g.** ``` // Changing Attribute value --> affects the corresponding property document.querySelector('test-component').setAttribute('custom-name', 'from attribute'); console.log(document.querySelector('test-component).customName); // "from attribute" // Changing Property value --> affects the corresponding attribute document.querySelector('test-component).customName = 'from property'; console.log(document.querySelector('test-component').getAttribute('custom-name')); //"from property" ``` Another Subject that related to the same context: Polymer creates automatically for each property an event that has the name "property-name-changed" that will be triggered, when the property is changed. Are you planning to do the same in Angular Elements?
feature,help wanted,freq3: high,area: elements,P4,feature: under consideration
low
Critical
318,006,747
vscode
Allow programatically un-selecting an item in a contributed tree
We can select items in the tree node with `reveal`, but we can't un-select. For an outline view that follows the users cursor, it would be good to unselect when the user moves the cursor to some empty whitespace that doesn't have a matching node. The existing explorer treeview also does this; if you open a file that's outside of the workspace folders (or create a new untitled file) then no items are selected in the tree.
feature-request,api,tree-views
medium
Critical
318,021,077
godot
Godot should add a warning symbol when a compressed emissive texture is used
By default Godot compresses every textures in Video Ram mode, that is fine for most textures type but with an emissive if a GIProbes is used the color will be wrong. Godot should add a warning message when the texture plugged in the emissive slot is compressed, saying that the colors of the GI may be wrong and that the image should be uncompressed. An emissive map is poor in informations and low resolution so even uncompressed it will still be very optimized. ![wrong gi](https://user-images.githubusercontent.com/30020215/39307490-383b1d74-4963-11e8-9dc3-d89a4825b923.png)
topic:rendering,documentation,topic:3d
low
Minor
318,105,733
pytorch
[pytorch] Not handling python reload properly
Trying to reload some modules cause crashes: On python 2.7 (crash with ubuntu release, error messages from debug build). ``` >>> import torch >>> reload(torch) Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/alban/workspace/dev-pytorch/torch/__init__.py", line 288, in <module> from . import _torch_docs, _tensor_docs, _storage_docs ImportError: cannot import name _torch_docs >>> exit() python: ../Objects/typeobject.c:2739: type_dealloc: Assertion `type->tp_flags & (1L<<9)' failed. Aborted (core dumped) ``` ``` >>> from torch import autograd >>> reload(autograd) terminate called after throwing an instance of 'std::runtime_error' what(): generic_type: cannot initialize type "ProfilerEvent": an object with that name is already defined Aborted (core dumped) ``` @colesbury can you see an obvious reason for this? Or should I look into more details?
todo,module: crash,triaged
low
Critical
318,110,271
youtube-dl
ERROR: Unsupported URL: http://play.afreecatv.com/whiteang/embed
``` ➜ ~ youtube-dl --proxy socks5://127.0.0.1:1080/ -F http://play.afreecatv.com/yuna830/203150344 [generic] 203150344: Requesting header WARNING: Falling back on generic information extractor. [generic] 203150344: Downloading webpage [generic] 203150344: Extracting information [generic] embed: Requesting header WARNING: Falling back on generic information extractor. [generic] embed: Downloading webpage [generic] embed: Extracting information ERROR: Unsupported URL: http://play.afreecatv.com/yuna830/embed ➜ ~ ```
site-support-request
low
Critical
318,153,665
go
cmd/compile: optimize unaligned load-XOR-store on byte slices
It would be nice if the following sets of code were equivalent on platforms that support unaligned loads/stores (386, amd64, arm64, ppc64le, s390x...). I've used XOR in these examples but it is also true for the other logical operators: (1) ```go binary.LittleEndian.PutUint32(dst, binary.LittleEndian.Uint32(src) ^ x) ``` (2) ```go dst[0] = src[0] ^ byte(x) dst[1] = src[1] ^ byte(x>>8) dst[2] = src[2] ^ byte(x>>16) dst[3] = src[3] ^ byte(x>>24) ``` (3) [less important] ```go x ^= uint32(src[0]) x ^= uint32(src[1]) << 8 x ^= uint32(src[2]) << 16 x ^= uint32(src[3]) << 24 binary.LittleEndian.PutUint32(dst, x) ``` Currently (1) is optimal on platforms with unaligned loads and (2) is optimal on other platforms. It would be nice if the compiler could optimize (2) into (1). I've added (3) as an additional case where the current rules are suboptimal. If this is ever done it will help simplify the generic `golang.org/x/crypto/internal/chacha20` implementation.
Performance,compiler/runtime
low
Minor
318,175,313
TypeScript
Compiler API: Expose More from typescript.d.ts
**TypeScript Version:** 2.9.0-dev.20180426 While [Traversing the TypeScript AST](https://github.com/Microsoft/TypeScript/wiki/Using-the-Compiler-API#traversing-the-ast-with-a-little-linter) of a source file, there have been a number of helpful things I've found by extending `ts.*` from `typescript.d.ts` and I would like it if these could be exposed (or not marked `/* @internal */`). **Search Terms:** typescript.d.ts Node.locals Symbol.parent getContainingFunction isAssignmentTarget **Code** ```ts declare namespace ts { interface Node { /* @internal */ readonly locals?: SymbolTable; // Locals associated with node (initialized by binding) } interface Symbol { /* @internal */ readonly parent?: Symbol; // Parent symbol } function getContainingFunction(node: Node): SignatureDeclaration | undefined; function isAssignmentTarget(node: Node): boolean; } ``` Note: * Added `readonly` for `Node#locals` & `Symbol#parent` * For `Symbol#parent`, the goal is: given the symbol for a method (e.g., `methodSymbol` for `Number#toString`) find where that method is defined (e.g., `Number`)... maybe `program.getTypeChecker().getSymbolAtLocation(methodSymbol.valueDeclaration.parent)` is what is "supposed" to be used instead? * For `ts.getContainingFunction()` it seems more appropriate to have a return type of `SignatureDeclaration | undefined` instead of `SignatureDeclaration` **Related Issues:** #15841
Suggestion,Help Wanted,API
low
Major
318,216,228
go
cmd/compile: prove pass doesn't draw signed int conclusions from range checks
This might be fixed by outstanding prove CLs, but just in case, consider this snippet from math/expm1.go: ```go var k int // ... switch { case k == -1: return 0.5*(x-e) - 0.5 case k == 1: if x < -0.25 { return -2 * (e - (x + 0.5)) } return 1 + 2*(x-e) case k <= -2 || k > 56: // suffice to return exp(x)-1 y := 1 - (e - x) y = Float64frombits(Float64bits(y) + uint64(k)<<52) // add k to y's exponent return y - 1 } if k < 20 { t := Float64frombits(0x3ff0000000000000 - (0x20000000000000 >> uint(k))) // t=1-2**-k y := t - (e - x) y = Float64frombits(Float64bits(y) + uint64(k)<<52) // add k to y's exponent return y } ``` Note the switch case `k <= -2 || k > 56`. The compiler rewrites this into a single unsigned comparison: `uint(x) > 57`. See `func walkinrange` in walk.go. After the `k < 20` check (in particular, when considering `uint64(k)<<52`, the prove pass has signed limits of [-9223372036854775808, 19] for k and no unsigned limits. But I believe that we should know that k is in [-2, 19]. I might have the culprit/analysis wrong...but in any case, we should know more about `uint64(k)` here. Noticed while exploring #25087. cc @rasky
Performance,compiler/runtime
low
Major
318,228,805
TypeScript
Some overloaded signatures never be choose when explicit type parameters are specified
**TypeScript Version:** 2.7.0-dev.201xxxxx <!-- Search terms you tried before logging this (so others can find this issue more easily) --> **Search Terms:** **Code** ```ts then<TResult1 = T, TResult2 = never>(onfulfilled?: undefined | null, onrejected?: undefined | null): Promise<T>; then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): PromiseLike<TResult1 | TResult2>; then<TResult1 = T, TResult2 = never>(onfulfilled?: undefined | null, onrejected?: undefined | null): Promise<T>; ``` ```ts Promise.resolve(0).then<string>(); ``` **Expected behavior:** ```ts Promise.resolve(0).then<string>(); // T is number from the first or third signature ``` **Actual behavior:** ```ts Promise.resolve(0).then<string>(); // T is string from the second signature ``` **Playground Link:** <!-- A link to a TypeScript Playground "Share" link which demonstrates this behavior --> **Related Issues:** #23364
Bug
low
Minor
318,248,707
pytorch
[Caffe2] LT and GT cannot be exported to ONNX
When I try to export a simple network using LT (or GT) to ONNX, I get the following error: ## Error log ``` Traceback (most recent call last): ... File "/home/masato/repo/pytorch/build/caffe2/python/onnx/frontend.py", line 346, in caffe2_net_to_onnx_model model = make_model(cls.caffe2_net_to_onnx_graph(*args, **kwargs), File "/home/masato/repo/pytorch/build/caffe2/python/onnx/frontend.py", line 262, in caffe2_net_to_onnx_graph checker.check_graph(graph_def) File "/home/masato/repo/onnx/onnx/checker.py", line 45, in checker proto.SerializeToString(), ctx) onnx.onnx_cpp2py_export.checker.ValidationError: No Schema registered for LT with domain_version of 6 ==> Context: Bad node spec: input: "in_data_0" input: "bias_0" output: "out_data_1" name: "" op_type: "LT ``` ## Sample Code ```python #!/usr/bin/env python import onnx import caffe2.python.onnx.frontend as oc2f import caffe2.python.predictor.predictor_exporter as pe import caffe2.python.predictor.mobile_exporter as c2me from caffe2.python import model_helper, workspace, brew, utils IN_DATA_NAME = "in_data" IN_BIAS_NAME = "bias" OUT_DATA_NAME = "out_data" WIDTH = 3 HEIGHT = 4 CHAN = 2 AXIS = 1 DATA_SHAPE = (1, CHAN, HEIGHT, WIDTH) model = model_helper.ModelHelper(name="less_net") model.net.LT([IN_DATA_NAME, IN_BIAS_NAME], OUT_DATA_NAME) model.param_init_net.UniformFill([], IN_DATA_NAME, shape=DATA_SHAPE) model.param_init_net.UniformFill([], IN_BIAS_NAME, shape=DATA_SHAPE) workspace.RunNetOnce(model.param_init_net) init_net, predict_net = c2me.Export(workspace, model.net, [IN_DATA_NAME, IN_BIAS_NAME]) value_info = { } onnx_model = oc2f.caffe2_net_to_onnx_model( predict_net, init_net, value_info) onnx.checker.check_model(onnx_model) print(onnx_model) outname = "less_no_broadcast.onnx" with open(outname, 'wb') as f: f.write(onnx_model.SerializeToString()) ``` ## Possible Fix? If I change Caffe2 like the following, it works. The error seems to be coming from `LT` not being converted to its appropriate ONNX counterpart name `Less` ```diff diff --git a/caffe2/python/onnx/frontend.py b/caffe2/python/onnx/frontend.py index c96b86143..b5106d337 100644 --- a/caffe2/python/onnx/frontend.py +++ b/caffe2/python/onnx/frontend.py @@ -54,6 +54,8 @@ class Caffe2Frontend(object): 'AveragePool1D': 'AveragePool', 'AveragePool2D': 'AveragePool', 'AveragePool3D': 'AveragePool', + 'LT': 'Less', + 'GT': 'Greater', } # caffe2 arguments that are completely removed in onnx ``` ## System Info - OS: Ubuntu 16.04.4 x86_64 - pytorch: 2e156f3eabb6fa4ae88c2e831aea7da344cf43a3 - onnx: b8c423889b3d15825e90fd5bd8fa1766ba2200ce - Python: 3.5.2
caffe2
low
Critical
318,250,105
go
x/net/http2: steady performance degeneration seen with HTTP/2 over recent releases
Hello, I work on the full text search engine at couchbase, and we recently moved our scatter gather protocol to use x/net/http2 instead of net/http. The go version we currently use is go-1.9.3. In some testing in house .. I've noticed the query throughput over a full text index take a nose dive as I upgraded the x/net release version used. (These numbers are over a system that runs on centos7) | branch | query throughput | | ----------------------- | ----------------- | | release-branch.go1.6 | 27734 q/s | | release-branch.go1.7 | 17037 q/s | | release-branch.go1.8 | 15139 q/s | | release-branch.go1.9 | 14836 q/s | | release-branch.go1.10 | 9500 q/s | | master | 8336 q/s | This is how the scatter-gather client is set up in our code using x/net/http2's transport: transport2 := &http2.Transport{ TLSClientConfig: clientTLSConfig, } cbft.Http2Client = &http.Client{Transport: transport2} And here's how the server is setup, which also uses the x/net/netutil to set up a LimitListener: listener, _ := net.Listen("tcp", bindHTTP) server := &http.Server{Addr: bindHTTP, Handler: routerInUse, ReadTimeout: httpReadTimeout, WriteTimeout: httpWriteTimeout } ... keepAliveListener := tcpKeepAliveListener{listener.(*net.TCPListener)} limitListener := netutil.LimitListener(keepAliveListener, httpMaxConnections) tlsListener := tls.NewListener(limitListener, serverTLSConfig) ... _ = server.Serve(tlsListener) **I was wondering if there're any known issues around this area, or if there're any additional settings that I'd have to tune in the later branches of x/net.** I also tried writing up a simple server client benchmark unit test, based on your current tests to see if it'd point out anything obvious .. ``` func BenchmarkServerClient(b *testing.B) { b.ReportAllocs() const ( itemSize = 1 << 10 itemCount = 1000 ) st := newServerTester(b, func(w http.ResponseWriter, r *http.Request) { for i := 0; i < itemCount; i++ { _, err := w.Write(make([]byte, itemSize)) if err != nil { return } } }, optOnlyServer) defer st.Close() tlsConfig := &tls.Config{ InsecureSkipVerify: true, } tr := &Transport{TLSClientConfig: tlsConfig} defer tr.CloseIdleConnections() cl := &http.Client{Transport: tr} b.ResetTimer() for i := 0; i < b.N; i++ { resp, err := cl.Get(st.ts.URL) if err != nil { b.Fatal(err) } resp.Body.Close() } } ``` And here're the results for the above benchmark test from my computer (on OSX 10.13.4): ``` release-branch.go1.6 BenchmarkServerClient-8 2000 742842 ns/op 18715 B/op 64 allocs/op release-branch.go1.7 BenchmarkServerClient-8 2000 554580 ns/op 20688 B/op 83 allocs/op release-branch.go1.8 BenchmarkServerClient-8 2000 631001 ns/op 20728 B/op 84 allocs/op release-branch.go1.9 BenchmarkServerClient-8 2000 675503 ns/op 19745 B/op 87 allocs/op release-branch.go1.10 BenchmarkServerClient-8 2000 772618 ns/op 19087 B/op 89 allocs/op master BenchmarkServerClient-8 2000 930152 ns/op 19212 B/op 89 allocs/op ``` So although I couldn't reproduce the issue accurately (with 1.6 as the anomaly here), there is some degeneration in time taken per op from 1.7 to master. This is the go env output from my system: ``` GOARCH="amd64" GOBIN="" GOCACHE="/Users/abhinavdangeti/Library/Caches/go-build" GOEXE="" GOHOSTARCH="amd64" GOHOSTOS="darwin" GOOS="darwin" GOPATH="/Users/abhinavdangeti/Documents/go" GORACE="" GOROOT="/usr/local/Cellar/go/1.10.1/libexec" GOTMPDIR="" GOTOOLDIR="/usr/local/Cellar/go/1.10.1/libexec/pkg/tool/darwin_amd64" GCCGO="gccgo" CC="clang" CXX="clang++" CGO_ENABLED="1" CGO_CFLAGS="-g -O2" CGO_CPPFLAGS="" CGO_CXXFLAGS="-g -O2" CGO_FFLAGS="-g -O2" CGO_LDFLAGS="-g -O2" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/ln/vkg1npcj5tz0ps359y6fwmn80000gn/T/go-build266872403=/tmp/go-build -gno-record-gcc-switches -fno-common" ``` I'd appreciate any pointers or advise regarding what I'm observing here ..
Performance,NeedsInvestigation
low
Critical
318,271,441
rust
E0210 Disallows theorietically legal implementation, or is misleading
Hi all, Had posted this on the internals forums as a potential improvement but didn't get any responses there. I'm fairly confident the following scenario should be allowed: ```rust trait CenterOriginRect { fn center(&self) -> Point; fn width(&self) -> Meters; fn height(&self) -> Meters; } impl<'a, T: CenterOriginRect> From<&'a T> for Rect { fn from(r: &T) -> Rect { Rect { x: r.center().x - r.width() / 2.0, y: r.center().y - r.height() / 2.0, w: r.width(), h: r.height(), } } } ``` Here, Rect is external to my crate, but, CenterOriginRect obviously isn't, and isn't exposed publicly either. Therefore, no one could define a conflicting implementation, but compiling results in E0210. At minimum, the error message seems either wrong or irrelevant, but seems to me this is a scenario the compiler could allow. Is that true? Thanks! Love Rust! Would be happy to contribute a fix if this is in fact legal. edit: [Link to forum post](https://internals.rust-lang.org/t/pre-rfc-allowing-generic-impls-of-external-traits-when-bounds-prevent-re-impl/7296)
C-enhancement,A-diagnostics,T-compiler
low
Critical
318,280,185
go
cmd/compile: regalloc's liveness analysis is quadratic
This is a known, difficult issue. It has been around since the SSA compiler was first merged. This is a tracking issue for it.
ToolSpeed,compiler/runtime
low
Minor
318,335,515
pytorch
[feature request] norm argument for RNNCells
Hey there pyTorch Community, I am currently working with RNNs and realized, that it would be great to have a norm argument for RNNCells which enables LayerNormalization for them. I implemented it for the LSTMCell and it should be straight forward to apply to the other ones as well. I think it would be worthwhile to implement it and I would be happy to do so, as it allows first time users to utilize a layer norm without going down to torch/nn/functions_/rnn. What do you think? Cheers, Jendrik cc @zou3519
module: rnn,triaged,enhancement
low
Minor
318,344,254
vscode
Does the watch view support auto completions?
_From @yaohaizh on April 8, 2018 14:37_ In the debug view, the auto completions is supported in the debug console, but it doesn't support in the watch view when typing expression for evaluation. _Copied from original issue: Microsoft/vscode-debugadapter-node#171_
feature-request,debug
medium
Critical
318,374,197
pytorch
[Compilation] how to disable caffe2?
Hi I have to compile and build pytorch from the source due to my geforce 920mx card. Now with merging caffe2 into pytorch the compilation time gets multipled beside the error i get when i try building it with `gcc-6` (i also get error near the end of building for gcc-5: `gcc-5: error: unrecognized command line option ‘-fno-plt’`). So is there any flag or switch to **not** include and compile caffe2 with pytorch? Thanks.
module: build,triaged
low
Critical
318,377,021
rust
HRTB variants are missing a std::fmt::Pointer impl
It seems that there is a missing implementation of `std::fmt::Pointer` on some function pointers: function pointers like `fn test() -> f32` can be passed as argument to `println!("{:p}", ...)` but function pointers like `fn test(Vec<T> a) -> f32` can't because it's a HRTB variant. see [https://users.rust-lang.org/t/display-function-pointer/17073](url) for more details.
C-enhancement,A-trait-system,E-needs-test,T-libs-api,T-types,A-higher-ranked
low
Major
318,387,376
vscode
Merge results from multiple DocumentHighlightProviders
as discussed in here: https://github.com/Microsoft/vscode-languageserver-node/issues/318 I would love to see VS Code to support the document highlights from multiple extensions simultaneously, much in the same way hovers can be provided from multiple extensions and are displayed in the same hover popup. The background for this is: I have a language server based extension for VS Code that can deliver documentHighlight information for Java code, but as long as the Java language extension itself is installed and active, my documentHighlights are never shown (but the ones from the Java extension instead). The purpose of my language server is to provide additional functionality for Java source code, not to replace the existing Java language tooling. Therefore I benefit from the ability to run multiple language servers for the same language (file type) and that the results from both are merged (which is the case for content assist and hover information, for example). I need the same mechanics for documentHighlight requests/responses... :-)
feature-request,editor-symbols
medium
Critical
318,388,636
go
cmd/compile: take into account that floating point special cases (NaN, Inf) are unlikely
`math.IsNaN` and `math.IsInf` are very unlikely to return true. It would be nice to use this information for code layout. I have hacked together a prototype using SSA rules but there is probably a better way to do it. The prototype is here: https://go-review.googlesource.com/c/go/+/64191. Feel free to take that and improve it.
Performance,help wanted,compiler/runtime
low
Minor
318,395,739
youtube-dl
Site support for Turner Classic Movies
## Please follow the guide below - You will be asked some questions and requested to provide some information, please read them **carefully** and answer honestly - Put an `x` into all the boxes [ ] relevant to your *issue* (like this: `[x]`) - Use the *Preview* tab to see what your issue will actually look like --- ### Make sure you are using the *latest* version: run `youtube-dl --version` and ensure your version is *2018.04.25*. If it's not, read [this FAQ entry](https://github.com/rg3/youtube-dl/blob/master/README.md#how-do-i-update-youtube-dl) and update. Issues with outdated version will be rejected. - [x ] I've **verified** and **I assure** that I'm running youtube-dl **2018.04.25** ### Before submitting an *issue* make sure you have: - [x ] At least skimmed through the [README](https://github.com/rg3/youtube-dl/blob/master/README.md), **most notably** the [FAQ](https://github.com/rg3/youtube-dl#faq) and [BUGS](https://github.com/rg3/youtube-dl#bugs) sections - [x ] [Searched](https://github.com/rg3/youtube-dl/search?type=Issues) the bugtracker for similar issues including closed ones - [x ] Checked that provided video/audio/playlist URLs (if any) are alive and playable in a browser ### What is the purpose of your *issue*? - [] Bug report (encountered problems with youtube-dl) - [x] Site support request (request for adding support for a new site) - [ ] Feature request (request for a new functionality) - [ ] Question - [ ] Other --- ### The following sections concretize particular purposed issues, you can erase any section (the contents between triple ---) not applicable to your *issue* --- ### If the purpose of this *issue* is a *bug report*, *site support request* or you are not completely sure provide the full verbose output as follows: 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 here. It should look similar to one below (replace it with **your** log inserted between triple ```): ``` youtube-dl --verbose http://tve-vod.cdn.turner.com/tcm/8c1f2dc45536e86658c56911a33246bb00000000/layer6/layer6_pt.m3u8 [debug] System config: [] [debug] User config: [] [debug] Custom config: [] [debug] Command-line args: [u'--verbose', u'http://tve-vod.cdn.turner.com/tcm/8c1f2dc45536e86658c56911a33246bb00000000/layer6/layer6_pt.m3u8'] [debug] Encodings: locale UTF-8, fs UTF-8, out UTF-8, pref UTF-8 [debug] youtube-dl version 2018.04.25 [debug] Python version 2.7.13 (CPython) - Linux-4.9.0-4-amd64-x86_64-with-debian-9.4 [debug] exe versions: none [debug] Proxy map: {} [generic] layer6_pt: Requesting header [generic] layer6_pt: Downloading m3u8 information ERROR: No video formats found; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output. Traceback (most recent call last): File "/usr/local/lib/python2.7/dist-packages/youtube_dl/YoutubeDL.py", line 789, in extract_info ie_result = ie.extract(url) File "/usr/local/lib/python2.7/dist-packages/youtube_dl/extractor/common.py", line 440, in extract ie_result = self._real_extract(url) File "/usr/local/lib/python2.7/dist-packages/youtube_dl/extractor/generic.py", line 2184, in _real_extract self._sort_formats(formats) File "/usr/local/lib/python2.7/dist-packages/youtube_dl/extractor/common.py", line 1083, in _sort_formats raise ExtractorError('No video formats found') ExtractorError: No video formats found; please report this issue on https://yt-dl.org/bug . Make sure you are using the latest version; see https://yt-dl.org/update on how to update. Be sure to call youtube-dl with the --verbose flag and include its complete output. ``` --- ### If the purpose of this *issue* is a *site support request* please provide all kinds of example URLs support for which should be included (replace following example URLs by **yours**): - Single video: http://tve-vod.cdn.turner.com/tcm/8c1f2dc45536e86658c56911a33246bb00000000/layer6/layer6_pt.m3u8 - Single video: http://tve-vod.cdn.turner.com/tcm/724d2a1565ff5d3863225e6584e230f400000000/layer6/layer6_pt.m3u8 Note that **youtube-dl does not support sites dedicated to [copyright infringement](https://github.com/rg3/youtube-dl#can-you-add-support-for-this-anime-video-site-or-site-which-shows-current-movies-for-free)**. In order for site support request to be accepted all provided example URLs should not violate any copyrights. --- ### Description of your *issue*, suggested solution and other information
site-support-request,geo-restricted,account-needed
low
Critical
318,396,470
pytorch
[Caffe2] compilation linker error `libtbb.so.2: undefined reference to std::__exception_ptr`
I am unable to compile caffe2 under fedora 27, cuda 9.1, cudnn 7. The linker fails with //usr/lib64/libtbb.so.2: undefined reference to `std::__exception_ptr::exception_ptr::exception_ptr(void*)@CXXABI_1.3.11' //usr/lib64/libtbb.so.2: undefined reference to `__cxa_init_primary_exception@CXXABI_1.3.11' This happens when linking `bin/common_subexpression_elimination_test`, `bin/conv_to_nnpack_transform_test`, `bin/generate_proposals_op_util_boxes_test` and some other tests as far as I can tell. Full gcc linker command before the first error: > /tools/miniconda2/bin/g++-5 -fvisibility-inlines-hidden -DONNX_NAMESPACE=onnx_c2 -O2 -fPIC -Wno-narrowing -Wno-invalid-partial-specialization -O3 -DNDEBUG -rdynamic caffe2/CMakeFiles/common_subexpression_elimination_test.dir/transforms/common_subexpression_elimination_test.cc.o -o bin/common_subexpression_elimination_test -Wl,-rpath,/home/pytorch/build/lib:/data/libs/cuda-9.1/lib64:/home/cudnn/v7/lib64: lib/libgtest_main.a lib/libgloo_cuda.a -Wl,--no-as-needed -Wl,--as-needed lib/libcaffe2_gpu.so lib/libcaffe2.so lib/libprotobuf.a -lpthread /usr/lib64/libgflags.so /usr/lib64/libglog.so /usr/lib64/libcuda.so /data/libs/cuda-9.1/lib64/libcurand.so /home/cudnn/v7/lib64/libcudnn.so /data/libs/cuda-9.1/lib64/libnvrtc.so /data/libs/cuda-9.1/lib64/libcublas.so /data/libs/cuda-9.1/lib64/libcublas_device.a lib/libgtest.a -pthread ../third_party/nccl/build/lib/libnccl_static.a /data/libs/cuda-9.1/lib64/libcudart_static.a -ldl -lrt lib/libgloo.a /data/libs/cuda-9.1/lib64/libcudart.so -lcuda /data/libs/cuda-9.1/lib64/libnvrtc.so -lpthread -lrt As referenced in [this issue](https://github.com/negativo17/cuda-gcc/issues/1), I suppose it has something to do with my system libraries compiled with gcc 7 instead of gcc 5 (which I use since cuda is not compatible with gcc 7), however I don't see what is dependent on `tbb` in caffe2 and how I can maintain my own local version of `tbb` compiled with gcc 5. ## System Info - Caffe2 - Build command: PATH=/data/libs/cuda-9.1/bin:$PATH cmake -DCUDNN_ROOT_DIR=/home/cudnn/v7 -DCUDA_HOST_COMPILER=/tools/miniconda2/bin/gcc-5 -DCMAKE_CXX_COMPILER=/tools/miniconda2/bin/g++-5 -DCMAKE_C_COMPILER=/tools/miniconda2/bin/gcc-5 -DCUDA_ARCH_NAME=Manual .. -DCMAKE_DISABLE_FIND_PACKAGE_Eigen3=TRUE -DCUDA_ARCH_BIN="35 50 52 60 61 70" - OS: fedora 27 CMake summary: > - General: > -- CMake version : 3.11.20180426-ge52cf > -- CMake command : /home/apps/cmake/bin/cmake > -- Git version : v0.1.11-8054-gf98b77808-dirty > -- System : Linux > -- C++ compiler : /tools/miniconda2/bin/g++-5 > -- C++ compiler version : 5.3.0 > -- BLAS : Eigen > -- CXX flags : -fvisibility-inlines-hidden -DONNX_NAMESPACE=onnx_c2 -O2 -fPIC -Wno-narrowing -Wno-invalid-partial-specialization > -- Build type : Release > -- Compile definitions : > -- > -- BUILD_BINARY : ON > -- BUILD_CUSTOM_PROTOBUF : ON > -- Link local protobuf : ON > -- BUILD_DOCS : OFF > -- BUILD_PYTHON : ON > -- Python version : 2.7.14 > -- Python includes : /usr/include/python2.7 > -- BUILD_SHARED_LIBS : ON > -- BUILD_TEST : ON > -- USE_ATEN : OFF > -- USE_ASAN : OFF > -- USE_CUDA : ON > -- CUDA static link : OFF > -- CUDA version : 9.1 > -- CuDNN version : 7.0.3 > -- CUDA root directory : /data/libs/cuda-9.1 > -- CUDA library : /usr/lib64/libcuda.so > -- cudart library : /data/libs/cuda-9.1/lib64/libcudart_static.a;-pthread;dl;/usr/lib64/librt.so > -- cublas library : /data/libs/cuda-9.1/lib64/libcublas.so;/data/libs/cuda-9.1/lib64/libcublas_device.a > -- curand library : /data/libs/cuda-9.1/lib64/libcurand.so > -- CuDNN library : /home/cudnn/v7/lib64/libcudnn.so > -- nvrtc : /data/libs/cuda-9.1/lib64/libnvrtc.so > -- CUDA include path : /data/libs/cuda-9.1/include > -- NVCC executable : /data/libs/cuda-9.1/bin/nvcc > -- CUDA host compiler : /tools/miniconda2/bin/gcc-5 > -- USE_TENSORRT : OFF > -- USE_EIGEN_FOR_BLAS : 1 > -- USE_FFMPEG : OFF > -- USE_GFLAGS : ON > -- USE_GLOG : ON > -- USE_GLOO : ON > -- USE_LEVELDB : OFF > -- USE_LITE_PROTO : OFF > -- USE_LMDB : ON > -- LMDB version : 0.9.21 > -- USE_METAL : OFF > -- USE_MKL : > -- USE_MOBILE_OPENGL : OFF > -- USE_MPI : OFF > -- USE_NCCL : ON > -- USE_NERVANA_GPU : OFF > -- USE_NNPACK : ON > -- USE_OBSERVERS : ON > -- USE_OPENCL : OFF > -- USE_OPENCV : ON > -- OpenCV version : 3.2.0 > -- USE_OPENMP : OFF > -- USE_PROF : OFF > -- USE_REDIS : OFF > -- USE_ROCKSDB : OFF > -- USE_ZMQ : OFF
module: crash,module: build,caffe2
low
Critical
318,412,982
TypeScript
Tooltip for function overloaded to mimic variadic types infers wrong overload when called with trailing comma
**TypeScript Version:** 2.7.0-dev.20180418 **Search Terms:** Intellisense overload, tooltip overload **Code** ```ts function test<A>(a: A): true; function test<A, B>(a: A, b: B): false; function test<T>(...values: T[]): boolean { return values.length === 1; } declare function assertTrue(truth: true): void; const noComma = test( // test<string>(a: string): true 'foo' ) assertTrue(noComma); const withComma = test( // test<string, {}>(a: string, b: {}): false, but withComma: true 'foo', ); assertTrue(withComma); assertTrue(test( // test<string, {}>(a: string, b: {}): false, but no error 'foo', )); ``` **Expected behavior:** The inferred version of `test` (as shown in hover-over tooltip) for `noComma`, `withComma`, and directly passed to `assertTrue` is the `test<A>(a: A): true` version. **Actual behavior:** The inferred version of `test` for the `withComma` and directly-passed versions is the `test<A, B>(a: A, b: B): false`, specifically `test<string, {}>(a: string, b: {}): false`. Despite this, `withComma` has type `true`, and no error is reported for the call to `assertTrue` with it or when directly passed. **Playground Link:** [here](http://www.typescriptlang.org/play/index.html#src=function%20test%3CA%3E(a%3A%20A)%3A%20true%3B%0D%0Afunction%20test%3CA%2C%20B%3E(a%3A%20A%2C%20b%3A%20B)%3A%20false%3B%0D%0Afunction%20test%3CT%3E(...values%3A%20T%5B%5D)%3A%20boolean%20%7B%0D%0A%20%20%20%20return%20values.length%20%3D%3D%3D%201%3B%0D%0A%7D%0D%0A%0D%0Adeclare%20function%20assertTrue(truth%3A%20true)%3A%20void%3B%0D%0A%0D%0Aconst%20noComma%20%3D%20test(%0D%0A%20%20%20%20'foo'%0D%0A)%0D%0AassertTrue(noComma)%3B%0D%0A%0D%0Aconst%20withComma%20%3D%20test(%0D%0A%20%20%20%20'foo'%2C%0D%0A)%3B%0D%0AassertTrue(withComma)%3B%0D%0A%0D%0AassertTrue(test(%0D%0A%20%20%20%20'foo'%2C%0D%0A))%3B%0D%0A) **Related Issues:** #7279
Bug,Help Wanted,Domain: Quick Info
low
Critical
318,432,238
vscode
Surface customized task proper in the API.
See https://github.com/Microsoft/vscode/issues/48831 for all the details. In the API the task should be the original provided task and it should contain a pointer to its customization from the tasks.json (not the other way around like it is today in the implementation).
api,tasks,debt
low
Minor
318,471,943
go
cmd/compile: eliminate more dead stores
### What version of Go are you using (`go version`)? Trunk go version devel +3470321 Tue Apr 24 15:26:21 2018 -0500 linux/amd64 ### What did you do? go build following program: ``` package test //go:noinline func f(x ...interface{}) { } func g() { var x string f(&x) } ``` When looking into generated code I see that autotmp_1 is zeroed and than immediately overwritten ``` v27 00003 (8) XORPS X0, X0 v7 00004 (8) MOVUPS X0, "".x-32(SP) v13 00005 (9) MOVUPS X0, ""..autotmp_1-16(SP) // zeroing v23 00006 (9) LEAQ type.*string(SB), AX v35 00007 (9) MOVQ AX, ""..autotmp_1-16(SP) // followed by 2 stores v34 00008 (9) LEAQ "".x-32(SP), AX v21 00009 (9) MOVQ AX, ""..autotmp_1-8(SP) v36 00010 (9) LEAQ ""..autotmp_1-16(SP), AX ``` dse pass already eliminates dead stores, including zeroing, so it should also handle this case.
Performance,binary-size,compiler/runtime
low
Major
318,487,852
go
x/mobile/cmd/gomobile: iOS app built with gomobile-build freezes after switching apps
### What version of Go are you using (`go version`)? ``` go version go1.10 darwin/amd64 ``` ### Does this issue reproduce with the latest release? Yes ### What operating system and processor architecture are you using (`go env`)? ``` GOARCH="amd64" GOBIN="" GOCACHE="/Users/hajimehoshi/Library/Caches/go-build" GOEXE="" GOHOSTARCH="amd64" GOHOSTOS="darwin" GOOS="darwin" GOPATH="/Users/hajimehoshi/go" GORACE="" GOROOT="/usr/local/go" GOTMPDIR="" GOTOOLDIR="/usr/local/go/pkg/tool/darwin_amd64" GCCGO="gccgo" CC="clang" CXX="clang++" CGO_ENABLED="1" CGO_CFLAGS="-g -O2" CGO_CPPFLAGS="" CGO_CXXFLAGS="-g -O2" CGO_FFLAGS="-g -O2" CGO_LDFLAGS="-g -O2" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/7t/qw3np69559591s1v0mk5_p1m0000gn/T/go-build572694656=/tmp/go-build -gno-record-gcc-switches -fno-common" ``` ### What did you do? 1. `gomobile build -target=ios -bundleid=com.hajimehoshi.gomobiletest -work golang.org/x/mobile/example/basic` 2. Open the Xcode project in the work directory 3. Fix the singing to be able to install the app 4. Install and run the 'basic' app 5. Try to switch to another app and go back to the basic app ### What did you expect to see? The app continues to run ### What did you see instead? The app freezes
mobile
low
Critical
318,496,141
pytorch
CuDNN version not supported
My OS is ubuntu 16.04, previously installed cuda-8.0 and cudnn-5. Now I want to install the latest PyTorch and I choose to install with souce code. I made some preparetions: install cuda-9.0 and cudnn-7 set these env-variables in my ~/.bashrc: `export CUDNN_include_DIR=/usr/local/cuda-9.0/include export PATH=/usr/local/cuda-9.0/bin:$PATH export LD_LIB_PATH=/usr/local/cuda-9.0/lib64:$LD_LIB_PATH` I have tried many ways: `export C_INCLUDE_PATH=/usr/local/cuda-9.0/include:$C_INCLUDE_PATH export CPLUS_INCLUDE_PATH=/usr/local/cuda-9.0/include:$CPLUS_INCLUDE_PATH` However, it still comes with error: cudnn v5. How can I solve it? Many others have to use old versions, so remove cudnn 5 is my last choice.
todo,module: build,module: cudnn,module: cuda,triaged
low
Critical
318,529,998
pytorch
"Undefined symbols for architecture arm64" when linking libcaffe2.a for iOS
## Issue description I am linking the caffe2 library to my iOS project using the built libraries after compiling for iOS and I'm getting "Apple Mach-O Linker errors, with all of them being "undefined symbols for architecture arm64" ## System Info - PyTorch or Caffe2: Caffe2 - How you installed PyTorch (conda, pip, source): source - Build command you used (if compiling from source): ./scripts/build_ios.sh - OS: iOS - PyTorch version: master - Python version: 3.6.4 - CUDA/cuDNN version: NA - GPU models and configuration: NA - GCC version (if compiling from source): Apple LLVM version 9.1.0 (clang-902.0.39.1) - CMake version: 3.11.1 - Versions of any other relevant libraries:
caffe2
low
Critical
318,586,795
pytorch
[feature request] Provide Caffe2 CUDA dockerfile with USE_REDIS=ON
It seems the Redis operator support in Caffe2 is off by default. When I compiled the source code with the option USE_REDIS=ON using [this dockerfile](https://github.com/pytorch/pytorch/blob/master/docker/caffe2/ubuntu-16.04-cuda8-cudnn6-all-options/Dockerfile), I ended up with an error complaining about being unable to find libhiredis.so. After some debugging, it turns out that the base image nvidia/cuda:8.0-cudnn6-devel-ubuntu16.04 has set the environment variable LIBRARY_PATH already while hiredis relies on it to install the generated libhiredis.so correctly. root@e7530e488c01:/# echo $LIBRARY_PATH /usr/local/cuda/lib64/stubs: To get around this issue, I simply reset it to lib as below in my dockerfile. ENV LIBRARY_PATH lib I think it will be helpful to put a comment on this in the dockerfile just in case anyone else gets stuck with the same error.
caffe2
low
Critical
318,604,931
pytorch
LBFGS contribution
LBFGS implementation is not proper. Could you please go through the following link and respond to this? https://discuss.pytorch.org/t/lbfgs-not-functioning-the-way-it-is/16705 I would like to contribute for this algorithm. Could you please respond soon? cc @vincentqb
awaiting response (this tag is deprecated),module: optimizer,triaged
low
Major
318,606,494
rust
Tracking issue for eRFC 2318, Custom test frameworks
This is tracking the `#[bench]` and `#[test_case]` attributes and the `custom_test_frameworks` lang item as well as the libtest crate. There is currently no plan/RFC for stabilizing them. **Old issue description.** <details> This is a tracking issue for the eRFC "Custom test frameworks" (rust-lang/rfcs#2318). **Documentation:** * Implementation proposal: https://www.jrenner.net/rust/testing/2018/08/06/custom-test-framework-prop.html * https://doc.rust-lang.org/nightly/unstable-book/language-features/custom-test-frameworks.html **Steps:** - [ ] Implement the RFC (cc @rust-lang/dev-tools @rust-lang/cargo -- can anyone write up mentoring instructions?) - [ ] Adjust documentation ([see instructions on forge][doc-guide]) - [ ] Stabilization PR ([see instructions on forge][stabilization-guide]) [stabilization-guide]: https://forge.rust-lang.org/stabilization-guide.html [doc-guide]: https://forge.rust-lang.org/stabilization-guide.html#updating-documentation **Unresolved questions:** - [ ] [Integration with doctests](https://github.com/rust-lang/rfcs/blob/master/text/2318-custom-test-frameworks.md#integration-with-doctests) - [ ] [Standardizing the output](https://github.com/rust-lang/rfcs/blob/master/text/2318-custom-test-frameworks.md#standardizing-the-output-1) - [ ] [Namespacing](https://github.com/rust-lang/rfcs/blob/master/text/2318-custom-test-frameworks.md#namespacing) - [ ] [Runtime dependencies and flags](https://github.com/rust-lang/rfcs/blob/master/text/2318-custom-test-frameworks.md#runtime-dependencies-and-flags) - [ ] [Naming](https://github.com/rust-lang/rfcs/blob/master/text/2318-custom-test-frameworks.md#naming) - [ ] [Bencher](https://github.com/rust-lang/rfcs/blob/master/text/2318-custom-test-frameworks.md#bencher) - [ ] [Cargo integration](https://github.com/rust-lang/rfcs/blob/master/text/2318-custom-test-frameworks.md#cargo-integration) **Notes:** - Destabilization of `#[bench]`: https://github.com/rust-lang/rust/issues/63798#issuecomment-526593504 **Implementation history:** * Initial implementation: #53410 </details>
B-RFC-approved,T-lang,T-dev-tools,T-cargo,A-libtest,C-tracking-issue,WG-embedded,F-custom_test_frameworks,S-tracking-design-concerns
high
Critical
318,616,538
go
brand: presentation theme: black background for source code is a problem
Please look at [this slide](https://docs.google.com/presentation/d/1Gib9XvcWW_FG9QT_5egNigJX9By7LFEpe69eu37k5Us/edit#slide=id.g33148270ac_0_429). While black background looks cool on the electronic displays (computers, TVs), and at the large conference screens in the dark environment, it will not work with typical equipment found at the meetup sites – projectors and white screens: they can't project black on the white screen, and switching off the lights and closing the curtains is not always possible (and also typically lead to tired gophers to snore). I propose to add another template with the light background. /cc @spf13
Documentation,NeedsFix
low
Major
318,617,723
TypeScript
Verbose computed property transpilation
**TypeScript Version:** 2.7.0-dev.201xxxxx <!-- Search terms you tried before logging this (so others can find this issue more easily) --> **Search Terms:** **Code** ```ts const p1 = 0; const p2 = 1; class A { [p1] = 0; [p2]() {} } ``` **Expected behavior:** ```js const p1 = 0; const p2 = 1; class A { constructor() { this[p1] = 0; } [p2]() { } } ``` **Actual behavior:** ```js const p1 = 0; const p2 = 1; class A { constructor() { this[_a] = 0; } [(_a = p1, p2)]() { } } var _a; ``` **Playground Link:** <!-- A link to a TypeScript Playground "Share" link which demonstrates this behavior --> **Related Issues:**
Suggestion,Help Wanted,Domain: Transforms
low
Major
318,648,888
go
x/mobile/cmd/gomobile: iOS app built with gomobile-build consumes memory and never frees
### What version of Go are you using (`go version`)? ``` go version go1.10 darwin/amd64 ``` ### Does this issue reproduce with the latest release? Yes ### What operating system and processor architecture are you using (`go env`)? ``` GOARCH="amd64" GOBIN="" GOCACHE="/Users/hajimehoshi/Library/Caches/go-build" GOEXE="" GOHOSTARCH="amd64" GOHOSTOS="darwin" GOOS="darwin" GOPATH="/Users/hajimehoshi/go" GORACE="" GOROOT="/usr/local/go" GOTMPDIR="" GOTOOLDIR="/usr/local/go/pkg/tool/darwin_amd64" GCCGO="gccgo" CC="clang" CXX="clang++" CGO_ENABLED="1" CGO_CFLAGS="-g -O2" CGO_CPPFLAGS="" CGO_CXXFLAGS="-g -O2" CGO_FFLAGS="-g -O2" CGO_LDFLAGS="-g -O2" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -m64 -pthread -fno-caret-diagnostics -Qunused-arguments -fmessage-length=0 -fdebug-prefix-map=/var/folders/7t/qw3np69559591s1v0mk5_p1m0000gn/T/go-build916245002=/tmp/go-build -gno-record-gcc-switches -fno-common" ``` ### What did you do? 1. Run `gomobile build -target=ios -bundleid=com.hajimehoshi.gomobiletest -work golang.org/x/mobile/example/basic` 2. Open the generated `main.xcodeproj` 3. Install it on a device (iPhone 6 in my case) 4. Run the app via Instruments memory profiler (Zombie) ### What did you expect to see? The app runs without memory increase. ### What did you see instead? The memory usage is increased monotonically: [![Screenshot from Gyazo](https://gyazo.com/63bfab74bebcc3a74e063076a47a7cb5/raw)](https://gyazo.com/63bfab74bebcc3a74e063076a47a7cb5) It looks like `_IOAccelResourceAlloc` allocates memory and it is never disposed? I'm not sure this is an actual leak.
mobile
low
Critical
318,653,741
go
fmt: State could be a little friendlier
### What version of Go are you using (`go version`)? 1.10 ### Does this issue reproduce with the latest release? yes. ### What operating system and processor architecture are you using (`go env`)? linux/amd64, but seems irrelevant ### What did you do? Tried to use Formatter efficiently. https://play.golang.org/p/sHI8UPe_f98 ### What did you expect to see? I don't honestly know. I was hoping for a reasonably straightforward way to express "use this format string for several things that I wish to format". ### What did you see instead? See playground example. In this specific use case, a fair bit of what I want could be accomplished much more easily if fmt.State had a member `Format []bytes` such that fmt.Sprintf(s.Format, value) would replicate the format specifier that created the fmt.State. (But with, for instance, a * width or precision already baked in.) It also almost feels like fmt.State arguments could be used with Printf, etc., as a sort of meta-specifier. Consider a hypothetical %S format specifier, which consumes two arguments, the first being a fmt.State and the second being a value. So, once you *have* a format.State which specifies a given width/precision/flags, you could do something like: `fmt.Fprintf(s, "[%S, %S, %S]", s, x0, s, x1, s, x2)` (There's an interesting line of inquiry with casting the members to a type that has a custom formatting function, but because you can't nest functions, you can't declare the type and its formatter inside the Format() function for the containing type, and if the formatter is outside it, you can't have different goroutines simultaneously printing objects using different formats.) (It might also be useful to mention explicitly in the fmt docs that Formatter can be used with arbitrary runes, as long as they're not %, T, or v.)
NeedsInvestigation,FeatureRequest
low
Major
318,677,570
go
x/sys/windows: port CL 106275 into x/sys/windows
@aclements said https://github.com/golang/go/issues/21376#issuecomment-382445433 > we could even move all of the crypto APIs from syscall to internal/syscall/windows and tell people to use x/sys/windows instead (which we also need to fix). This issue is so we do not forget to fix crypto APIs in x/sys/windows. Austin, lets also decide if we want to remove broken crypto APIs and how we will decide which ones to remove before go1.11 is released. So we don't make breaking changes in syscall twice. Maybe not in this issue. Thank you. Alex
compiler/runtime
low
Critical
318,687,334
go
encoding/json: include property name for marshal errors
### What version of Go are you using (`go version`)? ``` $ go version go version go1.10 linux/amd64 ``` ### Does this issue reproduce with the latest release? Yes ### What operating system and processor architecture are you using (`go env`)? ``` $ go env GOARCH="amd64" GOBIN="" GOCACHE="/home/dominic/.cache/go-build" GOEXE="" GOHOSTARCH="amd64" GOHOSTOS="linux" GOOS="linux" GOPATH="/home/dominic/dev" GORACE="" GOROOT="/usr/lib/go-1.10" GOTMPDIR="" GOTOOLDIR="/usr/lib/go-1.10/pkg/tool/linux_amd64" GCCGO="gccgo" CC="gcc" CXX="g++" CGO_ENABLED="1" CGO_CFLAGS="-g -O2" CGO_CPPFLAGS="" CGO_CXXFLAGS="-g -O2" CGO_FFLAGS="-g -O2" CGO_LDFLAGS="-g -O2" PKG_CONFIG="pkg-config" GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build203824871=/tmp/go-build -gno-record-gcc-switches" ``` ### What did you do? When encountering an error using `json.Marshal()` (and related functions) the error returned gives no indication where the error was encountered. The only included metadata is about the type of the value that was being encoded, but that is usually insufficient to narrow down problems without the original input value. (which may not always be at hand) ### What is being proposed? The proposal would be to add the property name for marshal errors (using dot notation to signify hierarchy). For example: > json: error calling MarshalJSON for type time.Time: Time.MarshalJSON: year outside of range [0,9999] would be updated to be more specific: > json: error calling MarshalJSON for timestamp (type time.Time): Time.MarshalJSON: year outside of range [0,9999] and in the case of a more complex/nested data structure: > json: error calling MarshalJSON for events.[0].timestamp (type time.Time): Time.MarshalJSON: year outside of range [0,9999] ### Why is this useful? I use Go to do a lot of data processing, which is generally from 3rd-parties (aka: customers) so the structure of data is not usually known ahead of time, not to mention weird values being sent due to programming errors and a host of other problems. Last week, I encountered the first error message above and needed to do some extra work just to determine which property was causing the error, when the encoder should be able to communicate that to the caller.
NeedsInvestigation
low
Critical
318,688,787
go
cmd/compile: emit variable byte-sized bit tests on amd64
Conversation moved from CL 109716. Consider this code from the runtime: ```go // Information from the compiler about the layout of stack frames. type bitvector struct { n int32 // # of bits bytedata *uint8 } // ptrbit returns the i'th bit in bv. func (bv *bitvector) ptrbit(i uintptr) uint8 { b := *(addb(bv.bytedata, i/8)) return (b >> (i % 8)) & 1 } ``` ptrbit should generate a BTL instruction on amd64, but instead it generates RSH and AND. (Related work: CL 105037.) IIRC, we intentionally don't generate BTL instructions for constant-offset bit tests for bytes, since the equivalent TEST instruction is shorter or faster. cc @rasky
Performance,compiler/runtime
low
Minor
318,693,558
pytorch
Fail to import Caffe2Backend
## Issue description After install Caffe2 from its source following the instruction on a clean VM (CPU only), I can run this [example](https://github.com/caffe2/tutorials/blob/master/Toy_Regression.ipynb). However, the following line produces an error. home:~/repos/pytorch/build$ python Python 2.7.14 (default, Sep 23 2017, 22:06:14) [GCC 7.2.0] on linux2 Type "help", "copyright", "credits" or "license" for more information. >>> from caffe2.python.onnx.backend import Caffe2Backend WARNING:root:This caffe2 python run does not have GPU support. Will run in CPU only mode. WARNING:root:Debug message: No module named caffe2_pybind11_state_gpu Segmentation fault (core dumped) ## System Info - PyTorch or Caffe2: Caffe2 - How you installed PyTorch (conda, pip, source): - Build command you used (if compiling from source): source - OS: Ubuntu - PyTorch version: - Python version: 2.7 - CUDA/cuDNN version: NO GPU - GPU models and configuration: - GCC version (if compiling from source): 7.2.0 - CMake version: 3.9.1 - Versions of any other relevant libraries:
caffe2
low
Critical
318,721,365
react
onMouseDown causes splash on real ios browsers
<!-- Note: if the issue is about documentation or the website, please file it at: https://github.com/reactjs/reactjs.org/issues/new --> **Do you want to request a *feature* or report a *bug*?** *bug* **What is the current behavior?** unexpected **grey splash** caused by `onMouseDown` on real ios device's browsers, both safari and chrome. [Please checkout this **grey splash** issue first](https://github.com/mui-org/material-ui/issues/11154) I did some trial later, and find out that vanilla html `<button onmousedown="">btn</button>` doesn't cause **grey splash**, but with React's jsx `<button onMouseDown={()=>{}}></button>`, there is a noticeable **grey splash** **What is the expected behavior?** who wants a splash? **Which versions of React, and which browser / OS are affected by this issue? Did this work in previous versions of React?** "react": "^16.3.2"
Type: Bug,Browser: Safari,Component: DOM
low
Critical
318,728,269
go
cmd/compile: use bounded shift information on non-amd64 architectures
CL 109776 optimized some shifts on amd64. We should apply the same straightforward optimization rule changes to other architectures. Might be a good starter SSA issue. cc @mundaym @cherrymui
Suggested,Performance,help wanted,compiler/runtime
low
Major
318,728,428
go
cmd/compile: detect bounded shifts in generic rules
CL 109776 introduced a mechanism for marking a shift value as being bounded, and used it in the prove pass. @mundaym suggested marking others during generic optimization rule application. This issue is a reminder to follow up on that suggestion. cc @rasky @mundaym
Performance,compiler/runtime
low
Minor
318,728,588
go
cmd/compile: detect bounded shifts of the form (bits-var) in prove
This is a reminder issue for a suggestion in the review of CL 109776: https://go-review.googlesource.com/c/go/+/109776/1/src/cmd/compile/internal/ssa/prove.go#797.
Performance,compiler/runtime
low
Minor
318,738,884
rust
Specialization: assigning associated type in default trait implementation leads typecheck to fail with weird error
I have a trait `NodeTrait` that I implemented for `Node` with a default implementation and a specialized one. The trait has an associated type `Item`. If I assign the type of `Item` in the specialized implementation, everything works. If I specify it in the default implementation, I get a weird type check error. here is the code ([playground](https://play.rust-lang.org/?gist=e2e5a88851eeb52b576d7113a586d906&version=nightly&mode=debug)) ```rust #![feature(specialization)] use std::marker::PhantomData; struct Node<T>(PhantomData<T>); struct Foo; trait NodeTrait { type Item; fn foo(&self, a: Self::Item); fn bar(); } default impl<T> NodeTrait for Node<T> { type Item = u32; // if you comment this one default fn foo(&self, a: Self::Item) { } } impl NodeTrait for Node<Foo> { //type Item = u32; // and uncomment this one, it works fn bar(){} } fn main() { let a = Node::<Foo>(PhantomData); a.foo(0u32); } ``` and the error ``` 27 | a.foo(0u32); | ^^^^ expected associated type, found u32 | = note: expected type `<Node<Foo> as NodeTrait>::Item` found type `u32` ``` FYI, my understanding of specialization is still very light, it might be expected behavior and not a bug.
T-lang,A-specialization,A-inference,C-bug,requires-nightly,F-specialization
low
Critical
318,753,904
rust
Linking dylib with "lto = true": assertion failed: !is_full_lto_enabled(sess)
Approximate file tree: ``` ├── Cargo.lock ├── Cargo.toml ├── src │   └── main.rs └── test_dylib    ├── Cargo.toml    └── lib.rs ``` Top-level Cargo.lock: ``` [profile.release] lto = true [dependencies] test_dylib = { path = "test_dylib" } ``` test_dylib/Cargo.toml: ``` [lib] path = "lib.rs" crate-type = ["dylib"] [profile.release] lto = true ``` Snippet of output from `RUST_BACKTRACE=1 cargo build --release --verbose`: ``` Running `rustc --crate-name test_package src/main.rs --crate-type bin --emit=dep-info,link -C opt-level=3 -C lto -C metadata=7e778ca5edc7bd6e -C extra-filename=-7e778ca5edc7bd6e --out-dir /src/test_package/target/release/deps -L dependency=/src/test_package/target/release/deps --extern test_dylib=/src/test_package/target/release/deps/libtest_dylib.so -L native=/src/test_package/target/release/build/ring-9d649aa185d933e6/out` thread 'rustc' panicked at 'assertion failed: !is_full_lto_enabled(sess)', librustc_trans/back/link.rs:1318:9 note: Some details are omitted, run with `RUST_BACKTRACE=full` for a verbose backtrace. stack backtrace: 0: std::sys::unix::backtrace::tracing::imp::unwind_backtrace at libstd/sys/unix/backtrace/tracing/gcc_s.rs:49 1: std::sys_common::backtrace::_print at libstd/sys_common/backtrace.rs:71 2: std::panicking::default_hook::{{closure}} at libstd/sys_common/backtrace.rs:59 at libstd/panicking.rs:380 3: std::panicking::default_hook at libstd/panicking.rs:396 4: std::panicking::rust_panic_with_hook at libstd/panicking.rs:576 5: std::panicking::begin_panic 6: rustc_trans::back::link::link_args 7: rustc_trans::back::link::link_natively 8: <rustc_trans::LlvmTransCrate as rustc_trans_utils::trans_crate::TransCrate>::join_trans_and_link::{{closure}} 9: <rustc_trans::LlvmTransCrate as rustc_trans_utils::trans_crate::TransCrate>::join_trans_and_link 10: rustc_driver::driver::compile_input 11: rustc_driver::run_compiler error: internal compiler error: unexpected panic note: the compiler unexpectedly panicked. this is a bug. note: we would appreciate a bug report: https://github.com/rust-lang/rust/blob/master/CONTRIBUTING.md#bug-reports note: rustc 1.25.0 (84203cac6 2018-03-25) running on x86_64-unknown-linux-gnu error: Could not compile `test_package`. Caused by: process didn't exit successfully: `rustc --crate-name test_package src/main.rs --crate-type bin --emit=dep-info,link -C opt-level=3 -C lto -C metadata=7e778ca5edc7bd6e -C extra-filename=-7e778ca5edc7bd6e --out-dir /src/test_package/target/release/deps -L dependency=/src/test_package/target/release/deps --extern test_dylib=/src/test_package/target/release/deps/libtest_dylib.so -L native=/src/test_package/target/release/build/ring-9d649aa185d933e6/out` (exit code: 101) ```
A-linkage,I-ICE,T-compiler,C-bug
low
Critical
318,806,945
TypeScript
Cannot use variable from common deconstruction into the initialising expression of another one when strictNullChecks is on
**TypeScript Version:** 2.8.3 <!-- Search terms you tried before logging this (so others can find this issue more easily) --> **Search Terms:** - deconstruction with initialzers - strictNullCheck **Code** If I use `tsc --strictNullChecks` I will get the following errors ```ts // strictNullCheck should be enabled // deconstruction of an array const arr: number[] = [1]; const [a, b = a] = arr; // Variable 'a' is used before being assigned. // deconstruction of an object const obj: { x: number, y?: number } = { x: 1 }; const { x, y = x } = obj; // Variable 'x' is used before being assigned. ``` **Expected behavior:** No errors as in the case when strictNullChecks is off. **Actual behavior:** The compiler raises the errors about unassigned variables using in initialising expressions. **Playground Link:** [demo code](https://www.typescriptlang.org/play/index.html#src=%2F%2F%20strictNullCheck%20should%20be%20enabled%0D%0A%0D%0A%2F%2F%20deconstruction%20of%20an%20array%0D%0Aconst%20arr%3A%20number%5B%5D%20%3D%20%5B1%5D%3B%0D%0Aconst%20%5Ba%2C%20b%20%3D%20a%5D%20%3D%20arr%3B%20%2F%2F%20Variable%20'a'%20is%20used%20before%20being%20assigned.%0D%0A%0D%0A%2F%2F%20deconstruction%20of%20an%20object%0D%0Aconst%20obj%3A%20%7B%20x%3A%20number%2C%20y%3F%3A%20number%20%7D%20%3D%20%7B%20x%3A%201%20%7D%3B%0D%0Aconst%20%7B%20x%2C%20y%20%3D%20x%20%7D%20%3D%20obj%3B%20%2F%2F%20Variable%20'x'%20is%20used%20before%20being%20assigned.%0D%0A) - `strictNullChecks` should be enabled
Bug
low
Critical