Add transitions to validation messages console warning

Reproduction
https://formkit.link/ff768a042681afaa932cce9690dd3bfc
Describe the bug
Add transitions to validation messages
[Vue warn]: Vue received a Component which was made a reactive object. This can lead to unnecessary performance overhead, and should be avoided by marking the component with markRaw or using shallowRef instead of ref.
Environment
• OS: [e.g. iOS]
• Browser [e.g. chrome, safari]
• Version [e.g. 22]

If you globally register the TransitionGroup component and then reference by name rather than passing it in directly you can bypass this warning.
https://formkit.link/ce9fe931562fbdb318cd172492cc13d8


"Paltenu", "Păuleni" are listed in the drop-down menu

Description:
When user writes "Paltenu" and "Păuleni" the locations appear in the drop-down menu next to the comune and the county witch is a part according to the law
Precondition:
The website is up an running.

Step 1
Write in the search bar "Paltenu"

Expected results
The location appears in the drop-down menu as "Sat Paltenu, ARGEȘ (Șuici)"

Step 2
Press "x" button.

Expected results
The location was deleted from the search bar.

Step 3
Write in the search bar "Păuleni"

Expected results
The location appears in the drop-down menu as "Sat Păuleni, ARGEȘ (Șuici)"


Magento 2 shared file pub/index.php not working as expected

Deployer version: 7.0.2
Deployment OS: debian

I added pub/index.php as a shared file among others. All others do work excecpt for this one. When I check it while the deploy is going on, I see the symlink is created, but when deploy is finished it is gone. Why is this? And how can I fix it?
namespace Deployer;

require_once 'recipe/magento2.php';

// Config

set('repository', 'repo.url');
set('static_content_locales', 'en_US nl_NL de_DE');
set('magento_themes', ['Client/default', 'Magento/luma', 'Magento/backend']);
add('shared_files', [
    '.htaccess',
    'app/etc/env.php',
    'pub/.htaccess',
    'pub/index.php'
]);
add('shared_dirs',[]);
add('writable_dirs', []);

// Hosts

// Staging server
host('staging url')
    ->set('labels', ['stage' => 'staging'])
    ->set('http_user', 'client')
    ->set('remote_user', 'client')
    ->set('port', '22')
    ->set('deploy_path', '/usr/www');

// Tasks

task('build', function () {
    cd('{{release_path}}');
});

after('deploy:failed', 'deploy:unlock');

@antonmedv any ideas?

@Aquive why would you add pub/index.php to the shared files? That file is automatically copied from vendor to that location by composer becauase of the mapping in magento/magento2-base (see vendor/magento/magento2-base/composer.json:488).

@peterjaap thanks for your answer! I guessed this was the problem already.
Yeah, I know. It's a weird one. Short answer: client insist on it. He wants to be able to put storeview specific things (like magerun code based on domains) in it. It is set up this way. Although moving it to its appropriate place would be better.
Would it be even possible? If not, we have to change the setup, so it adheres best practices.

@peterjaap Don't tell me you didn't come across weird setups ;)
The problem is that it should symlink to the pub/index.php in the shared folder. But I could use the same tactic for it right? rm pub/index.php && ln -s ../../shared/pub/index.php pub/index.php from the top of my head.
Thanks for the tip.

@Aquive I have, that's why I know these tricks :rofl:
But yes, same tactic, different command :)


ie strict mode

I am getting an error in IE, multiple definitions of a property is not allowed in strict mode
the line it errrors on looks like this:
presence: true
presence:
  message: 'my custom message'

not sure the best way to handle this. but essentially declaring presence as a property twice doesn't look like it is going to work.

Hey guys. Any update on this ? I am getting same error on IE 11.

If you pass an object to presence is is assumed true:
presence: true

is equal to
presence: {
  message: 'my custom message'
}

but the 2nd allows you to override the message.

Sorry I missed this when it originally opened.


Correction ms_to_frames/frames_to_ms/ms_to_str

Currently ms_to_frames and frames_to_ms does not works correctly. They can be imprecise.
I did a pullrequest on the PyonFx repos and I think it could be a good idea to do something similar with pysubs2: https://github.com/CoffeeStraw/PyonFX/pull/46
I recommand you to look at these two file of my PR. These are the only one that matters for pysubs2.

pyonfx/convert.py
pyonfx/timestamps.py

In brief, here is all the method I propose to change:

ms_to_str, should add this little part for the .ass and .saa format: ass_ms = (ass_ms + 5) - (ass_ms + 5) % 10

ms_to_frames(Current version) should be something like this: ms_to_frames

frames_to_ms (Current version) should be something like this: frames_to_ms- Corrected version

Hi @moi15moi, thanks for reaching out!
I see that Aegisub does proper rounding for the millisecond to centisecond conversion: https://github.com/Aegisub/Aegisub/blob/6f546951b4f004da16ce19ba638bf3eedefb9f31/libaegisub/include/libaegisub/ass/time.h#L32
While pysubs2 currently always rounds down: https://github.com/tkarabela/pysubs2/blob/master/pysubs2/substation.py#L147
I agree that we should round like Aegisub does when writing SSA/ASS timestapms, which is responsibility of SubstationFormat.ms_to_timestamp().
As for the general routines in time.py, I'm not sure they have anything to do with it? The library generally works with milliseconds, and SubStation is the only format that needs centiseconds, IIRC.

As for the general routines in time.py, I'm not sure they have anything to do with it? The library generally works with milliseconds, and SubStation is the only format that needs centiseconds, IIRC.

If you are talking about ms_to_frames/frames_to_ms, here is an example.
import bisect
from enum import Enum
from fractions import Fraction
import sys
from typing import Tuple, Union, List

def pysubs2_frames_to_ms(frames: int, fps: float) -> int:
    return int(round(frames * (1000 / fps)))

def pysubs2_ms_to_frames(ms: int, fps: float) -> int:
    return int(round((ms / 1000) * fps))

def create_timestamps_from_fps(
    fps: Union[int, float, Fraction], n_frames: int
) -> List[int]:

    timestamps = [round(frame * 1000 / fps) for frame in range(n_frames)]
    return timestamps

class TimeType(Enum):
    EXACT = "EXACT"
    START = "START"
    END = "END"

def ms_to_frames(
    timestamps: List[int], ms: int, time_type: TimeType = TimeType.EXACT
) -> int:

    if not isinstance(time_type, TimeType):
        raise TypeError(f'Unknown time_type "{time_type}" provided.')

    if time_type == TimeType.START:
        return ms_to_frames(timestamps, ms - 1) + 1
    elif time_type == TimeType.END:
        return ms_to_frames(timestamps, ms - 1)

    denominator, numerator, last = get_den_num_last(timestamps)
    if ms < 0:
        return int(int(ms * numerator / denominator - 999) / 1000)
    elif ms > timestamps[-1]:
        return int(
            int((ms * numerator - last + denominator - 1) / denominator) / 1000
        ) + (len(timestamps) - 1)

    return bisect.bisect_right(timestamps, ms) - 1

@staticmethod
def frames_to_ms(
    timestamps: List[int], frame: int, time_type: TimeType = TimeType.EXACT
) -> int:

    if not isinstance(time_type, TimeType):
        raise TypeError(f'Unknown time_type "{time_type}" provided.')

    if time_type == TimeType.START:
        prev_frame = frames_to_ms(timestamps, frame - 1)
        curr_frame = frames_to_ms(timestamps, frame)
        return prev_frame + int((curr_frame - prev_frame + 1) / 2)
    elif time_type == TimeType.END:
        curr_frame = frames_to_ms(timestamps, frame)
        next_frame = frames_to_ms(timestamps, frame + 1)
        return curr_frame + int((next_frame - curr_frame + 1) / 2)

    denominator, numerator, last = get_den_num_last(timestamps)
    if frame < 0:
        return int(frame * denominator * 1000 / numerator)
    elif frame > (len(timestamps) - 1):
        frames_past_end = frame - len(timestamps) + 1
        return int(
            (frames_past_end * 1000 * denominator + last + int(numerator / 2))
            / numerator
        )

    return timestamps[frame]

def get_den_num_last(timestamps: List[int]) -> Tuple[int, int, int]:

    denominator =<PHONE_NUMBER>
    numerator = int((len(timestamps) - 1) * denominator * 1000 / timestamps[-1])
    last = (len(timestamps) - 1) * denominator * 1000

    return denominator, numerator, last

def main():
    fps = Fraction(24000, 1001)
    timestamps = create_timestamps_from_fps(fps, 1000)

    print(f"TimeType.START: {frames_to_ms(timestamps, 500, TimeType.START)}")
    print(f"TimeType.EXACT: {frames_to_ms(timestamps, 500, TimeType.EXACT)}")
    print(f"TimeType.END: {frames_to_ms(timestamps, 500, TimeType.END)}")

    print(f"pysubs2_frames_to_ms: {pysubs2_frames_to_ms(500, fps)}")

if __name__ == "__main__":
    sys.exit(main())

It print
TimeType.START: 20833
TimeType.EXACT: 20854
TimeType.END: 20875
pysubs2_frames_to_ms: 20854

Like you can see, pysubs2_frames_to_ms return the same value as TimeType.EXACT.
But, there is 3 type of timing. Start, Exact, End.
The exact is the timestamps of the frame.
The start is the timestamps of the needed frame and the previous frame divided by two.
The end is the timestamps of the needed frame and the next frame divided by two.
Example:
You want to have a subtitle that only appear at the frame 500.
Like any line, you need to set an start time and a end time.
If you set the start_time and a end_time with the TimeType.EXACT, the subs won't appear since it would have a duration of 0ms.
This is why you need to use the TimeType.START and the TimeType.END.
I know that pysubs2 also support format like srt, webvtt, etc that are in milliseconds. I am not 100% sure if the algorith I propose works for these format, but it should works.

I think I understand better what you mean now!
To be honest, I've only ever used the library for batch shifting, format conversion, copying styles around, etc. - never for frame-perfect typesetting or karaoke where exact interpretation of timestamps would be relevant. On the other hand, this seems to be the main focus of the https://github.com/CoffeeStraw/PyonFX library you mentioned.
In my experience, subtitle formats (except perhaps OpenVTT and similar "official" stuff) are very poorly defined, so it ends up being dependent on the exact player/rendering library used for playback. You noted there is difference between ASS and SRT in mpv.
While I can see the use for a thing like ms_to_frames_for_srt(..., time_type=TimeType.START), I'm not really sure where it fits in the current API, and I'm certainly not the person to write documentation and tutorial on how to use it... So I'm not sure where to go with this :)

So I'm not sure where to go with this :)
When we use pysubs2 to convert any format to an another format, in my opinion, it should be frame perfect.

Yes, there are a lot of subtitle format where the spec aren't well defined, but if pysubs2 respect what mpv does, i think it is better than nothing.

@tkarabela
I thought about it and found a way to achieve accurate time conversion of subtitles regardless of format.
I think it would even be possible to implement it in pysubs2.
Here is what I have done: https://gist.github.com/moi15moi/9b68589e6df0a76efbd01693c6c6f2ff

@tkarabela What do you think about my previous message?

Hi @moi15moi , thank you for the code :) I'm somewhat busy at the moment, I'll probably get to it over the weekend.

@moi15moi I've looked at the code and it looks good to me (thanks for including the docstrings and tests!). As the next step I suggest that I create a new branch in this repo, put your code in there and integrate it with the rest of the library, and then we can make a review and decide if it's ready for release or more work is needed.
If all goes well I think it could be released before end of the year :)

I don't really know where to add it properly.
I thought about time.py, but since the new class I proposed contain frames_to_ms and ms_to_frames method, we need to change all the code where they are used.
I think think they are only used here:

https://github.com/tkarabela/pysubs2/blob/ff91d35cbe934df30c058b346b01a745a8e9d8ed/pysubs2/microdvd.py#L83
https://github.com/tkarabela/pysubs2/blob/ff91d35cbe934df30c058b346b01a745a8e9d8ed/pysubs2/microdvd.py#L46
https://github.com/tkarabela/pysubs2/blob/ff91d35cbe934df30c058b346b01a745a8e9d8ed/pysubs2/time.py#L36

Should we replace the parameter fps by an Timestamps?

I was thinking about something like this:
import pysubs2
import os.path

def snap_to_frames(subs: pysubs2.SSAFile, format_: str, ts: pysubs2.Timestamps):
    for e in subs:
        old_start_ms = e.start
        old_end_ms = e.end
        start_frames = ts.ms_to_frames(old_start_ms, format_, pysubs2.TimeType.START)  # not sure if we want START or END in these
        end_frames = ts.ms_to_frames(old_end_ms, format_, pysubs2.TimeType.END)
        new_start_ms = ts.frames_to_ms(start_frames, pysubs2.TimeType.START)
        new_end_ms = ts.frames_to_ms(end_frames, pysubs2.TimeType.END)
        e.start = new_start_ms
        e.end = new_end_ms

# this code would be incorporated into pysubs2.SSAFile.save()
def new_save(subs: pysubs2.SSAFile, path: str, ts: Optional[pysubs2.Timestapms]):
    subs = subs.copy()

    # when saving, we already know the target format
    ext = os.path.splitext(path)[1].lower()
    format_ = pysubs2.formats.get_format_identifier(ext)

    # new part: snap subtitles to frames according to timestamps
    if ts:
        snap_to_frames(subs, format_, ts)

    # save subtitles as usual
    subs.save(path)

ts = pysubs2.Timestamps.from_video_file("video.mkv")
subs = pysubs2.load("subs.srt")

new_save(subs, "subs.ass", timestamps=ts)

This would make sure that timestamps are properly "snapped" to timestamps in the output file, while requiring little modification to other code. Would that be useful?
I see that going further and allowing something like:
ts = pysubs2.Timestamps.from_video_file("video.mkv")
subs = pysubs2.load("subs.srt")
subs.shift(frames=5, timestamps=ts)  # <---

...is problematic if the frames/ms conversion needs to know output format, since we don't know that in pysubs2. The SSAFile class is based on the assumption that the subtitles are something like .ass with millisecond timestamps. While what your Timestamp class would ideally require is a subtitle class that uses frames instead of milliseconds, and is fixed to a given output format.
In the command line interface (python -m pysubs2 ...) we can do better since that requires specifying output format.
On a more general note, what are the use-cases for what Timestamps class provides?

karaoke / effects where one wants to work with frame precision?
converting eg. SRT -> ASS for VFR video?
time shifting subtitles for VFR video?

I'm thinking about how to best support it, given that the library wasn't designed for it: for the karaoke/fx use-case which is going to involve a lot of custom scripting anyway, I think even providing the Timestamps class as-is would be useful. For more casual use like converting subtitle formats, it could be put in the CLI and perhaps as a special method like snap_to_frames() above, with mention in the tutorial on how to use it.
P.S. Sorry for the late reply, I didn't get around to do it during the holidays.

This would make sure that timestamps are properly "snapped" to timestamps in the output file, while requiring little modification to other code. Would that be useful?

Not really, the timing does not need to be "snapped" to the frame when saving it, so I don't see the utility to snap_to_frames.

While what your Timestamp class would ideally require is a subtitle class that uses frames instead of milliseconds, and is fixed to a given output format.

The timestamps class has no use if the subtitle timing are already in frame!

On a more general note, what are the use-cases for what Timestamps class provides?

karaoke / effects where one wants to work with frame precision?

Exactly, but it isn't necessarily only usefull for karaoke/effect.
With keyframe and this new "module", we can verify if our timing isn't too bad by checking that our timing does not overlap the keyframe.
We may need to provide a method to get the keyframe, but this is an another subject.

converting eg. SRT -> ASS for VFR video?

This method allow to have a perfect timing when converting an .srt to an .ass file.
Currently, there may be a 1 frame difference between the original file (srt) and the converted one (.ass) on any kind of video (CFR and VFR).
But, when converting an .ass to an .srt, there isn't some kind of "error".
It can only happen when converting an subtitle format that has an higher timing precision (ex: milliseconds) to an subtitle format that has an lower timing precision (ex: centiseconds)

time shifting subtitles for VFR video?

Not necessarily a VFR video. It is also usefull with CFR video since the current algorithm does not always work (if you need example, ask it and I will provide you some).
There may be some other use case, but these are clearly the most important one.

Thanks, I see. If you have any examples, that would be helpful :) Feel free to link them here or send me an e-mail to tkarabela at seznam dot cz.
The conversion from SRT -> ASS should be improved as of version 1.6.0 of the library after this commit: https://github.com/tkarabela/pysubs2/commit/2725c0a000f4ad5cc9255e262743ee6c2681da5f

The conversion from SRT -> ASS should be improved as of version 1.6.0 of the library after this commit: 2725c0a

This isn't really a magic method that make the conversion working.
Before explaining why it does not, here is an reminder of possible value an time can have for an particular frame:

Start time: ]Previous image, Current image]
End time: ]Current image, Next image]

Let's suppose we have those timestamps (these are the timestamps for an 24000/1001 fps video with 6 images).
Image 0: 0 ms
Image 1: 42 ms
Image 2: 83 ms
Image 3: 125 ms
Image 4: 167 ms
Image 5: 209 ms

Possible start time for the image 3: ]83, 125] = [84, 125]

If we have 84 ms and we floor it, it give 80 ms which is the image 2, so we can't use it.
If we have 84 ms and we round it, it give 80 ms which is the image 2, so we can't use it.
If we have 84 ms and we ceil it, it give 90 ms we can use it because it is in the range we found.
But, if we have 125 ms and we ceil it, it give 130 ms which is the image 4, so we can't use it.

 This is why we need to have the timestamps information to know how to properly convert the milliseconds into centiseconds while conversing the exact frame timing.
Why is the shifting with frame does not work well.
I think the best is to give you an example: Example bad shift frame.zip
The input file is the srt file and the output is the ass file.
Like you can see, the subtitle start at the frame 2.
If I shift it by one frame, it appear on the frame 4 (but it shoud have been the frame 3), so there is a problem
Even if you floor or ceil the result, there will always be edge case that will cause problem.
Example why floor does not work.
Start time is 84 ms which correspond to frame 3.
The method return me 126 ms, but if I floor it, it give me 120 ms which is also frame 3.
Example why rounding does not work.
Start time is 83 ms which correspond to frame 2.
The method return me 125 ms, but if I round it, it give me 130 ms which is also frame 4.
Example why ceil does not work.
Start time is 83 ms which correspond to frame 2.
The method return me 125 ms, but if I ceil it, it give me 130 ms which is also frame 4.
Why frames_to_ms need to know the output format
I just realised we don't need it since I take an average of the 2 extreme value (for start time average of Previous image and Current image, for end time average of Current image and Next image) and you round the result when saving the .ass file.
This make the rounding perfectly working with any kind of subtitle format :)
But, this mean this rounding need to be implemented into all format that cannot represent milliseconds.

Remaining problem
I would need to have the TimeType in the method make_time https://github.com/moi15moi/pysubs2/blob/f9ea3c5863e795d37ce6e93f9fc2db9e8dab94b8/pysubs2/time.py#L44

I agree, we need an additional parameter with default value TimeType.START (so that output of make_time(frame=1234, fps=23.976) stays the same as in the current version).

Let's suppose we have those timestamps (these are the timestamps for an 24000/1001 fps video with 6 images).
Image 0: 0 ms
Image 1: 42 ms
Image 2: 83 ms
Image 3: 125 ms
Image 4: 167 ms
Image 5: 209 ms

Possible start time for the image 3: ]83, 125] = [84, 125]
* If we have 84 ms and we **floor** it, it give 80 ms which is the image 2, so we can't use it.

* If we have 84 ms and we **round** it, it give 80 ms which is the image 2, so we can't use it.

* If we have 84 ms and we **ceil** it, it give 90 ms we can use it because it is in the range we found.
  But, if we have 125 ms and we ceil it, it give 130 ms which is the image 4, so we can't use it.

 This is why we need to have the timestamps information to know how to properly convert the milliseconds into centiseconds while conversing the exact frame timing.

I think I finally get it ^^; I've made a test .mp4 file with frame information both in the video and in SRT subtitles, which match perfectly. Just converting this SRT file to ASS using the current version of the library messes up the timing and many subtitles are 1 frame off, as you explain.
This undesirable behaviour should be fixed by the snap_to_frames() function I suggested above.
The test data is here: pysubs2_timestamps_test.zip

So, how to make the shifting works?
With what I proposed, you need to call ms_to_frame, then shifting the frame and finally call the method frame_to_ms.

Let's have a look what may be happening:

CFR video, subs.shift(frames=...)

you suggest: call ms_to_frame, add frames, frame_to_ms
I suggest: just add duration in milliseconds, as we do now (to shift by 1234 frames, do e.start += make_time(frame=1234, fps=23.976), etc.) and handle the frame-aware rounding when saving, using snap_to_frames()

CFR video, subs.shift(s=...)

I think this makes sense as-is, ie. just add whatever the user specifies to the stored milliseconds
in reality, one can only achieve shift in discrete steps (+1 frame, etc.), so that shift by ms=100 is really a shift by ms=83 or ms=125 (to use your example)
I would like to handle this when saving and not sooner, if possible

VFR video, subs.shift(frames=...)

IMHO this doesn't make sense and ideally should raise an exception

VFR video, subs.shift(s=...)

I think this makes sense as-is, ie. just add whatever the user specifies to the stored milliseconds

As I understand it, doing the ms_to_frame -> frame_to_ms round-trip (which is what my snap_to_frames does) only needs to happen when we want to know the timestamps in reduced precision, ie. when saving the file to something like ASS.

I just realised we don't need it since I take an average of the 2 extreme value (for start time average of Previous image and Current image, for end time average of Current image and Next image) and you round the result when saving the .ass file.

Yes, this is a good trick. One consequence is that this kind of "rounding" will in practice subtly shift most timestamps (eg. a subtitle that used to start at 0:00:00.00 will now be something like 0:00:00.02), which may be somewhat confusing. The previous format-aware method would effectively just round the last digit up or down for timestamps where it is relevant.

The test data is here: pysubs2_timestamps_test.zip

The file test_video.mp4 is a bit strange since it doesn't round the timestamps.
Ex: for the image 1, it should be 42 ms, not 41 ms.
You can try it by making the srt file start at 42 ms and you will see that it is still displayed on the image 1.
But, if it helped you understand the current issues, that's great.

CFR video, subs.shift(frames=...)

I suggest: just add duration in milliseconds, as we do now (to shift by 1234 frames, do e.start += make_time(frame=1234, fps=23.976), etc.) and handle the frame-aware rounding when saving, using snap_to_frames()

This will cause the same problem has the current shifting since the e.start/end can be anything.
Even if e.start/end is snapped to the frame, it does not always works.
Example where the fps = 93, the end_time correspond to the frame 37 and we want to shift the end_time by 1 frame.
from pysubs2 import Timestamps, TimeType, make_time

def round_timing(ass_ms):
    """
    From https://github.com/Aegisub/Aegisub/blob/6f546951b4f004da16ce19ba638bf3eedefb9f31/libaegisub/include/libaegisub/ass/time.h#L32
    """
    return (ass_ms + 5) - (ass_ms + 5) % 10

fps = 93
timestamps = Timestamps.from_fps(fps)

end_frame = 37
# end_ms is snapped to the frame
end_ms = timestamps.frames_to_ms(end_frame, TimeType.END)

# I do like you said
end_ms += make_time(frames=1, fps=fps)

# Since .ass does not handle milliseconds, I "round" it
end_ms = round_timing(end_ms)
print(f"Expected result: {end_frame + 1}")
print(f"Result: {timestamps.ms_to_frames(end_ms, TimeType.END)}")

Output (Like you can see, it doesn't work)
Expected result: 38
Result: 39

In my opinion, this is why the method ms_to_frame -> frame_to_ms -> ms_to_frame is better.

2. CFR video, subs.shift(s=...)

I think this makes sense as-is, ie. just add whatever the user specifies to the stored milliseconds

I am 100% agree. We should not "invoke" anything relied with Timestamps.

3. VFR video, subs.shift(frames=...)

IMHO this doesn't make sense and ideally should raise an exception

I don't see why it should raise en exception.
Sometimes, I shift subtitles that are timed with a VFR video in frame and I am clearly not the only one.

4. VFR video, subs.shift(s=...)

I think this makes sense as-is, ie. just add whatever the user specifies to the stored milliseconds

I am 100% agree. We should not "invoke" anything relied with Timestamps.

As I understand it, doing the ms_to_frame -> frame_to_ms round-trip (which is what my snap_to_frames does) only needs to happen when we want to know the timestamps in reduced precision, ie. when saving the file to something like ASS.

If you don't consider the VFR video and a possibility an user shifted the subtitle by few ms, then I think you are right, but I am not 100$ sure.

This will cause the same problem has the current shifting since the e.start/end can be anything. Even if e.start/end is snapped to the frame, it does not always works.
Example where the fps = 93, the end_time correspond to the frame 37 and we want to shift the end_time by 1 frame.
from pysubs2 import Timestamps, TimeType, make_time

def round_timing(ass_ms):
    """
    From https://github.com/Aegisub/Aegisub/blob/6f546951b4f004da16ce19ba638bf3eedefb9f31/libaegisub/include/libaegisub/ass/time.h#L32
    """
    return (ass_ms + 5) - (ass_ms + 5) % 10

Sorry, by "snapping to frame" I didn't mean the simple rounding as you do in round_timing (that's already implemented, and I see it why it doesn't really help), I meant my earlier:
def snap_to_frames(subs: pysubs2.SSAFile, format_: str, ts: pysubs2.Timestamps):
    for e in subs:
        old_start_ms = e.start
        old_end_ms = e.end
        start_frames = ts.ms_to_frames(old_start_ms, format_, pysubs2.TimeType.START)  # not sure if we want START or END in these
        end_frames = ts.ms_to_frames(old_end_ms, format_, pysubs2.TimeType.END)
        new_start_ms = ts.frames_to_ms(start_frames, pysubs2.TimeType.START)
        new_end_ms = ts.frames_to_ms(end_frames, pysubs2.TimeType.END)
        e.start = new_start_ms
        e.end = new_end_ms

Curiously, in your example:

print(f"Expected result: {end_frame + 1}")
print(f"Result: {timestamps.ms_to_frames(end_ms, TimeType.END)}")

Expected result: 38
Result: 39

I actually do get both results as 38, this is with https://github.com/moi15moi/pysubs2/commit/aab99813da31a2fcfffa7f3a3e69a2bf2973fe62 and this change:
# TODO Correct this line
return timestamps.frames_to_ms(frames, TimeType.START)

VFR video, subs.shift(frames=...)

IMHO this doesn't make sense and ideally should raise an exception

I don't see why it should raise en exception. Sometimes, I shift subtitles that are timed with a VFR video in frame and I am clearly not the only one.

I meant that it's a tricky operation: let's say your video has 30fps and 60fps segments, then by shifting subtitles by 30 frames, you shift by 1 second in the 30fps parts, but only by 1/2 second in the 60fps parts. subs.shift() affects all subtitles in the file. If the subtitles you're shifting are all in a particular fps region, then I can see it being useful, since that's basically the CFR case.

As I understand it, doing the ms_to_frame -> frame_to_ms round-trip (which is what my snap_to_frames does) only needs to happen when we want to know the timestamps in reduced precision, ie. when saving the file to something like ASS.

If you don't consider the VFR video and a possibility an user shifted the subtitle by few ms, then I think you are right, but I am not 100$ sure.

Yeah, I'm also not sure, that's mainly why I actually generated a video with matching subtitles, to demonstrate the issues and see if the code changes resolve them.
I did another one for your 93fps example (this time I rounded the ms, as you suggest) and... it just doesn't seem to match, at least in ffmpeg and VLC. The SRT and ASS subtitles are both 2-3 frames ahead of the video, even though the SRT timestamps should be perfect (rounding the ms or not doesn't fix this). pysubs2_timestamps_test2.zip

Sorry, by "snapping to frame" I didn't mean the simple rounding as you do in round_timing (that's already implemented, and I see it why it doesn't really help)

I understood that. I don't know what make you think I misunderstood it.
Just to be sure we understand each other, my previous example is snapped to the frame since I got the result via frames_to_ms and I "round" it because .ass does support milliseconds.

I actually do get both results as 38, this is with moi15moi@aab9981 and this change:

This is simply a coincidence. Try with the fps 25 and the end_frame 1608.
You will get those result.
Expected result: 1609
Result: 1608

I did another one for your 93fps example (this time I rounded the ms, as you suggest) and... it just doesn't seem to match, at least in ffmpeg and VLC. The SRT and ASS subtitles are both 2-3 frames ahead of the video, even though the SRT timestamps should be perfect (rounding the ms or not doesn't fix this). pysubs2_timestamps_test2.zip

The video is broken. There are a lot of frame that are duplicated.
The frame 0 has 4 frame which make no sense:

Ah, you're right, ffmpeg messes up the .mp4 output somehow. With .mkv it's good.
I've tried with the first 23.976 video example:
import subprocess
import pysubs2

subs = pysubs2.load("test_video.srt")
ts = pysubs2.timestamps.Timestamps.from_video_file("test_video.mp4")

def snap_to_frames(subs: pysubs2.SSAFile, ts: pysubs2.Timestamps):
    for e in subs:
        old_start_ms = e.start
        old_end_ms = e.end
        start_frames = ts.ms_to_frames(old_start_ms, pysubs2.TimeType.START)  # not sure if we want START or END in these
        end_frames = ts.ms_to_frames(old_end_ms, pysubs2.TimeType.END)
        new_start_ms = ts.frames_to_ms(start_frames, pysubs2.TimeType.START)
        new_end_ms = ts.frames_to_ms(end_frames, pysubs2.TimeType.END)
        e.start = new_start_ms
        e.end = new_end_ms

subs.shift(frames=99, fps=23.976)
snap_to_frames(subs, ts)

subs.save("test_video-shift.ass")
subprocess.check_call(["ffmpeg", "-y", "-i", "test_video.mp4", "-vf", "subtitles=test_video-shift.ass", "test_video_with_ass-shift.mp4"])

With no shift, snap_to_frames() takes care of the difference between SRT and ASS, both show correctly on playback. When applying shift, it also seems to work well, but you suggest that's because the input subtitles are already snapped to frames, while this doesn't have to be the case necessarily.
Can you implement what you think is needed inside SSAFile.shift() in your branch?

I've tried with the first 23.976 video example:

See the message where I presented the example where the fps = 93, the end_time correspond to the frame 37 and we want to shift the end_time by 1 frame.
I "proved" by showing an counterexample that even if you snap the subs to the frame, it does not always works.
If you need any more detail, ask it. I know it is an complicated subject

Can you implement what you think is needed inside SSAFile.shift() in your branch?

Sure, see my last commit

Is there any problem?


XGBoost Plugin

Signed-off-by: Samhita Alla<EMAIL_ADDRESS>TL;DR
XGBoost Plugin for ODSC
Type

[ ] Bug Fix
[ ] Feature
[ ] Plugin

Are all requirements met?

[ ] Code completed
[ ] Smoke tested
[ ] Unit tests added
[ ] Code documentation added
[ ] Any pending items have an associated Issue

Complete description
How did you fix the bug, make the feature etc. Link to any design docs etc
Tracking Issue
https://github.com/lyft/flyte/issues/
Follow-up issue
NA
OR
https://github.com/lyft/flyte/issues/

I am not sure why we are using CSV Files. My preference is that we use FlyteSchema and then load CSV into FlyteSchema or have a task to transform it. That being said cc @wild-endeavor we should probably make CSV a valid type of schema?

@kumare3, let me know if everything looks okay. I can then copy this to the ODSC repo.


emm 为啥你们的模型不能判断这个13.11和13.8谁大的问题，参数量不够吗

This ability is related to LLM rather than LVLM. Our InternLMXComposer is designed for multi-modal inputs, e.g., image and video.

This ability is related to LLM rather than LVLM. Our InternLMXComposer is designed for multi-modal inputs, e.g., image and video.

好的，谢谢解答


Translation updated

Amazon is called Amazon worldwide. The word was translated unintentionally. Also, it is more common in spanish to use "E-book" instead of "E-libro", even when the word is accepted.

[x] I have read freeCodeCamp's contribution guidelines.
[x] My pull request has a descriptive title (not a vague title like Update index.md)
[x] My pull request targets the master branch of freeCodeCamp.
[x] None of my changes are plagiarized from another source without proper attribution.
[x] My article does not contain shortened URLs or affiliate links.

If your pull request closes a GitHub issue, replace the XXXXX below with the issue number.
Closes #XXXXX

Closed and Reopened this PR to attempt to resolve a specific Travis build failure.

Thank you for opening this pull request.
Book recommendations are beyond the scope of the freeCodeCamp Guide, so we've decided to go ahead and remove these book recommendation articles.
I encourage you to review this book in the ratings category of the freeCodeCamp forum. Your recommendation will reach way more people there.
Thanks again recommending this book, and for contributing to the freeCodeCamp Guide.


Virtualbox plugin crashes when out of disk space

If we run out of disk space during the creation of a virtualbox docker machine we just crashes with no proper explanation.
(rock2) DBG | Creating 20000 MB hard disk image...
WARNING >>> Error attempting heartbeat call to plugin server: read tcp <IP_ADDRESS>:49681-><IP_ADDRESS>:49680: wsarecv: An existing connection was forcibly closed by the remote host.

Full log
C:\Users\jlm>docker-machine -D create -d virtualbox rock2
Docker Machine Version: 0.5.0 (04cfa58)
Found binary path at C:\Program Files\Docker Toolbox\docker-machine-driver-virtualbox.exe
Launching plugin server for driver virtualbox
Plugin server listening at address <IP_ADDRESS>:49676
() Calling RpcServerDriver.GetVersion
Using API Version 1
() Calling RpcServerDriver.SetConfigRaw
() Calling RpcServerDriver.GetMachineName
(flag-lookup) Calling RpcServerDriver.GetCreateFlags
Making call to close connection to plugin binary
Making call to close driver server
(flag-lookup) Calling RpcServerDriver.Close
Successfully made call to close driver server
Found binary path at C:\Program Files\Docker Toolbox\docker-machine-driver-virtualbox.exe
Launching plugin server for driver virtualbox
Plugin server listening at address <IP_ADDRESS>:49680
() Calling RpcServerDriver.GetVersion
Using API Version 1
() Calling RpcServerDriver.SetConfigRaw
() Calling RpcServerDriver.GetMachineName
(rock2) Calling RpcServerDriver.GetMachineName
(rock2) Calling RpcServerDriver.DriverName
(rock2) Calling RpcServerDriver.GetCreateFlags
(rock2) Calling RpcServerDriver.SetConfigFromFlags
Running pre-create checks...
(rock2) Calling RpcServerDriver.PreCreateCheck
(rock2) DBG | COMMAND: C:\Program Files\Oracle\VirtualBox\VBoxManage.exe
(rock2) Calling RpcServerDriver.GetConfigRaw
(rock2) Calling RpcServerDriver.GetConfigRaw
Creating machine...
(rock2) Calling RpcServerDriver.Create
(rock2) DBG | COMMAND: wmic cpu get VirtualizationFirmwareEnabled
(rock2) DBG | STDOUT:
(rock2) DBG | {
(rock2) DBG | VirtualizationFirmwareEnabled
(rock2) DBG | TRUE
(rock2) DBG |
(rock2) DBG | }
(rock2) OUT | Creating VirtualBox VM...
(rock2) OUT | Creating SSH key...
(rock2) DBG | Creating disk image...
(rock2) DBG | Creating 20000 MB hard disk image...
WARNING >>> Error attempting heartbeat call to plugin server: read tcp <IP_ADDRESS>:49681-><IP_ADDRESS>:49680: wsarecv: An existing connection was forcibly closed by the remote host.
Error creating machine: Error in driver during machine creation: read tcp <IP_ADDRESS>:49681-><IP_ADDRESS>:49680: wsarecv: An existing connection was forcibly closed by the remote host.

closed as duplicate of #2285


SUSE buildpacks are not being properly tested

Describe the bug
I manually found out that the suse-java-buildpack was not being installed. The fix was applied here: https://github.com/cloudfoundry-incubator/kubecf/pull/827.
That means, no tests are asserting that we have all the SUSE buildpacks being installed correctly in the early stages.
To Reproduce
Deploy a commit previous to that bug-fix and assert that the java buildpack was not being installed.
Expected behavior
The deployment should have failed.

https://jira.suse.com/browse/CAP-1475

This is an internal SUSE item


Connection on background

Environment
System:
OS: Windows 10 10.0.19042
CPU: (4) x64 Intel(R) Pentium(R) Gold G6400 CPU @ 4.00GHz
Memory: 3.60 GB / 15.86 GB
Binaries:
Node: 14.17.3 - C:\Program Files\nodejs\node.EXE
Yarn: Not Found
npm: 6.14.13 - ~\AppData\Roaming\npm\npm.CMD
Watchman: Not Found
SDKs:
Android SDK:
API Levels: 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31
Build Tools: 29.0.3, 30.0.0, 30.0.1, 30.0.2, 30.0.3, 31.0.0
System Images: android-23 | Google APIs Intel x86 Atom, android-26 | Google APIs Intel x86 Atom_64, android-27 | Intel x86 Atom_64, android-28 | Intel x86 Atom, android-28 | Google Play Intel x86 Atom_64, android-29 | Intel x86 Atom_64, android-29 | Google APIs ARM 64 v8a, android-30 | Google APIs Intel x86 Atom, android-30 | Google Play Intel x86 Atom
Android NDK: Not Found
Windows SDK: Not Found
IDEs:
Android Studio: Not Found
Visual Studio: 16.11.31729.503 (Visual Studio Community�2019)
Languages:
Java: Not Found
npmPackages:
@react-native-community/cli: Not Found
react: ^17.0.2 => 17.0.2
react-native: ^0.65.1 => 0.65.1
react-native-windows: Not Found
npmGlobalPackages:
react-native: Not Found
Platforms
Android most likely
Versions

Android:
iOS:
react-native-netinfo:
react-native:
react:

Description
Install the app, everything works like it should. Then when I lock screen for an hour, after unlocking I have a Network error for second, then it restart the connection.
I have tried to log this error so I put all info to my main screen , here you can see all changes about internet connections , also I have
http requests every minute in my app , but I can't understand why after unlocking the screen for a second they get network error , and then reload ,and how can I fix it
Reproducible Demo
Lock the screen and wait an hour or more

same here on RN 0.66.3 and netinfo 7.1.2

We are facing same issue. Any help?

When examined it looked like the phone was really asleep and the network was really interrupted.
So the signals you receive are actually the reality of the connection state @tradebulls
If you do not like the interrupted status to be visible (that is: you want to hide the reality of a temporary network disconnection) there are strategies with setTimeout and debouncing right?

@UnySonic maybe https://github.com/react-native-netinfo/react-native-netinfo/pull/547 (7.1.4) fixes this?
How are you doing background network requests? If you are not starting an Android foreground service, then your app will go to sleep, and eventually doze will disconnect all your network requests.

@cristianoccazinsp The doze makes requests, once in a short period of time the dose allows making requests and goes to sleep again, I just turned off the smartphone screen and waited a couple of hours, and logged all network changes

@UnySonic unless you are using a foreground service or something like react-native-background-fetch (or anything that uses tasks or the alarm manager), even if doze lets you do network requests, your app will not get execution time and will remain sleeping.
Can you elaborate more on what you are trying to do and what's the issue?

My application makes requests every 30 minutes, if you turn off the screen and thus turn on the doze, the application will make requests only when the doze allows, and at some point after about 3 hours the request goes with NetWork error , idk why
You should also know that I am not closing the app just lock the screen

Try with 7.1.4 to see if something changes, although I doubt it will.
What are you using to run those requests every 30 minutes? Is the network error from this library, or just a network error when using fetch? Are you using the latest version of react native and okhttp ?

It is a network error from the library, I am using the latest versions but I will try to test again today

But this library does not let you make requests, it just checks the network status. From where exactly are you getting the network error? What's the network error exactly?

library return network error when everything is okey with connection , I also checked 7.1.4 version this is still happening

@UnySonic I'm sorry I can't help further. You should try doing some debugging yourself using the native android debugger and messing around with doze on/off.
Try testing with any of these:
adb shell dumpsys deviceidle force-idle
adb shell dumpsys deviceidle unforce

same problem

facing the same problem.

same here

facing Same issue on Android Device when app goes in Background and after a while comes to foreground it return false even if i am connected to Internet.

I have the same issue, makes the newer releases unusable

Is it possible to stop all network checks as soon as the app goes to background?
My app shows 'You are offline' message if there is no internet connection. It does it by subscribing to events:
  useEffect(() => {
    const unsubscribe = NetInfo.addEventListener(state => {
      // isInternetReachable is null if unknown
      setOffline(state.isInternetReachable === false);
    });
    return () => unsubscribe();
  }, []);

Sometimes if I open my app, turn off my phone, wait for some time, then turn it back on I see 'You are offline' message. This is inconsistent with the network state - the Internet is in fact reachable.

You can use AppState listeners I think to determine if you are in background or not
You can pass a function in this package via config to inform the module if it should perform reachability checks at all, that function could depend on AppState

Hi, I had a similar problem on android, when I returned from the background after some time isConnected from the hook returned false despite available internet.
In version v8.3.0 an interesting refresh() method was added, but in this version useNetInfo did not work correctly on android.
I solved the problem by downgrade the version of the library to 6.0.0 and manually added the refresh() method from version v8.3.0. and then through a patch-package modified the library.
Next I added to the app AppState listener that detects a change in the state of the app, in the case of 'active' it executes refresh().
Now it's work correctly :)

@wiktorkaplan great that you found a solution, but please note that basing a solution on a non-main codebase (that is: the v6 code here vs current) is not sustainable. I continue to implore anyone that is affected by this to take that as motivation to propose a PR that fixes it as needed. All reasonable PRs are merged+released here.

any news about this issue?

We've faced similar issues where we display a "no internet connection" banner which would be visible when foregrounding an app that has been in the background for as little as 1 minute when the connection is still fine.
Sharing our solution in case it helps someone. We have no need to make network requests when the app is in the background so It's unsubscribing from netinfo changes when the app is in the background.
import { useEffect, useRef, useState } from 'react';
import NetInfo, {
  NetInfoState,
  NetInfoSubscription,
} from '@react-native-community/netinfo';
import { AppState } from 'react-native';

function checkNetInfoState(state: NetInfoState) {
  if (
    typeof state.isConnected !== 'boolean' ||
    typeof state.isInternetReachable !== 'boolean'
  ) {
    // ambiguous states are considered online, until we know otherwise
    return true;
  }

  return state.isConnected && state.isInternetReachable;
}

export function useIsOnline() {
  const [isOnline, setIsOnline] = useState(true);
  const netInfoSubscriptionRef = useRef<NetInfoSubscription | null>(null);

  useEffect(() => {
    async function initIsOnlineSubscription() {
      const netInfoState = await NetInfo.fetch();
      setIsOnline(checkNetInfoState(netInfoState));

      netInfoSubscriptionRef.current = NetInfo.addEventListener(state =>
        setIsOnline(checkNetInfoState(state)),
      );
    }

    function removeIsOnlineSubscription() {
      if (netInfoSubscriptionRef.current) {
        netInfoSubscriptionRef.current();
        netInfoSubscriptionRef.current = null;
      }
    }

    initIsOnlineSubscription();

    const appStateSubscription = AppState.addEventListener(
      'change',
      async nextAppState => {
        removeIsOnlineSubscription();

        if (nextAppState === 'active') {
          await initIsOnlineSubscription();
        }
      },
    );

    return () => {
      appStateSubscription.remove();
      removeIsOnlineSubscription();
    };
  }, []);

  return { isOnline };
}


fix: standards/naics2017

Should we be including the 4 and 5 digit codes in addition to the six digit codes? See https://www.census.gov/naics/?input=6117&year=2017

@sayari-analytics/data-product Census website does indeed provide NAICS codes less than 6 digits, but I can confirm 2017,2012,2007,2002 "Concordance" files on https://www.census.gov/naics/?input=6117&year=2017 between NAICS and ISIC only contain 6 digit NAICS codes. The website itself contains NAICS codes for fewer digits, but no more recent concordance I can find for fewer digits. 1997 NAICS to 1987 SIC has some concordance but doesn't seem to match newer files.

Not high priority or tied to any requests, closing.


chore: Add codspeed

Hi, we had a little bug on our(CodSpeed) endpoint hence one of the run didn't get reported.  It was empty so not much would have been shown here but still you should have got a message. We're rolling out a fix now so the message will appear in a few minutes. 😁
Btw, I'm very curious about the potential complications your facing setting up the tool, don't hesitate if you think I can help!

Hey @art049, thanks for pinging! So far the biggest obstacle is that the current project structure does not seem to be compatible with CodSpeedHQ/action@v1 - there is no workspace in the root, so having working-directory-like config option would help with such a setup :)

Though, maybe I just need to properly set a workspace instead

Hey @art049, thanks for pinging! So far the biggest obstacle is that the current project structure does not seem to be compatible with CodSpeedHQ/action@v1 - there is no workspace in the root, so having working-directory-like config option would help with such a setup :)

Hey @Stranger6667, I hope the installation didn't give you too much troubles. Don't hesitate to let me know if you still have issues.
By the way, I just released a new version of the action providing the working-directory input so don't hesitate to use it 😄.

Hi @art049 ! Thank you very much! :) So far so good!

Really appreciate addressing the working-directory input :) Everything seems to be working as expected!

Awesome 🎉


Don't send back URLs in survey questions [fix]

Make sure that we use a placeholder instead of a real URL for createChoiceQuestion.
Fixes #154

@lgarron can you PTAL?

LGTM


Doc Feedback: Incorrect field highlighted in self signup UI

Is your suggestion related to a missing or misleading document? Please describe.
It seems the highlighted field of the image given step 3 of this doc is incorrect.
https://is.docs.wso2.com/en/5.11.0/learn/self-registration-and-account-confirmation/#configuring-self-registration-consent-purposes

Describe the improvement
The Manage self-sign-up purposes field should be marked.

This issue is being closed due to extended inactivity. Please feel free to reopen it if further attention is needed. Thank you for helping us keep the issue list relevant and focused!


When try to make release  android Build.error node_modules/react-native-webview/lib/WebView.android.js: Unexpected token: operator (<) in file node_modules/react-native-webview/lib/WebView.android.js at 417:20. Run CLI with --verbose flag for more details.

Bug description:

To Reproduce:

Expected behavior:

Screenshots/Videos:

Environment:

OS:
OS version:
react-native version:'0.62.0',
react-native-webview version:'10.0.0'

metro-react-native-babel-preset

This solution worked for me

@isthisshivam change "metro-react-native-babel-preset" to "^0.66.2" in package.json

this also worked for me. I had to do npx jest --clearCache after changing to "^0.66.2"


Tags in metadata not recognized by plugin

---
time: 2023-08-09 00:00 Wednesday
title: test
tags:
- permanent
---

This is the general format of my notes.
This will be recognized by obsidian as a Tag, but it's  prompt "Found zero notes" by Advanced random note.
I have observed that obsidian may improve the metadata area in the near future.
If you plan to support it after the update, it also very grateful!

Hi @Unimp0rtance thanks for the constructive feedback :)
I have changed the code to also include frontmatter tags and published it as version 0.0.7.
If you have time, could you also check if it works and report back? That would help a lot.
Thanks

I have updated the plugin to version 0.0.8 which enables queries to use the Dataview plugin and regular expressions.
I will create a new issue with this problem as I have to refactor a bit of code.
Thanks for the constructive feedback :)


Firefox preflighted request

Hello, i post new recipients to our Sendgrid global contacts with this:

                const client = require('@sendgrid/client');
                client.setApiKey(process.env.SENDGRID_APIKEY);
                const recipient = [
                    {
                        "email"<EMAIL_ADDRESS>                        "first_name": 'testFirstname',
                        "last_name": 'testLastname'
                    }
                ];
                let request = { method: 'POST', url: '/v3/contactdb/recipients', body: recipient };

All is fine except in Firefox. The preflighted request from Firefox seems to enforce the User-Agent header on Access-Control-Allow-Headers. All other browsers ignore it.
The response from the https://api.sendgrid.com/v3/contactdb/recipients is this:
Access-Control-Allow-Headers | AUTHORIZATION, Content-Type, On-behalf-of, x-sg-elas-acl, X-Recaptcha, X-Request-Source
There is no user-agent allowed and so Firefox blocks my POST-Request.
Could you perhaps return also the user-agent in your Access-Control-Allow-Headers list or is there perhaps another solution for Firefox to allow my request?
Thx

Are you using this package in a Client-side application? These libraries are intended to be used server-side.


Discord ban

Did you like that discord ban, Ben Tettmar? 😉
~ Pankeki, the reporter.

Sure bud lol. Add me as friend then to prove.

brain issue

im using this like for 3+ months even with abuse cmds and nothing bad happened

Who asked. I'm talking to Ben lool

This funny

Who asked. I'm talking to Ben lool

you literally "asked" in the issue, you made a statement, I rejected it💀

What

dumfuk


Change the embed page's add/update donation site button open a new tab

Closes https://github.com/findthemasks/findthemasks/issues/606

hey @4kbt  I forgot why we needed this, do we actually need the form link in the embed page to open a new tab? why can't it redirect on the same page?

I believe that the acute need has now been resolved.   The problem was that
GUPPE's embed wasn't tall enough  for people to fill in the Google Form
from within the GUPPE page.  They could fill it in, but not reach
"Submit".   Forcing a new tab was a shotgun approach to solving the problem.
On Wed, Apr 22, 2020 at 11:50 PM Saikat Bhadra<EMAIL_ADDRESS>wrote:

hey @4kbt https://github.com/4kbt I forgot why we needed this, do we
actually need the form link in the embed page to open a new tab? why can't
it redirect on the same page?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/findthemasks/findthemasks/pull/612#issuecomment-618213633,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AA6L2GGPOZGE2R5TMASCLC3RN7QLJANCNFSM4MLGTLLA
.

The GUPPE embed works okay right now on my desktop and mobile.
On Thu, Apr 23, 2020 at 9:30 AM Charlie Hagedorn<EMAIL_ADDRESS>wrote:

I believe that the acute need has now been resolved.   The problem was
that GUPPE's embed wasn't tall enough  for people to fill in the Google
Form from within the GUPPE page.  They could fill it in, but not reach
"Submit".   Forcing a new tab was a shotgun approach to solving the problem.
On Wed, Apr 22, 2020 at 11:50 PM Saikat Bhadra<EMAIL_ADDRESS>wrote:

hey @4kbt https://github.com/4kbt I forgot why we needed this, do we
actually need the form link in the embed page to open a new tab? why can't
it redirect on the same page?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/findthemasks/findthemasks/pull/612#issuecomment-618213633,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AA6L2GGPOZGE2R5TMASCLC3RN7QLJANCNFSM4MLGTLLA
.

closing for now then


NETOBSERV-236 Topology search item

This PR implement search input for topology view:

matching results are kept visible while others turn half visible
number of match is showed next to the input
an extra icon show if match is found or not
You can go to the next match pressing 'enter' or search button. It will open side panel with https://github.com/netobserv/network-observability-console-plugin/pull/110
Normal opacity comes back as soon as search input is empty.

Two minor issues (see video):

When you keep searching and you reach the last match, if you search again it shows like it was not found. I don't know if it's the normal expected behavior.

Maybe we should change the search icon by an arrow (or show two arrows to allow searching backwards) to match a more "standard" behavior. This could be done in another PR.

https://user-images.githubusercontent.com/939550/162406760-23f40802-48e7-4638-a07a-883c45bb8d28.mp4

Two minor issues (see video):

Cool thanks for your feedback. Red icon at the end of match list was the expected behavior but I admit it's weird. I will put the next / previous buttons in this PR !

Here is the new behavior with next / previous / clear buttons according to your feedback @mariomac

Nice to have the arrows! LGTM.


Add support for async / await

Probably not necessary near term, but eventually we are going to want some request entry points that use async / await rather than callbacks.

While adding this, we should change the file reads we added with GraphQL support to not block the main thread as well.


Date improvement + added radio button and checkbox inputs + updated documentation

For the improvement of the date input did I copy some improvements by @zygolechien on the date input. I've also added radio button and checkbox input support and updated the documentation (including the screenshot) with the new inputs.
Since it includes my other PR, I will close that PR.
Please review @wallter

Merged into master along with some Bootstrap 2/3 compatibility additions.

I think the merging didn't go as planned, I can't find your Bootstrap 2/3 additions anywhere.


Fake implementation doesn't render the right metadata for the pod

Hi
I'm using the fake implementation to test create pod in my program.
clientset := fake.NewSimpleClientset()

pod, err := clientset.CoreV1().Pods(namespace).Create(&v1.Pod{
		ObjectMeta: metav1.ObjectMeta{
			GenerateName: job.Name,
			Labels: map[string]string{
				"name": job.Name,
				"type": "production",
			},
		},
		Spec: v1.PodSpec{
			Containers: []v1.Container{
				{
					Name:                   job.Name,
					Image:                  job.Image,
					TerminationMessagePath: v1.TerminationMessagePathDefault,
					ImagePullPolicy:        v1.PullIfNotPresent,
					SecurityContext:        securitycontext.ValidSecurityContextWithContainerDefaults(),
					Command:                []string{},
					Args:                   []string{},
				},
			},
			RestartPolicy: v1.RestartPolicyOnFailure,
			DNSPolicy:     v1.DNSDefault,
		}})

Note that i set GenerateName: job.Name, and i don't set Name: because i want the Kubernetes to generate a radon name with GenerateName provided suffix.
This logic works just fine in the actual implementation.
When i use fake i get only the value of GenerateName back and the value of Name is empty string "". While the actual value in real usage for Name will be something like "GenerateName+RANDOM"
Is there a way to get around that in the fake implementation?
	k8s.io/api v0.16.9
	k8s.io/apimachinery v0.16.9
	k8s.io/client-go v0.16.9
	k8s.io/kubernetes v1.16.9

I tried to update it to something similar to this.
// Create takes the representation of a pod and creates it.  Returns the server's representation of the pod, and an error, if there is any.
func (c *FakePods) Create(pod *corev1.Pod) (result *corev1.Pod, err error) {
	if pod.GetGenerateName() != "" && pod.GetName() == "" {
		pod.SetName(pod.GetGenerateName())
	}

	obj, err := c.Fake.
		Invokes(testing.NewCreateAction(podsResource, c.ns, pod), &corev1.Pod{})

	if obj == nil {
		return nil, err
	}
	return obj.(*corev1.Pod), err
}

But i figured out that the implementation is auto-generated so i can't change it ¯_(ツ)_/¯

/remove-lifecycle stale


Call-out boxes block

See the big green box here; the user is able to add a background image.
https://www.sling.com/whatson/entertainment/documentary-and-news/watch-newsmax-on-sling
The links are orange here, text is white.
QUESTION: Need to find out from the customer if these will always be a dark background with white text, or are there any other variants?

Per Devin Riggins, we won't be building anything for this use-case. Closing.


Fix contributing.md link and add information about WG creation/removal

There is also reference to ../mechanics/WORKING-GROUP-PROCESSES.md on the page which doesn't exist any more. What would be the replacement for that?

I have updated the pr with what we have discussed in the TOC meeting today.


Data Science with Python : Diabetes Classification

Welcome to 'DSWP' Team, good to see you here
This issue will helps readers in giving all the guidance that one needs to learn about working on Diabetes Classification. Tutorial to Diabetes Classification and how it's applied using sample code with multiple algorithm.
To get assigned to this issue, add your serial numbers mentioned in the spreadsheet of "Data Science with Python", the approach one would follow and choice you prefer (Documentation, Audio, Video). You can go with all three or any number of options you're interested to work on.
If you had referred any resources, add them up in "DS Resources". Similarly if you had used datasets, include them in "DS Datasets".
Domain : Machine Learning
Mentors Assigned : Kareem Negm / Aishani Singh
Points to Note :
The issues will be assigned on a first come first serve basis, 1 Issue == 1 PR.
"Issue Title" and "PR Title should be the same. Include issue number along with it.
Changes should be made inside the Datascience_With_Python/ directory & Datascience_With_Python branch.
Follow Contributing Guidelines & Code of Conduct before start Contributing.
This issue is only for 'GWOC' contributors of 'DSWP' domain.
All the best. Enjoy your open source journey ahead. 😎

I would like to work on this.
Vanshika Mishra - 830
Batch - 19
Type: Documentation
Approach:

Diabetes Classification using KNN - data analysis, implementation, predictions
Diabetes Classification using Random Forests - data analysis, implementation, predictions
Diabetes Classification using Support Vector Machine - data analysis, implementation, predictions

Issue assigned @vanshika230 for documentation.

Hello, I am Deepthi M with serial number:172, Batch-2. I would like to do a video on this issue.
my approach: A detailed explanation of code.

Hello @prathimacode-hub , please assigned me the issue

Hello, I am Deepthi M with serial number:172, Batch-2. I would like to do a video on this issue.
my approach: A detailed explanation of code.

Issue assigned to @deepthi1107 for documentation

Ma'am I was assigned for documentation as I created this issue, I have done the work too.

@vanshika230 I'm clarifying up the things.


Server connected, SteamVR Ready, Head tracking working, but GearVR stuck waiting for stream

As 2nd picture implies, my gearVR headset is indeed upside down, showing that head-tracking is working.
However, client app on the gear VR is stuck at "Connected! Streaming will begin soon!".
Client app is responsive and does not show any signs of having crashed.
I am using an AMD R9 285X, using the H.264 experimental codec at 30MBps.
My intuition as a programmer myself thinks it might be related to video decoding on the client app.
I have already tried the solution specified at #20 , but am unable to get a ping from my device.
Please help.
Thanks!

Tried lowering bitrate and resolution. It worked. I bet it was taking too long to send a single frame? But still it should have showed it frame by frame.

Found that bitrate has no effect on whether gearVR gets stuck at "Connected!" page, rather, that at the recommended resolution, it gets stuck. Works smoothly at the lower resolution however.

Is it possible its related to the max resolution your monitor can handle? I'm having the same issue. I know the phone can handle that resolution. For example my phone can handle it but my tv (monitor) only has max res of 1080p. This weekend I'll try on the 4k tv in the house. Or super sampling higher res to my 1080p monitor and post results.

Ok confirmed it is not related to native resolution of monitor. Tried on a newer pc at the house with a 1080p monitor and it works perfectly at any resolution. The card in that computer is a amd rx560 which supports h265 encoding which works as well with ALVR. The PC I'm having issues with does not support h265 encoding.
I tried super sampling as the PC with the rx560 had that enabled already. On my PC it was not enabled but it made no difference. I think it just might be a graphics card related issue. Going to upgrade mine in the coming days to test.


Document certificate management for Elasticsearch

Currently, the operator generates the whole set of artifacts to generate TLS certificates to use with Elasticsearch. While this provides the basics for encrypted communication, it's sub-optimal as all artifacts are self-signed.
In order to allow users to properly secure the communication between Jaeger instances and Elasticsearch via TLS, we need to:

Document what artifacts are used
Document how to generate that using standard tools, like cfssl and Kubernetes' cert manager (CertificateSigningRequest, kubectl certificate approve ..., kubectl create secret tls ...)
Allow the operator to read those artifacts from secrets that are compatible with the standard Kubernetes tooling (cert manager)

Related to #330

Looks like @pavolloffay did this already: https://www.jaegertracing.io/docs/1.15/operator/#elasticsearch-storage


gdrdrv init script for ubuntu, closes #32

@drossetti one folder for debian stuff and one folder for rhel stuff

@drossetti  Is this PR ok? Or should I change something?

I guess more metadata files are needed to build deb packages

@pakmarkthub please review. How does this one compose with your other PR regarding packaging?

This PR should complement #61: Support debian and dkms packaging.
@e-ago How do you plan for the users to install this debian init.d script? Do they need to copy it to their system init.d folder?

Also merged into PR #74.

Merged


fix: prevent invalid property assesment lint error

Description
When a property of an object (or entity) is accessed and the property name is a computed value, linting should be ignored. This is because we can not statically determine what the computed value is, and secondly, this value can be an argument of a JS function that can change at run time.
Fixes #19925
Media
Type of change

Bug fix (non-breaking change which fixes an issue)

How Has This Been Tested?

Manual
Cypress

Test Plan

Add Testsmith test cases links that relate to this PR

Issues raised during DP testing

Link issues raised during DP testing for better visiblity and tracking (copy link from comments dropped on this PR)

Checklist:
Dev activity

[ ] My code follows the style guidelines of this project
[ ] I have performed a self-review of my own code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[ ] My changes generate no new warnings
[ ] I have added tests that prove my fix is effective or that my feature works
[ ] New and existing unit tests pass locally with my changes
[ ] PR is being merged under a feature flag

QA activity:

[ ] Test plan has been approved by relevant developers
[ ] Test plan has been peer reviewed by QA
[ ] Cypress test cases have been added and approved by either SDET or manual QA
[ ] Organized project review call with relevant stakeholders after Round 1/2 of QA
[ ] Added Test Plan Approved label after reveiwing all Cypress test

/ok-to-test sha=05add44

LGTM.
Can we add eslint & prettier config to ast module to avoid code formatting. ( This could be done separately or the maintainer of the module could be tagged )

Nice point, I will add it and assign the maintainer for review.

/ok-to-test sha=948615c


ionic version 1.x  Https request does not work, but http request no problem

Https request does not work, but http request no problem, this problem occurs in Brazil and Malaysia, in the United States and France are not any problems, I doubt whether the ssl certificate problem? What's the problem? Thank you

Hello! Thanks for opening an issue with us! As this seems like more of a support question I will urge that you ask this question on our forum or on our slack channel. Thanks for using Ionic!


[SPARK-36681][CORE][TESTS][FOLLOW-UP] Handle LinkageError when Snappy native library is not available in low Hadoop versions

What changes were proposed in this pull request?
This is a follow-up to https://github.com/apache/spark/pull/36136 to fix LinkageError handling in FileSuite to avoid test suite abort when Snappy native library is not available in low Hadoop versions:
23:16:22 FileSuite:
23:16:22 org.apache.spark.FileSuite *** ABORTED ***
23:16:22   java.lang.RuntimeException: Unable to load a Suite class that was discovered in the runpath: org.apache.spark.FileSuite
23:16:22   at org.scalatest.tools.DiscoverySuite$.getSuiteInstance(DiscoverySuite.scala:81)
23:16:22   at org.scalatest.tools.DiscoverySuite.$anonfun$nestedSuites$1(DiscoverySuite.scala:38)
23:16:22   at scala.collection.TraversableLike.$anonfun$map$1(TraversableLike.scala:238)
23:16:22   at scala.collection.Iterator.foreach(Iterator.scala:941)
23:16:22   at scala.collection.Iterator.foreach$(Iterator.scala:941)
23:16:22   at scala.collection.AbstractIterator.foreach(Iterator.scala:1429)
23:16:22   at scala.collection.IterableLike.foreach(IterableLike.scala:74)
23:16:22   at scala.collection.IterableLike.foreach$(IterableLike.scala:73)
23:16:22   at scala.collection.AbstractIterable.foreach(Iterable.scala:56)
23:16:22   at scala.collection.TraversableLike.map(TraversableLike.scala:238)
23:16:22   ...
23:16:22   Cause: java.lang.UnsatisfiedLinkError: org.apache.hadoop.util.NativeCodeLoader.buildSupportsSnappy()Z
23:16:22   at org.apache.hadoop.util.NativeCodeLoader.buildSupportsSnappy(Native Method)
23:16:22   at org.apache.hadoop.io.compress.SnappyCodec.checkNativeCodeLoaded(SnappyCodec.java:63)
23:16:22   at org.apache.hadoop.io.compress.SnappyCodec.getCompressorType(SnappyCodec.java:136)
23:16:22   at org.apache.spark.FileSuite.$anonfun$new$12(FileSuite.scala:145)
23:16:22   at scala.util.Try$.apply(Try.scala:213)
23:16:22   at org.apache.spark.FileSuite.<init>(FileSuite.scala:141)
23:16:22   at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
23:16:22   at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62)
23:16:22   at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45)
23:16:22   at java.lang.reflect.Constructor.newInstance(Constructor.java:423)

Scala's Try can handle only NonFatal throwables.
Why are the changes needed?
To make the tests robust.
Does this PR introduce any user-facing change?
Nope, this is test-only.
How was this patch tested?
Manual test.

cc @HyukjinKwon, @viirya, @dongjoon-hyun

Thanks all for the review.


Convert weights to original llama weights.

Hi,
Is it possible to convert this weights into https://github.com/facebookresearch/llama/tree/main/llama format?

Sorry for that we are not planing to support to convert the weights for lit format into the original llama in our repo. Can you check for this https://github.com/facebookresearch/llama-recipes/blob/98fcc538ff82bd8987b31026dd7f21c01bc6f46b/src/llama_recipes/tools/convert_hf_weights_to_llama.py#L4 ?


[Bugfix][Hardware][CPU] Fix broken encoder-decoder CPU runner

Fix broken encoder-decoder CPU runner due to #10193
I forgot implementing sampling preparation when refactoring CPU encoder-decoder runner😅

Can you take a look at why the CI still passed before, and fix it so that failing tests actually fail the CI?

Can you take a look at why the CI still passed before, and fix it so that failing tests actually fail the CI?

It is due to the CPU CI is set as soft-failed.

The CI didn't even soft fail here: https://buildkite.com/vllm/ci-aws/builds/11064#01931a18-e48d-485d-b357-f5f995bc474f

The CI didn't even soft fail here: https://buildkite.com/vllm/ci-aws/builds/11064#01931a18-e48d-485d-b357-f5f995bc474f

Perhaps make cpu_tests() in the test script to exit early can fix (adding set -e at the function beginning).

I added an intentional failing test to CPU test pipeline, let's see if it can be caught by the CI after adding set -e.

Added ready label to trigger Intel CPU tests

Seems that adding set -e can solve the issue: https://buildkite.com/vllm/ci-aws/builds/11071#01931aef-f91a-4901-a902-753db7a74f76/6-314

Classification model tests are failing now: https://buildkite.com/vllm/ci-aws/builds/11116#01932014-a8a8-4bbf-91a0-6ba08aa7cde8

Hmmm, this is odd, because I can't reproduce it on my CPU server. Let me try it on another device to see if this is related to device...

Seems that the failing tests only occur after several runs:
$ pytest --count=20 -x -s -v tests/models/embedding/language/test_cls_models.py::test_classification_models
================================================================================================== FAILURES ==================================================================================================
_________________________________________________________________ test_classification_models[float-/data/LLM-model/Qwen2.5-1.5B-apeach-5-20] _________________________________________________________________

hf_runner = <class 'tests.conftest.HfRunner'>, vllm_runner = <class 'tests.conftest.VllmRunner'>
example_prompts = ['vLLM is a high-throughput and memory-efficient inference and serving engine for LLMs.\n', 'Briefly describe the majo...me.\n', 'Analyze the impact of the COVID-19 pandemic on global economic structures and future business models.\n', ...]
model = '/data/LLM-model/Qwen2.5-1.5B-apeach', dtype = 'float'

    @pytest.mark.parametrize("model", CLASSIFICATION_MODELS)
    @pytest.mark.parametrize("dtype", ["float"])
    def test_classification_models(
        hf_runner,
        vllm_runner,
        example_prompts,
        model: str,
        dtype: str,
    ) -> None:
        with hf_runner(model,
                       dtype=dtype,
                       auto_cls=AutoModelForSequenceClassification) as hf_model:
            hf_outputs = hf_model.classify(example_prompts)

        with vllm_runner(model, dtype=dtype) as vllm_model:
            vllm_outputs = vllm_model.classify(example_prompts)

        print(hf_outputs, vllm_outputs)

        # check logits difference
        for hf_output, vllm_output in zip(hf_outputs, vllm_outputs):
            hf_output = torch.tensor(hf_output)
            vllm_output = torch.tensor(vllm_output)

>           assert torch.allclose(hf_output, vllm_output, 1e-3)
E           assert False
E            +  where False = <built-in method allclose of type object at 0x776c248678c0>(tensor([0.2645, 0.7355]), tensor([1., 0.]), 0.001)
E            +    where <built-in method allclose of type object at 0x776c248678c0> = torch.allclose

tests/models/embedding/language/test_cls_models.py:39: AssertionError
============================================================================================== warnings summary ==============================================================================================
../../miniconda3/envs/vllm/lib/python3.10/site-packages/intel_extension_for_pytorch/transformers/optimize.py:4
  /home/c4rbon/miniconda3/envs/vllm/lib/python3.10/site-packages/intel_extension_for_pytorch/transformers/optimize.py:4: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
    import pkg_resources

../../miniconda3/envs/vllm/lib/python3.10/site-packages/pkg_resources/__init__.py:3154
  /home/c4rbon/miniconda3/envs/vllm/lib/python3.10/site-packages/pkg_resources/__init__.py:3154: DeprecationWarning: Deprecated call to `pkg_resources.declare_namespace('sphinxcontrib')`.
  Implementing implicit namespace packages (as specified in PEP 420) is preferred to `pkg_resources.declare_namespace`. See https://setuptools.pypa.io/en/latest/references/keywords.html#keyword-namespace-packages
    declare_namespace(pkg)

../../miniconda3/envs/vllm/lib/python3.10/site-packages/torch/distributed/distributed_c10d.py:335
  /home/c4rbon/miniconda3/envs/vllm/lib/python3.10/site-packages/torch/distributed/distributed_c10d.py:335: UserWarning: Device capability of ccl unspecified, assuming `cpu` and `cuda`. Please specify it via the `devices` argument of `register_backend`.
    warnings.warn(

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
========================================================================================== short test summary info ===========================================================================================
FAILED tests/models/embedding/language/test_cls_models.py::test_classification_models[float-/data/LLM-model/Qwen2.5-1.5B-apeach-5-20] - assert False
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! stopping after 1 failures !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
============================================================================= 1 failed, 4 passed, 3 warnings in 61.51s (0:01:01) =============================================================================

Does the failure occur randomly?

Yes, and it seems that Intel CPU test in some new PRs is passing now: https://buildkite.com/vllm/ci-aws/builds/11137#0193231d-132d-40a9-9bfe-dfa5a1f05da0

This is odd... can you try setting max_num_seqs=1 and see if it can completely avoid the error? If so, maybe there is some problem with batching.

Setting max_num_seqs=1 didn't work...
======================================================================================================== FAILURES =========================================================================================================
_______________________________________________________________________ test_classification_models[float-/data/LLM-model/Qwen2.5-1.5B-apeach-4-20] ________________________________________________________________________

hf_runner = <class 'tests.conftest.HfRunner'>, vllm_runner = <class 'tests.conftest.VllmRunner'>
example_prompts = ['vLLM is a high-throughput and memory-efficient inference and serving engine for LLMs.\n', 'Briefly describe the majo...me.\n', 'Analyze the impact of the COVID-19 pandemic on global economic structures and future business models.\n', ...]
model = '/data/LLM-model/Qwen2.5-1.5B-apeach', dtype = 'float'

    @pytest.mark.parametrize("model", CLASSIFICATION_MODELS)
    @pytest.mark.parametrize("dtype", ["float"])
    def test_classification_models(
        hf_runner,
        vllm_runner,
        example_prompts,
        model: str,
        dtype: str,
    ) -> None:
        with hf_runner(model,
                       dtype=dtype,
                       auto_cls=AutoModelForSequenceClassification) as hf_model:
            hf_outputs = hf_model.classify(example_prompts)

        with vllm_runner(model, dtype=dtype, max_num_seqs=1) as vllm_model:
            vllm_outputs = vllm_model.classify(example_prompts)

        print(hf_outputs, vllm_outputs)

        # check logits difference
        for hf_output, vllm_output in zip(hf_outputs, vllm_outputs):
            hf_output = torch.tensor(hf_output)
            vllm_output = torch.tensor(vllm_output)

>           assert torch.allclose(hf_output, vllm_output, 1e-3)
E           assert False
E            +  where False = <built-in method allclose of type object at 0x794a340678c0>(tensor([0.2645, 0.7355]), tensor([1., 0.]), 0.001)
E            +    where <built-in method allclose of type object at 0x794a340678c0> = torch.allclose

tests/models/embedding/language/test_cls_models.py:39: AssertionError
==================================================================================================== warnings summary =====================================================================================================
../../miniconda3/envs/vllm/lib/python3.10/site-packages/intel_extension_for_pytorch/transformers/optimize.py:4
  /home/c4rbon/miniconda3/envs/vllm/lib/python3.10/site-packages/intel_extension_for_pytorch/transformers/optimize.py:4: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html
    import pkg_resources

../../miniconda3/envs/vllm/lib/python3.10/site-packages/pkg_resources/__init__.py:3154
  /home/c4rbon/miniconda3/envs/vllm/lib/python3.10/site-packages/pkg_resources/__init__.py:3154: DeprecationWarning: Deprecated call to `pkg_resources.declare_namespace('sphinxcontrib')`.
  Implementing implicit namespace packages (as specified in PEP 420) is preferred to `pkg_resources.declare_namespace`. See https://setuptools.pypa.io/en/latest/references/keywords.html#keyword-namespace-packages
    declare_namespace(pkg)

../../miniconda3/envs/vllm/lib/python3.10/site-packages/torch/distributed/distributed_c10d.py:335
  /home/c4rbon/miniconda3/envs/vllm/lib/python3.10/site-packages/torch/distributed/distributed_c10d.py:335: UserWarning: Device capability of ccl unspecified, assuming `cpu` and `cuda`. Please specify it via the `devices` argument of `register_backend`.
    warnings.warn(

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
================================================================================================= short test summary info =================================================================================================
FAILED tests/models/embedding/language/test_cls_models.py::test_classification_models[float-/data/LLM-model/Qwen2.5-1.5B-apeach-4-20] - assert False
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! stopping after 1 failures !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
=================================================================================== 1 failed, 3 passed, 3 warnings in 64.05s (0:01:04) ====================================================================================

Maybe there's something wrong with the softmax? It's really odd that the output is exactly 0 and 1...

I prefer this is an issue about the test itself, because only this test failed randomly and seems that running example/offline_inference_embedding.py won't output exactly 0 and 1.
Perhaps it's because of the runner order? We run hf_runner before vllm_runner in this test.

Perhaps it's because of the runner order? We run hf_runner before vllm_runner in this test.

Let's try swapping the order.

Seems that there is an overflow occured in score layer when the test is failing. Here is the logits tensor when test failed:
tensor([[ 3.3580e+36, -2.0206e+00],
        [ 3.3580e+36,  1.5207e+00],
        [ 3.3580e+36,  9.7952e-02],
        [ 3.3580e+36,  3.0942e+00],
        [ 3.3580e+36,  3.0767e+00]
        ...
        [ 3.3580e+36,  4.4228e+00],
        [ 3.3580e+36,  4.5115e+00],
        [ 3.3580e+36,  1.6440e+00],
        [ 3.3580e+36, -1.8783e+00]])

Note that the hidden_states from Qwen2Model in failing case is same to passing case.


Any way of adjusting Dualshock controller light strip through the SDK?

My apologies if this is the wrong place to ask this -- couldn't find any other resources or information anywhere else and I'm not sure if it's even a possibility.

Currently the light bar color is exclusively managed from the Driver Station, where it is tied to indicating driver position.
Supporting the ability for user code to control the color was considered, but at the time was decided against, for the reasons that 1) Having the light bar color always indicate driver position is good for clarity, and 2) Drivers are usually watching the robot, not looking at the gamepad, so rumble is probably a better choice for feedback in most circumstances.


use a buffered channel for signal.Notify

To avoid missing signals, the channel should be buffered and of the appropriate size.
For a channel used for notification of just one signal value, a buffer of size 1 is sufficient, as per https://golang.org/pkg/os/signal/#Notify

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.

Thanks for your PR. Since this method only listens for one signal and then calls Stops and doesn't read from the channel again, we don't need a buffer on it.
We do need a buffer on this one though, if you want to change your PR to fix that one: https://github.com/slackhq/nebula/blob/v1.3.0/config.go#L117


Contributor icons being cut off at the end

On an iPhone SE, the contributor icons are cut off at the end (right). It only shows about half of the last icon.

@CameronSamuels If you are using a released app, I think it has been fixed by #491.

Yes, this was already fixed and will be shipped in 1.4.0.
Thank you for reporting it Cameron!

Sorry for the duplicate


Add template for frontend

Why such a rename?

Why such a rename?

Enable user to load another graph.


Merge predict.py into train.py

Combine the functionality of predict.py into train.py. Prediction will be toggled on as a mode train.py --predict. In the current implementation, there is a very large amount of duplicated code that is changed often, which is an unsustainable situation. While the script train.py being used for prediction is a slight misnomer, ignore this for now. Add a [Predict] section to the config file including options for whether to export as a file, the filename, and whether the true label is present in the data files.

Resolved by 9842660d4293a485652ccfe48725fda3d5be9e33.


warpd is cannot be launched since: "C-o is not a valid key name"

warpd -f
gives the output:
Starting warpd v1.3.5-osx (built from: effea40) ERROR: C-o is not a valid key name
None of the warpd activation keys work.
config file is empty

Want to add that I'm not using C-o as shortcut in any other apps

I stumbled across a similar issue. When I start warpd in foreground, it says the following.
>> warpd -f
Starting warpd v1.3.5-osx (built from: effea40)
ERROR: A-M-x is not a valid key name


Add DIIT domain

https://diit.edu.ua

@Hooligan199 I have to close this request without merging, because you requested to add a non-existent domain to this repository: Host ust.dp.ua not found: 3(NXDOMAIN) Please ensure that you are familiar with this repository rules located at the bottom of this page and submit a new request with the correct information. Thank you for your understanding!


Testing framework

I experimented with an AST to SIL reconstruction (see also #15) with the purpose of helping writing tests, e.g. "busted" such as those initiated in file inputters/markdown_spec.lua. It would be nice to have a way (e.g. GitHub action?) to automate the testing:

On SILE latest official release or ideally a list of releases...
On several versions of Lua.

The AST to SIL reconstruction is not the right way to go and is pending removal.
How to properly test 3rd-party modules vs. several versions of SILE and Lua is still an open issue.
But it's more general that this very collection here.


Set offset to 1 in PNDMScheduler

As in the PyTorch version.
This is only appropriate for PNDMScheduler, will have to be revisited when we add more.
This does not fix all the differences between Flax and PyTorch.

Perfect!


POST_Links does not return link information when following links recursively

When using POST_Links to retrieve a link by name with follow_links enabled, if the link is retrieved from a sub-group, the returned JSON is empty.
Implementing the follow_links parameter for POST_Links raises some questions - if multiple links are found by the same name, which should be returned? The first in iteration order? Do the domain crawlers guarantee any particular iteration order, and do we want to expose that behavior?
It might make sense to remove the follow_links param from POST_Links. Similarly, CreateOrder, Limit, and Marker seem to be holdovers from GET_Links and should probably be removed as well.
Test to elicit the bug:
    def testPostLinksFollowLinks(self):
        domain = self.base_domain + "/testPostLinksFollowLinks.h5"
        helper.setupDomain(domain)
        print("testPostLinksFollowLinks", domain)
        headers = helper.getRequestHeaders(domain=domain)

        req = helper.getEndpoint() + "/"
        rsp = self.session.get(req, headers=headers)
        self.assertEqual(rsp.status_code, 200)
        rspJson = json.loads(rsp.text)
        root_id = rspJson["root"]

        # create group "g1" in root group
        req = helper.getEndpoint() + "/groups"
        body = {"link": {"id": root_id, "name": "g1"}}
        rsp = self.session.post(req, data=json.dumps(body), headers=headers)
        self.assertEqual(rsp.status_code, 201)
        rspJson = json.loads(rsp.text)
        group_id = rspJson["id"]

        path = "/dummy_target"

        # create link "link1" in g1
        req = helper.getEndpoint() + "/groups/" + group_id + "/links/link1"
        body = {"h5path": path}
        rsp = self.session.put(req, data=json.dumps(body), headers=headers)
        self.assertEqual(rsp.status_code, 201)

        # make POST_Links request to root group, expect 404
        body = {"titles": ["link1"]}
        req = helper.getEndpoint() + "/groups/" + root_id + "/links"
        rsp = self.session.post(req, data=json.dumps(body), headers=headers)
        self.assertEqual(rsp.status_code, 404)

        # make POST_Links request to root group with follow_links, expect to find link1
        req = helper.getEndpoint() + "/groups/" + root_id + "/links?follow_links=1"
        rsp = self.session.post(req, data=json.dumps(body), headers=headers)
        self.assertEqual(rsp.status_code, 200)
        rspJson = json.loads(rsp.text)
        self.assertTrue("links" in rspJson)
        links = rspJson["links"]
        self.assertTrue(len(links) == 1) # fails due to empty return
        link = links[0]
        self.assertTrue("title" in link)
        self.assertEqual(link["title"] == "link1")

Spoke to John about this - follow_links should return all links that match the name in the provided groups. Limit and CreateOrder are used in the case where titles is not provided, so they should stay. marker isn't actually checked for by POST_Links, so no change is needed there.

@jreadey I'm not sure I understand how this endpoint is supposed to work with the pattern parameter. testGetPattern expects group ids to be returned that don't contain any links that fit the pattern. Is it meant to return all searched group ids (empty or not) when using a pattern, and not without a pattern?
{'links':
   {'g-f81913f9-909037d3-7091-9b7118-18bf5b': [],
   'g-f81913f9-909037d3-0b41-8c15a0-ba4fad': [],
   'g-f81913f9-909037d3-2304-9163c1-15d503': [
      {'id': 'd-f81913f9-909037d3-cd25-bd6a92-8700e7', 'class': 'H5L_TYPE_HARD', 'created':<PHONE_NUMBER>.4165003, 'title': 'dset2.1'},
      {'id': 'd-f81913f9-909037d3-be98-2bdfa6-91fa48', 'class': 'H5L_TYPE_HARD', 'created':<PHONE_NUMBER>.4451396, 'title': 'dset2.2'}
   ],
    'g-f81913f9-909037d3-f6a8-00d8e6-4046b6': [
      {'id': 'd-f81913f9-909037d3-39d1-9c7ecc-a8b46b', 'class': 'H5L_TYPE_HARD', 'created':<PHONE_NUMBER>.270042, 'title': 'dset1.1.1'},
      {'id': 'd-f81913f9-909037d3-697f-a976fe-b8c909', 'class': 'H5L_TYPE_HARD', 'created':<PHONE_NUMBER>.2981899, 'title': 'dset1.1.2'}
   ],
   'g-f81913f9-909037d3-6cba-d68216-f3d0b1': [],
   'g-f81913f9-909037d3-cc63-497daf-2bf556': []
   }
}

Yes, that is the intent.  You could make the case to not return group ids that contain no links, but I like the  explicit empty list.

Resolved in #314


[Access Request] Table 81 - Gen. Journal Line

Hi Al team,
I would like to access the following functions and variables from the extension object
protected procedure GetCurrency()
    // local procedure GetCurrency()
    begin
        if "Additional-Currency Posting" =
           "Additional-Currency Posting"::"Additional-Currency Amount Only"
        then begin
            if GLSetup."Additional Reporting Currency" = '' then
                ReadGLSetup;
            CurrencyCode := GLSetup."Additional Reporting Currency";
        end else
            CurrencyCode := "Currency Code";

protected var
        Currency: Record Currency;
        CurrExchRate: Record "Currency Exchange Rate";

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. We will update this issue with information about availability.

Please keep this request in mind ;-). We need to call this function as well and want to avoid having duplicates. Thanks :)


 Do you happen to know by any chance?

No, I haven't looked into them myself. Can be in the dependency package like go-rancher etc. @ibuildthecloud may knows more.

@cjellick do you know where these logs come from?

ok, I figured how this logging works:

The controller installs a 3rd party Apache format logger into the http server handler chain
Therefore all http requests are logged after being processed

@yasker
Questions:

Do you suggest we filter out from the logs all http requests with /v1/replicas in the url?
Or some more sophisticated filtering?

No.
It's specify to the log shown above, which is:
::1 - - [02/Jun/2016:20:51:59 +0000] "GET /v1/volumes HTTP/1.1" 200 686
<IP_ADDRESS> - - [02/Jun/2016:20:51:59 +0000] "GET /v1/replicas HTTP/1.1" 200 588

In other words GET requests for:

/v1/volumes
/v1/replicas

Yeah.

Fixed by #183


Support for X.509 Certificate based authentication

I would like to be able to use this mqtt package to authenticate incoming client connections based on a client key / certificate chain. Couldn't find and example for this in the given auth examples folder.
Will I be able to add this functionality using the provided AddHook or AddListener methods?
If not, is this something being worked on ? If not yet, I'd like to be able to contribute towards the same.
Thanks!

Never mind, sorry about this, completely missed the TLS folder under examples.

@IshanDaga did you manage to do this? The TLS clientauth seems to work, but I don't seem to be able to get the certificates/client info from the hooks.

Hey @RangelReale !
I referred to this discussion to move forward : https://github.com/mochi-co/mqtt/discussions/87