Unable to send email with @sendgrid/mail

Issue Summary
I"m using the hello world example to send an email. I have three firebase environments. It works in one but not the other two. They are paid environments and work to access Stripe (just to eliminate the response that my environments are not configured for external api acess).
The error I'm getting is
The header content contains invalid characters
    at ClientRequest.OutgoingMessage.setHeader (_http_outgoing.js:359:11)
    at new ClientRequest (_http_client.js:85:14)
    at Object.exports.request (http.js:31:10)
    at Object.exports.request (https.js:206:15)
    at Request.start (/user_code/node_modules/@sendgrid/mail/node_modules/request/request.js:747:32)
    at Request.write (/user_code/node_modules/@sendgrid/mail/node_modules/request/request.js:1492:10)
    at end (/user_code/node_modules/@sendgrid/mail/node_modules/request/request.js:545:18)
    at Immediate.<anonymous> (/user_code/node_modules/@sendgrid/mail/node_modules/request/request.js:574:7)
    at runCallback (timers.js:672:20)
    at tryOnImmediate (timers.js:645:5)

From googling it appears that it could be related to an older request/request#2632. Although I'm not sure why this would succeed on one env and fail on two others.
My best guess at this point is because @sendgrid/client uses request: ^2.81.0 which was released on Mar 9, 2017 (before this bug was reported), the bug is still present. Maybe updating the request dependency will fix the issue.
Technical details:

version: "@sendgrid/mail": "^6.3.1",

The issue was a simple copy and paste error. When I copied the API key to my second and third firebase environment I newline character was introduced. Which is exactly inline with the issue I referenced. as that key gets written to the header.

Thanks for following up @ralphsmith80!


fix(azure-ci): Also test on python 3.8

(This is blocking on the release of TensorFlow 2.2, which will add Py3.8 compatibility - see https://github.com/tensorflow/tensorflow/issues/33374 for a long discussion)


Enhancement: Append to support other datatypes

Hi team,
Command Append has recently been migrated and missed support for all available datatypes. We need to make it consistent with Redis. For more context, please go through #1095 comments and unresolved review comments.
Requirements:

[ ] All datatypes are supported and error handling must be consistent.
[ ] updating unit tests to cover new enhancement
[ ] updating all integration test to test new enhancement
[ ] documentation updates with new enhancement

Thanks

@apoorvyadav1111 if noone is assigned on this then I would like to take this
thanks

Thanks for picking this up @shashi-sah2003.

@apoorvyadav1111 the command APPEND works only with string datatype and it will throw error when used with other datatype
you want me to check for all the other datatypes if it's throwing error or not?

Hi @shashi-sah2003 , yes please, we need to handle all datatypes which should be stringified. We need to be consistent with redis, hence, please check the behavior on redis.

@apoorvyadav1111 when I'm trying to append in sorted set then it should give relevant error but the server is being closed immediately and the below error is appeared on terminal, rest all other datatypes is giving relevant error/output

@apoorvyadav1111 I have created draft PR for the above issue with APPEND command pls review it https://github.com/DiceDB/dice/pull/1233
thanks

@apoorvyadav1111 I have created draft PR for the above issue with APPEND command pls review it #1233 also how should I go about fixing this issue or from where it is arising from? thanks

Hi @shashi-sah2003. Are you working on this panic exit? If not, I can raise a fix for it.

Hi @shashi-sah2003 , I ll take a look today afternoon and we can move ahead from there.
Thanks,
Apoorv

@apoorvyadav1111 I have created draft PR for the above issue with APPEND command pls review it #1233 also how should I go about fixing this issue or from where it is arising from? thanks

Hi @shashi-sah2003. Are you working on this panic exit? If not, I can raise a fix for it.

Hey @c-harish I have been assigned this issue and working on it. Instead it would be helpful if you can give your insight on solving this issue?


[Vue-3] Cannot read property 'contains' of null at Proxy.focusIn

I've got multiple Cannot read property 'contains' of null at Proxy.focusIn errors at this line regarding this.$refs.root.

[x] Bug report

Tell about your platform

Vue.js version : 3.0.11
Browser name and version : Chrome 91.0.4472.106 (Dev), Firefox 89.0.1
This package version : 4.0.2

Current behavior
Cannot read property 'contains' of null at Proxy.focusIn errors in browser developer console.
Expected behavior
No errors regarding nullish elements in browser developer console.
Minimal reproduction of the problem with instructions
I have vue-cli project and was getting this error only after building it and serving it at some domain.
I might have got this problem because of possibly wrong component usage such as following:

      <Loading
        active
        loader="dots"
        :is-full-page="false"
      />

I thought I did not need v-model, cause custom component appearance was controlled by loading prop and Loading component was always active.  After adding additional ref variable drived by loading prop, error is gone:

      <Loading
        v-model:active="active"
        loader="dots"
        :is-full-page="false"
      />

  setup(props) {
    const { loading } = toRefs(props);

    const active = ref<boolean>(loading.value);

    watch(loading, (value) => {
      active.value = value;
    });

    return {
      active,
    };
  },

Aftewards, I just wanted to know if v-model is required (even if only UI is needed in some cases) and propose to add some check to this.$refs.root.

I am not sure if you are reporting a bug or asking the right way to use the component.
But if you can make a minimal re-pro on js-fiddle or codesandbox, and write steps to re-produce the issue, would be helpful.
Tip: Please use the component as described in docs.

I am not sure if you are reporting a bug or asking the right way to use the component.

@ankurk91 kinda both, 'cause even if it's not supposed to happen due to inaccurate usage, imho it's better to check if element is not null.
Check example.
Steps to reproduce:

Open container
Click on green box
Close and open container
Click on green box again

-

+

      <Loading
        v-model:active="active"
        loader="dots"
        :is-full-page="false"
      />

Actually you no need to add v-if to parent container.
If you are adding a v-if on parent, you are forcing vue to remove the element from DOM and re-create it.
This is overhead on browser.
The v-model on component will cause it to hide/show, this way component no need bind all events again.
Regarding, checking if this.$refs.root is null, i believe when the component is mounted the this.$refs.root must be always available. I need to investigate why it is null.

It has been one year and no one has reported similar issue


Disable some date

Hello,
Greatly thank for provide the awesome calendar for every android developer. However, I have some issue to ask you. I want to disable some date in the calendar like we have the list of the holiday which needs to disable it.
Days to disable.

<days_off>
<day_off>2016-12-24</day_off>
<day_off>2016-12-25</day_off>
<day_off>2016-12-31</day_off>
<day_off>2017-01-01</day_off>
<day_off>2017-01-07</day_off>
<day_off>2017-01-08</day_off>
<day_off>2017-01-14</day_off>
<day_off>2017-01-15</day_off>
<day_off>2017-01-21</day_off>
<day_off>2017-01-22</day_off>
<day_off>2017-01-28</day_off>
<day_off>2017-01-29</day_off>
<day_off>2017-02-04</day_off>
<day_off>2017-02-05</day_off>
<day_off>2017-02-11</day_off>
<day_off>2017-02-12</day_off>
<day_off>2017-02-18</day_off>
<day_off>2017-02-19</day_off>
</days_off>

Would you show me how to do?
***note: disable date does not refer to min & max date.
thanks,

@hounsokhorn Did you manage to find a solution?

The sample as examples for this, as well as the wiki. Please check there for more information before posting an issue, thank you.


⚠ Spryr has degraded performance

In c92495c, Spryr (https://spryr.com) experienced degraded performance:

HTTP code: 200
Response time: 5694 ms

Resolved: Spryr performance has improved in 6f2ffe2 after 7 minutes.


add info tooltip to createnstreemodal header

Summary

What: Add tooltip to NS tree modal header linking to help center article
Why: Aid users in creating trees
Ticket: [sc-227223]
Env: https://maya-info-frontend.dev.czgenepi.org/
Design: https://www.figma.com/file/anSx7d4wui5D9c8TEeaGGo/Create-Tree---Help-link-refinement?node-id=34%3A76959

Demos

Checklist

[x] I merged latest trunk
[x] I manually verified the change
[x] I added labels to my PR
[x] I either asked design for a review or hid my changes behind a feature flag
[ ] I tested in multiple browsers
[ ] I added relevant unit tests
[ ] I have notified others of changes they need to make locally (migrations, jobs, package updates, etc)

I was just checking the accessibility and it looks like none of our tooltips are accessible with a screen reader (at least not that I could get working).  This isn't specific to this PR though.  Maybe we can work with SDS on this - maybe we could have a hidden indicator that there's a tooltip and a keyboard shortcut to open it?  There's probably best practices somewhere...


[AutoRelease] t2-servicebus-2022-12-07-01858(can only be merged by SDK owner)

https://github.com/Azure/sdk-release-request/issues/2985
Live test success
https://dev.azure.com/azure-sdk/internal/_build?definitionId=1021
BuildTargetingString
azure-mgmt-servicebus
Skip.CreateApiReview
true

issue link:https://github.com/Azure/sdk-release-request/issues/2985


PLAYSTATION(R)3Conteroller - DS3 - STATUS_DEVICE_POWER_FAILURE - code 10 - C000009E

Sony Dualshock 3 - PLAYSTATION(R)3Conteroller shows STATUS_DEVICE_POWER_FAILURE - code 10 - C000009E
I tried resetting the PS3 controller and I have already rebooted the computer, but it still remains the code 10.
Driver: dshidmini v2.2.282.0
Microsoft Windows 11 - 10.0.22000 (X64)
CPU: 11th Gen Intel(R) Core(TM) i7-11800H

DS3 Compatible HID Device
USB\VID_054C&PID_0268\5&2A83CFE&0&4
USB\VID_054C&PID_0268&REV_0100
01806400
DN_HAS_PROBLEM
DN_DISABLEABLE
DN_REMOVABLE
DN_NT_ENUMERATOR
DN_NT_DRIVER
C000009E

Device USB\VID_054C&PID_0268\5&2a83cfe&0&4 configured.
Driver name: oem253.inf
Class Guid : {2b959c9d-a4ed-4464-809d-0f1118cf055d}
Driver date: 11/08/2021
Driver version: 2.2.282.0
Driver provider: Nefarius Software Solutions e.U.
Driver section: dshidmini.USB.NT
Driver classification: 0xFF0001
ID: USB\VID_054C&PID_0268
Drivers: input.inf:USB\Class_03:00FF3202
Father device: USB\ROOT_HUB30\4&1fa01397&0&0

Device USB\VID_054C&PID_0268\5&2a83cfe&0&4 had a problem to start.
Driver name: oem253.inf
Class Guid : {2b959c9d-a4ed-4464-809d-0f1118cf055d}
Service: mshidumdf
Filters: WUDFRd nssmkig
Problem: 0xA
Problem Status: 0xC000009E

I am facing nearly same issue like this i have posted at forums below:
https://forums.vigem.org/topic/651/ps3-controller-blinking-all-four-lights-fast-when-pressing-ps-button-and-then-turns-off-also-no-lights-when-connecting-through-usb-device-manager-shows-ds3-compatible-hid-device-yellow-triangle

We most probably need a trace, will sketch together a small guide on how to do so.

Related to #244


Document new API

Also, don't include app name in the intermediate directory name — name in the artifact file is enough

LGTM, let's merge it and in case of any issues we will create other issues regarding this.
What do you think, @stefanjudis?

@havenchyk @develar
Yeah sure... Everybody feeling comfy with it? I'd then push out a major version bump immediately.

Thanks to everybody for participating. :)

I'd then push out a major version bump immediately.

There is a known issue — https://github.com/develar/electron-complete-builder/issues/3#issuecomment-183512014 — we should use normalize-package-data instead of using raw JSON.parse to read package.json. But I think it is ok to fix it in the next version.

major version

I think, it should be 2.8, but not 3.0 version. According to semserver we should publish 2.8 because we don't break existing API. And we will publish 3.0 when we drop old deprecated API.

I don't have the time currently to check all this... And I saw removal of
the CLI help text so assumed it's breaking. But if it's not. Cool. I'm
really pro semver.
Am 21.02.2016 4:27 nachm. schrieb "Vladimir Krivosheev" <
<EMAIL_ADDRESS>
I'd then push out a major version bump immediately.
There is a known issue — develar/electron-complete-builder#3 (comment)
https://github.com/develar/electron-complete-builder/issues/3#issuecomment-183512014
— we should use normalize-package-data
https://github.com/npm/normalize-package-data instead of using raw
JSON.parse to read package.json. But I think it is ok to fix it in the
next version.
major version
I think, it should be 2.8, but not 3.0 version. According to semserver we
should publish 2.8 because we don't break existing API. And we will publish
3.0 when we drop old deprecated API.
—
Reply to this email directly or view it on GitHub
https://github.com/loopline-systems/electron-builder/pull/162#issuecomment-186843633
.

This seems to missing documentation on how to use the Mac App Store compatible Electron build. electron-packager says you need to pass mas as the platform. This new API complains that I've passed an invalid platform if I do any of the following:
"scripts": {
  "dist": "build --platform=mas"
}

"build": {
  ...
  "platform": "mas"
}

@stefanjudis usage.txt was renamed to to indicate that it is a deprecated usage guide, but compatibility is preserved.
I have fixed Linux maintainer field — #163 (PR based on this branch, you can review only second commit).

@adam-lynch Mas support was added only 4 days ago, it is not yet supported by electron-builder. I will support it once https://github.com/maxogden/electron-packager/pull/255 will be accepted.

@develar cool. I just said in case it was forgotten about :+1:. Do you know how people will be able to use mas with electron-builder? --platform=mas? build:{platform: mas}? Something else?

@adam-lynch Not yet investigated. I don't like platform: mas — we already have target=nsis and will have soon target=rpm...  TBD.

@develar no problem.

@stefanjudis If you don't have time, maybe you can add me as a npm  collaborator, so, I can publish package? Or you can setup publishing on Travis (in any case we should do it to avoid publish on a development machine) and I will draft release (publish on tag). I want to speed up development ;)

@develar Done. Please go ahead.
Btw.
https://www.npmjs.com/package/electron-packager-tf
https://www.npmjs.com/package/electron-builder-tf
What are these about?

@stefanjudis

electron-builder-tf  — temp fork of electron-builder, unused.
electron-packager-tf — temp fork, pending PRs: https://github.com/maxogden/electron-packager/pull/255 and https://github.com/maxogden/electron-packager/pull/251
ava-tf — temp fork, pending PR: https://github.com/sindresorhus/ava/pull/477 (required to simplify test debug).

why do these need to be published?

@develar looks like this is published (new docs are here: https://www.npmjs.com/package/electron-builder) so shouldn't that be 3.0.0 since it has the new API?

@adam-lynch According to semserver, it is not a major release. Version is unromantic and unsentimental :) — no breaking changes — no major version.

no breaking changes

Oh... ok. Thought there was :smile:

@adam-lynch I am pretty sure that there are no breaking changes. And it was our goal to simplify migration. Please file issue and provide details if I am wrong.

why do these need to be published?

Because PR landing takes a lot of time (several weeks :( in the best case). We cannot wait.

Because PR landing takes a lot of time (several weeks :( in the best case). We cannot wait.

You could install them from a github directly?

You could install them from github directly?

windows-installer written in coffee and requires compilation.
Yes, electron-packager can be installed from github directly. Because in any case junk (test directory) is not ignored.

Well, it is easy and more robust to just publish npm package instead of using GH directly.


Fixed for issue 74

Fix for issue #74

[ ] ✨ New feature (non-breaking change which adds functionality)
[x] 🛠 Bug fix (non-breaking change which fixes an issue)
[ ] ❌ Breaking change (fix or feature that would cause existing functionality to change)
[ ] 🧹 Code refactor
[ ] ✅ Build configuration change
[ ] 📝 Documentation
[ ] 🗑 Chore

Thanks for your contribution, however, I think it's better to generalize this behavior in _handleResponse, so I will make a separate PR for it soon

closed in favor of #83
thanks for your PR!


Support versioning

Support versioning using branches (master changes to V3 and  adds V4 branch).

Versioning will be per repo, not branches.


Fix specs for Policy Toolbar Buttons

Fix failing specs introduced in #10763 and temporary  fixed in #11291

@romanblanco : can you, please, test and verify the fix?

@martinpovolny Looks good, specs are passing :+1:


[CONTROL] RequestHandler hasAction doesn't account for inbuilt actions in CMS setups (such as 'index')

If you have the following code setup:
<?php

class HolderPage extends Page
{
    private static $allowed_children = array('ChildPage');
}

class HolderPage_Controller extends Page_Controller
{
}

<?php

class ChildPage extends Page
{
    private static $can_be_root = false;
}

class ChildPage_Controller extends Page_Controller
{
}

Then you cannot create ChildPage with a URLSegment which has the same name as any public function inherited from Page, SiteTree etc.
This is due to the checking which is run in the SiteTree class to check the parent controllers actions before allowing a URLSegment to be set - https://github.com/silverstripe/silverstripe-cms/blob/3.1/code/model/SiteTree.php#L1642
This manifests in RequestHandler at https://github.com/silverstripe/silverstripe-framework/blob/3.1/control/RequestHandler.php#L374 where the $actionsWithoutExtra variable is set as an empty array, causing the following check to return true as if an action exists due to the method_exists which returns true (as Link() does exist as a method).
Adding an $allowed_actions static to the HolderPage like the following fixes the issue, but I feel that it should be accounted for further up the chain.
private static $allowed_actions = array('index');

I'm willing to help fix this, but am unsure what the correct approach would be? It seems like the most viable approach is enforcing that allowed actions must be set on all Controllers, however this is obviously quite a large API change. We cant check the type in the hasAction method as its a class from CMS causing the issue.
If anyone has any ideas of how else to do this, please let me know :)

@stevie-mayhew this is an old one; do you know if it's still occurring in SS4? I think we've overcome this issue from memory?

@sminnee I am not sure. I feel like I haven't run across it but will spend some time looking into it tomorrow and report back.

Cheers, I'm trying to clear out our cobweb issues a bit! ;)


Secp-r1 curve operations

Secp-r1 support will enable Starknet to work with standard mobile phone's hardware for signing, greatly improving the UX of interacting with the chain.
Currently, Secp-r1 operations are supported in the test-runner, but aren't proved. This requires work in the Starknet OS to fully integrate (until this point, the secpr1-related libfuncs can't move to the experimental list of allowed_libfuncs).

Supported.


Android Build Error: resource android:attr not found

I am getting a build error on the dev channel.
Command used: flutter build apk
Error output:
FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app_settings:verifyReleaseResources'.
> java.util.concurrent.ExecutionException: com.android.builder.internal.aapt.v2.Aapt2Exception: Android resource linking failed
  /Users/elias/Documents/GitHub/isontic-Education/build/app_settings/intermediates/res/merged/release/values/values.xml:236: error: resource android:attr/fontVariationSettings not found.
  /Users/elias/Documents/GitHub/isontic-Education/build/app_settings/intermediates/res/merged/release/values/values.xml:237: error: resource android:attr/ttcIndex not found.
  error: failed linking references.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 5m 32s

Doctor Output
Eliass-MBP:isontic-Education elias$ flutter doctor -v
[✓] Flutter (Channel dev, v1.10.14, on Mac OS X 10.15 19A582a, locale en-US)
    • Flutter version 1.10.14 at /Users/Elias/flutter
    • Framework revision 1946fc4da0 (21 hours ago), 2019-10-07 15:23:31 -0700
    • Engine revision 1d62160fdb
    • Dart version 2.6.0 (build 2.6.0-dev.1.0 d6c6d12ebf)

[✓] Android toolchain - develop for Android devices (Android SDK version 28.0.3)
    • Android SDK at /Users/elias/Library/Android/sdk
    • Android NDK location not configured (optional; useful for native profiling support)
    • Platform android-29, build-tools 28.0.3
    • Java binary at: /Applications/Android Studio.app/Contents/jre/jdk/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1343-b01)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 11.0)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Xcode 11.0, Build version 11A420a
    • CocoaPods version 1.7.5

[✓] Android Studio (version 3.4)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin version 38.1.1
    • Dart plugin version 183.6270
    • Java version OpenJDK Runtime Environment (build 1.8.0_152-release-1343-b01)

[✓] VS Code (version 1.38.1)
    • VS Code at /Applications/Visual Studio Code.app/Contents
    • Flutter extension version 3.5.1

[!] Connected device
    ! No devices available

! Doctor found issues in 1 category.

Hi @EliasDeuss,
I've spotted an issue similar to yours
and a possible resolution for it.
Can you please check if this fixes your situation?
Thank you

@iapicca I already have the compile sdk version set to 28

+1

Even I am facing the same issue with compileSdkVersion 28

@EliasDeuss any luck on this issue?

@nihalreddy33 nope

same issue...

same issue...

For some reason after changing  android.enableR8=true to android.enableR8=false an APK is produced with the error still printed in the terminal after running `flutter build apk``. However, while in the master channel, the issue https://github.com/flutter/flutter/issues/40150 is not fixed, even though it should be fixed there. Maybe it's not being built correctly after it ignores the error with missing resources and the fix is somehow not applied?

Same issue here, regardless of compileSDKVersion 28 or 29

@zoechi Can you elevate this to customer blocker. I am still not able to build for android.

This issue should be tag as important imo. It's so frustrated If a developer cannot build a apk with flutter 😞

Hey guys, I got a workaround after few hours trying...

Enable aar, and add a setting_aar.gradle as instruction.

flutter config --enable-build-plugin-as-aar

Change project's gradle version to 5.1.1 (android/gradle/wrapper/gradle-wrapper.properties). You might need to change another version. In my scenario, photo_manager, url_launcher, sharedPreferenced used the latest gradle.

distributionUrl=https\://services.gradle.org/distributions/gradle-5.1.1-all.zip

Change proguard rule

## Flutter wrapper
-keep class io.flutter.app.** { *; }
-keep class io.flutter.plugin.**  { *; }
-keep class io.flutter.util.**  { *; }
-keep class io.flutter.view.**  { *; }
-keep class io.flutter.**  { *; }
-keep class io.flutter.plugins.**  { *; }
-dontwarn io.flutter.embedding.**
-dontwarn android.**

After these changes, I could use flutter run --release successfully. It might be a workaround, worth tried, tho.

@Tokenyet I have tried and it's not building an APK, when I try flutter build apk.

cc @blasten

same issue

just found solution
found the package that throwed that error
then update it's build gradle

After upgrading to app_settings: ^2.0.0, I am not facing this issue.

This issues mostly caused by packages. I had same issue with devicelocale package. After they update the package the issue is solved.

see this https://github.com/adee42/flutter_keyboard_visibility/issues/42#issuecomment-566656630

just found a workaround for this
search the package that throwed that error (my case is :ovprogresshud)
open build.gradle
then update its compileSdkVersion to 28

Thanks It Worked For me

+1 - cant fix it with changing compiling sdk version. Any suggestions ? I tried everything i think.

+1

+1 tried everything above that made sense, did more breaking than fixing.

just found a workaround for this
search the package that throwed that error (my case is :ovprogresshud)
open build.gradle
then update its compileSdkVersion to 28

just found a workaround for this
search the package that throwed that error (my case is :ovprogresshud)
open build.gradle
then update its compileSdkVersion to 28

Thanks, it worked for me too.

See the solution here
https://github.com/flutter/flutter/issues/44760#issuecomment-570803317

The same problem

just found a workaround for this
search the package that throwed that error (my case is :ovprogresshud)
open build.gradle
then update its compileSdkVersion to 28

I did that still same error , even I clear .pub_cach/hosted and flutter clean => same error,
did update all package from pubspec.ymal also => same error

Seems to be an issue with packages updating there android SDK version

I have compileSdkVersion is 28 in build.grade file and flutter version is 1.17 but still getting below errors at the time of generating release apk file:

Android resource linking failed

 C:\Users\charlie\.gradle\caches\transforms-2\files-2.1\e74a1afd426538a36f0d6b21d498af68\core-1.1.0\res\values\values.xml:142:5-173:25: AAPT: error: resource android:attr/fontVariationSettings not found.

 C:\Users\charlie\.gradle\caches\transforms-2\files-2.1\e74a1afd426538a36f0d6b21d498af68\core-1.1.0\res\values\values.xml:142:5-173:25: AAPT: error: resource android:attr/ttcIndex not found.

I have also used below commands
flutter clean
flutter clean pub cache clear
flutter build apk
but nothing is working, your help will be appreciated. Thank you

I have compileSdkVersion is 28 in build.grade file and flutter version is 1.17 but still getting below errors at the time of generating release apk file:

Android resource linking failed

 C:\Users\charlie\.gradle\caches\transforms-2\files-2.1\e74a1afd426538a36f0d6b21d498af68\core-1.1.0\res\values\values.xml:142:5-173:25: AAPT: error: resource android:attr/fontVariationSettings not found.

 C:\Users\charlie\.gradle\caches\transforms-2\files-2.1\e74a1afd426538a36f0d6b21d498af68\core-1.1.0\res\values\values.xml:142:5-173:25: AAPT: error: resource android:attr/ttcIndex not found.

I have also used below commands
flutter clean
flutter clean pub cache clear
flutter build apk
but nothing is working, your help will be appreciated. Thank you

run again, check above error line, it should be showed the package name caused error . then correct that package's build gradle

@nguyenhuutinh thanks a lot.
In my case, it is path_provider package and upgrading it to latest version solved the issue.


Preserve visibility when including Dry::Monads::Do

Closes #128.
Proposed API enhancement for Do.for()

As discussed over on Discourse, it's difficult to
fix Do.for without additional help from the user. I've included a proposal
on how that could be achieved with no breaking changes - but
if the team would rather accept the patches for Do::All and
leave Do.for() for a later time, that's fine with me as well.

@solnic @flash-gordon For your perusal, gentlemen :slightly_smiling_face:

@anicholson thanks for submitting it. I underestimated the complexity of the subject, I'll think if there's a way for preserving visibility without bringing too much complexity to the code

@flash-gordon what have you found? I can't think of a way to fix Do::All that's simpler than what I've got here. Shall I remove the proposal for Do.for so we can get this merged?
/cc @solnic @timriley

@anicholson sorry, I haven't had time for this yet

I think this could be improved by using method_added. Then you could simply check visibility of a method and act accordingly.

@solnic problem is visibility can be changed after method being defined

for context, https://github.com/dylanahsmith/visibility_monitor

@flash-gordon:
visibility can be changed after method being defined

that won't happen, though, unless someone explicitly changes it in code. If the developer decides to protected :foo after it's been wrapped by Do, what's the problem?

@solnic:
I think this could be improved by using method_added. Then you could simply check visibility of a method and act accordingly.

that's exactly what this PR does :)

@anicholson because calling private :foo doesn't actually do a thing when Do::All is used. To illustrate the problem:
class Foo
  prepend(
    Module.new {
      def foo
        super
      end
    }
  )

  def foo
    :value
  end
  private :foo
end

Foo.new.foo # => :value

Or using monads
require 'dry/monads'

class Operation
  include ::Dry::Monads[:result, :do]

  def call(value)
    yield inner(value)
  end

  private def inner(value)
    Success(value)
  end
end

Operation.new.inner(123) # => Success(123)

It's funny this bug (or unspecified behavior at least) has been unnoticed/not reported for a very long time.

@anicholson thanks a lot for this, I rebased this branch and made some tweaks in https://github.com/dry-rb/dry-monads/pull/136 There's still a problem with hiding wrapped methods with private :foo but I'll try to come up with a solution. I'm going to cut a new version next week probably but it depends. There are a few other things I want to include in the next release.

I think it's not possible to handle cases of calling visibility modifiers with arity > 0, i.e. private :foo. Specifically, you can't have it working in both cases arity > 0 and arity == 0.

If we don't override private then later calls with method names won't be detected (:method_added isn't triggered).
If we override private to see its arguments then calling without arguments will stop working https://bugs.ruby-lang.org/issues/16100

I'll go with 1.

A workaround would be using https://github.com/dylanahsmith/visibility_monitor but it's MRI only. So I don't think it's worth it.


trying to use google stack driver

hello ,
I'm trying to figure out how to use the plugin , i'm confused here a bit . there might be a couple of steps missing , appreciate the effort  .
Thanks

also can't find google stackdriver plugin , on the grafana plugin page .

@percival-el it isn't published yet. If you want to use it now, you'll have to install it by hand. Example below.

https://github.com/HumanCellAtlas/metrics/blob/master/Makefile#L69-L74
https://github.com/HumanCellAtlas/metrics/blob/master/Dockerfile#L6

Note: not all features are working yet.

ok , Thanks .
Is there a automated build on the docker store ?

hi,
I geting the following error while trying to build from dockerfile .
" COPY target/grafana.ini /etc/grafana/grafana.ini
COPY failed: stat /var/lib/docker/tmp/docker-builder268304342/target/grafana.ini: no such file or directory "
steps

created a target directory , added the required grafana binaries
extracted the zip file , but there seems to be no .ini file  that has to be copied inside the docker images

let me know if i'm going wrong somewhere .

@percival-el The lines I highlighted in those two files were all you need if you are not configuring grafana with a grafana.ini. Once you have pulled the plugin into a directory called target here is a simpler Dockerfile that should work.
 What you have done is identified a need for better documentation. I would close this issue and just open another one asking specifically for documentation.


Add feature gate for atomic load/store, gate spsc behind loadstore (Alternative fix for #271)

The spsc module should only be build when atomic_polyfill is available. It's a big dependency (pulls in 12 extra dependencies) so for projects that don't need the atomics it's better to hide it behind a (default) feature gate.
I added two new features:

loadstore that pulls in atomic_polyfill for architectures that need it and gates spsc
atomics that enables loadstone and cas (replaces cas as the default feature)

Doing it this way should allow for more granular configuration of architectures, i.e. only pull-in atomic_polyfill if an architecture uses loadstore and doesn't have native support. This pull request does not contain that granularity as I'm not familiar with other architectures.

But this will now unnecessarily pull in atomic-polyfill even for targets with native atomic support

It only gets pulled in for targets which have 'atomic_polufill' as an (optional) dependency. For targets that support load store natively you can use cfgs in the Cargo.toml to only use 'atomic_polyfill' for 'cas'

This is slightly wrong. It's true that specifying atomic_polyfill as a feature only pulls it in as an optional dependency. However it's not possible to only pull it in for cas for some architectures. For that we'd need something like this.


build: migrate to @cucumber/gherkin npm package

The 'gherkin' npm package has been deprecated (even though it's not yet marked as such, see https://github.com/cucumber/cucumber/issues/1421). This PR updates it to the newest version in order to benefit from parser updates.

Thanks, I have been using the new package in other projects, but didn't think to update it here. 👍


Some thoughts (low priority)

Good day!
I have some thoughts not discovered in the issues/PRs. Nobody needs to react, just thoughts.

Snabbdom is written in TypeScript. So, we should describe / put an example in TypeScript. BTW, I don't know the standard way? Maybe move one of our examples to it.

As @nilslindemann noticed in #1088 , we could describe / put an example of a totally cooked project. Bundled with Rollup, Webpack? Maybe move one of our examples to it.

As I noticed in #1088 , we don't have the ## Installation section in  README.md. (A simple one.)

Did we consider which files we store in the NPM package? To store/not to store the source, the tests, etc.

According the changelog is automatically contented de-facto, we should  think more about commit messages and PR titles.

CONTRIBUTING.md looks not full.

README-in_HN.md and README-zh_CN.md will be outdated soon.

Are all devDependencies needed?

We have npm run build which builds everything. But maybe we would extract npm run build-examples, etc.

P.S. Finish to label issues/PRs :).

Thanks!

I would like to repeat/extend/add to these points by @kuraga, what especially interests me to be added to the snabbdom docs:

How to get the examples locally running (see my linked PR).
What may some error messages mean, when running the tests (E.g. the missing CHROME_VERSION env var error).
A simple workflow how to make a website, using snabbdom as a dependency (e.g. using Parcel1/webpack/rollup).
Maybe a Deno workflow.

I promise a German translation of the final docs.

1 Here a working example for Parcel. Feel free to use it in the docs:
npm init -y
npm install --save-dev parcel
npm install snabbdom

Create a src/index.html:
<!doctype html>

        <title>Snabbdom + Parcel Example</title>

Unpatched

Create a src/logic.ts:
import {
    init,
    classModule,
    propsModule,
    styleModule,
    eventListenersModule,
    h,
} from "snabbdom";

const patch = init([
    // Init patch function with chosen modules
    classModule, // makes it easy to toggle classes
    propsModule, // for setting properties on DOM elements
    styleModule, // handles styling on elements with support for animations
    eventListenersModule, // attaches event listeners
]);

const replaceWithLink = () => {
    console.log("Becoming a link");
    patch(greeting, link);
};

const replaceWithGreeting = () => {
    console.log("Becoming a greeting");
    patch(link, greeting);
};

const greeting = h("h1#heading.greeting", { on: { click: replaceWithLink } }, [
    h("span", { style: { color: "blue" } }, "Hello World!"),
    " (click me)",
]);

const link = h("h1#heading.link", { on: { click: replaceWithGreeting } }, [
    "Brought to you by ",
    h("a", { props: { href: "https://github.com/snabbdom" } }, "snabbdom"),
    " (click me again)",
]);

const heading = document.getElementById("heading"); if (!heading) {throw "I need a h1#heading"};

patch(heading, greeting);

Start the parcel dev server:
npx parcel src/index.html


[hmac/dv] Cleanups without functional impact

Put uvm macros at top in hmac_env_cfg,
Improve alignment in multiple files.
Move random variables and constraints from hmac_smoke_vseq and hmac_test_vectors_sha_vseq into hmac_base_vseq (deduplication).
Decrease verbosity of digest comparison to UVM_MEDIUM.
Fix uninitialized hmac_en in hmac_test_vectors_sha_vseq and hmac_test_vectors_hmac_vseq.

kokoro has flow errors; not flagging anything caused by this PR.
@martin-velay: Could you please post the results from the -i all_once run here?

Test Results

Stage
Name
Tests
Max Job Runtime
Simulated Time
Passing
Total
Pass Rate

V1
smoke
hmac_smoke
1.720s
87.190us
1
1
100.00 %

V1
csr_hw_reset
hmac_csr_hw_reset
0.820s
54.645us
1
1
100.00 %

V1
csr_rw
hmac_csr_rw
0.580s
43.645us
1
1
100.00 %

V1
csr_bit_bash
hmac_csr_bit_bash
3.190s
117.003us
1
1
100.00 %

V1
csr_aliasing
hmac_csr_aliasing
2.160s
194.900us
1
1
100.00 %

V1
csr_mem_rw_with_rand_reset
hmac_csr_mem_rw_with_rand_reset
1.530s
90.409us
1
1
100.00 %

V1
regwen_csr_and_corresponding_lockable_csr
hmac_csr_rw
0.580s
43.645us
1
1
100.00 %

hmac_csr_aliasing
2.160s
194.900us
1
1
100.00 %

V1

TOTAL

6
6
100.00 %

V2
long_msg
hmac_long_msg
18.130s
2.156ms
1
1
100.00 %

V2
back_pressure
hmac_back_pressure
7.850s
438.104us
1
1
100.00 %

V2
test_vectors
hmac_test_sha_vectors
4.205m
40.091ms
1
1
100.00 %

hmac_test_hmac_vectors
0.770s
40.310us
1
1
100.00 %

V2
burst_wr
hmac_burst_wr
9.490s
5.266ms
1
1
100.00 %

V2
datapath_stress
hmac_datapath_stress
40.430s
5.432ms
1
1
100.00 %

V2
error
hmac_error
1.166m
2.423ms
1
1
100.00 %

V2
wipe_secret
hmac_wipe_secret
29.790s
5.551ms
1
1
100.00 %

V2
stress_all
hmac_stress_all
4.842m
177.622ms
1
1
100.00 %

V2
alert_test
hmac_alert_test
0.490s
62.276us
1
1
100.00 %

V2
intr_test
hmac_intr_test
0.460s
18.062us
1
1
100.00 %

V2
tl_d_oob_addr_access
hmac_tl_errors
1.550s
156.352us
1
1
100.00 %

V2
tl_d_illegal_access
hmac_tl_errors
1.550s
156.352us
1
1
100.00 %

V2
tl_d_outstanding_access
hmac_csr_hw_reset
0.820s
54.645us
1
1
100.00 %

hmac_csr_rw
0.580s
43.645us
1
1
100.00 %

hmac_csr_aliasing
2.160s
194.900us
1
1
100.00 %

hmac_same_csr_outstanding
0.570s
20.503us
1
1
100.00 %

V2
tl_d_partial_access
hmac_csr_hw_reset
0.820s
54.645us
1
1
100.00 %

hmac_csr_rw
0.580s
43.645us
1
1
100.00 %

hmac_csr_aliasing
2.160s
194.900us
1
1
100.00 %

hmac_same_csr_outstanding
0.570s
20.503us
1
1
100.00 %

V2

TOTAL

13
13
100.00 %

V2S
tl_intg_err
hmac_sec_cm
0.930s
492.023us
1
1
100.00 %

hmac_tl_intg_err
2.720s
2.355ms
1
1
100.00 %

V2S
sec_cm_bus_integrity
hmac_tl_intg_err
2.720s
2.355ms
1
1
100.00 %

V2S

TOTAL

2
2
100.00 %

V3
write_config_and_secret_key_during_msg_wr
hmac_smoke
1.720s
87.190us
1
1
100.00 %

V3
stress_all_with_rand_reset
hmac_stress_all_with_rand_reset
2.877m
6.172ms
0
1
0.00 %

V3

TOTAL

0
1
0.00 %

TOTAL

21
22
95.45 %

Failure Buckets

UVM_ERROR (cip_base_vseq.sv:829) [hmac_common_vseq] Check failed (!has_outstanding_access()) Waited * cycles to issue a reset with no outstanding accesses. has 1 failures:

Test hmac_stress_all_with_rand_reset has 1 failures.

0.hmac_stress_all_with_rand_reset.39851062471293608766591213677005909603120307009860815160710888739059610400525
Line 57885, in log /home/dev/src/scratch/hmac_dv_upd/hmac-sim-vcs/0.hmac_stress_all_with_rand_reset/latest/run.log
  UVM_ERROR @<PHONE_NUMBER> ps: (cip_base_vseq.sv:829) [uvm_test_top.env.virtual_sequencer.hmac_common_vseq] Check failed (!has_outstanding_access()) Waited 10000 cycles to issue a reset with no outstanding accesses.
  UVM_INFO @<PHONE_NUMBER> ps: (uvm_report_catcher.svh:705) [UVM/REPORT/CATCHER]
  --- UVM Report catcher Summary ---

The failures in the FPGA tests are unrelated to these DV-only changes and the results from HMAC's -i all_once regression look good; merging.


Add the Ability to Specify Egui Texture Filters

Very quick draft, but it works for the egui_glow backend.
Not sure that it's a good API or not, and it needs more thought, but pushing this up because I needed it in my project, and other people might want to look at it.

Make another push, hopefully that fixes CI, sorry for the re-runs.

thanks!


deploy: use secured kubernetes service

Can one of the admins verify this patch?

ok to test

I have restarted the integration tests. Not sure why it failed. @simon3z this PR needs a rebase. Thank you!

@simon3z: This PR does not seem to work with kube version v0.14.1. When was the secure service added to Kube?
P.S.: You can run the integration test manually by following this guide

@vishh idea idea why it fails?

@simon3z: I haven't tried running it manually yet. From the logs, it looks like heapster is not able to fetch any data, which happens when there are issues reaching out to the apiserver.

AFAIK the default read only api service in vanilla kube doesn't use https by default (although it is in other impls like openshift). I suggest making the scheme configurable via an env var, defaulting to http.

This might become unnecessary once heapster starts using secrets to talk to the apiserver securely. FYI!

One option I thought of is we could sniff whether kubernetes-ro service is https or not by just trying to connect on https, falling back to http if it fails. I've used this on other projects successfully before.

@jimmidyson :+1:

#279 should have achieved the same goal. Kindly re-open if #279 doesn't satisfy your use case @simon3z


[project-structure] remove src/content and mention images

Description (required)
This PR updates project-structure.mdx because it still had some outdated information re: content collections.
Additionally, it more clearly mentions putting images in the src/ file, since the wording had not changed from when most images were kept in public/

Lunaria Status Overview
🌕 This pull request will trigger status changes.

Learn more
By default, every PR changing files present in the Lunaria configuration's files property will be considered and trigger status changes accordingly.
You can change this by adding one of the keywords present in the ignoreKeywords property in your Lunaria configuration file in the PR's title (ignoring all files) or by including a tracker directive in the merged commit's description.

Tracked Files

File
Note

en/basics/project-structure.mdx
Source changed, localizations will be marked as outdated.

Warnings reference

Icon
Description

🔄
The source for this localization has been updated since the creation of this pull request, make sure all changes in the source have been applied.


[10.x] Add "dot" method to Illuminate\Support\Collection class

This PR adds the dot method to the Illuminate\Support\Collection class in Laravel.
Additionally, I recently had a need to perform the dot operation on an array, extract 5 items from the flattened result, and then convert it back to a multi-dimensional array using the undot method. Unfortunately, achieving this with the current implementation required me to write the following code:
Arr::undot(array_slice(Arr::dot($keys), 0, 5))

With this PR, users can now easily achieve the same result using the following code:
collect($keys)->dot()->take(5)->undot()

This simplifies the code and makes it more readable, providing a better developer experience for users of Laravel's Illuminate\Support\Collection class.

Me thinking dot would do a dot product.


[BUG] "Load calibration" followed by "Capture Background" gives error

"Load calibration" followed by "Capture Background" yields:
Error: unsupported operand type(s) for *: 'NoneType' and 'float'

It seems like the lca{a/b}_{0,60,120} attributes of QLIPP_Calibration are not being set correctly during "Load calibration".
Ziwen, would you mind helping out with this? I think you should be able to recreate this issue locally.

Found these lines in load_calibration:
https://github.com/mehta-lab/recOrder/blob/00cf5ad0d733aad44067a8e65639f67abb446cd5/recOrder/plugin/workers/calibration_workers.py#L370-L372
It seems to me that the return line does not do anything here?

I think the return is used, but in a sneaky way by self.worker.returned here:
https://github.com/mehta-lab/recOrder/blob/main/recOrder/plugin/widget/main_widget.py#L2460
It seems like the calibration must be returned somehow, or else the LCs wouldn't receive any of the data from the thread.
This page was pretty helpful for me to understand how this section works:
https://napari.org/stable/guides/threading.html
"The @thread_worker decorator converts your function into one that returns a WorkerBase instance."


[Admin] Fix broken links

@Rick-Kirkham The link being used for extended-manifest.schema.json (https://developer.microsoft.com/en-us/json-schemas/office-js/extended-manifest.schema.json) is invalid. Can you provide the current link? Thanks.

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

File
Status
Preview URL
Details

docs/design/keyboard-shortcuts.md
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching in the Docs contributor and Admin GuideSee the frequently asked questionsPost your question in the Docs support channel

nice

Docs Build status updates of commit 178b51f:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

docs/design/keyboard-shortcuts.md
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching in the Docs contributor and Admin GuideSee the frequently asked questionsPost your question in the Docs support channel

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

File
Status
Preview URL
Details

docs/design/keyboard-shortcuts.md
:white_check_mark:Succeeded
View

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching in the Docs contributor and Admin GuideSee the frequently asked questionsPost your question in the Docs support channel


PHP Warning:  array_merge()

I'm seeing this error message sporadically in my debug.log:
PHP Warning:  array_merge(): Argument #2 is not an array in /var/www/wordpress/plugins/wp-stateless/lib/Google/src/Google/Client.php on line 133

@ahmed-sigmalux This line is only called when you save the settings. I am not sure how the warning is happening.
Can you install this version:
https://github.com/wpCloud/wp-stateless/tree/ahmed-sigmalux
Or you can apply the changes manually from this commit
This line of code will add extra debug info to debug log file, that will help to identify the issue.
Then try to save the settings that should generate the warning and backtrace to log file.

The error shows up sporadically when I run cron via wp-cli.

@alimuzzaman were you able to replicate this issue via wp-cli somehow?

@antonkorotkov No I wasn't able to replicate.

I'm not seeing this error anymore.


Add unit tests for u2flib_host.utils

Thanks! Can you state that you contribute this code under the license of the project? Please note that the project has recently changed license from GPL to BSD 2-clause, you will need to state that you contribute under the BSD license for us to merge this.

I state that this code is my own work, and that I am contributing it under the BSD 2-clause licence

Thank you!

Oh, you switched from nose to unittest. I'll submit a new PR.

Ah, whoops. Sorry about that!


Detect client disconnects more reliably.

See the comment. @naved001 reported that impitool processes were
persisting after disconnects; this is only a guess as to the problem, it
needs testing.
Naved, can you try this out and let me know if it fixes the problem?

Thanks for the quick fix!


Add per-directory custom apps

Feature request
Is your feature request related to a problem? Please describe.
There are directories in "pages" whose contents should all have the same layout. For example, an "articles" directory might have articles written in .mdx, which compile to react elements. It would be very useful for all the .mdx files under "articles" to have the same layout and shared logic.
Describe the solution you'd like
Ideally, one could create an _app.js file for each directory. All files in that directory would use that _app.js. Files in other directories with no custom app would use pages/_app.js if that file exists.
Describe alternatives you've considered
All the alternatives I've thought of seem to have the same problem, that the routing information needs to be written in code somewhere, in addition to next inferring that from the filesystem, which is redundant. For example, you could just have a single pages/_app.js and some logic in there to figure out which layouts to add to what. This makes it required to write out your routes in the _app.js file. It's basically a router inside a router, so it's not the best solution.
Another alternative is to keep the .mdx files (or react components) somewhere outside of "pages", and import them in pages/articles.jsx for example. Then, essentially implement a router that shows the proper component depending on the route. Again, you're basically implementing a router within a router.
Additional context
I'm new to next, so if there's something obvious I'm missing, I apologize.

Would also be super useful to retain context and other states across pages in the same folder! (thanks for pointing the duplicate @rafaelalmeidatk )

Closing as duplicate of #8193

This issue has been automatically locked due to no recent activity. If you are running into a similar issue, please create a new issue with the steps to reproduce. Thank you.


Result of Previous Tests should not default to 'positive'

Test type and test result should default to "Select an Option" rather than defaulting to a valid option. That way a user either is not selecting an option, or is clearly selecting an option, but not accidentally selecting an incorrect option.

@katiealoisi @hmyers-cms FYI

I already covered this in this ticket: https://github.com/CDCgov/prime-central/issues/176

Done and merged. Also fixed some of the style issues and a few other bugs while I was in that part of the codebase.

Closing since it's done.


Deploy website

We should make sure the new dashboard is up and running somewhere.

@SleeplessByte Do you have the magics need for this? I can set anything up that you need on s3.


Error while displaying $20.00 (Dollar Sign) as text  in Text()

Here for explaining this issue.
I'm just wrapping my Text in Child
child:Text("$20.00")
Showing me error "Expected an Identifier" (Missing Identifier).

$ is used for string interpolation, you need to escape it like \$20.00

That worked.
Thanks


Method name is wrong which is leading towards confusion : What is onSavedInstanceState() and onRestoreInstanceState() in activity?

It should be onSaveInstanceState() not onSavedInstanceState()

Corrected


Websocket connection

I can't seem to connect to the websocket, even following the code in the gui. Is there a reason for this?
I'm connecting to <ip>:<port>/?auth=password, that succeeds. But If I connect to /sys or /proc I get "invalid namespace". Whats with that?

just try <ip>:<port>/[namespace]?auth=password.


remove run_until_complete and tell people to use run_forever instead.

Long story short
I am a user of Discord.py However because of run_until_complete any websocket closurs closes the loop making me unable to reopen/recreate it.
Expected behaviour
the removal of run_until_complete and to make sure everyone that uses it to use run_forever instead.
Actual behaviour
Websocket closures makes run_until_complete finish and make things more complicated. However replacing that with run_forever fixes this issue. (on my copy of aiohttp)
Not to mention what is the point of run_until_complete when run_forever does it better?
Steps to reproduce
TBD All I currently do is try to recurse from my code when a major disconnection occurs that closes the event loop to try to reopen it. (which does not work because of run_until_complete)
Here is a the code I use when such things happen.
Note: The code is all over the place due to run_until_complete being a pain in the arse.
def login_info_code(self, client):
    global reconnects
    if os.path.isfile(PATH) and os.access(PATH, os.R_OK):
        credsfile = io.open(PATH, 'r')
        credentials = json.load(credsfile)
        discord_user_email = str(credentials['email'][0])
        if discord_user_email == 'None':
            discord_user_email = None
        discord_user_password = str(credentials['password'][0])
        if discord_user_password == 'None':
            discord_user_password = None
        bot_token = str(credentials['token'][0])
        is_bot_logged_in = False
        if bot_token == 'None':
            bot_token = None
        try:
            if discord_user_email and discord_user_password is not None:
                client.run(discord_user_email, discord_user_password)
            elif bot_token is not None:
                # This is for logging into the bot with a token.
                client.run(bot_token)
            is_bot_logged_in = True
        except discord.errors.GatewayNotFound:
            print(str(consoletext['Login_Gateway_No_Find'][0]))
            return
        except discord.errors.LoginFailure:
            print(str(consoletext['Login_Failure'][0]))
            sys.exit(2)
        except discord.errors.InvalidToken:
            print(str(consoletext['Invalid_Token'][0]))
            sys.exit(2)
        except discord.errors.UnknownConnectionError:
            print(str(consoletext['Unknown_Connection_Error'][0]))
            sys.exit(2)
        except TypeError:
            return
        except KeyboardInterrupt:
            return
        except asyncio.futures.InvalidStateError:
            reconnects = reconnects + 1
            if reconnects != 0:
                print('Bot is currently reconnecting for {0} times.'.format(str(reconnects)))
                # sleeptime = reconnects * 5
                # asyncio.sleep(sleeptime)
                self.login_info_code(client)
        except aiohttp.errors.ClientOSError:
            reconnects = reconnects + 1
            if reconnects != 0:
                print('Bot is currently reconnecting for {0} times.'.format(str(reconnects)))
                # sleeptime = reconnects * 5
                # asyncio.sleep(sleeptime)
                self.login_info_code(client)
        if is_bot_logged_in:
            if not client.is_logged_in:
                pass
            else:
                reconnects = reconnects + 1
                if reconnects != 0:
                    print('Bot is currently reconnecting for {0} times.'.format(str(reconnects)))
                    # sleeptime = reconnects * 5
                    # asyncio.sleep(sleeptime)
                    self.login_info_code(client)
    else:
        print(str(consoletext['Credentials_Not_Found'][0]))
        sys.exit(2)

Your environment
Windows 7 Ultimate x64 SP1 (Build 7601)

I honestly have no idea what are you asking about.
Your snippet has neither await/yield from nor run_until_complete() usage.

that is because client.py in Discord.py uses it. https://github.com/Rapptz/discord.py/pull/292/files

Very strange code.
Anyway aiohttp has nothing to do with it.


[ITEM] - Feather

Item name:
Feather
Current method of obtaining:
Killing chickens and parrots
Link to wiki:
https://minecraft.gamepedia.com/Feather

Arrows: recipe to use paper instead?
Book and quill: maybe use a stick instead?
Firework star: used to make the "burst" option - find something else for this (wheat seeds?)

Unable to edit firework recipe. Have implemented the other two recipes, feather now crafted from paper, stick, string for use with the firework recipe if desired.


solution for preventing vectory memory exhaused

Project Robyn
After upgrading to  Robyn v 3.8.1 I was experiencing vector memory exhausted error in which I could not export files from OutputCollect on my MacOS using 8k iterations and 4 trials.
Fixes # (issue)
In order to solve this, I increased the physical and virtual memory allocated through R_MAX_VSIZE=100Gb
Type of change
I added 4 lines of commented out code to increase memory
How Has This Been Tested?
I am successfully running models that were previously causing the error

Thanks for sharing @jbender5. I'm currently working on reducing the outputs size which will avoid these kinds of issues on memory crashes. A couple of questions:

What's the difference on your approach vs setting Sys.setenv('R_MAX_VSIZE'=32000000000) manually without further dependencies (usethis package)? We can set these envionment settings with Sys.setenv() and then check with  Sys.getenv("R_MAX_SIZE") afterwards.
Is it truly only for macOS users? What happens with other OS?

No problem. Reducing the outputs size is the best solution. Regarding your questions:

Setting 'R_MAX_VSIZE' through Sys.setenv should have the same effect as updating the .Renviron directly because they are both updating the environmental variable; however, I still receive the vector memory exhausted error using the former method. Rather than adding a dependency on the 'usethis' package, you can use the command line directly to update .Renviron as outlined here
Unfortunately, I only have have macOS for personal and professional use. I can't test on other OS

Hey @jbender5 I've just deployed 3.8.2 with a new way/order of calculating decomp vectors (which was the new super heavy list that was crashing some users' computation power) and I think this won't be needed for now. Thanks for providing a viable solution that worked for you though. I'll close this PR for now.


Rust Build Not Working on Windows

Building a rust project on windows still tries to use sh. This also breaks custom build configurations since the built in one seems to override the custom options.

Thanks for the report! It really should not use sh on windows!
However, custom options (e.g. a .atom-build.json file in the tree root) should be prioritized over any built-in tool. Could you detail your file structure?

I have the following .atom-build.json:
{
    "cmd": "cargo",
    "args": ["build"],
    "sh": false
}

When I try to build I get the following error and stack trace:
TypeError: Cannot read property 'sh' of undefined
  at ChildProcess.<anonymous> (C:\Users\excaliburhissheath\.atom\packages\build\lib\build.js:245:38)
  at ChildProcess.emit (events.js:116:17)
  at Process.ChildProcess._handle.onexit (child_process.js:1070:12)
  at child_process.js:1142:20
  at process._tickCallback (node.js:364:11)

I think that is a duplicate of #45 . I'll publish a new version soon with it (and this) fixed.

Cool, sorry for the duplicate.


Initial Endpoints

Finish simple read/write endpoints:

[ ] Create user (can be naive, just generate user when pinged)

[ ] Update user (can be naive, no need for authorization atm)

[ ] Delete user

[ ] Create order (should take user in account, automatically generating order items)

[ ] Update order (ie, is_paid)

[ ] Delete order

[ ] Create MenuItem (can be naive, doesn't require authorization)

[ ] Update MenuItem (name, description, availability, etc)

[ ] Delete MenuItem

Gonna separate these out into separate issues


When running playground-elements/configurator locally playground-preview is unable to resolve files

When I first began using the playground elements the previews would resolve properly but at some point since then (I don't believe changes were made) the files began failing to resolve and the preview is stuck in a pending state for a long time.
This is occurring using the default playground configurator setup and with some custom layout arrangements I was experimenting with.
Have you encountered this before? I'm unsure what is causing it as I believe that those files should be served from the service worker.  Is it possible that there is rate limiting happening on the unpkg?

Hmm, yeah it looks like the service worker is not handling those requests for some reason, since that's the unpkg.com 404 response. Will see if I can reproduce.
If you open it in an incognito window, does it start working again?

The incognito window seems to behave similarly except there is an additional error in console.
  VM5 playground-service-worker-proxy.html:11 Uncaught (in promise) DOMException: Failed to register a ServiceWorker for scope<EMAIL_ADDRESS>with script ('https://unpkg.com/playground-elements@0.9.3/playground-service-worker.js'): The user denied permission to use Service Worker.   (anonymous) @ VM5 playground-service-worker-proxy.html:11   async function (async)   (anonymous) @ VM5 playground-service-worker-proxy.html:11   (anonymous) @ VM5 playground-service-worker-proxy.html:11

I've just released v0.9.4 with https://github.com/PolymerLabs/playground-elements/pull/158 that I'm optimistic will fix this issue. Could you upgrade and confirm?

Fixed for me now! Thanks for getting to this so quickly


Suggested new profile name

Open Issues and Questions

As the profile covers not only document retrieval, shall it be renamed from
"Secure Retrieve" (SeR) to e.g. "User Authorization" (UAZ)?

The name "User Authorization" and when abbreviated as UAZ sounds strange to me.
I suggest to use the name "Access Decision Delegation" (ADD) which matches exactly what the profile defines: A framework for actors grouped with the Verifier to delegate access decisions to a single instance which implements the Authorization Decision Manager actor.


There seems to be no straightforward way to check whether node is element or text

there is a 'type' function on each node which will return the type of the node. The documentation doesn't seem to show this and I will update it.


Usefulness of RequestID in Websocket connections

request_id is generated in Websocket clients for the purpose of de-duplication -- Source: https://github.com/XRPLF/xrpl-py/blob/43636217953ecff424f9e5ba77faa97a2f9231a7/xrpl/asyncio/clients/websocket_base.py#L32
However, these IDs are generated in a pseudo-random fashion. Every incoming request is logged as a unique request, thanks to the pseudo-random nature of the ID. This does not help with the de-duplication effort.
There is a demonstration of this issue at the tip of this branch: https://github.com/ckeshava/xrpl-py/tree/requestID
Please execute poetry run python snippets/duplicate_requests.py to observe the websocket-client's queue. I have included an artificial delay on the server-side, in order to simulate certain delays.
(Without these delays, all the requests are full-filled near instantaneously, hence rendering the ID obsolete)
To ensure that no requests are duplicates, we'd need to maintain a time-based cache where every request is crystallized through a SHA-256 hash of its contents, as its unique identity.

@mvadari  what do you think?

I believe the way that xrpl.js handles this is just by using an incrementing ID value. Maybe that would be a better way of handling this - as long as we're able to do so in an atomic manner even in async code.
Since this is essentially an application of the birthday problem, I ran some calculations on the probability of a collision:

100 open requests: 0.5% chance
500 open requests: 10% chance
1000 open requests: 40% chance

This should provide enough data to make a decision on whether this is an important change.

no, I'm not alluding to the birthday problem.
Since we are appending pseudo-random numbers, it is very unlikely we see a collision at all. Owing to the correctness of the math library, I'm quite sure we'll never see a collision in practice. Identical requests also end up with unique RequestIds, is that not a problem?
In my branch, I'm bombarding the client with identical requests -- and I observe the queue size growing. A cache can be helpful in fulfilling all the extraneous requests (until the data becomes stale)

no, I'm not alluding to the birthday problem.
Since we are appending pseudo-random numbers, it is very unlikely we see a collision at all. Owing to the correctness of the math library, I'm quite sure we'll never see a collision in practice.

The correctness of the math library isn't a concern. https://github.com/XRPLF/xrpl-py/blob/43636217953ecff424f9e5ba77faa97a2f9231a7/xrpl/asyncio/clients/websocket_base.py#L18 shows that the pseudo-random numbers are being generated in a range of 1,000,000 (1 million). I applied the birthday problem math to any two numbers in that range.

Identical requests also end up with unique RequestIds, is that not a problem?
In my branch, I'm bombarding the client with identical requests -- and I observe the queue size growing. A cache can be helpful in fulfilling all the extraneous requests (until the data becomes stale)

They're different requests. It's rippled's job to cache, not the library's. If I'm sending the same request, I want the data from rippled, and caching could result in incorrect info. It changes as often as every 4 seconds (potentially more frequently if the UNL is smaller, or if I'm running a standalone node that closes super fast).

Hmm, okay. Yeah, my concern was related to caching.
yes, caching inside rippled makes more sense than the library. although, I suspect ledger close times is closer to 6-7 seconds, rather than 4.
I'll close this issue now.

yes, caching inside rippled makes more sense than the library. although, I suspect ledger close times is closer to 6-7 seconds, rather than 4.

Ledger close times are proven to be around 4. See the metrics at the top of https://livenet.xrpl.org/ (which use real time, not rippled fake time).

I did in fact see collisions of the randomly generated ID when using the lib for load-testing a private rippled cluster.
I needed a quick fix at the time, and this is it:
_REQ_ID_BITS: Final[int] = 16

async def _inject_request_id(request: Request, open_requests: _REQUESTS_TYPE) -> Request:
    """
    Given a Request with an ID, return the same Request.

    Given a Request without an ID, make a copy with a randomly generated ID.

    Arguments:
        request: The request to inject an ID into.

    Returns:
        The request with an ID injected into it.
    """
    if request.id is not None:
        return request
    request_dict = request.to_dict()
    while True:
        id = f"{request.method}_{getrandbits(_REQ_ID_BITS)}"
        if id not in open_requests:
            request_dict["id"] = id
            break
        await asyncio.sleep(0)  # prevent deadlock in case all possible IDs in use
    return Request.from_dict(request_dict)

Note that the function is now async to prevent deadlock, but that may just be paranoid.

I see, thanks for the code snippet.
Can you tell us a little bit about your load-testing environment? How many requests per second are you sending in? And what is the hardware capacity of the rippled server (compute/storage/network configuration) ?


Q2d wrong modeler inherit

Q2d calls modeler3D instead of of modeler2D
q = Q2d()

q.modeler.primitives.create_box()

Q2d.modeler is inherited from FieldAnalysis3D through QExtractor. This is because QExtractor inherits FieldAnalysis3D first over FieldAnalysis2D.
class QExtractor(FieldAnalysis3D, FieldAnalysis2D, object):

I think I was misled by pycharm. The inheritation


Improved topic & group id rules for programmatic message routing

Need to think on this one first

Things like:
opts.PublishMessage<SomeMessage>().ToMqttTopic(x => $"one/two/{x.Name}/action"

so that you can programmatically define topic names from the message body


Created the logo for both light and dark modes

Have put the logo files in assets folder in src

UItopia logo added


Function as objects

So they work as a parameter in apply.

Problems:

How can we solve definition in different files?
How can we still use ADL?


global_maximum/2

Hi!
I am not sure, but is this correct?
?- [X2, X3, X4]::real(0.01, 0.99), {X1 == (X2 + X3 - X2 * X3) * X4}, global_maximum(X1, MAX).
X2::real(0.5495054587018423, 0.9900000000000001),
X1:: 1.22761...,
MAX:: 1.22761...,
X4::real(0.7295252238616355, 0.9900000000000001),
X3::real(0.5495054587018423, 0.9900000000000001).

I am using clpBNR v0.9.3alpha
Kinds regards, JCR

Depends; what is the question? global_maximum finds the minimum of an expression by performing a bifurcating search on the variables in that expression. So I think the question you want to ask is what is the global maximum of the expression (X2 + X3 - X2 * X3) * X4:
?- [X2, X3, X4]::real(0.01, 0.99),global_maximum((X2 + X3 - X2 * X3) * X4, MAX,4).
X2::real(0.009999999999999998, 0.9900000000000001),
X3::real(0.009999999999999998, 0.9900000000000001),
X4::real(0.4999451934462877, 0.9900000000000001),
MAX:: 0.989... .

Due to the characteristics of this expression, this takes several seconds so I specified a reduced precision (4). Note that this just provides the maximum value of the expression, not the minimizers (values of X2, X3,X4). This takes an additional solver step:
?- [X2, X3, X4]::real(0.01, 0.99),global_maximum((X2 + X3 - X2 * X3) * X4, MAX,4), splitsolve([X2,X3,X4]).
X2:: 0.98390...,
X3:: 0.98999...,
X4:: 0.99000...,
MAX:: 0.98984... .

And this is just one of many approximately equal solutions since the precision is limited.
This expression is also somewhat problematical because the solution is not a local optima internal to the solution "box" (defined by [X2,X3,X4]); the minimum occurs at the edge defined by X2=0.99, X3=0.99, X4=0.99. So local optima constraints which could help precision and convergence cannot be applied.
The issue with your query example is that the global_maximum predicate has no visibility into the expression variables; it only sees X1. While it might be possible to extract those variables from the constraint network somehow, it's just simpler all around if the application deals with it.
The new section in the "User Guide" on "Global Optimization" should help with this. Let me know if it doesn't, or if I haven't addressed your question.

Thanks for helping me understand. I meant to say that i was expecting a maximum around 1. But i realise now that the equation i had has several maxima.
I am finding global_maximum and global_minimum very useful, and when there are unique maxima or minima i usually get the minimizers. For example
[X2, X3]::real(0.1, 0.9), {X1 == X2**X3}, global_maximum(X1, _).
yields
X2:: 0.9000...,
X1:: 0.98951...,
X3:: 0.10000... .

But would you consider this an incorrect use of these predicates? I.e. compared to having the whole equation as the first argument in global_maximum.

Thanks for helping me understand. I meant to say that i was expecting a maximum around 1. But i realise now that the equation i had has several maxima.

Mathematically, there is only one maximum (0.98901) when all the values are 0.99, but global_maximum does a bifurcating search until the precision limit is met. Further sub-divsion when generating the minimizers (using splitsolve) is also precision limited so you wind up with many practically identical answers within the bounds of the max value of the expression (same issue as finding roots of polynomials). If there were several actual maxima, splitsolve will separate them but may still generate many solutions for each actual maxima due to the limitations of the search predicates. (Sorry if this is too much information.)
The main thing is to recognize the built-in limits based on precision. If the fixed point iteration was left to run until all 15 digits (or so) were correct, most everything would just take too long.

But would you consider this an incorrect use of these predicates?

As your first example demonstrates, there are many cases where not using the expression (which provides global_maximum visibility into the expression variables) will not generate the results you would expect. But you can do something like:
?- [X2, X3]::real(0.1, 0.9), X1 = X2**X3, global_maximum(X1, X1_max).
X1 = X2**X3,
X2:: 0.9000...,
X3:: 0.10000...,
X1_max:: 0.98951... .

where X1 is the symbolic expression and X1_max is the maximum value of the evaluation of X1 given the interval values of X2 and X3.
In an ideal world, these two usage patterns should be the same, but I don't yet know how to get there.
Also, there may be examples where the variables narrow sufficiently to be deemed minimizers in the process of finding the global maximum, but that's not guaranteed even if they are unique (general "dependency" issue of interval arithmetic). In this example where each variable is used exactly once, everything works in your favour.

Thanks again for explaining. The reason I am looking at the possibility to just use a variable as an argument to global_maximum/minimum is that, conceptually, my programs look like the one below and that i am using meta interpreters (in the example i am using integers to simplify the output). My (maybe subjective) perception is that in all cases in which there is a clear cut maximum or minimum I have been able to get it by just using a variable (instead of having the whole equation as an argument to global_maximum). Sorry if this is a bit abstract, but as soon as our paper gets accepted for publication (or rejected, hehe) I will be able to tell you more (if you are interested). Generally i am finding clpBNR extremely useful.
:- use_module(library(clpbnr)).

x1(X1):- [X1]::integer(2, 10).
x2(X2):- [X2]::integer(2, 10).
x3(X3):- [X3]::integer(2, 10).
x4(X4):- x1(X1), x2(X2), {X4 == X1 + X2}.
x5(X5):- x3(X3), x4(X4), {X5 == X3 - X4}.

prove(true, true):- !.
prove((G1, G2), (P1, P2)):- !, prove(G1, P1), prove(G2, P2).
prove(G, P):- predicate_property(G, imported_from(_)), !, call(G), P = subproof(G, true).
prove(G, subproof(G, Sub)):- clause(G, B), prove(B, Sub).

test:- prove(x5(X5), Proof), global_maximum(X5, _), writeln(Proof).

I don't know enough to comment on whether all your use cases will work using this pattern. In particular, I suspect there will be issues if the underlying expressions are non-linear and contain multiple occurrences of one or more variables (directly or indirectly).
In this example the equations are linear, single use (X5==X3-(X1+X2)) so it's safe. But be wary that if you encounter unexpected results, this may well be an issue as your initial example demonstrated.
I'm always looking for applications of this technology, so when the dust settles I'd be very interested in reading your paper (or a draft).

OK I understand. Could you recommend a strategy that I could use to systematically test if using just a variable in global_maximum/minimum works as expected (in cases where there is a clear cut max or min)? In the paper I mentioned I used clpr and just iterated through all the solutions (then using max_list/2 to find the max). This works but is a bit crude, so it would be nice to have something more powerful. In my application i need at most a precision of 4 decimals.

Without thinking about it much, a possible test is to expand the variable back an expression of interval values, so using your last example, expand X5 to an expression in X2,X3,X4:
 X5 --> X3-X4 --> X3-(X1+X2)

If the expanded expression contains only single instances of any of the variables, I think it will work as you expect. Note that your original example (X1 --> (X2 + X3 - X2 * X3) * X4) does not have this property, i.e., multiple instances of X2 and X3 that cannot both be factored out.
I don't really understand what you're trying to model or what kind of answers you expect to be produced, but let me turn the question around. Why not allow expressions to be defined in your x? rules, as in:
x1(X1):- X1::integer(2, 10).
x2(X2):- X2::integer(2, 10).
x3(X3):- X3::integer(2, 10).
x4(X4):- x1(X1), x2(X2), X4 = X1 + X2.
x5(X5):- x3(X3), x4(X4), X5 = X3 - X4.

and:
test:- prove(x5(X5), Proof), global_maximum(X5, X5_max), writeln(Proof).

While X5 is an expression, X5_max should be the same as the X5 you're currently producing. (Any other expressions can be converted to intervals by {X == Exp}.)
And global_maximum should work as per design intent independent of the nature of the underlying expressions.

Thats really interesting, and a new insight for me! I think it's fascinating that Prolog is so good at symbolic manipulation.
I experimented with having expressions in my rules and handing an expression to global_maximum/2 as you suggested. I am getting the expected solutions but I can't yet figure out how to get a Proof that contains the results of calculations at each step, instead of the actual expression.
With my old approach:
:- use_module(library(clpBNR)).

x1(X1):- [X1]::integer(2, 10).
x2(X2):- [X2]::integer(2, 10).
x3(X3):- [X3]::integer(2, 10).
x4(X4):- x1(X1), x2(X2), {X4 == X1 + X2}.
x5(X5):- x3(X3), x4(X4), {X5 == X3 - X4}.

prove(true, true):- !.
prove((G1, G2), (P1, P2)):- !, prove(G1, P1), prove(G2, P2).
prove(G, P):- predicate_property(G, imported_from(_)), !, call(G), P = subproof(G, true).
prove(G, subproof(G, Sub)):- clause(G, B), prove(B, Sub).

test:- prove(x5(X5), Proof), global_maximum(X5, _), writeln(Proof).

The resulting proof came out as (I added line breaks and tabs for readability):
subproof(x5(6),(
    subproof(x3(10),
        subproof([10]::integer(2,10),true)),
    subproof(x4(4),(
        subproof(x1(2),
            subproof([2]::integer(2,10),true)),
        subproof(x2(2),
            subproof([2]::integer(2,10),true)),
        subproof({4==2+2},true))),
    subproof({6==10-4},true)))

With your suggested approach:
:- use_module(library(clpBNR)).

x1(X1):- [X1]::integer(2, 10).
x2(X2):- [X2]::integer(2, 10).
x3(X3):- [X3]::integer(2, 10).
x4(X4):- x1(X1), x2(X2), X4 = X1 + X2.
x5(X5):- x3(X3), x4(X4), X5 = X3 - X4.

prove(true, true):- !.
prove((G1, G2), (P1, P2)):- !, prove(G1, P1), prove(G2, P2).
prove(G, P):- predicate_property(G, imported_from(_)), !, call(G), P = subproof(G, true).
prove(G, subproof(G, Sub)):- clause(G, B), prove(B, Sub).

test:- prove(x5(X5), Proof), global_maximum(X5, _), writeln(Proof).

I get:
subproof(x5(10-(2+2)),(
    subproof(x3(10),
        subproof([10]::integer(2,10),true)),
    subproof(x4(2+2),(
        subproof(x1(2),
            subproof([2]::integer(2,10),true)),
        subproof(x2(2),
            subproof([2]::integer(2,10),true)),
        subproof(2+2=2+2,true))),
    subproof(10-(2+2)=10-(2+2),true)))

I preferred getting the outcome of a calculation at each step in the proof, e.g. x5(6) instead of x5(10-(2+2)) in the first line of the proofs, but I realise that it might be difficult to implement this (since an expression is passed around in the last example). I spent a number of hours modifying my meta interpreter trying to achieve this but ultimately had no success.
Thanks anyway for taking your time to look at my problem! I really appreciate it.

I see your point. If this expression route is useful, you might consider a "post-processing" step to generate a a more user friendly form, e.g.,
x1(X1):- [X1]::integer(2, 10).
x2(X2):- [X2]::integer(2, 10).
x3(X3):- [X3]::integer(2, 10).
x4(X4):- x1(X1), x2(X2), X4 = X1 + X2.
x5(X5):- x3(X3), x4(X4), X5 = X3 - X4.

prove(true, true):- !.
prove((G1, G2), (P1, P2)):- !, prove(G1, P1), prove(G2, P2).
prove(G, P):- predicate_property(G, imported_from(_)), !, call(G), P = subproof(G, true).
prove(G, subproof(G, Sub)):- clause(G, B), prove(B, Sub).

test:- prove(x5(X5), Proof), global_maximum(X5, _), reduce_proof(Proof,RProof), writeln(RProof).

reduce_proof(true, true) :- !.
reduce_proof(subproof(G,P), subproof(RG,RP)) :-
	G=..[I,Exp], !,
	catch(RExp is Exp,_,RExp=Exp),  % if evaluation traps, no change
	RG=..[I,RExp],
	reduce_proof(P,RP).
reduce_proof(subproof(G,P), subproof(G,P)).
reduce_proof((P1,P2), (RP1,RP2)) :- !,
	reduce_proof(P1,RP1),
	reduce_proof(P2,RP2).

which outputs (suitably hand formatted):
subproof(x5(6),(
	subproof(x3(10),subproof([10]::integer(2,10),true)),
	subproof(x4(4),(
		subproof(x1(2),subproof([2]::integer(2,10),true)),
		subproof(x2(2),subproof([2]::integer(2,10),true)),
		subproof(2+2=2+2,true))
		),
	subproof(10-(2+2)=10-(2+2),true)
	)
)

Additional reduce_proof clauses could be added to handle other cases, but I don't know whether this is general enough to handle all your use cases.

Thank you! I major obstacle for me was how to distinguish between compounds that are non numeric and the ones that are; your catch/3 does the trick. I'll try to integrate your code in what i am building.

One last caveat: This is all good if the intervals narrow to point values (integers or rationals), but is will fail with intervals that don't narrow to a point (due to floating point imprecision). If that's a use case you want to support, than you probably have to add additional clauses to reduce_proof.
Aside: I find turning exceptions into failures using catch a very useful technique. Prolog (unfortunately IMO) generates many exceptions where a logical failure would be more useful. catch is relatively expensive but the alternative is extensive pre-filtering on arguments which is a pain.

Thanks for the tips!


OnStop must update Application Health Probe state to avoid service unavailability

As a subtle but critical implication of https://docs.microsoft.com/en-us/azure/load-balancer/load-balancer-custom-probe-overview#design

you should probe a port on a backend endpoint that reflects the health of that instance and the application service you are providing

The on-stop handler must update the application custom health probe implementation to immediately return 503 Service Unavailable. Without application custom health probe the default guest agent probe would have done that, but its behavior is overwritten by the application custom health probe.
https://docs.microsoft.com/en-us/azure/load-balancer/load-balancer-custom-probe-overview#guestagent

A guest agent probe is a check of the guest agent inside the VM. It then listens and responds with an HTTP 200 OK response only when the instance is in the Ready state. (Other states are Busy, Recycling, or Stopping.)

Not knowing that has caused our very large service to have unavailability bursts of 2 minutes unbeknownst to us for years, every time we deployed, scaled-in, restarted, re-build, re-imaged.

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

ID: c2089595-7b6e-25db-d558-66eb5e838cc7
Version Independent ID: e2e3a9a0-8b3d-c6d6-e2bb-04245c104e02
Content: Handle Cloud Service lifecycle events
Content Source: articles/cloud-services/cloud-services-role-lifecycle-dotnet.md
Service: cloud-services
GitHub Login: @tgore03
Microsoft Alias: tagore

@daviburg  Thanks for the question! We are investigating and will update you shortly.

@daviburg Apologies in delayed response.
I checked with internal team on this and below is the information I got:
As stated in the document, guest agent probes are not effective and should be viewed as a last resort configuration. The recommendation is to use a tcp or http custom probe that would reflect the true health of the application running on an instance. If a custom probe is configured, it will override the guest agent probe.
On point 2: It is behavior of the guest agent. It reports a ready state sometime after the guest OS is booted up and running. So any probe gated on it will not work during start-up, reboots, re-images etc.

@daviburg
Hope the provided information is helpful.
We will now close this issue. If there are further questions regarding this, please tag me in a comment. I will reopen it and we will continue the discussion.


Question on using SMPyBandits on Neuroscience Data

Hi all,
Thanks a lot for this great package !!! I am a neuroscience PhD student, trying to implement multiple bandit algorithms to explain behavioral data collected from animals and humans.
Unfortunately there are not that many open source resources in the neuroscience community in this space (not that I know of, at least). I was wondering if it would be possible to use SMPyBandits to do things like :

Fitting different bandit algorithms to behavioral data. This data will be in the form of dictionary or structure, e.g.:
data['choices'] = [0,1,1,0,...] %indicating the chosen arm on each trial of the bandit task
data['rewards'] = [...] % indiating the obtained reward on each trial of the bandit task

2) Model/parameter recovery for these fits

3) Model comparisons on these fits - information criteria like AIC, BIC, and more, or likelihood ratio tests - possibly integrating SMpyBandits with other python libraries tailored for model fits

4) Plotting the results of models

These, together with an integration of some basic behavioral measures ( calculating performance, switching, etc.) could incredibly help neuroscience community. I have been implementing some of these myself, in Matlab... I just came across your python library.
Happy to chat more !
Thanks a lot,
Fatih

Hello @fspinar Fatih,
Thanks for your nice words, it's really sweet.
However, I'm deeply sorry, as my reply will be disappointing: as I'm no longer an active researcher (I'm a full-time teacher now), I don't have any free time to allocate to work again on SMPyBandits or other research software.
Feel free to take inspiration from what I implemented in Python for SMPyBandits, but I won't be able to help more, sorry.
Most likely I will also not accept any pull request with significant changes, as this project was part of my PhD and is kinda "frozen" as it is.
Regards from France,
@Naereen Lilian Besson

Hello @Naereen
Sorry, I forgot to respond... Thanks a lot for your kind message. I am sorry to hear that you are not working on it anymore...  😞
But I will be looking at your implementations and hopefully making my own implementations for neuroscience purposes.
Thanks again for creating SMPyBandits, and for your response,
Fatih.


gherkin: Rules can not be tagged

Feature: A feature with a single rule

  @RuleTag
  Rule: A rule

    Example: An example of this rule
      Given a single scenario
      When it is executed
      Then nothing else happens

Results in:
Caused by: io.cucumber.core.gherkin.FeatureParserException: Failed to parse resource at: classpath:io/cucumber/junit/platform/engine/rule.feature
(4:3): expected: #TagLine, #ScenarioLine, #Comment, #Empty, got 'Rule: A rule'

Because rules are a container for scenarios it would make sense to be able to tag a rules and that way tag a collection of scenarios.

See also: https://github.com/cucumber/cucumber/issues/1123

Is the recursive link in  the previous comment intentional, @mpkorstanje ?

He probably meant #1092

This will be fixed by #1356

When will this be released? We need to have tags also for rules. Thanks!

Hi @testgitdl this is done and released in a much older version of gherkin. Gherkin v18. There also was some big bug fixes to ruby in a later version: https://github.com/cucumber/common/blob/main/gherkin/CHANGELOG.md#fixed-5
See here: https://github.com/cucumber/common/blob/main/gherkin/CHANGELOG.md#1800---2021-03-24