Fast uart v2

I propose this in favor of #58.
Simple enough code, UART's FIFO act as a 24 byte buffered DMA (and has a timeout irq). No alarm code required, works fine at 1MBaud (higher bauds not tested), with CTS line from FPGA not to overflow the 1-byte simple uart module.

Continous stream at 1MBaud, no problems.
Possible improvements:

ice_usb_uart_tx as DMA,
less polled code, however I can't justify it without an RTOS and without mutexes.

Very interesting how measuring + insights of what happens permits to optimize the right thing first.
The other PR was having a great approach of DMA and permitted to lead to this more minimal changeset.
I will collect time to review this but looks pretty good overall. Small nits here if anything.
Is CTS support part of the PR? I suppose not everyone will implement it FPGA_side.

Is CTS support part of the PR? I suppose not everyone will implement it FPGA_side.

Actually RP2040 has CTS line support in hardware and it boils down to enable correct function on the gpio. It can be done outside of the sdk and it's not a part of this PR. The image is just to show USB flow control works as expected.

Hi,

After a long debugging day the board hanged on me 2 times. I think it's due to high reset count and usb device number overflowing or something, rebooting the linux host fixes it.
Garbage data fixed by sleep_ms(10) and then clearing the fifos, I didn't find a better way. RP2040 seems to pick up the slightest noise on the line when initializing FPGA. Maybe parity would help, but this aims to be as transparent as possible.

CDC seems to pass only whole 512 byte "packets" now (whole CFG_TUD_CDC_EP_BUFSIZE buffers)... Any ideas why?

I did find some time to follow your debugging, but did not get a chance to answer until now.

Actually RP2040 has CTS line support in hardware and it boils down to enable correct function on the gpio. It can be done outside of the sdk and it's not a part of this PR. The image is just to show USB flow control works as expected.

Thank you all good then! That also makes sense.

high reset count [...] rebooting the linux host fixes it.

Does this mean you found an existing bug on the pico-ice SDK? I will open an issue to make sure to test it upon next release if so.

RP2040 seems to pick up the slightest noise on the line when initializing FPGA. Maybe parity would help, but this aims to be as transparent as possible.

This is possible that the FPGA init consumes a lot of power at once and the clock signal could be a bit too close to the UART... that could be tested by using another pin if interested.

CDC seems to pass only whole 512 byte "packets" now

For BULK endpoints in FullSpeed, it looks like this should be 64 bytes that is right.
It also seems like 64 and 512 are default values picked to match the USB max packet size, and is a good idea to follow the defaults.
From TinyUSB:
// CDC Endpoint transfer buffer size, more is faster
#define CFG_TUD_CDC_EP_BUFSIZE   (TUD_OPT_HIGH_SPEED ? 512 : 64)

#ifndef CFG_TUD_CDC_EP_BUFSIZE
  #define CFG_TUD_CDC_EP_BUFSIZE    (TUD_OPT_HIGH_SPEED ? 512 : 64)
#endif

So yes you are right it can be deleted, thank you!

Do you think we should limit flush call count? I saw it generates packets as small as 1 byte. Maybe calling it once every 100ms or so?

Do you think we should limit flush call count? I saw it generates packets as small as 1 byte. Maybe calling it once every 100ms or so?

Feel free to add it to the PR, but it is always possible to add it in other PRs. That permits to avoid having one PR grow and grow and introduce a lot of changse at once. Either are fine!

I thought about a different PR solving a different issue!
I vote to merge this first as it works well enough.

Many thanks for all the time spent in this!


Some code issues and implementation not match the paper.

Thank you for your excellent work. The code in this repository appears to be outdated, and does not match the paper. Could you please confirm? I have encountered the following issues and would appreciate your assistance in resolving them:

reference before assignment
xgboost.py:
self.ranker = self.get_ranker()
self.avm_predictor = self.get_avm_predictor()
self.std_predictor = self.get_std_predictor()
self.ranker_path = ranker_path
self.avm_predictor_path = avm_predictor_path
self.std_predictor_path = std_predictor_path
The ranker xgboost model  (with weight loaded) always generate  0.5 with different architecture config, could you please check again. The EA optimization towards the highest ranking does not work.
The EA algorithm (ea_optimized.EAOptimizer) does not match the algorithm 1 announced in the paper.  e.g.,  there is no code of selecting the top_50 population. Also, no "union" or "crossover".

Hi @blyucs
Thank you for raising this issue.

The rankers' weights are being updated. More training is done to ensure that we can handle any type of search space, including modifying any layer's hyperparameter in the resnet macro architecture.
The union is done by directly appending the mutated architectures to the selected ones.
There is no crossover in the optimized EA. In general, in NAS we avoid crossover, because of the high number of invalid architectures produced.


OnChanged event not firing

Hi Christian.
I'm having an issue with your package that I cant quite figure out. I have tried following your example but and cannot get it to work.
When I change something in my database the OnChanged event doesn't fire.
I have had normal SqlDependencies work when data changes, but I need to know what the data that changed was, therefor I wanted to try your solution out.
Below is the class that I have implemented following your example. Hope you can help me out, thank you in advance
namespace RDSOnline.Data.Services
{
public class DatabaseMonitorService : IDatabaseMonitorService
{
readonly string ConnectionString = "Data Source=[SERVER];Initial Catalog=[NAME];User ID=[USER];Password=[PASSWORD]";
    public DatabaseMonitorService()
    {
        StartService();
    }

    private void StartService()
    {
        ListenForChanges();
    }
    private void ListenForChanges()
    {
        using (SqlTableDependency<Code> dep = new SqlTableDependency<Code>(ConnectionString, "Codes"))
        {
            dep.OnChanged += OnDependencyChange;
            dep.OnError += (sender, args) => Console.WriteLine($"Error: {args.Message}");
            dep.Start();
        }
    }

    public static void OnDependencyChange(object sender, RecordChangedEventArgs<Code> e)
    {
        var dependencyChanged = e.Entity.Description;
    }
    ~DatabaseMonitorService()
    {
        SqlDependency.Stop(ConnectionString);
    }
}

}

Hi,
SqlTableDependency implement IDisposable interface. This means that when the execution go out of the using statement, SqlTableDependency invoke dispose method and remove any database opbject created to send notifications. That is wky you do not get any record change notification.

Complete oversight from me.
Thank you very much for the quick response, much appreciated!!

You are welcome.
Check some real user cases in section Monitor record table change examples and use cases present in home page.


Multiple audio track support

Is it possible to make the audio track selectable? It should be possible
https://msdn.microsoft.com/en-us/library/windows/apps/hh452774.aspx
I'm not sure if you can get that data with streams though. I've been digging through the code a bit but can't find any video object that contains this data.

I also found this link https://html.spec.whatwg.org/multipage/embedded-content.html#media-resources-with-multiple-media-tracks.
Is it something you want to try to do? If you are up for it, you can take a look at player.js which might be a good starting point.

Look this https://www.chromestatus.com/feature/5748496434987008

recent experiment I did: https://gist.github.com/maxogden/108134f035decfcfdf15
I think if you parse the mp4 yourself and create two MediaSource instances, one for audio and one for video, then sync the playback yourself, it should be somewhat possible

re: mp4 parsing, https://github.com/mafintosh/mp4-stream


Fix: number type changed to string

Fixes an issue e.g. for '060'.
let currencies = require('currency-codes');
console.log(currencies.number('060')); // 'BMD'
console.log(currencies.number(60)); // undefined

In Typescript the first log wouldn't be possible due to type errors.

I think this is fair, let's take it in.

Released as 1.5.0


Securing UI

I've been looking into the best way to secure UI components behind a permissions system, and this project looks like it would help.
However, it this is part of a bundled blob of JS delivered to a browser, you could ultimately flip bits using react devtools or similar methods, correct?
The only way I've read to truly secure a UI is to not deliver it to the client at all. This would mean some tricky code splitting, I think.
Do we know if this problem has been tackled in a react app before?

If you are doing server side render and normal code splitting along with this library then it would not get to the front end. But unless you go full server side rendered and dont use react on the client at all other than for small functionality but not routing or permission control then A fully secure app as you put it would not be possible.


python27: add patch for CVE-2018-14647

Motivation for this change
Closes https://github.com/NixOS/nixpkgs/issues/52977
Things done

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

[X] NixOS
[X] macOS
[ ] other Linux distributions

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

We need to add (version of) this patch to all interpreter versions.

Also, you can target staging-next.

We need to add (version of) this patch to all interpreter versions.

python2.6 is the only affected.

python 3.6.8 (already in unstable) includes https://github.com/python/cpython/commit/f7666e828cc3d5873136473ea36ba2013d624fa1
python 3.7.2 (already in unstable) includes https://github.com/python/cpython/commit/18b20bad75b4ff0486940fba4ec680e96e70f3a2

Leaving this unresolved is probably a bad PR, though we do have the newest expat on both master and 18.09 so we probably aren't affected.

It's not a security issue with recent versions of libexpat. The library initializes the salt from a good entry source by default.


adds the application interface

This is the application shell file please update it so that all your microservices can also be accessed. Thanks

LGTM


Player movement

The character controller needs to be done. As of today it has all the basic mechanics but some aspects are missing, such as:

Jump inertia
Better headbob
Diagonal inertia
Gravity shifts

To fix:

the velocity changes with the angle of the camera. This is nice, but it should be controllable.

Added jump inertia and updated headbob, dismissed gravity shift. What is missing is the fact that the player hardly moves whilst in midair.

Switched to the advanced character branch and added various features such as gestures to run, head bob effects, subtle fov changes and chargeable jump, along with fixes regarding player movement in general


V1.2b deletefriendbyindex

Allow users to delete a friend by either index or name, based on their preference. More experienced users may choose to delete a friend by index instead of name to increase efficiency.
Summary of changes done:

Overloaded the constructor of delete command so that Delete command can be constructed with either a Name or an Index.
Added a boolean field isDeletionByIndex, which will be instantiated as True/False based on which Delete command constructor is used.
Updated DeleteCommandParser to be able to parse both text for Name and numbers for Index.
Updated test cases correspondingly to test both Delete command by index and Delete command by friend.

fixes #90

Codecov Report

Merging #98 (45380ad) into master (80a72fa) will increase coverage by 0.15%.
The diff coverage is 85.10%.

@@             Coverage Diff              @@
##             master      #98      +/-   ##
============================================
+ Coverage     63.42%   63.57%   +0.15%
- Complexity      538      542       +4
============================================
  Files            95       95
  Lines          2023     2048      +25
  Branches        275      281       +6
============================================
+ Hits           1283     1302      +19
- Misses          646      650       +4
- Partials         94       96       +2

Impacted Files
Coverage Δ

...eedu/address/logic/parser/DeleteCommandParser.java
77.77% <75.00%> (-11.12%)
:arrow_down:

...va/seedu/address/logic/commands/DeleteCommand.java
91.89% <90.32%> (-8.11%)
:arrow_down:

:mega: Codecov can now indicate which changes are the most critical in Pull Requests. Learn more


Can't work out how to depend on a File field

I would like to show some fields once a file has been selected to be uploaded (or previously uploaded).
File::make('Payroll Payment Summary', 'payroll_payment_summary'),
NovaDependencyContainer::make([
    Heading::make('NotEmpty') // Just an example field
])->dependsOnNotEmpty('payroll_payment_summary'),

Have also tried ->dependsOnNullOrZero('payroll_payment_summary').
Is what I am trying achievable?

Hello, I have the same problem, could you solve it? Thank you


Add wrappers.vector.HumanRendering

Description
Rather than add human rendering to every vector environment, this wrapper hopes to add human style rendering as a wrapper for environments to use.
Completes https://github.com/Farama-Foundation/Gymnasium/pull/880 and fixes cartpole rendering in https://github.com/Farama-Foundation/Gymnasium/issues/872

@TimSchneider42 Could you test this PR and see if it works for you?

I had to make an adjustment to make it work:
diff --git a/gymnasium/wrappers/vector/rendering.py b/gymnasium/wrappers/vector/rendering.py
index c4f691a44..1d7463152 100644
--- a/gymnasium/wrappers/vector/rendering.py
+++ b/gymnasium/wrappers/vector/rendering.py
@@ -131,7 +131,9 @@ class HumanRendering(VectorWrapper):
             assert (cols * subenv_size[0] * scaling_factor == self.screen_size[0]) or (
                 rows * subenv_size[1] * scaling_factor == self.screen_size[1]
             )
-            return rows, cols, scaling_factor
+            self.num_rows = rows
+            self.num_cols = cols
+            self.scaled_subenv_size = (int(subenv_size[0] * scaling_factor), int(subenv_size[1] * scaling_factor))

             assert self.num_rows * self.num_cols >= self.num_envs
             assert self.scaled_subenv_size[0] * self.num_cols <= self.screen_size[0]

Apart from this, it worked fine.
One thing that is confusing to me is that human rendering can no longer be enabled with the render_mode argument but rather requires the user to apply the wrapper manually. We could consider wrapping the classic control environments automatically if the render mode is human.
Also, is there a reason why this wrapper defines the render function to always return none? We could just leave it undefined so that the user can still call the original render function if they require a RGB image.
Best,
Tim


fix Fix data size calculation of auto sample

Fix data size calculation of auto sample, before this pr, the data size is include all the replicas
Sample 10 percent rather than fixed 200000 rows
Move some auto analyze related options to global session variable
Add some logs

Proposed changes
Issue Number: close #xxx

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

run buildall

run buildall

run buildall

run buildall


Android: Custom fonts not rendered with correct font when using fontWeight/fontStyle

Describe the bug
Bold/SemiBold/Italic fonts not working on Android when you are using custom fonts.
To Reproduce
Steps to reproduce the behaviour:

Add a custom font set to NativeBase
Render <Text fontWeight="bold">Hello world</Text>
The Text gets rendered as the default device system font.
See screenshots

Expected behaviour
The  component should render the correct font/font-weight/font-style based on theme configuration.
Screenshots
iOS (working)

Android (not working)

Platform

Device: Samsung S10
OS: Android

Additional information
The correct font gets rendered  when I removed the fontWeight and fontStyle prop from  component in the source code. But that might break for users who doesnt have a custom font. My suggestion to the solution is to check if the user has not configured a custom font than add the fontWeight and fontStyle prop to the component internally otherwhise just omit them.
Would be happy to help on this issue and create PR but I am going on vacation now and wont be able to help you out right now.

@chaaya thanks for reporting, this has been fixed in the latest version.

It works only for iOS, Android doesn't respect fontWeight prop. Please re-open.

Same here, please reopen it, font is not rendering correctly on Android

fontWeight prop still not working with custom fonts on Android

Still not working for me either, having to directly reference the name of the fontFamily at desired weight

Still a problem, please reopen

@intergalacticspacehighway I am also seeing this issue in v3.4.20.  Font weights working in iOS but not in Android.

Still a problem, please reopen

Still seeing this issue as well.

I'm not seeing this issue directly, although I am noticing responsive resolution of fontWeight doesn't work on Android with a custom font configured, so we've added this patch:
diff --git a/src/components/primitives/Text/index.tsx b/src/components/primitives/Text/index.tsx
index be860aaddd8cd25d335cca035cbcfeabb2b82c01..d9cc0b2e5dbab3f6ea570066315d8c1ddc9243f3 100644
--- a/src/components/primitives/Text/index.tsx
+++ b/src/components/primitives/Text/index.tsx
@@ -36,7 +36,7 @@ const Text = ({ children, ...props }: ITextProps, ref: any) => {
     props,
     {},
     {
-      resolveResponsively: ['noOfLines', 'numberOfLines'],
+      resolveResponsively: ['noOfLines', 'numberOfLines', 'fontWeight'],
       // We override the component base theme if text has an ancestor.
       componentTheme: hasTextAncestor ? {} : undefined,
     }

Still a problem, please reopen


New Source: APC - Software APC Schneider Electric Firmware: ID18UPS 09.3

Vendor: APC
Firmware: ID18UPS 09.3
Software: APC Schneider electric
<40>01/27/2022 14:21:31 <IP_ADDRESS> APC: Test Syslog.

this was already supported in 1.x note the apc test syslog events do not match normal events please see doc for setup


Credentials for local env patch

A small change to allow different credentials used on local environment. I've added package-lock.json to .gitignore to avoid cluttering next to yarn files.

Updated readme
Deleted ignore from .env.example to avoid confusion
updated index.ts variable

Why you added , package-lock.json ,I think you shouldn't, it's intended to be checked .

Usually I do check in on my own projects, but since this project is using yarn and I saw the yarn.lock I didn't know if it was best to leave both.


[Bug]: Task :ledgerhq_react-native-hid:verifyReleaseResources failed

Impacted Library name
@ledgerhq/react-native-hid
Impacted Library version
No response
Describe the bug
After updating to Expo SDK 47 bare and applying these steps in the android folder: React Native Upgrade Helper from the Expo migration guide, the production build and ./gradlew assembleRelease (APK generation) fail with error:
`> Task :ledgerhq_react-native-hid:verifyReleaseResources FAILED
w: Detected multiple Kotlin daemon sessions at build/kotlin/sessions

What went wrong:
Execution failed for task ':ledgerhq_react-native-hid:verifyReleaseResources'.

A failure occurred while executing com.android.build.gradle.tasks.VerifyLibraryResourcesTask$Action
Android resource linking failed
ERROR:/Applications/Ambire/ambire-mobile-wallet/node_modules/@ledgerhq/react-native-hid/android/build/intermediates/merged_res/release/values/values.xml:2722: AAPT: error: resource android:attr/lStar not found.
`

Expected behavior
Expo SDK 45 included react-native: 0.68.2 and there was no issue building on Android with this package
Additional context
No response

Any news on this issue?

For anyone else facing the same problem, I have created this patch which allows the @ledgerhq/react-native-hid package to be compiled with the latest sdk version 33
index d6eebd0..7fd0018 100644
---<EMAIL_ADDRESS>+++<EMAIL_ADDRESS>@@ -6,7 +6,7 @@ buildscript {
   }

   dependencies {
-    classpath 'com.android.tools.build:gradle:3.5.1'
+    classpath("com.android.tools.build:gradle:7.3.1")
   }
 }

@@ -21,11 +21,10 @@ allprojects {
 apply plugin: 'com.android.library'

 android {
-  compileSdkVersion 29
-
+  compileSdkVersion 33
   defaultConfig {
     minSdkVersion 24
-    targetSdkVersion 29
+    targetSdkVersion 33
     versionCode 1
     versionName "1.0"
   }```


crd for offline

What type of PR is this?

/kind feature
What this PR does / why we need it:

design new crds for the range of softwares

Which issue(s) this PR fixes:

Fixes #
Special notes for your reviewer:

/lgtm

/approve


Replace @vinxi/vite-plugin-inspect with vite-plugin-inspect

Currently package/start depend on two vite-plugin-inspect packages (it's the same github repo):

@vinxi/vite-plugin-inspect
vite-plugin-inspect (This is the newer npm package)

This PR simplifies things by:

removing @vinxi/vite-plugin-inspect
updating vite-plugin-inspect from 0.6.1 to 0.7.12 (Vite 4 compatible since ^0.7.10)

Thanks. We had played with forking it to add some unique features but probably not worth maintaining at this point. We might consider bringing it back later.


Changing the styles of the main page, alignment of footer box and addition of tutorials in home page

Is your feature request related to a problem? Please describe.
The whole page is in blackish color which will hide those things which we want to highlight.
On the home page, the portions of the footer are not aligned properly.
We will know that this website is providing tutorial sections also, only when we are going to the projects section. For new users, it will be difficult.
Describe the solution you'd like
->The color of the body should be different from the footer.
->Instead of adding a white circle in which a setting icon is inserted to represent the change in theme color, we can use some other icons like a circle of mixed colors, which will make users understand that it's a color-changing property. Otherwise, users will think that it's the tool of settings.
->When we are clicking to change the theme color, the color of the chat icon also should change, so that it will show uniformity.
->We should align those boxes in a single line using a grid box or flexbox.
->We should add a tutorial section in the navigation bar of the Home page.
->In the project section, we can add a search bar and a filter option, which will allow users to search according to their wishes
These are the aspect of changes that this website should need. Consider this and if any one of these is reliable, assign this to me, please.

Do we need these changes?
cc: @AnirudhPanda


API: update STRtree interface (merge shapely/pygeos features)

This PR tries to consolidate the STRtree implementations of Shapely and PyGEOS.
For now, I did the following:

Rename pygeos' query to query_items to follow the API discussion / refactoring from #1064, #1112. Compared to the current shapely version, this query_items now has the additional predicate and distance keywords.
~Rename pygeos' nearest method to nearest_bulk. I am not very of this new name, but so we have to discuss / decide how to otherwise resolve the inconsistency with shapely's current nearest which only accepts a single geometry as input and returns a single index (instead of 2D array).~
Rename pygeos' nearest to nearest_item and changed it to return a 1D instead of 2D array (see discussion below) to have it be compatible with the shapely version. Compared to the current shapely version of nearest_item, the new version is vectorized and can accept an array of geometries.
Added pygeos' query_bulk and nearest_all as is, as those are strictly new features not clashing with existing shapely methods.

See also some of the discussion in https://github.com/pygeos/pygeos/issues/398

Note for reviewing: I actually removed shapely's strtree.py and updated the pygeos version (strtree_pygeos.py) with new things from shapely in a first commit, and then renamed that to strtree.py in a second commit. So if you want to see the changes coming from pygeos, check the diff of only the first commit, while in the overall diff git shows the changes compared to shapely's existing strtree.py.
I still need to merge the docstrings (and especially the example sections)

Coverage increased (+3.02%) to 84.151% when pulling 1586d9fc74d663c374d4456142ddb5ebe1f584c1 on jorisvandenbossche:update-strtree into a0f8a31a18d5384f0a04ee8e8b2d089b37c186cc on Toblerity:main.

About the (old pygeos) nearest method: I think that its output should be changed from an (n, 2) array to an array/scalar with the same shape as the input. The same as a ufunc actually.
Then, if you provide a scalar, you get the same behaviour as the shapely nearest.
One question is: what do we return for “None” input? -1?

Good point, as long as nearest only returns a single value per input geometry (which is the difference with nearest_all), we indeed don't need to return a 2D array. That makes for scalars similar as shapely's nearest_item, and then we can safely extend that function to also work on array input.
So we currently have:
>>> points = shapely.points(range(5), range(5))
>>> tree = shapely.STRtree(points)

# current shapely method only works for a single geometry, returning a single index
>>> tree.nearest_item(shapely.points(1.5, 1.5))
1

# this is the pygeos.STRtree.nearest (which I called nearest_bulk here temporarily)
>>> tree.nearest_bulk(shapely.points(1.5, 1.5))
array([[0],    # <-- this could also return the scalar "1" instead for scalar input
       [1]])

>>> tree.nearest_bulk(shapely.points([(1.5, 1.5), (3.5, 3.5)]))
array([[0, 1],   # <-- for array input, this can return the array [1, 3] as output
       [1, 3]])

One question is: what do we return for “None” input? -1?

So currently for pygeos' nearest, those are skipped:
>>> tree.nearest_bulk([shapely.points(1.5, 1.5), None, shapely.points(3.5, 3.5)])
array([[0, 2],
       [1, 3]])

which is a reason that we needed to return a 2D array with the indices of the query geoms as well.
For integer output, I assume -1 is the only possible value to use. It is a bit annoying though, as you might typically use the result in an indexing context, and then -1 can actually be a valid value but meaning something differently. Another option could be to raise an error for missing values as input, although this also deviates from our general handling of missing values. But it might be the safer option here.

cc @brendan-ward

Another option could be to raise an error for missing values as input, although this also deviates from our general handling of missing values. But it might be the safer option here.

That makes sense. I think I’d opt for raising an exception for None input when returning indices.

I did an attempt to do what we discussed above: let the old pygeos' nearest return a single scalar / 1D array of indices instead of the 2D array (what I temporarily called query_bulk in this PR), so it can be combined into shapely's nearest_item.
(for now just did the changes on the python side; once we are happy with the API, we should probably move that to the C implementation)
For missing values as input, for now I am raising an error.
But there is another case where we need to decide what to do: querying an empty tree. In pygeos, that returned an empty array of indices, but that's also no longer possible (the output needs to have the same shape as the input). Shapely currently returns None for that case. So one option is to keep that behaviour, another option is to raise an error?

Pull Request Test Coverage Report for Build<PHONE_NUMBER>

82 of 82 (100.0%)  changed or added relevant lines in 1 file are covered.
26 unchanged lines in 2 files lost coverage.
Overall coverage increased (+3.08%) to 84.155%

Files with Coverage Reduction
New Missed Lines
%

shapely/strtree.py
2
98.36%

shapely/geometry/base.py
24
80.6%

Totals

Change from base Build<PHONE_NUMBER>:
3.08%

Covered Lines:
2135

Relevant Lines:
2537

💛  - Coveralls

Thanks @brendan-ward!

I think raising an exception for any query against an empty tree also makes sense. ...
In fact, if we caught this during the creation of the tree (since it is immutable), this may simplify later checks that the tree is non-empty since we'd never be able to construct an empty tree.

I think I would also prefer raising an error, at least when doing the nearest query, instead of returning None.
But already raising an error upon creation of the tree would be empty, might also be annoying in some use cases. Consider for example geopandas sindex / sjoin case. If the strtree creation can error, geopandas would need to protect for this in .sindex and have it return something else (eg None) if it would error (or protect every access of .sindex). In case of sjoin, geopandas currently is happy with the empty result from query_bulk for an empty tree, as that will result in an empty dataframe as result (note that an empty tree doesn't necessarily need to come from emtpy dataframes as input, it can be a dataframe with only missing or empty geometries).

API-wise, it feels a bit awkward that query_items can return items from items created with the tree, whereas query_bulk only ever returns indices. I'm not sure of the use case, but it seems like query_bulk should also return items if those are provided, so that it is the vectorized equivalent of query_items.

Yeah, that seems indeed best to do to ensure consistency .. (although I also don't see any use case for this)

API-wise, it feels a bit awkward that query_items can return items from items created with the tree, whereas query_bulk only ever returns indices. I'm not sure of the use case, but it seems like query_bulk should also return items if those are provided, so that it is the vectorized equivalent of query_items.

Yeah, that seems indeed best to do to ensure consistency .. (although I also don't see any use case for this)

Actually, that's not possible with the current API. query_bulk returns a 2D array, with indices both into the input geometries and into the tree geometries. The indices into the tree geometries can be replaced with the "items" stored in the tree. But for the input geometries, we only have actual positional indices that can be used.
And returning a mix seems even worse than only returning indices (and ignoring items)? Even if we would want to return a mix, it would need to be two separate arrays, as the items are not guaranteed to be integer.

it would need to be two separate arrays, as the items are not guaranteed to be integer
Right, sorry, bad idea on my part.  Thank you for exploring the idea though!

Also scratch the idea about preventing construction of empty trees, for the reasons you provided.

Any more comments on this? (cc @sgillies @mwtoews)
Otherwise I will fix up the docstring examples, and would like to get this merged.

I had one proposal for “nearest” in the case of missing  inputs or trees. Instead of raising directly, you could also return an index that is out of bounds (latest + 1)
This happens also for instance when using “np.searchsorted”.
It may be useful also to implement the version of “nearest” that returns geometries.

@jorisvandenbossche I left a bunch of comments inline. I feel like the first sentences in some docstrings regressed a bit and the predicate needs to be explained a little better. But generally, this is looking food.

The case of storing indexes is a specialization

It's actually the items that is the special case, as by default (when only passing geometries to the STRtree contructor) it are indexes that get returned.

I had one proposal for “nearest” in the case of missing inputs or trees. Instead of raising directly, you could also return an index that is out of bounds (latest + 1)
This happens also for instance when using “np.searchsorted”.

@caspervdw I think for the "nearest" purpose, that might be annoying to work with afterwards. You could typically use the return value as an index to get the corresponding geometry (or attributes corresponding to that geometry), and then an out of bounds index will error (so you would also have to explicitly check for that).
A difference with np.searchsorted is that this functions gives an index where the element would need to be inserted to keep order, so to expand the original array. So if you search for an element that would be added at the end (or missing / np.nan would also get added at the end), you get an "out of bounds" +1 index. But here that's expected, since the original array will grow (the return value of np.searchsorted is not expected to be usable as scalar index into the original array).

(gentle ping to get some responses to some of the comments/answers)

Probably unrelated to your discussion but of interest to me. In pygeos query_bulk works on the polygons, while in shapely it worked on the envelope. What is the plan for the new API?
tree = pygeos.STRtree(points_pygeos)
a, b = tree.query_bulk(poly_pygeos, predicate="contains")

@mathause The query against the underlying tree always uses the envelope of the geometries.  Only the optional predicate test involves the actual geometries.  The new API here for the bulk case is the same as for PyGEOS.

I had one proposal for “nearest” in the case of missing inputs or trees. Instead of raising directly, you could also return an index that is out of bounds (latest + 1)
This happens also for instance when using “np.searchsorted”.

@caspervdw I think for the "nearest" purpose, that might be annoying to work with afterwards. You could typically use the return value as an index to get the corresponding geometry (or attributes corresponding to that geometry), and then an out of bounds index will error (so you would also have to explicitly check for that).

True, but getting an error or a None (unexpected return type) would also be annoying. Returning index + 1 does give the additional option to substitute those values with None / NaN when transforming indices to geometries. In that way, None input may result in None output when querying the tree for nearest geometries.

@jorisvandenbossche I disagree with what you say in

It's actually the items that is the special case, as by default (when only passing geometries to the STRtree contructor) it are indexes that get returned.

I think the awkward situation we're in is only an accident. Let's not get hung up on it now, though. I'm happy with the PR and will suggest changes later.

I updated this PR (addressed part of the feedback + fixed the conflicts).
The docstring examples are not yet fully updated, but if we are not yet fully sure about the final API, I would prefer waiting with fixing those (all other docstrings from functions merged from pygeos still need to be updated as well anyway).

True, but getting an error or a None (unexpected return type) would also be annoying. Returning index + 1 does give the additional option to substitute those values with None / NaN when transforming indices to geometries. In that way, None input may result in None output when querying the tree for nearest geometries.

@caspervdw yes, I see your point, that could indeed be useful. My main worry is that this is a rather advanced feature and it would easily give silent errors for users not aware of it returning this index + 1 number (while an error is then the "safer", less surprising default). Although it will maybe most of the time give some loud error? (if you use it for indexing, both with numpy, python list, or pandas Series, you will get errors)

I think the awkward situation we're in is only an accident. Let's not get hung up on it now, though. I'm happy with the PR and will suggest changes later.

@sgillies That sounds good for this PR. Looking forward to hear your further thoughts on the API / wording.

I am planning to merge this shortly (but anyway we can continue the discussion in follow-up issues where needed)

I opened two follow-up issues for the items that were still being discussed above:

https://github.com/shapely/shapely/issues/1386
https://github.com/shapely/shapely/issues/1387


Encrypt Stored URLs, Usernames, Passwords?

Question
Does this add on encrypt its stored URLs, usernames, and passwords? Or are they stored in plaintext? Or else?
Challenge
If the URLs, usernames, and passwords are stored in plaintext, there is a risk that a not authorized person with access to your computer will be able to read anything stored using the add-on. Such as Basic Authentication URL, username and passwords
Suggested Resolution
For stronger security, how about automatically encrypting the add on storage of URLs, usernames, and passwords? This could potentially significantly slow down a not authorized person to access such sensitive data.
Note
Related ticket at https://github.com/krtek4/MultiPass/issues/48

@Francewhoa It seems that username, password and URLs are stored in plaintext in your firefox profil.
See the file<EMAIL_ADDRESS>+1 for encrypted storage of theses data :+1:

+1 for encrypting these values.

Hi. Please move on with the duscussion in main repository. My fork is no longer needed because the add on successfully appeared in Firefox.


Fix ebreak handling

This is regression which missed one change in the PR #8

Thanks for your contribution.


next challenge page code frame visibility

Hi,
I came across a little bug.
As soon as I got a passed test frame and then Ctrl+Enter, the next challenge page, although it loads completely, shifts up one line in my preferred browser, Firefox 67.0b7 (64-bit) (screenshot enclosed). I tested the same in Chrome 73.0.3683.103 (Official Build) (64-bit) and the issue is not present. Also, the issue is not present at all while looping back or forward to throughout the pages that I passed the test, or if I land on the challenge page from curriculum page.
It doesn't seem major, why I posted? Lately, being used with the first line containing a comment, I didn't scroll the page, assuming that there was a comment. Therefore I wrote a function line in duplicate, without being aware it was already written for me, on the first line. It took me a while to figure that out :) Ultimately, the extra curly brace gave me the clue. As such, I decided to let you know about the little bug.
The particular page I encountered the issue is this:
https://learn.freecodecamp.org/javascript-algorithms-and-data-structures/basic-javascript/stand-in-line
Can I can contribute to the fixing of this issue please?
Thank you!

@Emil-Valentin-Toma Can you test this on our beta site.  The beta site has many fixes in place and might have already been taken care of.  Let us know.
Thanks.

Hi @RandellDawson,
I replicated the test and the error is not present on the beta site. The code frame visibility is normal, starting with the first line (screenshot enclosed). Therefore the bug was fixed for this particular setting.
I didn't check other than the two pages necessary for replicating the test sequence. I'd be glad to perform other tests if you wish, as per instructions.
It looks like you going to store the user's solution on the challenge page? That would be very appreciated!
Best regards.

I am going to close this issue for now, since it can not be replicated on the beta site which will soon be moved to production.  Feel free to request it be reopened if you discover any problems after further testing of the beta site.

It looks like you going to store the user's solution on the challenge page? That would be very appreciated!

Not sure what you mean here.  What gives you this indication?

"It looks like you going to store the user's solution on the challenge
page? That would be very appreciated!
Not sure what you mean here. What gives you this indication?"
       On the actual site, as soon as I navigate further to the next

challenge, all the data I wrote (the solution) for the passed challenge is
lost. Should I need to refresh memory - no chance. If I accessed a solved
challenge it will show a bleak fresh challenge.  Good for learning.
However, I noticed that on beta site the solution to challenge is stored
(saved). I was able to access again the solution I wrote, regardless of how
many pages I navigated. That's all, long waited and fixed. Hopefully you'll
preserve this feature on the released version.
On Sun, 14 Apr 2019 at 16:11, Randell Dawson<EMAIL_ADDRESS>wrote:

I am going to close this issue for now, since it can not be replicated on
the beta site which will soon be moved to production. Feel free to request
it be reopened if you discover any problems after further testing of the
beta site.
It looks like you going to store the user's solution on the challenge
page? That would be very appreciated!
Not sure what you mean here. What gives you this indication?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/freeCodeCamp/freeCodeCamp/issues/35836#issuecomment-482994977,
or mute the thread
https://github.com/notifications/unsubscribe-auth/AX6D7mS-yU4aeF32pOysrDuB2wMeDJjSks5vg0UNgaJpZM4ct7fI
.

@Emil-Valentin-Toma If you clear your cache, my guess is you will lose your old solutions as they are not stored on a server anywhere.  The only thing saved is whether or not you have passed the challenge.

I am closing this as it has been decided that it's no longer an issue. Reopen if I am mistaken.


SEARCH_REPORT npl_class: Parsing and Consolidation ?

Hello,
Since v0.2-npl, we have introduced a WEBPAGE npl_class
Question
How should this class of citations be structured and consolidated?
Food for thoughts
Below is a sample of 100 citations for this class.

WITH
  tmp AS (
  SELECT
    npl_publn_id
  FROM
    `npl-parsing.patcit.v02_npl`
  WHERE
    npl_class="SEARCH_REPORT")
SELECT
  npl_biblio
FROM
  `usptobias.patstat.tls214` AS tls214,
  tmp
WHERE
  tmp.npl_publn_id = tls214.npl_publn_id
LIMIT 100

Row | npl_biblio |
-- | -- | --
2 | PCT International Search Report and Written Opinion dated Aug. 29, 2014 for International Application No. PCT/US2014/041698. |
3 | Written Opinion dated Mar. 6, 2008 (5 pages). |
4 | International Search report and Written Opinion for PCT Application PCT/US2010/043935 Search report dated Nov. 16, 2010. |
5 | Examination Report received in connection with corresponding ARIPO Patent Application No. AP/P/2006/003506 (dated Feb. 23, 2010). |
6 | International Search Report [PCT/ISA/210], dated Sep. 9, 2011, issued in Application No. PCT/KR2011/000301. |
7 | International Search Report and Written Opinion for PCT/US2012/051017 dated Oct. 23, 2012. |
8 | International search report and written opinion dated Aug. 9, 2011 for PCT/US2011/031477. |
9 | PCT International Preliminary Report on Patentability (IPRP) for PCT Application PCT/EP2007/009763, dated Sep. 11, 2009, 8 pages. |
10 | International Search Report mailed Mar. 19, 2008 for PCT/KR2007/006881. |
11 | International Search Report and Written Opinion of PCT/US2011/032102 mailed on Oct. 25, 2011, 11 pages. |
12 | European Search Report (App. No. EP09153867.8) dated Sep. 10, 2009. |
13 | JPO Search Report dated Aug. 18, 1998 with English translation of Office Action. |
14 | International Search Report and Written Opinion for PCT/US2013/023889, Applicant: Box, Inc., Mailed Jun. 24, 2013, 13 pages. |
15 | Written Opinion for PCT Application No. PCT/US2010/036630, mailed Sep. 15, 2010, 4 pages. |
16 | International Search Report dated Oct. 26, 2011 issued in PCT Patent Application No. PCT/IL11/00382. |
17 | International Search Report, PCT/EP2012/050927, Dated Jun. 26, 2012. |
18 | European Patent Office, Partial European Search Report for Related EP Application No. 08003713 dated Jul. 3, 2008. |
19 | Int'l Search Report EP 06024123.9 dated Feb. 26, 2007. |
20 | European Communication and Supplementary Search Report for Application No. 05757385.9, dated Aug. 23, 2011 (7 pages). |
21 | International Search Report and Written Opinion for PCT/US2007/011075, mailed Jul. 11, 2008. |
22 | European Search Report (Application No. 05780424.7; PCTEP08110), dated Nov. 23, 2009. |
23 | Extended European Search Report issued Dec. 21, 2016 in European Patent Application No. 14804777.2. |
24 | 'International Application Serial No. PCT/US2016/023063, International Search Report mailed Aug. 12, 2016', 5 pgs. |
25 | Extended European Search Report dated Nov. 16, 2015 from corresponding European Application No. 13761889.8, 8 pages. |
26 | European Search Report for Application No. EP08795684 dated Aug. 6, 2013. |
27 | An EP search report dated Feb. 20, 2015 that issued in EP 12782462.1. |
28 | 'International Search Report and Written Opinion', International Application No. PCT/US2011/055522, (May 15, 2012),9 pages. |
29 | Korean Intellectual Property Office, International Search Report and Written Opinion for International Application No. PCT/KR2004/000481, Jun. 11, 2004. |
30 | Supplementary European Search Report for Application No. EP09821219, mailed on Oct. 2, 2014, 8 pages. |
31 | “International Search Report & Written Opinion”, PCT/US2016/013988, Apr. 8, 2016. |
32 | 'PCT/US2006/025462 Search Report', (Nov. 14, 2006),2 pages. |
33 | The Extended European Search Report corresponding to EP 13 17 2008.8, completed Aug. 14, 2013 and mailed Aug. 28, 2013; (8 Pages). |
34 | PCT International Search Report Application No. PCT/US2007/083520, dated Mar. 25, 2008. |
35 | Intl Searching Authority, Notification of Transmittal of the Intl Search Report, PCT/US2007/007945, dated Aug. 17, 2007. |
36 | Extended European Search Report issued Apr. 20, 2011, in Patent Application No. 08841628.4. |
37 | International Search Report PCT/IB2005/003242, Feb. 22, 2006. |
38 | PCT International Search Report received in Corresponding PCT Application No. PCT/US2006/031523 dated Feb. 27, 2007. |
39 | PCT International Search Report and Written Opinion dated Aug. 4, 2005 for Application No. PCT/US04/25891 (5 pages). |
40 | International Search Report and Written Opinion for related PCT Application PCT/US2010/000412, mailed Sep. 29, 2010 (12 pgs.). |
41 | International Preliminary Report on Patentability issued Oct. 2, 2012 in co-pending PCT application No. PCT/JP2011/054942. |
42 | Transmittal of International Preliminary Report on Patentability and Written Opinion of the International Searching Authority for International Application No. PCT/US2012/046139, Jan. 30, 2014, 11 pages. |
43 | Supplementary European Search Report and the European Search Opinion Dated Jul. 23, 2010 From the European Patent Office Re. Application No. 06766237.9. |
44 | I European Search Report for priority application EP 13181518.5 dated Dec. 12, 2013. |
45 | International Search Report and Written Opinion for PCT/US2013/065403, mailed Feb. 5, 2014, 11 pages. |
46 | International Search Report and Written Opinion—PCT/US2013/065993—ISA/EPO—Jan. 13, 2015. |
47 | Australian Examination Report No. 3, Application No.<PHONE_NUMBER> dated Jan. 9, 2013. |
48 | European Search Report dated Dec. 6, 2010 in European Application No. 10154705.7. |
49 | European Search Report EP 09166708 dated Oct. 15, 2009. |
50 | International Search Report and Written Opinion of PCT/US2012/051984 mailed Nov. 5, 2012, 13 pages. |
51 | International Application No. PCT/US2009/033823, International Search Report and Written Opinion, Sep. 24, 2009. |
52 | International Preliminary Report on Patentability for Application No. PCT/US2008/051339, dated Jul. 30, 2009, 8 pages. |
53 | European Search Report No. 114400, Apr. 18, 2007, 3 pages. |
54 | Written Opinion for PCT/EP2006/012153; Published on Aug. 2, 2008. |
55 | International Search Report issued May 1, 2007 in the International (PCT) Application of which the present application is the U.S. National Stage. |
56 | International Report on Patentability issued in PCT/JP2005/009699, Nov. 21, 2006. |
57 | Extended European Search Report dated Mar. 11, 2008. |
58 | The extended European Search Report corresponding to European Application No. EP 09252050.1, completed Dec. 23, 2009; mailed Jan. 21, 2010; (3 Pages). |
59 | PCT Notification of Transmittal of the International Search Report or the Declaration, mailed Aug. 27, 2001. |
60 | Australian First Examination Report dated Apr. 30, 2012 issued in corresponding AU Application No. 2012-200706 (2 pages). |
61 | Noble et al., Predicting Grades in Specific College Freshman Courses from ACT Test Scores and Self-Reported High School Grades. ACT Research Report Series, 87-20. November 1987 |
62 | Communication Relating to the Results of the Partial International Search Dated Nov. 27, 2007 From the International Searching Authority Re.: Application No. PCT/IL2007/000903. |
63 | 'International Application Serial No. PCT/US2008/01135, Written Opinion mailed Oct. 9, 2008', 6 pgs. |
64 | PCT International Search Report for PCT/KR2011001953 dated Nov. 2, 2011. 7 pages. |
65 | International Search Report for International Application No. PCT/JP2011/070534, dated Dec. 6, 2011, 10 pages. |
66 | European Patent Office, European Search Report, issued in connection with European Patent Application No. 10006554.9, dated Jul. 11, 2012. (10 pages). |
67 | International Patent Examination Report for PCT/US07/10109 dated Jun. 18, 2009. |
68 | PCT International Search Report dated Dec. 16, 2010 issued in Application No. PCT/KR2010/003684. |
69 | International Search Report and Written Opinion mailed Aug. 15, 2008 in the International (PCT) Application No. PCT/US08/64911. |
70 | International Search Report and Written Opinion date mailed Dec. 23, 2009; PCT International Application No. PCT/US2009/057428. |
71 | International Search Report for corresponding International Application No. PCT/EP2008/050054, filed Apr. 1, 2008. |
72 | U.S. Appl. No. 13/244,739, Examiner Interview Summary mailed Feb. 7, 2012, 8 pgs. |
73 | Extended European Search Report dated Oct. 18, 2016 in European Application No. 09820687.3. |
74 | International Search Report from PCT application No. PCT/US2015/016515, dated Apr. 16, 2015, 10 pgs. |
75 | European Search Report for Application No. 12875245.8 mailed Dec. 15, 2015. |
76 | International Search Report and Written Opinion of the International Searching Authority in International Application PCT/US2008/073603, US Patent Office, Nov. 17, 2008, 7 pages. |
77 | European Search Report, dated Aug. 28, 2000. |
78 | Copy of the International Search Report for PCT/FI97/00525. |
79 | Int'l Search Report in Application No. PCT/DE03/03274, dated Apr. 2, 2004. |
80 | German Search Report dated Oct. 23, 2000 (and translation thereof). |
81 | International Search Report for PCT/US04/06696, 1 page, Omniture, Inc., Brett Error, et al., mailed Feb. 28, 2005. |
82 | International Search Report for PCT/EP2011/072286, dated Mar. 19, 2012. |
83 | Extended European Search Report in PCT/US2008/012970 dated Oct. 22, 2014. 9 pages. |
84 | PCT International Search Report for PCT/US2013/33373 dated Mar. 21, 2013, 2 pages. |
85 | International Preliminary Report on Patentability and Written Opinion mailed Oct. 10, 2013 in corresponding International Patent Application No. PCT/EP2012/052984. |
86 | International Search Report for PCT/CN2011/072965, mailed Feb. 16, 2012, 3 pages. |
87 | International Preliminary Report on Patentability, May 11, 2010, PCT/US2008/82505. |
88 | Extended European Search Report issued in European Patent Application No. 10002938.8 on Feb. 9, 2011. |
89 | International Preliminary Report on Patentability in Parent Application PCT/US06/46099, dated Jun. 10, 2009, 5 pages. |
90 | Int'l Search Report EP 98944778 dated Oct. 31, 2000. |
91 | International Search Report mailed Oct. 18, 2005 in International (PCT) Application No. PCT/JP2005/013113. |
92 | U.K. Search Report dated Sep. 12, 1997; Serial No. GB 9713687.3. |
93 | European Search Report of application No. EP99110137, which sites patents pertinent to the above-mentioned application. |
94 | International Search Report of corresponding PCT Application No. PCT/JP2010/001994. |
95 | Search Report corresponding to GB 1121447.5, dated Apr. 13, 2012. |
96 | International Preliminary Report on Patentability dated Apr. 27, 2010 for Application No. PCT/JP2010/002319. |
97 | International Search Report for PCT/US2011/029506 mailed Aug. 2, 2011. |
98 | Australian Examiner's First Report dated Feb. 15, 2011 issued in AU<PHONE_NUMBER>. |
99 | International Search Report for PCT Application No. PCT/US01/26505 dated Feb. 14, 2002. |
100 | Int'l Search Report EP 04027479.7 dated Mar. 8, 2005.

Open questions

Need for further sub-classification? If yes, which sub-classes?
Fields to be parsed?
Corpus/ reference database for consolidation?

I leave these questions open to discussion.
Cheers

Some ideas:

cat: search report, written opinion, communication ... Nb: search report and written opinion are not exclusive
patent: patent under review and related metadata (from grobid patent schema)
date: year


Etap 2

[ ] Starting point

[ ] text is in C#
[ ] all UT are green
[ ] the program behaves as expected (intermediate approval test)

[ ] Data Layer

[ ] responsibility of this layer is to represent boundaries of the movement rectangle and balls
[ ] balls representation are independent and self-contained (no timer required)
[ ] balls implementation uses concurrent programming

[ ] Logic Layer

[ ] responsibility of this layer is to manage movement rectangle boundaries and balls interaction (collisions)
[ ] prove that the protection  of data integration is implemented
[ ] Logic uses only the abstract Data layer API

[ ] Presentation Layer (MVVM)

[ ] responsibility of this layer is to manage the graphical user interface (GUI)
[ ] user => GUI interoperability must be implemented using interactive programming only
[ ] GUI => the user interoperability must be implemented using reactive programming only (timer is not allowed)
[ ] interoperability of the GUI and underlying layers must be synchronized

[ ] Fulfill functional requirements of the task
[ ] Testing

[ ] Unit Test - layers are tested independently using dependency injection (additional framework is not required)
[ ] Mock may be used for testing purposes (expected but not required)

dodatkowo (ale obligatoryjnie):

[ ] dodać zegar dla każdej kuli, aby była osobnym wątkiem


PR : ChocoSolver

Issue with Pythonnet

AssertionError: The expression with operator + is badly formed: None+1


ci: failed test since pr 3087

Is there an existing issue for this?

[X] I have searched the existing issues

What happened?
Elixir Mix test failed since #3087
@brianmaand @DrMichael please either revert or fix the test
I thought it was a caching issue at first, but after deleting all caches the problem persists.
Expected Behavior
CI Test success
Steps To Reproduce
see runner output
Relevant log output
First fail on master is this PR, see this runner output: https://github.com/teslamate-org/teslamate/actions/runs/6892784984
Last success was this runner https://github.com/teslamate-org/teslamate/actions/runs/6887784700 for PR #2840
Screenshots
n.a.
Additional data
n.a.
Type of installation
Docker
Version
v1.24.4

cc @jlestel

Hm, the behavior is strange, because the runner reported success before, even if it failed: https://github.com/teslamate-org/teslamate/actions/runs/6887784700/job/18735559815#step:11:10 but that was not in the test, but in the coverage step, which does not make sense here.

I've seen the coverage error: (ExCoveralls.ReportUploadError) Failed to upload the report to 'https://coveralls.io' (reason: status_code = 422, body = {"message":"Couldn't find a repository matching this job.","error":true}).
It seems that the repository no longer exists in coveralls.io and that's why it fails every time he wants to update it.
Could it be related to organizational change?

Yeah oberserved that as well, but is not related to failed elixir test cases

cc @jlestel

Il me semble que c'est plutôt le repository qui a été supprimé sur coveralls ?

Yeah oberserved that as well, but is not related to failed elixir test cases

I think that if, at the end of the Elixir check, the coverage is updated.
Until CI can't update it, it returns exit 1.

To simply test, you can deactivate coverage.

As continue-on-error: truefor the coverage the tests with failed coverage still report as success.
It is strange sometimes the failed elixir test cases are only shown in coverage, so will test it.

Hmmm... Failures seem linked with this PR? It's really related to the piece of code that was modified https://github.com/teslamate-org/teslamate/pull/3087

Yeah, so introducing new things to vehicle summary without updating test cases

Disabling Coverage did not solve it, as expected, see https://github.com/teslamate-org/teslamate/actions/runs/6933555983/job/18859928226?pr=3467

Rerunning the failed job solved it as well. So probably should avoid caching the test dependencies for the moment.

I reverted #3087 and restored ci.
Please open new PR for vehiclesummary @brianmay


UTXO Bubbles Zoom Improvements

Show only the labels if zoomed radius (scale * radius) is more than 100.
Fix flickering when double tapping (caveat: single tapping will have a slight delay)

Performance improvements

Put useFonts on the parent instead of loading the fonts on each bubble.
Memoize frequently render function

@umarluqman can you fix conflicts?
apps/mobile/app/accountList/account/[id]/signAndSend/selectUtxoBubbles.tsx
should now be
apps/mobile/app/account/[id]/signAndSend/selectUtxoBubbles.tsx


[Bug Report] el-radio & el-checkbox can't be checked in dynamic component

Element UI version
2.15.1
OS/Browsers version
win10/chrome
Vue version
2.6.12
Reproduction Link
https://codepen.io/wuceyang/pen/ZELWxMV
Steps to reproduce
About Project: the project is a free-design form page, and I use these element-ui components in my custom component.
About Issue: when i use vue.extend and $mount to create component on my page, these element-ui components can't be checked by click.event though i copied the official example code to the custom component,they won't work.
项目描述:项目主要功能是使用拖拽式来设计表单，我把el-radio(-group)和el-checkbox(-group)封装到自定义组件中。
问题描述：当我使用vue.extend的方式在页面创建自定义组件时，其中的这俩(radio和checkbox)组件无法被选中，即使将相关的官方示例代码复制到自定义组件中也无法正常选中.
What is Expected?
they can be checked correctly by click
What is actually happening?
they can't be checked correctly by click

it's my fault, there is a click handle with prevent modifier on the wraper element. when removed, they work correctly


Spring AAD - Support web-application and resource-server in one application

#21450
#21451

Closing this issue, Use this one instead: https://github.com/Azure/azure-sdk-for-java/issues/19816


RateMyProfessor

When you click on a class you get a list of all the professors that have taught the class recently. Then we can fetch data from RateMyProfessor and display the average score for each professor. We can also have a button or something that would link to that professor's page so a user can read the comments.

Might mess with the rate my professor api over break. i think it would be really easy to just iterate through every class and iterate through every professor and call their lil score fetcher. 😎

unironically looking at this now. i will assign myself to it to show my dedication


MINOR: Fix ThrottledReplicaListValidator doc error.

More detailed description of your change,
if necessary. The PR title and PR message become
the squashed commit message, so use a separate
comment to ping reviewers.
Summary of testing strategy (including rationale)
for the feature or bug fix. Unit and/or integration
tests are expected for any behaviour change and
system tests should be considered for larger changes.
Committer Checklist (excluded from commit message)

[ ] Verify design and implementation
[ ] Verify test coverage and CI build status
[ ] Verify documentation (including upgrade notes)

@ijuma Please review this minor change. Thanks.

@omkreddy Please review this minor patch. Thanks.

retest this please

retest this please


UI layout updates

Some suggested UI updates, comparing previous (L) and current (R) versions:

[x] Model parameters should be open by default
[ ] "Run" button should be visible at bottom of the left sidebar even when sections are open
[ ] For narrow screens, sidebar should be wider -- resumably with wide screens users would want to see both at the same time, but for narrow screens they'd switch back and forth
[ ] Might feel more app-like and less like a webpage if header and footer were always visible (then again, it does waste screen real estate)

If the header and footer persisted (i.e. the scrolling happened inside the graphs div instead), then something like the previous sidebar layout might be workable. The sidebar and the graphs should scroll independently since you might want to keep looking at a graph as you adjust the parameters.

E.g. the UX here would be improved by being able to see both the run button and the graphs:

Blocked by #202 and #194.

Closing for now since UI needs major overhaul


Ionhashtest

Issue #, if available:
Description of changes:
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

One stylistic thing......when we're asserting a function with a single return value, I prefer to put that function call in the assert itself.
ie.
assert.NoError(t, reader.StepIn(), "Something went wrong executing reader.StepIn()")
instead of
err := reader.StepIn()
assert.NoError(t, err, "Something went wrong executing reader.StepIn()")

One stylistic thing......when we're asserting a function with a single return value, I prefer to put that function call in the assert itself.
ie.
assert.NoError(t, reader.StepIn(), "Something went wrong executing reader.StepIn()")
instead of
err := reader.StepIn()
assert.NoError(t, err, "Something went wrong executing reader.StepIn()")

Addressed


Add compilation property

Description
Exposes the compilation_time attribute as a property of the Problem. I wanted to be able to access this programmatically in a project I was working on.
Type of change

[x] New feature (backwards compatible)
[ ] New feature (breaking API changes)
[ ] Bug fix
[ ] Other (Documentation, CI, ...)

Contribution checklist

[ ] Add our license to new files.
[x] Check that your code adheres to our coding style.
[x] Write unittests.
[x] Run the unittests and check that they’re passing.
[x] Run the benchmarks to make sure your change doesn’t introduce a regression.

 Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.You have signed the CLA already but the status is still pending? Let us recheck it.

This sort of thing is supposed to go in problem.solver_stats. It might already be there.

This sort of thing is supposed to go in problem.solver_stats. It might already be there.

I don't believe this is currently available from problem.solver_stats.
I did originally consider adding the compilation time to problem.solver_stats, but it is not strictly a property of the solver itself, so I thought it didn't really "belong" there. However, I'm happy to put it there instead.

This sort of thing is supposed to go in problem.solver_stats. It might already be there.

I don't believe this is currently available from problem.solver_stats.
I did originally consider adding the compilation time to problem.solver_stats, but it is not strictly a property of the solver itself, so I thought it didn't really "belong" there. However, I'm happy to put it there instead.

That's fair, but compilation time does depend on which solver is targeted, so I'd still put it in solver_stats.

I didn't realize that _compilation_time is something we already record and you're just exposing it. No need to move it to solver_stats.

Thanks @alxhslm !


Removed renderer status

null
Microsoft Reviewers: Open in CodeFlow

Docs Build status updates of commit d9dffe6:
:warning: Validation status: warnings

File
Status
Preview URL
Details

AdaptiveCards/toc.yml
:warning:Warning

Details

AdaptiveCards/rendering-cards/renderer-status.md
:white_check_mark:Succeeded

AdaptiveCards/toc.yml

Line 35, Column 11: [Warning-file-not-found] Invalid file link: 'rendering-cards/renderer-status.md'.

For more details, please refer to the build report.
If you see build warnings/errors with permission issues, it might be due to single sign-on (SSO) enabled on Microsoft's GitHub organizations. Please follow instructions here to re-authorize your GitHub account to Docs Build.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
Note: Your PR may contain errors or warnings unrelated to the files you changed. This happens when external dependencies like GitHub alias, Microsoft alias, cross repo links are updated. Please use these instructions to resolve them.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

Docs Build status updates of commit 572c2bf:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

AdaptiveCards/rendering-cards/renderer-status.md
:white_check_mark:Succeeded

AdaptiveCards/toc.yml
:white_check_mark:Succeeded

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

Docs Build status updates of commit 0fdee2f:
:warning: Validation status: warnings

File
Status
Preview URL
Details

AdaptiveCards/rendering-cards/actions.md
:warning:Warning

Details

AdaptiveCards/rendering-cards/renderer-status.md
:white_check_mark:Succeeded

AdaptiveCards/toc.yml
:white_check_mark:Succeeded

AdaptiveCards/rendering-cards/actions.md

Line 17, Column 152: [Warning-hard-coded-locale] Link 'https://docs.microsoft.com/en-us/adaptive-cards/authoring-cards/universal-action-model' contains locale code 'en-us'. For localizability, remove 'en-us' from links to most Microsoft sites.
Line 2, Column 1: [Suggestion-description-missing] Missing required attribute: 'description'.
Line 17, Column 152: [Suggestion-docs-link-absolute] Absolute link 'https://docs.microsoft.com/en-us/adaptive-cards/authoring-cards/universal-action-model' will be broken in isolated environments. Replace with a relative link.

For more details, please refer to the build report.
If you see build warnings/errors with permission issues, it might be due to single sign-on (SSO) enabled on Microsoft's GitHub organizations. Please follow instructions here to re-authorize your GitHub account to Docs Build.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
Note: Your PR may contain errors or warnings unrelated to the files you changed. This happens when external dependencies like GitHub alias, Microsoft alias, cross repo links are updated. Please use these instructions to resolve them.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel

Docs Build status updates of commit 497ea7d:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

AdaptiveCards/rendering-cards/actions.md
:bulb:Suggestion

Details

AdaptiveCards/rendering-cards/renderer-status.md
:white_check_mark:Succeeded

AdaptiveCards/toc.yml
:white_check_mark:Succeeded

AdaptiveCards/rendering-cards/actions.md

Line 2, Column 1: [Suggestion-description-missing] Missing required attribute: 'description'.
Line 17, Column 152: [Suggestion-docs-link-absolute] Absolute link 'https://docs.microsoft.com/adaptive-cards/authoring-cards/universal-action-model' will be broken in isolated environments. Replace with a relative link.

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching the docs.microsoft.com contributor guidesPost your question in the Docs support channel


fix: 'No content to add' error if we send empty alias for email

Fixed Issues
$ https://github.com/Expensify/App/issues/21234
Tests

Go to a chat and add following comment

<EMAIL_ADDRESS>[<EMAIL_ADDRESS>[

<EMAIL_ADDRESS>

Verify that
a. Only emails inside () are parsed as email link
b. [], () and spaces(including line break) inside [] are not parsed
Click to edit the comment
Verify that the initial draft is same as the original input.

See below demo video
https://github.com/Expensify/expensify-common/assets/117511920/82b49d50-067b-4299-a3e7-dea2a3ab0928
I'll fill out the full checklist in the PR to update version of App repo.
QA
Same as test

Tagging @parasharrajat here! (can't assign you as a reviewer, apparently)


Smol Hatching mod compatibility

Please describe your request.
It would be cool to make owo and sh compatible
Additional details.
Perhaps you should make it so that owo will synchronize the scale of the player only if it is less than, for example, 15? Maybe that doesn't make sense, but it's just an idea.

Hmm could be cool, but I imagine rather confusing for some players when others around them appear smol with no explanation. Although, that may not matter


vite_react_refresh_tag does not respect base setting

Description 📖
The script module appended by the vite_react_refresh_tag does not consider the base setting in the react preamble code.
Reproduction 🐞

Start with the rails example app
Add the following to config/environments/development.rbconfig.relative_url_root = '/sub'
config.action_controller.relative_url_root = '/sub'

Map the subpath in your config.rurequire_relative 'config/environment'

map '/sub' do
  run Rails.application
  Rails.application.load_server
end

Add base setting to config/vite.json{
  "all": {
    "base": "/sub",
    ...
  }
}

Now run the app in development mode with the /sub path loaded in the browser.

The appended module script will look something like so:
<script type="module">
//<![CDATA[
import RefreshRuntime from '/vite-dev/@react-refresh'
RefreshRuntime.injectIntoGlobalHook(window)
// ...
//]]>
</script>

This leads to a 404 error on the import. The correct import path should be.
<script type="module">
//<![CDATA[
import RefreshRuntime from '/sub/vite-dev/@react-refresh'
RefreshRuntime.injectIntoGlobalHook(window)
// ...
//]]>
</script>

I verified that navigating the correct path returns the module source as expected.
The prefix_asset_with_host method at vite_ruby/manifest.rb#L144 appears to be the issue at first glance. I might be able to use the assetHost setting, but setting it to /sub broke the other imports. Configuring the entire host URL would work, but it is undesirable.
Could config.base be included in this join as well? If desired, I could submit a PR with a test case.

Hi Aaron, thanks for reporting.
Can you confirm if the following patch fixes the issue in your scenario:
  # Internal: Prefixes an asset with the `asset_host` for tags that do not use
  # the framework tag helpers.
  def prefix_asset_with_host(path)
    File.join(vite_asset_origin || config.asset_host || "/", config.base, config.public_output_dir, path)
  end


renamed postData as data, allowed for method to equal put

@justincdalton @donovanm @cliu4151

:+1:


Write '*' as 'wildcard' on the filesystem

We wanted to use minica to issue some wildcard self-signed certificates on our Windows machine, but ran into the issue that Windows doesn't support a '*' character on it's filesystem.
This patch ensures that folders created with the char '*' are written out as 'wildcard'.
Not a go developer so unsure if this is the best approach :)

Should be _, not "wildcard" imho

@tox2ik agreed, thanks for the feedback!

Thanks so much for the patch! I had been meaning to get back to you on this with the feedback that "wildcard" didn't feel right, but I was stuck on proposing a better alternative. _ works great, thanks @tox2ik.


Use nginx:1.25.2 in node k8st tests

Description
The k8s system tests were using nginx v1.7.9, which was published in 2015 and segfaults on Azure Linux. This commit replaces all hard-coded references to the version with utils.NGINX_IMAGE (overridable with an env var if necessary) and updates the default version to 1.25.2.

/sem-approve

Gave the tests a re-run, as it looked like some had failed. Hopefully a flake and not a consequence.


Create the option to pass in kms key ARN for config logs bucket

Signed-off-by: Ivan Dechovski<EMAIL_ADDRESS>Changes proposed in this pull request:
Allow passing in the KMS key ARN used to encrypt objects delivered by AWS Config to the target bucket. The option is already available in the terraform resource, this PR just allows it to be configured by the module.

@esacteksab Would you perhaps have some time to review this change? Thanks in advance!

@esacteksab Would you perhaps have some time to review this change? Thanks in advance!

Apologies for missing this. What's the behavior with this if the value isn't set? Basically I'm wondering if this needs to be a bool to enable or disable setting this ARN. If this is not the case, this LGTM and I'm happy to merge this and publish a new release.

@esacteksab Would you perhaps have some time to review this change? Thanks in advance!

Apologies for missing this. What's the behavior with this if the value isn't set? Basically I'm wondering if this needs to be a bool to enable or disable setting this ARN. If this is not the case, this LGTM and I'm happy to merge this and publish a new release.

No problem at all. Default is null so the argument is omitted if variable is not passed. The argument itself is a an optional string which has to be the ARN of a key so either we pass it in or we omit as we don't want anything set.
A bool would be useful if other resources need to be created for this to work but I don't think we need any. This is based on the assumption that when you create a bucket and it's KMS key, that will be managed outside the module and then we just pass in the key in here.

Thank you for this, this has been released in 5.2.0


Update New-CsVideoInteropServiceProvider.md

Update the cmdlet document with accurate descriptions

Docs Build status updates of commit 693d3af:
:clock10: Full build: the average full build time is 11 min(s) 51 sec(s), this is based on the last 1000 build(s) for this repository.

Docs Build status updates of commit 693d3af:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

skype/skype-ps/skype/New-CsVideoInteropServiceProvider.md
:white_check_mark:Succeeded
View (skype-ps)

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.

Docs Build status updates of commit d04176f:
:clock10: Full build: the average full build time is 11 min(s) 52 sec(s), this is based on the last 1000 build(s) for this repository.

Docs Build status updates of commit d04176f:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

skype/skype-ps/skype/New-CsVideoInteropServiceProvider.md
:white_check_mark:Succeeded
View (skype-ps)

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.

Docs Build status updates of commit 47bb5cb:
:clock10: Full build: the average full build time is 11 min(s) 54 sec(s), this is based on the last 1000 build(s) for this repository.

Docs Build status updates of commit 47bb5cb:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

skype/skype-ps/skype/New-CsVideoInteropServiceProvider.md
:white_check_mark:Succeeded
View (skype-ps)

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.


Not compatible with bourbon v5

Looks like bourbon is working on releasing v5 and they renamed the font stack variables to be prefixed with $font-stack (ie $font-stack-helvetica). See thoughtbot/bourbon@4e92369. There is currently no constraint on the bourbon dependency in the thredded gemspec, so it will allow installing v5.
It's possible there's other incompatibilities too, this is just the first I saw based on the failing builds for my recent PRs (#151, #152, #153).

Resolved with 368c35c4.


Make consistent configuration of Kafka event source and channel

Expected Behavior
When I have configured Kafka brokers I expect I can reuse the configuration for Kafka sources and channels.
Ideal behavior would be to allow reuse of existing Kafka operators that make Kafka available inside kubernetes cluster. That means developer or system integrator need to do error prone copying and pasting and sometimes translation between different configuration formats.
Persona:
Which persona is this feature for? Event consumer (developer), Event producer, System Integrator
Actual Behavior
Configuration is very different and it is not consistent. Moreover some aspects can be configured only for source and not for channel (and maybe vice versa)
Exit Criteria
The same configuration can be re-used for Kafka event source and channel.
Investigate and document inconsistencies with Kafka operators.
Steps to Reproduce the Problem

Configure Kafka broker or use of Kafka operators (for example https://operatorhub.io/?keyword=kafka or https://github.com/IBM/event-streams-topic#example )
Configure Kafka source -  follow https://knative.dev/development/eventing/samples/kafka/source/
Configure Kafka channel - follow https://knative.dev/development/eventing/samples/kafka/channel/
Compare configuration artifacts created in previous steps

Additional Info
For example inconsistencies reported see https://github.com/knative/eventing-contrib/issues/323 and https://github.com/knative/eventing-contrib/issues/643

And maybe have one controller for both Kafka channel and source? https://github.com/knative/eventing-contrib/issues/533

the consumer part is already reused, and yes, happy to make the channel cfg like the source ones

@matzew @lionelvillard I have written down current state of how Knative/Kubernetes Kafka configuration is done and started on proposal for improvements - please edit it and comment: https://docs.google.com/document/d/1PLYm8amLRKmKK5FAo_34ZOKwTbYU9ooMjrjwkiPc7qA/edit?usp=sharing

Thank you for your comments @matzew - I added replies and first stab on what could be shared config map / secret

@matzew @lberk @lionelvillard I investigated options for Kafka configuration and what is used today within Apache Kafka and docker images. So if there are already Kafka configurations we should make it easy to use them in Knative without any changes. What I propose is to use Apache Kafka property names directly and allow to override them with well defined list of environment variables - started writing it down in https://docs.google.com/document/d/1PLYm8amLRKmKK5FAo_34ZOKwTbYU9ooMjrjwkiPc7qA/edit#
Please let me know what you think and add your comments.

Reading through @aslom's proposal, I thought I'd have a go at drawing up a straw man of what the configuration could look like. Here's where I got to:
apiVersion: sources.eventing.knative.dev/v1alpha1
kind: KafkaSource
metadata:
  name: my-kafka-source
spec:
  specFrom:
    configMapRef: kafka-cluster-config
  group.id: consumer-group-id
  topics: topic1,topic2
---
apiVersion: messaging.knative.dev/v1alpha1
kind: KafkaChannel
metadata:
  name: my-kafka-channel
spec:
  specFrom:
    configMapRef: kafka-cluster-config
---
apiVersion: v1
kind: ConfigMap
metadata:
  name: kafka-cluster-config
data:
  bootstrap.servers: broker-0:9093,broker-1:9093,broker-2:9093
  security.protocol: sasl_ssl
  sasl.mechanisms:  PLAIN
  sasl.username:
    secretKeyRef:
      name: kafka-creds-secret
        key:    user
    sasl.password:
      secretKeyRef:
        name: kafka-creds-secret
        key:    password

In addition to renaming the configuration properties to match the equivalent Kafka broker / consumer / producer properties, I have tried to find a way that the source and channel can share a set of common configuration. Kubernetes pods can share a common set of environment variables using a envFrom and configMapRef - for example:
containers:
  - envFrom:
      - configMapRef:
          name: common-env

I've tried to adapt this with specFrom and configMapRef which would have the semantic of merging the contents of a config map with the other properties specified under spec. AFAIK pods don't support an analogous merging of referenced config and inline config, so this would be a difference in behaviour. There's also the potential for the same property name (but with different values) to appear in both places, for which there would need to be a precedence rule.
You might have also noticed that I've deviated from the Kafka Java client property names for SASL. That's because the Java version looks something like this:
sasl.jaas.config=org.apache.kafka.common.security.plain.PlainLoginModule required username="user123" password="passw0rd";

Which is heavily influenced by the format of Java's JVM Config Login File. Instead, I was inspired by the librdkafka configuration which seems a bit more platform agnostic.
Finally, in addition to using secretKeyRef for referencing the SASL username and passwords, I think bootstrap.servers (and possibly other properties) should also support indirection via secretKeyRef and configMapKeyRef. This would allow interoperation with the various Kubernetes operators that provision Kafka and use their own formats for storing data about the provisioned Kafka cluster in secrets or config maps.

Hmmn. Configmaps are key/value pairs, and therefore cannot contain the structure of a secretRef. That's a shame. Using a custom resource for the shared config is a less attractive option.

@prestona it would be nice but it seems no  support for it forthcoming :( https://github.com/kubernetes/kubernetes/issues/79224

@aslom any progress?

@lionelvillard - well, I think we've ruled out one potential approach :smile:
Mulling this over, I can think of two alternate approaches that we could take:
Option 1
Implement something similar to my comment, here, but using a CR rather than a config map for the common configuration. I don't really like this approach, as I can't point at another example where this has been done. There's also the question of what to do if the same configuration property is present in, say, both the source resource and this custom configuration resource - for example:
apiVersion: sources.eventing.knative.dev/v1alpha1
kind: KafkaSource
metadata:
  name: my-kafka-source
spec:
  specFrom:
    kafkaCommonRef: kafka-cluster-config
  security.protocol: ssl                # duplicated in KafkaCommon CR
  group.id: consumer-group-id
  topics: topic1,topic2
---
apiVersion: sources.eventing.knative.dev/v1alpha1
kind: KafkaCommon
metadata:
  name: kafka-cluster-config
data:
  bootstrap.servers: broker-0:9093,broker-1:9093,broker-2:9093
  security.protocol: sasl_ssl          # duplicated in KafkaSource
  sasl.mechanisms: PLAIN
  # etc. etc.

In this case, which value of security.protocol do we use? Again, I haven't come across resources which have an order of precedence. So I wonder if this will surprise users, and be difficult to debug if the duplication is introduced by accident.
Option 2
Move away from trying to store common configuration in one resource and allow individual properties of the Kafka source / channel to reference configuration properties from a config map or secret. As a starting point, we could require sasl.username and sasl.password to be a secretKeyRef and allow bootstrap.servers to either be a string literal, a configMapRef or a secretKeyRef. In the future, we might want to extend this to having more configuration properties supporting indirection.
For example:
apiVersion: sources.eventing.knative.dev/v1alpha1
kind: KafkaSource
metadata:
  name: my-kafka-source
spec:
  bootstrap.servers:
    configMapKeyRef:          # point to common configuration
      name:  kafka-cluster-config
      key: bootstrap.servers
  security.protocol: sasl_ssl
  sasl.mechanisms: PLAIN
  sasl.username:
    secretKeyRef:
      name: kafka-creds-secret
      key: user
  sasl.password:
    secretKeyRef:
      name: kafka-creds-secret
      key: password
  group.id: consumer-group-id
  topics: topic1,topic2
---
apiVersion: messaging.knative.dev/v1alpha1
kind: KafkaChannel
metadata:
  name: my-kafka-channel
spec:
  bootstrap.servers:
    configMapKeyRef:          # point to common configuration
      name:  kafka-cluster-config
      key: bootstrap.servers
  security.protocol: sasl_ssl
  sasl.mechanisms: PLAIN
  sasl.username:
    secretKeyRef:
      name: kafka-creds-secret
      key: user
  sasl.password:
    secretKeyRef:
      name: kafka-creds-secret
      key: password
---
apiVersion: v1
kind: ConfigMap
metadata:
  name: kafka-cluster-config
data:
  bootstrap.servers: broker-0:9093,broker-1:9093,broker-2:9093

Obviously this is a bit more verbose, and has property names (but not values) duplicated across both the configuration of the source and channel. However, the benefit is that it has enough flexibility to allow Kafka-specific configuration to be stored in one place (perhaps a secret generated by an operator that provisions Kafka) and then referenced from multiple sources and/or channels. Of the two options, this would be my preference.

On Thu, Oct 31, 2019 at 10:23 AM Adrian Preston<EMAIL_ADDRESS>wrote:

@lionelvillard https://github.com/lionelvillard - well, I think we've
ruled out one potential approach 😄
Mulling this over, I can think of two alternate approaches that we could
take:
Option 1
Implement something similar to my comment, here
https://github.com/knative/eventing-contrib/issues/655#issuecomment-546121495,
but using a CR rather than a config map for the common configuration. I
don't really like this approach, as I can't point at another example where
this has been done. There's also the question of what to do if the same
configuration property is present in, say, both the source resource and
this custom configuration resource - for example:
apiVersion: sources.eventing.knative.dev/v1alpha1
kind: KafkaSource
metadata:
name: my-kafka-source
spec:
specFrom:
kafkaCommonRef: kafka-cluster-config

security.protocol: ssl                # duplicated in KafkaCommon CR

I do like this approach provided you specify the simple precedence rule
that "local" values given directly in the YAML are preferred over "shared"
values from a config map.
This kind of "layered" config is very common, for example command-line
tools that read a config file, env. vars. and command-line flags: command
line flags (most local) get highest precedence and the config file (most
shared) gets lowest.  I don't think it would be surprising to most
developers.
The benefit is it supports a range of configuration styles:

specify everything in the CR with no dependency on external resources -
handy for simple, self-contained cases.
specify everything in a shared configmap, but also allow individual
instances to over-ride specific items

In this case, which value of security.protocol do we use? Again, I
haven't come across resources which have an order of precedence. So I
wonder if this will surprise users, and be difficult to debug if the
duplication is introduced by accident.

The notion of "nearest" or "more specific" config taking precedence is
common enough in the software world at large that I don't think it would
cause confusion.

Option 2

Move away from trying to store common configuration in one resource and
allow individual properties of the Kafka source / channel to reference
configuration properties from a config map or secret. As a starting point,
we could require sasl.username and sasl.password to be a secretKeyRef and
allow bootstrap.servers to either be a string literal, a configMapRef or
a secretKeyRef. In the future, we might want to extend this to having
more configuration properties supporting indirection.

Seems to me you can combine the two options:   specFrom  loads everything
in a config-map as the default config. Subsequent config items can specify
values directly in YAML or references to other config map or secrets
entries as you show below. A singfle, flexible, standardized approach to
config to be used consistently by all sources (eventually)

For example:
apiVersion: sources.eventing.knative.dev/v1alpha1
kind: KafkaSource
metadata:
name: my-kafka-source
spec:
bootstrap.servers:
configMapKeyRef:          # point to common configuration

  name:  kafka-cluster-config

  key: bootstrap.servers

security.protocol: sasl_ssl
sasl.mechanisms: PLAIN
sasl.username:
secretKeyRef:

  name: kafka-creds-secret

  key: user

sasl.password:
secretKeyRef:

  name: kafka-creds-secret

  key: password

group.id: consumer-group-id
topics: topic1,topic2

apiVersion: messaging.knative.dev/v1alpha1
kind: KafkaChannel
metadata:
name: my-kafka-channel
spec:
bootstrap.servers:
configMapKeyRef:          # point to common configuration

  name:  kafka-cluster-config

  key: bootstrap.servers

security.protocol: sasl_ssl
sasl.mechanisms: PLAIN
sasl.username:
secretKeyRef:

  name: kafka-creds-secret

  key: user

sasl.password:
secretKeyRef:

  name: kafka-creds-secret

  key: password

apiVersion: v1
kind: ConfigMap
metadata:
name: kafka-cluster-config
data:
bootstrap.servers: broker-0:9093,broker-1:9093,broker-2:9093
Obviously this is a bit more verbose, and has property names (but not
values) duplicated across both the configuration of the source and channel.
However, the benefit is that it has enough flexibility to allow
Kafka-specific configuration to be stored in one place (perhaps a secret
generated by an operator that provisions Kafka) and then referenced from
multiple sources and/or channels. Of the two options, this would be my
preference.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
https://github.com/knative/eventing-contrib/issues/655?email_source=notifications&email_token=AB3LUXXZQ35JVLFBYRDH2Z3QRKW3NA5CNFSM4JBMDZH2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOECXHE2I#issuecomment-548303465,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AB3LUXUUM6OZYPZOVV4SPX3QRKW3NANCNFSM4JBMDZHQ
.

One scenario to consider is making it easy for k8s services using Kafka clients to use this configuration. That's usually done via mounting configmap and secret. So for this scenario I would probably stay away from CRD for the common shareable configuration.
I'm fine with overloading at the CRD level (as @alanconway suggest). This is common.

It looks to me as well that overriding shared configuration would layered approach would be the best developer/operator experience @alanconway @lionelvillard @prestona
Now that 0.10 is released I am going to open work-in-progress PR so we can test what works

I have put together slides that describe the problem and proposed solution with overriding
https://docs.google.com/presentation/d/1FaOYpenTlvZ5jq8ZYW56cX5TAYI9g42vElWfzMI2pTE/edit?usp=sharing

/assign

As I am implementing initial design I realized lot of things can be simplified by using kafka.properties file as a secret that is then passed to Kafka source and channel. That file provides properties that can be easily copied from existing Apache Kafka (or librdkafka) setup.
For example  using kafka.properties from Apache Kafka I can create one shared secret and use it to configure Kafka source:
$ cat kafka.properties
sasl.jaas.config=org.apache.kafka.common.security.plain.PlainLoginModule required username="T7f3xuwnKG0Q5V71" password="Xwup9VRp9diu4CD04vHLBIe9cLlAy3QP";
security.protocol=SASL_SSL
sasl.mechanism=PLAIN
ssl.protocol=TLSv1.2
ssl.enabled.protocols=TLSv1.2
ssl.endpoint.identification.algorithm=HTTPS
bootstrap.servers=my-server:9093

$ kubectl create secret generic kafka-binding --from-file=kafka.properties

  apiVersion: sources.eventing.knative.dev/v1alpha1
   kind: KafkaSource
   metadata:
     name: kafka-source
   spec:
     binding:
       name: kafka-binding
     bootstrapServers: REPLACE_WITH_CLUSTER_URL
...

Where bootstrapServers in  YAML are overriding bootstrap.servers property from kafka.properties file (list of properties to consider https://kafka.apache.org/documentation/#consumerconfigs )
Also updated https://docs.google.com/document/d/1PLYm8amLRKmKK5FAo_34ZOKwTbYU9ooMjrjwkiPc7qA/edit#heading=h.8j7ss5mualq6

@aslom,
Using the contents of kafka.properties as the key/values in a secret would certainly simplify the use-case where Kafka configuration already exists elsewhere.
I'm keen that there is also a way to reference SASL username, password and bootstrap servers when they are stored elsewhere - as this supports use-cases where the Kafka configuration is stored in cluster using a secret which perhaps doesn't conform exactly to the Kafka configuration properties. This could be achieved by supporting valueFrom / secretKeyRef properties for the overrides in the KafkaSource / KafkaChannel CRD.
Finally, I think that using Java's sasl.jaas.config property is a bit ugly:
sasl.jaas.config=org.apache.kafka.common.security.plain.PlainLoginModule required username="T7f3xuwnKG0Q5V71" password="Xwup9VRp9diu4CD04vHLBIe9cLlAy3QP";

I would prefer lifting librdkafka's configuration properties for SASL. Specifically: sasl.username and sasl.password. Using separate properties for username / password also makes it possible to reference values from another secret via accepting valueFrom / secretKeyRef properties.

@prestona I have now an example how that would work in https://github.com/knative/eventing-contrib/compare/master...aslom:consistent-knative-kafka-config
I am finishing writing and will be doing PR as soon as basic properties work.
I will see what can be done to support valueFrom / secretKeyRef for source and channel CR.


EyouCMS-V1.6.4-UTF8-SP1 has a vulnerability, Stored Cross-Site Scripting

Version:
<=EyouCMS-V1.6.4-UTF8-SP1

Description:

Log in to the backend with an administrator account, click on "Function Map" and add "Document Properties".

Select "Document Properties" and change the name of one of the properties to <img src=1 onerror=alert(1).

The principle is the same as https://github.com/weng-xianhu/eyoucms/issues/52.

Thank you for your feedback. It has been fixed


visual p100 test

I just used some images instead of using drawing up the checkerboard and red dot with code.
I had to update the PsychoPy version because 2020.2.3 was using an old version of PsychXR which only supported up to Python v3.6.

Let me know of any thing I need to change, like consolidating this experiment with the existing VEP code before it can be merged.
Thanks a lot for this great open source project.

Hi Ben.
This looks great!
There's quite a lot of interesting pieces here. I was wondering if you would be able to join an eegnb developer's meeting to talk us through a bit? Our next one is 10am EST on Thurs 20th.
A few thoughts so far:

Do you have an example dataset that shows the intended P100 effect and can be fetched and used in the docs example script ?
The 01r_p100_viz.ipynb needs to be a .py file, and the sphinx gallery docs will build it into a jupyter notebook, as per the other examples.
Good job on finding the develop branch and submitting the PR to there. FYI though we are on the cusp of merging a major refactor on the develop branch that simplifies substantially the experiment definition process. I think it would be best if we wait until that is done before merging this PR with some adjustments to meet the new conventions.

Hi John, thanks for the quick feedback.
Yeah sure I'll try to join the next meeting to give an overview of the changes, I find running through pull requests over a video call a nice way to get people across changes.
I'll take a look into dealing with points you've raised - I'll try getting across the experiment refactor and think how these changes will fit.

This work will be added in a new PR after merging the vr support for the n170 experiment.


West doc fixes

Updates from a periodic review of existing documentation.

@carlescufi @marc-hb @dbkinder comments addressed; thanks for review!


Set default value of sayid-ring set to empty list

Fixes #43

Hmm, in Elisp nil and () are the same thing, so I'm puzzled that this is resulting in some change.


fix: #728

Use same storage regardless of flow in sample
The "smart" way to select a different storage type in the sample
was causing issues. Sometimes the setStorage(localStorage) call
would be made just before the first time someone uses Code Flow
which after the redirect causes the app to look in sessionStorage
for the nonce (which it wont find as the initiation of Code Flow
still used the localStorage).
This fix changes it to always use the same storage type, which gives
more reliable results. (I did consider further tweaking the "smart"
way to select the right storage, but it's super hard to predict in
which order(s) users will swap between flow types in the sample).
See also: https://github.com/manfredsteyer/angular-oauth2-oidc/issues/728#issuecomment-808969225
Fixes #728

Thanks!