forward read_/write_timeout in ssl socket to underlaying socket

I'm a bit skeptical of this. Adding a bunch of NotImplementedErrors errors for this doesn't seem right.
First of all, what's the intended use case?
Maybe there could be other (more type-safe) solutions?
If we stay with the suggested methods, we could consider moving them to a more generic location than SSL::Socket (maybe even IO::Buffered).

So in our server software we listen both for plain text and TLS connections. We then hand over the socket (TCPSocket, or OpenSSL::SSL::Socket) down the line and treat them all the same. In parts of the protocol a read_timeout has be set, and sometimes we're just waiting endlessly (timeout = nil) for data on the socket. And instead of both having to pass the both raw TCPSocket AND the OpenSSL::SSL::Socket in the case of TLS connections down the line, we currently monkey patch the SSL::Socket with the above code.

I don't see how this could be implemented in IO::Buffered, but if BIO#io was a Socket instead of a IO here: https://github.com/crystal-lang/crystal/blob/3817a99db9b1a9bb2fa007a91ef0c857d80d097f/src/openssl/bio.cr#L115
we could avoid responds_to?.

So i guess my question is, can OpenSSL::BIO ever be passed an IO object that isn't a Socket?

It seems so: https://github.com/crystal-lang/crystal/blob/73518893dff6592287257c78574dcbe9d0b32903/src/openssl/x509/extension.cr#L60-L66

ah yeah, so what do you think? better for ppl to pass around both the underlaying socket and the openssl::socket, or to raise NotImplemented if you try to set read_timeout on an openssl::socket where you've used a IO::Memory as underlying socket?

I have no problem with this PR and I think it's fine. There's really no other way to do this in Crystal without proper interfaces.

Or maybe we can define these methods to IO with a default NotImplemented and then make IO::Buffered forward those methods to the underlying IO. That way there's no responds_to?.

@asterite an in-memory buffer with read/write timeouts sounds plausible to me, so :+1: for this transparent and more generic solution.

I was actually thinking that in-memory buffer would never timeout. So for IO::Memory it would be a nop.

But how would IO::Buffered forward to the underlying socket? As the underlying socket is @bio.io in OpenSSL::SSL::Socket, but in most other cases in @io? Or an abstract method in IO::Buffered, so that all classes that extends IO::Buffered has to implement read_timeout et al?

IO::Buffered feels misplaced too, timeouts doesn't have much to do with buffering either I feel? Is it just that SSL::Socket happens to extend that module?

Yes, SSL::Socket can wrap a generic IO. And that makes sense. None of it's behaviour is strictly bound to a socket, it can work on anything (wrapping a socket is certainly the most common application, though).
This change essentially merges unrelated behaviour into this class, which only belongs to Socket but not to generic IOs. I guess local_address and remote_address are already precedents for this. They're not in the inherent scope of SSL::Socket either.
Having these specific delegators on SSL::Socket only helps as far as it directly wraps a Socket. Should there be any other wrapping, for example compression, the entire thing breaks.
Promoting this to the generic IO interface makes more sense, I guess.
An alternative would be to introduce a method to access the wrapped IO, which would allow to navigate to the source socket and call methods on it directly. However, this would already be complicated for IO::MultiWriter and IO::Stapled which wrap multiple IOs.

Oh, I thought IO::Buffered wrapped another IO but that's not the case. Sorry, disregard what I said before.
Again, I see no problem with this PR. One usually works with a socket, and the socket can be a raw socket Socket or a secure socket OpenSSL::SSL::Socket. You want to work with those things uniformly. Then both types should have more or less the same methods.
What I don't understand is that when you have something that can either be a Socket or OpenSSL::SSL::Socket, the compiler will infer its type to be IO. Then you can't do io.read_timeout = ... because it's not defined on IO. So you have to check if it's Socket or ssl Socket. @carlhoerberg is that what you are doing?
If so, I think read_timeout and others should be in IO. Then you can work uniformly with any IO. Same reason we have flush on every IO even though not every IO can be flushed.
At least that's how Crystal works. Other languages have interfaces so you would have IO::Waitable or something and you could check that.
In any case, it makes sense to put a timeout on an ssl socket, and have that work properly without having to deal with the underlying IO.

Absolutely, putting read_timeout et al in IO and in SSL::Socket forward it to @bio.io could work. Do you think the default implementation should be noop like flush or raise NotImplemented?

@asterite I suppose SSL::Socket is actually a bad name, because this type is not a socket. It's just an IO wrapper (similar to Gzip::Reader for example) and has nothing to do with a socket.
In Crystal's IO design there is no raw socket and secure socket. There is only Socket, and such a socket can be wrapped in SSL::Socket for providing encryption.
We should consider this when re-designing a generic TLS API, this type should not be be called "socket" but maybe TLS::IO or similar.

I think the core issue here is that Socket represents two separate concerns: connection configuration (for example timeouts, addresses) and the stream interface (IO methods). SSL::Socket only wraps the latter (on purpose because because it's supposed to works with any IO).
So SSL::Socket can't fully replace Socket in a handler that needs direct access to the underlying socket configuration.
Moving the respective methods to IO mitigates that. And for {read,write}_timeout it might still make some kind of sense. But {remote,local}_address really shouldn't belong to IO, that's entirely specific to Socket.
IMO it would be better to pass both Socket and SSL::Socket to handlers, where the former is responsible for connection configuration and the latter for handling the stream IO.
This would allow users access to even more specific socket configuration, for example the tcp_keepalive_* options.
A practical implementation could simply add socket as a parameter to HTTP::RequestProcessor#process and property to HTTP::Context. In both cases it can be optional to allow for non-socket application.

or give access to the underlying IO through the SSLSocket?  eg. @ssl_socket.io.read_timeout = 15

it's annoying though in the handler code to distinguish if it's a SSL or a "normal" socket, i just want to read and write to it. and in some steps set the read_timeout as it's part of the protocol. passing around (socket : Socket, ssl_socket : SSLSocket?) is super ugly.

I think we can merge this, right? It's harmless and it works fine.


[tests] track dotnet/maui/release/9.0.1xx

This should fix the MAUI Integration test lane.

I guess they are using internal builds of .NET, and this won't work...
dotnet-install : Downloading from "primary" link has failed with error :  [D:\a\_work\1\s\maui\src\DotNet\DotNet.csproj]
EXEC : error : Unable to download https://dotnetbuilds.blob.core.windows.net/internal/Sdk/9.0.100-rtm.24522.3/dotnet-sdk-9.0.100-rtm.24522.3-win-x64.zip. Returned HTTP status code: 404 Downloading from "legacy" link has failed with error: [D:\a\_work\1\s\maui\src\DotNet\DotNet.csproj]
EXEC : error : Unable to download https://dotnetbuilds.blob.core.windows.net/internal/Sdk/9.0.100-rtm.24522.3/dotnet-dev-win-x<IP_ADDRESS>-rtm.24522.3.zip. Returned HTTP status code: 404 [D:\a\_work\1\s\maui\src\DotNet\DotNet.csproj]
dotnet-install : Downloading from "primary" link has failed with error :  [D:\a\_work\1\s\maui\src\DotNet\DotNet.csproj]
EXEC : error : Unable to download https://dotnetbuilds.blob.core.windows.net/internal/Sdk/9.0.100-rtm.24522.3/dotnet-sdk-9.0.100-rtm.24522.3-win-x64.zip. Returned HTTP status code: 404 Downloading from "legacy" link has failed with error: [D:\a\_work\1\s\maui\src\DotNet\DotNet.csproj]
EXEC : error : Unable to download https://dotnetbuilds.blob.core.windows.net/internal/Sdk/9.0.100-rtm.24522.3/dotnet-dev-win-x<IP_ADDRESS>-rtm.24522.3.zip. Returned HTTP status code: 404 [D:\a\_work\1\s\maui\src\DotNet\DotNet.csproj]
D:\a\_work\1\s\maui\src\DotNet\DotNet.csproj(139,5): error MSB3073: The command "powershell -ExecutionPolicy ByPass -NoProfile -Command "& 'D:\a\_work\1\s\maui\temp/dotnet-install.ps1' -Version 9.0.100-rtm.24522.3 -InstallDir 'D:\a\_work\1\s\maui\.dotnet/' -Verbose -AzureFeed https://dotnetbuilds.blob.core.windows.net/internal -FeedCredential $env:DOTNET_TOKEN"" exited with code 1.
    0 Warning(s)
    7 Error(s)


Cmake command to only build include files

I'm working on top of https://github.com/Ansersion/myRtspClient. It doesn't have cmake, I'm adding so it can work on Android. The problem is that in order for me to link it together with with JRTPLIB, I need to build with JRTPLIB source files. But for now, when I add_subdirectory the jrtplib in the myRtspClient's cmakelists file, it will build the headers but in the end it will also build the entire jrtplib, which is unnecesary.
Wouldn't it be great to have a way to build only the include files?

In fact, the only problem I'm having is that the generated .h files are going somewhere else that I can't access on my main project which uses yours by doing add_subdirectory. I just needed the include files to build mine. The simplest solution I can think of is adding the line
configure_file("${PROJECT_SOURCE_DIR}/src/rtptypes.h.in" "${PROJECT_BINARY_DIR}/src/rtptypes.h")
but with PROJECT_SOURCE_DIR instead of PROJECT_BINARY_DIR and for the other two configuration files add too.
Do you have a better idea?

A few thoughts:

If you only need the headers, then you need to take care that the settings they use match those of the compiled library (so the rtpconfig.h should contain the settings that were used when actually compiling the library)
In my opinion it's not a good idea to move the generated rtptypes.h and rtpconfig.h to the source directory: it would definitely mess things up when using different builds (with different settings) based on the same sources

But I don't really understand the problem. If I understand correctly, you need the headers, but not the compiled library in your project, right? Then where is the compiled library coming from? (You'll still need to link against it)

For the purpose of compiling and installing JRTPLIB I think the cmake file is great, the files are going to be installed into the system. If I want to compile a library that uses yours, like https://github.com/Ansersion/myRtspClient, I'd just include the installed header files from the system. However the compilation will use the headers generated for my system, not for other systems. That's ok in general but not for Android I guess.
In order to build for Android, there's no way of installing the headers into the system and then using them to build my project. The way I'm doing right now is to add JRTPLIB as a subdirectory to be built before the main project. However, the header files generated by JRTPLIB compilation are needed, so I added a dependency. I had to add a dependency to the shared library target, but it could be a simple dependency to the configure files (if possible).
Anyways, even for the shared library target I'm not being able to get the genrated headers because they are installed into a custom folder of the android project, but that has nothing to do with the main problem of needing the header files to build projects based on yours.
Do you have a better idea?

But why not? Why not build and install the library and header files in another location, and include those in your project?


style: customize docusaurus classic theme

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


Log extra information, and fix max_max_new_tokens

[x] Log extra information like prompt and generation hyperparameters.
[x] Fix max_max_new_tokens usage so separate from max_new_tokens and remove user_set_max_new_tokens

tried --max_max_new_tokens=2048 and looked at expert and good, and tried 1048 and looked at expert and good.

looks good, thx


How to get order of chats

Hi, I'm trying to update from v1.6.0 to v1.7.0.
According to the Getting Started section, the order should just be derived from the chat.positions_ attribute.

The correct order of chats in chat lists is maintained by TDLib, so the Application only needs to listen to updates that change the chat.positions field and sort all chats by the pair (position.order, chat.id) in a given position.list

However, positions is always an empty array. I found the following description of getChats:

Returns an ordered list of chats in a chat list. Chats are sorted by the pair (chat.position.order, chat.id) in descending order.

In fact, the order of the chats sorted by arrival of their updateNewChat events is correct. But once a message arrives / the order changes for other reasons, my application would have to derive the order again by itself, or query getChats again. Both wouldn't really contribute to a good architecture.
Is there something I have missed? How is the functionality of the order attribute now represented in 1.7.0?

Do you listen to and process all updates, which change the positions? You need to handle updateChatPosition, updateChatLastMessage and updateChatDraftMessage to maintain correct chat position in chat lists.

I missed the updateChatPosition one, thanks!
When the positions array of updateChatLastMessage and updateNewChat are empty (such as in my tests), what do I set the position of the chat to? Do I only update the chat position when they contain a non-empty positions array?

If it is empty, then the positions are unknown. Chats need to be placed in a chat list only if their positions are known.

Which means I only need the updates from updateChatPosition?


snap layer to LatLang?

Is snapping strictly for precision drawing or can it be used to snap a layer to a specific LatLang or bound while dragging? I am trying to support the ability to grid snap draggable layers. For example, if you are dragging an image layer, it snaps to every _n_th LatLang intersection instead of freely being draggable anywhere.

We don't have implemented any snapping for ImageOverlay, so you need do add this logic by your self.
I will add this as a Feature Request

Thanks @Falke-Design I did what you suggested.
For those that are interested, I used two layers: a Circle and an ImageOverlay, and only set the Circle as draggable. On Circle change I set the position of the underlying ImageOverlay after Math.rounding the LatLang to the nearest integer, which is the nearest grid position as per my map scale. Once I drop the Circle I have its position also snap to keep the two layers together.
You can see it here: https://github.com/hypergig/LeafyVTT/pull/1


How would you handle this case

Hey, first of all, I like the idea of labels and like even more on a "common" way of specifying them but how would your schema respond to this use case ?
Image these repos:

application/pikachu (vX.X.X)
docker/pikachu (vY.Y.Y)

Where application/pikachu contains the source for the pikachu app and docker/pikachu contains the Dockerfile for the pikachu container. Imagine now that the pikachu app has a dependency to ca-certificates in version vZ.Z.Z
So this would be some of the labels:
{
  "build-date" = "xxxxxxx",
  "name": "pikachu",
  "description": "foo bar stuff",
  "vcs-url": "[git_url]/docker/pikachu",
  "vcs-ref": "279FA63",
  "version": "vY.Y.Y"
  "vendor": "Pokemon"
}

Now in this case, I don't know which version of ca-certificates is installed nor do I know which version of pikachu app is installed.
So wouldn't it be better to add something like this:
{
  "build-date" = "xxxxxxx",
  "name": "pikachu",
  "description": "foo bar stuff",
  "vcs-url": "[git_url]/docker/pikachu",
  "vcs-ref": "279FA63",
  "version": "vY.Y.Y"
  "vendor": "Pokemon"
  "applications": {
    "pikachu" : {
      "vcs_url": "[git_url]/application/pikachu",
      "vcs_ref": "[commit_id]",
      "version": "vX.X.X"
    },
    "ca-certificates": {
      "version": "vZ.Z.Z"
    }
  }
}

This would allow to know what's actually in the image. It might also be great to have more info in the labels of the image it is based on since that could also be a changing factor if you reference for example: ubuntu:latest. Having the base image ID in there would garantee that you'll be able to rebuild that image exactly how it is
Like I said this is just an example of wht I'd like to see if there is some standardization of labels that would be done :)

dockerfiles and docker-compose.yml do not support this format currently.


Kindly request the inclusion

I'm reaching out to share a recent paper I've co-authored titled "DrAttack: Prompt Decomposition and Reconstruction Makes Powerful LLM Jailbreakers". Our research focuses on jailbreaking LLM by prompt decomposition, and I believe it aligns well with your interest in LLM safety.
You can access the paper here. Our project page and twitter message are also available for your reference.
Thank you so much for considering my request. I'm also open to any questions or discussions this might spark – I'd love to engage in a meaningful conversation with someone of your expertise.
Best regards,
Xirui Li

Thank you for point me to this paper! I will surely have a look. I will add it in the list now, but please let me know if you would like to provide your own summary of the paper.


Use ensure_future in server examples

The examples use two run commands:
asyncio.get_event_loop().run_until_complete(start_server)
asyncio.get_event_loop().run_forever()

If the purpose of the first one is only to add the task to the loop, would it not be better to use ensure_future?
asyncio.ensure_future(start_server)
asyncio.get_event_loop().run_forever()

In non-toy use cases, you'll need the result value of start_server to stop the server.
server = asyncio.get_event_loop().run_until_complete(start_server)
try:
    asyncio.get_event_loop().run_forever()
# still a toy, a real program would do this with signals.
except KeyboardInterrupt:
   server.close()
   asyncio.get_event_loop().run_until_complete(server.wait_close)

(not 100% sure about that code, I just typed it from memory, but hopefully you get the idea)
I'm going to keep this ticket around because it's a valid question that the docs should address, one way or another.

That makes sense. I wasn't aware of the need to clean up. Seems like the ideal case for a context manager. Going to add to that discussion (#86).

This may deserve some documentation as well.

I added a full example of how to shut down the server.


NIFI-4468: If an entire batch of Provenance Events are read by the Si…

…te-to-Site Provenance Reporting Task and none of them match the filters, then the reporting did not update its state, so it would be stuck in this cycle indefinitely. Made fix so that if any event is read from the provenance repository, regardless of whether or not it matches the filters, we update the state to keep track of what has been processed
Thank you for submitting a contribution to Apache NiFi.
In order to streamline the review of the contribution we ask you
to ensure the following steps have been taken:
For all changes:

[ ] Is there a JIRA ticket associated with this PR? Is it referenced
in the commit message?

[ ] Does your PR title start with NIFI-XXXX where XXXX is the JIRA number you are trying to resolve? Pay particular attention to the hyphen "-" character.

[ ] Has your PR been rebased against the latest commit within the target branch (typically master)?

[ ] Is your initial contribution a single, squashed commit?

For code changes:

[ ] Have you ensured that the full suite of tests is executed via mvn -Pcontrib-check clean install at the root nifi folder?
[ ] Have you written or updated unit tests to verify your changes?
[ ] If adding new dependencies to the code, are these dependencies licensed in a way that is compatible for inclusion under ASF 2.0?
[ ] If applicable, have you updated the LICENSE file, including the main LICENSE file under nifi-assembly?
[ ] If applicable, have you updated the NOTICE file, including the main NOTICE file found under nifi-assembly?
[ ] If adding new Properties, have you added .displayName in addition to .name (programmatic access) for each of the new properties?

For documentation related changes:

[ ] Have you ensured that format looks appropriate for the output in which it is rendered?

Note:
Please ensure that once the PR is submitted, you check travis-ci for build issues and submit an update to your PR as soon as possible.

@markap14 I tested on S2S with and without Provenance filter to see the bug before and after fix and all checked out as expected.


feat(#1659): add html reporter for cli

Description
Add a HTML reporter :
bruno run request.bru --output results.html --format html

The report describes each request and response, with full details of assertions and tests.
See example : https://github.com/trusta/bruno/blob/feat/html-report/packages/bruno-cli/examples/report.html
There are screenshots one the associated issue : https://github.com/usebruno/bruno/issues/1659
Contribution Checklist:

[x] The pull request only addresses one issue or adds one feature.
[x] The pull request does not introduce any breaking changes
[x] I have added screenshots or gifs to help explain the change if applicable.
[x] I have read the contribution guidelines.
[x] Create an issue and link to the pull request.

Note: Keeping the PR small and focused helps make it easier to review and merge. If you have multiple changes you want to make, please consider submitting them as separate pull requests.
Publishing to New Package Managers
Please see here for more information.

This is awesome!
Thank you, @trusta !


Google pay error message on cancel is "[object Object]"

Describe the bug
When canceling a google pay payment (closing the window for example). The error that gets sent to the onError function that was passed to the Checkout has the message [object Object]. The error name is also ERROR instead of CANCEL like with other payment methods
To Reproduce
Steps to reproduce the behavior:

Attempt payment with google pay
Cancel the payment
Check the onError callback

Expected behavior
I expected the error.name to be CANCEL, and to have a normal error message
Screenshots
If applicable, add screenshots to help explain your problem.
Desktop (please complete the following information):

OS: macOS 12.4
Browser firefox
Version 107

This has also been reproduced on a chromebook with google chrome, but i'm not sure about the exact version numbers there

Hey @BackEndTea ,
What version of the SDK are you using? When trying to reproduce the issue, I am getting the proper error message and not the [object Object] .  In my case, error.message has the value: 'AbortError: User closed the Payment Request UI.'
In regards of the error name - we are indeed passing ERROR and not CANCEL. We can't simply change it because this could potentially break other integrations. I also assume that, from the GooglePay SDK, all sorts of errors could be fired besides CANCEL, so that is why we are naming it as more generic ERROR.

I have tracked it down to this line
https://github.com/Adyen/adyen-web/blob/a39e82c31d8c836e8112ff2f5009032fea2d844a/packages/lib/src/components/GooglePay/GooglePay.tsx#L63
I added console.log(e, e.toString()) to the minified code on my side and got this result.
This is with SDK version 5.30.1 (the latest at moment of writing this)

Okay, i did some further digging.
On chrome the message comes through correct as 'AbortError: User closed the Payment Request UI.' However, on both firefox 108, and safari 16.1, the message is [object Object]

Thanks @ribeiroguilherme !


Make cc0 video smaller

The video is now 1.65MB (previously 4.36MB), with a smaller resolution + bitrate changed to 2000kbps. Also I corrected the timing of subtitles which seemed a bit off as the video is ~7sec long.
Changing the video to a lower bitrate might help with the size more and would probably kick even under 1MB, but the resolution is really small now and the frames are changing to pixelated something with compression artifacts. I'm not sure if I should try to push it more and make the quality worse.

If we have only one video file, it might be ok to keep it as is, this new version is really low quality. I'm also ok witch merging if others want it, it just seems like it would offer a not so flashy experience in a video playback example.

Would be nice if the video had a disclaimer like "Low Resolution Video Test".

Yeah, but that wouldn't make the experience better.

Let's close this. We could use the original mp4 file (2.2MB) when the ffpyplayer recipe for android gets merged.
https://videos.pexels.com/videos/time-lapse-video-of-tall-buildings-894


Clarabel 7.1 errors with insufficient progress on a seemingly simple SOCP

While upgrading Drake to clarabel 7.1 (https://github.com/RobotLocomotion/drake/pull/21053), one of our (seemingly simple) unit tests started falling down with "insufficient progress".  Mosek solves it fine.
I've carved out the following reproduction
import clarabel
import numpy as np
from scipy import sparse

q = [0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1]
b = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, -1, 1, -0, -0, -0, 1, -0, -0, -0, 1, 1, -0, 1, -0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]
P = sparse.csc_matrix((18, 18))

data = [-1, 1, 1, -1, 1, -1, -1, -1, -1, 1, -0.5, -0.5, 1, -0.7071067811865476, 1, -0.7071067811865476, 1, -1, 0.7071067811865475, -1.0536712127723509e-08, 1, -1, 0.7071067811865475, -1.0536712127723509e-08, -0.5, 0.5, -1, -1, 1, -1, 1, -1, -1, -1, -1, 1, -0.5, -0.5, 1, -0.7071067811865476, 1, -0.7071067811865476, 1, -1, 0.7071067811865475, -1.0536712127723509e-08, 1, -1, 0.7071067811865475, -1.0536712127723509e-08, -0.5, 0.5, -1, 1, -2, 1, -1, 1, 1, -1, 1, -0.5, -0.5, 1, 1, -0.7071067811865476, 1, 1, -0.7071067811865476, 1, 0.7071067811865475, -1.0536712127723509e-08, 1, 0.7071067811865475, -1.0536712127723509e-08, -0.5, 0.5]
rows = [2, 3, 12, 13, 20, 21, 22, 23, 30, 31, 34, 35, 0, 36, 1, 37, 2, 14, 36, 38, 3, 15, 37, 39, 34, 35, 6, 7, 12, 16, 24, 25, 26, 27, 30, 31, 40, 41, 4, 42, 5, 43, 6, 17, 42, 44, 7, 18, 43, 45, 40, 41, 8, 9, 10, 13, 19, 28, 29, 32, 33, 46, 47, 8, 14, 48, 9, 15, 49, 10, 48, 50, 11, 49, 51, 46, 47]
cols = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 2, 2, 3, 3, 3, 3, 4, 4, 4, 4, 5, 5, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 7, 7, 8, 8, 9, 9, 9, 9, 10, 10, 10, 10, 11, 11, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 12, 13, 13, 13, 14, 14, 14, 15, 15, 15, 16, 16, 16, 17, 17]
A = sparse.csc_matrix((data, (rows, cols)))
cones = [
  clarabel.ZeroConeT(20),
  clarabel.NonnegativeConeT(1),
  clarabel.NonnegativeConeT(1),
  clarabel.NonnegativeConeT(1),
  clarabel.NonnegativeConeT(1),
  clarabel.NonnegativeConeT(1),
  clarabel.NonnegativeConeT(1),
  clarabel.NonnegativeConeT(1),
  clarabel.NonnegativeConeT(1),
  clarabel.NonnegativeConeT(1),
  clarabel.ZeroConeT(1),
  clarabel.NonnegativeConeT(4),
  clarabel.SecondOrderConeT(6),
  clarabel.SecondOrderConeT(6),
  clarabel.SecondOrderConeT(6),
]

settings = clarabel.DefaultSettings()
solver = clarabel.DefaultSolver(P, q, A, b, cones, settings)
solver.solve()

Results in
-------------------------------------------------------------
           Clarabel.rs v0.7.1  -  Clever Acronym

                   (c) Paul Goulart
                University of Oxford, 2022
-------------------------------------------------------------

problem:
  variables     = 18
  constraints   = 52
  nnz(P)        = 0
  nnz(A)        = 77
  cones (total) = 15
    :        Zero = 2,  numel = (20,1)
    : Nonnegative = 10,  numel = (1,1,1,1,...,4)
    : SecondOrder = 3,  numel = (6,6,6)

settings:
  linear algebra: direct / qdldl, precision: 64 bit
  max iter = 200, time limit = Inf,  max step = 0.990
  tol_feas = 1.0e-8, tol_gap_abs = 1.0e-8, tol_gap_rel = 1.0e-8,
  static reg : on, ϵ1 = 1.0e-8, ϵ2 = 4.9e-32
  dynamic reg: on, ϵ = 1.0e-13, δ = 2.0e-7
  iter refine: on, reltol = 1.0e-13, abstol = 1.0e-12,
               max iter = 10, stop ratio = 5.0
  equilibrate: on, min_scale = 1.0e-5, max_scale = 1.0e5
               max iter = 10

iter    pcost        dcost       gap       pres      dres      k/t        μ       step
---------------------------------------------------------------------------------------------
  0  +0.0000e+00  -5.7518e+00  5.75e+00  9.93e-01  6.89e+03  1.00e+00  1.33e+03   ------
  1  +4.4363e-02  +7.9443e+01  7.94e+01  9.93e-01  3.89e-01  8.61e+01  2.96e+02  7.90e-01
  2  +4.4016e-01  +4.4876e+02  4.48e+02  9.92e-01  4.14e-01  4.55e+02  2.93e+02  8.17e-02
  3  +2.1750e+00  +1.5761e+03  7.24e+02  9.91e-01  1.30e+00  1.58e+03  2.79e+02  3.00e-01
  4  +5.5621e+00  +2.2199e+03  3.98e+02  9.69e-01  1.81e-01  2.22e+03  4.48e+01  8.55e-01
  5  +6.7417e+00  +1.0322e+02  1.43e+01  4.21e-01  4.90e-03  9.66e+01  1.22e+00  9.83e-01
  6  +5.0782e+00  +6.1775e+00  2.16e-01  4.76e-02  5.32e-04  1.10e+00  1.31e-01  9.05e-01
  7  +5.0782e+00  +6.1775e+00  2.16e-01  4.76e-02  5.32e-04  1.10e+00  1.31e-01  0.00e+00
---------------------------------------------------------------------------------------------
Terminated with status = InsufficientProgress
solve time = 286.812µs

Admittedly there are some ugly small coefficients in there... this was generated through our higher-level GCS abstraction.  But I thought it was best to capture the instance and report.

In 0.7.1 we fixed a bug in the data equilibration that allowed the matrix scaling to exceed the limits set by the user.    In the course of fixing that I also relaxed the bounds slightly (because hey, at least the bounds always work now....).
Probably that was a mistake.   A temporary fix is to go back to the old limits:
settings.equilibrate_min_scaling = 1e-4;
settings.equilibrate_max_scaling = 1e+4;

We will make this reversion permanent in the next minor release assuming it doesn't break something elsewhere.    I'll also add this case to our unit testing.


Check if country contains states to prevent UK issue

Duplicate of https://github.com/PrestaShopCorp/ps_checkout/pull/918


Update Cuda to 8.0.61

Update Cuda to 8.0.61
After making all changes to the cask:

[x] brew cask audit --download {{cask_file}} is error-free.
[x] brew cask style --fix {{cask_file}} left no offenses.
[x] The commit message includes the cask’s name and version.

Verified locally, thanks for your contribution.


The 'verbose' level 16 is not documented

Describe the bug
The description at :help 'verbose' doesn't mention level 16, which does differ from level 15.
To Reproduce

Run gvim.exe --clean -V15fifteen.txt, quit gVim with :q
Run gvim.exe --clean -V16sixteen.txt, quit gVim with :q
Diff-compare the files fifteen.txt and sixteen.txt: the latter has 4507 lines starting with "Executing:" while the former only has 4; maybe there are some other differences.

Environment

Vim 8.2.825 (https://github.com/vim/vim-win32-installer/releases/download/v8.2.0825/gvim_8.2.0825_x86_signed.zip)
OS: Windows 10 Home 1803
Terminal: GUI.

Here would be a doc patch:
diff --git a/runtime/doc/options.txt b/runtime/doc/options.txt
index cc3f5126b..4b457ff76 100644
--- a/runtime/doc/options.txt
+++ b/runtime/doc/options.txt
@@ -8332,6 +8332,7 @@ A jump table for the options with a short description can be found at |Q_op|.
        >= 13   When an exception is thrown, caught, finished, or discarded.
        >= 14   Anything pending in a ":finally" clause.
        >= 15   Every executed Ex command (truncated at 200 characters).
+       >= 16   Also mention, when the executed command is executed

        This option can also be set with the "-V" argument.  See |-V|.
        This option is also set by the |:verbose| command.

Actually, I think this is not really useful, so perhaps it is better to remove verbose level 16 altogether:
diff --git a/src/ex_docmd.c b/src/ex_docmd.c
index adde9d75f..d0abc391f 100644
--- a/src/ex_docmd.c
+++ b/src/ex_docmd.c
@@ -1691,9 +1691,6 @@ do_one_cmd(
     if ((*cmdlinep)[0] == '#' && (*cmdlinep)[1] == '!')
        goto doend;

-    if (p_verbose >= 16)
-       msg_verbose_cmd(0, *cmdlinep);
-
 /*
  * 1. Skip comment lines and leading white space and colons.
  * 2. Handle command modifiers.


Documentation: Update reference and include user-role

Issue: Pieces of documentation have references to other documentation that are being updated. The reference to the documentation has to be updated with the documentation.

Ensure that a reference to the user-role is included with the updated link to the documentation.
Ensure that documentation that references a user-role is also under the same user-role category.

This is the tree structure evolving place:

We have some files that need to be moved somewhere more appropriate: 310.md, sdmm.md, and some image assets in the /docs directory.

Introduced a new /docs/courses folder path to store course-specific resources until managed by course forks.

New directory structure of /docs/:

All files now organized by user-role:


custom fields in request payload

Hi devs,
I am using JWT,
how can I send some custom data/field to authenticate method generated request payload?
I tried to put myCustomField to credentials but that is not passed to request payload, just "email" and "password" went through.
this.get('session').authenticate(authenticator, credentials)

Which authenticator are you using?

@marcoow I was using authenticator:jwt
but this thread helped me create "custom authenticator" and solved my issue:
https://github.com/jpadilla/ember-simple-auth-token/issues/117
Thank you anyway.


Fix/teste pipeline

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


Resolved crashing issue when user deny Camera Permission

When the user opens app very first time, or when the permission is not allowed and open the app, It will ask the user for approving permission for camera access. If the user denies the permission, the app gets crashed. It is resolved now.

Hi,
May I know, Why this commit is not approved?
Sincerely,
Shreyash

Any updates on this?

Is there any update on this?

@googlebot
Is there any update on this PR?

This sample has been migrated to a new location where we can accept Pull Requests (check README for more information).
As recommended by GitHub, we are closing all issues and pull requests now that this older repo will be archived.
If you still see this issue in the updated repo, please reopen the issue/PR there. Thank you!


big hammer to get ip-transparent working with pf divert-to rules on OpenBSD

I've been tinkering with trying to get logging of DNS requests out of unbound so I can see what terrible things are happening on my network(s). That's been ok, except I noticed some devices ignore the DNS server I provide via DHCP, and I would like to log those requests too.
In this setup I am using an OpenBSD box as a router, and it's running unbound too. Assume i have the following interface:
$ ifconfig re1
re1: flags=8b43<UP,BROADCAST,RUNNING,PROMISC,ALLMULTI,SIMPLEX,MULTICAST> mtu 1500
        lladdr fe:e1:ba:d0:b8:c3
        index 2 priority 0 llprio 3
        groups: internal
        media: Ethernet autoselect (1000baseT full-duplex)
        status: active
        inet <IP_ADDRESS> netmask 0xffffff00 broadcast <IP_ADDRESS>
        inet6 fe80::20d:b9ff:fe3e:d8c9%re1 prefixlen 64 scopeid 0x2

And this up the top of my pf.conf:
$if_internal="re1"
$svc_dns="$if_internal"

I can then use a rule like this to catch the misbehaving hosts:
pass in quick on $if_internal \
        inet proto { tcp udp } to !$svc_dns port domain \
        rdr-to $svc_dns port domain

This is fine, DNS works, and unbound replies to the redirected DNS requests fine. However, in the logs this
looks like the misbehaving clients are doing the same thing as the well behaved ones. I would like to be able to tell the types of devices apart so I can identify/classify them and maybe fix them. An evolution of this is to have
unbound listen somehwere weird and redirect to that so there's something different in the logs.
So I put this in unbound.conf:
interface: <IP_ADDRESS>@35

... and this in pf.conf:
pass in quick on $if_internal \
        inet proto { tcp udp } to !$svc_dns port domain \
        rdr-to $svc_dns port 35

Now I can look for client requests to port 35 in the logs and I have my answer.
However, the ultimate would be being able to see address of the nameserver the misbehaving clients were trying to connect to in the logs. Reading the unbound.conf man page (and a bit of the code), it sounds like ip-transparent is what i want. It's supposed to enable SO_BINDANY on listening sockets and use getsockname()/IP_RECVDSTADDR to figure out
what the original IP was, and then use IP_SENDSRCADDR for replies.
So with this in unbound.conf:
ip-transparent: yes

... and this in pf.conf:
pass in quick on $0f_internal \
        inet proto { tcp udp } to !$svc_dns port domain \
        divert-to $svc_dns port domain

... it should work. For most things it does.
DNS clients using TCP and UDP to talk to <IP_ADDRESS> port 53 (like they're supposed to) work. DHS clients trying to talk to another NS like <IP_ADDRESS> port 53 work too. However, DNS clients using UDP to talk to <IP_ADDRESS> port 53 do not. They look
like this:
$ dig @<IP_ADDRESS> www.google.com
;; reply from unexpected source: <IP_ADDRESS>#53, expected <IP_ADDRESS>#53

Turns out that unbound isn't using the cmsg stuff to get the original IP addresses. This means when unbound replies, the addresses on the listening socket are used and they are not the right ones for the client. Turns out that's because unbound only enables "ancillary" data collection in specific situations, and at the moment enabling ip-transparent
isn't one of them.
This diff forces unbound to set all UDP sockets up to do the cmsg stuff. I know this is not the right solution, but I thought I'd ask for direction rather than make a guess and have to do the work again.

Diverting DNS traffic, like this, is not really good, and I think perhaps only useful as a debug aid, it looks like tampering to me, for the end clients. If the inspection of the traffic is wanted, something like wireshark can do that. It can also be set to filter out particular messages and display them.
The ip transparent option sets the socket option. But in addition you want to enable cmsg stuff, and this particular cmsg stuff is enabled by interface-automatic: yes and perhaps also use interface-automatic-ports: "additionalport1 additionalport2". That makes unbound fetch the IP addresses from the connection and use them in the reply so that the source address of the reply is correct.
If the code change still needs to be made, it would be nice to allow this as an additional option that can be enabled by the user for the specific use case, instead of an always active bypass.
Some devices ignore the DHCP provided DNS server, instead relying on others, and cloud providers are popular. There are encrypted connections that can be set up, using for example the dns over TLS and HTTPS options. Unbound can provide this kind of connectivity, and this is precisely to avoid the firewall here. It is possible to configure the certificate that unbound provides, but also wants to admit, to verify the server identity.

Diverting DNS traffic, like this, is not really good, and I think perhaps only useful as a debug aid, it looks like tampering to me, for the end clients. If the inspection of the traffic is wanted, something like wireshark can do that. It can also be set to filter out particular messages and display them.

I probably shouldn't have wasted time explaining all the logging background. I agree that capturing or duplicating packets also lets me log requests, but if I ever enable DoT or DoH on my local networks then the best point to observe DNS requests will be from inside unbound.
If my goal is to intercept or tamper with DNS in the clear, then I can do that already with an IP rewrite. The question is more whether ip-transparent is supposed to work in this situation too.

The ip transparent option sets the socket option. But in addition you want to enable cmsg stuff, and this particular cmsg stuff is enabled by interface-automatic: yes and perhaps also use interface-automatic-ports: "additionalport1 additionalport2". That makes unbound fetch the IP addresses from the connection and use them in the reply so that the source address of the reply is correct.
If the code change still needs to be made, it would be nice to allow this as an additional option that can be enabled by the user for the specific use case, instead of an always active bypass.

Sounds to me like the cmsg bits could also be enabled when ip-transparent: yes is set?

Some devices ignore the DHCP provided DNS server, instead relying on others, and cloud providers are popular. There are encrypted connections that can be set up, using for example the dns over TLS and HTTPS options. Unbound can provide this kind of connectivity, and this is precisely to avoid the firewall here. It is possible to configure the certificate that unbound provides, but also wants to admit, to verify the server identity.

There's an interesting philosophical discussion we could have here about ownership and authority over the equipment we purchase and are responsible for operating, and whether than ends at the network port on an individual device or on port on my router facing the public internet. It's one thing for a malicious network operator to intercept or modify my DNS requests, it's another thing for a device that we've bought and put on my network to think it always knows better than me about where it should do DNS lookups.

Yes that is a complicated space of concerns about device ownership and traffic patterns. But I wanted to make you aware, if you weren't, about DoT and so on.
The ip-transparent option should only enable the socket option that it uses. The additional cmsg stuff, to store and use the interface IP address, should be enabled with a separate option. That could then be used in conjunction with the ip-transparent option. This is a good idea, because the functionality is also useful for others, with eg. weird routing setups, that have source address issues. Not that, in that space, the ip-transparent and ip-freebind socket options are also used.
Perhaps the existing interface-automatic options can be used to enable the cmsg source IP capture that is needed here? If that is not useful, perhaps some option like perhaps ip-cmsg-srcaddr that enables the cmsg stuff?

I'll try interface-automatic instead of ip-transparent when I get a chance.
When to cmsg or not to cmsg is an annoyingly complicated decision tree. Technically you can use the IP_RECVSRCADDR and IP_SENDSRCADDR cmsgs if you have a listener on a wildcard address. This allows you to listen to all IPs on the system with a single FD (per address family), and reply to messages from any of those addresses. To me this sounds like any wildcard listener should use the cmsgs, regardless of ip-transparent or interface-automatic. Is interface-automatic actually needed?
Without the cmsgs the traditional approach is iterate over all addresses in the system and bind to them on startup. The more advanced approach is listen on the routing socket for new addresses and bind to them as they appear.
The way ip-transparent is documented is that it allows binding to non-local IPs. To me that implies SO_BINDANY/IP_BINDANY. If it's not a wildcard listener then it doesn't need the cmsgs because the address it's bound to provides the source address, which should be the only way a packet will come in on that socket.
The only real gap is the (ab)use case I have, which is that I'm binding to a non-wildcard address and redirecting/diverting packets to it. To divert packets with pf it needs to be bound with SO_BINDANY, and to reply to them it needs IP_SENDSRCADDR.
So, is that 4 possible configurations?

vanilla wildcard listener should use cmsgs when available
vanilla non-wildcard listener doesn't need SO_BINDANY or cmsgs
ip-transparent should be a non-wildcard listener with SO_BINDANY, but doesn't need cmsgs
divert-to in pf needs a bind to a non-wildcard address, and SO_BINDANY and cmsgs so it can reply to them

Am I missing anything?

It may also be possible to enable both the interface-automatic: yes and 'ip-transparent: yesoption at the same time, and that may be a good possible configuration. Theip-transparent: yes` config option enables SO_BINDANY. On BSD, it uses IP_TRANSPARENT.
There is an option in Unbound to list the addresses of an interface, with interface: eth0. That lists the addresses of the interface name, at startup of Unbound, and binds them.
I am not sure what the different configurations are you want; but in terms of the code change I was looking for, I thought of adding code that enables a new config option, that can be toggled together with other options, or on its own. The option enables the cmsg handling, the srcaddr handling, and it could be called ip-cmsg-srcaddr: yes perhaps. This is also the gist of the code change proposed, in the temporary code patch, but then as an option.


fix: set initial task title and description values from Onyx if present

Details
Set the the task title and description on the initial page in the assign task flow using values from Onyx if they are present.
Fixed Issues
$ https://github.com/Expensify/App/issues/19460
PROPOSAL: https://github.com/Expensify/App/issues/19460#issuecomment-1560405178
Tests

Click on Assign Task in global create menu.
Add title and description.
Click on the Next button.
On the Confirm Task page, click on the Title.
Change the value for the Title.
Click on Next.
Repeat steps 4 through 6 for the Description.
Click on the back chevron button at the left hand side of the assign task heading.
Verify that the Title and Description are updated with the new values set.

[x] Verify that no errors appear in the JS console

Offline tests
Same as tests.
QA Steps
Same as tests.

[x] Verify that no errors appear in the JS console

PR Author Checklist

[x] I linked the correct issue in the ### Fixed Issues section above
[x] I wrote clear testing steps that cover the changes made in this PR

[x] I added steps for local testing in the Tests section
[x] I added steps for the expected offline behavior in the Offline steps section
[x] I added steps for Staging and/or Production testing in the QA steps section
[x] I added steps to cover failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
[x] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)
[x] I tested this PR with a High Traffic account against the staging or production API to ensure there are no regressions (e.g. long loading states that impact usability).

[x] I included screenshots or videos for tests on all platforms
[x] I ran the tests on all platforms & verified they passed on:

[x] Android / native
[x] Android / Chrome
[x] iOS / native
[x] iOS / Safari
[x] MacOS / Chrome / Safari
[x] MacOS / Desktop

[x] I verified there are no console errors (if there's a console error not related to the PR, report it or open an issue for it to be fixed)
[x] I followed proper code patterns (see Reviewing the code)

[x] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick)
[x] I verified that the left part of a conditional rendering a React component is a boolean and NOT a string, e.g. myBool && <MyComponent />.
[x] I verified that comments were added to code that is not self explanatory
[x] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
[x] I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method

[x] If any non-english text was added/modified, I verified the translation was requested/reviewed in #expensify-open-source and it was approved by an internal Expensify engineer. Link to Slack message:

[x] I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
[x] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is approved by marketing by adding the Waiting for Copy label for a copy review on the original GH to get the correct copy.
[x] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
[x] I verified the JSDocs style guidelines (in STYLE.md) were followed

[x] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
[x] I followed the guidelines as stated in the Review Guidelines
[x] I tested other components that can be impacted by my changes (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar are working as expected)
[x] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
[x] I verified any variables that can be defined as constants (ie. in CONST.js or at the top of the file that uses the constant) are defined as such
[x] I verified that if a function's arguments changed that all usages have also been updated correctly
[x] If a new component is created I verified that:

[x] A similar component doesn't exist in the codebase
[x] All props are defined accurately and each prop has a /** comment above it */
[x] The file is named correctly
[x] The component has a clear name that is non-ambiguous and the purpose of the component can be inferred from the name alone
[x] The only data being stored in the state is data necessary for rendering and nothing else
[x] For Class Components, any internal methods passed to components event handlers are bound to this properly so there are no scoping issues (i.e. for onClick={this.submit} the method this.submit should be bound to this in the constructor)
[x] Any internal methods bound to this are necessary to be bound (i.e. avoid this.submit = this.submit.bind(this); if this.submit is never passed to a component event handler like onClick)
[x] All JSX used for rendering exists in the render method
[x] The component has the minimum amount of code necessary for its purpose, and it is broken down into smaller components in order to separate concerns and functions

[x] If any new file was added I verified that:

[x] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory

[x] If a new CSS style is added I verified that:

[x] A similar style doesn't already exist
[x] The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG))

[x] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
[x] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
[x] If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
[x] If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
[x] If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.
[x] I have checked off every checkbox in the PR author checklist, including those that don't apply to this PR.

Screenshots/Videos

Web
https://github.com/Expensify/App/assets/4160319/39908d03-7e97-4b3c-8b72-b4fda9f62623

Mobile Web - Chrome
19460-android-chrome.webm

Mobile Web - Safari
https://github.com/Expensify/App/assets/4160319/e5adc65b-ae16-4947-95b7-8ae1ac3052ee

Desktop
https://github.com/Expensify/App/assets/4160319/146ec601-1306-40dc-ad8c-9ae2ce8dd10f

iOS
https://github.com/Expensify/App/assets/4160319/b9072d02-cc82-4183-bf06-ecf64d5bcfff

Android
19460-android-native.webm

@abdulrahuman5196 A note regarding clearing the values when the "x" button is clicked: It looks like this is already working as expected. Clicking on the close button and then selecting Assign task to create a new task opens the form with empty fields (when the title and description were previously filled), so there is no need to implement this here.

@akinwale but when we open the task page directly via url after previously filling details in assign page and closing, we will be showing the old data.

@akinwale but when we open the task page directly via url after previously filling details in assign page and closing, we will be showing the old data.

I don't think we need to do anything in this case in my opinion. If the user accidentally closes or refreshes the page, it's a good experience for the input data to be preserved.

I don't think we need to do anything in this case in my opinion. If the user accidentally closes or refreshes the page, it's a good experience for the input data to be preserved.

@akinwale I wasn't mentioning about tab close or refresh. I meant to clear when user manually closed the drawer with the close button. I don't think we retain old values user manually presses the header x button
@aldo-expensify Correct me if wrong.
https://github.com/Expensify/App/assets/46707890/ca134c54-b2d0-4373-91d9-1ac6c9fed239

I don't think we need to do anything in this case in my opinion. If the user accidentally closes or refreshes the page, it's a good experience for the input data to be preserved.

@akinwale I wasn't mentioning about tab close or refresh. I meant to clear when user manually closed the drawer with the close button. I don't think we retain old values user manually presses the header x button
@aldo-expensify Correct me if wrong.
Untitled.45.mp4

@abdulrahuman5196 Ah,  I see what you mean.
The task info is actually being cleared out when the Assign task menu item is clicked. This is happening here:
https://github.com/Expensify/App/blob/09a4debff8d88443ebeacff050ee7ffb463120c5/src/pages/home/report/ReportActionCompose.js#L449
To clear out the information when the close button is clicked / pressed, then I'll need to add a call to TaskUtils.clearOutTaskInfo to the event handler on every task-related page. If this is the desired approach, I can push a commit with the changes now.

@akinwale Kindly check on the above issues

@akinwale Kindly check on the above issues

@abdulrahuman5196 Thanks for the review. I have pushed a new commit with the necessary fixes.

Reviewer Checklist

[x] I have verified the author checklist is complete (all boxes are checked off).
[x] I verified the correct issue is linked in the ### Fixed Issues section above
[x] I verified testing steps are clear and they cover the changes made in this PR

[x] I verified the steps for local testing are in the Tests section
[x] I verified the steps for Staging and/or Production testing are in the QA steps section
[x] I verified the steps cover any possible failure scenarios (i.e. verify an input displays the correct error message if the entered data is not correct)
[x] I turned off my network connection and tested it while offline to ensure it matches the expected behavior (i.e. verify the default avatar icon is displayed if app is offline)

[x] I checked that screenshots or videos are included for tests on all platforms
[ ] I included screenshots or videos for tests on all platforms
[x] I verified tests pass on all platforms & I tested again on:

[x] Android / native
[x] Android / Chrome
[x] iOS / native
[x] iOS / Safari
[x] MacOS / Chrome / Safari
[x] MacOS / Desktop

[x] If there are any errors in the console that are unrelated to this PR, I either fixed them (preferred) or linked to where I reported them in Slack
[x] I verified proper code patterns were followed (see Reviewing the code)

[x] I verified that any callback methods that were added or modified are named for what the method does and never what callback they handle (i.e. toggleReport and not onIconClick).
[x] I verified that the left part of a conditional rendering a React component is a boolean and NOT a string, e.g. myBool && <MyComponent />.
[x] I verified that comments were added to code that is not self explanatory
[x] I verified that any new or modified comments were clear, correct English, and explained "why" the code was doing something instead of only explaining "what" the code was doing.
[x] I verified any copy / text shown in the product is localized by adding it to src/languages/* files and using the translation method
[x] I verified all numbers, amounts, dates and phone numbers shown in the product are using the localization methods
[x] I verified any copy / text that was added to the app is grammatically correct in English. It adheres to proper capitalization guidelines (note: only the first word of header/labels should be capitalized), and is approved by marketing by adding the Waiting for Copy label for a copy review on the original GH to get the correct copy.
[x] I verified proper file naming conventions were followed for any new files or renamed files. All non-platform specific files are named after what they export and are not named "index.js". All platform-specific files are named for the platform the code supports as outlined in the README.
[x] I verified the JSDocs style guidelines (in STYLE.md) were followed

[x] If a new code pattern is added I verified it was agreed to be used by multiple Expensify engineers
[x] I verified that this PR follows the guidelines as stated in the Review Guidelines
[x] I verified other components that can be impacted by these changes have been tested, and I retested again (i.e. if the PR modifies a shared library or component like Avatar, I verified the components using Avatar have been tested & I retested again)
[x] I verified all code is DRY (the PR doesn't include any logic written more than once, with the exception of tests)
[x] I verified any variables that can be defined as constants (ie. in CONST.js or at the top of the file that uses the constant) are defined as such
[x] If a new component is created I verified that:

[x] A similar component doesn't exist in the codebase
[x] All props are defined accurately and each prop has a /** comment above it */
[x] The file is named correctly
[x] The component has a clear name that is non-ambiguous and the purpose of the component can be inferred from the name alone
[x] The only data being stored in the state is data necessary for rendering and nothing else
[x] For Class Components, any internal methods passed to components event handlers are bound to this properly so there are no scoping issues (i.e. for onClick={this.submit} the method this.submit should be bound to this in the constructor)
[x] Any internal methods bound to this are necessary to be bound (i.e. avoid this.submit = this.submit.bind(this); if this.submit is never passed to a component event handler like onClick)
[x] All JSX used for rendering exists in the render method
[x] The component has the minimum amount of code necessary for its purpose, and it is broken down into smaller components in order to separate concerns and functions

[x] If any new file was added I verified that:

[x] The file has a description of what it does and/or why is needed at the top of the file if the code is not self explanatory

[x] If a new CSS style is added I verified that:

[x] A similar style doesn't already exist
[x] The style can't be created with an existing StyleUtils function (i.e. StyleUtils.getBackgroundAndBorderStyle(themeColors.componentBG)

[x] If the PR modifies code that runs when editing or sending messages, I tested and verified there is no unexpected behavior for all supported markdown - URLs, single line code, code blocks, quotes, headings, bold, strikethrough, and italic.
[x] If the PR modifies a generic component, I tested and verified that those changes do not break usages of that component in the rest of the App (i.e. if a shared library or component like Avatar is modified, I verified that Avatar is working as expected in all cases)
[x] If the PR modifies a component related to any of the existing Storybook stories, I tested and verified all stories for that component are still working as expected.
[x] If a new page is added, I verified it's using the ScrollView component to make it scrollable when more elements are added to the page.
[x] If the main branch was merged into this PR after a review, I tested again and verified the outcome was still expected according to the Test steps.
[ ] I have checked off every checkbox in the PR reviewer checklist, including those that don't apply to this PR.

Screenshots/Videos

Web

Mobile Web - Chrome

Mobile Web - Safari

Desktop

iOS

Android

@akinwale  Offline test should Same as Tests in author's checklist instead of N/A? This is expected to work offline as well.

@akinwale  Kindly fix these issues

In author's checklist Offline tests should be Same as test right? Since we expect this fix to work offline as well.

I am getting error when we don't enter description and click next

https://github.com/Expensify/App/assets/46707890/da13583a-5145-47dc-8469-b5bf45f34dc8

@akinwale Kindly fix these issues

In author's checklist Offline tests should be Same as test right? Since we expect this fix to work offline as well.
I am getting error when we don't enter description and click next

Untitled.9.mp4

Correct.
This is because we removed the defaultValue for description. Do we want this to be empty string or props.task.description? Or I can set the value to props.task.description || '' which makes more sense.

@akinwale Kindly fix these issues

In author's checklist Offline tests should be Same as test right? Since we expect this fix to work offline as well.
I am getting error when we don't enter description and click next

Untitled.9.mp4

@abdulrahuman5196 Done. See comments here.

@akinwale
Is form setting the value as undefined for not passing default value or since props.task.description is undefined while calling useState() and we pass undefined value to form ?
If later we should update the useState() to not set undefined on taskDescription

I think the latter mentioned is the issue here https://github.com/Expensify/App/pull/19908#issuecomment-1575678599. Correct me if wrong. @akinwale

@akinwale
Is form setting the value as undefined for not passing default value or since props.task.description is undefined while calling useState() and we pass undefined value to form ?
If later we should update the useState() to not set undefined on taskDescription

@abdulrahuman5196 I believe it's the latter where props.task.description is undefined with useState.
What do you suggest here? Set useState('') for both taskTitle and taskDescription, or just taskDescription alone?

@akinwale

then we can use it this way

useState(props.task.description || '')
and similar way inside useEffect.(both should be only for description since task is not expected to have a default value)
This should be best way since we handle value and onValueChange.

One more thing. We have used onChangeText but onValueChange is the Form recommended - https://github.com/Expensify/App/blob/main/contributingGuides/FORMS.md
Kindly update this as well and kindly test and update here.

@akinwale

then we can use it this way

useState(props.task.description || '')
and similar way inside useEffect.(both should be only for description since task is not expected to have a default value)
This should be best way since we handle value and onValueChange.

One more thing. We have used onChangeText but onValueChange is the Form recommended - https://github.com/Expensify/App/blob/main/contributingGuides/FORMS.md
Kindly update this as well and kindly test from your end as well and update here.

@abdulrahuman5196 Thanks for the update. All done.
Tested and it works properly.

:hand: This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release.

🚀 Deployed to staging by https://github.com/aldo-expensify in version: 1.3.24-0 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
success ✅

🍎 iOS 🍎
success ✅

🕸 web 🕸
success ✅

🚀 Deployed to production by https://github.com/roryabraham in version: 1.3.24-5 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
failure ❌

🍎 iOS 🍎
failure ❌

🕸 web 🕸
success ✅

🚀 Deployed to production by https://github.com/roryabraham in version: 1.3.24-5 🚀

platform
result

🤖 android 🤖
success ✅

🖥 desktop 🖥
cancelled 🔪

🍎 iOS 🍎
cancelled 🔪

🕸 web 🕸
success ✅


Support trackpad gestures in framework

This commit adds support for new pointer events to convey trackpad gesture information. These new events will trigger existing widgets that expect scale or pan gestures.

Three new types of events (PointerPanZoomStartEvent, PointerPanZoomUpdateEvent, PointerPanZoomEndEvent) to convey the states of a trackpad gesture
GestureRecognizers can handle pointer flows (the relevant ones DragGestureRecognizer and ScaleGestureRecognizer have been updated)
GestureDetector has been updated so that onScale, onPan, onVerticalDrag, and onHorizontalDrag will trigger from trackpad gestures

Design Document
Engine PR: https://github.com/flutter/engine/pull/28571
Addresses https://github.com/flutter/flutter/issues/23604
Closes https://github.com/flutter/flutter/issues/63084
Widgets that use GestureRecognizers directly instead of GestureDetector will need to handle the onPointerPanZoomStart callback of Listener with their GestureRecognizers to receive trackpad gesture events.
Pre-launch Checklist

[x] I read the [Contributor Guide] and followed the process outlined there for submitting PRs.
[x] I read the [Tree Hygiene] wiki page, which explains my responsibilities.
[x] I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement].
[x] I signed the [CLA].
[x] I listed at least one issue that this PR fixes in the description above.
[x] I updated/added relevant documentation (doc comments with ///).
[x] I added new tests to check the change I am making or feature I am adding, or Hixie said the PR is test-exempt.
[x] All existing and new tests are passing.

I'm removing the tool label, as the only tool change is a single key in an XML config template.

@justinmc Thanks for the review. The engine isn't sending any trackpad gesture events yet. So if you want to try it out early, you need the changes from the PR for your platform (should all be linked under https://github.com/flutter/flutter/issues/23604).

Gold has detected about 1 new digest(s) on patchset 10.
View them at https://flutter-gold.skia.org/cl/github/89944

@justinmc Most operating systems do their own disambiguation and will lock a gesture into being only a zoom v.s. only a pan. Nothing in this PR prevents simultaneous zoom and pan, it's handled correctly if the engine provides that data. I believe it worked on one of the platforms during testing but now can't remember which one.

@moffatman Can you try sync'ing this PR with head?

@alexeylopukh can you file a new issue describing what you're seeing and what should happen instead?

This PR introduces a breaking change @dkwingsmt
Listener(
  onPointerSignal: (sig) {
    if (sig is PointerScrollEvent) { /* this is no longer triggered on trackpad scroll*/ }
  },
)


Registry Update All should limit concurrency

Currently we send calls to the registry for all tenants, which can be a lot for the backends to handle.
We should instead set a hard limit on the number of tenants running concurrently and send new calls only when the job processing for previous tenants finishes.

The current implementation already limits the concurrency to 1.


Restrict JSR-303 annotations to supported field types

I found that JSR-303 annotations were getting applied to types that didn't support them. For example, if a "pattern" was specified on a "string" property that also had a "format" of "uuid", then the generated field type is UUID class (rather than String) and @Pattern was still applied. Because that annotation isn't valid on a UUID type, then validators generate errors.
Continuing with this example, because a schema may be used to generate source classes in non-Java languages, there is still value to keep the "pattern" restriction on the source json schema itself for languages that might not have an in-built UUID type.
This patch updates the various JSR-303 Rules classes to enhance them to check the generated class type of potentially annotated fields against the classes/types that are documented to support the relevant annotation (as documented in each annotation's JavaDoc).
In a second logical commit, Unit tests were added for thes JSR-303 rules classes. This required updating Mockito to a newer version that (properly) supports mocking final classes.
In a third logical commit, integration tests were updated with schemas that generate unsupported field types for the various cases, in addition to the supported types.

@joelittlejohn ,
Do you have any plans or notions when you might release 1.0.2?
Thank you.


License?

What license is the code?

I'll add a reference to http://unlicense.org/

Thanks

Added UNLICENSE


Not compatible with Python 2

I'm not sure if this is something you want to deal with, but it's good to have compatibility with both. On a related but different not, you might want to implement Travis.

At this point I'm mostly focused on getting a version working in python 3. It's been challenging enough getting that to work consistently across ask versions and platforms. I know a lot of people still use python 2 so it might be a good long term goal to branch a python 2 version, but that is not a trivial task at this point. Anyone else have any thoughts on this?
And forgive my ignorance, but what is Travis?

I think I agree with Brandon here. It's likely not a trivial task to make
both compatible, since it would require a lot of changes, but it is a
worthy goal once the Python 3 version is up and running well. Do we know if
most users are currently on one version of Python or if it's a mix?
On Sat, Aug 13, 2016 at 11:58 AM, zephyr5050<EMAIL_ADDRESS>wrote:

At this point I'm mostly focused on getting a version working in python 3.
It's been challenging enough getting that to work consistently across ask
versions and platforms. I know a lot of people still use python 2 so it
might be a good long term goal to branch a python 2 version, but that is
not a trivial task at this point. Anyone else have any thoughts on this?
And forgive my ignorance, but what is Travis?
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/aurorayk/New_Hammer/issues/3#issuecomment-239627826,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ABYXF9VtN7CYkE0Zg703pLDHnxyDvR-Jks5qfemJgaJpZM4Jjssk
.

--
Daniel Feldman
Boston University Graduate Student
Department of Astronomy
<EMAIL_ADDRESS><EMAIL_ADDRESS>(917) 608-3850

You can look here for a survey of Python use in Astronomy: http://astrofrog.github.io/blog/2015/05/09/2015-survey-results/

Also, Travis (https://docs.travis-ci.com/user/languages/python) is a package for continuous integration. In a nutshell, it constantly checks to make sure your code works as Python versions and dependencies update.

As stated, we're not planning on supporting Python 2 at this point. We're going to focus on getting this working in Python 3 and possibly support Python 2 down the line. Besides, the article indicates that of the Python 2 users, 62% haven't switched because they have no incentive to do so. Consider this program the incentive.


Refactor toolbar

Still needs more refactoring but this is at least a start

We can merge this as a start, but there is still a lot to do in my oppinion

Yeah there for sure still is a lot to do and the code is a mess still, but this refactoring already does some improvements. Doing all at once would be too overwhelming.

I will make some more adaptions based on your comments and then I would merge

@PaulBredl okay, I would merge now. Also to avoid more merge conflicts. More refactoring can be done in a follow-up step.


Cleanup go.sum

there are so many duplicated dependencies in there, which

makes installation take forever
could add bugs if multiple versions of the same library are used
increases the binary size

for example:
k8s.io/apimachinery v0.0.0-20180126010752-19e3f5aa3adc h1:+YMPfU/2f9LMz0Sy68+JodreTTgo9PNSpkLw3PakNbs=
k8s.io/apimachinery v0.0.0-20180126010752-19e3f5aa3adc/go.mod h1:ccL7Eh7zubPUSh9A3USN90/OzHNSVN6zxzde07TDCL0=
k8s.io/apimachinery v0.0.0-20181015213631-60666be32c5d/go.mod h1:ccL7Eh7zubPUSh9A3USN90/OzHNSVN6zxzde07TDCL0=
k8s.io/apimachinery v0.0.0-20190404173353-6a84e37a896d/go.mod h1:ccL7Eh7zubPUSh9A3USN90/OzHNSVN6zxzde07TDCL0=
k8s.io/apimachinery v0.0.0-20190816221834-a9f1d8a9c101 h1:QtHYUjIdgXTtJVdYQhWIQZZoXa32aF3O9BNX2up2plE=
k8s.io/apimachinery v0.0.0-20190816221834-a9f1d8a9c101/go.mod h1:ccL7Eh7zubPUSh9A3USN90/OzHNSVN6zxzde07TDCL0=

I'd propose some CI step that makes sure it is only using 1 version per dependency ... does that make sense ?

Hi @grosser ,
From my understanding, unused entries in go.sum does not affect anything:

The only thing that's really affecting installation or compilation is what we stored in the /vendor directory (since we are using the "-mod vendor" option).
The golden rule determining the code in the /vendor directory is stored at go.mod.

I don't think it would slow down installation or increases binary size. And I don't think multiple versions in go.sum hurts anything (other than a few Bytes of storage on the repository :) ).
The closest tool I can think of to trim them, is to run GO111MODULE=on go mod tidy.
According to the documentation, it should remove unnecessary entries in go.mod and go.sum. I ran it once against the current state, and filed #391 .

One thing to note out is that even go mod tidy does not clean up the unused versions in go.sum, it only cleans up unused modules. See some related golang upstream discussions: https://github.com/golang/go/issues/28456 https://github.com/golang/go/issues/26381
The current opinion of the upstream folks is that the historical version checksums in go.sum is intended. We will see how it goes. But I think the bottom line is, we can follow upstream's decision, and just use the go mod tidy tool.

I also thought about adding a presubmit test or automation to run go mod tidy on every PR. However that's actually a little bit complicated. This is because go mod tidy trims the files using the currently specified build tags (e.g. linux, windows, journald...). NPD is built by different people using different build tags. It's very likely that the automation will accidentally trim modules used by some people in special environments.
So I think the best way is to NOT automate this, unless we can have a good understanding of the build tags that people are using. For now, I think we should just do a manual trim once a while (since it really doesn't hurt anything major).

/assign @xueweiz

👍 yeah not worth the effort I guess


Add support for raw SQL queries

Codecov Report

Merging #13 into master will increase coverage by 1.91%.
The diff coverage is 68.93%.

@@            Coverage Diff             @@
##           master      #13      +/-   ##
==========================================
+ Coverage   45.53%   47.45%   +1.91%
==========================================
  Files          10       11       +1
  Lines        1109     1199      +90
==========================================
+ Hits          505      569      +64
- Misses        573      593      +20
- Partials       31       37       +6

Impacted Files
Coverage Δ

cmd/promhouse/main.go
0% <0%> (ø)
:arrow_up:

handlers/prom.go
20% <0%> (-0.52%)
:arrow_down:

storages/clickhouse.go
77.98% <65.78%> (-0.97%)
:arrow_down:

storages/clickhouse_sql.go
76.66% <76.66%> (ø)

Continue to review full report at Codecov.

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


Update YahooOpenIdAttributesDefinition.java

Yahoo returns "fullname" attribute instead of "display_name"

Perfect

Oops! I merged it too quickly!
The pull request must be targeted for pac4j/pac4j, not leleuj/pac4j.

Hi Again,
No problem, I just created under pac4j/pac4j.
Have a nice day.
Best Regards
Faisal Mateen
On Wed, Mar 25, 2015 at 8:17 AM, LELEU Jérôme<EMAIL_ADDRESS>wrote:

Oops! I merged it too quickly!
The pull request must be targeted for pac4j/pac4j, not leleuj/pac4j.
—
Reply to this email directly or view it on GitHub
https://github.com/leleuj/pac4j/pull/1#issuecomment-85890548.


[FLINK-10853] Provide end-to-end test for Kafka 0.9 connector

What is the purpose of the change
This pull request provides end-to-end test for Kafka 0.9 connector
Brief change log

Provide end-to-end test for Kafka 0.9 connector

Verifying this change
This change is already covered by existing tests.
Does this pull request potentially affect one of the following parts:

Dependencies (does it add or upgrade a dependency): (yes / no)
The public API, i.e., is any changed class annotated with @Public(Evolving): (yes / no)
The serializers: (yes / no / don't know)
The runtime per-record code paths (performance sensitive): (yes / no / don't know)
Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Yarn/Mesos, ZooKeeper: (yes / no / don't know)
The S3 file system connector: (yes / no / don't know)

Documentation

Does this pull request introduce a new feature? (yes / no)
If yes, how is the feature documented? (not applicable / docs / JavaDocs / not documented)

cc @pnowojski

@pnowojski Yes, I found some testing problems, this PR is not ready yet, so I didn't ping you more. Some of the issues you mentioned, I have found out, but not only that, I found that the shell method of sending and reading Kafka messages is not compatible with higher Kafka versions (parameters). I haven't had time to fix it yet, I will ping you when I am ready.

Ok, let me know once that is ready. Keep in mind that if it is not easy to fix, we can live without 0.9 e2e test.


stats: track time waiting in reconcile queue

Add a timer that tracks time that each item has spent in the WorkQueue.
This is implemented by keeping an entryTimes map for each entry that
gets removed when the work item is removed from the WorkQueue.
Fixes: #185

@vagababov thanks for the pointer. I considered using those although my reading was that extracting the individual latency metric (which exists) the right way of reusing it would be to write a MetricsProvider for opencensus. I undestand that this means rewriting the stats_reporter altogether.
I'm happy to go that route if you guys think it's best. Or let me know if I'm overcomplicating the issue, it will likely be the case :)


Uncaught TypeError: $.ajax is not a function

In the latest commit, I'm getting an exception in this line.
It should be window.jQuery.ajax instead of $.ajax

Yea he is currently working on this problem

It's fixed.


Images not being encoded

Hello Anubhav,
Greatly appreciate the work done!
I'm currently facing problems in importing the images and training the algorithm
As per the tutorial after the encoding of the images, the classes needs to be created but i'm getting 0 classes created after running the Encoding code.
Please find the attached image.
This project is really important part of my bachelors project.
Please do the needful,

Thanks and Regards,
Ankith

use python 3, not 2.7

Hello Anubhav,
Thanks for the reply
As you suggested me to install 3 instead of 2.7.
I have tried doing the same.
But the error still persists
Could you please debug this problem.
Thanks and Regards,
Ankith
---Thanks and Regards,Ankith Rajashekar Mullangi,
On Thu, Jun 14, 2018 at 10:09 PM, Anubhav Shrimal<EMAIL_ADDRESS>wrote:

Closed #6 https://github.com/anubhavshrimal/FaceRecognition/issues/6.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/anubhavshrimal/FaceRecognition/issues/6#event-1682051967,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AmYY2Qxxda3ZIffYvI9-M7rVRcYUvCOvks5t8sLwgaJpZM4Ump6N
.


dirPagination: Passing custom values to template in scope

I'm using your pagination directive in Async mode with ngResource to page data. I wanted to show a loading icon in the pagination template when the next page was being loaded. I wanted to solve this in an Angular data binding way, same as the rest of your template, however I could not work out a way to pass this additional loading data into the template without modify your js source which I wanted to avoid.
Modifying your JS with a loading scope property:

Adding my loading spinner to my custom template:

    »

        Loading…

Binding my scope loading parameter to the new property on dir-pagination-controls:
<dir-pagination-controls boundary-links="true" on-page-change="controller.pageChanged(newPageNumber)" template-url="/views/dirPagination.tpl.html" loading="pageChangeLoading"></dir-pagination-controls>

And finally including this loading flag when pages are changed and query is returned:
    pageChanged(pageNumber) {
        this.$scope.pageChangeLoading = true;
        this.loadPageData(pageNumber);
    }

    loadPageData(pageNumber) {
        this.UserResource.query({ pageNumber: pageNumber },(data) => {
            this.$scope.pageChangeLoading = false;

If you have any suggestions on how I could implement this better, I would welcome it.
If we can't think of any better ways of solving this then maybe adding a data, viewBag or customObject property to the dirPaginationControlsDirective.scope object could be useful for people to be able to pass their own custom objects into the template.
As always, epic utilities and love your work!

Hi,
Thanks for the detailed question. I understand what you're trying to do. I am always hesitant at adding new things to the directive API unless there seems to be a fairly widespread need for it. In your case, here are some alternatives I can think of:

Show the loading spinner somewhere else.

Extending the first idea, this could even be something like a div just below the pagination controls which, when displaying, covers up the controls via CSS positioning. This could potentially give the effect you are going for without changing the pagination code. Hack factor = 10.

Something like this: Make a service that tracks whether the page is loaded yet - loadingService. Set loadingService.pageLoaded = true when the asyc call returns in your controller.

Then you define another controller, LoadingController, into which you also inject the loadingService. Now you have access to the loading state of your page calls. You can bind the value of the pageLoaded property to the LoadingController's scope. You can then place this controller into your pagination template so you can access the value there, something like:

    »

        Loading…

Okay, okay, also a little on the hacky side and adding a bit of complexity to your app. If you really can't live with it, feel free to submit a pull request with your changes and I'll consider adding to the API.

I like the idea of the loadingService. I have similar requirement on most of my controllers to show loading spinners while AJAX calls are happening so this would nicely clean up my controllers from setting loading bools all over the place. My data is already coming from an ng-Resource service so hopefully I can retro fit something into that to say when the service is querying data.
Thanks for your help!


v2

Рефакторинг.
Переработано API.
Уменьшен размер словарей.

Coverage decreased (-0.8%) to 97.753% when pulling 12e4cdb1a0a06aab4c967359009ef5a7715479ee on v2 into 25394f00294ea11ce78b2fc8c178003560156773 on master.

Coverage decreased (-0.8%) to 97.753% when pulling 12e4cdb1a0a06aab4c967359009ef5a7715479ee on v2 into 25394f00294ea11ce78b2fc8c178003560156773 on master.

Coverage decreased (-0.8%) to 97.778% when pulling 9526e5e8b26f0cf9b937e908431d53fa4e32c54b on v2 into 25394f00294ea11ce78b2fc8c178003560156773 on master.

Coverage decreased (-0.8%) to 97.778% when pulling e03ddcb5303e49b3025b6eacc9de6b81ee1ba6fb on v2 into 8e4921dd6a1f5634a6760d3c53b40735433499ce on master.

Coverage decreased (-0.8%) to 97.778% when pulling ae1b5ed531c5a1cb1ba4031513907721787d2a64 on v2 into 8e4921dd6a1f5634a6760d3c53b40735433499ce on master.

Coverage decreased (-0.8%) to 97.778% when pulling ae1b5ed531c5a1cb1ba4031513907721787d2a64 on v2 into 8e4921dd6a1f5634a6760d3c53b40735433499ce on master.

Coverage decreased (-0.8%) to 97.778% when pulling ae1b5ed531c5a1cb1ba4031513907721787d2a64 on v2 into 8e4921dd6a1f5634a6760d3c53b40735433499ce on master.

Coverage decreased (-0.8%) to 97.778% when pulling ae1b5ed531c5a1cb1ba4031513907721787d2a64 on v2 into 8e4921dd6a1f5634a6760d3c53b40735433499ce on master.

Coverage decreased (-6.8%) to 91.837% when pulling 8ac19cbd2b1eb1ff17b0150e100b8746d7495dc3 on v2 into 8e4921dd6a1f5634a6760d3c53b40735433499ce on master.

Coverage increased (+1.4%) to 100.0% when pulling bac2540e040a873a39e58b886a965b97fb4ebfe5 on v2 into 8e4921dd6a1f5634a6760d3c53b40735433499ce on master.

Coverage increased (+1.4%) to 100.0% when pulling<PHONE_NUMBER>8d68a8a95f3aeef3b336ce30cba777 on v2 into 8e4921dd6a1f5634a6760d3c53b40735433499ce on master.


test issue 2

second test issue... will neal be notified?

Let's find out :)

Hmm. I didn't get the original 'second test issue... will neal be notified?' update. But I did get the second update. :-)


[devcenter] Small updates - fix error string and update data plane help

This checklist is used to make sure that common guidelines for a pull request are followed.

For new extensions:

[ ] My extension description/summary conforms to the Extension Summary Guidelines.

About Extension Publish
There is a pipeline to automatically build, upload and publish extension wheels.
Once your pull request is merged into main branch, a new pull request will be created to update src/index.json automatically.
You only need to update the version information in file setup.py and historical information in file HISTORY.rst in your PR but do not modify src/index.json.

devcenter


🐞 Bug  Dashboard page image borders malfunction dur to bootstrap update

Is there an existing issue for this?

[X] I have searched the existing issues

Describe the bug
Earlier

Now

Steps To Reproduce

Go to circuitverse website
Login/signup
Go to dashboard page in profile

Expected Behavior
It should be like earlier so correct
Screenshots
No response
Device Information [optional]
- OS:Windoes
- Browser:Chrome
- version:

Additional context
No response
Are you working on this issue?
Yes

@tachyons please assign it to me

This was already addressed in PR #5171

Hey @priyanshagra ,
I think I'll be able to work on this.Could you
please assign me to the task?
thanks.


disable loading of canvas in browser enviroments. Helpful for webpack…

… and other CommonJS builds
Right now we have browserify-specific fields in the package.json which is fine, but it doesn't help with other build systems. I ran into a problem where Webpack was loading node-canvas for browser builds.
There are some solutions, such as

canvas-browserify (suggested here: https://github.com/trifacta/vega/issues/235)
Do what d3 did recently with jsdom: they just moved it into the devDependencies. While it isn't semantic usage of package.json, it worked.

I think this is the more generalized approach to dealing with the problem and recommended by Webpack (https://github.com/webpack/webpack/issues/553):
https://gist.github.com/defunctzombie/4339901#ignore-a-module
I implemented it and it worked.
this fix is related to: https://github.com/trifacta/vega/issues/274 and https://github.com/trifacta/vega/issues/235

Thanks for the PR, Jeff! I've merged it, and included other browser ignores from the datalib library as well. node-canvas has also been moved into optionalDependencies in a prior commit. Let me know if you run into any other issues including Vega 2 in your other builds.


[Release] Stage to Main

#48

Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 99.30%. Comparing base (7ba7746) to head (e031888).
Report is 8 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff             @@
##             main      #49       +/-   ##
===========================================
+ Coverage   86.62%   99.30%   +12.67%
===========================================
  Files           2        2
  Lines         172      144       -28
===========================================
- Hits          149      143        -6
+ Misses         23        1       -22

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.


UseRewriter on Linux/Apache2 gives The page isn’t redirecting properly

As I'm deploying on Ubuntu/Apache2, it works if I use this in Configure method using .NET Core 2.2
app.UseHttpsRedirection();
If I use this instead, however, the web server fails to work at all
app.UseRewriter(new RewriteOptions().AddRedirectToHttpsPermanent());
The Kestrel service log looks fine, but any request results in

The page isn’t redirecting properly
An error occurred during a connection to www.emergenceguardian.com.
This problem can sometimes be caused by disabling or refusing to accept cookies

How can I work around this issue?
By the way, whenever I update the application files, do I need to manually restart with 'systemctl restart website.service' every time or is there an easier way?
Here's my website configuration file
<VirtualHost *:80>
  ServerName www.emergenceguardian.com
  ServerAlias emergenceguardian.com

  Redirect permanent / https://www.emergenceguardian.com/
</VirtualHost>

<VirtualHost *:443>
  ServerName emergenceguardian.com
  ServerAlias www.emergenceguardian.com
#  DocumentRoot /var/www/emergenceguardian.com
  Documentroot /var/www/spiritualselftransformation.com/
   DirectoryIndex default.aspx index.aspx index.php index.html

  <Directory "/var/www/spiritualselftransformation.com/">
    Require all granted
    AllowOverride All
  </Directory>

  <Location "/blog">
    SetHandler None
  </Location>

  SSLEngine on
  SSLCertificateFile /etc/apache2/SSL-KEYS/www.emergenceguardian.com/www_emergenceguardian_com.2017-2019.crt
  SSLCertificateKeyFile /etc/apache2/SSL-KEYS/www.emergenceguardian.com/privateKey.key
  SSLCertificateChainFile /etc/ssl/certs/comodo.bundle
  SSLProtocol all -SSLv3 -TLSv1 -TLSv1.1
  Protocols h2 http/1.1

  <LocationMatch ".*\.php">
    SetHandler application/x-httpd-php
  </LocationMatch>

  ProxyPreserveHost On
  ProxyPass .ht* !
  ProxyPass / http://<IP_ADDRESS>:5000/
  ProxyPassReverse / http://<IP_ADDRESS>:5000/

</VirtualHost>

Can you post a sample project that reproduces the problem so we can run it and try it out, including your Apache configuration?

When I open in Chrome, it tells the error when using redirection middleware: ERR_TOO_MANY_REDIRECTS
Also, with UseHttpsRedirection, I see this in the log

Jun 01 07:53:42 localhost kestrel-sa[9148]: warn: Microsoft.AspNetCore.HttpsPolicy.HttpsRedirectionMiddleware[3]
Jun 01 07:53:42 localhost kestrel-sa[9148]:       Failed to determine the https port for redirect.

Jun 01 07:53:42 localhost kestrel-sa[9148]: Failed to determine the https port for redirect.

This is likely the problem. Can you post a sample project so we can look at the full configuration?

I created a new project and all I did was insert the middleware, compiled for Linux and deployed.
Download the project here.
Here's the Apache2 configuration file
<VirtualHost *:80>
  ServerName www.emergenceguardian.com
  ServerAlias emergenceguardian.com
  Redirect permanent / https://www.emergenceguardian.com/
</VirtualHost>

<VirtualHost *:443>
  ServerName www.emergenceguardian.com
  ServerAlias emergenceguardian.com
  Documentroot /var/www/emergenceguardian.com/
  DirectoryIndex index.php index.html

  # .NET
  ProxyPreserveHost On
  ProxyPass / http://<IP_ADDRESS>:5000/
  ProxyPassReverse / http://<IP_ADDRESS>:5000/

  # SSL
  SSLEngine on
  SSLCertificateFile /etc/apache2/SSL-KEYS/www.emergenceguardian.com/www_emergenceguardian_com.2017-2019.crt
  SSLCertificateKeyFile /etc/apache2/SSL-KEYS/www.emergenceguardian.com/privateKey.key
  SSLCertificateChainFile /etc/ssl/certs/comodo.bundle
  SSLProtocol all -SSLv3 -TLSv1 -TLSv1.1
  Protocols h2 http/1.1
</VirtualHost>

and the SystemD configuration
[Unit]
Description=test website

[Service]
WorkingDirectory=/var/www/emergenceguardian.com
ExecStart=/usr/bin/dotnet /var/www/emergenceguardian.com/WebApplication1.dll
Restart=always
# Restart service after 10 seconds if the dotnet service crashes:
RestartSec=10
KillSignal=SIGINT
SyslogIdentifier=kestrel-eg
User=www-data
Environment=ASPNETCORE_ENVIRONMENT=Production

[Install]
WantedBy=multi-user.target

ProxyPass / http://<IP_ADDRESS>:5000/

This is the problem, the request is arriving at your ASP.NET Core app as an HTTP request, not an HTTPS one. If you're using a proxy like Apache you need to configure the forwarded headers middleware so that the app knows what the front-end (Apache in this case) did, such as terminating SSL. See our docs on hosting ASP.NET Core apps in Apache for more detail.

Redirect permanent / https://www.emergenceguardian.com/

Given this, I don't see why you need ASP.NET Core to rewrite for you at all. Apache is doing the rewriting for you.

ProxyPass / http://<IP_ADDRESS>:5000/

So what should it be instead?
There's all kinds of other rewriting rules taking place, such as www to non-www, and renamed pages, etc. I've rewritten them all in the Apache2 config file so my website works, but it would have been a lot simpler to use the redirection middleware.

Redirect permanent / https://www.emergenceguardian.com/

All this does is the same as UseHttpsRedirection which does work.

All this does is the same as UseHttpsRedirection which does work.

Right, but if you do it in Apache you don't need anything in your ASP.NET Core app. No UseHttpsRedirection, no UseRewrite. Apache handles it entirely.

So what should it be instead?

It depends on what you want to do. If you want Apache to do the redirection, then let Apache do the redirection and just remove all the rewriting/redirection middleware.
If you want ASP.NET Core to do the redirection then you need to configure the forwarded headers middleware (as described in the doc I linked above) so that ASP.NET Core knows that Apache received an HTTPS request. Otherwise, ASP.NET Core is seeing an HTTP request (from Apache) and thinking it needs to redirect to port 443, but the user-facing URL is already on port 443, thus causing the loop.
The UseHttpsRedirection middleware does not just do a redirect like this. It first checks if you've configured Kestrel to use HTTPS. If Kestrel isn't using HTTPS it no-ops, which may be why it appears to be "working" (since I don't see any HTTPS configuration in your code, unless you're running in Development mode and have the dev-cert installed).
The rewrite rule you configured forcibly redirects to port 443 if the request coming in to ASP.NET Core is non-HTTPS. However, because Apache is terminating SSL (and making an unencrypted HTTP request to ASP.NET Core), it does this redirect even when the request actually already came in on port 443, thus causing a loop.

In that case, would removing the HTTPS redirect from the middleware allow to use the other URL rewriting features?

What do you mean? Removing that rule certainly wouldn't preclude using the rewriting features of our middleware. However, I would strongly advise just doing the rewriting in one place. Having multiple layers of rewrite/redirect rules can cause lots of confusion, like this.
The key thing to remember is that when you are being proxied, your app thinks it is being access by a local client (the proxy, Apache in this case) and the request URL is whatever that proxy used to make the request (http://<IP_ADDRESS>:5000/ from your ProxyPass directive in this case). There are special headers (the X-Forwarded-* headers) that proxies can put in their requests to tell ASP.NET Core that there is a proxy in front of them. These headers include the original hostname (emergenceguardian.com in your case), the original protocol (https) as well as the original client address (the IP address of the actual browser).
If you are going to use a proxy, you should configure the ForwardedHeaders middleware (again, docs are available in our hosting ASP.NET Core with Apache doc). This middleware should be right near the top of your pipeline and will "rewrite" the request object to make it look like it came directly from the client. That way all your URL generation will "just work" and you can remove the ProxyPassReverse directive in your file (since that is telling Apache to try to rewrite URLs in the response as well).

This is in 000-default.conf, I believe this sets email forwarding for all domains?
<VirtualHost *:*>
    RequestHeader set "X-Forwarded-Proto" expr=%{REQUEST_SCHEME}
</VirtualHost>

I believe it will, you can easily check by examining the headers in a custom middleware before the ForwardedHeaders middleware.


[SourceKit] Fix memory issue in response construction for typecontextinfo

Buffer may be reallocated during the construction. We can't modify buffer SmallString after getting StringRef out of it.

@swift-ci Please smoke test


HttpGetterInfo should be moved to the specialized package and made private

There is no need for customers to interact with this type and it doesn't need to be shared across package boundaries.

Moving would be a break so closing this