UI - No easy way to add system tools

gptscript version v0.0.0-dev+160a7334
Steps to reproduce the problem:

Launch UI -  DISABLE_CACHE=true GATEWAY_URL=https://gateway-api.gptscript.ai gptscript --ui --disable-cache
Try to create an assistant which uses system tools.
If i need to add a system tool say sys.exec , I have to use Find more tools option and then use Add by URL were i type the system tool name.

There should be a better way to discover and add system tools.

@sangee2004 This should be addressed now.

With latest version of electron app (commit id c5e7e29371) , we are able to add system tools using "Find Tools" option. They are listed in "System Tools" section in the "Tool catalog"


Update podManagementPolicy of StatefulSet object

In given manifest, podManagementPolicy is set as Parallel, but in later section of page, the console logs of "kubectl get pods -w -l app=zk" command displays ordered behavior, which is not the actual result in case of Parallel option.
Sample logs from doc :
NAME      READY     STATUS    RESTARTS   AGE
zk-0      0/1       Pending   0          0s
zk-0      0/1       Pending   0         0s
zk-0      0/1       ContainerCreating   0         0s
zk-0      0/1       Running   0         19s
zk-0      1/1       Running   0         40s
zk-1      0/1       Pending   0         0s
zk-1      0/1       Pending   0         0s
zk-1      0/1       ContainerCreating   0         0s
zk-1      0/1       Running   0         18s
zk-1      1/1       Running   0         40s
zk-2      0/1       Pending   0         0s
zk-2      0/1       Pending   0         0s
zk-2      0/1       ContainerCreating   0         0s
zk-2      0/1       Running   0         19s
zk-2      1/1       Running   0         40s
-- here pods are created in order
Actual results after applying the given manifest :
[taher@kubernetes-docker ~]$ kubectl apply -f zookeeper.yaml
service/zk-hs created
service/zk-cs created
poddisruptionbudget.policy/zk-pdb created
statefulset.apps/zk created
[taher@kubernetes-docker ~]$ kubectl get pods -w -l app=zk
NAME   READY   STATUS              RESTARTS   AGE
zk-0   0/1     Pending             0          3s
zk-1   0/1     Pending             0          3s
zk-2   0/1     ContainerCreating   0          3s
zk-1   0/1   Pending   0     4s
zk-0   0/1   Pending   0     4s
zk-1   0/1   Pending   0     5s
zk-0   0/1   Pending   0     5s
zk-1   0/1   Pending   0     5s
zk-1   0/1   ContainerCreating   0     5s
zk-0   0/1   Pending   0     5s
zk-2   0/1   Running   0     19s
zk-1   0/1   Running   0     24s
zk-2   1/1   Running   0     35s
zk-1   1/1   Running   0     37s
-- here pods are created in parallel
Resolution :
Either change the value of podManagementPolicy option to OrderedReady or remove that option, so that StatefulSet will take it's default behavior.

/assign @jaredbhatti

/approve

Any request need to raise for merge?

/lgtm


Does git-lfs support ProxyCommand?

I setup ~/.ssh/config like following:
Host          github.com
Port          22
User          git
HostName      github.com
IdentityFile  ~/.ssh/id_rsa.key
ProxyCommand  nc -x localhost:9002 %h %p

My proxy tool comes with a debug console, and while I do see nc making connections, I don't see much network traffic during a git push. Since git-lfs also goes through SSH, I am wondering if it obeys ProxyCommand or not?

git-lfs only uses ssh to establish an authentication token which it can then use over HTTPS for the main bulk of the actual work, including API calls and uploads / downloads. So when push, there will only be a single ssh call at the start to retrieve this token using ssh, then the rest will be HTTPS traffic.
Because git-lfs uses your ssh client then it will respect any settings you've configured for it, including ProxyCommand.

@sinbad Thx, it also mean I need to configure proxy setting manually right? Just setting system proxy (on OSX) is not enough.

For HTTPS proxy? Yes, you'll need to do this: http://stackoverflow.com/questions/128035/how-do-i-pull-from-a-git-repository-through-an-http-proxy


Project work

Will you be engaged in a project or can you consider it dead? There is almost no activity.

I can understand your urge.
I will try working on it soon.

As I've mentioned in the previous issue you posted regarding the same matter. It's on you now how you can integrate a solution in the project to make possible what you need.
If you're successful making it possible, do tell us how you did it.
Also, If I got any free time recently, I'll work on the solution myself. I hope there is no time boundation for your project.


Emulator doesnt allow double messages to bot?

I noticed that if you send a message through the emulator to your bot, and the bot is programmed to not send a message back, the emulator doesnt seem to allow you to send another message.
Also, is there a way to "restart" everything in the emulator? I find myself having to close the emulator and restart it every few minutes.

You're correct that the emulator waits for a response from the bot's web endpoint.  I'm not sure if it eventually times out.
We tend to "restart" the emulator by changing the user and/or conversation ID.  I'm not sure that stops the emulator's current http request, though.

you need to reply with at the very least a status code such as OK.  You don't have to return a message. Otherwise the emulator will wait for a response until it times out (probably 2 minutes).


Add blinding verification and fix warnings from dependencies

Add blinding verification
At some point in the DigiCash protocol, the bank receives N blinded bills and chooses to sign one blindly. Before the bank signature happens, the person should reveal the blinding for all the bills except the one selected by the bank by sending (non-blinded bills, blinding factors). At this point the bank has (blinded bills, non-blinded bills, blinding factors). The bank needs to verify the blinding of the blinded bills. This is done manually, unless this library has the added verification functionality.
Fix babel deprecated libraries
Apparently, babel changes the arch of the libraries which rendered the old one deprecated. This pull request also updates to the latest ones.

Thanks!


[WIP] move iptables and conntrack utils out of k/k

POC for moving iptables and conntrack out of kubernetes repo
Those are very useful libraries, specially iptables, and there are no similar ones in the golang ecosystem

/cc @thockin

The README claims you're supposed to follow the directions in https://github.com/kubernetes/utils/blob/master/HOWTOMOVE.md to move things with all of their git history, though that clearly hasn't been done in a lot of cases...

@aojea @danwinship i think it would be better to create a new repo for this instead of k8s.io/utils
@thockin ^^^

+1 to preserve history in the new repo.

2 issues:

the third_party is unpleasant.  Is that to break cycles?  I don't see any.  Could we coax the apimachinery repos to move those 5 or 6 libs to utils?  Or could we remove the deps on them?

@dims We could do a different repo.  I suggested that in the original discussion too.  This repo already has "ebtables" which is very similar.  If we made a new repo, I'd love to EOL this ebtables, too, but that is hard.  What is motivating the suggestion from your POV?

the third_party is unpleasant.  Is that to break cycles?  I don't see any.  Could we coax the apimachinery repos to move those 5 or 6 libs to utils?  Or could we remove the deps on them?

this was not supposed to be a proposal, just to have an idea of the code that will needed to move if we don't want to import k8s.io/apimachinery.
I don't know if t it should be possible to move those libraries easily, lot of projects depend on it.
I think that having a staging repo will allow to keep the code inside k/k and solve the dependency problem, no?

@thockin the mount package which moved from staging/ to utils went back to staging/src/k8s.io/mount-utils
All the reasons that went into it is documented here:
https://github.com/kubernetes/enhancements/blob/master/keps/sig-storage/20200508-move-utils-mount-2staging.md#motivation
Basically they were not able to test things and we ended up breaking k8s when changes were made in utils/ and then vendored in
Do we have a mitigation strategy to avoid the same situation happening with this set of code?

@thockin what about moving this to the new staging repo component-helpers https://github.com/kubernetes/kubernetes/pull/92507/files
k8s.io/component-helpers/networking/{iptables,ebtables,hostport}

That sounds like exactly what we're looking for

https://github.com/kubernetes/kubernetes/pull/100931 <- Started to move some functions internal to the API (as sig scheduling), I was wondering if the iptables/ipvs/conntrack should be kept on components-helper repo, or if we should create a new network-utils one.


Quicksilver keeps crashing

I am still running Yosemite and see no reason to upgrade yet. If it ain't broke, don't fix it....
Quicksilver, however, is constantly crashing since a couple of weeks and no updates appear. Is it dead ? Should I change to something else ?
The crash is always caused by this:
Exception Type:        EXC_BAD_ACCESS (SIGSEGV)
Exception Codes:       KERN_INVALID_ADDRESS at 0x0000148fb26fbec0
I am running version 1.5.2

Quicksilver, however, is constantly crashing since a couple of weeks and no updates appear. Is it dead ? Should I change to something else ?

Is this a serious question? There have been two updates very recently.
I’ve seen problems myself around the code that caused this crash, but I’m not sure yet what the solution is.

See #2311


Update glossary entry for Quantity #30885

Issue - #30885
This is my first PR, do let me know if there are any changes required.

/retitle Update glossary entry for Quantity
Still relevant to #30885


Number system convertor

Description
In this website user can input a binary number and convert into various number system.
#355

Type of change

[x] New feature (non-breaking change which adds functionality)

Explain the Testing instructions
Test Configuration:

Version: 1.0
Text-editors used: Vs code

Checklist:

[x] My code follows the style guidelines of this project
[x] I have performed a self-review of my own code
[x] I have commented my code, particularly in hard-to-understand areas
[x] I have made corresponding changes to the documentation
[x] My changes generate no new warnings
[x] I have added tests that prove my fix is effective or that my feature works
[x] New and existing unit tests pass locally with my changes
[x] Any dependent changes have been merged and published in downstream modules

ATTACH SCREEN-SHOTS / DEPLOYMENT LINK

Made required changes.

Still not fixed

Made the necessary changes.

Made the necessary changes.

Better, but if you can just increase the spacing between these buttons it will look neat.

increase the font and size of input field in small screen

@yellowberard its still very small check again and share a video sample

https://user-images.githubusercontent.com/82977727/159072008-43a83427-1f1a-404f-8916-9d6afd95478a.mp4
Here is a demo for responsiveness

@arpit456jain are you able to scroll till the end?

You can visit this  Link

@arpit456jain are you able to scroll till the end?

I think this is because of the netlify  preview bar overlapping the website.
Here I have attached a screenshot without the preview bar.

Let me just recheck

Let me just recheck
Edit: Still the same even without preview bar

@VidhiBhatt01 i am merging this just create a new issue for fixing it font size


error in - az vmss list-instance-connection-info

This is autogenerated. Please review and update as needed.
Describe the bug
Command Name
az vmss list-instance-connection-info
Errors:
'NoneType' object has no attribute 'id'
Traceback (most recent call last):
cli\Lib\site-packages\knack\cli.py, ln 231, in invoke
azure\cli\core\commands\__init__.py, ln 657, in execute
azure\cli\core\commands\__init__.py, ln 720, in _run_jobs_serially
azure\cli\core\commands\__init__.py, ln 691, in _run_job
azure\cli\core\commands\__init__.py, ln 328, in __call__
site-packages\azure\cli\core\__init__.py, ln 807, in default_command_handler
azure\cli\command_modules\vm\custom.py, ln 2869, in list_vmss_instance_connection_info
AttributeError: 'NoneType' object has no attribute 'id'

To Reproduce:
Steps to reproduce the behavior. Note that argument values have been redacted, as they may contain sensitive information.

Put any pre-requisite steps here...
az vmss list-instance-connection-info -g {} --name {}

Expected Behavior
Environment Summary
Windows-10-10.0.19041-SP0
Python 3.6.8
Installer: MSI

azure-cli 2.22.1

Additional Context

#14287


TS errors in unrelated projects in CSNX

From chat thread by Alex Sanders.
The issue seems to arise when:

you build a project that is not configured to handle JSX
Nx doesn't have a cache result for that project (or you skip the cache)
something in dist has a .d.ts that imports from @guardian/react-components (i.e. dev kitchen)

if you remove all import [whatevers] from "@guardian/source-react-components"; from dist/**/*.d.ts then everything seems fine
TS has found a declaration file that imports from a package that the paths config resolves to the react components source directory, and because the project is not set up handle jsx, it errors
what i don't know is why TS is worried about declaration files in dist at any point, let alone when building an unrelated project
for anyone else who looks into this, i reckon https://www.typescriptlang.org/tsconfig#Compiler_Diagnostics_6251 is your friend

i guess it needs to be fixed? i reckon there's some interesting discoveries awaiting but they're very hard to spot right now


[PF-2837] Remove access and cloning flags for aws-notebook creation

Same as https://github.com/DataBiosphere/terra-cli/pull/513, for AWS notebooks
remove unused functions
rename test classes to have suffix 'Test'

unrelated failure
COMMAND: workspace list --limit=500 --format=json |
-- | --
  | STDERR -------------- |
  | [ERROR] Error fetching list of workspaces: Not authorized to access Terra Policy Service


Update GroupMe API url

The initial API url was causing a 404 error.

@octohub I am confident in my ability to maintain this project going forward. Could I be given editing rights?

@ErikBoesen Awesome. I just sent you an invite to be a collaborator.

@octohub Thank you for the quick response! I look forward to helping out!


removed duplicate rubocop exclusion

Description
Removes duplicate Style/FileName cop exclusion.
Issues Resolved
[List any existing issues this PR resolves]
Check List

[ ] All tests pass. See https://github.com/chef-cookbooks/community_cookbook_documentation/blob/master/TESTING.MD
[ ] New functionality includes testing.
[ ] New functionality has been documented in the README if applicable
[ ] The CLA has been signed. See https://github.com/chef-cookbooks/community_cookbook_documentation/blob/master/CONTRIBUTING.MD

Obvious fix.

Hi. I am an automated pull request bot named Curry. There are commits in this pull request whose authors are not yet authorized to contribute to Chef Software, Inc. projects or are using a non-GitHub verified email address. To become authorized to contribute, you will need to sign the Contributor License Agreement (CLA) as an individual or on behalf of your company. You can read more on Chef's blog.
Non-GitHub Verified Committers
There are 1 commit author(s) whose commits are authored by a non-GitHub verified email address. Chef will have to manually verify that they are authorized to contribute.
Please sign the CLA here.

#94 is going to nuke the file entirely so I'm closing this out


PlutoBoard.run_fileserver() only serves files in the last created package by PlutoBoard.

Say I have setup two packages A and B via PlutoBoard. A is created before B. Then, if I run the notebook in A, PlutoBoard.run_fileserver() will only load static files from B.

That might be because it rather calls the function from B over A, I will look into that. Out of curiosity, why do you want to set up two packages using PlutoBoard with one depending on the other?

No, A and B are independent. At first, I setup A for my work. But I lost the original static/index.html during development. I want to learn something from it. And I can not find the content of this index.html in the doc site at that time. So I use PlutoBoard to create another package B so that I can refer to the original index.html. After I setup B, when I rerun the notebook in A, the content reverts back to the original index.html. I check the output of run_fileserver() in the A's notebook, and find it loading the static file from folders of B.

Ohh, I see. This happens because you precompiled PlutoBoard in package A. When you imported it in package B, PlutoBoard was already precompiled, so it didnt't use the new filepath of package B.
That's a mistake on PlutoBoard's side I will fix.
To force precompilation until the fix you can delete the folder ~/.julia/compiled/v1.11/PlutoBoard and precompile with ] precompile in your package.

And I can not find the content of this index.html in the doc site at that time

All setup files are located in setup/ (https://github.com/UniStuttgart-IKR/PlutoBoard.jl/blob/main/setup/static/index.html).
But yes, I should add an information where to find those example files to docs.


Allow For Multiple Parallel Messages

The current implementation is essentially "single-threaded" since it requests a single message and then wait for it to arrive, then we handle that message before sending back the ACK or next_message.
My use-case at work would certainly benefit from the ability to specify a limit of how many messages to handle in parallel. Something like:
@impl Jetstream.PullConsumer
  def init(nil) do
    consumer = [
      connection_name: :gnat,
      stream_name: "my_stream",
      consumer_name: "my_stream",
      max_concurrency: 10
    ]
    {:ok, nil, consumer}
  end

This would match the same option name from Task.async_stream in the standard library.

This is an use-case that I do not want to support in PullConsumer as it is meant to be a super simple API serving say 60-70% use-cases. See #8. Your use case basically would much more benefit from batching messages, so you could then pass these to async_stream or whatever else suits you. For this, I planned to recommend Broadway and to provide Broadway Producer and Consumer modules in this library. What do you think?

Picking up the thread of conversation from https://github.com/mmmries/jetstream/pull/43#issuecomment-1085724070
I did a handful of benchmarks to check on the performance and overhead of starting multiple PullConsumer processes vs starting a single PullConsumer that delegates the work to separate processes.

Benchmark Process and Results
Basic Assumptions
The purpose of these tests is to check for library overhead or bottlenecks. We aren't trying to simulate a realistic workload, we are setting up a simplistic scenario where nats won't be under heavy load so that we can stress test our own library in specific ways.
All of these benchmarks were run on my MacBook Pro (13-inch, M1, 2020) with nats-server: v2.6.6 installed view homebrew. I shut down and started nats between each benchmark run and then created the stream + consumer with memory-only retention to get a comparable nats performance for each run. I also disabled all of the debug logging in our library by adding a config/config.exs file with the following content.
import Config

config :logger,
  backends: [:console],
  compile_time_purge_matching: [
    [level_lower_than: :error]
  ]

For each run, I would start nats server with nats-server -js, then start the jetstream project with iex -S mix and copy-paste in the test scripts below.
Single Threaded Scenario (ie current master branch)
{:ok, _} = Gnat.ConnectionSupervisor.start_link(%{name: :gnat, connection_settings: [%{}]})
{:ok, stream} = Jetstream.API.Stream.create(:gnat, %Jetstream.API.Stream{name: "TEST", storage: :memory, subjects: ["test"]})

Enum.each(1..100_000, fn(i) ->
  Gnat.pub(:gnat, "test", Jason.encode!(%{num: i, body: "foobar"}))
end)

{:ok, consumer} = Jetstream.API.Consumer.create(:gnat, %Jetstream.API.Consumer{stream_name: "TEST", durable_name: "TEST"})

defmodule ConsumeTest do
  use Jetstream.PullConsumer

  def start_link(arg) do
    Jetstream.PullConsumer.start_link(__MODULE__, arg)
  end

  @impl true
  def init(_arg) do
    {:ok, {nil, nil},
      connection_name: :gnat,
      stream_name: "TEST",
      consumer_name: "TEST"}
  end

  @impl true
  def handle_message(message, {nil, ni}) do
    {:ack, {:erlang.monotonic_time(:millisecond), nil}}
  end

  def handle_message(message, {first, _last}) do
    last = :erlang.monotonic_time(:millisecond)
    {:ack, {first, last}}
  end
end

{:ok, pid} = ConsumeTest.start_link(nil)

# Wait for all 100k messages to be consumed

%{mod_state: %{state: {from, to}}} = :sys.get_state(pid)
100_000.0 / ((to - from) / 1000.0)
# this will output a number of messages per second

Results:
10:34:22.956 to 10:35:35.546 => 22.956 to 95.546 => 72.59sec
100k messages / 72.59sec => 1,377.6 msg/sec
After changing log level and removing extra IO.puts messages
-576460748985 to -576460695478 (milliseconds) => 53507ms
100k message / 53.507sec => 1868.9 msg/sec
Multiple PullConsumer Processes
defmodule MessageTimer do
  use GenServer

  def start_link do
    GenServer.start_link(__MODULE__, nil, name: __MODULE__)
  end

  def init(nil) do
    state = {0, nil, nil}
    {:ok, state}
  end

  def handle_info({:message, milliseconds}, {0, nil, nil}) do
    {:noreply, {1, milliseconds, milliseconds}}
  end

  def handle_info({:message, milliseconds}, state) do
    update_state(state, milliseconds)
    |> check_for_terminal()
  end

  defp check_for_terminal({100_000, first, last}) do
    messages_per_second = 100_000.0 / ((last - first) / 1000.0)
    IO.puts("Received 100k messages at a rate of #{messages_per_second} messages per second")
    {:stop, :normal, nil}
  end
  defp check_for_terminal(state), do: {:noreply, state}

  defp update_state({num_received, first, last}, milliseconds) do
    cond do
      milliseconds < first ->
        {num_received + 1, milliseconds, last}

      milliseconds > last ->
        {num_received + 1, first, milliseconds}

      true ->
        {num_received + 1, first, last}
    end
  end
end

{:ok, _} = MessageTimer.start_link()
{:ok, _} = Gnat.ConnectionSupervisor.start_link(%{name: :gnat, connection_settings: [%{}]})
{:ok, stream} = Jetstream.API.Stream.create(:gnat, %Jetstream.API.Stream{name: "TEST", storage: :memory, subjects: ["test"]})

Enum.each(1..100_000, fn(i) ->
  Gnat.pub(:gnat, "test", Jason.encode!(%{num: i, body: "foobar"}))
end)

{:ok, consumer} = Jetstream.API.Consumer.create(:gnat, %Jetstream.API.Consumer{stream_name: "TEST", durable_name: "TEST"})

defmodule ConsumeTest do
  use Jetstream.PullConsumer

  def start_link(arg) do
    Jetstream.PullConsumer.start_link(__MODULE__, arg)
  end

  @impl true
  def init(_arg) do
    {:ok, {nil, nil},
      connection_name: :gnat,
      stream_name: "TEST",
      consumer_name: "TEST"}
  end

  @impl true
  def handle_message(message, state) do
    send(MessageTimer, {:message, :erlang.monotonic_time(:millisecond)})
    {:ack, state}
  end
end

Enum.each(1..10, fn(_) ->
  {:ok, _pid} = ConsumeTest.start_link(nil)
end)

See full list of parallel test results at the bottom of this section

Batched Message Pull w/ Parallel Processing
defmodule MessageTimer do
  use GenServer

  def start_link do
    GenServer.start_link(__MODULE__, nil, name: __MODULE__)
  end

  def init(nil) do
    state = {0, nil, nil}
    {:ok, state}
  end

  def handle_info({:message, milliseconds}, {0, nil, nil}) do
    {:noreply, {1, milliseconds, milliseconds}}
  end

  def handle_info({:message, milliseconds}, state) do
    update_state(state, milliseconds)
    |> check_for_terminal()
  end

  defp check_for_terminal({100_000, first, last}) do
    messages_per_second = 100_000.0 / ((last - first) / 1000.0)
    IO.puts("Received 100k messages at a rate of #{messages_per_second} messages per second")
    {:stop, :normal, nil}
  end
  defp check_for_terminal(state), do: {:noreply, state}

  defp update_state({num_received, first, last}, milliseconds) do
    cond do
      milliseconds < first ->
        {num_received + 1, milliseconds, last}

      milliseconds > last ->
        {num_received + 1, first, milliseconds}

      true ->
        {num_received + 1, first, last}
    end
  end
end

{:ok, _} = MessageTimer.start_link()
{:ok, _} = Gnat.ConnectionSupervisor.start_link(%{name: :gnat, connection_settings: [%{}]})
{:ok, stream} = Jetstream.API.Stream.create(:gnat, %Jetstream.API.Stream{name: "TEST", storage: :memory, subjects: ["test"]})

Enum.each(1..100_000, fn(i) ->
  Gnat.pub(:gnat, "test", Jason.encode!(%{num: i, body: "foobar"}))
end)

{:ok, consumer} = Jetstream.API.Consumer.create(:gnat, %Jetstream.API.Consumer{stream_name: "TEST", durable_name: "TEST"})

defmodule ConsumeTest do
  use Jetstream.PullConsumer

  def start_link(arg) do
    Jetstream.PullConsumer.start_link(__MODULE__, arg)
  end

  @impl true
  def init(_arg) do
    {:ok, {nil, nil},
      connection_name: :gnat,
      stream_name: "TEST",
      consumer_name: "TEST"}
  end

  @impl true
  def handle_message(message, state) do
    send(MessageTimer, {:message, :erlang.monotonic_time(:millisecond)})
    {:ack, state}
  end
end

{:ok, pid} = ConsumeTest.start_link(nil)

Parallel Test Results:

Parallel
Throughput PullConsumer
Throughput Tasks

1
29559.56252
28768.6997

2
48567.26566
47370.9143

4
73046.01899
70422.5352

8
96525.09653
93023.2558

10
88028.16901
101419.878

16
104166.6667
106609.808

20
114155.2511
120336.943

24
120918.9843
130548.303

32
127713.9208
141843.972

64
140845.0704
149700.599

96
134589.502
150602.41

128
131406.0447
149476.831

The results are summarized in this graph.

The blue line shows the messages received acknowledge per second when starting multiple PullConsumer processes and the orange line shows the messages per second when running on a slightly modified version with a single PullConsumer that starts each job in a separate process.

There's not a huge gap in performance between the two methods, so starting multiple PullConsumer's is certainly a viable option.

his is an use-case that I do not want to support in PullConsumer as it is meant to be a super simple API serving say 60-70%

@mkaput I think this would be a good topic for us to discuss on a call, but if you have any thoughts before we get schedules lined up, I would be happy to read and try to understand asynchronously.
In my working experience, I have mostly worked at companies that were setting up event architectures between multiple backend services. In every case we have had multiple copies of the app running in production (for redundancy/resiliency). So this would mean having a single PullConsumer running per instance the beam and we would still need to deal with the fact that different instances would get only part of the message history.
And in each of my professional projects, we have wanted to avoid having a queue fall behind just because of a single slow message (maybe something waiting on an IO call), so we have always allowed some number (like 20 - 200) of parallel messages to be processed per instance of the application. This helps to keep each service up-to-date with the stream.
So for me, parallelism is the common-case and I would think of running only a single PullConsumer as being niche. It sounds like you have the opposite experience? I would love to better understand that use-case.

Hi @mmmries I've run some more benchmarks based on yours but with average of 10 runs per batch size, so it's less likely that we had some weird spikes etc. added https://github.com/membraneframework/beamchmark, so it's possible to see whats is holding us back and also on two different machines and got these results with small message size:

Looking at Beamchmark data we've came to a conclusion that requesting Jetstream itself is a chokepoint here and that might explain why in larger batch sizes one PullConsumer is faster as at the start we send one request instead of i.e. 128
But also to check for larger size of messages I've mocked larger message(~6kB)

Then with example message from our system(~1kB)

So for me it feels like it really depends on use case and think that we should somehow support both.
Please let me know if I've missed something that would make this measurements incorrect.
If you would like to check out the code I've forked the repo https://github.com/marmor157/jetstream_benchmarks/pull/1

It looks like JetStream has Batching built into its system and it makes sense to me to lean into the built-in batching mechanism as it will likely be the most optimized. It sounds cumbersome to me to require developers to create a separate Jetstream.PullConsumer for each parallel message they want to consume. Best I can tell it looks like the Broadway PR takes care of the complex case with concurrency and batching and the existing Jetstream.PullConsumer is good for simpler cases of processing one message at a time. I'm not super familiar with Broadway, but it makes sense to me to leverage it for the complex concurrency case because it already knows how to do that and won't require reinventing it ourselves.

@mmmries What are your thoughts about the Broadway approach of handling parallel messages? We would like to finally make a release of this library and this discussion seems like the only thing that is blocking the release.


fix: use consistent virtual module ID in module graph

Description
When investigating https://github.com/vitejs/vite/issues/12912, I found that when accepting virtual:my-plugin:foo like below
import.meta.hot.accept(['virtual:my-plugin:foo'], { /** code */ })

This will lead to adding a /src/virtual:my-plugin:foo generated by the following code to the module graph, however, IIUC, virtual module's URL should not be calculated with the importer.
https://github.com/vitejs/vite/blob/229c5925c8c84709b8e06e8092a255cb820dafc9/packages/vite/src/node/plugins/importAnalysis.ts#L744-L747

In this PR, the test case is modified to only update the virtual module as below.
import.meta.hot.accept(
    ['virtual:file', '/@id/__x00__virtual:file'],

To fix #12912 ideally, we shall only use 'virtual:file' but the HMR dilemma now is like this:

acceptedPath send to the client is "/@id/__x00__virtual:file"
the acceptedPath defined in main.js must include "/@id/__x00__virtual:file" to receive the update.

I'm not sure what's the best way to fix this, but I think it's straightforward to avoid assembling URL for virtual file with the importer in this PR. Looking forward to some feedback 🙌.
Additional context

What is the purpose of this pull request?

[x] Bug fix
[ ] New Feature
[ ] Documentation update
[ ] Other

Before submitting the PR, please make sure you do the following

[x] Read the Contributing Guidelines.
[x] Read the Pull Request Guidelines and follow the PR Title Convention.
[ ] Check that there isn't already a PR that solves the problem the same way to avoid creating a duplicate.
[x] Provide a description in this PR that addresses what the PR is solving, or reference the issue that it solves (e.g. fixes #123).
[x] Ideally, include relevant tests that fail without this PR but pass with it.

/ecosystem-ci run

Ecosystem CI looks good. The Nuxt failure is in main too 👍🏼

@bluwy could you explain why that would be better? I think it is more clear to me if the client already receives /@id/__x00__virtual:file", no? From the client POV, always getting valid URLs from the Vite dev server is easier to explain IMO

Hmm yeah after refreshing myself of what values the acceptedPath is usually gets passed with, seems like it's always URLs, so makes sense to continuing wrapping it, but unwrapping it later in the client again.
Also I tested with /@fs/ and it looks like the /@fs/ path is sent to the client too (not sure if HMR is fine with it though)


Tile 8257 half amp marked bad due to spurious amp jump

This isn't a new problem, similar to issue #14.
Tile 8257 exposure 208688 on 2023-12-08 triggers the "b6 amp D OSTEP=5.5 too large" error, rejecting the right half of the CCD in processing.  The underlying cause is a saturation event at (2539,3994) in the raw image that bleeds left into the overscan region.
I've marked this tile as "unsure" for now.

I think the fix is to identify the region to mask and add it to $DESI_SPECTRO_CALIB/ccd/ccd-region-mask.csv, then reprocess.  See desihub/desispec#2050 for context.  We might need to mask entire rows to avoid triggering the "b6 amp D OSTEP=5.5 too large" error.
Assigning myself to followup on this after catching up on daily ops (and likely not until later in the collab mtg or the following week).

@sbailey , pinging this ticket.

Pinging this ticket...

Brief update: this is more complicated than just masking pixels with $DESI_SPECTRO_CALIB/ccd/ccd-region-mask.csv, because that only masks in the active region but not the overscan region.
find_overscan_cosmic_trails was intended to find cases like this, but isn't getting triggered by this particular case.  I think the solution for this case will be to:

mask all columns for that amp for the impacted rows (there is also a negative shadow rightward of the bright streak leftward, so masking all of them is motivated since the shadow correction isn't working great for them anyway).
add additional preproc code to ignore overscan rows where all of the active region data for those rows are masked so that it won't trigger OSTEP for rows that are masked anyway.

@schlafly tile 8257 is re-processed in daily, recovering b6 (though petal 1 was still marked as bad that night due to bad z1):
https://data.desi.lbl.gov/desi/spectro/redux/daily/tiles/cumulative/8257/20231208/tile-qa-8257-thru20231208.png

This was closed and I lost track of it, but FWIW, I just marked this tile as good.


Mongoid 5.1 support

Is anyone having issues with Mongoid 5.1?
Here is my setup.  Rails <IP_ADDRESS> / Mongoid 5.1.1 / Mongo 2.4.14 / mongodb_logger 0.6.5.  I see the development_log collection in my mongo DB but I get these errors trying to run rake mongodb_logger:* tasks.
MongodbLogger WARNING: Using Rails Logger due to exception: uninitialized constant Mongo::MongoClient
Also nothing actually gets logged into development_log collection.
Here is my config/mongodb_logger.yml
development:
database: rails425_dev
capsize: <%= 10.megabytes %>
host: localhost
port: 27017
replica_set: false

mongodb_logger support mongo gem 1.x version. I am trying to make it working with mongo 2.x gem in mongo2 branch, but still not some tests pass for mongodb (some problems with users and roles inside mongodb). I am ready to review PR, which will help me.


Abstract out paginated logic in search API views

@reupen @elcct what do you think about abstracting out the pagination logic?
I've added it just to the OMIS search API View but could be applied to the other ones as well if you want.
This also catches the 500 error about the result window being too big that we are getting from sentry recently.

Codecov Report

Merging #394 into develop will increase coverage by <.01%.
The diff coverage is 96.42%.

@@             Coverage Diff             @@
##           develop     #394      +/-   ##
===========================================
+ Coverage    95.92%   95.92%   +<.01%
===========================================
  Files           77       77
  Lines         2722     2747      +25
  Branches       234      236       +2
===========================================
+ Hits          2611     2635      +24
  Misses          80       80
- Partials        31       32       +1

Impacted Files
Coverage Δ

datahub/search/omis/views.py
97.36% <96.42%> (-2.64%)
:arrow_down:

Continue to review full report at Codecov.

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

I wanted to use the DRF logic but it's not nicely separated unfortunately.


⚠ Site has degraded performance

In fe9a60d, Site (https://fyle.uk) experienced degraded performance:

HTTP code: 503
Response time: 27185 ms

Resolved: Site performance has improved in a6f98df after 8 minutes.


[CI] Upgrade MacOS ARM64 UBSAN to use gcc-13.

GCC 12.4 and 13.3 are minimum supported due to GCC bug #114007; prefer GCC 13.3
gcovr 7.x is required for parsing coverage output of GCC 13.x; gcovr 7.2 is currently latest

Does this fix need to go to the macOS package check as well? I am unable to get github actions to find a runner to pick up those jobs at all. Not sure why, there doesn't seem to be any indications as to why it is stuck like that.
I have cancelled and restarted those jobs multiple times over several days, no change.

Does this fix need to go to the macOS package check as well? I am unable to get github actions to find a runner to pick up those jobs at all. Not sure why, there doesn't seem to be any indications as to why it is stuck like that.
I have cancelled and restarted those jobs multiple times over several days, no change.

Some of the runners seem offline... I haven't checked yet if someone has reported the outage yet or if it's scheduled maintenance...

@Dead2 , @mtl1979
macos-11 removed from github actions: https://github.com/actions/runner-images/pull/10198
macos-11 zlib-ng issue: #1693

I knew they were planning to remove it, just didn't remember the date.


⚠ Bofrost.at has degraded performance

In 5593e68, Bofrost.at (https://www.bofrost.at) experienced degraded performance:

HTTP code: 200
Response time: 1123 ms

Resolved: Bofrost.at performance has improved in e88069e.


Can Flash Attention be used?

Hi!
A big thanks for your impressive work! Since full attention and causal attention are both included, I am curious how you implemented such attention masks if flash attention is used.
Best regards

Hi, We will try to implement it. Here's a potential solution to your question https://github.com/showlab/Show-o/issues/8.


Transmission plugin - BUG: Unhandled error in plugin transmission: 'Torrent' object has no attribute 'totalSize'

Expected behaviour:

Loading of found magnet link to transmission server
Actual behaviour:
Flexget executes find torrents and then pushes to transmission servers, the first magnet link that gets pushed loads on the server but the flexget run crashes with error BUG: Unhandled error in plugin transmission: 'Torrent' object has no attribute 'totalSize'
Steps to reproduce:

Step 1: ...
execute task

Config:
accept_all: true
discover:
  from:
    - magnetdl:
        category: tv
        pages: 1
  interval: 15 minutes
  release_estimations: loose
  what:
    - trakt_list:
        account: *****************
        list: tv_list
        strip_dates: true
        type: shows
        username: **************
metainfo_series: true
no_entries_ok: true
quality: 1080p
regexp:
  reject:
    - .*NTERNAL.*
    - .*REPACK.*
    - .*PROPER.*
    - .*ITA.*
  reject_excluding:
    - .*S[0-9][0-9]E[0-9][0-9]\..*\.1080p\..*
transmission:
  host: <IP_ADDRESS>
  magnetization_timeout: 30
  password: transmission
  path: /media/transmission/series/{{ series_name | replace(" ", ".") }}/season{{
    series_season }}
  port: 9091
  ratio: 30
  skip_files:
    - .*.exe
    - RARBG.txt
  username: ***************

Log:

(click to expand)
2023-02-25 21:34:09 VERBOSE  task          trakt_tv_to_transmission ACCEPTED: `The.Ark.S01E02.Like.It.Touched.the.Sun.1080p.AMZN.WEBRip.DDP5.1.x264-NTb [eztv]` by accept_all plugin
2023-02-25 21:34:09 VERBOSE  task          trakt_tv_to_transmission ACCEPTED: `The.Ark.S01E01.Everyone.Wanted.to.Be.on.This.Ship.1080p.AMZN.WEBRip.DDP5.1.x264-NTb [eztv]` by accept_all plugin
2023-02-25 21:34:09 VERBOSE  details       trakt_tv_to_transmission Summary - Accepted: 94 (Rejected: 702 Undecided: 0 Failed: 0)
2023-02-25 21:34:09 VERBOSE  task          trakt_tv_to_transmission REJECTED: `La.Brea.S02E12.The.Swarm.1080p.AMZN.WEBRip.DDP5.1.x264-NTb [TGx]` by seen_info_hash plugin because already accepted torrent with this infohash once for this task
2023-02-25 21:34:09 VERBOSE  task          trakt_tv_to_transmission REJECTED: `La.Brea.S02E12.The.Swarm.1080p.AMZN.WEBRip.DDP5.1.x264-NTb [eztv]` by seen_info_hash plugin because already accepted torrent with this infohash once for this task
2023-02-25 21:34:12 VERBOSE  transmission  trakt_tv_to_transmission Moving Godfather.of.Harlem.S03E05.Angel.of.Death.1080p.AMZN.WEB-DL.DDP5.1.H.264-NTb[eztv.re].mkv to "/media/transmission/series/Godfather.Of.Harlem/season3"
2023-02-25 21:34:15 CRITICAL task          trakt_tv_to_transmission BUG: Unhandled error in plugin transmission: 'Torrent' object has no attribute 'totalSize'
Traceback (most recent call last):

  File "/usr/lib/python3.9/threading.py", line 912, in _bootstrap
    self._bootstrap_inner()
    │    └ <function Thread._bootstrap_inner at 0x7f8b5c3430>
    └ <Thread(task_queue, started daemon<PHONE_NUMBER>12)>
  File "/usr/lib/python3.9/threading.py", line 954, in _bootstrap_inner
    self.run()
    │    └ <function Thread.run at 0x7f8b5c3160>
    └ <Thread(task_queue, started daemon<PHONE_NUMBER>12)>
  File "/usr/lib/python3.9/threading.py", line 892, in run
    self._target(*self._args, **self._kwargs)
    │    │        │    │        │    └ {}
    │    │        │    │        └ <Thread(task_queue, started daemon<PHONE_NUMBER>12)>
    │    │        │    └ ()
    │    │        └ <Thread(task_queue, started daemon<PHONE_NUMBER>12)>
    │    └ <bound method TaskQueue.run of <flexget.task_queue.TaskQueue object at 0x7f862d7370>>
    └ <Thread(task_queue, started daemon<PHONE_NUMBER>12)>
  File "/home/pi/flexget/lib/python3.9/site-packages/flexget/task_queue.py", line 47, in run
    self.current_task.execute()
    │    │            └ <function Task.execute at 0x7f88fc0f70>
    │    └ <flexget.task.Task object at 0x7f85fb5460>
    └ <flexget.task_queue.TaskQueue object at 0x7f862d7370>
  File "/home/pi/flexget/lib/python3.9/site-packages/flexget/task.py", line 87, in wrapper
    return func(self, *args, **kw)
           │    │      │       └ {}
           │    │      └ ()
           │    └ <flexget.task.Task object at 0x7f85fb5460>
           └ <function Task.execute at 0x7f88fc0ee0>
  File "/home/pi/flexget/lib/python3.9/site-packages/flexget/task.py", line 727, in execute
    self._execute()
    │    └ <function Task._execute at 0x7f88fc0e50>
    └ <flexget.task.Task object at 0x7f85fb5460>
  File "/home/pi/flexget/lib/python3.9/site-packages/flexget/task.py", line 696, in _execute
    self.__run_task_phase(phase)
    │                     └ 'output'
    └ <flexget.task.Task object at 0x7f85fb5460>
  File "/home/pi/flexget/lib/python3.9/site-packages/flexget/task.py", line 514, in __run_task_phase
    response = self.__run_plugin(plugin, phase, args)
               │                 │       │      └ (<flexget.task.Task object at 0x7f85fb5460>, {'host': '<IP_ADDRESS>', 'port': 9091, 'username': '******', 'password': ...
               │                 │       └ 'output'
               │                 └ <PluginInfo(name=transmission)>
               └ <flexget.task.Task object at 0x7f85fb5460>
> File "/home/pi/flexget/lib/python3.9/site-packages/flexget/task.py", line 547, in __run_plugin
    result = method(*args, **kwargs)
             │       │       └ {}
             │       └ (<flexget.task.Task object at 0x7f85fb5460>, {'host': '<IP_ADDRESS>', 'port': 9091, 'username': '*********', 'password': ...
             └ <Event(name=plugin.transmission.output,func=on_task_output,priority=135)>
  File "/home/pi/flexget/lib/python3.9/site-packages/flexget/event.py", line 20, in __call__
    return self.func(*args, **kwargs)
           │    │     │       └ {}
           │    │     └ (<flexget.task.Task object at 0x7f85fb5460>, {'host': '<IP_ADDRESS>', 'port': 9091, 'username': '*******', 'password': ...
           │    └ <bound method PluginTransmission.on_task_output of <flexget.plugins.clients.transmission.PluginTransmission object at 0x7f868...
           └ <Event(name=plugin.transmission.output,func=on_task_output,priority=135)>
  File "/home/pi/flexget/lib/python3.9/site-packages/flexget/plugins/clients/transmission.py", line 457, in on_task_output
    total_size = torrent_info.totalSize
                 └ <Torrent 2 "Godfather.of.Harlem.S03E05.Angel.of.Death.1080p.AMZN.WEB-DL.DDP5.1.H.264-NTb[eztv.re].mkv">

AttributeError: 'Torrent' object has no attribute 'totalSize'
2023-02-25 21:34:15 CRITICAL manager       trakt_tv_to_transmission An unexpected crash has occurred. Writing crash report to /home/pi/flexget/crash_report.2<IP_ADDRESS>415957195.log. Please verify you are running the latest version of flexget by using "flexget -V" from CLI or by using version_checker plugin at https://flexget.com/Plugins/version_checker. You are currently using version 3.5.27

Additional information:

FlexGet version:
Python version:
Installation method:
Using daemon (yes/no):
OS and version:
Link to crash log:

We are not yet compatible with the new version of transmission-rpc. There is a workaround in this topic to install a compatible version until we update the code for 4.0.
https://github.com/Flexget/Flexget/discussions/3698

Another related crash log.
Log:

(click to expand)
2023-02-27 20:33:32 DEBUG    task          cleanup-torrents executing cleanup-torrents
2023-02-27 20:33:32 DEBUG    disable       cleanup-torrents Disabled plugins: seen, seen_info_hash
2023-02-27 20:33:32 DEBUG    transmission  cleanup-torrents Connecting to http://transmission:9091/transmission/
2023-02-27 20:33:32 CRITICAL task          cleanup-torrents BUG: Unhandled error in plugin from_transmission: 'Torrent' object has no attribute 'seedRatioMode'
Traceback (most recent call last):

  File "/usr/lib/python3.10/threading.py", line 973, in _bootstrap
    self._bootstrap_inner()
    │    └ <function Thread._bootstrap_inner at 0x7f089dd25870>
    └ <Thread(task_queue, started daemon<PHONE_NUMBER>35736)>
  File "/usr/lib/python3.10/threading.py", line 1016, in _bootstrap_inner
    self.run()
    │    └ <function Thread.run at 0x7f089dd255a0>
    └ <Thread(task_queue, started daemon<PHONE_NUMBER>35736)>
  File "/usr/lib/python3.10/threading.py", line 953, in run
    self._target(*self._args, **self._kwargs)
    │    │        │    │        │    └ {}
    │    │        │    │        └ <Thread(task_queue, started daemon<PHONE_NUMBER>35736)>
    │    │        │    └ ()
    │    │        └ <Thread(task_queue, started daemon<PHONE_NUMBER>35736)>
    │    └ <bound method TaskQueue.run of <flexget.task_queue.TaskQueue object at 0x7f0896ba2b60>>
    └ <Thread(task_queue, started daemon<PHONE_NUMBER>35736)>
  File "/usr/lib/python3.10/site-packages/flexget/task_queue.py", line 47, in run
    self.current_task.execute()
    │    │            └ <function Task.execute at 0x7f089aa32e60>
    │    └ <flexget.task.Task object at 0x7f0889e52590>
    └ <flexget.task_queue.TaskQueue object at 0x7f0896ba2b60>
  File "/usr/lib/python3.10/site-packages/flexget/task.py", line 87, in wrapper
    return func(self, *args, **kw)
           │    │      │       └ {}
           │    │      └ ()
           │    └ <flexget.task.Task object at 0x7f0889e52590>
           └ <function Task.execute at 0x7f089aa32dd0>
  File "/usr/lib/python3.10/site-packages/flexget/task.py", line 727, in execute
    self._execute()
    │    └ <function Task._execute at 0x7f089aa32d40>
    └ <flexget.task.Task object at 0x7f0889e52590>
  File "/usr/lib/python3.10/site-packages/flexget/task.py", line 696, in _execute
    self.__run_task_phase(phase)
    │                     └ 'input'
    └ <flexget.task.Task object at 0x7f0889e52590>
  File "/usr/lib/python3.10/site-packages/flexget/task.py", line 514, in __run_task_phase
    response = self.__run_plugin(plugin, phase, args)
               │                 │       │      └ (<flexget.task.Task object at 0x7f0889e52590>, {'host': 'transmission', 'port': 9091, 'username': 'xxx', 'password': 'xxx...
               │                 │       └ 'input'
               │                 └ <PluginInfo(name=from_transmission)>
               └ <flexget.task.Task object at 0x7f0889e52590>
> File "/usr/lib/python3.10/site-packages/flexget/task.py", line 547, in __run_plugin
    result = method(*args, **kwargs)
             │       │       └ {}
             │       └ (<flexget.task.Task object at 0x7f0889e52590>, {'host': 'transmission', 'port': 9091, 'username': 'xxx', 'password': 'xxx...
             └ <Event(name=plugin.from_transmission.input,func=on_task_input,priority=128)>
  File "/usr/lib/python3.10/site-packages/flexget/event.py", line 20, in __call__
    return self.func(*args, **kwargs)
           │    │     │       └ {}
           │    │     └ (<flexget.task.Task object at 0x7f0889e52590>, {'host': 'transmission', 'port': 9091, 'username': 'dl', 'password': 'torrents...
           │    └ <bound method PluginTransmissionInput.on_task_input of <flexget.plugins.clients.transmission.PluginTransmissionInput object a...
           └ <Event(name=plugin.from_transmission.input,func=on_task_input,priority=128)>
  File "/usr/lib/python3.10/site-packages/flexget/plugins/clients/transmission.py", line 192, in on_task_input
    seed_ratio_ok, idle_limit_ok = self.check_seed_limits(torrent, session)
                                   │    │                 │        └ <transmission_rpc.session.Session object at 0x7f08946452a0>
                                   │    │                 └ <Torrent 1 "Alert.Missing.Persons.Unit.S01E08.1080p.WEB.H264-CAKES">
                                   │    └ <function TransmissionBase.check_seed_limits at 0x7f0899f417e0>
                                   └ <flexget.plugins.clients.transmission.PluginTransmissionInput object at 0x7f0896cdfaf0>
  File "/usr/lib/python3.10/site-packages/flexget/plugins/clients/transmission.py", line 114, in check_seed_limits
    if torrent.seedRatioMode == 1:  # use torrent's own seed ratio limit
       └ <Torrent 1 "Alert.Missing.Persons.Unit.S01E08.1080p.WEB.H264-CAKES">

AttributeError: 'Torrent' object has no attribute 'seedRatioMode'
Traceback (most recent call last):
  File "/usr/lib/python3.10/site-packages/flexget/task.py", line 547, in __run_plugin
    result = method(*args, **kwargs)
  File "/usr/lib/python3.10/site-packages/flexget/event.py", line 20, in __call__
    return self.func(*args, **kwargs)
  File "/usr/lib/python3.10/site-packages/flexget/plugins/clients/transmission.py", line 192, in on_task_input
    seed_ratio_ok, idle_limit_ok = self.check_seed_limits(torrent, session)
  File "/usr/lib/python3.10/site-packages/flexget/plugins/clients/transmission.py", line 114, in check_seed_limits
    if torrent.seedRatioMode == 1:  # use torrent's own seed ratio limit
AttributeError: 'Torrent' object has no attribute 'seedRatioMode'

I think this error has to do with the label functionality added in 3.5.27.  Looks like there are erroneous commas in the code.  I rolled back to 3.5.25 and everything works again, despite being on the newest version of Transmission RPC.

I think this error has to do with the label functionality added in 3.5.27. Looks like there are erroneous commas in the code. I rolled back to 3.5.25 and everything works again, despite being on the newest version of Transmission RPC.

I tried Flexget 3.5.25, transmission-rpc 4.1 and transmission 4.01, and can confirm the above.

Another related crash log.
Log:
(click to expand)

I got this too, but not everytime.

I tried flexget 3.5.25  with transmission-rpc 4.1.2 and 4.0.0  and it still fails. I had to downgrade to 3.4.1 for it to work.

` flexgetcompose | 2023-03-01 17:04:08 CRITICAL task          tvshows         BUG: Unhandled error in plugin transmission: 'Torrent' object has no attribute 'totalSize'
flexgetcompose | Traceback (most recent call last):
flexgetcompose |
flexgetcompose |   File "/usr/lib/python3.10/threading.py", line 973, in _bootstrap
flexgetcompose |     self._bootstrap_inner()
flexgetcompose |     │    └ <function Thread._bootstrap_inner at 0x7fdc86fbd870>
flexgetcompose |     └ <Thread(task_queue, started daemon<PHONE_NUMBER>70656)>
flexgetcompose |   File "/usr/lib/python3.10/threading.py", line 1016, in _bootstrap_inner
flexgetcompose |     self.run()
flexgetcompose |     │    └ <function Thread.run at 0x7fdc86fbd5a0>
flexgetcompose |     └ <Thread(task_queue, started daemon<PHONE_NUMBER>70656)>
flexgetcompose |   File "/usr/lib/python3.10/threading.py", line 953, in run
flexgetcompose |     self._target(*self._args, **self._kwargs)
flexgetcompose |     │    │        │    │        │    └ {}
flexgetcompose |     │    │        │    │        └ <Thread(task_queue, started daemon<PHONE_NUMBER>70656)>
flexgetcompose |     │    │        │    └ ()
flexgetcompose |     │    │        └ <Thread(task_queue, started daemon<PHONE_NUMBER>70656)>
flexgetcompose |     │    └ <bound method TaskQueue.run of <flexget.task_queue.TaskQueue object at 0x7fdc8102b5b0>>
flexgetcompose |     └ <Thread(task_queue, started daemon<PHONE_NUMBER>70656)>
flexgetcompose |   File "/home/flexget/.local/lib/python3.10/site-packages/flexget/task_queue.py", line 47, in run
flexgetcompose |     self.current_task.execute()
flexgetcompose |     │    │            └ <function Task.execute at 0x7fdc83cf0a60>
flexgetcompose |     │    └ <flexget.task.Task object at 0x7fdc8042a950>
flexgetcompose |     └ <flexget.task_queue.TaskQueue object at 0x7fdc8102b5b0>
flexgetcompose |   File "/home/flexget/.local/lib/python3.10/site-packages/flexget/task.py", line 87, in wrapper
flexgetcompose |     return func(self, *args, **kw)
flexgetcompose |            │    │      │       └ {}
flexgetcompose |            │    │      └ ()
flexgetcompose |            │    └ <flexget.task.Task object at 0x7fdc8042a950>
flexgetcompose |            └ <function Task.execute at 0x7fdc83cf09d0>
flexgetcompose |   File "/home/flexget/.local/lib/python3.10/site-packages/flexget/task.py", line 727, in execute
flexgetcompose |     self._execute()
flexgetcompose |     │    └ <function Task._execute at 0x7fdc83cf0940>
flexgetcompose |     └ <flexget.task.Task object at 0x7fdc8042a950>
flexgetcompose |   File "/home/flexget/.local/lib/python3.10/site-packages/flexget/task.py", line 696, in _execute
flexgetcompose |     self.__run_task_phase(phase)
flexgetcompose |     │                     └ 'output'
flexgetcompose |     └ <flexget.task.Task object at 0x7fdc8042a950>
flexgetcompose |   File "/home/flexget/.local/lib/python3.10/site-packages/flexget/task.py", line 514, in __run_task_phase
flexgetcompose |     response = self.__run_plugin(plugin, phase, args)
flexgetcompose |                │                 │       │      └ (<flexget.task.Task object at 0x7fdc8042a950>, {'path': '/plexmedia/TV', 'host': '<IP_ADDRESS>', 'port': 9091, 'skip_files'...
flexgetcompose |                │                 │       └ 'output'
flexgetcompose |                │                 └ <PluginInfo(name=transmission)>
flexgetcompose |                └ <flexget.task.Task object at 0x7fdc8042a950>
flexgetcompose | > File "/home/flexget/.local/lib/python3.10/site-packages/flexget/task.py", line 547, in __run_plugin
flexgetcompose |     result = method(*args, **kwargs)
flexgetcompose |              │       │       └ {}
flexgetcompose |              │       └ (<flexget.task.Task object at 0x7fdc8042a950>, {'path': '/plexmedia/TV', 'host': '<IP_ADDRESS>', 'port': 9091, 'skip_files'...
flexgetcompose |              └ <Event(name=plugin.transmission.output,func=on_task_output,priority=135)>
flexgetcompose |   File "/home/flexget/.local/lib/python3.10/site-packages/flexget/event.py", line 20, in call
flexgetcompose |     return self.func(*args, **kwargs)
flexgetcompose |            │    │     │       └ {}
flexgetcompose |            │    │     └ (<flexget.task.Task object at 0x7fdc8042a950>, {'path': '/plexmedia/TV', 'host': '<IP_ADDRESS>', 'port': 9091, 'skip_files'...
flexgetcompose |            │    └ <bound method PluginTransmission.on_task_output of <flexget.plugins.clients.transmission.PluginTransmission object at 0x7fdc8...
flexgetcompose |            └ <Event(name=plugin.transmission.output,func=on_task_output,priority=135)>
flexgetcompose |   File "/home/flexget/.local/lib/python3.10/site-packages/flexget/plugins/clients/transmission.py", line 455, in on_task_output
flexgetcompose |     total_size = torrent_info.totalSize
flexgetcompose |                  └ <Torrent 24 "REDACTED">
flexgetcompose |
flexgetcompose | AttributeError: 'Torrent' object has no attribute 'totalSize'
flexgetcompose | 2023-03-01 17:04:08 CRITICAL manager       tvshows         An unexpected crash has occurred. Writing crash report to /home/flexget/.flexget/crash_report.2<IP_ADDRESS>408543911.log. Please verify you are running the latest version of flexget by using "flexget -V" from CLI or by using version_checker plugin at https://flexget.com/Plugins/version_checker. You are currently using version 3.5.25
flexgetcompose | 2023-03-01 17:04:08 WARNING  task          tvshows         Aborting task (plugin: transmission)

For it me was seedRatioMode that caused the crash. I am seeing this both when using

flexget 3.5.29 + transmission-rpc 4.1.2
flexget 3.5.25 + transmission-rpc 4.1.2

2023-03-07 19:08:51 CRITICAL task          rss_stale       BUG: Unhandled error in plugin from_transmission: 'Torrent' object has no attribute 'seedRatioMode'
Traceback (most recent call last):

  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/threading.py", line 973, in _bootstrap
    self._bootstrap_inner()
    │    └ <function Thread._bootstrap_inner at 0x7f09cef230a0>
    └ <Thread(task_queue, started daemon<PHONE_NUMBER>90496)>
  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/threading.py", line 1016, in _bootstrap_inner
    self.run()
    │    └ <function Thread.run at 0x7f09cef22dd0>
    └ <Thread(task_queue, started daemon<PHONE_NUMBER>90496)>
  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/threading.py", line 953, in run
    self._target(*self._args, **self._kwargs)
    │    │        │    │        │    └ {}
    │    │        │    │        └ <Thread(task_queue, started daemon<PHONE_NUMBER>90496)>
    │    │        │    └ ()
    │    │        └ <Thread(task_queue, started daemon<PHONE_NUMBER>90496)>
    │    └ <bound method TaskQueue.run of <flexget.task_queue.TaskQueue object at 0x7f09c8a73610>>
    └ <Thread(task_queue, started daemon<PHONE_NUMBER>90496)>
  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/site-packages/flexget/task_queue.py", line 47, in run
    self.current_task.execute()
    │    │            └ <function Task.execute at 0x7f09cb9b56c0>
    │    └ <flexget.task.Task object at 0x7f09c8780f40>
    └ <flexget.task_queue.TaskQueue object at 0x7f09c8a73610>
  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/site-packages/flexget/task.py", line 87, in wrapper
    return func(self, *args, **kw)
           │    │      │       └ {}
           │    │      └ ()
           │    └ <flexget.task.Task object at 0x7f09c8780f40>
           └ <function Task.execute at 0x7f09cb9b5630>
  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/site-packages/flexget/task.py", line 727, in execute
    self._execute()
    │    └ <function Task._execute at 0x7f09cb9b55a0>
    └ <flexget.task.Task object at 0x7f09c8780f40>
  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/site-packages/flexget/task.py", line 696, in _execute
    self.__run_task_phase(phase)
    │                     └ 'input'
    └ <flexget.task.Task object at 0x7f09c8780f40>
  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/site-packages/flexget/task.py", line 514, in __run_task_phase
    response = self.__run_plugin(plugin, phase, args)
               │                 │       │      └ (<flexget.task.Task object at 0x7f09c8780f40>, {'only_complete': False, 'host': 'localhost', 'port': 9091, 'enabled': True, '...
               │                 │       └ 'input'
               │                 └ <PluginInfo(name=from_transmission)>
               └ <flexget.task.Task object at 0x7f09c8780f40>
> File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/site-packages/flexget/task.py", line 547, in __run_plugin
    result = method(*args, **kwargs)
             │       │       └ {}
             │       └ (<flexget.task.Task object at 0x7f09c8780f40>, {'only_complete': False, 'host': 'localhost', 'port': 9091, 'enabled': True, '...
             └ <Event(name=plugin.from_transmission.input,func=on_task_input,priority=128)>
  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/site-packages/flexget/event.py", line 20, in __call__
    return self.func(*args, **kwargs)
           │    │     │       └ {}
           │    │     └ (<flexget.task.Task object at 0x7f09c8780f40>, {'only_complete': False, 'host': 'localhost', 'port': 9091, 'enabled': True, '...
           │    └ <bound method PluginTransmissionInput.on_task_input of <flexget.plugins.clients.transmission.PluginTransmissionInput object a...
           └ <Event(name=plugin.from_transmission.input,func=on_task_input,priority=128)>
  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/site-packages/flexget/plugins/clients/transmission.py", line 192, in on_task_input
    seed_ratio_ok, idle_limit_ok = self.check_seed_limits(torrent, session)
                                   │    │                 │        └ <transmission_rpc.session.Session object at 0x7f09c883f970>
                                   │    │                 └ <Torrent 94 "REDACTED">
                                   │    └ <function TransmissionBase.check_seed_limits at 0x7f09ca73b010>
                                   └ <flexget.plugins.clients.transmission.PluginTransmissionInput object at 0x7f09c9dc1510>
  File "/home/flexget/anaconda3/envs/flexget/lib/python3.10/site-packages/flexget/plugins/clients/transmission.py", line 114, in check_seed_limits
    if torrent.seedRatioMode == 1:  # use torrent's own seed ratio limit
       └ <Torrent 94 "REDACTED">

AttributeError: 'Torrent' object has no attribute 'seedRatioMode'

I don't believe this is anything to do with flexget or transmission version. All of these errors are to do with changes in transmission-rpc. I had a brief look, and it appears the things we need to update would still let flexget work with both transmission-rpc 3.x and 4.x versions. It's just a few attributes that switched from camelCase to snake_case.

I don't believe this is anything to do with flexget or transmission version. All of these errors are to do with changes in transmission-rpc. I had a brief look, and it appears the things we need to update would still let flexget work with both transmission-rpc 3.x and 4.x versions. It's just a few attributes that switched from camelCase to snake_case.

seedRatioMode is always a snake_case attribute on Torrent object...
https://github.com/trim21/transmission-rpc/blob/v3.3.0/transmission_rpc/torrent.py#L540

I can help upgrading to transmission-rpc v4 after you drop python3.7(EOL 06 Dec 2022) 🤔


Wait for line callbacks to finish before finishing process

We have a potential race condition when uploading header times to BK. I believe the follow backtrace is saying: "You tried to call .Add() on a wait group that is already waiting".
Looking a the stack trace [HeaderTimesStreamer] Waiting for all the lines to be scanned is called, then another header time is found, so I believe the line callbacks are still being fired even after the process has finished.
This change ensures that all the line callbacks have fired before finishing the process. Even if the line callback in itself fires off another go-routine that's ok, because that code usually has it's own waiters setup.
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: 2016-11-24 23:42:31 DEBUG  [LineScanner] Encountered EOF
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: 2016-11-24 23:42:31 DEBUG  [LineScanner] Finished
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: 2016-11-24 23:42:31 INFO   Process with PID: 29576 finished with Exit Status: 0
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: 2016-11-24 23:42:31 DEBUG  [Process] Waiting for routines to finish
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: 2016-11-24 23:42:31 DEBUG  [Process] PTY has finished being copied to the buffer
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: 2016-11-24 23:42:31 DEBUG  [HeaderTimesStreamer] Waiting for all the lines to be scanned
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: 2016-11-24 23:42:31 DEBUG  [HeaderTimesStreamer] Found header "\x1b[0m~~~ Running global post-command hook"
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: 2016-11-24 23:42:31 DEBUG  [HeaderTimesStreamer] Found header "~~~ Running local post-command hook"
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: panic: sync: WaitGroup is reused before previous Wait has returned
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: goroutine 1 [running]:
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: panic(0x784440, 0xc420407c80)
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /usr/local/go/src/runtime/panic.go:500 +0x1a1
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: sync.(*WaitGroup).Wait(0xc4202c0878)
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /usr/local/go/src/sync/waitgroup.go:133 +0xfe
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: github.com/buildkite/agent/agent.(*HeaderTimesStreamer).Stop(0xc4202c0840)
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /go/src/github.com/buildkite/agent/agent/header_times_streamer.go:127 +0x69
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: github.com/buildkite/agent/agent.(*JobRunner).Run(0xc4202c07e0, 0x0, 0xc420405920)
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /go/src/github.com/buildkite/agent/agent/job_runner.go:109 +0x250
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: github.com/buildkite/agent/agent.(*AgentWorker).Ping(0xc42015c4e0)
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /go/src/github.com/buildkite/agent/agent/agent_worker.go:273 +0x4b5
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: github.com/buildkite/agent/agent.(*AgentWorker).Start(0xc42015c4e0, 0xc4203fd760, 0x0)
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /go/src/github.com/buildkite/agent/agent/agent_worker.go:85 +0x18b
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: github.com/buildkite/agent/agent.(*AgentPool).Start(0xc420052680, 0xc42000cae0, 0xc42010e1a0)
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /go/src/github.com/buildkite/agent/agent/agent_pool.go:81 +0x5bf
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: github.com/buildkite/agent/clicommand.glob..func1(0xc420086580)
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /go/src/github.com/buildkite/agent/clicommand/agent_start.go:230 +0x3cf
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: github.com/buildkite/agent/vendor/github.com/codegangsta/cli.Command.Run(0x80e4d5, 0x5, 0x0, 0x0, 0x81730d, 0x18, 0x827fa4, 0x1c1, 0x0, 0x0, ...)
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /go/src/github.com/buildkite/agent/vendor/github.com/codegangsta/cli/command.go:101 +0x6e9
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: github.com/buildkite/agent/vendor/github.com/codegangsta/cli.(*App).Run(0xc42010a000, 0xc42000a120, 0x2, 0x2, 0x0, 0x0)
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /go/src/github.com/buildkite/agent/vendor/github.com/codegangsta/cli/app.go:125 +0x64b
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: main.main()
Nov 24 23:42:31 buildkite-agent-b06ec88b buildkite-agent: /go/src/github.com/buildkite/agent/main.go:100 +0x401
Nov 24 23:42:31 buildkite-agent-b06ec88b systemd: buildkite-agent.service: main process exited, code=exited, status=2/INVALIDARGUMENT
Nov 24 23:42:31 buildkite-agent-b06ec88b systemd: Unit buildkite-agent.service entered failed state.
Nov 24 23:42:31 buildkite-agent-b06ec88b systemd: buildkite-agent.service failed.
Nov 24 23:42:36 buildkite-agent-b06ec88b systemd: buildkite-agent.service holdoff time over, scheduling restart.

@sj26 would you be able to review this for me when you get a chance? I think this fix should work, but it's a little gnarly.

I think maybe your lineCallbackWaitGroup.Wait() should go before the waitGroup.Done() within the LineScanner on line 179, otherwise we're skipping another timeout.
If io.Copy is never returning from some builds and we're seeing some goroutines never finish / reach waitGroup.Done then we probably also probably seeing memory leaks...

There are similar races in the start callback, too...
Perhaps instead of callbacks we should be using channels?

I have no idea how to channel :P if you can think of a better way go for it!
Can you see the problem? It was a little tricky to get my head around...

@sj26 I've made that suggested change!


Very unstable JBD_BLE bluetooth connection on version 1.1.20240212dev

Describe the bug
After upgrading to driver 1.1.20240212dev on the initial reset after installing, everything was working fine but on succesfull resets the system has become very unstable with continuous connects and disconnects of the BMSs.
I have cerbo gx with an external Asus BT-500 Bluetooth dongle (one of the aproved ones).
How to reproduce
Just install the dev version and perform 4 or 5 reboots .
Expected behavior
Was very stable on my previous version 1.0.20231117dev
Driver version
1.1.20240212dev
Venus OS device type
Cerbo GX
Venus OS version
3.14
BMS type
Smart BMS (LLT, JBD, Overkill Solar)
Cell count
4
Battery count
2
Connection type
Bluetooth
Config file
[DEFAULT]

LOGGING = DEBUG
MAX_BATTERY_CHARGE_CURRENT = 150.0
MAX_BATTERY_DISCHARGE_CURRENT = 150.0
MIN_CELL_VOLTAGE   = 3.000
MAX_CELL_VOLTAGE   = 3.600
FLOAT_CELL_VOLTAGE = 3.400
;BLUETOOTH_BMS = LltJbd_Ble A5:C2:37:05:95:9E, LltJbd_Ble A5:C2:37:05:95:B6
BLUETOOTH_BMS = LltJbd_Ble A5:C2:37:05:95:B6
BLUETOOTH_USE_USB = True

; --------- SOC reset voltage ---------
; Description: May be needed to reset the SoC to 100% once in a while for some BMS, because of SoC drift.
;              Specify the cell voltage where the SoC should be reset to 100% by the BMS.
;                - JKBMS: SoC is reset to 100% if one cell reaches OVP (over voltage protection) voltage
;              As you have to adopt this value to your system, I reccomend to start with
;              OVP voltage - 0.030 (see Example).
;                - Try to increase (add) by 0.005 in steps, if the system does not switch to float mode, even if
;                  the target voltage SOC_RESET_VOLTAGE * CELL_COUNT is reached.
;                - Try to decrease (lower) by 0.005 in steps, if the system hits the OVP too fast, before all
;                  cells could be balanced and the system goes into protection mode multiple times.
; Example: If OVP is 3.650, then start with 3.620 and increase/decrease by 0.005
; Note: The value has to be higher as the MAX_CELL_VOLTAGE
SOC_RESET_VOLTAGE  = 3.620
; Specify after how many days the soc reset voltage should be reached again
; The timer is reset when the soc reset voltage is reached
; Leave empty if you don't want to use this
; Example: Value is set to 15
; day 1: soc reset reached once
; day 16: soc reset reached twice
; day 31: soc reset not reached since it's very cloudy
; day 34: soc reset reached since the sun came out
; day 49: soc reset reached again, since last time it took 3 days to reach soc reset voltage
SOC_RESET_AFTER_DAYS =

; --------- Charge mode ---------
; Choose the mode for voltage / current limitations (True / False)
; False is a step mode: This is the default with limitations on hard boundary steps
; True is a linear mode:
;     For CCL and DCL the values between the steps are calculated for smoother values (by WaldemarFech)
;     For CVL max battery voltage is calculated dynamically in order that the max cell voltage is not exceeded
LINEAR_LIMITATION_ENABLE = False

; Specify in seconds how often the linear values should be recalculated
LINEAR_RECALCULATION_EVERY = 120
; Specify in percent when the linear values should be recalculated immediately
; Example: 5 for a immediate change, when the value changes by more than 5%
LINEAR_RECALCULATION_ON_PERC_CHANGE = 5

; --------- Charge Voltage limitation (affecting CVL) ---------
; Description: Limit max charging voltage (MAX_CELL_VOLTAGE * cell count), switch from max voltage to float
;              voltage (FLOAT_CELL_VOLTAGE * cell count) and back
;     False: Max charging voltage is always kept
;     True: Max charging voltage is reduced based on charge mode
;         Step mode: After max voltage is reached for MAX_VOLTAGE_TIME_SEC it switches to float voltage. After
;                    SoC is below SOC_LEVEL_TO_RESET_VOLTAGE_LIMIT it switches back to max voltage.
;         Linear mode: After max voltage is reachend and cell voltage difference is smaller or equal to
;                      CELL_VOLTAGE_DIFF_KEEP_MAX_VOLTAGE_UNTIL it switches to float voltage after 300 (fixed)
;                      additional seconds.
;                      After cell voltage difference is greater or equal to CELL_VOLTAGE_DIFF_TO_RESET_VOLTAGE_LIMIT
;                      OR
;                      SoC is below SOC_LEVEL_TO_RESET_VOLTAGE_LIMIT
;                      it switches back to max voltage.
; Example: The battery reached max voltage of 55.2V and hold it for 900 seconds, the the CVL is switched to
;          float voltage of 53.6V to don't stress the batteries. Allow max voltage of 55.2V again, if SoC is
;          once below 80%
;          OR
;          The battery reached max voltage of 55.2V and the max cell difference is 0.010V, then switch to float
;          voltage of 53.6V after 300 additional seconds to don't stress the batteries. Allow max voltage of
;          55.2V again if max cell difference is above 0.080V or SoC below 80%.
; Charge voltage control management enable (True/False).
CVCM_ENABLE = True

; -- CVL reset based on cell voltage diff (linear mode)
; Specify cell voltage diff where CVL limit is kept until diff is equal or lower
CELL_VOLTAGE_DIFF_KEEP_MAX_VOLTAGE_UNTIL = 0.010
; Specify cell voltage diff where CVL limit is reset to max voltage, if value get above
; the cells are considered as imbalanced, if the cell diff exceeds 5% of the nominal cell voltage
; e.g. 3.2 V * 5 / 100 = 0.160 V
CELL_VOLTAGE_DIFF_TO_RESET_VOLTAGE_LIMIT = 0.080

; -- CVL reset based on SoC option (step mode & linear mode)
; Specify how long the max voltage should be kept
;     Step mode: If reached then switch to float voltage
;     Linear mode: If cells are balanced keep max voltage for further MAX_VOLTAGE_TIME_SEC seconds
MAX_VOLTAGE_TIME_SEC = 900
; Specify SoC where CVL limit is reset to max voltage
;     Step mode: If SoC gets below
;     Linear mode: If cells are unbalanced or if SoC gets below
SOC_LEVEL_TO_RESET_VOLTAGE_LIMIT = 80

; --------- Cell Voltage Current limitation (affecting CCL/DCL) ---------
; Description: Maximal charge / discharge current will be in-/decreased depending on min and max cell voltages
; Example: 18 cells * 3.55V/cell = 63.9V max charge voltage
;          18 cells * 2.70V/cell = 48.6V min discharge voltage
;          But in reality not all cells reach the same voltage at the same time. The (dis)charge current
;          will be (in-/)decreased, if even ONE SINGLE BATTERY CELL reaches the limits

; Charge current control management referring to cell-voltage enable (True/False).
CCCM_CV_ENABLE = True
; Discharge current control management referring to cell-voltage enable (True/False).
DCCM_CV_ENABLE = False

; Set steps to reduce battery current
; The current will be changed linear between those steps if LINEAR_LIMITATION_ENABLE is set to True
CELL_VOLTAGES_WHILE_CHARGING   = 3.61, 3.55, 3.50, 3.45
MAX_CHARGE_CURRENT_CV_FRACTION =    0, 0.05,  0.5,   1

CELL_VOLTAGES_WHILE_DISCHARGING   = 2.70, 2.80, 2.90, 3.10
MAX_DISCHARGE_CURRENT_CV_FRACTION =    0,  0.1,  0.5,    1

; --------- Temperature limitation (affecting CCL/DCL) ---------
; Description: Maximal charge / discharge current will be in-/decreased depending on temperature
; Example: The temperature limit will be monitored to control the currents. If there are two temperature senors,
;          then the worst case will be calculated and the more secure lower current will be set.
; Charge current control management referring to temperature enable (True/False).
CCCM_T_ENABLE = False
; Charge current control management referring to temperature enable (True/False).
DCCM_T_ENABLE = False

; Set steps to reduce battery current
; Valores exactos obtenidos de CATL. The current will be changed linear between those steps if LINEAR_LIMITATION_ENABLE is set to True
TEMPERATURE_LIMITS_WHILE_CHARGING = 0,   2,     5,    10,    15,20, 35, 40,  55,  60,  65
MAX_CHARGE_CURRENT_T_FRACTION     = 0, 0.116, 0.116, 0.372, 0.5, 1, 1, 0.8, 0,5, 0.279, 0

TEMPERATURE_LIMITS_WHILE_DISCHARGING = -20,   0,   5,  10, 15, 45, 55
MAX_DISCHARGE_CURRENT_T_FRACTION     =   0, 0.2, 0.3, 0.4,  1,  1,  0

; --------- SOC limitation (affecting CCL/DCL) ---------
; Description: Maximal charge / discharge current will be increased / decreased depending on State of Charge,
;              see CC_SOC_LIMIT1 etc.
; Example: The SoC limit will be monitored to control the currents.
; Charge current control management enable (True/False).
CCCM_SOC_ENABLE = False
; Discharge current control management enable (True/False).
DCCM_SOC_ENABLE = False

; Charge current SoC limits
CC_SOC_LIMIT1 = 98
CC_SOC_LIMIT2 = 95
CC_SOC_LIMIT3 = 91

; Charge current limits
CC_CURRENT_LIMIT1_FRACTION = 0.1
CC_CURRENT_LIMIT2_FRACTION = 0.3
CC_CURRENT_LIMIT3_FRACTION = 0.5

; Discharge current SoC limits
DC_SOC_LIMIT1 = 10
DC_SOC_LIMIT2 = 20
DC_SOC_LIMIT3 = 30

; Discharge current limits
DC_CURRENT_LIMIT1_FRACTION = 0.1
DC_CURRENT_LIMIT2_FRACTION = 0.3
DC_CURRENT_LIMIT3_FRACTION = 0.5

; --------- Time-To-Go ---------
; Description: Calculates the time to go shown in the GUI
;              Recalculation is done based on TIME_TO_SOC_RECALCULATE_EVERY
TIME_TO_GO_ENABLE = True

; --------- Time-To-Soc ---------
; Description: Calculates the time to a specific SoC
; Example: TIME_TO_SOC_POINTS = 50, 25, 15, 0
;          6h 24m remaining until 50% SoC
;          17h 36m remaining until 25% SoC
;          22h 5m remaining until 15% SoC
;          28h 48m remaining until 0% SoC
; Set of SoC percentages to report on dbus and MQTT. The more you specify the more it will impact system performance.
; [Valid values 0-100, comma separated list. More that 20 intervals are not recommended]
; Example: TIME_TO_SOC_POINTS = 100, 95, 90, 85, 75, 50, 25, 20, 10, 0
; Leave empty to disable
TIME_TO_SOC_POINTS = 30, 20, 0
; Specify TimeToSoc value type [Valid values 1, 2, 3]
; 1 Seconds
; 2 Time string <days>d <hours>h <minutes>m <seconds>s
; 3 Both seconds and time string "<seconds> [<days>d <hours>h <minutes>m <seconds>s]"
TIME_TO_SOC_VALUE_TYPE = 2
; Specify in seconds how often the TimeToSoc should be recalculated
; Minimum are 5 seconds to prevent CPU overload
TIME_TO_SOC_RECALCULATE_EVERY = 180
; Include TimeToSoC points when moving away from the SoC point [Valid values True, False]
; These will be as negative time. Disabling this improves performance slightly
TIME_TO_SOC_INC_FROM = False

; Battery temperature
; Specify how the battery temperature is assembled
; 0 Get mean of temperature sensor 1 to sensor 4
; 1 Get only temperature from temperature sensor 1
; 2 Get only temperature from temperature sensor 2
; 3 Get only temperature from temperature sensor 3
; 4 Get only temperature from temperature sensor 4
TEMP_BATTERY = 1

; Temperature sensor 1 name
TEMP_1_NAME = T Celdas

; Select the format of cell data presented on dbus [Valid values 0,1,2,3]
; 0 Do not publish all the cells (only the min/max cell data as used by the default GX)
; 1 Format: /Voltages/Cell (also available for display on Remote Console)
; 2 Format: /Cell/#/Volts
; 3 Both formats 1 and 2
BATTERY_CELL_DATA_FORMAT = 1

; --------- BMS specific settings ---------

; -- LltJbd settings
; SoC low levels
; NOTE: SOC_LOW_WARNING is also used to calculate the Time-To-Go even if you are not using a LltJbd BMS
SOC_LOW_WARNING = 25
SOC_LOW_ALARM   = 20

Relevant log output
==> /data/log/dbus-blebattery.1/current <==
2024-02-13 16:41:19.158193500 INFO:SerialBattery:Test of LltJbd_Ble at A5:C2:37:05:95:B6
2024-02-13 16:41:21.674476500 [CHG] Device A5:C2:37:05:95:B6 RSSI: -60
2024-02-13 16:41:24.173736500 ERROR:SerialBattery:>>> ERROR: Unable to connect with BLE device
2024-02-13 16:41:24.177596500 ERROR:SerialBattery:No BMS found at A5:C2:37:05:95:B6
2024-02-13 16:41:24.178315500 ERROR:SerialBattery:ERROR >>> No battery connection at LltJbd_Ble
2024-02-13 16:41:30.069239500 ERROR:SerialBattery:BleakClient(): Exception occurred: BleakDBusError('org.bluez.Error.Failed', 'Software caused connection abort') of type <class 'bleak.exc.BleakDBusError'> in /opt/victronenergy/dbus-serialbattery/bms/lltjbd_ble.py line #100
2024-02-13 16:41:30.494053500
2024-02-13 16:41:30.496107500 INFO:Bluetooth details
2024-02-13 16:41:30.809781500 Attempting to disconnect from A5:C2:37:05:95:B6
2024-02-13 16:41:30.809791500 [CHG] Device A5:C2:37:05:95:9E RSSI is nil
2024-02-13 16:41:30.809794500 [CHG] Device C5:71:5B:8D:F5:BC RSSI is nil
2024-02-13 16:41:30.809797500 [CHG] Device A5:C2:37:05:95:B6 RSSI is nil
2024-02-13 16:41:30.809800500 [CHG] Device 47:9B:C3:1D:82:B9 RSSI is nil
2024-02-13 16:41:30.809802500 [CHG] Device E9:CC:15:95:BA:68 RSSI is nil
2024-02-13 16:41:30.809805500 [CHG] Device 04:52:C7:B8:5F:6D TxPower is nil
2024-02-13 16:41:30.809927500 [CHG] Device 04:52:C7:B8:5F:6D RSSI is nil
2024-02-13 16:41:30.809931500 [CHG] Device FC:97:F8:5D:A2:EC RSSI is nil
2024-02-13 16:41:30.809934500 [CHG] Controller 08:BF:B8:56:B7:50 Discovering: no
2024-02-13 16:41:30.809937500 Successful disconnected
2024-02-13 16:41:35.974184500 Device A5:C2:37:05:95:B6 (public)
2024-02-13 16:41:35.974194500   Alias: Bateria Serv 2
2024-02-13 16:41:35.974196500   Paired: no
2024-02-13 16:41:35.974197500   Trusted: no
2024-02-13 16:41:35.974199500   Blocked: no
2024-02-13 16:41:35.974200500   Connected: no
2024-02-13 16:41:35.974201500   LegacyPairing: no
2024-02-13 16:41:35.974203500   UUID: Device Information        (0000180a-0000-1000-8000-00805f9b34fb)
2024-02-13 16:41:35.974206500   RSSI: -62
2024-02-13 16:41:35.975081500
2024-02-13 16:41:37.399490500 INFO:SerialBattery:
2024-02-13 16:41:37.400200500 INFO:SerialBattery:Starting dbus-serialbattery
2024-02-13 16:41:37.402258500 INFO:SerialBattery:Venus OS v3.14
2024-02-13 16:41:37.403030500 INFO:SerialBattery:dbus-serialbattery v1.1.20240212dev
2024-02-13 16:41:37.949819500 INFO:SerialBattery:Init of LltJbd_Ble at A5:C2:37:05:95:B6
2024-02-13 16:41:37.950642500 INFO:SerialBattery:Test of LltJbd_Ble at A5:C2:37:05:95:B6
2024-02-13 16:41:42.971792500 ERROR:SerialBattery:>>> ERROR: Unable to connect with BLE device
2024-02-13 16:41:42.975998500 ERROR:SerialBattery:No BMS found at A5:C2:37:05:95:B6
2024-02-13 16:41:42.978327500 ERROR:SerialBattery:ERROR >>> No battery connection at LltJbd_Ble
2024-02-13 16:41:53.162187500 ERROR:SerialBattery:BleakClient(): asyncio.exceptions.TimeoutError: TimeoutError() of type <class 'asyncio.exceptions.TimeoutError'> in /opt/victronenergy/dbus-serialbattery/bms/lltjbd_ble.py line #100
2024-02-13 16:41:53.516470500
2024-02-13 16:41:53.516926500 INFO:Bluetooth details
2024-02-13 16:41:53.595163500 [CHG] Device A5:C2:37:05:95:B6 RSSI: -62
2024-02-13 16:41:53.595175500 [CHG] Device A5:C2:37:05:95:B6 RSSI: -62
2024-02-13 16:41:53.679118500 Attempting to disconnect from A5:C2:37:05:95:B6
2024-02-13 16:41:53.679128500 Successful disconnected
2024-02-13 16:41:58.815020500 Device A5:C2:37:05:95:B6 (public)
2024-02-13 16:41:58.815031500   Alias: Bateria Serv 2
2024-02-13 16:41:58.815033500   Paired: no
2024-02-13 16:41:58.815034500   Trusted: no
2024-02-13 16:41:58.815036500   Blocked: no
2024-02-13 16:41:58.815037500   Connected: no
2024-02-13 16:41:58.815038500   LegacyPairing: no
2024-02-13 16:41:58.815040500   UUID: Device Information        (0000180a-0000-1000-8000-00805f9b34fb)
2024-02-13 16:41:58.815043500   RSSI: -64
2024-02-13 16:41:58.815459500
2024-02-13 16:42:00.248574500 INFO:SerialBattery:
2024-02-13 16:42:00.249700500 INFO:SerialBattery:Starting dbus-serialbattery
2024-02-13 16:42:00.251702500 INFO:SerialBattery:Venus OS v3.14
2024-02-13 16:42:00.252435500 INFO:SerialBattery:dbus-serialbattery v1.1.20240212dev
2024-02-13 16:42:00.798959500 INFO:SerialBattery:Init of LltJbd_Ble at A5:C2:37:05:95:B6
2024-02-13 16:42:00.799354500 INFO:SerialBattery:Test of LltJbd_Ble at A5:C2:37:05:95:B6
2024-02-13 16:42:05.814891500 ERROR:SerialBattery:>>> ERROR: Unable to connect with BLE device
2024-02-13 16:42:05.820013500 ERROR:SerialBattery:No BMS found at A5:C2:37:05:95:B6
2024-02-13 16:42:05.820720500 ERROR:SerialBattery:ERROR >>> No battery connection at LltJbd_Ble
2024-02-13 16:42:07.386446500 INFO:SerialBattery:BLE client disconnected
2024-02-13 16:42:07.394047500 ERROR:SerialBattery:BleakClient(): Exception occurred: BleakError('failed to discover services, device disconnected') of type <class 'bleak.exc.BleakError'> in /opt/victronenergy/dbus-serialbattery/bms/lltjbd_ble.py line #100
2024-02-13 16:42:07.726596500
2024-02-13 16:42:07.727371500 INFO:Bluetooth details
2024-02-13 16:42:07.792414500 [CHG] Device A5:C2:37:05:95:B6 RSSI: -62
2024-02-13 16:42:07.878966500 Attempting to disconnect from A5:C2:37:05:95:B6
2024-02-13 16:42:07.878978500 Successful disconnected
2024-02-13 16:42:13.048343500 Device A5:C2:37:05:95:B6 (public)
2024-02-13 16:42:13.048353500   Alias: Bateria Serv 2
2024-02-13 16:42:13.048356500   Paired: no
2024-02-13 16:42:13.048357500   Trusted: no
2024-02-13 16:42:13.048358500   Blocked: no
2024-02-13 16:42:13.048359500   Connected: no
2024-02-13 16:42:13.048361500   LegacyPairing: no
2024-02-13 16:42:13.048362500   UUID: Device Information        (0000180a-0000-1000-8000-00805f9b34fb)
2024-02-13 16:42:13.048365500   RSSI: -62
2024-02-13 16:42:13.050752500
2024-02-13 16:42:14.452005500 INFO:SerialBattery:
2024-02-13 16:42:14.452768500 INFO:SerialBattery:Starting dbus-serialbattery
2024-02-13 16:42:14.454893500 INFO:SerialBattery:Venus OS v3.14
2024-02-13 16:42:14.455533500 INFO:SerialBattery:dbus-serialbattery v1.1.20240212dev
2024-02-13 16:42:15.014904500 INFO:SerialBattery:Init of LltJbd_Ble at A5:C2:37:05:95:B6
2024-02-13 16:42:15.015883500 INFO:SerialBattery:Test of LltJbd_Ble at A5:C2:37:05:95:B6
2024-02-13 16:42:20.028885500 ERROR:SerialBattery:>>> ERROR: Unable to connect with BLE device
2024-02-13 16:42:20.033066500 ERROR:SerialBattery:No BMS found at A5:C2:37:05:95:B6
2024-02-13 16:42:20.033824500 ERROR:SerialBattery:ERROR >>> No battery connection at LltJbd_Ble
2024-02-13 16:42:25.775663500 ERROR:SerialBattery:BleakClient(): asyncio.exceptions.TimeoutError: TimeoutError() of type <class 'asyncio.exceptions.TimeoutError'> in /opt/victronenergy/dbus-serialbattery/bms/lltjbd_ble.py line #100
2024-02-13 16:42:26.136626500
2024-02-13 16:42:26.136634500 INFO:Bluetooth details
2024-02-13 16:42:26.180636500 [CHG] Device A5:C2:37:05:95:B6 RSSI: -62
2024-02-13 16:42:26.271000500 Attempting to disconnect from A5:C2:37:05:95:B6
2024-02-13 16:42:26.271010500 Successful disconnected
2024-02-13 16:44:36.110049500 *** CCGX booted (0) ***
2024-02-13 16:50:07.044734500 *** CCGX booted (0) ***
2024-02-13 16:59:48.912221500 *** CCGX booted (0) ***
2024-02-13 17:10:56.036678500 *** CCGX booted (0) ***

==> /data/log/dbus-blebattery.0/current <==
2024-02-13 17:16:47.597959500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\x00\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf8\x30\x77
2024-02-13 17:16:47.862534500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xdd\x0d\xda\x0d\xdd\x0d\xdb\xfc\x55\x77
2024-02-13 17:16:47.878622500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:47.879411500 DEBUG:SerialBattery:Cells:[1]3.549V [2]3.546V [3]3.549V [4]3.547V
2024-02-13 17:16:48.634579500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\x00\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf8\x30\x77
2024-02-13 17:16:48.897317500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xdd\x0d\xda\x0d\xdd\x0d\xdb\xfc\x55\x77
2024-02-13 17:16:48.901418500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:48.902314500 DEBUG:SerialBattery:Cells:[1]3.549V [2]3.546V [3]3.549V [4]3.547V
2024-02-13 17:16:49.623224500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\x00\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf8\x30\x77
2024-02-13 17:16:49.887114500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xdd\x0d\xda\x0d\xdd\x0d\xdc\xfc\x54\x77
2024-02-13 17:16:49.893384500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:49.896469500 DEBUG:SerialBattery:Cells:[1]3.549V [2]3.546V [3]3.549V [4]3.548V
2024-02-13 17:16:50.616565500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\x00\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf8\x30\x77
2024-02-13 17:16:50.880577500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xdd\x0d\xda\x0d\xdd\x0d\xdb\xfc\x55\x77
2024-02-13 17:16:50.917026500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:50.918545500 DEBUG:SerialBattery:Cells:[1]3.549V [2]3.546V [3]3.549V [4]3.547V
2024-02-13 17:16:51.599932500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\x00\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf8\x30\x77
2024-02-13 17:16:51.878477500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xdd\x0d\xda\x0d\xdd\x0d\xdb\xfc\x55\x77
2024-02-13 17:16:51.884624500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:51.893446500 DEBUG:SerialBattery:Cells:[1]3.549V [2]3.546V [3]3.549V [4]3.547V
2024-02-13 17:16:52.637789500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\x00\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf8\x30\x77
2024-02-13 17:16:52.902458500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xdd\x0d\xda\x0d\xdd\x0d\xdc\xfc\x54\x77
2024-02-13 17:16:52.918513500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:52.920531500 DEBUG:SerialBattery:Cells:[1]3.549V [2]3.546V [3]3.549V [4]3.548V
2024-02-13 17:16:53.627822500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\x00\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf8\x30\x77
2024-02-13 17:16:53.893379500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xdd\x0d\xda\x0d\xdd\x0d\xdb\xfc\x55\x77
2024-02-13 17:16:53.902886500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:53.904214500 DEBUG:SerialBattery:Cells:[1]3.549V [2]3.546V [3]3.549V [4]3.547V
2024-02-13 17:16:54.619067500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\x00\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf8\x30\x77
2024-02-13 17:16:54.882450500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xdd\x0d\xda\x0d\xdd\x0d\xdc\xfc\x54\x77
2024-02-13 17:16:54.890352500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:54.892036500 DEBUG:SerialBattery:Cells:[1]3.549V [2]3.546V [3]3.549V [4]3.548V
2024-02-13 17:16:55.606406500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\x57\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf7\xd9\x77
2024-02-13 17:16:55.874080500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xde\x0d\xdb\x0d\xdd\x0d\xdc\xfc\x52\x77
2024-02-13 17:16:55.914049500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:55.916098500 DEBUG:SerialBattery:Cells:[1]3.55V [2]3.547V [3]3.549V [4]3.548V
2024-02-13 17:16:56.644466500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\x9a\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf7\x96\x77
2024-02-13 17:16:56.907600500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xde\x0d\xdc\x0d\xde\x0d\xdd\xfc\x4f\x77
2024-02-13 17:16:56.932780500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:56.934414500 DEBUG:SerialBattery:Cells:[1]3.55V [2]3.548V [3]3.55V [4]3.549V
2024-02-13 17:16:57.631758500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\xf1\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf7\x3f\x77
2024-02-13 17:16:57.897737500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xdf\x0d\xdc\x0d\xde\x0d\xdd\xfc\x4e\x77
2024-02-13 17:16:57.910837500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:57.910846500 DEBUG:SerialBattery:Cells:[1]3.551V [2]3.548V [3]3.55V [4]3.549V
2024-02-13 17:16:58.621933500 DEBUG:SerialBattery:bytearray: \xdd\x03\x00\x22\x05\x8b\x00\xb8\xb3\xa7\xb3\xb0\x00\x06\x2f\x46\x00\x00\x00\x00\x00\x00\x28\x64\x03\x04\x01\x0b\x8a\x00\x00\x00\xb3\xb0\xb3\xa7\x00\x00\xf7\x78\x77
2024-02-13 17:16:58.887400500 DEBUG:SerialBattery:bytearray: \xdd\x04\x00\x08\x0d\xde\x0d\xdc\x0d\xde\x0d\xdd\xfc\x4f\x77
2024-02-13 17:16:58.918592500 DEBUG:SerialBattery:logged to dbus [99.98]
2024-02-13 17:16:58.919447500 DEBUG:SerialBattery:Cells:[1]3.55V [2]3.548V [3]3.55V [4]3.549V

Any other information that may be helpful
I have notices with my setup, that after Absortion with a 7.5a CCL, it cycles from 7.5 ABS to 70a Abs. But my quattro charger goes from Abs to Bulk. Never reaches Float althoug the driver may deliver Float and charger on Abs or BUlk delivers Float voltage but on Abs or Bulk

The previous versions take longer to start/restart. I will add a short sleep time, so the BMS can recover to be ready for a new connection.

@AlexdeKairos could you install the latest version from my dev build?

Seems to running better. My second ble battery has some troubleshoot and is not avail for testing.  Second unit used to give more trouble.
Next week I'll try again and report.

@AlexdeKairos any news?

Sorry Manuel. Most of the problems I could find in several versions of the driver were related to multiple BLE batteries. Unfortunately my second battery BMS has failed and I'm waiting for replacement but it may take lots of time.
With my single temporary setup, driver has been working for one week without a single failure.

I close this issue in the meanwhile. Feel free to open a new one, if you have further problems.


creating fuctionalitys buttons

summary:

[ ] check button active
[ ] line through the text
[ ] bacground change
[ ] delete itens selected
[ ] delete all items
[ ] make animations

The changes of the previous reviewer were corrected


Problem in auto dispose room

Hi,
I see here little issue in auto room disposing. When I set allowReconnection in my code room will not be auto dispose even after all player after has been left & allowReconnection has been timeout.

Hi @bhavik66, I couldn't reproduce this issue, can you provide an example? Cheers

Use this example https://github.com/gamestdio/colyseus-examples and change on leave code to
onLeave (client) {         try {             // allow disconnected client to rejoin into this room until 20 seconds             this.allowReconnection(client, 20)           } catch (e) {             console.log(e)           }     }
Now when all players will leave the room will not dispose automatically. As I mentioned here https://github.com/gamestdio/colyseus/pull/182


Don't log output.

Hey @sindresorhus,
I would love to have an an option like hideLog: true which just does not output anything.
It would be extremely simple to implement and allow for one to collect different size measurements and report a result in the end.
I am happy to send PR if you want, its basically just another check in the if that otherwise reports all. There should be no bc problem.

Can you share your specific use-case? (I'm asking as there might be a better way to solve the problem)

Well, my specific use-case is that I want to report an overall improvement (in %) for which I need the size at specific points in the execution. However I do not want my output to be littered with reported sizes, as this makes it harder to scan and find what you are looking for.

I would be ok with a silent option if it came as a pull request with a test and readme updates.

Hey, I wrote the change, but when adding the readme I notice that setting showTotal to false, does the same thing, so this is actually not needed.
However, FYI I noticed that npm test fails due to formatting issues. Maybe you want to look into this.


Shadow priest wrath rotation updates

Updated Spriest rotations for basic/clipping/ideal. Clipping/basic need minor updates still, but this is a good place to start for wrath analysis. Ideal is pretty much there, but definitely some work to do on snap shotting, but most of the stuff is in.

Accidently merged 2 pull requests


Request to add Dockery as related project

Requesting to add my project below in Laradock’s related projects page.
https://github.com/taufek/dockery
It is another Laradock inspired project for Rails applications.

Thank you @Mahmoudz . 👍


Integrate blob like feature

Hey @bonustrack, is this issue still valid?

@zzuziak Yes, this issue is still relevant

Do you think that with a proper pitch and technical scope it could be a bounty / hackathon project?