only/exclude config support

Was the config functionality implemented yet? I tried something similar by checking for armor values ['iron','diamond'] and then pulling those item_ids to allow them to be worn.

Nope, I'm currently moving codebase to typescript so there are quite a bit of major changes coming up soon. I'll try to look at this after the migration.

I'm very curious of the result, I'm still using javascript together with Node to get my bots in, which also gives me the ability to create an easy Web UI, what are cons and pros for typescript?

It's done already by the way, feel free to explore. Typescript is a subset of javascript which basically adds strict types to the language,  it's a two edged sword since it allows to create code less prone to errors by sacrificing speed of development because you need to write same code as in javascript but also add types and ensure they are being followed. You can still easily use this module in your javascript project, I just personally find typescript better in a long run 🙂

Thanks for the heads up buddy, will look into Typescript! ;)


Proper device assignment in generated labels for loss ops and image sampling

Codecov Report

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

@@            Coverage Diff             @@
##           master      #47      +/-   ##
==========================================
+ Coverage   24.09%   24.11%   +0.02%
==========================================
  Files          24       24
  Lines        1108     1107       -1
==========================================
  Hits          267      267
+ Misses        841      840       -1

Impacted Files
Coverage Δ

metrics/classifierscore.py
0% <0%> (ø)
:arrow_up:

trainer/trainer.py
0% <0%> (ø)
: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 150d847...759f2f0. Read the comment docs.


How to make ZodUnion from a enum?

Imagine we have an API where some types are list of options. It can be done via enums, arrays or objects. Here's a enum example:
enum color {
  red = "red",
  green = "green",
};

Imagine also, that we have to validate user input. Using Zod we can create a schema:
const colorSchema = z.union([z.literal("red"), z.literal("green")])

and then use it for validation:
const color = colorSchema.parse(userInput)
      //^? color: "red" | "green"

The problem with this approach is that we're breaking the DRY principle: we have to repeat every value from every enum from the API, which brings even bigger problem with keeping it up to date. If a new color gets added to the enum, how will our schema know about it? There is no way. So the only solid way to do it, is to convert enums to z.unions.
However, I couldn't figure out how to do this.
z.union() accepts an array of literals, but I cannot find a solution how to create ZodUnion from a enum.
Here are a couple of sandboxes, that differ only in the way how options are defined:

using enum
using object

Check out the ***-marked lines.

Thanks to folks from the TypeScript Discord channel, I've finally come up with this solution.

import { z } from "zod";

// API: we have some API which returns themes by color ids

enum color {
  red = "red",
  green = "green",
};
type ColorId = keyof typeof color

type ThemeRequest = {
  colorId: ColorId;
};

declare function getThemeApi(req: ThemeRequest): any;

// UTILTIY TYPES, to convert TS union to TS tuple

type ToIntersection<T> = (T extends T ? (_: T) => 0 : never) extends (_: infer U) => 0
	? U
	: never;

type Last<T> = ToIntersection<T extends unknown ? () => T : never> extends () => infer U
	? U
	: never;

type Keys<T> = [T] extends [never] ? [] : [...Keys<Exclude<T, Last<T>>>, Last<T>];

// UTILITY TYPE, that takes object type and retuns a union of ZodLiteral's

type MakeValues<T> = { [K in keyof T]: z.ZodLiteral<T[K]> }[keyof T]

type _V = MakeValues<typeof color>
    //^?

// UTILITY FUNCTION, that takes object and returns an array z.literal() but asserts its
// type to be a tuple of specific values from the object keys.

function makeValues<T extends Record<string, unknown>>(options: T) {
  return Object.keys(options).map((k) => z.literal(k)) as Keys<MakeValues<T>>
}

const _F = makeValues(color)
     //^?

// ZOD SCHEMA, which combines things from above

const colorRequestSchema = z.object({
  colorId: z.union(makeValues(color))
});

// USAGE: let's write some code

function getTheme(colorId: string) {
  const request = colorRequestSchema.parse({ colorId });
        //^?
  getThemeApi(request);
}

Update. It finally failed in the end due to the limitation of TS.
See: https://github.com/microsoft/TypeScript/issues/34933#issuecomment-1696519995
I believe ZodUnion shouldn't be used for tasks like this one.

It should work: https://stackoverflow.com/a/76797654

In case you have similar problem I had - the trick was to use ${EnumName} which resolves to union in TS and convince TS Object.values of enum is that union:
const myEnumSchema = z.enum(Object.values(MyEnum) as [`${MyEnum}`]);

This returns a schema, that infers to union of enum values.

for example:
type FruitsUnion = 'Apples' | 'Bananas' | 'Oranges';

enum FruitsEnum {
  ApplesWithDifferentKey = 'Apples',
  Bananas = 'Bananas',
  WhateverSomethingElse = 'Oranges',
}

const fruitsEnumSchema = z.enum(Object.values(FruitsEnum) as [`${FruitsEnum}`]);
// z.ZodEnum<["Apples" | "Bananas" | "Oranges"]>

type FruitsEnumUnion = z.infer<typeof fruitsEnumSchema>;
// "Apples" | "Bananas" | "Oranges"

assert<Equals<FruitsUnion, FruitsEnumUnion>>();
// No error

assert<Equals<'Apples' | 'Bananas', FruitsEnumUnion>>();
assert<Equals<'Apples' | 'Bananas' | 'Oranges' | 'Tomatoes', FruitsEnumUnion>>();
// error

console.log('Parsing result:', fruitsEnumSchema.safeParse('Apples'));
// {success: true, data: 'Apples'}
console.log('Parsing result:', fruitsEnumSchema.safeParse('Tomatoes'));
// {success: false}


Refactor: Introduce message header factor to remove duplication

Description
Refactor: Introduce message header factor to remove duplication

Codecov Report

Merging #102 (a8719ec) into main (1b96c90) will decrease coverage by 66.44%.
The diff coverage is 0.00%.

@@             Coverage Diff             @@
##             main     #102       +/-   ##
===========================================
- Coverage   81.82%   15.39%   -66.44%
===========================================
  Files         325      320        -5
  Lines        5993     6014       +21
  Branches      598        0      -598
===========================================
- Hits         4904      926     -3978
- Misses        878     5068     +4190
+ Partials      211       20      -191

Impacted Files
Coverage Δ

...e/OutgoingMessages/Common/Json/JsonHeaderWriter.cs
0.00% <0.00%> (-94.65%)
:arrow_down:

... and 266 files with indirect coverage changes
:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more


Typo "Visual Studio code"→"Visual Studio Code"

https://docs.microsoft.com/en-us/azure/developer/github/deploy-with-visual-studio
#PingMSFTDocs

@hyoshioka0128 - thanks for catch.


KICS install.sh script cannot completed on v1.5.1 and and v1.5.2

Hi, I tried to run KICS install using One-liner Install Script using Curl command:
sudo curl -sfL 'https://raw.githubusercontent.com/Checkmarx/kics/master/install.sh' | bash -s -- -b /usr/local/bin
I tried with debugging mode and it return:
38 | Checkmarx/kics debug http_download https://github.com/Checkmarx/kics/releases/v1.5.2
39 | Checkmarx/kics info found version: 1.5.2 for v1.5.2/linux/x64
40 | Checkmarx/kics debug downloading files into /tmp/tmp.rgij4CjclP
41 | Checkmarx/kics debug http_download https://github.com/Checkmarx/kics/releases/download/v1.5.2/kics_1.5.2_linux_x64.tar.gz
42 | Checkmarx/kics debug http_download https://github.com/Checkmarx/kics/releases/download/v1.5.2/kics_1.5.2_checksums.txt
43 | % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
44 | Dload  Upload   Total   Spent    Left  Speed
45 |
46 | 0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
47 | 100  1700  100  1700    0     0  47222      0 --:--:-- --:--:-- --:--:-- 47222
And when I tried the KICS scanning command:
 kics scan -p
it gave kics: command not found error response on Linux based CLI
But when I tried to add tag using v1.5.0 , there is no issue and KICS run properly.

Hello, @adhitris 🙂 Thank you so much for contacting us!
KICS deprecated the availability of binaries in the GitHub releases assets as of version 1.5.2.
The lastest binary available is 1.5.1: https://github.com/Checkmarx/kics/releases/tag/v1.5.1

Hello, @adhitris!
We will close this issue. The file install.sh will be probably removed in the next KICS release (1.6.4) since KICS deprecated the availability of binaries. However, we documented how to build KICS from source code (PR #5982).
cd kics
go mod vendor
LINUX/MAC: go build -o ./bin/kics cmd/console/main.go
WINDOWS: go build -o ./bin/kics.exe cmd/console/main.go (make sure to create the bin folder)


Handle non-happy paths where the final payment fails and the state changes to pending_*_info_update

What
Handle non-happy paths where the SEP-31 transaction gets to the pending_customer_info_update or pending_transaction_info_update states.

Cc @reecexlm, @lijamie98, @stfung77


merge commits from freakboy3742

see also: https://github.com/pybee/briefcase/issues/117#issuecomment-381393379

NameError: name 'errno' is not defined

fixed with: https://github.com/pybee/briefcase/pull/119


Todo input from "text" to "textarea"

This app has a nice UI and I would like to see the input field be a textarea field to make editing longer than normal items easier.  This would improve the usability IMHO and you can circumvent LF with a special character if desired as not to inject them into the text file.

Hi @marshmanGit.
That should not be a problem, although I would not replace the input field with a textarea, as the input field is imo sufficient in most cases.
How about a switch button that will replace the input field with a textarea on demand?
Can you explain, what you mean with this "and you can circumvent LF with a special character if desired as not to inject them into the text file." I don't get it ;)

Hi @marshmanGit.
That should not be a problem, although I would not replace the input field with a textarea, as the input field is imo sufficient in most cases.
How about a switch button that will replace the input field with a textarea on demand?
Can you explain, what you mean with this "and you can circumvent LF with a special character if desired as not to inject them into the text file." I don't get it ;)

I think @marshmanGit means that, while being in the text area mode, you could insert new lines into the task's description. When saving it to the file, the LF (line feed) characters would be replaced with some other invisible and harmless ASCII character, for example ACK. And the code for displaying the loaded tasks would then  replace ACK characters with the LF character.
Apart from the bigger text input field, it looks like this is also a feature request for multi-line tasks. Is that correct?
It's quite an interesting idea, but it abuses the todo.txt format, so I'm not sure if this is a good or bad thing.

I think @marshmanGit means that, while being in the text area mode, you could insert new lines into the task's description. When saving it to the file, the LF (line feed) characters would be replaced with some other invisible and harmless ASCII character, for example ACK. And the code for displaying the loaded tasks would then  replace ACK characters with the LF character.
Apart from the bigger text input field, it looks like this is also a feature request for multi-line tasks. Is that correct?
It's quite an interesting idea, but it abuses the todo.txt format, so I'm not sure if this is a good or bad thing.

Absolutely!   I was just offering a possible approach to address an issue you could run into due to the fact that Textarea input fields will typically allow Line Feeds.  As @wsdfhjxc eluded to, your text files that hold the TASK data appears to parse based on line feeds ( Line 1 = task 1, Line2=task2 etc...).  Provided that is true then you will need to replace LF in the textarea input value when posted with something else.  You can then convert it back upon the user clicking to edit the task.
I appreciate the quick response and your alternate solution offering.

Absolutely!   I was just offering a possible approach to address an issue you could run into due to the fact that Textarea input fields will typically allow Line Feeds.  As @wsdfhjxc eluded to, your text files that hold the TASK data appears to parse based on line feeds ( Line 1 = task 1, Line2=task2 etc...).  Provided that is true then you will need to replace LF in the textarea input value when posted with something else.  You can then convert it back upon the user clicking to edit the task.
I appreciate the quick response and your alternate solution offering.

In lieu of the textarea ( and possibly abusing the todo.txt format as @wsdfhjxc mentioned, another idea that may prove valuable would be to have a "notes".  In my mind the missing element is the ability to supply some form of extended notes no matter how it is implemented.  These could be kept within individual files per TASK (assuming most tasks will never have notes ) but since you don't have a unique identifier for each task then I'm not sure how you would relate them.

In lieu of the textarea ( and possibly abusing the todo.txt format as @wsdfhjxc mentioned, another idea that may prove valuable would be to have a "notes".  In my mind the missing element is the ability to supply some form of extended notes no matter how it is implemented.  These could be kept within individual files per TASK (assuming most tasks will never have notes ) but since you don't have a unique identifier for each task then I'm not sure how you would relate them.

@marshmanGit . Took me some time, but now I got it, sorry ;)
@wsdfhjxc , I'm not even sure if it would clash with the todo.txt rules, as the syntax doesn't change or anything. I think the problem is more, that it could be a feature that won't actually be used by many users. Also there might be some minor challenges with the date and recurrence picker or the suggestions container for contexts and projects.
I for instance add one todo after another using the keyboard shortcuts and I'm quite efficient doing this with sleek. For me a multi line textarea, with the purpose of creating more than one todo, wouldn't be helpful. But that's just me. If you have a really good idea on how to implement it user friendly, I wouldn't mind to merge a PR at all.
But let's talk about the textarea itself. I added it to a testing release: https://github.com/ransome1/sleek/releases/tag/v0.8.2
If you find a bit of spare time I would like to hear your feedback, if this helps you.

@marshmanGit . Took me some time, but now I got it, sorry ;)
@wsdfhjxc , I'm not even sure if it would clash with the todo.txt rules, as the syntax doesn't change or anything. I think the problem is more, that it could be a feature that won't actually be used by many users. Also there might be some minor challenges with the date and recurrence picker or the suggestions container for contexts and projects.
I for instance add one todo after another using the keyboard shortcuts and I'm quite efficient doing this with sleek. For me a multi line textarea, with the purpose of creating more than one todo, wouldn't be helpful. But that's just me. If you have a really good idea on how to implement it user friendly, I wouldn't mind to merge a PR at all.
But let's talk about the textarea itself. I added it to a testing release: https://github.com/ransome1/sleek/releases/tag/v0.8.2
If you find a bit of spare time I would like to hear your feedback, if this helps you.

@ransome1 Yeah, it doesn't clash with the todo.txt rules. I was rather talking about ideological reasons, as the format doesn't support multi-line tasks by design (there is a discussion, however). And I don't know how much "faithful" to the todo.txt format sleek aims to be, but it seems you're not against that, so that's cool. Personally, single-line tasks are enough for me as well.

@ransome1 Yeah, it doesn't clash with the todo.txt rules. I was rather talking about ideological reasons, as the format doesn't support multi-line tasks by design (there is a discussion, however). And I don't know how much "faithful" to the todo.txt format sleek aims to be, but it seems you're not against that, so that's cool. Personally, single-line tasks are enough for me as well.

Thank your for the update.  AWESOME!!!

Thank your for the update.  AWESOME!!!


Sample code: Remove auto-edit behavior when adding ROIs

This PR removes the toggle of editable ROI when selecting a mode to draw a ROI since this is hard to understand when running the sample code.

LGTM. Smaller sample code, better


[C++] Remove MSVC warning suppression

Clear out all warnings generated at -W4 on MSVC. Eliminate the need for the warning suppression header inc/bond/core/warning.h. Includes changes to codegen to ensure there is no name shadowing between parameters names and field names. warning.h is left in place in case applications are dependent on it. This will be removed in a few months.

Added https://github.com/Microsoft/bond/issues/367 to track removal of warning.h.

Looks like I need to address some things in VC12 still.

CI failure is unrelated. I think this is ready to be committed to master. Please Rebase and Merge, not Squash.

LGTM. I can rebase and merge this later today.


[FEATURE] update dependency

Requirements
@easyops-cn/docusaurus-search-local   0.33.6  →   0.34.0
@typescript-eslint/eslint-plugin      5.52.0  →   5.54.0
@typescript-eslint/parser             5.52.0  →   5.54.0
eslint                                8.34.0  →   8.35.0
sass                                 ^1.58.1  →  ^1.58.3
/assign

Hey @Arhell, I see that you added /assign to your issues. Is there a GitHub action that you're aware of that automatically assigns issues when you do that? If so, I'll look into adding it to this repo.


Add reducer for fetcher

Description
some foreign exchange only supports reversed pairs.
for example USD-KRW is supported rather than KRW-USD.
somehow, after getting 1 USD price in KRW, for example 1USD = 1350KRW,
to get 1 KRW price in USD, it should be calculated with reversed division 1 KRW = 1 / 1350 USD.
this PR adds reducer for that functionality
Fixes # (issue)
Type of change
Please delete options that are not relevant.

[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] This change requires a documentation update

Checklist before requesting a review

[x] I have performed a self-review of my code.
[ ] If it is a core feature, I have added thorough tests.

Deployment

[ ] Should publish npm package
[ ] Should publish Docker image

@nick-bisonai I know it is not related to this PR, but could you please look at this https://github.com/Bisonai/orakl/blob/master/core/src/worker/reducer.ts. I think we have duplicated reducers since it used to be part of core before. Additionally, we have tests for reducers at https://github.com/Bisonai/orakl/blob/master/core/test/reducer.test.ts which would be good to move to fetcher and revive them 🎉 We could also make separate issue out of it. Please decide 🙏

@nick-bisonai I know it is not related to this PR, but could you please look at this https://github.com/Bisonai/orakl/blob/master/core/src/worker/reducer.ts. I think we have duplicated reducers since it used to be part of core before. Additionally, we have tests for reducers at https://github.com/Bisonai/orakl/blob/master/core/test/reducer.test.ts which would be good to move to fetcher and revive them 🎉 We could also make separate issue out of it. Please decide 🙏

totally agreed, I'll make issues for removing reducer duplication and updating test codes


mocha test fails when i add route middleware in express

Prerequisites

[x ] Checked that your issue hasn't already been filed by cross-referencing issues with the faq label
[x ] Checked next-gen ES issues and syntax problems by using the same environment and/or transpiler configuration without Mocha to ensure it isn't just a feature that actually isn't supported in the environment in question or a bug in your code.
[x ] 'Smoke tested' the code to be tested by running it outside the real test suite to get a better sense of whether the problem is in the code under test, your usage of Mocha, or Mocha itself
[ x] Ensured that there is no discrepancy between the locally and globally installed versions of Mocha. You can find them with: node node_modules/.bin/mocha --version(Local) and mocha --version(Global). We recommend that you not install Mocha globally.

Description
After Adding route middleware mocha runs into error but after commenting the route middlware mocha test works
i have configured it to run in my test folder only.
const express = require('express)
const routes = require('../routes)
const app = express()

app.use('/api/, routes)

Steps to Reproduce

Expected behavior: [What you expect to happen]
 ✓ generateId should generate a uuid
    ✓ generateTransactionRef should generate a uuid
    ✓ hashPassword should hash a plain password (73ms)
    ✓ compareHash should compare hashed password to the plain value (65ms)
    ✓ generateToken should generate a string of token with different characters
    ✓ addTokenToData should generate a user object with the token included
    ✓ verifyToken should decoded the token
    ✓ validateInput should validate an input using a schema
    ✓ checkArrayIsNotEmpty should check if an array is empty

Actual behavior: [What actually happens]
Users/xexnon/Resource/practice/wallet-api/app/utils/helpers/helper.js:1
TypeError: Cannot destructure property 'SECRET' of '_07c.a(...)' as it is undefined.
at Object. (/Users/xexnon/Resource/practice/wallet-api/app/utils/helpers/helper.js:11:9)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/app/utils/helpers/index.js:1)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/app/utils/index.js:1)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/app/validations/user.js:1)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/app/validations/index.js:1)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/app/routes/v1/auth/index.js:1)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/app/routes/v1/index.js:1)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/config/app.js:1)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/config/index.js:1)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/app/flutterwave/helpers/helper.js:1)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/app/flutterwave/helpers/index.js:1)
at Generator.next ()
at Object. (/Users/xexnon/Resource/practice/wallet-api/test/unit/flwhelper.test.js:1)
at Generator.next ()
at Object.exports.requireOrImport (/Users/xexnon/Resource/practice/wallet-api/node_modules/mocha/lib/esm-utils.js:42:12)
at Object.exports.loadFilesAsync (/Users/xexnon/Resource/practice/wallet-api/node_modules/mocha/lib/esm-utils.js:55:34)
at Mocha.loadFilesAsync (/Users/xexnon/Resource/practice/wallet-api/node_modules/mocha/lib/mocha.js:473:19)
at singleRun (/Users/xexnon/Resource/practice/wallet-api/node_modules/mocha/lib/cli/run-helpers.js:125:15)
at exports.runMocha (/Users/xexnon/Resource/practice/wallet-api/node_modules/mocha/lib/cli/run-helpers.js:190:10)
at Object.exports.handler (/Users/xexnon/Resource/practice/wallet-api/node_modules/mocha/lib/cli/run.js:362:11)
at /Users/xexnon/Resource/practice/wallet-api/node_modules/yargs/build/index.cjs:443:71
at process.runNextTicks [as _tickCallback] (internal/process/task_queues.js:60:5)
at internal/main/run_main_module.js:17:47

Reproduces how often: [What percentage of the time does it reproduce?]
Versions

The output of mocha --version and node node_modules/.bin/mocha --version: 8.4.0
The output of node --version:v14.17.0
Your operating system

name and version: Mac
architecture (32 or 64-bit):

Your shell (e.g., bash, zsh, PowerShell, cmd): bash
Your browser and version (if running browser tests):
Any third-party Mocha-related modules (and their versions):chai
Any code transpiler (e.g., TypeScript, CoffeeScript, Babel) being used (and its version): esm 3.2.25

Additional Information

@Xexnon without any sample to reproduce this issue, you will have to find the cause on your own. I will close this issue within the next few days.
The esm package hasn't been maintained since more than two years. I guess you use it on your own risk. I recommend to switch to Node's native ESM support, which is supported by Mocha.


Several templates disappeared from Docs: Template menu

My team has two article templates that are part of the Docs: Template menu. These are smb-article-template.md and smb-faq-template.md. These templates somehow dropped out of the menu.  I'm only seeing 6 there now. Can someone please look into this problem so we can get our templates back? Thanks!

@jamarw can you check on this? I believe this has to do with the changes made to the docs article templates/scaffolding.

Hi @SKjerland , an updated version of the template extension was released to support friendly names and repo-specific templates. I've contacted the PM team to let them know we need to get your templates added. Thanks and I'll check back in on this soon.

@SKjerland apologies! We restructured the template menu and lost a few.  We'll get them back ASAP.

@meganbradley - I thought the templates could be used from any repo as long as you have the Docs Article Templates Extension enabled in VS Code? I don't recall templates needing to be tied to specific repos previously. I know our main repo is microsoft-365-docs-pr, but there may be other repos that my co-workers work in that I don't know about. Also, we may be adding a new repo for some partner content and we would want to use the template there. Is there no way to make templates available across all repos?

@SKjerland I can make them available for all repos for now, but it would be better to have a list of repos where they're likely to be used. The list was getting very long and most templates aren't applicable to most repos, so we're trying to scope them appropriately to reduce noise. Do you have a team alias I could send a query to to try to get the right list?

@meganbradley - Okay, I understand. I asked our team and they said it's okay to scope them to microsoft-365-docs-pr for now. If we need to use them in other repos in the future, should I just email you? Or is there another process you want me to follow? Thanks!

Thanks @skjerland. I added the SMB templates to the microsoft-365-docs-pr repo and verified that they're showing up. Let me know if you want different friendly names. To get them added to other repos in the future, it's probably better to file an issue and @ mention me and Jamar, just so the request isn't delayed if I'm on vacation or something.

@meganbradley - I can see them now! Thanks! The friendly names are great. I will be sure to file and issue @mention you and Jamar if we need them added to other repos in the future. Thanks for fixing this so quickly!


Public relay name change

nostr.bitcoiner.social -> offchain.pub
note1zpgy9f8tlwdwhhwtzy50vpl72qkunzhmy57p4f5xaf8h57pfvwpschwe74
I also pulled it out of the default relay list because I've been starting to realize that I don't think I can sustain a free relay by myself long-term, even with funds from the pay-to-relay server. Nostr relays will need to host files for applications like "github on nostr" and at a certain point I will need to experiment with non-free models for that to work.

yeah you bet. thanks for supporting the network! will try to push to prod tonight.


Spaces in URL

Hi, I have Problems cloning a Repository, that is in a folder with a space.
I tried
a) git clone http://entwsrv01/r/Tests/Leerzeichen Test/Test1.git
b) git clone "http://entwsrv01/r/Tests/Leerzeichen Test/Test1.git"
both results in "fatal: repository ... not found"
What I'm doing wrong? Or isn't it supported?

Whilespace is illegal in repo names.
http://gitblit.com/administration.html#H3


Performance log (profile)

FUNCTION  <SNR>1_LoadFTPlugin()
    Defined: /opt/homebrew/Cellar/neovim/0.10.0/share/nvim/runtime/ftplugin.vim:15
Called 8 times
Total time:   0.023398
 Self time:   0.019442

count  total (s)   self (s)
    8              0.000035     if exists("b:undo_ftplugin")
                                  exe b:undo_ftplugin
                                  unlet! b:undo_ftplugin b:did_ftplugin
    8              0.000006     endif

    8              0.000034     let s = expand("<amatch>")
    8              0.000012     if s != ""
    8              0.000033       if &cpo =~# "S" && exists("b:did_ftplugin")
                            	" In compatible mode options are reset to the global values, need to
                            	" set the local values also when a plugin was already used.
                            	unlet b:did_ftplugin
    8              0.000003       endif

                                  " When there is a dot it is used to separate filetype names.  Thus for
                                  " "aaa.bbb" load "aaa" and then "bbb".
   16              0.000047       for name in split(s, '\.')
                                    " Load Lua ftplugins after Vim ftplugins _per directory_
                                    " TODO(clason): use nvim__get_runtime when supports globs and modeline
                                    " XXX: "[.]" in the first pattern makes it a wildcard on Windows
    8   0.023100   0.019143         exe $'runtime! ftplugin/{name}[.]{{vim,lua}} ftplugin/{name}_*.{{vim,lua}} ftplugin/{name}/*.{{vim,lua}}'
   16              0.000025       endfor
    8              0.000005     endif

FUNCTION  <SNR>11_Remove_Matches()
    Defined: /opt/homebrew/Cellar/neovim/0.10.0/share/nvim/runtime/plugin/matchparen.vim:206
Called 90 times
Total time:   0.001069
 Self time:   0.001069

count  total (s)   self (s)
   90              0.000271   if exists('w:paren_hl_on') && w:paren_hl_on
                                while !empty(w:matchparen_ids)
                                  silent! call remove(w:matchparen_ids, 0)->matchdelete()
                                endwhile
                                let w:paren_hl_on = 0
   90              0.000034   endif

FUNCTION  <SNR>4_isHelm()
    Defined: ~/.local/share/nvim/lazy/vim-helm/ftdetect/helm.vim:1
Called 4 times
Total time:   0.000551
 Self time:   0.000551

count  total (s)   self (s)
    4              0.000410   let filepath = expand("%:p")

                              " yaml/yml/tpl/txt inside templates dir
    4              0.000066   if filepath =~ '\v/(templates)/.*\.(ya?ml|tpl|txt)$' | return 1 | endif

    4              0.000010   let filename = expand("%:t")

                              " helmfile templated values
    4              0.000023   if filename =~ '\v.*\.gotmpl$' | return 1 | endif

                              " helmfile.yaml / helmfile-my.yaml / helmfile_my.yaml etc
    4              0.000018   if filename =~ '\v(helmfile).*\.ya?ml$' | return 1 | endif

    4              0.000005   return 0

FUNCTION  <SNR>2_LoadIndent()
    Defined: /opt/homebrew/Cellar/neovim/0.10.0/share/nvim/runtime/indent.vim:14
Called 8 times
Total time:   0.004549
 Self time:   0.004549

count  total (s)   self (s)
    8              0.000020     if exists("b:undo_indent")
                                  exe b:undo_indent
                                  unlet! b:undo_indent b:did_indent
    8              0.000004     endif
    8              0.000022     let s = expand("<amatch>")
    8              0.000009     if s != ""
    8              0.000010       if exists("b:did_indent")
                            	unlet b:did_indent
    8              0.000003       endif

                                  " When there is a dot it is used to separate filetype names.  Thus for
                                  " "aaa.bbb" load "indent/aaa.vim" and then "indent/bbb.vim".
   16              0.000035       for name in split(s, '\.')
                                    " XXX: "[.]" in the pattern makes it a wildcard on Windows
    8              0.004374         exe $'runtime! indent/{name}[.]{{vim,lua}}'
   16              0.000013       endfor
    8              0.000003     endif

FUNCTION  <SNR>18_SynSet()
    Defined: /opt/homebrew/Cellar/neovim/0.10.0/share/nvim/runtime/syntax/synload.vim:27
Called 14 times
Total time:   0.043364
 Self time:   0.015706

count  total (s)   self (s)
                              " clear syntax for :set syntax=OFF  and any syntax name that doesn't exist
   14              0.000100   syn clear
   14              0.000022   if exists("b:current_syntax")
                                unlet b:current_syntax
   14              0.000005   endif

   14              0.000034   0verbose let s = expand("<amatch>")
   14              0.000012   if s == "ON"
                                " :set syntax=ON
                                if &filetype == ""
                                  echohl ErrorMsg
                                  echo "filetype unknown"
                                  echohl None
                                endif
                                let s = &filetype
   14              0.000012   elseif s == "OFF"
                                let s = ""
   14              0.000004   endif

   14              0.000008   if s != ""
                                " Load the syntax file(s).  When there are several, separated by dots,
                                " load each in sequence.  Skip empty entries.
   24              0.000040     for name in split(s, '\.')
   12              0.000015       if !empty(name)
                                    " XXX: "[.]" in the first pattern makes it a wildcard on Windows
   12   0.042901   0.015243         exe $'runtime! syntax/{name}[.]{{vim,lua}} syntax/{name}/*.{{vim,lua}}'
   12              0.000010       endif
   24              0.000036     endfor
   14              0.000005   endif

FUNCTION  <SNR>11_Highlight_Matching_Pair()
    Defined: /opt/homebrew/Cellar/neovim/0.10.0/share/nvim/runtime/plugin/matchparen.vim:44
Called 76 times
Total time:   0.006907
 Self time:   0.006062

count  total (s)   self (s)
   76              0.000419   if !exists("w:matchparen_ids")
    4              0.000006     let w:matchparen_ids = []
   76              0.000068   endif
                              " Remove any previous match.
   76   0.001417   0.000573   call s:Remove_Matches()

                              " Avoid that we remove the popup menu.
                              " Return when there are no colors (looks like the cursor jumps).
   76              0.000271   if pumvisible() || (&t_Co < 8 && !has("gui_running"))
                                return
   76              0.000024   endif

                              " Get the character under the cursor and check if it's in 'matchpairs'.
   76              0.000227   let c_lnum = line('.')
   76              0.000145   let c_col = col('.')
   76              0.000060   let before = 0

   76              0.000198   let text = getline(c_lnum)
   76              0.001132   let matches = matchlist(text, '\(.\)\=\%'.c_col.'c\(.\=\)')
   76              0.000154   if empty(matches)
                                let [c_before, c] = ['', '']
   76              0.000043   else
   76              0.000255     let [c_before, c] = matches[1:2]
   76              0.000030   endif
   76              0.000852   let plist = split(&matchpairs, '.\zs[:,]')
   76              0.000185   let i = index(plist, c)
   76              0.000058   if i < 0
                                " not found, in Insert mode try character before the cursor
   76              0.000150     if c_col > 1 && (mode() == 'i' || mode() == 'R')
                                  let before = strlen(c_before)
                                  let c = c_before
                                  let i = index(plist, c)
   76              0.000034     endif
   76              0.000044     if i < 0
                                  " not found, nothing to do
   76              0.000078       return
                                endif
                              endif

                              " Figure out the arguments for searchpairpos().
                              if i % 2 == 0
                                let s_flags = 'nW'
                                let c2 = plist[i + 1]
                              else
                                let s_flags = 'nbW'
                                let c2 = c
                                let c = plist[i - 1]
                              endif
                              if c == '['
                                let c = '\['
                                let c2 = '\]'
                              endif

                              " Find the match.  When it was just before the cursor move it there for a
                              " moment.
                              if before > 0
                                let has_getcurpos = exists("*getcurpos")
                                if has_getcurpos
                                  " getcurpos() is more efficient but doesn't exist before 7.4.313.
                                  let save_cursor = getcurpos()
                                else
                                  let save_cursor = winsaveview()
                                endif
                                call cursor(c_lnum, c_col - before)
                              endif

                              if !has("syntax") || !exists("g:syntax_on")
                                let s_skip = "0"
                              else
                                " Build an expression that detects whether the current cursor position is
                                " in certain syntax types (string, comment, etc.), for use as
                                " searchpairpos()'s skip argument.
                                " We match "escape" for special items, such as lispEscapeSpecial, and
                                " match "symbol" for lispBarSymbol.
                                let s_skip = 'synstack(".", col("."))' . '->indexof({_, id -> synIDattr(id, "name") =~? ' . '"string\\|character\\|singlequote\\|escape\\|symbol\\|comment"}) >= 0'
                                " If executing the expression determines that the cursor is currently in
                                " one of the syntax types, then we want searchpairpos() to find the pair
                                " within those syntax types (i.e., not skip).  Otherwise, the cursor is
                                " outside of the syntax types and s_skip should keep its value so we skip
                                " any matching pair inside the syntax types.
                                " Catch if this throws E363: pattern uses more memory than 'maxmempattern'.
                                try
                                  execute 'if ' . s_skip . ' | let s_skip = "0" | endif'
                                catch /^Vim\%((\a\+)\)\=:E363/
                                  " We won't find anything, so skip searching, should keep Vim responsive.
                                  return
                                endtry
                              endif

                              " Limit the search to lines visible in the window.
                              let stoplinebottom = line('w$')
                              let stoplinetop = line('w0')
                              if i % 2 == 0
                                let stopline = stoplinebottom
                              else
                                let stopline = stoplinetop
                              endif

                              " Limit the search time to 300 msec to avoid a hang on very long lines.
                              " This fails when a timeout is not supported.
                              if mode() == 'i' || mode() == 'R'
                                let timeout = exists("b:matchparen_insert_timeout") ? b:matchparen_insert_timeout : g:matchparen_insert_timeout
                              else
                                let timeout = exists("b:matchparen_timeout") ? b:matchparen_timeout : g:matchparen_timeout
                              endif
                              try
                                let [m_lnum, m_col] = searchpairpos(c, '', c2, s_flags, s_skip, stopline, timeout)
                              catch /E118/
                                " Can't use the timeout, restrict the stopline a bit more to avoid taking
                                " a long time on closed folds and long lines.
                                " The "viewable" variables give a range in which we can scroll while
                                " keeping the cursor at the same position.
                                " adjustedScrolloff accounts for very large numbers of scrolloff.
                                let adjustedScrolloff = min([&scrolloff, (line('w$') - line('w0')) / 2])
                                let bottom_viewable = min([line('$'), c_lnum + &lines - adjustedScrolloff - 2])
                                let top_viewable = max([1, c_lnum-&lines+adjustedScrolloff + 2])
                                " one of these stoplines will be adjusted below, but the current values are
                                " minimal boundaries within the current window
                                if i % 2 == 0
                                  if has("byte_offset") && has("syntax_items") && &smc > 0
                            	let stopbyte = min([line2byte("$"), line2byte(".") + col(".") + &smc * 2])
                            	let stopline = min([bottom_viewable, byte2line(stopbyte)])
                                  else
                            	let stopline = min([bottom_viewable, c_lnum + 100])
                                  endif
                                  let stoplinebottom = stopline
                                else
                                  if has("byte_offset") && has("syntax_items") && &smc > 0
                            	let stopbyte = max([1, line2byte(".") + col(".") - &smc * 2])
                            	let stopline = max([top_viewable, byte2line(stopbyte)])
                                  else
                            	let stopline = max([top_viewable, c_lnum - 100])
                                  endif
                                  let stoplinetop = stopline
                                endif
                                let [m_lnum, m_col] = searchpairpos(c, '', c2, s_flags, s_skip, stopline)
                              endtry

                              if before > 0
                                if has_getcurpos
                                  call setpos('.', save_cursor)
                                else
                                  call winrestview(save_cursor)
                                endif
                              endif

                              " If a match is found setup match highlighting.
                              if m_lnum > 0 && m_lnum >= stoplinetop && m_lnum <= stoplinebottom
                                if s:has_matchaddpos
                                  call add(w:matchparen_ids, matchaddpos('MatchParen', [[c_lnum, c_col - before], [m_lnum, m_col]], 10))
                                else
                                  exe '3match MatchParen /\(\%' . c_lnum . 'l\%' . (c_col - before) . 'c\)\|\(\%' . m_lnum . 'l\%' . m_col . 'c\)/'
                                  call add(w:matchparen_ids, 3)
                                endif
                                let w:paren_hl_on = 1
                              endif

FUNCTION  <SNR>12_LocalBrowse()
    Defined: /opt/homebrew/Cellar/neovim/0.10.0/share/nvim/runtime/plugin/netrwPlugin.vim:105
Called 11 times
Total time:   0.000345
 Self time:   0.000345

count  total (s)   self (s)
                              " Unfortunate interaction -- only DechoMsg debugging calls can be safely used here.
                              " Otherwise, the BufEnter event gets triggered when attempts to write to
                              " the DBG buffer are made.

   11              0.000025   if !exists("s:vimentered")
                               " If s:vimentered doesn't exist, then the VimEnter event hasn't fired.  It will,
                               " and so s:VimEnter() will then be calling this routine, but this time with s:vimentered defined.
                            "   call Dfunc("s:LocalBrowse(dirname<".a:dirname.">)  (s:vimentered doesn't exist)")
                            "   call Dret("s:LocalBrowse")
                               return
   11              0.000005   endif

                            "  call Dfunc("s:LocalBrowse(dirname<".a:dirname.">)  (s:vimentered=".s:vimentered.")")

   11              0.000042   if has("amiga")
                               " The check against '' is made for the Amiga, where the empty
                               " string is the current directory and not checking would break
                               " things such as the help command.
                            "   call Decho("(LocalBrowse) dirname<".a:dirname.">  (isdirectory, amiga)")
                               if a:dirname != '' && isdirectory(a:dirname)
                                sil! call netrw#LocalBrowseCheck(a:dirname)
                                if exists("w:netrw_bannercnt") && line('.') < w:netrw_bannercnt
                                 exe w:netrw_bannercnt
                                endif
                               endif

   11              0.000050   elseif isdirectory(a:dirname)
                            "   call Decho("(LocalBrowse) dirname<".a:dirname."> ft=".&ft."  (isdirectory, not amiga)")
                            "   call Dredir("LocalBrowse ft last set: ","verbose set ft")
                               " Jul 13, 2021: for whatever reason, preceding the following call with
                               " a   sil!  causes an unbalanced if-endif vim error
                               call netrw#LocalBrowseCheck(a:dirname)
                               if exists("w:netrw_bannercnt") && line('.') < w:netrw_bannercnt
                                exe w:netrw_bannercnt
                               endif

   11              0.000004   else
                               " not a directory, ignore it
                            "   call Decho("(LocalBrowse) dirname<".a:dirname."> not a directory, ignoring...")
   11              0.000004   endif

                            "  call Dret("s:LocalBrowse")

FUNCTIONS SORTED ON TOTAL TIME
count  total (s)   self (s)  function
   14   0.043364   0.015706  <SNR>18_SynSet()
    8   0.023398   0.019442  <SNR>1_LoadFTPlugin()
   76   0.006907   0.006062  <SNR>11_Highlight_Matching_Pair()
    8   0.004549             <SNR>2_LoadIndent()
   90   0.001069             <SNR>11_Remove_Matches()
    4   0.000551             <SNR>4_isHelm()
   11   0.000345             <SNR>12_LocalBrowse()

FUNCTIONS SORTED ON SELF TIME
count  total (s)   self (s)  function
    8   0.023398   0.019442  <SNR>1_LoadFTPlugin()
   14   0.043364   0.015706  <SNR>18_SynSet()
   76   0.006907   0.006062  <SNR>11_Highlight_Matching_Pair()
    8              0.004549  <SNR>2_LoadIndent()
   90              0.001069  <SNR>11_Remove_Matches()
    4              0.000551  <SNR>4_isHelm()
   11              0.000345  <SNR>12_LocalBrowse()

I've tried to recreate the same output from my profiler.

enabled matchparen
enabled netrw
installed vim-helm (went into a template so it would activate)

resulting in almost the same profile as yours (couldn't get netrw to trigger
FUNCTIONS SORTED ON TOTAL TIME
count  total (s)   self (s)  function
  189   0.014192   0.012304  <SNR>27_Highlight_Matching_Pair()
   10   0.008151             <SNR>43_SynSet()
    5   0.006246   0.005811  <SNR>1_LoadFTPlugin()
  189   0.001888             <SNR>27_Remove_Matches()
    5   0.001654             <SNR>2_LoadIndent()

FUNCTIONS SORTED ON SELF TIME
count  total (s)   self (s)  function
  189   0.014192   0.012304  <SNR>27_Highlight_Matching_Pair()
   10              0.008151  <SNR>43_SynSet()
    5   0.006246   0.005811  <SNR>1_LoadFTPlugin()
  189              0.001888  <SNR>27_Remove_Matches()
    5              0.001654  <SNR>2_LoadIndent()

I got at most a bit of stuttering when vim-helm was engaged but it was still pretty smooth.
I really hate asking this but could you try without any autocmd and other plugins? If not, can you share your config?

I've tried to recreate the same output from my profiler.
* enabled matchparen

* enabled netrw

* installed vim-helm (went into a template so it would activate)

resulting in almost the same profile as yours (couldn't get netrw to trigger
FUNCTIONS SORTED ON TOTAL TIME
count  total (s)   self (s)  function
  189   0.014192   0.012304  <SNR>27_Highlight_Matching_Pair()
   10   0.008151             <SNR>43_SynSet()
    5   0.006246   0.005811  <SNR>1_LoadFTPlugin()
  189   0.001888             <SNR>27_Remove_Matches()
    5   0.001654             <SNR>2_LoadIndent()

FUNCTIONS SORTED ON SELF TIME
count  total (s)   self (s)  function
  189   0.014192   0.012304  <SNR>27_Highlight_Matching_Pair()
   10              0.008151  <SNR>43_SynSet()
    5   0.006246   0.005811  <SNR>1_LoadFTPlugin()
  189              0.001888  <SNR>27_Remove_Matches()
    5              0.001654  <SNR>2_LoadIndent()

I got at most a bit of stuttering when vim-helm was engaged but it was still pretty smooth. I really hate asking this but could you try without any autocmd and other plugins? If not, can you share your config?

I've sent you an invitation to my configs

Tried it out with your config and recorded it to show how I'm experiencing it, is the cursor slow for you or just opening floats? I'm starting to think that maybe your api requests (kubectl commands) might take a long time? But I'm guessing k9s is working fine? Could you try this command just so I understand the delay from kubectl:
time k get --raw /api/v1/pods > output

It should give something like this:

https://github.com/Ramilito/kubectl.nvim/assets/8473233/a7de0a5b-15ea-4a86-ad71-649a73c49eb1

I have no issues with k9s. It's running pretty smooth. Executing kubectl commands in my terminal is also fast.
My k8s lives in aws if that will make it easier to debug the performance issue

And opening the float window is taking so much time yes. Especially when I open/close this plugin

So, i used this "hack" to profile a little bit more, and it shows how long it took to toggle this plugin:
{"ts":7996830.958,"ph":"X","name":"kubectl.actions.layout.set_buf_options","tid":1,"dur":11594.5,"cat":"function","args":{"3":"k8s_pods","2":1000,"4":"k8s_pods","n":4,"1":7},"pid":1},
{"ts":9347202.791,"ph":"X","name":"kubectl.actions.highlight.set_highlighting","tid":1,"dur":148.1670000013,"cat":"function","args":{"n":1,"1":7},"pid":1},
{"ts":7995015.5,"ph":"X","name":"kubectl.actions.actions.buffer","tid":1,"dur":1352336,"cat":"function","args":{"n":3,"2":"k8s_pods"},"pid":1},
{"ts":7994936.5,"ph":"X","name":"kubectl.resourcebuilder.display","tid":1,"dur":1352416.291,"cat":"function","args":{"3":"Pods","2":"k8s_pods","n":4},"pid":1},

the duration specified for the following methods are enormous:

kubectl.actions.actions.buffer
kubectl.resourcebuilder.display

I hope this helped a little bit more

That's really surprising, those functions are only neovim api things. It's even after processing the data which I was going to suspect after ruling out the kubectl delay.
I use that profiler quite a bit and really like it, do you have the rest of the file!? It might show me exactly which function is the problem

I can feel the performance difference. It feels faster. Almost the same as using k9s.

Even in aws!?

The performance issue was only applicable with aws. Otherwise it was smooth.
Right now, after this proxy change stuff, it feels faster than before, but not at the same level as using k9s. But I think we will get there :)

Nice! Yeah k9s is butter smooth, they use some tricks when loading that I'll try to copy (show partial information for example), Also, added a loading indicator that's supposed to entertain when loading 😅


Use quick_error in most of programs

A few still need to be done

Ow I actually disagree with this... quick_error seems a bit unmaintained. I like thiserror better, but I'd prefer to get rid of both. I don't think they really pull their weight over just implementing Display and From.

But, at the very least we should choose between using quick_error or thiserror and not have both in our dependency tree like we do now. So in that sense I agree with this.

happy to move to thiserror
I didn't realize that quick_error wasn't maintained


Add untrusted workspace supported flags

This PR fixes #https://github.com/microsoft/azuredatastudio/issues/17535.  The built-in extensions haven't been updated to supported restricted mode.  This change will allow all the built-in extensions to work in this mode.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 41.479%

Totals

Change from base Build<PHONE_NUMBER>:
0.0%

Covered Lines:
26892

Relevant Lines:
58801

💛  - Coveralls


Manage Neighbor Advertisement without Target link-layer address

While running the lwAFTR with a conf file were next_hop_ipv6_addr was set, I noticed the address couldn't be resolved into a MAC address. The reason was that although a Neighbor Solicitation was sent, the Neighbor Advertisement that arrived to the lwAFTR didn't include a Target link-layer address. The current code was not managing this case. About this, RFC 4861 says:
"When responding to unicast solicitations, the option can be omitted since the sender of the solicitation has the correct link-layer address"
Source: https://tools.ietf.org/html/rfc4861#page-23
In this case, the source ethernet address of the Neighbor Advertisement packet is used instead.
The pull-request includes an Unit test for a packet of this kind.

After the nit with ffi.copy is addressed, lgtm. I've run the tests manually, on the grounds you'll have snabb-bot up soon and we can't use .travis.yml without blocking our ability to merge this branch upstream.

Ok, yes, given that caller we need it to have the copy; I missed that, and thought it was only used in a much more local scope. In that case, LGTM.


Add support to disable/enable SST-BF

#63

Codecov Report

Merging #77 (410ab28) into main (56bb49f) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main      #77   +/-   ##
=======================================
  Coverage   77.08%   77.08%
=======================================
  Files          17       17
  Lines        1872     1872
=======================================
  Hits         1443     1443
  Misses        320      320
  Partials      109      109

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 56bb49f...410ab28. Read the comment docs.

Changes:

changed the SetBFStatus API signature to use a pointer to SstPackageInfo instead of the actual struct

Could you submit the 3rd commit make: Enable gofmt to write changes  as a separate PR. It's unrelated and I'd like to get that merged smile

This is in #84

Intermediate push that addresses some of the comments.

Changes:

multiple packages can be selected with -package option
User can give a list of packages when enabling or disabling BF

ping @jukkar, any update on this? I think we should try to get this merged

Updated according to comments.


Sagemaker notebook failed - no option to start no option to retrieve ipynb files

I added activation code to the script start notebook script.
The notebook failed.
I restored the srcipt, but can't run the notebook.
The important ting is to get the code of the ipynb files inside.
How can I restore the notebook or get the inner files data?

@juliensimon any solution?
all my code is inside...
I will make a backup after restoring that's for sure..

Hi @Kaidanov .  I'm sorry to hear you've run into troubles.  An AWS Support request is probably the best path here.  They should be able to dig into your account and resources more thoroughly to diagnose and hopefully resolve your problem.
On a side note, have you checked your CloudWatch logs for the notebook instance (CloudWatch -> Logs -> filter to the /aws/sagemaker/NotebookInstances Log Group)?  That may give you more insight into the problem.
Thanks.

@djarpin
I added activation code to the script start notebook script.
The notebook failed.
I restored the srcipt
The log shows the stage when the script was with the lines of python activate.
The issue is that the state of the notebook not renewed and I don't how to make it to reload from failed state ..
That's the log :

Hi @Kaidanov
You may restart the failed notebook instance using the AWS CLI or SDK's StartNotebookInstance API.  Note that you will need to fix the issue in your script that caused it to fail the first time for it to succeed.
aws sagemaker start-notebook-instance \

  --region us-west-2 \

  --notebook-instance-name <name>

@jaipreetss thank you so much ! no words.. thanks alot

Closing this issue.  Feel free to re-open as necessary.

Thanks for the solution @jaipreetss .. this saved my day !!! 👍
The solution suggested by @jaipreetss can be implemented via boto3 as well:
import boto3
client = boto3.client('sagemaker')
response = client.start_notebook_instance(
    NotebookInstanceName='<Notebook-Name-to-Restart>'
)


get_publishing_date() doesn't fallback to raw regexes search?

via newspapers/extractors.py#get_publishing_date() documentation:
    3 strategies for publishing date extraction. The strategies
    are descending in accuracy and the next strategy is only
    attempted if a preferred one fails.
    1. Pubdate from URL
    2. Pubdate from metadata
    3. Raw regex searches in the HTML + added heuristics

From what I can see, it looks like the search for publish_date ends with the iteration through PUBLISH_DATE_TAGS. I think raw regex search is a nice fallback and I've seen it done reasonably well in a Ruby library named pismo.
The relevant code:
    # Return an estimate of when the page/content was created
    # As clients of this library should be doing HTTP retrieval themselves, they can fall to the
    # Last-Updated HTTP header if they so wish. This method is just rough and based on content only.
    MONTHS_REGEX = %r{(Jan|Feb|Mar|Apr|May|Jun|Jul|Aug|Sep|Oct|Nov|Dec|January|February|March|April|May|June|July|August|September|October|November|December)\.?}i
    DATETIME_REGEXEN = [
      /#{MONTHS_REGEX}\b\s+\d+\D{1,10}\d{4}/i,
      /(on\s+)?\d+\s+#{MONTHS_REGEX}\s+\D{0,10}\d+/i,
      /(on[^\d+]{1,10})\d+(th|st|rd)?.{1,10}#{MONTHS_REGEX}\b[^\d]{1,10}\d+/i,
      /\b\d{4}\-\d{2}\-\d{2}\b/i,
      /\d+(th|st|rd).{1,10}#{MONTHS_REGEX}\b[^\d]{1,10}\d+/i,
      /\d+\s+#{MONTHS_REGEX}\b[^\d]{1,10}\d+/i,
      /on\s+#{MONTHS_REGEX}\s+\d+/i,
      /#{MONTHS_REGEX}\s+\d+/i,
      /\d{4}[\.\/\-]\d{2}[\.\/\-]\d{2}/,
      /\d{2}[\.\/\-]\d{2}[\.\/\-]\d{4}/
    ]

    def datetime
      datetime = 10
      DATETIME_REGEXEN.detect {|r| datetime = @doc.to_html[r] }

      return unless datetime and datetime.length > 4
      # Clean up the string for use by Chronic
      datetime.strip!
      datetime.gsub!(/(Monday|Tuesday|Wednesday|Thursday|Friday|Saturday|Sunday|mon|tues|tue|weds|wed|thurs|thur|thu|fri|sat|sun)[^\w]*/i, '')
      datetime.sub!(/(on\s+|\,|\.)/, '')
      datetime.sub!(/(\d+)(th|st|rd)/, '\1')
      Chronic.parse(datetime, :context => :past) || datetime
    end

As an example of where this regex approach succeeds: This Github Engineering post on Jekyll: http://githubengineering.com/browser-monitoring-for-github-com/ ...currently, newspaper does not return a publish_date attribute, but pismo succeeds...and it doesn't even use heuristics as far as I can tell, other than, find the first regex match for a date.
Although to speak specifically of the Jekyll scenario...the standard template produces this HTML and CSS selector:
May 19, 2015

Perhaps there should be 4  extraction strategies, with the 4th being raw regex, and the 3rd being body tag parsing? You could solve the problem for a huge number of standard Jekyll and Wordpress blogs by having a list of known HTML tags and selectors.
And hell, since newspaper handles the HTTP request...maybe a 5th strategy should be to use the last-updated HTTP header? Yes, it's pretty unreliable...but maybe it's better than nothing? That said, with this many strategies, maybe it's worth it to include an attribute (e.g. publish_date_info) that is a dict, e.g.
{ 'publish_date': datetime.datetime(2015, 5, 19, 0, 0), 'strategy': 'raw_regex', 'candidates': [list of other found dates] }

I know that making the API more complicated is not ideal...but in the case of publish date...this bit of metadata is extremely helpful for curation/archiving activities, so it's arguably worth it. I'd argue the same for authors and the various strategies needed to extract bylines.

Oops I see this is a duplicate of #119

Closing as it's a duplicate

Thanks for identifying this however!


Error when initializing a repo

I'm getting this error when initializing a new repo.
record not written, error codes 71 571011C
record not written, error codes 71 571011C
record not written, error codes 71 571011C
record not written, error codes 71 571011C
record not written, error codes 71 571011C

TSO BPXMTEXT shows this for the 571011C error
571011C
BPXFSRDW 08/23/18
JRFileNotOpen: The file is not opened
Action: Reissue the request specifying an open file descriptor.

The repo is init'd, the .git dir has files and directories and the .gitattributes is empty.
I get this on both LPARs I have DBB 1.0.7 installed.
Am I doing something wrong or is there a bug?

I traced the BGZINIT file and the file descriptor being returned in this call:
"open /u/xx35/test7/.gitattributes 147 755"
fd = retval
"0"
Is returning fd 0 (zero, which is normally for STDIN)
The write call fails with a -1 (presumably because fd 0 is normally STDIN?)
"write 0 rec 15"
if retval=-1
"-1"
"1"
"-1"
"1"
then
say 'record not written, error codes' errno errnojr
"record not written, error codes"
"71"
"record not written, error codes 71"
"571011C"
"record not written, error codes 71 571011C"

Hi,
can you please share the entire output of your git init cmd?
Do you run this from the cmdline or any CI agent?
What version of git do you use on USS?
Probably it would be good to raise this question on the Rocket Git forum at:
https://forum.rocketsoftware.com/c/rocket-z-os-open-source-languages-tools/13?order=activity

Hi, I'm using the IBM ISPF Git Client provided by IBM in the DBB IDE directory.  Option 1.  This is a ISPF application with an interface to Rocket's Git port.  Output of git --version:
git version 2.14.4_zos_b09
This is a problem with the ISPF code, not the git client.  I've reported this to my IBM contact and they could reproduce the problem and have forwarded it to the developers.

Thanks for sharing the details. We recently discussed a similar situation, if not yours.

This issue has been resolved by the refresh of the ISPF client  through commit https://github.com/IBM/dbb/commit/2f154c21eb3f4b2d406c580852fdaeb4fb5261bb


Packaged OS X application automatically associates with .love files

A very common problem i see often and frankly kinda annoying, but whatever.
Just thought i would bring this up.

Hey hatninja, thanks for reporting the issue.
I think this is due to UTExportedTypeDeclarations not being removed in Info.plist. However, this should have been done by the internal script.
Could you please show me the Info.plist file in .app/Contents/ ?

`

BuildMachineOSBuild
15C50
CFBundleDevelopmentRegion
English
CFBundleDocumentTypes

CFBundleTypeIconFile
GameIcon
CFBundleTypeName
LÖVE Project
CFBundleTypeRole
Viewer
LSHandlerRank
Owner
LSItemContentTypes

org.love2d.love-game

CFBundleTypeName
Folder
CFBundleTypeOSTypes

fold

CFBundleTypeRole
Viewer
LSHandlerRank
None

CFBundleTypeIconFile
Document
CFBundleTypeName
Document
CFBundleTypeOSTypes

****

CFBundleTypeRole
Editor

CFBundleExecutable
love
CFBundleIconFile
OS X AppIcon
CFBundleIdentifier
org.hatninja.bouncingball
CFBundleInfoDictionaryVersion
6.0
CFBundleName
Bouncing Ball
CFBundlePackageType
APPL
CFBundleShortVersionString
1.0
CFBundleSignature
LoVe
CFBundleSupportedPlatforms

MacOSX

DTCompiler
com.apple.compilers.llvm.clang.1_0
DTPlatformBuild
7C68
DTPlatformVersion
GM
DTSDKBuild
15C43
DTSDKName
macosx10.11
DTXcode
0720
DTXcodeBuild
7C68
LSApplicationCategoryType
public.app-category.games
NSHighResolutionCapable

NSHumanReadableCopyright
© 2006-2016 LÖVE Development Team
NSPrincipalClass
NSApplication
UTExportedTypeDeclarations

UTTypeConformsTo

com.pkware.zip-archive

UTTypeDescription
LÖVE Project
UTTypeIconFile
GameIcon
UTTypeIdentifier
org.love2d.love-game
UTTypeReferenceURL
http://love2d.org/wiki/Game_Distribution
UTTypeTagSpecification

com.apple.ostype
LOVE
public.filename-extension

love

public.mime-type
application/x-love-game

`

http://pastebin.com/w7ZBHD0Q

Hm... Strange. It indeed seems like the UTExportedTypeDeclarations section hasn't been removed. I'll be sure to find a fix for that.


Fix zero-point addition in PortableCwiseMul

This bug caused errors for the int8 unidirectional_sequence_lstm layer.

Python example to reproduce the bug in the LSTM layer, fixed by this PR (click to expand).
import numpy as np
import tensorflow as tf

BATCH_SIZE = 1
NUM_SAMPLES = 3
SAMPLE_SIZE = 4
LSTM_UNITS = 2

def convert_model(model: tf.keras.Model, representative_dataset_gen) -> bytes:
    converter = tf.lite.TFLiteConverter.from_keras_model(model)
    converter.experimental_new_converter = True
    converter.optimizations = [tf.lite.Optimize.DEFAULT]
    converter.representative_dataset = representative_dataset_gen
    converter.target_spec.supported_ops = [tf.lite.OpsSet.TFLITE_BUILTINS_INT8]
    converter.inference_input_type = tf.int8
    converter.inference_output_type = tf.int8
    return converter.convert()

def dataset_example(num_samples: int = 100):
    for _ in range(num_samples):
        yield [
            tf.random.uniform(shape=(1, NUM_SAMPLES, SAMPLE_SIZE), minval=-1, maxval=1)
        ]

def get_model() -> tf.keras.Model:
    input_layer = tf.keras.layers.Input(
        shape=(NUM_SAMPLES, SAMPLE_SIZE), batch_size=BATCH_SIZE
    )
    x = tf.keras.layers.LSTM(
        units=LSTM_UNITS,
        return_sequences=True,
    )(input_layer)
    x = tf.keras.layers.Flatten()(x)
    return tf.keras.Model(input_layer, x, name="LSTM")

def test_bug_reproducer() -> None:
    # Get Keras model
    lstm_model = get_model()
    lstm_model.summary()

    # Convert model to INT8 TFLite
    tflite_lstm_model = convert_model(lstm_model, dataset_example)

    # Test Keras model
    test_data = np.random.uniform(-1, 1, (BATCH_SIZE, NUM_SAMPLES, SAMPLE_SIZE))
    print("> Testing Keras LSTM with input data:")
    print(test_data)
    result = lstm_model.predict(test_data)
    print("> got Keras result:")
    print(result)

    # Test INT8 TFLite model
    interpreter = tf.lite.Interpreter(model_content=tflite_lstm_model)
    interpreter.allocate_tensors()
    output_details = interpreter.get_output_details()[0]
    input_details = interpreter.get_input_details()[0]
    input_scale = input_details["quantization_parameters"]["scales"][0]
    input_zp = input_details["quantization_parameters"]["zero_points"][0]
    output_scale = output_details["quantization_parameters"]["scales"][0]
    output_zp = output_details["quantization_parameters"]["zero_points"][0]
    test_data_int8 = np.round((test_data / input_scale) + input_zp).astype(np.int8)
    print("> Testing TFLite INT8 LSTM with input data:")
    print(test_data_int8)
    interpreter.set_tensor(input_details["index"], test_data_int8)
    interpreter.invoke()
    result_int8 = interpreter.get_tensor(output_details["index"])
    print("> got TFlite INT8 result:")
    print(result_int8)
    result_float = (result_int8 - output_zp) * output_scale
    print("> got TFlite float result:")
    print(result_float)

test_bug_reproducer()

@JunyoungLim  Can you please review this PR ? Thank you!

Pushed an additional fix based on debugging from @rewu93 that should hopefully mean all the internal tests pass. Let's go through the PR merging process one more time.

@Tombana, are you ok with us making the same fixes as an internal commit and then having that be reflected in the GitHub tree? That may be a more efficient path to getting this fix in.

@Tombana, are you ok with us making the same fixes as an internal commit and then having that be reflected in the GitHub tree? That may be a more efficient path to getting this fix in.

That's totally fine :+1:, thanks for the additional fixes.

The changes from this PR have been merged with https://github.com/tensorflow/tensorflow/commit/59fb183f7e7153a91b5ec0b054d3ecdea432a50a

@Tombana, please note that the fix had to be reverted with https://github.com/tensorflow/tensorflow/commit/db1dd64675e4cb471390ba2aacdedf27b842399a due to some internal regressions.

@Tombana, the fix is now merged with https://github.com/tensorflow/tensorflow/commit/9b4997f7b0c13972c03362f94768e8f8e4d046f4 (from @rewu93).
The corresponding change is in the TFLM repo as well with https://github.com/tensorflow/tflite-micro/pull/1553

Thanks!


Visualization tool

Hi,
I'm trying to reproduce the visualizations presented in the paper. The 3D visualization showing consistent high values across tokens for a channel is the one I'm working on. I tried matplotlib and vega but they both fail due to lack of memory. Can you share details/code on how that visualization was made?
To be precise, the visualization in slide#5.
Thank you!

Could you share the visualization method? thanks


Support RTPSender.ReplaceTrack()

In Web API, Track connected to RTPSender can be replaced without renegotiation.
For example, it is used to switch between front/rear cameras.
https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpSender/replaceTrack
In the currently implementation, Track which is not bound to RTPSender returns error.
https://github.com/pion/webrtc/blob/2b212f8a7c4feed4621272bf8309637827e695cd/track.go#L155-L157

Add ReplaceTrack() to RTPSender which removes itself from the currently bound Track and add to the new Track
Allow Track.WriteRTP() to be called on Track without RTPSender

(It will be useful when using with https://github.com/pion/mediadevices)

👍 from me on ReplaceTrack, that would be really helpful
Can we just have the caller ignore io.ErrClosedPipe? In the past users were confused why video wasn't showing up. They would create a Track and just expect it to work. By returning an error it helped users debugging a lot.

I do think we need to revisit the Media API entirely. This could be a good kicking off point. Stuff like we shouldn't be story the PayloadType/SSRC on tracks at all.

https://github.com/pion/webrtc/issues/1020#issue-563147171 is a kind of a workaround to do it on v2 API.
https://github.com/pion/webrtc/issues/1025 may be a better solution to implement ReplaceTrack easily.

Are there any plans to implement this in v2 (or is v3 coming anytime soon)? I am considering adding it myself and have not dug into the specs, but any idea what ReplaceTrack look like? I see the spec but I fear details like checking whether renegotiation is needed and what "switch seamlessly" entails.

@cretz  I don't have specific plan yet. It's very helpful if you can dig into this.

checking whether renegotiation is needed

MDN said:
https://developer.mozilla.org/en-US/docs/Web/API/RTCRtpSender/replaceTrack

The new track must be of the same media kind (audio, video, etc) and switching the track should not require negotiation.

I need this for an impl I'm working on, so I started a toying w/ an impl at https://github.com/cretz/webrtc/tree/replace-track. It's not very cleaned up by intention as I'm still working bugs out, but right now when it tries to switch tracks in the example code, it just ends up pausing the track, but if switched back, resumes just fine. I will be digging more into why, but if there's anything obvious, pointers welcome.

After further investigation, the only way I can get track replacement to work is to mess w/ the RTP packets. Specifically, besides setting the ssrc, I also have to keep my own sequence number, keep my own timestamps, and send an out-of-band RTCP PLI on change. I have tested with h264 and vp8 (no audio atm) and that procedure works well. There are various issues if any of those 4 things are not done which I can explain on request.
So, I don't think we can really support RTPSender.ReplaceTrack here since it requires tighter control over all of the outbound RTP/RTCP params. If we did want to add a helper, it'd be some kind of pseudo track that relayed a track and allowed it to be switched.
I will open a PR a bit later with an example for "swapping" tracks, but I think there is no value in RTPSender.ReplaceTrack at the moment because basically we'd need a pseudo track in the sender that is piped and alters RTP stuff.

PR opened at #1166


Unnecessary scrollbar due to 100vw

When the browser has classic scrollbars (e.g., on Windows), your website shows an unnecessary scrollbar. Please take a look at the video below.
This issue is caused by the CSS value 100vw.

The CSS length value 100vw is equal to the width of the <html> element. However, if a classic vertical scrollbar is added to the page, the <html> element becomes narrower (as explained above), but 100vw stays the same. In other words, 100vw is wider than the page when a classic vertical scrollbar is present.

https://css-tricks.com/weekly-platform-news-reduced-motion-cors-whitehouse-gov-popups-and-100vw/#the-css-100vw-value-can-cause-a-useless-horizontal-scrollbar
https://user-images.githubusercontent.com/716405/129596937-0ffa03f3-26b8-4452-a5f0-de5cc0c9e62c.mov

Thanks for reporting this - and apologies for not seeing it sooner. I will fix this now. :)


Minor proposal on line 99

Thank you for the correction! I merged it into the develop branch because it is ahead of the master branch. I hope to be able to update it into the master branch soon.


Beginner Question: How to generate responses programmatically with h2ogpt?

My ideal use case would be to give it a prompt and read the output either through a bash script or a Node.js script. It it possible to do this with h2ogpt? If so, what is a brief example of some code/pseudocode to get started. Do I need to train my own model or does it have a robust model already built out of terabytes of web data like ChatGPT? If it is not like ChatGPT in its robustness, how is it different?
Thank you for having this open source version! Excited to learn more about this use case and start exploring :)

I'm probably not answering your actual question, but let me know!
The repository includes the gradio chatbot and all models are on Huggingface as publicly available.  So once everything is pip installed, just do:
python generate.py --base_model=h2oai/h2ogpt-oig-oasst1-256-6.9b

to get started very quickly.  If one wants to load-unload various models in gradio app, you should just do:
python generate.py

and load in models tab.
===
If one wants to use it as a client, we provide client code that talks to the gradio server:
https://github.com/h2oai/h2ogpt/blob/main/client_test.py
===
If one wants to use it as just a model, then it's like usual on HF with typical usage:
https://huggingface.co/h2oai/h2ogpt-oig-oasst1-256-6.9b#usage

@pseudotensor thanks for the initial response! I am completely new to language models so I don't have the context to know a lot of where to begin.  I don't see how to do that still from your example, and still unclear how this compares in quality/knowledge of ChatGPT.
What does this do, do I pass it a prompt and get a response?
python generate.py --base_model=h2oai/h2ogpt-oig-oasst1-256-6.9b

For example, ChatGPT's API is like this in Node.js:
getResponseAsText().then(text => console.log(text))

async function getResponseAsText() {
  const completion = await openai.createCompletion({
    model: "text-davinci-003",
    prompt: "How are you today?",
  });
  return completion.data.choices[0].text;
}

I can easily make this into a shell/bash script. How can I do the same sort of thing with h2ogpt's python API or CLI?

@this added an OpenAI like API which should satisfy that particular need.  It's still a bit WIP due to some package dependency issues.
Otherwise, the simplest gradio client call would be:
from gradio_client import Client
client = Client(os.getenv('HOST', "http://localhost:7860"))

# string of dict for input
kwargs = dict(instruction_nochat='Who are you?')
res = client.predict(str(dict(kwargs)), api_name='/submit_nochat_api')

# string of dict for output
response = ast.literal_eval(res)['response']
assert 'I am h2oGPT' in response or "I'm h2oGPT" in response or 'I’m h2oGPT' in response

@pseudotensor
What if NO gradio but  just a huggingface server?
Which client is to be adopted??

The text-generation-inference server has a client that we use to talk to it.  That also has a REST API one can curl to.

@pseudotensor
I'm using client.generate_stream. it looks the replied messages are NOT quite accurate ????


F3+F4 Permission Denied.

Hello,
I gave all permissions to default group (LuckPerms) I am sure I am in that group but unfortunately without op, I can't use F3+F4. I see "[DEBUG]: Unable to open game mode switcher; no permission" in the chat.
Should this addon allow gamemode switcher (F3+F4) working based on permissions? If no.. may I ask for it? Is it possible?
Thank you.

When I coded this i didn't think about f3+f4, but I will look into this in the future, for now I'm focusing on my other projects, so this one probably won't receive any update soon.


Installing on vagrant

Linux precise32 3.2.0-23-generic-pae #36-Ubuntu SMP Tue Apr 10 22:19:09 UTC 2012 i686 i686 i386 GNU/Linux
vagrant@precise32:~$ go get github.com/tylertreat/comcast
github.com/tylertreat/comcast/throttler
/usr/lib/go/src/pkg/github.com/tylertreat/comcast/throttler/throttler.go:160: undefined: bufio.NewScanner

What version of Go is this?

go version go1
Note that its Ubuntu.

Yeah, I don't think this will work with versions before 1.3.


Adding to/polishing docs

I originally changed the Annotation traits to a single line to match how the rest of the traits were written, but I changed all of the traits in core.py and annotation.py to match how Annotation's were originally written.

I made updates that cover how to use tab completion for layers.

Also, should we wait to merge these doc edits until the next release? Users would be seeing features that previous release doesn't have. I can also open another PR that adds information about the universe/solar system and individual planet modes.

The solution is to make a stable branch and point the default docs to that, and we can continue to merge changes into master. I'll do that now.

Done - http://pywwt.readthedocs.io/ now points to http://pywwt.readthedocs.io/en/stable/, and to get the latest docs from master you can access http://pywwt.readthedocs.io/en/latest/ manually. So I'll go ahead and merge this :)


error while running train_second.py (caused by size mismatch)

Traceback (most recent call last):
File "/home/jumpcloud/libraries/StyleTTS/train_second.py", line 494, in
main()
File "/home/jumpcloud/miniconda3/envs/work/lib/python3.10/site-packages/click/core.py", line 1157, in call
return self.main(*args, **kwargs)
File "/home/jumpcloud/miniconda3/envs/work/lib/python3.10/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
File "/home/jumpcloud/miniconda3/envs/work/lib/python3.10/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, **ctx.params)
File "/home/jumpcloud/miniconda3/envs/work/lib/python3.10/site-packages/click/core.py", line 783, in invoke
return __callback(*args, **kwargs)
File "/home/jumpcloud/libraries/StyleTTS/train_second.py", line 220, in main
bert_dur = model.bert(texts, attention_mask=(~text_mask).int()).last_hidden_state
File "/home/jumpcloud/miniconda3/envs/work/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1501, in _call_impl
return forward_call(*args, **kwargs)
File "/home/jumpcloud/miniconda3/envs/work/lib/python3.10/site-packages/transformers/models/albert/modeling_albert.py", line 724, in forward
buffered_token_type_ids_expanded = buffered_token_type_ids.expand(batch_size, seq_length)
RuntimeError: The expanded size of the tensor (584) must match the existing size (512) at non-singleton dimension 1.  Target sizes: [12, 584].  Tensor sizes: [1, 512]

Is it a problem in PL-BERT or StyleTTS?

problem is with PL-BERT based styleTTS and the cause of that is if there's any transcription longer than 512 character length, it will throw an error, so fixed my dataset creator accordingly, it works now


⚠ DDoS-Relay US-W-sfo3-03 has degraded performance

In 95b5989, DDoS-Relay US-W-sfo3-03 (http://<IP_ADDRESS>:42069/;csv) experienced degraded performance:

HTTP code: 200
Response time: 35 ms

Resolved: DDoS-Relay US-W-sfo3-03 performance has improved in 5714cad after 9 minutes.


Added a link to RULES.md after printing results

Fixes #53

I could be cool actually if you could link to related rule directly. GitHub generates an anchor tag for each header in markdown files, such as: https://github.com/mivok/markdownlint/blob/master/docs/RULES.md#md001---header-levels-should-only-increment-by-one-level-at-a-time.
If you could rename titles contain rule names only, then you could simply "https://github.com/mivok/markdownlint/blob/master/docs/RULES.md#{rule_name}".
What do you think?

That'd mean you'd need to print the link for each error separately, which I think is a bit overwhelming. IMHO printing the link once and letting the user lookup the rules is a better experience.

Fair enough. :clap:
--
Ali
On Mon, Sep 7, 2015 at 2:36 PM, Alexander Köplinger <
<EMAIL_ADDRESS>wrote:

That'd mean you'd need to print the link for each error separately, which
I think is a bit overwhelming. IMHO printing the link once and letting the
user lookup the rules is a better experience.
—
Reply to this email directly or view it on GitHub
https://github.com/mivok/markdownlint/pull/89#issuecomment-138285744.

@mivok any updates on getting this merged? Happy to close the PR if it's not something you want in markdownlint 😄

I'm reviewing this and will most likely merge. Perhaps in the spirit of this PR, seeing something like
mdl --explain MD033
would be nice too. The rust compiler does this and it's pretty handy.

Thank you ❤
mdl --explain MD033 is a great idea!


[2.3 beta] Utilities list in editor uses old blue highlight

Selected utilities in the page/utility editor list use the old selected colour (blue, no gradient) which looks very different to the new row selection colour and text shadow effect (which is awesome).
http://cl.ly/283A0t0P133W1V003B39

Nick, would you mind posting direct links to your screenshots so that Github displays and caches them? Thanks!

(It doesn't seem like Github can read those URL's, I just tried to update the OP to use Markdown for images)

Fixed in my local branch.


overtouching when re-assigning items into dask_awkward.Array

with awkward>=2.2.0, dask_awkward>=2023.5.1, uproot>=5.0.7
import uproot
import dask_awkward as dak

events = uproot.dask({"https://github.com/CoffeaTeam/coffea/raw/master/tests/samples/nano_dy.root": "Events"})

events["WeightXYZW"] = events.MET_pt**2

print(dak.necessary_columns(events.Muon_pt))

results in:
{'from-uproot-59351be15738a0a09c842e264bf155b9': ['Muon_pt', 'MET_pt']}

I'm still not quite sure why did wasn't causing problems in the more strenuous test until now, but this is definitely an issue.

From playing around at the typetracer level I can't get this to happen, so I think it's in dask_awkward.

Here's the more complex example with data, which requires coffea 2023 and additional latest awkward/dask_awkward/uproot:
complex_repro.zip

maybe just do a bisect? it should be quick: https://github.com/scikit-hep/awkward/compare/v2.2.1...v2.2.2

Indeed:

https://github.com/scikit-hep/awkward/pull/2479 is the offending PR
within that PR it is the following commit: https://github.com/scikit-hep/awkward/pull/2479/commits/19f62aaac1f77c8d8096730f56dead782260d400

@agoose77

These may be separate issues, I just can't get a minimal repro (mostly due to time) for the one that's clearly awkward related.

Applying https://github.com/scikit-hep/awkward/pull/2520 I am able to remove the regression (although column optimization is a good 2 seconds slower in awkward 2.2.2 as well, so there's a big performance regression in there too)

Indeed - these are separate issues.
The dask_awkward specific issue here is that unrelated assigned fields are not being optimized away, which should be possible to do with form rehydration.

This can be closed, as it is expected behaviour.
When loading naively from uproot (without form remapping), uproot gives us an outermost RecordArray containing (in this case) ragged lists. These ragged lists are considered distinct by the column optimisation routine, because they descend from different columns. As such, touching MET_pt.__list__ (as required by with_field), we have to touch MET_pt.
With form remapping, subfields Muon_XXX become Muon.XXX, i.e. fields in the same record array, surrounded by an outer list. This remapping gives sufficient information to dask-awkward to understand that the offsets of MET.xxx are all shared.
Further, if MET and Muon are also contained within their own list-of-record array, then it is possible to indicate that MET.xxx and Muon.yyy share the same offsets too.  This might not be what actually happens in nanoevents, i.e. Muon and MET might be top-level fields in an root RecordArray node, but it's possible for the aforementioned configuration to be the case.
As such, with_field is now behaving as expected, and it is the user side of things that might need some work.

Let me check that columns touching hasn't blown up in the torture test in 2.2.4

Everything is good! Huzzah!


Development: Playwright system health tests

Checklist
General

[x] Language: I followed the guidelines for inclusive, diversity-sensitive, and appreciative language.
[x] I chose a title conforming to the naming conventions for pull requests.

Client

[x] I strictly followed the client coding and design guidelines.
[x] I documented the TypeScript code using JSDoc style.

Motivation and Context
System health tests are missing in Playwright. As a part of migration to Playwright, they need to be migrated from Cypress.
Description
Adds system health tests to Playwright and disables them in Cypress.
Steps for Testing

Code Review: Ensure that tests pass for valid reasons, functionality is adequately tested and check the code quality.
Run the tests (optional): Tests are checked by automatic run in CI environment. You can optionally run them locally and check if they pass.

Steps for running the tests:

Navigate to src/tests/playwright
Configure Playwright using playwright.env file based on your local setup. Current configuration should work for default Artemis setup.
Run npm install && npm run playwright:setup && npx playwright test e2e/SystemHealth.spec.ts
Confirm that "System health" tests pass

Testserver States

[!NOTE]
These badges show the state of the test servers.
Green = Currently available, Red = Currently locked

Review Progress

Code Review

[ ] Code Review 1
[ ] Code Review 2

Manual Tests

[ ] Test 1
[ ] Test 2

Summary by CodeRabbit
Summary by CodeRabbit

Tests

Introduced tests for checking the health status of system components using Playwright.
Temporarily skipped system health check tests in Cypress.
Added a new test script SystemHealth.spec.ts for checking system health indicators on a web page.

Thanks for the changes, @muradium, but the build plan doesn't seem to exist for this branch, so we can't see the impact of the test here. Could you please ensure that the branch gets activated so we can get the results of the playwright tests?


iMessage gifs don't work

After jail breaking with the latest beta 7 the iMessage gifs don't work if I reboot they work but when I rejailbreak the don't work.Please help

https://github.com/kpwn/yalu102/issues/294

This is a duplicate of #294


Update react-loader.jsx

componentWillReceiveProps is no longer supported from react v16.3 .
Replacing it with UNSAFE_componentWillReceiveProps
What does this PR do?
This will replace the componentWillReceiveProps which is no longer supported from react v16.3
Where should the reviewer start?
How should this be manually tested?
I have tested it by manually putting the lines in my code.
Any background context you want to provide?
No .
What are the relevant issues (if any)?
Updating to new react version will throw the error or warning about componentWillReceiveProps component.
Screenshots (if appropriate)
Obligatory GIF

Thanks for the pr! Can you also please run npm run build and commit the .js changes as well?


Feature request: Read-only transactions

PostgreSQL supports read-only transactions.
It would be great if SQLx will be able to use this feature for users to ensure that their code will not accidentally change any rows.

Duplicate of #481


Weird border gap in running cell

Fresh install, default theme, linux (handy dandy notebook)

That is a new feature by design, see https://github.com/microsoft/vscode/issues/141222


Docker build is crash in setp yarn install

🐛 Bug Report
Docker build is crash in setp yarn install
log is :
error An unexpected error occurred: "ENOENT: no such file or directory, lstat '/app/website/node_modules/gifsicle/\u0001\f3@@@�'".

Have you read the Contributing Guidelines on issues?
yes
To Reproduce
If possible, use https://new.docusaurus.io to create a CodeSandbox reproducible demo of the bug.
(Write your steps here:)

use an docker in resperry
run docker build .

Expected behavior
docker build success
Actual Behavior
Docker build is crash in setp yarn install
log is :
error An unexpected error occurred: "ENOENT: no such file or directory, lstat '/app/website/node_modules/gifsicle/\u0001\f3@@@�'".

Your Environment

Public source code: https://cocoadepot.github.io/
Public site url: https://cocoadepot.github.io/
Docusaurus version used:
Environment name and version (e.g. Chrome 78.0.3904.108, Node.js 10.17.0):
Operating system and version (desktop or mobile): ubuntu (resperry)

Hi,
It seems you are using v1 right?
We encourage users to migrate to v2.
This is a problem related to Gifsicle, which apparently is used in v1 to resize gifs. And it seems to fail to install, which is somehow outside the scope of Docusaurus but should rather be reported on Gifsicle repos. What I would try is to use another Docker image, or re-generate my yarn.lock file


android: more detail for test config verify exception

Recently CI started failing the real world verification suite on Android (https://github.com/rustls/rustls-platform-verifier/issues/68). The root cause was the vendored Let's Encrypt end entity certificate expiring. Figuring this out was hard for two main reasons:

CI was eating the Android logs we needed to see the error message. This has since been fixed (https://github.com/rustls/rustls-platform-verifier/pull/72).

The Android verifier was surfacing the expiration as an unknown issuer error with a generic "Chain validation failed" message.

This branch attempts to fix item 2 by surfacing a more relevant error message.
Unfortunately doing so is a little bit annoying. The checkServerTrusted call throws an exception with ~3 layers of wrapping before you get at the CertificateExpiredException that's the root cause.
Since non-test configurations should never have an expired exception thrown at this stage (recall we check this explicitly earlier in processing), we gate the more complicated exception "digging" based on BuildConfig.TEST.
This should be a good balance of:

not changing existing behaviour, or introducing complexity for normal validation
surfacing a better error message when test certificates expire and start to break CI.

Before this fix running the verification test suite back at 6cd02326f1be869b4a6732f262bb04c4958ecf3b before 15d487a9c6e4bf23bc54ac2450d074c10f63eb69 landed would produce output like:
03-12 15:05:38.900 18229 18250 W rustls_platform_verif..: certificate was not trusted: java.security.cert.CertificateException: Chain validation failed
03-12 15:05:38.900 18229 18250 E rustls_platform_verif..: failed to verify TLS certificate: invalid peer certificate: UnknownIssuer
03-12 15:05:38.900 18229 18250 E rustls_platform_verif..: test panic: assertion `left == right` failed
03-12 15:05:38.900 18229 18250 E rustls_platform_verif..:   left: Err(InvalidCertificate(UnknownIssuer))
03-12 15:05:38.900 18229 18250 E rustls_platform_verif..:  right: Ok(())
03-12 15:05:38.901 18229 18248 E rustls_platform_verif..: real world: test failed

Afterwards it logs output like:
03-12 15:06:05.297 18482 18503 E rustls_platform_verif..: failed to verify TLS certificate: invalid peer certificate: Expired
03-12 15:06:05.297 18482 18503 E rustls_platform_verif..: test panic: assertion `left == right` failed
03-12 15:06:05.297 18482 18503 E rustls_platform_verif..:   left: Err(InvalidCertificate(Expired))
03-12 15:06:05.297 18482 18503 E rustls_platform_verif..:  right: Ok(())
03-12 15:06:05.298 18482 18501 E rustls_platform_verif..: real world: test failed

I'm starting to wonder if instead of these gymnastics we should just back out the time argument being fed through to the CertificateVerifier until we work out a broader solution to https://github.com/rustls/rustls-platform-verifier/issues/59. That would let the early checkValidity call surface the better error early on.

I'm starting to wonder if instead of these gymnastics we should just back out the time argument being fed through to the CertificateVerifier until we work out a broader solution to https://github.com/rustls/rustls-platform-verifier/issues/59.

@complexspaces WDYT :point_up: vs this branch? In a perfect world we'd fix #59 instead of doing either but I don't think I'll personally be able to find time to work on that solution and it would be nice to have CI report the correct failure before it happens on April 26th (and every 90d afterwards).

What do you think about just merging this to keep CI nicer and maintain the "good" errors most end users will see?

That works for me :-) If you have a chance to put a review on this branch I'll merge when ready.

Thanks!