Adding tests

I liked this project, so I decided to try and add some tests to it.
If i get this merged, I might also add the feature of getting the polygon drawn clockwise (since it coordinates of inner polygons (holes) has to be clockwise, but the outer polygon has to be counter-clockwise.
I might also add test for non-trivial center positions.
This tests the following:
Input validation

[x] Throw error on in-valid longitude argument (types and value)
[x] Throw error on in-valid latitude argument (types and value)
[x] Throw error on in-valid center argument (types and values)
[x] Throw error on in-valid radius (types and value, min is set to 1 m)
[x] Throw error on invalid segment arguments (type and value, min set to 3)

Output validation

[x] Polygon has the correct attributes
[x] All attributes has correct type and length (for arrays)

Trivial center positions:

[x] Center is east of GMT, north of equator
[x] Center is east of GMT, south of equator
[x] Center is west of GMT, north of equator
[x] Center is west of GMT, south of equator
[x] Center is on [0, 0]
[x] Pentagon on pentagon test (this one is just for fun)

Non-trivial center positions:

[ ] Positions on the lat -90
[ ] Positions on the lat 90
[ ] Positions on the lng -180
[ ] Positions on the lng 180
[ ] Circle border passes the 180th Meridian
[ ] Circle area includes north pole
[ ] Circle area includes south pole

I forgot to add, I'm using Prettify, and prettified the files.
I will happily change my code if you follow some other code style (but even happier if you accept prettified code :) )

Happy to merge this if you can fix the conflict!

@gabzim I just solved the merge conflict, please have a look!

@gabzim , please wait a sec with merging this, I need to fix the behavior when numberOfSegments is undefined.


feat: lnd implementation of MakeInvoice

The NIP-47 extension PR specifies msats as the unit. I think sats is enough but I don't feel like argueing so we should also use msats everywhere (lnd + alby backend)

@kiwiidb  @im-adithya it should then also be consistent in GetBalance.

In the alby service it returns the value in sats
In handle_balance_request we set MaxAmount (from the budget) also in sats


Grocery detection

Hello,
I wonder something,
https://ai.googleblog.com/2020/07/on-device-supermarket-product.html
this article has OCR used for product recognition, I think your method could be more efficient. but I'm not sure. your opinion is very important to me.
In your opinion, which one would be more efficient in recognizing the grocery's product. OCR or Your method?
Best Regards
Onur Güzeldemirci

Hello Onur,
Thanks for your interest in our work. I believe the method mentioned I the article (ROI embedding + OCR) will be 1) faster and 2) more reliable than feature-matching-based methods like LoFTR, mostly because LoFTR is not designed for this task.


getTracks is not defined on demo (video and screen sharing.html)

https://github.com/muaz-khan/RTCMultiConnection/blob/master/demos/video-and-screen-sharing.html
I follow that link camera on owner and participants work OK, but when i click btn share screen , i get an error that "getTracks is not defined"
is it a issue or my setup has problem ?

I have the same case as you.
Anyone who can resolve it. Please help me
Thank you

@Viruss98  have you had resolved this issue?

@muaz-khan  How do you know the way to define getTracks function ?
  function getScreenStream(callback) {
    screenHelper(function (screen) {
      RMCMediaTrack.screen = **getTracks**(screen, "video")[0];


Installation of 3bot with 3sdk on linux failed

Two things:

package.sh file has commented out sections. I required these to be uncommented to be able to "compile" and have a working binary at the end.

#!/usr/bin/env bash
set -e

#pip3 uninstall pyinstaller
#pip3 install https://github.com/pyinstaller/pyinstaller/archive/develop.zip
#brew install upx

#if [ "$(whoami)" == "root" ]; then
#    pip3 install -r requirements.txt
#else
#    pip3 install --user -r requirements.txt
#fi
pyinstaller 3sdk.spec
#--onefile --additional-hooks-dir=./hooks

secondly I cannot enter my seed phrase, either typing in or copy-paste result in the same error:

Welcome to sdk shell, for available modules, call info()
3sdk> container threebot

will make sure you have your 3bot alive

- identity is your 3bot unique name (only needed to specify once)
- email is your email (only needed to specify once)
- if you already have your secret key, specify the words of your key

when 3bot becomes unrepsonsive you can always ask a restart on server, the container will not be restarted

 2085 ?        Zs     0:00 [ssh-agent] <defunct>
12725 ?        Ss     0:00 ssh-agent -a /sandbox/var/sshagent_socket
13479 pts/0    S+     0:00 grep ssh-agent
what is your threebot name (identity)?
weynandkuijpers.3bot
 - SSH PORT ON: 9000
 - Docker machine gets created:
20c23c04067dfb51bd8214032c49b87908e73e682e49ef46ccd51427be41c68b
 - Configure / Start SSH server
 - make sure jumpscale code is on local filesystem.
 - install jumpscale for identity:weynandkuijpers.3bot
specify secret passphrase please::
specify secret passphrase please: (confirm):
Invalid password!
specify secret passphrase please::
specify secret passphrase please: (confirm):
Connection to localhost closed.
 - Configure secret
Usage: jsx secret [OPTIONS] SECRET
Try "jsx secret --help" for help.

Error: Got unexpected extra arguments (deliver monkey.... <<rest deleted of passphrase>>

verified.


Perserve OSM history when merging, spiltting, etc.

Many operation result in loosing OSM history in view of tags and/or geometry. For example:

Merge ways or areas
Splitting ways or areas
Multipoygon <-> area conversions
JOSM has some methods to reduce history impact, but these need some user experience, and are not a full solution.

How about adding one or two tags to bridge the history gap? One tag has to describe which other object tags have been sourced from, and the second tag describes which other object the geometry has been sourced from. These tags can be discarded with the next revision of the object. It is sufficient to keep the tags in the OSM history only.
This can work in the following way:
When loading an entity a with id a.id and version a.vers from the database add two array properties a.tag_hist = a.geo_hist = [a.id+a.vers];
When splitting an entity a into b and c, set
b.tag_hist = c.tag_hist = a.tag_hist;
b.geo_hist = c.geo_hist = a.geo_hist;
When merging two entities a, b with result c, set
c.tag_hist = a.tag_hist + b.tag_hist;
c.geo_hist = a.geo_hist = b.geo_hist;
When transfering tags from a to b (e.g. point/area merge), set
b.tag_hist = a.tag_hist + b.tag_hist;
b.geo_hist = b.geo_hist;
When storing an object a with version a.new_vers into the database remove duplicate items and any occurences of a.id+(a.new_vers-1) from both arrays a.tag_hist and a.geo_hist.
Add the following tags:
key: 'editor_history:tags:'+a.id+a.new_vers,
value: a.tag_hist converted to string, discard tag if empty
and
key: 'editor_history:geo:'+a.id+a.new_vers,
value: a.geo_hist converted to string, discard tag if empty
If this is acceptable for iD we should discuss it with the JOSM developers too. I would expect JOSM to be the first one using the additional information.

👎 to this, if we want to preserve this information, the right way is to change the API.

:-1: too. These history tags will grow over time and use more space then the property itself.

These history tags will grow over time and use more space then the property itself.

This is wrong. An editor supporting this concept would discard the old tags, new tags are added in case the stored object is the result of merging, spitting, or copying during the current edit session. Therefore, most objects wouldn't have any such tag. Editors which are not supporting the concept might propagate the tags to the next version, but don't add anything.

@pnorman An api change can't replace this concept because the api can't know what has happened during the edit session. The editor needs to provide this information. Changing the api to let us store this information (the two tag values) in a differnent way than using normal tags would be nice. A more general api change offering object version specific tags/properties (some kind of object specific changeset tags) would be sufficient, but is such an api change realistic?

@pnorman Instead of using normal tags we can use changeset tags which are more intended for such purposes of describing the edit. My concept would work with changeset tags without any significant changes, but I see some potential drawbacks:

JOSM changesets can be quite large. In case of using merge, split, copy tags heavily during the edit session, this can result in a quite large number of such changeset tags. I don't know if there are any limitations in view of changeset tags. Maybe JOSM can split the changeset if required.
Tracing the history of an object seems to require to load all the changesets, which can be quite time-consuming. If any efficient method to get the object related tags selectively exists or can be provided this will not be a problem. It is not mandatory to get this from the API directly. It would be sufficient to get it from the Overpass API or any other service, which is sufficiently current. Maybe it is easier to get the Overpass API changed than the API. We don't need to wait for this a change, because it is not required to store the extended history information, but we need to choose the right data format to enable this change if required.

I don't really understand the proposal very well, but I think it should be vetted by the tagging community.  If I am understanding it correctly, the proposal is "whenever a new object is created from an old object, store the old object id and old object version in tags".
It's not clear to me who actually wants this, or how it would help.  If people in OSM actually want it, and JOSM implements it, then we'd implement it too.  But until it picks up more support, let's leave the issue as closed.


Fix maven build

Fix maven build. C:\Users\Arte\ doesnt exist on my server ;)

True true true... Always forgetting about that one...


Telling if a container's policy is locked or it's retention period/type

It was previously mentioned in https://github.com/Azure/azure-sdk-for-go/issues/16751 and @RickWinter mentioned it might be looked into but as of v1.1 azblob is still not populating the RemainingRetentionDays which I'm not sure if it's meant to be the same thing (it'd make more sense if without Remaining).
azblob client tells you if there's a policy on a container (Properties.HasImmutabilityPolicy) but it doesn't tell you if the policy is locked or what the policy time period or type is.
armstorage has some of this information (GetImmutabilityPolicy, although the comment of ImmutabilityPeriodSinceCreationInDays could be made more clear) but using these 2 clients together is not so ideal since it asks for so much information in comparison.
azblob: SA name + accessKey + container is enough
armstorage: subscriptionId + resourceGroupName + tenantId + clientId + clientSecret + SA name + container
Are there plans to move more container policy info into the azblob client?
Any way to get armstorage to work with SA name + accessKey (i.e. azblob.NewSharedKeyCredential) that I didn't notice?
What about discovering the other information (subscriptionId + resourceGroupName) from the azblob/something else using the shared key?
Finally is there any client currently that returns the retention type? https://learn.microsoft.com/en-gb/azure/storage/blobs/immutable-storage-overview#about-immutable-storage-for-blobs mentions there can be Regulatory compliance & Secure document retention but I don't see an option to set/view either in the portal and it's not visible in either of the 2 clients I tried from azblob or armstorage

Are there plans to move more container policy info into the azblob client?

AFAIK, there are no plans for this at the moment.
At the moment, you can call ContainerClient.GetProperties get the following related immutability policy information:
// HasImmutabilityPolicy contains the information returned from the x-ms-has-immutability-policy header response.
HasImmutabilityPolicy *bool

// HasLegalHold contains the information returned from the x-ms-has-legal-hold header response.
HasLegalHold *bool

// IsImmutableStorageWithVersioningEnabled contains the information returned from the x-ms-immutable-storage-with-versioning-enabled header response.
IsImmutableStorageWithVersioningEnabled *bool

You can also call BlobClient.GetProperties get the following related immutability policy information:
// ImmutabilityPolicyExpiresOn contains the information returned from the x-ms-immutability-policy-until-date header response.
ImmutabilityPolicyExpiresOn *time.Time

// ImmutabilityPolicyMode contains the information returned from the x-ms-immutability-policy-mode header response.
ImmutabilityPolicyMode *ImmutabilityPolicyMode

Any way to get armstorage to work with SA name + accessKey (i.e. azblob.NewSharedKeyCredential) that I didn't notice? What about discovering the other information (subscriptionId + resourceGroupName) from the azblob/something else using the shared key?

I believe the subscriptionID is one of the required parameters and armstorage won't work without it. As for azblob, currently we don't have any APIs that would return the desired information.

Finally is there any client currently that returns the retention type? https://learn.microsoft.com/en-gb/azure/storage/blobs/immutable-storage-overview#about-immutable-storage-for-blobs mentions there can be Regulatory compliance & Secure document retention but I don't see an option to set/view either in the portal and it's not visible in either of the 2 clients I tried from azblob or armstorage

The applications shown in the documentation (Regulatory compliance & Secure document retention) are actually examples. You can have an immutability policy with two different scopes (time-retention or legal hold) that can be configurable in Azure Portal as described here: https://learn.microsoft.com/en-gb/azure/storage/blobs/immutable-storage-overview#immutability-policy-scope.
You can also set the immutability policy BlobClient.SetImmutabilityPolicy on a blob client using azblob Go SDK.
I hope this helps and please let me know if there are additional questions I can help with @KastenMike !


Command needs to judge whether the string length is empty before using it.

https://github.com/openGemini/opengemini-client-go/blob/00cca69028e8aac2b5de2dd6c522d393d7b8091e/opengemini/measurement.go#L29

closed by #155


Add Checkr to company using Airflow

Dear Airflow maintainers,
Please accept this PR. I understand that it will not be reviewed until I have checked off all the steps below!
Description

[ Y ] Here are some details about my PR, including screenshots of any UI changes:
Add Checkr to companies officially using Airflow.

Codecov Report

Merging #2276 into master will increase coverage by 0.04%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #2276      +/-   ##
==========================================
+ Coverage   68.86%   68.91%   +0.04%
==========================================
  Files         142      142
  Lines       10969    10969
==========================================
+ Hits         7554     7559       +5
+ Misses       3415     3410       -5

Impacted Files
Coverage Δ

airflow/models.py
87.01% <0%> (+0.04%)
:arrow_up:

airflow/jobs.py
74.41% <0%> (+0.4%)
:arrow_up:

Continue to review full report at Codecov.

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

Please squash your commit

@bolkedebruin Thanks for jumping on the PR, just squashed commits.


[Feature]: Remove upper bound on python version

To Dos

[X] I have checked the issues and think that this is not a duplicate.

[X] I added a very descriptive title to this issue.

Description
Currently rstcheck declares compatibility with python versions >=3.7 <4.0. This can be problematic, particularly because it makes it difficult to use recent versions with any project that does not declare a similar upper bound.
This blog post puts forth the argument better than I can about why it is a better practice to omit the upper bound and simply declare >=3.7. https://iscinumpy.dev/post/bound-version-constraints/
For more context I ran into this issue a while ago on my own project.
I'd be happy to propose a PR if you're convinced.
Operating System
macOS
Operating System Details
No response
Python Version
3.10
rstcheck Version
3.5.0

I read the linked article and some more and I am convinced. Thanks.
A PR would be appreciated. But if you change it in rstcheck could also make the change in rstcheck-core as well, because otherwise it would be somewhat pointless I guess. No need for a new issue in core, just reference this issue in the PR.
Unfortunately my free time in which I can make a new release is very scarce. Merging PRs I can do from anywhere. The coming weekend is the last opportunities for me to make a new release for the next around 2 months to come.

This should be fixed in 6.2.0.
Moved from poetry to plain old setuptools with open dependency bounds.


Network/Disk  usage graph sidebar real-time

Feature Request
A side bar that contains graphs showing the current CPU/RAM/Network/Disk usage usage in real-time
Feature Information:

What should it do?
Show a side bar that contains graphs showing the current CPU/RAM/Network/Disk usage usage in real-time
Is it specific to a given application module?
No
included pictures

I confirm:

[x] that I have searched for an existing feature request matching the description.

Disk access is something that might happen but Network Monitoring isn't always feasible. Linux doesn't track network activity per-PID so this is only possible when A) running in a container and B) not using host-mode networking (which AMP generally uses) - which means you're seeing the activity for the entire container rather than the main process and it's fairly limited in situations where it's useful.


Replace data.base with data.values.base

Should eliminate the Pandas series deprecation warning in issue #4300.

Hello @astrowonk any reason why you closed this PR? Didn't it address #4300 ?

@thvasilo It actually didn’t do what I hoped it did; It failed a bunch of unit tests. I closed until I had time to come up with something that would work properly.
Right now the same code that is applied to np arrays is applying to pandas series and if I did the .values insertion as I tried, various tests error when the .values is applied to a numpy array.
I think this can be solved with some more cleverly nested conditional, I just didn’t have time yet to figure out the exact structure.


Update docker-entrypoint.sh to allow a user mounted script to be sourced to allow for extra settings

This PR is part of a bash script so I'm not sure how you want me to test it.
It will simply allow a custom script to be mounted into the image so that a user can specify commands to be run on start up.
See Issue #189 on why I think this is a good idea.
Thanks for any consideration

This would be very helpful for us as well.

Maintenance of the docker files for elasticsearch has moved to the elasticsearch repo. As we will be archiving this repository, I am going to close this PR. If you are still interested in making this contribution, please open a new pull request there.


Tridecagon calculator

Hi I would like to make a tridecagon calculator (area,perimeter and related things)

Go ahead
Deadline 10 May,2021


j:Group itemsHorizontalAlign property issue. SDK#0.9.7 #1086

Hi Carlos,
I'm not sure if itemsHorizontalAlign property must exist or not for j:Group.
For now, you can use it, the compiler don't complain.
But if you use it there is an error on runtime :

Here is test case:
<j:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
	xmlns:j="library://ns.apache.org/royale/jewel"
	xmlns:js="library://ns.apache.org/royale/basic"
	xmlns:local="*" >

	<j:valuesImpl>
		<js:SimpleCSSValuesImpl />
	</j:valuesImpl>

	<j:initialView>
		<j:View width="100%" height="100%">

			<j:Group  width="100%" height="100%" itemsHorizontalAlign="itemsCenter">
					<j:Card width="80%" height="10"/>
					<j:Label text="HELLO"/>
			</j:Group>

		</j:View>
	</j:initialView>

</j:Application>

same issue for itemsVerticalAlign

Hi Fred,
this methods are to use with the subclasses VGroup and HGroup and not for Group. It's clear that does not have sense to have in the Group class, so maybe the solution is replicate in subclasses. Will see what to do in that case. Thanks

Hi Carlos,
Thanks for you message.
I use a lot of  code completion in VSC (visual studio code) to know what are usable property . (I was doubting myself that itemsHorizontalAlign  what not for Group )
I'm afraid that a new dev guy makes like me (auto completion code),  using itemsHorizontalAlign    in Group  and think SDK is buggy.
Other than that it's not really annoying

Hi Fred,
just do the refactor to remove APIs from the Group and Container level in this commit: 59aa6238704586f4f40222fbec760b50318575a8


[hyperdebug] GPIO testing

This is the beginning of a GPIO test that can serve as a chip-level test and a bringup test for HyperDebug.
This test uses a test-harness program (//sw/host/tests/chip/gpio) to command the DUT to perform certain operations on the pinmux and gpio IPs.  The status of the GPIOs are then checked by test harness via the debug module (e.g. hyperdebug).
This PR includes the following:

Importing chip-level constants into opentitanlib with bindgen.
Creating new ujson structs to command pinmux configurations and GPIO actions.
Adding flow-control to the OTTF console UART (opentitantool easily overwhelms verilator without flow control).
Misc cleanups to file locations and several libraries.

This PR is too big. I'm going to try to break this PR apart into some smaller, more easily reviewed units.


[animations] Using gesture detectors or navigating to previous page with OpenContainer widget returns to the root screen.

I am using the animations package in Flutter to navigate between several pages in Flutter, as a sort of alternative to using Navigator.push(). I am navigating between several pages, and when I navigate between several pages, and when I just want to return to the last one, it will return back to the first page ever. Here is the code with the issue.
import 'package:animations/animations.dart';
import 'package:flutter/material.dart';

void main() {
  runApp(const FirstScreen(),);
}

class FirstScreen extends StatelessWidget {
  const FirstScreen({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        body: Center(
          child: OpenContainer(
      transitionDuration: Duration(seconds: 1),
      openBuilder: (context, _) => SecondScreen(),
      closedElevation: 0,
      closedShape: RoundedRectangleBorder(
        borderRadius: BorderRadius.circular(32),
        side: BorderSide(color: Colors.white, width: 1)),
      closedColor: Colors.blue,
      closedBuilder: (context, _) => Container(
      alignment: Alignment.center,
      width: 200,
      height: 50,
      child: Padding(
        padding: const EdgeInsets.all(8),
        child: Text(
          "First Screen",
          style: TextStyle(
              color: Colors.white,
              fontWeight: FontWeight.bold,
              fontSize: 20),
        ),
      ),
      ),
    )
        ),
      ),
    );
  }
}

class SecondScreen extends StatelessWidget {
  const SecondScreen({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        body: Center(
          child: OpenContainer(
      transitionDuration: Duration(seconds: 1),
      openBuilder: (context, _) => ThirdScreen(),
      closedElevation: 0,
      closedShape: RoundedRectangleBorder(
        borderRadius: BorderRadius.circular(32),
        side: BorderSide(color: Colors.white, width: 1)),
      closedColor: Colors.blue,
      closedBuilder: (context, _) => Container(
      alignment: Alignment.center,
      width: 200,
      height: 50,
      child: Padding(
        padding: const EdgeInsets.all(8),
        child: Text(
          "Second Screen",
          style: TextStyle(
              color: Colors.white,
              fontWeight: FontWeight.bold,
              fontSize: 20),
        ),
      ),
      ),
    )
        ),
      ),
    );
  }
}

//third screen

class ThirdScreen extends StatelessWidget {
  const ThirdScreen({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        body: Center(
          child: OpenContainer(
      transitionDuration: Duration(seconds: 1),
      openBuilder: (context, _) => FourthScreen(),
      closedElevation: 0,
      closedShape: RoundedRectangleBorder(
        borderRadius: BorderRadius.circular(32),
        side: BorderSide(color: Colors.white, width: 1)),
      closedColor: Colors.blue,
      closedBuilder: (context, _) => Container(
      alignment: Alignment.center,
      width: 200,
      height: 50,
      child: Padding(
        padding: const EdgeInsets.all(8),
        child: Text(
          "Third Screen",
          style: TextStyle(
              color: Colors.white,
              fontWeight: FontWeight.bold,
              fontSize: 20),
        ),
      ),
      ),
    )
        ),
      ),
    );
  }
}

//fourth screen

class FourthScreen extends StatelessWidget {
  const FourthScreen({super.key});

  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        body: Center(
          child: OpenContainer(
      transitionDuration: Duration(seconds: 1),
      openBuilder: (context, _) => SecondScreen(),
      closedElevation: 0,
      closedShape: RoundedRectangleBorder(
        borderRadius: BorderRadius.circular(32),
        side: BorderSide(color: Colors.white, width: 1)),
      closedColor: Colors.blue,
      closedBuilder: (context, _) => Container(
      alignment: Alignment.center,
      width: 200,
      height: 50,
      child: Padding(
        padding: const EdgeInsets.all(8),
        child: Text(
          "Fourth Screen",
          style: TextStyle(
              color: Colors.white,
              fontWeight: FontWeight.bold,
              fontSize: 20),
        ),
      ),
      ),
    )
        ),
      ),
    );
  }
}

In this code, keep pressing buttons from First to Fourth Screen, then once you are on the Fourth Screen, use the triangle icon in the emulator or on the bottom bar to navigate back; it will return to the First Screen when I want to return to the Third Screen.

Thank you so much, this works!


e2e: drop stripSchema

For https://github.com/coreos/etcd/pull/6309#issuecomment-243523255.
Confirmed that this fails without Xiang's patch
2016-08-30 16:47:58.995114 C | etcdmain: database file (/tmp/testname1.etcd397787835/member/snap/db index 0) does not match with snapshot (index 16).
2016-08-30 16:47:58.998345 C | etcdmain: database file (/tmp/testname2.etcd766704350/member/snap/db index 0) does not match with snapshot (index 16).
2016-08-30 16:47:59.000010 C | etcdmain: database file (/tmp/testname0.etcd443864012/member/snap/db index 0) does not match with snapshot (index 16).

/cc @xiang90 @heyitsanthony

Currently we only test with latest v3.0.x releases. Will change it to use only one binary as Xiang suggested.

@xiang90 PTAL. Changed it to use v2.3.x

@xiang90 Now TestReleaseUpgrade fails, where we only write v3 keys. So v2.3.7 with experimental feature on and with only v3 keys fails to migrate to v3.x. Can you take a look?
etcdmain: database file (/tmp/testname1.etcd433904263/member/snap/db index 13) does not match with snapshot (index 16)

Current TestReleaseUpgrade and the new TestReleaseUpgradeWithSnapshot are almost the same.
I think we should combine those two after v3.1.

we should not enable experiment flag for v2 cluster. the v2 experimental cluster cannot upgrade to v3. we need to write v2 keys to trigger snapshot for v2 cluster, not v3 keys.

@xiang90 Right, I will switch to v2 keys then.

@gyuho I did not know that we were testing 3.0.x to 3.0.x upgrading. If it requires too much effort, we can probably drop this pr. we are going to release 3.1 rc soon anyway...

@xiang90 Ok, just dropped v2 tests part. But for v3.1 releases, I change test script to download v3.0.x.
Or should we just keep getting the latest releases, like 3.1, 3.1.1, ...?
Also dropped unnecessary function stripSchema.

right before we branch out 3.1 we should test 3.0 -> 3.1. right before we branch out 3.2, we should test 3.1 -> 3.2.

Ok will just keep test script change.

lgtm


[CSPM] FIPS: add missing documentation for enabling fips proxy for co…

What does this PR do?
Followup on #22470: adding missing documentation on endpoints override when enabling FIPS proxy
Motivation

Additional Notes

Possible Drawbacks / Trade-offs

Describe how to test/QA your changes

/merge


Tests for REST controllers fail when the size of the test data set exceeds the page request size in PageRequestVM

Describe the bug
Tests for REST controllers fail when the size of the test data set exceeds the page request size in PageRequestVM when pagination is implemented.
The tests fail because they use the size of the array returned by the .get("/api/<%= entityApiUrl %>") clause as a proxy for the size of the dataset in the database.
This is not correct because the size of the array is limited to the page request size in PageRequestVM if pagination is implemented.
If the number of test data items exceeds the page request size (default is 50), the tests that use the array fail because the size is either larger than expected, or the entity cannot be found because it is outside the page that is returned.
To Reproduce

Create a test dataset that is larger than the page request size in PageRequestVM (by default this is 50, so create a dataset with more than 50 entries)
Run the REST controller test on the entity
The update, create and delete tests fail

Expected behavior
All tests should pass irrespective of the test dataset size.
Screenshots
For example, the REST test for delete failes with:
java.lang.AssertionError:
Expected size: 49 but was: 50 in:
[Gender{id=1, code='Toys Viaduct proactive', description='Incredible'},
    Gender{id=2, code='Cotton', description='Communications Tasty'},
    Gender{id=3, code='Kids', description='haptic generation'},
    Gender{id=4, code='sensor Account', description='Sausages Home'},

Desktop (please complete the following information):
Not relevant
Smartphone (please complete the following information):
Not relevant
Additional context
None

The pagination shows the correct number of items in the HTML. It gets the total from the response header (see this.totalItems = Number(headers.get('X-Total-Count'));), so this could be used in the test instead of testing the array size.

I have made a first attempt to fix the problem see here but I have not submitted a pull request because I am using an older version of the generator, but the fix may assist others while work on 2.0 continues.

Added bug bounty to get this fixed. Please submit a PR if you have time.

I am currently working on this issue.
Using X-Total-Length instead of the length of the response array for determining the count of entities is straightforward.
The thing about retrieving the entity from a paged response is more tricky.
An alternative way to test that an entity was successfully added and the count of entities increased by one correctly would be to get the entity by ID and do another request to get the total count of entities.
e.g.
Current implementation, but I moved the logic to get the total count from the request to the function getDatabaseSize().
    @Test
    public void createMyEntityA() {
        var databaseSizeBeforeCreate = getDatabaseSize();

        // Create the MyEntityA
        myEntityA =
            given()
                .auth()
                .preemptive()
                .oauth2(adminToken)
                .contentType(APPLICATION_JSON)
                .accept(APPLICATION_JSON)
                .body(myEntityA)
                .when()
                .post("/api/my-entity-as")
                .then()
                .statusCode(CREATED.getStatusCode())
                .extract()
                .as(ENTITY_TYPE);

        // Validate the MyEntityA in the database
        var myEntityAList = given()
            .auth()
            .preemptive()
            .oauth2(adminToken)
            .accept(APPLICATION_JSON)
            .when()
            .get("/api/my-entity-as")
            .then()
            .statusCode(OK.getStatusCode())
            .contentType(APPLICATION_JSON)
            .extract()
            .as(LIST_OF_ENTITY_TYPE);

        assertThat(myEntityAList).hasSize(databaseSizeBeforeCreate + 1);
        var testMyEntityA = myEntityAList.stream().filter(it -> myEntityA.id.equals(it.id)).findFirst().get();
        assertThat(testMyEntityA.fieldName).isEqualTo(DEFAULT_FIELD_NAME);
    }

Alternative:
    @Test
    public void createMyEntityA() {
        var databaseSizeBeforeCreate = getDatabaseSize();

        // Create the MyEntityA
        myEntityA =
            given()
                .auth()
                .preemptive()
                .oauth2(adminToken)
                .contentType(APPLICATION_JSON)
                .accept(APPLICATION_JSON)
                .body(myEntityA)
                .when()
                .post("/api/my-entity-as")
                .then()
                .statusCode(CREATED.getStatusCode())
                .extract()
                .as(ENTITY_TYPE);

        // Validate the MyEntityA in the database
        var testMyEntityA = given()
            .auth()
            .preemptive()
            .oauth2(adminToken)
            .accept(APPLICATION_JSON)
            .when()
            .get("/api/my-entity-as/{id}", myEntityA.id)
            .then()
            .statusCode(OK.getStatusCode())
            .contentType(APPLICATION_JSON)
            .extract()
            .as(ENTITY_TYPE);

        var databaseSizeAfterCreate = getDatabaseSize();

        assertThat(databaseSizeAfterCreate).isEqualTo(databaseSizeBeforeCreate + 1);
        assertThat(testMyEntityA.fieldName).isEqualTo(DEFAULT_FIELD_NAME);
    }

This would introduce an extra request, to get databaseSizeAfterCreate though.
Thoughts on this?


Size of database file

Hi,
I have just tested your database library, it looks very promising.
However, the DB file size is 65% larger than our sqlite database (which contains indexes, unlike the Objectbox test db).
Is it because of the beta? Or is it because of the internal format of the DB ?
And, what is the max file size ? in the previous version, the app was crashing when DB file size > 1GB, but with the last release, the size seem to don't get higher than 1GB (and don't crash anymore).
Edit: Just tested again with multiple add/delete and finally, i still got the crash when i launch the app again:
[ERROR] Storage error "Cannot allocate memory" (code 12)
Thanks

We currently optimize for performance over on-disk size, so that is to be expected for now. That said, we've prototyped approaches to compression that should reduce on-disk footprint in the future, alas that is not implemented yet.
For the file size limit, there is a max file size parameter that you pass to the Store. when you create it. Have you tried increasing that?
That crash should actually be a Swift exception (we just didn't implement a lot of exception handling in the example app), so you could catch that instead of crashing (I'll verify that it is, if it wasn't before, it should be in the next release).
As to file size limits, as we memory-map the database, the only hard limit should be your CPU's addressable memory (not physical, so usually ~48 bits).

Ok,
Any "compact on launch"-like command ? To reclaim space after multiple delete/insert ?

Not at the moment, no, but I'll make a ticket for it.

Ok thanks.


Dko hotfix pt 2

hot fix for DKO which enables to use the dask-scheduler deployment/dask cuda worker daemonset as an alternative, and various chart cleanups

Awesome -- @aucahuasi can you take reviewing?


⚠ BCR Bot has degraded performance

In 44a4afb, BCR Bot (https://bcr.alternativasinteligentes.com/BCRApi/web/chatbot) experienced degraded performance:

HTTP code: 200
Response time: 1160 ms

Resolved: BCR Bot performance has improved in 780a969.


Update serialport to 4.2.0, remove obsolete language constructs, typos

Hi,
Are you looking for a maintainer for this?
I'm currently doing my own EnOcean project, and using this lib is faster than starting from scratch, but it could use some architectural improvements.

Hi,
Are you looking for a maintainer for this?
I'm currently doing my own EnOcean project, and using this lib is faster than starting from scratch, but it could use some architectural improvements.

Hello!
I indeed started this project as a rust training, few years ago.
I never took the time to work back on it but I would be glad to change that.
Would you like to draw some milestones together ?
NB: I am browsing github on my phone right now, and will get back on a décent device later ;)

Yes, sure!
I'm currently trying to pull data from temperature sensors and feed them to Prometheus, using the USB300 stick. I don't really need a full EnOcean lib for that, but I thought it would be nicer.
Everything in this branch should pass the tests (except for the failing test that was already on your branch); It's small fixes; the big changes are in a new API.
The things I'm looking at right now are:

[x] An incremental CRC8 interface
[ ] Separate framing and packet parsing/building

[x] A framing abstraction that only handles ESP3 header, CRC & buffer allocation
[ ] Packet parsing/building on top of that

[x] Using the stdlib's BufRead/Write interface for reading and writing frames
[x] Use num_enum to simplify byte tags handling
[ ] Refactor error handling with thiserror
[ ] Make the Packet datatype consistent (i.e. instead of a PacketType field and an enum for the payload, make it directly an enum of payloads )
[ ] Make the EEP interface extensible

[ ] Each EEP should be a distinct type implementing a trait
[ ] Should be possible to create a map of EEPs at runtime and use that for parsing

What do you think?

Hi,
Nice job, back at the time writing this code, you checklist was exactly the "dreamed implementation".
I would just add basics CI/CD stuff to your list.
I have to admit that it is my first "real life" experience building a code with people that do not sit on the desk just next to me ;). Maybe you can give me some hints on how to proceed?
Thx

Bah, I'm not that experienced with online collaboration either - but let's see how it goes!
I know almost nothing about CI/CD, so you'll probably have to do it yourself.
I think the best strategy would be to keep the existing API in the existing enocean/eep modules, but introduce new bricks in separate modules (like I did for crc8.rs and frame.rs). Then the old code can be transitioned to use the new code internally, while making sure the tests continue to pass.
First, please let me know what you think of the frame.rs interface. It's a bit awkward to have two types for the owned and borrowed versions of a frame, but that's more or less how stdlib does it, I think.
Next, I'll try to come up with a good packet datastructure, and put that in packet.rs, and then think about if the communicator can be improved too. Maybe the communicator should depend on a feature flag, so that the dependency to serialport can be dropped by people who don't need it?
(btw, the dependency tree for num_enums is quite impressive, but it is compile-time only afaik)
I'll implement as much as I can, and then you can decide if you want to merge the changes or not. I will try not to break any existing code that depends on the current API; currently the only breaking change I did was to change &Vec<u8> for &[u8], which is almost always desirable.

I know almost nothing about CI/CD, so you'll probably have to do it yourself.

perfect for me, if you can benefit from this I would be glad

I'll implement as much as I can, and then you can decide if you want to merge the changes or not. I will try not to break any existing code that depends on the current API; currently the only breaking change I did was to change &Vec for &[u8], which is almost always desirable.

I think the best strategy would be to keep the existing API in the existing enocean/eep modules, but introduce new bricks in separate modules (like I did for crc8.rs and frame.rs). Then the old code can be transitioned to use the new code internally, while making sure the tests continue to pass.

Given all the warnings in the readme, plus cargo dependencies management, I think it would be OK to break API (we'll just have to stick with semver, which I will take care in CI/CD stuff).
Nice idea to smoothen transition though.

First, please let me know what you think of the frame.rs interface. It's a bit awkward to have two types for the owned and borrowed versions of a frame, but that's more or less how stdlib does it, I think.

Well, that was my first thought also, but I cannot find any "more idimoatic" way to achieve same functionnality.

Maybe the communicator should depend on a feature flag, so that the dependency to serialport can be dropped by people who don't need it?

Nice idea, I can work on this if you want (though I have no idea how to do it yet)

(btw, the dependency tree for num_enums is quite impressive, but it is compile-time only afaik)

Thx for that, I sure will use this in another projects !

I discovered that using BufReader does not work on Windows. The idea was to make opportunistic big reads, but apparently on Windows it won't return partial reads unless EOF is reached (so, for a serial port, never).
The frame interface now uses Read instead of BufRead, meaning it could fail to synchronize if it repeatedly receives frames with 0x55 in the last 6 bytes of the frame. That should be fixed.
Here is a proposal for a basic communication port API.
The response packets (type 0x02) are synchronous in nature, but you cannot parse them properly without knowledge of the last request.
I want to make the port synchronous: after sending a request (type 0x05, or others that expect an answer), the port immediately starts to look for a response. Non-response packets will be queued, and delivered on subsequent read calls. Only when the queue is empty do we actually read the port.
For the packet interface, for now, all of them favor borrowing over owning. This is because borrowing is best for assembling packets without copy, and for parsing packets owned by the caller.
One possibility would be to use two different datatypes, one for received packets (owned) and one for packets about to be sent(borrowed). That also helps the user (no need to match for packet types that are only host->device after a parse, for instance), but it makes the lib unusable for anyone who'd like to do a device-side implementation. But maybe we should not care about device-side implementation?


Generating LoRA parameters with hypernetworks

Hi,
Thanks for open-sourcing this brilliant package! Similar to #6 , I also want to apply hypernetworks (HN) to LoRA, but my setting is a bit different. I have a base transformer model, and I want to use LoRA to adapt it to multiple different tasks. Instead of learning a separate adapter for each task, I want to use a single HN to generate different LoRA parameters for each task, by conditioning the HN on some task context that is different for each task. During the fine-tuning process, only the parameters of the HN are updated, while the base transformer is frozen. I was wondering that if you can give some suggestions or examples on how to implement this HN idea in lorax? Thanks a lot for your help!

Yeah so basically I'd try using lorax to lorafy the parameters of your base transformer. Take a look at them in the python interpreter, and figure out where the A/B values you want to generate are. Then, during your forward pass just generate the As and Bs and populate the tree with them. If you give me some minimal example code I can give you more specific pointers.

Thanks for your help! Here is a minimal example code of the transformer module I use:
class MlpBlock(nn.Module):
    """Transformer MLP / feed-forward block."""

    mlp_dim: int
    dtype: Dtype = jnp.float32
    out_dim: Optional[int] = None
    dropout_rate: float = 0.1
    kernel_init: Callable[
        [PRNGKey, Shape, Dtype], jax.Array
    ] = nn.initializers.xavier_uniform()
    bias_init: Callable[[PRNGKey, Shape, Dtype], jax.Array] = nn.initializers.normal(
        stddev=1e-6
    )

    @nn.compact
    def __call__(self, inputs, *, deterministic):
        """Applies Transformer MlpBlock module."""
        actual_out_dim = inputs.shape[-1] if self.out_dim is None else self.out_dim
        x = nn.Dense(
            features=self.mlp_dim,
            dtype=self.dtype,
            kernel_init=self.kernel_init,
            bias_init=self.bias_init,
            name="Dense_0",
        )(inputs)
        x = nn.gelu(x)
        x = nn.Dropout(rate=self.dropout_rate)(x, deterministic=deterministic)
        output = nn.Dense(
            features=actual_out_dim,
            dtype=self.dtype,
            kernel_init=self.kernel_init,
            bias_init=self.bias_init,
            name="Dense_1",
        )(x)
        output = nn.Dropout(rate=self.dropout_rate)(output, deterministic=deterministic)
        return output

class Encoder1DBlock(nn.Module):
    """Transformer encoder layer.

    Attributes:
      inputs: input data.
      mlp_dim: dimension of the mlp on top of attention block.
      dtype: the dtype of the computation (default: float32).
      dropout_rate: dropout rate.
      attention_dropout_rate: dropout for attention heads.
      deterministic: bool, deterministic or not (to apply dropout).
      num_heads: Number of heads in nn.MultiHeadDotProductAttention
    """

    mlp_dim: int
    num_heads: int
    dtype: Dtype = jnp.float32
    dropout_rate: float = 0.1
    attention_dropout_rate: float = 0.1

    @nn.compact
    def __call__(self, inputs, attention_mask, *, deterministic):
        """Applies Encoder1DBlock module.

        Args:
          inputs: Inputs to the layer.
          deterministic: Dropout will not be applied when set to true.

        Returns:
          output after transformer encoder block.
        """

        # Attention block.
        assert inputs.ndim == 3, f"Expected (batch, seq, hidden) got {inputs.shape}"
        x = nn.LayerNorm(dtype=self.dtype)(inputs)
        x = nn.MultiHeadDotProductAttention(
            dtype=self.dtype,
            kernel_init=nn.initializers.xavier_uniform(),
            broadcast_dropout=False,
            deterministic=deterministic,
            dropout_rate=self.attention_dropout_rate,
            num_heads=self.num_heads,
        )(x, x, mask=attention_mask)
        x = nn.Dropout(rate=self.dropout_rate)(x, deterministic=deterministic)
        x = x + inputs

        # MLP block.
        y = nn.LayerNorm(dtype=self.dtype)(x)
        y = MlpBlock(
            mlp_dim=self.mlp_dim, dtype=self.dtype, dropout_rate=self.dropout_rate
        )(y, deterministic=deterministic)

        return x + y

The transformer module is stacked for multiple layers to get the final model like below:
class Transformer(nn.Module):
    """Transformer Model Encoder for sequence to sequence translation.

    Attributes:
      num_layers: number of layers
      mlp_dim: dimension of the mlp on top of attention block
      num_heads: Number of heads in nn.MultiHeadDotProductAttention
      dropout_rate: dropout rate.
      attention_dropout_rate: dropout rate in self attention.
    """

    num_layers: int
    mlp_dim: int
    num_attention_heads: int
    dropout_rate: float = 0.1
    attention_dropout_rate: float = 0.1
    add_position_embedding: bool = False

    @nn.compact
    def __call__(self, x, attention_mask, *, train):
        """Applies Transformer model on the inputs.

        Args:
          x: Inputs to the layer.
          train: Set to `True` when training.

        Returns:
          output of a transformer encoder.
        """
        assert x.ndim == 3  # (batch, len, emb)

        if self.add_position_embedding:
            x = AddPositionEmbs(
                posemb_init=nn.initializers.normal(stddev=0.02),  # from BERT.
                name="posembed_input",
            )(x)
            x = nn.Dropout(rate=self.dropout_rate)(x, deterministic=not train)

        # Input Encoder
        for lyr in range(self.num_layers):
            x = Encoder1DBlock(
                mlp_dim=self.mlp_dim,
                dropout_rate=self.dropout_rate,
                attention_dropout_rate=self.attention_dropout_rate,
                name=f"encoderblock_{lyr}",
                num_heads=self.num_attention_heads,
            )(x, attention_mask, deterministic=not train)
        encoded = nn.LayerNorm(name="encoder_norm")(x)

        return encoded

My thought is to initialize the hypernetwork parameters inside class Transformer. The hypernetwork takes some context information (like task id, layer id in the model) as input, and have different output heads to generate the LoRA parameters for value, key, query, and the MLP layers respectively. Then I will pass the corresponding LoRA parameters to each Encoder1DBlock layer when calling them. Do you think this makes sense? Or maybe there are some better way to do this with lorax? Thanks!

I think the correct implementation depends a lot on what you want the hypernetwork to take as input. Are you going to compute all the lora weights at once, before beginning execution of your model? If so, I'd recommend making the hypernetwork a separate model (or at least making a new flax module which holds both the transformer and the hypernetwork).
The reason is that it's actually a little bit annoying to interact with parameters from within the context of a flax model, since they make everything appear to be OOP-y. You'd probably have to look into using lift (https://flax.readthedocs.io/en/latest/developer_notes/lift.html).


install error  Cannot open include file: 'node.h'

I have Windows 10 Pro x64, node v6.10.0, npm v3.10.10
when I make: npm install hummus , I have error:

what I do wrong?

Hard to say but it's probably not anything to do with node-gyp.  You should report this to the hummus project.  Good luck.

Thanks. Good luck.


Initialize angel_msgs/angel_debug, Update py-nodes to use message

This updates more than it ideally should but includes:

docker/support updates

Include additional option to angel-workspace-shell.sh script to automatically source the built workspace setup script, making it easier to get a "use my workspace" environment up.

Update smqtk-detection dep to use a pinned hash from master upstream. This should be temporary until there is a release with the desired fix in it. Pyproject/poetry.lock/Dockerfile have been updated to reflect/handle this.
added angel_msgs, including initial detection message
added a C++ package angel_debug with a very initial C++ version of the object detection debugging node. This is not complete but I didn't feel like extracting it from this history.
Add an uncrustify config and helper script for standard C++ code style, useful for future use of CI enforcement.

object_detector and object_detector_debug work on my end. Did not spend too much time trying the angel_debug overlay node.


Create WebFlux + Boot example

That would be very interessting.
Especially it looks like that
X-Forwarded-Prefix:
is no more added to Link in such a scenario
spring:
  main:
    web-application-type: reactiveserver:
server:
  forward-headers-strategy: native

Perhaps this could be some example:
private fun wrapInHateoas(someObject: SomeObject): Mono<EntityModel<SomeObject>> =
      someObject
          .toMono()
          .zipWith(linkTo(controller.getSomeObject(someObject.id)).withSelfRel().toMono()) {
              some: SomeObject, link: Link -> EntityModel(some, link)
            }


⚠ Bofrost.es has degraded performance

In 996b433, Bofrost.es (https://www.bofrost.es) experienced degraded performance:

HTTP code: 200
Response time: 1493 ms

Resolved: Bofrost.es performance has improved in e2f538a after 7 minutes.


az vm run-command results in ERROR: InvalidApiVersionParameter

Describe the bug

It seems the API being used to run az command by the azure-cli is too new for Az Compute resource provider? Target VM is on East US 2, Azure Commercial Cloud.
Error is as follows:
Code: InvalidApiVersionParameter
Message: The api-version '2021-07-01' is invalid. The supported versions are '2021-04-01,2021-01-01,2020-10-01,2020-09-01,2020-08-01,2020-07-01,2020-06-01,2020-05-01,2020-01-01,2019-11-01,2019-10-01,2019-09-01,2019-08-01,2019-07-01,2019-06-01,2019-05-10,2019-05-01,2019-03-01,2018-11-01,2018-09-01,2018-08-01,2018-07-01,2018-06-01,2018-05-01,2018-02-01,2018-01-01,2017-12-01,2017-08-01,2017-06-01,2017-05-10,2017-05-01,2017-03-01,2016-09-01,2016-07-01,2016-06-01,2016-02-01,2015-11-01,2015-01-01,2014-04-01-preview,2014-04-01,2014-01-01,2013-03-01,2014-02-26,2014-04'.
Boot config for cvuv-appliance1:

To Reproduce

Command being run:
az vm run-command invoke -g "$resourceGroup" -n "$vm" --command-id RunShellScript --scripts "echo 'test az run command'"

This is just an example, but populate the $resoruceGroup and $vm variables as needed and the error will return the same.
Expected behavior

The command should have run on the target VM. It was running fine a few days ago. As far as I know the API didn't change?
Environment summary

Azure CLI Version:
  "azure-cli": "2.32.0",
  "azure-cli-core": "2.32.0",
  "azure-cli-telemetry": "1.0.6",
  "extensions": {}

OS: Debian WSL - <IP_ADDRESS>-microsoft-standard-WSL2
/etc/os-release contents:
PRETTY_NAME="Debian GNU/Linux 11 (bullseye)"
NAME="Debian GNU/Linux"
VERSION_ID="11"
VERSION="11 (bullseye)"
VERSION_CODENAME=bullseye

Compute

Sorry, this is incorrect. Viewing https://github.com/Azure/azure-cli/issues/10641 I noticed I am having the same issue. I simply did not define one of the shell variables. The error does not match what is wrong here.
You can close the issue or make a new one regarding this error code inaccuracy. Thanks


pyspark.sql.utils.IllegalArgumentException: u"Could not parse table name from ...'

I m using:

spark 2.0.1
python 2.7.6
spark-redshift_2.10:2.0.1
RedshiftJDBC4-<IP_ADDRESS>7.jar

If I pass a regular table to option("dbtable", "my_table") it works good. Once I m passing a query as a dtable i m receiving the error. E.g.:
query = "(select ....) t"
jdbcDF = sqlContext.read.format("com.databricks.spark.redshift").option("url", "jdbc:redshift://hostname:5438/dbname?user=user&password=password").option("dbtable", query).option("tempdir", 's3n://path_for_temp_data').load()

Error:
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/spark/python/pyspark/sql/readwriter.py", line 153, in load
    return self._df(self._jreader.load())
  File "/usr/local/spark/python/lib/py4j-0.10.3-src.zip/py4j/java_gateway.py", line 1133, in __call__
  File "/usr/local/spark/python/pyspark/sql/utils.py", line 79, in deco
    raise IllegalArgumentException(s.split(': ', 1)[1], stackTrace)
pyspark.sql.utils.IllegalArgumentException: u"Could not parse table name from '(select ... ) t'"

It works good though when I m using RedShift as a regular jdbc source:
jdbcDF = sqlContext.read.format("jdbc").option("url", "jdbc:redshift://hostname:5438/dbname?user=user&password=password").option("dbtable", query).load()
Here is the full command I run from shell:
./bin/pyspark --master local --packages com.fasterxml.jackson.core:jackson-core:2.8.3,com.amazonaws:aws-java-sdk:1.11.48,org.apache.hadoop:hadoop-aws:2.6.0,com.databricks:spark-redshift_2.10:2.0.1 --exclude-packages com.fasterxml.jackson.core:jackson-annotations,com.sun.jersey:jersey-core,com.sun.jersey:jersey-json,org.codehaus.jettison:jettison,com.sun.xml.bind:jaxb-impl,javax.xml.bind:jaxb-api,javax.activation:activation,com.sun.jersey:jersey-server --driver-class-path /home/.../RedshiftJDBC4-<IP_ADDRESS>7.jar

Try omitting the t from your subquery. In other words, do
query = "(select ....)"

instead of
query = "(select ....) t"

The problem here is that this library's table name parser expects either a valid table identifier or a string which begins and ends with parentheses, so the trailing  t is throwing it off. We could do a better job of throwing an error message here.
Note, also, that you can pass .option(query, "select ...") and omit the the parentheses in that context.

Thank you, @JoshRosen .
The first suggestions works as expected (after removing t). However, when I m trying to pass option 'query' I receive error:
custom_query = "select t.column1, ... from my_table t"

>>> jdbcDF = sqlContext.read.format("com.databricks.spark.redshift").option("url", "jdbc:redshift://hostoname:5438/db?user=user&password=password").option(query, custom_query).option("tempdir", 's3n://my_temp_dir').load()

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/spark/python/pyspark/sql/readwriter.py", line 153, in load
    return self._df(self._jreader.load())
  File "/usr/local/spark/python/lib/py4j-0.10.3-src.zip/py4j/java_gateway.py", line 1133, in __call__
  File "/usr/local/spark/python/pyspark/sql/utils.py", line 79, in deco
    raise IllegalArgumentException(s.split(': ', 1)[1], stackTrace)
pyspark.sql.utils.IllegalArgumentException: u"You must specify a Redshift table name with the 'dbtable' parameter or a query with the 'query' parameter."

Any advise what I might do wrong here?

Take a closer look at the error message:

You must specify a Redshift table name with the 'dbtable' parameter or a query with the 'query' parameter.

You must supply exactly one of these options, but this message suggests that neither option has been set properly.
It looks like you wrote
.option(query, custom_query)

Can you try using
.option("query", custom_query)

instead, with the string "query"?

Thank you.
You are right, I missed quotes around the query. Now this option works as expected as well.
Btw, is that possible that passing query to 'dtable' works faster than with 'query' ?

AFAIK there shouldn't be a performance difference between dbtable with parentheses and query because both options currently get normalized to the same internal path.


Broken Link: Theme Generator Tool

https://developer.microsoft.com/en-us/fabric#/styles/themegenerator gets redirected to https://developer.microsoft.com/en-us/fabric#/styles/web which is not the Theme Generator Tool.
Haven't looked for a new link yet...

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

ID: 8c4c91be-dca2-6411-b707-a023ad26306c
Version Independent ID: 29ba4619-814e-784a-04a8-84b4d56933dd
Content: SharePoint site theming - JSON schema
Content Source: docs/declarative-customization/site-theming/sharepoint-site-theming-json-schema.md
Product: sharepoint
GitHub Login: @spdevdocs
Microsoft Alias: spdevdocs

Should point to: https://aka.ms/spthemebuilder
Will get docs updated, or feel free to submit PR ;)

https://aka.ms/themedesigner

Thanks for the info @joeparzel & @sparkitect! :) Submitted a PR to fix.


Bring back improvements from client project

Set the status code correctly on the 404 page
Remove graphql-tag from the final bundle since GraphQL queries are precompiled and don’t need graphql-tag at runtime
Remove Babel config to add polyfills, it’s already taken care of by ember-cli-babel-polyfills
Make sure to never cache /health, /robots.txt, sitemap.xml, /sw.js
Use cacheControl middleware to cache assets

🦀 Requesting reviewers for this pull request:

@loboulet (contributor with 0 commits in the last 90 days and 22 commits overall)


do not download whole file from remote mounted cloud when user cancel it

This is based on
https://github.com/nextcloud/server/issues/5279
if i have locally mounted remote drive,
for example rclone is mounting as fuse fs google drive to /local_folder
and when in nextcloud i start to download some big file,
and when i cancel it
php script still works, still is reading from google drive.
I think its probably because of sabre http sapi wants to immediately load whole big post data into input and read from it
as seen here:
https://github.com/fruux/sabre-http/blob/master/lib/Sapi.php
lines 50 - 53
$r = self::createFromServerArray($serverArr);
$r->setBody(fopen('php://input', 'r'));
$r->setPostData($_POST);
return $r;
How to do it that when user cancels downloads, it will stop, not still read?

http://php.net/manual/en/misc.configuration.php#ini.ignore-user-abort

i have it not changed, default, disabled. So it is not this.

i have checked inside php files.
When i changed ignore_user_abort(true) to (false) inside:
/var/www/nextcloud/apps/dav/appinfo/v1/webdav.php = NOT HELPED
/var/www/nextcloud/apps/dav/appinfo/v2/remote.php = NOT HELPED
/var/www/nextcloud/lib/private/legacy/files.php = NOT HELPED
/var/www/nextcloud/lib/private/Files/View.php -  YES - HELPED, now it works fine but is that really ok?

if ignore_user_abort didn't help, I don't think there's anything this package can do about this.


tts: asynchronous event callback

Fixes an issue caused by async cancel emission
Checklist

[x] npm test passes
[x] tests and/or benchmarks are included
[x] documentation is changed or added

Local unit test passed.


How to get transcription language in websocket response ?

Hello, thank you for this project, it looks incredible!
When using websockets with websocket_client, is there a way to get the detected language in the transcription result? Something like:
{
  "start": 11.22,
  "end": 16.580000000000002,
  "text": "This is a test sentence.",
  "detected_language": "en",  <- here
  "temperature": 0.0,
  "avg_logprob": -0.46804791405087426,
  "compression_ratio": 0.9428571428571428,
  "no_speech_prob": 0.23318801820278168
}

Thanks in advance !

Hello, thank you!
Unfortunately, the feature does not exist currently, but it can be implemented .
I open the issue #30 and will re-design the protocol of websocket.

Awesome, thanks!


adding MessageAnalysisCompletedEvent to EG SDk

Data Plane API - Pull Request

API Info: The Basics
Most of the information about your service should be captured in the issue that serves as your API Spec engagement record.

Link to API Spec engagement record issue:

Is this review for (select one):

[ ] a private preview
[ ] a public preview
[ ] GA release

Change Scope
This section will help us focus on the specific parts of your API that are new or have been modified. Please share a link to the design document for the new APIs, a link to the previous API Spec document (if applicable), and the root paths that have been updated.

Design Document:
Previous API Spec Doc:
Updated paths:

Viewing API changes
For convenient view of the API changes made by this PR, refer to the URLs provided in the table
in the Generated ApiView comment added to this PR. You can use ApiView to show API versions diff.
Suppressing failures
If one or multiple validation error/warning suppression(s) is detected in your PR, please follow the
Swagger-Suppression-Process
to get approval.
❔Got questions? Need additional info?? We are here to help!

 Contact us!
The Azure API Review Board is dedicated to helping you create amazing APIs. You can read about our mission and learn more about our process on our wiki.

💬 Teams Channel
💌 email

Click here for links to tools, specs, guidelines & other good stuff
Tooling

Open API validation tools were run on this PR. Go here to see how to fix errors
Spectral Linting
Open API Hub

Guidelines & Specifications

Azure REST API Guidelines
OpenAPI Style Guidelines
Azure Breaking Change Policy

Helpful Links

Schedule a data plane REST API spec review

Checks stuck in `queued` state?
If the PR CI checks appear to be stuck in `queued` state, please add a comment with contents `/azp run`.
This should result in a new comment denoting a `PR validation pipeline` has started and the checks should be updated after few minutes.

We no longer accept swagger PRs for system events. Instead, all new events need to be written in Typespec. For ACS, that would mean updating this file https://github.com/Azure/azure-rest-api-specs/blob/main/specification/eventgrid/Azure.Messaging.EventGrid.SystemEvents/Microsoft.Communication/AzureCommunicationServices.tsp


⚠ Bofrost.at has degraded performance

In 7fde8a2, Bofrost.at (https://www.bofrost.at) experienced degraded performance:

HTTP code: 200
Response time: 1746 ms

Resolved: Bofrost.at performance has improved in c779c4f after 13 minutes.


Improve service tab control buttons

Rename 'Cancel' to 'Close'
Make buttons more prominent

I did a few things:

Converted the control button to Dijit Button's instead of native ones.
Made the buttons bigger.
Added Icons
Allowed the cancel/close button label to be changed with a configuration setting.

Tested and doc'd.


Publish to sdkman

Could you guys please publish jmc to sdkman?
I know this isn't the right repo, but I couldnt find any better.

I'd like to see this too.  Interestingly, sdkman now lists an 8.0.0-adpt version as available for JMC. It would be great if this was updated for new releases.
I see a PR in the sdkman-db-migrations repo to add it, but it doesn't seem to follow the current onboarding advice, so maybe unrelated?
Looks like whatever is currently available from SDKMAN is configured to download from https://github.com/AdoptOpenJDK/openjdk-jmc-overrides/releases/download/8.0.0/org.openjdk.jmc-8.0.0-linux.gtk.x86_64.tar.gz , which then redirects here, so I'm guessing its out of date.

这是来自QQ邮箱的假期自动回复邮件。您好，我最近正在休假中，无法亲自回复您的邮件。我将在假期结束后，尽快给您回复。

sdkman has jmc now, but leading version is from zulu and it's still out of date, so I created an aur package https://aur.archlinux.org/packages/jmc-adoptium

这是来自QQ邮箱的假期自动回复邮件。您好，我最近正在休假中，无法亲自回复您的邮件。我将在假期结束后，尽快给您回复。


Rename xdai to gnosis

Changes:

Rename xDai to Gnosis

Types of changes

[x] Other (please describe):

Codecov Report
Patch and project coverage have no change.

Comparison is base (1df8b8a) 86.75% compared to head (aeaef1e) 86.75%.

Additional details and impacted files
@@           Coverage Diff            @@
##           develop     #308   +/-   ##
========================================
  Coverage    86.75%   86.75%
========================================
  Files           78       78
  Lines         4582     4582
========================================
  Hits          3975     3975
  Misses         522      522
  Partials        85       85

Flag
Coverage Δ

unittests
86.75% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

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


change the output of asg-capacity

It's currently "desired, maximum, minimum". That's not a very intuitive order. minimum, desired, maximum is probably better.
I've set this to milestone 1 because it's a minor change and will be a breaking change if we fix it later.

closed by b70d58e3cfa6702fb21414ddee8425818e9595de


Superior dropdown empty

When creating a new user the Superior dropdown is not populated and the field is required.
I'm using latest code from main branch with SQLite
Is this a bug or maybe I'm missing a step?

Thanks!

Hello @274188A,
Are you in development mode, if so, a few users are being generated automatically. The reason why they might not show up in the "Select Superior" dropdown is that those fields are being filled depending on what Tentan you have selected. Try setting Slave to Master, and check if you are now able to select a superior.
However @neozhu, if no user is present in a tenant, I can't figure out how to create a new account without a superior either. Could you take a look?

Thanks , yeah I have a brand new Tenant so this blocked me a bit.  I can see where we would need to fix it but my thoughts may not fit in with the owner.
my 2 c
So for a new tenant, if there are no other users in that tenant then the field need not be shown.
From that point on, we need to populate users from the tenant (excluding themselves).

That sounds like a good solution to me!
@neozhu What are your thoughts on this, or are we both overseeing something?

hi,
Regarding "Select Superior," I think the TenantId filter condition should be removed or allowed to be empty. The requirement of this mandatory field is hardcoded in the backend code, stating that it must be filled by non-admin users.

I see - so if I understood correctly, there is a relationship between a 'Superior' and the 'TenantId' of a user?


Error while running submitPT and submitFT   FileNotFoundError: [Errno 2] No such file or directory

Hi,
Error when running submitPT.py
(RL-GraphINVENT-env) user@Pramod:~$ python submitPT.py

Creating dataset directory output_chembl25_500k/train/
Creating model subdirectory output_chembl25_500k/train/job_0/
Running job as a normal process.
/home/anaconda3/envs/RL-GraphINVENT-env/bin/python
Running job using HDF datasets located at data/pre-training/chembl25_500k/
Checking that the relevant parameters match those used in preprocessing the dataset.
Traceback (most recent call last):
File "pre-training/main.py", line 5, in
import util
File "/home/RL-GraphINVENT/pre-training/util.py", line 6, in
from tensorboard_writer import writer as tb_writer
File "/home/RL-GraphINVENT/pre-training/tensorboard_writer.py", line 5, in
from parameters.constants import constants as C
File "/home/RL-GraphINVENT/pre-training/parameters/constants.py", line 255, in
job_dir=args.job_dir)
File "/home/RL-GraphINVENT/pre-training/parameters/constants.py", line 235, in collect_global_constants
params_to_check = load_params(input_csv_path=csv_file)
File "/home/cadd/RL-GraphINVENT/pre-training/parameters/constants.py", line 104, in load_params
with open(input_csv_path, "r") as csv_file:
FileNotFoundError: [Errno 2] No such file or directory: 'data/pre-training/chembl25_500k/preprocessing_params.csv'
-- Sleeping 2 seconds.

Error when running submitFT.py
(RL-GraphINVENT-env) user@Pramod:~$ python submitFT.py

Creating dataset directory output_chembl25_500k/score_name/
Creating model subdirectory output_chembl25_500k/score_name/job_0/
Running job as a normal process.
/home/anaconda3/envs/RL-GraphINVENT-env/bin/python
Running job using HDF datasets located at data/fine-tuning/chembl25_500k/
Checking that the relevant parameters match those used in preprocessing the dataset.
-- Job parameters match preprocessing parameters.
Run mode: 'generate'
Loading training set properties.
Loading model from previous saved state (Epoch 5).
Traceback (most recent call last):
File "fine-tuning/main.py", line 54, in
main()
File "fine-tuning/main.py", line 40, in main
workflow.generation_phase()
File "/home/RL-GraphINVENT/fine-tuning/Workflow.py", line 183, in generation_phase
self.agent_model = torch.load(model_path)
File "/home/anaconda3/envs/RL-GraphINVENT-env/lib/python3.6/site-packages/torch/serialization.py", line 419, in load
f = open(f, 'rb')
FileNotFoundError: [Errno 2] No such file or directory: 'output_chembl25_500k/score_name/job_0/model_restart_5.pth'
-- Sleeping 2 seconds.

I have encountered the same issues

same issues，
In submitPT.py, I used preprocessing_params.csv in data/fine-tuning/output_chembl25_500k, it can continue run for the problem of preprocessing_params.csv, but it also has problem with the files,

FileNotFoundError: [Errno 2] Unable to synchronously open file (unable to open file: name = 'data/pre-training/chembl25_500k/valid.h5', errno = 2, error message = 'No such file or directory', flags = 1, o_flags = 2)

I think there may be some prepocess program need to be excute before the pre-train.
submitFT.py is the same, it maybe need pre-train to generate the  model_restart_5.pth


Support safety_settings method parameter

With Vertex, there is the case that false positives occasionally arise in the safety settings due to using the "probability" method as default. To help fix the false positives, it would be desirable to switch to "severity" instead. This is not supposed in the way that LangChain accepts the safety_settings.
To fix the safety settings, it would likely break the current implementation since it is a dictionary rather than a proper object with the parameter names from Vertex. However, I think this is important to change to. If there are alternatives, please let me know. More details below and documentation from Vertex here.
Since langchain safety filters are in the format
{HarmCategory.HARM_CATEGORY_UNSPECIFIED: HarmBlockThreshold.BLOCK_LOW_AND_ABOVE,
it doesn't seem very conducive to doing the same in the Vertex SDK, but in Vertex I can do this and use severity rather than probability (the default) which is extremely helpful in reducing false positives
SafetySetting(
    category=SafetySetting.HarmCategory.HARM_CATEGORY_HARASSMENT,
    threshold=SafetySetting.HarmBlockThreshold.BLOCK_MEDIUM_AND_ABOVE,
    method: SafetySetting.HarmBlockMethod.SEVERITY
   )

I think this might be doable if the validation for SafetySettings is fixed in https://github.com/langchain-ai/langchain-google/blob/eedb0d2e105c3573388ab2470702871efcddaab2/libs/vertexai/langchain_google_vertexai/_base.py#L142C32-L142C50
Currently setting it in the non-dict format will fail with the following error message:
ValidationError: 1 validation error for ChatVertexAI
safety_settings
  value is not a valid dict (type=type_error.dict)

Investigating further, it looks like this has been fixed in https://github.com/langchain-ai/langchain-google/commit/4435b06ddd53cb06eddbd11f987b4b37bcf91d0b and we just need a new release

it looks like this one can be closed

I need to debug this further, but FYI it doesn't appear that this is being set when it's sent to Vertex (the method is not in the request object).

NVM - we are setting it, we just don't see it returned when using debug. I think when langchain gets the safetysetting back we need to return the severity parameters as well as the probability parameters.


Support for PSP titles

I hope it can support Adrenaline titles such as PSX / PSP created with Adrenaline Bubble Booter

..or better up, native support by PS/PSP/PSM/Minis titles.


Make the API module work on iOS

Kind (Required)

Improvement

Overview (Required)

Currently, adding an iOS target in the Kotlin Multiplatform settings will prevent code completion on the IDE. Probably a problem with GitLiveApp/firebase-kotlin-sdk.
I want to solve this problem and enable iOS targeting.

Links

Probably, adding it to gradle.properties will solve it.
kotlin.mpp.enableGranularSourceSetsMetadata=true
kotlin.native.enableDependencyPropagation=false

https://kotlinlang.org/docs/migrating-multiplatform-project-to-14.html#try-the-hierarchical-project-structure
https://kotlinlang.org/docs/mpp-share-on-platforms.html#share-code-on-similar-platforms

It's working fine in my environment 👍
If this is correct, I will create a pull-request 🙌

Thank you for investigating! Assigned!!

The problem seems like commonMain is using Arbor which does not support iOS.

I removed the arbor library. Thank you for reporting!


Optimize regexification of search tokens

Currently, Mongoid::Search turns your search terms into a list of simple, two-way wildcard regular expressions. However, two-way wildcards are very difficult for the query optimizer to handle, so this change only makes it a one-way wild card. Here's an example, wherein the collection being queried only has 100,000 documents -- note the nscanned value.
Person.collection.create_index '_keywords'

exp = Person.collection.find(:_keywords => {:$in => [/so/]}).explain
exp["nscanned"] # => 973496, almost 10 times the size of the collection
exp["millis"] # => 945
exp["nscannedObjects"] # => 4014
exp["n"] # => 4013

exp = Person.collection.find(:_keywords => {:$in => [/^so.*/]}).explain
exp["nscanned"] # => 4014, only scans one more document than we need
exp["millis"] # => 6
exp["nscannedObjects"] # => 4013
exp["n"] # => 4013

@mauriciozaffari any interest in pulling this in?

Hi Alex,
just too busy around here.
Anyway, it seems to me like something that should have a configuration option on it.
Can you provide it an option to choose between the two?
I'll be more than happy to merge it after that.

+1

@mauriciozaffari Sorry for the slow response, been pretty busy myself :) What do you have in mind for the configuration option?


patch releases don't appear in changelog

I noticed that the patch releases don't appear in the changelog: https://websockets.readthedocs.io/en/stable/changelog.html
It would be useful to be able to know how those differ from the minor version on which they're based.

4.0.1 was functionally identical to 4.0. I did it because wheels for 4.0 failed to build on Travis CI.
5.0.1 fixed a major regression in 5.0 (#411).

Thanks!


DateTimeFormatConst is private, clumsy for FromSql

If one needs to call FromSql, it would be helpful if there were a way to turn the Datetime to same kind of string as EF has done
E.g. in SQLite I had to hard code the DateTimeFormatConst's value @"yyyy\-MM\-dd HH\:mm\:ss.FFFFFFF" to my own program. Could it be exposed as a public value to help building FromSql bits that are more general?
Thanks

Our recommendation is to use parameterized queries, rather than stitching strings together - in this case EF will take care of the correct formatting. If you want to stitch strings together, then copying the format is an ok approach.


Isolate sql precommit

The commits are independent and should not be squashed:

Add ability to exclude patterns. Current Jenkins DSL docs imply a list of strings is applicable. Our "include" patterns concatenates them on newline.
Add SQL precommit (so it is in place before excluded from main Java precommit)
Exclude SQL precommit from the main Java precommit

After this, changes to the SQL extensions should not trigger the entire Java precommit. This can serve as a pattern for non-core Java changes.

Thank you for your contribution! Follow this checklist to help us incorporate your contribution quickly and easily:

[ ] Choose reviewer(s) and mention them in a comment (R: @username).
[ ] Format the pull request title like [BEAM-XXX] Fixes bug in ApproximateQuantiles, where you replace BEAM-XXX with the appropriate JIRA issue, if applicable. This will automatically link the pull request to the issue.
[ ] If this contribution is large, please file an Apache Individual Contributor License Agreement.

See the Contributor Guide for more tips on how to make review process smoother.

CC @apilloud @amaliujia @XuMingmin @xumingming @akedin
Just FYI about working toward separating the precommit

Run CommunityMetrics PreCommit

LGTM on the idea that SQL change should not trigger entire java precommit

run seed job

run seed job

run sql precommit

Confirmed that the tests executed are all SQL.


add related section in readme

I think this is related. I have good docs and tests.

Thanks :)!

Good to know you like it @kevva :smile:


minor changes on Sdk automl tabular regression online bq1

If you are opening a PR for Official Notebooks under the notebooks/official folder, follow this mandatory checklist:

[x] Use the notebook template as a starting point.
[x] Follow the style and grammar rules outlined in the above notebook template.
[x] Verify the notebook runs successfully in Colab since the automated tests cannot guarantee this even when it passes.
[ ] Passes all the required automated checks. You can locally test for formatting and linting with these instructions.
[ ] You have consulted with a tech writer to see if tech writer review is necessary. If so, the notebook has been reviewed by a tech writer, and they have approved it.
[ ] This notebook has been added to the CODEOWNERS file under # Official Notebooks section, pointing to the author or the author's team.
[ ] The Jupyter notebook cleans up any artifacts it has created (datasets, ML models, endpoints, etc) so as not to eat up unnecessary resources.

If you are opening a PR for Community Notebooks under the notebooks/community folder:

[ ] This notebook has been added to the CODEOWNERS file under the # Community Notebooks section, pointing to the author or the author's team.
[ ] Passes all the required formatting and linting checks. You can locally test with these instructions.

If you are opening a PR for Community Content under the community-content folder:

[ ] Make sure your main Content Directory Name is descriptive, informative, and includes some of the key products and attributes of your content, so that it is differentiable from other content
[ ] The main content directory has been added to the CODEOWNERS file under the # Community Content section, pointing to the author or the author's team.
[x] Passes all the required formatting and linting checks. You can locally test with these instructions.

/gcbrun

/gcbrun

/gcbrun

All the tests are passing -- just have a couple small comments, and this one is done.

Linter test still failing, make sure to run nbfmt step

/gcbrun

/gcburn

/gcbrun


Flutter imports are not case sensitive resulting in static variables not behaving correctly

Steps to reproduce

Create a new file with a static boolean variable.
Import the file in two separate files, one with capital letters in the import path and the other with the correct casing
Set the static variable to true and update state for both
The variable is true with the correct import and false without
Zero indication anywhere that the reason is the import is incorrect

This issue has already been reported here and for some reason nothing has been done about it and it's just been closed. https://github.com/flutter/flutter/issues/98993
I just spent an hour tearing my hair out over what appeared to be a completely impossible problem. The reason is the import has been "found" despite the incorrect file name but it has not since it's a totally different static variable. It's very easy to have this kind of error when you're running some kind of find and replace action.
Expected results
It should flag a huge error up saying your file import is completely incorrect.
Actual results
The import sits there like it's perfectly fine with no error in sight.
Code sample
Code sample
import '../utils/Demo.dart';

vs

import '../utils/demo.dart';

This is a general dart issue rather than a flutter issue. See https://github.com/dart-lang/linter/issues/3244
Kindly follow up in the issue linked above for updates.
Closing from here.
Thank you


I'm a Beginner, there is some problem for me, someone can help me? thx ^_^

when I run the python demo.py , OOM occurred like below:
RuntimeError: CUDA out of memory. Tried to allocate 44.00 MiB (GPU 0; 1.95 GiB total capacity; 1.23 GiB already allocated; 2.62 MiB free; 98.86 MiB cached)
so where is bitch_size?
thx ^_^

In CornerNet.json,you should change both batch_size and chunk_sizes.For example, the batch_size is 30, the  chunk_sizes is [15, 15]

In CornerNet.json,you should change both batch_size and chunk_sizes.For example, the batch_size is 30, the chunk_sizes is [15, 15]

thx for your answer.^_^
my CornerNet.json is like below:
But it's still OOM  T_T
"system": {
"dataset": "COCO",
"batch_size": 1,
"sampling_function": "cornernet",
    "train_split": "trainval",
    "val_split": "minival",

    "learning_rate": 0.00025,
    "decay_rate": 10,

    "val_iter": 100,

    "opt_algo": "adam",
    "prefetch_size": 5,

    "max_iter": 500000,
    "stepsize": 450000,
    "snapshot": 5000,

    "chunk_sizes": [15, 15],

    "data_dir": "./data"
}

[root@localhost CornerNet-Lite]# python3 demo.py
total parameters: 116969339
loading from /data/MachineLearning/CornerNet-Lite/core/../cache/nnet/CornerNet_Saccade/CornerNet_Saccade_500000.pkl
/usr/local/python3/lib/python3.7/site-packages/torch/nn/functional.py:2423: UserWarning: Default upsampling behavior when mode=bilinear is changed to align_corners=False since 0.4.0. Please specify align_corners=True if the old behavior is desired. See the documentation of nn.Upsample for details.
"See the documentation of nn.Upsample for details.".format(mode))
Traceback (most recent call last):
File "demo.py", line 10, in
bboxes = detector(image)
File "/data/MachineLearning/CornerNet-Lite/core/base.py", line 25, in call
bboxes = self._inference(image, *args, **kwargs)
File "/data/MachineLearning/CornerNet-Lite/core/base.py", line 21, in _inference
return self._func(self._db, self._nnet, image.copy(), *args, **kwargs)
File "/data/MachineLearning/CornerNet-Lite/core/test/cornernet_saccade.py", line 346, in cornernet_saccade_inference
dets, atts = decode_func(db, nnet, images, no_att=no_att)
File "/data/MachineLearning/CornerNet-Lite/core/test/cornernet_saccade.py", line 77, in batch_decode
test=True, num_dets=num_dets, no_border=True, no_att=no_att
File "/data/MachineLearning/CornerNet-Lite/core/nnet/py_factory.py", line 112, in test
return self.model(*xs, **kwargs)
File "/usr/local/python3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 489, in call
result = self.forward(*input, **kwargs)
File "/data/MachineLearning/CornerNet-Lite/core/nnet/py_factory.py", line 30, in forward
return self.module(*xs, **kwargs)
File "/usr/local/python3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 489, in call
result = self.forward(*input, **kwargs)
File "/data/MachineLearning/CornerNet-Lite/core/models/py_utils/modules.py", line 303, in forward
return self._test(*xs, **kwargs)
File "/data/MachineLearning/CornerNet-Lite/core/models/py_utils/modules.py", line 280, in _test
cnvs, ups = self.hg(image)
File "/usr/local/python3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 489, in call
result = self.forward(*input, **kwargs)
File "/data/MachineLearning/CornerNet-Lite/core/models/py_utils/modules.py", line 234, in forward
inter = self.intersind
File "/usr/local/python3/lib/python3.7/site-packages/torch/nn/modules/module.py", line 489, in call
result = self.forward(*input, **kwargs)
File "/data/MachineLearning/CornerNet-Lite/core/models/py_utils/utils.py", line 194, in forward
return self.relu(bn2 + skip)
RuntimeError: CUDA out of memory. Tried to allocate 44.00 MiB (GPU 0; 1.95 GiB total capacity; 1.21 GiB already allocated; 20.62 MiB free; 75.49 MiB cached)
[root@localhost CornerNet-Lite]#

How many GPU do you have? If you have just one, I think you can try set chunk_sizes=[1].

How many GPU do you have? If you have just one, I think you can try set chunk_sizes=[1].

OOM  T_T
But if I use debug mode to execute setp by setp, it can be done.
Maybe I should change my video card >_<
[root@localhost ~]# nvidia-smi
Tue May  7 20:31:20 2019
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 418.56       Driver Version: 418.56       CUDA Version: 10.1     |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  GeForce GTX 750 Ti  Off  | 00000000:01:00.0  On |                  N/A |
| 38%   28C    P8     1W /  38W |    222MiB /  1999MiB |      0%      Default |
+-------------------------------+----------------------+----------------------+
+-----------------------------------------------------------------------------+
| Processes:                                                       GPU Memory |
|  GPU       PID   Type   Process name                             Usage      |
|=============================================================================|
|    0     12655      G   /usr/bin/X                                   109MiB |
|    0     13192      G   /usr/bin/gnome-shell                         110MiB |
+-----------------------------------------------------------------------------+
[root@localhost ~]#


Fix handling of Cache-Control header.

Fixes #48.

@dlecocq: This is the price of mocks. You could be testing behavior that differs from reality.

I would argue that fixtures would have this same problem. We could have made an asis page with the same error.
I should have captured a in-the-wild example first.


Add new answers to "randomanswer"

Add 3 new answers to .randomanswer.

I just copy again your commit 57638e9 @Ecuacion, becuase there was a "Merge Conflicts" if you don't want this, I can close the pr and open another.


Error while deserializing header: HeaderTooLarge

SafetensorError                           Traceback (most recent call last)
 in <cell line: 6>()
4
5 LPWStableDiffusionPipeline = get_class_from_dynamic_module("lpw_stable_diffusion", module_file="lpw_stable_diffusion.py")
----> 6 colab.load_model(LPWStableDiffusionPipeline)
4 frames
/content/StableDiffusionUi/ColabUI/ColabWrapper.py in load_model(self, pipeline_interface, custom_pipeline)
26
27         #TODO we can try catch here, and load file itself if diffusers doesn't want to load it for us
---> 28         self.pipe = loader_func(model_id,
29             custom_pipeline=custom_pipeline,
30             torch_dtype=torch.float16).to("cuda")
/usr/local/lib/python3.10/dist-packages/huggingface_hub/utils/_validators.py in _inner_fn(*args, **kwargs)
116             kwargs = smoothly_deprecate_use_auth_token(fn_name=fn.name, has_token=has_token, kwargs=kwargs)
117
--> 118         return fn(*args, **kwargs)
119
120     return _inner_fn  # type: ignore
/usr/local/lib/python3.10/dist-packages/diffusers/loaders/single_file.py in from_single_file(cls, pretrained_model_link_or_path, **kwargs)
261             )
262
--> 263         pipe = download_from_original_stable_diffusion_ckpt(
264             pretrained_model_link_or_path,
265             pipeline_class=cls,
/usr/local/lib/python3.10/dist-packages/diffusers/pipelines/stable_diffusion/convert_from_ckpt.py in download_from_original_stable_diffusion_ckpt(checkpoint_path_or_dict, original_config_file, image_size, prediction_type, model_type, extract_ema, scheduler_type, num_in_channels, upcast_attention, device, from_safetensors, stable_unclip, stable_unclip_prior, clip_stats_path, controlnet, adapter, load_safety_checker, pipeline_class, local_files_only, vae_path, vae, text_encoder, text_encoder_2, tokenizer, tokenizer_2, config_files)
1255             from safetensors.torch import load_file as safe_load
1256
-> 1257             checkpoint = safe_load(checkpoint_path_or_dict, device="cpu")
1258         else:
1259             if device is None:
/usr/local/lib/python3.10/dist-packages/safetensors/torch.py in load_file(filename, device)
306     """
307     result = {}
--> 308     with safe_open(filename, framework="pt", device=device) as f:
309         for k in f.keys():
310             result[k] = f.get_tensor(k)
SafetensorError: Error while deserializing header: HeaderTooLarge
Error from Load chosen model

It would be helpful if you tell me what exactly you tried to load.
It seems that something is wrong with huggingface trying to download a file. You can try to download the file first using
!wget "your url" --content-disposition

and then load it using local path.


[Feature] SCAN limit and return cursor

Describe the solution you'd like
Actually not sure if this is a feature or bug - I would like an ergonomic way to stop the SCAN streams when they hit a certain number of results, and then return the last cursor (or just "0" if it got all the results). Then the SCAN commands would also have an Option<String> parameter to provide the cursor to start from. Basically, this would allow us to "paginate" the results.
Something like: client.scan(pattern, count, Some(cursor), Some(max_count))
Additional context
The way I'm doing this right now does work, but it feels clunky, and I see errors in the DEBUG logs that indicate that the client is still scanning all the results after I break the loop. Maybe there's a better way to do this, so do let me know if so.
Current code (abbreviated):
let count: u32 = 100;
let max_count: usize = 1000;
let mut scan_stream = client.scan("foo:*", Some(count), None);
let mut keys: Vec<String> = vec![];
let mut current_cursor: Option<String> = None;

while let Some(mut scan_result) = scan_stream.try_next().await? {
    current_cursor = scan_result.cursor().map(|c| c.to_string());
    if let Some(page) = scan_result.take_results() {
        keys.extend(
            page.iter()
                .map(|key| key.as_str_lossy()),
        );
    }
    let _ = scan_result.next();
    if keys.len() >= max_count {
        break;
    }
}

When there are more results than max_count and the loop breaks early, here are the DEBUG errors I see. I assume this means that the client is still scanning all pages:
fred-RB7FokOcij: Error sending SCAN page.
fred-RB7FokOcij: Error sending SCAN page.
fred-RB7FokOcij: Error sending SCAN page.
....

Hey @fa-sharp, this'll be added in the next version (https://github.com/aembke/fred.rs/pull/314). Here's an example of what the interface will look like: https://github.com/aembke/fred.rs/blob/feat/10.0.0/examples/scan.rs#L52-L74

Looks great, thank you!! I ended up using a custom command to do something similar in the meantime, but that should work nicely once it's released.

Sounds good, I just merged v10.0.0 so I'll close this for now.