Soft deletes are not applied in time while testing

Laravel Version: 5.3.10
PHP Version: 7.0.5
Database Driver & Version: Postgres 9.4.7

Description:
When using soft deletes on a model, the deleted_at attribute does not seem to "fire" in time for the test to successfully asset that the column is not null.
Steps To Reproduce:

Create a model using Soft Deletes
Add a resource controller with the endpoint to test the destroy method
Write the test

It is also important to note that I removed the use of DatabaseTransactions on the main test to troubleshoot. After the test fails, I check that record in the table and the deleted_at attribute is NOT null.
It appears to set the timestamp after the test has run.
Hopefully this is just a simple user error :)
Thoughts?
Model
This is a sample model, nothing specific.
<?php
namespace App;

use Illuminate\Database\Eloquent\SoftDeletes;
use Illuminate\Database\Eloquent\Model;

class County extends Model
{
    use SoftDeletes;
}

Test
The test that is failing.
/** @test */
public function can_delete_an_existing_resource()
{
    $county = \App\County::all()->random(1);
    $this->delete('v2/counties/' . $county->id);
    $this->seeIsSoftDeletedInDatabase('counties', $county->getAttributes());
}
```

#### Helper On TestCase.php

Added this helper on the TestCase class.

```
protected function seeIsSoftDeletedInDatabase($table, array $data, $connection = null)
{
    $database = $this->app->make('db');

    $connection = $connection ?: $database->getDefaultConnection();

    $count = $database->connection($connection)
        ->table($table)
        ->where($data)
        ->whereNotNull('deleted_at')
        ->count();

    $this->assertGreaterThan(0, $count, sprintf(
        'Found unexpected records in database table [%s] that matched attributes [%s].', $table, json_encode($data)
    ));

    return $this;
}
```

$county->getAttributes() has deleted_at = null, so when you do where($data) the model won't be found, that's why the test is failing.

@themsaid thanks for closing this, I realized it was a mistake last night.
I needed to find the model after the fact and then query that to see the test pass.
$deletedModel = \App\County::where('id', $model->id)
            ->withTrashed()
            ->get();


Looking for maintainers

I do not have enough interest or time to maintain this project. So, I'm looking for a maintainer that would meet these requirements:

Experienced in this field, and is preferably trusted and notable
Won't differ away from the goal of the project, such as adding QOL mods

For the time being, I won't be updating this until I do have more maintainers as I would rather focus on Adrenaline, Additive, and Adrenaserver. Moving to an organization makes this significantly easier to manage.
Thanks in advance.

Could I be a maintainer of the project?  I have knowledge in Forge and modpacks, in fact I have two modpacks published in modrinth.

Sure thing! I can add you to the org and give write access to the repository.

My Modrinth username is "WaffleIBOT", it's the same from Github.

I've now invited you to the organization and invited you to the Modrinth project. I can then give you perms for this repository specifically.


Failed to display a survey on iOS 14 Beta.  App crash.

Device: iPad Pro 9.7in
iOS 14 Beta (18A5351d)
App fails to show a survey after Apptentive.shared.engage(event: eventName, withCustomData: nil, from: controller) than stops responding and crashes in a minute. Profiling shows that there is some problem with an Apptentive collection layout flow which leads to huge memory consumption and app crashing.

Hi @mike-dutka. Thanks for the report. We'll take a closer look as soon as possible.
What version of the SDK are you using?

Hi @CaseyApptentive. Tried 5.2.12 and 5.2.14

Thanks for the versions, @mike-dutka !
We're able to reproduce the issue now and will let you know as soon as we have a fix. This is a priority for us and we'll have it available as soon as we can have everything verified.

This is fixed on the new ios-14 branch released today. Please take a look and let us know if it works for you.
Thanks again for the detailed report!

@frankus we're having issues with the changes to the header imports when we pull this branch in via cocoapods. Our builds are failing because some header files aren't found.
Changing
#import <Apptentive/ApptentiveStyleSheet.h>

to this
#import <ApptentiveStyleSheet.h>

resolves the issue
Has anyone else experienced this? I'm trying to figure out if it's something in our cocoapods setup that's wrong

I am able to reproduce this by removing the use_frameworks! directive from the Podfile.
It's been a few years since I've investigated this, but it sounds like use_frameworks! has fallen out of favor somewhat due to longer app startup times. Can you tell me a bit more about your setup so we can look at improving support for this? Mostly around language mix (Swift/Obj-C) and how you're actually importing things.

Ahhh right right. Our codebase is majority Objective-C with maybe a slowly increasing chunk of swift. Our actual use of the Apptentive SDK is all in a single Objective-C wrapper where we're importing the root Apptentive header file with an #import "Apptentive.h"

We've just released the changes as version 5.3.0.
If adding the use_frameworks! directive to your podfile is not something you're comfortable with, there are instructions here to add a post-install hook and a preprocessor macro that should fix the include issues.
If you can use  use_frameworks! then it should be smooth sailing without any extra work.

Bummer. That's probably not a change we want to make just to support a single package. I'd definitely say I'd recommend y'all figure out how to get the library building without requiring it to be a framework. But admittedly I don't have a full grasp of the challenges there. And I know we're all on a tight timeline with iOS 14 😅
For the long term we may either build more manually or maybe use a git submodule

@braker1nine we've updated the way headers are managed, so you should be able to include it as you have been all along. The only change you might notice is that the Apptentive.h header is no longer copied, so you'll have to include the two headers that live under that umbrella header manually (ApptentiveMain.h and ApptentiveStyleSheet.h).

@frankus I saw that this morning and already have a branch in our codebase building off that branch! 👍 thanks we really appreciate the quick turnaround!


Typing of order_by parameter incorrect in azure-search-documents SearchClient.search

Package Name: azure-search-documents
Package Version: 11.4.0b6
Operating System: MacOS Sonoma 14.2.1
Python Version:  3.11.8

Describe the bug
The typing of the order_by parameter in the SearchClient.search() method is list[str] but returns HttpResponseError: () Invalid expression: Sorting on literal values is not supported in $orderby. when using a list. Using just a string works as expected.
To Reproduce
Steps to reproduce the behavior:

Create a search index with a Sortable field on AI Search
Connect with a SearchClient
Try to run list(search_client.search("*", order_by=[fieldName])) => the above error
Running list(search_client.search("*", order_by=fieldName)) works as expected

Expected behavior
I expected the typing to be correct.
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
https://github.com/Azure/azure-sdk-for-python/blob/91816731c350b9bf4c1f0391f006766d91f5d6a0/sdk/search/azure-search-documents/azure/search/documents/_search_client.py#L349

Thanks for your feedback.
Unfortunately, I cannot repro the issue.
In terms of the code you shared, we handle the case of list in the code below:
https://github.com/Azure/azure-sdk-for-python/blob/main/sdk/search/azure-search-documents/azure/search/documents/_search_client.py#L376-L377

Interesting, thanks for the quick feedback. Maybe this anonymized trace might be helpful?
list(search_client.search("*", order_by=["datePublished"]))
---------------------------------------------------------------------------
HttpResponseError                         Traceback (most recent call last)
----> 1 list(search_client.search("*", order_by=["datePublished"]))

File python3.11/site-packages/azure/search/documents/_paging.py:54, in SearchItemPaged.__next__(self)
     52     first_iterator = self._first_iterator_instance()
     53     self._page_iterator = itertools.chain.from_iterable(first_iterator)
---> 54 return next(self._page_iterator)

File python3.11/site-packages/azure/core/paging.py:75, in PageIterator.__next__(self)
     73     raise StopIteration("End of paging")
     74 try:
---> 75     self._response = self._get_next(self.continuation_token)
     76 except AzureError as error:
     77     if not error.continuation_token:

File python3.11/site-packages/azure/search/documents/_paging.py:124, in SearchPageIterator._get_next_cb(self, continuation_token)
    122 def _get_next_cb(self, continuation_token):
    123     if continuation_token is None:
--> 124         return self._client.documents.search_post(search_request=self._initial_query.request, **self._kwargs)
    126     _next_link, next_page_request = unpack_continuation_token(continuation_token)
    128     return self._client.documents.search_post(search_request=next_page_request, **self._kwargs)

File python3.11/site-packages/azure/core/tracing/decorator.py:89, in distributed_trace.<locals>.decorator.<locals>.wrapper_use_tracer(*args, **kwargs)
     87 for key, value in tracing_attributes.items():
     88     span.add_attribute(key, value)
---> 89 return func(*args, **kwargs)

File python3.11/site-packages/azure/search/documents/_generated/operations/_documents_operations.py:793, in DocumentsOperations.search_post(self, search_request, request_options, **kwargs)
    791     map_error(status_code=response.status_code, response=response, error_map=error_map)
    792     error = self._deserialize.failsafe_deserialize(_models.SearchError, pipeline_response)
--> 793     raise HttpResponseError(response=response, model=error)
    795 deserialized = self._deserialize("SearchDocumentsResult", pipeline_response)
    797 if cls:

HttpResponseError: () Invalid expression: Sorting on literal values is not supported in $orderby.
Parameter name: $orderby
Code:
Message: Invalid expression: Sorting on literal values is not supported in $orderby.
Parameter name: $orderby

Thanks for sharing.
The error comes from the service side.
Please open a support ticket for investigation assistance.


Treat warning as errors globally in web

The only exception is web-widgets, which are all deprecated but suppressing this deprecation via annotation won't do a good service to users (and there's no way in modern Kotlin tooling to ignore this warning only).
The other change  useExperimentalAnnotation in build (which is going to be deprecated) with recommended optIn option

since https://github.com/JetBrains/compose-jb/pull/1803 was merged,  can this pr be closed?


Set SOVERSION=2

Closes #71

ping @wjakob

The issue you've pointed out is fairly specific to the setup with Numba and not relevant for the use case of most packages that recursively include this repository (where it is simply easier to have a bunch of plain .so files). Can't you just set SOVERSION yourself from a parent project?

This change is innocuous, and just mimics upstream packages as much as possible.

That is understood -- but the role of this repository is not to mirror upstream, but to package up TBB in a way that makes it convenient to use recursively as a git submodule, within a larger CMake-based build system of a parent project. I'll close this, I don't think it makes sense to include here.

ok that's not the goal of the repo. but if it helps packaging it doesnt hurt to include this one-liner.

would you reconsider, please ?

How about making it an optional feature that is default-off?
Thanks,
Wenzel
On Wed, Sep 2, 2020, at 9:02 AM, Julien Schueller wrote:

would you reconsider, please ?

—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub https://github.com/wjakob/tbb/pull/72#issuecomment-685386452, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJF3LJCGQMXAMZR5KDO7ZDSDXUY7ANCNFSM4QF7TM3Q.

yes, why not

How about TBB_SET_SOVERSION?

ok

Merged, thanks!


MusicXML Support

Proposal
Add support for reading and authoring MusicXML.
Support for markers will be the main priority.
Considerations
A bit of testing is needed to determine if precise timing information can be derived.

There is a possibility that it may be a fairly lossy format.
It's also not totally clear whether MusicXML supports a novel 'marker' element type. It appears be treated as generic text which means that various DAWs may encode or interpret it differently.
In practicality, using MusicXML may not be as worthwhile as other potential formats.

Preliminary Observations
For example, a MusicXML xml file exported from Digital Performer 10 is summarized below.

It contains two markers: one at 1:00:00:00, and another at 1:00:01:00
DP exports markers as Direction markings. The <direction> element with inner element <words> are used.
Similar to a MIDI file, it contains tempo, time signature, and PPQ information.
However, no frame rate or origin timecode information is included and would need to be supplied separately by the user.

<?xml version="1.0" encoding="UTF-8"?>

<!DOCTYPE score-partwise PUBLIC "-//Recordare//DTD MusicXML 3.0 Partwise//EN" "http://www.musicxml.org/dtds/partwise.dtd">

<score-partwise>
	<identification>
		<creator type="composer">Steffan Andrews</creator>
		<rights>© Steffan Andrews</rights>
		<encoding>
			<software>Digital Performer 10.13 86175</software>
			<encoding-date>2021-02-06</encoding-date>
			<supports attribute="new-system" element="print" type="no" value="yes"/>
			<supports attribute="new-page" element="print" type="no" value="yes"/>
			<supports element="accidental" type="yes"/>
			<supports element="beam" type="yes"/>
			<supports element="stem" type="no"/>
		</encoding>
	</identification>
	<part-list>
		<part-group number="2" type="start">
			<group-symbol>bracket</group-symbol>
			<group-barline>yes</group-barline>
		</part-group>
		<score-part id="P0">
			<part-name>MIDI-1</part-name>
			<part-abbreviation>MI.1</part-abbreviation>
		</score-part>
		<part-group number="2" type="stop"/>
	</part-list>
	<part id="P0">
		<measure number="1">
			<attributes>
				<divisions>480</divisions>
				<key>
					<fifths>0</fifths>
					<mode>major</mode>
				</key>
				<time>
					<beats>4</beats>
					<beat-type>4</beat-type>
				</time>
				<staves>1</staves>
				<clef number="1">
					<sign>G</sign>
					<line>2</line>
				</clef>
				<transpose>
					<diatonic>0</diatonic>
					<chromatic>0</chromatic>
					<octave-change>0</octave-change>
				</transpose>
			</attributes>
			<note>
				<rest measure="yes"/>
				<duration>1920</duration>
				<voice>1</voice>
				<staff>1</staff>
			</note>
			<direction placement="above">
				<direction-type>
					<metronome>
						<beat-unit>quarter</beat-unit>
						<per-minute>120.00</per-minute>
					</metronome>
				</direction-type>
				<offset>-1920</offset>
				<voice>1</voice>
				<staff>1</staff>
				<sound tempo="120.00"/>
			</direction>
		</measure>
		<measure number="2">
			<note>
				<rest measure="yes"/>
				<duration>1920</duration>
				<voice>1</voice>
				<staff>1</staff>
			</note>
		</measure>

                <!-- ... (snipped: empty measures 3 through 1800 which are identical to measure 2) ... -->

		<measure number="1801">
			<note>
				<rest measure="yes"/>
				<duration>1920</duration>
				<voice>1</voice>
				<staff>1</staff>
			</note>
			<direction placement="above">
				<direction-type>
					<words>Unlocked Marker 1_00_00_00</words>
				</direction-type>
				<offset>-1920</offset>
				<voice>1</voice>
				<staff>1</staff>
			</direction>
			<direction placement="above">
				<direction-type>
					<words>Locked Marker 1_00_01_00</words>
				</direction-type>
				<offset>-960</offset>
				<voice>1</voice>
				<staff>1</staff>
			</direction>
		</measure>
		<measure number="1802">
			<note>
				<rest measure="yes"/>
				<duration>1920</duration>
				<voice>1</voice>
				<staff>1</staff>
			</note>
			<barline location="right">
				<bar-style>light-heavy</bar-style>
			</barline>
		</measure>
	</part>
</score-partwise>

References
https://github.com/w3c/musicxml/blob/799e2defb2ece0ae7bafe08dcbcac25b2c631d53/schema/direction.mod#L83-L97
https://github.com/w3c/musicxml/blob/799e2defb2ece0ae7bafe08dcbcac25b2c631d53/schema/direction.mod#L117-L127

Update: Importing the above xml file into Cubase does not import any text or marker events.
So the theory is correct that there is no standard MusicXML event type for a marker.


⚠ Bofrost.de has degraded performance

In e73b9d9, Bofrost.de (https://www.bofrost.de) experienced degraded performance:

HTTP code: 200
Response time: 1447 ms

Resolved: Bofrost.de performance has improved in 1dacf65 after 25 minutes.


Universal test inputs and outputs file format

As we discussed during the meeting, it would be nice to define the file format for test_inputs and test_outputs.
I was thinking that we can use a raw formats that are commonly used to store ND-array (represent the ND array with its raw bytes, shape and dtype).
After some research, I actually think that we should perhaps stick with the npy or npz. The main reason it that the format has been supported in many languages including:

native support in numpy/Python
Java: https://deeplearning4j.org/api/latest/org/nd4j/linalg/factory/Nd4j.html#createFromNpyFile-java.io.File-, https://github.com/JetBrains-Research/npy
Javascript: https://gist.github.com/nvictus/88b3b5bfe587d32ac1ab519fd0009607, https://github.com/mrjj/npyz, https://github.com/aplbrain/npyjs

For simplicity, I propose with the uncompressed format npy for now, potentially later we can additionally support npz in a future version.

I really doin't get why tiff is not the first choice. I can accept .npy and/or .npz, but essentially all tools support tiff and we should too (only my opinion).

The reasons for avoid using tiff files are: 1) tiff is more like a container with many variations that can yield different results with different readers 2) we cannot use tiff to store test_outputs for, e.g. classification models that output labels. with npy we can handle arbitrary dimensions.

just throwing this in: an alternative could be hdf5

For hdf5, the numpy team have some discussion here about why they go for npy rather than use HDF5: https://numpy.org/doc/1.13/neps/npy-format.html#alternatives
If you read the specification of npy, it's basically consists of a header with meta info and the raw bytes. In any language, one can easily write a reader (see a js example). It's much simpler and consistent than tiff and hdf5, i.e. we won't need further documentation about how the ndarray is represented as tags in tiff or files in hdf5.

If you read the specification of npy

Very interesting. The fact that libhdf5 is

decision in today's bioimage.io meeting:

test_inputs/outputs as .npy
add field sample_inputs/outputs where any format, e.g. .tif and .csv are allowed


[dsnsd-server] support handling of "A record" queries

This commit adds support for responding to "A record" queries in the DNS-SD server and the discovery proxy.
If the query is resolved by SRP (i.e., the hostname matches a host on the SRP server), the host's IPv6 addresses are returned in the Additional Data Section. When resolved by proxy, the otPlatDnssd APIs are used to start/stop IPv4 address resolvers for the name on the infrastructure network.
This commit also adds helper methods to detect if an IPv6 address follows the IPv4-mapped IPv6 address format using the ::ffff:0:0/96 prefix (e.g., ::ffff:<IP_ADDRESS>) and parse or or construct such addresses.
Unit test test_dnssd_discovery_proxy and test_ip_address are also updated to check the newly added functionalities.

This PR currently contains the commits from https://github.com/openthread/openthread/pull/9362.

Closing this PR in favored of the updated one in https://github.com/openthread/openthread/pull/10364.


feat: Allow users to select system as a theme option

Description 📝

Allow users to select system as a theme option to use their system's theme

Preview 📷
https://user-images.githubusercontent.com/115251059/224392649-7fed124b-06be-447d-9e7b-2848d97d6830.mov
How to test 🧪
Tests

yarn test LinodeTheme

Manual Testing

Test theme switching on the /profile/settings page
Verify that the selection persists when the page is reloaded

I know you didn't initially write this, but we should really be removing the listener on componentWillUnmount

+1 since I love websites that have this option. I also wonder whether it might be better to have a radio group (or even a toggle button) here instead of a dropdown:

If there are 3 or fewer items to select, use radio buttons rather than drop-down menus.
-Storybook

@hkhalil-akamai That's a good point. I went with a Select because that seems to be standard on other websites/apps i've used.

Updated to use Radios
https://user-images.githubusercontent.com/115251059/224830530-84675f4f-0bb6-4d23-8e9f-3c3afd578f80.mov


radio_buttons + label:false not working

when using as: :radio_buttons, label is present event if label: false is added.
Current behavior
= f.association :service, collection: Service.all, as: :radio_buttons, label: false
=> Label is still visible
Expected behavior
=> Label is removed

Could you please provide us a sample application that reproduces the issue in isolation?
That would help us find the issue.

@yshmarov I know this is months old, but I think I had the same issue you did. SimpleForm renders vertical_collection inputs with a <legend> element instead of a label, even though it will use the label's text. If you replace your line:
f.association :service, collection: Service.all, as: :radio_buttons, label: false

with this:
f.association :service, collection: Service.all, as: :radio_buttons, label_text: false

I'm willing to bet it'll fix the problem you had.

I have the same issue, and the suggestion above half-fixes it. It empties the <legend> element, but does not remove it from the generated HTML. Whilst you could style the legend to have zero size or display: none, it would be nice for it not to be there in the first place when using label: false

Had the same problem.
@davelens' workaround makes the labels disappear, thanks.
@pacso's comment is true, the empty <legend> elements disrupt my layout ever so slightly, but it's better than the labels.

Hey! It would be hard to make label: false work here since vertical_collection wrapper doesn't use label component but label_text one. To make legend disappear when label_text: false you can add unless_blank: true option to the wrapper here https://github.com/heartcombo/simple_form/blob/21148b319bc9740af7580ecc44826df7bf5c5fcc/lib/generators/simple_form/templates/config/initializers/simple_form_bootstrap.rb#L82. So it'll look like this:
b.wrapper :legend_tag, tag: 'legend', class: 'col-form-label pt-0', unless_blank: true do |ba|
  ba.use :label_text
end


cy.create() 500 error - Laravel 8

Hello,
I'm new to cypress and trying to following the README and create a user via the cy.create() method but I continue to get 500 errors.
I wish I could provide more error details but I can't seem to get the specific error. Even setting {failOnStatusCode: false} inside the Cypress.Commands.add('create' method does not provide more information, it just skips the error and moves on.
Laravel: 8.11.2
Cypress: 5.6.0
laracasts/cypress: 1.1
Inside my login.spec.js file
describe('Login', () => {
    before(() => {
        cy.refreshDatabase().seed();

        cy.create('App\\Models\\User', {
            name: 'Mike Fake Person',
            email<EMAIL_ADDRESS>            password: 'superawesomepasword',
            timezone: 'America/Los_Angeles'
        })

    })

    describe('with valid credentials', () => {
        it('works!');
    });
});

I get the following error in cypress:

I've also tried a few other models just in case but it continues to error.
I have verified the cy.refreshDatabase().seed(); is running correctly and all seed records are seeding so I assume the connection is working.
Is this possibly due to laravel 8's changes in how factories are handled?
Thanks!

Okay, I got it to work but after some hacky fixes to the CypressController@factory method..
I had to ucwords the model request input as i'm not sure why but it was lowercasing the passed in model to App\models\user:
I also had to ensure I passed in the times parameter as I would get the following error: TypeError: Argument 1 passed to Illuminate\Database\Eloquent\Factories\Factory::times() must be of the type int, null given
I'm not sure if I should send in a PR for the ucwords fix as no-one else seems to have had this issue but I'll keep this issue opne for you to verify.
This is what my CypressController@factory method now looks like:
    public function factory(Request $request)
    {
        return $this->factoryBuilder(ucwords($request->input('model')))
            ->times($request->input('times'))
            ->create($request->input('attributes'));
    }


Bump to version 0.14.0

Coverage remained the same at 94.171% when pulling 448ae1fb925d64b7fe489ad64c994eeeebe64cb4 on philipc:ver into 41ea3a8939d6a51e373bad259f9c92beaada2980 on gimli-rs:master.

I'll publish now, then write up some release notes :)

https://users.rust-lang.org/t/gimli-a-lazy-zero-copy-parser-for-dwarf-debugging-information/7348/13
https://www.reddit.com/r/rust/comments/6sfjxt/announcing_gimli_v0140_gimli_is_a_blazing_fast/


Question about firstConsecutiveStaticIP param

Is this a request for help?:
I have a question about firstConsecutiveStaticIP parameter.
Due to the fact we re-use a subnet from another Resource Group, we do not control the IP addresses allocation.
Can the parameter above be dynamic according to the subnet?
Is this an ISSUE or FEATURE REQUEST? (choose one):
no
What version of acs-engine?:
v0.5.0
Orchestrator and version (e.g. Kubernetes, DC/OS, Swarm)
Kubernetes

I too would be interested in some additional documentation around the firstConsecutiveStaticIP. Either way, great job on this project!


Tagging decorators

Function tagging may be very beneficial for many reasons.
It may simplify to benchmark something on multiple functions, may help creating unusual relationships between functions.
The topic is wide, so probably not one decorator may be used. Of course we may need to add few non-decorator functions to fully utilize it.

I would appreciate some help with tagging, I need ideas for use cases


parameters destructuring is failing

module.exports = function Handler(productsRepo) {
  this.handle = async function({ message } = ctx) {
    ctx.success()   // <-- Fails here
  }
}

Error:
 ReferenceError: ctx is not defined
     ReferenceError: ctx is not defined
     at Handler.handle

@igorshapiro This is expected behavior
The function definition above destructures ctx into a message variable instead of assigning ctx itself. The = ctx part is just a default parameter assignment but ctx itself is still not defined anywhere.
I think what you are attempting to accomplish here can somewhat be achieved using:
this.handle = async function({ message, ...ctx }) {

This will destructure message and put the rest of the fields into a ctx variable (the ctx variable will not contain message though)

Thanks @tomeresk . Closing this


Traffic Shaper TCP (ACK only) catches all tcp traffic

Issue is referenced in this thread on the forums: https://forum.opnsense.org/index.php?topic=6004.0
Describe the bug
The traffic shaper protocol option "TCP (ACK packets only)" captures all tcp traffic instead of only ACK packets. The inverse is also true for "TCP (Non-ACK packets)"
To Reproduce
Steps to reproduce the behavior:

In Traffic Shaper>Settings create an upload pipe less than ISP bandwidth on WAN interface.
Create a rule pointed at the pipe with protocol TCP (ACK packets only) selected
Apply the rule and reset states
Run an upload or speedtest

Expected behavior
Only TCP ACK packets are captured and forwarded
Environment
OPNsense 20.1.1 (amd64, OpenSSL).
Intel i5
igb and em NIC drivers

Counters are running on my end (speedtest slows down as well).
# ipfw show | grep tcpflags
60003 34280 36812136 pipe 10000 tcp from any to any tcpflags ack via le1 // wan: 5 Mbps

# ipfw show | grep tcpflags
60003     98      5660 pipe 10000 tcp from any to any not tcpflags ack via le1 // wan: 5 Mbps

Forgive my ignorance, Does this mean you've reproduced the issue?

No problem, I couldn't reproduce it at my end, matching the traffic seems to be working fine on my machine.  You probably have to dig a bit deeper in ipfw to inspect if traffic is matching or it's accidentally being affected by one of the other rules.

Let me clarify a difference from my original post; I forgot to mention I'm using a weighted queue between the pipe and rule. I have the tcp ack only targeting a queue which is then fed to the upload pipe I set for 5Mbps to ensure ack packets always have bandwidth. These are now the only rule and queue for the pipe. Swapping the target for the high priority queue from the 5Mb priority upload pipe to the 40Mb lan upload pipe makes the speedtest show the correct bandwidth. Disabling the ack only rule also shows the correct 40mbps on the speedtest. only when I'm pointing the rule and queue at the 5mb pipe am i seeing the speedtest drop to 5mbps. I admit, I could be mistaken but i don't think the speedtest only uses ack packets. dslreports.com/speedtest

I'm also seeing the exact same issue, I have a weighted setup, one pipe down and one up. 1, 50 & 100 weighted queues for each direction. Rules direct traffic to the appropriate queue as per their priority. ACK packets are directed to the high priority queue.
I've got HTTP & HTTPS rules which aren't doing anything, because the TCP(ack only) rule takes all the traffic.
Using OPNSense version 20.1.6

I'm also seeing this exact issue with OPNsense 20.1.7

Quick update, After digging through the forum https://forum.opnsense.org/index.php?topic=17372.0
to Summarize

it matches all tcp traffic with ACK set, which is indeed most of the traffic.
M0n0wall used the same technology (tcpflags in ipfw), but offered the option to select or deselect any of them.
It was added a very long time ago (https://github.com/opnsense/core/issues/528), but doesn't look very useful indeed.
There are a couple of options, open a feature request to add flags as an option, so you can select which ones need to be set, maybe accompanied by a switch to expect exactly these flags (negate the rest).
Selecting both which must be set and which may not be set (like m0n0 did) could also be an option, but in our layout can be a bit confusing.
The other option is to fix the flags on this option to something more logical (tcpflags ack,!psh ?)

The current code:
Code: [Select]
tcpflags ack
Ad suggested:
Code: [Select]
tcpflags ack,!psh
which I think would be an improvement.
My suggestion would be to try and narrow it down to packets doing nothing but ack by excluding larger payloads. E.g.:
Code: [Select]
tcpflags ack iplen 52

#4132 addresses this issue and there are workarounds posted in the comments until/if the change is merged


Building on linux

I'm trying to build on Ubuntu 16.04, but the cmake file for finding the api is proving to be a challenge. Because the api doesn't provide a cmake install target (at this rate I'm considering making a PR for one), I'm trying to trick your file into thinking the api is accessible. So far I managed to get the libraries to be found with
sudo mkdir -p /opt/local/lib
sudo ln -s ~/s2client-api/build/bin/ /opt/local/lib/sc2api

but the includes fail to be found using the same method. Reading through the cmake file it seems like you expect the sc2api and sc2utils directories to be found in one of
"/opt/local/include"
"/usr/local/include"
"/usr/include

(plus any directories cmake has defaulted in). And yet I still get failures for finding the first set of  includes after doing
sudo mkdir -p /opt/local/include
for i in ~/s2client-api/include/; do sudo ln -s $i $(basename $i); done

I realized that I'll further need to add the protobuf includes since they're generated and build into the build directory, but I can't even get past the first find_path. Do you have any ideas?

Apologies but I have not yet tested the bot on Linux. I will leave this issue open in hopes someone else can help you with the issue.

Hi @kuzi117 ,

for i in ~/s2client-api/include/; do sudo ln -s $i $(basename $i); done

Probably 'ln' is a problem here. Does it fails if you copy all headers directly?
For additional info, I have the following directory structure for sc2api and it works:
alkurbatov@Vika:local/include $ ls /opt/local/include/sc2utils
sc2_arg_parser.h            sc2_manage_process.h        sc2_property_reader.h       sc2_scan_directory.h        sc2_simple_serialization.h

alkurbatov@Vika:local/include $ ls /opt/local/include/sc2api
contrib/                  sc2_args.h                sc2_coordinator.h         sc2_map_info.h            sc2_typeenums.h
proto/                    sc2_client.h              sc2_data.h                sc2_proto_interface.h     sc2_types.h
sc2_action.h              sc2_common.h              sc2_game_settings.h       sc2_proto_to_pods.h       sc2_unit.h
sc2_agent.h               sc2_connection.h          sc2_gametypes.h           sc2_replay_observer.h
sc2_api.h                 sc2_control_interfaces.h  sc2_interfaces.h          sc2_score.h

alkurbatov@Vika:local/include $ ls /opt/local/include/sc2api/contrib/protobuf/src
Makefile.am  README.md    google/      solaris/

alkurbatov@Vika:local/include $ ls /opt/local/include/sc2api/proto
common.pb.cc   data.pb.cc     debug.pb.cc    error.pb.cc    query.pb.cc    raw.pb.cc      sc2api.pb.cc   score.pb.cc    spatial.pb.cc  ui.pb.cc
common.pb.h    data.pb.h      debug.pb.h     error.pb.h     query.pb.h     raw.pb.h       sc2api.pb.h    score.pb.h     spatial.pb.h   ui.pb.h

Please also apply the following pull-request to fix several linux build problems:
https://github.com/davechurchill/commandcenter/pull/11

@alkurbatov I'll try copying them directly, though I figured it if it was working for the kind it would've been ok. Will report back.

Turns out after I looked a little bit harder I realized that I misread the stack trace cmake gave me and it actually had found the sc2api directory after using ln. Even still it seems like ln is not the way to go with this because it involves adding links to directories that shouldn't have them. E.g. adding the path to the protobuf generated headers at s2client-api/build/generated has to be linked into s2client-api/include/ which doesn't seem like it should be done. The protobuf stuff also needs to be relocated.
I noticed something kind of odd @davechurchill:
# Find Protobuf headers.
find_path(SC2Api_Protobuf_INCLUDE_DIR
    NAMES
        "google/protobuf/stubs/common.h"
    PATHS
        "${SC2Api_INCLUDE_DIR}/sc2api/contrib/protobuf/src"
)

I assumed that you were trying to follow the format of the precompiled headers provided by the api repo, but their doesn't exist a path such that the directory resolving to ${SC2Api_INCLUDE_DIR} contains sc2api/contrib/protobuf/src. Now that I look at it again, it's true for the previous find_path as well. Any insight as to how you came up with these paths? The precompiled headers don't have those paths and the files generated by cmake don't exist at those paths either.

Have you looked at my directory listing above? It contains everything regarding headers directory structure.
The current layout was selected just because it looks more or less ok nothing more. The protobuf sources were copued from sc2apy (look at contrib folder carefully) just because it simplier then pick each header one by one or search for proper protobuf version. The latter could cause additional problems if blizzard team will modify their copy of protobuf.

@alkurbatov Yes, I know the structure above works, I'm just saying it seems like unnecessary work. I don't have a better suggestion right now. I asked about the paths chosen because I wanted to know if there was more reason behind it than arbitrary paths because it looks "ok".

The problem here is lack of 'install' target in sc2api and requirment to have 'generated' headers and some 'protobuf' headers on the same level as the sc2api headers. I preserved the folders structure more or less similar to the sc2api just to avoid mixing headers in one folder.
**/lib (not lib64) was selected because OS X doesn't have lib64 folders while for Linux it should be lib64 definitely. /opt was selected just because I like macports approach :)
Please feel free to adjust the build to Linux specifics. The pull-request will be highly appreciated.

That will be the best solution and we can fix this findSC2Api.cmake too. Probably we should even include it into the upstream repo because it is not project specific.
Feel free to ask.

My intention was to have it merged into the blizzard repo, yes.

Hey @alkurbatov, could you test out the install on this fork here? https://github.com/kuzi117/s2client-api

Also this doesn't look right:
alkurbatov@Vika:s2client-api/build ‹master›$ ls tt/usr/local/lib/cmake/SC2API/SC2APIConfig.cmake
tt/usr/local/lib/cmake/SC2API/SC2APIConfig.cmake

This macros should be placed among other similar related cmake things otherwise a user must explicitly specify where to get it.

And another  one small moment. You use the following string:
find_package(Protobuf REQUIRED)
Which version of Protobuf I need to install? As far as I know sc2api use specific submodule for it which means specific version not just random Protobuf from macports or rpm repo.

Ok, responding in order of comments:
I'm not sure what the DESTDIR assignment does. Are you trying to change the install directory? I believe you should be using -DCMAKE_INSTALL_PREFIX="/path/to/install". Also the error that occurs there is the civetweb trying to install its binary. I just realized I forgot to give you a heads up about something that needs to be done first. The tags used in the contrib folder are... out of date. I fixed the installing binary issue, so I believe if you cd to contrib/civetweb` and checkout master it should be fixed. Similarly, protobuf is using a tag from over a year ago. Checkout master as well there to get a fix for cmake. There's a better solution that checkouts a specific commit but I'm waiting on blizzard to update the main repo.
The relative path is calculated at install time and should point to where the headers are installed (I can point you to the cmake code that makes this file). If it doesn't I'd be both very surprised and very happy to find this problem now. I agree that setting everything into a single library variable is a bit heavy-handed. I mostly wanted to see that this works first, we can absolutely add variables that separate things better if this works to begin with.
You don't need to install protobuf. The correct version of protobuf is already installed as part of the installl process for s2client-api. I should probably include a version argument to match the version we've installed just before us but I haven't looked into it yet. If this is the sticking point for everything I'd be glad that it's only this.

DESTDIR is a usual way to test 'make install' command and don't pollute system folders (it is supported by the make utility itself). Cmake install prefix can be used here but I prefer destdir due to historical reasons. Actually both approaches can be used simultaneously.
Regarding protobuf lets check it after we will have working 'make install'. Probably I am wrong here.
Same for relative path.
Regarding submodules: which commit I need to checkout or it is ok to checkout from master?

I didn't know that. I'll be honest, I have no idea what sort of effect DESTDIR has on the results of the make install. If you know what you're doing that's fine, my only concern is that the SC2APIConfig.cmake won't find be found by a find_package in an importing cmake file. Can you add that directory to the search path for cmake? I'm worried this might obfuscate problems with a a real install for you, but I suppose we can deal with that after making sure you can link against it.
Go ahead and checkout master. That's what I have currently and it's working for me. If that doesn't work then I can grab specific commits to checkout.

DESTDIR is for testing purposes only and dont break anything. Actually it allows me to test and make proper installation after the tests without recompilation of the whole api (which I have to do for cmake install prefix). This is just good-old approach from the unix world :) I will do proper make install when it will be time to test compilation with the installed api.
Ok I'll try tomorrow.

I've updated protobuf and civetweb but still have the same error in civetweb during install.
The problem is in submodule itself, see this extract from .gitmodules:
[submodule "contrib/civetweb"]
        path = contrib/civetweb
        url = https://github.com/KevinCalderone/civetweb

Seems that Blizzard use its own fork of civetweb which don't have your fixes. Which commit should be applied? I'll cherry-pick it manually.

You're right, I've confused myself this time. Here's the PR: https://github.com/civetweb/civetweb/pull/506/commits

Now it works, looks good.

Thank you all for going so deep into this :)

Sorry, we're probably spamming you with notifications.
@alkurbatov Does it work for importing as well or are you just saying it builds and installs now?

@kuzi117 Import works too, I've checked on the clean environment.
The only two minor suggestion here:
a. Add a 'status' message regarding sc2api found. Right know it prints nothing during cmake phase.
b. Include path is really complex :) /usr/local/lib/cmake/SC2API/../../../include/sc2api

I'd love to add a message saying something like "Found SC2API version x.x.x", but I don't think there's a version string anywhere I can get at.
I'm trying to test out an addition to the config but I'm getting the errors in https://github.com/Blizzard/s2client-api/issues/108. I've pushed a change that makes the path absolute, though I feel like it should actually be done a different way. Would you mind testing it now?

I believe it will be enough to print "Found SC2API", we don't need the version numbers because the api has no numbers right now. The only thing that could be used at this point is a hash of the last git commit.
The path looks good now:
/usr/local/include/sc2api

Generally I've seen those messages as part of the including cmake rather than the included. This is because find_package creates a variable for the includer called <package name>_FOUND.
So a user of the api would include the API as:
find_package(SC2API REQUIRED)
message(STATUS "Found SC2API: ${SC2API_FOUND}")
include_directories(..)

If you really think it's a good idea I can add it no problem. Also, what version of Mac are you using so when I make this into a PR I can notify them where it's been tested.

Usually it is cmake 'find' macro that print such message, not the user.
In general this is cosmetic moment, I can just enable trace in cmake or print all the variables manually, but probably somebody who don't know cmake could stuck.Because it is just an assumption you are free to decide. This message could be added anytime.
      System Version: macOS 10.12.6 (16G29)
      Kernel Version: Darwin 16.7.0

Thanks. I'll notify you if I make any significant changes.


Fix Unix installation instructions, fixes #238

Adding missing ./bootstrap command before running ./configure,
whether the instruction is still "usual" or not is left intact.
Signed-off-by: Ｖ字龍<EMAIL_ADDRESS>

The very fact that this would not be "usual" should have tipped you off. This is not only completely unnecessary and wrong advice, but also described in detail further down the README for the only case when it is needed (compilation from git).

Thanks for pointing out, I've stopped reading the README further once I found the "Installing from sources/Unix" section.
I would suggest to somehow improve the README by specifying those subsections only applies to released source tarballs, though.

I would suggest to somehow improve the README

No, sorry, there is absolutely nothing wrong with the README, it explains everything. The section does apply to git checkouts, but another section also applies. No amount of "somehow improving" the README will help when people ignore the file's content in the first place!
No, the only problem here is this:

I've stopped reading the README

That you did that, and that you didn't return to finishing it as soon as you hit problems, is something I just don't understand.


Mcs 648 downloader

Not ready for review.

So cool.
>>> import machine_common_sense as mcs
>>> controller = mcs.create_controller()
MCS-AI2-THOR-Unity-App-v0.4.3-linux.zip: |####################################################|100%  24.2 MiB/s of 775.MB

We should make it clear in the docs that you can provide your own unity build file or continue doing things the way we've been doing it. This change is an easy-button option if researcher don't want to manage the downloads.


a

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

@umairmehmoodnn I'm closing this PR because it seems to contain changes for your own experimentation, which should be done in a fork of the repo and not the original one. Thanks.


checkDocument does not respect the viewport size

I expect to see the same image sizes, but browser.checkDocument does not agree with me :)

Yep, my team mates noticed this issue also for chrome. I think that this happen due to Ì used windowHandleSize instead of setViewportSize.

Thanks to @PM8668 for this fix.
Released with v0.5.0.
@monolithed let me know if this solves your issues.


Added random-uniform-like operation on TensorMaps

:books: Documentation preview :books:: https://equistore--196.org.readthedocs.build/en/196/

The linter is failing! You can run it locally with tox -e lint, and reformat the code automatically with tox -e format

Ok, thank you for the response, I will do the changes

Some tests are failing because since 1a495992d6d6e82cc508fed4926a91babea311ac
equal does not have only_metadata anymore, but you have to use
equistore.equal_metadata

I was actually thinking to add another way of generating random array, namely with a gaussian distribution. Should make it in a separate file or put inside the random_like.py ?


Vagrant support

Add the files to create and configure a pump.io instance on an Ubuntu VM. pump.io is not started, but is all configured to run with mongodb and on port 8000.

@ocasta sorry this was closed; I'm not sure why. If you want to come back and try this again based on the work here, we'd love to have it. See #1302


New version: Polymers v0.3.6

Registering package: Polymers
Repository: https://github.com/sandialabs/Polymers
Created by: @github-actions[bot]
Version: v0.3.6
Commit: c977b84d921019b3731b2c6cce2537e1d03ebcef
Reviewed by: @github-actions[bot]
Reference: https://github.com/sandialabs/Polymers/commit/c977b84d921019b3731b2c6cce2537e1d03ebcef#commitcomment-119139250
Description: Polymers Modeling Library

f

[noblock]


Fixed navbar in free E-books Page

Fixes:  #1682
Description
Fixed the alignment of contents in the navbar of the Free E-Books Page.

[x] I have made this change on my own.

[x] My code follows the style guidelines of this project.
[x] I have performed a self-review of my own code.
[x] I have made corresponding changes to the documentation.
[x] My changes generate no new warnings.
[x] I have tested the changes thoroughly before submitting this pull request.
[x] I have provided relevant issue numbers and screenshots after making the changes.

Hey!! @RitiChandak Please check the changes I have made and let me know if any other customizations are needed.
Regards,
Tanishka
Checklist:

Hey!! @RitiChandak Please check the changes I have made and let me know if any other customizations are needed.
Regards,
Tanishka

Fixes #1682


Docs: Add user documentation for view the list of installed Bots feature

Automated message from Dropbox CLA bot
@anirudhjain75, it looks like you've already signed the Dropbox CLA. Thanks!

@anirudhjain75 I have posted some feedback.

@hackerkid Made the changes suggested

@femnad Made the changes

👍

check this :happy_person_raising_hand:

check this  :happy_person_raising_hand:

I went ahead and fixed this and merged it as 3bd70075c4f3e8a9246eb1966f8e70506717c40c.  Thanks @anirudhjain75!


correctly resolve Symbol of destructuring shorthand intializer

Fixes: #21046

Apart from this can you add testcase in tests\cases\fourslash that verifies quickinfo as mentioned in the issue #21046


terminal cut zsh PROMPT to two lines and not show fully

VSCode Version: 1.3.0
OS Version: OS X 10.11.2
shell: zsh(oh-my-zsh with theme robbyrussell)

Steps to Reproduce:

open a project
CTRL + ` open terminal

actual behavior
PROMPT was cut to two lines and not show fully

expected(iTerm2 example)

Duplicate of https://github.com/Microsoft/vscode/issues/8219


String literal inference not following if/else cases

Bug Report
🔎 Search Terms
String literal if inference
🕗 Version & Regression Information
Tested with latest version in the playground
⏯ Playground Link

Playground link with relevant code
💻 Code
type Updatable = 'foo' | 'bar'

type Foo = { foo: string }
type Bar = { bar: string }

type Events = {
  'foo.update': { foos: Foo[] },
  'bar.update': { bars: Bar[] },
}

type Models = {
  foo: Foo,
  bar: Bar
}

const sendEvent = <T extends keyof Events>(event: T, payload: Events[T]) => {
  // classic dispatch event
}

// ----------cut----------

const testFunction = <T extends Updatable>(event: `${T}.update`, model: Models[T]) => {
  let payload: Events[typeof event];

  if (event === 'foo.update') {
    // here TS should know payload is correct because if event === 'foo.update',
    // then T === 'foo', therefore typeof payload is Events['foo'] which is { foos: Foo[] }
    sendEvent(event, { foos: [model] })
  }
  else if (event === 'bar.update') {
    // here TS should know payload is correct because if event === 'bar.update',
    // then T === 'bar', therefore typeof payload is Events['bar'] which is { bars: Bar[] }
    sendEvent(event, { bars: [model] })
  }
}

// typing works!
testFunction('foo.update', { foo: '' })

// typing works!
testFunction('bar.update', { foo: '' })

🙁 Actual behavior
There's an issue with type inference related to string literals.
🙂 Expected behavior
Typing should be inferred correctly

This is a duplicate of #27808 and/or #30851.

Without something like #27808, the type parameter T is allowed to be the full union, which breaks your intended constraint. Right now you can do the following call with your code, so the compiler's warning inside the implementation is technically correct:
// typing... doesn't work?
testFunction(Math.random() < 0.5 ? "foo.update" : "bar.update", { foo: "" }); // no error

But even if you can fix it, you'd still run into the problem in #30581.  Let's make testFunction take a union of rest arguments:
type Args = { [T in Updatable]: [event: ${T}.update, model: Models[T]] }[Updatable]
// type Args = [event: "foo.update", model: Foo] | [event: "bar.update", model: Bar]
const testFunction = (...[event, model]: Args) => { /.../ }
testFunction('foo.update', { foo: '' }) // okay
testFunction('bar.update', { foo: '' }) // error
testFunction(Math.random() < 0.5 ? "foo.update" : "bar.update", { foo: "" }); // error
Now the call side is safe, but the compiler still has no idea inside the implementation that the types of event and model are correlated the way you want:
const testFunction = (...[event, model]: Args) => {
  let payload: Events[typeof event];

  if (event === 'foo.update') {
    sendEvent(event, { foos: [model] }) // error! Foo | Bar not assignable to Foo
  }
  else if (event === 'bar.update') {
    sendEvent(event, { bars: [model] }) // error! Foo | Bar not assignable to Bar
  }
}

You can work around this by using a single args rest argument as a discriminated union without destructuring it:
const testFunction = (...args: Args) => {
  if (args[0] === 'foo.update') {
    sendEvent(args[0], { foos: [args[1]] }) // okay
  }
  else if (args[0] === 'bar.update') {
    sendEvent(args[0], { bars: [args[1]] }) // okay
  }
}

Now everything works, but it's weird looking.

@jcalz Thanks so much for the explanation. It's really nice and with examples. Thank you :)
For what you wrote on Args:
type Args = { [T in Updatable]: [event: `${T}.update`, model: Models[T]] }[Updatable]
// type Args = [event: "foo.update", model: Foo] | [event: "bar.update", model: Bar]

const testFunction = (...[event, model]: Args) => { /*...*/ }

I don't get how it's different from:
const testFunction = <T extends Updatable>(event: `${T}.update`, model: Models[T]) { /*...*/ }

In your version, you manually build a union of arguments that ends in: [event: "foo.update", model: Foo] | [event: "bar.update", model: Bar] but in mine, the only valid outcome are similarly [event: "foo.update", model: Foo] | [event: "bar.update", model: Bar] since the two parameters are bound by the <T> constraint?
Or is it a misinterpretation from my side and actually the <T> constraint results in a larger union for the function's arguments (notably [event: "foo.update", model: Bar] | [event: "bar.update", model: Foo]) ?
Or is it something related to string literals?
Thanks again

See this section:

Without something like #27808, the type parameter T is allowed to be the full union, which breaks your intended constraint. Right now you can do the following call with your code, so the compiler's warning inside the implementation is technically correct:
testFunction(Math.random() < 0.5 ? "foo.update" : "bar.update", { foo: "" }); // no error

That can be called without errors, but you don't want it to be.  The type parameter T is not inferred to be "foo", and it is not inferred to be "bar"... it is inferred to be "foo" | "bar", the full union type to which it is constrained.  And therefore the parameters list looks like [event: "foo.update" | "bar.update", model: Bar | Foo]:
// IntelliSense:
// const testFunction: <"foo" | "bar">(event: "foo.update" | "bar.update", model: Bar | Foo) => void

There is currently no direct way in TypeScript to constrain type parameter T to one of a set of types.  T extends ("foo" | "bar") does not have that effect.  You want to say something like (T extends "foo") | (T extends "bar") but that's not valid TypeScript  This situation what #27808 is about.


Revert ".github/CODEOWNERS: add podman team"

This reverts commit 89b6d5f175e276acdacfdaee2b0bb2e141076ab9.
The team needs write permissions to the repo so it isn't actually useful for us.

How do you mean that it's not useful?

I still don't see any harm in keeping the entries.

Sure, I guess it doesn't hurt.


[8.x] Adds onFail parameter to validate method

This allows us to pass a closure, so in case the validation fails we can run some code to log something or raise an event.
(It also encourages functional style) The way the validation exception is currently caught in Exception class is only good to set a global handler for all validations errors, but if we want the code to be run for only one validation, it would be problematic.
Example Usage:

Notes:
1- Obviously it is not fully backward compatible since the contract signature changes, but it is rare that anyone has a custom implementation.
2- I will add the needed tests if accepted.
3- $onFail can also be called by App::call(), instead of $onFail($this); so that it would be more flexible.
4- It can be rewritten like below, but I did not do it so that it was easier to judge the changes. (Taylor may do it if he likes to)

Changing a contract is a major breaking change. As such, I have re-targetted this at 8.x.

Tbvh I think this is a bit overkill here. Just catch the exception and do any validation you need.

@driesvints I mentioned catching the exception is good for setting a global handler.
What if we want to only run the callback for only one specific validation?
It is possible, but it requires setting and checking flag variables on both sides, which is crappy.
Or extending the Validation exception class and catch the subclass, the problem is the on Fail logic is no longer in front of our eyes in the controller, and will live in the Exception class.
I do not know if there is an elegant way.

I am with @driesvints here. But if it were to stay, I would vote for something like onValidate() so we know there is an ability to be called.

@gocanto This somewhat just mimics the javascript Promise Api.

Thanks for your pull request to Laravel!
Unfortunately, I'm going to delay merging this code for now. To preserve our ability to adequately maintain the framework, we need to be very careful regarding the amount of code we include.
If possible, please consider releasing your code as a package so that the community can still take advantage of your contributions!
If you feel absolutely certain that this code corrects a bug in the framework, please "@" mention me in a follow-up comment with further explanation so that GitHub will send me a notification of your response.


specs-go/config: Make consoleSize a pointer

Otherwise we it will never be omitted when empty.  This is the same case as 6323157 (specs-go/config: Make Linux and Solaris omitempty (again), 2016-06-17, #502).

Can we finish the discussion in other PRs until you start opening up more PRs to change other unrelated things?

On Thu, Sep 22, 2016 at 09:14:50AM -0700, Michael Crosby wrote:

Can we finish the discussion in other PRs until you start opening up
more PRs to change other unrelated things?

I'd rather file the issue, and you can tag it priority/P3 if you don't
think it's important.  In this case, I'm fixing code that landed 21
hours ago (#563), so I don't think this one is out of the blue.

I'd forgotten about this one, but the change recently landed via #792.


Pattern Matching for tuples in let isn't work as expected

Hello!
This code works fine (in elm-0.17.1):
import Html exposing (text)

main =
  let
    b = a / 2
    a = 4  -- declarations are in mixed order, but it's fine!
  in text <| toString (a, b)

-- Output:
-- (4, 2)

but this one isn't
main =
  let
    (a, b) = (4, a / 2)
  in text <| toString (a, b)

-- Output:
-- (4, NaN)

There is no warning / compilation errors. And I think what this binding is legal as legal the former one.
Here is an example with strings:
main =
  let (a, b) = ("hello", String.append a " world!")
  in text <| toString (a, b)

-- Output:
-- ("hello", "undefined world!")

Browser: Firefox 49.0
OS: Ubuntu 16.04.1 LTS
Elm version: 0.17.1 (installed from npm)

This is a duplicate of https://github.com/elm-lang/elm-compiler/issues/873 which will be fixed in 0.18.

@astynax can you reopen this on elm-compiler? This is an issue with code generation, not with the core libraries.


Add atg-platform-patching role

Add atg-platform-patching ansible role for installing patches/fix packs on Oracle Commerce (ATG) platform

The role was reviewed by @arno49 preliminarily


Change http://localhost:8080 to http://localhost:8000

Fixes development instructions

@sureshbathala01 please review these changes when you get a chance.


where is prompt_utils_for_llamaguard?

I was running the run_art.sh .But it warned me that there is no module named prompt_utils_for_llamaguard. Could you provide it for me?

Sry, I forgot to upload it. Now, you can find it in the repo.


Tiny readdir glob gitignore

tiny-readdir-glob-gitignore ver

closed by #1414
Tiny readdir glob can not accept file path as glob


Add support for Raspberry Pi Pico

Companion draft pull request to the Firmware side of things. As with the firmware this leverages the amazing work by @elral where he figured out how to use the rpi2040load.exe command to upload firmware to the Raspberry Pi Pico.
Additions to Ralf's work:

Added a new section to the board definition file called PicoToolSettings for the pico-specific flash options.
Added a general purpose DelayBeforeFirmwareUpload setting to control how long to wait for a board to reconnect before trying to flash the firmware.
Use the presence of that new settings block to determine whether firmware should be uploaded using that method.
Added a new method to encapsulate the Pico flash process

This does work, I successfully used it to flash a Pico from 0.0.1 to 2.0.1. It's still draft though.
Questions I have:

Why do people talk about using picotool.exe for this when it's actually rpi2040load.exe that does the work?
Is picotool.exe even needed?
I think this should be called Rpi2040LoadSettings, RunRpi2040Load() etc. instead since that's the actual command that gets run?
Why did I have to leave the extension off of the firmware when passing it to rpi2040load.exe? In Ralf's code he includes .elf on the end of the firmware, but when I did that (even on the command line manually) it got an extra .uf2 added to the end which caused a failure.
Why did Ralf use .elf when as far as I can tell the tool wants the .uf2 version of the firmware? Is that because I never bothered to download the elf2uf2.exe app?

(Side note: this rpi2040load.exe is the most obscure and opaque piece of software I've seen in a long time!!!)

Answering some of my questions...
I found the source for rpi2040load.exe. It's just a wrapper around elf2uf2 and picotool. I'm going to take a pass at updating this PR so it only uses picotool and gets rid of the other two apps.

I've spent a bunch more time on this and unfortunately picotool doesn't seem to handle talking to specific boards by address on my Windows machine. I can't tell if it's just me or some wider issue with the tool, but without direct bus & address support it'll be impossible to pick which attached Pico to flash.
I've opened https://github.com/raspberrypi/picotool/issues/48 on their side, hopefully there will either be a "you're doing X wrong" or "yeah we can fix that" response soon.

Questions I have:

Why do people talk about using picotool.exe for this when it's actually rpi2040load.exe that does the work?
Is picotool.exe even needed?
I think this should be called Rpi2040LoadSettings, RunRpi2040Load() etc. instead since that's the actual command that gets run?
Why did I have to leave the extension off of the firmware when passing it to rpi2040load.exe? In Ralf's code he includes .elf on the end of the firmware, but when I did that (even on the command line manually) it got an extra .uf2 added to the end which caused a failure.
Why did Ralf use .elf when as far as I can tell the tool wants the .uf2 version of the firmware? Is that because I never bothered to download the elf2uf2.exe app?

Unfortunetely I can not answer these questions. I made it very simple, I flashed the Pico from PlatformIO with verbose output and copied what they are doing. I was wondering too why they used the .elf file and it is converted to an .uf2 file. But I didn't make such a deep dive as Neil did (and does).

I've made a ton of progress on this in the last few days. The .elf extension is a debug-enabled version of the code. .uf2 is what we'll want to flash to the device in production.
The rpi2040load.exe app is just a thin wrapper around elf2uf2 (which converts from the debug-enabled firmware to release firmware) and then runs picotool that makes all sorts of (bad?) assumptions. We don't need it.
I was successfully able to build picotool locally this morning and talk to a Pico via device address. The remaining problem is how to discover that device address. According to device manager my pico's address is 5 but according to picotool it is 15.

After two days of digging into this I've given up on finding a way to flash from within MobiFlight. For any connected board (regardless of type, Arduino or Raspberry Pi, doesn't matter) MobiFlight needs to know two things:

What COM port to use when doing serial communication with the device
What address to use when flashing the device

On Arduinos the COM port is the address for flashing. This is obtained by looking in the Windows Registry.
On the Pico the COM port is used for serial communication but the address is a combination of bus number and address that come from libusb. It's highly specific to libusb and its underlying libraries and after two days of investigation the only way I found to get them is to enumerate connected USB devices using libusb.
MobiFlight can successfully get the COM port for Picos during getSupportedPorts(), no problem. The challenge is, somewhere, somehow, getting the bus number and address that matches the device connected at that COM port. Everything I've tried gets me either the COM port or the bus number, not both.
You might think "ok, split the two. Get the COM port and then later on look up the bus number and address". Unfortunately there's no way I can find to make a connection between the two.
Imagine you have two Picos connected, one on COM1 and one on COM2, and you want to flash the second one. How does MobiFlight know after enumerating the bus number and address for all connected Picos that the one at bus 5 address 15 is the device connected to COM2? There's no unique identifier I can find for connected USB devices that could be used to make this link.
So... I'm giving up for now :(

The closest thing I can find that would make this link is LocationInformation in the registry. For my connected Mega 2560 it reports Port_#0003.Hub_#0009.
On the libusb side of things PortNumber is available and matches (it shows 3). I can't find anywhere to get the hub though :(
Soooooooooo close.

Will open a new PR sometime with just the board definition file.


python3 super

Rewrite super() in python3 syntax
Testing Plan:
GIFs or Screenshots:

@timabbott Here is a small patch.


🐛 Plugin Init improvements

What this PR does / why we need it:
This PR contains two fixes for the plugin Init operation:

Get the latest operator version from the list of all available versions
Now we use "latest" tag, but due to recent clusterctl changes it forces to download metadata.yaml file which is not available for CAPI operator. Because of that installation fails with exceeded context deadline. To prevent this we specify a version when we create a repo object, and then pick the latest version from the list of all available versions.

Add a short delay before deploying providers
We have to add a short delay here to ensure that the webhooks are successfully started.

Which issue(s) this PR fixes (optional, in fixes #<issue number>(, fixes #<issue_number>, ...) format, will close the issue(s) when PR gets merged):
Fixes #436
/area plugin

We have run into this issue as well trying to install the operator and then immediately trying to create a coreprovider resource. could this be solved alternatively through a podReadiness probe that waited until the webhook service was up to mark the operator pod as ready?


Implement service level interceptors using InterceptableService

Description:
For the details discussion, refer the original discussion [1].

[ ] Add InterceptableService to http module and get the service level interceptors using this initInterceptors() function.
[ ] Give a warning/compiler error when interceptors are added from both this function and the annotation
[ ] Deprecate the usage of having the interceptors in the annotation (might be provided by the compiler plugin)
[ ] Update the website and other samples

[1] https://github.com/ballerina-platform/ballerina-standard-library/issues/4300

Give a warning/compiler error when interceptors are added from both this function and the annotation,
For this better to give a compile error rather than a warning right? As we cannot decide on a order of the interceptors in the runtime.
@TharmiganK


test(e2e,playwright): unsubscribe page

With this commit, the playwright will test the unsubscribed page with and without passing a random id. This id decides if the page should have a button to resubscribe or not.
Checklist:

[x] I have read and followed the contribution guidelines.
[x] I have read and followed the how to open a pull request guide.
[x] My pull request targets the main branch of freeCodeCamp.
[x] I have tested these changes either locally on my machine, or GitPod.

Refers #51705

camperbot cant code

camperbot cant code

Just now noticed that https://github.com/freeCodeCamp/freeCodeCamp/pull/51749 might fix this. If that is the case, please feel free to close (although this PR has extra checks).
Also, please let me know if there is any other part of this that I can work on. I can see many open PRs for features in https://github.com/freeCodeCamp/freeCodeCamp/issues/51705 and hence will not try to implement anything without a 👍 from the maintainer.


docs: enhance docs by adding version and update date info

Description of change
Enhance the docs
Pull-Request Checklist

[ ] Code is up-to-date with the main branch
[ ] This pull request follows the contributing guidelines.
[ ] This pull request links relevant issues as Fixes #0000
[ ] There are new or updated unit tests validating the change
[X] Documentation has been updated to reflect this change
[X] The new commits follow conventions outlined in the conventional commit spec, such as "fix(api): prevent racing of requests".

If pre-commit.ci is failing, try pre-commit run -a for further information.
If CI / test is failing, try poetry run pytest for further information.

:warning: Please install the  to ensure uploads and comments are reliably processed by Codecov.
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 96.70%. Comparing base (f289992) to head (1697ce4).

:white_check_mark: All tests successful. No failed tests found.
Additional details and impacted files
@@           Coverage Diff           @@
##             main       #2   +/-   ##
=======================================
  Coverage   96.70%   96.70%
=======================================
  Files           9        9
  Lines         577      577
  Branches       91       91
=======================================
  Hits          558      558
  Misses          3        3
  Partials       16       16

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


Rewrite ingress without tls termination example

@vadimeisenbergibm That's too bad. So, let's just merge this one, and then I'll create a PR myself with a few wording tweaks.

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: frankbu
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

content/OWNERS [frankbu]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment


Suggestion: Add additional buffs

This addon looks great but would love to see the ability to have 6 buffs visible instead of the default 3.

thanks for your contribution, this is a good suggestion, but modifying max_buff requires testing more, i will append this func in the next future version, but I can't guarantee the release time.
please pay attention to my curseforge update.

progress: #9


Support to expose host ports via @Testcontainers for JUnit Jupiter

Currently, it is not possible to expose host ports when using the @Testcontainers annotation in JUnit Jupiter due to the execution order of @BeforeAll [1] and the registration order of extensions added with @ExtendWith [2]. A method annotated with @BeforeAll within a test class annotated with @Testcontainers is executed after the @BeforeAll of the Testcontainers extension. If you use another extension such as WireMock in combination with @Testcontainers, the same problem occurs. The documentation [3] notes that exposing host ports should be invoked before containers are started, but after the server is started on the host.
This change adds exposeHostPorts to @Testcontainers and configures it before the containers are started.
[1] https://junit.org/junit5/docs/current/api/org.junit.jupiter.api/org/junit/jupiter/api/BeforeAll.html
[2] https://junit.org/junit5/docs/current/api/org.junit.jupiter.api/org/junit/jupiter/api/extension/ExtendWith.html
[3] https://www.testcontainers.org/features/networking/#exposing-host-ports-to-the-container

@kiview thanks, I'll give it a try and let you know if it works.


chore: limit renovate packages

Attempt for #8503 . First disable all packages under "com.google". Then selectively enable the two artifacts.

Important to know: Renovate will evaluate all packageRules and not stop once it gets a first match. You should order your packageRules in ascending order of importance so that more important rules come later and can override settings from earlier rules if needed.

https://docs.renovatebot.com/configuration-options/#packagerules
The important rule comes later.

The "units" job is queued.


Python version imcompatible with HTSeq

Hi, I'm trying to install scPathoQuant in my server. I used conda virtual environment with python version 3.12.2 and follow the instruction. But the error log indicates that the python version is too old, which comes from HTSeq (as shown below). COuld you help with that question?

Best Regards,
Zhixuan

Hi Zhixuan,
Thanks for the note.  I am going to try and replicate this but wanted to clarify, you mention you ran this on pythn 3.12.2 but your terminal output says you used  python version 3.6.3.  Did you happen to try both python versions?
Thanks!
Leanne

Hi @Zhixuan-Jing,
I was able to replicate the error you had with python 3.6.  Because all the new htseq packages need at least 3.7 I updated scpathoquant to require python 3.8 or greater which was necessary for a couple other dependencies/packages as well. Note that the install instructions are now a bit different than in the previous version.   Hopefully this works better but please let me know if  there are new or other issues! Note that the install instructions are a bit different than in the previous version.


WIP Multi outputs

This is the start of implementing support for multiple outputs (and also similar to implement support for multiple recipes).
Some points for discussion:

evaluate and order the build tree, which is dependent on finding the edges of the tree. The edges can be strongly or loosely connected by a pin_subpackage expression. If the pin_subpackage pins "exact" we might have to build more variants. I am going to create a diagram for this.
The PR takes the recipe with multiple outputs and splits it into multiple recipes. It follows some merging rules:

if the output does not define a version, use the version of the toplevel recipe
Should we make the top-level "name" optional? conda-forge uses it for the feedstock name I think
We merge the keys of the about section, as well as extra and build, although for build the main relevant fields are number, string and maybe script.

Scenario 1 where we have a Python specific libmambapy and a Python specific mamba that are connected by a `pin_subpackage(..., exact=True). In this case we need to expand the matrix, but only for "solveable" combinations (python=3.8 & libmambapy=*=*py38, ...).

Scenario 2 is a bit simpler, here we only have two variant packages on top. The exact pinned lower packages should also produce two variants.

Or, if they are not pinned exact, it's enough to produce a single output for the final package.

This is how we compute the "variant overlap" and build tree order in boa: https://github.com/mamba-org/boa/blob/d332420fc2c764e0077e2b02071469a6f0b73d23/boa/core/variant_arithmetic.py#L225-L278

Variant computation algorithm!

For a single package, it's modestly simple. There are two inputs:

The used variables and dependencies (incl. run_exports) of the package
The conda_build_config.yaml that contains the variant configuration and zip_keys.

For the following examples, let's consider the following variant config:
python:
  - 3.8
  - 3.9
  - 3.10
numpy:
  - 1.19
  - 1.20
  - 2

Simple variants: if our recipe depends on python, we create 3 variants with 3.8, 3.9, and 3.10.
Zip Keys "zip up" some variants into a single variant. If our variant configuration would contain the statement
zip_keys: [python, numpy] the first condition is that we have the same number of numpy variants as python.
They are then zipped, so that we end up with a "joint variant" of python_numpy: [[3.8, 1.19], [3.9, 1.20], [3.10, 2]].

Multiple outputs

Multiple outputs behave like independent recipes that can be "strongly" connected with pin_subpackage dependencies.
When strong pin_subpackage connections are introduced, variant computation also needs to be altered.
Let's consider the following recipe:

outputs:
  - package:
      name: libfoo
    requiremnts:
      host:
        - python
  - package:
      name: foofoo
    requiremnts:
      host:
        - python
        - ${{ pin_subpackage('libfoo', exact=True) }}

We build libfoo py38, libfoo py39 and libfoo py310.
Now for foofoo, we expect to build foofoo py38, foofoo py39 and foofoo py310 (stemming from python variants). However, since there is also
an exact pin on libfoo, we also expect 3 variant packages for libfoo to be built. We need to find the shared variants between the exactly pinned subpackages
and create a joint variant for them. In this case, we would end up with 3 variants for libfoo and 9 variants for foofoo. Of the 9 variants for foofoo only 3 are solvable.
We create a pin_subpackage_zip to create only the solvable subset of variants:

py38  libfoo-py38
py38  libfoo-py39 (UNSOLVABLE! as are the others)
py39  libfoo-py39
py310 libfoo-py310

So the pin_subpackage_zip looks like python_libfoo: [[3.8, libfoo py38], [3.9, libfoo py39], [3.10, libfoo py310]].
outputs:
  - package:
      name: libfoo
    requiremnts:
      host:
        - python
  - package:
      name: foofoo
    requiremnts:
      host:
        - python
        - numpy   # here we need to be careful to still `zip` the variants with `python` and `numpy` together
        - ${{ pin_subpackage('libfoo', exact=True) }}

py38  [numpy 1.19] [libfoo py38]
py39  [numpy 1.20] [libfoo py39]
py310 [numpy 2]    [libfoo py39]

Let's assume we also have two boost versions (17 and 18), and only libfoo depends on them.
outputs:
  - package:
      name: libfoo
    requiremnts:
      host:
        - python
        - boost
  - package:
      name: foofoo
    requiremnts:
      host:
        - python
        - ${{ pin_subpackage('libfoo', exact=True) }}

Now the variants look like:

libfoo py38  boost 17
libfoo py38  boost 18
libfoo py39  boost 17
libfoo py39  boost 18
libfoo py310 boost 17
libfoo py310 boost 18

And the variants for foofoo are:

py38  [libfoo py38  boost 17]
py38  [libfoo py38  boost 18]
py39  [libfoo py39  boost 17]
py39  [libfoo py39  boost 18]
py310 [libfoo py310 boost 17]
py310 [libfoo py310 boost 18]

Okay now I am considering to build the full variant tree, and then subtract everything that is not solvable based on examining the run dependencies / constraints of the package.
Jaime's case:
package:
  version: 1.0.0
outputs:
  - package:
      name: libfoo
    build:
      string: ${{PKG_HASH}}_{GPU_OR_CPU}
  - package:
      name: foofoo
    requiremnts:
      host:
        - ${{ pin_subpackage('libfoo', exact=True) }}

In this case we get

libfoo 1.0.0  GPU
libfoo 1.0.0  CPU

And for foofoo we get

foofoo 1.0.0  [libfoo 1.0.0 GPU]
foofoo 1.0.0  [libfoo 1.0.0 CPU]


Fix broken test for rgba image rotation

OK, now all the libs build with nightly so I see my bugs and fix them. Rgba test rotation pass now. Sorry for the mistake in my previous pull request.

Thanks!


Fixed malformed cluster name error.

This error will occur when $USER is different from CRL username.

TFTR!


chore: change default branch to main

We are going through all of the node.js repositories to rename the
primary branch to main. Please see nodejs/node#33864 for more context.
This PR updates all of the references to the default branch that
need to be updated at the same time that we rename the branch.
Signed-off-by: Michael Dawson<EMAIL_ADDRESS>

you're probably going to have to chase this one up through launchpad too and rename it there or have some kind of bridging mechanism, hopefully the readme explains enough of those mechanics


Memory leak in fragments

Hello.
createElement(Fragment) permanently puts an entry into vnodesForComponent, which then never gets cleaned up. Further diffing becomes slower, as a hook will try to iterate all entries. The app gets slow.

@JoviDeCroock  mentioned:

Skipping built-in's here would fix that https://github.com/preactjs/prefresh/blob/main/packages/core/src/runtime/vnode.js#L15

I think it's reasonable way to approach it.


tt-rss: 2019-01-29 -> 2021-01-29

Motivation for this change
tt-rss does not tag specific releases, master branch is considered the stable production ready output.
This PR bump the revision to match most recent commit on master at the time.
Things done

[x] Tested a deployment using the NixOS module

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

[x] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[ ] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[x] Fits CONTRIBUTING.md.

cc @globin @zohl

This is a semi-automatic executed nixpkgs-review with nixpkgs-review-checks extension. It is checked by a human on a best effort basis and does not build all packages (e.g. lumo, tensorflow or pytorch).
If you have any questions or problems please reach out to SuperSandro2000 on IRC.
Result of nixpkgs-review pr 111286 run on x86_64-darwin 1

1 package built:

tt-rss

This is a semi-automatic executed nixpkgs-review with nixpkgs-review-checks extension. It is checked by a human on a best effort basis and does not build all packages (e.g. lumo, tensorflow or pytorch).
If you have any questions or problems please reach out to SuperSandro2000 on IRC.
Result of nixpkgs-review pr 111286 run on x86_64-darwin 1

1 package built:

tt-rss


Resource Linking Failing  during  ./gradlew assembleRelease

Been trying to assemble an apk for a long time now but keep running across this error when building.
java.util.concurrent.ExecutionException: com.android.builder.internal.aapt.v2.Aapt2Exception: Android resource linking failed
node_modules/react-native-dialogflow/android/build/intermediates/res/merged/release/values-v26/values-v26.xml:7: error: resource android:attr/colorError not found.
node_modules/react-native-dialogflow/android/build/intermediates/res/merged/release/values-v26/values-v26.xml:11: error: resource android:attr/colorError not found.
node_modules/react-native-dialogflow/android/build/intermediates/res/merged/release/values-v26/values-v26.xml:15: error: style attribute 'android:attr/keyboardNavigationCluster' not found.
node_modules/react-native-dialogflow/android/build/intermediates/res/merged/release/values-v28/values-v28.xml:7: error: resource android:attr/dialogCornerRadius not found.
node_modules/react-native-dialogflow/android/build/intermediates/res/merged/release/values-v28/values-v28.xml:11: error: resource android:attr/dialogCornerRadius not found.
node_modules/react-native-dialogflow/android/build/intermediates/res/merged/release/values/values.xml:2747: error: resource android:attr/fontStyle not found.
node_modules/react-native-dialogflow/android/build/intermediates/res/merged/release/values/values.xml:2748: error: resource android:attr/font not found.
node_modules/react-native-dialogflow/android/build/intermediates/res/merged/release/values/values.xml:2749: error: resource android:attr/fontWeight not found.
node_modules/react-native-dialogflow/android/build/intermediates/res/merged/release/values/values.xml:2750: error: resource android:attr/fontVariationSettings not found.
/node_modules/react-native-dialogflow/android/build/intermediates/res/merged/release/values/values.xml:2751: error: resource android:attr/ttcIndex not found.
Any ideas ?? Your help is much appreciated.

For anyone building and app with RN ^0.60.0, I was able to build the apk with a little help from GitHub: https://github.com/react-community/create-react-native-app/issues/499#issuecomment-396545716
Only changing the SDK & build tools versions to 28 and 28.0.3, respectively.

@eggybot @jaklew @Gabsys
This is my build.gradle file:
// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    ext {
        buildToolsVersion = "28.0.3"
        minSdkVersion = 16
        compileSdkVersion = 28
        targetSdkVersion = 28
    }
    repositories {
        google()
        jcenter()
    }
    dependencies {
        classpath("com.android.tools.build:gradle:3.5.2")
        classpath 'com.google.gms:google-services:4.2.0'
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        mavenLocal()
        maven {
            // All of React Native (JS, Obj-C sources, Android binaries) is installed from npm
            url("$rootDir/../node_modules/react-native/android")
        }
        maven {
            // Android JSC is installed from npm
            url("$rootDir/../node_modules/jsc-android/dist")
        }

        google()
        jcenter()
        maven { url 'https://www.jitpack.io' }
    }
}

My RN version is 0.62.2
I am still unable to build the apk for react native android project.


unable to install/update hyn package 1.0

on executing following command
composer require hyn/multi-tenant
I will receive following error :
Updating dependencies (including require-dev)
  - Installing hyn-me/framework (0.4.0)
    Downloading: Failed
    Failed to download hyn-me/framework from dist: The "https://api.github.com/repos/hyn-me/framework/zipball/347784b8257099c661419d280f45662a2d3497c8" file could not be downloaded (
HTTP/1.1 404 Not Found)
    Now trying to download from source
  - Installing hyn-me/framework (0.4.0)
    Cloning 347784b8257099c661419d280f45662a2d3497c8

Installation failed, reverting ./composer.json to its original content.

  [RuntimeException]
  Failed to clone https://github.com/hyn-me/framework.git via https, ssh protocols, aborting.
  - https://github.com/hyn-me/framework.git
    Cloning into 'E:\Ampps\www\managetrainings4u\SourceCode\vendor\hyn-me\framework'...
    remote: Invalid username or password.
    fatal: Authentication failed for 'https://github.com/hyn-me/framework.git/'
  - git@github.com:hyn-me/framework.git
    Cloning into 'E:\Ampps\www\managetrainings4u\SourceCode\vendor\hyn-me\framework'...
    Host key verification failed.
    fatal: Could not read from remote repository.

    Please make sure you have the correct access rights
    and the repository exists.

require [--dev] [--prefer-source] [--prefer-dist] [--no-progress] [--no-update] [--update-no-dev] [--update-with-dependencies] [--ignore-platform-reqs] [--sort-packages] [-o|--optimi
ze-autoloader] [-a|--classmap-authoritative] [--] [<packages>]...

You still have the old package installed:
edit your composer.json file and rename hyn-me/multi-tenant to hyn/multi-tenant then do a composer update. After that change the version constraint in the file.

Please re-open if this was not the solution.

I dont think this is fixed yet or probably not working at this moment, I am trying to require 2 packages

"hyn/multi-tenant": "1.0.1"
"hyn/management-interface": "0.5.5"

Inmy composer.json I get the above mentioned error. and also it will fallback to github where it fails to authenticate similar like in the above bug.

I can no longer provide support for version 1. In addition the management interface has been dropped.

Ya i knew you guys had stopped supporting the 1.x version but that is the only one compatible with Laravel 5.1 which is actually a LTS. sad to see you guys not supporting :( Atleast can u suggest me an alternative in what other way i can load this package to my existing 5.1 laravel app

You are still including the wrong package or you have hyn-me/framework in your composer file. If you require hyn/multi-tenant:1.* it should load hyn/framework not hyn-me/framework, see
https://github.com/hyn/multi-tenant/blob/1.x/composer.json#L19

Just did a test by running:
composer require hyn/multi-tenant:1.*

And it worked perfectly.

I tried what you said no luck, I even cleared composer cache and tried installing in a seperate folder freshly out of my project no luck I still get same error. Any how thank you very much i really liked your package .

can you post your composer.json?

here is the link https://codeshare.io/2BAKEx

Drop this from the composer.json and it will work:
    "config": {
        "preferred-install": "dist"
    }

Tried removing the config from composer.json! same error :( What am I doing wrong this is the first time I m facing this issue with composer

@appningsdev same error meaning it's still looking for hyn-me/framework?

Yes same error like in the screen shot i have posted

@appningsdev can you humor me and send me a new screenshot of the problem please...
When getting the screenshot please include the command you are running so that I can know what command you ran, and see what the error is...
Thanks

@appningsdev ok. that is weird.. maybe it is a composer problem..
try this: rm -rf vendor composer.lock
then try to composer update again..

Tried that! nothing changed .

@appningsdev have you tried removing your home global composer directory? ~/.composer?
I don't see why it's causing this issue.

I have never done that, how do i do it just go and delete that folder ? would that affect my project ?

it will remove any composer packages that you've installed globally. yes just delete it..
please do a backup before deleting so.

No luck!

@bkintanar i ran into the same issue with the old composer.json. I'm not sure why this is happening but loading the dist files results in this behaviour. Either we report this at the composer repo and hope for the best or we let this be. It's taking too much of my time already for a unsupported version.

Well is there any other alternative to your multi-tenant package compatible with Laravel 5.1.

Maybe this will help for seeking an alternative.

Thank you very much  :+1: .


no box detected using code in the codelab demo

Thanks for the great work! I'm trying the code provided in your codelab demo. However,  there is no bounding box detected (No errors appear during the compiling and execution). I've also tried to re-install packages to ensure versions of packages on my server are the same as those in your code. Is there any possible reasons for the result?

@abril4416 Hi, thank you for the support! Due to the recent update of the Colab env (CUDA and Pytorch version), our original code does not seem compatible. There are mainly two quick fixes that need to be added to the notebook and to the codes to make the demo work.

In the Colab demo: 'cuda' needs to be changed with 'cuda-10.2'

After installing the cuda-10.2, it's always better to double-check the CUDA installation with '!nvcc -V'.

In the codes (maskrcnn_benchmark/engine/predictor_glip.py) https://github.com/microsoft/GLIP/blob/fd52c6361f013e70ae7682d90b3ab3ca2bd5e6bc/maskrcnn_benchmark/engine/predictor_glip.py#L347, please change the self.color to 255.

Sorry I am currently busy with something else, so I don't have time to update the codes. We will make sure to fix the issues and release them with the updated GLIPv2 codes and models very soon. Thanks for the support and patience!

Hi haotian, thanks for the patient reply. I'll try the updated codes as you've mentioned first. A problem is that I re-use the code on my own server, but there is no bounding box detected (no errors appeared). Could you please offer some suggestions when you are free?

@abril4416 Hi, thank you for the support! Due to the recent update of the Colab env (CUDA and Pytorch version), our original code does not seem compatible. There are mainly two quick fixes that need to be added to the notebook and to the codes to make the demo work.

In the Colab demo: 'cuda' needs to be changed with 'cuda-10.2'

After installing the cuda-10.2, it's always better to double-check the CUDA installation with '!nvcc -V'.
2. In the codes (maskrcnn_benchmark/engine/predictor_glip.py) https://github.com/microsoft/GLIP/blob/fd52c6361f013e70ae7682d90b3ab3ca2bd5e6bc/maskrcnn_benchmark/engine/predictor_glip.py#L347
, please change the self.color to 255.

Sorry I am currently busy with something else, so I don't have time to update the codes. We will make sure to fix the issues and release them with the updated GLIPv2 codes and models very soon. Thanks for the support and patience!

@abril4416  did you ever solve your problem?

Hi, I have updated the demo to use an older version of the code for
inference. Could you try again to see if your problem persists?
On Tue, 2 Aug 2022 at 14:26, ktrapeznikov @.***> wrote:

@abril4416 https://github.com/abril4416 did you ever solve your problem?
—
Reply to this email directly, view it on GitHub
https://github.com/microsoft/GLIP/issues/31#issuecomment-1203230266, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/ALAYVCT66AQ22DWCZJRUHRDVXGHBBANCNFSM54UGSLTA
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>

no need to change the code.
just add
glip_demo.color = 255
after initialize "GLIPDemo" class

If after specifying the self.color, it still does not work. Make sure to check if the bboxlist contains non-zero num_boxes
result, bboxlist = glip_demo.run_on_web_image(image, caption, 0.5)
bboxlist:
BoxList(num_boxes=2, image_width=640, image_height=480, mode=xyxy)
num_boxes, should greater than zero.
If it's zero, consider checking if you have downloaded the right weights for your config yaml file. For example, these 2 are different set of weights:
https://huggingface.co/GLIPModel/GLIP/resolve/main/glip_tiny_model_o365_goldg.pth
https://huggingface.co/GLIPModel/GLIP/resolve/main/glip_a_tiny_o365.pth


Is there a way to set maxSockets? I want to enable Keep Alive connections

I would like to enable keep alive and I've seen following solution for http-proxy: https://github.com/nodejitsu/node-http-proxy/issues/767. I wonder if it is a similar solution for http-master and how could it be achieved?
Thank you

Yeah, you are welcome to try messing with https://github.com/encharm/http-master/blob/master/modules/middleware/proxy.js - you mean keep alive between proxy and target server, right?

Correct. Thank you, I'll take a look.

@szarouski let me know your results. Perhaps it should be supported OOTB.

Seems to be working fine if I do following:
add var http = require('http'); at the top
And adjust proxy to include agent:
var agent = new http.Agent({ maxSockets: Number.MAX_VALUE });
var proxy = httpProxy.createProxyServer({xfwd: true, agent: agent});

I wonder if that should be configurable? I don't know how options could be passed into middlewares.
I agree with you that it will be nice to have it OOTB. Let me know what should be next steps to make it happen :)

Just trying to think of disadvantages of this solution. I think the risk is that the server may more easily run out of available sockets. Have you done any benchmarking?

Here is some feedback. I used http-proxy with agent created like above and I setup a load test using loadimpact.com with maximum at 250 connections. I was able to see that number of occupied sockets was growing over time. Once load test finished sockets state changed to TIMED_WAIT. After 1 minute I could see that sockets on my linux machine were closed (indeed tcp_fin_timeout is 60). ulimit on my linux box was set to unlimited. From other comments I can see that TIMED_WAIT and number of available sockets is depending on machine configuration. It seems that for default linux configuration there is a limit of 470 sockets at any given time. So... I think that it would be nice to be able to configure agent settings. What do you think?

Also something that I forgot to mention - it is not a maxSockets value which is making connection to change to 'keep-alive'. It is enough to just have http.Agent instance. I tried to debug core http module, but stuck on what exactly is causing it to pick keepAlive setting even when it is not set to true on the agent instance.

Hi @Rush, I'll have some free time soon and I wonder if you can point me to what you think is the best way to define agent options and if there are any similar examples in the code where http-master takes configuration options. I'll make a PR once I'm done. Thank you sir.

Hey @szarouski, thanks for the offer. Actually I would rather appreciate some more tests to get a good default option. To answer your question, http-master uses dependency injection:
https://github.com/encharm/http-master/blob/master/modules/middleware/proxy.js#L32
Change it to:
module.exports = function ProxyMiddleware(config, portConfig, di) {

and you have access to global config hash, where you could have config.maxSockets
Thanks!

Proxy improvements, including agent settings landed here: https://github.com/encharm/http-master/pull/103. I'll try to contribute more when I have time. I'm not certain what editor you're using, but there is a great tool for realtime javascript development and testing called wallaby.js, which is available for WebStorm, and soon for other editors. It was easy to get it working with your existing testing tools.

Open in new window

@szarouski That's huge. Thanks for that. We'll both use it in our RubyMine.