Adding messages to history doesn't work with custom message types

System Info
langchain 0.0.320
MacOS 13.14.1
Python 3.9.18
Who can help?
No response
Information

[ ] The official example notebooks/scripts
[X] My own modified scripts

Related Components

[X] LLMs/Chat Models
[ ] Embedding Models
[ ] Prompts / Prompt Templates / Prompt Selectors
[ ] Output Parsers
[ ] Document Loaders
[ ] Vector Stores / Retrievers
[X] Memory
[X] Agents / Agent Executors
[ ] Tools / Toolkits
[ ] Chains
[ ] Callbacks/Tracing
[ ] Async

Reproduction
I'm using DynamoDBChatMessageHistory for storing chat messages. However, I do not use Human or AI as my chat prefixes. Using pre-defined methods add_user_message and add_ai_message won't work for me. I extended the BaseMessage class to create a new message type. I get this error when trying to read messages from history.
 raise ValueError(f"Got unexpected message type: {_type}")
ValueError: Got unexpected message type: User

Here's my code:
import uuid

from typing_extensions import Literal
from langchain.memory.chat_message_histories import DynamoDBChatMessageHistory
from langchain.schema.messages import BaseMessage

class UserMessage(BaseMessage):
    type: Literal["User"] = "User"

class BotMessage(BaseMessage):
    type: Literal["Bot"] = "Bot"

session_id = str(uuid.uuid4())
history = DynamoDBChatMessageHistory(
    table_name="tableName",
    session_id=session_id,
    primary_key_name='sessionId'
)

# history.add_user_message("hi!")  # works fine
# history.add_ai_message("whats up?")  # works fine

history.add_message(UserMessage(content="Hello, I'm the user!"))  # saves the message to the table with the correct message type
history.add_message(BotMessage(content="Hello, I'm the bot!!"))  # doesn't run due to the above-encountered error

print(history.messages)  # throws a ValueError

Expected behavior
The error should not be thrown so that other execution steps are completed.

Ok, the problem is here: https://github.com/langchain-ai/langchain/blob/master/libs/langchain/langchain/schema/messages.py#L388


List of Compliance Ready Policies for AWS page lacks formatting

What happened?
The page that lists the details on Compliance Ready Policies for each cloud provider has formatting that is not suitable for API docs.
https://www.pulumi.com/docs/using-pulumi/crossguard/compliance-ready-policies-aws/

Example
n/a
Output of pulumi about
n/a
Additional context
No response
Contributing
Vote on this issue by adding a 👍 reaction.
To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).

@jkodroff could you please clarify as your issue description lack details. Could you please provide an example and some code changes that would address the situation?


[TEVA-2007] Set explicit 10s healthcheck timeout for CF apps

Jira ticket URL
https://dfedigital.atlassian.net/browse/TEVA-2077
Changes in this PR:

Set web and worker app healthcheck to 10s

Review app deployed to https://teaching-vacancies-review-pr-2927.london.cloudapps.digital

As discussed, this fails as the app may take longer than 10s to start. It was suggested by paas support to set it explicitly to 60s.


React 15+

You have done a great job with this component! Any plans to support React 15 and above? Thank you.

Hi, thanks a lot! Thanks for the request. I've created a new release to support React 15.

Excellent! Thank you very much


Needs a license

This looks great, but few people are going to make use of it without an MIT license. Keep of the good work!

Thank you so much for messaging!
I looked and noticed I have "license": "MIT",.
Where did you see there's no license?

Oh I should have checked the package.json file. I'm personally in the habit of checking Git Repos to evaluate a new package before installing it. Typically, a GitHub repo will have a LICENSE file in the root and GitHub will detect it and show MIT or whatever on the right-hand side. E.g.

Fixed!


.env file support

Hello,
IMHO .env file is a nice thing to have for such a project. It provides:

Painless clustering for isolated environments e.g. Docker
In-place support on cloud platforms
More naturalness for other developers

Caveat? The config.json file would be deleted and modules requiring env. variables should the variables, but we can export the whole env. variable as a single object to maximize the code re-use.
What does this need?

Delete package.json file
Setup .env variables (with a small .env.example)
Update README.md

I can work on this and send a PR if you're interested in the issue.

? not wanted?

Sorry, I reopened it. Pull request is welcome. Later can see how it goes.


Fix jsdoc for docgenerator

remove type annotation.
replace dataset.forEach(e => console.log(e)) with console.log(JSON.stringify(await dataset.collectAll())) because console.log in callback does not work in tfjs-website.

This change is

Our hijacked console.log just sets the innerText of the div to be the value passed to console.log, which prints something like [object Object].
We could make console.log smarter on our end.
Filed https://github.com/tensorflow/tfjs/issues/956


Create SECURITY.md

Hi, thanks for this awesome tool!
could you provide a Security policy and also it would be great if you enable the security report dashboard in here in github.  thanks!

Thanks, I've enabled security reporting. Only the latest version will receive updates, and you can report security problems via the security reporting mechanism for via the issue tracker.


Add >required< statements to requestBodies/responseBodies where missing

required statements should be included in the bodies, with exception of the callbacks.

Is to be checked, whether the required: statements are actually missing.
Searching shall be limited to service paths (but not resource paths).


titleTemplate: titleChunk is undefined in og:title and ogTitle has no effect in useServerSeoMeta

Describe the bug
When providing a titleTemplate in app.vue, it appears that titleChunk is undefined when generating the og:title meta tag.
I tried to override og:title by setting ogTitle in useServerSeoMeta, and it has no effect on the og:title tag. If I remove the titleTemplate from app.vue, ogTitle works as expected.
Reproduction
To come. I will update this issue.
System / Nuxt Info
"@nuxtjs/seo": "2.0.0-rc.21",
    "nuxt": "^3.13.1",

  System:
    OS: macOS 14.7.1
    CPU: (12) arm64 Apple M2 Pro
    Memory: 659.48 MB / 32.00 GB
    Shell: 5.9 - /bin/zsh
  Binaries:
    Node: 20.15.1 - ~/.nvm/versions/node/v20.15.1/bin/node
    npm: 10.7.0 - ~/.nvm/versions/node/v20.15.1/bin/npm
    pnpm: 9.5.0 - /opt/homebrew/bin/pnpm
  Browsers:
    Chrome: 131.0.6778.70
    Edge: 131.0.2903.51
    Safari: 18.1

Hi, I'd recommend using a string titleTemplate over a function, please see this guide for working with titles like this: https://nuxtseo.com/learn/mastering-meta/titles#social-share-titles-in-vue
If you still have issues then please provide a reproduction and I'll re-open and take a look.


Fix sub-model link in usage/models docs

Change Summary
There is a broken link in Error Handling section of models doc.

Related issue number

Checklist

[ ] Unit tests for the changes exist
[ ] Tests pass on CI and coverage remains at 100%
[x] Documentation reflects the changes where applicable
[ ] changes/<pull request or issue id>-<github username>.md file added describing change
(see changes/README.md for details)
[x] My PR is ready to review, please add a comment including the phrase "please review" to assign reviewers

please review

thanks so much.


Resolves #2212 Add ApplyMigrationsAsync (and related async methods)

Add ApplyMigrationsAsync method to IMigrator interface and implement it.
Add extension to call this method throw RelationalDatabaseFacadeExtensions.

Hi @laskoviymishka, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!
The agreement was validated by .NET Foundation and real humans are currently evaluating your PR.
TTYL, DNFBOT;

Add ExistsAsync and GetAppliedMigrationsAsync methods in history repository interface and implement it.
Reimplement ApplyMigrationsAsync in async way.

Hey,
Having two code paths is the right thing to do here but at the moment there is a large amount of duplicated code that is not async. We would like to see this refactored so that the duplicated logic between the async/sync code paths is mostly just the parts that are actually async. What we are after is factoring out the code that does not change into helper methods etc. so that we don't have two copies of it.
~Rowan

Hi,
I Refactored migrator and history repositories. Extract shared code to helper methods.
Best regards,
Andrei Tserakhau

Fix merge conflicts.

Hi, @laskoviymishka, I apologize for the delay in processing this. There has been a lot of churn in Migrations recently. Would you mind updating on top of the latest changes?

Hi, @bricelam sure. I update it and notify you when it will be completed. Sorry from my side also :sweat_smile:  was pretty busy.

Hi @laskoviymishka, I'm your friendly neighborhood .NET Foundation Pull Request Bot (You can call me DNFBOT). Thanks for your contribution!
You've already signed the contribution license agreement. Thanks!
The agreement was validated by .NET Foundation and real humans are currently evaluating your PR.
TTYL, DNFBOT;

Hi, @bricelam code was synced with latest changes. Could you please review it. I accidentally close PR  :), but reopen it again.

Yikes: 301 changed files with 23,100 additions. I think something went wrong with the update...

Hm. Something goes wrong. Definitely.
Maybe i should create new PR

A new PR would be fine.

@bricelam Sorry again, my bad :cry: . Create new PR #3059 could you please review it? (it only 6 changed files with 253 additions and 73 deletions :+1: ).


Didn't find the information I was looking for

I was looking for the exact location of the data centre shown in our Exchange Online profile as "Asia Pacific". Instead, I ended in circles between pages to not found the information I need.

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

ID: 61c6fa7b-7e9e-21a5-40da-adbd35040ec1
Version Independent ID: 530df3b2-2048-8351-2f09-59e604aedf5b
Content: Microsoft 365 data locations - Microsoft 365 Enterprise
Content Source: microsoft-365/enterprise/o365-data-locations.md
Service: microsoft-365-enterprise
GitHub Login: @kelleyvice-msft
Microsoft Alias: kvice

@kelleyvice-msft Please help us in resolving this issue. Thanks

To make it easier for you to submit feedback on articles on learn.microsoft.com, we're transitioning our feedback system from GitHub Issues to a new experience.
As part of the transition, this GitHub Issue will be moved to a private repository. We're moving Issues to another repository so we can continue working on Issues that were open at the time of the transition. When this Issue is moved, you'll no longer be able to access it.
If you want to provide additional information before this Issue is moved, please update this Issue before December 15th, 2023.
With the new experience, you no longer need to sign in to GitHub to enter and submit your feedback. Instead, you can choose directly on each article's page whether the article was helpful. Then you can then choose one or more reasons for your feedback and optionally provide additional context before you select Submit.
Here's what the new experience looks like.
Note: The new experience is being rolled out across learn.microsoft.com in phases. If you don't see the new experience on an article, please check back later.
First, select whether the article was helpful:

Then, choose at least one reason for your feedback and optionally provide additional details about your feedback:

Article was helpful
Article was unhelpful

Finally, select Submit and you're done!


remove cstruct dependency, use mirage-crypto and tls 1.0.0+

requires https://github.com/ocaml/opam-repository/pull/26768

otr is released, merging.


Inhomogeneous shape error in Face Analysis node - Requesting assistance with resolving array shape inconsistency

When processing, I get the following error message:
!!! Exception during processing!!! setting an array element with a sequence. The requested array has an inhomogeneous shape after 1 dimensions. The detected shape was (4,) + inhomogeneous part.
I can provide further details if required, I would greatly appreciate any assistance in resolving this issue.

I need to see the workflow and every reference images

The issue produces a variation of the error with different workflows so I included both.
https://github.com/cubiq/ComfyUI_FaceAnalysis/issues/8#issuecomment-2132481583

Hello, have you resolved this issue? I have also encountered the same problem and have upgraded the nodes and versions used to the latest version

can you try to update to the latest version I pushed few minutes ago?

unfortunately I cannot replicate, the provided workflows work as intended for me.
I need the full error backtrace and info about your environment (the initial comfyui message should suffice)

I didn't think it was going to be easy to replicate. The only real differences were the input images as snapshots of your video, the workflows are yours.

can you try to update to the latest version I pushed few minutes ago?

Whatever you done to that new code of yours has fixed my problem, it's working! YAY!
I actually spent the last 20 hours or so studying tensor shapes with Ollama LLM chat,  learning as much as I could to try to understand that part of your code. I learnt I have much to learn!


Parser error when have multi line comment after data table.

Feature: Using calculator to calculate total addition, multiplication of list number

  This feature used to do addition and multiplication for all numbers in the list.
  In this test we just test for integer numbers.

  Background:
    Given I have list of number
      |12|
      |3 |
      |45|
      |2 |

    # This scenario for addition operation

    """
    This feature used to do addition and multiplication for all numbers in the list.
    In this test we just test for integer numbers.
    """
  Scenario: Add all number in list
    When I add all number in list
    Then the result after adding all number in list should be 62

    # This scenario for multiplication operation
  Scenario: Multiply all number in list
    When I multiply all number in list
    Then the result after multiplying all number in list should be 3240

Throws exception when parse this feature with above content.

Did you expect both the data table and the doc string to be passed as arguments to the background step?

@aslakhellesoy No, I did not. I just does not want to have an exception when parsing this feature.
Here is the exception.
gherkin.ParserException$CompositeParserException: Parser errors:
(13:5): expected: #EOF, #TableRow, #StepLine, #TagLine, #ScenarioLine, #ScenarioOutlineLine, #Comment, #Empty, got '"""'
(14:5): expected: #EOF, #TableRow, #StepLine, #TagLine, #ScenarioLine, #ScenarioOutlineLine, #Comment, #Empty, got 'This feature used to do addition and multiplication for all numbers in the list.'
(15:5): expected: #EOF, #TableRow, #StepLine, #TagLine, #ScenarioLine, #ScenarioOutlineLine, #Comment, #Empty, got 'In this test we just test for integer numbers.'
(16:5): expected: #EOF, #TableRow, #StepLine, #TagLine, #ScenarioLine, #ScenarioOutlineLine, #Comment, #Empty, got '"""'
	at gherkin.Parser.parse(Parser.java:148)
	at gherkin.Parser.parse(Parser.java:115)
	at gherkin.Parser.parse(Parser.java:111)
	at gherkin.Parser.parse(Parser.java:107)

Why do you have a DocString underneath the table? It looks like you're using it like a comment?

Yup, it's just a comment.

You can't use DocStrings and comments. You have to use # for comments.

Got this message too and I don't even know what DocStrings is.  I just use # for comments.  Why is Selenium complaining about a file that shouldn't even be called by the Cucumber script I am running?

@DougMaisells rather than commenting on a closed issue, please create a new one, and make sure you provide us with a Gherkin document that will allow us to reproduce the issue.
Please mark it up in the issue using triple backticks - like so:

```gherkin
Feature: bla bla
```

Sorry, I did not see the issue was closed nor do I know your process tracking mechanism or process.  A co-worker sent me the issue to try and resolve my issue but as usual with internet help, when I read the response, the help is of no help.  I opened a new ticket.
<EMAIL_ADDRESS>[email-Sig_peak2]
From: Aslak Hellesøy <notifications<EMAIL_ADDRESS>Reply-To: cucumber/gherkin <reply<EMAIL_ADDRESS>Date: Friday, August 26, 2016 at 3:15 AM
To: cucumber/gherkin <gherkin<EMAIL_ADDRESS>Cc: Douglas Maisells <Douglas.Maisells<EMAIL_ADDRESS>Mention <mention<EMAIL_ADDRESS>Subject: Re: [cucumber/gherkin] Parser error when have multi line comment after data table. (#106)
@DougMaisellshttps://github.com/DougMaisells rather than commenting on a closed issue, please create a new one, and make sure you provide us with a Gherkin document that will allow us to reproduce the issue.
Please mark it up in the issue using triple backticks - like so:
Feature: bla bla

You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHubhttps://github.com/cucumber/gherkin/issues/106#issuecomment-242675847, or mute the threadhttps://github.com/notifications/unsubscribe-auth/ALgvtP0jsBA3Qli4YlxwR-kwraakmBC2ks5qjq6bgaJpZM4GKfsa.

is a solution worked for you ? I have the same problem can you help me ? thanks

@Skhoshhal The solution is to mark comment lines with a #. This is the only valid way to identify a comment in Gherkin.


Add: +refactor: multi-grid - grids with different sizes of cells

This seems to put to much load on NARS even for this simple scene - closed because I got a better idea


add err checks; fix deref null ptrs, mem boundary/leak issues, etc.

mostly fix luxonis/XLink#35

found with msvc code analysis
one open concern about bulk_chunklen var as described in linked issue

Is there a way for CI to build and test XLink PRs? I don't have the harness to test the linux variations.
Meanwhile, I'll work on the bulk_chunklen changes.

I've started the CI - will lift this for next PRs for XLink


Fix several issues when using the library in Laravel

This PR addresses numerous issues with the library:

The documentation for the Cookie and Cache objects indicates that they are interfaces, when in fact they implementations. The converts them to interfaces and builds out separate implementations for them.
Removes a number of ?> tags per PSR-2 2.2
Create a class for launch-related constants and removes magic strings.
Fixes several issues with LTI_Launch_message::validate_jwt_signature() to allow these failures to be properly handled per the LTI 1.3 certification process (specifically, no kid specified, and expired jwt token)
Throws an exception when no Deployment ID is specified
Exposes the cookie prefix so the cookie can be referenced outside of the context of this library without using magic strings

This PR is dependent on EricTendian's PR: https://github.com/IMSGlobal/lti-1-3-php-library/pull/44

@MartinLenord do you have any feedback on these changes?

@MartinLenord I finally got some time to go back and implement the feedback. Let me know if you have any additional comments.
Also, can we get this repo added to packagist? It makes me a little nervous that our composer.json is just pointing to the master branch. As it stands, anyone could push breaking changes to master and we'd have no idea and no easy way to lock it down to a specific version.

@dbhynds - IMS will discuss the possible movement of a point-in-time copy of the master to a repo site. Martin L can't do that on his own - that must be a change from IMS Global.
However, you worries are real and we will look into it. If IMS doesn't want to (for some technical reason unknown to me) use pakagist or some other repo site, could we do Releases here in Github? Would your php composer suite be able to query and use named/numbered Releases?
-Dereck

@mumitr0ll Thanks for sharing that context. Github releases would be an acceptable fallback if the packagist option doesn't work out.

Any update on the merge? I will be using this branch instead of the official one.

Hi, any updates on this? Would be nice to have it merged, if possible. Thanks!

Hi, any updates on this? Would be nice to have it merged, if possible. Thanks!

Thanks for those who have asked. Yesterday, I actually released a large refactor to this library (based on this fork) to Packagist: https://packagist.org/packages/packbackbooks/lti-1p3-tool. We're still doing final testing on it to ensure it's stable, but should be releasing 1.0 of the package early next week. There are some considerable changes as part of the upgrade (most classes and methods got renamed). However, if you want to start using the new package, do:
composer require packbackbooks/lti-1p3-tool

Thanks for the interest.

Thanks for those who have asked. Yesterday, I actually released a large refactor to this library (based on this fork) to Packagist: https://packagist.org/packages/packbackbooks/lti-1p3-tool. We're still doing final testing on it to ensure it's stable, but should be releasing 1.0 of the package early next week. There are some considerable changes as part of the upgrade (most classes and methods got renamed). However, if you want to start using the new package, do:
composer require packbackbooks/lti-1p3-tool

Thanks for the interest.


AES 256 output is inverted

I've been using this project to send encrypted messages over Bluetooth to a peripheral device.  The encryption part works well and the device understands me and sends replies back.
However, I've just decrypted my first message and after a bit of head scratching I noticed that if I invert the bytes of the output, I get the expected message.  I am using AES 256 in CBC mode.
Has anyone else seen this behavior? Thanks

Hi @esimunds and thanks for your interest
First let me note that this project has been tested thoroughly and against official "golden vectors", meaning input + output pairs which have been certified by NIST. I find it highly unlikely that an error in this project is causing you problems.
What you are describing sounds more like a case of "misuse" where you are doing something wrong or unintended.
Opening an issue here is not a very good way to get help with usage-related problems - I suggest you open a question on stackoverflow.com instead.
If you can post the code you are using on both sides here, maybe I can take a look and try and see if I can spot the error :)
You mention that you exchange data with a peripheral unit via Bluetooth - I would expect the errors to be contained in that part of the code.

Hi @esimunds and thanks for your interest
First let me note that this project has been tested thoroughly and against official "golden vectors", meaning input + output pairs which have been certified by NIST. I find it highly unlikely that an error in this project is causing you problems.
What you are describing sounds more like a case of "misuse" where you are doing something wrong or unintended.
Opening an issue here is not a very good way to get help with usage-related problems - I suggest you open a question on stackoverflow.com instead.
If you can post the code you are using on both sides here, maybe I can take a look and try and see if I can spot the error :)
You mention that you exchange data with a peripheral unit via Bluetooth - I would expect the errors to be contained in that part of the code.

I figured it was some sort of user error on my part, I just thought maybe someone else had made the same mistakes and could help out.  It turns out I hadn't zeroed out the IV when starting the decryption and it caused the decrypted response message to look quite similar to the inverse of what I expected, when in reality it wasn't a perfect inversion and I was just getting lucky to get somewhat close, if that makes sense.
So "misuse" is definitely the cause and I have sorted it out.  Probably should have done a bit more testing before posting here.

I figured it was some sort of user error on my part, I just thought maybe someone else had made the same mistakes and could help out.  It turns out I hadn't zeroed out the IV when starting the decryption and it caused the decrypted response message to look quite similar to the inverse of what I expected, when in reality it wasn't a perfect inversion and I was just getting lucky to get somewhat close, if that makes sense.
So "misuse" is definitely the cause and I have sorted it out.  Probably should have done a bit more testing before posting here.

@esimunds no problem at all - glad you got it working :)
I am working on a FAQ and some sort of implementation-guide. +90% of all issues here are asking for help on how to use the library correctly, or have problems because they aren't.
The focus on small size means there is less hand-holding and fewer meaningful error messages to guide you.
That makes the library less user-friendly than it could be with better documentation...

@esimunds no problem at all - glad you got it working :)
I am working on a FAQ and some sort of implementation-guide. +90% of all issues here are asking for help on how to use the library correctly, or have problems because they aren't.
The focus on small size means there is less hand-holding and fewer meaningful error messages to guide you.
That makes the library less user-friendly than it could be with better documentation...


Add license section to README.

Add license section to README.
Update GitHub Action dependency versions.
Upgrade devDependencies; Add engines.node.

Codecov Report

Merging #10 (47f90d1) into main (9396b7b) will not change coverage.
The diff coverage is n/a.

Additional details and impacted files
@@           Coverage Diff           @@
##             main      #10   +/-   ##
=======================================
  Coverage   95.85%   95.85%
=======================================
  Files           3        3
  Lines         193      193
=======================================
  Hits          185      185
  Misses          8        8

Continue to review full report in Codecov by Sentry.

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


feat(STONE-855): making alerts less sensitive

Increasing alert for value to make trigering of alerts less sensitive.

I think these changes will also require updates to unit tests at https://github.com/redhat-appstudio/o11y/tree/main/test/promql/tests/data_plane

@mmorhun
https://github.com/redhat-appstudio/o11y/blob/main/rhobs/alerting/data_plane/prometheus.latency_pac_provision_alerts.yaml
Could be running into same troubles as other two mentioned alerts, do you want me to update it also?

@jsztuka we haven't experienced problems so far with PaC metrics, but I think we can increase the value, because 1 minute looks too sensetive


Revert "Emit event for contract registration (#1518)"

This reverts commit e2440de8baf19467f1136c1fda7e60a8a21a3cfb.
Describe your changes and provide context
Testing performed to validate your change

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

Project coverage is 60.16%. Comparing base (e2440de) to head (9cc5a09).

Additional details and impacted files

@@            Coverage Diff             @@
##            seiv2    #1528      +/-   ##
==========================================
- Coverage   60.21%   60.16%   -0.05%
==========================================
  Files         363      363
  Lines       25797    25765      -32
==========================================
- Hits        15533    15501      -32
+ Misses       9277     9275       -2
- Partials      987      989       +2

Files
Coverage Δ

precompiles/pointer/pointer.go
32.62% <ø> (-0.05%)
:arrow_down:

x/evm/gov.go
100.00% <ø> (ø)

x/evm/keeper/msg_server.go
77.27% <ø> (-0.73%)
:arrow_down:

... and 2 files with indirect coverage changes


joinVoiceChannel: Error: could not resolve channel

Hi, I have a problem when trying to play sound using discord.js
Actually it works perfect, but after some time or after a user has played some sounds, it stops working.
Suddenly it wont play any sound (neither playFile nor playRawStrean) and the user who can't play sounds must leave the voice channel and rejoin.
This is the error:
http://i.imgur.com/ogHYUtg.png
vChannel is get from a client.on("message, ... as: message.sender.voiceChannel
mybot.joinVoiceChannel( vChannel , (error,connection) => {
    if (error){
        console.log("Error joining",error);
        //return; // I tried with and without return
    }
    if (youUrl)
        connection.playRawStream(youstream, play);
    else
        connection.playFile('./sonidos/' + fileName, options, play);
});
function play(error, connection){
    if( error ){
        console.log("Error play",error);
        return;
    }
    connection.on('error'   , (error)  => { console.log(error); youstream.destroy(); programVoiceLeave(true);    });
    connection.on('end'     , ()       => { programVoiceLeave();        });
}

I tried testing many things but I can't get the root cause of the problem. I am using the #16 indev branch right now.

you may want to consider an else if on the line with if (youURL). If their's an error connecting to the voice Channel it will probably fail to play music in it.

You're using the #16 Indev branch?
Can you use either stable npm i --save discord.js or the latest indev ? npm install hydrabolt/discord.js#indev

@macdja38 I think that is not the problem because it works even when youURL has no way to result true.
@GexoXYZ I tried latest indev by reinstalling and cleaning.
Same problem, after some time, one user looses the ability to play sounds and must rejoin voice channel.

Sounds like it's related to what's happening in #360 but not just on bot start when there's no cache(?)

Apparently voiceLeave will sometimes give an undefined channel, don't see how this could happen though? (When a user leaves a channel and doesn't join a new one)
	eventVoiceLeave(user) {
		for (let chan of this.channels.getAll("type", "voice")) {
			if (chan.members.has(user)) {
				chan.members.remove(user);
				user.voiceChannel = null;
				return chan;
			}
		}
		return {server: this};
	}

Here's what I do at the moment to get around this issue seems to work most of the time, though it isn't foolproof.
`function resolveVoiceChannel(user, server) {
if (user.voiceChannel) {
return user.voiceChannel;
}
else {
var voiceChannels = server.channels.filter((channel) => { return channel.type === "voice"; });
	for (var v = 0; v < voiceChannels.length; v++) {
		var voiceChannel = voiceChannels[v];

		if (voiceChannel.members.has("id", user.id))
			return voiceChannel;
	}

	return null; // not found
}

}`

@Programmix Thanks for sharing. Although, as you say, it won't help always, I still need to rejoin voice channel some times.

I'm gonna be testing another (shitty) solution. It is just an idea, and should be perfectioned for multi-server bots, and even per user 'lastChannel' but it might be useful for some one reading this before we get to a fix.
var lastChannel = null;
function resolveVoiceChannel(user, server) {

    if ( user.voiceChannel ) {
        return user.voiceChannel;
    }
    server.channels
        .filter(  (channel) => {
            return channel.type === 'voice';
        } )
        .forEach( (channel) => {
            if ( channel.members.has('id', user.id) )
                lastChannel = channel;
        } );
    return lastChannel;

}

I have not tested it yet, will do it soon.

Fixed with https://github.com/hydrabolt/discord.js/commit/f49f1ab3c8d0354e5021d7ff8eb721196e96020f :eyes:

Good, thanks

Fixed in 9.0.2


Added Bouncing Loader

Fixes Issue🛠

Closes #
Description👨💻
Added "BOUNCING-LOADER" folder with index.html and style.css for implementing a bouncing loader animation.
Type of Change📄

[ ] Bug fix (non-breaking change which fixes a bug)
[x] New feature (non-breaking change which adds functionality)
[ ] Style (non-breaking change which improves website style or formatting)
[ ] Documentation (non-breaking change which updates or adds documentation)
[ ] Responsiveness (non-breaking change which improves UI/UX on different screen sizes)

Checklist✅

[ ] I am an Open Source contributor
[x] I have performed a self-review of my code
[ ] My code follows the style guidelines of this project
[x] I have commented on my code, particularly in hard-to-understand areas

Screenshots/GIF📷

Which issue are you assigned to @ShagunSharma17


24 Oct 2023 - InnerSource SIG Meeting Minutes

Date
Tuesday 24 OCT 2023 - 3:00pm EST / 10:00am UK
Untracked attendees

Fullname, Affiliation, (optional) GitHub username
...

Meeting notices

FINOS SIG Leads are responsible for observing the FINOS guidelines for running project meetings. Project maintainers can find additional resources in the FINOS Maintainers Cheatsheet.

All participants in FINOS project meetings are subject to the LF Antitrust Policy, the FINOS Community Code of Conduct and all other FINOS policies.

FINOS meetings involve participation by industry competitors, and it is the intention of FINOS and the Linux Foundation to conduct all of its activities in accordance with applicable antitrust and competition laws. It is therefore extremely important that attendees adhere to meeting agendas, and be aware of, and not participate in, any activities that are prohibited under applicable US state, federal or foreign antitrust and competition laws. Please contact<EMAIL_ADDRESS>with any questions.

FINOS SIG meetings may be recorded for use solely by the FINOS team for administration purposes. In very limited instances, and with explicit approval, recordings may be made more widely available.

Agenda

[ ] Convene & roll call (5mins)
[ ] Display FINOS Antitrust Policy summary slide
[ ] Review Meeting Notices (see above)
[ ] Approve past meeting minutes
[ ] Review FINOS Slack InnerSource SIG Channel - https://finos-lf.slack.com/archives/C01SYB503QT
[ ] Working session on License Generator
[ ] Working session on InnerSource portal
[ ] ...
[ ] AOB, Q&A & Adjourn (5mins)

Decisions Made

[ ] Decision 1
[ ] Decision 2
[ ] ...

Action Items

[ ] Action 1
[ ] Action 2
[ ] ...

Zoom Details

https://zoom.us/j/94949043746?pwd=WnBFQjhpUnBjMWE0OUhqUGhhb0ZOdz09
Meeting ID: 949 4904 3746
Passcode: 067897

Join by phone
Find your local number: https://zoom.us/u/adJnH9JOiY
Mailing List
Email<EMAIL_ADDRESS>to subscribe to the InnerSource SIG
mailing list.

Rob / FINOS 👾

:wave Cham from Citi

Peter Smulovics / Morgan Stanley 🏢

Gabriel Simon

Some minutes from me:
InnerSourceCommons Events: Discussed the upcoming events and whether they could be added to a FINOS blog.
License Generator: Cham showing progress, looking for help from Python developers.  Interested in integrating with Backstage.
Should we track people using the tool?
Hosting from FINOS was discussed, and the legal implications of providing licenses - would users of the tool need to accept an EULA?
PRs and Maintainers: We had some discussion around this and updated the maintainer list to reflect the currently active members of the group.
Breakout Events after OSFF:  One is being held at Morgan Stanley on 2nd November.  Everyone invited to attend.  InnerSourceCommons also planning something to coincide.  Rob & Russell to amplify.


Create a new SDK or development tool facilitating integration of Keycard

Title: Create a new SDK or development tool facilitating integration of Keycard
About Keycard: Keycard is an open framework for smartcards in the crypto sphere. Smartcards are cost-effective, highly secure hardware, that can generate & store private keys, sign transactions with a tap on a mobile (android sdk available), or with a desktop (with a usb reader).
Keycard can be used as a easy-to-use and mobile friendly hardware wallet, bringing security and ownership over their keys to end users. Its form factor, tangibility and cost effectiveness can also be leveraged as an adoption tool, to bring new comers to decentralized services.

Keycard has an Android SDK & Go SDK.
Keycard is integrated with geth.

Challenge description: Create a new SDK or development tool facilitating integration of Keycard in various environments.
Developer Guide: Full documentation and links to repos can be found here
https://status.im/keycard_api/
How to get a Keycard:
If you want to hack with Keycard, get in touch with us on https://get.status.im/chat/public/status-keycard, let us know what you plan to build, and we will send you a keycard!
Prize: 1,500 DAI

Just wondering what use-cases you see for such an SDK

I don't understand. Do you want to port this library to, say, iOS?

@rasom


Update add-a-billing-api.md

bililng.js doesn't yet exist (at least didn't for me), if that's correct then the language should be similar to other chapters & explicitly suggest that we create it.
Cheers <3

Thanks!


Companies add topic

Does not fulfill requirements and changes were not made on time

Does not fulfill requirements and changes were not made on time


Determine latest versions for tools not hosted on GitHub

Determine latest versions for tools not hosted on GitHub
Expected Behaviour

To lighten the load, kubectl and the various HashiCorp tools which are not hosted on GitHub, could determine their latest (stable, not pre-release) versions for download.
Current Behaviour

We hard code a few of these, but GitHub uses auto-determination through the releases HTTP endpoint.
Possible Solution

Do HashiCorp provide an API or HTTP endpoint for this? Or a static file somewhere?
For kubectl, Google provide one: i.e. curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl"
Steps to Reproduce (for bugs)

Remove the version for one of these tools
Run arkade get
See it pull in the latest stable version, and not a pre-release or alpha

Neither Kuma (#571 #572) provide GitHub releases.
But it also has an endpoint for it: https://kuma.io/latest_version.
Should we introduce a new field in the Tool struct for example VersionURL, if provided and Version is not, then fetch the provided URL and use the response as the version string?

After some research, I was yet to find any HashiCorp related release version urls, every available script that trying to achive the same goal was parsing their GitHub releases.
So basically something like this should work:
curl https://api.github.com/repos/hashicorp/terraform/releases/latest | jq .tag_name | sed 's/^.//;s/.$//

That is looking very promising. For the version checking we are better to use the HTTP HTML endpoint than the JSON API request since it's not rate-limited.
Can you suggest how you would like to handle this at runtime, so we don't need to pin a version?

I am thinking on a duck-tape way, why don't we write an HTTP endpoint (an OpenFaaS function for example) which returns it like kubectl's or kuma's end point?

This might be a good idea:
https://github.com/alexellis/arkade/issues/574#issuecomment-961342358_
Or this one:
https://github.com/alexellis/arkade/pull/574#issuecomment-961340135
(Just to keep these ideas one place.)

What do you think about changing the Version field from a string to a function returns a string? Then, each tool can be implemented according to its requirements.
https://github.com/alexellis/arkade/blob/19077193030259be439587b2686b0d4530ced248/pkg/get/get.go#L35-L37
Current code would be transformed to the following schema (so nothing would be affected)
			Version:     func() string {return "1.6.13"},

more complex scenarios could be like this
			Version: func() string {
				resp, err := http.Get("https://kuma.io/latest_version")
				if err != nil {
					return ""
				}
				body, err := ioutil.ReadAll(resp.Body)
				if err != nil {
					return ""
				}
				return string(body)
			},

or even with an error returned for better error handling
			Version:     func() (string, error) {return "1.6.13", nil},
...
			Version: func() (string, error) {
				resp, err := http.Get("https://kuma.io/latest_version")
				if err != nil {
					return "", errors.Wrapf(err, "Failed to get kuma website")
				}
				body, err := ioutil.ReadAll(resp.Body)
				if err != nil {
					return "", errors.Wrapf(err, "Failed to read response")
				}
				return string(body), nil
			},

What do you think about changing the Version field from a string to a function returns a string? Then, each tool can be implemented according to its requirements.
https://github.com/alexellis/arkade/blob/19077193030259be439587b2686b0d4530ced248/pkg/get/get.go#L35-L37
Current code would be transformed to the following schema (so nothing would be affected)

			Version:     func() string {return "1.6.13"},

more complex scenarios could be like this

			Version: func() string {

				resp, err := http.Get("https://kuma.io/latest_version")

				if err != nil {

					return ""

				}

				body, err := ioutil.ReadAll(resp.Body)

				if err != nil {

					return ""

				}

				return string(body)

			},

or even with an error returned for better error handling

			Version:     func() (string, error) {return "1.6.13", nil},

...

			Version: func() (string, error) {

				resp, err := http.Get("https://kuma.io/latest_version")

				if err != nil {

					return "", errors.Wrapf(err, "Failed to get kuma website")

				}

				body, err := ioutil.ReadAll(resp.Body)

				if err != nil {

					return "", errors.Wrapf(err, "Failed to read response")

				}

				return string(body), nil

			},

Such a great idea! @alexellis what do you think?

Let me get back to you on this. Thanks for looking into it

Hi @YuviGold
Changing Version from a string to function would involve a massive refactor. I think we could probably add a separate field with a different name like: VersionSource
When empty, VersionSource would default to the current behaviour. If a string was given, i.e. kuma hashicorp then we'd determine what code to run (some custom lookup function) and return the version.
Wherever Version is used, would need to be updated to read from the specific version lookup function.

Hi @YuviGold
Changing Version from a string to function would involve a massive refactor. I think we could probably add a separate field with a different name like: VersionSource
When empty, VersionSource would default to the current behaviour. If a string was given, i.e. kuma hashicorp then we'd determine what code to run (some custom lookup function) and return the version.
Wherever Version is used, would need to be updated to read from the specific version lookup function.

This approach creates a bit more complexity(conditions) and misses the flexibility of the former. For example, if one source would return a JSON instead of a raw data.
That being said, I agree that refactoring the function is a bit more tedious but not much. As long as there is no other package that uses this API as a library. Please correct me if I'm wrong.
Anyway, both implementations sound good to me :)

Hi @YuviGold
Changing Version from a string to function would involve a massive refactor. I think we could probably add a separate field with a different name like: VersionSource
When empty, VersionSource would default to the current behaviour. If a string was given, i.e. kuma hashicorp then we'd determine what code to run (some custom lookup function) and return the version.
Wherever Version is used, would need to be updated to read from the specific version lookup function.

This approach creates a bit more complexity(conditions) and misses the flexibility of the former. For example, if one source would return a JSON, or some other response, instead of a raw data. That being said, I agree that refactoring the function is a bit more tedious but not much. As long as there is no other package that uses this API as a library. Please correct me if I'm wrong.
Anyway, both implementations sound good to me :)

I think, the version that @alexellis recommends, can be introduced without any code change on the arkade/pkg/get/tools.go  side, which is currently one of the most frequently updated files, not to mention it is not a breaking change, so it's just a minor bump.
That being said, your version still the elegant way to do it, yet that is a major version bump and introduces a lot of change in the above mentioned file and it's tests.

Hi,
Sorry, I didn't read this conversation before doing my PR (https://github.com/alexellis/arkade/pull/602).
I have done a little experiment to retrieve the last version using Github API. Any feedback are welcome :)

Sorry for the other issues. I will continue the discussion here.
In the case of tools like kubectl and helm, the latter do not have binaries that can be downloaded directly from Github. It is therefore necessary to specify the version in order to be able to download the binary. On the other hand, in the case of these projects, they are present in Github and it is quite possible to retrieve the latest known version using the findGitHubRelease function.
My proposal would therefore be to make the request despite everything to Github even when the release does not contain the Github address (https://github.com/). Here the code to modify inside pkg/get/get.go:
	if len(version) == 0 &&
		(len(tool.URLTemplate) == 0 || strings.Contains(tool.URLTemplate, "https://github.com/")) {
		log.Printf("Looking up version for %s", tool.Name)
		v, err := findGitHubRelease(tool.Owner, tool.Repo)
...
		version = v
	}

We can change the if condition for the following one:
	if len(version) == 0 &&
		(len(tool.URLTemplate) == 0) {
		log.Printf("Looking up version for %s", tool.Name)
...
	}

Alternatively, one can also use a special version value to force the download of the latest version (like latest for exemple). Here the corresponding condition:
	if strings.Compare(version, "latest") == 0 || len(version) == 0 &&
		(len(tool.URLTemplate) == 0 || strings.Contains(tool.URLTemplate, "https://github.com/")) {

We can thus use a specific value in the tools.go file while leaving the possibility for users to download the latest version.
What do you think ?

There are tools which do not use GitHub at all for their releases or binaries, but separate text files or HTTP endpoints.
There's been some discussion with @Shikachuu and my preference would be to implement an optional field like "source" = "github" (or "" blank as a default) / "hashicorp" / "kubernetes" etc for these non-standard tools.
At runtime, the value of this field would use a "VersionFinder" interface to determine the URL.
For the GitHubVersionFinder, the existing code would be used. For Hashicorp, their series of text files / HTTP endpoints, and likewise for kubectl:
curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl"

For Hashicorp, there is a download server that can be browsed, but there may also be a text file that can be read. I'm not sure:
https://releases.hashicorp.com

It looks like there are releases on Github for most of the tools. So far I have only found hashicorp/vagrant, minio/mc and rancher/kim. For the rest, it seems to be there.

Just checked about the different URLs

Click to expand the code:
func Test_Tools(t *testing.T) {
	tools := MakeTools()

	nonGitHubURLs := make([]string, 0)

	for _, tool := range tools {
		url, err := tool.GetURL("", "", "")
		if err != nil {
			t.Fatal(err)
		}

		if !strings.Contains(url, "github") {
			nonGitHubURLs = append(nonGitHubURLs, url)
		}
	}

	fmt.Println("github URLs: ", (len(tools) - len(nonGitHubURLs)))
	fmt.Println("Non-github URLs: ", len(nonGitHubURLs), nonGitHubURLs)
}

github URLs:  67
Non-github URLs:  8 [https://get.helm.sh/helm---amd64.tar.gz https://storage.googleapis.com/kubernetes-release/release//bin//arm/kubectl https://releases.hashicorp.com/terraform//terraform___.zip https://releases.hashicorp.com/vagrant//vagrant___.zip https://releases.hashicorp.com/packer//packer___.zip https://releases.hashicorp.com/waypoint//waypoint___.zip https://dl.min.io/client/mc/release/-/mc https://dl.influxdata.com/influxdb/releases/influxdb2-client---.tar.gz]

I believe that a mix of VersionSource + Having a flexible Version function is the optimized solution. But we can start only with the first one to avoid refactoring.
@alexellis let me know if you want me to implement any of the solutions.

To put a hacky bandaid on the HashiCorp tools we can call the github API since they tag their releases there and after that just use the provided url template.
This should be a minor change in the runtime in this condition to be specific, yet as I mentioned above this is a hack.
Yet to be honest, at this point I trust the documented and versioned GitHub API more then the "random" download server that HashiCorp provides without versioning.
wdyt @alexellis?

K8s implemented in #1062
hashicorp implemented in #1065
This might be a candidate for closure at this point

/close: completed

/lock: resolved, open a new issue, if we implement new CLIs or applications with their own version scheme.


Test requirements for usage of RepositoryMapping

Write down test requirements for all usage of RepositoryMapping in controllers in report.md

Implemented in #15


Update MFA instructions to include other options

Currently, the page around MFA setup (https://docs.mattermost.com/onboard/multi-factor-authentication.html) seems to indicate that Google Authenticator is the only option when we support any TOTP option.  Something like:
“Users with AD/LDAP or email login can add multi-factor authentication to their account using a multi-factor authenticator app that generates Time-based One-time Passwords (TOTP), such as OneLogin, Google Authenticator, LastPass, Microsoft Authenticator app, Duo, Authy, or 1Password.”
This page should be updated to reflect that. There is also a separate Jira ticket to update the MFA setup page user's see when they configure their account.

Thanks for logging this, @ewwollesen! I agree that we need to clarify that Google Authenticator-compatible 2FA tools are supported.

This issue is resolved via https://github.com/mattermost/docs/pull/6375.


service discovery: Removing redundant language finder code

What does this PR do?
Removing redundant unused language finder

Motivation
Code cleanup

Additional Notes

Possible Drawbacks / Trade-offs

Describe how to test/QA your changes

/merge


display: nrf52840: adafruit_2_8_tft_touch_v2 shield not working with nrf-spim driver

Describe the bug
Neither the drivers/display nor the display/lvgl samples work with the default nrf52840dk_nrf52840 devicetree and adafruit_2_8_tft_touch_v2 shield.
With no changes to the dts only a white screen is displayed for either demo. Changing the 'arduino_spi' node to be 'spi1' instead of 'spi3' (but still using the nrf-spim driver, like the 'spi3' node must use) causes the display to show alternating grey and white bars which go up about three quarters of the display.
Changing the 'arduino_spi: &spi1' node to then use the 'nrf-spi' driver instead of the 'nrf-spim' driver resolves the issue, and both samples begin to work.
To Reproduce
Steps to reproduce the behavior:

west init && west update
west build -p -b nrf52840dk_nrf52840 samples/drivers/display/ -- -DSHIELD=adafruit_2_8_tft_touch_v2
west flash
observe issue
make suggested changes above
observe working display

Expected behavior
The display samples should work without modification on the board combinations suggested by documentation.
Impact
Default sample does not work, causing a poor experience when trying to start using a display with the board combinations suggested in the zephyr documentation.
The 'SPI' peripheral of the nrf52840 also doesn't support easyDMA, whereas the 'SPIM' peripheral does, so I would also expect to see diminished performance when having to use the spi driver to drive the display instead of the spim driver.
Environment (please complete the following information):

OS: Windows 10 19041
Toolchain: gcc-arm-embedded 9.3.1
Commit SHA: 3c79b565fe

Additional context
SPI3 w/ nrf-spim driver:

SPI1 w/ nrf-spim driver:

SPI1 w/ nrf-spi driver:

I can not reproduce it with latest master (b3ff89bd511afef484c193a428633f6a1c866944), please recheck.

Sorry for the late reply. Got around to checking this again, still does not work on latest master for me (577d588), and also does not work on the commit that you mentioned (b3ff89b), just getting the fully white screen. Just tried it out on both of those commits on a nucleo_f767zi board, which worked no issue.
Looking over my nrf52840 DK, and it is actually a nrf52840 preview DK, and it looks like I have a super early version with an engineering sample A nrf52840 chip. Looking through the errata for this chip (PDF warning), and it actually explains my issue. On this silicon rev both the SPIM3 peripheral doesn't work at all, and the SPIM peripheral in general has an issue where it clocks out an extra byte, which is probably what is happening.
So, seems like this is due to me having some extremely early hardware, and probably isn't something that could be recreated on a recent setup. Should be all good to close this issue IMO.

okay, thanks for response


Add a feed section restyle

I styled yes/no toggle buttons, and alignment of them, got rid of the border from directional buttons, set the floating of directional buttons
I also rearranged DOM a bit to make more use of bootstrap, details comment on the code
closes #126
closes #112

@hanbyul-here this looks great! The yes/no button styling needs a few small changes, I'll make a separate ticket for those.


Update silencer-lib, silencer-plugin to 1.7.10

Updates

com.github.ghik:silencer-lib
com.github.ghik:silencer-plugin

from 1.7.8 to 1.7.10.
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

Adjust future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "com.github.ghik" } ]

Or, add this to slow down future updates of this dependency:
dependencyOverrides = [{
  pullRequests = { frequency = "@monthly" },
  dependency = { groupId = "com.github.ghik" }
}]

labels: library-update, early-semver-patch, semver-spec-patch, commit-count:1

Superseded by #545.


Trigger phrase triggers inside code blocks and email addresses

If I'm writing Python code inside ` ` `py blocks with lots of decorators like @property, NL dates pops up all the time.
If it's an easy fix could the trigger phrase only trigger outside of code block contexts?
The same applies when writing email addresses - perhaps the @ should only trigger after whitespace and the popup should disappear if the phrase isn't part of a valid date string?
This is not a big deal as in the meantime I can just change the trigger phrase

Yeah, I use a different trigger since @ is used by something else in my notes. I'll ping @liamcain in case he can do some magic on this/


Allow background-color and border-style to be set on Graph config

Very specific solution for issue #428. Not really sure if it will work but seems reasonable. Maybe a more general solution would be to have the whole style object in config?

I think that a way to allow this kind of styling would be to have a standard className or style prop, that would be passed to the Graph element without having to introduce a lot of new props in the config.
What do you think?

I think that a way to allow this kind of styling would be to have a standard className or style prop, that would be passed to the Graph element without having to introduce a lot of new props in the config.
What do you think?


forc formatter incorrectly formats dependencies

The dependencies were formatted weird with a prefixed comma that doesn't seem to be needed.
Secondarily, I don't like how it folds up all the dependencies into a single line. Then I can't see what dependencies I'm actually using as they get tucked behind the editor.
I think these should be unfolded.
This:
contract;

use std::{
    address::Address,
    context::msg_amount,
    context::call_frames::{msg_asset_id, contract_id},
    assert::assert,
    contract_id::ContractId,
    token::{mint_to_address, transfer_to_output}
};

abi LiquidityPool {
    fn deposit(recipient: Address);
    fn withdraw(recipient: Address);
}

const BASE_TOKEN:b256 = 0x9ae5b658754e096e4d681c548daf46354495a437cc61492599e33fc64dcdc30c;

impl LiquidityPool for Contract {
    fn deposit(recipient: Address) {
        assert(msg_asset_id() == ~ContractId::from(BASE_TOKEN));
        assert(msg_amount() > 0);

        // Mint two times the amount.
        let amount_to_mint = msg_amount() * 2;

        // Mint some LP token based upon the amount of the base token.
        mint_to_address(amount_to_mint, recipient);
    }

    fn withdraw(recipient: Address) {
        assert(msg_asset_id() == contract_id());
        assert(msg_amount() > 0);

        // Amount to withdraw.
        let amount_to_transfer = msg_amount() / 2;

        // Transfer base token to recipient.
        transfer_to_output(amount_to_transfer, ~ContractId::from(BASE_TOKEN), recipient);
    }
}

Formatted to this:
contract;

use std::{, address::Address, assert::assert, context::call_frames::{contract_id, msg_asset_id}, context::msg_amount, contract_id::ContractId, token::{mint_to_address, transfer_to_output}};

abi LiquidityPool {
    fn deposit(recipient: Address);
    fn withdraw(recipient: Address);
}

const BASE_TOKEN: b256 = 0x9ae5b658754e096e4d681c548daf46354495a437cc61492599e33fc64dcdc30c;

impl LiquidityPool for Contract {
    fn deposit(recipient: Address) {
        assert(msg_asset_id() == ~ContractId::from(BASE_TOKEN));
        assert(msg_amount() > 0);

        // Mint two times the amount.
        let amount_to_mint = msg_amount() * 2;

        // Mint some LP token based upon the amount of the base token.
        mint_to_address(amount_to_mint, recipient);
    }

    fn withdraw(recipient: Address) {
        assert(msg_asset_id() == contract_id());
        assert(msg_amount() > 0);

        // Amount to withdraw.
        let amount_to_transfer = msg_amount() / 2;

        // Transfer base token to recipient.
        transfer_to_output(amount_to_transfer, ~ContractId::from(BASE_TOKEN), recipient);
    }
}

Secondarily, I don't like how it folds up all the dependencies into a single line. Then I can't see what dependencies I'm actually using as they get tucked behind the editor.

This is orthogonal to the primary issue of this PR, and there's an issue open for it actually: #1209


[Avatar] Conditionally set color

I would like to be able to conditionally set color of all components that has the color prop i.e Avatar, Badge and so on. Locally I manage to do it by just returning a string from a method but it complains about wanting the correct type which crashes the build. I tried to import the declared const of avatarPropDefs but it doesn't seem to work to have avatarPropDefs.color as a return type of a method and use it like color={methodThatReturns<avatarPropDefs.color>}.
Thanks for the lovelt library!

You'll need to tweak the method implementation and/or type signature so that it returns the allowed colors. It's hard to say more without seeing the code of your function.

Something like this should do the trick.
function getAvatarColor(): (typeof avatarPropDefs.color.values)[number]

Or
function getAvatarColor(): (typeof avatarPropDefs.color.default)

Works like a charm! Many thanks :)


Fix variable name

Thank you for nice notebook tutorial!!
I found the wrong variable name in docs, so I modified it.

I think issue here is simple my poor writing.
By default the merge method in pandas will return only those rows where a common identifier found in both tables, which is known as an “inner” join.
That means that if we merge the full contributions file to our filtered list of Proposition 64 committees, only the contributions to the Proposition 64 committees will remain. The result will be equivalent to a filter.
So it is actually intentional that we're using  prop here and now props. You may recall we created it as new variable near the end of chapter 7.
For that reason, I'm not going to accept this pull request as is. Though I'm open to perhaps renaming the variables through the lesson to more clearly distinguish them.

I'm sorry for forgetting a new variable assignment near the end of chaper 7 🙏 . I'll close this PR.


SWARM-771: Provide a zipkin fraction

[x] Have you followed the guidelines in our Contributing document?
[x] Have you created a JIRA and used it in the commit message?
[x] Have you checked to ensure there aren't other open Pull Requests for the same issue?
[x] Have you built the project locally prior to submission with mvn clean install?

Motivation
In order to integrate with Hawkular BTM, zipkin instrumentation is needed
Modifications
This introduces a zipkin fraction that adds the instrumentation to server side JAX-RS resources
Result
Zipkin instrumented JAX-RS resources can now send the reporting data to a zipkin backend

This change was initially motivated by https://issues.jboss.org/browse/SWARM-624

Reviewing locally. Will merge after applying some changes

Thanks @gastaldi

Merged in https://github.com/wildfly-swarm/wildfly-swarm/commit/4040187dffc05a2f95ce5614b7510d8a4521e842


Update README issue #664

Improved Documentation

Hi @rushikeshadhav , sorry missing this, I will reopen it now


Change titles on Set Active Profiles and Edit Profile pages

The title on the Set Active Profiles page is "Select Profiles".  The title on the Edit Profiles page is "Select Profile".  I know one is plural and one is singular, but this is subtle. Perhaps change the first to "Select Profiles to Activate" or simply "Activate Profile", and the second to "Select Profile to Edit" or "Edit Profile".  As it is, the Delete Profile page says "Delete Profile".

Changed in commit c2e71b5caab9044623222934208e6b514fe7d3fb.


Datadog tracing bad host header

Bug Description
Hello we are using the telemetry CRD with the extensionProvider Datadog.
From mesh config :
    extensionProviders:
    - name: datadog
      datadog:
        service: datadog-agent.sre.svc.cluster.local
        port: 8126

When istio proxy is sending traces to datadog agent :
The host header is set to  the cluster name outbound|8126||datadog-agent.sre.svc.cluster.local
The datadog agent respond a 400 Http response code with  Bad Request: malformed Host header
Version
istioctl version
client version: 1.15.3
control plane version: 1.15.3
data plane version: 1.15.3 (123 proxies)

kubectl version --short
Client Version: v1.24.0
Kustomize Version: v4.5.4
Server Version: v1.24.3-gke.2100

helm version --short
v3.2.4+g0ad800e

Additional Information
No response

this seems a bug need fix from upstream, authority must be configurable if cluster is eds type.

upstream is envoy ? should i create an issue ?

upstream is envoy ? should i create an issue ?

let's keep track here, I will send a PR to envoy.


[BUG] hotplug volume of VM will perform IO error on the specific scenario

Describe the bug
hotplug volume will perform an IO error when it dead twice. In detail, this behavior would cause the related iSCSI connection to re-login. After that, the original hotplug volume does not use anymore on the VM. You may see the IO error message on the VM side or the VM will hang on when you try to access this hotplug volume.
To Reproduce

create one VM instance.
attach the hotplug volume.
manually delete the hp-volume-xxx.
manually delete the hp-volume-xxx (newly hp-volume- pod) again.
You could check the iSCSI connection that will logout and then login. Also, the disk on the VM should be broken.

Expected behavior
Even the hp-volume pod is killed more than twice. The volume should work as usual.
Support bundle
Environment

Harvester ISO version: v1.1.1
Underlying Infrastructure (e.g. Baremetal with Dell PowerEdge R630):

Additional context
It is related to kubevirt behavior.
Kubevirt issue: https://github.com/kubevirt/kubevirt/issues/9263

Verified fixed on master-35717460-head (05/26). Close this issue.
Result
After manually delete the volume pods attached on virtual machine with two and several times.
harv0526:~ # kubectl get pods -A -o wide | grep hp-volume
default                     hp-volume-tm5nr                                         1/1     Running     0               4h3m    <IP_ADDRESS>        harv0526   <none>           <none>
harv0526:~ # kubectl delete pods hp-volume-tm5nr
pod "hp-volume-tm5nr" deleted
harv0526:~ # kubectl get pods -A |grep hp-volume
default                     hp-volume-bb6wl                                         1/1     Running     0               12s
harv0526:~ # kubectl delete pods hp-volume-bb6wl
pod "hp-volume-bb6wl" deleted

The hp-volume pod can work as usual and do IO on the attached volume in VM
After two times deletion of hp-volume pod, we can still write file to the disk
vm:/mnt/data # lsblk
NAME   MAJ:MIN RM SIZE RO TYPE MOUNTPOINT
sdb      8:16   0   5G  0 disk
└─sdb1   8:17   0   5G  0 part
vda    253:0    0  20G  0 disk
├─vda1 253:1    0   2M  0 part
├─vda2 253:2    0  20M  0 part /boot/efi
└─vda3 253:3    0  20G  0 part /
vdb    253:16   0   1M  0 disk
vm:/mnt/data # sudo mkdir /data
vm:/mnt/data # sudo mount /dev/sdb1 /data
vm:/mnt/data # echo "This is a file on the second disk" > /data/02_file_on_second_disk.txt
vm:/mnt/data # cat /data/02_file_on_second_disk.txt
This is a file on the second disk

After several times deletion on hp-volume pod, we can still write file to the disk
vm:/mnt/data # mkdir /data2
vm:/mnt/data # sudo mount /dev/sdc1 /data2
vm:/mnt/data # echo "This is a 5th delete on the second disk" > /data2/05_file_on_second_disk.txt
vm:/mnt/data # cat /data2/05_file_on_second_disk.txt
This is a 5th delete on the second disk

Test Information

Test Environment: single nodes Harvester on local kvm machine
Harvester version:master-35717460-head (05/26)

Verify Steps

Create a new volume with default storage-class
Create a VM in running state
Add volume to the VM
Check the current hotplug volume

kubectl get pods -A | grep hp-volume

Manually delete the hp-volume-xxx.

kubectl delete pods hp-volume-tm5nr

Manually delete the newly created hp-volume-xxx again.
ssh to the VM
mount the attached volume
Create file and write content to the attached volume
Check the volume can work as expected with IO