https://self not working

Hi,
I have a function in a router that receives a request and sends a request to another service.
@router.route("/users/{username}/bookings")
def user_booking(uri: ParseResult, request: Request, params):
    global users
    if users == None:
        open_file()
    username = params['username']
    if username not in users:
        raise Exception("Not found")
    resp = send(Request("GET", f"/bookings/{username}", {}, None))
    print(f"Response: {resp}")
    return Response(200, {}, resp.body)

I get the following error:

It seems like set_authority is throwing an error. On looking at the source code of that function, it has not been implemented.
def set_authority(self, authority: Optional[str]) -> None:
        """
        Set the HTTP Authority for the Request. A value of `none` may be used
        with Related Schemes which do not require an Authority. The HTTP and
        HTTPS schemes always require an authority. Fails if the string given is
        not a syntactically valid uri authority.

        Raises: `spin_sdk.wit.types.Err(None)`
        """
        raise NotImplementedError

Another thing is the error says line 883 and this is not at line 883.
at line 883, the function is:
def set_between_bytes_timeout(self, duration: Optional[int]) -> None:
        """
        Set the timeout for receiving subsequent chunks of bytes in the Response
        body stream. An error return value indicates that this timeout is not
        supported.

        Raises: `spin_sdk.wit.types.Err(None)`
        """
        raise NotImplementedError

On adding a few logs into spin-python-sdk, I see the following differences between this example and my code:
Example:
request Request(method='GET', uri='https://example.com', headers={}, body=None)
Parsed Url: ParseResult(scheme='https', netloc='example.com', path='', params='', query='', fragment='')

Output of my component:
request Request(method='GET', uri='/bookings/dwight_schrute', headers={}, body=None)
Parsed Url: ParseResult(scheme='', netloc='', path='/bookings/dwight_schrute', params='', query='', fragment='')

I see that both the scheme and netloc fields are empty.
On changing the outbound hosts to:
allowed_outbound_hosts = ["http://*:*", "https://*:*"]

from:
allowed_outbound_hosts = ["http://self", "https://self"]

and changing the url to point to http://<IP_ADDRESS>:3000/users/{username}/bookings (the default url that spin exposes the application to), it seems to be working.
On changing the url to http://self/users/{username}/bookings it throws a DNS not found error, as https://self is not a website that exists.

Thanks for reporting this, @thesuhas.
The spin_sdk.wit code in the spin_sdk package is not actually used at runtime -- that code is just stub bindings generated for the purposes of documentation and IDE integration.  The actual code is generated by componentize-py at build time such that each imported function calls into the host instead of raising a NotImplementedError.  That also affects the line numbers, since the function bodies are different.  Sorry for the confusion.
In this case, I'm not surprised the /bookings/dwight_schrute path doesn't work, since wasi:http needs a full URL including a protocol and an authority.  Have you tried following https://developer.fermyon.com/spin/v2/http-outbound#making-http-requests-within-an-application ?  I think that's the official way to do this, but @itowlson could probably correct me if I'm mistaken.

Oh, but I just noticed that http://self should work according to https://developer.fermyon.com/spin/v2/http-outbound#intra-application-http-requests-by-route.  Hopefully @itowlson can tell us what we're missing here.

I think I have figured out what the issue is.
In the rust sdk:
impl OutboundHttp {
    /// Check if guest module is allowed to send request to URL, based on the list of
    /// allowed hosts defined by the runtime. If the url passed in is a relative path,
    /// only allow if allowed_hosts contains `self`. If the list of allowed hosts contains
    /// `insecure:allow-all`, then all hosts are allowed.
    /// If `None` is passed, the guest module is not allowed to send the request.
    fn is_allowed(&mut self, url: &str) -> Result<bool, HttpError> {
        if url.starts_with('/') {
            return Ok(self.allowed_hosts.allows_relative_url(&["http", "https"]));
        }

        Ok(OutboundUrl::parse(url, "https")
            .map(|u| self.allowed_hosts.allows(&u))
            .unwrap_or_default())
    }
}

That check is not done here.
I believe it can be an easy fix. Something like:
    url_parsed = parse.urlparse(request.uri)
    if url_parsed.netloc == '' and url_parsed.path.startswith('/'):
        # If not allowed, throw error
        # Else set scheme to http/https and netloc to <IP_ADDRESS>:port

@dicej Paths are meant to work. The Spin runtime translates them into self-requests (provided self is an allowed host) by prepending the host and protocol of the original inbound request.
@thesuhas I don't think http://self works as part of the URL - it is a magic identifier for allowed_outbound_hosts.  As you note, https://developer.fermyon.com/spin/v2/http-outbound#intra-application-http-requests-by-route describes this.  The expected pseudo-URL is /api/customers.
However, as Joel notes, if your target environment supports it, it's more efficient to use local service chaining (https://developer.fermyon.com/spin/v2/http-outbound#local-service-chaining), which does not travel over the network.
@thesuhas regarding where the error is created, it is in the Spin runtime - the OutboundHttp::is_allowed fragment you quote is part of the Spin host, not part of the Rust SDK.

Thanks @itowlson !
But, having allowed_outbound_hosts = ["http://self", "https://self"] and just using a url such as /api/customers seems to be throwing an error for now.
If I would not want to switch to local service chaining, how could I fix this?

I am not sure @thesuhas.  I believe it ought to work, and unless I am missing something it's a bug that it doesn't.  I will have a look but I don't know much about the Python side.

Sounds like we need to add the equivalent relative URL handling @thesuhas found in the Rust SDK to the Python SDK, if I'm understanding correctly.

Actually, where did you find that code in the Rust SDK, @thesuhas ?  I'm not seeing it.

It's not in the Rust SDK though @dicej.  That's the Spin Outbound HTTP host component.

If I would want to add the equivalent relative URL handling and make a contribution, how would I gain access to both the allowed outbound hosts , the url and the port that spin is deploying the application on?
If one could access them, this check could be added into the python sdk itself.

Actually, where did you find that code in the Rust SDK, @thesuhas ? I'm not seeing it.

I found it here: https://github.com/fermyon/spin/blob/9f1d9dbc43ae0bde8ffe3729ac9b545b7d571e15/crates/outbound-http/src/host_impl.rs#L23

Oh, actually I think this needs to be ported to the Python SDK: https://github.com/fermyon/spin-rust-sdk/blob/184946fdd3cb48de3c3af60f8e053b42947c791b/src/http/conversions.rs#L557-L560

It's not in the Rust SDK though @dicej. That's the Spin Outbound HTTP host component.

Does this mean that this is where the check happens even while using the python sdk? And does this mean spin composes an Outbound HTTP component to the spin component it builds and the flow of the request is Spin Component Created by User -> Outbound HTTP Component -> Request is sent?

The problem is that with the current Python SDK, the relative URL requests aren't even making it to the host, since set_authority is choking.  We need to port the above code I linked to from spin-rust-sdk to fix that.

See also https://github.com/fermyon/spin-rust-sdk/commit/9f59a5ea6d4575618bc4bbc63b6825ec63c2c341

And https://github.com/fermyon/spin-rust-sdk/issues/8

@thesuhas It's not quite composition, but conceptually similar.  The HTTP service is provided by the Spin host, and the Spin host understands the special self-request syntax and service chaining URLs.  So when you make a HTTP request through any SDK, that gets passed through to the Spin host which, after validating, performs the actual request.
The outbouind hosts validation etc. has to be in the runtime rather than in the SDK, because the SDK is strictly optional.  You can write a Spin component using raw component tooling and the Spin WITs.  We cannot depend on the SDK for security checking.

@thesuhas It's not quite composition, but conceptually similar. The HTTP service is provided by the Spin host, and the Spin host understands the special self-request syntax and service chaining URLs. So when you make a HTTP request through any SDK, that gets passed through to the Spin host which, after validating, performs the actual request.
The outbouind hosts validation etc. has to be in the runtime rather than in the SDK, because the SDK is strictly optional. You can write a Spin component using raw component tooling and the Spin WITs. We cannot depend on the SDK for security checking.

So this means that the only fix in this case would be setting the authority correctly as then the spin host would have all the information it needs to validate and perform the request?
And in this case, authority would be the domain name and port right? And domain name would be the URL at which the spin application is running (localhost if running locally) and port would just be the port that the spin application is listening at?

@thesuhas Looking at the Rust SDK code I think the idea is not to prepend a full URL but to inject a dummy authority consisting only of the port.

Can you try this, please?
diff --git a/src/spin_sdk/http/__init__.py b/src/spin_sdk/http/__init__.py
index dd98107..094d94a 100644
--- a/src/spin_sdk/http/__init__.py
+++ b/src/spin_sdk/http/__init__.py
@@ -174,7 +174,14 @@ async def send_async(request: Request) -> Response:
     outgoing_request = OutgoingRequest(Fields.from_list(headers))
     outgoing_request.set_method(method)
     outgoing_request.set_scheme(scheme)
-    outgoing_request.set_authority(url_parsed.netloc)
+    if url_parsed.netloc is None:
+        if scheme == "http":
+            authority = ":80"
+        else:
+            authority = ":443"
+    else:
+        authority = url_parsed.netloc
+    outgoing_request.set_authority(authority)
     path_and_query = url_parsed.path
     if url_parsed.query:
         path_and_query += '?' + url_parsed.query

BTW, if that doesn't work we might need to check if url_parsed.netloc is non-None and non-empty.  And I guess I should probably just test it myself :)

Can you try this, please?
diff --git a/src/spin_sdk/http/__init__.py b/src/spin_sdk/http/__init__.py
index dd98107..094d94a 100644
--- a/src/spin_sdk/http/__init__.py
+++ b/src/spin_sdk/http/__init__.py
@@ -174,7 +174,14 @@ async def send_async(request: Request) -> Response:
     outgoing_request = OutgoingRequest(Fields.from_list(headers))
     outgoing_request.set_method(method)
     outgoing_request.set_scheme(scheme)
-    outgoing_request.set_authority(url_parsed.netloc)
+    if url_parsed.netloc is None:
+        if scheme == "http":
+            authority = ":80"
+        else:
+            authority = ":443"
+    else:
+        authority = url_parsed.netloc
+    outgoing_request.set_authority(authority)
     path_and_query = url_parsed.path
     if url_parsed.query:
         path_and_query += '?' + url_parsed.query

That did not work. I got the following error:

Authority is still nothing.
On changing it to:
if url_parsed.netloc == '':
        if scheme == "http":
            authority = ":80"
        else:
            authority = ":443"
    else:
        authority = url_parsed.netloc

I get:

The authority is now being set but a HttpProtocolError

Ok, thanks for trying.  I'll start debugging this on my side.

Oh, I wonder if scheme is empty or None also.  I'll check it out.

Oh, I wonder if scheme is empty or None also. I'll check it out.

scheme is empty as well. url_parsed is : ParseResult(scheme='', netloc='', path='/bookings/dwight_schrute', params='', query='', fragment='')

Yeah, so we'll need to force scheme to "http" in that case.

    match url_parsed.scheme:
        case "http":
            scheme: Scheme = Scheme_Http()
        case "https":
            scheme = Scheme_Https()
        case "":
            scheme = Scheme_Http()
        case _:
            scheme = Scheme_Other(url_parsed.scheme)

    if request.headers.get('content-length') is None:
        content_length = len(request.body) if request.body is not None else 0
        request.headers['content-length'] = str(content_length)

    headers = list(map(
        lambda pair: (pair[0], bytes(pair[1], "utf-8")),
        request.headers.items()
    ))

    outgoing_request = OutgoingRequest(Fields.from_list(headers))
    outgoing_request.set_method(method)
    outgoing_request.set_scheme(scheme)
    if url_parsed.netloc == '':
        if scheme == "http":
            authority = ":80"
        else:
            authority = ":443"
    else:
        authority = url_parsed.netloc

    outgoing_request.set_authority(authority)

This works!

I have tried to create a new branch to make a PR but it seems like I do not have permissions to create a new branch. Can I make this contribution? How could I go about doing that?

Sorry, I was in a meeting.  You should be able to fork the repo, push your change to a branch of that fork, and then PR to the main repo from there.  If that's a pain, I can do it it myself.

Will do, thanks!

Raised https://github.com/fermyon/spin-python-sdk/pull/108


fix(legacy): extend path normalisation to legacy CLI integration

Extends https://github.com/microsoft/playwright-vscode/pull/538 to the CLI integration, as per https://github.com/microsoft/playwright-vscode/pull/538#discussion_r1794844011.

seems to be breaking lots of tests. let's keep it as is


"on-the-fly" dependent tiddler creation

Provide a mechanism to create dependent GSD5 tiddlers within the parent tiddler.  An idea is in progress.

Having some issues with implementing the widget.
https://groups.google.com/forum/?utm_medium=email&utm_source=footer#!msg/tiddlywikidev/VS8Xw-8ixrs/usUQjkP2eHAJ


Enable xUnit diagnostic messages

Required to log long-running tests
Will help investigate https://github.com/aspnet/KestrelHttpServer/issues/2503

Verified the new setting is working (this particular test is long-running by design):
[00:04:48]   [xUnit.net 00:01:33.4351782] Sockets.FunctionalTests: [Long Running Test] 'TestKeepAliveTimeout', Elapsed: 00:01:29

CC: @ryanbrandenburg


docs: Passing Stores - edit pass

What is it?

[ ] Feature / enhancement
[ ] Bug
[x] Docs / tests

Description
n/a
Use cases and why
n/a
Checklist:

[x] My code follows the developer guidelines of this project
[x] I have performed a self-review of my own code
[x] I have made corresponding changes to the documentation
[ ] Added new tests to cover the fix / functionality

Holding merge until https://github.com/BuilderIO/qwik/pull/834 is in

Updated in https://github.com/BuilderIO/qwik/pull/890


How to monitor in background mode

Hi
Thanks for your code . I want to monitor the beacons in background mode. if possible scan the beacon in background mode. ? I have searched in Internet come many peoples are saying apple doesn’t allow the app in appastore for background mode app?
Please help me how to scan in background mode

Thanks for jumping in @stephenrob!

Thanks @stephenrob Let me check then update you

@stephenrob i tried to call startMonitoringForRegion in background mode. But it is not wokring can you please advice where it is issue ?


S3 Drivers issue.

## Summary
Uploading a file into S3 . I am getting below error.
ERROR:
**<LibcloudError in <class 'libcloud.storage.drivers.s3.S3StorageDriver'> 'This bucket is located in a different region. Please use the correct driver.'>**
## Detailed Information
Version of libcloud:  2.6.1
Python version: 3.7
code:
`import libcloud
from libcloud.storage.types import Provider
from libcloud.storage.providers import get_driver
FILE_PATH = 'filepath'
cls = get_driver(Provider.S3)
driver = cls('api key','api secret key')
container = driver.get_container(container_name='my-backups-12345')
extra = {'content_type': 'application/octet-stream'}
with open(FILE_PATH, 'rb') as iterator:
                obj = driver.upload_object_via_stream(iterator=iterator,
                                                      container=container,
                                                      object_name='images_backup.tar',
                                                      extra=extra)

In  the above code i mentioned correct driver then also am getting below error.please help me on this issue.Am I missing something?

@570096 I suggest you to install the latest stable version of Libcloud (v2.7.0) and then pass region=<region name> argument to the driver constructor and make sure the region matches the region where the bucket is located.
In v2.7.0, that exception has also been improved so the error now also includes the name of the region where the bucket in question is located.
For example, if your driver is located in the us-west-2 region, you would instantiate a driver like this:
cls = get_driver(Provider.S3)
driver = cls('api key','api secret key', region='us-west-2')

If you are working with buckets in different regions, you need to use multiple driver instances (one per region).


Lifetime-aware Clone

Describe the bug
Current #[derivative(Clone)] does not work on struct with specific lifetime
To Reproduce
#[macro_use]
extern crate derivative;

#[derive(Derivative)]
#[derivative(Clone)]
struct MyStruct<'a> {
    pub borrowed: &'a String,
}

will give:
  --> src/main.rs:45:10
   |
45 | #[derive(Derivative)]
   |          ^^^^^^^^^^ expected `&String`, found struct `String`
   |
   = note: this error originates in the derive macro `Derivative` (in Nightly builds, run with -Z macro-backtrace for more info)

Expected behavior
Here's what current version of macro expands to:
#[allow(unused_qualifications)]
impl<'a> ::core::clone::Clone for MyStruct<'a> {
    fn clone(&self) -> Self {
        match *self {
            MyStruct {
                borrowed: ref __arg_0,
            } => MyStruct {
                borrowed: (*__arg_0).clone(),
            },
        }
    }
}

what we need:
impl<'a> Clone for MyStruct<'a> {
    fn clone(&self) -> Self {
        Self {
            borrowed: &self.borrowed, // instead of the default, which is: `self.borrowed.clone()`
        }
    }
}

Thanks!

Interesting! Something like <#FieldType as Clone>::clone(#field_ref) needs to be produced.


Responsive

Has anyone been successful at implementing responsiveness to the page? Been trying to do so myself but no luck due to lack of CSS knowledge.
Issue is I switch between various window sizes on both 15.6" and 24" monitors I have and with my containers etc, its problematic to see the containers at smaller windows.

Found how:
  .categories {
    display: flex;
    grid-template-columns: 250px 175px;
    justify-content: space-around;
    flex-wrap: wrap;
  }


VM_OPERATION spelling

It is actually PROCESS_VM_OPERATION, without the final "S".

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 9beaec6a-c99a-3de9-f89a-8e8f1995240a
Version Independent ID: 196da704-5288-514b-120a-ae747ae9c4f5
Content: _OB_PRE_CREATE_HANDLE_INFORMATION
Content Source: wdk-ddi-src/content/wdm/ns-wdm-_ob_pre_create_handle_information.md
Service: unspecified
GitHub Login: @windows-driver-content
Microsoft Alias: windowsdriverdev

Hello Marco,
This is now fixed. Thanks for catching that.
PageWriter


Modular snippets

Migrating from Ultisnips, I want to store my snippets separate for each file. How can I load snippets from /lua/snippets/filename.lua instead of the defining all the snippets in a single file? Suppose I  have this directory tree:
lua/
├── core/
│   ├── ...
└── luasnip/
    └── init.lua
    └── snippets/
        ├── c.lua
        ├── css.lua
          ...

I have this function in my luasnip/init.lua
local snippet_table = {}

local snip_dir = "./snippets"

local function get_fname(file)
    return file:match "(.+)%..+$"
end

-- Pseudo code for what I want to achieve:

for file in snip_dir do
    local f_name = get_fname(file)
    local snippets = require(snip_dir .. f_name)
    snippet_table[f_name] = snippets[f_name]
end

luasnip.add_snippets(nil, snippets_table)

Each snippet file is returning a table as such:
return  {
     c = {
           -- snippets for c
    }
}

Oh check DOC.md, there's an extensive section on the lua-loader, it can handle files exactly like you want

Oh check DOC.md, there's an extensive section on the lua-loader, it can handle files exactly like you want

Found exactly what I was looking for. The only downside I found was I had to define those short hands withing every file for the snippets to work properly.

It's possible to define shorthands which will be inserted into the global environment of those files, see snip_env (in the readme though :sweat_smile:, maybe some mentions in the doc too).
You might get warnings from your lsp though (it doesn't know we insert some global variables), but they can be prevented


how to use with visual studio

Hi,
I am new to C/C++ and I am using visual studio. I find your project very cool, but I have no clue of how to include this library into my project. I was wondering if I could have some step by step guidance. Any links to external learning resource would also be appreciated!
Many thanks,
Jason

Hi,
I don't use Visual Studio myself, but I know that people are using this
project in Visual Studio.
Basically you should search on Internet how to use CMake to build a
library from source for Visual Studio.
You will also need to build the dependancies (libzip and expat).
Once you have the library you need to link with it in your own Visual
Studio project.
But you could also just try using the binary files and link with the .a
library files, see this link for more information:
http://stackoverflow.com/questions/2096519/from-mingw-static-library-a-to-visual-studio-static-library-lib
Regards
 Brecht

On 25/07/2016 23:46, Jiasen (Jason) Xu wrote:

Hi,
I am new to C/C++ and I am using visual studio. I find your project
very cool, but I have no clue of how to include this library into my
project. I was wondering if I could have some step by step guidance.
Any links to external learning resource would also be appreciated!
Many thanks,
Jason
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/brechtsanders/xlsxio/issues/8, or mute the thread
https://github.com/notifications/unsubscribe-auth/AQ0-ebzUP_0SMcLdGnWnuoReTi3Dieifks5qZS64gaJpZM4JUlNX.

Thanks, Brecht. It really helps a lot. Very much appreciated.

hi, Jason
have you succeeded in VC? I try to use CMake against Visual C++ and come across the error while configure
Could NOT find ZLIB (missing: ZLIB_LIBRARY ZLIB_INCLUDE_DIR)
CMake Error at C:/Program Files/CMake/share/cmake-3.11/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
Could NOT find Minizip (missing: MINIZIP_LIBRARIES MINIZIP_INCLUDE_DIRS)
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.11/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
CMake/FindMinizip.cmake:18 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
CMakeLists.txt:38 (FIND_PACKAGE)
I have downloaded miniZip and expat-2.2.6 but CMake failed, can you help share your visual c++ project structure?
thanks.

zlib and minizip are not really my projects, so I'm not sure how I can help. Also I'm not a Visual C++ user as I like to stick to open source and cross-platform tools.
But, a simple Google search led me to this: https://github.com/madler/zlib/tree/master/contrib/vstudio
It explains how to build zlib and minizip for VC 9 to 14.

Still getting

Could NOT find ZLIB (missing: ZLIB_LIBRARY) (found version "1.2.11")
CMake Error at C:/Program Files/CMake/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
Could NOT find Minizip (missing: MINIZIP_LIBRARIES MINIZIP_INCLUDE_DIRS)
Call Stack (most recent call first):
C:/Program Files/CMake/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
CMake/FindMinizip.cmake:18 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
CMakeLists.txt:38 (FIND_PACKAGE)

Still getting

Still getting
Could NOT find ZLIB (missing: ZLIB_LIBRARY) (found version "1.2.11") CMake Error at C:/Program Files/CMake/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:137 (message):   Could NOT find Minizip (missing: MINIZIP_LIBRARIES MINIZIP_INCLUDE_DIRS) Call Stack (most recent call first):   C:/Program Files/CMake/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)   CMake/FindMinizip.cmake:18 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)   CMakeLists.txt:38 (FIND_PACKAGE)

Still getting
Could NOT find ZLIB (missing: ZLIB_LIBRARY) (found version "1.2.11")
CMake Error at C:/Program Files/CMake/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:137 (message):
  Could NOT find Minizip (missing: MINIZIP_LIBRARIES MINIZIP_INCLUDE_DIRS)
Call Stack (most recent call first):
  C:/Program Files/CMake/share/cmake-3.15/Modules/FindPackageHandleStandardArgs.cmake:378 (_FPHSA_FAILURE_MESSAGE)
  CMake/FindMinizip.cmake:18 (FIND_PACKAGE_HANDLE_STANDARD_ARGS)
  CMakeLists.txt:38 (FIND_PACKAGE)

After tons of rebuildings of multiple libs i'm stucked on this
Configuring done
WARNING: Target "xlsxio_read_STATIC" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_read_STATIC" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_read_STATIC" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_read_STATIC" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_write_STATIC" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_write_STATIC" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_write_STATIC" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_write_STATIC" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_read_SHARED" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_read_SHARED" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_read_SHARED" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_read_SHARED" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_write_SHARED" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_write_SHARED" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_write_SHARED" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_write_SHARED" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_csv2xlsx" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_csv2xlsx" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_csv2xlsx" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_csv2xlsx" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_xlsx2csv" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_xlsx2csv" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_xlsx2csv" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
WARNING: Target "xlsxio_xlsx2csv" requests linking to directory "C:/Users/kdpc/Desktop/zlib-master/build/minigzip.dir".  Targets may link only to libraries.  CMake is dropping the item.
Generating done

As described in README.md, you do need the prerequisites (zlib and expat) before building.
Those warnings are saying you are linking to a driectory instead of a library file. I have no idea why you are doing that.
Note that the -DLIBZIP_DIR:PATH= and -DMINIZIP_DIR:PATH= cmake parameters expect  to be the folder where subfolders lib and include can be found with the required files.

Fixed that, it now works but generetes no libraries, only VS project files which are not building succesfully

In fact i don't need to build this
The initial problem was 0xc000007b error when launching my application. As far as i know this error means that x64 application trying to use x86 dll but i definely using the correct one

You definitely can't mix bit depths. Are you sure you built the x64 library?
Have you tried using the prebuilt downloads (avoiding the hassle of building all by yourself)?

xlsxio_xlsx2csv.exe reporting the same error either

I'm using prebuild downloads

So you are building x64 with the win64 download?

Note that you still need the dependancy libraries too in the same bit-depth (zlib, expat).
For example if there is a zlib1.dll in your PATH that is 32-bit while building 64-bit, it may cause this error.

Thanks, I'll check that

The error still remains

Is your problem with 64-bit only / did you have success with 32-bit?
Again, I'm not an MSVC expert. Make sure to figure out how to build for win32 and win64 respectively with CMake and MSVC...
Personally I use MinGW-w64 on Windows and have no problems.

Ended up using precompiled 32-bit version, it works well for me
Anyway thank you for support


Fix HeadersAlreadySentException

Since Yii2 version 2.0.14 there is a new exception thrown if headers are already sent:
https://github.com/yiisoft/yii2/issues/15046
Since the outputImage() method in this library sends headers, this causes every request to generate an error. The only thing we risk with this PR is that web/Response events are not being triggered any more.
This will solve #19
If you accept this PR, please bump yii2-glide version.

@trntv I'm sorry but by modifying my PR, you actually do not fix the problem at all. Yii::$app->end(); still calls the error handler and the exception still corrupts our image output. This was the reason that I used exit;.

@ddinchev Yes, In our project, "Yii::$app->end();" may not solve the problem, but "exit;" or "die;" works.


Feature Request: Add Trakt integration.

Would be awesome if we could see our trakt progress list.

Yes please!


Support Bintracker

It's not urgent as the tracker is still under development, but I thought I'll already make you aware of https://bintracker.org

Looks like this tracker is written in Scheme. Hippoplayer mainly uses C/C++ so adding support for this tracker will likely be hard as a new player will have to be written.

Looked closer at the file format of the tracker, it's all scheme based so supporting this would mean re-implementing everything in C/C++ which is out of scope for HippoPlayer. If someone makes a player for the format that isn't in scheme this issue could be re-opened.


File logging reconfiguration issue (Error: write after end)

Please tell us about your environment:

winston version?

[ ] winston@2
[ X] winston@3

_node -v outputs:_v10.15.0
_Operating System?_Windows 10
_Language? JavaScript (pure Node)

What is the problem?
When logger is reconfigured, the open streams are destroyed and winston tries to write to an already destroyed stream.
I created a really simple playground to replicate it (less than 10 lines of actual code): https://github.com/peterbakonyi05/winston-log-rotate-reconfiguration-issue/blob/master/index.js
What do you expect to happen instead?
winston creates a new stream and handles reconfiguration.
Note
Alternatively, instead of reconfiguring winston a new instance can be created, in case someone else has the same issue. Just call .close on the old instance and create a new from scratch.

It seems to be fixed with v 3.2.1

Still happening on 3.2.1

Tried to reproduce with unit test in logger.test.js:
  // https://github.com/winstonjs/winston/issues/1573
  it.only('.configure({ transports }) purity', function (done) {
    var combinedFile = path.join(__dirname, 'fixtures', 'file', 'combined.log');
    function getWinstonConfiguration() {
      return {
          level: 'info',
          format: winston.format.json(),
          defaultMeta: { service: 'user-service' },
          transports: [
              new winston.transports.Console(),
              new winston.transports.File({ filename: combinedFile }),
          ]
      };
    }

    var logger = winston.createLogger(getWinstonConfiguration());
    logger.info('this should make the first log to file');

    setTimeout(() => {
      try {
        logger.configure(getWinstonConfiguration());

        logger.info('this should make the second log to file after reconfiguration');
        assume(true).true();
        done();
      } catch(e) {
        assume(!!e).false()
        done(e);
      }
    }, 200);
  });

but unsuccessful:

am I missing something or this was fixed?

Yes still happening in 3.2.1
~\nodeproject\node_modules\winston\lib\winston\logger.js:307
throw ex;
^
Error: write after end
at writeAfterEnd (~\nodeproject\node_modules\winston\node_modules\readable-stream\lib_stream_writable.js:257:12)
at PassThrough.Writable.write (~\nodeproject\node_modules\winston\node_modules\readable-stream\lib_stream_writable.js:301:21)
at File.log (~\nodeproject\node_modules\winston\lib\winston\transports\file.js:185:34)
at ExceptionStream._write (~\nodeproject\node_modules\winston\lib\winston\exception-stream.js:48:29)
at doWrite (~\nodeproject\node_modules\winston\node_modules\readable-stream\lib_stream_writable.js:405:139)
at writeOrBuffer (~\nodeproject\node_modules\winston\node_modules\readable-stream\lib_stream_writable.js:394:5)
at ExceptionStream.Writable.write (~\nodeproject\node_modules\winston\node_modules\readable-stream\lib_stream_writable.js:303:11)
at DerivedLogger.ondata (~\nodeproject\node_modules\winston\node_modules\readable-stream\lib_stream_readable.js:662:20)
at DerivedLogger.emit (events.js:187:15)
at addChunk (~\nodeproject\node_modules\winston\node_modules\readable-stream\lib_stream_readable.js:297:12)
Since I set the handleExceptions to true, so when this error occur neither winston handle this exception nor process.on("uncaughtException")

tl;dr
Pass by reference in logger.add() function causes the transport object to be altered and thus invalidated when used again in logger.configure()
I think I found the cause of this issue, stemming from the logger.add() function:
add(transport) {

    console.log('In add function\n')
    const target =
      !isStream(transport) || transport.log.length > 2
        ? new LegacyTransportStream({ transport })
        : transport;

    console.log("Original target:", JSON.stringify(target), "\n")
    if (!target._writableState || !target._writableState.objectMode) {
      throw new Error(
        'Transports must WritableStreams in objectMode. Set { objectMode: true }.'
      );
    }

    // Listen for the `error` event and the `warn` event on the new Transport.
    this._onEvent('error', target);
    this._onEvent('warn', target);
    this.pipe(target);

    console.log("Target after pipe:", JSON.stringify(target))

    if (transport.handleExceptions) {
      this.exceptions.handle();
    }

    if (transport.handleRejections) {
      this.rejections.handle();
    }

    return this;
  }

As can be seen in output from the print statements; the target object is edited after it is used for piping. Since target is equivalent to the transport parameter through pass by reference, the change to target also changes the transport object and thus makes it invalid for reuse in logger.configure(). This explains why an entirely new but identical transport would work with configure() but editing the original transport would give the error.
Probable Solution: Make a deep copy of the passed in transport object so that the target object is pass by value
This is my first time commenting on an open issue on GitHub so please let me know if I missed anything that would make this more helpful. I would have tried to create a coded solution myself but since object cloning doesn't seem to be a native tool in JavaScript I figured it would be better for someone with more knowledge of the code base to create an actual solution

I'm also facing the same issue whenever i use firebase commands. please help me fix this

Just deployed to firebase like ten times no problems, several minutes later I try deploying and get this issue on line 307 of logger in Winston. Have no idea what Winston is, but still having this issue in 11/4/20

@justingolden21 Just had the same thing happen to me. Eventually, I re-installed then npm package firebase-tools and it worked

Still happen in 3.3.3

Still happen in 3.3.3

If you are calling logger.configure(options) at some point to change/set i.e. logger level dynamically or some other options, simply add File transport just before the new configuration setter. That helped me.
...
// you may want to check before if file transport is already exist, in my case i havent added before.
options.transports.push(new winston.transports.File({ filename: "./name_of_log_file.log" }))
logger.configure(options);

If you are calling logger.configure(options) at some point to change/set i.e. logger level dynamically or some other options, simply add File transport just before the new configuration setter. That helped me.
...
// you may want to check before if file transport is already exist, in my case i havent added before.
options.transports.push(new winston.transports.File({ filename: "./name_of_log_file.log" }))
logger.configure(options);

Anyone has a quick fix for this ? I'm doing a lot of requests at the same time (each logged in different controllers with different configurations) and this stops the server.
Example for my code :
const config = require('./config/config.js');
const path = require('path')
const {createLogger, format, transports} = require('winston');
const {combine, label, timestamp, splat, colorize, printf} = format;

const getLabel = function (callingModule) {
    var parts = callingModule.filename.split(path.sep);
    return parts[parts.length - 2] + '/' + parts.pop();
};

module.exports = function(callingModule) {
    var logger = createLogger({
        format: combine(
            //label({ label: path.basename(process.mainModule.filename) }),
            label({ label: getLabel(callingModule)}),
            colorize(),
            timestamp({ format: 'YYYY-MM-DD HH:mm:ss' }),
            splat(),
            printf(info => `${info.timestamp} ${info.level} [${info.label}]: ${info.message}`)
        ),
        transports: [
            new transports.Console(),
            new transports.File({filename: config.logDirectory + 'server.log'}),
        ],
        level: config.logLevel,
        exceptionHandlers: [
            new transports.File({filename: config.logDirectory + 'exception.log'}),
            new transports.Console(),
        ],
        exitOnError: false,
    });
    logger.info('Logs set up done, captured 2 ways- console & file');
    return logger;
}

Still happen in winston 3.4.0   winston-daily-rotate-file 4.5.5

Still happen in winston 3.4.0 winston-daily-rotate-file 4.5.5

https://github.com/winstonjs/winston/blob/master/UPGRADE-3.0.md#winstonlogger

Still happen in winston 3.4.0 winston-daily-rotate-file 4.5.5
the problem is exceptionHandlers with transports.File，After the program exits abnormally, the write closure of this Exception is not synchronized.

PRs are welcomed to fix this issue.  It sounds like a fix may have been suggested earlier in the thread.  Winston relies on the community for help with fixing features.  Maintainers will try to help shepherd and review PRs.

I also facing the same issue<EMAIL_ADDRESS>

Yeah, I also facing too in<EMAIL_ADDRESS>

3.8.2 also

Hello everyone @xxAROX , @Zarinia , @finallyRaunak, @tatujan could you please specify some details about your particular usecase and code. Because the code presented in the first comment seems to be working fine and shows no error. That will be really helpful.
Thanks :)

could you please specify some details about your particular usecase and code.

Don't have the code anymore sorry :G

still facing problem in 3.11.0 version available on NPM, any idea about how to solve it?

+1 Still occurs on 3.14.2

Please see comment above
https://github.com/winstonjs/winston/issues/1573#issuecomment-1020766640
I don’t think anyone has volunteered a PR to fix this issue, but it would certainly be welcome, and I would be more than happy to review if one is opened

Its been five years since I originally suggested a solution to this issue and I can now say I feel confident enough to introduce a PR for this issue. I am, however, unable to reproduce this issue anymore. @iradofurioso @chpeagle7 @SuppliedOrange would either of you be able to provide the code that is still seeing this bug? I would be happy to make a PR for it if I can replicate the issue.


marker rotates full circle

when angle is set from 5 to 355 , marker moves clockwise so it performs a full circle instead it should have turned anticlockwise so that it can make small turn. how i can do this?

Hi!
This is not really a part of the plugin, as it doesn't come with any animation, but I guess you added some transition property to the marker style.
The direction of the rotation depends only on the start and end angle values. Rotation is clockwise if end > start, and counter-clockwise if start > end. Fortunately, all different values of an angleare supported, not only [0, 360[, but also negatives and all values modulo 360.
That means 355 deg <=> -5 deg, so if you use -5 in your example, the animation will happen counter-clockwise. To generalize it, you need to compute:

for clockwise, the minimum value of the end angle greater than the start angle
for counter-clockwise, the maximum value of the end angle lower than the start angle

Would love to be able to set the direction of the rotation

Hi @diklankolsin. As I explained in the above reply, rotation animation is not part of this plug-in, but I proposed a way to control it through angle values. I don't want to give the plug-in responsibility for animation, because more than direction it would open the door to other things that are better left to CSS (rotation speed and easing, for example).


One radio button selection missing from PIM task

Module: 01
Lab/Demo: 05
Task: 03
Step: 07
By default, Assignment type is eligible. --> Review the Assignment type and select Active as an assignment type and click Assign.
Add also a justification for an active assignment.

Or do you mean to give a permanten eligible role in this step?

Hi Markus,
the latter. Pls refer to Exercise 2 task 2:
On the My roles | Azure AD roles blade, locate the Security Administrator role, and click Activate.
Click the warning Additional verification required. Click to continue.
Follow the instructions to verify your identity.
Note: You only have to authenticate once per session.
Once you are back in the Azure Portal interface, on the Activate - Security Administrator blade, in the Reason text box, type a text providing justification for the activation, and then click Activate.
Note: The auto approval process should complete.
Back on the My roles | Azure AD roles blade, click the Active assignments tab and notice that the listing of active assignments includes Security Administrator but not the Global Reader role.
rgds
Marcin


GraphEngineService Stateful Service does not register ServiceEventSource

In the previous build of Service Fabric, this was not a problem but now with the latest updates, it is. Our current implementation of the GraphEngineService does not make this call: "ServiceEventSource.Current.ServiceTypeRegistered(Process.GetCurrentProcess().Id, typeof(GraphEngineService).Name);". So now when you a debugging in VS and you view Diagnostic Events it does not connect and show the active log; the facility now requires an "Event Source Name" or a Guid. I'll submit a PR to resolve.

Okay - so after digging around and tracing through the GE/SF implementation the EventSource is registered vai the GraphEngineStatefulServiceEventSource class; however, when debugging Service Fabric in VS 2019 the Diagnostics View does not automatically connect and show the contents of the "Microsoft-ServiceFabric.Trinity.StatefulService" event source. I had to manual paste the name in the Viewer to see the log contents.


SIP voicemail

demo for SIP voicemail. Will still need to wrap up README and parent folder index README

Still need to

[ ] debug transcribe callback
[ ] add descriptions in Voice parent README


Stylizing 'search' box

The search box position is currently on the top left and it looks plain.
The position is to be fixed in a good spot on the page and stylized to make it look better.

@osBins assign me

Great! Assigning this issue to you @vedantiitkgp.

Can I work on this issue?

Hey @Bibhavshah, this issue has already been resolved via #105. Feel free to go through the list of issues and work on one not assigned to anyone, or you could create an issue to work on for yourself too!


Can ClusterClient point to a single node in the cluster?

In the example for the ClusterClient, it shows multiple redis hosts. Would the ClusterClient work if just one host was given? If so, does it matter if the host is a master or slave?
For example, I have 6 redis nodes running (3 master, with 1 slave each). I have a DNS server which round-robins between any of them. Meaning, if you connect to "redis.myserver.com" you'll get to any one of the 6 nodes.

AFAIK it is safe to connect to only one random node in the cluster (master or slave). So you should be fine.


Replace scheduling integration tests with feature tests

Trello: https://trello.com/c/rBYaERp4/708-handle-scheduled-publishing-errors
This acts as something of a proof of concept that the scheduling feature can be testing by feature tests.
The tests end up rather long so I've tried to start them at a reasonable point so they're still understandable.
There is a lot of duplication between spec/features/scheduling/scheduled_publishing_spec.rb and spec/features/scheduling/scheduled_publishing_without_review_spec.rb - however attempts to have them as two scenarios of the same test ended up with some really grimly verbose step names so I decided to have them as separate.
Anyway feedback welcome, particularly on how they fit into the wider consistency of our feature tests.

@benthorner all comments addressed

@kevindew thanks - feel free to merge. This feels almost like I'm approving something 🤔


Fix link in CONTRIBUTING.rst

Thanks! 👍

Coverage increased (+0.6%) to 89.431% when pulling 54dc1b49c38917abbfaecd44bbdc85fd80c759cb on timgraham:contributing-link2 into 65ed1c7801925b1a5a8458aff02200d730d957a1 on divio:release/3.3.x.


Update codeowner

Description
Add myself to some of the backend modules

code owner feature only works for people with write access.


Can't launch programs through mirror

If I try to launch programs through the mirror, I either end up with <program>.exe is not a valid Win32 application or it manages to start and instantly crashes.
I've tried launching several different programs this way (also with the C mirror), but none of them have launched properly.
Haven't noticed anything suspicious in the debug output either.
I'm mirroring the whole C:\ drive, so it shouldn't matter if the programs use absolute or relative paths to locate their stuff, as it should map to the same place anyway.

Hi @MythicManiac ,
With the C Mirror it should work (we had issue before but they have been fixed).
DId you try to start the mirror with admin rights ?

Tried again, this time running it as an administrator, still facing the same issue.
Notepad++ seems to be able to launch, but that's the only one that I have found working so far.
It should be mentioned that I'm using the pre-release version.

Some of the error messages I'm getting from the applications:

I ran mirror.exe /r C:\ /l L /t 5 /d /C from an administrator privileged command prompt.

Notepad++ seems to have roughly a 50% success in launching, but the other 50% of the time it fails like the rest:

@MythicManiac @Liryna this was fixed on current 1.0.0 coming release, latest stable release 0.8.0 doesn't have this fix. I believe you're using this one right?

https://github.com/dokan-dev/dokany/releases/tag/v1.0.0-RC2 This is the release I'm using of Dokany, and the DotNet wrapper I have was installed with Install-Package DokanNet -Pre on the package manager console.

I had no time to test with the RC2 for now but I made a test with the last dokan commit that I have build and installed

I face no issue by running notepad++, NSIS and even iexplorer.exe
It is possible that since RC2 there is some changes that fixed what you face but I still doubt about it :(
I have never had the behaviour you describe.

@Liryna could you try launching some application that heavily relies on DirectX / OpenGL through it?
I could try if downgrading would fix my problem, but I doubt it.

I don't have games installed on my system sorry :'(
But I started Visual Studio directly and it worked.
L:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\devenv.exe

I tested with my VS2015 as well, sometimes it launched properly, sometimes it hanged, and sometimees it got pretty much the same errors as the ones I posted earlier.
Is there a way to have the mirror output log to a file directly? Window's cmd printing is really slow with large amounts of data

You can try with mirror.exe > a.txt 2>&1

Heres a log.txt where I failed to start League of Legends a few times (Also Windows crashed after unmounting while I still had a process left hanging through the mirror :+1:)
What do you mean with a simple hello world?

Build and run something like:
/* Hello World program */

#include<stdio.h>

main()
{
    printf("Hello World");

}

Crashed after unmounting ? thats interesting!
Could you give the report analyse of the memory dump ?
https://github.com/dokan-dev/dokany/wiki/How-to-Debug-Dokan#crash-report-bsod

Just to confirm: did you mean I should run a basic hello world through the mirror until I get an error?
As for the crash, I'm pretty sure it's supposed to happen and not a bug, because Windows was running a program through the mirror when I killed the mirror. Here's the dump.txt anyway in case it helps you in any way.

I'm not sure you're both talking about the same mirror. C mirror should be fine to run exe file, but not current C# mirror. https://github.com/dokan-dev/dokan-dotnet/blob/master/sample/DokanNetMirror/Mirror.cs#L520 should be changed according to C mirror, eg. NTFS.
@MythicManiac could you give a try with latest 1.0.0-RC3 pre-release and C mirror (not C# for the sake of testing ; also please don't use /n for now). Thanks.

Change has been made https://github.com/dokan-dev/dokan-dotnet/commit/ed41f46e49bf46b022df29199de16d00d7bd5de4

@Maxhy I tested with the C and C# mirrors with several different setups, neither seemed to be working. I'll test with the latest version when I have time and get back to you.

Just FYI, this is still on my to-do list, although I'm not sure if I'll get back to trying again anytime soon, so closing is probably a smart idea. Will open another issue if this still persists.

@MythicManiac Ah! no problem ! I tought you moved to something else 😄


Is entity order guaranteed?

Hi, I use entities to carry networking messages and have a deferred system to send them. I'm wondering if their order inside Collector/Group is ordered by their create time?

I might be wrong but i think they use HashSets which do not preserver order, so you would need to manually sort them if order was important to you.

Thank you @FNGgames 😄
I guess sorting entities by an incrementing id manually would be an easy yet concrete solution

Or creation time perhaps?

Order is not preserved. You have to save data for ordering yourself. Internal all entities are saved in a HashSet.

Yep. You did. I just wanted to confirm it because you put "I might be wrong but I think" in front of your sentence :smile:

Or creation time perhaps?

Good idea! Creation time should be good enough for most cases. In my case, multiple reliable network message(entity) might be created at the same frame and I still want their order to be guaranteed 😄


RuntimeError: Expected fft_size >= 16 && fft_size <= 16384

Hello, thanks for the interesting research and open source repo!
I'm trying to integrate the HyenaOperator (with default settings) in a sequence modeling task and am running into the error in the title when using the fftconv extension.
My sequence (u in the trace below) has the shape (batch=10, channels=32, seq_len=8760) which apparently leads to an fft_size of 32768.
  File ".../hyena.py", line 31, in fftconv_fused
    return fftconv_func(u, k, D, gelu=False, force_fp16_output=torch.is_autocast_enabled())
  File ".../extensions/fftconv/fftconv.py", line 175, in fftconv_func
    return FFTConvFunc.apply(
  File ".../extensions/fftconv/fftconv.py", line 98, in forward
    out = fftconv_fwd(
RuntimeError: Expected fft_size >= 16 && fft_size <= 16384 && (fft_size == 1 << int(log2(float(fft_size)))) to be true, but got false.  (Could this error message be improved?  If so, please report an enhancement request to PyTorch.)

Is the maximum supported sequence length 8192? Is this a theoretical / hardware limitation? Or just of the current implementation? Would it be possible to support longer sequences?
Thanks!

Yes, this code path does not support sequence lengths longer than 8192 yet

will update this issue when the code is updated. For now, the slow
version of fftconv (without extension) should support longer sequences up
to GPU memory limits.

On Tue, Mar 14, 2023 at 7:07 AM Hans Brouwer @.***>
wrote:

Hello, thanks for the interesting research and open source repo!
I'm trying to integrate the HyenaOperator (with default settings) in a
sequence modeling task and am running into the error in the title when
using the fftconv extension.
My sequence (u in the trace below) has the shape (batch=10, channels=32,
seq_len=8760) which apparently leads to an fft_size of 32768.
File ".../hyena.py", line 31, in fftconv_fused
return fftconv_func(u, k, D, gelu=False, force_fp16_output=torch.is_autocast_enabled())
File ".../extensions/fftconv/fftconv.py", line 175, in fftconv_func
return FFTConvFunc.apply(
File ".../extensions/fftconv/fftconv.py", line 98, in forward
out = fftconv_fwd(
RuntimeError: Expected fft_size >= 16 && fft_size <= 16384 && (fft_size == 1 << int(log2(float(fft_size)))) to be true, but got false.  (Could this error message be improved?  If so, please report an enhancement request to PyTorch.)
Is the maximum supported sequence length 8192? Is this a theoretical /
hardware limitation? Or just of the current implementation? Would it be
possible to support longer sequences?
Thanks!
—
Reply to this email directly, view it on GitHub
https://github.com/HazyResearch/safari/issues/6, or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABDDIIUSTVVRRO33V473B53W4BGQXANCNFSM6AAAAAAV2JGJDA
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>

@JCBrouwer Is fftconv working well for you? I can execute fftconv_func but it take very long time to launch the kernel making it almost unusable.

@DanFu09 I also noticed that the fftconv extension here doesn't seem to reach the speed gains as claimed in the paper (it does give memory savings though!)

Can you give more details on the workload you’re using to measure the speedup?

@DanFu09 It's a regular Transformer with self-attention layers replaced with Hyena, with FFTConv. The overall training time per step doesn't seem to decrease when switching between the cuFFT Pytorch implementation and this extension. It might be dominated by other layers. Sequence length ~1K.
Let me know if there are any specific details you're looking for.


Good stuff

https://github.com/rancher/types/pull/312

https://github.com/rancher/rancher/issues/12113


 (Which I guess is expected). But warpd works, I can use any mode if that exit(-1) is commented out of inputs.c but then it will fail to ungrab. That is on 65e8cd6e7d91e45547bc9d6838d4794753e59ba3.
I also tried 0dff1f0736c5b7c202ef977fc72ed3a290b777d8, which was working before and now I get on it:
$ warpd -f
rescan_devices: detected keyboard: Power Button (6)
rescan_devices: detected keyboard: Video Bus (7)
rescan_devices: detected keyboard: Video Bus (8)
rescan_devices: detected keyboard: Power Button (9)
rescan_devices: detected keyboard: Sleep Button (10)
rescan_devices: detected keyboard: USB OPTICAL MOUSE  Keyboard (13)
rescan_devices: detected keyboard: BY Tech Usb Gaming Keyboard (15)
rescan_devices: detected keyboard: BY Tech Usb Gaming Keyboard System Control (16)
rescan_devices: detected keyboard: BY Tech Usb Gaming Keyboard (18)
rescan_devices: detected keyboard: Integrated Webcam: Integrated W (20)
rescan_devices: detected keyboard: Intel HID events (23)
rescan_devices: detected keyboard: Intel HID 5 button array (24)
rescan_devices: detected keyboard: Dell WMI hotkeys (25)
rescan_devices: detected keyboard: USB OPTICAL MOUSE  Consumer Control (27)
rescan_devices: detected keyboard: BY Tech Usb Gaming Keyboard Consumer Control (28)
rescan_devices: detected keyboard: Corsair Raptor HS40 (11)
rescan_devices: detected keyboard: AT Translated Set 2 keyboard (26)
main: Built from commit: 0dff1f0736c5b7c202ef977fc72ed3a290b777d8

main: Waiting for activation key
X Error of failed request:  BadAccess (attempt to access private resource denied)
  Major opcode of failed request:  33 (X_GrabKey)
  Serial number of failed request:  514
  Current serial number in output stream:  519

And that also happens on 08ed81af04c7b63b185e66385602d5795489a2c1... So something surelly changed on my system but I am not sure what....

Can you run the latest commit and post the output?
 (Which
I guess is expected). But warpd works, I can use any mode if that exit(-1)
is commented out of inputs.c but then it will fail to ungrab. That is on
65e8cd6
https://github.com/rvaiya/warpd/commit/65e8cd6e7d91e45547bc9d6838d4794753e59ba3
.
I also tried 0dff1f0
https://github.com/rvaiya/warpd/commit/0dff1f0736c5b7c202ef977fc72ed3a290b777d8,
which was working before and now I get on it:
$ warpd -f
rescan_devices: detected keyboard: Power Button (6)
rescan_devices: detected keyboard: Video Bus (7)
rescan_devices: detected keyboard: Video Bus (8)
rescan_devices: detected keyboard: Power Button (9)
rescan_devices: detected keyboard: Sleep Button (10)
rescan_devices: detected keyboard: USB OPTICAL MOUSE  Keyboard (13)
rescan_devices: detected keyboard: BY Tech Usb Gaming Keyboard (15)
rescan_devices: detected keyboard: BY Tech Usb Gaming Keyboard System Control (16)
rescan_devices: detected keyboard: BY Tech Usb Gaming Keyboard (18)
rescan_devices: detected keyboard: Integrated Webcam: Integrated W (20)
rescan_devices: detected keyboard: Intel HID events (23)
rescan_devices: detected keyboard: Intel HID 5 button array (24)
rescan_devices: detected keyboard: Dell WMI hotkeys (25)
rescan_devices: detected keyboard: USB OPTICAL MOUSE  Consumer Control (27)
rescan_devices: detected keyboard: BY Tech Usb Gaming Keyboard Consumer Control (28)
rescan_devices: detected keyboard: Corsair Raptor HS40 (11)
rescan_devices: detected keyboard: AT Translated Set 2 keyboard (26)
main: Built from commit: 0dff1f0736c5b7c202ef977fc72ed3a290b777d8
main: Waiting for activation key
X Error of failed request:  BadAccess (attempt to access private resource denied)
Major opcode of failed request:  33 (X_GrabKey)
Serial number of failed request:  514
Current serial number in output stream:  519
And that also happens on 08ed81a
https://github.com/rvaiya/warpd/commit/08ed81af04c7b63b185e66385602d5795489a2c1...
So something surelly changed on my system but I am not sure what....
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/rvaiya/warpd/issues/26, or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAOP7GMPFW3U65DLSWREGA3SKPOBTANCNFSM4SOCLF4Q
.

I found the cause. I used to use xmodmap to remap my keys but recently found that KDE had a built in way to do those remappings which surely affects the way warp crashes:

I am not sure of what kde is using to do remap the keyboard.  Unfortunately
there is nothing that can be done about this since warpd is predicated on
the assumption that most software will use standard X grabs. If turning off
KDE remappings solves the problem then it is likely KDE, although simple
mappings can be done using setxbmap without the need for Xinput so I would
be surprised if this was the case.
On Tue, Oct 13, 2020 at 2:56 PM Matheus Fillipe<EMAIL_ADDRESS>wrote:

I found the cause. I used to use xmodmap to remap my keys but recently
found that KDE had a built in way to do those remappings which surely
affects the way warp crashes:
[image: image]
https://user-images.githubusercontent.com/24435787/95902919-db7d0f00-0d6b-11eb-8f24-5f3aae837b2a.png
I am not sure of what kde is using to do remap the keyboard.
Reply to this email directly, view it on GitHub
https://github.com/rvaiya/warpd/issues/26#issuecomment-707943019, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/AAOP7GJ3LX2KOCCCCGCWIS3SKSPELANCNFSM4SOCLF4Q
.

I rebooted now and I have warpd on my kde's startup script. It works fine until I restart warpd, then I start having FATAL: Failed to grab keyboard AT Translated Set 2 keyboard: 1.

My guess would be that putting it in your start up script gives it a change
to grab the input devices before kde. Try disabling all input handling in
KDE. Do you have this problem with other desktop environments? It is likely
that KDEs input layer in mangling the xinput logic.
On Tue, Oct 13, 2020 at 11:11 PM Matheus Fillipe<EMAIL_ADDRESS>wrote:

I rebooted now and I have warpd on my kde's startup script. It works fine
until I restart warpd, then I start having FATAL: Failed to grab keyboard
AT Translated Set 2 keyboard: 1.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/rvaiya/warpd/issues/26#issuecomment-708128219, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/AAOP7GOJCAMKOG7DYAA2XADSKUJGNANCNFSM4SOCLF4Q
.

The problem is that after exiting warpd and ungrabing the DE's mouse cursor doesn't appear again.  Is like if warpd is failing to ungrab? I believe I only have this problem in kde. I didn't have this problem on i3.   I added some code to show the cursor if you kill warp while
it is active in the latest commit (although you probably shouldn't be doing
this). See if that solves your problem.
On Wed, Oct 14, 2020 at 4:34 PM Matheus Fillipe<EMAIL_ADDRESS>wrote:

The problem is that after exiting warpd and ungrabing the DE's mouse
cursor doesn't appear again.  Is like if warpd is failing to ungrab? I believe
I only have this problem in kde. I didn't have this problem on i3.
Reply to this email directly, view it on GitHub
https://github.com/rvaiya/warpd/issues/26#issuecomment-708645009, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/AAOP7GPTYBY6DTGUBAQXM33SKYDMZANCNFSM4SOCLF4Q
.

That last log was produced by launching warpd, pressing the hints mode keybind, then pressing Esc and then I don't have my "normal" cursor back.
 I did something like this on input.c to ignore the error:
void input_grab_keyboard(int wait_for_keyboard)
{
	size_t i, not_grabbed_count=0;
	XIEventMask mask;

	dbg("Grabbing keyboard");

	mask.deviceid = XIAllDevices;
	mask.mask_len = XIMaskLen(XI_LASTEVENT);
	mask.mask = calloc(mask.mask_len, sizeof(char));
	XISetMask(mask.mask, XI_KeyPress);
	XISetMask(mask.mask, XI_KeyRelease);

	for (i = 0; i < nkbds; i++) {
		int rc;
		if((rc = XIGrabDevice(dpy, kbds[i],
				      DefaultRootWindow(dpy),
				      CurrentTime,
				      None,
				      GrabModeAsync,
				      GrabModeAsync,
				      False, &mask))) {
			int n;
      not_grabbed_count++;
			XIDeviceInfo *info = XIQueryDevice(dpy, kbds[i], &n);
			fprintf(stderr, "FATAL: Failed to grab keyboard %s: %d\n", info->name, rc);
		}
	}
  if (not_grabbed_count==nkbds)
			exit(-1);

	XSync(dpy, False);
	clear_keys();
	grabbed = 1;
	dbg("Done");
}

Which I have no idea if would be right but at least it warpd shows and work then, but when exiting I still don't get my mouse cursor back unless if I kill it manually. Maybe is just something it is just being held? I have to kill warpd with sigkill after I hit esc like that though.

I'm not sure what branch you made those change to. You should see your
mouse cursor after closing warp however given the fact that you can't even
start it there is a high probability that KDE is interfering with the input
logic. Have you tried disabling all remapping in KDE? Your changes should
break the input logic, the issue doesn't have anything to do with the
specific input device grabbed.
On Wed, Oct 14, 2020 at 9:26 PM Matheus Fillipe<EMAIL_ADDRESS>wrote:

That last log was produced by launching warpd, pressing the hints mode
keybind, then pressing Esc and then I don't have my "normal" cursor back.
 I did something like this on
input.c to ignore the error:
void input_grab_keyboard(int wait_for_keyboard)
{
size_t i, not_grabbed_count=0;
XIEventMask mask;
dbg("Grabbing keyboard");
mask.deviceid = XIAllDevices;
mask.mask_len = XIMaskLen(XI_LASTEVENT);
mask.mask = calloc(mask.mask_len, sizeof(char));
XISetMask(mask.mask, XI_KeyPress);
XISetMask(mask.mask, XI_KeyRelease);
for (i = 0; i < nkbds; i++) {
int rc;
if((rc = XIGrabDevice(dpy, kbds[i],
DefaultRootWindow(dpy),
CurrentTime,
None,
GrabModeAsync,
GrabModeAsync,
False, &mask))) {
int n;
not_grabbed_count++;
XIDeviceInfo *info = XIQueryDevice(dpy, kbds[i], &n);
fprintf(stderr, "FATAL: Failed to grab keyboard %s: %d\n", info->name, rc);
}
}
if (not_grabbed_count==nkbds)
exit(-1);
XSync(dpy, False);
clear_keys();
grabbed = 1;
dbg("Done");
}
Which I have no idea if would be right but at least it warpd shows and
work then, but when exiting I still don't get my mouse cursor back unless
if I kill it manually. Maybe is just something it is just being held? I
have to kill warpd with sigkill after I hit esc like that though.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/rvaiya/warpd/issues/26#issuecomment-708837070, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/AAOP7GMFZ57VGGUQPIVX5V3SKZFUNANCNFSM4SOCLF4Q
.

I was able to fix it here and made a pull request to you can understand what solved it and see if that's possible and correct it. I don't know much C :P. Here: #27
I restarted warp many times and seems like that solved. I hope that's fine and won't create a regression to the Xorg crashing problem. If a device fails to be grabbed then we skip it and skip attempting to ungrab it too.  It fixed for me, been testing since a while and restarted warpd without problems with the KDE remap also on.

Silently failing is the wrong solution. Please confirm whether or not the problem disappears when you disable all input mapping in KDE. I have asked several times but it is still unclear whether or not turning that feature off causes the problem to disappear.

Sorry. Doesn't seem to be related to the KDE's input remaping. I rebooted and was able to run def543553d53528609dff7171c1ce88b6c11f2eb just fine now... Another thing I am running is imwheel. Do you think it could be related?
By the way weirdly now I am able to restart warpd and use (def543553d53528609dff7171c1ce88b6c11f2eb) just fine...With all my input mess running (synergy+imwheel+kde remapping). I just tested having only one of them separately and turns out none are a problem now :P
I'll report if this happens again and close if not, maybe was your last commit.

The last two commits (def5435 and ae82680) made superficial changes which should not have changed anything. 65e8cd6 did indeeed introduce some stability related change to the input system but I'm assuming you were running from the tip of master when you posted your logs. I am not familiar with imwheel but a cursory grep through the source suggests it doesn't use xinput and should not be a problem. As discussed in #17 synergy does use xinput and should be considered mutually incompatible with warpd. In this partuclar instance it might be synergy, KDE or a combination of the two. Given that the problem spontaneously disappeared you may also have been running on an older commit. Without being able to consistently reproduce the issue it is difficult to isolate. The next time you have issues try disabling synergy. If it doesn't fix the problem then it is probably caused by the KDE input layer. I would recommend using setxkpmap to do remapping in your startup scripts anyway unless you need some feature only provided by KDE.

I was going to post the problem happened again but finally figured out what is causing this problem!!
 I think warpd can work just fine with synergy (on the host machine) and KDE remapping. The problem is that it should detect disabled devices I believe? Maybe kinda like what my pull request does but instead of ignoring the error, skipping disable devices.

You seem to do a lot of weird things with your input devices :P. I can't reproduce this, the rescan logic seems to be working fine. It is possible (likely) that synergy is interfering. Can you disable it an see if you can reproduce the problem? Also, please always include the full log output. If it is too large to fit in put commit include it as an attachment.
Thanks

Yeah. I disabled synergy. Look, if you might only be able to reproduce this if you have a laptop or two attached keyboards I guess. Run xinput disable $device_id. You can see the device_id with xinput list. Then run warpd or with it already running you will get an infinite loop when trying to ungrab and the normal cursor won't show up again.
I did this test with synergy killed, is not it's fault, is because it is trying to grab a manually disabled device (and trying to ungrab it).

I've already done exactly that without issue. warpd should not be trying to ungrab anything if you able to run xinput disable id. It only grabs the keyboard when it is active. I'm not sure what you are doing. It shouldn't even be possible to type the command if warp is active, I can only assume you are calling it from a script which is getting triggered while warp is active. To properly isolate the problem please start with a fresh X session with no other programs running (ideally running a simple window manager like fluxbox) and list the steps you are performing in order to reproduce the issue. Also please include the full output.

I was finally able to reproduce it by scripting the xinput command. This was not clear in your original post. Please always include a list of steps to reproduce the issue. Sometimes minor details which may seem insignificant are key to reproduction, and it also helps you isolate the problem on your own system. I will look into this and release a patch soon.

I believe this should be fixed in the latest commit.  In general there are no guarantees of compatibility with programs that use xinput, so things like this are not officially supported. Synergy might work under certain conditions but it is entirely possible for either of the programs to introduce a breaking change at any point so please be aware of this moving forward. While It was possible to address this particular issue but there are certain things that will inevitably break. This is just a limitation of the X input system.
other attempts at a keyboard driven mouse program appear to have run into some of the same problems I ran into while designing warp though warp is the only program I am aware of that circumvents them by abusing xinput (which is an ugly kludge). A byproduct of this approach is that while certain normally impossible things are made possible, other things will break. Really you should be glad warpd works at all :P.

Fixed! Sorry for not making clear I was disabling a device after warpd was launched :P.


Slightly goofy globbing

There is something a little goofy about our globbing when we do SuiteLoader::getTests($path).
Sometimes there is an extra directory separator in one of the paths:
specs/Foo/Api/Route/Middleware//register-application-middleware.spec.php

I think that is a perfectly valid path still, just not as pretty to look at

in the concurrency plugin i look for it to strip it

But.... most likely this line:
https://github.com/peridot-php/peridot/blob/master/src/Runner/SuiteLoader.php#L78


Update dependencies

Landed in https://github.com/metarhia/metavm/commit/6b32a1411fb706c2bc5d603f570fc4223a53507e and https://github.com/metarhia/metavm/commit/0fabb5c790594deee5409d12193256c227e78a1a


Code Coverage published to codecov.io

TL;DR
The PR publishes test coverage report to codecov.io. This allows tracking every checkin and the code coverage over time
Type

[ ] Bug Fix
[x] Feature
[ ] Plugin

Are all requirements met?

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

Complete description
Same as TL;DR
Tracking Issue
https://github.com/lyft/flyte/issues/260
Follow-up issue
NA

Codecov Report

:exclamation: No coverage uploaded for pull request base (master@6844b7a). Click here to learn what that means.
The diff coverage is n/a.

@@            Coverage Diff            @@
##             master      #61   +/-   ##
=========================================
  Coverage          ?   57.23%
=========================================
  Files             ?      362
  Lines             ?     5745
  Branches          ?      789
=========================================
  Hits              ?     3288
  Misses            ?     2457
  Partials          ?        0

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 6844b7a...7a19b7e. Read the comment docs.


refactoring

Coverage remained the same at 100.0% when pulling 859e55f58db3bf0b3b3eb11d14b8b6f503ac21b0 on 3.0 into 6cb4a8030b01e59847cdb6ac01a8680d1bf57eae on master.


v0.3.3 is broken: Layers for new releases are not published (403: Forbidden / AccessDeniedException)

When using the latest version of the template (https://aws-managed-cost-intelligence-dashboards.s3.amazonaws.com/cfn/cid-cfn.yml), the stack fails to deploy with an Error on CidResourceLambdaLayer:

Resource handler returned message: "Your access has been denied by S3, please make sure your request credentials have permission to GetObject for aws-managed-cost-intelligence-dashboards-eu-west-1/cid-resource-lambda-layer/cid-0.3.3.zip. S3 Error Code: AccessDenied. S3 Error Message: Access Denied (Service: AWSLambdaInternal; Status Code: 403; Error Code: AccessDeniedException; Request ID: afd6441e-ec28-4e5f-ae5e-9b07dd142eca; Proxy: null)" (RequestToken: 6518417a-61ff-c0dc-4c4a-e2b457a7ce7f, HandlerErrorCode: GeneralServiceException)

When I try to download the S3 file I do indeed get an access denied:
~$ aws s3 cp s3://aws-managed-cost-intelligence-dashboards-eu-west-1/cid-resource-lambda-layer/cid-0.3.2.zip . --no-sign-request
download: s3://aws-managed-cost-intelligence-dashboards-eu-west-1/cid-resource-lambda-layer/cid-0.3.2.zip to ./cid-0.3.2.zip

~$ aws s3 cp s3://aws-managed-cost-intelligence-dashboards-eu-west-1/cid-resource-lambda-layer/cid-0.3.3.zip . --no-sign-request
fatal error: An error occurred (403) when calling the HeadObject operation: Forbidden

This seems to be because the upload script fails, without failing the action:
see https://github.com/aws-samples/aws-cudos-framework-deployment/actions/runs/8829933297/job/24242012051
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/home/runner/work/aws-cudos-framework-deployment/aws-cudos-framework-deployment/cid/__init__.py", line 3, in <module>
    __import__('pkg_resources').declare_namespace(__name__)
    ^^^^^^^^^^^^^^^^^^^^^^^^^^^
ModuleNotFoundError: No module named 'pkg_resources'
cat: cid-.hash: No such file or directory

The actuall failure is probably here: https://github.com/aws-samples/aws-cudos-framework-deployment/blob/main/assets/build_lambda_layer.sh#L3
Adding this to the top of all .sh files will at least surface this error in the github actions (see https://sipb.mit.edu/doc/safe-shell/):
set -euf -o pipefail

please can you retry? There was a release pipeline in progress

this works now from any acc.
aws s3 cp s3://aws-managed-cost-intelligence-dashboards-eu-west-1/cid-resource-lambda-layer/cid-0.3.3.zip .
Will close the issue. Thanks for suggestions on pipeline

Works for me too, thanks!


refactor: Common static analysis issues

Use this link to re-run the recipe: https://app.moderne.io/recipes/org.openrewrite.staticanalysis.CommonStaticAnalysis?organizationId=RGVmYXVsdA%3D%3D

@zieka Please sign the Contributor License Agreement!
Click here to manually synchronize the status of this Pull Request.
See the FAQ for frequently asked questions.

Thanks but we don't accept cosmetic changes and we would rather automate such checks with our own build.


[graphiql] Display more types in <SchemaDocumentation />

Hello 👋
Currently, SchemaDocumentation shows only the root types in the initial screen, and has a lot of screen real estate that could be used to show more types. That would bring the UI closer to the results of { __schema { types { name } } } query, so it's IMHO both a nice use of the empty space an pretty consistent.
I'm up for sending a PR if you feel it would be a worthwhile contribution. With TypeLink and schema.getTypeMap() the implementation seems be pretty straightforward.

Got a hacky implementation working with `pnpm patch`.
@@ -19643,6 +19634,9 @@ function SchemaDocumentation(props2) {
   const queryType = props2.schema.getQueryType();
   const mutationType = (_b = (_a = props2.schema).getMutationType) == null ? void 0 : _b.call(_a);
   const subscriptionType = (_d = (_c = props2.schema).getSubscriptionType) == null ? void 0 : _d.call(_c);
+
+  const typeMap = props2.schema.getTypeMap && props2.schema.getTypeMap();
+
   return /* @__PURE__ */ jsxs(Fragment, {
     children: [/* @__PURE__ */ jsx(MarkdownContent, {
       type: "description",
@@ -19671,6 +19665,29 @@ function SchemaDocumentation(props2) {
           type: subscriptionType
         })]
       })]
+    }), !typeMap ? null : jsxs(ExplorerSection, {
+      title: "Possible Types",
+      children: [
+        Object.values(typeMap).map(typeValue => {
+          const renderedKinds = [
+            "Interface",
+            "Object",
+          ].map(s => `GraphQL${s}Type`)
+
+          const ctorName = typeValue.constructor.name
+          const typeName = typeValue.name;
+
+          const ignoredTypes = ['Query', 'Subscription'];
+
+          if (renderedKinds.includes(ctorName) && !ignoredTypes.includes(typeName) && typeName[0] !== '_') {
+            return jsxs("div", {
+              children: [jsx(TypeLink, { type: typeValue })],
+            })
+          }
+
+          return null;
+        })
+      ]
     })]
   });
 }
@@ -19811,7 +19828,6 @@ function fillInChunks(_ref4) {
       });
     }
   }
 }

https://user-images.githubusercontent.com/15332326/213796151-c92d1c8b-3bb4-49ef-8630-a6ace29ddb83.mov
As alternatives, I've considered disabling the Documentation Explorer plugin and swapping it with my own version, and mutating DOC_EXPLORER_PLUGIN export like a bandit, but I feel like it would be nice to have this feature in all GraphiQLs, not only in mine :)

Sorry for the late response, I like this idea, let's wait for thoughts for the team cc @acao @jonathanawesome @thomasheyenbrock

@hasparus I really like this idea! we could also call it 'all schema types'
noting that some schemas include a lengthy markdown in the Schema.description, so perhaps we can make it disable-able via a plugin setting, but I like the idea of enabling this feature by default


runtime_error  CU timeout 0

When I use vck5000 run onnxruntime demo, get into error

I try the flow with u200 ,it's succeed.
How can I solve this error?

hi @jzymessi
Which vck5000 DPU ID did you used? https://github.com/Xilinx/Vitis-AI/blob/master/setup/vck5000/README.md
Are you using vck5000 prod or vck5000 es?
And you can first verify your machine state with the release xmodel and AILibrary in docker container.

@SuZhan0322 :
After my experiment, it seems to be compiled using VITIS-AI-2.0 environment, but running in ViTIS-AI-2.5 environment.
By the way,I encountered two errors in feature extraction data when running the model. The feature results extracted from all pictures are the same. I have solved the problem after powering off and restarting VCK5000. May I ask how this phenomenon is caused?

@jzymessi ：
The model's build environment version should be the same as the runtime environment version.  They need to be all VITIS-AI-2.0 or all VITIS-AI-2.5.
After the model runs timeout, the DPU state will not meet expectations. We recommend to reset the board or cold restart after DPU timeout.


Is it possible to ignore at Docket initialization specific methods/endpoints from actuator?

I'm interested in ignoring all /health endpoints but the GET /health.
Is it possible to exclude specific methods from the documentation?
From the example bellow, I'm ignoring all /health.json endpoints from /health, but I still want to ignore:
DELETE /health
HEAD /health
OPTIONS /health
PATCH /health
POST /health
PUT /health
@Bean
public Docket swaggerSettings() {
    return new Docket(DocumentationType.SWAGGER_2)
            .select()
            .apis(any())
            .paths(not(regex("/error")))
            .paths(not(regex("/health.json")))
            .build();
}

This is currently not possible unfortunately. I believe there is an issue for this already


night mode

this adds the command night_mode which inverts all colors (except for media attachments)

Looks great! I'd love it if the command added / removed the night_mode class to body so that custom.css could adapt to this.

oh, yeah you're right. that seems like a much better solution
going to try that!

loading custom.css again after night_mode.css (permitting proper cascade) would be a simpler and better UX solution.


On task loading error: "show task" button

Description
Fixes #949
Notes (out of scope, known issues, hints for reviewing code, ...)  (optional)
Since error messages are already blue, I used the usual link color (grey, not blue) because otherwise it was not obvious that a user action was available.
Test cases

[ ] Case 1:

Given I am an anonymous user
When I go to this activity
And I wait for the task to fail
Then I see the normal error message "Unable to load this task"

[ ] Case 2:

Given I am the usual user
When I go to this activity
And I wait for the task to fail
Then I see the two error messages: "It usually occurs when task url is invalid, if the task url is valid and the problem persists, please contact us" and "Show task anyway (for debugging)"
And I click on "Show task anyway"
Then I see the error message is hidden and the iframe is shown

From a usage test:

what the difference between the two cases? Why the anonymous user do not have the "Show task anyway"?
design-wise, that looks very strange: maybe an actual small p-button would be more appropriate?


updated url

I got a 404 error on the URL in ImplicitParams.scala so I updated it to what I think is the new URL. (Also, my apologies if I didn’t choose the correct branch here.)

This failure is the same as the one on master and unrelated, so merging.


Fix bug when specifying customGeckoDriverPath

WHAT?
Destructured customGeckoDriverPath out of params in function start().
Additionally, updated test.e2e.js to test the three webdriver usage modes: 1/ automatically download and start, 2/ automatically start, 3/ manually start.
Finally, added a self-referencing devDependency to geckodriver since webdriverio transitively depends on it.
WHY?
Before this change, running the following code:
import { start } from 'geckodriver'

await start({ customGeckoDriverPath: '/some/path/geckodriver' })

Would fail to start the geckodriver because it would execute:
geckodriver --custom-gecko-driver-path=/some/path/geckodriver --port=43083 --host=<IP_ADDRESS> --websocket-port=0

Which results in exit code 64 and the following output:
/some/path/geckodriver: error: Found argument '--custom-gecko-driver-path' which wasn't expected, or isn't valid in this context

If you tried to supply `--custom-gecko-driver-path` as a value rather than a flag, use `-- --custom-gecko-driver-path`

USAGE:
    geckodriver [OPTIONS]

For more information try --help

By destructuring customGeckoDriverPath, the extraneous --custom-gecko-driver-path argument is no longer specified and the webdriver starts successfully.
HOW?
Successfully ran:
npm run build && npm test

Can we update the branch?

Can we update the branch?

Done!

Thank you!


Update/Add NDK (Side by side)

Tool information

Tool name: NDK (Side by side)
Tool license: Apache License Version 2.0
Add or update? Add
Desired version: N/A
Approximate size: N/A
If this is an add request:

Brief description of tool: NDK (Side by side) allows multiple NDKs to be installed.
URL for tool's homepage: https://developer.android.com/studio/projects/install-ndk
Provide a basic test case to validate the tool's functionality: N/A

Area for Triage: Android
Question, Bug, or Feature?: Feature
Virtual environments affected

[x] Ubuntu 16.04
[x] Ubuntu 18.04
[x] Ubuntu 20.04
[x] macOS 10.15
[x] macOS 11.0
[x] Windows Server 2016 R2
[x] Windows Server 2019

Can this tool be installed during the build?
Yes. ${ANDROID_SDK_ROOT}/cmdline-tools/latest/bin/sdkmanager --install "ndk;version"
Tool installation time in runtime
1 minute
Are you willing to submit a PR?
I think we should discuss it first.
NDK (Side by side) allows multiple NDK to be installed, And ndk-bundle should keep the NDK LTS version.
We should at least install the latest version, AGP default version and LTS version.

AGP
Default NDK version

4.1
21.1.6352462

4.0
21.0.6113669

3.6
20.0.5594570

Path
Version
Description
Suggest

ndk-bundle
22.0.7026061
NDK (Bundle)
symbolic link to last LTS version (21.X)

ndk;16.1.4479499
16.1.4479499
NDK (Side by side) 16.1.4479499

ndk;17.2.4988734
17.2.4988734
NDK (Side by side) 17.2.4988734

ndk;18.1.5063045
18.1.5063045
NDK (Side by side) 18.1.5063045

ndk;19.2.5345600
19.2.5345600
NDK (Side by side) 19.2.5345600

ndk;20.0.5594570
20.0.5594570
NDK (Side by side) 20.0.5594570
Install (AGP Default)

ndk;20.1.5948944
20.1.5948944
NDK (Side by side) 20.1.5948944

ndk;21.0.6113669
21.0.6113669
NDK (Side by side) 21.0.6113669

ndk;21.1.6352462
21.1.6352462
NDK (Side by side) 21.1.6352462
Install (AGP Default)

ndk;21.2.6472646
21.2.6472646
NDK (Side by side) 21.2.6472646

ndk;21.3.6528147
21.3.6528147
NDK (Side by side) 21.3.6528147
Install (last LTS)

ndk;22.0.7026061
22.0.7026061
NDK (Side by side) 22.0.7026061
Install (last)

Hi @vvb2060,
we are already implementing installation of latest (currently r22) and LTS (currently r21) versions side by side, you can track process in these PRs: Ubuntu, macOS, Windows.
We are also getting rid of ndk-bundle due to possible breaking changes when it updates to new version.
I will keep this issue open, we'll notify you when changes go to the rollout stage (approx. next week). Thanks!

Hi @vvb2060,
we are already implementing installation of latest (currently r22) and LTS (currently r21) versions side by side, you can track process in these PRs: Ubuntu, macOS, Windows.
We are also getting rid of ndk-bundle due to possible breaking changes when it updates to new version.
I will keep this issue open, we'll notify you when changes go to the rollout stage (approx. next week). Thanks!

Will you install the default NDK version of AGP?  I think that many people have not configured the NDK version, and due to an AGP bug, AGP is likely to ignore the configured version and download the default NDK version.

Will you install the default NDK version of AGP?  I think that many people have not configured the NDK version, and due to an AGP bug, AGP is likely to ignore the configured version and download the default NDK version.

Do you mean 21.1.6352462 that is specified as a default version for AGP 4.1?
Our future strategy is to always install latest patch of LTS and latest non-LTS versions. Unfortunately, we cannot afford to install a wide range of versions due to space concerns, especially for Ubuntu images.

Do you mean 21.1.6352462 that is specified as a default version for AGP 4.1?
Our future strategy is to always install latest patch of LTS and latest non-LTS versions. Unfortunately, we cannot afford to install a wide range of versions due to space concerns, especially for Ubuntu images.

Closing this issue for now. Currently, images contain NDK 21 (latest LTS) and NDK 22 (latest) will be added next week in https://github.com/actions/virtual-environments/issues/2365
As Alena mentioned above, we can't afford to pre-install more NDK versions to images. If you need any specific version - please install it in runtime.


how can you configure jest transform to process files outside of jest root?

Issue
I have a project structure like so:
projectA
shared

I am running jest inside of project A. I have files that I am importing from projectA that are in the shared sibling folder. What is the right way to configure jest transform to also process the files in shared?
my current transform config:
  transform: {
    "^.+\\.(ts|tsx|js|jsx)$": "<rootDir>/node_modules/babel-jest",
    "^.+\\.(ts|tsx|js|jsx)$": "ts-jest",
  },

Expected behavior

[describe the expected behavior here]

Output from your debug log
[ You can activate the debug logger by setting the environment variable TS_JEST_DEBUG="true" before running yarn test. The output of the logger
will be in <your_project_dir>/node_modules/ts-jest/debug.txt ]

Link to a minimal repo that reproduces this issue

[If you haven't already, create the smallest possible repo that reproduces this issue by running npm install and npm test. This will speed up any fixes that this issue might need]

Optional (but highly recommended) - Configure Travis (or your favorite system) with the minimal repo

This allows potential solutions to be tested against the minimal repo. This saves everyone time and avoids a lot of back and forth.

Hi @kelly-tock, this is explained in jest documentation
It would help to have your full jest config, but yeah I guess you're missing some modulePaths value. Also the transform you gave us here has twice the same key: it should be something like:
  transform: {
    "\\.(ts|js)x?$": "ts-jest",
  },

and be sure you have allowJs in your tsconfig, or use this as transform instead:
  transform: {
    "\\.tsx?$": "ts-jest",
    "\\.jsx?$": "babel-jest",
  },


ci: use nextest

Replaces cargo test with nextest, and also fixes a potentially flaky port assignment routine.
Benefits of nextest:

Instead of building 6 times, we build 3 times
The test runs themselves do not require Rust
Good integration with coverage tools (see https://github.com/taiki-e/cargo-llvm-cov)
Nextest can retry and report on flaky tests
We can partition slower test suites if we want
Faster than Cargo

Cons:

While nextest does not require anything special and is 1:1 compatible with Cargo's test runner, it might still be a concern that we use nextest remotely and not necessarily locally
Since it's super fast a lot of our tests are outed as being super flaky lol

The workflow works like this:

We build archives of test executables using nextest
Integration tests, unit tests and external unit tests are run in matrixes off of these artifacts

Edit: The run might look somewhat slow but that's because the Rust cache had to rebuild - subsequent runs are about 3-4 mins for build.

supportive of this, read the docs couple days ago, the retry feature should definitely come in handy

Rebased on top of #2048

Good to merge, can always iterate more on it to improve speed and add coverage :smile: I'm not entirely sure how to approach coverage yet since we're running split jobs, so we'd need to figure out where cargo llvm-cov places the coverage data and share that between jobs. Alternatively, perhaps it is possible for tools like CodeCov to merge multiple uploads for the same job.

yep, agreed


setDragImage type signature causing BigInt conversion issue

Any idea why the signature for setDragIamge uses int64? It exists in both the Nim dom module and kdom_impl here.
https://github.com/nim-lang/Nim/blob/78c834dd76f273d8813247647531005a1f7db1a6/lib/js/dom.nim#L1658
https://github.com/karaxnim/karax/blob/141f116535f6a16de17f426b9d09294aa28486e6/karax/kdom_impl.nim#L1160
It seems to be causing this error in the browser:  Uncaught TypeError: Cannot convert a BigInt value to a number
Due to emitting 0n instead of 0:  dev_704645398.dataTransfer.setDragImage(overlay_704645399, 0n, 0n);
Converting it to int seems to solve the issue for me.

Good point, please fix it.

fixed by https://github.com/karaxnim/karax/pull/286


matrix-org/node-irc dependency not tracking upstream

In #170 / 52fcb1c the hubot-irc adapter was moved from node-irc to a fork, and pinned to a specific ref. There appear to be two problems with this:

Because the dependency is pinned to a ref, the hubot-irc adapter is no longer tracking any bugfixes or updates made to that fork.
The fork that has been selected is missing vital bugfixes from upstream.

An example of one such missing bugfix is martynsmith/node-irc#452. I happen to be encountering this multiple connection error right now.
Suggested fix: move back to martynsmith/node-irc.
I'm happy to send a PR to do so. Let me know if the maintainers are open to switching back.

I'm happy to test and review a PR.

Sorry for the delay.
We should most likely not switch back to martynsmith/node-irc simply because while matrix-org's version may be missing a few bug fixes, marty's version seems to have development entirely halted (matrix-org's version also has many features and additions because of this).
I forgot why I exactly I pinned to a specific ref at the time, but it was probably A Bad Idea(TM). Let's definitely undo that.
I think the best course of action going forward is still to use matrix-org's version, and help port over bugs that marty's version has resolved. I'm not worried about matrix-org halting development because they use it in production to manage 10% of connections to Freenode :slightly_smiling_face: .
In actuality, I've recently just gotten back from a OSS development hiatus and I believe that Hubot actually has a new version - so it might make sense to re-write hubot-irc entirely (we might not actually have another option) before they deprecate APIs we're using.
Let me know your guy's thoughts.
/cc @stephenyeargin

My experience has been that v3 hasn't been disruptive for other packages/adapters. The team there was mostly "decaffeinating" it (converting everything into ES6 from CoffeeScript, cleaning up other internals rather than overhauling the APIs). We're running the current version of hubot-irc and 3.1.1 without issue.

@chrisdotcode Sounds like despite your hiatus you're in a better position than I am to judge which of the two forks has a brighter future. I only run one of my hubot's on IRC and it's on a private server. If you think the matrix-org version is a better long-term fit, I'm all about helping to get some bugs in it fixed.

I have developed a potential fix in matrix-org/node-irc#34 for the primary issue that led me to open this: hubot-irc keeping open multiple connections.

The folks at matrix-org have merged my PR matrix-org/node-irc#34. #177 will catch us up to the latest node-irc which should contain that fix.

Thanks for merging #177. I believe we are still waiting on the maintainers to cut a new release to npm before we can close this one.

It has been 1.5 years since the last release of hubot-irc and 7 months since I fixed this bug. Can we either get a new release published to npm or can myself or @stephenyeargin get added as maintainers here and on npm? Those of us using this in production would love to see this bug fixed.

Closing since #177 was merged, and a new version was released.