Renaming PanObjects

I am looking to use pandevice to achieve the same effect as CLI command:
rename address TestOriginalName to TestNewName

Here's what I've tried without success:
objects.AddressObject.refreshall(Firewall, add=True)

for item in Firewall.children:
    if isinstance(item, pandevice.objects.AddressObject):
        if item.name == 'TestOriginalName':

            # This just results in completely new AddressObject being added to the firewall
            # And not a rename of the existing one like the docs for PanObject.apply() seem to imply:

            # apply()
            #   Apply this object to the device, replacing any existing object of the same name

            item.name = 'TestNewName'
            item.apply()

            # This just raises:
            # KeyError: 'name'
            item.name = 'TestNewName'
            item.update('name')

@johnworkman
Need to check and see if PAN-OS has a "rename" action, I don't know.  However, if you are looking to accomplish a rename in pandevice, you need to delete the object, then update the name, then you would .create().  We need to be slightly careful here as executing .delete() removes it from the parent's children, so we need to add it back in.  Finally, if you don't want to save the address object listing returned from the refreshall() method to loop through, you can use .find() to cut down on the code you are doing above:
from pandevice.firewall import Firewall
from pandevice.objects import AddressObject

old_name = 'TestOriginalName'
new_name = 'TestNewName'

fw = Firewall(....)
AddressObject.refreshall(fw)

target = fw.find(old_name, AddressObject)
if target is not None:
    target.delete()
    target.name = new_name
    fw.add(target)
    target.create()


Why the python encoding in Atom is different with terminal?

In Atom, when I print(sys.stdout.encoding), it shows US-ASCII.
But in terminal, it shows UTF-8, how can I change the atom python encoding to be same as terminal?

It would be nice if we could change the encoding

Could anyone answer the question?


new domain

New domain

@berlusvictius Please provide us with:

the school official website URL
the school street address, including city and country
an URL of a page on the official website where the school offers an IT-related long-term (>1 year) course
a proof, which shows that the school recognizes the domain you are submitting as an official email domain for the students.

You can provide us with any of the following as the proof:

A copy of instruction (a hard-copy or electronic one) given to you by the school that tells you to use an email address in this email domain
An URL of a page at the official school website that says that students use this email domain
A reference to a recognized journal where an article was published by someone from the school, with explicit affiliation to the school, and e-mail address from the email domain
A WHOIS data that link the email domain to the school somehow
A copy of official letter from the school representative saying that the school provides e-mail addresses in this domain to the students
Anything else that can prove this fact in similar way, i.e. can be verified independently.

@berlusvictius You might miss my previous comment. Please react.

@berlusvictius I am sorry, this request remains unanswered for a while. I have to close it without merging. Please reopen and comment if you have an update regarding the aforementioned issue. Thank you for your understanding!


Configure word wrapping on Markdown editor

Problem
Long lines in the markdown editor when PMs are entering the report scroll the editor to the right, for simplicity we want to configure both the editor and preview to wrap lines.
Solution

[ ] Configure the editor to wrap lines
[ ] Configure the markdown preview with CSS so the text wraps

https://microsoft.github.io/monaco-editor/typedoc/variables/editor.EditorOptions.html


Changed to external CLA service

 You should sign our Contributor License Agreement in order to get your pull request merged.


Could not find a suitable toolset under conda

Boost seems to have a unique way of identifying toolsets which does not integrate well with Conda's model of installing and providing a compiler. In essence the problem is that Conda's compilers have a path such as /opt/conda/bin/x86_64-conda-linux-gnu-gcc, so the binary gcc or g++ is not on the $PATH. However, Conda correctly sets the $CC and $CXX etc variables which most build systems are able to detect. However due to the way that bootstrap.sh and build.sh seem to work, this is ignored, and instead a user will receive Could not find a suitable toolset.
I think it would be great to think about how Boost could support a workflow such as this.
Example
Below is a reproducible example. It runs in docker or podman because this is the easiest way to demonstrate a system that has no system gcc but also has conda pre-installed. I use [...] to indicate omitted output for brevity.
$ podman run -it continuumio/miniconda3 bash
$ which gcc
$ echo $CC
$ echo $CXX

At this point note that we have no system compiler installed at all. This is important for demonstration.
$ conda install -c conda-forge gcc_linux-64=10.4.0 gxx_linux-64=10.4.0 cmake=3.26.3 make=4.3
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Collecting package metadata (repodata.json): done
Solving environment: done
[...]
$ which gcc
$ echo $CC
/opt/conda/bin/x86_64-conda-linux-gnu-cc
$ echo $CXX
/opt/conda/bin/x86_64-conda-linux-gnu-c++

Now that we have installed a compiler via conda, note that $CC and $CXX are set, but that there is no gcc in the PATH.
$ cd /root
$ wget https://boostorg.jfrog.io/artifactory/main/release/1.82.0/source/boost_1_82_0.tar.gz
--2023-05-04 00:54:07--  https://boostorg.jfrog.io/artifactory/main/release/1.82.0/source/boost_1_82_0.tar.gz
Resolving boostorg.jfrog.io (boostorg.jfrog.io)... <IP_ADDRESS>, <IP_ADDRESS>, <IP_ADDRESS>, ...
Connecting to boostorg.jfrog.io (boostorg.jfrog.io)|<IP_ADDRESS>|:443... connected.
HTTP request sent, awaiting response... 302
[...]
$ tar xzf boost_1_82_0.tar.gz
$ cd boost_1_82_0
$ ./bootstrap.sh
Could not find a suitable toolset.

You can specify the toolset as the argument, i.e.:
    ./build.sh [options] gcc
[...]
$ ./bootstrap.sh --with-toolset=gcc
Building B2 engine..

A C++11 capable compiler is required for building the B2 engine.
Toolset 'gcc' does not appear to support C++11.

> g++ -x c++ -std=c++11  check_cxx11.cpp
./tools/build/src/engine/build.sh: 120: g++: not found
> g++ -x c++ -std=c++11 -D_GNU_SOURCE  check_cxx11.cpp
./tools/build/src/engine/build.sh: 120: g++: not found
> g++ -x c++ -std=c++11 -pthread  check_cxx11.cpp
./tools/build/src/engine/build.sh: 120: g++: not found
[...]

Note also that conda has to patch Boost to resolve this issue: https://github.com/conda-forge/boost-feedstock/blob/main/recipe/5eff1ecc8413b0dc93a1ab047d7fed751e6cb40e.patch.
Although this is sufficient for installing Boost via conda, it doesn't resolve the use case I'm encountering, where a third party script tries to install Boost from source inside a conda environment, but without using conda to do the installation.


Use ByteBuffer for RESPValue data storage

From the proposal discussion thread: https://forums.swift.org/t/discussion-nioredis-nio-based-redis-driver/22455/11
Change
public enum RESPValue {
    case .simpleString(String)
    case .bulkString([UInt8])
}

to
public enum RESPValue {
    case .simpleString(ByteBuffer)
    case .bulkString(ByteBuffer?)
}```

Big +1 to this. ByteBuffer slices are much cheaper to create than copying the bytes out into a String or Array<UInt8>. If the resulting data is ignored or discarded, then the copy doesn't need to take place at all which is a huge win.


Provide alternative formats for bulk download

Hey! This is the only complete data source I've been able to find regarding legislators and all their information (NYTimes API comes close but doesn't provide contact info). I typically work in the .NET environment so we have a ton of great JSON deserializers.
It's a bit of a handful and a lot of extra hassle to transform these YAML documents into a strongly-typed model... I would love if you provided multiple formats for these documents, like JSON or XML; something that's a bit easier to deserialize.
I plan to use GH's API to periodically check when these are updated to grab the latest and download them to an offline cache. I do my own parsing and converting using YamlDotNet but I still need to create intermediate objects to transform the YAML into a nicer object graph.

Closing due to inactivity.

I am still interested in having support for JSON-LD.

See #257 (your issue).


MRG: rebased mmio refactoring

Rebased mmio refactoring by Joscha Reimer, in
https://github.com/scipy/scipy/pull/4875.
Added a couple of small refactorings on top.

@jor- reviewed, tiny formatting changes added to reviewed PR at #4875 - merging.

@matthew-brett thanks for rebasing.


Esp32-WROVER Unable to include the header file esp32-pinctrl.h

Description:
I was trying to build for esp32 WROVER and getting the following error:
zephyr/boards/xtensa/esp_wrover_kit/esp_wrover_kit-pinctrl.dtsi:8:10: fatal error: dt-bindings/pinctrl/esp32-pinctrl.h: No such file or directory
    8 | #include <dt-bindings/pinctrl/esp32-pinctrl.h>
      |          ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.

I checked the repository 3.2.0, in both zephyr/boards/xtensa/esp_wrover_kit/esp_wrover_kit.dts and zephyr\dts\xtensa\espressif\esp32.dtsi. The header file esp32-pinctrl.h is included. But in the folder zephyr\include\zephyr\dt-bindings\pinctrl. The header file does not exist

Windows 10 Pro version 21H2
I tried to use #include <dt-bindings/pinctrl/esp-pinctrl-common.h> instead of using the missing header but getting the following error

CMake Error at C:/ncs/v2.1.1/zephyr/cmake/modules/dts.cmake:230 (message):
 gen_defines.py failed with return code: 1

@r0n9Y I am not able no reproduce the issue. Have you run west update as well? Which sample code you have been using for that?


Unable to restore down window size

Issue Type: Bug
After I maximum the window size, the "maximum" button still remain there instead of become a "restore down" button
VS Code version: Code 1.40.0 (86405ea23e3937316009fc27c9361deee66ffbf5, 2019-11-06T17:02:13.381Z)
OS version: Windows_NT x64 10.0.18362

dup of https://github.com/microsoft/vscode/issues/84343

Just double click the title bar, the maximum button would become a restore button and then you can't resize the window by dragging the edges.


Implementing the call for proposal process.

We would begin the work of ensuring that people can submit proposals. This would include

[ ] Removing the sections on the home page that have nothing to do with submitting proposals

[ ] Implementing the designs of the Dashboard pages and ensuring that the current style guides are been used

[ ]  Deploying

For access to a db dump, this should be located https://github.com/orgs/pyung/teams/development-team/discussions/1

The work on this feature would be implemented in the following branch cfp

@danidee10 I would use this branch to do the conversion of the templates, and would be replacing step by step.

With the content from the dump, we would see how we can hook up the new design  templates.

@gbozee  Is there any design that will imported at invisionapp.com to follow or Is just inspiration from the last conference site...

I would come up with a sample. we would be following the inspiration from last conference

OK... Noted..

Has anyone been able to get the change form in the admin to display?
Here is what i mean?

In my dev environment, when i try opeining any change form, it gets stuck loading.

this is the error i get from the logs

I have been able to solve the above. Had to pin down the django version to v1.10.8.
A list of the pages and where to find content for them for the call for proposal launch would be gotten from https://us.pycon.org/2018
I have also moved the design folder to the `static directory of the python_nigeria folder.
The following pages are paramount for the successful launch of this page.
https://us.pycon.org/2018/about/staff/
https://us.pycon.org/2018/about/diversity/
https://us.pycon.org/2018/about/code-of-conduct/
https://us.pycon.org/2018/speaking/recording/
https://us.pycon.org/2018/speaking/tutorials/
https://us.pycon.org/2018/speaking/posters/
https://us.pycon.org/2018/speaking/talks/
https://us.pycon.org/2018/speaking/
Take a look at the cfp branch. this is where effort would be directed at now.

@shante66  Please take a look at the links i pasted above and confirm if they would be relevant.
@aanaedu @danidee10 @depecode
@depecode i added a cfp.html to the design folder which shows just the section that needs to be used. It is similar to the home page with some info missing.
I would also create another issue to track deployment of the site to a staging server so that we can keep track of what needs to be done and what has been done so far.
@pyung/development-team Work has started and we are under some form of deadlines.

Just deployed a working staging url http://staging.pycon.ng:8008/
@danidee10 since you are the only one that offered to also work on infrastructure, reach out to me on slack for the staging server password.

@gbozeeI totally forgot. The Conference change form worked on my system with Django 1.9.9. Maybe it's a windows issue or something on your system.
It still works on 1.10

I tried uploading to 1.11 but it failed. I guess we are stuck with 1.10

@gbozee not all those pages are relevant, trying to keep things as simple as possible. I would say organizers (which they call staff), code of conduct, Tutorial,Talks, and speaking are the relevant ones.
https://us.pycon.org/2018/about/staff/
https://us.pycon.org/2018/about/code-of-conduct/
https://us.pycon.org/2018/speaking/tutorials/
https://us.pycon.org/2018/speaking/
https://us.pycon.org/2018/speaking/talks/
I think the recording part should be covered when people submit their proposal, they have to tick the I agree box allowing us to publish the recording and slides

Alright. @depecode this is the step you need to take to ensure you always have access to the latest repo.
Right now if you run git remote -v  you should see only one repo which in your case should look like this
origin   git@github.com:gbozee/pyconng.git (fetch)
origin   git@github.com:gbozee/pyconng.git (push) # your repo name in this case

So as far as your git installation is concerned, origin means your own local remote fork. But there is a chance that your local fork is out of date. so you need to ensure you also have a link to the pyung repo since you can be guaranteed anytime that that would always be up to date.
 It should get all the available branches  locally which you can then switch to.

Thanks @ gbozee

@shante66 are those the only links, this is what it would look like oo

I just added the designs for all the relevant internal pages
They are

dashboard
speaker edit page
proposal create page
propodal speaker page
sponsor register page
review pages
staff pages

I also moved the design folder to the static directory so that it would be easier to reference the static files directly from django templates.
The next phase is to start replacing the different parts of these templates with the designs

There is also a trello board https://trello.com/b/5hxWIRoD/pycon-nigeria to track the tasks that are been worked on and the big picture. If you can't view it, send me a message on slack to add you

@gbozee this is still in the beginning right for people signing up and for accepting proposals right? Internal pages. the final site would have sponsors, programme, Venue, Travel and accomodation,   with some of the listed sub categories

I just hooked up all the functional pages required for CFP a561d550c740966a88d4ae95b6e30f2017413c57.
A working link can be found here. http://ci.tuteria.com:8001.
What is remaining are as follows.

[  ] Mobile design is kinda messed up

[  ] Ability to become a sponsor even after registering as a regular user

[  ] Preparing for deployment. Automating the deploy process and all devops activities.

@depecode if you have got git bash please use that and create this file in the root of the project with the following
startup.sh
export DATABASE_URL=postgres://<username>:<password>@localhost:5432/pyconnigeria
export DJANGO_SETTINGS_MODULE=config.settings.local

where username is the username of your postgres instance. i believe the default on windows is postgres
and password is whatever password was set. I think the default is postgres but i might be wrong.

Thanks @gbozee  The steps works....

So currently preparing for production, latest working url is at staging.pycon.ng:8005.
We would be making sections of the django site editable from the admin.
some of them are

[ ] Footer section across all pages
[ ]  Creating the sponsors page and styling it like the coc page
[ ] Creating the speaker page and styling it like the coc page
[ ] setting up an automated script for deployment
[ ] setting up https in production environment
[ ] Implementing automated backups


Icons

Use icons on the website. See icons and type article for some visual tips.
Use icomoon or ionicons. Icons ftw :balloon:!

Used icomoon, see #18 and #26.


split approve and migrate into two actions

seems we'd want to use the existing approval component so that the UI is consistent.


Add l-moving-marker component

Im trying to add https://github.com/LouisMazel/vue2-leaflet-movingmarker to the library, How can I add this as a plugin to the library?
What I did is I installed it then added import LMovingMarker from 'vue2-leaflet-movingmarker'  to my leaflef plugin in nuxt plugins folder and adding Vue.component('l-moving-marker', LMovingMarker);  at the  end , but when leaflet map opens it throws error that did you register the component properly.
// leafletmap plugin.js for nuxt
import Vue from 'vue';
import {LMap, LTileLayer, LMarker , LIconDefault, LPopup} from 'vue2-leaflet';
import {VGeosearch} from 'vue2-leaflet-geosearch';
import LMovingMarker from 'vue2-leaflet-movingmarker'
import L from 'leaflet';
delete L.Icon.Default.prototype._getIconUrl;

L.Icon.Default.mergeOptions({
  iconRetinaUrl: require('leaflet/dist/images/marker-icon-2x.png'),
  iconUrl: require('leaflet/dist/images/marker-icon.png'),
  shadowUrl: require('leaflet/dist/images/marker-shadow.png')
})

Vue.component('l-map', LMap);
Vue.component('l-tilelayer', LTileLayer);
Vue.component('l-marker', LMarker);
Vue.component('l-popup', LPopup);
Vue.component('l-icon-default', LIconDefault);
Vue.component('v-geosearch', VGeosearch);
Vue.component('l-moving-marker', LMovingMarker);

thanks for any help

So everything works perfectly until you had those both lines:
import LMovingMarker from 'vue2-leaflet-movingmarker'
...
Vue.component('l-moving-marker', LMovingMarker);

Is that right?

Tnx for coming back to me.well everything works, but I still dont see the l-moving-marker  and I get the did u register the component correctly or not but I do have the map

No I didnt contact the author which I will, thought u might have some insights or maybe you did it already.
thanks anyway


Check function: writeCovariateDataAndromedaToCsv

Function documentation in order with SRS (Roxygen2)
Functionality in order with function documentation
Unit test in order with TestPlan (usethis, testthat)
Code review of function (other dev than whoever picked up this ticket) (lintr)

Function does not exists anymore within CohortDiagnostics.
Could maybe use:
CohortDiagnostics:::writeToCsv

Function is deperecated


App under the 64 - bit system can not use this tool?

python appmon.py -p android -s scripts/Android -a com.xx.account
[ERROR] unable to handle 64-bit processes due to build configuration
Traceback (most recent call last):
File "appmon.py", line 264, in init_session
session = device.attach(app_name)
File "/usr/local/lib/python2.7/dist-packages/frida/core.py", line 96, in attach
return Session(self._impl.attach(self._pid_of(target)))
NotSupportedError: unable to handle 64-bit processes due to build configuration
^CTraceback (most recent call last):
File "appmon.py", line 305, in
script.unload()
NameError: name 'script' is not defined

Hello,
For which system do you speak about? Your desktop or arm64?
If it's for arm64 you have to take the proper version of frida-server  here

Thanks @max01203


docs, proposals: Kiagnose as an operator with mutli checkups CRDs

A design proposal to transform Kiagnose to Kubernetes operator and transition to using dedicated checkup CRD and controller for each type of checkup.
Rendered doc https://github.com/ormergi/kiagnose/blob/c4367bd20e0a328b3abbb2169165070fc28d05be/docs/proposals/kiagnose-operator-multi-checkups-crds.md
Signed-off-by: Or Mergi<EMAIL_ADDRESS>

A decision has been taken to not proceed with any operator based solution.
We should revisit this and the other suggestions when the need will be raised .


Reseting state to a different file

I'm currently crashing due to the error malloc_consolidate(): invalid chunk size and after looking through valgrind and doing some print debugging, I suspect that resetting the yasl state to a different script is causing the mismatch due to this part here.
==23676==  Address 0x18ed3bb6 is 134 bytes inside a block of size 315 free'd
==23676==    at 0x4839A0C: free (vg_replace_malloc.c:540)
==23676==    by 0x432C9A: YASL_resetstate (yasl.c:73)
==23676==    by 0x414FCD: BackgroundWorker::doWork(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >) (backgroundworker.cpp:304)
.....
==23676==  Block was alloc'd at
==23676==    at 0x483880B: malloc (vg_replace_malloc.c:309)
==23676==    by 0x4357A1: return_bytes (compiler.c:316)
==23676==    by 0x435924: compile (compiler.c:340)
==23676==    by 0x433146: YASL_execute (yasl.c:137)
==23676==    by 0x4136D9: AtomicState::AtomicState() (atomicstate.cpp:37)
.....

I don't know the contents of what is being freed (the init doesn't really do anything but create empty objects to set. But some buffer being allocated for the first script is having a problem being freed at the second

I was able to isolate the error to a small set of files.
main.cpp:
int main(int argc, char** argv) {
        YASL_State* S = YASL_newstate("test.yasl");
        YASL_execute(S);

        YASL_resetstate(S, "echo.yasl");
        YASL_execute(S);

        YASL_delstate(S);

        return 0;
}

test.yasl:
const $ = {}

echo.yasl:
echo $

this seems to be fixed?


get_messages on 0.9.3 not working properly

Hi guys,
We found an issue with version 0.9.3 of kafka-python (installed via pip). The following code would always get only one message:
c = KafkaClient(address)
cons = SimpleConsumer(c, group, topic)
messages = cons.get_messages(100) # Trying to get the last 100 messages
print "len", len(messages) # Always print "1"

However, the same code works OK with version 0.9.2.

I cannot reproduce. I am also using version 0.9.3 installed via pip. I uninstalled and reinstalled, but still can't reproduce.

I made tests and results that number of messages is also limited by the buffer_size. count parameter does not force to get that number of messages. It is just the maximal count, but actually buffer_size has precedence on messages retrieved count.

@bertinatto Can you give more info on what you are seeing here?  I just tested and 0.9.3 is working fine for me.  Are you sure you don't have a consumer committing as messages are coming in so that you are only seeing one at a time?

I can reproduce it with the following code (kafka-python 0.9.3):
>>> prod = KeyedProducer(c)
>>> for i in range(1000):
...     prod.send("test-topic", "KEY%i" % i, ("Data%i" % i) * 1000)
...
[ProduceResponse(topic='test-topic', partition=0, error=0, offset=0)]
[ProduceResponse(topic='test-topic', partition=0, error=0, offset=1)]
...
[ProduceResponse(topic='test-topic', partition=0, error=0, offset=999)]
>>> up = 10000000
>>> cons = SimpleConsumer(c, 'test-group', 'test-topic',
fetch_size_bytes=up, buffer_size=up, max_buffer_size=up)  # set large enough buffer & fetch size
>>> cons.pending()
1000
>>> msgs = cons.get_messages(100)
>>> len(msgs)  # each time for the first request it gets only one message, why?
1
>>> msgs = cons.get_messages(100)
>>> len(msgs)  # for next requests it works well
100

Also it seems that it's related with message length, it works fine with "Data%i" % i message values.

I suspect this is a timeout issue.  Can you try passing a timeout kwarg to the get_messages call?  The fetch phase probably takes longer than the default 0.1 sec timeout, which forces a return with only 1 message.  See http://kafka-python.readthedocs.org/en/latest/apidoc/kafka.consumer.html#kafka.consumer.simple.SimpleConsumer.get_messages for docs on the params.

@dpkp It's probably related with the fetch phase, but only with the initial fetch phase for the first message. Anyway timeout kwarg doesn't work, the behavior is the same even with timeout=100. I emphasize that it's only for large messages, and only for the first get_messages call. I'll try to investigate it later if I have some time.

KafkaClient processes FetchRequests in serial, which means that it will query each broker individually before moving to the next. It is possible that the first partition/broker queried does not have sufficient messages to respond to the request and triggers the request timeout. The only way I can think of to address this situation is to rewrite the client module to handle parallel broker requests.

Not planning to do any further work on SimpleConsumer -- it is deprecated in favor of KafkaConsumer, which has the same interface as the mainline java client (no get_messages).


Feature Request: Adding Support for Meter in the Eve App

Problem
No response
Solution
It is possible to get Stats of the Temperature and the Humidy in the Eve App. It would be cool if this could be added.
Alternatives
No response
Additional context
No response

I will look into it.


[Snyk] Security upgrade sentry-rails from 5.18.1 to 5.18.2

This PR was automatically created by Snyk using the credentials of a real user.![snyk-top-banner](https://github.com/andygongea/OWASP-Benchmark/assets/818805/c518c423-16fe-447e-b67f-ad5a49b5d123)
Snyk has created this PR to fix 1 vulnerabilities in the rubygems dependencies of this project.
Snyk changed the following file(s):

Gemfile

⚠ Warning
```
Failed to update the Gemfile.lock, please update manually before merging.
```

Vulnerabilities that will be fixed with an upgrade:

Issue
Score

Web Cache Poisoning SNYK-RUBY-RACK-1061917
  616

[!IMPORTANT]

Check the changes in this PR to ensure they won't cause issues with your project.
Max score is 1000. Note that the real score may have changed since the PR was raised.
This PR was automatically created by Snyk using the credentials of a real user.

Note: You are seeing this because you or someone else with access to this repository has authorized Snyk to open fix PRs.
For more information:
🧐 View latest project report
📜 Customise PR templates
🛠 Adjust project settings
📚 Read about Snyk's upgrade logic

Learn how to fix vulnerabilities with free interactive lessons:
🦉 Learn about vulnerability in an interactive lesson of Snyk Learn.

Closing as this PR is broken as always with Snyk, and Dependabot already fixed this.


Can't Render SVG

I've tried without success:
proc createDom(): VNode =
  result = buildHtml(tdiv):
    svg(width = "100", height="100"):
      circle(cx="50", cy="50", r="40", stroke="green", stroke-width="4", fill="yellow")
      text "Doesn't Support SVG"

Everything compiles fine with no errors amd I can see the Element in the Browser developer mode, but the image doesn't render and I see the text. On on the latest version of Chrome.

This seems to work:
tdiv:
  verbatim """<svg width=100 height=100>
                        <circle cx=50 cy=50 r=40 stroke=green stroke-width=4 fill=yellow />
                      </svg>"""

This seems to work:
tdiv:
  verbatim """<svg width=100 height=100>
                        <circle cx=50 cy=50 r=40 stroke=green stroke-width=4 fill=yellow />
                      </svg>"""

Same with firefox

So the problem is empty tags, browser prefer self closing tags in that case.

I have found this issue to also affect rendering gifs.

SVG support added in #271


generalization from andrew's sgx

I'm making this PR just to document changes I needed for this to validate the certificates generated on my local SGX machine. I don't think these should be taken as-is, probably a better way than adding one new thing at a time!

Checking further, this PCK_ISSUER_NAME  in PEMCertChainLib is a fair issue. In the PCK Cert CRL reference (pdf) the field should be either <Intel SGX PCK Platform CA | Intel SGX PCK Processor CA>. Right now exactly Platform must be matched, i just notice because my setup is producing Processor. Modified the pull request to deal with just this issue so it's actionable

hey @amiller , thanks for the PR. we've made the changes in #3 DEV2678 and it has been merged so we'll be closing this.
thanks so much again.


Download entire albam

Enhancement - Easy way to download entire album or list all the files from the album so one can download in sequence

Humm, seems interesting. Will add album feature soon after that possibly do that.


Fix the deployment error of sleep-vault.yaml

This PR is to fix the issue: https://github.com/istio/istio/issues/16604
[ ] Configuration Infrastructure
[ x] Docs
[ ] Installation
[ ] Networking
[ ] Performance and Scalability
[ ] Policies and Telemetry
[ x] Security
[ ] Test and Release
[ ] User Experience
[ ] Developer Infrastructure

@lei-tang It looks like this needs to be backported. Please comment /cherrypick release-1.3.

/cherrypick release-1.3

@rlenglet Done: I have commented "/cherrypick release-1.3".

ping @istio/wg-docs-maintainers this is a blocker

In response to a cherrypick label: new pull request created: #16884


vesktop: add libpipewire for audio sharing

Description of changes
Links against (I think this is the right term?) libpipewire, needed for desktop audio sharing.
Things done
For testing, I shared my screen with audio successfully yesterday, it worked without any problems for the whole time, which was some hours.

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

[ ] 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
[X] 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

[ ] Fits CONTRIBUTING.md.

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

Hmmm, it did not work. Maybe I did something wrong? I'll try to reproduce it again this week when I have the time, and then I'll come back at this PR.

Yeah, just tested this again, this time with an updated nixpkgs. I probably just had an old nixpkgs and opened a PR instead of updating :sweat_smile:...
Sorry for the inconvenience.

no worries! thanks so much for trying to help out :)


content is undefined when extending template using class syntax

Description

this.content is undefined when extending template using class syntax
Live Demo

http://jsbin.com/debihucuha/2/edit?html,console,output
Steps to Reproduce

Create custom element that extends template using ES6 Class syntax
Check content property on element

Expected Results

Should return document-fragment of template
Actual Results

Returns undefined
Browsers Affected

[x] Chrome
[x] Firefox
[ ] Edge
[ ] Safari 9
[ ] Safari 8
[ ] IE 11

Versions

Polymer: v1.4.0
webcomponents: v0.7.21

This isn't supported yet, but we are considering it for the inheritance implementation.

@azakus is this only for extending template or others as well? Also - where's the best place to keep track of the inheritance implementation? Thanks


Add collaborators to this repo

Comment below to be added as a collaborator
We will all be using this repository today. Even though it's public right now, you will not be able to make changes until you're given the correct permissions. We've automated this process via the GitHub API. Once you comment, we will add you as a collaborator.
You'll start to receive a lot of emails. (❗) You can slow these down immediately by clicking the Unwatch button at the top of the page and selecting either the Participating and @mentions or Ignore option.

Hello!

Hi Emily, ready to learn.

Hi Everyone

Hello

Hi

Hello!

Hello!

test

Halo

Following Emily's instructions to add a comment.

Hello!

test

This is Dale

comment

hello


Add new shouldExecute method to prevent a migration or seeder from being executed

The company I work for uses Phinx and we are pleased with it. However what's currently stopping us from using it in production is not being able to run migrations in two steps, before and after deployment.
This is an issue that's been raised several times already, in #529, #1044, #1619 and #1824
I started using my own implementation of AbstractMigration and creating a custom template, but I realized that there was a key feature that I was missing if I did not want to wrap all my code in big if conditions in all my migrations: a way to stop the migrations from being executed at the Manager level, before it inserts data in phinxlog. This was rightly suggested here: https://github.com/cakephp/phinx/issues/1619#issuecomment-578732670
Even with if conditions as mentioned in #1619, the migration would still be recorded in the database and not tried again. What I needed was a way to make sure it would only be executed when the shouldExecute method returns true.
As I implemented it, a custom AbstractMigration implementation can override shouldExecute and perform any logic it wants to determine if the migration should run.
If not, it displays "skipped" in the console and stops there.
I was toying with the idea of changing how preFlightCheck works, and making it return a boolean and execute the migrations or not based on that, but it would break its existing behaviour, and I was not sure what to do with postFlightCheck, resulting in an inconsistency between the two methods.
While I was at it, I also refactored the console status message display to use a common method to display all the similar migration/seed status messages.
I believe this method would provide a simple, implementation agnostic solution for pre/post deployments and possibly other uses such as determining if a migration should run based on migration attributes, time, tags, environment, etc.
Please let me know if you have any comments! Thank you :)

Does this also make https://github.com/cakephp/phinx/pull/1926 hook not necessary?

If I'm not mistaken #1926 is about seeds. But yes I could add the same check in the seed function to keep it consistent

Given that we chance interface contracts, we also should put this into 0.13 (.next) branch as target

This MR is now targeting 0.next and I applied the changes to Seeders.
stickler-ci complains about migrations but I guess it should ignore the namespaces there since most migrations do not have a namespace?

Then, about #1926 or even the pre/post deployment requests. I was thinking this would enable us to maybe use traits that define a specific behaviour for shouldExecute. For example, I think your use case could done as follows:
trait SeedOnce
{
    /**
     * @param string $tableName Table name.
     *
     * @return bool
     */
    public function hasData(string $tableName): bool
    {
        $table = $this->getAdapter()->quoteTableName($tableName);
        $countQuery = $this->getAdapter()->query('SELECT COUNT(*) as count FROM ' . $table);
        $res = $countQuery->fetchAll();

        return $res[0]['count'] > 0;
    }

    /**
     * Checks to see if the seed should be executed.
     *
     * Returns true by default.
     *
     * You can use this to prevent a seed from executing.
     *
     * @return bool
     */
    public function shouldExecute()
    {
        return !$this->hasData($this->seedOnceTable);
    }
}

class CustomSeeder extends AbstractSeeder
{
    use SeedOnce;

    $seedOnceTable = 'posts';
}

I know traits often do not have a good reputation but in this case I think they could be handy :)

It is even fine to just have the trait add the hasData() convenience method
Having to code
public function shouldExecute()
{
    return !$this->hasData($this->seedOnceTable);
}

is still not too much work :)

You're right. However, using it as a trait (that could be bundled here) means that we do not have to add the hasData function to the AbstractSeeder and only have it when necessary.

Hello, I wonder if there are any modifications that should be made before it can be merged to the next branch?

Hello, I don't want to overstep but do we have an idea as to when it could be merged?

I'm fine with this, as it provides a nice generic abstraction over what #1926 was doing that works for both migrations and seeds.

Thanks a lot!


Update README.md

Fix typo

Coverage remained the same at 97.717% when pulling a420f4b7c578ac15947d92e233056462b5e837d8 on loongmxbt:patch-1 into 5c172b686ebe4960d2cff5f583c356f0476fc810 on nietaki:master.


[WIP] Improvements to get higher pana score

07.03.23: 110/130 Pana score

10 Points: The package has a git dependency
10 Points: The constraint 0.17.0 intl does not support the stable version 0.18.0

I used the last Flutter 3.7.6, but flutter_localizations package is still depends on intl 0.17.0


Fix wekzeug 1.0 compatibility

werkzeug.contrib.cache was moved to https://github.com/pallets/cachelib since version 1.0

Any update on when this will be merged @SqrtMinusOne ? Thanks!

I have no idea; addressing that to @fengsp.
As for now, as the module isn't complicated, I'd suggest taking the parts you need.

FYI: I encounter same problem, and I fixed it in my fork, and you can install it in this way.

Had the issue causing this PR. Can confirm this PR update fixed the issue for me when manually updating flask_session/sessions.py

@m1waterman88  Would you mind also try out pip install<EMAIL_ADDRESS>to see if it can fix the issue for you WITHOUT needing to manually update the file?

@m1waterman88 Would you mind also try out pip install<EMAIL_ADDRESS>to see if it can fix the issue for you WITHOUT needing to manually update the file?

Since you made the same code change that this PR request has (and thus that I have), yes, it would fix it.

pip install<EMAIL_ADDRESS>
I can confirm this fixed it for me too.

I've reached out to to repo owner twice via email in addition to any actions in the Flask-Session repo, and I haven't received a reply. Between the lack of response and the last commit occurring on Feb 9, 2017, unfortunately I think this repo has been abandoned.

@m1waterman88 I hate it when this happens. Great software gets abandoned at some point and is turning into waste over time. What are our alternatives for flask-session?

@fengsp, please provide write access so we can keep this repo going. Many use it and would like to continue to do so.

We can fork it, sure, but it's easier for projects already routing to this repo to continue to do so.
Thanks.

@m1waterman88 I hate it when this happens. Great software gets abandoned at some point and is turning into waste over time. What are our alternatives for flask-session?

If write access isn't granted, I'll do what I just did with flask-snippets for Atom today:
fork it (flask-snips), make necessary changes, and push the package to atom.io. Then monitor, maintain, and add features.
Except pypi for flask-session rather than atom.io so it can be used with standard pip commands.

 :-D  Please release this into 0.3.2 soon!

😱


web: use TypeScript for log app

Mostly just putting a bunch of any types in places unless a better typt was obvious. We can fill them in later, or not at all.
@nicks if you think this will be more trouble than it's worth, that's fine by me and I'll close this PR. As a JavaScript foreigner I like the types safety blanket but I can live without it.
Also create-react-app makes this so easy! 🎉

huh, somehow my package.json changes didn't make it in to this commit. One moment.

i think a little bit of tooling work is fine; as long as we're not spending a large % of the eng effort on it this cycle.


qwen model selected and api_key inputted, but always got state model is openai

on my M2 MPS, I successfully started the server, but the state model is always openai rather than Qwen which I selected and key inputted

Thank you for your feedback! We will look into this problem:)


Large Data Warnings

Description of PR
This PR adds data warnings for when users pick large amounts of data that will take long periods to run operations.
Summary of changes and related issue
Relevant motivation and context
Dependencies required for this change?
Fixes # (issue), delete if not necessary
Type of change

[ ] Bug fix (non-breaking change which fixes an issue)
[x] New feature (non-breaking change which adds functionality)
[ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
[ ] This change requires a documentation update

How Has This Been Tested?
Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce.

[ ] Test A
[ ] Test B

Checklist:

[ ] My code follows the style guidelines of this project
[ ] I have performed a self-review of my code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[ ] My changes generate no new warnings
[ ] I have added tests that prove my fix is effective or that my feature works
[ ] New and existing unit tests pass locally with my changes
[ ] Any dependent changes have been merged and published in downstream modules

 Can't download big file

 Data Warning

Tested in getting_started on:

hourly air temp
all of CA
not area averaged
3km
historical + ssp370
Which rightfully returns the "huge" option. My preference is to modify the warning text in this case that it is prohibitively large and that operations may not work without further subsetting.

Otherwise, is there a way we can be more explicit? "Extra time" and "considerably more time" is somewhat vague

I made some ballpark guesses compared 1GB of data using ck.load times


Fix HashOperation.HMSET Cannot Set On Existing Data

When calling HMSET, the first initialization works as expectation, but second HMSET to initialized key just ignores the input.
And finally i found HashObject.SetOrNX() only targeted on HashOperation.HSET, so it ignores HMSET to existing data.
I think it needs to check both of HashOperation.

@microsoft-github-policy-service agree

@microsoft-github-policy-service agree


Update Gradle version to 4.2

Gradle 3.1, which was previously used, is incompatible with the latest
Kotlin. Updating to the latest Kotlin (1.1.50) would result in an
exception during configuration phase

All changes in this commit were done by the command
gradle wrapper --gradle-version 4.2


fix: Support multipart requests with type: array

Fixes #451 though perhaps a better "fix" would be to disallow multipart request bodies with type: array?

I'm still having the issue if I try to generate a client from this YAML (I've writted it manually and I'm not an OpenAPI expert so maybe there are conceptual mistakes):
NOTE: there is no type: array on multipart request body.
openapi: 3.0.2
info:
  title: ''
  version: ''
paths:
  /api/media/upload-file/:
    post:
      operationId: uploadFile
      requestBody:
        content:
          multipart/form-data:
            schema:
              properties:
                file:
                  type: string
                  format: binary
      responses:
        '200':
          content:
            application/json:
              schema:
                properties:
                  filename:
                    type: string
                    maxLength: 128
                required:
                - filename
          description: ''

@slamora Ok, this is a slightly different issue, and a more complicated one!
TLDR; if you add type: object under schema, all will work fine.
Your schema is valid, because type is not a mandatory keyword in JSONschema. This seems a bit strange to me, and I haven't  actually found an official source for it, but there's a long discussion here with pros and cons.
As it currently stands, your schema says: "this could be anything, but if it's an object, it must have these properties".
Unfortunately we don't have code to handle this case, so we just interpret this schema as simply "this could be anything" and ignore the properties (see relevant code below from properties/__init__.py). As you can imagine, modifying this behaviour would not be trivial.
    elif data.type == "object" or data.allOf:
        return build_model_property(
            data=data, name=name, schemas=schemas, required=required, parent_name=parent_name, config=config
        )
    elif not data.type:
        return (
            AnyProperty(
                name=name,
                required=required,
                nullable=False,
                default=None,
                python_name=utils.PythonIdentifier(value=name, prefix=config.field_prefix),
            ),
            schemas,
        )

TLDR; if you add type: object under schema, all will work fine.

Thanks @csymeonides-mf for your tip!
I guess that it's a very uncommon situation so the effort to support it doesn't compensate. As reminder, I've created this YAML by hand to be able to reproduce the issue so it's and edge case that AFAIK doesn't exist on a real environment.
IMHO, you can follow with the PR merge workflow.

Excellent, sounds like the major issue is solved here then! Thanks again for fixing this so quickly!


liveness & readiness probe for callback service

Checklist

[x] Test your changes as thoroughly as possible before you commit them. Preferably, automate your test by unit/integration tests.
[x] Make sure mvn -P integration-tests clean verify runs for the whole project and, if you touched any code for a service in the services folder, ensure it can be run with spring-boot:run

Description

Enable liveness and readiness probe for callback service on port 8081

hey @kilbphilippSAP if possible, can you also check on issue #318 - which is kind of related... but before we're enforcing this, we need to check with operations, if that's possible for their tools.


Added metadata for reporting

:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

SP-Framework/docfx.json
:white_check_mark:Succeeded

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.


Fit one full page to window & fit to window width.

Hello,
The "Fit page" functionality is very important for us since it is an essential part of any PDF Viewer.
Could you help us with it?

The PdfRenderer class has a ZoomMode property which either automatically fits the contents to the maximum age width or height. Can you have a look whether this is what you're looking for?

Yes, it's very similar to what I need, but "fit page" applies only after switching from one mode to another.
Which method should I use for applying "fit page" for the current page?

I'm not sure what you're looking for. Do you want to introduce something like a toolbar button that the user can press?

Yes, I want to use it for this button

That explains a lot. I'll have a look at this when I get the chance.

Please have a look at the demo application. It has two new buttons that do what you're looking for.

Yes, it works well. But there was a problem with FitHeight when the page is Landscape.

Could you please create a new issue for this? I didn't change the library
for those buttons and it probably also doesn't work if you set the mode of
the viewer to fitwidth.
On Mon, Jun 15, 2015, 14:40 InfSource<EMAIL_ADDRESS>wrote:

Yes, it works well. But there was a problem with FitHeight when the page
is Landscape.
—
Reply to this email directly or view it on GitHub
https://github.com/pvginkel/PdfiumViewer/issues/24#issuecomment-112050825
.

FitWidth works correctly. Similarly, it works in Acrobat Reader. http://myscreenshot.info/i/0006/265251434377821885379631358467.png

Thanks. I'll have a look at the issue when I have the chance.
On Mon, Jun 15, 2015, 16:21 InfSource<EMAIL_ADDRESS>wrote:

FitWidth works correctly. Similarly, it works in Acrobat Reader.
http://myscreenshot.info/i/0006/265251434377821885379631358467.png
—
Reply to this email directly or view it on GitHub
https://github.com/pvginkel/PdfiumViewer/issues/24#issuecomment-112087434
.


chef_gem resource installs gems into push-jobs' environment instead of Chef client's

@manderson26
The installation of push-jobs appends the push-jobs's embedded environment to the system's PATH environment variable.
C:\Users\vagrant>echo %path%
C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\OpenSSH\bin;C:\opscode\chef\bin;C:\opscode\pushy\bin;C:\opscode\pushy\embedded\bin;C:\opscode\pushy\embedded\lib\zeromq\bin

This causes Chef's embedded ruby and gem environment to mistakenly use the push-jobs' ruby and gem environment.
C:\Users\vagrant>c:\opscode\chef\embedded\bin\gem env
RubyGems Environment:
  - RUBYGEMS VERSION: 1.8.28
  - RUBY VERSION: 1.9.3 (2013-11-22 patchlevel 484) [i386-mingw32]
  - INSTALLATION DIRECTORY: C:/opscode/pushy/embedded/lib/ruby/gems/1.9.1
  - RUBY EXECUTABLE: C:/opscode/pushy/embedded/bin/ruby.exe
  - EXECUTABLE DIRECTORY: C:/opscode/pushy/embedded/bin
  - RUBYGEMS PLATFORMS:
    - ruby
    - x86-mingw32
  - GEM PATHS:
     - C:/opscode/pushy/embedded/lib/ruby/gems/1.9.1
     - C:/Users/vagrant/.gem/ruby/1.9.1
  - GEM CONFIGURATION:
     - :update_sources => true
     - :verbose => true
     - :benchmark => false
     - :backtrace => false
     - :bulk_threshold => 1000
  - REMOTE SOURCES:
     - http://rubygems.org/

The workaround I've come up with is to remove the push-jobs embedded paths from the PATH environment variable during the chef-client run. This only affects the environment variable as the chef-client sees it. It does not make a permanent change to the environment variable.
The following line can be put in either a recipe or in the node's client.rb file. If you put it in a recipe you need to make sure it comes before any chef_gem resources are declared.
ENV['PATH'] = ENV['PATH'].split(";").delete_if { |p| p.match(/pushy\\embedded/) }.join(';')

wrong repo and most likely better solved by getting push client fully integrated with chef-client.


Removing .babelrc file since Babel 6 no longer allow "blacklist" option

"blacklist" is deprecated in Babel 6.
Source: http://babeljs.io/blog/2015/10/29/6.0.0#opt-in-plugins

UglifyJS fails to compile with this error..
Module build failed: ReferenceError: [BABEL] C:\Dev\boss\boss\node_modules\parsleyjs\dist\parsley.js: Using removed Babel 5 option: C:\Dev\boss\boss\node_modules\parsleyjs\.babelrc.blacklist - Put the specific transforms you want in the plugins option

Thanks!

This broke the release, see #1159.
Reverted.

PS: A better fix that doesn't cause similar issues welcome.

My commit is too old, I can't even remember what was my issue at the time :)
Maybe we can try with an empty .babelrc file, instead of removing it. But I think an empty file is not a valid JSON file...

Same error here:
ERROR in ./~/parsleyjs/dist/parsley.js Module build failed: ReferenceError: [BABEL] /Users/user/Projects/project/node_modules/parsleyjs/dist/parsley.js: Using removed Babel 5 option: /Users/user/Projects/project/node_modules/parsleyjs/.babelrc.blacklist - Put the specific transforms you want in the `plugins` option
Think you should use the babel strict mode plugin for babel 6 support (http://babeljs.io/docs/plugins/transform-strict-mode/).


feat(Data/Nat/Squarefree): Add lemmas about the product of distinct factors of a squarefree Nat

These lemmas will be used to develop a basic theory of arithmetic functions $n \mapsto \prod_{p\mid n} f(p)$.

bors merge
Thanks!


krane: 2.3.4 → 2.4.0

Motivation for this change
Update to the latest version: https://github.com/Shopify/krane/releases/tag/v2.4.0
Things done

Built on platform(s)

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

[ ] For non-Linux: Is sandbox = true set in nix.conf? (See Nix manual)
[ ] Tested, as applicable:

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

[ ] Tested compilation of all packages that depend on this change using nix-shell -p nixpkgs-review --run "nixpkgs-review rev HEAD". Note: all changes have to be committed, also see nixpkgs-review usage
[x] Tested basic functionality of all binary files (usually in ./result/bin/)
22.05 Release Notes (or backporting 21.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
[ ] (Release notes changes) Ran nixos/doc/manual/md-to-db.sh to update generated release notes

[x] Fits CONTRIBUTING.md.

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

1 package built:

krane


added required approvals workflow

Pull Request Functional Test Report for #3557 / 291ad56a89bdfee603cf268168d862c365619a03
No tests identified for validation.
Help

Pull Request Test Coverage Report for Build<PHONE_NUMBER>0
Details

0 of 0   changed or added relevant lines in 0 files are covered.
No unchanged relevant lines lost coverage.
Overall coverage remained the same at 55.268%

Totals

Change from base Build<PHONE_NUMBER>8:
0.0%

Covered Lines:
1983

Relevant Lines:
3588

💛  - Coveralls

Raised another PR - https://github.com/openconfig/featureprofiles/pull/3563


Hawkular-1208 Notification Mechanism

This new notification mechanism provides the agent-side solution to the Jira in question.
Add new "notification-dmr" meta-data that causes notifications to be sent to the server based on various inventory events.
-- Currently only "resource-added" is supported.
-- Uses services REST API

Marked as DoNotMerge until we can update to a server src dep.  A slight versioning game is unfortunately going to be needed here due to a circular dep.  Agent depends on server api, server depends on agent extension...  I suppose we could avoid this if we didn't depend on the new api jar and generated explicit JSON in the requests.  Something to consider, I guess.  Although as long as the api doesn't change we'll only have to play this game once.
Also, tests likely need to be added, not sure I can get that in place before PTO.
@jmazzitelli Please review.

to avoid circular dep, we should put API jars in https://github.com/hawkular/hawkular-commons somewhere.

Updated to use new commons hawkular-client-api jar to remove circular deps. Still marked as DNM due to commons snapshot dep and probabaly need to add an itest.

before we merge, @jshaughn needs to merge my PR to this PR to fix some things

I think this is ready to merge.


Add install instructions

Deploy preview for gestalt ready!
Built with commit a23ee95bce8e70ee175c516420781b17f71afc76
https://deploy-preview-252--gestalt.netlify.com

Warnings

:warning:

Please add a changelog.md entry for your changes.

  Generated by :no_entry_sign: dangerJS

Codecov Report

Merging #252 into master will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##           master     #252   +/-   ##
=======================================
  Coverage   70.73%   70.73%
=======================================
  Files          46       46
  Lines         820      820
  Branches      189      189
=======================================
  Hits          580      580
  Misses        169      169
  Partials       71       71

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 a94c29f...a23ee95. Read the comment docs.


Adopt junit-attachments

https://github.com/jenkinsci/junit-attachments-plugin (marked for adoption)
@abayer
@jglick
Description

Submitter checklist for adding or changing permissions

Always

[x] Add link to plugin/component Git repository in description above

For a newly hosted plugin only

[ ] Add link to resolved HOSTING issue in description above

For a new permissions file only

[ ] Make sure the file is created in permissions/ directory
[ ] artifactId (pom.xml) is used for name (permissions YAML file).
[ ] groupId / artifactId (pom.xml) are correctly represented in path (permissions YAML file)
[ ] Check that the file is named plugin-${artifactId}.yml for plugins

When adding new uploaders (this includes newly created permissions files)

[x] Make sure to @mention an existing maintainer to confirm the permissions request, if applicable
[x] Use the Jenkins community (LDAP) account name in the YAML file, not the GitHub account name
[x] Make sure to @mention the users being added so their GitHub account names are known if they require GitHub merge access (see below).
[x] All newly added users have logged in to Artifactory and Jira at least once

Reviewer checklist (not for requesters!)

[ ] Check this if newly added person also needs to be given merge permission to the GitHub repo (please @ the people/person with their GitHub username in this issue as well). If needed, it can be done using an IRC Bot command
[ ] Check that the $pluginId Developers team has Admin permissions while granting the access.
[ ] In the case of plugin adoption, ensure that the Jenkins Jira default assignee is either removed or changed to the new maintainer.
[ ] If security contacts are changed (this includes add/remove), ping the security officer (currently @Wadeck) in this pull request. If an email contact is changed, wait for approval from the security officer.

There are IRC Bot commands for it

Also posted to dev list : https://groups.google.com/g/jenkinsci-dev/c/-TK-eMrSlro

Fine I think, but is there anything in particular outstanding that warrants adoption?

Started to use the plugin on my fleet of Jenkins
Plugin is for adoption
Even if plugin has very low maintenance I just want to give some time to the community by keeping the plugin up-to-date and refreshed

If it doesn't justify an adoption I'm fine with it
Regards,


kernel:unregister_netdevice: waiting for lo to become free. Usage count = 1

Base ENV CentOS7
when I use "docker-compose build --build-arg "redis_version=4.0.1" redis-cluster" to build redis
the problem appear
“
Message from syslogd@localhost at Jul 29 20:03:22 ...
kernel:unregister_netdevice: waiting for lo to become free. Usage count = 1
”
How can i solve this problem？

@1456764506 I dont know. This seems to be a problem on your system and/or docker itself. It has nothing todo with this image or repo really. I suggest you have to search for help on dev.to, stackoverflow or google to find out a solution to your problem.


database/sql: few usable connections in connection pool after network packet loss event

Go version
go version go1.20.6 linux/amd64
What operating system and processor architecture are you using (go env)?
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/home/shipeng/.cache/go-build"
GOENV="/home/shipeng/.config/go/env"
GOEXE=""
GOEXPERIMENT=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GOMODCACHE="/pay/src/go/pkg/mod"
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/pay/src/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/usr/local/go"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/usr/local/go/pkg/tool/linux_amd64"
GOVCS=""
GOVERSION="go1.20.6"
GCCGO="gccgo"
GOAMD64="v1"
AR="ar"
CC="gcc"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/dev/null"
GOWORK=""
CGO_CFLAGS="-O2 -g"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-O2 -g"
CGO_FFLAGS="-O2 -g"
CGO_LDFLAGS="-O2 -g"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -Wl,--no-gc-sections -fmessage-length=0 -fdebug-prefix-map=/pay/tmp/go-build1095428125=/tmp/go-build -gno-record-gcc-switches"

What did you do?
We’re using pgx v4 as driver and database/sql as connection pool for client requests and database connections. Our server and database are in different regions, causing a 50 - 60 ms network latency. We're having an issue where our host can't recover and complete client queries in time, even after network recovered from prior packet loss events. Check this link to see how to reproduce the issue with script: https://github.com/spencer-x/go-database-sql-issue#ways-to-reproduce-the-issue-in-linux-machine.
What did you expect to see?
Service host should be able to serve requests within timeout limits after network recovers.
What did you see instead?
Even after the network between the host and the database recovered, client requests continued to timeout. The number of open connections reported from the connection pool stats was considerably higher (200) than the actual number of connections reported from the PostgreSQL database (20-30).
We tried to look into the issue and found that many connections were closed during the network packet loss event. Subsequently, even after the network was recovered, pgx continued to close the connection when clients canceled the query due to context timeout. The connection opener in database/sql rapidly increased the count of db.numOpen, but the opening of new connections was sequential and relatively slow. Consequently, there were few usable connections available from the connection pools.

The pgx driver returned database/sql/driver.ErrBadConn in ResetSession and many other places, so database/sql.DB knew the connection was closed.
To help further debug, I changed the variable scope in database/sql connection pool and printed them out.
 NumPendingOpenConn is cleared quickly with this change and the pool is recovered quickly after the packet loss event is canceled. I can help submit a PR if needed.

cc @kardianos


DASHBUILDE-91: Filter UI Controls

Includes a new displayer component "Selector" with three different subtypes: dropdown, label set & slider.
This first iteration cover most of the use cases regarding the filtering of dashboards.
@romartin @jhrcek Can you review please?
PS: A video preview showing progress => https://youtu.be/6PZoHo7sMaI

@jhrcek Added the changes you suggested.
jenkins retest this

@dgutierr I did the 2nd round of review and all the issues I found have been fixed except for one:
I can still reproduce the problem with slider displayer - when lower and upper limits are equal I'm getting values from some wider interval. Here is the video illustrating the issue
sliderIssue.zip with data from csv dataset as added to the previous jira

@jhrcek The latest issue you mention is also fixed.
I've also applied some fine tuning, specially in the dropdown & slider selectors as recommended by UXD team =>https://docs.google.com/document/d/1YawDcudXkCEq3uVh1h-J-xd_uyd8BROqSlUaWhrh9T4/edit#    Notice, the document introduces some advanced features which will be implemented in future versions.
A video showing the latest changes => https://issues.jboss.org/secure/attachment/12418440/dashbuilder_selectors_finetune.mp4
@romartin In my opinion, the PR is ready to merge.

I tested it locally and all the issues I found have been fixed. +1 to merge

Closed: 5666fa9af4a3c5bd8df9026053a610641797a1c5


V2

Resolved / Related Issues
Items resolved / related issues by this PR.

Closes #issue...
Related #issue...

Details of Changes
Add details of changes here.

Added...
Fixed...

Validation
How did you test these changes?

[ ] Built and ran the app
[ ] Tested the changes for accessibility

Screenshots (optional)
Add screenshots here.

@yaichenbaum please close it, that shouldn't be opened


where is the installer?

or do you have to compile it yourself?

Please read the install instructions on the main page. There is a link to the installer download.


Version 4 BC idea list

Hi all,
Basically I would like to share a list of v4 BC ideas I got. Mainly to get feedback and see what others think.

I would like to have custom tokens for all different types of usages of the following symbols.
: :

goto
alternative syntax control structure
before return type hint in function signature (T_TYPE_COLON, listed here for completeness)
named argument (CT::T_NAMED_ARGUMENT_COLON, listed here for completeness)
in use of switch-case

&:

pass by reference in signature and  reference variable name ($b = &$a;)
bitwise operator
type intersect (CT::T_TYPE_INTERSECTION, listed here for completeness)
return reference (CT::T_RETURN_REF, listed here for completeness)

| :

bitwise operator
type alternation ([CT::T_TYPE_ALTERNATION, listed here for completeness)

I would like the exit code to changed when a file got fixed or needs fixing. If the fix is done successful the tool currently ends with exit code 0 unless running with the dry-run flag, I would like this exception to go away and not exit with code 0.

In general to have a look at single use classes to see if it makes sense to not merge these (for example NamespacedStringTokenGenerator ) with the caller/use class.

Deprecate FinalClassFixer in favor of FinalInternalClassFixer  - https://github.com/FriendsOfPHP/PHP-CS-Fixer/issues/6128
Drop alternative syntax by default for all build in fixers - https://github.com/FriendsOfPHP/PHP-CS-Fixer/issues/6003

start looking for external library managing types parsing for PHPDocs
https://github.com/FriendsOfPHP/PHP-CS-Fixer/pull/6063#discussion_r731317220

CT type of the enum case vs. swtich case

This ☝🏼 and the priorities.
I'm thinking about creating in v3 new interface like:
interface NewFixerInterface extends FixerInfertace
{
    public function getFixersToRunAfter(): array {}
}

and deprecate FixerInfertace::getPriority - in 4.0 NewFixerInterface will be removed and getFixersToRunAfter will go to FixerInfertace to replace getPriority.
The runner then will get the list of fixers somehow sorted (like we have the fixer that always run first) and after running every fixer will have a list of fixers still to run and will update that list with getFixersToRunAfter results.
This will solve problem of circular priorities which now cannot be addressed. But, it will bring new problems - performance (how much will that slow down the fixer? Some fixers might need to run multiple times) and how to handle situation when set of fixers reverts each others and are still on a list of fixers to be run?

Or, maybe we do not want to have getFixersToRunAfter, but getFixersToRunBefore (similarly it will replace getPriority in v4) - and we build the set to run with the information which fixer "blocks" which (when fixer is unblocking other fixers) - this way we keep the same performance, but will still have circular dependencies problem. This solution basically replace numbers from getPriority with list of fixers.

proposal - let's create a label/milestone marker for BC breaks and have a way to discuss each idea separately. otherwise it will be a mess with constant changing of WHICH bc break we discuss

@SpacePossum for the transformers what about BC break for the interface? NameQualifiedTransformer is a killer for large files, such as https://raw.githubusercontent.com/sabbelasichon/typo3-rector/v0.11.32/config/composer/typo3-87-composer-packages-extensions.php
It's not a problem if 4.0 will be fot PHP 8+ only.

Mark fixes supports alternative syntax like as "risky rule" (i.e. "alt syntax rule") because in most case alternative syntax using only in "views" files and views don't mix syntaxes.

Need high-level API/tools for working with code as with abstraction.
2.1. Create high-level API to parse PHP code as nested tree or use something like AST parser.
2.2. Get parent/context Reflection for AST leaves (namespace, class/interface/trait or function/method)
2.3. Get Reflection for AST leaves of native PHP stuff by stubs (if function/class not exists in using version of PHP)


popen in Feedback script

Consider using this instead:

def run_popen(command, timeout):
    """
    Runs a sub-program in subprocess.Popen using the given COMMAND and
    TIMEOUT (seconds).
    """
    # command = 'bash CountLines.sh'
    # timeout = 10
    import time
    start = time.time()
    p = subprocess.Popen(f'{command}', shell=True, stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
    stdout, stderr = p.communicate(timeout=timeout)
    end = time.time()
    return p, stdout.decode(), stderr.decode(), (end - start) # decode: binary --> string

Fixed in https://github.com/mhasoba/TheMulQuaBio/commit/b26edc65c5238bb06830b6070be45d743499be79


Remove extra 'Power On' action from StatusDropdown

Coverage decreased (-0.01%) to 50.57% when pulling c05fae2e84505c7aeaaca2fe07aacfcbf74314e4 on asauber:bugfix-extra-dropdown into e24f1a1d14090cfe380ad1dec340199cf2b80b8f on linode:develop.


Migrate CityCamp NC blog to staging site

@FrankCJones this can now be migrated, staging is moved to /civictech


Build: Elaboration error leads to multiple failing grep calls

The problem below occurs if one uses an HLS action without CARD_DDR but configured
SDRAM_USED=TRUE. Elaboration fails and multiple calls to grep seem to go wrong.
I think we should check the return code and fail on the first one such that we stop on the
first occurring error.
****************************************************************************************
Now try BLOWFISH
****************************************************************************************
~/framework ~/framework
simulator=irun simdir=ies simtop=work.top
hostname=hdclv034 arguments=-explore -app examples/snap_blowfish -arg
in sim_script subdirectory
prepare simout directory
cp: cannot stat `cds.lib': No such file or directory
cp: cannot stat `hdl.var': No such file or directory
SNAP_root=/afs/bb/u/haver/framework/snap
pslse_root=/afs/bb/u/haver/framework/pslse
simbase=   /afs/bb/u/haver/framework/snap/hardware/sim/ies
simout=    20170704_093253
run_sim sim_arg= -batch +model_data+. -64bit -input ncrun.tcl, tst_arg=  -v, AET=1
**** call simulator=irun in background, wait for socket in irun.log->shim_host.dat
irun(64): 15.10-s019: (c) Copyright 1995-2016 Cadence Design Systems, Inc.
irun: *E,RFAIL: A previous invocation failed while running the subexec ncelab.  -R/-r cannot be used until the design has been successfully compiled and elaborated.
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
Usage: grep [OPTION]... PATTERN [FILE]...
Try `grep --help' for more information.
tee sim.log PID=88294 ppid= sim_pid= after 10 sec
could not start irun
**** append msgs from sim.log
**** RC=-1 parallel=1 executed= failed= runtime= simtime= cpus=12 speed=2899 load=0.75 local=0 used_kB=42 percused=38%
**** Versions: SNAP=2ce94b1 2017-07-03 PSLSE=N/A
~/framework
bash-4.1$

9:57:53 AM: So sieht das aktuell aus. Die fehlschlagenenden greps sind doof, das sollten wir besser hinbekommen.

9:57:57 AM: Das log sagt:

9:58:14 AM: ncvlog: *W,SPDUSD: Include directory ../../viv_project/framework.ip_user_files/ipstatic/hdl given but not used.
        Total errors/warnings found outside modules and primitives:
                errors: 0, warnings: 1
        Elaborating the design hierarchy:
                Caching library 'work' ....... Done
                Caching library 'xil_defaultlib' ....... Done
                Caching library 'unisim' ....... Done
                Caching library 'unisims_ver' ....... Done
                Caching library 'secureip' ....... Done
                Caching library 'unimacro' ....... Done
                Caching library 'unimacro_ver' ....... Done
                Caching library 'blk_mem_gen_v8_3_5' ....... Done
                Caching library 'fifo_generator_v13_1_3' ....... Done
                Caching library 'axi_infrastructure_v1_1_0' ....... Done
                Caching library 'axi_clock_converter_v2_1_10' ....... Done
                Caching library 'xpm' ....... Done
ncelab: *E,CUCGNA: component generic HLS_ACTION.C_M_AXI_CARD_MEM0_ID_WIDTH not associated with any formal [<IP_ADDRESS>].
           Default binding for instance: top.a0@psl_accel(psl_accel):action_w@action_wrapper(STRUCTURE):hls_action_0
ncelab: *E,CUCPNA: component port HLS_ACTION.M_AXI_CARD_MEM0_AWADDR not associated with any formal [<IP_ADDRESS>].
           Default binding for instance: top.a0@psl_accel(psl_accel):action_w@action_wrapper(STRUCTURE):hls_action_0
ncelab: *W,CUDEFF: default binding failed for component instance (top.a0@psl_accel(psl_accel):action_w@action_wrapper(STRUCTURE):hls_action_0) with design unit (WORK.HLS_ACTION:BEHAV) because of the above mentioned reason.
ncelab: *W,CUNOTB: component instance is not fully bound (top.a0@psl_accel(psl_accel):action_w@action_wrapper(STRUCTURE):hls_action_0) [File:action_wrapper.vhd, Line:337].
irun: *E,ELBERR: Error during elaboration (status 1), exiting.

@fhaverkamp  Frank, the data is inconsistent. You mentioned the elaboration error, but the grep and other messages come from simulation (run_sim call).
You should have received an error from make config (elaboration), which should be investigated, and not proceeding into simulation.

please verify with branch=fix_grep_356

I trust you. Thanks for taking care. If it reoccurs, I will open a new bug.


FillType Pattern is wrong

https://github.com/sketch-hq/sketch-file-format/blob/master/schema/enums/fill-type.schema.yaml#L7 is supposed to be 4 and not 2

👍


Added GUI animation of FizzBuzz

A remake of the gif below with Tkinter just without the fancy text animations.

[Image source © 100daysofalgorithms]

Awesome! Thanks :D


de.js i18n updates

special thanks to @arbadacarbaYK
https://github.com/lnbits/lnbits/pull/1664

Codecov Report

Merging #1675 (45d2871) into main (bd47527) will decrease coverage by 0.15%.
The diff coverage is n/a.

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more
@@            Coverage Diff             @@
##             main    #1675      +/-   ##
==========================================
- Coverage   46.18%   46.03%   -0.15%
==========================================
  Files          47       47
  Lines        6916     6916
==========================================
- Hits         3194     3184      -10
- Misses       3722     3732      +10

see 2 files with indirect coverage changes
:mega: We’re building smart automated test selection to slash your CI/CD build times. Learn more


TLS Origination glossary entry

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: frankbu
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

content/OWNERS [frankbu]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Thanks!

/lgtm
/approve

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: frankbu, geeknoid
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

content/OWNERS [frankbu,geeknoid]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment


ERROR [vue-tsc] Found 0 errors. Watching for file changes.

Why is error if no errors found?
ERROR
[vue-tsc] Found 0 errors. Watching for file changes.

I use vue-tsc.

Please provide a minimal reproduction

@so1ve https://github.com/imcm7/nuxt-db

I agree that if there are 0 errors, the log could be a regular console.log, as Vite shows console.error with an "ERROR" label:

This is a tsc "issue" though, so I'll create a new issue upstream.

Are there any solution for this issue? Why closed it?


No authentication headers when using Single Table Inheritance on my User model

Hello,
I have my user model set up as such
class User < ActiveRecord::Base
  devise :database_authenticatable, :registerable,
          :recoverable, :rememberable, :trackable, :validatable,
          :confirmable, :omniauthable
  include DeviseTokenAuth::Concerns::User

  ...

end

with SIngle Table Inheritance models set up as
class Applicant < User; end
class Judge < User; end
class Admin < User; end

and in my config/routes.rb
mount_devise_token_auth_for 'User', at: 'auth', controllers: { registrations: 'users/registrations' }

I want to use Single Table Inheritance because I intend to treat the main User model almost as an abstract class and have all accounts be either an Applicant, Judge, or Admin, where I can leverage polymorphism to define custom validations for each of the different types of accounts, etc. Yes, I've considered using a gem to take care of the roles, but since my roling is very primitive (always applicant, judge, or admin) and I would like to leverage inheritance, I thought a simple inheritance pattern was more fitting for the occasion.
Since all accounts will have a single sign-up and sign-in flow regardless of the type of account, I only mounted the devise routes for the superclass, rather than individually for each of the subclasses.
The problem arises when attempting to log on. The response body will come back properly, but the header will come back missing the uid, authentication-token, and client fields.
Stepping through the code in this gem, I believe the problem to be on this line:
https://github.com/lynndylanhurley/devise_token_auth/blob/master/app/controllers/devise_token_auth/concerns/set_user_by_token.rb#L50
By changing the line from
return @resource if @resource and @resource.class == rc

to
return @resource if @resource and @resource.is_a? rc

I was able to get my Single Table Inheritance user models to log in properly and respond with the correct headers.
My questions are:

Is this a valid fix? Is this change consistent with the intended behavior of this line of code?
If not, is there something in the configuration of devise_token_auth or the mounting of relevant routes that I could change to achieve this behavior?

Thank you for your help.

This solved it for me as well, I hope someone can clear up if this is the way to go.

Workaround posted, closing for now.


Automated cherry pick of #1860: 添加同步安全组日志

Cherry pick of #1860 on release/2.10.0.
#1860: 添加同步安全组日志

Codecov Report

:exclamation: No coverage uploaded for pull request base (release/2.10.0@c4f6f51). Click here to learn what that means.
The diff coverage is 0%.

@@               Coverage Diff                @@
##             release/2.10.0   #1862   +/-   ##
================================================
  Coverage                  ?   7.64%
================================================
  Files                     ?     410
  Lines                     ?   62936
  Branches                  ?       0
================================================
  Hits                      ?    4811
  Misses                    ?   57715
  Partials                  ?     410

Flag
Coverage Δ

#aFlag
7.64% <0%> (?)

Impacted Files
Coverage Δ

pkg/compute/models/cloudsync.go
0% <0%> (ø)

pkg/compute/models/secgroupcache.go
6.29% <0%> (ø)

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 c4f6f51...66da35e. Read the comment docs.


Require loop solution in documentation not working with Webpack

I'm using Webpack to transpile parts of my API. When using the modelClass: `${__dirname}/Week`  solution per mentioning in the documentation, the thrown error is unclear;
Client.relationMappings.weeks: modelClass: database\\models/Week is an invalid file path to a model class
I tried manually writing paths without success. Ideally the error would contain information of the path where it's looking for the file.

It does contain the path...

@koskimas so it would be looking here;
root
    node_modules/objection/...
    database/models/Week  <---

However it does not resolve.
root
    node_modules/objection/...
    src/server/api/database/models/Client.js
    src/server/api/database/models/Week.js

webpack context: 'src/server/api/'
`${__dirname}/Week` in src/server/api/database/models/Client.js resolves to 'database\\models/Week' per Objection
It can't find the file.
It also can't find the file when I manual write:
modelClass: 'src/server/api/database/models/Week'
modelClass: 'server/api/database/models/Week'
modelClass: '/api/database/models/Week'
modelClass: 'database/models/Week'
modelClass: 'models/Week'
modelClass: '/Week'
modelClass: 'Week'

I tried all sorts of imports but it is totally unclear why it can't find the file.
A verbose log could help here in the form of:
node_modules/../../src/server/api/database/models/Week is an invalid file path to a model class
Or perhaps something else is the reason for this issue.
This is my webpack config:
module.exports = {
    mode: 'development',
    context: path.resolve('./src/server/api/'),
    entry: ['webpack/hot/poll?1000', './index.js'],
    output: {
        path: path.resolve('build'),
        filename: 'api.server.js',
        libraryTarget: 'commonjs2',
        devtoolModuleFilenameTemplate: '[absolute-resource-path]',
    },
    resolve: {
        ...config.resolve,
        mainFields: ['main', 'module'],
    },
    target: 'node',
    node: {
        __filename: true,
        __dirname: true,
    },

All objection does is this internally:
const modelClass = require(mapping.modelClass);

and what you see in the error is the content of mapping.modelClass. It cannot get more verbose than that on objection's part.

__dirname should be an absolute file path. I don't know what webpack does with it to make it non-absolute. You should probably use one of the other ways to resolve circular deps.

Resolved by changing using named exports and using require like so:
Client.js
export class Client extends Model {...}
Week.js
modelClass: require('./Client').Client,


Ability to provide default values for params/queries

This is something I have wanted to be able to do a few times now and doesn't seem possible. Could be solved via the Zod default function if all the params/query fields were parsed with the schema (I don't see that happening anywhere but maybe I missed it), that's what I have tried so far.

Indeed this is by design, cf https://github.com/ecyrbe/zodios/discussions/225
what could be done is an option to activate it, but would not be activated by default.

An option to activate it would be useful, as we are only using @zodios/core on the front-end so that's where I need default values. I've updated @zodios/core to try the transform option mentioned in that discussion but it doesn't work for this scenario as the schema isn't executed for undefined values.

As a general advice, if you have optional parameters with defaults, you should let your backend set it.
Indeed, default values can be considered business code and you usually want business code to be executed on your backend.
That's why zodios has this behaviour by default.
Nevetheless, this option is now available on @zodios/core v10.7.0. see documentation

Thanks :tada: The specific endpoint I'm adding now has different responses depending on whether you include a query param or not so I'm making two separate endpoints, one with the query param forced to true and the other without it.


[DOC] Fix interpreter version in doc

What is this PR for?
Change the version from 0.7.0 to 0.8.0
What type of PR is it?
[Documentation]
Todos

[ ] - Task

What is the Jira issue?

No jira created

Screenshots (if appropriate)
Questions:

Does the licenses files need update? No
Is there breaking changes for older versions? No
Does this needs documentation? No

@felixcheung  Could you help review it ? Thanks

Thanks for review @felixcheung  will merge it soon


cmd/cgo: write C code in a more proper way

Hello,
Just like C code is written in Go comments, an IDE implementation would bring problem for intellisense. I find the current notation ugly. From today on, I propose to implement old style Pascal comments to use C code with Cgo.
package cgoexample

(*
    #include <stdio.h>
    #include <stdlib.h>

    void myprint(char* s) {
        printf("%s", s);
    }
*)

import "C"
import "unsafe"

func Example() {
    cs := C.CString("Hello from stdio\n")
    C.myprint(cs)
    C.free(unsafe.Pointer(cs))
}

What do you think ? I think it would be another good loan to Pascal.
Source
http://www.freepascal.org/docs-html/ref/refse2.html
http://www.math.uni-leipzig.de/pool/tuts/FreePascal/prog/node3.html

I'm sorry we cannot change the language, including the two forms of comment's it accepts, //,  and /* */.
I feel that you can use the C style /* ... */ forms equally as well as the example you showed above. Note that C code must directly preceed the import "C" line, that is there must be no linebreak between the commentary and the import declaration.

I will second ANY proposal to make included C code unmistakably distinguishable from comments.
I Personally would prefer an explicit directive like
inline{
     //  C code goes here
}

@pablochacin C is not part of the Go language specification. cgo is implemented entirely as a preprocessor and the go tool on top of the regular go compiler.

@davecheney Why cannot Cgo pimp go language and add syntaxes. It is a preprocessor. So I don't think there could be a problem.
Using the C preprocessor in Go would be great too :
{$ifdef OS}
/* Go code */
{$endif}

Or you could just move the majority of your C code to actual .c files.

@dominikh Does anything happens if there's a comment in a .c file included in Go using cgo ?

@dominikh All cgo cares about is what you put in the .go file.  You can write
// #include "foo.h"
import "C"
and put anything you like in foo.h.  You can still reference things declared in foo.h using the C. syntax--see the cgo docs.

@ianlancetaylor I assume your last comment was directed at @StEvUgnIn, not me?

@StEvUgnIn et al, this issue is marked as closed. Please continue the discussion on golang-nuts. Thanks.

@dominikh Yes, sorry.  Error on my part.


SSR Apps and using custom traces - nuxt3

Describe the bug
Using the performance library is hard in SSR Apps. In SSR Apps, code can be executed on the server or on the client.
This library is only for the Client and in nuxt we can create a plugin which is only executed on the client side.
So far so good.
The Problem now happens with the actual components. If we want to create a simple component with two button which start and end a span we run into some problems. As we are executing this code first on the server side, the document is undefined and the performance library will throw an error. We can't execute the code just on the client side, because the document is requested already in the import. As far as I know there is no way to do a conditional import in JS.
Can you guide me here a little bit? I'm not really sure if it's even a bug or the behaviour is wanted like that.
BTW I am the author of this library and wanted to add this cool feature to make it easy to get started with it :)
Steps to reproduce
Reproduction here:
Just refresh the page and you know what I mean
Environment

BugSnag Performance library version: 1.0.0
BugSnag Error Monitoring library version (if any): -
Browser framework version (if any):

Nuxt: 3.6.5

Example Repo

[x] Link to it here: https://stackblitz.com/edit/nuxt-starter-wljh1k?file=app.vue

Same issue using Next.JS
ReferenceError: document is not defined

Hi @JulianMar
We’re glad to hear you’re interested in using our Performance library!
Our engineers will look into this and we will make sure to update the thread with any updates, or ask any questions if we need to. Thanks!

Hi :wave:
🎉 🎉 🎉   We have just released a new version (v2.2.0) of the Bugsnag-js-performance notifier that has support for SSR apps and using custom traces!
If after update updating you see any issues then please let us know and we can investigate further.


Enable messageboxed v2

Starting here, clients write MBv2 messages. This PR simultaneously adds MerkleRoot to HeaderPlaintextV1 (the signed struct).
There are no MBv1 messages with a non-nil HeaderPlaintextV1.MerkleRoot. There are some MBv1 messages with a MessageClientHeader.MerkleRoot, we'll discard those values because they're not mirrored in the signed header. All MBv2 messages will have HeaderPlaintextV1.MerkleRoot set and that will be required to unbox.
Also this discards the local message cache. Because a client running a previous version will have unboxed V2 messages but without knowledge of the MerkleRoot field. So it would have MBv2 messages with MerkleRoot=nil in its cache. So we bust the cache (by incrementing blockIndexVersion).
As a reminder the header structs are:

remote.MessageBoxed contains a

Plaintext, non-versioned common.MessageClientHeader
Sealed, versioned local.HeaderPlaintext[V1]

which gets transmogrified into a client-local, non-versioned common.MessageClientHeaderVerified

The tests do not test across versions. (Except for the canned tests which do test the new client unboxing some old messages). I tested locally talking and starting conversations across MBv1/MBv2 version boundary. And I talked to Jack on prod this MBv2 client and switched back with no problems.

The commits d1674e38733a...b92d829efaae introduce visual changes on linux. :mag_right: 2 changed

Changed: unlock_folders-No_paperkeys (before) (after)

Changed: Markdown-emoji (before) (after)

The commits d1674e38733a...c550cd982307 introduce visual changes on linux. :mag_right: 2 changed

Changed: Tracker-New_user_Scroll_1 (before) (after)

Changed: Markdown-emoji (before) (after)

The commits 8986c164c250...8d1fc52d3d9d introduce visual changes on linux. :mag_right: 2 changed

Changed: Tracker-New_user_Scroll_1 (before) (after)

Changed: Markdown-emoji (before) (after)


Toc changes

OPS Build status updates of commit 01d5771:
:warning: Validation status: warnings

File
Status
Preview URL
Details

enterprise-graph/toc.yml
:warning:Warning

Details

enterprise-graph/toc.yml

Line 0: [Warning] Invalid file link:(~/concepts/schema-maps.md).
Line 0: [Warning] Invalid file link:(~/concepts/relationships.md).

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.

OPS Build status updates of commit 846cac9:
:warning: Validation status: warnings

File
Status
Preview URL
Details

enterprise-graph/concepts/ontology.md
:warning:Warning

Details

enterprise-graph/ontology-concepts.md
:warning:Warning

Details

enterprise-graph/ontology-tutorial.md
:warning:Warning

Details

enterprise-graph/toc.yml
:warning:Warning

Details

enterprise-graph/create-source-schema.md
:warning:Warning

Details

enterprise-graph/concepts/input_data.md
:warning:Warning

Details

enterprise-graph/deleting-your-ontology.md
:white_check_mark:Succeeded

enterprise-graph/media/deleting-ontology/delete-data-source.png
:white_check_mark:Succeeded

enterprise-graph/media/deleting-ontology/delete-ontology.png
:white_check_mark:Succeeded

enterprise-graph/media/deleting-ontology/source-schema-view.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-concepts/1_ontology_config.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-concepts/2_ontology_config.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-concepts/3_ontology_config.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-concepts/relations_tab.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-concepts/type_values.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-tutorial/add-ontology-from.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-tutorial/cities-entity.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-tutorial/cities-second-degree.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-tutorial/entity-list.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-tutorial/inherited-properties.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-tutorial/property-edits.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-tutorial/property-view.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-tutorial/publish-button.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-tutorial/type-view.png
:white_check_mark:Succeeded

enterprise-graph/media/ontology-tutorial/version-selector.png
:white_check_mark:Succeeded

enterprise-graph/concepts/ontology.md

Line 37: [Warning] Invalid file link:(~/creating-your-ontology.md).

enterprise-graph/ontology-concepts.md

[Warning] Author stflanag cannot be recognized in GitHub.
Line 23: [Warning] Invalid file link:(~/media/creating-your-ontology/1_ontology_config.png).
Line 102: [Warning] Invalid file link:(~/media/creating-your-ontology/type_values.png).
Line 106: [Warning] Invalid file link:(~/media/creating-your-ontology/relations_tab.png).

enterprise-graph/ontology-tutorial.md

[Warning] Author stflanag cannot be recognized in GitHub.
Line 29: [Warning] Invalid file link:(~/media/ontology-tutorial/version-slector.png).

enterprise-graph/toc.yml

Line 0: [Warning] Invalid file link:(~/creating-your-ontology.md).
Line 0: [Warning] Invalid file link:(~/creating-your-ontology.md).
Line 0: [Warning] Invalid file link:(~/concepts/schema-maps.md).

enterprise-graph/create-source-schema.md

[Warning] Author stflanag cannot be recognized in GitHub.
Line 0: [Warning] Invalid file link:(~/mapping_source_data).
Line 24: [Warning] Invalid file link:(~/media/creating-your-ontology/1_ontology_config.png).
Line 46: [Warning] Invalid file link:(~/media/creating-your-ontology/create_source_schema.png).
Line 62: [Warning] Invalid file link:(~/media/creating-your-ontology/fields_not_mapped.png).

enterprise-graph/concepts/input_data.md

Line 24: [Warning] Invalid file link:(~/creating-your-ontology.md).

For more details, please refer to the build report.
Note: If you changed an existing file name or deleted a file, broken links in other files to the deleted or renamed file are listed only in the full build report.


Update gallery.html

Purpose
Describe the purpose of this change. If there is an existing issue that is resolved by this pull request, please reference it in the form Fixes #1234 where 1234 is the relevant issue number.
Screenshots
If this is a GUI change, try to include screenshots of the change. If not, please delete this section.
Documentation
If this is an enhancement, add a link here to the corresponding pull request on https://github.com/sourcethemes/academic-www or describe the documentation changes necessary.

Closing PR as it appears to have been submitted by accident and it lacks a title/description on what the purpose of the PR is.


Unknow property "repoLoadStatus"

In step 7 the very last sentence is

Removed repoLoadStatus, since Paging 3.0 has a mechanism for tracking the load status as well, as we'll see in the next step.

In the project there is no such property anywhere.

thanks for reporting! fixed