Fix URL parsing problem.

When I input mongodb port, url parsing has problem.
It shows "double colon in host identifier".
I think the ":" must be exchanged to "::".

what is the breaking url that you are trying to fix ?

I have inputed following url.
http://root:a.382~3v@store.net:27017/mydb.
This url causes double colon problem.

that's first of all not a valid uri. it needs to start with mongodb:// not http://

Oh~ sorry.
I was input it as mongodb.
mongodb://root:a.382~3v@store.net:27017/mydb.

you probably want to change the password on that server if that is real credentials. will look at this tomorrow but from first glance I'm not sure why this string would not work

cannot reproduce with latest


Tmux -> Vim Not working in El Capitan

Just performing a fresh install of vim on OSX.
Everything is working as expected, I can navigate from:
vim -> tmux
vim -> vim
But failing to switch from tmux bash -> vim pane.
Any suggestions?

This has been fixed. Apparently, I have to manually tmux --source-file .tmux.conf to get this to register.


Fixing Login and SignUp Pages UI

I would like to fix the UI of login and signup pages.
@skmirajulislam please assign it to me with label gsssoc-ext and level 2 or as per your choice.

git lfs status what its says ?, provide an screenshot

@skmirajulislam this is coming on doing git lfs status
git lfs status
On branch authentication-ui-fix
Objects to be committed:
Objects not staged for commit:
    frontend/package-lock.json (Git: 4f04c0c -> File: ee585ea)
    frontend/package.json (Git: 2e96c40 -> File: c2f7d34)
    frontend/public/images/e2.png (Git: a9e647d -> File: a9e647d)
    frontend/public/images/e20.jpg (Git: c334b10 -> File: c334b10)
    frontend/public/images/e21.jpg (Git: 7b15193 -> File: 7b15193)
    frontend/public/images/e22.jpg (Git: 5c63606 -> File: 5c63606)
    frontend/public/images/e23.jpg (Git: affb036 -> File: affb036)
    frontend/public/images/e23jpg.jpg (Git: 17db037 -> File: 17db037)
    frontend/public/images/e3.png (Git: 8c3d43b -> File: 8c3d43b)
    frontend/public/images/e4.png (Git: cc896ff -> File: cc896ff)
    frontend/public/images/e5.png (Git: 860169f -> File: 860169f)
    frontend/public/images/e6.png (Git: 1e3100e -> File: 1e3100e)
    frontend/public/images/e7.png (Git: 773f9ac -> File: 773f9ac)
    frontend/public/images/e8.png (Git: 8dab0c2 -> File: 8dab0c2)
    frontend/public/images/e9.png (Git: 5a38fcd -> File: 5a38fcd)
    frontend/public/images/f1.png (Git: 2134a2c -> File: 2134a2c)
    frontend/public/images/f2.png (Git: def4866 -> File: def4866)
    frontend/public/images/f3.png (Git: 1915169 -> File: 1915169)
    frontend/public/images/g1.png (Git: bba4a4d -> File: bba4a4d)
    frontend/public/images/g2.png (Git: bf463e9 -> File: bf463e9)
    frontend/public/images/g3.png (Git: f489d3c -> File: f489d3c)
    frontend/public/images/l.jpg (Git: 522a983 -> File: 522a983)
    frontend/public/images/l.png (Git: 8cc26df -> File: 8cc26df)
    frontend/public/images/log.jpg (Git: 25673da -> File: 25673da)
    frontend/public/images/login.jpg (Git: 72e3571 -> File: 72e3571)
    frontend/public/images/m.png (Git: 40e3588 -> File: 40e3588)
    frontend/public/images/moon.png (Git: 13dbeb7 -> File: 13dbeb7)
    frontend/public/images/r.jpg (Git: 46b5483 -> File: 46b5483)
    frontend/public/images/r.png (Git: f650b6c -> File: f650b6c)
    frontend/public/images/sun.png (Git: 96ee17f -> File: 96ee17f)
    frontend/public/images/w.jpg (Git: 73ec748 -> File: 73ec748)
    frontend/public/images/y.png (Git: e6ec9ab -> File: e6ec9ab)
    frontend/src/App.js (Git: b83d6be -> File: b83d6be)
    frontend/src/components/Act/Act.js (Git: d612061 -> File: d612061)
    frontend/src/components/Car/Car.js (Git: 01ba471 -> File: 01ba471)
    frontend/src/components/Concept/Concep.js (Git: 88329d6 -> File: 88329d6)
    frontend/src/components/Craft/Craft.js (Git: 2b80ab5 -> File: 2b80ab5)
    frontend/src/components/Education/Educ.js (Git: aae1eef -> File: aae1eef)
    frontend/src/components/Firebase/firebase.js (Git: 0e8db5f -> File: 0e8db5f)
    frontend/src/components/Firebase/logout.js (Git: f43b35c -> File: f43b35c)
    frontend/src/components/Firebase/useAuth.js (Git: 9369767 -> File: 9369767)
    frontend/src/components/Footer/Footer.js (Git: 2c5a4a8 -> File: 2c5a4a8)
    frontend/src/components/ForgotPassword/ForgotPassword.js (Git: 187f2d3 -> File: 187f2d3)
    frontend/src/components/GoogleButton/GoogleButton.js (Git: 9bf6b48 -> File: 9bf6b48)
    frontend/src/components/Navbar/Navbar.js (Git: 6330b2a -> File: 6330b2a)
    frontend/src/components/Quiz/Quiz.js (Git: 6dd6e76 -> File: 6dd6e76)
    frontend/src/components/Register/Register.js (Git: 12856ab -> File: 12856ab)
    frontend/src/components/Sef/Sef.js (Git: 4780af3 -> File: 4780af3)
    frontend/src/components/profileCard/ProfileCard.js (Git: d91a986 -> File: d91a986)
    frontend/src/index.js (Git: 2b22625 -> File: 2b22625)
    frontend/src/pages/About/About.js (Git: adacd84 -> File: adacd84)
    frontend/src/pages/Contact/Contact.js (Git: 7c179a6 -> File: 7c179a6)
    frontend/src/pages/Contributor/ContributorsPage.jsx (Git: 4816026 -> File: 4816026)
    frontend/src/pages/Dashboard/Dashboard.js (Git: 525dcf5 -> File: 525dcf5)
    frontend/src/pages/Error/index.js (Git: f29129c -> File: f29129c)
    frontend/src/pages/Home/Faqs.jsx (Git: 6ae8172 -> File: 6ae8172)
    frontend/src/pages/Home/Hom.js (Git: 15c06f3 -> File: 15c06f3)
    frontend/src/pages/Loan/Loan.js (Git: 6195f70 -> File: 6195f70)
    frontend/src/pages/career/career.js (Git: a2ab8a2 -> File: a2ab8a2)
    frontend/src/reportWebVitals.js (Git: 7148516 -> File: 7148516)
    frontend/src/setupTests.js (Git: 2258375 -> File: 2258375)
    frontend/src/validations/validation.js (Git: 8b8535b -> File: 8b8535b)


MFE Crashes when config reloads too often

I have created a keyboard shortcut using ahk to reload MFE config due to the issue of file explorer losing mica when resized/maximised etc. I have bound this to Displayfusion so that when maximised, it reloads the config automatically. However when I use the shortcut too often, MFE crashes from reloading config file too often.

Here are the crash logs I have obtained from Event Viewer

I tried to fix this using a mutex, but reloading config file and reapplying rules too often is not recommended because it may put your CPU on pressure.


fix: many reference typegraphql

I found the problem with typegraphql query dialect. GET MANY REFERENCE has different query params

ping @macrozone


Support Ed25519 for JWT algorithms

Is it possible to support Ed25519?

I'll check and will update this issue.


merge: esp-idf-svc v0.46.0 into stabl-master

Merge version/tag v0.46.0 from upstream into stabl-master.
Note
Did a trial compile with https://github.com/Stabl-Energy/Rust-SBC-Client/pull/23 and it looked promising.

I only had merge conflicts in src/wifi.rs and src/nvs.rs.

Not sure why my code comment is marked Outdated...


Spec-interpreter fuzzing: modify to generate and test single-instruction or no-control-flow cases

In #3186 we found that the WebAssembly spec interpreter may not be suitable for high-throughput fuzzing because of certain performance characteristics. While we were able to locally patch one source of quadratic runtime, there are likely others, and the patch was not really a good fit to upstream. We are looking into other peer implementations to fuzz against for general programs (aside from existing differential_wasmi fuzzing).
However, there is another way we could use the reference interpreter: we could validate single instructions' semantics more closely by generating short test cases that just execute an instruction (or a straight-line sequence with no control flow or calls) and return. This would be very valuable for instructions with more complex semantics, such as many of the SIMD instructions.
This is sort of a breadth-vs-depth situation: the "depth" comes from longer-running programs and tests interactions between instructions, and a good oracle there is a more optimized implementation; while the "breadth" comes from exhaustive many-inputs testing of very short sequences and tests mainly that we got the instruction semantics right. The combination seems like it should give pretty good coverage.
cc @abrown @alexcrichton

My intuition is that combining multiple instructions, even if it is just two or three, would give us much more bang for our buck than testing single instructions.

Ah, old issue, paging back in context (I'm not sure why the labeler decided to tag you just now on a discussion from August!)...
Yup, agreed, that's the "or a straight-line sequence with no control flow or calls" above :-)
Adding some more thought just now: IMHO we should do it only up to the max depth of our instruction combining patterns. The point of this suggestion was specifically to target the fuzz throughput in a different way, at the input-value space rather than the input-program space. As we test straightline sequences of n instructions we have O(|wasm opcodes|^n) possibilities, and cut our time spent (on exploring argument values) per individual test program exponentially.
In other words, if my goal is to say that all cases for (say) SIMD instruction X have been covered, then separately fuzzing vector_add(X(x, y, z), [1.0, 1.0, 1.0, 1.0]) and vector_add(X(x, y, z), [2.0, 2.0, 2.0, 2.0]) doesn't really add any coverage. Testing vector_add(X, ...) and vector_mul(X, ...) might, if we have combining patterns that differ for those. But combining instructions may also mask some of the value space, for any operation that isn't bijective (e.g. extract one lane, or multiply by zero, or min/max).
So, said another way, what I think would be useful is a unit-test-inspired approach where we take each individual lowering and then throw a long test-vector of argument values at it. (In other words the Arbitrary type is a (short inst sequence, Vec<ArgValues>).) That gets us "each individual lowering is good" coverage in a way that might hide when we're testing n (for n larger) instructions at a time.
cc @abrown , any interest in looking at this as a way to get the spec interpreter in active fuzzing use?

I would eventually like to look into this more but if anyone else has the bandwidth feel free to jump in first (read: I'm not sure when I will get to this).

@cfallin, in a separate project I did something using proptest that reminded me of this. The basic idea, adapted to Wasmtime, would be to:

construct a single-instruction WebAssembly module
create random inputs using proptest
run the module's sole function in two different engines and check the results for equality

I wasn't too concerned with multiple-instruction sequences and other things mentioned above but if we have a place to put this proptest-guided fuzz test then I would be happy to contribute the code.

I think this is closed by #4409 which is now in use by the new differential fuzz target (#4515).


has_module_perms always return True

even if user doesn't have any perms for the object/module or no permission logic set

Could you explain it bit more with procedure for how to reproduce?

I'm checking
if self.request.user.has_module_perms(model_cls._meta.app_label):
without django-permission - if a user doesn't have any model perms - it returns false (as expected)
with django-permission - even without any logical perms attached to model and no static permissions - it returns true (false expected)
i think it should returm false even with attached (but not matched) logical permissions

I could not reproduce your issue on Django 1.8.7

Which version of Django do you use
Give me a minimum example project


Fix docker image name

Note to maintainers: Temporarily disabled Deploy check as this branch can't be deployed because of the branch name conflict.

Enabled Deno / Fresh status requirement again


Automator: update proxy@master in istio/istio@master

Generated by Automator - 2023-11-14T03:49:48+00:00

@istio-testing: The following test failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name
Commit
Details
Required
Rerun command

unit-tests-arm64_istio
bda9d5b54635be220679850179cba059e95725eb
link
true
/test unit-tests-arm64

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@istio-testing: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name
Commit
Details
Required
Rerun command

unit-tests-arm64_istio
bda9d5b54635be220679850179cba059e95725eb
link
true
/test unit-tests-arm64

integ-security-istiodremote_istio
bda9d5b54635be220679850179cba059e95725eb
link
true
/test integ-security-istiodremote

Instructions for interacting with me using PR comments are available here.  If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

/retest


Node sass missing - module too opinionated?

Describe the bug
When importing Uppload into my (react) app I get the error:
To import Sass files, you first need to install node-sass. Runnpm install node-sassoryarn add node-sassinside your workspace.
My project runs PostCSS and is a create-react-app project. Is it really necessary to automatically import the CSS/Sass file when importing the module? I love the idea of the package but I think it's a bit too opinionated for widespread use. I really don't like the idea of setting up a another css preprocessor to use this module.
What do you think about adding CSS separately to JS, like other modules are doing it as well (see for example the slick-carousel)?  Therefore I could import your CSS to my CSS file like this for example:
@import "~uppload/uppload.css";

You could still use sass for development and generate a css file when you build the project before you release a new version.

In Uppload v2, this is now fixed. I'll close this issue as soon as v2 is released. Here is an excerpt from the the theme docs:
If you want to use the built-in themes, you can import the CSS in your JavaScript file using a bundler like Webpack (you'll need an additional loader, like style-loader):
import { Uppload } from "uppload";
import "uppload/dist/uppload.css"; // Basic styles
import "uppload/dist/themes/light.css"; // Light theme

const uppload = new Uppload();

You can also use the Sass source code instead:
@import "uppload/src/styles/uppload.scss";
@import "uppload/src/themes/light.scss";

Or, use a CDN for styling:
<head>
  <link rel="stylesheet" href="https://unpkg.com/uppload/dist/uppload.css">
  <link rel="stylesheet" href="https://unpkg.com/uppload/dist/themes/light.css">
</head>


[doc] Updated doc file for this new prim library

Updated doc file for this new prim library
Signed-off-by: Joshua Park<EMAIL_ADDRESS>

For the commit message can you prepend a [doc] label?

Also, it seems like you're touching some SystemVerilog as well (hw/ip/prim/rtl/prim_clock_gp_mux2.sv) so maybe add the [prim] label as well.

In terms of commit message, it is uncommon to see the text inside the square brackets be capitalized. May I suggest changing the commit message to something like: [doc,prim] Explain glitch protection by prim IP

Updated. Thanks

ah same here, looks like this probably needs a rebase and push again.

ah same here, looks like this probably needs a rebase and push again.

It's passing after rebase/push. Thanks


Pubsub: Cannot connect to Pubsub Emulator with PublisherClient from google-cloud-pubsub version 0.28

I just update to google-cloud-pubsub version 0.28, where Google restructured the Python client into a PublisherClient and SubscriberClient. I was trying to connect to the Pubsub Emulator on localhost, but despite setting the environment variables, it still connects to the cloud pubsub service, where it can list all the topic from cloud pubsub, but not the ones from emulator.
Here is the code I used to connect to emulator
from google.cloud import pubsub
import os
os.environ['PUBSUB_EMULATOR_HOST'] = 'localhost:8085'
os.environ['GOOGLE_CLOUD_PROJECT'] = 'my-project'
publisher = pubsub.PublisherClient()
topic = 'projects/my-project/topics/abc'
publisher.get_topic(topic)

and here is the exception:
Traceback (most recent call last):
  File "<input>", line 5, in <module>
  File "/Users/sx5640/Envs/uie/lib/python2.7/site-packages/google/cloud/pubsub_v1/_gapic.py", line 42, in <lambda>
    fx = lambda self, *a, **kw: wrapped_fx(self.api, *a, **kw)
  File "/Users/sx5640/Envs/uie/lib/python2.7/site-packages/google/cloud/gapic/pubsub/v1/publisher_client.py", line 341, in get_topic
    return self._get_topic(request, options)
  File "/Users/sx5640/Envs/uie/lib/python2.7/site-packages/google/gax/api_callable.py", line 452, in inner
    return api_caller(api_call, this_settings, request)
  File "/Users/sx5640/Envs/uie/lib/python2.7/site-packages/google/gax/api_callable.py", line 438, in base_caller
    return api_call(*args)
  File "/Users/sx5640/Envs/uie/lib/python2.7/site-packages/google/gax/api_callable.py", line 376, in inner
    return a_func(*args, **kwargs)
  File "/Users/sx5640/Envs/uie/lib/python2.7/site-packages/google/gax/retry.py", line 127, in inner
    ' classified as transient', exception)
RetryError: RetryError(Exception occurred in retry method that was not classified as transient, caused by <_Rendezvous of RPC that terminated with (StatusCode.NOT_FOUND, Resource not found (resource=abc).)>)

Update: Issue seems to be fixed in version 0.29. Closing issue


NotImplementedError should be NotImplementedException

The javadoc of java.lang.Error states that

An Error is a subclass of Throwable that indicates serious problems that a reasonable application should not try to catch. Most such errors are abnormal conditions.

I believe NotImplementedError should extend RuntimeException and should be called NotImplementedException instead, because something not being implemented can still be a recoverable error an application could, and probably should try to catch.
It mostly matters in generic error handling code that decides what to do based on exception classes:

RuntimeException -> recover from it
Error -> try to log it and let the app die

A NotImplementedError is defined to be non-recoverable, like Scala's NotImplementedError.
From the Scala Docs:

Throwing this exception can be a temporary replacement for a method body that remains to be implemented.

There is no room for interpretation.
We should close this ticket.

This can be worked around quite easily even if it stays like it is now, but I think interpreting it as a recoverable error rather than non-recoverable makes more sense. Maybe the Scala people got it wrong in the first place?
This changeset is suggesting this might actually be the case:
https://github.com/scala/scala/commit/68f62d7e9c200034bd42ffaf795b57fb379d9d38
Also, this bug: https://issues.scala-lang.org/browse/SI-7164
I'm not familiar with Scala but it seems they have a separate mechanism to distinguish between fatal and non-fatal exceptions while Java, and more precisely, generic error handling code in Java uses the base Java exception categories: Exception, RuntimeException, Error.
I think the mistake was that they thought at first that it's similar to Java's LinkageError while in reality it's not, because LinkageError is thrown in an unexpected/invalid state where some binary incompatibility arose, while the NotImplementedError is pretty much intentional.
The question is whether we want to blindly copy Scala behavior even if it seems wrong or walk our own walk where appropriate?

What if we would only change the superclass, but not the name? We could keep binary compatibility while subtly changing semantics towards the right way.

Both Error and RuntimeException are unchecked exceptions, so technically there is no difference.
UnsupportedOperationException is a good example for a semantically missing implementation. It extends RuntimeException and has the (original) meaning that it is intended that no implementation exists. It was necessary for Java to introduce it because of the Java Collection Framework's immutable classes.
Our NotImplementedError is another cup of tea. It can be thrown by using the TODO() method of API (similar to Scala's Predefs ???`). The main use is in the field of rapid prototyping. We want rapidly get our code statically compile in order not to cope with the bloody details (for now):
R compute(A a) {
    return TODO(/* Will do that later... */);
}

void run() {
    compute(TODO(/*call service1 to get an A*/)).doSomethingMeaningful();
}

A Program that contains TODO()s is wrong and should not go to production! The user should not try to handle NotImplementedErrors. These are more sort of development-time errors than runtime errors.

The Fatal / NonFatal discussion is a different story. It has only to do with the internal implementation of Try (in Scala and in Javaslang Vavr).
More specifically
Try(() -> { throw new Err(); });

Will result in a Failure if Err is considered to be NonFatal. If it is considered to be Fatal, the application will re-throw the cause instead of creating a Try instance. That is all.
For example a StackOverflowError extends VirtualMachineError but is considered to be NonFatal because a flooded Stack is cleaned up by the JVM when the method body exists. But an OutOfMemoryError may mix up the program semantics. The program execution is non-deterministic in such a case.
Please see also Vavr's Try.NonFatal.
Please note that this is subject to change. See #1382 and #1722. However, fatal exception will still be re-thrown in Vavr but exceptions need not to be wrapped anymore in NonFatal and Fatal :)

Trust me, extending Error is correct.

I've recognized that we should re-introduce StackOverflowError as non-fatal exception. I will create an issue.

NotImplementedError extending Error instead of RuntimeException doesn't prevent it from ending up in production. It depends on whether though pre-production testing of the app actually touches that code path or not. The only difference I see is how the application reacts to such an event.
Let's suppose there's an app shell providing the skeleton for the app (could be a container or some custom app skeleton). The skeleton/container is responsible for centralized error handling. The app skeleton/container contains a number of modules, and it's not even aware that one of the module uses vavr. The error handling code is some top level code that contains an exception handler that handles Exception subclasses to log them and to present the user with some meaningful error message ("This function is not implemented yet" is a meaningful user error message). The generic error handler also catches subclasses of Error, but only to log them, rethrowing afterwards, letting the app die, as there's no expected way to recover from such an error. This kind of generic error handling code is pretty common, I suppose a lot of frameworks/containers contain such error handling code.
In the end, we didn't necessarily prevent the app going into production (that's more a matter of proper testing), but made matters worse by letting our app die while we could just as easily recover from the exception.
I strongly believe TODO is a recoverable exception and we should treat is as such.
Also note that Try.of(API::TODO) returns a Failure(javaslang.NotImplementedError: An implementation is missing.), while
Try.of(() -> {
    throw new LinkageError();
});

throws Try.FatalException, a subclass of RuntimeException which is pretty wrong, it converts a non-recoverable exception into a recoverable one. My point is that vavr already treats NotImplementedError as a recoverable exception, it just doesn't communicate it as such to the outside world (being a subclass of the non-recoverable Error).
This seems to be a useful discussion as it uncovered another possible issue, that of FatalException being a subclass of RuntimeException.

I currently see no problem that arises. If in doubt, we always align to Scala.
We want to signal that it is semantically an Error if the underlying program runs into a NotImplementedError, regardless if it is recoverable or not.
This is by definition. It is part of our suggested programming model and part of the contract of the TODO() method.
Before having TODO(), the only possibility was to assign null to such code-parts. This could leak undefined behaviour into the code base. The job of TODO() resp. NotImplementedError is to put this right.
When we start to treat NotImplementedError as recoverable exception, the original idea of replacing null is broken again. It will lead to a JavaScript-like undefined state. We have to make clear that a TODO() is an error that has to be fixed by the developer.

Try.Fatal can be understood as

Computer, stop now. Immediately.
It makes no sense to do anything else than shutting down.
Even writing something to the logs makes no sense anymore. It might end up in chaos.

But you are right, Try may leak a NotImplementedError into production, in every scenario we discussed so far.
However, I would leave it this way. Fatal exceptions are very rare. It means "shut down, now". It is more something 'physically broken'  than 'logically broken'. I would align to Scala here.

It was interesting to discuss about it because even something simple as an Exception may span a whole universe of aspects. For example I did not think about the dependency to Try.Fatal, yet.
However, sprinkling dependencies to something simple like NotImplementedException across the code-base is evil on its own. Before doing this I would consider to remove TODO() and NotImplementedError instead. Simplicity is the most important goal.
Let's close this ticket.

Before having TODO(), the only possibility was to assign null to such code-parts. This could leak undefined behaviour into the code base. The job of TODO() resp. NotImplementedError is to put this right.
When we start to treat NotImplementedError as recoverable exception, the original idea of replacing null is broken again. It will lead to a JavaScript-like undefined state. We have to make clear that a TODO() is an error that has to be fixed by the developer.

I wasn't saying TODO() is a bad idea and we should use return null; instead, on the contrary, I think it's good practice, I just said that extending RuntimeException would be better than extending Error, because of semantics defined in the java.lang.Error class javadoc. I see this as a very similar exception to UnsupportedOperationException, the only difference being the latter is not necessarily planned to be implemented later.

Thanks. This issue is a good reference, I will take parts for the documentation.

@nfekete (related)
I think the other way makes sense: making NotImplementedError fatal. We then ensure that it does not leak into a Failure.


Xlib.error.DisplayConnectionError: Can't connect to display ":0": b'No protocol specified\n'

Description
A Clear and Concise Description of the Bug
To Reproduce
Steps to Reproduce the Bug
Screenshots
If applicable, add Screenshots to help explain your Problem
Version Information

OS: [e.g. Windows 10]
Browser: [e.g. Microsoft Edge, Google Chrome]
Python: [e.g. 3.10.1]
PyWhatKit: [e.g. 5.3]

You can Check the PyWhatKit Version using
print(pywhatkit.__VERSION__)

So i encountered this error :
Xlib.error.DisplayConnectionError: Can't connect to display ":0": b'No protocol specified\n'
So for the guys using the linux distros, ubuntu to be specific they can just run:
 xhost + on the terminal
Then run:
 sudo apt-get install python3-tk python3-dev
So this will solve this  error Xlib.error.DisplayConnectionError: Can't connect to display ":0": b'No protocol specified\n'


[PI-1239]Add useful getter for CreatedAt object

Thanks to this update it is possible to get created at timestamp directly from CreatedAt object by calling $event->getCreatedAt()->getTimestamp(). Thanks to this change, Event usage will be more object-oriented.

Działa tutaj te CI? :P


Need an Object matcher that can ignore fields from expected and/or received json

Needed an Object matcher that can ignore fields from expected and/or received json
I've made this one (in kotlin), maybe you could integrate it.
class CustomJsonObjectPartialMatcher(
  val excludingExpected: List<String> = emptyList(),
  val excludingReceived: List<String> = emptyList()
) : PartialJsonMatcher<ObjectNode> {

    override fun jsonDiff(path: Path, receivedJson: ObjectNode?, expectedJson: ObjectNode, jsonMatcher: JsonMatcher): JsonDiff {
        var jsonDiff = JsonObjectDiff(path)
        Objects.requireNonNull<ObjectNode>(receivedJson)
        val receivedJsonFields: MutableSet<String> = receivedJson!!.fieldNames().asSequence().toMutableSet()
        expectedJson.fields().forEachRemaining { (expectedPropertyName, expectedValue) ->
            if (!excludingExpected.contains(transformedPropertyName(path,expectedPropertyName) )) {
                var receivedValue = receivedJson.get(expectedPropertyName)
                if (receivedValue == null) {
                    jsonDiff.addNotFoundProperty(expectedPropertyName, expectedValue)
                } else {
                    var diff = jsonMatcher.diff(path.add(Path.PathItem.of(expectedPropertyName)), expectedValue, receivedValue)
                    jsonDiff.addPropertyDiff(expectedPropertyName, diff)
                }
                receivedJsonFields.remove(expectedPropertyName)
            }
        }
        receivedJson.fields().forEachRemaining { (receivedPropertyName, receivedPropertyValue) ->
            if (!excludingReceived.contains(transformedPropertyName(path,receivedPropertyName) )) {
                var expectedValue = expectedJson.get(receivedPropertyName)
                if (expectedValue == null) {
                    jsonDiff.addExtraProperty(receivedPropertyName, receivedPropertyValue)
                }
            }
        }
        return jsonDiff
    }

    val regex = "\\.\\d+|\\\$\\.".toRegex()

    private fun transformedPropertyName(path: Path, propertyName: String): String {
        return if("$"==path.toString())
            propertyName
        else {
            path.toString().replace(regex, "")+".$propertyName"
        }
    }

...(
expectedJson = legacyProfileJson,
excludingExpected = listOf(
"talentId",
"aptitudes.favorite", //sub fields from an array ($.aptitues.0.favorite)
),
excludingReceived = listOf(
"permissionScope",
)
)

Hi, Thank you for this proposal.
I'm working on a refactoring of this project, I think it will be easier to implement this kind of feature afterwards.


Feature suggestion: Add time to templates.

When formatting notification messages - it can be useful to add the current date / time.
I don't think there is currently a way to do this in templates.

I'm down to add utcnow and now as available methods to templates

:+1: Shall I close this?

Well no one did it yet


Update project status

Hello,
Reading some closed PR like this one: https://github.com/hemerajs/fastify-graceful-shutdown/pull/37 could be seen that the project is not accepting new features and it is recommended to use close-with-grace. So I created this PR to update the status so future users consider using a different alternative. This might be beneficial.

Hi, I'm not sure why you got this impression. The last release was 1 week ago https://github.com/hemerajs/fastify-graceful-shutdown/releases/tag/v4.0.1

@StarpTech I got the impression because of this comment: https://github.com/hemerajs/fastify-graceful-shutdown/pull/37#issuecomment-1305404919

It's 2 years old. The situation has changed.

@StarpTech I see, sorry for the misunderstanding.
So would you be open to bring back this topic https://github.com/hemerajs/fastify-graceful-shutdown/pull/37 it would also be interesting for us to have that feature or a similar mechanism. I can create a similar PR.

Please continue the discussion in the issue. As stated here, I'm ok with logging a WARN rather than throw.


Minor propositions CMPackager.ps1

Sorry for my poor english and thanks for your Work !
It's also my first PR ;-)

$ScriptRoot is define at the beginning, I have replace all $PSScriptRoot by $ScriptRoot
Add Invoke-Expression in Application Variables Definition to use powershell variable in XML

Thank you!
I am not sure about the Invoke-Expressions everywhere, Things like the name, description, etc. are meant to be strings, not PowerShell expressions.
What is the use case for having things like the name and description of the app to be created as a script?

One of my client define application name like this :
"APP_publisher_appname_appversion_sccmreleasenumber_OSarchitecture_language"
For other variables, i have no use case 🙂

Going to close this one for now, the Scriptroot changes are great, but I don't want to have all the extra Invoke-Expressions at this time. Thank you for the contribution though!


Fallback to CPUAccelerator when ([], 0, "0") are passed to the devices flag

What does this PR do?

Fallback to CPUAccelerator when ([], 0, "0") are passed to the devices flag and to keep it consistent with the gpus, tpu_cores and ipus flag.
Current behavior with gpus and other device flags.
## Doesn't fail and falls back to `CPUAccelerator`
Trainer(gpus=0)

Without the fix in this PR, the following used to fail
Trainer(accelerator="xpu", devices=0)

Does your PR introduce any breaking changes? If yes, please list them.

Before submitting

[ ] Was this discussed/approved via a GitHub issue? (not for typos and docs)
[x] Did you read the contributor guideline, Pull Request section?
[x] Did you make sure your PR does only one thing, instead of bundling different changes together?
[ ] Did you make sure to update the documentation with your changes? (if necessary)
[x] Did you write any new necessary tests? (not for typos and docs)
[x] Did you verify new and existing tests pass locally with your changes?
[ ] Did you list all the breaking changes introduced by this pull request?
[x] Did you update the CHANGELOG? (not for typos, docs, test updates, or internal minor changes/refactorings)

PR review
Anyone in the community is welcome to review the PR.
Before you start reviewing make sure you have read Review guidelines. In short, see the following bullet-list:

[x] Is this pull request ready for review? (if not, please submit in draft mode)
[x] Check that all items from Before submitting are resolved
[x] Make sure the title is self-explanatory and the description concisely explains the PR
[x] Add labels and milestones (and optionally projects) to the PR so it can be classified

Did you have fun?
Make sure you had fun coding 🙃
cc @akihironitta @rohitgr7 @justusschock

Trainer(gpus=0)

wouldn't it be better if this raises another error saying invalid values for gpus for 0 and []? this means the user has made a mistake while selecting the devices.
also
Trainer(gpus="0")

shouldn't train on GPU:0?

also

Trainer(gpus="0")
shouldn't train on GPU:0?

Nope, it falls back to CPUAccelerator. Trainer(gpus="0,") runs on GPU:0
https://pytorch-lightning.readthedocs.io/en/latest/accelerators/gpu.html#select-gpu-devices

Was this change introduced in https://github.com/PyTorchLightning/pytorch-lightning/pull/12410/ on purpose?

Was this change introduced in #12410 on purpose?

https://github.com/PyTorchLightning/pytorch-lightning/pull/12160#discussion_r816714587

Closing this for #12633


Warning virtualizedCell.cellKey

I think we must change the key from number to string

Failed child context type: Invalid child context virtualizedCell.cellKey of type number supplied to CellRenderer, expected string.

yes, you are right, I can update number to string.


AWS2 S3 native extension

Fixes #1083 and #1084

Sure. I was going through the components first. I'll create the support extension with the next one. Thabks


Develop to Next post 2.1.5

Looks like we need to add METRICS_AUTHENTICATED to the JSON schema for settings. :)


Should make a new CONTRIBUTING.MD file

Is your feature request related to a problem? Please describe.
README,md  file has Contribution Guidelines which is not good I thing!
Describe the solution you'd like
ill create a separate File for this

i can do it

@sayashchaudhary  I'm also a Participates !! sorry

@ritiksoni00 can you please elaborate a little bit here what extra things you goona add/modify in there? (May be you can just paste here the things you are planning to add in the contribution.md file)

like contribution guidelines ... should be in this file!!

@ritiksoni00 please go ahead.

You should warn me! @Kajol-Kumari   ABOUT THIS #107


Make envrc mode work

Propagate process-environment and exec-path to any auxiliary buffer which is created, so that envrc mode works.
An example requirement for this is with Nix development shells via direnv.  With this, the Rust compiler, rust-analyzer, et al are not on the user's default path, but only on a local path configured by direnv within the project directory.
Two different mechanisms are used to make this work.

Code which makes use of get-buffer-create or generate-new-buffer is wrapped in inheritenv

A macro which wraps with-temp-buffer is used in place of that, since inheritenv does not handle that case, adapted from https://github.com/magit/magit/pull/4169

Subsequent additions of code which creates such auxiliary buffers should do likewise.
Additionally, LSP mode is started with lsp-deferred so that envrc has a chance to configure the path before it is required.
This change is working for me for cargo compilation and LSP mode rust-analyzer.  I am sure I'm not utilising the full surface area of rustic mode, so may have overlooked something.  Feedback welcome.
Fixes #420

An example requirement for this is with Nix development shells via direnv.

I use pretty much the same workflow and have been using envrc for it which seems to well (at least for my workflows).

Squashed before rebase, sorry, as rebase unsquashed is just :weary:

Thanks!

Thanks for merging this promptly!


BabelPlugin with Babel7 support

Now that Babel 7 is out, I was attempting to run a test project with fuse-box and Babel 7. However, here BabelPlugin explicitly requires babel-core. I want to discuss the possibility of allowing the user to define which or from where to include babel core. Kind of like:
BabelPlugin({
  babelCore: '@babel/core', // < fallback to `babel-core` if not specified?
  config: {...}
})

Since babel-core and @babel/core have the same API (I think, I took a quick look :P), It would work.
Or, as an alternative, if It can be versioned. Maybe something like:
Babel7Plugin({...})

Keeping the previous one untouched.

@eddyw sounds legit to me? can you submit a PR? also please update the docs ;-)

@nchanged I have a dirty implementation working on local. It'd take me some time to implement it properly :P
While we're at it, @babel/preset-env has a useBuiltIns options which can be set to usage to include polyfills for things that need to be polyfilled. For instance, with the following:
Source:
[1, 2, 3].includes(3);

Config:
const client = FuseBox.init({
  cache: false,
  target: "universal@esnext",
  homeDir: "src",
  output: "dist/$name.js",
  useTypescriptCompiler: false,
  tsConfig: "./tsconfig.json",
  sourceMaps: {
    project: true,
    vendor: true,
    inline: true
  },
  ensureTsConfig: true,
  log: false,
  plugins: [
    EnvPlugin({
      NODE_ENV: "development"
    }),
    SourceMapPlainJsPlugin(),
    Babel7Plugin({ // << Just replaces babel-core with @babel/core and `transform` to `transformAsync`
      limit2Project: true,
      config: {
        sourceMaps: true,
        sourceType: "module", // << by default babel will guess
        ast: true, // << this defaults to `false`, I'm not sure if it was like that before Babel 7
        presets: [
          [
            "@babel/preset-env",
            {
              useBuiltIns: "usage",
              targets: "> 0.25%, not dead",
              debug: true,
              modules: "commonjs"
            }
          ]
        ]
      },
      extensions: [".tsx", ".ts", ".js", ".jsx"]
    }),
  ]
})

with the preset config, it generates the following:
(function(FuseBox){FuseBox.$fuse$=FuseBox;
FuseBox.target = "universal";
var __process_env__ = {"NODE_ENV":"development"};
FuseBox.pkg("default", {}, function(___scope___){
___scope___.file("client/app.jsx", function(exports, require, module, __filename, __dirname){

"use strict";

require("core-js/modules/es7.array.includes"); // <<< Injected by babel

require("core-js/modules/es6.string.includes"); // <<< Injected by babel

[1, 2, 3].includes(3);
});
return ___scope___.entry = "client/app.jsx";
});

FuseBox.import("default/client/app.jsx");
FuseBox.main("default/client/app.jsx");
})
(function(e){function r(e){var r=e.charCodeAt(0),n=e.charCodeAt(1);if((m||58!==n) ...blablabla... }();return m||(h.FuseBox=_),e.FuseBox=_}(this))
//# sourceMappingURL=app.js.map?tm=1535441846599

Since those require are included by babel, this code may work on NodeJS but it won't work on browser since those require are not resolved/included by FuseBox.
I'm not very familiar with the FuseBox API. Any suggestion where to look at? useBuiltIns: "usage" is a pretty cool feature and I want to implement this.

Well, I found file.analysis.addDependency which should add those extra requires, I guess?
For instance:
file.analysis.addDependency('core-js/modules/es7.array.includes')
file.analysis.addDependency('core-js/modules/es6.string.includes')

That will work, also you could kick analysis on the generate babel source and see what's there

Actually, I thought maybe to "inject" a plugin to babel config, so we can get from AST all references to core-js, kind of like this:
this.config.plugins = [ // << Just testing but shouldn't over-write
  function addStringDependenciesForCoreJS() {
    return {
      visitor: {
        CallExpression(path) {
          const node = path.node
          if ( // << probably all this can be better :/
            node.callee.type === 'Identifier' &&
            node.callee.name === 'require' &&
            node.arguments[0].type === 'StringLiteral' &&
            node.arguments[0].value.indexOf('core-js/modules') === 0
          ) {
            file.addStringDependency(node.arguments[0].value)
          }
        }
      }
    };
  }
];

I was checking analysis but in dependencies those imports do not appear, only the ones that are originally in the source. Unless I'm missing something.
Anyway, I'll get some time this week (maybe) to have a babel 7 plugin and leave the polyfills thing for later (or kind of under an optional flag/property)

@nchanged question, the BabelPlugin does file.analysis.analyze(); if result.ast is returned. However, file.analysis.wasAnalysed always returns false, so file.analysis.analyze(); actually does nothing there, so it's not able to recognize and resolve the imports. If setting file.analysis.wasAnalysed = false, it analyses the file correctly and recognized the imports/require added by @babel/polyfill. So my question is, why or when does file.analysis.wasAnalysed becomes false here? :/
Since it's a private var, I'm not sure that it's a pretty solution to set it to true, also I still don't fully understand it yet. file.analysis.requiresTranspilation returns false though, so I guess it's not transpiling with TypeScript over again.

@eddyw I think you need to investigate it. The last time I touched Babel - was a very long time ago =(

Still relevant?

@nchanged I'm not working with FuseBox right now, so I didn't have time to make much progress and learn how Fusebox works. I'd like to keep the issue open though :P
Main reason why I wanted to work on the plugin was because of the automatically inserted polyfills but I haven't figured out yet how Fusebox works and how to make it follow and transpile the auto-inserted imports or requires. They are just ignored.

This still seems relevant, when using @babel/core 7 I get an error where it's looking for babel-core via FuseBox.

Merry Christmast PR 🙌
I've taken time-off until end of year and decided to work on this today. I haven't done anything about the polyfills (it'll just complicate it) but I've ported all the logic from babel plugin to make it work with babel7.
I'm starting a new project next year which will likely use FuseBox and I'd love to have babel7 plugin, so I'll be more focused on making it work and solve any issues :)


Add CodeQL workflow

Description of changes
Add the CodeQL GitHub workflow.

Was able to onboard to CodeQL using the methods in #441


Support signalfd on Android

Add target_os = "android" to the signalfd code (target_oses are listed in alphabetical order.

Resolved by #739.


[dvsim] DVSIM check X_PROP result

Description
Based on the discussions and preparation for V2.5; it was suggested that there should be a DVSIM check for the result of the tools to see if X_PROP_ANALYSIS_COMPLETED can be signed-off.
Add a check in dvsim that ensures 100% instrumentation success and fails if <100%.

CC @andreaskurth / @cindychip

This is a tooling issue and I believe there are alternative ways to extract that result from the tools directly. Moving out of M5.


Passing props to elements

Hello!
I would like to know how to pass a scoped element props to the elements.
/* page.astro */
---
const value = [ ];
---
<div class="paragraph">
  <MyPortableText value={value} />
</div>

<!-- The styles have to be here, as it is unique to this page -->
<style lang="scss">
  .paragraph {
    color: green;
    ul {
      color: red;
    }
  }
</style>

/* MyPortableText.astro */
---
import { PortableText } from 'astro-portabletext';
import { mergeComponents } from 'astro-portabletext/utils';
import Block from './Block.astro';
import List from './List.astro';
import ListItem from './ListItem.astro';
import Mark from './Mark.astro';

type PortableTextProps = Parameters<typeof PortableText>[0];

export type Props = Pick<PortableTextProps, 'value' | 'components'>;

const { value, components: overrideComponents = {} } = Astro.props;

const components = mergeComponents(
  {
    block: Block,
    list: List,
    listItem: ListItem,
    mark: Mark,
  },
  overrideComponents,
);
---
<PortableText value={value} components={components} />

Everything in that text is green – that's correct, but the ul inside isn't red as I specified.
I tried almost every strategy, but nothing works. Is there any way to pass all props to all the elements? The astro scoped styles add something like data-astro-cid-someid and I need to pass that for every element with {...props}.

Hi @milewskibogumil the best way is to use :global() selector. See Astro docs mix global & scoped CSS rules
<style lang="scss">
  .paragraph {
    color: green;
-   ul {
+  :global(ul) {
      color: red;
    }
  }
</style>

Yes, it is certainly an option, but I need to have this SCSS scoped. There is no way to pass props from astro to Portable Text elements?

That's it, thank you @theisel!


Add Code of Conduct

I would like to add a code of conduct file as code of conduct is a necessary file which the contributors need to follow so that everyone follows a decorum.

I would love to work on this issue as a part of Girl Script Summer Of Code. Kindly assign it to me.

Can you assign this issue to me, once approved I can start working on it under GSSOC'21.

hello @Ayushbajpai19 @muthuannamalai12  the code of conduct file is already added please first go through the project files and then raise a issue.
best of luck for gssoc2021!

@vaibhavirohilla741 When we click on the code of conduct hyperlink in Custom message shown by welcome bot it say 404 page not found error.

@vaibhavirohilla741 Can I start working on it??

Yeah!

@vaibhavirohilla741 Can i work on this issue and contribute to project

Yes @435akashjha don't ask same question.
Do the changes I'll provide you gssoc label😁.
Best of luck!!

Kindly assign me this issue under GSSOC 2021.


Add proj local frame projector

This PR adds a projector that uses the common Proj Library to allow projections between arbitrary geodesic and Cartesian reference frames. The projector takes in a base frame and target frame specified as proj library strings and generates the necessary projection between the two.
This PR is based off source code originally developed as part of the CARMA Platform and requested as a PR to this repo by the Autoware Foundation
Original Source Code: https://github.com/usdot-fhwa-stol/autoware.ai/blob/carma-develop/common/lanelet2_extension/include/lanelet2_extension/projection/local_frame_projector.h
NOTE: Not yet ready to merge.
There is still some work required to make this code functional as this creates a dependency on the Proj library and will require updates to the CMakeList.txt file.
How would the Lanelet2 maintainers prefer such dependencies be managed?

Actually these proj strings are one of the reasons that speak against proj. I think they are error-prone and not restrictive enough to ensure that the chosen projector is actually suitable for the task.
If handling proj strings is so important, I think it would be better (and more transparent) to have a utility function that tries to parse and translate them into one of lanelet2's projectors and otherwise raises an error if the string is not supported. What do you think of that?

@poggenhans I understand your concern, but I would think it's the responsibility of the user to ensure their string is properly constrained. There are command-line tools for proj that can be used for testing the string in question. A utility function to do the conversion is certainly an alternative approach, but it would potentially lead to more user confusion as the output might differ slightly from the output of proj tools if the accuracy differences you describe are present in any given conversion. Creating such a utility function is probably not something I would be able to commit time to at the moment as it would be a fairly substantial undertaking to write both the interpretation of the string and more projectors to go with it. This PR could be left up until then, or an alternative enhancement request issue could be opened referencing this.

I'm closing this PR since it looks like it will not get merged.
There were a few bug fixes discovered for this feature during use in the CARMA project and users wishing to use the most stable version of this feature can see the implementation here
https://github.com/usdot-fhwa-stol/autoware.ai/blob/carma-develop/common/lanelet2_extension/include/lanelet2_extension/projection/local_frame_projector.h
https://github.com/usdot-fhwa-stol/autoware.ai/blob/carma-develop/common/lanelet2_extension/lib/local_frame_projector.cpp


deprecated

Issue opened with imdone.io from code comment on 9f751f1
CHANGED  deprecated id:14

https://github.com/imdone/imdone-atom/blob/9f751f14f022fed15d90b360e4f50f43250dcb82/lib/views/imdone-atom-view.coffee#L24-L29

Issue closed with imdone.io by removing a comment.

https://github.com/imdone/imdone-atom/blob/b7251b7ccf00e69c484ae85d9668078cedb7152e/lib/views/imdone-atom-view.coffee#L24-L29


Bug with using measure and lines inside a table

The following code returns a size of (0pt, 0pt), while measuring other elements like rect or box works.
#tablex(
  style(st => {
    measure(line(length: 1cm), st)
  })
)

This error occurs when trying to use cetz canvas (0.1.2) insides tablex, see https://github.com/johannes-wolf/cetz/issues/345.

This was actually a huge oversight by my part, and broke not only measuring lines but also, really, placing any lines inside the table, as I was using #show line: place.with(top + left, dy: some-constant-here). Thanks for reporting!


Port element is not deleted even after deletion of deployment specification

Description
Port element is created when a DS is created, the port element should be deleted after deleting the DS, But port element remains even after deleting the DS.
Expected Behavior
Port element should be deleted after the deletion of Deployment Specification.
Actual Behavior
Port element remains even after deletion of Deployment Specification.
Steps to Reproduce

Create manually VC(using SDN NSC plugin)
Create manually MC, DA and DS
Using any of REST Client make GET API request using below URL
https://OSC-IP:8090/sample/sdn/nsc/controller/OpenStack IP/portElements
Id of newly created port element will be listed as a response.
Manually Delete DS
Again make GET API request using below URL
https://OSC-IP:8090/sample/sdn/nsc/controller/OpenStack IP/portElements
The Id of port element is still listed.

Additional Information
A new port element will be created after creating new DS, the port element that was created earlier by DS will also be listed even after deletion of DS, so both the port elements get listed when above GET request call is made.
Environment

OSC Version/Build: Build:14-g7adf532, 2017-11-27T16:45:44Z
Cloud Provider Info:
Plugin Info: SDN NSC plugin
Other:

Status

[ ] Reproduced
[ ] In Progress
[ ] Validated     =>    Verified in Version/Build:

As a work around one can go and delete the port entities via the rest api's.


why is there a key placed here?

seed 236348 default settings has a key. why?

gonna assume this was a fluke or has been fixed accidentally


Initial pip package.

Pull Request Description
What issue does this change request address?
Closes #379
What are the significant changes in functionality due to this change request?
This adds the files necessary to build a pip package to the repository (note that this probably only works on Mac and Linux because of the symbolic link).

For Change Control Board: Change Request Review
The following review must be completed by an authorized member of the Change Control Board.

[ ] 1. Review all computer code.
[ ] 2. If any changes occur to the input syntax, there must be an accompanying change to the user manual and xsd schema. If the input syntax change deprecates existing input files, a conversion script needs to be added (see Conversion Scripts).
[ ] 3. Make sure the Python code and commenting standards are respected (camelBack, etc.) - See on the wiki for details.
[ ] 4. Automated Tests should pass.
[ ] 5. If significant functionality is added, there must be tests added to check this. Tests should cover all possible options.  Multiple short tests are preferred over one large tes.
[ ] 6. If the change modifies or adds a requirement or a requirement based test case, the Change Control Board's Chair or designee also needs to approve the change.  The requirements and the requirements test shall be in sync.
[ ] 7. The merge request must reference an issue.  If the issue is closed, the issue close checklist shall be done.
[ ] 8. If an analytic test is changed/added, the the analytic documentation must be updated/added.
[ ] 9. If any test used as a basis for documentation examples have been changed, the associated documentation must be reviewed and assured the text matches the example.

@j-bryan  Ping.


Propagate error from spawned task reading spills

Which issue does this PR close?

Closes #7509.
Rationale for this change

Any error happened in the spawned task reading spills cannot propagate out currently. So these errors will be ignored and it doesn't look correct as the sorted result will be incorrect.
What changes are included in this PR?

Propagating errors from spawned task reading spills.
Are these changes tested?

Are there any user-facing changes?

Thank you @alamb


Make the error domain and codes public and documented.

Fixes #2107.

I'm not sure it's a good idea to duplicate the documentation in grpc/status.h here.

We need to, for it to be part of the generated documentation. I also modified it to make it specific to RPCs, and the client use case, which the one in grpc/status.h isn't.

OK, that's a good enough reason for me. Also, there's a merge conflict.

Solved conflict.


Combine multiple pseudo selector

Description:
Support multiple pesudo selectors
Current:
Using makestyle, if we want similar CSS properties on active and hover, we have to repeat our code,
Expected:
There should be a way in which we can combine multiple pseudo selectors

Tip, you can use the same comma syntax as with CSS


.navbar-expand-* .nav-link issue

Currently .nabvar-expand-* classes adds padding to .nav-link wrapped by media-breakpoint-up
https://github.com/twbs/bootstrap/blob/v4-dev/scss/_navbar.scss#L168-L171
This should be moved few lines above to media-breakpoint-down https://github.com/twbs/bootstrap/blob/v4-dev/scss/_navbar.scss#L143
It would be great if those paddings were variables.
EDIT:
should be moved to media-breakpoint-down

Without a screenshot or demo of what you're running into, I can't help more. The paddings have been built this way by design. Agreed though we need variables there.

If you plan to make variables then moving to media-breakpoint-down is not necessary


Issue with k8s.io/docs/tasks/tools/install-minikube/: too superficial?

[ ] Feature Request
[X] Bug Report

Problem:
Hi there! This is a weird documentation at the moment: https://kubernetes.io/docs/tasks/tools/install-minikube/.
If you look at it closely, at the moment, in its most important part It's just a link to a github download page.  There could be better instructions for this.
Proposed Solution:
Instructions for how to install minikube in different platforms.
I am happy to (maybe slowly) work on something like this if you agree that this is needed. I can probably contribute instructions for Linux (Debian/Ubuntu), Windows and OSX. Thanks!

Never mind. If you scroll down on the github release page there are clear instructions for how to install it. My bad :-)


Update try it guide

Fix some spelling and update the dictionary. I'm a bit disturbed that I had to put "tl" and "dr" as separate words to get it to accept tl;dr. Do you know if there is a better way to do this?
Removed non-existing section from TOC
Added section for tear down to make it easier to find. I'm wondering if it would make sense to put this as a level 2 section at the end instead? Then we would have 1) Environment setup 2) Working with environment 3) Tear down environment. What do you think?
Updated logs example to use the new deployment name.

In 2.5. Running Custom Cluster API Provider Metal3  the instruction is to scale down the statefulset:
kubectl scale statefulset capm3-controller-manager -n capm3-system --replicas=0
I am wondering why we should scale down statefulset instead of deployment? I think the procedure should be same that it is in 2.4.

In 2.5. Running Custom Cluster API Provider Metal3 the instruction is to scale down the statefulset:
kubectl scale statefulset capm3-controller-manager -n capm3-system --replicas=0
I am wondering why we should scale down statefulset instead of deployment? I think the procedure should be same that it is in 2.4.

Well spotted! I think you are correct that this should be deployment in both places.
 It also looks like the bare-metal-operator should be changed to capm3-baremetal-operator-controller-manager. Will update the PR. :slightly_smiling_face:

I'd probably avoid using "tl;dr" in the official documentation

/approve


Feat/allow relative imports in custom rule folder

Closes #1122
Still requires documentation.

Looks good! Interesting enough, recently I got similar question from someone regarding relative importing in external rules. Workaround was to add 'sys.path.append' inside rule module, before import. This PR should fix it.

Awesome. If you're convinced, I'll add some docs somewhere this week.

I added a section on using an external rules folder. It includes the new import capabilities. Please let me know if it's clear like this.


Add real counter semantics

Would like to track the current value of counters over a long period of time.
For example, how many get requests has my site ever received. Right now I don't see an easy way to do with with Prometheus due to resets on process restart. The only solution that I can see it to save the actual counter values in some shared DB outside of the processes and Prometheus.
This is particularliy problematic for distributed applications that are best not being tighly coupled through share writable state and restart often (which IMO is the modern version of a GC).
Issues like this https://github.com/prometheus/prometheus/issues/1334 propose a solution, but will not work because of limited retention times.
A solution could be server and client library support for counter semantics
Rather than send the current value to the server, clients would send increment commands. The server would be responsible for caching (or loading) the last value, incrementing by the amount sent, and storing the result.
Client libraries would have to be changed to expose increments since last scrape. Yes, this gets a bit tricky because a scrape could happen followed by a server crash (or whatever) resulting the increment command being lost. A few ways to handle this:

Just acknowledge and ignore the problem. It is not any worse than today where the data for counters is discarded by design unless clients track it.
Add versions, acks, etc. (much like an MQ protocol) to provide more robust updates
I assume you'd still support the current semantics (counter v1) that would allow clients to track and report values directly. They could then use whatever means they want to ensure correctness (as they'd do today).

Expected result
Prometheus would get a new style of counter that could increment over any period of time. You might only have the last 1 month of data points, but each counter's last value would be useful. Today, counter are really only useful for rate unless the clients to a bunch of work or the counters are short lived.

There are gauges for this genre of timeseries data; just use a recording rule to aggregate them on a fixed time interval, e.g. to sum them up on a 1-minute interval by instance and request type.

I think you don't understand how Prometheus counters work, please see https://www.robustperception.io/how-does-a-prometheus-counter-work/ and my upcoming talk at Cloudnativecon Europe in a few weeks.
If you've further questions about counters, you can ask them at https://groups.google.com/forum/#!aboutgroup/prometheus-users


Include Kubeapps in the TCE Repository

Proposal
Include the Kubeapps application in the TCE repository so that users can view and interact with the packages available in the TCE repository via the Kubeapps UI, which now supports browsing and installing Carvel packages.
This requires ensuring that the Carvel source package for the latest stable release of Kubeapps is available in a git repository.
In addition, once Kubeapps is installed, users would be able to enable the helm support and add the Bitnami application catalog to then be able to view and install both Carvel packages from the TCE repo as well as Helm packages from the Bitnami catalog.
Note: this proposal originated as #2418, but that proposal mixed two separate proposals: (1) adding Kubeapps to TCE and (2) adding the Bitnami Application Catalog as Carvel packages to TCE. This proposal focuses on the (1) only.
Background
Kubeapps now supports Carvel packages (and Flux packages) in addition to Helm packages, so can be used to provide a visual catalog of the TCE repository to TCE users:

Or with the Helm support enabled (and the Bitnami Helm app repository) so that both Helm and Carvel packages can be viewed:

Questions
While looking at the options for packaging Kubeapps as a Carvel package recently (including using a carvel package generated internally by the Bitnami Application Catalog), there have been a couple of questions/uncertainties from my side.
1. Admin access required for service account used with Carvel PackageInstall
Similar to a number of other packages already in the TCE repository, the Kubeapps package includes a CRD with a corresponding controller that runs as part of the install. This means that the service account used to reconcile a Carvel package with a CRD will need to have enough RBAC not only to create the CRD at the cluster-scope, but also to create a service account for the controller that services the CRD with the RBAC it requires to react to changes of a CR in any namespace. In the general case (as with some packages in the TCE repo), this appears to mean something akin to cluster-admin. In the Kubeapps-specific case, the cluster-wide RBAC required by the controller is limited to get/list on Kubeapps' own AppRepository custom resource (the controller doesn't generate other resources in the namespace of the AppRepository).  See the slack conversation where I asked about this.
2. Carvel packaging using helm-template
Since Kubeapps is already part of the helm Bitnami Application Catalog (with security updates and lots of maintenance improvements handled by the Bitnami team), the path of least friction and most value for us would be to use the existing maintained Helm chart with the helm-template option for the carvel package. This option has been used in the past by @vrabbi as well as the Bitnami team and some tooling exists.
When I first looked at the Carvel packaging requirements, I saw that although Helm charts can be used as a source for the upstream content, the docs don't mention using the helm-template option for kapp to generate the template during the install (with user-supplied values). In fact, the other details for the packaging assume that the package always has the vendored yaml with ytt overlays etc.
But I checked on slack and the response was that it should be fine to use helm-template, it's just not documented yet because people haven't yet used that for TCE packages.
Limitations
Kubeapps and Contour
Kubeapps currently has an issue when the Contour ingress controller is installed. In particular, Kubeapps can only be used with (service-account) token authentication when Contour is installed, until the Contour team implement the ability to disable the currently automatic gRPC-web -> gRPC translation.
Service-account token authentication is only recommended for demos, but OIDC auth for Kubeapps won't be possible currently unless the above Contour issue is resolved.
Packaging versions and App versions
The Bitnami Kubeapps chart is updated regularly with fresher images for subcomponents or other packaging-only related changes, which creates a new chart version without changing the app version. Helm has the concept of separate package and app versions, where Carvel does not. We'll need to think about versioning carefully when translating automatic updates from the chart to the carvel package.
High-level implementation path
I'll be seeing what I can re-use from the Bitnami team's Helm -> Carvel package translation to generate the carvel package source in a public github repository as per the tce packaging docs. Other steps in the tce packaging doc requirements may not be relevant (lock container image references, add configurable params etc.) since they are already handled by the helm-template. Once we have a git repo with the package source,  we can test it for inclusion in the TCE repo and add our own CI for upgrades etc.

@absoludity you have all my attention and support :-D Love to see this coming through.
A couple of comments, when come to the implementation:

Would be awesome if rbac for the PackageInstall could be narrowed down to what's needed and not to cluster-admin. I know all packages currently do cluster-admin, but to be honest, we should be more serious about enforcing only what's needed. Since you brought up the topic and probably have the skills, would be awesome to guinea-pig the narrowing down of RBAC to see what (if anything) would need to change from TCE side to better support this scenario.
We're working on providing ARM support, and we should request any new package that gets accepted to provide images for ARM64 architectures. I would expect that kubeapps will already come with this support :-D
For first implementation, the OIDC problem you describe above shouldn't be a stopper, but when contour provides what kubeapps needs, I would love to see better integration.
If possible, rely on existing packages on the TCE repo for require capabilities and don't bring your own. There's no mechanism in kapp-controller to enforce dependencies on other packages (yet) so it will need to live in the documentation for now.

@absoludity you have all my attention and support :-D Love to see this coming through.

Excellent, thanks @jorgemoralespou

A couple of comments, when come to the implementation:
* Would be awesome if rbac for the PackageInstall could be narrowed down to what's needed and not to cluster-admin. I know all packages currently do cluster-admin, but to be honest, we should be more serious about enforcing only what's needed. Since you brought up the topic and probably have the skills, would be awesome to guinea-pig the narrowing down of RBAC to see what (if anything) would need to change from TCE side to better support this scenario.

Yep, for Kubeapps I don't see this as a big issue (since our CRD controller doesn't create resources in namespaces). It was more a general question about adding CRDs as part of Carvel packages and whether there was some separate process I needed to follow since, afaict, if the package has a CRD that  deploys a controller which needs to respond to changes on the CRD in any namespace and create/update resources in any namespaces, then the installer effectively needs something close to cluster-admin for certain resources (ability to create RBAC that allows controller to create/update resources in arbitrary namespaces). Sounds like there's not yet a separate process, and as above, not so much an issue for Kubeapps, so no issue there. I'll just be using the required RBAC for our AppRepository resource only.

* We're working on [providing ARM support](https://github.com/vmware-tanzu/community-edition/issues/2171), and we should request any new package that gets accepted to provide images for ARM64 architectures. I would expect that kubeapps will already come with this support :-D

Oooh , interesting. I'll keep that in mind and check our arches.

* For first implementation, the OIDC problem you describe above shouldn't be a stopper, but when contour provides what kubeapps needs, I would love to see better integration.

Great.

* If possible, rely on existing packages on the TCE repo for require capabilities and don't bring your own. There's no mechanism in kapp-controller to enforce dependencies on other packages (yet) so it will need to live in the documentation for now.

We depend on two other helm charts (postgresql and redis) which don't yet seem to be in the TCE repo. I think they're currently included (tgz's) in the kubeapps carvel package. Not sure if you mean I should be getting those packages (from the bitnami charts) into the TCE repo first? Seems like right now, it'd be better to have a Kubeapps package that controls its dependencies out-of-the-box (as the helm chart does?)

I was referring to contour and cert-manager if needed for ingress, since they typically are.

Just an update here:

I've a package-for-kubeapps repo which has the desired directory structure, with two versions, 8.0.9 and 8.0.10 (only the package 8.0.10 works).
The repo includes a script that builds and pushes a new version.

The repo is itself private at the moment until approved etc., but you can manually add the package meta and package from the following gist:
kubectl apply -n kapp-controller-packaging-global -f https://gist.githubusercontent.com/absoludity/0ae853e3e826293e06369ac485cacc2d/raw/8a46f71fe2c0061ff405b49189fba92d7f884e15/kubeapps-carvel-pkg-8.0.10.yaml

and then install with:
tanzu package install kubeapps --package-name kubeapps.community.tanzu.vmware.com --version 8.0.10

(of course, add --values-file my-values.yaml to add other settings, such as enabling carvel rather than flux).
I have a bunch of follow on tasks that I'm going to work on (see issues for the above repo), primarily the triggering the packaging automatically, adding e2e test for the carvel package install (and upgrade?) etc.
Regarding other topics mentioned above:

Package versions and App versions: I've ended up using the package version here since, as @vrabbi pointed out, the includedSoftware option that is outlined (and already landed) in https://github.com/vmware-tanzu/carvel-kapp-controller/issues/212 is exactly what I'd want to use.
ARM support: I'm using the official bitnami chart/images to generate the kubeapps carvel package here. The Bitnami catalog doesn't yet produce arm support. We'll need to look at options here.
RBAC: afaict, the tanzu install command is creating a service account to be used with the install, which currently has the required privs for creating CRDs etc. Is there a plan for this to be narrowed down, or for packages to specify what RBAC they need for installation/upgrade (for the service account that will do the reconciliation)
The contour issue (ability to switch off the grpc-web->grpc translation) is not yet available, so the workaround with the HTTPProxy will still be required on TCE where contour is running (and we can only use the demo-only token authentication). See this comment for the work-around.

@absoludity what's the current status of this?I know there's been many updates to the package. It seems the package repository is public, so where do we stand with regards to the other issues here described?

Hi @jorgemoralespou . I think we chatted on slack about this a few weeks ago, when I asked:

Not urgent, but when you get a chance, if you can have a quick look through the remaining issues I've highlighted for the carvel package in case any are essential in your view (I don't think the remaining ones should be blockers, but keen to get your thoughts):  https://github.com/vmware-tanzu/package-for-kubeapps/issues

You'd replied that the issues sound as non critical... I'd assumed that meant non-critical for blocking Kubeapps in the repo. Are any of those issues required to be able to accept Kubeapps in the repo? If so, please let me know which one(s) and I'll prioritise those. The contour issue isn't something we can fix (only work around), but the others are all listed at https://github.com/vmware-tanzu/package-for-kubeapps/issues

I don't think they are blockers, but since time has passed, wondering if any was addressed.
I'm ok with the current state.

I don't think they are blockers,

Yep, same.

but since time has passed, wondering if any was addressed. I'm ok with the current state.

No - given there were no blockers, I moved on to other work which were blockers (right now just finishing the work to ensure Kubeapps returns a combination of available apps from multiple plugins when enabled). Looking at those issues, some of them are going to be harder to solve (eg. things requiring automation and VPN together, such as automatically updating the repo whenever a new chart is published) and provide less value.
The two that I would (personally) prioritise out of those are #8 and #4 , since those are both things that I would expect from an author of a carvel package (based on the docs) and are something we can do without infrastructure constraints (I only skipped those for time reasons at the time). So unless you think otherwise (let me know), I'll prioritise those two and pick them up soon?

I don't think they are blockers, but since time has passed, wondering if any was addressed.
I'm ok with the current state.

Thanks @jorgemoralespou! So then, what are the next steps?

I've fixed https://github.com/vmware-tanzu/package-for-kubeapps/issues/4 so all images within the chart end up resolved in the .imgpkg/images.yml automatically, and closed https://github.com/vmware-tanzu/package-for-kubeapps/issues/8 after reading in the docs that a tag is perfectly valid for the imagepackageBundle.image .
Released 8.1.2 with those changes.
Let me know if any of the other issues need attention.

Thanks @absoludity for your update here.
Let's wait for TCE engineers comments to move forward.

It might take some days as after kubecon most of them team will be out some days.

I just saw via slack this PR which proposed adding a new package to the TCE repo, so I assume we need to do the same. I'll set up a PR for that: #4096

Thank you @absoludity! Let's set up this PR for adding Kubeapps to the TCE repo.

@ppbaena @absoludity yes, create the PR as that will be the easiest way to get this rolling

Thanks @jorgemoralespou!

@ppbaena @absoludity yes, create the PR as that will be the easiest way to get this rolling

Done in #4666 , just need to sort out the markdown lint in the README.md (doing currently).

Thanks @seemiller! Now that https://github.com/vmware-tanzu/community-edition/pull/4666 has been merged, the proposal is ready to be moved to complete status.


Support passing multiple i18next modules to RemixI18Next

Based on this discussion: https://github.com/sergiodxa/remix-i18next/discussions/136
Currently, you can only pass an i18next back end module to RemixI18next using the backend option.
However, it would be useful to be able to pass one or more modules of any type that can be passed to the internal i18next instance.
In my particular use case, I'd like to configure RemixI18next to use a custom I18nFormat plugin.
What has changed in this PR?

Introduce an optional plugins option that is an array of i18next plugins.
Deprecate the backend option in favour of using plugins
Update the type signature of backend to accept NewableModule<BackendModule<unknown>> | BackendModule<unknown>

This is primarily to simplify test setup to allow plugins to be objects instead of full-blown classes

Add tests to confirm that plugins are being used by RemixI18Next, whether they are set on backend, plugins, or both
Update example in README to use plugins

Hello @sergiodxa, what do you think of this possible approach?

Hi @sergiodxa, could you please give this a look? This PR would allow me to apply more customization plugins to Remix's i18next instance besides the Backend plugin. 🙏🏻


Paste Event Inside

Is your feature request related to a problem? Please describe.
It is frustrating to not be able to paste an event within another one (ex: pasting a dialogue event within an if/else function or a switch).
Currently, you need to paste the event after or before and move it within the correct position.
Describe alternatives you've considered
I don't really have a good solution in mind so I'll throw different ideas:

Add the options in this droplist:

I don't know if this is a good idea because it would require adding an arrow for "else", "when" (others?) statements.

Add a Paste Event button next to the Add Event button:

Grey it out if no event has been copied.
This might look ugly, but I think it's a better alternative than 1)

Right click within a "if", "else", "while" (others?) statement to show the option.
I don't think the right click is used much in GB Studio though so not ideal either.

Since 1.2 you can hold the Alt key to turn all Add Event buttons into Paste Event buttons allowing you to paste events into control flow branches.

Oh I see. Thanks for the tip! That will help a lot.
Maybe it could be a good idea to make the feature a bit less hidden then? The default button could read "Add Event (Hold ALT to paste)" or something?

Or split it into two buttons if something's in the Clipboard?

Please add the the down arrow found on the right side of "Event" blocks to the "Add Event" block. This dropdown menu could always contain "Paste Event", but have it grayed out when there isn't an event in the clipboard.


[WIP] Add Deny reason and stage count to the request expandable content

Add Deny reason and stage count to the request expandable content.
Update package versions.

Codecov Report

Merging #47 into master will not change coverage.
The diff coverage is 50%.

@@           Coverage Diff           @@
##           master      #47   +/-   ##
=======================================
  Coverage   42.95%   42.95%
=======================================
  Files          48       48
  Lines         433      433
  Branches       46       46
=======================================
  Hits          186      186
  Misses        214      214
  Partials       33       33

Impacted Files
Coverage Δ

src/utilities/store.js
0% <ø> (ø)
:arrow_up:

.../smart-components/request/request-table-helpers.js
50% <0%> (ø)
:arrow_up:

src/smart-components/request/expandable-content.js
50% <100%> (ø)
:arrow_up:

Continue to review full report at Codecov.

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

@Hyperkid123 - please review


go-pluginserver terminated: exit 0, context: ngx.timer

I ran go-hello plugin on ubuntu18.04 os，but encounter problems below:
2020/04/01 11:30:33 [notice] 18798#0: *9 [kong] go.lua:95 go-pluginserver terminated: exit 0, context: ngx.timer 2020/04/01 11:30:33 [notice] 18798#0: *9 [kong] go.lua:84 Starting go-pluginserver, context: ngx.timer
with the error log file keep refreshing until stop kong.
Many thanks!

because of my nginx daemon have no permission.


generate tests YAML automatically

How can we generate the YAML measurement manifest?
@mustafacc
@simbilod

Last time there was a GUI-based app that could be downloaded at pip install SiEPICLabTestParam3 python
This defined a YAML file with a list of devices associated with tests:
Devices:
  EBeam,JoaquinMatres,Simon,2,6:
    DeviceID: EBeam,JoaquinMatres,Simon,2,6
    Electrical Coordinates: []
    Optical Coordinates:
    - 57.0
    - 5972.0
    Polarization: TE
    RoutineCheck: true
    Routines:
    - Fixed Voltage Wavelength Sweep:JoaquinSimon
    Type: device
    Wavelength: '1550'

And tests:
  Fixed Voltage Wavelength Sweep:
    Default:
      Channel A: true
      Channel B: true
      ELECflag: false
      IV: false
      Initialrange: '-20'
      Laseroutput: High power
      MaxA: ''
      MaxB: ''
      MinA: ''
      MinB: ''
      Numscans: '1'
      OPTICflag: false
      PV: false
      RV: false
      RangeDec: '20'
      ResA: ''
      ResB: ''
      Start: '1480'
      Stepsize: '1'
      Stop: '1580'
      Sweeppower: ''
      Sweepspeed: auto
      Voltages: 1, 2, 3
      Wavelengths: ''
      setvflag: true
      setwflag: false
    JoaquinSimon:
      Channel A: true
      Channel B: true
      IV: false
      Initialrange: '-20'
      Laseroutput: High power
      MaxA: 0, 0, 0, 0, 1, 1, 1, 2, 2, 3
      MaxB: 0, 1, 2, 3, 1, 2, 3, 2, 3, 3
      MinA: ''
      MinB: ''
      Numscans: '1'
      PV: false
      RV: false
      RangeDec: '20'
      ResA: ''
      ResB: ''
      Start: '1530'
      Stepsize: '0.1'
      Stop: '1570'
      Sweeppower: '0'
      Sweepspeed: auto
      VoltagesA: 0, 0, 0, 0, 1, 1, 1, 2, 2, 3
      VoltagesB: 0, 1, 2, 3, 1, 2, 3, 2, 3, 3
      Wavelengths: ''

See main repo:
The testing routine creation software is ready to be used and can be found on the SiEPICLab GitHub repository (https://github.com/SiEPIC/SiEPIClab). The executable can be found under the release called Testing Paramaters.


Add reasonable timeouts to API calls

Add reasonable timeouts to API calls to prevent entire application from hanging when a service goes down.

What is "reasonable" for a timeout?


Slim 3 passthrough all routes in apache

When no public routes set, middleware runs ok, but when add the following:
    "rules" => [
        new \Slim\Middleware\JwtAuthentication\RequestPathRule([
            "path" => "/",
            "passthrough" => ["/api/ping"]
        ]),
        new \Slim\Middleware\JwtAuthentication\RequestMethodRule([
            "passthrough" => ["OPTIONS"]
        ])
	]

Middleware just don't check JWT and passthrough all routes. The same code works fine on Slim 2, but Slim 3 don't.
Ps: Works fine on php built-in server, (without any dot (.) char in uri params), Apache doesn't work,  passthrough all routes. Current .htaccess:
<IfModule mod_rewrite.c>
    RewriteEngine On

    RewriteCond %{REQUEST_FILENAME} !-f
    RewriteRule ^ index.php [QSA,L]
    RewriteRule .* - [env=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
</IfModule>

Just tested with Apache 2.2.15 on CentOS 6.5. Everything works as expected.
$app = new \Slim\App;

$app->add(new \Slim\Middleware\JwtAuthentication([
    "secure" => false,
    "secret" => "supersecretkeyyoushouldnotcommittogithub",
    "rules" => [
        new \Slim\Middleware\JwtAuthentication\RequestPathRule([
            "path" => "/",
            "passthrough" => ["/api/ping"]
        ]),
        new \Slim\Middleware\JwtAuthentication\RequestMethodRule([
            "passthrough" => ["OPTIONS"]
        ])
    ]
]));

$app->get("/", function ($request, $response, $args) {
     return $response->write("hello");
});

$app->get("/foo", function ($request, $response, $args) {
    return $response->write("foo");
});

$app->get("/bar", function ($request, $response, $args) {
    return $response->write("bar");
});

$app->get("/api/ping", function ($request, $response, $args) {
    return $response->write("ping");
});

$app->run();

Yields
$ curl --insecure --include https://<IP_ADDRESS>/foo
HTTP/1.1 401 Unauthorized
Date: Tue, 15 Sep 2015 06:49:13 GMT
Server: Apache/2.2.15 (CentOS)
X-Powered-By: PHP/5.6.13
Content-Length: 0
Connection: close
Content-Type: text/html;charset=UTF-8

$ curl --insecure --include https://<IP_ADDRESS>/bar
HTTP/1.1 401 Unauthorized
Date: Tue, 15 Sep 2015 06:49:17 GMT
Server: Apache/2.2.15 (CentOS)
X-Powered-By: PHP/5.6.13
Content-Length: 0
Connection: close
Content-Type: text/html;charset=UTF-8

$ curl --insecure --include https://<IP_ADDRESS>/api/ping
HTTP/1.1 200 OK
Date: Tue, 15 Sep 2015 06:49:23 GMT
Server: Apache/2.2.15 (CentOS)
X-Powered-By: PHP/5.6.13
Content-Length: 4
Connection: close
Content-Type: text/html;charset=UTF-8

ping

As a sidenote you should move  RewriteRule .* - [env=HTTP_AUTHORIZATION:%{HTTP:Authorization}] up. Currently it is not reached because L flag in previous rule stops processing the ruleset.
http://httpd.apache.org/docs/2.2/rewrite/flags.html#flag_l

I forgot to mention, maybe it's important, the route is in a group and calling external controllers, something like this:
$app->group("/api", function () {
// Auth
$this->post("/auth", "Controllers\Auth:attemp");
// Administradoras
$this->get("/ping", "Controllers\Api:ping");
});
My index.php app is in a subfolder structure www/api/v3/public

Test the code above to see if it works with your Apache. If not then it is probably server config issue. If yes then can you provide minimal code which I can reproduce the bug with.

Don't work. I do a fresh install and it just passthrough with your code above. Foo route returning status 200 at http://<IP_ADDRESS>/api/v4/public/foo it's running over windows xamp. As I said previously, I'm not running directly on server root, as you do in https://<IP_ADDRESS>/foo, but on slim 2 it's not a problem

I tried php built-in server to call http://<IP_ADDRESS>:1337/foo still get 200 code.
My .htaccess:
RewriteEngine On

RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule .* - [env=HTTP_AUTHORIZATION:%{HTTP:Authorization}]
RewriteRule ^ index.php [QSA,L]

My index.php code test:
<?php

require_once '/vendor/autoload.php';

$app = new \Slim\App;

$app->add(new \Slim\Middleware\JwtAuthentication([
    "secure" => false,
    "secret" => "supersecretkeyyoushouldnotcommittogithub",
    "rules" => [
        new \Slim\Middleware\JwtAuthentication\RequestPathRule([
            "path" => "/",
            "passthrough" => ["/api/ping"]
        ]),
        new \Slim\Middleware\JwtAuthentication\RequestMethodRule([
            "passthrough" => ["OPTIONS"]
        ])
    ]
]));

$app->get("/", function ($request, $response, $args) {
     return $response->write("hello");
});

$app->get("/foo", function ($request, $response, $args) {
    return $response->write("foo");
});

$app->get("/bar", function ($request, $response, $args) {
    return $response->write("bar");
});

$app->get("/api/ping", function ($request, $response, $args) {
    return $response->write("ping");
});

$app->run();

Composer requires:
{
    "minimum-stability": "dev",
    "prefer-stable": true,
    "autoload": {
        "psr-4": {
            "App\\": "app/"
        }
    },
    "require": {
        "slim/slim": "3.x-dev",
        "tuupola/slim-jwt-auth": "~2.0@dev"
    }
}

I do a fresh install and just requires Slim 3 and Slim-jwt-auth 2dev

There is 200 code but what is the actual response? Response should be foo.  Looks like your vendor require is wrong (unless you really have it on the root of your hard drive). It should be something like following instead:
require __DIR__ . "/vendor/autoload.php";

PHP builtin server does not use .htaccess file so it kind of moot.

Response is foo, it's passing. Vendor autoload file is ok, it's serving and all routes still unprotected.
Sending a like of files, http://expirebox.com/download/2c68734ccef26a79cecb3336b7b1a522.html

Copy pasted your composer.json and index.php. Fixed the vendor require as mentioned above. Works as expected.
php -S <IP_ADDRESS>:8080 index.php
PHP 5.6.9 Development Server started at Tue Sep 15 16:19:16 2015
Listening on http://<IP_ADDRESS>:8080

$  curl --include  http://<IP_ADDRESS>:8080/foo
HTTP/1.1 401 Unauthorized
Host: <IP_ADDRESS>:8080
Connection: close
X-Powered-By: PHP/5.6.9
Content-type: text/html;charset=UTF-8
Content-Length: 0

Unrarred your file, ran composer install and internal PHP webserver. Works as expected. Feels like Windows issue to me.
$ unrar x slim3jwt.rar

UNRAR 5.21 freeware      Copyright (c) 1993-2015 Alexander Roshal

Extracting from slim3jwt.rar

Creating    public                                                    OK
Extracting  public/.htaccess                                          OK
Extracting  public/index.php                                          OK
Extracting  composer.json                                             OK
Creating    app                                                       OK
All OK
$ composer install
Loading composer repositories with package information
Installing dependencies (including require-dev)
...
Writing lock file
Generating autoload files
$ cd public/
$ php -S <IP_ADDRESS>:8081 index.php
PHP 5.6.9 Development Server started at Tue Sep 15 16:31:11 2015
Listening on http://<IP_ADDRESS>:8081

$ curl --include http://<IP_ADDRESS>:8081/foo
HTTP/1.1 401 Unauthorized
Host: <IP_ADDRESS>:8081
Connection: close
X-Powered-By: PHP/5.6.9
Content-type: text/html;charset=UTF-8
Content-Length: 0

Installed the lastest version of XAMP on windows, tried and same issue occurs, maybe it's a windows issue, because I have installed a totally fresh new webserver with php 5.6.12

I would check Vagrant. Having same development and deployment environment is a real life saver. Less "Works on my machine" issues :)

WAMP also fails, maybe a native windows problems. Slim 2 works fine on both XAMP/WAMP

I found a clue. If RequestPathRule is defined, it fails, if there's no RequestPathRule defined in rules, middleware works fine, but, in my case, I can't define public routes.
It works:
$app->add(new \Slim\Middleware\JwtAuthentication([
    "secure" => false,
    "secret" => getenv('APP_KEY'),
    "callback" => function ($request, $response, $arguments) use ($app) {
        $app->jwt = $arguments["decoded"];
    },
    "rules" => [
        new \Slim\Middleware\JwtAuthentication\RequestMethodRule([
            "passthrough" => ["OPTIONS"]
        ])
	]
]));

It doesn't work:
$app->add(new \Slim\Middleware\JwtAuthentication([
    "secure" => false,
    "secret" => getenv('APP_KEY'),
    "callback" => function ($request, $response, $arguments) use ($app) {
        $app->jwt = $arguments["decoded"];
    },
    "rules" => [
        new \Slim\Middleware\JwtAuthentication\RequestPathRule([
            "path" => "/",
            "passthrough" => ['api/ping'],
        ]),
        new \Slim\Middleware\JwtAuthentication\RequestMethodRule([
            "passthrough" => ["OPTIONS"]
        ])
	]
]));

I've tested in alot of routes, namespaces and groups possible, it's not miss configuration because the same code works on slim 2, it's just RequestPathRule problem, when missed, middleware works.

It is most likely this line which returns different value in Windows and *NIX hosts when using Slim 3. I do not use Windows myself so cannot debug.

I debug their two tuupola/slim-jwt-auth version 1.x 2.x and found the following error.
file slim-jwt-auth/src/JwtAuthentication/RequestPathRule.php
in version 2.x
at line 34 $uri = $request->getUri()->getPath(); this command in slim 3 returns the route without the bar at first, for example the route /auth/login returns auth/login
in version 1.x
at line 32 $uri = $app->request->getResourceUri(); this command in slim 2 returns with the bar /auth/login
with this regular expression under the function will not work correctly.
Sorry my English because I am Brazilian

I'm brazilian too =)
For some reason, in slim 2 this package works really fine, but, in slim 3, doesn't =(
I got a full rewrite of my application in slim 3, everything works fine, but, tuupola middleware don't worked, so, i go back to slim 2. Slim 3 got modern conventions and is more organized than it's forefather

$uri = $request->getUri()->getPath();
replace
$uri = "/".$request->getUri()->getPath();
while they do not release the patch.

Will try, thank you.
BR-PT: Elvis, usa o gitter? Qualquer coisa me chama nesta sala https://gitter.im/neomerx/json-api to sempre lá, trabalho bastante com Slim, Laravel e JSON-API/JWT abraços.

@tuupola as @elvispdosreis mentioned, at line 34 $uri = $request->getUri()->getPath(); changes to $uri = "/".$request->getUri()->getPath(); works o/

Is this in Windows version only or also *NIX? Note that Slim 3 itself is not released yet. There is only release candidate so breaks might occur.

Windows PHP 5.6.11 NTS

I cannot reproduce with OSX nor Linux so it seems like Windows issue. Because I do not have access to Windows can you test what the following returns.
<?php
require_once "./vendor/autoload.php";
$app = new \Slim\App;
$app->get("/foo/bar", function ($request, $response, $args) {
    return $response->write($request->getUri()->getPath() . "\n");
});
$app->run();

For me it returns the following.
$  curl --include http://<IP_ADDRESS>:8080/foo/bar
HTTP/1.1 200 OK
Host: <IP_ADDRESS>:8080
Connection: close
X-Powered-By: PHP/5.6.9
Content-type: text/html;charset=UTF-8
Content-Length: 9

/foo/bar

Apparently in windows you get only foo/bar?

this in windows I get foo/bar only if the initial route bar

Windows 8. @elvispdosreis patch fix the problem.

Thanks. Did some more testing and it happens only in *NIX hosts when installed into subfolder. Not sure yet if it is a bug or feature.

Submitted a bug report https://github.com/slimphp/Slim/issues/1554.

Thanks
Em 23/10/2015 5:50 PM, "Mika Tuupola"<EMAIL_ADDRESS>escreveu:

Submitted a bug report slimphp/Slim#1554
https://github.com/slimphp/Slim/issues/1554.
—
Reply to this email directly or view it on GitHub
https://github.com/tuupola/slim-jwt-auth/issues/9#issuecomment-150673897
.

This should now be fixed in 2.0.1.

Great. Keep your good job.


DeltaSHAPE does not work when comparing sequences with deletions

When I compare a sequence to itself, DeltaSHAPE produces a plot properly.
Comparing two replicates of the same sequence also produces a plot.
Comparing two constructs where one has a deletion that the other does not produces the error.
`WT_vs_dp = rnav.analysis.DeltaSHAPE(WT_m, dp_m).plot()

ValueError                                Traceback (most recent call last)
/Users/jwaldern/Documents/Jupyter/2023-07-03_QC_Merged_data_Analysis/2023-08-30_Replicate_comparisons_exons_WT34.ipynb Cell 82 line 1
----> 1 WT_vs_dp = rnav.analysis.DeltaSHAPE(WT_m, dp_m).plot()
File ~/RNAvigate/rnavigate/analysis/deltashape.py:56, in DeltaSHAPE.init(self, sample1, sample2, pad, mask_5, mask_3, z_coeff, z_thresh, ss_thresh, find_site)
54 sample1 = sample1.get_data_list("profile").data[columns].copy()
55 sample2 = sample2.get_data_list("profile").data[columns].copy()
---> 56 assert all(sample1["Sequence"] == sample2["Sequence"]
57            ), "Sequences don't match"
58 self.data = sample1.merge(sample2, how="left",
59                           on=["Nucleotide", "Sequence"],
60                           suffixes=("_1", "_2"))
62 # STEP TWO
63 # smooth data and errors
File ~/opt/anaconda3/envs/RNAvigate/lib/python3.9/site-packages/pandas/core/ops/common.py:65, in _unpack_zerodim_and_defer..new_method(self, other)
61             return NotImplemented
63 other = item_from_zerodim(other)
---> 65 return method(self, other)
File ~/opt/anaconda3/envs/RNAvigate/lib/python3.9/site-packages/pandas/core/arraylike.py:29, in OpsMixin.eq(self, other)
27 @unpack_zerodim_and_defer("eq")
28 def eq(self, other):
---> 29     return self._cmp_method(other, operator.eq)
...
-> 4973     raise ValueError("Can only compare identically-labeled Series objects")
4975 lvalues = extract_array(self, extract_numpy=True)
4976 rvalues = extract_array(other, extract_numpy=True)
ValueError: Can only compare identically-labeled Series objects
Output is truncated. View as a scrollable element or open in a text editor. Adjust cell output settings...
`

Hi Justin, I forgot about this. Hopefully I told you in person already; this issue was fixed a few months ago.


FAQ-Section is Added

Title : FAQ-Section is added in the website
Issue No. :  #412

Please merge the PR as soon as possible