Word Wrap Problem

Related Issue

Word Wrap Problem, issue no. #1387

Proposed Changes

Given ‘n’ words of various lengths, and a limit on the number of characters that can be put in one line. Assume each word has length less than the width of line. You have to arrange these given words in line.

Checklist

[x] ✅ My code follows the code style of this project.
[ ] 📝 My change requires a change to the README.
[x] 🎀 I have updated the README accordingly.
[x] 👀 I have read the CONTRIBUTING document.
[x] ✨ I have added tests to cover my changes.
[x] 🚩 All new and existing tests passed.
[x] 🌟 ed the repo

[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to change)

Output Screenshots

Let take an array A={aaa, bbb, cc, dddd} and length of line=6.

@Mrjoy832 Please check my pr for issue no. #1387

Put ticks on proper boxes

Put ticks on proper boxes

@Mrjoy832 which box should i tick? I think i tick accordingly.

Put ticks on proper boxes

@Mrjoy832 which box should i tick? I think i tick accordingly.

I closed my laptop and on my bed 😂😂please check Amy merged PR

Put ticks on proper boxes

@Mrjoy832 which box should i tick? I think i tick accordingly.

I closed my laptop and on my bed 😂😂please check Amy merged PR

@Mrjoy832 Can you please tell me what do you by "Amy Merged PR", i don't get it?
and by mistake i closed my PR can you please also tell how to reopen "i by mistake clicked on closed without comment".

Put ticks on proper boxes

@Mrjoy832 which box should i tick? I think i tick accordingly.

I closed my laptop and on my bed 😂😂please check Amy merged PR

@Mrjoy832 Sorry for this late, Can you please tell me what do you by "Amy Merged PR", i don't get it?

Put tick on 2nd box

Put tick on 2nd box

@Mrjoy832 Is there any further process to get my PR merged?

LGTM🌟

@Mrjoy832 Out of this pr, a doubt, How many PR's should get merged to get official certificate from GSSOC, because from next week i am having my exams?

@Mrjoy832 Out of this pr, a doubt, How many PR's should get merged to get official certificate from GSSOC, because from next week i am having my exams?

I think 60 points ...but not 100% sure


"Docs" Folder

Documentation Scope
Docs are scattered throughout the application. One new user reports this is difficult to navigate.
Describe the Change
We could have a "Docs" folder to make it easier to find docs.

It makes sense to place docs of plugin inside the  plugin's own folder.
Maybe we could use some tool or write some scripts to pull all those docs together and generate a github pages website for document

All documentation will be addressed by official website in the future, not a problem anymore


Allow for using KClass<*> directly ➕  by forgery() delegate

Description
Allow using Kotlin class definitions directly.
Added forgery and forgeries property delegate.
How to test / reproduce
See readme
Review checklist

[x] PR is split into meaningful commits for the ease of reviewing
[x] Description contains clear instructions on how to test the feature (where applicable)
[x] Tests have been written
[x] Appropriate labels have been applied - sure they have

Hey I made a small change to the the work flow here: https://github.com/HelloCuriosity/model-forge/pull/45/files
The coverage report should upload after you rebase 👍

Codecov Report

Merging #44 (fb3e15b) into main (430ef6c) will decrease coverage by 5.8%.
The diff coverage is 55.5%.

@@            Coverage Diff             @@
##               main     #44     +/-   ##
==========================================
- Coverage     100.0%   94.1%   -5.9%
  Complexity       39      39
==========================================
  Files             9      11      +2
  Lines            61      68      +7
  Branches          9      10      +1
==========================================
+ Hits             61      64      +3
- Misses            0       4      +4


Configure ignores CXX environment variable

export CXX=clang++35
./configure

gives the error
Checking if compiler (g++) supports -std=c++11 flag... (cached) no
C++ compiler does not support C++11 standard (-std=c++11), which is required. Please upgrade your compiler to at least g++ 4.7 (ideally 4.8)

Inspecting config.log reveals it is trying the command g++ -o .sconf_temp/conftest_2.o -c -std=c++11 -DSHAPE_MEMORY_MAPPED_FILE -Iinclude -I/usr/include -I/usr/local/include/freetype2 -I/usr/local/include/libxml2 .sconf_temp/conftest_2.cpp

node-mapnik does not have a ./configure script so I presume you intended to create this at the mapnik repo? Either way, this behavior is by design. The ./configure script is a shim around scons and the longstanding behavior of the scons script is to only accept options via argument and not by environment.

you intended to create this at the mapnik repo?

yes


GCCH Specific details

This feature is not currently available in GCCH to all tenants. Can you please add specific information about this features availability in GCCH?
Here is the link to the roadmap entry for this. https://www.microsoft.com/en-us/microsoft-365/roadmap?featureid=86311

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

ID: 470478ed-3b4e-ced8-0e28-6cda545b8400
Version Independent ID: 95b4044b-3a47-a511-c726-b5ee75863441
Content: Manage meeting settings - Microsoft Teams
Content Source: Teams/meeting-settings-in-teams.md
Service: msteams
GitHub Login: @SerdarSoysal
Microsoft Alias: serdars

Hi @J227668, thank you for your feedback.
I think this feature should be available now for GCCH.

@dariomws it is currently being rolled out and should be available to all tenants by the end of the month is my current understanding. Customers often look to the docs page for guidance on if the feature is available in GCCH and if the set up/configuration the process is the same. Can we call out in the document any known parity? https://docs.microsoft.com/en-us/microsoftteams/meeting-settings-in-teams.
Alternatively can we call out specifically that anonymous meeting join is available to GCCH customers?
https://docs.microsoft.com/en-us/microsoftteams/meeting-settings-in-teams#allow-anonymous-users-to-join-meetings

@J227668, please check the note I'm adding.
If you have a Microsoft alias, you can link your accounts in GitHub so that a blue "Microsoft submitter" label appears to any PR's or issue you submit. Guidance on it here: https://docs.opensource.microsoft.com/tools/github/index.html
Here is the site you can use to see the mappings between GitHub and Microsoft aliases: https://repos.opensource.microsoft.com/people?q=


Cleanup on deprecated API

Fix prop name
Undeprecate XSD (only XSL is defunct)
Remove long dead part

Codecov Report

Merging #1846 (afcc2a6) into master (2ff411a) will decrease coverage by 2.90%.
The diff coverage is 100.00%.

@@             Coverage Diff              @@
##             master    #1846      +/-   ##
============================================
- Coverage     87.74%   84.84%   -2.91%
+ Complexity     7763     7760       -3
============================================
  Files           282      282
  Lines         21321    21310      -11
============================================
- Hits          18709    18080     -629
- Misses         2612     3230     +618

Flag
Coverage Δ

5-max
84.84% <100.00%> (-2.91%)
:arrow_down:

7.4
84.84% <100.00%> (-2.91%)
:arrow_down:

agnostic
66.92% <100.00%> (+0.01%)
:arrow_up:

mysql
?

pgsql
?

sqlite
66.86% <0.00%> (+0.01%)
:arrow_up:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

src/Propel/Generator/Manager/AbstractManager.php
77.20% <ø> (ø)

src/Propel/Generator/Model/Table.php
91.63% <ø> (+0.25%)
:arrow_up:

...l/Generator/Behavior/Delegate/DelegateBehavior.php
90.22% <100.00%> (ø)

src/Propel/Generator/Reverse/PgsqlSchemaParser.php
0.00% <0.00%> (-86.62%)
:arrow_down:

src/Propel/Generator/Reverse/MysqlSchemaParser.php
0.00% <0.00%> (-86.24%)
:arrow_down:

src/Propel/Runtime/Adapter/Pdo/PgsqlAdapter.php
2.94% <0.00%> (-50.00%)
:arrow_down:

src/Propel/Runtime/Adapter/Pdo/MysqlAdapter.php
41.30% <0.00%> (-36.96%)
:arrow_down:

.../Propel/Generator/Reverse/AbstractSchemaParser.php
44.44% <0.00%> (-22.23%)
:arrow_down:

.../ActiveQuery/QueryExecutor/InsertQueryExecutor.php
59.37% <0.00%> (-21.88%)
:arrow_down:

src/Propel/Generator/Platform/PgsqlPlatform.php
81.42% <0.00%> (-13.63%)
:arrow_down:

... and 16 more

Continue to review full report at Codecov.

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


Some ideas of improvements

I was looking at the code and thought there are some things worth trying to further improve the execution time:

pass Summary by ref to Merge
Summary is 16 bytes and for min/max int is not needed, short should be enough.
.Select(x => (Name: x.Key.ToString(), x.Value)) for final result may not be needed, instead Utf8Span could implement IComparable and do comparison on Span property
if the previous point is implemented OrderBy can be replaced with something like Span<Utf8Span> spans = stackalloc Utf8Span[result.Count]; spans.Sort();
apply [SkipLocalsInit] to Summary since it looks like the Init method is always invoked for a new instance anyway
.ToList() may not be needed before calling Aggregate because Aggregate already has a version for ParallelQuery<TSource>
Console.Write($"{pair.Name} = {pair.Value}"); allocates an unnecessary string, could instead rewrite it as Console.Write(pair.Name); Console.Write(" = "); Console.Write(pair.Value) however not sure what is the performance of actual Console api, maybe the better strategy would be to just form 1 big resulting string and invoke a single Console.Write?

pass Summary by ref to Merge

Everything besides ProcessChunk has near zero impact on performance

Summary is 16 bytes and for min/max int is not needed, short should be enough.

Thanks, I did that after your original comment. It was helpful to reduce the struct size to 16 bytes.

.Select(x => (Name: x.Key.ToString(), x.Value)) for final result may not be needed, instead Utf8Span could implement IComparable and do comparison on Span property

Again, doesn't matter. I need to materialize the span at some point, it's better to just use string sort. Then I reuse the same strings for printing,
The rest is really not relevant for performance, it happens only once.

I need to materialize the span at some point

why? I think it should be possible to just print span to console

The rest is really not relevant for performance, it happens only once.

yes but it depends on the number of unique cities and if we combine overhead of ToList, allocations caused by OrderBy (btw we could sort this with Radix sort in O(N)) it may be noticeable

yes but it depends on the number of unique cities and if we combine overhead of ToList, allocations caused by OrderBy (btw we could sort this with Radix sort in O(N)) it may be noticeable

Oh, please. Profile it before suggesting. It's becoming boring.

The problem is there is no exact data set to profile, of course for the sample in the original repo with like 80 cities there would be no difference, however it was mentioned that we can not make any assumptions about the data and if all 1B rows have distinct cities it is obvious there will be a difference

Everything is 100% reproducible... I cannot even imagine which step could be difficult even for a total noob. Both Java repo (with its instructions), and this plain vanilla repo with script showing which commands to call.
Profiling is built into free IDEs.


Fixed potential divide by zero error

This fixes issue: https://github.com/microsoft/fhir-loader/issues/23
If the FHIR request is completed in less than 1000 milliseconds, then the conversion would return zero seconds. This causes a divide-by-zero error. I modified the divisor to a double so it will perform a floating point calculation instead of an integer calculation.

We refactored with telemetry client and the line in question no longer exists in main. Closing this out.


Include datetime stamp in IER12 filename.

Created as a placeholder for now.  Will fill out later.


Temporarily removed gitleaks commit hoook

This PR ...
Temporarily removes the gitleaks hook until we can determine the issues we are having with the current rules.
Test Steps:

Commit and verify that gitleaks does not run.

Changes

Commented out gitleaks from the pre-commit runner script.

Checklist
Testing

[x] Tested locally?
[ ] Ran ./prime test or ./gradlew testSmoke against local Docker ReportStream container?
[ ] (For Changes to /frontend-react/...) Ran npm run lint:write?
[ ] Added tests?

Process

[ ] Are there licensing issues with any new dependencies introduced?
[ ] Includes a summary of what a code reviewer should test/verify?
[ ] Updated the release notes?
[ ] Database changes are submitted as a separate PR?
[ ] DevOps team has been notified if PR requires ops support?

Pull reviewers stats
Stats for the last 30 days:

User
Total reviews
Median time to review
Total comments

MauriceReeves-usds
44
46m
11

cwinters-usds
30
1h 46m
26

sean-usds
23
1h 11m
8

jimduff-usds
21
1d 8h 36m
15

kevinhaube
20
1h 34m
11

carlosfelix2
17
4h 34m
40

RickHawesUSDS
16
4h 9m
6

whytheplatypus
10
17h 22m
20

TomNUSDS
9
2h 26m
12

clediggins-usds
9
2h 26m
17

jorg3lopez
5
6h 49m
0

jbiskie
5
1h 26m
1

brick-green-agile6
4
1h 5m
3

JosiahSiegel
1
4m
2

ahay-agile6
1
2d 16h 45m
0

oslynn
1
2h 42m
0

MikeC-A6
1
7h 7m
3

rhood23699
1
14h 10m
0

I also approved of this action. My reasoning is that GitLeaks was not working before, so this action does not reduce the effectiveness of this control. Will make it a priority to get a functional GitLeaks control in place.


renderToString not working

Bug report
Describe the bug
We try to use stitches to render our mail with the renderToString() method from react-dom/server and the styles are not included we don't know why :/
To Reproduce
call with renderToString(<Base title="TITLE" />)
Expected behavior
styles included in the final html
Screenshots

Hey @yovanoc 👋
I think you're using the SSR functionality incorrectly,
the css.getStyles function accepts the final app you're going to render.
It's important that it renders the app in order for it to be able to collect the styles.
Right now you're only passing it an empty function, hence it's not able to collect any styles
so here is a way to fix this:

encapsulate everything that uses stitches styles in one react component App.tsx
inside your Base component that renders the final HTML, you should not use any stitches components there. you then will be able to call

// here the result will be the output of running <YourApp/>
const { result, styles } = css.getStyles(() => <YourApp/>);

use styles and result to construct the HTML in your Base component.

I believe that this should fix your issue so I'm gonna close it but If you're still having the issue after doing the above, then please feel free to re-open it with a code reproduction that we can run (codesandbox, github repo, etc..) and we will be happy to assist you further ❤

Thanks for these informations but I not sure to understand. Here's what I changed and it gives me the exact same result:

@yovanoc
here is a working nodejs based codesandbox with renderToString working correctly https://codesandbox.io/s/crazy-bhabha-r4u9x?file=/src/index.js
one thing that I forgot to mention in my last comment is that the renderToString call needs to happen inside the callback for the styles to be injected correctly
besides that, in your screenshot, the global styles call will also need to happen inside the getStyles callback.
the result will be the HTML string so you will likely need to use dangerouslySetInnerHTML on the body.
if you apply the above changes and things are still not working for you. it would be very helpful if you could provide a repo or a codesandbox so that we could assist you better.

Thanks. All is working perfectly now!


No such property databaseChangeLog

When running:
grails dbm-changelog-sync
I get the following error.
INFO 20/12/16 12:06 PM: liquibase: Can not use class org.grails.plugins.databasemigration.liquibase.GormDatabase as a Liquibase service because it does not have a no-argument constructor
Command execution error: groovy.lang.MissingPropertyException: No such property: databaseChangeLog for class: Script1
:dbmChangelogSync FAILED
I have included in dependencies:
compile 'org.liquibase:liquibase-core:3.5.3'

as per the documentation.

Seems to work ok despite the error.

Attach an example project and I'll take a look

I'm seeing this during startup as well.  No noticeable side effects yet tho.

I am also seeing this during startup in a grails 3.2.4 project.
    compile 'org.liquibase:liquibase-core:3.5.3'

Closing this as no example project attached. If you are still facing this problem, open a new issue with an example project.


Improve ProjectRootElementCache caching strategy

ProjectRootElementCache.DiscardImplicitReferences is always called (directly or indirectly) from BuildManager.BeginBuild.  The implicit references will be all the .props and .targets files imported by a project.  These should be the project files that are most likely to be shared between different projects, so it seems counterproductive to force them to be ejected from the cache for each build.
With the Chromium solution (which has ~3500 projects), disabling the calls to DiscardImplicitReferences improved the time until Visual Studio finished initializing the projects from 18 minutes to 13.5 minutes on the PC I was using to test it.
While this is a great improvement, we need to understand if there is a good reason that the implicit references are being discarded, or if keeping them is likely to negatively impact other scenarios.

@BenVillalobos


Open multiseries tiff file with LazyArrays

I cannot open multiseries tiff files with Lazy Arrays. I have some multiseries recordings and also that is also how I convert .mmap files into .tiff files again when the files are bigger than my RAM or when I want to decrease the floating precision of the data for longer storage. It would be great if this was possible for fast visualizations.

LazyArrays are a mesmerize thing, you can now manually set the shape if you use the latest version on the repo. You could also subclass it with parsing logic for your file format. If you have further issues you can post it there.


Portfolio Desktop Version

Used media queries to display desktop screens
Built with CSS Grid and Flexbox
Replicated the design as much as possible from the selected Figma Template

Thanks😊


Do we need to replace the prompt ids in the result["labels"] with -100?

def group_texts(examples):
    # Concatenate all texts.
    concatenated_examples = {k: list(chain(*examples[k])) for k in examples.keys()}
    total_length = len(concatenated_examples[list(examples.keys())[0]])
    # We drop the small remainder, we could add padding if the model
    # supported it instead of this drop, you can customize this part to
    # your needs.
    total_length = (total_length // block_size) * block_size
    # Split by chunks of max_len.
    result = {
        k: [t[i : i + block_size] for i in range(0, total_length, block_size)]
        for k, t in concatenated_examples.items()
    }
    result["labels"] = result["input_ids"].copy()
    return result

The result["labels"] is the same as result["input_ids"] which contain the prompt ids, so the loss function will compute the loss of prompt ids, and I think this is no what we want in QA scenario. Therefore, do we need to replace the prompt ids in the result["labels"] with -100 to make loss function ignore the loss of prompt ids?

Thanks for your interest in LMFlow! For finetuning decoder-only models, we normally concatenate questions & answers together and ask models to reproduce the whole sequence, so this label is necessary. For evaluation, this label is indeed unnecessary, as shown in our code src/lmflow/pipeline/evaluator.py, no such group_texts procedure is invoked.
Hope that answers your question 😄

Thanks for your reply. I think result["labels"] only used in loss calculation, so if we mask the questions ids in result["labels"] with -100, we still can reproduce the whole sequence. Moreover, I check other open-source LLM fine-tune project, they will mask the questions ids in result["labels"] with -100 (e.g., https://github.com/tatsu-lab/stanford_alpaca/blob/main/train.py#L133, https://github.com/lm-sys/FastChat/blob/main/fastchat/train/train.py#L143). I want to know whether this setting will affect the model performance.

It seems that we need to refactor the preprocessing of the dataset to record question length and response length, which may require you to reformat the dataset, so it would be more appropriate for you to do the refactoring, and I look forward to your updates and experimental results.

Thanks for your suggestions! Actually we have considered that problem during architecture design. In that case, users will just provide a "text2text" typed data for decoder-only models, and the question/answer length will be available for the preprocessing procedure. This feature is under implementation and we will let you know as soon as it is available. Thanks 😄

Hi,
We have supported the text2text training by masking questions ids in result["labels"] with -100.
Thank you for your great suggestion!


Feature/frame pipeline

Cleanup repository:
Move

[ ] experimental/embeddings/scripts/evaluate_promises_sequence_tagging.py  to scripts/evaluate_promises_sequence_tagging.py
[ ]  experimental/embeddings/scripts/evaluate_document_classification.py to scripts/evaluate_document_classification.py

Remove

[ ]  Remove functionality from experimental that was moved to embeddings module. Even if it makes some parts of code from experimental broken

@laugustyniak @riomus @albert097
Should we have some predefined pipelines, where only parameters are dataset name and transformer name? Currently we have only scripts for that purpose.


Font from file data 3

last time. Sorry, I am trying to learn git

Resolved comments and manually merged :+1: Thank you again for the PR!

Resolved comments and manually merged :+1: Thank you again for the PR!

Ok thanks! Was busy doing other stuff this weekend. Sorry for not responding


Feature/asb 2134 terms and conditions page

Ticket: https://pins-ds.atlassian.net/browse/ASB-2134
-introduce terms and conditions page
-remove hardcoded links from packages/forms-web-app/src/views/components/core/pins-footer.njk
-update e2e test
Type of change 🧩

[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] Documentation update
[ ] Other (please explain in the description section above)

Checklist before requesting a review

[x] I have performed a self-review of my own code
[x] I have double checked this work does not include any hardcoded secrets or passwords
[x] I have made corresponding changes to the documentation
[x] I have provided details on how I have tested my code
[x] I have referenced the ticket number above
[x] I have provided a description of the ticket
[x] I have included unit tests to cover any testable code changes

:tada: This PR is included in version 1.9.1 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:

:tada: This PR is included in version 2.26.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:

:tada: This PR is included in version 2.21.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:

:tada: This PR is included in version 1.1.0 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


Add support to extract a TF_Function in tracing.

This makes changes in three places:

Adds a '$func' keyword for specifying which can be used to specify a function name for attributes of tensorflow ops that require a function (e.g., "If", "While", etc.)
Changes the IRGenSIL to generate appropriate tensorflow runtime calls for "$func" keyword.
Adds a _tffunc method to the compiler runtime to construct a TF_Function and return its name.

(Unfortunately, I could not split this up into smaller PRs with tests.)

@swift-ci please test tensorflow

@jekbradbury, FYI

@swift-ci please test tensorflow

@swift-ci please test tensorflow

@swift-ci please clean test tensorflow macos

@swift-ci please test tensorflow macos


setup.py is getting hung after trying to find nv-usd-py36.

Setup.py is getting hung after trying to find nv-usd-py36.
Processing project file 'packman/target_deps.xml'
Package 'nv-usd-py36' at version '<IP_ADDRESS>6f7aaf-linux-x86_64' is missing from local storage.
(hangs here)
Ubuntu 18.04
I had no trouble installing last Friday with a near identical build on another computer. Not sure why this is broken now. Can probably reproduce by nuking your packman-repo to simulate having a fresh setup and then running: python setup.py install
Other packman-repo packages are getting pulled and installed correctly for example:
Processing project file '/home/stephen/packman-repo/packman-common/6.1.3/deps.packman.xml'
Package '7za' at version '16.02.4' is missing from local storage.
Downloading from 'packman-bootstrap.s3.amazonaws.com'<EMAIL_ADDRESS>(4.33 MiB)
100.00% (speed 10.4 MiB/s)
Seems the url is no longer valid?
Edit*
I just downloaded and copied the files into the packman-repo and named the directory accordingly. Quick fix for anyone waiting for this to get fixed. Here's the file: https://developer.nvidia.com/usd

Could you please try this command and see if it works:
wget https://public.packman.nvidia.com/nv-usd-py36%4<IP_ADDRESS>6f7aaf-linux-x86_64.7z

This is effectively what packman is doing when pulling down the package.

Could you please try this command and see if it works:
wget https://public.packman.nvidia.com/nv-usd-py36%4<IP_ADDRESS>6f7aaf-linux-x86_64.7z

This is effectively what packman is doing when pulling down the package.

I have downloaded this package. There's not 'setup.py' for installation.How to install this package?

Hi, thank you for using Kaolin! The library went through a major rewrite with the version 0.9.0, and this issue is no longer current.
Please refer to our latest documentation:
https://kaolin.readthedocs.io/en/latest/
If you encounter issues, please file new bugs. Thanks!


Update 3D Tiles Sandcastle example

Made it more robust for tilesets without the expected properties and added new toggles for picking.

@lilleyse this is ready.

All looks good to me.


Ensure that the same exact version of PDF.js is used in both the API and the Worker

I don't have a good example at hand right know, but I recall seeing custom deployments of PDF.js that bundle a specific version of the build/pdf.js file and then set PDFJS.workerSrc to point to https://mozilla.github.io/pdf.js/build/pdf.worker.js.
That practice seems really bad since, besides (obviously) causing unnecessary server load, it will very quickly result in a version mismatch between the pdf.js and pdf.worker.js files in those PDF.js deployments.
Such a version mismatch could easily lead to either breaking errors, or even worse slightly inconsistent behaviour for an API call (if the API -> Worker interface changes, which does happen from time to time).
To avoid the problems described above, I'm thus proposing that we enforce that the versions of the pdf.js and pdf.worker.js files must always match.

/botio test

/botio-linux preview

@yurydelendik Thank you for the review :-)


Feature - Version check on Settings page

I took a first stab at this feature in issue https://github.com/BookStackApp/BookStack/issues/2809. It uses the Github API to check the latest release tag for this repository and uses version_compare to do a comparison. I only tested it with valid release versions (so no -dev).
@ssddanbrown

I added a new translation, what would be the correct way to add this to the repo?
Do you think this fits well with the rest of the application design wise?

Please let me know if there is anything unclear or missing. Thanks!

Thanks for this @siegerhansma, All appears to work nicely from a quick test on my dev instance.

I added a new translation, what would be the correct way to add this to the repo?

Please just add only the English translation value for the initial implementation. Our translation system will automatically create entries for all other languages once this is merged into master. So just editing and adding an entry to the resources/lang/en/settings.php file for this one.

Do you think this fits well with the rest of the application design wise?

Yeah, I'm happy with the simplicity, We don't need anything fancy here.
A few additional things it would be good to solve before I merge:

[ ] Could you please remove any changes to the package-lock.json from this? Since there are no dependency changes to be made here.
[ ] Please remove the if (app()->runningUnitTests()) { part. I will want to test this. It's fine to leave tests failing due to this, I'll look to mock the httpFetcher maybe globally for tests.
[ ] There's an option defined here that we'll need to honour in this since we're calling an external service; So always assume latest if config('services.disable_services') is true.

Hi @siegerhansma,
Would you still be looking to address the above to get this feature in? If you could at least do the first it would mean I could merge this while still attributing you, otherwise it makes things a little complicated while ensuring correct attribution.
Otherwise, Please let me know if you won't be able to make changes and I'll close this off.

Will therefore close this off. Feel free to re-submit this with the above requests in the future if not already addressed.


samples: Introduce "simple_txrx"

This introduce an example of use of Rail library in Zephyr.
This is a reboot of this PR. Compared to the original PR, this version:

remove some files imported from Simplicity Studio. Only radio_config.[ch] are kept.
drop the useless Finite State Machine

For now only two boards (based xg22 and xg24) are supported. I hope to add support for all the Series-2 boards in the future.
Note Zephyr does not allow to host samples application in HALs. Samples specific to one board and using non-standard APIs are not very welcomed in the main repo. So, the Silabs downstream is probably the best (the only) place to provide publish it.

v2:

rebase
fix long lines
fix C89 comments

v3:

rebase

Arg... I forgot to merge hal_silabs first

Seems like we should really take https://github.com/zephyrproject-rtos/action-manifest into use together with a DNM label and the appropriate branch protections, so that these mistakes don't happen.

I have to admit the current process is error prone.


Add price symbol param

Adds a price symbol parameter to the API call
This will allow other currencies (a setting that could be added to the UI)

Looks like prettier had a change up to. Let me know if you don't want this 😄

made the changes, removing prettier. Any reason that you the project isn't following the ESLint rules?


Question: TLS 1.3

Hello!
Do you have plans to implement TLS 1.3 support on SSLProxy?
Best Regards;

I have just pushed the tls13 branch, which cannot pass travis tests, but I know why and that's alright for now. It passes my e2e tests, so I think it works. Can you try the tls13 branch and report back please?

Hi,
I tested it with the tls13 branch and works.
The test was done with Centos 7, openssl 1.1.1f and libevent 2.1.11
[root@centos src]# ./sslproxy -V
SSLproxy  (built 2020-06-25)
------------------------------------------------------------------------------
WARNING: Something is wrong with the version compiled into sslproxy!
The version should contain a release number and/or a git commit reference.
If using a package, please report a bug to the distro package maintainer.
------------------------------------------------------------------------------
Copyright (c) 2017-2020, Soner Tari<EMAIL_ADDRESS>https://github.com/sonertari/SSLproxy
Copyright (c) 2009-2019, Daniel Roethlisberger<EMAIL_ADDRESS>https://www.roe.ch/SSLsplit
Build info: V:DIR N:475e540
Features: -DHAVE_NETFILTER
NAT engines: netfilter* tproxy
netfilter: IP_TRANSPARENT IP6T_SO_ORIGINAL_DST
Local process info support: no
compiled against OpenSSL 1.1.1f  31 Mar 2020 (1010106f)
rtlinked against OpenSSL 1.1.1f  31 Mar 2020 (1010106f)
OpenSSL has support for TLS extensions
TLS Server Name Indication (SNI) supported
OpenSSL is thread-safe with THREADID
OpenSSL has engine support
Using SSL_MODE_RELEASE_BUFFERS
SSL/TLS protocol availability: tls10 tls11 tls12 tls13
SSL/TLS algorithm availability: !SHA0 RSA DSA ECDSA DH ECDH EC
OpenSSL option availability: SSL_OP_NO_COMPRESSION SSL_OP_NO_TICKET SSL_OP_ALLOW_UNSAFE_LEGACY_RENEGOTIATION SSL_OP_DONT_INSERT_EMPTY_FRAGMENTS SSL_OP_NO_SESSION_RESUMPTION_ON_RENEGOTIATION SSL_OP_TLS_ROLLBACK_BUG
compiled against libevent 2.1.11-stable
rtlinked against libevent 2.1.11-stable
compiled against libnet 1.1.6
rtlinked against libnet 1.1.6
compiled against libpcap n/a
rtlinked against libpcap 1.5.3
compiled against sqlite 3.7.17
rtlinked against sqlite 3.7.17
2 CPU cores detected

Connection Log:

SNI peek: [tls13.1d.pw] [complete], fd=41
Connecting to [<IP_ADDRESS>]:443
SNI peek: [tls13.1d.pw] [complete], fd=43
Connecting to [<IP_ADDRESS>]:443
===> Original server certificate:
Subject DN: /CN=tls13.1d.pw
Common Names: tls13.1d.pw/tls13.1d.pw/www.tls13.1d.pw
Fingerprint: C4:12:9C:09:6C:53:7B:0D:55:2714:4C:D2:54:7A:06:22:78:F1:AF
Certificate cache: MISS
===> Original server certificate:
Subject DN: /CN=tls13.1d.pw
Common Names: tls13.1d.pw/tls13.1d.pw/www.tls13.1d.pw
Fingerprint: C4:12:9C:09:6C:53:7B:0D:55:2714:4C:D2:54:7A:06:22:78:F1:AF
Certificate cache: MISS
===> Forged server certificate:
Subject DN: /CN=tls13.1d.pw
Common Names: tls13.1d.pw/tls13.1d.pw/www.tls13.1d.pw
Fingerprint: F6:48:6E:17:CF:0A:11:9C:43:132D:83:BB:84:AF:47:F7:EA:8D:60
HTTPS connected to [<IP_ADDRESS>]:443 TLSv1.3 TLS_CHACHA20_POLY1305_SHA256
CLIENT_RANDOM 21BB4E5C37F19AB79D0CFC0D9A8BE3D064A5BAEC1A0554AE64D7055B867A7C4F<PHONE_NUMBER>00000000000000000000000400000000000000184EC1A4967F00000E0000000000000070660094967F0000
SSL session cache: MISS
Certificate cache: KEEP (SNI match or target mode)
SSL session cache: MISS
Certificate cache: KEEP (SNI match or target mode)
===> Forged server certificate:
Subject DN: /CN=tls13.1d.pw
Common Names: tls13.1d.pw/tls13.1d.pw/www.tls13.1d.pw
Fingerprint: B3:EC:39:0C:BD:1D:60:7F:B1:560E:FE:9E:E2:4E:CB:1D:E3:B9:60
HTTPS connected to [<IP_ADDRESS>]:443 TLSv1.3 TLS_AES_256_GCM_SHA384
CLIENT_RANDOM 4D1E3DF57EABA3DB92ECBF7175D956DF72DD028318513C8F63F135C30A2592BC<PHONE_NUMBER>00000000000000000000000400000000000000184EC1A4967F00000E00000000000000D08F009C967F0000
SSL session cache: MISS
Certificate cache: KEEP (SNI match or target mode)
SSL session cache: MISS
Certificate cache: KEEP (SNI match or target mode)
HTTPS connected to [<IP_ADDRESS>]:443 TLSv1.3 TLS_AES_128_GCM_SHA256
CLIENT_RANDOM 9B75C686004C88D7B1F87E6A6179BDC7CC70C921DE246DAC7447DF6EB2BDDF8D 0995A362BC6FEBD6F6A3903C61A6D6E1C0070CDB08636897507F03124A1076F100000000000000000200000000000000
HTTPS connected to [<IP_ADDRESS>]:443 TLSv1.3 TLS_AES_128_GCM_SHA256
CLIENT_RANDOM 63608989FC901616D9DE19186F5E509EE27FEE71AAC98640BA4BBA0FD37ABD9C 5608F6B4092BE55FE6CBC03A417522058DDB06C96F5414D07534206D055C5AEC00000000000000000200000000000000
Child connecting to [<IP_ADDRESS>]:443
SSL_free() in state 00000001 = 0001 = SSLOK  (SSL negotiation finished successfully) [connect socket]
Child HTTPS disconnected to [<IP_ADDRESS>]:443, child fd=49, fd=41
Child HTTPS disconnected from [<IP_ADDRESS>]:2364, child fd=49, fd=41
CONN: https <IP_ADDRESS> 2364 <IP_ADDRESS> 443 tls13.1d.pw GET / 200 - sni:tls13.1d.pw names:tls13.1d.pw/tls13.1d.pw/www.tls13.1d.pw sproto:TLSv1.3:TLS_AES_128_GCM_SHA256 dproto:TLSv1.3:TLS_AES_256_GCM_SHA384 origcrt:C4129C096C537B0D5527144CD2547A062278F1AF usedcrt:B3EC390CBD1D607FB1560EFE9EE24ECB1DE3B960 user:-
SSL_free() in state 00000001 = 0001 = SSLOK  (SSL negotiation finished successfully) [accept socket]
HTTPS disconnected to [<IP_ADDRESS>]:443, fd=41
HTTPS disconnected from [<IP_ADDRESS>]:2364, fd=41

Thanks  for your support.

Thanks for testing. Btw, I have fixed the testproxy e2e tests, so travis tests pass now too.

Will this enable support for Encrypted SNI?

No, Encrypted SNI is not supported, as mentioned in README.


Define chaos workflows that can sequence experiments in a desired manner

Ref: https://github.com/argoproj/argo/blob/master/examples/dag-diamond-steps.yaml

The workflow creation takes into account the parallel/sequential sub-flows or experiments (target could be one application or multiple, each mapped to the respective sub-flow)
Ability to launch the liveness controllers described here
Calculate a resiliency score on the basis of outcome of the workflow
Expose the resiliency data as a result resource

Run custom resource that is currently a WIP should handle most of the DAG requirements. We can have a set of planned actions to see completion of this requirement:

[ ] Initial completion of Run controller
[ ] Create examples that are run & tested via CI
[ ] Create docs
[ ] Execute the real world chaos scenarios that need to be run as a DAG or without DAG via this Run controller
[ ] Design resiliency score
[ ] Implement resiliency score

@ksatchit Meanwhile, let us try to put some real world scenarios of a bunch of experiments that need to be run as a 1/ DAG & 2/ without DAG.


Make "needs sudo" a guest fact

Then it can be used by interested parties. It was needed for package installation, then for installation of tmt scripts, and we seem to need it for touching /etc/hosts in multi-host lands.
The patch adds the fact, but does not seek out all uses of sudo - some will need a bit more work, therefore worth their own patches.

Oops, I forgot to update the test.


I did make a better version that are made for human consumption, then went to work on another project, and like the Idiot I am I did sudo rm -rf particle-engine.py how ironic >:(

Waiting to see the grace of the Pythonic God

LOLLLL

im actually on the floor rn

Welp I now did rerewrite it but I'm blocked out of github cause 2FA and
Microsoft doesn't support Egypt
Making me look even far worse than what I have been lol
On Sun, Nov 19, 2023, 2:21 AM Crooked Alter @.***>
wrote:

im actually on the floor rn
—
Reply to this email directly, view it on GitHub
https://github.com/hunar4321/particle-life/issues/90#issuecomment-1817696919,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AOUNPJ35Y3D4HGCZWIT23Q3YFFGG3AVCNFSM6AAAAAAX6KUYNWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQMJXGY4TMOJRHE
.
You are receiving this because you were mentioned.Message ID:
@.***>

wait, but I can't even run the C++ program because the ofMain.h; ofxGui.h and ofUtils.h don't even exist...

it's a bit annoying how openframeworks work. you need to install the framework and import the project. i think it's described somewhere in the readme.

wait, but I can't even run the C++ program because the ofMain.h; ofxGui.h and ofUtils.h don't even exist...

it's a bit annoying how openframeworks work. you need to install the framework and import the project. i think it's described somewhere in the readme.

Thank you

How is your Python programming going? I can't wait to see some top tier code

I have finished I just can't log into github and deploy it because of the 2
factor authentication
I live in a country that isn't supported :(
On Thu, Jan 4, 2024, 11:30 PM Alan Haertel @.***> wrote:

How is your Python programming going? I can't wait to see some top tier
code
—
Reply to this email directly, view it on GitHub
https://github.com/hunar4321/particle-life/issues/90#issuecomment-1877785789,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AOUNPJ7AL6EME2AN4353HJ3YM4NN7AVCNFSM6AAAAAAX6KUYNWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNZXG44DKNZYHE
.
You are receiving this because you were mentioned.Message ID:
@.***>

sure
On Fri, Jan 5, 2024 at 6:54 AM King Oni @.***> wrote:

I have finished I just can't log into github and deploy it because of the
2
factor authentication
I live in a country that isn't supported :(
On Thu, Jan 4, 2024, 11:30 PM Alan Haertel @.***> wrote:

How is your Python programming going? I can't wait to see some top tier
code
—
Reply to this email directly, view it on GitHub
<
https://github.com/hunar4321/particle-life/issues/90#issuecomment-1877785789>,

or unsubscribe
<
https://github.com/notifications/unsubscribe-auth/AOUNPJ7AL6EME2AN4353HJ3YM4NN7AVCNFSM6AAAAAAX6KUYNWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNZXG44DKNZYHE>

.
You are receiving this because you were mentioned.Message ID:
@.***>

—
Reply to this email directly, view it on GitHub
https://github.com/hunar4321/particle-life/issues/90#issuecomment-1878620593,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/BAQPTOJGSOGCVKDRSP4N6P3YM7ZZLAVCNFSM6AAAAAAX6KUYNWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNZYGYZDANJZGM
.
You are receiving this because you commented.Message ID:
@.***>

--
-----------------------------
Christian Osei
6th Grade - Homeroom / Ellis

Here is a pythonic version, I asked ChatGPT to modify the Python code so that the pythonic community are happy :)
`import matplotlib.pyplot as plt
import random
import math
window_size = 200
class Atom:
def init(self, x, y, color):
self.x = x
self.y = y
self.vx = 0
self.vy = 0
self.color = color
def update_position(self):
    self.x = min(max(self.x + self.vx, 0), window_size)
    self.y = min(max(self.y + self.vy, 0), window_size)
    self.vx *= -1 if self.x in {0, window_size} else 1
    self.vy *= -1 if self.y in {0, window_size} else 1

def apply_force(self, fx, fy):
    self.vx = (self.vx + fx) * 0.5
    self.vy = (self.vy + fy) * 0.5

def draw(ax, atom, size=3):
ax.plot(atom.x, atom.y, 'o', color=atom.color, markersize=size)
def random_position():
return random.uniform(1, window_size)
def create_atoms(number, color):
return [Atom(random_position(), random_position(), color) for _ in range(number)]
def apply_rule(atoms1, atoms2, g):
for a in atoms1:
fx, fy = 0, 0
for b in atoms2:
dx, dy = a.x - b.x, a.y - b.y
distance = math.hypot(dx, dy)
if 0 < distance < 50:
force = g / distance
fx += force * dx
fy += force * dy
a.apply_force(fx, fy)
a.update_position()
yellow = create_atoms(50, "yellow")
red = create_atoms(50, "red")
green = create_atoms(50, "green")
all_atoms = yellow + red + green
fig, ax = plt.subplots()
ax.set_xlim(0, window_size)
ax.set_ylim(0, window_size)
ax.set_facecolor('black')
def update():
ax.clear()
ax.set_xlim(0, window_size)
ax.set_ylim(0, window_size)
ax.set_facecolor('black')
apply_rule(green, green, -0.32);
apply_rule(green, red, -0.17);
apply_rule(green, yellow, 0.34);
apply_rule(red, red, -0.1);
apply_rule(red, green, -0.34);
apply_rule(yellow, yellow, 0.15);
apply_rule(yellow, green, -0.2);

for atom in all_atoms:
    draw(ax, atom)

plt.pause(0.01)

while(True):
update()
plt.draw()
plt.close()`

Finally my restless python demons shall let me rest \\_(*W*)_//
On Thu, Aug 29, 2024 at 7:26 PM Hunar Ahmad @.***>
wrote:

Here is a pythonic version, I asked ChatGPT to modify the Python code so
that the pythonic community are happy :)
`import matplotlib.pyplot as plt
import random
import math
window_size = 200
class Atom:
def init(self, x, y, color):
self.x = x
self.y = y
self.vx = 0
self.vy = 0
self.color = color
def update_position(self):
self.x = min(max(self.x + self.vx, 0), window_size)
self.y = min(max(self.y + self.vy, 0), window_size)
self.vx *= -1 if self.x in {0, window_size} else 1
self.vy *= -1 if self.y in {0, window_size} else 1
def apply_force(self, fx, fy):
self.vx = (self.vx + fx) * 0.5
self.vy = (self.vy + fy) * 0.5
def draw(ax, atom, size=3):
ax.plot(atom.x, atom.y, 'o', color=atom.color, markersize=size)
def random_position():
return random.uniform(1, window_size)
def create_atoms(number, color):
return [Atom(random_position(), random_position(), color) for _ in
range(number)]
def apply_rule(atoms1, atoms2, g):
for a in atoms1:
fx, fy = 0, 0
for b in atoms2:
dx, dy = a.x - b.x, a.y - b.y
distance = math.hypot(dx, dy)
if 0 < distance < 50:
force = g / distance
fx += force * dx
fy += force * dy
a.apply_force(fx, fy)
a.update_position()
yellow = create_atoms(50, "yellow")
red = create_atoms(50, "red")
green = create_atoms(50, "green")
all_atoms = yellow + red + green
fig, ax = plt.subplots()
ax.set_xlim(0, window_size)
ax.set_ylim(0, window_size)
ax.set_facecolor('black')
def update():
ax.clear()
ax.set_xlim(0, window_size)
ax.set_ylim(0, window_size)
ax.set_facecolor('black')
apply_rule(green, green, -0.32);
apply_rule(green, red, -0.17);
apply_rule(green, yellow, 0.34);
apply_rule(red, red, -0.1);
apply_rule(red, green, -0.34);
apply_rule(yellow, yellow, 0.15);
apply_rule(yellow, green, -0.2);
for atom in all_atoms:
draw(ax, atom)
plt.pause(0.01)
while(True):
update()
plt.draw()
plt.close()`
—
Reply to this email directly, view it on GitHub
https://github.com/hunar4321/particle-life/issues/90#issuecomment-2318294373,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AOUNPJYPJ23D6YDVPN7J6FLZT5DTNAVCNFSM6AAAAAAX6KUYNWVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMJYGI4TIMZXGM
.
You are receiving this because you were mentioned.Message ID:
@.***>


Fix flaky common.sh

This is related to the previously raised PR
CC: @SamYuan1990 @rootfs

Looks good, but let't try to use sed instead of gsed....

AFAIK the sed -i -e command creates <filename>.<extension>-e files when run on MacOS. This creates an issue when we are modifying the kube-prometheus manifests. Currently it creates yaml with -e at the end and kubectl throws error as it tries to create duplicate manifests i.e one with <name>.yaml and other with <name>.yaml-e.


Deprecate app services

Replaces #2963.

8.18.2 or later

8.18.2 or later

@GulamY @joostverhoog are app services deprecated/removed from support for 8.18.2?

After careful consideration, we ended up deciding that the level of support for app services (deprecated) will not change. So this pull request can be closed.

@MarkvanMents see above - app services remain deprecated in Mx8, so the Dev Portal page will stay for the foreseeable future.


Bundler still mad about todo

This seems to be more or less a reincarnation of this prior issue. This time around bundle chokes on two configurations. When rendered in the gemspec they look like this --
  spec.metadata["source_code_uri"] = "to-do: Put your gem's public repo URL here."
  spec.metadata["changelog_uri"] = "to-do: Put your gem's CHANGELOG.md URL here."

Reproduction steps for creating an offending gemspec can be found at step 13 of this issue.
The error triggered when attempting to bundle install
The gemspec at /clean_root/bash-taming-magic/bash-taming-magic.gemspec is not valid. Please fix this gemspec.
The validation error was 'metadata['source_code_uri'] has invalid link: "to-do: Put your gem's public repo URL here."'

It appears that bundle is looking for more than the disallowed TODO and FIXME, it's looking to validate these two URIs. I can think of a few possible solutions:

When generating the gemspec, comment out these lines by convention. Users would need to uncomment these lines when they wanted to publish the gem.
Expose a new flag to the bootstrap CLI to allow users to indicate their intent to publish their CLI tool as a gem. I haven't yet come up with a flag name that encapsulates that idea. There are probably a few slightly different possible interfaces there.
I don't think this makes much sense but these lines could be removed from the gemspec.

Closing in favor of #137 that captures the poor state of the scaffold
FWIW, I think commenting this stuff out is probably the right call. I hate that bundler does this.


Fix issue with old value for settings crashing app

Automated message from Dropbox CLA bot
@borisyankov, it looks like you've already signed the Dropbox CLA. Thanks!


Information

How can I check if the connection is successful?
the console does not give me information if it has been connected or not.
This query comes to me why I have the suspicion that this line has exchanged the slash_ids with the channel_ids? because when printing that value it indicates the slash_ids.
channelid = m['channel_id']
if int(channelid) not in mhids:

You can turn the discum log to true and then it will print all the Gateway stuff


MetadataChangeEvent Instance to Avro Question

I am working on publishing MCE event. I came up with this MCE event
MetadataChangeEvent metadataChangeEvent = new MetadataChangeEvent();
CorpUserSnapshot corpUserSnapshot = new CorpUserSnapshot();
CorpUserAspectArray corpUserAspectArray = new CorpUserAspectArray();
    for(CorpUserInfo corpUserInfo: corpUserInfoList) {
      try {
        corpUserSnapshot.setUrn(CorpuserUrn.createFromString("urn:li:corpuser:" + corpUserInfo.getAccountName()));
      } catch (URISyntaxException e) {
        e.printStackTrace();
      }
      CorpUserAspect corpUserAspect = new CorpUserAspect();
      corpUserAspect.setCorpUserInfo(corpUserInfo);
      corpUserAspectArray.add(corpUserAspect);
    }

 corpUserSnapshot.setAspects(corpUserAspectArray);

metadataChangeEvent.setProposedSnapshot(Snapshot.create(corpUserSnapshot));
metadataChangeEvent.setAuditHeader(new KafkaAuditHeader());
metadataChangeEvent.setProposedDelta(new Delta());

GenericRecord genericMCERecord = EventUtils.pegasusToAvroMCE(metadataChangeEvent);

then I received this error
MetadataChangeEvent: Exception  - [com.linkedin.data.avro.DataTranslator.dataTranslationException(DataTranslator.java:224), com.linkedin.data.avro.DataTranslator.dataMapToGenericRecord(DataTranslator.java:109), com.linkedin.data.avro.DataTranslator.dataMapToGenericRecord(DataTranslator.java:130), com.linkedin.metadata.EventUtils.pegasusToAvroMCE(EventUtils.java:127), com.linkedin.metadata.kafka.MetadataChangeEventsProcessor.sendCorpUserMCEs(MetadataChangeEventsProcessor.java:121), com.linkedin.metadata.kafka.MceConsumerApplication.main(MceConsumerApplication.java:59)]

If I look at the metadataevent, it prints out
{proposedSnapshot={com.linkedin.metadata.snapshot.CorpUserSnapshot={urn=urn:li:corpuser:abc, aspects=[{com.linkedin.identity.CorpUserInfo={departmentName=DSD, firstName=John, lastName=Doe, accountName=johnd, displayName=John Doe, title=CEO, managerUrn=urn:li:corpuser:chair<EMAIL_ADDRESS>proposedDelta={}, auditHeader={}}

What did I do wrong?

Hi @liangjun-jiang
This is a common error of schema mismatch while converting your data modeled in Pegasus to Avro. Unfortunately, the library doesn't quite help to locate where exactly the mismatch.
That being said, most of the time, you get this when you forgot to set a required field in your model. active is a required field of CorpUserInfo model.
active: boolean

Seems like you're not setting it.

Thanks, @keremsahin1 . I helped a lot. I put a try-catch around
try {
GenericRecord genericMCERecord = EventUtils.pegasusToAvroMCE(metadataChangeEvent);
} catch (IOException e) {
 System.out.println(e.getLocalizedMessage())
}

It helped me trace where it went wrong.
first of all, active is required in CorpUserInfo
Secondly, those two lines also give me problem
metadataChangeEvent.setAuditHeader(new KafkaAuditHeader());
metadataChangeEvent.setProposedDelta(new Delta());

I can't ignore to set them. If I do set, KafkaAuditHeader and Delta need to have full information to make them working.

Hi, @liangjun-jiang
Since both KafkaAuditHeader  and Delta are optional filed in the MetadataChangeEvent, you may consider to set them as null?

@RealChrisL , it won't pass the not-null check for GenericRecord if we explicitly set them to null.
for example, if we do
metadataChangeEvent.setAuditHeader(null);
metadataChangeEvent.setProposedDelta(null);

We will receive an error.
If we don't set them at all, the default ones seem null.


feat(keep-sorted): support destructuring assignment

Description

Linked Issues
Additional context

@hyoban did you have this enabled? https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/allowing-changes-to-a-pull-request-branch-created-from-a-fork
I again I can't push to your branch


Loading the in-memory loaded saved model

Hi all,
Can someone tell me a way to load an in-memory loaded tensorflow model (a protobuf file) into Tensorflow?
For example, the current code I have is as follows:
model_path = 'path/to/the/model/'
session = tf.Session(graph=tf.Graph())
tf.saved_model.loader.load(session, ['serve'], model_path)

However, instead of loading the model by providing its path, I would like to load a model by providing a bytebuffer of the loaded model file.
Can anyone tell me how I can do this? Thanks!

@harshithdwivedi, Please find the doc for Tensorflow save and load model. Thanks!

I can't find the answer to my issue in the doc that you linked @gadagashwini

@harshithdwivedi What version of tensorflow are you using?

In 1.x we have import_graph_def: https://www.tensorflow.org/versions/r1.15/api_docs/python/tf/graph_util/import_graph_def
That doesn't work with variables, since we don't put variable values in protobufs. (Although you could load the variables yourself.)
In 2.x I'd just keep the SavedModel on an in-memory filesystem and use the file-based APIs.

Hi @allenlavoie , that sounds like a good idea.
Can you point me towards any docs or code examples that let load the an in-memory model in 2.x?
Thanks again!

I think /run/shm/ is in-memory on most Linux systems. This works on my machine:
import tensorflow as tf

path = "/run/shm/saved_model/"

m = tf.Module()
m.v = tf.Variable(1.)
tf.saved_model.save(m, path)

imported = tf.saved_model.load(path)
assert imported.v == 1.

But on any operating system you should be able to configure one somehow, and once you do that you can just feed the path to TensorFlow.

This is great, thanks!


Turnstile update

Update Turnstile so that this example fulfills the following purposes:

ontology overlay exemplar
CDR usage exemplar
instance data exemplar
an exemplar ingestion package with a Load-TurnstileData.sh script

Following the other overlay naming conventions, create a GE-Ontology directory with the turnstile overlay, and create a separate directory with the turnstile instance data.
This update will be piecemeal. In the meantime, the original Turnstile-Ontology will be preserved until the example is fully migrated.
Related issues: #224, #440, #457

Issue #457 may also be relevant - please take a look.

Issue #480 may also be relevant - please take a look.

Also addresses #487 - the new URI for the Turnstile example will be http://arcos.turnstile/GE.

See also #506, which might be relevant.

See also #556


winreg module is missing in linux

I have a python 3.6.12 installed in linux and when I import mph in python, I get this error.
ModuleNotFoundError: No module named 'winreg'

Linux, or any operating system other than Windows, is currently not supported by MPh. See chapter "Limitations" in the documentation.

Linux, or any operating system other than Windows, is currently not supported by MPh. See chapter "Limitations" in the documentation.

Exactly, I found a solution for that and its fake winreg library in python.
Best regards,
Ebrahim
On Jan 11, 2021, at 5:14 PM, John Hennig<EMAIL_ADDRESS>wrote:

Linux, or any operating system other than Windows, is currently not supported by MPh. See chapter "Limitations" in the documentationhttps://mph.readthedocs.io/en/latest/limitations.html.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHubhttps://github.com/John-Hennig/MPh/issues/6#issuecomment-758058448, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AKXVAHBSLZJWXQKXPNQIWWDSZMPULANCNFSM4V5XD7WQ.

Exactly, I found a solution for that and its fake winreg library in python.
Best regards,
Ebrahim
On Jan 11, 2021, at 5:14 PM, John Hennig<EMAIL_ADDRESS>wrote:

Linux, or any operating system other than Windows, is currently not supported by MPh. See chapter "Limitations" in the documentationhttps://mph.readthedocs.io/en/latest/limitations.html.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHubhttps://github.com/John-Hennig/MPh/issues/6#issuecomment-758058448, or unsubscribehttps://github.com/notifications/unsubscribe-auth/AKXVAHBSLZJWXQKXPNQIWWDSZMPULANCNFSM4V5XD7WQ.

Exactly, I found a solution for that and its fake winreg library in python.
Best regards,
Ebrahim
--
Ebrahim Norouzi
M.Sc. Materials Science and Simulation
Interdisciplinary Center for Advanced Materials Simulation (ICAMS)
Ruhr-University Bochum
44780 Bochum
Germany
Tel. +49 157 87 975458
Email<EMAIL_ADDRESS>
On Jan 11, 2021, at 5:14 PM, John Hennig<EMAIL_ADDRESS>wrote:

Linux, or any operating system other than Windows, is currently not supported by MPh. See chapter "Limitations" in the documentation.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Exactly, I found a solution for that and its fake winreg library in python.
Best regards,
Ebrahim
--
Ebrahim Norouzi
M.Sc. Materials Science and Simulation
Interdisciplinary Center for Advanced Materials Simulation (ICAMS)
Ruhr-University Bochum
44780 Bochum
Germany
Tel. +49 157 87 975458
Email<EMAIL_ADDRESS>
On Jan 11, 2021, at 5:14 PM, John Hennig<EMAIL_ADDRESS>wrote:

Linux, or any operating system other than Windows, is currently not supported by MPh. See chapter "Limitations" in the documentation.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Hello Ebrahim,
It's not enough to "fake" the WinReg library. The only reason it is loaded is to locate the Comsol installation, based on the information the Comsol installer has left in the Windows Registry. This only helps on Windows though. On Linux, you will find that you cannot start the Comsol client, even if you "successfully" loaded MPh.
On Linux, that mechanism (to locate the Comsol installation and start the "client") has to be replaced by something else instead. WinReg would not even be loaded then. See this pull request (contributed by Jacob Feder) — especially the diff on the first commit, where importing winreg is skipped in case the import fails.
To elaborate a little further, that pull request only covers client–server connections on Linux, i.e., the use case where you would start an independent Comsol server and then, in a different Python session, a client that connects to that very server.
In an effort to achieve full Linux compatibility, I've been trying to get stand-alone Comsol clients to work. Then one could script Comsol in a single Python session and would not have to worry about the server instance. After all, that's the most common use case — at least as far as I'm concerned. However, I still haven't quite figured that out yet. Though I have uploaded a test script, test_client, to demonstrate the (unresolved) issue with that.
Best,
John

Hello Ebrahim,
It's not enough to "fake" the WinReg library. The only reason it is loaded is to locate the Comsol installation, based on the information the Comsol installer has left in the Windows Registry. This only helps on Windows though. On Linux, you will find that you cannot start the Comsol client, even if you "successfully" loaded MPh.
On Linux, that mechanism (to locate the Comsol installation and start the "client") has to be replaced by something else instead. WinReg would not even be loaded then. See this pull request (contributed by Jacob Feder) — especially the diff on the first commit, where importing winreg is skipped in case the import fails.
To elaborate a little further, that pull request only covers client–server connections on Linux, i.e., the use case where you would start an independent Comsol server and then, in a different Python session, a client that connects to that very server.
In an effort to achieve full Linux compatibility, I've been trying to get stand-alone Comsol clients to work. Then one could script Comsol in a single Python session and would not have to worry about the server instance. After all, that's the most common use case — at least as far as I'm concerned. However, I still haven't quite figured that out yet. Though I have uploaded a test script, test_client, to demonstrate the (unresolved) issue with that.
Best,
John

Hi John,
Thank you for your explanation. That is helpful. I have one question. Is it possible to do more things in python, for instance create a model or geometry, something like complete power of java? What are the difficulties?
I am materials scientists and really need that for my project but do not know about the possibility of developing python api for comsol. Do you have any references and suggestions for me?
Best regards,
Ebrahim
--
Ebrahim Norouzi
M.Sc. Materials Science and Simulation
Interdisciplinary Center for Advanced Materials Simulation (ICAMS)
Ruhr-University Bochum
44780 Bochum
Germany
Tel. +49 157 87 975458
Email<EMAIL_ADDRESS>
On Jan 11, 2021, at 8:06 PM, John Hennig<EMAIL_ADDRESS>wrote:

Hello Ebrahim,
It's not enough to "fake" the WinReg library. The only reason it is loaded is to locate the Comsol installation, based on the information the Comsol installer has left in the Windows Registry. This only helps on Windows though. On Linux, you will find that you cannot start the Comsol client, even if you "successfully" loaded MPh.
On Linux, that mechanism (to locate the Comsol installation and start the "client") has to be replaced by something else instead. WinReg would not even be loaded then. See this pull request (contributed by Jacob Feder) — especially the diff on the first commit, where importing winreg is skipped in case the import fails.
To elaborate a little further, that pull request only covers client–server connections on Linux, i.e., the use case where you would start an independent Comsol server and then, in a different Python session, a client that connects to that very server.
In an effort to achieve full Linux compatibility, I've been trying to get stand-alone Comsol clients to work. Then one could script Comsol in a single Python session and would not have to worry about the server instance. After all, that's the most common use case — at least as far as I'm concerned. However, I still haven't quite figured that out yet. Though I have uploaded a test script, test_client, to demonstrate the (unresolved) issue with that.
Best,
John
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Hi John,
Thank you for your explanation. That is helpful. I have one question. Is it possible to do more things in python, for instance create a model or geometry, something like complete power of java? What are the difficulties?
I am materials scientists and really need that for my project but do not know about the possibility of developing python api for comsol. Do you have any references and suggestions for me?
Best regards,
Ebrahim
--
Ebrahim Norouzi
M.Sc. Materials Science and Simulation
Interdisciplinary Center for Advanced Materials Simulation (ICAMS)
Ruhr-University Bochum
44780 Bochum
Germany
Tel. +49 157 87 975458
Email<EMAIL_ADDRESS>
On Jan 11, 2021, at 8:06 PM, John Hennig<EMAIL_ADDRESS>wrote:

Hello Ebrahim,
It's not enough to "fake" the WinReg library. The only reason it is loaded is to locate the Comsol installation, based on the information the Comsol installer has left in the Windows Registry. This only helps on Windows though. On Linux, you will find that you cannot start the Comsol client, even if you "successfully" loaded MPh.
On Linux, that mechanism (to locate the Comsol installation and start the "client") has to be replaced by something else instead. WinReg would not even be loaded then. See this pull request (contributed by Jacob Feder) — especially the diff on the first commit, where importing winreg is skipped in case the import fails.
To elaborate a little further, that pull request only covers client–server connections on Linux, i.e., the use case where you would start an independent Comsol server and then, in a different Python session, a client that connects to that very server.
In an effort to achieve full Linux compatibility, I've been trying to get stand-alone Comsol clients to work. Then one could script Comsol in a single Python session and would not have to worry about the server instance. After all, that's the most common use case — at least as far as I'm concerned. However, I still haven't quite figured that out yet. Though I have uploaded a test script, test_client, to demonstrate the (unresolved) issue with that.
Best,
John
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or unsubscribe.

Short answer: yes.
All of these things — "create a model or geometry, something like complete power of java" — are possible. Not so much because of MPh itself, but rather because of JPype — the Python-to-Java bridge that MPh is built on. (All credit to Thrameos and the other contributors to JPype.)
I did mention that in the documentation, if only in passing. It is not the primary focus of MPh to do these things. The primary focus is: Take an existing model (i.e., not create it in code, but rather set it up in the Comsol GUI) and then solve it. Usually, after changing parameter values and/or to implement some customized, Python-power post-processing. (Otherwise you might just click solve on the appropriate study node in the Comsol GUI.)
But, nevertheless, it is possible to do all of these things in code. Take this Comsol blog entry as an example: Automate Your Modeling Tasks with the COMSOL API for use with Java®. It starts with this Java code example:
import com.comsol.model.*;
import com.comsol.model.util.*;

public class HelloWorld {

   public static void main(String[] args) {
      run();
   }
   public static Model run() {
      Model model = ModelUtil.create("Model");
      model.modelNode().create("comp1");
      model.geom().create("geom1", 3);
      model.geom("geom1").feature().create("blk1", "Block");
      model.geom("geom1").feature("blk1").set("size", new String[]{"0.1", "0.2", "0.5"});
      model.geom("geom1").run("fin");
      return model;
   }
}

What it does is, it creates a model, which contains a 3d geometry component, which is just a block that is 0.1 by 0.2 by 0.5 meters in size.
You can do the same thing using MPh. Again, that's not the primary purpose, but it works. So in Python, with only MPh (and Comsol) installed, you would do this:
import mph

client = mph.Client()
pymodel = client.create('model')
model = pymodel.java

model.modelNode().create("comp1");
model.geom().create("geom1", 3);
model.geom("geom1").feature().create("blk1", "Block");
model.geom("geom1").feature("blk1").set("size", ["0.1", "0.2", "0.5"]);
model.geom("geom1").run("fin");

Note how I copy-and-pasted most of the (functional) Java code — even the semicolons, which Python simply ignores. I had to replace new String[]{"0.1", "0.2", "0.5"}. That's because Python does not know what new means. But there, Java expects a list of three strings. So I replaced that with ["0.1", "0.2", "0.5"] — which is the Python equivalent of just that: a list of these three strings.
Occasionally, when translating Java (or Matlab) code you find in the documentation — or a blog entry, as was the case here —, you will have to amend code lines such as the one above. But they are few and far between. And the error message you'd receive should at least point you in the right direction.
The upside is:

You don't really need to know Java. I know embarrassingly little. A bit more than what it takes to fix the code example above, but not much more.
You don't need to install Java. It just ships with Comsol. You also don't need to worry about "compiling" Java source code to Java "classes" (via comsolcompile).
You can use Python "introspection" to understand how Comsol models are "created in code". This may be the most productive feature. The Comsol documentation explains a lot of things, but not every little thing. I used the mph.inspect() function a lot in development.

Finally, to save the model created in the above example, we can just do this in Python:
pymodel.save('model')

This stored a file named model.mph in the working directory, which you can then open in the Comsol GUI. Or use in any other (Python/Java/Matlab) script, as you please.

Short answer: yes.
All of these things — "create a model or geometry, something like complete power of java" — are possible. Not so much because of MPh itself, but rather because of JPype — the Python-to-Java bridge that MPh is built on. (All credit to Thrameos and the other contributors to JPype.)
I did mention that in the documentation, if only in passing. It is not the primary focus of MPh to do these things. The primary focus is: Take an existing model (i.e., not create it in code, but rather set it up in the Comsol GUI) and then solve it. Usually, after changing parameter values and/or to implement some customized, Python-power post-processing. (Otherwise you might just click solve on the appropriate study node in the Comsol GUI.)
But, nevertheless, it is possible to do all of these things in code. Take this Comsol blog entry as an example: Automate Your Modeling Tasks with the COMSOL API for use with Java®. It starts with this Java code example:
import com.comsol.model.*;
import com.comsol.model.util.*;

public class HelloWorld {

   public static void main(String[] args) {
      run();
   }
   public static Model run() {
      Model model = ModelUtil.create("Model");
      model.modelNode().create("comp1");
      model.geom().create("geom1", 3);
      model.geom("geom1").feature().create("blk1", "Block");
      model.geom("geom1").feature("blk1").set("size", new String[]{"0.1", "0.2", "0.5"});
      model.geom("geom1").run("fin");
      return model;
   }
}

What it does is, it creates a model, which contains a 3d geometry component, which is just a block that is 0.1 by 0.2 by 0.5 meters in size.
You can do the same thing using MPh. Again, that's not the primary purpose, but it works. So in Python, with only MPh (and Comsol) installed, you would do this:
import mph

client = mph.Client()
pymodel = client.create('model')
model = pymodel.java

model.modelNode().create("comp1");
model.geom().create("geom1", 3);
model.geom("geom1").feature().create("blk1", "Block");
model.geom("geom1").feature("blk1").set("size", ["0.1", "0.2", "0.5"]);
model.geom("geom1").run("fin");

Note how I copy-and-pasted most of the (functional) Java code — even the semicolons, which Python simply ignores. I had to replace new String[]{"0.1", "0.2", "0.5"}. That's because Python does not know what new means. But there, Java expects a list of three strings. So I replaced that with ["0.1", "0.2", "0.5"] — which is the Python equivalent of just that: a list of these three strings.
Occasionally, when translating Java (or Matlab) code you find in the documentation — or a blog entry, as was the case here —, you will have to amend code lines such as the one above. But they are few and far between. And the error message you'd receive should at least point you in the right direction.
The upside is:

You don't really need to know Java. I know embarrassingly little. A bit more than what it takes to fix the code example above, but not much more.
You don't need to install Java. It just ships with Comsol. You also don't need to worry about "compiling" Java source code to Java "classes" (via comsolcompile).
You can use Python "introspection" to understand how Comsol models are "created in code". This may be the most productive feature. The Comsol documentation explains a lot of things, but not every little thing. I used the mph.inspect() function a lot in development.

Finally, to save the model created in the above example, we can just do this in Python:
pymodel.save('model')

This stored a file named model.mph in the working directory, which you can then open in the Comsol GUI. Or use in any other (Python/Java/Matlab) script, as you please.

Thank you for your nice suggestions.
I run mph in Linux and want to further develop the model as you said but faced one error:
pymodel = client.create('model')
Traceback (most recent call last):
File "SourceFile", line 90, in com.comsol.model.util.ModelUtil.createUnique
File "SourceFile", line 83, in com.comsol.model.util.ModelUtil.create
File "SourceFile", line 42, in com.comsol.model.util.ServerModelUtil.create
File "SourceFile", line 636, in com.comsol.nativeutil.d.b.l
File "SourceFile", line 22, in com.comsol.nativeutil.d.c.
File "SourceFile", line 157, in com.comsol.nativejni.util.FlLicense.getInstance
File "SourceFile", line 71, in com.comsol.nativejni.util.FlLicense.
File "SourceFile", line -2, in com.comsol.nativejni.util.FlLicense.initWS0
Exception: Java Exception
The above exception was the direct cause of the following exception:
pymodel = client.create('model')
Traceback (most recent call last):
File "SourceFile", line 90, in com.comsol.model.util.ModelUtil.createUnique
File "SourceFile", line 83, in com.comsol.model.util.ModelUtil.create
File "SourceFile", line 42, in com.comsol.model.util.ServerModelUtil.create
File "SourceFile", line 636, in com.comsol.nativeutil.d.b.l
File "SourceFile", line 22, in com.comsol.nativeutil.d.c.
File "SourceFile", line 157, in com.comsol.nativejni.util.FlLicense.getInstance
File "SourceFile", line 71, in com.comsol.nativejni.util.FlLicense.
File "SourceFile", line -2, in com.comsol.nativejni.util.FlLicense.initWS0
Exception: Java Exception
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "", line 1, in
File "/home/IWM/runs/pydev/py36-venv/lib64/python3.6/site-packages/mph/client.py", line 183, in create
java = self.java.createUnique('model')
mph.client.UnsatisfiedLinkError: java.lang.UnsatisfiedLinkError: com.comsol.nativejni.util.FlLicense.initWS0(Lcom/comsol/nativejni/CPointer;)V
I also have the same error by loading the .mph file. How should I use mph.inspect() to get a clue about this kind of error?

Thank you for your nice suggestions.
I run mph in Linux and want to further develop the model as you said but faced one error:
pymodel = client.create('model')
Traceback (most recent call last):
File "SourceFile", line 90, in com.comsol.model.util.ModelUtil.createUnique
File "SourceFile", line 83, in com.comsol.model.util.ModelUtil.create
File "SourceFile", line 42, in com.comsol.model.util.ServerModelUtil.create
File "SourceFile", line 636, in com.comsol.nativeutil.d.b.l
File "SourceFile", line 22, in com.comsol.nativeutil.d.c.
File "SourceFile", line 157, in com.comsol.nativejni.util.FlLicense.getInstance
File "SourceFile", line 71, in com.comsol.nativejni.util.FlLicense.
File "SourceFile", line -2, in com.comsol.nativejni.util.FlLicense.initWS0
Exception: Java Exception
The above exception was the direct cause of the following exception:
pymodel = client.create('model')
Traceback (most recent call last):
File "SourceFile", line 90, in com.comsol.model.util.ModelUtil.createUnique
File "SourceFile", line 83, in com.comsol.model.util.ModelUtil.create
File "SourceFile", line 42, in com.comsol.model.util.ServerModelUtil.create
File "SourceFile", line 636, in com.comsol.nativeutil.d.b.l
File "SourceFile", line 22, in com.comsol.nativeutil.d.c.
File "SourceFile", line 157, in com.comsol.nativejni.util.FlLicense.getInstance
File "SourceFile", line 71, in com.comsol.nativejni.util.FlLicense.
File "SourceFile", line -2, in com.comsol.nativejni.util.FlLicense.initWS0
Exception: Java Exception
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
File "", line 1, in
File "/home/IWM/runs/pydev/py36-venv/lib64/python3.6/site-packages/mph/client.py", line 183, in create
java = self.java.createUnique('model')
mph.client.UnsatisfiedLinkError: java.lang.UnsatisfiedLinkError: com.comsol.nativejni.util.FlLicense.initWS0(Lcom/comsol/nativejni/CPointer;)V
I also have the same error by loading the .mph file. How should I use mph.inspect() to get a clue about this kind of error?

As expected. This is why Linux is not supported. I haven't quite figured out why this happens. It's something to do with the external shared libraries that aren't correctly loaded. See my earlier comment and the test script that I mentioned. The doc-string at the top of the test script also hints at a possible work-around. Though, again, I will not claim Linux support until this issue is resolved in a robust way, which it currently isn't. Unfortunately.

As expected. This is why Linux is not supported. I haven't quite figured out why this happens. It's something to do with the external shared libraries that aren't correctly loaded. See my earlier comment and the test script that I mentioned. The doc-string at the top of the test script also hints at a possible work-around. Though, again, I will not claim Linux support until this issue is resolved in a robust way, which it currently isn't. Unfortunately.

I asked a user that has windows to test this for me and when the line "java.initStandalone(False)" is commented out, the exact error appears as I mentioned in my previous comment. I thought this may give some hints. But I tried many options like using graphic standalone and they are not working.
Also using server connection is not working with this command: "java.connect('localhost', port=2036)".

I asked a user that has windows to test this for me and when the line "java.initStandalone(False)" is commented out, the exact error appears as I mentioned in my previous comment. I thought this may give some hints. But I tried many options like using graphic standalone and they are not working.
Also using server connection is not working with this command: "java.connect('localhost', port=2036)".

So the solution is to add server before adding client.
import mph
server = mph.Server(cores=1)
print(f'Server listing on port {server.port}.')
client = mph.Client(cores=1, port = 2036)
pymodel = client.create('model')
model = pymodel.java
and so on ...

So the solution is to add server before adding client.
import mph
server = mph.Server(cores=1)
print(f'Server listing on port {server.port}.')
client = mph.Client(cores=1, port = 2036)
pymodel = client.create('model')
model = pymodel.java
and so on ...

Sorry, I just confused about converting codes from python to java. For instance for this java code:
public class Hello_world {
public static Model run1() {
}
public static Model run2(Model model) {
}
public static void main(String[] args) {
Model model = run1();
run2(model);
}
}
Is this a proper python code?
Is it possible to name Hello_world, run, run2 in python for better interpretation?
Where do we have to define "model = run()" an "run2(model)"?
pymodel_1 = client.create('model_run1')
model_1 = pymodel_1.java
pymodel_2 = client.create('model_run2')
model_2 = pymodel_2.java

Sorry, I just confused about converting codes from python to java. For instance for this java code:
public class Hello_world {
public static Model run1() {
}
public static Model run2(Model model) {
}
public static void main(String[] args) {
Model model = run1();
run2(model);
}
}
Is this a proper python code?
Is it possible to name Hello_world, run, run2 in python for better interpretation?
Where do we have to define "model = run()" an "run2(model)"?
pymodel_1 = client.create('model_run1')
model_1 = pymodel_1.java
pymodel_2 = client.create('model_run2')
model_2 = pymodel_2.java

I guess this is Java code that was originally auto-generated by Comsol and then edited down? I don't know why Comsol's code generator splits up the run() method. (Note how all the code acts on the same model object, not two different ones.) But it's not necessary to do that, not even in Java. This could all be one method, even just main().
In Python, you don't need any methods/functions. Not even the class definition, which is mandatory in Java. So I would omit all of that, unless there is a good reason to structure the code. I would create the model once, same way as in the earlier example, and then copy all the "functional" lines of Java code, from whichever of those methods. By "functional" I mean lines of code that modify the model object, i.e. create or change features — geometry, mesh, physics, solver, plots, exports, etc.

I guess this is Java code that was originally auto-generated by Comsol and then edited down? I don't know why Comsol's code generator splits up the run() method. (Note how all the code acts on the same model object, not two different ones.) But it's not necessary to do that, not even in Java. This could all be one method, even just main().
In Python, you don't need any methods/functions. Not even the class definition, which is mandatory in Java. So I would omit all of that, unless there is a good reason to structure the code. I would create the model once, same way as in the earlier example, and then copy all the "functional" lines of Java code, from whichever of those methods. By "functional" I mean lines of code that modify the model object, i.e. create or change features — geometry, mesh, physics, solver, plots, exports, etc.

Support for Linux was added in version 0.8.0, released today. See the updated documentation as well as issue #8. The winreg module is thus no longer imported unconditionally, only on Windows.


Proof of Concept: read locations, parameters and timeseries from databricks

Ultimate goal is to be able to read from Azure as a source for the WIK hydrodashboards app.
With this issue we purely test performance with a basic POC bokeh dashboard

Some nice to haves:

[ ] SQL statement for getting the header of a databricks table, as we won't be able to construct it if the List[Row] result gives an empty list


provenance of recipe_multimodel_products.yml broken

Same error as in #1705 and #1711:
Traceback (most recent call last):
  File "/mnt/lustre02/work/bd0080/b309057/SOFTWARE/miniconda3/envs/esmvaltool/lib/python3.8/multiprocessing/pool.py", line 125, in worker
    result = (True, func(*args, **kwds))
  File "/mnt/lustre01/pf/b/b309057/ESMValTool/core/esmvalcore/_task.py", line 723, in _run_task
    output_files = task.run()
  File "/mnt/lustre01/pf/b/b309057/ESMValTool/core/esmvalcore/_task.py", line 242, in run
    self.output_files = self._run(input_files)
  File "/mnt/lustre01/pf/b/b309057/ESMValTool/core/esmvalcore/_task.py", line 520, in _run
    self._collect_provenance()
  File "/mnt/lustre01/pf/b/b309057/ESMValTool/core/esmvalcore/_task.py", line 583, in _collect_provenance
    if ancestor_file in ancestor_products:
TypeError: unhashable type: 'list'

Hi @jvegasbsc could you help me? Thanks in advance!


change text from "fromt" to "from" in OCR screen

Related Issuse or bug

Info about Issue or bug

Fixes: #[issue number that will be closed through this PR]
Describe the changes you've made
A clear and concise description of what you have done to successfully close your assigned issue. Any new files? or anything you feel to let us know!
Fill in the form: https://forms.gle/uTfMxj8282nzwPck8
Type of change
Please delete options that are not relevant.

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

How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce.
Describe if there is any unusual behaviour of your code(Write NA if there isn't)
A clear and concise description of it.
Checklist:

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

Screenshots

Original
Updated

original screenshot
updated screenshot

It is always appreciated that you raise an issue for a particular thing before making a PR.


can you add d3d12 example

can you add d3d12 example,thx

hello, we worked on it with a friend, but we will probably not release it actually sorry, maybe later, you can use the imgui sample for the moment


[RedisCache] Allow injection of ConnectionMultiplexer

Currently the RedisCache creates the ConnectionMultiplexer and does not allow access to it. This prevents the application from reusing the ConnectionMultiplexer for other operations like PubSub.
Granted, the application could create another ConnectionMultiplexer, but the recommendation is to have only one per application.
I was thinking if it would be possible to have a separate constructor for RedisCache that would receive the ConnectionMultiplexer. I understand that so far Microsoft.Extensions.Caching.Redis did not leak any implementation details about its usage of StackExchange.Redis. However, I noticed that Microsoft.AspNetCore.DataProtection.Redis leaks StackExchange.Redis types here. So, I'm unclear about how you feel about keeping StackExchange.Redis as an implementation detail.

Just noticed there is an open pull request enabling this scenario. But did not find an issue discussing the proposed change, so I'll keep this one open to discuss it.

Closing https://github.com/aspnet/Caching/pull/318 as it entails to a breaking change. Keeping this bug open for any alternatives or for a potential major release change.

I believe that injecting IConnectionMultiplexer as a dependency is the path to go.
I share @epignosisx concerns about  StackExchange.Redis being a implementation detail or not.
The pragmatic way to address it would be have a service interface and ** StackExchange.Redis ** being used in a adaptor that implements that interface. But that would possibly mean too many levels of generalization though.

@muratg could you share where does the team stand on whether StackExchange.Redis should be kept as an implementation detail or not?
Answering this question is critical to make progress on this issue. As @israellot pointed out the alternatives are more abstractions that probably will be undesirable.

cc @davidfowl

Yes we should allow for this. Not sure about injecting the IConnectionMultiplexer as a dependency though we should have an option that allows setting a Func<IConnectionMultiplexer>

I know the application has created a ConnectionMultiplexer.
Why the application must be create another ConnectionMultiplexer?

FYI this issue is referenced here:
https://stackoverflow.com/questions/49403973/net-core-idistributedcache-redis-sentinel-support-for-master-slave/49931794#49931794

@muratg Any update to this?

Over a year old and nothing new ?

+1
Perhaps a much easier solution would be to allow getting the current Multiplexer? This way Microsoft.Extensions.Caching.Redis would create the Multiplexer instance, and any external code would use the same instance.

@effyteva That would become a problem if other libraries did the same thing - everyone would create their own multiplexer and expect others to use it.


Using svg-url-loader for webpack configs that accept svgs

Issue: #2474
What I did
Added svg-url-loader to make svg imports smaller
How to test
build core, docs, examples
Is this testable with jest or storyshots?
No
Does this need a new example in the kitchen sink apps?
No
Does this need an update to the documentation?
No
If your answer is yes to any of these, please make sure to include it in your PR.

Can someone please check that it works on #3148 branch?

Sure Ill do that in a bit!

@Hypnosphi I can just wait until that one is merged!

@Hypnosphi It worked! :)
except some stuff with webpack 4 that I had to add:
uglifyjs is its own plugin in webpack 4 yarn add -D  uglifyjs-webpack-plugin
webpack command is now in its own cli yarn add -D webpack-cli
But other than that It works.

uglifyjs is its own plugin in webpack 4 yarn add -D uglifyjs-webpack-plugin
Actually, it's used as default optimization.minimizer option in webpack 4, so there's no need to depend on it directly

@Hypnosphi My mistake. I was directly running yarn build in the vue-kitchen-sink directory.
Is there anything else to be done on this PR?

Seems like danger ci has no api token

Looks like it broke image in polymer example: https://deploy-preview-3221--storybooks-polymer.netlify.com/?selectedKind=Welcome&selectedStory=Welcome&full=0&addons=1&stories=1&panelRight=0&addonPanel=storybook%2Fstories%2Fstories-panel

@Hypnosphi seems that noquotes breaks polymer svg imports. But for others it doesnt. So I've removed it


Derek furst/log queries search adaptor

Added query logging to search-adaptor for _search. Applied minimal changes in execute_opensearch_query and execute_query in opensearch_helper.

@DerekFurstPitt I've tested your changes on DEV, we can merge this into main directly after you make the two small tweaks. Then I'll merge this PR so you can make a new PR in search-api to use the latest commit in search-adaptor.


Remove version: NelsonNumericalSoftware.Nelson version <IP_ADDRESS>52

[Automated] It returns code over 400 in all urls
Microsoft Reviewers: Open in CodeFlow

URL: https://github.com/Nelson-numerical-software/nelson/releases/download/v0.5.2/Nelson-<IP_ADDRESS>52-x86-64.exe
Response Error: The remote server returned an error: (404) Not Found.
(Automated message - build 911)


feat(button): add states style

still missing design tokens of colors to match the design

Right!! I've restricted the style when not idle. I don't think we need to target when disabled (as attribute) because it added the class (*-idle) anyway, right?

@rachelbt run npx beachball change to create the change file. it's a none type

decided to control the states via appearance and not as a separated mixin

do we still need libs/shared/src/lib/sass/mixins/_states.scss?


Sub-millisecond component inaccuracy in OffsetDateTime conversion from js_sys::Date

When generating an OffsetDateTime from a js_sys::Date, there are cases where the sub-millisecond components are not set to zero. This behavior is unexpected and can lead to inaccuracies in the resulting OffsetDateTime.
Steps to Reproduce

Use the following code to reproduce the issue:

let millis =<PHONE_NUMBER>579i64; // 2023-11-04T07:45:11.579Z
let js_date = js_sys::Date::new(&JsValue::from_f64(millis as f64));
let datetime = OffsetDateTime::from(js_date);

println!("{}", datetime);
// => 2023-11-04 7:45:11.579000064 +00:00:00

Reason for Considering It a Bug
The precision of js_sys::Date is limited to milliseconds. Therefore, when converting it to an OffsetDateTime, we expect the sub-millisecond components to be set to zero for consistency and accuracy.
Cause
https://github.com/time-rs/time/blob/72f03e05073621f713dead88f16c227187afd6f9/time/src/date_time.rs#L1226-L1233
The issue stems from the conversion process of milliseconds to nanoseconds. It appears that the code converts milliseconds to nanoseconds using f64, and subsequently converts it to i128, which can introduce inaccuracies and prevent sub-millisecond components from being zeroed out.
Proposed Solution
To address this issue, consider converting milliseconds to i128 first and then perform the conversion to nanoseconds. This approach should maintain accuracy and ensure that sub-millisecond components are set to zero.
Additional Information
I encountered this issue while using OffsetDateTime::now_utc() in a WASM environment.

Without even looking into this, I am confident that the multiplication magnifies the inherent error of representing decimal values in floating point numbers. I'm happy to accept your proposed solution as a PR, as I'm sure it'll fix the issue.


⚠ ClamAV has degraded performance

In 1a94719, ClamAV (https://spamassassin.apache.org/) experienced degraded performance:

HTTP code: 200
Response time: 89 ms

Resolved: ClamAV performance has improved in ba16920.


Implementing an Interface with a property in a base class causes internal compiler error

interface IFoo:
   A as int:
      get
   B as int:
      get

class Base:
   A as int:
      get: return 42

class Derived(Base, IFoo):
   B as int:
      get: return 7

Expected: This should work
Observed: Internal compiler error: Failed to create 'MyNamespace.Derived' type. (Error occurs during EmitAssembly step.)

With the CCI backend, I was able to create the invalid assembly that Reflection.Emit kept erroring out on and use ILDasm to compare it to CSC's version and see what the difference was, and then fix it.
I'll close this issue when the CCI backend is merged into Master.


Create unisnu.txt

Institution/School Name
Universitas Islam Nahdlatul Ulama Jepara
Instiution/School Website
https://unisnu.ac.id/
Email Users
Please place an x between the square brackets if yes

[x] Students
[x] Academic/Teaching Staff
[ ] Other/Support Staff
[x] Alumni

Education Levels
Please place an x between the square brackets if yes

[ ] Post-graduate research
[ ] Graduate School
[x] College (University) or Undergraduate School or equivalent
[ ] Community College or equivalent
[ ] High School or equivalent
[ ] Elementary School or equivalent

@abunaum Pull request merged. Thank you!


Accidentially used Encoder instead of Decoder?

Hey there, great project!
I have just one thing that I am not sure if I misunderstood or you did. You wanted to reproduce the architecture of IconShop, but to my understanding, IconShop is a decoder-only transformer (like a language model).
Excerpt from their paper:

I first thought you had a minor mistake in your blog post, but also there you wrote encoder-only:

An encoder-only autoregressive transformer is self-contradictory, isn't it?
Also here, you took the xFormerEncoderConfig instead of the (imo) correct xFormerDecoderConfig.
https://github.com/SerCeMan/fontogen/blob/de1e50b2b42ed17bbfe442949957dd001b5ba80e/model/model.py#L201-L227
I haven't thought this through what the implications are. You correctly used causal attention, so there should not be issues on that front. There might not even be an issue at all, as decoders (without cross-attention) are kinda just encoders with causal attention masking, but I don't know the xformers library and its inner workings. Just wanted to set the mental model straight.
Thanks for releasing your code and project!

Hey, @DerEchteFeuerpfeil! The article should indeed be saying decoder-only. Thank you for this, I'll fix it up!
Implementation-wise, if I understand correctly, there is no other way to implement a decoder-only transformer in xFormers, https://github.com/facebookresearch/xformers/issues/617.

Alright, makes sense! Does not speak for the library that a decoder-only architecture issue is open for >1y 😅
When re-implementing parts of this for my project I used x_transformers by lucidrains instead.
I'll close this issue for now, as it has served its purpose. Cheers!


Panic with "Cannot replace slice of data that was already replaced"

I have a PR to add a new suggestion to rustc: https://github.com/rust-lang/rust/pull/88672. It uses Diagnostic::multipart_suggestions since there are multiple ways for the user to change their code. These multiple suggestions are exclusive since they modify the same code.
However, rustfix is panicking when I use run-rustfix in a test: "Cannot replace slice of data that was already replaced".
The relevant code in my PR is here: https://github.com/rust-lang/rust/blob/6a89e97ab14cd4c6be70b47fd139c87fd90150b7/compiler/rustc_parse/src/parser/diagnostics.rs#L226-L234
and here: https://github.com/rust-lang/rust/blob/6a89e97ab14cd4c6be70b47fd139c87fd90150b7/compiler/rustc_parse/src/parser/diagnostics.rs#L1272-L1277
I'm not sure how to fix this problem in rustfix, but I'm willing to try with some mentoring :)

FWIW, there's some existing code in rustc that references this panic: https://github.com/rust-lang/rust/blob/f103b2969b0088953873dc1ac92eb3387c753596/compiler/rustc_builtin_macros/src/format.rs#L323-L330

Hi @ehuss, thanks for your quick reply! I would have responded sooner but I missed your message :)
The multiple exclusive options actually are not marked as MachineApplicable. They were marked as MaybeIncorrect and then later Unspecified, but I'm still getting the panic. Any idea why this is happening?

If you mean by a UI test, then you'll want to remove the run-rustfix header. That header will apply all suggestions ignoring the applicability.  There's also rustfix-only-machine-applicable, but I don't think that applies to your case (assuming no suggestions are machine-applicable).

Ah, I didn't realize that it applied suggestions indiscriminately! I moved the exclusive suggestions to another test since otherwise the generated .fixed file was invalid. Thanks so much for your help!
Is this panic still considered a bug (and thus I should leave the issue open) or is it considered a sign of something wrong with rustc's output that is thus not a rustfix bug?

I'd leave it open.  Even though these types of suggestions aren't currently supported, it probably shouldn't panic.