Custom roles do not work with launch template mixed groups

I have issues
I'm submitting a...

[x] bug report
[ ] feature request
[ ] support request
[ ] kudos, thank you, warm fuzzy

What is the current behavior?
Right now iam_instance_profile_name is incompatible with worker_groups_launch_template_mixed.
If this is a bug, how to reproduce? Please include a code sample if relevant.
Using 1 classic worker_group and 1 worker_group_launch_template_mixed and setting
  manage_worker_iam_resources = false
  iam_instance_profile_name = "whatever"

results in:
4 errors occurred:
        * module.k8s.module.eks.aws_iam_instance_profile.workers_launch_template_mixed[1]: 1 error occurred:
        * aws_iam_instance_profile.workers_launch_template_mixed.1: Either `role` or `roles` (deprecated) must be specified when creating an IAM Instance Profile

        * module.k8s.module.eks.aws_iam_instance_profile.workers_launch_template_mixed[2]: 1 error occurred:
        * aws_iam_instance_profile.workers_launch_template_mixed.2: Either `role` or `roles` (deprecated) must be specified when creating an IAM Instance Profile

        * module.k8s.module.eks.aws_iam_instance_profile.workers_launch_template_mixed[3]: 1 error occurred:
        * aws_iam_instance_profile.workers_launch_template_mixed.3: Either `role` or `roles` (deprecated) must be specified when creating an IAM Instance Profile

        * module.k8s.module.eks.aws_iam_instance_profile.workers_launch_template_mixed[0]: 1 error occurred:
        * aws_iam_instance_profile.workers_launch_template_mixed.0: Either `role` or `roles` (deprecated) must be specified when creating an IAM Instance Profile

What's the expected behavior?
The expected behavior would be that the EC2 instances would launch with the given IAM role.
Are you able to fix this problem and submit a PR? Link here if you have already.
Manually setting iam_role_id to "" seems to fix the issue, but then breaks creating IAM roles for when we want manage_worker_iam_resources to be true.
Environment details

Affected module version: 4.0.2
OS: macOS
Terraform version: 0.11.14

Any other relevant info
I can share the Terraform code if needed.
CC @bmihaescu, @markmunozoz

I am thinking this may be due to https://github.com/terraform-aws-modules/terraform-aws-eks/blob/758fdab1ee770e82af805f801eb357c3ba28e9f9/workers_launch_template_mixed.tf#L118-L123 ignoring iam_instance_profile_name but I am already too confused by the level of interpolation to be sure.

Aaaaaand this is fixed in https://github.com/terraform-aws-modules/terraform-aws-eks/pull/381. Of course I had to create an issue before finding that 🤦♂
I can confirm that fixes the issue so I am closing this. Apologies for the spam.


[feat] Add support for class directives

A directive makes available a method defined in a class to the execution of the class body during its creation.
A directive simply captures the arguments passed to it and all directives are stored in a registry inside the class. When the final object is created, they will be applied to that instance by calling the target method on the freshly created object. As soon as they are applied, they set to point to the actual object method, since they have served their purpose. This allows us to export functions such as depends_on() at the class level.
Currently, only depends_on() is exposed as a directive, but in the future the skip test functions would also be.
This builds on top of #1865.
Todos

[ ] Update documentation

Codecov Report

Merging #1868 (3d20133) into master (ed40b22) will increase coverage by 0.06%.
The diff coverage is 95.71%.

@@            Coverage Diff             @@
##           master    #1868      +/-   ##
==========================================
+ Coverage   87.61%   87.68%   +0.06%
==========================================
  Files          49       50       +1
  Lines        8141     8207      +66
==========================================
+ Hits         7133     7196      +63
- Misses       1008     1011       +3

Impacted Files
Coverage Δ

reframe/core/deferrable.py
98.04% <ø> (ø)

reframe/core/directives.py
95.00% <95.00%> (ø)

reframe/core/meta.py
99.15% <95.00%> (-0.85%)
:arrow_down:

reframe/core/decorators.py
97.14% <100.00%> (+0.05%)
:arrow_up:

reframe/core/namespaces.py
93.22% <100.00%> (+0.11%)
:arrow_up:

reframe/core/pipeline.py
92.03% <100.00%> (+0.05%)
:arrow_up:

Continue to review full report at Codecov.

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

I do get that having that general method to export any member function as a directive is far more flexible, but I feel like it's a bit of an overkill for just one directive.

Currently, it's just for one.. The plan is to use this mechanism for the skip function functionality, with skip() and/or skip_if() function.

Regarding the syntax for dependencies, that would require a complete redesign of the dependencies. I see your point, but I'm not sure it's worth the effort. The fact also that you name the dependencies, I find it a bit confusing as a user. It fits better for an internal implementation rather than a user API, imho. I prefer the depends_on() syntax.

This would be more consistent with what we have right now for the other built-ins and it would avoid the name mangling in the pipeline (which I would try to avoid at all costs).

The name mangling does not interfere with the pipeline. We're not mangling any pipeline method.

Regarding the syntax for dependencies, that would require a complete redesign of the dependencies. I see your point, but I'm not sure it's worth the effort. The fact also that you name the dependencies, I find it a bit confusing as a user. It fits better for an internal implementation rather than a user API, imho. I prefer the depends_on() syntax.

Perhaps that's something for the getdeps PR then 🙃
What about inheritance? As far as I understand from this, a test dependency would not be inherited along by any child class. Is this right? I feel like that we're blurring the line between the test class and the test instance here. My view is that things which get declared at the class level MUST be inherited by any child class; whereas things that get specified at the instance level are just "private" to that instance (which is what happens for both variables and parameters). This is why I was thinking of different functions for specifying the dependencies at the class level and the instance level. The way I see this, a class may define dependencies for its tests, but the class itself does not depend on these dependencies; the tests themselves do. This is why I suggested the name dependency for the directive, because you're just creating a new dependency here, but the class itself does not depend_on that dependency.

The name mangling does not interfere with the pipeline. We're not mangling any pipeline method.

I meant having depends_on being an alias to _D_depends_on.

Dependencies are inherited properly. Check this out:
import reframe as rfm
import reframe.utility.sanity as sn

class Base(rfm.RunOnlyRegressionTest):
    valid_systems = ['*']
    valid_prog_environs = ['*']
    executable = 'echo'

    @rfm.run_before('run')
    def set_exec_opts(self):
        self.executable_opts = [self.name]

    @rfm.run_before('sanity')
    def set_sanity_check(self):
        self.sanity_patterns = sn.assert_found(rf'{self.name}', self.stdout)

@rfm.simple_test
class T0(Base):
    pass

class TX(Base):
    depends_on('T0')

@rfm.simple_test
class T1(TX):
    pass

@rfm.simple_test
class T2(TX):
    pass

This will make T1 and T2 depend on T0:
- T2:
   <...>
    Dependencies (conceptual):
      T0

    Dependencies (actual):
      - ('T2', 'generic:default', 'builtin') -> ('T0', 'generic:default', 'builtin')

- Τ1:
   <...>
    Dependencies (conceptual):
      T0

    Dependencies (actual):
      - ('T1', 'generic:default', 'builtin') -> ('T0', 'generic:default', 'builtin')

But you spotted a very subtle detail! This works nicely because none of T1, T2 defines __init__() so they end up invoking the augmented __init__() of TX, which applies the directives and therefore they also get the dependencies. If I define T1 as follows:
@rfm.simple_test
class T1(TX):
    def __init__(self):
        pass

Then T1 is independent. I would have to call super().__init__() to get it right. Technically, this is no different than currently: if TX was doing self.depends_on('T0') and I forgot to do super().__init__() in T1 I would again miss the dependency.
This PR has a meaning if we want to eliminate the use of __init__() and this was its original assumption. In that case, as I showed, inheritance works nicely. I do believe that we don't need __init__(), and we can replace its functionality, which is literally very-very specific to test filtering only, with a post-init hook as in #1865. All the rest of the test functionality can either be defined in the class body or in the various pipeline hooks. Nothing is needed in the __init__() except if you want to change the tags or the valid_prog_environs, and for this you can have a hook. Then we, as framework, gain control of the __init__() and we can do the directive magic. I would argue that mixing __init__() with directives or __init__() with post-init hooks is not something users should do, unless they know what they are doing. There are two alternatives in writing tests, therefore: (a) the classic way: __init__() without directives and without  post-init hooks, (b) the new way without __init__(), but with directives and post-init hooks if necessary.

Instead of augmenting the __init__(), we could possibly apply the directives in _rfm_init() and avoid this artifact here.

Indeed, augmenting _rfm_init() instead of __init__() works nicely avoiding the side effects described above when users define __init__() and inheritance works nicely in all cases. It will also simplify a lot the part in the metaclass that applies the directives, since _rfm_init is always there and there is no need to specialize for the hooks.

I meant having depends_on being an alias to _D_depends_on.

I don't see this as a problem, users will not ever call the esoteric function. Also, after the initialization depends_on() behaves exactly as before, when it wasn't a directive, so that the syntax self.depends_on() is legitimate. The only problem I see is with the documentation :-) We will have to move it to the rst and add an explicit entry for the depends_on class method.

@jjotero For parametrised tests, it is true that you have to do it with hooks, but why should we restrict the depends_on() to only define it in an init hook? Usually, the dependency information is static; if not, then yes, it should go in a hook. Skip functions may make little sense to be directives, but I can see use cases there as well. Currently, if my tests have dependencies, there is no way to write it without dependencies, whereas you can write the sanity patterns in the class body if you redirect the standard output/error of your executable to a file. But if you have dependencies, you will be obliged to have a hook and a post-init hook particularly, nothing else: if you add a dependency at a later stage, it will be simply ignored. Isn't this also counter-intuitive?

why should we restrict the depends_on() to only define it in an init hook?

Because that locks a class to a specific dependency and it will prevent you from deriving and extending the dependency if you want to. For example:
@rfm.simple_test
class A(rfm.RegressionTest):
   ...

@rfm.simple_test
class B(rfm.RegressionTest):
    depends_on('A')
    ...

All good so far, but say that someone imports the above into another file and does
import the.other.module as m
@rfm.simple_test
class A1(m.A):
    '''Extend the functionality of A'''

@rfm.simple_test
class B1(m.B):
    '''This class now depends on both A and A1, which doesn't make much sense.'''
    depends_on('A1')

Here if you want to run only B1, you're still forced to register both A and A1 even though you don't need A at all. Otherwise you simply get a could not resolve dependency error. However, if you have the dependencies in an init hook, you can just override them if you want to. This is why I still think that test dependencies belong to the instance and not the class.
With fixtures in mind, fixtures MUST be defined in the class body because a fixture is a building block for the test itself (the test requires of the fixture for it to be complete). But this is not the case with dependencies, where a test may or may not need the dependency to run.
So in short, I think that if it belongs in the class body, it's because it is a fixture, else, it's a dependency and should be attached as a hook.

whereas you can write the sanity patterns in the class body if you redirect the standard output/error of your executable to a file.

Sanity patterns are different because they do not depend on anything external to the class where they're defined. It doesn't matter what you do with it, a derived class can always override it.

if you add a dependency at a later stage, it will be simply ignored.

The same applies to every other test variable that is used at some point along the pipeline, right? I think this is more than fine as long as we state clearly that dependencies and test skipping conditions must not be defined beyond the post-init stage.

Ok, it agains boils down to the dependencies vs. fixtures thing. I think you are probably right. Dependencies should be something more dynamic, although this is not the actual case, since they are used as (and are shown to be used as) fixtures. I am a bit disappointed to have to close this PR, because I feel like throwing quite some effort out of the window... Anyway, I will keep my branch for future reference in case we need to implement directives.


chore: Replace poetry with uv

Replaces the python project manager with uv.
For most commands that used poetry before, it just be as easy as replacing poetry {things} with uv {things}.
Some notable exeptions:

Instead of poetry install --with extra1,extra2,
use uv sync --extra extra1 --extra extra2.
Note that will delete any extraneous packages/extras so the venv state is deterministic.
Add --inexact if you want to replicate the old poetry behaviour.

poetry shell is no longer available. The preferred workflow is to uv run / uvx things, to ensure you are always in sync with the project definition.
If that's too annoying, it is always possible to source .venv/bin/activate.

Updates the justfile, so using that should be the same as before.

This one also needs an updated devenv.lock

I added a --locked flag to the uv sync calls.
That will cause the check to fail if uv.lock is out of date.


Remove duplicate rspec dependencies from gemspec

Hi there,
This PR addresses issue #26, removing the duplicate dependency :)
Happy to hear feedback!

Thank you for this small but clean PR.


Formatting Options, private/internal keyword formatting

Are there settings for private/internal keyword formatting?
Something like:
"PrivateMethodKeyword": "Leave", //Leaves private keyword as is for methods (ether specified or not)
"PrivateFieldKeyword": "Remove", //Removes private keyword if it's specified for fields
"InternalClassKeyword": "Add", //Adds internal keyword if doesn't exist before class

I was unable to find anything similar to this in Here

This is not possible at the moment via the formatter - it only deals with code formatting (indentation, new lines, spacing, wrapper and so on) rather than code simplification.
The closest you could get to something similar (although that is a bit of stretch) is to install Roslynator Refactorings and use it to help you manually change accessibility.

@DustinCampbell
Can you're tell when? https://github.com/OmniSharp/omnisharp-vscode/issues/1726 ~2 year ago


Refactor solver preference searching.

This resolves a couple bugs in the solver's preference search. First,
multiple ordered constraints (i.e. Dependency) on a single
Installable are searched properly now. Second, the search will make a
selection for each dependency constraint in the solution, whereas
before it would bail as soon as it's known to be SAT.
Searching has also been refactored to be tested independently from
solving, with a fake of S.

This PR failed tests for 1 times with 1 individual failed tests and 5 skipped tests. A test is considered flaky if failed on multiple commits.

totaltestcount: 1
flaketestcount: 1
skippedtestcount: 5
flaketests:

classname: End-to-end
name: 'Package Manifest API lists available Operators from Catalog Sources Given
a CatalogSource created using gRPC catalog source type when the display name
for catalog source is updated should successfully update the CatalogSource
field'
counts: 1
details:

count: 1
error: |4-
/home/runner/work/operator-lifecycle-manager/operator-lifecycle-manager/test/e2e/packagemanifest_e2e_test.go:247
error updating catalogSource
Unexpected error:
    <*errors.StatusError | 0xc000dbc8c0>: {
        ErrStatus: {
            TypeMeta: {Kind: "", APIVersion: ""},
            ListMeta: {
                SelfLink: "",
                ResourceVersion: "",
                Continue: "",
                RemainingItemCount: nil,
            },
            Status: "Failure",
            Message: "Operation cannot be fulfilled on catalogsources.operators.coreos.com \"catalog-rbwn2\": the object has been modified; please apply your changes to the latest version and try again",
            Reason: "Conflict",
            Details: {
                Name: "catalog-rbwn2",
                Group: "operators.coreos.com",
                Kind: "catalogsources",
                UID: "",
                Causes: nil,
                RetryAfterSeconds: 0,
            },
            Code: 409,
        },
    }
    Operation cannot be fulfilled on catalogsources.operators.coreos.com "catalog-rbwn2": the object has been modified; please apply your changes to the latest version and try again
occurred
/home/runner/work/operator-lifecycle-manager/operator-lifecycle-manager/test/e2e/packagemanifest_e2e_test.go:261

meandurationsec: 15.799529
skippedtests:
classname: End-to-end
name: 'Catalog image update'
counts: 1
details: []
meandurationsec: 0.385987
classname: End-to-end
name: 'Subscriptions create required objects from Catalogs Given a Namespace
when a CatalogSource is created with a bundle that contains prometheus objects
creating a subscription using the CatalogSource should have created the expected
prometheus objects'
counts: 1
details: []
meandurationsec: 2.16355
classname: End-to-end
name: 'Installing bundles with new object types when a bundle with a pdb, priorityclass,
and VPA object is installed should create the additional bundle objects'
counts: 1
details: []
meandurationsec: 0
classname: End-to-end
name: 'Subscription updates existing install plan'
counts: 1
details: []
meandurationsec: 0.040567
classname: End-to-end
name: 'Subscriptions create required objects from Catalogs Given a Namespace
when a CatalogSource is created with a bundle that contains prometheus objects
creating a subscription using the CatalogSource should install the operator
successfully'
counts: 1
details: []
meandurationsec: 2.291503


Add clinical review

https://www.ebi.ac.uk/panda/jira/browse/ENSVAR-4594

Merged into release/105 and master


Sample Robot Script?

A sample robot script showing how test steps are run and update Zephyr would be help us understand how to wire this up.  Do you have any samples?  Showing 1 Zephyr test case (with multiple steps) being execute would be terrific.

Library should register itself as a listener by just taking it to use in Robot-files. Test management tool is then recognized by the settings.
Currently status is uploaded for whole test case only, as step amount might be hard to keep same.
I don't have Zephyr available now, so can't test if there has been changes on that after the development.


Some scattered notes on possible changes to rad-lang.

Superseded by https://github.com/radicle-dev/transparent-machines-doc.


fixed misspelled word

'overriden' should be 'overridden'
http://dictionary.reference.com/browse/overridden

Thanks! Bonus points if you could update the commit message to be sth. like chore(docs-shredder): fixes misspelled word


[sc -17119] Enable codecov

Description of changes

Shortcut story linked

sc-17119
Pull request checklist

[X] I have performed a self-review of my own code
[ ] I have tested that my change works
[ ] I have updated documentation (if applicable)

Tokens have been added as per https://github.com/SGNL-ai/adapter-sgnl/pull/50


Add tests for iree-run-module inputs.

A few people have asked about scalar inputs, i1 inputs, and npy inputs/outputs. This gives a test we can point people at.
Also updated the "developer overview" docs to embed the tests:

Fixes https://github.com/openxla/iree/issues/14911

Tweaked the comments but left the si32 thing unaddressed. Also added a section to the docs (using those faaaancy embeds)

@dcaballe does this answer your questions on https://github.com/openxla/iree/issues/14911?

worth making that simple_abs example not take a scalar tensor - it's weird now to see --input=f32=-2 as one could think that's a scalar f32 but that'd really be --input=-2.0 (-2 would parse as an integer)

worth making that simple_abs example not take a scalar tensor - it's weird now to see --input=f32=-2 as one could think that's a scalar f32 but that'd really be --input=-2.0 (-2 would parse as an integer)

Revised iree-run-module.mlir and the docs. PTAL


form_params not sending

Guzzle version(s) affected: 6.3^
Description
I'm using Guzzle to send a post request, however the form_params can't be found on the server.
How to reproduce
          $client = new HttpClient([
            'base_uri' => url(''),
            'http_errors' => false
          ]);

          // Guzzle is not guzzling.
          // form params not sending...
          $freeBetResponse = $client->post('pulse/server/api/wallet?cmd=PLACE_FREE_BET&generateBetId=true', [
            'form_params' => [
              'account_id' => $player->id,
              'game_id' => $game->id,
              'amount' => 0
            ],
            'headers' => [
              'Authorization' => 'ApiKey ' . $apiKey->key
            ]
          ]);

Additional context
Here is what I'm doing on the server then to debug:
$database->Debug('ACCOUNT ID FROM API  : : ' . print_r($_REQUEST, true));

Which outputs:
(
    [cmd] => PLACE_FREE_BET
    [generateBetId] => true
)

From the context of the issue this does not seem neither as a bug nor as a feature request. Support questions should be addressed to other channels like https://github.com/guzzle/.github/blob/master/SUPPORT.md
If there is something that I miss please feel free to provide more context.


Support both LEFT and RIGHT direction

Would you like to implement this? I think it could be more efficient to use:
SwipeMenuLayout.setSwipeDirection(DIRECTION_LEFT | DIRECTION_RIGHT);
SwipeMenuLayout.setLeftView();
SwipeMenuLayout.setRightView();

It already supported left and right direction (the same menu view).
Do you mean the different menu view of left and right direction?

Ok, how can i use both left and right direction with only one menu. In case
of 2 unique menu, it already supported?

No, It not support that yet (with 2 unique menu).

I will implement that at the next version.
Thanks.

Great, thank you.

This library is good for swipe actions.
It will be great if we can have these 2 options:

can add left/right menus at a time on one item.
if one menu is already opened and we try to open another menu, right now it closes the opened one.
// is not touched the opened menu view, so we intercept this touch event if (mTouchPosition != oldPos && mTouchView != null && mTouchView.isOpen()) {                  mTouchView.smoothCloseMenu(); }
It can be done, close already opened menu and open new one.

Thanks

@thuckechsu @swatigoel
Hello, LEFT and RIGHT direction supported in the new version.
Thanks!

thanks a lot.. will try it :)

awesome, thank you


Better handling on platforms where os/user.Current() is not implemented

Closes #287
Code should not panic when the package os/user's Current() function isn't implemented.  Instead try to get the environment variable HOME.
Changed the 'constructor' function for the directory discovery to accept a directory parameter.  This better articulates the dependency (the name of the directory) and allows future tests to better control the directory to scan for the discovery code under testing.
Changed the mains to use the Dir() function which computes the default directory, as the input.

Please sign your commits following these rules:
https://github.com/docker/docker/blob/master/CONTRIBUTING.md#sign-your-work
The easiest way to do this is to amend the last commit:
$ git clone -b "287-os-user" git@github.com:chungers/infrakit.git somewhere
$ cd somewhere
$ git rebase -i HEAD~842353372976
editor opens
change each 'pick' to 'edit'
save the file and quit
$ git commit --amend -s --no-edit
$ git rebase --continue # and repeat the amend for each commit
$ git push -f

Amending updates the existing PR. You DO NOT need to open a new one.

Current coverage is 69.56% (diff: 22.22%)

Merging #294 into master will decrease coverage by 0.02%

@@             master       #294   diff @@
==========================================
  Files            25         25
  Lines          1302       1301     -1
  Methods           0          0
  Messages          0          0
  Branches          0          0
==========================================
- Hits            906        905     -1
  Misses          319        319
  Partials         77         77

Powered by Codecov. Last update 8fa8129...fc16e8f


Send Metervalues data to OCPP server

Hi Matth,
I am trying to send the meter values like voltage, current, energy, and frequency to the OCPP server. But unable to send MeterValues.req to OCPP.
I added the below functions in the setup function,
Is there anything I need to add in a void loop or any library files?
`
addMeterValueInput([]
{ return readVoltage(); },
"Voltage", "V", nullptr, "L1");
addMeterValueInput(
{ return readCurrent(); },
"Current.import",
"A");
addMeterValueInput([]
{ return readEnergy(); },
"Energy.Active.Import.Register", "Wh");
addMeterValueInput([]
{ return readFreaquency(); },
"Frequency", "Hz");`

Not even the Energy.Active.Import.Register is sent? That's weird.
Does the code even run the MeterValues::createReq() function? You can check that by adding a print on ArduinoOcpp/MessagesV16/MeterValues.cpp
If it's running try adding the following code to the end of the createReq() function:
String reqSent;

serializeJson(*doc, reqSent);

Serial.println(reqSent);
return doc;

This will print on the serial monitor the message that's being sent to the Central System, you can post it here if you want further help.
Also, check #110

Also, did you successfully connect to the Ocpp server through OCPP_initialize() ?

@pedro-fuoco
Thank you very much for your response.
I added "Energy.Active.Import.Register" in setup function.
`void setup()
{
Serial.begin(115200);
Serial.print(F("[main] Wait for WiFi: "));
#if defined(ESP8266)
WiFiMulti.addAP(STASSID, STAPSK);
while (WiFiMulti.run() != WL_CONNECTED)
{
Serial.print('.');
delay(1000);
}
#elif defined(ESP32)
WiFi.begin(STASSID, STAPSK);
while (!WiFi.isConnected())
{
Serial.print('.');
delay(1000);
}
#else
#error only ESP32 or ESP8266 supported at the moment
#endif
Serial.println(F(" connected!"));
std::shared_ptr<ArduinoOcpp::Configuration<const char *>> mvSampledData = ArduinoOcpp::declareConfiguration<const char *>("MeterValuesSampledData", "", CONFIGURATION_FN);
const char *example = *mvSampledData;                                                                                // example: read value of configuration
mvSampledData = "Voltage,Current.import,Energy.Active.Import.Register,Frequency, Power.Active.Import, Temperature"; // example: update configuration value
ArduinoOcpp::configuration_save();                                                                                // write configs file back to flash immediately (not really necessary though)
/

Initialize the OCPP library
*/
OCPP_initialize(OCPP_HOST, OCPP_PORT, OCPP_URL);

setEnergyMeterInput(
{
static ulong lastSampled = millis();
static float energyMeter = 0.f;
if (getTransactionId() > 0)
    energyMeter += ((float) (millis() - lastSampled)) * 0.003f; //increase by 0.003Wh per ms (~ 10.8kWh per h)
lastSampled = millis();
return energyMeter; });

addMeterValueInput([]
{ return readVoltage(); },
"Voltage", "V", nullptr, "L1");
addMeterValueInput(
{ return readCurrent(); },
"Current.import",
"A");
addMeterValueInput([]
{ return readEnergy(); },
"Energy.Active.Import.Register", "Wh");
addMeterValueInput([]
{ return readFreaquency(); },
"Frequency", "Hz");
addMeterValueInput(
{ return (float)50.000f; },
"Power.Active.Import",
"kW");
addMeterValueInput(
{ return (float)23.220f; },
"Temperature",
"deg");
setConnectorPluggedInput(
{
//return true if an EV is plugged to this EVSE
return false; },
1);
bootNotification("AC4", "S2: 22kW");
pinMode(chargingPin, OUTPUT);
}`
Also successfully connected to the OCPP server charger available, preparing, charging and finishing states are working properly in my code.
***************************** Logs above mentioned states********************************
Charger Condition:ev_connect
[AO] info (.pio/libdeps/esp32dev/ArduinoOcpp/src/ArduinoOcpp.cpp:308): Added ConnectorPluggedSampler. Transaction-management is in auto mode
now
0
[AO] info (.pio/libdeps/esp32dev/ArduinoOcpp/src/ArduinoOcpp/MessagesV16/StatusNotification.cpp:50): New status: Preparing (connectorId 1)
Charger Condition:start_charging
[main] Transaction initiated. StartTransaction will be sent when ConnectorPlugged Input becomes true
[main] Authorizing user with idTag NO.000000192468
0
[AO] info (.pio/libdeps/esp32dev/ArduinoOcpp/src/ArduinoOcpp/Tasks/ChargePointStatus/ConnectorStatus.cpp:237): Session mngt: trigger StartTransaction
Allowed to charge
isTransactionRunning
1
[AO] info (.pio/libdeps/esp32dev/ArduinoOcpp/src/ArduinoOcpp/MessagesV16/StatusNotification.cpp:50): New status: Charging (connectorId 1)
Allowed to charge
isTransactionRunning
1
Charger Condition:stop_charging
[main] End transaction by RFID card
1
[AO] info (.pio/libdeps/esp32dev/ArduinoOcpp/src/ArduinoOcpp/Tasks/ChargePointStatus/ConnectorStatus.cpp:280): Session mngt: trigger StopTransaction
[AO] info (.pio/libdeps/esp32dev/ArduinoOcpp/src/ArduinoOcpp/MessagesV16/StartTransaction.cpp:145): Request has been accepted
[AO] info (.pio/libdeps/esp32dev/ArduinoOcpp/src/ArduinoOcpp/MessagesV16/StatusNotification.cpp:50): New status: Finishing (connectorId 1)
[AO] info (.pio/libdeps/esp32dev/ArduinoOcpp/src/ArduinoOcpp/MessagesV16/StopTransaction.cpp:187): Request has been accepted!
Charger Condition:ev_disconnect
[AO] info (.pio/libdeps/esp32dev/ArduinoOcpp/src/ArduinoOcpp.cpp:308): Added ConnectorPluggedSampler. Transaction-management is in auto mode
now
0
[AO] info (.pio/libdeps/esp32dev/ArduinoOcpp/src/ArduinoOcpp/MessagesV16/StatusNotification.cpp:50): New status: Available (connectorId 1)
Do i need to call MeterValues::createReq() in setup as well as in loop?

The code and the logs look good

Do i need to call MeterValues::createReq() in setup as well as in loop?

No, MeterValues::createReq() is called by the library during the OCPP_loop. In fact it is called every minute after the charger starts a transaction. Did you wait more than a minute in the Charging state to see if the values were sent?

Thank you very much @pedro-fuoco
Now I am able to send metervalues to OCPP server.
Allowed to charge
isTransactionRunning
1
Allowed to charge
isTransactionRunning
1
Allowed to charge
isTransactionRunning
1
{"connectorId":1,"transactionId":671421,"meterValue":[{"timestamp":"2023-03-17T04:55:19.000Z","sampledValue":[{"value":"0","context":"Sample.Periodic","measurand":"Energy.Active.Import.Register","unit":"Wh"},{"value":"230","context":"Sample.Periodic","measurand":"Voltage","phase":"L1","unit":"V"},{"value":"124","context":"Sample.Periodic","measurand":"Current.import","unit":"A"},{"value":"1244","context":"Sample.Periodic","measurand":"Energy.Active.Import.Register","unit":"Wh"},{"value":"50","context":"Sample.Periodic","measurand":"Frequency","unit":"Hz"}]}]}
Allowed to charge
isTransactionRunning
1
Can i change the period of meter values?
Also the reading context is Sample.Periodic,  but could not found Transaction.Begin and Transaction.End.

Hi,
You can change the period with MeterValueSampleInterval.
By default, Transaction.Begin and Transaction.End is turned off. You can set the desired parameters in the Configuration Key StopTxnSampledData just like MeterValuesSampledData for normal Meter Values. These values will appear in the StopTransaction message then.

Could you please share the full code?
Even if you analyze arduinoOCPP.cpp, there is difficulty in implementing meter sending. Any help would be appreciated.

@matth-x
Hi,
I am facing issues while sending the meter values for the "context=Transaction.Begin", as for start transaction we need to send context as Transaction.Begin, but in the OCPP server logs I am able to see only context=Sample.Periodic.
Following snippet from server logs.
I have also attached the snippet of void setup of my code.
ERROR FROM OCPP SERVER*****
023-03-23 11:22:08 DEBUG [Thread-351] ServerCoreResponseEvent:179 - Meter Values information*
2023-03-23 11:22:08 DEBUG [Thread-351] ServerCoreResponseEvent:180 - Meter Value Request :: MeterValuesRequest{connectorId=1, transactionId=597335, meterValue.length=1, isValid=true}
2023-03-23 11:22:08 DEBUG [Thread-351] ServerCoreResponseEvent:219 - Charger :: /AC_CHARGER1
2023-03-23 11:22:08 DEBUG [Thread-351] ServerCoreResponseEvent:220 - User :: NO.000000192468
2023-03-23 11:22:08 DEBUG [Thread-351] ServerCoreResponseEvent:221 - Time Elapsed :: 00:01:03
2023-03-23 11:22:08 DEBUG [Thread-351] ServerCoreResponseEvent:222 - Rate :: 10.0
2023-03-23 11:22:08 DEBUG [Thread-351] ServerCoreResponseEvent:235 - Meter Sample Value :: SampledValue{value=230, context=Sample.Periodic, format=null, measurand=Voltage, phase=L1, location=null, unit=V, isValid=true}
2023-03-23 11:22:08 DEBUG [Thread-351] ServerCoreResponseEvent:235 - Meter Sample Value :: SampledValue{value=124, context=Sample.Periodic, format=null, measurand=Current.import, phase=null, location=null, unit=A, isValid=true}
2023-03-23 11:22:08 DEBUG [Thread-351] ServerCoreResponseEvent:235 - Meter Sample Value :: SampledValue{value=1941, context=Sample.Periodic, format=null, measurand=Energy.Active.Import.Register, phase=null, location=null, unit=Wh, isValid=true}
2023-03-23 11:22:08 ERROR [Thread-351] ServerCoreResponseEvent:414 - Error in MeterValue request ::
java.lang.NullPointerException: null
at ocpp1_6.events.ServerCoreResponseEvent.handleMeterValuesRequest(ServerCoreResponseEvent.java:354) [classes!/:1.0.0]
at eu.chargetime.ocpp.feature.profile.ServerCoreProfile.handleRequest(ServerCoreProfile.java:82) [v1_6-1.0.1.jar!/:?]
at eu.chargetime.ocpp.feature.ProfileFeature.handleRequest(ProfileFeature.java:54) [common-1.0.jar!/:?]
at eu.chargetime.ocpp.Server$1.handleRequest(Server.java:104) [common-1.0.jar!/:?]
at eu.chargetime.ocpp.SimplePromiseFulfiller.fulfill(SimplePromiseFulfiller.java:41) [common-1.0.jar!/:?]
at eu.chargetime.ocpp.AsyncPromiseFulfillerDecorator$1.run(AsyncPromiseFulfillerDecorator.java:43) [common-1.0.jar!/:?]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_191]
END ERROR FROM OCPP SERVER*****
void setup function****************
void setup()
{
/*

Initialize Serial and WiFi
*/
Serial.begin(115200);
Serial.print(F("[main] Wait for WiFi: "));
#if defined(ESP8266)
WiFiMulti.addAP(STASSID, STAPSK);
while (WiFiMulti.run() != WL_CONNECTED)
{
Serial.print('.');
delay(1000);
}
#elif defined(ESP32)
WiFi.begin(STASSID, STAPSK);
while (!WiFi.isConnected())
{
Serial.print('.');
delay(1000);
}
#else
#error only ESP32 or ESP8266 supported at the moment
#endif

Serial.println(F(" connected!"));
/*

Initialize the OCPP library
*/
OCPP_initialize(OCPP_HOST, OCPP_PORT, OCPP_URL);

/*

Integrate OCPP functionality. You can leave out the following part if your EVSE doesn't need it.
*/

addMeterValueInput([]
{ return readVoltage(); },
"Voltage", "V", nullptr, "L1");
addMeterValueInput(
{ return readCurrent(); },
"Current.import",
"A");
addMeterValueInput([]
{ return readEnergy(); },
"Energy.Active.Import.Register", "Wh");
addMeterValueInput([]
{ return readFreaquency(); },
"Frequency", "Hz");
addMeterValueInput(
{ return readPower(); },
"Power.Active.Import",
"kW");
addMeterValueInput(
{ return readTemp(); },
"Temperature",
"Celsius");
std::shared_ptr<ArduinoOcpp::Configuration<const char *>> mvSampledData = ArduinoOcpp::declareConfiguration<const char *>(
"MeterValuesSampledData", "", CONFIGURATION_FN);
*mvSampledData = "Voltage,Current.import,Energy.Active.Import.Register,Frequency, Power.Active.Import,Temperature";
ArduinoOcpp::configuration_save();
setConnectorPluggedInput(
{
//return true if an EV is plugged to this EVSE
return false; },
1);
int connectorId = 1; // select connectorId 0, 1 or 2
/*

Notify the Central System that this station is ready
*/
bootNotification("AC4", "S2: 22kW");

pinMode(ledPin, OUTPUT);
}
void setup function end****************
Is there any configuration which will send the the metervalue for the

context=Transaction.Begin
context=Sample.Periodic  //Its working fine

Please have a look and help me to solve this issue.

Hi @matth-x and @jpily,
I am little bit confused regarding when to send meter values.
Please correct my understanding if it is wrong. The flow is mentioned below as per my understanding.

StartTransaction.req with the meterStart value
MeterValues.req with the context as Transaction.Begin   (Send meterValues to represent data related to beginning of transaction)
MeterValues.req with the context as Sample.Periodic      (Send meterValues periodically)
StopTranscation.req with the meterStop value

//////////OR/////////////

StartTransaction.req with the meterStart value
MeterValues.req with the context as Sample.Periodic      (Send meterValues periodically)
StopTranscation.req with the meterStop and transactionData containing Transaction.Begin & Transaction.End

My Questions:

The power consumption will be based on meterStart & meterStop  OR
The power consumption will be based on Transaction.Begin & meterStop

It is difficult to answer with simple information. Please post the complete code used by the arduino IDE. The basic test for the code I am developing has been completed.
RFID (Authentication) -> Start of charging -> Charging -> RFID (Recognition)-> End of charging

I have summarized the function execution order based on the OCPP 1.6 charging scenario as follows:
OCPP_initialize(): Initializes the OCPP library.
bootNotification(): Sends a signal to the charging station that the charging station has completed booting.
authorize(): Performs user authentication.
beginTransaction(): Notifies the charging station that the charging has started.
setConnectorPluggedInput(): Detects that the vehicle is connected to the charger.
setEvReadyInput(): Detects that the vehicle is ready for charging.
setEvseReadyInput(): Detects that the charging station is ready for charging.
addMeterValueInput(): Adds energy meter values.
setOnResetNotify(): Registers a callback function to receive notifications when the charger is reset.
setOnResetExecute(): Registers a callback function to execute when the charger is reset.
setOnUnlockConnectorInOut(): Registers a callback function to execute when the vehicle completes charging and the connection is released.
setConnectorLockInOut(): Locks the charger so that the connection cannot be released while the vehicle is charging.
setTxBasedMeterInOut(): Registers the meter value to measure the energy usage of the charging vehicle.
stopTransaction(): Notifies the charging station that the charging has completed.
OCPP_deinitialize(): Deinitializes the OCPP library.
Of these functions, OCPP_initialize(), OCPP_loop(), and OCPP_deinitialize() functions must be called. The remaining functions are called as needed according to the scenario.

@matth-x @pedro-fuoco @jpily
Thank you very much for your support. This library really helping us.

Thank you very much @pedro-fuoco
Now I am able to send metervalues to OCPP server.
Allowed to charge isTransactionRunning 1 Allowed to charge isTransactionRunning 1 Allowed to charge isTransactionRunning 1 {"connectorId":1,"transactionId":671421,"meterValue":[{"timestamp":"2023-03-17T04:55:19.000Z","sampledValue":[{"value":"0","context":"Sample.Periodic","measurand":"Energy.Active.Import.Register","unit":"Wh"},{"value":"230","context":"Sample.Periodic","measurand":"Voltage","phase":"L1","unit":"V"},{"value":"124","context":"Sample.Periodic","measurand":"Current.import","unit":"A"},{"value":"1244","context":"Sample.Periodic","measurand":"Energy.Active.Import.Register","unit":"Wh"},{"value":"50","context":"Sample.Periodic","measurand":"Frequency","unit":"Hz"}]}]} Allowed to charge isTransactionRunning 1

@matth-x @jpily
One quick question on value field of the each meterValue.
Why the value are not showing "230.14" instead of "230"?
My declaration in the setup function is mentioned below

void setup(){
OCPP_initialize(OCPP_HOST, OCPP_PORT, OCPP_URL);
addMeterValueInput([]
{ return (int32_t) readVoltage(1); },
"Voltage", "V", nullptr, "L1", 1);
addMeterValueInput(
{ return (int32_t) readCurrent(1); },
"Current.Import",
"A", nullptr, "L1", 1);
addMeterValueInput([]
{ return (int32_t) readEnergy(1); },
"Energy.Active.Import.Register", "Wh", nullptr, "L1", 1);
std::shared_ptr<ArduinoOcpp::Configuration<const char *>> mvSampledData = ArduinoOcpp::declareConfiguration<const char *>("MeterValuesSampledData", "DEFAULT VALUE", CONFIGURATION_FN);
*mvSampledData = "Voltage,Current.Import,Energy.Active.Import.Register"; // example: update configuration value
ArduinoOcpp::configuration_save();
}

All the parameter read function are returning double.
Is there any configuration setting I need to do to get "230.90" instead of "230"?

@dipankarkhartad you are casting the return of your functions as (int32_t) before returning to addMeterValueInput. Try removing that cast.
The library should accept floats since #125 merged

Got it @pedro-fuoco
Thank you.

@pedro-fuoco Thank you, I got it.


Can't download two Github artifacts in the same release pipeline

Agent Version and Platform
Version of your agent? 2.158.0
OS of the machine running the agent? Linux
Azure DevOps Type and Version
dev.azure.com
If dev.azure.com, what is your organization name? https://dev.azure.com/vimla
What's not working?
I have a release pipeline (setup with the classic UI) that includes one pipeline artifact (which is not used, only for triggering the builds) and two GitHub artifacts.  The issue is that the second Github artifact always fails to download.  It doesn't matter what repo it is.  I've changed the order, I've changed the repos, always the same result. Only thing I will note is that they are both always private (connected using the GitHub Azure Pipelines app).  Every time, I get the same error message and stacktrace (first couple lines added for context):
2019-10-09T15:37:32.7804647Z Downloaded linked artifact devops
2019-10-09T15:37:32.7806488Z Starting artifacts download...
2019-10-09T15:37:33.0596835Z ##[error]Downloading artifacts failed: System.InvalidOperationException: NotFound
   at Microsoft.VisualStudio.Services.Agent.Worker.Release.Artifacts.GitHubHttpClient.GetUserRepo(String accessToken, String repositoryName)
   at Microsoft.VisualStudio.Services.Agent.Worker.Release.Artifacts.GitHubArtifact.GetArtifactDetails(IExecutionContext context, AgentArtifactDefinition agentArtifactDefinition)
   at Microsoft.VisualStudio.Services.Agent.Worker.Release.ReleaseJobExtension.<>c__DisplayClass46_0.<ConvertToArtifactDefinition>b__1()
   at Microsoft.VisualStudio.Services.Agent.Worker.Release.RetryExecutor.Execute(Action action)
   at Microsoft.VisualStudio.Services.Agent.Worker.Release.ReleaseJobExtension.ConvertToArtifactDefinition(AgentArtifactDefinition agentArtifactDefinition, IExecutionContext executionContext, IArtifactExtension extension)
   at Microsoft.VisualStudio.Services.Agent.Worker.Release.ReleaseJobExtension.DownloadArtifacts(IExecutionContext executionContext, IList`1 agentArtifactDefinitions, String artifactsWorkingFolder)
   at Microsoft.VisualStudio.Services.Agent.Worker.Release.ReleaseJobExtension.DownloadArtifactsAndCommitsAsync(IExecutionContext executionContext, Object data)
2019-10-09T15:37:33.0653937Z ##[error]NotFound

I think that what is happening is that the same token is being used by the task for both calls but GitHub invalidates it after the first one is successful, maybe?  Either way, it's a real bummer.  Am I missing something obvious or is this truly an issue?

Just experienced this bug today


No code available

Hi, Haytham,
I found this link on your paper, and may I ask when the code will be available?  Thanks a lot.
Best,
Cindy

Hi,Haytham,
I found your paper that has a link,and could you enjoy your code?Thank you very much.
Yours,
Frank

+1

+1

+1

Hi haythm,
Could you upload the code
thank u


android: fix path in plugin.xml

Hello,
Thanks for trying to fix Ionic.
Won't that change break cordova? The manifest path is right for Cordova. If ionic moved it (or if ionic uses an outdated version of cordova), it is not something we want to support as we aim to be Cordova compatible first.

I have no idea. But you check other plugin.xml they seem to write path as I did in this PR.

Sorry, but I'm not going to merge something that might break Cordova. The current path works fine, and I'm positive that others have used this version of the plugin with Ionic.
Please try using an older version of the plugin, such as 1.7.4

If you really need this pr, I suggest you fork this repo and use your fork as a dependency

I'm experiencing problems with the plugin:
AndroidRuntime: java.lang.RuntimeException: Unable to start receiver com.batch.cordova.android.BatchCordovaPushReceiver: java.lang.IllegalArgumentException: No such service ComponentInfo{com.mycompany.myapp/com.batch.cordova.android.BatchCordovaPushService}
AndroidRuntime:        at android.app.ActivityThread.handleReceiver(ActivityThread.java:3978)
AndroidRuntime:        at android.app.ActivityThread.access$2300(ActivityThread.java:273)
AndroidRuntime:        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2036)
AndroidRuntime:        at android.os.Handler.dispatchMessage(Handler.java:112)
AndroidRuntime:        at android.os.Looper.loop(Looper.java:216)
AndroidRuntime:        at android.app.ActivityThread.main(ActivityThread.java:7593)
AndroidRuntime:        at java.lang.reflect.Method.invoke(Native Method)
AndroidRuntime:        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)
AndroidRuntime:        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:987)
AndroidRuntime: Caused by: java.lang.IllegalArgumentException: No such service ComponentInfo{com.mycompany.myapp/com.batch.cordova.android.BatchCordovaPushService}
AndroidRuntime:        at android.os.Parcel.createException(Parcel.java:1957)
AndroidRuntime:        at android.os.Parcel.readException(Parcel.java:1921)
AndroidRuntime:        at android.os.Parcel.readException(Parcel.java:1871)
AndroidRuntime:        at android.app.job.IJobScheduler$Stub$Proxy.enqueue(IJobScheduler.java:215)
AndroidRuntime:        at android.app.JobSchedulerImpl.enqueue(JobSchedulerImpl.java:58)
AndroidRuntime:        at androidx.core.app.JobIntentService$JobWorkEnqueuer.enqueueWork(JobIntentService.java:342)
AndroidRuntime:        at androidx.core.app.JobIntentService.enqueueWork(JobIntentService.java:522)
AndroidRuntime:        at androidx.core.app.JobIntentService.enqueueWork(JobIntentService.java:500)
AndroidRuntime:        at com.batch.cordova.android.BatchCordovaPushService.enqueueWork(BatchCordovaPushService.java:37)
AndroidRuntime:        at com.batch.cordova.android.BatchCordovaPushReceiver.onReceive(BatchCordovaPushReceiver.java:18)

When I apply the fix here, it works without a problem.
Also, the official cordova-documentation doesn't have any path in their examples:
https://cordova.apache.org/docs/en/latest/plugin_ref/spec.html#config-file
https://cordova.apache.org/docs/en/3.0.0/plugin_ref/spec.html#config-file
So I wouldn't know why there should be a difference between "cordova"-Applications and "ionic"-Applications.

I'm experiencing problems with the plugin:
AndroidRuntime: java.lang.RuntimeException: Unable to start receiver com.batch.cordova.android.BatchCordovaPushReceiver: java.lang.IllegalArgumentException: No such service ComponentInfo{com.mycompany.myapp/com.batch.cordova.android.BatchCordovaPushService}
AndroidRuntime:        at android.app.ActivityThread.handleReceiver(ActivityThread.java:3978)
AndroidRuntime:        at android.app.ActivityThread.access$2300(ActivityThread.java:273)
AndroidRuntime:        at android.app.ActivityThread$H.handleMessage(ActivityThread.java:2036)
AndroidRuntime:        at android.os.Handler.dispatchMessage(Handler.java:112)
AndroidRuntime:        at android.os.Looper.loop(Looper.java:216)
AndroidRuntime:        at android.app.ActivityThread.main(ActivityThread.java:7593)
AndroidRuntime:        at java.lang.reflect.Method.invoke(Native Method)
AndroidRuntime:        at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:524)
AndroidRuntime:        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:987)
AndroidRuntime: Caused by: java.lang.IllegalArgumentException: No such service ComponentInfo{com.mycompany.myapp/com.batch.cordova.android.BatchCordovaPushService}
AndroidRuntime:        at android.os.Parcel.createException(Parcel.java:1957)
AndroidRuntime:        at android.os.Parcel.readException(Parcel.java:1921)
AndroidRuntime:        at android.os.Parcel.readException(Parcel.java:1871)
AndroidRuntime:        at android.app.job.IJobScheduler$Stub$Proxy.enqueue(IJobScheduler.java:215)
AndroidRuntime:        at android.app.JobSchedulerImpl.enqueue(JobSchedulerImpl.java:58)
AndroidRuntime:        at androidx.core.app.JobIntentService$JobWorkEnqueuer.enqueueWork(JobIntentService.java:342)
AndroidRuntime:        at androidx.core.app.JobIntentService.enqueueWork(JobIntentService.java:522)
AndroidRuntime:        at androidx.core.app.JobIntentService.enqueueWork(JobIntentService.java:500)
AndroidRuntime:        at com.batch.cordova.android.BatchCordovaPushService.enqueueWork(BatchCordovaPushService.java:37)
AndroidRuntime:        at com.batch.cordova.android.BatchCordovaPushReceiver.onReceive(BatchCordovaPushReceiver.java:18)

When I apply the fix here, it works without a problem.
Also, the official cordova-documentation doesn't have any path in their examples:
https://cordova.apache.org/docs/en/latest/plugin_ref/spec.html#config-file
https://cordova.apache.org/docs/en/3.0.0/plugin_ref/spec.html#config-file
So I wouldn't know why there should be a difference between "cordova"-Applications and "ionic"-Applications.

Hi,
Ionic finds the config element fine, as it adds the broadcast receiver just fine (which is why the crash happens, the receiver expects that the service if there).
However, it seems to ignore the service for some unknown reason, even though they're both in the same config element. Meaning that Ionic picks up our change but only partially applies it.
A workaround we found is to add the batch plugin AFTER adding the android platform. If you add the plugin before the platform, the incorrect manifest is generated.
You can also make a custom pre build task that patches the manifest using a javascript hook.
The definitive solution is to bypass Ionic's broken manifest configuration by providing an AAR and letting Google's Gradle plugin merge the manifests.

Hi,
Ionic finds the config element fine, as it adds the broadcast receiver just fine (which is why the crash happens, the receiver expects that the service if there).
However, it seems to ignore the service for some unknown reason, even though they're both in the same config element. Meaning that Ionic picks up our change but only partially applies it.
A workaround we found is to add the batch plugin AFTER adding the android platform. If you add the plugin before the platform, the incorrect manifest is generated.
You can also make a custom pre build task that patches the manifest using a javascript hook.
The definitive solution is to bypass Ionic's broken manifest configuration by providing an AAR and letting Google's Gradle plugin merge the manifests.

Hm, adding the plugin after adding the platform would mean chaning our CI-build scripts ... I'd rather live with having our own fork of the plugin and use that instead.
Since we will be using our own fork anyways: Is it okay to update the SDK version used from 1.13.0 to 1.16.1 in dist/src/android/batch.gradle? Or will there be problems mixing the latest SDK with the current plugin's Java code?

Regarding cordova not specifying any path in their example: if we don't do that, we run into other problems that result in the manifest not being properly modified either.

Could you please elaborate what kind of non-proper modifications there might be? Push notifications seem to be working. We didn't yet test the analytics/statistics since we are using the DEV keys for now.
Thank you!

Hm, adding the plugin after adding the platform would mean chaning our CI-build scripts ... I'd rather live with having our own fork of the plugin and use that instead.
Since we will be using our own fork anyways: Is it okay to update the SDK version used from 1.13.0 to 1.16.1 in dist/src/android/batch.gradle? Or will there be problems mixing the latest SDK with the current plugin's Java code?

Regarding cordova not specifying any path in their example: if we don't do that, we run into other problems that result in the manifest not being properly modified either.

Could you please elaborate what kind of non-proper modifications there might be? Push notifications seem to be working. We didn't yet test the analytics/statistics since we are using the DEV keys for now.
Thank you!

adding the plugin after adding the platform would mean chaning our CI-build scripts

I understand that. It's the only workaround we've found so far.
This issue needs to be fixed upstream, but has been going on for years. I wouldn't hold my breath.

Is it okay to update the SDK version used from 1.13.0 to 1.16.1

It should be.
Note that 1.16.1 requires androidx, so you might need to tweak the plugin's build.gradle to use androidx deps. You might also need to tweak your cordova project accordingly.
This is something that we will eventually update in the plugin too: androidx migration is inevitable.

Could you please elaborate what kind of non-proper modifications there might be?
By "not being properly modified", I mean not modified at all. Unfortunately your fix might work for you with a specific cordova-android version, but we handle a range of versions and Cordova's plugin API isn't exactly stable.

If the manifest isn't modified at all, handling of notifications when the app is in the foreground might be broken.
It's relatively easy to check if your manifest is merging properly: build the final apk, open it with jadx-gui and see if you see BatchCordovaPushReceiver and BatchCordovaPushService in the manifest.

adding the plugin after adding the platform would mean chaning our CI-build scripts

I understand that. It's the only workaround we've found so far.
This issue needs to be fixed upstream, but has been going on for years. I wouldn't hold my breath.

Is it okay to update the SDK version used from 1.13.0 to 1.16.1

It should be.
Note that 1.16.1 requires androidx, so you might need to tweak the plugin's build.gradle to use androidx deps. You might also need to tweak your cordova project accordingly.
This is something that we will eventually update in the plugin too: androidx migration is inevitable.

Could you please elaborate what kind of non-proper modifications there might be?
By "not being properly modified", I mean not modified at all. Unfortunately your fix might work for you with a specific cordova-android version, but we handle a range of versions and Cordova's plugin API isn't exactly stable.

If the manifest isn't modified at all, handling of notifications when the app is in the foreground might be broken.
It's relatively easy to check if your manifest is merging properly: build the final apk, open it with jadx-gui and see if you see BatchCordovaPushReceiver and BatchCordovaPushService in the manifest.

Your reaction time is impressive :)
About AndroidX: Yes, our apps are already using it despite current cordova recommondation not to use it yet.
In our APK's Manifest (with the changes in this PR applied) I can see:
<service android:name="com.batch.cordova.android.BatchCordovaPushService" android:permission="android.permission.BIND_JOB_SERVICE"/>
<receiver android:name="com.batch.cordova.android.BatchCordovaPushReceiver" android:permission="com.google.android.c2dm.permission.SEND">

Push notifications that arrive while the app is in foreground are shown in the status bar + the phone vibrates. Is that the expected behaviour or should something happen in addition?

Your reaction time is impressive :)
About AndroidX: Yes, our apps are already using it despite current cordova recommondation not to use it yet.
In our APK's Manifest (with the changes in this PR applied) I can see:
<service android:name="com.batch.cordova.android.BatchCordovaPushService" android:permission="android.permission.BIND_JOB_SERVICE"/>
<receiver android:name="com.batch.cordova.android.BatchCordovaPushReceiver" android:permission="com.google.android.c2dm.permission.SEND">

Push notifications that arrive while the app is in foreground are shown in the status bar + the phone vibrates. Is that the expected behaviour or should something happen in addition?

All's good :)

All's good :)


Update deploy-overview.md

Add links to Teams advanced deployment guide available on Setup.Microsoft.Com and Admin Center

@MikePlumleyMSFT PR has been copyedited and is ready for final review, could you please check and merge? Thanks!


Metrics phase 2

This is Phase 2 of Metrics.
This includes metrics that are not built on losses.
The new classes are the xxxxAccuracy set of classes
and the Confusion Matrix set of classes; AUC, FalseNegatives, FalsePositives, PrecisionAtRecall, RecallAtPrecison, Recall, SensitivityAtSpecificity and SpecificityAtSensitivity.
This PR is based on the current master branch including metrics1, and the metrics/losses generic cleanup and is not dependent on other PRs.

@karllessard There seems to be something wrong with the build environment. This is the second PR that created this error on the quick build.
Failed to execute goal on project tensorflow-core-api: Could not resolve dependencies for project org.tensorflow:tensorflow-core-api:jar:0.3.0-SNAPSHOT: Could not find artifact org.tensorflow:tensorflow-core-api:jar:linux-x86_64:0.3.0-20210211.071905-248 in ossrh-snapshots (https://oss.sonatype.org/content/repositories/snapshots) -> [Help 1]

@JimClarke5 I'm seeing that as well when building, locally too.
Your list is missing Precision fyi, although it's implemented.
Would it be possible to add a ConfusionMatrix metric, and a metric to calculate all of the true/false positive/negative stats in the same metric?

The core method for confusion metrics is MetricsHelper.updateConfusionMatrixVariables() an handles all four possibilities true and false positives and true and false negatives.
As far as a ConfusionMatrix metric, how would that be defined?   sklearn.metrics.confusion_matrix()?

The core method for confusion metrics is MetricsHelper.updateConfusionMatrixVariables() and handles all four possibilities true and false positives and true and false negatives.

Yeah, I just want a way to do it by passing a metric to get all 4, rather than relying on internal code.

As far as a ConfusionMatrix metric, how would that be defined? sklearn.metrics.confusion_matrix()?

Sklearn's would work, I was thinking of PyTorch-Lightning's, but hey do the same thing (lightning bases theirs on https://scikit-learn.org/stable/modules/model_evaluation.html#confusion-matrix).  Obviously it doesn't work with multidimensional outputs, but it's a helpful visual way to see which classes are causing errors in classification.  And generating one after evaluation from the existing metrics is hard (if not impossible) since you lose the actual predictions.

I see that TF has tf.math.confusion_matrix().

tfa.metrics.MultiLabelConfusionMatrix seems like a misnomer, it's not a confusion matrix, just the true/false positive/negatives.  The docs aren't super clear though so I could be reading it wrong.  tf.math.confusion_matrix() is exactly what I mean.

@karllessard the build seems to be broken when JavaDoc is run against framework after my last push. It works locally on my computer.

@deansher looks like the CLA bot wants you to approve these commits after the merge.

The core method for confusion metrics is MetricsHelper.updateConfusionMatrixVariables() and handles all four possibilities true and false positives and true and false negatives.

Yeah, I just want a way to do it by passing a metric to get all 4, rather than relying on internal code.

As far as a ConfusionMatrix metric, how would that be defined? sklearn.metrics.confusion_matrix()?

Sklearn's would work, I was thinking of PyTorch-Lightning's, but hey do the same thing (lightning bases theirs on https://scikit-learn.org/stable/modules/model_evaluation.html#confusion-matrix). Obviously it doesn't work with multidimensional outputs, but it's a helpful visual way to see which classes are causing errors in classification. And generating one after evaluation from the existing metrics is hard (if not impossible) since you lose the actual predictions.

I'm a bit late to this party so I'm not sure if it's still relevant, but we have a multiclass confusion matrix in Tribuo which is used as the basis for (almost) all the classification metrics. We construct the confusion matrix, update the necessary values as the predictions come in, and then compute the various evaluation statistics based on that once we've finished receiving examples. You can see how it works here (warning, it is mostly a pile of lambdas) - https://github.com/oracle/tribuo/blob/main/Classification/Core/src/main/java/org/tribuo/classification/evaluation/LabelConfusionMatrix.java, along with the other classes in org.tribuo.classification.evaluation.

@googlebot I consent

@deansher do you have to do this? Or am I missing something.  {AtSign}googlebot I consent.
I tried it but it still complains.

Dean has to do it if he's got a commit in this PR now, it needs it from everyone's username who has commits.

@googlebot I consent

You might need the full stop on the end of that. I assume it's doing an exact string match.

@googlebot I consent.

TF Python, tf.math.confusion_matrix() produces the same result as sklearn.metrics.confusion_matrix. However, in Java, this operation is not generated.  In TF Python, this is implemented in tensorflow/python/ops/confusion_matrix.py. We would have to port this to Java.

FYI, I have implemented math.confusionMatrix in #255, FrameworkOps,  and verified it against TF Python.

Hi @deansher  and @JimClarke5 , just checking here if this PR is ready to be merged, after collecting 320 of your comments :)
If not, do you think it would be worth it to set up a chat room or video call to discuss about it?

I am ready when, @deansher is. The next PR on layers won't be any easier wrt review.

Repeating this at the top level, where it's easier to see (and cc @karllessard): I agree! @JimClarke5 worked long and hard on this code before PR'ing it. Then he and I worked long and hard on it in PR. It's good code. Time for it to live in master.

Ok great sounds good! Good job guys, really! I’ll let you figure out how you want to not lose track of any remaining opened comments/suggestions.


csi-node-driver ImagePullBackOff for csi-node-driver in the Tigera operator and Connection to the datastore is unauthorized error=connection is unauthorized: Unauthorized

csi-node-driver ImagePullBackOff and
Connection to the datastore is unauthorized error=connection is unauthorized: Unauthorized
Expected Behavior
Should be able to pull images from a private repository
Current Behavior
ImagePullSecret is missing for csi-node-driver  in the Tigera operator
Possible Solution
Add ImagePullSecret for csi-node-driver  in the Tigera operator
Steps to Reproduce (for bugs)

helm upgrade --install tigera-calico projectcalico/tigera-operator --version v3.24.5 --namespace calico-system -f b.yaml
where b.yaml contains  installation: registry: registry \n imagePullSecrets: docker-reg-secret: ' '

Context
We can not use new version of Calico if it is not fixed
Your Environment

Calico version: v3.24.5
Orchestrator version (e.g. kubernetes, mesos, rkt): 1.22 eks

Closing this as inactive (might have been fixed?). Feel free to reopen if you're still affected by it (and please provide more info if possible).


Segmentation fault using symmetric eigenvalue problems for large matrices

Cross posting from the julia issue tracker (https://github.com/JuliaLang/julia/issues/55471), symmetric eigenvalue problems (dsyev/dsyevd/dsyevr) seem to be segfaulting for matrix sizes of 64x64 and above on x86_64-linux-gnu using OpenBLAS v0.3.28.
How to reproduce in Julia (using a nightly version > v"1.12.0-DEV.1038" that includes OpenBLAS v0.3.28):
julia> using LinearAlgebra

julia> H = Hermitian(rand(1024, 1024));

julia> eigen(H); # calls `dsyevd`, but the issue is seen for other function as well
[1]    56499 segmentation fault (core dumped)  julia +nightly

System info:
julia> versioninfo()
Julia Version 1.12.0-DEV.1038
Commit 9d222b87d77 (2024-08-12 01:13 UTC)
Build Info:
  Official https://julialang.org/ release
Platform Info:
  OS: Linux (x86_64-linux-gnu)
  CPU: 12 × Intel(R) Core(TM) i7-10750H CPU @ 2.60GHz
  WORD_SIZE: 64
  LLVM: libLLVM-18.1.7 (ORCJIT, skylake)
Threads: 1 default, 0 interactive, 1 GC (on 12 virtual cores)
Environment:
  JULIA_EDITOR = subl

Matrices smaller than 64x64 do not produce this error.

Somewhat strange as there is no obvious (to me) change in 0.3.28 that could have caused this, and no such failures in the LAPACK testsuite even if I increase matrix sizes significantly beyond the defaults. That is at least when compiled with gcc, maybe LLVM18 plays a role here although the cpu seems to be fairly standard AVX2-only

that said, the backtrace (from Julia 1.12.0.DEV.1043 aka 96fd25a764c) has dgemm_itcopy called from dsyr2k_UN (with no changes to either DGEMM or DSYR2K code in 0.3.28, but maybe Julia used a version earlier than 0.3.27 previously ?)

For what is worth, I believe the segmentation fault may depend on the version of GCC used.  I can see it when we compile OpenBLAS with GCC 11 but not with GCC 8.  I'm trying other combinations now.

but maybe Julia used a version earlier than 0.3.27 previously ?

Julia nightly was using OpenBLAS v0.3.27 until 3 days ago.  Upcoming Julia v1.11 will use OpenBLAS v0.3.27 (feature freeze was a few months ago), Julia v1.10 (current stable version) uses OpenBLAS v0.3.23.

I'm trying other combinations now.

It seems to work for me when compiling OpenBLAS with GCC 12.

Can you tell me your build options for OpenBLAS please ? I'm trying with clang/flang-new from LLVM18.1 but getting a missing reference to FortranACharacterCompareScalar1 when I replace the library that comes with the Julia nightly

It seems to work for me when compiling OpenBLAS with GCC 12.

I was wrong with all my references to GCC versions, I forgot a detail that was mentioned in https://github.com/JuliaLang/julia/issues/55471, but not here: the segmentation fault happens when setting the number of threads with openblas_set_num_threads, in particular when using a number of threads larger than 3.  In my tests with different builds I was missing to set the number of threads.

Can you tell me your build options for OpenBLAS please ?

For x86_64 it should be
make USE_THREAD=1 GEMM_MULTITHREADING_THRESHOLD=400 NO_AFFINITY=1 NO_STATIC=1 NUM_THREADS=512 INTERFACE64=1 SYMBOLSUFFIX=64_ DYNAMIC_ARCH=1 TARGET=GENERIC all

As an additional datapoint, I don't get any crash when setting OPENBLAS_NUM_THREADS:
$ OPENBLAS_NUM_THREADS=4 julia +nightly -q
julia> using LinearAlgebra

julia> BLAS.get_num_threads()
4

julia> H = Hermitian(ones(1024, 1024));

julia> eigen(H);

julia>

If the environment variable OPENBLAS_NUM_THREADS is set before starting Julia, we don't call openblas_set_num_threads automatically.
Is there a different setup of threading in OpenBLAS when the env var is set?

I could reproduce it without setting any environment variable, perhaps the difference is just in random memory layout/contents if this turns out to be uninitialized or overflowed memory

Indeed looks like the code reshuffle to support other threading backends has created a loophole for starting a thread without having a memory buffer allocated for it. Working on a patch (or rather, I have a patch but no full understanding of the root cause yet)

@martin-frbg I backported your patch in #4871 with https://github.com/JuliaPackaging/Yggdrasil/pull/9262, but I'm still segmentation faults in some machines, but not everywhere:

AMD Ryzen 9 3950X 16-Core Processor: works
AMD EPYC 7742 64-Core Processor: segfaults
Neoverse-V2 (Nvidia Grace): segfaults

What's interesting is that Ryzen 9 3950X and EPYC 7742 have the same OpenBLAS core type, both "Zen", but Ryzen 9 3950X has also fewer threads.

Out of curiosity, did you manage to craft a C reproducer?  I'm failing badly at that 😞

I haven't even tried yet, and I'm wondering if this may somehow be connected to how Julia uses OpenBLAS (though I couldn't say what might be special about it). If it was that easy to get on the "bad" code path simply by calling TRMM or GEMM, this should have blown up in the LAPACK, numpy and scipy testsuites or even one of our trivial benchmarks prior to the release.

@ViralBShah over at https://github.com/JuliaLang/julia/issues/55471#issuecomment-2291337101 prepared a C program which I can confirm segfaults on a macbook M1 for me with openblas v0.3.28, but not v0.3.23, nor with #4879:
#include <stdio.h>
#include <stdlib.h>

int main() {
    long n = 1024;
    double *a;
    a = (double*) malloc(n*n*sizeof(double));

    openblas_set_num_threads64_(16);

    // Check if the memory has been successfully
    // allocated by malloc or not
    if (a == NULL) {
        printf("Memory not allocated.\n");
        exit(0);
    }

    for(long row=0; row<n; row++){
        for(long col=0; col<=row; col++){
            a[row*n + col] = 1.0;
        }
    }

    // Allocate space for eigenvalues
    double *w;
    w = (double*) malloc(n * sizeof(double));

    if (w == NULL) {
        printf("Memory not allocated.\n");
        exit(0);
    }

    // Leading dimension of the matrix
    long lda = n;

    // workspace query
    double *work = (double*) malloc(sizeof(double));
    long lwork = -1;
    long *iwork = (long*) malloc(sizeof(long));
    long liwork = -1;
    long info = -100;

    char jobz = 'V';
    char uplo = 'U';

    dsyevd_64_(&jobz, &uplo, &n, a, &lda, w, work, &lwork, iwork, &liwork, &info, 1, 1);

    // Workspace allocation
    lwork = work[0];
    work = (double *) malloc(lwork * sizeof(double));
    liwork = iwork[0];
    iwork = (long *) malloc(liwork * sizeof(long));

    dsyevd_64_(&jobz, &uplo, &n, a, &lda, w, work, &lwork, iwork, &liwork, &info, 1, 1);

    // Print eigenvalues
    printf("First 5 Eigenvalues:\n");
    for (int i = 0; i < 5; i++) {
        printf("%f\n", w[i]);
    }

    return 0;
}

However the same program doesn't segfault for me with OpenBLAS v0.3.28 on the other machines I mentioned at https://github.com/OpenMathLib/OpenBLAS/issues/4868#issuecomment-2291038160 where I could still reproduce the segfault after #4871.

However the same program doesn't segfault for me with OpenBLAS v0.3.28 on the other machines I mentioned at https://github.com/OpenMathLib/OpenBLAS/issues/4868#issuecomment-2291038160 where I could still reproduce the segfault after https://github.com/OpenMathLib/OpenBLAS/pull/4871.

Actually, I can reproduce it on the other machines, but I need to increase the number of threads quite a bit, perhaps depending on the system.  For example this segfaults for me on AMD EPYC 7742 with 384 threads:
-    openblas_set_num_threads64_(16);
+    openblas_set_num_threads64_(384);

$ gcc -o test test.c  -L${HOME}/.julia/juliaup/julia-nightly/lib/julia -Wl,-rpath,${HOME}/.julia/juliaup/julia-nightly/lib/julia -lopenblas64_
test.c: In function ‘main’:
test.c:9:5: warning: implicit declaration of function ‘openblas_set_num_threads64_’ [-Wimplicit-function-declaration]
     openblas_set_num_threads64_(384);
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~
test.c:46:5: warning: implicit declaration of function ‘dsyevd_64_’ [-Wimplicit-function-declaration]
     dsyevd_64_(&jobz, &uplo, &n, a, &lda, w, work, &lwork, iwork, &liwork, &info, 1, 1);
     ^~~~~~~~~~
$ ./test
Segmentation fault (core dumped)


Test-NAVApplicationObjectLanguage Logpath Option for this Command

It would be greate to have a -Logpath Parameter like "Import-NAVApplicationObject" to investigate the missing translations
and the Link to "Remove-NAVApplicationObjectLanguage" has a typo.

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

ID: 59fc4afe-27b5-da34-622a-79ec85c24325
Version Independent ID: 0a82d2d1-2fc9-a7d7-5a97-d69124b4f5dc
Content: Test-NAVApplicationObjectLanguage (Microsoft.Dynamics.Nav.Model.Tools)
Content Source: businesscentral-ps/Microsoft.Dynamics.Nav.Model.Tools/Test-NAVApplicationObjectLanguage.md

Hi, thanks your feedback. The typo in the link has been fixed, but with regards to the -Logpath feature suggestion, please submit product ideas through https://aka.ms/bcideas.


#11989: Code clean up

Ticket
Link to Github Issue #11989
Work Done

Removed the global namespace usage for tt::constants in auto_format.hpp.
Added it within the respective functions instead.

Checklist

[x] All Post commit CI
[x]  (Single-card) Model perf tests
[x] (Single-card) Demo tests
[x] (Single-card) Device perf regressions
[x] Nightly fast dispatch tests
[x] [post-commit] models tests
[x] (T3K) T3000 model perf tests
[x] (T3K) T3000 frequent tests
[x] (T3K) T3000 nightly tests

There is no point in having constants namespace if we do using tt::namespace anyway.
I recommend removing this namespace and holding constants in tt namespace instead. This is at least the case for TILE* constants.

That is a good recommendation.  Let's please post a separate PR for that change given it impacts a lot of code.


After using @loadable/babel-plugin the webpack reports module not found

🐛 Bug Report
@loadable/babel-plugin、Module not found
As long as I remove @loadable/babel-plugin  from babel.config.json  it compiles correctly.
ERROR in ./src/components/router/index.tsx
Module not found: Error: Can't resolve '@/pages/' in 'D:\htdocs\react\react-app\src\components\router'
 @ ./src/components/router/index.tsx 54:13-44 26:11-30:15
 @ ./src/components/application/index.tsx
 @ ./src/server.tsx

The code reporting the error is:
const Page = loadable((props: any) => import(/* webpackChunkName: "pages/[request]" */`@/pages/${props.path}`), {
  cacheKey: props => props.path
});

I configured resolve.alias  in webpack,  The error persists even though I use relative path.
To Reproduce
react-app.
git clone -b 3.x https://github.com/kaysonwu/react-app.git

yarn install && yarn build:server

Expected behavior
Compile correctly
Link to repl or repo (highly encouraged)
react-app.
## System:
 - OS: Windows 10 10.0.18363
 - CPU: (8) x64 Intel(R) Core(TM) i5-8250U CPU @ 1.60GHz
 - Memory: 1.74 GB / 7.89 GB
## Binaries:
 - Node: 12.13.1
 - Yarn: 1.21.1
 - npm: 6.13.4
## npmPackages:
 - @loadable/babel-plugin: ^5.12.0 => 5.12.0
 - @loadable/component: ^5.12.0 => 5.12.0
 - @loadable/server: ^5.12.0 => 5.12.0
 - @loadable/webpack-plugin: ^5.12.0 => 5.12.0

@gregberge

For now - just don't use module aliases.
Plus could you explain how you configured them.

@theKashey  I have provided the project, you can download it and try it. Unfortunately, even with relative paths, errors are reported.

out of curiosity (sorry, I cannot download and try your example right now) - try<EMAIL_ADDRESS>ie a bit simpler construction.
The problem is not at the loadable side, the problem is in webpack, which does not like the code generated by the babel plugin.
Thus we have to find something webpack will like, and then might be amend babel plugin  somehow.

Meanwhile I would personally not recommend to use full dynamic import for named chunks/pages. It's cool, but you don't need it.

Thank you for your advice, but let me write repetitive code. I prefer simplicity.  One thing is for sure, the problem must be with @loadable/babel-plugin.  Maybe I should research its source code

/* webpackChunkName: "pages/[request]" */  is the issue. Remove it and it would be ok.
Probably this is what babel plugin is breaking by a some reason.

PS:  add modules:false to your babel config.

@theKashey Thank you for finding out the source of the problem.  @gregberge  It seems you need to update @loadable/babel-plugin to support webpack magic comments.

@theKashey @gregberge I need your help because it can't use the [request] placeholder

I found that something seemed to be deleted in this line of code, so webpack could not find the module

 loadable(() => import(/* webpackChunkName: "pages/exception-404" */'@/pages/exception/404'))
[
  NodePath {
    parent: Node {
      type: 'StringLiteral',
      start: 222,
      end: 245,
      loc: [SourceLocation],
      extra: [Object],
      value: '@/pages/exception/404',
      leadingComments: [Array],
      innerComments: undefined,
      trailingComments: undefined
    },
    hub: {
      file: [File],
      getCode: [Function: getCode],
      getScope: [Function: getScope],
      addHelper: [Function: bound addHelper],
      buildError: [Function: bound buildCodeFrameError]
    },
    contexts: [],
    data: null,
    _traverseFlags: 0,
    state: null,
    opts: null,
    skipKeys: null,
    parentPath: NodePath {
      parent: [Node],
      hub: [Object],
      contexts: [],
      data: null,
      _traverseFlags: 0,
      state: [Object],
      opts: [Object],
      skipKeys: null,
      parentPath: [NodePath],
      context: [TraversalContext],
      container: [Array],
      listKey: 'arguments',
      key: 0,
      node: [Node],
      scope: [Scope],
      type: 'StringLiteral'
    },
    context: null,
    container: [ [Object] ],
    listKey: 'leadingComments',
    key: 0,
    node: {
      type: 'CommentBlock',
      value: ' webpackChunkName: "pages/exception-404" ',
      start: 176,
      end: 221,
      loc: [SourceLocation]
    },
    scope: Scope {
      uid: 123,
      block: [Node],
      path: [NodePath],
      labels: Map {},
      references: [Object: null prototype] {},
      bindings: [Object: null prototype] {},
      globals: [Object: null prototype] {},
      uids: [Object: null prototype] {},
      data: [Object: null prototype] {}
    },
    type: 'CommentBlock'
  }
]

Importing multiple possible targets will report errors， As follows：
loadable((props: any) => import(/* webpackChunkName: "pages/[request]" */ `@/pages/${props.path}`))

[
  NodePath {
    parent: Node {
      type: 'BinaryExpression',
      start: 358,
      end: 381,
      loc: [SourceLocation],
      left: [Node],
      operator: '+',
      right: [Node],
      leadingComments: [Array],
      innerComments: undefined,
      trailingComments: undefined
    },
    hub: {
      file: [File],
      getCode: [Function: getCode],
      getScope: [Function: getScope],
      addHelper: [Function: bound addHelper],
      buildError: [Function: bound buildCodeFrameError]
    },
    contexts: [],
    data: null,
    _traverseFlags: 0,
    state: null,
    opts: null,
    skipKeys: null,
    parentPath: NodePath {
      parent: [Node],
      hub: [Object],
      contexts: [],
      data: null,
      _traverseFlags: 0,
      state: undefined,
      opts: [Object],
      skipKeys: null,
      parentPath: [NodePath],
      context: [TraversalContext],
      container: [Array],
      listKey: 'arguments',
      key: 0,
      node: [Node],
      scope: [Scope],
      type: 'BinaryExpression'
    },
    context: null,
    container: [ [Object] ],
    listKey: 'leadingComments',
    key: 0,
    node: {
      type: 'CommentBlock',
      value: ' webpackChunkName: "pages/[request]" ',
      start: 316,
      end: 357,
      loc: [SourceLocation]
    },
    scope: Scope {
      uid: 125,
      block: [Node],
      path: [NodePath],
      labels: Map {},
      references: [Object: null prototype] {},
      bindings: [Object: null prototype],
      globals: [Object: null prototype] {},
      uids: [Object: null prototype] {},
      data: [Object: null prototype] {}
    },
    type: 'CommentBlock'
  }
]

@loadable/babel-plugin The resulting module cannot be found error, only occurs under webpack compilation.

I don't quite understand. For the import with webpackChunkName already set, @loadable/babel-plugin still deletes and adds it, isn't it redundant? see code

After testing, I have clearly identified the source of the problem. Please refer to my minimal reproduction loadable-babel-plugin
If you just compile with Babel, Page is an aggressive import. Unfortunately, when compiled with ts-loader in webpack, Page becomes BinaryExpression type.
Personally, the responsibility of the chunkName property is to supplement the webpackChunkName annotation for import. So if you set webpackChunkName yourself, it should not do any work. Therefore, I deleted this line of code

@gregberge @theKashey Who can evaluate it? Thank you!


How to strip html from json

Im retrieving json from an html page does alamofire have a function that remove the html or what can you sugest.

There's is nothing built into Alamofire to do this. Also, we use our GitHub project for bug reports and feature requests. In the future, you should open questions like this on Stack Overflow and tag alamofire.
Cheers. 🍻

From our Contribution Guidelines
Asking Questions
We don't use GitHub as a support forum. For any usage questions that are not specific to the project itself, please ask on Stack Overflow instead. By doing so, you'll be more likely to quickly solve your problem, and you'll allow anyone else with the same question to find the answer. This also allows maintainers to focus on improving the project for others.


[Validation] List all validation requirements

#148 introduces a validate_project() function, largely as an interface to functionality that enforces leading zeros. In a follow up PR, this can be extended to run all validation, and include the factoring out of validation functionality. This issue is strongly releated to #198.
I thought @neuroinformatics-unit/neuroinformatics-team this could be a good place to list every possible validation requirement we can think of . Currently things that throw an error / warning include:

subjects or sessions with duplicate id (e.g. no sub-001_id-xxx and sub-01).
do not allow mixing of leading zeros within subject or session. For example sub-01 sub-002 is not allowed, same for session, but sub-001, ses-01 is allowed.
Check the order of dashes and underscores matches that expected by BIDS filename (i.e. -_-_-_-)
subject / session names cannot include spaces
ensure all sub / session level names have prefix sub- or ses- prefix (during file creation)
ensure datatype names are valid (during file creation)

There will be many more needed. Many things need to be caught during creation, because in a real-world project folder it will not be possible to determine what was an intended e.g. subject folder or just another folder that makes up part of the project. We will only be able to validate sub-, ses- prefixed folders (and files?) and datatypes with known names.

Also, maybe it is better to just merge this into #198

the animal ephys BEP already has one we may be able to leverage https://bep032tools.readthedocs.io/en/latest/

Need to refactor, currently due to circular imports we sometimes have to make_folders rather than use the inbuild function e.g. see TODO's e.g.     # TODO: cannot use folders.makefoldesr due to circular import.


Strict-Transport-Security Header not complet submittet

I'm trying to get the strict-transport-security header in python3 with requests.
My code looks like the following:
import requests r = requests.get("https://%s" % domain") print (r.headers)
My problem is that the strict-transport-security header does not contain all data. The real Header looks like max-age=31536010; includeSubDomains; preload, but the header by r.headers['strict-transport-security'] only contains max-age=31536010; includeSubDomains, not the preload which is needed by my application.
Tested on FreeBSD 11.0 and Mint Rosa and Arch 4.8.13

Requests does not amend the headers in any way, so you get what we received. Are there any proxies or other intermediaries which may be amending headers?


CS5356 Homework

Hi,
I've added my details to the github repository.
Please accept.

See my comment above + please squash your commits into 1.

Hi,
I've squashed the commits into one and have renamed the image file as well.

Merged via https://github.com/Cornell-CS5356-Fall2015/cs5356/commit/33090b9a51cdbb6f08375950fb9f2b4ad13a72e6.


feat!: sync new features from Noir

Please read contributing guidelines and remove this line.

Closing this as @sirasistant is taking this over.


Max length of certain URL fields are extremely limited

As an example, the organisation favicon field (https://github.com/casdoor/casdoor/blob/034f28def9360cfc009ee67bb221eb840e593053/object/organization.go#L59C1-L59C72) is limited to 100 characters. 100-character is extremely limited by today's standard; is there a reason why it is so?
Past comment on increasing the limit: https://github.com/casdoor/casdoor/issues/1831#issuecomment-1545069944.

@nan0tube fixed in: https://github.com/casdoor/casdoor/commit/bf730050d54553ff8fda665b6cbe75b8d4e10042

Thanks for the quick fix!
But are you able to share why does the project limits URLs to 200 characters? Just curious, why not say 1000 characters?


Unintuitive adapter syntax

Current syntax for adapters has some peculiarities.
Consider the following example.
        step = Step(
            name='ensembler',
            transformer=Dummy(),
            input_data=['input_1'],
            adapter={'X': [('input_1', 'features')]},
            cache_dirpath='.cache'
        )

This step basically extracts one element of the input. It seems redundant to write brackets and parentheses. Doing
adapter={'X': ('input_1', 'features')},
should be sufficient.
Moreover, to my suprise
adapter={'X': [('input_1', 'features'), ('input_2', 'extra_features')]},
is incorrect, and currently leads to
ValueError: too many values to unpack (expected 2)
My suggestions to make the syntax consistent are:

adapter={'X': ('input_1', 'features')} should map X to extracted features.
adapter={'X': [...]} should map X to a list of extracted objects (specified by elements of the list). In particular adapter={'X': [('input_1', 'features')]} should map X to a one-element list with extracted features.
adapter={'X': ([...], func)} should extract appropriate objects and put them on the list, then func should be called on that list, and X should map to the result of that call.

@grzes314 great idea, it seems intuitive to have it as you described.
Current api is (especially for just one element) very clunky. Also I think one option that could be useful is to be able to pass a chain of functions simply for example np.exp(lambda x: x[0]) or something.

merged in #42. Closing this.


Update nodejs dependencies to use latest ProtobufJs 5.x

Update "protobufjs" from ^4.0.0 to ^5.0.1.

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

cla signed

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

Thanks for your pull request. The automated tests will run as soon as one of the admins verifies this change is ok for us to run on our infrastructure.

Thank you for your contribution, but this change has been superseded by other changes.


Demo not working

when i try to open demo link :- https://allenroyston.herokuapp.com/access/acr-croppie/
its gives application access error.

1 year later the issue persist...


Retained will topic not be deleted in mnesia when disconnected

Environment

OS: Ubuntu 14.04
Erlang/OTP: 19.1
EMQ: emqttd-2.1.0-batea.2

Description
if the will topic is retained, when the client send DISCONNECTED packet to disconnect from server, In the code, I see the will topic in record proto_state is deleted, but it may not be deleted in mnesia table mqtt_retained.  Should the message in mnesia be deleted?  IMO, I think it should be deleted.

@congleetea  It seems there is no spec for the case. @phanimahesh Your opinion?

I believe it should be deleted. There's no use keeping it around in mnesia
anymore after receiving a DISCONNECT packet.


Add searching and sorting algorithms

Added binary search and three types of sorting (Bubble sort, Insertion sort and selection sort) algorithms by Java.

Thank you for appriciating and  accepting my code. I think It is a good
contribution for you repo. ☺
On Fri, 22 Oct 2021, 09:34 Princeton21, @.***> wrote:

Looks great 🎊🎊🎊
Thank you for your contribution.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/Princeton21/Hacktoberfest_DSA_2021/pull/8#issuecomment-949267964,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AMRH7IHDQ2WLPXKRYLXGURLUIDPE3ANCNFSM5GPR3O5A
.
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.


Add support for Aurelle LED panel (3216331P5)

It seems to be fairly new. And hard to actually find on the English  Phillips Hue pages. But I got one of these: https://www.p4c.philips.com/files/3/3216331p5/3216331p5_pss_.pdf. And figured I'd add it to the list of devices to support.

I will add it to my TODO-list.

@kristofferpeterhansel
Could you please provide:
deviceId and profileId

Hey
Would this be something I could extract from the Athom dev tools? I was was looking to see if I could see the device though it. And so far I have not had much success.
/Kristoffer Peterhänsel

On 25 Nov 2018, at 22.39, Erik M M<EMAIL_ADDRESS>wrote:
@kristofferpeterhansel
Could you please provide:
deviceId and profileId
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub, or mute the thread.

Add it as a Generic device first and then check the device information for the device.
If you need more info on doing this we will help you.

Hmm. Maybe I didn't get it correctly into pair mode then. I'll git it another go tonight

Strange. Seems to not be working.

I put it into pairing mode with a dimmer switch (holding down first and third button from the top).
lamp flashes.
I click the add ZigBee button in the Homey app.
Lamp brightens the light (this happens no matter if I do step 3)
Nothing happens in Homey

A reset of the lamp does not seem to do anything either (holding down first button until lap blinks).
Suggestions? Or is there a chance it is incompatible somehow. The included dimmer seems to be the same. So it can't be that different from the other offerings? 😕

Im not sure if you should go thorough with step 1. I usually do it like this.
Reset the bulb with a RWL021 hue dimmer switch. Keep the dimmer close to the bulb and then press on and off at the same time until the bulb flashes. Then i just go and att new zigbee device in homey.
It could also be that it is using ZigBee 3.0 after searching for some info on that particular lamp. And i don´t think that it will be possible to add to Homey in that case. Try contacting Athom support and ask if your particular device will be compatible.

Oh. That is a new key combination I don't think I have tried. I'll give that a shot.
But yeah. I did come across references to ZigBee 3.0 too. But didn't find up with much info from either Philips or Athom about protocol versions - except that Philips started moving to ZigBee 3.0.
Still it seems all the basic infrastructure from Philips has not changed. It is the same bridges and remotes. And 3.0 is supposed to be compatible with Zigbee Light Link that seemed to be used before.

Yay! It worked. Took a couple of attempts (think maybe the remote will sometimes end up behaving as when just holding down the on button?).
But here we go:

Nice thx it´s added to the todo-list.

BTW. Initial testing of 1.4.3 beta seems to indicate it works


The files.insertFinalNewline setting doesn't work in the 1.1.0-insiders build

VSCode Version: 1.1.0-insiders
OS Version: Windows 8

Steps to Reproduce:

Add the user setting: "files.insertFinalNewline": true,
Edit a file and save

I expect that a newline is added at the end of the file. It is in the 1.0 release, but it is not in the 1.1.0-insiders build.

@gwynjudd this setting is coming from an extension? which one?

@bpasero sorry please close this, I'd forgotten to install the final-newline extension in the insiders build


Arrays

PR Checklist:

[x] My submission is formatted according to the guidelines in the contributing guide
[x] My addition is on refer on the language README.md file
[x] My addition does not have a spelling problem
[x] My submission has a proper and user-friendly description of the algorithm
[x] My submission has the time complexity of the algorithm
[x] My submission has sample input-output of the program (NOT FOR PYTHON)

What kind of change does this PR introduce? (check at least one)

[ ] Bugfix
[ ] New algorithm
[x] Optimization in previous algorithms
[ ] Code style update
[ ] Refactor
[x] Documentation
[ ] Other, please describe:

Briefly describe the changes in this PR

This code is used to rotate any matrix 90 degree clock-wise or 90 degree anti-clockwise  inplace
so most optimal solution for matrix rotation based problems
Other information:

PR Checklist:

[x] My submission is formatted according to the guidelines in the contributing guide
[x] My addition is on refer on the language README.md file
[x] My addition does not have a spelling problem
[x] My submission has a proper and user-friendly description of the algorithm
[x] My submission has the time complexity of the algorithm
[x] My submission has sample input-output of the program (NOT FOR PYTHON)

What kind of change does this PR introduce? (check at least one)

[ ] Bugfix
[ ] New algorithm
[x] Optimization in previous algorithms
[ ] Code style update
[ ] Refactor
[x] Documentation
[ ] Other, please describe:

Briefly describe the changes in this PR

This code is used to rotate any matrix 90 degree clock-wise or 90 degree anti-clockwise  inplace
so most optimal solution for matrix rotation based problems
Other information:

changes made successfully


Composable is reset when screen turn off and on

Hi, i want report a bug,
when you turn off and turn on the screen, Composable destination is resetted.
For test i take sample project of the library
and edited it with
@Destination
@Composable
fun AccountScreen(
//    vm: AccountViewModel = viewModel(),
) {

    var abc by remember {
        mutableStateOf("")
    }

    Column {
        TextField(value = abc, onValueChange = {
            abc = it
        }
        )

//        Button(onClick = { vm.onLogoutClick() }) {
//            Text("Logout")
//        }
    }

}

when i turn off and turn on the screen i think the navigation restart.
Library version used: 1.5.2-beta

Hey. I can't quite understand what is the trigger for this, but I have reproduced it without Compose Destinations too. I'm thinking that it may be expected that it could happen. Both with and without Compose Destinations, it sometimes happens, other times it does not.
Anyway, hoist that state to ViewModel and/or use rememberSaveable instead of remember. That will fix it for you :)
Closing this as it is not an issue with this library, let me know how that went for you!

The only thing I've noticed (again, also with vanilla official compose navigation) is that the navBackStackEntry passes through ON_CREATE when this happens and it doesn't when it works as expected.
onStateChanged NavBackStackEntry@86ef65fd - ON_PAUSE
onStateChanged NavBackStackEntry@86ef65fd - ON_STOP <-- Screen turn off
onStateChanged NavBackStackEntry@86ef65fd - ON_CREATE <-- Screen turn on and text field state is lost
onStateChanged NavBackStackEntry@86ef65fd - ON_START
onStateChanged NavBackStackEntry@86ef65fd - ON_RESUME

onStateChanged NavBackStackEntry@5be23c59 - ON_PAUSE
onStateChanged NavBackStackEntry@5be23c59 - ON_STOP <-- Screen turn off
onStateChanged NavBackStackEntry@5be23c59 - ON_START <-- Screen turn on and text field state is kept
onStateChanged NavBackStackEntry@5be23c59 - ON_RESUME

I asked a question on Kotlin slack and Ian Lake from Google just told me to use rememberSaveable if we want the state to be saved. So I guess that's it then 🙂
https://kotlinlang.slack.com/archives/CJLTWPH7S/p1651692124686329?thread_ts=1651691130.284029&cid=CJLTWPH7S