[Bugfix / Core] Prefix Caching Guards

Added checks for cases where prefix caching is not supported (due to limitations of context_attention_fwd):

Sliding window
fp8 kv cache

Also added CLI for user to specify that they want to disable sliding window. This enables us to run mistral with prefix caching. Note - we could add onto this PR to disable sliding window if max_len < sliding_window_len
FIX #3880
cc @SageMoore @ElizaWszola @tlrmchlsmth
BEFORE SUBMITTING, PLEASE READ THE CHECKLIST BELOW AND FILL IN THE DESCRIPTION ABOVE

 PR Checklist (Click to Expand)
Thank you for your contribution to vLLM! Before submitting the pull request, please ensure the PR meets the following criteria. This helps vLLM maintain the code quality and improve the efficiency of the review process.
PR Title and Classification
Only specific types of PRs will be reviewed. The PR title is prefixed appropriately to indicate the type of change. Please use one of the following:

[Bugfix] for bug fixes.
[CI/Build] for build or continuous integration improvements.
[Doc] for documentation fixes and improvements.
[Model] for adding a new model or improving an existing model. Model name should appear in the title.
[Frontend] For changes on the vLLM frontend (e.g., OpenAI API server, LLM class, etc.)
[Kernel] for changes affecting CUDA kernels or other compute kernels.
[Core] for changes in the core vLLM logic (e.g., LLMEngine, AsyncLLMEngine, Scheduler, etc.)
[Hardware][Vendor] for hardware-specific changes. Vendor name should appear in the prefix (e.g., [Hardware][AMD]).
[Misc] for PRs that do not fit the above categories. Please use this sparingly.

Note: If the PR spans more than one category, please include all relevant prefixes.
Code Quality
The PR need to meet the following code quality standards:

We adhere to Google Python style guide and Google C++ style guide.
Pass all linter checks. Please use format.sh to format your code.
The code need to be well-documented to ensure future contributors can easily understand the code.
Include sufficient tests to ensure the project to stay correct and robust. This includes both unit tests and integration tests.
Please add documentation to docs/source/ if the PR modifies the user-facing behaviors of vLLM. It helps vLLM user understand and utilize the new features or changes.

Notes for Large Changes
Please keep the changes as concise as possible. For major architectural changes (>500 LOC excluding kernel/data/config/test), we would expect a GitHub issue (RFC) discussing the technical design and justification. Otherwise, we will tag it with rfc-required and might not go through the PR.
What to Expect for the Reviews
The goal of the vLLM team is to be a transparent reviewing machine. We would like to make the review process transparent and efficient and make sure no contributor feel confused or frustrated. However, the vLLM team is small, so we need to prioritize some PRs over others. Here is what you can expect from the review process:

 After the PR is submitted, the PR will be assigned to a reviewer. Every reviewer will pick up the PRs based on their expertise and availability.
 After the PR is assigned, the reviewer will provide status update every 2-3 days. If the PR is not reviewed within 7 days, please feel free to ping the reviewer or the vLLM team.
 After the review, the reviewer will put an  action-required label on the PR if there are changes required. The contributor should address the comments and ping the reviewer to re-review the PR.
 Please respond to all comments within a reasonable time frame. If a comment isn't clear or you disagree with a suggestion, feel free to ask for clarification or discuss the suggestion.

Thank You
 Finally, thank you for taking the time to read these guidelines and for your interest in contributing to vLLM. Your contributions make vLLM a great tool for everyone!

Close this PR since we merged #4846


IBM Provider: Update ESO to use latest v2.0.1 of the secrets manager Go SDK

Is your feature request related to a problem? Please describe.
We have recently added a mechanism to allow IBM Cloud Secrets Manager (SM) users to fetch the secret by name instead of ID as described under https://github.com/external-secrets/external-secrets/issues/2210.
This mechanism is a 2 step process with caching enabled which involves below:
Step 1: Provider calls the list API to filter the given name to find out the corresponding ID
Step 2: Provider calls the get API with the ID to fetch the secret details
This has also been documented under https://external-secrets.io/v0.9.4/provider/ibm-secrets-manager/#getting-the-kubernetes-secret.
A new API has been introduced in IBM Cloud Secrets Manager's Go SDK v2.0.1 which allows the users to fetch the secret by name through a single API call. See the corresponding API documentation for reference. This API is much more efficient than the current 2 step mechanism.
Describe the solution you'd like
We want IBM Cloud Secrets Manager provider to implement this new API in place of the existing process.
The IBM provider currently supports below formats of specifying the value of remoteRef.key in the External Secret definition:

<secret-type>/<secret-id> : to fetch the SM secret by secret ID
<secret-type>/<secret-name> : to fetch the SM secret by secret name (this is the recently added functionality)

The new API requires an additional parameter SecretGroupName referring to the name of the secret group the given secret belongs to.
In order to support the new API, the provider.go needs this input passed in as a part of remoteRef.key.
However, we don't want any breaking changes in case any user is already leveraging the existing way of getting the secret by name. We also want to replace the existing 2-step approach to the new API where the group-name is to be provided.
To tackle this, we are proposing below process to achieve this migration:

Add support:

Add support to specify remoteRef.key in the format <secret-type>/<secret-name>/<secret-group-name>, where the secret-group-name is an optional parameter which is to be specified to fetch the secret by name using the new API.

Announce deprecation:

There will be a deprecation notice of around 2 months (exact date is yet to be decided), where any users using the format of <secret-type>/<secret-name> should migrate to use <secret-type>/<secret-name>/<group-name> format. During this deprecation period, both <secret-type>/<secret-name> and <secret-type>/<secret-name>/<secret-group-name> formats will be supported.
There will be a recommendation to use the new way of providing the remoteRef.key (i.e. <secret-type>/<secret-name>/<secret-group-name>).

Post-deprecation notice period:

Support to use secret-type>/<secret-name>  to fetch secret by name will be removed.
In order to fetch the secret by name, specifying the secret-group-name is mandatory, i.e. remoteRef.key should be provided in the format <secret-type>/<secret-name>/<secret-group-name>.

Additional context
Note that providing remoteRef.key provided in the format <secret-type>/<secret-id> to fetch the secret by ID is unaffected and should function as usual.

Consider a secret of type imported_cert with name my-imported-cert created in group name terraform-secrets
Below is an example External Secret definition for this secret to fetch by name:
apiVersion: external-secrets.io/v1beta1
kind: ExternalSecret
metadata:
  name: ibmcloud-secrets-manager-example
spec:
  secretStoreRef:
    name: ibmcloud-secrets-manager-example
    kind: SecretStore
  target:
    name: test-app-secret
    template:
      engineVersion: v2
      type: kubernetes.io/tls
  data:
  - secretKey: tls.crt
    remoteRef:
      key: imported_cert/my-imported-cert/terraform-secrets
      property: certificate
  - secretKey: tls.key
    remoteRef:
      key: imported_cert/my-imported-cert/terraform-secrets
      property: private_key

@moolen Looking for any input you may have before we start work on this.

Thanks for writing up that detailed issue.
My first thoughts: maybe it would be better to have the group before the secret name:
<secret-type>/<secret-group-name>/<secret-name>

IMO, it's odd/confusing to define the secret-name before the group. If i understand correctly, a secret is part of a group, hence i'd want to first define which group and then the secret (just my opinion on that).
I find this more readable:
secret/fluentd/api-key
secret/fluentd/some-config
secret/grafana/api-key
secret/grafana/some-config

than:
secret/api-key/grafana
secret/some-config/grafana
secret/api-key/fluentd
secret/some-config/fluentd

Are / charaters allowed in the secret name or secret group name, is there a potential of conflict? :thinking: That would make things worse :fearful:
Apart from that :point_up_2: the proposition LGTM.
Is that API going to be removed from the official IBM Cloud Secrets Manager API? Or will it stay there indefinitely?
If it stays i'd prefer to not break existing users, but if it will be removed we have to move as well :+1:  :smiley:

@moolen , thanks for looking into this.
Firstly, apologies for the delayed response.
Initial thought on the format was to retain the existing way of defining the remoteRef.key.
However, will go ahead with below, as suggested, and Idan had the same suggestion too
<secret-type>/<secret-group-name>/<secret-name>

/ character is not allowed as secret name or secret group, value must match regular expression^[A-Za-z0-9_][A-Za-z0-9_]*(?:_*-*\.*[A-Za-z0-9]*)*[A-Za-z0-9]+$. So there should be no conflict.
The API should be having a long term support, @IdanAdar can add more on that.

Hi @moolen , we now have a PR to address this issue.
We would like to deprecate the old mechanism of getting the secret by name, for which a deprecation notice will be issued in the documentation.
Deprecation notice would look something like below:
Note that specifying the 'remoteRef.key' in below manner to fetch the secret by name will soon be deprecated by <>
...
    remoteRef:
      key: <SECRET_TYPE>/<SECRET_NAME>
...

In order to get a secret by name, the secret group name should be specified in below manner:
...
    remoteRef:
      key: <SECRET_GROUP_NAME>/<SECRET_TYPE>/<SECRET_NAME>
...
The mechanism of fetching the secret by secret ID is unaffected.

Would you have any suggestion on the time frame till which the old mechanism should be supported. Thanks.

Hi @moolen , in case you missed above, thanks.

You're welcome 😊
On Sun, Oct 8, 2023, 12:11 AM Shanti G @.***> wrote:

Hi @moolen https://github.com/moolen , in case you missed above, thanks.
—
Reply to this email directly, view it on GitHub
https://github.com/external-secrets/external-secrets/issues/2717#issuecomment-1751922992,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/A4JB6WJNBBFVAPZL6ONY2V3X6IYZTAVCNFSM6AAAAAA47UI4WKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTONJRHEZDEOJZGI
.
You are receiving this because you are subscribed to this thread.Message
ID: @.***>

Hey! Sorry for the delay, I think we can deprecated it right away and remove the functionality with 0.10.

That works for us. @Shanti-G please update the wording accordingly and then we'll merge this PR to be included in the 0.9.6 release


Spack install of openblas on arm64 commands not working?

How does one call openblas within spack environment to install on something like a raspberry pi 5 arm64 architecture?

tried using
spack install --add openblas
and
spack install openblas target=aarch64
those error out and don't work

All prereqs are installed cmake, gmake, ninja, gcc

spack install --add  openblas target=armv8
==> Error: failed to concretize openblas arch=None-None-armv8<EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS>for the following reasons:
1. 'openblas target=neoverse_n1' cannot satisfy constraint 'target=armv8'. Couldn't concretize without changing the existing environment. If you are ok with changing it, try spack concretize --force. You could consider setting concretizer:unify to when_possible or false to allow multiple versions of some packages.

This is a problem within spack - their tool "helpfully" presets compiler/target options that conflict with what you actually want to use. There must be at least one open issue ticket in spack from at least a year ago - I untagged myself there after the comments became a stream of "me too" without any actual developer activity

So there's no fix

I honestly do not know if anyone has come up with a workaround - but this is not an OpenBLAS problem, please take it up with Spack (and search their open issue list for existing discussions).


fix: wip add fix_colr_font

Improvements I should make:

I had difficulties adding an empty glyph so I'm expecting the font to have one. It's not as simple as just adding a new glyph to the glyf table and then updating the font's glyphOrder order. You also need to update other tables such as hmtx etc,

cc @anthrotype basics are down. May chuck in CFF since I see Yanone has worked around this by using an area pen.

Thanks Cosimo. You've been great


Add Export PDF buttons to top of Vetting Worksheet

Description:
Users tend to open an application solely to print the PAF or Handle-It forms.  Users find it tedious to scroll to the bottom of the Vetting Worksheet for each application to do this.  Users request a similar button configuration to export the PDFs at the top of the Vetting Worksheet.
Acceptance Criteria:
Look at the top of VW for an Export PDFs button
PDF button content should be as follows

light blue button: "Export PDFs" - when this button is clicked, it should turn into
green buttons:  "Export PAF Report" and "Export Handle-It Report"
When a green button is clicked, the connected PDF is downloaded properly.
Functionality should be similar to the way it works at the bottom of VW

#157 Add Export PDF buttons to top of Vetting Worksheet
Branch 157 complete - not merged to develop yet:
Developer: Mike Haines
Highlights:

Added PDF Export buttons and functionality to top of Vetting Worksheet
Made behavior similar for top and bottom (press export at the top, the bottom shows that the files are ready to view as well)
Refactored Button Verbiage to reflect what is happening (PDF Generation happens on Export, View happens on green PAF Report or Handle It Report button push - the export has already happened, so I removed export from the PAF/Handle It buttons)
added post-export data change instructions (reload the page, export PDF again)
Project View export buttons reflect same changes for cross-application continuity

Acceptance Criteria:
See highlights above, and Issue Description for more Acceptance Criteria

Closed with the merge. May modify for two urls - one public and one private, but will open a new issue. Thanks Mike!


IBM UCD - using datapower plugin for deployment - timeout issue

Hi There,
I am using the datapower plugin to do deployment to datapower. The deployment actually works however the status on UCD ends in failure due to the timeout issue. Please find the attached screen from UCD. Logs attached as well. Tks
DP-logs-for-UCD.txt

UCD_Error_Logs.txt
UCD_stdOut_logs.txt

I scanned through UCD_stdOut_logs.txt for
status="ERROR"
There are several certificates that did not import correctly because of
some problem with one or more password aliases.  Set up those password
alias entries and give it another try.
As a general debugging tip when Import is failing, it is often useful to do
the import through the web browser since it does a better job of showing
the errors.
Hope this helps.
Thanks,
Rich
On Wed, Oct 26, 2016 at 12:36 PM, sawab80<EMAIL_ADDRESS>wrote:

Hi There,
I am using the datapower plugin to do deployment to datapower. The
deployment actually works however the status on UCD ends in failure due to
the timeout issue. Please find the attached screen from UCD. Logs attached
as well. Tks
DP-logs-for-UCD.txt
https://github.com/ibm-datapower/datapower-configuration-manager/files/553882/DP-logs-for-UCD.txt
[image: ucd_deployment_status]
https://cloud.githubusercontent.com/assets/23081143/19735215/aa3dea90-9b78-11e6-9637-b9ae2687272d.png
UCD_Error_Logs.txt
https://github.com/ibm-datapower/datapower-configuration-manager/files/553883/UCD_Error_Logs.txt
UCD_stdOut_logs.txt
https://github.com/ibm-datapower/datapower-configuration-manager/files/553884/UCD_stdOut_logs.txt
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/ibm-datapower/datapower-configuration-manager/issues/33,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ADuMmvIs-Z_Txog2ep7_mcNUy3Hka5Woks5q34F4gaJpZM4KhZQb
.

Set up those password alias entries and give it another try.
- where to set these password? The passwords do exist in the environment from where the export of the package was taken, in firmware 7 the passwords doesn't get imported.

Yeah, password aliases cannot be (iirc) exported, which is a key part of
their contribution to the security of the appliance.  You'll want to
manually create new password aliases on the target appliance before the
import can be expected to complete successfully.
On Thu, Oct 27, 2016 at 1:41 PM, Asim<EMAIL_ADDRESS>wrote:

Set up those password alias entries and give it another try.
- where to set these password? The passwords do exist in the environment
from where the export of the package was taken, in firmware 7 the passwords
doesn't get imported.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/ibm-datapower/datapower-configuration-manager/issues/33#issuecomment-256717272,
or mute the thread
https://github.com/notifications/unsubscribe-auth/ADuMmuUsCGI0bUxa3Z-vCyQGrvIc3V6Cks5q4OI2gaJpZM4KhZQb
.

Hi Rich,
Is there any way we can create this Password Alias Object at run time. May be using DCM  (object-from-def) or any other option?

Getting a success flag in UCD now. Created password alias in dp first then followed by the ucd deployment. Thanks


Half the collisions dont work in v2.4.9

I landed on experimentation cant touch the monitors, the sides of the ship, the concrete platform on exp on the ship without falling through or walking through them.

same

Bump.
most of Colliders are not working on most maps.

Can confirm, this update caused me to fall through several areas (notably with ladders) including the ones on the ship, as well as the two ladders leading into experimentation.

Hi! Most colosseum models don't work. The standard models of the game such as the Ship, platforms, and internal parts of the ship - monitors - have broken down. Containers in the company , pipes that lead to the doorway. As a complication of the game, it's cool, but it really bothers and bothers, especially knowing that it shouldn't be like this.

Same issue here

same got to play on 2.4.8 then

Yes! Hope it gets fixed soon, for now you can just run old version

See the latest version.


feat: adding samples to start/stop/reset operations

Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly:

[x] Ensure the tests and linter pass
[x] Code coverage does not decrease (if any source code was changed)

b/192839790
Will be added to this page

@engelke can you have a look?

The tests should be finally fixed now. @engelke can  you review?


Design a good All Categories page

Design a good All category page
The  demo template is shown below  https://demo.activeitzone.com/ecommerce/brands
let's know if you need more information
NOTE: the page file is located in the pages folder

I would like to work on this

@alvinokafor  you can go on

@iamkelv Just to clarify, for this task i just need to replicate the all categories page from the demo link right?

@alvinokafor  Yes

ok, thanks


Problem running on Ubuntu 20.04 with 4 x NVIDIA T4

I've gone through all the steps of installation and am receiveing the following error... can anyone point me in the right direction?
(.venv) deploy@flux:~/flux/fluxcode/src$ python -m flux --name flux-schnell --loop

You are using the default legacy behaviour of the <class 'transformers.models.t5.tokenization_t5.T5Tokenizer'>. This is expected, and simply means that the `legacy` (previous) behavior will be used so nothing changes for you. If you want to use the new behaviour, set `legacy=False`. This should only be set if you understand what it means, and thoroughly read the reason why this was added as explained in https://github.com/huggingface/transformers/pull/24565
/home/deploy/flux/fluxcode/.venv/lib/python3.10/site-packages/transformers/tokenization_utils_base.py:1601: FutureWarning: `clean_up_tokenization_spaces` was not set. It will be set to `True` by default. This behavior will be depracted in transformers v4.45, and will be then set to `False` by default. For more details check this issue: https://github.com/huggingface/transformers/issues/31884
  warnings.warn(
Traceback (most recent call last):
  File "/home/deploy/flux/fluxcode/.venv/lib/python3.10/site-packages/transformers/modeling_utils.py", line 575, in load_state_dict
    return torch.load(
  File "/home/deploy/flux/fluxcode/.venv/lib/python3.10/site-packages/torch/serialization.py", line 1087, in load
    overall_storage = torch.UntypedStorage.from_file(os.fspath(f), shared, size)
RuntimeError: unable to mmap<PHONE_NUMBER>9 bytes from file </home/deploy/.cache/huggingface/hub/models--google--t5-v1_1-xxl/snapshots/3db67ab1af984cf10548a73467f0e5bca2aaaeb2/pytorch_model.bin>: Cannot allocate memory (12)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/deploy/flux/fluxcode/.venv/lib/python3.10/site-packages/transformers/modeling_utils.py", line 584, in load_state_dict
    if f.read(7) == "version":
  File "/home/deploy/.pyenv/versions/3.10.14/lib/python3.10/codecs.py", line 322, in decode
    (result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: 'utf-8' codec can't decode byte 0x80 in position 64: invalid start byte

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/home/deploy/.pyenv/versions/3.10.14/lib/python3.10/runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "/home/deploy/.pyenv/versions/3.10.14/lib/python3.10/runpy.py", line 86, in _run_code
    exec(code, run_globals)
  File "/home/deploy/flux/fluxcode/src/flux/__main__.py", line 4, in <module>
    app()
  File "/home/deploy/flux/fluxcode/src/flux/cli.py", line 250, in app
    Fire(main)
  File "/home/deploy/flux/fluxcode/.venv/lib/python3.10/site-packages/fire/core.py", line 143, in Fire
    component_trace = _Fire(component, args, parsed_flag_args, context, name)
  File "/home/deploy/flux/fluxcode/.venv/lib/python3.10/site-packages/fire/core.py", line 477, in _Fire
    component, remaining_args = _CallAndUpdateTrace(
  File "/home/deploy/flux/fluxcode/.venv/lib/python3.10/site-packages/fire/core.py", line 693, in _CallAndUpdateTrace
    component = fn(*varargs, **kwargs)
  File "/home/deploy/flux/fluxcode/.venv/lib/python3.10/site-packages/torch/utils/_contextlib.py", line 116, in decorate_context
    return func(*args, **kwargs)
  File "/home/deploy/flux/fluxcode/src/flux/cli.py", line 158, in main
    t5 = load_t5(torch_device, max_length=256 if name == "flux-schnell" else 512)
  File "/home/deploy/flux/fluxcode/src/flux/util.py", line 131, in load_t5
    return HFEmbedder("google/t5-v1_1-xxl", max_length=max_length, torch_dtype=torch.bfloat16).to(device)
  File "/home/deploy/flux/fluxcode/src/flux/modules/conditioner.py", line 18, in __init__
    self.hf_module: T5EncoderModel = T5EncoderModel.from_pretrained(version, **hf_kwargs)
  File "/home/deploy/flux/fluxcode/.venv/lib/python3.10/site-packages/transformers/modeling_utils.py", line 3738, in from_pretrained
    state_dict = load_state_dict(resolved_archive_file)
  File "/home/deploy/flux/fluxcode/.venv/lib/python3.10/site-packages/transformers/modeling_utils.py", line 596, in load_state_dict
    raise OSError(
OSError: Unable to load weights from pytorch checkpoint file for '/home/deploy/.cache/huggingface/hub/models--google--t5-v1_1-xxl/snapshots/3db67ab1af984cf10548a73467f0e5bca2aaaeb2/pytorch_model.bin' at '/home/deploy/.cache/huggingface/hub/models--google--t5-v1_1-xxl/snapshots/3db67ab1af984cf10548a73467f0e5bca2aaaeb2/pytorch_model.bin'. If you tried to load a PyTorch model from a TF 2.0 checkpoint, please set from_tf=True.

same

i think you need to choose a vm with more ram (say 50G+), according to unable to mmap<PHONE_NUMBER>9 bytes.
however, the gpu ram will be another issue which i'm facing  https://github.com/black-forest-labs/flux/issues/120


shapeshifter-dispatcher: init at 3.0.1

Description of changes
https://github.com/OperatorFoundation/shapeshifter-dispatcher
Things done

Built on platform(s)

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

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

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

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

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module
[ ] (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes

[x] Fits CONTRIBUTING.md.

Well, after all I decided not to use it. So closing the MR, but if anyone needs it it's still mergeable, I'm just not sure I'll be the best maintainer :)


Add configuration to enable or disable submissions

Right now it was hardcoded, moved it to scaffoldConfig, similar to how we manage if voting is enabled or disabled for admins.

Thanks <3


OCPBUGS-2076: Replace k8s.io/cloud-provider with openshift's version

Service handling logic in k8s.io/cloud-provider v0.25.(0,1,2) is broken. This issue was fixed upstream, but not released yet. We are expecting that this fixes will be included into v0.25.3, but now need to replace released cloud-provider library version with the latest version from release-1.25 branch.
Xref: https://github.com/kubernetes/kubernetes/issues/112793
This commit is expected to be dropped during next rebase.

/jira refresh

/retest

/retest-required

/approve


Extra experiment management dvc

I wanted to further explore dvc, going to see how it handles experiments. The pipeline behind the experiments is composed in two parts: one to prepare the data and the other to work on it (training, validation, testing)

Hi,
I edited the sentences
Best regards,
RIccardo
Il giorno ven 8 ott 2021 alle ore 18:15 Riccardo Denni <
@.***> ha scritto:

Hi,
Hi,
yes unfortunately I realized after finishing the project that another guy
has chosen my same topic ... only that since our two projects are different
and that I had already finished mine I thought to make the pull request the
same
Alright, I'll edit the sentences I took from the dvc site and delete that
sentence
Is this ok for the exam?
Best regards,
Riccardo
Il ven 8 ott 2021, 16:38 Simone Scardapane @.***> ha
scritto:

Hi,

We already have a branch on this, is it similar?
https://github.com/sscardapane/reprodl2021/tree/extra_dvc_experiments_management
Can you remove sentences that are copy-pasted from elsewhere?
Remove this sentence: "Make an introduction to how to handle
experiments with dvc!".

—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/sscardapane/reprodl2021/pull/24#issuecomment-938694938,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AV3QCE4BRKM5DIDTOVN4THTUF365RANCNFSM5FTMZSAQ
.
Triage notifications on the go with GitHub Mobile for iOS
https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675
or Android
https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

I'll think about including this in the main repository, but it is okay for the exam in the meantime.


measureText() is slightly off

Hi! I've been using canvas cairo backend / node-canvas created by Automattic. And I'm using packages called canvas-text-wrapper for wraps big/long texts. When using node-canvas it works fine, everything align to the middle. But after using your canvas, it offset are off. And it might be because of value width on measureText() are different compared to node-canvas.
Here is the result when measuring text 'Hello World' :
node-canvas :
{
  width: 22,
  actualBoundingBoxLeft: 0,
  actualBoundingBoxRight: 22,
  actualBoundingBoxAscent: 8,
  actualBoundingBoxDescent: 0,
  emHeightAscent: 10,
  emHeightDescent: 3,
  alphabeticBaseline: 0.947265625
}

@napi-rs/canvas
{
  actualBoundingBoxAscent: 10,
  actualBoundingBoxDescent: 0,
  actualBoundingBoxLeft: 0,
  actualBoundingBoxRight: 24,
  fontBoundingBoxAscent: 8.056640625,
  fontBoundingBoxDescent: 6.62109375,
  width: 25
}

I'm using 512x512 canvas.
And here I'm using the package canvas-text-wrapper with the options below :
wrap(canvas, 'Hello World', {
	font: '82px chevin',
	textAlign: 'center',
	verticalAlign: 'middle',
	sizeToFill: true,
});

The font I used :
https://fontsgeek.com/fonts/Chevin-Bold
Results :
node-canvas : https://imgur.com/a/gjplLKV
@napi-rs/canvas : https://imgur.com/a/jZ0Rtgi

same

Same as me :(

Same as me :(

Just a suggestion, this issue is already noticed by the maintainer so let's not spam the inbox of the people watching this repository by commenting like this unless it is really necessary 😕

@nugraizy this font https://fontsgeek.com/fonts/Chevin-Bold is Chevin not chevin

@nugraizy this font https://fontsgeek.com/fonts/Chevin-Bold is Chevin not chevin

done it. sadly doesn't fix the issue

@nugraizy could you provide a minimal reproducible repo so I can debug it

@nugraizy could you provide a minimal reproducible repo so I can debug it

sure! here's the repo


[ENHANCEMENT] Responsive Width

Is your feature request related to a problem? Please describe.
Currently width is set to a fixed amount (ie: sm, lg, xl, xxl).  Another option to allow the svg to scale responsively to the width of the container would improve the UX compatibility for desktop/mobile screens.
Describe the solution you'd like
Add responsive option for size property to allow the svg to scale dynamically with the width of the container.

This is a great idea and I have been thinking about this for a long time. I have been getting requests over email asking me for different sizes and have been thinking about this and I think this would be a great solution. Will begin working on it and send you an update.

This is a great idea and I have been thinking about this for a long time. I have been getting requests over email asking me for different sizes and have been thinking about this and I think this would be a great solution. Will begin working on it and send you an update.

Hey @peetss!
Thank you so much for the suggestion! Check out https://github.com/yanivam/react-svg-worldmap/pull/70. Version 1.0.41 contains the string "responsive" as on option for size.
Thanks again,
Yams

Hey @peetss!
Thank you so much for the suggestion! Check out https://github.com/yanivam/react-svg-worldmap/pull/70. Version 1.0.41 contains the string "responsive" as on option for size.
Thanks again,
Yams


Optimize num_rows() method for data_sources

Right now the num_rows() method typically means an athena query. This take WAY TOO LONG, figure out a way to compute or cache or something.
'NumRows': athena_source.num_rows(),  # This takes TOO LONG

Rows are now captured as part of the details() method and the results of that method get cached so it's no longer important to optimize this method.


automatic file import stopped working

I have a docker setup. I don't need a mail import so far. I just want import my documents via files. So I did my test runs. The first two documents worked like almost like a charm. The first document was added twice. Anyway an adding of any new file to the importer directory doesn't trigger anything. But when I execute the import manually be ./manage.py local_importer it works fine. Any idea how can I get the automatic import back?
thnx

For me it also doesn't work. I configured the IMPORT_DIR inside the papermerge.conf.py file and restarted the docker. However when I place documents inside the specified IMPORT_DIR nothing happens. How can I debug this?
I'm kind of new to papermerge and I'm in the process of setting up my system, it has been 2 weeks and I'm slowly getting there. Thanks for this beautiful open source project.

I have some infos. Seems that the worker got an issue during the OCR of one file - see log below, Than it stopped working. So the still not OCRed files are still in the importer dir. Until I don't delete them manually the importer won't work automatically. After deletion of those files - it works again. But the crashes happens quite often. This brings me to my next question. I have an extra OCR pipeline with tesseract and imagemagick. So I don't need the OCR feature and it seems not quite stable. So is it possible to deactivate the OCR feature?
here  the log of the papermerge_worker
[2021-07-08 06:39:07,712: ERROR/ForkPoolWorker-2] Task papermerge.core.management.commands.worker.import_from_local_folder[c8436101-f970-4efb-a992-25b9879bb8d7] raised unexpected: Exception('Error occured while getting document page count.')
Traceback (most recent call last):
File "/opt/app/.venv/lib/python3.8/site-packages/celery/app/trace.py", line 405, in trace_task
R = retval = fun(*args, **kwargs)
File "/opt/app/.venv/lib/python3.8/site-packages/celery/app/trace.py", line 697, in protected_call
return self.run(*args, **kwargs)
File "/opt/app/.venv/lib/python3.8/site-packages/papermerge/core/management/commands/worker.py", line 70, in import_from_local_folder
import_documents(settings.PAPERMERGE_IMPORTER_DIR)
File "/opt/app/.venv/lib/python3.8/site-packages/papermerge/core/importers/local.py", line 52, in import_documents
doc = go_through_pipelines(init_kwargs, apply_kwargs)
File "/opt/app/.venv/lib/python3.8/site-packages/papermerge/core/import_pipeline.py", line 371, in go_through_pipelines
doc = importer.apply(**apply_kwargs)
File "/opt/app/.venv/lib/python3.8/site-packages/papermerge/core/import_pipeline.py", line 272, in apply
page_count = self.page_count()
File "/opt/app/.venv/lib/python3.8/site-packages/papermerge/core/import_pipeline.py", line 156, in page_count
return get_pagecount(self.path)
File "/opt/app/.venv/lib/python3.8/site-packages/mglib/pdfinfo.py", line 126, in get_pagecount
raise Exception("Error occured while getting document page count.")
Exception: Error occured while getting document page count.


Suggestion to rework tabs/spaces commands

For tabs/spaces work, currently app has the weird checkboxes in the "File Properties" dlg.

I suggest to make it like in Sublime Text and CudaText.

make the "Tabs" or "Spaces" cell in the lower statusbar
on clicking this cell, show dropdown menu with several check-items, and/or commands

CudaText has this

if "tabs as spaces" on: statusbar  cell name is "Spaces: 4" (4 is tab width)
if "tabs as spaces" off: cell name is "Tabs: 4" (so cell is renamed)
dropdown from this cell shows items:

The lowest 2 items are the same in CudaText and in SublimeText, so user like that.

Convert ... to spaces
Convert ... to tabs

The upper items are check-items which change flags.

Look at last version. I have fixed some Tabs logic, but without Status Bar using.

I will, but I need the compiled version (I am not a C++ man)

You can get snap.

Will check it..

It’s improved but yet not like in the proposal. I wish you make it like in proposal, thanks.


Models created in GIMS crash upon Import

Steps to reproduce:

Open Blender with Sollumz
Get a mesh assembled in Gims EVO (demo file attached)
Get the ydr.xml of said mesh
Import file into Blender. Blender will crash upon trying to import

Demo File.zip

Fixed, sorry for the wait


Add secrets.yml to multinode env

This change adds a template secrets.yml file to provide a definition for the barbican role IDs required for backend and internal TLS.

See also https://github.com/stackhpc/terraform-kayobe-multinode/pull/29


Error when deploying to Heroku

I was having this error when trying to deploy a Django app to Heroku (following their tutorial). This also happens when running foreman start locally.
ImproperlyConfigured: Requested setting USE_I18N, but settings are not configured.
You must either define the environment variable DJANGO_SETTINGS_MODULE or call
settings.configure() before accessing settings.

The solution?
Setting the DJANGO_SETTINGS_MODULE before importing and calling Cling.
import os
from django.core.wsgi import get_wsgi_application

os.environ.setdefault('DJANGO_SETTINGS_MODULE', 'trappt.settings')

from dj_static import Cling
application = Cling(get_wsgi_application())

This can be closed.

Why was this closed? Shouldn't it at least be documented in the README?

Why would DJANGO_SETTINGS_MODULE not be set? How are you launching Django?

Not sure right now TBH.
But I remember debugging that and getting the error, and solving it by having DJANGO_SETTINGS_MODULE move up before Cling.

Why would DJANGO_SETTINGS_MODULE not be set?

It wouldn't be set unless you set the environmental variable. Often this is unnecessary which is why the default wsgi.py created by python manage.py startproject sets a default:
"""
WSGI config for mysite project.

It exposes the WSGI callable as a module-level variable named ``application``.

For more information on this file, see
https://docs.djangoproject.com/en/1.8/howto/deployment/wsgi/
"""

import os

from django.core.wsgi import get_wsgi_application

os.environ.setdefault("DJANGO_SETTINGS_MODULE", "mysite.settings")

application = get_wsgi_application()


P5 inno 167 create project submission review page

✨ Purpose:
Added Project Submission Review Page

Format formData
Allows the user to enter edit mode
User can edit each formData

Added UploadCard to both ProjectReviewPage and ProjectSubmissionPage and maps uploaded file
Added Header component

Looks good!


[Doc]--cloud storage sink connector doc

as the connector doc uses a new structure, more inputs are required. Please help provides the inputs as i comment in this google doc:
https://docs.google.com/document/d/1xxAtu-GjTLnzY0s6lQ3f_UJnhUDk6pULGPpThMFS47g/edit#
You can take SQS source connector doc for your reference.
SQS source connector doc: https://github.com/streamnative/pulsar-io-sqs/blob/master/docs/sqs-source.md

@jianyun8023 how is going on this issue? Do you plan to work on this document? Thanks.


Need  a possibility to specify the name of state directory

I'm submitting a...

[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report
[ ] Performance issue
[x] Feature request
[ ] Documentation issue or request
[ ] Support request
[ ] Other... Please describe:

Current behavior

 function buildPath( name, chosenDir ) {
    if(userPath) {
      return `${userConfig}/${chosenDir}/state/${name}`;
    }
     return `${process.cwd()}/${chosenDir}/state/${name}`;
}

Currently the name of state directory is hardcoded in cli source code.
Expected behavior
Please, add a possibility to specify the name of state directory :)
What is the motivation / use case for changing the behavior?
I want a possibility to create state directory with specified name w/o "state" directory inside using cli.
e.g.

/app/states/
    widgets/widgets.store.ts
    ....
    globals/globals.store.ts
    ...
    etc.

Currently i must to do it manually.
Thx =)

Will do soon, thanks!

Released v1.4.0. You can now add the following config:
"akitaCli": {
  "customFolderName": "true",
  "basePath": "./playground/src/app/"
}


chore(users): use swr to manage user state and mutations

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


EC2-stopped not working

EC2-stopped task is not working/ stopping instance. I created task using SSM automation document and S3 folder as mention in document.
Please help and share SSM docs if anyone created, so that I can compare with mine.

Hi @satyajitkoijam
It might help to check a couple of things before troubleshooting the SSM Automation Document itself:

When creating the custom action, you will also need to create a CloudFormation template for the IAM Role that will be created to give Operations Conductor to stop the instance. Described in the Create IAM Role Template section of Appendix C
Are the resources (EC2 instances) tagged with the target-tag that you used when creating the task in the Operations Conductor UI? You can manually double check to make sure the correct tags are on the EC2 instances (double check the Target Tag section of Appendix A) or you can check the CloudWatch logs for the Resource Selector lambda to make sure:

The lambda is being run (confirms your Operations Conductor task is set up and scheduled correctly)
The resource selector is finding your EC2 instances. If you see that Resource Selector found 0 resources to act on, it's probably that the instances are not tagged.

If you've validated that the Operations Conductor task is created correctly and that Resource Selector is able to find your resources, then Operations Conductor should be executing your SSM Automation Document to stop the instances. The next step would be to have a look in the SSM console to see if there are any errors being reported in the execution of the automation document.


Added 'enabled' attribute to the logging rule element.

Enabled attribute was added in revision 9a069ef3121b7d87edaaf1c40a7b5f6bc57886e2. Now it's supported in NLog.xsd schema too.
closes #13

@Xharze why is this milestone 4.0? The enabled attribute is already in the 3.x releases?

It believe this fix was introduced after the v3.2 release. But I'll try and
create an update for xsd file which can be released separately.


Mysql - Cannot connect to a database with a "-" in its name

Your issue may already be reported! Please search on the issue track before creating one.
What version of Go are you using (go version)?
go version go1.13 linux/amd64
Which database and its version are you using?
mysql 5.7
Please provide a complete runnable program to reproduce your issue. IMPORTANT
Need to runnable with GORM's docker compose config or please provides your config.
func Init() {
	var err error

	dbConfig := conf.GetDatabase()
	DB, err = gorm.Open(dbConfig.Dialect, dbConfig.Dsn)
	if err != nil {
		panic(errkit.Wrapf(err, "failed to connect finance database, database config is %v", dbConfig))
	}
	if dbConfig.Debug {
		DB = DB.Debug()
	}

	DB.AutoMigrate(
		&pkg.test{},
	)
	log.Print("All table AutoMigrate finish.")
}

// Database 数据库配置
type Database struct {
	Dialect string
	Dsn     string
	Debug   bool
}

// GetDatabase 获取数据库配置
func GetDatabase() *Database {
	return &Database{
		Dialect: viper.GetString("database.dialect"),
		Dsn:     viper.GetString("database.dsn"),
		Debug:   viper.GetBool("database.debug"),
	}
}

log
Using config file: /var/config/config.yaml
panic: Error 1064: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '-kit WHERE Tables_in_pro-kit= ?' at line 1

goroutine 1 [running]:
github.com/jinzhu/gorm.mysql.HasTable(0xc72680, 0xc00032c0c0, 0xc000482100, 0xc000482100, 0xd, 0xf)
	/go/src/github.com/jinzhu/gorm/dialect_mysql.go:172 +0x3bb
github.com/jinzhu/gorm.(*Scope).autoMigrate(0xc0001d5e80, 0xa6d720)
	/go/src/github.com/jinzhu/gorm/scope.go:1262 +0xb3
github.com/jinzhu/gorm.(*DB).AutoMigrate(0xc0002f45b0, 0xc0004a5e58, 0x9, 0x9, 0x1)
	/go/src/github.com/jinzhu/gorm/main.go:657 +0x88
code.aliyun.com/pro/kit/internal/sql.Init()

I found a solution and submitted a new pull request

I found the problem and submitted a new pull request,But my submission doesn't seem to pass the coverage check.


error use combo as grid cell editor

I use combo as grid cell editor, when I press a key (char or digit) in combo control, the error occured:
TypeError: input.val(...) is undefined
if (input.val().length == 1) this.refresh()  (the line 14961 in w2ui.js)
I use the latest nightly build (2015-10-18)

I was getting slightly different error, but in the same place. I have fixed it. Will recompile lib later today. I hope it helps, reopen if you still have the issue.


Set up a frontend outline

navigation

home : show dashboard
sensor : show sensor, node list
kibana : link to kibana

register node, raspberrypi, sensor

modal window
form
make json file and send to backend

for your information - post request
https://github.com/PacktPublishing/Hands-On-Full-Stack-Development-with-Go/tree/master/Chapter07/Frontend
async handleSubmit(event) {
        let response = await fetch("/users/charge", {
            method: "POST",
            headers: { "Content-Type": "application/json" },
            body: JSON.stringify({
                token: id,
                customer_id: this.props.user,
                product_id: this.props.productid,
                sell_price: this.props.price,
                rememberCard: this.state.remember !== undefined,
                useExisting: this.state.useExisting
            })
        });

        if (response.ok) {
            console.log("Purchase Complete!");
            this.setState({ status: SUCCESSSTATE });
        } else {
            this.setState({ status: FAILEDSTATE });
        }
    }

thank for your information


Insert initial data into conductor in Docker compose [feature]

I've managed to change a docker-compose in a way to Insert my arbitrary Workflows and Taskdefs in startup:
# Docker compose for netflix conductor + elasticsearch + dynomite
version: '2'
services:
  conductor-server:
    environment:
      - CONFIG_PROP=config.properties
    image: conductor:server
    build:
      context: ../
      dockerfile: docker/server/Dockerfile
    ports:
      - 8080:8080
    links:
      - elasticsearch:es
      - dynomite:dyno1
    healthcheck:
      test: curl -f http://localhost:8080/api/metadata/taskdefs/task_0/ || false
      interval: 10s
      timeout: 2s
      retries: 7

  conductor-ui:
    environment:
      - WF_SERVER=http://conductor-server:8080/api/
    image: conductor:ui
    build:
      context: ../
      dockerfile: docker/ui/Dockerfile
    ports:
      - 5000:5000
    links:
      - conductor-server

  dynomite:
    image: v1r3n/dynomite

  elasticsearch:
    image: elasticsearch:5
    command: "-Etransport.host=<IP_ADDRESS>"

  init-curl-tasks-and-workflows:
    image: spotify/alpine
    entrypoint: bash /opt/conductor/init.sh
    volumes:
      - ./init-script/init.sh:/opt/conductor/init.sh
    depends_on:
      conductor-server:
        condition: service_healthy
    links:
      - conductor-server:conductor-server

in this docker-compose i added healthcheck to conductor-server and
after conductor server state become healthy,  i've just started init-curl-tasks-and-workflows in which i've curled my initial taskdefs and workflows into conductor-server.
in the init-curl-tasks-and-workflows container i needed curl to be available so i've used spotify/alpine docker image which had curl into itself.
there was a problem with the healthcheck in conductor-server  because curl was not available in it's docker image so i changed it's docker file to add curl inside it:
#
# conductor:server - Netflix conductor server
#
FROM openjdk:8-jre-alpine

MAINTAINER Netflix OSS<EMAIL_ADDRESS>
RUN apk update && apk add curl && rm -rf /var/cache/apk/*

# Make app folders
RUN mkdir -p /app/config /app/logs /app/libs

# Copy the project directly onto the image
COPY ./docker/server/bin /app
COPY ./docker/server/config /app/config
COPY ./server/build/libs/conductor-server-*-all.jar /app/libs

# Copy the files for the server into the app folders
RUN chmod +x /app/startup.sh

EXPOSE 8080
EXPOSE 8090

CMD [ "/app/startup.sh" ]
ENTRYPOINT [ "/bin/sh"]

and now i was able to add my arbitrary tasks using init.sh script using curl:
curl -X POST \
  http://conductor-server:8080/api/metadata/taskdefs \
  -H 'cache-control: no-cache' \
  -H 'content-type: application/json' \
  -d '[
  {
    "name": "t_em_register_user",
    "retryCount": 3,
    "timeoutSeconds": 1200,
    "inputKeys": [
      "studentId",
      "educationalInstituteId",
      "majorName",
      "degree",
      "startSemester",
      "person"
    ],
    "outputKeys": [
      "responseCode",
      "responseStatus"
    ],
    "timeoutPolicy": "TIME_OUT_WF",
    "retryLogic": "FIXED",
    "retryDelaySeconds": 600,
    "responseTimeoutSeconds": 3600
  },
  {
    "name": "t_bm_register_cardholder",
    "retryCount": 3,
    "timeoutSeconds": 1200,
    "inputKeys": [
      "studentId",
      "educationalInstituteId",
      "majorName",
      "degree",
      "startSemester",
      "person"
    ],
    "outputKeys": [
      "responseCode",
      "responseStatus"
    ],
    "timeoutPolicy": "TIME_OUT_WF",
    "retryLogic": "FIXED",
    "retryDelaySeconds": 600,
    "responseTimeoutSeconds": 3600
  }
]'&&
curl -X POST \
  http://conductor-server:8080/api/metadata/workflow \
  -H 'cache-control: no-cache' \
  -H 'content-type: application/json' \
  -d '{
  "name": "w_em_register_student",
  "description": "A workflow for saving student with 2 tasks",
  "version": 1,
  "tasks": [
    {
      "name": "t_em_register_user",
      "taskReferenceName": "t_em_register_user",
      "type": "SIMPLE",
      "startDelay": 0,
      "optional": false
    },
    {
      "name": "t_bm_register_cardholder",
      "taskReferenceName": "t_bm_register_cardholder",
      "type": "SIMPLE",
      "startDelay": 0,
      "optional": false
    }
  ],
  "schemaVersion": 2,
  "restartable": true
}'

should i create a PR for it? and from which branches should i start with?

@unikzforce It's been a while, but this looks good to me. Please send a PR if you're still interested. Also, please make sure to rebase with latest Docker set-up. Thank you.

i've just rebased and wanted to test my solution again, but there is a problem with the healthcheck.
during my healthcheck interval "kitchensink" example cannot be added to the system.
i mean the conductor-server will start and after it started it'll try to add kitchensink, if there was no healthcheck it'll add kitchensink,
but if it has a healthcheck it will stuck like this

and it will continue only after healthcheck has been failed.
first i thought that my healthcheck test is interrupting it was like this (in conductor-server service):
version: '2.3'

services:
  conductor-server:
    environment:
      - CONFIG_PROP=config.properties
    image: conductor:server
    build:
      context: ../
      dockerfile: docker/server/Dockerfile
    networks:
      - internal
    ports:
      - 8080:8080
    links:
      - elasticsearch:es
      - dynomite:dyno1
    depends_on:
      elasticsearch:
        condition: service_healthy
      dynomite:
        condition: service_healthy
    # logging:
    #   driver: "json-file"
    #   options:
    #     max-size: "1k"
    #     max-file: "3"
    healthcheck:
      test: curl -f http://localhost:8080/api/metadata/taskdefs/task_0/ || false
      interval: 10s
      timeout: 2s
      retries: 50

  conductor-ui:
    environment:
      - WF_SERVER=http://conductor-server:8080/api/
    image: conductor:ui
    build:
      context: ../
      dockerfile: docker/ui/Dockerfile
    networks:
      - internal
    ports:
      - 5000:5000
    links:
      - conductor-server

  dynomite:
    image: v1r3n/dynomite
    networks:
      - internal
    ports:
      - 8102:8102
    healthcheck:
      test: timeout 5 bash -c 'cat < /dev/null > /dev/tcp/localhost/8102'
      interval: 5s
      timeout: 5s
      retries: 12
    # logging:
    #   driver: "json-file"
    #   options:
    #     max-size: "1k"
    #     max-file: "3"

  # https://www.elastic.co/guide/en/elasticsearch/reference/5.6/docker.html
  elasticsearch:
    image: docker.elastic.co/elasticsearch/elasticsearch:5.6.8
    environment:
      - "ES_JAVA_OPTS=-Xms512m -Xmx512m"
      - transport.host=<IP_ADDRESS>
      - discovery.type=single-node
      - xpack.security.enabled=false
    networks:
      - internal
    ports:
      - 9200:9200
      - 9300:9300
    healthcheck:
      test: timeout 5 bash -c 'cat < /dev/null > /dev/tcp/localhost/9300'
      interval: 5s
      timeout: 5s
      retries: 12
    logging:
      driver: "json-file"
      options:
        max-size: "1k"
        max-file: "3"

  init-curl-tasks-and-workflows:
    image: spotify/alpine
    networks:
      - internal
    entrypoint: bash /opt/conductor/init.sh
    volumes:
      - ./init-script/init.sh:/opt/conductor/init.sh
    depends_on:
      conductor-server:
        condition: service_healthy
    links:
      - conductor-server:conductor-server

networks:
  internal:

so i changed it from test: curl -f http://localhost:8080/api/metadata/taskdefs/task_0/ || false to test: timeout 2 bash -c 'cat < /dev/null > /dev/tcp/localhost/8080',
but still the same reaction happen.
do you know how to create a proper healthcheck?

after the healthcheck fails:

kitchensink example addition will continue:

I don't want to depend healthcheck on the existence of kitchensink but even the test: timeout 2 bash -c 'cat < /dev/null > /dev/tcp/localhost/8080' will fail anyway.
you can find my code in this fork in master branch.

Hard to tell why the health checks have failed, would you mind posting full error logs?

Of course ,i'll send more information ASAP.


apoc.periodic.repeat does not affect

apoc.periodic.repeat does not take a place, for example the below simple cypher does not execute
CALL apoc.periodic.repeat(
"create-people",
"UNWIND range(1,2) AS id CREATE (:Person {uuid: apoc.create.uuid()})",
1
);

@java-eyes Your query looks correct to me. Do you mean that it is the inner create query that is never run (i.e. no nodes created) or that you get some error when you run the whole query? Which version of Neo4j and APOC are you using?
Best regards Louise, Neo4j

Seems to work correctly on 5.25.1. I will close the issue. Let us know if you have any further problems.


changed background gradient to meet contrast requirements

Changed background gradient to meet contrast requirements affecting the header, footer and some design elements in the middle of the web page.
My used colors were approved by the UX team.
Before

After

@svengabr

Does this resolve the old issue https://github.com/corona-warn-app/cwa-website/issues/16?

This will increase the minimum contrast to 1:3 which should be the minimum required amount. I will link it to this very old issue which weirdly I can't even select since the issue is too old (I guess)

Closes https://github.com/corona-warn-app/cwa-website/issues/16


Segmentation: new events segment

For example, I wanted to add the new events are:
SEGMENT_ADDED
SEGMENT_COMPLETED
What do you think? I needed "SEGMENT_COMPLETED" to be able to update the segmentation listing. It's like "ANNOTATION_COMPLETED"

I'm not sure if SEGMENT_COMPLETED makes sense, since we already have SEGMENTATION_DATA_MODIFIED, it doesn't have SEGMENT index since for instance we can paint with segment1 but during paint it modifies the segment2 also. Maybe we can include the active segment index in that event.
Also for SEMGNET_ADDED we don't keep track of segments as of now. I really think we should do somehow but then synchronizing them would be a pain


Log collection for the functional job

Signed-off-by: Dmitry Tantsur<EMAIL_ADDRESS>

needs rebase

/lgtm

/approve


InputLang Component uses Redux state

Refactor InputLang Component to use more of the Redux state (currently has placeholders for mapStateToProps and mapDispatchToProps.

@jcoyne is this done?  Should ticket be closed?

I'm still working on it.


Refactor Tholder to accept and process all forms of sith, and limen (CESR)

Codecov Report

Merging #252 (3ccac6d) into development (28873f4) will increase coverage by 0.16%.
The diff coverage is 97.33%.

@@               Coverage Diff               @@
##           development     #252      +/-   ##
===============================================
+ Coverage        89.65%   89.82%   +0.16%
===============================================
  Files              165      165
  Lines            36306    36864     +558
===============================================
+ Hits             32551    33112     +561
+ Misses            3755     3752       -3

Impacted Files
Coverage Δ

src/keri/app/delegating.py
80.11% <ø> (ø)

tests/app/test_multisig.py
97.65% <ø> (ø)

tests/core/test_partial_rotation.py
100.00% <ø> (ø)

tests/demo/test_demo.py
99.68% <ø> (ø)

src/keri/core/eventing.py
78.07% <50.00%> (-0.55%)
:arrow_down:

src/keri/core/coring.py
88.68% <97.31%> (+1.54%)
:arrow_up:

tests/core/test_coring.py
99.97% <99.82%> (+<0.01%)
:arrow_up:

src/keri/app/cli/commands/incept.py
88.29% <100.00%> (+0.12%)
:arrow_up:

src/keri/app/cli/common/rotating.py
86.95% <100.00%> (ø)

src/keri/app/habbing.py
82.83% <100.00%> (ø)

... and 18 more

:mega: Codecov can now indicate which changes are the most critical in Pull Requests. Learn more


Add Srinivas Panuganti to Contributors list

@cnuis2cool, I'm quite elated about your PR. I wanna evolve this project to addresses various problems faced by first-time contributors. I'd love to learn about your journey in open source community, the problems, pain points you had etc.
Could you explain how you felt when you went through the tutorial, made a PR and learned that I merged it?


making edits and corrections to the db devops docs

Thanks for contributing to the Harness Developer Hub! Our code owners will review your submission.
Description

Please describe your changes: \ making edits and corrections to the db devops docs
Jira/GitHub Issue numbers (if any): \ DBOPS-326
Preview links/images (Internal contributors only): __________________

PR lifecycle
We aim to merge PRs within one week or less, but delays happen sometimes.
If your PR is open longer than two weeks without any human activity, please tag a code owner in a comment.
PRs must meet these requirements to be merged:

[X] Successful preview build.
[X] Code owner review.
[X] No merge conflicts.
[X] Release notes/new features docs: Feature/version released to at least one prod environment.

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://66b25f8ab3ff5c2ff72ac4c1--harness-developer.netlify.app

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://66b2600dd5440937e2e5dd58--harness-developer.netlify.app

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://66b279784ce5c550f9c9742c--harness-developer.netlify.app

Please check the Execution Link of the Pipeline for the Website Draft URL. This is located in the Preview Step behind the Harness VPN and also is available in #hdh_alerts. E.g Website Draft URL: https://unique-id--harness-developer.netlify.app. Current Draft URL is: https://66b27a05e393784d61a88266--harness-developer.netlify.app


ld: library not found for -lboost_context

When I run the OSX Build Instructions I get this error when I run scons.
ld: library not found for -lboost_context
clang: error: linker command failed with exit code 1 (use -v to see invocation)
scons: *** [build/clang.release/rippled] Error 1
scons: building terminated because of errors.

My .bashrc has the BOOST_ROOT path set.
export BOOST_ROOT=/Users/<<USERNAME>>/dev/boost_1_56_0

Thank you for reporting this. You are likely stumbling because of the confusing language on with the wiki page, which I will update. The boost_1_56_0 bit would be applicable only if you were compiling Boost 1.56.0 (the latest at the time the page was updated). But if you were using, for example, Boost 1.60.0, then it would be boost_1_60_0. Etc.
Can you check which version of Boost you download and compiled?

That fixed it!


Customize ID behavior

There are a few places where the codebase assumes that id is the magic field that can be used to identify an identity. This should be generalized to allow for any field (or a list of fields) to be used

I've started working on this in a branch and need a place to hold onto some thoughts:

a single type could have multiple keys that are used together to form a record's ID
the node query used by refetches should be configurable to allow for specific queries that look up a value.

My current thinking for the API:
config  = {
    types: {
        User: {
            keys: ['email'],
            refetch(user) {
                return {
                    field: "user",
                    arguments: {
                        email: user.email
                    }
                }
            }
        }
    }
}

My Vote...
I like the idea of the defaultKeys - not sure of the name... it might be better to call it defaultKeyField: '_id' as I think the default should only be a single.
And for entity key I would go with keyFields
config  = {
    defaultKeyField: '_id',
    types: {
        User: {
            keyFields: ['email'],
            // not quite sure what to call this
            refetch: {
                queryField: 'user',
                arguments: (user) => {email: user.email}
            },
        }
    }
}

Thanks for the input @lyle! I'm also unsure about the names. I was hoping that "key" implied "keyField" but I guess if a user is coming up to a config file for the first time it might not be totally clear. I'll think on it some more.
Do you have any ideas for what I could use instead of "refetch"? In case it wasn't clear from the example, that object configures the query that the cache uses to support things like paginated fragments. For any object that implements the Node interface, that object would take the default value:
{
    //...
    refetch: {
        queryField: 'node',
        arguments: node => ({ id: node.id })
    }
}


sshWorkerFakeVmPasswordTest false positive; too strict on valid output

Found by Lukasz
currently it is too strict on the expected oup; probably sometimes the error output is slightly different. you can rerun just this test, and then print the output, we will know the other error string.
https://github.com/eBay/parallec/blob/master/src/test/java/io/parallec/core/main/ssh/ParallelClientSshTest.java#L32

I'm glad I could help, even if unwittingly :)

Cannot reproduce it in Travis CI or my local.. will reopen if needed


Use a logging module and make it extensible

Description
This PR introduces a logging module and makes the SDK use that, instead of console.log statements. It also introduces a configuration for SDK users to customize (1) how much data to log, depending on logging levels, and (2) implementation of the logger.
Issue to track docs changes: #288
Issue reference
Please reference the issue this PR will close: #217
Checklist
Please make sure you've completed the relevant tasks for this PR, out of the following list:

[x] Code compiles correctly
[x] Created/updated tests
[ ] Extended the documentation

Looking good! Can we also get the constructor params to be all optional maybe? Wdyt?


attached svg file to png not working

using dotnet 6
using System.Drawing.Imaging;
using System.Xml;
using Svg;

string directory = AppContext.BaseDirectory;
string inputSvgFile = Path.Combine(directory, "input.svg");
string outputPngFile = Path.Combine(directory, "output.png");
string svg = File.ReadAllText(inputSvgFile);

XmlDocument doc = new();
doc.LoadXml(svg);
var svgDoc = SvgDocument.Open(doc);
var bitmap = svgDoc.Draw();
bitmap.Save(outputPngFile, ImageFormat.Png);

input.svg.zip

This looks like the same problem as #1013, I think it's a duplicate.
It also seems to be a regression, at least on version 3.4.1 it still works.
@H1Gdev - maybe you can have a look?

For reference: the problem has appeared after this commit with version 3.4.0. The same is true for the image in #1013.

Image is output in my execution environment.
Since Path Data is as large as 29300, it takes time to generate image.

I have identified process that becomes expensive as number of elements increases.
From now on, I will consider countermeasures.

you can use this code to generate some test svg files:
using Net.Codecrete.QrCodeGenerator;

string directory = AppContext.BaseDirectory;

string outputDir = Path.Combine(directory, "output");
Directory.CreateDirectory(outputDir);

Random rand = new Random(12345);
var queryInputData = Enumerable.Repeat(0, 20000)
    .Select(_ => BitConverter.GetBytes(rand.Next()))
    .SelectMany(x => x);

var queryItems =
    from pair in queryInputData.Chunk(1500)
        .Select((Chunk, Index) => (Chunk, Index))
    let index = pair.Index
    let chunk = pair.Chunk
    let text = Convert.ToBase64String(chunk)
    let qr = QrCode.EncodeText(text, QrCode.Ecc.Medium)
    let Svg = qr.ToSvgString(4)
    let OutputSvgFile = Path.Combine(outputDir, $"test-{index}.svg")
    select new { Svg, OutputSvgFile };

foreach (var item in queryItems)
{
    File.WriteAllText(item.OutputSvgFile, item.Svg);
}

<PackageReference Include="Net.Codecrete.QrCodeGenerator" Version="2.0.3" />


[Feature] Directives configuration file

Submit a feature request or bug report

[x] I've read the guidelines for Contributing to Roots Projects
[x] This is a feature request
[ ] This is a bug report
[x] This request isn't a duplicate of an existing issue
[x] I've read the docs and NPM Debugging Guidelines post and followed them (if applicable)
[x] This is not a personal support request that should be posted on the Roots Discourse forums

What is the current behavior?
Currently there's no convenient way and place to put custom directives (the @asset is created at the end of the app/setup.php)
What is the expected or desired behavior?
It would be good to have something like config/directives.php. See Example

Feature Request

Please provide use cases for changing the current behavior:
It's easier and clearer to define directives in a dedicated file.
Part of my current directives.php:
<?php

$getBladeArgs = function( $expression ) {
	return explode(', ', str_replace(['(', ')'], '', $expression));
};
$fnEndWhile = function () { return '<?php endwhile; wp_reset_query(); ?>'; };

return [
	/*
	|--------------------------------------------------------------------------
	| Directives
	|--------------------------------------------------------------------------
	|
	| Custom directives
	|
	*/

	// Create @asset() Blade directive
	'asset' => function ( $asset ) {
		return "<?php echo " . __NAMESPACE__ . "\\asset_path({$asset}); ?>";
	},

	// Creates @mainquery Blade directive
	 'mainquery' => function () {
		return '<?php while(have_posts()) : the_post(); ?>';
	},

	// Creates @mainquery Blade directive
	'endmainquery' => $fnEndWhile,

	// Creates @customquery(\WP_Query $queryObj) Blade directive
	'customquery' => function( $queryObj ) {
		$output = "<?php while ({$queryObj}->have_posts()) : ?>";
		$output .= "<?php {$queryObj}->the_post(); ?>";
		return $output;
	},

	// Creates @endcustomquery Blade directive
	'endcustomquery' => $fnEndWhile,

	// Create @shortcode($shortCodeString) Blade directive
	'shortcode' => function ( $shortcode ) {
		return "<?php echo do_shortcode({$shortcode}); ?>";
	},

	// Create @set($name, value) Blade directive
	'set' => function ( $expression ) {
		list($variable, $value) = $getBladeArgs($expression);

		// Ensure variable has no spaces or apostrophes
		$variable = trim(str_replace('\'', '', $variable));

		// Make sure that the variable starts with $
		if ( !starts_with($variable, '$') ) {
			$variable = '$' . $variable;
		}
		$value = trim($value);
		return "<?php {$variable} = {$value}; ?>";
	},
];

Other relevant information:
If wanted, I can make a pull request 😃

Maybe at some point I'll create an application container and you can register a proper serviceprovider for things like this, similar to how things are done in Laravel. Until then i'd say to just create a new file if you want a bunch of directives and load that file (from functions.php or whatever) or toss your directives in setup.php if you feel so inclined.

An application container that can register ServiceProviders would be excellent. It'd be nice to be able to use the various Blade extensions as well as be able to depreciate my shitty blade-svg-sage plugin.

+5000 for app container.
Some of our sites have a lot of application code. We abstract as much as possible to private packages but at some point you have to wire up your dependencies and right now the amount of factory classes I have on this one project is just about killing me 😂 .
An app container would be amazing and if you're open to it it's something I would be down to take a stab at.

create an application container and you can register a proper serviceprovider

Huge 👍 too!
What is required to "convert" current container into app container?

@LeoColomb The easiest way would be to include the entire Laravel Framework. The Application container is actually in Illuminate/Foundation and cannot be installed via composer. It is all of the framework or nothing, and that would be more than what Sage really needs.
What Laravel Lumen is doing, is they cherry-picked some components out of Illuminate/Foundation and reworked them. This may be a good starting point for creating a custom Sage Application container, but it is still a lot of work.
@kaisermann @Log1x I have created an extension package for Sage 9 that has built-in Blade directives plus a config file where you can add your own directives. See my GitHub repo Sage Xpress. One special directive @menu is tied into a MenuServiceProvider that renders a menu based on a config file -- pretty trippy and clutter free.

There are other container options out there, such as PHP-DI. No need to go overkill with the Laravel dependencies in order to rework a couple things and wire up something like PHP-DI.

@samrap Sage is already dependent on Illuminate/Container. Any other dependencies are built on that. My Sage Xpress repo already shows how easy it can be done.
My intent for that repo is to extend Sage in its current state.


Callkit not displaying on ios using fcm

I am using fcm push notifications to trigger call both in android and ios. In android it works even when the app is in background, but in ios I am getting push notification but call kit ui is not triggered. Do we need to implement push kit even if fcm package is used ?

I am having same issue and can not solve it for 3 months now :(
On iOS the onBackgroundMessage function from Fcm does't trigger at all. The notification arrive on time but the function doesn't trigger to start the incoming call screen :(
Somebody please share the solution.
thanks

on ios the only way to get push notifications when the app is in the background is to use PushKit

@dadagov125 How to test voip notification? Do you have any idea?


How to specify a different name for the db table that a SQLModel refers to?

First Check

[X] I added a very descriptive title to this issue.
[X] I used the GitHub search to find a similar issue and didn't find it.
[X] I searched the SQLModel documentation, with the integrated search.
[X] I already searched in Google "How to X in SQLModel" and didn't find any information.
[X] I already read and followed all the tutorial in the docs and didn't find an answer.
[X] I already checked if it is not related to SQLModel but to Pydantic.
[X] I already checked if it is not related to SQLModel but to SQLAlchemy.

Commit to Help

[X] I commit to help with one of those options 👆

Example Code
from typing import Optional

from sqlmodel import SQLModel, Field

# If the actual db table is called `assets`, for example, how can I keep the following model named `Product` but have it refer to the correct table?

class Product(SQLModel, table=True):

    id: Optional[int] = Field(None, primary_key=True)
    name: str

Description

I have an existing database with table names that are different than what I would like my model names to be.
The documentation here under the "SQL Table Names" section notes that there will be information on how to do this in the "Advanced Guide," but that section has not been worked on yet...

Operating System
Linux, macOS
Operating System Details
No response
SQLModel Version
0.0.4
Python Version
3.10.0
Additional Context
No response

I tried manually setting __table__ and __tablename__ on the models, but that did not do anything (would be super hacky anyway...).

Seems that setting __tablename__ as part of the class definition worked (at least, it seems to have created the table with the correct name when testing with sqlite):
class Product(SQLModel, table=True):

    __tablename__ = "assets"

    id: Optional[int] = Field(None, primary_key=True)
    name: str

I tried this based on reading this in the sqlalchemy docs: https://docs.sqlalchemy.org/en/13/orm/extensions/declarative/table_config.html
Just to confirm though: is this the recommended way to deal with the scenario?

@taranlu-houzz SQLModel is essentially a combination of SQLAlchemy (for ORM) and Pydantic (for validation).
While not explicitly documented in SQLModel, yes you right that using the tablename attribute will amend the auto generated table name for a class.
You can also see in the doc tests that this attribute is asserted:
https://github.com/tiangolo/sqlmodel/search?q=__tablename__
Finally, in the main codebase, you can see that unless set otherwise, the tablename attribute defaults to the class name lowercased:

@chriswhite199 Thanks for the confirmation. I'd say my questions is resolved now.

If you're using Pylance/Pyright, you should do
__tablename__: str = name_in_database

If you don't include the : str annotation, you'll see the error

Expression of type "str" cannot be assigned to declared type "declared_attr"
"str" is incompatible with "declared_attr"

Credit to @indivisible for https://github.com/tiangolo/sqlmodel/issues/98#issuecomment-996651619

A very convenient way to change the table name generation is overriding the __tablename__ class method. E.g. to convert the class name to snake casing:
from sqlmodel import SQLModel as _SQLModel
from sqlalchemy.orm import declared_attr
from .utils import snake_case

class SQLModel(_SQLModel):
    @declared_attr
    def __tablename__(cls) -> str:
        return snake_case(cls.__name__)

class HTTPProxy(SQLModel):
    ...

print(HTTPProxy.__tablename__)
#> http_proxy

# utils.py
from functools import partial
import re

_snake_1 = partial(re.compile(r'(.)((?<![^A-Za-z])[A-Z][a-z]+)').sub, r'\1_\2')
_snake_2 = partial(re.compile(r'([a-z0-9])([A-Z])').sub, r'\1_\2')

def snake_case(string: str) -> str:
    return _snake_2(_snake_1(string)).casefold()

A SQLModel.Config.tablename_generator prop that accepts a callable (like Pydantic.Config.alias_generator) would be great feature.

If you're using Pylance/Pyright, you should do
__tablename__: str = name_in_database

I'm using Pyright and this doesn't work. When I try it I get the error
"__tablename__" incorrectly overrides property of same name in class "SQLModel" Pylance(reportIncompatibleMethodOverride)

Not sure why this is happening to me but not others. Perhaps I'm on a newer version of Pyright. There are two fixes. First, use declared_attr:
class Lineitem(SQLModel, table=True):
    @declared_attr
    def __tablename__(cls):
        return "invoice_lineitems"

Second, just tell Pyright to ignore it:
    __tablename__: str = (  # pyright: ignore [reportIncompatibleMethodOverride]
        "invoices_legacy"
    )

or just:
    __tablename__: str = "invoices_legacy"  #  type: ignore

I choose this last method because the others are far too verbose for something as simple as declaring the table name. This may seem hacky, but although I have to tell Pyright to ignore a number of things in sqlmodel, it's not half the file like I have to type: ignore with sqlalchemy.
As I suggested in https://github.com/tiangolo/sqlmodel/issues/98, a more intuitive solution that would make Pyright happy might be putting the table name declaration in a Meta as ormar does:
class Lineitem(SQLModel, table=True):
    class Meta:
        tablename: str = "invoice_lineitems"

I tried
class SQLModel(_SQLModel):
    @declared_attr
    def __tablename__(cls) -> str:
        return snake_case(cls.__name__)

But mypy complained that
Signature of "__tablename__" incompatible with supertype "SQLModel"

@kingyue737 In the base code, typing is ignored.
class SQLModel(_SQLModel):
    @declared_attr  # type: ignore
    def __tablename__(cls) -> str:
        return snake_case(cls.__name__)

@kingyue737, in my code i usually just have to explicitly type the class attribute to keep mypy happy:
class MyModel(SQLModel, table=True)
  __tablename__: ClassVar[str] = 'my_model'

  # ...

What do you think of using the Pascal case instead lowercase or snake case? It can be more intuitive on foreign_key due to already class name is in pascal and cruds are in pascal either.
class SQLModel(_SQLModel):
    @declared_attr  # type: ignore
    def __tablename__(cls) -> str:
        return cls.__name__

class RoleBase(SQLModel):
    name: str
    description: str

class Role(RoleBase, table=True):
    users: List["User"] = Relationship(back_populates="role", sa_relationship_kwargs={"lazy": "selectin"})

class UserBase(SQLModel):
    first_name: str
    last_name: str
    email: EmailStr

class User(UserBase, table=True):
    role_id: Optional[UUID] = Field(default=None, foreign_key="Role.id")
    role: Optional["Role"] = Relationship(back_populates="users", sa_relationship_kwargs={"lazy": "selectin"})

users =  await db_session.execute(select(User).where(User.email == email))

Thanks for the help and discussion here everyone! 👏  🙇
Thanks for reporting back and closing the issue @taranlu-houzz  👍

I know setting the table name through __tablename__ does the trick, but it is very much not like using pydantic.
Is it possible to replicate the Config in Pydantic so that we can pass extra parameters related to the database? That way, we can create a Config inner class to which we can add any configuration we need that is not supported by Pydantic, like the table name. Seems like a weird mix to be able to treat the objects as pedantic objects but at the same time have these old-looking APIs from SQLalchemy.
If that is something you would be willing to consider, I could try to take a look and see how hard it would be to implement.

I know setting the table name through __tablename__ does the trick, but it is very much not like using pydantic.
Is it possible to replicate the Config in Pydantic so that we can pass extra parameters related to the database? That way, we can create a Config inner class to which we can add any configuration we need that is not supported by Pydantic, like the table name. Seems like a weird mix to be able to treat the objects as pedantic objects but at the same time have these old-looking APIs from SQLalchemy.
If that is something you would be willing to consider, I could try to take a look and see how hard it would be to implement.

not implement yet?

I know this is closed already but just in case anyone else winds up here-- this worked without any type: ignore comments for me
    __tablename__: typing.ClassVar[
        typing.Union[str, typing.Callable[..., str]]
    ] = "your_table_name"

sorry, for me your version does not work:

├╴  "__tablename__" overrides symbol of same name in class "SQLModel"
│      Variable is mutable so its type is invariant
│        Override type "str | ((...) -> str)" is not the same as base type "declared_attr[Unknown]" basedpyright >> (reportIncompatibleVariableOverride) [31, 5]


Specify which main.py functions to run when setting workflows

This way - You can create different workflow on ocp-python-wrapper, that rely on main.py

please change pr_action.yml to use this as well


Declare strstrip for picky compilers

Hi,
Here's a trivial patch needed for really picky compiler flags (i.e. mine :-) ).

@dllaurence Indeed your compiler seems really picky ! ^^
Can you provide me some information about it and the logs of your failed compilation. I'd like to see if we could think of a more elegant solution.

More elegant solution:
static unsigned strstrip(char * s)
{
    // ...
}


[web]: screenshot RepaintBoundary contains Image  don't work

RepaintBoundary contains Image  don't work
RepaintBoundary contains Canvas(image)   don't work
Canvaskit no warning, Html render null Exception!
Other platform is fine!
Obx(() {
return RepaintBoundary(
key: logic.out_key,
child: Container(
alignment: Alignment.center,
width: 500,
height: 500,
child: Column(
children: [
Image.asset("/images/little.jpeg")
,Text(state.back_img.value.toString())
// CustomPaint(
//   painter: MyImgPaint(state.back_img.value),
//   // foregroundPainter: MyImgPaint(state.foreground_img.value),
//   child: Image.asset("/images/little.jpeg"),
// ),
],
),
),
);
})
[✓] Flutter (Channel stable, 3.3.8, on macOS 12.6.1 21G217 darwin-x64, locale zh-Hans-CN)
• Flutter version 3.3.8 on channel stable
• Upstream repository https://github.com/flutter/flutter.git
• Framework revision 52b3dc25f6 (13 days ago), 2022-11-09 12:09:26 +0800
• Engine revision 857bd6b74c
• Dart version 2.18.4
• DevTools version 2.15.0
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
• Android SDK at
• Platform android-33, build-tools 33.0.0
• Java binary at:
• Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)
• All Android licenses accepted.
[✓] Xcode - develop for iOS and macOS (Xcode 14.1)
• Xcode at /Applications/Xcode.app/Contents/Developer
• Build 14B47b
• CocoaPods version 1.11.3
[✓] Chrome - develop for the web
• Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome
[✓] Android Studio (version 2021.3)
• Android Studio at
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
• Java version OpenJDK Runtime Environment (build 11.0.13+0-b1751.21-8125866)
[✓] IntelliJ IDEA Ultimate Edition (version 2022.2.3)
• IntelliJ at
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
[✓] IntelliJ IDEA Ultimate Edition (version 2022.2.3)
• Flutter plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/9212-flutter
• Dart plugin can be installed from:
🔨 https://plugins.jetbrains.com/plugin/6351-dart
[✓] Connected device (2 available)
• macOS (desktop) • macos  • darwin-x64     • macOS 12.6.1 21G217 darwin-x64
• Chrome (web)    • chrome • web-javascript • Google Chrome 107.0.5304.110

@tv009 thanks for providing sample code. But I think it relates to CORS issue rather than RepaintBoundary. When removing RepaintBoundary, the image also can not display and there is exception log from the console.

Exception logs
An Observatory debugger and profiler on Chrome is available at: http://<IP_ADDRESS>:51980/ect3YGMI-Oo=
══╡ EXCEPTION CAUGHT BY IMAGE RESOURCE SERVICE ╞════════════════════════════════════════════════════
The following ImageCodecException was thrown resolving an image codec:
Failed to load network image.
Image URL<EMAIL_ADDRESS>Trying to load an image from another domain? Find answers at:
https://flutter.dev/docs/development/platform-integration/web-images

When the exception was thrown, this was the stack

Image provider<EMAIL_ADDRESS>scale: 1)
Image key<EMAIL_ADDRESS>scale: 1)
════════════════════════════════════════════════════════════════════════════════════════════════════
The Flutter DevTools debugger and profiler on Chrome is available at: http://<IP_ADDRESS>:9100?uri=http://<IP_ADDRESS>:51980/ect3YGMI-Oo=

When using another image (for eg this image), the issue is not reproducible.

Demo (another image source)

Sample code
import 'dart:typed_data';
import 'dart:ui' as ui;

import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      title: 'Flutter Demo',
      theme: ThemeData(
        primarySwatch: Colors.blue,
      ),
      home: const MyHomePage(title: 'Flutter Demo Home Page'),
    );
  }
}

class MyHomePage extends StatefulWidget {
  const MyHomePage({super.key, required this.title});
  final String title;
  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  Uint8List bytes = Uint8List(0);
  var rbkey = GlobalKey();
  @override
  Widget build(BuildContext context) {
    return Scaffold(
      body: SingleChildScrollView(
        child: Column(
          mainAxisAlignment: MainAxisAlignment.start,
          children: <Widget>[
            RepaintBoundary(
              key:rbkey,
              child: Column(
                children: [
                  const Text(
                    'I can show below',
                  ),
                  Image.network("https://www.online-image-editor.com/styles/2019/images/power_girl.png"), //but Image don't show below
                ],
              ),
            ),

            ElevatedButton(onPressed: (){
              fetchData(rbkey).then((value) =>
                  setState(() {
                    bytes = value;
                    print(bytes);
                  })
              );
            }, child: Text("press me")),
            if(bytes.isNotEmpty)Image.memory(bytes)
          ],
        ),
      ),
    );
  }
}

Future<Uint8List> fetchData(GlobalKey key) async {
  var boundary = key.currentContext!.findRenderObject()! as RenderRepaintBoundary;
  final ui.Image image = await boundary.toImage();
  final ByteData? byteData = await image.toByteData(format: ui.ImageByteFormat.png);
  final Uint8List pngBytes = byteData!.buffer.asUint8List();
  return pngBytes;
}

This is also a known issue #92344. Please check flutter docs rendering images on the web as a reference for this.
Closing, as this isn't an issue with Flutter itself. If you disagree, please write in the comments and I will reopen it. Thank you!

The following code contains local images
`import 'dart:typed_data';
import 'dart:ui' as ui;
import 'package:flutter/material.dart';
import 'package:flutter/rendering.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({super.key});
// This widget is the root of your application.
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Demo',
theme: ThemeData(
primarySwatch: Colors.blue,
),
home: const MyHomePage(title: 'Flutter Demo Home Page'),
);
}
}
class MyHomePage extends StatefulWidget {
const MyHomePage({super.key, required this.title});
final String title;
@override
State createState() => _MyHomePageState();
}
class _MyHomePageState extends State {
Uint8List bytes = Uint8List(0);
var rbkey = GlobalKey();
@override
Widget build(BuildContext context) {
return Scaffold(
body: Column(
mainAxisAlignment: MainAxisAlignment.start,
children: [
RepaintBoundary(
key:rbkey,
child: Column(
children: [
Image.asset('/images/little.jpeg',width:100,height:100),
const Text(
'I can show below',
),
Image.network("https://www.online-image-editor.com/styles/2019/images/power_girl.png"
,width: 100,height: 100,), //but Image don't show below
],
),
),
      ElevatedButton(onPressed: (){
        fetchData(rbkey).then((value) =>
            setState(() {
              bytes = value;
              print(bytes);
            })
        );
      }, child: Text("press me")),
      if(bytes.isNotEmpty)Image.memory(bytes)
    ],
  ),
);

}
}
Future fetchData(GlobalKey key) async {
var boundary = key.currentContext!.findRenderObject()! as RenderRepaintBoundary;
final ui.Image image = await boundary.toImage();
final ByteData? byteData = await image.toByteData(format: ui.ImageByteFormat.png);
final Uint8List pngBytes = byteData!.buffer.asUint8List();
return pngBytes;
}
`
CORS issue will cause the above figure to be unable to be displayed, so I don't agree with you. I now suspect that there is something wrong with my environment
Thank you again for your attention

A solution has been found. The same code Windows compiles normally, but the mac compiles abnormally!
@huycozy


Create package object-store-harvestor:FileWalker

based on https://github.com/AAFC-BICoE/object-store-harvestor/blob/dev/doc/design.md
Phase 1: Initial File walker package
add functionality to recursively traverse directories and find media files from any given entry point(will be provided by config)
for each file populate structs  : OSFile, FileMetadata (will be used later on in DB)
nice to have for Phase 1 : add basic validation functionality with a possibility to load some values from a config

all requirements are done
File walker package has been created and tested e2e


MODE-2664 Fixes various issues with SQLServer support

The fixes include:

making sure CREATE and DROP table statements correctly detect existing objects
using correct syntax for DB locking
using the correct binary type for storing schematic documents

will try it out. TY


Indent Error for Platform Names in Client

There is an indent error that is prohibiting the usage of the metriq client.

Closed from https://github.com/unitaryfund/metriq-client/pull/104


SQL/PGQ or even GQL support

Is your feature request related to a problem or challenge?
SQL (standard) was recently extended with property graph querying features (PGQ): ISO standard, theoretical foundations. I wonder if DataFusion can be extended with PGQ.
Describe the solution you'd like
All parts should be extended. The most nontrivial part is interconnection between traditional SQL and graph analysis (path-related evaluations). While it is possible to store graph in columnar storage (e.g. Apache Arrow), it may be inefficient for path-related queries (while pretty efficient for attributes-of-vertex-related analytical queries). So, specific path-indexes may be required. Even more, in some cases it may be good idea to store graph topology in separated storage in specific format (e.g. sparse adjacency matrix, similar to FalkorDB).
On the other hand, even if we store graph in columnar storage, linear-algebra-related primitives can be useful for path querying (DuckPGQ: Efficient Property Graph Queries in an analytical RDBMS).
So, logical and physical plans should provide not only specific operators, but support balancing between data representation.
Describe alternatives you've considered
No response
Additional context
Can something like this project be used for physical level of linear algebra?
Possible theoretical foundations.
It may be a first step to support GQL.
I'm interested in such a system design and development, but I'm aware that such an extension of DataFusion may leads to system recreation. So, I want to discuss this direction: should we extend DataFusion or create new independent system.

Possible steps.

Extend SLQ parser with PGQ support Independent task. Technical.
Express PGQ in terms of existing operations. As shown in GQL and SQL/PGQ: Theoretical Models and Expressive Power, core PGQ can be translated to standard relational algebra (plus recursion). It may be not optimal in terms of performance, but can be a baseline for analysis and further optimizations. Technical.
Advanced techniques introduction. For example, linear algebra utilization as a physical implementation of some operation. Respective logical plan extension. It is a topic for research.

So, the first and the second can be done as a technical tasks, and after that possible directions should be discussed.
Additionally for discussion: TenSQL: An SQL Database Built on GraphBLAS that shows linear algebra as a physical level can improve performance of some SQL queries in some cases.

As mentioned before, SQL/PGQ could be expressed with relational algebra operations plus recursion.
Though, as it's mentioned in the issue on recursive CTEs (#462) they tend to be quite slow. Implementing one of the graph querying languages using this feature may require performance improvements to make consequent JOINs execute in decent time.


Sidekiq Stats Collector Memory Leak

Hello there,
we have Investigated an Issue with one of our prometheus_exporter Setups which stopped working.
After a certain perioud of runtime the collector started to report collector_working with Value 0 and all our Instrumentation Metrics went missing.
The only difference we found to another Setup of our which has no issues was the usage of the SideKiqStats Instrumentation so we looked into that.
It seems that here new observations are added to the sidekiq_metrics object which results in it getting bigger and bigger.
After a certain amount of time the Collector is not able to generate the Metric Text withing the configured default Timeout of 2 Seconds and we start seeing the above mentioned behavior.
As a comparison the SidekiqQueueCollector seems to have a mechanism to clean up older Observations.
Our guess would be that the SidekiqStatsCollector would need something like that too.

Does #256 close this issue?


Suggestions for Chapter 5: Advanced Modelling

[ ] Structure: It could be beneficial to rearrange the topics here: specifically, I suggest putting the Intervals section right after Tour constraints. Scheduling is one of the most used applications of OR-Tools, while automaton/reservoir constraints seem more niche to me.

[ ] Question: There are a lot of different interval variable creation methods (fixed size, optional, etc.). Are they different from each other or is it just a simple interface? For instance, you can also pass constant values to the start/end/size arguments in new_interval_var. I would assume that preprocessing takes care of the redundancies but I'm not sure about that.

The new_optional_interval_var is the most expressive but also the most expensive, while the new_fixed_size_interval_var is the least expressive and the easiest to optimize.

[ ] Content: In my opinion, it is a bit much to describe all types of intervals here. Only keeping variable-sized interval variables should be enough to explain the concept of interval variables, while the fixed-size types can be briefly mentioned in a line or two afterwards (and the reason when to use fixed-size intervals). (Note: My perspective mostly comes from OR-Tools' machine scheduling examples which don't use fixed-size intervals.)

Regarding the structure: True. It made sense while these sections where very short as they seemed completely lost at the end. With the current text (and maybe soon a more extensive example), it makes sense to push them further to the end.

Regarding the question: Actually, the restricted versions just enter constants into the generic version. However, one reason to keep them is that it can be very beneficial to explicitly use the most restricted versions as this makes it easier to directly see potential complexities in your model. My students have often created creatively bad models because they see a complex constraint and try to use it to its full expressiveness. So, this is less about teaching intervals and more about teaching this soft skill. I also like to start with the simpler versions, which already allow to do cool stuff and then go into how to suddenly do complex stuff like packing with rotations with them. Another soft skill I wanted to teach here is that one should not have a too narrow view on variables and constraints (like assuming intervals are always time), as this is another common issue students have had.

Regarding fixed-size intervals, they are actually quite useful in timetable scheduling, which is a common use case for CP-SAT, which is why I did an explicit example on them.

Just a quick heads-up: tomorrow I'll take the afternoon to work on this and #49 :)

I only addressed the first comment in #55. I agree with your comments related to using the simpler interface!


Losing operator call when one of operands is application of a partially applied function

This code:
let f x y = x+y
let g = f 1
let h = (g 2) + 3

Produces TAST without the last (+) call:
    Application
        (Call (null,val g,[],[],[]),[],[Const (2,type Microsoft.FSharp.Core.int)])

If I make g a normal function (i.e. let g x = f 1 x), the problem disappears.
If I make g a value (i.e. let g = 5), the problem disappears.

It's possible this is the same bug as https://github.com/fsharp/FSharp.Compiler.Service/issues/543

Fixed by https://github.com/fsharp/FSharp.Compiler.Service/pull/549

Fix is in <IP_ADDRESS>

Awesome, thank you!

Hmmm, but now it generates some extraneous lambdas where none are required.
For example:
      let f x = x+5
      let g f y = f y
      let h = g f 42

<IP_ADDRESS> produces:
Call
  (null,val g,[],[type Microsoft.FSharp.Core.int; type Microsoft.FSharp.Core.int],
   [Lambda (val x, Call (null,val f,[],[],[Value val x]));
    Const (42,type Microsoft.FSharp.Core.int)])

But <IP_ADDRESS> produces:
Call
  (null,val g,[], [type Microsoft.FSharp.Core.int; type Microsoft.FSharp.Core.int],
   [Value val f; Const (42,type Microsoft.FSharp.Core.int)])

This is by design for first-class uses of all members and module-bound functions.  The expansion was always being applied when some arguments were present - it is now applied all the time even when no arguments are given.

Ok, thanks.