Adjust logging output of osc-transformer-presteps

Currently we face several logging issues:

[ ] No message for successful extraction of a file
[ ] To much information on unsuccessful extraction to stdout
[ ] No log file
[ ] No possibility to adjust logging depth in the cli
[ ] No progress bar

No message for successful extraction of a file
When a file is extracted successfully there is no message, which is difficult to follow up on when you extract 100 pdfs as you never get an information if code is still running or not. Maybe this can also be solved by "just" a progress bar in stdout and a message to the log file that file was extracted successfully.
To much information on unsuccessful extraction to stdout
If a file is not of the correct type (like a json, xlsx in the moment) then the systems throws an error message. Maybe we should silence this to stdout and just mention in one line that a specific file was not extracted without filling the whole terminal with an error. Details should be stored in log file and only if logging depth is "low" enough.
No log file
No log file provided in the moment so no follow up possible.
No possibility to adjust logging depth in the cli
No possibility to adjust the logging depth to debug, info, ...
No progress bar
If you extract a lot of files it would be good to see how much files have already been processed.

https://github.com/os-climate/osc-transformer-presteps/pull/121


Closes #92 2.12 apply buttons

Coverage remained the same at 100.0% when pulling 708c50771b9b9d86f354724fd8c10cb00bcb9c24 on #92_2.12_apply_buttons into 4a840be03af267dcd6dbe2b9a48256872d301199 on dev.


no connection

Hey!
Thank you first for this nice plugin.
But Obsidian can't connect to the server.
When I open it up in the Browser this is showing up:
{"couchdb":"Welcome","version":"3.3.3","git_sha":"40afbcfc7","uuid":"e73edae4b386aa1a7cf7ae6895d0dd07","features":["access-ready","partitioned","pluggable-storage-engines","reshard","scheduler"],"vendor":{"name":"The Apache Software Foundation"}}
end under /{databasename}:
{"error":"not_found","reason":"Database does not exist."}
Can you help me?

Sorry for being late!
The database will be created after the plug-in has been connected. Please try Check and Fix database configuration once.


SyntaxError: invalid syntax during build

This happens with python3 (3.7) builds of mitogen 2.8 on Debian GNU/Linux "sid":
byte-compiling /<<PKGBUILDDIR>>/debian/python3-mitogen/usr/lib/python3.7/dist-packages/ansible_mitogen/__init__.py to __init__.cpython-37.pyc
byte-compiling /<<PKGBUILDDIR>>/debian/python3-mitogen/usr/lib/python3.7/dist-packages/ansible_mitogen/runner.py to runner.cpython-37.pyc
running install_egg_info
running egg_info
creating mitogen.egg-info
writing mitogen.egg-info/PKG-INFO
writing dependency_links to mitogen.egg-info/dependency_links.txt
writing top-level names to mitogen.egg-info/top_level.txt
writing manifest file 'mitogen.egg-info/SOURCES.txt'
reading manifest file 'mitogen.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'mitogen.egg-info/SOURCES.txt'
Copying mitogen.egg-info to /<<PKGBUILDDIR>>/debian/python3-mitogen/usr/lib/python3.7/dist-packages/mitogen-0.2.8.egg-info
Skipping SOURCES.txt
running install_scripts
  File "/usr/lib/python3.7/dist-packages/ansible_mitogen/compat/simplejson/decoder.py", line 148
    def JSONObject((s, end), encoding, strict, scan_once, object_hook, _w=WHITESPACE.match, _ws=WHITESPACE_STR):
                   ^
SyntaxError: invalid syntax

  File "/usr/lib/python3.7/dist-packages/ansible_mitogen/compat/simplejson/encoder.py", line 264
    False=False,
        ^
SyntaxError: invalid syntax

Full logs can be viewed at http://phd-sid.ethz.ch/debian/python-mitogen/
Ah Fedora is patching parts of it:
https://src.fedoraproject.org/rpms/python-mitogen/blob/master/f/remove-compat.patch

That's because of Python 3, hmm :)   Probably the simplest fix is to rename those files from .py -- setuptools shouldn't be looking at them at all. They are only used on Python 2.4. This is a super easy fix, will have it in 0.2.10.
Apologies for the convenience and thanks for reporting

To be clear, the .py rename requires an accompanying code change in (I believe) ansible_mitogen/

What I did is rm -rf */compat and then build. That is good enough?

0.2.9 builds just fine with the nulled init.py in */compat ;)

FWIW seeing this on FreeBSD ports too, which builds both 3.x and 2.x python flavours.
byte-compiling /tmp/usr/ports/sysutils/py-mitogen/work-py36/stage/usr/local/lib/python3.6/site-packages/mitogen/parent.py to parent.cpython-36.pyc
byte-compiling /tmp/usr/ports/sysutils/py-mitogen/work-py36/stage/usr/local/lib/python3.6/site-packages/mitogen/buildah.py to buildah.cpython-36.pyc
writing byte-compilation script '/tmp/tmpx7e7q3q1.py'
/usr/local/bin/python3.6 /tmp/tmpx7e7q3q1.py
  File "/usr/local/lib/python3.6/site-packages/ansible_mitogen/compat/simplejson/decoder.py", line 148
    def JSONObject((s, end), encoding, strict, scan_once, object_hook, _w=WHITESPACE.match, _ws=WHITESPACE_STR):
                   ^
SyntaxError: invalid syntax

  File "/usr/local/lib/python3.6/site-packages/ansible_mitogen/compat/simplejson/encoder.py", line 264
    False=False,
        ^
SyntaxError: invalid syntax

removing /tmp/tmpx7e7q3q1.py


Enable FW without airspeed sensor

Enables flying a fw / vtol without an airspeed sensor.
The new mode parameter enables 3 different modes:

Use values from airspeed sensor
Approximate airspeed with ground velocity (good if wind-still, e.g indoors with VICON )
Declare airspeed invalid, controllers will assume trim speed (e.g. TECS or fw attitude controller)

Jenkins test this please!

Very nice. To enable VTOL transitions without ASPS we need to change the transition logic to consider this param. A new (or existing param) should be used to add a time constant (front transition time).
At the moment we have a VT_F_TRANS_DUR (front transition duration) param which in effect is the ramp-up time for the pusher motor. To avoid confusion i propose to rename this to VT_F_TRANS_RAMP and use VT_F_TRANS_TIME as the new constant.
Alternatively we could rely on VT_TRANS_MIN_TM but this will have defaulted to low values by now.
@tumbili ?

SITL flies very well on mode 2 (disable airspeed) (transition still looks at airspeed) but the FW flights holds well even at very low airspeeds. TECS does respond too slow to compensate for stalls when the throttle trim is too low but it nicely balances banking etc.

So, in VTOL we need to use ground speed estimation to replace indicated_airspeed_m_s ?

@melisab You certainly don't need to do this and if you have an airspeed sensor available I certainly don't recommend you to do this.

@tumbili i added initial support for vtol transition based on minimum transition time. Works very nice in sitl. tested a few scenarios, no regression.

Notes on flying VTOL without airspeed sensor:

Make sure your FW_THR_CRUISE is set to a sensible level.
Set the airspeed sensor circuit braker
Set VT_TRANS_MIN_TM higher (this is the time it will take to transition)
Set VT_F_TRANS_DUR lower (this is the time the pusher takes to ramp up, 1 second should be good)

The problem with relying on ground speed is that when there is tailwind then there won't be enough lift to transition from MC to FW.

@melisab relying on fixed throttle settings is not the same as relying on ground speed. this would however only work when the fixed throttle is significantly above stall speed.

@tumbili time based blending is in

@sanderux This needs testing now. I'll do some basic tests in SITL.

@sanderux Tested all three modes in SITL, works as expected.

@tumbili considering all these changes only have impact on disabled airspeed sensor i see no possibility for regression. I think it's safe to merge this but i'll leave that up to you. I will test fly but that might be a while.

@tumbili The publish logic for EKF1 is missing, which is what planes are using still today.


How to disable lint when I'm developing...

I wanna mess up the code a lot XD

http://eslint.org/docs/user-guide/configuring#disabling-rules-with-inline-comments

Is there another way instead of Disabling Rules with Inline Comments?
I think there should be a config set to do this.
Sorry for the helpless issue T.T


api/synchronous without GPU

Is it possible to install api/synchronous without having a GPU server?

Yes, the code in the api/synchronous folder will work with or without a GPU.  The setup process is the same with or without a GPU; the only difference is that in the last step ("Run the Docker image"), you would run nvidia-docker if you have a GPU, or plain-old-just-docker docker if you don't have a GPU.
Hope that helps!

Hi Dan!

Yes, the code in the api/synchronous folder will work with or without a GPU. The setup process is the same with or without a GPU; the only difference is that in the last step ("Run the Docker image https://github.com/microsoft/CameraTraps/tree/main/api/synchronous#run-the-docker-image"), you would run nvidia-docker if you have a GPU, or plain-old-just-docker docker if you don't have a GPU.

Thanks for that very fast response.
The first step in you tutorial at https://github.com/microsoft/CameraTraps/tree/main/api/synchronous https://github.com/microsoft/CameraTraps/tree/main/api/synchronous is the installation of nvidia-docker. This I would have to replace with the installation of „plain-old-just-docker docker“, wright?
All other steps will remain the same, wright?

Thanks for reaching out.  You don't need a GPU to run anything in our repo, though obviously everything will run faster with a GPU.  A good ballpark is that you can process around 30k-50k images per day through MegaDetector v5 on a relatively modern CPU, and anywhere from 250,000 to 1M images per day on a relatively modern GPU.  We have some benchmarks here https://github.com/microsoft/CameraTraps/blob/main/megadetector.md#timing-results-for-mdv5.

We just have 300-500 images a day. So the performance is not that crucial for our application.

Hope that helps!

Thanks a lot for your help.
Kind regards
Rainer Prüller
DR. RAINER PRÜLLER
Managing Director
pentamap GmbH
Petersbachstraße 28/6, A-8042 Graz
+43<PHONE_NUMBER>
www.pentamap.com https://www.pentamap.com/

Am 26.04.2023 um 17:12 schrieb Dan Morris @.***>:
Yes, the code in the api/synchronous folder will work with or without a GPU. The setup process is the same with or without a GPU; the only difference is that in the last step ("Run the Docker image https://github.com/microsoft/CameraTraps/tree/main/api/synchronous#run-the-docker-image"), you would run nvidia-docker if you have a GPU, or plain-old-just-docker docker if you don't have a GPU.
Hope that helps!
—
Reply to this email directly, view it on GitHub https://github.com/microsoft/CameraTraps/issues/342#issuecomment-1523592085, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABUCN7GWNYRD7QLTVEZ6U4TXDE3N5ANCNFSM6AAAAAAXMN55DA.
You are receiving this because you authored the thread.

Yes, I think you probably want to install Docker rather than nvidia-docker.  I'm about 61% sure that you could install nvidia-docker and everything would work fine without a GPU, but it won't do anything useful for you, so, yes, I would just install Docker.

Dear Dan!
Due to your help I was able to install and run MegaDetector on my server. Thanks a lot for that.
I tested with Postman an got successfully this results:

--6018a6c8840b43aaa69dee4270946f90
Content-Disposition: form-data; name="detection_result"; filename="detection_result"
Content-Type: application/json
{"wildkamera-hirsch.jpg": [[0.05833, 0.1015, 0.72083, 0.5718, 0.979, 1]]}
--6018a6c8840b43aaa69dee4270946f90--

But I now have problems to interpret these results. What do these numbers mean:

[[0.05833, 0.1015, 0.72083, 0.5718, 0.979, 1]]

Thanks a lot for a short explanation or a link to the documentation.
Kind regards.
Rainer

Am 26.04.2023 um 18:07 schrieb Dan Morris @.***>:
Yes, I think you probably want to install Docker rather than nvidia-docker. I'm about 61% sure that you could install nvidia-docker and everything would work fine without a GPU, but it won't do anything useful for you, so, yes, I would just install Docker.
—
Reply to this email directly, view it on GitHub https://github.com/microsoft/CameraTraps/issues/342#issuecomment-1523680820, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABUCN7DVYPCRTV5DEXZ6QHDXDFB4XANCNFSM6AAAAAAXMN55DA.
You are receiving this because you authored the thread.

I'm about 98.7% sure that array will be, for each detection:
[y1, x1, y2, x2, confidence, category]
Where (x1,y1) and (x2,y2) are the upper-left and lower-right coordinates of the bounding box (normalized to the width and height of the image), and category is 1/2/3 for animal/person/vehicle, respectively.  So it looks like MegaDetector thinks you have one animal in this image, taking up more or less the upper-left quarter of the image.
Let us know if that doesn't add up, but... I'm 98.7% sure.

Thanks a lot for your explanation. Your are 100% right👍🏼

Hi Dan!
One more question to the now running MegaDetector service: I can successfully test it with Postman - but I can't access it with PHP-CURL:
$curl = curl_init("server:5050/v1/camera-trap/sync/detect");
curl_setopt($curl, CURLOPT_POST, 1);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);
curl_exec($curl);
Are there any settings have to be made on the server so that I can access it with CURL?

Sorry, you've traveled beyond my expertise.  If it's working in Postman, this sounds like a PHP/curl question.
Good luck!


doc/instances: Fix bridged NIC ipv{n}.address docs indicating none is valid value

This was missed in the original PR https://github.com/lxc/lxd/pull/9641
Signed-off-by: Thomas Parrott<EMAIL_ADDRESS>

Documentation preview available at: https://linuxcontainers.org/lxd/docs/pr.9879/


Click doesn't work for Twitter's follower follow / unfollow button in CasperJS environment, from the follower's page

Hi everyone,
I actually want to follow / unfollow Twitter accounts in a CasperJS environment. I am used to do some testing with a navigator (for example with Firefox or Chrome) before I write my JavaScript code. I have tried several button click syntaxes that just work great in the navigator, but not in the CasperJS environment.
For example, I log in to Twitter with Firefox, and go to this URL "https://twitter.com/googledrive" (it is an account that I am already following). I move the mouse over the "Follow / Unfollow" button and right click in order to inspect the button element. The navigator opens a console (just like F12).
Then I right click on the element (in the HTML code) and select "Copy Unique Selector".
Then I just have to write the following line in the Console bar :
document.querySelector("span.button-text:nth-child(3)").click();
Or even this one works
document.querySelector(".button-text.unfollow-text").click();
And when I go back to my followings list, the Google Drive account has been removed.
CasperJS part :
I would like to do the same action in CasperJS environment. I am able to log in, go to the page containing the account I am following, click on the Google Drive account, and when I try to do the unfollowing click, CasperJS throws no error, and do the click action. But when I go to Firefox and refresh my page, I still have the same number of followings... My full code is right below ::
var casper = require("casper").create({
verbose: true,
logLevel: 'debug',
pageSettings: { userAgent: "Mozilla/5.0 (Windows NT 6.3; WOW64; rv:40.0) Gecko/20100101 Firefox/40.0" }
});
var email = 'My Email';
var auth = 'My Password';
casper.start('https://twitter.com/', function() {
this.fill('form.t1-form.signin', {
"session[username_or_email]" : email,
"session[password]" : auth
},true);
}); //It leads me to my Twitter Dashboard
//Go to my followings list
casper.then(function(){
console.log(this.getTitle());
this.click("div.ProfileCardStats:nth-child(3) > ul:nth-child(1) > li:nth-child(2) > a:nth-child(1)");
casper.wait(2000);
});
//I click one of the links to Google Drive page
casper.then(function(){
console.log(this.getTitle());
this.click("#stream-item-user-32468665 > div:nth-child(1) > div:nth-child(2) > div:nth-child(3) > span:nth-child(2) > a:nth-child(1)");
casper.wait(2000);
});
//Unfollow action
casper.then(function(){
console.log(this.getTitle());
this.click("button.user-actions-follow-button");
casper.wait(2000);
});
casper.then(function(){
casper.wait(1000, function(){
this.back();
});
casper.wait(2000);
});
//Then I want to go back to my followings list
casper.then(function(){
casper.wait(2000, function(){
console.log(this.getTitle());
});
});
casper.run();
The debugging says that the click is done, but in fact not really.
I even tried with casperJS evaluate function, in order to use jQuery, but it still doesn't do the click action : this.evaluate(function(){
$('span.button-text:nth-child(3)').click();
});
And the following didn't work either, but I get in the condition and I get the message "Button detected". this.mouse.move("button.user-actions-follow-button:nth-child(2)");
if(this.exists("button.user-actions-follow-button:nth-child(2) > span:nth-child(3)")){
casper.click("button.user-actions-follow-button.js-follow-btn.follow-button.btn:hover");
console.log("Button detected");
}
What am I doing wrong? If I could at least understand why this code doesn't work, or get to know if it is an impossible action to do, it would help me a lot.
Thank you,
Siona-A

I often have this problem a lot when using Casper, and I'll point you to this important note in the docs:
Warning

Step functions added to then() are processed in two different cases:

    when the previous step function has been executed,
    when the previous main HTTP request has been executed and the page loaded;

Note that there’s no single definition of page loaded; is it when the DOMReady event
has been triggered? Is it “all requests being finished”? Is it *all application logic being
performed”? Or “all elements being rendered”? The answer always depends on the
context. Hence why you’re encouraged to always use the waitFor() family methods to
keep explicit control on what you actually expect.

So what I think that means is that you're executing click() when the DOM's not ready yet, so the event is happening on nothing.  Restructure your code to use the waitFor() functions to make sure things are there when you go to click them.


DBZ-1280 Lock timeout for SQL Server

https://issues.jboss.org/browse/DBZ-1280

@jpechane, LGTM! Only the doc upate missing, you know the drill :) Thanks!

@gunnarmorling Added

Thanks, @jpechane!


feat: Define onTokenExpired event

Description of change
Hello there,
In this PR, two main changes are introduced:

A callback handler for expired access token is incorporated into the client.
The need for a client to manually set the accessToken is removed and is instead now done inside the code, together with the setting of refreshToken and expiresAt

NOTE: This PR is still in draft because I am unsure of the approach to set the accessToken, refreshToken and expiresAt. I think this is internal knowledge of the SDK and should be handle there, however, the previous method to set the accessToken by the client existed, therefore I am a bit confused as to which approach to follow. Also, by removing the getter and setter of accessToken, a breaking change would be introduced.
Issues resolved by this PR
This PR solves #25

@cla-bot check

NOTE: This PR is still in draft because I am unsure of the approach to set the accessToken,

@danielSbastos please see my comments near
https://github.com/devopness/devopness/pull/724/files#diff-c3e0a26c94e6f04b527990186dc2c64eaf953b64927e54536f3cf607290ace6eL45
As the existing approach to set the accessToken is already documented in the README file, but it's being removed in your proposed changes.

I think this is internal knowledge of the SDK and should be handle there, however, the previous method to set the accessToken by the client existed, therefore I am a bit confused as to which approach to follow. Also, by removing the getter and setter of accessToken, a breaking change would be introduced.

You can follow the introduction guide to Devopness and once logged in you can inspect the call to /login and /refresh-token in a browser network panel, so you can see how the API endpoints are invoked and which data is returned by each one of them.
You can also check the attributes on the response model for each of these endpoints:

UserLoginResponse
UserRefreshTokenResponse

Hope that helps!

Hey @jfoliveira, sorry for the delay. I'm thinking of ways to verify the expiresIn (or expiresAt) without relying on the application state. Would it be okay to assume that the user has set it on the localStorage? And then on the function to verify the authentication error, fetch from it?
By assuming the user sets in the localStorage also implies the addition on the respective documentation/instructions for them to know that this is needed

Hey @jfoliveira, sorry for the delay. I'm thinking of ways to verify the expiresIn (or expiresAt) without relying on the application state. Would it be okay to assume that the user has set it on the localStorage?

We can't assume that for many reasons including, but not limited to, the fact that this SDK is designed to be used not only browser, but also in Node.js command line applications, which cannot access localStorage.
Moreover, the developers consuming this SDK are the ones responsible to manage if/how any SDK exposed data, such as accessToken, are going to be stored by their apps.
We should not impose any requirement on how the client apps consuming this SDK are designed by their developers.

Hey @jfoliveira, sorry for the delay. I'm thinking of ways to verify the expiresIn (or expiresAt) without relying on the application state. Would it be okay to assume that the user has set it on the localStorage?

We can't assume that for many reasons including, but not limited to, the fact that this SDK is designed to be used not only browser, but also in Node.js command line applications, which cannot access localStorage.
Moreover, the developers consuming this SDK are the ones responsible to manage if/how any SDK exposed data, such as accessToken, are going to be stored by their apps.
We should not impose any requirement on how the client apps consuming this SDK are designed by their developers.

Gotcha, that makes sense. Maybe the best option is then for the client to implement an interface, injecting it into the SDK, on how to access this token, which its implementation would be up to them?

Maybe the best option is then for the client to implement an interface, injecting it into the SDK, on how to access this token, which its implementation would be up to them?

We should not care or influence how SDK clients implement anything on their side.
We should not interfere on any client application design.
We should not judge or limit how client apps consume this SDK.
We should just expose data and trigger events so client apps can handle the events anyway their developers feel like and read/store the exposed data in any ways that suit them better.
I believe I'm not following what is making this implementation so hard and why you're trying to find ways to tell the SDK clients what to do.
Are you sure we can't just keep things simple and expose an event handler method as discussed in previous comments and in original issue #25?

We should not care or influence how SDK clients implement anything on their side. We should not interfere on any client application design. We should not judge or limit how client apps consume this SDK.
We should just expose data and trigger events so client apps can handle the events anyway their developers feel like and read/store the exposed data in any ways that suit them better.
I believe I'm not following what is making this implementation so hard and why you're trying to find ways to tell the SDK clients what to do.
Are you sure we can't just keep things simple and expose an event handler method as discussed in previous comments and in original issue #25?

What is making it not so simple is because, right now, the solution to invoke the callback depends on the 401 status code and the expiresIn value, which should be stored somewhere. I did not find a difference on the 401 response from an expired token or an general authentication error.
Given this, there is a need to define a strategy on how to handle the exporesIn. Previously you mentioned that you saw no need for the client to set the refreshToken and expiresIn, so I opted to remove it from the SDK, but then the issue on how to access the exporesIn remained. This lead to the previous option I suggested.
If you have another idea on how to manage the expiresIn, please tell me, given that right now, the solutions I mentioned were the only ones I was able to come up.

I did not find a difference on the 401 response from an expired token or an general authentication error.

@danielSbastos well, that's the basic requirement of this task. If you didn't know how to check that, which is understandable, I would expect you to have written no code at all and specially before proposing to remove existing working code. As you started adding and removing code, I thought you knew exactly what you were doing. 🤷♂
We'd better plan before writing code. Keep that in mind!
That being said ...
If you just keep the accessToken property exposed and required to be set by client apps when creating an instance of this SDK, as it was already working before, you could then decode the accessToken JWT and check if the token is expired by checking the value on the token exp claim/attribute.
We could use Auth0 JWT package and its jwt.verify() method to do the job here.
See examples below:

https://github.com/auth0/node-jsonwebtoken#tokenexpirederror
https://stackoverflow.com/questions/34329280/node-js-express-js-jwt-how-to-check-token-expired-or-not

Having that plumbing in place, you could have something like the pseudo code below:
if (response.statusCode == 401) {
  const isTokenExpired = jwt.verify(this.accessToken, ...);
  if (isTokenExpired) {
    trigger_onTokenExpired_callback(...);
  }
}

Closing this PR, as a simpler and more effective solution was implemented in #907, solving issue https://github.com/devopness/devopness/issues/25


feat(operator): Make timeouts and retries configurable for function executions

Fixes: #64

Yeah, @thschue will add the function too but I am not sure where to add can guide me on this?


Finch in Action

This PR is an attempt to address #204.
The work is in progress but I feel that direction is correct. The hight-level idea is to:

Allow users write their services using custom domain types, i.e., (Int, String) => User instead of HttpRequest => HttpResponse.
Hide explicit HttpRequest and HttpResponse types. Ideally users should not deal with them directly.
Use RequestReader (Micro) instead of Service.
Enable implicit conversion from A to HttpResponse

I just realized that RequestReader is actually a Service or Microservice (Micro) but more powerful. Like a service it takes a request and transforms it into something. For example, request reader (or microservice) RequiredParam("a") takes request and transforms it into a string value. So, we can consider RequestReader as a building block for users services: we use bunch of predefined micorservices to build powerful Finagle services. For that propose I added a magic ~> compositor that works as follows:
def magic(a: String, b: String): Future[String] = ???
val a: Micro[String] = RequiredParam("a") ~ RequiredParam("b") ~> magic

This  idea is originally came from Jens.
I was also trying to enable an implicit conversion from A to HttpResponse if there is an implicit EncodeResponse available in the scope.
This is a long-standing PR that will probably lead to some refactoring but I want to have it published so I can get some feedback on this direction. I'm personally super excited about treating the request reader as microservice. So the Finch application is just a bunch of composed microservices (request readers).
The resulting API looks as follows (Micro is a RequestReader):
def echo(what: String): Micro[String] = Micro.value(what)
val e: Endpoint[String] = Get / "echo" / string /> echo
Httpx.serve("8081", e) // string will be implictly converted into plain-text HTTP response

Coverage decreased (-8.96%) to 82.75% when pulling 04e29ee581aa2df1a2df01405cf057d45a6a062f on finch-in-action into 23cecfa56e4d4237136f6ef9209098bbf9988142 on master.

Coverage decreased (-8.96%) to 82.75% when pulling 04e29ee581aa2df1a2df01405cf057d45a6a062f on finch-in-action into 23cecfa56e4d4237136f6ef9209098bbf9988142 on master.

Coverage decreased (-8.34%) to 83.38% when pulling f154dfbfb29b3716bd88cbdb6b37162d12d3a7a1 on finch-in-action into 23cecfa56e4d4237136f6ef9209098bbf9988142 on master.

Coverage decreased (-9.13%) to 82.59% when pulling 414a88380711634e8257f57c3a37af8a7903c697 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-9.13%) to 82.59% when pulling 414a88380711634e8257f57c3a37af8a7903c697 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-10.98%) to 80.73% when pulling 0cc7beebac0f0a60d708dbfe2f856fef9b8c5609 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-10.98%) to 80.73% when pulling 0cc7beebac0f0a60d708dbfe2f856fef9b8c5609 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.92%) to 83.8% when pulling 65873e41fe1a32c9c152614a8ef2d480fdea7b34 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.92%) to 83.8% when pulling 65873e41fe1a32c9c152614a8ef2d480fdea7b34 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.92%) to 83.8% when pulling 67a28615ba4a7ff6f762fa141113c918eadd978a on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.92%) to 83.8% when pulling 67a28615ba4a7ff6f762fa141113c918eadd978a on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.92%) to 83.8% when pulling 67a28615ba4a7ff6f762fa141113c918eadd978a on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.92%) to 83.8% when pulling 479a4ca20b9f92d016b01a0015561313403d3f73 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.92%) to 83.8% when pulling 479a4ca20b9f92d016b01a0015561313403d3f73 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.66%) to 84.05% when pulling cfd79220e7345ca9f6517085fdfae299ec2a5a70 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.66%) to 84.05% when pulling cfd79220e7345ca9f6517085fdfae299ec2a5a70 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.66%) to 84.05% when pulling cfd79220e7345ca9f6517085fdfae299ec2a5a70 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

For now I'm really happy with the following:

Magic of both ~> and /> compositors
Using RequestReader instead of Service, as a result hiding the HttpRequest type
Downgrade the Endpoint to carry just one type - output type, which actually matters

But, I don't like the way I solved the last problem: hiding the HttpResponse type and composing the endpoints of different types. Given the following endpoints:
val e1: Endpoint[A] = ???
val e2: Endpoint[B] = ???
val e3: Endpoint[C] = ???

The problem is how to compose them together. For now, I solved it in an ugly way, using the type type Endopints = Seq[Endpoint[HttpResponse]] that explicitly enables implicit conversions:
val e: Endpoints = Seq(e1, e2, e3)

I was wondering if there is another way to solve it and found out that I've already seen a similar problem. And more importantly, I've seen an elegant solution. The scodec library uses Shapeless HList to convert list of codecs (i.e., Codec[A] :: Codec[B] :: Codec[C]) into a single Codec[X]. This is exactly what I'm trying to do. Thus, the idea is to have an HList of endpoints and then magically convert it into an Endpoint[HttpResponse] (which is actually a Service[HttpRequest, HttpResponse]) if there is an implicit view X => HttpResponse available for each type A, B, etc.
This sounds like a solid approach. And I'm totally fine with introducing dependency to Shapeless, since it will bring us to an awesome solution.
That said, this is my plan for weekend.

Coverage decreased (-7.7%) to 84.01% when pulling a98b9596b8318ad0071580a0554b2ab345649e9d on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-7.7%) to 84.01% when pulling a98b9596b8318ad0071580a0554b2ab345649e9d on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Was playing around HList and realized that we might better use it instead of ~ and / types to handle composite entities. In case of endpoint, it doesn't really make sense to curry all the types of endpoints. I decided to solve it in a different and much simpler way (via ! compositor).
Still looking for a good solution and would be happy to hear feedback.

Coverage decreased (-7.66%) to 84.05% when pulling 406363479a17fd573cb12815e0ccc2076154991e on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

Coverage decreased (-9.58%) to 82.13% when pulling 9a2c17f89ed36fd66e3fb9e1c1fc093667286ec7 on finch-in-action into 49edd59938d163f8d298ddf67bb3d63145174d70 on master.

This looks like a good direction. I'm happy to see that pattern matching gets avoided through implicits now and not a new Micro trait. I analyzed the impl and the code samples and I don't have any concerns.
Somehow I'm still not in love with the name Micro, being a type alias for RequestReader even though the two somehow sound like two distinct things. But this is just semantic nit-pickyness and I don't have a counter-proposal either.
I'd still have two questions:

What is this new ! compositor for routes about?

What would be the most elegant way to apply a certain reader (like for auth) for each route? Is there anything apart from the repetition of using an auth reader in each Micro then? Apart from the plumbing it would introduce the risk of forgetting it for just one route (e.g. if you don't need the User object, but still require the request to be authenticated).

Super cool questions, as usual.
Probably, Micro isn't a best name. But it's definitely better than RequestReader, since it's no longer a RequestReader but RequestHandler or RequestProcessor. The only thing I like about Micro is that it's a short name :) I would be happy to change it into something more reasonable.
Here is the problem I'm trying to solve with ! combinator. Let's say we have two endpoints:
val i: Endpoint[Int] = Get / "i" /> Micro.value(10)
val s: Endpoint[String] = Get / "s" /> Micro.value("10")

The question here is how to compose them together and what's the result type should be. I'm still thinking how to handle this and I'm not sure I'm happy with ! compositor here, which is a forced or it converts Int and String into HttpResponse if there are both EncodeResonse[A]s (for string and int) available in the scope.
Regarding the auth request reader. I can't really see a way to do it w/o filters. So, since the RequestReader still takes a request of any type we can think about having a classic Auth filter that changes a request type to AuthReq and then having a factory method like this:
object RequestReader {
  def apply[Req, A](f: Req => A)(implicit ev: Req => HttpRequest): RequestReader[A] = ???
}

We may define an auth request reader like this:
case class AuthReq(userId: Int, http: HttpRequest)
val auth: RequestReader[Int] = RequestReader[AuthReq, Int](_.userId)

So combine both, an Auth filter that actually performs authorization and auth request reader that fetches the auth details from the custom request type. This will guarantee us that all the services will be authorized by Finagle filter.
@jenshalm, how does it sound?

Just realized that it's actually not possible to define this factory method. Hopefully, there is another way to  make a reader that reads from a custom request type.

Thus, I still have to solve to problems:

How to compose Endpoint[A] and Endpoint[B] together (and what is a result type).

We successfully use lazy auth after routing part done it's work. It allows to avoid request url checks in filter and start authentication process only when you need it (in specific endpoints)

Yeah. I also think that having a auth done after routing is a nice way to control the things. Although, it also may cause a bug when you simply forget to put auth before service that doesn't requires any authorization information (i.e., userId).

@ImLiar @vkostyukov I think post routing auth can work in some scenarios, but for us our API is all auth controlled so it makes a lot more sense for use to auth pre-route.

Right. I'm thinking about supporting both ways somehow.

Great! Thank you.

Simplified the implementation quite heavily based on a idea that Endpoint is Router[RequestReader[HttpResponse]]. This solves the first problem I've been working on. The second problem (pre routing auth) still in progress.

Coverage decreased (-8.71%) to 83.0% when pulling ee8a1cdb4b15c03d673348f4118b0f43c8cb18db on finch-in-action into b48458f727780c8d556154e5e5fc87392cd9c094 on master.

Coverage decreased (-9.53%) to 82.18% when pulling 761a12c39ede0eaa96d02bd057ef3863bfd1b3fc on finch-in-action into 74dbe4ef15aafc05e483cb34ba6fa9af4450e580 on master.

Coverage decreased (-9.53%) to 82.18% when pulling 3390a85d04da5de3e64a181feaa2e3f656fca3a4 on finch-in-action into 74dbe4ef15aafc05e483cb34ba6fa9af4450e580 on master.

Coverage decreased (-8.96%) to 82.75% when pulling 7aca11ed445b4ce1e209be3dc0f27c7129c22b9f on finch-in-action into 74dbe4ef15aafc05e483cb34ba6fa9af4450e580 on master.

I think this is ready to go alive. I spend a month trying to approach this problem and ended up solving it in the most straightforward way. I'm pretty happy with the current solution. It still requires some stylistic changes and docs but for now this code might be merged in.
Anyway. I'm totally happy to revisit this problem later.


Scroll browser window when selecting

I have a use case that requires a schedule table that is taller than some browser windows, and in user testing it seemed to be expected that the browser would scroll vertically when the mouse exits the window while selecting a range.
This is a fairly rough implementation, but it does work. If you see value in it, I can refine it a bit more and maybe make it configurable through options. Thoughts?

          1 Warning

:warning:
Please include a CHANGELOG entry.
You can find it at CHANGELOG.md.

  Generated by :no_entry_sign: Danger

@mmarich Thanks for contributing and welcome! Apologies for the slowness. I made a comment inline. Let me know how you think about the other approach.


Replace deprecated dependencies

jade -> pug
babel-preset-es201x -> babel-preset-env

It was not a serious issue.
The warning has decreased.
Several warnings remain, but there is no problem.
npm WARN deprecated<EMAIL_ADDRESS>Use uuid module instead
npm WARN optional SKIPPING OPTIONAL DEPENDENCY<EMAIL_ADDRESS>(node_modules\fsevents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for<EMAIL_ADDRESS>wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"})


Sorry to ask. How do u split framework repo.

How do you guys split the main framework components into read only repositories.
Would love to know.
CC @SvenAlHamad @adrian1358

Hey Collins,
this not really an issue :) but let me try and provide you some quick guidelines:

have a master repo, in our case (https://github.com/Webiny/Framework)
you only write and commit into master
check the composer json inside the master repo, especially the "replace" section which references the components. This tells to composer to resolve that dependency to the master repo.
creating and maintaining the component repos is bit time consuming, so we created this tool to automate that (https://github.com/Webiny/GitSplit)

Hope it helps.


Student: As a student I want to, when allowed, view other student submissions.

front end implemented, back end missing


Added Radix Sort Algorithm

Added Radix Sort Algorithm in Sorting Algorithm Section
Happy HactoberFest 2021

Hi Dear @sumanrox
Great code
Thanks for your contribution......
Show your support on my youtube channel web Pixar(The institute of coding)
like , share , subscribe
youtube - https://youtu.be/5qnQjgdpFPg
telegram-channel - https://t.me/WebPixar
join our telegram channel for more goodies , swag packs


Different functionality on hover for ---@type fun() vs ---@param/return

How are you using the lua-language-server?
Visual Studio Code Extension (sumneko.lua)
Which OS are you using?
Windows
What is the issue affecting?
Annotations, Completion, Hover, Libraries
Expected Behaviour
If I define syntax in a meta library, like this:
SomeFunction=nil ---@type fun(param1: type1, param2, type2): returnType
It should behave identically to if I had declared this:
---@param param1 type1
---@param param2 type2
---@return returnType
function SomeFunction(param1, param2) end ---@diagnostic disable missing-return

Actual Behaviour
When I use ---@type, I get:

But when I use ---@param, I get:

Reproduction steps
Hover over the function name in each respective example code provided in the "Expected Behavior" section.

---@param is used for function definition, while ---@type are more likely to be used for references such as "callback" or "interface".

Is there another way to declare a function exclusively via annotation for use with the language parser? WarCraft 3 has hundreds of publicly-defined functions in _G which point to its closed-source native environment, which is challenging to simply "declare" as a normal function.

Refer to https://github.com/sumneko/lua-language-server/tree/master/meta/3rd/Jass

Thanks! Very insightful :)


Update Korean translation

This PR updates these documentations below(Korean).

DevTools
FAQ

watch vs getValues vs state

API

Controller: onChange
useFieldArray: new important note when using with useFormContext

Thanks very much ❤👌


[CLEANUP] Need to specify the versions of some eclipse dependencies in

order to avoid pulling in Java 11 artifacts.
This commit is a cherry-pick from master 98a58a36a7f6

:white_check_mark: Build finished in 4m 59s
Build command:
mvn clean verify -B -e -Daudit -amd -pl assemblies/lib

:exclamation: No tests found!
:information_source:  This is an automatic message


form() not working in nomal action

Laravel Version: 5.8.38
PHP Version: 7.4
Laravel-admin: 1.8.13

Description:
strange problem with a normal grid action and the form() function.
the dialog() works like a charm shows a dialog and fine.
butusing form(), the form never shows up.
I figured out that somehow the function addModalHtml() (and here basically Admin::html($modal)) inside the class Encore\Admin\Actions\Interactor\Form does not put out the modal html.
any ideas where to look after?
Steps To Reproduce:

no steps available as it is an existing older project

update: it seems that in this case Admin::html() is not working

fatal thing which cost lot hours to debug
no bug at all - at some older stage we deployed index.blade.php to resources/views/vendor/admin
meanwhile some behaviour may have changed, because Admin::html() was completely missing in that file
dang ...
okay - closing

reason: be8d5bce77639e61247c8c746f170761025593c6
breaking change


Wallet UI bugs from chris's bug list for 3.2

Addresses these bugs:

[x]  Install flow: Custom path, clicking the install guide button takes user to docs, should take user to /docs/gui-wallet
[x]  Wallet home: Can we please remove 'compress the blockchain'? Non-functional UI is unnecessarily confusing.
[x]  Wallet home: click send, click cancel: Send button text disappears
[x] Staking & Delegating: default tx fee is 5 coda — now that fees are expressed in decimals, can we set the default much lower?

Should we also put a default fee here? https://github.com/CodaProtocol/coda/blob/97729988c8732124322090328ebc90faa5e00a4e/frontend/wallet/src/render/views/footer/SendModal.re#L165

Should we also put a default fee here?
https://github.com/CodaProtocol/coda/blob/97729988c8732124322090328ebc90faa5e00a4e/frontend/wallet/src/render/views/footer/SendModal.re#L165
(not sure why we have two different designs for specifying fees)

yeah idk i will change here too though!


Using 'impressionist' controller mixin without an associated model

I'm trying to add the impressionist mixin into a controller I've got in Rails 5.1, but I'm running into an issue. The controller doesn't have a model associated with it, so the Impression won't save, with the validation error ActiveRecord::RecordInvalid: Validation failed: Impressionable must exist.

should be fixed in v1.6.1


chore(demo): fix for nested levels in package demo

Description
Fixes the Topology Package demo nesting depth setting. The setting was not being used when creating nodes.
Type of change

[x] Bugfix : DEMO code only

@jenny-s51 Updated the padding. https://nested-levels.surge.sh/


Get/set oplog index host functions

Resolves #160
Fixes an issue where previous instance of a retried worker was not dropped
Unifies the oplog index type to be u64 everywhere
Adds version (0.2.0) to the Golem host WIT interface
Required golem-wit change: https://github.com/golemcloud/golem-wit/pull/9

I have just realized this is not fault tolerant yet - as it ignores set-oplog-index in replay mode assuming that when it reaches it it already "performed the jump". But that is only true if it is replaying because previously it reached that point in live mode. If it did the jump once already and moved forward in the execution and got recovered for any other reason - failure, or just moving shards or recovering a suspended instance - then it won't work correctly.
In an earlier version of the PR i had a solution for it I think but got removed. It would be something like this:

when reaching set-oplog-index in replay mode, if it is not in the active jumps table, then we append a new jump entry to the oplog and restart the recoevry
it requires some attention to properly skip these extra jump entries when needed

Or an alternative is to not just look at the last oplog entry on startup but scan the whole oplog in advance and collect all jump entries. Then we always know about the jumps during recovery and we can do it in one run. This is probably more efficient than restarting the recoveries anyway.
And if we do this we don't need to accumulate the jumps in the jump entries like in the current version of the PR because we can accumulate them while traversing the oplog.

And this scanning approach can be made optimal similar to how the worker status is handled - store the jumps in a separate redis key with the oplog index it was last updated at, and then we only need to scan the newer oplog entries.

So to sum it up, the PR will be extended with the following:

OplogEntry::Jump only stores a single jump not a list of jumps
There is a separate redis key for storing the last known set of jumps
On worker startup we don't just check the last oplog entry but load this cached value, (and use empty list @ idx = 0 as default) and scan the oplog entries after the last update index to look for additional jump entries

These changes will make sure the jumps are repeated correctly in any case of failure.


Add test for web.config.

Enforces that the binding redirects have been manually fixed up.

Yes! This fixes #1571


Documentation for generating image gallery

Documentation should contain how to generate simple image gallery with images with descriptions with possibility of multi-layer deep folder structure.

right, but this is a subject of yosymfony/Spress.yosymfony.com repo.

Moved to https://github.com/yosymfony/Spress.yosymfony.com/issues/13


Health Probe Timeout and Node Claiming Issues Following Upgrade to Karpenter v0.36.1

Observed Behavior:
We recently upgraded Karpenter from v0.35.5 to v0.36.1 in our EKS 1.29 environment within an isolated VPC. Post upgrade, Karpenter ceased to create new node claims and schedule new nodes. This was accompanied by a non-responsive health probe, causing Karpenter to enter a continuous cycle of shutdown and restart.
An error related to the pricing API was observed:

{"level":"ERROR","time":"2024-05-30T09:35:18.886Z","logger":"controller.pricing","message":"updating pricing, retreiving on-demand pricing data, RequestCanceled: request context canceled\ncaused by: context canceled; RequestCanceled: request context canceled\ncaused by: context canceled","commit":"fb4d75f"}

However, please note that this error was present even before the upgrade and it did not affect the health probe timeout or Karpenter's ability to claim new nodes.
Additionally, the following warning messages were captured from the pod events, showing that the liveness probe failed continuously:

Warning Unhealthy 92s (x6 over 13m) kubelet Liveness probe failed: Get "http://<IP_ADDRESS>:8081/healthz": context deadline exceeded (Client.Timeout exceeded while awaiting headers)
Normal Killing 92s (x2 over 12m) kubelet Container controller failed liveness probe, will be restarted
Normal Created 61s (x3 over 14m) kubelet Created container controller Normal Started 61s (x3 over 14m) kubelet Started container controller

Expected Behavior:
Karpenter should continue to create new node claims and schedule new nodes without any disruptions, even after the upgrade. The health probe should respond in time, preventing any unnecessary cycling of shutdown and restart.
Reproduction Steps:

Upgrade Karpenter to v0.36.1 in an EKS 1.29 environment within an isolated VPC.
Observe that Karpenter stops creating new node claims and scheduling new nodes.
Investigate and find that Karpenter's health probe isn't responding in time, causing a continuous cycle of shutdown and restart.

Versions:

Karpenter Version: 0.36.1
Kubernetes Version (kubectl version): 1.29
Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
If you are interested in working on this issue or have submitted a pull request, please leave a comment

Are you running Karpenter in EKS Fargate or MNG? Can you share the size of the nodes that are running Karpenter? Can you share the Karpenter deployment that you are running in the cluster?

Thank you for your response.
Karpenter is running on a self-managed node group on t3a.medium size instances.
The deployment used for testing involves 10 replicas of an 'inflate' pod. Here is the YAML configuration for the same:
apiVersion: apps/v1
kind: Deployment
metadata:
  name: inflate
spec:
  replicas: 10
  selector:
    matchLabels:
      app: inflate
  template:
    metadata:
      labels:
        app: inflate
    spec:
      terminationGracePeriodSeconds: 0
      containers:
        - name: inflate
          image: public.ecr.aws/eks-distro/kubernetes/pause:3.7
          resources:
            requests:
              cpu: 1

As a workaround, setting the isolatedVPC value to true in the Karpenter settings has resolved the issue: isolatedVPC: true
However, it's worth noting that this configuration was not required prior to the upgrade to v0.36.1. We're trying to understand why this change has become necessary and whether this is the intended behavior moving forward.

Apologize for the confusion, I was more interested in the Karpenter Pods. What is your request and limits for the Karpenter Pods? The team recommends that the request and limits both be set for 1 cpu and 1 Gi of memory https://karpenter.sh/v0.32/getting-started/getting-started-with-karpenter/#4-install-karpenter. The workload that Karpenter is provisioning nodes, should not impact it's ability to create nodes.

Apologies for any confusion, but during the time of the issue, we hadn't set any resource requests or limits for the Karpenter deployment. Thanks for the suggestion, we'll apply the recommended settings.

Closing this issue out for now. Open a new issue if the problem persists.


Add LGTM code quality badges

Hi there!
I thought you might be interested in adding these code quality badges to your project. They will indicate a very high code quality to potential users and contributors.
You can also check the alerts discovered by LGTM.
N.B.: I am on the team behind LGTM.com, I'd appreciate your feedback on this initiative, whether you're interested or not, if you find time to drop me a line. Thanks.

I used landscape.io before but didn't particularly like it. I will give your service a try. Does it support C as well as Python? Is it ok with multiple languages in one repo?

Hello @remram44
Thanks for this feedback.
Yes we support C and C++:  supported languages
If there are multiple languages in one repo, all of them are analysed: https://lgtm.com/help/lgtm/analysis-faqs#how-does-lgtm-determine-which-languages-to-analyze
If you have an example of repo where one language is missing, please point it to me ... it usually means that  it has a complex build sequence and that our autobuilder didn't manage to compile it automagically.
While you're having a look at it, you should try out the PR integration, that you can activate easily here. This is the usage we recommend, as LGTM will report any new alert (or fix) directly within the GitHub pull request.

This project has C code that doesn't seem to appear in LGTM (see LGTM vs GitHub). There is no "complex" build sequence, in the sense that it is a Python extension compiled the usual way using setuptools.

@remram44 let me check this! Thanks.

Hey @remram44
Just wanted to let you know that during 6 weeks, for each LGTM alert fixed, we'll make a donation to WWF. You can also win a free ticket to GitHub Universe, with travel and accommodation. Details here: https://competitions.lgtm.com/ghu-2018

Aww but I already fixed them!
You seem to have fixed the C code not showing up, so I'll consider it.

Oh, sorry, I totally forgot to get back to you about the C code after making it work ...


⚠ Bofrost.be has degraded performance

In 767e48d, Bofrost.be (https://www.bofrost.be) experienced degraded performance:

HTTP code: 200
Response time: 1368 ms

Resolved: Bofrost.be performance has improved in a167549 after 18 minutes.


Give every Roblox type its own struct

This idea formed when we got types like ColorSequence that are useful to reason about on their own.
It'd be nice to have actual types for values like Color3 and Vector2 so that we don't have to continually talk about their representations, [f32; 3] and [f32; 2].
This would break existing consumers of rbx_dom_weak, but would be a pretty nice improvement.

Done with the introduction of the types crate!


All the bots update the same user profile

Description
While using the /settings command and editing the user profile, all the bots update the records and it looks like they work on the same chat_id, which is supposed to be different according to Telegram#chat
Possible Solution

Check the records on the database to see how many of them contain the same chat_id and if we have duplicates.

Try with 2 different users and see if the problem persists.

No problem with 2 different users, it looks like chat_id is the same on different chats.


VSCode Plug-in terminates unexpectedly when searching for symbols

Using one of the current development snapshots of clangd, the vscode plugin suddenly stops when I use Ctrl-T and search for "main".
The issue is always reproducible using for example the libwebsockets project from https://github.com/warmcat/libwebsockets/archive/v4.1.6.tar.gz
Note that this problem never occurs when I switch back to clangd 11.0.
Extension Host Tab
[2021-01-15 08:48:12.994] [exthost] [error] [llvm-vs-code-extensions.vscode-clangd] provider FAILED [2021-01-15 08:48:12.994] [exthost] [error] Error: Connection got disposed. 	at Object.dispose (/home/thomasm4/.vscode/extensions/llvm-vs-code-extensions.vscode-clangd-0.1.9/node_modules/vscode-jsonrpc/lib/common/connection.js:1044:27) 	at Object.dispose (/home/thomasm4/.vscode/extensions/llvm-vs-code-extensions.vscode-clangd-0.1.9/node_modules/vscode-languageclient/lib/common/client.js:73:35) 	at /home/thomasm4/.vscode/extensions/llvm-vs-code-extensions.vscode-clangd-0.1.9/node_modules/vscode-languageclient/lib/common/client.js:2320:28
Full Clangd Logs
issuelog.txt
System information
Clangd version (from the log, or clangd --version): clangd version 12.0.0 (https://github.com/llvm/llvm-project.git ceb9379a90f5a320d19f5694ef00b4d1164fa7d6)
clangd extension version: 0.1.9
Operating system: Manjaro Linux

Sent out https://reviews.llvm.org/D94755

Sent out https://reviews.llvm.org/D94755

Your diff fixes the issue. Thanks for the quick response!

Your diff fixes the issue. Thanks for the quick response!


remove bucket4j and ehcache

I decided to remove Bucket4J because it is not useful until the Butler API is actually publicly available. We are currently still very far away from that.

 Remove bucket4j


There are a lot of detected instance centers

When I training nuscense dataset，it display issue ：There are a lot of detected instance centers: torch.Size([4377, 2])

Hi,
Does it happen at the beginning of the training (in the validation sanity check)? If so, I think it is expected because the model is not trained, and it makes some random predictions. However, if it happens after some training, it probably means that your training has failed because after a few epochs model converges into a point where it makes reasonable predictions.
P.S.: I'm not an author of the paper; I just know the code and the repository.

Thank you for reply！


Date incorrectly parsed for browsers in UTC+ timezones

Describe the bug
Flight Search needs to work correctly from any time zone
When a user is using a browser in a time zone in Europe and Asia, i.e., UTC-0 through UTC-+12, this component will incorrectly parse the date resulting in it rendering the day  before even though the underlying data contains the correct date.
To Reproduce
Steps to reproduce the behavior:

Set the time zone of your computer to any positive time zone, e.g., Amsterdam.
Go to ascom and search for any flight.
When you get to the matrix results page, note that the shoulder dates are one off.
If you inspect the auro-pane element, you will see that it had the correct date, but was parsed incorrectly,

Expected behavior
The auro-pane element will show the correct date regardless of the user's time zone.
Screenshots

This issue has been discussed with the Auro team and we are actively looking into a solution and potential release ASAP.

:tada: This issue has been resolved in version 1.1.3 :tada:
The release is available on:

npm package (@latest dist-tag)
GitHub release

Your semantic-release bot :package::rocket:


template update icbi lab infercnvpy v0.3.0

Update tutorials (#114)
Update release.yaml (#115)
Update README.md
Update template to v0.3.0
Fix merge conflicts
Update pre-commit config

Codecov Report
Attention: 1 lines in your changes are missing coverage. Please review.

Comparison is base (12c103f) 56.20% compared to head (92f440e) 56.20%.

:exclamation: Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@           Coverage Diff           @@
##             main     #119   +/-   ##
=======================================
  Coverage   56.20%   56.20%
=======================================
  Files          13       13
  Lines         427      427
=======================================
  Hits          240      240
  Misses        187      187

Files
Coverage Δ

src/infercnvpy/tl/_infercnv.py
51.51% <0.00%> (ø)


(k9s) Need To Force Package Update

k9s package has got new changes made via merging #1713 but it is not updated in chocolatey registry.
Seems like some manual "forcing" step should be made for that.
Expected Behavior
Version 0.24.15 should be available to all users of chocolatey.
Current Behavior
Only previous version (0.24.10) of k9s package is available in chocolatey registry.
Seems that even though the package is updated successfully via automation, the update is not pushed to the registry.
Possible Solution
I personally do not know the internal working of how it's done, but maybe we can somehow "force" it to be re-submitted?

Steps to Reproduce (for bugs)

call choco install k9s or choco upgrade k9s should install/upgrade to the latest version (v0.24.15 currently).

Context
I am just trying to upgrade to the latest k9s package on my machine.
Your Environment

Package Version used: 0.24.10
Operating System and version: Windows 10
Chocolatey version: 0.11.1
Install/uninstall gist:

❯ choco upgrade k9s
Chocolatey v0.11.1
Upgrading the following packages:
k9s
By upgrading, you accept licenses for the packages.
k9s v0.24.10 is the latest version available based on your source(s).

Chocolatey upgraded 0/1 packages.
 See the log for details (C:\ProgramData\chocolatey\logs\chocolatey.log)

The issue is gone now - k9s upgrade is successful! 🎉
Thank you, @majkinetor!


Rethink the name of GenericConfiguration in telestion-api

In my opinion, calling the implementation of the TelestionConfiguration GenericConfiguration is a bad idea.
Here me out why:
In Java when talking about Generics usually type-inferring is meant. Yes, you use it in a type-inferred context, but calling it generic might tell Java developers, that the Configuration can somehow be type inferred. I think the naming is then just incosistent.
On top of that I don't really think a GenericConfiguration describes the usecase really well. Generic objects are things which cannot be further described and don't really have an identity. Yes it is partially the case, but when you make an API I rather have names telling me in what context to use them than names of what it might tell you about the usecase it is used in. The usecase is a generic one, you don't know how to specify it even further. But no, you don't know what you can do with it.
Therefore I would propose one of the following names:

NoConfiguration - you tell the API user that when he does not need a TelestionConfiguration, this one can be used
EmptyConfiguration - tells you that the custom configuration is empty
BaseConfiguration - tells you that you have the basic features, which usually are sparse (I think this name is not that great, but better imo than GenericConfiguration)
VirtualConfiguration - tells you that the Configuration does not have a real implementation but just fulfills its purpose with dummy signatures so that you don't loose the functionality of your class.
PlaceHolderConfiguration - tells you that the Configuration is not used or only temporary there - again not the biggest fan of this but I wanted to give you some options to choose from :D

I for my part would go with VirtualConfiguration or NoConfiguration

What about instead of renaming GenericConfig we get ridd of it entirely and introduce 2 new Config types; one for each usecase:

NoConfig which implements TelestionConfig
ManualConfig or RawJsonConfig which gives you the config as a Map
This proposal would fix both problems at the same time by handling both cases equally well but on the other hand give you solid names and not ambiguity with Generics from Java.


unify accessing of rule configuration

see https://github.com/INT-NIT/AnDO/pull/49#discussion_r539989371

implemented in #63


[.2] Replace Superlinter with individual linters for each language

Superlinter was great on paper, but in practice, it's a bit slow, and the configuration is ugly.
Each language should just have its own linter file.

hello @svix-frank can I please be assigned this issue?


Game, fix full screen not working

Fixed by: https://github.com/Zachary-Ronayne/UnnamedSwordsAndSpellsGame/commit/6bfaa764d18b4414ecc966a5756324eb76498815


Call to undefined method

This issue has been reported before, but there has never been any confirmed resolution for it, so I am creating another issue.
#1078
#1056
This occurs when trying to php artisan koel:sync. I tried all the steps suggested in the comments, which did not solve the issue, neither did composer update.
Apologies for not following the issue template. Its my 10th try or so in the past two years to get this thing running at all. Getting into the web-interface now was as far as i ever got, just to be stopped again by yet another bug. Considering the enormous list of open/unresolved issues, I just want to understand whether this software actually works reliably for anyone or if I should give up and save my. time.

This issue has been reported before, but there has never been any confirmed resolution for it, so I am creating another issue.
https://github.com/phanan/koel/issues/1078
https://github.com/phanan/koel/issues/1056
This occurs when trying to php artisan koel:sync. I tried all the steps suggested in the comments, which did not solve the issue, neither did composer update.
Apologies for not following the issue template.

So you can't be bothered to follow a simple issue template but insist that a project's maintainers should spend their time to solve your problem? That's weird.
An issue template is there for a purpose. For instance, I can't reproduce the above problem at all in my environment (MacOS Mojave 10.14, master branch, PHP 7.1.19). That's why I need as many details as possible to debug the issue (which you're hardly providing and as a result, not really helping).
For your other statement/question:

I'm not defensive, but no, the issue list is not "enormous." You're very welcome to look at similar project's repository and compare (not saying this list represents the software's quality anyway).
I can't speak for others, but the software works reliably for me at least, in many environments. That said, it's perfectly within your rights to pick what works best for you, so I'm not here to convince you.

Closing in favor of #1078.


Full package seems to be required for enum fields

In contrast to normal (class) datatypes, the full package seems to be required when referring to enums defined in the same package:
enum dev.gen.archive.Oper;

fields {
  oper pending;
}

this won't work:
enum Oper;

fields {
  oper pending;
}

The case of enum Oper is maybe a bit clunky.

Hmm, took another look and I was mistaken.


Fix State Fidelity cache key

Summary
Fixes #90
Details and comments
Switches from id() to _circuit_key() where the latter is that which the reference primitives use. Using id() is problematic, as #90 notes, though _circuit_key is designated a private method, and while its the better choice functionally, it feels a bit off to be using what is designated a private method. Its been used/stable for a while though. A choice might be to copy the whole routine here - but perhaps better to see if this changes going forwards in the way some unique key/hash can be obtained for a circuit.

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

3 of 3 (100.0%)  changed or added relevant lines in 1 file are covered.
No unchanged relevant lines lost coverage.
Overall coverage increased (+0.002%) to 90.528%

Totals

Change from base Build<PHONE_NUMBER>:
0.002%

Covered Lines:
6451

Relevant Lines:
7126

💛  - Coveralls


Possible Unicode Problem?

If I share our site in Discord I get this funny representation of the title:

Fixed in https://github.com/codeformuenster/muenster-jetzt/pull/154


consider incorporating Monte Carlo strength evaluation

Based on academic work published here (free access):
http://www.eurecom.fr/en/publication/4711/detail/monte-carlo-strength-evaluation-fast-and-reliable-password-checking
Quoting:

The proposed method requires little resources, applies to a wide set of probabilistic models, and is characterised by highly desirable convergence properties. The experiments demonstrate the scalability and generality of the proposal. In particular, the experimental analysis reports evaluations on a wide range of password strengths, and of state-of-the-art attacks on very large datasets, including attacks that would have been prohibitively expensive to handle with existing simulation-based approaches.

Hi @roycewilliams, that's a great paper. I'm not sure how to incorporate Monte Carlo sampling into zxcvbn, so I'm going to close this issue for now. What I understand so far:

the method they propose takes a probability from a generative guessing model (PCFG, Markov, etc) and converts it into a guess order. That conversion from probability -> guesses is time- and space-efficient.

however, those underlying probability models typically require quite a bit of space, orders of magnitude more than will fit into a small client library like zxcvbn. I think there's some remaining work to build small, portable probability models that have nice approximations to the larger ones. If you know of a way to incorporate Monte Carlo sampling that doesn't require the support of a backing server, let me know!

Hi, @lowe - thanks for the thoughtful analysis. I hadn't done enough analysis of my own, and didn't recognize the space requirement. And approximation may indeed be possible someday, but beyond my ken at present. :) But I'll keep an eye out!


free mem by madvise(MADV_DONTNEED) may not work when enabled linux transparent hugepage

On linux(before kernel version 4.4.0) with transparent hugepage, tcmalloc interface 'heap stats' show a lot memory has released to OS, but command 'top' and '/proc/smaps' show process still uses it. This often happens, and leading to high mem usage.  On system with no transparent hugepage or disable hugepage, it works well as expectly.
Does tcmalloc has other way to release memory?

I found, without tcmalloc, only use native mmap() interface,  high memory usage can appear easily:
environment:
1.kernel 4.4.0 on x86_64
2.enable thp:
echo always > /sys/kernel/mm/transparent_hugepage/enable
echo always > /sys/kernel/mm/transparent_hugepage/defrag
echo 2000000 > /sys/kernel/mm/transparent_hugepage/khugepaged/pages_to_scan ( faster defrag pages to reproduce problem)
problem:

use mmap() to allocate 4096 bytes for 1024512 times (40961024*512=2G).
use madvise(MADV_DONTNEED) to free most of the above pages, but reserve a few pages(by if（i%33==0) continue;), then process's physical memory firstly come down, but after a few seconds, it rise back to 2G again, and can't come down forever.
if i delete this condition(if（i%33==0) continue;) or disable transparent_hugepage by setting 'enable' and 'defrag' to never, all go well and the physical memory can come down expectly.

test code:
#include <stdio.h>
#include <memory.h>
#include <stdlib.h>
#include <sys/mman.h>
#include <errno.h>
#include <assert.h>
#define PAGE_SIZE 4096
#define PAGE_COUNT 1024512
int main()
{
void** table = (void**)malloc(sizeof(void) * PAGE_COUNT);
printf("begin mmap...\n");
for (int i=0; i<PAGE_COUNT; i++) {
table[i] = mmap(NULL, PAGE_SIZE, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1 ,0);
assert(table[i] != MAP_FAILED);
memset(table[i], 1, PAGE_SIZE);
}
printf("mmap ok, press enter to free most of them\n");
getchar();
//it behaves not expectly: after most pages freed, thp make it rise to 2G again
for(int i=0; i<PAGE_COUNT; i++) {
if (i%33==0) continue;
if (madvise(table[i], PAGE_SIZE, MADV_DONTNEED) != 0)
printf("madvise error, errno:%d\n", errno);
}
printf("release finish\n");
free(table);
getchar();
getchar();
}

Yes, and this known issue. This is arguably kernel bug. This is because default value of /sys/kernel/mm/khugepaged/max_ptes_none is set to 511. Setting it to 0 will fix it.
With value set to 511 khugepaged will convert chunks of 2 megs to huge page even it just 1 small page is used there (rest is madvise-dont-need-ed).
Another way to work around is to disable returning memory back to kernel. Set TCMALLOC_RELEASE_RATE to 0. Of course it means that some kinds of memory fragmentation where we previously at least returned fragmented memory back to kernel, will now actually fragment memory badly.

have you all any experience with how these effects manifest when running many vastly overcommitting processes on the same machine? reduction in TLB misses is great and all in theory but i'm concerned about extreme memory pressure resulting in OOMM process kills.
I wrote a little program to play around with different madvise strategies. (had to rename the extension from .cpp to .txt so github would let me upload it lol). trivially compilable and runnable like so..
g++ mem.test.cpp -o mem.test
./mem.test 100000 MADV_COLD

can try MADV_DONTNEED, MADV_FREE, MADV_COLD, MADV_PAGEOUT
i'm focusing on how long these operations take, and how many resident pages the process still has when it completes (I assumed there would be 0 since I was memset-ing every page to 0... and claimed elsewhere that replaces pages with the zero page.... but clearly not?).
with /sys/kernel/mm/khugepaged/max_ptes_none set the default 511...
root@clr-18a47c16c91c437c8ce854a37e6f5e26~ # ./mem.test 100000 MADV_DONTNEED
Memory Space 1.93TB
Resident 13.07GB
3066 ms

then setting /sys/kernel/mm/khugepaged/max_ptes_none to 0...
root@clr-18a47c16c91c437c8ce854a37e6f5e26~ # ./mem.test 100000 MADV_DONTNEED
Memory Space 1.93TB
Resident 10.49GB
2560 ms
but THEN... when i outright disable transparent hugepages....
root@clr-18a47c16c91c437c8ce854a37e6f5e26~ # ./mem.test 100000 MADV_DONTNEED
Memory Space 1.93TB
Resident 0.01GB
389 ms

mem.test.txt

Sorry, I don't undestand the question(s) in latest comments. Please elaborate. Otherwise assuming this ticket is about max pte none thingy being borked by default.


Changing the default privacy settings applied to Pokémon I upload.

For reference:
Settings:

Pokémon/boxes are private: enabled by default

Private/viewable/downloadable


Return keyword list of associations for a given module

Adds the ability to find the name and type of association between two schema modules via schema reflection. It's a combination of __schema__(:associations) and __schema__(:association, assoc).
Doesn't handle traversing through associations.

What is the use case? Couldn’t it perhaps be something you compute somehow else?

What is the use case? Couldn’t it perhaps be something you compute somehow else?

I have a module that recursively clones records through child associations. So if we have a schema:
erDiagram
  GRANDPARENT ||--o{ PARENT : has
  PARENT ||--o{ CHILD :has

We can pass an existing %Grandparent{} to the cloning function and it will clone through all its children, copying the fields that should be copied and reassociating the new record to appropriate parent.
graph
  subgraph o[Original]
    gp[Grandparent]
    p1[Parent]
    p2[Parent]
    c1[Child]
    c2[Child]
    c3[Child]
    c4[Child]

    gp --> p1 & p2
    p1 --> c1 & c2
    p2 --> c3 & c4
  end

  subgraph c[Clones]
    cgp[Grandparent]
    cp1[Parent]
    cp2[Parent]
    cc1[Child]
    cc2[Child]
    cc3[Child]
    cc4[Child]

    cgp --> cp1 & cp2
    cp1 --> cc1 & cc2
    cp2 --> cc3 & cc4
  end

  gp -.->|clones|cgp
  p1 -.->|clones|cp1
  p2 -.->|clones|cp2
  c1 -.->|clones|cc1
  c2 -.->|clones|cc2
  c3 -.->|clones|cc3
  c4 -.->|clones|cc4

We have some records that are recursive or need to inherit from multiple parents so part of the cloning calls:
defp assoc(%{data: %child{}} = changeset, parent) do
  for {_, {:assoc, assoc}} <- parent.__struct__.__changeset__(),
      assoc.related == child,
      assoc.relationship == :child,
      reduce: changeset do
    changeset ->
      Changeset.change(changeset, [{assoc.related_key, Map.fetch!(parent, assoc.owner_key)}])
  end
end

This uses the existing changeset reflection to get all child associations and associate them to the parent. An alternative would be to call the associations reflection and then get the association struct for each key with the association reflection.
😆 I recognize this is a niche use-case and I can work around it. An alternative to the proposal here could be to have another reflection that gives the association key and the association struct.
No hard feelings if you don't want this in Ecto 😄

Yes, I believe this is too specific to have in Ecto, given it is metadata that we will now compute and store for every possible schema. Thanks!


New bond highlighting code does a rubbish job with cyclopropane

Describe the bug
It's not unattractive, IMO, but clearly wrong.

To Reproduce
Steps to reproduce the behavior, feel free to paste a bit of Python in here.
Expected behavior
Plain rectangles under the cyclopropane bonds.
Screenshots
If applicable, add screenshots to help explain your problem.
Configuration (please complete the following information):

RDKit version: Build from current master
OS: MacOS and Windows
Python version (if relevant):
Are you using conda?
If you are using conda, which channel did you install the rdkit from?
If you are not using conda: how did you install the RDKit?

Additional context
I'll start work on a fix.

It occurred to me after filing this issue that even though I was being rude
about my own code, it sets a bad example. I will moderate my tone in future!
On Mon, 26 Sep 2022 at 09:58, Greg Landrum @.***> wrote:

Closed #5592 https://github.com/rdkit/rdkit/issues/5592 as completed
via #5596 https://github.com/rdkit/rdkit/pull/5596.
—
Reply to this email directly, view it on GitHub
https://github.com/rdkit/rdkit/issues/5592#event-7456743521, or
unsubscribe
https://github.com/notifications/unsubscribe-auth/ACGF2FT5Z4X5QLXYJJICJOLWAFQTBANCNFSM6AAAAAAQUTACIY
.
You are receiving this because you authored the thread.Message ID:
@.***>

--
David Cosgrove
Freelance computational chemistry and chemoinformatics developer
http://cozchemix.co.uk


admin failed to register， admin enrollment failed

[2017-08-05 13:15:32.016] [DEBUG] Helper - [ecdsa/key.js]: ECDSA curve param X: 6188b4831bf1b7707e52f0979ccab9381650ff5e4b63980e1cc93883a3eb15fa
[2017-08-05 13:15:32.016] [DEBUG] Helper - [ecdsa/key.js]: ECDSA curve param Y: eeb49cd01691e7c5ecdda343195f825a0f91ffe50d2d06fff57b9bb7e4fecf0f
[2017-08-05 13:15:32.016] [DEBUG] Helper - [FileKeyValueStore.js]: FileKeyValueStore -- setValue
[2017-08-05 13:15:32.035] [DEBUG] Helper - [crypto_ecdsa_aes]: ecdsa signature:  Signature {
  r: <BN: 5a65ab889c89564bbc408e9647053e0cd273da05ab8dbd58d2f99ebfe51e4739>,
  s: <BN: 58de5ec0560d5830a877716a0bc2746942ced76d603a67ad8fd45c112ae5dd68>,
  recoveryParam: 0 }
[2017-08-05 13:15:32.052] [DEBUG] Helper - admin failed to register
[2017-08-05 13:15:32.053] [ERROR] Helper - admin enrollment failed
[2017-08-05 13:15:32.053] [DEBUG] Helper - [ecdsa/key.js]: ECDSA curve param X: 6188b4831bf1b7707e52f0979ccab9381650ff5e4b63980e1cc93883a3eb15fa
[2017-08-05 13:15:32.053] [DEBUG] Helper - [ecdsa/key.js]: ECDSA curve param Y: eeb49cd01691e7c5ecdda343195f825a0f91ffe50d2d06fff57b9bb7e4fecf0f

Question: I setup fabric-explorer according to the README.md,
Everything go well except  an error reported above when I execute node main.js to try to setup the fabric-explorer server.
Thanks: If maintainers see this, help me :-).
It will be much appreciated.

Hello, I have this also, but it is because I don't have a CA server I think.
We don't use the CA server as we're using the generated certificates as is. So we don't enroll our user with login/password but directly with the certificates.
Is it supported?


Class Twig_Loader_Array does not exist

If you update composer.json, Twig_Loader_Array now Twig\Loader\ArrayLoader


Add support for Prometheus v2.0.0-beta0

Would be really nice to get working without modding the operator.
Patch should be pretty straightforward
Would it be possible to get this in the next patch release?

Prometheus v2.0.0-beta.0 is already supported (starting with the v0.11.0 release) :slightly_smiling_face:
I just deployed it on minikube from contrib/kube-prometheus/ off of master:

apiVersion: monitoring.coreos.com/v1alpha1
kind: Prometheus
metadata:
  name: k8s
  labels:
    prometheus: k8s
spec:
  replicas: 2
  version: v2.0.0-beta.0
  serviceAccountName: prometheus-k8s
  serviceMonitorSelector:
    matchExpressions:
    - {key: k8s-app, operator: Exists}
  ruleSelector:
    matchLabels:
      role: prometheus-rulefiles
      prometheus: k8s
  resources:
    requests:
      # 2Gi is default, but won't schedule if you don't have a node with >2Gi
      # memory. Modify based on your target and time-series count for
      # production use. This value is mainly meant for demonstration/testing
      # purposes.
      memory: 400Mi
  alerting:
    alertmanagers:
    - namespace: monitoring
      name: alertmanager-main
      port: web

$ kubectl -n monitoring get pod prometheus-k8s-0

apiVersion: v1
kind: Pod
metadata:
  annotations:
    kubernetes.io/created-by: |
      {"kind":"SerializedReference","apiVersion":"v1","reference":{"kind":"StatefulSet","namespace":"monitoring","name":"prometheus-k8s","uid":"da3e67ec-7468-11e7-a025-080027a8554e","apiVersion":"apps/v1beta1","resourceVersion":"421"}}
  creationTimestamp: 2017-07-29T14:18:54Z
  generateName: prometheus-k8s-
  labels:
    app: prometheus
    controller-revision-hash: prometheus-k8s-4270898966
    prometheus: k8s
  name: prometheus-k8s-0
  namespace: monitoring
  ownerReferences:
  - apiVersion: apps/v1beta1
    blockOwnerDeletion: true
    controller: true
    kind: StatefulSet
    name: prometheus-k8s
    uid: da3e67ec-7468-11e7-a025-080027a8554e
  resourceVersion: "584"
  selfLink: /api/v1/namespaces/monitoring/pods/prometheus-k8s-0
  uid: da410e36-7468-11e7-a025-080027a8554e
spec:
  containers:
  - args:
    - --config.file=/etc/prometheus/config/prometheus.yaml
    - --storage.tsdb.path=/var/prometheus/data
    - --storage.tsdb.retention=24h
    - --web.route-prefix=/
    image: quay.io/prometheus/prometheus:v2.0.0-beta.0
    imagePullPolicy: IfNotPresent
    livenessProbe:
      failureThreshold: 10
      httpGet:
        path: /status
        port: web
        scheme: HTTP
      initialDelaySeconds: 300
      periodSeconds: 5
      successThreshold: 1
      timeoutSeconds: 3
    name: prometheus
    ports:
    - containerPort: 9090
      name: web
      protocol: TCP
    readinessProbe:
      failureThreshold: 6
      httpGet:
        path: /status
        port: web
        scheme: HTTP
      periodSeconds: 5
      successThreshold: 1
      timeoutSeconds: 3
    resources:
      requests:
        memory: 400Mi
    terminationMessagePath: /dev/termination-log
    terminationMessagePolicy: File
    volumeMounts:
    - mountPath: /etc/prometheus/config
      name: config
      readOnly: true
    - mountPath: /etc/prometheus/rules
      name: rules
      readOnly: true
    - mountPath: /var/prometheus/data
      name: prometheus-k8s-db
    - mountPath: /var/run/secrets/kubernetes.io/serviceaccount
      name: prometheus-k8s-token-21c2j
      readOnly: true
  - args:
    - -reload-url=http://localhost:9090/-/reload
    - -config-volume-dir=/etc/prometheus/config
    - -rule-volume-dir=/etc/prometheus/rules
    image: quay.io/coreos/prometheus-config-reloader:v0.0.2
    imagePullPolicy: IfNotPresent
    name: prometheus-config-reloader
    resources:
      limits:
        cpu: 5m
        memory: 10Mi
      requests:
        cpu: 5m
        memory: 10Mi
    terminationMessagePath: /dev/termination-log
    terminationMessagePolicy: File
    volumeMounts:
    - mountPath: /etc/prometheus/config
      name: config
      readOnly: true
    - mountPath: /etc/prometheus/rules
      name: rules
    - mountPath: /var/run/secrets/kubernetes.io/serviceaccount
      name: prometheus-k8s-token-21c2j
      readOnly: true
  dnsPolicy: ClusterFirst
  hostname: prometheus-k8s-0
  nodeName: minikube
  restartPolicy: Always
  schedulerName: default-scheduler
  securityContext: {}
  serviceAccount: prometheus-k8s
  serviceAccountName: prometheus-k8s
  subdomain: prometheus-operated
  terminationGracePeriodSeconds: 600
  volumes:
  - name: config
    secret:
      defaultMode: 420
      secretName: prometheus-k8s
  - emptyDir:
      sizeLimit: "0"
    name: rules
  - emptyDir:
      sizeLimit: "0"
    name: prometheus-k8s-db
  - name: prometheus-k8s-token-21c2j
    secret:
      defaultMode: 420
      secretName: prometheus-k8s-token-21c2j
status:
  conditions:
  - lastProbeTime: null
    lastTransitionTime: 2017-07-29T14:18:54Z
    status: "True"
    type: Initialized
  - lastProbeTime: null
    lastTransitionTime: 2017-07-29T14:20:09Z
    status: "True"
    type: Ready
  - lastProbeTime: null
    lastTransitionTime: 2017-07-29T14:18:54Z
    status: "True"
    type: PodScheduled
  containerStatuses:
  - containerID: docker://17fb72d4c203835d3f602db50e9a4965c307f5e034087f28ec42658e7cffd713
    image: quay.io/prometheus/prometheus:v2.0.0-beta.0
    imageID: docker-pullable://quay.io/prometheus/prometheus@sha256:9ef4f19f79a9659f9988635b340959ee1a765116ad3b1ac34a4d5ed7feecd839
    lastState: {}
    name: prometheus
    ready: true
    restartCount: 0
    state:
      running:
        startedAt: 2017-07-29T14:19:49Z
  - containerID: docker://cb94abba9debde18e16f7b60edaa2f28f865626cb491017061b7944f4128ab2c
    image: quay.io/coreos/prometheus-config-reloader:v0.0.2
    imageID: docker-pullable://quay.io/coreos/prometheus-config-reloader@sha256:9ea705b2234f7deea22058a00ea46a303087828bde579b37255a590e8c0f4eca
    lastState: {}
    name: prometheus-config-reloader
    ready: true
    restartCount: 0
    state:
      running:
        startedAt: 2017-07-29T14:20:07Z
  hostIP: <IP_ADDRESS>
  phase: Running
  podIP: <IP_ADDRESS>
  qosClass: Burstable
  startTime: 2017-07-29T14:18:54Z

Closing here, let us know if you have any problem with using the beta! :slightly_smiling_face:

What about new rule format: https://prometheus.io/blog/2017/06/21/prometheus-20-alpha3-new-rule-format/ ?
I maybe missing something, but right now I get
time="2017-08-25T06:42:26Z" level=error msg="yaml: unmarshal errors:
  line 1: cannot unmarshal !!str `ALERT A...` into rulefmt.RuleGroups" source="manager.go:484"

when i try to use v2.0.0-beta.2
And I see that those rule files are still in old format. The easiest path if I understand correctly would be to put those converted rules into  ConfigMap and re-apply it

@gytisgreitai this issue is about the Prometheus Operator supporting the Prometheus beta, which it does. What you're referring to is kube-prometheus supporting the beta. kube-prometheus explicitly just supports whichever version we specify currently in the manifest. For other versions you will need to put in some effort to make it work. Typically we always support the latest stable release of Prometheus in kube-prometheus. So once Prometheus 2.0 stable is released we will make kube-prometheus compatible.

yeah thanks, I'm not complaining, just wanted to know if I understand this correctly. Thanks.

I didn't take it as a complaint, just clarifying. Of course if you already are working on getting everything 2.0 ready that will be a huge help once we need it, and testing 2.0 is definitely also encouraged! :slightly_smiling_face:

and fyi promtool can convert between old and new alerting syntax


[WIP] Audit changes

closes #151

All changes made except
LOW IMPORTANCE Note that if there is a input parameter validation error,
the ValidationError(...) events from RequestFactory will never get generated
because BaseScheduler.schedule(...) will throw an error if the validation fails,
and the event logs will not be persisted on the blockchain

Since RequestFactory can be used on a lower level than BaseScheduler I believe this is desired behavior. So if a user is using the Scheduler, they prefer to just get reverted if something is not validated, but if an advanced user is using the Request Factory itself, they may want the error.
Likewise I skipped the last comment about delayed payment for now. Will need to look into it more before resolution.


Feature request: log to files

Sometimes it is useful to log on Android and iOS to files, which can easily be zipped up and transferred for remote analysis.
Now that kotlinx-io has been released and supports multiplatform filesystem writes (via okio, and works at least for most platforms including Android and iOS), it would be great if Kermit would leverage this to provide filesystem writing capability out of the box, rather than having users roll their own LogWriters.
For a logging tool, it would be useful also to support automatic roll-overs and deletion of older logs.

Any thoughts on good models for this with other logging libraries? For mobile, do other logging libraries have default folders to store to and any kind of built-in functionality for wrapping up files? Probably nothing with actually sending them, but I could see returning a file reference to the zip.
It would be easier to essentially replicate an existing library that people seem to use vs writing something entirely new.

If you have a rough structure in mind, yeah, a PR would be good. I'd probably release this as another module rather than directly in kermit-core, at least to start. It can be focused more on mobile, or at least platforms that would support files easily (not JS).


The Server function is not working when routing back

I am using Solid Start with the server function to fetch a data from a Swapi API & I see that the server function works in a dev mode, but after deploying the App to Cloudflare workers, it seems broken.
In the Fist Load of the App I didn't see any errors, but when routing to about page & routing back to home page, its fails returning ugly HTML. when I see it in network tab preview window, I see these thing. It's an issue in Cloudflare Workers or in Solid Start? Note, that it works when I remove the server function & Also I am getting these error after alpha 61.

https://swapi.zeamanuel.workers.dev/
https://github.com/ZeAmanuel28/Solid-Swapi

Received new request: https://swapi.vinxi.workers.dev/_m/0dbe216f23
TypeError: Body has already been used. It can only be used once. Use tee() first if you need to read it twice. at line 0, col -2
{
  "exceptionDetails": {
    "columnNumber": -2,
    "exception": {
      "className": "TypeError",
      "description": "TypeError: Body has already been used. It can only be used once. Use tee() first if you need to read it twice.",
      "preview": {
        "description": "TypeError: Body has already been used. It can only be used once. Use tee() first if you need to read it twice.",
        "entries": null,
        "overflow": false,
        "properties": [
          {
            "name": "stack",
            "subtype": null,
            "type": "string",
            "value": "TypeError: Body has already been used. It can only…ce. Use tee() first if you need to read it twice.",
            "valuePreview": null
          },
          {
            "name": "message",
            "subtype": null,
            "type": "string",
            "value": "Body has already been used. It can only be used once. Use tee() first if you need to read it twice.",
            "valuePreview": null
          }
        ],
        "subtype": "error",
        "type": "object"
      },
      "subtype": "error",
      "type": "object",
      "value": null
    },
    "lineNumber": 0,
    "text": "Uncaught (in promise)",
    "url": "undefined"
  },
  "timestamp":<PHONE_NUMBER>000
}
TypeError: Body has already been used. It can only be used once. Use tee() first if you need to read it twice. at line 0, col -2
{
  "exceptionDetails": {
    "columnNumber": -2,
    "exception": {
      "className": "TypeError",
      "description": "TypeError: Body has already been used. It can only be used once. Use tee() first if you need to read it twice.",
      "preview": {
        "description": "TypeError: Body has already been used. It can only be used once. Use tee() first if you need to read it twice.",
        "entries": null,
        "overflow": false,
        "properties": [
          {
            "name": "stack",
            "subtype": null,
            "type": "string",
            "value": "TypeError: Body has already been used. It can only…ce. Use tee() first if you need to read it twice.",
            "valuePreview": null
          },
          {
            "name": "message",
            "subtype": null,
            "type": "string",
            "value": "Body has already been used. It can only be used once. Use tee() first if you need to read it twice.",
            "valuePreview": null
          }
        ],
        "subtype": "error",
        "type": "object"
      },
      "subtype": "error",
      "type": "object",
      "value": null
    },
    "lineNumber": 0,
    "text": "Uncaught (in response)",
    "url": "undefined"
  },
  "timestamp":<PHONE_NUMBER>000
}
[2022-04-01 20:01:01] POST swapi.vinxi.workers.dev/_m/0dbe216f23 HTTP/1.1 500 Internal Server Error

Okay this should be fixed now.. we haven't released the fixed version yet, but https://github.com/solidjs/solid-start/commit/fa64c6756a814589f1b99baf5f636d212df1816b should fix this


Metrics library - Changing metrics very small exponential number E-109 values to 0

Hello,
we are using metrics library to pull the metrics from springboot apps. On pushing the metrics to AWS cloudwatch  and whenever there is a small value found in metrics value like
(4.784335455263847E-109)  cloudwatch rejects those values and breaks completely updating the other positive (>0) metrics too.
After spoke with AWS cloudwatch we found that these very smaller values (E-169) need to be converted to 0 before sending the same metrics to cloudwatch. Could we get some approach how to to modify these smaller values as 0 which is a solution that we are looking ?
Actual Behaviour:
com.sam.work.rest.controller.ServiceControllerV1.getData.oneMinuteRate:2.721723306412017E-169
2017-03-11T07:56:42Z E! Error writing to output [cloudwatch]: InvalidParameterValue: The value 0 for parameter MetricData.member.10.Value is invalid.
The value 0 for parameter MetricData.member.12.Value is invalid.
Desired Behaviour to resolve this issue:
com.sam.work.rest.controller.ServiceControllerV1.getData.oneMinuteRate:0
2017-03-14T22:15:51Z D! Output [cloudwatch] wrote batch of 74 metrics in 11.133616242s
Please refer the below link as explained by AWS rejecting those metrics lesser than E-109
http://docs.aws.amazon.com/AmazonCloudWatch/latest/APIReference/API_PutMetricData.html

Hello. I guess this depends how you actually report data to CloudWatch. Do you use a third-party reporter, parse a some servlet output or read out a MetricsRegistry manually? The best way I think is write some decorator where you can perform any needed conversion. For instance, GraphiteReporter converts measurements to 2 digits after the point.  See here.

I forgot to mention that we use Telegraf to pull the HTTP JSON metrics and write it to cloudwatch.
In our case telegraf not able to convert the measurements , which is the bug confirmed by telegraf. So here is what recommened by telegraf team as a quick workaround. So looking for some guidance on what needs to be implemented on server to adjust the values to 0  before they enter in telegraf?
Recommendations from Telegraf:
"Update the server that your httpjson input uses as its source to adjust the values before they enter telegraf. We will try to get a fix done for this before the next release"
[[inputs.httpjson]]
servers = [
"http://localhost:2960/metrics"
]

I believe you use MetricsServlet which outputs metrics in the JSON format via HTTP. The actual JSON conversion is handled by Jackson in MetricsModule. Unfortunately, it can't be customized. The simplest option as I see is too copy-paste MetricsServlet and MetricsModule and make needed adjustments. Another option is too contribute to the original module the ability to configure a threshold for measurements.

Hey, was there any progress on this?

@abhi-jha This has to be fixed in your metrics reporter or in the monitoring system you're using.


Config Mismatch between the provided script and pretrained model

Hello, I had a look at the configs in the pretrained OFA-large model, and found a couple of differences. For example:

lr = 0.00005 instead of 0.0001 in the script nor 0.0002 in the paper.
max_update = 150K, instead of 500K in the paper nor 50 epochs in the script.
patch_image_size = 480 instead of 384 in the paper/script.
sample_patch_num = -1 instead of 196 in the script.

How was the large model being trained? Is the global_batch_size=batch_size * #GPUs * update_freq = 2048 for all models?
Thanks!

@zhaoweicai Please refer to Appendix A.2 in our paper. For OFA-Large, we first train it with images of the resolution of 384 × 384 (sample 196 patches), and continue pretraining with images of the resolution of 480 × 480.

Oh, I was reading the old version of the paper. But still some details are missing for the two-stage training of OFA-Large. I can find the configs of the 2nd stage from the model, but what are parameters for the 1st stage, e.g. LR and max_update?

And the datasets are exactly the same for those two stages?