TestNG printout wrong statistic number

hi ,
i am using 6.1
I have parameters set in xml suite file ,
when suite file is executed i have code to check if there are jvm parameter set , if yes these jvm parameters will overwrite the ones in xml file by calling "suite.getXmlSuite().setParameters(xmlPropertiesAfter);" ,
At the end of the execution testng printout following info (statistic number are all 0):
HelloAnything
Total tests run: 0, Failures: 0, Skips: 0
I found the root cause is that  testng will initialize  a "suiteRunnerMap" with XmlSuite/ISuite as key/value at the very beginning of the execution and then we changed xmlsuite in our code by the called "suite.getXmlSuite().setParameters(xmlPropertiesAfter);" , and at the end of the execution testng is not able to get the expected value by the modified key "xmlsuite" , see line 144 in calculateResultCounts() in SuiteRunnerWorker
So my question is Is there a workaround to let testng be able to get the right value from the key ?
or Could this bug be fixed ?
Many thanks !
br,
geoffrey/

Could you create a simple github project that I can pull and build in order to reproduce the problem? It's the easiest way. You should only need to include your test classes and a pom.xml, nothing else.
Thanks.

Hi，
It is done .
As requested only four files :
/testngcounterissue/src/main/java/MySuiteListener.java
/testngcounterissue/src/main/java/TestTestngCounter.java
/testngcounterissue/src/main/resources/TestTestNGCounter_suite.xml
/testngcounterissue/pom.xml
If you are using eclipse , rightclick the file TestTestNGCounter_suite.xml . Run as ->Run Configurations , create a TestNG configuration for this xml file and add jvm parameter "-Dtestng.eclipse.verbose=true" and run . You can see the wrong printout info :
TestTestngCounter
Total tests run: 0, Failures: 0, Skips: 0
NB! please try it on linux , it is 100% reproduced on this OS(at least in the linux servers in our team ) .
Thanks !

Where are the files?

Sorry my bad.
https://github.com/geoffreyzhang/TestNGcounterIssue

Hi cbeust,
BTW, May i know the plan when 6.2.2 will be released ?

？

Hi cbeust,
Do you have time to look into this? :-)

i make  a fix for this
https://github.com/cbeust/testng/pull/113

Thank you both for reporting and fixing the issue. I ended up fixing it differently from the way Luis did, take a look:
https://github.com/cbeust/testng/commit/09a11dcbf2138b933a5f6b9d61210cd8632e2bd9
Can you try the fix and report back? (either from github or by downloading the beta at http://testng.org/beta )
Thanks!

sorry Cedric,
but this does not fix the real problem
the real problem is that when you modify the suite from a suiteListener,
the hashcode of the xmlsuite changes.
and as the xmlSuite is the key of suiteRunnerMap,
the ISuite in the map never found
for example:
I could put this code in MySuiteListener:
public void OnStart (ISuite suite) {
Map <String, String> xmlPropertiesAfter <String, String> = new HashMap ();
xmlPropertiesAfter.put ("hello", "abc");
XmlSuite suite.getXmlSuite xmlSuite = ();
/ / xmlSuite.setParameters (xmlPropertiesAfter);
xmlSuite.setName ("Luis");
xmlSuite.setConfigFailurePolicy ("a");
}
and the problem still appear,Because I am changing the xmlsuite
for this in my fix ,i change the old xmlSuite whit the new
Code for my fix:
ISuite suiteRun = suiteRunnerMap.remove(xmlSuite);
SuiteRunner suiteRunner = (SuiteRunner) suiteRun;
suiteRunner.run();
suiteRunnerMap.put(xmlSuite, suiteRunner);
please check this
thanks for Luis Rivera

Hi Luis,
Have you tried the fixed version? I think it addresses the problem, which I
think I understood correctly. By removing m_parameters from the
equals()/hashCode() calculations, XmlSuites with different parameters become
equal.
Having said that, I think a better way to address this would be to look up
the object by name.
--
Cdric
2011/10/23 Luis Alfredo Rivera Acua <
<EMAIL_ADDRESS>
sorry Cedric,
but this does not fix the real problem
the real problem is that when you modify the suite from a suiteListener,
the hashcode of the xmlsuite changes.
and as the xmlSuite is the key of suiteRunnerMap,
the ISuite in the map never found
for example:
I could put this code in MySuiteListener:
public void OnStart (ISuite suite) {
Map <String, String> xmlPropertiesAfter <String, String> = new HashMap ();
xmlPropertiesAfter.put ("hello", "abc");
XmlSuite suite.getXmlSuite xmlSuite = ();
/ / xmlSuite.setParameters (xmlPropertiesAfter);
xmlSuite.setName ("Luis");
xmlSuite.setConfigFailurePolicy ("a");
}
and the problem still appear,Because I am changing the xmlsuite
for this in my fix ,i change the old xmlSuite whit the new
Code for my fix:
ISuite suiteRun = suiteRunnerMap.remove(xmlSuite);
SuiteRunner suiteRunner = (SuiteRunner) suiteRun;
suiteRunner.run();
suiteRunnerMap.put(xmlSuite, suiteRunner);
please check this
thanks for Luis Rivera
--
Reply to this email directly or view it on GitHub:
https://github.com/cbeust/testng/issues/107#issuecomment-2498726

yes  I try your solution,
but only fixes it, for the specific case of having parameters,
but could also change other things like:
xmlSuite.setName ("Luis");
xmlSuite.setConfigFailurePolicy ("a");
or any other change to the object xmlSuite and the hashCode change.
I think the way you generate the hashcode is very well, so just change the old key for the new.but
which would be a better way to solve this?

By mapping by name instead of XmlSuite: <String, ISuite> instead of <XmlSuite, ISuite>. This way, it doesn't matter what changes are made to the XmlSuite. Here is the change:
https://github.com/cbeust/testng/commit/9c1ba971b4d404a61308c77ae1891ad38400a0ba
What do you think?

I think you're solving a simple problem with a complex solution.
Plus I could change the name of the xmlSuite in the OnStart method of my listener
xmlSuite.setName ("Luis");
and so would not find ISuite on the map

Hi cbeust,
Have you verified your fix in my example project "https://github.com/geoffreyzhang/TestNGcounterIssue", i have tried the release 6.3.1 on that project , it does not work , or the fix did not included in this release?


add tests for current JSON parsers

[ ] activity
[ ] youtube likes
[ ] app installs
[ ] location history with timestampMS
[ ] location history with isoformat time
[ ] chrome history

for location history, this test should be running for HPI ci, using some public data in other github repository


[ContainerApp] Cloud Build Bugfix - 500 Internal Server Error (Wrong env selected to create builder)

This checklist is used to make sure that common guidelines for a pull request are followed.
Related command

Problem Statement - Running up with --source to trigger source to cloud, without passing the --environment argument selects the first environment by location and creates the builder in the wrong environment.
This fix extracts the environment from the Container App if it exists and ensures the container app and the builder are created in the same environment, so the container app has access to the private registry service to pull down the build image created by the builder.
Validation :
(After Change) This screenshot extracts environment from the Container App because it already exists.

(Before Change) This screenshot throws the Internal Server error because the builder was created in another environment and the Container App does not have access to the private registry that was spun up in the Builder's environment

If Container App does not exist, the first environment in the list of environments by location is selected to create the Builder resource and Container App

General Guidelines

[ ] Have you run azdev style <YOUR_EXT> locally? (pip install azdev required)
[ ] Have you run python scripts/ci/test_index.py -q locally? (pip install wheel==0.30.0 required)

For new extensions:

[ ] My extension description/summary conforms to the Extension Summary Guidelines.

About Extension Publish
There is a pipeline to automatically build, upload and publish extension wheels.
Once your pull request is merged into main branch, a new pull request will be created to update src/index.json automatically.
You only need to update the version information in file setup.py and historical information in file HISTORY.rst in your PR but do not modify src/index.json.

ContainerApp

The CI failed duo to Microsoft.DBforPostgreSQL update the api-version from 2023-03-01-preview to 2023-06-01-preview:
FAILED src/containerapp/azext_containerapp/tests/latest/test_containerapp_commands.py::ContainerappServiceBindingTests::test_containerapp_managed_service_binding_e2e
except CannotOverwriteExistingCassetteException as ex:

      raise AssertionError(ex)

E           AssertionError: Can't overwrite existing cassette ('/mnt/vss/_work/1/s/src/containerapp/azext_containerapp/tests/latest/recordings/test_containerapp_managed_service_binding_e2e.yaml') in your current record mode ('once').
E           No match for the request (<Request (POST) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DBforPostgreSQL/locations/eastus/checkNameAvailability?api-version=2023-06-01-preview>) was found.
E           Found 1 similar requests with 1 different matcher(s) :
E
E           1 - (<Request (POST) https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/providers/Microsoft.DBforPostgreSQL/locations/eastus/checkNameAvailability?api-version=2023-03-01-preview>)..)
E           Matchers succeeded : ['method', 'scheme', 'host', 'port', 'path']
E           Matchers failed :
E           _custom_request_query_matcher - assertion failure :
E           None
Please rerun this test with newest azure-cli code on the dev branch.

Please rerun all tests relate to the az containerapp up  lively with --live.

Please rerun all tests relate to the az containerapp up lively with --live.

@snehapar9 we should add test to cover this bug fix scenario with mutiple environment in same resource group.

Please rerun all tests relate to the az containerapp up lively with --live.

@snehapar9 we should add test to cover this bug fix scenario with mutiple environment in same resource group.

Thanks @Greedygre. Added a test to cover this bug fix scenario.

Please fix CI issues.

After this PR https://github.com/Azure/azure-cli-extensions/pull/7004 merge, the CI should pass.


Netfilterqueue dies unexpectedly

Because:
Compiled with a 4096-byte buffer for packets, so it probably won't work on loopback or Ethernet with jumbo packets. If this is a problem, either lower MTU on your loopback, disable jumbo packets, or get Cython, change DEF BufferSize = 4096 in netfilterqueue.pyx, and rebuild

I believe that when running iperf, to test the connection cannot handle the throughput and dies about 2-3 seconds into the test.  This could also be due to the low CPU rate for consuming packets, but the buffer may be leading the unexpected closing.

using -n 100000 max, at 1000000 unexpected quit occurs from nsfqueue.run()


always import install.yml when using local dir

fixes #160
solution proposed by @paulfantom

Apparently, ansible-lint don't like comparisons to empty string (E602 from https://docs.ansible.com/ansible-lint/rules/default_rules.html). I wonder if just ( node_exporter_binary_local_dir ) would work?

you seem to use  | length > 0  in other places, ok to use it here as well?

The error message does not say much but I assume it fails on 2.9 due to #158.

Failure is not related to #158. This is typical molecule failure to create test instance.


[V2V] Allow the ConversionHost#address field to be empty

Something of a followup to #18516, this again is based on feedback from the V2V team where it was decided that making the address field mandatory was a problem. Since the UI doesn't (currently) allow users to specify an IP, attempts to connect to the conversion host will fail without this atm.
~~https://bugzilla.redhat.com/show_bug.cgi?id=1622728~~
https://bugzilla.redhat.com/show_bug.cgi?id=1695797
Supersedes https://github.com/ManageIQ/manageiq/pull/18577 which originally set the default value. However, since the underlying IP address could change, it could get out of sync. Internally we use the ipaddress method, which will use the associated resource's IP already.
So, I think the best thing is to just loosen the restriction on setting the address.

@miq-bot add_reviewer @agrare

@miq-bot add_label transformation refactoring

@miq-bot add_label transformation, refactoring

@miq-bot add-label hammer/yes

Hammer backport details:
$ git log -1
commit 0c99f2223eb9b5020ac448f4fa80290c2d3d9d89
Author: Adam Grare<EMAIL_ADDRESS>Date:   Thu Apr 4 15:57:05 2019 -0400

    Merge pull request #18610 from djberg96/conversion_host_address_validation

    [V2V] Allow the ConversionHost#address field to be empty

    (cherry picked from commit 81a9ecaa36f2fd707092047716cafe4c217be158)

    https://bugzilla.redhat.com/show_bug.cgi?id=1696437


Generate Compute client library version 19.0.0 and update the tests.

Description

This checklist is used to make sure that common guidelines for a pull request are followed.

[x] Please add REST spec PR link to the SDK PR
[x] I have read the contribution guidelines.
[x] The pull request does not introduce breaking changes.

General Guidelines

[x] Title of the pull request is clear and informative.
[x] There are a small number of commits, each of which have an informative message. This means that previously merged commits do not appear in the history of the PR. For more information on cleaning up the commits in your PR, see this page.

Testing Guidelines

[x] Pull request includes test coverage for the included changes.

SDK Generation Guidelines

[x] If an SDK is being regenerated based on a new swagger spec, a link to the pull request containing these swagger spec changes has been included above.
[x] The generate.cmd file for the SDK has been updated with the version of AutoRest, as well as the commitid of your swagger spec or link to the swagger spec, used to generate the code.
[x] The *.csproj and AssemblyInfo.cs files have been updated with the new version of the SDK.

@dsgouda   I generated the code using the powershell script and updated the PR.

@dsgouda  Fixed tests and all checks passed.


Error with add new Inline form

All versions of django-smart-selects prior to version 1.2.8 are vulnerable to an XSS attack as detailed in issue 171. As a result, all previous versions have been removed from PyPI to prevent users from installing insecure versions. All users are urged to upgrade as soon as possible.
Checklist

[ x] This issue is not about installing previous versions of django-smart-selects older than 1.2.8. I understand that previous versions are insecure.
[x ] I have verified that that issue exists against the master branch of django-smart-selects.
[x ] I have searched for similar issues in both open and closed tickets and cannot find a duplicate.
[ ] I have debugged the issue to the smart_selects app.
[ ] I have reduced the issue to the simplest possible case.
[ ] I have included all relevant sections of models.py, forms.py, and views.py with problems.

Steps to reproduce
Hi,
I've this Inline
class EstateQualityEstateInline(admin.StackedInline):
model = EstateQualityEstate
extra = 2
suit_classes = 'suit-tab suit-tab-quality'
class EstateQualityEstate(models.Model):
estate = models.ForeignKey(Estate)
estate_quality = models.ForeignKey(EstateQuality, related_name='estate_quality_estate')
estate_quality_options = ChainedForeignKey(
EstateQualityOptions,
chained_field="estate_quality",
chained_model_field="estate_quality",
show_all=False,
auto_choose=True,
related_name='estate_quality_options_estate'
)
The code selects works fine for the two inline forms created. But when I click on "Add new form" in the inline. The new form don't populate the chained field.
Expected behavior
Actual behavior

Okay, this still doesn't tell me what's going on. Open up your browser developers tools and post the AJAX request data and the AJAX response data. Thanks!

Hi the problem that the new form don’t send request

On 23 Mar 2017, at 19:11, blag<EMAIL_ADDRESS>wrote:
Okay, this still doesn't tell me what's going on. Open up your browser developers tools and post the AJAX request data and the AJAX response data. Thanks!
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub https://github.com/digi604/django-smart-selects/issues/193#issuecomment-288812749, or mute the thread https://github.com/notifications/unsubscribe-auth/ACcCHFyj4jFDl1nOI4DWJXiljq56q80Eks5rorXggaJpZM4MnEzm.

Does your browser console show anything?

No,  the new one don’t send request

On 23 Mar 2017, at 20:04, blag<EMAIL_ADDRESS>wrote:
Does your browser console show anything?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub https://github.com/digi604/django-smart-selects/issues/193#issuecomment-288828039, or mute the thread https://github.com/notifications/unsubscribe-auth/ACcCHG91B_rW4dg99EfAKQ6btYIJpAefks5rosI7gaJpZM4MnEzm.

Post the entire HTML file please.

Just post everything that could possibly be relevant - I don't like guessing without any useful information. This includes:

Your INSTALLED_APPS setting
HTML of page that isn't working
Relevant excerpts from forms.py, views.py
Browser request/responses, even if they're empty (the endpoints may give me some clues)
Any troubleshooting steps you have taken so far

Also, try disabling django-suit and see if that fixes it.

I test it with and without django-suit
OTHER_APPS = [
'analytical',
'schedule',
'djangobower',
'adminsortable2',
'multiupload',
'easy_thumbnails',
'modeltranslation',
'easy_thumbnails.optimize',
'ckeditor',
'smart_selects',
'cachalot',
'cities_light',
'compressor',
'raven.contrib.django.raven_compat',
'djangoseo',
'djmoney',
'django_comments',
'polymorphic',
'import_export',
'django_extensions',
'filer',
'mptt',
'tagging',
'reversion',
'phonenumber_field',
'location_field.apps.DefaultConfig'
]

DJANGO_APPS = [
'django.contrib.contenttypes',
'django.contrib.auth',
'django.contrib.sessions',
'django.contrib.messages',
'django.contrib.staticfiles',
'django.contrib.humanize',
'django.contrib.sitemaps',
'django.contrib.flatpages',
'django.contrib.sites',
'django.contrib.gis',

'django.contrib.admindocs'
]
LOCAL_APPS = ['account',
#'zinnia',
'common',
'estate',
'location',
'customer',
'rental'
]
INSTALLED_APPS = OTHER_APPS + DJANGO_APPS + LOCAL_APPS
Browser request/responses, even if they're empty :
request URL:http://<IP_ADDRESS>:8000/chaining/filter/estate/EstateQualityOptions/estate_quality/estate/EstateQualityEstate/estate_quality_options/4/
Request Method:GET
Status Code:200 OK
Remote Address:<IP_ADDRESS>:8000
Response Headers
view source
Cache-Control:no-cache, no-store, must-revalidate, max-age=0
Content-Type:application/json
Date:Thu, 23 Mar 2017 21:52:12 GMT
Expires:Thu, 23 Mar 2017 21:52:12 GMT
Last-Modified:Thu, 23 Mar 2017 21:52:12 GMT
Server:WSGIServer/0.1 Python/2.7.13
X-Frame-Options:SAMEORIGIN
Request Headers
view source
Accept:application/json, text/javascript, /; q=0.01
Accept-Encoding:gzip, deflate, sdch, br
Accept-Language:es,pt-BR;q=0.8,pt;q=0.6,en-US;q=0.4,en;q=0.2,ca;q=0.2
Connection:keep-alive
Cookie:djdt=hide; sessionid=wu5miwf64r9qvig9xlkqebmqiu3yuul4; csrftoken=qQKsD447ZmWN5Jh8w0LTA7OixWU7ZoxvTxvCN4xHOuIOiY5R0mdqKm1r0h5Jv2U3
DNT:1
Host:<IP_ADDRESS>:8000
Referer:http://<IP_ADDRESS>:8000/admin/estate/estate/add/
User-Agent:Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_3) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/56.0.2924.76 Safari/537.36
X-Requested-With:XMLHttpRequest
Response:
[{"display": "A la Calle", "value": 50}, {"display": "A la piscina", "value": 53}, {"display": "A la Playa", "value": 44}, {"display": "Al golf", "value": 56}, {"display": "Al Mar", "value": 42}, {"display": "Al Parque", "value": 45}, {"display": "Al Puerto", "value": 51}, {"display": "Avenida", "value": 48}, {"display": "Centro Comercial", "value": 52}, {"display": "Colegio", "value": 54}, {"display": "Exterior", "value": 46}, {"display": "Jard\u00edn", "value": 49}, {"display": "Monta\u00f1a", "value": 43}, {"display": "Patio", "value": 47}, {"display": "Plaza", "value": 55}]
This request is the request/response created by the form.
When I click "Add Estate Quality Estate". The new inline model don't make any request/response
html.txt

This isn't supported yet. It relies on a refactor that externalizes the Javascript and updates the way we select widgets to attach event handlers to.
I'm keeping this open and adding the new "Needs external javascript rewrite" tag.

I also don't have too much time to work on the rewrite, but I can review a pull request for it. So if you find the time, please submit a PR. Thanks! 😄

Hi @blag,
I'm having the same issue: chained fields don't get updated for new forms and won't even make a request, but they do in existing forms and extras. I've been reading through all the issues and i'm a little confused, as I thought it was solved with #148, but now I read this issue and you say it isn't supported yet. Maybe there's a difference I can't see?
I'm using 1.3.4 with Django 1.10 and Suit, if you need any further information or want me to open a new issue just let me know, but I think my case is very similar to this.

@vborras Good question; they are different. #148 was about supporting modifying existing inlines, this one is about adding new objects via inlines. So if I have a parent with two children that already exist, D-S-S should support modifying the children (that's what #148 is about). This issue is about adding a new child via an inline, which isn't supported yet.
And IIRC, this is because the id attributes of the <input>s are known for existing objects, but not known for new <input>s that are created dynamically. That and we currently write out inline, customized javascript for each individual widget. A side effect of externalizing our JS is that we have to identify all <input>s we want D-S-S to bind to by their class attributes, which would make it much easier to support this. That is the "proper" way to do what we want, after all.
I hope that makes sense. Feel free to ask more questions if it isn't. And if you're having the same issue - unable to add new objects via inlines - please post any helpful info in this issue (and don't create a duplicate). If you are having a different issue that hasn't been reported yet, then please open a new issue. Thanks!

I see the problem. I'm not very confident about my JS skills, but I need this functionality, so I'll give it a try and if I get to a solution, I'll make a PR. Any guidelines on how to face this? I'm thinking about using data attributes instead of classes, is that ok?

This should be fixed in version 1.4.0, so I'm closing this. If it's not fixed please reopen it.

I am facing the same issue on smart-selects 1.5.4 / Django 2.0.6 / Py 3.6 (see https://github.com/digi604/django-smart-selects/issues/276).
Is the issue sorted out yet?

Hi Is this issue has been resolved already? I'm using the latest version both django and django-smart-selects

Hi Is this issue has been resolved already? I'm using the latest version both django and django-smart-selects

Hi! Has this issue been resolved yet? I'm also using the latest versions of both django and django-smart-selects and I'm still facing the same issue.

@blag hi!
this problem is still relevant for versions above 1.5.4.
Log from latest (1.6.0) version when i changed parent chained field:
2023-06-13 17:44:36 | INFO/MainProcess | "GET /chaining/filter/crm/Tariff/product_group/crm/UserInvoiceItem/tariff/53/ HTTP/1.1" 200 364
2023-06-13 17:44:36 | INFO/MainProcess | "GET /chaining/filter/crm/Product/product_group/crm/UserInvoiceItem/product/53/ HTTP/1.1" 200 556

Log from version 1.5.4 in same situation:
2023-06-13 17:57:36 | INFO/MainProcess | "GET /chaining/filter/crm/Tariff/product_group/crm/UserInvoiceItem/tariff/50/ HTTP/1.1" 200 361
2023-06-13 17:57:36 | INFO/MainProcess | "GET /chaining/filter/crm/Product/product_group/crm/UserInvoiceItem/product/50/ HTTP/1.1" 200 552
2023-06-13 17:57:36 | INFO/MainProcess | "GET /chaining/filter/crm/Discount/product_groups/crm/UserInvoiceItem/discounts/50/ HTTP/1.1" 200 129

My model structure:
product_group = models.ForeignKey(ProductGroup, on_delete=models.RESTRICT, default=None, null=True)

  product = ChainedForeignKey(Product,
                              chained_field="product_group",
                              chained_model_field="product_group",
                              show_all=False,
                              auto_choose=True,
                              sort=True,
                              default=None
                              )
  tariff = ChainedForeignKey("Tariff",
                             chained_field="product_group",
                             chained_model_field="product_group",
                             show_all=False,
                             auto_choose=True,
                             sort=True,
                             default=None
                             )
  discounts = ChainedManyToManyField("Discount",
                                     horizontal=True,
                                     chained_field="product_group",
                                     chained_model_field="product_groups",
                                     default=None,
                                     blank=True,
                                     )

I think its something wrong with inlines in versions >1.5.4


Add errorMessage in taskStatus for task failures in middleManagers/indexers/peons

Description
This PR is a follow-up of https://github.com/apache/druid/pull/11419 and fills the error message in TaskStatus properly when the task fails in the middleManager, indexer, or peon. It includes a minor refactoring for ForkingTaskRunner to make it more testable. Other than that, all changes are quite straight forward.
While I was making this PR, I remembered an issue with TaskRunnerListener that sometimes a wrong taskStatus is fed even though TaskRunnerListener is almost not in use. I created https://github.com/apache/druid/issues/11445 to track this issue.

This PR has:

[x] been self-reviewed.

[ ] using the concurrency checklist (Remove this item if the PR doesn't have any relation to concurrency.)

[ ] added documentation for new or modified features or behaviors.
[ ] added Javadocs for most classes and all non-trivial methods. Linked related entities via Javadoc links.
[ ] added or updated version, license, or notice information in licenses.yaml
[x] added comments explaining the "why" and the intent of the code wherever would not be obvious for an unfamiliar reader.
[x] added unit tests or modified existing tests to cover new code paths, ensuring the threshold for code coverage is met.
[ ] added integration tests.
[ ] been tested in a test Druid cluster.

@abhishekagarwal87 @loquisgon thanks for the review :+1:


clustermesh: missing identity from remote cluster leading to dropped traffic

Is there an existing issue for this?

[X] I have searched the existing issues

What happened?
We have 6 clusters, all in different aws regions, configured with clustermesh. Our workloads are broken into two types proxy and auth with auth living in only one of the clusters and proxy living in all the clusters. We observed a proxy pod failing to start due to being unable to connect to its respective auth pod that lived in another cluster. Hubble showed traffic being dropped due to Policy denied. The auth IP was properly resolved but had the label reserved:world. Running cilium identity list on the affected cilium pod showed a missing identity for the target auth.

Unhealthy node:
106300     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-usw2
           k8s:role=proxy
--
154213     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-use1
           k8s:role=proxy
--
225920     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-euc1
           k8s:role=proxy
--
251430     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-euc1
           k8s:role=proxy
--
280542     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=tc-prod-cs-01-aps1
           k8s:role=proxy
--
350792     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-apse1
           k8s:role=proxy
--
398899     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-sae1
           k8s:role=proxy

Healthy node:
77498      k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-usw2
           k8s:role=auth
--
106300     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-usw2
           k8s:role=proxy
--
154213     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-use1
           k8s:role=proxy
--
225920     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-euc1
           k8s:role=proxy
--
251430     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-euc1
           k8s:role=proxy
--
280542     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-aps1
           k8s:role=proxy
--
350792     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-apse1
           k8s:role=proxy
--
398899     k8s:app=teleport-cloud
           k8s:io.cilium.k8s.namespace.labels.kubernetes.io/metadata.name=namespace1
           k8s:io.cilium.k8s.policy.cluster=cs-01-sae1
           k8s:role=proxy

The surprising portion is that the proxy from usw2 is present but not the auth in usw2. I expect that both of those are known from the etcd cluster present in usw2. Restarting the cilium pod resulted in the complete identity list being generated and the affected proxy being able to connect to auth.
I have collected a sysdump from the affected cilium pod but haven't posted as I would likely need to do some redaction. If there are specific files that are useful that would make it easier to provide the information required.
Cilium Version
Client: 1.14.8 cf6e022e 2024-03-13T12:23:35-04:00 go version go1.21.8 linux/amd64
Daemon: 1.14.8 cf6e022e 2024-03-13T12:23:35-04:00 go version go1.21.8 linux/amd64
Kernel Version
Linux ip-10-19-101-0.eu-central-1.compute.internal 6.1.82 #1 SMP PREEMPT_DYNAMIC Fri Apr  5 22:26:15 UTC 2024 x86_64 x86_64 x86_64 GNU/Linux
Kubernetes Version
Server Version: v1.28.8-eks-adc7111
Regression
No response
Sysdump
No response
Relevant log output
No response
Anything else?
No response
Cilium Users Document

[X] Are you a user of Cilium? Please add yourself to the Users doc

Code of Conduct

[X] I agree to follow this project's Code of Conduct

We spotted an issue that feels similar to this in one of our environments. The identity was present but Service -> Pod IP mapping was missing. The only pods for the service existed in a different cluster.
# Bad state
cilium service list | grep <IP_ADDRESS>
8     <IP_ADDRESS>:26258    ClusterIP
9     <IP_ADDRESS>:26257    ClusterIP

# Good state
cilium service list | grep <IP_ADDRESS>
953   <IP_ADDRESS>:26257    ClusterIP      1 => <IP_ADDRESS>:26257 (active)
954   <IP_ADDRESS>:26258    ClusterIP      1 => <IP_ADDRESS>:26258 (active)

I have collected a sysdump of a node exhibiting this bad state as well and can provide redacted logs on request.

We have hit this once again. We had about ~5 pods across 3 clusters run into this causing app issues. Restarting the cilium pods on the nodes resolves the issue.

I'm mildly confident that the underlying cause should be fixed by https://github.com/cilium/cilium/pull/34091. Could you please give the latest patch release a try (the fix got backported to all affected releases)?

I'm mildly confident that the underlying cause should be fixed by #34091. Could you please give the latest patch release a try (the fix got backported to all affected releases)?

I believe you are right. We are running a custom version currently with https://github.com/cilium/cilium/pull/34148 patched which looks like the same fix you pushed and haven't encountered the issue again where we were previously able to consistently reproduce it. We are currently in the process of moving to latest v1.15 so we should be good there. Thanks!

Perfect, thanks for confirming.


[TW#27501] assertion "res == coreID || res == portMUX_FREE_VAL" failed: . function: vPortCPUAcquireMutexIntsDisabledInternal

Hi,
I am working on a project that integrates wifi manager https://github.com/tonyp7/esp32-wifi-manager, frequency counter https://github.com/DavidAntliff/esp32-freqcount and mqtt (tcp) example in latest release.
freqeuency counter and overall project event handler tasks are pinned to core 1.
on make flash, all code runs fine and I am able to subscribe to topic and publish first time.
Cyclic logic in the mqtt event handler: Publish should happens only when a previously subscribed topic is received.
Issue: the moment a subscribed topic is received, system crashes with below error.
assertion "res == coreID || res == portMUX_FREE_VAL" failed: file "/home/acer/esp/esp-idf/components/freertos/portmux_impl.inc.h", line 105, function: vPortCPUAcquireMutexIntsDisabledInternal
abort() was called at PC 0x400d64e3 on core 0
0x400d64e3: __assert_func at /Users/ivan/e/newlib_xtensa-2.2.0-bin/newlib_xtensa-2.2.0/xtensa-esp32-elf/newlib/libc/stdlib/../../../.././newlib/libc/stdlib/assert.c:63 (discriminator 8)
Backtrace: 0x40090588:0x3ffce650 0x400907b5:0x3ffce670 0x400d64e3:0x3ffce690 0x4008de4b:0x3ffce6c0 0x4008f7ae:0x3ffce6e0 0x400d3905:0x3ffce700 0x400d51d1:0x3ffce720 0x400d542a:0x3ffce740 0x400d55c6:0x3ffce780 0x400d5778:0x3ffce7b0 0x4008d56d:0x3ffce7d0
0x40090588: invoke_abort at /home/acer/esp/esp-idf/components/esp32/panic.c:680
0x400907b5: abort at /home/acer/esp/esp-idf/components/esp32/panic.c:680
0x400d64e3: __assert_func at /Users/ivan/e/newlib_xtensa-2.2.0-bin/newlib_xtensa-2.2.0/xtensa-esp32-elf/newlib/libc/stdlib/../../../.././newlib/libc/stdlib/assert.c:63 (discriminator 8)
0x4008de4b: vPortCPUAcquireMutexIntsDisabledInternal at /home/acer/esp/esp-idf/components/freertos/tasks.c:3564
(inlined by) vPortCPUAcquireMutexIntsDisabled at /home/acer/esp/esp-idf/components/freertos/portmux_impl.h:98
(inlined by) vTaskEnterCritical at /home/acer/esp/esp-idf/components/freertos/tasks.c:4258
0x4008f7ae: xEventGroupClearBits at /home/acer/esp/esp-idf/components/freertos/event_groups.c:338
0x400d3905: mqtt_event_handler at /home/acer/esp/esp-idf*.*/main.c:224
0x400d51d1: esp_mqtt_dispatch_event at /home/acer/esp/esp-idf/components/mqtt/esp-mqtt/mqtt_client.c:856
0x400d542a: deliver_publish at /home/acer/esp/esp-idf/components/mqtt/esp-mqtt/mqtt_client.c:856
0x400d55c6: mqtt_process_receive at /home/acer/esp/esp-idf/components/mqtt/esp-mqtt/mqtt_client.c:856
0x400d5778: esp_mqtt_task at /home/acer/esp/esp-idf/components/mqtt/esp-mqtt/mqtt_client.c:856
0x4008d56d: vPortTaskWrapper at /home/acer/esp/esp-idf/components/freertos/port.c:403
Please suggest how to solve this problem.
**Project environment:
IDF release 3.2
xtensa-esp32-elf-gcc (crosstool-NG crosstool-ng-1.22.0-80-g6c4433a) 5.2.0
HW: WROOM32**

hi @NewStackLearner
What exactly does the 'cyclic logic' in event handler mean? Do you publish to the same topic as subscribed? This scenario doesn't make much sense, but as far as I can see it works as expected and keeps publishing. Could you post a snippet here please?
The assertion indicates either a corupt memory or uninitialized mutex. From the attached log it looks like the crash happened when event propagated from mqtt module to user handler while clearing the event flags. Is the event flag initialized?
No other idea than probably a memory issue. Please check your heap size and stack size. Are you able to see the failure also without the two projects you mention? Can you try to comment out creating those to see if the error still persists?
Thanks

@david-cermak
Appreciate your interaction on the topic.

What exactly does the 'cyclic logic' in event handler mean?

static esp_err_t mqtt_event_handler(esp_mqtt_event_handle_t event)
{
switch (event->event_id) {
case MQTT_EVENT_CONNECTED:
//subscribe to topic1
break;

case MQTT_EVENT_SUBSCRIBED:
//publish topic 2
break;

case MQTT_EVENT_PUBLISHED:

//Wait for 5 seconds and then event in SensorStateChangeEventGroup;
//publish topic2 if event to publish
break;

case MQTT_EVENT_DATA:
wait for
//publish topic2 if current received data subscribed on topic1 is different from previous saved state
break;
}

Based on your feedback, i increased mqtt stack size to 32K. Also moved mqtt task to same core (Core 1) which is running user event handler. And, brought task priority of mqtt from 15 to 5, same as http. Same as before: user event handler task runs on priority 1 and frequency count task handler runs on priority 2
With this change, see the failure is less frequent and persists randomly within first 10 seconds of mqtt connection
i still see an infrequent debug message:
dhcps: send_offer>>udp_sendto result 0
and even less frequent
dhcps: send_offer>>udp_sendto result 0
dhcps: send_nak>>udp_sendto result 0
dhcps: send_offer>>udp_sendto result 0

I am also kind of lost with respect to task priorities. I noticed that if I am browsing web pages served by http, failure happens much faster.

Please check your heap size and stack size.
I could not find how to change heap size, please help.

Are you able to see the failure also without the two projects you mention?
No, failure occurs only when mqtt task is integrated in the wifi manager

Can you try to comment out creating those to see if the error still persists?
Issue not seen without MQTT task.

Ran out of ides to tryout further. Any suggestion are very welcome.
Many thanks!
Deepak

Hi Deepak,
Thanks for sharing the code. What struck me as odd is the
//Wait for 5 seconds and then event in SensorStateChangeEventGroup;

What kind of wait you use? (assuming vTaskDelay) The event handler runs from the MQTT thread context so it actually blocks all mqtt message reception/transmission.
If that's the case I would suggest another condition variable so the waiting takes place in a different thread (but that wouldn't explain crashes -- just some misbehaving transmission on mqtt side)
Wrtt dhcps debug logs: Don't you use some older IDF? (with the latest master, these lwip debug messages are all suppressed -- and I don't think it's even configurable to enable those)
Your issue is most likely some memory corruption. I cannot much help with that, but at least try to give some pointers (don't think changing task priority nor task pin to any core would help). IDF tools generate automatically ld script (https://docs.espressif.com/projects/esp-idf/en/latest/api-guides/linker-script-generation.html?highlight=linker).

I would not suggest to try to change heap size, but you can check it's size periodically calling esp_get_free_heap_size(). (note that FreeRTOS threads consume it for it's stack allocation).
When the app is compiled you can check remaining memory by idf.py size (or make size), interesting is Used static DRAM:,  you can read more about it here https://docs.espressif.com/projects/esp-idf/en/latest/api-guides/general-notes.html#dram-data-ram
About heap debugging please read https://docs.espressif.com/projects/esp-idf/en/latest/api-reference/system/heap_debug.html#heap-memory-debugging

Hopefully this helps, David

Hi David,
Thanks for all the help.
I repositioned event groups and removed them completely from the interrupt calls.
This solved the problem.
Many thanks once again!


Added base documentation

Thanks, Gary.

Completely my pleasure Evan.

I think @EvanDotPro merged this by accident because merge to develop branch is missing

@Maks3w: @GeeH asked him to only merge to master.

I need to confirm with @mwop, previously I have only been merging these
docs to master and Matthew has taken care of the rest.
On Sun, 17 Jan 2016 at 17:41 Rob Allen<EMAIL_ADDRESS>wrote:

@Maks3w https://github.com/Maks3w: @GeeH https://github.com/GeeH
asked him to only merge to master.
—
Reply to this email directly or view it on GitHub
https://github.com/zendframework/zend-json/pull/7#issuecomment-172400896
.


CMSCouch: using update_after for default (?)

Hi guys,
I was having a chat with @geneguvo this morning. As you might already know, using stale="ok" in couch queries means that the view will start building the cache before answering. In most cases this is annoying/dangerous because it can takes minutes/hours or even days for a view to rebuild the cache.
I think most of the queries we use in both CRAB3 and WMAgent use the update_after flag, which means Couch first return the data, and then starts building the cache of the view (anc connections never hangs).
In the past, it happened that developers forgot to put the update_after flag in their queries with all the kind of bad consequences.
Therefore my question, why don't we use the 'update_after' as a default value for the stale parameter  couch queries in CMSCouch (?). Should be just a matter of changing one line here somewhere: https://github.com/dmwm/WMCore/blob/master/src/python/WMCore/Database/CMSCouch.py#L398

Closing this, even though I still think it is a good idea that we use update_after by default when querying couch, I am resigning myself that it is never going to be implemented if this was not done in one year :)


Tina Style Isolation

Right now, Tina's style reset is designed to normalize elements between browsers (given it's pulled from Tailwind's preflight) and doesn't guard us from global user styles. Our wrapper class prevents our styles from interfering with the user's website, but not the reverse. In general, our UI is exposed and can be broken in a number of ways.
Here's an example from @jhuggett:

There are only two approaches I can think of to definitively resolve these types of issues:

Use an iFrame. (I believe we've ruled this out in the past)
Use a combination of all: unset; and px for all units (we're nearly there with this, but our rich text editor and some other elements are still subjected to root font size).

This seems to be the approach to have a blank slate to work with if you're putting a component somewhere with preexisting styles, but it will require a lot of work.

our rich text editor and some other elements are still subjected to root font size

We're using prose in there, but we do have control over all rich-text elements now, do you want to remove the use of prose?


Another dead link

"1.Create an MFA provider."
leads to a 404

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

ID: 45385357-e3b9-46ad-1230-98cf8ea2db35
Version Independent ID: 85fbe629-595d-1e1c-e112-0eb59c3bc59c
Content: Working with Self-Service Password Reset
Content Source: MIMDocs/working-with-self-service-password-reset.md
Product: microsoft-identity-manager
GitHub Login: @billmath
Microsoft Alias: billmath

Looks like the issue is caused because the link is pointing to the markdown URL instead of to the page URL.
Current URL: https://docs.microsoft.com/en-us/azure/multi-factor-authentication/multi-factor-authentication-get-started-auth-provider.md
Correct URL: https://docs.microsoft.com/en-us/azure/multi-factor-authentication/multi-factor-authentication-get-started-auth-provider
There are other links on the page that suffer from the same issue:

"Azure AD self-service password reset" - https://docs.microsoft.com/azure/active-directory/authentication/concept-sspr-howitworks.md
"writing back the new passwords to AD DS" - https://docs.microsoft.com/en-us/azure/active-directory/authentication/concept-sspr-writeback.md
"writing back the new passwords to AD DS" - https://docs.microsoft.com/en-us/azure/active-directory/authentication/concept-sspr-writeback.md

There are several more, but it doesn't effect every link.

Updating links.


Dotless does not accept -ms-filter

Hi,
If I have this piece of code below it works fine:
.gp_opacity(@opacity: 0.5) {
opacity: @opacity;
filter: ~"alpha(opacity=@{opacity});"
}
if I add a -ms-filter line to it like this:
.gp_opacity(@opacity: 0.5) {
opacity: @opacity;
-ms-filter: ~"'progid:DXImageTransform.Microsoft.Alpha(Opacity=@{opacity})';"
filter: ~"alpha(opacity=@{opacity});"
}
I get:
Expected '}' on line 20 in file 'gp_functions.less':
[19]: 	opacity: @opacity;
[20]: 	-ms-filter: ~"'progid:DXImageTransform.Microsoft.Alpha(Opacity=@{opacity})';"
-^
[21]: 	filter: ~"alpha(opacity=@{opacity});"

at a guess it is because the semi-colon needs to be outside the string so dotless knows the end of the value... It works with 1 property without a semi-colon because it forgives the last rule missing a semi-colon...

It works!


Documentation about $events Observable

I'm submitting a...

[ ] Regression (a behavior that used to work and stopped working in a new release)
[ ] Bug report
[ ] Performance issue
[ ] Feature request
[x] Documentation issue or request
[ ] Support request
[ ] Other... Please describe:

Current behavior
In the current documentation (2.13.0),
https://netbasal.gitbook.io/transloco/service-api/translation-api
we read :
// don't forget to unsubscribe
translocoService.events$.pipe(
 filter(e => e.type === 'translationLoadSuccess')
).subscribe(({ langName, scope }) => {
 ...
});

This gives an error : property langName does not exist on TranslocoEvents
Expected behavior
The following works with version 2.13.0 :
this.translate.events$.pipe(
      filter(e => e.type === 'translationLoadSuccess')
    ).subscribe(({ payload }) => {
      console.log(payload.langName);
    });

This does match the declared types :
export declare type LoadedEvent = {
    type: 'translationLoadSuccess';
    wasFailure: boolean;
    payload: {
        scope: string | null;
        langName: string;
        /** @deprecated */
        lang: string;
    };
};

Environment

Angular version: 8.2.14

Browser:
- [x ] Chrome (desktop) version 77

For Tooling issues:
- Node version: 10.16.0
- Platform:  Windows

updated the docs, thanks


python311Packages.splinter: 0.20.1 -> 0.21.0

Description of changes
Diff: https://github.com/cobrateam/splinter/compare/refs/tags/0.20.1...0.21.0
Changelog: https://splinter.readthedocs.io/en/stable/news/0.21.0.html

Things done

Built on platform(s)

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

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

[ ] sandbox = relaxed
[ ] sandbox = true

[ ] Tested, as applicable:

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

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

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

[x] Fits CONTRIBUTING.md.

Add a :+1: reaction to pull requests you find important.

Result of nixpkgs-review pr 281260 run on x86_64-linux 1

2 packages built:

python311Packages.splinter
python311Packages.splinter.dist


1.0.0.-rc.1 agent - invalid character '<' looking for beginning of value

Running agent rc.1 throws the following error in logs
{"level":"error","error":"invalid character '<' looking for beginning of value","platform":"linux/amd64","time":"2018-11-11T20:07:46Z","message":"cannot get queue item"}
Happens regardless of specified platform

I have not fully researched the issue. So I am closing this report.


net/http: include status code in comments

By showing the status code in the comment the code will be shown
in various editors as additional information.  As a developer, I often
know that I need to return a specific http code but I'm uncertain of
the semantic mapping that golang is using.  By including the code in
the comment it avoids having to either view the RFC or opening
the status.go source.
This PR will be imported into Gerrit with the title and first
comment (this text) used to generate the subject and body of
the Gerrit change.
Please ensure you adhere to every item in this list.
More info can be found at https://github.com/golang/go/wiki/CommitMessage

The PR title is formatted as follows: net/http: frob the quux before blarfing

The package name goes before the colon
The part after the colon uses the verb tense + phrase that completes the blank in,
"This change modifies Go to ___________"
Lowercase verb after the colon
No trailing period
Keep the title as short as possible. ideally under 76 characters or shorter

No Markdown
The first PR comment (this one) is wrapped at 76 characters, unless it's
really needed (ASCII art, table, or long link)
If there is a corresponding issue, add either Fixes #1234 or Updates #1234
(the latter if this is not a complete fix) to this comment
If referring to a repo other than golang/go you can use the
owner/repo#issue_number syntax: Fixes golang/tools#1234
We do not use Signed-off-by lines in Go. Please don't add them.
Our Gerrit server & GitHub bots enforce CLA compliance instead.
Delete these instructions once you have read and applied them

@googlebot I signed it!

I'm using VSCode.
  As I type I'd like to see what the code (the const int value) is as I pick from the list of presented terms.
The current behavior using vscode with gopls is to show...
int

If I type/complete http.StatusOK and then hover with my mouse over I see...
const http.StatusOK untyped int = 200
http.StatusOK on pkg.go.dev

hovering + ctrl is better (shows the line of code and RFC reference)
StatusOK                   = 200 // RFC 7231, 6.3.1
StatusCreated              = 201 // RFC 7231, 6.3.2
const http.StatusOK untyped int = 200
http.StatusOK on pkg.go.dev

I'm tempted to offer an updated PR with individual comments for each code..
	// StatusOK 200 - RFC 7231, 6.3.1
	StatusOK = 200

which offers while I type what I'd like to see...
int

StatusOK 200 - RFC 7231, 6.3.1

I agree this is certainly not a language issue.  Perhaps this is best fixed in gopls.

This sed line was used to modify the file (then formated by vscode/gofmt).
cat status.go | sed -r 's|(.*(Status[[:alpha:]]*)[[:space:]]*= ([[:digit:]]*)) // (.*)|// \2 \3 - \4\n\1\n|'


documentdb cli minor improvement

updates help description for credentials
minor change to formatting of failure error message
--coll-name changed to --collection-name

This checklist is used to make sure that common guidelines for a pull request are followed.
General Guidelines

[x] The PR has modified HISTORY.rst with an appropriate description of the change (see Modifying change log).

Command Guidelines

[x] Each command and parameter has a meaningful description.
[ ] Each new command has a test.

(see Authoring Command Modules)

@moderakh,
Thanks for your contribution as a Microsoft full-time employee or intern. You do not need to sign a CLA.
Thanks,
Microsoft Pull Request Bot

Codecov Report

Merging #3129 into master will increase coverage by 0.2%.
The diff coverage is n/a.

@@            Coverage Diff            @@
##           master    #3129     +/-   ##
=========================================
+ Coverage   70.22%   70.43%   +0.2%
=========================================
  Files         360      360
  Lines       23759    23759
  Branches     3626     3640     +14
=========================================
+ Hits        16685    16734     +49
+ Misses       6010     5962     -48
+ Partials     1064     1063      -1

Impacted Files
Coverage Δ

...db/azure/cli/command_modules/documentdb/_params.py
72.72% <ø> (ø)
:arrow_up:

...re/cli/command_modules/documentdb/_command_type.py
91.66% <ø> (ø)
:arrow_up:

...i/command_modules/documentdb/_exception_handler.py
18.96% <ø> (ø)
:arrow_up:

...-cli-role/azure/cli/command_modules/role/custom.py
35.74% <0%> (ø)
:arrow_up:

...zure-cli-vm/azure/cli/command_modules/vm/custom.py
73.13% <0%> (+0.32%)
:arrow_up:

...ource/azure/cli/command_modules/resource/custom.py
49.82% <0%> (+0.35%)
:arrow_up:

...cli-vm/azure/cli/command_modules/vm/_validators.py
68.82% <0%> (+0.36%)
:arrow_up:

...ice/azure/cli/command_modules/appservice/custom.py
73.29% <0%> (+0.45%)
:arrow_up:

.../azure/cli/command_modules/vm/_template_builder.py
76.84% <0%> (+0.52%)
:arrow_up:

...li-acs/azure/cli/command_modules/acs/acs_client.py
50% <0%> (+0.89%)
:arrow_up:

... and 13 more

Continue to review full report at Codecov.

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

@troydai there is no need for the status code (it can be inferred from the message itself). So I removed it. Please merge if looks fine to you.

@moderakh thank you.


new update break rpxy functionality

Today i have updated rpxy to latest version. rpxy works but my webpage is showing me blank white screen.  with htop linux command i am able to see rpxy works fine. i guess something need to change in my rpxy.toml file. please help me to translate my old rpxy.toml file

listen_port = 8080
listen_port_tls = 8443
tcp_listen_backlog = 1024
listen_ipv6 = false
max_concurrent_streams = 100
max_clients = 512
##[apps.calibre-web]
##server_name = 'calibre-web.XXX.xyz'
##tls = { https_redirection = true, tls_cert_path = '/certs/server.crt',  tls_cert_key_path = '/certs/server.key' }
##reverse_proxy = [{ upstream = [{ location = 'calibre-web:8083' }] }]
[apps.adguard]
server_name = 'adguard.XXX.xyz'
##tls = { https_redirection = true, tls_cert_path = '/certs/server.crt',  tls_cert_key_path = '/certs/server.key' }
tls = { https_redirection = true, tls_cert_path = '/mnt/dietpi_userdata/rpxy/server.crt',  tls_cert_key_path = '/mnt/dietpi_userdata/rpxy/server.key' }
reverse_proxy = [{ upstream = [{ location = 'localhost:8083' }] }]
[apps.vaultwarden]
server_name = 'vaultwarden.XXX.xyz'
#tls = { https_redirection = true, tls_cert_path = '/certs/server.crt',  tls_cert_key_path = '/certs/server.key' }
tls = { https_redirection = true, tls_cert_path = '/mnt/dietpi_userdata/rpxy/server.crt',  tls_cert_key_path = '/mnt/dietpi_userdata/rpxy/server.key' }
##reverse_proxy = [{ upstream = [{ location = 'localhost:8001' }] }]
#reverse_proxy = [{ upstream = [{ location = '<IP_ADDRESS>:8001', tls = true }] }]
reverse_proxy = [{ upstream = [{ location = 'localhost:8001' }] }]
##[apps.paperless]
##server_name = 'paperless.XXX.xyz'
##tls = { https_redirection = true, tls_cert_path = '/certs/server.crt',  tls_cert_key_path = '/certs/server.key' }
##reverse_proxy = [{ upstream = [{ location = 'paperless:8000' }] }]
[apps.homeassistant]
server_name = 'homeassistant.XXX.xyz'
#tls = { https_redirection = true, tls_cert_path = '/certs/server.crt',  tls_cert_key_path = '/certs/server.key' }
tls = { https_redirection = true, tls_cert_path = '/mnt/dietpi_userdata/rpxy/server.crt',  tls_cert_key_path = '/mnt/dietpi_userdata/rpxy/server.key' }
reverse_proxy = [{ upstream = [{ location = 'localhost:8123' }] }]
[experimental]
ignore_sni_consistency = false
[experimental.h3]
alt_svc_max_age = 3600             # sec
request_max_body_size = 65536      # bytes
max_concurrent_connections = 10000
max_concurrent_bidistream = 100
max_concurrent_unistream = 100
max_idle_timeout = 10              # secs. 0 represents an infinite timeout.
[experimental.cache]
cache_dir = '/tmp/rpxy'
#cache_dir = './cache'                # optional. default is "./cache" relative to the current working directory
max_cache_entry = 1000               # optional. default is 1k
max_cache_each_size = 65535          # optional. default is 64k
max_cache_each_size_on_memory = 4096 # optional. default is 4k if 0, it is always file cache.

this rpxy.toml file workes with second latest version of rpxy. but now latest showing me blank screen.

some error shows in logs like Feb 22 14:04:18 wyse rpxy_active[526]: 2024-02-22T21:04:18.173942Z  WARN rpxy rpxy_lib::forwarder::cache::cache_main: Too large to cache Feb 22 14:04:19 wyse rpxy_active[526]: 2024-02-22T21:04:19.364426Z ERROR rpxy rpxy_lib::message_handler::handler_main: Coping between upgraded connections failed: unexpected end of file

Feb 22 14:04:18 wyse rpxy_active[526]: 2024-02-22T21:04:18.173942Z  WARN rpxy rpxy_lib::forwarder::cache::cache_main: Too large to cache
Feb 22 14:04:19 wyse rpxy_active[526]: 2024-02-22T21:04:19.364426Z ERROR rpxy rpxy_lib::message_handler::handler_main: Coping between upgraded connections failed: unexpected end of file

As far as I roughly read the file, it looks fine even for the latest version. But I do not see what's wrong in your settings since I do not know your environment.
Please check first with the smallest configuration in your environment, like the example in README.md

with no TLS both in the front and backend,
using the basic executable binary compiled with no option,
etc.

I hash out experimental cache block then rpxy start working
###[experimental.cache]
###cache_dir = '/tmp/rpxy'
#cache_dir = './cache'                # optional. default is "./cache" relative to the current working directory
###max_cache_entry = 1000               # optional. default is 1k
###max_cache_each_size = 65535          # optional. default is 64k
###max_cache_each_size_on_memory = 4096 # optional. default is 4k if 0, it is always file cache.


Update vintage and active years

Please confirm that this PR has done the following:

[ ] Tests Added
[ ] Documentation Added
[ ] Description in RELEASE_NOTES.md Added

Adding to RELEASE_NOTES.md
Please add a single line in the release notes similar to the following:
- (#XX)[http://link-to-pr.com] Added feature which does something

rebased into<PHONE_NUMBER>e21ee8e877538f1e9767dbbad017f2


Emacs cleanup

Motivation for this change
Remove old code in the derivation. Make more explicit the fact that some inputs and steps are optional.
Things done

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

[ ] NixOS
[ ] OS X
[x] Linux

[ ] Tested compilation of all pkgs that depend on this change using nix-shell -p nox --run "nox-review wip"
[x] Tested execution of all binary files (usually in ./result/bin/)
[x] Fits CONTRIBUTING.md.

@the-kenny: comments addressed.

Did we really need the 6 commits?

Thanks @the-kenny.
@DamienCassou I had made 6 commits to document each step and help in the review. Each commit had its rationale in the commit message. Anyway, the commits were squashed pre-merge. The problem with that squashing is that all the information in the commit messages is gone from the repo and only lives in github.

@DamienCassou Note that I squashed the commits while merging the PR


Instagram problems

can't display data from instagram. why? thanks from Argentina!

you need to get here client id https://www.instagram.com/developer/
then get a token - and paste the token in the Social feed
Read more here http://instagram.pixelunion.net/

is betetr you not grant access to your instagram for 3rd part application.
Just folow the instagram instructions i used:
i've the original script workign simply getting from here:
https://www.instagram.com/developer/
CLIENT ID
CLIENT SECRET
WEBSITE URL
REDIRECT URI
SUPPORT EMAIL

now using your CLIENT ID and REDIRECT URI call this url:
https://api.instagram.com/oauth/authorize/?client_id=CLIENT-ID&redirect_uri=REDIRECT-URI&response_type=token
you will get the right TOKEN to use.
I've made this and all works.

@HartLarsson I've got two Instagram accounts I'm trying to pull from, and it's only pulling from the first one. I've dug through the source, and it doesn't seem that it takes multiple access_token's or client_id's, but it won't show the second account no matter what I do. Any ideas?

for what i know is impossible to pull from 2 diff accounts because the token is created per account(?)
I don't remember if i've tested two accounts, i oly use one instagram at time. One solution could be to use two istances configured with 2 ids and tokens.
I sonly a suppose i've not tested it.

Create an app and generate an access token from https://www.instagram.com/developer/.
Alternatively, you can generate an access token from http://instagram.pixelunion.net/
For it to work with the latest instagram API changes, you will only need your access token.
Here's a sample request with access token fb2e77d.47a0479900504cb3ab4a1f626d174d2d
instagram:{
    accounts: ['&fb2e77d'],  //Array: Specify a list of accounts from which to pull posts
    limit: 5, //Integer: max number of posts to load
    access_token: 'fb2e77d.47a0479900504cb3ab4a1f626d174d2d' //String: Instagram access token
}

This worked for me. I have not tried with multiple accounts.

@HartLarsson the URL you posted that generates the Token didn't work for me. It looks like it's missing a parameter, &scope=public_content. Here is the URL that worked for me:
https://www.instagram.com/oauth/authorize/?client_id=CLIENT_ID&redirect_uri=REDIRECT_URI&response_type=token&scope=public_content
Of course, you'll have to replace CLIENT_ID and REDIRECT_URI with your values.


"'filamentgroup' is not in the npm registry."

When running npm install grunt-grunticon --save-dev, I get errors.
I had no problem installing it for another project something like a month ago, and now impossible to install anything in any of my new projects. 😕
  ✔ jpegtran pre-build test passed successfully
npm ERR! 404 404 Not Found: filamentgroup
npm ERR! 404
npm ERR! 404 'filamentgroup' is not in the npm registry.
npm ERR! 404 You should bug the author to publish it
npm ERR! 404 It was specified as a dependency of 'directory-colorfy'
npm ERR! 404
npm ERR! 404 Note that you can also install from a
npm ERR! 404 tarball, folder, or http url, or git url.

npm ERR! System Darwin 14.3.0
npm ERR! command "node" "/usr/local/bin/npm" "install" "/Users/amaurymoulron/Downloads/grunticon-master"
npm ERR! cwd /opt/buzzfeed/solid
npm ERR! node -v v0.10.32
npm ERR! npm -v 1.4.28
npm ERR! code E404
npm ERR! not ok code 0

Oop.
npm install -g npm@latest should fix this up for you.

It did.
Thanks.


No Method to Configure Y-Axis... Words are Cut-Off

I am unable to configure the margins for the Y-axis Labels on the Left.
Essentially I have some long worded labels and they are getting cut off when the chart is drawn for Each Row. There is only a method to set the margins for the charts, that is currently not accounting for the margins of the x or y axes.
Please help. Thanks.

PR #73 should probably fix your issue, allowing you to set a custom label width. It should be merged very soon and be available in the 0.3.

Thanks! Looking forward to it

It should be fixed on latest master version now (PR #73 has been merged).
I let you check and close the issue if everything is fine?

Awesome! Let me check tomorrow...
On Thu, Jul 7, 2016 at 3:16 AM, Jonathan Petitcolas <
<EMAIL_ADDRESS>wrote:

It should be fixed on latest master version now (PR #73
https://github.com/marmelab/EventDrops/pull/73 has been merged).
I let you check and close the issue if everything is fine?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
https://github.com/marmelab/EventDrops/issues/78#issuecomment-231001560,
or mute the thread
https://github.com/notifications/unsubscribe/AIq0HvQO23qfH7R1e8H1f4vtEPfl0BuFks5qTKfegaJpZM4IioLk
.

--
Felix Dasgupta
C#:<PHONE_NUMBER>
Developer @Hindsait https://twitter.com/Hindsait
DJ Felix @adfelix2 http://soundcloud.com/adfelix2
TW: @FelixDasgupta https://twitter.com/FelixDasgupta
LN: @FelixDasgupta https://www.linkedin.com/in/felixdasgupta

Did you check with the new version? Is it OK for you?

Closing as no feedbacks.


integration-test 1.5.1

1.5.1 - 9534
casper-node 1.5.1-805a420
Added

config-example.toml

node

shutdown_for_upgrade_timeout
upgrade_timeout

Changed

chainspec.toml

protocol

version
activation_point

wasm

max_stack_height

should we change max_ttl from 1 day to 18hrs?


NixOS support (and other FHS-challenged distros)

Problem
Right now the shipped binaries make assumptions about where dynamically-linked libraries live. This is a problem for NixOS and other Linux distros that use less usual FHS layouts (there are dozens of us!).

The binaries that ship in the release are not statically linked, so there's several shared libraries that aren't loaded successfully (I suspect this can be patchelf'd in a pinch)

$ ldd forge
	linux-vdso.so.1 (0x00007ffe0b58f000)
	libssl.so.1.1 => not found
	libcrypto.so.1.1 => not found
[...]

forge build downloads a solc binary which suffers from the same problem.

$ forge build
compiling...
Error:
   0: "/home/shazow/.svm/0.8.2/solc-0.8.2": No such file or directory (os error 2)
[...]
$ ldd /home/shazow/.svm/0.8.2/solc-0.8.2
	linux-vdso.so.1 (0x00007ffec07b9000)
	libdl.so.2 => /nix/store/s9qbqh7gzacs7h68b2jfmn9l6q4jwfjz-glibc-2.33-59/lib/libdl.so.2 (0x00007fe833da6000)
	libm.so.6 => /nix/store/s9qbqh7gzacs7h68b2jfmn9l6q4jwfjz-glibc-2.33-59/lib/libm.so.6 (0x00007fe833c65000)
	libc.so.6 => /nix/store/s9qbqh7gzacs7h68b2jfmn9l6q4jwfjz-glibc-2.33-59/lib/libc.so.6 (0x00007fe833aa0000)
	/lib64/ld-linux-x86-64.so.2 => /nix/store/s9qbqh7gzacs7h68b2jfmn9l6q4jwfjz-glibc-2.33-59/lib64/ld-linux-x86-64.so.2 (0x00007fe834965000)

I tried using forge build --no-auto-detect but looks like it's refusing to use my local version.
$ which solc
/nix/store/5q9xn2s9pjav5fsh7qg8nj94gnj3jqdg-solc-0.8.2/bin/solc
$ forge build --no-auto-detect
compiling...
Error:
   0: "/home/shazow/.svm/0.8.2/solc-0.8.2": No such file or directory (os error 2)
[...]

Solutions

The low hanging fruit would be to build the shipped binaries as more statically linked than they are now. I do this for some other projects I maintain (mainly Go), it helps reduce all kinds of problems (can make it runnable on Alpine and other minimalist distros!) in exchange for larger binaries.

The more sustainable solution is to rely less on out-of-band binary fetching, and more on distro-friendly pre-packaging.

I understand that the current state of the project is in flux and perhaps the main demographic is people who copypasta curl-bash into their terminals (per the README), but realistically it does not need to be a big change to make this more distro packaging friendly. Even if we're not ready to start tagging releases, small things like changing the default Cargo dependencies to load specific versions rather than git main would go a long way (e.g. ethers-rs). Happy to send some PRs to this effect if it sounds desirable. :)

Unfortunately we can't statically link because of libusb. We're going to add packages on different package managers (apt, pacman, yum, brew are on my list), are there others you think we should have on our list?

I'd love nix support. :)
If you could include a flake.nix derivation, so that any distro that supports the nix package manager (basically everything) will be able to automagically build foundry from source in one command. This would also make it trivial to add to the nixpkgs package set as a full derivation.
I started some work on this here, but still needs more work: https://github.com/shazow/foundry/pull/1
Somewhat related to https://github.com/gakonst/foundry/issues/315 but I wanted to clarify that you can have this declaration in a generic way that does not require any further maintenance (unless your build process changes substantially), and you don't need to use it to manage your releases or anything like that.

I'll note this but do note that it is not top of my priority list currently. Feel free to open up a PR if you feel this is pressing, keeping in mind that we want to support releasechannels where possible (stable, nightly) and fixed versions for multiple package repositories, so maintainability is key here :smile:

I'll try to make it work out of band somehow, but right now none of this works on any of my devices unfortunately. So it is equally as pressing as me (or any other NixOS/etc user) wanting to use foundry. 😅

One more note: I compiled forge etc from source, and I'm able to reliably patch the svm-downloaded solc binaries with patchelf --set-interpreter "$(cat $NIX_CC/nix-support/dynamic-linker)" ~/.svm/0.8.2/solc-0.8.2 for example, but unfortunately that changes the hash of the file which prompts svm to overwrite it before building again and putting me back in square one.
I'd love for there to be a place to disable that svm behaviour, or an alternative approach.

@shazow all good points. You can disable svm with --offline / --no-autodetect when building or testing or disable them via the foundry toml.
Am supportive of making svm-rs more configurable, so that the paths issue does not manifest. cc @roynalnaruto
Further removing dynamic libraries seems hard, I've given it a lot of effort so far, but if you have any ideas for it I'd also be supportive, if we can let the user choose from static/dynamically linked to not inflate binary sizes too much or get us in violated license land.

@shazow Hi, if I'm not wrong, you are probably getting this error?
https://github.com/gakonst/ethers-rs/blob/e0ee03328332776f5f18a52b968ea3f62df982cb/ethers-solc/src/resolver.rs#L408-L413
Which would re-fetch the solc binary and your changed dynamic loader is reset?
Could you try the SOLC_PATH with --offline flag?
I am not sure how to configure svm-rs in order to support NixOS, but would be happy to take any suggestions from you or if you could PR to the repo?

(We just fixed  bug with --no-auto-detect btw, so I'd use that: t/foundry/pull/560)

Thanks, I'll give it a try soon!

Confirmed that the --no-auto-detect flag works as expected now.
I'm not sure if something like svm-rs is fixable for NixOS and similar distros. By nature, non-statically-linked binaries don't work. We have decent good tooling for patching the dynamically linked paths, and one idea would be to allow for a hook to run on install but that modifies the hash so hash-based version detection goes out the window.
In a full Nix-ified version of this, you would specify the derivation and companion versions you want available, and nix would make sure it's available for you. If foundry has provisions for enabling this scenario (ie. allow for multiple versions of solc to be available for selection but without necessarily relying on a binary fetcher), then I think the rest can be done in the nix packaging out of band.
Would it be possible for it to be an ENV var rather than a flag with every command?

One more update: I made a stand-alone nix flake which uses the binary releases, it lives here for now (good chance I'll move it eventually): https://github.com/shazow/nixfiles/blob/master/flakes/foundry/flake.nix
This means that anyone who has nix installed can run nix develop git+https://github.com/shazow/nixfiles?dir=flakes/foundry to enter a shell that has forge and cast that has been patchelf'd to the current system.
A few caveats:

As expected, it's pinned to specific release binaries/hashes (nix requires this). It would need to be updated with every release (this can be scripted).
It doesn't work as a build input for other flakes yet, I think that's because I tossed it into my repo with my other nix configs and flakes don't like that apparently. :)

Ah figured out how to use my foundry flake as an input for my solidity project's devshell flake, in case this is useful for anyone:
{
  inputs = {
    nixpkgs.url = "github:NixOS/nixpkgs/nixpkgs-unstable";
    utils.url = "github:numtide/flake-utils";
    foundry.url = "git+https://github.com/shazow/nixfiles?dir=flakes/foundry";
  };

  outputs = { self, nixpkgs, utils, foundry }:
    utils.lib.eachDefaultSystem (system:
      let
        pkgs = import nixpkgs { inherit system; };
      in {
        devShell = with pkgs; mkShell {
          buildInputs = [
            solc
            foundry.defaultPackage.${system}
          ];

          shellHook = ''
            export PS1="\e[1;33m\][dev]\e[1;34m\] \w $ \e[0m\]"
          '';
        };
      });
}

Would it be possible for it to be an ENV var rather than a flag with every command?

You can do that via the foundry.toml file, by specifying a compiler version, see the config package readme!

Update in case anyone else is using this with nix: I refactored my foundry binaries derivation so it's much cleaner now and can be easily updated with latest nightlies using ./update.sh: https://github.com/shazow/nixfiles/tree/master/flakes/foundry
I'm considering putting this in another repo that is just a nix overlay, and could setup a Github CI to auto-update regularly, but probably won't do it unless other people are relying on this (feel free to ping if that's the case). :) For now I just run the update script when it's convenient for me.
(For non-nixers: this makes the equivalent of foundryup to be nix flake update in your respective project.)

Separating it in an isolated Nix package that people can easily install would be great! Thanks for taking the time. We should then add it to the Readme

Maybe this can be resolved upstream in the forthcoming release for solidity as they are overhauling their build pipeline/automation, https://github.com/ethereum/solidity/issues/13610

Given the Solidity pipeline cleanup does not seem to be going as fast as we would wish, would it make sense to add a compilation flag capable of configuring a hook that invoked a command or shell script after solc binary download? It's a quick and dirty fix, but it would solve this issue.

I use nix-ld, so this seems not a problem. And I specify solc_version in the foundry.toml so that foundry (setup using foundry.nix project by shazow) wouldn't attempt to download it all the time.

https://github.com/hellwolf/solc.nix this flake may help you to get different version of solc locally available. And with FOUNDRY_SOLC_VERSION environment variable you can choose solc-* binary you need; we use that in our CI pipeline.

I think I have a working setup here: https://github.com/shazow/foundry.nix

@shazow thank you so much for the overlay!
Keep an eye on https://github.com/nix-community/ethereum.nix, we might merge into there once foundry has persistent tagged versions. Lots of other goodies there too!

Is this working well enough? Should we close this? Should we highlight this better in the book @shazow ?

@gakonst Ideally I'd prefer to have versioned tagged releases so that we can do cached builds from source on NixOS. Right now it's fairly hacky.
I do agree it's a good idea to document this in the book. Should I add it to https://github.com/foundry-rs/book/blob/master/src/getting-started/installation.md?

we will not be forgotten

https://discourse.nixos.org/t/nix-ld-rs-testers-wanted/42145

"Nix-LD-RS provides a shim layer that allows users to specify the necessary libraries for each executable and improves the user experience by allowing users to easily run binaries from third-party sources and proprietary software"

Testers are wanted, @shazow , see the repo at: https://github.com/Mic92/nix-ld

I came across this thread after a lot of digging and experimenting with foundry + solc + nix. I've been having a difficult time making foundry reconcile different solc versions and have been following svm-rs path handling.
I was thinking that if we emulate the svm folder structure while symlinking to the static solc.nix versions, it should be sufficient to run forge build --offline. @shazow and @hellwolf, have ye come across a solution for something like this?
{
  pkgs,
  lib,
  fetchFromGitHub,
  ...
}:

pkgs.stdenv.mkDerivation rec {
  pname = "contracts-bedrock";
  version = "1.4.0-rc.2";

  src = fetchFromGitHub {
    owner = "ethereum-optimism";
    repo = "optimism";
    rev = "op-contracts/v${version}";
    hash = "sha256-ryiXWuH3vIjOdMrKSeIeJOWd+7X+hTaDnWx/ugoUI/Q=";
    fetchSubmodules = true;
  };

  nativeBuildInputs = with pkgs; [ foundry-bin ];

  unpackPhase = ''
    cp $src/packages/contracts-bedrock/foundry.toml .
    cp -r $src/packages/contracts-bedrock/src .
    cp -r $src/packages/contracts-bedrock/test .
    cp -r $src/packages/contracts-bedrock/scripts .
    cp -r $src/packages/contracts-bedrock/lib .

    TEMP=$(mktemp -d)

    mkdir -p $TEMP/svm
    touch $TEMP/svm/.global-version

    mkdir -p $TEMP/svm/0.8.15
    ln -s ${lib.getExe pkgs.solc_0_8_15} $TEMP/svm/0.8.15/solc-0.8.15

    mkdir -p $TEMP/svm/0.8.24
    ln -s ${lib.getExe pkgs.solc_0_8_24} $TEMP/svm/0.8.24/solc-0.8.24

    mkdir -p $TEMP/svm/0.8.0
    ln -s ${lib.getExe pkgs.solc_0_8_0} $TEMP/svm/0.8.0/solc-0.8.0

    XDG_DATA_HOME=$TEMP
  '';

  buildPhase = ''
    forge build --offline
  '';

  meta = with lib; {
    description = "Optimism is Ethereum, scaled.";
    homepage = "https://optimism.io/";
    license = with licenses; [ mit ];
    platforms = [ "x86_64-linux" ];
  };
}

Fixed with missing export and some util functions, could probably be more polished but I think it works as a general solution
{
  pkgs,
  lib,
  fetchFromGitHub,
  ...
}:
let

  mkSolcSvmInstallation =
    solcPkg:
    let
      solcBinPath = lib.getExe solcPkg;
      version = lib.lists.last (
        lib.strings.splitString "-" (lib.lists.last (lib.splitString "/" solcBinPath))
      );
    in
    ''
      mkdir -p $XDG_DATA_HOME/svm/${version}
      ln -s ${solcBinPath} $XDG_DATA_HOME/svm/${version}/solc-${version}
    '';

  mkSolcSvmDataDir =
    solcPkgs:
    let
      solcInstalls = lib.strings.concatLines (lib.lists.forEach solcPkgs mkSolcSvmInstallation);
    in
    ''
      export XDG_DATA_HOME=$(mktemp -d)
      mkdir -p $XDG_DATA_HOME/svm
      touch $XDG_DATA_HOME/svm/.global-version
      ${solcInstalls}
    '';
in
pkgs.stdenv.mkDerivation rec {
  pname = "contracts-bedrock";
  version = "1.4.0-rc.2";

  src = fetchFromGitHub {
    owner = "ethereum-optimism";
    repo = "optimism";
    rev = "op-contracts/v${version}";
    hash = "sha256-ryiXWuH3vIjOdMrKSeIeJOWd+7X+hTaDnWx/ugoUI/Q=";
    fetchSubmodules = true;
  };

  nativeBuildInputs = with pkgs; [ foundry-bin ];

  unpackPhase = ''
    cp $src/packages/contracts-bedrock/foundry.toml .
    cp -r $src/packages/contracts-bedrock/src .
    cp -r $src/packages/contracts-bedrock/test .
    cp -r $src/packages/contracts-bedrock/scripts .
    cp -r $src/packages/contracts-bedrock/lib .

    ${mkSolcSvmDataDir (
      with pkgs;
      [
        solc_0_5_17
        solc_0_8_15
        solc_0_8_19
        solc_0_8_24
        solc_0_8_25
      ]
    )}
  '';

  buildPhase = ''
    forge build --offline
  '';

  installPhase = ''
    mkdir -p $out
    cp foundry.toml $out/
    cp -r src $out/
    cp -r test $out/
    cp -r scripts $out/
    cp -r lib $out/
    cp -r forge-artifacts $out/
    cp -r cache $out/
  '';

  meta = with lib; {
    description = "Optimism is Ethereum, scaled.";
    homepage = "https://optimism.io/";
    license = with licenses; [ mit ];
    platforms = [ "x86_64-linux" ];
  };
}

@Padraic-O-Mhuiris Very cool! Any interest in adding that as a helper to https://github.com/shazow/foundry.nix? Or maybe even https://github.com/nix-community/ethereum.nix

@shazow I'd love to when I have the time, maybe over the weekend, it actually could be a lot more polished where a bit more nix lib code can be used to "grep" for the pragma line in each solidity contract and use that to build the solc package list.
Also to make it even more generalised is utilise the foundry.toml to comprehend what relevant solidity files should be tangled out. There would be complications as some people may use npm/yarn/pnpm to pull in 3rd party contracts.

Tagging as blocked by https://github.com/foundry-rs/foundry/issues/3895

Hi all, would be great to get your input on this PR: https://github.com/foundry-rs/foundry/pull/9260
Would this be a valuable addition unblocking you?

@zerosnacks Thanks for the ping! Looks like a solid improvement for adding support to build foundry from source. I'd say #3895 is still blocking for proper upstream distribution/packaging management support, but this is a worthy improvement.


Update docker-compose-collect.yml

Bugs in docker-compose-collect.yml solved

Hello,
Thanks for the fix. Sorry it took so long to integrate those changes (cf #2). I made an update today that should fix it.


Allow application to replace the default pattern for all log appenders

Allows the single, default pattern to be customized by the application (e.g. to include certain MDC values)
without requiring individual deployments to copy-paste the same format override in their YAML files.

@wrprice sorry it took so long for a reply.
The theme of this looks good, but I don't like the static state. Could you just have a:
public String getPattern(Timezone timezone)
which by default returns what existed.
If people want custom patterns, they can subclass & override.
Alternatively, pass the factory via constructor and store it in a normal field.
thanks for the contribution.

Looking at this some more, I think we should just rely on the configuration patterns in the config. If you really want to override the defaults, now you can roll your own LoggerFactory


msp-osd doesn't work with goggles V2 and O3

I hope to be clear.
I have DJI Goggles V2 properly rooted. I can access the CLI, activate the package and so on.
They are updated to the latest firmware in order to be used with DJI O3 and BF 4.4.
With the msp-osd service enabled and fakeHD enabled, I still can't get the HD OSD. Also the fonts in the SD are not read.
Even if I copy them to the blackbox.
I can't figure out what's missing to see the changed fonts. I continue to see the default OSD
I can add that also the Image Configurator seems not working. I put the 3 png files on the SD but are not read at all.
The only way to change the screensaver is using the internal WTFOS images.

I found this answer on another forum:
You can use wtf.os with Vistas and original air units. When you switch to O3 mode then it will use msp-osd DJI came up with. Wtfos is only for the original Fpv system side.
Upgrading goggles will wipe out the wtfos hack. But after upgrading you can reinstall it. All works fine and and I go back and forth on my goggles.
If you have used wtfos with nice fonts it is way prettier then DJIs o3 msp-osd. Crazy amateur hackers can create a nicer system than DJI.
Heres hoping they root the o3 side and can make things better for us.

Rooting allows you to run and install a custom operating system on the goggles (WTFOS) along with custom non-approved 3rd party packages on the hardware when used with the original DJI FPV System firmware. One good example is giving users the ability to make use of the full Betaflight OSD which isn't natively available under the original DJI FPV System firmware unless you root the goggles (and also the Air Unit) and install the msp-osd package. Other approved and tested packages can be found HERE.
None of the WTFOS stuff works with the DJI O3 Air Unit and that already has native support for full Betaflight OSD anyway, so you don't need to root or hack your goggles to get that functionality.
If you have no reason to root your goggles (because you're not using a Caddx Vista, RunCam Link or full size OG DJI Air Unit) then I wouldn't bother wasting your time doing so because it will just be a load of work for no gain as it won't offer you anything when using an O3 Air Unit.


Add reStructuredText to markupGrammars

Another language we support out of the box 🎉

Nice add!

Very awesome @lgeiger :cake:


Request units calculation when reading from secondary

Suppose I'm reading from a collection in a secondary (geo replicated) CosmosDB region - Does this read counts towards the general RU limit of the collection on the primary region ?
In other words - is the RU limit per region or the sum of all operations in all regions must be lower than the limit ?

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

ID: abb0beaa-01ab-7031-937e-2d44c147b5d2
Version Independent ID: 742b249e-054f-a160-c2f5-7c22a796f9d0
Content
Content Source
Service: cosmos-db

@liranms We are looking into this question and will get back to you.

"A read is 1 RU regardless of the number of items stored or the number of concurrent requests running at the same time". I agree it's not specific to where the RUs go to the primary or secondary region. I'll forward your feedback to the author.

The RU limit is per region. There is throughput isolation, so what happens in one region does not affect what happens in other regions. It's covered well in this video - https://azure.microsoft.com/en-us/resources/videos/planet-scale-nosql-with-documentdb/ - near 11 min 45 sec.  I will update the documentation shortly.

#in-process

I've submitted a PR for the fix and am waiting on tech review of the new material.

@liranms - The following information will be published tomorrow morning to address this issue in https://docs.microsoft.com/en-us/azure/cosmos-db/request-units, and I'm assuming this addresses this issue. This issue is set to auto close when the pull request with that fix is merged into our build for publication. If this does not meet your needs, please let me know. Thank you!
Throughput isolation in globally distributed databases
When you have replicated your database to more than one region, Azure Cosmos DB provides throughput isolation to ensure that RU usage in one region does not impact RU usage in another region. For example, if you write data to one region, and read data from another region, the RUs used to perform the write operation in region A do not take away from the RUs used for the read operation in region B. RUs are not split across the regions in which you've deployed. Each region in which the database is replicated has the full amount of RUs provisioned. For more information about global replication, see How to distribute data globally with Azure Cosmos DB.


Home page for large repositories is slow

Gitea version (or commit ref):1.9.4
Git version:2.22.0
Operating system:Debian Linux (but using the official docker container)
Database (use [x]):

[x] PostgreSQL
[ ] MySQL
[ ] MSSQL
[ ] SQLite

Can you reproduce the bug at https://try.gitea.io:

[x] Yes (provide example URL)
[ ] No
[ ] Not relevant

Log gist:

Description
Loading the index page for large repositories is slow, loading:
https://try.gitea.io/tonycoz/perl5
takes 15000 to 19000 ms, the similar page on github:
https://github.com/perl/perl5
loads in 2000ms
Screenshots

Duplicate of #491.
It is the combination of many files/directories and many commits that makes it slow.


getNetworkType doesn't work with VPN

getNetworkType works when you have say both a mobile and a wifi connection active, but unfortunately does not when you have a VPN active since VPN is the active network. As a result, you'd get NOT ROAMING.
I suggest checking if network is of type VPN, and if it is, proceed to loop over all existing networks to see what they are and if they include WIFI. (Unfortunately in this case you can't know if it's unmetered, but yea - at least you know if it's VPN via WIFI or VPN via mobile connection).

Do you have sample code for that?

Sure, I just bugged @tobiasKaminsky  to do it for something else :P
Check isOnlineWithWifi method here:
https://github.com/nextcloud/android/pull/2352/files
And my explanation here:
https://github.com/nextcloud/android/pull/2352#issuecomment-373310256

Now that I think about it, NOT ROAMING is appropriate return value, but maybe poorly worded for this particular use case. It means metered (since it's not unmetered), it's just the fact that it would be good to know if it's via WIFI or VIA mobile.

Those names are coming from the JobScheduler. I'll take a look, but I can't guarantee that I'll make any changes.

Sounds good, thanks.

This issue has been fixed in version 1.2.5. Thanks for reporting it!