Augmentation layers only active during training!

Description of issue (what needs to be changed):.
Correct links. https://keras.io/guides/preprocessing_layers/
As it said, the following layers apply random augmentation transforms to a batch of images. They are only active during training.
tf.keras.layers.RandomCrop
tf.keras.layers.RandomFlip
tf.keras.layers.RandomTranslation
tf.keras.layers.RandomRotation
tf.keras.layers.RandomZoom
tf.keras.layers.RandomHeight
tf.keras.layers.RandomWidth
tf.keras.layers.RandomContrast
So, in the model, if we use these layers, they will be active (i.e. model.fit / model(..., training=True) during training but will be inactive when we call model.evaluate and model.predict / model(..., training=False). A sample model would be
model = keras.Sequential(
   [
      tf.keras.layers.RandomHeight,
      tf.keras.layers.RandomContrast,
      tf.keras.layers.Conv2D,
      tf.keras.layers.Dense
      ...
    ]
)

Queries

What if I want the augmentaiton layer be active in the prediction phase (i.e for making test-time-augmentaiton), using model.predict? We can use model(..., training=True) but (a). It's best suited for small amount of data, and (b). some other function (dropout) might be active.
Already checked it. https://github.com/keras-team/keras/blob/e6784e4302c7b8cd116b74a784f4b78d60e83c26/keras/backend.py#L451-L456

What if I want the augmentaiton layer be active in the prediction phase (i.e for making test-time-augmentaiton), using model.predict

I think one way would be writing a wrapper class and force training=True:
class WrappedRandomFlip(layers.experimental.preprocessing.PreprocessingLayer):
    def __init__(self, mode, seed):
        super(WrappedRandomFlip, self).__init__()
        self.layer = layers.RandomFlip(mode=mode, seed=seed)

    def call(self, inputs, training):
        return self.layer(inputs, training=True)

Otherwise using training=True can trigger such regularization layers like Dropout etc. as you said.

What if I want the augmentaiton layer be active in the prediction phase (i.e for making test-time-augmentaiton), using model.predict

I think one way would be writing a wrapper class and force training=True:
class WrappedRandomFlip(layers.experimental.preprocessing.PreprocessingLayer):
    def __init__(self, mode, seed):
        super(WrappedRandomFlip, self).__init__()
        self.layer = layers.RandomFlip(mode=mode, seed=seed)

    def call(self, inputs, training):
        return self.layer(inputs, training=True)

Otherwise using training=True can trigger such regularization layers like Dropout etc. as you said.

@Frightera thanks, It seems a standard approach. But to make it work, I've to rewrite the model definision in the prediction time.
model = [random_layers, conv2d, dense, ..]
model.fit
model.evaluate

model = [wrapper_random_layers, , model[1:]]
model.predict

@innat What about inheriting BaseImageAugmentationLayer directly and creating an attribute called test_time_aug?
from keras.layers.preprocessing.image_preprocessing import BaseImageAugmentationLayer

class WrappedRandomFlip(BaseImageAugmentationLayer):
    def __init__(self,
                 mode="horizontal_and_vertical",
                 seed=None):

        super(WrappedRandomFlip, self).__init__()

        self.layer = layers.RandomFlip(mode=mode, seed=seed)
        self.test_time_aug = False

    def call(self, inputs, training):
        if self.test_time_aug:
            return self.layer(inputs, training=True)
        else:
            return self.layer(inputs, training=training)

random_layer = WrappedRandomFlip()

Then you need to override/wrap your predict function into another one and check the layers of the model using isinstance(layer, BaseImageAugmentationLayer) and set test_time_aug = True.

@Frightera Thanks, really appreciate your suggestion.  I expected to get it directly without any sort of workaround. But as augmentation only supposed to be applied on training set, so that makes sense to disable it fully in the testing time. From your suggestion, here is one way to achieve. I'm also interested to know if it's the best way to do this from the API until now. (cc. @rchao)
class TrainingAugmentationLayers(keras.layers.Layer):
    def __init__(self):
        super().__init__()
        self.random_flip = RandomFlip("horizontal")
        self.random_zoom = RandomZoom(0.1, fill_mode='reflect')
        self.random_rotate = RandomRotation(0.1, fill_mode='reflect')
    def call(self, inputs):
        x = self.random_flip(inputs)
        x = self.random_zoom(x)
        x = self.random_rotate(x)
        return x

class PredictAugmentaitonLayers(TrainingAugmentationLayers):
    def call(self, inputs):
        x = self.random_flip(inputs, training=True)
        x = self.random_zoom(x, training=True)
        x = self.random_rotate(x, training=True)
        return x

img = tf.random.normal([20, 512, 512, 3], 0, 1, tf.float32)
y_true = img

inputs = tf.keras.Input(shape=(512, 512, 3))
x = TrainingAugmentationLayers()(inputs)
y = PredictAugmentaitonLayers()(inputs)
model = tf.keras.Model(inputs=inputs, outputs=[x, y])

y_pred1, y_pred2 = model.predict(img)
np.allclose(y_pred1, y_true) # True
np.allclose(y_pred2, y_true) # False

@innat - It is expected behavior for augmentation to run only during training. However if you want augmented data during inference too, I have some questions

Do you expect your model to always augment during inference? - you might not know what to expect in the results. - If you want this to be your final model behavior, you can create a wrapper class that subclasses the random* or BaseImageAugmentation class and override the call method as suggested by @Frightera
Do you just want to generate more data using augmentation layers and test your model, not necessarily want it as final model behavior? - in this case you can add augmentation layers outside your model during inference and feed that input to your model.

@divyashreepathihalli
I was trying to achieve this for Test-Time-Augmentation (TTA). (with model (defined by any API, sequential, functional or subclass).

In that case I would recommend option one specified above.

@divyashreepathihalli
How it can be controlled in a more elegant way with a same model?
model = [InputLayer, Preprocessing, Augmentation, ...]
model.fit <- Augment
model.evaluate <- No Augment
model.predict <- Augment (for TTA)

To make TTA in the prediction time, it is needed to rebuild the augmentation layer (with training=True) of the trained model. In that case, I like to test it how it goes with all modeling API (seq, func, sub). The possible problem might be the insert and remove layer in some cases.

Please, don't close the issue w/o asking the OP and set stat:awaiting response from contributor.


Authorized Cluster Endpoint unavailable after upgrading to Rancher 2.6.x and RKE 1.21.5-rancher1-1

Rancher Server Setup

Rancher version: 2.6.1
Installation option (Docker install/Helm Chart):

If Helm Chart, Kubernetes Cluster and version (RKE1, RKE2, k3s, EKS, etc): Helm Chart

Information about the Cluster

Kubernetes version: RKE 1.21.5-rancher1-1
Cluster Type (Local/Downstream): Downstream

If downstream, what type of cluster? (Custom/Imported or specify provider for Hosted/Infrastructure Provider): RKE Rancher Launched using Docker

Describe the bug

Authorized cluster endpoint isn't working, even after enabling and reenabling it the following issue presents itself:
Kubectl output:
error: You must be logged in to the server (Unauthorized)

Output of the kube-api-auth pod:
time="2021-10-19T17:23:39Z"  level=error msg="clusterAuthToken.cluster.cattle.io  \"cattle-system/kubeconfig-u-m2ac4e3amu.c-hjvg2\" not found"
--

And indeed the result of the check whether there is any token results in:
$ kubectl get clusterAuthToken.cluster.cattle.io --all-namespaces
No resources found

The endpoint is enabling/disabling correctly as the resource types are created. However it seems no auth token is being created when the kubeconfig is being downloaded.
To Reproduce
This is where it gets tricky. I've upgraded these clusters from rancher 2.5.10 and the then current RKE version. I haven't done anything else to them and the endpoint has always been enabled. I've tried disabling and reenabling it.
Result
Access denied
Expected Result

Authorized Endpoint works
Screenshots

Additional context
Power cycling the cluster does not solve the problem.
Installing a new cluster with rke 1.21.5-rancher1-1 shows the same issue.
Logs from the rancher pod itself:

2021/10/19 17:48:03 [ERROR] error syncing 'kubeconfig-u-m2ac4e3amu.c-hjvg2': handler cat-token-controller: clusterAuthToken for token [kubeconfig-u-m2ac4e3amu.c-hjvg2] has not been created yet, requeuing
2021/10/19 17:48:12 [ERROR] error syncing 'c-9qr2x': handler restrictedAdminsRBACCluster: 1 error occurred:
	* RoleBinding.rbac.authorization.k8s.io "crt-c-9qr2x-cluster-owner-" is invalid: subjects[0].name: Required value

, requeuing
2021/10/19 17:48:16 [ERROR] error syncing 'c-pr5ds': handler restrictedAdminsRBACCluster: 1 error occurred:
	* RoleBinding.rbac.authorization.k8s.io "crt-c-pr5ds-cluster-owner-" is invalid: subjects[0].name: Required value

Feature flags:
> kubectl get features.management.cattle.io
NAME                          CUSTOM VALUE   DEFAULT   DESCRIPTION
continuous-delivery           <no value>     true      Gitops components in fleet
fleet                         <no value>     false     Install Fleet when starting Rancher
harvester                     <no value>     true      Enable Harvester integration, with ability to import and manage Harvester clusters
istio-virtual-service-ui      <no value>     true      Exposes a UI that enables users to create, read, update and delete virtual services and destination rules, which are traffic management features of Istio.
legacy                        true           false     Enable legacy features
multi-cluster-management      <no value>     false     Multi-cluster provisioning and management of Kubernetes clusters.
rke2                          <no value>     false     Enable provisioning of RKE2
token-hashing                 <no value>     false     Enable one way hashing of tokens. Once enabled token hashing can not be disabled
unsupported-storage-drivers   <no value>     false     Allows the use of types for storage providers and provisioners that are not enabled by default.

Since this might be relevant to the bug. Users are SSO users via Keycloak SAML.

I failed to  reproduce
Note: While I failed to reproduce this doesn't necessarily mean this issue does not exist. It's possible that the steps to reproduce could have been misinterpreted or that my environment was different in some way that could cause me to not reproduce the issue.
Reproduction Environment:

Rancher version: v2.5.10 to v2.6.1
Rancher cluster type: HA
Downstream cluster type: RKE1
Downstream K8s version: v1.20.11-rancher1-1 via AWS EC2 Node driver, upgraded post rancher upgrade to v1.21.6-rancher1-1 (the latest available in the UI).
Reproduction steps:

Throughout all testing watch the rancher pod logs for any errors.
Install Rancher 2.5.10. Setup Keycloak SAML as the auth provider. Create a downstream RKE1 cluster - I used the AWS EC2 node driver to create this downstream cluster. RKE k8s version 1.20.11-rancher1-1. ACE should be enabled when creating the cluster (it is by default).
Wait for the downstream cluster to provision, when it is ready get the kubeconfig from the Rancher UI. Set it as the config for kubectl on another machine. Ensure the primary context works (it does). Now, use the secondary context (This is the ACE context) -- kubectl config use-context 2ND-CONTEXT-NAME ensure this works (it does).
Now, upgrade rancher to v2.6.1. During this process I didn't notice anything concerning in the rancher pod logs. When the upgrade is done reset the kubectl queries (I actually used kubetail) so they monitor the new rancher pods (the upgraded ones).
Now, upgrade the downstream RKE1 cluster to the latest available version. Due to a KDM release this is v1.21.6-rancher1-1 (issue reports v1.21.5-rancher1-1 as that was probably the latest at the time).
Ensure that the secondary context still works with the same kubeconfig for the downstream cluster. This works for me -- I didn't encounter any issues.

Additional Info:

I have some thoughts about my attempt to reproduce. Maybe I could not reproduce due to any of the following?

Misinterpretation of the issue (maybe an imported rke cluster was used as the downstream cluster? This is not clear)
My environment could be slightly different or Keycloak SAML server slightly different in some way
The newer RKE version I upgraded to for the downstream cluster could be a factor
Something else

cc: @sowmyav27 for awareness.

Ok the fact that you can not reproduce it gives me hope that this is an issue with our environment rather than with rancher itself. I'll try to setup a new separate rancher server and try to reproduce the issue myself on a different cluster.
Some additional info myself:

Its not an imported RKE Cluster, it was launched in 2.5 and just ported over automatically
The downstream RKE version doesn't seem to matter as I've upgraded it to the latest available version as well (even the one shipped with 2.6-head and marked as experimental)
Rancher itself is running on a k3s cluster, the same cluster that keycloak itself is running on
The nodes themselves are baremetal and not cloud hosted, might make a difference as our environment isn't the same there.

If I can reproduce it in an additional cluster I'll let you know, if I can't reproduce it myself that will make it probably impossible to diagnose as reproduction is the first step in such a process as always.

I failed to reproduce Note: While I failed to reproduce this doesn't necessarily mean this issue does not exist. It's possible that the steps to reproduce could have been misinterpreted or that my environment was different in some way that could cause me to not reproduce the issue.
Reproduction Environment:
Rancher version: v2.5.10 to v2.6.1 Rancher cluster type: HA
Downstream cluster type: RKE1 Downstream K8s version: v1.20.11-rancher1-1 via AWS EC2 Node driver, upgraded post rancher upgrade to v1.21.6-rancher1-1 (the latest available in the UI).
Reproduction steps:
0. Throughout all testing watch the rancher pod logs for any errors.

1. Install Rancher 2.5.10. Setup Keycloak SAML as the auth provider. Create a downstream RKE1 cluster - I used the AWS EC2 node driver to create this downstream cluster. RKE k8s version 1.20.11-rancher1-1. ACE should be enabled when creating the cluster (it is by default).

2. Wait for the downstream cluster to provision, when it is ready get the kubeconfig from the Rancher UI. Set it as the config for `kubectl` on another machine. Ensure the primary context works (it does). Now, use the secondary context (This is the ACE context) -- `kubectl config use-context 2ND-CONTEXT-NAME` ensure this works (it does).

3. Now, upgrade rancher to v2.6.1. During this process I didn't notice anything concerning in the rancher pod logs. When the upgrade is done reset the kubectl queries (I actually used kubetail) so they monitor the new rancher pods (the upgraded ones).

4. Now, upgrade the downstream RKE1 cluster to the latest available version. Due to a KDM release this is v1.21.6-rancher1-1 (issue reports v1.21.5-rancher1-1 as that was probably the latest at the time).

5. Ensure that the secondary context still works with the same kubeconfig for the downstream cluster. This works for me -- I didn't encounter any issues.

Additional Info:
I have some thoughts about my attempt to reproduce. Maybe I could not reproduce due to any of the following?
* Misinterpretation of the issue (maybe an imported rke cluster was used as the downstream cluster? This is not clear)

* My environment could be slightly different or Keycloak SAML server slightly different in some way

* The newer RKE version I upgraded to for the downstream cluster could be a factor

* Something else

cc: @sowmyav27 for awareness.

It seems I forgot to add one vital piece of information.
Everything works fine in the default install. When you apply the steps from Setting TTL on Kubeconfig Tokens is when it stops to work.
The first two steps are enough. As soon as you switch from having a token embedded in the kubeconfig to having the rancher command in the kubeconfig it breaks.

Do you set TTL on the kubeconfig tokens in v2.5.10 or after the upgrade?
It may not matter but just want to make sure I get the timing of this correct when I try to reproduce again.

Either produces the issue. In the original issue that happened I set the TTL on the 2.5 instance and it just persisted through the upgrade. In my repro I've set it after seeing that it still worked in 2.6 and found out that setting that breaks it.

I cannot encounter the issue with v2.5.10. I will try upgrading and see if the issue happens to me post-upgrade but this will take some time as I am juggling other priorities currently.


Treats all single quotes as comments.  Not just the ones inside a code block.

Any line that has a single quote ' is treated as a comment.  Doesn't matter where it is.  This really messes with the javascript highlighting.

Unfortunately this is the problem in ASP.tmLanguage file. I am not sure if it is possible to fix it. If you know how to do this, I'd like to have this pull request. Sorry.


Add FITS file name to version mismatch warning

This fixes #311. It is just a follow-on to #306, so there is no need to update the change log.

Coverage increased (+0.001%) to 94.495% when pulling d98a8742bb17043bea98f9b1479f98e18b25a336 on drdavella:fitsname-in-warning into 58fb686601dae42ee4a8eba917fc32546523d8d1 on spacetelescope:master.

Coverage increased (+0.001%) to 94.495% when pulling d98a8742bb17043bea98f9b1479f98e18b25a336 on drdavella:fitsname-in-warning into 58fb686601dae42ee4a8eba917fc32546523d8d1 on spacetelescope:master.

LGTM.


Locations

hey, the program doesn't let me write on the location box, I tried to copy paste and still nothing..

this problem is neither there on linux nor on windows in the newest version for me. did you clear your appdata cache and get the newest version?
another question: what does it depend on, whether I see the little globe where I can get the location of a profile, or not? some of them are just "queryable", some not..

I think I noticed that they need to be within your view of guys on the first page, otherwise you won't get a link..
further I noticed that their distance measure must be turned on. But that makes me wondering: Isn't it possible to get the location without distance measurement, if it is (obviously!) based on whether they appear on your "radar" screen? =)

He could be having problems with the distance and location if he had an old version and installed this over it.  When the program was updated, the location settings were slightly modified.  Clearing the appdata would reset everything, but could also clear old chats.
For you to get the globe, the person has to have their "show distance" setting turned on, and then they have to be on the grid of 100, or 600 people, (600 if you have grindr xtra).  If you had someone in chat and it shows the distance, but not the globe, you could try to narrow down, typically by age, tribe, or 'looking for' to get them on the grid, then the globe will show up.
The app uses a triangulate technique to pinpoint, so if there is no distance to base off of, then it may be possible to get a general idea, but ti definitely would not be more than a guess, and I doubt that will get programmed in.  Grindr still has access to the users location, even when it's not shown to other users, as it still sorts everyone on the grid by location, higher on the grid is closer to you, but that is sorted on the back side aka their server, then output to the app, so the front end aka other users don't see it.

@markbosshard @RobbieTechie I just clean the appData and it is working! My problem was writing my location, I couldn't write where I wanted to search. Because of that no one appeared. I had some wierd problems until I get it working, but some appData and temp folder cleaning and it is working almost at 100%. I still cant see where the guys are on the map. But that isn't that important. Thanks for your help!

BTW I have to uncheck/check the "photo only" checkbox sometimes to get profiles appearing as thumbnails (i can't see them on the map mode)

@filisil Grindr updated the code in their servers to check if you are using an xtra or free account, and enforce that.  Before that, the photo and online check boxes functioned, but now they will return an error to the app that those filters could not be applied.  I tried doing a pull request to update some stuff but Thom does not appear to be bothering with working on this app much anymore, so it never was added.  The photo only is a paid filter so it doesn't work and seems to sort of hang the app or cause problems with other bits if it's left on.
@markbosshard I had the filters back in, in the work I did, and also tried to get Thom to do a pull request for those.  I'm not sure if he's just crazy busy, or doesn't want those in or why he didn't bother with it, but the official version off here does not have those put back in yet.
As for people without locations being turned on, I have no intention of attempting to subvert someone who desires that privacy.
@filisil Since this issue has been fixed for you, could you lease close this.  Glad you got it worked out.


Update instructions to describe how  to combine different episodes to change focus of lesson

As discussed in #166
NB: links to an example repo on escience academy. This should be forked to coderefinery github org.

Thank you!


Draft a release note of 0.12.0

Coverage increased (+0.01%) to 52.932% when pulling a690aa2ddececdf4d1d224446d025aed92982f12 on release-0.12/release-note into 0a73b406004c1fc8ef19c3fd7d073170fcfa4738 on pai-0.12.y.


Atlanta Peachtree Race Game

As part of the partnership with Atlanta Track Club, we're modifying Monster Racer (aka.ms/monsterRacer) to be a racing/hurdle game.
We'd need a park tilemap instead of a cave (branches and hurdles instead of spikes and acid), the Atlanta skyline as a background instead of a spooky forest, and maybe an animated running peach instead of the monster truck.  We would also need a new skillmap background,  certificate, and badge.
Please let us know ASAP if you aren't interested and we'll look into getting MeeNa.
See above
Is there a deadline or date this is needed by?
Early to Mid-Feb
Please share any existing references, screenshots, links, etc. here that will help us better understand your requirements
https://www.atlantatrackclub.org/
aka.ms/monsterRacer
Who are the stakeholders that need to sign off on this design? Tag them here.
Kiki, then I will take to clients
What audience is this request for?
External - Atlanta Track Club
What does success look like?
A track-themed skillmap
How will we measure if this is successful or not?
The client will tell us whether or not they're happy

@BeckHaru @soniakandah
Pinging on this. They're wanting to know if they'll need budget for an artist.

We'll let you know today. Thanks for the ping. @kiki-lee

I've gone ahead and replaced all the in-game assets. You can find the project with those here: https://makecode.com/_V6sV3JEcMVwb

Based on those sprites, here are the badges:

And here is the certificate:
Atlanta Peach Racer.pdf

And here's the background I came up with; not animated cause I didn't have enough time unfortunately.

@soniakandah  They're asking if they can get sunglasses on the peach :)

Here are all the updates:
https://makecode.com/_Lo4KYi3vibcY

Atlanta Peach Racer.pdf

This is completed.


MGDOBR-829: Add Data Plane deployment scripts

https://issues.redhat.com/browse/MGDOBR-829
Added the scripts for deploying the Data Plane (shard-operator).
PR owner checklist
Please make sure that your PR meets the following requirements:

[ ] Your code is properly formatted according to this configuration.
Run mvn clean verify -DskipTests so that imports are correctly set.
[ ] Your commit messages are clear and reference the JIRA issue e.g: "[MGDOBR-1] - $clear_explanation_of_what_you_did"
[ ] The layers in the kustomize folder have been updated accordingly.
[ ] All new functionality is tested
[ ] Pull Request title is properly formatted: MGDOBR-XYZ Subject
[ ] Pull Request contains link to the JIRA issue
[ ] Pull Request contains link to any dependent or related Pull Request
[ ] Pull Request contains description of the issue
[ ] Pull Request does not include fixes for issues other than the main ticket

PR reviewer(s) checklist

[ ] Check if code and Github action workflows have been modified and if the modification is safe
[ ] If the modification is safe, add the safe to test label

How to trigger pipelines and use the bots:

Run the end to end pipeline
Annotate the pull request with the label: safe to test. If you want to run the pipeline again, remove and add it again.

Rebase the pull request
Comment with: /rebase.

Deploy BOT
Comment with `/deploy <dev,stable> when the PR has been merged to deploy to a target environment.

Still need to properly set the parameters to the operator deployment.

@winklerm I think we can now close this PR. Do you agree?
cheers,
Rob

Closing this. Feel free to reopen it in case


Feature/issue 56 manage tweet

This a PR for issue #56
https://developer.twitter.com/en/docs/twitter-api/tweets/manage-tweets/introduction

@g8rswimmer I was trying out the example for creating a tweet from the master branch but it appears that the authentication mech used (bearer tokens) won't work with that endpoint I get this error
status 403 Unsupported Authentication:Authenticating with OAuth 2.0 Application-Only is forbidden for this endpoint.  Supported authentication types are [OAuth 1.0a User Context, OAuth 2.0 User Context]

Is it possible to provide an updated example or point out what I might be doing wrong?

I was able to fix the auth issue by using an oauth1 pkg following this issue #15 but after that, the tweet API returned a 400 Invalid Request:One or more parameters to your request was invalid.  I manually tinkered around and saw that the payload being sent in the body had some redundant/optional fields that were not being removed. I have raised a PR for the fix #84 , let me know if any changes are needed.

@gdsoumya thanks for the bug fix.  It would appear that auth 2.0 would need to use PKCE.  That might be an improvement to the examples in the future.


DG-1894 Last Updated Attribute for Custom metadata value now getting updated

Change description

Added ModifiedTimestamp record for entity/guid/{guid}/businessmetadata API flow.

Type of change

[ ] Bug fix (fixes an issue)

Related issues

Fix Ticket

Screenshots

Development

[ ] Lint rules pass locally
[ ] Application changes have been tested thoroughly
[ ] Automated tests covering modified code pass

Security

[ ] Security impact of change has been considered
[ ] Code follows company security practices and guidelines

Code review

[ ] Pull request has a descriptive title and context useful to a reviewer. Screenshots or screencasts are attached as necessary
[ ] "Ready for review" label attached and reviewers assigned
[ ] Changes have been reviewed by at least one other contributor
[ ] Pull request linked to task tracker where applicable

Please add test cases from the perspective of the POST entity/bulk API as well

Please add test cases from the perspective of the POST entity/bulk API as well

I suggest creating a confluence doc so that it can be linked to the ticket as well


Image not displaying on card with AnkiConnect, despite being present. Cut and paste fixes the issue. Why?

I'm running into a weird issue. When I mine a card, I usually use Yomichan for the lookup and card creation, then ASB player for the update card. It captures everything perfectly, but when I preview the card in Anki the image does not show. Despite being present in the card field. If I cut the image to my clipboard, then paste again, it suddenly starts showing up. Why might this be the case ? Is it a known bug?

@elemn There's a known issue with AnkiConnect where cards won't update if the card browser is open. Could this be what is happening for you?

If by card browser you mean clicking browse, where a window pops up, then no I don't believe that's the case. I made sure to close it and the issue remains. Is that known issue exclusive to image media or everything else ? All other information transfers okay. Perhaps this is an issue on the side of my card template? Image format? Any other ideas would be appreciated.
I'm on Linux by the way, AnkiConnect seems to be up to date and I have the latest version of ASBPlayer installed on Chrome.

Update: I looked in the CSS (not mine), and this line seems to have something to do with it : .images br, .images> :not(img) {     display: none;     visibility: hidden; }

@elemn asbplayer wraps the img in a div so that's probably why.


Proper handling of UTF-8

This PR has a bunch of modification in it, in short, it fixes UTF-8 issues #161.
Here a a summary of what has been done:

use a dedicated struct to manipulate string (LineBuffer) to avoid splitting inside UTF-8 code points
Console::write does not take bytes anymore but a string slice to ensure proper UTF-8 data is sent to the console
sdl & web implementation of write_wrapped do not manipulate bytes anymore but are using LineBuffer instead. This  ensures correct line length & line splitting while wrapping
sdl console rendering use the render method instead of the render_latin1 method to properly render UTF-8 strings.

I did not test the web version as I do not know how to run it ;)

I did not test the web version as I do not know how to run it ;)

I've tested it and it works as expected.

Thanks so much for this contribution, and again apologies for the delay.
I've recreated your PR as #175 because I had to resolve merge conflicts. In the process, I squashed some of the commits against some others to come up with a cleaner set of changes, but I tried to preserve the same sequence in spirit. I've also adjusted comments to better match existing style of wording and punctuation and done some other small-ish changes.
The web UI seems to work fine for Spanish characters, but I'm still trying to convince Windows to give me IME for Korean and do some extra validation. And I'll have to also adjust the SDL tests to do some UTF-8 rendering. Hope to merge this soon now.


Feature Request: Example mono repo code base

I would like to request examples of the ways that sphinx-collections can be used in a real monorepo.
Maybe an actual example of a monorepo being documented.
For example, see the example project here which is pretty close:
https://github.com/backstage/mkdocs-monorepo-plugin/tree/master/sample-docs

I totally agree, we need some kind of a real-life example.
But in my understanding, I would not combine it with the keyword "monorepo", as menorepo does not tell anything about how the documentation is structured. It still can be in a single folder, or in multiple.
For me, it's more about central or distributed documentation, where distributed documentation has multiple locations, where doc-parts are stored.
These parts can all be in a monorepo or in different repositories or just in different local folders or in a database and a script downloads them and creates files out of it or ...
So sphinx-collections is designed to give the user a free choice of how the documentation is structured.
It just allows to collect the different parts into a joint, single folder-structure during the build.
But yes, a folder as an example inside this repo would be great. This could also be used then for test-cases :)

Hi,
Thanks for the reply.
Instead of monorepo, what if we describe a particular repo structure as a large repository structure that follows PEP 420?

I would simply have a central /docs/ folder and multiple documentation under the related sub-project: /project_a/docs/.
All the subproject-docs are complete Sphinx projects and can be built on their own.
We use Sphinx-Collection on the central /docs folder to copy/link the subproject-docs together.
So for the build, it may be:
/docs
  - index.rst
  - conf.py
  - project_a/
     - index.rst
     - .. other files
  - project_b/
     - index.rst
     - and so on

Thanks for the reply and info.

What are some examples of .. other files in your example above? static content such as css, images, etc.?

What if the large codebase looks like this and I would like to auto-generate an API reference with autodoc for all of the projects along with including README files which live in their respective projects directories where the source code lives?

/monorepo
  - /project_a
      - README.md
      - src/
      - .. other files
  - /project_b
      - README.md
      - src/
      - .. other files
  - /project_c
      - README.md
      - src/
      - .. other files
  - /project_d
      - README.md
      - src/
      - .. other files

Would the docs folder structure still be as you stated (note that docs is at the same level as project_a, project_b, etc. source directories?
/root
  /docs
    - index.rst
    - conf.py
    - project_a/
      - index.rst
      - .. other files
    - project_b/
      - index.rst
      - and so on
  /project_a
    - README.md
    - src/
    - .. other files
  /project_b
    - README.md
    - src/
    - .. other files

other files can be anything. But mostly I was talking about md/rst files/folders storing other chapters.
But for sure images and co. can be there as well.
source-files can be kept in the original folder. No need to copy them to the final "central" doc folder.
Just make the project-folder aware to automodule by adding them to the Python-Path.
I don't know how you want to use README.md inside your Sphinx under /docs. That's up to you.
I'm also not sure in which status your above folder-structure is shown.
Is it the one how it is stored in git? So the docs of project_a are really stored outside the main project_a folder?
Or is it the way the final build folder under /docs shall look, but will not be committed to git.
Sphinx-Collections creates a temporary folder structure during the build. So it mostly copies documents outside of /docs somewhere into /docs. So it doubles the files, but just for the build. Afterward the copied files under /docs get deleted again to keep the workspace clean.


Add a windows test

This adds a configuration for windows + node 14 for the github test action. I had to upgrade node-sass because version 4.13.1 does not provide a version for windows and node 14 but version 5.0.0 does. And then sass-loader had to be upgraded to a version compatible with node-sass 5.0.0

I approve! But I also accidentally merged this PR, so it's all good!

I approve! But I also accidentally merged this PR, so it's all good!


Bug: 'Special' characters in a symbolic link cause an error "Fatal error: Uncaught Error: Class 'App\Config' not found"

PHP Version
7.4
CodeIgniter4 Version
4.2.1
CodeIgniter4 Installation Method
Composer (using codeigniter4/appstarter)
Which operating systems have you tested for this bug?
Windows
Which server did you use?
apache
Database
MySQL 8.0.21
What happened?
Error message "Fatal error: Uncaught Error: Class 'App\Config' not found" on fresh install
Steps to Reproduce
Just install using composer in a folder containing a symbolic link in the path containing 'special characters'.
In my case the path was D:\Dropbox (Dubbel 16).
Removing the brackets solved the issue, but is in fact a workaround.
Expected Output
See the welcome page
Anything else?
Bug has been reported on StackOverflow: https://stackoverflow.com/a/72825733/760777 with the possible workaround.
The problem is probly caused by using the function file_exists. It returns FALSE when containing a symbolic link with certain characters.

See #6192 .

Thank you for reporting, but as datamweb pointed out, this is not a bug.
See the note:
https://codeigniter4.github.io/CodeIgniter4/installation/installing_composer.html#installation-set-up


Android deviceManager.js emulatros typo

https://github.com/pavjacko/renative/blob/d00c1ff03dbe2aacc751f4afcc343298c7023a2f/packages/rnv/src/platformTools/android/deviceManager.js#L504

@TheDuc thx for pointing up :) fixed in upcoming 0.29.0

Thanks!


Image carousel is glitchy on swipe

If you haven’t already, check out our contributing guidelines for onboarding and email<EMAIL_ADDRESS>to request to join our Slack channel!

Coming from this comment: https://github.com/Expensify/App/pull/9279#issuecomment-1419797717
Action Performed:

On iOS or android, open a chat with several attachments
Tap on an attachment
Swipe left and right on attachments
Notice that the image resizes/flickers on swipe but not when using the arrows

Expected Result:
No image resize/flicker on swipe
Actual Result:
Image resizes/flickers on swipe
Workaround:
Can the user still use Expensify without this being fixed? Have you informed them of the workaround?
Platforms:

Which of our officially supported platforms is this issue occurring on?

[x] Android / native
[ ] Android / Chrome
[x] iOS / native
[ ] iOS / Safari
[ ] MacOS / Chrome / Safari
[ ] MacOS / Desktop

Version Number:
Reproducible in staging?:
Reproducible in production?:
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Notes/Photos/Videos: Any additional supporting documentation
Expensify/Expensify Issue URL:
Issue reported by:
Slack conversation:
View all open jobs on GitHub

Triggered auto assignment to @garrettmknight (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

Bug0 Triage Checklist (Main S/O)

[ ] This "bug" occurs on a supported platform (ensure Platforms in OP are ✅)
[ ] This bug is not a duplicate report (check E/App issues and #expensify-bugs)

If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead

[ ] This bug is reproducible using the reproduction steps in the OP. S/O

If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
If the reproduction steps aren't clear and you determine the correct steps, please update the OP.

[ ] This issue is filled out as thoroughly and clearly as possible

Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.

[ ] I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync

@luacmartins Having trouble reproducing on iOS v1.2.88-1. Images take a bit to load and I see a spinner, but no flicker. Can you confirm the version and maybe include a vid if possible?


Remove message dialog appearance during loading

Delete the dashboard/alert count message when the spinner is showing during loading.

Current coverage is 36.39% (diff: 100%)

Merging #157 into develop will decrease coverage by 0.02%

@@            develop       #157   diff @@
==========================================
  Files           257        257
  Lines         13869      13869
  Methods           0          0
  Messages          0          0
  Branches       2326       2326
==========================================
- Hits           5051       5048     -3
- Misses         8111       8114     +3
  Partials        707        707

Powered by Codecov. Last update ab3230b...0c0ffb2


Update for CUDA 12.1.1

xref: https://github.com/conda-forge/cuda-feedstock/issues/11

Seeing this error on CI:
conda_build.exceptions.OverLinkingError: overlinking check failed
['  ERROR (cuda-nvcc-dev_linux-64,targets/x86_64-linux/bin/nvcc): /lib64/libpthread.so.0 not found in packages, sysroot(s) nor the missing_dso_whitelist.\n.. is this binary repackaging?', '  ERROR (cuda-nvcc-dev_linux-64,targets/x86_64-linux/bin/nvcc): /lib64/libm.so.6 not found in packages, sysroot(s) nor the missing_dso_whitelist.\n.. is this binary repackaging?', "  ERROR (cuda-nvcc-dev_linux-64,targets/x86_64-linux/bin/nvcc): .. but ['libgcc-ng'] not in reqs/run, (i.e. it is overlinking) (likely) or a missing dependency (less likely)", '  ERROR (cuda-nvcc-dev_linux-64,targets/x86_64-linux/bin/nvcc): /lib64/libc.so.6 not found in packages, sysroot(s) nor the missing_dso_whitelist.\n.. is this binary repackaging?', '  ERROR (cuda-nvcc-dev_linux-64,targets/x86_64-linux/bin/nvcc): /lib64/ld-linux-x86-64.so.2 not found in packages, sysroot(s) nor the missing_dso_whitelist.\n.. is this binary repackaging?']

This happens when...
Packaging cuda-nvcc-dev_linux-64

Think we need to add {{ compiler("c") }} to cuda-nvcc-dev_{{ target_platform }}'s requirements/build section to resolve the overlinking error

@conda-forge-admin, please rerender

Following up on the error above, Alex tried adding {{ compiler("c") }} to cuda-nvcc-dev_{{ target_platform }}'s requirements/build, but it didn't work. Our guess is that run_exports don't work correctly with noarch
Given this, we could try just adding the run_exports dependencies directly to requirements/run. In that case think we want libgcc-ng would make sure to provide a lower bound version constraint on it that is consistent with our gcc_impl_{{ target_platform }} constraint. The upper bound is unneeded


Adding section on configuring user attributes

Adding documentation for user attributes in the services management webapp.

Coverage remained the same at 45.702% when pulling 6887e1aa9cf59c787132b6dcfda1330e980c9911 on jtgasper3:patch-3 into c8c2ad8dd5e8edb02cc6c9cb9c2b0a78b4fbafcf on apereo:master.


Hello World - popper text overwrites reference until resize

I feel foolish like I'm missing something essential.
Codepen test case

Hello

var reference = document.querySelector('.myReference');
new Popper(reference, {content: 'World'}, {placement: 'right'})

Is there a recommended baseline css to use with this for placement?  I'm threw in the popper.css from the popper.js.org site and it's closer.

It looks like minimally, if you don't have the following, you'll see this behavior:
.popper {
  position: absolute;
}

Seems like a problem with the first update, if you then scroll or resize the window, it works properly.

Still no solution about this issue ?

I need a free weekend to work on it, still had no time :/
A PR is welcome tho

Fixed the problem.
The position of the popper element wasn't set before the computations performed by the first .update(). Now I set the position before everything else, so we are sure the update works properly.


add cilium-operator restart to cluster mesh getting started guide

discussed here: https://cilium.slack.com/messages/C1MATJ5U5/
Note: something to consider for a subsequent PR: automating the whole cluster mesh getting started guide with a script, such as https://github.com/admiraltyio/multicluster-scheduler/blob/master/test/e2e/cilium.sh

This change is

Coverage increased (+0.004%) to 42.579% when pulling cf427bcce8e35afa07f4a70969db0f5a8eb56b15 on adrienjt:patch-1 into 720316a724bfa8c4ed99584db446dc33911bf037 on cilium:master.

test-docs-please


Is this module not available on bower?

Is this module not available on bower?
bower install angular-fixed-table-header says package not found.

No I haven't published it anywhere.

Can you please publish it? It will be easier for us to use.
And Thanks for this very useful module..!!

@Dhara-ZYMR You can still install it through bower using a Git endpoint.
e.g. bower install https://github.com/daniel-nagy/fixed-table-header.git --save

This module should be available on Bower now.


Error

Traceback (most recent call last):
File "C:\Users\Administrator\Desktop\Gmail-Generator-Python-main\source\gmail_generator.py", line 188, in
if open_firefox() :
File "C:\Users\Administrator\Desktop\Gmail-Generator-Python-main\source\gmail_generator.py", line 48, in open_firefox
location=pyautogui.center(start_button)
File "C:\Python310\lib\site-packages\pyscreeze_init_.py", line 582, in center
return Point(coords[0] + int(coords[2] / 2), coords[1] + int(coords[3] / 2))
TypeError: 'NoneType' object is not subscriptable

have you installed the required pips?


Add FrontEnd Masters Guides

What does this PR do?
Add resource(s)
For resources
Description
Why is this valuable (or not)?
Ensure adds resources found at https://frontendmasters.com/guides/
How do we know it's really free?
CC-BY-3
For book lists, is it a book? For course lists, is it a course? etc.
Books/Guides with exercises to track front-end web development discipline using HTML5, CSS, Javascript...
Checklist:

[x] Read our contributing guidelines
[x] Search for duplicates.
[x] Include author(s) and platform where appropriate.
[x] Put lists in alphabetical order, correct spacing.
[x] Add needed indications (PDF, access notes, under construction)

Follow-up

Check the status of GitHub Actions and resolve any reported warnings!

thanks!


I should be able to browse a curated list of merchants

Detailed Description
I should be able to browse a curated list of merchants.
The listing should be populated from a remote data feed.
Each merchant should display as a card.
The listing should have a basic search widget.
The page should display in a full screen modal.
It should be accessible from a new Autopay entry in the the wallet menu.
Context
Autopay
Possible Implementation
https://zpl.io/bAZdRrq

Closed via https://github.com/LN-Zap/zap-desktop/pull/1795


Might want to update this to the new Particle branding

Agreed, we missed this one - also needs to be updated with new repos. Thanks @nolanhergert!

done, thanks @nolanhergert!


Appropriate menu placement

The Eclipse menus are very heavy, there is a lot of items. That is why menus group items into submenus. And, there is a special "Open With" or "Show In" group for opening extensions like this. I think it had to be reused. "Copy resource path into clipboard" does not fit this category indeed. But, it is not that necessary since Eclipse is the Number One IDE in providing user access to resource path info. Just click Properties item, right next to your StartExplorer.
Originally submitted by valentin tihhomirov ( valtih1978 ) on 2012-01-23 01:53:41 PST via project's former sourceforge site.

Originally posted by me on 2012-02-09 13:13:17 PST on project's former sourceforge tracker
.
I think I can agree with what you say about the menu placement. With one
exception: I really like to have the Copy resource path to clipboard
option. Clicking Properties and then fumbling with the Properties dialog to
manually selecting and copying the resource path is just a bit to
inconvenient for my taste. Of course, that's really a matter of taste.
I'll think about that, but to be honest, it's quite low on my priority
list.
If you are interested, you are of course welcome to provide a patch :-))
Regards
Bastian


Add Markdownlint-rule Max 1 Sentence Per Line

Description
Having a consistent style for Markdown files helps contributors and maintainers.
Currently, we're only checking for line length, but that doesn't mean it is easy to work with the documentation, moving around sentences etc. is hard with punctuation in the middle of a line, etc.
Issue
There is a markdown-lint rule, which limits the amount of sentences to max one per line - https://github.com/aepfli/markdownlint-rule-max-one-sentence-per-line
as an example:
This is a markdown example where we are working with a certain line limit,
specially with our currently configured one.
This line limit is set to 120 and allows us for a limited line length.
If this is suitabl or not is questionable,
as we can easily use `soft-wrap` which is supported by any kind of tool.
Hence that, why not focus more on one sentence per line.

and
This is a markdown example where we are working with a certain line limit,
specially with our currently configured one. This line limit is set to 120 and
allows us for a limited line-length. If this is suitabl or not is questionable,
as we can easily use `soft-wrap` which is supported by any kind of tool. Hence
that, why not focus more on one sentence per line.

are both the same when rendered. But the first one is easier to maintain, as you can rearrange sentences more easily.
Additionally, one sentence per line, is also something, which is nice to read.
This is a markdown example where we are working with a certain line limit, specially with our currently configured one.
This line limit is set to 120 and allows us for a limited line length.
If this is suitabl or not is questionable, as we can easily use `soft-wrap` which is supported by any kind of tool.
Hence that, why not focus more on one sentence per line.

Note this rule those not enforce one sentence per line, it is maximum one sentence per line, which allows more specific breaking if needed and depending on the contributor.
Proposal
Usage of https://github.com/aepfli/markdownlint-rule-max-one-sentence-per-line
Problems
There is only one docker image containing this rule out of the box and it is within davidanson/markdownlint-cli2-rules:next hence that we would need to swap also to markdownlint-cli2 instead of markdownlint-cli.
Possible problems with IDE Integrations
It might be that eg. the VS code extension for markdownlint, does not like the new kind of configuration, because of the missing rule (it is in the docker image but not within the project)
We should provide a functionality or a guide within our readme on how to handle this.

[ ] lets discuss this approach
[ ] how do we want to handle IDE integration, or do we want to do this afterwards?

I like this!  I actually favor breaking out clauses and phrases onto separate lines in some cases but I wouldn't want checking for that.

https://github.com/keptn/lifecycle-toolkit/pull/1031/ is a draft showing what would change - not everything is optimal, specially as some breaks seem to be disturbing now


Need more information on 'Usage' section

The part explaining the usage of Swagger Converter is not very informative. I had troubles figuring out both the installation ways mentioned. For npm, I wasn't sure where to put those javascript statements. Then I realized I need a node to implement that, which I dont have. For the other one, with browser.js, I am still not able to get the desired result. Maybe I am calling the method incorrectly: var convert = SwaggerConverter.convert; ...... I am including this call in index.html of Swagger UI.

Swagger-converter is used in swagger-tools and you can see how to use it at https://github.com/apigee-127/swagger-tools/blob/master/docs/API.md#convertresourcelisting-apideclarations-skipvalidation-callback

Well this page should be referenced on the page for Swagger-Converter. I read the link you gave, it looks like all examples were for coding in Node.js. Is there an example on how to do it using browser.js ?

You need to have all swagger files in plain-old JavaScript objects and pass the root swagger object as first arguments and an array of objects (which are your other swagger files)  as second arguments. Please let me know what error you're getting when you're trying that

Oh ok. I have Swagger resource files in JSON (spec 1.2) as is required by the Swagger UI. I thought this utility will help generate JSON files which comply with Swagger 2.0 spec given the spec 1.2 JSON files. I think I am mistaken here. Is it ?

First, parse the JSON strings to get the objects out.
Your resources files which you have as JSON should be passed as an array of objects and for the first argument send the main swagger file object.
For example if I want to convert petstore example I need to do the following
Download and parse file at list resources (root file)
Download and parse all resources files and push it to

Same problem. The description is really not informative at all. It will be really great if we can get a step by step usage information (which doesn't assume any technical knowledge).

@shubhamchaudhary Your usage here at https://github.com/apigee-127/swagger-converter/issues/15 is correct.

I was able to use swagger-converter in swagger-tools without any issue based on the README.  It's a very simple API that is pretty well documented.  (The example in the README is spot on and the API arguments are documented there too.)  If you're wanting to have a CLI for converting Swagger 1.2 to Swagger 2.0, check out swagger-tools.  Otherwise, I don't see how else to make the README any simpler in my opinion.

Thank for the explanation mohsen1. I understand it. But actually I am working in Java codebase and thought to implement it there. I don't have Node.js. When I saw the following code, I thought I could implement this in the index.html of the Swagger UI and get the UI working with spec 2.0:
Include the browser.js script in your HTML

Use the script
var convert = SwaggerConverter.convert;

I've never used it in browser but there is nothing stopping it working in browser. What error are you getting?


Remove V2 EOL date

@Jann-Skotdal : Thanks for your contribution! The author, @v-pawal, has been notified to review your proposed change.

Hi @Jann-Skotdal - Microsoft authors should make updates to content through the private repository so the updates can be staged and validated by the validation rules. See this article for more information. We'll close this PR. Thank you.

@GitHubber17 - I am currently working off network for the Translator team. I do not have access to the private repository. Please reopen the PR so that it can be approved by @v-pawal. I have informed her of the changes I made. Thank you.

@v-pawal - Would you follow the instructions in the Contributor Guide to Link your GitHub and Microsoft accounts? The linked accounts will enable us to assign this PR to you for review. Thank you.

#sign-off


Settings up mac for development

NOTE: A similar PR may already be submitted! Please search among the Pull request before creating one.
Types of Changes
What types of changes does your PR introduce? Put an x in all boxes that apply

[x] New addition to list
[ ] Fixing bug in existing item in list
[ ] Removing item from list
[ ] Changing structure (organization) of list

Proposed Changes
Describe each of your changes here to communicate to the maintainers why we should accept this pull request.

If you're adding something to the list, be sure to explain why it should be added.
If you're fixing a bug or resolving a feature request, be sure to link to that issue.

PR Checklist
Put an x in the boxes once you've completed each step. You can also fill these out after creating the PR. If you're unsure about any of them, don't hesitate to ask. We're here to help! This is simply a reminder of what we are going to look for before merging your code.

[x] I have read the CONTRIBUTING guide
[x] I have explained why this PR is important
[x] I have added necessary documentation (if appropriate)

Further Comments
If this is a relatively large or complex change, kick off the discussion by explaining why you chose the solution you did and what alternatives you considered, etc...

You may need to setup up your brand new Mac or after purchasing a used one with factory reset for software development purposes

This is not a software @Gudrum


Migrate existing shared tasks from apps to shared gradle plugin

@nasthagiri please review. I'm happy to walk through it with you. Groovy/gradle are super bizarre. Also, this PR might be slightly out of context since PRs will need to follow that actually integrate this with the per app build scripts.

cc @BenjiLee

@aleffert @nasthagiri Maybe we should have a quick walkthrough meeting (10 mins)?

@hanningni fyi, this is some in progress work to make the apps share a common gradle plugin. It still needs to reviewed, but maybe we can all go through it tomorrow.

@aleffert  sure.

@hanningni @BenjiLee now that we've gone over this, could you please review?

LGFM

:+1:

@BenjiLee please review

:+1: Looks groovy.


MarkdownSanitizer sanitizes URLs

General Troubleshooting

[X] I have checked for similar issues on the Issue-tracker.
[X] I have updated to the latest JDA version
[X] I have checked the branches or the maintainers' PRs for upcoming bug fixes.

Expected Behaviour
Discord treats URLs (almost) as literals, even URLs with Markdown characters in them.
Consider the following Google search:
https://www.google.com/search?q=__test__
Although the string __test__ is Markdown for underlined text, because it's part of a URL, Discord leaves it as-is.
JDA's MarkdownSanitizer does not make the distinction between URLs and normal text, so JDA escapes this URL:
https://www.google.com/search?q=\_\_test\_\_
When trying to send this URL as a Discord message, Discord replaces the backslashes with forward slashes but doesn't apply Markdown rules, including escaping, so the end result is the broken URL https://www.google.com/search?q=/_/_test/_/_.
I expected JDA's Markdown handler to leave URLs as-is.
Code Example for Reproduction Steps
//add this to the EscapeMarkdownTest class in src/test/java/MarkdownTest.java
//all of the assertions except the first fail
@Test
public void testUrl()
{
	Assertions.assertEquals("https://www.google.com/", markdown.compute("https://www.google.com/"));
	Assertions.assertEquals("https://www.google.com/search?q=_test_", markdown.compute("https://www.google.com/search?q=_test_"));
	Assertions.assertEquals("https://www.google.com/search?q=__test__", markdown.compute("https://www.google.com/search?q=__test__"));
	Assertions.assertEquals("https://www.google.com/search?q=*test*", markdown.compute("https://www.google.com/search?q=*test*"));
	Assertions.assertEquals("https://www.google.com/search?q=**test**", markdown.compute("https://www.google.com/search?q=**test**"));
	Assertions.assertEquals("https://www.google.com/search?q=***test***", markdown.compute("https://www.google.com/search?q=***test***"));
	Assertions.assertEquals("https://www.google.com/search?q=~~test~~", markdown.compute("https://www.google.com/search?q=~test~"));
}

Code for JDABuilder or DefaultShardManagerBuilder used
N/A

Exception or Error
N/A

I'm willing to take a shot at this issue, but I'd like to discuss the correct way to approach it first.
The current entities in MarkdownSanitizer are represented by simple tokens or by regex. Parsing URLs with regex is an unpleasant problem, and I would probably have to roll my own regex since I'm unsure of licensing (and correctness) implications if I grab one from somewhere else on the internet.
Java does have a URL parser, but its implementation seems like a bad fit for this use case, since I'd have to construct a new URL and potentially catch an exception (MalformedURLException) on every possible text sequence.
I could explore a hybrid approach, with a regex to detect possible leading URLs in a sequence (i.e. in the text sequence https://www.google.com?q=~~test~~ some other text here, each space indicates the end of a potential URL) and feed those potential URLs to java.net.URL for validation.
I'm open to any other ideas.

I am currently giving this issue a shot. This is somewhat complicated as previously suggested, but as long as the programme detects and URL, replaces it with a placeholder and changes it back after the algorithm, it should work correctly.
I would be able to make a pull request tomorrow.

For the final assertion in that test method, I think you may have made a mistake: the expect result should be the URL with only one layer of "~" wrapped around the word "test" in the url, not two.


Vulnerability roundup 111: clamav-0.103.3: 1 advisory [7.5]

search, files

[ ] CVE-2022-20698 CVSSv3=7.5 (nixos-unstable)

CVE details
CVE-2022-20698
A vulnerability in the OOXML parsing module in Clam AntiVirus (ClamAV) Software version 0.104.1 and LTS version 0.103.4 and prior versions could allow an unauthenticated, remote attacker to cause a denial of service condition on an affected device. The vulnerability is due to improper checks that may result in an invalid pointer read. An attacker could exploit this vulnerability by sending a crafted OOXML file to an affected device. An exploit could allow the attacker to cause the ClamAV scanning process to crash, resulting in a denial of service condition.

Scanned versions: nixos-unstable: 5aaed40d22f.
Cc @fpletz
Cc @globin
Cc @qknight
Cc @robberer

Already fixed in #155019 (unstable) and #155040 (21.11)


Compute connected components in factor generation

Required for BI query variant Q20a: https://github.com/ldbc/ldbc_snb_bi/issues/77

Fixed by #415


Missing information

Please add a message saying that this is the old repo and with a link to v4 location. Lot's of people is still using this one.

Done! Active development of our Python SDK has moved to https://github.com/Azure/azure-sdk-for-python. README has been updated.


Add handling for more naga capabilities

Objective
Following on from https://github.com/bevyengine/bevy/pull/4824, this MR adds the capabilities for:

MULTISAMPLED_SHADING
TEXTURE_FORMAT_16BIT_NORM
MULTIVIEW
EARLY_DEPTH_TEST

Solution
RenderAdapter is passed down, and then downlevel flags are translated into capabilities that are passed into wgpu.
shader_prepass example has been changed to show that multisampled shading now works, by adding a controller for MSAA. The text color changes have also been removed, as otherwise the text couldn't be seen on the motion vectors screen.

Changelog
Added support for more naga capabilities.
Migration Guide
PipelineCache::new now takes a RenderAdapter.

Resolved changes with #5703

@IceSentry Thanks for the response - I've just fixed the merge conflict.

This will be superseded by https://github.com/gfx-rs/wgpu/pull/5606 once we upgrade to wgpu 0.20 #13186.

@JMS55 should we pursue this or simply close it out in favor of the linked PR?

Close it in favor of the wgpu update PR, but we have to remember to make the change in that PR.


The DEFAULT_SQL of JdbcEnvironmentRepository

The DEFAULT_SQL of JdbcEnvironmentRepository is "SELECT KEY, VALUE from PROPERTIES where APPLICATION=? and PROFILE=? and LABEL=?".  The KEY column is mysql's keyword , execute this sql will get an error "You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'KEY, VALUE from PROPERTIES where APPLICATION='testing' and PROFILE='dev' and LAB' at line 1".
Thanks a lot .

You can change the SQL using spring.cloud.config.server.jdbc.sql

I was changed it using the "spring.cloud.config.server.jdbc.sql" .


Instructions: Migration to v2 GPIO API

I've been working on converting to the new V2 GPIO API. It was confusing at first how to migrate so this may help some folks:

Remove define_pins! macro from your lib.rs file
Include this at the top of your example/main use hal::gpio::v2::Pins; (where halis extern crate <your board> as hal;
Then access the pins as shown in the documentationlet pins = Pins::new(peripherals.PORT);
let mut red_led = pins.pa23.into_push_pull_output();

I could be wrong here so any additions would be great.

Another thing that I needed to get working is USB. I'm using an SAMD21 so /hal/src/samd21/usb/mod.rs needs to be tweaked:
//! USB Device support

#[cfg(not(feature = "unproven"))]
use crate::gpio;
#[cfg(feature = "unproven")]
use crate::gpio::v2::{AlternateG, Pin, PA23, PA24, PA25};

pub use usb_device;

mod bus;
pub use self::bus::UsbBus;

mod devicedesc;
use self::devicedesc::Descriptors;

/// Emit SOF at 1Khz on this pin when configured as function G
#[cfg(feature = "unproven")]
pub type SofPad = Pin<PA23, AlternateG>;
#[cfg(not(feature = "unproven"))]
pub type SofPad = gpio::Pa23<gpio::PfG>;

/// USB D- is connected here
#[cfg(feature = "unproven")]
pub type DmPad = Pin<PA24, AlternateG>;
#[cfg(not(feature = "unproven"))]
pub type DmPad = gpio::Pa24<gpio::PfG>;

/// USB D+ is connected here
#[cfg(feature = "unproven")]
pub type DpPad = Pin<PA25, AlternateG>;
#[cfg(not(feature = "unproven"))]
pub type DpPad = gpio::Pa25<gpio::PfG>;

This is merely a bandaid until all projects/examples can move to the v2 API. Similar to what's propose in #362
In my BSP lib.rs I've changed the usb_allocator function to:
use hal::gpio::v2::{Floating, Input, Pin, PA24, PA25};

...

#[cfg(feature = "usb")]
pub fn usb_allocator(
    usb: pac::USB,
    clocks: &mut GenericClockController,
    pm: &mut pac::PM,
    dm: Pin<PA24, Input<Floating>>,
    dp: Pin<PA25, Input<Floating>>,
) -> UsbBusAllocator<UsbBus> {
    let gclk0 = clocks.gclk0();
    let usb_clock = &clocks.usb(&gclk0).unwrap();

    UsbBusAllocator::new(UsbBus::new(
        usb_clock,
        pm,
        dm.into_alternate(),
        dp.into_alternate(),
        usb,
    ))
}

Hope this helps folks change things over so they can use DynPin etc.

@jaredwolff, thanks for this. I haven't gone through it all, but you point out something valid. We should definitely have migration instructions. Maybe we can add it to the docs.
Over the long weekend, I want to go through this and the work from @ryankurte. If either of you have any feedback on v2, please let me know. I don't think it's too late to make changes.

Maybe we can add it to the docs.

Happy to help where I can. :)

If either of you have any feedback on v2, please let me know. I don't think it's too late to make changes.

One thing I've noticed, thus far, is there's no open drain output as before. That would be handy to have especially if you only need to drive the N-side. I haven't looked at the data sheet so I'm not sure if this is a specific mode or its basically putting the pin back into floating input when not being driven.
After going through the above I finally was able to collect my pins and use them as DynPin the jury is still out on that. So far so good though.
Is it possible to read and write directly to the PORT as well? That's also immensely useful if you don't want to define a bunch of pins then end put put side by side in an array.
Also, as mentioned earlier, some way to alias the pins would be great. I was also thinking about somehow when creating the   stand alone enums that there could be type definitions for all trait combinations? Right now I'm using a separate file where I'm defining the pin types for use across the firmware:
use hal::gpio::v2::{Output, Pin, PushPull, PA17, PA22, PA23, PB14};

pub type LedPassT = Pin<PA23, Output<PushPull>>;
pub type LedFailT = Pin<PA22, Output<PushPull>>;

pub type PsEnT = Pin<PB14, Output<PushPull>>;
pub type VbatEnT = Pin<PA17, Output<PushPull>>;

It's handy especially when using something like rtic. (Here's what my Resources looks like:
#[rtic::app(device = hal::pac, peripherals = true)]
const APP: () = {
    struct Resources {
        bus_allocator: &'static UsbBusAllocator<UsbBus>,
        usb_serial_port: SerialPort<'static, UsbBus>,
        usb_dev: UsbDevice<'static, UsbBus>,
        p: Producer<'static, Command, U8>,
        c: Consumer<'static, Command, U8>,
        led_pass: types::LedPassT,
        led_fail: types::LedFailT,
        ps_en: types::PsEnT,
        vbat_en: types::VbatEnT,
        test_pins: Vec<DynPin, U23>,
    }

I'll likely do a write up, at the very least, about using atsamd-hal with rtic. I'd love to add some rtic examples once a BSP solution has been sorted out. 👍
This is me spitballing though. I've been pouring through here for the past few days straight. Take what you want and ignore the rest. Thanks for all your hard work on this. Getting the blinky LEDs and USB serial working made my weekend.

The SAM chips don't actually have open drain outputs. That's something I realized when writing v2. In fact, if you look at the old v1 code, you can see that push pull and open drain use the same settings. I think the original version of gpio must have been copypasta from another chip.

I was also thinking about somehow when creating the stand alone enums that there could be type definitions for all trait combinations?

Sorry, I'm not sure what you mean by this. What enums? And what trait combinations?

I think the original version of gpio must have been copypasta from another chip.

Got it. I figured as much as well.  If someone wants to drive it like an open drain they can always set it to floating input and then back to an output I suppose. I'm looking at how the GPIOs get converted here Probably not worth the extra effort to create a new trait or extra handling in the set_high()/set_low() methods. If I do find myself needing it more I'll tinker to see if I can come up with something.

Sorry, I'm not sure what you mean by this. What enums? And what trait combinations?

Sorry, let me explain better. When the define_pins macro is called it generates the PAXX enums. Maybe it's not the best place but having all the different types defined of a pin may be useful. Otherwise someone has to go in manually and create the types. (This is more painful when the board pins are aliased. It kinda negates the whole purpose of an alias)
For example:
I can create this guy and use it throughout my code. It's handy for making the pins static variables that can be modified anywhere in the code.
pub type LedPassT = Pin<PA15, Output<PushPull>>;

Then used later like:
struct Resources {
    led_pass: types::LedPassT,
}

This gets hairy when you have to go back and look at what the pin was defined as in the BSP (originally before the v2 changes):
pin led_pass = a15,

So later if I wanted to use Pins.led_pass I'd have to go back, look up led_pass and define it manually everywhere or create a type like LedPassT. This is particularly applicable to rtic but applies if you want to create/define any mutable static variable for controlling GPIOS. (Unless I'm missing something here)
I hope that made sense!

@jaredwolff, a few comments:

This is merely a bandaid until all projects/examples can move to the v2 API. Similar to what's proposed in #362

I just added a comment to #362. Now that v0.12 has been released, there are implementations of From between v1 and v2 pins. If you want to support both versions, you can make the type generic with a bound like Into<Pin<PA24, AlternateH>>.

Is it possible to read and write directly to the PORT as well?

The v2::Pins struct has a port method that will give you a reference to the PORT. It's unsafe, but it should be useful as an escape hatch, if you need it.
You can also use the free method. However, I just now realized that it won't work the way I thought it would. When I wrote it, I thought you could move pins out of the Pins struct, then call free to get the PORT and use it to control the remaining pins. But I realized just now that moving some of the pins out of the Pins struct will mean you can't call free, because it takes ownership of the Pins struct, which has been partially moved. If you need an owned PORT, you probably want to steal the peripherals and take it from there.

If someone wants to drive it like an open drain they can always set it to floating input and then back to an output I suppose.

That's an interesting idea. I wouldn't really call that open drain. It's more like a software emulated tri-state buffer. But it still might be useful. I would probably design that as a feature built on top of the gpio module. You could create a struct that holds a pin and manages its state for you.

When the define_pins macro is called it generates the PAXX enums.

As mentioned in #364, I think the unfortunate naming coincidence is causing some confusion here. The v2 define_pins macro is not meant for users. It's purely a one-time-use, internal macro used to prevent code repetition.
It sounds like you want the BSP to define type aliases for each pin in the corresponding mode for its use, e.g. LedPass in your example. I'll try to create a new define_pins macro that also allows you to create type aliases like that. It probably won't save much typing for BSP authors, but at least it will be there as a way to encourage them to add the type aliases.
I think that addresses all of your questions. Did I miss anything?

@jaredwolff, a few comments:

This is merely a bandaid until all projects/examples can move to the v2 API. Similar to what's proposed in #362

I just added a comment to #362. Now that v0.12 has been released, there are implementations of From between v1 and v2 pins. If you want to support both versions, you can make the type generic with a bound like Into<Pin<PA24, AlternateH>>.

Is it possible to read and write directly to the PORT as well?

The v2::Pins struct has a port method that will give you a reference to the PORT. It's unsafe, but it should be useful as an escape hatch, if you need it.
You can also use the free method. However, I just now realized that it won't work the way I thought it would. When I wrote it, I thought you could move pins out of the Pins struct, then call free to get the PORT and use it to control the remaining pins. But I realized just now that moving some of the pins out of the Pins struct will mean you can't call free, because it takes ownership of the Pins struct, which has been partially moved. If you need an owned PORT, you probably want to steal the peripherals and take it from there.

If someone wants to drive it like an open drain they can always set it to floating input and then back to an output I suppose.

That's an interesting idea. I wouldn't really call that open drain. It's more like a software emulated tri-state buffer. But it still might be useful. I would probably design that as a feature built on top of the gpio module. You could create a struct that holds a pin and manages its state for you.

When the define_pins macro is called it generates the PAXX enums.

As mentioned in #364, I think the unfortunate naming coincidence is causing some confusion here. The v2 define_pins macro is not meant for users. It's purely a one-time-use, internal macro used to prevent code repetition.
It sounds like you want the BSP to define type aliases for each pin in the corresponding mode for its use, e.g. LedPass in your example. I'll try to create a new define_pins macro that also allows you to create type aliases like that. It probably won't save much typing for BSP authors, but at least it will be there as a way to encourage them to add the type aliases.
I think that addresses all of your questions. Did I miss anything?

One more thing. If you're using DynPins, you might want to note the following. The PinId and PinMode traits both have DYN associated constants. For each type that implements them (e.g. PA24 for PinId or AlternateH for PinMode), the DYN constant is equal to the corresponding DynPinId or DynPinMode. That might come in handy. I'm not sure. Unfortunately, to access those constants, you might need to use the fully specified syntax, e.g.
<PA24 as PinId>::DYN

You could also access it through the type aliases defined above, e.g.
<<LedPass as AnyPin>::Id as PinId>::DYN

I think the context would determine which associated types/constants would require the full syntax to access.
BSP authors could also add constants that act like the type aliases.
pub const LED_PASS_ID: DynPinId = DynPinId { group: DynGroup::A, num: 24 };
pub const LED_PASS_MODE: DynPinMode = DYN_ALTERNATE_H;
// Users can't create `DynPin`s directly, so a BSP can only define the IDs and modes

One more thing. If you're using DynPins, you might want to note the following. The PinId and PinMode traits both have DYN associated constants. For each type that implements them (e.g. PA24 for PinId or AlternateH for PinMode), the DYN constant is equal to the corresponding DynPinId or DynPinMode. That might come in handy. I'm not sure. Unfortunately, to access those constants, you might need to use the fully specified syntax, e.g.
<PA24 as PinId>::DYN

You could also access it through the type aliases defined above, e.g.
<<LedPass as AnyPin>::Id as PinId>::DYN

I think the context would determine which associated types/constants would require the full syntax to access.
BSP authors could also add constants that act like the type aliases.
pub const LED_PASS_ID: DynPinId = DynPinId { group: DynGroup::A, num: 24 };
pub const LED_PASS_MODE: DynPinMode = DYN_ALTERNATE_H;
// Users can't create `DynPin`s directly, so a BSP can only define the IDs and modes

@jaredwolff and @sajattack, how does this look as an updated version of the v1 define_pins macro?
The macro would be called like this:
bsp_pins!(
    #[cfg(feature = "unproven")]
    PA24 {
        name: led_pass,
        aliases: {
            AlternateH: LedPass,
            #[cfg(feature = "usb")]
            AlternateM: UsbPin
        }
    }
);

And it would expand to this:
pub mod bsp_pins_mod {
    use crate::target_device as pac;
    use crate::gpio::v2::{
        self as gpio, Pin, PinId, PinMode, Reset, DynPinId, DynPinMode
    };

    pub struct Pins {
            #[cfg(feature = "unproven")]
            pub led_pass: Pin<gpio::PA24, Reset>,
    }

    impl Pins {
        pub fn new(port: pac::PORT) -> Self {
            let pins = gpio::Pins::new(port);
            Self {
                #[cfg(feature = "unproven")]
                led_pass: pins.pa24,
            }
        }
    }

    #[cfg(feature = "unproven")]
    pub type LedPass = Pin<gpio::PA24, gpio::AlternateH>;
    #[cfg(feature = "unproven")]
    pub const LED_PASS_ID: DynPinId = <gpio::PA24 as PinId>::DYN;
    #[cfg(feature = "unproven")]
    pub const LED_PASS_MODE: DynPinMode = <gpio::AlternateH as PinMode>::DYN;

    #[cfg(feature = "unproven")]
    #[cfg(feature = "usb")]
    pub type UsbPin = Pin<gpio::PA24, gpio::AlternateM>;
    #[cfg(feature = "unproven")]
    #[cfg(feature = "usb")]
    pub const USB_PIN_ID: DynPinId = <gpio::PA24 as PinId>::DYN;
    #[cfg(feature = "unproven")]
    #[cfg(feature = "usb")]
    pub const USB_PIN_MODE: DynPinMode = <gpio::AlternateM as PinMode>::DYN;
}
pub use bsp_pins_mod::*;

@jaredwolff and @sajattack, how does this look as an updated version of the v1 define_pins macro?
The macro would be called like this:
bsp_pins!(
    #[cfg(feature = "unproven")]
    PA24 {
        name: led_pass,
        aliases: {
            AlternateH: LedPass,
            #[cfg(feature = "usb")]
            AlternateM: UsbPin
        }
    }
);

And it would expand to this:
pub mod bsp_pins_mod {
    use crate::target_device as pac;
    use crate::gpio::v2::{
        self as gpio, Pin, PinId, PinMode, Reset, DynPinId, DynPinMode
    };

    pub struct Pins {
            #[cfg(feature = "unproven")]
            pub led_pass: Pin<gpio::PA24, Reset>,
    }

    impl Pins {
        pub fn new(port: pac::PORT) -> Self {
            let pins = gpio::Pins::new(port);
            Self {
                #[cfg(feature = "unproven")]
                led_pass: pins.pa24,
            }
        }
    }

    #[cfg(feature = "unproven")]
    pub type LedPass = Pin<gpio::PA24, gpio::AlternateH>;
    #[cfg(feature = "unproven")]
    pub const LED_PASS_ID: DynPinId = <gpio::PA24 as PinId>::DYN;
    #[cfg(feature = "unproven")]
    pub const LED_PASS_MODE: DynPinMode = <gpio::AlternateH as PinMode>::DYN;

    #[cfg(feature = "unproven")]
    #[cfg(feature = "usb")]
    pub type UsbPin = Pin<gpio::PA24, gpio::AlternateM>;
    #[cfg(feature = "unproven")]
    #[cfg(feature = "usb")]
    pub const USB_PIN_ID: DynPinId = <gpio::PA24 as PinId>::DYN;
    #[cfg(feature = "unproven")]
    #[cfg(feature = "usb")]
    pub const USB_PIN_MODE: DynPinMode = <gpio::AlternateM as PinMode>::DYN;
}
pub use bsp_pins_mod::*;

That's an interesting idea. I wouldn't really call that open drain. It's more like a software emulated tri-state buffer. But it still might be useful. I would probably design that as a feature built on top of the gpio module. You could create a struct that holds a pin and manages its state for you.

Oh yea Tri-state would definitely be a better way to refer it as.

@jaredwolff and @sajattack, how does this look as an updated version of the v1 define_pins macro?

On first glance, it seems like it covers all the pain points I described earlier. Happy to kick the tires when it's ready for testing.

That's an interesting idea. I wouldn't really call that open drain. It's more like a software emulated tri-state buffer. But it still might be useful. I would probably design that as a feature built on top of the gpio module. You could create a struct that holds a pin and manages its state for you.

Oh yea Tri-state would definitely be a better way to refer it as.

@jaredwolff and @sajattack, how does this look as an updated version of the v1 define_pins macro?

On first glance, it seems like it covers all the pain points I described earlier. Happy to kick the tires when it's ready for testing.

 Now I'm frustrated and don't want to work on it anymore. Sorry about that. I'll try to redo it tomorrow.

 Now I'm frustrated and don't want to work on it anymore. Sorry about that. I'll try to redo it tomorrow.

Oh crap! Sorry about that I've been there.
Do you have anything running backups in the background? Backblaze and Time Machine have saved my butt on multiple occasions like this.

Oh crap! Sorry about that I've been there.
Do you have anything running backups in the background? Backblaze and Time Machine have saved my butt on multiple occasions like this.

HA! VSCode saved the day. It had everything in the undo history. Give me a minute.

HA! VSCode saved the day. It had everything in the undo history. Give me a minute.

Yesssss. VSCode for the win.

Yesssss. VSCode for the win.

Once the other two GPIO PRs are accepted, I'll go back and add a little more detail to the Migration section in the gpio module docs.

Once the other two GPIO PRs are accepted, I'll go back and add a little more detail to the Migration section in the gpio module docs.

@jaredwolff, could you check out the content in #411 and see if it covers all the problems/questions you ran into with gpio::v2? If you wait until it's merged, you should be able to view it rendered here. If you still have things to address, I'll create another PR.

Nice I'll check it out @bradleyharden

@jaredwolff, did you ever get a chance to check out the updated documentation? I added some discussion to the base gpio module-level docs.
Has anyone else taken a look? Can we close this issue? Are there any further thoughts on improving the documentation?

Hey @bradleyharden not yet. I've been swamped with work. It's on my list. I don't know when I can get to it though. 😞

No worries. Just trying to see what issues can be closed.

@bradleyharden so far here's a few bits of feedback since I have not looked/played with this in a while:

It was hard to find info about the gpio module since it was buried in the overarching common module. I did get to it finally by simply searching gpio. This isn't necessarily your fault, but the main page of the documentation is less than inviting.
Once I got there, the documentation is thorough and provides some great examples of converting between different GPIO modes. (Well done!)
I wasn't sure what the purpose of an Optional pin is. Or the use case. That may need more explanation if it's worth it.

Short of having some actual examples, this is a great start. (more for folks who are starting from zero) I have implemented a few examples here for the board I've been using this with. I have noticed some of the boards in this repo have been converted/are using V2 which is awesome!

@jaredwolff, a few replies:

@vccggorski is leading an effort to address some of these issues in #426. In fact, #425 removes the common module and lifts all of its submodules, including gpio, to the top level of the HAL.
I recently decided to use the typelevel module as a place to document some of the higher-kinded type patterns used throughout the HAL. When I publish it, I'll be sure to include a section on OptionalKind traits and their uses. I can point to that from the OptionalPin documentation.

If you're interested, you can take a look at the sercom::v2::spi::Pads struct to see an example using OptionalPad. However, note that I'll soon be making some changes to simplify and generalize that struct. The changes will also support the analogous struct in any future v2::uart or v2::i2c module.

I see you're using of the changes I made to the USB modules to support v2::Pins. I should just bite the bullet and make the same changes to the rest of the HAL. With the AnyPin trait, it's really easy to support both v1::Pins and v2::Pins simultaneously. It just takes time to modify the code and all the BSPs.

@bradleyharden yea you could bite the bullet. Is there a future benefit of using an AnyPin trait since V1 will be going bye bye soon enough?

Sometimes, and sometimes not. It can help save a type parameter in some cases. But I'm not sure the v1 modules will be deprecated so quickly. A lot of code depends on them, both in the HAL and in the BSPs. There's a lot of refactoring to do.

Yea that's true! That is a big mountain to climb. 😅

@bradleyharden one thing I noticed is that there's no way to know how to utilize the pins once they're set. There's no clear path on how to write or read a pin depending on its mode. It's hard to find since it seems to be in a different location. May be good to add to the examples though.

@jaredwolff, that's a good point. The only way to do so currently is through the embedded-hal traits, but that is not communicated explicitly.


Prompt for confirmation if a source-installed Hummingbot user runs gateway create

Feature Suggestion

Hummingbot Gateway is designed to be installed by running gateway create from Hummingbot client (which pulls Gateway Docker image and automatically configures it), or from source by developers.
The gateway create method is designed for instances of Humminbot installed via Docker, while Gateway source is designed to work with instances of Hummingbot installed from source
However, source-installed Hummingbot instances can still run gateway create, and it may be hard for users to switch to the source-installed Gateway afterwards
Therefore, after user runs gateway create, if the user is not running the Docker version of Hummingbot, add the following prompt: This command will automatically install Gateway as a Docker image, and it is designed to work with Docker versions of Hummingbot only. Are you sure that you want to continue? (Yes/No)?
Only continue to pull Docker image if user answers Yes
Do not show this prompt if users are running Hummingbot from source

gateway has been refactored and gateway create command has been removed


Enums with values, qt-enum-values

Added enums with values (like used by C++), when someone needs to define the ordinal value of an enum member. E.g. enum Foo { Bar = 1, FooBar = 2 };

FYI: The build error is just because your PR produces new output files.  We always diff all outputs against master, and if there's a change, we report it as an error, because there is no "warning" category for tests.  I was too lazy so far to make it so that new files in the diff don't trigger an error.

Superseded by #987


Authentication issue with spree

I am creating an admin template and I am giving an e-commerce section in the template. Firstly I build the project using ROR then I add auth using Devise and now I have added the e-commerce section using Spree. And for that, I Followed https://github.com/spree/spree
and when I use this command rails g spree:auth:install it removes all the config settings of devise.rb that I have made for the devise (i followed this for devise setup https://www.sitepoint.com/devise-authentication-in-depth/) and remains only one line Devise.secret_key = " key value "
This is what I have done till now.
Now I login to my Template using devise and then I go to the spree and then I create another user there in spree by login link and I get successfully login and when I log out from the spree it log me out through my template also and the login page of my template is shown, I know its same path for both the logout , but how can i differentiate it..? and when I am logging in spree as user , i get logged in but it flash message "Authorization failed"
Please help me, Thank you

Can anyone response on this ??

Hello @theshashiverma,
Please use StackOverflow for questions/help, where a wider community will be able to help you. We reserve the issues tracker for issues only.
Thank you!


Fixed wrong i2c port numbers in bubblegum 96 board

Checked the schematic & tested on hardware with Grove LCD module.

Is there still upstream activity on this issue?

My apologies, I'm not sure why this has been skipped/ignored for so long. Thanks for bringing it to my attention. Merged!


ons_datasets_setup() csv format includes unidentified index column

When using .csv file format, an unnamed row index column is included with the data

@JohnHC86 Is this after loading a file that has been downloaded? If so how are you reading the csv?


Create profile page for user details

Set alias & option to use that or email for public
Change password form
Change email form
Change profile picture (to a selection of defaults or gravatar - we're not storing pics)

Wham - this one was a long time coming!


Pyuavcan

Motivation for this change
Tinkering arround with UAVCAN.
Things done

[x] Tested using sandboxing (nix.useSandbox on NixOS, or option sandbox in nix.conf on non-NixOS linux)
Built on platform(s)

[x] NixOS
[ ] macOS
[ ] other Linux distributions

[ ] Tested via one or more NixOS test(s) if existing and applicable for the change (look inside nixos/tests)
[x] Tested compilation of all pkgs that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
[ ] Determined the impact on package closure size (by running nix path-info -S before and after)
[ ] Ensured that relevant documentation is up to date
[x] Fits CONTRIBUTING.md.

@GrahamcOfBorg build python3Packages.{pydsdl,nunavut,pyuavcan}

Result of nixpkgs-review pr 89735 1

6 packages built:
- python37Packages.nunavut
- python37Packages.pydsdl
- python37Packages.pyuavcan
- python38Packages.nunavut
- python38Packages.pydsdl
- python38Packages.pyuavcan


[BUG] Android Beta m5-rc14 Home can´t be decompiled. (Yes, i know, that this an very, very old Android version, but maybe it can be fixed)

Information

Apktool Version (apktool -version) - 2.8.1
Operating System (Mac, Linux, Windows) - Windows
APK From? (Playstore, ROM, Other) - ROM
Java Version (java --version) - java version "1.8.0_381" Java(TM) SE Runtime Environment (build 1.8.0_381-b09) Java HotSpot(TM) 64-Bit Server VM (build 25.381-b09, mixed mode)
If you don´t know what Android Beta m5-rc14 is, here is the SDK with the Emulator, and here is the BetaWiki.

Stacktrace/Logcat
I: Using Apktool 2.8.1 on Home.apk
I: Loading resource table...
Exception in thread "main" java.lang.NullPointerException
        at brut.androlib.res.decoder.ARSCDecoder.readEntry(ARSCDecoder.java:351)
        at brut.androlib.res.decoder.ARSCDecoder.readTableType(ARSCDecoder.java:318)
        at brut.androlib.res.decoder.ARSCDecoder.readResourceTable(ARSCDecoder.java:99)
        at brut.androlib.res.decoder.ARSCDecoder.decode(ARSCDecoder.java:50)
        at brut.androlib.res.data.ResTable.loadResPackagesFromApk(ResTable.java:176)
        at brut.androlib.res.data.ResTable.loadMainPkg(ResTable.java:126)
        at brut.androlib.res.ResourcesDecoder.getResTable(ResourcesDecoder.java:88)
        at brut.androlib.res.ResourcesDecoder.decodeManifest(ResourcesDecoder.java:106)
        at brut.androlib.ApkDecoder.decode(ApkDecoder.java:95)
        at brut.apktool.Main.cmdDecode(Main.java:190)
        at brut.apktool.Main.main(Main.java:93)

Steps to Reproduce

apktool d Home.apk

Frameworks
If this APK is from an OEM ROM (Samsung, HTC, LG). Please attach framework files
(.apks that live in /system/framework or /system/priv-app)
Android Beta m3 framework-res.apk(doesn't changed anything to M5)
APK
If this APK can be freely shared, please upload/attach a link to it.
Home.apk
Questions to ask before submission

Have you tried apktool d, apktool b without changing anything? - No, because it can´t decompile
If you are trying to install a modified apk, did you resign it? - I don´t can install it, because i can´t decompile it.
Are you using the latest apktool version? - Yes

Yeah doesn't work on latest. I'll take a look when I'm back in the zone of disassembly errors and take another look.

Thanks

The same with all Apks from Android Beta m5-rc-14. All available at https://github.com/user0-tb/ApktoolDebug

Is it fixable?

Sorry I don't tend to like mixing working on issues recently. I've found it more helpful for me to stay focused on an a single issue on the way towards resolution. Once I'm complete with my latest ticket (#2836) - I'll revisit open tickets.
So I don't have an answer yet.

If you need any Files or Source Code, ask me.

I took a look - this is because we either regressed or the packing order of chunks was different back then.
F: Chunk #1 start: type=0x0002 chunkSize=0x0002c8fc
F: Chunk #2 start: type=0x0001 chunkSize=0x00010f84
F: Chunk #3 start: type=0x0200 chunkSize=0x0001b96c
F: Chunk #4 start: type=0x0201 chunkSize=0x00003b80

What I tend to normally expect
F: Chunk #1 start: type=0x0002 chunkSize=0x0010ca40
F: Chunk #2 start: type=0x0001 chunkSize=0x0007132c
F: Chunk #3 start: type=0x0200 chunkSize=0x0009b708
F: Chunk #4 start: type=0x0202 chunkSize=0x00000060

We are basically reading types without specs so lots of NPEs on that path. Probably fixable if we change up our type loading to be more deferred.

This looks to be a never ending journey of patches. I'm going to toss in backlog @user0-tb.
If you have source of the framework-res or ResourceTypes.h - I can revisit.

Here @iBotPeaches
Framework-res:
framework-res_src.zip

@user0-tb - This doesn't look like the source of the application, just the source (java) portion.

I've decided after peeking a bit more - that there is real no chance of this older M builds working on compilation. The build tools of this era will generate a resource table that Milestone builds from '08 have zero chance of understanding.
So I'll merge a PR that at least fixes disassembly, but not going to have any chance of compilation. This seems like a happy medium for how old this is.
Ticket will close on merge of PR.

It´s working now! Thanks @iBotPeaches!


cant delete any pdfs that I uploaded.  Using the private version.

This maybe a simple question for you guys but I am a new guy to all this and still learing.
can anyone please tell me where the PDF are stored while I am using them?  I want to start from scratch and i dont know how to remove the old PDFs

same here, I would like to know how to delete any uploaded pdf
thnaks

I delete them directly in the supabase interface, there is no button implemented in this repo to do it through the API


[BUG] targetBlobClient.beginCopy really slow

Description
1.
First we used BlockBlobClient.copyFromUrlWithResponse to trigger the copy process in azure.
Was really fast and worked well, except for files bigger than 256M.
(see https://docs.microsoft.com/en-us/rest/api/storageservices/put-blob#remarks)
This call also failed if the target Client was a BlockBlobClient and a source Blob was of type AppendBlob.

Then we changed the call to BlockBlobClient.beginCopy: Can handle different blob types, and files bigger than 256MB.
BUT...
...it's much slower than copyFromUrlWithResponse. (We need more than 1 day for some storage account)
Test setup
Copy a Storage Account with 3 Files
                      | copyFromUrlWithResponse   | beginCopy
----------------------------------------------------------------------------------
file1 (1MB)     |  219 ms                                  | 1.2 sec
file2 (1MB)     |  232 ms                                  | 15 sec
file3 (250MB) |  7557 ms                                | 37 sec

Any ideas what could be the reason?

@daolis Apologies for the delay. The main difference in performance between copyFromFurl and begin copy is that the former is sync and the latter is not, which becomes particularly noticeable when copying across accounts. Because begin copy is async, there can be all kids of other factors that might play into this slow behavior like where the accounts are located and how busy they are. Still, 37s does seem long for copying 250mb, so let me double check with the service team and see if there are any other extenuating circumstances that may cause such a delay.
In the meantime, have you tried adjusting the polling interval on the SyncPoller you get back?

So what I'm hearing is that this is indeed dependent on how much load the network and accounts are experiencing. Async copies actually only have a guarantee of completing within 2 weeks. While that is certainly atypical, there just aren't really any guarantees on the speed of this copy operation.

Right now, the polling interval is set to 1sec. Should i increase the value?

Tried also with higher polling interval values, but time for 250MB is always ~30sec

@daolis As mentioned, with async copies, the service itself doesn't make any guarantees on how fast the copy will complete within a maximum of two weeks, so unfortunately there isn't much we can do in the sdk to assist with the slow copy time. Depending on you account locations and network configurations, you may be able to tweak those for better results, but again it's not guaranteed.

Could you send me the documentation link where i can find the information about the 2 week?

The REST Docs have the following in the "Remarks" section:
"A pending Copy Blob operation has a 2 week timeout. A copy attempt that has not completed after 2 weeks times out and leaves an empty blob with the x-ms-copy-status field set to failed and the x-ms-copy-status-description set to 500 (OperationCancelled). Intermittent, non-fatal errors that can occur during a copy might impede progress of the copy but not cause it to fail. In these cases, x-ms-copy-status-description describes the intermittent errors."

Thank you!
So, there nothing what can be done on java api side...
Closing...