Expose encoding/decoding raw packets without streams

Streams are not actually necessary for encoding/decoding, only muxing/demuxing. Refactor encoding/decoding onto a CodecContext, and then have a {Video,Audio,Subtitle}CodecContext which implements the specifics functions.
Do this for #154.

I was tried making some edits to the FFVideo library, though due to the fact that we do not have #174 solved, I can't actually proceed any further. I thought maybe I could load a sample flv file into the library , this would mean the library would set the codec context to flv. Then I can just feed in custom packets by creating a new function which should theoretically decode the packets.
I have yet to try this out but the library I am modifying resides here: https://github.com/oddballz/labs/tree/master/AV

Just a quick follow up for #174 we need to have access to:

avcodec_find_decoder() with the CODEC IDS e.g. AV_CODEC_ID_MPEG1VIDEO
avcodec_alloc_context from which we can just use avcodec_open to open and start using the codec.

I've started making progress in the codec-ctx branch. Encoding works (with a ton of hardcoded options), but decoding roughly does this (lifting the error from #181):
<av.VideoCodecContext video/flv at 0x7f470d5f47e0>
<av.Packet of #0, dts=None, pts=None; 128 bytes at 0x7f4711bd3890>
Traceback (most recent call last):
  File "/home/ubuntu/workspace/PyAV/scratchpad/cctx_decode.py", line 30, in <module>
    frames = cc.decode(packet) or ()
  File "av/codeccontext.pyx", line 83, in av.codeccontext.CodecContext.decode (src/av/codeccontext.c:3598)
  File "av/codeccontext.pyx", line 115, in av.codeccontext.CodecContext.decode (src/av/codeccontext.c:3331)
  File "av/video/codeccontext.pyx", line 134, in av.video.codeccontext.VideoCodecContext._decode_one (src/av/video/codeccontext.c:2109)
  File "av/utils.pyx", line 78, in av.utils.err_check (src/av/utils.c:1517)
av.AVError: [Errno<PHONE_NUMBER>] Invalid data found when processing input
ERROR:libav.flv:Bad picture start code
ERROR:libav.flv:header damaged

I got the same in my "mpeg4" tests. More testing/investigation is needed.

I'm not sure if what I am saying is correct, but when allocating the packet with the data, maybe we should provide with the compressed data and not just a chunk of the file. E.g. when we are streaming, we get the frames of the data. If this is the case, is it only looking to decode the actual frame in the data?
Maybe treating the the file without streams causes this, is it only useful for raw packet data?

I just saw the reference to exactly what you meant here: https://ffmpeg.org/doxygen/trunk/doc_2examples_2decoding_encoding_8c-example.html
See note the note under the video_decode function.
It says:
 if(codec->capabilities&CODEC_CAP_TRUNCATED)
        c->flags|= CODEC_FLAG_TRUNCATED; /* we do not send complete frames */
    /* For some codecs, such as msmpeg4 and mpeg4, width and height
       MUST be initialized there because this information is not
       available in the bitstream. */
    /* open it */
    if (avcodec_open2(c, codec, NULL) < 0) {
        fprintf(stderr, "Could not open codec\n");
        exit(1);
    }
    f = fopen(filename, "rb");
    if (!f) {
        fprintf(stderr, "Could not open %s\n", filename);
        exit(1);
    }
    frame = av_frame_alloc();
    if (!frame) {
        fprintf(stderr, "Could not allocate video frame\n");
        exit(1);
    }
    frame_count = 0;
    for (;;) {
        avpkt.size = fread(inbuf, 1, INBUF_SIZE, f);
        if (avpkt.size == 0)
            break;
        /* NOTE1: some codecs are stream based (mpegvideo, mpegaudio)
           and this is the only method to use them because you cannot
           know the compressed data size before analysing it.
           BUT some other codecs (msmpeg4, mpeg4) are inherently frame
           based, so you must call them with all the data for one
           frame exactly. You must also initialize 'width' and
           'height' before initializing them. */
        /* NOTE2: some codecs allow the raw parameters (frame size,
           sample rate) to be changed at any frame. We handle this, so
           you should also take care of it */
        /* here, we use a stream based decoder (mpeg1video), so we
           feed decoder and see if it could decode a frame */
        avpkt.data = inbuf;
        while (avpkt.size > 0)
            if (decode_write_frame(outfilename, c, frame, &frame_count, &avpkt, 0) < 0)
                exit(1);
    }
    /* some codecs, such as MPEG, transmit the I and P frame with a
       latency of one frame. You must do the following to have a
       chance to get the last frame of the video */
    avpkt.data = NULL;
    avpkt.size = 0;
    decode_write_frame(outfilename, c, frame, &frame_count, &avpkt, 1);

Just pushed another commit. With big enough chunks it is able to decode from mp4 and flv. I think a problem we are running into is that Packets don't mutate as they are consumed to reflect how much data is left, and so for stuff like flv that does not need a parser we are dropping parts of frames across packet boundaries.
Getting somewhere though!

Great work @mikeboers , I really look forward to seeing this library have an option to decode a single frame from a packet (and encode a frame from raw data)!

I was trying to build the latest commit on virtualbox and I seem to be encountering some issues without cythonizing the .pyx files. The previous set of files before the AVCodec context parser commit was working fine.
goel@goel-VirtualBox:~/Desktop/PyAV$ sudo python setup.py build_ext --inplace
running build_ext
running reflect
running config
looking for avformat_open_input... found
looking for pyav_function_should_not_exist... missing
looking for av_calloc... found
looking for av_frame_get_best_effort_timestamp... found
looking for avformat_alloc_output_context2... found
looking for avformat_close_input... found
looking for AVStream.index... found
looking for PyAV.struct_should_not_exist... missing
looking for AVFrame.mb_type... missing
writing build/temp.linux-x86_64-2.7/include/pyav/config.h
running cythonize
Compiling av/utils.pyx because it changed.
[1/1] Cythonizing av/utils.pyx
Compiling av/packet.pyx because it changed.
[1/1] Cythonizing av/packet.pyx
warning: av/packet.pyx:56:13: Unreachable code
Compiling av/descriptor.pyx because it changed.
[1/1] Cythonizing av/descriptor.pyx
Compiling av/bytesource.pyx because it changed.
[1/1] Cythonizing av/bytesource.pyx
Compiling av/_core.pyx because it changed.
[1/1] Cythonizing av/_core.pyx
Compiling av/buffer.pyx because it changed.
[1/1] Cythonizing av/buffer.pyx
Compiling av/stream.pyx because it changed.
[1/1] Cythonizing av/stream.pyx
Compiling av/dictionary.pyx because it changed.
[1/1] Cythonizing av/dictionary.pyx
Compiling av/frame.pyx because it changed.
[1/1] Cythonizing av/frame.pyx
Compiling av/logging.pyx because it changed.
[1/1] Cythonizing av/logging.pyx
Compiling av/plane.pyx because it changed.
[1/1] Cythonizing av/plane.pyx
Compiling av/format.pyx because it changed.
[1/1] Cythonizing av/format.pyx
Compiling av/option.pyx because it changed.
[1/1] Cythonizing av/option.pyx
Compiling av/subtitles/stream.pyx because it changed.
[1/1] Cythonizing av/subtitles/stream.pyx
Compiling av/subtitles/subtitle.pyx because it changed.
[1/1] Cythonizing av/subtitles/subtitle.pyx
Compiling av/audio/layout.pyx because it changed.
[1/1] Cythonizing av/audio/layout.pyx
Compiling av/audio/resampler.pyx because it changed.
[1/1] Cythonizing av/audio/resampler.pyx
Compiling av/audio/stream.pyx because it changed.
[1/1] Cythonizing av/audio/stream.pyx
Compiling av/audio/fifo.pyx because it changed.
[1/1] Cythonizing av/audio/fifo.pyx
Compiling av/audio/frame.pyx because it changed.
[1/1] Cythonizing av/audio/frame.pyx
Compiling av/audio/plane.pyx because it changed.
[1/1] Cythonizing av/audio/plane.pyx
Compiling av/audio/format.pyx because it changed.
[1/1] Cythonizing av/audio/format.pyx
av/codec/context.pyx: cannot find cimported module 'av.codec.codec'
av/codec/context.pxd: cannot find cimported module 'av.codec.codec'
/home/goel/Desktop/PyAV/av/codec/context.pxd: cannot find cimported module 'av.codec.codec'
Compiling av/codec/context.pyx because it changed.
[1/1] Cythonizing av/codec/context.pyx

Error compiling Cython file:
------------------------------------------------------------
...
from libc.stdint cimport int64_t

cimport libav as lib

from av.codec.codec cimport Codec
^
------------------------------------------------------------

av/codec/context.pxd:5:0: 'av/codec/codec.pxd' not found

Error compiling Cython file:
------------------------------------------------------------
...
from libc.stdint cimport int64_t

cimport libav as lib

from av.codec.codec cimport Codec
^
------------------------------------------------------------

av/codec/context.pxd:5:0: 'av/codec/codec/Codec.pxd' not found

Error compiling Cython file:
------------------------------------------------------------
...
    cdef size_t parse_buffer_max_size
    cdef size_t parse_pos

    cdef _init(self, lib.AVCodecContext *ptr)

    cdef readonly Codec codec
                 ^
------------------------------------------------------------

av/codec/context.pxd:22:18: 'Codec' is not a type identifier

Error compiling Cython file:
------------------------------------------------------------
...
    cdef size_t parse_buffer_max_size
    cdef size_t parse_pos

    cdef _init(self, lib.AVCodecContext *ptr)

    cdef readonly Codec codec
                       ^
------------------------------------------------------------

av/codec/context.pxd:22:24: C attribute of type '<error>' cannot be accessed from Python

Error compiling Cython file:
------------------------------------------------------------
...
from libc.stdlib cimport malloc, realloc, free
from cpython cimport PyWeakref_NewRef

cimport libav as lib

from av.codec.codec cimport Codec, wrap_codec
^
------------------------------------------------------------

av/codec/context.pyx:8:0: 'av/codec/codec/wrap_codec.pxd' not found

Error compiling Cython file:
------------------------------------------------------------
...

cdef class CodecContext(object):

    @staticmethod
    def create(codec, mode=None):
        cdef Codec cy_codec = codec if isinstance(codec, Codec) else Codec(codec, mode)
            ^
------------------------------------------------------------

av/codec/context.pyx:38:13: 'Codec' is not a type identifier

Error compiling Cython file:
------------------------------------------------------------
...
cdef class CodecContext(object):

    @staticmethod
    def create(codec, mode=None):
        cdef Codec cy_codec = codec if isinstance(codec, Codec) else Codec(codec, mode)
        cdef lib.AVCodecContext *c_ctx = lib.avcodec_alloc_context3(cy_codec.ptr)
                                                                           ^
------------------------------------------------------------

av/codec/context.pyx:39:76: Cannot convert Python object to 'AVCodec *'

Error compiling Cython file:
------------------------------------------------------------
...
        if sentinel is not _cinit_sentinel:
            raise RuntimeError('cannot instantiate CodecContext')

    cdef _init(self, lib.AVCodecContext *ptr):
        self.ptr = ptr
        self.codec = wrap_codec(self.ptr.codec)
                                       ^
------------------------------------------------------------

av/codec/context.pyx:48:40: Cannot convert 'AVCodec *' to Python object

Error compiling Cython file:
------------------------------------------------------------
...
        # We might pass partial frames.
        if self.codec.ptr.capabilities & lib.CODEC_CAP_TRUNCATED:
            self.ptr.flags |= lib.CODEC_FLAG_TRUNCATED

        # TODO: Options
        err_check(lib.avcodec_open2(self.ptr, self.codec.ptr, NULL))
                                                       ^
------------------------------------------------------------

av/codec/context.pyx:66:56: Cannot convert Python object to 'AVCodec *'
Traceback (most recent call last):
  File "setup.py", line 715, in <module>
    distclass=distclass,
  File "/usr/lib/python2.7/distutils/core.py", line 151, in setup
    dist.run_commands()
  File "/usr/lib/python2.7/distutils/dist.py", line 953, in run_commands
    self.run_command(cmd)
  File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
    cmd_obj.run()
  File "setup.py", line 657, in run
    self.run_command('cythonize')
  File "/usr/lib/python2.7/distutils/cmd.py", line 326, in run_command
    self.distribution.run_command(command)
  File "/usr/lib/python2.7/distutils/dist.py", line 972, in run_command
    cmd_obj.run()
  File "setup.py", line 575, in run
    include_path=ext.include_dirs,
  File "/usr/local/lib/python2.7/dist-packages/Cython/Build/Dependencies.py", line 915, in cythonize
    cythonize_one(*args)
  File "/usr/local/lib/python2.7/dist-packages/Cython/Build/Dependencies.py", line 1037, in cythonize_one
    raise CompileError(None, pyx_file)
Cython.Compiler.Errors.CompileError: av/codec/context.pyx

Hello people,
Is the implementation finished.. And if so, is there a quick example available? Thank you

Hi @tuxuser , I was wondering how you managed to use CodecContext. Is there an example I could see please?
Thank you.

Sure, here is a snippet that works for me
import av

data = b'\xDE\xAD\xBE\xEF'  # Just for illustration
codec_ctx = av.codec.CodecContext.create('aac', 'r')
packet = av.packet.Packet(data)
for frame in codec_ctx.decode(packet):
    decoded_data = frame.planes[0].to_bytes()
    # Do stuff

The original 'scratch'-code: https://github.com/mikeboers/PyAV/blob/master/scratchpad/cctx_decode.py
Did not work for me as CodecContext.parse expects a string... but I wanted to supply binary data of course... That's why I am assembling the av.packet.Packet by myself

Thanks for the help @tuxuser , my issue was similarly like this, I had some h263 RTMP data which I needed to create an flv file from, so I needed a way to decode that data and place it into the file.

@tuxuser Thanks for the example, and noting that the parse doesn't work well for you. That was in the first iteration of the CodecContext refactor, and I haven't revisited it since.

@koenvo Did you manage to solve the problem?
In my case the error is as below:
File "av/codec/context.pyx", line 326, in av.codec.context.CodecContext.decode   File "av/codec/context.pyx", line 372, in av.codec.context.CodecContext.decode   File "av/video/codeccontext.pyx", line 108, in av.video.codeccontext.VideoCodecContext._decode   File "av/utils.pyx", line 105, in av.utils.err_check av.AVError: [Errno<PHONE_NUMBER>] Invalid data found when processing input (libav.h264: no frame!)

nope. But I didn't spend time on it lately. Looks like your error is same as mine..

Some codecs need a few extra data for decoding and I think h264 is one of them. So I made a few changes to the code and provided a function to copy these data from a source CodecContext to a destination CodecContext. In my case, the data was about 40 bytes (so we can easily save it somewhere).
I sent a pull request #287.
@mikeboers Would you please check it?

I've been hitting the same issue when trying to re-decode from raw packets (about no start code, and cannot split NAL units).
@adavoudi I tested your PR locally, and it fixed the problems I was having. Would be great if this could get merged.

I am working with the tello drone which transmits raw h264 through udp socket. How do I get the extradata from the stream ?? The TelloPy library creates a file like object from recveived udp then use av.open on it which result in a very laggy stream.

@l0stb1t can you get this from the container?
Example:
codec_ctx = container.streams.video[0].codec_context
codec_ctx.extradata

@koenvo @jd20 Hi, I want my frame to H264 encoded and then decoded back to original frame. For this i tried the above code and hitting the same issues 'Error splitting the input into NAL units'. Can you provide me any right example/pointer for my problem.

@koenvo Did you manage to solve the problem?
In my case the error is as below:
File "av/codec/context.pyx", line 326, in av.codec.context.CodecContext.decode File "av/codec/context.pyx", line 372, in av.codec.context.CodecContext.decode File "av/video/codeccontext.pyx", line 108, in av.video.codeccontext.VideoCodecContext._decode File "av/utils.pyx", line 105, in av.utils.err_check av.AVError: [Errno<PHONE_NUMBER>] Invalid data found when processing input (libav.h264: no frame!)

did u get solution for this.

Please refrain from hijacking a closed issue. If you have found a bug in pyav please open a new issue. If it's to chat with other users consider using the project's gitter


Half-Precision SGEMV() and SGEMM() not support CblasColMajor

Currently, the implementation of half-precision SGEMV() and SGEMM() does not support CblasColMajor for the order parameter (CBLAS_ORDER).
/** CBLAS_ORDER order parameter is not used. */
static void sgemv_FP16(CBLAS_ORDER order, CBLAS_TRANSPOSE TransA,
                       const unsigned int M, const unsigned int N,
                       const float alpha, const _FP16 *A,
                       const unsigned int lda, const _FP16 *X, const int incX,
                       const float beta, _FP16 *Y, const int incY) {

  unsigned int incy = abs(incY);
  unsigned int incx = abs(incX);

  if (TransA == CblasTrans) {
#if (defined USE__FP16 && USE_NEON)
    nntrainer::neon::sgemv_transpose_neon_fp16(A, X, Y, M, N, alpha, beta);
#else
    sgemv_loop_fp16(i, j, N, M);
#endif
  } else {
#if (defined USE__FP16 && USE_NEON)
    nntrainer::neon::sgemv_neon_fp16(A, X, Y, M, N, alpha, beta);
#else
    sgemv_loop_fp16(j, i, M, N);
#endif
  }
}

This limitation results in issues when trying to use these functions with column-major data layouts.
Such support for CblasColMajor in the half-precision implementations of SGEMV() and SGEMM() is needed.

:octocat: cibot: Thank you for posting issue #2399. The person in charge will reply soon.


A suggestion from EMBEDDED TEXTURES

Good afternoon here in Brazil,
One suggestion, could you put under SET ALL TEXTURES EMBEDDED, which is for SELECTED MATERIALS, a function that sets ALL TEXTURES of the object to EMBEDDED, without having to click ONE BY ONE ...

This is not a bad idea per se, but I do recommend most of the time to don't use embedded textures, and this change will encourage doing models without any texture dictionaries. Which can lead to bad practices.

Yes, I know, but if the model is of small size, few quantities of vertices, few faces, we put embed to accelerate the work because in the end, the sum of weight, will be little! !!
Simillar Like this !!

!

If you say that the model is small, then there are 2-3 textures, and this is 2-3 clicks on the button to make the texture EMBEDDED

Just use a texture dictionary, there's no real reason to embed its textures.

Sorry, I don't think this is necessary, but thanks for the suggestion.


Make snippet buttons invisible rather than hidden to prevent issues

Overview
On Chrome, clicking the icon de-selected the snippet, which caused the button to disappear and the onClick to never get called. This makes the button transparent instead, which means the onClick still gets called.
connected issues and PRs:
Jira ticket: https://binnenland.atlassian.net/browse/GN-5019
GN PR: https://github.com/lblod/frontend-gelinkt-notuleren/pull/716
Setup
N/A
How to test/reproduce
Seems to only be easily reproducible in GN/RB and on Chrome. After inserting a snippet, the buttons that appear when the snippet is selected are now functional wherever you click on them. Before clicking on the icon would not work. Moving the selection away from the snippet should hide the buttons.
Challenges/uncertainties
Seems like weird timing issues and is very hard to debug.
Checks PR readiness

[ ] UI: works on smaller screen sizes
[ ] UI: feedback for any loading/error states
[ ] Check if dummy app is correctly updated
[ ] Check cancel/go-back flows
[x] changelog
[x] npm lint
[x] no new deprecations

@elpoelma Hmm, I was able to reproduce it, but I used the snippet that was used in the video in the Jira ticket, and didn't test extensively with other snippets. Can you try again using that one? If you can't find it, the snippet was a relatively long paragraph of text, long enough to increase the size of the snippet node from the minimum. Perhaps that is a necessary condition for this bug to appear? I used Chromium 128.0.6613.137 on Arch.

@piemonkey I tested it with the same 'lorem ipsum' snippet, but still could not reproduce the issue. I'll see if I can try to reproduce it with the previous chrome version, but that would be a big coincidence.

it seems I managed to make the button black in the screenshot, this went away though
I'm pretty sure this is unrelated

The trick seems to be setting contenteditable='false' on the div that's wrapping the buttons. I think it prevents the selectionchange event from firing, which the editor plugs into to update it's selection (which ultimately causes the issue, cause the new selection falls outside of the snippet node, causing the buttons to be deactivated)
@elpoelma do you see any issues with this

@piemonkey bonus fix you can add:
simply add this.controller.focus() to openModal() BEFORE this.showModal = true
this will cause the editor to refocus after you close the modal, allowing one to continue typing.
(the reason you set it before is because the AU modal uses focus-trap, which takes over focus control and gives it back to the last element that was focused before it activated)

The trick seems to be setting contenteditable='false' on the div that's wrapping the buttons. I think it prevents the selectionchange event from firing, which the editor plugs into to update it's selection (which ultimately causes the issue, cause the new selection falls outside of the snippet node, causing the buttons to be deactivated) @elpoelma do you see any issues with this

I think this is the best way to approach this issue. As a rule of thumb, with ember block nodes with content, it's better to only put contenteditable: false on elements that really need it (such as these buttons). You (almost) never want to have nested contenteditable: false > contenteditable: true structures. (inline nodes with content are an exception, as well as any nested prosemirror editors)

@abeforgit I've made the button container not contenteditable. I couldn't reproduce the bug with my previous change though, so could you test whether it fixes it for you?

@abeforgit @piemonkey can confirm that the contenteditable: false solution fixes the issue for me.


Update Default Cromwell Version for Dockstore CLI

Feature Request
The default Cromwell version is currently 30.2, which is a getting a little outdated -- they are up to release 36.
┆Issue is synchronized with this Jira Story
┆Issue Type: Story
┆Fix Versions: Dockstore 1.6
┆Sprint: Seabright Sprint 5 Electric
┆Issue Number: DOCK-183

It might be worth learning how to use tool tester and run in the background, but unknown how many WDL workflows we have.

Verified with DOCKSTORE_VERSION=1.6.0-beta.0 when running dockstore CLI.


Style add/delete slide icons

Add add slide & delete slide icons
Move the menu to the bottom, and use flex to keep it fixed as slide outline grows

The blue highlighting for the selected slide looks weird, but it looked weird on master, too. :cry:
/cc @rgerstenberger

@kenwheeler can you take a look at the issue? I think some styles were updated that affect the list and I didn't do my due diligence :/

Trying to find the offending styles. It looks like if you take this branch, and open index.js in slide-menu, changing line 286 to 140 instead of slideHeight fixes it, but I'm going to look further because I haven't identified the exact cause, might be a better fix somewhere

Ok, it looks like the root cause is here https://github.com/FormidableLabs/spectacle-editor/commit/d17d4302daffa0678e9284f288c17ca338cfa527, the conversion border-box universally. A simpler and more reliable fix for this branch would be to add box-sizing: content-box to .slideOuter in slide-menu/index.css. Confirmed working on this branch

@kenwheeler can you just push the fix on this branch please? 💃

💥

Daaaang! Thanks for the inspection and quick fix. I should have expected consequences from normalizing so late. I'll keep a lookout for more, and border-box should be much nicer. :pray:
Is this good to :dancer: merge :dancer:?

Yes, approved! Merge away 👯


server/build.rs still not firing if I change a template or static file -> requires touch of build.rs itself

I am no longer seeing this issue


Update Dockerfile to install target package deps

This PR adds code that would install target package dependencies, but doesn't actually work as it runs into issue with rate limiting unauthenticated against github...
https://github.com/insightsengineering/r-pkg-installation-validation/blob/dev/add_deps/report-generator.R#L23
mentioned the issue in issue #7 : https://github.com/insightsengineering/r-pkg-installation-validation/issues/7#issuecomment-915310280

Looks great! I've created https://github.com/insightsengineering/r-pkg-installation-validation/issues/13 to resolve the errors obtained from the reports.


PyRuSH-1.0.8.tar.gz -  Installing build dependencies: finished with status 'error'

Hi, I am trying to build a container with medspacy and receiving the following error.
Could anyone point me in the direction of what I've done incorrectly
Thanks
Rob
 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 181.6/181.6 kB 12.2 MB/s eta 0:00:00

Collecting PyRuSH>=1.0.8 (from medspacy->-r requirements.txt (line 10))
Downloading PyRuSH-1.0.8.tar.gz (46 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 46.6/46.6 kB 28.3 MB/s eta 0:00:00
Installing build dependencies: started
Installing build dependencies: finished with status 'error'
error: subprocess-exited-with-error
                                                                           Building wheels for collected packages: quicksectx
                                                                                Building wheel for quicksectx (pyproject.toml): started
                                                                                Building wheel for quicksectx (pyproject.toml): finished with status 'error'
                                                                                error: subprocess-exited-with-error

                                                                                × Building wheel for quicksectx (pyproject.toml) did not run successfully.
                     │ exit code: 1
                                           ╰─> [33 lines of output]
                                                                               /tmp/pip-build-env-r5mnhjfo/overlay/lib/python3.10/site-packages/setuptools/config/_apply_pyprojecttoml.py:80: SetuptoolsWarning: `install_requires` overwritten in `pyproject.toml` (dependencies)
                                                                                corresp(dist, value, root_dir)
                                                                                running bdist_wheel
                                                                                running build
                                                                                running build_py
                        creating build
                                                  creating build/lib.linux-aarch64-cpython-310
                                                                                creating build/lib.linux-aarch64-cpython-310/quicksect
                                                                                copying quicksect/__init__.py -> build/lib.linux-aarch64-cpython-310/quicksect
                                                                   creating build/lib.linux-aarch64-cpython-310/quicksectx
                                                                                copying quicksectx/__init__.py -> build/lib.linux-aarch64-cpython-310/quicksectx
                               running egg_info
                                                           writing quicksectx.egg-info/PKG-INFO
                                                                                writing dependency_links to quicksectx.egg-info/dependency_links.txt
                                                                                writing requirements to quicksectx.egg-info/requires.txt
                                                            writing top-level names to quicksectx.egg-info/top_level.txt
                                                                                reading manifest file 'quicksectx.egg-info/SOURCES.txt'
                                                                                reading manifest template 'MANIFEST.in'
                                                       adding license file 'LICENSE'
                                                                                writing manifest file 'quicksectx.egg-info/SOURCES.txt'
                                                                                copying quicksect/quicksect.cpp -> build/lib.linux-aarch64-cpython-310/quicksect
                                                            copying quicksect/quicksect.pyx -> build/lib.linux-aarch64-cpython-310/quicksect
                                                                                copying quicksectx/quicksectx.cpp -> build/lib.linux-aarch64-cpython-310/quicksectx
                                                    copying quicksectx/quicksectx.pxd -> build/lib.linux-aarch64-cpython-310/quicksectx
                                                                                copying quicksectx/quicksectx.pyx -> build/lib.linux-aarch64-cpython-310/quicksectx
                                               running build_ext
                                                                            building 'quicksect.quicksect' extension
                                                                                creating build/temp.linux-aarch64-cpython-310
                                                                                creating build/temp.linux-aarch64-cpython-310/quicksect
                                                         gcc -Wno-unused-result -Wsign-compare -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -I/tmp/pip-install-y2l67nd0/quicksectx_7f7ce7948da34a27adbe10f5d8f548bb/quicksectx -I/tmp/pip-install-y2l67nd0/quicksectx_7f7ce7948da34a27adbe10f5d8f548bb -I/tmp/pip-install-y2l67nd0/quicksectx_7f7ce7948da34a27adbe10f5d8f548bb/quicksect -I/usr/local/include/python3.10 -c quicksect/quicksect.cpp -o build/temp.linux-aarch64-cpython-310/quicksect/quicksect.o
                                                                                gcc: fatal error: cannot execute ‘cc1plus’: execvp: No such file or directory
                                                                                compilation terminated.
                                       error: command '/usr/bin/gcc' failed with exit code 1
                                                                                [end of output]

                                                                                note: This error originates from a subprocess, and is likely not a problem with pip.
                              ERROR: Failed building wheel for quicksectx
                                                                               Failed to build quicksectx
                                                                                ERROR: Could not build wheels for quicksectx, which is required to install pyproject.toml-based projects
                          [end of output]

                                             note: This error originates from a subprocess, and is likely not a problem with pip.

error: subprocess-exited-with-error
                               × pip subprocess to install build dependencies did not run successfully.
                                                                                │ exit code: 1
                                                                                ╰─> See above for output.

Here is my Dockerfile
FROM quay.io/centos/centos:stream9
Install necessary tools and Python 3.10.13
RUN dnf install -y --allowerasing curl gcc openssl-devel bzip2-devel libffi-devel make zlib-devel
Download and install Python 3.10.13 from source
RUN curl -O https://www.python.org/ftp/python/3.10.13/Python-3.10.13.tgz &&
tar xvf Python-3.10.13.tgz &&
cd Python-3.10.13 &&
./configure --enable-optimizations &&
make altinstall
Use the installed Python by default
RUN ln -s /usr/local/bin/python3.10 /usr/bin/python &&
ln -s /usr/local/bin/pip3.10 /usr/bin/pip
Install pip
RUN curl https://bootstrap.pypa.io/get-pip.py -o get-pip.py &&
python get-pip.py
Install and configure Dapr
RUN curl -sSL https://raw.githubusercontent.com/dapr/cli/master/install/install.sh -o /tmp/install.sh
RUN chmod +x /tmp/install.sh && /tmp/install.sh
RUN dapr -h
Set non-root user with fixed UID
ARG APP_UID=1000
RUN useradd -m -u "$APP_UID" appuser
USER $APP_UID
ARG DAPR_BUILD_DIR
COPY $DAPR_BUILD_DIR /opt/dapr
ENV PATH="/opt/dapr/:${PATH}"
RUN dapr init --slim
Copy app
WORKDIR /home/appuser/app
COPY . /home/appuser/app/
Install app packages without cache
RUN python -m pip install --user --no-cache-dir -r requirements.txt
RUN python -m spacy download en_core_web_trf
EXPOSE 8082
CMD ["python", "main.py"]

Have you ensured that you have installed g++?
Top solutions for this are to ensure that it is installed.  If you are not sure, can you share what you see when you run this?
where cc1plus
https://askubuntu.com/a/637029

Thank you, that resolved the issue.  I am using quay.io/centos/centos:stream9 as the image.


does not work

I use sptarkov.

I didn't find the NLog.dll.nlog file in it
when using the installer, it gives this:

And where can I download aki-efttrainer.dll ?

The Bradmower is off.
During installation .NET Framework says that a newer version is installed.

See #81


Findings from fuzzing drivers/lms

Fuzzing the LMS implementation with https://github.com/chipsalliance/caliptra-sw/pull/618 - again, the libFuzzer feature enabled - triggers ASAN with the following:
ERROR: AddressSanitizer: SEGV on unknown address 0x000000000004
This is at <caliptra-sw>/drivers/src/lms.rs:387:12

Using struct-aware fuzzing (or simply running for longer), the target panics with the following:
thread '<unnamed>' panicked at 'attempt to add with overflow', <caliptra-sw>/drivers/src/lms.rs:393:33

I can't see where the bug uncovered by ASAN was fixed, that first line wasn't changed, but I can't make it trigger now either. Anyways, I found these in local runs while writing them, in the future, it'll come from CI.


better Point type factoring

There is now a type for identifying actual blocks, called BlockPoint.
It's parameterized on the slot and hash, and specialized to use the
class/families variant, so that it's not forced upon the programmer.
Next, there is a Point functor which is just like Maybe; it adds the
Origin.
This way, we eliminate silly things like Point 42 GenesisHash. The
"genesis point" is now called Origin, and it has no slot number nor
header hash.
According to Ouroboros.Network.Chain, headSlot Genesis = SlotNo 0.
Also, valid chains have strictly increasing slot numbers. So in this
model, the first actual block has SlotNo 1. But that's contrary to the
cardano-sl implementation, which gives SlotNo 0 to the first block.
In ouroboros-consensus, does any block have SlotNo 0?
Point 0 (BlockHash hash) is apparently nonsense too, for all hash.
Motivation for this change: I'm reworking the hash index in byron-proxy
so that it will be ready for use with the ChainDB (currently it is paired
with an ImmutableDB). This means the index must deal with forks.
The plan is to have it follow by way of the newReader interface. Naturally,
it will use Points to deal with rollbacks. I don't want to (nor should I have to)
write a program which knows how to rollback to the point at slot 42 with the
genesis hash. This makes no sense. With this patch, I won't have to.
The patch only goes so far as to make ouroboros-network compile and its tests
pass. I will patch downstream packages only if this pull request is approved in
principle.

There is
rewindChainState :: OuroborosTag p => NodeConfig p -> ChainState p -> SlotNo -> Maybe (ChainState p)

What does this mean at SlotNo 0? Does it remove all blocks? Or does the block at SlotNo 0 remain? Is there ever a block at SlotNo 0? In mainnet, there is, but in the ouroboros-network model, head of the empty chain Genesis :: Chain has slot SlotNo 0.

@avieth it perfectly makes sense to have
data Chain block = Genesis | Chain block :> block

and and the same time:
data Point block = Origin | Point block

But let's see what the consensus team things about it, @mrBliss, this might also affect cardano-ledger
integration with ouroboros-consensus.

Pushed another commit which makes ouroboros-consensus compile and tests pass.

One thing I noticed is that Ouroboros.Network.Chain.validExtension used to rule out any block that had SlotNo 0. While that is in principle a legitimate way to go, I think it's not ideal. It reserves SlotNo 0 for something which does not correspond to a block (the genesis is not a block). In the new factoring introduced in this patch, every SlotNo n is as good as any other when it comes to indexing a chain, with no special treatment for n = 0. Then, if the programmer wishes to include the genesis, they can throw in Origin by way of TPoint.
A nice summary of the benefit of this patch can be seen in Ouroboros.Storage.ChainDB.Model, where the partial function notGenesis :: Point blk -> HeaderHash blk has been removed.

@dcoutts @coot checks passed

@mrBliss This Point type change will affect a ChainDB implementation so it would be good to hear your thoughts on it.

@mrBliss This Point type change will affect a ChainDB implementation so it would be good to hear your thoughts on it.

Ok, I'll give this a look after the weekend.

Alternative go at starting this in #690. See commentary there.

I wholeheartedly agree with Duncan.
I'm all for refactoring  the Point type to rule out things like Point 42 GenesisHash.
I also understand why you want to assign SlotNo 0 to Genesis, especially since cardano-sl is using SlotNo 0 for a regular block. However, this will be a less straight-forward change than the Point refactoring, so I'd rather do this in a separate PR.
We're also using BlockNo 0 for Genesis, would that have to change too?
Just a thought: we need a separate case for Genesis in multiple types: Point, ChainHash, and now for SlotNo. Maybe we can use one sum type, isomorphic to Maybe, for this (names are still temporary):
data BlockOrGen a = Genesis | Block a
  deriving (Functor)

data BlockPoint blk = Point SlotNo (HeaderHash blk)
type Point      blk = BlockOrGen (BlockPoint blk)
type GenSlotNo      = BlockOrGen SlotNo
type ChainHash  blk = BlockOrGen (HeaderHash blk)

I also understand why you want to assign SlotNo 0 to Genesis, especially since cardano-sl is using SlotNo 0 for a regular block. However, this will be a less straight-forward change than the Point refactoring, so I'd rather do this in a separate PR.
We're also using BlockNo 0 for Genesis, would that have to change too?

The first slot is slot 0. If there is a block here, its block number is 1.

Just a thought: we need a separate case for Genesis in multiple types: Point, ChainHash, and now for SlotNo. Maybe we can use one sum type, isomorphic to Maybe, for this (names are still temporary):
data BlockOrGen a = Genesis | Block a
  deriving (Functor)

data BlockPoint blk = Point SlotNo (HeaderHash blk)
type Point      blk = BlockOrGen (BlockPoint blk)
type GenSlotNo      = BlockOrGen SlotNo
type ChainHash  blk = BlockOrGen (HeaderHash blk)

This is exactly what I've done... but I've called `BlockOrGen` `TPoint` instead and everybody seems to hate the name. No problem, I always intended to change it.

Just a thought: we need a separate case for Genesis in multiple types: Point, ChainHash, and now for SlotNo. Maybe we can use one sum type, isomorphic to Maybe, for this (names are still temporary):
data BlockOrGen a = Genesis | Block a
  deriving (Functor)

data BlockPoint blk = Point SlotNo (HeaderHash blk)
type Point      blk = BlockOrGen (BlockPoint blk)
type GenSlotNo      = BlockOrGen SlotNo
type ChainHash  blk = BlockOrGen (HeaderHash blk)

This is exactly what I've done... but I've called BlockOrGen TPoint instead and everybody seems to hate the name. No problem, I always intended to change it.

I see. Yeah, the name TPoint confused me, it made me think it was only meant for points, not for slots or hashes.

Obsoleted by #706


Changeset publish seems to be ignoring the publishConfig settings

Affected Packages
@trueplan/forecast-components
@trueplan/forecast-icons
@trueplan/forecast-theme
Problem
Previous to moving to changesets, we were publishing to the Github package registry. Now we're publishing directory to NPM. In doing so, running the changeset publish script seems to ignore our publishConfig settings in each of package.json files. See example here: https://github.com/trueplan/forecast/blob/1e3bb8953e7957c6f2287975f94310119df2b0eb/packages/components/package.json#L16
So we're now getting a stray src/index.ts directory in the NPM packages which breaks out imports, i.e. import {foo} from @trueplan/forecast-componentsnow has to becomeimport {foo} from @trueplan/forecast-components/dist.
Proposed solution
Basically changeset publish would overwrite the main setting in package.json based off the publishConfig setting.

This feature request proposes adjustments to "packing" process (preparing a publishable tarball) and proposes for us to get involved in that (so we could "rewrite" some package.json fields with the ones defined in publishConfig).
I'm afraid that we don't have any plans for this. This feels like something out of the scope of this project and something that would probably open a can of worms for us - it would be somewhat hard to replicate all other assumptions about this packing process that people might have, based on their experience with their package managers. At the moment, we almost completely delegate this responsibility to package managers (npm, yarn, pnpm).
That being said - I would love to hear out how you have been using this before and I would like to discuss alternatives.

What were you using before to accomplish this? Which exact tool supports rewriting those specific fields in this way?
I see that your regular package.json#main is set to src/index.ts - so I assume that the goal of the whole thing is to make the development easier~, to "link" your monorepo packages, so a bundler (or a similar) tool can always resolve to your source files. Would you say that this is correct? What tooling are you using there? What needs to resolve to those source files?

@Andarist thanks for the reply. The error/confusion here stems from a bad rollup config on our end. Closing this issue since we resolved the bad config.


Request to add native support for Feign Reactive

Hi, I am trying to add Spring Native (version 0.12.1) to my Spring Boot app (version 2.7.3) with Feign Reactive.  I am running into issues with configuring native hints for Feign Reactive.  I have tried adding the following content into META-INF\native-image\<my group id>\<my artifact id>\reflect-config.json, but it didn't work, upon app startup, I got error complaining the bean definition for my DemoClient class, which is annotated with @ReactiveFeignClient, couldn't be found.
[
  {
    "name": "reactivefeign.spring.config.ReactiveFeignAutoConfiguration",
    "allDeclaredMethods": true,
    "allDeclaredFields": true,
    "allDeclaredConstructors": true,
    "allDeclaredClasses": true,
    "allPublicClasses": true,
    "allPublicConstructors": true,
    "allPublicFields": true,
    "allPublicMethods": true
  }
]

I have also tried annotating NativeHint in my main app class DemoApplication, but it didn't work either, same error.
@SpringBootApplication
@EnableReactiveFeignClients
@NativeHint(
        trigger = ReactiveFeignClient.class,
        types = {
                @TypeHint(types = ReactiveFeignAutoConfiguration.class,
		        access = { TypeAccess.DECLARED_METHODS, TypeAccess.DECLARED_FIELDS,
				        TypeAccess.DECLARED_CLASSES, TypeAccess.DECLARED_CONSTRUCTORS,
				        TypeAccess.PUBLIC_CLASSES, TypeAccess.PUBLIC_CONSTRUCTORS,
				        TypeAccess.PUBLIC_FIELDS, TypeAccess.PUBLIC_METHODS
                })
        }
)
public class DemoApplication {
	public static void main(String[] args) {
		SpringApplication.run(DemoApplication.class, args);
	}
}

I'd like to know what I am missing in properly configuring native hints for Feign Reactive.  Any chance Feign Reactive native support can be incorporated into future release of Spring Native?
Thanks,
Wenqi

First be aware that we are transitioning from Spring Native which brings experimental native support for Spring Boot 2.x to Spring Boot 3 and Spring Framework 6 who are going to provide official out of the box support for native, the release is expected late november.
I would advise to begin migrating it to Spring Boot 3 / Spring Framework 6 to see if it work out of the box, and if not, adding missing hints on Feign Reactive side since it is an external project. Maybe create a related issue on https://github.com/PlaytikaOSS/feign-reactive side and ping me if you need guidance.


64-bit Taint Labels

[ ] update dfsan instrumentation and runtime to use 64-bit labels
[x] update PolyTracker instrumentation and runtime

This is now OBE. Increasing taint labels to 64bits would make the shadow memory region too large; we'd either have to reduce application memory or find a different way to store shadow memory. Revisit this later, but for now we will be sticking with 32bit labels.


CI Integration

Investigate CI integrations (circle CI, jenkins) to see if we can automate at least the testing process and ideally, the whole build upload (fastlane can help on that)

Closing in favor of #77 since we already have CircleCi up and running


[dev_compiler] Help debugger map js symbols to dart symbols

Issue
Currently, the debugger has heuristics to filter out temporary variables from the variables window, and temporary fields from JavaScript objects.
Suggestion
Store type and symbol information so the debugger can map Javascript symbols and fields to the corresponding dart ones.

duplicate of https://github.com/dart-lang/sdk/issues/40273


log channel must be created after initializing the developerHooks

The actual sequence of initialization can result in a type error.

Fixed on master (v2.1.0) and on release-2.0.x (v2.0.1).


CTD when launching the game with 0.1.0

PostureModLog.txt
Windows 10 (Latest, afaik)
App/ Calibrations: v1.08.1
Seamless Co-op: v1.4.3
Elden Mod Loader: v3.2
Latest version of ModEngine 2
Custom mod files (map, reg.bin, models) on top for personal overhaul project
The only other DLL being loaded is eldenring_title_skip.dll

Thanks for report
Interesting, as log-wise everything seems to work fine, at least to moment of hooking everything.
App/ Calibrations: v1.08.1 - does that means you play on ER version that is 1.08.1? Mod was created and play-tested on 1.09.1, therefore previous versions might not work.
Are you playing with Full Screen screen mode?
Could you try to start mod without any other mods running, just to figure if this is compatibility issue?
Is eldenring_title_skip.dll from Skip the intro logos and remove white startup screen
Thx

Mod was created and play-tested on 1.09.1, therefore previous versions might not work.

Funnily enough, my friend is also running 1.08.1, and the mod does seem to work flawlessly for them (after a few tries of getting it to show up). So it seems a likely cause, but not definite.

Are you playing with Full Screen screen mode?
I am playing with Borderless Windowed. I'll test with Fullscreen enabled instead.

Could you try to start mod without any other mods running, just to figure if this is compatibility issue?
I will see if I can test that.

Is eldenring_title_skip.dll from...
Custom dll build by Chainfailure (from the general FromSoft modding discord, ?ServerName?). It isn't public yet (I don't think), but I did try some attempts without that dll loaded, and unfortunately the same crashes continued. I had my friend load that particular dll as well, and it didn't cause any CTDs for them.

Actually playing on borderless should cause less issues :)
If issue won't be resolved while launching mod alone, then that could be a bigger issue which I might not be capable of resolving right now, due to lack of logs in places where it crashes. Technically, you could try to debug it yourself if you are familiar with Visual Studio, but if not, then I might have to make some special version that could acquire more information about potential issue you are experiencing.

So, after a bit more testing, I can confirm that swapping to/ from Fullscreen does not solve the crashes, and neither does setting ModEngine 2 to use a blank mod folder. Currently rather dumbfounded as to what could be causing this...

Sure, for now unfortunately I have no solution, but will try to create slightly more debug version, that could be capable of logging a lot more extensively then right now, sorry for trouble. I am also assuming that you have not edited anything inside .ini file. Perhaps something with directX12 is causing issue, but that is just blindly guessing ideas, most likely have to have more logs

Late response here, apologies, but correct - other than enabling logs, I haven't changed anything else within the .ini file. For now, I'll remain patient and wait for further updates/ developments. Best of luck, mate, and if I can help in any way with testing, I'd be glad to assist :D

Hey,
I made second release: 0.2.0
You can check out if you still have crash. In case you still have it, there is new debug version that aims at creating more logs, so you can check it out and send debug version of logs.
Thx

PostureModLog.txt
So, unfortunately, both the regular 0.2.0 and Debug 0.2.0 still do not work... but differently.
The ModLog is from the regular 0.2.0 with logging enabled, and it will still CTD at the main menu. Other than that, not much changes.
On the other hand, the Debug .dll won't even load, according to Mod Loader. Upon starting the game, I get a "PostureBarMod.dll will not load... " popup. The game will not CTD, and the ModLog won't even change.

On an incredibly confusing success note - on using the regular 0.2.0, and simply disabling the logging feature... the CTDs stop.
Either that or repetitive re-launching of the game finally allowed it to work, but considering it now works flawlessly on the attempt that I disabled logging for the hell of it? No idea what's going on there, but at the very least, I'm incredibly happy that it works.

Ok, that is interesting that debug version would not work at all, I will send you special version that still do a lot of logging, but might pass Loader, hopefully. It is indeed weird how it worked one time.... . In that case it would seem like issue might not have 100% reproducibility. Also I have made mod try to activate after 10 seconds in this special version, maybe more time for ER to load is somehow a thing that could help here. BTW, remember to use 0.2.0 .ini file, there was a little change made between 0.1.0 and 0.2.0
PostureBarMod.zip

Apologies for the long time to respond, I wanted to make sure that things are working as they should be. CTDs with that particular Debug version that you have sent me are far less prevalent, though IIRC when I disabled the "logging" feature, the game would not start properly. I assume this is just a result of the Debug version, as using it normally (with logging enabled, and nothing else disabled other than the control UI) has resulted in a much more CTD-free experience, if I get them at all.
Thank you for helping me so far, I can't wait to see where this project goes in the future :D


Metasploit Update from 3.3.1 to 4.12.5

Motivation for this change
Things done

[X] Tested using sandboxing
(nix.useSandbox on NixOS,
or option build-use-sandbox in nix.conf
on non-NixOS)
Built on platform(s)

[X] NixOS
[ ] OS X
[ ] Linux

[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
[X] Tested execution of all binary files (usually in ./result/bin/)
[X] Fits CONTRIBUTING.md.

May I suggest that you add yourself as the maintainer of this package?

The commits must be cleaned up.

Once the commits are cleaned up I'm sure we can take this, if it works for you --- I have no personal stake in this, at any rate so whatever you think makes sense is good by me.

Awesome!  I will address your suggestions, and will have an update shortly.


Say which env vars are missing in the error and expose that.

This replaces {:error, :could_not_load_config} with {:error, {:could_not_load_config, "ENV vars not set: FOO, BAR"}}, saves time trying to puzzle out which ones are really missing.

This looks great @derekkraan :+1:.

This will be tremendously helpful :)

This has been merged into master


level=error msg="Recovered from panic in http handler: net/http: abort Handler"

Hi! I'm running traefik in docker,
traefik:1.7.2-alpine
on ubuntu linux
And getting this message filling my log.. any idea how to fix?
level=error msg="Recovered from panic in http handler: net/http: abort Handler"
Version:      v1.7.2
Codename:     maroilles
Go version:   go1.11.1
Built:        2018-10-04_01:44:36PM
OS/Arch:      linux/amd64

Hello,
could you update Traefik to current latest version: 1.7.22
Next could you follow the issue template, thanks.

How do I label that image on docker??
Right now it’s “traefik:1.7.2-alpine”
On Mar 20, 2020, 6:48 PM -0500, Ludovic Fernandez<EMAIL_ADDRESS>wrote:

Hello,
could you update Traefik to current latest version: 1.7.22
Next could you follow the issue template, thanks.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

https://hub.docker.com/_/traefik?tab=tags
traefik:1.7.22-alpine

Seems to be working but now I have no logs?

Zack Cleaver
On March 20, 2020 at 7:21 PM, Ludovic Fernandez<EMAIL_ADDRESS>wrote:
https://hub.docker.com/_/traefik?tab=tags
traefik:1.7.22-alpine
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.


Reformatting some of the code

Just cleaning up some whitespace, getting rid of a few unused and shadow variables (my mistake when I rebased incorrectly).
luacheck is now down to 64 warnings :)

Changes fixed up now.

So we are intentionally making
strCurrentScreen
a global? I'm just making sure the internet is not getting in the way of being on the same page?

It's not a global, its a local variable to main.lua
On Wed, 10 Nov 2021 at 10:42, Fox @.***> wrote:

So we are intentionally making
strCurrentScreen
a global? I'm just making sure the internet is not getting in the way of
being on the same page?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/togfoxy/MarsLander/pull/221#issuecomment-964674607,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAFNONZMZWIHDUCC5PSYIVTULG5WJANCNFSM5HVI3C4Q
.
Triage notifications on the go with GitHub Mobile for iOS
https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675
or Android
https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

Right. I see now. I didn't notice. Did I make that local to the module? I forget. Lolz.

I didn't play test this but the changes are minimal.
This PR is older than the other PR so I'll merge it now. Thanks!


reinitialization

Could you please explain the avoid_clsmodel_reinitialization in args?

Hi @CHR-ray, were you able to figure that out?


Running ds run twice on master dotmesh causes infinite hang on polling intercluster transfer

See these instructions: https://github.com/dotmesh-io/dotscience-roadsigns/tree/master/ds-run-demo
The following order of steps caused the issue:

fetching data
train model (will fail saying signnames.csv does not exist)
upload signnames.csv
train model

Possibly same thing as https://github.com/dotmesh-io/e2e/issues/31


I am using this theme:
https://startbootstrap.com/template-overviews/agency/
and in agency.js I added:
var lazyLoad = new LazyLoad();
$('.modal').on('shown.bs.modal', function () {
    lazyLoad.update();
});

but the problem is that when the modal which contains many images is opened all of them get loaded instantly. I would like them to load lazily, i.e. when scrolling down.
How can I do that?

In fact I notice that the last few images in the modal often don't show unless the window is resized, moved or the view is zoomed in/out using Ctrl and +/-

Hi @anchev and thanks for choosing my LazyLoad.

If so, you need to initialize a new LazyLoad when the modal is shown, and pass the scrolling container in the container option.
Something like:
$('.modal').on('shown.bs.modal', function () {
    var lazyLoad = new LazyLoad({
         container: $(this) /// <--- not sure if this works here, read below
    });
});

In the container you need to pass the element that scrolls (so the one that has the overflow property set to scroll or auto).
You could also call lazyLoad.destroy() when the modal is closed, in order to save memory and do everything properly.

Thanks for the reply. However it seems to me I didn't explain correctly.
I want to have lazy load both on the main page, as well as in the modals. So as far as I understand the lazyLoad object must be created initially (right?) Then the question is how to make it work also for the modal.
I hope that clarifies what I am looking for.

I think I figured it out:
var globalLazyLoad = new LazyLoad();

var modalLazyLoad;
$('.modal')
        .bind('shown.bs.modal', function () {
            modalLazyLoad = new LazyLoad({
                container: this
            });
        })
        .bind('hidden.bs.modal', function () {
            modalLazyLoad.destroy();
        });

It seems to work. Could you please confirm if this is the right way to do it?

Yess!!! That's correct. Congratulations.

Thank you!

Psst: have you already starred this repo? All you need to do is to press the Star ★ button on the top right corner of the website. ;)

I'm working on getting this modal to work the same way. Cant seem to get it working with the same code. Can I re-open this?


Removes dependency on no longer maintained parity-wasm crate

The parity-wasm crate is no longer maintained, so relying on it is a liability
The parity-wasm crate, even the newest version, fails to parse "modern" WASI modules produced by TinyGo and other languages (the infamous "unknown opcode" error). In order to ensure we can properly parse newer WASI modules, we need to remove the dependency on parity-wasm.

Instead, the parser is now a crate provided by the bytecode alliance.
wasmCloud modules signed prior to this version of wascap will have their module hashes given a free pass. It's not a breaking change, and the module hash validation comes back as soon as people sign modules with 0.9.0 or greater.

Looks like the hashing might not be as deterministic as it should be. Exploring.

I already changed the section name in this branch can you back out your commit?

Unless I misunderstand @stevelr 's comment I think this does the same type of hash as before (hashing the full module bytes without the contents of the JWT) and this looks good to me. We'll definitely need to be careful rolling this out in the wasmCloud host and for signing actors because of the breaking parser change, let's make sure to document that.

The new hash only hashes the contents of the code sections and the data sections (which is almost the entire file). This is mainly because we used to use a round-trip through parity-wasm to sanitize the bytes before generating the hash. Since we don't have that any more, we're only hashing the sections that give us a byte array (function bodies and data sections).
This does mean that less of the file is hashed, but the net change in security is practically nil, since you can't actually accomplish anything by tampering with the unhashed sections of the .wasm file.

Just one non-nit comment to discuss


Different look of generated QR-Codes - are all ISO/IEC 18004 compatible?

Terry, you explaned clearly (in #99) that 2D datamatrix (and i assume QRCode too) may look different coding same content. I want to ask if you think that your actual version of QRCode generating meets the ISO/IEC 18004 standard as well. I have a ISO compatible example, which codes the given content in a different look.
Thanks for any explaining this point.

Yes.
Modern QR Code is ISO/IEC 18004 *. The standard does not dictate how the data is to be encoded, only what the meaning of the codewords is and their effect to state machine when decoding. The standard provides a reference algorithm for generation a minimal encoding sequence, however it is neither complete nor does it result in the minimal encoding so implementation have to roll their own.
* Some application of "QR Code" like Swiss QR deliberately paint over the top and by doing so violate ISO/IEC 18004 and undermine the data redundancy guarantees provided by the ISO specification. I would argue strongly that they therefore ought not to use the term "QR".

Terry, many thanks for this explanation. I Thought so, but was unsure...
kind regards j- th


The data link and the model link are the same.

The data link and the model link are the same.

The data link and the model link are the same.

The data link and the model link are the same.

Thank you for your attention!
The current code is related to the MolTC model, and it includes scattered download links in each submodule for the corresponding datasets required.
We are updating the integrated dataset MoT-instructions to the latest version, which will be displayed soon.
Fortunately, its temporary absence will not affect the operation of the MolTC model at all, and you can run MolTC directly.
Thank you once again for your attention! :)

The data link and the model link are the same.

I just checked again, and the two links point to the same place. I will update them within two days.

The data link and the model link are the same.

Done! Thanks!


Error when define the schema name using the "search_path" option in database settings

Hello.
When the schema name is defined using the OPTIONS keyword in the database settings, the sql that verifies if the view exists for a specific schema returns always 0 (sql here) because the function _schema_and_name returns public instead of the right schema name.
Environment

Python 3.10;
Django 4.1;
Django-pgviews 0.8.4.

How to reproduce

Configure the database with the OPTIONS keyword as following:DATABASES = {
    "default": {
        "ENGINE": "django.db.backends.postgresql",
        # ...
        "OPTIONS": {
            "options": "-c search_path=custom_schema_name"
        },
    }
}

Make sure that the specified schema exists and the db user has permission:CREATE SCHEMA custom_schema_name;
ALTER SCHEMA custom_schema_name OWNER TO db_username;

Execute python manage.py sync_pgviews or python manage.py migrate. Is expected an traceback like this:...

  File "./venv/lib/python3.10/site-packages/django_pgviews/view.py", line 232, in create_materialized_view
    _create_mat_view(cursor, view_name, query, view_query.params, with_data=view_cls.with_data)
  File "./venv/lib/python3.10/site-packages/django_pgviews/view.py", line 84, in _create_mat_view
    cursor.execute(
psycopg2.errors.DuplicateTable: relation "app_view" already exists

Fix suggestion
This is only a suggestion and I can create a pull request if you like.
django_pgviews/view.py
# ...
RE_DB_SEARCH_PATH = re.compile(r'search_path=(?P<s>[\'"]?)(?P<sp>\w+)(?P=s)')
# ...

def _schema_and_name(connection, view_name):
    if "." in view_name:
        return view_name.split(".", 1)

    try:
        schema_name = connection.schema_name
    except AttributeError:
        search_path = RE_DB_SEARCH_PATH.search(connection.settings_dict.get('OPTIONS', {}).get('options', ''))
        if search_path:
            schema_name = search_path.group('sp')
        else:
            with connection.cursor() as cursor:
                cursor.execute("SELECT current_schema;")
                schema_name = cursor.fetchone()[0]
    return schema_name, view_name

If the schema is hardcoded in the settings I think I'd much prefer if instead of using regex to search options we introduced a new setting which would simply say what the schema should be?

Is just a theory and requires testing.
Depending on how to define the schemas in the settings file, the same issue will happen when is using multiple databases with different schemas. If define the variable as a string, is for sure that the same problem will occur. Define as a dictionary solve the problem, but creates verbosity.
The advantage of the doing this in the settings is the control we will have. However, we are more susceptible to errors due the necessity to change in two places the same configuration instead of one.
What I imagined using the settings:
DATABASES = {
    "default": {
        # ...
        "OPTIONS": {
            "options": "-c search_path=custom_schema_name"
        },
    },
    "db2": {
        # ...
        "OPTIONS": {
            "options": "-c search_path=another_schema_name"
        },
    },
}

# Will fail when is using the database "db2"
PG_VIEWS_SCHEMA = "custom_schema_name"

# May be a solution, but creates verbosity.
PG_VIEWS_SCHEMAS = {
    "default": "custom_schema_name",
    "db2": "another_schema_name",
}

On the other hand, I've no guarantee that the my solution will work using multiple databases with custom routers. It seems more complex and can leads to unexpected issues.
In short, I prefer the automation, but your approach is simplest and also a suitable solution for me.
PS.: The purpose of this text was to give us an overview about the problem.
Next step
Based on that, which solution do you consider most suitable? We can use the settings solution using the dictionary to use it in _schema_and_name function.

Hm I quite like the variation of having two settings variables (PG_VIEWS_DEFAULT_SCHEMA would be public by default, PG_VIEWS_SCHEMAS would be an empty dictionary by default), somehow seems cleaner than having a regex or an extra query to get a schema in each call of _schema_and_name.
I think especially since these are two things that are not particularly likely to happen (having multiple databases, and defining schemas in OPTIONS), and the combination is even less likely, I would like not to create too much overhead in accounting for rare cases.
Yes, having more settings does create some verbosity and some duplication, but I think it's a case of set and forget, that you need to just get it right once on setup and then never worry about it again.

So, do we both agreed to use this two settings variables? Which naming standard do you want to use? Or are these names good for you?

I'm good with PG_VIEWS_DEFAULT_SCHEMA and PG_VIEWS_SCHEMAS

Hello, @mikicz.
I'm having trouble configuring the project. Basically the views creation is not respecting the app name when try to apply the migration of an specific app.
Example:
$ python manage.py migrate auth

Result:
Operations to perform:
  Apply all migrations: auth
Running migrations:
  Applying contenttypes.0001_initial... OK
  Applying contenttypes.0002_remove_content_type_name... OK
  Applying auth.0001_initial... OK
  Applying auth.0002_alter_permission_name_max_length... OK
  Applying auth.0003_alter_user_email_max_length... OK
  Applying auth.0004_alter_user_username_opts... OK
  Applying auth.0005_alter_user_last_login_null... OK
  Applying auth.0006_require_contenttypes_0002... OK
  Applying auth.0007_alter_validators_add_error_messages... OK
  Applying auth.0008_alter_user_username_max_length... OK
  Applying auth.0009_alter_user_last_name_max_length... OK
  Applying auth.0010_alter_group_name_max_length... OK
  Applying auth.0011_update_proxy_permissions... OK
  Applying auth.0012_alter_user_first_name_max_length... OK
All applications have migrated, time to sync
pgview viewtest.Superusers created
pgview viewtest.LatestSuperusers created
pgview viewtest.SimpleUser created
Traceback (most recent call last):
  ...
  File ".../django-pgviews/django_pgviews/models.py", line 81, in run_backlog
    status = create_view(
  File "/usr/local/lib/python3.10/contextlib.py", line 79, in inner
    return func(*args, **kwds)
  File ".../django-pgviews/django_pgviews/view.py", line 297, in create_view
    cursor.execute("CREATE OR REPLACE VIEW {0} AS {1};".format(view_name, view_query.query), view_query.params)
psycopg2.errors.UndefinedTable: relation "viewtest_testmodel" does not exist
LINE 1: ...est_relatedview AS SELECT id AS model_id, id FROM viewtest_t...
                                                             ^

I was trying to configure the app first to execute the tests. So I was thinking if this could be this another bug.

So looking at those migrations and that error I think the issue is that the table for the model TestModel does not exist in the database yet - the migrations didn't run for it, so the materialized view can't use it. It's either because the migration for the model doesn't exist or it's because you're running a subselection of migrations (in the command you have auth, but contenttypes ran as well, so not sure what is actually happening

My best guess is that app is just verifying if the migration process has bee executed by all apps that have a models.py file. This means that the pgviews will try to create the views every time, even if the target app is not the app that have the view. This approach is not the good because creates a limitation.
A possible solution is try to move the views creation to the migrations file instead of use the post_migrate signal. The update trigger keeps it as it is.
To do this we need to define a few things:

Consider the possibility of we may need to define the minimal Django version. I thing the python version will not be a issue;
Search how to add new operations in migration file. I my opinion for now the best is to use the operation RunSQL. Using a queryset or a pure string will be compatible. The advantage of this is that we will keep the change history;
If you consider a valid task, it's a good idea to create a new issue for this problem.

The reason I said about to use queryset is because I'm defining the SQL this way:
class City(ReadOnlyMaterializedView):
    # ...
    @classmethod
    def view_queryset(cls):
        return (
            Territory.objects.only('id', 'code', 'name', 'is_enabled', 'country', 'administrative_division')
            .annotate(
                microregion_id=models.F('parent_territory_id'),
                mesoregion_id=models.F('parent_territory__parent_territory_id'),
                federative_unit_id=models.F('parent_territory__parent_territory__parent_territory_id'),
                region_id=models.F('parent_territory__parent_territory__parent_territory__parent_territory_id'),
            )
            .filter(
                administrative_division_id=cls.ADMINISTRATIVE_DIVISION.CITY,
                parent_territory__parent_territory__parent_territory__administrative_division_id=(
                    cls.ADMINISTRATIVE_DIVISION.FEDERATIVE_UNIT
                ),
                parent_territory__parent_territory__parent_territory__parent_territory__administrative_division_id=(
                    cls.ADMINISTRATIVE_DIVISION.REGION
                ),
            )
        )

    @classmethod
    @property
    @lru_cache
    def sql(cls):
        return str(cls.view_queryset().query)

My best guess is that app is just verifying if the migration process has bee executed by all apps that have a models.py file. This means that the pgviews will try to create the views every time, even if the target app is not the app that have the view.

Not really, the app doesn't interact with migrations in any way except for using the post_migrate hook.

This approach is not the good because creates a limitation.

Yes, but not massive one though I think - you want to be running all migrations in most cases anyway.
If you run migrations for specific apps often, you can override the ViewConfig app config to override the ready method, to for example not run the signal if an environment variable is set.

A possible solution is try to move the views creation to the migrations file instead of use the post_migrate signal.

I do agree that if I were writing this library from scratch I would probably try to write it like that, but currently you would basically need to rewrite most of  this library, which I will not be doing. There's also stuff this library supports which probably would be very hard to do using migrations.

The reason I said about to use queryset is because I'm defining the SQL this way:

Neat - does it work?

Fixed in #28, release 0.10.0


go.mod: bump sigs.k8s.io/controller-runtime from 0.15.1 to 0.16.0

Closes: #1505

Codecov Report

Merging #1507 (800c887) into main (6861ef5) will not change coverage.
The diff coverage is n/a.

:exclamation: Current head 800c887 differs from pull request most recent head 60530ec. Consider uploading reports for the commit 60530ec to get more accurate results

@@           Coverage Diff           @@
##             main    #1507   +/-   ##
=======================================
  Coverage   50.04%   50.04%
=======================================
  Files          43       43
  Lines        4884     4884
=======================================
  Hits         2444     2444
  Misses       2301     2301
  Partials      139      139

:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more


Fixed callback signature in file.read for keymap.json

The previous signature used just callback, taking the 'null' value for err and assigning it to keymap, throwing a null-value error when the keymap variable was accessed later on.

any updates on this?


Create and refactor user dropdown menu

This ticket encompasses a few different aspects:

Within WonderTix, there are 3-5 separate but identical dropdown components used for navigation between customer-facing and admin pages. These should be combined into one component.

When fixing this, there is a bug with the home pages's mobile drop down menu where you cannot click the buttons (as the menu disappears prior to being redirected anyway). This will probably be fixed in the process.

There are (at least) 2 admin top-bar components when there should instead be 1 reusable one.

User story: As a client, I want the navigation drop downs to work and the navigation bars and website to be elegantly designed for ease of performance and less chance of myself experiencing bugs.


[RFE] Rancher should only reconcile CAPI manifests it creates

Is your feature request related to a problem? Please describe.
I cannot currently install Cluster API into the same k8s cluster as Rancher Manager when the embedded-cluster-api feature flag is set to true which it is by default. If I want to use CAPI i need to set this feature flag to false, but this then means i cannot create RKE2 based clusters.
Describe the solution you'd like
I would like to be able to install CAPI in the same cluster as Rancher Manager without disabling the embedded CAPI  feature.
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
The embedded CAPI controllers in Rancher should only reconcile CAPI manifests it created as part of creating an RKE2 based cluster.

This will be needed for future integration with CAPI.


Support for python 3.12

Hello! Is there any specific reason for not supporting Python 3.12? I've checked all the base dependencies already support it
Any plan to add support?

Maybe you can try to re-install the Anaconda because it will install Python 3.7 or 3.8, meanwhile, make sure you have installed it in the right place. If it doesn't working, try to uninstall the Python 3.12 manually and install the correct version.

Hi @PRFina,
Thank you for checking the dependencies. I just created a pull request to add support for python 3.12 and will merge it shortly


Rust-reqwest client fails because of null values in tags arrays from petstore.swagger.io

Steps to Reproduce
1. Generate the rust-reqwest based client
docker run --rm -v ${PWD}:/local/out/rust/ openapitools/openapi-generator-cli generate     -i http://petstore.swagger.io/v2/swagger.json     -g rust     -o /local/out/rust/generated --additional-properties packageName=petstore_client --library=reqwest

2. Use it to call find_pets_by_status against petstore.swagger.io
use petstore_client;

fn main() -> Result<(), Box<dyn std::error::Error>> {
    let configuration = petstore_client::apis::configuration::Configuration::new();
    let apiclient = petstore_client::apis::client::APIClient::new(configuration);
    let status = vec![std::string::String::from("pending")];
    let result = apiclient.pet_api().find_pets_by_status(status);
    println!("result = {:?}", result);
    Ok(())
}

3. See error with null tags
result = Err(Reqwest(Error(Json(Error("invalid type: null, expected struct Tag", line: 1, column: 2807)))))

Background
I generated the rust-reqwest based client and tried to do a find_pets_by_status operation, but I got this error:
result = Err(Reqwest(Error(Json(Error("invalid type: null, expected struct Tag", line: 1, column: 2807)))))

Sure enough, when I hit the API directly I see that there are null values in the tags arrays for some pets:
$ curl -X GET "https://petstore.swagger.io/v2/pet/findByStatus?status=pending" -H  "accept: application/json" | jq ".[].tags"
...
[
  {
    "id": 0,
    "name": "string"
  }
]
[
  null
]
[
  null
]
[
  null
]
[
  {
    "id": 0,
    "name": "Asdasd"
  }
]
...

The spec that I generated this client from doesn't say anything about nulls being allowed:
$ curl --silent --output - http://petstore.swagger.io/v2/swagger.json | jq ".definitions.Pet.properties.tags"
{
  "type": "array",
  "xml": {
    "name": "tag",
    "wrapped": true
  },
  "items": {
    "$ref": "#/definitions/Tag"
  }
}

The spec doesn't mention null at all:
$ curl --silent --output - http://petstore.swagger.io/v2/swagger.json | jq "." | grep null
(nothing)

I'm not sure if nulls should be allowed in arrays and the client is wrong, or if they shouldn't and the server is wrong.  I see this issue which makes me think null values being allowed wasn't intended to be the default.
To get it working, I had to change this line in the Pet model:
    pub tags: Option<Vec<crate::models::Tag>>,

To this:
    pub tags: Option<Vec<Option<crate::models::Tag>>>,

Thanks for your work on this project!  Let me know if there's a better place I should file this.

This repository is for the spec alone and not any of the tools. Please file the ticket with the respective product.

Ah, sorry @webron.  I got this confused with the generator.  I'll go file this there: https://github.com/OpenAPITools/openapi-generator/.


Copy does not work in Svelte, Paste does.

There is an issue with Copying a range of values in the svelte-datagrid. useClipboard is enables and ctx[8] is set to true. However only the paste works and that is only by copying the values from the RevoGrid main demo. In the svelte demo codesandbox using cmd + c crashes the sandbox with a:
NoModificationAllowedError
Modifications are not allowed for this document

Sandbox: Reproduction
... Same code
<RevoGrid class="grid" on:beforeedit={onEdit} {source} useClipboard range resize="true" {columns} theme="material"/>

Outside of the Sandbox, no errors are thrown to console.
Dev System:
Environment
› OS: Mac OS 12.6.1 X64
› Node.js: 16.14.2
› npm: 8.5.0
› pnpm: 7.11.0
› VSCode
› WebViews: Firefox, Safari
Thank you

I can confirm that this is the case.

Was issue in grid, pls verify if it's still a problem for v4. Can't reproduce.


Caravele doesn't provide internal picorv32 interrupts!

The Caravel SOC design has one external interrupt pin, but doesn't seem to provide any accessible internal interrupt ports for internal wishbone slave peripheral user projects that would need them. It would be a shame to have to drive an extra output pin just to loop it back to the external interrupt input pin.

You're wanting to have the user project be able to raise an interrupt on the managment SoC through the wishbone bus?

I believe that is the feature request seen on slack, correct.

Not over the bus. Wishbone doesn't support it. More likely one or two unused wires into the interrupt controller. Something akin to the user_clock2 signal user project port.

Not over the bus. Wishbone doesn't support it. More likely one or two unused wires into the interrupt controller. Something akin to the user_clock2 signal user project port.

This issue was corrected on the caravel version for MPW-two, so I am closing this issue now.


refactor music-box to use new musica-core library

the musica library source code was moved to a new repo (musica-core), which was made a submodule in music-box and MICM_Chemistry. The unit tests for the musica library were moved to musica-core and a testing infrastructure (but no real tests) was set up in MICM_Chemistry

closes #27

Thanks. This looks like a useful reorganization


Populate dev database

As a developer I want prepopulated data in my database So That It can be consumed and tested (locally, OpenShift)
Additional Context

Use a script or OpenShift configMap to populate the pipeline database
Use a script or other means to populate the database locally (docker-compose)
Assume this is safe to deploy to prod (for now)
Here's a configMap example

Acceptance Criteria

[ ] Given a new deployment, When started, Then view data
[ ] Given some data-related tests, When started, Then they pass

Definition of Done

[ ] There is at least one table with any sample data
[ ] This can be viewed in Docker Compose (locally)
[ ] This can be viewed in a Dev PR (OpenShift)
[ ] There is one tests that checks for some of this data
[ ] All other tests and steps continue to pass
[ ] Merged

Resolved by #234


fixed #363 PHP_IDE_CONFIG variable.

cc @LarryEitel @Mahmoudz @thelittlebug
Signed-off-by: Bo-Yi Wu<EMAIL_ADDRESS>

I see no reason to hold back from merging this PR especially if you have confirmed the issue. I will work to get caught up with LaraDock and further confirm your PR is good. :)

@LarryEitel In workspace container. I got the different result from PHP_IDE_CONFIG  variable.
The PHP_IDE_CONFIG="serverName=laravel" environment variable. It will output "serverName=laravel".
The PHP_IDE_CONFIG=serverName=laravel environment variable. It will output serverName=laravel without double quote.
$ export PHP_IDE_CONFIG="serverName=laravel"
$ echo $PHP_IDE_CONFIG
serverName=laravel
$ export PHP_IDE_CONFIG="\"serverName=laravel\""
$ echo $PHP_IDE_CONFIG
"serverName=laravel"

I think we don't need the double quote in PHP_IDE_CONFIG variable.

Now I recall noticing seeing the same thing. It DOES need the double quote.
I hit a bump in the road and am unable to remote debug laravel as before. Have not tracked down why. I CAN debug unit tests though. Once I resolve that problem I will be able to give more attention to this.  :)


Add ECDSA/RSA-based JWT token support

Implemented RSA and ECDSA type of JWT key (RS* and ES* algo) checking.
Login/generation part not included.
Testing code
Tested using certtool from GnuTLS,  jwt and onefile-websrv.
Generation of keys
certtool -p --outfile rsa.key
# ECDSA keys are considerably smaller
certtool -p --outfile ecdsa.key --ecdsa

Setting public keys in prest.toml
certtool --pubkey-info --load-privkey ecdsa.key

Copy-paste PEM data between and including BEGIN and END lines as multi-line string value for jwt.key using """ syntax in prest.toml like this:
[jwt]
algo = "ES256"
key = """
-----BEGIN PUBLIC KEY-----
MFkwEwYHKoZIzj0CAQYIKoZIzj0DAQcDQgAEiU5COUED4Jtml5qd6S48D1828jvn
NPO+ZSY6VA7tBXmaGCCFP0sIUDgYRhCu2qYj2jeq3dbpMlZvn7jDgpPzMQ==
-----END PUBLIC KEY-----
"""

Generating tokens with jwt
token="$(jwt -sign + -key rsa.key -alg RS256)"
curl -H "Authorization: Bearer $token" localhost:3000/databases

Generating JWT token on-fly with onefile-websrv
Should go without saying that for real-world use, this server should be secured with additional configuration.
onefile-websrv -map "/rsa=jwt:{alg=RS256,exp=ts:+1h}file:rsa.key" -map "/ecdsa=jwt:{alg=ES256,exp=ts:+1h}file:ecdsa.key" -map "/hs=jwt:{alg=HS256,exp=ts:+1h}s3cr3t" -listen <IP_ADDRESS>:3001
# for ECDSA keys
curl -H "Authorization: Bearer $(curl -s localhost:3001/ecdsa)" http://localhost:3000/databases
# for RSA kes
curl -H "Authorization: Bearer $(curl -s localhost:3001/rsa)" http://localhost:3000/databases
# for shared secrets
curl -H "Authorization: Bearer $(curl -s localhost:3001/hs)" http://localhost:3000/databases

 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.Lauri Korts-Pärn seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.You have signed the CLA already but the status is still pending? Let us recheck it.

After submitting, I noticed there was actually already pull request #552 ... My approach does not have slice panic problem, because I use strings.HasPrefix, and is probably slightly faster, because it parses the keys at startup, not  at each request. IMHO easier to catch problems with key setup.
It doesn't use jwt.Parse*PEM functions though, instead going to directly parsing pem, very much like jwt.Parse*PEM do, and also support private keys.
Which approach would you prefer?


Offset not taking parent margins into account

I'm not certain, but I don't think you are correctly accounting for a margin applied to an input field when using the offset. My text inputs are margin-left: 20px through the entire site but when applying the datepicker it is off:

Modifying the script and offsetting the values by my expected margins worked, I'm looking into a more generic solution so I can fork and submit, but I thought I'd give you the heads up.

I ran into this same "parent margin" issue. I was able to fix it by using the container option. With this option the date picker popup is appended to the specified container rather than the end of the body tag. This fixed the popup offset issue for me. Ex:

  <input type="text" class="datepicker form-control" value="05/21/2015" readonly>

$('.datepicker').datepicker({
  format: 'mm/dd/yyyy',
  container: '.date-input-group'
});

See also #1662


[SPARK-45402][SQL][PYTHON] Add UDTF API for 'analyze' to return a buffer to consume on each class creation

What changes were proposed in this pull request?
This PR adds a Python UDTF API for 'analyze' to return a buffer to consume on each class creation.

The AnalyzeResult class now contains a new string field prepare_buffer.
If assigned to a non-empty value, the UDTF should have another method prepare that accepts the string argument, which will get called after __init__ when the class is  created.
The format of the buffer is opaque and known only to the UDTF. Common use-cases including serializing protocol buffers or JSON objects into the buffer in order to help organize the contents therein.

For example, this UDTF accepts a constant scalar string argument, then assigns this value to the buffer.
@udtf
class TestUDTF:
    def __init__(self):
        self._total = 0
        self._buffer = None

    @staticmethod
    def analyze(argument, _):
        return AnalyzeResult(
            schema=StructType().add("total", IntegerType()).add("buffer", StringType()),
            prepare_buffer=argument.value,
            with_single_partition=True)

    def prepare(self, buffer):
        self._buffer = buffer
        self._total = len(buffer)

    def eval(self, argument, row: Row):
        self._total += 1

    def terminate(self):
        yield self._total, self._buffer

Why are the changes needed?
In this way, the UDTF can perform potentially expensive initialization logic in the analyze method just once and result the result of such initialization rather than repeating the initialization in eval.
Does this PR introduce any user-facing change?
Yes, see above.
How was this patch tested?
This PR adds new unit test coverage.
Was this patch authored or co-authored using generative AI tooling?
No.

cc @ueshin @allisonwang-db @HyukjinKwon

Implementation seems fine from a cursory look, but let me defer to @allisonwang-db and @ueshin for the design.

Hi @allisonwang-db @ueshin thanks for your reviews, these were good comments, please look again! I think the new API is better now.

The failed tests seem not related to this PR. Let me merge this now.

Thanks! merging to master.


rust_analyzer get_root_dir fails assert

Description
When trying to get the root dir of the current Rust project it fails with the error:
E5108: Error executing lua ...ig/lua/lspconfig/server_configurations/rust_analyzer.lua:14: assertion failed!
stack traceback:
        [C]: in function 'assert'
        ...ig/lua/lspconfig/server_configurations/rust_analyzer.lua:14: in function 'get_workspace_dir'
        ...ig/lua/lspconfig/server_configurations/rust_analyzer.lua:63: in function 'get_root_dir'
        [string ":lua"]:1: in main chunk

Example command: :lua print(require('lspconfig')["rust_analyzer"].get_root_dir(vim.fn.getcwd()))
Neovim version
NVIM v0.9.0
Build type: Release
LuaJIT 2.1.0-beta3
Nvim-lspconfig version
No response
Operating system and version
Arch Linux (6.3.2)
Affected language servers
rust_analyzer
Steps to reproduce

Create a random project cargo new test-error
cd test-error
nvim src/main.rs
Run :lua print(require('lspconfig')["rust_analyzer"].get_root_dir(vim.fn.getcwd()))

Actual behavior
Crash
Expected behavior
Not a crash, get the root dir printed.
Minimal config
???

LSP log

you can't run it in cmdline it's async must run in a coroutine


Create an SSR endpoint that hydrates off of wc-registry

oh yeah... it's mostly working tho there are some low level issues that might just be bc the library is experimental. It's working w/ meme-maker but things that get into deeply nested dependencies w/ calls to window need updated to globalThis and it has graceful failures right now... but MANY things should be SSR'ing automatically right now
This is the magic script but for the backend.
This script also has implications for #2008 as it could be used to hydrate automatically on nodejs deploys which have a backend. We should have a methodology for handling standard vs hydrated route content

Error [ERR_MODULE_NOT_FOUND]: Cannot find module '/var/task/utilities/requestHelpers.js' imported from /var/task/api/experiments/hydrateSsr.js

https://github.com/thescientist13/greenwood-lit-ssr

https://github.com/lit/lit/pull/4712

https://webcomponents.hax.cloud/api/hydrateSsr