Fix: reload and merge easy-install pth file before save

Summary of changes
Refactor PthDistributions._load into/with a second _load_raw. Re-use _load from PthDistributions.save().
and thus use that in save() to reload/refresh the file content before saving. and merge the eventual new found items.
Closes #3126

Hi @gst thank you very much for the PR! Any help is very appreciated.
I probably lack the knowledge to properly review your PR, so I will leave that for the other maintainers.
But something that would really help is if you can add a test case capturing the failing behaviour you are trying to solve.

Hi @abravalheri
I have got this :
    def test_many_pth_distributions_merge_together(self, tmpdir):
        pth_path = tmpdir.join("file1.pth")
        pth1 = PthDistributions(pth_path)
        pth2 = PthDistributions(pth_path)
        new_path = tmpdir.join("foobar")
        new_path.mkdir()  # must exist
        pth2.paths.append(str(new_path))
        pth2.save()
        new_path_str = str(new_path)
        assert new_path_str not in pth1.paths
        pth1.save()
        assert new_path_str in pth1.paths, "the new_path should have been added by pth1 as well"

that I added in setuptools/tests/test_easy_install.py but I can't succeed to make it run right now..
I'm not used to run setuptools tests I guess ;)

Hi @gst.
Something that is useful to run is flake8 setuptools (pytest-flake8 errors are quite cryptic, so you can solve that first before running the tests).
If you have tox installed, I would suggest running tox -- -p no:cov first (coverage will add a lot of noise) and then if everything passes just tox. You can also add -x and the specific test file if the tests are too slow in your machine (e.g. tox -- -p no:cov -x setuptools/tests/test_easy_install.py).

Could you add a little comment/note in this test explaining in which scenario the PthDistributions would be duplicated?

        pth1 = PthDistributions(pth_path)
        pth2 = PthDistributions(pth_path)

(That is a way of signing for people changing this file in the future why this test should not be removed).

(By the way, thank you very much for working in a test case, that really helps in the PR and to better understand the problem).

That's my pleasure :)
but I cannot get the test to succeed still.. I'm doube checking..
but it's not easy with tox I find. any direct python call that I could pdb with ?

but it's not easy with tox I find. any direct python command that I could pdb with ?

That is a tricky question.
I usually rely on pytest's ability to open pdb on failure, e.g.:
tox -- -p no:cov -x --pdb setuptools/tests/test_easy_install.py

If you want to avoid tox completely it is more complicated... I imagine you can create a virtualenv install .[testing] inside of it and then proceed running:
pytest -p no:cov -x --pdb setuptools/tests/test_easy_install.py

(I never tested this way of running the tests though).

Hi, any comment on the test case and the change/fix(or enhancement?) ?

Hi @gst, I will have a look on the test case, thank you very much!
Unfortunately, I will have to leave further review to other maintainers because this topic is a bit out of the areas of setuptools I am familiar with.
I you need these changes in your workflow urgently, there are a few workarounds that you can use while this PR gets reviewed. For example, in your pyproject.toml you can use:
[build-system]
requires = [
    "setuptools @ git+https://github.com/gst/setuptools@fix-easy-install-pth-file-not-reloaded-before-save",
    ...
]

Currently, the CI seems to be unhappy.
I recommend always running flake8 setuptools and tox (the full test suite) before pushing.
Of course you just run pytest locally while working on the changes (so you can have quick feedback), but it is good to run tox once you are finished to make sure everything is in a good shape (and avoid unexpected CI errors).

@abravalheri I made the first changes you proposed.
I ran tox locally and everything succeed but 2 test cases .. not related.
I'm waiting anymore comments or review.

Thank you very much @gst, that is really appreciated.
Just a minor comment: flake8 seems to be still unhappy 😅.

@abravalheri that's flaked now ;)

Overall, this change looks reasonable. I'm sorry the pytest-flake8 reporting is so bad (due to https://github.com/tholo/pytest-flake8/issues/81). I'll try to review this soon.

I found https://github.com/tholo/pytest-flake8/issues/22, which shows some users having difficulty with pytest-flake8 getting it to honor the settings, so maybe that's what's happening.

Nah. I'll deal with that separately.

ping


cc2652r ZNP and sampleLamp example not reflect on hassio

hi,

TI cc2652r ZNP works with zigbee2mqtt-edge addon but, not work with zigbee2mqtt addon.
error to start zigbee shepherd -- SAPI RSP timeout.
Checked with z-tool ping cmd but SAPI is not listed.
Is it a problem of ZNP firmware or hassio zigbee2mqtt? and what needs to be change to get it working.

successfully connect sample light example with the zigbee2mqtt-edge. lamp on and off from hassio.
But when lamp toggle from the device is not reflected to hassio gateway. Try to send the command to the gateway but fails.
form zigbee - converter
livolo_switch_dev_change: {
cid: 'genOnOff',
type: 'devChange',
convert: (model, msg, publish, options) => {
const status = msg.data.data.onOff;
const payload = {};
payload['state_left'] = status & 1 ? 'ON' : 'OFF';
payload['state_right'] = status & 2 ? 'ON' : 'OFF';
if (msg.endpoints[0].hasOwnProperty('linkquality')) {
payload['linkquality'] = msg.endpoints[0].linkquality;
}
return payload;
},
},
please help me to send device lamp on/off cmd from device to gateway.So it will reflect switch status on dashboard.
i have not found zcl frame of cid-genonoff with type - devChange.

After update zigbee2mqtt addon to version 1.4.0. zigbee2mqtt start working without any issue.
where I can configure custom device which automatically discovers in MQTT broker?
like below in zigbee2mqtt addon: (http://www.zigbee2mqtt.io/integration/home_assistant.html)
TI0001 (with a different device name)
switch:

platform: "mqtt"
state_topic: "zigbee2mqtt/<FRIENDLY_NAME>"
availability_topic: "zigbee2mqtt/bridge/state"
payload_off: "OFF"
payload_on: "ON"
value_template: "{{ value_json.state_left }}"
command_topic: "zigbee2mqtt/<FRIENDLY_NAME>/left/set"

switch:

platform: "mqtt"
state_topic: "zigbee2mqtt/<FRIENDLY_NAME>"
availability_topic: "zigbee2mqtt/bridge/state"
payload_off: "OFF"
payload_on: "ON"
value_template: "{{ value_json.state_right }}"
command_topic: "zigbee2mqtt/<FRIENDLY_NAME>/right/set"

sensor:

platform: "mqtt"
state_topic: "zigbee2mqtt/<FRIENDLY_NAME>"
availability_topic: "zigbee2mqtt/bridge/state"
unit_of_measurement: "-"
value_template: "{{ value_json.linkquality }}"

also let me know how to define const mapping for the same device.
where I can add in zigbee2mqtt addon?


Master

Please can you describe what this add/removes/changes?

Hi, I'm not sure what this PR is about. I'm closing it for now, if you want to re-open with a clean description and cleaned up commits we will take another look.
Thanks,
Andy


Unable to run setup script in ubuntu

Hey sorry to bother but I got a new computer running ubuntu that i'm trying to get things running on and i'm hitting this error:
gregg@goldman:~/Development/website$ ./script/setup
==> Installing Bundler...
Successfully installed bundler-1.16.1
Parsing documentation for bundler-1.16.1
Done installing documentation for bundler after 2 seconds
1 gem installed
==> Installing gem dependencies...
==> Setting up DB...
rails aborted!
PG::ConnectionBad: fe_sendauth: no password supplied
bin/rails:4:in `require'
bin/rails:4:in `<main>'
Tasks: TOP => db:drop => db:check_protected_environments
(See full trace by running task with --trace)

Any ideas? Googling is talking about TCP and i don't really know what I need to do

i edited database.yml
default: &default
  adapter: postgresql
  encoding: unicode
  pool: <%= ENV.fetch("RAILS_MAX_THREADS") { 5 } %>

development:
  <<: *default
  host: ''
  database: crimethinc_development

test:
  <<: *default
  host: ''
  database: crimethinc_test

so now it correctly creates the database, now i'm hitting another issue with one of the migrations
gregg@goldman:~/Development/website$ rake db:migrate
==<PHONE_NUMBER>1238 CreateSearchResults: migrating ==============================
-- create_view(:search_results, {:materialized=>true})
rake aborted!
StandardError: An error has occurred, this and all later migrations canceled:

PG::UndefinedFunction: ERROR:  function array_to_tsvector(character varying[]) does not exist
LINE 10:   setweight(array_to_tsvector(tag_names), 'D') ||
                     ^
HINT:  No function matches the given name and argument types. You might need to add explicit type casts.
 You might need to add explicit type casts.
 You might need to add explicit type casts.
/home/gregg/Development/website/db/migrate/20170517041238_create_search_results.rb:3:in `change'
Tasks: TOP => db:migrate
(See full trace by running task with --trace)

The version shipping with ubuntu 16.04 is 9.5. Following the instructions here:
https://www.postgresql.org/download/linux/ubuntu/
I upgraded to postgres 10 and still had the issue.

The version shipping with ubuntu 16.04 is 9.5. Following the instructions here:
https://www.postgresql.org/download/linux/ubuntu/
I upgraded to postgres 10 and still had the issue.
➜  website git:(master) ✗ psql -V
psql (PostgreSQL) 10.1

@veganstraightedge do you know the version of postgresql we are using in prod?

Nevermind, I found the missing function was introduced in 9.6. I fully uninstalled 9.5 and made sure it was running on the right port and now we are good.
If anyone ever needs help running the environment on ubuntu let me know lol


make type reentrant

We use an autoloader so in the middle of RDL type checking something it might const_get into some other file which does more type annotations so this function has to be reentrant. Thankfully it was a straightforward fix.
The old error was
  1) Error:
TestTypecheck#test_reentrant:
RuntimeError: can't add a new key into hash during iteration
    /Users/pt/.rbenv/versions/2.4.1/lib/ruby/2.4.0/set.rb:331:in `add'
    /Users/pt/stripe/rdl/lib/rdl/wrap.rb:350:in `type'
    test/test_typecheck.rb:1931:in `const_missing'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:1523:in `const_get'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:1523:in `block (2 levels) in find_constant'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:1523:in `each'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:1523:in `inject'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:1523:in `block in find_constant'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:1522:in `each'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:1522:in `find_constant'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:601:in `tc'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:247:in `block in typecheck'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:226:in `each'
    /Users/pt/stripe/rdl/lib/rdl/typecheck.rb:226:in `typecheck'
    /Users/pt/stripe/rdl/lib/rdl/wrap.rb:551:in `block in do_typecheck'
    /Users/pt/.rbenv/versions/2.4.1/lib/ruby/2.4.0/set.rb:324:in `each_key'
    /Users/pt/.rbenv/versions/2.4.1/lib/ruby/2.4.0/set.rb:324:in `each'
    /Users/pt/stripe/rdl/lib/rdl/wrap.rb:550:in `do_typecheck'
    test/test_typecheck.rb:1938:in `test_reentrant'

(to make the tests pass this needs my constant lookup fixes from https://github.com/plum-umd/rdl/pull/45)

This fix looks good but there's something weird with the test. It's failing on a random assortment of Ruby versions with an error about the `allocate' method of TestTypecheck::Reentrant:Module.
I don't have any great suggestions for alternative test cases. Perhaps a gross hack, like add a "secret" parameter to type that will do some behavior that can be used for testing it, like call a code block while type is executing. That way the test wouldn't need to rely on any subtle Ruby behavior that apparently changes a bit from version to version...?


Add aliases, created_by, related, and full name to topic "PHP"

Please confirm this pull request meets the following requirements:

[x] I followed the contributing guidelines: https://github.com/github/explore/blob/main/CONTRIBUTING.md.
[x] I am not the sole author or employee of a company who created the topic or collection I am changing.

Which change are you proposing?

[x] Suggesting edits to an existing topic or collection
[ ] Curating a new topic or collection
[ ] Something that does not neatly fit into the binary options above

Editing an existing topic or collection
I'm suggesting these edits to an existing topic or collection:

[ ] Image (and my file is *.png, square, dimensions 288x288, size <= 75 kB)
[x] Content (and my changes are in index.md)

This topic looked like GitHub was one of the ones to only know PHP for its shortcomings, not beyond PHP 7—and clearly, we can't have that 😉

Curating a new topic or collection

[ ] I've formatted my changes as a new folder directory, named for the topic or collection as it appears in the URL on GitHub (e.g. https://github.com/topics/[NAME] or https://github.com/collections/[NAME])
[ ] My folder contains a *.png image (if applicable) and index.md
[ ] All required fields in my index.md conform to the Style Guide and API docs: https://github.com/github/explore/tree/main/docs

Please replace this line with an explanation of why you think this topic or collection should be curated.

Something that does not neatly fit into the binary options above

[ ] My suggested edits are not about an existing topic or collection, or at least not a single one
[ ] My suggested edits are not about curating a new topic or collection, or at least not a single one
[ ] My suggested edits conform to the Style Guide and API docs: https://github.com/github/explore/tree/main/docs

Please replace this line with an explanation of your proposed changes.

Please note: we will close your PR without comment if you do not check the boxes above and provide ALL requested information.

Yeah, that's always the problem: We can't prevent people from using them, but apparently they do use them 🤷🏻
I'll be happy when GitHub comes up with some kind of helper/notification/bot, that guides people towards choosing better topics for their repositories 😉


RFC: Service detach until

Graph Execution is awesome!
What about add limit for service execution?
For example i need database and other infrastructure only for testing, but testing is not end of pipeline. I want to free resource immediately as it no more necessary.
---
kind: pipeline
type: docker
name: default

steps:
- name: database
  image: mariadb
  detach:
    until:
      - unit
      - e2e

- name: install
  image: node
  commands:
  - npm install

- name: unit
  image: node
  commands:
  - npm test

- name: e2e
  image: node
  commands:
  - npm e2e

- name: build / push / deploy / notify / something else
  ...

You should use different pipelines.

@tboerger hmm.. i guess it should work, but it will require repeat installation in every pipeline as it not share state..


docs: fix an unpaired backticks problem

@Chasing1020 Thanks. Please follow the DCO check details link to pass it.


Heads-Up: Copy edits

Docs Build status updates of commit 3ab5473:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

mixed-reality-docs/directx-development-overview.md
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

Docs Build status updates of commit 761d891:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

mixed-reality-docs/directx-development-overview.md
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

Docs Build status updates of commit ccf5829:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

mixed-reality-docs/directx-development-overview.md
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.


request_views() retrieving significance levels

When using request_views() the way users need to name significance levels for retrieval is too exact. Currently we have to say exactly .10 and cannot say simply .1 which is arguably what many people would more intuitively expect to work.
Similarly, we should allow low, mid and high as names for .1, .05 and .01 respectively.

Resolved by #73


type为number的input表单绑定数据后输入“0”开头的数字无法保留“0”

Vue.js version
vue-cli: v2.7.0
vue: v2.1.7
Reproduction Link
http://codepen.io/mqhe2007/pen/Kadaoe
Steps to reproduce
What is Expected?
需要输入“012345”这6个数字
为什么我一定要设置type为number呢，因为移动端项目，我需要默认弹出数字键盘，只能输入数字。
What is actually happening?
实际上结果却是“12345”

You have set input type to number.

@znck After reading the doc, I don't think it is an expected behavior.  We should cast the result to number if and only if .number modifier is on. Because native input element allows user to input leading zero. @defcc should know it better.

Currently Vue handles .number and the input with number type in the same logic. Maybe we need to improvement the behavior to keep consistence with native number type input.

Because native input element allows user to input leading zero.

It does, but will revert to a real number (12345 instead of 012345). Basically, the value in <input type="number"> is always treated as Number. So I'd say the current behavior is correct.

I think it's good to remove leading zeros from the number. If you need leading zeros for a number you probably want to use the type="tel" on the input, don't you?

What about something like social security number?

What about something like social security number?

It's not a Number per-se. The value of a ` field is a floating-point number, as per specs.

I'd say it's the same: not a number (in its strict meaning 😆 ) I'd use the type=tel for that one aswell

Close per spec se

The type=number state is not appropriate for input that happens to only consist of numbers but isn’t strictly speaking a number. For example, it would be inappropriate for credit card numbers or US postal codes.

Alternatives can be found here http://stackoverflow.com/questions/3368546/what-input-field-type-forces-the-number-pad-mobile-keyboard-to-come-up-when-focu


Fix incorrect case with SDLHMIZoneCapabilities

WARNING: This is a backward-incompatible change
The case of the file and class are different. This resolves that change by making the acronym for HMI fully uppercase, changing the class to match the file.

Consider resolving via #71


Compile PHASE to RZ

The translation employed here is pretty interesting. When you look at
the matrices of
    PHASE(θ) = | 1  0   |
               | 0  eⁱᶿ |

and
    RZ(2α) = | e⁻ⁱᵅ  0   |
             | 0     eⁱᵅ |

you might notice that PHASE is equivalent to RZ × e^(iθ/2). So you
seek how to write the follow gate in terms of Quil's native gates
    RZ(β) = | eⁱᵝ  0   |
            | 0    eⁱᵝ |.

Then it's problem solved.
Instead, remember that during measurement, any phase factor is
irrelevant! Hence PHASE ≡ RZ × e^(iθ/2) ≡ RZ.
This closes #57.

High quality unicode.


Is it possible to integrate this with ngrx-forms?

Question
I would love to use ngx-formly and ngrx-forms together. I know you can implement ngrx separately but this library ngrx-forms does a good job at removing a lot of boiler plate code for ngrx on forms. Is it possible to use ngrx-forms state/form control in place of the normal FormControl on ngx-formly?
https://ngrx-forms.readthedocs.io/en/master/user-guide/
A clear and concise description of what the question is.

It may be possible but I may need to find some spare time to play with ngrx-forms!

Is there anything I can do on my side to test this?

Right now, I have no idea :pray:!

Thanks! Really quick non-sequitur. Is there a pre-built form builder library out there for this awesome forms library?

https://github.com/franzeal/ngx-formly-designer

The integration is somehow not as easy as I was thinking, so I'm going to close this issue as resolved.

The integration is somehow not as easy as I was thinking, so I'm going to close this issue as resolved.


Custom validation name should not contain colon ':'

I found a case when I can't use the input value to validate form field, because it is formatted. I want to validate the unformatted value of formated number field (react-number-format) by a dynamic minimum value. So I try to make custom validation below.
const minNumber = (min) => `minimum:${min}`;

// ---
const [value, setValue] = useState('');
const [min, setMin] = useState(10);

useEffect(() => {
    ValidatorForm.addValidationRule(minNumber(min), () => {
      if (value < min) {
        return false;
      }
      return true;
    });

    return () => {
      ValidatorForm.removeValidationRule(minNumber(min));
    };
  }, [min, value]);

// ---

But I got an error:

I try to figure out by re-reading the documentation of this and the other library and experimenting, but I can't find any solution.
After some time, I found that I cannot use colon ':' as validation name.
const minNumber = (min) => `minimum${min}`; // <---- so I changed it so that it only uses alphabet and numbers

Please add this rule to the documentation react-form-validator-core and react-material-ui-form-validator
Thank you ✨. !

@nlatifahulfah hi
minNumber validation rule already exists in react-form-validator-core

It is. But it will validate the formatted value (string), eg. "Rp. 123". In my case, the field value is formatted using react-number-format, and I want to validate the unformatted value using controlled component. I can't use the minNumber validation rule.

you can use custom validation component with error message only to validate correct numeric value
import React from 'react';
import { ValidatorComponent } from 'react-form-validator-core';

class ValidationArea extends ValidatorComponent {
    render() {
        return (

                {this.errorText()}

        );
    }

    errorText() {
        const { isValid } = this.state;

        if (isValid) {
            return null;
        }

        return (

                {this.getErrorMessage()}

        );
    }
}

export default ValidationArea;

<ValidationInput value={fancyTextValue} />
<ValidationArea value={numericValue}>

Thank you for your suggestion. It will work too. But I prefer to extract the logic from the ui component.

@nlatifahulfah I still cannot see real issue. Why your solution so complex?
Why you just can't do something like this?
const [min, setMin] = useState(10);
// validation rule will receive input value
ValidatorForm.addValidationRule('customMinNumber', (inputValue) => {
      // use any suitable parse logic to get unformatted value
      const realValue = Number(inputValue);
      // min variable already available because of Closure
      if (realValue < min) {
          return false;
      }
      return true;
});

I don't know why I can't think something like that before 😅 Thank you so much .


Comparison y-axis goes above 100%

It's a little confusing to see that the comparison graph can have a y-axis higher than 100%. It makes it seem like even the best cities/districts aren't as good as they could be, and it kind of wastes space on the screen.

I have reduced the padding around the max values, so I think it should work!


Empty group member list gives success message

Adding group members without any emails shows the success message that a groups member has been added. It should show an error message regarding the empty email field.
Similar issue occurs while adding collaborators.

I would like to self assign this issue. :slightly_smiling_face:

I would like the message to show the following details.

[ ] Number of emails newly invited
[ ] Number of emails already invited
[ ] Number of emails failed (email is not actually an email)

For checking if the email given is an email, right now, the system doesn't parse the email strings to check if the string is actually an email. You will need to implement this.

We can use validates :email, format: { with: URI::MailTo::EMAIL_REGEXP  } in the required models to check the emails. I also wanted to propose the use of strong params as it a good security practice.

We can use validates :email, format: { with: URI::MailTo::EMAIL_REGEXP } in the required models to check the emails.

This is good, but we might not want to create a PendingInvitation record in the first place if the email ID is incorrect.


otel collector not able to send logs from volume path on AKS cluster

Describe the issue you're reporting
Hi Team,
i am trying to setup otel agent to send AKS logs to splunk index.   Actually logs are mounted on /appl/server/logs path.
i have made below configuration in values.yml file
under Agent section:
extraVolumes:
  - name: app-logs
    hostPath:
      path: /appl/server/log
extraVolumeMounts:
  - name: app-logs
    mountPath: /appl/server/log

also added below config under log collection section
extraFileLogs:
  filelog/app-logs:
    include: [/appl/server/log/*.log]
    start_at: beginning
    include_file_path: true
    include_file_name: true
    resource:
      com.splunk.source: /appl/server/log/*.log
      host.name: 'EXPR(env("K8S_NODE_NAME"))'
      com.splunk.sourcetype: applogs

i deployed helm charts on name space. but it does not sending any logs from this path to index, also don't see any errors in logs except below warning.
2023-05-22T08:18:25.106Z        warn    fileconsumer/file.go:63 no files match the configured include patterns  {"kind": "receiver", "name": "filelog", "data_type": "logs", "component": "fileconsumer", "include": ["/appl/server/log/*.log"],
am i missing anything here ? thanks in advance

Hey,
Maybe this is a basic advice, but shouldn't the path be /appl/server/logs/*.log? Logs with s at the end? Because you mentioned

Actually logs are mounted on /appl/server/logs path

Hey, Maybe this is a basic advice, but shouldn't the path be /appl/server/logs/*.log? Logs with s at the end? Because you mentioned

Actually logs are mounted on /appl/server/logs path

logs are stored in /appl/server/logs  path. under this we have log files like application.log

Ok, because in your config you have include: [/appl/server/log/*.log] everywhere, this seems like a different path.
Can you update /appl/server/log/*.log to /appl/server/logs/*.log and /appl/server/log to /appl/server/logs?

Ok, because in your config you have include: [/appl/server/log/*.log] everywhere, this seems like a different path. Can you update /appl/server/log/*.log to /appl/server/logs/*.log and /appl/server/log to /appl/server/logs?

sorry, its my bad,  actuall path is  /appl/server/log   which is actual path and configured same but logs are not forwarding to index

I used your config and created a log following /appl/server/log/*.log pattern and it works correctly for me.
Are you sure you have any files in /appl/server/log on this node? You can additionally find out what files are visible from the otel collector pod perspective using command:
kubectl exec -it pod/my-splunk-otel-collector-agent-6ddjp -- ls /appl/server/log

Where pod/my-splunk-otel-collector-agent-6ddjp  is your agent pod name.

I am not getting any data when i execute this command.    let me give you clear info
pods are writing logs to /appl/ri****/server/log which is mounted on azure file share.
when i connect to application pod and check the above path, i see log files exist.

please find above screenshot how it looks inside app pod, may be i am adding  wrong configuration in values file..
i doubt that should i use /appl/ri***/server/log or //fileshare/*/logs path in values file.
thank you for your time

i doubt that should i use /appl/ri***/server/log or //fileshare/*/logs path in values file.

Why is that?
It looks like you should use /appl/ri*/server/log in include statement as this is the correct path in your system where you have logs (the mount place for your azure logs). Can you update all paths in the config with this value? Also, is ri* something dynamic that can be different depending on the node? Or you just added * for anonymization purposes?

include statement works with *, but I don't think mountPath or hostPath support that. You need to provide the path explicitly there, or mount the whole /appl directory, like:
  extraVolumes:
  - name: app-logs
    hostPath:
      path: /appl
 extraVolumeMounts:
  - name: app-logs
    mountPath: /appl

include statement works with *, but I don't think mountPath or hostPath support that. You need to provide the path explicitly there, or mount the whole /appl directory, like:
  extraVolumes:
  - name: app-logs
    hostPath:
      path: /appl
 extraVolumeMounts:
  - name: app-logs
    mountPath: /appl

i have provide complete path . in post i am mentioning * as  i dont want to disclose here:)

Ah, okay. Sorry, didn't get it. Does it still not see any files?

Ah, okay. Sorry, didn't get it. Does it still not see any files?

find something here , when i try to list the log directory, it says no files

but actually there application logs.
should we change some recievers, exporters config changes in helm ?

Hey,
I think agent.securityContext https://github.com/signalfx/splunk-otel-collector-chart/blob/7698ca2498dffe121ec7776227c4bf77733a1dba/helm-charts/splunk-otel-collector/values.yaml#L369 is the one, but it is already set up to be root by default, so permissions shouldn't be a problem I think

i am able to list out directories upto log folder from /appl but not inside log folder.

You mean when you mounted hostPath as /appl directories are inside, but not logs at the end?
I'm starting to think that maybe the way it works differently on AKS in terms of how filesystem is being seen by the K8s system. Maybe I would try to create just a bare pod trying to mount any of those paths to see if it's even visible? I found some more complicated way of creating volume mounts in AKS here: https://learn.microsoft.com/en-us/azure/aks/azure-csi-files-storage-provision, I am not an AKS expert, but maybe it requires this settings to mount anything that is taken from *file.core.windows.net?

donot see port 13133 in config anywhere ? how can i resolve this

This is a readiness probe of the otel collector pod itself, does it happen frequently?
If a readiness probe fails, it indicates that the container is not yet in a ready state, and the orchestrator will consider the container as unavailable for serving traffic. This could be due to various reasons, such as the container taking longer than expected to start up, encountering an error during initialization, or being overwhelmed with existing workload and unable to handle additional requests.

it was my mistake, mount path is not on host machine. it is on Persistent Volume Claim, after i changing to PVC, it is able to sent logs to splunk. thanks


Run demo examples

Hi,
I am trying to run the "tns run ios" for both demos I am having the same problem for both:
Project successfully built.
Installing...
Successfully installed on device with identifier 'D7FF528C-C525-4DB2-8264-1E2BB88D8F3A'.
Successfully transferred all files.
Refreshing application...
Successfully synced application org.nativescript.demo on device D7FF528C-C525-4DB2-8264-1E2BB88D8F3A.
Executing before-watch hook from /Library/WebServer/Documents/nativescript-facebook/demo/hooks/before-watch/nativescript-dev-typescript.js
Found peer TypeScript 2.2.2
objc[26573]: Class PLBuildVersion is implemented in both /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/System/Library/PrivateFrameworks/AssetsLibraryServices.framework/AssetsLibraryServices (0x119ebccc0) and /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/System/Library/PrivateFrameworks/PhotoLibraryServices.framework/PhotoLibraryServices (0x119cd36f0). One of the two will be used. Which one is undefined.
17:20:55 - Compilation complete. Watching for file changes.

1   0x109bd629c -[TNSRuntime executeModule:referredBy:]
2   0x1095a3eb0 main
3   0x10e54765d start
file:///app/app.js:5:38: JS ERROR Error: Could not find module 'nativescript-facebook'. Computed path '/Users/fiel/Library/Developer/CoreSimulator/Devices/D7FF528C-C525-4DB2-8264-1E2BB88D8F3A/data/Containers/Bundle/Application/F503F1DA-61DF-4369-BFB1-F5BEA5E0F495/demo.app/app/tns_modules/nativescript-facebook'.

I tried to run  "tns plugin add nativescript-facebook" but it shows me a message "It is already installed"
Am I missing something?
Thanks in advance.

Hi @gpfiel ,
You can see in the demo's package.json that it uses the plugin implementation from the src folder which requires to run npm i and tsc in both the src first. It looks like you missed and the plugin's TypeScript files are not transpiled to javascript. To ease the plugin and demo builds we have created some scripts to do this so you need just to follow these steps:

open Terminal / Command Promt and navigate to nativescript-facebook folder
run git clean -fdx . This will clean all non-versioned files which were generated from tns run. Or just get a clean copy of the code.
go to  the demo folder of your choice. For example cd demo
run npm run build.plugin - this will install plugin dependencies and transpile the TypeScript
run tns run ios - this will install demo dependencies, transpile the TypeScript to javascript and run the application.

Let me know if this works for you.
Best regards,
Veselina

Hi @radeva,
Sorry I missed some steps. I checked the package.json, I didn't realize it was using the ../src.
But aftter following the steps above I've got a new problem.
`** BUILD SUCCEEDED **
Project successfully built.
Installing...
Successfully installed on device with identifier 'D7FF528C-C525-4DB2-8264-1E2BB88D8F3A'.
Successfully transferred all files.
Refreshing application...
Successfully synced application org.nativescript.demoangular on device D7FF528C-C525-4DB2-8264-1E2BB88D8F3A.
Executing before-watch hook from /Library/WebServer/Documents/nativescript-facebook/demo-angular/hooks/before-watch/nativescript-dev-typescript.js
Found peer TypeScript 2.3.4
objc[70801]: Class PLBuildVersion is implemented in both /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/System/Library/PrivateFrameworks/AssetsLibraryServices.framework/AssetsLibraryServices (0x111a06cc0) and /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/System/Library/PrivateFrameworks/PhotoLibraryServices.framework/PhotoLibraryServices (0x11181d6f0). One of the two will be used. Which one is undefined.
Falling back to loading access token from NSUserDefaults because of simulator bug
Falling back to storing access token in NSUserDefaults because of simulator bug
Falling back to loading access token from NSUserDefaults because of simulator bug
Falling back to storing access token in NSUserDefaults because of simulator bug
Falling back to loading access token from NSUserDefaults because of simulator bug
Falling back to storing access token in NSUserDefaults because of simulator bug
1   0x10171171b NativeScript::FFICallbackNativeScript::ObjCMethodCallback::ffiClosureCallback(ffi_cif*, void*, void**, void*)
2   0x101de615e ffi_closure_unix64_inner
3   0x101de6a92 ffi_closure_unix64
4   0x102b0c3c3 -[UIViewController __viewWillAppear:]
5   0x102b45b51 -[UINavigationController _startTransition:fromViewController:toViewController:]
6   0x102b46a03 -[UINavigationController _startDeferredTransitionIfNeeded:]
7   0x102b47b41 -[UINavigationController __viewWillLayoutSubviews]
8   0x102d3960c -[UILayoutContainerView layoutSubviews]
9   0x102a2655b -[UIView(CALayerDelegate) layoutSublayersOfLayer:]
10  0x1086d5904 -[CALayer layoutSublayers]
11  0x1086c9526 CA::Layer::layout_if_needed(CA::Transaction*)
12  0x1086c93a0 CA::Layer::layout_and_display_if_needed(CA::Transaction*)
13  0x108658e92 CA::Context::commit_transaction(CA::Transaction*)
14  0x108685130 CA::Transaction::commit()
15  0x108685b37 CA::Transaction::observer_callback(__CFRunLoopObserver*, unsigned long, void*)
16  0x10579d717 CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION
17  0x10579d687 __CFRunLoopDoObservers
18  0x105782038 CFRunLoopRunSpecific
19  0x10295d08f -[UIApplication _run]
20  0x102963134 UIApplicationMain
21  0x101de68ed ffi_call_unix64
22  0x120d73b10
file:///app/tns_modules/@angular/compiler/./bundles/compiler.umd.js:15019:24: JS ERROR Error: Unexpected value 'NativeScriptFacebookModule' imported by the module 'AppModule'. Please add a @NgModule annotation.
Aug 18 10:16:25 gpfiel com.apple.CoreSimulator.SimDevice.D7FF528C-C525-4DB2-8264-1E2BB88D8F3A.launchd_sim[69783] (UIKitApplication:org.nativescript.demoangular[0xcf32][69805][70801]): Service exited due to Segmentation fault: 11
10:16:25 - Compilation complete. Watching for file changes.`
Any idea about this one?
The application crashes after it is started.

Hi @gpfiel,
I tried the angular demo on my side with iPhone 7 Simulator and it works as expected. Could you give some more info like:

CLI version (run tns --version)
are you trying to run on Simulator or Device and on what operating system
do you have any global installation of angular related packages

You can also try to clean you platforms folder (run rm -rf platformsif you're on MAC) and run tns run ios once again.
If the problem persists, I'll ask you to send us a zip with all the files so we can check it on our side.
Best regards,
Veselina

Hi @radeva,
I am trying run it on an Iphone SE (Simulator on Macbook), IOS 10.3, TNS version 3.1.3. My mac os is Sierra.

demo-angular (package) the app start but it crashes with erro:
 JS ERROR Error: Unexpected value 'NativeScriptFacebookModule' imported by the module 'AppModule'. Please add a @NgModule annotation.
demo (package) the app is running and connect to facebook to get the information but in the console I get this problem. But it is working anyway
-canOpenURL: failed for URL: "fbauth2:/" - error: "The operation couldn’t be completed. (OSStatus error -10814.)"

The important to me is to make it work on demo-angular because my application is angular.
Regards,
Gabriel Fiel.

Hi @gpfiel,
Could you try to reset Simulator Content and Settings and try to run the demos again? To do so go to Simulator -> Reset Content and Settings. Here is more discussion on that topic.
Best regards,
Veselina

Hi @radeva,
I reseted it but I didn't get any changes. Same problem.
Regards,
Gabriel Fiel.

Hi @gpfiel .
To fix the angular demo issue, could you make sure you do not use npm link to link the plugin in demo-angular? Just in case you can do the following:

go to src folder and run npm unlink
go to demo-angular and run npm unlink nativescript-facebook
again in demo-angular run rm -rf node_modules and `npm i``

This should fix the issue in demo-angular.
Could you try to do the same in demo and tell if the issue there still appears? I'm still not able to reproduce it.
Best regards,
Veselina

Hi @radeva,
I was following the steps above but I've got an extra error. Also I did clone the plugin again to ensure it was clean.
Project successfully built.
Installing...
Successfully installed on device with identifier 'E51162E1-5753-4001-B904-2B88B9080607'.
Successfully transferred all files.
Refreshing application...
Successfully synced application org.nativescript.demoangular on device E51162E1-5753-4001-B904-2B88B9080607.
Executing before-watch hook from /Library/WebServer/Documents/nativescript-facebook/demo-angular/hooks/before-watch/nativescript-dev-typescript.js
Found peer TypeScript 2.3.4
objc[1905]: Class PLBuildVersion is implemented in both /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/System/Library/PrivateFrameworks/AssetsLibraryServices.framework/AssetsLibraryServices (0x11ae4bcc0) and /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator.sdk/System/Library/PrivateFrameworks/PhotoLibraryServices.framework/PhotoLibraryServices (0x11ac626f0). One of the two will be used. Which one is undefined.

2 import * as Facebook from "nativescript-facebook";
                            ~~~~~~~~~~~~~~~~~~~~~~~

app/app.component.ts(2,27): error TS2307: Cannot find module 'nativescript-facebook'.

7 import { NativeScriptFacebookModule } from "nativescript-facebook/angular";
                                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

app/app.module.ts(7,44): error TS2307: Cannot find module 'nativescript-facebook/angular'.

2 import * as Facebook from "nativescript-facebook";
                            ~~~~~~~~~~~~~~~~~~~~~~~

app/pages/home/home.component.ts(2,27): error TS2307: Cannot find module 'nativescript-facebook'.

6 import { NativeScriptFacebookModule } from "nativescript-facebook/angular";
                                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

app/pages/home/home.module.ts(6,44): error TS2307: Cannot find module 'nativescript-facebook/angular'.

2 import * as Facebook from "nativescript-facebook";
                            ~~~~~~~~~~~~~~~~~~~~~~~

app/pages/login/login.component.ts(2,27): error TS2307: Cannot find module 'nativescript-facebook'.

6 import { NativeScriptFacebookModule } from "nativescript-facebook/angular";
                                             ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

app/pages/login/login.module.ts(6,44): error TS2307: Cannot find module 'nativescript-facebook/angular'.

11:09:11 - Compilation complete. Watching for file changes.

Falling back to loading access token from NSUserDefaults because of simulator bug
Falling back to storing access token in NSUserDefaults because of simulator bug
Falling back to loading access token from NSUserDefaults because of simulator bug
Falling back to storing access token in NSUserDefaults because of simulator bug
Falling back to loading access token from NSUserDefaults because of simulator bug
Falling back to storing access token in NSUserDefaults because of simulator bug
1   0x10ab5e71b NativeScript::FFICallback<NativeScript::ObjCMethodCallback>::ffiClosureCallback(ffi_cif*, void*, void**, void*)
2   0x10b23315e ffi_closure_unix64_inner
3   0x10b233a92 ffi_closure_unix64
4   0x10c3bc3c3 -[UIViewController __viewWillAppear:]
5   0x10c3f5b51 -[UINavigationController _startTransition:fromViewController:toViewController:]
6   0x10c3f6a03 -[UINavigationController _startDeferredTransitionIfNeeded:]
7   0x10c3f7b41 -[UINavigationController __viewWillLayoutSubviews]
8   0x10c5e960c -[UILayoutContainerView layoutSubviews]
9   0x10c2d655b -[UIView(CALayerDelegate) layoutSublayersOfLayer:]
10  0x111bae904 -[CALayer layoutSublayers]
11  0x111ba2526 CA::Layer::layout_if_needed(CA::Transaction*)
12  0x111ba23a0 CA::Layer::layout_and_display_if_needed(CA::Transaction*)
13  0x111b31e92 CA::Context::commit_transaction(CA::Transaction*)
14  0x111b5e130 CA::Transaction::commit()
15  0x111b5eb37 CA::Transaction::observer_callback(__CFRunLoopObserver*, unsigned long, void*)
16  0x10ed3f717 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__
17  0x10ed3f687 __CFRunLoopDoObservers
18  0x10ed24038 CFRunLoopRunSpecific
19  0x10c20d08f -[UIApplication _run]
20  0x10c213134 UIApplicationMain
21  0x10b2338ed ffi_call_unix64
22  0x12a175b10
file:///app/tns_modules/@angular/compiler/./bundles/compiler.umd.js:15019:24: JS ERROR Error: Unexpected value 'NativeScriptFacebookModule' imported by the module 'AppModule'. Please add a @NgModule annotation.
Aug 21 11:09:13 gpfiel com.apple.CoreSimulator.SimDevice.E51162E1-5753-4001-B904-2B88B9080607.launchd_sim[98244] (UIKitApplication:org.nativescript.demoangular[0xbb60][98266][1905]): Service exited due to Segmentation fault: 11

Regards,
Gabriel Fiel.

 Take a at my first answer above.
Best regards,
Veselina

Hi @radeva,
Yes, I did it. The demo folder is working fine.
My issue is demo-angular.
If possible could we have a call on skype? So I can show whats is happening there.
Skype: gpfiel
Regards,
Gabriel Fiel

Hi @gpfiel,
Let's have a chat in the NativeScript Community Slack. I sent you an invitation.
In the meantime you can try to

go to demo-angular
rm -rf node_modules
rm -rf platforms
npm i
tns run ios

Best regards,
Veselina

SOLVED: JS ERROR Error: Unexpected value 'NativeScriptFacebookModule' imported by the module 'AppModule'. Please add a @NgModule annotation. error can be fixed by installing the nativescript-facebook plugin from npm and not from the srcfolder.

@gpfiel @radeva Can you please test with nativescript@next, yesterday we pushed a fix that should resolve this issue.

I'm closing this issue as the above fix solves it. It was caused by the npm 5 symlinks. More info can be found in fix description. If you want to install the version of nativescript containing the fix use "npm i nativescript@next" or wait for the official release.
@gpfiel


Add tags

Following https://en.wikipedia.org/wiki/Apache_Groovy
Added "declarative" (collect, inject, findAll, ...)  and "functional" (see https://en.wikipedia.org/wiki/Apache_Groovy#Functional_programming) styles.

@ErikSchierboom how to proceed with this PR?
It has the same 2 jobs failing as on main. At the moment I'm too unfamiliar with the project setup to solve those.

@artamonovkirill Those build failures are unrelated to this PR, so I'm gonna merge this. Thanks!


Transpose narrow matmuls so that the narrow dimension is M

Narrow-N and narrow-M cases of matmuls are entirely similar. There is no need to write data-tiling logic and ukernels for all combinations of the two narrow dimensions.
We have standardized on only implementing data-tiling logic and ukernels for the narrow-M case. The idea all along was to reduce narrow-N cases to that by transposition. So this issue is about finally doing that.

Fixed at last by #17545 !


Set EMS status when during orchestrate_destroy

Set the ems status to deleting while the workers are shutting down.
This can be used for display as well as preventing the user from
accidentally re-enabling an EMS which is being deleted.
Depends: https://github.com/ManageIQ/manageiq-schema/pull/140

I'd like to add a task to track the destroy that can be seen by users, probably need to change the args to allow a userid to be passed in from the UI.

Going to close this for now since it isn't getting any traction.  If we find we need this in the future I will re-open it.


fix product price so taxes are calculated accurately

When a product is taxable and has configurable options that modify its price, taxes are calculated with the default price, I edited it so it works with the modified price.

Thank you for this - I'll merge this one in shortly.
It's critical enough that I'll probably do another release right after.

I'm not able to replicate the bug you've described, and I appear to have taxes correctly calculating without these updates to TaxRate.php
For example, I:

Set up a tax rate of 10%
Create a product with a base rate of $100
Add an option that added $50 to the base price
Added the price to the cart, meaning the price is $150.
In the checkout, the tax calculated is $15, which is 10% of the price that includes the option adjustment.

I also tried the above with a variation.
I may simply be missing the particular configuration this addresses though, can you can give me an example to test?

Sorry, I found this bug some weeks ago but I can't remember what settings I had, I tried to reproduce it again but I don't find it anymore.
I'm going to close this for now, I'll post it again if I happen to reproduce the bug.

No problem at all, it's better to flag something like this even if it ends up just being a false alarm.
Perhaps you were using the master for testing, and that wasn't completely finished in terms of this aspect?
Certainly check back if you hit the bug again, it's not the type of thing we'd want to overlook!


Jobs can download a huge amount of unneeded data

Consider a very typical workload where you have a models repo and a data repo.  A pipeline takes both repos as inputs.  If a new model is added, the pipeline runs the model against a subset of data.
Currently (since #1078 landed), a job downloads all input data before executing.  Therefore, if a new commit comes into the models repo, the job will download the entire data repo.  This is clearly undesirable since:

The size of the data repo might exceed disk capacity.
The job doesn't even actually need the entire data repo.  It only needs a subset of the data (as determined by the newly added model).

I'm a little confused about what's going on here. What are the input methods of models and data in this example? Unless one of them is REPO I wouldn't expect it to ever be necessary to download either one in its entirety.
Also will #1108 help with this?

Lets say your data repo is 100TB and your models repo is small like 1GB. Each model maps to quite a bit of data. Now lets say you have a pipeline which is applying your models to the data (2 input pipeline) and you make a change to your model. Via the cross product rules, you have the change appearing in the model repo, but you have every single shard of data appearing in the data repo. If you cluster is medium sized, say 10 nodes. Hell lets be bold and say 100 nodes you will need to pull down 1TB per node which is not great. Even more so, lets say that a model doesn't apply to all the data and  you can tell which data to apply the model too by its path/filename. In which case you don't need to download all of the data which matches, but you won't be able to tell that until the job is running.

@JonathanFraser summarized the problem pretty well.
@jdoliner #1108 will help solve the first part of the problem, which is data might not fit into disk.  It doesn't solve the second problem which is that sometimes you really only need a subset of datums, and only the application itself knows which subset it needs (usually by looking at filenames).

@jdoliner has an interesting proposal:
Instead of using normal files in /pfs, we use unix domain sockets.  Each socket corresponds to a file in PFS.  This has the following benefits:

We still get a non-FUSE file system layout.  That means meta operations (e.g. listing files) will be fast and non-buggy.
Data is loaded lazily, thereby circumventing both problems mentioned in this issue (i.e. data doesn't fit onto disk, and only partial data is needed)

The downsides are:

Sockets are still distinguishable from files, which means that certain applications might break.  For instance, sockets don't support seek.

@derekchiang @jdoliner This is probably been summarized in a different issue, but what about the Fuse layer makes it so slow. Is it the trips into userspace or something else?

It's slow due to the lack of caching.  When you read the same file twice, it's downloaded twice.  Even worse, every time you list a directory it translates to a ListFile over the network.
There is technically no reason why we can't just cache everything, but our FUSE implementation was already very buggy as it was, so instead of adding more code to it, we thought we might as well just get rid of it.
Implementing (and maintaining) a FUSE driver is hard because FUSE has many callbacks, since it's supposed to behave like a normal file system.  Compare this with a unix socket, which only needs to implement read and write.

With #1130, we now have a solution for this problem.  Basically you can set the lazy flag in your pipeline spec to download files lazily.  This is possible because when lazy is set, we put named pipes instead of normal files in /pfs.  The named pipes only download the corresponding files when they are explicitly read from.  Note that named pipes do not support certain syscalls such as seek.


🐛 New Bug: NPE is thrown when WebSetting in boyka-config.json does not match.

❓ What is the bug?
NPE is thrown when WebSetting in boyka-config.json does not match.
Version
0.1.0 (Default)
🖥 What framework domain type is this bug for?
Web
📃 Steps to reproduce the bug

[ ] Scenario 1:
Update the WebSetting as "test_chrom" in boyka-config.json and provide the WebSetting value as "test_chrome" in test.

[ ] Scenario 2:
Modify the web block name to webii, api block name to API and ui to UUI

✅ Expected Behavior

[ ] Scenario 1:
Display appropriate FrameworkError message like WebSetting <setting_name> not found, please check the boyka-config.json file.

[ ] Scenario 2:
FrameworkError should be thrown that block name should be kept as "web"/ "api" only.

❌ Actual Behavior
NullPointerException is thrown.

Scenario 1 is a valid issue which is handled in PR #182 , while scenario 2 is invalid as user should not modify the constant config blocks like ui, web, api, etc.


fix: LSDV-4960: Sort annotations by creation date instead of pk

Hi @Travis1282!
This PR was created in response to a PRs in upstream repo:

https://github.com/heartexlabs/label-studio-frontend/pull/1342

already merged


[Discussion] What values should the user update/modify in the profile page?

Problem

Above are the current fields that the user can modify in the profile page. However, I really am not sure if the user needs to modify all these fields, or if there are any other fields that should be here.
Please leave your thoughts on what user information we should collect.

Changed profile page so not relevant anymore


ModuleNotFoundError: No module named 'concordex_map'

Hello,
I successfully installed concordex using the command line from README. However, this error pops up when I call concordex on the command line:
(default_env) bash-4.4$ concordex -h
Traceback (most recent call last):
  File "/mnt/beegfs/users/akwok/miniconda3/envs/default_env/bin/concordex", line 33, in <module>
    sys.exit(load_entry_point('concordex==0.0.1', 'console_scripts', 'concordex')())
  File "/mnt/beegfs/users/akwok/miniconda3/envs/default_env/bin/concordex", line 25, in importlib_load_entry_point
    return next(matches).load()
  File "/mnt/beegfs/users/akwok/miniconda3/envs/default_env/lib/python3.9/importlib/metadata.py", line 86, in load
    module = import_module(match.group('module'))
  File "/mnt/beegfs/users/akwok/miniconda3/envs/default_env/lib/python3.9/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "<frozen importlib._bootstrap>", line 1030, in _gcd_import
  File "<frozen importlib._bootstrap>", line 1007, in _find_and_load
  File "<frozen importlib._bootstrap>", line 986, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 680, in _load_unlocked
  File "<frozen importlib._bootstrap_external>", line 850, in exec_module
  File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed
  File "/mnt/beegfs/users/akwok/miniconda3/envs/default_env/lib/python3.9/site-packages/concordex/main.py", line 5, in <module>
    from .concordex_stat import setup_stat_args, validate_stat_args
  File "/mnt/beegfs/users/akwok/miniconda3/envs/default_env/lib/python3.9/site-packages/concordex/concordex_stat.py", line 6, in <module>
    from concordex_map import concordex_map
ModuleNotFoundError:` No module named 'concordex_map'

Also tried to install via cloning the repo, i.e.:
python setup.py install
But ran into the same error. Could this be a versioning problem?
Thanks!

Hi @aaronkwc, it's almost certainly an issue with versioning. I'll work on a fix today. Thanks for bringing this to my attention.

Hi @aaronkwc, I've made some major changes to the code, and I'm working on writing new documentation + examples this week. In any case, this issue is resolved and the install should work now.

Hi, I am facing a similar issue and cannot import concordex.concordex_map after using the install command above.
(venv) jupyter@cbd1437fc4ad:~/test-concordec$ python
Python 3.10.14 | packaged by conda-forge | (main, Mar 20 2024, 12:45:18) [GCC 12.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import concordex
>>> concordex.__version__
'1.0.2'
>>> from concordex.concordex_map import concordex_map
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ModuleNotFoundError: No module named 'concordex.concordex_map'

Are the new docs + examples available? I am interested in using the functions in the example notebook. Thanks!

Hi @sidwekhande,
I've updated the PBMC example notebook The interface has changed considerably and the concordex_map function has been depreciated.
All of the functionality of concordex_map has been wrapped into concordex.tools.calculate_concordex()
I hope this helps!

Thanks @kayla-jackson, that's really helpful!


Split existing processor into multiple processors

Currently there is a single annotation processor that handles TypeAdapter and TypeAdapterFactory.
These do not need to be bound together, and by splitting them apart, it could enable parallelism during building.

This has been completed


Redundant If check in deployment script for SIMULATOR_API_KEY

Since SIMULATOR_API_KEY is not defined as an environment variable in sample.env, nor it is documented in README, the following top level "If check" on same seems redundant.

Would like to know the reason for same and also if not then would like to suggest that we:

Either we remove this top-level check
or add a corresponding environment variable (if that was the intention)

Thanks @sushaanttb
The first check would allow you to override the SIMULATOR_API_KEY value for an individual run of the deployment (either by settings a value in the .env file or on the command line), but I'm not sure that this is a likely use-case


Update user version when discarding a draft.

When discarding a draft work version and the draft work version has a user_version:

If the previous work version has a user_version do nothing.
If the previous work version does not have a user_version, move the user_version from the draft work_version to the previous work_version.

I'm not clear on how a draft work version from H2 will get a UserVersion. Can we discuss at standup or a story time?

In the H2 data model, user_version is an attribute of WorkVersion. (This logically aligns with a DSA UserVersion, but is not the same.)

Changing strategy so closing this issue.


Torrent Searcher

Script Title - Able to search on torrent
what will change - Adding script
Instructions

Create a new folder for your script and file/folder name should be appropriate.
Create a README.md in your folder for program Instructions
add requirements.txt if needed

Please add/delete options that are not relevant.

[x] Adding New Code
[x] Improving Code
[x] Improving Documentation
[x] Bug Fix

Programming Language

[x] Python

Happy Coding,

Hi @pawangeek
Can I try it ¡¡¡
Thanks.

Hello, I would take this one for HacktoberFest :smiley:

okay, @HolgerDoerner go ahead :)


Null exception with angular

Hello!
Expected behavior and actual behavior:
For some reason, I'm getting null inside of _itemsChanged  while trying to initialize the component in an angular application. I got this error while migrating from 2.x to 4.x.
This is the exception I get:
Uncaught TypeError: Cannot read property '0' of null
    at HTMLElement._itemsChanged (px-dropdown.html:446)
    at HTMLElement._observerEffect (polymer.html:1613)
    at HTMLElement._effectEffects (polymer.html:1458)
    at HTMLElement._propertySetter (polymer.html:1442)
    at HTMLElement.__setProperty (polymer.html:1451)
    at HTMLElement._applyConfig (polymer.html:2064)
    at HTMLElement._afterClientsReady (polymer.html:2058)
    at HTMLElement._ready (polymer-mini.html:144)
    at HTMLElement._tryReady (polymer-mini.html:130)
    at HTMLElement._initFeatures (polymer.html:4121)

And this is how I initialize the component:
<px-dropdown  id="add-shift-locations-dropdown-data" items='{{vm.locationsToShow}}' multi display-value="Select one or more locations" search-mode></px-dropdown>
And this is what I have in my controller:
vm.locationsToShow = [];
If I replace that line with:
if(items != null && items[0] && typeof items[0] === 'string') {
everything works correctly.
I get as many exceptions as dropdowns I have on the page. It doesn't matter if I have the items initialized to [] or not.
Is there any way to add that null check to the code?
Environment (component version number, Browser (including version), operating system, hardware, etc):
Angular 1.6.6
Bower 1.8.2
px-dropdown 4.0.7 (tried with 4.0.13 too and still not worked)

Added in v4.0.14.


PD behaviour in secure mode for commands with no defined command structure

Describe the bug
The secure session gets discarded due to "failed" decryption upon receiving commands that have no command structure defined in the spec. Such commands are LSTAT, OSTAT, RSTAT, ISTAT. These simply instruct the PD to reply based on the command code.
Expected behavior
Secure mode should not be discarded
Observed behavior
It is observed that secure session gets discarded when PD receives CMD_LSTAT in secure mode, due to decrypt function osdp_decrypt_data returning 0.
Additional context
Looking at the spec, the commands LSTAT, OSTAT, RSTAT, ISTAT have no command structure (i.e. no data to go along with the command), and could potentially have no decrypted data to work with. I think this is why returned length from osdp_decrypt_data is 0. Because the caller in osdp_phy_decode_packet considers 0 return value to be a failure scenario, this causes a secure session reset.
To be more specific, the decrypted data block for LSTAT looks like<PHONE_NUMBER>0000000000000000000000 which indicates that there is no data available, just the padding 0x80 to indicate end of message. So I don't think it is necessary to fail here.
I propose either removing the equality condition for all, or making an exception for just those four commands.

To be more specific, the decrypted data block for LSTAT looks like<PHONE_NUMBER>0000000000000000000000 which indicates that there is no data available, just the padding 0x80 to indicate end of message. So I don't think it is necessary to fail here.

@prxvm, According to the specification (v2.1.6, section D.3.2.1 and D.3.2.2) if a command or reply has no data, it should use SCS_15/SCS_16 and not SCS_17/SCS_18. You can see that LibOSDP handles this correctly while sending and receiving.
Is this a commercially available PD that has this issue? If that is the case and it is widely used, we add a macro switch to allow this.

@cbsiddharth this was observed a commercial panel. you are right this packet should not have been sent with SCS_17, but alas. Thank you.


New amiSelectorTerm alias for latest~1

Description
What problem are you trying to solve?
I want our staging environment to use the latest ami and our production environment to use n-1

staging: - alias: al2023@latest
production: - alias: al2023@latest~1

This requires less manual work to find the specific AMI versions and having to manually pin/update Karpenter each time. This includes when they can lag behind in each region and when we there are multiple arch as well.
How important is this feature to you?
We have been recommended by our AWS TAM team to implement this strategy for our environments.

Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
If you are interested in working on this issue or have submitted a pull request, please leave a comment

I have a similar requirement but I don't think that n-1 is a workable solution. Firstly even with a 7 day regular release cycle, which none of AL2, AL2023 or Bottlerocket actually follow, this is a significant lag to get updates which are likely already lagged in the first place. Secondly how do we know that n-1 is actually a "good" release; n could have been released to replace a "bad" n-1 without n-1 having been delisted.
I'd like to see support for marking an AMI as stable either in the context of AWS/EKS or Karpenter and then being able to use a - alias: al2023@stable selector. The stable concept could have some constraints, such as min release age etc, and there should be an expectation that in the case of a "bad" stable version that this would be rolled back to the previous "good" stable version.
As a less integrated option Karpenter could support managing dynamic AMI selection from a user defined SSM (or equivalent) source.

Not related to the stable tag, but because of an issue in the latest AL2023 release, and because a lack of documentation around selecting versions by alias, I have been using:
  amiSelectorTerms:
    - alias: al2023@v20241031

to back off the most recent version.
+1 for a stable tag the lags behind!


Time on actions

New features:

Define actions by status.
Add time constraints on action generation, absolute or based on calendar.

@jshaughn this PR is ready for your review. Thx

I've added additional examples and fix some issues from review.
Sorry, the commit of "built-in smtp testing" library was included.
It's harmless but it was part of another branch, I think is ok to add it.

As commented, perhaps the terminology for Mx and Dx for relative dates could be less readable.
I can change them for short/long english constants as monday (mo) or january (jan), that would maintain the same philosophy or we can add a full object for that.
My suggestion would be to change the expression with short/long formats and check how this feature is accepted, and change into a TimeConstraint object later in future if we see that we have a lack of flexibility for that.

I've introduced a TimeConstraint object to express in a better readable way the calendar expressions.
The PR is not finished yet.
I would like to add constraints (states and/or time) at Trigger level but also at ActionDefinition level.
So, if a constraint is defined at Trigger level it has priority over those defined at ActionDefinition level.
But constraints defined at Action level could be good to modify just the definition.
It's low hanging fruit with the present approach, so I think it could be good to add it for a first iteration.

I have added support to have action constraints defined at trigger and at action level, so I think we can cover more uses cases.
please, @jshaughn can you review it ?
Thanks

I like the addition of TimeConstraint (surprise :) ).  A little more definition around semantics and I think the PR can be merged.

"Relative" term is used as "relative" to the current time/date.
So, a {startTime: "2016.02.01,09:00", endTime: "2016.02.01,18:00", relative: false} is doesn't need an additional info to calculate the interval.
But a {startTime:"09:00", endTime:"18:00"} is relative in the meaning that if now it is "15:00" the constraint is satisfied in the same way that yesterday/tomorrow at "15:00" will be satisfied as the interval is "relative".
You have brought an interesting question.
With the current implementation, {startTime:"Mon,09:00", endTime:"Fri,18:00"} has a "repetitive" behaviour, in the sense that if now it is "Monday,15:00" that will be satisfied the constraint, but if it is "Monday,18:01" the constraint won't be satisfied.
I tend to think that perhaps behaviour should be to consider the interval linear.
It is a flaw in the implementation, as it is validated by steps in the relative dates (first it validates month, if correct, it validates days, and finally it validates time).
But perhaps the behaviour is useful as it is and it is just a flaw in the documentation that is not clear enough.
I am for fix that and implement relative dates in linear behaviour, but not sure what both formats can be more useful (I think that we can include both with an additional flag, but perhaps it is "overarch" for this iteration).

I am fine with whatever level of impl you want to have for this iteration.  My desire is only for clear documentation of the semantics, preferably with some examples. And a blog.  And a demo :)

When you are satisfied and make your final commit I will merge.

@jshaughn I've rebased with your last commit from yesterday.
I think PR is ready to be merged from my side.


Vue PWA doesn't update on iOS

Version
3.1.0
Reproduction link
https://github.com/mikeli11/vuepwaplugin
Node and OS info
Node 8.11.3 / Windows 10
Steps to reproduce
The issue is simple, I create a new project using vue-cli-3.1.0 and select the pwa plugin. I publish this app to netlify and add it to my homescreen on iOS12. I open the app and everything looks fine, I make an update and publish the site again. No matter how many times i open the app on iOS it is always showing the old version. This could be a Vue pwa plugin specific issue or with safari.
See it in action:
https://youtu.be/b197y8sMaKM
What is expected?
PWA is updated with the latest content.
What is actually happening?
PWA is still the older version of the app.

I'm also puzzled by this behavior.
Seems a Safari bug.
https://github.com/GoogleChrome/workbox/issues/1744

@kawazoe I fixed the issue by adding the skipwaiting:true option in the vue.config.js. After restarting the app on iOS, the latest version is now loaded.
  workboxOptions: {       skipWaiting: true }
Let me know if this helps you with your workbox issue. I don't know if this is the expected behaviour in Safari since this setting force installs the latest SW as soon as it's downloaded (which is not recommended). As you know already, chrome doesn't need this for the expected behaviour.
Reference:
https://developers.google.com/web/tools/workbox/modules/workbox-webpack-plugin

Can you provide a more detailed solution? I face the same problem at the latest iOS Beta version.
Thank you.


fix: highlight calculations race with buffer updates

Addresses #1888 (I'm unsure if it's fully fixed, but my preliminary testing shows great improvement. I'll probably run this as a daily driver for a bit to see what I can uncover)
Demo:
https://github.com/vscode-neovim/vscode-neovim/assets/977151/1355c0a8-4e69-499e-ae32-eed44dbf6392
The issue stems from the fact that highlight updates were calculated based on text which may have not yet been committed to the vscode editor. I refactored part of the HighlightManager to allow the deferral of this calculation until we can acquire a lock on the editor.

FWIW, I've been using this for the past couple of days and not seen any strange behavior with highlights :)

Very cool. Is there any way to simplify the code? Or to re-use it in other places in the codebase? Or at least delete some old code?
Since you have abstracted PendingHLUpdates, it seems like it could get a lot of test coverage simply by writing tests against the PendingHLUpdates interface (without involving actualy vscode operations).

Nice💯

there weren't really "unit" tests of things like this, but I'm happy to work some in :)

Ah right. IIRC, the tests don't have access to the direct process, they all go over RPC. So you may need to register a special-purpose vscode command which acts as an interface to the tests.

phew this PR blew up a bit, but just a summary of the changes I just pushed

I added unit tests, which run on every npm test invocation. Just for clarity, I renamed some of the existing test scripts to include integration explicitly, which blew up the number of files
I couldn't find any useful places to reuse this PendingUpdates structure without forcing it a bit, but I did break it out and added tests
I also did some minor reshuffling of the HighlightManager for clarity :)

Thanks for this! I'd keep daily driving the highlights for a bit longer, and then I'm good to merge.
@ollien if you have the time/the will, you are more than welcome to use your newfound knowledge of the highlight provider to make a new PR which continues to simplify things :).  I was actually thinking of throwing some unit tests around HighlightProvider and working on it. Is there anything in particular you have a particular affliction to (e.g. what carries the most debt)? Or is it just a "big ball of code I'd like to see untangled"?

@ollien Big ball of code, definitely. It's also the source of a large number of issues in this project. Many of those issues are now closed, as @xiyaowong did a lot of work on the highlight provider. However, it can still be simplified.
No pressure at all to fix the following open issues, simplifying the code + adding tests is useful enough!

https://github.com/vscode-neovim/vscode-neovim/issues/1766
https://github.com/vscode-neovim/vscode-neovim/issues/1739
https://github.com/vscode-neovim/vscode-neovim/issues/329#issuecomment-1215278530
https://github.com/vscode-neovim/vscode-neovim/issues/1367

Daily driving is going well :) I'll keep it up. Separately, I've been investigating some of the bugs @theol0403 mentioned this morning, and I think this also fixes #1766, or at least the test case mentioned here https://github.com/vscode-neovim/vscode-neovim/issues/1766#issuecomment-1919864798
On version 1.8.1 if I enter sample text on both lines, indent them with >> (bottom up), then execute the steps listed here, I get garbled text
https://github.com/vscode-neovim/vscode-neovim/assets/977151/e526d75a-89bf-4f1c-b163-62e2455040a7
However, with this PR, that doesn't seem to happen :tada:
https://github.com/vscode-neovim/vscode-neovim/assets/977151/a069f214-3a08-4002-85d9-a795c984376e


Specifying a blank host bypasses API security check

e.g. siad --api-addr :9980 is equivalent to siad --api-addr [::]:9980, but only the latter will get caught by the API security check.

If you specify siad --api-addr :9980 it should only be serving on localhost. A brief test showed that this is not the case.

If that's too confusing, then it should at least deny the usage of --api-addr :9980, forcing you to add the full address.

note that the new sia.js calls siad with a set of default flags, one of them being --api-addr :9980.  It's critical that this binds only to localhost for our UI users, although new sia.js probably won't be released in the UI until after 1.0.2

We should also consider how any changes we make would affect the other addr flags, --rpc-addr and --host-addr. For those flags it is much more convenient to specify :xxxx than <IP_ADDRESS>:xxxx or [::]:xxxx. I think using :xxxx is also the only way to listen on both IPv4 and IPv6 interfaces.
In general a blank host means "all available interfaces" (see net.Listen). I think a reasonable solution (and the solution presented in the PR) is to require the --disable-api-security flag if the host is blank.

alright, I'll change sia.js's default flags to localhost:998*

Only the API address should be localhost. The other addresses' hosts should be unspecified.

roger that, looks like that's how it was regardless.  For some reason I thought the api was bound to :9980


[Audit] Select

variants:

Select
Inline

🖼 design spec (internal link): https://ibm.ent.box.com/file/329981608564
changes:
Select:

[ ]  dev: use type tokens (currently commented-out as TODO items in code)

label: $label-01 ✅
text in field: $body-short-01 ✅

[ ]  dev: verify that we're using spacing tokens in field & label margin
[x]  dev: disabled label text should be $disabled-02 ✅ . verify which token/hex is being used

helper text should be same color as label when disabled

helper text type token: $label-01 ✅
helper text color tokens: enabled = $text-02; disabled = $disabled-02  ✅

[x]  dev: space between label & helper text is off—should be 2px
[ ]  dev: verify error icon is there (it's not there on website)
[ ] screenshot: is this overlap in the error state an issue with the component, or its display on the website?

Inline:

[ ]  dev: width should always be the content width plus padding (fluid width) to match design spec. (it will get small with short content)
[x]  dev: disabled label using wrong color/token

helper text should be same color as label when disabled

FYI @aagonzales

screenshot: is this overlap in the error state an issue with the component, or its display on the website?

where is this screenshot taken from?

CC @IBM/carbon-designers to see if our designers have answers to some of above questions. Thanks!

I edited the original comment with the correct token names and added a  ✅  as verified.

thanks @aagonzales !! going thru these double-checks now.
also looking into other outstanding questions. the source of the elect input error screenshot seems to have been updated, i'm looking into reproducing this bug locally to test if it was resolved

update: screenshotted issue marked as resolved; we assume devs apply appropriate margin on wrapper class themselves. may update in future version

issue for Select page on website: https://github.com/carbon-design-system/carbon-website/issues/1276

✅ color token usage verified
✅ spacing token usage verified, aside from custom values, of which there are numerous:
.#{$prefix}--select-input {
    …
    height: rem(40px);
    …
    width: rem(224px);
    min-width: rem(128px);
    max-width: rem(448px);
    padding: 0 rem(34px) 0 $spacing-md; // 1.5rem + chevron width
    …
}

just want to make sure we're not duplicating work, I began a draft PR to address these a few days ago but needed clarification on several of the points that came out of the audit https://github.com/IBM/carbon-components/pull/1978

just assign me as reviewer in whichever PR when its ready

the screenshotted error disappeared after we merged component previews https://github.com/IBM/carbon-components/pull/1983, so the error still persists if we remove the demo styles. opened  https://github.com/IBM/carbon-components/issues/2023 to track this

dev: width should always be the content width plus padding (fluid width) to match design spec. (it will get small with short content)

just to clarify on this point: if we have items of varying width as options in the menu list, do we want the width to change as the user selects different options?

@emyarod i think it is specced so that the currently-displayed value will set what the width of the displayed select field will be. which implies changing widths when other values are selected. @aagonzales or @laurenmrice might be able to answer that question more accurately tho.

@emyarod @lovemecomputer I believe that only the Inline Select would vary in length based on the text within the field. For Normal Selects you should be able to control what width you want to set regardless of text length.

@laurenmrice thanks!! just to verify: will inline select be sized based on the largest option available, or will it be sized based on the currently selected option? (the latter implying that it will change width as you select different options with different text lengths)

will it be sized based on the currently selected option?

This one.

Is this bit of custom logic something we want to roll into our library? I'm not sure there's a reliable way to implement this given our current restrictions (relying on native <select> and avoiding custom logic as much as possible). I ran into a similar situation in #1756, and while I'm fine with adding some custom logic into our component to get this presentational behavior, I want to confirm that this is the direction we want to pursue

@aagonzales I think our select content historically has had a requirement for user to specify its size explicitly, because how its visual is constructed doesn't allow us to auto-size the trigger button upon the content. I see a desire for auto-sizing from designer's perspective, but wondering if we can defer this until we find a trick? CC @tw15egan in case he has an idea.

If the developer can some how control the size that would be acceptable. Especially, with the inline selects, the arrow can become very disassociated with the field input.

after discussion btwn @emyarod and @aagonzales, we decided to leave Inline Select width as-is (fixed width). product teams will be able to set their own width manually for the time being.
further fixes and development to achieve dynamic width for Select can be tracked post-v10-launch here: https://github.com/IBM/carbon-components/issues/2063
@emyarod 's PR for select, which should resolve vanilla issues listed in this Audit post: https://github.com/IBM/carbon-components/pull/1978
thanks y'all! close to completion aside from checking react

@aagonzales @lovemecomputer thanks for the clarification, I've marked the PR as ready for review