Vulnerabilities when installing Gridsome dependencies

Am I doing something wrong or you guys have some outdated dependencies????
I'm having "found 14 vulnerabilities (8 moderate, 5 high, 1 critical) " when run npm update -> npm install in my gridsome project (I have the latest "gridsome": "^0.7.23" version )
__
Moderate        Improper Input Validation

  Package         sanitize-html

  Patched in      >=2.3.1

  Dependency of   @gridsome/transformer-remark

  Path            @gridsome/transformer-remark > sanitize-html

  More info       https://npmjs.com/advisories/1675

  Moderate        Improper Input Validation

  Package         sanitize-html

  Patched in      >=2.3.2

  Dependency of   @gridsome/transformer-remark

  Path            @gridsome/transformer-remark > sanitize-html

  More info       https://npmjs.com/advisories/1676

  High            Regular Expression Denial of Service in trim

  Package         trim

  Patched in      >=0.0.3

  Dependency of   @gridsome/transformer-remark

  Path            @gridsome/transformer-remark > remark-html >
                  mdast-util-to-hast > trim

  More info       https://npmjs.com/advisories/1700

  High            Regular Expression Denial of Service in trim

  Package         trim

  Patched in      >=0.0.3

  Dependency of   @gridsome/transformer-remark

  Path            @gridsome/transformer-remark > remark-parse > trim

  More info       https://npmjs.com/advisories/1700

  Moderate        Regular expression denial of service

  Package         glob-parent

  Patched in      >=5.1.2

  Dependency of   @gridsome/source-filesystem

  Path            @gridsome/source-filesystem > chokidar > glob-parent

  More info       https://npmjs.com/advisories/1751

  Moderate        Regular expression denial of service

  Package         glob-parent

  Patched in      >=5.1.2

  Dependency of   gridsome

  Path            gridsome > chokidar > glob-parent

  More info       https://npmjs.com/advisories/1751

  Moderate        Regular expression denial of service

  Package         glob-parent

  Patched in      >=5.1.2

  Dependency of   gridsome

  Path            gridsome > webpack > watchpack > watchpack-chokidar2 >
                  chokidar > glob-parent

  More info       https://npmjs.com/advisories/1751

  Moderate        Regular expression denial of service

  Package         glob-parent

  Patched in      >=5.1.2

  Dependency of   @gridsome/source-filesystem

  Path            @gridsome/source-filesystem > globby > fast-glob >
                  glob-parent

  More info       https://npmjs.com/advisories/1751

  Moderate        Regular expression denial of service

  Package         glob-parent

  Patched in      >=5.1.2

  Dependency of   gridsome

  Path            gridsome > imagemin > globby > fast-glob > glob-parent

  More info       https://npmjs.com/advisories/1751

  Moderate        Regular expression denial of service

  Package         glob-parent

  Patched in      >=5.1.2

  Dependency of   gridsome

  Path            gridsome > globby > fast-glob > glob-parent

  More info       https://npmjs.com/advisories/1751

  High            Regular Expression Denial of Service

  Package         trim-newlines

  Patched in      >=3.0.1 <4.0.0 || >=4.0.1

  Dependency of   gridsome

  Path            gridsome > imagemin-mozjpeg > mozjpeg > logalot > squeak >
                  lpad-align > meow > trim-newlines

  More info       https://npmjs.com/advisories/1753

  High            Regular Expression Denial of Service

  Package         trim-newlines

  Patched in      >=3.0.1 <4.0.0 || >=4.0.1

  Dependency of   gridsome

  Path            gridsome > imagemin-pngquant > pngquant-bin > logalot >
                  squeak > lpad-align > meow > trim-newlines

  More info       https://npmjs.com/advisories/1753

  High            Regular Expression Denial of Service

  Package         trim-newlines

  Patched in      >=3.0.1 <4.0.0 || >=4.0.1

  Dependency of   gridsome

  Path            gridsome > imagemin-webp > cwebp-bin > logalot > squeak >
                  lpad-align > meow > trim-newlines

  More info       https://npmjs.com/advisories/1753
```__

That was my 2 year old project. So I have just created Gridsome new start up with "gridsome create my-gridsome-site" cli. Running "npm install" command brings "found 7 vulnerabilities (4 moderate, 3 high)":
=== npm audit security report ===
                                 Manual Review
             Some vulnerabilities require your attention to resolve

          Visit https://go.npm.me/audit-guide for additional guidance

  Moderate        Regular expression denial of service

  Package         glob-parent

  Patched in      >=5.1.2

  Dependency of   gridsome

  Path            gridsome > chokidar > glob-parent

  More info       https://npmjs.com/advisories/1751

  Moderate        Regular expression denial of service

  Package         glob-parent

  Patched in      >=5.1.2

  Dependency of   gridsome

  Path            gridsome > webpack > watchpack > watchpack-chokidar2 >
                  chokidar > glob-parent

  More info       https://npmjs.com/advisories/1751

  Moderate        Regular expression denial of service

  Package         glob-parent

  Patched in      >=5.1.2

  Dependency of   gridsome

  Path            gridsome > globby > fast-glob > glob-parent

  More info       https://npmjs.com/advisories/1751

  Moderate        Regular expression denial of service

  Package         glob-parent

  Patched in      >=5.1.2

  Dependency of   gridsome

  Path            gridsome > imagemin > globby > fast-glob > glob-parent

  More info       https://npmjs.com/advisories/1751

  High            Regular Expression Denial of Service

  Package         trim-newlines

  Patched in      >=3.0.1 <4.0.0 || >=4.0.1

  Dependency of   gridsome

  Path            gridsome > imagemin-mozjpeg > mozjpeg > logalot > squeak >
                  lpad-align > meow > trim-newlines

  More info       https://npmjs.com/advisories/1753

  High            Regular Expression Denial of Service

  Package         trim-newlines

  Patched in      >=3.0.1 <4.0.0 || >=4.0.1

  Dependency of   gridsome

  Path            gridsome > imagemin-pngquant > pngquant-bin > logalot >
                  squeak > lpad-align > meow > trim-newlines

  More info       https://npmjs.com/advisories/1753

  High            Regular Expression Denial of Service

  Patched in      >=3.0.1 <4.0.0 || >=4.0.1

  Dependency of   gridsome

  Path            gridsome > imagemin-webp > cwebp-bin > logalot > squeak >
                  lpad-align > meow > trim-newlines

  More info       https://npmjs.com/advisories/1753

Nothing critical though as project runs with no errors, but I'm not sure how those dependencies will affect the code in future???

This post on npm audit explains these quite well: https://overreacted.io/npm-audit-broken-by-design/
Generally, "Regular Expression Denial of Service" in those packages are not actually making your web app vulnerable.

Hey Allan, thanks for pointing to that article. Makes sense now.


⚠ Fortnite has degraded performance

In 06aaa2c, Fortnite (https://fortnite.com) experienced degraded performance:

HTTP code: 200
Response time: 1790 ms

Resolved: Fortnite performance has improved in d73b0a8.


feat/improve_backtesting

Before submitting this PR, please make sure:

[ ] Your code builds clean without any errors or warnings
[ ] You are using approved title ("feat/", "fix/", "docs/", "refactor/")

A description of the changes proposed in the pull request:
Tests performed by the developer:
Tips for QA testing:

Test commit db44ef801a042bdf95a14473eac0cbc90a85dd54

Setup PR with deploy ✅
Create config xgridt and run on dashboard

Successfully launch bot okay but need more test for new controller in progress

Ran mexc tests and compare with development branch
Relay gateway/amm changes test to @nikspz


Why could PKCS11_TOKEN_PIN equal None?

Hi @danni,
I was wondering which specific use case would require a None value for PKCS11_TOKEN_PIN? Most tests would fail on a decent PKCS#11 implementation, so is it addressing a specific one?
https://github.com/danni/python-pkcs11/blob/82cf55683bedc7a662de7351d5db9ff07bb6248d/tests/__init__.py#L20

Passing None means to skip login to the session.

So, when I run tests without defining a user PIN for the token (i.e. PKCS11_TOKEN_PIN equals None), many (but not all) fail:
...
test_encrypt (tests.test_aes.AESTests) ... ERROR
test_encrypt_big_string (tests.test_aes.AESTests) ... ERROR
test_encrypt_stream (tests.test_aes.AESTests) ... ERROR
test_encrypt_whacky_sizes (tests.test_aes.AESTests) ... ERROR
test_sign (tests.test_aes.AESTests) ... ERROR
test_sign_stream (tests.test_aes.AESTests) ... ERROR
test_wrap (tests.test_aes.AESTests) ... ERROR
test_encrypt_oaep (tests.test_rsa.RSATests) ... ERROR
test_encrypt_too_much_data (tests.test_rsa.RSATests) ... ERROR
test_key_wrap (tests.test_rsa.RSATests) ... ERROR
test_sign_default (tests.test_rsa.RSATests) ... ERROR
test_sign_pkcs_v15 (tests.test_rsa.RSATests) ... ERROR
test_sign_pss (tests.test_rsa.RSATests) ... ERROR
test_sign_stream (tests.test_rsa.RSATests) ... ERROR
...

Should there be some decorator to skip tests where a PIN is actually needed?

It really depends on the implementation you're testing against.

..are you suggesting some implementations aren't requiring a C_Login() to interact with the private objects? That would be pretty much non compliant with the specs.
I was only suggesting (and volunteering) to add some decorators around these test cases that require C_Login(). If no password is given, fair enough, these would be skipped.

Just that there's some C_Login implementations we're not handling yet (e.g. Out of Band), so I wouldn't go adding a lot of decorators for it. At the moment not supplying a pin causes it to skip of C_Login, and I'm pretty sure I've seen a USB key where everything was a public object.

OK, so let's leave it as it is for now. Thanks for the rationale.


Bugfix: Albert load workflow opt

Bug: operator links disappear when using version switching feature
Cause:

Jointjs attempts to sort DOM elements using z attributes saved in it's internal model.
However, during async mode, the visible DOM is out of sync with the internal model.
Thus, jointjs sometimes cannot find the elements that exist in the DOM (they have been deleted, for example)

Solution:

disable sorting during async mode

Superseded by #1482


Error finding util/twi.h

In file included from /home/parker/Pictures/PackProbe/PackProbe.ino:54:0:
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:81:22: fatal error: util/twi.h: No such file or directory
compilation terminated.
Error compiling for board Teensy 3.6.

[parker@e55 ~]$ find /usr/share/arduino/ -name "*twi.h"
/usr/share/arduino/hardware/teensy/avr/libraries/Wire/utility/twi.h
/usr/share/arduino/hardware/archlinux-arduino/avr/libraries/Wire/src/utility/twi.h

I tried changing the twi.h include to the absolute path
#include </usr/share/arduino/hardware/teensy/avr/libraries/Wire/utility/twi.h>

But that ends up with this
In file included from /home/parker/Pictures/PackProbe/PackProbe.ino:54:0:
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h: In function 'void i2c_wait_scl_high()':
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:228:39: error: '_SFR_IO_ADDR' was not declared in this scope
 #define SCL_IN  (_SFR_IO_ADDR(SCL_PORT) - 2)
                                       ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:265:23: note: in expansion of macro 'SCL_IN'
      : : [SCLIN] "I" (SCL_IN), [SCLPIN] "I" (SCL_PIN));
                       ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h: In function 'bool i2c_init()':
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:224:46: error: '_SFR_IO_ADDR' was not declared in this scope
 #define SCL_DDR        (_SFR_IO_ADDR(SCL_PORT) - 1)
                                              ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:346:23: note: in expansion of macro 'SCL_DDR'
        [SCLDDR] "I"  (SCL_DDR), [SCLPIN] "I" (SCL_PIN),
                       ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h: In function 'bool i2c_start(uint8_t)':
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:223:46: error: '_SFR_IO_ADDR' was not declared in this scope
 #define SDA_DDR        (_SFR_IO_ADDR(SDA_PORT) - 1)
                                              ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:409:25: note: in expansion of macro 'SDA_DDR'
      : : [SDADDR] "I"  (SDA_DDR), [SDAPIN] "I" (SDA_PIN),
                         ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h: In function 'bool i2c_rep_start(uint8_t)':
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:224:46: error: '_SFR_IO_ADDR' was not declared in this scope
 #define SCL_DDR        (_SFR_IO_ADDR(SCL_PORT) - 1)
                                              ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:453:25: note: in expansion of macro 'SCL_DDR'
      : : [SCLDDR] "I"  (SCL_DDR), [SCLPIN] "I" (SCL_PIN),
                         ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h: In function 'bool i2c_start_wait(uint8_t)':
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:223:46: error: '_SFR_IO_ADDR' was not declared in this scope
 #define SDA_DDR        (_SFR_IO_ADDR(SDA_PORT) - 1)
                                              ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:554:24: note: in expansion of macro 'SDA_DDR'
     : : [SDADDR] "I"  (SDA_DDR), [SDAPIN] "I" (SDA_PIN), [SDAOUT] "I" (SDA_OUT),
                        ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:559:1: warning: no return statement in function returning non-void [-Wreturn-type]
 }
 ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h: In function 'void i2c_stop()':
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:224:46: error: '_SFR_IO_ADDR' was not declared in this scope
 #define SCL_DDR        (_SFR_IO_ADDR(SCL_PORT) - 1)
                                              ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:606:25: note: in expansion of macro 'SCL_DDR'
      : : [SCLDDR] "I"  (SCL_DDR), [SCLPIN] "I" (SCL_PIN), [SCLIN] "I" (SCL_IN),
                         ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h: In function 'bool i2c_write(uint8_t)':
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:224:46: error: '_SFR_IO_ADDR' was not declared in this scope
 #define SCL_DDR        (_SFR_IO_ADDR(SCL_PORT) - 1)
                                              ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:734:22: note: in expansion of macro 'SCL_DDR'
       [SCLDDR] "I"  (SCL_DDR), [SCLPIN] "I" (SCL_PIN), [SCLIN] "I" (SCL_IN),
                      ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h: In function 'uint8_t i2c_read(bool)':
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:224:46: error: '_SFR_IO_ADDR' was not declared in this scope
 #define SCL_DDR        (_SFR_IO_ADDR(SCL_PORT) - 1)
                                              ^
/home/parker/Arduino/libraries/SoftI2CMaster/SoftI2CMaster.h:844:22: note: in expansion of macro 'SCL_DDR'
       [SCLDDR] "I"  (SCL_DDR), [SCLPIN] "I" (SCL_PIN), [SCLIN] "I" (SCL_IN),
                      ^
Error compiling for board Teensy 3.6.

Use the SoftI2C from https://github.com/felias-fogg/SoftI2CMaster
Here's my sketch for reference
/************************************************************************************

  PackProbe

  by Erik Speckman

  For documentation and the latest version see: http://powercartel.com/projects/packprobe/
  Source Repository: git@github.com:PowerCartel/PackProbe.git

  Depends on SoftI2CMaster http://playground.arduino.cc/Main/SoftwareI2CLibrary

  PackProbe allows you to obtain detailed history and health information on laptop battery
  packs without access to the corresponding laptop.

  This is is a proof of concept. It doesn't handle error conditions and spurious values

  PackProbe is based on:
  http://linuxehacking.blogspot.com/2014/03/recharging-and-reusing-acer-laptop.html
  and http://forum.arduino.cc/index.php?topic=62955.0

*************************************************************************************/

/************************************************************************************

  Configure and then load the SoftI2CMaster library

  The default is for data (SDA) on DPin6 and clock (SDC) on DPin8 on the Arduino Yun.

  For more details on configuring the library, see:
  http://playground.arduino.cc/Main/SoftwareI2CLibrary

  For background on Arduino Port and Pin Mapping, see:
  http://www.arduino.cc/en/Reference/PortManipulation

  To find the pin mappings for your board see:
  Atmega 168/328 MCU (Uno, Mini, Nano, Fio, Pro):
    http://arduino.cc/en/Hacking/PinMapping168

  Atmega 32u4 MCU (Yun, Leonardo, Micro):
    http://arduino.cc/en/Hacking/PinMapping32u4

*************************************************************************************/

//  Arduino Dpin6 = Atmega PD7
#define SDA_PORT PORTD
#define SDA_PIN 7

// Arduino DPin8 = Atmega PB4
#define SCL_PORT PORTB
#define SCL_PIN 4

#define I2C_SLOWMODE 1
#include <SoftI2CMaster.h>

// standard I2C address for Smart Battery packs
byte deviceAddress = 11;

/************************************************************************************

  Output Selection

  This sketch was made to run on the WiFi-enabled Arduino Yun.

  The default programming and output connection of the Yun is over TCP/IP
  rather than the serial connection used by most other Arduino boards.

  The default output on the Yun is available through the Console library.

  If you are using this sketch on board with a serial port, you'll need to
  #include <Serial.h> instead and change every instance of "Console." in the
  code to "Serial." In addition you need to comment/uncomment the necessary
  code in the setup function before compiling and installing on your board.

  We are looking for a clean way to simplify this configuration in the future,
  or make it automatic. Suggestions welcome.

*************************************************************************************/

// Yun Bridge Console Access
// Standard and common non-standard Smart Battery commands
#define BATTERY_MODE             0x03
#define TEMPERATURE              0x08
#define VOLTAGE                  0x09
#define CURRENT                  0x0A
#define RELATIVE_SOC             0x0D
#define ABSOLUTE_SOC             0x0E
#define REMAINING_CAPACITY       0x0F
#define FULL_CHARGE_CAPACITY     0x10
#define TIME_TO_FULL             0x13
#define CHARGING_CURRENT         0x14
#define CHARGING_VOLTAGE         0x15
#define BATTERY_STATUS           0x16
#define CYCLE_COUNT              0x17
#define DESIGN_CAPACITY          0x18
#define DESIGN_VOLTAGE           0x19
#define SPEC_INFO                0x1A
#define MFG_DATE                 0x1B
#define SERIAL_NUM               0x1C
#define MFG_NAME                 0x20   // String
#define DEV_NAME                 0x21   // String
#define CELL_CHEM                0x22   // String
#define MFG_DATA                 0x23   // String
#define CELL4_VOLTAGE            0x3C   // Indidual cell voltages don't work on Lenovo and Dell Packs
#define CELL3_VOLTAGE            0x3D
#define CELL2_VOLTAGE            0x3E
#define CELL1_VOLTAGE            0x3F
#define STATE_OF_HEALTH          0x4F

#define bufferLen 32
uint8_t i2cBuffer[bufferLen];

void setup()
{

  /**************************************************

    Comment out the next two lines following lines for use with Serial output

  **************************************************/
  //Bridge.begin();
  //Console.begin();

  /**************************************************

    Uncomment the following lines for use with Serial output

  **************************************************/
  Serial.begin(115200);  // start serial for output
  Serial.println(i2c_init());
  pinMode(22, INPUT_PULLUP);
  pinMode(23, INPUT_PULLUP);

  //while (!Console) {
  //  ; // wait for Console port to connect.
  //}

  Serial.println("Console Initialized");

  i2c_init();
  Serial.println("I2C Inialized");
  scan();
}

int fetchWord(byte func)
{
  i2c_start(deviceAddress << 1 | I2C_WRITE);
  i2c_write(func);
  i2c_rep_start(deviceAddress << 1 | I2C_READ);
  byte b1 = i2c_read(false);
  byte b2 = i2c_read(true);
  i2c_stop();
  return (int)b1 | ((( int)b2) << 8);
}

uint8_t i2c_smbus_read_block ( uint8_t command, uint8_t* blockBuffer, uint8_t blockBufferLen )
{
  uint8_t x, num_bytes;
  i2c_start((deviceAddress << 1) + I2C_WRITE);
  i2c_write(command);
  i2c_rep_start((deviceAddress << 1) + I2C_READ);
  num_bytes = i2c_read(false); // num of bytes; 1 byte will be index 0
  num_bytes = constrain(num_bytes, 0, blockBufferLen - 2); // room for null at the end
  for (x = 0; x < num_bytes - 1; x++) { // -1 because x=num_bytes-1 if x<y; last byte needs to be "nack"'d, x<y-1
    blockBuffer[x] = i2c_read(false);
  }
  blockBuffer[x++] = i2c_read(true); // this will nack the last byte and store it in x's num_bytes-1 address.
  blockBuffer[x] = 0; // and null it at last_byte+1
  i2c_stop();
  return num_bytes;
}

void scan()
{
  byte i = 0;
  for ( i = 0; i < 127; i++  )
  {
    Serial.print("Address: 0x");
    Serial.print(i, HEX);
    bool ack = i2c_start(i << 1 | I2C_WRITE);
    if ( ack ) {
      Serial.println(": OK");
      Serial.flush();
    }
    else {
      Serial.println(": -");
      Serial.flush();
    }
    i2c_stop();
  }
}

void loop()
{
  uint8_t length_read = 0;

  Serial.print("Manufacturer Name: ");
  length_read = i2c_smbus_read_block(MFG_NAME, i2cBuffer, bufferLen);
  Serial.write(i2cBuffer, length_read);
  Serial.println("");

  Serial.print("Device Name: ");
  length_read = i2c_smbus_read_block(DEV_NAME, i2cBuffer, bufferLen);
  Serial.write(i2cBuffer, length_read);
  Serial.println("");

  Serial.print("Chemistry ");
  length_read = i2c_smbus_read_block(CELL_CHEM, i2cBuffer, bufferLen);
  Serial.write(i2cBuffer, length_read);
  Serial.println("");

  // Serial.print("Manufacturer Data ");
  // length_read = i2c_smbus_read_block(MFG_DATA, i2cBuffer, bufferLen);
  // Serial.write(i2cBuffer, length_read);
  // Serial.println("");

  Serial.print("Design Capacity: " );
  Serial.println(fetchWord(DESIGN_CAPACITY));

  Serial.print("Design Voltage: " );
  Serial.println(fetchWord(DESIGN_VOLTAGE));

  String formatted_date = "Manufacture Date (Y-M-D): ";
  int mdate = fetchWord(MFG_DATE);
  int mday = B00011111 & mdate;
  int mmonth = mdate >> 5 & B00001111;
  int myear = 1980 + (mdate >> 9 & B01111111);
  formatted_date += myear;
  formatted_date += "-";
  formatted_date += mmonth;
  formatted_date += "-";
  formatted_date += mday;
  Serial.println(formatted_date);

  Serial.print("Serial Number: ");
  Serial.println(fetchWord(SERIAL_NUM));

  Serial.print("Specification Info: ");
  Serial.println(fetchWord(SPEC_INFO));

  Serial.print("Cycle Count: " );
  Serial.println(fetchWord(CYCLE_COUNT));

  Serial.print("Voltage: ");
  Serial.println((float)fetchWord(VOLTAGE) / 1000);

  Serial.print("Full Charge Capacity: " );
  Serial.println(fetchWord(FULL_CHARGE_CAPACITY));

  Serial.print("Remaining Capacity: " );
  Serial.println(fetchWord(REMAINING_CAPACITY));

  Serial.print("Relative Charge(%): ");
  Serial.println(fetchWord(RELATIVE_SOC));

  Serial.print("Absolute Charge(%): ");
  Serial.println(fetchWord(ABSOLUTE_SOC));

  Serial.print("Minutes remaining for full charge: ");
  Serial.println(fetchWord(TIME_TO_FULL));

  // These aren't part of the standard, but work with some packs.
  // They don't work with the Lenovo and Dell packs we've tested
  Serial.print("Cell 1 Voltage: ");
  Serial.println(fetchWord(CELL1_VOLTAGE));
  Serial.print("Cell 2 Voltage: ");
  Serial.println(fetchWord(CELL2_VOLTAGE));
  Serial.print("Cell 3 Voltage: ");
  Serial.println(fetchWord(CELL3_VOLTAGE));
  Serial.print("Cell 4 Voltage: ");
  Serial.println(fetchWord(CELL4_VOLTAGE));

  Serial.print("State of Health: ");
  Serial.println(fetchWord(STATE_OF_HEALTH));

  Serial.print("Battery Mode (BIN): 0b");
  Serial.println(fetchWord(BATTERY_MODE), BIN);

  Serial.print("Battery Status (BIN): 0b");
  Serial.println(fetchWord(BATTERY_STATUS), BIN);

  Serial.print("Charging Current: ");
  Serial.println(fetchWord(CHARGING_CURRENT));

  Serial.print("Charging Voltage: ");
  Serial.println(fetchWord(CHARGING_VOLTAGE));

  Serial.print("Temp: ");
  unsigned int tempk = fetchWord(TEMPERATURE);
  Serial.println((float)tempk / 10.0 - 273.15);

  Serial.print("Current (mA): " );
  Serial.println(fetchWord(CURRENT));

  Serial.println(".");
  delay(1000);
}

Found a mention of the same error here https://forum.pjrc.com/threads/32911-Reading-battery-data-from-SMBus-i2c

Seems its due to ARM
Trying https://github.com/felias-fogg/SlowSoftI2CMaster


Custom style button

I want to use my own custom buttons to bold a word.
Is there a way to change the style of the selected words (without using the toolbar)?

Yes you can totally do that! There are two ways;

You can remove the default bold button in the toolbar and add your own to display in the toolbar section

You can remove the default bold button in the toolbar and add your own widget wherever you want

Which one are you trying to do? I can send an example for that.

Thanks for your prompt reply
I want to create a button outside the toolbar and change the style of the selected word (s) through it.
It will be nice if you send me an example code.

Sorry for the late response. Here is how to do that:
bool isBold = false;

IconButton(
   icon: Icon(Icons.format_bold, color: isBold ? Colors.blue : Colors.black),
   onPressed: () => controller.execCommand('bold'),
);

HtmlEditor(
   htmlToolbarOptions: HtmlToolbarOptions(
      defaultToolbarButtons: [
            //add buttons here, but remove the bold button because you have a custom one. See README for more details
      ]
    ),
    callbacks: Callbacks(
       onChangeSelection: (EditorSettings settings) => setState(() { isBold = settings.isBold }),
    )
);

It isn't super difficult. You can use the same approach for any other button or dropdown. onChangeSelection is important so you can update your UI dynamically when the user puts the cursor on bold text or when the user puts the cursor on regular text.
Let me know if you have any issues or other questions.

@alirezaemami I hope the above code was helpful. Closing for now, let me know if you have any other questions.


Updated url in config.properties for dl4j-labs and dl4j-cv-labs by re…

…placing the url from archive.org to wasabi
Description
The storage of data have been migrated from archive.org to wasabi. Thus, the url in config.properties for both dl4j-labs and dl4j-cv-labs have been updated.
Fixes # (issue)
Tested on

[X ] Windows
[ ] Linux Ubuntu
[ ] Mac
[ ] Others  (State here -> xxx )

Assign a reviewer to review your code.

branch ready to merge @kenghooi-teoh


crash when calling trainSamples() of ZstdDictTrainer

I need to use compress with dictionary. After add samples to ZstdDictTrainer, and when calling trainSamples it crashes and makes this error:
art/runtime/java_vm_ext.cc:470] JNI DETECTED ERROR IN APPLICATION: jfieldID int java.nio.Buffer.capacity not valid for an object of class int[]
art/runtime/java_vm_ext.cc:470]     in call to GetIntField
art/runtime/java_vm_ext.cc:470]     from long com.github.luben.zstd.Zstd.trainFromBufferDirect(java.nio.ByteBuffer, int[], java.nio.ByteBuffer)
art/runtime/java_vm_ext.cc:470] "main" prio=5 tid=1 Runnable
art/runtime/java_vm_ext.cc:470]   | group="main" sCount=0 dsCount=0 obj=0x74fac610 self=0xa988b400
art/runtime/java_vm_ext.cc:470]   | sysTid=9405 nice=-10 cgrp=default sched=0/0 handle=0xadc3e534
art/runtime/java_vm_ext.cc:470]   | state=R schedstat=( 0 0 0 ) utm=28 stm=41 core=3 HZ=100
art/runtime/java_vm_ext.cc:470]   | stack=0xbf683000-0xbf685000 stackSize=8MB
art/runtime/java_vm_ext.cc:470]   | held mutexes= "mutator lock"(shared held)
art/runtime/java_vm_ext.cc:470]   native: #00 pc 00572f1e  /system/lib/libart.so (_ZN3art15DumpNativeStackERNSt3__113basic_ostreamIcNS0_11char_traitsIcEEEEiP12BacktraceMapPKcPNS_9ArtMethodEPv+238)

Hmm, that's strange, I thought it's well tested. Can you post some minimal example?

The following is part of my code where I want to make dictionary from samples. Here my samples is array string with length 4. Each sample string length is less than 500 characters
    ZstdDictTrainer trainer = new ZstdDictTrainer(1024 * 1024, 32 * 1024);
    String[] samples = context.getResources().getStringArray(R.array.samples);
    for (String s : samples) {
        try {
            trainer.addSample(s.getBytes("UTF-8"));
        } catch (UnsupportedEncodingException e) {
            e.printStackTrace();
        }
    }
    trainer.trainSamples();

It craches on last line when trainer.trainSamples is called;

hmm, can you try something in the same spirit but without going through the dict trainer class? This will narrow-down the bug place. Pseudo-code below:
String[] samples = ...
byte[][] samples_bytes = Arrays.stream(samples).map((s) -> s.getBytes("UTF-8")).toArray(byte[][]::new);
byte[] dict_buff = new byte[32 * 1024];
int dict_len = Zstd.trainFromBuffer(samples_bytes, dict_buff);
bytes[] dict = Arrays.copyOfRange(dict_buff, 0, dict_len-1);

The latter works fine. The error may be related to use of buffer. I prefer to use buffer, becuase my real data has several thousand records. could you fix the bug?

Hi,
I just pushed a commit that hopefully fixes it. Can you test it? I will push a release later today as I don't have my keys with me now.
Regards,

I pushed 1.3.3-4 with the fix. It's already on maven-central. Can you try if it fixes the issue?

Hi,
Thanks so much. The problem was solved.
Best regards

Thanks for reporting it. There was some unnecessary code left.

hi @luben
what does this mean?
    ZstdDictTrainer trainer = new ZstdDictTrainer(1024 * 1024, 32 * 1024);

what are 1024 * 1024 and 32 * 1024?
I do this
    String jsonString1 = "very long hello world string 1";
    String jsonString2 = "very long hello world string 2";
    String jsonString3 = "very long hello world string 3";

    ZstdDictTrainer trainer = new ZstdDictTrainer(1024 * 1024, 32 * 1024);
    trainer.addSample(jsonString1.getBytes(StandardCharsets.UTF_8));
    trainer.addSample(jsonString2.getBytes(StandardCharsets.UTF_8));
    trainer.addSample(jsonString3.getBytes(StandardCharsets.UTF_8));
    trainer.trainSamples();

and it throws:
com.github.luben.zstd.ZstdException: Src size is incorrect
at com.github.luben.zstd.ZstdDictTrainer.trainSamplesDirect(ZstdDictTrainer.java:40)
at com.github.luben.zstd.ZstdDictTrainer.trainSamples(ZstdDictTrainer.java:51)
at com.github.luben.zstd.ZstdDictTrainer.trainSamples(ZstdDictTrainer.java:47)
at org.apache.cassandra.io.compress.ZstdCompressorTest.testDict(ZstdCompressorTest.java:71)

new ZstdDictTrainer(1024 * 1024, 32 * 1024);
This configures dict trainer to expect 1024*1024 bytes as samples - they have to match.


Basis rotation circuit

Google's basis rotation circuit ansatz. Should be OK, will un-draft it after I do a bit more testing and write up an example.

Yup, doing that now actually haha


1.21

> Task :1.21:compileJava FAILED
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/InstrumentsDataGenerator.java:6: error: cannot find symbol
import net.minecraft.block.enums.Instrument;
                                ^
  symbol:   class Instrument
  location: package net.minecraft.block.enums
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/TintsDataGenerator.java:11: error: cannot find symbol
import net.minecraft.client.color.world.FoliageColors;
                                       ^
  symbol:   class FoliageColors
  location: package net.minecraft.client.color.world
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/mixin/ReadyMixin.java:19: error: cannot find symbol
                DGU.getCurrentlyRunningServer().getRunDirectory().toPath()
                                                                 ^
  symbol:   method toPath()
  location: interface Path
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/InstrumentsDataGenerator.java:17: error: cannot find symbol
        for (Instrument instrument : Instrument.values()) {
                                     ^
  symbol:   variable Instrument
  location: class InstrumentsDataGenerator
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/InstrumentsDataGenerator.java:17: error: cannot find symbol
        for (Instrument instrument : Instrument.values()) {
             ^
  symbol:   class Instrument
  location: class InstrumentsDataGenerator
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/ItemsDataGenerator.java:35: error: incompatible types: List<RegistryEntryList<Item>> cannot be converted to List<TagKey<Item>>
                .toList();
                       ^
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/TintsDataGenerator.java:54: error: cannot find symbol
        resultColors.put(Blocks.BIRCH_LEAVES, FoliageColors.getBirchColor());
                                              ^
  symbol:   variable FoliageColors
  location: class TintsDataGenerator
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/TintsDataGenerator.java:55: error: cannot find symbol
        resultColors.put(Blocks.SPRUCE_LEAVES, FoliageColors.getSpruceColor());
                                               ^
  symbol:   variable FoliageColors
  location: class TintsDataGenerator
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/EnchantmentsDataGenerator.java:47: error: cannot find symbol
        enchantmentDesc.addProperty("displayName", DGU.translateText(enchantment.getTranslationKey()));
                                                                                ^
  symbol:   method getTranslationKey()
  location: variable enchantment of type Enchantment
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/EnchantmentsDataGenerator.java:53: error: cannot find symbol
        enchantmentDesc.addProperty("treasureOnly", enchantment.isTreasure());
                                                               ^
  symbol:   method isTreasure()
  location: variable enchantment of type Enchantment
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/EnchantmentsDataGenerator.java:54: error: cannot find symbol
        enchantmentDesc.addProperty("curse", enchantment.isCursed());
                                                        ^
  symbol:   method isCursed()
  location: variable enchantment of type Enchantment
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/EnchantmentsDataGenerator.java:57: error: cannot find symbol
                .filter(other -> !enchantment.canCombine(other))
                                             ^
  symbol:   method canCombine(Enchantment)
  location: variable enchantment of type Enchantment
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/EnchantmentsDataGenerator.java:68: error: incompatible types: RegistryEntryList<Item> cannot be converted to TagKey<Item>
        enchantmentDesc.addProperty("category", getEnchantmentTargetName(enchantment.getApplicableItems()));
                                                                                ^
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/EnchantmentsDataGenerator.java:70: error: cannot find symbol
        enchantmentDesc.addProperty("tradeable", enchantment.isAvailableForEnchantedBookOffer());
                                                            ^
  symbol:   method isAvailableForEnchantedBookOffer()
  location: variable enchantment of type Enchantment
/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/EnchantmentsDataGenerator.java:71: error: cannot find symbol
        enchantmentDesc.addProperty("discoverable", enchantment.isAvailableForRandomSelection());
                                                               ^
  symbol:   method isAvailableForRandomSelection()
  location: variable enchantment of type Enchantment
Note: Some messages have been simplified; recompile with -Xdiags:verbose to get full output
15 errors

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':1.21:compileJava'.
> Compilation failed; see the compiler error output for details.

* Try:
> Run with --info option to get more log output.
> Run with --scan to get full insights.

BUILD FAILED in 42s
8 actionable tasks: 3 executed, 5 up-to-date

Whats still missing here? Id like to help!

/workspaces/minecraft-data-generator-server/1.21/src/main/java/dev/u9g/minecraftdatagenerator/generators/EnchantmentsDataGenerator.java:47: error: cannot find symbol
        enchantmentDesc.addProperty("displayName", DGU.translateText(enchantment.getTranslationKey()));
                                                                                ^
  symbol:   method getTranslationKey()
  location: variable enchantment of type Enchantment

old displayname code:

maybe we can use getName instead?  im not sure of the purpose of translation keys but its been removed and getName added, but it accepts a level argument so im not really sure how we should handle this, wouldnt it return like "Unbreaking III"? we just want the displayname without the level for this right?

it looks like the isCursed() is completely removed, i couldnt find an equivelant in the mappings maybe we will just have to have a list and add known cursed enchantments and new ones manually in the data generator idk

im assuming its the same with isTreasure aswell
alot of enchantment stuff is changed

ive just done the list solution for now for getting the "treasure only" and "cursed" field.
i dont like this but im not sure what else we can do since there dosnt seem to be an equivelent method.

maybe we could do smth to determine if its treasure with the weight since apparently enchantments that cant be obtained from enchantment tables have a weight of 0
idk about cursed yet tho

i looked at the enchantment weights of treasure enchants in 1.20.6 data and none of them are 0, most of them are 1 and some of them even have weights of 2 so sadly we cant use this to determine whether its treasure or not since some non enchants have weights of 1 and 2.
some treasure enchants from 1.20.6:

non treasure enchants from 1.20.6

it dosnt look like they are even used for anything in mineflayer so ig we could either remove that property since its not in the code anymore idk, or just manually update a list with new treasure enchants for each new version.

Are there still useful changes here? If yes can you please rebase on master ?

1.21 missing here: https://github.com/PrismarineJS/minecraft-data-generator-server/blob/d29015b4daaec4f37409236113bdeb64b182a333/.github/workflows/build.yml#L32
CI is currently not testing 1.21

Added, runs, merging


[10.x] Database layer fixes

This PR fixes a couple of issues discussed in #49735  .
Appropriate checks are added to Illuminate\Database\Eloquent\Relations\BelongsTo::getForeignKeyFrom() and Illuminate\Database\Query\Builder::whereIntegerInRaw() to return the proper value if a BackedEnum is encountered. This is typically the case on models where a cast has been defined, especially on keys.
I have also added a couple of tests to cover these cases where it seemed appropriate.
There might be other similar cases. Please see this comment.

@taylorotwell sorry I'm confused as to why the PR was reverted to a draft. If there are any comments or suggestions I'll be happy to contribute the fixes.

@driesvints any idea what else is needed here? I'm very confused.

Hi @sidquisaad. Most likely Taylor is too busy rn to review and will review at a later moment. Thanks!

@taylorotwell gonna mark this ready for you again if that's okay.


node-js examples not compiling

To try and run the examples I do the following with a freshly cloned repo:
cd examples/examples-nodejs
npm i
tsc faceDetection.ts

I get the following error:
node_modules/@types/webgl2/index.d.ts:582:13 - error TS2403: Subsequent variable declarations must have the same type.  Variable 'WebGL2RenderingContext' must be of type '{ new (): WebGL2RenderingContext; prototype: WebGL2RenderingContext; readonly ACTIVE_ATTRIBUTES: number; readonly ACTIVE_TEXTURE: number; ... 556 more ...; readonly WAIT_FAILED: number; }', but here has type '{ new (): WebGL2RenderingContext; prototype: WebGL2RenderingContext; readonly ACTIVE_ATTRIBUTES: number; readonly ACTIVE_TEXTURE: number; ... 557 more ...; readonly MAX_CLIENT_WAIT_TIMEOUT_WEBGL: number; }'.

582 declare var WebGL2RenderingContext: {
                ~~~~~~~~~~~~~~~~~~~~~~

  ../../../../../../usr/lib/node_modules/typescript/lib/lib.dom.d.ts:16485:13
    16485 declare var WebGL2RenderingContext: {
                      ~~~~~~~~~~~~~~~~~~~~~~
    'WebGL2RenderingContext' was also declared here.

Found 1 error.

I have the following:
tsc --version: 3.7.2
node --version: 12.13.0
I have tried adding skipLibCheck: true to tsconfig.json but it did not do any difference.
Do you have any idea why it is not working for node?

This command works.
tsc --skipLibCheck faceDetection.ts
But then it doesn't work
error:
UnhandledPromiseRejectionWarning: TypeError: this.backend.register is not a function
    at Engine.registerTensor (/home/ff/nodejs/face-api.js/node_modules/@tensorflow/tfjs-core/dist/engine.js:468:30)

Please check out @russellwmy's answer in this issue #376. Make sure you are using the same typescript (take a look at the package.json of the examples folder) and tfjs-core version as face-api.js.

same error, I tried #376, seems different errors. not work.

@kerloom @FerX have you got any progress of this issue?

Thanks! Just to make this clear for anyone else, you can fix by removng the caret (^) in the package.json for  @tensorflow/tfjs-node and getting version 1.2.3 specifically. For example in the examples folder changing package.json to:
{
  "author": "justadudewhohacks",
  "license": "MIT",
  "dependencies": {
    "@tensorflow/tfjs-node": "1.2.3",
    "canvas": "^2.5.0",
    "face-api.js": "../../"
  }
}

just cloned the repository, with
tsc --version: 3.7.3
node --version: v13.3.0
cd face-api.js/examples/examples-nodejs
npm i
ts-node  faceDetection.ts

gives:
faceDetection.ts:1:26 - error TS2307: Cannot find module 'face-api.js'.

1 import * as faceapi from 'face-api.js';

Same scenario, and same results as @sbocconi.
node --version: 12.4.0
tsc --version: 3.7.4

@sbocconi @imgh1010 What version of tfjs-node are you using? Did you change the version in package.json before installing with npm install as per my previous comment?

My package.json is as  currently available in the repository:
{
  "author": "justadudewhohacks",
  "license": "MIT",
  "dependencies": {
    "@tensorflow/tfjs-node": "1.4.0",
    "canvas": "^2.6.0",
    "face-api.js": "../../"
  }
}

and the error does not depend on the version of tensorflow, but on the fact that face-api.js cannot be found.
I also tried with:
{
  "author": "justadudewhohacks",
  "license": "MIT",
  "dependencies": {
    "@tensorflow/tfjs-node": "1.4.0",
    "canvas": "^2.6.0",
    "face-api.js": "git+https://github.com/justadudewhohacks/face-api.js.git#master"
  }
}

but I get the same error, even after a npm install face-api.js

The solution was to first run
npm i && npm run-script build

in the root directory before trying to run the example.

however,I found https://github.com/justadudewhohacks/face-api.js/blob/master/examples/examples-nodejs/package.json will circulate create face-api.js fold, is usually or not?

however,I found :
examples/examples-nodejs/package.json
{
"author": "justadudewhohacks",
"license": "MIT",
"dependencies": {
"face-api.js": "../../"  #   this will happen circulate create
}
}
will circulate create face-api.js fold, is usually or not? @justadudewhohacks

when I do "npm i" in console.

The solution was to first run
npm i && npm run-script build

in the root directory before trying to run the examples.

when I do “npm i && npm run-script build”,and I get:

<EMAIL_ADDRESS>install /home/dzy/Project/face-api.js/node_modules/@tensorflow/tfjs-node
node scripts/install.js

CPU-linux-1.7.0.tar.gz

Downloading libtensorflow
[==============================] 15944787/bps 100% 0.0s
Building TensorFlow Node.js bindings

<EMAIL_ADDRESS>install /home/dzy/Project/face-api.js/node_modules/canvas
node-pre-gyp install --fallback-to-build

node-pre-gyp WARN Using needle for node-pre-gyp https download
[canvas] Success: "/home/dzy/Project/face-api.js/node_modules/canvas/build/Release/canvas.node" is installed via remote
npm WARN optional SKIPPING OPTIONAL DEPENDENCY<EMAIL_ADDRESS>(node_modules/fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for<EMAIL_ADDRESS>wanted {"os":"darwin","arch":"any"} (current: {"os":"linux","arch":"x64"})
added 442 packages from 783 contributors and audited 1741 packages in 170.919s
10 packages are looking for funding
run npm fund for details
found 8 low severity vulnerabilities
run npm audit fix to fix them, or npm audit for details

<EMAIL_ADDRESS>build /home/dzy/Project/face-api.js
rm -rf ./build && rm -rf ./dist && npm run rollup && npm run rollup-min && npm run tsc && npm run tsc-es6

<EMAIL_ADDRESS>rollup /home/dzy/Project/face-api.js
rollup -c rollup.config.js

loaded rollup.config.js with warnings
(!) Unused external imports
default imported from external module 'path' but never used
src/index.ts → dist/face-api.js...
created dist/face-api.js in 10.3s

<EMAIL_ADDRESS>rollup-min /home/dzy/Project/face-api.js
rollup -c rollup.config.js --environment minify:true

loaded rollup.config.js with warnings
(!) Unused external imports
default imported from external module 'path' but never used
src/index.ts → dist/face-api.min.js...
created dist/face-api.min.js in 14.5s

<EMAIL_ADDRESS>tsc /home/dzy/Project/face-api.js
tsc

<EMAIL_ADDRESS>tsc-es6 /home/dzy/Project/face-api.js
tsc --p tsconfig.es6.json
And tsc faceDetection.ts,  get same error.

Worked fine for me:

npm install & npm run-script build (the remove commands for the directories fail on windows, remove them from package.json in the face-api.js\package.json file)
run npm install in examples-nodejs
running tsc faceDetection.ts fails with an error (duplicate librarydefinition WebGL2 or something)
instead tsc --skipLibCheck faceDetection.ts and things run fine.

@ronaldkuip I am also that add '--skipLibCheck' , but is fine?

ts-node faceDetection.ts should run in examples-nodejs directory.
Tsc -skipLibCheck.ts creates faceDetection.js
node faceDetection.js then runs fine too.
Van: homedawn<EMAIL_ADDRESS>Verzonden: woensdag 6 mei 2020 02:52
Aan: justadudewhohacks/face-api.js<EMAIL_ADDRESS>CC: ronaldkuip<EMAIL_ADDRESS>Mention<EMAIL_ADDRESS>Onderwerp: Re: [justadudewhohacks/face-api.js] node-js examples not compiling (#491)
@ronaldkuiphttps://github.com/ronaldkuip I am also that add '--skipLibCheck' , but is fine?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/justadudewhohacks/face-api.js/issues/491#issuecomment-624383634, or unsubscribehttps://github.com/notifications/unsubscribe-auth/ACV4DRCPYR5R362D6IYE3JDRQCYDJANCNFSM4JUN6MOA.

Hi everyone getting this error while running examples-nodejs using command => tsc faceDetection.ts
commons/env.ts:5:26** - error TS2307: Cannot find module 'face-api.js' or its corresponding type declarations.
5 import * as faceapi from 'face-api.js';
~~~~~~~~~~~~~
commons/faceDetection.ts:1:26 - error TS2307: Cannot find module 'face-api.js' or its corresponding type declarations.
1 import * as faceapi from 'face-api.js';
~~~~~~~~~~~~~
faceDetection.ts:1:26 - error TS2307: Cannot find module 'face-api.js' or its corresponding type declarations.
1 import * as faceapi from 'face-api.js';
~~~~~~~~~~~~~
node_modules/@tensorflow/tfjs-node/dist/nodejs_kernel_backend.d.ts:61:5 - error TS2416: Property 'stridedSlice' in type 'NodeJSKernelBackend' is not assignable to the same property in base type 'KernelBackend'.
Type '<T extends Tensor>(x: T, begin: number[], end: number[], strides: number[], beginMask: number, endMask: number, ellipsisMask: number, newAxisMask: number, shrinkAxisMask: number) => T' is not assignable to type '<T extends Tensor>(x: T, begin: number[], end: number[], strides: number[]) => T'.
61     stridedSlice(x: T, begin: number[], end: number[], strides: number[], beginMask: number, endMask: number, ellipsisMask: number, newAxisMask: number, shrinkAxisMask: number): T;
~~~~~~~~~~~~
node_modules/@tensorflow/tfjs-node/dist/nodejs_kernel_backend.d.ts:64:5 - error TS2416: Property 'fusedBatchMatMul' in type 'NodeJSKernelBackend' is not assignable to the same property in base type 'KernelBackend'.
Type '(a: Tensor3D, b: Tensor3D, transposeA: boolean, transposeB: boolean, bias?: Tensor, activation?: Activation) => Tensor3D' is not assignable to type '({ a, b, transposeA, transposeB, bias, activation, preluActivationWeights }: FusedBatchMatMulConfig) => Tensor3D'.
64     fusedBatchMatMul(a: Tensor3D, b: Tensor3D, transposeA: boolean, transposeB: boolean, bias?: Tensor, activation?: Activation): Tensor3D;
~~~~~~~~~~~~~~~~
node_modules/@types/webgl2/index.d.ts:582:13 - error TS2403: Subsequent variable declarations must have the same type.  Variable 'WebGL2RenderingContext' must be of type '{ new (): WebGL2RenderingContext; prototype: WebGL2RenderingContext; readonly ACTIVE_ATTRIBUTES: number; readonly ACTIVE_TEXTURE: number; ... 556 more ...; readonly WAIT_FAILED: number; }', but here has type '{ new (): WebGL2RenderingContext; prototype: WebGL2RenderingContext; readonly ACTIVE_ATTRIBUTES: number; readonly ACTIVE_TEXTURE: number; ... 557 more ...; readonly MAX_CLIENT_WAIT_TIMEOUT_WEBGL: number; }'.
582 declare var WebGL2RenderingContext: {
~~~~~~~~~~~~~~~~~~~~~~
../../../../../AppData/Roaming/npm/node_modules/typescript/lib/lib.dom.d.ts:16394:13
16394 declare var WebGL2RenderingContext: {
~~~~~~~~~~~~~~~~~~~~~~
'WebGL2RenderingContext' was also declared here.
Found 6 errors.

Is there a way to implement face-api with webRTC where webRTC is running on browser and face-api on server
I am trying it but couldn't find a way to do so because my nodejs server cannot access DOM elements which is a requirement to implement face-api

same here

The solution was to first run
npm i && npm run-script build

in the root directory before trying to run the examples.

sl3@luciano-GrIA:~/face-api.js/examples/examples-nodejs$ npm i && npm run-script build
up to date, audited 3 packages in 1s
found 0 vulnerabilities
npm ERR! Missing script: "build"
npm ERR!
npm ERR! To see a list of scripts, run:
npm ERR!   npm run
npm ERR!


Add consistent proto field numbers

I've opened a new branch based on main, because the merge was not successful and was easier to do it again as to fix.


微信支付统一下单接口增加 scene_info 字段

https://pay.weixin.qq.com/wiki/doc/api/H5.php?chapter=9_20&index=1

Codecov Report

Merging #279 into master will decrease coverage by 0.04%.
The diff coverage is 33.33%.

@@            Coverage Diff             @@
##           master     #279      +/-   ##
==========================================
- Coverage   76.27%   76.23%   -0.05%
==========================================
  Files          74       74
  Lines        3204     3206       +2
==========================================
  Hits         2444     2444
- Misses        760      762       +2

Impacted Files
Coverage Δ

wechatpy/pay/api/order.py
40.54% <33.33%> (-2.32%)
:arrow_down:

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 9e1e04a...b541f71. Read the comment docs.


update github.com/mcuadros/go-version to v0.0.0-20190308113854-92cdf37c5b75

fix #6814

Codecov Report

Merging #6815 into master will increase coverage by <.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #6815      +/-   ##
==========================================
+ Coverage   41.21%   41.22%   +<.01%
==========================================
  Files         421      421
  Lines       58059    58059
==========================================
+ Hits        23929    23933       +4
+ Misses      30963    30958       -5
- Partials     3167     3168       +1

Impacted Files
Coverage Δ

models/repo_list.go
67.89% <0%> (+1.05%)
:arrow_up:

models/unit.go
67.56% <0%> (+5.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 eb8632b...acf437f. Read the comment docs.

Thanks much!


Relicense to MIT-0 OR (Apache-2.0 WITH LLVM-Exception)

This PR relicenses the codebase to the following SPDX license identifier:
MIT-0 OR (Apache-2.0 WITH LLVM-Exception)
Note that:

I used the LLVM-Exception for apache-2.0 (for better GPLv2 compatibility)
I used MIT-0 instead of MIT, which is strictly more permissive than MIT by removing attribution. This is effectively a public domain compatible license.

@marceline-cramer please confirm that you are the original author of this work and grant your permission to relicense the codebase in accordance with the above SPDX identifier with no additional terms or conditions.

sure, i am the author of this and i grant permission to relicense
cya in court


Refactor embeddings builder in prep for SV addition

This PR moves all data files to under data/, and allows multiple SV-name-description files.

data/curated_input/sheets_svs.csv:  The current 1.3K spreadsheet which going forward will be edited only for "override descriptions"
data/autogen_input/*.csv: Incremental additions of SVs will go here.
data/alternatives/*.csv:  The palm and other alternatives can be in one or more files, and will go here.
data/preindex/sv_descriptions.csv: The pre-index output for sanity check

In summary:  curated_input + autogen_input + alternatives => preindex => embeddings

Thanks Jehangir!


shippable or something

or travis-ci
... or we can just add a pre-commit hook that runs tests

If we use a pre-commit hook how will we get a fancy badge for the readme?!?!?! 😉

Guess we need to make our own fancy badge

Closed, LK


Update pointer-events.json

Feature that should not be ignored.
The SVG 2.0 specification also defines a bounding-box value. When the value of pointer-events is bounding-box, the rectangular area around the element can also receive pointer events. Only Chrome 65+ supports the bounding-box value.

Thanks!


Default task based on glob pattern doesn't work

v1.71.0 WSL2
https://github.com/microsoft/vscode/pull/141230 introduces the default tasks based on filenames.
However, it doesn't seem to work in my settings. I still have to choose one here, after I opened up a txt file and clicked "Tasks: Run Build Task"

I would expect it auto executes echo TextFile in this case withou prompts, just as if I had set isDefault: true in echo txt task

Do you have a folder / workspace open? If yes, does it contain more than one .txt file, and/or more than one .js file?

Ignore my previous comment. Instead please try "/*.txt" instead of ".txt".

Thanks. it works once I replace it with **/*.txt
Previously I was following from https://github.com/microsoft/vscode-docs/pull/5401/files

Thanks. it works once I replace it with **/*.txt
Previously I was following from https://github.com/microsoft/vscode-docs/pull/5401/files

@alexr00 does the doc need to be amended?

I am now the owner, so will take a look.


Specify event detection methods by strings

Description of the problem
Currently when using Dataset.detect_events() we have to pass a class.
Passing a string would be much nicer.
Description of a solution
This could be done similarly as it's currently done for the event properties with a EventDetectionLibrary then.
Minimum acceptance criteria

[ ] add EventDetectionLibrary
[ ] register all event detection methods
[ ] add ability to specify event detection methods by using strings

implemented in #406


Fastfetch rendering issue when launching initial ghostty window

Description
So I recently migrated from kitty to ghostty, and everything works perfectly except for my fastfetch config. It does work, but only if there's an inherited ghostty instances, else as you can see in the first image, the entire prompt seems to break.
I first believed it was due to the padding or the font size, but it seems like the problem is there regardless.
I also suspect if it's a special edge-case scenario with my fastfetch config (as shown below) using escape sequences and causing issues.
Screenshots

Screenshot
Description

The initial ghostty window with the issue

Inherited ghostty tab with no such issue

Inherited ghostty tab, split horizontally with no such issue

Interited ghostty tab, split vertically with no such issue

Steps to Reproduce
Step 1:
Get Ghostty from the AUR and apply the config below.
Step 2:
Set up .zshrc to allow fastfetch to launch on every ghostty instance
Expected Behaviour:
Ghostty should show Fastfetch consistently, not only on inherited instances, but also on initial ones.
Actual Behaviour:
Ghostty breaks the configs and puts some of the text behind the fastfetch image using the kitty protocol.
Ghostty config:
background = #222436
background-opacity = 0.85
background-blur-radius = 5
cursor-color = #c8d3f5
cursor-opacity = 0.8
cursor-style = underline
cursor-style-blink = true
cursor-text = #000000
mouse-hide-while-typing = true
font-family = CaskaydiaCove NF
font-family-bold = CaskaydiaCove NF Bold
font-family-bold-italic = CaskaydiaCove NF Bold Italic
font-family-italic = CaskaydiaCove NF Italic
font-size = 10.5
font-feature = +zero +liga
foreground = #c8d3f5
gtk-tabs-location = bottom
#palette = 0=#1b1d2b
#palette = 10=#c3e88d
#palette = 11=#ffc777
#palette = 12=#82aaff
#palette = 13=#c099ff
#palette = 14=#86e1fc
#palette = 15=#c8d3f5
#palette = 1=#ff757f
#palette = 2=#c3e88d
#palette = 3=#ffc777
#palette = 4=#82aaff
#palette = 5=#c099ff
#palette = 6=#86e1fc
#palette = 7=#828bb8
#palette = 8=#444a73
#palette = 9=#ff757f
selection-background = #2d3f76
selection-foreground = #c8d3f5
window-theme = dark
theme = tokyonight
wait-after-command = true
title = "ghostty"
working-directory = inherit
window-padding-x = 0,0
window-padding-y = 0,0
window-padding-balance = true
window-padding-color = background
window-decoration = false
window-save-state = always
resize-overlay-position = bottom-center
focus-follows-mouse = true
quick-terminal-position = center
shell-integration-features = cursor,sudo,no-title
gtk-single-instance = true
gtk-titlebar = false
minimum-contrast = 1.1
unfocused-split-opacity = 0.5
shell-integration = detect

Fastfetch config.jsonc
{
  "$schema": "https://github.com/fastfetch-cli/fastfetch/raw/dev/doc/json_schema.json",
  "logo": {
    "type": "kitty",
    "source": "/home/sametaor/.config/fastfetch/logos/Fastfetcharch.png",
    "width": 40,
    "padding": {
      "left": 1,
      "right": 1
    }
  },
  "general": {
    "thread": true,
    "playerName": "mpv"
  },
  "display": {
    "disableLinewrap": false,
    "separator": " ❯ ",
    "color": {
      "separator": "cyan"
    },
    "constants": [
      "━━━━━━━━━━━━━━━━━━━━━━━",
      "╽\u001b[51C╽\u001b[50D",
      "┃\u001b[51C┃\u001b[52D",
      "╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌╌",
      "╿\u001b[51C╿\u001b[52D"
    ],
    "temp": {
      "unit": "C",
      "ndigits": 1
    },
    "bar": {
      "charElapsed": "█",
      "charTotal": "▒",
      "borderLeft": "",
      "borderRight": "",
      "width": 10
    },
    "freq": {
      "ndigits": 1
    },
    "percent": {
      "type": 9,
      "ndigits": 1,
      "color": {
        "green": "green",
        "red": "red",
        "yellow": "yellow"
      }
    }
  },
  "modules": [
    {
      "type": "custom",
      "format": "{#34}╭╼{$1} 󰫃 {$1}╾╮"
    },
    {
      "type": "title",
      "format": "{#1}{#keys}{$2}{6} {7} {8}",
      "outputColor": "italic_"
    },
    {
      "type": "custom",
      "format": "{#1}{#keys}┠╌{$4} 󰫄 {$4}╌┨"
    },
    {
      "key": "{$3}{#34}󰨇 Distro",
      "outputColor": "bright_",
      "type": "os",
      "format": "{3} {12}"
    },
    {
      "outputColor": "bright_",
      "key": "{$3}{#32}󰾰 Device",
      "type": "host",
      "format": "{5} {2} {3}"
    },
    {
      "outputColor": "bright_",
      "key": "{$3}{#31}󰒓 Kernel",
      "type": "kernel",
      "format": "{1} {2} ({4})"
    },
    {
      "key": "{$3}{#33}󱦟 Uptime",
      "type": "uptime",
      "format": "{1}d, {2}:{3}hrs"
    },
    {
      "key": "{$3}{#35} Shell ",
      "type": "shell",
      "format": "{6} {4}"
    },
    {
      "key": "{$3}{#36}󰏖 Pkgs  ",
      "type": "packages",
      "format": "{1}"
    },
    {
      "type": "custom",
      "format": "{#1}{#keys}┠╌{$4} 󰫅 {$4}╌┨"
    },
    {
      "key": "{$3}{#34}󱎴 Res   ",
      "type": "display",
      "compactType": "original-with-refresh-rate",
      "outputColor": "bright_"
    },
    {
      "key": "{$3}{#32} WM    ",
      "type": "wm",
      "format": "{2} ({3})",
      "outputColor": "bright_"
    },
    {
      "key": "{$3}{#31}󰍂 LM    ",
      "type": "lm"
    },
    {
      "key": "{$3}{#33}󰔎 Theme ",
      "type": "theme"
    },
    {
      "key": "{$3}{#35} Icons ",
      "type": "icons",
      "format": "{1}"
    },
    {
      "key": "{$3}{#36} Term  ",
      "type": "terminal"
    },
    {
      "key": "{$3}{#38}󰛖 Fonts ",
      "type": "font",
      "format": "{1}, {2}"
    },
    {
      "type": "custom",
      "format": "{#1}{#keys}┠╌{$4} 󰫆 {$4}╌┨"
    },
    {
      "key": "{$3}{#34} CPU   ",
      "type": "cpu",
      "format": "{1}({5})",
      "outputColor": "bright_"
    },
    {
      "key": "{$3}{#32}󰍛 GPU   ",
      "type": "gpu",
      "format": "{1} {2}({6})",
      "outputColor": "bright_"
    },
    {
      "key": "{$3}{#31} Mem   ",
      "type": "memory",
      "format": "{1}/{2} {4}",
      "outputColor": "bright_"
    },
    {
      "key": "{$3}{#33} Disk  ",
      "type": "disk",
      "format": "{1}/{2} {13}",
      "outputColor": "bright_"
    },
    {
      "key": "{$3}{#35} Files ",
      "type": "disk",
      "format": "{4}/{5} {14}"
    },
    {
      "key": "{$3}{#36}󱊣 Batt  ",
      "type": "battery",
      "format": "{1} ({4}) {10}"
    },
    {
      "type": "custom",
      "format": "{#1}{#keys}┠╌{$4} 󰫇 {$4}╌┨"
    },
    {
      "key": "{$3}{#32} Wttr  ",
      "type": "command",
      "shell": "/bin/sh",
      "text": "curl 'wttr.in/(INSERT LOCATION)?format=%C+%t'"
    },
    {
      "key": "{$3}{#35}󰦖 Time  ",
      "type": "command",
      "shell": "/bin/sh",
      "text": "date '+%H:%M 󰛡 %d-%m-%Y'"
    },
    {
      "key": "{$5}{#31} Colors",
      "type": "custom",
      "format": " {#90}  {#31}  {#32}  {#33}  {#34}  {#35}  {#36}  {#37}  {#38}  {#39} "
    },
    {
      "key": " ",
      "format": "{#34}╰╼{$1} 󰫈 {$1}╾╯",
      "type": "custom"
    }
  ]
}

I can reproduce a similar but not exact result on NixOS with my own config
in home-manager I added fastfetch --kitty /path/img.jpg
fastfetch --kitty /home/user/Pictures/water-lily-small.jpg but it only prints the logo and no image

Changing font-family, font-family-bold, font-family-italic, font-family-bold-italic to font-style, font-style-bold, font-style-italic, and font-style-bold-italic respectively fixes the issue.
Looks like the issue was due to font-family synthesizing the glyphs and escape sequences as well.
Closing the issue.


Renaming files does not let changes persist & more strange behavior

Steps

Go to osf.io.

In either the Files widget in the project overview page or the Files page itself, select a file or folder.
Click the "Rename" button in the menu that appears.
Click in the middle of the file's name, either in the middle of a word or in between words.
Type a letter or two.
Click to the right of the name / the end of the text (where the cursor was before you clicked in the middle).
Notice how your edits change.

Expected behavior
I expected that if I try to change the name of a file, any changes I make in the "Rename" field will persist until I click the "Rename" button, even if I click at the end of the text.
Actual behavior
I cannot click at the end of the text without losing some or all of my edits. My old edits also reappear if I change something in the middle and then click the end again.
Tested on Safari, Chrome, and Firefox.
File widget, one word name example

Files page, multiple word name example

I am working on this

This also occurs on mouseover of other files.

So I have a fix for the problem mentioned in the original issue, still working on the mouseover issue.


docs: remove module-metadata.json and commitlint.config.js

/run pipeline

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


allow all JSON types

Good news to simply allow to use all JSON types for SXL.
The #135 issue should link to this commit proposal.
Why removing the specialized "integer" datatype ?
It can be interesting to keep for some informations that are integers only (for performance reason to parse).
For some equipments, many informations can be only integers values (no float)....

To keep the interested specialized type "integer",
in the list of specialized type, the "base64" and "timestamp" would be send as JSON strings,
but the "integer" would be send as a number.
In the first sentence, it would be good to precise that it is concerning the "signals" exchanged in general.


I need some help with my code...

What is up my fellow GitHubbers?  I'm having some trouble with my code for this week's homework.  For my piece, I am trying to create eyeballs that will move all across the screen while creating more and more eyeballs.  Here’s what I have for my code…
// creating the variables and arrays
var words = [ "eye", "for", "an", "eye"];
var index = [ random ];
var pos = {
x: 10,
y: 50
};
// creating the setup function
function setup() {
createCanvas( windowWidth,windowHeight );
}
// creating the drawing function
function draw() {
background( 'black' );
eyeBall( 40, 100, 1.0, 1.0 );
eyeBall ( 200, 100, 1.0, 1.0 )
myObj = map( mouseX, mouseY, 200, 300, 0 )
}
function text(){
translate( 50, 55 );
fill ( 155 );
textSize ( 45 );
text ( words[index], 12, 200 );
}
// creating the eyeBall function
function eyeBall( pos_x, pos_y, scale_x, scale_y ) {
push(); // <- Start of Sandbox
// 1. scaling and positioning the eyeBall
translate( pos_x, pos_y );
scale( scale_x, scale_y );
// 2. drawing the eyeBall
noStroke();
fill( 'rgb(252, 253, 245)' );
ellipse( 20, -35, 135, 135 );
noStroke();
fill( 'rgb(47, 79, 79)' );
ellipse( 20, -35, 50, 50 );
noStroke();
fill( 'black' );
ellipse( 20, -35, 25, 25 );
noStroke();
fill( 'white' );
ellipse( 7, -45, 12, 12 );
pop(); // <- End of Sandbox
}
This is a pretty difficult lesson, and I’m stuck, so any kind of help would be just great.

@JakeTheFlare  I would look at @michaelmusick's example in week 10 and think of replacing the smiley with your eyeball. Something like that would probably work better with an empty array and a couple of for statements. I know that is not much help but maybe it will point you in the right direction. You are right it is a bugger of a week, I barely got mine written sorry I can't help more than that. I think he had some earlier examples of that smiley as a movable object. I took the easy way out and pushed it to mouseX and mouseY. One thing is for sure you are going to have to increment to make it move, remember the bouncy ball one from Shiffman? I was thinking something like that when you described what you want to do.

Okay, thanks anyway.  The bouncy ball thing with Shiffman was from week 7 right?

Yeah I think so, I bet someone is going to have a better suggestion I was just hoping to kind of point you in a direction that might spark something.  That one had a good example of incrementation. For sure I would look at the smiley code. See page 175 of Make Getting started with p5.js maybe that could help you could make the function of the eyeball and use random movement. Wish I could help more.


Third way of making configurable how hosting is kept alive

I have tried to incorporate the comments on the other two approaches (#129 and #253) to tackle the problem from yet another angle.
This now entirely relies on IApplicationShutdown as the method of communication and instead of going back and forth between Program and the keep-alive implementation, the latter is now responsible for doing whatever is required to call RequestShutdown(). For things like Console.CancelKeyPressed, this is the simplest event handler imaginable.
Additionally, it's now possible to register any number of IHostingKeepAlive implementations and any one can call RequestShutdown() independently.
The default implementation can be IServiceCollection.Replaced, but keep in mind the open issue and discussion from aspnet/DependencyInjection#155.
As a bonus, the implementation in Program.cs is now as simple as it can get.
@lodejard @davidfowl @victorhurdugaci @HaoK

I have updated my sample code

I don't really like the name of the interface IHostingKeepAlive. It implies that it is used to keep the hosting alive. It has nothing to do with that.
If the implementation doesn't call one of the termination methods, then the code will keep running forever. It would be a keep alive contract if it would block or return a cancellation token.

IShutdownMethod?

IShutdownMethod

IApplicationShutdownHandler /  Handle (instead of Setup)?

Isn't it weird that the "shutdown" handler writes "started"? :smile:

Hehe. See my samples for some better texts. It should be something along the lines of To terminate, press enter or similar.

IShutdownManager might not be bad either, since its his job to request shutdown...

Well, then all the way: IShutdownRequester. "Manager" is such an overloaded term…

Ok, then my vote is back to IShutdownHandler / Handle(IApplicationShutdown)

Huh, cla-required?

@Tragetaschen We just changed the repos from MS Open Tech to .NET Foundation so there's a different CLA. The new CLA is simpler than the old one and so should only take a few moments to re-sign. Apologies for the extra bit of work!

I have submitted the .NET Foundation's CLA, but @dnfclas doesn't recognize it yet. Maybe I did something wrong? @danroth27

Back to topic: Yes, indeed, IShutdownHandler concisely covers the the intention of the interface.
However, I'm having a harder time with the method name. I tried to write the API documentation when the name was Handle, but couldn't come up with a sentence that made it the logical conclusion. Setup on the other hand strongly points to the do-something-and-return mentality of the method.

Perhaps something like: "This method is responsible for handling shutdown and eventually calling RequestShutdown."

After thinking through this a bit I'd (and after a discussion with @victorhurdugaci), I'm wondering why we need any of this at all? We can just always wait on the reset event and nothing else. If you want to setup something then just do it in your Configure method. Hook whatever it is you need and then call RequestShutdown at the appropriate time.

And an app.UseDefaultShutdown() to get the the Console.ReadLine() behavior?

Nah just cut it altogether.

We were going to do that anyways in favor of ctrl+c

You won't see me shed tears :smile:

And again an update to the sample

@davidfowl I spoke to @lodejard and he thinks that this will not work because one might want to override the default behavior for Ctrl+C

@Tragetaschen regarding the CLA did you get an email from DocuSign, and then did you do the digital signature that it requests? If you've done that and it's not working let me know and I'll contact the CLA people.

You can always register an event handler on Console.CancelKeyPress to override the default behavior for Ctrl+C. I'm using a variant that maps Ctrl+C to graceful application shutdown:
public static void OnCancelKeyPress(this IApplicationShutdown applicationShutdown)
{
    Console.WriteLine("To terminate, press CTRL+C");
    Console.CancelKeyPress += delegate
    {
        applicationShutdown.RequestShutdown();
        Console.WriteLine("Received cancel key press");
    };
}

Of course, the event handler can do anything and Hosting doesn't put any requirement on that.
Maybe, I'm missing some information what this has to do with this PR :smile:

We want a default behavior that allows the server to shutdown gracefully, but that behavior has to be override-able.

@Tragetaschen, Thanks for signing the contribution license agreement so quickly! Actual humans will now validate the agreement and then evaluate the PR.
Thanks, DNFBOT;

I actually think is the best approach. What happens when you do ctrl + c right now?

This ends up calling the equivalent of Environment.Exit on both Mono and Windows and runs the Finalizers, not the Dispose logic. Btw, it's that finalizer code path that currently blocks Kestrel when doing CTRL+C.

@Tragetaschen so as it is right now, things will hang for kestrel without the graceful unwind? We could just add the control c handling then.

The main problem with Console.ReadLine is, that it requires a working TTY on Unix. That's the reason why this specific code needs to be removed from Hosting, so a Docker image or a systemd service can remove this superfluous requirement.
On the other hand, I don't think it's necessary to overriding/replace a default CTRL+C handler when Hosting registers it. You would only need this, if you don't want the process to shutdown and that's quite counter-intuitive when actually running on a terminal.
All other requirements can be easily wired against the members of IApplicationLifetime.
(dang, you beat me with your comment)

@Tragetaschen add that to your change

The Console.CancelKeyPress hasn't landed in .NET Core (System.Console 4.0.0-beta-22906) yet. I've if'ed that part and left a comment

@ellismg @ericstj Why don't we have that change yet in our builds? Has it made it in?

Looks like @ellismg didn't update the reference assembly.

I made a fix to the reference assembly, you should see it in the next build.

4.0.0-beta-22910 has landed and includes CancelKeyPress
:clap: :smile:

How do you overwrite the Ctrl+C behavior?

Why would you want to do that?
As discussed above, when not running in a console environment, the registered handler is never called and you can still implement any method you want to call IApplicationShutdown.RequestShutdown().
If you are running in a console environment, that's an interactive environment and properly reacting to CTRL+C like here is a genuinely good idea.
Still, I might be missing something, but right now I think a good answer to your question is: You don't need to.


3k stars

This project will reach more than 2000 stars. Change the name or add keywords in order to appear in the search engine on github.

Any idea for a better name?😂

yes  trading on Solana  or Sniper Solana


Unaligned load in vm/cc/SerializeString

There are new test failures on analyzer: Remove pre-NNBD strong_mode and non_error tests...[gardening] Remove gc tests, clean up failing tests in stress test suite..
The tests
vm/cc/SerializeString Crash (expected Pass)

are failing on configurations
vm-ubsan-linux-release-x64

Log:
--- Command "run_vm_unittest" (took 01.000175s):
DART_CONFIGURATION=ReleaseUBSANX64 out/ReleaseUBSANX64/run_vm_tests --dfe=/b/s/w/ir/out/ReleaseUBSANX64/gen/kernel-service.dart.snapshot --sound-null-safety --ignore-unrecognized-flags SerializeString

exit code:
-6

stdout:
Running test: SerializeString

stderr:
../../runtime/vm/object.cc:24827:32: runtime error: load of misaligned address 0x55de48614977 for type 'const uint16_t *' (aka 'const unsigned short *'), which requires 2 byte alignment
0x55de48614977: note: pointer points here
 3c 81 81 86 01  00 7f 00 80 00 ff 07 00  08 ff ff 80 80 80 8a 00  00 00 00 00 00 00 00 00  01 00 00
             ^
    #0 0x55de45fa77ff in dart::TwoByteString::New(unsigned short const*, long, dart::Heap::Space) /b/f/w/out/ReleaseUBSANX64/../../runtime/vm/object.cc:24827:5
    #1 0x55de45ef641c in dart::TwoByteStringMessageDeserializationCluster::ReadNodes(dart::MessageDeserializer*) /b/f/w/out/ReleaseUBSANX64/../../runtime/vm/message_snapshot.cc:2648:26
    #2 0x55de45eda060 in dart::MessageDeserializationCluster::ReadNodesWrapped(dart::MessageDeserializer*) /b/f/w/out/ReleaseUBSANX64/../../runtime/vm/message_snapshot.cc:459:9
    #3 0x55de45eda060 in dart::MessageDeserializer::Deserialize() /b/f/w/out/ReleaseUBSANX64/../../runtime/vm/message_snapshot.cc:3363:20
    #4 0x55de45edba0f in dart::ReadMessage(dart::Thread*, dart::Message*) /b/f/w/out/ReleaseUBSANX64/../../runtime/vm/message_snapshot.cc:3494:27
    #5 0x55de4589ed93 in dart::TestString(char const*) /b/f/w/out/ReleaseUBSANX64/../../runtime/vm/snapshot_test.cc:384:21
    #6 0x55de45885bd0 in dart::Dart_TestHelperSerializeString(dart::Thread*) /b/f/w/out/ReleaseUBSANX64/../../runtime/vm/snapshot_test.cc:406:3
    #7 0x55de45885bd0 in dart::Dart_TestSerializeString() /b/f/w/out/ReleaseUBSANX64/../../runtime/vm/snapshot_test.cc:395:1
    #8 0x55de4568d6c6 in dart::TestCase::Run() /b/f/w/out/ReleaseUBSANX64/../../runtime/bin/run_vm_tests.cc:53:3
    #9 0x55de4568d862 in dart::TestCaseBase::RunTest() /b/f/w/out/ReleaseUBSANX64/../../runtime/bin/run_vm_tests.cc:65:11
    #10 0x55de458d3b6c in dart::TestCaseBase::RunAll() /b/f/w/out/ReleaseUBSANX64/../../runtime/vm/unit_test.cc:86:13
    #11 0x55de4568e251 in dart::Main(int, char const**) /b/f/w/out/ReleaseUBSANX64/../../runtime/bin/run_vm_tests.cc:414:3
    #12 0x55de4568dde0 in main /b/f/w/out/ReleaseUBSANX64/../../runtime/bin/run_vm_tests.cc:445:29
    #13 0x7f765dede082 in __libc_start_main /build/glibc-BHL3KM/glibc-2.31/csu/../csu/libc-start.c:308:16
    #14 0x55de456741a8 in _start (/b/s/w/ir/out/ReleaseUBSANX64/run_vm_tests+0x28ba1a8)

SUMMARY: UndefinedBehaviorSanitizer: undefined-behavior ../../runtime/vm/object.cc:24827:32 in

--- Re-run this test:
python3 tools/test.py -n vm-ubsan-linux-release-x64 vm/cc/SerializeString

https://dart-review.googlesource.com/c/sdk/+/338644


chore(e2e): fixed failing e2e

What this PR does / why we need it:
Which issue(s) does this PR fixes?:

Fixes #
Additional comments?:
Developer Checklist:

[ ] Read your code changes at least once
[ ] Tested on iOS/Android device (e.g, No crashes, library supported etc.)
[ ] No console errors on web
[ ] Tested on Light mode and Dark mode*
[ ] Your UI implementation visually matched the rendered design*
[ ] Unit tests*
[ ] Added e2e tests*
[ ] Added translations*

@fullstackninja864 can we update this?

not relevant after v2 changes


Bug: Fix line height for WI Title in detail page

Bug: Fix line height for WI Title in detail page
#604

Current coverage is 56.38% (diff: 100%)

Merging #625 into master will not change coverage

@@             master       #625   diff @@
==========================================
  Files            41         41
  Lines          2100       2100
  Methods         409        409
  Messages          0          0
  Branches        433        433
==========================================
  Hits           1184       1184
  Misses          916        916
  Partials          0          0

Powered by Codecov. Last update 8f4cd02...4adb0ab

@almighty/uxd can we have a styleguide of some sort?
I feel like most of the styling we have for now is somewhat random/magic numbers with eye-estimation that works for the time being, and to regress horribly, should the peer DOM styles may change.

@debloper please review PatternFly.org for styles, etc.
Pattern Library: http://www.patternfly.org/pattern-library/#_
Styles: http://www.patternfly.org/styles/#_
If there is something that does not fall within the guidelines of PatternFly, then that needs to be brought up with the CSS Devs.


[derive] Test with trivial_bounds feature

DO NOT MERGE: We need to debug this issue.
The nightly trivial_bounds causes some derive-emitted code to compile which is designed to fail compilation. This commit adds a test that ensures that the emitted code still triggers some compiler errors.
Affects #61
Closes #500

Hey @joshlf. We rely on static assertions in some of our crates and were considering enabling trivial_bounds as well and ended up stumbling upon this through the RFC issue. In our testing, we couldn't actually get invalid assert_impl_alls to compile. I tried with a few separate Rust versions, and from what I can tell it looks like the error order in the nightly this repo happened to use was unexpected. After satisfying the FromZeros requirement, the assert_impl_all error gets displayed:
error[E0277]: the trait bound `NotZerocopy: FromBytes` is not satisfied
  --> zerocopy-derive/tests/trivial_bounds.rs:60:18
   |
60 | assert_impl_all!(FromBytes1: FromBytes);
   |                  ^^^^^^^^^^ the trait `FromBytes` is not implemented for `NotZerocopy`
   |
   = help: the following other types implement trait `FromBytes`:
             isize
             i8
             i16
             i32
             i64
             i128
             usize
             u8
           and 38 others
note: required for `FromBytes1` to implement `FromBytes`
  --> zerocopy-derive/tests/trivial_bounds.rs:55:10
   |
55 | #[derive(FromBytes, FromZeroes)]
   |          ^^^^^^^^^ unsatisfied trait bound introduced in this `derive` macro
note: required by a bound in `_::{closure#0}::assert_impl_all`
  --> zerocopy-derive/tests/trivial_bounds.rs:60:1
   |
60 | assert_impl_all!(FromBytes1: FromBytes);
   | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ required by this bound in `assert_impl_all`
   = note: this error originates in the derive macro `FromBytes` which comes from the expansion of the macro `assert_impl_all` (in Nightly builds, run with -Z macro-backtrace for more info)

Amusingly, in the nightly 5 days later (2023-10-26 instead of 2023-10-21), all the errors are shown as expected. Presumably some change fixed the error ordering or something.
Is the zerocopy crate still interested in adding trivial_bounds?

Huh fascinating! I'll have to resurrect this PR and try again.
Yes, we're still interested in trivial_bounds: specifically to support https://github.com/google/zerocopy/issues/1769.


[AutoPR scheduler/resource-manager] Add scheduler/resource-manager/readme.typescript.md

Created to sync https://github.com/Azure/azure-rest-api-specs/pull/4130

(message created by the CI based on PR content)


[MODULE] - Manhattan distance

Please describe the module you would like to add to bricks
I would like to have a module that calculates the manhattan distance between two vectors.
Do you already have an implementation?
If so, please share it here. For instance:
def manhattan(vector_one, vector_two):
    return sum(abs(val1-val2) for val1, val2 in zip(vector_one, vector_two))

Additional context

added with #262


RPC getpeerinfo

Initial implementation of RPC method getpeerinfo. Some RPC properties are not populated. In trello backlog https://trello.com/c/4SRyzKjI/59-connection-rpc-getpeerinfo
@bokobza

Oh yeah much clearer :-)
Still mine!

I'll probably do it tomorrow morning @mikedennis.

@bokobza @dangershony Thanks for the feedback. Will fix it up shortly.
Regarding "blocks" property. I found the same thing myself. The RPCClient does however pull it back and I ran the BitcoinD client and tested and it is populated with data so I'm a bit confused on where it comes from as well. I'm not sure if I'm putting the right data into it either, as I'm populating it as follows:
                    ChainHeadersBehavior chainHeadersBehavior = node.Behavior<ChainHeadersBehavior>();
                    if (chainHeadersBehavior != null)
                    {
                        rpcNode.Blocks = chainHeadersBehavior.PendingTip.Height;
                    }

Concerning "blocks", you can remove the property entirely as I think it comes from an old version of Core.

When you're done with that, I'll merge.

thanks @mikedennis !


Port the zfs driver

This PR includes https://github.com/lxc/lxd/pull/6686

jenkins: test this please

jenkins: test this please

jenkins: test this please


Help with pull request error.

Hi,
I am getting below error in my pull request for the check "  go test -v -coverprofile=profile.cov $(go list ./... | grep -v /.test.)".
Is it possible to see complete log of this run  or how to interpret the error code?
FAIL
Error: Process completed with exit code 1.
pull request: https://github.com/openconfig/featureprofiles/runs/6734436684?check_suite_focus=true
Thanks,
Prabha

I see this line, but I am also not sure exactly which path is missing?
https://github.com/openconfig/featureprofiles/runs/6734436684?check_suite_focus=true#step:5:180

@liulk for help

I see similiar failure for pull request  #198  https://github.com/openconfig/featureprofiles/runs/6759628187?check_suite_focus=true
Thanks.

Here is the explanation for lines 179-180.
F0604 00:05:07.462612    2421 ondatra.go:56] testbed path not specified
FAIL	github.com/openconfig/featureprofiles/feature/experimental/base_bgp_session_parameters	0.348s

Currently the config gen library unit tests and device Ondatra tests are mixed together in the same tree, and coverage tests in CI try to filter them out like this:
https://github.com/openconfig/featureprofiles/blob/34a869077a7142df858d290c6b0539e5358b314a/.github/workflows/go.yml#L44
This requires us to put the Ondatra tests in one of the .../{tests,ate_tests,otg_tests}/... subdirectories.
@cprabha Try to relocate the base_bgp_session_parameters here: feature/experimental/bgp/ate_tests/base_bgp_session_parameters
@azubaidhar Same for TE-3.6, which should be put under: feature/experimental/gribi/ate_tests/hierarchical_gribi_entries/ack_in_presence_other_routes
FYI: @bstoll @sthesayi relevant to our ongoing discussion about restructuring the directory tree.

Thanks Likai.
After moving scripts under ate_tests folder, all checks passed.
Thanks,
Prabha
Juniper Business Use Only
From: Likai Liu @.>
Sent: Tuesday, June 7, 2022 10:50 AM
To: openconfig/featureprofiles @.>
Cc: Prabha Chethan @.>; Mention @.>
Subject: Re: [openconfig/featureprofiles] Help with pull request error. (Issue #219)
[External Email. Be cautious of content]
Here is the explanation for lines 179-180.
F0604 00:05:07.462612    2421 ondatra.go:56] testbed path not specified
FAIL github.com/openconfig/featureprofiles/feature/experimental/base_bgp_session_parameters        0.348s
Currently the config gen library unit tests and device Ondatra tests are mixed together in the same tree, and coverage tests in CI try to filter them out like this:
https://github.com/openconfig/featureprofiles/blob/34a869077a7142df858d290c6b0539e5358b314a/.github/workflows/go.yml#L44https://urldefense.com/v3/__https:/github.com/openconfig/featureprofiles/blob/34a869077a7142df858d290c6b0539e5358b314a/.github/workflows/go.yml*L44__;Iw!!NEt6yMaO-gk!BclEldsTcP1RcQQClBznmG6JfIWI48-AmV0GWAgHhUhL6Ur9lqdkPAm1caD0zjYMo6kZ4qk3NE9q3YU4nLz7DYlt$
This requires us to put the Ondatra tests in one of the .../{tests,ate_tests,otg_tests}/... subdirectories.
@cprabhahttps://urldefense.com/v3/__https:/github.com/cprabha__;!!NEt6yMaO-gk!BclEldsTcP1RcQQClBznmG6JfIWI48-AmV0GWAgHhUhL6Ur9lqdkPAm1caD0zjYMo6kZ4qk3NE9q3YU4nEPKiwO2$ Try to relocate the base_bgp_session_parameters here: feature/experimental/bgp/ate_tests/base_bgp_session_parameters
@azubaidharhttps://urldefense.com/v3/__https:/github.com/azubaidhar__;!!NEt6yMaO-gk!BclEldsTcP1RcQQClBznmG6JfIWI48-AmV0GWAgHhUhL6Ur9lqdkPAm1caD0zjYMo6kZ4qk3NE9q3YU4nOyrambr$ Same for TE-3.6, which should be put under: feature/experimental/gribi/ate_tests/hierarchical_gribi_entries/ack_in_presence_other_routes
FYI: @bstollhttps://urldefense.com/v3/__https:/github.com/bstoll__;!!NEt6yMaO-gk!BclEldsTcP1RcQQClBznmG6JfIWI48-AmV0GWAgHhUhL6Ur9lqdkPAm1caD0zjYMo6kZ4qk3NE9q3YU4nMAOMZcB$ @sthesayihttps://urldefense.com/v3/__https:/github.com/sthesayi__;!!NEt6yMaO-gk!BclEldsTcP1RcQQClBznmG6JfIWI48-AmV0GWAgHhUhL6Ur9lqdkPAm1caD0zjYMo6kZ4qk3NE9q3YU4nKMhiZDr$ relevant to our ongoing discussion about restructuring the directory tree.

Reply to this email directly, view it on GitHubhttps://urldefense.com/v3/__https:/github.com/openconfig/featureprofiles/issues/219*issuecomment-1148987378__;Iw!!NEt6yMaO-gk!BclEldsTcP1RcQQClBznmG6JfIWI48-AmV0GWAgHhUhL6Ur9lqdkPAm1caD0zjYMo6kZ4qk3NE9q3YU4nFm51bX2$, or unsubscribehttps://urldefense.com/v3/__https:/github.com/notifications/unsubscribe-auth/AHCEB5UNNNH72SF7MKO2W7DVN6DT5ANCNFSM5YBCAB4Q__;!!NEt6yMaO-gk!BclEldsTcP1RcQQClBznmG6JfIWI48-AmV0GWAgHhUhL6Ur9lqdkPAm1caD0zjYMo6kZ4qk3NE9q3YU4nMXvMhXw$.
You are receiving this because you were mentioned.Message ID<EMAIL_ADDRESS>

Thanks Likai. Problem solved. Thanks.
From: Likai Liu @.>
Date: Tuesday, 7 June 2022 at 11:19 PM
To: openconfig/featureprofiles @.>
Cc: Abdul Zubaidhar Abdulla @.>, Mention @.>
Subject: Re: [openconfig/featureprofiles] Help with pull request error. (Issue #219)
[External Email. Be cautious of content]
Here is the explanation for lines 179-180.
F0604 00:05:07.462612    2421 ondatra.go:56] testbed path not specified
FAIL        github.com/openconfig/featureprofiles/feature/experimental/base_bgp_session_parameters        0.348s
Currently the config gen library unit tests and device Ondatra tests are mixed together in the same tree, and coverage tests in CI try to filter them out like this:
https://github.com/openconfig/featureprofiles/blob/34a869077a7142df858d290c6b0539e5358b314a/.github/workflows/go.yml#L44https://urldefense.com/v3/__https:/github.com/openconfig/featureprofiles/blob/34a869077a7142df858d290c6b0539e5358b314a/.github/workflows/go.yml*L44__;Iw!!NEt6yMaO-gk!H_iCLw0naS3_JixyhTXjQ39GZVvhTrSxN5iRnCkfoBKxzOGi5V_dBIQ5EFnVioAikoTrYgaHDVJG-XpRmup5WjMoK_o$
This requires us to put the Ondatra tests in one of the .../{tests,ate_tests,otg_tests}/... subdirectories.
@cprabhahttps://urldefense.com/v3/__https:/github.com/cprabha__;!!NEt6yMaO-gk!H_iCLw0naS3_JixyhTXjQ39GZVvhTrSxN5iRnCkfoBKxzOGi5V_dBIQ5EFnVioAikoTrYgaHDVJG-XpRmup5lunPaxU$ Try to relocate the base_bgp_session_parameters here: feature/experimental/bgp/ate_tests/base_bgp_session_parameters
@azubaidharhttps://urldefense.com/v3/__https:/github.com/azubaidhar__;!!NEt6yMaO-gk!H_iCLw0naS3_JixyhTXjQ39GZVvhTrSxN5iRnCkfoBKxzOGi5V_dBIQ5EFnVioAikoTrYgaHDVJG-XpRmup5bh45-Zk$ Same for TE-3.6, which should be put under: feature/experimental/gribi/ate_tests/hierarchical_gribi_entries/ack_in_presence_other_routes
FYI: @bstollhttps://urldefense.com/v3/__https:/github.com/bstoll__;!!NEt6yMaO-gk!H_iCLw0naS3_JixyhTXjQ39GZVvhTrSxN5iRnCkfoBKxzOGi5V_dBIQ5EFnVioAikoTrYgaHDVJG-XpRmup50afenqo$ @sthesayihttps://urldefense.com/v3/__https:/github.com/sthesayi__;!!NEt6yMaO-gk!H_iCLw0naS3_JixyhTXjQ39GZVvhTrSxN5iRnCkfoBKxzOGi5V_dBIQ5EFnVioAikoTrYgaHDVJG-XpRmup5_JQNz-M$ relevant to our ongoing discussion about restructuring the directory tree.
—
Reply to this email directly, view it on GitHubhttps://urldefense.com/v3/__https:/github.com/openconfig/featureprofiles/issues/219*issuecomment-1148987378__;Iw!!NEt6yMaO-gk!H_iCLw0naS3_JixyhTXjQ39GZVvhTrSxN5iRnCkfoBKxzOGi5V_dBIQ5EFnVioAikoTrYgaHDVJG-XpRmup5JVsv-AU$, or unsubscribehttps://urldefense.com/v3/__https:/github.com/notifications/unsubscribe-auth/AYQGC73GMYGD3I5BETN5SY3VN6DT5ANCNFSM5YBCAB4Q__;!!NEt6yMaO-gk!H_iCLw0naS3_JixyhTXjQ39GZVvhTrSxN5iRnCkfoBKxzOGi5V_dBIQ5EFnVioAikoTrYgaHDVJG-XpRmup5ek7EtsA$.


No support for Material design

It should have a support for Material design so we can change the color scheme easily from theme styles like this:
<style name="AppTheme" parent="Theme.AppCompat.Light.NoActionBar">
        <!-- Customize your theme here. -->
        <item name="colorPrimary">@color/colorPrimary</item>
        <item name="colorPrimaryDark">@color/colorPrimaryDark</item>
        <item name="colorAccent">@color/colorAccent</item>
</style>

We have now added support for material design.


docker build fails at step 32/35

Hello,
I try to build zato docker image as described in the documentaiton.
The build fails on STEP 32/35:
Step 32/35 : COPY ide_password_update.sh /opt/zato/ide_password_update.sh
COPY failed: stat /var/lib/docker/tmp/docker-builder646339215/ide_password_update.sh: no such file or directory

here my docker version
$ docker --version
Docker version 18.09.3, build 774a1f4

my setup:
$ uname -a
Linux localhost.localdomain 4.20.16-200.fc29.x86_64 #1 SMP Thu Mar 14 15:10:22 UTC 2019 x86_64 x86_64 x86_64 GNU/Linux
$ cat /etc/fedora-release
Fedora release 29 (Twenty Nine)

In fact this file is missing in filelist:
https://github.com/zatosource/zato-build/blob/master/docker/quickstart/filelist

I have downloaded the missing file and now it works.

This is fixed now, thank you @MikHulk

it's a pleasure!


Bad Supervisor.start_child call

In Ace.HTTP2.Connection there is a call to Supervisor.start_child/2 that doesn't have a child spec as the second argument.
https://github.com/CrowdHailer/Ace/blob/master/lib/ace/http2/connection.ex#L751
I am not sure what it's trying to do or how it could work.

Also here: https://github.com/CrowdHailer/Ace/blob/master/lib/ace/http/service.ex#L272

Ok, I understand what happened here. Older versions of Elixir allowed the last argument to be a lit of terms. That's no longer the case. This breaks dialyzer on recent version of Elixir.


Migrate from Apache Commons Lang to Commons Lang3

Teams often are using org.apache.commons.lang.StringUtils instead of org.apache.commons.lang3.StringUtils so I would like a recipe that migrates to commons-lang3.
I see the recipe as:

org.apache.commons.lang -> org.apache.commons.lang3
If commons-lang is present in the pom file, remove it.
If commons-lang3 is NOT present in the pom and/or dependency tree add it.

Hi @rdifrango,  Thanks for the suggestion, similar issue #106 exits.
I hope you don't mind me copying some of your info to that one and closing this one.


Add move semantics (constructor, operator=) to List.

We've recently begun to introduce move semantics to core, for its performance benefits. Examples of functions that can benefit a lot from move semantics include SWAP (https://github.com/godotengine/godot/pull/100367), reduce_at and insert (https://github.com/godotengine/godot/pull/100477), and simple data transfer. For more information on motivation, see https://github.com/godotengine/godot/pull/100426.
For List, this is especially important because a copy-constructor and copy-assignment are forced to copy the entire array, and all elements in it. And worse, because List is not contiguous, this is slow.
I first wanted to do a use-case analysis like in #100560, but quickly gave up because there were just too many beneficiaries of List move semantics.

Thanks!


[docs] Fix codesandbox export with dayjs

Since https://github.com/mui/mui-x/pull/5481 the bug is a lot more visible. When you export a codesandbox from https://mui.com/x/react-date-pickers/date-picker/#basic-usage

you will get https://codesandbox.io/s/3sem4m?file=/package.json:161-172

but this package doesn't exist. Dayjs already includes the types, proof<EMAIL_ADDRESS>
I found this while I was doing a bit of support in https://groups.google.com/a/mui.com/g/x/c/xHe-_HUVhjc.

Will be applied to MUI-X in https://github.com/mui/mui-x/pull/6103


Issue #7 | Add Mixpanel

Fixes #7

@Saidmurod1996 It seems mixpanel is not getting initialized.

[ ] Didn't get any event related to context menu which is added in this PR.

Plus, I think, it is good to have a property called environment which will be either debug or production.

Events are flowing to mixpanel now. @Saidmurod1996 awesome.


install hirefire raises syntax error

hirefire can be installed successfully but raises a syntax error
When installing 0.0.4 with pip I get:
File "/tmp/pip_build_root/HireFire/hirefire/procs/hotqueue.py", line 59
SyntaxError: invalid syntax -> def quantity(self. **kwargs):
This typo is also in the latest master

Indeed. I guess that means nobody (except you now) is using hotqueue. Thanks for the bug report!
You can either 1) wait for someone to fix this bug (perhaps me later this evening), or 2) create a pull request with the fix. Once that's done, I can't give you a timeframe on when a release would be cut (it's not up to me), but you can install the updated branch directly from git with pip.

It's not critical for me, I don't use hotqueue in my project. I just stumble across this ugly syntax error installing hirefire via pip.  👉 PR#25


TrafficFlow branch deployment error

Builds, but publish fails after initializing WorkerHost.

Fixed by DInar in various commits.


`@ Macros

Are macros supported?

Yes! Here's me using the macro autocompletion feature on my machine.

I was using ' instead of `. Thanks!

Glad it's all figured out!

Thanks!
On Sat, Nov 11, 2023 at 3:19 PM Liam Strand @.***>
wrote:

Glad it's all figured out!
—
Reply to this email directly, view it on GitHub
https://github.com/TuftsBCB/medford-vscode/issues/4#issuecomment-1806908300,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AH46USCDPTP24LIWTHCG77LYD7MT7AVCNFSM6AAAAAA6KLV466VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMBWHEYDQMZQGA
.
You are receiving this because you commented.Message ID:
@.***>