remove User trait

removes the currently implemented User and traits. Leaves these application specific which attach to the Daemon with channels.
This basically requires running the Daemon from the application User process, but that should be fine I think.
In an attempt to remove duplicated code, I have the SendTransaction use the same kind of channel to send user primitives to the daemon. It makes an extra sender whose receiver is immediately dropped.
Maybe there is a better way that doesn't coping the same match block around twice.
@xpromache is this what you hand in mind about removing the current User trait and implementation?
Still having the trouble that it needs the one off because of the multiplexed users in the testing.

hmm except windows does not appear to be happy about the removal of a set of channels :thinking:

Codecov Report
Patch coverage: 65.62% and project coverage change: -0.20 :warning:

Comparison is base (bfa0f81) 93.62% compared to head (7139ad0) 93.42%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #30      +/-   ##
==========================================
- Coverage   93.62%   93.42%   -0.20%
==========================================
  Files          18       17       -1
  Lines        8701     8398     -303
==========================================
- Hits         8146     7846     -300
+ Misses        555      552       -3

Impacted Files
Coverage Δ

cfdp-core/src/lib.rs
100.00% <ø> (ø)

cfdp-core/src/transaction/send.rs
97.83% <ø> (ø)

cfdp-core/src/daemon.rs
73.45% <65.62%> (-3.01%)
:arrow_down:

cfdp-core/src/pdu.rs
93.57% <0.00%> (-0.72%)
:arrow_down:

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

@xpromache is this what you hand in mind about removing the current User trait and implementation?
I think it goes indeed in that direction.

Still having the trouble that it needs the one off because of the multiplexed users in the testing.
Can you please point me to this problem of multiplexed users? I don't really understand it.

I made a drawing to get it all in my mind because I somehow feel it is too convoluted:
https://drive.google.com/file/d/1oz0oo4hBmZe7m80OlYjB0EayG-HIPbIG/view?usp=sharing
After I made the drawing I think I understand why I'm confused: it's because the daemon does things which I believe should be user responsibility - namely all the proxy operations.
For example what if a user does not want to execute a Proxy Put Request? Currently it's the daemon which is executing it automatically.
I'm not sure how to organize the code in a way to allow library users (i.e. other people using the cfdp library) to plug in bits and pieces of  (what I believe to be) user implementation currently residing in the Daemon ( for example the current Daemon::categorize_user_msg) and in the SendTransaction (the code in the "if self.config.send_proxy_response {").
Maybe just group the functions into a module  and in the example we provide, we show how a user can use those functions to process the messages, sending some of them back to the daemon.

When I was reading through the specification documents they didn't seem like very optional things that could be done. Which is why I initially built them straight into the daemon. But I think if I understand what you're saying, even a implementation wants them to be automatic, the User instance really should be handling them and sending new Primitives to the Daemon?
I think your idea is as good a place to start as any. We may even find a better solution along the way. That would allow for the removal of the extra channel from the SendTransaction to the daemon (it's only used for sending a Proxy Put Response), but I think some more book keeping would need to be done so the user can get the OriginatingTransactionID from a transaction to send a Proxy Response.
I think some of the difficultly I'm having with imagining an implementation is how to set up tests too. Maybe it just needs a completely different test structure where every inter agency test has a separate user and daemon processes. But that seems like a lot of overhead.

For the ProxyPutRequest (A requests B to send a file to C) - it is the B user which should be receiving and decoding the MessageToUser containing the proxy put rquest, then it can initiate the requested Put transaction from B to C, monitor that transaction and at the end it can initiate the second transaction from B to A to notify the original requestor of the outcome. All that logic can be moved away from the Daemon/SentTransaction. It also gives the opportunity to the user B to verify the request and deny it if necessary.

Right the idea in my head was how to track with originating message is associated with each request. But like you're saying, that should just be each User implementation's own issue it can solve however it likes.

I think some of the difficultly I'm having with imagining an implementation is how to set up tests too. Maybe it just needs a completely different test structure where every inter agency test has a separate user and daemon processes. But that seems like a lot of overhead.

So I've been looking at the tests and I don't see where you have one daemon with multiple users.
What I see is local_user/local_daemon and remote_user/remote_daemon.
Am I missing something?

I suppose multiple users isn't quite accurate, but there are multiple references to the local and remote user. Any test that uses the get_filestore fixture is returned a reference to both the local and remote user.
I've noticed that when trying to move to a single channel to return information to the User from the Daemon, some responses are not necessarily returned in the expected order. So when one test is calling local_user.put and expecting to be returned the ID of the transaction, the next response from the daemon might be a report another test has created.
Maybe the test user interface just needs to be refined. it just seemed useful that when calling put or report, the caller should be returned the ID or report for the input transaction.

Wow, I didn't realize that all those tests run in parallel sharing the same objects. I didn't even think that is possible in Rust. I only now see you can send a message to a channel without having mutable access to it...
In that case, what we can do is to keep the current scheme with a channel <(UserPrimitive, Sender)> for request/replay patterns but add an additional channel for the asynchronous messages (what they call "indications" in the standard).
The test user can collect all those  messages into a HashMap<TransactionID, Vec> behind a Arc<Mutex<>> and the tests can lookup and verify the messages related to the transactions they initiated.

oh good idea, then the test user just needs to spawn thread to listen on indications channel and update the hashmap as indications are received.

I think I have most of the indications now but I think the Report indications could be all handled by the User too. I tried moving the report history and all the logic there up to the testuser but ran into some problems and wanted to roll back to a working commit for now.

hmm i don't have these same issues on my personal windows machine. but I think if you want to look when you have time @xpromache I would appreciate it.

hmm i don't have these same issues on my personal windows machine. but I think if you want to look when you have time @xpromache I would appreciate it.

Looks that the windows built is quite slow probably due to limited CPU and what kills it is the tight sleep(1ms) in the f2 suite. I managed to pass the tests by replacing that with sleep(100ms) and allowing f8 and f9 to run for 15 seconds.
I believe there are some tight sleep loops still in the transport, I do plan to get rid of those after you have committed the user refactoring.

Thanks! If you are interested in taking a closer look at this code I think it is ready too.

For me this can be merged. I did not have time to test it with my application but I will do it later.

Thanks for getting back! I'm sure there's some tweaks we'll need!


Include documentation for migration when schema changes

Any chance documentation for migration can be included when schema changes? I'm not sure what is the best way to do so with the additional of the oauth providers and I can see in db-init.sql that the schema has significant changes

Yes, there are significant changes in this next release. I'm my self trying to figure out what the best way to migrate is.
I think there will be a lot of manual work since, just changing user id from int to uuid is a big change. This will require your FKs to change too. And that means dropping and recreating the FKs, which in turn means for Hasura to retrack them.
I do not think there is aa easy and general way to do this.

There is no quick fix.
What I ended up doing was dumping the whole database and carefully, and manually, re instantiate the database.

Recreate the tables with the updated types
Make sure the FKs are correct
Insert data that is not relational or not depended on the new db update
Wrote a custom python script that loaded all data into memory and inserted it. Ex: 1. Insert user 2. get new user uuid. 3. Get all projects for that user. 4. Insert that users projects (with the updated uuid user_id) etc.

Hopefully this will be the last time we do such significant changes the the database structure. 🙏


Add error and rate limit handling for calls to OpenAI API

We'll have a better sense of how we want to handle this once we have some UX for the "summarize" AI interactions.

https://github.com/openai/openai-cookbook/blob/main/examples/How_to_handle_rate_limits.ipynb

https://github.com/BerriAI/reliableGPT looks to be useful for this task


YETUS-915 Update GitHub vote emojis for usability by color blind folks

Can we just make them configurable so that projects can work out what's good for them?

Can we just make them configurable so that projects can work out what's good for them?

We could but we still need to provide default emojis?
As the statement is that it is for color blindness, I do not think there will be a project in ASF can say that 'I do not care about the color blindness'?  So the old ones are not suitable...

Oh! In that case please change the commit message and jira subject to something that indicates the purpose, e.g. "update GitHub vote emojis for usability by color blind folks."

No worries. Sorry we missed this during reviews for adding emoji votes in the first place.

(!) A patch to the testing environment has been detected.
Re-executing against the patched versions to perform further tests.
The console is at https://builds.apache.org/job/yetus-github-multibranch/job/PR-73/1/console in case of problems.

:broken_heart: -1 overall

Vote
Subsystem
Runtime
Comment

+0 :ok:
reexec
0m  0s
Docker mode activated.

-1 :x:
docker
31m 53s
Docker failed to build yetus/yetus:e8f542b3.

Subsystem
Report/Notes

GITHUB PR
https://github.com/apache/yetus/pull/73

Console output
https://builds.apache.org/job/yetus-github-multibranch/job/PR-73/1/console

versions
git=2.17.1

Powered by
Apache Yetus 0.12.0-SNAPSHOT https://yetus.apache.org

This message was automatically generated.


Added TypeScript Types

Downside is that Discord.js is a required dependency for types

thanks for your aportation 👍


Add Recurssion and linkedlist problems solution in python

More than 25+ recurssion and linkedlist problems solution in python
Contribution mb is already updated

PR accepted @PARKER-X .
Profile Already Verified.
Successfully merged to HacktoberFest_22 repo.
🚀🚀👍


process_embedding.py

this processing need's lots of memory, my computer run it, then Process finished with exit code 137(interrupted by signal 9:SIGKILL) what is wrong? it needs GPU?

It just cost a lot of memory since the source code loads the Glove embedding file at once.


[1pt] Implement add music album action - App Options (Team member 2)

[ ] Implement add music album option of the app menu

done


oauth token shouldn't be a config setting

closed in https://github.com/learn-co/learn-ide/pull/362 & https://github.com/learn-co/learn-ide/pull/362


systemd shutdownRamfs: Fix infinite shutdown loop

Description of changes
This is a prerequisite for #243242.
systemd 254 now goes into a loop during the shutdown ramfs (aka exitrd) unless initrd-release is present, because it repeatedly returns to initrd over and over again. Frankly, I have no idea why this wasn't an issue before.
Things done

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[x] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[ ] Tested basic functionality of all binary files (usually in ./result/bin/)
23.11 Release Notes (or backporting 23.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[ ] Fits CONTRIBUTING.md.

@ofborg test systemd-shutdown systemd-initrd-shutdown


Error running model with external_location when table already exists

I'm experiencing a strange error when running a model with materialized='table' and external_location. It only happens when the table already exists in Athena. I thought #73 would fix it but it doesn't appear to.
portfolio_account.sql:
{{ config(
   materialized = 'table',
   external_location = 's3://<my bucket>/test/' + target.name + '/portfolio_account/',
   partitioned_by = ['_company_id'],
   format = 'orc',
   write_compression = 'zlib'
) }}
...

dbt run --models portfolio_account (relevant dbt.log snippet):
14:38:54.901965 [debug] [Thread-1 (]: Began running node model.lake.portfolio_account
14:38:54.901965 [info ] [Thread-1 (]: 1 of 1 START table model lake_dev.portfolio_account ............................ [RUN]
14:38:54.901965 [debug] [Thread-1 (]: Acquiring new athena connection "model.lake.portfolio_account"
14:38:54.901965 [debug] [Thread-1 (]: Began compiling node model.lake.portfolio_account
14:38:54.917542 [debug] [Thread-1 (]: Compiling model.lake.portfolio_account
14:38:54.917542 [debug] [Thread-1 (]: Writing injected SQL for node "model.lake.portfolio_account"
14:38:54.917542 [debug] [Thread-1 (]: finished collecting timing info
14:38:54.917542 [debug] [Thread-1 (]: Began executing node model.lake.portfolio_account
14:38:54.982451 [debug] [Thread-1 (]: Opening a new connection, currently in state init
14:38:55.492034 [debug] [Thread-1 (]: Athena adapter: Error running SQL: macro drop_relation
14:38:55.507660 [debug] [Thread-1 (]: finished collecting timing info
14:38:55.507660 [debug] [Thread-1 (]: On model.lake.portfolio_account: Close
14:38:55.507660 [debug] [Thread-1 (]: Runtime Error in model portfolio_account (models\portfolio_account.sql)
  local variable 'table' referenced before assignment
14:38:55.507660 [debug] [Thread-1 (]: Sending event: {'category': 'dbt', 'action': 'run_model', 'label': 'fedef137-2292-43ea-9d8f-27a910d27f59', 'context': [<snowplow_tracker.self_describing_json.SelfDescribingJson object at 0x0000027BE7F09F60>]}
14:38:55.507660 [error] [Thread-1 (]: 1 of 1 ERROR creating table model lake_dev.portfolio_account ................... [ERROR in 0.61s]
14:38:55.507660 [debug] [Thread-1 (]: Finished running node model.lake.portfolio_account

When I updated to a version of dbt-athena with #73 included, I had saw this behavior as well. Full-refreshing my tables once after update seemed the resolve the issue going forward (I have not had this issue since), but I have no idea what was causing the problem.

Even after full refreshing once, this is still happening for me.

Same error here
dbt-athena
Version: 1.0.1
Location: /usr/local/lib/python3.9/dist-packages
19:50:14  Runtime Error in model alpha_product_category (models/silver/alpha_product_category.sql)
19:50:14    local variable 'table' referenced before assignment
DBT logs:
21:30:58.863264 [debug] [Thread-1  ]: Began running node model.dbt_printi.alpha_product_category
21:30:58.865017 [info ] [Thread-1  ]: 1 of 1 START table model bi_datalake_dev_silver.alpha_product_category.......... [RUN]
21:30:58.868244 [debug] [Thread-1  ]: Acquiring new athena connection "model.dbt_printi.alpha_product_category"
21:30:58.871360 [debug] [Thread-1  ]: Began compiling node model.dbt_printi.alpha_product_category
21:30:58.872429 [debug] [Thread-1  ]: Compiling model.dbt_printi.alpha_product_category
21:30:58.885684 [debug] [Thread-1  ]: Writing injected SQL for node "model.dbt_printi.alpha_product_category"
21:30:58.893848 [debug] [Thread-1  ]: finished collecting timing info
21:30:58.895043 [debug] [Thread-1  ]: Began executing node model.dbt_printi.alpha_product_category
21:30:58.911181 [debug] [Thread-1  ]: Opening a new connection, currently in state closed
21:30:59.640458 [debug] [Thread-1  ]: Athena adapter: Error running SQL: macro drop_relation
21:30:59.645847 [debug] [Thread-1  ]: finished collecting timing info
21:30:59.650678 [debug] [Thread-1  ]: On model.dbt_printi.alpha_product_category: Close
21:30:59.654288 [debug] [Thread-1  ]: Runtime Error in model alpha_product_category (models/silver/alpha_product_category.sql)
local variable 'table' referenced before assignment
21:30:59.657052 [debug] [Thread-1  ]: Sending event: {'category': 'dbt', 'action': 'run_model', 'label': '91a10d40-84e3-4a33-a7f3-cc6e2a3f5a83', 'context': [<snowplow_tracker.self_describing_json.SelfDescribingJson object at 0xffff8a63d400>]}
21:30:59.660499 [error] [Thread-1  ]: 1 of 1 ERROR creating table model bi_datalake_dev_silver.alpha_product_category. [ERROR in 0.79s]
21:30:59.663327 [debug] [Thread-1  ]: Finished running node model.dbt_printi.alpha_product_category
Appreciate any help, this is really impacting my project. Thanks.

Closing this for now, it will be fixed by #124 or #125


Privly icon scrolls with window

When privly is in injecting state and facebook chat window is opened, the icon appears on its correct place, in the input box. But when window is scrolled the 'privly icon doesnt stays fixed in the chat window but scrolls up as the window moves down. This may have something to do with the position of the icon set to 'fixed' may be...

Duplicate of #90


[SQL] Show better error messages for incorrect join types in DataFrames.

As a follow-up to https://github.com/apache/spark/pull/5944

Merged build triggered.

Merged build started.

Test build #32429 has started for   PR 6064 at commit 7629bf7.

Test build #32429 has finished for   PR 6064 at commit 7629bf7.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/32429/
Test PASSed.


Tab file icons overlapping tab text

It seems that a recent update to this theme is causing file type icons to overlap the text within open file tabs. I've switched between a few other themes to double-check and this only happens with atom-material-ui.

Whoops, just noticed there is an option for icons within tabs.  Not sure if this was a recent addition or not, but checking this fixed my issue.

Confirming this, I think this needs more investigation. With the option disabled the icons shouldn't show at all, and the Settings icon shows up on my end.

My bad! I'm pushing an update!


sendPhoto returns 400

I'm having trouble sending any type of media (photos in my case).
I'm passing a request Object (that has a readable Stream interface) to sendPhoto
client.sendPhoto(config.group_chat_id, request(someUrl));

yet telegram returns
[Error: 400 {"ok":false,"error_code":400,"description":"Error: Bad Request: there is no photo in request"}]

I noticed the same thing happens when running the examples in the repository. Has there been an API change, am I doing something wrong or is this a bug?

Hi, which URL are you sending?
There was a change on the Telegram API, maybe for a while wasn’t working.
Test are passing now, could you please check again? Thanks

Hi & thanks for getting back to me so quick.
The URL that is used is:
https://api.telegram.org/<token>/sendPhoto

A little unrealted (but maybe related again), I was looking at your tests as well but I'm not too sure if they work at all (that's probably another issue):
When doing:
it('does stuff', function(done){
  thingy().then(function(result){
   assert(false);
   done();
  });
});

the test will still pass as the promise will swallow the thrown exception. So I usually use it like this:
it('does stuff', function(){
  return thingy().then(function(result){
   assert(false);
  });
});

I never use Bluebird though, so I don't know if it handles this smarter (I'm asking in hope for a yes, so I can get rid of that.....).

I mean the request URL (someUrl) on client.sendPhoto(config.group_chat_id, request(someUrl));
You can run the test with:
DEBUG='node-telegram-bot-api' \
TEST_TELEGRAM_TOKEN=<YOUR_TOKEN> \
TEST_USER_ID=<YOUR_USER> ./node_modules/.bin/mocha test/index.js

If promise fails, it will throw an Unhandled rejection Error: 400 {"ok":false,"error_code":400,"description":"Error: AUDIO_EXT_INVALID"}

I'm using random image URLs from flickr.
I can save them to disk and do whatever with them so that should not be the
problem I guess.
Can you run the demo in /examples? I'm getting the same error for any kind
of upload here.
Thanks!
Am 20.07.2015 23:30 schrieb "Yago"<EMAIL_ADDRESS>
I mean the request URL (someUrl) on client.sendPhoto(config.group_chat_id,
request(someUrl));
You can run the test with:
DEBUG='node-telegram-bot-api'
TEST_TELEGRAM_TOKEN=<YOUR_TOKEN>
TEST_USER_ID=<YOUR_USER> ./node_modules/.bin/mocha test/index.js
If promise fails, it will throw an Unhandled rejection Error: 400
{"ok":false,"error_code":400,"description":"Error: AUDIO_EXT_INVALID"}
—
Reply to this email directly or view it on GitHub
https://github.com/yagop/node-telegram-bot-api/issues/12#issuecomment-123049113
.

Maybe it because of the lib make only GET requests, not POST. So large queries can be cut.

@SerjoPepper I actually tried hacking on the lib to make it a POST as I was thinking the same thing as you, but it did not make a difference. I ended up "manually" (i.e. no lib) uploading the files which worked fine.

In order to send form data, it sends a POST request. Could you please provide me the URL which you ere testing? It works fine with URL with file format extension because Telegram needs an extension.

I was using full image URLs like: https://farm1.staticflickr.com/323/19723079154_f405855a4c.jpg
But as I have already written above I also could not run the example bot in /examples/polling.js as it would fail with the exact same error.

Did you try the test and passed them out? Clone the repository, get inside the folder and then:
DEBUG='node-telegram-bot-api' \
TEST_TELEGRAM_TOKEN=<YOUR_TOKEN> \
TEST_USER_ID=<YOUR_USER> ./node_modules/.bin/mocha test/index.js

Ok so this is super weird and seems to be an issue with Telegram. I created a new bot where the token works perfectly fine, whereas when I use the "old" token it will still return the 400.
I'll try to use the two tokens with my own wrapper once I find the time to do so, so we can find out if this is a Telegram issue or not (sounds a lot like it).

So this really is an issue with the token I am using. My own lib, test suites and everything fails when using that one single token. Everything else works. Going to contact Telegram regarding that.
Thanks for your input and sorry for all that noise.


[SELC-4892] Added function to send events on topic through event hub

List of Changes

Added trigger endpoint to receive onboarding updates
Added function to send events on topic through event hub
Added event hub rest client and its configuration to send messages for different products

Motivation and Context
In order to manage all events from database, a new trigger endpoint has been been added. This endpoint invoke an azure function to send messages on topic
How Has This Been Tested?
I have deployed the feature branch direclty in DEV environment.

You could use a different approach instead iterator on product.consumers configuration....you might create 2 independent functions that listened to the event on SC-Contract and then sent to SC-ContractFD and SC-ContractSAP with the related mapping logic


Clicking on addresses, hashes and values copies to clipboard

A small change, a big quality of life improvement. Plus, the component CopyToClipboard can be easily used anywhere. You don't need to specify the text you want to copy to the clipboard.

One thing is annoying me
when I hover something, it takes some miliseconds for the tooltip to show up (which is good, less intrusive). But after that first one, moving the mouse throw the window shows the tooltip immediatelly on other elements. On the Transactions tab, where there's a bunch of these, it gets pretty annoying
Plus, I feel that with the cursor: pointer and the hover background color, it's already noticeable enough that this is clickable. maybe we could go without the tooltip, and just show it when it is clicked?

@naps62 Yap, the delay was on purpose, so you only see it if you hover for a bit. I fixed the issues you mentioned and increased the delay time a bit. This should be enough so you never see those tooltips, but let me know what you think. I'm ok with removing them, but hovering on elements to see the tooltip is an action I frequently do; that's why I built it.


[Shaka UI] [Android] Full screen closed captions over-sized in profile mode

Have you read the FAQ and checked for duplicate open issues?
Yes
What version of Shaka Player are you using?
Build: Shaka v2.5.4 (uncompiled)
Can you reproduce the issue with our latest release version?
Yes
Can you reproduce the issue with the latest code from master?
Yes
Are you using the demo app or your own custom app?
Shaka Player Demo
What browser and OS are you using?
Environment: Android mobile (Q build QD1A) Chrome browser
What did you do?
Steps:

Navigate to: https://shaka-player-demo.appspot.com
Launch video asset and select (we used Angel One)
Select Overflow menu and turn on Closed Captions
Select the Fullscreen button while in profile mode

Actual Result:
The Closed Captions are so large that the text is cut off screen
Expected:
Closed captions text would not flow off screen while in Fullscreen and profile mode

We'll fix that.
For now, you can customize the font size of shaka-text-container .


Feat/hats allowlists

Add Hats allowlisting
Integrate with 6551 and Zodiac modules
Add tests
Add to deploy scripts

Works on #23
Closes #22

lgtm


Feedback on /docs/reference/specification/v2.0.0 - Tue, 29 Aug 2023 17:06:53 GMT

Discussed in https://github.com/orgs/asyncapi/discussions/860

Originally posted by asyncapi-bot August 29, 2023
It would be nice to have a link to the entire example file

It is a valid feedback. Whenever I look into insights on GH, on spec repo, examples are first to visit, after the root of the repo. They are more important than spec 😄

So would be good to somehow figure, how we could link to examples from a spec document, so it is visible in the website.
Alternative would be to have some dedicated view in the website, independent from the spec - much more complicated though
thoughts?


Cypress/E2E: Save code body, error details and screenshots to dashboard when test  failed

Summary
Save code body, error details (if available) and screenshots to Automation Dashboard when test  failed.
Screenshots

/update-branch

Will try to auto merge this PR once all tests and checks are passing. This might take up to an hour.

Trying to auto merge this PR.

Pull Request successfully merged
SHA: 018d1d0cec4b4b91583c187d6a7b730722fe8171

Thanks Prapti and thanks for the feedback. We can discuss and consolidate all the feedbacks during our meeting.

/release-note-none


Calliope: Compass Sensor Input

Describe the bug

The slider for the compass sensor of calliope is difficult to be accurate with.

To Reproduce
Steps to reproduce the behavior:

Switch to Calliope.
Open Robot's view.
Use the compass sensor slider to get the value to a number like 128.

Fix

An input box that allows the user to input a number.

GIF

Additional Information
The value shown does not change dynamically with the slider as well.
Device information

Type: Laptop
OS: Windows 10
Browser: Google Chrome

works nice.


Support get cluster metrics from Promethues

Development Task
We need PD to give advice for TiDB cloud or TiDB Operator to help decide if we need to scale. So getting metrics from Prometheus is necessary. We can utilize these metrics and some information from store heartbeats and region heartbeats to make a better decision.

I think it would be better to use the statistics reported from tikv.

But we still need some statistics of TiDB to help make a decision.

I don't think PD should have anything to do with the scale of TiDB instances...

I think AutoScaler strategy API could see as an extended API to suggest how to scale the cluster.


Update README.md

removed the message which said discord.py was discontinued in 27 August 2021, bcz it's in development now..

Will this be merged?

Will this be merged?

idk 🤷♂


Fenzo job placement, rebased and with fixes

@wyegelwel I've made adjustments based on your comments.  Wrapped a block in timers/time! rather than using start & stop, and added dru-scale for metrics as a documented configuration option.

Would you mind listing me as the author of the original commit?
You can use these instructions to change the author: http://stackoverflow.com/a/28845565
If you choose to do so, you could list me as David Greenberg<EMAIL_ADDRESS>

I think this PR is ready to go. When you get a chance please squash commits and I will merge.

@dgrnbrg No problem 👍

Congrats!


DBZ-642 Enforce single task per connector

https://issues.jboss.org/browse/DBZ-642

I'm confused by this issue and PR. It seems strange that you'd limit the number of tasks in the connector configuration, when Connect already allows a user to control the maximum number of tasks. The MySQL and PG connectors can only run a single task, no matter what the maximum number of tasks are. And IIRC MongoDB would compute the number of tasks (for parallel processing) based upon the number of collections and the max number of tasks.

@rhauch What will happen if a user (and we had such reports) overeagerly configure 4 tasks for MySQL connector? IMHO it will either behave erratically or will fail with a confusin message. As I'd say that we are starting Readers per task not per connector.

@jpechane, the MySqlConnector.taskConfigs(...) is responsible for returning the configuration for each task that will be started. It's currently doing nothing, but it should return a list with a single map (task configuration). Same for the PostgreSQL connector.
The MongoDB connector is already doing it properly by looking at how much work there is, computing the correct number of tasks, and then defining the configuration for each of those tasks.

Hey @rhauch, the idea is to protect against a configuration of max tasks we actually can't support. I.e. it doesn't make sense to start the MySQL or PG connector with a max.tasks > 1, potentially leaving the user hoping that it'd achieve a better parallelism (this came up recently). So we thought we'd rather fail early on, to make that clear. Would that make sense?
But indeed we missed that the MongoDB connector actually supports more than one task, that had escaped my memory. So indeed this early fail should be done for the two other connectors then only.

@rhauch You are right, thanks for pointing me to the right direction!

@jpechane ah, sorry. comments passed in transit again.

@rhauch @gunnarmorling Guys, how about a little bit more interactive gitter chat? :-)

@rhauch Yes, having re-read the JavaDocs of taskConfigs(), I think it's best to leave things as is.
For some reason I was under the wrong assumption that the configured number is authoritative on the number of tasks started, but as you say, the connector is still in control (and we rightly return list with a single element for MySQL and PG, no matter what max task number has been configured). So a higher count is just ignored.
We might log a warning if a higher count than 1 is given, stating that this takes no affect, but it's probably not worth the effort.
Thanks for pointing this out, @rhauch!

Will not be implemented


Adding maxPerRow for all panels and repeatDirection for row panel

These two attributes are required for below reasons.

maxPerRow: To limit on the max repeating panels in a row.
repeatDirection: To allow repeat direction either "h" or "v" for a row panel.

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.Vishnu Challa seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.You have signed the CLA already but the status is still pending? Let us recheck it.

@K-Phoen @iainlane @Duologic  Requesting a review.

The files in gen/ are generated, please do not edit them by hand. Have a look at https://github.com/grafana/grafonnet/blob/main/DEVELOPMENT.md to see how the generate process works.
It looks like the schema for the row panel is missing these fields. These functions can be added in this file: https://github.com/grafana/grafonnet/blob/main/custom/row.libsonnet

Better would be an issue or PR against grafana/grafana to update the underlying schema. Then Grafonnet would automatically pick it up.

Better would be an issue or PR against grafana/grafana to update the underlying schema. Then Grafonnet would automatically pick it up.

Grafana upstream already seems to be having these elements in their schema, as we can see them in the UI dashboard.

The files in gen/ are generated, please do not edit them by hand. Have a look at https://github.com/grafana/grafonnet/blob/main/DEVELOPMENT.md to see how the generate process works.
It looks like the schema for the row panel is missing these fields. These functions can be added in this file: https://github.com/grafana/grafonnet/blob/main/custom/row.libsonnet

Made these changes in schema as suggested instead of generated files. I am not sure why make generate is not working in my local and running into below error.
+ cp -r /home/vchalla/myforks/grafonnet/custom /home/vchalla/myforks/grafonnet/gen/grafonnet-v10.1.0
+ mapfile -t FILES
++ jsonnet -J vendor -S -c -m /home/vchalla/myforks/grafonnet/gen --tla-str version=v10.1.0 --tla-code-file schemas=github.com/grafana/grok/jsonnet/v10.1.0/imports.libsonnet --tla-code-file openapiSpec=github.com/grafana/grafana/public/openapi3.json -e '(import '\''generator/main.libsonnet'\'')'
RUNTIME ERROR: vendor/github.com/crdsonnet/crdsonnet/crdsonnet/renderEngines/ast.libsonnet:46:15-18 Unknown variable: xtd
	vendor/github.com/crdsonnet/crdsonnet/crdsonnet/renderEngines/main.libsonnet:4:8-32	object <anonymous>
	vendor/github.com/crdsonnet/crdsonnet/crdsonnet/render.libsonnet:24:13-32	object <anonymous>
	vendor/github.com/crdsonnet/crdsonnet/crdsonnet/render.libsonnet:26:15-26	object <anonymous>
	vendor/github.com/crdsonnet/crdsonnet/crdsonnet/render.libsonnet:38:7-8
	vendor/github.com/crdsonnet/crdsonnet/crdsonnet/processor.libsonnet:31:7-51	function <anonymous>
	vendor/github.com/crdsonnet/crdsonnet/crdsonnet/main.libsonnet:146:12-48	function <anonymous>
	generator/alerting.libsonnet:(93:9)-(99:10)	thunk from <thunk <ast> from <function <anonymous>>>
	generator/utils.libsonnet:33:7-16
	vendor/github.com/Duologic/jsonnet-libsonnet/utils.libsonnet:37:26-35	thunk from <function <anonymous>>
	vendor/github.com/Duologic/jsonnet-libsonnet/utils.libsonnet:27:28-31	thunk from <function <anonymous>>
	...
	vendor/github.com/Duologic/jsonnet-libsonnet/main.libsonnet:(33:5)-(44:6)
	vendor/github.com/Duologic/jsonnet-libsonnet/main.libsonnet:(51:26)-(57:8)	object <anonymous>
	vendor/github.com/Duologic/jsonnet-libsonnet/main.libsonnet:59:20-30	thunk from <object <anonymous>>
	vendor/github.com/Duologic/jsonnet-libsonnet/main.libsonnet:59:9-31	object <anonymous>
	generator/alerting.libsonnet:(116:5)-(120:15)	function <anonymous>
	generator/alerting.libsonnet:63:25-85	object <anonymous>
	generator/alerting.libsonnet:15:20-32	object <anonymous>
	generator/main.libsonnet:21:9-20	object <anonymous>
	Field "grafonnet-v10.1.0/clean/alerting/contactPoint.libsonnet"
	During manifestation

+ jsonnet -S -c -m /home/vchalla/myforks/grafonnet/gen/grafonnet-v10.1.0 vendor/generator/dependencies.libsonnet
/home/vchalla/myforks/grafonnet/gen/grafonnet-v10.1.0/jsonnetfile.json
+ jrsonnet -J vendor -S -c -m /home/vchalla/myforks/grafonnet/gen/grafonnet-v10.1.0/docs/ --exec '(import '\''doc-util/main.libsonnet'\'').render(import '\''/home/vchalla/myforks/grafonnet/gen/grafonnet-v10.1.0/main.libsonnet'\'')'
./scripts/generate.sh: line 49: jrsonnet: command not found
+ finish
+ rm -rf /tmp/tmp.81Tat8DGoI
make: *** [Makefile:8: gen/grafonnet-latest] Error 127

./scripts/generate.sh: line 49: jrsonnet: command not found
@vishnuchalla You are missing jrsonnet

Hey, sorry for letting this hang for so long.
I've just been looking into this, trying to figure out why those fields aren't there. AFAICT these values don't make sense on a row panel, the direction is always vertical, regardless of the value in the json, that's just how rows work. The maxPerRow doesn't mean anything as nested rows don't exist.
repeatDirection is available on panels: example
maxPerRow fixed in #207 along with a few other fields.


pysnmp :  working with up to None octets of substrate

I am trying a simple SNMP receiver script:
from pysnmp.entity import engine, config
from pysnmp.carrier.asyncore.dgram import udp
from pysnmp.entity.rfc3413 import ntfrcv
from pyasn1 import debug
debug.setLogger(debug.Debug('all'))

# Create SNMP engine with autogenernated engineID and pre-bound
# to socket transport dispatcher
snmpEngine = engine.SnmpEngine()

# Transport setup
# UDP over IPv4, first listening interface/port
config.addTransport(
    snmpEngine,
    udp.domainName + (1,),
    udp.UdpTransport().openServerMode(('<IP_ADDRESS>', 162))
)

# SNMPv1/2c setup
# SecurityName <-> CommunityName mapping
config.addV1System(snmpEngine, 'my-area', 'public')

# Callback function for receiving notifications
# noinspection PyUnusedLocal,PyUnusedLocal,PyUnusedLocal
def cbFun(snmpEngine, stateReference, contextEngineId, contextName,
          varBinds, cbCtx):
    print('Notification from ContextEngineId "%s", ContextName "%s"' % (contextEngineId.prettyPrint(),
                                                                        contextName.prettyPrint()))
    for name, val in varBinds:
        print('%s = %s' % (name.prettyPrint(), val.prettyPrint()))

# Register SNMP Application at the SNMP engine
ntfrcv.NotificationReceiver(snmpEngine, cbFun)
snmpEngine.transportDispatcher.jobStarted(1)  # this job would never finish
snmpEngine.transportDispatcher.runDispatcher()

# Run I/O dispatcher which would receive queries and send confirmations
try:
    snmpEngine.transportDispatcher.runDispatcher()

finally:
    snmpEngine.transportDispatcher.closeDispatcher()

Output:
2022-08-22 14:18:44,463 pyasn1: decoder called at scope Sequence with state 0, working with up to None octets of substrate: <_io.BytesIO object at 0x7fbc1d815048>
2022-08-22 14:18:44,464 pyasn1: tag decoded into <TagSet object, tags 0:32:16>, decoding length
2022-08-22 14:18:44,464 pyasn1: value length decoded into 444
2022-08-22 14:18:44,464 pyasn1: candidate ASN.1 spec is Sequence
2022-08-22 14:18:44,464 pyasn1: value decoder chosen for an ambiguous type by type ID 11
2022-08-22 14:18:44,464 pyasn1: codec SequencePayloadDecoder chosen by ASN.1 spec, decoding value
Traceback (most recent call last):
  File "/usr/local/lib/python3.6/site-packages/pysnmp/carrier/asyncore/dispatch.py", line 46, in runDispatcher
    use_poll=True, map=self.__sockMap, count=1)
  File "/usr/lib64/python3.6/asyncore.py", line 207, in loop
    poll_fun(timeout, map)
  File "/usr/lib64/python3.6/asyncore.py", line 188, in poll2
    readwrite(obj, flags)
  File "/usr/lib64/python3.6/asyncore.py", line 123, in readwrite
    obj.handle_error()
  File "/usr/lib64/python3.6/asyncore.py", line 108, in readwrite
    obj.handle_read_event()
  File "/usr/lib64/python3.6/asyncore.py", line 423, in handle_read_event
    self.handle_read()
  File "/usr/local/lib/python3.6/site-packages/pysnmp/carrier/asyncore/dgram/base.py", line 170, in handle_read
    self._cbFun(self, transportAddress, incomingMessage)
  File "/usr/local/lib/python3.6/site-packages/pysnmp/carrier/base.py", line 85, in _cbFun
    self, transportDomain, transportAddress, incomingMessage
  File "/usr/local/lib/python3.6/site-packages/pysnmp/entity/engine.py", line 152, in __receiveMessageCbFun
    self, transportDomain, transportAddress, wholeMsg
  File "/usr/local/lib/python3.6/site-packages/pysnmp/proto/rfc3412.py", line 291, in receiveMessage
    msgVersion = verdec.decodeMessageVersion(wholeMsg)
  File "/usr/local/lib/python3.6/site-packages/pysnmp/proto/api/verdec.py", line 17, in decodeMessageVersion
    recursiveFlag=False, substrateFun=lambda a, b, c: (a, b[:c])
  File "/usr/lib/python3.6/site-packages/pyasn1-0.5.0rc1-py3.6.egg/pyasn1/codec/ber/decoder.py", line 1998, in __call__
    for asn1Object in streamingDecoder:
  File "/usr/lib/python3.6/site-packages/pyasn1-0.5.0rc1-py3.6.egg/pyasn1/codec/ber/decoder.py", line 1914, in __iter__
    self._substrate, self._asn1Spec, **self._options):
  File "/usr/lib/python3.6/site-packages/pyasn1-0.5.0rc1-py3.6.egg/pyasn1/codec/ber/decoder.py", line 1776, in __call__
    self, substrateFun, **options):
  File "/usr/lib/python3.6/site-packages/pyasn1-0.5.0rc1-py3.6.egg/pyasn1/codec/ber/decoder.py", line 653, in valueDecoder
    for chunk in substrateFun(asn1Object, substrate, length, options):
TypeError: <lambda>() takes 3 positional arguments but 4 were given

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.6/site-packages/pysnmp/carrier/asyncore/dispatch.py", line 50, in runDispatcher
    raise PySnmpError('poll error: %s' % ';'.join(format_exception(*exc_info())))
pysnmp.error.PySnmpError: poll error: Traceback (most recent call last):
;  File "/usr/local/lib/python3.6/site-packages/pysnmp/carrier/asyncore/dispatch.py", line 46, in runDispatcher
    use_poll=True, map=self.__sockMap, count=1)
;  File "/usr/lib64/python3.6/asyncore.py", line 207, in loop
    poll_fun(timeout, map)
;  File "/usr/lib64/python3.6/asyncore.py", line 188, in poll2
    readwrite(obj, flags)
;  File "/usr/lib64/python3.6/asyncore.py", line 123, in readwrite
    obj.handle_error()
;  File "/usr/lib64/python3.6/asyncore.py", line 108, in readwrite
    obj.handle_read_event()
;  File "/usr/lib64/python3.6/asyncore.py", line 423, in handle_read_event
    self.handle_read()
;  File "/usr/local/lib/python3.6/site-packages/pysnmp/carrier/asyncore/dgram/base.py", line 170, in handle_read
    self._cbFun(self, transportAddress, incomingMessage)
;  File "/usr/local/lib/python3.6/site-packages/pysnmp/carrier/base.py", line 85, in _cbFun
    self, transportDomain, transportAddress, incomingMessage
;  File "/usr/local/lib/python3.6/site-packages/pysnmp/entity/engine.py", line 152, in __receiveMessageCbFun
    self, transportDomain, transportAddress, wholeMsg
;  File "/usr/local/lib/python3.6/site-packages/pysnmp/proto/rfc3412.py", line 291, in receiveMessage
    msgVersion = verdec.decodeMessageVersion(wholeMsg)
;  File "/usr/local/lib/python3.6/site-packages/pysnmp/proto/api/verdec.py", line 17, in decodeMessageVersion
    recursiveFlag=False, substrateFun=lambda a, b, c: (a, b[:c])
;  File "/usr/lib/python3.6/site-packages/pyasn1-0.5.0rc1-py3.6.egg/pyasn1/codec/ber/decoder.py", line 1998, in __call__
    for asn1Object in streamingDecoder:
;  File "/usr/lib/python3.6/site-packages/pyasn1-0.5.0rc1-py3.6.egg/pyasn1/codec/ber/decoder.py", line 1914, in __iter__
    self._substrate, self._asn1Spec, **self._options):
;  File "/usr/lib/python3.6/site-packages/pyasn1-0.5.0rc1-py3.6.egg/pyasn1/codec/ber/decoder.py", line 1776, in __call__
    self, substrateFun, **options):
;  File "/usr/lib/python3.6/site-packages/pyasn1-0.5.0rc1-py3.6.egg/pyasn1/codec/ber/decoder.py", line 653, in valueDecoder
    for chunk in substrateFun(asn1Object, substrate, length, options):
;TypeError: <lambda>() takes 3 positional arguments but 4 were given
caused by <class 'TypeError'>: <lambda>() takes 3 positional arguments but 4 were given

I looked for references for this particular issue but I am unable to find any. Can someone please help ?

Found the issue. The issue was with the pyasn1 package. I had  pyasn1 0.5.0.rc1 version installed. Downgrading it to  pyasn1 0.4.8 resolved the issue. For some reason decoder was erroring out due to the above error message that I posted. But glad that it is working now.


TODO: play sound

OpenChampagne

https://1drv.ms/f/s!An3wL8jLytBXo_tJfSxA80LypTvSKg?e=WUWjvQ
Select 1 as SFX for open Champagne

@gyxx-xc

The 1st SFX is applyed


Question about Consumer RTT Metrics and Changes to Fetch.Wait.Max.Ms

Description

We recently upgraded to Confluent.Kafka 1.5.1 from an earlier version, and noticed that both the Confluent.Kafka consumer rtt, and Fetch Consumer TotalTimeMs from Kafka itself went from 100ms - 500ms.

I see the default value of fetch.wait.max.ms went from 100 ms to 500 ms, and we are using default values there, so I assume this is the reason for the change in metric values.

Our actual produce to consume timings remained the same ~ 15 ms (we set a timestamp at produce time, and then report the diff at consume time).

My question is what is the relation between the confluent consumer rtt, and kafka fetch consume rtt, and real produce to consume latencies?

How to reproduce
N/A. Just a question.
Checklist
Please provide the following information:

[ ] A complete (i.e. we can run it), minimal program demonstrating the problem. No need to supply a project file.
[x] Confluent.Kafka nuget version. 1.5.1
[x] Apache Kafka version. kafka_2.12-2.3.0.
[ ] Client configuration.
[ ] Operating system. Windows.
[ ] Provide logs (with "debug" : "..." as necessary in configuration).
[ ] Provide broker log excerpts.
[ ] Critical issue.

I'm guessing that this is one topic without too much throughput, where messages aren't coming constantly. Is that a fair assumption?
The time for which a request "waits" at the broker is set by Fetch.Wait.Max.Ms. This is counted within the rtt calculation, since, if there is no message, the broker respond after Fetch.Wait.Max.Ms has elapsed. In case there is a message, the broker replies quickly. What I imagine may be happening is that most Fetch requests sent to the broker don't have any messages waiting for them, and hence the consumer rtt is ~500ms. But when there is actually a message, it is returned quickly. So there's no actual performance degradation.
Hope that helps. I'm closing this issue now since it's pretty old, please reopen for more questions.


[BUG] Broken exit button in board screen

Describe the bug
The exit modal component's 'Yes' option does not exit the program properly, leaving it hanging. It inconsistently may respond to subsequent clicks or not at all.
To Reproduce
Steps to reproduce the behavior:

Click on any of the main menu buttons to reach the board screen
Click the exit button
Click 'Yes'
See error

Expected behavior
Hitting 'Yes' should exit the program, like how it does in the main menu screen

Marking issue as stale


SWARM-478: Add Flyway fraction

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

Motivation
Flyway (https://flywaydb.org/) is an open-source database migration tool. It strongly favors simplicity and convention over configuration.
Modifications
Created a flyway fraction that automatically bounds to the primary DataSource if not configured or uses the provided URL/user/pass otherwise.
It registers a ServletContextListener in the deployed app to perform the migration. Scripts must be placed under src/main/resources/db/migration
Result
Flyway can now be activated in Swarm applications by simply adding the flyway fraction and dropping the scripts in the specified place.

test this please

Retest this please


Change estimator default resilience level

Summary
Change estimator default resilience_level from 0 to 1.
Details and comments
Fixes #596

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

0 of 7 (100.0%)  changed or added relevant lines in 3 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage decreased (-2.2%) to 61.832%

Totals

Change from base Build<PHONE_NUMBER>:
-2.2%

Covered Lines:
3287

Relevant Lines:
5316

💛  - Coveralls

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

7 of 7 (100.0%)  changed or added relevant lines in 3 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.04%) to 64.065%

Totals

Change from base Build<PHONE_NUMBER>:
0.04%

Covered Lines:
3366

Relevant Lines:
5254

💛  - Coveralls


Failed to build the preview   SB_BUILDER-WEBPACK5_0002 (WebpackInvocationError): Module not found: Error: Can't resolve './Typography' in './components/Typography'

I'm trying to upload my storybook to github pages and i'm facing this problem, does anyone can help?
More information:
node version: v20.15.1
storybook: "^8.2.5"
next: "14.2.5",
components/Typography.tsx
'use client'

import React from 'react'
import { THEMES } from '@/config/themes'
type TVariantsAndThemesTypography = {
  theme: 'theme1' | 'theme2' | 'theme3'
  variant: 'h1' | 'h2' | 'h3' | 'body-1' | 'body-2' | 'caption' | 'overline'
}

export const Typography: React.FC<
  TVariantsAndThemesTypography & { children: React.ReactNode }
> = ({ children, ...props }) => {
  const { theme, variant } = props

  switch (variant) {
    case 'h1':
      return
{children}

    case 'h2':
      return
{children}

    case 'h3':
      return
{children}

    case 'body-1':
      return
{children}

    case 'body-2':
      return
{children}

    case 'caption':
      return
{children}

    case 'overline':
      return
{children}

    default:
      return
{children}

  }
}

Typography.displayName = 'Typography'

components/Typography.stories.tsx
import type { Meta, StoryObj } from '@storybook/react'
import { Typography } from './Typography'

export default {
  title: 'Componentes/Tipografias',
  component: Typography,
  args: {
    children:
      'Lorem ipsum, dolor sit amet consectetur adipisicing elit. Porro reprehenderit est veniam? Rem recusandae sint perspiciatis debitis corrupti. Deserunt neque exercitationem illo voluptatum laudantium culpa suscipit accusantium blanditiis voluptas numquam.',
  },
} as Meta

type Story = StoryObj<typeof Typography>

export const h1: Story = {
  args: {
    variant: 'h1',
    theme: 'theme1',
  },
}

export const h2: Story = {
  args: {
    variant: 'h2',
    theme: 'theme1',
  },
}

export const h3: Story = {
  args: {
    variant: 'h3',
    theme: 'theme1',
  },
}

export const Body1: Story = {
  args: {
    variant: 'body-1',
    theme: 'theme1',
  },
}

export const Body2: Story = {
  args: {
    variant: 'body-2',
    theme: 'theme1',
  },
}

export const Caption: Story = {
  args: {
    variant: 'caption',
    theme: 'theme1',
  },
}

export const Overline: Story = {
  args: {
    variant: 'overline',
    theme: 'theme1',
  },
}

storybook/main.ts
import type { StorybookConfig } from '@storybook/nextjs'

const config: StorybookConfig = {
  stories: [
    '../components/**/*.mdx',
    '../components/**/*.stories.@(js|jsx|mjs|ts|tsx)',
    '../stories/**/*.mdx',
  ],
  addons: [
    '@storybook/addon-onboarding',
    '@storybook/addon-links',
    '@storybook/addon-essentials',
    '@chromatic-com/storybook',
    '@storybook/addon-interactions',
    '@storybook/addon-themes',
  ],
  framework: {
    name: '@storybook/nextjs',
    options: {},
  },
  staticDirs: ['../public'],
}
export default config

storybook/preview.ts
import type { Preview } from '@storybook/react'
import '../app/globals.css'

import { withThemeByClassName } from '@storybook/addon-themes'

const preview: Preview = {
 parameters: {
   backgrounds: {
     default: 'dark',
   },
   controls: {
     matchers: {
       color: /(background|color)$/i,
       date: /Date$/i,
     },
   },
 },
 tags: ['autodocs'],
 decorators: [
   withThemeByClassName({
     themes: {
       theme1: 'theme1',
       theme2: 'theme2',
       theme3: 'theme3',
     },
     defaultTheme: 'theme1',
   }),
 ],
}

export default preview

.github/workflows/deploy-github-pages.yaml
name: Build and Publish Storybook to GitHub Pages

on:
  push:
    branches:
      - 'design-system'

permissions:
  contents: read
  pages: write
  id-token: write

jobs:
  deploy:
    environment:
      name: github-pages
      url: ${{ steps.build-publish.outputs.page_url }}
    runs-on: ubuntu-latest
    steps:
    - id: build-publish
      uses<EMAIL_ADDRESS>      with:
        path: storybook-static
        install_command: npm install
        build_command: npm run build-storybook

Hi there @kobe-leonelceolin !
Thanks for opening an issue with us.
I can only think of a path related issue. The Typography files are located inside the Typography folder and should be at components?
Or the imports should be import { Typography } from './Typography/Typography'; ?
Not sure what is your specific scenario.
Let us know how it goes

Hi there @kobe-leonelceolin ! Thanks for opening an issue with us.
I can only think of a path related issue. The Typography files are located inside the Typography folder and should be at components?
Or the imports should be import { Typography } from './Typography/Typography'; ?
Not sure what is your specific scenario.
Let us know how it goes

Hi @LeoDiazL , thanks for your reply!
i tried to use the import the way that you mentioned but the error doesn't disappear
this is my structure
components/Typpography/Typography
and like i added the description of the issue, inside of the Typography.stories.tsx i'm calling my component from ./Typography and i'm having the error with the webpack, i also tried to import on those ways:
import { Typography } from './Typography/Typography';
import { Typography } from '@/components/Typography/Typography';
import { Typography } from '.../../components/Typography/Typography';
but none of them worked as well!
more context, i also tried to do the configuration in this docs storybook-webpack-docs but no success as well

Hi @kobe-leonelceolin
I'm pretty sure is something specific to your repo, and most likely a path-related thing.
It is really hard to pick up exactly what could be happening.
Are you able to make this work in a local environment? I would start there first.
I'll close this issue as it's not really an issue of our action, but thanks for reaching us!
You could also reach us through Discord.


backend: create renderer and allocator in wlr_backend_autocreate

Instead of ensuring the renderer and allocator are initialized in each
backend, do it in wlr_backend_autocreate. This allows compositors to
create backends without any renderer/allocator if they side-step
wlr_backend_autocreate.
Since the wlr_backend_get_renderer and backend_get_allocator end up
calling wlr_renderer_autocreate and wlr_allocator_autocreate, it sounds
like a good idea to centralize all of the opimionated bits in one place.

The should be a way for users to use let wlroots choose the backend without creating the renderer and allocator.
In wxrc I call this function, then add the XR backend and create the renderer after.
Maybe a wlr_backend_create function that will attempt all backend without ensuring a renderer?

This PR doesn't intend to fix everything, it's just a small step in the right direction.

Maybe a wlr_backend_create function that will attempt all backend without ensuring a renderer?

That would still be "auto" because it would have an hardcoded list of backends in it and it would pick the one it thinks is best.

Alright, LGTM :)


Update to Character Options to Allow for Character Level, Item Level, or Gear Score

Replace highlighted section with
LFG Messages
LFG Messages sent before Max Level will always show your Character Level.
At Max Level, show:
Drop-down (Character Level, Item-Level, GearScore)
Select Box Include Non-Current Spec in LFG Messages.

Is character level the intended default here? Just checking before closing


Create CI/CD process (including acceptance tests)

jenkins on openshift?

Travis is now used to build and push the images to quay. https://travis-ci.org/redhat-cop/pathfinder


Microphone level

How to get the microphone level (average volume)? Help me, please!

MediaStreamAudioSourceNode is required to get microphone input.
node-web-audio-api doesn't support it yet.
https://webaudio.github.io/web-audio-api/#widl-AudioContext-createMediaStreamSource-MediaStreamAudioSourceNode-MediaStream-mediaStream

Hi @webmaxik,
I guess you can't yet do this with node-web-audio-api, but you probably can with node-microphone and Meyda. You'd just use the tutorial from node-microphone, and pipe the data in the callback into Meyda's RMS or Loudness feature extractor.


Live

Test PR

Docs Build status updates of commit 0629b75:
:white_check_mark: Validation status: passed
For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

Test PR


Sometimes small amounts of stocks hang around in a portfolio when they should have been sold

An example of this can be seen when running seeking alpha from 8/9/2019 - 4/1/2020. BRK/A hangs around when the strategy thinks it has switched to VUSTX:

This is probably due to BRK/A being very expensive (hundreds of thousands of dollars per share) so only a small portion was purchased to begin with.

Looks like SEEK is getting some 0 share SELLS of BRK/A, this isn't allowed:

It would be much easier to debug this if Transaction IDs were included as an option in the UI

Problem looks to occur in December 2019

This was due to a bug when rebalancing failed due to too small a dollar or share amount the existing holding was not carried forward. the only time a holding should be written off is when the price data is unavailable. should consider creating a marker transaction that makes it clear that a stock was written off.


Date time spinners dont change year

Any of the date selectors only change the month
They should be either:

switched to a control that supports it
Find property that manages it
Do it programatically

@M-Zuber Can I handle this problem

Sure!
Thank you


Getting Invalid Response Status Error

Early this morning the integration stopped working and the logs were being flooded with this log:
Logger: custom_components.cielo_home.cielohome
Source: custom_components/cielo_home/cielohome.py:259
First occurred: 6:08:13 AM (399 occurrences)
Last logged: 6:23:38 AM

498, message='Invalid response status', url=URL('wss://apiwss.smartcielo.com/websocket/?sessionId=chrome-1693476893&token=REDACTED

Using the Cielo app and google home integration works as expected.

I am also seeing the “498, message='Invalid response status'” error.

yup me too, i'm on it! They change something in the auth proces. i don't know what yet

I am seeing this as well. Just to add to the data. Same error in logs.

the integration of the Breeze Plus devices seems to be offline

i fixed it, install the version 1.5.3


Easy way to segment into 30s snippets given an m4a file and a vtt file

Feature request
Uploading datasets is straightforward thanks to the ability to push Audio to hub. However, it would be nice if the data (text and audio) could be segmented when being pushed (if not possible already).
Motivation
It's easy to create a vtt file from an audio file. If there could be auto-segmenting, this would make the creation of datasets much faster.
Your contribution
I have made a custom script to do this but it's not all that clean - uses librosa and pydub.

Hi! Non-generic data processing is out of this library's scope, so it's downstream libraries/users' responsibility to implement such logic.

That's fair. Thanks


cryptpad: re-add package/module

Things done
cryptpad removed its dependency on bower and can be sanely packaged again.
Add the package and module back.
The old module almost didn't do anything and there was no test so this really is a full rewrite and should be considered as such.
I have a few remarks/questions I'll post inline
cc people who were involved in this or earlier versions of the modules:
@Pamplemousse @DavHau @xeji @blitz @zimbatm
Link: cryptpad/cryptpad#295

Built on platform(s)

[x] x86_64-linux
[ ] aarch64-linux
[ ] x86_64-darwin
[ ] aarch64-darwin

[x] Tested, as applicable:

NixOS test(s) (look inside nixos/tests)
and/or package tests
or, for functions and "core" functionality, tests in lib/tests or pkgs/test
made sure NixOS tests are linked to the relevant packages

[x] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
23.11 Release Notes (or backporting 23.05 Release notes)

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[x] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

I would like to try out the module locally, but I am having (probably unrelated) issues. Hopefully I will solve that and approve this WE.

Thanks for the review!
I have this in my /etc/nixos so there's no hurry on my end; let's wait until you can test and we agree on small details :)

TL;DR: it works!
I upgraded my instance from 4.11 to what this PR provides (5.4). Instance is running fine, and documents were conserved.
However, I got messages akin to "This document has been upgraded. Edit is not possible until a registered user opens it" (or alike, I didn't think of writing it down!), forcing me to create a user to be able to edit existing "anonymous" documents.

Another thing to note: here's the report of the /checkup endpoint of my instance:

checkup
This instance is running CryptPad 5.4.0.Page content was served by "nginx".You appear to be using a firefox/gecko browser on UNIX to view this page.52 / 57 tests passed.Details found belowThis instance does not provide a valid adminEmail which can make it difficult to contact its adminstrator to report vulnerabilities or abusive content. This can be configured on your instance's admin panel. Use the provided Flush cache' button for this change to take effect for all users.Test number14Returned valueThis instance's encrypted support ticket functionality has not been enabled. This can make it difficult for its users to safely report issues that concern sensitive information. This can be configured via the admin panel's Support tab.Test number15Returned valueThis instance has not been configured to support web administration. This can be enabled by adding a registered user's public signing key to the adminKeys array in cryptpad/config/config.js. Changes to cryptpad/config/config.js will require a server restart in order for /api/config to be updated.Test number16Returned valuefalseNo terms of service were specified. This link will be included in the home page footer and 'About CryptPad' menu. It's advised that you either provide one or disable registration. See the relevant documentation about how to customize CryptPad's terms value.Test number37Returned valueNo privacy policy was specified. This link will be included in the home page footer and 'About CryptPad' menu. It's advised that you either provide one or disable registration. See the relevant documentation about how to customize CryptPad's privacy value.Test number39Returned value

Overall, an awesome news, but there's some work to do in the NixOS module to get its complexity down IMHO :).
Adopting RFC42 could help drastically here, cutting down NGINX complexity and pushing it on the user might be a good idea here too.
Thank you for doing this and I am available (let's say: starting the 6th) to help you land this.

Update from https://github.com/cryptpad/cryptpad/pull/1213 : they're dropping their complex nginx config in favor of one that just forwards everything to the node process.
I feel it's a bit of a shame, but that'll definitely be much easier to write "properly", so I'll update this PR with that as soon as I have some time (likely next weekend).
Most questions left in previous comment still stand for when you have time to answer, no hurry.

Sorry for the delay, I had mostly forgotten about this and have been keeping myself busy otherwise so might not have time to finish shortly...
Regarding my last comment, I was waiting for feedback from upstream regarding the default config but they're really really bad at replying to github so never got any answer; they reverted the "simpler nginx config" shortly after committing it and now there's both configs in their documentation.
Basically, we get to pick between either proxying everything through node, or keeping the complex config that does the bulk of simple files sending through nginx. I guess we should strive to keep the efficient config if we can, but if the simple config works it could work as a first step.
With that in mind, what do you think @RaitoBezarius ?
I don't think there's any hurry so while I might not have much time right now, I'll be happy to work with you to convert the horrible nginx config text block as something more dynamic, but I could use some pointers to start with (see previous questions) when you have time to answer.
If you don't have time either (let's say until the end of the year), let's just make this simple and proxy it all for now and I'll open a follow-up PR later™
Cheers.

If you don't have time either (let's say until the end of the year), let's just make this simple and proxy it all for now and I'll open a follow-up PR later™

Sounds good for now for me. (unfortunately always too many things to do…)

Thanks for the effort to bring Cryptpad back to NixOS, @martinetd! I made a feeble attempt last year but I couldn't even get the package to build with my limited Nix skills at the time. I've met one of the Cryptpad developers last month at NGI Forum 2023 in Brussels and they said that they indeed updated their build system, nice!
So I read up on the PR here and saw the discussion on the Nginx configuration bit. By chance I happen to have just done a clean Cryptpad install on a Debian server last week and I remember seeing the notes about the Nginx in their documentation. There are indeed 2 ways to put Cryptpad behind Nginx now. From the Cryptpad documentation:

CryptPad’s application server handles active connections via websocket and serves static assets (HTML, Javascript, CSS, etc.). This basic configuration is designed to be very easy to configure for small to midsize instances (up to 3000 concurrent users).

In a production environment, the development team recommends Nginx with our advanced example configuration for the following reasons:

Scale to many more users by serving static content with a more scalable web-server instead of the single-threaded NodeJS web-server that is built-in
Allow the application server to focus exclusively on handling websocket connections

I went with 1. (up to 3000 concurrent users) on the Debian server because it was for a relatively small setup. But to be honest that's what I often need Cryptpad for. I'd say large scale Cryptad setups (+3000 concurrent users) are probably less common than smaller scale setups. So I would recommend to go forward with the simple Nginx configuration and get this PR moving so that Cryptpad gets back into NixOS. Then future fixup PRs can add the more complicated Nginx configuration.
All that said. Can I do anything to help? I'm testing out this PR on an instance of my own. What can we do to move this forward?
Next I will read up on RFC 42 and I concur with @RaitoBezarius to further implement their comments. Thanks again. Let me know. Cryptpad is awesome!

I've hacked on this for a couple of hours, but it's getting pretty late here and I'm tired. I'd love to help out and polish this PR a bit more. I'm not sure what the best way to collaborate on this is. I think I've been able to clean up some of the code here with the simplified Nginx config, but I wonder what the best way to share is. Because I don't think there's a way I can add commits to this PR. Maybe I have to open a PR at the source at https://github.com/martinetd/nixpkgs/tree/cryptpad? Or should I just dump code suggestions in a review? What do you think?
I'm definitely not done with my incantation so I could continue to work on it over the next days / weeks and then come back here when I feel it looks presentable. Then you can have a look and decide what to do with it?

Some findings:

Websockets don't seem to get used / configured with the simplified Nginx config. I went to check in the setup on the Debian server I did last week and there's no configuration of websockets whatsoever yet Cryptpad works just fine (in page updates, notifications, all working). And I followed the official documentation for that install.
You can't have two virtualhosts with ACME for Cryptpad because that will generate two separate certificates. It's in the Cryptpad docs somewhere but you must generate 1 certificate with multiple names. There is an easy way to fix that using useACMEhost though.
Use of ssl_dhparam in nginx config should be checked / compared with what is done in sslDhparam
Use of resolver in nginx config should be checked / compared with what is done in sslDhparam
...

Thanks for looking at this! I started replying earlier and got interrupted, so lost my text, oh well.
Regarding how to work together -- I'm not fussy, adding commits on top of my branch somewhere that I can take (either a PR to my branch or just a stray branch somewhere, I can take the patches) is probably the most convenient for me. That'll work out somehow.
For nginx config (simple vs complex), I'm running this on a very weak atom so every bit helps and I'm not quite sure about the 3000 simultaneous users (pages are already pretty slow to load with the "advanced" config!); but I agree we can do this in two steps. Let's go with simple config now and I can try to add static paths etc later the proper way.
For the RFC42 bit, I'm not sure what you've done with the snippet you pasted (which is why I'd prefer to see patches, I'd need to copy this out somewhere to take a diff myself and really low on time right now)... My opinion is that the cryptpad settings themselves (config.js generation) is good enough as is -- I agree if we could hide some of the paths somehow the documentation would be better but this isn't a priority for me, and having settings like this already allows for users to add settings I didn't prepare myself (which is what I understand of RFC42 -- this is easily extensible without touching the module).
What we'd need to do is get rid of the nginxConfig = ''... snippet and do this through services.nginx.virtualhosts.... = { ... } instead, so settings can be properly processed/overridden as required.
My understanding is that this is the only piece of work that really needs to be sorted out before this can be merged?
As I'm short of time I'd also appreciate if you could rebase the commits and update the release note for the current rl.md, but this isn't difficult if you've got the nginx config sorted out I can find a moment to do it.
Cheers!

Thanks for looking at this! I started replying earlier and got interrupted, so lost my text, oh well.
I've had that happen on the web too, it sucks! Sometimes I remember to copy paste the text into my editor, continue there and then copy back. I often forget :)
Regarding how to work together -- I'm not fussy, adding commits on top of my branch somewhere that I can take (either a PR to my branch or just a stray branch somewhere, I can take the patches) is probably the most convenient for me. That'll work out somehow.

Yes, I want to either add commits on top of this PR or do a pull request on https://github.com/martinetd/nixpkgs/tree/cryptpad so that you can take patches from there. I'd prefer adding commits on top of this PR so the discussion can continue here, but I have no idea how to do that. I consider myself quite the git expert but this is something I haven't done yet (i.e. where I'm not the owner of the origin repo Nixos/nixpkgs here).
I already have a fork of nixpkgs from previous contributions at https://github.com/michaelshmitty/nixpkgs. I have done the following, but that does not work out:
# Add a remote to your nixpkgs fork to my nixpkgs fork
arrakis:~/code/nixpkgs [master]$ git remote add martinetd git@github.com:martinetd/nixpkgs.git
arrakis:~/code/nixpkgs [master]$ git fetch martinetd
# Checkout your cryptpad branch into a new local branch 'cryptpad' in my fork
arrakis:~/code/nixpkgs [master]$ git checkout -b cryptpad martinetd/cryptpad
# Rebased onto master like you asked and resolved the conflicts
arrakis:~/code/nixpkgs [cryptad]$ git rebase master

So now I have a local 'cryptpad' branch in my fork of nixpkgs rebased on latest origin master and containing your commits. Now I want to add on top of that. And then I want to either have my extra commits show up here or be able to open a PR on your fork to add them into your branch. But I can't seem to do that:
At https://github.com/michaelshmitty/nixpkgs/tree/cryptpad I only have the ability to open a new PR against origin nixpkgs, not your fork. I don't want to open a new PR, I want to add to this one or open a PR to your remote instead so you can compare and merge there.
I tried a few things, like pushing my branch to your fork, but that didn't work due to permission problems. I don't know if that's because this is not the right way to do it or if you have to allow contributors to your fork explicitly.
arrakis:~/code/nixpkgs [cryptpad]$ git push martinetd HEAD
ERROR: Permission to martinetd/nixpkgs.git denied to michaelshmitty.
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.

I really want to learn how to do this properly because it will help me contribute better in the future. So if anyone following this could help out, that would be awesome. @Janik-Haag I know you are very busy, but perhaps you could help me out? If I learn this I can help others. Plus I think many NixOS aficionados at CCC are going to love seeing Cryptpad back into nixpkgs!

For nginx config (simple vs complex), I'm running this on a very weak atom so every bit helps and I'm not quite sure about the 3000 simultaneous users (pages are already pretty slow to load with the "advanced" config!); but I agree we can do this in two steps. Let's go with simple config now and I can try to add static paths etc later the proper way.
For the RFC42 bit, I'm not sure what you've done with the snippet you pasted (which is why I'd prefer to see patches, I'd need to copy this out somewhere to take a diff myself and really low on time right now)... My opinion is that the cryptpad settings themselves (config.js generation) is good enough as is -- I agree if we could hide some of the paths somehow the documentation would be better but this isn't a priority for me, and having settings like this already allows for users to add settings I didn't prepare myself (which is what I understand of RFC42 -- this is easily extensible without touching the module). What we'd need to do is get rid of the nginxConfig = ''... snippet and do this through services.nginx.virtualhosts.... = { ... } instead, so settings can be properly processed/overridden as required.

Yes, forget my earlier pasted code. I know how to do it properly, but I want to put it in a commit and I would also like to know how to test this PR easily on one of my own servers.

My understanding is that this is the only piece of work that really needs to be sorted out before this can be merged?
Yes! There's a few more quirks to sort out like having both mainDomain and sandboxDomain used in the same virtualhost (if sandboxDomain is set) but other than that I think we're looking pretty good.
As I'm short of time I'd also appreciate if you could rebase the commits and update the release note for the current rl.md, but this isn't difficult if you've got the nginx config sorted out I can find a moment to do it.

I have time, but unfortunately I'm having to spend most of it on how to do the actual contribution instead of the code. That's why I want to learn this so I don't have this overhead on future contributions.

Cheers!

Again, thanks to you for bringing Cryptpad back!

I think I've figured it out. There's a huge commit list though because I've already rebased onto (fairly) latest master from nixpkgs upstream: https://github.com/martinetd/nixpkgs/pull/1

@martinetd My suggestions are ready. Until you sync your fork of nixpkgs it's perhaps easier to see my contributions here:
https://github.com/NixOS/nixpkgs/compare/master...michaelshmitty:nixpkgs:martinetd-cryptpad
instead of here https://github.com/martinetd/nixpkgs/pull/1
The first commit "Implement basic Nginx configuration for Cryptpad" adds the simplified Nginix config. I've done some additional work that you are free to look at in following commits. Note that I wasn't able to test any of this. I still need to learn how I can quickly try this out on my own server without too much hassle.
Feel free to review my contributions at https://github.com/martinetd/nixpkgs/pull/1 before continuing the conversation here if you like. Thanks!

The first commit "Implement basic Nginx configuration for Cryptpad" adds the simplified Nginix config. I've done some additional work that you are free to look at in following commits. Note that I wasn't able to test any of this. I still need to learn how I can quickly try this out on my own server without too much hassle. I can't run the tests on macOS. I'll need to setup a NixOS VM. Maybe I'll try that this afternoon.

nix -L build -f . nixosTests.cryptpad will run a VM so I believe it could work on MacOS but I haven't tried; if that works you can also evaluate nixosTests.cryptpad.driver and run ./result/bin/nixos-test-driver --interactive for further debugging (some example in https://blog.thalheim.io/2023/01/08/how-to-execute-nixos-tests-interactively-for-debugging/ )
But yeah for real tests running in a VM or similar would probably be easier

I've rebased to nixos-unstable (so a bit older than your branch, I want a working cache) and picked up your commits as they were a while ago (they were updated in the 10 minutes I checked this, I'll update again in a while longer)
Let's keep discussions here, I'll just fetch your branch before reviewing again. I'll give you a bit more time to play with the nginx config too :)

The first commit "Implement basic Nginx configuration for Cryptpad" adds the simplified Nginix config. I've done some additional work that you are free to look at in following commits. Note that I wasn't able to test any of this. I still need to learn how I can quickly try this out on my own server without too much hassle. I can't run the tests on macOS. I'll need to setup a NixOS VM. Maybe I'll try that this afternoon.

nix -L build -f . nixosTests.cryptpad will run a VM so I believe it could work on MacOS but I haven't tried; if that works you can also evaluate nixosTests.cryptpad.driver and run ./result/bin/nixos-test-driver --interactive for further debugging (some example in https://blog.thalheim.io/2023/01/08/how-to-execute-nixos-tests-interactively-for-debugging/ ) But yeah for real tests running in a VM or similar would probably be easier

Thanks! Unfortunately that doesn't work. Still seems to assert running on Linux:
arrakis:~/code/nixpkgs [martinetd-cryptpad]$ nix -L build -f . nixosTests.cryptpad
error:
       … while evaluating the attribute 'drvPath'

         at /Users/m/code/nixpkgs/lib/customisation.nix:263:7:

          262|     in commonAttrs // {
          263|       drvPath = assert condition; drv.drvPath;
             |       ^
          264|       outPath = assert condition; drv.outPath;

       … while calling the 'derivationStrict' builtin

         at /builtin/derivation.nix:9:12: (source not available)

       (stack trace truncated; use '--show-trace' to show the full trace)

       error: assertion '(stdenv).isLinux' failed

       at /Users/m/code/nixpkgs/pkgs/os-specific/linux/kernel/generic.nix:75:1:

           74|
           75| assert stdenv.isLinux;
             | ^
           76|

But that's ok, I'm trying to create a flake for this that I can then import in my infrastructure and test it that way. Taking inspiration from https://github.com/reckenrode/nix-foundryvtt

But that's ok, I'm trying to create a flake for this that I can then import in my infrastructure and test it that way. Taking inspiration from https://github.com/reckenrode/nix-foundryvtt

I've made a flake (https://github.com/michaelshmitty/cryptpad-flake) that I can easily iterate on and test in my infrastructure. The goal is to backport the code there as suggestion onto the PR here. I got it all up and running on my end but I had to fix some quirks like making sure the default generated config has all the paths in it as well. I have an instance up with the flake at https://cryptpad.michaelsmith.be/checkup/

5.6.0 has just been tagged.

I'm gonna remove my review request since there is already some quite capable reviewer involved.

@martinetd I pushed a commit to fix miscellaneous things here and there. Feel free to fixup the commit in yours at your best convenience (I don't care about the credits).

@drupol thanks for your commits and time! I've made some suggestions based on a newer version of my flake. You may want to have a look to see what else you'd like to backport: https://github.com/michaelshmitty/cryptpad-flake/blob/main/module.nix
I've made some extra options for the nginx virtualhost settings for example. And there are some bug fixes in it as well. Take what you want!

You may want to have a look to see what else you'd like to backport<EMAIL_ADDRESS>
Ugh, indentation is different so it's not easy to compare and pick either...
Did you use a tool for formatting? iirc there's still no agreement on nix formatting rule so stuff like nixfmt / nixpkgs-fmt aren't standard, but I guess I ought to give them a try..
For the rest I'll check if the patch is still needed & cleanup a bit over the weekend, you've both been working too fast for me. Thanks for picking up the slack :)

You may want to have a look to see what else you'd like to backport<EMAIL_ADDRESS>
Ugh, indentation is different so it's not easy to compare and pick either... Did you use a tool for formatting? iirc there's still no agreement on nix formatting rule so stuff like nixfmt / nixpkgs-fmt aren't standard, but I guess I ought to give them a try..

That's annoying, sorry for that. Yes I use nixpkgs-fmt for all my nix expressions. Even though there's no standard, I like to have some consistency for my own files. My suggestion to have a look at the flake was intended for @drupol because he's been so eagerly helping out. So don't feel obliged. It's great you got this ball rolling to get Cryptpad back into nixpkgs, thanks!

For the rest I'll check if the patch is still needed & cleanup a bit over the weekend, you've both been working too fast for me. Thanks for picking up the slack :)

No worries, I have the time. I just didn't know how to iterate quickly and add commits to this PR, but @drupol is already doing it. Supposedly there is away for you to allow contributions to this PR by others, but you have to enable it or something. I don't know about that. Luckily the ability to compose stuff in Nix helps out here.

I want to look into why a Cryptpad release is 800+ MB in size. That's kind of silly for a JavaScript based web app

I want to look into why a Cryptpad release is 800+ MB in size (compressed!). That's kind of silly for a JavaScript based web app.

Apparently it bundles ONLYOFFICE?
arrakis:~/src/cryptpad-5.6.0$ du -sh www/common/onlyoffice
1.8G	www/common/onlyoffice

sheesh...

Apparently it bundles ONLYOFFICE?

Ah, for Spreedsheets wow...

I want to look into why a Cryptpad release is 800+ MB in size (compressed!). That's kind of silly for a JavaScript based web app.

Apparently it bundles ONLYOFFICE?
arrakis:~/src/cryptpad-5.6.0$ du -sh www/common/onlyoffice
1.8G	www/common/onlyoffice

sheesh...

I want to look into why a Cryptpad release is 800+ MB in size (compressed!). That's kind of silly for a JavaScript based web app.

Apparently it bundles ONLYOFFICE?
arrakis:~/src/cryptpad-5.6.0$ du -sh www/common/onlyoffice
1.8G	www/common/onlyoffice

sheesh...

Yes... this is one of the reasons that I prefer and use every day hedgedoc (available in Nix!).

thanks folks for repack such a "interesting" program!
I tried the current PR.
I needed to remove the patch ./0002-don-t-ignore-config-s-httpAddress.patch mention by @michaelshmitty .
Otherwise it didn't build with an error.
It is included in the v5.6 release of cryptpad here: https://github.com/cryptpad/cryptpad/commit/650e4c42ca9cd5f04fbbe53b7c879cb9b1419a73
I rebased the branch to nixos-23.11 for having it up to date, but mostly irrelevant for this PR.
here: https://git.o-g.at/nixpkg/nixpkgs/src/branch/cryptpad_tuxcoder
tested on x86_64

Sorry for lack of activity.
I've rebased + updated to 2024.3.0, they changed their build again (but I guess it's an improvement, they're not keeping all historical onlyoffice builds in their source tree anymore -- I'm using the binaries they provide instead of rebuilding it but it should be possible to rebuild it if we really want; I'm not going down this hole)
I've fixed also a few issues that were pointed out and tests; I'm still not very happy with this nginx config so I'll probably try to add a few bits from the advanced config as time permits but this appears to work.
I kept the commits as is and added more for easier review, but I guess at some point we might want to cut the work somewhere and say let's merge this. If there's no other obvious problem I'll tidy up the git history once 24.05 has branched out so we can merge this early next cycle.

Sorry for the delay in updating this; I think I've covered everything:

updated the package to the latest release; the httpSafePort patch conflicted with a comment update but meanwhile I've clarified with upstream we don't actually need it in most case (basically if the second domain is properly set); the config item is still broken so I've opened https://github.com/cryptpad/cryptpad/pull/1571 but we could live without it
module-side, they've strengthened the requirement on the websocket so I added a section in the nginx proxy for it as per their example
I removed the confinement option and just enabled it; https://github.com/NixOS/nixpkgs/pull/314440 also added a service with confinement enabled so let's bite the bullet and that'll be less burden on maintenance. If it turns out to be a problem I'll re-add the option, but I'd expect it to just work for everyone.
some small details like nginx recommended proxy settings were enabled; they're set in the example cryptpad config from upstream so we probably want them here too.

I've also updated my own instance to this PR and was able to access old data, create new files etc fine as expected. the checkup only fails HSTS but we don't have any nginx config that sets it so I'll let that fail.
So hopefully this is now ready!

I got nerd-snipped into adding some systemd hardening options to the service (then drifted into #328648 because SocketBindDeny=all didn't work...); shouldn't change anything user-facing but I've kept that as a separate commit to easily revert just in case.
(At least no problem on my server, and I've also confirmed disabling blockDailyCheck also still works even if I'm not sure who would do that... fun fact, if you disable it in the nixosTests then cryptpad tries to connect to the accounting server before eth0 is up so that telemetry request never goes anywhere unless you restart the service later (or make the service depend on having a default route); I'll pretend I didn't see that)
Really won't touch this anymore now.

(sorry to systemd folks, pushed the bpf fix by mistake here and removed it but I assume the harm is done and you got cc'd :/)

Fixed the subject line; I think it still makes sense to mention it's a re-add in the details but that probably doesn't bother anyone if I ramble a bit there.
I'm not sure if you meant I should also squash the hardening patch; I'd also prefer to keep it separate in case the hardening causes problems for anyone as I haven't left my instance running with these hardened settings for long enough to be confident all corner cases work properly and it could be helpful to just revert it, but will squash if you think it's better.

Thank you!
Opinionated thought: I don't believe mentioning that it has been removed then added again in the commit log message is relevant. However, mentioning it in the commit log description and PR makes sense.

Hmm, I guess that if the file name stays the same doing a git log by path would easily find the removal commit again, but in this case for the package the path isn't the same so one wouldn't stumble on the old package by chance so one wouldn't notice it's a re-add and try to compare with the old package (although to be fair it's different enough that it probably wouldn't be of any help)
For the module git log would yield the removal and old commits, at which point I think being explicit that it's a full rewrite that has nothing to do with the old version is also helpful.
(... and actually now I think about it even if the content was close I'd do something like a revert first and then add whatever fix is needed as a separate commit, so it's also mentioning that it's a re-add indirectly...)
Anyway, in general I'd rather be more verbose than not enough in commit messages -- if what was in commit messages wasn't enough one can always find the PR, but the first place I look is commit messages and if that has enough information I'll be more than happy to not have to open firefox.
So back to square one, sorry for being insistent but if you still want me to reword if as a new module I'll do that later tonight, just say. I don't have to agree if that helps get the module merged :)

No worries, we are just discussing, and it's totally fine to not agree on everything.
The current state of things in this PR is good, I wouldn't change anything.


Feature request: Create integration with Gitbook?

It would be awesome to see this in a gitbook format. WIth the existing travis integration, it should be pretty easy to do so. Makes the doc nice and searchable then.

If you'd like the book ready and automatically up-to-date in a different format, buy it!
If you for some reason are unable to do so, that's fine too! As it's written in markdown it's easy to convert it to a myriad of formats through pandoc and other open source tools. :)


⚠ Bofrost.es has degraded performance

In 6eac71e, Bofrost.es (https://www.bofrost.es) experienced degraded performance:

HTTP code: 200
Response time: 1386 ms

Resolved: Bofrost.es performance has improved in ff098e7 after 21 minutes.


get database all table meta data not implemented

currently, the table meta data is return null , which should be implemented

currently, 5.3.3 branch have one getTables implemented


Replace main hero image with actual text

need to figure out the font family for the logo (asking right now):

might need to figure out the font family for HackUMass XII logo. Let me know what you think @Shiven110504

Let me know what you think @Shiven110504


Dev james

This pull request includes a small change to the pyproject.toml file. The change adds autodoc_mock_imports to the documentation configuration.

pyproject.toml: Added autodoc_mock_imports with the value ["mpi4py"] to the documentation configuration.

:warning: Please install the  to ensure uploads and comments are reliably processed by Codecov.
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 100.00%. Comparing base (76edf49) to head (424c739).
Report is 3 commits behind head on main.

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@            Coverage Diff            @@
##              main       #22   +/-   ##
=========================================
  Coverage   100.00%   100.00%
=========================================
  Files            2         2
  Lines           92        92
=========================================
  Hits            92        92

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.


Large binaries in the repository

Due to an erroneous commit in #364, a large amount (~600 MB) of binaries landed in the repository.
Although they have been deleted by the next commit, they are still downloaded when cloning the repository.
A solution proposed by @bjoernbroetz allows to clean the data from the repository but requires an action by all users. Further information to be posted here.
@ESMValGroup/esmvaltool-developmentteam

So the way to go here will be (as @bouweandela already wrote here ) to rewrite the history of that branch and then all of us should execute
git gc

on all our local clones.

I have seen that we don have the usual binary formats in our .gitignore files.
I will add them and look for a way to prevent this from happening again in a more general way

A further measure to prevent us from committing large binary files to the repository could be to setup a pre-commit hook.

Somehing like this https://stackoverflow.com/questions/7147699/limiting-file-size-in-git-repository?

The branch is fixed, see here.
If you still have to run the git fetch && git gc on your local clone

Correction: Please, issue
git reflog expire --expire=now --all &&  git gc --prune=now --aggressive

on your local clone.

This can cause you to loose your stash, so git stash pop might not work anymore.
If you are not using git stash or make sure that there is no stash currently active, that is not an issue.

If you already lost your stash you can find its commit (look for the blue stash label in gitk or try something like git log stash). Then with the hash you can do
git stash apply 5ce5647dc1ae4916b44725612ab26e55399c3591

to get the stash back and git stash to stow it away again.

For the developers @bjoernbroetz @jvegasbsc, here is a stackoverflow answer that helps to find large objects in the repo.

I have run the commands:
git gc git reflog expire --expire=now --all &&  git gc --prune=now --aggressive
And also:
git rev-list --objects --all \ | git cat-file --batch-check='%(objecttype) %(objectname) %(objectsize) %(rest)' \ | sed -n 's/^blob //p' \ | sort --numeric-sort --key=2 \ | cut -c 1-12,41- \ | numfmt --field=2 --to=iec-i --suffix=B --padding=7 --round=nearest
from the stack overflow page linked by @zklaus.
However, I'm not entirely sure that these files have the desired effect. My ESMValTool directory is still ~1.3 GB, and the stack overflow command above still says that my repository contains 8x 54MB surge height files.
What is the expected result of these commands? (How can I tell if they worked?) Thanks!

It is expected that the size of the local clone goes down to about the size of a newly cloned ESMValTool repository, i.e.: currently ca 144M (there are still some binaries there that will be removed later...)
If everything fails you could consider to create a new local clone.

guys, after a fresh git repo clone git fetch don't work no more and I suspect neither will git stash. Bit of a bummer because I use them both...

Hej @valeriupredoi, could you be a little more specific? I just did a fresh clone followed by git fetch without a problem, so it does not seem to be a problem with the server repo per se.
What kind of error are you getting?

hey @zklaus man, no error, git clone and followed it by git fetch and nothing shows up after git fetch, it returns to prompt

Could it be that there simply is nothing to fetch? In that case there is no output and that is usually what you expect for a fetch right after the clone.

the verbose option works well and I can see the branches again cheers :grinning:

Hi, I am in a situation similar to that described by @ledm. After following the instructions, the folder is still > 700 MB. It seems that most space is taken by the pack files, in ./git/objects/pack/
-r--r--r-- 1 serva serva 574K Oct  2 11:30 pack-676cd0e0b9cb013bd885d2aa85c8e2398ced78bd.idx
-r--r--r-- 1 serva serva 253K Oct  2 11:43 pack-633725fee65918461caecf0146d92cd7f781e117.idx
-r--r--r-- 1 serva serva 583M Oct  2 11:53 pack-676cd0e0b9cb013bd885d2aa85c8e2398ced78bd.pack
-r--r--r-- 1 serva serva  11M Oct  2 11:53 pack-633725fee65918461caecf0146d92cd7f781e117.pack
Do you know if it is safe to delete the larger file?
And secondly, I still have the folder "doc" and "interface_scripts" in the local branch, while they are absent from version2_development. Shouldn't they be automatically purged when pulling? Can these be removed, as well? Many thanks

See git clean --help for help on how to remove untracked stuff. If you do not have (m)any local changes, by far the easiest solution might be to just start from a clean clone of the github copy of the repository.