[5103] Set/recalculate trainee's academic cycles within Trainee instead of background job

Context
https://trello.com/c/4qdPXFjm/5103-investigate-why-the-end-academic-year-is-incorrect-for-trainees
We started to see some trainees with incorrect academic end years. After an investigation, it was postulated that because the academic years were updated using a background job in various places, it's possible that either the job failed or it was never executed during a manual update.
To ensure the academic years is always correct, we have decided to move this calculation into the Trainee's model and executed after every save.
Changes proposed in this pull request

Remove Trainees::SetAcademicCyclesJob
Add Trainees::SetAcademicCycles to Trainee model under a before_save callback
Update tests to work around this new approach

Guidance to review
Important business

[ ] Does this PR introduce any PII fields that need to be overwritten or deleted in db/scripts/sanitise.sql?
[ ] Does this PR change the database schema? If so, have you updated the config/analytics.yml file and considered whether you need to send 'import_entity' events?
[ ] Do we need to send any updates to DQT as part of the work in this PR?
[ ] Does this PR need an ADR?

NB: Please notify the #twd_data_insights team and ask for a review if new fields are being added to analytics.yml

 Investigate why the end academic year is incorrect for trainees


customVerificationCallback is executed only once

I can only get the client certificate for the first request. Upon repeated browser refreshes I can't get the client certificate. I expect the customVerificationCallback function be called on every request. Is it not supposed to do that? If so, how can I get client certificate on every request?
Here is my code,
           .channelInitializer { channel in
                let ssl_handler = NIOSSLServerHandler(
                        context: sslContext,
                        customVerificationCallback: { cert, promise in
                            let cert = cert[0]
                            print("in customVerificationCallback")
                            promise.succeed(.certificateVerified)
                        }

I only get to see in customVerificationCallback once. If I keep refreshing the browser, it's not showing up. An equivalent code in Node.js gives me a client certificate on every refresh.
I will also try repeatedly with curl.

TLS handshakes occur once per connection, not per request. The certificate chains cannot change from one request to the next on the same connection. Because TLS is more general than just HTTP, swift-nio-ssl talks in terms of TLS, so it doesn't re-call this callback, and the callback isn't really intended as a general-purpose method for extracting the certificates.
The answer to your general question is that you need to save the certificates when the connection is constructed.
I'll note that SwiftNIO is not a direct comparison to NodeJS: it's substantially lower level, more equivalent to the internal libraries of NodeJS than to Node itself. It may be worth investigating a tool like Vapor or Hummingbird, rather than using SwiftNIO directly.

I have solved it on my end by adding Connection: close header in HTTP response. For reasons to be covered by a patent, I can't disclose what exactly I am doing.


Nuxt usage

I tried to use this as plugin in Nuxt.
I have created currency.js under plugins/ folder.
// plugins/currency.js

import VueCurrencyFilter from 'vue-currency-filter'
import Vue from 'vue'

Vue.use(VueCurrencyFilter)

and include the script in nuxt.config.js
// nuxt.config.js

module.exports = {
    plugins: [
        { src: '~/plugins/currency.js', ssr: false }
    ]
}

and inside my component at components/ProductCard.vue
// components/ProductCard.vue
<template>
    <h4>{{ price | currency }}</h4>
</template>
<script>
    import currency from '~/plugins/currency.js'

    export default {
        ...
    }
</script>

This resulted error as below
[Vue warn]: Failed to resolve filter: currency

(found in <ProductCard> at components/ProductCard.vue)

Any workaround how to use this on Nuxt?

Can you try to clone and run in your local this sample project https://github.com/mazipan/nuxt-blog ?
I have test it, and okay.

I get exactly the same error, any updates on this one?

my environment
Nuxt.js @ v2.14.6
I change
{ src: '~/plugins/currency', ssr: true } <--change to true
and everything works


Update ContainerServiceApiImplementation with getByTag

Changed

Updated ContainerInstanceServiceApi with getByTag.

Codecov Report

Merging #198 (23a3e84) into master (77056c8) will increase coverage by 3.05%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master     #198      +/-   ##
==========================================
+ Coverage   95.82%   98.88%   +3.05%
==========================================
  Files         112       22      -90
  Lines        1726      359    -1367
  Branches      235       55     -180
==========================================
- Hits         1654      355    -1299
+ Misses         70        4      -66
+ Partials        2        0       -2

Flag
Coverage Δ

cuaktask
99.17% <ø> (ø)

iocuak
?

porygon
98.30% <ø> (ø)

porygon-typeorm
?

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

.../services/api/ContainerServiceApiImplementation.ts

...a/services/domain/MetadataServiceImplementation.ts

...ask/modules/cuaktask/CreateInstanceTaskLazyNode.ts

...s/iocuak/src/binding/models/domain/BindingScope.ts

...eTask/models/domain/ContainerModuleTaskKindType.ts

...s/iocuak/src/classMetadata/decorators/injectTag.ts

...rud/modules/iocuak/TypeOrmUpdateContainerModule.ts

...ng/services/domain/BindingServiceImplementation.ts

...ages/iocuak/src/classMetadata/decorators/inject.ts

...sMetadata/models/api/ClassElementMetadatApiType.ts

... and 80 more

Continue to review full report at Codecov.

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


Head metadata .xml makes reference to downloaded tile only.

Hi,
I will post my question as a new issue, although I had initially replied to a closed post from Safalabolo:
Safalabolo:
"Unfortunately, the processing by SEN2COR of granule downloaded fails, contrary to what happens for the same granule selected from the entire acquisition (zip file) downloaded via a simple download manager."
Your answer: "I will modify the downloader to produce the same structure, with dummy files, so that Sen2Cor will process them."
The head .xml metadata file still doesn't match the same structure as it does would you download it from the esa hub directly. It's fine if you download only one tile and do the sen2cor and subsequent processing on that one and single tile, but if you download one tile, and then some time later another one of that same image, the .SAFE folder will be completed by the new granule(s), but the head metadata .xml file will be replaced by a metadata file referring to that new tile only. What you refer to as the "dummies" should be there to mimic the structure of the scihub data.
I am trying to see what needs be done in your code, but I am unfortunately not too handy in java.
Thanks for the effort in all cases and hope to hear back soon.

It would be enough to put the two tile ids as argument of --tiles parameter. The already downloaded one will not be downloaded again, the second one will be downloaded and the product metadata will reflect both.

As you mentioned, the new granules are downloaded and the already downloaded one remains as it is, but the general metadata .xml is not updated with the newly downloaded tiles and still only refers to the single tile which I had previously downloaded, meaning that only that tile shows when opened in SNAP or any other software.
For the S-2 images which are newly downloaded (i.e. no previous tiles of that same image had been downloaded before), the general metadata .xml is created conform to the number of tiles referred to in the argument --tiles, which is great. However, the "updating" seems to be the issue if part of the image was previously downloaded in another instance. I have hundreds of images, and looking through all of them to see which .xml files are incorrect/corrupted would take forever.
Looking for a smooth solution, but if there is no such thing I will do it the hard way, can't be that bad :)
Thanks in advance,
William

What if you supply all the tileIDs you need for a product for which you have previously downloaded just a part of its tiles?
For example, if you have previously download product X with only the tile 35JMK, next time you try with the same product X with the tiles 35JMK and 35JML.
Normally, with the latest version from Git, the product metadata should be overwritten each time.

I got the latest version from git, but now get the following error after packaging and assembling as described:
Exception in thread "main" java.lang.NullPointerException
at java.util.Properties$LineReader.readLine(Properties.java:434)
at java.util.Properties.load0(Properties.java:353)
at java.util.Properties.load(Properties.java:341)
at ro.cs.products.ProductDownloader.(ProductDownloader.java:61)
at ro.cs.products.sentinel2.SentinelProductDownloader.(SentinelProductDownloader.java:87)
at ro.cs.products.Main.main(Main.java:428)
The command line I use is the following:
java -jar /home/s_admin/awsdownload/target/ProductDownload-bin/ProductDownload/ProductDownload.jar --sensor S2 -o /nas --relative.orbit 51 --tiles 31UDT 31UDS 31UET 31UES 31UER 31UFT 31UFS 31UFR 31UFQ 31UGS 31UGR -l 1000 --startdate 2015-01-01 --cloudpercentage 80 --store AWS --user ****** --password *****

I have a feeling it is not accepting a linux syntax for the output folder: "--out /nas"

I've traced the error up to ProductDownloader.java, where it seems to have issues reading the "download.properties" file. But it's weird because if the resource read was indeed Null, then an error should be thrown and printed as indicated by the "Catch (IOException e)" line, but instead i get this NullPointerException in "Main".
Just trying to give some hints to where the problem could come from based on what I could find online, but still can't seem to find a solution.

The last commit solved the issue.
Cheers

Glad to hear J
Cheers.
From: wouellette<EMAIL_ADDRESS>Sent: Friday, November 18, 2016 4:07 PM
To: kraftek/awsdownload<EMAIL_ADDRESS>Cc: Cosmin Cara<EMAIL_ADDRESS>Comment<EMAIL_ADDRESS>Subject: Re: [kraftek/awsdownload] Head metadata .xml makes reference to downloaded tile only. (#5)
The last commit solved the issue.
Cheers
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub https://github.com/kraftek/awsdownload/issues/5#issuecomment-261539190 , or mute the thread https://github.com/notifications/unsubscribe-auth/AHQBsNfEfgSJRMacGuv4YQRpqWKWnA0cks5q_bDsgaJpZM4KLEt_ .  https://github.com/notifications/beacon/AHQBsMl-Z1JIJN0xCZEzvhn4BdQPwIxeks5q_bDsgaJpZM4KLEt_.gif


nixos/systemd-repart: add assertion for partition label length

Description of changes
The maximum length for a GPT label supported by systemd is 36 characters. When a repart definition contains a label that is longer than the supported maximum length, it is ignored by systemd-repart and a log message is produced.
The new assertion makes this obvious to the user at evaluation time, allowing them to either drop the property entirely or choose a supported label within the length limit instead.
Related upstream PR:
https://github.com/systemd/systemd/pull/19581
Things done

Built on platform(s)

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

For non-Linux: Is sandboxing enabled in nix.conf? (See Nix manual)

[ ] sandbox = relaxed
[ ] sandbox = true

[x] Tested, as applicable:

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

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

[ ] (Package updates) Added a release notes entry if the change is major or breaking
[ ] (Module updates) Added a release notes entry if the change is significant
[ ] (Module addition) Added a release notes entry if adding a new NixOS module

[x] Fits CONTRIBUTING.md.

@ofborg test systemd-repart appliance-repart-image


Urgent fix needed - School admin users are not authorised to access the page accessed from Choose an Activity

Urgent fix needed - School admin users are not authorised to access the page accessed from clicking on Choose an Activity from their school home page. The link works fine when I am logged in as an Admin user, but not when logged in as a School Admin user. I have been alerted to the problem by the Head of Pensford primary  who was testing out the site.

I will fix this today, but won't be able to do a new release until late this evening.


GridStat and other wrappers set input dir to OUTPUT_BASE if not set

This should be set to an empty string if not set so the user can define the entire input path using the input template variable.
Describe the Enhancement
Go through each wrapper and make sure the default value for *_INPUT_DIR is an empty string and not OUTPUT_BASE.
Time Estimate
~ 1 day
Sub-Issues
Consider breaking the enhancement down into sub-issues.

[X] Add a checkbox for each sub-issue here.

Relevant Deadlines
None
Funding Source
None
Define the Metadata
Assignee

[x] Select engineer(s) or no engineer required
[x] Select scientist(s) or no scientist required

Labels

[x] Select component(s)
[x] Select priority
[x] Select requestor(s)

Projects and Milestone

[x] Review projects and select relevant Repository and Organization ones
[x] Select milestone

Define Related Issue(s)
Consider the impact to the other METplus components.

[x] METplus, MET, METdb, METviewer, METexpress, METcalcpy, METplotpy

Enhancement Checklist
See the METplus Workflow for details.

[x] Complete the issue definition above.
[ ] Fork this repository or create a branch of develop.
Branch name:  feature_<Issue Number>_<Description>
[ ] Complete the development and test your changes.
[ ] Add/update unit tests.
[ ] Add/update documentation.
[ ] Push local changes to GitHub.
[ ] Submit a pull request to merge into develop.
Pull request: feature <Issue Number> <Description>
[ ] Iterate until the reviewer(s) accept and merge your changes.
[ ] Delete your fork or branch.
[ ] Close this issue.

First step. OUTPUT_BASE is not set to INPUT_BASE anywhere
grep -r "OUTPUT_BASE =" * and
grep -r "OUTPUT_BASE=" *
show that only internal_tests have OUTPUT_BASE set to something explicit

Sorry, there was a typo in the initial comment. _INPUT_DIR is set to OUTPUT_BASE by default when it should be set to an empty string so the full path to input data can be defined in the corresponding _INPUT_TEMPLATE. For example, currently we have:
        c_dict['FCST_INPUT_DIR'] = \
          self.config.getdir('FCST_GRID_STAT_INPUT_DIR', self.config.getdir('OUTPUT_BASE'))
        c_dict['FCST_INPUT_TEMPLATE'] = \
          self.config.getraw('filename_templates',
                             'FCST_GRID_STAT_INPUT_TEMPLATE')

The _INPUT_TEMPLATE is required and we tell users that the _INPUT_DIR is optional so you can put the full path in _INPUT_TEMPLATE. The way the above code works now, if you do that, then the path will be {OUTPUT_BASE}/some/full/path/to/input/data/filename.txt, when the intended path should be /some/full/path/to/input/data/filename.txt. It should look like this:
        c_dict['FCST_INPUT_DIR'] = \
          self.config.getdir('FCST_GRID_STAT_INPUT_DIR',
                             '')
        c_dict['FCST_INPUT_TEMPLATE'] = \
          self.config.getraw('filename_templates',
                             'FCST_GRID_STAT_INPUT_TEMPLATE')
        if not c_dict['FCST_INPUT_TEMPLATE']:
            self.log_error("FCST_GRID_STAT_INPUT_TEMPLATE is required to run")

getraw returns an empty string if it is not found, so we also need to check that it is set because it is required. If it is not set, then we call log_error and the initialization of the wrapper will fail. (A recent change I made in a branch sets self.isOK = False inside log_error, so you no longer need to explicitly set it to False if an error is found in the create_c_dict function).


Support RPM packages with different names than the crate name

Solves https://github.com/RustRPM/cargo-rpm/issues/51.
Adds a --package to the cargo rpm init command to set this variable.
It's also added to Cargo.toml as package.metadata.rpm.package.

I successfully tested this for my https://github.com/stevenroose/hal/ crate.

Looks good, thanks!


[localize] Escape markup characters when generating HTML text content

Fixes a bug where we were not escaping <, >, and & characters to HTML entities when generating HTML text content in both runtime and transform mode.
cc @fetherston

Tests and fix make sense to me! Thanks for putting this together 🚀


node / jest-cli / homepage slightly out of sync

The homepage at http://facebook.github.io/jest/ says at one step, "Run npm install jest-cli --save-dev"
When I tried to run it, with node 0.12.0 and NPM recently built from source, something seemed to be out of sync:
<EMAIL_ADDRESS>npm install jest-cli --save-dev
npm WARN engine<EMAIL_ADDRESS>wanted: {"node":"0.8.x || 0.10.x"} (current: {"node":"0.12.0","npm":"2.5.1"})

Could jest-cli be updated to accept current Node installation?
Thanks,

jest has some problems with 0.12 so for the time being that node preferred version checking is actually a good thing. We're tracking that in #243.

Sorry for the trouble; thanks for the note!


\Zend\Mail\Header\HeaderValue should support unicode characters

The isValid method doesn't support unicode characters in the header value. This is a problem for example when unicode email address is given. (eg<EMAIL_ADDRESS>- which is a valid email address)
Unicode email addresses cause Zend\Mail\Header\Exception\RuntimeException in vendor\zendframework\zend-mail\src\Header\HeaderValue.php:115
Exception message: Invalid header value detected.

This issue has been moved from the zendframework repository as part of the bug migration program as outlined here - http://framework.zend.com/blog/2016-04-11-issue-closures.html
New issue can be found at: https://github.com/zendframework/zend-mail/issues/96


Ebpf Netsh API should be able to get max instruction count about an eBPF program

Ebpf Netsh API should be able to get stats about an eBPF program
A developer must be able to get statistics (e.g., size, max instruction count, etc.) about an eBPF program without running it.

Many statistics are already available about eBPF programs without running it (e.g., size, etc.), which can be seen via
netsh ebpf show sections bindmonitor.o level=verbose for instance.
max instruction count is not yet visible, hence the rename of the issue.

https://github.com/vbpf/ebpf-verifier/pull/232 tracks exposing the info from the verifier.


Issue launching outside of us-west-2

I believe there is an issue launching outside of us-west-2.  In this case I'm attempting to launch in us-east-1
I tried:

downloading the template yaml and uploading it
looking through the temlate yaml for any mention of us-west, there is none.

I believe it is this reference to a bucket which may be in us-west?  Hard to tell: CodeUri: s3://shhorsfi-sam-deploy/76821eb711355c29fff055f33b33a153
Error when creating DataSinkTerminationEnrichmentFunction:
Error occurred while GetObject. S3 Error Code: PermanentRedirect. S3 Error Message: The bucket is in this region: us-west-2. Please use this region to retry the request (Service: AWSLambdaInternal; Status Code: 400; Error Code: InvalidParameterValueException; Request ID: 5f7b61d8-7631-4376-9b7b-f98f6a7494e2; Proxy: null)

I tried to capture that code to put in a bucket of my own but seemingly don't have access:
aws s3 cp s3://shhorsfi-sam-deploy/76821eb711355c29fff055f33b33a153 -
download failed: s3://shhorsfi-sam-deploy/76821eb711355c29fff055f33b33a153 to - An error occurred (403) when calling the HeadObject operation: Forbidden

oh geez the source is right here in this repo! 🤦 .  will try that

Dan thanks for reporting this. I’ll need to setup a new bucket for the one click deployment. Until then as you mentioned, you’ll need to compile from source with SAM.


fix build error

fix error when building , the error is " undefined reference to `leveldb::ConcurrentTest::K"

Thank you for your contribution!
A similar fix was just published from our internal repository -- https://github.com/google/leveldb/commit/23d67e7c1f4396919bd0c73c0eced13a0dac37f3


doesnt play well with pjax

basicly the lib doesnt get the chance to construct its dom structure &
select.selectpicker {
    display: none!important;
}

doesn't get disabled, so the original select stays hidden.

nvm, thats because non of the js gets reloaded so the lib never fires.


added option to specify height in lines of the window

Exactly what it sounds like. You can now specify how many lines the harpoon window should have.
What is my use-case for this?
I want to be able to use more than 8 lines and want to see them all at once. I like to use 10, so I gave a general option for it.

Fine

thanks brother 🔥🔥💯💯💯💯


Add support for JSON patch customizations of the ECSTask task run payload

Summary

This exposes customizations of the payload for ECS task runs, allowing users to set fields not available at the top level or override any of the options that Prefect sets.
We follow the JSON Patch customizations pattern used in the core library for Kubernetes. Tests and examples have been added for the current user requests. Future requests can be followed with new documentation examples, as patches can be challenging to write at times.
Relevant Issue(s)

Closes https://github.com/PrefectHQ/prefect-aws/issues/115
Closes https://github.com/PrefectHQ/prefect-aws/issues/113
Closes https://github.com/PrefectHQ/prefect-aws/issues/112
Checklist

[x] Summarized PR's changes in the Unreleased section of the CHANGELOG.md

Note I have not done QA of this feature against a live ECS cluster. cc @anna-geller ?


OCPBUGS-3630: deployment: enforce recreate strategy to avoid conflicts during upgrades

As per the upstream update: https://github.com/kubernetes-sigs/external-dns/pull/2772. ExternalDNS is currently unable of handling multiple parallel instances (no leader election implemented). This may result into split brain situation during the rolling upgrades.

Azure cluster install failure.
/retest

/label qe-approved

/assign

On hold until comments addressed
/hold

Cluster installation failed.
/test e2e-infoblox-operator

Back-off pulling image "registry.redhat.io/redhat/redhat-marketplace-index:v4.12"

One of the OLM catalog images is missing, again...
/retest

/remove-lifecycle stale

/remove-lifecycle stale

/unhold
/lgtm

Rebased from main, new test added for SharedVPC support had to be adopted.

/retest-required

/jira refresh

/jira refresh

/jira refresh

/lgtm
/approve


WIP,MNT: Add support for qtpy

This PR adds support for qtpy which allows us to become Qt-agnostic. This can eventually make the transition to Qt6 easier.
Related to https://github.com/mne-tools/mne-python/issues/9710#issuecomment-1063371893

As I explain in https://github.com/mne-tools/mne-python/issues/9710#issuecomment-1063942500, the resource system needs some rework to allow Qt6 support.

Although there is no pyrcc6, pyside6-rcc does exist:
https://doc.qt.io/qtforpython/tutorials/basictutorial/qrcfiles.html
So I think we could migrate to PySide6 easily but for the sake of being Qt-agnostic, I still plan to rework the resource system.

Could we just load the PNGs directly?

@larsoner feel free to take a look at the code. This did the trick to me for PySide6, I'll try with PyQt6 next.

Could we just load the PNGs/SVGs directly?

Definitely, but I think we need to be smart here because a relative path won't do. I chose importlib.resources and found that it worked quite well. I just refactored _init_qt_resources().
Of course, the PR is not ready, I tried Brain and coreg mainly.

There are still many places in the project where PyQt5 is used or referred to directly:

.circleci/config.yml:            name: Check PyQt5
.circleci/config.yml:            command: LD_DEBUG=libs python -c "from PyQt5.QtWidgets import QApplication, QWidget; app = QApplication([])"
doc/install/mne_python.rst:    PyQt5:         5.14.1
mne/conftest.py:    # Check PyQt5
mne/conftest.py:        import PyQt5  # noqa: F401
mne/conftest.py:        pytest.skip('PyQt5 is not installed but needed for pyqtgraph!')
mne/conftest.py:        pytest.skip(f'PyQt5 has version {_check_pyqt5_version()}'
mne/conftest.py:        pytest.skip("Test skipped, requires PyQt5.")
mne/conftest.py:    from PyQt5.QtWidgets import QApplication, QMainWindow
mne/gui/__init__.py:    from PyQt5.QtWidgets import QApplication
mne/gui/__init__.py:        from PyQt5 import QtGui
mne/gui/_ieeg_locate_gui.py:from PyQt5 import QtCore, QtGui, Qt
mne/gui/_ieeg_locate_gui.py:from PyQt5.QtCore import pyqtSlot
mne/gui/_ieeg_locate_gui.py:from PyQt5.QtWidgets import (QMainWindow, QGridLayout,
mne/utils/check.py:        from PyQt5.Qt import PYQT_VERSION_STR as version
mne/utils/check.py:        warn('macOS users should use PyQt5 >= 5.10 for GUIs, got %s. '
mne/utils/check.py:             '    pip install "PyQt5>=5.10,<5.14"\n'
mne/utils/config.py:        PyQt5:         5.15.0
mne/utils/config.py:                     'PyQt5', 'ipympl', 'pooch', '', 'mne_bids', 'mne_nirs',
mne/utils/config.py:            elif mod_name == 'PyQt5':
mne/viz/_scraper.py:        from PyQt5.QtWidgets import QApplication
mne/viz/backends/tests/_utils.py:    """Check if PyQt5 is installed."""
mne/viz/backends/tests/_utils.py:        import PyQt5  # noqa: F401
mne/viz/raw.py:    fig : matplotlib.figure.Figure | ``PyQt5.QtWidgets.QMainWindow``
mne/viz/utils.py:    """Protect against PyQt5 exiting on event-handling errors."""
mne/viz/utils.py:        from PyQt5.QtWidgets import QApplication
tools/azure_dependencies.sh:    python -m pip install --progress-bar off --upgrade --pre --only-binary ":all:" --no-deps --extra-index-url https://www.riverbankcomputing.com/pypi/simple PyQt5 PyQt5-sip PyQt5-Qt5
tools/circleci_dependencies.sh:echo "Working around PyQt5 bugs"
tools/github_actions_dependencies.sh:   echo "PyQt5"
tools/github_actions_dependencies.sh:   pip install $STD_ARGS --pre --only-binary ":all:" --no-deps --extra-index-url https://www.riverbankcomputing.com/pypi/simple PyQt5 PyQt5-sip PyQt5-Qt5

As a first step let's make the only change CIs just to add qtpy to the CI requirements, keeping PyQt5 as the lib that actually gets installed. Then this PR's purpose can be to remove PyQt5 uses in our code in favor of some pyqt abstraction. Once that's green we can merge.
Then the next PR can be to improve CIs by adding PySide2 / PySide 6 / PyQt6 runs -- this will require a bit of work and thinking as we probably only want to test things that use our new abstraction (Brain, iEEG GUI, etc.). The easiest way to do this is maybe by making a pytest.mark.qt or so to signify that it's a Qt test, then we can pytest -m qt in these (hopefully quick) framework-only CI runs. Or maybe we get this for free by using something like pytest-qt with a qtbot fixture, in which case we should just add it to the appropriate set of tests and use it.

Also I think there is no hurry. I jumped on this because I am interested but I can wait for the release.

Agreed we should merge this right after release. So actually if the qtpy abstraction is quick and some commit is green before release, it's okay to roll the CI changes into this PR, too. It will be obvious what CIs and infrastructure have been added to make it work I think.

At the time I made the switch, QtPy did not support Qt6, around a year after Qt6 had been released. I mainly wanted to upgrade to Qt6 because I found a bug in Qt5's font rendering (which looked really bad).
Moreover, PySide6 is the official Python package from Qt. Besides some nice features (which I currently don't use, but snake case names is tempting), it is licensed under the LGPL as opposed to PyQt6's GPL. I don't think that this prohibits PyQt6 from using together with BSD/MIT-style licenses, but LGPL is definitely less restrictive. PySide6 is available for all three platforms as binary wheels on PyPI. For these reasons, I didn't see the necessity to (1) support PyQt6 and (2) introduce yet another layer of abstraction (QtPy).
So far, I'm quite happy with the transition. To be honest, not that much changed since Qt seems to be in maintenance mode anyway (they seem to focus on QtQuick instead), but at least they still support PySide6 officially and fix bugs.

Also, regarding loading icons, I load SVGs directly (using a theme) in MNELAB, e.g. https://github.com/cbrnr/mnelab/blob/main/mnelab/mainwindow.py#L80
I'd be happy to discuss all Qt-related things with you – we'd probably both benefit a lot from each other because each of us has already solved different problems with Qt.

Thanks for chiming in @hoechenberger, @cbrnr, your feedback is appreciated :)
Personally, I am interested in qtpy because I want to offer the flexibility to choose whatever Qt api you want/like/use but maybe not the majority of mne-python users or devs care about this matter at all. After all, mne-python sticks to PyQt5 for a while now but I am not sure if it's really by choice considering how sometimes it's difficult to migrate to another API. At least, this PR makes it easier to switch, especially in the long run.

So far, I'm quite happy with the transition.

From another perspective, maybe the transition was not painful because you were using qtpy in the first place? :thinking:

PySide6 is the official Python package from Qt
PySide6 is available for all three platforms as binary wheels on PyPI

Those are all good points, that's why I am not opposed to choose PySide6 by default for example.

yet another layer of abstraction (QtPy)

In my opinion, this is a small layer and very comfortable to use as a dev :sweat_smile:
This is just my opinion but of course there are also considerations about licensing and maintenance cost for the project. I'll be happy to help no matter what we decide.

I load SVGs directly (using a theme)

I'll take a look right away! :star_struck:

Personally, I am interested in qtpy because I want to offer the flexibility to choose whatever Qt api you want/like/use but maybe not the majority of mne-python users or devs care about this matter at all. After all, mne-python sticks to PyQt5 for a while now but I am not sure if it's really by choice considering how sometimes it's difficult to migrate to another API. At least, this PR makes it easier to switch, especially in the long run.

I agree, I think almost no one will care whether the GUI uses PySide6 or PyQt6. Having said that, there is not really any reason why one would choose PyQt6 over PySide6, so we might as well decide to stick with PySide6 in the future. All the other choices offered via QtPy are older versions of Qt, and I'm not sure why we should keep supporting those.

From another perspective, maybe the transition was not painful because you were using qtpy in the first place? 🤔

Maybe. It's basically just replacing qtpy with PySide6 in the imports.

Those are all good points, that's why I am not opposed to choose PySide6 by default for example.

I think this would indeed be a sensible choice.

In my opinion, this is a small layer and very comfortable to use as a dev 😅

It is, yes, but if there is no real benefit then I'd rather not use it, no matter how small it is. The more you add, the more potential issues you will encounter at some point.

Good idea to discuss the resource system in a separate PR. I'd switch to PySide6 directly (i.e. without QtPy) – but this means that there needs to be a pyside6 package in conda-forge before the next release, right?

Maybe so. For reference: https://github.com/conda-forge/qt-main-feedstock/pull/14

I don't think we need to wait for conda forge to have a package to prefer it internally (as long as we can nicely fall back to PyQt6/5). People who use pip will still get the benefits, and we're ready whenever conda comes around. So I say keep going @GuillaumeFavelier !

I can continue working on this and switch from PyQt5 to PySide6 of course. But is that okay for environment.yml and mne-installers ? I might have to rely on pip if the package is not available on conda-forge.

as long as we can nicely fall back to PyQt6/5

I'm not sure to understand what you mean

Sorry, I missed the arguments against qtpy above. I think they are mostly not relevant for us and that we should transition to qtpy rather than plain PySide6. In addition to allowing PyQt5/PyQt6/PySide2/PySide6 already now (right?), if there is ever a PySide7/QtPy7, it will probably reduce the transition pain. To me it's the easiest, most compatible option. The only real downside is that we can't make a quick transition to PySide7 or something later, but we (MNE) never go to the latest-and-greatest right away -- our requirements tend to support things to 2 years back as much as possible.

but we (MNE) never go to the latest-and-greatest right away

sad noises 😭

provided that there's a conda-forge package of PySide6, there is no reason to support PyQt5/PyQt6/PySide2 anymore.

I disagree, we don't want to force people to update, even if an update is available on all platforms.

Yes, I don't see the point in maintaining old versions. Qt6 has been released 15 months ago and we're still OK with people using the old Qt5? Issues will only be fixed in Qt6, e.g. the font rendering bug is here to stay in Qt5. So once the conda-forge package is out I really don't understand why we don't want to force people to upgrade. For me, it is already annoying to support anything else other than PySide6.
But OK, if you disagree I'm also fine with adding QtPy - but keep in mind this is yet another package we're adding to our dependency pile.

Qt6 has been released 15 months ago and we're still OK with people using the old Qt5?

Yes, upgrades often cause problems. Even for me as an experienced dev, I tried testing mnelab recently and it required PySide6, but installing this broke PyVistaQt. I couldn't have both installed at once. Things like this are not uncommon.
We have a standard policy of supporting libraries 2 years out (as much as possible), and in this case, Qt6 hasn't been available directly via conda (our preferred installation method) at all yet, so even though PySide6 has been out 15 months, I would vote for considering the 2-year clock to have not started yet on this library (!).

For me, it is already annoying to support anything else other than PySide6.

I think if we go the qtpy route, it will minimize our pain. And I think we need to do it for our users.

keep in mind this is yet another package we're adding to our dependency pile.

Agreed it's sad to add another dependency, but here I think it's a necessary evil.
Let's move on with qtpy.

Thank you everyone for taking the time to interact in here. All your suggestions are valuable so I'll do my best to converge to something satifisfying :+1:

Considering the latest comments, this is what I suggest:

I will update this PR to 'Add support to QtPy'
Then I will open an issue about the choice of the default Qt API

At the moment, I am busy working on Qt resource management (icon & them) but once this is taken care of, I'll go back on this.
Sorry for the noise, I think I miscalculated how ambitious this PR would be :pray:

Hello, I just wanted to chime in again and say that I've discussed this issue with @GuillaumeFavelier personally last weekend, and I now also agree that we should probably go with QtPy. It seems to be the most sustainable option in terms of future maintenance work.

Locally, I was able to try coreg and plot_stc on c2b4f7eb9016d382a5e1e43af9a554c9cb1c1a7b with PySide6 and PyQt6 and it works as I would expect. I did not find any bug for now.
When the window closes I do see the following in the log:
qt.qpa.xcb: QXcbConnection: XCB error: 3 (BadWindow), sequence: 5660, resource id: 15444581, major code: 40 (TranslateCoords), minor code: 0

I reverted c2b4f7e right away because I don't think we want to change [the Qt version pinning] now

Sure, seems reasonable to move to qtpy first but keep using PyQt5 everywhere as far as our requirements.txt and environment.yml go.
In this PR or a follow-up one, we could add a CI job that runs GUI + viz tests (only, for speed) with a matrix of PyQt5, PyQt6, PySide2, and PySide6 (probably all just on linux, again for speed?). WDYT?
Then separately we can look to see if we can fix HiDPI on macOS. Once that works, we can deal with environment.yml and requirements.txt. This can all land in 1.1 so that we have months to sort it out.

I think this goes in pair with environment.yml and requirements.txt because it's very messy to test with multiple APIs installed or we need to hack something in the job itself to ensure there is only one.

There are already places we give complete, separate specs of what to install, like https://github.com/mne-tools/mne-python/blob/main/tools/azure_dependencies.sh and the GH actions equivalent. I would "just" add a new else if clause in those with some QT_API arg. Then we define the QT_API arg in some tests.
Should I give it a shot in this PR? I'm thinking Azure probably has the lightest load currently... actually I'd probably try reenabling appveyor since I think it does still work but we don't use it. We could even test Ubuntu and Windows if we wanted, but I'd probably just do half on one and half on the other for now.

Should I give it a shot in this PR?

If you want, I just pushed so I'm okay with it.

@GuillaumeFavelier should we merge https://github.com/mne-tools/mne-python/pull/10495 once it's ready, then rebase/merge-with-main in this PR?

The Test Qt job skips some tests while testing PyQt6 and PySide2:
mne/viz/_brain/tests/test_brain.py::test_layered_mesh[pyvistaqt] SKIPPED (Test skipped, requires pyvistaqt) [  2%]
mne/viz/_brain/tests/test_brain.py::test_single_hemi[pyvistaqt-lh] SKIPPED (Test skipped, requires pyvistaqt) [  5%]
mne/viz/_brain/tests/test_brain.py::test_single_hemi[pyvistaqt-rh] SKIPPED (Test skipped, requires pyvistaqt) [  8%]
mne/viz/_brain/tests/test_brain.py::test_brain_screenshot[pyvistaqt] SKIPPED (Test skipped, requires pyvistaqt) [ 11%]
mne/viz/_brain/tests/test_brain.py::test_foci_mapping[pyvistaqt] SKIPPED (Test skipped, requires pyvistaqt) [ 14%]
mne/viz/_brain/tests/test_brain.py::test_brain_gc[pyvistaqt] SKIPPED (Test skipped, requires pyvistaqt) [ 17%]
mne/viz/_brain/tests/test_brain.py::test_brain_routines[pyvistaqt] SKIPPED (Test skipped, requires pyvistaqt) [ 20%]
...

And the  PySide2 section of mne sys_info does not find pyvistaqt:

Platform:            Linux-5.13.0-1017-azure-x86_64-with-glibc2.31
Python:              3.10.4 (main, Mar 24 2022, 14:07:25) [GCC 9.4.0]
Executable:          /opt/hostedtoolcache/Python/3.10.4/x64/bin/python
CPU:                 x86_64: 2 cores
Memory:              6.8 GB

mne:                 1.1.dev0
                     •/home/vsts/work/1/s/mne
numpy:               1.21.5 {blas=openblas, lapack=openblas}
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/numpy
scipy:               1.8.0
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/scipy
matplotlib:          3.5.1 {backend=QtAgg}
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/matplotlib

sklearn:             1.0.2
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/sklearn
numba:               0.55.1
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/numba
nibabel:             3.2.2
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/nibabel
nilearn:             0.9.0
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/nilearn
dipy:                1.5.0
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/dipy
cupy:                Not found
pandas:              1.4.2
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/pandas
pyvista:             0.34.0 {OpenGL 4.5 (Core Profile) Mesa 21.2.6 via llvmpipe (LLVM 12.0.0, 256 bits)}
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/pyvista
pyvistaqt:           Not found
ipyvtklink:          0.2.2
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/ipyvtklink
vtk:                 9.1.0.rc1
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/vtkmodules
qtpy:                2.0.1 {PySide2=<IP_ADDRESS>}
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/qtpy
ipympl:              Not found
pooch:               v1.6.0
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/pooch

mne_bids:            Not found
mne_nirs:            Not found
mne_features:        Not found
mne_qt_browser:      0.2.6
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/mne_qt_browser
mne_connectivity:    Not found

sphinx:              4.5.0
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/sphinx
sphinx_gallery:      0.10.1
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/sphinx_gallery
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/pytest
nbclient:            0.5.13
                     •/opt/hostedtoolcache/Python/3.10.4/x64/lib/python3.10/site-packages/nbclient
qtpy:                2.0.1 {PySide2=<IP_ADDRESS>}

Good catch. Can you replicate locally?

Maybe we need the dev version of pyvistaqt / maybe it needs a new release with some of your fixes?

Can you replicate locally?

I'm on it!

I narrowed the issue down to:
# Check whether a specific PyQt implementation was chosen
try:
    import vtkmodules.qt
    PyQtImpl = vtkmodules.qt.PyQtImpl
except ImportError:
    pass

Somehow, vtkmodules.qt.PyQtImpl is still set to PyQt5 forcing pyvistaqt/rwi.py to load PyQt5 causing the error preventing pyvistaqt to be imported.

And all of this happens because PyQt6 is not officially supported in vtk yet...
I modified the following locally and it works:
# Has an implementation has been imported yet?
-for impl in ["PySide6", "PyQt5", "PySide2", "PyQt4", "PySide"]:
+for impl in ["PyQt6", "PySide6", "PyQt5", "PySide2", "PyQt4", "PySide"]:
    if impl in sys.modules:
        PyQtImpl = impl
        break

https://gitlab.kitware.com/vtk/vtk/-/blob/master/Wrapping/Python/vtkmodules/qt/__init__.py#L27-31

I guess I have to open this PR rather sooner than later :sweat_smile:
Meanwhile, do you think it's worth patching in pyvistaqt @larsoner ?

IIRC VTK 9.2 will already support PyQt6. I think it's supposed to come out in a month. So perhaps for now we should just omit the PyQt6 support / CI entry.
An option in the interim would be to get an updated pyvista wheel with 9.2dev that supports PyQt6. But it doesn't seem worth it.
So that covers PyQt6. Why isn't PySide2 working though?

IIRC VTK 9.2 will already support PyQt6

This is good to know, thank you for the info!

So that covers PyQt6. Why isn't PySide2 working though?

I will update the PR to disable PyQt6 testing then. I'll continue to investigate

I will update the PR to disable PyQt6 testing then.

On second thought, let's just leave the PyQt6 CI entry in here. It at least tests matplotlib, and eventually will get mne-qt-browser, then finally VTK. And the skips work in the meantime.
So I think all that is left to do is figure out PySide2...

For PySide2, the error is slightly different:
❯ python
Python 3.9.12 (main, Apr  5 2022, 06:56:58)
[GCC 7.5.0] :: Anaconda, Inc. on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import pyvistaqt
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/home/guillaume/source/anaconda3/envs/test/lib/python3.9/site-packages/pyvistaqt/__init__.py", line 31, in <module>
    from .plotting import BackgroundPlotter, MainWindow, MultiPlotter, QtInteractor
  File "/home/guillaume/source/anaconda3/envs/test/lib/python3.9/site-packages/shiboken2/files.dir/shibokensupport/__feature__.py", line 142, in _import
    return original_import(name, *args, **kwargs)
  File "/home/guillaume/source/anaconda3/envs/test/lib/python3.9/site-packages/pyvistaqt/plotting.py", line 76, in <module>
    from .rwi import QVTKRenderWindowInteractor
  File "/home/guillaume/source/anaconda3/envs/test/lib/python3.9/site-packages/shiboken2/files.dir/shibokensupport/__feature__.py", line 142, in _import
    return original_import(name, *args, **kwargs)
  File "/home/guillaume/source/anaconda3/envs/test/lib/python3.9/site-packages/pyvistaqt/rwi.py", line 143, in <module>
    from PyQt5.QtWidgets import QWidget
  File "/home/guillaume/source/anaconda3/envs/test/lib/python3.9/site-packages/shiboken2/files.dir/shibokensupport/__feature__.py", line 142, in _import
    return original_import(name, *args, **kwargs)
ModuleNotFoundError: No module named 'PyQt5.QtWidgets'
>>> from qtpy import API
>>> API
'pyside2'
>>>

This time, PySide2 is in the list of vtkmodules.qt but PyQt5 is checked first and for an unknown reason:
import sys

# PyQtImpl can be set by the user
PyQtImpl = None

# Has an implementation has been imported yet?
for impl in ["PySide6", "PyQt5", "PySide2", "PyQt4", "PySide"]:
    if impl in sys.modules:
        PyQtImpl = impl
        break

PyQtImpl is set to PyQt5 even though I uninstalled it :thinking:

PyQtImpl is set to PyQt5 even though I uninstalled it

If you're on linux, perhaps you have one in the system dist, like python3-pyqt5 or whatever?

I investigated and it is caused by qtpy. Setting QT_API should fix it.

Setting QT_API should fix it.

Can you open an upstream bug report with them? In the meantime, let's set this env var in just the PySide2 calls, then. (I can push a commit for this if you don't get what I mean.) And let's reenable PyQt6 -- sorry for the suggestion to disable earlier! Give me 1h to try to get a working VTK 9.2dev build to see if I can get PyQt6 fully working, but even if we don't, we can still test the non-3D stuff with that run...

Can you open an upstream bug report with them?

Sorry for the noise. Technically, qtpy is right because it tries to import PyQt5 and it properly detects PySide2 afterwards. That's when PyQt5 ends up in sys.modules and then is detected by vtk (because of the order in sysmodules.qt).
The real problem is that it should not be possible to import PyQt5 after uninstalling it right? Locally, it's still there for me:
python3.9/site-packages/PyQt5
❯ tree
.
├── bindings
└── Qt5
    ├── plugins
    ├── qml
    │   ├── Qt
    │   │   ├── labs
    │   │   └── test
    │   └── QtQuick
    └── qsci
        └── api

10 directories, 0 files

When I delete this directory manually, the issue is resolved because PyQt5 is not present in sys.modules. Setting QT_API prevents qtpy from importing PyQt5, that's why it also works for me.
I can also guess that it works with PySide6 because it has higher priority than PyQt5 in vtkmodules.qt.
At this point, I don't know if it's only me or this is something related to conda or pip :sweat_smile:

At this point, I don't know if it's only me or this is something related to conda or pip

Does pip list | grep -i pyqt5 yield anything? Maybe there is some other package like https://pypi.org/project/pyqt5-tools/ is installed?

One moment, I will double-check because I modified the env too much :+1:

... given that this can happen, though, it might still make sense to make a PR to qtpy to go beyond just a in sys.modules check, and actually try to import something that should be there, like QtCore, and only accept it as "imported" if it works.

The check of sys.modules is done in vtk, qtpy is correct and tries to import QtCore, that's why it detects PySide2 in the end:
https://github.com/mne-tools/mne-python/pull/10430#issuecomment-1090238118

https://gitlab.kitware.com/vtk/vtk/-/blob/master/Wrapping/Python/vtkmodules/qt/__init__.py#L27-31

Argh, I missed that this was already master! It would be good to open a PR to VTK to just add PyQt6 now that 9.2 will support it. They hopefully/maybe just forgot to update this Python code along the way. It's also possible that more changes will be required beyond just adding it, but at least we can get the ball rolling with them by making a PR to add PyQt6 to the list. Feel free to ping me over there (still as @larsoner )

qtpy is correct and tries to import QtCore,

I would also port this over to VTK and see what they say. In a worst case we have to remove it and just live with the in sys.modules check, but I assume qtpy did it for a good reason (maybe the one we're hitting here actually...)

... FYI here is a little diff I'm going to apply to VTK master and do a manylinux docker wheel build of 9.2dev / master with the following patch applied:
diff --git a/Wrapping/Python/vtkmodules/qt/__init__.py b/Wrapping/Python/vtkmodules/qt/__init__.py
index 2b5b2f73fb..cb7c27a308 100644
--- a/Wrapping/Python/vtkmodules/qt/__init__.py
+++ b/Wrapping/Python/vtkmodules/qt/__init__.py
@@ -19,16 +19,24 @@ For more information, see QVTKRenderWidgetConeExample() in the file
 QVTKRenderWindowInteractor.py.
 """

+import importlib
 import sys

 # PyQtImpl can be set by the user
 PyQtImpl = None

 # Has an implementation has been imported yet?
-for impl in ["PySide6", "PyQt5", "PySide2", "PyQt4", "PySide"]:
+for impl in ["PySide6", "PyQt6", "PyQt5", "PySide2", "PyQt4", "PySide"]:
     if impl in sys.modules:
-        PyQtImpl = impl
-        break
+        # Sometimes an attempted import can be crufty (e.g., unclean
+        # uninstalls of PyQt5), so let's try to import the actual functionality
+        try:
+            importlib.import_module(impl + '.QtCore')
+        except Exception:
+            pass
+        else:
+            PyQtImpl = impl
+            break

 # QVTKRWIBase, base class for QVTKRenderWindowInteractor,
 # can be altered by the user to "QGLWidget" or "QOpenGLWidget"

It's probably going to take a couple of hours to actually build, then I'll upload the wheel to OSF, and we can try it here!

It's probably going to take a couple of hours to actually build, then I'll upload the wheel to OSF, and we can try it here!

Thank you for the help! I think the updated test is more robust indeed.

Does pip list | grep -i pyqt5 yield anything?

Sorry for the delay, I purged my pip cache:
mne-python on  mnt/qtpy via 🐍 v3.9.12 via 🅒 test
❯ pip list | grep -i qt
mne-qt-browser                0.2.6
pyqtgraph                     0.12.4
pyvistaqt                     0.8.0
qtconsole                     5.3.0
QtPy                          2.0.1
sphinxcontrib-qthelp          1.0.3

mne-python on  mnt/qtpy via 🐍 v3.9.12 via 🅒 test
❯ pip list | grep -i pyside2
PySide2                       <IP_ADDRESS>

At the moment, there are some timeouts for:
mne-python on  mnt/qtpy via 🐍 v3.9.7 via 🅒 pyside2 took 18s
❯ pip install -i "https://pypi.anaconda.org/scipy-wheels-nightly/simple" pandas
Looking in indexes: https://pypi.anaconda.org/scipy-wheels-nightly/simple
WARNING: Retrying (Retry(total=4, connect=None, read=None, redirect=None, status=None)) after connection broken by 'ReadTimeoutError("HTTPSConnectionPool(host='pypi.anaconda.org', port=443): Read timed out. (read timeout=15)")': /scipy-wheels-nightly/simple/pandas/

I will try again later.

Thanks @GuillaumeFavelier !


Don't pull in importlib_metadata & zipp backports for Python 3.8+

The Python 3.8+ standard library importlib.metadata and zipfile.Path are preferred over the backports.
(FWIW: Fedora doesn't have the backports packaged for 3.8, but we use the wheel metadata, so things go boom! I'm sharing the patch – less dependencies is always good, right?)

The CI doesn't test 3.8, so I opened https://github.com/pypa/pep517/pull/71 to enable it.
If that is accepted, I can rebase this PR on top and let Travis test it.

Closing & reopening - I believe this will test the merge with master, no need for a rebase.


FIX: Potential uninitialised value returned if empty string passed to from_string()

Fix uninitialised value when empty string is passed to from_string<T>()
Update unicode emojis to latest version

[ Please outline your change here. Be sure to check the checkboxes below. ]
Code change checklist

[x] I have ensured that all methods and functions are fully documented using doxygen style comments.
[x] My code follows the coding style guide.
[x] I tested that my change works before raising the PR.
[x] I have ensured that I did not break any existing API calls.
[x] I have not built my pull request using AI, a static analysis tool or similar without any human oversight.

Fixes #1047


IMPORT CSV EMAIL

I can't import a csv. However I changed line 460 to "function isValidEmail($email) { //supports RFC 5322".
I now have this error:

Can you share a sample mail causing the error?

I put a test email in this file.
Otherwise I have 57 people.
test.csv

The CSV file is in wrong format. Add contents in correct structure. Check https://docs.sniperphish.com/getting-started/email-campaign/user-group

I added "First Name", "Last Name" and others... but I still have the error
test.csv

Why are you using semi-colon as a separator in CSV? What application are you using to create CSV file?

You should use comma instead of semi-colon for separating values.

I use excel, and yet I exported in .csv

I tried with several software, it does not solve anything

I solved the problem, but I don't know how.
Weird
Thanks for your reactivity GEM!


singletons-2.1

singletons-2.1 (FP Complete<EMAIL_ADDRESS>@snoyberg) is out of bounds for:

[ ] type-list-<IP_ADDRESS> (>=1.0 && < 2.1). Marcin Mrotek<EMAIL_ADDRESS>@marcinmrotek

Issue closed in the GHC 8 release. If packages have been removed temporarily, please sent a pull request to update build-constraints.yaml (search for GHC 8 or BLOCKED).


Mac address PSLAAC scanning

As suggested at Troopers, look into whether or not MAC addresses can be used to figure out PSLAAC addresses and scan for them.

+1 for this, this could be interesting with MAC address datasets such as the set of 600 or so MAC addresses specifically targetted in the ASUS Supply Chain Attack.


Workspace name fix

Summary
Fixes #167
Before this, I used to get random errors on every build. I just get a consistent RCTTurboModule not found now.
Changelog

[IOS] [BUG FIX]

@stealthanthrax I will run it locally today and let you know my findings.

@anku255 , which findings are you talking about as this is not a fix which will fix the app but will make the app give out consistent errors 😅

@stealthanthrax Well, I meant, if I also get the same errors or not.. and doesn't look like I do. :(

Oh man :( . Either way, RNTesterPods  doesn't exist anymore.

I believe we should be pointing to the right file.

Closing as it's not needed now.


Support for search

Can we add support for search in the database we already support.

added in v0.15.0 via the regex operator


[Release] sdk/resourcemanager/apicenter/armapicenter/0.1.0

https://github.com/Azure/sdk-release-request/issues/4365

module name reviewed: https://github.com/Azure/azure-sdk-pr/issues/1183

/azp run prepare-pipelines

/azp run go - armapicenter - ci

/check-enforcer override


Use ForkJoinPool as executorService

ForkJoinPool: threads are created only if there are waiting tasks. They expire after 2seconds (it's
hardcoded in the jdk code).
ForkJoinPool is better than ThreadPoolExecutor
It's available in the JDK 1.7

Merged build triggered.

Merged build started.

Test build #43504 has started for   PR 9054 at commit 43c4730.

Test build #43504 has finished for   PR 9054 at commit 43c4730.

This patch fails Spark unit tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test FAILed.

Test FAILed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/43504/
Test FAILed.

Merged build triggered.

Merged build started.

Test build #43514 has started for   PR 9054 at commit b39edc1.

Test build #43514 has finished for   PR 9054 at commit b39edc1.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/43514/
Test PASSed.

I don't think this is a helpful change. ForkJoinPool is for a work-stealing system where threads very frequently create small new tasks. We don't have that in Spark, and this will be less effective as a result. I would close this.

The executorService in this case is used to initiate retry for fetching blocks.
In a congested network environment, ForkJoinPool would serve better.
ThreadPoolExecutor is actually worse - it tries to create a thread even if there are already enough threads available.

The cached thread pool does not create threads if threads are available: http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/Executors.html#newCachedThreadPool()
Why do you think ForkJoinPool is better? http://docs.oracle.com/javase/7/docs/api/java/util/concurrent/ForkJoinPool.html
It is for contexts where threads create lots of small tasks. That's not the case here.

We have:
  public int ioRetryWaitTimeMs() {
    return (int) JavaUtils.timeStringAsSec(conf.get("spark.shuffle.io.retryWait", "5s")) * 1000;

According to http://grepcode.com/file/repository.grepcode.com/java/root/jdk/openjdk/6-b14/java/util/concurrent/Executors.java#Executors.newCachedThreadPool(java.util.concurrent.ThreadFactory) , keepalive timeout is 60 sec.
If there are relatively heavy retries, default keepalive timeout would keep more threads alive than necessary.

I think you're misunderstanding how it works. It doesn't create a thread, use it for one task, and then keep it alive for 60 seconds. Instead, any idle thread is reused immediately rather than creating a new one. It's only after a thread has seen no tasks for 60 seconds that it stops.
I disagree that it "keeps more threads alive than necessary". Still, what's the problem you're solving? This also has nothing to do with how ForkJoinPool is better. I'm certain it is not appropriate for this case. Would you close this PR?

Background:
http://stackoverflow.com/questions/19528304/how-to-get-the-threadpoolexecutor-to-increase-threads-to-max-before-queueing/19528305#19528305
Toward the end of the thread you would see LifoThreadPoolExecutorSQP which is unfortunately not Apache License.

In that discussion, the goal is to start threads more readily. (I'm actually not clear why it isn't solved with an unbounded queue, max core size, and allowing core threads to time out. The OP later mentions for some reason he wants to keep those threads alive, but also said he doesn't want to keep idle threads alive. ? )
newCachedThreadPool does not use an unbounded queue; in fact it uses one that can contain 1 element only. So it will always start a thread if none are available.
Is your desired behavior to block rather than start a thread? that's possible without ForkJoinPool; the thread you cite is an example. But I don't think this is necessarily OK given the function of this pool. However, I can imagine wanting to cap the number of threads in this pool to something reasonable, beyond which indeed requests just have to block. But you can do that directly (see above).
In any event, ForkJoinPool is not a tool that addresses either of these things. Its design goal is to overcome the overhead and contention of scheduling work in the pool itself. That's not a factor here.

Merged build triggered.

Merged build started.

Test build #43543 has started for   PR 9054 at commit 058e962.

Test build #43543 has finished for   PR 9054 at commit 058e962.

This patch passes all tests.
This patch merges cleanly.
This patch adds no public classes.

Merged build finished. Test PASSed.

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins/job/SparkPullRequestBuilder/43543/
Test PASSed.


Discussion: Futurism Improvements

Feature Request
I'm in the process of vetting futurism for use with Rails russian doll caching to solve some long-standing performance issues that I have an app that I've built out that has fairly deeply nested relationships (4 or 5 levels deep, some polymorphic) along with some fairly complex permission requirements currently implemented with CanCanCan.
It seems to me that pairing futurize and some judicious caching could allow extremely smart and lazy caching to significantly speed up page load times and greatly improve the user experience. Thank you this gem is amazing and I'm excited to see where it can go.
While working on evaluating whether this will work or not, I've developed an example app that might be helpful to use in further testing and refining futurism. You can find it at https://github.com/rickychilcott/futurism-auth-spike and can test it at https://sleepy-sea-13861.herokuapp.com/ (note I'm using free Heroku so spin up times initially will be slow). The app isn't that interesting, but to get a sense of the interesting bits please see:

https://github.com/rickychilcott/futurism-auth-spike/blob/main/app/controllers/home_controller.rb
https://github.com/rickychilcott/futurism-auth-spike/tree/main/app/views/home
https://github.com/rickychilcott/futurism-auth-spike/blob/main/app/helpers/application_helper.rb

The short explanation is that we lazily load several nested sets of resources, going to the database and randomly sleeping a certain amount of time to determine whether or not the "current user" has the permission to edit a given resource. The user/resource permission mapping is cached in Redis for 10 minutes so that future lookups of a given resource will only take the time to read from the cache. All partials are cached, but since they are really only generating <futurism-element> tags, they are lazily rendered on the page sometimes quickly (i.e. from cache) or slower (i.e. newly generated server side).
While this app isn't a perfect test, it's good enough to highlight some of the challenges and areas to improve futurism.
While playing with this in "production", I've noticed a few things:

Occasionally <futurism-element> never resolves. I have no idea why, but perhaps some sort of retry after a default/settable interval would be good.
The initial page load requires all "top-level resources" to be generated server-side before any of them are triggered. This, is caused by https://github.com/julianrubisch/futurism/blob/abb5bcf31c9cb381777b623c5f4768ddc8eda67d/lib/futurism/channel.rb#L23-L32 the cable_ready.broadcast line being called after all of the resources are rendered.

Some other things that would be nice:

A mechanism to implement poll/updated a <futurism-element> on a timer or to use javascript to trigger a rerender (i.e. document.queryselector('furism-element').reRender().
A mechanism to client-side cache the rendered content for some period of time and not go back to the server to ask for the server-side rendered content. For instance, I could see all of my permissions based partials could be cached for 10 minutes and NEVER ask the server until that time expires. This would reduce chatter over the wire.
A small thing, but sometimes you don't want a placeholder at all for a given element, so ideally a block would not be required as a placeholder.

Describe the solution you'd like
To fix the 2nd item on the "things I've noticed" list, I wonder if we could move the cable_ready.broadcast line into the loop. For quickly generating partials, this would have likely a small performance hit. For slower generating partials, it will have a significantly improved user experience.
For the other items, this is largely a set of discussion points that I'm open to working through, so I don't have a solution. However, as I've thought about these things, it feels like many of them could be made easier if instead of replacing <futurism-element> using cable ready's outer_html operating, what if we used inner_html and kept the <futurism-element> around for the entire duration of the page.
We'd likely need to clean up or change the API to remove classes/styling after the server side render is complete, but it may make caching, rerendering, and even #57 could be made simpler by not caching the previous <futurism-element> but instead just resetting it back to the pre-rendered state and setting element.innerHtml = ''. I also wonder if we could build out a small function API to allow things like element.reset(), element.render(), element.cache(1000*60*60), element.reRender(), element.reRender(force: true), element.reRender(every: 1000*60*5), etc.
Also, note that web components do allow you to implement a shadow DOM, so some of the "state" might be able to be kept within the component itself instead of localStorage, sessionStorage, etc. I don't fully understand whether or not turbolinks snapshotting or how styling is affected by the shadow DOM.
I'm happy to submit PRs (or ideally pair) for these items to get something started, but perhaps I've missed something in implementation details or specific reasons that some of these approaches haven't been taken. I love this gem and what it will enable, so I'm not intending any criticism. Just trying to help!

Awesome! It feels so great that other folks recognize the need and help me along with this 🙏
I have to go through all this but want to add to the list an obvious thing that could speed up things dramatically, is to use locate_many in case of a collection: https://github.com/rails/globalid#locating-many-global-ids

@rickychilcott I'm going to go over this again in the next few days.

Finally getting round to addressing some of the points you made. My goal is to finally get to a stable v1 some time soon.

retry after a default/settable interval would be good.

yep, I think this should be easily done.

The initial page load requires all "top-level resources" to be generated server-side before any of them are triggered.

This is intentional, to prevent some race conditions with CableReady I’ve encountered.

A mechanism to client-side cache the rendered content for some period of time and not go back to the server to ask for the server-side rendered content.

This is a perfect use case for a PWA. I could see that implemented like an additional JS module you can pull in if desired. (And added by the generator)

sometimes you don't want a placeholder at all for a given element, so ideally a block would not be required as a placeholder.

Do you have an idea how you’d implement this? An invisible/non-existent will never trigger the IntersectionObserver

shadow DOM, so some of the "state" might be able to be kept within the component itself instead of localStorage, sessionStorage, etc. I don't fully understand whether or not turbolinks snapshotting or how styling is affected by the shadow DOM.

Right, styling is the elephant in the room, which is why I wanted to keep the shadow DOM out of the equation here so as to not confuse users...

Re: PWA
Right after writing this I'm wondering if we should maybe just provide general instructions rather than an implementation because there can only be 1 service-worker for any given domain...

We could easily use the same pattern that I use for turbolinks caching (sessionStorage) because it destroys itself once the session is destroyed.
The problem is that it's not expireable and can only hold a few MB https://stackoverflow.com/questions/15171711/expiry-of-sessionstorage

@rickychilcott I decided to pull out some issues from this discussion, because I’m still getting a lot of positive feedback about futurism and think it should stay in the CableReady ecosystem, even with the advent of Turbo lazily loaded frames.
So please let me know if you see yourself taking on one or more of these issues :-)

@rickychilcott I decided to pull out some issues from this discussion, because I’m still getting a lot of positive feedback about futurism and think it should stay in the CableReady ecosystem, even with the advent of Turbo lazily loaded frames.
So please let me know if you see yourself taking on one or more of these issues :-)

Good stuff. You generated #78, #77, #76, #75. I also just added #79.
Thanks for pulling these out. I'm happy to work on them and will try to do so in the next week or so.

Awesome. I would like to take on #78, #77 is more a discussion right now.
Looking at #79 shortly

I've successfully fixed the Appraisals, so we're good to go now 👍

I've added the 1.0.0 milestone to the issues I'd like to see closed so we can finally do the major version bump.
Closing this for now


please add Clarksville, TN

Sorry reposting because was not sure if it was visible in other request, removed part about reform because I do strongly believe in defunding to abolish. Would this meet the guidelines?
Amending to this:
to<EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS><EMAIL_ADDRESS>subject: We Demand Justice
Hello,
My name is [NAME] and I am a resident of [NEIGHBORHOOD/WARD]. The unjust deaths of George Floyd, Breonna Taylor, and others undeniably call for justice. I am emailing today to demand action.
If you stand and, as Leaf Chronicle Photo captions, “listen to protesters in the middle of Wilma Rudolph Boulevard on Saturday,” we demand that you recognize and condemn the murder of George Floyd, who did not simply “die in police custody.” Failing to acknowledge his death as a murder only serves to minimize the responsibility that should be assumed by the police.
In response to national protests and unrest relating to police brutality and racial biases, the Clarksville Police Department has decided to conduct a review of its practices, which articles report you “praised.” I demand that such a review be performed externally rather than internally so as to improve the reliability of the findings of the review. The police killed 1,098 people in 2019. The existing policies do not work. The praise reported in the article is directed towards the CALEA accreditation website. Further research reveals no statistically significant difference between CALEA-accredited departments and non-accredited ones in the total number of complaints received and the number of sustained citizen complaints. That being said, the cities with the highest average number of police killings per 1M in the US (St. Louis and Oklahoma City) also have this accreditation. What significance does CALEA really play in reducing police brutality other than providing a certificate of completion when it is shown not to work?
I demand that the budget for the Clarksville Police Department be made available immediately and I urge you to consider redistributing funds from the CPD to initiatives relating to community development, COVID-19 relief, Parks and Recreation, and the Clarksville Montgomery County School System. Better investment of resources in these sectors can be used to ameliorate Clarksville’s sense of community and even to address racism explicitly.
This is a human rights issue. I am heartbroken to see yet another black life lost at the hands of racist officers. They must be held accountable. Your immediate action is necessary. I urge you to do the right thing.
Sincerely,
[Your Name]

duplicate of issue #508


ejabberd staging deployment

Damit MVPF mit der Entwicklung gegen die XMPP API starten kann benötigen wir einen entsprechenden staging server.

@tailic Please setup a CNAME for stage.jabber.hausgold.de -> jabber-stage-4e6fb84edbb7ac59.elb.eu-west-1.amazonaws.com.

Credentials:
Username<EMAIL_ADDRESS>Password: defaultpw

We use the https://github.com/hausgold/docker-ejabberd Docker image right now. Just to fulfil the high-prio/MVPF requirements. The storage is wiped on every deployment, so it's not persistent right now. The Identity API external auth is also missing.
But they are good to go for their development from XMPP perspective.

Port mapping:

4560 (XMLRPC)
5222 (Client 2 Server)
5269 (Server 2 Server)
5280 (HTTP admin/websocket/http-bind) - this is also bound on tcp/80, just for the sake of http://stage.jabber.hausgold.de
5443 (HTTP Upload)

Superfast™ ;)
CNAME added


Upgrade terraform-provider-confluent to v1.25.0

Fixes #67
Fixes #64
Fixes #63
Fixes #62
Fixes #61
Fixes #60
Fixes #59
Fixes #58
Fixes #56
Fixes #54

@aq17 can you point to what part of this PR fixes https://github.com/pulumi/pulumi-confluentcloud/issues/54?

@aq17 can you point to what part of this PR fixes #54?

My bad, that is a mistake


Include good Windows install instructions

Right now there are no instructions to run this under Windows, other than one line for how to run it under docker.
There should be a section specifically for doing a windows install, with as many helpful links as possible.
If anyone has gone through a windows install and would like to include their steps here, it would be much appreciated. I can validate them and update the README. I took a quick first pass last night and was surprised as the level of hassle, but maybe it's easier than I realize and I just did not follow a good path.

Hi there,
Not sure how useful this is as I had a lot of this setup already, although the path I would follow is below:
For ease of use I would suggest the windows package manager chocolatey, as it will ensure things are on path etc.

install espeak-ng from https://github.com/espeak-ng/espeak-ng/releases/latest
install ffmpeg with the command choco install ffmpeg, make sure you are in an elevated powershell session.
install python 3.11 with the command choco install python311
Install git with the command choco install git.
Decide where you want your epub2tts project to live, documents is a common place.
Once you've found a directory you're happy with, clone the project with git clone https://github.com/aedocw/epub2tts and cd epub2tts so you're now in your working directory.
There are probably a few different ways you can go here, I personally opted for a venv to keep everything organized.
create a venv with the command python -m venv .venv
Activate the venv, on windows the command is slightly different as you issue .venv\scripts\activate
install epub2tts along with the requirements with the command pip install .
If all goes well, you should be able to call epub2tts from within your venv and update it going forward.
Not sure how useful these quick notes are, as you may have a preferred way of doing things.
For sake of time at this stage I've skipped over installing chocolatey etc, as their docs are easily accessible.
This could also all be done manually of course, although for end users I don't know how comfortable I am instructing them to edit their path environment variables etc.
Hth a bit, and let me know if there's any testing/refining of this that would be useful for you.
I'm mostly on linux now, although my primary reason for running this on windows is due to the fact that's where my slightly better gpu is.
Can spin up a vm and test a fresh install, let me know what your thoughts are though.

These instructions worked for me yesterday, though when I had tried them a few days earlier I got an error when pip was installing TTS. Seems like it was just a transient problem with a dependency, because I had no issues later. That problem was what made me think this was a more complicated process than I had expected, but seems like it's pretty straightforward.
This is helpful and gives me enough to go from, hopefully I will get to writing them this week.

I'm just fumbling blindly trying to learn to use awesome code and project like this.. So a step by step like this is really helpful!
It worked for me.
Tho I was stuck on using CPU. Tried lots of things, but in the end i saw that requirements.txt was torch. I did:
"pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121" within .venv.
So now i am happily converting my first epub to an audiobook!

Troubleshooting Windows installation
Thank you @danielw97 and @michwad for the instructions, and of course @aedocw for the fantastic work that you've done!
I've managed to install it on Windows, but encountered some roadblocks along the way, so I thought I'd list a couple of the issues I encountered with solutions which might be helpful for others trying to install.

Install errors

At step 10 in @danielw97 's instructions (when running "pip install ."), the following errors may appear:
1. Microsoft C++ Build Tools not installed

ERROR: Could not build wheels for TTS, which is required to install pyproject.toml-based projects

This error appears if you haven't installed Microsoft C++ Build Tools. If you haven't installed, you should download the installer from:
https://visualstudio.microsoft.com/visual-cpp-build-tools/
run the vs_BuildTools.exe and select the "C++ Buld tools" checkbox leaving all options at their default value.
Note: This will require about 7 GB of space on C drive.
2. Cannot install lxml automatically

× Encountered error while trying to install package. ╰─> lxml

Run pip install lxml to install the latest version manually then re-run pip install .

Run errors

At step 11, (when calling epub2tts), the following errors may appear:
3. ffmpeg not found
Rerun the command choco install ffmpeg, making sure you are in an elevated powershell session, outside of the virtual environment.
4. NLTK: punkt not found

Resource punkt not found.
Please use the NLTK Downloader to obtain the resource:

Run the following to install it:
python -c "import nltk"
python -m nltk.downloader punkt

5. Enabling CUDA

Torch not compiled with CUDA enabled

As per @michwad 's solution, within .venv, run:
pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu121

Note: this will require about 2.5 GB of space.
After that, you may get yet another error, stating that the graphics card drivers are out of date. You should update them to proceed.

souns very complicated. usually I am under Linux but my desktop has to be windows, as I want CUDA there is only teh way over cuda enabled WSL2
Once that is installed (there are many easy guides for that) your Linux install instructions work 1:1 inside the WSL with CUDO working right away.
Just note that Ubutnu 20.04 has dependency issues ond WSL2-ubuntunu22.04 everything worked right away as described

Thank you @winfran for these detailed steps! I think I'll have time to update the docs tomorrow and include this stuff, it is super helpful - really appreciate it!

One thing to note is that installing deepspeed on Windows doesn't work. Potential work around with a precompiled .whl (I haven't tried it): https://github.com/microsoft/DeepSpeed/issues/2588#issuecomment-1502628005

README now has improved windows installation instructions.


copy & pasted docs

https://github.com/photonstorm/phaser/blob/v2.4.6/src/net/Net.js#L152-L160
the docs here look like they were just copy & pasted from the method above

Thanks for submitting this issue. We have fixed this, and the fix has been pushed to the dev branch.


Add battery and sensors to hello_services

Still no ios version.

Battery.dart is causing a test failure:
https://travis-ci.org/mit-mit/flutter


Status with 0.5.0?

Seems like the project has stalled a little bit after being merged together. Are you guys still working on this release?

Indeed we are @thehydroimpulse .  You can see what we're doing on this PR.  There is quite a bit to do still but we are chugging away. Feel free to chip in ;)

Thanks @achambers! I'll definitely dig into things.


Request adding a note about SiraUtil.json

Might want to add a note that editing the SiraUtil.json file won't be necessary if the 'Enabled' options don't exist. I was following the tut and saw the options weren't there, so I tried running the game anyways and all the features worked fine.
https://github.com/bsmg/wiki/blob/2b7053be8adaa465bdf20a5adf39dfe9aae52492/wiki/mapping/basic-lighting.md?plain=1#L215

Has been fixed in #399


Connection interface

Note: This PR is to get review and feedback
Connection interface for Bigtable client.

@jdpedrie @sduskis can we discuss this on call?

Sure, I’d be happy to.

I've pushed up a bigtable branch we can use to open this and other incremental PRs against. That way we can merge code in without worrying about holding up any releases.

Created client connection interface PR to GoogleCloudPlatform:bigtable from mohitq:bigtable_connection-interface
https://github.com/GoogleCloudPlatform/google-cloud-php/pull/1020


Update into newest solidity and solcpiler

Now when using erc820 contract with pragma solidity ^0.4.24 there are a lot of warnings. Would be nice if you could update.

This was actually done when moving to ERC1820.

(Note that solcpiler was not updated but removed in favor of plain solc.)


Add cylinder article

[x] I have read freeCodeCamp's contribution guidelines.
[x] My pull request has a descriptive title (not a vague title like Update index.md)
[x] My pull request targets the master branch of freeCodeCamp.
[x] None of my changes are plagiarized from another source without proper attribution.
[x] My article does not contain shortened URLs or affiliate links.

This pull request adds an article explaining the surface area and volume formulas of a cylinder.

Closed and Reopened this PR to attempt to resolve a specific Travis build failure.

Thank you for opening this pull request.
This is a standard message notifying you that we’ve reviewed your pull request and have decided not to merge it. We would welcome future pull requests from you.
Reason: Since your PR was created, the master branch content has updated making some of your changes unnecessary or need to be reorganized to fit the current version.  Please re-sync your fork so you are looking at the latest version of master and then create a new PR if you find any changes warranted.
Thank you and happy coding.


Datasets conversion tool

Can you provide datasets conversion tools?

Can you provide icdar2015 dataset conversion script, thanks

Yes definitely, we'll prioritize it and aim to upload it in about a week, I'll keep you posted in any case.

Hi, may i ask whether you upload the conversion scripts? i cound't find the scripts.

Thanks a lot, but now I still can not find converision scripts.

+1


[REQ] Add more emojis

Acknowledgement of preliminary instructions

[X] I have read and acknowledged the preliminary instructions.

What idea do you have?
like seriously, the only things you can select are cat emojis and windows emojis, more variants please!

true... hold on let me see if i can find any

https://fonts.google.com/noto/specimen/Noto+Emoji i found this one that i like, will edit this comment if i find more

I've looked at this before, only the monochrome emojis are compatible with Windows.

I wouldn't really want to add this.

?

also i meant the monochrome emojis, not the stinky color ones

 ?

they shouldn't make options that would be a problem for certain systems considering bloxstrap may expand to other platforms

?

I meant to say that the colour ones weren't supported for Windows. I didn't know people preferred monochrome emojis - I guess I can consider other ones too.
If you want to do this for yourself in the meantime, open the mods folder, go to content\fonts, place your emoji font file there and rename it to TwemojiMozilla.ttf.

@pizzaboxer im updating my repository.

@imadeagithubaccountforthis about docomo emoji (by: meownica), is have 166 emojis and unicode 3.0...

yeah, i was just searching for stuff, why aren't there more emoji fonts smh

...You can't just tell me to add more emoji sets without giving me any.

okay what about this https://github.com/c1710/blobmoji

above comment is infact not off topic

another possible emoji pack
https://github.com/hfg-gmuend/openmoji

yet another one https://github.com/linusg/serenityos-emoji-font

Noto Color Emoji looks way better than normal Noto Emoji

whatsapp & ios emoji packs (they look basically the same)
https://github.com/dmlls/whatsapp-emoji-linux/releases
https://github.com/samuelngs/apple-emoji-linux/releases

whatsapp & ios emoji packs (they look basically the same) https://github.com/dmlls/whatsapp-emoji-linux/releases https://github.com/samuelngs/apple-emoji-linux/releases

is can't support on roblox not raster emojis...

Noto Color Emoji looks way better than normal Noto Emoji

only works perfectly Noto Emoji BnW

If you want to do this for yourself in the meantime, open the mods folder, go to content\fonts, place your emoji font file there and rename it to TwemojiMozilla.ttf.

doesnt work

Your chosen emoji font isn't compatible then

can u clarify?

Roblox requires a specific format that not all emoji fonts can satisfy (especially those from other platforms/devices).

and the emoji format is...?

All you need to know is that it's specific to Windows. If the emojis show up as blank then it doesn't fit the format.


Component model: bindgen! with multiple worlds

It does not seem to be possible to import two worlds in the same Rust file.
When the two worlds are part of the same WIT package, bindgen! allows you to select only one, and if you use the macro twice with different world names the package export gets duplicated.
If you add the two worlds to different packages in the WIT files and try to use bindgen! for each of them on the same Rust file, you get the error: the name exports is defined multiple times.
Is it possible to do this in some way that I am missing?
Test Case
Any file that defines two worlds
Steps to Reproduce

Create a WIT with two worlds
Try to use bindgen! to use both worlds on the same Rust file.

Expected Results
Being able to use both worlds in the Rust code
Actual Results
The compiler fails because of how the exports are setup. I have to place the bindgen! macro in different files, so it produces a weird way of referencing the worlds in rust as you have the same package name and my WIT files cannot share functions from the package.
Versions and Environment
Wasmtime version or commit: 15.0.1
Operating system: Ubuntu 22.04
Architecture: x86_64

Yes bindgen! works at the granularity of worlds, so if you've got two worlds your choices are:

Create a third world that includes both, and then bindgen that one.
Use bindgen! twice in separate modules: mod a { bindgen!(...); } mod b { bindgen!(...); }

Does either of those work for you?

Hi @alexcrichton ,
Yes. I mean, there are several ways of working around this. But is there any actual reason for that? It seems to me a bit counterintuitive. I would expect to be able to use all the worlds of a package in the same file. It would be like "importing a package in the file" instead of being able to "import a single class from each package per file".

More-or-less the answer is "this is what worlds are built for". They're the unit of work for bindings generators. WIT is designed to be used by many bindings generators and it's desirable to have the same interface (ish) across them all, and using a world is what they are all currently based on. While it's possible to refactor and update all of them to work with multiple worlds, this is also why features like include where added in addition to the inline option for Wasmtime's bindgen! macro were added (to easily make new worlds).
Basically the choice of "what is the unit of bindgen" is a cross-cutting decision. We chose "world" as the unit and so everything is built on that. Similar to how C compilers work on a single *.c file at a time while the Rust compiler works on a whole crate at a time. No fundamental reason for either choice, but so many things are built around that as a result.

Thank you for the explanation @alexcrichton. Closing the issue since it seems it is not unexpected behavior but a design choice.


Update 10_bayesian-differential-equations.jmd

suggested new ICs for simulation;
suggested using real-world LV data.

@ChrisRackauckas @yebai I just added the real-world data from the Stan tutorial (https://mc-stan.org/users/documentation/case-studies/lotka-volterra-predator-prey.html), assigned it to odedata as an alternative to the simulated data.
Should be ready to be merged if you think it's appropriate. Thanks.

@devmotion Thanks very much for your time and useful advice. Yes I also found the Stan, Tensorflow, and Edward/Python p-PCA tutorials useful.

thanks @YongchaoHuang!


Factoring of semantics-specific functionalities

This PR creates a KCFGSemantics class, which holds semantics-specific functionalities, specifically:

the is_terminal(c) predicate, which checks whether or not the passed-in node is terminal;
the extract_branches(c) function, which understands whether the passed-in node can be split;
the abstract_node(c) function, which abstracts the passed-in node
the same_loop(c1, c2) function, which identifies if the two passed-in nodes represent the same loop head;
the cut-point rules of the semantics; and
the terminal rules of the semantics;

and refactors the code to use this class appropriately.

@PetarMax can you mark the conversations that are done as resolved?

@PetarMax can you mark the conversations that are done as resolved?

Done.

That is true, but this is a user-supplied semantics -specific function, so
if the user chooses to do something like that, so be it - I don't think we
should be protecting against.
On Wed, 26 Jul 2023, 11:33 Raoul, @.***> wrote:

@.**** commented on this pull request.
In src/pyk/kcfg/explore.py
https://github.com/runtimeverification/pyk/pull/546#discussion_r1274669396
:

   new_cterm = self.kcfg_semantics.abstract_node(node.cterm)

   if new_cterm == node.cterm:

       return False

But what if the two terms are equivalent modulo alpha-renaming? In this
case, we don't have pure syntactic equality, i.e., new_cterm == node.cterm
is false, and kcfg.create_cover will succeed, where the substitution
gives us the renamings. Strictly speaking, the new term is not strictly
more abstract than the original term. This could lead to some infinite
loop, where we keep abstracting terms forever without progressing, no?
—
Reply to this email directly, view it on GitHub
https://github.com/runtimeverification/pyk/pull/546#discussion_r1274669396,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ACBFCSSQI6KOMEWNIYAJR6LXSDP43ANCNFSM6AAAAAA2RLKPRA
.
You are receiving this because you modified the open/close state.Message
ID: @.***>


knit: move commands into pkg

code movement + trivial rename to move the cobra commands into
a package, to improve reusability.
Signed-off-by: Francesco Romani<EMAIL_ADDRESS>

/cc @Tal-or @marcel-apf @yanirq

this PR enables us to easily consume knit code from gather_sysinfo.


Avoid panic when generating certificates for conversion webhook

Description
Currently if the CRD has no ClientConfig or the whole conversion section in the CRD was empty, the operator panicked, because of a nil pointer error. This should be solved with properly checking if the values, which are accessed inside isBundleValid() are set
How can this be tested?
Deploy a CRD with an empty ClientConfig section
Start the operator and check if the cert-controller is still panicking
Checklist

[x] Unit tests have been updated/added
[x] PR is labeled accordingly
[x] I have read and understood the contribution guidelines

Adding a log is not necessary, as a log is written properly afterwards: https://github.com/Dynatrace/dynatrace-operator/blob/c2808df05b60b2f0c0696bac9d7a8c5faf37300a/src/controllers/certificates/webhook_cert_controller.go#L230


[Element] is not a known element

Package.json
{
"name": [App Name],
"main": "./src/main.ts",
"version": "1.0.0",
"private": true,
"dependencies": {
"@angular/animations": "~13.1.1",
"@angular/common": "~13.1.1",
"@angular/compiler": "~13.1.1",
"@angular/core": "~13.1.1",
"@angular/forms": "~13.1.1",
"@angular/platform-browser": "~13.1.1",
"@angular/platform-browser-dynamic": "~13.1.1",
"@angular/router": "~13.1.1",
"@nativescript/angular": "^13.0.0",
"@nativescript/background-http": "^5.0.2",
"@nativescript/core": "~8.1.1",
"@nativescript/firebase-analytics": "^1.0.0-alpha.0",
"@nativescript/firebase-core": "^1.0.0-alpha.0",
"@nativescript/theme": "~3.0.1",
"@nativescript/webpack": "~5.0.0",
"@nstudio/nativescript-cardview": "^2.0.1",
"@nstudio/nativescript-checkbox": "^2.0.4",
"@nstudio/nativescript-loading-indicator": "^4.1.2",
"moment": "^2.29.1",
"nativescript-appavailability": "^1.3.2",
"nativescript-appversion": "^1.4.4",
"nativescript-exit": "^1.0.1",
"nativescript-fingerprint-auth": "^7.0.2",
"nativescript-geolocation": "^5.1.0",
"nativescript-google-maps-sdk": "^3.0.2",
"nativescript-mediafilepicker": "^4.0.2",
"nativescript-modal-datetimepicker": "^2.1.5",
"nativescript-phone": "^3.0.2",
"node-sass": "^7.0.1",
"rxjs": "~7.4.0",
"zone.js": "~0.11.4"
},
"devDependencies": {
"@angular-devkit/build-angular": "~13.1.1",
"@angular/compiler-cli": "~13.1.1",
"@nativescript/android": "8.1.1",
"@nativescript/types": "~8.1.1",
"@ngtools/webpack": "~13.1.1",
"typescript": "~4.4.4"
}
}
Error:
error NG8001: 'FlexboxLayout' is not a known element:

If 'FlexboxLayout' is an Angular component, then verify that it is part of this module.
To allow any element add 'NO_ERRORS_SCHEMA' to the<EMAIL_ADDRESS>of this component.

error NG8001: 'CardView' is not a known element:

If 'CardView' is an Angular component, then verify that it is part of this module.
To allow any element add 'NO_ERRORS_SCHEMA' to the<EMAIL_ADDRESS>of this component.

All modules on my project, has @NgModule.schemas: "NO_ERRORS_SCHEMA".
This is a newly generated Nativescript angular app, but I copy paste a "src" folder from my old Nativescript project.

I have the same problem on Angular v13.0.0, I tried creating a shared module which exports the desired component but does not work either.


Feature Request: add config to follow redirects with Sensitive Headers

Can we get the ability to enable/disable sensitive headers when following redirects?
Seems the default is to always remove headers like Authorization which has caused unexpected problems for me: https://github.com/softwaremill/sttp/blob/master/core/src/main/scala/sttp/client/FollowRedirectsBackend.scala#L78
private def stripSensitiveHeaders[T](request: Request[T, S]): Request[T, S] = {
    request.copy[Identity, T, S](
      headers = request.headers.filterNot(h => sensitiveHeaders.contains(h.name.toLowerCase()))
    )
  }

I'd like the ability to opt-in to resend Authorization and other headers when following redirects.
Currently, I have to work around this by immediately flatMap-ing after a response to check if it returned 401 with history.nonEmpty and the last response had a Location header, then re-issue the original request with an updated uri to this location. And combining that workaround with the logging backend means I'm always making valid API calls, but the logs are polluted with Http 401s.

One possibility to achieve this today is to wrap your backend in FollowRedirectsBackend. This effectively deactivates any nested FollowRedirectsBackend (which are there by default).
So you can do: val myBackend = new FollowRedirectsBackend(delegateBackend, sensitiveHeaders = Set.empty)
Maybe this would need better documentation :)

Ok I tried that and it works.
val sttpBackend = Slf4jLoggingBackend[Future, Source[ByteString, Any], Nothing](
  new FollowRedirectsBackend[Future, Source[ByteString, Any], Nothing](
    AkkaHttpBackend(),
    sensitiveHeaders = Set.empty // we want redirects with Authorization
  )
)

That's interesting, because I would expect it to fail after the initial FollowRedirectsBackend redirects and gets 401 and bubbles that up to the second FollowRedirectsBackend, which shouldn't redirect because its not a Http 3XXcode. Seems the redirect logic does not look at status codes, only Location header.

Any nested FollowRedirectsBackends are effectively deactivated, as the request that's passed down the chain has followReidrects set to false. So only the outer one does any work - and it does take into account status codes :)


Cron > Tips & Troubleshooting

Under "Tips & Troubleshooting" section, there is an example of how to pipe cron output to a file:

To assist in troubleshooting cron issues, you can pipe the output of each cron job to a specific file by adding something like >/path/to/somefile.log 2>&1 at the end of the cron job.

But this would overwrite the log on every cron run, which isn't too useful. Better to use >> to append log.

Thanks for pointing it out! Would you be able to update the docs?

Done.


Select multiple nodes/edges

Is your feature request related to a problem? Please describe.
Sometimes it'd be nice to interact with multiple nodes or edges at the same time - for mass-deleting, or even just having multiple parts highlighted (after #196 , this will probably be significantly more desired, for mass-moving).
Describe the solution you'd like
Allow me to select multiple nodes and edges, potentially through:

ctrl + click to add another part to the selection
click + drag to select many parts at once (currently left-click pans; perhaps we can use ctrl + left-click for select?)

Multi-select actions:

mass-delete
mass-connect to another node
copy/paste to another diagram (probably future)

Draw.io and miro.com will be good references for how this functionality can work, e.g. Draw.io looks like this for the above two things:

Describe alternatives you've considered
Additional context
Discord convo https://discord.com/channels/1057707973482401892/1057707973482401899/1148994000909516870
Technical ideas

react flow probably has built-in multi-select functionality
we're probably hardcoding some assumptions that only one part is selected at a time

this would be really really nice when a diagram is big and want to create a view specifically for nodes relevant to newly-created criteria (example topic where this would be nice)


Side Panel Art

The side panel containing players' stats is currently text based and not very attractive. Use images to represent stats and make the panel more visually appealing.

commit f6b8d26208ff5ae40f592075a51679bfd3c9599a