text:
Robot test execution

As a developer, I would like to execute Robot tests natively in the IDE
Just so it's written down, the #1 item that would differentiate the various Intellij plugins (and for record, I really like this one!) is the ability to run/debug tests natively. This can be done with currently with low-level Maven and Java debugger commands but that isn't very nice at all (and assumes Maven).
Obviously this is not a trivial enhancement but do you have any idea of what the sizing would be?

Closing as I got confused by which repo is the canonical source for this plugin - neither this nor the jivesoftware one are forked from each other (in github terms) so both appear as the primary (and both have PRs and Issues enabled!).
Assuming I have direction correct, I recommend destroying this one recreating it by "forking" from jivesoftware

repo: charlescapps/robot-intellij-plugin


text:
Columns' alignment

In a demo app, columns on the right hand side are slightly shifted. I had a similar issue and placing the table inside the div with table-responsive class helped, like described here. Perhaps can help here too?

@bsrdjan This is probably because I've hard coded the scrollbar size - I assume you are looking at this on a Mac (or something with a thin/thick scrollbar)
At some point I'll be tidying this all up so it should work better cross-browser

source: gharchive/issue

authors: bsrdjan charlespockert

repo: charlespockert/aurelia-bs-grid

license: MIT

license_type: permissive

license_source: github-api


text:
edge case: disabled* param apply when not enabled

Hi,
Thanks for publishing this project.   If I get time I will submit a patch and close this issue myself.
If you don't set the disabledFrom or disabledTo inputs; and you have a CTO who likes doing things "at" midnight (i.e. he choose 00:00:00); the validation (which isn't enabled) will still say that its an error.
I resolved this on my copy of the source by adding to the top of isDisabled()
if(this.disabledFrom ==='' && this.disabledTo==='') { return false; }
I will be responding abit slowly, as this  github account isn't an account I use during work hours

Sorry, I have opened this on the wrong project. I should have opened it on vue2-clock-picker

repo: charliekassel/vuejs-datepicker

license: mit

license_source: bigquery


text:
For point cloud registration

How to use this code for point cloud registration ?

hellow, how to use this code to align a 3D mesh I create with the 3DMM mean shape. The coordinate of 3DMM mean shape is too big about +- 50000.my mesh is about +-0.1

repo: charlienash/nricp


text:
Assignment suggestions using Tabea's PRA solver

Short description

The "suggest assignment" button finally works! 🥳 🎉
Proposed changes

add management command for exporting ward patients to Tabea's format, using her solver, and returning the solution
clicking the "suggest assignment" button takes you to the normal timeline view, with the option to save, cancel, or edit the timeline as usual

Please Note

#93 should be merged BEFORE this, so if you want to review this PR, please instead review that one 😉
the bed assignments aren't exactly ideal, but this is not on us. Not sure if there is an error in the solver, or if it is just due to the rounding. We will have to wait and see how it works with the final presentation data; before then, there isn't really anything we can do with this.
this does not work for Pädiatrie, because the solver cannot handle rooms with more than 2 beds (see error in console)

Installation

clone TabeaBrandt/patient-to-room_assignment next to where your copy of ycms lives
inside patient-to-room_assignment, do

python -m venv .venv
. .venv/bin/activate
pip install gurobipy

Resolved issues

Fixes: #20

A doubt:
I am on the branch automatic-assignment
So I installed patient-to-room_assignment in the same directory as ycms. I installed gurobi in the same virtual environment as rest of the project (its called denv). I run ycms and click on suggest assignment but nothing seems to pop up, What am i missing?

A doubt:
I am on the branch automatic-assignment
So I installed patient-to-room_assignment in the same directory as ycms. I installed gurobi in the same virtual environment as rest of the project (its called denv). I run ycms and click on suggest assignment but nothing seems to pop up, What am i missing?

Please follow the instructions as given:

clone TabeaBrandt/patient-to-room_assignment next to where your copy of ycms lives
inside patient-to-room_assignment, do

python -m venv .venv
. .venv/bin/activate
pip install gurobipy

"next to" means that the two are "siblings".
For example,
/home/sneha/ycms/
/home/sneha/patient-to-room_assignment

but not
/home/sneha/ycms/
/home/sneha/ycms/patient-to-room_assignment

(its called denv)

I am really not sure how that works, the install.sh script handles virtual envireonments in our project, and it will always be located in .venv.
In any case, you need a separate one, as the instructions say.

"next to" means that the two are "siblings". For example,
/home/sneha/ycms/
/home/sneha/patient-to-room_assignment

but not
/home/sneha/ycms/
/home/sneha/ycms/patient-to-room_assignment

Yup they are siblings.

(its called denv)

I am really not sure how that works, the install.sh script handles virtual environments in our project, and it will always be located in .venv.
In any case, you need a separate one, as the instructions say.

I had created a virtual env denv in the begining where I installed everything in ycms. I followed the instructions also and added venv inside patient-to-room directory. and then I went back to ycms and ran it. clicking on suggest assignment didn't do anything for me. Am I supposed to directly click on that or I check in timetravel for assignments and then it will show

"next to" means that the two are "siblings". For example,
/home/sneha/ycms/
/home/sneha/patient-to-room_assignment

but not
/home/sneha/ycms/
/home/sneha/ycms/patient-to-room_assignment

Yup they are siblings.

(its called denv)

I am really not sure how that works, the install.sh script handles virtual environments in our project, and it will always be located in .venv.
In any case, you need a separate one, as the instructions say.

I had created a virtual env denv in the begining where I installed everything in ycms. I followed the instructions also and added venv inside patient-to-room directory. and then I went back to ycms and ran it. clicking on suggest assignment didn't do anything for me. Am I supposed to directly click on that or I check in timetravel for assignments and then it will show

Alright, what's the console output when you click the button? And no, should not matter which one.

Actually, could you please also provide the output of pwd and ls -al from inside the solver directory?
A more direct way for trouble shooting could also be using ./tools/ycms-cli call_solver_api 1, since this is what the ward/timeline views call

Actually, could you please also provide the output of pwd and ls -al from inside the solver directory?
A more direct way for trouble shooting could also be using ./tools/ycms-cli call_solver_api 1, since this is what the ward/timeline views call

So when I click on the button I get the following output:

Console shows this :

So the main directory is hosproj under in which both ycms and pra reside.

Actually, could you please also provide the output of pwd and ls -al from inside the solver directory?
A more direct way for trouble shooting could also be using ./tools/ycms-cli call_solver_api 1, since this is what the ward/timeline views call

So when I click on the button I get the following output:

Console shows this :

So the main directory is hosproj under in which both ycms and pra reside.

From the console error output: looks like you need a (free) license. Interesting. I got one but thought it's activation failed, but apparently not!
Have a look online, the license is pretty easy to get.

Works for me👌👌. I can see suggested assignments for unassigned patients in the timeline view for past current and future.
Do you want to wait till the final data before merging this?

Works for me👌👌. I can see suggested assignments for unassigned patients in the timeline view for past current and future. Do you want to wait till the final data before merging this?

Great! And no, let's merge if you've no change requests.

source: gharchive/pull-request

repo: charludo/ycms


text:
feat: implement word wrapping for formatted output

I don't know if this is a feature you wanted to expose, but it has come in handy to me, so I wanted to share it with you.
The most common use case is with code; wrapping the lines too early makes it difficult to copy the generated examples.
I tried following the same convention and using the same wording as on the glamour page to document the word-wrap option.

I fixed the issue detected by the linter. Sorry I missed that.

I fixed the issue detected by the linter. Sorry I missed that.

the linter was me after merging with main... I was gonna fix it but got caught up in other stuff...
Thanks for fixing it though 🙏

repo: charmbracelet/mods


text:
How can I draw a chart like this.

How can I draw a chart like this.

Use the callbacks found in options.scales.xAxes[0].ticks.callback and same for the yAxes[0].  For insteance, suppose your y-values are decimals and you want to show 0.3919 as 39.19%, you would set the following option:
var options={
    scales: {
        xAxes: [
            {
                ticks:{
                    callback:function(v){return 100*v + "%"}
                }
            }
        ]
        yAxes: [
            {
                ticks:{
                    callback://TODO: point to your transform function
                }
            }
        ]
    },
};

You then use those options to create your chart

@RoxKilly is correct.

authors: RoxKilly etimberg longboy


text:
[BUG] getHsla() can't parse float Hue

Using hsla color (for example "hsla(240.0384227364303,4.12843378950259%,48.71943371204973%,0.3)") causes (at least in bubble chart) error when you hover over bubbles. It is because the getHsla function parses (idk for what) color with regex that does not support float Hue.
Seems like it was fixed here https://github.com/Qix-/color-string/pull/19/files but your fork looks very outdated. Should I make a PR to chartjs-color repo?
Also consider https://github.com/Qix-/color-string/pull/37

@Nakilon a PR to the chartjs-color repo sounds good to me. @simonbrunel thoughts?

Here https://github.com/chartjs/color-string/pull/2/files

@kurkle is this fixed with the switch to your color implementation?

Looks like no. Will be after couple of minutes :)

Fixed in @kurkle/color v0.13

authors: Nakilon etimberg kurkle


text:
[BUG] Legends in tooltips cannot be hidden

Expected Behavior
As of 2.3.0 one could use:
options: {
        legend: {
        	display: false
        },
        tooltips: {
        	callbacks: {
        		label: function(tooltipItem) {
        			return tooltipItem.yLabel;
        		}
        	}
        }
 }

and would receive:

Current Behavior
The legend appears before the label

Steps to Reproduce (for bugs)
Here is a working example on 2.3.0:
http://jsfiddle.net/wpck00bq/1/
Switching to version 2.4.0 or later causes the issue.
Context
I am working on a scatter plot and want a tooltip with just the data points. I also would like to remove the title, is there a better way than setting the title to a blank string in the title callback?

The legend and tooltip are independent. You can remove the title by changing the tooltip title callback to return null.

Is the grey square before the 80 in the second picture removable like it used to be?

@matthanson12 it can be removed with the displayColors setting. http://www.chartjs.org/docs/latest/configuration/tooltip.html#tooltip-configuration

My god I'm an idiot. Cheers


text:
[Feature] Add more alignment values to chart title, xAxes and yAxes

Bug []
Feature Request [x]
Expected Behavior

Documentation for positioning a title in Chart.js are: top, left, right, bottom. I believe the option for adding two values such a top left should be added.
User should have the option to align xAxes and yAxes values to start, middle or end.

An example of this expected behavior is shown in the following image:

As you can see - the chart title is aligned top left, yAxes is aligned at the start and the xAxes is aligned at the start.
Current Behavior
I'm only able to align chart titles to the middle. For example:

Possible Solution

xAxes/yAxes - Add an align property to the scaleLabel object. For example: scaleLabel: { align:  'start' }
Title: - Add an align property to the title object. For example: title: { align: 'top left' }

Context

For me personally, I want to align many of my chart and yAxes titles to the top left as viewers tend to absorb visualisations in a zigzag direction. So by starting at the top left, the user will find the chart title and yAxes title immediately.

Scale title options exist in v2.9.x. Title alignment options added in #6908

I would like to know if this option has already been implemented for version two of chartjs?

authors: SeanLuis etimberg jamesbarrett95


text:
Stacked rounded bar chart with positive and negative and rounded on top and bottom.

I can't seem to find a complete solution for this and I also wonder why it isn't an option included in the library? Anyways, could someone help me out with this? I need to create a stacked bar chart with both positive and negative values. Rounded only the top and bottom parts. Also, some data points could be 0.
Here is the closest I came up with from various examples.
https://jsfiddle.net/uffo/5oty49r3/6/
And here is what I need to achieve

Any help would be much appreciated :)

This would be a nice thing to have in the library in the future. For non stacked bars it's fairly trivial as its just some rounding at the end of the bar that is not the base.
In terms of doing this cleanly, I think it would be best to have some sort of corner radius added to each bar element by the controller. The controller may have a better idea of where in the stack a bar is.

Hi @uffou,
I have same issue for dataset with 0 at end.
please help if you found any solution.
Thank you in advance for any advice.
Jitendra

Using the built-in borderRadius property in v3 coupled with the fact that nearly everything is scriptable starting in v3.0.0-beta.11, this is quite easy to do now.
https://jsfiddle.net/7sh342wj/

authors: Jitendra94 etimberg uffou


text:
Module '"chart.js"' has no exported member 'SubTitle'.

Expected Behavior
Using Chart.js v3.4.1 in an angular application, I expect that I can use the new options.plugins.SubTitle feature
import { SubTitle } from 'chart.js'; to then allow
Chart.register(SubTitle);

I should not get an error when trying to use SubTitle.
Current Behavior
I am getting the error Module '"chart.js"' has no exported member 'SubTitle'.
Possible Solution
I suspect either it is not called "SubTitle" or it is not being exported.
Steps to Reproduce
Following the https://www.chartjs.org/docs/next/getting-started/integration.html (Bundlers (Webpack, Rollup, etc.)), try and register the "SubTitle" module.
When using
import { registerables } from 'chart.js';
Chart.register(...registerables);
SubTitle work perfectly, but this will load all plugins which is not ideal.
Context
I am required to load all plugins and not just the ones I need.
Environment

Chart.js version: 3.4.1

I looked into the built file and see the plugin being exported as SubTitle. Do you have a reproduce for this?

Seems to work fine: https://codesandbox.io/s/admiring-ardinghelli-wk15h?file=/src/components/HelloWorld.vue

I do see that there isn't a type of SubTitle so perhaps this is a TS error?

@LeeLenaleee  Thanks for the VUE example. I was able to create an angular one that shows the error I'm seeing. https://codesandbox.io/s/sharp-swanson-r5qpk?file=/src/main.ts

@LeeLenaleee  If I used "registerables" instead of "SubTitle" then everything works fine, but it load all the ChartJS modules.

As @etimberg suspected its a type error which should be rsolved by his pr

This is a pure TS error. You can add a TS ignore and it will be fine until a fix is released

Yes changing it to
import {
// @ts-ignore
SubTitle
} from 'chart.js'
fixed the problem.
Thanks so much for the help!

authors: LeeLenaleee etimberg mfriesen


text:
Update pie chart Chart.js with select

I have a pie chart that updates depending on the option selected by the user. When I click the option "All" the graph updates correctly but when you click individual options the graph does not show what it should.
orders = [
  { name: 'Luis', orders_by_user: 25.5 },
  { name: 'Jose', orders_by_user: 16.3 },
  { name: 'Miguel', orders_by_user: 3.8 }
];

const myChart = new Chart(document.getElementById('orders'), {
  type: 'pie',
  data: {
    labels: orders.map(o => o.name),
    datasets: [{
      label: 'Terminadas',
      data: orders.map(o => o.orders_by_user),
      borderColor: 'rgba(75, 192, 192, 1)',
      backgroundColor: "#229954",
      borderWidth: 1,

    }]
  },
  options: {
    title: {
      display: true,
      text: "Ordenes en estado terminado"
    },
    },

});

orders.forEach(o => {
  const opt = document.createElement('option');
  opt.value = o.name;
  opt.appendChild(document.createTextNode(o.name));
  document.getElementById('operator').appendChild(opt);
});

function refreshChart(name) {
  myChart.data.labels = [name];
  if (name == 'All') {
     myChart.data.labels = orders.map(o => o.name),
     myChart.data.datasets[0].data = orders.map(o => o.orders_by_user);
  } else {
    myChart.data.labels = [name];
    myChart.data.datasets[0].data = orders.find(o => o.name == name).orders_by_user;
  }
  myChart.update();
}

And this is mi html code
Operarios:
<select id="operator" onchange="refreshChart(this.value)">
    <option>All</option>
</select>
<script src="https://cdnjs.cloudflare.com/ajax/libs/Chart.js/2.9.3/Chart.min.js"></script>
<canvas id="orders" height="90"></canvas>

This is my url fiddle https://jsfiddle.net/mariaa92/5ewp7k8n/10/
Someone could help me?

data needs to be an array. You are passing single value.


text:
Width for Label annotation doesn't work

I want label annotation to take the whole width of the axis, but for some reason, xMin and xMax values are ignored.
I also tried to use width parameter, but it doesn't have any effect either.
In the docs, there's a line saying that "To enable to use the box positioning, the radius must be set to 0 or NaN.", but could you specify what radius it refers to? I wasn't able to find anything for both this plugin or ChartJS itself.
In the example below I used 2 annotations - box that can take the whole width of the axis and label that doesn't work.
Thank you!
https://jsfiddle.net/ntyv2cdb/17/

In the docs, there's a line saying that "To enable to use the box positioning, the radius must be set to 0 or NaN.", but could you specify what radius it refers to? I wasn't able to find anything for both this plugin or ChartJS itself.

Thank you @dmbaranov, that's a bug in the doc. Sorry. I'll fix it.
You can not specify the height or the width of the label, because is automatically calculated based on the content to draw.
[x/y]Min and [x/y]Max will be used to calculate the point (middle of the rectangle) where positioning the label.
width option is used ONLY where the content of the label is an Image or a Canvas.
The solution is to use a box annotation, with a label, something like (using your sample):
{
  type: 'box',
  yMin: 9,
  yMax: 11,
  backgroundColor: 'rgba(255, 99, 132, 0.25)',
  label: {
    display: true,
    content: 'hello'
  }
}

FYI, I have an issue to fix the doc: https://github.com/chartjs/chartjs-plugin-annotation/issues/829

Thank you so much @stockiNail! Your solution with the box seems to work really nicely for my case, I'll stick to it :)

authors: dmbaranov stockiNail

repo: chartjs/chartjs-plugin-annotation


text:
Null pointer exception on calling ChatSDK.auth()

Is the bug present in the demo Chat SDK project?
I guess no.

What modifications have you made to the Chat SDK?
None

Android Version:
10.0 (Emulator)

Steps taken to reproduce the problem:
Call ChatSDK.auth()

Expected result:
No crash

Actual result:
Crash

Comments:

Hey,
Currently I'm trying to manually sign in a user with a custom token. However, I found out that just calling ChatSDK.auth() crashes the app. I'm using the current ChatSDK version.
E/AndroidRuntime: FATAL EXCEPTION: main
    Process: ..., PID: 8128
    java.lang.RuntimeException: Unable to start activity ComponentInfo{.../...MainActivity}: java.lang.NullPointerException: Attempt to read from field 'sdk.chat.core.handlers.AuthenticationHandler sdk.chat.core.base.BaseNetworkAdapter.auth' on a null object reference
        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3270)
        at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3409)
        at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:83)
        at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
        at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2016)
        at android.os.Handler.dispatchMessage(Handler.java:107)
        at android.os.Looper.loop(Looper.java:214)
        at android.app.ActivityThread.main(ActivityThread.java:7356)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:930)
     Caused by: java.lang.NullPointerException: Attempt to read from field 'sdk.chat.core.handlers.AuthenticationHandler sdk.chat.core.base.BaseNetworkAdapter.auth' on a null object reference
        at sdk.chat.core.session.ChatSDK.auth(SourceFile:1)
        at ....MainActivity.signUpToChat(MainActivity.kt:65)
        at ....MainActivity.onCreate(MainActivity.kt:45)
        at android.app.Activity.performCreate(Activity.java:7802)
        at android.app.Activity.performCreate(Activity.java:7791)
        at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1299)
        at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:3245)
        at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:3409)
        at android.app.servertransaction.LaunchActivityItem.execute(LaunchActivityItem.java:83)
        at android.app.servertransaction.TransactionExecutor.executeCallbacks(TransactionExecutor.java:135)
        at android.app.servertransaction.TransactionExecutor.execute(TransactionExecutor.java:95)
        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2016)
        at android.os.Handler.dispatchMessage(Handler.java:107)
        at android.os.Looper.loop(Looper.java:214)
        at android.app.ActivityThread.main(ActivityThread.java:7356)
        at java.lang.reflect.Method.invoke(Native Method)
        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:930)

Code:
fun signUpToChat() {
        val token = "[jwt-token]"
        val details = AccountDetails.token(token)
        ChatSDK.auth() // Crashes already
        ChatSDK.auth().authenticate(details).subscribe({ // Initial attempt to authenticate
            Log.i("Chat", "Authenticated")
        }, { error ->
            Log.e("Chat","error: $error")
        })
}

My SDK configuration:
    private fun setUpChat() {
        try {
            val defaultBuild = ChatSDK.builder()
                .build()
                .addModule(
                    FirebaseModule.builder()
                        .setFirebaseRootPath("develop-android")
                        .setDisablePublicThreads(true)
                        .build()
                )
                .addModule(FirebasePushModule.shared())
                .addModule(
                    UIModule.builder()
                        .setPublicRoomCreationEnabled(false)
                        .setPublicRoomsEnabled(false)
                        .setLocationMessagesEnabled(false)
                        .setShowAvatarInChatView(false)
                        .setRequestPermissionsOnStartup(false)
                        .setGroupsEnabled(false)
                        .setImageMessagesEnabled(false)
                        .build()
                )
                .build()
                .activate(this)
        } catch (e: Exception) {
            e.printStackTrace()
        }

signUpToChat() is called immediately after setUpChat has finished.
project build.gradle:
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
    ext.kotlin_version = "1.4.0"
    repositories {
        google()
        jcenter()
    }
    dependencies {
        classpath "com.android.tools.build:gradle:4.0.1"
        classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
        classpath "org.jetbrains.kotlin:kotlin-serialization:$kotlin_version"
        classpath "com.google.gms:google-services:4.3.3"
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

allprojects {
    repositories {
        google()
        jcenter()
        maven { url "https://jitpack.io" }
        maven { url "http://dl.bintray.com/chat-sdk/chat-sdk-android" }
    }
}

task clean(type: Delete) {
    delete rootProject.buildDir
}

app.gradle:
apply plugin: 'com.android.application'
apply plugin: 'kotlin-android'
apply plugin: 'kotlin-android-extensions'
apply plugin: 'kotlinx-serialization'
apply plugin: 'com.google.gms.google-services'

android {
    compileSdkVersion 29

    defaultConfig {
        applicationId "..."
        minSdkVersion 21
        targetSdkVersion 29
        versionCode 1
        versionName "1.0"
        multiDexEnabled = true

        testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
    }

    buildTypes {
        release {
            minifyEnabled false
            proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
        }
    }

    compileOptions {
        sourceCompatibility JavaVersion.VERSION_1_8
        targetCompatibility JavaVersion.VERSION_1_8
    }
}

dependencies {
    implementation fileTree(dir: "libs", include: ["*.jar"])
    implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
    implementation 'androidx.core:core-ktx:1.1.0'
    implementation 'androidx.appcompat:appcompat:1.1.0'
    implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
    testImplementation 'junit:junit:4.12'
    androidTestImplementation 'androidx.test.ext:junit:1.1.1'
    androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0'
    implementation 'com.google.firebase:firebase-analytics:17.5.0'
//    implementation 'com.google.firebase:firebase-database:19.4.0'
//    implementation 'com.google.firebase:firebase-crashlytics:17.2.1'

    implementation("io.reactivex.rxjava3:rxkotlin:3.0.0")
    implementation("io.reactivex.rxjava3:rxandroid:3.0.0")
    implementation("com.squareup.okhttp3:okhttp:4.8.1")
    implementation("org.jetbrains.kotlinx:kotlinx-serialization-core:1.0.0-RC")

    implementation "sdk.chat:firebase-app:5.0.9"
}

allprojects {
    repositories {
        google()
        jcenter()
        maven { url "https://jitpack.io" }
        maven { url "http://dl.bintray.com/chat-sdk/chat-sdk-android" }
    }
}

So I figured out, that the app does not crash using quickStart. Is something missing in my custom start setup?

The issue was that my custom start code was throwing an error. This error was thrown because my root path contained a "-" ("develop-android") which was not allowed and led to the error message:
java.lang.Exception: The root path cannot contain special characters, they were removed so your new root path is: developandroid
Of course - with no startup the auth() call failed.
This issue is fixed now.

repo: chat-sdk/chat-sdk-android


text:
Bug:  oracle表不存在

Chat2DB Version
2.0.11
Describe the bug
Bug:  oracle表不存在

2.0.13已经修复


text:
知识库问答问题，回复内容知识库已经匹配到对应内容，但是还是回复根据已知信息，无法回答该问题

分数阈值都试过了，都不行

使用的是 LLM=chatglm2-6b

你在直接和LLM对话中贴原文+问题看看chatglm2-6b能不能回答，有可能是LLM不给力总结不出来，我测试了chatglm1和2目前开源的全系列，可能是因为训练数据集小了，推理能力捉急，很多问题直接问也死都答不出来，后面换了baichuan2-13B-chat，解决了大部分此类问题，数据集b值越大，推理能力越强，带不动就加配置

我用了Qwen，在chatglm上栽太多跟头了

你在直接和LLM对话中贴原文+问题看看chatglm2-6b能不能回答，有可能是LLM不给力总结不出来，我测试了chatglm1和2目前开源的全系列，可能是因为训练数据集小了，推理能力捉急，很多问题直接问也死都答不出来，后面换了baichuan2-13B-chat，解决了大部分此类问题，数据集b值越大，推理能力越强，带不动就加配置

请问您的数据集多大规模？用baichuan2-13B-chat是直接微调还是用langchain? 我微调baichuan2-13B-chat效果不理想，回答是错的

你在直接和LLM对话中贴原文+问题看看chatglm2-6b能不能回答，有可能是LLM不给力总结不出来，我测试了chatglm1和2目前开源的全系列，可能是因为训练数据集小了，推理能力捉急，很多问题直接问也死都答不出来，后面换了baichuan2-13B-chat，解决了大部分此类问题，数据集b值越大，推理能力越强，带不动就加配置

我试了一下，第一次居然不行，第二次就可以了，glm确实不大行

我用了Qwen，在chatglm上栽太多跟头了

确实，我也换一个试试

你在直接和LLM对话中贴原文+问题看看chatglm2-6b能不能回答，有可能是LLM不给力总结不出来，我测试了chatglm1和2目前开源的全系列，可能是因为训练数据集小了，推理能力捉急，很多问题直接问也死都答不出来，后面换了baichuan2-13B-chat，解决了大部分此类问题，数据集b值越大，推理能力越强，带不动就加配置

FlagAlpha/Llama2-Chinese-13b-Chat 这个怎么样

同样遇到这个问题，我用的是本地模型：chatglm3-6b
我尝试了直接和LLM对话中贴原文+问题看看chatglm3-6b能不能回答，回答效果不太理想
将本地模型换为：qwen-max api去跑，可以完全回答正确。
想请教大家有什么可以下载到本地的LLM模型推荐吗

repo: chatchat-space/Langchain-Chatchat


text:
【求助】环境搭好后，模型显示使用cuda，但加载模型时不使用显存

问题描述
环境搭好之后，下载了本地模型，修改了model_config.py文件，执行python startup.py -a项目启动
启动过程中，只增加内存占用，显存不占用。
使用的WSL2环境，Ubuntu22.04
相同的环境可以直接运行chatglm3-6b模型
pytorch相关信息输出如下
import torch

# 检查CUDA是否可用
cuda_available = torch.cuda.is_available()

if cuda_available:
    # 获取GPU设备数量
    num_gpu = torch.cuda.device_count()

    # 获取当前使用的GPU索引
    current_gpu_index = torch.cuda.current_device()

    # 获取当前GPU的名称
    current_gpu_name = torch.cuda.get_device_name(current_gpu_index)

    # 获取GPU显存的总量和已使用量
    total_memory = torch.cuda.get_device_properties(current_gpu_index).total_memory / (1024 ** 3)  # 显存总量(GB)
    used_memory = torch.cuda.memory_allocated(current_gpu_index) / (1024 ** 3)  # 已使用显存(GB)
    free_memory = total_memory - used_memory  # 剩余显存(GB)

    print(f"CUDA可用，共有 {num_gpu} 个GPU设备可用。")
    print(f"当前使用的GPU设备索引：{current_gpu_index}")
    print(f"当前使用的GPU设备名称：{current_gpu_name}")
    print(f"GPU显存总量：{total_memory:.2f} GB")
    print(f"已使用的GPU显存：{used_memory:.2f} GB")
    print(f"剩余GPU显存：{free_memory:.2f} GB")
else:
    print("CUDA不可用。")

CUDA可用，共有 1 个GPU设备可用。
当前使用的GPU设备索引：0
当前使用的GPU设备名称：NVIDIA GeForce RTX 3090 Ti
GPU显存总量：23.99 GB
已使用的GPU显存：0.00 GB
剩余GPU显存：23.99 GB
PyTorch版本：2.1.0+cu121

运行日志如下
==============================Langchain-Chatchat Configuration==============================
操作系统：Linux-5.15.90.1-microsoft-standard-WSL2-x86_64-with-glibc2.35.
python版本：3.10.9 (main, Mar  1 2023, 18:23:06) [GCC 11.2.0]
项目版本：v0.2.7
langchain版本：0.0.335. fastchat版本：0.2.32

当前使用的分词器：ChineseRecursiveTextSplitter
当前启动的LLM模型：['chatglm3-6b'] @ cuda
{'device': 'cuda',
 'gpus': 0,
 'host': '127.0.0.1',
 'infer_turbo': False,
 'max_gpu_memory': '20GiB',
 'model_path': '/mnt/f/llm/model/dataroot/models/THUDM/chatglm3-6b',
 'num_gpus': 1,
 'port': 20002}
当前Embbedings模型： m3e-base @ cuda
==============================Langchain-Chatchat Configuration==============================

2023-11-14 11:00:46,710 - startup.py[line:647] - INFO: 正在启动服务：
2023-11-14 11:00:46,710 - startup.py[line:648] - INFO: 如需查看 llm_api 日志，请前往 /mnt/f/llm/Langchain-Chatchat/logs
2023-11-14 11:00:50 | ERROR | stderr | INFO:     Started server process [1456]
2023-11-14 11:00:50 | ERROR | stderr | INFO:     Waiting for application startup.
2023-11-14 11:00:50 | ERROR | stderr | INFO:     Application startup complete.
2023-11-14 11:00:50 | ERROR | stderr | INFO:     Uvicorn running on http://127.0.0.1:20000 (Press CTRL+C to quit)
2023-11-14 11:00:51 | INFO | stdout | cuda
2023-11-14 11:00:51 | INFO | model_worker | Loading the model ['chatglm3-6b'] on worker 85221f74 ...
Loading checkpoint shards:   0%|                                                                  | 0/7 [00:00<?, ?it/s]
Loading checkpoint shards:  14%|████████▎                                                 | 1/7 [00:04<00:27,  4.63s/it]
Loading checkpoint shards:  29%|████████████████▌                                         | 2/7 [00:23<01:05, 13.10s/it]
Loading checkpoint shards:  43%|████████████████████████▊                                 | 3/7 [00:44<01:05, 16.45s/it]

查看一下torch和cuda的配置

查看一下torch和cuda的配置

这些信息可以吗？我直接跑chatglm3-6b模型的demo是会使用GPU的
甚至在初始化知识库的时候也会用GPU
但是执行python startup.py -a时就不行
(lang) hengyue@hengyue-Ubuntu:~/llm/chat0.2.6$ python
Python 3.9.18 (main, Sep 11 2023, 13:41:44)
[GCC 11.2.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import torch
>>> print(torch.cuda.is_available())
True
>>> print(torch.__version__)
2.1.0+cu121
>>> exit()
(lang) hengyue@hengyue-Ubuntu:~/llm/chat0.2.6$ nvcc -V
nvcc: NVIDIA (R) Cuda compiler driver
Copyright (c) 2005-2023 NVIDIA Corporation
Built on Mon_Apr__3_17:16:06_PDT_2023
Cuda compilation tools, release 12.1, V12.1.105
Build cuda_12.1.r12.1/compiler.32688072_0

这是我修改的model_config.py文件：
import os

# 可以指定一个绝对路径，统一存放所有的Embedding和LLM模型。
# 每个模型可以是一个单独的目录，也可以是某个目录下的二级子目录。
# 如果模型目录名称和 MODEL_PATH 中的 key 或 value 相同，程序会自动检测加载，无需修改 MODEL_PATH 中的路径。
MODEL_ROOT_PATH = ""

# 选用的 Embedding 名称
EMBEDDING_MODEL = "m3e-base" # bge-large-zh

# Embedding 模型运行设备。设为"auto"会自动检测，也可手动设定为"cuda","mps","cpu"其中之一。
EMBEDDING_DEVICE = "auto"

# 如果需要在 EMBEDDING_MODEL 中增加自定义的关键字时配置
EMBEDDING_KEYWORD_FILE = "keywords.txt"
EMBEDDING_MODEL_OUTPUT_PATH = "output"

# 要运行的 LLM 名称，可以包括本地模型和在线模型。
# 第一个将作为 API 和 WEBUI 的默认模型
LLM_MODELS = ["chatglm3-6b", "zhipu-api", "openai-api"]

# AgentLM模型的名称 (可以不指定，指定之后就锁定进入Agent之后的Chain的模型，不指定就是LLM_MODELS[0])
Agent_MODEL = None

# LLM 运行设备。设为"auto"会自动检测，也可手动设定为"cuda","mps","cpu"其中之一。
LLM_DEVICE = "auto"

# 历史对话轮数
HISTORY_LEN = 3

# 大模型最长支持的长度，如果不填写，则使用模型默认的最大长度，如果填写，则为用户设定的最大长度
MAX_TOKENS = None

# LLM通用对话参数
TEMPERATURE = 0.7
# TOP_P = 0.95 # ChatOpenAI暂不支持该参数

ONLINE_LLM_MODEL = {
    # 线上模型。请在server_config中为每个在线API设置不同的端口

    "openai-api": {
        "model_name": "gpt-35-turbo",
        "api_base_url": "https://api.openai.com/v1",
        "api_key": "",
        "openai_proxy": "",
    },

    # 具体注册及api key获取请前往 http://open.bigmodel.cn
    "zhipu-api": {
        "api_key": "",
        "version": "chatglm_turbo",  # 可选包括 "chatglm_turbo"
        "provider": "ChatGLMWorker",
    },

    # 具体注册及api key获取请前往 https://api.minimax.chat/
    "minimax-api": {
        "group_id": "",
        "api_key": "",
        "is_pro": False,
        "provider": "MiniMaxWorker",
    },

    # 具体注册及api key获取请前往 https://xinghuo.xfyun.cn/
    "xinghuo-api": {
        "APPID": "",
        "APISecret": "",
        "api_key": "",
        "version": "v1.5",  # 你使用的讯飞星火大模型版本，可选包括 "v3.0", "v1.5", "v2.0"
        "provider": "XingHuoWorker",
    },

    # 百度千帆 API，申请方式请参考 https://cloud.baidu.com/doc/WENXINWORKSHOP/s/4lilb2lpf
    "qianfan-api": {
        "version": "ERNIE-Bot",  # 注意大小写。当前支持 "ERNIE-Bot" 或 "ERNIE-Bot-turbo"， 更多的见官方文档。
        "version_url": "",  # 也可以不填写version，直接填写在千帆申请模型发布的API地址
        "api_key": "",
        "secret_key": "",
        "provider": "QianFanWorker",
    },

    # 火山方舟 API，文档参考 https://www.volcengine.com/docs/82379
    "fangzhou-api": {
        "version": "chatglm-6b-model",  # 当前支持 "chatglm-6b-model"， 更多的见文档模型支持列表中方舟部分。
        "version_url": "",  # 可以不填写version，直接填写在方舟申请模型发布的API地址
        "api_key": "",
        "secret_key": "",
        "provider": "FangZhouWorker",
    },

    # 阿里云通义千问 API，文档参考 https://help.aliyun.com/zh/dashscope/developer-reference/api-details
    "qwen-api": {
        "version": "qwen-turbo",  # 可选包括 "qwen-turbo", "qwen-plus"
        "api_key": "",  # 请在阿里云控制台模型服务灵积API-KEY管理页面创建
        "provider": "QwenWorker",
    },

    # 百川 API，申请方式请参考 https://www.baichuan-ai.com/home#api-enter
    "baichuan-api": {
        "version": "Baichuan2-53B",  # 当前支持 "Baichuan2-53B"， 见官方文档。
        "api_key": "",
        "secret_key": "",
        "provider": "BaiChuanWorker",
    },

    # Azure API
    "azure-api": {
        "deployment_name": "",  # 部署容器的名字
        "resource_name": "",  # https://{resource_name}.openai.azure.com/openai/ 填写resource_name的部分，其他部分不要填写
        "api_version": "",  # API的版本，不是模型版本
        "api_key": "",
        "provider": "AzureWorker",
    },

}

# 在以下字典中修改属性值，以指定本地embedding模型存储位置。支持3种设置方法：
# 1、将对应的值修改为模型绝对路径
# 2、不修改此处的值（以 text2vec 为例）：
#       2.1 如果{MODEL_ROOT_PATH}下存在如下任一子目录：
#           - text2vec
#           - GanymedeNil/text2vec-large-chinese
#           - text2vec-large-chinese
#       2.2 如果以上本地路径不存在，则使用huggingface模型
MODEL_PATH = {
    "embed_model": {
        "ernie-tiny": "nghuyong/ernie-3.0-nano-zh",
        "ernie-base": "nghuyong/ernie-3.0-base-zh",
        "text2vec-base": "shibing624/text2vec-base-chinese",
        "text2vec": "/home/hengyue/llm/dataroot/models/GanymedeNil/text2vec-large-chinese",
        "text2vec-paraphrase": "shibing624/text2vec-base-chinese-paraphrase",
        "text2vec-sentence": "shibing624/text2vec-base-chinese-sentence",
        "text2vec-multilingual": "shibing624/text2vec-base-multilingual",
        "text2vec-bge-large-chinese": "shibing624/text2vec-bge-large-chinese",
        "m3e-small": "moka-ai/m3e-small",
        "m3e-base": "/home/hengyue/llm/dataroot/models/moka-ai/m3e-base",
        "m3e-large": "moka-ai/m3e-large",
        "bge-small-zh": "BAAI/bge-small-zh",
        "bge-base-zh": "BAAI/bge-base-zh",
        "bge-large-zh": "BAAI/bge-large-zh",
        "bge-large-zh-noinstruct": "BAAI/bge-large-zh-noinstruct",
        "bge-base-zh-v1.5": "BAAI/bge-base-zh-v1.5",
        "bge-large-zh-v1.5": "BAAI/bge-large-zh-v1.5",
        "piccolo-base-zh": "sensenova/piccolo-base-zh",
        "piccolo-large-zh": "sensenova/piccolo-large-zh",
        "text-embedding-ada-002": "your OPENAI_API_KEY",
    },

    "llm_model": {
        # 以下部分模型并未完全测试，仅根据fastchat和vllm模型的模型列表推定支持
        "chatglm3-6b": "/home/hengyue/llm/dataroot/models/THUDM/chatglm3-6b",
        "chatglm2-6b": "/home/hengyue/llm/dataroot/models/THUDM/chatglm2-6b",
        "chatglm2-6b-32k": "THUDM/chatglm2-6b-32k",

        "baichuan2-13b": "baichuan-inc/Baichuan2-13B-Chat",
        "baichuan2-7b": "baichuan-inc/Baichuan2-7B-Chat",

        "baichuan-7b": "baichuan-inc/Baichuan-7B",
        "baichuan-13b": "baichuan-inc/Baichuan-13B",
        'baichuan-13b-chat': 'baichuan-inc/Baichuan-13B-Chat',

        "aquila-7b": "BAAI/Aquila-7B",
        "aquilachat-7b": "BAAI/AquilaChat-7B",

        "internlm-7b": "internlm/internlm-7b",
        "internlm-chat-7b": "internlm/internlm-chat-7b",

        "falcon-7b": "tiiuae/falcon-7b",
        "falcon-40b": "tiiuae/falcon-40b",
        "falcon-rw-7b": "tiiuae/falcon-rw-7b",

        "gpt2": "gpt2",
        "gpt2-xl": "gpt2-xl",

        "gpt-j-6b": "EleutherAI/gpt-j-6b",
        "gpt4all-j": "nomic-ai/gpt4all-j",
        "gpt-neox-20b": "EleutherAI/gpt-neox-20b",
        "pythia-12b": "EleutherAI/pythia-12b",
        "oasst-sft-4-pythia-12b-epoch-3.5": "OpenAssistant/oasst-sft-4-pythia-12b-epoch-3.5",
        "dolly-v2-12b": "databricks/dolly-v2-12b",
        "stablelm-tuned-alpha-7b": "stabilityai/stablelm-tuned-alpha-7b",

        "Llama-2-13b-hf": "meta-llama/Llama-2-13b-hf",
        "Llama-2-70b-hf": "meta-llama/Llama-2-70b-hf",
        "open_llama_13b": "openlm-research/open_llama_13b",
        "vicuna-13b-v1.3": "lmsys/vicuna-13b-v1.3",
        "koala": "young-geng/koala",

        "mpt-7b": "mosaicml/mpt-7b",
        "mpt-7b-storywriter": "mosaicml/mpt-7b-storywriter",
        "mpt-30b": "mosaicml/mpt-30b",
        "opt-66b": "facebook/opt-66b",
        "opt-iml-max-30b": "facebook/opt-iml-max-30b",

        "Qwen-7B": "Qwen/Qwen-7B",
        "Qwen-14B": "Qwen/Qwen-14B",
        "Qwen-7B-Chat": "Qwen/Qwen-7B-Chat",
        "Qwen-14B-Chat": "Qwen/Qwen-14B-Chat",
        "Qwen-14B-Chat-Int8": "Qwen/Qwen-14B-Chat-Int8",  # 确保已经安装了auto-gptq optimum flash-attn
        "Qwen-14B-Chat-Int4": "Qwen/Qwen-14B-Chat-Int4",  # 确保已经安装了auto-gptq optimum flash-attn
    },
}

# 通常情况下不需要更改以下内容

# nltk 模型存储路径
NLTK_DATA_PATH = os.path.join(os.path.dirname(os.path.dirname(__file__)), "nltk_data")

VLLM_MODEL_DICT = {
    "aquila-7b": "BAAI/Aquila-7B",
    "aquilachat-7b": "BAAI/AquilaChat-7B",

    "baichuan-7b": "baichuan-inc/Baichuan-7B",
    "baichuan-13b": "baichuan-inc/Baichuan-13B",
    'baichuan-13b-chat': 'baichuan-inc/Baichuan-13B-Chat',
    # 注意：bloom系列的tokenizer与model是分离的，因此虽然vllm支持，但与fschat框架不兼容
    # "bloom":"bigscience/bloom",
    # "bloomz":"bigscience/bloomz",
    # "bloomz-560m":"bigscience/bloomz-560m",
    # "bloomz-7b1":"bigscience/bloomz-7b1",
    # "bloomz-1b7":"bigscience/bloomz-1b7",

    "internlm-7b": "internlm/internlm-7b",
    "internlm-chat-7b": "internlm/internlm-chat-7b",
    "falcon-7b": "tiiuae/falcon-7b",
    "falcon-40b": "tiiuae/falcon-40b",
    "falcon-rw-7b": "tiiuae/falcon-rw-7b",
    "gpt2": "gpt2",
    "gpt2-xl": "gpt2-xl",
    "gpt-j-6b": "EleutherAI/gpt-j-6b",
    "gpt4all-j": "nomic-ai/gpt4all-j",
    "gpt-neox-20b": "EleutherAI/gpt-neox-20b",
    "pythia-12b": "EleutherAI/pythia-12b",
    "oasst-sft-4-pythia-12b-epoch-3.5": "OpenAssistant/oasst-sft-4-pythia-12b-epoch-3.5",
    "dolly-v2-12b": "databricks/dolly-v2-12b",
    "stablelm-tuned-alpha-7b": "stabilityai/stablelm-tuned-alpha-7b",
    "Llama-2-13b-hf": "meta-llama/Llama-2-13b-hf",
    "Llama-2-70b-hf": "meta-llama/Llama-2-70b-hf",
    "open_llama_13b": "openlm-research/open_llama_13b",
    "vicuna-13b-v1.3": "lmsys/vicuna-13b-v1.3",
    "koala": "young-geng/koala",
    "mpt-7b": "mosaicml/mpt-7b",
    "mpt-7b-storywriter": "mosaicml/mpt-7b-storywriter",
    "mpt-30b": "mosaicml/mpt-30b",
    "opt-66b": "facebook/opt-66b",
    "opt-iml-max-30b": "facebook/opt-iml-max-30b",

    "Qwen-7B": "Qwen/Qwen-7B",
    "Qwen-14B": "Qwen/Qwen-14B",
    "Qwen-7B-Chat": "Qwen/Qwen-7B-Chat",
    "Qwen-14B-Chat": "Qwen/Qwen-14B-Chat",

    "agentlm-7b": "THUDM/agentlm-7b",
    "agentlm-13b": "THUDM/agentlm-13b",
    "agentlm-70b": "THUDM/agentlm-70b",

}

# 你认为支持Agent能力的模型，可以在这里添加，添加后不会出现可视化界面的警告
SUPPORT_AGENT_MODEL = [
    "azure-api",
    "openai-api",
    "claude-api",
    "zhipu-api",
    "qwen-api",
    "Qwen",
    "baichuan-api",
    "agentlm",
    "chatglm3",
    "xinghuo-api",
]

已解决！原来加载模型是先加载到内存，再转到显存的。之前内存不够，加了内存条之后就可以了。

已解决！原来加载模型是先加载到内存，再转到显存的。之前内存不够，加了内存条之后就可以了。
请问你内存加到多少G呀？我的是2条16G的内存，启动的时候也是卡在这里： Loading checkpoint shards:  14%|████████▎                                                 | 1/7 [00:04<00:27,  4.63s/it]，看了下任务管理器性能，内存占用最高的时候还没到16G，不知道是哪里的问题

@zoneRohn

已解决！原来加载模型是先加载到内存，再转到显存的。之前内存不够，加了内存条之后就可以了。
请问你内存加到多少G呀？我的是2条16G的内存，启动的时候也是卡在这里： Loading checkpoint shards:  14%|████████▎                                                 | 1/7 [00:04<00:27,  4.63s/it]，看了下任务管理器性能，内存占用最高的时候还没到16G，不知道是哪里的问题

我24G就够用了！chatglm3-6b模型。估计加载模型占用13G左右。
一开始我也是卡住，可能是因为机械盘加载太慢，后来换到了固态上，就可以了，你可以试试看。

authors: WyingPer zRzRzRzRzRzRzR zoneRohn


text:
Upgrade to latest docusaurus

Upgrades to docusaurus v14 beta.

@PatelN123 Thanks for the changes. There is an error in deploying the changes. Would you be able to take a look at it?
11:08:08 AM: error @docusaurus/core@2.0.0-beta.14: The engine "node" is incompatible with this module. Expected version ">=14". Got "12.18.0"

Thanks @pranavrajs
I managed to deploy locally and through Netlify with no errors.
The site is hosted here: https://upbeat-curran-413939.netlify.app/docs/self-hosted/

Would you be able to add NODE_VERSION to the Netlify Environments? Under Build & Deploy > Environment. And set it to the Latest Current Version listed as 17.3.0 at https://nodejs.org/en/download/current/
I think this will solve this issue 🤔

Never mind, I managed to specify the node version through a file.
Works great now!

Merged this by mistake supposed to merge this one : https://github.com/chatwoot/chatwoot/pull/3685
I am reverting this PR for now as we need to test this first on netlify and on develop if the version is being supported or not.

@PatelN123 Can you open this PR against chatwoot:develop

@tejaswinichile We don't maintain a develop branch in docs.

authors: PatelN123 pranavrajs tejaswinichile vishnu-narayanan

repo: chatwoot/docs


text:
Update faq.md

Typo in point 1.
Before : User the channel
After : Use the channel

Thanks @ammaraslam

authors: ammaraslam pranavrajs


text:
feat: adds environment and refactors gitInfo to be more flexible

I hereby confirm that I followed the code guidelines found at engineering guidelines
Affected Components

[x] CLI
[ ] Create CLI
[ ] Test
[ ] Docs
[ ] Examples
[ ] Other

Notes for the Reviewer

enable overrides on the collected git info via env. vars. CHECKLY_TEST_REPO_SHA etc.
enable setting the environment with an env. var. CHECKLY_TEST_ENVIRONMENT

@nahuelon @clample @nahuelon this PR took way too much time but is pretty simple. Docs will follow on how folks can use the new env vars to tweak the Git info scraping.

repo: checkly/checkly-cli


text:
Long project name causes policy problem

User Story
Project ids can be up to 64 characters.
Policy ids can be up to 64 characters.
That presents an integration problem: Creating a project x begets three policies, x-project-owners, x-project-viewers, and x-project-editors.
So if x is longer than 48 characters then you cannot fetch the project.
On the command-line:
$ curl -sSkH "api-token: $TOK" -H "" "https://a2-dev.test/apis/iam/v2/policies/p123456789p123456789p123456789p123456789p123456789p123456789-project-viewers"
{
  "error": "invalid GetPolicyReq.Id: value does not match regex pattern \"^[a-z0-9-_]{1,64}$\"",
  "code": 3,
  "message": "invalid GetPolicyReq.Id: value does not match regex pattern \"^[a-z0-9-_]{1,64}$\"",
  "details": [
  ]
}

On-screen:

Definition of Done
Perhaps limit project names to 48 characters...?
Demo Script / Repro Steps

oh jeez, good catch!

we should probably do this with team names too, since we will be auto-generating the teams as well soon.

notes from standup 04/06

verify that we can update project names with more than 64 characters
limit project ids to 48 characters
re-think validation on fetch
do not worry about anyone who has already created a project id with more than 48 characters

authors: msorens susanev

repo: chef/automate


text:
adding proxy host logic

Signed-off-by: Daniel Bright danielcbright@gmail.com
:nut_and_bolt: Description: What code changed, and why?
I updated the automate-es-gateway logic to allow for the setting of the proxy_set_header Host value to be one of the users choosing. This will allow for external ES to work when using an external cluster that uses hostname based routing (think most Nginx load balancers, Elastic Cloud, and probably more). It sets the default to $http_host if it is not defined, which is the current behaviour.
To enable the setting you would add this to a config.toml during deploy or via a config patch:
[esgateway.v1.sys.ngx.http]
proxy_set_header_host = "yourawesomeexternaleshostname:1234"

:chains: Related Resources
The esgateway api config was also updated to reflect the changes.
:+1: Definition of Done
You can make the above changes, and they are reflected in the automate-es-gateway's final, rendered nginx.conf in the /hab/svc/automate-es-gateway/config/nginx.conf file.
:athletic_shoe: How to Build and Test the Change

start_all_services
create a custom patch.toml with the above settings
patch the chef-automate install
verify that the /hab/svc/automate-es-gateway/config/nginx.conf reflects the changes

:white_check_mark: Checklist

[x] I have read the CONTRIBUTING document.
[ ] Tests added/updated?
[x] Docs added/updated?
[x] All commits have been signed-off for the Developer Certification of Origin.

:camera: Screenshots, if applicable

👍

I've never used the suggested edit commit before, so apparently those two that I merged didn't have the DCO, how can I go back and add my Signed-off-by to those commits?

@danielcbright in the future you can add Signed-off-by: susanev <susan.ra.evans@gmail.com> (but with whoever suggested info) directly when you choose to commit that in the ui as the commit message.
as far as dealing with it now, i think ur gonna have to amend the commit from the command line if there's no new changes to commit. but only the last commit really needs one to pass that dco check.

@susanev @mjingle ok I've rebased/signed my last 2 commits, should be good now! thanks for the help

authors: danielcbright kavanista susanev


text:
Experiment around reindexing fixes (WIP)

This is an attempt to address an issue (#1586) we've seen when the indexer gets backlogged. We put a work item on the queue via a gen_server , and it is waiting to be indexed. But because it's backlogged, we don't get to it, and fail to reply to the caller before the 5 sec timeout fires. And so the server returns 500, and the client retries. However the indexer will eventually get to the item, and index it successfully. Indexing is basically the last thing we do in the request, and so we've successfully done all of the work, but the client still retries because we've told it has failed. This ends up causing load amplification on an already backlogged server.
This increases the timeout and attempts to do better error logging.
This PR as is is incomplete, as it doesn't check the call chain to see if there's something else that will timeout once this gen server timeout is increased.
Signed-off-by: Mark Anderson mark@chef.io

Resolved in #1945

repo: chef/chef-server


text:
homebrew_bin_path in homebrew_user doesn't deal with non-strings

Description

After updating to chef-client 18.3.0 on MacOS, we ran into issues where chef-client was no longer converging due to a bug introduced in the homebrew_user helper.
https://github.com/chef/chef/blob/v18.3.0/lib/chef/mixin/homebrew_user.rb#L64 calls which, which can return boolean values (specifically false here) as per https://github.com/chef/chef/blob/v18.3.0/chef-utils/lib/chef-utils/dsl/which.rb#L53
I think that the fix is that the code here needs to deal with all the possible return values of which, which includes booleans.
Chef Version

18.3.0
Platform Version

MacOS 10.15
Replication Case

Homebrew executable is located somewhere that is not in the PATH for the launchd that is running chef.
Client Output

[2023-09-19T16:47:45+00:00] ERROR: Running exception handlers
  - ChefRunRecorder::LastRunRecorder
Running handlers complete
[2023-09-19T16:47:45+00:00] ERROR: Exception handlers complete
Infra Phase failed. 10 resources updated in 05 minutes 18 seconds
[2023-09-19T16:47:45+00:00] FATAL: Stacktrace dumped to /var/chef/cache/chef-stacktrace.out
[2023-09-19T16:47:45+00:00] FATAL: ---------------------------------------------------------------------------------------
[2023-09-19T16:47:45+00:00] FATAL: PLEASE PROVIDE THE CONTENTS OF THE stacktrace.out FILE (above) IF YOU FILE A BUG REPORT
[2023-09-19T16:47:45+00:00] FATAL: ---------------------------------------------------------------------------------------
[2023-09-19T16:47:45+00:00] FATAL: TypeError: homebrew_package[openssl@1.1, autoconf, automake, libtool] (systems::packages line 228) had an error: TypeError: no implicit conversion of false into String

Stacktrace

TypeError: homebrew_package[openssl@1.1, autoconf, automake, libtool] (systems::packages line 228) had an error: TypeError: no implicit conversion of false into String
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/mixin/homebrew_user.rb:64:in `exist?'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/mixin/homebrew_user.rb:64:in `block in homebrew_bin_path'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/mixin/homebrew_user.rb:64:in `select'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/mixin/homebrew_user.rb:64:in `homebrew_bin_path'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/mixin/homebrew_user.rb:72:in `calculate_owner'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/mixin/homebrew_user.rb:47:in `find_homebrew_uid'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/provider/package/homebrew.rb:182:in `brew_cmd_output'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/provider/package/homebrew.rb:98:in `brew_info'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/provider/package/homebrew.rb:126:in `package_info'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/provider/package/homebrew.rb:146:in `installed_version'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/provider/package/homebrew.rb:52:in `block in get_current_versions'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/provider/package/homebrew.rb:51:in `map'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/provider/package/homebrew.rb:51:in `get_current_versions'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/provider/package/homebrew.rb:38:in `load_current_resource'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/provider.rb:228:in `run_action'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/resource.rb:601:in `block in run_action'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/resource.rb:628:in `with_umask'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/resource.rb:600:in `run_action'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/runner.rb:74:in `run_action'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/runner.rb:108:in `block in run_all_actions'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/runner.rb:108:in `each'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/runner.rb:108:in `run_all_actions'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/runner.rb:132:in `block in converge'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/resource_collection/resource_list.rb:96:in `block in execute_each_resource'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/resource_collection/stepable_iterator.rb:114:in `call_iterator_block'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/resource_collection/stepable_iterator.rb:85:in `step'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/resource_collection/stepable_iterator.rb:103:in `iterate'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/resource_collection/stepable_iterator.rb:54:in `each_with_index'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/resource_collection/resource_list.rb:94:in `execute_each_resource'
/opt/chef/embedded/lib/ruby/3.1.0/forwardable.rb:238:in `execute_each_resource'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/runner.rb:130:in `converge'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/client.rb:869:in `block in converge'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/client.rb:864:in `catch'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/client.rb:864:in `converge'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/client.rb:888:in `converge_and_save'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/client.rb:298:in `run'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/application.rb:305:in `run_with_graceful_exit_option'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/application.rb:281:in `block in run_chef_client'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/local_mode.rb:42:in `with_server_connectivity'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/application.rb:264:in `run_chef_client'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/application/base.rb:354:in `run_application'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-18.3.0/lib/chef/application.rb:67:in `run'
/opt/chef/embedded/lib/ruby/gems/3.1.0/gems/chef-bin-18.3.0/bin/chef-client:25:in `<top (required)>'
/opt/chef/bin/chef-client:180:in `load'
/opt/chef/bin/chef-client:180:in `<main>

This will be addressed with the next 18 release. Problem occurs if brew is not in the path, I believe, so ensuring brew exists in the path first is a potential workaround.

Will this fix be released soon? It seems like the 18.2.46 release now has this issue as well, and previous 18.2.x release (18.2.7) our CI was pinned at seems to not be available via omnibus currently.

This was released (and subsequently patched for a slight miss) as of 18.4.2.

authors: cisco-abrandel jazaval tpowell-progress

repo: chef/chef


text:
gpg/keyserver and apt_repository

Problem
apt_repository supports different ways to provide a gpg key/key id for a repository. A common way is to provide the key id and a public key server to fetch the key.
However it turns out that many public key servers and even key server pools like sks-keyservers.net are not very reliable, rate limited or sometimes unreachable. This usually breaks a chef-run and causes a lot of "false" positives in monitoring.
I might be wrong but it also looks to me that it's currently not idempotent, e.g. it fetches the key on each converge, at least on chef 12.
Suggestion for fix
I suggest to implement the following:

implement a default retry option for key fetching which is unrelated to the retries. (Most public cookbooks don't use retries)

allow to specify an array of key-servers that will be iterated on error.

Backport https://github.com/chef/chef/commit/c90401fa936353550b7658a2a9f4908cf6d27a40 to chef12 client (fixes idempotency)

Related / Real world example of the issue
https://github.com/chef-cookbooks/chef-apt-docker/pull/5

We use apt-key to do the actual install so not sure how far down the rabbit hole we want to go vs. declaring this an upstream issue :-/ retries should work already as that's a core feature of all Chef resources so you might want to solve it using that and wrappers or edit_resource.
If it isn't idempotent we should definitely fix that though, https://github.com/chef/chef/blob/master/lib/chef/provider/apt_repository.rb#L200-L203 is the relevant code.

So maybe the broken idempotency caused the increase in timeouts due to rate-limiting?

Can we get a backport of c90401f to chef12?

A backport would be nice, we still have some cookbooks that need updated before moving to Chef 13.

Chef 12 is maintenance only at this point and releases are cut (almost*) exclusively for security fixes so a backport is very unlikely to happen.

In chef 12 I it comes from the cookbook so it would need to be done there.

@majormoses Chef 12.9 included apt_repository which before was provided by the apt cookbook.

I'm closing this issues as Chef 14 is released and everyone should at least have upgraded to chef 13 in the meantime. (If you don't have, ask me for consultancy services ;)

authors: cheeseplus coderanger e100 majormoses rmoriz


text:
Add tags so Expeditor can manage chef-12 changelog

Signed-off-by: Tom Duffield tom@chef.io

Thanks


text:
loosen restriction for docker api

fixes #108

Kudos :smile:

authors: arlimus chris-rock

repo: chef/train


text:
New release

Hi, I noticed the the latest published release doesn't contain a couple of very useful commits that were added after the release of v1.5.1.
Are there any plans on creating and publishing a new release?
Greetings, Dennis

@denniscoorn v2 published, let me know if it works for you.

authors: chemerisuk denniscoorn


text:
Build chemfiles on ARMv7 / AARCH64

A few minor changes required to build and run chemfiles om ARM platforms.
I did not test on real hardware since I don't have any (anyone with a raspberry pi around?), but the code cross-compile (using https://gist.github.com/Luthaf/46c711a2f205ab99d81116848cd45ad3) and run with qemu, so this is a good first step.
I also got chemfiles to compile on PowerPC64 targets. There seems to be an endianness issue with the molfile DCD reader on ppc64le, and a lot a tests error with ppc64, so this will have to wait.

I also got chemfiles to compile on PowerPC64 targets. There seems to be an endianness issue with the molfile DCD reader on ppc64le, and a lot a tests error with ppc64, so this will have to wait.

Strangely, it seems that on native hardware the tests pass: https://build.opensuse.org/package/show/home:Luthaf/chemfiles, Fedora builders have a ppc64le version.

repo: chemfiles/chemfiles


text:
Comparison between GCMS spectra

[x] Integrate the mass in peaks
[x] "Vectorify" the MS
[x] Cosine similarity between two chromatograms

I think there is a mistake in
https://github.com/cheminfo-js/chromatography/blob/d9511a818cfb8e5ee6a4651521916fd89a78a727/src/cosine.js#L21
It should not be index2 ?
But this seems strange if your testcases pass ...

You should add test case with cosine that we can understand ...
Like:

[1,2,3], [1,1,1], [1,2,3], [1,1,1]
[1,2,3], [1,1,1], [1,2,4], [1,1,1]
[1,2,3], [1,2,3], [1,2,3], [1,2,3]
[1,2,3,4], [1,1,1,1], [1,2,4,5], [1,1,1,1]
[1,2,3,4], [1,1,1,1], [4,5], [1,1]
You should be able to calculate the result easily otherwise you may miss some mistakes

Wonder also if there is no mistake in https://github.com/cheminfo-js/chromatography/blob/d9511a818cfb8e5ee6a4651521916fd89a78a727/src/vectorify.js#L19
intPower should not be on something like peakList[i].ms.y[j] (and not x ?)

Is it normal there is 1.4 million lines ?

I'ts mainly the docs

authors: lpatiny maasencioh

repo: cheminfo-js/chromatography


text:
Compounds and ActivesOrNaturals need to use a route fromMF

this should solve the issue of different results for the same molecule if using positive or negative mode

duplicate

repo: cheminfo/docker-pubchem


text:
🛑 tt is down

In d6d1a09, tt (https://telebot-app-serverless-i7z8-chenhaonanniubi.vercel.app/checkhealth) was down:

HTTP code: 500
Response time: 2546 ms

Resolved: tt is back up in 4bb577d.

repo: chenhaonanniubi/upptime


text:
🛑 tt is down

In 22de640, tt (https://telebot-app-serverless-i7z8-chenhaonanniubi.vercel.app/checkhealth) was down:

HTTP code: 504
Response time: 10112 ms

Resolved: tt is back up in 6dbfc72 after 10 minutes.


text:
🛑 tt is down

In d535322, tt (https://telebot-app-serverless-i7z8-chenhaonanniubi.vercel.app/checkhealth) was down:

HTTP code: 500
Response time: 3436 ms

Resolved: tt is back up in eadd3a3 after 15 minutes.


text:
🛑 tt is down

In 97533a3, tt (https://telebot-app-serverless-i7z8-chenhaonanniubi.vercel.app/checkhealth) was down:

HTTP code: 500
Response time: 2210 ms

Resolved: tt is back up in a00db4a after 17 minutes.


text:
Cross-platform npm script support

The way environment variables are set in npm scripts within package.json are not supported on all platforms.

Fixed via #19

authors: chentsulin jmfirth

repo: chentsulin/generator-redux-app


text:
🛑 Tuits borrados (Politwoops) is down

In 23a25ce, Tuits borrados (Politwoops) (https://chequeado.com/tuitsborrados) was down:

HTTP code: 503
Response time: 18 ms

Resolved: Tuits borrados (Politwoops) is back up in 90a02b6.

repo: chequeado/status


text:
🛑 Chequeo Colectivo is down

In bb92077, Chequeo Colectivo (https://chequeado.com/colectivo) was down:

HTTP code: 502
Response time: 9089 ms

Resolved: Chequeo Colectivo is back up in 9ac0378.


text:
[Fix][WRS-1658] Add PDF export (out of experimental)

This PR adds PDF as the export setting

Approved by aqa

repo: chili-publish/studio-ui


text:
Missing equals

https://github.com/chinarulezzz/pixload/blob/dd41770405a257df862b489a625343ea12721dd5/bmp.pl#L30
Some of the sample payloads miss the = sign in the source attribute, is that intentional/needed for the file format or an oversight?

ah ok. its also in jpg and readme

repo: chinarulezzz/pixload

license: WTFPL


text:
Optimize passing going from a Rust std::string::String to a Swift String

This issue was born from a discussion on the Rust reddit

Problem
Today, in order to go from a Rust std::string::String to a Swift String we need to:

Box::into_raw(Box::new(string)) the rust std::string::String to get a raw pointer to the String (one allocation) https://github.com/chinedufn/swift-bridge/blob/38699d43bf998ff8698ba03039663bc92a634bbc/crates/swift-bridge-ir/src/codegen/codegen_tests/string_codegen_tests.rs#L135

Send the pointer to Swift

Allocate a RustString(ptr: ptr) class instance https://github.com/chinedufn/swift-bridge/blob/38699d43bf998ff8698ba03039663bc92a634bbc/crates/swift-bridge-ir/src/codegen/codegen_tests/string_codegen_tests.rs#L142-L144

Call rustString.toString(), which allocates a swift String https://github.com/chinedufn/swift-bridge/blob/d4d97e462672aed7827d76abbccb9aab255c9e9d/src/std_bridge/string.swift#L27-L46

The class RustString on the Swift side has a deinit method that calls into Rust to deallocate the Rust std::string::String

When returning  a Rust &mut String such as:
extern "Rust" {
    type Foo;
    fn get_mut_string(&self) -> &mut String;
}

we want a class RustStringRefMut on the Swift side that exposes methods to access / mutate the underlying Rust std::string::String.
However, when returning an owned String such as:
extern "Rust" {
    type Foo;
    fn get_owned_string(&self) -> String;
}

there is no reason to have the intermediary class RustString since we don't need Rust to manage the underlying std::string::String.
Instead we want to go directly from Rust std::string::String to Swift String.
Open Questions
This entire issue still needs some more thought on planning... We need to think through all of the implications.
Here are a list of things to think through that we can add to over time:

[ ] If we called shrink_to_fit on the std::string::String before passing it over to Swift we'd only need the pointer and length in order to de-allocate it later.. If we use a CFAllocatorContext (illustrated in the comment below... func rustDeallocate) in order to de-allocate the std::string::String whenever Swift no longer needed it... we'd have the pointer to the bytes.. but how would we get that len? Or do we need another approach..? Could have a global de-allocator on the Rust side that looked up lengths in something like a  HashMap<String pointer, String length> in order to de-allocate Strings... But perhaps there's a simpler/smarter approach to all of this..?

Here's an example of going from a buffer if utf8 bytes to a Swift String

// FIXME: Delete this.. Just trying some stuff out
func testNewStringPassingApproach() throws {
    var string = makeString()

    string.utf8CString.withUnsafeBytes({buffer in
        print(
"""
String buffer before mutation \(buffer)
"""
        )
    })

    string += "."

    string.utf8CString.withUnsafeBytes({buffer in
        print(
"""
String buffer after mutation \(buffer)
"""
        )
    })

    print(string)
}

var RustStringDeallocator: CFAllocatorContext = CFAllocatorContext(
    version: 0,
    info: nil,
    retain: nil,
    release: nil,
    copyDescription: nil,
    allocate: nil,
    reallocate: nil,
    deallocate: rustDeallocate,
    preferredSize: nil
)

func rustDeallocate(_ ptr: UnsafeMutableRawPointer?, _ info: UnsafeMutableRawPointer?) {
    print(
        """
Deallocating pointer \(ptr)
"""
    )
}

// https://gist.github.com/martinmroz/5905c65e129d22a1b56d84f08b35a0f4
func makeString() -> String {
    let buffer = UnsafeMutableBufferPointer<UInt8>.allocate(capacity: 11)
    let _ = buffer.initialize(from: "hello world".utf8)

    print(
"""
Allocated String buffer \(buffer)
"""
    )

    let bytes = buffer.baseAddress!
    let numBytes = buffer.count

    let stringDeallocator = CFAllocatorCreate(kCFAllocatorDefault, &RustStringDeallocator)

    // https://developer.apple.com/documentation/corefoundation/1543597-cfstringcreatewithbytesnocopy
    let managedCFString = CFStringCreateWithBytesNoCopy(
        kCFAllocatorDefault,
        bytes,
        numBytes,
        CFStringBuiltInEncodings.UTF8.rawValue,
        false,
        // Should be kCFAllocatorNull for &str
        // TODO: take retained or unretained ?
        stringDeallocator?.takeUnretainedValue()
    )

    let cfStringPtr = CFStringGetCharactersPtr(managedCFString!)
    print("CFString pointer: \(cfStringPtr)")

    let managedString: String = managedCFString! as String

    managedString.utf8CString.withUnsafeBytes({buffer in
        print(
"""
String initial buffer \(buffer)
"""
        )
    })

    return managedString
}

Output
Allocated String buffer UnsafeMutableBufferPointer(start: 0x00007fe045f23330, count: 11)
CFString pointer: nil
String initial buffer UnsafeRawBufferPointer(start: 0x0000600003088230, count: 12)
String buffer before mutation UnsafeRawBufferPointer(start: 0x0000600003088230, count: 12)
Deallocating pointer Optional(0x00007fe045f23330)
String buffer after mutation UnsafeRawBufferPointer(start: 0x00006000030882f0, count: 13)
hello world.

It looks like in between going from our raw utf8 byte buffer to our Swift String the bytes seemingly get copied to a new address.
Not sure why.. need to look into whether or not it's possible to remove that copy.

Hmm.. it seems like there isn't a zero-copy way to construct a Swift String today https://forums.swift.org/t/does-string-bytesnocopy-copy-bytes/51643/3 .

So.. this all needs some more design thinking.... For example.. if you're reading a 1Gb file into a String and then passing that to Swift, you probably don't want any avoidable copies.

We need to think through cases where we'd want to immediately copy bytes from a Rust std::string::String to a Swift String and when we'd instead want to have an intermediary RustString Swift class. Do we need to be able to annotate functions to indicate how owned Strings should be passed? What would the default be? Things like that need to be answered.

I have a simple suggestion.
When we want rust to have an ownership, annotate such as:
extern "Rust" {
    #[swift_bridge(ownership = "rust")]
    fn get_value()->String;
}

/// Generated Swift code
func get_value()->RustString{
   //...
}

When we want swift to have an ownership, annotate such as:
extern "Rust" {
    #[swift_bridge(ownership = "swift")]
    fn get_value()->String;
}

/// Generated Swift code
func get_value()->String{
   //...
}

By default, I think swift should have an ownership because a swift-bridge beginner(such as me) expects to be able to use String directly.

When we pass the owned Rust String over to Swift we don't want  Rust ownership of the String.
We'd much prefer for it to always immediately become a Swift String once we pass it over.
The only reason that we don't do that is that right now this would involve copying all of the Rust String's bytes to a new Swift String's memory address. We don't want to do any copying without the user explicitly calling .toString().
If Swift had a zero-copy way to construct a Swift String, we would immediately turn the Rust String into a Swift String and delete the RustString type.
Here's how things would ideally work.
#[swift_bridge::bridge]
mod ffi {
    extern "Rust" {
        // On the Rust side when this is called we would immediately
        // `std::mem::forget` the String.
        // !! THIS IS NOT HOW THINGS WORK TODAY !!
        fn make_string() -> String;
    }
}

// Swift

// Generated code
func make_string() -> String {
    // In here the automatically generated code will construct
    // a Swift String that points to the same memory address that
    // the Rust String did.
    // This means that , we've created a a Swift String from a Rust String
    // without any copying.
}

So, before exploring any annotation based approaches I think we'd want to research whether or not it is, or will ever be possible to construct a Swift String without copying.
If it is or ever will be possible, then that would be a much better approach than annotating functions.

authors: NiwakaDev chinedufn

repo: chinedufn/swift-bridge


text:
[WIP] Make test-fmc use FIRMWARE_LOAD to trigger the update reset.

This is necessary to work around the race condition in #786.

Will probably also want to make the same change here.

(Waiting for verilator tests to run to confirm that this fully fixes #786)

Confirmed that the tests passed under verilator.

repo: chipsalliance/caliptra-sw


text:
Autoc-ompletion feature request

I am trying to get neovim lsp autocomplete working.
I followed the steps as listed in the README file.
I wrote a sample file with a couple of classes. Very simple example is:
`
class aVeryLongName;
endclass : aVeryLongName
class bVeryLongName;
aVe <<<<------ there is nothing suggested in autocomplete here
endclass : bVeryLongName
`
Trying to figure out how to debug it from here. I also tried adding the project level file and that didn't solve this either.
I am able to see other LSP features such as warnings on bit-width mismatches, trailing whitespaces, etc however, nothing for autocompletion.
Any idea what might be missing?

This is expected, as there are no auto-completion features yet implemented in the language server.
Can you give examples where you'd like to have completion support ? The needs are often different, so I like to understand what are the most common ones. I personally would like to have support for e.g. auto-suggestion of fields in a struct.

The Veridian SystemVerilog Language server implements a completion engine that pulls basic completion options from multiple context sets, found here.
Their approach was to break completion requests into the following Contexts:

Keywords (assert, assign, begin, end, if, else ...)
System Tasks (error, info, timeformat, random ...)
Directives (ifndef, endif, include, timescale ...)

When a completion request is triggered by the server, the context is determined (e.g. a '$' character would imply a System Task) and the appropriate pool of keywords is parsed for completion suggestions. The main completion engine can be found here.
I like this approach as it provides enough filtering to provide relevant completion options without much complexity, and implementing a similar system in Verible would greatly benefit the Language Server.

For me the struct capability and class members are the most valuable short term capabilities.

authors: aGhandhii adibis allRisc hzeller

repo: chipsalliance/verible


text:
UHDM Plugin: Very slow string comparison

Nearly 11% of the profile in the UHDM plugin is running this block of code.
https://github.com/chipsalliance/yosys-f4pga-plugins/blob/main/systemverilog-plugin/UhdmAst.cc#L1200-L1202
Is there something we can do to speed this up?

Some of my thoughts are can we create a temporary hash_map for AST::Nodes and their children
Can we compare a cheaper property than its name. Maybe it's type first?

@kamilrakoczy Can you take a look, or suggest a path forward. I can send a PR

This function should become obsolete if we switched to the elaborated model in UHDM.
If we used the elaborated model, each module instance would only get processed once. Thus removing the need for replacing any of their children.
It would also significantly simplify the module handling code.
I was experimenting with it for a bit, but ran into many issues. Some of our assumptions in the frontend no longer held up when using the elaborated model.
You can take a look at my (fairly stale) branch: https://github.com/antmicro/yosys-f4pga-plugins/commits/kbieganski/uhdm-plugin/elaborated-model
(Remember to use the -elabuhdm flag in Surelog for this to work in any way)
The main changes are

https://github.com/antmicro/yosys-f4pga-plugins/commit/7b8794febaecc827b973499789785fdb9df7c071#diff-0de03cd2799cd71f0b7bb897fe3c50a057d26a822810348b9bdb4acf24e9cdfbL1283-R1286
https://github.com/antmicro/yosys-f4pga-plugins/commit/7b8794febaecc827b973499789785fdb9df7c071#diff-0de03cd2799cd71f0b7bb897fe3c50a057d26a822810348b9bdb4acf24e9cdfbL1354-R1465

Instead of going through uhdmallModules and then through uhdmtopModules and replacing nodes, we only iterate over uhdmtopModules. So we no longer worry about 'partial' modules that we clone and fill in. We simply create a new module for each instance (of course if a module doesn't use parameters, this is unnecessary; I think reusing parameterless modules shouldn't be an issue).
The rest is a consequence of those changes: an attempt to fix memories, more complex handling of vpiRefObj as the elaborated model sometimes actually puts operations in place of those (it happens for assignment patterns IIRC). With new versions of Surelog these parts may be completely outdated.
Feel free to take over, as I won't be able to continue this any time soon.

Is it ever the case that we would want to replace a child whose name is the same, but type is different?

Is it ever the case that we would want to replace a child whose name is the same, but type is different?

I don't think there is a case like this at the moment. There used to be one when we were replacing parameter and localparam nodes, but it seems to be resolved now in UHDM.

authors: QuantamHD kbieganski rkapuscik


text:
can't authenticate

$ cloudplaya authenticate --username my@email.address --password my_password
Unable to write authentication data: HTTP Error 404: NotFound

Looks like amazon may have changed the way the login works. I'm having a similar problem with the PHP version I made of this script (mine's at https://github.com/micah1701/ACP-API). If I find a solution, I'll post here but I don't have a ton of time to dig into it right now

I'm sorry everyone, I wish I had time to dig into this.. All my time right now is going into my company's product, Review Board. I haven't had time to do any maintenance on cloudplaya in a good long while.
Sadly, Amazon never published any real API for this service. I completely understand it, but it means there's no future-proof way of performing authentication or any of the other operations needed. Theoretically, the mobile apps are using something stable but undocumented, and if someone could MITM their own connection for that to find out what it is, they'd be in better shape of figuring out a better long-term way of working with all this.


text:
Feature: Add support for fake_rx_time

This is a useful feature in the Gateway Bridge for non-GPS gateways. It has a been mentioned on the forum as a roadblock to converting from Gateway Bridge, and I've experienced similar.
Thanks.

I believe this belongs to the concentratord : https://github.com/chirpstack/chirpstack-concentratord/issues/49

Negative, this feature request is for a setting comparable to what has existed in Gateway Bridge for a long time and works with the Semtech UDP forwarder. There are a number of gateways where I prefer not to use concentratord in favor of the buddled packet forwarder.

My bad you are right, I thought fake_rx_time was already in the Semtech UDP Packet Forwarder and this feature was for other backends.

Hi @bconway and @mullerch the above commit implement the requested feature. I named it time_fallback_enabled as we are not really faking a time, we are providing a less accurate time in as a fallback.

authors: bconway brocaar mullerch

repo: chirpstack/chirpstack-mqtt-forwarder


text:
Streaming Data via Post Request not Supported by Web Application Firewall with Packet Inspection

Background
In Chirpstack v3, the Events and LoRaWAN frames streaming was done via web socket. We recently upgraded from Chirpstack v3 to v4 which worked without any issues. However, the event streaming is Chirpstack v4 is apparently now done via a never ending post request. We are using a WAF (Web Application Firewall) to protect the Chirpstack UI and apparently the packet inspection requires the post request to finish before any data is forwarded to the client. This therefore breaks the events streaming feature in the web UI.
The Issue
Opening the Events page for a device or the LoRaWAN frames page for a gateway or a device loads indefinitely. This is due to packet inspection which requires a request to finish before any data is forwarded to the client.
Workaround
We investigated this issue for some time and found out that if we were using nginx as a reverse proxy (according to the config found here) between Chirpstack and the WAF, after about a minute, the Events would show up and the post request to /api.InternalService/StreamDeviceEvents finishes with status code 200 but with the Firefox error NS_ERROR_NET_PARTIAL_TRANSFER. This was because the default nginx grpc reverse proxy read timeout to the backend server (chirpstack) is 60s. Setting this lower allows for the frames to show up faster and since the web UI opens a new post request if the old one was closed. We are using the following nginx config as a workaround for now:
location ^~ /api {
    grpc_read_timeout 5s;
    grpc_pass grpc://127.0.0.1:8080;
}

Solution
Please look into this issue and use a different way to stream data. I know this would be hard to reproduce, since technically this error is partly due to packet inspection. However, I would argue that this is mainly an application issue since using this without a WAF and nginx as reverse proxy would cancel the post request every minute anyway and would force the web UI the create a new post request. Furthermore, streaming data via a post request isn't exactly best practice in the frontend, that's what web socket is for. The issue seems to be due to the grpc-web library used to translate the gRPC HTTP to HTTP used be the web browser. I haven't looked further into if that library supports streaming via web socket, I would guess it doesn't. The best solution imho would be to not use gRPC in this case and create a separate web socket api for this event streaming, like it was previously done in Chirpstack v3.

Please look into this issue and use a different way to stream data. I know this would be hard to reproduce, since technically this error is partly due to packet inspection.

You can find more details about gRPC-web here:
https://github.com/grpc/grpc/blob/master/doc/PROTOCOL-WEB.md
Wouldn't it be possible (based on headers for example) to configure your application firewall to transparently proxy the gRPC(-web) data?

Please see "Server-side Streaming RPCs" :)
On Wed, Dec 6, 2023, 17:07 Morpheus0x @.***> wrote:

According to the grpc-web readme
https://github.com/grpc/grpc-web#streaming-support gRPC streaming to
the client isn't supported yet!
—
Reply to this email directly, view it on GitHub
https://github.com/chirpstack/chirpstack/issues/333#issuecomment-1843308000,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AABIM6M5MAXE6A7D4JVR3BLYICQ4LAVCNFSM6AAAAABAJWGXX2VHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNBTGMYDQMBQGA
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>

Please see "Server-side Streaming RPCs" :)

Yes, Server-side streaming does work, but like the name says, it isn't intended to be used to communicate with a web browser, which is the case here.

Wouldn't it be possible (based on headers for example) to configure your application firewall to transparently proxy the gRPC(-web) data?

The WAF only forwards HTTP communication, it is used as a reverse proxy, transparent inspection must be enabled for the whole WAF which reduces the features set we require. It doesn't specifically support gRPC, which in general shouldn't be an issue using grpc-web, except when streaming data to the client, which isn't supported yet.
According to the roadmap for streaming, they are planning to use WebTransport, but it is unclear when this will be implemented exactly. Also, WebTransport uses the HTTP/3 protocol and currently gRPC has some issues working with HTTP/2, Chirpstack for example, doesn't work if HTTP/2 is enforced.

Yes, Server-side streaming does work, but like the name says, it isn't intended to be used to communicate with a web browser, which is the case here.

Please see the definition within the gRPC context here:

Server streaming RPCs where the client sends a request to the server and gets a stream to read a sequence of messages back. The client reads from the returned stream until there are no more messages. gRPC guarantees message ordering within an individual RPC call.

This is exactly how it is implemented within ChirpStack. The client (browser) makes a request to the server (e.g. indicating the Gateway ID or DevEUI) and gets a stream (Server > Client) that it can read.
https://grpc.io/docs/what-is-grpc/core-concepts/

I have been thinking about this yesterday, but I'm not planning to make implementation changes. It works well:

Stand-alone
With Nginx as reverse-proxy (+ grpc proxy config)
With for example Cloudflare in front (+ grpc enabled)

I don't know which WAF service or product you are using. Maybe your WAF does not support gRPC or it needs additional configuration (note that this might also cause issues when using gRPC / not gRPC-web). Maybe you could just white-list the API parameters for which it shouldn't do deep packet inspection?
Adding a Websocket based API would mean:

A new API interface
Additional authentication / authorization layer
Additional logging layer

For the sake of complexity, security, maintainability and time investment I do not think this is worth it to create an API interface parallel to what is provided by gRPC and gRPC-web.

repo: chirpstack/chirpstack


text:
Fix access token validation

Commit c2b284118f7579f2a07f60d260b4383069ad083a caused a regression in
the CLI because JWT validation in getAccessToken() is broken.
Before:
$ turso db create
Error: could not create database comic-humbug: Authentication required

After:
$ turso db create
Error: user not logged in, please login with turso auth login

I still see the regression:
╰──> ./turso db list
Error: failed to get database listing: 401 Unauthorized

authors: haaawk penberg

repo: chiselstrike/turso-cli


text:
cant buy or bid on players using web app

after using the script this year I am now unable to buy or bid on players through the web app, but can still buy and bid using the companion app. has anyone else had this? this is the error message i get when i try to buy or bid.

is this a soft ban? if so how to prevent it using safety settings on the autobuyer?

Diminuisci il numero di ricerca ed aumenta la durata di pausa

license: ISC


text:
Resin Calculator subtraction buttons can no longer be clicked on in Brave browser

Low priority, since this issue only seems to happen while using the Brave browser.
https://i.imgur.com/ZHJQBCA.gif
Works fine in Google Chrome and Mozilla Firefox.

As a workaround, you can still manually type into the calculator by clicking on the number.

Yeah, been doing just that.
Would it be possible to also add keyboard shortcuts for those subtraction commands?

Sure, let's keep this issue focused on the Brave browser bug and create a new issue.

Which version of Brave browser are you using? I cannot reproduce this issue on the latest release. Can you try updating and restarting the browser and see if the problem persists?
Version 1.17.75 Chromium: 87.0.4280.88 (Official Build) (64-bit)

Same Brave version. Restarting the browser/computer didn't fix the issue the past two days I was having it, but with your most recent update it looks like it fixed itself. It was probably something on my end I couldn't track down, so I'll close the issue. Sorry for your time.

repo: chiyadev/genshin-schedule


text:
(GH-757) Introduce concept of Allowed Commands

This will allow us to control "what" commands are allowed within the Chocolatey GUI interface.

@AdmiringWorm @mkevenaar can I also get your comments on this?  Thanks

Relates to #757

repo: chocolatey/ChocolateyGUI


text:
Fix tests chocolatey download url

See issue #111.

You need to integrate #109 first.

Like it.

:+1:

Restarted TravisCI.

Well it passed in 2.1.5 - failed in the others - https://travis-ci.org/chocolatey/puppet-chocolatey/builds/97406614

Or I should say, passed in Puppet v4+.

It's likely that both false and 3 are treated as strings in Puppet v3.

@empi89 have a look at https://github.com/chocolatey/puppet-chocolatey/blob/9219ee0dfe36084249a4e0f2309ef52b46862110/spec/classes/init_spec.rb#L68-L121 for a hint on how you will need to fix this.

I have just rebased this commit to current master. I will check your suggestion tomorrow.

works with puppet 3 now :-) :+1:

Interesting way about it, like it!

authors: empi89 ferventcoder stefandollase

repo: chocolatey/puppet-chocolatey


text:
Update README.md

It actually does support TypeScript!

Yeah, but then why do you wanna remove it from the readme?:D

Oh gosh. I guess I somehow completely misread it..?

authors: chooklii evrys

repo: chooklii/num-words-de


text:
Add LimitNOFILE support for systemd

I had to set LimitNOFILE to make nats work with high amount of TCP connections. This is equal to ulimit -n: https://www.freedesktop.org/software/systemd/man/systemd.exec.html

squashed, updated commit message, opened issue, extended readme

this is perfect, put the lock file back and we're good to go :)

@ripienaar done

thanks a lot @bastelfreak

authors: bastelfreak ripienaar

repo: choria-io/puppet-nats


text:
ds4drv joystick device is added and removed dynamically.

It would be great if inputs were created dynamically.
Starting ds4drv at boot, it will always use js0. If we do not use the PS4 controller, some emulators will reserve the first player for js0.
I think the best way is to run the dynamic creation as it is done in Sixad PS3.

I would be ok with merging some --dynamic option that makes ds4drv do this.

I should add that if you've got a ds4drv daemon already running in the background, and you plug in the controller and reads from a config file, it'll move the controller to /dev/js1 because it thinks /dev/js0 is already taken by the daemon with another controller, instead of hooking into the already existing daemon, so you end up what looks like multiple controllers connected to the system when there is only 1 connected. This is also further shown when you open up jstest GUI app, it'll show as if two controllers are connected at once, this can somewhat cause issues when reading the ds4drv.conf file and some readings of the configurations not working properly.

authors: Alkaris Ape leosmeira


text:
cannot set player args with mpv

trying to set :
--player-args screen=2 geometry=+50+50
and get:
error: Failed to start player: /Applications/mpv.app/Contents/MacOS/mpv (Process exited prematurely)
mpv works fine with no arguments, but if i put --player-args with no arguments it tells me it is expecting an argument

You must include {filename} somewhere in the --player-args or mpv will not know what to play.
It’s usually enough to just use --player instead though, unless you need to add arguments after the filename.
For example,  --player 'mpv --screen=2 --geometry=+50+50'.

Thank you!

authors: WatermelonDriveway chrippa

repo: chrippa/livestreamer


text:
setOnItemClickListener missing?

Hi Chris,
Is there a way I can get the selected item in the list? I don't see setOnItemClickListener, and when I tried to add setOnClickListener to View in getView, xml styling for "pressed" doesn't work somehow.

Use getRefreshableView().setOnItemClickListener()

authors: chrisbanes tienn

repo: chrisbanes/Android-PullToRefresh


text:
Remove debug functionality

Closes #3

done! 1.0.6

authors: chrisbolin newyork-anthonyng

repo: chrisbolin/react-detect-offline


text:
Add missing silent param in csv#CalculateColumnWidth() call.

A correction of calls to csv#CalculateColumnWidth(), in relation with issue #152

thanks!

authors: chrisbra pkrog

license: Vim


text:
Doesn't work with Get/Set KJNodes

I'm not sure which extensions bug this is, but when I try to use the AE? node in combination with Get/Set KJNodes, something breaks with the links.
got prompt
Failed to validate prompt for output 14:
* CLIPTextEncode 9:
  - Exception when validating inner node: '2'

Why would you use them both together ?!

😅😅
I was organizing my "globals" into a section where I pass the get results into a bunch of UEs with varying RegEx's to allow me to determine all node inputs by the groups they are in.
This let me keep the "set" areas clean by just having a small collapsed node next to the load checkpoint, or clip text encode.
I'll upload a pic in a few hours
My thinking is this wouldn't be too hard for somebody who's more familiar with the node graph and linking structure. I think the UEs are setting the input on the matching nodes to the virtual Get node's ID, rather than the Set nodes ID. I could definitely be wrong though, as I've only put about 30 min into this so far.
If you aren't able to take a look, I would appreciate if you could share some info about which functions in your code would probably be the best place to start looking. Also could you explain what upstream and downstream represent, I'd assumed they were the inputs and matched targets, but thought I was seeing the UE node ids as a downstream, but it's also possible I was getting nodeID and array indexes mixed up in the debugger 😭

repo: chrisgoringe/cg-use-everywhere


text:
Why not find 2.2.0 in jcenter?

I can't gradle the project, because gradle can't download it. Is the jcenter delete it ?

well the dep is in maven and jcenter mirrors maven. Not sure. I only include jcenter in my gradle and it works. might just be there site which is out of date...

Also no one else has complained about this, reopen if still an issue. (Also might need to refresh your deps).

> Could not find calligraphy.aar (uk.co.chrisjenx:calligraphy:2.2.0).
  Searched in the following locations:
      https://jcenter.bintray.com/uk/co/chrisjenx/calligraphy/2.2.0/calligraphy-2.2.0.aar

Same problem here.. @chrisjenx could have been removed from jCenter()?

Yeah I'm not sure as https://jcenter.bintray.com/uk/co/chrisjenx/calligraphy/2.2.0/calligraphy-2.2.0.aar this actually resolves for me. I don't push to jcenter, I push to mavenCentral which sync's with jCenter.

alternatively, you can use https://jitpack.io and paste this repo.

Nope nope nope nope, that is a horrible broken distribution model. Part of
me publishing a version is a contract that it works and it's built in a
reliable way, jitpack breaks all those things.
On Thu, 15 Sep 2016, 05:05 darien toh, notifications@github.com wrote:

alternatively, you can use https://jitpack.io and paste this repo.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/chrisjenx/Calligraphy/issues/296#issuecomment-247228959,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ABHRsR8MbGc9z1iMawChyUNnbbEqVkPDks5qqMQMgaJpZM4Ivx3D
.

noted with thanks. i saw something broken in the build log yet it still allow to distribute to user.

Yeah, there's a divide in the community. You can guess which side I'm on :)
On Thu, 15 Sep 2016, 08:37 darien toh, notifications@github.com wrote:

noted with thanks. i saw something broken in the build log
https://jitpack.io/com/github/chrisjenx/Calligraphy/v2.2.0/build.log
yet it still allow to distribute to user.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/chrisjenx/Calligraphy/issues/296#issuecomment-247258216,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ABHRsefR-egXLs50lrKGRmmgY6OkVfohks5qqPWsgaJpZM4Ivx3D
.

authors: alexsimo caik13 chrisjenx tohjg

repo: chrisjenx/Calligraphy


text:
Feature request: allow atexit-style application cleanup

I occasionally use Gooey to wrap CLI apps for internal distribution (primarily on Windows, but also some Linux).  I recently had to wrap a script that runs until canceled.  Prior to program exit, it tabulates some data and generates a graph.  I handle the graphing as a post-termination cleanup through the atexit module (but I have also trapped SIGKILL and SIGTERM to see if that works).
When the Gooey wrapper stops the underlying process, it appears that the atexit hooks aren't performed; and (apparently) due to wxWindow signal / exit handling in onClose, none of my efforts at writing a signal handler work, either.  It would be nice to be able to inject a function call prior to destroying the wrapper for any application-land cleanup.
OS:  Linux and Windows
Python 3.7+

Yeah, this is a good call out. It's in the backlog of things to get done -- I forgot about it until now. Original issue is here. Closing this one in favor of the original.
I'll get it into the next release! :+1:

Yeah, this is a good call out. It's in the backlog of things to get done -- I forgot about it until now. Original issue is here. Closing this one in favor of the original.
I'll get it into the next release! 👍

Thanks a bunch, Chris!  I'll dig at this if I have some extra time and see about submitting a patch, but it'll be delayed.

authors: chriskiehl methanm

repo: chriskiehl/Gooey


text:
Cannot store more than 1GB in volume with Docker

I run seaweedfs in a docker container on my Synology NAS, which has around 45TB storage. The following is how I run the container.
docker run --name seaweedfs-s3 -d \
  --restart unless-stopped \
  -p 9333:9333 -p 8333:8333 -p 8080:8080 -p 18080:8080 \
  -v /volume1/seaweedfs/data:/data chrislusf/seaweedfs \
  server -dir="/data" -volume.max=1500 -s3

I was uploading large files (300-500M) via S3 API and very soon seaweedfs complaint no free volume available. I found the size of the *.dat files are all around 1GB, which was not the expected 32GB. I have a dev/test environment (non-Docker) running on Ubuntu and the size of the *.dat could reach 30GB. Is there anything I configured incorrectly or if it is a problem with the Docker version?

I pulled the latest 13 days ago and just notice a fresh new latest is available. Restarted the container with the latest images seem the problem is resolved.

The docker image has fixed volume max size to 1GB. You need to overwrite the setting weed server -master.volumeSizeLimitMB=30000

authors: Joseph-Hui chrislusf

repo: chrislusf/seaweedfs