misc: ignore some files during npm publish

Motivation
This single change should reduce bundle size by 100KB / package. We can even be more aggressive and ignore more stuff in the src folder; we just need those actually required at runtime. For now I decided to not do much, considering that the TS components are used for swizzling. The files that certainly should be ignored:

copyUntypedFiles.js
.tsbuildinfo (and this file is large: just ignoring this is able to save 50KB)
tsconfig
__tests__

Have you read the Contributing Guidelines on pull requests?
Yes

Making another action to monitor the package size probably doesn't make a lot of sense because we are a node app anyways and package sizes aren't critical, but I still did two local publishes to compare the bundle sizes:

Mmm, some of them contain the type declaration files, and these declarations in turn import from the src files, so refactoring them is going to be a little risky. I will err on the safe side and only do refactors later

We can ignore all files in source directory except for certain files, in our case it should work for docs plugin:
src/*
!src/plugin-content-docs.d.ts

Done! I was a bit worried about the safety of doing so (accidentally not publishing something in the future) but for now it seems safe

Yep, this is significant 👀

Alternatively you can use the package.json files field to create an array of file patterns to include instead of files to exclude.
https://yarnpkg.com/configuration/manifest#files

Our exclude pattern is quite complex, so we'd rather opt-in for ignore rather than opt-out. (cf #6087 for a publish mistake) I originally didn't even plan to exclude the TS source files.

Asked here about publishing src or not: https://twitter.com/sebastienlorber/status/1471156386050592778
Seems there's a usecase for using sourcemaps in Node.js + TS
Otherwise, there's no strong consensus so far. I'm ok to not publish sources if we find a sustainable way to manage exclusions and prevent mistakes.
As a first step we could merge asap the exclusion of everything else, and figure out about src in another PR?

Maybe we should keep sources for now, and test publishing source/declaration maps?
We'll see then if those features are useful or not in practice, or if it's worth optimizing the package size even more?

Yes, I'm actually in favor of publishing src. But if we publish src, we should also publish a source map, since that would mean I don't end up inspecting the compiled output. Sounds good @slorber?

If we publish source, we should also publish source maps;

Yes, that seems like a nice thing to do (+ declaration maps?)

We shouldn't publish src for the plugins / themes since they never expose APIs;

I don't understand, you said the opposite in the line just before? 😅
src/theme should rather always be published for swizzle + if we have some typedefs importing src files it will also break. So in current state it doesn't look safe to me

We should publish src for the utility packages that will be imported;

Do we really need to make any distinction? It seems that it can be useful to publish sources all the time, for all packages, with source/declaration maps + ability to read/inspect the code more easily + swizzle
To me, it does not look worth it to optimize further and publish src partially according to complex rules: we probably have much lower handing fruits in our dependencies.
Also, there is much more impactful research we can do to make Docusaurus significantly faster to install. Next.js is pre-compiling its dependencies as single files with ncc: https://github.com/vercel/ncc (ex with Babel: https://github.com/vercel/next.js/pull/18768)
For these reasons, I think including/excluding src is not really time-worthy to discuss, at least not atm. It is really a micro-optimization with a very limited impact.
I'd only focus on the obvious easy changes to exclude in this PR

We should invert the way we import the types and make sure the declaration files are always working on their own so that all the .ts files can be safely npm ignored.

Agree that there is remaining cleanup to be done. Exposed types should probably be .d.ts and we should find a way to prevent type imports from .ts

I don't understand, you said the opposite in the line just before? 😅

The previous sentence was a logical implication: if we publish the source, then we publish the source maps :D However publishing source isn't really worthwhile for things that would never be imported.
I would agree to not bikeshed on whether src should be ignored and just include it for now, but let's not pretend that the line is unclear: the plugins and themes are never imported in other codes, and if they ever need to be, it means we should refactor those methods into utils instead.

Still looking good despite generating source maps. Removing test files and tsbuildinfo certainly helps:

👍 that's already a decent win thanks
For themes/plugins, I believe there's value to publish sources:

easily inspect sources
it may be imported once we support an API to extend existing plugins
it may need to contain sources to implement the docusaurus theme diff feature I suggested in https://github.com/facebook/docusaurus/issues/6114)


Add multihop support to GeneratePath()

Dependent on: https://github.com/cosmos/relayer/pull/1192/files


pass IO descriptors to HOOK transparently

closes #101
Verified with following test-hook:
#!/bin/bash

echo "Args:"
for a
do
	echo "$a"
done
echo "Press return"
read

BTW: In contrast to the official client your script is a delight (and just works).  Thanks!

I don't really like this, it looks ugly, but up to now this is the best solution so i'll merge it.


Initial support for poll-based backend

With mio_unsupported_force_poll_poll, mio will use the legacy poll(2) syscall instead of epoll or kqueue.  While this is not intended to replace either of those more modern and efficient alternatives, it is a suitable avenue to enable a lot of other somewhat more obscure platforms such as the esp32 family or Haiku OS.  esp-idf support is my primary purpose and I believe the esp-rs community can get behind this as a way to better interop with a large number of Tokio-based async crates out there, but this PR is intended only to provide the barebones technical support for now with minimal invasion into existing production code paths.
This work is largely based off #1602 with improvements to fix tests and provide a more consistent implementation.  Specific changes include:

Closed fds are now automatically removed as is the case with the Windows implementation
Waker supports the same re-registration pattern as IoSourceState
Haiku and esp-idf specific changes were greatly minimized.  IMO, those should be introduced as part of separate PRs for each respective platform.

Closes #1604

Also, I wonder if maybe the WakerRegistrar thing would be better served by copying the kqueue design pattern whereby the Selector provides factory-type methods to create and use a waker.  I didn't notice that it already is working pretty similarly to what I need until just now...

Indeed, I think I found a much cleaner way to detangle Waker behaviour from the Selector so that we can have the concept of a WakerDriver (a low-level description of how to call eventfd, pipe, pipe2, or kevent) vs a Waker which is created by the selector and introduces some customization of the WakerDriver behaviour based on the selector's quirks.  For example, the poll selector can use either eventfd or pipe2 WakerDriver, but the Waker it creates requires reregistering the interest with poll before wake can be called.  The epoll selector can use either eventfd or pipe2 WakerDriver, but the Waker it creates has a no-op before each call to wake.
This seems to elegantly resolve one existing gotcha and two that I created:

pipe::Waker::wake no longer needs an illumos-specific cfg check.  Instead, the epoll selector will have that check since it is epoll-specific behaviour on that platform that's the issue.
I can drop my WakerRegistrar as I can now have the poll selector directly control reregistration of whatever WakerDriver is used
The poll selector won't need another eventfd/pipe impl living in side the poll selector for the purposes of internally waking a blocking poll call.  We can just use the WakerDriver internally.

This also fixes the FreeBSD failing tests (which are actually just because WakerRegistrar is unused in the kqueue path)

Oh and also I could break up the refactor into a separate PR so it's easier to swallow and confirm that it's correct without introducing the poll backend.

I was wrong re my statement that any UNIX should be able to support the poll+pipe backend.  While technically true that it will "work", it's hopeless to get all current tests to pass because libc::POLLRDHUP is Linux-specific and without it tests like tests/tcp.rs:write_shutdown will fail.  There are about a dozen tests like this.  This does mean that mio still works of course, just that shutdown(Read/Write) will not behave as expected and the caller will need to detect these shutdown events by trying to read or write.

I wanted to review this in the weekend, but I didn't. I think this still has a lot of changes that are not strictly necessary for poll(2) support. From the changes to IoSourceState (can be contained to src/sys/unix/poll.rs), to the macros (not required), but also the waker (this should just be an pipe/eventfd fd with IoSourceState). Also unnecessary name changes Waker to WakerDriver?
Maybe I have time next weekend, but not promises, I do want to reduce the number of changes though. I really like to see a minimal set of changes to implement this.

From the changes to IoSourceState (can be contained to src/sys/unix/poll.rs)

Ackd, I'll avoid breaking things out into separate files.

...to the macros (not required)

I only did this because the original PR reviewer asked for it because the PR will require copy/pasting the cfg criteria quite a few times.  I can drop it though, but see my comments below so we're on the same page as to how many times this will need to get repeated.

...but also the waker (this should just be an pipe/eventfd fd with IoSourceState)

I'm not sure how this can be achieved.  The critical difference between epoll vs poll is that for poll you either need to read the pipe/eventfd when it wakes (what the original PR did) or you need to reregister the interests again before calling wake (what my PR did).  In either case, there needs to be code that allows the poll Selector to interact with Waker internals.  IoSourceState is also but separately interacting with Selector internals.
Fwiw the reason I opted for a different strategy was so that I didn't need to deepen the circular relationship between Selector and Waker but could rather describe the dependencies as such:
Selector -> Waker -> WakerDriver
Waker -> Selector

Also unnecessary name changes Waker to WakerDriver?

There wasn't a rename here as such, but rather WakerDriver was added to be used by Waker.  This is because as I mentioned above in a previous comment, we need to use pipe or eventfd to internally wake poll() when register() is called.  But Waker as written right now calls register in the constructor making it a bit fragile to reuse internally.  So I stripped WakerDriver away which is just a pure side effect free API and then added Waker back inside the Selector with the register side effect.  This allowed the poll Selector to internally use WakerDriver and this neither duplicated code nor, as the original PR did, unintentionally use pipe for the internal register() wakeup case but eventfd for the Waker case.

Maybe I have time next weekend, but not promises, I do want to reduce the number of changes though. I really like to see a minimal set of changes to implement this.

Understood, I'm willing to rework the PR with reduced churn, it's just not 100% clear where the tradeoffs should be.  See my comment above about how clumsy it gets to try to conditionally call reregister() inside wake() only for the poll Selector case.  If that clumsiness is preferred, that's what I'll do.
It is, I admit, less intrusive to use the original PR's strategy for reading the pipe/eventfd on wake tho since you only need to add new constructor APIs that don't do the register (e.g. new_internal), then add a new clear() API that resets them as needed.  I'll play around with this approach some more and see if I can't get it to look a little less clumsy than the original PR had it.

Also wanted to thank you for taking the time to review and discuss. I know this poll support is probably weighing on you as a reviewer a bit after so much churn and iteration.  This will be such a huge help for the esp32 community once we're able to get it over the line though!

...to the macros (not required)

I only did this because the original PR reviewer asked for it because the PR will require copy/pasting the cfg criteria quite a few times. I can drop it though, but see my comments below so we're on the same page as to how many times this will need to get repeated.

I'm personally a bit torn on the macros. For things like cfg_net they help, but for the selector I'm no so sure, I think the code/cfgs is easier to follow without th emacro.

...but also the waker (this should just be an pipe/eventfd fd with IoSourceState)

I'm not sure how this can be achieved. The critical difference between epoll vs poll is that for poll you either need to read the pipe/eventfd when it wakes (what the original PR did) or you need to reregister the interests again before calling wake (what my PR did). In either case, there needs to be code that allows the poll Selector to interact with Waker internals. IoSourceState is also but separately interacting with Selector internals.

I was thinking an eventfd/pipe who's fd is always passed to poll (assuming the waker was added), preferably in a fixed position in the pollfds. Then we always check the waker's pollfd and drain it's readiness if we get an event (e.g. read from the pipe). For the Waker we can't use the kqueue implementation as it has no fd, but the eventfd and pipe should continue working as normal, I would expect. The only change in the Waker code would be a special call to register, something like selector.register_waker, which for poll(2) would mean to duplicate the fd and use it as described above. For epoll we can just call register.register (as we currently do).

Fwiw the reason I opted for a different strategy was so that I didn't need to deepen the circular relationship between Selector and Waker but could rather describe the dependencies as such:
Selector -> Waker -> WakerDriver
Waker -> Selector

Also unnecessary name changes Waker to WakerDriver?

There wasn't a rename here as such, but rather WakerDriver was added to be used by Waker. This is because as I mentioned above in a previous comment, we need to use pipe or eventfd to internally wake poll() when register() is called. But Waker as written right now calls register in the constructor making it a bit fragile to reuse internally. So I stripped WakerDriver away which is just a pure side effect free API and then added Waker back inside the Selector with the register side effect. This allowed the poll Selector to internally use WakerDriver and this neither duplicated code nor, as the original PR did, unintentionally use pipe for the internal register() wakeup case but eventfd for the Waker case.

That makes more sense. If my idea describe above doesn't work we can go with something like this. But I'm not sure about the "driver" name, but we can bikeshed this later.

Maybe I have time next weekend, but not promises, I do want to reduce the number of changes though. I really like to see a minimal set of changes to implement this.

Understood, I'm willing to rework the PR with reduced churn, it's just not 100% clear where the tradeoffs should be. See my comment above about how clumsy it gets to try to conditionally call reregister() inside wake() only for the poll Selector case. If that clumsiness is preferred, that's what I'll do.

See above, but I prefer to limit the scope of this pr, affecting the minimal amount of non-poll(2) code would be ideal. That makes it easier to review and less risky to merge as other code isn't affected.

It is, I admit, less intrusive to use the original PR's strategy for reading the pipe/eventfd on wake tho since you only need to add new constructor APIs that don't do the register (e.g. new_internal), then add a new clear() API that resets them as needed. I'll play around with this approach some more and see if I can't get it to look a little less clumsy than the original PR had it.

Also wanted to thank you for taking the time to review and discuss. I know this poll support is probably weighing on you as a reviewer a bit after so much churn and iteration. This will be such a huge help for the esp32 community once we're able to get it over the line though!

I appreciate this. I very much want to help the esp32 community, but my main priority is to keep the existing code working and maintainable (for my own sanity).

I was thinking an eventfd/pipe who's fd is always passed to poll (assuming the waker was added), preferably in a fixed position in the pollfds. Then we always check the waker's pollfd and drain it's readiness if we get an event (e.g. read from the pipe). For the Waker we can't use the kqueue implementation as it has no fd, but the eventfd and pipe should continue working as normal, I would expect. The only change in the Waker code would be a special call to register, something like selector.register_waker, which for poll(2) would mean to duplicate the fd and use it as described above. For epoll we can just call register.register (as we currently do).

Looking into more detail here and this is basically how the original PR (#1602) worked but it needed unsafe handling of the waker RawFd and a change to all sys::Selector impls.  I also realized that your suggestion to dup the fd won't work directly directly because esp32 doesn't implement dup but it can work indirectly by just internally re-using the waker we know the poll-impl already has:
#[cfg(mio_unsupported_force_poll_poll)]
mod poll {
  pub struct Waker {
    selector: sys::Selector,
  }

  impl Waker {
    pub fn new(selector: &Selector, token: Token) -> io::Result<Waker> {
      Ok(Waker { selector: selector.try_clone()? })
    }

    pub fn wake(&self) -> io::Result<()> {
      // Since this is the poll-only impl, the Selector would need only to call self.notify_waker.wake() and everything would
      // just work the exact same way it does when you call Selector::register.
      select.selector.wake_internal()
    }
  }
}

This would then save on an fd and make the code path far, far clearer how it's being used.  So, the only real issue then is how can we get the poll impl to re-use the code we have in eventfd::Waker and pipe::Waker.  I'd propose that once again the WakerDriver idea helps us here (pending a rename perhaps):

Expose pub(crate) versions of eventfd::Waker and pipe::Waker as a new type (for argument let's say WakerImpl) that doesn't interact with Selector at all (like what my PR did with WakerDriver).  This can be a simple rename mostly, but unlike my PR today will not include other Waker implementations and is only meant to be an internal sys/unix utility to re-use eventfd/poll impl code.
Convert the eventfd::Waker and pipe::Waker types to be simple pass-throughs to eventfd::WakerImpl and pipe::WakerImpl with the extra register behaviour on top.
Add a new poll::Waker as written above that is a simple pass-through to poll::Selector::wake_internal.

Thoughts?  I'm working on this locally now in parallel but I want to be respectful of your suggestions and not blindside you with changes to the PR that aren't quite like we discussed already.

Force pushed a reworked version of the PR that I think is much cleaner based on your feedback and on my comment above.  Heads up that there is a functional change here to re-use the internal Waker which both simplifies the implementation and makes it much clearer why we had to slightly refactor eventfd::Waker and pipe::Waker.

Silly mistake had the CI checks not running, now that they're up and failing I'll go ahead and fix.

Applied most of the suggested changes (see comments above on the others) and confirmed tests still pass.  If you prefer I can squash all commits to prepare to merge.

Ok applied a few more suggestions and left a tracking issue for the optimizations.  Again, I can squash all these commits if you prefer, just lmk how you want to proceed to merge.

Just caught an issue from CI that needs to be addressed, working on fixing up a bad assumption that IoSourceState in sys/shell/mod could assume non-Windows was UNIX which breaks for wasm32-wasi

Thanks @jasta for pulling this over the finish line!


SSLCertVerificationError

hi All,
We are getting the below error in the logs .
2023-03-09 11:37:01: Caught exception while requesting OAuth 2.0 credentials for<EMAIL_ADDRESS>URLError(SSLCertVerificationError(1, '[SSL: CERTIFI
ATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:997)'))
2023-03-09 11:37:01: IMAP (localhost:1993; <IP_ADDRESS>:52373->outlook.office365.com:993) <-- b'A1 NO AUTHENTICATE Email OAuth 2.0 Proxy: Login failed for account
<EMAIL_ADDRESS>- please check your internet connection and retry\r\n'
2023-03-09 11:37:01: IMAP (localhost:1993; <IP_ADDRESS>:52373->outlook.office365.com:993) <-- b'* BYE Autologout; authentication failed\r\n'
We are getting the error from
except Exception as e:
# note that we don't currently remove cached credentials here, as failures on the initial request are before
# caching happens, and the assumption is that refresh token request exceptions are temporal (e.g., network
# errors: URLError(OSError(50, 'Network is down'))) - access token 400 Bad Request HTTPErrors with messages
# such as 'authorisation code was already redeemed' are caused by our support for simultaneous requests,
# and will work from the next request; however, please report an issue if you encounter problems here
Log.info('Caught exception while requesting OAuth 2.0 credentials for %s:' % username, Log.error_string(e))
return False, '%s: Login failed for account %s - please check your internet connection and retry' % (
APP_NAME, username)
===================
We checked it in AZURE Portal and Certificate is valid till next year,
can you Please Help it out, it is impacting all our production Enviorenment

THank you rob ,  i will consider sponsoring you without any issue,
fyi, Tool is working for without any issues till yesterday , this issue has started recently ,
As noticed, authectication is not happening,
i removed
token_salt
access_token
access_token_expiry
refresh_token
last_activity
and popup for sutehectaion has come and it closing automtatically,
2023-03-10 05:39:32,641: Initialised Email OAuth 2.0 Proxy - listening for authentication requests. Connect your tradeXpress 5 email client to begin
2023-03-10 05:39:33,125: Authorisation request received for<EMAIL_ADDRESS>(interactive mode)
2023-03-10 05:39:54,044: Returning authorisation request result for<EMAIL_ADDRESS>2023-03-10 05:39:54,303: Authorisation request received for<EMAIL_ADDRESS>(interactive mode)
2023-03-10 05:40:24,835: Returning authorisation request result for<EMAIL_ADDRESS>
in debug mode i am seeing below error.
2023-03-10 06:27:49,630: Caught exception while requesting OAuth 2.0 credentials for<EMAIL_ADDRESS>URLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:997)'))
2023-03-10 06:27:49,632: IMAP (localhost:1993; <IP_ADDRESS>:61408->outlook.office365.com:993) <-- b'A1 NO AUTHENTICATE Email OAuth 2.0 Proxy: Login failed for account<EMAIL_ADDRESS>- please check your internet connection and retry\r\n'
2023-03-10 06:27:49,638: IMAP (localhost:1993; <IP_ADDRESS>:61408->outlook.office365.com:993) <-- b'* BYE Autologout; authentication failed\r\n'
2023-03-10 06:27:49,651: Caught exception while requesting OAuth 2.0 credentials for<EMAIL_ADDRESS>URLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:997)'))
2023-03-10 06:27:49,660: SMTP (localhost:1587; <IP_ADDRESS>:61576->smtp.office365.com:587) <-- b'535 5.7.8  Authentication credentials invalid. Email OAuth 2.0 Proxy: Login failed for account<EMAIL_ADDRESS>- please check your internet connection and retry\r\n'
2023-03-10 06:27:49,892: New incoming connection to SMTP server at localhost:1587 (unsecured) proxying smtp.office365.com:587 (STARTTLS)
2023-03-10 06:27:49,892: Accepting new connection to SMTP server at localhost:1587 (unsecured) proxying smtp.office365.com:587 (STARTTLS) via ('<IP_ADDRESS>', 61634)
2023-03-10 06:27:49,908: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) --> [ Client connected ]
2023-03-10 06:27:49,908: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'220 PR1P264CA0052.outlook.office365.com Microsoft ESMTP MAIL Service ready at Fri, 10 Mar 2023 05:27:51 +0000\r\n'
2023-03-10 06:27:49,908: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'220 PR1P264CA0052.outlook.office365.com Microsoft ESMTP MAIL Service ready at Fri, 10 Mar 2023 05:27:51 +0000\r\n'
2023-03-10 06:27:49,923: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) --> b'EHLO srveditdx5.cat.groupecat.com\r\n'
2023-03-10 06:27:49,923: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     --> b'EHLO srveditdx5.cat.groupecat.com\r\n'
2023-03-10 06:27:49,923: New incoming connection to IMAP server at localhost:1993 (unsecured) proxying outlook.office365.com:993 (SSL/TLS)
2023-03-10 06:27:49,923: Accepting new connection to IMAP server at localhost:1993 (unsecured) proxying outlook.office365.com:993 (SSL/TLS) via ('<IP_ADDRESS>', 61636)
2023-03-10 06:27:49,923: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-PR1P264CA0052.outlook.office365.com Hello [<IP_ADDRESS>]\r\n'
2023-03-10 06:27:49,923: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-SIZE 157286400\r\n'
2023-03-10 06:27:49,923: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-PIPELINING\r\n'
2023-03-10 06:27:49,939: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-DSN\r\n'
2023-03-10 06:27:49,939: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993) --> [ Client connected ]
2023-03-10 06:27:49,939: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-ENHANCEDSTATUSCODES\r\n'
2023-03-10 06:27:49,939: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993) <-> [ Starting TLS handshake ]
2023-03-10 06:27:49,939: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-STARTTLS\r\n'
2023-03-10 06:27:49,939: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-8BITMIME\r\n'
2023-03-10 06:27:49,939: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-BINARYMIME\r\n'
2023-03-10 06:27:49,939: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-CHUNKING\r\n'
2023-03-10 06:27:49,939: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250 SMTPUTF8\r\n'
2023-03-10 06:27:49,939: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     --> b'STARTTLS\r\n'
2023-03-10 06:27:49,955: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'220 2.0.0 SMTP server ready\r\n'
2023-03-10 06:27:49,955: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-> [ Starting TLS handshake ]
2023-03-10 06:27:49,955: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) [ Successfully negotiated SMTP STARTTLS connection - re-sending greeting ]
2023-03-10 06:27:49,955: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993) <-> [ TLS handshake complete ]
2023-03-10 06:27:49,970: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     --> b'EHLO srveditdx5.cat.groupecat.com\r\n'
2023-03-10 06:27:49,986: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-> [ TLS handshake complete ]
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-> [ TLS handshake complete ]
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-PR1P264CA0052.outlook.office365.com Hello [<IP_ADDRESS>]\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'250-PR1P264CA0052.outlook.office365.com Hello [<IP_ADDRESS>]\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-SIZE 157286400\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'250-SIZE 157286400\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-PIPELINING\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'250-PIPELINING\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-DSN\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'250-DSN\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-ENHANCEDSTATUSCODES\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'250-ENHANCEDSTATUSCODES\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-AUTH LOGIN XOAUTH2\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'250-AUTH PLAIN LOGIN\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-8BITMIME\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'250-8BITMIME\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-BINARYMIME\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'250-BINARYMIME\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250-CHUNKING\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'250-CHUNKING\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'250 SMTPUTF8\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'250 SMTPUTF8\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) --> b'AUTH LOGIN\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'334 VXNlcm5hbWU6\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) --> b'c3R2YW1haWxlZGlAZ3JvdXBlY2F0LmNvbQ==\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) <-- b'334 UGFzc3dvcmQ6\r\n'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587) --> b'[[ Credentials removed from proxy log ]]'
2023-03-10 06:27:50,001: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     --> b'AUTH XOAUTH2\r\n'
2023-03-10 06:27:50,017: SMTP (localhost:1587; <IP_ADDRESS>:61634->smtp.office365.com:587)     <-- b'334 \r\n'
2023-03-10 06:27:50,017: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993)     <-- b'* OK The Microsoft Exchange IMAP4 service is ready. [UABSADEAUAAyADYANABDAEEAMAAwADkANAAuAEYAUgBBAFAAMgA2ADQALgBQAFIATwBEAC4ATwBVAFQATABPAE8ASwAuAEMATwBNAA==]\r\n'
2023-03-10 06:27:50,017: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993) <-- b'* OK The Microsoft Exchange IMAP4 service is ready. [UABSADEAUAAyADYANABDAEEAMAAwADkANAAuAEYAUgBBAFAAMgA2ADQALgBQAFIATwBEAC4ATwBVAFQATABPAE8ASwAuAEMATwBNAA==]\r\n'
2023-03-10 06:27:50,017: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993) --> b'A0 CAPABILITY\r\n'
2023-03-10 06:27:50,033: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993)     --> b'A0 CAPABILITY\r\n'
2023-03-10 06:27:50,033: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993)     <-- b'* CAPABILITY IMAP4 IMAP4rev1 AUTH=PLAIN AUTH=XOAUTH2 SASL-IR UIDPLUS ID UNSELECT CHILDREN IDLE NAMESPACE LITERAL+\r\n'
2023-03-10 06:27:50,033: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993) <-- b'* CAPABILITY IMAP4 IMAP4rev1 AUTH=PLAIN SASL-IR UIDPLUS ID UNSELECT CHILDREN IDLE NAMESPACE LITERAL+\r\n'
2023-03-10 06:27:50,033: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993)     <-- b'A0 OK CAPABILITY completed.\r\n'
2023-03-10 06:27:50,048: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993) <-- b'A0 OK CAPABILITY completed.\r\n'
2023-03-10 06:27:50,048: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993) --> b'A1 AUTHENTICATE PLAIN\r\n'
2023-03-10 06:27:50,048: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993) <-- b'+ \r\n'
2023-03-10 06:27:50,048: IMAP (localhost:1993; <IP_ADDRESS>:61636->outlook.office365.com:993) --> b'[[ Credentials removed from proxy log ]]'
2023-03-10 06:27:50,095: Authorisation request received for<EMAIL_ADDRESS>(interactive mode)
2023-03-10 06:27:50,126: Authorisation request received for<EMAIL_ADDRESS>(interactive mode)

if i add my working configuration it giving below error in debug logs,
2023-03-10 07:27:20,244: Accepting new connection to IMAP server at localhost:1993 (unsecured) proxying outlook.office365.com:993 (SSL/TLS) via ('<IP_ADDRESS>', 55877)
2023-03-10 07:27:20,251: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) --> [ Client connected ]
2023-03-10 07:27:20,269: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) <-> [ Starting TLS handshake ]
2023-03-10 07:27:20,291: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) <-> [ TLS handshake complete ]
2023-03-10 07:27:20,345: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993)     <-- b'* OK The Microsoft Exchange IMAP4 service is ready. [UABSADEAUAAyADYANABDAEEAMAAwADAAMQAuAEYAUgBBAFAAMgA2ADQALgBQAFIATwBEAC4ATwBVAFQATABPAE8ASwAuAEMATwBNAA==]\r\n'
2023-03-10 07:27:20,346: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) <-- b'* OK The Microsoft Exchange IMAP4 service is ready. [UABSADEAUAAyADYANABDAEEAMAAwADAAMQAuAEYAUgBBAFAAMgA2ADQALgBQAFIATwBEAC4ATwBVAFQATABPAE8ASwAuAEMATwBNAA==]\r\n'
2023-03-10 07:27:20,347: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) --> b'A0 CAPABILITY\r\n'
2023-03-10 07:27:20,348: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993)     --> b'A0 CAPABILITY\r\n'
2023-03-10 07:27:20,354: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993)     <-- b'* CAPABILITY IMAP4 IMAP4rev1 AUTH=PLAIN AUTH=XOAUTH2 SASL-IR UIDPLUS ID UNSELECT CHILDREN IDLE NAMESPACE LITERAL+\r\n'
2023-03-10 07:27:20,355: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) <-- b'* CAPABILITY IMAP4 IMAP4rev1 AUTH=PLAIN SASL-IR UIDPLUS ID UNSELECT CHILDREN IDLE NAMESPACE LITERAL+\r\n'
2023-03-10 07:27:20,356: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993)     <-- b'A0 OK CAPABILITY completed.\r\n'
2023-03-10 07:27:20,356: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) <-- b'A0 OK CAPABILITY completed.\r\n'
2023-03-10 07:27:20,358: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) --> b'A1 AUTHENTICATE PLAIN\r\n'
2023-03-10 07:27:20,358: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) <-- b'+ \r\n'
2023-03-10 07:27:20,359: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) --> b'[[ Credentials removed from proxy log ]]'
2023-03-10 07:27:20,505: Caught exception while requesting OAuth 2.0 credentials for<EMAIL_ADDRESS>URLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:997)'))
2023-03-10 07:27:20,507: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) <-- b'A1 NO AUTHENTICATE Email OAuth 2.0 Proxy: Login failed for account<EMAIL_ADDRESS>- please check your internet connection and retry\r\n'
2023-03-10 07:27:20,508: IMAP (localhost:1993; <IP_ADDRESS>:55877->outlook.office365.com:993) <-- b'* BYE Autologout; authentication failed\r\n'

Having the same/very similar issue. Had this working and then it suddenly refused to authenticate yesterday or the day before. Maybe this is something on Microsoft's end?
Using --external-auth to attempt to authenticate account.
2023-03-10 15:13:25: Caught exception while requesting OAuth 2.0 credentials for [REDACTED]: URLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:997)'))
2023-03-10 15:13:25: IMAP (localhost:1993; <IP_ADDRESS>:52287->outlook.office365.com:993) <-- b'RUBY0001 NO LOGIN Email OAuth 2.0 Proxy: Login failed for account [REDACTED] - please check your internet connection and retry\r\n'
2023-03-10 15:13:25: IMAP (localhost:1993; <IP_ADDRESS>:52287->outlook.office365.com:993) <-- b'* BYE Autologout; authentication failed\r\n'

I having same problem at work running Windows 10.  Booted it up on Linux Mint and got it working.  Is it windows issue?
2023-03-10 16:45:21: New incoming connection to POP server at localhost:1995 (unsecured) proxying outlook.office365.com:995 (SSL/TLS)
2023-03-10 16:45:21: Accepting new connection to POP server at localhost:1995 (unsecured) proxying outlook.office365.com:995 (SSL/TLS) via ('::1', 56057, 0, 0)
2023-03-10 16:45:21: POP (localhost:1995; ::1:56057->outlook.office365.com:995) --> [ Client connected ]
2023-03-10 16:45:21: POP (localhost:1995; ::1:56057->outlook.office365.com:995) <-> [ Starting TLS handshake ]
2023-03-10 16:45:21: POP (localhost:1995; ::1:56057->outlook.office365.com:995) <-> [ TLSv1.2 handshake complete ]
2023-03-10 16:45:21: POP (localhost:1995; ::1:56057->outlook.office365.com:995)     <-- b'+OK The Microsoft Exchange POP3 service is ready. [WQBUADMAUABSADAAMQBDAEEAMAAwADEAMQAuAEMAQQBOAFAAUgBEADAAMQAuAFAAUgBPAEQALgBPAFUAVABMAE8ATwBLAC4AQwBPAE0A]\r\n'
2023-03-10 16:45:21: POP (localhost:1995; ::1:56057->outlook.office365.com:995) <-- b'+OK The Microsoft Exchange POP3 service is ready. [WQBUADMAUABSADAAMQBDAEEAMAAwADEAMQAuAEMAQQBOAFAAUgBEADAAMQAuAFAAUgBPAEQALgBPAFUAVABMAE8ATwBLAC4AQwBPAE0A]\r\n'
2023-03-10 16:45:35: POP (localhost:1995; ::1:56057->outlook.office365.com:995) --> b'USER<EMAIL_ADDRESS>2023-03-10 16:45:35: POP (localhost:1995; ::1:56057->outlook.office365.com:995) <-- b'+OK\r\n'
2023-03-10 16:45:41: POP (localhost:1995; ::1:56057->outlook.office365.com:995) --> b'PASS [[ Credentials removed from proxy log ]]\r\n'
2023-03-10 16:45:41: POP (localhost:1995; ::1:56057->outlook.office365.com:995)     --> b'AUTH XOAUTH2\r\n'
2023-03-10 16:45:41: POP (localhost:1995; ::1:56057->outlook.office365.com:995)     <-- b'+ \r\n'
2023-03-10 16:45:41: Authorisation request received for<EMAIL_ADDRESS>(interactive mode)
2023-03-10 16:48:39: Waiting for URL matching redirect_uri; following browser redirection to login.microsoftonline.com/[...]
2023-03-10 16:48:54: Waiting for URL matching redirect_uri; following browser redirection to login.microsoftonline.com/[...]
2023-03-10 16:48:57: Returning authorisation request result for<EMAIL_ADDRESS>2023-03-10 16:48:58: Caught exception while requesting OAuth 2.0 credentials for<EMAIL_ADDRESS>URLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:1131)'))
2023-03-10 16:48:58: POP (localhost:1995; ::1:56057->outlook.office365.com:995) <-- b'-ERR Authentication failed. Email OAuth 2.0 Proxy: Login failed for account<EMAIL_ADDRESS>- please check your internet connection and retry\r\n'

I had the same issue -- the issue is that DigiCert changed their Root and Intermediate certificate. The fix for me at least (ymmv) is to REMOVE the DigiCert certificates that expired on 3/8/2023 from both the root and intermediate stores and fetch the new ones, however you're fetching based on the OS. I believe with python you can pip the new ones, but it doesn't necessarily delete the old.
Here's the link to DigiCert's page describing their change. This has nothing to do with the OAuthProxy program, but a lot to do with generally how python is checking the certificates and which it's finding. It seems deleting the certificate that expired and ensure the new ones are present seems to be the fix.
p.s. I love the proxy, it's a dream, but if any of you are using it in production, show the man some love and sponsor. =)
https://knowledge.digicert.com/generalinformation/digicert-root-and-intermediate-ca-certificate-updates-2023.html
Cheers.
Basil

how do you delete the certificates and add them back in?
Bruce

Since this is an issue with the environment rather than the proxy, and not one I've experienced myself, I can only suggest the usual python certificate updating approach: python -m pip install --upgrade certifi.

On Windows, you open the cert store of the machine (mmc -> certs> local machine) and delete the expired digicert certificate from 3/8/23 from both the trusted root and intermediate stores, then restart the python program.

Thank you Basil.  I did not pay attention to the Intermediate Certificates.
Bruce

Forwarded the sponsorship page to my boss.
Still getting the same certificate has expired issue. Cleared everything out of MMC certs for trusted root and intermediate stores, also tried running python -m pip install --upgrade certifi last week and today but no luck. Any other suggestions? Running Windows.
2023-03-13 10:41:24: Caught exception while requesting OAuth 2.0 credentials for [REDACTED]: URLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:997)'))
2023-03-13 10:41:24: IMAP (localhost:1993; <IP_ADDRESS>:34987->outlook.office365.com:993) <-- b'RUBY0001 NO LOGIN Email OAuth 2.0 Proxy: Login failed for account [REDACTED] - please check your internet connection and retry\r\n'
2023-03-13 10:41:24: IMAP (localhost:1993; <IP_ADDRESS>:34987->outlook.office365.com:993) <-- b'* BYE Autologout; authentication failed\r\n'
Thank you,

Thanks for following up – I'm glad you were able to resolve this. I'll leave this issue open for a while in case others run into this.
To summarise: the issue occurs when running the proxy on Windows, and is due to updated DigiCert root and intermediate certificates. When attempting to authenticate, the expired certificate causes the proxy to produce an error message similar to: Caught exception while requesting OAuth 2.0 credentials for<EMAIL_ADDRESS>URLError(SSLCertVerificationError(1, '[SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed: certificate has expired (_ssl.c:997)'))
To resolve, go to Control Panel->Internet Options->Content->Certificates->Intermediate Certification Authorities and remove the DigiCert certificates that expired on 8th March 2023 (from both trusted root and intermediate stores)


Update WindowsBuild.md

Corrections and improvements to the documentation to build on Windows.  This includes:

switching to cl for the swift build
setting up the paths correctly
correcting the instructions for XCTest builds
setup to ensure that XCTest can be tested in the future
fixes to actually get the swift tests to run on Windows
removal of unnecessary arguments to libdispatch build

Replace this paragraph with a description of your changes and rationale. Provide links to external references/discussions if appropriate.

Resolves SR-NNNN.

@swift-ci please smoke test


Need help with the test 14.

Hi im trying to check the 14th test: The program uses the environment list. Can you help me with that? Thanks.

Hi @anderamo,
unfortunately, I can't help you much without any further details. You can write the logs presents in the outs folder (outs/test-14*.txt). Explain your problem and give as much details as you can. As every programmer will respond this to you, I am forced to do so: see https://dontasktoask.com. 😉
Moreover, this is not the right place to ask that kind of questions. Here, you can share some bug you found, a documentation mistake, a test that would fit in the tester, etc... But for help about your project, you should ask me on Slack or eventually Discord (if you are from Paris campus, you can easily find me). You can even ask in a general channel, some nice guy will help you for sure.
I am then waiting you in private messages on Slack for you to give me more informations to help you properly. See you soon !


[Backlog] Fix Deprecation Warnings

Task for some point: fix the deprecation warnings when running.
torchquantum/torchquantum/plugin/qiskit/qiskit_pulse.py:29: DeprecationWarning: The module 'qiskit.test.mock' is deprecated since Qiskit Terra 0.21.0, and will be removed 3 months or more later. Instead, you should import the desired object directly 'qiskit.providers.fake_provider'.
    from qiskit.test.mock import FakeQuito, FakeArmonk, FakeBogota

Adding to this, we should eventually migrate from opflow: https://qiskit.org/documentation/migration_guides/opflow_migration.html


SearchBar - tap event not working on Android

Hi,
I tried to implement a simple tap event on a SearchBar as follow:
XML
<SearchBar #sb hint="Search" (loaded)="onSearchBarLoaded($event)" (clear)="onClear()" (submit)="onSubmit(sb.text)" (tap)="toggle()"></SearchBar>

Component
import { Component, ElementRef, ViewChild } from '@angular/core';
import {
    trigger,
    state,
    style,
    animate,
    transition
} from '@angular/animations';
import { Page } from "ui/page";
import { topmost } from "ui/frame";
import { Color } from "color";
import { isIOS } from "platform";
import { RouterExtensions } from "nativescript-angular/router";

@Component({
    moduleId: module.id,
    templateUrl: 'messages.component.html',
    styleUrls: ['./messages.component.css'],
    animations: [
        trigger(
            'hidden', [
                transition(':enter', [
                    style({ transform: 'translateY(-100%)' }),
                    animate('700ms', style({ transform: 'translateY(0)' }))
                ]),
                transition(':leave', [
                    style({ transform: 'translateY(0)' }),
                    animate('700ms', style({ transform: 'translateY(-100%)' }))
                ])
            ]
        )
    ]
})

export class MessagesComponent {
    @ViewChild('sb') searchBar: ElementRef
    public focused: boolean;
    .
    .
    .
    .

    toggle() {
        if (!this.focused) {
            this.focused = !this.focused;
       }
   }

It works well on iOS but on Android I have to click on the "border" of the SearchBar for the tap event to be fired. I also tried to surround the SearchBar with a StackLayout but it doesn't work neither.
I also checked the core ui code to see if there is a "Focus" event property or an implementable event to trigger when the keyboard is open but I didn't find those.
I need to be able to trigger the tap event because I show a custom DropDown containing filters when the user is searching something on this page. For now I use a simple TextField on Android and it works. But having the SearchBar on Android would be great!

I don't know if you can get the actual native SearchView element on angular, but you could do something like this:
nativeSearchElement
.setOnQueryTextFocusChangeListener(new android.view.View.OnFocusChangeListener({
            onFocusChange:  function(view, hasfocus) {
                console.log('Search focus: ', view, hasfocus);
        }}));

As @tsonevn said on #746 you can use the loaded event to track the searchBar initialization code.


An error

Hi,
I am trying to make my own motorRecords by modifying db and found examples under tests.
My softioc is pip installed, and it produces the error below:
pythonSoftIOC/tests] python sim_asyncio_ioc_override.py myprefix
Traceback (most recent call last):
File "sim_asyncio_ioc_override.py", line 36, in
softioc.iocInit(asyncio_dispatcher.AsyncioDispatcher(event_loop))
TypeError: init() takes 1 positional argument but 2 were given

Hi Byeongdulee. I think your problem is here:

asyncio_dispatcher.AsyncioDispatcher(event_loop)

AsyncioDispatcher doesn't accept any arguments. It certainly doesn't want to take an input event loop, as it creates one itself. If you want you can use that created dispatcher's loop for further asyncio processing, something like this:
dispatcher = asyncio_dispatcher.AsyncioDispatcher()
asyncio.run_coroutine_threadsafe(my_method(), dispatcher.loop)

softioc.iocInit(asyncio_dispatcher.AsyncioDispatcher(event_loop))

These changes were added in master, but were not released. I will make a release later today and comment on here.

make my own motorRecords

This will not work at the moment, as pythonSoftIOC does not build in support for the motor record. There are two things that would need to be done to make that work:

Sort out generic packaging of epics modules as per #6
Write Python device support for the motor record

Unfortunately we don't have the time to do either of those at present
Can I ask what is your use case for making an IOC with python device support for a motor record?

Thank you Alexander and Tom.
I have been working with a PI piezo stage. The PI has updated its firmware, but the epics driver is not yet as far as I know. Hope to use the DIO of the controller programmatically, for example to send or receive a detector trigger. It could be done in other ways, but since PI's python support is available, I thought pythonsoftioc would be ideal if possible.
Another example is to make a simple IOC for the UR robot.

If you avoid the motor record, then you could do this with pythonSoftIOC. If you need the motor record I'm afraid it won't be suitable at the moment


Shipping address not coming back

The billing adress returns, but the shipping address does not... I think I have it configured right?
v ^1.8.0
 <ReactStripeCheckout
                stripeKey='bobloblaw'
                token={this.onToken}

                name="Foo Inc."
                componentClass="div"
                panelLabel = "Purchase a Gadget"
                amount={100}
                currency="USD"
                shippingAddress={true}
                allowRememberMe={true}
                />

My bad, it's in the second parameter to the token callback as the documentation states. When all else fails... read the docs... LOL!  Nice widget BTW.


http://registratie.fkgent.be/backend/fk has too many redirects

Started GET "/backend/fk" for <IP_ADDRESS> at 2015-07-29 22:58:54 +0200
Processing by Backend::FkController#index as HTML
Redirected to http://registratie.fkgent.be/cas/auth?redirect=%2Fbackend%2Ffk
Filter chain halted as :verify_fk rendered or redirected
Completed 302 Found in 6ms (ActiveRecord: 1.0ms)
Started GET "/cas/auth?redirect=%2Fbackend%2Ffk" for <IP_ADDRESS> at 2015-07-29 22:58:54 +0200
Processing by Frontend::CasController#auth as HTML
  Parameters: {"redirect"=>"/backend/fk"}
Redirected to http://registratie.fkgent.be/cas/verify
Completed 302 Found in 6ms (ActiveRecord: 0.9ms)
Started GET "/cas/verify" for <IP_ADDRESS> at 2015-07-29 22:58:55 +0200
Processing by Frontend::CasController#verify as HTML
Redirected to http://registratie.fkgent.be/backend/fk
Completed 302 Found in 7ms (ActiveRecord: 1.2ms)
Started GET "/backend/fk" for <IP_ADDRESS> at 2015-07-29 22:58:55 +0200
Processing by Backend::FkController#index as HTML
Redirected to http://registratie.fkgent.be/cas/auth?redirect=%2Fbackend%2Ffk
Filter chain halted as :verify_fk rendered or redirected
Completed 302 Found in 7ms (ActiveRecord: 1.1ms)
Started GET "/cas/auth?redirect=%2Fbackend%2Ffk" for <IP_ADDRESS> at 2015-07-29 22:58:55 +0200
Processing by Frontend::CasController#auth as HTML
  Parameters: {"redirect"=>"/backend/fk"}


Revert "Refactor ziplist to pass when arg_1 = 1."

Reverts crimsobot/crimsoBOT#121. We've had our fun.

It worked, but perhaps too well.


Error: rpc error: code = Unavailable desc = transport is closing

Strange - keep getting this error:
null_resource.sql_init[0]: Still creating... [10s elapsed]
null_resource.sql_init[0] (local-exec): -1
azurerm_cosmosdb_sql_container.metadata: Still creating... [40s elapsed]
null_resource.sql_init[0]: Still creating... [20s elapsed]
null_resource.sql_init[0] (local-exec): -1
null_resource.sql_init[0]: Creation complete after 23s [id=7882090812782899888]
azurerm_cosmosdb_sql_container.metadata: Still creating... [50s elapsed]
azurerm_cosmosdb_sql_container.metadata: Still creating... [1m0s elapsed]
azurerm_cosmosdb_sql_container.metadata: Creation complete after 1m3s [id=/subscriptions/b970f71b-bc04-47c8-89cd-7e491b4656b2/resourceGroups/rgcdedlplay02/providers/Microsoft.DocumentDB/databaseAccounts/cmdbcdedlplay02/sqlDatabases/metadatadb/containers/metadata]

Error: rpc error: code = Unavailable desc = transport is closing

Error: rpc error: code = Unavailable desc = transport is closing

Error: rpc error: code = Unavailable desc = transport is closing

Error: rpc error: code = Unavailable desc = transport is closing

Probably related to https://github.com/databrickslabs/terraform-provider-databricks/issues/223

Will be fixed with #176 (expected in the next few days)


Add additional checking for Azure Functions restrictions in Static Web Apps

Currently, there are some restrictions for Static Web Apps functions that are beyond those of regular function apps.

Core Tools should be the latest v3 version
Only Node 12, .NET 3.1, and Python 3.8 are supported
Only HTTP triggers are supported
Only valid routePrefix in host.json is api
It's not good practice to nest the API folder inside the web app. Not sure if we want to have a warning here. There's potential for exposing the API code if it's deployed as static files too, and npm modules in the function app can cause the static app to exceed the 4000 file limit

Internal tracking link: https://dev.azure.com/azuretracking/Azure tracking/_workitems/edit/1678

This issue has become stale and is at risk of being closed. The community has 60 days to upvote the issue. If it receives 5 upvotes we will keep it open and take another look. If not, we will close it. To learn more about how we handle issues, please see our documentation.
Happy Coding!


Incorrect Initial URL Retrieval

When prompted for a particular list of links to be included in HowDoI's current response regarding various companies, the first link was wrong (and also did not exist, although a different domain suffix of the incorrect URL existed somewhere on the internet).
When told that it was incorrect and asked to fix the first link, it provided the correct link.
When asked why it had done the error, the response was that it had "misread" the website, as it had looked for a site that "started with the letter [a] and ended with [letter b].com".

Hmm... that seems like a pretty complex query - not sure the LLM model can handle it. Can you share what the exact where was/

Sure, Here is the entire conversation for this particular instance. (might be a bit blurred haha)

Also: potentially relevant? (see below)
Cant be bothered to make a myriad of issue posts. I assume all this is still very much so a work in progress. Cool stuff tho!


FUIAuthDelegate callback not called for Facebook login in iOS 13

Step 1: Are you in the right place?
yes
Step 2: Describe your environment

Swift
iOS version: 13
Firebase SDK version: 6.3.1
FirebaseUI version: 8.2.0
CocoaPods Version: 1.6.2

Step 3: Describe the problem:
Launching Facebook auth from root view controller (this seemed to be an issue with others). Facebook authenticates but callback is never triggered.
Steps to reproduce:
See sample ccode
Observed Results:
Callback not triggered
Relevant Code:
class AuthViewController: UIViewController, FUIAuthDelegate {

  override func viewDidLoad() {
      super.viewDidLoad()
      self.view.backgroundColor = .white
      let authUI = FUIAuth.defaultAuthUI()
      authUI?.delegate = self;
  }

  override func viewDidAppear(_ animated: Bool) {
      super.viewDidAppear(animated)

      let vc = AuthHelper.shared.authUI.authViewController()
      vc.modalPresentationStyle = .overFullScreen
      self.present(vc, animated: true, completion: nil)
  }

  func authUI(_ authUI: FUIAuth, didSignInWith authDataResult: AuthDataResult?, error: Error?) {
      if (error != nil) {
          let vc = AuthHelper.shared.authUI.authViewController()
          vc.modalPresentationStyle = .overFullScreen
          self.present(vc, animated: true, completion: nil)
      } else {
          FlowControl.gotoMainApp(loggedIn: true)
      }
  }

  func authPickerViewController(forAuthUI authUI: FUIAuth) -> FUIAuthPickerViewController {
      return FUICustomAuthPickerViewController(nibName: "FUICustomAuthPickerViewController",
                                               bundle: Bundle.main,
                                               authUI: authUI)
  }

}

You can create a sample project and just instantiate this VC as follows to reproduce:
guard let appDelegate = UIApplication.shared.delegate as? AppDelegate else { return } appDelegate.window!.rootViewController = AuthViewController()

Looks like the callback changed at some point. Was missing this:
func authUI(_ authUI: FUIAuth, didSignInWith user: User?, error: Error?) {...}


Remove duplication in runner.js

The system.* functions all get mapped to variables of the same name, and then get returned from the exported function in an object with the keys being the same names. Could the system module just be returned directly from the function? It just seems like a lot of duplication.

I'd say put together a PR. We can review it then and see. If it makes things smaller and neater we are all for it.

#27 should work.

@mcdonnelldean you happy with @epicsharp PR?
From my POV,  duplication isn't always bad if it affords clarity
Also prior to just this month, the PR could not have been merged as is, without dropping support for 0.10, 0.12 - now we can do that because support has been dropped at the org level

Hey Guys, going to close this as runner has been re-implemented.


Refactor the failure messages of planner

What this PR does / why we need it:
Which issue(s) this PR fixes:
Fixes #
Does this PR introduce a user-facing change?:

NONE

/approve


Move all Bento Blocks into their own groups and make sure they have icons

An image speaks a thousand words:

...and the wrong PR target speaks some words too


Fix shairport-sync after migration from pulseaudio to alsa

Tested on a freshly installed Raspberry Pi OS (bullseye).

OK. I see my error now. Your general assumption is, that install.sh is executed in ANY case which would result in the pulse-access group being present.


BUG Fix GridFieldAddExistingAutocompleter

This fix exchanges references to sub-components by ID with class references
Fixes #5382
Probably best reviewed with '?w=1' to remove whitespaces from diff.
CC @HARVS1789UK  for review. Can you please confirm this fixes your issue?

I'll fix these tests.

4.x version at https://github.com/silverstripe/silverstripe-framework/pull/5437

The 4.x version is fixed. Anyone care to merge this into 3.3? It's too late fro 3.3.2 unfortunately.

Tested this locally and verified that it fixes #5382. Nice work @tractorcow

Thanks @tractorcow - Sorry I didn't have time to test it myself for you before it got merged, I will be pulling down the changes as soon as I get back to this personal project. Thank you for the fix!


runtime(vim): correctly handle ! attribute for augroup/doautocmd/doautoall

I noticed that
:autocmd! FooBar
:augroup! FooBar

looks slightly different to how the ! is drawn. While the ! for the autocmd case is shown in the same color as autocmd, for :augroup is is shown as VimEventList
In addition, the vim syntax seems to accept doautocmd! and doautoall! (with bang attribute) even so this is not valid.
So let's fix all of those and mark the ! as an error for the the :doautocmd/doautoall case.
cc @dkearns

do you want to take over this one then? Or shall I squash your patch on top of mine and go ahead merging?


how to do evaluation on the pascal server

This is not a issue for your project. Recently, I upload the result.tgz to the pascal server. However, there is no response and submission results.
Do you know the reason?

Did you fill in all the fields when submitting? In my experience, leaving some field empty results in the behaviour that you have encountered

@gaopeng-eugene this could also happen when the format of your segmentation masks is not what the server is expecting. I faced something similar, when I tried to use the code to put colour palette on the segmentation masks from this repository. The server took 30 minutes and then exited with a weird error without providing any description. I later figured out that my format (colour palette) of segmentation mask is causing the problem, so I used my own code. Try using the following script and see if it helps.

Hello,
I know this place s not the proper for this question, sorry for that.
I try to evaluate my results on Pascal VOC Evaluation servers but I got an error and not enough definition.
I convert my segmentation output array(WxH) to three depth array(WxHx3) for saving as a png image.
I ve used to make_palette function to get the correct RGB value. also, there is also the same function in VOC DEVKIT.
For example, Person RGB value is [W,H,x] = [192,128,128]
Do you have any idea about that?
Thanks in advance...

your upload image should be in 0~20, don't need colormap

Thank you for your interest. @dongzhuoyao
I mean, My output is a 2D array(WxH) for only person segmentation so it includes 0(background) and 1 for(person.)
as I know, I have to convert these 2D arrays to image(WxHx3). I multiply the first layer with 192, the second layer with 128, the third layer with 128.
Because I reviewed the sample result file from Pascal Voc site. I see segmentation results are PNGs and have different colors.
Am I wrong?
Also, I have changed [192,128,128] to [15,15,15] namely I have multiple all pixel with 15. Its almost the black.
but i got same error. :-(
Same Error: Error while evaluating challenge 6. Results were not generated properly.
Error while submission. No scores were generated.
Its almost black, any idea? thank you so much btw


Running opvault 0.4.9 pex leads to infinite recursion in setup tools

Operating system macOS 11.2.3
Python 3.8.2 (installed via pyenv)
Pex 2.1.38.
To reproduce in a clean environment:
pex opvault=="0.4.9" -o opvault.pex
<snip>
Saving PEX file to opvault.pex
pex: Zipping PEX file.: 1471.6ms
pex --disable-cache opvault=="0.4.9" -e opvault-cli -vvv -o opvault.pex  14.98s user 5.21s system 158% cpu 12.734 total

Running it results in:
./opvault.pex
Traceback (most recent call last):
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/pex.py", line 482, in execute
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/pex.py", line 138, in activate
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/pex.py", line 125, in _activate
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/environment.py", line 428, in activate
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/environment.py", line 784, in _activate
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/environment.py", line 608, in resolve
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/environment.py", line 635, in resolve_dists
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/environment.py", line 505, in _resolve_requirement
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/environment.py", line 505, in _resolve_requirement
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/environment.py", line 505, in _resolve_requirement
  [Previous line repeated 955 more times]
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/environment.py", line 484, in _resolve_requirement
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/dist_metadata.py", line 258, in requires_dists
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/__init__.py", line 3180, in parse
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/__init__.py", line 3126, in parse_requirements
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/__init__.py", line 3133, in __init__
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/packaging/requirements.py", line 106, in __init__
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1644, in parseString
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1402, in _parseNoCache
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 3417, in parseImpl
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1402, in _parseNoCache
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 3552, in parseImpl
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1402, in _parseNoCache
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 3400, in parseImpl
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1402, in _parseNoCache
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 3417, in parseImpl
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1402, in _parseNoCache
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 4005, in parseImpl
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1402, in _parseNoCache
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 3552, in parseImpl
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1402, in _parseNoCache
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 3739, in parseImpl
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1402, in _parseNoCache
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 3400, in parseImpl
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1402, in _parseNoCache
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 3471, in parseImpl
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1443, in tryParse
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 1402, in _parseNoCache
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/vendor/_vendored/setuptools/pkg_resources/_vendor/pyparsing.py", line 2816, in parseImpl
RecursionError: maximum recursion depth exceeded

If I install the same package via pip:
 pip install opvault==0.4.9
Collecting opvault==0.4.9
  Using cached opvault-0.4.9-py2.py3-none-any.whl (21 kB)
Requirement already satisfied: pycryptodome==3.9.7 in /Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/site-packages (from opvault==0.4.9) (3.9.7)
Requirement already satisfied: requests==2.24.0 in /Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/site-packages (from opvault==0.4.9) (2.24.0)
Requirement already satisfied: shellescape==3.8.1 in /Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/site-packages (from opvault==0.4.9) (3.8.1)
Requirement already satisfied: certifi==2020.6.20 in /Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/site-packages (from opvault==0.4.9) (2020.6.20)
Requirement already satisfied: PyYAML==5.3.1 in /Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/site-packages (from opvault==0.4.9) (5.3.1)
Requirement already satisfied: Naked==0.1.31 in /Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/site-packages (from opvault==0.4.9) (0.1.31)
Requirement already satisfied: chardet==3.0.4 in /Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/site-packages (from opvault==0.4.9) (3.0.4)
Requirement already satisfied: urllib3==1.25.9 in /Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/site-packages (from opvault==0.4.9) (1.25.9)
Requirement already satisfied: idna==2.9 in /Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/site-packages (from opvault==0.4.9) (2.9)
Installing collected packages: opvault
Successfully installed opvault-0.4.9

I can run it successfully:
 opvault-cli
Usage: /Users/zmanji/.pyenv/versions/3.8.2/bin/opvault-cli <path_to_opvault> <item_title>

Update, it seems this is related to specifying an incorrect entrypoint as I intended to do -c opvault-cli intead of -e opvault-cli.
If I run the same original command with an older pex (2.1.21) when I run the built pex I see:
Traceback (most recent call last):
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/pex.py", line 446, in execute
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/pex.py", line 378, in _wrap_coverage
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/pex.py", line 409, in _wrap_profiling
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/pex.py", line 508, in _execute
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/pex.py", line 610, in execute_entry
  File "/Users/zmanji/bin/opvault.pex/.bootstrap/pex/pex.py", line 618, in execute_module
  File "/Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/runpy.py", line 202, in run_module
    mod_name, mod_spec, code = _get_module_details(mod_name)
  File "/Users/zmanji/.pyenv/versions/3.8.2/lib/python3.8/runpy.py", line 137, in _get_module_details
    raise error("No module named %s" % mod_name)
ImportError: No module named opvault-cli

I would say this is a minor regression.

Update:
This is a regression between 2.1.24 and 2.1.25.
If I build the pex with 2.1.24 it works fine, but with 2.1.25 I get this error.

My reading of changed commits between the two releases seems like it is related to the code introduced in 5a8c50f5ad5a057a43f4e879de078ee1f5c01ffa.

Beautiful. Naked 0.1.31 depends on ... Naked: https://github.com/chrissimpkins/naked/issues/19
Of course Pex should be robust against this.

Thanks for running this down @zmanji. The fix will be released here shortly in 2.1.39.


[BUG] utils.reverse_video_file causes excessive RAM usage

Description
EDIT: This issue actually comes from reverse_video_file. See below.
I'm aware this is likely an av bug, but I'm filling it here because others might encounter it.
It seems manim-slides' concatenate_video_files eats up too much RAM (it crashes my 16GB laptop) and can cause severe OS crashes. I've tried to fix this bug on my end by monkey-patching it to use manimCE's equivalent of concatenate_video_files like so:
import manim_slides
from manim_slides.logger import logger

# Yet another bad idea... but it works **shrug**
def _concatenate_video_files(files: list[Path], dest: Path) -> None:
    logger.warn("Warning: Using monkey-patched `concatenate_video_files`")
    renderer = CairoRenderer()
    writer = SceneFileWriter(renderer, "NotARealScene")
    writer.combine_files(files, dest)
manim_slides.slide.base.concatenate_video_files = _concatenate_video_files

The above works fine most of the time (which raises the question: why does manim-slides have its own version of combine files then?), but also causes OOMs just like the original version.
A long-term fix would be great, but I understand this might be out of scope. In the meanwhile, I'm trying to render out my slides in HQ because I've a presentation coming up in a few days, and, while they render fine with -ql (which I was using to prototype the slides), I can't seem to render them in HQ. Any temporary fixes I could do?
Version
Latest at time of writing (manim-slides, version 5.1.7)
Platform
Linux, Fedora 40
Screenshots
No response
Additional information
No response

Hello @jungerm2, thank you for reporting this bug!
I highly suspect that your bug is caused by a previous fix I deployed to avoid concatenating empty video files. This was needed prior to Manim v18.1 (fixed by https://github.com/ManimCommunity/manim/pull/3491) because Manim could produce empty video files.
This fix is in def _filter:
https://github.com/jeertmans/manim-slides/blob/b08073983b8ac8b871c34c2a422c150e097e3be1/manim_slides/utils.py#L12-L62
Can you try monkey-patching this function by replacing the _filter function with:
_filter = lambda files: files

I suspect that the context manager does not correctly close the files, and this might explain why we have an increase in memory.

I thought this might have been an ffmpeg bug at first, so I updated from 5.11 to latest and the problem persists. There's some similar bugs that have been reported in the concat muxer, but I don't know if they are related, i.e: https://trac.ffmpeg.org/ticket/10550
I'll try your above suggestion, but since I've monkey-patched concatenate_video_files to use manim's version, and it still doesn't work, I do not think this is the issue. I'm starting to think it's the reverse_video_file function that causes issues and that I had misdiagnosed this. FFmpeg is notorious for large memory consumption during reversal: https://trac.ffmpeg.org/ticket/9073
Thanks for the quick reply and I'll keep you updated.

Ok then reversing indeed requires to load the whole video into memory, which then can be an issue for large videos and I am afraid there is not real solutions.
Some people have suggested to reverse a video by splitting it into parts and then concatenate them.
Can you share a minimal example when memory is an issue?

Seems like the recommended way to reverse large videos is to split it into chunks, reverse those and concat back (here, and here). This should be pretty straightforward to implement -- we're only missing the split part.
To avoid dealing with ffmpeg, or pyAV, I used moviepy to reverse the video (as I have a deadline coming up!) as it reverses the video by extracting one frame at a time thus not loading everything into memory. It is also much slower because of this:
def _reverse_video_file(src: Path, dest: Path) -> None:
    from moviepy.editor import VideoFileClip, vfx
    clip = VideoFileClip(str(src)).fx(vfx.time_mirror)
    clip.write_videofile(str(dest))

if literal_eval(os.environ.get("SKIP_REVERSE", "False")):
    logger.warn("Warning: Skipping video reversal because the `SKIP_REVERSE` environment variable was set.")
    manim_slides.slide.base.reverse_video_file = shutil.copy2
else:
    manim_slides.slide.base.reverse_video_file = _reverse_video_file

And finally, this works as intended!
For reference, the video I'm reversing is only about 5mb when encoded, but it's 4k60, and is relatively simple so it compresses very well, so I suspect its full decoded size is very large. Reversing it with the above takes ~1 hour though...
This is not a viable solution long-term, and a more efficient reversal method will be needed. But for now, it means I can do my presentation.
I think adding a cli flag to skip reverse video generation might be a good idea too. It's not a feature I've ever used (the V in the GUI), and it's likely not needed during prototyping, although maybe it complicates other things such as exports...

Looks like you answered while I was writing a reply...
Here's a minimal example that breaks on my system:

Step 1: Go download some test video file, i.e form here: https://download.blender.org/peach/bigbuckbunny_movies/
Step 2: Reverse it:

from manim_slides.utils import reverse_video_file
reverse_video_file("big_buck_bunny_720p_h264.mov", "assets/big_buck_bunny_720p_h264_reversed.mov")

On my system, the 720p version is more than enough to cause havoc.

Sure, here's a simple one (which you might recongnize):
from manim import *  # or: from manimlib import *

from manim_slides import Slide

class BasicExample(Slide):
    def construct(self):
        circle = Circle(radius=3, color=BLUE)
        dot = Dot()

        self.play(GrowFromCenter(circle))
        self.next_slide()  # Waits user to press continue to go to the next slide

        self.next_slide(loop=True)  # Start loop
        for _ in range(100):
            self.play(MoveAlongPath(dot, circle), run_time=2, rate_func=linear)
        self.next_slide()  # This will start a new non-looping slide

        self.play(dot.animate.move_to(ORIGIN))

Rendering with default settings (i.e: manim example.py) uses huge amounts of memory.

The above can probably be addressed easily by reversing individual animations (or partial-movie-files) and then concatenating them together, this could be done in this loop:
https://github.com/jeertmans/manim-slides/blob/b08073983b8ac8b871c34c2a422c150e097e3be1/manim_slides/slide/base.py#L476-L495
But here's another MWE that causes issues on my machine, when running with -qh or equivalently if the runtime is longer, which would not be fixed by the above:
from manim import *  # or: from manimlib import *
from manim_slides import Slide

class BasicExample(Slide):
    def construct(self):
        circle = Circle(radius=3, color=BLUE)
        dot = Dot()

        self.play(GrowFromCenter(circle))
        self.next_slide()  # Waits user to press continue to go to the next slide

        self.next_slide(loop=True)  # Start loop
        self.play(MoveAlongPath(dot, circle), run_time=30, rate_func=linear)
        self.next_slide()  # This will start a new non-looping slide

        self.play(dot.animate.move_to(ORIGIN))

I don't think it's unrealistic to render 30 second animations in high quality.
I see two solutions:

Implement a split, reverse & concat method (short-term)
Hook into (or submit a PR) manim's rendering pipeline so that is directly saves forward and backwards videos. There's already a --save_sections flag for manimCE which we could use such that manim takes care of concatenating animations instead of re-implementing it here.

I see, this is a non-trivial problem because it happens for both: many animations and one very long animations. I actually had the same issue before in presentations.
Regarding your 2nd solution, I am afraid that submitting a PR to Manim is not a good solution, because they do even use reversed animations, so why would they accept that?
I could "easily" implement a mix of both "reversing individual partial movies files and them concatenating the reversed list", and, in reverse_video_file, split the video if it is too large and concatenate it back. I could even leverage parallel threads for that.
The only question I still have is "when" to split (what criterion?) and "how" (I know there is a split filter, but I have never used it).

See #439


Update sprint-171-update.md

grammar

@savaticus : Thanks for your contribution! The author(s) have been notified to review your proposed change.

@savaticus Looks good, thanks.


Looks like it will require a change of "as"es to "as!" for Swift 1.2...

I put a "!" at the end of all of SwiftyJSON's "as" downcasts and it seems to work under the new requirements of Swift 1.2.

This issue has been addressed, look at issue #148 and branch xcode6.3


Fix return value when structure

Return value must be between brackets in NodeJS if a structure is returned. Otheewise it returns {}

Cannot at brackets. Workflow removes them

Cannot at brackets. Workflow removes them


wlroots rotation exits after hot-unplugging

I tested hotplugging the VGA-1 output on my Intel HD 3000.
Plugging it in while ./build/examples/rotation is running is detected, and the display is used.
Unplugging it shuts down the application after a few seconds. Here is a log of plugging the display in and unplugging.
It does not make a difference, whether the display was plugged in when starting rotation, or got plugged in while rotation is running.

It's probably crashing. There was an issue with a possible null pointer dereference that can happen when a monitor is unplugged and was fixed in fe2fbd0fad96624ab64a86b0b8eb8ead769908f2.
Can you test master now and see if it fixes it for you?

Looks good to me. I can unplug while it is running now.
Bot hotplug and hotunplug now work. Repeated and when monitor is plugged in when started and when it's unplugged.


Add dynamicTypeRamp documentation

Documentation for this PR: https://github.com/facebook/react-native/pull/35017

LGTM. It looks like there are some linting errors for the Markdown table (see the failing CircleCI job). You should be able to either resolve them manually, or by running yarn format:markdown from the website directory.


Enforce code quality by intentionally killing gulp on error

This PR is related to issue #255, it will intentionally kill gulp and prevent development until issues have been fixed.

You do realize that jshint has a reporter('fail') you can pipe to, right? That instantly fails the build when lint fails.

Nice PR, but apparently Travis didn't like it as much, could someone please investigate why is that?
Apparently the map stream is causing it.
map stream is not writable at agar.io-clone/node_modules/map-stream/index.js:90

@IgorAntun This whole PR can be summarized by adding one line. (pipe to reporter(fail)). I'll prepare a comparable PR.

Okay, I'm gonna merge #257 and close this one then.
Thanks to you both @JuhQ @MadaraUchiha for helping :)

Well done @MadaraUchiha :) :+1:


Depreciated call to async_setup_platforms() in init.py

Logger: homeassistant.helpers.frame
Source: helpers/frame.py:77
First occurred: May 7, 2023 at 11:12:14 PM (1 occurrences)
Last logged: May 7, 2023 at 11:12:14 PM
Detected integration that called async_setup_platforms instead of awaiting async_forward_entry_setups; this will fail in version 2023.3. Please report issue to the custom integration author for frigidaire using this method at custom_components/frigidaire/init.py, line 32: hass.config_entries.async_setup_platforms(entry, PLATFORMS)

Please follow the steps in #29


Shortcuts for commands are not enabled on startup

With default settings (i.e. no RTVS tool windows visible), when VS starts, none of the shortcuts are active:

Shortcuts become enabled once one of RTVS tool windows, or the editor, is active:

However, it means that on first launch, there's no way to quickly open the REPL via keyboard. You have to mouse through R Tools | Windows.

Technically design since we don't bind shortcuts in global.

Partial fix: bind Ctrl+2 to global so REPL is accessible


Network : The native filter box is moved to the left

STR:

Open Firebug
Open the Network panel using the Firebug.next theme
Switch to the light theme
Go back to the Network panel

Actual Result:
The native filter box has been moved to the left

Expected Result:
It should be at the bottom-right as it is without Firebug:

@janodvarko I propose a fix with the commit above + a question here:
https://github.com/firebug/firebug.next/commit/02b9dce9abf1a17c0618e68ba3fbbaedd43910a0#diff-14c22f0115d7dedea42a63de4f4cf7d9R149
Florent

I propose a fix with the commit above + a question here:

Great, works for me.
And yes, using CSS is better.
Thanks!
Honza

Merged. Thanks for the review Honza.
Florent


docs: dependencies

:tada: This PR is included in version 0.116.10 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


Implemented the JsonRpc protocol with actix-web

Problem

Implementation of issue #9

Summary of Changes
Implemented

JsonRpc
ErrorHandling
Basic SendTransaction
ActixWeb

Todo

Followup issue for implementing retry logic for sendTransaction #12

Could you resolve conflicts. Why use actix-web. why not use the preexisting package in solana jsonrpc-http-server

Could you resolve conflicts. Why use actix-web. why not use the preexisting package in solana jsonrpc-http-server

I can have a look at the conflicts and try to merge them

@aniketfuryrocks could you please solve the merge conflicts?

@godmodegalactus Resolved all comments and issues. No more merge conflicts :)


Conceptual Question on Video Bottleneck Models

Hi @dutran et al,
I was wondering, is not including the block expansion in spatio-temporal convolution by design?
Specifically, let's say VideoModelBuilder makes a model where layer_2 has 2 bottleneck layers (for illustration purposes). Then the graph from VMZ looks like
Bottleneck1:
  3D conv (in: 64, 1,1,1, out: 64)
  2+1D conv (
    in: 64, 1,3,3, out: 144
    in 144, 3, 1, 1, out: 64
  )
  3D conv (in: 64, 1,1,1, out: 64*4)
Bottleneck2:
  3D conv (in: 64*4, 1,1,1, out: 64)
  2+1D conv (
      in: 64, 1,3,3, out: 144
      in 144, 3, 1, 1, out: 64
  )
  3D conv (in: 64, 1,1,1, out: 64*4)

When according to the block formula for the second bottlenect, one would expect to have the middle layer expanded as well, i.e.
Bottleneck1:
  3D conv (in: 64, 1,1,1, out: 64)
  2+1D conv (
    in: 64, 1,3,3, out: 144
    in 144, 3, 1, 1, out: 64
  )
  3D conv (in: 64, 1,1,1, out: 64*4)
Bottleneck2:
  3D conv (in: 64*4, 1,1,1, out: 64)
  2+1D conv (
      in: 64, 1,3,3, out: 177
      in 177, 3, 1, 1, out: 64
  )
  3D conv (in: 64, 1,1,1, out: 64*4)

Note that the difference is the separated conv layer - specifically midplanes computation.
In the original paper, it specifies the midplanes formula but it's ambiguous wether N_i refers to block or layers
Just as a side note, I found that models with block expansion accounted for get approx. 0.9% better results on Kinetics with R2+5D50, but the setup was different than specified in paper so it's not really apple-to-apple comparison.
Cheers,
Bruno

Note that this is the design from ResNet [He at al. CVPR'16] where 1x1 filters are about 4x more than the middle layer 3x3, that's why it is name bottleneck.

Looking at the official implementation [1], I don't think that's correct, specifically, it looks like the naive bottleneck looks like the following
1x1x1, in_dim, n
3x3x3, n, n
1x1x1, n, 4*n

If you look at the output of that code (omitting BN and RELU's), the middle bottleneck for the naive resnet 152 layer 1 looks something like the following:
(conv1): Conv2d(256, 64, kernel_size=(1, 1), stride=(1, 1), bias=False)
(conv2): Conv2d(64, 64, kernel_size=(3, 3), stride=(1, 1), padding=(1, 1), bias=False)
(conv3): Conv2d(64, 256, kernel_size=(1, 1), stride=(1, 1), bias=False)

But this is beside the point.
Even if the implementation is as you've written it, there is a misunderstanding on how the M_i is actually calculated. Specifically, paper specifies the formula

Since we know that t=d=3, the question is what N_i and N_{i-1} actually are if we follow your example, we have N_{i-1} = 256 and N_i = 64 - then the equation becomes

But the actual M_i that I have in the weights dimension is 144, which corresponds to N_i = N_{i-1} = 64 which means that in eIther way the bottleneck multiplier is not considered in the computation of M_i. Is that something we should follow in principle for our reimplementation?

Sounds good, thanks for clarification.


IronWolf Health Management - Can't Schedule Task

Hi,
First off, thanks a ton for this. Awesome.
Noticed with v3.6.109  - "Added -I, --ihm option to update IronWolf Health Management to 2.5.1 to support recent model IronWolf and IronWolf Pro drives."
Sweet. But then I noticed I can't schedule a task to do this despite it telling me I can ;)

Notice the bottom text about scheduling.
But then on the schedule page:

S.M.A.R.T is the only Task Type.
Now back on my older NAS, DS815+ with some older drives I see this:

Hello IronWorlf Health Task Type option.
Best,
Will

Well OK, never mind. Cool, just had to run the scan at least once and now the schedule option has appeared. :)

Sweet, passed. And nice and quick.

Oh dang, hello IronWorlf Health Task type :)

Nice, now shows correctly scheduled.
Awsome, thanks again.


Scroll as a User Gesture in RWS

Context
The Related-Website-Set (RWS) comprises a network of websites belonging to the same organization. While ensuring stringent data privacy protocols, there is a need to provide organizations with more detailed insights about users within the limited ecosystem that FPS has restricted to.
The Case for Scroll as a User Gesture-

Problem with Current Tracking: Currently FPS does not allow to capture navigation user activities, like reading an article or browsing through a page.
Solution: Implementing scroll tracking can bridge this gap. It would allow us to understand how users interact with our content beyond just clicks and page views.

Proposed Implementation Strategy
Event-Driven Tracking: Implement scroll depth tracking to capture user engagement at various thresholds (25%, 50%, 75%, 100%).

I don't think I understand the problem here. The scroll event already exists; can your pages use that to measure user engagement? If not, why not?
If you're trying to measure reach using a cross-site embed, and your use case doesn't fit into an RWS (e.g. because your embed needs to be embedded on more than 6 sites), then you could consider using other Privacy Sandbox proposals like Shared Storage to measure reach in a privacy-preserving way.

Chris, I am just talking about embedding needs up to 5, but the requestStorageAccessFor method which grants permission to write third-party cookies in a related-site restricted domain needs a user gesture to be triggered which currently is restricted to 'keydown', 'mousedown', 'pointerdown', 'pointerup', 'touchend' events. There are some cases where a User of Site A visits Site B and just scrolls the content of that site and leaves without doing the above-mentioned gesture he would be left untracked or considered as another user by the system.
What I am suggesting is if a user visits some percentage of the page he visits, the requestStorageAccessFor method should be permitted to read and write third-party cookies

I see, you're asking if RWS can treat scroll events as "user interaction", in addition to the event types that have traditionally counted as user interaction on the web platform (HTML specification), for the purposes of the document.requestStorageAccessFor(origin) (and presumably also document.requestStorageAccess()) APIs.
Unfortunately, I don't think that is a good option, for a few reasons:

It's not a reliable signal of engagement.

Whether a user has to scroll depends on their device's screen size (and the location of the content they're interested in), so a user with a sufficiently large screen would never scroll, and would not be able to scroll. This makes it hard to build a reliable site that relies on scrolling.
Similarly, a user who is only interested in content that's above-the-fold would not need to scroll, so the site would not work properly if it relies on scrolling.

It is unexpected for the user.

The web platform has aligned on requiring user activation (using the current definition in the HTML specification) for powerful capabilities. Sharing unpartitioned data will be considered a powerful capability in the near future, since it can be used for pervasive tracking; so it ought to require the same kind of "interactions" that are required for other powerful features in the web platform. However, I think it's extremely unlikely that we could succeed in changing the definition of "user interaction" in the HTML spec to include scrolling, since scroll events have historically not been considered a signal of user interaction, in general.

It encourages sites to build worse experiences for users.

As noted above, a user only needs to scroll if the content they're interested in is currently off-screen. If browsers treated scroll events as user interactions, then sites would be incentivized to put interesting content below the fold, to force the user to scroll (and therefore unlock some powerful feature such as access to unpartitioned data, as described above). This is bad for the user because they had to do more work in order to get to the content they wanted.

There may be more issues that I haven't thought of, but these are enough to convince me that we should not consider scroll events for document.requestStorageAccessFor(origin).

Why do you even need the user interaction at all for requestStorageAccessFor, if you're using RWS, isn't the grant automatic? The documentation reads:

When third-party cookies are blocked but Related Website Sets (RWS) is enabled, Chrome will automatically grant permission in intra-RWS contexts

Are you experiencing otherwise? Or did you not setup RWS and you're just using SAA without RWS?

The requestStorageAccessFor spec requires a transient user interaction for a successful invocation of the API; please see step 13.7 of the specification.

The documentation reads:

When third-party cookies are blocked but Related Website Sets (RWS) is enabled, Chrome will automatically grant permission in intra-RWS contexts

It's tricky to document this in an unambiguous way, but the auto-granting behavior described here means that Chrome will accept the permission request on the user's behalf (without prompting the user), provided that all of the other requirements (e.g. that the caller is the top-level document, that the requestedOrigin is valid, etc.) are met.
Having a transient user activation is one of the baseline requirements that Chrome checks before deciding to accept or reject the request on the user's behalf.


Extensions support

In my browser env, I'm using some useful extensions to enhance services.
It would be very great to support loading these extensions (or at least some of them)
Electron already support some chrome extensions APIs and apps like Station, or Shift already support this feature.
There is also this issue for Franz
You can also use extensions for supporting Dark Theme, AdBlocker and many more!
For more information, please see:

https://github.com/sentialx/electron-extensions
https://github.com/getstation/electron-chrome-extension
https://github.com/getstation/repackage-chrome-extension-for-electron
https://electronjs.org/docs/api/browser-window#browserwindowaddextensionpath

+1 for extension support from me. I'd love to be able to use 1Password.

Another +1. Would love to integrate lastpass.

+1 Dashlane

Related: https://github.com/electron/electron/issues/19447
Electron seems to be getting native support for basic extensions in Electron >= 9. We'll have to wait until that is released and until we have upgraded to it though.

Not stale, in fact, with the release of Electron 9 with extension support, this issue is more relevant than ever

Yes, we need make Ferdi compatible with Electron 9 first (see https://github.com/orgs/getferdi/projects/3). I'm really looking forward to seeing Ferdi support Extensions.

+1 for passbolt (https://www.passbolt.com/) – that would be the missing puzzle piece for me

+1 for me too, would allow me to add Mailvelope, which can be used for many web mail providers, Roundcube, GMail etc.

Just something like tampermonkey would be nice too, there's a firefox addon for discord, for example, that somehow reduces battery drain a bit by disabling the discord typing indicators...
Being able to block some of the API urls would help as well, I think that some, especially with discord, are more or less tracking cruft.

+1 for me and I wanted to bump it. Super important feature.

+1 Can't wait for this to be released

+1 I am really missing this on Gmail for extensions like mixmax

Same here, I feel this is the last piece for the definitive app given the fact that is built over Electron, which makes this swifter like Wavebox does.

I put up a $50 bounty on this issue (via bountysource) to support the work already done by @vantezzen via https://github.com/getferdi/ferdi/pull/822.

+1 for ad-blockers

+1 for chrome extensions

+1 for chrome extensions

+1 LastPass and an ad blocker would be awesome!!!

+1 LastPass and an ad blocker would be awesome!!!

Looking forward to the possibility of extensions support also.

Looking forward to the possibility of extensions support also.

With all due respect, but could we stop adding +1 comments? It just needlessly notifies anyone subscribed to this issue.
To show your support/desire for this issue, give the original post a :+1: and subscribe to be alerted of any updates!

With all due respect, but could we stop adding +1 comments? It just needlessly notifies anyone subscribed to this issue.
To show your support/desire for this issue, give the original post a :+1: and subscribe to be alerted of any updates!

remove staleness

Reposting my thoughts: the best would be .CRX extensions, but it would be too much, scripts are cool as they are like extensions. The idea is to implement a userscripts (like greasemonkey, tampermonkey etc )  This would really expand a possibility of software to a new level

@warshell - the idea is good. We are looking for contributors - either to review and/or to help test. As noted by @kytwb in https://github.com/getferdi/ferdi/issues/113#issuecomment-719445447 - we need some contributor to own this up and take it forward.

Just put up an extra $100 on the bounty with a 3mo expiration to hopefully speed this along :)

Adding my note after exploring Fredi a little more (it seems like it's growth in on turbo right now. )
Wish extensions can be introduced here too. something like 1Password and such (which apparently also moved to Electron) would be epic addition.
Thanks you to all the contributors\bounty boosters and those that gave the idea too!

FYI It looks like two anonymous backers put an additional $200 on the bounty, bringing the total up to $350

+1

+1