Dio (HttpClient) cannot set a self-signed trust certificate

Package
dio
Version
4.0.6
Operating-System
Android, iOS, Windows
Adapter
Default Dio
Output of flutter doctor -v
[√] Flutter (Channel stable, 3.3.10, on Microsoft Windows [版本 10.0.17763.5830], locale zh-CN)
    • Flutter version 3.3.10 on channel stable at X:\FlutterSDK
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision 135454af32 (1 year, 5 months ago), 2022-12-15 07:36:55 -0800
    • Engine revision 3316dd8728
    • Dart version 2.18.6
    • DevTools version 2.15.0
    • Pub download mirror https://pub.flutter-io.cn
    • Flutter download mirror https://storage.flutter-io.cn

[√] Android toolchain - develop for Android devices (Android SDK version 34.0.0)
    • Android SDK at X:\Android\SDK
    • Platform android-33, build-tools 34.0.0
    • Java binary at: X:\Java\jdk-<IP_ADDRESS>\bin\java
    • Java version Java(TM) SE Runtime Environment 18.9 (build <IP_ADDRESS>+1-LTS-1)
    • All Android licenses accepted.

[X] Chrome - develop for the web (Cannot find Chrome executable at .\Google\Chrome\Application\chrome.exe)
    ! Cannot find Chrome. Try setting CHROME_EXECUTABLE to a Chrome executable.

[√] Visual Studio - develop for Windows (Visual Studio Professional 2022 17.6.5)
    • Visual Studio at X:\Microsoft Visual Studio\2022\Professional
    • Visual Studio Professional 2022 version 17.6.33829.357
    • Windows 10 SDK version 10.0.20348.0

[!] Android Studio (version 2023.1)
    • Android Studio at X:\Android Studio
    • Flutter plugin can be installed from:
       https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
       https://plugins.jetbrains.com/plugin/6351-dart
    X Unable to find bundled Java version.
    • Try updating or re-installing Android Studio.

[√] IntelliJ IDEA Ultimate Edition (version 2023.1)
    • IntelliJ at X:\JetBrains\ideaIU-2023.1.6
    • Flutter plugin version 78.2.1
    • Dart plugin version 231.9414.10

[√] Connected device (3 available)
    • AOSP on IA Emulator (mobile) • emulator-5554 • android-x86    • Android 9 (API 28) (emulator)
    • Windows (desktop)            • windows       • windows-x64    • Microsoft Windows [版本 10.0.17763.5830]
    • Edge (web)                   • edge          • web-javascript • Microsoft Edge 109.0.1518.78

[√] HTTP Host Availability
    • All required HTTP hosts are available

! Doctor found issues in 2 categories.

Dart Version
2.18.6
Steps to Reproduce
Code snippet：
  (dio.httpClientAdapter as DefaultHttpClientAdapter).onHttpClientCreate =
      (client) {
    SecurityContext securityContext = SecurityContext(withTrustedRoots: true);
    // securityContext.setTrustedCertificatesBytes(certBytes);
    securityContext.setTrustedCertificates('assets/ca-cert.crt');
    HttpClient httpClient = HttpClient(context: securityContext);
    httpClient.badCertificateCallback =
        (X509Certificate cert, String host, int port) {
      return true;
    };
  };

Expected Result
In addition to the system's own trust root certificate, I want to add my own trust certificate! Certificate verification is not ignored blindly.
Actual Result
Failed to load "...\dio_ca_trust_test.dart":
DioError [DioErrorType.other]: TlsException: Failure trusting builtin roots (OS Error:
    CERT_ALREADY_IN_HASH_TABLE(../../third_party/boringssl/src/crypto/x509/x509_lu.c:357), errno = 184549481)

We no longer provide support to dio: <5.0.0.
Do some search: https://www.mongodb.com/docs/atlas/device-sdks/sdk/flutter/troubleshooting/#connect-to-app-services-using-android-7-or-older

We no longer provide support to .dio: <5.0.0
Do some search: https://www.mongodb.com/docs/atlas/device-sdks/sdk/flutter/troubleshooting/#connect-to-app-services-using-android-7-or-older

dio: ^5.0.0 was also tested and the problem remains! I have doubts that the signature algorithm for the certificate format does not support IP certificates, and the support is not perfect! But there is no documentation

Previously, the IP certificate was deployed on the HTTP server, now replace the certificate with the domain name certificate! Create a new test code in the test directory.
dio.httpClientAdapter = IOHttpClientAdapter(
      createHttpClient: () {
        SecurityContext securityContext =
            SecurityContext(withTrustedRoots: true);
        **securityContext.setTrustedCertificates('assets/ca-cert.crt'); or
        securityContext.useCertificateChainBytes(File('assets/ca-cert.crt').readAsBytesSync());**
        final client = HttpClient(
          context: securityContext,
        );
        client.badCertificateCallback = (cert, host, port) => true;

        return client;
      },
    );

This code will work in a separate test file with setTrustedCertificates and useCertificateChainBytes Settings. But placing the code in the project indicates that the certificate file is not found
I/flutter ( 6689): Error: FileSystemException: Cannot open file, path = 'assets/ca-cert.crt' (OS Error: No such file or directory, errno = 2)

Dio (HttpClient) certificate authentication The support for IP certificate authentication is not perfect.

Using File('assets/ca.crt').readAsBytesSync() or await rootBundle.load("assets/ca.crt") in the Widget neither of these methods work properly FileSystemException: Cannot open file. But it works fine until the main function calls runApp(const App()), I don't know why!

In the main () function configuration HttpOverrides. The method of HttpOverrides.global = _HttpOverrides _HttpOverrides. createHttpClient will be multiple calls even if I just call the HTTP request at a time, Setting the certificate is also invalid, and this method is only suitable for ignoring the certificate globally.

The solution:
Adds a global variable, initialized before runApp(const App()).Use this global variable where http requests are required
Future<void> main() async {
  WidgetsFlutterBinding.ensureInitialized();
  var chainBytes = await rootBundle.load("assets/ca.crt");

  Global.dio.httpClientAdapter = IOHttpClientAdapter(
    createHttpClient: () {
      SecurityContext securityContext = SecurityContext(withTrustedRoots: true);
      securityContext.setTrustedCertificatesBytes(chainBytes.buffer.asUint8List());
      // securityContext.useCertificateChainBytes(chainBytes.buffer.asUint8List());
      final client = HttpClient(
        context: securityContext,
      );
      // client.badCertificateCallback = (cert, host, port) => true;

      return client;
    },
  );

  runApp(const BiliApp());
}

This may not be the best way but it's the one I can think of right now.


Avoid creation of unidirectional channel

In the refresh loop (in backgroundRefresh), there is a make(<-chan time.Time) - while i understand its purpose, it would be nice to avoid creating a unidirectional channel, as this seems to prevent executing the code via yaegi (and thus in a traefik plugin). I am not entirely sure why exactly this is a problem, but probably it is a limitation of yaegi, which panics when trying to execute this statement. Maybe there is a more elegant way than what I am using as a quick fix at the moment (an if-condition before the select to use it with or without a <-time.After case).

Thank you for submitting this issue @tcriess.
Would you please provide steps to reproduce this issue and the copy/paste of the error or panic you experience at the end of these steps?

create a traefik plugin (f.e. based on the example plugin), based on the traefik documentation https://doc.traefik.io/traefik/plugins/
use github.com/MicahParks/keyfunc and github.com/golang-jwt/jwt/v4 in this plugin for verifying a jwt like so

options := keyfunc.Options{
	Ctx: ctx,
	RefreshErrorHandler: func(err error) {
		log.Printf("error: there was an error with the jwt.Keyfunc: %s", err.Error())
	},
	RefreshInterval:   time.Hour,
	RefreshRateLimit:  time.Minute * 5,
	RefreshTimeout:    time.Second * 10,
	RefreshUnknownKID: true,
}

jwks, err := keyfunc.Get(jwksUrl, options)
if err != nil {
	return nil, err
}

start traefik using this plugin. Traefik will panic with

panic: reflect.MakeChan: unidirectional channel type [recovered]
        panic: reflect.MakeChan: unidirectional channel type

goroutine 114 [running]:
github.com/traefik/yaegi/interp.runCfg.func1()
        github.com/traefik/yaegi@v0.15.0/interp/run.go:205 +0x13b
panic({0x3a3ed60, 0x529f910})
        runtime/panic.go:884 +0x212

traefik uses yaegi, a runtime go interpreter for its plugins, which heavily uses reflection - and thus unidirectional channels cannot be created. At least that is my interpretation.
Meanwhile I discovered that the token verification does not work even if a workaround for the unidirectional channel is in place (golang-jwt complains about a wrong key type...). So I'll close this issue as there seems to be more to investigate than just the unidirectional channel - and there is an alternative at https://github.com/team-carepay/traefik-jwt-plugin which I should have looked at earlier :).


run_sql rpc method casts number-like strings to numbers

Describe the bug
If you execute some sql via the run_sql rpc method that will return string values that look like numbers, the values are erroneously cast to numbers.
This seems to happen for anything that looks like a number, e.g.:

'0.55' -> 0.5
'-10' -> -10
'+12024561111' -><PHONE_NUMBER>1
'0.000000000000000001' -> 5e-18

This doesn't happen when you actually run the model. The materialized view shows the string value as expected.
Steps To Reproduce
Execute the following via the run_sql rpc method:
select '+1' as test

You will see the following in the response:
...
"table": {
  "column_names": [
    "test_value"
  ],
  "rows": [
    [
      1
    ]
  ]
}
...

Expected behavior
...
"table": {
  "column_names": [
    "test_value"
  ],
  "rows": [
    [
      "+1"
    ]
  ]
}
...

System information
Which database are you using dbt with?

[x] postgres
[x] redshift
[x] bigquery
[x] snowflake
[ ] other (specify: ____________)

The output of dbt --version:
Have confirmed on 0.15.0 through to 0.20.1.
The operating system you're using:
Linux and macOS.
The output of python --version:
3.6

@tom-james-watson Thanks for the detailed report! We've recently resolved this (https://github.com/dbt-labs/dbt/pull/3499); that fix will be going out in the next minor version of dbt (v0.21.0).
You can try installing v0.21.0b1 yourself to test:
select '+1' as test

{
    "jsonrpc": "2.0",
    "method": "run_sql",
    "id": "2db9a2fe-9a39-41ef-828c-25e04dd6b07d",
    "params": {
        "timeout": 60,
        "sql": "c2VsZWN0ICcrMScgYXMgdGVzdA==",
        "name": "my_first_query"
    }
}

...
"table": {
    "column_names": [
        "test"
    ],
    "rows": [
        [
            "+1"
        ]
    ]
},
...


How to select a high quality video steam and keep 20~30fps in hololens2 in video chat (unity)

I set up a stable call between the PC(NVIDIA GeForce GTX 1060 6GB) and hololens2 using the latest version of MixedReality-WebRTC, and found to my frustration that the video quality I saw on the computer was lower than 1080p.
I need some helpful solutions for getting high quality video frame and at the same time the suitable framerate,  the worst not lower than 20fps, in a video chat.
I have tried to change the capture format to manual and add a general constraints with 2272x1278 resolution and 30 framerate. However, I didn't got the expected result that the video frame quality has improved but the framerate has dropped to 3fps. Then I tried to reduce the resolution to 1080p, but the sad thing happened. HoloLens2 showed a red hint, and I couldn't see it clearly, so I guess it's not supported by the hardware.
In any case, I can't think of a way to achieve the goal mentioned in the title. I need your help.

the video frame quality has improved but the framerate has dropped to 3fps

It is difficult to tell why this would happen; there are many steps alongside the path from the video capture to the final rendering that could get slow. Did you try with a proper Unity build in Release config, instead of via the Editor? And what does the Unity profiler say in the Editor? If you're using node-dss, you could also test with the TestAppUWP sample to see if the same problem occurs.

I guess it's not supported by the hardware.

1080p is definitely supported, see https://docs.microsoft.com/en-us/windows/mixed-reality/develop/platform-capabilities-and-apis/locatable-camera

ok, I will try to run the TestAppUWP sample.

I set transceiver locally:

Then, I set it on the opposite end as before.
At the end, I start negotiation in local. I can't get any frames from the remote side. I‘m trying to start negotiation on the far end at the same time, but the result is the same.
How should I do to solve this problem?

the video frame quality has improved but the framerate has dropped to 3fps

It is difficult to tell why this would happen; there are many steps alongside the path from the video capture to the final rendering that could get slow. Did you try with a proper Unity build in Release config, instead of via the Editor? And what does the Unity profiler say in the Editor? If you're using node-dss, you could also test with the TestAppUWP sample to see if the same problem occurs.

I guess it's not supported by the hardware.

1080p is definitely supported, see https://docs.microsoft.com/en-us/windows/mixed-reality/develop/platform-capabilities-and-apis/locatable-camera

I set transceiver locally:

Then, I set it on the opposite end as before.
At the end, I start negotiation in local. I can't get any frames from the remote side. I‘m trying to start negotiation on the far end at the same time, but the result is the same.
How should I do to solve this problem?

You shouldn't create any transceiver on the callee (answering peer). They will be created automatically when the callee receives the call offer. This is why things don't work. Now the caller creates transceivers and sends an offer, and the callee has already some transceivers so ends up with 4 transceivers (2 offers and 2 created locally). On top of that, that's probably not handled very well in TestAppUWP, although I expect you should see 4 transceivers on the callee once the call is connected. Just delete the transceivers on the callee and try again, that should work.


Benchmarks

Created draft here https://github.com/deep-foundation/materialized-path/tree/main/benchmarks


[#23] Simplify library usage to retrieve data concerning a specified period

Fix issue #23
Client don't have to fill inner variables anymore to retrieve data that is not the last day data.
Class "static" fields have also been added because HOURLY, DAILY (, ...) constants where not usable outside the class.

Would it be ok to merge this PR ?

Would be nice to get this one merged for sure !

deployed on pypi with v0.4.0


Background colors are either bugged or soon to be deprecated?

Describe the bug
When remapping surface tokens, I've noticed that dark mode background is not pointing to the correct color, as it clashes with the new surface-container-low.
To Reproduce
Steps to reproduce the behavior:

Use background.
Have an app bar on your mocks, which uses surface-container-low.
Apply dark mode.
See that they're the same shade, whereas surface seems to work much better for backgrounds.

Expected behavior
background would be much darker, as it's supposed to be below everything else.
Screenshots

Yes, we are encouraging everyone to move to the new tonal surfaces. Background is essentially replaced by surface. https://material.io/blog/tone-based-surface-color-m3 Not a bug :)

The post never mentioned background which is why I was confused. 🙏 But thank you!


[Bug]: Battery doorbell stream does not work

What happened?
Everything besides video stream works on my eufy 1080p battery doorbell, any work in progress to fix that? I’m attaching some images that may help:

Device Type
Doorbell (Supported)
Plugin Version
v1.0.x (Supported)
HomeBridge Version
v1.3.x (Supported)
NodeJS Version
v16 (Supported)
Operating System
Raspbian
Relevant log output
No response

Yes, and suddenly it started working. I’ll close the issue for now and reopen if it stops

After a while not using the camera, it starts not working anymore again

Battery and wired doorbell not streaming on the latest version . Installed the beta version, now both cameras are working fine.

Hello,
I wonder if this can help :
https://github.com/samemory/homebridge-eufy-security/issues/284#issuecomment-981137804
(I don't know how to do it to test)

Duplicate of https://github.com/samemory/homebridge-eufy-security/issues/295


fscrunch not supported for coherent beamformer

Need to include fscrunch in coherent beamformer.

Solved in fbfuse branch and will be integrated to master with PR #3


Request to Update Documentation to Reflect the Retirement of Certain Facial Attributes

Dears,
Kindly update the document section that mentions the retirement of certain face attributes.
Notice of the retirement has been posted but the section still has the retired features in the list of attributes that can be detected.
Thank you!

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

ID: 735bd5b5-ae11-5bbc-6fcb-26aa8b3f022d
Version Independent ID: 3ab0fb5d-faba-2380-967a-13d4ae3afde0
Content: Face detection and attributes - Face - Azure Cognitive Services
Content Source: articles/cognitive-services/Computer-vision/concept-face-detection.md
Service: cognitive-services
Sub-service: face-api
GitHub Login: @PatrickFarley
Microsoft Alias: pafarley

@iamramengirl
Thanks for your feedback! We will investigate and update as appropriate.

@PatrickFarley
Could you please review add comments on this, update as appropriate.

@iamramengirl
Thank you for bringing this to our attention.
I've delegated this to content author @PatrickFarley, who will review it and offer their insightful opinions.

I've asked the PMs to confirm that these attributes were retired

Confirmed; updating the docs now
#please-close


[upstream contributions] Promote Kubeflow Model Management WG

There are some members in Kubeflow community want to establish a new WG Model Management WG. We can be part of the WG and see what we can do there.
https://groups.google.com/forum/#!topic/kubeflow-discuss/8DGqfg75qW0

/priority p3

/assign @gaocegege


updated explanation for why {} + [] differs from [] + {}

It is not a case of concatenation, but rather {} being interpreted as a code block rather than an empty object.

Thanks for contributing!


Unable to use docker-registry-frontend with htpasswd enabled docker registry

Hi,
I am trying to use this application with docker registry with SSL enabled and htpasswd authentication enabled. I am not able to get any configuration details where I can pass the htpasswd credentials. If I disabled htpasswd from my registry setup then its working perfectly fine but not with htpasswd enabled. Any pointers will be helpful!
Thanks,
Guruprasad

I am facing the same issue now, after a reinstall of the frontend. Interestingly enough on my first install it showed the User/PW prompt on the browser and let you log in the the htpasswd credentials set for the docker registry.

Hi, I am also facing same issue while enabled htpassword on the registry and any solution for this ?


Unregistered language system tags in the Tibetan script

The language system tags 'TSJ ', 'XKF ', and 'KJZ ' for Tshangla, Khengkha, and Bumthangkha are not registered at https://docs.microsoft.com/en-us/typography/opentype/spec/languagetags.

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

ID: afaf5060-fd0d-2b4c-7555-e3d81ccafe24
Version Independent ID: 06c7f355-4cd9-4d0c-188b-4d65d4a5b406
Content: Creating and Supporting OpenType Fonts for Tibetan Script - Typography
Content Source: typographydocs/script-development/tibetan.md
Product: windows
GitHub Login: @mijacobs
Microsoft Alias: mijacobs

If they're not registered, what's the basis for calling these "language system tags"?

Was that a question for me? I called them that because they’re in the “Language system tag” column.

Sorry, I missed that you were commenting on the script-development page for Tibetan script. Makes sense now. Thanks. I'll add those to the language system tag registry.

Mixup on Balti: the tag 'BLT ' was registered for that a looong time ago -- 2002 or earlier. So, the Tibetan script page has a bug.

Added KJZ ', 'TSJ ', 'XKF to the lang sys tag registry, to be published with OT 1.8.3.


HDDS-7524. Compaction DAG node pruning

What changes were proposed in this pull request?
To generate faster diff between snapshots, we maintain a compaction DAG in memory. Whenever compaction happens, related SST file nodes get added to the DAG. Over time, DAG will keep on increasing and may cause memory pressure or become a bottleneck. To solve this, we can prune the unnecessary SST file nodes from the DAG since we have a concept of the oldest snapshot with compaction history.
Related doc: https://docs.google.com/document/d/19ZOT-lY2WS8nDj1s9HGVyUY3kgnKIfv-Eck--SokaDU/
This change proposes the traversal and pruning of the DAG.
Idea here is to remove the nodes and arcs which were created before snapshot, to be deleted, was created because they are not needed to  generate the diff anymore.
pruneBackwardDag prunes the backward DAG and removes the nodes and arcs from the upstream of the level at which snapshot was taken.
pruneForwardDag prunes the forward DAG and removes the nodes and arcs from the downstream of the level at which snapshot was taken.
Let's take an example of the following diagram (Backward DAG).

Snapshots were taken at level1, level-3 and level-5
Snapshot-1: 000015.sst, 000013.sst, 000011.sst, 000009.sst
Snapshot-2: 000027.sst, 000030.sst, 000028.sst, 000031.sst, 000029.sst, 000039.sst, 000037.sst, 000035.sst, 000033.sst
Snapshot-3: 000059.sst, 000055.sst, 000056.sst, 000060.sst, 000057.sst, 000058.sst
If Snapshot-1 and Snapshot-2 need to be pruned, we can simply prune upstream of level-3 in backward DAG and downstream of level-3 in Forward DAG. So all the nodes from level-1, level-2 and level-3 and arcs between level-1 & level-2, level-2 & level-3  and outgoing/incoming arcs from/to level-3 will be removed from both forward and backward DAGs.
What is the link to the Apache JIRA

https://issues.apache.org/jira/browse/HDDS-7524

How was this patch tested?

Unit tests.

Thanks @hemantk-12 for the patch. Thanks @GeorgeJahad and @prashantpogde for reviewing this.


Double Head Extension

From paper: https://arxiv.org/pdf/1904.06493.pdf

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.

Hi @tuannguyenanh177！We are grateful for your efforts in helping improve this open-source project during your personal time.
Welcome to join OpenMMLab Special Interest Group (SIG) private channel on Discord, where you can share your experiences, ideas, and build connections with like-minded peers. To join the SIG channel, simply message moderator— OpenMMLab on Discord or briefly share your open-source contributions in the #introductions channel and we will assist you. Look forward to seeing you there! Join us ：https://discord.gg/UjgXkPWNqA
If you have a WeChat account，welcome to join our community on WeChat. You can add our assistant ：openmmlabwx. Please add "mmsig + Github ID" as a remark when adding friends：）
Thank you again for your contribution❤ @tuannguyenanh177


Fix Browserify support

The procedural require()s in lib/messages/builder.js were causing problems for Browserify (message building would fail since the constructors were not detected as dependencies and would not be included in the bundle). This PR changes builder.js to use an explicit require() for each command.
Previously, the builder contained a map of the commands, the values being the names. I changed this so the values are now the required constructors, which each now have a _name property.
The tests were also updated to work with this change.

Coverage remained the same at 100.0% when pulling ecf7db6770f2f583554ed7daa3a1e9065813d3ef on mappum:master into a603858c4bc7dba853112d85df974e0855290119 on bitpay:master.

Interesting! Our trials to make this module work in the browser had failed. Did you manage to connect to a node from the browser? I'll check the code to see how you did this, I'm intrigued.

I'm connecting to nodes in the browser using WebRTC data channels in my project, webcoin (https://github.com/mappum/webcoin). Of course, it's not possible to create real TCP sockets in the browser so browsers can only connect to other nodes that support WebRTC, but Node.js nodes can connect to both and bridge the p2p networks. I'm using the same Bitcoin network protocol in both TCP and WebRTC connections (which is why I need bitcore-p2p).

Nice. Didn't realize bitcore-p2p could be useful without the networking part.
ACK. @braydonf comments?

I rebased this change on 0.14.0. Could you guys take a look and think about merging this PR?

Coverage remained the same at 100.0% when pulling dded8c092add196573aaae460719aca19171b8d4 on mappum:master into 05605b7b7c7f90bf6ee9b6d0ba4e3a71c97e0341 on bitpay:master.

I'm all for it. Waiting for someone else to review. Thanks for your work @mappum!

As previously mentioned, support in a browser with browserify would require many other updates, as the networking portions wouldn't work. I also didn't realize it could be useful without the networking portions.... However we still wouldn't have tests for browser/browserify support.
There are a few other similar related open issues, for reference:

https://github.com/bitpay/bitcore-p2p/issues/49 - Add support for Foxtrot Sockets
https://github.com/bitpay/bitcore-p2p/issues/36 - Support FirefoxOS & ChromeOS TCP Sockets
https://github.com/bitpay/bitcore-p2p/issues/21 - Support Connecting to Peers in a Browser

To clarify, I'm not opening an issue or suggesting to make changes to support browserify. This is a PR that includes all the necessary changes to make bitcore-p2p build in browserify. The connection code does not automatically port to browsers, but that is only a small part of this package (if you look at it, most of the volume of code is for bitcoin protocol serialization/deserialization, not managing connections).
@braydonf Please consider pulling this PR, as it will make Bitcoin network protocol serialization possible in the browser. Thank you :+1:

We don't have a test that reveals and covers the problem that is being fixed here, since we're not running any browser tests yet.

We may have a few paths to do that:

Run browser tests and build a bitcore-p2p browserify bundle without the network portions.
Separate message serialization code into a separate module that is fully Node.js/browser compatible.

The previous may be more simple, especially considering we may be able to make peer/pool more extensible.

Is there a way we can skip certain tests in the browser? All the tests pass in the browser except the Peer/Pool tests (I just added a commit to fix a bug with the message serialization tests).

Coverage remained the same at 100.0% when pulling 0c01a566f314e4a97c8864cde6584cc3757d840a on mappum:master into 05605b7b7c7f90bf6ee9b6d0ba4e3a71c97e0341 on bitpay:master.

@mappum something like this?
bxit.js:
module.exports = typeof window === 'undefined' ? it : xit

peer.js:
var bxit = require('./bxit')
describe(..., function () {
  it('...', function () { ... })
  bxit('...', function () { ... })
})

I made the tests run in the browser, and they pass. :+1: (However, we are skipping the Peer and Pool tests since they are not compatible with the browser).

Coverage remained the same at 100.0% when pulling e733a8e264df4f26bbb9443b344e104b64a714ca on mappum:master into 05605b7b7c7f90bf6ee9b6d0ba4e3a71c97e0341 on bitpay:master.

Karma appears to have a problem in Travis, but it passes successfully on my machine. Any idea how to fix that?

Coverage remained the same at 100.0% when pulling 5d31001b77f70ed8db894ca15a847ebb8caa6e25 on mappum:master into 05605b7b7c7f90bf6ee9b6d0ba4e3a71c97e0341 on bitpay:master.

Now this PR has been open for a month, and I've addressed your concerns by enabling browser tests. Could you please take one last look when you get a chance and pull this if it is to your satisfaction? Thanks :)

LGTM

Adding browser support or partial browser support isn't currently a priority (for maintenance purposes), as every use case we need this module for is with Node.js. And Copay uses BWS (bitcore wallet service): https://github.com/bitpay/bitcore-wallet-service @matiu
Also in context: We've previously separated this module from Bitcore, so that the Bitcore module would be 100% compatible between browser and Node.js, due to problems and confusion between having partial browser support and extra unneeded dependencies in the browserify bundle. The same problems would arise here as well. Separate modules solve this problem much more cleanly.
This PR helps to identify which pieces are working in a browser, that there can be partial browser support, and that in developing web applications there is a use for messages because alternative connections can be made to the Bitcoin network. So in summary:
Features that do work in the browser:

All of the message handling and creation

Features that do not work in a browser:

Connecting to a Peer, because of the TCP socket dependency
Creating a Pool, because of dns dependency for seeding

Something that hasn't been mentioned yet, is to move the features that are working in a browser into the Bitcore module in a similar way that many necessary pieces such as Block, MerkleBlock and Transaction. Would this be satisfactory for your needs? Would need to look into what this would mean for the file-size increase, and if it was an issue, we could add a new module that would have all of the message handling.

Something that hasn't been mentioned yet, is to move the features that are working in a browser into the Bitcore module in a similar way that many necessary pieces such as Block, MerkleBlock and Transaction. Would this be satisfactory for your needs?

Sure, that would work fine.

Would need to look into what this would mean for the file-size increase, and if it was an issue, we could add a new module that would have all of the message handling.

After being Browserified/minified, the network protocol code increases the size of Bitcore from 500kb to slightly under 700kb. I think it would be a good move to put it in its own package (called something like bitcoin-net). The network (de)serialization code can be very useful on its own, for instance in building node status monitors, SPV clients, proxies, and many other applications.

Created an issue for this: https://github.com/bitpay/bitcore/issues/1260

Would this be OK if we don't publish to bower? What about a note on the README?
I really love the idea of a WebRTC-based bitcoin subnetwork, à la webtorrent. This need not be a priority for maintenance

There are several changes that need to be done to enable that, which why implementing a new Peer I think makes sense. We can track with https://github.com/bitpay/bitcore/issues/1260

bitcore-p2p can be browserified withound changing the builder.js, one needs to require the messages explicitly in the browserify comand. An example can be found here: https://github.com/getbitpocket/bitcore-p2p-cordova/blob/master/gulpfile.js


You no longer need to wrap your server integration tests in Jasmine.onTest

from your database-fixtures file
Jasmine.onTest(function() {
  beforeAll(function() {
    resetDatabase();
    loadDefaultFixtures();
  });
});

Is the database-fixtures file from your project?
You can remove the Jasmine.onTest and the message will disappear.
Change the content to:
beforeAll(function() {
  resetDatabase();
  loadDefaultFixtures();
});

Let me know if this file is not under your control. Just give me the link to the location ;-)

this is the file
https://gist.github.com/Sanjo/edbc0c1848de726b78d5


Identity matrix initialization (was Custom Initialization of Weights)

Hey TF,
In your seq2seq library you define your weights W, by setting your initializer to none:
https://github.com/tensorflow/tensorflow/blob/master/tensorflow/python/ops/rnn_cell.py#L675
I'm trying to build Identity RNN's and Unitary RNN's in tensorflow. For identity rnn's they need to be initialized by a identity matrix. Numpy easily makes this
How can this be done using get_variable? Is there way you can custom build your own matrix and then use get_variable and its initializer?
Also, when you set initializer = None in get_variable what is created?  Thanks alot!

This is a better question for stackoverflow, but the answer is easy, so: get_variable takes an initializer argument which you can set to constant_initializer with any numpy array.  You can easily easily build your own initializers if you want to build the initializer with tensorflow ops; look at the source for constant_initializer to see how.

Thanks girving, I apologize for asking this in the wrong place. I will look at the source code for constant_initializer. If I get it working, I'll post here with the solution for identity matrix.

try this:
def identity_initializer():
    def _initializer(shape, dtype=tf.float32):
        if len(shape) == 1:
            return tf.constant_op.constant(0., dtype=dtype, shape=shape)
        elif len(shape) == 2 and shape[0] == shape[1]:
            return tf.constant_op.constant(np.identity(shape[0], dtype))
        elif len(shape) == 4 and shape[2] == shape[3]:
            array = np.zeros(shape, dtype=float)
            cx, cy = shape[0]/2, shape[1]/2
            for i in range(shape[2]):
                array[cx, cy, i, i] = 1
            return tf.constant_op.constant(array, dtype=dtype)
        else:
            raise
    return _initializer

Actually, reopening and saying enhancement, since this is clearly something common enough to want in the code.

@alexatknit: That looks pretty good, though before we check it in we'll probably want to split it into two functions: one op the does the work and one identity_initializer that uses it.

@alexatknit thanks for the help! Works great. I'll be working on an intializer for complex numbers for the unitary RNN's . Again I appreciate both of your help.

drive-by: probably would be easy to do using np.diag()  (or tf.diag(), its equivalent).

I think get_variable can now take a tf.Tensor as an initializer, which is probably sufficient if that tensor is a tf.constant set by a numpy array.  Closing due to inactivity, though we could re-open if this was insufficient.

Since tf.orthogonal_initializer exists, I'd expect tf.identity_initializer to exist as well. Could this be reopened?

You can do this
a = tf.Variable(tf.eye(3))
sess.run(a.initializer)
print(sess.run(a))

@yaroslavvb, thanks!
Matter of taste, I guess, but it's cleaner to keep with the tf.get_variable / tf.variable_initializer API instead of mixing in tf.Variable, especially for variable scoping and sharing variables.
Passing a tf.constant to tf.get_variable, or making a custom initializer just for this, isn't very clean IMO. E.g. I like:
with tf.variable_scope('my_scope', initializer=tf.identity_initializer()):
  x = tf.get_variable(...)
  y = tf.get_variable(...)
  # ...and so on...

OK, that seems like a case that's not covered. Not sure what's the state of initializers are (if they are going to get deprecated at some point), cc  @fchollet for opinion on having identity_initializer

@carlthome So given that glorot_uniform_initializer was just added to core, I think if you wrote identity_initializer that used tf.ones, that would probably get accepted

Neat. :+1:
Sidebar: I see some merit of deprecating tf.get_variable actually. Python already has classes, so much of it is redundant. It's also a bit weird to see neural network specific stuff like Glorot initialization in TensorFlow's top package instead of in tf.nn.

@yaroslavvb I think we do need an Identity initializer. Btw, note that we are currently refactoring initializers to be classes instead of functions that return functions. Let's add the new initializers afterwards.

I would like to work on this issue but it seems that the refactoring is not yet complete. Should I work on a PR or wait?

I think the identity initializer has been added in commit (https://github.com/tensorflow/tensorflow/commit/d5f1790530db0ee430d223497a59cfc26ab5f4d8) recently. Maybe this issue could be closed?

Good idea, fixed by https://github.com/tensorflow/tensorflow/commit/d5f1790530db0ee430d223497a59cfc26ab5f4d8


Numbers on assignment grades summary do not match the graph

From a user:
"How to reproduce: In the instructor view, there's some assignment statistics page somewhere that shows the grade distribution and the number of people who got a grade of zero, among other things.
Expected result: The written data in the sidebar should match the data displayed in the graph.
Actual result: The data in the sidebar is counted over individual students, while the data in the graph represents statistics for individual submissions, so in the sidebar grades for groups of two are double-counted."
The data in both should be represented per group.
Assignments submitted and Assignments graded seem fine, but Number of Fails is incorrect.
(I didn't check the other numbers but they should be double-checked.)

Reason to mark as invalid:

this has been resolved but the issue was not closed (both the histogram and side panel data are calculated per grouping)


Top-level await is not available in the configured target environment ("chrome87", "edge88", "es2020", "firefox78", "safari14" + 2 overrides)

We work on electron forge in production app, we worked to app offline mode but after installed package
"@hookform/resolvers": "^3.9.0",
"@journeyapps/wa-sqlite": "^0.4.0",
"@powersync/kysely-driver": "^0.4.2",
"@powersync/react": "^1.4.5",
"@powersync/tanstack-react-query": "^0.0.1",
"@powersync/web": "^1.8.2",
We git  error Top-level await is not available in package bson that we never installed, so, we don't know where is issue.

able in the configured target environment ("chrome87", "edge88", "es2020", "firefox78", "safari14" + 2 overrides)

Could you try enabling the vite-plugin-toplevel-await plugin as in this example?

Thanks that worked


Fatal Bug: TypeError: str.replace is not a function

Brief Issue Summary
The CMake Tools extension on the VSCode on WSL cannot run at all due to the error TypeError: str.replace is not a function.

Reproduce the bug

Install the VSCode v1.64(x64 Windows) and start a WSL connection to the WSL2 on the same computer.
Install cmake-tools v1.9.2 extension.
There is no any CMake options either in the command palette or in the sidebar.

CMake Tools Diagnostics
The CMake: Log Diagnostics cannot run at all since the extension can't load.

[2022-02-24 20:38:28.707] [exthost] [error] Activating extension ms-vscode.cmake-tools failed due to an error:
[2022-02-24 20:38:28.708] [exthost] [error] TypeError: str.replace is not a function
	at Object.replaceAll (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:62770:16)
	at /home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:53765:32
	at Map.forEach (<anonymous>)
	at expandStringHelper (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:53763:10)
	at Object.expandString (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:53653:33)
	at CMakeTools._init (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:46317:81)
	at Function.create (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:46547:20)
	at Function.createForDirectory (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:46559:27)
	at CMakeToolsFolderController._loadCMakeToolsForWorkspaceFolder (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:55710:38)
	at CMakeToolsFolderController._addFolder (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:55725:36)
	at CMakeToolsFolderController.loadAllCurrent (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:55679:28)
	at ExtensionManager._init (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:54050:33)
	at Function.create (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:54102:20)
	at setup (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:55194:55)
	at activate (/home/lexington/.vscode-server/extensions/ms-vscode.cmake-tools-1.9.2/dist/main.js:55363:12)
	at processTicksAndRejections (internal/process/task_queues.js:93:5)
	at async Promise.all (index 0)
	at async w.$activate (/home/lexington/.vscode-server/bin/f80445acd5a3dadef24aa209168452a3d97cc326/out/vs/workbench/services/extensions/node/extensionHostProcess.js:98:21810)

Debug Log
There isn't debug log since the extension cannot load due to the error trace.
<!-- Paste the debug log contents HERE -->

Installed Extensions and Activated Extensions

ms-vscode.cmake-tools v1.9.2
cheshirekow.cmake-format v0.6.11
josetr.cmake-language-support-vscode v0.0.4

This bug can be resolved by adding toString() in the erroneous functions listed below:
utils.ts/normalizePath
export function normalizePath(p: string, opt: PathNormalizationOptions): string {
    const normCase: NormalizationSetting = opt ? opt.normCase ? opt.normCase : 'never' : 'never';
    const normUnicode: NormalizationSetting = opt ? opt.normUnicode ? opt.normUnicode : 'never' : 'never';
    let norm = path.normalize(p.toString()); // p->p.toString()
    while (path.sep !== path.posix.sep && norm.includes(path.sep)) {
        norm = norm.replace(path.sep, path.posix.sep);
    }
//...
}

utils.ts/replaceAll
export function replaceAll(str: string, needle: string, what: string) {
    const pattern = escapeStringForRegex(needle);
    const re = new RegExp(pattern, 'g');
    return str.toString().replace(re, what); //str.replace()->str.toString().replace()
}

utils.ts/escapeStringForRegex
export function escapeStringForRegex(str: string): string {
    return str.toString().replace(/([.*+?^=!:${}()|\[\]\/\\])/g, '\\$1');  //str.replace()->str.toString().replace()
}

utils.ts/fixPaths
export function fixPaths(str: string | undefined) {
    if (str === undefined) {
        return undefined;
    }
    const fix_paths = /[A-Z]:(\\((?![<>:\"\/\\|\?\*]).)+)*\\?(?!\\)/gi;
    let pathmatch: RegExpMatchArray | null = null;
    let newstr = str;
    while ((pathmatch = fix_paths.exec(str))) {
        const pathfull = pathmatch[0];
        const fixslash = pathfull.replace(/\\/g, '/');
        newstr = newstr.toString().replace(pathfull, fixslash);  //str.replace()->str.toString().replace()
    }
    return newstr;
}

I think there's a bigger problem here if the parameters typed as "string" are not actually "strings".  We'll need to try to reproduce this error under a debugger and see what the problem is.

This problem pops up only on the WSL version of VSCode so far, and there is no problem on Windows version temporarily.

By casting the parameters passed into the suspicious functions into string can also resolve the problem temporarily on WSL2 version of the VSCode.

Hmm, can't reproduce the problem on my WSL2 instance running Ubuntu 22.04.


build(lint): make lint script compatible with typescript >=v4.8.0

We had to disable linting [1] entirely when upgrading to Angular v15 (typescript
v4.8.4) because

the older ESLint we have right now does not support typescript versions of >=v4.8.0 AND
the newer ESLint that we COULD upgrade to is broken because it needs our packages to
be ESM (EcmaScript Modules) which is a big can of worms for now for us to open.

The big picture of the task here is to make yarn lint work again without crashes
and with good results (e.g. the script as it is right now is broken because it
lists hudnreds of false positive linter errors despite our configuration to not
do so)
The solution might be to migrate to ESM (which is long overdue because of how
annoying it is to have dependencies not work because of it).
Other, quick and dirty workarounds MIGHT be acceptible depending on what the
actual trade-offs are in terms of technical debt, performance, developer experience, etc.
[1] https://github.com/hyperledger/cacti/pull/2540

This will be fixed by another issue because of cascading dependencies: #1475


Notebook output mimetype text/x-LANGUAGE_ID is broken

An extension that I work on contributes multiple languages. I would like the output of my notebook cells to be colored using textmate grammar for one of those languages. The Notebook API documentation says this is possible using the text/x-LANGUAGE_ID mimetype, but this doesn't work, regardless of whether text/x-LANGUAGE_ID is listed as a mimetype in the language contribution point in package.json. This is broken in stable (1.67.1) and insiders.
Previously reported in #143358

@isc-bsaviano can you share a screenshot of what you are seeing now?

@rebornix Here's what I'm seeing when the output is text and the mimetype is text/x-vscode-objectscript-output:

And here's the section of my package.json where the language vscode-objectscript-output is defined:
https://github.com/intersystems-community/vscode-objectscript/blob/08f6775946c8f6dddeeca9233aa39bd234feee2f/package.json#L534-L605
Note that I see this behavior with any language in my package.json, not just vscode-objectscript-output.

This is currently a challenge after we moving the renderers from the core to builtin extensions, where the mimetypes we support is a fixed list https://github.com/microsoft/vscode/blob/main/extensions/markdown-language-features/package.json#L53 .

This issue has been closed automatically because it needs more information and has not had recent activity. See also our issue reporting guidelines.
Happy Coding!

@rebornix I think this was auto-closed in error


Can not delete folder

Description
Can not delete or move the folder, if the folder have sub-folder and the sub-folder is unfolded.
Steps to Reproduce

Create the folder A;
Create the folder B under A;
Unfold the folder B in the Tree View;
Delete A;

Expected behavior: Delete the folder A and B;
Actual behavior: Get error;
Versions
Atom    : 1.7.2
Electron: 0.36.8
Chrome  : 47.0.2526.110
Node    : 5.1.1
apm  1.9.2
npm  2.13.3
node 0.10.40
python
git 2.7.4.windows.1
visual studio
OS: Windows 7 SP 1
You can get this information from executing atom --version and apm --version at the command line. Also, please include the OS and what version of the OS you're running.

Please reopen this on the tree-view repository.


Modify the docs on scope schemes

[Please don’t  merge  Until WUM fix is released]
Purpose
Change the description of adding oauth2 scopes using an open API swagger definition.
Goals
Fixes: https://github.com/wso2/product-apim-tooling/issues/271
Approach
Previously it stated that name of the security scheme when adding scopes should be "default". But with the newest fix, this name can be an arbitrary one. This will state that change in docs.
When adding user roles for scopes there is the standard keyword to use. That also stated in here.

User stories
Users can follow the steps to create API using Swagger definition without changing the name of the security scheme.

@Chamindu36 , pls let me know when the WUM fix is released and also details of the WUM fix such as date it was released as that information needs to be added to the document.

Sure. I’ll do that


Does MLC support CPU or not

❓ General Questions
https://mlc.ai/package/
From above link, it seems that MLC can support CPU inference, but when I install it on a CPU platform, it failed with below error message even install vulkan
vulkaninfo
WARNING: [Loader Message] Code 0 : terminator_CreateInstance: Failed to CreateInstance in ICD 1.  Skipping ICD.
'DISPLAY' environment variable not set... skipping surface info
ERROR at vulkaninfo/vulkaninfo.h:248:vkEnumeratePhysicalDevices failed with ERROR_INITIALIZATION_FAILED
mlc_chat_cli --local-id Llama-2-7b-chat-hf-q4f16_1
terminate called after throwing an instance of 'tvm::runtime::InternalError'
what():  [14:52:44] /usr/share/miniconda/envs/mlc-llm-build/conda-bld/mlc-chat-cli-nightly-package_1692767194298/work/3rdparty/tvm/src/runtime/vulkan/vulkan_instance.cc:144: InternalError: Check failed: (__e == VK_SUCCESS) is false: Vulkan Error, code=-3: VK_ERROR_INITIALIZATION_FAILED
Stack trace:
[bt] (0) /root/anaconda3/envs/mlc/bin/../lib/libtvm_runtime.so(tvm::runtime::Backtraceabi:cxx11+0x27) [0x7fb5050a4d27]
[bt] (1) /root/anaconda3/envs/mlc/bin/../lib/libtvm_runtime.so(+0x680a8) [0x7fb5050680a8]
[bt] (2) /root/anaconda3/envs/mlc/bin/../lib/libtvm_runtime.so(tvm::runtime::vulkan::VulkanInstance::GetPhysicalDevices() const+0x1cd) [0x7fb50519af7d]
[bt] (3) /root/anaconda3/envs/mlc/bin/../lib/libtvm_runtime.so(tvm::runtime::vulkan::VulkanDeviceAPI::VulkanDeviceAPI()+0x14b) [0x7fb50519903b]
[bt] (4) /root/anaconda3/envs/mlc/bin/../lib/libtvm_runtime.so(tvm::runtime::vulkan::VulkanDeviceAPI::Global()+0x4c) [0x7fb5051992cc]
[bt] (5) /root/anaconda3/envs/mlc/bin/../lib/libtvm_runtime.so(+0x19930d) [0x7fb50519930d]
[bt] (6) /root/anaconda3/envs/mlc/bin/../lib/libtvm_runtime.so(+0x70c1c) [0x7fb505070c1c]
[bt] (7) /root/anaconda3/envs/mlc/bin/../lib/libtvm_runtime.so(tvm::runtime::DeviceAPI::Get(DLDevice, bool)+0x299) [0x7fb505072369]
[bt] (8) mlc_chat_cli(+0xfb98) [0x55a7ceb78b98]
Aborted (core dumped)

Looks like your vulkan driver fails:

vulkaninfo/vulkaninfo.h:248:vkEnumeratePhysicalDevices failed with ERROR_INITIALIZATION_FAILED

Please confirm if vulkaninfo could work.

Looks like your vulkan driver fails:

vulkaninfo/vulkaninfo.h:248:vkEnumeratePhysicalDevices failed with ERROR_INITIALIZATION_FAILED

Please confirm if vulkaninfo could work.
So? I still don't know whether MLC-LLM support pure CPU, as I guess vulkan should be a GPU driver?

Do you like to follow the instructions here to properly install Vulkan and validate if it works: https://mlc.ai/mlc-llm/docs/install/gpu.html#vulkan-driver?
If you are not using Vulkan, MLC LLM has a LLVM backend that targets CPU, but it's not officially supported. Use it at your own risk.

Do you like to follow the instructions here to properly install Vulkan and validate if it works: https://mlc.ai/mlc-llm/docs/install/gpu.html#vulkan-driver?
If you are not using Vulkan, MLC LLM has a LLVM backend that targets CPU, but it's not announced as officially supported yet. Use it at your own risk.

If CPU support is ok, can you share the guide about how to enable it on pure CPU platform?
If not, I think there should be some warning about CPU support on the webpage.

Do you like to follow the instructions here to properly install Vulkan and validate if it works: https://mlc.ai/mlc-llm/docs/install/gpu.html#vulkan-driver?
If you are not using Vulkan, MLC LLM has a LLVM backend that targets CPU, but it's not announced as officially supported yet. Use it at your own risk.

I would like to try using llvm as the backend version. Where can I obtain this version? If there are any bugs in this version, I am willing to try fixing it. I have some understanding of llvm.


Update Exercise 04 in training material

I have gone through the notebook (not run it) and I have the following comments that I hope you can take into account when you work through it @nabriis. Overall, I think the notebook is already in great shape and through setting up and solving a Bayesian Problem, we see a bit of distributions, samplers etc. It’s somewhat comprehensive but shorter than eg notebook 1, and fairly to the point, so I wouldn’t remove anything.

[ ] Other than: Remove “Finally” in first sentence.
[ ] Update Bayesian Model to Bayesian Problem throughout.
[ ] We discussed skipping Joint Distribution, and replace by BayesianProblem from which to pull out .posterior.  I'd suggest to wait until RV rework, as this breaks the current flow of the notebook.
[ ] Add URL to “Bayesian workflow” preprint: https://arxiv.org/abs/2011.01808
[ ] Sec 1, in Bayes theorem, Consider writing likelihood using L notation instead of as distribution. In fact, could add a few lines to introduce and distinguish CUQIpy “data distribution” and “likelihood” concepts and notation. Edit: I see this is done in Sec 1.4.  In the CUQIpy paper we use the expanded notation L(x| y = y^obs), which for consistency should consider here as well.
[ ] Strongly suggest to replace all greek symbols, e.g. \sigma by “s”, as I feel – while clear and neat in principle – looks unconventional and therefore adds unnecessary overhead, may cause confusion as to whether one must use greek symbols, and is also more difficult to type new code in as one may not know how to type a greek letter, so would copy paste.
[ ] Sec 1.2, after equation of noise e: “observed data” should probably be “data”, since y is not the actual observed data. Seems the term “data distribution” is not used here, but I think it should be?
[ ] In the sampler section, unlike previos sections, we use full name eg cuqi.sampler.LinearRTO. Change to from cuqi.sampler import LinearRTO to simplify and make consistent.
[ ] Note that the notebook does not cover Gibbs sampling or automated sampling using BayesianProblem of hierarchical problems. I think that is fine, we do not want to expand it, but perhaps at the end of the session you could point to the Gibbs notebook (and the other notebooks) to point out where participants can find such examples.
[ ] Please run through and execute the notebook to make sure the results make sense and you know what code to type in to solve the exercises.
[ ] Do we need to run through other training notebooks and make sure they work, if directing participants to them?


docs: update readme with new Node recursive developments

closes https://github.com/fabiospampinato/watcher/issues/32 as it's written
I don't know if you have an opinion about whether this library should be updated to use that new functionality on Linux when using Node 20+

Thanks 👍

I don't know if you have an opinion about whether this library should be updated to use that new functionality on Linux when using Node 20+

Yeah it probably should. It's probably best to wait until Node v18 reaches end of life, next year 🤔


[google_maps_flutter] (web) The GoogleMap widget is always on top.

The GoogleMap widget is always on top.
I have tried to use stack, dialog, and IgnorePointer to block any action of the GoogleMaps but it's not working.
I think it is a bug. I can't play this with any widget. I am using the onTab of the GoogleMap to show the GoogleMap picker, when I click dialog, dropdown menu, the container in the stack, or icon button in the area of GooleMap, the GoogleMap will action it too or I click the icon button in the same position of pin location of GoogleMap, the GoogleMap will action by show info of this location.
In my opinion. I think it is a bug. The GoogleMap should be a general widget that can be used in a variety of ways.

You can find this issue in my video.

The Inkwell on a GoogleMap to show the GoogleMap picker.
At 9 seconds, I click at the pin of the location.
After I closed the dialog, the info will show at 16 seconds.
I already used Inkwell but GoogleMap is still active.
https://user-images.githubusercontent.com/59549741/152727927-e122bbeb-0f00-4af6-99b4-ea7d6ad2ae76.mp4

The IconButton with The Stack on the GoogleMap.
At 5 seconds, I click the IconButton on the blank area and the map will move to my location.
At 15 seconds, I click the IconButton on the pin location. After this, the map will move to my location and move again to this pin location.
I already used the Stack and the IconButton is on the GoogleMap but the GoogleMap still active.
https://user-images.githubusercontent.com/59549741/152728378-ce077e9a-0ea5-4d47-a454-22e65aba69eb.mp4

The Dropdown Menu on GoogleMap.
At 17 seconds, I click the menu of the Dropdown on GoogleMap, and the GooleMap is active.
https://user-images.githubusercontent.com/59549741/152728702-3fd9021e-8899-43f0-88f5-aeeb0b5e832a.mp4

The DatePicker on GoogleMap.
At 17 seconds, I click the DatePicker on GoogleMap, and the GooleMap is active.
https://user-images.githubusercontent.com/59549741/152729043-f7122316-a626-4e9f-b2b2-90a91370aaea.mp4

The dialog with the context on The GoogleMap.
At 8 seconds, I click the dialog on GoogleMap, and The GooleMap is active.
At 20 seconds, you can see the info of the pin location is active too. The function of GoogleMap for show info is under the dialog but it is still active.
At 28 seconds, you can see the zoom function of The GoogleMap is active.
https://user-images.githubusercontent.com/59549741/152729878-b7969c8c-a4a0-4cfc-a2dc-0312d3ddb3b5.mp4

I am using google_maps_flutter: ^2.1.1 and google_maps_flutter_web: ^0.3.2+1 package.
flutter doctor:
Doctor summary (to see all details, run flutter doctor -v):
[√] Flutter (Channel beta, 2.10.0-0.3.pre, on Microsoft Windows [Version 10.0.19042.1466], locale th-TH)
[√] Android toolchain - develop for Android devices (Android SDK version 30.0.3)
[√] Chrome - develop for the web
[√] Android Studio (version 2020.3)
[√] VS Code (version 1.63.2)
[√] Connected device (2 available)
[√] HTTP Host Availability

• No issues found!

Now, I am using google map static API for my project.
But this solution is waste the internet to download the map picture and I need to create a custom button and function for Google Maps.
I hope the developer will solve this.

@SittiphanSittisak
Please provide a complete minimal reproducible code sample (e.g main.dart) without any 3rd party plugins along with exact steps to replicate that shows what exactly is the issue you are facing including actual vs expected behavior.
Thanks.

@SittiphanSittisak
This is an underlying issue related to web framework and platform-views, which is tracked here, so follow-up in it for further updates.
Closing this as a duplicate.


Mixed frequencies in ML and PC

This is currently not possible. Can we not use the same routines here as well? Both seems highly useful.

Both ML and PC estimation have issues with mixed frequency estimation, though various ways around these problems are common enough. I'll begin with ML estimation:
Maximum Likelihood Estimation
Mixed frequency estimation via maximum likelihood is no problem when we estimate the model numerically, i.e. by searching over all possible parameter values for those which maximize the log likelihood from the Kalman Filter. We do not use this approach in the bdfm package as it is very slow and subject to getting stuck in local (but not global) maxima.
When estimating the model via Watson and Engle's algorithm mixed frequency estimation becomes a little problematic due to the mechanics of the algorithm. The algorithm works by keeping track of an extra lag of factors (i.e. one more than we specify in the transition equation) to derive the adjustments to our otherwise OLS estimates of parameters. These adjustments compensate for the fact that factors are not observed.
With mixed frequency data, we specify the transition equation at high frequency. However, we typically want to include enough lags in the model include at least one lag of the data at low frequency, sometimes more. With quarterly-monthly data that's no big deal --- we need at least 3 lags (three months in a quarter). With monthly-daily data, however, this becomes problematic. We need at least 31 lags of the data, which makes the Watson Engle algorithm prohibitively slow due to the fact that we need to use the standard Kalman Smoother, not a more efficient disturbance smoother (the latter does not return the variance of factors given all observations which is required for the Watson Engle algorithm). With Bayesian estimation things aren't so slow because we are able to use the disturbance smoother which handles lots of lags much better.
The only way around this I'm aware of that is not prohibitively slow (slow meaning numerical estimation or Watson Engle estimation with lots of lags) is to specify the model at low frequency. Whether PC, Bayesian, or ML, specifying the model at low frequency is a totally different approach to what we've done with this package. I've done it (it's the approach I use with my new company OttoQuant), but I'm not really willing to give it away.
Principal Component Estimation
Principal component estimation relies on there being few missing observations since there is not a particularly clean way to calculate principal components when observations are missing. With mixed frequency data, lots of observations are necessarily missing as we have no high frequency observations of low frequency series. The way most people get around this issue is to simply estimate principle components using the high frequency data only, then plugging the resulting parameter estimates into the dynamic factor model. However, if your low frequency series are central to your model or if you don't have many high frequency series, this approach probably won't work well. It's a fudge and I don't really like it, so I've not included it. However, it is very easy to do using the existing bdfm framework, so if you want to include it we can, with the disclaimer that the results will probably be poor.

With monthly-daily data, however, this becomes problematic

I thought the Bayesian method also does not support monthly daily. Or does it? If so, we need an example! I would be happy with standard quarterly-monthly ML, not supporting the daily stuff is fine.

The Bayesian method should cover any frequency mix: monthly-quarterly, hours-half hours, even minutes-seconds, though with that many lags (60) it would probably be slow. The one caveat is that the package does not handle irregular frequencies properly. When given mixed frequency data, the package looks for patterns of missing observations, and interprets regular patterns as mixed frequency data. A frequency argument of 1 means the series is observed every period. A frequency argument of 2 means the series is observed every other period. 3 is every third period, and so on. With monthly data, more months have 31 days than anything else, so if the data mix is monthly-daily the package sets the frequency of monthly data to 31. This means we will be using too many days in months like September with 30 days --- observations for September would actually use factors for September as well as the last day of August. Not ideal, but much simpler than trying to change the frequency mix at every period.
I'll work on putting together an example with monthly-daily data.
Regarding mixed frequency ML estimation, I'd rather not get into it as (a) it's a big project and would take a lot of time as the filtering/smoothing algorithms for ML are not the same as the Bayesian filtering/smoothing algorithms, (2) it would still be slow for longer lag lengths and (3) estimates won't be any better than Bayesian estimates anyhow --- and probably worse.

Thanks, that's very useful.
So I didn't know The Bayesian method should cover any frequency mix. I just opened a separate issue with the pros and cons of the different methods (#80) and one for the example (#81).
To summarize, you are saying:

ML monthly daily would be possible, but a lot of work, with not too much use.
PC mix frequency is not accurate.

So I am fine with both of them not supporting mixed frequencies.
One final question:
Let's say I have 1000 daily financial series and 10 monthly and quarterly series. Would it make sense to use PC to aggregate the 1000 series to a few factors, and use them withing the Bayesian method, along with the 10 series?
Otherwise, we can close this.


android view not working.

The tab bar is not working on android when I click on the tab on android the content is not showing.
		        <ScrollView tabLabel="Tab2">
							<Tab2Page />
						</ScrollView>

What version do you use?

"react-native": "^0.26.0"
"react-native-scrollable-tab-view": "^0.4.3"

I can't reproduce this bug. Could you please give a code snippet? Even better if you create a pull request to example with this bug

@skv-headless. I found the issue already.
<ScrollView style={styles.bottomFrame}>
  <ScrollableTabView tabBarUnderlineColor="#38B69A" tabBarActiveTextColor="#38B69A">
    <ScrollView tabLabel="Tab1">
      <Tab1Page />
    </ScrollView>

   <ScrollView tabLabel="Tab2">
      <Tab2Page />
    </ScrollView>

   <ScrollView tabLabel="Tab3">
      <Tab3Page />
    </ScrollView>

  </ScrollableTabView>
</ScrollView>

After I have changed the ScrollView to VIew. It works like charm. So probably i will move the scroll into the content of each tab. Thanks for the help.


Add some better error messages for an edge case.

Fixes https://github.com/Azure/azure-cli/issues/9657

@brendandburns Hello. The title should be meaningful which summarize the content of this PR. Besides, History.rst should be updated.


Have a mode to show what's causing a keyboard shortcut conflict

Is your feature request related to a problem? Please describe.
I forgot where I saw the feature, maybe Atom. When you are tweaking your keyboard shortcut, if it runs into a conflict, the editor will list out what actions are bound to this shortcut and which ones are not being triggered. Something like that. This is extremely helpful if you are configuring VSCode Vim to work with normal VSCode.
Describe the solution you'd like
Having something similar would be really nice. Just a way to list out all the actions and their conditions when I press a shortcut and marking out which one is being executed and which ones are not.
Describe alternatives you've considered
Well, I mean without the feature, VSCode is still amazing. I just need to spend more time to wrap my head around and figure out why a specific shortcut is not working. I guess it's nice to have...

It's already in VS Code. When you perform Add Keybinding or Change Keybinding action in Keyboard Shortcuts view it will show that there are commands that have provided shortcut

Click on "13 existing commands..." will perform search by this shortcut to show you whole list
If it's not what you are looking for - please add more details how it should be different from current behavior.

Sorry, I'm more talking about when I'm actually using a shortcut in a file. Not in the keyboard shortcut page. I know people may think the difference is subtle, but I think the context here can be quite handy. Again I think it's just a good to have if this never makes it to the priority list. Thanks.

Oh, I was confused by

When you are tweaking your keyboard shortcut, if it runs into a conflict, the editor will list out what actions are bound to this shortcut

Where "tweaking" looks more like changing/adding than actually using.

Sorry for the confusion, I was picturing using Vim in VSCode when I typed that "tweaking"


Multiple Monitor Roundly - different results editor player vs standalone app

Hello @hecomi ,
First of all, thanks for the Unity plugin you created, it is awesome.
I am trying to use the Multiple monitors roundly sample, but for some reason, I am getting different results when running with Unity Editor vs building and running a standalone app.
Here are the screenshots:

I've tried to debug and understand what's going on - mainly on uDesktopDuplication\Examples\Scripts\MultipleMonitorRoundLayouter.cs script, but didn't find the root cause. Could you check it?
Thanks,
Andre

I had same question. anyone can address?

Hello, the solution to this problem is simply to change the TargetEye mode to None (MainDisplay) on the corresponding Camera to solve it

same here.

solve this issue by adjust the setting on monitor board prefab : Texture->Mesh Forward Direction->Z


Added Newsletter Subscription-2 Form

Fixes Issue🛠

Closes #607
Description👨💻
Added Newsletter Subscription-2 Form

Type of change📄

[x] New feature (non-breaking change which adds functionality)

How this has been tested✅
On my local system.

Checklist✅

[x] My code follows the style guidelines of this project
[x] I have performed a self-review of my own code
[x] I have commented my code, particularly in hard-to-understand areas
[x] I have added demonstration in the form of GIF/video file
[x] I am an Open Source Contributor

Screenshots/GIF📷

Merged 🎉 @PranavBarthwal


Fix Glyphs Sometimes Existing Where They Shouldn't in Multiplayer

Fixes an issue where, sometimes in multiplayer, glyphs would randomly be applied to items that really shouldn't have glyphs. This is complemented by the server and client seeming to disagree which items should(n't) have glyphs, leading to random glyph'd items at best and completely breaking multiplayer at worst.
Also fixed a small issue where GlyphGlobalItem was retrieved from an item without checking if that item actually had GlyphGlobalItem.
I'm not 100% sure of the cause of this, but I do know that I saw GlyphGlobalItem hooks being called on items that they shouldn't've been (namely, dyes). I want to say that it was being applied to modded items
Reproduction:

Enable Spirit Mod, any mod that adds a dye, and your cheat tool of choice. (I used Example Mod for this, but I can confirm it also happens with Calamity's Vanities).
Enter a world in singleplayer and place down a Mannequin. Fill this Mannequin's dye slots with a modded dye (Example Dye).
Place a second Mannequin to the right of the first one.
Exit the world, then Host & Play on the same world.
Upon loading in, the second Mannequin shouldn't be rendering properly, and other strange occurrences will be happening (tiles not being frames, chunk errors, NPCs sliding, etc.)

I recently made the change with AppliesToEntity, and I thought I got everything. I don't know exactly what lateInstantiation means so I missed that too. We have had some reports with GlyphGlobalItem though, just didn't know why. Thank you!


How to handle item offsets in flex grids?

I am trying to achieve something like Bootstrap's offset utility classes, particularly useful in horizontal forms where an element doesn't have a label, for example. Any thoughts on how to achieve that here? I would like to avoid inserting dummy divs or spans to deal with it. (They serve no semantic purpose, and therefore should not be part of the DOM.)
I was thinking that utility classes along the lines of .ml-1/3 and .pr-1/4 would be nice, but I do understand that those add can add quite a bit of overhead?

Hey Mike, for simple cases you can handle this with either auto margin utilities or justify content utilities. Here are quick examples of both:
Using auto margin utilities
Using justify content utilities
These won't handle really complex situations with many columns in a row, but they should be enough for common use cases. Let me know how that works for you!

oh, of course!! haha, forgot about the aligning features of the auto classes. Thanks for the reminder, that should work perfectly!

Hi, I've raised this here (didn't realise this discussion site existed)
https://github.com/tailwindcss/tailwindcss/issues/632
i've been using inuitcss previously and needed to use its responsive push/pull column offset classes on the last 3 projects I've done, so yes it would be great to see some implementation of this like @aaronmoodie posted above
as mentioned something like this would be useful
.u-pull-1/6@tablet
.u-push-1/4@desktop
.u-push-reset@wide

so in terms of tailwind syntax maybe eg
md:pull-1/6 lg:push-1/4

just leaving the info for anyone looking. this is essentially doable with the margin/negativeMargin in the config file
( @aaronmoodie )
negativeMargin: { ... '1/6': '16.6666666667%' }
then
class="lg:-ml-1/6" (instead of a custom pull class for eg lg:pull-1/6)


[SPARK-49391][PS] Box plot select outliers by distance from fences

What changes were proposed in this pull request?
Box plot select outliers by distance from fences
Why are the changes needed?
if there are more than 1k outliers, existing implementations select the values by distance |value - min(non_outliers)| which is not reasonable because it prefers outliers above upper fence over outliers below lower fence.
We should order them by the distance from fences:
1, if value > upper fence,  value - upper fence;
2, it value < lower fence,  lower fence - value;
Does this PR introduce any user-facing change?
No
How was this patch tested?
CI and manually test
Was this patch authored or co-authored using generative AI tooling?
No

merged to master


This action does not support the 'pull_request' event.

Greetings. I am getting the following error;
"This action does not support the 'pull_request' event."
I am using the latest version.
Thanks

Only the pull_request_target event is supported since you need access to secrets.

Actually, I figured it out. I created to have two separate GitHub Actions yaml files one for the pr.yml and another for the merge.yml  with:
on:   pull_request_review:     types:       - submitted
and it worked.
Thanks

Next question: is there an input to close the PR after the merge?
Thanks

If a PR is merged, it is also closed.

Okay thanks for some reason it's not doing that.


MI300 Infra Testing

ci-exactly: test_mi300

This was a bunch of debugging/testing out the mi300 machine to figure out what needs to be done with all of the security constraints on the machine


Stretch shrink messes up the ui

Godot version:
3.2.1 stable
OS/device including version:
Windows 10
Issue description:
From the docs I get, that using scale shrink can be used to get a performance boost, by lowering the 3d resolution.

If Stretch Mode is set to something other than Disabled, the size of
the root viewport is scaled down by the Shrink factor, and pixels in
the output are scaled up by the same amount. This is rarely useful for
2D games, but can be used to increase performance in 3D games by
rendering them at a lower resolution.
https://docs.godotengine.org/de/stable/tutorials/viewports/multiple_resolutions.html#stretch-shrink

Using the shrink is not just scaling the 3d rendering, but also the ui rendering.
This is how my main menu looks with shrink = 1:

This is how it looks with shrink = 5:

The 3d rendering is lowered as intended, but the game can't be played anymore because of the ui scaling.
I've set my stretch mode to "2d" and the aspect to "expand" in the project settings.

This happens because that option affects the root viewport, which contains every single visible object, including UIs. To achieve what you want, you need to create another viewport, and scale that instead, something like this:

I do agree though that this option is generally used for reducing 2D/3D objects rendering time, and leaving the UI elements at full scale; so if that was the reason this option was introduced, then it is not working as it should.

See the answer I posted on the Godot Q&A: https://godotengine.org/qa/71239/lower-3d-resolutions-without-messing-up-ui#a71243

I think the info in Calinou's QA answer and Ev1lbl0w's comment should be added to docs.

While the addition of the "use multiple viewports" answer is useful, it only addresses some cases. Most (all?) people using "stretch: shrink" (now renamed to "stretch: scale") will have some kind of 2D UI in addition to the 3D viewport. We may want to scale that UI as well, to achieve a pixelated or retro look. However, as Godot is now, "Anchors Preset: Full Rect" positions the UI using un-scaled dimensions. Is there an alternative anchoring approach that should be used for projects with scale != 1?

While the addition of the "use multiple viewports" answer is useful, it only addresses some cases. Most (all?) people using "stretch: shrink" (now renamed to "stretch: scale") will have some kind of 2D UI in addition to the 3D viewport. We may want to scale that UI as well, to achieve a pixelated or retro look. However, as Godot is now, "Anchors Preset: Full Rect" positions the UI using un-scaled dimensions. Is there an alternative anchoring approach that should be used for projects with scale != 1?

See the Multiple Resolutions demo which was created after this issue was opened (it exists for both 4.0 and 3.5).


Styleguide

We should provide a styleguide for the various components we will have.
There some tools to create styleguides:

https://github.com/styleguidist/react-styleguidist
https://github.com/storybooks/storybook

I'd go for storybook :)


Clarify comparisons for null

Use this query to search for the most popular feature requests.
Is your feature request related to a problem? Please describe.
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...]
Since null is supported in comparisons, its behavior should be documented and tested.
Describe the solution you'd like
A clear and concise description of what you want to happen.
Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.
Additional context
Add any other context or screenshots about the feature request here.
[enhancement]

Hi @luhan2017, can you close this issue if it is done?
Thanks


Renaming knives internally will break Dynamic Surroundings support

Currently DS looks for itemDruidKnife, not itemMageKnife.  If you change it internally, Dynamic Surroundings will need to update to reflect this change.  Not critical, but you said to remind you if it didn't happen that night.

Ty, this issue will help me remember to change it back. I umm'd and ahh'd before renaming and then decided to just go ahead with it, but with this knowledge, I'll revert back, as it doesn't really cause any issues internally.

Oh, I undid this.


Update testing libraries

Update the testing libraries to their latest available versions. In preparation for migration to JUnit 5.

also update joda-time (version 2.9.1 comes with AEM 6.3 and 6.4)

Pull Request Test Coverage Report for Build 5269

0 of 0   changed or added relevant lines in 0 files are covered.
28 unchanged lines in 4 files lost coverage.
Overall coverage decreased (-0.07%) to 55.595%

Files with Coverage Reduction
New Missed Lines
%

bundle/src/main/java/com/adobe/acs/commons/analysis/jcrchecksum/impl/ChecksumGeneratorImpl.java
1
96.35%

bundle/src/main/java/com/adobe/acs/commons/httpcache/config/impl/HttpCacheConfigImpl.java
1
93.98%

bundle/src/main/java/com/adobe/acs/commons/replication/status/impl/ReplicationStatusManagerImpl.java
3
84.29%

bundle/src/main/java/com/adobe/acs/commons/filefetch/impl/FileFetcherImpl.java
23
68.6%

Totals

Change from base Build 5268:
-0.07%

Covered Lines:
15040

Relevant Lines:
27053

💛  - Coveralls

Let's wait until aem-mocks 2.7.2 is released; i had to disable a test because of WTES-48 (https://wcm-io.atlassian.net/browse/WTES-48)

Ready for merging, please review :-)


https://arxiv.org/abs/2410.18113 html wrong

Description
only footnote and references are available.
(Optional:) Please add any files, screenshots, or other information here.
No response
(Required) What is this issue most closely related to? Select one.
Choose One
Internal issue ID
ade76aee-fc85-4c99-8a6a-c4487bbc570c
Paper URL
https://arxiv.org/html/2410.18113v1
Browser
Firefox/133.0
Device Type
Desktop

I figure out that at local, i should add --path=./sections to use latexmlc correctly.

Well-identified, as this is a limitation due to latexml not emulating the deeper internal macro layer for path inptus.
Specifically, the article uses:
\def\input@path{{sections/}}

which isn't part of the public LaTeX interface, and hasn't been used internally by latexml. We support the TEXINPUTS enviornmental variable, as well as \graphicspath for graphics.
For use in arXiv today, you may need to provide the accurate relative path from the main TeX file to each input.


Allow clients to define custom callbacks to handle telemetry

Description of change
Different users of mountpoint will care about different metrics returned for each requests, so allow them to define their own custom handlers for the on_telemetry callback in addition to the default metrics that mountpoint emits.
This allows users to do things like:

emit extended request ids ("x-amz-id-2")
When some criteria is met, log out additional information

Relevant issues: #1079
Does this change impact existing behavior?
No there should be no breaking changes, the only visible change is that there's a new field to the S3ClientConfig which defines the custom telemetry handler
Does this change need a changelog entry in any of the crates?
Just a note in mountpoint-s3-client letting users know this feature now exists

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license and I agree to the terms of the Developer Certificate of Origin (DCO).

Resolved conflicts in latest revision

Another merge conflict with mainline
@vladem Can you restart the test runs again?

Interface has changed, I will have to resolve this locally.

I've rebased back onto upstream's mainline


Hangs on run

Roberts-MacBook-Pro:Scripts robertnash$ cd ~/Desktop/Folder1/
Roberts-MacBook-Pro:Folder1 robertnash$ marathon create addSuffix
🐣  Created script at addSuffix.swift
✏  Opening Addsuffix.xcodeproj/
ℹ  Marathon will keep running, in order to commit any changes you make in Xcode back to the original script file
Press any key once you're done

Marathonfile = git@github.com:JohnSundell/Files.git

Roberts-MacBook-Pro:Folder1 robertnash$ marathon run addSuffix "something"
hangs here

@rob-nash Hi! Thanks for the report. Unfortunately I can't reproduce it on my machine, even if I first remove Files from Marathon. Let's debug it - can you:

Verify that the contents of your Marathonfile is exactly git@github.com:JohnSundell/Files.git?
Confirm that you have Swift 3.1 (bundled with Xcode 8.3) installed?
Run $ marathon list and show me what it outputs?

And let's take it from there 🙂

Hi John,
Thanks for the quick response.
Today it is not hanging! But I do get an error. Firstly, let's go through your steps.

Verified 👍
Confirmed 👍
Here you go:

Roberts-MacBook-Pro:~ robertnash$ marathon list
📄  Scripts
/Users/robertnash/Desktop/Folder1/addSuffix.swift
👉  To remove either a package or the cached data for a script, use 'marathon remove'
Roberts-MacBook-Pro:~ robertnash$ marathon run addSuffix "something"
💥  Could not find a Swift script at 'addSuffix.swift'
👉  Please check that the path is valid and try again

Now I understand why it was hanging, only sometimes. Now I can reproduce the hanging consistently by performing this command in the same folder as addSuffix.swift.
Video attached shows the point at which it hangs.
1.mov.zip

@rob-nash Since I'm unable to reproduce this locally, do you mind helping a bit with debugging this issue?

Generate an Xcode project for marathon by going to its repo and running swift package generate-xcodeproj.
Open the generated Marathon.xcodeproj.
Select the command line scheme, and go to Product > Run...
Add the launch arguments run, <path-to-addSuffix.swift> (replace with actual path) and "something".
Run.

Does it still hang? If so, can you pause execution of the program and let me know where it hangs?
Also, can you make sure you are on the latest master?

Sorry for late reply. Yes I don't mind. I will take a look now.

It's failing here
let rootFolder = try perform(fileSystem.createFolderIfNeeded(at: folderPath), orThrow: setupError)

couldNotPerformSetup("~/Desktop/Folder1/addSuffix.swift")
Program ended with exit code: 0
Might be permissions again.

Wait...why are we trying to create a folder at this point ?
'if needed' suggests that it might fail for a good reason and that we should ignore that error right ?
will take a look

Just pulled files and imported into iOS App target.
class ViewController: UIViewController {

    override func viewDidLoad() {
        super.viewDidLoad()

        let fileSystem = FileSystem()
        let path = "~/Desktop/Folder1/addSuffix.swift"
        do {
            let folder = try fileSystem.createFolderIfNeeded(at: path)
            print(folder)
        } catch let error {
            print(error)
        }

    }

}

No error. Output is
Folder(name: addSuffix.swift, path: /path/to/Desktop/Folder1/addSuffix.swift/)
Although, this is a file...not a folder. So will run Marathon again with use the path ~/Desktop/Folder1/

???
try Marathon.run(with: ["run", "something"], folderPath: "~/Desktop/Folder1/", printer: { value in
    print(value)
})

Output
'something' is not a valid command
try Marathon.run(with: ["run"], folderPath: "~/Desktop/Folder1/", printer: { value in
    print(value)
})

Output
Welcome to Marathon 🏃
Marathon makes it easy to write, run and manage your Swift scripts.
These are the available commands:
🐣    create    Create new script at a given path and open it
✏    edit      Edit a script at a given path
🗑    remove    Remove a package or the cache data for a script at a given path
🏃♀    run       Run a script at a given path
💻    install   Install a script at a given path as a binary
📦    add       Add a package from a given URL to be able to use it from your scripts
📋    list      List all packages and cached script data
♻    update    Update all added packages to their latest versions
ℹ    help      Print these instructions
👉  You can also type a command you wish to know more about after 'help'
For example: 'marathon help create' will show information about the 'create' command
🌏  For more information, go to https://github.com/johnsundell/marathon
Program ended with exit code: 0
try Marathon.run(with: ["addSuffix"], folderPath: "~/Desktop/Folder1/", printer: { value in
    print(value)
})

Output
Welcome to Marathon 🏃
Marathon makes it easy to write, run and manage your Swift scripts.
These are the available commands:
🐣    create    Create new script at a given path and open it
✏    edit      Edit a script at a given path
🗑    remove    Remove a package or the cache data for a script at a given path
🏃♀    run       Run a script at a given path
💻    install   Install a script at a given path as a binary
📦    add       Add a package from a given URL to be able to use it from your scripts
📋    list      List all packages and cached script data
♻    update    Update all added packages to their latest versions
ℹ    help      Print these instructions
👉  You can also type a command you wish to know more about after 'help'
For example: 'marathon help create' will show information about the 'create' command
🌏  For more information, go to https://github.com/johnsundell/marathon
Program ended with exit code: 0

@rob-nash Really seems like a permissions problem. Marathon stores all of its data in a ~/.marathon folder, which is what it seems to fail to create. It's very curious that the file path is ~/Desktop/Folder1 though. Did you modify Marathon's source code before installing it? Can you make sure that you have write permissions to your home folder (can't see any reason why you shouldn't have though).

The reason you get something is not a valid command is because the first argument should be the execution path, as this is what gets given from the command line. Why are you envoking Marathon.run in code btw? Just for testing?

I attempted to debug the source code by running it and passing arguments in line with the source code.
If I execute the source code using the 'Marathon - My Mac' scheme the debug panel prints the same output that I see in the deployed terminal App. The programme runs to completion (Program ended with exit code: 0) so I am not given an opportunity to add arguments unless I modify the source code.
The permissions for my home directory is
drwxr-xr-x+ 40 robertnash                 staff   1360  6 Apr 11:24 robertnash

I don't actually know what the '+' symbol represents. Interestingly I can't launch the mac Spotify.app ! I have asked stacks for some input on this. http://stackoverflow.com/questions/43274359/cant-open-macos-app-what-does-the-symbol-represent-in-permissions
It now seems like my file system is being weird and I have no idea why it's behaving this way. This worried me a great deal. You may want to close this thread.

Then again...
I can see the ~/.marathon directory. The subdirectory 'Scripts' has the following
-Users-robertnash-Desktop-Folder1-addSuffix

If this was a permissions problem the terminal App would return some sort of error, instead of hanging, right?
I'm sorry I can't give you any more insightful information than this. I will perform some more debugging over the weekend and if I find anything useful, I will post it here. You may want to close this thread anyway as the permissions problem I'm getting launching macOS Apps is likely the root cause, even if it doesn't make sense.

 For reference here are the permissions of my home folder: drwxr-xr-x@ (I know too little about permissions to decipher them though 😅).
If you're fine with closing this, then I think we can do it. You can always open a new issue if you find this to be a Marathon-specific problem.
Btw, you can totally set launch arguments in Xcode without having to modify the source code. Just go to the Product > Run... menu and set arguments there 🙂

Thanks John. Will get back to you if I learn something relevant.


About IQKeyboardManagert

Hey there:
The SLKTextViewController has integrated a functional that the STKToolBar and tableView will move with the Keyboard, which has a conflict with the IQKeyboardManager, the solution is to disable the keyboard manager in viewWillAppear and enable it again in viewWillDisappear. As both these two libs have a wide usage already, I think it is necessary to mention it. This is not an already-known issue, right?

I don't mean to fix it. I mean to present it on the readme file to let people know. I have fixed it by add a few codes, and can send a pr for this which only add three or four lines in only the readme file, only if you think that is necessary

I added warning notes for third-party libraries and for other developers who uses third-party library UI with IQKeyboardManager. hackiftekhar/IQKeyboardManager@29be5f058b6f2d350b6f3527b7fb31c051459cf9

Thanks @hackiftekhar
It's very useful. I've get used to disabling it for some specific UIViewController in AppDelegate. Hope other developers could get used to it quickly.


Fix lint warnings

The following rules were set to "warn" so that we could focus on more important issues, but these should all be fixed as well:

[ ] no-negated-condition
[ ] no-unused-vars
[ ] prefer-destructuring
[ ] unicorn/no-for-loop
[ ] unicorn/prefer-includes
[ ] unicorn/prefer-string-slice
[ ] unicorn/filename-case
[ ] unicorn/prefer-query-selector
[ ] Unsafe assignment to innerHTML  no-unsanitized/property - see FIXME in in display.js

The overrides are defined in https://github.com/zaproxy/zap-hud/blob/develop/package.json#L54-L63 (the lines may change in time)

These are the pending no-warning-comments in HUD.

// TODO change to try loading from localstorage (src\main\zapHomeFiles\hud\tools\commonAlerts.js)
// Todo: change this to 'continue' and figure out / fix stopBreaking (src\main\zapHomeFiles\hud\tools\break.js)
// FIXME: remove after #620 (src\main\zapHomeFiles\hud\display.js)
// Todo: is this too hacky? (src\main\zapHomeFiles\hud\target\inject.js)
// TODO showComments section - put this code in a separate file and inject ? (src\main\zapHomeFiles\hud\target\inject.js)
// TODO showEnable section - put this code in a separate file and inject ? (src\main\zapHomeFiles\hud\target\inject.js)

Give me the go-ahead to remove them and then we can merge this PR

Assigned 😁


use Linux bridge CNI in vmi_multus_test.go

The preferred CNI providing L2 connectivity has been changed from
OVS to Linux bridge. Because of that, and since we don't configure
OVS bridge on OKD local setup, this patch switches to Linux bridge
CNI.
Release note:

NONE

/test pull-kubevirt-e2e-k8s-multus-1.13.3

/test pull-kubevirt-e2e-k8s-multus-1.13.3

/test pull-kubevirt-e2e-k8s-1.11.0

pull-kubevirt-e2e-k8s-multus-1.13.3

/test pull-kubevirt-e2e-k8s-multus-1.13.3

/test pull-kubevirt-e2e-k8s-multus-1.13.3

/test pull-kubevirt-e2e-k8s-multus-1.13.3

I can see this 3 failures
Multus [rfe_id:694][crit:medium][vendor:cnv-qe@redhat.com][level:component]VirtualMachineInstance using different types of interfaces. VirtualMachineInstance with Linux bridge CNI plugin interface [test_id:1577]should create two virtual machines with one interface expand_more	1m30s
Multus [rfe_id:694][crit:medium][vendor:cnv-qe@redhat.com][level:component]VirtualMachineInstance using different types of interfaces. VirtualMachineInstance with Linux bridge CNI plugin interface [test_id:1578]should create two virtual machines with two interfaces expand_more	1m30s
Multus [rfe_id:694][crit:medium][vendor:cnv-qe@redhat.com][level:component]VirtualMachineInstance using different types of interfaces. VirtualMachineInstance with Linux bridge CNI plugin interface and custom MAC address. [test_id:676]should configure valid custom MAC address on Linux bridge CNI interface. expand_more	1m51s

/hold
@cynepco3hahue yeah, persistent retests cured timeouts on all the other suites, I guess this one really needs a fix.

@phoracek how new is the change? I have the feeling our multus tests are still using the previous ovs.

@petrkotas they are using OVS, that's why I posted this PR. The local kubernetes and openshift clusters contain pre-installed OVS CNI pluggins as well as pre-created OVS bridge br1. Recently we switched to using cluster-network-addons-operator in order to install network components on kubevirtci images. While on kubernetes and openshift cluster we still have original OVS deployment in place, with okd that's not the case. We want to test whatever CNI L2 plugin is given by network-addons-operator, hence this change.

/test pull-kubevirt-e2e-os-3.11.0-multus

As @SchSeba found out, we have to configure iptables on the node. We can do it either as a part of kubevirtci, or using https://github.com/containernetworking/plugins/tree/master/plugins/meta/firewall (after patching it for L2).
https://github.com/containernetworking/plugins/tree/master/plugins/meta/firewall

/test pull-kubevirt-e2e-k8s-multus-1.13.3

/test pull-kubevirt-e2e-k8s-multus-1.13.3

/test pull-kubevirt-e2e-k8s-multus-1.13.3

/test pull-kubevirt-e2e-k8s-multus-1.13.3

/test pull-kubevirt-e2e-k8s-1.11.0

@cynepco3hahue could you please take another look at this approach? Thanks.

/test pull-kubevirt-e2e-os-3.11.0-multus

/test pull-kubevirt-e2e-k8s-genie-1.11.1

/test pull-kubevirt-e2e-k8s-1.11.0

/test pull-kubevirt-e2e-os-3.11.0

/test pull-kubevirt-e2e-windows2016

/assign @vladikr
All affected suites have passed, could you please take a look?

/test pull-kubevirt-e2e-os-3.11.0-crio

/test pull-kubevirt-e2e-os-3.11.0

/test pull-kubevirt-e2e-k8s-multus-1.13.3

/test pull-kubevirt-e2e-os-3.11.0-multus

/test pull-kubevirt-e2e-windows2016

/test pull-kubevirt-e2e-k8s-genie-1.11.1

/test pull-kubevirt-e2e-os-3.11.0

/test pull-kubevirt-e2e-k8s-1.11.0

/test pull-kubevirt-e2e-os-3.11.0-crio

/test pull-kubevirt-e2e-os-3.11.0-multus

/test pull-kubevirt-e2e-k8s-1.13.3

/test pull-kubevirt-e2e-k8s-1.11.0

/test pull-kubevirt-e2e-os-3.11.0-crio

/test pull-kubevirt-e2e-k8s-1.13.3

/test pull-kubevirt-e2e-os-3.11.0

/retest

@qinqon @booxter and @fedepaol are from the network team @cynepco3hahue

/test pull-kubevirt-e2e-k8s-genie-1.11.1

@phoracek Please run make generate and re-commit

@cynepco3hahue done

/lgtm

/approve

/hold cancel

/test pull-kubevirt-e2e-k8s-1.11.0

/test pull-kubevirt-e2e-os-3.11.0-crio

/retest

/retest

/retest

/retest

/test pull-kubevirt-e2e-k8s-1.13.3

/test pull-kubevirt-e2e-os-3.11.0-crio

/lgtm
/approve


crude and simple tool for building vocabularies from proto files.

for review only *

This builds on the vocabulary work by creating vocabulary structures for .proto files. Several things were copied-and-pasted from metrics/vocabulary because they had private scope and couldn't be used outside the package. We should either make those fields public or put the proto vocabulary generation in the vocabulary package (my concern about that is that it adds a dependency on go-protoparser).
To try it, build proto-vocabulary  and run it on a directory of protos with
% proto-vocabulary --path <path to directory containing protos>

or on a single proto with
% proto-vocabulary --proto <path to proto>

It will produce a single csv file, vocabulary.csv.

This has been merged into another project, to-be-released soon. I'll close this when that becomes available.

Vocabulary analysis for protos is now available in https://github.com/apigee/registry.


Add disconnected solution space optimization support

Using the paramspace module it is possible to create multiple minimization problems by analyzing each disconnected space generated.  Tasks:

Possibly create different search spaces to optimize;
Excluded arguments would create this multiple spaces;
Validate if number of agents is sufficient;

Implemented in commit 4510843ebc64cd3f0a15aa339cbb134e3e9363e5. Closing.


Transport: add Streams/Sinks for zmq_mio::Socket

Hi! I found a bug with the basic futures, and in fixing that, the trail took me to implementing a couple of new traits for sending and receiving, which made creating streams & sinks quite easy.
Please refer to the changelog for a description of what was done.
I think there are some missing docs remaining, so please let me know if you find any glitches or have any comments. Thanks!

What's the status of this PR? I'm assuming that @rotty hasn't had time to maintain this crate in recent months

The status: don't waste your time on this crate.

@cetra3 I've had a good experience using this crate: https://github.com/asonix/tokio-zmq

That crate is the GPL which means it's a bit prohibitive to use it


[BUG]: Subscribe Tag API only work when the sender is the author of the tag

Describe the bug
Subscribe Tag API only work when the sender is the author of the tag
Expected behavior
The Subscribe Tag API should work even the sender is not the Tag's author. (We'll add more security to this API later)

Implemented in #40