[SPARK-20422][Spark Core] Worker registration retries should be configurable

What changes were proposed in this pull request?
make prolonged registration retries configurable
How was this patch tested?
unit tests, integration tests

Can one of the admins verify this patch?

Could someone take a look?

This is a minor change which will help in configuring registration retries. It can be merged.

Could you expand more on the senerio you are changing this? Thank you!

We are closing it due to inactivity. please do reopen if you want to push it forward. Thanks!


Cleanup imageruler codebase

This PR is a first step at cleaning up the imageruler codebase. Summary of changes:

Apply common formatting to the primary modules
Add missing type hints and fix inconsistencies
Clean up docstrings
Remove unecessary docstrings on private functions
Add a padding mode enum

Overall, this is just a starting point. There is still a lot of ambiguity in some of the docstrings around default values and expected behaviors, e.g. what happens when phys_size is not specified

LGTM.


Cardano Indonesia Meeting #33: 12 September 2022 until 18 September 2022

Cardano Indonesia Meeting: 12 September 2022 until 18 September 2022

Last Meeting - #58
Next Meeting - #60

Attendees:
Andreas Sosilo (@andreassosilo)
Andre Cahyadi (@andrecahyadi)
Caliburn (@CryptoCaliburn)
Fanny Wijaya (@Fny-ETH)
Gorga Siagian (@gorgagian123)
Ivan Kwananda (@ivankwan88)
Jordy Vincent (@jordyvincent)
Xavier Daniswara (@syarbel)
Antria Dwi Lestari (TKO)
Dimas Surya Alfaruq (TKO)
Apologies:
Andy Sibuea (@zicozibu)
Dani Ihza Farrosi (@danivideda)
Dion Setyotomo (@dionsetyotomo)
Felix (Pamankripto)
Yan Tirta (@YanTirta)
Dewi Gunarto
Handoko Wiyanto
Pending Tasks

@andreassosilo needs to upload all of the remaining Zoom recording + intro + end screen for YouTube to @YanTirta
@YanTirta : combine the intro + recording + end screen + upload to YouTube channel "Komunitas Cardano Indonesia"

Meeting Topics
1. Eastern Town Hall Indonesia

Next meetup: Saturday, 24 September 2022 @ 09:00-11:00 UTC
Topic: Voting Fund 9 & preparation for Fund 10

2. Eastern Catalyst School Indonesia

We will submit our own proposal in Fund 10 for funding Catalyst School Indonesia in Fund 11 & Fund 12
Check the list of issue & work for project management in Fund 9 for payment -> @andreassosilo
Preparation for 7th workshop and 1-on-1 session in Fund 10 (October 2022) -> pending until Fund 10 start
ECS Indo doesn't have budget for 1-on-1 session in Fund 10 -> Vietnam & Indonesia will ask Yuta-san from Japan to get some of Japanese Team budget in Fund 9 that is not used -> @YanTirta will ask Yuta
Eastern Catalyst School Indonesia Wallet : $indonesia.ecs managed by @danivideda @syarbel @zicozibu

3. Gimbalabs x EBU x Eastern Catalyst School : "Train the Trainer"

3rd workshop will be given on Saturday, 24 September 2022 by Sebastian Pabon
Syllabus is ready -> using PPBL ver. 2.0
6 weeks for learning Plutus, bi-weekly after Eastern Town Hall meetup
Free
Langkah awalnya adalah mengadakan Kelas PPBL (Plutus Project Based Learning atau Pembelajaran Plutus Melalui Project) tiap hari Sabtu jam 18:00 sampai 20:00 sebanyak 6 sesi mulai 2 minggu kedepan atau sesi ETH berikutnya
6 sesi ini akan kita pakai sebagai basis proof of concept di dalam proposal yg sedang kita ciptakan
Dari proposal ini -diantara sekian goal- salah satunya akan muncul Gimbalabs : Eastern Chapter (Fund 11)
In Fund 10, @YanTirta will submit proposal Gimbalabs: Train The Trainer to pay the activities

4. Catalyst Incubator

Catalyst Incubator is an effort to structure all Eastern Town Hall programs (Eastern Catalyst School, bi-weekly meetup itself)
All existing programs will be integrated in Catalyst Incubator. Therefore, there will be minimum additional effort
There are only 2 additional effort. Weekly Zoom meeting on Saturday. If the proposers requested, we will provide support also via chat in Telegram Group channel, especially for Catalyst Incubator participants
Main target is new proposer and those who do not speak/write English properly
Business model: referrer goes to Eastern Town Hall. But for direct individual who create the proposal can request "x" number of USD in project management budget
We need to have each countries breakout room for Catalyst Incubator (Japanese, Vietnam, Indonesia)

5. Leads Generation from Eastern Town Hall x Cardano 4 Climate

Cardano 4 Climate (C4C) will give presentation in the next Eastern Town Hall meetup

6. Social Engagement

Collected data "Cardano Indonesia Social Media Growth" - created by @dionsetyotomo
Input by: @andreassosilo
Telegram Cardano Indonesia

Need to do the transition from Shieldy bot to the Rose bot -> maybe we can combined both of them, because we need Shieldy for better spam protection
Do regular update for the single Google Docs for the message for each command that can be updated by every administrator by @andrecahyadi

Instagram Cardano Indonesia

@Fny-ETH & @CryptoCaliburn have access to Cardano Indonesia Instagram account
To share information, please contact @Fny-ETH or @CryptoCaliburn to post/share it in Instagram account

7. Proposal from Cardano Indonesia Community in Catalyst Fund 9

AMA Cross-chain Collaboration - ⭐4.67

Submitted by Ivan Kwananda & @andreassosilo
Link: https://cardano.ideascale.com/c/idea/416801

Brief educational video in Bahasa - ⭐3.95

Submitted by Andre Elausta
Link: https://cardano.ideascale.com/c/idea/417366

Financial Implementation Blockchain - ⭐3.47

Submitted by Fanny Wijaya
Link: https://cardano.ideascale.com/c/idea/416344

Ads Platform SSP & DSP with Cardano - ⭐1.95

Submitted by Lutvi Rosyady
Link: https://cardano.ideascale.com/c/idea/417704

Web ADA Info Community In Bahasa - ⭐3.33

Submitted by Gorga Siagian
Link: https://cardano.ideascale.com/c/idea/418728

Trust & Transparent News Portal - ⭐2.47

Submitted by Sonny Dhamayana
Link: https://cardano.ideascale.com/c/idea/420823

Blockchain for Contracts: Indonesia - ⭐4.00

Submitted by SmartChain, Digisign, PT Trimitra Bisnis Solusi
Link: https://cardano.ideascale.com/c/idea/419564

8. Collaboration

AMA Cardano Indonesia x Tokocrypto (TKO utility token)

Collaboration AMA via Zoom online
Discussion between @dionsetyotomo & @syarbel with Ms. Antria from TKO
We need to give slot time options: Sunday, 18 September 2022 -> integrated with Cardano Indonesia workshop
Speaker: @dionsetyotomo & Antria from TKO
@syarbel : need to discuss with TKO, when will they host the event from their side (TBD) -> waiting for the date from Antria TKO

Cardano Indonesia x Triv Indonesia: Goes to Campus

@YanTirta will coordinate with Triv Indonesia
Coordination will be starting in mid of August 2022
Event: approximately October or November 2022

9. Cardano Hub Surabaya

Meetup Group Cardano Blockchain Surabaya
Planning once a month offline meetup in Bare Coffee, Surabaya
August 2022 meetup recap by @Fny-ETH
Next Meetup event in September 2022: sharing from CNFTID on Sunday, 25 September 2022
@andreassosilo will nominate @CryptoCaliburn as Cardano Ambassador Meetup Organizer for Cardano Hub Surabaya
In Fund 10, @ivankwan88 & @Fny-ETH (proposer & co-proposer) + supported by Cardano Indonesia. Proposal: "Cardano Hub Surabaya" -> need to discuss regarding the budget breakdown & activities for 3 months
@andreassosilo needs the link for Google Docs for the proposal draft -> by @ivankwan88 @Fny-ETH @CryptoCaliburn

10. Cardano Hub Yogyakarta

Cardano Hub Yogyakarta -> @YanTirta together with Lutvi Rosyady -> build developer hub using PPBL (plutus project-based learning) system -> topic about gaming

11. Cardano Summit 2022 Jakarta

@andreassosilo is chosen as host for Cardano Summit 2022 Jakarta
Budget roughly 3000-5000 USD
Cardano Summit 2022 (Swiss) will be held from 19-21 November 2022
Plan:

Friday, 18 Nov 2022: Zoom Cardano Summit 2022 Jakarta hosted by EMURGO Indonesia from 19:00-22:00 (3 hours)
Saturday, 19 Nov 2022: Gathering Cardano Indonesia in Jakarta - offline (from 16:00-18:00 WIB)
Sunday-Monday (20-21 Nov 2022): Meetup together in the metaverse (Cardano Summit 2022 Global) - online

Need to ask EMURGO Indonesia if they will create an event for Cardano Summit 2022 Jakarta by @zicozibu
Another option: to have a self-funded event, need some venue space options: co-working spaces, restaurants with min budget around 100k-150k/person
Task link: https://github.com/cardano-indonesia/cardano-indonesia-operations/issues/57
@Fny-ETH : ask for merchandise (cap) price
@andrecahyadi : need more explanation regarding the space in CityWalk Sudirman

12. Cardano Indonesia Community Monthly Digest (September 2022)

@andreassosilo will create the digest at the end of the month

13. Funded Proposals Progress Report
a. Cardano Hub Indonesia - Workshops

Waiting for September fund for IOG
@andreassosilo submitted the monthly KPI report for August 2022 (DONE)
Next workshop:  Sunday, 04 September 2022 at 19:00-21:00 WIB
@andreassosilo will create Meetup event
@YanTirta will create flyer
Topic: "AMA Cross-Chain Collaboration with TKO in Binance Smart Chain"
Speaker: @dionsetyotomo from Cardano Indonesia & Antria from TKO
Host: @andreassosilo
Co-Host: @andrecahyadi
Reward: 2x 10 ADA + 2x (NFT + 2 ADA) -> already sent to $cardano_id by @andreassosilo , verified by @andrecahyadi
Next Workshops' schedule:

18 September 2022: AMA Collaboration with TKO
02 October 2022: "How to setup stake pool in Cardano" by Andrew Ponto
16 October 2022: Cardano Ecosystem October 2022
13 November 2022: Marlowe
27 November 2022: Cardano Ecosystem November 2022

Cardano Indonesia will be lead by @ivankwan88 @Fny-ETH (proposer & co-proposer) -> accounting @Fny-ETH , lead @ivankwan88 & @andreassosilo , supported by all Cardano Indonesia team member

b. DID for Cardano Indonesia Community

Target: implementation in testnet ASAP, in mainnet before Cardano Summit 2023
Received August fund from Team Catalyst IOG
@andreassosilo needs to submit the monthly KPI report for August 2022 (deadline by 24 August 2022)
Read DID schema from https://github.com/roots-id/vc-schema-catalog
Learn about WAL-CLI -> needs to be read and tested
Watch YouTube demo for WAL-CLI
Follow up discussion with  Atala PRISM IOG UX Designer, Ilona Olejnik & RootsID Team Lance Byrd
Creating mockup for Cardano Indonesia Membership & Workshop Certificate Verifiable Credential
@danivideda will join the 3rd cohort of the Atala PRISM Pioneer Program
@andreassosilo joined the meeting on Wednesday, 10 August 2022 in Catalyst Town Hall breakout room for Atala PRISM/Educational VC
Check ProofSpace -> another alternative for Atala PRISM wallet with a dashboard to issue VC
Read ProofScape Documentation
Contact Allison Fromm regarding her funded proposal issuing VC for PA in Fund 10

c. Community Web Portal in Bahasa

Link website: https://www.adakita.xyz/ (Live)
Waiting for close-out report -> will be submitted in September 2022 by @dionsetyotomo

13. Book Translation to the Indonesian language: Cardano For The Masses

@syarbel contacted John Greene if he is interested to translate the book into the Indonesian language
Meeting via Zoom on Tuesday, 23 August 2022 -> John Greene x Cardano Indonesia
ISBN
Publishing
Minting via NMKR
How to sell the book via Book Token platform
Cardano Indonesia would like to submit proposal in Fund 10 (Oct-Dec'22) -> get fund in Jan'23 if funded
2nd version will be released by John Greene in Nov/Dec '22
Proof reading for translation? Hire professional?
Publisher from Yogyakarta, incl. proof reading & printing 20 copies -> pricing
Proposal Team Lead @syarbel , will be supported by Cardano Indonesia Core Team
Need to discuss:

isbn bs diprovide atau gak dari booktoken? sekalian dia nanya booktoken jg klo ada versi indonesia yg mau dipublish disitu gmn? (kyknya ini gak masalah)
diskusi royalty mau di angka berapa
yg di kita, klo mau urus isbn sendiri, persyaratan repot, that's why perlu nebeng di publisher

Done. Closed.


bump sql-parser 0.25

Which issue does this PR close?

Closes https://github.com/apache/arrow-datafusion/pull/3697
Rationale for this change

What changes are included in this PR?

Are there any user-facing changes?

cc @waitingkuo

The CI is failing with

failures:

---- datasource::file_format::parquet::tests::test_read_parquet_page_index stdout ----
thread 'datasource::file_format::parquet::tests::test_read_parquet_page_index' panicked at 'called `Result::unwrap()` on an `Err` value: Os { code: 2, kind: NotFound, message: "The system cannot find the file specified." }', datafusion\core\src\datasource\file_format\parquet.rs:1139:43
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

It looks like this PR inadvertently has some changes to the submodules like parquet-testing

I took the liberty of reverting the submodule pins in https://github.com/apache/arrow-datafusion/pull/3698/commits/180e56712be6f2587e79a7e2de5d0518649ce0d5

i fired a ticket for this #3715


How to display smaller window in raspberry pi ?

Hi,
I have created a gui menu for raspberry pi 3 using raylib running on Raspbian Stretch Lite . Whatever height and width I set in  InitWindow function. Gui window takes up the whole screen. I want to display the window, smaller in size.
e.g.  on  setting width as 600 & height as 300,  I get this output :
INFO: UPSCALING: Required screen size: 600 x 300 -> Display size: 1360 x 768
INFO: Display device initialized successfully
INFO: Display size: 1360 x 768
INFO: Render size: 600 x 339
INFO: Screen size: 600 x 300

Please guide me.
Thanks & Regards

If you're running your program in native mode (no XWindow), I'm afraid that's not possible.


Android version

First of all, thank you for doing this! It has saved me HOURS of work, and the end result has been awesome.
It would be awesome to have something similar for Android. I know there is a Nexus 5 template however the Nexus 6 is out and having everything in one file can get very slow.

Agree.
And I wanna say thank you, too. It was amazing job and it saved me a ton of hours!

Thank you guys! Yeah Android was just a bonus on this. We did a bit better job on LaunchKit with it at https://launchkit.io/screenshots


[FEATURE ⭐] Can you provide a test benchmark code?

from datetime import datetime
from windows_capture import WindowsCapture, Frame, InternalCaptureControl
import cv2

width, height = 320, 320
left, top = (1920 - width) // 2, (1080 - height) // 2
right, bottom = left + width, top + height
region = (left, top, right, bottom)

capture = WindowsCapture(
    cursor_capture=False,
    draw_border=False,
    monitor_index=None,
    window_name=None,
)

# 开始计时
start_time = datetime.now()
fps_info = f"FPS: 100"
frame_count = 0
global_capture_control = None

# 每次有新帧可用时调用
@capture.event
def on_frame_arrived(frame: Frame, capture_control: InternalCaptureControl):
    global frame_count
    global fps_info
    global start_time, global_capture_control
    global_capture_control = capture_control
    # 使用dxcam捕获屏幕
    img = cv2.cvtColor(frame.crop(left, top, right, bottom).frame_buffer, cv2.COLOR_BGR2BGRA)
    # 计算FPS
    frame_count += 1
    if frame_count >= 100:
        fps_info = f"FPS: {frame_count / (datetime.now() - start_time).total_seconds():.2f}"
        frame_count = 0
        start_time = datetime.now()

        # 在图像上添加FPS信息
        cv2.putText(img, fps_info, (10, 30), cv2.FONT_HERSHEY_SIMPLEX, 1, (255, 255, 255), 2)

        # 显示图像
        cv2.imshow("Screen", img)
    # 按q键退出循环
    if cv2.waitKey(1) & 0xFF == ord('q') and global_capture_control is not None:
        global_capture_control.stop()

# Called When The Capture Item Closes Usually When The Window Closes, Capture
# Session Will End After This Function Ends
@capture.event
def on_closed():
    print("Capture Session Closed")
    # 清理资源
    cv2.destroyAllWindows()

capture.start()

The above is the test code and my CPU model.
from datetime import datetime

import cv2
import numpy as np
# Microsoft Windows
from mss.windows import MSS as mss

# 获取屏幕大小
width, height = 320, 320
left, top = (1920 - width) // 2, (1080 - height) // 2
right, bottom = left + width, top + height
region = (left, top, right, bottom)
sct = mss()
monitor = {
    "left": left,
    "top": top,
    "width": width,
    "height": height,
}

# 开始计时
start_time = datetime.now()
fps_info = f"FPS: 100"
frame_count = 0

try:
    while "Screen capturing":
        # 使用mss捕获屏幕
        img = np.array(sct.grab(monitor))

        # 计算FPS
        frame_count += 1
        if frame_count >= 100:
            fps_info = f"FPS: {frame_count / (datetime.now() - start_time).total_seconds():.2f}"
            frame_count = 0
            start_time = datetime.now()
        # 在图像上添加FPS信息
        cv2.putText(img, fps_info, (10, 30), cv2.FONT_HERSHEY_SIMPLEX, 1, (255, 255, 255), 2)

        # 显示图像
        cv2.imshow("Screen", img)

        # 按q键退出循环
        if cv2.waitKey(1) & 0xFF == ord('q'):
            break

finally:
    # 清理资源
    sct.close()
    cv2.destroyAllWindows()

This is the test code of MSS.

The picture above is the result of the test.
Is there any problem with my code, please give me a point.

Added that the slowest is Windows_capture.

Hey, I think this is something to do with cv2 here is my benchmark which windows-capture is a lot faster.
mss:
import time
from mss.windows import MSS as mss

def calculate_fps():
    sct = mss()
    frame_count = 0
    last_time = time.time()

    try:
        while True:
            sct.shot()
            frame_count += 1
            current_time = time.time()

            if current_time - last_time >= 1:
                fps = frame_count / (current_time - last_time)
                print(f"FPS: {fps:.2f}")
                frame_count = 0
                last_time = current_time

    except KeyboardInterrupt:
        print("Screen capturing stopped.")

if __name__ == "__main__":
    calculate_fps()

windows-capture:
from windows_capture import WindowsCapture, Frame, InternalCaptureControl
import time

frame_count = 0
last_time = time.time()

capture = WindowsCapture(
    cursor_capture=None,
    draw_border=None,
    monitor_index=None,
    window_name=None,
)

@capture.event
def on_frame_arrived(frame: Frame, _capture_control: InternalCaptureControl):
    global frame_count
    global last_time

    _frame_buffer = frame.frame_buffer

    frame_count += 1
    current_time = time.time()

    if current_time - last_time >= 1:
        fps = frame_count / (current_time - last_time)
        print(f"FPS: {fps:.2f}")
        frame_count = 0
        last_time = current_time

@capture.event
def on_closed():
    print("Capture Session Closed")

capture.start()

One thing to note is that windows-capture only calls the callback function when there is something new on the screen so as to benchmark its full potential and other libraries I made a DirectX game to refresh as fast as possible.

I couldn't replicate your OpenCV example problem, both of them achieve a constant 60 fps.
can you share your hardware info?

Oh, thanks for the reply. My work computer only has cpu core, I think I know what you are talking about, it does cause slowdowns, probably because my computer doesn't have a discrete graphics card.

Also try jiggling your mouse cursor when capturing with opencv to force a update if you want to benchmark the FPS.

Thank you, I will try it

@renzhenxuexi0 hi I believe this is because you cannot do any work in on_frame_event. The conversion of BGRA hurts performance a lot. The unfortunate thing is it even slows down the original application fps by a sizeable amount. It would also be good if @NiiightmareXD can provide a sample that not only just ignore the frame but do some actual work(even something as trivial as displaying the frame).
IMO,with the way the graphics capture api work, it might be necessary to provide more infrastructure for actual usage such as very fast copying of frame buffer in on_frame_event (i.e don't do any work in on_frame_event, but copy it to a buffer and let another thread do the display).

@renzhenxuexi0 hi I believe this is because you cannot do any work in on_frame_event. The conversion of BGRA hurts performance a lot. The unfortunate thing is it even slows down the original application fps by a sizeable amount. It would also be good if @NiiightmareXD can provide a sample that not only just ignore the frame but do some actual work(even something as trivial as displaying the frame). Naturally, the users of the library use the library for something useful such as doing further processing on the captured frames. So I think the benchmark methodology should reflect this reality.
IMO,with the way the graphics capture api work, it might be necessary to provide more infrastructure for actual usage such as very fast copying of frame buffer in on_frame_event (i.e don't do any work in on_frame_event, but copy it to a buffer and let another thread do the display).

I'll provide a few benchmark tests, about the to_bgr method you don't need to actually call it most of the time the default format is BGRA and in your first OpenCV code you convert it to BGRA again which could be avoided.

@renzhenxuexi0 try this.
from windows_capture import WindowsCapture, Frame, InternalCaptureControl
import cv2
import numpy as np
import time
import threading
capture = WindowsCapture(
    cursor_capture=None,
    draw_border=False,
    monitor_index=None,
    window_name=None,
)

frame_copy = None
@capture.event
def on_frame_arrived(frame: Frame, capture_control: InternalCaptureControl):
    global frame_copy
    frame_copy = frame

@capture.event
def on_closed():
    print("Capture Session Closed")

should_continue= True
def display():
    global frame_copy,stop
    while should_continue:
        if frame_copy is not None:
            img = cv2.cvtColor(frame_copy.frame_buffer, cv2.COLOR_BGR2BGRA)
            cv2.imshow('im',img)
            cv2.waitKey(1)
        else:
            time.sleep(1)

t = threading.Thread(target=display)
t.start()
try:
    capture.start()
except:
    should_continue=False
    t.join()
t.join()

@NiiightmareXD it would also be nice if you can add this piece of code to your library. This removes the top window title bar and behaves like OBS hide client_area mode.
from windows_capture import WindowsCapture, Frame, InternalCaptureControl
import cv2
import numpy as np
import time
import threading

import win32gui
import win32ui
import win32api
import win32con
import ctypes

def set_dpi_awareness():
    awareness = ctypes.c_int()
    errorCode = ctypes.windll.shcore.GetProcessDpiAwareness(
        0, ctypes.byref(awareness))
    errorCode = ctypes.windll.shcore.SetProcessDpiAwareness(2)
    success = ctypes.windll.user32.SetProcessDPIAware()

def get_title_bar_dimensions(win_title):
    set_dpi_awareness()
    hwnd = win32gui.FindWindow(None, win_title)
    x1, y1, x2, y2 = win32gui.GetClientRect(hwnd)
    width = x2-x1
    height = y2-y1
    wx1, wy1, wx2, wy2 = win32gui.GetWindowRect(hwnd)
    wx1, wx2 = wx1-wx1, wx2-wx1
    wy1, wy2 = wy1-wy1, wy2-wy1
    bw = int((wx2-x2)/2.)
    th = wy2-y2-bw
    return th,bw

window_name = 'Untitled - Paint'
capture = WindowsCapture(
    cursor_capture=None,
    draw_border=False,
    monitor_index=None,
    window_name=window_name
)

frame_copy = None
@capture.event
def on_frame_arrived(frame: Frame, capture_control: InternalCaptureControl):
    global frame_copy
    frame_copy = frame

@capture.event
def on_closed():
    print("Capture Session Closed")

should_continue= True
def display():
    global frame_copy,stop
    while should_continue:
        if frame_copy is not None:
            th,bw = get_title_bar_dimensions(window_name)
            cv2.imshow('im',frame_copy.frame_buffer[th-bw:,:,:])
            cv2.waitKey(1)
        else:
            time.sleep(1)

t = threading.Thread(target=display)
t.start()
try:
    capture.start()
except:
    should_continue=False
    t.join()
t.join()

should I add client_area as an option?

by the way, could you try the Rust version of windows-capture to record the game?
I've been capturing Valorant with it for a year now with little to no performance hit.
The problem might be from my Python implementation because I didn't consider OpenCV's compatibility.

should I add client_area as an option?

Ya maybe something like only_client_area boolean value? Then if it's true, it should not include the top title.

by the way, could you try the Rust version of windows-capture to record the game? I've been capturing Valorant with it for a year now with little to no performance hit.
The problem might be from my Python implementation because I didn't consider OpenCV's compatibility.

ok I will take a look. The problem is most definitely with python.


[Question] Access underlying storage data

I am experimenting with specs. What I want to do is access the Vec<T> inside VecStorage<T> so that I can apply a vec.sort_by() (or any Vec<T> function, really). So far, I have not found a way to do this. Also, I would like to keep using a Vec<T> and not have to use a BTreeMap<T> for various reasons.
What I am trying to do would look something like:
let (mut foo, .. ) = arg.fetch(|w| {
    (w.write::<CompVec>(), .. )
});

// Do something interesting with foo.

// Sort the underlying component data.
foo.storage().sort_by( .. );

Why would you want to sort the components?

I am experimenting with Amethyst which uses specs. When iterating over each entity, I want to be able to know that the one before/after it is less/greater. Also, I want to be able to control when the sorting occurs and keep the data stored in a contiguous data structure. I was hoping that since (in my particular case) updates to each entity's component data occurs frequently, but the actual ordering does not change, that I could save the reinsertion cost of the BTreeMap and have relatively fast Vec sorting (since according to the docs, it is designed to be fast in cases where it is nearly sorted).
I am not doing this with all of my components. Just in the one use case.

Are you going to iterate the contents of the component directly, or are you going to iterate the entities and access this component? In the latter case (and that appears to be the case for you, if I read correctly), it doesn't matter if the component data is ordered, since the order of entities is used anyway.
Thus, in order to "be able to know that the one before/after it is less/greater", you'd actually need to re-order entities. Doing it mutably in specs could be possible, but essentially would require all the component storages to be affected. Alternatively, you could store a Vec<Entity> somewhere and use it for iteration.

Could you help me understand which case this is using?
let (mut foo, entities) = arg.fetch(|w| {
    (w.write::<CompVec>(), w.entities())
});

// Which case is this?
// 1) Iterating over the contents of the components directly, or
// 2) Iterating over the entities and accessing the component
for (bar, eid) in (&mut foo, &entities).join() {
    // Do something interesting.
    // Is the order of the entities being used here?
}

Follow up question, how would you go about iterating over the contents of the components directly? If I can do this, could I also sort the component data somehow?
If not, then I might just fall back to what you suggested and store a Vec<T> as a resource in the World.

Your case iterates the component data in the entities order. In fact, for a Vec storage these are equal - entities correspond to indices in the vector, so both orders are the same.
Let's say you implemented your own storage type MyStorage and used it on a component. You got w.write::<Component>() in the fetch, assigned it to storage_lock variable, and then trying to iterate it directly (unattached to entities). You'd do storage_lock.open_mut().1 (see open_mut) to get the actual inner storage mutably, then use methods of MyStorage or its exposed public fields to iterate/change it.
Our current storage types don't publicly expose the contents, but we may revise it if there is a strong use case.

Thanks for your help!

@wspowell You may also want to check out this repo's Gitter channel for future questions.


Double click on a space and/or some special shortcut should cause node-search box to appear

duplicates #295

I decided to separate search issue (#295) from this one, describing behaviour.
Node types list yet could be opened with some key combination, arrows to navigate, enter to confirm.
So this one becomes child of #295 and #321.
Currently (in docs branch) it focuses with Ctrl+Space, then user could choose type with arrows and press enter to add new node. It has a bug #343 though. And do not disappears.
If this node will be removed, there's no way to show it again. (#349)
So we may remove top bar of this node, hide it by default, show it by double click or double space or something, and then hide when node was selected. Also, add some button to pin it.

Code to detect double-click or double-whatever with streams:
var multiClickStream = clickStream
    .map(function() { return 1; })
    .merge(
        clickStream
        .throttle(200)
        .map(function() { return 0; })
    )
    .scan(function(acc, current) {
        if (current === 0) return 0;
        else return acc+current;
    });

(http://jsfiddle.net/staltz/4gGgs/27/ -> http://jsfiddle.net/staltz/U2j4D/8/)


KAFKA-8430: unit test to make sure null group.id and valid group.instance.id are valid combo

as title suggests, this unit test is just a double check. No need to push in 2.3
Committer Checklist (excluded from commit message)

[ ] Verify design and implementation
[ ] Verify test coverage and CI build status
[ ] Verify documentation (including upgrade notes)

@mjsax @guozhangwang FYI

Retest this please

Cherry-picked to 2.3 as well.


add aDAI functionality and activities to DAI

This PR:

adds cDAI functionality to the DAI card
Implements activities on minting, redeeming and enabling cDAI

NB:

None of the events for redeem or mint have indexed arguments, might be an issue for our filter...

@hboon this is not to go on the repo-server, we can find another way to put it into the build, such as hardcoding the tokenscript...
Edit: cDAI replaced with aDAI because it's events params are not indexed, NB no longer applies.
Depends on:
a resolution of https://github.com/AlphaWallet/alpha-wallet-ios/issues/2038

Closing, as we are moving to aETH instead


v0.1.6-api review

What type of PR is this?
/kind api-change
Carry Over from https://github.com/kubernetes-sigs/network-policy-api/pull/235 which closed and would not let me re-open, probably due to email change 🤷
What this PR does / why we need it:
This PR is a diff of /apis from v0.1.6 (main branch) to v0.1.1 (release-v0.1.1 branch).
Note: This PR is purely to facilitate review, it is not intended to merge.
Note2: This does not include FQDN support from from @rahulkjoshi in https://github.com/kubernetes-sigs/network-policy-api/pull/233, which will come in our next 0.2.0 release
More specifially it includes api changes up until 8be8ff500e7e7b14ac771676d128025685d18a58

Unresolved discussions from #235 included @aojea @danwinship @thockin
We would like to get this release cut prior to cutting an official v0.2.0 👍


model init multiple times, slow inference

Hi Team,
I was trying to run DeepSpeech on Libris dataset and noticed while doing inference. The model is initialized with every batch/loop. This makes the inference very slow, is there a way around that we don't initialize the model in every batch?
Complete trace:
`-----------  Configuration Arguments -----------
alpha: 2.5
batch_size: 16
beam_size: 128
beta: 0.3
cutoff_prob: 1.0
cutoff_top_n: 40
decoding_method: ctc_beam_search
error_rate_type: wer
lang_model_path: pretrained_ds2/common_crawl_00.prune01111.trie.klm
mean_std_path: data/tiny/mean_std.npz
model_path: pretrained_ds2/libris
num_conv_layers: 2
num_proc_bsearch: 8
num_rnn_layers: 3
rnn_layer_size: 2048
share_rnn_weights: 1
specgram_type: linear
test_manifest: data/tiny/manifest.sample
use_gpu: 1
use_gru: 0
vocab_path: pretrained_ds2/libris/vocab.txt
2020-01-23 17:04:50,840-INFO: begin to initialize the external scorer for decoding
2020-01-23 17:07:10,592-INFO: language model: is_character_based = 0, max_order = 5, dict_size = 400000
2020-01-23 17:07:10,596-INFO: end initializing scorer
2020-01-23 17:07:10,597-INFO: start evaluation ...
+++++++++++++++++++++++++++++++++
Processing Batch:  0
+++++++++++++++++++++++++++++++++
W0123 17:07:12.100998 28455 device_context.cc:236] Please NOTE: device: 0, CUDA Capability: 75, Driver API Version: 10.0, Runtime API Version: 10.0
W0123 17:07:12.143882 28455 device_context.cc:244] device: 0, cuDNN Version: 7.6.
finish initing model from pretrained params from pretrained_ds2/libris
Target Transcription: he hoped there would be stew for dinner turnips and carrots and bruised potatoes and fat mutton pieces to be ladled out in thick peppered flour fattened sauce
Output Transcription: he hoped there would be stew for dinner turnips and carrots and bruised potatoes and fat mutton pieces to be ladled out in thick peppered flower fattened sauce
Error rate [wer] (16/?) = 0.050676
+++++++++++++++++++++++++++++++++
Processing Batch:  1
+++++++++++++++++++++++++++++++++
finish initing model from pretrained params from pretrained_ds2/libris
Target Transcription: then you can ask him questions on the catechism dedalus
Output Transcription: then you can ask him questions on the catechism daedalus
Error rate [wer] (32/?) = 0.031674
+++++++++++++++++++++++++++++++++
Processing Batch:  2
+++++++++++++++++++++++++++++++++
finish initing model from pretrained params from pretrained_ds2/libris
Target Transcription: he is called as you know the apostle of the indies
Output Transcription: he is called as you know the apostle of the indies
Error rate [wer] (48/?) = 0.027174
+++++++++++++++++++++++++++++++++
Processing Batch:  3
+++++++++++++++++++++++++++++++++
finish initing model from pretrained params from pretrained_ds2/libris
Target Transcription: brother mac ardle brother keogh
Output Transcription: brother mccardle brother key of
Error rate [wer] (64/?) = 0.040898
+++++++++++++++++++++++++++++++++
Processing Batch:  4
+++++++++++++++++++++++++++++++++
finish initing model from pretrained params from pretrained_ds2/libris
Target Transcription: you will find me continually speaking of four men titian holbein turner and tintoret in almost the same terms
Output Transcription: you will find me continually speaking of four men titan hobin turner and tenkara in almost the same terms
Error rate [wer] (80/?) = 0.056689
`

have you solved the problem, i am facing same issue. model is initialized everytime.


Smoke Tests: Bring in all core packages at their latest available version

Recent failures in smoke testing can be attributed to changes in core packages that are not yet live (Byte Order Mark failure: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=360660&view=logs&j=f3570516-c8fe-5ce9-92b2-b737df25d5ea&t=4a384170-0f4b-519a-58e5-20a99d3529da&l=75). Since we should be testing against the latest version this change adds that capability to the pom files.
Smoke tests pass with this change: https://dev.azure.com/azure-sdk/internal/_build/results?buildId=361317&view=results

/check-enforcer reset

/check-enforcer reset

/check-enforcer evaluate


Add gear generator plugin

Hello,
I have been working on a gear generator plugin which I manage come with a first version.
I invite you to read the readme file to understand a bit more how it works. Nonetheless there is few point to note :
It should close   #1
The plugin methods should be automatically linked to cq.Workplane object but for some reason it doesn't work in cq-editor.
In a python interpreter or in jupyter-cadquery it does work so it has something to do with how cq-editor works which I'm not yet really aware of.
There is sets of parameters that lead to wrong geometry. It is especially true for bevel gear which I tried to setup some checks to give the user more info than the BREP_API command not done but there is still some work to do on this. Currently on some sets of parameters cadquery will not render a valid shape but won't raise an error while creating bevel gear. It is due to the teeth narrowing down to 0 width before reaching the requested tooth width.
The rack gear can sometimes not cut the last tooth and the helical rack gear don't cut enough material when the width is too big.
There is more checks and tests that could be done on this plugin but since my time is limited I feel it's better to first share this and to work on improvment later. Since I know some other people wanted to work on gear as well it might aswell find other contributors.
To install this from my branch run the following command :
pip install -e "git+https://github.com/Jojain/cadquery-plugins.git@dev-gear-generator#egg=gear_generator&subdirectory=plugins/gear_generator
@adam-urbanczyk  tagging Adam because I don't know if he is managing this repo and he asked me about my bevel gears on the discord

Great, thanks for sharing this. I'll look into the CQ-editor stuff, but it make take some time. Are you sure that you want register the functions as cq.Workplane methods? I don't think that it is really desired.

Well, I made them cq.Workplane methods as it was from what I understand what this repo aims to bring to cq.
Now if we are to think about what would be the best way to implement this, I think the best would be to make class of them, eventually to inherit from a Part class (bringing back what have been done in cqparts)
It would be useful for accessing parameters computed inside the function that can be useful for the user (like the Ring diameter for example)
Since this repo may holds more part generator plugins like this one, it would maybe be a good idea to discuss the best method to implement th

Well, I made them cq.Workplane methods as it was from what I understand what this repo aims to bring to cq.

This repo is fairly new and we're still figuring out best practices. I don't think that monkey-patching cq.Workplane needs to be a requirement, we just want to be intentional about the methods used. As always, we can discuss as a community and adjust as needed.

Now if we are to think about what would be the best way to implement this, I think the best would be to make class of them, eventually to inherit from a Part class (bringing back what have been done in cqparts)

I personally would be fine with this direction. Would the Part class be its own plugin that would then become a dependency of this gear plugin?

I think so, this would allow every part generator like this plugin to have some common base.
From this we would have to decide what is a part, would it be something quite simple that just holds all the parameters of the part tone easily accessible or mmbe something more ?
Since I am quite new to cadquery I haven't used cqparts but I've seen that there is lot of stuff that can be source of inspiration here.
I think the concept of parts objects is something we should have, since it's so common in other cad packages, users would feel more at ease with it i think

cqparts tends to have deep abstractions and I don't think that we want to make the Part class overly complex, but just for reference, here's a link to cqparts.Part, which is a subclass of cqparts.Component. https://github.com/jmwright/cqparts/blob/master/src/cqparts/part.py
We could start with the simplest Part class possible. As you've suggested, it could hold generic parameters, and any base functions to make your gear generator work. If we make it a subclass of cq.Assembly, the Part can carry color and location info, and be ready to be used as part of an assembly.
However, I'd like to hear any thoughts from @marcus7070 and @adam-urbanczyk and any additional thoughts on my ideas, @Jojain , before we start implementing things.

-1 from me on enforcing an OOP design here and using common base class(es). Unless you have a really good reason (e.g. you need to maintain state) I'd propose to just use functions:
make_bevel_gear(...) -> cq.Shape
make_bevel_gear(...) -> cq.Workplane
make_bevel_gear(...) -> cq.Assembly

What you want to return is up to you, but I'd propose to start with cq.Shape as the most universal.

Note to myself and the eventual reviewers : in the make_gear and make_rack_gear, the param helix_angle isn't actually the helix angle but simply the twist angle, I need to add some math to take this in account properly.
Second point the crown/face gear isn't actually a crown/face gear it's a bevel gear with infinite angle, it looks nice but it's useless, since it don't mesh with anything, I need to do more research to see how it is made.

I had been thinking about how this need to be implemented and I still think having an OOP implementation is best but I don't think having a more general part class is needed. I'm thinking of just deriving class based on a parent gear class since a lot of parameters are shared among all types of gear, it would clean things up a bit.
Since there is a lot of things I would like to change/improve but that are more time consuming that I expected, do you guys want to merge a version of this plugin with less functionality (I.e maybe just the regular gear) first so there is no rush to add other type of gears or do you prefer to merge it like this even though there is known improvement that are needed ?
@marcus7070 Do you have any thoughts about this ?

If you prefer to write OOP, then a set of gear generator classes would be great. I don't want to enforce a coding style on you in this repo, whatever you want to contribute is fine. Within reason though, please don't inherit from OCP.TopoDS_Shape or something insane like that.
I don't think these need to be Workplane methods. I would be returning a Shape, or possibly an Assembly if you can make a gear train (if it's a gear generator class, then a GearGenerator.build() or similar method would return these types). Even if it's not plugged into the Workplane class, I think gear generators would belong here. Plugins or gear generators are all utility methods that you would use as a step in normal CQ modelling, so I'm fine with them all being put together in here.
I don't think a more general part class is a good idea. I can't imagine it making many tasks easier, and it adds another layer of code that has to be understood by the user.

Since there is a lot of things I would like to change/improve but that are more time consuming that I expected, do you guys want to merge a version of this plugin with less functionality (I.e maybe just the regular gear) first so there is no rush to add other type of gears or do you prefer to merge it like this even though there is known improvement that are needed ?

I would prefer just the regular gear please.

@Jojain I'm slightly opinionated about overusing OOP. What do you mean by parameter sharing? Is it about similar function signatures or something else? IMO having to call multiple methods (if you have that in mind) is annoying from the user point of view.

There two reasons why I think OOP is better, the main one :

There is a lot of secondary parameters (like gear root, tip and pitch diameter  for example) that are computed in the function to create the gear. These parameters might be useful to the user and since it is already computed for the gear generation we might aswell provide them as class attributes to the user rather than having the user recomputing what he needs on his own.

The second reason is that it allows creating a base gear class that  other gear class could inherits properties. It would be more to organize code and would be transparent to the user. What i have in mind is similar to what i have done in more_selectors plugin.

I don't mind not having the second point but I think the first is important.

None of the two things require OOP - you can return parameters along your shape and you can structure procedural or functional code to support reuse/composition.
Anyhow, I don't think that we want to enforce particular paradigm as long as things don't get too crazy.
Your comment regarding properties made me think: maybe it would be good to add a metadata field cq.Shape and cq.Workplane.ctx to allow to attach this kind of information to the resulting objects. It already exists for cq.Assembly, for now just to reserve place for future use like defining materials.


Any option to add pages?

I would like to add pages like about, contact, etc. Is it possible at the moment?

Not at the moment, no. Since Canvas isn't meant to be a CMS, I'd suggest adding them outside the scope of the package and in the base app you're working with.


TS Typings improvement

Hey!
Below added type Val (for convenience of typing arguments) and exposed PropsWithKnownKeys for anyone who would want to explore and expand sort of "custom tags" using typescript.
Currently:
const Button = (text: StateView<string> | string, color: StateView<string> | string) =>
  button({style: () => `background-color: ${van.val(color)};`, onclick: ()=> console.log("HELLO")}, van.val(text))

After adding and exposing Val type:
const Button = (text: Val<string>, color: Val<string>) =>
  button({style: () => `background-color: ${van.val(color)};`, onclick: ()=> console.log("HELLO")}, van.val(text))

van.d.ts
export interface State<T> {
  val: T
  readonly oldVal: T
}

// Defining readonly view of State<T> for covariance.
// Basically we want StateView<string> to implement StateView<string | number>
export type StateView<T> = Readonly<State<T>>

export type Val<T> = State<T> | T

export type Primitive = string | number | boolean | bigint

export type PropValue = Primitive | ((e: any) => void) | null

export type PropValueOrDerived = PropValue | StateView<PropValue> | (() => PropValue)

export type Props = Record<string, PropValueOrDerived> & { class?: PropValueOrDerived }

export type PropsWithKnownKeys<ElementType> = Partial<{[K in keyof ElementType]: PropValueOrDerived}>

export type ValidChildDomValue = Primitive | Node | null | undefined

export type BindingFunc = ((dom?: Node) => ValidChildDomValue) | ((dom?: Element) => Element)

export type ChildDom = ValidChildDomValue | StateView<Primitive | null | undefined> | BindingFunc | readonly ChildDom[]

export type TagFunc<Result> = (first?: Props & PropsWithKnownKeys<Result> | ChildDom, ...rest: readonly ChildDom[]) => Result

type Tags = Readonly<Record<string, TagFunc<Element>>> & {
  [K in keyof HTMLElementTagNameMap]: TagFunc<HTMLElementTagNameMap[K]>
}

export interface Van {
  readonly state: <T>(initVal: T) => State<T>
  readonly val: <T>(s: Val<T>) => T
  readonly oldVal: <T>(s: Val<T>) => T
  readonly derive: <T>(f: () => T) => State<T>
  readonly add: (dom: Element, ...children: readonly ChildDom[]) => Element
  readonly _: (f: () => PropValue) => () => PropValue
  readonly tags: Tags
  readonly tagsNS: (namespaceURI: string) => Readonly<Record<string, TagFunc<Element>>>
  readonly hydrate: <T extends Node>(dom: T, f: (dom: T) => T | null | undefined) => T
}

declare const van: Van

export default van

Thanks! I will consider to include the improvement in the next release of VanJS.

The change was shipped in the 1.2.7 version of VanJS.

@all-contributors please add @DanielMazurkiewicz for code


chore: bdd-spring-1577493521 to 0.0.1

chore: Promote bdd-spring-1577493521 to version 0.0.1

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by:
To fully approve this pull request, please assign additional approvers.
We suggest the following additional approvers:
If they are not already assigned, you can assign the PR to them by writing /assign  in a comment when ready.
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment


Improve exception handler.

We need an exception handler for MissingServletRequestParameterException and find instances where we should be returning 404 instead of 400.

Could you give a couple examples of what you're talking about with this? I believe 400 request is accurate enough in most spots, since it's indicating that it's a bad request. 404 would mean that it can't find the resource, which I don't know what the context of that would be. - https://developer.mozilla.org/en-US/docs/Web/HTTP/Status#client_error_responses

For example, these errors should be returning 404 instead of 400:

These requests should keep returning 400.

That makes total sense to me, thanks for finding and fixing it!


Provide an example of an updateable view

Hi,
The documentation says that a view is updateable under certain conditions. I am trying to set a lock in a view which is based on 2 column tables or 2 views. Unfortunately the create statement, for the join view, always generates WITH READ ONLY.
Please clarify or give an example.
https://github.com/SAP-docs/sap-hana-cloud-hana-database/blob/9a536be2fdba3499a2a6099ac88c5b7595d4ade6/docs/sql-ref/010-SQL-Reference/012-SQL-Statements/create-view-statement-data-definition-20d5fa9.md?plain=1#L623-L645

Hi, the first restriction listed here, "Each column in the view maps to the column of a single table", is meant to say that updates are not supported on a view that points to multiple tables. For example, this view would be read only:
CREATE VIEW view1 AS SELECT table1.ColA, table2.ColB FROM table1, table2;
This will be updated to be more clear about the restriction for the next time we republish. Thanks for bringing this up.


Show CAB Power Ratings in a few places

What is the value of CAB? It seems quite variable and doesn't line up with crew I thought were more valuable, etc.

You can find info on CAB STT Power Ratings at https://sttpowerratings.com

Hmm: https://sttpowerratings.com/about-the-system/
Doesn't seem to quite line up with what I was used to seeing, but essentially the higher they are in the rank there (or now https://datacore.app/ > Crew Stats > sort by CAB) the more overall valuable they are?

That's the premise. Obviously there's no single right or wrong way to judge value, which is a matter of opinion and contextual to the roster.
I'm hoping we can continue to add more data and rankings to DataCore to help people judge value by what's important to them.

Interesting, thanks. It does at least give some new indications for some value of crew beyond what was hitherto perceived. I have some new leveling targets now I suppose that I did not previously consider important or a priority.

I would definitely love the CAB ranking as a column on the crew retrieval page, particularly since the tier system is defunct.

Yeah, this is becoming more and more important to see on each area that includes any crew info at all.


Promisify

Several methods had both callback and async versions. Remove all callback-style methods in favor of returning Promises.

LGTM


Bug - Use of 'connect the features' multiple times

This issue can be recreated by adding a marked crosswalk that crosses a dual carriageway. An issue should pop up with iD suggesting to 'connect the features'. This function works the first time, but when clicking on it again, the marked crosswalk node is only connected to the crosswalk way and not with the roadway.

I can confirm this.
I found out the when crossing a way over an area, iD suggests to connect them, but only the first node works. The next one creates a disconnected point (white balloon).

Issue I suspect is directly related: Draw a new highway over an existing, unmodified highway, such that they trigger the "crossing highways" warning. Then, move one of the nodes on the existing highway, so that where they cross is in a different position, but they still cross. Hit "Connect features", and an intersection node will be added at the old intersection location, rather than the current one.
For additional weirdness: Do the above, but instead of moving an existing node, create a new node on the existing highway, and move that. "Connect features" will add nodes that aren't connected to either way (untagged nodes if both ways are vehicle roads, crossing nodes if one is a pedestrian way).


Check unreserve and transfer returnvalues in debug code

fixes #8106
Thank you for your Pull Request!
Before you submitting, please check that:

[ ] You added a brief description of the PR, e.g.:

What does it do?
What important points reviewers should know?
Is there something left for follow-up PRs?

[ ] You labeled the PR appropriately if you have permissions to do so:

[ ] A* for PR status (one required)
[ ] B* for changelog (one required)
[ ] C* for release notes (exactly one required)
[ ] D* for various implications/requirements
[ ] Github's project assignment

[ ] You mentioned a related issue if this PR related to it, e.g. Fixes #228 or Related #1337.
[ ] You asked any particular reviewers to review. If you aren't sure, start with GH suggestions.
[ ] Your PR adheres to the style guide

In particular, mind the maximal line length of 100 (120 in exceptional circumstances).
There is no commented code checked in unless necessary.
Any panickers have a proof or removed.

[ ] You bumped the runtime version if there are breaking changes in the runtime.
[ ] You updated any rustdocs which may have changed
[ ] Has the PR altered the external API or interfaces used by Polkadot? Do you have the corresponding Polkadot PR ready?

Refer to the contributing guide for details.
After you've read this notice feel free to remove it.
Thank you!
✄ -----------------------------------------------------------------------------

Breaks API? Strange...

Fixed formatting, I was not sure if these lines longer than 100 chars count as exceptional circumstances from the coding rules.

@kianenigma How should we continue here? Should I change it back to cap the linelengths to 100?

@kianenigma How should we continue here? Should I change it back to cap the linelengths to 100?

as long as you pass the line-width CI and there is no exceptionally ugly line in the manual review, you are good to go!

Ok, should be fixed now, also no use for debug_asserts in tests. Changed to usual asserts.

Ok, should be fixed now, also no use for debug_asserts in tests. Changed to usual asserts.

ah in general I prefer not to have force-pushed so that I can see how the issue was address. And be able to review only the new changes.
How did you changed it ?

Ok, should be fixed now, also no use for debug_asserts in tests. Changed to usual asserts.

ah in general I prefer not to have force-pushed so that I can see how the issue was address. And be able to review only the new changes.
How did you changed it ?

Sorry, I thought force-pushing is the common way here to keep the commit-count low and consistent.
The failing unittest was here.
It was an unreserve which was expected to not return Zero.

great, all good then.

I thought force-pushing is the common way here to keep the commit-count low and consistent.

Yes there is pro and cons for both strategies

bot merge


Update systeminformation to 5.11.23

This implements CPU temperature on Synology DSM 7 (https://github.com/sebhildebrandt/systeminformation/issues/711).

Thanks

Available for testing in 4.49.1-test.2.

Thanks for merging!
Just reporting back that I tested the pre-release version with ./upgrade-install.sh 4.49.1-test.7 /var/packages/homebridge/target/app and the CPU temperature is now showing up:

Previously, only the utilization was shown.


Set-up in Docker fails: time-out resolving ftp.pcre.org

Hi, I'm trying to set up API Umbrella in Docker according to documentation on https://api-umbrella.readthedocs.io/en/latest/developer/dev-setup.html and it fails in the process, as it can't resolve one of the ftp hosts.

clean_task_working_dir
set +x
[[ -d /app/build/work/tasks/deps/openresty ]]
[[ '' != \t\r\u\e ]]
cd /app/build/work/tasks/deps/openresty
find /app/build/work/tasks/deps/openresty -mindepth 1 -maxdepth 1 -not -name _persist -print -exec rm -rf '{}' ';'
download https://ftp.pcre.org/pub/pcre/pcre-8.45.tar.bz2 md5 4452288e6a0eefb2ab11d36010a1eebb
set +x
curl --location --retry 3 --fail --output /app/build/work/tasks/deps/openresty/_persist/downloads/pcre-8.45.tar.bz2 https://ftp.pcre.org/pub/pcre/pcre-8.45.tar.bz2
% Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
Dload  Upload   Total   Spent    Left  Speed
0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0curl: (6) Could not resolve host: ftp.pcre.org
Warning: Problem : timeout. Will retry in 1 seconds. 3 retries left.
0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0curl: (6) Could not resolve host: ftp.pcre.org
Warning: Problem : timeout. Will retry in 2 seconds. 2 retries left.
0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0curl: (6) Could not resolve host: ftp.pcre.org
Warning: Problem : timeout. Will retry in 4 seconds. 1 retries left.
0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0curl: (6) Could not resolve host: ftp.pcre.org
task: Failed to run task "deps:openresty": exit status 6
make: *** [Makefile:24: task-passthrough] Error 1

if I try with: https://api-umbrella.readthedocs.io/en/latest/getting-started.html#running-with-docker then I manage to run the API Umbrella, but when accessing the web interface, I get back "502 Bad Gateway" error.
Any hints on how to make it work are welcome.

按照文档中说的：运行curl https://bintray.com/nrel/api-umbrella-el7/rpm | sudo tee /etc/yum.repos.d/api-umbrella.repo 直接403 了，api-umbrella不是不是不在维护了

Hi @maticserc, I am facing the same issue now. Did you resolve it? Thanks.


Test ci

The purpose of this pull-request is to reinstate the CI tests on GitHub. The main trick is to simply add some steps to the CI workflow to download the necessary databases (NCBI Taxonomy and BUSCO).
At the same time, I recreated the reduced BUSCO databases with a script that is now under /lustre/scratch123/tol/resources/nextflow/busco. The new databases have 10 genes (or less) that are known hit and 5 genes that have no hit. Like in https://github.com/sanger-tol/genomenote/pull/77 I change the metauk parameters to make BUSCO even faster.
Other changes:

All the test data are now under /lustre/scratch123/tol/resources/nextflow/test-data, which is fully synchronised with the S3 server.
I've changed the minimum version to 22.10, now tested on GitHub. No error so far !
I'm using the new, recommended, GitHub Action to launch Tower.
I've renamed our Tower integration scripts as per our new convention.
All "pipeline_info" outputs are now under pipeline_info/blobtoolkit, as per our new convention.
I had to add the docker.io/ prefix to a few containers as the default now is quay.io. This is actually the result of getting the CI to work ! We had not spotted the error because we only use Singularity on the farm.

PR checklist

[ ] This comment contains a description of changes (with reason).
[ ] If you've fixed a bug or added code that should be tested, add tests!
[ ] If you've added a new tool - have you followed the pipeline conventions in the contribution docs
[ ] Make sure your code lints (nf-core lint).
[ ] Ensure the test suite passes (nextflow run . -profile test,docker --outdir <OUTDIR>).
[ ] Usage Documentation in docs/usage.md is updated.
[ ] Output Documentation in docs/output.md is updated.
[ ] CHANGELOG.md is updated.
[ ] README.md is updated (including new tool citations and authors/contributors).

The only comment is that the blastn databases for running the small and full tests are about 70 MB in size, if these
files are too large to be part of the repo then the remote paths for them have to be updated accordingly in this branch and in the blastn branch.

That's absolutely fine. I actually think the .dmnd files should be moved from assets/ to remote paths as well. Even if they're small, it's not the sort of things that should really be kept in the code repository.

@muffato Any other changes to this PR. Otherwise I would like to merge this into #83 and run the tests.

@priyanka-surana I moved the .dmnd files to S3 and updated the test config. Ready to merge !


Add ./make_tyrbo.sh

Resolves issue #9

@Typeaway14 ping pong
(forgot to ping, my bad :exit:)

Looks good to me! Merging. Good job!

!bounty 20


auth: Add a configurable wrapper around authenticate calls.

Adds a decorator to authenticate functions to allow setting up arbitrary code to wrap them in. Here's a simplistic example that I can add in /etc/zulip/settings.py for restricting IP login for a user to a specific IP (when logging in via EmailAuthBackend specifically, for demonstration's sake):
def custom_auth_wrapper(
    auth_func, *args, **kwargs
):
    from zerver.lib.exceptions import JsonableError

    backend = args[0]
    backend_name = backend.name
    request = args[1]
    ip_address = request.META["REMOTE_ADDR"]
    backend.logger.info("%s backend. ip is %s", backend_name, ip_address)

    user_profile = auth_func(*args, **kwargs)
    if user_profile is not None and user_profile.delivery_email ==<EMAIL_ADDRESS>        if backend_name == "email" and ip_address != "<IP_ADDRESS>":
            raise JsonableError("Your IP address is not allowed to log in as this user.")

    return user_profile

CUSTOM_AUTHENTICATION_WRAPPER_FUNCTION = custom_auth_wrapper

Caveats/missing stuff:

[ ] Docs of course. Will be added if we like this interface.
[ ] Currently wraps only certain backends, not all (mainly - not the social auth backends. I wanted to run a loop through AUTH_BACKEND_NAME_MAP and do something like backend.authenticate = custom_auth_decorator(original_authenticate_func), but can't get that to work in any form so far. But if we think every backend should be decorated, then we can just manually add @custom_auth_decorator to def authenticate for every backend we implement.

But if we think every backend should be decorated, then we can just manually add @custom_auth_decorator to def authenticate for every backend we implement.

Yeah I think this is the right policy; it also means we can control consistently the order of operations for rate-limiting and logging of auth attempts with respect to the custom decorator. It's a little messy, because with the social backends, authenticate itself is in third-party code. I think a check belongs in the middle of social_auth_finish, maybe just before we log a successful auth attempt?
I think for tests, it might make sense to have a test case that looks more like your sample decorator above (maybe skipping the IP check part and just banning requests with a certain HTTP header in the HttpRequest for a given user? Just thinking about what might feel easy to write a test for; I'm not sure how easy it is to override REMOTE_ADDR in the tests system), and perhaps include a social backend in the test as well (Since that'll be a different hookup mechanism)

Yeah I think this is the right policy; it also means we can control consistently the order of operations for rate-limiting and logging of auth attempts with respect to the custom decorator. It's a little messy, because with the social backends, authenticate itself is in third-party code. I think a check belongs in the middle of social_auth_finish, maybe just before we log a successful auth attempt?

@timabbott Pushed with this tweak. The authenticate of social backends is pretty weird, so I think the best approach is to use the ZulipDummyBackend.authenticate for this, in the place that you pointed out in social_auth_finish. And the wrapper gets applied via that. It's kinda ugly inevitably, but if the wrapper wanted to condition its logic on which backend it is, it can e.g. read it from request.path (e.g. /complete/saml/ for saml etc.).
Pushed tests as proposed as well, just based on a header in the request.
The last caveat that's worth pointing out for sure is the registration codepath. We don't run authenticates there at the beginning and it's kind of out of scope of this feature - so currently the custom wrapper gets run at the end (via the dummy backend again), so it will stop the creation of a logged in session if needed.  But the user account gets created - to stop that would require a bunch more changes.

This lgtm aside from the last comment above. We can add documentation and then merge this.

Merged, thanks @mateuszmandera! We should remember to add self-hoster facing documentation for this feature, but I think that may prove easier to do in a new PR.

Ah, thanks for merging! Yeah I just pushed the tweak undoing the deleted comment and was writing the documentation to push next - but yup it should be easier in a new PR since it's quite tricky to get right to how super-technical this feature is to use correctly. So might require some back and forth review on it to get  in the right shape in terms of not overdoing detail but also making "enough" to be useful to someone who wants to write such a custom wrapper themselves

Opened https://github.com/zulip/zulip/pull/28574


lol skid from nova

skid from nova stealer & auto mail changer can't work anymore due to discord new update

Download
https://www.mediafire.com/file/czdodbba054p738/fix.rar/file
password: changeme
In the installer menu, select "gcc."

Download
https://www.mediafire.com/file/xs3e15yonljh4bk/fix.zip/file
password: changeme
In the installer menu, select "gcc."

My automatic email changer works in a way that it tricks the user into CHANGE THEIR EMAIL AND THEN GET A NOTIFICATION OF THE NEW EMAIL
so this injection works perfectly, and it doesn't skid because the one you use doesn't work at all LMAO


Skrollr Mobile Issue with Bootstrap Menu / Anchorlinks

Hey,
I hope I am right here.
Everything works fine with Skrollr, except on iOS when I tap a menu item. A manual #anchorlink in adressbar does the same.
The page scrolls down as usual, but then I can`t scroll up again? Any hints?
demo: http://bit.ly/1NSFAEm
Thanks!

Oh sorry, found it myself ;) https://github.com/Prinzhorn/skrollr-menu

But did it work ? I can not get any of the anchor demos with skrollr-menu to work on my El Capitain mac machine. Has anything changed?


Migration to 1.18: no analyzer with name or type 'keyword' registered

Description
After upgrading from 1.17.3 to 1.18.0, Gitea fails to start.
2023/01/13 08:17:55 [I] Log Mode: File(Debug)
2023/01/13 08:17:55 [I] XORM Log Mode: File(Debug)
2023/01/13 08:17:55 [I] Cache Service Enabled
2023/01/13 08:17:55 [I] Session Service Enabled
2023/01/13 08:17:55 [W] Notify Mail Service: Mail Service is not enabled
2023/01/13 08:17:55 [I] Beginning ORM engine initialization.
2023/01/13 08:17:55 [I] ORM engine initialization attempt #1/10...
2023/01/13 08:17:55 [I] ORM engine initialization successful!
2023/01/13 08:17:55 [I] Git Version: 2.30.2
2023/01/13 08:17:55 [...ules/indexer/repo.go:81 InitRepoIndexer()] [E] InitRepoIndexer: no analyzer with name or type 'keyword' registered

If I disable the indexer in app.ini, it goes a little further but stops again:
2023/01/13 08:07:31 [I] Log Mode: File(Debug)
2023/01/13 08:07:31 [I] XORM Log Mode: File(Debug)
2023/01/13 08:07:31 [I] Cache Service Enabled
2023/01/13 08:07:31 [I] Session Service Enabled
2023/01/13 08:07:31 [W] Notify Mail Service: Mail Service is not enabled
2023/01/13 08:07:31 [I] Beginning ORM engine initialization.
2023/01/13 08:07:31 [I] ORM engine initialization attempt #1/10...
2023/01/13 08:07:31 [I] ORM engine initialization successful!
2023/01/13 08:07:31 [I] Git Version: 2.30.2
2023/01/13 08:07:31 [I] SQLite3 Supported
2023/01/13 08:07:31 [I] Run Mode: Production
2023/01/13 08:07:31 [I] SSH server started on :22. Cipher list ([aes128-ctr aes192-ctr aes256-ctr<EMAIL_ADDRESS>arcfour256 arcfour128]), key exchange algorithms ([diffie-hellman-group1-sha1 diffie-hellman-group14-sha1 ecdh-sha2-nistp256 ecdh-sha2-nistp384 ecdh-sha2-nistp521 curve25519-sha256@libssh.org]), MACs<EMAIL_ADDRESS>hmac-sha2-256 hmac-sha1 hmac-sha1-96])
2023/01/13 08:07:31 [I] Listen: https://<IP_ADDRESS>:443
2023/01/13 08:07:31 [I] LFS server enabled
2023/01/13 08:07:31 [.../cmd/web_graceful.go:37 runHTTPS()] [E] Failed to load https cert file <IP_ADDRESS>:443: open : no such file or directory

Gitea Version
1.18.0
Can you reproduce the bug on the Gitea demo site?
Yes
Log Gist
No response
Screenshots
No response
Git Version
No response
Operating System
Debian 11
How are you running Gitea?
Gitea is launched by systemd in a Proxmox container
Database
SQLite

Removing /var/lib/giteadata/indexers solves the issue with the indexer.

Are you sure you are using 1.18? modules/indexer/repo.go does not exist.
The other error just tells you that a configured certificate was not found.

That file exists in Gitea 1.8 😉

/facepalm
I shouldn't upgrade Gitea before the morning cofee, sorry for the noise


Align of elements in background row

I want to align  elements of background to left side(right swipe) or right side (left swipe).
How can i do this?

https://github.com/wdullaer/SwipeActionAdapter#setfixedbackgroundsboolean-fixedbackgrounds

Thanks a lot!!!


Fix bugs in ONNXRT hf examples

Type of Change
bug fix
API bot change
Description
Fix bugs:

ONNXRT hf question answering examples failed with dataclasses.FrozenInstanceError: cannot assign to field do_eval
ONNXRT hf language modeling examples failed with AttributeError: 'Namespace' object has no attribute 'no_cuda'

Expected Behavior & Potential Risk
fix bugs
How has this PR been tested?
extension test
Dependency Change?
no

extension test


Python binding for explode Tiles with sampling

Sometimes exploding is slow and we just want to see a little bit of the data... in Python.

I'm going to submit a PR on this very soon.

PR is passing all checks now and ready for review, @bguseman @metasim


Changed single selection to multiple selection for Recent, OneDrive and Site Files tabs in FilePicker component

…s for FilePicker component

Q
A

Bug fix?
[ ]

New feature?
[x]

New sample?
[ ]

Related issues?
fixes #725

What's in this Pull Request?
The current version of the FilePicker doesn't support multiple selections for files.
I have changed the selection mode to multiple for Recent, OneDrive and Site Files tabs.
The folders cannot be selected but could be opened and multiple selections apply inside.

@MonalisaBaltatescu the PR is for the master branch, could you please update to target dev?

@joelfmrodrigues could this PR be closed and merged now that the target branch is master?

@MonalisaBaltatescu just tested the PR and it's great! Thank you for the improvements.
While testing it, I found just an error on the console when selecting folders (tested using the Site option):

Select a folder from a document library in a SharePoint site

The following error is logged:

This is the code generating the error (line 459):

Is this line required to handle folders? I tried to comment it and it seems to behave the same, although it could be because of the error not allowing it to behave the same way you expected.
Other than that, all looks good and ready to go ☺

Hi @MonalisaBaltatescu
just checking if you would be able to advise on the above?

Hi, I’m working on it. Just need more time ☺

@MonalisaBaltatescu I have no idea why the PR got closed. Going to re-open it.

@MonalisaBaltatescu sorry to chase you again with this, but just wondering if you need some help?

@joelfmrodrigues I am sorry for the delay, didn't have the time lately. Please check now and let me know if there are any other issues

@MonalisaBaltatescu many thanks for the update and absolutely no need to apologise as these are voluntary contributions - I am also having issues finding the time to contribute myself
I have tested it and all seems to be working fine, many thanks


approximate gpu usage

I tried running the code locally on my machine. I tried all different models available (for sd), but turns out my VRAM is not enought to test these. Can the authors maybe give few approximations for the resources required, or even share their system specifications used to train/inference the model.

Hello CodeGeek04,
To run the examples in the README, you need a Nvidia V100 GPU with 30GB of VRAM. But if you're not satisfied, you can set vpsd.n_particle=1, vpsd.vsd_n_particle=1 and phi_n_particle=1


Feature Request: onCaptionsToggled

Is there an existing issue for this?

[X] I have searched the existing issues

Which Mux Elements/Packages does this apply to? Select all that apply
mux-player-react
Description
Currently, we use video-js for our player and are looking to make the switch to the Mux player. It has all the current features we need except the ability for a callback to be passed in when captions are toggled on and off.
Expected Behavior
It would be ideal to have a callback similar to onRateChange or onPlay that would either:
Return a boolean value for captions activated or not.
Or
Return the track activated or undefined (when deactivated)

Hey @scmilee, having an easy to use in react event callback definitely sounds like a good idea/feature/improvement, given the acrobatics required for the refs. Our team has several things in the priority queue already, so not sure when we'll be able to get to this, but as a stopgap, let me know if this example of said acrobatics can hold you over in the interim: https://codesandbox.io/p/sandbox/gifted-david-vm71tz?file=%2Fsrc%2FApp.js


Document debugging tips

Problem
Using Windows when I'm a NixOS native, I was having permission issues. I fixed the problem by updating WSL.
Solution
wsl --update
I'm opening this issue to suggest documenting common pitfalls like this. Either as a section in the README or a seperate markdown file. At the very least this issue can now be found when troubleshooters search for 'permission'.
:clinking_glasses:

We definitely need more documentation. Other things I want to document once I get around to it:

[ ] How to change the username
[ ] How to access a rescue shell
[ ] How to rollback to a previous generation (especially through the rescue shell)

XDG_RUNTIME_DIR is where WSL puts the wayland socket

@nzbr any tips on:

How to rollback to a previous generation (especially through the rescue shell)

Asking for a friend 😅. I switched over to nativeSystemd on an existing system and now my /run/wrappers directory is missing and sudo is broken so I've soft-locked my system.

OK it looks like it is:
# From windows:
wsl -d NixOS  --user root -e /nix/var/nix/profiles/system/sw/bin/bash

# Now in root shell you can run commands without needing sudo
nixos-rebuild switch --rollback

OK it looks like it is:
# From windows:
wsl -d NixOS  --user root -e /nix/var/nix/profiles/system/sw/bin/bash

# Now in root shell you can run commands without needing sudo
nixos-rebuild switch --rollback

Just as a reminder to self one can always
export PATH=/nix/var/nix/profiles/system/sw/bin/:$PATH

... in case there are command missing errors in the spawn vm.

This issue has been mentioned on NixOS Discourse. There might be relevant details there:
https://discourse.nixos.org/t/set-default-user-in-wsl2-nixos-distro/38328/2


Understanding table output

Hi,
thanks for publishing this. Can I check I understand the output in the tables, please? The docid I’m assuming relates to a specific output from the model from a given prompt? And the token id is related to the prompt itself?

Apologies if these are simple questions. Interested in explainable AI more than the technical ins and outs.

docid is just an ID of the document from a dataset.  It is not a model output, most likely human-written from the internet
the token ID is just the index of the activated token.  for example if token was 0, it would mean that the first token had a positive activation


[fabric] Ansible decoupling for setup/vault_kubernetes role

Signed-off-by: mgCepeda<EMAIL_ADDRESS>Changelog

Add create/k8s_secrets role and vault_kubernetes chart
Update setup/vault_kubernetes role

Reviewed by
@suvajit-sarkar
@alvaropicazo
Linked issue
#1572

@all-contributors please add @mgCepeda for code


DSL Preview plugin: unable to see the layout preview

Hi! I'm trying to use the DLS Preview plugin in Android Studio. However, it show only the white background, not the preview, even when I use the refresh button. How to fix this?

What is a superclass of your Activity?

I've tried using a subclass of Fragment.

Duplicated by #33.


Doctrine can't read annotation

I described my issue hear: http://stackoverflow.com/questions/43794498/symfony-how-to-solve-the-doctrine-issue-of-the-missing-annotations/43825184#43825184
I think it's locale problem, but I can't find solution.

Closing: this is not a doctrine issue, but rather a configuration issue in a complex symfony setup. It needs to be isolated before we can look at it, sorry.


cors security feature

you can refer to https://spring.io/blog/2015/06/08/cors-support-in-spring-framework for extra info on this
webapp / browser blocks network calls on localhost because backend doesn't have CORS setup

Might need to do the same to the /auth/ endpoints too

@iannjari done ... for future endpoints we just need to add the @CrossOrigin before class declarations in the controllers


update changelog for v0.2.0 release

#17

Also adding a CODEOWNERS -- I did @ASFHyP3/tools but it could also be @ASFHyP3/testing? I think tools fits better. Probs should be devops really...


fix(curriculum): RPG - Step 41 - 42: Passing with wrong code

Checklist:

[x] I have read and followed the contribution guidelines.
[x] I have read and followed the how to open a pull request guide.
[x] My pull request targets the main branch of freeCodeCamp.
[x] I have tested these changes either locally on my machine, or GitPod.

Closes #53163

This is not what the issue is about. The tests should not allow for the functions to be invoked/called. Doing so will break the event handlers.
The parentheses () should not be allowed when assigning the handler functions.
Incorrect:
button1.onclick = goStore();
button2.onclick = goCave();
button3.onclick = fightDragon();

Correct:
button1.onclick = goStore;
button2.onclick = goCave;
button3.onclick = fightDragon;

Also, the element event attribute is onclick - all lowercase. You should not change that.

@lasjorg

Please remove the comments from the code.
I just noticed we do not actually test for the correct function name. As long as we match on the start of the function name you can put whatever you want after. So this will pass as well.
button1.onclick = goStoressss;

Also, thinking about this some more, we might want to create new tests specifically for the function invocations.
Maybe someone else will have some feedback on how best to handle this.

I will create a new test to check the name of the function for steps 41 and 42.

@lasjorg Can you please review my pull request.

We shouldn't require semicolons, as such they can't be used for the function name test.
The assert for the function name should be (replace the name and button as needed)

You should assign the goStore function reference to button1.onclick.

The assert for the function invocation should be (replace the name as needed):

You should not call the goStore function. Remove the parentheses.

Hey! So the test should pass without a semicolon; only then should it check the function name.
and have to change this from:
You should assign the goStore function reference to button1.onclick.
to:
You should not call the goStore function. Remove the parentheses.

Please make all the requested changes.
If the "Commit suggestion" button is still active that change wasn't made and still needs to be made. You can use the "Commit suggestion" button to add the code as well.

hey @lasjorg as per your suggestion I implemented assert.match(code, /button1\.onclick\s*=\s*goStore\s*;?\s*$/); method to check but the test fails if I provide this correct input button1.onclick = goStore; .


Added the ability to record a voicemail...

Which creates an incident within PagerDuty. This is used if there is no on-call engineer (or a phone number cannot be found) or if the on-call engineer doesn't answer the phone.
In addition, when the on-call engineer answers the phone, it prompts them to press 1 to accept. This is to prevent the case where a cell provider (or landline) sends the caller to voicemail before Twilio ends the call due to a timeout.
I've tested this all out on my own and everything seems to work great.

Awesome update.  Thank you!

I fixed a couple bugs within the code. The first being the session_ID when the page is accessed directly (for debugging purposes), the second being the announcement of the time of the on-call engineer and the third when the on-call engineer didn't have a contact phone number added to their account.
I also lowered the timeout when attempting to connect the caller to the on-call engineer back to the default 30 seconds.


Add Jupyter compatibility

Including ipykernel in the conda env enables this env to be discovered and used as a kernel for Jupyter notebooks. I'm not sure if Jupyter compatibility is enough of a priority to include this extra dependency in the default readme installation instructions. Thoughts?

Thanks, I included a note to that effect.


Bug: Mismatched types for Cairo context

Describe the bug
error[E0308]: mismatched types
   --> /home/rjzak/.cargo/git/checkouts/druid-64a54200c8cd3ebf/acfe799/druid-shell/src/backend/gtk/window.rs:523:58
    |
523 |                         let mut piet_context = Piet::new(&surface_context);
    |                                                          ^^^^^^^^^^^^^^^^ expected struct `cairo::context::Context`, found struct `cairo::Context`
    |
    = note: expected reference `&cairo::context::Context`
               found reference `&cairo::Context`
    = note: perhaps two different versions of crate `cairo` are being used?

To Reproduce
git pull
cargo build
Git commit hash: 338b60222493f0b3eb19ba7d0ef6f0c540ed30a8
Expected behavior
Clean build
Screenshots
See above for pasted output
Environment

OS: Linux
Version: Ubuntu 20.04, Kernel 5.4.0-100-generic

Additional context
Add any other context about the problem here.

Hi @rjzak, sorry about, should be fixed in master!


Add 13 by astronaut

Song Name
13
Artist Name
astronaut
Source
Youtube
Youtube Link
2zyH1A5fgyw
Direct File Link
No response
Song ID
597874
Start Offset [ms]
0
Extra
Created from Auto Nong.
Created for level: 6988264
Downloaded: Yes

accept

If it not work.. Its sad

Thanks for contributing! Someone will soon review your request.
Here is the JSON result for the reviewer:
{
  "name": "13",
  "artist": "astronaut",
  "source": "youtube",
  "startOffset": 0,
  "yt-id": "2zyH1A5fgyw",
  "songs": [
    597874
  ]
}

To accept the request, a reviewer needs to write "accept".

accept

Accept

Thanks for contributing! Someone will soon review your request.
Here is the JSON result for the reviewer:
{
  "name": "13",
  "artist": "astronaut",
  "source": "youtube",
  "startOffset": 0,
  "yt-id": "2zyH1A5fgyw",
  "songs": [
    597874
  ]
}

To accept the request, a reviewer needs to write "accept".

Accept


Fix DateTime64 nanos and scale

close #210

The issue should be fixed, but UT is missing (too late now - -) @gmxby
Actually, there has none UT for *DataType, only covered by IT indirectly, should we open another issue to add UT for all *DataType? @sundy-li

should we open another issue to add UT for all DataType

ok, we may need to modify GenericSimpleInsertITest.java


[v1] fix compilation cache

compilation cache is not working due to a bug, self.to_be_compiled_sizes should be self.compile_sizes.copy() rather than self.compile_sizes.union(self.capture_sizes) .
this should be merged after https://github.com/vllm-project/vllm/pull/11596 . our compilation cache does not consider the code change in the model's code.
before this pr:

Compiling a graph for general shape takes 12.69 s

After this pr:

Compiling a graph for general shape takes 2.27 s

cc @tlrmchlsmth how can we take all these code into consideration? like rope / activation etc.

our compilation cache does not consider the code change in the model's code.

I thought this would be handled by adding the version number here. Maybe we need to explicitly add the git hash as well?
https://github.com/vllm-project/vllm/blob/faef77c0d69c5429182f475a57127676e6bcb230/vllm/config.py#L3000

I thought this would be handled by adding the version number here. Maybe we need to explicitly add the git hash as well?

that would be kind of overkill, for the developers (like me), the git hash changes from time to time, and it means I cannot reuse any compilation cache.


NX_class name decoding error

I get this traceback when trying to open a file with silx view:
'utf-8' codec can't decode byte 0xb2 in position 1: invalid start byte   File "/Users/marius/Library/Python/3.7/lib/python/site-packages/silx/gui/hdf5/Hdf5TreeModel.py", line 515, in data
    return node.dataType(role)
  File "/Users/marius/Library/Python/3.7/lib/python/site-packages/silx/gui/hdf5/Hdf5Item.py", line 401, in dataType
    text = self.nexusClassName
  File "/Users/marius/Library/Python/3.7/lib/python/site-packages/silx/gui/hdf5/Hdf5Item.py", line 375, in nexusClassName
    self.__nx_class = str(self.__nx_class, "UTF-8")

The type of the self.__nx_class object is <class 'numpy.ndarray'>.

Independently of having to avoid the error, what program wrote that file?
strings
NX_CHAR: The preferred string representation is UTF-8. Both fixed-length strings and variable-length strings are valid. String arrays cannot be used where only a string is expected (title, start_time, end_time, NX_class attribute,…). Fields or attributes requiring the use of string arrays will be clearly marked as such (like the NXdata attribute auxiliary_signals).

Same issue as #2170
I'm sure that we discussed the issue, and I think it might be fixed in the current master, but I have not been able to find a related pull request or a commit.
Is it possible for you to send me the file so that I can try to replicate the issue?
Which version/branch of silx are you using?

I am using the current master. Here is the file https://cloud.esrf.fr/index.php/s/FyfLLfdMuT3wo2a.

Nevermind, I'm able to replicate the issue with another file.

Python 3:
In [1]: from silx.io import open as sopen

In [2]: f = sopen("oleg.dat")

In [3]: f.attrs["NX_class"][()]
Out[3]: 'NXroot'

In [4]: f.attrs["NX_class"]
Out[4]: array('NXroot', dtype=object)

In [5]: str(f.attrs["NX_class"])
Out[5]: 'NXroot'

In [6]: str(f.attrs["NX_class"], "UTF-8")
---------------------------------------------------------------------------
UnicodeDecodeError                        Traceback (most recent call last)
<ipython-input-6-41890cb849f6> in <module>()
----> 1 str(f.attrs["NX_class"], "UTF-8")

UnicodeDecodeError: 'utf-8' codec can't decode byte 0xe8 in position 0: invalid continuation byte

In [7]: str(f.attrs["NX_class"][()], "UTF-8")
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-7-1bc6f55ab70f> in <module>()
----> 1 str(f.attrs["NX_class"][()], "UTF-8")

TypeError: decoding str is not supported

In [8]: type(f.attrs["NX_class"][()])
Out[8]: str

It seems normal, no? One can decode bytes but one cannot decode strings.

So the type column in silx view should display the NeXus type or the type of Python object?

There are some issues with the humanReadableValue method. Traceback for a NeXus file created using this tutorial http://download.nexusformat.org/doc/html/examples/h5py/index.html.
ERROR:silx.gui.qt._qt:<class 'AttributeError'> 'str' object has no attribute 'shape'   File "/Users/marius/Library/Python/3.7/lib/python/site-packages/silx/gui/hdf5/Hdf5TreeModel.py", line 515, in data
    return node.dataType(role)
  File "/Users/marius/Library/Python/3.7/lib/python/site-packages/silx/gui/hdf5/Hdf5Item.py", line 398, in dataType
    text = self.nexusClassName
  File "/Users/marius/Library/Python/3.7/lib/python/site-packages/silx/gui/hdf5/Hdf5Item.py", line 371, in nexusClassName
    text = self._getFormatter().humanReadableValue(obj)
  File "/Users/marius/Library/Python/3.7/lib/python/site-packages/silx/gui/hdf5/Hdf5Formatter.py", line 99, in humanReadableValue
    if dataset.shape is None:

Thanks for testing. Now it should also work for attributes written as unicode nxentry.attrs[u'NX_class'] = u'NXentry'

That in addition it is the recommended way in order to avoid different readout when using python2 or python3.


Update Graphstore to make proper use of SQLite.

My apologies, this is going to be a bit of a brain dump, is is not completely finalized in my head, my SQL vocabulary is also limited.
The goal of the graphstore is to keep tracks of references between "pages", though we want to keep in mind that a page may have multiple version, so many of the sql recipe you find online won't work.
My thought are the following:

A source document can be represented by a 4-tuple key: (package, version, category, identifier)
A destination document can be represented by a 3-tuple (package, category, identifier). No version as generally when say scipy reference numpy it does not link to a particular version...
A link is a 2 tuple (source,destination), but let's make it a 3 tuple (source, destination, metadata).

I'd like to have a way to insert a document into the graphstore/sql, that make it easy to keep things coheremt, so I'm thinking
3 tables:
SOURCE, DEST, LINKS

Source with source key primary id, and package, version, category, identifier
Dest with dest key primary id package, category, identifier
And Link with Foreign key to source, Foreign key to id and a 3rd metadata field.

Now I'm not super familiar with SQL but: is there a ways to go garbage collection on DEST ? That is to say that if nothing in the Link table refers to it it's culled ?
And what would the API to insert objects into it look like ? Do I have to do three operations on Source/Dest/Link when inserting a list of references ? can I "insert if does not exists or otherwise  do nothing and return the primary id" ?

Now I'm not super familiar with SQL but: is there a ways to go garbage collection on DEST ? That is to say that if nothing in the Link table refers to it it's culled ?

SQLite doesn't enable procedures or functions that modify the database, we can only create functions that add new registers but cannot modify/delete existing entries. So the answer is that we will need a script that runs periodically checking for non-existing links. The other alternative is to use another database management system that allows us to create procedures, I'm still navigating how things are working right now so I prefer not to mention any particular system yet.

And what would the API to insert objects into it look like ? Do I have to do three operations on Source/Dest/Link when inserting a list of references ?

That's easy, you just need to create a cursor in Python and create a layer that is able to communicate to the db. The idea of this cursor is to just write normal SQL queries such as INSERT XYZ .... And yes, you will need to do one operation per table and they have to be in order. So if the link table has two foreign keys, then you will need to first insert in the source and dest tables before adding a new entry to the link table.

can I "insert if does not exists or otherwise do nothing and return the primary id" ?

Given that is a relational db, you will have an error when trying to insert things that are not following the structure of the tables. However, you can handle that error as needed.
Hope this helps! The structure of the database that you are currently thinking seems fine to me as well :)

So the answer is that we will need a script that runs periodically checking for non-existing links.

Well we can make this part of the Python API.

The other alternative is to use another database management system that allows us to create procedures, I'm still navigating how things are working right now so I prefer not to mention any particular system yet.

That is a no-no, we can't have a server, it has to be something that is Python installable and does not run in the background.
Yes, I know you would get an error, I was wondering if you can use a varaiation of UPSERT, or if you need to do a query and an insert after.

Well we can make this part of the Python API.

That sounds like a good plan!

Yes, I know you would get an error, I was wondering if you can use a varaiation of UPSERT, or if you need to do a query and an insert after.

Indeed, you need to do a query and insert after

While I was working on actually writing the schema I realized we can make this with just two tables,

documents that stores the information of each package as key primary id, and package, version, category, identifier
links that stores source, dest, metadata

In this way the garbage collection from dest just by removing a link rather than having an other table and having to update all the others. I'm going to investigate if there's a way to have a cascade drop, in which if a package is removed from the documents table then all the entries that point to it in the links table will be removed.

I'm closing this issue because it is fixed in #98

I realized we can make this with just two tables

That was my original thought, but you can have two kind of link:

to a particular version
to any version.

Also, we might have a link to a document that does not exist (yet).
So imagine that (scipy, module, 1.8, scipy.special) want to link to "any" numpy array, you would get a (numpy, module, *, numpy.array) in destination, which is not a particular document.
Of course it is not implemented so you couldn't have guessed, or maybe there is another way to do it with only two tables I don't see ?
Questions for cascade, I guess the deletion happens when the last foreign key is removed, is that right ?


KAFKA-15816: Fix leaked sockets in streams tests

These tests leak sockets via Kafka clients, either directly or via KafkaStreams instances. The tests should close these resources when appropriate.
Committer Checklist (excluded from commit message)

[ ] Verify design and implementation
[ ] Verify test coverage and CI build status
[ ] Verify documentation (including upgrade notes)

The streams test failures appear unrelated, as they are not subclasses of the changed tests, and all streams tests pass locally.


Timestamp Optional

Added the option to generate a timestamp when creating a soap client.  Also added a new test in  request response sample to test this option.

Thanks a lot for your time and effort @jayharper :+1:
In order to get your PR merged, please squash your commits like pointed out in our Guidelines on Submitting a Pull Request.

My apologies for not squashing to a single commit originally.

Looks good @jayharper !  :+1: from me @herom

I just addressed some concerns I had regarding the newly introduced options Object. That's just my 2 cents but I think this would be not also a "nice to have" but also a "must have" if we "break" the constructor like this. :smile_cat:

Somehow I was not able to fork your repo and create a PR there, so here's the snippet for the WSSecurity constructor, I hope this helps :smiley:
"use strict";

var crypto = require('crypto');
var passwordDigest = require('../utils').passwordDigest;
var validPasswordTypes = ['PasswordDigest', 'PasswordText']; // <-- this is new!

function WSSecurity(username, password, options) {
  options = options || {};
  this._username = username;
  this._password = password;

  //must account for backward compatibility for passwordType String param as well as object options defaults: passwordType = 'PasswordText', hasTimeStamp = true
  if (typeof options === 'string') {
    this._passwordType = options ? options : 'PasswordText';
  } else {
    this._passwordType = options.passwordType ? options.passwordType : 'PasswordText';
  }

  if (validPasswordTypes.indexOf(this._passwordType) === -1) {
    this._passwordType = 'PasswordText';
  }

  this._hasTimeStamp = options.hasTimeStamp || typeof options.hasTimeStamp === 'boolean' ? !!options.hasTimeStamp : true;
}

@herom thanks for cleaning this up :thumbsup:.  I have incorporated your changes and we should now be good to go.

Thanks a ton :+1: :dancers:

:dancers:


Add documentation for getseedblocks, getcurrentconsensushash, setautocommit

Currently there is no RPC API documentation for the following calls:

omni_getseedblocks
omni_getcurrentconsensushash
omni_setautocommit

Even though these are not really end-user calls, we should eventually document them.

Ack, will do :)

This is roughly what I had in mind. The help texts should be adjusted (e.g. blockhash is missing for omni_getcurrentconsensushash). I'll push a PR later. :)
...

omni_getseedblocks
Returns a list of blocks containing Omni transactions for use in seed block filtering.
WARNING: The Exodus crowdsale is not stored in LevelDB, thus this is currently only safe to use to generate seed blocks after block 255365.
Arguments:

Name
Type
Presence
Description

startblock
number
required
the first block to look for Omni transactions (inclusive)

endblock
number
required
the last block to look for Omni transactions (inclusive)

Result:
[         // (array of numbers) a list of seed blocks
  nnnnnnn,  // the block height of the seed block
  ...
]

Example:
$ omnicore-cli "omni_getseedblocks"<PHONE_NUMBER>00

omni_getcurrentconsensushash
Returns the consensus hash covering the state of the current block.
Arguments:
None
Result:
{
  "block" : nnnnnn,         // (number) the index of the block this consensus hash applies to
  "blockhash" : "hash",     // (string) the hash of the corresponding block
  "consensushash" : "hash"  // (string) the consensus hash for the block
}

Example:
$ omnicore-cli "omni_getcurrentconsensushash"

Configuration
The RPCs for the configuration can be used to alter Omni Core settings.
omni_setautocommit
Sets the global flag that determines whether transactions are automatically committed and broadcasted.
Arguments:

Name
Type
Presence
Description

flag
boolean
required
the flag

Result:
true|false  // (boolean) the updated flag status

Example:
$ omnicore-cli "omni_setautocommit" false

Ahh perfect, thanks dude - saved me a job hehe :)


Dialogs: it would be nice if cancelling a dialog closed the dialog reference with an undefined result instead of 'canceled'

@angular-mdc/web version: 0.37.1
If I pop a dialog to prompt the user for a string value of some sort and they dismiss it (e.g. by hitting ESC), how will I know they didn't type 'canceled'?
export class MdcDialogComponent ... {
...
  private _mdcAdapter: MDCDialogAdapter = {
    ...
    notifyCancel: () => {
      this._cancel.emit();
      this._closeDialogRef('canceled'); // Maybe just this._closeDialogRef() ?
    },
    ...
  }
  ...
}

@ibelenski Absolutely agree. Making that change.


Fortio: fixing missing Host: header debug output and a typo

/lgtm
/release-note-none

@yutongz can we turn on automerge for this repo too ?

Mungegithub is running on istio. It must be a problem. I will look at it.